Index: core/binutils/2.43.1/PATCHES
===================================================================
--- core/binutils/2.43.1/PATCHES (revision 75)
+++ core/binutils/2.43.1/PATCHES (nonexistent)
@@ -1,16 +0,0 @@
-
-../../../sources/GNU/binutils/patches/binutils-2.43.1-copy-osabi.patch -p0
-../../../sources/GNU/binutils/patches/binutils-2.43.1-ldforcele.patch -p0
-../../../sources/GNU/binutils/patches/binutils-2.43.1-libtool-lib64.patch -p0
-../../../sources/GNU/binutils/patches/binutils-2.43.1-cleansweep.patch -p0
-../../../sources/GNU/binutils/patches/binutils-2.43.1-export-demangle.patch -p0
-../../../sources/GNU/binutils/patches/binutils-2.43.1-no-config-check.patch -p0
-
-../../../sources/GNU/binutils/patches/binutils-2.43.1-aarch64-ifunc.patch -p0
-../../../sources/GNU/binutils/patches/binutils-2.43.1-fname-in-error-messages.patch -p0
-../../../sources/GNU/binutils/patches/binutils-2.43.1-gold-i386-gnu-property-notes.patch -p0
-../../../sources/GNU/binutils/patches/binutils-2.43.1-gold-mismatched-section-flags.patch -p0
-../../../sources/GNU/binutils/patches/binutils-2.43.1-gold-warn-unsupported.patch -p0
-../../../sources/GNU/binutils/patches/binutils-2.43.1-not-link-static-libstdc++.patch -p0
-../../../sources/GNU/binutils/patches/binutils-2.43.1-readelf-other-sym-info.patch -p0
-../../../sources/GNU/binutils/patches/binutils-2.43.1-testsuite-failures.patch -p0
Index: core/binutils/2.43.1/Makefile
===================================================================
--- core/binutils/2.43.1/Makefile (revision 75)
+++ core/binutils/2.43.1/Makefile (nonexistent)
@@ -1,736 +0,0 @@
-
-
-COMPONENT_TARGETS = $(TOOLCHAIN_ARM32_NEWLIB)
-COMPONENT_TARGETS += $(TOOLCHAIN_A33XX_NEWLIB)
-COMPONENT_TARGETS += $(TOOLCHAIN_A9XX_NEWLIB)
-COMPONENT_TARGETS += $(TOOLCHAIN_H5_NEWLIB)
-COMPONENT_TARGETS += $(TOOLCHAIN_S9XX_NEWLIB)
-COMPONENT_TARGETS += $(TOOLCHAIN_RK33XX_NEWLIB)
-COMPONENT_TARGETS += $(TOOLCHAIN_M1000_NEWLIB)
-COMPONENT_TARGETS += $(TOOLCHAIN_AT91SAM7S_NEWLIB)
-COMPONENT_TARGETS += $(TOOLCHAIN_RISCV64_NEWLIB)
-
-COMPONENT_TARGETS += $(TOOLCHAIN_A1X_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_A2X_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_H3_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_H5_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_IMX6_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_IMX6ULL_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_JZ47XX_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_P5600_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_M1000_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_OMAP543X_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_AM335X_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_RK328X_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_S8XX_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_S9XX_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_A9XX_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_A311X_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_RK33XX_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_RK339X_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_RK358X_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_A33XX_GLIBC)
-
-COMPONENT_TARGETS += $(TOOLCHAIN_PPC8_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_PPC9_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_POWER8_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_POWER9_GLIBC)
-
-COMPONENT_TARGETS += $(TOOLCHAIN_POWER8LE_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_POWER9LE_GLIBC)
-
-COMPONENT_TARGETS += $(TOOLCHAIN_RISCV64_GLIBC)
-
-COMPONENT_TARGETS += $(TOOLCHAIN_I586_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_I686_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_X86_64_GLIBC)
-
-
-include ../../../build-system/config.mk
-
-
-SOURCE_REQUIRES = sources/GNU/binutils
-
-# ======= __END_OF_REQUIRES__ =======
-
-tar_xz_archive = $(SRC_PACKAGE_PATH)/GNU/binutils/binutils-2.43.1.tar.xz
-SRC_ARCHIVE = $(tar_xz_archive)
-SRC_DIR = $(TARGET_BUILD_DIR)/binutils-2.43.1
-src_dir_name = binutils-2.43.1
-src_done = $(SRC_DIR)/.source-done
-
-PATCHES = PATCHES
-
-build_dir = $(TARGET_BUILD_DIR)/build
-install_dir = $(TOOLCHAIN_PATH)
-
-sysroot_dir = $(TOOLCHAIN_PATH)/$(TARGET)/sys-root
-
-build_target = $(TARGET_BUILD_DIR)/.built
-install_target = $(TARGET_BUILD_DIR)/.installed
-
-
-BUILD_TARGETS = $(build_target)
-BUILD_TARGETS += $(install_target)
-
-include ../../../build-system/core.mk
-
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_ARM32_NEWLIB))
-extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
-extra_configure_switches += '--with-bugurl=https://radix-linux.su'
-extra_configure_switches += --disable-werror
-extra_configure_switches += --enable-interwork
-extra_configure_switches += --enable-multilib
-extra_configure_switches += --with-abi=aapcs
-extra_configure_switches += --enable-plugins
-extra_configure_switches += --with-sysroot=$(TOOLCHAIN_PATH)/$(TARGET)
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A33XX_NEWLIB))
-extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
-extra_configure_switches += '--with-bugurl=https://radix-linux.su'
-extra_configure_switches += --disable-werror
-extra_configure_switches += --enable-interwork
-extra_configure_switches += --enable-multilib
-extra_configure_switches += --with-abi=aapcs
-extra_configure_switches += --enable-plugins
-extra_configure_switches += --with-sysroot=$(TOOLCHAIN_PATH)/$(TARGET)
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A9XX_NEWLIB))
-extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
-extra_configure_switches += '--with-bugurl=https://radix-linux.su'
-extra_configure_switches += --disable-werror
-extra_configure_switches += --enable-interwork
-extra_configure_switches += --enable-multilib
-extra_configure_switches += --with-abi=aapcs
-extra_configure_switches += --enable-plugins
-extra_configure_switches += --with-sysroot=$(TOOLCHAIN_PATH)/$(TARGET)
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_H5_NEWLIB))
-extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
-extra_configure_switches += '--with-bugurl=https://radix-linux.su'
-extra_configure_switches += --disable-multiarch
-extra_configure_switches += --enable-multilib
-extra_configure_switches += --with-cpu=cortex-a53
-extra_configure_switches += --with-arch=armv8-a
-extra_configure_switches += --enable-plugins
-extra_configure_switches += --with-sysroot=$(TOOLCHAIN_PATH)/$(TARGET)
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_S9XX_NEWLIB))
-extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
-extra_configure_switches += '--with-bugurl=https://radix-linux.su'
-extra_configure_switches += --disable-multiarch
-extra_configure_switches += --enable-multilib
-extra_configure_switches += --with-cpu=cortex-a53
-extra_configure_switches += --with-arch=armv8-a
-extra_configure_switches += --enable-plugins
-extra_configure_switches += --with-sysroot=$(TOOLCHAIN_PATH)/$(TARGET)
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_RK33XX_NEWLIB))
-extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
-extra_configure_switches += '--with-bugurl=https://radix-linux.su'
-extra_configure_switches += --disable-multiarch
-extra_configure_switches += --enable-multilib
-extra_configure_switches += --with-cpu=cortex-a53
-extra_configure_switches += --with-arch=armv8-a
-extra_configure_switches += --enable-plugins
-extra_configure_switches += --with-sysroot=$(TOOLCHAIN_PATH)/$(TARGET)
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_M1000_NEWLIB))
-extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
-extra_configure_switches += '--with-bugurl=https://radix-linux.su'
-extra_configure_switches += --disable-multiarch
-extra_configure_switches += --enable-multilib
-extra_configure_switches += --with-cpu=cortex-a57
-extra_configure_switches += --with-arch=armv8-a
-extra_configure_switches += --enable-plugins
-extra_configure_switches += --with-sysroot=$(TOOLCHAIN_PATH)/$(TARGET)
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_AT91SAM7S_NEWLIB))
-extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
-extra_configure_switches += '--with-bugurl=https://radix-linux.su'
-extra_configure_switches += --enable-interwork
-extra_configure_switches += --enable-multilib
-extra_configure_switches += --with-float=soft
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_RISCV64_NEWLIB))
-extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
-extra_configure_switches += '--with-bugurl=https://radix-linux.su'
-extra_configure_switches += --enable-multilib
-extra_configure_switches += --with-abi=lp64d
-extra_configure_switches += --with-arch=rv64imafdc
-extra_configure_switches += --enable-plugins
-extra_configure_switches += --with-sysroot=$(TOOLCHAIN_PATH)/$(TARGET)
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_A1X_GLIBC)),)
-extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
-extra_configure_switches += '--with-bugurl=https://radix-linux.su'
-# experimental gold linker( DEFAULT_LD=ld.bfd ):
-extra_configure_switches += --enable-gold=yes
-extra_configure_switches += --enable-ld=default
-extra_configure_switches += --enable-werror=no
-# standard options:
-extra_configure_switches += --enable-interwork
-extra_configure_switches += --enable-multilib
-extra_configure_switches += --with-cpu=cortex-a8
-extra_configure_switches += --with-arch=armv7-a
-extra_configure_switches += --with-fpu=neon
-extra_configure_switches += --with-abi=aapcs-linux
-extra_configure_switches += --disable-compressed-debug-sections
-extra_configure_switches += --with-sysroot=$(sysroot_dir)
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_A2X_GLIBC)),)
-extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
-extra_configure_switches += '--with-bugurl=https://radix-linux.su'
-# experimental gold linker( DEFAULT_LD=ld.bfd ):
-extra_configure_switches += --enable-gold=yes
-extra_configure_switches += --enable-ld=default
-extra_configure_switches += --enable-werror=no
-# standard options:
-extra_configure_switches += --enable-interwork
-extra_configure_switches += --enable-multilib
-extra_configure_switches += --with-cpu=cortex-a7
-extra_configure_switches += --with-arch=armv7ve
-extra_configure_switches += --with-fpu=neon-vfpv4
-extra_configure_switches += --with-abi=aapcs-linux
-extra_configure_switches += --disable-compressed-debug-sections
-extra_configure_switches += --with-sysroot=$(sysroot_dir)
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_H3_GLIBC)),)
-extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
-extra_configure_switches += '--with-bugurl=https://radix-linux.su'
-# experimental gold linker( DEFAULT_LD=ld.bfd ):
-extra_configure_switches += --enable-gold=yes
-extra_configure_switches += --enable-ld=default
-extra_configure_switches += --enable-werror=no
-# standard options:
-extra_configure_switches += --enable-interwork
-extra_configure_switches += --enable-multilib
-extra_configure_switches += --with-arch=armv7ve
-extra_configure_switches += --with-tune=cortex-a7
-extra_configure_switches += --with-fpu=neon-vfpv4
-extra_configure_switches += --with-abi=aapcs-linux
-extra_configure_switches += --disable-compressed-debug-sections
-extra_configure_switches += --with-sysroot=$(sysroot_dir)
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_H5_GLIBC)),)
-extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
-extra_configure_switches += '--with-bugurl=https://radix-linux.su'
-# experimental gold linker( DEFAULT_LD=ld.bfd ):
-extra_configure_switches += --enable-gold=yes
-extra_configure_switches += --enable-ld=default
-extra_configure_switches += --enable-werror=no
-# standard options:
-extra_configure_switches += --disable-multilib
-extra_configure_switches += --with-cpu=cortex-a53
-extra_configure_switches += --with-arch=armv8-a
-extra_configure_switches += --with-fpu=neon-fp-armv8
-extra_configure_switches += --with-abi=lp64
-extra_configure_switches += --disable-compressed-debug-sections
-extra_configure_switches += --with-sysroot=$(sysroot_dir)
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_S8XX_GLIBC)),)
-extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
-extra_configure_switches += '--with-bugurl=https://radix-linux.su'
-# experimental gold linker( DEFAULT_LD=ld.bfd ):
-extra_configure_switches += --enable-gold=yes
-extra_configure_switches += --enable-ld=default
-extra_configure_switches += --enable-werror=no
-# standard options:
-extra_configure_switches += --enable-interwork
-extra_configure_switches += --enable-multilib
-extra_configure_switches += --with-cpu=cortex-a5
-extra_configure_switches += --with-arch=armv7-a
-extra_configure_switches += --with-fpu=neon
-extra_configure_switches += --with-abi=aapcs-linux
-extra_configure_switches += --disable-compressed-debug-sections
-extra_configure_switches += --with-sysroot=$(sysroot_dir)
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_S9XX_GLIBC)),)
-extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
-extra_configure_switches += '--with-bugurl=https://radix-linux.su'
-# experimental gold linker( DEFAULT_LD=ld.bfd ):
-extra_configure_switches += --enable-gold=yes
-extra_configure_switches += --enable-ld=default
-extra_configure_switches += --enable-werror=no
-# standard options:
-extra_configure_switches += --disable-multilib
-extra_configure_switches += --with-cpu=cortex-a53
-extra_configure_switches += --with-arch=armv8-a
-extra_configure_switches += --with-fpu=neon-fp-armv8
-extra_configure_switches += --with-abi=lp64
-extra_configure_switches += --disable-compressed-debug-sections
-extra_configure_switches += --with-sysroot=$(sysroot_dir)
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_A9XX_GLIBC)),)
-extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
-extra_configure_switches += '--with-bugurl=https://radix-linux.su'
-# experimental gold linker( DEFAULT_LD=ld.bfd ):
-extra_configure_switches += --enable-gold=yes
-extra_configure_switches += --enable-ld=default
-extra_configure_switches += --enable-werror=no
-# standard options:
-extra_configure_switches += --disable-multilib
-extra_configure_switches += --with-cpu=cortex-a53
-extra_configure_switches += --with-arch=armv8-a
-extra_configure_switches += --with-fpu=neon-fp-armv8
-extra_configure_switches += --disable-compressed-debug-sections
-extra_configure_switches += --with-sysroot=$(sysroot_dir)
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_A311X_GLIBC)),)
-extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
-extra_configure_switches += '--with-bugurl=https://radix-linux.su'
-# experimental gold linker( DEFAULT_LD=ld.bfd ):
-extra_configure_switches += --enable-gold=yes
-extra_configure_switches += --enable-ld=default
-extra_configure_switches += --enable-werror=no
-# standard options:
-extra_configure_switches += --disable-multilib
-extra_configure_switches += --with-cpu=cortex-a53
-extra_configure_switches += --with-arch=armv8-a
-extra_configure_switches += --with-fpu=neon-fp-armv8
-extra_configure_switches += --with-abi=lp64
-extra_configure_switches += --disable-compressed-debug-sections
-extra_configure_switches += --with-sysroot=$(sysroot_dir)
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_RK33XX_GLIBC)),)
-extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
-extra_configure_switches += '--with-bugurl=https://radix-linux.su'
-# experimental gold linker( DEFAULT_LD=ld.bfd ):
-extra_configure_switches += --enable-gold=yes
-extra_configure_switches += --enable-ld=default
-extra_configure_switches += --enable-werror=no
-# standard options:
-extra_configure_switches += --disable-multilib
-extra_configure_switches += --with-cpu=cortex-a53
-extra_configure_switches += --with-arch=armv8-a
-extra_configure_switches += --with-fpu=neon-fp-armv8
-extra_configure_switches += --with-abi=lp64
-extra_configure_switches += --with-sysroot=$(sysroot_dir)
-extra_configure_switches += --disable-compressed-debug-sections
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_RK339X_GLIBC)),)
-extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
-extra_configure_switches += '--with-bugurl=https://radix-linux.su'
-# experimental gold linker( DEFAULT_LD=ld.bfd ):
-extra_configure_switches += --enable-gold=yes
-extra_configure_switches += --enable-ld=default
-extra_configure_switches += --enable-werror=no
-# standard options:
-extra_configure_switches += --disable-multilib
-extra_configure_switches += --with-cpu=cortex-a53
-extra_configure_switches += --with-arch=armv8-a
-extra_configure_switches += --with-fpu=neon-fp-armv8
-extra_configure_switches += --with-abi=lp64
-extra_configure_switches += --disable-compressed-debug-sections
-extra_configure_switches += --with-sysroot=$(sysroot_dir)
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_RK358X_GLIBC)),)
-extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
-extra_configure_switches += '--with-bugurl=https://radix-linux.su'
-# experimental gold linker( DEFAULT_LD=ld.bfd ):
-extra_configure_switches += --enable-gold=yes
-extra_configure_switches += --enable-ld=default
-extra_configure_switches += --enable-werror=no
-# standard options:
-extra_configure_switches += --disable-multilib
-extra_configure_switches += --with-cpu=cortex-a75
-extra_configure_switches += --with-arch=armv8.2-a
-extra_configure_switches += --with-fpu=neon-fp-armv8
-extra_configure_switches += --with-abi=lp64
-extra_configure_switches += --disable-compressed-debug-sections
-extra_configure_switches += --with-sysroot=$(sysroot_dir)
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_A33XX_GLIBC)),)
-extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
-extra_configure_switches += '--with-bugurl=https://radix-linux.su'
-# experimental gold linker( DEFAULT_LD=ld.bfd ):
-extra_configure_switches += --enable-gold=yes
-extra_configure_switches += --enable-ld=default
-extra_configure_switches += --enable-werror=no
-# standard options:
-extra_configure_switches += --disable-multilib
-extra_configure_switches += --with-cpu=cortex-a53
-extra_configure_switches += --with-arch=armv8-a
-extra_configure_switches += --with-fpu=neon-fp-armv8
-extra_configure_switches += --disable-compressed-debug-sections
-extra_configure_switches += --with-sysroot=$(sysroot_dir)
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_RK328X_GLIBC)),)
-extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
-extra_configure_switches += '--with-bugurl=https://radix-linux.su'
-# experimental gold linker( DEFAULT_LD=ld.bfd ):
-extra_configure_switches += --enable-gold=yes
-extra_configure_switches += --enable-ld=default
-extra_configure_switches += --enable-werror=no
-extra_configure_switches += --enable-plugins
-# standard options:
-extra_configure_switches += --enable-interwork
-extra_configure_switches += --enable-multilib
-extra_configure_switches += --with-cpu=cortex-a17
-extra_configure_switches += --with-arch=armv7ve
-extra_configure_switches += --with-fpu=neon-vfpv4
-extra_configure_switches += --with-abi=aapcs-linux
-extra_configure_switches += --disable-compressed-debug-sections
-extra_configure_switches += --with-sysroot=$(sysroot_dir)
-endif
-
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_IMX6_GLIBC)),)
-extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
-extra_configure_switches += '--with-bugurl=https://radix-linux.su'
-# experimental gold linker( DEFAULT_LD=ld.bfd ):
-extra_configure_switches += --enable-gold=yes
-extra_configure_switches += --enable-ld=default
-extra_configure_switches += --enable-werror=no
-# standard options:
-extra_configure_switches += --enable-interwork
-extra_configure_switches += --enable-multilib
-extra_configure_switches += --with-arch=armv7-a
-extra_configure_switches += --with-tune=cortex-a9
-extra_configure_switches += --with-fpu=vfpv3
-extra_configure_switches += --with-abi=aapcs-linux
-extra_configure_switches += --disable-compressed-debug-sections
-extra_configure_switches += --with-sysroot=$(sysroot_dir)
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_IMX6ULL_GLIBC)),)
-extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
-extra_configure_switches += '--with-bugurl=https://radix-linux.su'
-# experimental gold linker( DEFAULT_LD=ld.bfd ):
-extra_configure_switches += --enable-gold=yes
-extra_configure_switches += --enable-ld=default
-extra_configure_switches += --enable-werror=no
-# standard options:
-extra_configure_switches += --enable-interwork
-extra_configure_switches += --enable-multilib
-extra_configure_switches += --with-arch=armv7-a
-extra_configure_switches += --with-cpu=cortex-a7
-extra_configure_switches += --with-fpu=neon-vfpv4
-extra_configure_switches += --with-abi=aapcs-linux
-extra_configure_switches += --disable-compressed-debug-sections
-extra_configure_switches += --with-sysroot=$(sysroot_dir)
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_OMAP543X_GLIBC)),)
-extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
-extra_configure_switches += '--with-bugurl=https://radix-linux.su'
-# experimental gold linker( DEFAULT_LD=ld.bfd ):
-extra_configure_switches += --enable-gold=yes
-extra_configure_switches += --enable-ld=default
-extra_configure_switches += --enable-werror=no
-# standard options:
-extra_configure_switches += --enable-interwork
-extra_configure_switches += --enable-multilib
-extra_configure_switches += --with-arch=armv7ve
-extra_configure_switches += --with-tune=cortex-a15
-extra_configure_switches += --with-fpu=neon-vfpv4
-extra_configure_switches += --with-abi=aapcs-linux
-extra_configure_switches += --disable-compressed-debug-sections
-extra_configure_switches += --with-sysroot=$(sysroot_dir)
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_AM335X_GLIBC)),)
-extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
-extra_configure_switches += '--with-bugurl=https://radix-linux.su'
-# experimental gold linker( DEFAULT_LD=ld.bfd ):
-extra_configure_switches += --enable-gold=yes
-extra_configure_switches += --enable-ld=default
-extra_configure_switches += --enable-werror=no
-# standard options:
-extra_configure_switches += --enable-interwork
-extra_configure_switches += --enable-multilib
-extra_configure_switches += --with-arch=armv7-a
-extra_configure_switches += --with-tune=cortex-a8
-extra_configure_switches += --with-fpu=neon
-extra_configure_switches += --with-abi=aapcs-linux
-extra_configure_switches += --disable-compressed-debug-sections
-extra_configure_switches += --with-sysroot=$(sysroot_dir)
-endif
-
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_JZ47XX_GLIBC)),)
-extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
-extra_configure_switches += '--with-bugurl=https://radix-linux.su'
-# experimental gold linker( DEFAULT_LD=ld.bfd ):
-extra_configure_switches += --enable-gold=yes
-extra_configure_switches += --enable-ld=default
-extra_configure_switches += --enable-werror=no
-# standard options:
-extra_configure_switches += --enable-multilib
-extra_configure_switches += --with-arch=mips32r2
-extra_configure_switches += --enable-plugins
-extra_configure_switches += --disable-compressed-debug-sections
-extra_configure_switches += --with-sysroot=$(sysroot_dir)
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_P5600_GLIBC)),)
-extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
-extra_configure_switches += '--with-bugurl=https://radix-linux.su'
-# experimental gold linker( DEFAULT_LD=ld.bfd ):
-extra_configure_switches += --enable-gold=yes
-extra_configure_switches += --enable-ld=default
-extra_configure_switches += --enable-werror=no
-# standard options:
-extra_configure_switches += --enable-multilib
-extra_configure_switches += --with-arch=mips32r5
-extra_configure_switches += --enable-plugins
-extra_configure_switches += --disable-compressed-debug-sections
-extra_configure_switches += --with-sysroot=$(sysroot_dir)
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_M1000_GLIBC)),)
-extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
-extra_configure_switches += '--with-bugurl=https://radix-linux.su'
-# experimental gold linker( DEFAULT_LD=ld.bfd ):
-extra_configure_switches += --enable-gold=yes
-extra_configure_switches += --enable-ld=default
-extra_configure_switches += --enable-werror=no
-# standard options:
-extra_configure_switches += --disable-multilib
-extra_configure_switches += --with-cpu=cortex-a57
-extra_configure_switches += --with-arch=armv8-a
-extra_configure_switches += --with-fpu=neon-fp-armv8
-extra_configure_switches += --with-abi=lp64
-extra_configure_switches += --disable-compressed-debug-sections
-extra_configure_switches += --with-sysroot=$(sysroot_dir)
-endif
-
-
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_PPC8_GLIBC)),)
-extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
-extra_configure_switches += '--with-bugurl=https://radix-linux.su'
-# experimental gold linker( DEFAULT_LD=ld.bfd ):
-extra_configure_switches += --enable-gold=yes
-extra_configure_switches += --enable-ld=default
-extra_configure_switches += --enable-werror=no
-# standard options:
-extra_configure_switches += --disable-multilib
-extra_configure_switches += --enable-plugins
-extra_configure_switches += --enable-targets=ppc-radix-linux,ppc-linux,powerpc-radix-linux,powerpc-linux
-extra_configure_switches += --enable-64-bit-bfd
-extra_configure_switches += --disable-compressed-debug-sections
-extra_configure_switches += --with-sysroot=$(sysroot_dir)
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_PPC9_GLIBC)),)
-extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
-extra_configure_switches += '--with-bugurl=https://radix-linux.su'
-# experimental gold linker( DEFAULT_LD=ld.bfd ):
-extra_configure_switches += --enable-gold=yes
-extra_configure_switches += --enable-ld=default
-extra_configure_switches += --enable-werror=no
-# standard options:
-extra_configure_switches += --disable-multilib
-extra_configure_switches += --enable-plugins
-extra_configure_switches += --enable-targets=ppc-radix-linux,ppc-linux,powerpc-radix-linux,powerpc-linux
-extra_configure_switches += --enable-64-bit-bfd
-extra_configure_switches += --disable-compressed-debug-sections
-extra_configure_switches += --with-sysroot=$(sysroot_dir)
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_POWER8_GLIBC)),)
-extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
-extra_configure_switches += '--with-bugurl=https://radix-linux.su'
-# experimental gold linker( DEFAULT_LD=ld.bfd ):
-extra_configure_switches += --enable-gold=yes
-extra_configure_switches += --enable-ld=default
-extra_configure_switches += --enable-werror=no
-# standard options:
-extra_configure_switches += --enable-multilib
-extra_configure_switches += --enable-plugins
-extra_configure_switches += --enable-targets=ppc64-radix-linux,powerpc64-radix-linux,ppc64-linux,powerpc64-linux,ppc-radix-linux,powerpc-radix-linux,ppc-linux,powerpc-linux
-extra_configure_switches += --enable-64-bit-bfd
-extra_configure_switches += --disable-compressed-debug-sections
-extra_configure_switches += --with-sysroot=$(sysroot_dir)
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_POWER9_GLIBC)),)
-extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
-extra_configure_switches += '--with-bugurl=https://radix-linux.su'
-# experimental gold linker( DEFAULT_LD=ld.bfd ):
-extra_configure_switches += --enable-gold=yes
-extra_configure_switches += --enable-ld=default
-extra_configure_switches += --enable-werror=no
-# standard options:
-extra_configure_switches += --enable-multilib
-extra_configure_switches += --enable-plugins
-extra_configure_switches += --enable-targets=ppc64-radix-linux,powerpc64-radix-linux,ppc64-linux,powerpc64-linux,ppc-radix-linux,powerpc-radix-linux,ppc-linux,powerpc-linux
-extra_configure_switches += --enable-64-bit-bfd
-extra_configure_switches += --disable-compressed-debug-sections
-extra_configure_switches += --with-sysroot=$(sysroot_dir)
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_POWER8LE_GLIBC)),)
-extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
-extra_configure_switches += '--with-bugurl=https://radix-linux.su'
-# experimental gold linker( DEFAULT_LD=ld.bfd ):
-extra_configure_switches += --enable-gold=yes
-extra_configure_switches += --enable-ld=default
-extra_configure_switches += --enable-werror=no
-# standard options:
-extra_configure_switches += --disable-multilib
-extra_configure_switches += --enable-plugins
-extra_configure_switches += --enable-targets=ppc64le-radix-linux,powerpc64le-radix-linux,ppc64le-linux,powerpc64le-linux,ppcle-radix-linux,powerpcle-radix-linux,ppcle-linux,powerpcle-linux
-extra_configure_switches += --enable-64-bit-bfd
-extra_configure_switches += --disable-compressed-debug-sections
-extra_configure_switches += --with-sysroot=$(sysroot_dir)
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_POWER9LE_GLIBC)),)
-extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
-extra_configure_switches += '--with-bugurl=https://radix-linux.su'
-# experimental gold linker( DEFAULT_LD=ld.bfd ):
-extra_configure_switches += --enable-gold=yes
-extra_configure_switches += --enable-ld=default
-extra_configure_switches += --enable-werror=no
-# standard options:
-extra_configure_switches += --disable-multilib
-extra_configure_switches += --enable-plugins
-extra_configure_switches += --enable-targets=ppc64le-radix-linux,powerpc64le-radix-linux,ppc64le-linux,powerpc64le-linux,ppcle-radix-linux,powerpcle-radix-linux,ppcle-linux,powerpcle-linux
-extra_configure_switches += --enable-64-bit-bfd
-extra_configure_switches += --disable-compressed-debug-sections
-extra_configure_switches += --with-sysroot=$(sysroot_dir)
-endif
-
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_RISCV64_GLIBC))
-extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
-extra_configure_switches += '--with-bugurl=https://radix-linux.su'
-# experimental gold linker( DEFAULT_LD=ld.bfd ):
-extra_configure_switches += --enable-gold=yes
-extra_configure_switches += --enable-ld=default
-# standard options:
-extra_configure_switches += --enable-targets=riscv64-radix-linux,riscv64-linux
-extra_configure_switches += --disable-multilib
-extra_configure_switches += --with-abi=lp64d
-extra_configure_switches += --with-arch=rv64imafdc
-extra_configure_switches += --enable-64-bit-bfd
-extra_configure_switches += --enable-plugins
-extra_configure_switches += --enable-threads
-extra_configure_switches += --disable-compressed-debug-sections
-extra_configure_switches += --with-sysroot=$(TOOLCHAIN_PATH)/$(TARGET)
-endif
-
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_I586_GLIBC)),)
-extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
-extra_configure_switches += '--with-bugurl=https://radix-linux.su'
-# experimental gold linker( DEFAULT_LD=ld.bfd ):
-extra_configure_switches += --enable-gold=yes
-extra_configure_switches += --enable-ld=default
-extra_configure_switches += --enable-werror=no
-# standard options:
-extra_configure_switches += --enable-targets=i586-radix-linux
-extra_configure_switches += --disable-multilib
-extra_configure_switches += --enable-initfini-array
-extra_configure_switches += --enable-plugins
-extra_configure_switches += --enable-threads
-extra_configure_switches += --disable-compressed-debug-sections
-extra_configure_switches += --with-sysroot=$(sysroot_dir)
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_I686_GLIBC)),)
-extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
-extra_configure_switches += '--with-bugurl=https://radix-linux.su'
-# experimental gold linker( DEFAULT_LD=ld.bfd ):
-extra_configure_switches += --enable-gold=yes
-extra_configure_switches += --enable-ld=default
-extra_configure_switches += --enable-werror=no
-# standard options:
-extra_configure_switches += --enable-targets=i686-radix-linux
-extra_configure_switches += --disable-multilib
-extra_configure_switches += --enable-initfini-array
-extra_configure_switches += --enable-plugins
-extra_configure_switches += --enable-threads
-extra_configure_switches += --disable-compressed-debug-sections
-extra_configure_switches += --with-sysroot=$(sysroot_dir)
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_X86_64_GLIBC)),)
-extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
-extra_configure_switches += '--with-bugurl=https://radix-linux.su'
-# experimental gold linker( DEFAULT_LD=ld.bfd ):
-extra_configure_switches += --enable-gold=yes
-extra_configure_switches += --enable-ld=default
-extra_configure_switches += --enable-werror=no
-# standard options:
-extra_configure_switches += --enable-targets=x86_64-radix-linux
-extra_configure_switches += --enable-multilib
-extra_configure_switches += --enable-64-bit-bfd
-extra_configure_switches += --enable-initfini-array
-extra_configure_switches += --enable-plugins
-extra_configure_switches += --enable-threads
-extra_configure_switches += --disable-compressed-debug-sections
-extra_configure_switches += --with-sysroot=$(sysroot_dir)
-endif
-
-
-
-$(src_done): $(SRC_ARCHIVE) $(PATCHES_DEP)
- $(UNPACK_SRC_ARCHIVE)
- $(APPLY_PATCHES)
- # ======= These pages were shipped empty and will need to be regenerated =======
- @( cd $(SRC_DIR) ; \
- rm -f binutils/doc/*.1 binutils/doc/*.man gprof/gprof.1 ld/ld.1 gas/doc/as.1 ; \
- )
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_POWER8_GLIBC) $(TOOLCHAIN_POWER9_GLIBC)),)
- # ======= On ppc64 and aarch64, we might use 64KiB pages =======
- @( cd $(SRC_DIR) ; \
- sed -i -e '/#define.*ELF_COMMONPAGESIZE/s/0x1000$$/0x10000/' bfd/elf*ppc.c ; \
- sed -i -e '/common_pagesize/s/4 /64 /' gold/powerpc.cc ; \
- )
-endif
- @touch $@
-
-$(build_target): $(src_done)
- @mkdir -p $(build_dir)
- @cd $(build_dir) && ../$(src_dir_name)/configure \
- --prefix=$(TOOLCHAIN_PATH) \
- --target=$(TARGET) \
- --infodir=$(TOOLCHAIN_PATH)/share/info \
- --mandir=$(TOOLCHAIN_PATH)/share/man \
- --disable-nls \
- $(extra_configure_switches)
- @$(MAKE) -C $(build_dir)
- @$(MAKE) -C $(build_dir) info
- @touch $@
-
-$(install_target): $(build_target)
- @mkdir -p $(install_dir)
- @$(MAKE) -j1 -C $(build_dir) install
- @$(MAKE) -j1 -C $(build_dir) install-info
- @rm -f $(TOOLCHAIN_PATH)/share/info/dir
- @echo "" > $(TOOLCHAIN_PATH)/README
- @echo " TOOLCHAIN = $(TOOLCHAIN)" >> $(TOOLCHAIN_PATH)/README
- @echo " TARGET = $(TARGET)" >> $(TOOLCHAIN_PATH)/README
- @echo " BASE_PATH = $(TOOLCHAINS_BASE_PATH)" >> $(TOOLCHAIN_PATH)/README
- @echo " DIRECTORY = $(TOOLCHAIN_DIR)" >> $(TOOLCHAIN_PATH)/README
- @echo " VERSION = $(TOOLCHAIN_VERSION)" >> $(TOOLCHAIN_PATH)/README
- @echo "" >> $(TOOLCHAIN_PATH)/README
- @echo "-----------" >> $(TOOLCHAIN_PATH)/README
- @echo "" >> $(TOOLCHAIN_PATH)/README
- @echo " $(subst $(TOP_BUILD_DIR_ABS)/,,$(CURDIR))$(if $(FLAVOUR),:$(FLAVOUR),)" >> $(TOOLCHAIN_PATH)/README
- @touch $@
Index: core/binutils/2.43.1
===================================================================
--- core/binutils/2.43.1 (revision 75)
+++ core/binutils/2.43.1 (nonexistent)
Property changes on: core/binutils/2.43.1
___________________________________________________________________
Deleted: svn:ignore
## -1,81 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.rk358x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: core/binutils/2.44/Makefile
===================================================================
--- core/binutils/2.44/Makefile (nonexistent)
+++ core/binutils/2.44/Makefile (revision 76)
@@ -0,0 +1,737 @@
+
+
+COMPONENT_TARGETS = $(TOOLCHAIN_ARM32_NEWLIB)
+COMPONENT_TARGETS += $(TOOLCHAIN_A33XX_NEWLIB)
+COMPONENT_TARGETS += $(TOOLCHAIN_A9XX_NEWLIB)
+COMPONENT_TARGETS += $(TOOLCHAIN_H5_NEWLIB)
+COMPONENT_TARGETS += $(TOOLCHAIN_S9XX_NEWLIB)
+COMPONENT_TARGETS += $(TOOLCHAIN_RK33XX_NEWLIB)
+COMPONENT_TARGETS += $(TOOLCHAIN_M1000_NEWLIB)
+COMPONENT_TARGETS += $(TOOLCHAIN_AT91SAM7S_NEWLIB)
+COMPONENT_TARGETS += $(TOOLCHAIN_RISCV64_NEWLIB)
+
+COMPONENT_TARGETS += $(TOOLCHAIN_A1X_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_A2X_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_H3_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_H5_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_IMX6_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_IMX6ULL_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_JZ47XX_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_P5600_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_M1000_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_OMAP543X_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_AM335X_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_RK328X_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_S8XX_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_S9XX_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_A9XX_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_A311X_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_RK33XX_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_RK339X_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_RK358X_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_A33XX_GLIBC)
+
+COMPONENT_TARGETS += $(TOOLCHAIN_PPC8_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_PPC9_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_POWER8_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_POWER9_GLIBC)
+
+COMPONENT_TARGETS += $(TOOLCHAIN_POWER8LE_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_POWER9LE_GLIBC)
+
+COMPONENT_TARGETS += $(TOOLCHAIN_RISCV64_GLIBC)
+
+COMPONENT_TARGETS += $(TOOLCHAIN_I586_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_I686_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_X86_64_GLIBC)
+
+
+include ../../../build-system/config.mk
+
+
+SOURCE_REQUIRES = sources/GNU/binutils
+
+# ======= __END_OF_REQUIRES__ =======
+
+tar_xz_archive = $(SRC_PACKAGE_PATH)/GNU/binutils/binutils-2.44.tar.xz
+SRC_ARCHIVE = $(tar_xz_archive)
+SRC_DIR = $(TARGET_BUILD_DIR)/binutils-2.44
+src_dir_name = binutils-2.44
+src_done = $(SRC_DIR)/.source-done
+
+PATCHES = PATCHES
+
+build_dir = $(TARGET_BUILD_DIR)/build
+install_dir = $(TOOLCHAIN_PATH)
+
+sysroot_dir = $(TOOLCHAIN_PATH)/$(TARGET)/sys-root
+
+build_target = $(TARGET_BUILD_DIR)/.built
+install_target = $(TARGET_BUILD_DIR)/.installed
+
+
+BUILD_TARGETS = $(build_target)
+BUILD_TARGETS += $(install_target)
+
+include ../../../build-system/core.mk
+
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_ARM32_NEWLIB))
+extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
+extra_configure_switches += '--with-bugurl=https://radix-linux.su'
+extra_configure_switches += --disable-werror
+extra_configure_switches += --enable-interwork
+extra_configure_switches += --enable-multilib
+extra_configure_switches += --with-abi=aapcs
+extra_configure_switches += --enable-plugins
+extra_configure_switches += --with-sysroot=$(TOOLCHAIN_PATH)/$(TARGET)
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A33XX_NEWLIB))
+extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
+extra_configure_switches += '--with-bugurl=https://radix-linux.su'
+extra_configure_switches += --disable-werror
+extra_configure_switches += --enable-interwork
+extra_configure_switches += --enable-multilib
+extra_configure_switches += --with-abi=aapcs
+extra_configure_switches += --enable-plugins
+extra_configure_switches += --with-sysroot=$(TOOLCHAIN_PATH)/$(TARGET)
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A9XX_NEWLIB))
+extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
+extra_configure_switches += '--with-bugurl=https://radix-linux.su'
+extra_configure_switches += --disable-werror
+extra_configure_switches += --enable-interwork
+extra_configure_switches += --enable-multilib
+extra_configure_switches += --with-abi=aapcs
+extra_configure_switches += --enable-plugins
+extra_configure_switches += --with-sysroot=$(TOOLCHAIN_PATH)/$(TARGET)
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_H5_NEWLIB))
+extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
+extra_configure_switches += '--with-bugurl=https://radix-linux.su'
+extra_configure_switches += --disable-multiarch
+extra_configure_switches += --enable-multilib
+extra_configure_switches += --with-cpu=cortex-a53
+extra_configure_switches += --with-arch=armv8-a
+extra_configure_switches += --enable-plugins
+extra_configure_switches += --with-sysroot=$(TOOLCHAIN_PATH)/$(TARGET)
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_S9XX_NEWLIB))
+extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
+extra_configure_switches += '--with-bugurl=https://radix-linux.su'
+extra_configure_switches += --disable-multiarch
+extra_configure_switches += --enable-multilib
+extra_configure_switches += --with-cpu=cortex-a53
+extra_configure_switches += --with-arch=armv8-a
+extra_configure_switches += --enable-plugins
+extra_configure_switches += --with-sysroot=$(TOOLCHAIN_PATH)/$(TARGET)
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_RK33XX_NEWLIB))
+extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
+extra_configure_switches += '--with-bugurl=https://radix-linux.su'
+extra_configure_switches += --disable-multiarch
+extra_configure_switches += --enable-multilib
+extra_configure_switches += --with-cpu=cortex-a53
+extra_configure_switches += --with-arch=armv8-a
+extra_configure_switches += --enable-plugins
+extra_configure_switches += --with-sysroot=$(TOOLCHAIN_PATH)/$(TARGET)
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_M1000_NEWLIB))
+extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
+extra_configure_switches += '--with-bugurl=https://radix-linux.su'
+extra_configure_switches += --disable-multiarch
+extra_configure_switches += --enable-multilib
+extra_configure_switches += --with-cpu=cortex-a57
+extra_configure_switches += --with-arch=armv8-a
+extra_configure_switches += --enable-plugins
+extra_configure_switches += --with-sysroot=$(TOOLCHAIN_PATH)/$(TARGET)
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_AT91SAM7S_NEWLIB))
+extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
+extra_configure_switches += '--with-bugurl=https://radix-linux.su'
+extra_configure_switches += --enable-interwork
+extra_configure_switches += --enable-multilib
+extra_configure_switches += --with-float=soft
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_RISCV64_NEWLIB))
+extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
+extra_configure_switches += '--with-bugurl=https://radix-linux.su'
+extra_configure_switches += --enable-multilib
+extra_configure_switches += --with-abi=lp64d
+extra_configure_switches += --with-arch=rv64imafdc
+extra_configure_switches += --enable-plugins
+extra_configure_switches += --with-sysroot=$(TOOLCHAIN_PATH)/$(TARGET)
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_A1X_GLIBC)),)
+extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
+extra_configure_switches += '--with-bugurl=https://radix-linux.su'
+# experimental gold linker( DEFAULT_LD=ld.bfd ):
+extra_configure_switches += --enable-gold=no
+extra_configure_switches += --enable-ld=default
+extra_configure_switches += --enable-werror=no
+# standard options:
+extra_configure_switches += --enable-interwork
+extra_configure_switches += --enable-multilib
+extra_configure_switches += --with-cpu=cortex-a8
+extra_configure_switches += --with-arch=armv7-a
+extra_configure_switches += --with-fpu=neon
+extra_configure_switches += --with-abi=aapcs-linux
+extra_configure_switches += --disable-compressed-debug-sections
+extra_configure_switches += --with-sysroot=$(sysroot_dir)
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_A2X_GLIBC)),)
+extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
+extra_configure_switches += '--with-bugurl=https://radix-linux.su'
+# experimental gold linker( DEFAULT_LD=ld.bfd ):
+extra_configure_switches += --enable-gold=no
+extra_configure_switches += --enable-ld=default
+extra_configure_switches += --enable-werror=no
+# standard options:
+extra_configure_switches += --enable-interwork
+extra_configure_switches += --enable-multilib
+extra_configure_switches += --with-cpu=cortex-a7
+extra_configure_switches += --with-arch=armv7ve
+extra_configure_switches += --with-fpu=neon-vfpv4
+extra_configure_switches += --with-abi=aapcs-linux
+extra_configure_switches += --disable-compressed-debug-sections
+extra_configure_switches += --with-sysroot=$(sysroot_dir)
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_H3_GLIBC)),)
+extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
+extra_configure_switches += '--with-bugurl=https://radix-linux.su'
+# experimental gold linker( DEFAULT_LD=ld.bfd ):
+extra_configure_switches += --enable-gold=no
+extra_configure_switches += --enable-ld=default
+extra_configure_switches += --enable-werror=no
+# standard options:
+extra_configure_switches += --enable-interwork
+extra_configure_switches += --enable-multilib
+extra_configure_switches += --with-arch=armv7ve
+extra_configure_switches += --with-tune=cortex-a7
+extra_configure_switches += --with-fpu=neon-vfpv4
+extra_configure_switches += --with-abi=aapcs-linux
+extra_configure_switches += --disable-compressed-debug-sections
+extra_configure_switches += --with-sysroot=$(sysroot_dir)
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_H5_GLIBC)),)
+extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
+extra_configure_switches += '--with-bugurl=https://radix-linux.su'
+# experimental gold linker( DEFAULT_LD=ld.bfd ):
+extra_configure_switches += --enable-gold=no
+extra_configure_switches += --enable-ld=default
+extra_configure_switches += --enable-werror=no
+# standard options:
+extra_configure_switches += --disable-multilib
+extra_configure_switches += --with-cpu=cortex-a53
+extra_configure_switches += --with-arch=armv8-a
+extra_configure_switches += --with-fpu=neon-fp-armv8
+extra_configure_switches += --with-abi=lp64
+extra_configure_switches += --disable-compressed-debug-sections
+extra_configure_switches += --with-sysroot=$(sysroot_dir)
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_S8XX_GLIBC)),)
+extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
+extra_configure_switches += '--with-bugurl=https://radix-linux.su'
+# experimental gold linker( DEFAULT_LD=ld.bfd ):
+extra_configure_switches += --enable-gold=no
+extra_configure_switches += --enable-ld=default
+extra_configure_switches += --enable-werror=no
+# standard options:
+extra_configure_switches += --enable-interwork
+extra_configure_switches += --enable-multilib
+extra_configure_switches += --with-cpu=cortex-a5
+extra_configure_switches += --with-arch=armv7-a
+extra_configure_switches += --with-fpu=neon
+extra_configure_switches += --with-abi=aapcs-linux
+extra_configure_switches += --disable-compressed-debug-sections
+extra_configure_switches += --with-sysroot=$(sysroot_dir)
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_S9XX_GLIBC)),)
+extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
+extra_configure_switches += '--with-bugurl=https://radix-linux.su'
+# experimental gold linker( DEFAULT_LD=ld.bfd ):
+extra_configure_switches += --enable-gold=no
+extra_configure_switches += --enable-ld=default
+extra_configure_switches += --enable-werror=no
+# standard options:
+extra_configure_switches += --disable-multilib
+extra_configure_switches += --with-cpu=cortex-a53
+extra_configure_switches += --with-arch=armv8-a
+extra_configure_switches += --with-fpu=neon-fp-armv8
+extra_configure_switches += --with-abi=lp64
+extra_configure_switches += --disable-compressed-debug-sections
+extra_configure_switches += --with-sysroot=$(sysroot_dir)
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_A9XX_GLIBC)),)
+extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
+extra_configure_switches += '--with-bugurl=https://radix-linux.su'
+# experimental gold linker( DEFAULT_LD=ld.bfd ):
+extra_configure_switches += --enable-gold=no
+extra_configure_switches += --enable-ld=default
+extra_configure_switches += --enable-werror=no
+# standard options:
+extra_configure_switches += --disable-multilib
+extra_configure_switches += --with-cpu=cortex-a53
+extra_configure_switches += --with-arch=armv8-a
+extra_configure_switches += --with-fpu=neon-fp-armv8
+extra_configure_switches += --disable-compressed-debug-sections
+extra_configure_switches += --with-sysroot=$(sysroot_dir)
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_A311X_GLIBC)),)
+extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
+extra_configure_switches += '--with-bugurl=https://radix-linux.su'
+# experimental gold linker( DEFAULT_LD=ld.bfd ):
+extra_configure_switches += --enable-gold=no
+extra_configure_switches += --enable-ld=default
+extra_configure_switches += --enable-werror=no
+# standard options:
+extra_configure_switches += --disable-multilib
+extra_configure_switches += --with-cpu=cortex-a53
+extra_configure_switches += --with-arch=armv8-a
+extra_configure_switches += --with-fpu=neon-fp-armv8
+extra_configure_switches += --with-abi=lp64
+extra_configure_switches += --disable-compressed-debug-sections
+extra_configure_switches += --with-sysroot=$(sysroot_dir)
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_RK33XX_GLIBC)),)
+extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
+extra_configure_switches += '--with-bugurl=https://radix-linux.su'
+# experimental gold linker( DEFAULT_LD=ld.bfd ):
+extra_configure_switches += --enable-gold=no
+extra_configure_switches += --enable-ld=default
+extra_configure_switches += --enable-werror=no
+# standard options:
+extra_configure_switches += --disable-multilib
+extra_configure_switches += --with-cpu=cortex-a53
+extra_configure_switches += --with-arch=armv8-a
+extra_configure_switches += --with-fpu=neon-fp-armv8
+extra_configure_switches += --with-abi=lp64
+extra_configure_switches += --with-sysroot=$(sysroot_dir)
+extra_configure_switches += --disable-compressed-debug-sections
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_RK339X_GLIBC)),)
+extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
+extra_configure_switches += '--with-bugurl=https://radix-linux.su'
+# experimental gold linker( DEFAULT_LD=ld.bfd ):
+extra_configure_switches += --enable-gold=no
+extra_configure_switches += --enable-ld=default
+extra_configure_switches += --enable-werror=no
+# standard options:
+extra_configure_switches += --disable-multilib
+extra_configure_switches += --with-cpu=cortex-a53
+extra_configure_switches += --with-arch=armv8-a
+extra_configure_switches += --with-fpu=neon-fp-armv8
+extra_configure_switches += --with-abi=lp64
+extra_configure_switches += --disable-compressed-debug-sections
+extra_configure_switches += --with-sysroot=$(sysroot_dir)
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_RK358X_GLIBC)),)
+extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
+extra_configure_switches += '--with-bugurl=https://radix-linux.su'
+# experimental gold linker( DEFAULT_LD=ld.bfd ):
+extra_configure_switches += --enable-gold=no
+extra_configure_switches += --enable-ld=default
+extra_configure_switches += --enable-werror=no
+# standard options:
+extra_configure_switches += --disable-multilib
+extra_configure_switches += --with-cpu=cortex-a75
+extra_configure_switches += --with-arch=armv8.2-a
+extra_configure_switches += --with-fpu=neon-fp-armv8
+extra_configure_switches += --with-abi=lp64
+extra_configure_switches += --disable-compressed-debug-sections
+extra_configure_switches += --with-sysroot=$(sysroot_dir)
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_A33XX_GLIBC)),)
+extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
+extra_configure_switches += '--with-bugurl=https://radix-linux.su'
+# experimental gold linker( DEFAULT_LD=ld.bfd ):
+extra_configure_switches += --enable-gold=no
+extra_configure_switches += --enable-ld=default
+extra_configure_switches += --enable-werror=no
+# standard options:
+extra_configure_switches += --disable-multilib
+extra_configure_switches += --with-cpu=cortex-a53
+extra_configure_switches += --with-arch=armv8-a
+extra_configure_switches += --with-fpu=neon-fp-armv8
+extra_configure_switches += --disable-compressed-debug-sections
+extra_configure_switches += --with-sysroot=$(sysroot_dir)
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_RK328X_GLIBC)),)
+extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
+extra_configure_switches += '--with-bugurl=https://radix-linux.su'
+# experimental gold linker( DEFAULT_LD=ld.bfd ):
+extra_configure_switches += --enable-gold=no
+extra_configure_switches += --enable-ld=default
+extra_configure_switches += --enable-werror=no
+extra_configure_switches += --enable-plugins
+# standard options:
+extra_configure_switches += --enable-interwork
+extra_configure_switches += --enable-multilib
+extra_configure_switches += --with-cpu=cortex-a17
+extra_configure_switches += --with-arch=armv7ve
+extra_configure_switches += --with-fpu=neon-vfpv4
+extra_configure_switches += --with-abi=aapcs-linux
+extra_configure_switches += --disable-compressed-debug-sections
+extra_configure_switches += --with-sysroot=$(sysroot_dir)
+endif
+
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_IMX6_GLIBC)),)
+extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
+extra_configure_switches += '--with-bugurl=https://radix-linux.su'
+# experimental gold linker( DEFAULT_LD=ld.bfd ):
+extra_configure_switches += --enable-gold=no
+extra_configure_switches += --enable-ld=default
+extra_configure_switches += --enable-werror=no
+# standard options:
+extra_configure_switches += --enable-interwork
+extra_configure_switches += --enable-multilib
+extra_configure_switches += --with-arch=armv7-a
+extra_configure_switches += --with-tune=cortex-a9
+extra_configure_switches += --with-fpu=vfpv3
+extra_configure_switches += --with-abi=aapcs-linux
+extra_configure_switches += --disable-compressed-debug-sections
+extra_configure_switches += --with-sysroot=$(sysroot_dir)
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_IMX6ULL_GLIBC)),)
+extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
+extra_configure_switches += '--with-bugurl=https://radix-linux.su'
+# experimental gold linker( DEFAULT_LD=ld.bfd ):
+extra_configure_switches += --enable-gold=no
+extra_configure_switches += --enable-ld=default
+extra_configure_switches += --enable-werror=no
+# standard options:
+extra_configure_switches += --enable-interwork
+extra_configure_switches += --enable-multilib
+extra_configure_switches += --with-arch=armv7-a
+extra_configure_switches += --with-cpu=cortex-a7
+extra_configure_switches += --with-fpu=neon-vfpv4
+extra_configure_switches += --with-abi=aapcs-linux
+extra_configure_switches += --disable-compressed-debug-sections
+extra_configure_switches += --with-sysroot=$(sysroot_dir)
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_OMAP543X_GLIBC)),)
+extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
+extra_configure_switches += '--with-bugurl=https://radix-linux.su'
+# experimental gold linker( DEFAULT_LD=ld.bfd ):
+extra_configure_switches += --enable-gold=no
+extra_configure_switches += --enable-ld=default
+extra_configure_switches += --enable-werror=no
+# standard options:
+extra_configure_switches += --enable-interwork
+extra_configure_switches += --enable-multilib
+extra_configure_switches += --with-arch=armv7ve
+extra_configure_switches += --with-tune=cortex-a15
+extra_configure_switches += --with-fpu=neon-vfpv4
+extra_configure_switches += --with-abi=aapcs-linux
+extra_configure_switches += --disable-compressed-debug-sections
+extra_configure_switches += --with-sysroot=$(sysroot_dir)
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_AM335X_GLIBC)),)
+extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
+extra_configure_switches += '--with-bugurl=https://radix-linux.su'
+# experimental gold linker( DEFAULT_LD=ld.bfd ):
+extra_configure_switches += --enable-gold=no
+extra_configure_switches += --enable-ld=default
+extra_configure_switches += --enable-werror=no
+# standard options:
+extra_configure_switches += --enable-interwork
+extra_configure_switches += --enable-multilib
+extra_configure_switches += --with-arch=armv7-a
+extra_configure_switches += --with-tune=cortex-a8
+extra_configure_switches += --with-fpu=neon
+extra_configure_switches += --with-abi=aapcs-linux
+extra_configure_switches += --disable-compressed-debug-sections
+extra_configure_switches += --with-sysroot=$(sysroot_dir)
+endif
+
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_JZ47XX_GLIBC)),)
+extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
+extra_configure_switches += '--with-bugurl=https://radix-linux.su'
+# experimental gold linker( DEFAULT_LD=ld.bfd ):
+extra_configure_switches += --enable-gold=no
+extra_configure_switches += --enable-ld=default
+extra_configure_switches += --enable-werror=no
+# standard options:
+extra_configure_switches += --enable-multilib
+extra_configure_switches += --with-arch=mips32r2
+extra_configure_switches += --enable-plugins
+extra_configure_switches += --disable-compressed-debug-sections
+extra_configure_switches += --with-sysroot=$(sysroot_dir)
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_P5600_GLIBC)),)
+extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
+extra_configure_switches += '--with-bugurl=https://radix-linux.su'
+# experimental gold linker( DEFAULT_LD=ld.bfd ):
+extra_configure_switches += --enable-gold=no
+extra_configure_switches += --enable-ld=default
+extra_configure_switches += --enable-werror=no
+# standard options:
+extra_configure_switches += --enable-multilib
+extra_configure_switches += --with-arch=mips32r5
+extra_configure_switches += --enable-plugins
+extra_configure_switches += --disable-compressed-debug-sections
+extra_configure_switches += --with-sysroot=$(sysroot_dir)
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_M1000_GLIBC)),)
+extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
+extra_configure_switches += '--with-bugurl=https://radix-linux.su'
+# experimental gold linker( DEFAULT_LD=ld.bfd ):
+extra_configure_switches += --enable-gold=no
+extra_configure_switches += --enable-ld=default
+extra_configure_switches += --enable-werror=no
+# standard options:
+extra_configure_switches += --disable-multilib
+extra_configure_switches += --with-cpu=cortex-a57
+extra_configure_switches += --with-arch=armv8-a
+extra_configure_switches += --with-fpu=neon-fp-armv8
+extra_configure_switches += --with-abi=lp64
+extra_configure_switches += --disable-compressed-debug-sections
+extra_configure_switches += --with-sysroot=$(sysroot_dir)
+endif
+
+
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_PPC8_GLIBC)),)
+extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
+extra_configure_switches += '--with-bugurl=https://radix-linux.su'
+# experimental gold linker( DEFAULT_LD=ld.bfd ):
+extra_configure_switches += --enable-gold=no
+extra_configure_switches += --enable-ld=default
+extra_configure_switches += --enable-werror=no
+# standard options:
+extra_configure_switches += --disable-multilib
+extra_configure_switches += --enable-plugins
+extra_configure_switches += --enable-targets=ppc-radix-linux,ppc-linux,powerpc-radix-linux,powerpc-linux
+extra_configure_switches += --enable-64-bit-bfd
+extra_configure_switches += --disable-compressed-debug-sections
+extra_configure_switches += --with-sysroot=$(sysroot_dir)
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_PPC9_GLIBC)),)
+extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
+extra_configure_switches += '--with-bugurl=https://radix-linux.su'
+# experimental gold linker( DEFAULT_LD=ld.bfd ):
+extra_configure_switches += --enable-gold=no
+extra_configure_switches += --enable-ld=default
+extra_configure_switches += --enable-werror=no
+# standard options:
+extra_configure_switches += --disable-multilib
+extra_configure_switches += --enable-plugins
+extra_configure_switches += --enable-targets=ppc-radix-linux,ppc-linux,powerpc-radix-linux,powerpc-linux
+extra_configure_switches += --enable-64-bit-bfd
+extra_configure_switches += --disable-compressed-debug-sections
+extra_configure_switches += --with-sysroot=$(sysroot_dir)
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_POWER8_GLIBC)),)
+extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
+extra_configure_switches += '--with-bugurl=https://radix-linux.su'
+# experimental gold linker( DEFAULT_LD=ld.bfd ):
+extra_configure_switches += --enable-gold=no
+extra_configure_switches += --enable-ld=default
+extra_configure_switches += --enable-werror=no
+# standard options:
+extra_configure_switches += --enable-multilib
+extra_configure_switches += --enable-plugins
+extra_configure_switches += --enable-targets=ppc64-radix-linux,powerpc64-radix-linux,ppc64-linux,powerpc64-linux,ppc-radix-linux,powerpc-radix-linux,ppc-linux,powerpc-linux
+extra_configure_switches += --enable-64-bit-bfd
+extra_configure_switches += --disable-compressed-debug-sections
+extra_configure_switches += --with-sysroot=$(sysroot_dir)
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_POWER9_GLIBC)),)
+extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
+extra_configure_switches += '--with-bugurl=https://radix-linux.su'
+# experimental gold linker( DEFAULT_LD=ld.bfd ):
+extra_configure_switches += --enable-gold=no
+extra_configure_switches += --enable-ld=default
+extra_configure_switches += --enable-werror=no
+# standard options:
+extra_configure_switches += --enable-multilib
+extra_configure_switches += --enable-plugins
+extra_configure_switches += --enable-targets=ppc64-radix-linux,powerpc64-radix-linux,ppc64-linux,powerpc64-linux,ppc-radix-linux,powerpc-radix-linux,ppc-linux,powerpc-linux
+extra_configure_switches += --enable-64-bit-bfd
+extra_configure_switches += --disable-compressed-debug-sections
+extra_configure_switches += --with-sysroot=$(sysroot_dir)
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_POWER8LE_GLIBC)),)
+extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
+extra_configure_switches += '--with-bugurl=https://radix-linux.su'
+# experimental gold linker( DEFAULT_LD=ld.bfd ):
+extra_configure_switches += --enable-gold=no
+extra_configure_switches += --enable-ld=default
+extra_configure_switches += --enable-werror=no
+# standard options:
+extra_configure_switches += --disable-multilib
+extra_configure_switches += --enable-plugins
+extra_configure_switches += --enable-targets=ppc64le-radix-linux,powerpc64le-radix-linux,ppc64le-linux,powerpc64le-linux,ppcle-radix-linux,powerpcle-radix-linux,ppcle-linux,powerpcle-linux
+extra_configure_switches += --enable-64-bit-bfd
+extra_configure_switches += --disable-compressed-debug-sections
+extra_configure_switches += --with-sysroot=$(sysroot_dir)
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_POWER9LE_GLIBC)),)
+extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
+extra_configure_switches += '--with-bugurl=https://radix-linux.su'
+# experimental gold linker( DEFAULT_LD=ld.bfd ):
+extra_configure_switches += --enable-gold=no
+extra_configure_switches += --enable-ld=default
+extra_configure_switches += --enable-werror=no
+# standard options:
+extra_configure_switches += --disable-multilib
+extra_configure_switches += --enable-plugins
+extra_configure_switches += --enable-targets=ppc64le-radix-linux,powerpc64le-radix-linux,ppc64le-linux,powerpc64le-linux,ppcle-radix-linux,powerpcle-radix-linux,ppcle-linux,powerpcle-linux
+extra_configure_switches += --enable-64-bit-bfd
+extra_configure_switches += --disable-compressed-debug-sections
+extra_configure_switches += --with-sysroot=$(sysroot_dir)
+endif
+
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_RISCV64_GLIBC))
+extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
+extra_configure_switches += '--with-bugurl=https://radix-linux.su'
+# experimental gold linker( DEFAULT_LD=ld.bfd ):
+extra_configure_switches += --enable-gold=no
+extra_configure_switches += --enable-ld=default
+# standard options:
+extra_configure_switches += --enable-targets=riscv64-radix-linux,riscv64-linux
+extra_configure_switches += --disable-multilib
+extra_configure_switches += --with-abi=lp64d
+extra_configure_switches += --with-arch=rv64imafdc
+extra_configure_switches += --enable-64-bit-bfd
+extra_configure_switches += --enable-plugins
+extra_configure_switches += --enable-threads
+extra_configure_switches += --disable-compressed-debug-sections
+extra_configure_switches += --with-sysroot=$(TOOLCHAIN_PATH)/$(TARGET)
+endif
+
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_I586_GLIBC)),)
+extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
+extra_configure_switches += '--with-bugurl=https://radix-linux.su'
+# experimental gold linker( DEFAULT_LD=ld.bfd ):
+extra_configure_switches += --enable-gold=no
+extra_configure_switches += --enable-ld=default
+extra_configure_switches += --enable-werror=no
+# standard options:
+extra_configure_switches += --enable-targets=i586-radix-linux
+extra_configure_switches += --disable-multilib
+extra_configure_switches += --enable-initfini-array
+extra_configure_switches += --enable-plugins
+extra_configure_switches += --enable-threads
+extra_configure_switches += --disable-compressed-debug-sections
+extra_configure_switches += --with-sysroot=$(sysroot_dir)
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_I686_GLIBC)),)
+extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
+extra_configure_switches += '--with-bugurl=https://radix-linux.su'
+# experimental gold linker( DEFAULT_LD=ld.bfd ):
+extra_configure_switches += --enable-gold=no
+extra_configure_switches += --enable-ld=default
+extra_configure_switches += --enable-werror=no
+# standard options:
+extra_configure_switches += --enable-targets=i686-radix-linux
+extra_configure_switches += --disable-multilib
+extra_configure_switches += --enable-initfini-array
+extra_configure_switches += --enable-plugins
+extra_configure_switches += --enable-threads
+extra_configure_switches += --disable-compressed-debug-sections
+extra_configure_switches += --with-sysroot=$(sysroot_dir)
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_X86_64_GLIBC)),)
+extra_configure_switches = '--with-pkgversion=Radix $(TOOLCHAINS_VERSION)'
+extra_configure_switches += '--with-bugurl=https://radix-linux.su'
+# experimental gold linker( DEFAULT_LD=ld.bfd ):
+extra_configure_switches += --enable-gold=no
+extra_configure_switches += --enable-ld=default
+extra_configure_switches += --enable-werror=no
+# standard options:
+extra_configure_switches += --enable-targets=x86_64-radix-linux
+extra_configure_switches += --enable-multilib
+extra_configure_switches += --enable-64-bit-bfd
+extra_configure_switches += --enable-initfini-array
+extra_configure_switches += --enable-plugins
+extra_configure_switches += --enable-threads
+extra_configure_switches += --disable-compressed-debug-sections
+extra_configure_switches += --with-sysroot=$(sysroot_dir)
+endif
+
+
+
+$(src_done): $(SRC_ARCHIVE) $(PATCHES_DEP)
+ $(UNPACK_SRC_ARCHIVE)
+ $(APPLY_PATCHES)
+ # ======= These pages were shipped empty and will need to be regenerated =======
+ @( cd $(SRC_DIR) ; \
+ rm -f binutils/doc/*.1 binutils/doc/*.man gprof/gprof.1 ld/ld.1 gas/doc/as.1 ; \
+ )
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_POWER8_GLIBC) $(TOOLCHAIN_POWER9_GLIBC)),)
+ # ======= On ppc64 and aarch64, we might use 64KiB pages =======
+ @( cd $(SRC_DIR) ; \
+ sed -i -e '/#define.*ELF_COMMONPAGESIZE/s/0x1000$$/0x10000/' bfd/elf*ppc.c ; \
+ sed -i -e '/common_pagesize/s/4 /64 /' gold/powerpc.cc ; \
+ )
+endif
+ @touch $@
+
+$(build_target): $(src_done)
+ @mkdir -p $(build_dir)
+ @cd $(build_dir) && ../$(src_dir_name)/configure \
+ --prefix=$(TOOLCHAIN_PATH) \
+ --target=$(TARGET) \
+ --infodir=$(TOOLCHAIN_PATH)/share/info \
+ --mandir=$(TOOLCHAIN_PATH)/share/man \
+ --disable-nls \
+ $(extra_configure_switches)
+ @$(MAKE) -C $(build_dir)
+ @$(MAKE) -C $(build_dir) info
+ @touch $@
+
+$(install_target): $(build_target)
+ @mkdir -p $(install_dir)
+ @$(MAKE) -j1 -C $(build_dir) install
+ @$(MAKE) -j1 -C $(build_dir) install-info
+ @rm -f $(TOOLCHAIN_PATH)/share/info/dir
+ @rm -f $(TOOLCHAIN_PATH)/bin/gp-{archive,collect-app,display-html,display-src,display-text}
+ @echo "" > $(TOOLCHAIN_PATH)/README
+ @echo " TOOLCHAIN = $(TOOLCHAIN)" >> $(TOOLCHAIN_PATH)/README
+ @echo " TARGET = $(TARGET)" >> $(TOOLCHAIN_PATH)/README
+ @echo " BASE_PATH = $(TOOLCHAINS_BASE_PATH)" >> $(TOOLCHAIN_PATH)/README
+ @echo " DIRECTORY = $(TOOLCHAIN_DIR)" >> $(TOOLCHAIN_PATH)/README
+ @echo " VERSION = $(TOOLCHAIN_VERSION)" >> $(TOOLCHAIN_PATH)/README
+ @echo "" >> $(TOOLCHAIN_PATH)/README
+ @echo "-----------" >> $(TOOLCHAIN_PATH)/README
+ @echo "" >> $(TOOLCHAIN_PATH)/README
+ @echo " $(subst $(TOP_BUILD_DIR_ABS)/,,$(CURDIR))$(if $(FLAVOUR),:$(FLAVOUR),)" >> $(TOOLCHAIN_PATH)/README
+ @touch $@
Index: core/binutils/2.44/PATCHES
===================================================================
--- core/binutils/2.44/PATCHES (nonexistent)
+++ core/binutils/2.44/PATCHES (revision 76)
@@ -0,0 +1,9 @@
+
+../../../sources/GNU/binutils/patches/binutils-2.44-ldforcele.patch -p0
+../../../sources/GNU/binutils/patches/binutils-2.44-libtool-lib64.patch -p0
+../../../sources/GNU/binutils/patches/binutils-2.44-export-demangle.patch -p0
+../../../sources/GNU/binutils/patches/binutils-2.44-no-config-check.patch -p0
+
+../../../sources/GNU/binutils/patches/binutils-2.44-aarch64-ifunc.patch -p0
+../../../sources/GNU/binutils/patches/binutils-2.44-not-link-static-libstdc++.patch -p0
+../../../sources/GNU/binutils/patches/binutils-2.44-readelf-other-sym-info.patch -p0
Index: core/binutils/2.44
===================================================================
--- core/binutils/2.44 (nonexistent)
+++ core/binutils/2.44 (revision 76)
Property changes on: core/binutils/2.44
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,81 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.rk358x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: core/crypt/4.4.36-ppc32/Makefile
===================================================================
--- core/crypt/4.4.36-ppc32/Makefile (revision 75)
+++ core/crypt/4.4.36-ppc32/Makefile (nonexistent)
@@ -1,148 +0,0 @@
-
-
-COMPONENT_TARGETS = $(TOOLCHAIN_POWER8_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_POWER9_GLIBC)
-
-
-FLAVOURS = compat next
-
-include ../../../build-system/config.mk
-
-SOURCE_REQUIRES = sources/crypt
-
-ifeq ($(FLAVOUR),compat)
-REQUIRES = core/glibc/2.40-ppc32^full
-endif
-ifeq ($(FLAVOUR),next)
-REQUIRES = core/crypt/4.4.36-ppc32^compat
-endif
-
-# ======= __END_OF_REQUIRES__ =======
-
-tar_xz_archive = $(SRC_PACKAGE_PATH)/crypt/libxcrypt/libxcrypt-4.4.36.tar.xz
-SRC_ARCHIVE = $(tar_xz_archive)
-SRC_DIR = $(TARGET_BUILD_DIR)/libxcrypt-4.4.36
-src_dir_name = libxcrypt-4.4.36
-src_done = $(TARGET_BUILD_DIR)/.source-done
-
-PATCHES = PATCHES
-
-build_compat_dir = $(TARGET_BUILD_DIR)/build-compat
-build_next_dir = $(TARGET_BUILD_DIR)/build-next
-
-sysroot_dir = $(TOOLCHAIN_PATH)/$(TARGET)/sys-root
-
-build_compat_target = $(TARGET_BUILD_DIR)/.compat-built
-compat_target = $(TARGET_BUILD_DIR)/.compat-installed
-
-build_next_target = $(TARGET_BUILD_DIR)/.next-built
-next_target = $(TARGET_BUILD_DIR)/.next-installed
-
-
-ifeq ($(FLAVOUR),compat)
-BUILD_TARGETS = $(build_compat_target)
-BUILD_TARGETS += $(compat_target)
-endif
-
-ifeq ($(FLAVOUR),next)
-BUILD_TARGETS = $(build_next_target)
-BUILD_TARGETS += $(next_target)
-endif
-
-include ../../../build-system/core.mk
-
-
-env_sysroot = DESTDIR=$(sysroot_dir)
-
-
-CC = $(CCACHE)$(TOOLCHAIN_PATH)/bin/$(TARGET)-gcc -m32
-CXX = $(CCACHE)$(TOOLCHAIN_PATH)/bin/$(TARGET)-g++ -m32
-
-environment = AS=$(TOOLCHAIN_PATH)/bin/$(TARGET)-as
-environment += LD=$(TOOLCHAIN_PATH)/bin/$(TARGET)-ld
-environment += CC="$(CC)"
-environment += CXX="$(CXX)"
-environment += AR=$(TOOLCHAIN_PATH)/bin/$(TARGET)-ar
-environment += RANLIB=$(TOOLCHAIN_PATH)/bin/$(TARGET)-ranlib
-
-environment += PATH=$(TOOLCHAIN_PATH)/bin:$(PATH)
-
-LIBSUFFIX =
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_POWER8_GLIBC))
-environment += CFLAGS="-g -O3 -mcpu=power8 -mlong-double-128"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_POWER9_GLIBC))
-environment += CFLAGS="-g -O3 -mcpu=power9 -mlong-double-128"
-endif
-
-LIBSUFFIX = 32
-
-TARGET32 = $(shell echo $(TARGET) | sed 's/ppc64/ppc/')
-
-
-extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
-extra_configure_switches += --mandir=/usr/share/man
-ifeq ($(FLAVOUR),compat)
-extra_configure_switches += --enable-hashes=strong,glibc
-extra_configure_switches += --enable-obsolete-api=glibc
-extra_configure_switches += --disable-feature-tokens
-endif
-ifeq ($(FLAVOUR),next)
-extra_configure_switches += --enable-hashes=strong,glibc
-extra_configure_switches += --enable-obsolete-api=no
-extra_configure_switches += --disable-feature-tokens
-extra_configure_switches += --enable-static=no
-endif
-
-
-
-$(src_done): $(SRC_ARCHIVE) $(PATCHES_DEP)
- $(UNPACK_SRC_ARCHIVE)
- $(APPLY_PATCHES)
- @touch $@
-
-$(build_compat_target): $(src_done)
- @mkdir -p $(build_compat_dir)
- @cd $(build_compat_dir) && $(env_sysroot) $(environment) ../$(src_dir_name)/configure \
- --prefix=/usr \
- --build=$(BUILD) \
- --host=$(TARGET32) \
- $(extra_configure_switches)
- @cd $(build_compat_dir) && $(environment) $(MAKE) all
- @touch $@
-
-$(build_next_target): $(src_done)
- @mkdir -p $(build_next_dir)
- @cd $(build_next_dir) && $(env_sysroot) $(environment) ../$(src_dir_name)/configure \
- --prefix=/usr \
- --build=$(BUILD) \
- --host=$(TARGET32) \
- $(extra_configure_switches)
- @cd $(build_next_dir) && $(environment) $(MAKE) all
- @touch $@
-
-$(compat_target): $(build_compat_target)
- @mkdir -p $(sysroot_dir)/{,usr/}lib$(LIBSUFFIX)
- @cd $(build_compat_dir) && $(environment) $(MAKE) -j1 install $(env_sysroot)
- @( cd $(sysroot_dir)/usr/lib$(LIBSUFFIX) ; \
- rm -f *.la ; \
- rm libcrypt.so ; \
- mv libcrypt.so* ../../lib$(LIBSUFFIX) ; \
- ln -sf ../../lib$(LIBSUFFIX)/libcrypt.so.1 libcrypt.so ; \
- )
- @echo " $(subst $(TOP_BUILD_DIR_ABS)/,,$(CURDIR))$(if $(FLAVOUR),:$(FLAVOUR),)" >> $(TOOLCHAIN_PATH)/README
- @touch $@
-
-$(next_target): $(build_next_target)
- @mkdir -p $(sysroot_dir)/{,usr/}lib$(LIBSUFFIX)
- @cd $(build_next_dir) && $(environment) $(MAKE) -j1 install $(env_sysroot)
- @( cd $(sysroot_dir)/usr/lib$(LIBSUFFIX) ; \
- rm -f *.la ; \
- rm libcrypt.so ; \
- mv libcrypt.so* ../../lib$(LIBSUFFIX) ; \
- ln -sf ../../lib$(LIBSUFFIX)/libcrypt.so.2 libcrypt.so ; \
- )
- @echo " $(subst $(TOP_BUILD_DIR_ABS)/,,$(CURDIR))$(if $(FLAVOUR),:$(FLAVOUR),)" >> $(TOOLCHAIN_PATH)/README
- @touch $@
Index: core/crypt/4.4.36-ppc32
===================================================================
--- core/crypt/4.4.36-ppc32 (revision 75)
+++ core/crypt/4.4.36-ppc32 (nonexistent)
Property changes on: core/crypt/4.4.36-ppc32
___________________________________________________________________
Deleted: svn:ignore
## -1,81 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.rk358x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: core/crypt/4.4.36-x86_32/Makefile
===================================================================
--- core/crypt/4.4.36-x86_32/Makefile (revision 75)
+++ core/crypt/4.4.36-x86_32/Makefile (nonexistent)
@@ -1,142 +0,0 @@
-
-
-COMPONENT_TARGETS = $(TOOLCHAIN_X86_64_GLIBC)
-
-
-FLAVOURS = compat next
-
-include ../../../build-system/config.mk
-
-SOURCE_REQUIRES = sources/crypt
-
-ifeq ($(FLAVOUR),compat)
-REQUIRES = core/glibc/2.40-x86_32^full
-endif
-ifeq ($(FLAVOUR),next)
-REQUIRES = core/crypt/4.4.36-x86_32^compat
-endif
-
-# ======= __END_OF_REQUIRES__ =======
-
-tar_xz_archive = $(SRC_PACKAGE_PATH)/crypt/libxcrypt/libxcrypt-4.4.36.tar.xz
-SRC_ARCHIVE = $(tar_xz_archive)
-SRC_DIR = $(TARGET_BUILD_DIR)/libxcrypt-4.4.36
-src_dir_name = libxcrypt-4.4.36
-src_done = $(TARGET_BUILD_DIR)/.source-done
-
-PATCHES = PATCHES
-
-build_compat_dir = $(TARGET_BUILD_DIR)/build-compat
-build_next_dir = $(TARGET_BUILD_DIR)/build-next
-
-sysroot_dir = $(TOOLCHAIN_PATH)/$(TARGET)/sys-root
-
-build_compat_target = $(TARGET_BUILD_DIR)/.compat-built
-compat_target = $(TARGET_BUILD_DIR)/.compat-installed
-
-build_next_target = $(TARGET_BUILD_DIR)/.next-built
-next_target = $(TARGET_BUILD_DIR)/.next-installed
-
-
-ifeq ($(FLAVOUR),compat)
-BUILD_TARGETS = $(build_compat_target)
-BUILD_TARGETS += $(compat_target)
-endif
-
-ifeq ($(FLAVOUR),next)
-BUILD_TARGETS = $(build_next_target)
-BUILD_TARGETS += $(next_target)
-endif
-
-include ../../../build-system/core.mk
-
-
-env_sysroot = DESTDIR=$(sysroot_dir)
-
-
-CC = $(CCACHE)$(TOOLCHAIN_PATH)/bin/$(TARGET)-gcc -m32
-CXX = $(CCACHE)$(TOOLCHAIN_PATH)/bin/$(TARGET)-g++ -m32
-
-environment = AS=$(TOOLCHAIN_PATH)/bin/$(TARGET)-as
-environment += LD=$(TOOLCHAIN_PATH)/bin/$(TARGET)-ld
-environment += CC="$(CC)"
-environment += CXX="$(CXX)"
-environment += AR=$(TOOLCHAIN_PATH)/bin/$(TARGET)-ar
-environment += RANLIB=$(TOOLCHAIN_PATH)/bin/$(TARGET)-ranlib
-
-environment += PATH=$(TOOLCHAIN_PATH)/bin:$(PATH)
-
-LIBSUFFIX =
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_X86_64_GLIBC))
-environment += CFLAGS="-g -O3 -march=i686 -mtune=i686"
-LIBSUFFIX = 32
-endif
-
-TARGET32 = $(shell echo $(TARGET) | sed 's/x86_64/i686/')
-
-
-extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
-extra_configure_switches += --mandir=/usr/share/man
-ifeq ($(FLAVOUR),compat)
-extra_configure_switches += --enable-hashes=strong,glibc
-extra_configure_switches += --enable-obsolete-api=glibc
-extra_configure_switches += --disable-feature-tokens
-endif
-ifeq ($(FLAVOUR),next)
-extra_configure_switches += --enable-hashes=strong,glibc
-extra_configure_switches += --enable-obsolete-api=no
-extra_configure_switches += --disable-feature-tokens
-extra_configure_switches += --enable-static=no
-endif
-
-
-
-$(src_done): $(SRC_ARCHIVE) $(PATCHES_DEP)
- $(UNPACK_SRC_ARCHIVE)
- $(APPLY_PATCHES)
- @touch $@
-
-$(build_compat_target): $(src_done)
- @mkdir -p $(build_compat_dir)
- @cd $(build_compat_dir) && $(env_sysroot) $(environment) ../$(src_dir_name)/configure \
- --prefix=/usr \
- --build=$(BUILD) \
- --host=$(TARGET32) \
- $(extra_configure_switches)
- @cd $(build_compat_dir) && $(environment) $(MAKE) all
- @touch $@
-
-$(build_next_target): $(src_done)
- @mkdir -p $(build_next_dir)
- @cd $(build_next_dir) && $(env_sysroot) $(environment) ../$(src_dir_name)/configure \
- --prefix=/usr \
- --build=$(BUILD) \
- --host=$(TARGET32) \
- $(extra_configure_switches)
- @cd $(build_next_dir) && $(environment) $(MAKE) all
- @touch $@
-
-$(compat_target): $(build_compat_target)
- @mkdir -p $(sysroot_dir)/{,usr/}lib$(LIBSUFFIX)
- @cd $(build_compat_dir) && $(environment) $(MAKE) -j1 install $(env_sysroot)
- @( cd $(sysroot_dir)/usr/lib$(LIBSUFFIX) ; \
- rm -f *.la ; \
- rm libcrypt.so ; \
- mv libcrypt.so* ../../lib$(LIBSUFFIX) ; \
- ln -sf ../../lib$(LIBSUFFIX)/libcrypt.so.1 libcrypt.so ; \
- )
- @echo " $(subst $(TOP_BUILD_DIR_ABS)/,,$(CURDIR))$(if $(FLAVOUR),:$(FLAVOUR),)" >> $(TOOLCHAIN_PATH)/README
- @touch $@
-
-$(next_target): $(build_next_target)
- @mkdir -p $(sysroot_dir)/{,usr/}lib$(LIBSUFFIX)
- @cd $(build_next_dir) && $(environment) $(MAKE) -j1 install $(env_sysroot)
- @( cd $(sysroot_dir)/usr/lib$(LIBSUFFIX) ; \
- rm -f *.la ; \
- rm libcrypt.so ; \
- mv libcrypt.so* ../../lib$(LIBSUFFIX) ; \
- ln -sf ../../lib$(LIBSUFFIX)/libcrypt.so.2 libcrypt.so ; \
- )
- @echo " $(subst $(TOP_BUILD_DIR_ABS)/,,$(CURDIR))$(if $(FLAVOUR),:$(FLAVOUR),)" >> $(TOOLCHAIN_PATH)/README
- @touch $@
Index: core/crypt/4.4.36-x86_32
===================================================================
--- core/crypt/4.4.36-x86_32 (revision 75)
+++ core/crypt/4.4.36-x86_32 (nonexistent)
Property changes on: core/crypt/4.4.36-x86_32
___________________________________________________________________
Deleted: svn:ignore
## -1,81 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.rk358x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: core/crypt/4.4.36/Makefile
===================================================================
--- core/crypt/4.4.36/Makefile (revision 75)
+++ core/crypt/4.4.36/Makefile (nonexistent)
@@ -1,306 +0,0 @@
-
-
-COMPONENT_TARGETS = $(TOOLCHAIN_A1X_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_A2X_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_H3_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_H5_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_IMX6_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_IMX6ULL_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_JZ47XX_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_P5600_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_M1000_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_OMAP543X_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_AM335X_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_RK328X_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_S8XX_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_S9XX_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_A9XX_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_A311X_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_RK33XX_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_RK339X_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_RK358X_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_A33XX_GLIBC)
-
-COMPONENT_TARGETS += $(TOOLCHAIN_PPC8_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_PPC9_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_POWER8_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_POWER9_GLIBC)
-
-COMPONENT_TARGETS += $(TOOLCHAIN_POWER8LE_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_POWER9LE_GLIBC)
-
-COMPONENT_TARGETS += $(TOOLCHAIN_RISCV64_GLIBC)
-
-COMPONENT_TARGETS += $(TOOLCHAIN_I586_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_I686_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_X86_64_GLIBC)
-
-
-FLAVOURS = compat next
-
-include ../../../build-system/config.mk
-
-SOURCE_REQUIRES = sources/crypt
-
-ifeq ($(FLAVOUR),compat)
-REQUIRES = core/glibc/2.40^full
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_X86_64_GLIBC))
-REQUIRES += core/crypt/4.4.36-x86_32^compat
-else
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_POWER8_GLIBC) \
- $(TOOLCHAIN_POWER9_GLIBC)),)
-REQUIRES += core/crypt/4.4.36-ppc32^compat
-endif
-endif
-endif
-
-ifeq ($(FLAVOUR),next)
-REQUIRES = core/crypt/4.4.36^compat
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_X86_64_GLIBC))
-REQUIRES += core/crypt/4.4.36-x86_32^next
-else
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_POWER8_GLIBC) \
- $(TOOLCHAIN_POWER9_GLIBC)),)
-REQUIRES += core/crypt/4.4.36-ppc32^next
-endif
-endif
-endif
-
-# ======= __END_OF_REQUIRES__ =======
-
-tar_xz_archive = $(SRC_PACKAGE_PATH)/crypt/libxcrypt/libxcrypt-4.4.36.tar.xz
-SRC_ARCHIVE = $(tar_xz_archive)
-SRC_DIR = $(TARGET_BUILD_DIR)/libxcrypt-4.4.36
-src_dir_name = libxcrypt-4.4.36
-src_done = $(TARGET_BUILD_DIR)/.source-done
-
-PATCHES = PATCHES
-
-build_compat_dir = $(TARGET_BUILD_DIR)/build-compat
-build_next_dir = $(TARGET_BUILD_DIR)/build-next
-
-sysroot_dir = $(TOOLCHAIN_PATH)/$(TARGET)/sys-root
-
-build_compat_target = $(TARGET_BUILD_DIR)/.compat-built
-compat_target = $(TARGET_BUILD_DIR)/.compat-installed
-
-build_next_target = $(TARGET_BUILD_DIR)/.next-built
-next_target = $(TARGET_BUILD_DIR)/.next-installed
-
-
-ifeq ($(FLAVOUR),compat)
-BUILD_TARGETS = $(build_compat_target)
-BUILD_TARGETS += $(compat_target)
-endif
-
-ifeq ($(FLAVOUR),next)
-BUILD_TARGETS = $(build_next_target)
-BUILD_TARGETS += $(next_target)
-endif
-
-include ../../../build-system/core.mk
-
-
-env_sysroot = DESTDIR=$(sysroot_dir)
-
-
-CC = $(CCACHE)$(TOOLCHAIN_PATH)/bin/$(TARGET)-gcc
-CXX = $(CCACHE)$(TOOLCHAIN_PATH)/bin/$(TARGET)-g++
-
-environment = AS=$(TOOLCHAIN_PATH)/bin/$(TARGET)-as
-environment += LD=$(TOOLCHAIN_PATH)/bin/$(TARGET)-ld
-environment += CC="$(CC)"
-environment += CXX="$(CXX)"
-environment += AR=$(TOOLCHAIN_PATH)/bin/$(TARGET)-ar
-environment += RANLIB=$(TOOLCHAIN_PATH)/bin/$(TARGET)-ranlib
-
-environment += PATH=$(TOOLCHAIN_PATH)/bin:$(PATH)
-
-LIBSUFFIX =
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A1X_GLIBC))
-environment += CFLAGS="-g -O3 -march=armv7-a -mtune=cortex-a8 -mfpu=neon -mfloat-abi=hard"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A2X_GLIBC))
-environment += CFLAGS="-g -O3 -march=armv7ve -mtune=cortex-a7 -mfpu=neon-vfpv4 -mfloat-abi=hard"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_H3_GLIBC))
-environment += CFLAGS="-g -O3 -march=armv7ve -mtune=cortex-a7 -mfpu=neon-vfpv4 -mfloat-abi=hard"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_H5_GLIBC))
-environment += CFLAGS="-g -O3 -march=armv8-a -mcpu=cortex-a53 -mabi=lp64"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_IMX6_GLIBC))
-environment += CFLAGS="-g -O3 -march=armv7-a -mtune=cortex-a9 -mfpu=vfpv3 -mfloat-abi=hard"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_IMX6ULL_GLIBC))
-environment += CFLAGS="-g -O3 -march=armv7-a -mtune=cortex-a7 -mfpu=neon-vfpv4 -mfloat-abi=hard"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_JZ47XX_GLIBC))
-environment += CFLAGS="-g -O2 -march=mips32r2 -mhard-float"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_P5600_GLIBC))
-environment += CFLAGS="-g -O2 -march=mips32r5 -mtune=p5600 -mhard-float"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_M1000_GLIBC))
-environment += CFLAGS="-g -O3 -march=armv8-a -mcpu=cortex-a57 -mabi=lp64"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_OMAP543X_GLIBC))
-environment += CFLAGS="-g -O3 -march=armv7ve -mtune=cortex-a15 -mfpu=neon-vfpv4 -mfloat-abi=hard"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_AM335X_GLIBC))
-environment += CFLAGS="-g -O3 -march=armv7-a -mtune=cortex-a8 -mfpu=neon -mfloat-abi=hard"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_RK328X_GLIBC))
-environment += CFLAGS="-g -O3 -march=armv7ve -mtune=cortex-a17 -mfpu=neon-vfpv4 -mfloat-abi=hard"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_S8XX_GLIBC))
-environment += CFLAGS="-g -O3 -march=armv7-a -mtune=cortex-a5 -mfpu=neon -mfloat-abi=hard"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_S9XX_GLIBC))
-environment += CFLAGS="-g -O3 -march=armv8-a -mcpu=cortex-a53 -mabi=lp64"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A9XX_GLIBC))
-environment += CFLAGS="-g -O3 -march=armv8-a -mfpu=neon-fp-armv8 -mfloat-abi=hard"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A311X_GLIBC))
-environment += CFLAGS="-g -O3 -march=armv8-a -mcpu=cortex-a73.cortex-a53 -mabi=lp64"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_RK33XX_GLIBC))
-environment += CFLAGS="-g -O3 -march=armv8-a -mcpu=cortex-a53 -mabi=lp64"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_RK339X_GLIBC))
-environment += CFLAGS="-g -O3 -march=armv8-a -mcpu=cortex-a72.cortex-a53 -mabi=lp64"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_RK358X_GLIBC))
-environment += CFLAGS="-g -O3 -march=armv8.2-a -mtune=cortex-a76.cortex-a55 -mabi=lp64"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A33XX_GLIBC))
-environment += CFLAGS="-g -O3 -march=armv8-a -mfpu=neon-fp-armv8 -mfloat-abi=hard"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_PPC8_GLIBC))
-environment += CFLAGS="-g -O3 -mcpu=power8 -mlong-double-128"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_PPC9_GLIBC))
-environment += CFLAGS="-g -O3 -mcpu=power9 -mlong-double-128"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_POWER8_GLIBC))
-environment += CFLAGS="-g -O3 -mcpu=power8 -mlong-double-128"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_POWER9_GLIBC))
-environment += CFLAGS="-g -O3 -mcpu=power9 -mlong-double-128"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_POWER8LE_GLIBC))
-environment += CFLAGS="-g -O3 -mcpu=power8 -mlong-double-128"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_POWER9LE_GLIBC))
-environment += CFLAGS="-g -O3 -mcpu=power9 -mlong-double-128"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_RISCV64_GLIBC))
-environment += CFLAGS="-g -O3 -march=rv64gc -mcmodel=medany"
-endif
-
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_I586_GLIBC))
-environment += CFLAGS="-g -O3 -march=i586 -mtune=i586"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_I686_GLIBC))
-environment += CFLAGS="-g -O3"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_X86_64_GLIBC))
-environment += CFLAGS="-g -O3"
-endif
-
-
-extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
-extra_configure_switches += --mandir=/usr/share/man
-ifeq ($(FLAVOUR),compat)
-extra_configure_switches += --enable-hashes=strong,glibc
-extra_configure_switches += --enable-obsolete-api=glibc
-extra_configure_switches += --disable-feature-tokens
-endif
-ifeq ($(FLAVOUR),next)
-extra_configure_switches += --enable-hashes=strong,glibc
-extra_configure_switches += --enable-obsolete-api=no
-extra_configure_switches += --disable-feature-tokens
-extra_configure_switches += --enable-static=no
-endif
-
-
-
-$(src_done): $(SRC_ARCHIVE) $(PATCHES_DEP)
- $(UNPACK_SRC_ARCHIVE)
- $(APPLY_PATCHES)
- @touch $@
-
-$(build_compat_target): $(src_done)
- @mkdir -p $(build_compat_dir)
- @cd $(build_compat_dir) && $(env_sysroot) $(environment) ../$(src_dir_name)/configure \
- --prefix=/usr \
- --build=$(BUILD) \
- --host=$(TARGET) \
- $(extra_configure_switches)
- @cd $(build_compat_dir) && $(environment) $(MAKE) all
- @touch $@
-
-$(build_next_target): $(src_done)
- @mkdir -p $(build_next_dir)
- @cd $(build_next_dir) && $(env_sysroot) $(environment) ../$(src_dir_name)/configure \
- --prefix=/usr \
- --build=$(BUILD) \
- --host=$(TARGET) \
- $(extra_configure_switches)
- @cd $(build_next_dir) && $(environment) $(MAKE) all
- @touch $@
-
-$(compat_target): $(build_compat_target)
- @mkdir -p $(sysroot_dir)/{,usr/}lib$(LIBSUFFIX)
- @cd $(build_compat_dir) && $(environment) $(MAKE) -j1 install $(env_sysroot)
- @( cd $(sysroot_dir)/usr/lib$(LIBSUFFIX) ; \
- rm -f *.la ; \
- rm libcrypt.so ; \
- mv libcrypt.so* ../../lib$(LIBSUFFIX) ; \
- ln -sf ../../lib$(LIBSUFFIX)/libcrypt.so.1 libcrypt.so ; \
- )
- @echo " $(subst $(TOP_BUILD_DIR_ABS)/,,$(CURDIR))$(if $(FLAVOUR),:$(FLAVOUR),)" >> $(TOOLCHAIN_PATH)/README
- @touch $@
-
-$(next_target): $(build_next_target)
- @mkdir -p $(sysroot_dir)/{,usr/}lib$(LIBSUFFIX)
- @cd $(build_next_dir) && $(environment) $(MAKE) -j1 install $(env_sysroot)
- @( cd $(sysroot_dir)/usr/lib$(LIBSUFFIX) ; \
- rm -f *.la ; \
- rm libcrypt.so ; \
- mv libcrypt.so* ../../lib$(LIBSUFFIX) ; \
- ln -sf ../../lib$(LIBSUFFIX)/libcrypt.so.2 libcrypt.so ; \
- )
- @echo " $(subst $(TOP_BUILD_DIR_ABS)/,,$(CURDIR))$(if $(FLAVOUR),:$(FLAVOUR),)" >> $(TOOLCHAIN_PATH)/README
- @touch $@
Index: core/crypt/4.4.36
===================================================================
--- core/crypt/4.4.36 (revision 75)
+++ core/crypt/4.4.36 (nonexistent)
Property changes on: core/crypt/4.4.36
___________________________________________________________________
Deleted: svn:ignore
## -1,81 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.rk358x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: core/crypt/4.4.38/Makefile
===================================================================
--- core/crypt/4.4.38/Makefile (nonexistent)
+++ core/crypt/4.4.38/Makefile (revision 76)
@@ -0,0 +1,306 @@
+
+
+COMPONENT_TARGETS = $(TOOLCHAIN_A1X_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_A2X_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_H3_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_H5_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_IMX6_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_IMX6ULL_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_JZ47XX_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_P5600_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_M1000_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_OMAP543X_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_AM335X_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_RK328X_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_S8XX_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_S9XX_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_A9XX_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_A311X_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_RK33XX_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_RK339X_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_RK358X_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_A33XX_GLIBC)
+
+COMPONENT_TARGETS += $(TOOLCHAIN_PPC8_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_PPC9_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_POWER8_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_POWER9_GLIBC)
+
+COMPONENT_TARGETS += $(TOOLCHAIN_POWER8LE_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_POWER9LE_GLIBC)
+
+COMPONENT_TARGETS += $(TOOLCHAIN_RISCV64_GLIBC)
+
+COMPONENT_TARGETS += $(TOOLCHAIN_I586_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_I686_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_X86_64_GLIBC)
+
+
+FLAVOURS = compat next
+
+include ../../../build-system/config.mk
+
+SOURCE_REQUIRES = sources/crypt
+
+ifeq ($(FLAVOUR),compat)
+REQUIRES = core/glibc/2.41^full
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_X86_64_GLIBC))
+REQUIRES += core/crypt/4.4.38-x86_32^compat
+else
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_POWER8_GLIBC) \
+ $(TOOLCHAIN_POWER9_GLIBC)),)
+REQUIRES += core/crypt/4.4.38-ppc32^compat
+endif
+endif
+endif
+
+ifeq ($(FLAVOUR),next)
+REQUIRES = core/crypt/4.4.38^compat
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_X86_64_GLIBC))
+REQUIRES += core/crypt/4.4.38-x86_32^next
+else
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_POWER8_GLIBC) \
+ $(TOOLCHAIN_POWER9_GLIBC)),)
+REQUIRES += core/crypt/4.4.38-ppc32^next
+endif
+endif
+endif
+
+# ======= __END_OF_REQUIRES__ =======
+
+tar_xz_archive = $(SRC_PACKAGE_PATH)/crypt/libxcrypt/libxcrypt-4.4.38.tar.xz
+SRC_ARCHIVE = $(tar_xz_archive)
+SRC_DIR = $(TARGET_BUILD_DIR)/libxcrypt-4.4.38
+src_dir_name = libxcrypt-4.4.38
+src_done = $(TARGET_BUILD_DIR)/.source-done
+
+PATCHES = PATCHES
+
+build_compat_dir = $(TARGET_BUILD_DIR)/build-compat
+build_next_dir = $(TARGET_BUILD_DIR)/build-next
+
+sysroot_dir = $(TOOLCHAIN_PATH)/$(TARGET)/sys-root
+
+build_compat_target = $(TARGET_BUILD_DIR)/.compat-built
+compat_target = $(TARGET_BUILD_DIR)/.compat-installed
+
+build_next_target = $(TARGET_BUILD_DIR)/.next-built
+next_target = $(TARGET_BUILD_DIR)/.next-installed
+
+
+ifeq ($(FLAVOUR),compat)
+BUILD_TARGETS = $(build_compat_target)
+BUILD_TARGETS += $(compat_target)
+endif
+
+ifeq ($(FLAVOUR),next)
+BUILD_TARGETS = $(build_next_target)
+BUILD_TARGETS += $(next_target)
+endif
+
+include ../../../build-system/core.mk
+
+
+env_sysroot = DESTDIR=$(sysroot_dir)
+
+
+CC = $(CCACHE)$(TOOLCHAIN_PATH)/bin/$(TARGET)-gcc
+CXX = $(CCACHE)$(TOOLCHAIN_PATH)/bin/$(TARGET)-g++
+
+environment = AS=$(TOOLCHAIN_PATH)/bin/$(TARGET)-as
+environment += LD=$(TOOLCHAIN_PATH)/bin/$(TARGET)-ld
+environment += CC="$(CC)"
+environment += CXX="$(CXX)"
+environment += AR=$(TOOLCHAIN_PATH)/bin/$(TARGET)-ar
+environment += RANLIB=$(TOOLCHAIN_PATH)/bin/$(TARGET)-ranlib
+
+environment += PATH=$(TOOLCHAIN_PATH)/bin:$(PATH)
+
+LIBSUFFIX =
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A1X_GLIBC))
+environment += CFLAGS="-g -O3 -march=armv7-a -mtune=cortex-a8 -mfpu=neon -mfloat-abi=hard"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A2X_GLIBC))
+environment += CFLAGS="-g -O3 -march=armv7ve -mtune=cortex-a7 -mfpu=neon-vfpv4 -mfloat-abi=hard"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_H3_GLIBC))
+environment += CFLAGS="-g -O3 -march=armv7ve -mtune=cortex-a7 -mfpu=neon-vfpv4 -mfloat-abi=hard"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_H5_GLIBC))
+environment += CFLAGS="-g -O3 -march=armv8-a -mcpu=cortex-a53 -mabi=lp64"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_IMX6_GLIBC))
+environment += CFLAGS="-g -O3 -march=armv7-a -mtune=cortex-a9 -mfpu=vfpv3 -mfloat-abi=hard"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_IMX6ULL_GLIBC))
+environment += CFLAGS="-g -O3 -march=armv7-a -mtune=cortex-a7 -mfpu=neon-vfpv4 -mfloat-abi=hard"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_JZ47XX_GLIBC))
+environment += CFLAGS="-g -O2 -march=mips32r2 -mhard-float"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_P5600_GLIBC))
+environment += CFLAGS="-g -O2 -march=mips32r5 -mtune=p5600 -mhard-float"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_M1000_GLIBC))
+environment += CFLAGS="-g -O3 -march=armv8-a -mcpu=cortex-a57 -mabi=lp64"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_OMAP543X_GLIBC))
+environment += CFLAGS="-g -O3 -march=armv7ve -mtune=cortex-a15 -mfpu=neon-vfpv4 -mfloat-abi=hard"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_AM335X_GLIBC))
+environment += CFLAGS="-g -O3 -march=armv7-a -mtune=cortex-a8 -mfpu=neon -mfloat-abi=hard"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_RK328X_GLIBC))
+environment += CFLAGS="-g -O3 -march=armv7ve -mtune=cortex-a17 -mfpu=neon-vfpv4 -mfloat-abi=hard"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_S8XX_GLIBC))
+environment += CFLAGS="-g -O3 -march=armv7-a -mtune=cortex-a5 -mfpu=neon -mfloat-abi=hard"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_S9XX_GLIBC))
+environment += CFLAGS="-g -O3 -march=armv8-a -mcpu=cortex-a53 -mabi=lp64"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A9XX_GLIBC))
+environment += CFLAGS="-g -O3 -march=armv8-a -mfpu=neon-fp-armv8 -mfloat-abi=hard"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A311X_GLIBC))
+environment += CFLAGS="-g -O3 -march=armv8-a -mcpu=cortex-a73.cortex-a53 -mabi=lp64"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_RK33XX_GLIBC))
+environment += CFLAGS="-g -O3 -march=armv8-a -mcpu=cortex-a53 -mabi=lp64"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_RK339X_GLIBC))
+environment += CFLAGS="-g -O3 -march=armv8-a -mcpu=cortex-a72.cortex-a53 -mabi=lp64"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_RK358X_GLIBC))
+environment += CFLAGS="-g -O3 -march=armv8.2-a -mtune=cortex-a76.cortex-a55 -mabi=lp64"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A33XX_GLIBC))
+environment += CFLAGS="-g -O3 -march=armv8-a -mfpu=neon-fp-armv8 -mfloat-abi=hard"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_PPC8_GLIBC))
+environment += CFLAGS="-g -O3 -mcpu=power8 -mlong-double-128"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_PPC9_GLIBC))
+environment += CFLAGS="-g -O3 -mcpu=power9 -mlong-double-128"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_POWER8_GLIBC))
+environment += CFLAGS="-g -O3 -mcpu=power8 -mlong-double-128"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_POWER9_GLIBC))
+environment += CFLAGS="-g -O3 -mcpu=power9 -mlong-double-128"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_POWER8LE_GLIBC))
+environment += CFLAGS="-g -O3 -mcpu=power8 -mlong-double-128"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_POWER9LE_GLIBC))
+environment += CFLAGS="-g -O3 -mcpu=power9 -mlong-double-128"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_RISCV64_GLIBC))
+environment += CFLAGS="-g -O3 -march=rv64gc -mcmodel=medany"
+endif
+
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_I586_GLIBC))
+environment += CFLAGS="-g -O3 -march=i586 -mtune=i586"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_I686_GLIBC))
+environment += CFLAGS="-g -O3"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_X86_64_GLIBC))
+environment += CFLAGS="-g -O3"
+endif
+
+
+extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
+extra_configure_switches += --mandir=/usr/share/man
+ifeq ($(FLAVOUR),compat)
+extra_configure_switches += --enable-hashes=strong,glibc
+extra_configure_switches += --enable-obsolete-api=glibc
+extra_configure_switches += --disable-feature-tokens
+endif
+ifeq ($(FLAVOUR),next)
+extra_configure_switches += --enable-hashes=strong,glibc
+extra_configure_switches += --enable-obsolete-api=no
+extra_configure_switches += --disable-feature-tokens
+extra_configure_switches += --enable-static=no
+endif
+
+
+
+$(src_done): $(SRC_ARCHIVE) $(PATCHES_DEP)
+ $(UNPACK_SRC_ARCHIVE)
+ $(APPLY_PATCHES)
+ @touch $@
+
+$(build_compat_target): $(src_done)
+ @mkdir -p $(build_compat_dir)
+ @cd $(build_compat_dir) && $(env_sysroot) $(environment) ../$(src_dir_name)/configure \
+ --prefix=/usr \
+ --build=$(BUILD) \
+ --host=$(TARGET) \
+ $(extra_configure_switches)
+ @cd $(build_compat_dir) && $(environment) $(MAKE) all
+ @touch $@
+
+$(build_next_target): $(src_done)
+ @mkdir -p $(build_next_dir)
+ @cd $(build_next_dir) && $(env_sysroot) $(environment) ../$(src_dir_name)/configure \
+ --prefix=/usr \
+ --build=$(BUILD) \
+ --host=$(TARGET) \
+ $(extra_configure_switches)
+ @cd $(build_next_dir) && $(environment) $(MAKE) all
+ @touch $@
+
+$(compat_target): $(build_compat_target)
+ @mkdir -p $(sysroot_dir)/{,usr/}lib$(LIBSUFFIX)
+ @cd $(build_compat_dir) && $(environment) $(MAKE) -j1 install $(env_sysroot)
+ @( cd $(sysroot_dir)/usr/lib$(LIBSUFFIX) ; \
+ rm -f *.la ; \
+ rm libcrypt.so ; \
+ mv libcrypt.so* ../../lib$(LIBSUFFIX) ; \
+ ln -sf ../../lib$(LIBSUFFIX)/libcrypt.so.1 libcrypt.so ; \
+ )
+ @echo " $(subst $(TOP_BUILD_DIR_ABS)/,,$(CURDIR))$(if $(FLAVOUR),:$(FLAVOUR),)" >> $(TOOLCHAIN_PATH)/README
+ @touch $@
+
+$(next_target): $(build_next_target)
+ @mkdir -p $(sysroot_dir)/{,usr/}lib$(LIBSUFFIX)
+ @cd $(build_next_dir) && $(environment) $(MAKE) -j1 install $(env_sysroot)
+ @( cd $(sysroot_dir)/usr/lib$(LIBSUFFIX) ; \
+ rm -f *.la ; \
+ rm libcrypt.so ; \
+ mv libcrypt.so* ../../lib$(LIBSUFFIX) ; \
+ ln -sf ../../lib$(LIBSUFFIX)/libcrypt.so.2 libcrypt.so ; \
+ )
+ @echo " $(subst $(TOP_BUILD_DIR_ABS)/,,$(CURDIR))$(if $(FLAVOUR),:$(FLAVOUR),)" >> $(TOOLCHAIN_PATH)/README
+ @touch $@
Index: core/crypt/4.4.38/PATCHES
===================================================================
Index: core/crypt/4.4.38
===================================================================
--- core/crypt/4.4.38 (nonexistent)
+++ core/crypt/4.4.38 (revision 76)
Property changes on: core/crypt/4.4.38
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,81 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.rk358x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: core/crypt/4.4.38-ppc32/Makefile
===================================================================
--- core/crypt/4.4.38-ppc32/Makefile (nonexistent)
+++ core/crypt/4.4.38-ppc32/Makefile (revision 76)
@@ -0,0 +1,148 @@
+
+
+COMPONENT_TARGETS = $(TOOLCHAIN_POWER8_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_POWER9_GLIBC)
+
+
+FLAVOURS = compat next
+
+include ../../../build-system/config.mk
+
+SOURCE_REQUIRES = sources/crypt
+
+ifeq ($(FLAVOUR),compat)
+REQUIRES = core/glibc/2.41-ppc32^full
+endif
+ifeq ($(FLAVOUR),next)
+REQUIRES = core/crypt/4.4.38-ppc32^compat
+endif
+
+# ======= __END_OF_REQUIRES__ =======
+
+tar_xz_archive = $(SRC_PACKAGE_PATH)/crypt/libxcrypt/libxcrypt-4.4.38.tar.xz
+SRC_ARCHIVE = $(tar_xz_archive)
+SRC_DIR = $(TARGET_BUILD_DIR)/libxcrypt-4.4.38
+src_dir_name = libxcrypt-4.4.38
+src_done = $(TARGET_BUILD_DIR)/.source-done
+
+PATCHES = PATCHES
+
+build_compat_dir = $(TARGET_BUILD_DIR)/build-compat
+build_next_dir = $(TARGET_BUILD_DIR)/build-next
+
+sysroot_dir = $(TOOLCHAIN_PATH)/$(TARGET)/sys-root
+
+build_compat_target = $(TARGET_BUILD_DIR)/.compat-built
+compat_target = $(TARGET_BUILD_DIR)/.compat-installed
+
+build_next_target = $(TARGET_BUILD_DIR)/.next-built
+next_target = $(TARGET_BUILD_DIR)/.next-installed
+
+
+ifeq ($(FLAVOUR),compat)
+BUILD_TARGETS = $(build_compat_target)
+BUILD_TARGETS += $(compat_target)
+endif
+
+ifeq ($(FLAVOUR),next)
+BUILD_TARGETS = $(build_next_target)
+BUILD_TARGETS += $(next_target)
+endif
+
+include ../../../build-system/core.mk
+
+
+env_sysroot = DESTDIR=$(sysroot_dir)
+
+
+CC = $(CCACHE)$(TOOLCHAIN_PATH)/bin/$(TARGET)-gcc -m32
+CXX = $(CCACHE)$(TOOLCHAIN_PATH)/bin/$(TARGET)-g++ -m32
+
+environment = AS=$(TOOLCHAIN_PATH)/bin/$(TARGET)-as
+environment += LD=$(TOOLCHAIN_PATH)/bin/$(TARGET)-ld
+environment += CC="$(CC)"
+environment += CXX="$(CXX)"
+environment += AR=$(TOOLCHAIN_PATH)/bin/$(TARGET)-ar
+environment += RANLIB=$(TOOLCHAIN_PATH)/bin/$(TARGET)-ranlib
+
+environment += PATH=$(TOOLCHAIN_PATH)/bin:$(PATH)
+
+LIBSUFFIX =
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_POWER8_GLIBC))
+environment += CFLAGS="-g -O3 -mcpu=power8 -mlong-double-128"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_POWER9_GLIBC))
+environment += CFLAGS="-g -O3 -mcpu=power9 -mlong-double-128"
+endif
+
+LIBSUFFIX = 32
+
+TARGET32 = $(shell echo $(TARGET) | sed 's/ppc64/ppc/')
+
+
+extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
+extra_configure_switches += --mandir=/usr/share/man
+ifeq ($(FLAVOUR),compat)
+extra_configure_switches += --enable-hashes=strong,glibc
+extra_configure_switches += --enable-obsolete-api=glibc
+extra_configure_switches += --disable-feature-tokens
+endif
+ifeq ($(FLAVOUR),next)
+extra_configure_switches += --enable-hashes=strong,glibc
+extra_configure_switches += --enable-obsolete-api=no
+extra_configure_switches += --disable-feature-tokens
+extra_configure_switches += --enable-static=no
+endif
+
+
+
+$(src_done): $(SRC_ARCHIVE) $(PATCHES_DEP)
+ $(UNPACK_SRC_ARCHIVE)
+ $(APPLY_PATCHES)
+ @touch $@
+
+$(build_compat_target): $(src_done)
+ @mkdir -p $(build_compat_dir)
+ @cd $(build_compat_dir) && $(env_sysroot) $(environment) ../$(src_dir_name)/configure \
+ --prefix=/usr \
+ --build=$(BUILD) \
+ --host=$(TARGET32) \
+ $(extra_configure_switches)
+ @cd $(build_compat_dir) && $(environment) $(MAKE) all
+ @touch $@
+
+$(build_next_target): $(src_done)
+ @mkdir -p $(build_next_dir)
+ @cd $(build_next_dir) && $(env_sysroot) $(environment) ../$(src_dir_name)/configure \
+ --prefix=/usr \
+ --build=$(BUILD) \
+ --host=$(TARGET32) \
+ $(extra_configure_switches)
+ @cd $(build_next_dir) && $(environment) $(MAKE) all
+ @touch $@
+
+$(compat_target): $(build_compat_target)
+ @mkdir -p $(sysroot_dir)/{,usr/}lib$(LIBSUFFIX)
+ @cd $(build_compat_dir) && $(environment) $(MAKE) -j1 install $(env_sysroot)
+ @( cd $(sysroot_dir)/usr/lib$(LIBSUFFIX) ; \
+ rm -f *.la ; \
+ rm libcrypt.so ; \
+ mv libcrypt.so* ../../lib$(LIBSUFFIX) ; \
+ ln -sf ../../lib$(LIBSUFFIX)/libcrypt.so.1 libcrypt.so ; \
+ )
+ @echo " $(subst $(TOP_BUILD_DIR_ABS)/,,$(CURDIR))$(if $(FLAVOUR),:$(FLAVOUR),)" >> $(TOOLCHAIN_PATH)/README
+ @touch $@
+
+$(next_target): $(build_next_target)
+ @mkdir -p $(sysroot_dir)/{,usr/}lib$(LIBSUFFIX)
+ @cd $(build_next_dir) && $(environment) $(MAKE) -j1 install $(env_sysroot)
+ @( cd $(sysroot_dir)/usr/lib$(LIBSUFFIX) ; \
+ rm -f *.la ; \
+ rm libcrypt.so ; \
+ mv libcrypt.so* ../../lib$(LIBSUFFIX) ; \
+ ln -sf ../../lib$(LIBSUFFIX)/libcrypt.so.2 libcrypt.so ; \
+ )
+ @echo " $(subst $(TOP_BUILD_DIR_ABS)/,,$(CURDIR))$(if $(FLAVOUR),:$(FLAVOUR),)" >> $(TOOLCHAIN_PATH)/README
+ @touch $@
Index: core/crypt/4.4.38-ppc32/PATCHES
===================================================================
Index: core/crypt/4.4.38-ppc32
===================================================================
--- core/crypt/4.4.38-ppc32 (nonexistent)
+++ core/crypt/4.4.38-ppc32 (revision 76)
Property changes on: core/crypt/4.4.38-ppc32
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,81 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.rk358x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: core/crypt/4.4.38-x86_32/Makefile
===================================================================
--- core/crypt/4.4.38-x86_32/Makefile (nonexistent)
+++ core/crypt/4.4.38-x86_32/Makefile (revision 76)
@@ -0,0 +1,142 @@
+
+
+COMPONENT_TARGETS = $(TOOLCHAIN_X86_64_GLIBC)
+
+
+FLAVOURS = compat next
+
+include ../../../build-system/config.mk
+
+SOURCE_REQUIRES = sources/crypt
+
+ifeq ($(FLAVOUR),compat)
+REQUIRES = core/glibc/2.41-x86_32^full
+endif
+ifeq ($(FLAVOUR),next)
+REQUIRES = core/crypt/4.4.38-x86_32^compat
+endif
+
+# ======= __END_OF_REQUIRES__ =======
+
+tar_xz_archive = $(SRC_PACKAGE_PATH)/crypt/libxcrypt/libxcrypt-4.4.38.tar.xz
+SRC_ARCHIVE = $(tar_xz_archive)
+SRC_DIR = $(TARGET_BUILD_DIR)/libxcrypt-4.4.38
+src_dir_name = libxcrypt-4.4.38
+src_done = $(TARGET_BUILD_DIR)/.source-done
+
+PATCHES = PATCHES
+
+build_compat_dir = $(TARGET_BUILD_DIR)/build-compat
+build_next_dir = $(TARGET_BUILD_DIR)/build-next
+
+sysroot_dir = $(TOOLCHAIN_PATH)/$(TARGET)/sys-root
+
+build_compat_target = $(TARGET_BUILD_DIR)/.compat-built
+compat_target = $(TARGET_BUILD_DIR)/.compat-installed
+
+build_next_target = $(TARGET_BUILD_DIR)/.next-built
+next_target = $(TARGET_BUILD_DIR)/.next-installed
+
+
+ifeq ($(FLAVOUR),compat)
+BUILD_TARGETS = $(build_compat_target)
+BUILD_TARGETS += $(compat_target)
+endif
+
+ifeq ($(FLAVOUR),next)
+BUILD_TARGETS = $(build_next_target)
+BUILD_TARGETS += $(next_target)
+endif
+
+include ../../../build-system/core.mk
+
+
+env_sysroot = DESTDIR=$(sysroot_dir)
+
+
+CC = $(CCACHE)$(TOOLCHAIN_PATH)/bin/$(TARGET)-gcc -m32
+CXX = $(CCACHE)$(TOOLCHAIN_PATH)/bin/$(TARGET)-g++ -m32
+
+environment = AS=$(TOOLCHAIN_PATH)/bin/$(TARGET)-as
+environment += LD=$(TOOLCHAIN_PATH)/bin/$(TARGET)-ld
+environment += CC="$(CC)"
+environment += CXX="$(CXX)"
+environment += AR=$(TOOLCHAIN_PATH)/bin/$(TARGET)-ar
+environment += RANLIB=$(TOOLCHAIN_PATH)/bin/$(TARGET)-ranlib
+
+environment += PATH=$(TOOLCHAIN_PATH)/bin:$(PATH)
+
+LIBSUFFIX =
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_X86_64_GLIBC))
+environment += CFLAGS="-g -O3 -march=i686 -mtune=i686"
+LIBSUFFIX = 32
+endif
+
+TARGET32 = $(shell echo $(TARGET) | sed 's/x86_64/i686/')
+
+
+extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
+extra_configure_switches += --mandir=/usr/share/man
+ifeq ($(FLAVOUR),compat)
+extra_configure_switches += --enable-hashes=strong,glibc
+extra_configure_switches += --enable-obsolete-api=glibc
+extra_configure_switches += --disable-feature-tokens
+endif
+ifeq ($(FLAVOUR),next)
+extra_configure_switches += --enable-hashes=strong,glibc
+extra_configure_switches += --enable-obsolete-api=no
+extra_configure_switches += --disable-feature-tokens
+extra_configure_switches += --enable-static=no
+endif
+
+
+
+$(src_done): $(SRC_ARCHIVE) $(PATCHES_DEP)
+ $(UNPACK_SRC_ARCHIVE)
+ $(APPLY_PATCHES)
+ @touch $@
+
+$(build_compat_target): $(src_done)
+ @mkdir -p $(build_compat_dir)
+ @cd $(build_compat_dir) && $(env_sysroot) $(environment) ../$(src_dir_name)/configure \
+ --prefix=/usr \
+ --build=$(BUILD) \
+ --host=$(TARGET32) \
+ $(extra_configure_switches)
+ @cd $(build_compat_dir) && $(environment) $(MAKE) all
+ @touch $@
+
+$(build_next_target): $(src_done)
+ @mkdir -p $(build_next_dir)
+ @cd $(build_next_dir) && $(env_sysroot) $(environment) ../$(src_dir_name)/configure \
+ --prefix=/usr \
+ --build=$(BUILD) \
+ --host=$(TARGET32) \
+ $(extra_configure_switches)
+ @cd $(build_next_dir) && $(environment) $(MAKE) all
+ @touch $@
+
+$(compat_target): $(build_compat_target)
+ @mkdir -p $(sysroot_dir)/{,usr/}lib$(LIBSUFFIX)
+ @cd $(build_compat_dir) && $(environment) $(MAKE) -j1 install $(env_sysroot)
+ @( cd $(sysroot_dir)/usr/lib$(LIBSUFFIX) ; \
+ rm -f *.la ; \
+ rm libcrypt.so ; \
+ mv libcrypt.so* ../../lib$(LIBSUFFIX) ; \
+ ln -sf ../../lib$(LIBSUFFIX)/libcrypt.so.1 libcrypt.so ; \
+ )
+ @echo " $(subst $(TOP_BUILD_DIR_ABS)/,,$(CURDIR))$(if $(FLAVOUR),:$(FLAVOUR),)" >> $(TOOLCHAIN_PATH)/README
+ @touch $@
+
+$(next_target): $(build_next_target)
+ @mkdir -p $(sysroot_dir)/{,usr/}lib$(LIBSUFFIX)
+ @cd $(build_next_dir) && $(environment) $(MAKE) -j1 install $(env_sysroot)
+ @( cd $(sysroot_dir)/usr/lib$(LIBSUFFIX) ; \
+ rm -f *.la ; \
+ rm libcrypt.so ; \
+ mv libcrypt.so* ../../lib$(LIBSUFFIX) ; \
+ ln -sf ../../lib$(LIBSUFFIX)/libcrypt.so.2 libcrypt.so ; \
+ )
+ @echo " $(subst $(TOP_BUILD_DIR_ABS)/,,$(CURDIR))$(if $(FLAVOUR),:$(FLAVOUR),)" >> $(TOOLCHAIN_PATH)/README
+ @touch $@
Index: core/crypt/4.4.38-x86_32/PATCHES
===================================================================
Index: core/crypt/4.4.38-x86_32
===================================================================
--- core/crypt/4.4.38-x86_32 (nonexistent)
+++ core/crypt/4.4.38-x86_32 (revision 76)
Property changes on: core/crypt/4.4.38-x86_32
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,81 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.rk358x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: core/gcc/14.2.0/Makefile
===================================================================
--- core/gcc/14.2.0/Makefile (revision 75)
+++ core/gcc/14.2.0/Makefile (revision 76)
@@ -61,22 +61,22 @@
ifneq ($(findstring newlib, $(TOOLCHAIN)),)
ifeq ($(FLAVOUR),static)
-REQUIRES = core/binutils/2.43.1
+REQUIRES = core/binutils/2.44
endif
ifeq ($(FLAVOUR),full)
-REQUIRES = core/newlib/4.4.0.20231231^full
+REQUIRES = core/newlib/4.5.0.20241231^full
endif
endif
ifneq ($(findstring -glibc, $(TOOLCHAIN)),)
ifeq ($(FLAVOUR),static)
-REQUIRES = core/binutils/2.43.1
+REQUIRES = core/binutils/2.44
endif
ifeq ($(FLAVOUR),second)
-REQUIRES = core/glibc/2.40^headers
+REQUIRES = core/glibc/2.41^headers
endif
ifeq ($(FLAVOUR),full)
-REQUIRES = core/crypt/4.4.36^next
+REQUIRES = core/crypt/4.4.38^next
endif
endif
@@ -465,7 +465,7 @@
extra_configure_switches += --with-abi=aapcs-linux
# add
extra_configure_switches += --with-float=hard
-extra_configure_switches += --enable-gold
+extra_configure_switches += --enable-gold=no
extra_configure_switches += --enable-c99
extra_configure_switches += --enable-long-long
extra_configure_switches += --disable-isl-version-check
@@ -531,7 +531,7 @@
extra_configure_switches += --with-abi=aapcs-linux
# add
extra_configure_switches += --with-float=hard
-extra_configure_switches += --enable-gold
+extra_configure_switches += --enable-gold=no
extra_configure_switches += --enable-c99
extra_configure_switches += --enable-long-long
extra_configure_switches += --disable-isl-version-check
@@ -598,7 +598,7 @@
# add
extra_configure_switches += --with-float=hard
extra_configure_switches += --with-mode=thumb
-extra_configure_switches += --enable-gold
+extra_configure_switches += --enable-gold=no
extra_configure_switches += --enable-c99
extra_configure_switches += --enable-long-long
extra_configure_switches += --disable-isl-version-check
@@ -666,7 +666,7 @@
extra_configure_switches += --enable-fix-cortex-a53-835769
extra_configure_switches += --enable-fix-cortex-a53-843419
# add
-extra_configure_switches += --enable-gold
+extra_configure_switches += --enable-gold=no
extra_configure_switches += --enable-c99
extra_configure_switches += --enable-long-long
extra_configure_switches += --disable-isl-version-check
@@ -732,7 +732,7 @@
extra_configure_switches += --with-abi=aapcs-linux
# add
extra_configure_switches += --with-float=hard
-extra_configure_switches += --enable-gold
+extra_configure_switches += --enable-gold=no
extra_configure_switches += --enable-c99
extra_configure_switches += --enable-long-long
extra_configure_switches += --disable-isl-version-check
@@ -800,7 +800,7 @@
extra_configure_switches += --enable-fix-cortex-a53-835769
extra_configure_switches += --enable-fix-cortex-a53-843419
# add
-extra_configure_switches += --enable-gold
+extra_configure_switches += --enable-gold=no
extra_configure_switches += --enable-c99
extra_configure_switches += --enable-long-long
extra_configure_switches += --disable-isl-version-check
@@ -866,7 +866,7 @@
extra_configure_switches += --with-fpu=neon-fp-armv8
# add
extra_configure_switches += --with-float=hard
-extra_configure_switches += --enable-gold
+extra_configure_switches += --enable-gold=no
extra_configure_switches += --enable-c99
extra_configure_switches += --enable-long-long
extra_configure_switches += --disable-isl-version-check
@@ -934,7 +934,7 @@
extra_configure_switches += --enable-fix-cortex-a53-835769
extra_configure_switches += --enable-fix-cortex-a53-843419
# add
-extra_configure_switches += --enable-gold
+extra_configure_switches += --enable-gold=no
extra_configure_switches += --enable-c99
extra_configure_switches += --enable-long-long
extra_configure_switches += --disable-isl-version-check
@@ -1002,7 +1002,7 @@
extra_configure_switches += --enable-fix-cortex-a53-835769
extra_configure_switches += --enable-fix-cortex-a53-843419
# add
-extra_configure_switches += --enable-gold
+extra_configure_switches += --enable-gold=no
extra_configure_switches += --enable-c99
extra_configure_switches += --enable-long-long
extra_configure_switches += --disable-isl-version-check
@@ -1070,7 +1070,7 @@
extra_configure_switches += --enable-fix-cortex-a53-835769
extra_configure_switches += --enable-fix-cortex-a53-843419
# add
-extra_configure_switches += --enable-gold
+extra_configure_switches += --enable-gold=no
extra_configure_switches += --enable-c99
extra_configure_switches += --enable-long-long
extra_configure_switches += --disable-isl-version-check
@@ -1136,7 +1136,7 @@
extra_configure_switches += --with-cpu=cortex-a76.cortex-a55
extra_configure_switches += --with-abi=lp64
# add
-extra_configure_switches += --enable-gold
+extra_configure_switches += --enable-gold=no
extra_configure_switches += --enable-c99
extra_configure_switches += --enable-long-long
extra_configure_switches += --disable-isl-version-check
@@ -1202,7 +1202,7 @@
extra_configure_switches += --with-fpu=neon-fp-armv8
# add
extra_configure_switches += --with-float=hard
-extra_configure_switches += --enable-gold
+extra_configure_switches += --enable-gold=no
extra_configure_switches += --enable-c99
extra_configure_switches += --enable-long-long
extra_configure_switches += --disable-isl-version-check
@@ -1268,7 +1268,7 @@
extra_configure_switches += --with-abi=aapcs-linux
# add
extra_configure_switches += --with-float=hard
-extra_configure_switches += --enable-gold
+extra_configure_switches += --enable-gold=no
extra_configure_switches += --enable-c99
extra_configure_switches += --enable-long-long
extra_configure_switches += --disable-isl-version-check
@@ -1335,7 +1335,7 @@
# add
extra_configure_switches += --with-float=hard
extra_configure_switches += --with-mode=thumb
-extra_configure_switches += --enable-gold
+extra_configure_switches += --enable-gold=no
extra_configure_switches += --enable-c99
extra_configure_switches += --enable-long-long
extra_configure_switches += --disable-isl-version-check
@@ -1401,7 +1401,7 @@
extra_configure_switches += --with-abi=aapcs-linux
# add
extra_configure_switches += --with-float=hard
-extra_configure_switches += --enable-gold
+extra_configure_switches += --enable-gold=no
extra_configure_switches += --enable-c99
extra_configure_switches += --enable-long-long
extra_configure_switches += --disable-isl-version-check
@@ -1468,7 +1468,7 @@
# add
extra_configure_switches += --with-float=hard
extra_configure_switches += --with-mode=thumb
-extra_configure_switches += --enable-gold
+extra_configure_switches += --enable-gold=no
extra_configure_switches += --enable-c99
extra_configure_switches += --enable-long-long
extra_configure_switches += --disable-isl-version-check
@@ -1534,7 +1534,7 @@
extra_configure_switches += --with-abi=aapcs-linux
# add
extra_configure_switches += --with-float=hard
-extra_configure_switches += --enable-gold
+extra_configure_switches += --enable-gold=no
extra_configure_switches += --enable-c99
extra_configure_switches += --enable-long-long
extra_configure_switches += --disable-isl-version-check
@@ -1735,7 +1735,7 @@
extra_configure_switches += --with-cpu=cortex-a57
extra_configure_switches += --with-abi=lp64
# add
-extra_configure_switches += --enable-gold
+extra_configure_switches += --enable-gold=no
extra_configure_switches += --enable-c99
extra_configure_switches += --enable-long-long
extra_configure_switches += --disable-isl-version-check
Index: core/gdb/15.1/Makefile
===================================================================
--- core/gdb/15.1/Makefile (revision 75)
+++ core/gdb/15.1/Makefile (nonexistent)
@@ -1,418 +0,0 @@
-
-
-COMPONENT_TARGETS = $(TOOLCHAIN_ARM32_NEWLIB)
-COMPONENT_TARGETS += $(TOOLCHAIN_A33XX_NEWLIB)
-COMPONENT_TARGETS += $(TOOLCHAIN_A9XX_NEWLIB)
-COMPONENT_TARGETS += $(TOOLCHAIN_H5_NEWLIB)
-COMPONENT_TARGETS += $(TOOLCHAIN_S9XX_NEWLIB)
-COMPONENT_TARGETS += $(TOOLCHAIN_RK33XX_NEWLIB)
-COMPONENT_TARGETS += $(TOOLCHAIN_M1000_NEWLIB)
-COMPONENT_TARGETS += $(TOOLCHAIN_RISCV64_NEWLIB)
-
-COMPONENT_TARGETS += $(TOOLCHAIN_A1X_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_A2X_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_H3_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_H5_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_IMX6_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_IMX6ULL_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_JZ47XX_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_P5600_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_M1000_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_OMAP543X_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_AM335X_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_RK328X_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_S8XX_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_S9XX_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_A9XX_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_A311X_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_RK33XX_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_RK339X_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_RK358X_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_A33XX_GLIBC)
-
-COMPONENT_TARGETS += $(TOOLCHAIN_PPC8_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_PPC9_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_POWER8_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_POWER9_GLIBC)
-
-COMPONENT_TARGETS += $(TOOLCHAIN_POWER8LE_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_POWER9LE_GLIBC)
-
-COMPONENT_TARGETS += $(TOOLCHAIN_RISCV64_GLIBC)
-
-COMPONENT_TARGETS += $(TOOLCHAIN_I586_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_I686_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_X86_64_GLIBC)
-
-
-include ../../../build-system/config.mk
-
-
-SOURCE_REQUIRES = sources/GNU/gdb
-
-REQUIRES = core/gcc/14.2.0^full
-
-# ======= __END_OF_REQUIRES__ =======
-
-tar_xz_archive = $(SRC_PACKAGE_PATH)/GNU/gdb/gdb-15.1.tar.xz
-SRC_ARCHIVE = $(tar_xz_archive)
-SRC_DIR = $(TARGET_BUILD_DIR)/gdb-15.1
-src_dir_name = gdb-15.1
-src_done = $(TARGET_BUILD_DIR)/.source-done
-
-build_dir = $(TARGET_BUILD_DIR)/build
-
-sysroot_dir = $(TOOLCHAIN_PATH)/$(TARGET)/sys-root
-
-build_target = $(TARGET_BUILD_DIR)/.built
-install_target = $(TARGET_BUILD_DIR)/.installed
-
-environment = PATH=$(TOOLCHAIN_PATH)/bin:$(PATH)
-
-
-BUILD_TARGETS = $(build_target)
-BUILD_TARGETS += $(install_target)
-
-include ../../../build-system/core.mk
-
-
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_ARM32_NEWLIB))
-extra_configure_switches = --enable-interwork
-extra_configure_switches += --enable-multilib
-extra_configure_switches += --with-abi=aapcs
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A33XX_NEWLIB))
-extra_configure_switches = --enable-interwork
-extra_configure_switches += --enable-multilib
-extra_configure_switches += --with-arch=armv6-m
-extra_configure_switches += --with-tune=cortex-m0
-extra_configure_switches += --with-float=soft
-extra_configure_switches += --with-abi=aapcs
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A9XX_NEWLIB))
-extra_configure_switches = --enable-interwork
-extra_configure_switches += --enable-multilib
-extra_configure_switches += --with-arch=armv7-m
-extra_configure_switches += --with-tune=cortex-m3
-extra_configure_switches += --with-fpu=fpv4-sp-d16
-extra_configure_switches += --with-float=hard
-extra_configure_switches += --with-abi=aapcs
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_H5_NEWLIB))
-extra_configure_switches = --enable-multiarch
-extra_configure_switches += --enable-multilib
-extra_configure_switches += --with-arch=armv8-a
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_S9XX_NEWLIB))
-extra_configure_switches = --enable-multiarch
-extra_configure_switches += --enable-multilib
-extra_configure_switches += --with-arch=armv8-a
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_RK33XX_NEWLIB))
-extra_configure_switches = --enable-multiarch
-extra_configure_switches += --enable-multilib
-extra_configure_switches += --with-arch=armv8-a
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_1000_NEWLIB))
-extra_configure_switches = --enable-multiarch
-extra_configure_switches += --enable-multilib
-extra_configure_switches += --with-arch=armv8-a
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_RISCV64_NEWLIB))
-extra_configure_switches = --enable-multilib
-extra_configure_switches += --with-abi=lp64d
-extra_configure_switches += --with-arch=rv64imafdc
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_A1X_GLIBC)),)
-extra_configure_switches = --enable-interwork
-extra_configure_switches += --enable-multilib
-extra_configure_switches += --disable-libssp
-extra_configure_switches += --with-arch=armv7-a
-extra_configure_switches += --with-tune=cortex-a8
-extra_configure_switches += --with-fpu=neon
-extra_configure_switches += --with-abi=aapcs-linux
-extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_A2X_GLIBC)),)
-extra_configure_switches = --enable-interwork
-extra_configure_switches += --enable-multilib
-extra_configure_switches += --disable-libssp
-extra_configure_switches += --with-arch=armv7ve
-extra_configure_switches += --with-tune=cortex-a7
-extra_configure_switches += --with-fpu=neon-vfpv4
-extra_configure_switches += --with-abi=aapcs-linux
-extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_H3_GLIBC)),)
-extra_configure_switches = --enable-interwork
-extra_configure_switches += --enable-multilib
-extra_configure_switches += --disable-libssp
-extra_configure_switches += --with-arch=armv7ve
-extra_configure_switches += --with-tune=cortex-a7
-extra_configure_switches += --with-fpu=neon-vfpv4
-extra_configure_switches += --with-abi=aapcs-linux
-extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_H5_GLIBC)),)
-extra_configure_switches = --disable-multilib
-extra_configure_switches += --with-arch=armv8-a
-extra_configure_switches += --with-cpu=cortex-a53
-extra_configure_switches += --with-fpu=neon-fp-armv8
-extra_configure_switches += --with-abi=lp64
-extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_IMX6_GLIBC)),)
-extra_configure_switches = --enable-interwork
-extra_configure_switches += --enable-multilib
-extra_configure_switches += --disable-libssp
-extra_configure_switches += --with-arch=armv7-a
-extra_configure_switches += --with-tune=cortex-a9
-extra_configure_switches += --with-fpu=vfpv3
-extra_configure_switches += --with-abi=aapcs-linux
-extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_IMX6ULL_GLIBC)),)
-extra_configure_switches = --enable-interwork
-extra_configure_switches += --enable-multilib
-extra_configure_switches += --disable-libssp
-extra_configure_switches += --with-arch=armv7-a
-extra_configure_switches += --with-tune=cortex-a7
-extra_configure_switches += --with-fpu=neon-vfpv4
-extra_configure_switches += --with-abi=aapcs-linux
-extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_JZ47XX_GLIBC)),)
-extra_configure_switches = --enable-multilib
-extra_configure_switches += --disable-libssp
-extra_configure_switches += --with-arch-32=mips32r2
-extra_configure_switches += --with-arch-64=mips64r2
-extra_configure_switches += --with-float=hard
-extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
-extra_configure_switches += --enable-werror=no
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_P5600_GLIBC)),)
-extra_configure_switches = --enable-multilib
-extra_configure_switches += --disable-libssp
-extra_configure_switches += --with-arch=mips32r5
-extra_configure_switches += --with-tune=p5600
-extra_configure_switches += --with-float=hard
-extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
-extra_configure_switches += --enable-werror=no
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_M1000_GLIBC)),)
-extra_configure_switches = --disable-multilib
-extra_configure_switches += --with-arch=armv8-a
-extra_configure_switches += --with-cpu=cortex-a57
-extra_configure_switches += --with-fpu=neon-fp-armv8
-extra_configure_switches += --with-abi=lp64
-extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_OMAP543X_GLIBC)),)
-extra_configure_switches = --enable-interwork
-extra_configure_switches += --enable-multilib
-extra_configure_switches += --disable-libssp
-extra_configure_switches += --with-arch=armv7ve
-extra_configure_switches += --with-tune=cortex-a15
-extra_configure_switches += --with-fpu=neon-vfpv4
-extra_configure_switches += --with-abi=aapcs-linux
-extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_AM335X_GLIBC)),)
-extra_configure_switches = --enable-interwork
-extra_configure_switches += --enable-multilib
-extra_configure_switches += --disable-libssp
-extra_configure_switches += --with-arch=armv7-a
-extra_configure_switches += --with-tune=cortex-a8
-extra_configure_switches += --with-fpu=neon
-extra_configure_switches += --with-abi=aapcs-linux
-extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_RK328X_GLIBC)),)
-extra_configure_switches = --enable-interwork
-extra_configure_switches += --enable-multilib
-extra_configure_switches += --disable-libssp
-extra_configure_switches += --with-arch=armv7ve
-extra_configure_switches += --with-tune=cortex-a17
-extra_configure_switches += --with-fpu=neon-vfpv4
-extra_configure_switches += --with-abi=aapcs-linux
-extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_S8XX_GLIBC)),)
-extra_configure_switches = --enable-interwork
-extra_configure_switches += --enable-multilib
-extra_configure_switches += --disable-libssp
-extra_configure_switches += --with-arch=armv7-a
-extra_configure_switches += --with-tune=cortex-a5
-extra_configure_switches += --with-fpu=neon
-extra_configure_switches += --with-abi=aapcs-linux
-extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_S9XX_GLIBC)),)
-extra_configure_switches = --disable-multilib
-extra_configure_switches += --with-arch=armv8-a
-extra_configure_switches += --with-cpu=cortex-a53
-extra_configure_switches += --with-fpu=neon-fp-armv8
-extra_configure_switches += --with-abi=lp64
-extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_A9XX_GLIBC)),)
-extra_configure_switches = --disable-multilib
-extra_configure_switches += --with-arch=armv8-a
-extra_configure_switches += --with-fpu=neon-fp-armv8
-extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_A311X_GLIBC)),)
-extra_configure_switches = --disable-multilib
-extra_configure_switches += --with-arch=armv8-a
-extra_configure_switches += --with-cpu=cortex-a53
-extra_configure_switches += --with-fpu=neon-fp-armv8
-extra_configure_switches += --with-abi=lp64
-extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_RK33XX_GLIBC)),)
-extra_configure_switches = --disable-multilib
-extra_configure_switches += --with-arch=armv8-a
-extra_configure_switches += --with-cpu=cortex-a53
-extra_configure_switches += --with-fpu=neon-fp-armv8
-extra_configure_switches += --with-abi=lp64
-extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_RK339X_GLIBC)),)
-extra_configure_switches = --disable-multilib
-extra_configure_switches += --with-arch=armv8-a
-extra_configure_switches += --with-cpu=cortex-a53
-extra_configure_switches += --with-fpu=neon-fp-armv8
-extra_configure_switches += --with-abi=lp64
-extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_RK358X_GLIBC)),)
-extra_configure_switches = --disable-multilib
-extra_configure_switches += --with-arch=armv8.2-a
-extra_configure_switches += --with-cpu=cortex-a76
-extra_configure_switches += --with-fpu=neon-fp-armv8
-extra_configure_switches += --with-abi=lp64
-extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_A33XX_GLIBC)),)
-extra_configure_switches = --disable-multilib
-extra_configure_switches += --with-arch=armv8-a
-extra_configure_switches += --with-fpu=neon-fp-armv8
-extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_PPC8_GLIBC)),)
-extra_configure_switches = --disable-multilib
-extra_configure_switches += --with-cpu=power8
-extra_configure_switches += --with-tune=power8
-extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_PPC9_GLIBC)),)
-extra_configure_switches = --disable-multilib
-extra_configure_switches += --with-cpu=power9
-extra_configure_switches += --with-tune=power9
-extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_POWER8_GLIBC)),)
-extra_configure_switches = --with-multilib-list=m64,m32
-extra_configure_switches += --with-cpu=power8
-extra_configure_switches += --with-tune=power8
-extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_POWER9_GLIBC)),)
-extra_configure_switches = --with-multilib-list=m64,m32
-extra_configure_switches += --with-cpu=power9
-extra_configure_switches += --with-tune=power9
-extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_POWER8LE_GLIBC)),)
-extra_configure_switches = --disable-multilib
-extra_configure_switches += --with-cpu=power8
-extra_configure_switches += --with-tune=power8
-extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_POWER9LE_GLIBC)),)
-extra_configure_switches = --disable-multilib
-extra_configure_switches += --with-cpu=power9
-extra_configure_switches += --with-tune=power9
-extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_RISCV64_GLIBC))
-extra_configure_switches = --disable-multilib
-extra_configure_switches += --with-abi=lp64d
-extra_configure_switches += --with-arch=rv64imafdc
-extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_I586_GLIBC)),)
-extra_configure_switches = --with-arch=i586
-extra_configure_switches += --with-tune=i586
-extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_I686_GLIBC)),)
-extra_configure_switches = --with-arch=i686
-extra_configure_switches += --with-tune=i686
-extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_X86_64_GLIBC)),)
-extra_configure_switches = --with-multilib-list=m64,m32
-extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
-endif
-
-
-
-$(src_done): $(SRC_ARCHIVE) $(PATCHES_DEP)
- $(UNPACK_SRC_ARCHIVE)
- @touch $@
-
-$(build_target): $(src_done)
- @mkdir -p $(build_dir)
- @cd $(build_dir) && $(environment) ../$(src_dir_name)/configure \
- --prefix=$(TOOLCHAIN_PATH) \
- --target=$(TARGET) \
- --datadir=$(TOOLCHAIN_PATH)/share \
- --infodir=$(TOOLCHAIN_PATH)/share/info \
- --mandir=$(TOOLCHAIN_PATH)/share/man \
- $(extra_configure_switches)
- @$(MAKE) $(environment) -C $(build_dir) all
- @touch $@
-
-$(install_target): $(build_target)
- @$(MAKE) $(environment) -j1 -C $(build_dir) install
- @echo " $(subst $(TOP_BUILD_DIR_ABS)/,,$(CURDIR))$(if $(FLAVOUR),:$(FLAVOUR),)" >> $(TOOLCHAIN_PATH)/README
- @touch $@
Index: core/gdb/15.1
===================================================================
--- core/gdb/15.1 (revision 75)
+++ core/gdb/15.1 (nonexistent)
Property changes on: core/gdb/15.1
___________________________________________________________________
Deleted: svn:ignore
## -1,81 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.rk358x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: core/gdb/16.2/Makefile
===================================================================
--- core/gdb/16.2/Makefile (nonexistent)
+++ core/gdb/16.2/Makefile (revision 76)
@@ -0,0 +1,418 @@
+
+
+COMPONENT_TARGETS = $(TOOLCHAIN_ARM32_NEWLIB)
+COMPONENT_TARGETS += $(TOOLCHAIN_A33XX_NEWLIB)
+COMPONENT_TARGETS += $(TOOLCHAIN_A9XX_NEWLIB)
+COMPONENT_TARGETS += $(TOOLCHAIN_H5_NEWLIB)
+COMPONENT_TARGETS += $(TOOLCHAIN_S9XX_NEWLIB)
+COMPONENT_TARGETS += $(TOOLCHAIN_RK33XX_NEWLIB)
+COMPONENT_TARGETS += $(TOOLCHAIN_M1000_NEWLIB)
+COMPONENT_TARGETS += $(TOOLCHAIN_RISCV64_NEWLIB)
+
+COMPONENT_TARGETS += $(TOOLCHAIN_A1X_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_A2X_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_H3_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_H5_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_IMX6_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_IMX6ULL_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_JZ47XX_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_P5600_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_M1000_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_OMAP543X_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_AM335X_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_RK328X_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_S8XX_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_S9XX_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_A9XX_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_A311X_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_RK33XX_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_RK339X_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_RK358X_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_A33XX_GLIBC)
+
+COMPONENT_TARGETS += $(TOOLCHAIN_PPC8_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_PPC9_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_POWER8_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_POWER9_GLIBC)
+
+COMPONENT_TARGETS += $(TOOLCHAIN_POWER8LE_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_POWER9LE_GLIBC)
+
+COMPONENT_TARGETS += $(TOOLCHAIN_RISCV64_GLIBC)
+
+COMPONENT_TARGETS += $(TOOLCHAIN_I586_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_I686_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_X86_64_GLIBC)
+
+
+include ../../../build-system/config.mk
+
+
+SOURCE_REQUIRES = sources/GNU/gdb
+
+REQUIRES = core/gcc/14.2.0^full
+
+# ======= __END_OF_REQUIRES__ =======
+
+tar_xz_archive = $(SRC_PACKAGE_PATH)/GNU/gdb/gdb-16.2.tar.xz
+SRC_ARCHIVE = $(tar_xz_archive)
+SRC_DIR = $(TARGET_BUILD_DIR)/gdb-16.2
+src_dir_name = gdb-16.2
+src_done = $(TARGET_BUILD_DIR)/.source-done
+
+build_dir = $(TARGET_BUILD_DIR)/build
+
+sysroot_dir = $(TOOLCHAIN_PATH)/$(TARGET)/sys-root
+
+build_target = $(TARGET_BUILD_DIR)/.built
+install_target = $(TARGET_BUILD_DIR)/.installed
+
+environment = PATH=$(TOOLCHAIN_PATH)/bin:$(PATH)
+
+
+BUILD_TARGETS = $(build_target)
+BUILD_TARGETS += $(install_target)
+
+include ../../../build-system/core.mk
+
+
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_ARM32_NEWLIB))
+extra_configure_switches = --enable-interwork
+extra_configure_switches += --enable-multilib
+extra_configure_switches += --with-abi=aapcs
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A33XX_NEWLIB))
+extra_configure_switches = --enable-interwork
+extra_configure_switches += --enable-multilib
+extra_configure_switches += --with-arch=armv6-m
+extra_configure_switches += --with-tune=cortex-m0
+extra_configure_switches += --with-float=soft
+extra_configure_switches += --with-abi=aapcs
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A9XX_NEWLIB))
+extra_configure_switches = --enable-interwork
+extra_configure_switches += --enable-multilib
+extra_configure_switches += --with-arch=armv7-m
+extra_configure_switches += --with-tune=cortex-m3
+extra_configure_switches += --with-fpu=fpv4-sp-d16
+extra_configure_switches += --with-float=hard
+extra_configure_switches += --with-abi=aapcs
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_H5_NEWLIB))
+extra_configure_switches = --enable-multiarch
+extra_configure_switches += --enable-multilib
+extra_configure_switches += --with-arch=armv8-a
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_S9XX_NEWLIB))
+extra_configure_switches = --enable-multiarch
+extra_configure_switches += --enable-multilib
+extra_configure_switches += --with-arch=armv8-a
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_RK33XX_NEWLIB))
+extra_configure_switches = --enable-multiarch
+extra_configure_switches += --enable-multilib
+extra_configure_switches += --with-arch=armv8-a
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_1000_NEWLIB))
+extra_configure_switches = --enable-multiarch
+extra_configure_switches += --enable-multilib
+extra_configure_switches += --with-arch=armv8-a
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_RISCV64_NEWLIB))
+extra_configure_switches = --enable-multilib
+extra_configure_switches += --with-abi=lp64d
+extra_configure_switches += --with-arch=rv64imafdc
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_A1X_GLIBC)),)
+extra_configure_switches = --enable-interwork
+extra_configure_switches += --enable-multilib
+extra_configure_switches += --disable-libssp
+extra_configure_switches += --with-arch=armv7-a
+extra_configure_switches += --with-tune=cortex-a8
+extra_configure_switches += --with-fpu=neon
+extra_configure_switches += --with-abi=aapcs-linux
+extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_A2X_GLIBC)),)
+extra_configure_switches = --enable-interwork
+extra_configure_switches += --enable-multilib
+extra_configure_switches += --disable-libssp
+extra_configure_switches += --with-arch=armv7ve
+extra_configure_switches += --with-tune=cortex-a7
+extra_configure_switches += --with-fpu=neon-vfpv4
+extra_configure_switches += --with-abi=aapcs-linux
+extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_H3_GLIBC)),)
+extra_configure_switches = --enable-interwork
+extra_configure_switches += --enable-multilib
+extra_configure_switches += --disable-libssp
+extra_configure_switches += --with-arch=armv7ve
+extra_configure_switches += --with-tune=cortex-a7
+extra_configure_switches += --with-fpu=neon-vfpv4
+extra_configure_switches += --with-abi=aapcs-linux
+extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_H5_GLIBC)),)
+extra_configure_switches = --disable-multilib
+extra_configure_switches += --with-arch=armv8-a
+extra_configure_switches += --with-cpu=cortex-a53
+extra_configure_switches += --with-fpu=neon-fp-armv8
+extra_configure_switches += --with-abi=lp64
+extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_IMX6_GLIBC)),)
+extra_configure_switches = --enable-interwork
+extra_configure_switches += --enable-multilib
+extra_configure_switches += --disable-libssp
+extra_configure_switches += --with-arch=armv7-a
+extra_configure_switches += --with-tune=cortex-a9
+extra_configure_switches += --with-fpu=vfpv3
+extra_configure_switches += --with-abi=aapcs-linux
+extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_IMX6ULL_GLIBC)),)
+extra_configure_switches = --enable-interwork
+extra_configure_switches += --enable-multilib
+extra_configure_switches += --disable-libssp
+extra_configure_switches += --with-arch=armv7-a
+extra_configure_switches += --with-tune=cortex-a7
+extra_configure_switches += --with-fpu=neon-vfpv4
+extra_configure_switches += --with-abi=aapcs-linux
+extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_JZ47XX_GLIBC)),)
+extra_configure_switches = --enable-multilib
+extra_configure_switches += --disable-libssp
+extra_configure_switches += --with-arch-32=mips32r2
+extra_configure_switches += --with-arch-64=mips64r2
+extra_configure_switches += --with-float=hard
+extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
+extra_configure_switches += --enable-werror=no
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_P5600_GLIBC)),)
+extra_configure_switches = --enable-multilib
+extra_configure_switches += --disable-libssp
+extra_configure_switches += --with-arch=mips32r5
+extra_configure_switches += --with-tune=p5600
+extra_configure_switches += --with-float=hard
+extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
+extra_configure_switches += --enable-werror=no
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_M1000_GLIBC)),)
+extra_configure_switches = --disable-multilib
+extra_configure_switches += --with-arch=armv8-a
+extra_configure_switches += --with-cpu=cortex-a57
+extra_configure_switches += --with-fpu=neon-fp-armv8
+extra_configure_switches += --with-abi=lp64
+extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_OMAP543X_GLIBC)),)
+extra_configure_switches = --enable-interwork
+extra_configure_switches += --enable-multilib
+extra_configure_switches += --disable-libssp
+extra_configure_switches += --with-arch=armv7ve
+extra_configure_switches += --with-tune=cortex-a15
+extra_configure_switches += --with-fpu=neon-vfpv4
+extra_configure_switches += --with-abi=aapcs-linux
+extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_AM335X_GLIBC)),)
+extra_configure_switches = --enable-interwork
+extra_configure_switches += --enable-multilib
+extra_configure_switches += --disable-libssp
+extra_configure_switches += --with-arch=armv7-a
+extra_configure_switches += --with-tune=cortex-a8
+extra_configure_switches += --with-fpu=neon
+extra_configure_switches += --with-abi=aapcs-linux
+extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_RK328X_GLIBC)),)
+extra_configure_switches = --enable-interwork
+extra_configure_switches += --enable-multilib
+extra_configure_switches += --disable-libssp
+extra_configure_switches += --with-arch=armv7ve
+extra_configure_switches += --with-tune=cortex-a17
+extra_configure_switches += --with-fpu=neon-vfpv4
+extra_configure_switches += --with-abi=aapcs-linux
+extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_S8XX_GLIBC)),)
+extra_configure_switches = --enable-interwork
+extra_configure_switches += --enable-multilib
+extra_configure_switches += --disable-libssp
+extra_configure_switches += --with-arch=armv7-a
+extra_configure_switches += --with-tune=cortex-a5
+extra_configure_switches += --with-fpu=neon
+extra_configure_switches += --with-abi=aapcs-linux
+extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_S9XX_GLIBC)),)
+extra_configure_switches = --disable-multilib
+extra_configure_switches += --with-arch=armv8-a
+extra_configure_switches += --with-cpu=cortex-a53
+extra_configure_switches += --with-fpu=neon-fp-armv8
+extra_configure_switches += --with-abi=lp64
+extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_A9XX_GLIBC)),)
+extra_configure_switches = --disable-multilib
+extra_configure_switches += --with-arch=armv8-a
+extra_configure_switches += --with-fpu=neon-fp-armv8
+extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_A311X_GLIBC)),)
+extra_configure_switches = --disable-multilib
+extra_configure_switches += --with-arch=armv8-a
+extra_configure_switches += --with-cpu=cortex-a53
+extra_configure_switches += --with-fpu=neon-fp-armv8
+extra_configure_switches += --with-abi=lp64
+extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_RK33XX_GLIBC)),)
+extra_configure_switches = --disable-multilib
+extra_configure_switches += --with-arch=armv8-a
+extra_configure_switches += --with-cpu=cortex-a53
+extra_configure_switches += --with-fpu=neon-fp-armv8
+extra_configure_switches += --with-abi=lp64
+extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_RK339X_GLIBC)),)
+extra_configure_switches = --disable-multilib
+extra_configure_switches += --with-arch=armv8-a
+extra_configure_switches += --with-cpu=cortex-a53
+extra_configure_switches += --with-fpu=neon-fp-armv8
+extra_configure_switches += --with-abi=lp64
+extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_RK358X_GLIBC)),)
+extra_configure_switches = --disable-multilib
+extra_configure_switches += --with-arch=armv8.2-a
+extra_configure_switches += --with-cpu=cortex-a76
+extra_configure_switches += --with-fpu=neon-fp-armv8
+extra_configure_switches += --with-abi=lp64
+extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_A33XX_GLIBC)),)
+extra_configure_switches = --disable-multilib
+extra_configure_switches += --with-arch=armv8-a
+extra_configure_switches += --with-fpu=neon-fp-armv8
+extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_PPC8_GLIBC)),)
+extra_configure_switches = --disable-multilib
+extra_configure_switches += --with-cpu=power8
+extra_configure_switches += --with-tune=power8
+extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_PPC9_GLIBC)),)
+extra_configure_switches = --disable-multilib
+extra_configure_switches += --with-cpu=power9
+extra_configure_switches += --with-tune=power9
+extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_POWER8_GLIBC)),)
+extra_configure_switches = --with-multilib-list=m64,m32
+extra_configure_switches += --with-cpu=power8
+extra_configure_switches += --with-tune=power8
+extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_POWER9_GLIBC)),)
+extra_configure_switches = --with-multilib-list=m64,m32
+extra_configure_switches += --with-cpu=power9
+extra_configure_switches += --with-tune=power9
+extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_POWER8LE_GLIBC)),)
+extra_configure_switches = --disable-multilib
+extra_configure_switches += --with-cpu=power8
+extra_configure_switches += --with-tune=power8
+extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_POWER9LE_GLIBC)),)
+extra_configure_switches = --disable-multilib
+extra_configure_switches += --with-cpu=power9
+extra_configure_switches += --with-tune=power9
+extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_RISCV64_GLIBC))
+extra_configure_switches = --disable-multilib
+extra_configure_switches += --with-abi=lp64d
+extra_configure_switches += --with-arch=rv64imafdc
+extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_I586_GLIBC)),)
+extra_configure_switches = --with-arch=i586
+extra_configure_switches += --with-tune=i586
+extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_I686_GLIBC)),)
+extra_configure_switches = --with-arch=i686
+extra_configure_switches += --with-tune=i686
+extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_X86_64_GLIBC)),)
+extra_configure_switches = --with-multilib-list=m64,m32
+extra_configure_switches += --with-build-sysroot=$(sysroot_dir)
+endif
+
+
+
+$(src_done): $(SRC_ARCHIVE) $(PATCHES_DEP)
+ $(UNPACK_SRC_ARCHIVE)
+ @touch $@
+
+$(build_target): $(src_done)
+ @mkdir -p $(build_dir)
+ @cd $(build_dir) && $(environment) ../$(src_dir_name)/configure \
+ --prefix=$(TOOLCHAIN_PATH) \
+ --target=$(TARGET) \
+ --datadir=$(TOOLCHAIN_PATH)/share \
+ --infodir=$(TOOLCHAIN_PATH)/share/info \
+ --mandir=$(TOOLCHAIN_PATH)/share/man \
+ $(extra_configure_switches)
+ @$(MAKE) $(environment) -C $(build_dir) all
+ @touch $@
+
+$(install_target): $(build_target)
+ @$(MAKE) $(environment) -j1 -C $(build_dir) install
+ @echo " $(subst $(TOP_BUILD_DIR_ABS)/,,$(CURDIR))$(if $(FLAVOUR),:$(FLAVOUR),)" >> $(TOOLCHAIN_PATH)/README
+ @touch $@
Index: core/gdb/16.2
===================================================================
--- core/gdb/16.2 (nonexistent)
+++ core/gdb/16.2 (revision 76)
Property changes on: core/gdb/16.2
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,81 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.rk358x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: core/glibc/2.40-ppc32/PATCHES
===================================================================
--- core/glibc/2.40-ppc32/PATCHES (revision 75)
+++ core/glibc/2.40-ppc32/PATCHES (nonexistent)
@@ -1,9 +0,0 @@
-
-../../../sources/GNU/glibc/patches/glibc-2.40-reenable-DT-HASH.patch -p0
-../../../sources/GNU/glibc/patches/glibc-2.40-i18n.patch -p0
-../../../sources/GNU/glibc/patches/glibc-2.40-locale-no-archive.patch -p0
-../../../sources/GNU/glibc/patches/glibc-2.40-malloc-hooks.patch -p0
-../../../sources/GNU/glibc/patches/glibc-2.40-en_US-no-am-pm.patch -p0
-
-../../../sources/GNU/glibc/patches/glibc-2.40-ppc64-interpreter.patch -p0
-../../../sources/GNU/glibc/patches/glibc-2.40-x86_64-interpreter.patch -p0
Index: core/glibc/2.40-ppc32/Makefile
===================================================================
--- core/glibc/2.40-ppc32/Makefile (revision 75)
+++ core/glibc/2.40-ppc32/Makefile (nonexistent)
@@ -1,147 +0,0 @@
-
-
-COMPONENT_TARGETS = $(TOOLCHAIN_POWER8_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_POWER9_GLIBC)
-
-FLAVOURS = headers full
-
-include ../../../build-system/config.mk
-
-SOURCE_REQUIRES = sources/GNU/glibc
-
-ifeq ($(FLAVOUR),headers)
-REQUIRES = core/linux/6.6.52
-endif
-
-ifeq ($(FLAVOUR),full)
-REQUIRES = core/gcc/14.2.0^second
-endif
-
-# ======= __END_OF_REQUIRES__ =======
-
-tar_xz_archive = $(SRC_PACKAGE_PATH)/GNU/glibc/glibc-2.40.tar.xz
-SRC_ARCHIVE = $(tar_xz_archive)
-SRC_DIR = $(TARGET_BUILD_DIR)/glibc-2.40
-src_dir_name = glibc-2.40
-src_done = $(TARGET_BUILD_DIR)/.source-done
-
-PATCHES = PATCHES
-
-full_dir = $(TARGET_BUILD_DIR)/build-full
-headers_dir = $(TARGET_BUILD_DIR)/build-headers
-
-sysroot_dir = $(TOOLCHAIN_PATH)/$(TARGET)/sys-root
-
-headers_target = $(TARGET_BUILD_DIR)/.headers-installed
-full_target = $(TARGET_BUILD_DIR)/.installed
-
-
-
-ifeq ($(FLAVOUR),headers)
-BUILD_TARGETS = $(headers_target)
-endif
-
-ifeq ($(FLAVOUR),full)
-BUILD_TARGETS = $(full_target)
-endif
-
-include ../../../build-system/core.mk
-
-
-env_sysroot = install_root=$(sysroot_dir)
-
-
-CC = $(CCACHE)$(TOOLCHAIN_PATH)/bin/$(TARGET)-gcc -m32
-CXX = $(CCACHE)$(TOOLCHAIN_PATH)/bin/$(TARGET)-g++ -m32
-
-environment = AS=$(TOOLCHAIN_PATH)/bin/$(TARGET)-as
-environment += LD=$(TOOLCHAIN_PATH)/bin/$(TARGET)-ld
-environment += CC="$(CC)"
-environment += CXX="$(CXX)"
-environment += AR=$(TOOLCHAIN_PATH)/bin/$(TARGET)-ar
-environment += RANLIB=$(TOOLCHAIN_PATH)/bin/$(TARGET)-ranlib
-
-environment += PATH=$(TOOLCHAIN_PATH)/bin:$(PATH)
-
-environment += BUILD_CC="$(CCACHE)/usr/bin/gcc"
-
-LIBSUFFIX =
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_POWER8_GLIBC))
-environment += CFLAGS="-g -O3 -mcpu=power8 -mlong-double-128"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_POWER9_GLIBC))
-environment += CFLAGS="-g -O3 -mcpu=power9 -mlong-double-128"
-endif
-
-LIBSUFFIX = 32
-
-TARGET32 = $(shell echo $(TARGET) | sed 's/ppc64/ppc/')
-
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_POWER8_GLIBC) $(TOOLCHAIN_POWER9_GLIBC)),)
-extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
-extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
-ifeq ($(FLAVOUR),headers)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=3.2.0
-extra_configure_switches += --disable-profile
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-ifeq ($(FLAVOUR),full)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=3.2.0
-extra_configure_switches += --disable-profile
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-endif
-
-
-extra_configure_switches += libc_cv_slibdir=/lib$(LIBSUFFIX)
-extra_configure_switches += libc_cv_rtlddir=/lib$(LIBSUFFIX)
-
-
-
-$(src_done): $(SRC_ARCHIVE) $(PATCHES_DEP)
- $(UNPACK_SRC_ARCHIVE)
- $(APPLY_PATCHES)
- @touch $@
-
-$(headers_target): $(src_done)
- @mkdir -p $(headers_dir)
- @cd $(headers_dir) && $(env_sysroot) $(environment) ../$(src_dir_name)/configure \
- --prefix=/usr \
- --build=$(BUILD) \
- --host=$(TARGET32) \
- $(extra_configure_switches)
- @cd $(headers_dir) && $(MAKE) -j1 install-headers \
- install-bootstrap-headers=yes $(env_sysroot)
- @cd $(headers_dir) && $(environment) $(MAKE) -j1 csu/subdir_lib
- # ======= install 'lib-names-32.h' =======
- @mkdir -p $(sysroot_dir)/usr/include/gnu
- @install --mode=0644 $(headers_dir)/gnu/lib-names-32.h $(sysroot_dir)/usr/include/gnu
- # ========================================
- @cd $(headers_dir) && $(environment) $(MAKE) -j1 csu/subdir_install $(env_sysroot)
- @$(environment) $(CC) -nostdlib -nostartfiles -shared -x c /dev/null \
- -o $(sysroot_dir)/usr/lib$(LIBSUFFIX)/libc.so
- @echo " $(subst $(TOP_BUILD_DIR_ABS)/,,$(CURDIR))$(if $(FLAVOUR),:$(FLAVOUR),)" >> $(TOOLCHAIN_PATH)/README
- @touch $@
-
-$(full_target): $(src_done)
- @mkdir -p $(full_dir)
- @echo "slibdir=/lib$(LIBSUFFIX)" >> $(full_dir)/configparms
- @echo "rtlddir=/lib$(LIBSUFFIX)" >> $(full_dir)/configparms
- @cd $(full_dir) && $(env_sysroot) $(environment) ../$(src_dir_name)/configure \
- --prefix=/usr \
- --build=$(BUILD) \
- --host=$(TARGET32) \
- $(extra_configure_switches)
- @cd $(full_dir) && $(environment) $(MAKE) all
- @cd $(full_dir) && $(environment) $(MAKE) -j1 install $(env_sysroot)
- @echo " $(subst $(TOP_BUILD_DIR_ABS)/,,$(CURDIR))$(if $(FLAVOUR),:$(FLAVOUR),)" >> $(TOOLCHAIN_PATH)/README
- @touch $@
Index: core/glibc/2.40-ppc32
===================================================================
--- core/glibc/2.40-ppc32 (revision 75)
+++ core/glibc/2.40-ppc32 (nonexistent)
Property changes on: core/glibc/2.40-ppc32
___________________________________________________________________
Deleted: svn:ignore
## -1,81 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.rk358x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: core/glibc/2.40-x86_32/PATCHES
===================================================================
--- core/glibc/2.40-x86_32/PATCHES (revision 75)
+++ core/glibc/2.40-x86_32/PATCHES (nonexistent)
@@ -1,9 +0,0 @@
-
-../../../sources/GNU/glibc/patches/glibc-2.40-reenable-DT-HASH.patch -p0
-../../../sources/GNU/glibc/patches/glibc-2.40-i18n.patch -p0
-../../../sources/GNU/glibc/patches/glibc-2.40-locale-no-archive.patch -p0
-../../../sources/GNU/glibc/patches/glibc-2.40-malloc-hooks.patch -p0
-../../../sources/GNU/glibc/patches/glibc-2.40-en_US-no-am-pm.patch -p0
-
-../../../sources/GNU/glibc/patches/glibc-2.40-ppc64-interpreter.patch -p0
-../../../sources/GNU/glibc/patches/glibc-2.40-x86_64-interpreter.patch -p0
Index: core/glibc/2.40-x86_32/Makefile
===================================================================
--- core/glibc/2.40-x86_32/Makefile (revision 75)
+++ core/glibc/2.40-x86_32/Makefile (nonexistent)
@@ -1,141 +0,0 @@
-
-
-COMPONENT_TARGETS = $(TOOLCHAIN_X86_64_GLIBC)
-
-FLAVOURS = headers full
-
-include ../../../build-system/config.mk
-
-SOURCE_REQUIRES = sources/GNU/glibc
-
-ifeq ($(FLAVOUR),headers)
-REQUIRES = core/linux/6.6.52
-endif
-
-ifeq ($(FLAVOUR),full)
-REQUIRES = core/gcc/14.2.0^second
-endif
-
-# ======= __END_OF_REQUIRES__ =======
-
-tar_xz_archive = $(SRC_PACKAGE_PATH)/GNU/glibc/glibc-2.40.tar.xz
-SRC_ARCHIVE = $(tar_xz_archive)
-SRC_DIR = $(TARGET_BUILD_DIR)/glibc-2.40
-src_dir_name = glibc-2.40
-src_done = $(TARGET_BUILD_DIR)/.source-done
-
-PATCHES = PATCHES
-
-full_dir = $(TARGET_BUILD_DIR)/build-full
-headers_dir = $(TARGET_BUILD_DIR)/build-headers
-
-sysroot_dir = $(TOOLCHAIN_PATH)/$(TARGET)/sys-root
-
-headers_target = $(TARGET_BUILD_DIR)/.headers-installed
-full_target = $(TARGET_BUILD_DIR)/.installed
-
-
-
-ifeq ($(FLAVOUR),headers)
-BUILD_TARGETS = $(headers_target)
-endif
-
-ifeq ($(FLAVOUR),full)
-BUILD_TARGETS = $(full_target)
-endif
-
-include ../../../build-system/core.mk
-
-
-env_sysroot = install_root=$(sysroot_dir)
-
-
-CC = $(CCACHE)$(TOOLCHAIN_PATH)/bin/$(TARGET)-gcc -m32
-CXX = $(CCACHE)$(TOOLCHAIN_PATH)/bin/$(TARGET)-g++ -m32
-
-environment = AS=$(TOOLCHAIN_PATH)/bin/$(TARGET)-as
-environment += LD=$(TOOLCHAIN_PATH)/bin/$(TARGET)-ld
-environment += CC="$(CC)"
-environment += CXX="$(CXX)"
-environment += AR=$(TOOLCHAIN_PATH)/bin/$(TARGET)-ar
-environment += RANLIB=$(TOOLCHAIN_PATH)/bin/$(TARGET)-ranlib
-
-environment += PATH=$(TOOLCHAIN_PATH)/bin:$(PATH)
-
-environment += BUILD_CC="$(CCACHE)/usr/bin/gcc"
-
-LIBSUFFIX =
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_X86_64_GLIBC))
-environment += CFLAGS="-g -O3 -march=i686 -mtune=i686"
-LIBSUFFIX = 32
-endif
-
-TARGET32 = $(shell echo $(TARGET) | sed 's/x86_64/i686/')
-
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_X86_64_GLIBC))
-extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
-extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
-ifeq ($(FLAVOUR),headers)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=2.6.36
-extra_configure_switches += --disable-profile
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-ifeq ($(FLAVOUR),full)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=2.6.36
-extra_configure_switches += --disable-profile
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-endif
-
-
-extra_configure_switches += libc_cv_slibdir=/lib$(LIBSUFFIX)
-extra_configure_switches += libc_cv_rtlddir=/lib$(LIBSUFFIX)
-
-
-
-$(src_done): $(SRC_ARCHIVE) $(PATCHES_DEP)
- $(UNPACK_SRC_ARCHIVE)
- $(APPLY_PATCHES)
- @touch $@
-
-$(headers_target): $(src_done)
- @mkdir -p $(headers_dir)
- @cd $(headers_dir) && $(env_sysroot) $(environment) ../$(src_dir_name)/configure \
- --prefix=/usr \
- --build=$(BUILD) \
- --host=$(TARGET32) \
- $(extra_configure_switches)
- @cd $(headers_dir) && $(MAKE) -j1 install-headers \
- install-bootstrap-headers=yes $(env_sysroot)
- @cd $(headers_dir) && $(environment) $(MAKE) -j1 csu/subdir_lib
- # ======= install 'lib-names-32.h' =======
- @mkdir -p $(sysroot_dir)/usr/include/gnu
- @install --mode=0644 $(headers_dir)/gnu/lib-names-32.h $(sysroot_dir)/usr/include/gnu
- # ========================================
- @cd $(headers_dir) && $(environment) $(MAKE) -j1 csu/subdir_install $(env_sysroot)
- @$(environment) $(CC) -nostdlib -nostartfiles -shared -x c /dev/null \
- -o $(sysroot_dir)/usr/lib$(LIBSUFFIX)/libc.so
- @echo " $(subst $(TOP_BUILD_DIR_ABS)/,,$(CURDIR))$(if $(FLAVOUR),:$(FLAVOUR),)" >> $(TOOLCHAIN_PATH)/README
- @touch $@
-
-$(full_target): $(src_done)
- @mkdir -p $(full_dir)
- @echo "slibdir=/lib$(LIBSUFFIX)" >> $(full_dir)/configparms
- @echo "rtlddir=/lib$(LIBSUFFIX)" >> $(full_dir)/configparms
- @cd $(full_dir) && $(env_sysroot) $(environment) ../$(src_dir_name)/configure \
- --prefix=/usr \
- --build=$(BUILD) \
- --host=$(TARGET32) \
- $(extra_configure_switches)
- @cd $(full_dir) && $(environment) $(MAKE) all
- @cd $(full_dir) && $(environment) $(MAKE) -j1 install $(env_sysroot)
- @echo " $(subst $(TOP_BUILD_DIR_ABS)/,,$(CURDIR))$(if $(FLAVOUR),:$(FLAVOUR),)" >> $(TOOLCHAIN_PATH)/README
- @touch $@
Index: core/glibc/2.40-x86_32
===================================================================
--- core/glibc/2.40-x86_32 (revision 75)
+++ core/glibc/2.40-x86_32 (nonexistent)
Property changes on: core/glibc/2.40-x86_32
___________________________________________________________________
Deleted: svn:ignore
## -1,81 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.rk358x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: core/glibc/2.40/PATCHES
===================================================================
--- core/glibc/2.40/PATCHES (revision 75)
+++ core/glibc/2.40/PATCHES (nonexistent)
@@ -1,9 +0,0 @@
-
-../../../sources/GNU/glibc/patches/glibc-2.40-reenable-DT-HASH.patch -p0
-../../../sources/GNU/glibc/patches/glibc-2.40-i18n.patch -p0
-../../../sources/GNU/glibc/patches/glibc-2.40-locale-no-archive.patch -p0
-../../../sources/GNU/glibc/patches/glibc-2.40-malloc-hooks.patch -p0
-../../../sources/GNU/glibc/patches/glibc-2.40-en_US-no-am-pm.patch -p0
-
-../../../sources/GNU/glibc/patches/glibc-2.40-ppc64-interpreter.patch -p0
-../../../sources/GNU/glibc/patches/glibc-2.40-x86_64-interpreter.patch -p0
Index: core/glibc/2.40/Makefile
===================================================================
--- core/glibc/2.40/Makefile (revision 75)
+++ core/glibc/2.40/Makefile (nonexistent)
@@ -1,987 +0,0 @@
-
-
-COMPONENT_TARGETS = $(TOOLCHAIN_A1X_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_A2X_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_H3_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_H5_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_IMX6_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_IMX6ULL_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_JZ47XX_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_P5600_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_M1000_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_OMAP543X_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_AM335X_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_RK328X_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_S8XX_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_S9XX_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_A9XX_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_A311X_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_RK33XX_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_RK339X_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_RK358X_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_A33XX_GLIBC)
-
-COMPONENT_TARGETS += $(TOOLCHAIN_PPC8_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_PPC9_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_POWER8_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_POWER9_GLIBC)
-
-COMPONENT_TARGETS += $(TOOLCHAIN_POWER8LE_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_POWER9LE_GLIBC)
-
-COMPONENT_TARGETS += $(TOOLCHAIN_RISCV64_GLIBC)
-
-COMPONENT_TARGETS += $(TOOLCHAIN_I586_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_I686_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_X86_64_GLIBC)
-
-FLAVOURS = headers full
-
-include ../../../build-system/config.mk
-
-SOURCE_REQUIRES = sources/GNU/glibc
-
-ifeq ($(FLAVOUR),headers)
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A1X_GLIBC))
-REQUIRES = core/linux/6.6.52
-endif
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A2X_GLIBC))
-REQUIRES = core/linux/6.6.52
-endif
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_H3_GLIBC))
-REQUIRES = core/linux/6.6.52
-endif
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_H5_GLIBC))
-REQUIRES = core/linux/6.6.52
-endif
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_IMX6_GLIBC))
-REQUIRES = core/linux/6.6.52
-endif
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_IMX6ULL_GLIBC))
-REQUIRES = core/linux/6.6.52
-endif
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_JZ47XX_GLIBC))
-REQUIRES = core/linux/6.6.52
-endif
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_P5600_GLIBC))
-REQUIRES = core/linux/Baikal/T1000/t1-6.1.59-6.2.19
-endif
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_M1000_GLIBC))
-REQUIRES = core/linux/Baikal/M1000/m1-6.6.32-6.6.161
-endif
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_OMAP543X_GLIBC))
-REQUIRES = core/linux/6.6.52
-endif
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_AM335X_GLIBC))
-REQUIRES = core/linux/6.6.52
-endif
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_RK328X_GLIBC) \
- $(TOOLCHAIN_RK33XX_GLIBC) \
- $(TOOLCHAIN_RK339X_GLIBC) \
- $(TOOLCHAIN_RK358X_GLIBC) \
- $(TOOLCHAIN_A33XX_GLIBC)),)
-REQUIRES = core/linux/6.6.52
-endif
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_S8XX_GLIBC))
-REQUIRES = core/linux/6.6.52
-endif
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_S9XX_GLIBC) \
- $(TOOLCHAIN_A9XX_GLIBC) \
- $(TOOLCHAIN_A311X_GLIBC)),)
-REQUIRES = core/linux/6.6.52
-endif
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_PPC8_GLIBC) \
- $(TOOLCHAIN_PPC9_GLIBC)),)
-REQUIRES = core/linux/6.6.52
-endif
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_POWER8_GLIBC) \
- $(TOOLCHAIN_POWER9_GLIBC)),)
-REQUIRES = core/glibc/2.40-ppc32^headers
-endif
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_POWER8LE_GLIBC) \
- $(TOOLCHAIN_POWER9LE_GLIBC)),)
-REQUIRES = core/linux/6.6.52
-endif
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_RISCV64_GLIBC)),)
-REQUIRES = core/linux/6.6.52
-endif
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_I586_GLIBC))
-REQUIRES = core/linux/6.6.52
-endif
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_I686_GLIBC))
-REQUIRES = core/linux/6.6.52
-endif
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_X86_64_GLIBC))
-REQUIRES = core/glibc/2.40-x86_32^headers
-endif
-endif
-
-ifeq ($(FLAVOUR),full)
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_X86_64_GLIBC))
-REQUIRES = core/glibc/2.40-x86_32^full
-else
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_POWER8_GLIBC) \
- $(TOOLCHAIN_POWER9_GLIBC)),)
-REQUIRES = core/glibc/2.40-ppc32^full
-else
-REQUIRES = core/gcc/14.2.0^second
-endif
-endif
-endif
-
-# ======= __END_OF_REQUIRES__ =======
-
-tar_xz_archive = $(SRC_PACKAGE_PATH)/GNU/glibc/glibc-2.40.tar.xz
-SRC_ARCHIVE = $(tar_xz_archive)
-SRC_DIR = $(TARGET_BUILD_DIR)/glibc-2.40
-src_dir_name = glibc-2.40
-src_done = $(TARGET_BUILD_DIR)/.source-done
-
-PATCHES = PATCHES
-
-full_dir = $(TARGET_BUILD_DIR)/build-full
-headers_dir = $(TARGET_BUILD_DIR)/build-headers
-
-sysroot_dir = $(TOOLCHAIN_PATH)/$(TARGET)/sys-root
-
-headers_target = $(TARGET_BUILD_DIR)/.headers-installed
-full_target = $(TARGET_BUILD_DIR)/.installed
-
-
-
-ifeq ($(FLAVOUR),headers)
-BUILD_TARGETS = $(headers_target)
-endif
-
-ifeq ($(FLAVOUR),full)
-BUILD_TARGETS = $(full_target)
-endif
-
-include ../../../build-system/core.mk
-
-
-env_sysroot = install_root=$(sysroot_dir)
-
-
-CC = $(CCACHE)$(TOOLCHAIN_PATH)/bin/$(TARGET)-gcc
-CXX = $(CCACHE)$(TOOLCHAIN_PATH)/bin/$(TARGET)-g++
-
-environment = AS=$(TOOLCHAIN_PATH)/bin/$(TARGET)-as
-environment += LD=$(TOOLCHAIN_PATH)/bin/$(TARGET)-ld
-environment += CC="$(CC)"
-environment += CXX="$(CXX)"
-environment += AR=$(TOOLCHAIN_PATH)/bin/$(TARGET)-ar
-environment += RANLIB=$(TOOLCHAIN_PATH)/bin/$(TARGET)-ranlib
-
-environment += PATH=$(TOOLCHAIN_PATH)/bin:$(PATH)
-
-environment += BUILD_CC="$(CCACHE)/usr/bin/gcc"
-
-LIBSUFFIX =
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A1X_GLIBC))
-environment += CFLAGS="-g -O3 -march=armv7-a -mtune=cortex-a8 -mfpu=neon -mfloat-abi=hard"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A2X_GLIBC))
-environment += CFLAGS="-g -O3 -march=armv7ve -mtune=cortex-a7 -mfpu=neon-vfpv4 -mfloat-abi=hard"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_H3_GLIBC))
-environment += CFLAGS="-g -O3 -march=armv7ve -mtune=cortex-a7 -mfpu=neon-vfpv4 -mfloat-abi=hard"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_H5_GLIBC))
-environment += CFLAGS="-g -O3 -march=armv8-a+crc+nocrypto -mcpu=cortex-a53 -mabi=lp64"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_IMX6_GLIBC))
-environment += CFLAGS="-g -O3 -march=armv7-a -mtune=cortex-a9 -mfpu=vfpv3 -mfloat-abi=hard"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_IMX6ULL_GLIBC))
-environment += CFLAGS="-g -O3 -march=armv7-a -mtune=cortex-a7 -mfpu=neon-vfpv4 -mfloat-abi=hard"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_JZ47XX_GLIBC))
-environment += CFLAGS="-g -O2 -march=mips32r2 -mhard-float"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_P5600_GLIBC))
-environment += CFLAGS="-g -O2 -march=mips32r5 -mtune=p5600 -mhard-float"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_M1000_GLIBC))
-environment += CFLAGS="-g -O3 -march=armv8-a+crc+nocrypto -mcpu=cortex-a57 -mabi=lp64"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_OMAP543X_GLIBC))
-environment += CFLAGS="-g -O3 -march=armv7ve -mtune=cortex-a15 -mfpu=neon-vfpv4 -mfloat-abi=hard"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_AM335X_GLIBC))
-environment += CFLAGS="-g -O3 -march=armv7-a -mtune=cortex-a8 -mfpu=neon -mfloat-abi=hard"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_RK328X_GLIBC))
-environment += CFLAGS="-g -O3 -march=armv7ve -mtune=cortex-a17 -mfpu=neon-vfpv4 -mfloat-abi=hard"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_S8XX_GLIBC))
-environment += CFLAGS="-g -O3 -march=armv7-a -mtune=cortex-a5 -mfpu=neon -mfloat-abi=hard"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_S9XX_GLIBC))
-environment += CFLAGS="-g -O3 -march=armv8-a+crc+nocrypto -mcpu=cortex-a53 -mabi=lp64"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A9XX_GLIBC))
-environment += CFLAGS="-g -O3 -march=armv8-a -mfpu=neon-fp-armv8 -mfloat-abi=hard"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A311X_GLIBC))
-environment += CFLAGS="-g -O3 -march=armv8-a+crc+nocrypto -mcpu=cortex-a73.cortex-a53 -mabi=lp64"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_RK33XX_GLIBC))
-environment += CFLAGS="-g -O3 -march=armv8-a+crc+nocrypto -mcpu=cortex-a53 -mabi=lp64"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_RK339X_GLIBC))
-environment += CFLAGS="-g -O3 -march=armv8-a+crc+nocrypto -mcpu=cortex-a72.cortex-a53 -mabi=lp64"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_RK358X_GLIBC))
-environment += CFLAGS="-g -O3 -march=armv8.2-a+crc+crypto -mtune=cortex-a76.cortex-a55 -mabi=lp64"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A33XX_GLIBC))
-environment += CFLAGS="-g -O3 -march=armv8-a -mfpu=neon-fp-armv8 -mfloat-abi=hard"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_PPC8_GLIBC))
-environment += CFLAGS="-g -O3 -mcpu=power8 -mlong-double-128"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_PPC9_GLIBC))
-environment += CFLAGS="-g -O3 -mcpu=power9 -mlong-double-128"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_POWER8_GLIBC))
-environment += CFLAGS="-g -O3 -mcpu=power8 -mlong-double-128"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_POWER9_GLIBC))
-environment += CFLAGS="-g -O3 -mcpu=power9 -mlong-double-128"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_POWER8LE_GLIBC))
-environment += CFLAGS="-g -O3 -mcpu=power8 -mlong-double-128"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_POWER9LE_GLIBC))
-environment += CFLAGS="-g -O3 -mcpu=power9 -mlong-double-128"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_RISCV64_GLIBC))
-environment += CFLAGS="-g -O3 -march=rv64gc -misa-spec=2.2 -mcmodel=medany"
-endif
-
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_I586_GLIBC))
-environment += CFLAGS="-g -O3 -march=i586 -mtune=i586"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_I686_GLIBC))
-environment += CFLAGS="-g -O3"
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_X86_64_GLIBC))
-environment += CFLAGS="-g -O3"
-endif
-
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_A1X_GLIBC) \
- $(TOOLCHAIN_A2X_GLIBC) \
- $(TOOLCHAIN_H3_GLIBC) \
- $(TOOLCHAIN_IMX6_GLIBC) \
- $(TOOLCHAIN_IMX6ULL_GLIBC) \
- $(TOOLCHAIN_OMAP543X_GLIBC) \
- $(TOOLCHAIN_AM335X_GLIBC) \
- $(TOOLCHAIN_RK328X_GLIBC) \
- $(TOOLCHAIN_S8XX_GLIBC) \
- $(TOOLCHAIN_A9XX_GLIBC) \
- $(TOOLCHAIN_A33XX_GLIBC)),)
-LIB_NAMES_SUFFIX = hard
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_JZ47XX_GLIBC) $(TOOLCHAIN_P5600_GLIBC)),)
-LIB_NAMES_SUFFIX = o32_hard
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_H5_GLIBC) \
- $(TOOLCHAIN_S9XX_GLIBC) \
- $(TOOLCHAIN_A311X_GLIBC) \
- $(TOOLCHAIN_RK33XX_GLIBC) \
- $(TOOLCHAIN_RK339X_GLIBC) \
- $(TOOLCHAIN_RK358X_GLIBC) \
- $(TOOLCHAIN_M1000_GLIBC)),)
-LIB_NAMES_SUFFIX = lp64
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_I586_GLIBC) $(TOOLCHAIN_I686_GLIBC)),)
-LIB_NAMES_SUFFIX = 32
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_PPC8_GLIBC) $(TOOLCHAIN_PPC9_GLIBC)),)
-LIB_NAMES_SUFFIX = 32
-endif
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_POWER8_GLIBC) $(TOOLCHAIN_POWER9_GLIBC)),)
-LIB_NAMES_SUFFIX = 64-v1
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_POWER8LE_GLIBC) $(TOOLCHAIN_POWER9LE_GLIBC)),)
-LIB_NAMES_SUFFIX = 64-v2
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_RISCV64_GLIBC)),)
-LIB_NAMES_SUFFIX = lp64d
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_X86_64_GLIBC)),)
-LIB_NAMES_SUFFIX = 64
-endif
-
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A1X_GLIBC))
-extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
-extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
-ifeq ($(FLAVOUR),headers)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=3.0.52
-extra_configure_switches += --disable-profile
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-ifeq ($(FLAVOUR),full)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=3.0.52
-extra_configure_switches += --disable-profile
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A2X_GLIBC))
-extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
-extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
-ifeq ($(FLAVOUR),headers)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=3.0.52
-extra_configure_switches += --disable-profile
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-ifeq ($(FLAVOUR),full)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=3.0.52
-extra_configure_switches += --disable-profile
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_H3_GLIBC))
-extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
-extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
-ifeq ($(FLAVOUR),headers)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=4.14.52
-extra_configure_switches += --disable-profile
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-ifeq ($(FLAVOUR),full)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=4.14.52
-extra_configure_switches += --disable-profile
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_H5_GLIBC))
-extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
-extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
-ifeq ($(FLAVOUR),headers)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=4.14.52
-extra_configure_switches += --disable-profile
-extra_configure_switches += --disable-mathvec
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-ifeq ($(FLAVOUR),full)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=4.14.52
-extra_configure_switches += --disable-profile
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --disable-mathvec
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_IMX6_GLIBC))
-extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
-extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
-ifeq ($(FLAVOUR),headers)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=3.0.35
-extra_configure_switches += --disable-profile
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-ifeq ($(FLAVOUR),full)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=3.0.35
-extra_configure_switches += --disable-profile
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_IMX6ULL_GLIBC))
-extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
-extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
-ifeq ($(FLAVOUR),headers)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=3.0.35
-extra_configure_switches += --disable-profile
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-ifeq ($(FLAVOUR),full)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=3.0.35
-extra_configure_switches += --disable-profile
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_JZ47XX_GLIBC))
-extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
-extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
-ifeq ($(FLAVOUR),headers)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=3.0.52
-extra_configure_switches += --disable-profile
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-ifeq ($(FLAVOUR),full)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=3.0.52
-extra_configure_switches += --disable-profile
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_P5600_GLIBC))
-extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
-extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
-ifeq ($(FLAVOUR),headers)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=3.0.52
-extra_configure_switches += --disable-profile
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-ifeq ($(FLAVOUR),full)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=3.0.52
-extra_configure_switches += --disable-profile
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_M1000_GLIBC))
-extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
-extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
-ifeq ($(FLAVOUR),headers)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=4.9.14
-extra_configure_switches += --disable-profile
-extra_configure_switches += --disable-mathvec
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-ifeq ($(FLAVOUR),full)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=4.9.14
-extra_configure_switches += --disable-profile
-extra_configure_switches += --disable-mathvec
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_OMAP543X_GLIBC))
-extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
-extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
-ifeq ($(FLAVOUR),headers)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=2.6.36
-extra_configure_switches += --disable-profile
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-ifeq ($(FLAVOUR),full)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=2.6.36
-extra_configure_switches += --disable-profile
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_AM335X_GLIBC))
-extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
-extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
-ifeq ($(FLAVOUR),headers)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=3.0.52
-extra_configure_switches += --disable-profile
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-ifeq ($(FLAVOUR),full)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=3.0.52
-extra_configure_switches += --disable-profile
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_RK33XX_GLIBC))
-extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
-extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
-ifeq ($(FLAVOUR),headers)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=3.14.29
-extra_configure_switches += --disable-profile
-extra_configure_switches += --disable-mathvec
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-ifeq ($(FLAVOUR),full)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=3.14.29
-extra_configure_switches += --disable-profile
-extra_configure_switches += --disable-mathvec
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_RK339X_GLIBC))
-extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
-extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
-ifeq ($(FLAVOUR),headers)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=3.14.29
-extra_configure_switches += --disable-profile
-extra_configure_switches += --disable-mathvec
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-ifeq ($(FLAVOUR),full)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=3.14.29
-extra_configure_switches += --disable-profile
-extra_configure_switches += --disable-mathvec
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_RK358X_GLIBC))
-extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
-extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
-ifeq ($(FLAVOUR),headers)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=3.14.29
-extra_configure_switches += --disable-profile
-extra_configure_switches += --enable-mathvec
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-ifeq ($(FLAVOUR),full)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=3.14.29
-extra_configure_switches += --disable-profile
-extra_configure_switches += --enable-mathvec
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A33XX_GLIBC))
-extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
-extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
-ifeq ($(FLAVOUR),headers)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=3.14.29
-extra_configure_switches += --disable-profile
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-ifeq ($(FLAVOUR),full)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=3.14.29
-extra_configure_switches += --disable-profile
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-endif
-
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_RK328X_GLIBC))
-extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
-extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
-ifeq ($(FLAVOUR),headers)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=3.0.52
-extra_configure_switches += --disable-profile
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-ifeq ($(FLAVOUR),full)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=3.0.52
-extra_configure_switches += --disable-profile
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_S8XX_GLIBC))
-extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
-extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
-ifeq ($(FLAVOUR),headers)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=3.10.33
-extra_configure_switches += --disable-profile
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-ifeq ($(FLAVOUR),full)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=3.10.33
-extra_configure_switches += --disable-profile
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_S9XX_GLIBC))
-extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
-extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
-ifeq ($(FLAVOUR),headers)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=3.14.29
-extra_configure_switches += --disable-profile
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --disable-mathvec
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-ifeq ($(FLAVOUR),full)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=3.14.29
-extra_configure_switches += --disable-profile
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --disable-mathvec
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A9XX_GLIBC))
-extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
-extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
-ifeq ($(FLAVOUR),headers)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=3.14.29
-extra_configure_switches += --disable-profile
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-ifeq ($(FLAVOUR),full)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=3.14.29
-extra_configure_switches += --disable-profile
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A311X_GLIBC))
-extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
-extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
-ifeq ($(FLAVOUR),headers)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=3.14.29
-extra_configure_switches += --disable-profile
-extra_configure_switches += --disable-mathvec
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-ifeq ($(FLAVOUR),full)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=3.14.29
-extra_configure_switches += --disable-profile
-extra_configure_switches += --disable-mathvec
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-endif
-
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_PPC8_GLIBC) $(TOOLCHAIN_PPC9_GLIBC)),)
-extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
-extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
-ifeq ($(FLAVOUR),headers)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=3.2.0
-extra_configure_switches += --disable-profile
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-ifeq ($(FLAVOUR),full)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=3.2.0
-extra_configure_switches += --disable-profile
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-endif
-
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_POWER8_GLIBC) $(TOOLCHAIN_POWER9_GLIBC)),)
-extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
-extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
-ifeq ($(FLAVOUR),headers)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=3.2.0
-extra_configure_switches += --disable-profile
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-ifeq ($(FLAVOUR),full)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=3.2.0
-extra_configure_switches += --disable-profile
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-endif
-
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_POWER8LE_GLIBC) $(TOOLCHAIN_POWER9LE_GLIBC)),)
-extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
-extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
-ifeq ($(FLAVOUR),headers)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=3.2.0
-extra_configure_switches += --disable-profile
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-ifeq ($(FLAVOUR),full)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=3.2.0
-extra_configure_switches += --disable-profile
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-endif
-
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_RISCV64_GLIBC)),)
-extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
-extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
-ifeq ($(FLAVOUR),headers)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=5.8.0
-extra_configure_switches += --disable-profile
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-ifeq ($(FLAVOUR),full)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=5.8.0
-extra_configure_switches += --disable-profile
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-endif
-
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_I586_GLIBC))
-extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
-extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
-ifeq ($(FLAVOUR),headers)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=2.6.36
-extra_configure_switches += --disable-profile
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-ifeq ($(FLAVOUR),full)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=2.6.36
-extra_configure_switches += --disable-profile
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_I686_GLIBC))
-extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
-extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
-ifeq ($(FLAVOUR),headers)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=2.6.36
-extra_configure_switches += --disable-profile
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-ifeq ($(FLAVOUR),full)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=2.6.36
-extra_configure_switches += --disable-profile
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_X86_64_GLIBC))
-extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
-extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
-ifeq ($(FLAVOUR),headers)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=2.6.36
-extra_configure_switches += --disable-profile
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-ifeq ($(FLAVOUR),full)
-extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
-extra_configure_switches += --enable-kernel=2.6.36
-extra_configure_switches += --disable-profile
-extra_configure_switches += --enable-bind-now
-extra_configure_switches += --without-gd
-extra_configure_switches += --without-cvs
-endif
-endif
-
-
-extra_configure_switches += libc_cv_slibdir=/lib$(LIBSUFFIX)
-extra_configure_switches += libc_cv_rtlddir=/lib$(LIBSUFFIX)
-
-
-
-$(src_done): $(SRC_ARCHIVE) $(PATCHES_DEP)
- $(UNPACK_SRC_ARCHIVE)
- $(APPLY_PATCHES)
- @touch $@
-
-$(headers_target): $(src_done)
- @mkdir -p $(headers_dir)
- @cd $(headers_dir) && $(env_sysroot) $(environment) ../$(src_dir_name)/configure \
- --prefix=/usr \
- --build=$(BUILD) \
- --host=$(TARGET) \
- $(extra_configure_switches)
- @cd $(headers_dir) && $(MAKE) -j1 install-headers \
- install-bootstrap-headers=yes $(env_sysroot)
- @cd $(headers_dir) && $(environment) $(MAKE) -j1 csu/subdir_lib
- # ======= install 'lib-names-$(LIB_NAMES_SUFFIX).h' =======
- @mkdir -p $(sysroot_dir)/usr/include/gnu
- @install --mode=0644 $(headers_dir)/gnu/lib-names-$(LIB_NAMES_SUFFIX).h $(sysroot_dir)/usr/include/gnu
- @install --mode=0644 $(SRC_DIR)/include/gnu/stubs.h $(sysroot_dir)/usr/include/gnu
- # =========================================================
- @cd $(headers_dir) && $(environment) $(MAKE) -j1 csu/subdir_install $(env_sysroot)
- @$(environment) $(CC) -nostdlib -nostartfiles -shared -x c /dev/null \
- -o $(sysroot_dir)/usr/lib$(LIBSUFFIX)/libc.so
- @echo " $(subst $(TOP_BUILD_DIR_ABS)/,,$(CURDIR))$(if $(FLAVOUR),:$(FLAVOUR),)" >> $(TOOLCHAIN_PATH)/README
- @touch $@
-
-$(full_target): $(src_done)
- @mkdir -p $(full_dir)
- @echo "slibdir=/lib$(LIBSUFFIX)" >> $(full_dir)/configparms
- @echo "rtlddir=/lib$(LIBSUFFIX)" >> $(full_dir)/configparms
- @cd $(full_dir) && $(env_sysroot) $(environment) ../$(src_dir_name)/configure \
- --prefix=/usr \
- --build=$(BUILD) \
- --host=$(TARGET) \
- $(extra_configure_switches)
- @cd $(full_dir) && $(environment) $(MAKE) all
- @cd $(full_dir) && $(environment) $(MAKE) -j1 install $(env_sysroot)
- @rm -f $(sysroot_dir)/usr/share/info/dir
- @echo " $(subst $(TOP_BUILD_DIR_ABS)/,,$(CURDIR))$(if $(FLAVOUR),:$(FLAVOUR),)" >> $(TOOLCHAIN_PATH)/README
- @touch $@
Index: core/glibc/2.40
===================================================================
--- core/glibc/2.40 (revision 75)
+++ core/glibc/2.40 (nonexistent)
Property changes on: core/glibc/2.40
___________________________________________________________________
Deleted: svn:ignore
## -1,81 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.rk358x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: core/glibc/2.41/Makefile
===================================================================
--- core/glibc/2.41/Makefile (nonexistent)
+++ core/glibc/2.41/Makefile (revision 76)
@@ -0,0 +1,987 @@
+
+
+COMPONENT_TARGETS = $(TOOLCHAIN_A1X_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_A2X_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_H3_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_H5_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_IMX6_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_IMX6ULL_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_JZ47XX_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_P5600_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_M1000_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_OMAP543X_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_AM335X_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_RK328X_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_S8XX_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_S9XX_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_A9XX_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_A311X_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_RK33XX_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_RK339X_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_RK358X_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_A33XX_GLIBC)
+
+COMPONENT_TARGETS += $(TOOLCHAIN_PPC8_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_PPC9_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_POWER8_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_POWER9_GLIBC)
+
+COMPONENT_TARGETS += $(TOOLCHAIN_POWER8LE_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_POWER9LE_GLIBC)
+
+COMPONENT_TARGETS += $(TOOLCHAIN_RISCV64_GLIBC)
+
+COMPONENT_TARGETS += $(TOOLCHAIN_I586_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_I686_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_X86_64_GLIBC)
+
+FLAVOURS = headers full
+
+include ../../../build-system/config.mk
+
+SOURCE_REQUIRES = sources/GNU/glibc
+
+ifeq ($(FLAVOUR),headers)
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A1X_GLIBC))
+REQUIRES = core/linux/6.12.15
+endif
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A2X_GLIBC))
+REQUIRES = core/linux/6.12.15
+endif
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_H3_GLIBC))
+REQUIRES = core/linux/6.12.15
+endif
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_H5_GLIBC))
+REQUIRES = core/linux/6.12.15
+endif
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_IMX6_GLIBC))
+REQUIRES = core/linux/6.12.15
+endif
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_IMX6ULL_GLIBC))
+REQUIRES = core/linux/6.12.15
+endif
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_JZ47XX_GLIBC))
+REQUIRES = core/linux/6.12.15
+endif
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_P5600_GLIBC))
+REQUIRES = core/linux/Baikal/T1000/t1-6.1.59-6.2.19
+endif
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_M1000_GLIBC))
+REQUIRES = core/linux/Baikal/M1000/m1-6.6.63-6.6.236
+endif
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_OMAP543X_GLIBC))
+REQUIRES = core/linux/6.12.15
+endif
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_AM335X_GLIBC))
+REQUIRES = core/linux/6.12.15
+endif
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_RK328X_GLIBC) \
+ $(TOOLCHAIN_RK33XX_GLIBC) \
+ $(TOOLCHAIN_RK339X_GLIBC) \
+ $(TOOLCHAIN_RK358X_GLIBC) \
+ $(TOOLCHAIN_A33XX_GLIBC)),)
+REQUIRES = core/linux/6.12.15
+endif
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_S8XX_GLIBC))
+REQUIRES = core/linux/6.12.15
+endif
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_S9XX_GLIBC) \
+ $(TOOLCHAIN_A9XX_GLIBC) \
+ $(TOOLCHAIN_A311X_GLIBC)),)
+REQUIRES = core/linux/6.12.15
+endif
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_PPC8_GLIBC) \
+ $(TOOLCHAIN_PPC9_GLIBC)),)
+REQUIRES = core/linux/6.12.15
+endif
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_POWER8_GLIBC) \
+ $(TOOLCHAIN_POWER9_GLIBC)),)
+REQUIRES = core/glibc/2.41-ppc32^headers
+endif
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_POWER8LE_GLIBC) \
+ $(TOOLCHAIN_POWER9LE_GLIBC)),)
+REQUIRES = core/linux/6.12.15
+endif
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_RISCV64_GLIBC)),)
+REQUIRES = core/linux/6.12.15
+endif
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_I586_GLIBC))
+REQUIRES = core/linux/6.12.15
+endif
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_I686_GLIBC))
+REQUIRES = core/linux/6.12.15
+endif
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_X86_64_GLIBC))
+REQUIRES = core/glibc/2.41-x86_32^headers
+endif
+endif
+
+ifeq ($(FLAVOUR),full)
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_X86_64_GLIBC))
+REQUIRES = core/glibc/2.41-x86_32^full
+else
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_POWER8_GLIBC) \
+ $(TOOLCHAIN_POWER9_GLIBC)),)
+REQUIRES = core/glibc/2.41-ppc32^full
+else
+REQUIRES = core/gcc/14.2.0^second
+endif
+endif
+endif
+
+# ======= __END_OF_REQUIRES__ =======
+
+tar_xz_archive = $(SRC_PACKAGE_PATH)/GNU/glibc/glibc-2.41.tar.xz
+SRC_ARCHIVE = $(tar_xz_archive)
+SRC_DIR = $(TARGET_BUILD_DIR)/glibc-2.41
+src_dir_name = glibc-2.41
+src_done = $(TARGET_BUILD_DIR)/.source-done
+
+PATCHES = PATCHES
+
+full_dir = $(TARGET_BUILD_DIR)/build-full
+headers_dir = $(TARGET_BUILD_DIR)/build-headers
+
+sysroot_dir = $(TOOLCHAIN_PATH)/$(TARGET)/sys-root
+
+headers_target = $(TARGET_BUILD_DIR)/.headers-installed
+full_target = $(TARGET_BUILD_DIR)/.installed
+
+
+
+ifeq ($(FLAVOUR),headers)
+BUILD_TARGETS = $(headers_target)
+endif
+
+ifeq ($(FLAVOUR),full)
+BUILD_TARGETS = $(full_target)
+endif
+
+include ../../../build-system/core.mk
+
+
+env_sysroot = install_root=$(sysroot_dir)
+
+
+CC = $(CCACHE)$(TOOLCHAIN_PATH)/bin/$(TARGET)-gcc
+CXX = $(CCACHE)$(TOOLCHAIN_PATH)/bin/$(TARGET)-g++
+
+environment = AS=$(TOOLCHAIN_PATH)/bin/$(TARGET)-as
+environment += LD=$(TOOLCHAIN_PATH)/bin/$(TARGET)-ld
+environment += CC="$(CC)"
+environment += CXX="$(CXX)"
+environment += AR=$(TOOLCHAIN_PATH)/bin/$(TARGET)-ar
+environment += RANLIB=$(TOOLCHAIN_PATH)/bin/$(TARGET)-ranlib
+
+environment += PATH=$(TOOLCHAIN_PATH)/bin:$(PATH)
+
+environment += BUILD_CC="$(CCACHE)/usr/bin/gcc"
+
+LIBSUFFIX =
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A1X_GLIBC))
+environment += CFLAGS="-g -O3 -march=armv7-a -mtune=cortex-a8 -mfpu=neon -mfloat-abi=hard"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A2X_GLIBC))
+environment += CFLAGS="-g -O3 -march=armv7ve -mtune=cortex-a7 -mfpu=neon-vfpv4 -mfloat-abi=hard"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_H3_GLIBC))
+environment += CFLAGS="-g -O3 -march=armv7ve -mtune=cortex-a7 -mfpu=neon-vfpv4 -mfloat-abi=hard"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_H5_GLIBC))
+environment += CFLAGS="-g -O3 -march=armv8-a+crc+nocrypto -mcpu=cortex-a53 -mabi=lp64"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_IMX6_GLIBC))
+environment += CFLAGS="-g -O3 -march=armv7-a -mtune=cortex-a9 -mfpu=vfpv3 -mfloat-abi=hard"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_IMX6ULL_GLIBC))
+environment += CFLAGS="-g -O3 -march=armv7-a -mtune=cortex-a7 -mfpu=neon-vfpv4 -mfloat-abi=hard"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_JZ47XX_GLIBC))
+environment += CFLAGS="-g -O2 -march=mips32r2 -mhard-float"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_P5600_GLIBC))
+environment += CFLAGS="-g -O2 -march=mips32r5 -mtune=p5600 -mhard-float"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_M1000_GLIBC))
+environment += CFLAGS="-g -O3 -march=armv8-a+crc+nocrypto -mcpu=cortex-a57 -mabi=lp64"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_OMAP543X_GLIBC))
+environment += CFLAGS="-g -O3 -march=armv7ve -mtune=cortex-a15 -mfpu=neon-vfpv4 -mfloat-abi=hard"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_AM335X_GLIBC))
+environment += CFLAGS="-g -O3 -march=armv7-a -mtune=cortex-a8 -mfpu=neon -mfloat-abi=hard"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_RK328X_GLIBC))
+environment += CFLAGS="-g -O3 -march=armv7ve -mtune=cortex-a17 -mfpu=neon-vfpv4 -mfloat-abi=hard"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_S8XX_GLIBC))
+environment += CFLAGS="-g -O3 -march=armv7-a -mtune=cortex-a5 -mfpu=neon -mfloat-abi=hard"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_S9XX_GLIBC))
+environment += CFLAGS="-g -O3 -march=armv8-a+crc+nocrypto -mcpu=cortex-a53 -mabi=lp64"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A9XX_GLIBC))
+environment += CFLAGS="-g -O3 -march=armv8-a -mfpu=neon-fp-armv8 -mfloat-abi=hard"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A311X_GLIBC))
+environment += CFLAGS="-g -O3 -march=armv8-a+crc+nocrypto -mcpu=cortex-a73.cortex-a53 -mabi=lp64"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_RK33XX_GLIBC))
+environment += CFLAGS="-g -O3 -march=armv8-a+crc+nocrypto -mcpu=cortex-a53 -mabi=lp64"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_RK339X_GLIBC))
+environment += CFLAGS="-g -O3 -march=armv8-a+crc+nocrypto -mcpu=cortex-a72.cortex-a53 -mabi=lp64"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_RK358X_GLIBC))
+environment += CFLAGS="-g -O3 -march=armv8.2-a+crc+crypto -mtune=cortex-a76.cortex-a55 -mabi=lp64"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A33XX_GLIBC))
+environment += CFLAGS="-g -O3 -march=armv8-a -mfpu=neon-fp-armv8 -mfloat-abi=hard"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_PPC8_GLIBC))
+environment += CFLAGS="-g -O3 -mcpu=power8 -mlong-double-128"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_PPC9_GLIBC))
+environment += CFLAGS="-g -O3 -mcpu=power9 -mlong-double-128"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_POWER8_GLIBC))
+environment += CFLAGS="-g -O3 -mcpu=power8 -mlong-double-128"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_POWER9_GLIBC))
+environment += CFLAGS="-g -O3 -mcpu=power9 -mlong-double-128"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_POWER8LE_GLIBC))
+environment += CFLAGS="-g -O3 -mcpu=power8 -mlong-double-128"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_POWER9LE_GLIBC))
+environment += CFLAGS="-g -O3 -mcpu=power9 -mlong-double-128"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_RISCV64_GLIBC))
+environment += CFLAGS="-g -O3 -march=rv64gc -misa-spec=2.2 -mcmodel=medany"
+endif
+
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_I586_GLIBC))
+environment += CFLAGS="-g -O3 -march=i586 -mtune=i586"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_I686_GLIBC))
+environment += CFLAGS="-g -O3"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_X86_64_GLIBC))
+environment += CFLAGS="-g -O3"
+endif
+
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_A1X_GLIBC) \
+ $(TOOLCHAIN_A2X_GLIBC) \
+ $(TOOLCHAIN_H3_GLIBC) \
+ $(TOOLCHAIN_IMX6_GLIBC) \
+ $(TOOLCHAIN_IMX6ULL_GLIBC) \
+ $(TOOLCHAIN_OMAP543X_GLIBC) \
+ $(TOOLCHAIN_AM335X_GLIBC) \
+ $(TOOLCHAIN_RK328X_GLIBC) \
+ $(TOOLCHAIN_S8XX_GLIBC) \
+ $(TOOLCHAIN_A9XX_GLIBC) \
+ $(TOOLCHAIN_A33XX_GLIBC)),)
+LIB_NAMES_SUFFIX = hard
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_JZ47XX_GLIBC) $(TOOLCHAIN_P5600_GLIBC)),)
+LIB_NAMES_SUFFIX = o32_hard
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_H5_GLIBC) \
+ $(TOOLCHAIN_S9XX_GLIBC) \
+ $(TOOLCHAIN_A311X_GLIBC) \
+ $(TOOLCHAIN_RK33XX_GLIBC) \
+ $(TOOLCHAIN_RK339X_GLIBC) \
+ $(TOOLCHAIN_RK358X_GLIBC) \
+ $(TOOLCHAIN_M1000_GLIBC)),)
+LIB_NAMES_SUFFIX = lp64
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_I586_GLIBC) $(TOOLCHAIN_I686_GLIBC)),)
+LIB_NAMES_SUFFIX = 32
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_PPC8_GLIBC) $(TOOLCHAIN_PPC9_GLIBC)),)
+LIB_NAMES_SUFFIX = 32
+endif
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_POWER8_GLIBC) $(TOOLCHAIN_POWER9_GLIBC)),)
+LIB_NAMES_SUFFIX = 64-v1
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_POWER8LE_GLIBC) $(TOOLCHAIN_POWER9LE_GLIBC)),)
+LIB_NAMES_SUFFIX = 64-v2
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_RISCV64_GLIBC)),)
+LIB_NAMES_SUFFIX = lp64d
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_X86_64_GLIBC)),)
+LIB_NAMES_SUFFIX = 64
+endif
+
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A1X_GLIBC))
+extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
+extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
+ifeq ($(FLAVOUR),headers)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=3.0.52
+extra_configure_switches += --disable-profile
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+ifeq ($(FLAVOUR),full)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=3.0.52
+extra_configure_switches += --disable-profile
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A2X_GLIBC))
+extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
+extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
+ifeq ($(FLAVOUR),headers)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=3.0.52
+extra_configure_switches += --disable-profile
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+ifeq ($(FLAVOUR),full)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=3.0.52
+extra_configure_switches += --disable-profile
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_H3_GLIBC))
+extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
+extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
+ifeq ($(FLAVOUR),headers)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=4.14.52
+extra_configure_switches += --disable-profile
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+ifeq ($(FLAVOUR),full)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=4.14.52
+extra_configure_switches += --disable-profile
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_H5_GLIBC))
+extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
+extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
+ifeq ($(FLAVOUR),headers)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=4.14.52
+extra_configure_switches += --disable-profile
+extra_configure_switches += --disable-mathvec
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+ifeq ($(FLAVOUR),full)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=4.14.52
+extra_configure_switches += --disable-profile
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --disable-mathvec
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_IMX6_GLIBC))
+extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
+extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
+ifeq ($(FLAVOUR),headers)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=3.0.35
+extra_configure_switches += --disable-profile
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+ifeq ($(FLAVOUR),full)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=3.0.35
+extra_configure_switches += --disable-profile
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_IMX6ULL_GLIBC))
+extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
+extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
+ifeq ($(FLAVOUR),headers)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=3.0.35
+extra_configure_switches += --disable-profile
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+ifeq ($(FLAVOUR),full)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=3.0.35
+extra_configure_switches += --disable-profile
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_JZ47XX_GLIBC))
+extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
+extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
+ifeq ($(FLAVOUR),headers)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=3.0.52
+extra_configure_switches += --disable-profile
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+ifeq ($(FLAVOUR),full)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=3.0.52
+extra_configure_switches += --disable-profile
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_P5600_GLIBC))
+extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
+extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
+ifeq ($(FLAVOUR),headers)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=3.0.52
+extra_configure_switches += --disable-profile
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+ifeq ($(FLAVOUR),full)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=3.0.52
+extra_configure_switches += --disable-profile
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_M1000_GLIBC))
+extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
+extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
+ifeq ($(FLAVOUR),headers)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=4.9.14
+extra_configure_switches += --disable-profile
+extra_configure_switches += --disable-mathvec
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+ifeq ($(FLAVOUR),full)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=4.9.14
+extra_configure_switches += --disable-profile
+extra_configure_switches += --disable-mathvec
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_OMAP543X_GLIBC))
+extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
+extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
+ifeq ($(FLAVOUR),headers)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=2.6.36
+extra_configure_switches += --disable-profile
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+ifeq ($(FLAVOUR),full)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=2.6.36
+extra_configure_switches += --disable-profile
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_AM335X_GLIBC))
+extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
+extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
+ifeq ($(FLAVOUR),headers)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=3.0.52
+extra_configure_switches += --disable-profile
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+ifeq ($(FLAVOUR),full)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=3.0.52
+extra_configure_switches += --disable-profile
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_RK33XX_GLIBC))
+extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
+extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
+ifeq ($(FLAVOUR),headers)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=3.14.29
+extra_configure_switches += --disable-profile
+extra_configure_switches += --disable-mathvec
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+ifeq ($(FLAVOUR),full)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=3.14.29
+extra_configure_switches += --disable-profile
+extra_configure_switches += --disable-mathvec
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_RK339X_GLIBC))
+extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
+extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
+ifeq ($(FLAVOUR),headers)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=3.14.29
+extra_configure_switches += --disable-profile
+extra_configure_switches += --disable-mathvec
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+ifeq ($(FLAVOUR),full)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=3.14.29
+extra_configure_switches += --disable-profile
+extra_configure_switches += --disable-mathvec
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_RK358X_GLIBC))
+extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
+extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
+ifeq ($(FLAVOUR),headers)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=3.14.29
+extra_configure_switches += --disable-profile
+extra_configure_switches += --enable-mathvec
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+ifeq ($(FLAVOUR),full)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=3.14.29
+extra_configure_switches += --disable-profile
+extra_configure_switches += --enable-mathvec
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A33XX_GLIBC))
+extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
+extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
+ifeq ($(FLAVOUR),headers)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=3.14.29
+extra_configure_switches += --disable-profile
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+ifeq ($(FLAVOUR),full)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=3.14.29
+extra_configure_switches += --disable-profile
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+endif
+
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_RK328X_GLIBC))
+extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
+extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
+ifeq ($(FLAVOUR),headers)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=3.0.52
+extra_configure_switches += --disable-profile
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+ifeq ($(FLAVOUR),full)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=3.0.52
+extra_configure_switches += --disable-profile
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_S8XX_GLIBC))
+extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
+extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
+ifeq ($(FLAVOUR),headers)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=3.10.33
+extra_configure_switches += --disable-profile
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+ifeq ($(FLAVOUR),full)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=3.10.33
+extra_configure_switches += --disable-profile
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_S9XX_GLIBC))
+extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
+extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
+ifeq ($(FLAVOUR),headers)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=3.14.29
+extra_configure_switches += --disable-profile
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --disable-mathvec
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+ifeq ($(FLAVOUR),full)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=3.14.29
+extra_configure_switches += --disable-profile
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --disable-mathvec
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A9XX_GLIBC))
+extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
+extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
+ifeq ($(FLAVOUR),headers)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=3.14.29
+extra_configure_switches += --disable-profile
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+ifeq ($(FLAVOUR),full)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=3.14.29
+extra_configure_switches += --disable-profile
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A311X_GLIBC))
+extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
+extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
+ifeq ($(FLAVOUR),headers)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=3.14.29
+extra_configure_switches += --disable-profile
+extra_configure_switches += --disable-mathvec
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+ifeq ($(FLAVOUR),full)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=3.14.29
+extra_configure_switches += --disable-profile
+extra_configure_switches += --disable-mathvec
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+endif
+
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_PPC8_GLIBC) $(TOOLCHAIN_PPC9_GLIBC)),)
+extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
+extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
+ifeq ($(FLAVOUR),headers)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=3.2.0
+extra_configure_switches += --disable-profile
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+ifeq ($(FLAVOUR),full)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=3.2.0
+extra_configure_switches += --disable-profile
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+endif
+
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_POWER8_GLIBC) $(TOOLCHAIN_POWER9_GLIBC)),)
+extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
+extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
+ifeq ($(FLAVOUR),headers)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=3.2.0
+extra_configure_switches += --disable-profile
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+ifeq ($(FLAVOUR),full)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=3.2.0
+extra_configure_switches += --disable-profile
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+endif
+
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_POWER8LE_GLIBC) $(TOOLCHAIN_POWER9LE_GLIBC)),)
+extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
+extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
+ifeq ($(FLAVOUR),headers)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=3.2.0
+extra_configure_switches += --disable-profile
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+ifeq ($(FLAVOUR),full)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=3.2.0
+extra_configure_switches += --disable-profile
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+endif
+
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_RISCV64_GLIBC)),)
+extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
+extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
+ifeq ($(FLAVOUR),headers)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=5.8.0
+extra_configure_switches += --disable-profile
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+ifeq ($(FLAVOUR),full)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=5.8.0
+extra_configure_switches += --disable-profile
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+endif
+
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_I586_GLIBC))
+extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
+extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
+ifeq ($(FLAVOUR),headers)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=2.6.36
+extra_configure_switches += --disable-profile
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+ifeq ($(FLAVOUR),full)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=2.6.36
+extra_configure_switches += --disable-profile
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_I686_GLIBC))
+extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
+extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
+ifeq ($(FLAVOUR),headers)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=2.6.36
+extra_configure_switches += --disable-profile
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+ifeq ($(FLAVOUR),full)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=2.6.36
+extra_configure_switches += --disable-profile
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_X86_64_GLIBC))
+extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
+extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
+ifeq ($(FLAVOUR),headers)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=2.6.36
+extra_configure_switches += --disable-profile
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+ifeq ($(FLAVOUR),full)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=2.6.36
+extra_configure_switches += --disable-profile
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+endif
+
+
+extra_configure_switches += libc_cv_slibdir=/lib$(LIBSUFFIX)
+extra_configure_switches += libc_cv_rtlddir=/lib$(LIBSUFFIX)
+
+
+
+$(src_done): $(SRC_ARCHIVE) $(PATCHES_DEP)
+ $(UNPACK_SRC_ARCHIVE)
+ $(APPLY_PATCHES)
+ @touch $@
+
+$(headers_target): $(src_done)
+ @mkdir -p $(headers_dir)
+ @cd $(headers_dir) && $(env_sysroot) $(environment) ../$(src_dir_name)/configure \
+ --prefix=/usr \
+ --build=$(BUILD) \
+ --host=$(TARGET) \
+ $(extra_configure_switches)
+ @cd $(headers_dir) && $(MAKE) -j1 install-headers \
+ install-bootstrap-headers=yes $(env_sysroot)
+ @cd $(headers_dir) && $(environment) $(MAKE) -j1 csu/subdir_lib
+ # ======= install 'lib-names-$(LIB_NAMES_SUFFIX).h' =======
+ @mkdir -p $(sysroot_dir)/usr/include/gnu
+ @install --mode=0644 $(headers_dir)/gnu/lib-names-$(LIB_NAMES_SUFFIX).h $(sysroot_dir)/usr/include/gnu
+ @install --mode=0644 $(SRC_DIR)/include/gnu/stubs.h $(sysroot_dir)/usr/include/gnu
+ # =========================================================
+ @cd $(headers_dir) && $(environment) $(MAKE) -j1 csu/subdir_install $(env_sysroot)
+ @$(environment) $(CC) -nostdlib -nostartfiles -shared -x c /dev/null \
+ -o $(sysroot_dir)/usr/lib$(LIBSUFFIX)/libc.so
+ @echo " $(subst $(TOP_BUILD_DIR_ABS)/,,$(CURDIR))$(if $(FLAVOUR),:$(FLAVOUR),)" >> $(TOOLCHAIN_PATH)/README
+ @touch $@
+
+$(full_target): $(src_done)
+ @mkdir -p $(full_dir)
+ @echo "slibdir=/lib$(LIBSUFFIX)" >> $(full_dir)/configparms
+ @echo "rtlddir=/lib$(LIBSUFFIX)" >> $(full_dir)/configparms
+ @cd $(full_dir) && $(env_sysroot) $(environment) ../$(src_dir_name)/configure \
+ --prefix=/usr \
+ --build=$(BUILD) \
+ --host=$(TARGET) \
+ $(extra_configure_switches)
+ @cd $(full_dir) && $(environment) $(MAKE) all
+ @cd $(full_dir) && $(environment) $(MAKE) -j1 install $(env_sysroot)
+ @rm -f $(sysroot_dir)/usr/share/info/dir
+ @echo " $(subst $(TOP_BUILD_DIR_ABS)/,,$(CURDIR))$(if $(FLAVOUR),:$(FLAVOUR),)" >> $(TOOLCHAIN_PATH)/README
+ @touch $@
Index: core/glibc/2.41/PATCHES
===================================================================
--- core/glibc/2.41/PATCHES (nonexistent)
+++ core/glibc/2.41/PATCHES (revision 76)
@@ -0,0 +1,9 @@
+
+../../../sources/GNU/glibc/patches/glibc-2.41-reenable-DT-HASH.patch -p0
+../../../sources/GNU/glibc/patches/glibc-2.41-i18n.patch -p0
+../../../sources/GNU/glibc/patches/glibc-2.41-locale-no-archive.patch -p0
+../../../sources/GNU/glibc/patches/glibc-2.41-malloc-hooks.patch -p0
+../../../sources/GNU/glibc/patches/glibc-2.41-en_US-no-am-pm.patch -p0
+
+../../../sources/GNU/glibc/patches/glibc-2.41-ppc64-interpreter.patch -p0
+../../../sources/GNU/glibc/patches/glibc-2.41-x86_64-interpreter.patch -p0
Index: core/glibc/2.41
===================================================================
--- core/glibc/2.41 (nonexistent)
+++ core/glibc/2.41 (revision 76)
Property changes on: core/glibc/2.41
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,81 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.rk358x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: core/glibc/2.41-ppc32/Makefile
===================================================================
--- core/glibc/2.41-ppc32/Makefile (nonexistent)
+++ core/glibc/2.41-ppc32/Makefile (revision 76)
@@ -0,0 +1,147 @@
+
+
+COMPONENT_TARGETS = $(TOOLCHAIN_POWER8_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_POWER9_GLIBC)
+
+FLAVOURS = headers full
+
+include ../../../build-system/config.mk
+
+SOURCE_REQUIRES = sources/GNU/glibc
+
+ifeq ($(FLAVOUR),headers)
+REQUIRES = core/linux/6.12.15
+endif
+
+ifeq ($(FLAVOUR),full)
+REQUIRES = core/gcc/14.2.0^second
+endif
+
+# ======= __END_OF_REQUIRES__ =======
+
+tar_xz_archive = $(SRC_PACKAGE_PATH)/GNU/glibc/glibc-2.41.tar.xz
+SRC_ARCHIVE = $(tar_xz_archive)
+SRC_DIR = $(TARGET_BUILD_DIR)/glibc-2.41
+src_dir_name = glibc-2.41
+src_done = $(TARGET_BUILD_DIR)/.source-done
+
+PATCHES = PATCHES
+
+full_dir = $(TARGET_BUILD_DIR)/build-full
+headers_dir = $(TARGET_BUILD_DIR)/build-headers
+
+sysroot_dir = $(TOOLCHAIN_PATH)/$(TARGET)/sys-root
+
+headers_target = $(TARGET_BUILD_DIR)/.headers-installed
+full_target = $(TARGET_BUILD_DIR)/.installed
+
+
+
+ifeq ($(FLAVOUR),headers)
+BUILD_TARGETS = $(headers_target)
+endif
+
+ifeq ($(FLAVOUR),full)
+BUILD_TARGETS = $(full_target)
+endif
+
+include ../../../build-system/core.mk
+
+
+env_sysroot = install_root=$(sysroot_dir)
+
+
+CC = $(CCACHE)$(TOOLCHAIN_PATH)/bin/$(TARGET)-gcc -m32
+CXX = $(CCACHE)$(TOOLCHAIN_PATH)/bin/$(TARGET)-g++ -m32
+
+environment = AS=$(TOOLCHAIN_PATH)/bin/$(TARGET)-as
+environment += LD=$(TOOLCHAIN_PATH)/bin/$(TARGET)-ld
+environment += CC="$(CC)"
+environment += CXX="$(CXX)"
+environment += AR=$(TOOLCHAIN_PATH)/bin/$(TARGET)-ar
+environment += RANLIB=$(TOOLCHAIN_PATH)/bin/$(TARGET)-ranlib
+
+environment += PATH=$(TOOLCHAIN_PATH)/bin:$(PATH)
+
+environment += BUILD_CC="$(CCACHE)/usr/bin/gcc"
+
+LIBSUFFIX =
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_POWER8_GLIBC))
+environment += CFLAGS="-g -O3 -mcpu=power8 -mlong-double-128"
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_POWER9_GLIBC))
+environment += CFLAGS="-g -O3 -mcpu=power9 -mlong-double-128"
+endif
+
+LIBSUFFIX = 32
+
+TARGET32 = $(shell echo $(TARGET) | sed 's/ppc64/ppc/')
+
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_POWER8_GLIBC) $(TOOLCHAIN_POWER9_GLIBC)),)
+extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
+extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
+ifeq ($(FLAVOUR),headers)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=3.2.0
+extra_configure_switches += --disable-profile
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+ifeq ($(FLAVOUR),full)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=3.2.0
+extra_configure_switches += --disable-profile
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+endif
+
+
+extra_configure_switches += libc_cv_slibdir=/lib$(LIBSUFFIX)
+extra_configure_switches += libc_cv_rtlddir=/lib$(LIBSUFFIX)
+
+
+
+$(src_done): $(SRC_ARCHIVE) $(PATCHES_DEP)
+ $(UNPACK_SRC_ARCHIVE)
+ $(APPLY_PATCHES)
+ @touch $@
+
+$(headers_target): $(src_done)
+ @mkdir -p $(headers_dir)
+ @cd $(headers_dir) && $(env_sysroot) $(environment) ../$(src_dir_name)/configure \
+ --prefix=/usr \
+ --build=$(BUILD) \
+ --host=$(TARGET32) \
+ $(extra_configure_switches)
+ @cd $(headers_dir) && $(MAKE) -j1 install-headers \
+ install-bootstrap-headers=yes $(env_sysroot)
+ @cd $(headers_dir) && $(environment) $(MAKE) -j1 csu/subdir_lib
+ # ======= install 'lib-names-32.h' =======
+ @mkdir -p $(sysroot_dir)/usr/include/gnu
+ @install --mode=0644 $(headers_dir)/gnu/lib-names-32.h $(sysroot_dir)/usr/include/gnu
+ # ========================================
+ @cd $(headers_dir) && $(environment) $(MAKE) -j1 csu/subdir_install $(env_sysroot)
+ @$(environment) $(CC) -nostdlib -nostartfiles -shared -x c /dev/null \
+ -o $(sysroot_dir)/usr/lib$(LIBSUFFIX)/libc.so
+ @echo " $(subst $(TOP_BUILD_DIR_ABS)/,,$(CURDIR))$(if $(FLAVOUR),:$(FLAVOUR),)" >> $(TOOLCHAIN_PATH)/README
+ @touch $@
+
+$(full_target): $(src_done)
+ @mkdir -p $(full_dir)
+ @echo "slibdir=/lib$(LIBSUFFIX)" >> $(full_dir)/configparms
+ @echo "rtlddir=/lib$(LIBSUFFIX)" >> $(full_dir)/configparms
+ @cd $(full_dir) && $(env_sysroot) $(environment) ../$(src_dir_name)/configure \
+ --prefix=/usr \
+ --build=$(BUILD) \
+ --host=$(TARGET32) \
+ $(extra_configure_switches)
+ @cd $(full_dir) && $(environment) $(MAKE) all
+ @cd $(full_dir) && $(environment) $(MAKE) -j1 install $(env_sysroot)
+ @echo " $(subst $(TOP_BUILD_DIR_ABS)/,,$(CURDIR))$(if $(FLAVOUR),:$(FLAVOUR),)" >> $(TOOLCHAIN_PATH)/README
+ @touch $@
Index: core/glibc/2.41-ppc32/PATCHES
===================================================================
--- core/glibc/2.41-ppc32/PATCHES (nonexistent)
+++ core/glibc/2.41-ppc32/PATCHES (revision 76)
@@ -0,0 +1,9 @@
+
+../../../sources/GNU/glibc/patches/glibc-2.41-reenable-DT-HASH.patch -p0
+../../../sources/GNU/glibc/patches/glibc-2.41-i18n.patch -p0
+../../../sources/GNU/glibc/patches/glibc-2.41-locale-no-archive.patch -p0
+../../../sources/GNU/glibc/patches/glibc-2.41-malloc-hooks.patch -p0
+../../../sources/GNU/glibc/patches/glibc-2.41-en_US-no-am-pm.patch -p0
+
+../../../sources/GNU/glibc/patches/glibc-2.41-ppc64-interpreter.patch -p0
+../../../sources/GNU/glibc/patches/glibc-2.41-x86_64-interpreter.patch -p0
Index: core/glibc/2.41-ppc32
===================================================================
--- core/glibc/2.41-ppc32 (nonexistent)
+++ core/glibc/2.41-ppc32 (revision 76)
Property changes on: core/glibc/2.41-ppc32
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,81 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.rk358x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: core/glibc/2.41-x86_32/Makefile
===================================================================
--- core/glibc/2.41-x86_32/Makefile (nonexistent)
+++ core/glibc/2.41-x86_32/Makefile (revision 76)
@@ -0,0 +1,141 @@
+
+
+COMPONENT_TARGETS = $(TOOLCHAIN_X86_64_GLIBC)
+
+FLAVOURS = headers full
+
+include ../../../build-system/config.mk
+
+SOURCE_REQUIRES = sources/GNU/glibc
+
+ifeq ($(FLAVOUR),headers)
+REQUIRES = core/linux/6.12.15
+endif
+
+ifeq ($(FLAVOUR),full)
+REQUIRES = core/gcc/14.2.0^second
+endif
+
+# ======= __END_OF_REQUIRES__ =======
+
+tar_xz_archive = $(SRC_PACKAGE_PATH)/GNU/glibc/glibc-2.41.tar.xz
+SRC_ARCHIVE = $(tar_xz_archive)
+SRC_DIR = $(TARGET_BUILD_DIR)/glibc-2.41
+src_dir_name = glibc-2.41
+src_done = $(TARGET_BUILD_DIR)/.source-done
+
+PATCHES = PATCHES
+
+full_dir = $(TARGET_BUILD_DIR)/build-full
+headers_dir = $(TARGET_BUILD_DIR)/build-headers
+
+sysroot_dir = $(TOOLCHAIN_PATH)/$(TARGET)/sys-root
+
+headers_target = $(TARGET_BUILD_DIR)/.headers-installed
+full_target = $(TARGET_BUILD_DIR)/.installed
+
+
+
+ifeq ($(FLAVOUR),headers)
+BUILD_TARGETS = $(headers_target)
+endif
+
+ifeq ($(FLAVOUR),full)
+BUILD_TARGETS = $(full_target)
+endif
+
+include ../../../build-system/core.mk
+
+
+env_sysroot = install_root=$(sysroot_dir)
+
+
+CC = $(CCACHE)$(TOOLCHAIN_PATH)/bin/$(TARGET)-gcc -m32
+CXX = $(CCACHE)$(TOOLCHAIN_PATH)/bin/$(TARGET)-g++ -m32
+
+environment = AS=$(TOOLCHAIN_PATH)/bin/$(TARGET)-as
+environment += LD=$(TOOLCHAIN_PATH)/bin/$(TARGET)-ld
+environment += CC="$(CC)"
+environment += CXX="$(CXX)"
+environment += AR=$(TOOLCHAIN_PATH)/bin/$(TARGET)-ar
+environment += RANLIB=$(TOOLCHAIN_PATH)/bin/$(TARGET)-ranlib
+
+environment += PATH=$(TOOLCHAIN_PATH)/bin:$(PATH)
+
+environment += BUILD_CC="$(CCACHE)/usr/bin/gcc"
+
+LIBSUFFIX =
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_X86_64_GLIBC))
+environment += CFLAGS="-g -O3 -march=i686 -mtune=i686"
+LIBSUFFIX = 32
+endif
+
+TARGET32 = $(shell echo $(TARGET) | sed 's/x86_64/i686/')
+
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_X86_64_GLIBC))
+extra_configure_switches = --libdir=/usr/lib$(LIBSUFFIX)
+extra_configure_switches += --with-headers=$(sysroot_dir)/usr/include
+ifeq ($(FLAVOUR),headers)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=2.6.36
+extra_configure_switches += --disable-profile
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+ifeq ($(FLAVOUR),full)
+extra_configure_switches += --with-binutils=$(TOOLCHAIN_PATH)/bin
+extra_configure_switches += --enable-kernel=2.6.36
+extra_configure_switches += --disable-profile
+extra_configure_switches += --enable-bind-now
+extra_configure_switches += --without-gd
+extra_configure_switches += --without-cvs
+endif
+endif
+
+
+extra_configure_switches += libc_cv_slibdir=/lib$(LIBSUFFIX)
+extra_configure_switches += libc_cv_rtlddir=/lib$(LIBSUFFIX)
+
+
+
+$(src_done): $(SRC_ARCHIVE) $(PATCHES_DEP)
+ $(UNPACK_SRC_ARCHIVE)
+ $(APPLY_PATCHES)
+ @touch $@
+
+$(headers_target): $(src_done)
+ @mkdir -p $(headers_dir)
+ @cd $(headers_dir) && $(env_sysroot) $(environment) ../$(src_dir_name)/configure \
+ --prefix=/usr \
+ --build=$(BUILD) \
+ --host=$(TARGET32) \
+ $(extra_configure_switches)
+ @cd $(headers_dir) && $(MAKE) -j1 install-headers \
+ install-bootstrap-headers=yes $(env_sysroot)
+ @cd $(headers_dir) && $(environment) $(MAKE) -j1 csu/subdir_lib
+ # ======= install 'lib-names-32.h' =======
+ @mkdir -p $(sysroot_dir)/usr/include/gnu
+ @install --mode=0644 $(headers_dir)/gnu/lib-names-32.h $(sysroot_dir)/usr/include/gnu
+ # ========================================
+ @cd $(headers_dir) && $(environment) $(MAKE) -j1 csu/subdir_install $(env_sysroot)
+ @$(environment) $(CC) -nostdlib -nostartfiles -shared -x c /dev/null \
+ -o $(sysroot_dir)/usr/lib$(LIBSUFFIX)/libc.so
+ @echo " $(subst $(TOP_BUILD_DIR_ABS)/,,$(CURDIR))$(if $(FLAVOUR),:$(FLAVOUR),)" >> $(TOOLCHAIN_PATH)/README
+ @touch $@
+
+$(full_target): $(src_done)
+ @mkdir -p $(full_dir)
+ @echo "slibdir=/lib$(LIBSUFFIX)" >> $(full_dir)/configparms
+ @echo "rtlddir=/lib$(LIBSUFFIX)" >> $(full_dir)/configparms
+ @cd $(full_dir) && $(env_sysroot) $(environment) ../$(src_dir_name)/configure \
+ --prefix=/usr \
+ --build=$(BUILD) \
+ --host=$(TARGET32) \
+ $(extra_configure_switches)
+ @cd $(full_dir) && $(environment) $(MAKE) all
+ @cd $(full_dir) && $(environment) $(MAKE) -j1 install $(env_sysroot)
+ @echo " $(subst $(TOP_BUILD_DIR_ABS)/,,$(CURDIR))$(if $(FLAVOUR),:$(FLAVOUR),)" >> $(TOOLCHAIN_PATH)/README
+ @touch $@
Index: core/glibc/2.41-x86_32/PATCHES
===================================================================
--- core/glibc/2.41-x86_32/PATCHES (nonexistent)
+++ core/glibc/2.41-x86_32/PATCHES (revision 76)
@@ -0,0 +1,9 @@
+
+../../../sources/GNU/glibc/patches/glibc-2.41-reenable-DT-HASH.patch -p0
+../../../sources/GNU/glibc/patches/glibc-2.41-i18n.patch -p0
+../../../sources/GNU/glibc/patches/glibc-2.41-locale-no-archive.patch -p0
+../../../sources/GNU/glibc/patches/glibc-2.41-malloc-hooks.patch -p0
+../../../sources/GNU/glibc/patches/glibc-2.41-en_US-no-am-pm.patch -p0
+
+../../../sources/GNU/glibc/patches/glibc-2.41-ppc64-interpreter.patch -p0
+../../../sources/GNU/glibc/patches/glibc-2.41-x86_64-interpreter.patch -p0
Index: core/glibc/2.41-x86_32
===================================================================
--- core/glibc/2.41-x86_32 (nonexistent)
+++ core/glibc/2.41-x86_32 (revision 76)
Property changes on: core/glibc/2.41-x86_32
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,81 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.rk358x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: core/linux/6.6.52/Makefile
===================================================================
--- core/linux/6.6.52/Makefile (revision 75)
+++ core/linux/6.6.52/Makefile (nonexistent)
@@ -1,125 +0,0 @@
-
-COMPONENT_TARGETS = $(TOOLCHAIN_A1X_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_A2X_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_H3_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_H5_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_IMX6_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_IMX6ULL_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_JZ47XX_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_P5600_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_M1000_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_OMAP543X_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_AM335X_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_RK328X_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_S8XX_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_S9XX_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_A9XX_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_A311X_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_RK33XX_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_RK339X_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_RK358X_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_A33XX_GLIBC)
-
-COMPONENT_TARGETS += $(TOOLCHAIN_PPC8_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_PPC9_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_POWER8_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_POWER9_GLIBC)
-
-COMPONENT_TARGETS += $(TOOLCHAIN_POWER8LE_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_POWER9LE_GLIBC)
-
-COMPONENT_TARGETS += $(TOOLCHAIN_RISCV64_GLIBC)
-
-COMPONENT_TARGETS += $(TOOLCHAIN_I586_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_I686_GLIBC)
-COMPONENT_TARGETS += $(TOOLCHAIN_X86_64_GLIBC)
-
-
-include ../../../build-system/config.mk
-
-
-SOURCE_REQUIRES = sources/Linux/v6.x
-
-REQUIRES = core/gcc/14.2.0^static
-
-# ======= __END_OF_REQUIRES__ =======
-
-tar_xz_archive = $(SRC_PACKAGE_PATH)/Linux/v6.x/linux-6.6.52.tar.xz
-SRC_ARCHIVE = $(tar_xz_archive)
-SRC_DIR = $(TARGET_BUILD_DIR)/linux-6.6.52
-src_done = $(TARGET_BUILD_DIR)/.source-done
-
-PATCHES = PATCHES
-
-sysroot_dir = $(TOOLCHAIN_PATH)/$(TARGET)/sys-root
-
-
-headers_target = $(TARGET_BUILD_DIR)/.headers-installed
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_A1X_GLIBC) $(TOOLCHAIN_A2X_GLIBC) \
- $(TOOLCHAIN_H3_GLIBC) $(TOOLCHAIN_IMX6_GLIBC)\
- $(TOOLCHAIN_IMX6ULL_GLIBC) $(TOOLCHAIN_OMAP543X_GLIBC)\
- $(TOOLCHAIN_AM335X_GLIBC) $(TOOLCHAIN_RK328X_GLIBC) \
- $(TOOLCHAIN_S8XX_GLIBC) $(TOOLCHAIN_A9XX_GLIBC) \
- $(TOOLCHAIN_A33XX_GLIBC)),)
-arch = arm
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_H5_GLIBC) \
- $(TOOLCHAIN_S9XX_GLIBC) $(TOOLCHAIN_A311X_GLIBC) \
- $(TOOLCHAIN_RK33XX_GLIBC) $(TOOLCHAIN_RK339X_GLIBC) \
- $(TOOLCHAIN_RK358X_GLIBC) $(TOOLCHAIN_M1000_GLIBC)),)
-arch = arm64
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_JZ47XX_GLIBC) $(TOOLCHAIN_P5600_GLIBC)),)
-arch = mips
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_PPC8_GLIBC) $(TOOLCHAIN_PPC9_GLIBC) \
- $(TOOLCHAIN_POWER8_GLIBC) $(TOOLCHAIN_POWER9_GLIBC) \
- $(TOOLCHAIN_POWER8LE_GLIBC) $(TOOLCHAIN_POWER9LE_GLIBC)),)
-arch = powerpc
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_RISCV64_GLIBC)),)
-arch = riscv
-endif
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_X86_64_GLIBC) \
- $(TOOLCHAIN_I686_GLIBC) \
- $(TOOLCHAIN_I586_GLIBC)),)
-arch = x86
-endif
-
-
-BUILD_TARGETS = $(headers_target)
-
-
-include ../../../build-system/core.mk
-
-
-
-$(src_done): $(SRC_ARCHIVE) $(PATCHES_DEP)
- $(UNPACK_SRC_ARCHIVE)
- $(APPLY_PATCHES)
- @touch $@
-
-$(SRC_DIR)/include/generated/uapi/linux/version.h: $(src_done)
- @touch $(SRC_DIR)/.config
- @$(MAKE) -C $(SRC_DIR) include/generated/uapi/linux/version.h
-
-$(sysroot_dir)/usr/include/linux/autoconf.h: $(SRC_DIR)/include/generated/uapi/linux/version.h
- @$(MAKE) -C $(SRC_DIR) headers_install \
- ARCH=$(arch) CROSS_COMPILE=$(TOOLCHAIN_PATH)/bin/$(TARGET)- \
- INSTALL_HDR_PATH=$(sysroot_dir)/usr
- @touch $@
-
-$(headers_target): $(sysroot_dir)/usr/include/linux/autoconf.h
- @( cd $(sysroot_dir)/usr/include ; \
- for file in `find . -name *.install*` ; do \
- rm -f $$file ; \
- done ; \
- )
- @echo " $(subst $(TOP_BUILD_DIR_ABS)/,,$(CURDIR)):headers" >> $(TOOLCHAIN_PATH)/README
- @touch $@
Index: core/linux/6.6.52
===================================================================
--- core/linux/6.6.52 (revision 75)
+++ core/linux/6.6.52 (nonexistent)
Property changes on: core/linux/6.6.52
___________________________________________________________________
Deleted: svn:ignore
## -1,81 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.rk358x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: core/linux/6.12.15/Makefile
===================================================================
--- core/linux/6.12.15/Makefile (nonexistent)
+++ core/linux/6.12.15/Makefile (revision 76)
@@ -0,0 +1,125 @@
+
+COMPONENT_TARGETS = $(TOOLCHAIN_A1X_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_A2X_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_H3_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_H5_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_IMX6_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_IMX6ULL_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_JZ47XX_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_P5600_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_M1000_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_OMAP543X_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_AM335X_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_RK328X_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_S8XX_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_S9XX_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_A9XX_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_A311X_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_RK33XX_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_RK339X_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_RK358X_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_A33XX_GLIBC)
+
+COMPONENT_TARGETS += $(TOOLCHAIN_PPC8_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_PPC9_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_POWER8_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_POWER9_GLIBC)
+
+COMPONENT_TARGETS += $(TOOLCHAIN_POWER8LE_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_POWER9LE_GLIBC)
+
+COMPONENT_TARGETS += $(TOOLCHAIN_RISCV64_GLIBC)
+
+COMPONENT_TARGETS += $(TOOLCHAIN_I586_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_I686_GLIBC)
+COMPONENT_TARGETS += $(TOOLCHAIN_X86_64_GLIBC)
+
+
+include ../../../build-system/config.mk
+
+
+SOURCE_REQUIRES = sources/Linux/v6.x
+
+REQUIRES = core/gcc/14.2.0^static
+
+# ======= __END_OF_REQUIRES__ =======
+
+tar_xz_archive = $(SRC_PACKAGE_PATH)/Linux/v6.x/linux-6.12.15.tar.xz
+SRC_ARCHIVE = $(tar_xz_archive)
+SRC_DIR = $(TARGET_BUILD_DIR)/linux-6.12.15
+src_done = $(TARGET_BUILD_DIR)/.source-done
+
+PATCHES = PATCHES
+
+sysroot_dir = $(TOOLCHAIN_PATH)/$(TARGET)/sys-root
+
+
+headers_target = $(TARGET_BUILD_DIR)/.headers-installed
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_A1X_GLIBC) $(TOOLCHAIN_A2X_GLIBC) \
+ $(TOOLCHAIN_H3_GLIBC) $(TOOLCHAIN_IMX6_GLIBC)\
+ $(TOOLCHAIN_IMX6ULL_GLIBC) $(TOOLCHAIN_OMAP543X_GLIBC)\
+ $(TOOLCHAIN_AM335X_GLIBC) $(TOOLCHAIN_RK328X_GLIBC) \
+ $(TOOLCHAIN_S8XX_GLIBC) $(TOOLCHAIN_A9XX_GLIBC) \
+ $(TOOLCHAIN_A33XX_GLIBC)),)
+arch = arm
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_H5_GLIBC) \
+ $(TOOLCHAIN_S9XX_GLIBC) $(TOOLCHAIN_A311X_GLIBC) \
+ $(TOOLCHAIN_RK33XX_GLIBC) $(TOOLCHAIN_RK339X_GLIBC) \
+ $(TOOLCHAIN_RK358X_GLIBC) $(TOOLCHAIN_M1000_GLIBC)),)
+arch = arm64
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_JZ47XX_GLIBC) $(TOOLCHAIN_P5600_GLIBC)),)
+arch = mips
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_PPC8_GLIBC) $(TOOLCHAIN_PPC9_GLIBC) \
+ $(TOOLCHAIN_POWER8_GLIBC) $(TOOLCHAIN_POWER9_GLIBC) \
+ $(TOOLCHAIN_POWER8LE_GLIBC) $(TOOLCHAIN_POWER9LE_GLIBC)),)
+arch = powerpc
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_RISCV64_GLIBC)),)
+arch = riscv
+endif
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_X86_64_GLIBC) \
+ $(TOOLCHAIN_I686_GLIBC) \
+ $(TOOLCHAIN_I586_GLIBC)),)
+arch = x86
+endif
+
+
+BUILD_TARGETS = $(headers_target)
+
+
+include ../../../build-system/core.mk
+
+
+
+$(src_done): $(SRC_ARCHIVE) $(PATCHES_DEP)
+ $(UNPACK_SRC_ARCHIVE)
+ $(APPLY_PATCHES)
+ @touch $@
+
+$(SRC_DIR)/include/generated/uapi/linux/version.h: $(src_done)
+ @touch $(SRC_DIR)/.config
+ @$(MAKE) -C $(SRC_DIR) include/generated/uapi/linux/version.h
+
+$(sysroot_dir)/usr/include/linux/autoconf.h: $(SRC_DIR)/include/generated/uapi/linux/version.h
+ @$(MAKE) -C $(SRC_DIR) headers_install \
+ ARCH=$(arch) CROSS_COMPILE=$(TOOLCHAIN_PATH)/bin/$(TARGET)- \
+ INSTALL_HDR_PATH=$(sysroot_dir)/usr
+ @touch $@
+
+$(headers_target): $(sysroot_dir)/usr/include/linux/autoconf.h
+ @( cd $(sysroot_dir)/usr/include ; \
+ for file in `find . -name *.install*` ; do \
+ rm -f $$file ; \
+ done ; \
+ )
+ @echo " $(subst $(TOP_BUILD_DIR_ABS)/,,$(CURDIR)):headers" >> $(TOOLCHAIN_PATH)/README
+ @touch $@
Index: core/linux/6.12.15/PATCHES
===================================================================
Index: core/linux/6.12.15
===================================================================
--- core/linux/6.12.15 (nonexistent)
+++ core/linux/6.12.15 (revision 76)
Property changes on: core/linux/6.12.15
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,81 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.rk358x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: core/linux/Baikal/M1000/m1-6.6.32-6.6.161/Makefile
===================================================================
--- core/linux/Baikal/M1000/m1-6.6.32-6.6.161/Makefile (revision 75)
+++ core/linux/Baikal/M1000/m1-6.6.32-6.6.161/Makefile (nonexistent)
@@ -1,60 +0,0 @@
-
-
-COMPONENT_TARGETS = $(TOOLCHAIN_M1000_GLIBC)
-
-
-include ../../../../../build-system/config.mk
-
-
-SOURCE_REQUIRES = sources/Linux/Baikal/M1000
-
-
-REQUIRES = core/gcc/14.2.0^static
-
-# ======= __END_OF_REQUIRES__ =======
-
-tar_xz_archive = $(SRC_PACKAGE_PATH)/Linux/Baikal/M1000/linux-m1-6.6.32-6.6.161.tar.xz
-SRC_ARCHIVE = $(tar_xz_archive)
-SRC_DIR = $(TARGET_BUILD_DIR)/linux-m1-6.6.32-6.6.161
-src_done = $(TARGET_BUILD_DIR)/.source-done
-
-sysroot_dir = $(TOOLCHAIN_PATH)/$(TARGET)/sys-root
-
-headers_target = $(TARGET_BUILD_DIR)/.headers-installed
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_M1000_GLIBC)),)
-arch = arm64
-endif
-
-
-BUILD_TARGETS = $(headers_target)
-
-
-include ../../../../../build-system/core.mk
-
-
-
-$(src_done): $(SRC_ARCHIVE) $(PATCHES_DEP)
- $(UNPACK_SRC_ARCHIVE)
- @touch $@
-
-$(SRC_DIR)/include/generated/uapi/linux/version.h: $(src_done)
- @touch $(SRC_DIR)/.config
- @$(MAKE) -C $(SRC_DIR) \
- ARCH=$(arch) CROSS_COMPILE=$(TOOLCHAIN_PATH)/bin/$(TARGET)- \
- include/generated/uapi/linux/version.h
-
-$(sysroot_dir)/usr/include/linux/autoconf.h: $(SRC_DIR)/include/generated/uapi/linux/version.h
- @$(MAKE) -C $(SRC_DIR) headers_install \
- ARCH=$(arch) CROSS_COMPILE=$(TOOLCHAIN_PATH)/bin/$(TARGET)- \
- INSTALL_HDR_PATH=$(sysroot_dir)/usr
- @touch $@
-
-$(headers_target): $(sysroot_dir)/usr/include/linux/autoconf.h
- @( cd $(sysroot_dir)/usr/include ; \
- for file in `find . -name *.install*` ; do \
- rm -f $$file ; \
- done ; \
- )
- @echo " $(subst $(TOP_BUILD_DIR_ABS)/,,$(CURDIR)):headers" >> $(TOOLCHAIN_PATH)/README
- @touch $@
Index: core/linux/Baikal/M1000/m1-6.6.32-6.6.161
===================================================================
--- core/linux/Baikal/M1000/m1-6.6.32-6.6.161 (revision 75)
+++ core/linux/Baikal/M1000/m1-6.6.32-6.6.161 (nonexistent)
Property changes on: core/linux/Baikal/M1000/m1-6.6.32-6.6.161
___________________________________________________________________
Deleted: svn:ignore
## -1,81 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.rk358x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: core/linux/Baikal/M1000/m1-6.6.63-6.6.236/Makefile
===================================================================
--- core/linux/Baikal/M1000/m1-6.6.63-6.6.236/Makefile (nonexistent)
+++ core/linux/Baikal/M1000/m1-6.6.63-6.6.236/Makefile (revision 76)
@@ -0,0 +1,60 @@
+
+
+COMPONENT_TARGETS = $(TOOLCHAIN_M1000_GLIBC)
+
+
+include ../../../../../build-system/config.mk
+
+
+SOURCE_REQUIRES = sources/Linux/Baikal/M1000
+
+
+REQUIRES = core/gcc/14.2.0^static
+
+# ======= __END_OF_REQUIRES__ =======
+
+tar_xz_archive = $(SRC_PACKAGE_PATH)/Linux/Baikal/M1000/linux-m1-6.6.63-6.6.236.tar.xz
+SRC_ARCHIVE = $(tar_xz_archive)
+SRC_DIR = $(TARGET_BUILD_DIR)/linux-m1-6.6.63-6.6.236
+src_done = $(TARGET_BUILD_DIR)/.source-done
+
+sysroot_dir = $(TOOLCHAIN_PATH)/$(TARGET)/sys-root
+
+headers_target = $(TARGET_BUILD_DIR)/.headers-installed
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_M1000_GLIBC)),)
+arch = arm64
+endif
+
+
+BUILD_TARGETS = $(headers_target)
+
+
+include ../../../../../build-system/core.mk
+
+
+
+$(src_done): $(SRC_ARCHIVE) $(PATCHES_DEP)
+ $(UNPACK_SRC_ARCHIVE)
+ @touch $@
+
+$(SRC_DIR)/include/generated/uapi/linux/version.h: $(src_done)
+ @touch $(SRC_DIR)/.config
+ @$(MAKE) -C $(SRC_DIR) \
+ ARCH=$(arch) CROSS_COMPILE=$(TOOLCHAIN_PATH)/bin/$(TARGET)- \
+ include/generated/uapi/linux/version.h
+
+$(sysroot_dir)/usr/include/linux/autoconf.h: $(SRC_DIR)/include/generated/uapi/linux/version.h
+ @$(MAKE) -C $(SRC_DIR) headers_install \
+ ARCH=$(arch) CROSS_COMPILE=$(TOOLCHAIN_PATH)/bin/$(TARGET)- \
+ INSTALL_HDR_PATH=$(sysroot_dir)/usr
+ @touch $@
+
+$(headers_target): $(sysroot_dir)/usr/include/linux/autoconf.h
+ @( cd $(sysroot_dir)/usr/include ; \
+ for file in `find . -name *.install*` ; do \
+ rm -f $$file ; \
+ done ; \
+ )
+ @echo " $(subst $(TOP_BUILD_DIR_ABS)/,,$(CURDIR)):headers" >> $(TOOLCHAIN_PATH)/README
+ @touch $@
Index: core/linux/Baikal/M1000/m1-6.6.63-6.6.236
===================================================================
--- core/linux/Baikal/M1000/m1-6.6.63-6.6.236 (nonexistent)
+++ core/linux/Baikal/M1000/m1-6.6.63-6.6.236 (revision 76)
Property changes on: core/linux/Baikal/M1000/m1-6.6.63-6.6.236
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,81 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.rk358x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: core/newlib/4.4.0.20231231/PATCHES
===================================================================
--- core/newlib/4.4.0.20231231/PATCHES (revision 75)
+++ core/newlib/4.4.0.20231231/PATCHES (nonexistent)
@@ -1,2 +0,0 @@
-
-../../../sources/newlib/patches/newlib-4.4.0.20231231-riscv.patch -p0
Index: core/newlib/4.4.0.20231231/Makefile
===================================================================
--- core/newlib/4.4.0.20231231/Makefile (revision 75)
+++ core/newlib/4.4.0.20231231/Makefile (nonexistent)
@@ -1,419 +0,0 @@
-
-
-COMPONENT_TARGETS = $(TOOLCHAIN_ARM32_NEWLIB)
-COMPONENT_TARGETS += $(TOOLCHAIN_A33XX_NEWLIB)
-COMPONENT_TARGETS += $(TOOLCHAIN_A9XX_NEWLIB)
-COMPONENT_TARGETS += $(TOOLCHAIN_H5_NEWLIB)
-COMPONENT_TARGETS += $(TOOLCHAIN_S9XX_NEWLIB)
-COMPONENT_TARGETS += $(TOOLCHAIN_RK33XX_NEWLIB)
-COMPONENT_TARGETS += $(TOOLCHAIN_M1000_NEWLIB)
-COMPONENT_TARGETS += $(TOOLCHAIN_AT91SAM7S_NEWLIB)
-COMPONENT_TARGETS += $(TOOLCHAIN_RISCV64_NEWLIB)
-
-FLAVOURS = nano full
-
-
-include ../../../build-system/config.mk
-
-
-SOURCE_REQUIRES = sources/newlib
-
-ifeq ($(FLAVOUR),nano)
-REQUIRES = core/gcc/14.2.0^static
-endif
-ifeq ($(FLAVOUR),full)
-REQUIRES = core/newlib/4.4.0.20231231^nano
-endif
-
-# ======= __END_OF_REQUIRES__ =======
-
-tar_gz_archive = $(SRC_PACKAGE_PATH)/newlib/newlib-4.4.0.20231231.tar.gz
-SRC_ARCHIVE = $(tar_gz_archive)
-SRC_DIR = $(TARGET_BUILD_DIR)/newlib-4.4.0.20231231
-src_dir_name = newlib-4.4.0.20231231
-src_done = $(TARGET_BUILD_DIR)/.source-done
-
-PATCHES = PATCHES
-
-build_dir = $(TARGET_BUILD_DIR)/newlib
-build_gloss_dir = $(TARGET_BUILD_DIR)/libgloss
-build_nano_dir = $(TARGET_BUILD_DIR)/nano
-
-install_dir = $(TOOLCHAIN_PATH)/$(TARGET)
-
-build_nano_target = $(TARGET_BUILD_DIR)/.nano-built
-nano_target = $(TARGET_BUILD_DIR)/.nano-installed
-
-build_target = $(TARGET_BUILD_DIR)/.built
-full_target = $(TARGET_BUILD_DIR)/.installed
-
-
-
-ifeq ($(FLAVOUR),nano)
-BUILD_TARGETS = $(build_nano_target)
-BUILD_TARGETS += $(nano_target)
-endif
-
-ifeq ($(FLAVOUR),full)
-BUILD_TARGETS = $(build_target)
-BUILD_TARGETS += $(full_target)
-endif
-
-include ../../../build-system/core.mk
-
-
-environment = AS="$(TOOLCHAIN_PATH)/bin/$(TARGET)-as"
-environment += LD="$(TOOLCHAIN_PATH)/bin/$(TARGET)-ld"
-environment += CC="$(CCACHE)$(TOOLCHAIN_PATH)/bin/$(TARGET)-gcc"
-environment += AR="$(TOOLCHAIN_PATH)/bin/$(TARGET)-ar"
-environment += RANLIB="$(TOOLCHAIN_PATH)/bin/$(TARGET)-ranlib"
-
-environment += PATH_FIG2DEV="/usr/bin:/usr/X11R6/bin:/usr/share/texmf/bin"
-environment += PATH="$(TOOLCHAIN_PATH)/bin:$(PATH):$(PATH_FIG2DEV)"
-# =============
-# need for fig2dev and documentation (see: ../.config).
-
-environment += BUILD_CC="$(CCACHE)/usr/bin/gcc"
-environment += TARGET_CFLAGS="-g -O2 -ffunction-sections -fdata-sections"
-environment += CPPFLAGS="-I$(TOOLCHAIN_PATH)/$(TARGET)/include"
-
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_ARM32_NEWLIB))
-extra_configure_switches = --enable-multilib
-extra_configure_switches += --with-gnu-as
-extra_configure_switches += --with-gnu-ld
-extra_configure_switches += --disable-nls
-extra_configure_switches += --disable-shared
-extra_configure_switches += --disable-newlib-supplied-sycalls
-ifeq ($(FLAVOUR),full)
-extra_configure_switches += --enable-newlib-io-long-long
-extra_configure_switches += --enable-newlib-register-fini
-extra_configure_switches += --enable-newlib-io-c99-formats
-extra_configure_switches += --enable-newlib-io-pos-args
-extra_configure_switches += --enable-newlib-multithread
-endif
-ifeq ($(FLAVOUR),nano)
-extra_configure_switches += --enable-newlib-reent-small
-extra_configure_switches += --disable-newlib-fvwrite-in-streamio
-extra_configure_switches += --disable-newlib-fseek-optimization
-extra_configure_switches += --disable-newlib-wide-orient
-extra_configure_switches += --enable-newlib-nano-malloc
-extra_configure_switches += --disable-newlib-unbuf-stream-opt
-extra_configure_switches += --enable-lite-exit
-extra_configure_switches += --enable-newlib-global-atexit
-extra_configure_switches += --enable-newlib-nano-formatted-io
-endif
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A33XX_NEWLIB))
-extra_configure_switches = --enable-multilib
-extra_configure_switches += --with-gnu-as
-extra_configure_switches += --with-gnu-ld
-extra_configure_switches += --disable-nls
-extra_configure_switches += --disable-shared
-extra_configure_switches += --disable-newlib-supplied-sycalls
-ifeq ($(FLAVOUR),full)
-extra_configure_switches += --enable-newlib-io-long-long
-extra_configure_switches += --enable-newlib-register-fini
-extra_configure_switches += --enable-newlib-io-c99-formats
-extra_configure_switches += --enable-newlib-io-pos-args
-extra_configure_switches += --enable-newlib-multithread
-endif
-ifeq ($(FLAVOUR),nano)
-extra_configure_switches += --enable-newlib-reent-small
-extra_configure_switches += --disable-newlib-fvwrite-in-streamio
-extra_configure_switches += --disable-newlib-fseek-optimization
-extra_configure_switches += --disable-newlib-wide-orient
-extra_configure_switches += --enable-newlib-nano-malloc
-extra_configure_switches += --disable-newlib-unbuf-stream-opt
-extra_configure_switches += --enable-lite-exit
-extra_configure_switches += --enable-newlib-global-atexit
-extra_configure_switches += --enable-newlib-nano-formatted-io
-endif
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A9XX_NEWLIB))
-extra_configure_switches = --enable-multilib
-extra_configure_switches += --with-gnu-as
-extra_configure_switches += --with-gnu-ld
-extra_configure_switches += --disable-nls
-extra_configure_switches += --disable-shared
-extra_configure_switches += --disable-newlib-supplied-sycalls
-ifeq ($(FLAVOUR),full)
-extra_configure_switches += --enable-newlib-io-long-long
-extra_configure_switches += --enable-newlib-register-fini
-extra_configure_switches += --enable-newlib-io-c99-formats
-extra_configure_switches += --enable-newlib-io-pos-args
-extra_configure_switches += --enable-newlib-multithread
-endif
-ifeq ($(FLAVOUR),nano)
-extra_configure_switches += --enable-newlib-reent-small
-extra_configure_switches += --disable-newlib-fvwrite-in-streamio
-extra_configure_switches += --disable-newlib-fseek-optimization
-extra_configure_switches += --disable-newlib-wide-orient
-extra_configure_switches += --enable-newlib-nano-malloc
-extra_configure_switches += --disable-newlib-unbuf-stream-opt
-extra_configure_switches += --enable-lite-exit
-extra_configure_switches += --enable-newlib-global-atexit
-extra_configure_switches += --enable-newlib-nano-formatted-io
-endif
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_H5_NEWLIB))
-extra_configure_switches = --enable-multilib
-extra_configure_switches += --with-gnu-as
-extra_configure_switches += --with-gnu-ld
-extra_configure_switches += --disable-nls
-extra_configure_switches += --disable-shared
-extra_configure_switches += --disable-newlib-supplied-sycalls
-ifeq ($(FLAVOUR),full)
-extra_configure_switches += --enable-newlib-io-long-long
-extra_configure_switches += --enable-newlib-register-fini
-extra_configure_switches += --enable-newlib-io-c99-formats
-extra_configure_switches += --enable-newlib-io-pos-args
-extra_configure_switches += --enable-newlib-multithread
-endif
-ifeq ($(FLAVOUR),nano)
-extra_configure_switches += --enable-newlib-reent-small
-extra_configure_switches += --disable-newlib-fvwrite-in-streamio
-extra_configure_switches += --disable-newlib-fseek-optimization
-extra_configure_switches += --disable-newlib-wide-orient
-extra_configure_switches += --enable-newlib-nano-malloc
-extra_configure_switches += --disable-newlib-unbuf-stream-opt
-extra_configure_switches += --enable-lite-exit
-extra_configure_switches += --enable-newlib-global-atexit
-extra_configure_switches += --enable-newlib-nano-formatted-io
-endif
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_S9XX_NEWLIB))
-extra_configure_switches = --enable-multilib
-extra_configure_switches += --with-gnu-as
-extra_configure_switches += --with-gnu-ld
-extra_configure_switches += --disable-nls
-extra_configure_switches += --disable-shared
-extra_configure_switches += --disable-newlib-supplied-sycalls
-ifeq ($(FLAVOUR),full)
-extra_configure_switches += --enable-newlib-io-long-long
-extra_configure_switches += --enable-newlib-register-fini
-extra_configure_switches += --enable-newlib-io-c99-formats
-extra_configure_switches += --enable-newlib-io-pos-args
-extra_configure_switches += --enable-newlib-multithread
-endif
-ifeq ($(FLAVOUR),nano)
-extra_configure_switches += --enable-newlib-reent-small
-extra_configure_switches += --disable-newlib-fvwrite-in-streamio
-extra_configure_switches += --disable-newlib-fseek-optimization
-extra_configure_switches += --disable-newlib-wide-orient
-extra_configure_switches += --enable-newlib-nano-malloc
-extra_configure_switches += --disable-newlib-unbuf-stream-opt
-extra_configure_switches += --enable-lite-exit
-extra_configure_switches += --enable-newlib-global-atexit
-extra_configure_switches += --enable-newlib-nano-formatted-io
-endif
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_RK33XX_NEWLIB))
-extra_configure_switches = --enable-multilib
-extra_configure_switches += --with-gnu-as
-extra_configure_switches += --with-gnu-ld
-extra_configure_switches += --disable-nls
-extra_configure_switches += --disable-shared
-extra_configure_switches += --disable-newlib-supplied-sycalls
-ifeq ($(FLAVOUR),full)
-extra_configure_switches += --enable-newlib-io-long-long
-extra_configure_switches += --enable-newlib-register-fini
-extra_configure_switches += --enable-newlib-io-c99-formats
-extra_configure_switches += --enable-newlib-io-pos-args
-extra_configure_switches += --enable-newlib-multithread
-endif
-ifeq ($(FLAVOUR),nano)
-extra_configure_switches += --enable-newlib-reent-small
-extra_configure_switches += --disable-newlib-fvwrite-in-streamio
-extra_configure_switches += --disable-newlib-fseek-optimization
-extra_configure_switches += --disable-newlib-wide-orient
-extra_configure_switches += --enable-newlib-nano-malloc
-extra_configure_switches += --disable-newlib-unbuf-stream-opt
-extra_configure_switches += --enable-lite-exit
-extra_configure_switches += --enable-newlib-global-atexit
-extra_configure_switches += --enable-newlib-nano-formatted-io
-endif
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_M1000_NEWLIB))
-extra_configure_switches = --enable-multilib
-extra_configure_switches += --with-gnu-as
-extra_configure_switches += --with-gnu-ld
-extra_configure_switches += --disable-nls
-extra_configure_switches += --disable-shared
-extra_configure_switches += --disable-newlib-supplied-sycalls
-ifeq ($(FLAVOUR),full)
-extra_configure_switches += --enable-newlib-io-long-long
-extra_configure_switches += --enable-newlib-register-fini
-extra_configure_switches += --enable-newlib-io-c99-formats
-extra_configure_switches += --enable-newlib-io-pos-args
-extra_configure_switches += --enable-newlib-multithread
-endif
-ifeq ($(FLAVOUR),nano)
-extra_configure_switches += --enable-newlib-reent-small
-extra_configure_switches += --disable-newlib-fvwrite-in-streamio
-extra_configure_switches += --disable-newlib-fseek-optimization
-extra_configure_switches += --disable-newlib-wide-orient
-extra_configure_switches += --enable-newlib-nano-malloc
-extra_configure_switches += --disable-newlib-unbuf-stream-opt
-extra_configure_switches += --enable-lite-exit
-extra_configure_switches += --enable-newlib-global-atexit
-extra_configure_switches += --enable-newlib-nano-formatted-io
-endif
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_AT91SAM7S_NEWLIB))
-extra_configure_switches = --enable-interwork
-extra_configure_switches = --enable-multilib
-extra_configure_switches += --enable-fpu=no
-extra_configure_switches += --enable-nofmult=no
-extra_configure_switches += --enable-26bit=no
-extra_configure_switches += --enable-underscore=no
-extra_configure_switches += --with-gnu-as
-extra_configure_switches += --with-gnu-ld
-extra_configure_switches += --disable-nls
-extra_configure_switches += --disable-shared
-extra_configure_switches += --disable-newlib-supplied-sycalls
-ifeq ($(FLAVOUR),full)
-extra_configure_switches += --enable-newlib-io-long-long
-extra_configure_switches += --enable-newlib-register-fini
-# also NEWLIB allows:
-extra_configure_switches += --enable-newlib-io-c99-formats
-extra_configure_switches += --enable-newlib-io-pos-args
-extra_configure_switches += --enable-newlib-multithread
-endif
-ifeq ($(FLAVOUR),nano)
-extra_configure_switches += --enable-newlib-reent-small
-extra_configure_switches += --disable-newlib-fvwrite-in-streamio
-extra_configure_switches += --disable-newlib-fseek-optimization
-extra_configure_switches += --disable-newlib-wide-orient
-extra_configure_switches += --enable-newlib-nano-malloc
-extra_configure_switches += --disable-newlib-unbuf-stream-opt
-extra_configure_switches += --enable-lite-exit
-extra_configure_switches += --enable-newlib-global-atexit
-extra_configure_switches += --enable-newlib-nano-formatted-io
-endif
-endif
-
-ifeq ($(TOOLCHAIN),$(TOOLCHAIN_RISCV64_NEWLIB))
-extra_configure_switches = --enable-multilib
-extra_configure_switches += --with-gnu-as
-extra_configure_switches += --with-gnu-ld
-extra_configure_switches += --disable-nls
-extra_configure_switches += --disable-shared
-extra_configure_switches += --disable-newlib-supplied-sycalls
-ifeq ($(FLAVOUR),full)
-extra_configure_switches += --enable-newlib-io-long-long
-extra_configure_switches += --enable-newlib-register-fini
-extra_configure_switches += --enable-newlib-io-c99-formats
-extra_configure_switches += --enable-newlib-io-pos-args
-extra_configure_switches += --enable-newlib-multithread
-endif
-ifeq ($(FLAVOUR),nano)
-extra_configure_switches += --enable-newlib-reent-small
-extra_configure_switches += --disable-newlib-fvwrite-in-streamio
-extra_configure_switches += --disable-newlib-fseek-optimization
-extra_configure_switches += --disable-newlib-wide-orient
-extra_configure_switches += --enable-newlib-nano-malloc
-extra_configure_switches += --disable-newlib-unbuf-stream-opt
-extra_configure_switches += --enable-lite-exit
-extra_configure_switches += --enable-newlib-global-atexit
-extra_configure_switches += --enable-newlib-nano-formatted-io
-endif
-endif
-
-
-ENABLE_STRIP_DEBUG_INFO = no
-
-ENABLE_LIBGLOSS_SUPPORT = yes
-
-ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_AT91SAM7S_NEWLIB)),)
-ENABLE_LIBGLOSS_SUPPORT = no
-endif
-
-$(src_done): $(SRC_ARCHIVE) $(PATCHES_DEP)
- $(UNPACK_SRC_ARCHIVE)
- $(APPLY_PATCHES)
- @touch $@
-
-$(build_nano_target): $(src_done)
- @mkdir -p $(build_nano_dir)
- @cd $(build_nano_dir) && $(environment) ../$(src_dir_name)/newlib/configure \
- --prefix=$(TOOLCHAIN_PATH) \
- --build=$(BUILD) \
- --host=$(TARGET) \
- --target=$(TARGET) \
- --infodir=$(TOOLCHAIN_PATH)/share/info \
- --mandir=$(TOOLCHAIN_PATH)/share/man \
- --srcdir=../$(src_dir_name)/newlib \
- $(extra_configure_switches)
- @$(environment) $(MAKE) -C $(build_nano_dir) all
- @touch $@
-
-$(build_target): $(src_done)
- @mkdir -p $(build_dir)
- @cd $(build_dir) && $(environment) ../$(src_dir_name)/newlib/configure \
- --prefix=$(TOOLCHAIN_PATH) \
- --build=$(BUILD) \
- --host=$(TARGET) \
- --target=$(TARGET) \
- --infodir=$(TOOLCHAIN_PATH)/share/info \
- --mandir=$(TOOLCHAIN_PATH)/share/man \
- --srcdir=../$(src_dir_name)/newlib \
- $(extra_configure_switches)
- @$(environment) $(MAKE) -C $(build_dir) all
-ifeq ($(ENABLE_LIBGLOSS_SUPPORT),yes)
- @mkdir -p $(build_gloss_dir)
- @cd $(build_gloss_dir) && $(environment) ../$(src_dir_name)/libgloss/configure \
- --prefix=$(TOOLCHAIN_PATH) \
- --build=$(BUILD) \
- --host=$(TARGET) \
- --target=$(TARGET) \
- --infodir=$(TOOLCHAIN_PATH)/share/info \
- --mandir=$(TOOLCHAIN_PATH)/share/man \
- --srcdir=../$(src_dir_name)/libgloss \
- $(extra_configure_switches)
- @$(environment) $(MAKE) -C $(build_gloss_dir) all info
-endif
- @touch $@
-
-$(nano_target): $(build_nano_target)
- @mkdir -p $(install_dir)
- @$(environment) $(MAKE) -C $(build_nano_dir) -j1 install
- @mkdir -p $(install_dir)/include/newlib-nano
- @install -m644 -t $(install_dir)/include/newlib-nano $(install_dir)/include/newlib.h
- @find $(install_dir)/lib -regex ".*/lib\(c\|g\|m\|rdimon\)\.a" -exec rename .a _nano.a '{}' \;
- @echo " $(subst $(TOP_BUILD_DIR_ABS)/,,$(CURDIR))$(if $(FLAVOUR),:$(FLAVOUR),)" >> $(TOOLCHAIN_PATH)/README
- @touch $@
-
-$(full_target): $(build_target)
- @mkdir -p $(install_dir)
- @$(environment) $(MAKE) -C $(build_dir) -j1 install
-ifeq ($(ENABLE_LIBGLOSS_SUPPORT),yes)
- @$(environment) $(MAKE) -C $(build_gloss_dir) -j1 install
-endif
-ifeq ($(ENABLE_STRIP_DEBUG_INFO),yes)
- @find $(install_dir)/lib \( -name "*.a" -or -name "*.o" \) \
- -exec $(TOOLCHAIN_PATH)/bin/$(TARGET)-objcopy \
- -R .comment -R .note -R .debug_info -R .debug_aranges \
- -R .debug_pubnames -R .debug_pubtypes -R .debug_abbrev \
- -R .debug_line -R .debug_str -R .debug_ranges -R .debug_loc '{}' \;
-endif
- @$(environment) $(MAKE) -C $(build_dir) pdf
-ifeq ($(ENABLE_LIBGLOSS_SUPPORT),yes)
- @$(environment) $(MAKE) -C $(build_gloss_dir) pdf
-endif
- # ======= Install Documentation =======
- @mkdir -p $(TOOLCHAIN_PATH)/share/doc/newlib
- @cp $(build_dir)/libc/libc.pdf $(TOOLCHAIN_PATH)/share/doc/newlib
- @cp $(build_dir)/libm/libm.pdf $(TOOLCHAIN_PATH)/share/doc/newlib
-ifeq ($(ENABLE_LIBGLOSS_SUPPORT),yes)
- @cp $(build_gloss_dir)/doc/porting.pdf $(TOOLCHAIN_PATH)/share/doc/newlib
-endif
- @echo " $(subst $(TOP_BUILD_DIR_ABS)/,,$(CURDIR))$(if $(FLAVOUR),:$(FLAVOUR),)" >> $(TOOLCHAIN_PATH)/README
- @touch $@
Index: core/newlib/4.4.0.20231231
===================================================================
--- core/newlib/4.4.0.20231231 (revision 75)
+++ core/newlib/4.4.0.20231231 (nonexistent)
Property changes on: core/newlib/4.4.0.20231231
___________________________________________________________________
Deleted: svn:ignore
## -1,81 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.rk358x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: core/newlib/4.5.0.20241231/Makefile
===================================================================
--- core/newlib/4.5.0.20241231/Makefile (nonexistent)
+++ core/newlib/4.5.0.20241231/Makefile (revision 76)
@@ -0,0 +1,419 @@
+
+
+COMPONENT_TARGETS = $(TOOLCHAIN_ARM32_NEWLIB)
+COMPONENT_TARGETS += $(TOOLCHAIN_A33XX_NEWLIB)
+COMPONENT_TARGETS += $(TOOLCHAIN_A9XX_NEWLIB)
+COMPONENT_TARGETS += $(TOOLCHAIN_H5_NEWLIB)
+COMPONENT_TARGETS += $(TOOLCHAIN_S9XX_NEWLIB)
+COMPONENT_TARGETS += $(TOOLCHAIN_RK33XX_NEWLIB)
+COMPONENT_TARGETS += $(TOOLCHAIN_M1000_NEWLIB)
+COMPONENT_TARGETS += $(TOOLCHAIN_AT91SAM7S_NEWLIB)
+COMPONENT_TARGETS += $(TOOLCHAIN_RISCV64_NEWLIB)
+
+FLAVOURS = nano full
+
+
+include ../../../build-system/config.mk
+
+
+SOURCE_REQUIRES = sources/newlib
+
+ifeq ($(FLAVOUR),nano)
+REQUIRES = core/gcc/14.2.0^static
+endif
+ifeq ($(FLAVOUR),full)
+REQUIRES = core/newlib/4.5.0.20241231^nano
+endif
+
+# ======= __END_OF_REQUIRES__ =======
+
+tar_gz_archive = $(SRC_PACKAGE_PATH)/newlib/newlib-4.5.0.20241231.tar.gz
+SRC_ARCHIVE = $(tar_gz_archive)
+SRC_DIR = $(TARGET_BUILD_DIR)/newlib-4.5.0.20241231
+src_dir_name = newlib-4.5.0.20241231
+src_done = $(TARGET_BUILD_DIR)/.source-done
+
+PATCHES = PATCHES
+
+build_dir = $(TARGET_BUILD_DIR)/newlib
+build_gloss_dir = $(TARGET_BUILD_DIR)/libgloss
+build_nano_dir = $(TARGET_BUILD_DIR)/nano
+
+install_dir = $(TOOLCHAIN_PATH)/$(TARGET)
+
+build_nano_target = $(TARGET_BUILD_DIR)/.nano-built
+nano_target = $(TARGET_BUILD_DIR)/.nano-installed
+
+build_target = $(TARGET_BUILD_DIR)/.built
+full_target = $(TARGET_BUILD_DIR)/.installed
+
+
+
+ifeq ($(FLAVOUR),nano)
+BUILD_TARGETS = $(build_nano_target)
+BUILD_TARGETS += $(nano_target)
+endif
+
+ifeq ($(FLAVOUR),full)
+BUILD_TARGETS = $(build_target)
+BUILD_TARGETS += $(full_target)
+endif
+
+include ../../../build-system/core.mk
+
+
+environment = AS="$(TOOLCHAIN_PATH)/bin/$(TARGET)-as"
+environment += LD="$(TOOLCHAIN_PATH)/bin/$(TARGET)-ld"
+environment += CC="$(CCACHE)$(TOOLCHAIN_PATH)/bin/$(TARGET)-gcc"
+environment += AR="$(TOOLCHAIN_PATH)/bin/$(TARGET)-ar"
+environment += RANLIB="$(TOOLCHAIN_PATH)/bin/$(TARGET)-ranlib"
+
+environment += PATH_FIG2DEV="/usr/bin:/usr/X11R6/bin:/usr/share/texmf/bin"
+environment += PATH="$(TOOLCHAIN_PATH)/bin:$(PATH):$(PATH_FIG2DEV)"
+# =============
+# need for fig2dev and documentation (see: ../.config).
+
+environment += BUILD_CC="$(CCACHE)/usr/bin/gcc"
+environment += TARGET_CFLAGS="-g -O2 -ffunction-sections -fdata-sections"
+environment += CPPFLAGS="-I$(TOOLCHAIN_PATH)/$(TARGET)/include"
+
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_ARM32_NEWLIB))
+extra_configure_switches = --enable-multilib
+extra_configure_switches += --with-gnu-as
+extra_configure_switches += --with-gnu-ld
+extra_configure_switches += --disable-nls
+extra_configure_switches += --disable-shared
+extra_configure_switches += --disable-newlib-supplied-sycalls
+ifeq ($(FLAVOUR),full)
+extra_configure_switches += --enable-newlib-io-long-long
+extra_configure_switches += --enable-newlib-register-fini
+extra_configure_switches += --enable-newlib-io-c99-formats
+extra_configure_switches += --enable-newlib-io-pos-args
+extra_configure_switches += --enable-newlib-multithread
+endif
+ifeq ($(FLAVOUR),nano)
+extra_configure_switches += --enable-newlib-reent-small
+extra_configure_switches += --disable-newlib-fvwrite-in-streamio
+extra_configure_switches += --disable-newlib-fseek-optimization
+extra_configure_switches += --disable-newlib-wide-orient
+extra_configure_switches += --enable-newlib-nano-malloc
+extra_configure_switches += --disable-newlib-unbuf-stream-opt
+extra_configure_switches += --enable-lite-exit
+extra_configure_switches += --enable-newlib-global-atexit
+extra_configure_switches += --enable-newlib-nano-formatted-io
+endif
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A33XX_NEWLIB))
+extra_configure_switches = --enable-multilib
+extra_configure_switches += --with-gnu-as
+extra_configure_switches += --with-gnu-ld
+extra_configure_switches += --disable-nls
+extra_configure_switches += --disable-shared
+extra_configure_switches += --disable-newlib-supplied-sycalls
+ifeq ($(FLAVOUR),full)
+extra_configure_switches += --enable-newlib-io-long-long
+extra_configure_switches += --enable-newlib-register-fini
+extra_configure_switches += --enable-newlib-io-c99-formats
+extra_configure_switches += --enable-newlib-io-pos-args
+extra_configure_switches += --enable-newlib-multithread
+endif
+ifeq ($(FLAVOUR),nano)
+extra_configure_switches += --enable-newlib-reent-small
+extra_configure_switches += --disable-newlib-fvwrite-in-streamio
+extra_configure_switches += --disable-newlib-fseek-optimization
+extra_configure_switches += --disable-newlib-wide-orient
+extra_configure_switches += --enable-newlib-nano-malloc
+extra_configure_switches += --disable-newlib-unbuf-stream-opt
+extra_configure_switches += --enable-lite-exit
+extra_configure_switches += --enable-newlib-global-atexit
+extra_configure_switches += --enable-newlib-nano-formatted-io
+endif
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A9XX_NEWLIB))
+extra_configure_switches = --enable-multilib
+extra_configure_switches += --with-gnu-as
+extra_configure_switches += --with-gnu-ld
+extra_configure_switches += --disable-nls
+extra_configure_switches += --disable-shared
+extra_configure_switches += --disable-newlib-supplied-sycalls
+ifeq ($(FLAVOUR),full)
+extra_configure_switches += --enable-newlib-io-long-long
+extra_configure_switches += --enable-newlib-register-fini
+extra_configure_switches += --enable-newlib-io-c99-formats
+extra_configure_switches += --enable-newlib-io-pos-args
+extra_configure_switches += --enable-newlib-multithread
+endif
+ifeq ($(FLAVOUR),nano)
+extra_configure_switches += --enable-newlib-reent-small
+extra_configure_switches += --disable-newlib-fvwrite-in-streamio
+extra_configure_switches += --disable-newlib-fseek-optimization
+extra_configure_switches += --disable-newlib-wide-orient
+extra_configure_switches += --enable-newlib-nano-malloc
+extra_configure_switches += --disable-newlib-unbuf-stream-opt
+extra_configure_switches += --enable-lite-exit
+extra_configure_switches += --enable-newlib-global-atexit
+extra_configure_switches += --enable-newlib-nano-formatted-io
+endif
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_H5_NEWLIB))
+extra_configure_switches = --enable-multilib
+extra_configure_switches += --with-gnu-as
+extra_configure_switches += --with-gnu-ld
+extra_configure_switches += --disable-nls
+extra_configure_switches += --disable-shared
+extra_configure_switches += --disable-newlib-supplied-sycalls
+ifeq ($(FLAVOUR),full)
+extra_configure_switches += --enable-newlib-io-long-long
+extra_configure_switches += --enable-newlib-register-fini
+extra_configure_switches += --enable-newlib-io-c99-formats
+extra_configure_switches += --enable-newlib-io-pos-args
+extra_configure_switches += --enable-newlib-multithread
+endif
+ifeq ($(FLAVOUR),nano)
+extra_configure_switches += --enable-newlib-reent-small
+extra_configure_switches += --disable-newlib-fvwrite-in-streamio
+extra_configure_switches += --disable-newlib-fseek-optimization
+extra_configure_switches += --disable-newlib-wide-orient
+extra_configure_switches += --enable-newlib-nano-malloc
+extra_configure_switches += --disable-newlib-unbuf-stream-opt
+extra_configure_switches += --enable-lite-exit
+extra_configure_switches += --enable-newlib-global-atexit
+extra_configure_switches += --enable-newlib-nano-formatted-io
+endif
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_S9XX_NEWLIB))
+extra_configure_switches = --enable-multilib
+extra_configure_switches += --with-gnu-as
+extra_configure_switches += --with-gnu-ld
+extra_configure_switches += --disable-nls
+extra_configure_switches += --disable-shared
+extra_configure_switches += --disable-newlib-supplied-sycalls
+ifeq ($(FLAVOUR),full)
+extra_configure_switches += --enable-newlib-io-long-long
+extra_configure_switches += --enable-newlib-register-fini
+extra_configure_switches += --enable-newlib-io-c99-formats
+extra_configure_switches += --enable-newlib-io-pos-args
+extra_configure_switches += --enable-newlib-multithread
+endif
+ifeq ($(FLAVOUR),nano)
+extra_configure_switches += --enable-newlib-reent-small
+extra_configure_switches += --disable-newlib-fvwrite-in-streamio
+extra_configure_switches += --disable-newlib-fseek-optimization
+extra_configure_switches += --disable-newlib-wide-orient
+extra_configure_switches += --enable-newlib-nano-malloc
+extra_configure_switches += --disable-newlib-unbuf-stream-opt
+extra_configure_switches += --enable-lite-exit
+extra_configure_switches += --enable-newlib-global-atexit
+extra_configure_switches += --enable-newlib-nano-formatted-io
+endif
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_RK33XX_NEWLIB))
+extra_configure_switches = --enable-multilib
+extra_configure_switches += --with-gnu-as
+extra_configure_switches += --with-gnu-ld
+extra_configure_switches += --disable-nls
+extra_configure_switches += --disable-shared
+extra_configure_switches += --disable-newlib-supplied-sycalls
+ifeq ($(FLAVOUR),full)
+extra_configure_switches += --enable-newlib-io-long-long
+extra_configure_switches += --enable-newlib-register-fini
+extra_configure_switches += --enable-newlib-io-c99-formats
+extra_configure_switches += --enable-newlib-io-pos-args
+extra_configure_switches += --enable-newlib-multithread
+endif
+ifeq ($(FLAVOUR),nano)
+extra_configure_switches += --enable-newlib-reent-small
+extra_configure_switches += --disable-newlib-fvwrite-in-streamio
+extra_configure_switches += --disable-newlib-fseek-optimization
+extra_configure_switches += --disable-newlib-wide-orient
+extra_configure_switches += --enable-newlib-nano-malloc
+extra_configure_switches += --disable-newlib-unbuf-stream-opt
+extra_configure_switches += --enable-lite-exit
+extra_configure_switches += --enable-newlib-global-atexit
+extra_configure_switches += --enable-newlib-nano-formatted-io
+endif
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_M1000_NEWLIB))
+extra_configure_switches = --enable-multilib
+extra_configure_switches += --with-gnu-as
+extra_configure_switches += --with-gnu-ld
+extra_configure_switches += --disable-nls
+extra_configure_switches += --disable-shared
+extra_configure_switches += --disable-newlib-supplied-sycalls
+ifeq ($(FLAVOUR),full)
+extra_configure_switches += --enable-newlib-io-long-long
+extra_configure_switches += --enable-newlib-register-fini
+extra_configure_switches += --enable-newlib-io-c99-formats
+extra_configure_switches += --enable-newlib-io-pos-args
+extra_configure_switches += --enable-newlib-multithread
+endif
+ifeq ($(FLAVOUR),nano)
+extra_configure_switches += --enable-newlib-reent-small
+extra_configure_switches += --disable-newlib-fvwrite-in-streamio
+extra_configure_switches += --disable-newlib-fseek-optimization
+extra_configure_switches += --disable-newlib-wide-orient
+extra_configure_switches += --enable-newlib-nano-malloc
+extra_configure_switches += --disable-newlib-unbuf-stream-opt
+extra_configure_switches += --enable-lite-exit
+extra_configure_switches += --enable-newlib-global-atexit
+extra_configure_switches += --enable-newlib-nano-formatted-io
+endif
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_AT91SAM7S_NEWLIB))
+extra_configure_switches = --enable-interwork
+extra_configure_switches = --enable-multilib
+extra_configure_switches += --enable-fpu=no
+extra_configure_switches += --enable-nofmult=no
+extra_configure_switches += --enable-26bit=no
+extra_configure_switches += --enable-underscore=no
+extra_configure_switches += --with-gnu-as
+extra_configure_switches += --with-gnu-ld
+extra_configure_switches += --disable-nls
+extra_configure_switches += --disable-shared
+extra_configure_switches += --disable-newlib-supplied-sycalls
+ifeq ($(FLAVOUR),full)
+extra_configure_switches += --enable-newlib-io-long-long
+extra_configure_switches += --enable-newlib-register-fini
+# also NEWLIB allows:
+extra_configure_switches += --enable-newlib-io-c99-formats
+extra_configure_switches += --enable-newlib-io-pos-args
+extra_configure_switches += --enable-newlib-multithread
+endif
+ifeq ($(FLAVOUR),nano)
+extra_configure_switches += --enable-newlib-reent-small
+extra_configure_switches += --disable-newlib-fvwrite-in-streamio
+extra_configure_switches += --disable-newlib-fseek-optimization
+extra_configure_switches += --disable-newlib-wide-orient
+extra_configure_switches += --enable-newlib-nano-malloc
+extra_configure_switches += --disable-newlib-unbuf-stream-opt
+extra_configure_switches += --enable-lite-exit
+extra_configure_switches += --enable-newlib-global-atexit
+extra_configure_switches += --enable-newlib-nano-formatted-io
+endif
+endif
+
+ifeq ($(TOOLCHAIN),$(TOOLCHAIN_RISCV64_NEWLIB))
+extra_configure_switches = --enable-multilib
+extra_configure_switches += --with-gnu-as
+extra_configure_switches += --with-gnu-ld
+extra_configure_switches += --disable-nls
+extra_configure_switches += --disable-shared
+extra_configure_switches += --disable-newlib-supplied-sycalls
+ifeq ($(FLAVOUR),full)
+extra_configure_switches += --enable-newlib-io-long-long
+extra_configure_switches += --enable-newlib-register-fini
+extra_configure_switches += --enable-newlib-io-c99-formats
+extra_configure_switches += --enable-newlib-io-pos-args
+extra_configure_switches += --enable-newlib-multithread
+endif
+ifeq ($(FLAVOUR),nano)
+extra_configure_switches += --enable-newlib-reent-small
+extra_configure_switches += --disable-newlib-fvwrite-in-streamio
+extra_configure_switches += --disable-newlib-fseek-optimization
+extra_configure_switches += --disable-newlib-wide-orient
+extra_configure_switches += --enable-newlib-nano-malloc
+extra_configure_switches += --disable-newlib-unbuf-stream-opt
+extra_configure_switches += --enable-lite-exit
+extra_configure_switches += --enable-newlib-global-atexit
+extra_configure_switches += --enable-newlib-nano-formatted-io
+endif
+endif
+
+
+ENABLE_STRIP_DEBUG_INFO = no
+
+ENABLE_LIBGLOSS_SUPPORT = yes
+
+ifneq ($(filter $(TOOLCHAIN),$(TOOLCHAIN_AT91SAM7S_NEWLIB)),)
+ENABLE_LIBGLOSS_SUPPORT = no
+endif
+
+$(src_done): $(SRC_ARCHIVE) $(PATCHES_DEP)
+ $(UNPACK_SRC_ARCHIVE)
+ $(APPLY_PATCHES)
+ @touch $@
+
+$(build_nano_target): $(src_done)
+ @mkdir -p $(build_nano_dir)
+ @cd $(build_nano_dir) && $(environment) ../$(src_dir_name)/newlib/configure \
+ --prefix=$(TOOLCHAIN_PATH) \
+ --build=$(BUILD) \
+ --host=$(TARGET) \
+ --target=$(TARGET) \
+ --infodir=$(TOOLCHAIN_PATH)/share/info \
+ --mandir=$(TOOLCHAIN_PATH)/share/man \
+ --srcdir=../$(src_dir_name)/newlib \
+ $(extra_configure_switches)
+ @$(environment) $(MAKE) -C $(build_nano_dir) all
+ @touch $@
+
+$(build_target): $(src_done)
+ @mkdir -p $(build_dir)
+ @cd $(build_dir) && $(environment) ../$(src_dir_name)/newlib/configure \
+ --prefix=$(TOOLCHAIN_PATH) \
+ --build=$(BUILD) \
+ --host=$(TARGET) \
+ --target=$(TARGET) \
+ --infodir=$(TOOLCHAIN_PATH)/share/info \
+ --mandir=$(TOOLCHAIN_PATH)/share/man \
+ --srcdir=../$(src_dir_name)/newlib \
+ $(extra_configure_switches)
+ @$(environment) $(MAKE) -C $(build_dir) all
+ifeq ($(ENABLE_LIBGLOSS_SUPPORT),yes)
+ @mkdir -p $(build_gloss_dir)
+ @cd $(build_gloss_dir) && $(environment) ../$(src_dir_name)/libgloss/configure \
+ --prefix=$(TOOLCHAIN_PATH) \
+ --build=$(BUILD) \
+ --host=$(TARGET) \
+ --target=$(TARGET) \
+ --infodir=$(TOOLCHAIN_PATH)/share/info \
+ --mandir=$(TOOLCHAIN_PATH)/share/man \
+ --srcdir=../$(src_dir_name)/libgloss \
+ $(extra_configure_switches)
+ @$(environment) $(MAKE) -C $(build_gloss_dir) all info
+endif
+ @touch $@
+
+$(nano_target): $(build_nano_target)
+ @mkdir -p $(install_dir)
+ @$(environment) $(MAKE) -C $(build_nano_dir) -j1 install
+ @mkdir -p $(install_dir)/include/newlib-nano
+ @install -m644 -t $(install_dir)/include/newlib-nano $(install_dir)/include/newlib.h
+ @find $(install_dir)/lib -regex ".*/lib\(c\|g\|m\|rdimon\)\.a" -exec rename .a _nano.a '{}' \;
+ @echo " $(subst $(TOP_BUILD_DIR_ABS)/,,$(CURDIR))$(if $(FLAVOUR),:$(FLAVOUR),)" >> $(TOOLCHAIN_PATH)/README
+ @touch $@
+
+$(full_target): $(build_target)
+ @mkdir -p $(install_dir)
+ @$(environment) $(MAKE) -C $(build_dir) -j1 install
+ifeq ($(ENABLE_LIBGLOSS_SUPPORT),yes)
+ @$(environment) $(MAKE) -C $(build_gloss_dir) -j1 install
+endif
+ifeq ($(ENABLE_STRIP_DEBUG_INFO),yes)
+ @find $(install_dir)/lib \( -name "*.a" -or -name "*.o" \) \
+ -exec $(TOOLCHAIN_PATH)/bin/$(TARGET)-objcopy \
+ -R .comment -R .note -R .debug_info -R .debug_aranges \
+ -R .debug_pubnames -R .debug_pubtypes -R .debug_abbrev \
+ -R .debug_line -R .debug_str -R .debug_ranges -R .debug_loc '{}' \;
+endif
+ @$(environment) $(MAKE) -C $(build_dir) pdf
+ifeq ($(ENABLE_LIBGLOSS_SUPPORT),yes)
+ @$(environment) $(MAKE) -C $(build_gloss_dir) pdf
+endif
+ # ======= Install Documentation =======
+ @mkdir -p $(TOOLCHAIN_PATH)/share/doc/newlib
+ @cp $(build_dir)/libc/libc.pdf $(TOOLCHAIN_PATH)/share/doc/newlib
+ @cp $(build_dir)/libm/libm.pdf $(TOOLCHAIN_PATH)/share/doc/newlib
+ifeq ($(ENABLE_LIBGLOSS_SUPPORT),yes)
+ @cp $(build_gloss_dir)/doc/porting.pdf $(TOOLCHAIN_PATH)/share/doc/newlib
+endif
+ @echo " $(subst $(TOP_BUILD_DIR_ABS)/,,$(CURDIR))$(if $(FLAVOUR),:$(FLAVOUR),)" >> $(TOOLCHAIN_PATH)/README
+ @touch $@
Index: core/newlib/4.5.0.20241231/PATCHES
===================================================================
--- core/newlib/4.5.0.20241231/PATCHES (nonexistent)
+++ core/newlib/4.5.0.20241231/PATCHES (revision 76)
@@ -0,0 +1,2 @@
+
+../../../sources/newlib/patches/newlib-4.5.0.20241231-riscv.patch -p0
Index: core/newlib/4.5.0.20241231
===================================================================
--- core/newlib/4.5.0.20241231 (nonexistent)
+++ core/newlib/4.5.0.20241231 (revision 76)
Property changes on: core/newlib/4.5.0.20241231
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,81 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.rk358x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/A1X-glibc/1.11.3/A1X-TEST-neon/main.c
===================================================================
--- products/A1X-glibc/1.11.3/A1X-TEST-neon/main.c (revision 75)
+++ products/A1X-glibc/1.11.3/A1X-TEST-neon/main.c (nonexistent)
@@ -1,17 +0,0 @@
-
-//#include <stdlib.h>
-//#include <inttypes.h>
-
-int main()
-{
- float d, f = 3.1415;
-
-// uint32_t a = 7, b = 3, c, r;
-
-// c = a / b;
-// r = a % b;
-
- d = f * 2.1;
-
- return( 0 );
-}
Index: products/A1X-glibc/1.11.3/A1X-TEST-neon/build.sh
===================================================================
--- products/A1X-glibc/1.11.3/A1X-TEST-neon/build.sh (revision 75)
+++ products/A1X-glibc/1.11.3/A1X-TEST-neon/build.sh (nonexistent)
@@ -1,21 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-ARCH_FLAGS=" -march=armv7-a -mtune=cortex-a8"
-
-FPU_FLAGS=" -mfloat-abi=hard -mfpu=neon -ftree-vectorize -fomit-frame-pointer -ffast-math"
-
-$TARGET-gcc -g -O3 -gdwarf-2 -fomit-frame-pointer $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/A1X-glibc/1.11.3/A1X-TEST-neon/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/A1X-glibc/1.11.3/A1X-TEST-neon/.config
===================================================================
--- products/A1X-glibc/1.11.3/A1X-TEST-neon/.config (revision 75)
+++ products/A1X-glibc/1.11.3/A1X-TEST-neon/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=arm-a1x-linux-gnueabihf
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/arm-A1X-linux-glibc/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/A1X-glibc/1.11.3/A1X-TEST-neon/clean.sh
===================================================================
--- products/A1X-glibc/1.11.3/A1X-TEST-neon/clean.sh (revision 75)
+++ products/A1X-glibc/1.11.3/A1X-TEST-neon/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/A1X-glibc/1.11.3/A1X-TEST-neon/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/A1X-glibc/1.11.3/A1X-TEST-neon
===================================================================
--- products/A1X-glibc/1.11.3/A1X-TEST-neon (revision 75)
+++ products/A1X-glibc/1.11.3/A1X-TEST-neon (nonexistent)
Property changes on: products/A1X-glibc/1.11.3/A1X-TEST-neon
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/A1X-glibc/1.11.3/Makefile
===================================================================
--- products/A1X-glibc/1.11.3/Makefile (revision 75)
+++ products/A1X-glibc/1.11.3/Makefile (nonexistent)
@@ -1,35 +0,0 @@
-
-
-COMPONENT_TARGETS = $(TOOLCHAIN_A1X_GLIBC)
-
-export TOOLCHAIN_VERSION = 1.11.3
-
-include ../../../build-system/config.mk
-
-REQUIRES = core/gcc/14.2.0^full
-REQUIRES += tools/patchelf/0.18.0
-REQUIRES += core/gdb/15.1
-
-# ======= __END_OF_REQUIRES__ =======
-
-tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
-tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
-
-tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
-
-BUILD_TARGETS = $(tarball_target)
-
-PRODUCT_TARGETS = $(tarball)
-
-include ../../../build-system/core.mk
-
-
-$(tarball): $(tarball_target)
-
-$(tarball_target):
- @echo ""
- @echo "Creating $(tarball_name) tarball..."
- @cd $(TOOLCHAINS_BASE_PATH) ; \
- tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
- @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
- @touch $@
Index: products/A1X-glibc/1.11.3
===================================================================
--- products/A1X-glibc/1.11.3 (revision 75)
+++ products/A1X-glibc/1.11.3 (nonexistent)
Property changes on: products/A1X-glibc/1.11.3
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/A1X-glibc/1.11.4/A1X-TEST-neon/.config
===================================================================
--- products/A1X-glibc/1.11.4/A1X-TEST-neon/.config (nonexistent)
+++ products/A1X-glibc/1.11.4/A1X-TEST-neon/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=arm-a1x-linux-gnueabihf
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/arm-A1X-linux-glibc/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/A1X-glibc/1.11.4/A1X-TEST-neon/build.sh
===================================================================
--- products/A1X-glibc/1.11.4/A1X-TEST-neon/build.sh (nonexistent)
+++ products/A1X-glibc/1.11.4/A1X-TEST-neon/build.sh (revision 76)
@@ -0,0 +1,21 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+ARCH_FLAGS=" -march=armv7-a -mtune=cortex-a8"
+
+FPU_FLAGS=" -mfloat-abi=hard -mfpu=neon -ftree-vectorize -fomit-frame-pointer -ffast-math"
+
+$TARGET-gcc -g -O3 -gdwarf-2 -fomit-frame-pointer $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/A1X-glibc/1.11.4/A1X-TEST-neon/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/A1X-glibc/1.11.4/A1X-TEST-neon/clean.sh
===================================================================
--- products/A1X-glibc/1.11.4/A1X-TEST-neon/clean.sh (nonexistent)
+++ products/A1X-glibc/1.11.4/A1X-TEST-neon/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/A1X-glibc/1.11.4/A1X-TEST-neon/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/A1X-glibc/1.11.4/A1X-TEST-neon/main.c
===================================================================
--- products/A1X-glibc/1.11.4/A1X-TEST-neon/main.c (nonexistent)
+++ products/A1X-glibc/1.11.4/A1X-TEST-neon/main.c (revision 76)
@@ -0,0 +1,17 @@
+
+//#include <stdlib.h>
+//#include <inttypes.h>
+
+int main()
+{
+ float d, f = 3.1415;
+
+// uint32_t a = 7, b = 3, c, r;
+
+// c = a / b;
+// r = a % b;
+
+ d = f * 2.1;
+
+ return( 0 );
+}
Index: products/A1X-glibc/1.11.4/A1X-TEST-neon
===================================================================
--- products/A1X-glibc/1.11.4/A1X-TEST-neon (nonexistent)
+++ products/A1X-glibc/1.11.4/A1X-TEST-neon (revision 76)
Property changes on: products/A1X-glibc/1.11.4/A1X-TEST-neon
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/A1X-glibc/1.11.4/Makefile
===================================================================
--- products/A1X-glibc/1.11.4/Makefile (nonexistent)
+++ products/A1X-glibc/1.11.4/Makefile (revision 76)
@@ -0,0 +1,35 @@
+
+
+COMPONENT_TARGETS = $(TOOLCHAIN_A1X_GLIBC)
+
+export TOOLCHAIN_VERSION = 1.11.4
+
+include ../../../build-system/config.mk
+
+REQUIRES = core/gcc/14.2.0^full
+REQUIRES += tools/patchelf/0.18.0
+REQUIRES += core/gdb/16.2
+
+# ======= __END_OF_REQUIRES__ =======
+
+tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
+tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
+
+tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
+
+BUILD_TARGETS = $(tarball_target)
+
+PRODUCT_TARGETS = $(tarball)
+
+include ../../../build-system/core.mk
+
+
+$(tarball): $(tarball_target)
+
+$(tarball_target):
+ @echo ""
+ @echo "Creating $(tarball_name) tarball..."
+ @cd $(TOOLCHAINS_BASE_PATH) ; \
+ tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
+ @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
+ @touch $@
Index: products/A1X-glibc/1.11.4
===================================================================
--- products/A1X-glibc/1.11.4 (nonexistent)
+++ products/A1X-glibc/1.11.4 (revision 76)
Property changes on: products/A1X-glibc/1.11.4
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/A2X-glibc/1.11.3/A2X-TEST-vfp/main.c
===================================================================
--- products/A2X-glibc/1.11.3/A2X-TEST-vfp/main.c (revision 75)
+++ products/A2X-glibc/1.11.3/A2X-TEST-vfp/main.c (nonexistent)
@@ -1,17 +0,0 @@
-
-//#include <stdlib.h>
-//#include <inttypes.h>
-
-int main()
-{
- float d, f = 3.1415;
-
-// uint32_t a = 7, b = 3, c, r;
-
-// c = a / b;
-// r = a % b;
-
- d = f * 2.1;
-
- return( 0 );
-}
Index: products/A2X-glibc/1.11.3/A2X-TEST-vfp/build.sh
===================================================================
--- products/A2X-glibc/1.11.3/A2X-TEST-vfp/build.sh (revision 75)
+++ products/A2X-glibc/1.11.3/A2X-TEST-vfp/build.sh (nonexistent)
@@ -1,21 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-ARCH_FLAGS=" -march=armv7ve -mtune=cortex-a7"
-
-FPU_FLAGS=" -mfloat-abi=hard -mfpu=neon-vfpv4 -ftree-vectorize -fomit-frame-pointer -ffast-math"
-
-$TARGET-gcc -g -O3 -gdwarf-2 -fomit-frame-pointer $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/A2X-glibc/1.11.3/A2X-TEST-vfp/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/A2X-glibc/1.11.3/A2X-TEST-vfp/.config
===================================================================
--- products/A2X-glibc/1.11.3/A2X-TEST-vfp/.config (revision 75)
+++ products/A2X-glibc/1.11.3/A2X-TEST-vfp/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=arm-a2x-linux-gnueabihf
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/arm-A2X-linux-glibc/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/A2X-glibc/1.11.3/A2X-TEST-vfp/clean.sh
===================================================================
--- products/A2X-glibc/1.11.3/A2X-TEST-vfp/clean.sh (revision 75)
+++ products/A2X-glibc/1.11.3/A2X-TEST-vfp/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/A2X-glibc/1.11.3/A2X-TEST-vfp/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/A2X-glibc/1.11.3/A2X-TEST-vfp
===================================================================
--- products/A2X-glibc/1.11.3/A2X-TEST-vfp (revision 75)
+++ products/A2X-glibc/1.11.3/A2X-TEST-vfp (nonexistent)
Property changes on: products/A2X-glibc/1.11.3/A2X-TEST-vfp
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/A2X-glibc/1.11.3/Makefile
===================================================================
--- products/A2X-glibc/1.11.3/Makefile (revision 75)
+++ products/A2X-glibc/1.11.3/Makefile (nonexistent)
@@ -1,35 +0,0 @@
-
-
-COMPONENT_TARGETS = $(TOOLCHAIN_A2X_GLIBC)
-
-export TOOLCHAIN_VERSION = 1.11.3
-
-include ../../../build-system/config.mk
-
-REQUIRES = core/gcc/14.2.0^full
-REQUIRES += tools/patchelf/0.18.0
-REQUIRES += core/gdb/15.1
-
-# ======= __END_OF_REQUIRES__ =======
-
-tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
-tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
-
-tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
-
-BUILD_TARGETS = $(tarball_target)
-
-PRODUCT_TARGETS = $(tarball)
-
-include ../../../build-system/core.mk
-
-
-$(tarball): $(tarball_target)
-
-$(tarball_target):
- @echo ""
- @echo "Creating $(tarball_name) tarball..."
- @cd $(TOOLCHAINS_BASE_PATH) ; \
- tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
- @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
- @touch $@
Index: products/A2X-glibc/1.11.3
===================================================================
--- products/A2X-glibc/1.11.3 (revision 75)
+++ products/A2X-glibc/1.11.3 (nonexistent)
Property changes on: products/A2X-glibc/1.11.3
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/A2X-glibc/1.11.4/A2X-TEST-vfp/.config
===================================================================
--- products/A2X-glibc/1.11.4/A2X-TEST-vfp/.config (nonexistent)
+++ products/A2X-glibc/1.11.4/A2X-TEST-vfp/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=arm-a2x-linux-gnueabihf
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/arm-A2X-linux-glibc/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/A2X-glibc/1.11.4/A2X-TEST-vfp/build.sh
===================================================================
--- products/A2X-glibc/1.11.4/A2X-TEST-vfp/build.sh (nonexistent)
+++ products/A2X-glibc/1.11.4/A2X-TEST-vfp/build.sh (revision 76)
@@ -0,0 +1,21 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+ARCH_FLAGS=" -march=armv7ve -mtune=cortex-a7"
+
+FPU_FLAGS=" -mfloat-abi=hard -mfpu=neon-vfpv4 -ftree-vectorize -fomit-frame-pointer -ffast-math"
+
+$TARGET-gcc -g -O3 -gdwarf-2 -fomit-frame-pointer $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/A2X-glibc/1.11.4/A2X-TEST-vfp/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/A2X-glibc/1.11.4/A2X-TEST-vfp/clean.sh
===================================================================
--- products/A2X-glibc/1.11.4/A2X-TEST-vfp/clean.sh (nonexistent)
+++ products/A2X-glibc/1.11.4/A2X-TEST-vfp/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/A2X-glibc/1.11.4/A2X-TEST-vfp/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/A2X-glibc/1.11.4/A2X-TEST-vfp/main.c
===================================================================
--- products/A2X-glibc/1.11.4/A2X-TEST-vfp/main.c (nonexistent)
+++ products/A2X-glibc/1.11.4/A2X-TEST-vfp/main.c (revision 76)
@@ -0,0 +1,17 @@
+
+//#include <stdlib.h>
+//#include <inttypes.h>
+
+int main()
+{
+ float d, f = 3.1415;
+
+// uint32_t a = 7, b = 3, c, r;
+
+// c = a / b;
+// r = a % b;
+
+ d = f * 2.1;
+
+ return( 0 );
+}
Index: products/A2X-glibc/1.11.4/A2X-TEST-vfp
===================================================================
--- products/A2X-glibc/1.11.4/A2X-TEST-vfp (nonexistent)
+++ products/A2X-glibc/1.11.4/A2X-TEST-vfp (revision 76)
Property changes on: products/A2X-glibc/1.11.4/A2X-TEST-vfp
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/A2X-glibc/1.11.4/Makefile
===================================================================
--- products/A2X-glibc/1.11.4/Makefile (nonexistent)
+++ products/A2X-glibc/1.11.4/Makefile (revision 76)
@@ -0,0 +1,35 @@
+
+
+COMPONENT_TARGETS = $(TOOLCHAIN_A2X_GLIBC)
+
+export TOOLCHAIN_VERSION = 1.11.4
+
+include ../../../build-system/config.mk
+
+REQUIRES = core/gcc/14.2.0^full
+REQUIRES += tools/patchelf/0.18.0
+REQUIRES += core/gdb/16.2
+
+# ======= __END_OF_REQUIRES__ =======
+
+tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
+tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
+
+tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
+
+BUILD_TARGETS = $(tarball_target)
+
+PRODUCT_TARGETS = $(tarball)
+
+include ../../../build-system/core.mk
+
+
+$(tarball): $(tarball_target)
+
+$(tarball_target):
+ @echo ""
+ @echo "Creating $(tarball_name) tarball..."
+ @cd $(TOOLCHAINS_BASE_PATH) ; \
+ tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
+ @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
+ @touch $@
Index: products/A2X-glibc/1.11.4
===================================================================
--- products/A2X-glibc/1.11.4 (nonexistent)
+++ products/A2X-glibc/1.11.4 (revision 76)
Property changes on: products/A2X-glibc/1.11.4
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/A311X-glibc/1.11.3/A311X-TEST/main.c
===================================================================
--- products/A311X-glibc/1.11.3/A311X-TEST/main.c (revision 75)
+++ products/A311X-glibc/1.11.3/A311X-TEST/main.c (nonexistent)
@@ -1,17 +0,0 @@
-
-#include <stdlib.h>
-#include <inttypes.h>
-
-int main()
-{
- float d, f = 3.1415;
-
- uint32_t a = 7, b = 3, c, r;
-
- c = a / b;
- r = a % b;
-
- d = f * 2.1;
-
- return( 0 );
-}
Index: products/A311X-glibc/1.11.3/A311X-TEST/build.sh
===================================================================
--- products/A311X-glibc/1.11.3/A311X-TEST/build.sh (revision 75)
+++ products/A311X-glibc/1.11.3/A311X-TEST/build.sh (nonexistent)
@@ -1,19 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-ARCH_FLAGS=" -march=armv8-a -mcpu=cortex-a73.cortex-a53 -mabi=lp64"
-
-$TARGET-gcc -g -O3 -gdwarf-2 -fomit-frame-pointer $ARCH_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/A311X-glibc/1.11.3/A311X-TEST/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/A311X-glibc/1.11.3/A311X-TEST/.config
===================================================================
--- products/A311X-glibc/1.11.3/A311X-TEST/.config (revision 75)
+++ products/A311X-glibc/1.11.3/A311X-TEST/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=aarch64-a311x-linux-gnu
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/aarch64-A311X-linux-glibc/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/A311X-glibc/1.11.3/A311X-TEST/clean.sh
===================================================================
--- products/A311X-glibc/1.11.3/A311X-TEST/clean.sh (revision 75)
+++ products/A311X-glibc/1.11.3/A311X-TEST/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/A311X-glibc/1.11.3/A311X-TEST/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/A311X-glibc/1.11.3/A311X-TEST
===================================================================
--- products/A311X-glibc/1.11.3/A311X-TEST (revision 75)
+++ products/A311X-glibc/1.11.3/A311X-TEST (nonexistent)
Property changes on: products/A311X-glibc/1.11.3/A311X-TEST
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/A311X-glibc/1.11.3/Makefile
===================================================================
--- products/A311X-glibc/1.11.3/Makefile (revision 75)
+++ products/A311X-glibc/1.11.3/Makefile (nonexistent)
@@ -1,35 +0,0 @@
-
-
-COMPONENT_TARGETS = $(TOOLCHAIN_A311X_GLIBC)
-
-export TOOLCHAIN_VERSION = 1.11.3
-
-include ../../../build-system/config.mk
-
-REQUIRES = core/gcc/14.2.0^full
-REQUIRES += tools/patchelf/0.18.0
-REQUIRES += core/gdb/15.1
-
-# ======= __END_OF_REQUIRES__ =======
-
-tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
-tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
-
-tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
-
-BUILD_TARGETS = $(tarball_target)
-
-PRODUCT_TARGETS = $(tarball)
-
-include ../../../build-system/core.mk
-
-
-$(tarball): $(tarball_target)
-
-$(tarball_target):
- @echo ""
- @echo "Creating $(tarball_name) tarball..."
- @cd $(TOOLCHAINS_BASE_PATH) ; \
- tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
- @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
- @touch $@
Index: products/A311X-glibc/1.11.3
===================================================================
--- products/A311X-glibc/1.11.3 (revision 75)
+++ products/A311X-glibc/1.11.3 (nonexistent)
Property changes on: products/A311X-glibc/1.11.3
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/A311X-glibc/1.11.4/A311X-TEST/.config
===================================================================
--- products/A311X-glibc/1.11.4/A311X-TEST/.config (nonexistent)
+++ products/A311X-glibc/1.11.4/A311X-TEST/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=aarch64-a311x-linux-gnu
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/aarch64-A311X-linux-glibc/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/A311X-glibc/1.11.4/A311X-TEST/build.sh
===================================================================
--- products/A311X-glibc/1.11.4/A311X-TEST/build.sh (nonexistent)
+++ products/A311X-glibc/1.11.4/A311X-TEST/build.sh (revision 76)
@@ -0,0 +1,19 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+ARCH_FLAGS=" -march=armv8-a -mcpu=cortex-a73.cortex-a53 -mabi=lp64"
+
+$TARGET-gcc -g -O3 -gdwarf-2 -fomit-frame-pointer $ARCH_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/A311X-glibc/1.11.4/A311X-TEST/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/A311X-glibc/1.11.4/A311X-TEST/clean.sh
===================================================================
--- products/A311X-glibc/1.11.4/A311X-TEST/clean.sh (nonexistent)
+++ products/A311X-glibc/1.11.4/A311X-TEST/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/A311X-glibc/1.11.4/A311X-TEST/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/A311X-glibc/1.11.4/A311X-TEST/main.c
===================================================================
--- products/A311X-glibc/1.11.4/A311X-TEST/main.c (nonexistent)
+++ products/A311X-glibc/1.11.4/A311X-TEST/main.c (revision 76)
@@ -0,0 +1,17 @@
+
+#include <stdlib.h>
+#include <inttypes.h>
+
+int main()
+{
+ float d, f = 3.1415;
+
+ uint32_t a = 7, b = 3, c, r;
+
+ c = a / b;
+ r = a % b;
+
+ d = f * 2.1;
+
+ return( 0 );
+}
Index: products/A311X-glibc/1.11.4/A311X-TEST
===================================================================
--- products/A311X-glibc/1.11.4/A311X-TEST (nonexistent)
+++ products/A311X-glibc/1.11.4/A311X-TEST (revision 76)
Property changes on: products/A311X-glibc/1.11.4/A311X-TEST
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/A311X-glibc/1.11.4/Makefile
===================================================================
--- products/A311X-glibc/1.11.4/Makefile (nonexistent)
+++ products/A311X-glibc/1.11.4/Makefile (revision 76)
@@ -0,0 +1,35 @@
+
+
+COMPONENT_TARGETS = $(TOOLCHAIN_A311X_GLIBC)
+
+export TOOLCHAIN_VERSION = 1.11.4
+
+include ../../../build-system/config.mk
+
+REQUIRES = core/gcc/14.2.0^full
+REQUIRES += tools/patchelf/0.18.0
+REQUIRES += core/gdb/16.2
+
+# ======= __END_OF_REQUIRES__ =======
+
+tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
+tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
+
+tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
+
+BUILD_TARGETS = $(tarball_target)
+
+PRODUCT_TARGETS = $(tarball)
+
+include ../../../build-system/core.mk
+
+
+$(tarball): $(tarball_target)
+
+$(tarball_target):
+ @echo ""
+ @echo "Creating $(tarball_name) tarball..."
+ @cd $(TOOLCHAINS_BASE_PATH) ; \
+ tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
+ @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
+ @touch $@
Index: products/A311X-glibc/1.11.4
===================================================================
--- products/A311X-glibc/1.11.4 (nonexistent)
+++ products/A311X-glibc/1.11.4 (revision 76)
Property changes on: products/A311X-glibc/1.11.4
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/A33XX-glibc/1.11.3/A33XX-TEST/main.c
===================================================================
--- products/A33XX-glibc/1.11.3/A33XX-TEST/main.c (revision 75)
+++ products/A33XX-glibc/1.11.3/A33XX-TEST/main.c (nonexistent)
@@ -1,17 +0,0 @@
-
-//#include <stdlib.h>
-//#include <inttypes.h>
-
-int main()
-{
- float d, f = 3.1415;
-
-// uint32_t a = 7, b = 3, c, r;
-
-// c = a / b;
-// r = a % b;
-
- d = f * 2.1;
-
- return( 0 );
-}
Index: products/A33XX-glibc/1.11.3/A33XX-TEST/build.sh
===================================================================
--- products/A33XX-glibc/1.11.3/A33XX-TEST/build.sh (revision 75)
+++ products/A33XX-glibc/1.11.3/A33XX-TEST/build.sh (nonexistent)
@@ -1,21 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-ARCH_FLAGS=" -march=armv8-a"
-
-FPU_FLAGS=" -mfloat-abi=hard -mfpu=neon-fp-armv8 -ftree-vectorize -fomit-frame-pointer -ffast-math"
-
-$TARGET-gcc -g -O3 -gdwarf-2 -fomit-frame-pointer $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/A33XX-glibc/1.11.3/A33XX-TEST/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/A33XX-glibc/1.11.3/A33XX-TEST/.config
===================================================================
--- products/A33XX-glibc/1.11.3/A33XX-TEST/.config (revision 75)
+++ products/A33XX-glibc/1.11.3/A33XX-TEST/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=armv8l-a33xx-linux-gnueabihf
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/armv8l-A33XX-linux-glibc/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/A33XX-glibc/1.11.3/A33XX-TEST/clean.sh
===================================================================
--- products/A33XX-glibc/1.11.3/A33XX-TEST/clean.sh (revision 75)
+++ products/A33XX-glibc/1.11.3/A33XX-TEST/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/A33XX-glibc/1.11.3/A33XX-TEST/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/A33XX-glibc/1.11.3/A33XX-TEST
===================================================================
--- products/A33XX-glibc/1.11.3/A33XX-TEST (revision 75)
+++ products/A33XX-glibc/1.11.3/A33XX-TEST (nonexistent)
Property changes on: products/A33XX-glibc/1.11.3/A33XX-TEST
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/A33XX-glibc/1.11.3/Makefile
===================================================================
--- products/A33XX-glibc/1.11.3/Makefile (revision 75)
+++ products/A33XX-glibc/1.11.3/Makefile (nonexistent)
@@ -1,35 +0,0 @@
-
-
-COMPONENT_TARGETS = $(TOOLCHAIN_A33XX_GLIBC)
-
-export TOOLCHAIN_VERSION = 1.11.3
-
-include ../../../build-system/config.mk
-
-REQUIRES = core/gcc/14.2.0^full
-REQUIRES += tools/patchelf/0.18.0
-REQUIRES += core/gdb/15.1
-
-# ======= __END_OF_REQUIRES__ =======
-
-tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
-tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
-
-tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
-
-BUILD_TARGETS = $(tarball_target)
-
-PRODUCT_TARGETS = $(tarball)
-
-include ../../../build-system/core.mk
-
-
-$(tarball): $(tarball_target)
-
-$(tarball_target):
- @echo ""
- @echo "Creating $(tarball_name) tarball..."
- @cd $(TOOLCHAINS_BASE_PATH) ; \
- tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
- @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
- @touch $@
Index: products/A33XX-glibc/1.11.3
===================================================================
--- products/A33XX-glibc/1.11.3 (revision 75)
+++ products/A33XX-glibc/1.11.3 (nonexistent)
Property changes on: products/A33XX-glibc/1.11.3
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/A33XX-glibc/1.11.4/A33XX-TEST/.config
===================================================================
--- products/A33XX-glibc/1.11.4/A33XX-TEST/.config (nonexistent)
+++ products/A33XX-glibc/1.11.4/A33XX-TEST/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=armv8l-a33xx-linux-gnueabihf
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/armv8l-A33XX-linux-glibc/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/A33XX-glibc/1.11.4/A33XX-TEST/build.sh
===================================================================
--- products/A33XX-glibc/1.11.4/A33XX-TEST/build.sh (nonexistent)
+++ products/A33XX-glibc/1.11.4/A33XX-TEST/build.sh (revision 76)
@@ -0,0 +1,21 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+ARCH_FLAGS=" -march=armv8-a"
+
+FPU_FLAGS=" -mfloat-abi=hard -mfpu=neon-fp-armv8 -ftree-vectorize -fomit-frame-pointer -ffast-math"
+
+$TARGET-gcc -g -O3 -gdwarf-2 -fomit-frame-pointer $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/A33XX-glibc/1.11.4/A33XX-TEST/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/A33XX-glibc/1.11.4/A33XX-TEST/clean.sh
===================================================================
--- products/A33XX-glibc/1.11.4/A33XX-TEST/clean.sh (nonexistent)
+++ products/A33XX-glibc/1.11.4/A33XX-TEST/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/A33XX-glibc/1.11.4/A33XX-TEST/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/A33XX-glibc/1.11.4/A33XX-TEST/main.c
===================================================================
--- products/A33XX-glibc/1.11.4/A33XX-TEST/main.c (nonexistent)
+++ products/A33XX-glibc/1.11.4/A33XX-TEST/main.c (revision 76)
@@ -0,0 +1,17 @@
+
+//#include <stdlib.h>
+//#include <inttypes.h>
+
+int main()
+{
+ float d, f = 3.1415;
+
+// uint32_t a = 7, b = 3, c, r;
+
+// c = a / b;
+// r = a % b;
+
+ d = f * 2.1;
+
+ return( 0 );
+}
Index: products/A33XX-glibc/1.11.4/A33XX-TEST
===================================================================
--- products/A33XX-glibc/1.11.4/A33XX-TEST (nonexistent)
+++ products/A33XX-glibc/1.11.4/A33XX-TEST (revision 76)
Property changes on: products/A33XX-glibc/1.11.4/A33XX-TEST
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/A33XX-glibc/1.11.4/Makefile
===================================================================
--- products/A33XX-glibc/1.11.4/Makefile (nonexistent)
+++ products/A33XX-glibc/1.11.4/Makefile (revision 76)
@@ -0,0 +1,35 @@
+
+
+COMPONENT_TARGETS = $(TOOLCHAIN_A33XX_GLIBC)
+
+export TOOLCHAIN_VERSION = 1.11.4
+
+include ../../../build-system/config.mk
+
+REQUIRES = core/gcc/14.2.0^full
+REQUIRES += tools/patchelf/0.18.0
+REQUIRES += core/gdb/16.2
+
+# ======= __END_OF_REQUIRES__ =======
+
+tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
+tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
+
+tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
+
+BUILD_TARGETS = $(tarball_target)
+
+PRODUCT_TARGETS = $(tarball)
+
+include ../../../build-system/core.mk
+
+
+$(tarball): $(tarball_target)
+
+$(tarball_target):
+ @echo ""
+ @echo "Creating $(tarball_name) tarball..."
+ @cd $(TOOLCHAINS_BASE_PATH) ; \
+ tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
+ @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
+ @touch $@
Index: products/A33XX-glibc/1.11.4
===================================================================
--- products/A33XX-glibc/1.11.4 (nonexistent)
+++ products/A33XX-glibc/1.11.4 (revision 76)
Property changes on: products/A33XX-glibc/1.11.4
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/A33XX-newlib/1.11.3/A33XX-TEST/main.c
===================================================================
--- products/A33XX-newlib/1.11.3/A33XX-TEST/main.c (revision 75)
+++ products/A33XX-newlib/1.11.3/A33XX-TEST/main.c (nonexistent)
@@ -1,17 +0,0 @@
-
-//#include <stdlib.h>
-//#include <inttypes.h>
-
-int main()
-{
- float d, f = 3.1415;
-
-// uint32_t a = 7, b = 3, c, r;
-
-// c = a / b;
-// r = a % b;
-
- d = f * 2.1;
-
- return( 0 );
-}
Index: products/A33XX-newlib/1.11.3/A33XX-TEST/build.sh
===================================================================
--- products/A33XX-newlib/1.11.3/A33XX-TEST/build.sh (revision 75)
+++ products/A33XX-newlib/1.11.3/A33XX-TEST/build.sh (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-DEBUG_FLAGS="-gdwarf-2"
-ARCH_FLAGS="-mthumb -march=armv6-m -mcpu=cortex-m0"
-#NO_STD_FLAGS=" -nostdlib -nostartfiles"
-
-$TARGET-gcc -g $DEBUG_FLAGS $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-
-$TARGET-gcc ${NO_STD_FLAGS} $ARCH_FLAGS $FPU_FLAGS $LDFLAGS -o main main.o
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/A33XX-newlib/1.11.3/A33XX-TEST/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/A33XX-newlib/1.11.3/A33XX-TEST/.config
===================================================================
--- products/A33XX-newlib/1.11.3/A33XX-TEST/.config (revision 75)
+++ products/A33XX-newlib/1.11.3/A33XX-TEST/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=arm-a33xx-eabi
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/arm-A33XX-eabi-newlib/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/A33XX-newlib/1.11.3/A33XX-TEST/clean.sh
===================================================================
--- products/A33XX-newlib/1.11.3/A33XX-TEST/clean.sh (revision 75)
+++ products/A33XX-newlib/1.11.3/A33XX-TEST/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/A33XX-newlib/1.11.3/A33XX-TEST/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/A33XX-newlib/1.11.3/A33XX-TEST
===================================================================
--- products/A33XX-newlib/1.11.3/A33XX-TEST (revision 75)
+++ products/A33XX-newlib/1.11.3/A33XX-TEST (nonexistent)
Property changes on: products/A33XX-newlib/1.11.3/A33XX-TEST
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/A33XX-newlib/1.11.3/Makefile
===================================================================
--- products/A33XX-newlib/1.11.3/Makefile (revision 75)
+++ products/A33XX-newlib/1.11.3/Makefile (nonexistent)
@@ -1,34 +0,0 @@
-
-
-COMPONENT_TARGETS = $(TOOLCHAIN_A33XX_NEWLIB)
-
-export TOOLCHAIN_VERSION = 1.11.3
-
-include ../../../build-system/config.mk
-
-REQUIRES = core/gcc/14.2.0^full
-REQUIRES += core/gdb/15.1
-
-# ======= __END_OF_REQUIRES__ =======
-
-tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
-tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
-
-tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
-
-BUILD_TARGETS = $(tarball_target)
-
-PRODUCT_TARGETS = $(tarball)
-
-include ../../../build-system/core.mk
-
-
-$(tarball): $(tarball_target)
-
-$(tarball_target):
- @echo ""
- @echo "Creating $(tarball_name) tarball..."
- @cd $(TOOLCHAINS_BASE_PATH) ; \
- tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
- @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
- @touch $@
Index: products/A33XX-newlib/1.11.3
===================================================================
--- products/A33XX-newlib/1.11.3 (revision 75)
+++ products/A33XX-newlib/1.11.3 (nonexistent)
Property changes on: products/A33XX-newlib/1.11.3
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/A33XX-newlib/1.11.4/A33XX-TEST/.config
===================================================================
--- products/A33XX-newlib/1.11.4/A33XX-TEST/.config (nonexistent)
+++ products/A33XX-newlib/1.11.4/A33XX-TEST/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=arm-a33xx-eabi
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/arm-A33XX-eabi-newlib/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/A33XX-newlib/1.11.4/A33XX-TEST/build.sh
===================================================================
--- products/A33XX-newlib/1.11.4/A33XX-TEST/build.sh (nonexistent)
+++ products/A33XX-newlib/1.11.4/A33XX-TEST/build.sh (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+DEBUG_FLAGS="-gdwarf-2"
+ARCH_FLAGS="-mthumb -march=armv6-m -mcpu=cortex-m0"
+#NO_STD_FLAGS=" -nostdlib -nostartfiles"
+
+$TARGET-gcc -g $DEBUG_FLAGS $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+
+$TARGET-gcc ${NO_STD_FLAGS} $ARCH_FLAGS $FPU_FLAGS $LDFLAGS -o main main.o
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/A33XX-newlib/1.11.4/A33XX-TEST/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/A33XX-newlib/1.11.4/A33XX-TEST/clean.sh
===================================================================
--- products/A33XX-newlib/1.11.4/A33XX-TEST/clean.sh (nonexistent)
+++ products/A33XX-newlib/1.11.4/A33XX-TEST/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/A33XX-newlib/1.11.4/A33XX-TEST/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/A33XX-newlib/1.11.4/A33XX-TEST/main.c
===================================================================
--- products/A33XX-newlib/1.11.4/A33XX-TEST/main.c (nonexistent)
+++ products/A33XX-newlib/1.11.4/A33XX-TEST/main.c (revision 76)
@@ -0,0 +1,17 @@
+
+//#include <stdlib.h>
+//#include <inttypes.h>
+
+int main()
+{
+ float d, f = 3.1415;
+
+// uint32_t a = 7, b = 3, c, r;
+
+// c = a / b;
+// r = a % b;
+
+ d = f * 2.1;
+
+ return( 0 );
+}
Index: products/A33XX-newlib/1.11.4/A33XX-TEST
===================================================================
--- products/A33XX-newlib/1.11.4/A33XX-TEST (nonexistent)
+++ products/A33XX-newlib/1.11.4/A33XX-TEST (revision 76)
Property changes on: products/A33XX-newlib/1.11.4/A33XX-TEST
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/A33XX-newlib/1.11.4/Makefile
===================================================================
--- products/A33XX-newlib/1.11.4/Makefile (nonexistent)
+++ products/A33XX-newlib/1.11.4/Makefile (revision 76)
@@ -0,0 +1,34 @@
+
+
+COMPONENT_TARGETS = $(TOOLCHAIN_A33XX_NEWLIB)
+
+export TOOLCHAIN_VERSION = 1.11.4
+
+include ../../../build-system/config.mk
+
+REQUIRES = core/gcc/14.2.0^full
+REQUIRES += core/gdb/16.2
+
+# ======= __END_OF_REQUIRES__ =======
+
+tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
+tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
+
+tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
+
+BUILD_TARGETS = $(tarball_target)
+
+PRODUCT_TARGETS = $(tarball)
+
+include ../../../build-system/core.mk
+
+
+$(tarball): $(tarball_target)
+
+$(tarball_target):
+ @echo ""
+ @echo "Creating $(tarball_name) tarball..."
+ @cd $(TOOLCHAINS_BASE_PATH) ; \
+ tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
+ @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
+ @touch $@
Index: products/A33XX-newlib/1.11.4
===================================================================
--- products/A33XX-newlib/1.11.4 (nonexistent)
+++ products/A33XX-newlib/1.11.4 (revision 76)
Property changes on: products/A33XX-newlib/1.11.4
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/A9XX-glibc/1.11.3/A9XX-TEST/main.c
===================================================================
--- products/A9XX-glibc/1.11.3/A9XX-TEST/main.c (revision 75)
+++ products/A9XX-glibc/1.11.3/A9XX-TEST/main.c (nonexistent)
@@ -1,17 +0,0 @@
-
-//#include <stdlib.h>
-//#include <inttypes.h>
-
-int main()
-{
- float d, f = 3.1415;
-
-// uint32_t a = 7, b = 3, c, r;
-
-// c = a / b;
-// r = a % b;
-
- d = f * 2.1;
-
- return( 0 );
-}
Index: products/A9XX-glibc/1.11.3/A9XX-TEST/build.sh
===================================================================
--- products/A9XX-glibc/1.11.3/A9XX-TEST/build.sh (revision 75)
+++ products/A9XX-glibc/1.11.3/A9XX-TEST/build.sh (nonexistent)
@@ -1,21 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-ARCH_FLAGS=" -march=armv8-a"
-
-FPU_FLAGS=" -mfloat-abi=hard -mfpu=neon-fp-armv8 -ftree-vectorize -fomit-frame-pointer -ffast-math"
-
-$TARGET-gcc -g -O3 -gdwarf-2 -fomit-frame-pointer $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/A9XX-glibc/1.11.3/A9XX-TEST/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/A9XX-glibc/1.11.3/A9XX-TEST/.config
===================================================================
--- products/A9XX-glibc/1.11.3/A9XX-TEST/.config (revision 75)
+++ products/A9XX-glibc/1.11.3/A9XX-TEST/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=armv8l-a9xx-linux-gnueabihf
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/armv8l-A9XX-linux-glibc/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/A9XX-glibc/1.11.3/A9XX-TEST/clean.sh
===================================================================
--- products/A9XX-glibc/1.11.3/A9XX-TEST/clean.sh (revision 75)
+++ products/A9XX-glibc/1.11.3/A9XX-TEST/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/A9XX-glibc/1.11.3/A9XX-TEST/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/A9XX-glibc/1.11.3/A9XX-TEST
===================================================================
--- products/A9XX-glibc/1.11.3/A9XX-TEST (revision 75)
+++ products/A9XX-glibc/1.11.3/A9XX-TEST (nonexistent)
Property changes on: products/A9XX-glibc/1.11.3/A9XX-TEST
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/A9XX-glibc/1.11.3/Makefile
===================================================================
--- products/A9XX-glibc/1.11.3/Makefile (revision 75)
+++ products/A9XX-glibc/1.11.3/Makefile (nonexistent)
@@ -1,35 +0,0 @@
-
-
-COMPONENT_TARGETS = $(TOOLCHAIN_A9XX_GLIBC)
-
-export TOOLCHAIN_VERSION = 1.11.3
-
-include ../../../build-system/config.mk
-
-REQUIRES = core/gcc/14.2.0^full
-REQUIRES += tools/patchelf/0.18.0
-REQUIRES += core/gdb/15.1
-
-# ======= __END_OF_REQUIRES__ =======
-
-tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
-tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
-
-tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
-
-BUILD_TARGETS = $(tarball_target)
-
-PRODUCT_TARGETS = $(tarball)
-
-include ../../../build-system/core.mk
-
-
-$(tarball): $(tarball_target)
-
-$(tarball_target):
- @echo ""
- @echo "Creating $(tarball_name) tarball..."
- @cd $(TOOLCHAINS_BASE_PATH) ; \
- tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
- @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
- @touch $@
Index: products/A9XX-glibc/1.11.3
===================================================================
--- products/A9XX-glibc/1.11.3 (revision 75)
+++ products/A9XX-glibc/1.11.3 (nonexistent)
Property changes on: products/A9XX-glibc/1.11.3
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/A9XX-glibc/1.11.4/A9XX-TEST/.config
===================================================================
--- products/A9XX-glibc/1.11.4/A9XX-TEST/.config (nonexistent)
+++ products/A9XX-glibc/1.11.4/A9XX-TEST/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=armv8l-a9xx-linux-gnueabihf
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/armv8l-A9XX-linux-glibc/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/A9XX-glibc/1.11.4/A9XX-TEST/build.sh
===================================================================
--- products/A9XX-glibc/1.11.4/A9XX-TEST/build.sh (nonexistent)
+++ products/A9XX-glibc/1.11.4/A9XX-TEST/build.sh (revision 76)
@@ -0,0 +1,21 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+ARCH_FLAGS=" -march=armv8-a"
+
+FPU_FLAGS=" -mfloat-abi=hard -mfpu=neon-fp-armv8 -ftree-vectorize -fomit-frame-pointer -ffast-math"
+
+$TARGET-gcc -g -O3 -gdwarf-2 -fomit-frame-pointer $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/A9XX-glibc/1.11.4/A9XX-TEST/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/A9XX-glibc/1.11.4/A9XX-TEST/clean.sh
===================================================================
--- products/A9XX-glibc/1.11.4/A9XX-TEST/clean.sh (nonexistent)
+++ products/A9XX-glibc/1.11.4/A9XX-TEST/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/A9XX-glibc/1.11.4/A9XX-TEST/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/A9XX-glibc/1.11.4/A9XX-TEST/main.c
===================================================================
--- products/A9XX-glibc/1.11.4/A9XX-TEST/main.c (nonexistent)
+++ products/A9XX-glibc/1.11.4/A9XX-TEST/main.c (revision 76)
@@ -0,0 +1,17 @@
+
+//#include <stdlib.h>
+//#include <inttypes.h>
+
+int main()
+{
+ float d, f = 3.1415;
+
+// uint32_t a = 7, b = 3, c, r;
+
+// c = a / b;
+// r = a % b;
+
+ d = f * 2.1;
+
+ return( 0 );
+}
Index: products/A9XX-glibc/1.11.4/A9XX-TEST
===================================================================
--- products/A9XX-glibc/1.11.4/A9XX-TEST (nonexistent)
+++ products/A9XX-glibc/1.11.4/A9XX-TEST (revision 76)
Property changes on: products/A9XX-glibc/1.11.4/A9XX-TEST
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/A9XX-glibc/1.11.4/Makefile
===================================================================
--- products/A9XX-glibc/1.11.4/Makefile (nonexistent)
+++ products/A9XX-glibc/1.11.4/Makefile (revision 76)
@@ -0,0 +1,35 @@
+
+
+COMPONENT_TARGETS = $(TOOLCHAIN_A9XX_GLIBC)
+
+export TOOLCHAIN_VERSION = 1.11.4
+
+include ../../../build-system/config.mk
+
+REQUIRES = core/gcc/14.2.0^full
+REQUIRES += tools/patchelf/0.18.0
+REQUIRES += core/gdb/16.2
+
+# ======= __END_OF_REQUIRES__ =======
+
+tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
+tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
+
+tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
+
+BUILD_TARGETS = $(tarball_target)
+
+PRODUCT_TARGETS = $(tarball)
+
+include ../../../build-system/core.mk
+
+
+$(tarball): $(tarball_target)
+
+$(tarball_target):
+ @echo ""
+ @echo "Creating $(tarball_name) tarball..."
+ @cd $(TOOLCHAINS_BASE_PATH) ; \
+ tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
+ @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
+ @touch $@
Index: products/A9XX-glibc/1.11.4
===================================================================
--- products/A9XX-glibc/1.11.4 (nonexistent)
+++ products/A9XX-glibc/1.11.4 (revision 76)
Property changes on: products/A9XX-glibc/1.11.4
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/A9XX-newlib/1.11.3/A9XX-TEST/main.c
===================================================================
--- products/A9XX-newlib/1.11.3/A9XX-TEST/main.c (revision 75)
+++ products/A9XX-newlib/1.11.3/A9XX-TEST/main.c (nonexistent)
@@ -1,17 +0,0 @@
-
-#include <stdlib.h>
-#include <inttypes.h>
-
-int main()
-{
- double d, f = 3.1415;
-
- uint32_t a = 7, b = 3, c, r;
-
- c = a / b;
- r = a % b;
-
- d = f * 2.0;
-
- return( 0 );
-}
Index: products/A9XX-newlib/1.11.3/A9XX-TEST/build.sh
===================================================================
--- products/A9XX-newlib/1.11.3/A9XX-TEST/build.sh (revision 75)
+++ products/A9XX-newlib/1.11.3/A9XX-TEST/build.sh (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-DEBUG_FLAGS="-gdwarf-2"
-ARCH_FLAGS="-march=armv7-m -mcpu=cortex-m3 -mthumb"
-#NO_STD_FLAGS=" -nostdlib -nostartfiles"
-
-$TARGET-gcc -g $DEBUG_FLAGS $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-
-$TARGET-gcc ${NO_STD_FLAGS} $ARCH_FLAGS $FPU_FLAGS $LDFLAGS -o main main.o
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/A9XX-newlib/1.11.3/A9XX-TEST/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/A9XX-newlib/1.11.3/A9XX-TEST/.config
===================================================================
--- products/A9XX-newlib/1.11.3/A9XX-TEST/.config (revision 75)
+++ products/A9XX-newlib/1.11.3/A9XX-TEST/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=arm-a9xx-eabi
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/arm-A9XX-eabi-newlib/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/A9XX-newlib/1.11.3/A9XX-TEST/clean.sh
===================================================================
--- products/A9XX-newlib/1.11.3/A9XX-TEST/clean.sh (revision 75)
+++ products/A9XX-newlib/1.11.3/A9XX-TEST/clean.sh (nonexistent)
@@ -1,11 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.gdb
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/A9XX-newlib/1.11.3/A9XX-TEST/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/A9XX-newlib/1.11.3/A9XX-TEST
===================================================================
--- products/A9XX-newlib/1.11.3/A9XX-TEST (revision 75)
+++ products/A9XX-newlib/1.11.3/A9XX-TEST (nonexistent)
Property changes on: products/A9XX-newlib/1.11.3/A9XX-TEST
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/A9XX-newlib/1.11.3/A9XX-TEST-fpv4/main.c
===================================================================
--- products/A9XX-newlib/1.11.3/A9XX-TEST-fpv4/main.c (revision 75)
+++ products/A9XX-newlib/1.11.3/A9XX-TEST-fpv4/main.c (nonexistent)
@@ -1,17 +0,0 @@
-
-#include <stdlib.h>
-#include <inttypes.h>
-
-int main()
-{
- double d, f = 3.1415;
-
- uint32_t a = 7, b = 3, c, r;
-
- c = a / b;
- r = a % b;
-
- d = f * 2.0;
-
- return( 0 );
-}
Index: products/A9XX-newlib/1.11.3/A9XX-TEST-fpv4/build.sh
===================================================================
--- products/A9XX-newlib/1.11.3/A9XX-TEST-fpv4/build.sh (revision 75)
+++ products/A9XX-newlib/1.11.3/A9XX-TEST-fpv4/build.sh (nonexistent)
@@ -1,23 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-DEBUG_FLAGS="-gdwarf-2"
-ARCH_FLAGS="-march=armv7-m -mcpu=cortex-m3 -mthumb"
-FPU_FLAGS=" -mfpu=fpv4-sp-d16 -mfloat-abi=hard"
-#NO_STD_FLAGS=" -nostdlib -nostartfiles"
-
-$TARGET-gcc -g $DEBUG_FLAGS -fomit-frame-pointer $ARCH_FLAGS $FPU_FLAGS -c -o main.o main.c
-
-$TARGET-gcc ${NO_STD_FLAGS} $ARCH_FLAGS $FPU_FLAGS $LDFLAGS -o main main.o
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/A9XX-newlib/1.11.3/A9XX-TEST-fpv4/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/A9XX-newlib/1.11.3/A9XX-TEST-fpv4/.config
===================================================================
--- products/A9XX-newlib/1.11.3/A9XX-TEST-fpv4/.config (revision 75)
+++ products/A9XX-newlib/1.11.3/A9XX-TEST-fpv4/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=arm-a9xx-eabi
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/arm-A9XX-eabi-newlib/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/A9XX-newlib/1.11.3/A9XX-TEST-fpv4/clean.sh
===================================================================
--- products/A9XX-newlib/1.11.3/A9XX-TEST-fpv4/clean.sh (revision 75)
+++ products/A9XX-newlib/1.11.3/A9XX-TEST-fpv4/clean.sh (nonexistent)
@@ -1,11 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.gdb
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/A9XX-newlib/1.11.3/A9XX-TEST-fpv4/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/A9XX-newlib/1.11.3/A9XX-TEST-fpv4
===================================================================
--- products/A9XX-newlib/1.11.3/A9XX-TEST-fpv4 (revision 75)
+++ products/A9XX-newlib/1.11.3/A9XX-TEST-fpv4 (nonexistent)
Property changes on: products/A9XX-newlib/1.11.3/A9XX-TEST-fpv4
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/A9XX-newlib/1.11.3/Makefile
===================================================================
--- products/A9XX-newlib/1.11.3/Makefile (revision 75)
+++ products/A9XX-newlib/1.11.3/Makefile (nonexistent)
@@ -1,34 +0,0 @@
-
-
-COMPONENT_TARGETS = $(TOOLCHAIN_A9XX_NEWLIB)
-
-export TOOLCHAIN_VERSION = 1.11.3
-
-include ../../../build-system/config.mk
-
-REQUIRES = core/gcc/14.2.0^full
-REQUIRES += core/gdb/15.1
-
-# ======= __END_OF_REQUIRES__ =======
-
-tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
-tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
-
-tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
-
-BUILD_TARGETS = $(tarball_target)
-
-PRODUCT_TARGETS = $(tarball)
-
-include ../../../build-system/core.mk
-
-
-$(tarball): $(tarball_target)
-
-$(tarball_target): $(build_requires)
- @echo ""
- @echo "Creating $(tarball_name) tarball..."
- @cd $(TOOLCHAINS_BASE_PATH) ; \
- tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
- @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
- @touch $@
Index: products/A9XX-newlib/1.11.3
===================================================================
--- products/A9XX-newlib/1.11.3 (revision 75)
+++ products/A9XX-newlib/1.11.3 (nonexistent)
Property changes on: products/A9XX-newlib/1.11.3
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/A9XX-newlib/1.11.4/A9XX-TEST/.config
===================================================================
--- products/A9XX-newlib/1.11.4/A9XX-TEST/.config (nonexistent)
+++ products/A9XX-newlib/1.11.4/A9XX-TEST/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=arm-a9xx-eabi
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/arm-A9XX-eabi-newlib/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/A9XX-newlib/1.11.4/A9XX-TEST/build.sh
===================================================================
--- products/A9XX-newlib/1.11.4/A9XX-TEST/build.sh (nonexistent)
+++ products/A9XX-newlib/1.11.4/A9XX-TEST/build.sh (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+DEBUG_FLAGS="-gdwarf-2"
+ARCH_FLAGS="-march=armv7-m -mcpu=cortex-m3 -mthumb"
+#NO_STD_FLAGS=" -nostdlib -nostartfiles"
+
+$TARGET-gcc -g $DEBUG_FLAGS $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+
+$TARGET-gcc ${NO_STD_FLAGS} $ARCH_FLAGS $FPU_FLAGS $LDFLAGS -o main main.o
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/A9XX-newlib/1.11.4/A9XX-TEST/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/A9XX-newlib/1.11.4/A9XX-TEST/clean.sh
===================================================================
--- products/A9XX-newlib/1.11.4/A9XX-TEST/clean.sh (nonexistent)
+++ products/A9XX-newlib/1.11.4/A9XX-TEST/clean.sh (revision 76)
@@ -0,0 +1,11 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.gdb
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/A9XX-newlib/1.11.4/A9XX-TEST/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/A9XX-newlib/1.11.4/A9XX-TEST/main.c
===================================================================
--- products/A9XX-newlib/1.11.4/A9XX-TEST/main.c (nonexistent)
+++ products/A9XX-newlib/1.11.4/A9XX-TEST/main.c (revision 76)
@@ -0,0 +1,17 @@
+
+#include <stdlib.h>
+#include <inttypes.h>
+
+int main()
+{
+ double d, f = 3.1415;
+
+ uint32_t a = 7, b = 3, c, r;
+
+ c = a / b;
+ r = a % b;
+
+ d = f * 2.0;
+
+ return( 0 );
+}
Index: products/A9XX-newlib/1.11.4/A9XX-TEST
===================================================================
--- products/A9XX-newlib/1.11.4/A9XX-TEST (nonexistent)
+++ products/A9XX-newlib/1.11.4/A9XX-TEST (revision 76)
Property changes on: products/A9XX-newlib/1.11.4/A9XX-TEST
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/A9XX-newlib/1.11.4/A9XX-TEST-fpv4/.config
===================================================================
--- products/A9XX-newlib/1.11.4/A9XX-TEST-fpv4/.config (nonexistent)
+++ products/A9XX-newlib/1.11.4/A9XX-TEST-fpv4/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=arm-a9xx-eabi
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/arm-A9XX-eabi-newlib/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/A9XX-newlib/1.11.4/A9XX-TEST-fpv4/build.sh
===================================================================
--- products/A9XX-newlib/1.11.4/A9XX-TEST-fpv4/build.sh (nonexistent)
+++ products/A9XX-newlib/1.11.4/A9XX-TEST-fpv4/build.sh (revision 76)
@@ -0,0 +1,23 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+DEBUG_FLAGS="-gdwarf-2"
+ARCH_FLAGS="-march=armv7-m -mcpu=cortex-m3 -mthumb"
+FPU_FLAGS=" -mfpu=fpv4-sp-d16 -mfloat-abi=hard"
+#NO_STD_FLAGS=" -nostdlib -nostartfiles"
+
+$TARGET-gcc -g $DEBUG_FLAGS -fomit-frame-pointer $ARCH_FLAGS $FPU_FLAGS -c -o main.o main.c
+
+$TARGET-gcc ${NO_STD_FLAGS} $ARCH_FLAGS $FPU_FLAGS $LDFLAGS -o main main.o
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/A9XX-newlib/1.11.4/A9XX-TEST-fpv4/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/A9XX-newlib/1.11.4/A9XX-TEST-fpv4/clean.sh
===================================================================
--- products/A9XX-newlib/1.11.4/A9XX-TEST-fpv4/clean.sh (nonexistent)
+++ products/A9XX-newlib/1.11.4/A9XX-TEST-fpv4/clean.sh (revision 76)
@@ -0,0 +1,11 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.gdb
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/A9XX-newlib/1.11.4/A9XX-TEST-fpv4/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/A9XX-newlib/1.11.4/A9XX-TEST-fpv4/main.c
===================================================================
--- products/A9XX-newlib/1.11.4/A9XX-TEST-fpv4/main.c (nonexistent)
+++ products/A9XX-newlib/1.11.4/A9XX-TEST-fpv4/main.c (revision 76)
@@ -0,0 +1,17 @@
+
+#include <stdlib.h>
+#include <inttypes.h>
+
+int main()
+{
+ double d, f = 3.1415;
+
+ uint32_t a = 7, b = 3, c, r;
+
+ c = a / b;
+ r = a % b;
+
+ d = f * 2.0;
+
+ return( 0 );
+}
Index: products/A9XX-newlib/1.11.4/A9XX-TEST-fpv4
===================================================================
--- products/A9XX-newlib/1.11.4/A9XX-TEST-fpv4 (nonexistent)
+++ products/A9XX-newlib/1.11.4/A9XX-TEST-fpv4 (revision 76)
Property changes on: products/A9XX-newlib/1.11.4/A9XX-TEST-fpv4
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/A9XX-newlib/1.11.4/Makefile
===================================================================
--- products/A9XX-newlib/1.11.4/Makefile (nonexistent)
+++ products/A9XX-newlib/1.11.4/Makefile (revision 76)
@@ -0,0 +1,34 @@
+
+
+COMPONENT_TARGETS = $(TOOLCHAIN_A9XX_NEWLIB)
+
+export TOOLCHAIN_VERSION = 1.11.4
+
+include ../../../build-system/config.mk
+
+REQUIRES = core/gcc/14.2.0^full
+REQUIRES += core/gdb/16.2
+
+# ======= __END_OF_REQUIRES__ =======
+
+tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
+tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
+
+tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
+
+BUILD_TARGETS = $(tarball_target)
+
+PRODUCT_TARGETS = $(tarball)
+
+include ../../../build-system/core.mk
+
+
+$(tarball): $(tarball_target)
+
+$(tarball_target): $(build_requires)
+ @echo ""
+ @echo "Creating $(tarball_name) tarball..."
+ @cd $(TOOLCHAINS_BASE_PATH) ; \
+ tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
+ @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
+ @touch $@
Index: products/A9XX-newlib/1.11.4
===================================================================
--- products/A9XX-newlib/1.11.4 (nonexistent)
+++ products/A9XX-newlib/1.11.4 (revision 76)
Property changes on: products/A9XX-newlib/1.11.4
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/AM335X-glibc/1.11.3/AM335X-TEST-neon/main.c
===================================================================
--- products/AM335X-glibc/1.11.3/AM335X-TEST-neon/main.c (revision 75)
+++ products/AM335X-glibc/1.11.3/AM335X-TEST-neon/main.c (nonexistent)
@@ -1,17 +0,0 @@
-
-//#include <stdlib.h>
-//#include <inttypes.h>
-
-int main()
-{
- float d, f = 3.1415;
-
-// uint32_t a = 7, b = 3, c, r;
-
-// c = a / b;
-// r = a % b;
-
- d = f * 2.1;
-
- return( 0 );
-}
Index: products/AM335X-glibc/1.11.3/AM335X-TEST-neon/build.sh
===================================================================
--- products/AM335X-glibc/1.11.3/AM335X-TEST-neon/build.sh (revision 75)
+++ products/AM335X-glibc/1.11.3/AM335X-TEST-neon/build.sh (nonexistent)
@@ -1,21 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-ARCH_FLAGS=" -march=armv7-a -mtune=cortex-a8"
-
-FPU_FLAGS=" -mfloat-abi=hard -mfpu=neon -ftree-vectorize -fomit-frame-pointer -ffast-math"
-
-$TARGET-gcc -g -O3 -gdwarf-2 -fomit-frame-pointer $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/AM335X-glibc/1.11.3/AM335X-TEST-neon/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/AM335X-glibc/1.11.3/AM335X-TEST-neon/.config
===================================================================
--- products/AM335X-glibc/1.11.3/AM335X-TEST-neon/.config (revision 75)
+++ products/AM335X-glibc/1.11.3/AM335X-TEST-neon/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=arm-am335x-linux-gnueabihf
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/arm-AM335X-linux-glibc/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/AM335X-glibc/1.11.3/AM335X-TEST-neon/clean.sh
===================================================================
--- products/AM335X-glibc/1.11.3/AM335X-TEST-neon/clean.sh (revision 75)
+++ products/AM335X-glibc/1.11.3/AM335X-TEST-neon/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/AM335X-glibc/1.11.3/AM335X-TEST-neon/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/AM335X-glibc/1.11.3/AM335X-TEST-neon
===================================================================
--- products/AM335X-glibc/1.11.3/AM335X-TEST-neon (revision 75)
+++ products/AM335X-glibc/1.11.3/AM335X-TEST-neon (nonexistent)
Property changes on: products/AM335X-glibc/1.11.3/AM335X-TEST-neon
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/AM335X-glibc/1.11.3/Makefile
===================================================================
--- products/AM335X-glibc/1.11.3/Makefile (revision 75)
+++ products/AM335X-glibc/1.11.3/Makefile (nonexistent)
@@ -1,35 +0,0 @@
-
-
-COMPONENT_TARGETS = $(TOOLCHAIN_AM335X_GLIBC)
-
-export TOOLCHAIN_VERSION = 1.11.3
-
-include ../../../build-system/config.mk
-
-REQUIRES = core/gcc/14.2.0^full
-REQUIRES += tools/patchelf/0.18.0
-REQUIRES += core/gdb/15.1
-
-# ======= __END_OF_REQUIRES__ =======
-
-tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
-tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
-
-tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
-
-BUILD_TARGETS = $(tarball_target)
-
-PRODUCT_TARGETS = $(tarball)
-
-include ../../../build-system/core.mk
-
-
-$(tarball): $(tarball_target)
-
-$(tarball_target):
- @echo ""
- @echo "Creating $(tarball_name) tarball..."
- @cd $(TOOLCHAINS_BASE_PATH) ; \
- tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
- @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
- @touch $@
Index: products/AM335X-glibc/1.11.3
===================================================================
--- products/AM335X-glibc/1.11.3 (revision 75)
+++ products/AM335X-glibc/1.11.3 (nonexistent)
Property changes on: products/AM335X-glibc/1.11.3
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/AM335X-glibc/1.11.4/AM335X-TEST-neon/.config
===================================================================
--- products/AM335X-glibc/1.11.4/AM335X-TEST-neon/.config (nonexistent)
+++ products/AM335X-glibc/1.11.4/AM335X-TEST-neon/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=arm-am335x-linux-gnueabihf
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/arm-AM335X-linux-glibc/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/AM335X-glibc/1.11.4/AM335X-TEST-neon/build.sh
===================================================================
--- products/AM335X-glibc/1.11.4/AM335X-TEST-neon/build.sh (nonexistent)
+++ products/AM335X-glibc/1.11.4/AM335X-TEST-neon/build.sh (revision 76)
@@ -0,0 +1,21 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+ARCH_FLAGS=" -march=armv7-a -mtune=cortex-a8"
+
+FPU_FLAGS=" -mfloat-abi=hard -mfpu=neon -ftree-vectorize -fomit-frame-pointer -ffast-math"
+
+$TARGET-gcc -g -O3 -gdwarf-2 -fomit-frame-pointer $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/AM335X-glibc/1.11.4/AM335X-TEST-neon/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/AM335X-glibc/1.11.4/AM335X-TEST-neon/clean.sh
===================================================================
--- products/AM335X-glibc/1.11.4/AM335X-TEST-neon/clean.sh (nonexistent)
+++ products/AM335X-glibc/1.11.4/AM335X-TEST-neon/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/AM335X-glibc/1.11.4/AM335X-TEST-neon/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/AM335X-glibc/1.11.4/AM335X-TEST-neon/main.c
===================================================================
--- products/AM335X-glibc/1.11.4/AM335X-TEST-neon/main.c (nonexistent)
+++ products/AM335X-glibc/1.11.4/AM335X-TEST-neon/main.c (revision 76)
@@ -0,0 +1,17 @@
+
+//#include <stdlib.h>
+//#include <inttypes.h>
+
+int main()
+{
+ float d, f = 3.1415;
+
+// uint32_t a = 7, b = 3, c, r;
+
+// c = a / b;
+// r = a % b;
+
+ d = f * 2.1;
+
+ return( 0 );
+}
Index: products/AM335X-glibc/1.11.4/AM335X-TEST-neon
===================================================================
--- products/AM335X-glibc/1.11.4/AM335X-TEST-neon (nonexistent)
+++ products/AM335X-glibc/1.11.4/AM335X-TEST-neon (revision 76)
Property changes on: products/AM335X-glibc/1.11.4/AM335X-TEST-neon
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/AM335X-glibc/1.11.4/Makefile
===================================================================
--- products/AM335X-glibc/1.11.4/Makefile (nonexistent)
+++ products/AM335X-glibc/1.11.4/Makefile (revision 76)
@@ -0,0 +1,35 @@
+
+
+COMPONENT_TARGETS = $(TOOLCHAIN_AM335X_GLIBC)
+
+export TOOLCHAIN_VERSION = 1.11.4
+
+include ../../../build-system/config.mk
+
+REQUIRES = core/gcc/14.2.0^full
+REQUIRES += tools/patchelf/0.18.0
+REQUIRES += core/gdb/16.2
+
+# ======= __END_OF_REQUIRES__ =======
+
+tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
+tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
+
+tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
+
+BUILD_TARGETS = $(tarball_target)
+
+PRODUCT_TARGETS = $(tarball)
+
+include ../../../build-system/core.mk
+
+
+$(tarball): $(tarball_target)
+
+$(tarball_target):
+ @echo ""
+ @echo "Creating $(tarball_name) tarball..."
+ @cd $(TOOLCHAINS_BASE_PATH) ; \
+ tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
+ @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
+ @touch $@
Index: products/AM335X-glibc/1.11.4
===================================================================
--- products/AM335X-glibc/1.11.4 (nonexistent)
+++ products/AM335X-glibc/1.11.4 (revision 76)
Property changes on: products/AM335X-glibc/1.11.4
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/ARM32-newlib/1.11.3/OMAP543X-TEST/main.c
===================================================================
--- products/ARM32-newlib/1.11.3/OMAP543X-TEST/main.c (revision 75)
+++ products/ARM32-newlib/1.11.3/OMAP543X-TEST/main.c (nonexistent)
@@ -1,16 +0,0 @@
-
-#include <stdlib.h>
-#include <inttypes.h>
-
-int main()
-{
- uint32_t a = 7, b = 3, c, r;
- float pi = 3.1415, e = 2.71, f;
-
- c = a / b;
- r = a % b;
-
- f = pi * e;
-
- return( 0 );
-}
Index: products/ARM32-newlib/1.11.3/OMAP543X-TEST/build.sh
===================================================================
--- products/ARM32-newlib/1.11.3/OMAP543X-TEST/build.sh (revision 75)
+++ products/ARM32-newlib/1.11.3/OMAP543X-TEST/build.sh (nonexistent)
@@ -1,19 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-ARCH_OPTIONS=" -march=armv7ve -mtune=cortex-a15 -mfpu=neon-vfpv4 -mfloat-abi=hard"
-
-$TARGET-gcc -g -gdwarf-2 -fomit-frame-pointer ${ARCH_OPTIONS} -mlittle-endian -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-$TARGET-gcc ${ARCH_OPTIONS} -mlittle-endian -o main main.o
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/ARM32-newlib/1.11.3/OMAP543X-TEST/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/ARM32-newlib/1.11.3/OMAP543X-TEST/.config
===================================================================
--- products/ARM32-newlib/1.11.3/OMAP543X-TEST/.config (revision 75)
+++ products/ARM32-newlib/1.11.3/OMAP543X-TEST/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=arm-none-eabi
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/arm-NONE-eabi-newlib/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/ARM32-newlib/1.11.3/OMAP543X-TEST/clean.sh
===================================================================
--- products/ARM32-newlib/1.11.3/OMAP543X-TEST/clean.sh (revision 75)
+++ products/ARM32-newlib/1.11.3/OMAP543X-TEST/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/ARM32-newlib/1.11.3/OMAP543X-TEST/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/ARM32-newlib/1.11.3/OMAP543X-TEST
===================================================================
--- products/ARM32-newlib/1.11.3/OMAP543X-TEST (revision 75)
+++ products/ARM32-newlib/1.11.3/OMAP543X-TEST (nonexistent)
Property changes on: products/ARM32-newlib/1.11.3/OMAP543X-TEST
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/ARM32-newlib/1.11.3/armv8l-TEST/main.c
===================================================================
--- products/ARM32-newlib/1.11.3/armv8l-TEST/main.c (revision 75)
+++ products/ARM32-newlib/1.11.3/armv8l-TEST/main.c (nonexistent)
@@ -1,16 +0,0 @@
-
-#include <stdlib.h>
-#include <inttypes.h>
-
-int main()
-{
- uint32_t a = 7, b = 3, c, r;
- float pi = 3.1415, e = 2.71, f;
-
- c = a / b;
- r = a % b;
-
- f = pi * e;
-
- return( 0 );
-}
Index: products/ARM32-newlib/1.11.3/armv8l-TEST/build.sh
===================================================================
--- products/ARM32-newlib/1.11.3/armv8l-TEST/build.sh (revision 75)
+++ products/ARM32-newlib/1.11.3/armv8l-TEST/build.sh (nonexistent)
@@ -1,19 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-ARCH_OPTIONS=" -march=armv8-a -mcpu=cortex-a53 -mfpu=neon-fp-armv8 -mfloat-abi=hard"
-
-$TARGET-gcc -g -gdwarf-2 -fomit-frame-pointer ${ARCH_OPTIONS} -mlittle-endian -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-$TARGET-gcc ${ARCH_OPTIONS} -mlittle-endian -o main main.o
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/ARM32-newlib/1.11.3/armv8l-TEST/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/ARM32-newlib/1.11.3/armv8l-TEST/.config
===================================================================
--- products/ARM32-newlib/1.11.3/armv8l-TEST/.config (revision 75)
+++ products/ARM32-newlib/1.11.3/armv8l-TEST/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=arm-none-eabi
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/arm-NONE-eabi-newlib/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/ARM32-newlib/1.11.3/armv8l-TEST/clean.sh
===================================================================
--- products/ARM32-newlib/1.11.3/armv8l-TEST/clean.sh (revision 75)
+++ products/ARM32-newlib/1.11.3/armv8l-TEST/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/ARM32-newlib/1.11.3/armv8l-TEST/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/ARM32-newlib/1.11.3/armv8l-TEST
===================================================================
--- products/ARM32-newlib/1.11.3/armv8l-TEST (revision 75)
+++ products/ARM32-newlib/1.11.3/armv8l-TEST (nonexistent)
Property changes on: products/ARM32-newlib/1.11.3/armv8l-TEST
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/ARM32-newlib/1.11.3/S8XX-TEST/main.c
===================================================================
--- products/ARM32-newlib/1.11.3/S8XX-TEST/main.c (revision 75)
+++ products/ARM32-newlib/1.11.3/S8XX-TEST/main.c (nonexistent)
@@ -1,16 +0,0 @@
-
-#include <stdlib.h>
-#include <inttypes.h>
-
-int main()
-{
- uint32_t a = 7, b = 3, c, r;
- float pi = 3.1415, e = 2.71, f;
-
- c = a / b;
- r = a % b;
-
- f = pi * e;
-
- return( 0 );
-}
Index: products/ARM32-newlib/1.11.3/S8XX-TEST/build.sh
===================================================================
--- products/ARM32-newlib/1.11.3/S8XX-TEST/build.sh (revision 75)
+++ products/ARM32-newlib/1.11.3/S8XX-TEST/build.sh (nonexistent)
@@ -1,19 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-ARCH_OPTIONS=" -march=armv7-a -mtune=cortex-a5 -mfpu=neon -mfloat-abi=hard"
-
-$TARGET-gcc -g -gdwarf-2 -fomit-frame-pointer ${ARCH_OPTIONS} -mlittle-endian -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-$TARGET-gcc ${ARCH_OPTIONS} -mlittle-endian -o main main.o
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/ARM32-newlib/1.11.3/S8XX-TEST/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/ARM32-newlib/1.11.3/S8XX-TEST/.config
===================================================================
--- products/ARM32-newlib/1.11.3/S8XX-TEST/.config (revision 75)
+++ products/ARM32-newlib/1.11.3/S8XX-TEST/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=arm-none-eabi
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/arm-NONE-eabi-newlib/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/ARM32-newlib/1.11.3/S8XX-TEST/clean.sh
===================================================================
--- products/ARM32-newlib/1.11.3/S8XX-TEST/clean.sh (revision 75)
+++ products/ARM32-newlib/1.11.3/S8XX-TEST/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/ARM32-newlib/1.11.3/S8XX-TEST/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/ARM32-newlib/1.11.3/S8XX-TEST
===================================================================
--- products/ARM32-newlib/1.11.3/S8XX-TEST (revision 75)
+++ products/ARM32-newlib/1.11.3/S8XX-TEST (nonexistent)
Property changes on: products/ARM32-newlib/1.11.3/S8XX-TEST
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/ARM32-newlib/1.11.3/RK328X-TEST/main.c
===================================================================
--- products/ARM32-newlib/1.11.3/RK328X-TEST/main.c (revision 75)
+++ products/ARM32-newlib/1.11.3/RK328X-TEST/main.c (nonexistent)
@@ -1,16 +0,0 @@
-
-#include <stdlib.h>
-#include <inttypes.h>
-
-int main()
-{
- uint32_t a = 7, b = 3, c, r;
- float pi = 3.1415, e = 2.71, f;
-
- c = a / b;
- r = a % b;
-
- f = pi * e;
-
- return( 0 );
-}
Index: products/ARM32-newlib/1.11.3/RK328X-TEST/build.sh
===================================================================
--- products/ARM32-newlib/1.11.3/RK328X-TEST/build.sh (revision 75)
+++ products/ARM32-newlib/1.11.3/RK328X-TEST/build.sh (nonexistent)
@@ -1,19 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-ARCH_OPTIONS=" -march=armv7ve -mtune=cortex-a17 -mfpu=neon-vfpv4 -mfloat-abi=hard"
-
-$TARGET-gcc -g -gdwarf-2 -fomit-frame-pointer ${ARCH_OPTIONS} -mlittle-endian -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-$TARGET-gcc ${ARCH_OPTIONS} -mlittle-endian -o main main.o
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/ARM32-newlib/1.11.3/RK328X-TEST/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/ARM32-newlib/1.11.3/RK328X-TEST/.config
===================================================================
--- products/ARM32-newlib/1.11.3/RK328X-TEST/.config (revision 75)
+++ products/ARM32-newlib/1.11.3/RK328X-TEST/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=arm-none-eabi
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/arm-NONE-eabi-newlib/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/ARM32-newlib/1.11.3/RK328X-TEST/clean.sh
===================================================================
--- products/ARM32-newlib/1.11.3/RK328X-TEST/clean.sh (revision 75)
+++ products/ARM32-newlib/1.11.3/RK328X-TEST/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/ARM32-newlib/1.11.3/RK328X-TEST/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/ARM32-newlib/1.11.3/RK328X-TEST
===================================================================
--- products/ARM32-newlib/1.11.3/RK328X-TEST (revision 75)
+++ products/ARM32-newlib/1.11.3/RK328X-TEST (nonexistent)
Property changes on: products/ARM32-newlib/1.11.3/RK328X-TEST
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/ARM32-newlib/1.11.3/IMX6-TEST/main.c
===================================================================
--- products/ARM32-newlib/1.11.3/IMX6-TEST/main.c (revision 75)
+++ products/ARM32-newlib/1.11.3/IMX6-TEST/main.c (nonexistent)
@@ -1,16 +0,0 @@
-
-#include <stdlib.h>
-#include <inttypes.h>
-
-int main()
-{
- uint32_t a = 7, b = 3, c, r;
- float pi = 3.1415, e = 2.71, f;
-
- c = a / b;
- r = a % b;
-
- f = pi * e;
-
- return( 0 );
-}
Index: products/ARM32-newlib/1.11.3/IMX6-TEST/build.sh
===================================================================
--- products/ARM32-newlib/1.11.3/IMX6-TEST/build.sh (revision 75)
+++ products/ARM32-newlib/1.11.3/IMX6-TEST/build.sh (nonexistent)
@@ -1,19 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-ARCH_OPTIONS=" -march=armv7-a -mtune=cortex-a9 -mfpu=vfpv3 -mfloat-abi=hard"
-
-$TARGET-gcc -g -gdwarf-2 -fomit-frame-pointer ${ARCH_OPTIONS} -mlittle-endian -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-$TARGET-gcc ${ARCH_OPTIONS} -mlittle-endian -o main main.o
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/ARM32-newlib/1.11.3/IMX6-TEST/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/ARM32-newlib/1.11.3/IMX6-TEST/.config
===================================================================
--- products/ARM32-newlib/1.11.3/IMX6-TEST/.config (revision 75)
+++ products/ARM32-newlib/1.11.3/IMX6-TEST/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=arm-none-eabi
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/arm-NONE-eabi-newlib/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/ARM32-newlib/1.11.3/IMX6-TEST/clean.sh
===================================================================
--- products/ARM32-newlib/1.11.3/IMX6-TEST/clean.sh (revision 75)
+++ products/ARM32-newlib/1.11.3/IMX6-TEST/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/ARM32-newlib/1.11.3/IMX6-TEST/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/ARM32-newlib/1.11.3/IMX6-TEST
===================================================================
--- products/ARM32-newlib/1.11.3/IMX6-TEST (revision 75)
+++ products/ARM32-newlib/1.11.3/IMX6-TEST (nonexistent)
Property changes on: products/ARM32-newlib/1.11.3/IMX6-TEST
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/ARM32-newlib/1.11.3/A1X-TEST/main.c
===================================================================
--- products/ARM32-newlib/1.11.3/A1X-TEST/main.c (revision 75)
+++ products/ARM32-newlib/1.11.3/A1X-TEST/main.c (nonexistent)
@@ -1,16 +0,0 @@
-
-#include <stdlib.h>
-#include <inttypes.h>
-
-int main()
-{
- uint32_t a = 7, b = 3, c, r;
- float pi = 3.1415, e = 2.71, f;
-
- c = a / b;
- r = a % b;
-
- f = pi * e;
-
- return( 0 );
-}
Index: products/ARM32-newlib/1.11.3/A1X-TEST/build.sh
===================================================================
--- products/ARM32-newlib/1.11.3/A1X-TEST/build.sh (revision 75)
+++ products/ARM32-newlib/1.11.3/A1X-TEST/build.sh (nonexistent)
@@ -1,19 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-ARCH_OPTIONS=" -march=armv7-a -mtune=cortex-a8 -mfpu=neon -mfloat-abi=hard"
-
-$TARGET-gcc -g -gdwarf-2 -fomit-frame-pointer ${ARCH_OPTIONS} -mlittle-endian -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-$TARGET-gcc ${ARCH_OPTIONS} -mlittle-endian -o main main.o
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/ARM32-newlib/1.11.3/A1X-TEST/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/ARM32-newlib/1.11.3/A1X-TEST/.config
===================================================================
--- products/ARM32-newlib/1.11.3/A1X-TEST/.config (revision 75)
+++ products/ARM32-newlib/1.11.3/A1X-TEST/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=arm-none-eabi
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/arm-NONE-eabi-newlib/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/ARM32-newlib/1.11.3/A1X-TEST/clean.sh
===================================================================
--- products/ARM32-newlib/1.11.3/A1X-TEST/clean.sh (revision 75)
+++ products/ARM32-newlib/1.11.3/A1X-TEST/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/ARM32-newlib/1.11.3/A1X-TEST/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/ARM32-newlib/1.11.3/A1X-TEST
===================================================================
--- products/ARM32-newlib/1.11.3/A1X-TEST (revision 75)
+++ products/ARM32-newlib/1.11.3/A1X-TEST (nonexistent)
Property changes on: products/ARM32-newlib/1.11.3/A1X-TEST
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/ARM32-newlib/1.11.3/A2X-TEST/main.c
===================================================================
--- products/ARM32-newlib/1.11.3/A2X-TEST/main.c (revision 75)
+++ products/ARM32-newlib/1.11.3/A2X-TEST/main.c (nonexistent)
@@ -1,16 +0,0 @@
-
-#include <stdlib.h>
-#include <inttypes.h>
-
-int main()
-{
- uint32_t a = 7, b = 3, c, r;
- float pi = 3.1415, e = 2.71, f;
-
- c = a / b;
- r = a % b;
-
- f = pi * e;
-
- return( 0 );
-}
Index: products/ARM32-newlib/1.11.3/A2X-TEST/build.sh
===================================================================
--- products/ARM32-newlib/1.11.3/A2X-TEST/build.sh (revision 75)
+++ products/ARM32-newlib/1.11.3/A2X-TEST/build.sh (nonexistent)
@@ -1,19 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-ARCH_OPTIONS=" -march=armv7ve -mtune=cortex-a7 -mfpu=neon-vfpv4 -mfloat-abi=hard"
-
-$TARGET-gcc -g -gdwarf-2 -fomit-frame-pointer ${ARCH_OPTIONS} -mlittle-endian -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-$TARGET-gcc ${ARCH_OPTIONS} -mlittle-endian -o main main.o
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/ARM32-newlib/1.11.3/A2X-TEST/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/ARM32-newlib/1.11.3/A2X-TEST/.config
===================================================================
--- products/ARM32-newlib/1.11.3/A2X-TEST/.config (revision 75)
+++ products/ARM32-newlib/1.11.3/A2X-TEST/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=arm-none-eabi
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/arm-NONE-eabi-newlib/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/ARM32-newlib/1.11.3/A2X-TEST/clean.sh
===================================================================
--- products/ARM32-newlib/1.11.3/A2X-TEST/clean.sh (revision 75)
+++ products/ARM32-newlib/1.11.3/A2X-TEST/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/ARM32-newlib/1.11.3/A2X-TEST/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/ARM32-newlib/1.11.3/A2X-TEST
===================================================================
--- products/ARM32-newlib/1.11.3/A2X-TEST (revision 75)
+++ products/ARM32-newlib/1.11.3/A2X-TEST (nonexistent)
Property changes on: products/ARM32-newlib/1.11.3/A2X-TEST
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/ARM32-newlib/1.11.3/H3-TEST/main.c
===================================================================
--- products/ARM32-newlib/1.11.3/H3-TEST/main.c (revision 75)
+++ products/ARM32-newlib/1.11.3/H3-TEST/main.c (nonexistent)
@@ -1,16 +0,0 @@
-
-#include <stdlib.h>
-#include <inttypes.h>
-
-int main()
-{
- uint32_t a = 7, b = 3, c, r;
- float pi = 3.1415, e = 2.71, f;
-
- c = a / b;
- r = a % b;
-
- f = pi * e;
-
- return( 0 );
-}
Index: products/ARM32-newlib/1.11.3/H3-TEST/build.sh
===================================================================
--- products/ARM32-newlib/1.11.3/H3-TEST/build.sh (revision 75)
+++ products/ARM32-newlib/1.11.3/H3-TEST/build.sh (nonexistent)
@@ -1,19 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-ARCH_OPTIONS=" -march=armv7ve -mtune=cortex-a7 -mfpu=neon-vfpv4 -mfloat-abi=hard"
-
-$TARGET-gcc -g -gdwarf-2 -fomit-frame-pointer ${ARCH_OPTIONS} -mlittle-endian -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-$TARGET-gcc ${ARCH_OPTIONS} -mlittle-endian -o main main.o
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/ARM32-newlib/1.11.3/H3-TEST/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/ARM32-newlib/1.11.3/H3-TEST/.config
===================================================================
--- products/ARM32-newlib/1.11.3/H3-TEST/.config (revision 75)
+++ products/ARM32-newlib/1.11.3/H3-TEST/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=arm-none-eabi
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/arm-NONE-eabi-newlib/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/ARM32-newlib/1.11.3/H3-TEST/clean.sh
===================================================================
--- products/ARM32-newlib/1.11.3/H3-TEST/clean.sh (revision 75)
+++ products/ARM32-newlib/1.11.3/H3-TEST/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/ARM32-newlib/1.11.3/H3-TEST/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/ARM32-newlib/1.11.3/H3-TEST
===================================================================
--- products/ARM32-newlib/1.11.3/H3-TEST (revision 75)
+++ products/ARM32-newlib/1.11.3/H3-TEST (nonexistent)
Property changes on: products/ARM32-newlib/1.11.3/H3-TEST
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/ARM32-newlib/1.11.3/Makefile
===================================================================
--- products/ARM32-newlib/1.11.3/Makefile (revision 75)
+++ products/ARM32-newlib/1.11.3/Makefile (nonexistent)
@@ -1,34 +0,0 @@
-
-
-COMPONENT_TARGETS = $(TOOLCHAIN_ARM32_NEWLIB)
-
-export TOOLCHAIN_VERSION = 1.11.3
-
-include ../../../build-system/config.mk
-
-REQUIRES = core/gcc/14.2.0^full
-REQUIRES += core/gdb/15.1
-
-# ======= __END_OF_REQUIRES__ =======
-
-tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
-tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
-
-tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
-
-BUILD_TARGETS = $(tarball_target)
-
-PRODUCT_TARGETS = $(tarball)
-
-include ../../../build-system/core.mk
-
-
-$(tarball): $(tarball_target)
-
-$(tarball_target): $(build_requires)
- @echo ""
- @echo "Creating $(tarball_name) tarball..."
- @cd $(TOOLCHAINS_BASE_PATH) ; \
- tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
- @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
- @touch $@
Index: products/ARM32-newlib/1.11.3
===================================================================
--- products/ARM32-newlib/1.11.3 (revision 75)
+++ products/ARM32-newlib/1.11.3 (nonexistent)
Property changes on: products/ARM32-newlib/1.11.3
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/ARM32-newlib/1.11.4/A1X-TEST/.config
===================================================================
--- products/ARM32-newlib/1.11.4/A1X-TEST/.config (nonexistent)
+++ products/ARM32-newlib/1.11.4/A1X-TEST/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=arm-none-eabi
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/arm-NONE-eabi-newlib/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/ARM32-newlib/1.11.4/A1X-TEST/build.sh
===================================================================
--- products/ARM32-newlib/1.11.4/A1X-TEST/build.sh (nonexistent)
+++ products/ARM32-newlib/1.11.4/A1X-TEST/build.sh (revision 76)
@@ -0,0 +1,19 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+ARCH_OPTIONS=" -march=armv7-a -mtune=cortex-a8 -mfpu=neon -mfloat-abi=hard"
+
+$TARGET-gcc -g -gdwarf-2 -fomit-frame-pointer ${ARCH_OPTIONS} -mlittle-endian -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+$TARGET-gcc ${ARCH_OPTIONS} -mlittle-endian -o main main.o
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/ARM32-newlib/1.11.4/A1X-TEST/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/ARM32-newlib/1.11.4/A1X-TEST/clean.sh
===================================================================
--- products/ARM32-newlib/1.11.4/A1X-TEST/clean.sh (nonexistent)
+++ products/ARM32-newlib/1.11.4/A1X-TEST/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/ARM32-newlib/1.11.4/A1X-TEST/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/ARM32-newlib/1.11.4/A1X-TEST/main.c
===================================================================
--- products/ARM32-newlib/1.11.4/A1X-TEST/main.c (nonexistent)
+++ products/ARM32-newlib/1.11.4/A1X-TEST/main.c (revision 76)
@@ -0,0 +1,16 @@
+
+#include <stdlib.h>
+#include <inttypes.h>
+
+int main()
+{
+ uint32_t a = 7, b = 3, c, r;
+ float pi = 3.1415, e = 2.71, f;
+
+ c = a / b;
+ r = a % b;
+
+ f = pi * e;
+
+ return( 0 );
+}
Index: products/ARM32-newlib/1.11.4/A1X-TEST
===================================================================
--- products/ARM32-newlib/1.11.4/A1X-TEST (nonexistent)
+++ products/ARM32-newlib/1.11.4/A1X-TEST (revision 76)
Property changes on: products/ARM32-newlib/1.11.4/A1X-TEST
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/ARM32-newlib/1.11.4/A2X-TEST/.config
===================================================================
--- products/ARM32-newlib/1.11.4/A2X-TEST/.config (nonexistent)
+++ products/ARM32-newlib/1.11.4/A2X-TEST/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=arm-none-eabi
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/arm-NONE-eabi-newlib/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/ARM32-newlib/1.11.4/A2X-TEST/build.sh
===================================================================
--- products/ARM32-newlib/1.11.4/A2X-TEST/build.sh (nonexistent)
+++ products/ARM32-newlib/1.11.4/A2X-TEST/build.sh (revision 76)
@@ -0,0 +1,19 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+ARCH_OPTIONS=" -march=armv7ve -mtune=cortex-a7 -mfpu=neon-vfpv4 -mfloat-abi=hard"
+
+$TARGET-gcc -g -gdwarf-2 -fomit-frame-pointer ${ARCH_OPTIONS} -mlittle-endian -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+$TARGET-gcc ${ARCH_OPTIONS} -mlittle-endian -o main main.o
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/ARM32-newlib/1.11.4/A2X-TEST/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/ARM32-newlib/1.11.4/A2X-TEST/clean.sh
===================================================================
--- products/ARM32-newlib/1.11.4/A2X-TEST/clean.sh (nonexistent)
+++ products/ARM32-newlib/1.11.4/A2X-TEST/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/ARM32-newlib/1.11.4/A2X-TEST/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/ARM32-newlib/1.11.4/A2X-TEST/main.c
===================================================================
--- products/ARM32-newlib/1.11.4/A2X-TEST/main.c (nonexistent)
+++ products/ARM32-newlib/1.11.4/A2X-TEST/main.c (revision 76)
@@ -0,0 +1,16 @@
+
+#include <stdlib.h>
+#include <inttypes.h>
+
+int main()
+{
+ uint32_t a = 7, b = 3, c, r;
+ float pi = 3.1415, e = 2.71, f;
+
+ c = a / b;
+ r = a % b;
+
+ f = pi * e;
+
+ return( 0 );
+}
Index: products/ARM32-newlib/1.11.4/A2X-TEST
===================================================================
--- products/ARM32-newlib/1.11.4/A2X-TEST (nonexistent)
+++ products/ARM32-newlib/1.11.4/A2X-TEST (revision 76)
Property changes on: products/ARM32-newlib/1.11.4/A2X-TEST
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/ARM32-newlib/1.11.4/H3-TEST/.config
===================================================================
--- products/ARM32-newlib/1.11.4/H3-TEST/.config (nonexistent)
+++ products/ARM32-newlib/1.11.4/H3-TEST/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=arm-none-eabi
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/arm-NONE-eabi-newlib/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/ARM32-newlib/1.11.4/H3-TEST/build.sh
===================================================================
--- products/ARM32-newlib/1.11.4/H3-TEST/build.sh (nonexistent)
+++ products/ARM32-newlib/1.11.4/H3-TEST/build.sh (revision 76)
@@ -0,0 +1,19 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+ARCH_OPTIONS=" -march=armv7ve -mtune=cortex-a7 -mfpu=neon-vfpv4 -mfloat-abi=hard"
+
+$TARGET-gcc -g -gdwarf-2 -fomit-frame-pointer ${ARCH_OPTIONS} -mlittle-endian -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+$TARGET-gcc ${ARCH_OPTIONS} -mlittle-endian -o main main.o
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/ARM32-newlib/1.11.4/H3-TEST/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/ARM32-newlib/1.11.4/H3-TEST/clean.sh
===================================================================
--- products/ARM32-newlib/1.11.4/H3-TEST/clean.sh (nonexistent)
+++ products/ARM32-newlib/1.11.4/H3-TEST/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/ARM32-newlib/1.11.4/H3-TEST/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/ARM32-newlib/1.11.4/H3-TEST/main.c
===================================================================
--- products/ARM32-newlib/1.11.4/H3-TEST/main.c (nonexistent)
+++ products/ARM32-newlib/1.11.4/H3-TEST/main.c (revision 76)
@@ -0,0 +1,16 @@
+
+#include <stdlib.h>
+#include <inttypes.h>
+
+int main()
+{
+ uint32_t a = 7, b = 3, c, r;
+ float pi = 3.1415, e = 2.71, f;
+
+ c = a / b;
+ r = a % b;
+
+ f = pi * e;
+
+ return( 0 );
+}
Index: products/ARM32-newlib/1.11.4/H3-TEST
===================================================================
--- products/ARM32-newlib/1.11.4/H3-TEST (nonexistent)
+++ products/ARM32-newlib/1.11.4/H3-TEST (revision 76)
Property changes on: products/ARM32-newlib/1.11.4/H3-TEST
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/ARM32-newlib/1.11.4/IMX6-TEST/.config
===================================================================
--- products/ARM32-newlib/1.11.4/IMX6-TEST/.config (nonexistent)
+++ products/ARM32-newlib/1.11.4/IMX6-TEST/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=arm-none-eabi
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/arm-NONE-eabi-newlib/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/ARM32-newlib/1.11.4/IMX6-TEST/build.sh
===================================================================
--- products/ARM32-newlib/1.11.4/IMX6-TEST/build.sh (nonexistent)
+++ products/ARM32-newlib/1.11.4/IMX6-TEST/build.sh (revision 76)
@@ -0,0 +1,19 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+ARCH_OPTIONS=" -march=armv7-a -mtune=cortex-a9 -mfpu=vfpv3 -mfloat-abi=hard"
+
+$TARGET-gcc -g -gdwarf-2 -fomit-frame-pointer ${ARCH_OPTIONS} -mlittle-endian -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+$TARGET-gcc ${ARCH_OPTIONS} -mlittle-endian -o main main.o
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/ARM32-newlib/1.11.4/IMX6-TEST/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/ARM32-newlib/1.11.4/IMX6-TEST/clean.sh
===================================================================
--- products/ARM32-newlib/1.11.4/IMX6-TEST/clean.sh (nonexistent)
+++ products/ARM32-newlib/1.11.4/IMX6-TEST/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/ARM32-newlib/1.11.4/IMX6-TEST/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/ARM32-newlib/1.11.4/IMX6-TEST/main.c
===================================================================
--- products/ARM32-newlib/1.11.4/IMX6-TEST/main.c (nonexistent)
+++ products/ARM32-newlib/1.11.4/IMX6-TEST/main.c (revision 76)
@@ -0,0 +1,16 @@
+
+#include <stdlib.h>
+#include <inttypes.h>
+
+int main()
+{
+ uint32_t a = 7, b = 3, c, r;
+ float pi = 3.1415, e = 2.71, f;
+
+ c = a / b;
+ r = a % b;
+
+ f = pi * e;
+
+ return( 0 );
+}
Index: products/ARM32-newlib/1.11.4/IMX6-TEST
===================================================================
--- products/ARM32-newlib/1.11.4/IMX6-TEST (nonexistent)
+++ products/ARM32-newlib/1.11.4/IMX6-TEST (revision 76)
Property changes on: products/ARM32-newlib/1.11.4/IMX6-TEST
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/ARM32-newlib/1.11.4/Makefile
===================================================================
--- products/ARM32-newlib/1.11.4/Makefile (nonexistent)
+++ products/ARM32-newlib/1.11.4/Makefile (revision 76)
@@ -0,0 +1,34 @@
+
+
+COMPONENT_TARGETS = $(TOOLCHAIN_ARM32_NEWLIB)
+
+export TOOLCHAIN_VERSION = 1.11.4
+
+include ../../../build-system/config.mk
+
+REQUIRES = core/gcc/14.2.0^full
+REQUIRES += core/gdb/16.2
+
+# ======= __END_OF_REQUIRES__ =======
+
+tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
+tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
+
+tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
+
+BUILD_TARGETS = $(tarball_target)
+
+PRODUCT_TARGETS = $(tarball)
+
+include ../../../build-system/core.mk
+
+
+$(tarball): $(tarball_target)
+
+$(tarball_target): $(build_requires)
+ @echo ""
+ @echo "Creating $(tarball_name) tarball..."
+ @cd $(TOOLCHAINS_BASE_PATH) ; \
+ tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
+ @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
+ @touch $@
Index: products/ARM32-newlib/1.11.4/OMAP543X-TEST/.config
===================================================================
--- products/ARM32-newlib/1.11.4/OMAP543X-TEST/.config (nonexistent)
+++ products/ARM32-newlib/1.11.4/OMAP543X-TEST/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=arm-none-eabi
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/arm-NONE-eabi-newlib/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/ARM32-newlib/1.11.4/OMAP543X-TEST/build.sh
===================================================================
--- products/ARM32-newlib/1.11.4/OMAP543X-TEST/build.sh (nonexistent)
+++ products/ARM32-newlib/1.11.4/OMAP543X-TEST/build.sh (revision 76)
@@ -0,0 +1,19 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+ARCH_OPTIONS=" -march=armv7ve -mtune=cortex-a15 -mfpu=neon-vfpv4 -mfloat-abi=hard"
+
+$TARGET-gcc -g -gdwarf-2 -fomit-frame-pointer ${ARCH_OPTIONS} -mlittle-endian -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+$TARGET-gcc ${ARCH_OPTIONS} -mlittle-endian -o main main.o
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/ARM32-newlib/1.11.4/OMAP543X-TEST/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/ARM32-newlib/1.11.4/OMAP543X-TEST/clean.sh
===================================================================
--- products/ARM32-newlib/1.11.4/OMAP543X-TEST/clean.sh (nonexistent)
+++ products/ARM32-newlib/1.11.4/OMAP543X-TEST/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/ARM32-newlib/1.11.4/OMAP543X-TEST/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/ARM32-newlib/1.11.4/OMAP543X-TEST/main.c
===================================================================
--- products/ARM32-newlib/1.11.4/OMAP543X-TEST/main.c (nonexistent)
+++ products/ARM32-newlib/1.11.4/OMAP543X-TEST/main.c (revision 76)
@@ -0,0 +1,16 @@
+
+#include <stdlib.h>
+#include <inttypes.h>
+
+int main()
+{
+ uint32_t a = 7, b = 3, c, r;
+ float pi = 3.1415, e = 2.71, f;
+
+ c = a / b;
+ r = a % b;
+
+ f = pi * e;
+
+ return( 0 );
+}
Index: products/ARM32-newlib/1.11.4/OMAP543X-TEST
===================================================================
--- products/ARM32-newlib/1.11.4/OMAP543X-TEST (nonexistent)
+++ products/ARM32-newlib/1.11.4/OMAP543X-TEST (revision 76)
Property changes on: products/ARM32-newlib/1.11.4/OMAP543X-TEST
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/ARM32-newlib/1.11.4/RK328X-TEST/.config
===================================================================
--- products/ARM32-newlib/1.11.4/RK328X-TEST/.config (nonexistent)
+++ products/ARM32-newlib/1.11.4/RK328X-TEST/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=arm-none-eabi
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/arm-NONE-eabi-newlib/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/ARM32-newlib/1.11.4/RK328X-TEST/build.sh
===================================================================
--- products/ARM32-newlib/1.11.4/RK328X-TEST/build.sh (nonexistent)
+++ products/ARM32-newlib/1.11.4/RK328X-TEST/build.sh (revision 76)
@@ -0,0 +1,19 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+ARCH_OPTIONS=" -march=armv7ve -mtune=cortex-a17 -mfpu=neon-vfpv4 -mfloat-abi=hard"
+
+$TARGET-gcc -g -gdwarf-2 -fomit-frame-pointer ${ARCH_OPTIONS} -mlittle-endian -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+$TARGET-gcc ${ARCH_OPTIONS} -mlittle-endian -o main main.o
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/ARM32-newlib/1.11.4/RK328X-TEST/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/ARM32-newlib/1.11.4/RK328X-TEST/clean.sh
===================================================================
--- products/ARM32-newlib/1.11.4/RK328X-TEST/clean.sh (nonexistent)
+++ products/ARM32-newlib/1.11.4/RK328X-TEST/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/ARM32-newlib/1.11.4/RK328X-TEST/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/ARM32-newlib/1.11.4/RK328X-TEST/main.c
===================================================================
--- products/ARM32-newlib/1.11.4/RK328X-TEST/main.c (nonexistent)
+++ products/ARM32-newlib/1.11.4/RK328X-TEST/main.c (revision 76)
@@ -0,0 +1,16 @@
+
+#include <stdlib.h>
+#include <inttypes.h>
+
+int main()
+{
+ uint32_t a = 7, b = 3, c, r;
+ float pi = 3.1415, e = 2.71, f;
+
+ c = a / b;
+ r = a % b;
+
+ f = pi * e;
+
+ return( 0 );
+}
Index: products/ARM32-newlib/1.11.4/RK328X-TEST
===================================================================
--- products/ARM32-newlib/1.11.4/RK328X-TEST (nonexistent)
+++ products/ARM32-newlib/1.11.4/RK328X-TEST (revision 76)
Property changes on: products/ARM32-newlib/1.11.4/RK328X-TEST
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/ARM32-newlib/1.11.4/S8XX-TEST/.config
===================================================================
--- products/ARM32-newlib/1.11.4/S8XX-TEST/.config (nonexistent)
+++ products/ARM32-newlib/1.11.4/S8XX-TEST/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=arm-none-eabi
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/arm-NONE-eabi-newlib/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/ARM32-newlib/1.11.4/S8XX-TEST/build.sh
===================================================================
--- products/ARM32-newlib/1.11.4/S8XX-TEST/build.sh (nonexistent)
+++ products/ARM32-newlib/1.11.4/S8XX-TEST/build.sh (revision 76)
@@ -0,0 +1,19 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+ARCH_OPTIONS=" -march=armv7-a -mtune=cortex-a5 -mfpu=neon -mfloat-abi=hard"
+
+$TARGET-gcc -g -gdwarf-2 -fomit-frame-pointer ${ARCH_OPTIONS} -mlittle-endian -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+$TARGET-gcc ${ARCH_OPTIONS} -mlittle-endian -o main main.o
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/ARM32-newlib/1.11.4/S8XX-TEST/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/ARM32-newlib/1.11.4/S8XX-TEST/clean.sh
===================================================================
--- products/ARM32-newlib/1.11.4/S8XX-TEST/clean.sh (nonexistent)
+++ products/ARM32-newlib/1.11.4/S8XX-TEST/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/ARM32-newlib/1.11.4/S8XX-TEST/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/ARM32-newlib/1.11.4/S8XX-TEST/main.c
===================================================================
--- products/ARM32-newlib/1.11.4/S8XX-TEST/main.c (nonexistent)
+++ products/ARM32-newlib/1.11.4/S8XX-TEST/main.c (revision 76)
@@ -0,0 +1,16 @@
+
+#include <stdlib.h>
+#include <inttypes.h>
+
+int main()
+{
+ uint32_t a = 7, b = 3, c, r;
+ float pi = 3.1415, e = 2.71, f;
+
+ c = a / b;
+ r = a % b;
+
+ f = pi * e;
+
+ return( 0 );
+}
Index: products/ARM32-newlib/1.11.4/S8XX-TEST
===================================================================
--- products/ARM32-newlib/1.11.4/S8XX-TEST (nonexistent)
+++ products/ARM32-newlib/1.11.4/S8XX-TEST (revision 76)
Property changes on: products/ARM32-newlib/1.11.4/S8XX-TEST
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/ARM32-newlib/1.11.4/armv8l-TEST/.config
===================================================================
--- products/ARM32-newlib/1.11.4/armv8l-TEST/.config (nonexistent)
+++ products/ARM32-newlib/1.11.4/armv8l-TEST/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=arm-none-eabi
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/arm-NONE-eabi-newlib/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/ARM32-newlib/1.11.4/armv8l-TEST/build.sh
===================================================================
--- products/ARM32-newlib/1.11.4/armv8l-TEST/build.sh (nonexistent)
+++ products/ARM32-newlib/1.11.4/armv8l-TEST/build.sh (revision 76)
@@ -0,0 +1,19 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+ARCH_OPTIONS=" -march=armv8-a -mcpu=cortex-a53 -mfpu=neon-fp-armv8 -mfloat-abi=hard"
+
+$TARGET-gcc -g -gdwarf-2 -fomit-frame-pointer ${ARCH_OPTIONS} -mlittle-endian -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+$TARGET-gcc ${ARCH_OPTIONS} -mlittle-endian -o main main.o
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/ARM32-newlib/1.11.4/armv8l-TEST/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/ARM32-newlib/1.11.4/armv8l-TEST/clean.sh
===================================================================
--- products/ARM32-newlib/1.11.4/armv8l-TEST/clean.sh (nonexistent)
+++ products/ARM32-newlib/1.11.4/armv8l-TEST/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/ARM32-newlib/1.11.4/armv8l-TEST/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/ARM32-newlib/1.11.4/armv8l-TEST/main.c
===================================================================
--- products/ARM32-newlib/1.11.4/armv8l-TEST/main.c (nonexistent)
+++ products/ARM32-newlib/1.11.4/armv8l-TEST/main.c (revision 76)
@@ -0,0 +1,16 @@
+
+#include <stdlib.h>
+#include <inttypes.h>
+
+int main()
+{
+ uint32_t a = 7, b = 3, c, r;
+ float pi = 3.1415, e = 2.71, f;
+
+ c = a / b;
+ r = a % b;
+
+ f = pi * e;
+
+ return( 0 );
+}
Index: products/ARM32-newlib/1.11.4/armv8l-TEST
===================================================================
--- products/ARM32-newlib/1.11.4/armv8l-TEST (nonexistent)
+++ products/ARM32-newlib/1.11.4/armv8l-TEST (revision 76)
Property changes on: products/ARM32-newlib/1.11.4/armv8l-TEST
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/ARM32-newlib/1.11.4
===================================================================
--- products/ARM32-newlib/1.11.4 (nonexistent)
+++ products/ARM32-newlib/1.11.4 (revision 76)
Property changes on: products/ARM32-newlib/1.11.4
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/AT91SAM7S-newlib/1.11.3/AT91SAM7S-TEST/main.c
===================================================================
--- products/AT91SAM7S-newlib/1.11.3/AT91SAM7S-TEST/main.c (revision 75)
+++ products/AT91SAM7S-newlib/1.11.3/AT91SAM7S-TEST/main.c (nonexistent)
@@ -1,13 +0,0 @@
-
-#include <stdlib.h>
-#include <inttypes.h>
-
-int main()
-{
- uint32_t a = 7, b = 3, c, r;
-
- c = a / b;
- r = a % b;
-
- return( 0 );
-}
Index: products/AT91SAM7S-newlib/1.11.3/AT91SAM7S-TEST/_build.sh
===================================================================
--- products/AT91SAM7S-newlib/1.11.3/AT91SAM7S-TEST/_build.sh (revision 75)
+++ products/AT91SAM7S-newlib/1.11.3/AT91SAM7S-TEST/_build.sh (nonexistent)
@@ -1,17 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-arm-at91sam7s-eabi-gcc -g -gdwarf-2 -fomit-frame-pointer -mcpu=arm7tdmi -mbig-endian -I$TOOLCHAIN_PATH/include -c -o main.o main.c
-arm-at91sam7s-eabi-gcc -mcpu=arm7tdmi -mbig-endian -o main main.o
-
-arm-at91sam7s-eabi-objdump -x main > main.map
-
-arm-at91sam7s-eabi-strip main -o main.elf
-
-arm-at91sam7s-eabi-objcopy -O srec main.elf main.srec
-arm-at91sam7s-eabi-objcopy -O ihex main.elf main.hex
-arm-at91sam7s-eabi-objdump -S -d main.o > main.asm
-arm-at91sam7s-eabi-objdump -S -d main > full.program.asm
Property changes on: products/AT91SAM7S-newlib/1.11.3/AT91SAM7S-TEST/_build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/AT91SAM7S-newlib/1.11.3/AT91SAM7S-TEST/_clean.sh
===================================================================
--- products/AT91SAM7S-newlib/1.11.3/AT91SAM7S-TEST/_clean.sh (revision 75)
+++ products/AT91SAM7S-newlib/1.11.3/AT91SAM7S-TEST/_clean.sh (nonexistent)
@@ -1,3 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm main main.asm main.elf main.hex main.map main.o main.srec
Property changes on: products/AT91SAM7S-newlib/1.11.3/AT91SAM7S-TEST/_clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/AT91SAM7S-newlib/1.11.3/AT91SAM7S-TEST/.config
===================================================================
--- products/AT91SAM7S-newlib/1.11.3/AT91SAM7S-TEST/.config (revision 75)
+++ products/AT91SAM7S-newlib/1.11.3/AT91SAM7S-TEST/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=arm-at91sam7s-eabi
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/arm-AT91SAM7S-eabi-newlib/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/AT91SAM7S-newlib/1.11.3/AT91SAM7S-TEST
===================================================================
--- products/AT91SAM7S-newlib/1.11.3/AT91SAM7S-TEST (revision 75)
+++ products/AT91SAM7S-newlib/1.11.3/AT91SAM7S-TEST (nonexistent)
Property changes on: products/AT91SAM7S-newlib/1.11.3/AT91SAM7S-TEST
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/AT91SAM7S-newlib/1.11.3/Makefile
===================================================================
--- products/AT91SAM7S-newlib/1.11.3/Makefile (revision 75)
+++ products/AT91SAM7S-newlib/1.11.3/Makefile (nonexistent)
@@ -1,33 +0,0 @@
-
-
-COMPONENT_TARGETS = $(TOOLCHAIN_AT91SAM7S_NEWLIB)
-
-export TOOLCHAIN_VERSION = 1.11.3
-
-include ../../../build-system/config.mk
-
-REQUIRES = core/gcc/14.2.0^full
-
-# ======= __END_OF_REQUIRES__ =======
-
-tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
-tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
-
-tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
-
-BUILD_TARGETS = $(tarball_target)
-
-PRODUCT_TARGETS = $(tarball)
-
-include ../../../build-system/core.mk
-
-
-$(tarball): $(tarball_target)
-
-$(tarball_target):
- @echo ""
- @echo "Creating $(tarball_name) tarball..."
- @cd $(TOOLCHAINS_BASE_PATH) ; \
- tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
- @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
- @touch $@
Index: products/AT91SAM7S-newlib/1.11.3
===================================================================
--- products/AT91SAM7S-newlib/1.11.3 (revision 75)
+++ products/AT91SAM7S-newlib/1.11.3 (nonexistent)
Property changes on: products/AT91SAM7S-newlib/1.11.3
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/AT91SAM7S-newlib/1.11.4/AT91SAM7S-TEST/.config
===================================================================
--- products/AT91SAM7S-newlib/1.11.4/AT91SAM7S-TEST/.config (nonexistent)
+++ products/AT91SAM7S-newlib/1.11.4/AT91SAM7S-TEST/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=arm-at91sam7s-eabi
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/arm-AT91SAM7S-eabi-newlib/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/AT91SAM7S-newlib/1.11.4/AT91SAM7S-TEST/_build.sh
===================================================================
--- products/AT91SAM7S-newlib/1.11.4/AT91SAM7S-TEST/_build.sh (nonexistent)
+++ products/AT91SAM7S-newlib/1.11.4/AT91SAM7S-TEST/_build.sh (revision 76)
@@ -0,0 +1,17 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+arm-at91sam7s-eabi-gcc -g -gdwarf-2 -fomit-frame-pointer -mcpu=arm7tdmi -mbig-endian -I$TOOLCHAIN_PATH/include -c -o main.o main.c
+arm-at91sam7s-eabi-gcc -mcpu=arm7tdmi -mbig-endian -o main main.o
+
+arm-at91sam7s-eabi-objdump -x main > main.map
+
+arm-at91sam7s-eabi-strip main -o main.elf
+
+arm-at91sam7s-eabi-objcopy -O srec main.elf main.srec
+arm-at91sam7s-eabi-objcopy -O ihex main.elf main.hex
+arm-at91sam7s-eabi-objdump -S -d main.o > main.asm
+arm-at91sam7s-eabi-objdump -S -d main > full.program.asm
Property changes on: products/AT91SAM7S-newlib/1.11.4/AT91SAM7S-TEST/_build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/AT91SAM7S-newlib/1.11.4/AT91SAM7S-TEST/_clean.sh
===================================================================
--- products/AT91SAM7S-newlib/1.11.4/AT91SAM7S-TEST/_clean.sh (nonexistent)
+++ products/AT91SAM7S-newlib/1.11.4/AT91SAM7S-TEST/_clean.sh (revision 76)
@@ -0,0 +1,3 @@
+#!/bin/bash
+
+rm -f full.program.asm main main.asm main.elf main.hex main.map main.o main.srec
Property changes on: products/AT91SAM7S-newlib/1.11.4/AT91SAM7S-TEST/_clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/AT91SAM7S-newlib/1.11.4/AT91SAM7S-TEST/main.c
===================================================================
--- products/AT91SAM7S-newlib/1.11.4/AT91SAM7S-TEST/main.c (nonexistent)
+++ products/AT91SAM7S-newlib/1.11.4/AT91SAM7S-TEST/main.c (revision 76)
@@ -0,0 +1,13 @@
+
+#include <stdlib.h>
+#include <inttypes.h>
+
+int main()
+{
+ uint32_t a = 7, b = 3, c, r;
+
+ c = a / b;
+ r = a % b;
+
+ return( 0 );
+}
Index: products/AT91SAM7S-newlib/1.11.4/AT91SAM7S-TEST
===================================================================
--- products/AT91SAM7S-newlib/1.11.4/AT91SAM7S-TEST (nonexistent)
+++ products/AT91SAM7S-newlib/1.11.4/AT91SAM7S-TEST (revision 76)
Property changes on: products/AT91SAM7S-newlib/1.11.4/AT91SAM7S-TEST
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/AT91SAM7S-newlib/1.11.4/Makefile
===================================================================
--- products/AT91SAM7S-newlib/1.11.4/Makefile (nonexistent)
+++ products/AT91SAM7S-newlib/1.11.4/Makefile (revision 76)
@@ -0,0 +1,33 @@
+
+
+COMPONENT_TARGETS = $(TOOLCHAIN_AT91SAM7S_NEWLIB)
+
+export TOOLCHAIN_VERSION = 1.11.4
+
+include ../../../build-system/config.mk
+
+REQUIRES = core/gcc/14.2.0^full
+
+# ======= __END_OF_REQUIRES__ =======
+
+tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
+tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
+
+tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
+
+BUILD_TARGETS = $(tarball_target)
+
+PRODUCT_TARGETS = $(tarball)
+
+include ../../../build-system/core.mk
+
+
+$(tarball): $(tarball_target)
+
+$(tarball_target):
+ @echo ""
+ @echo "Creating $(tarball_name) tarball..."
+ @cd $(TOOLCHAINS_BASE_PATH) ; \
+ tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
+ @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
+ @touch $@
Index: products/AT91SAM7S-newlib/1.11.4
===================================================================
--- products/AT91SAM7S-newlib/1.11.4 (nonexistent)
+++ products/AT91SAM7S-newlib/1.11.4 (revision 76)
Property changes on: products/AT91SAM7S-newlib/1.11.4
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/H3-glibc/1.11.3/H3-TEST-neon/main.c
===================================================================
--- products/H3-glibc/1.11.3/H3-TEST-neon/main.c (revision 75)
+++ products/H3-glibc/1.11.3/H3-TEST-neon/main.c (nonexistent)
@@ -1,17 +0,0 @@
-
-//#include <stdlib.h>
-//#include <inttypes.h>
-
-int main()
-{
- float d, f = 3.1415;
-
-// uint32_t a = 7, b = 3, c, r;
-
-// c = a / b;
-// r = a % b;
-
- d = f * 2.1;
-
- return( 0 );
-}
Index: products/H3-glibc/1.11.3/H3-TEST-neon/build.sh
===================================================================
--- products/H3-glibc/1.11.3/H3-TEST-neon/build.sh (revision 75)
+++ products/H3-glibc/1.11.3/H3-TEST-neon/build.sh (nonexistent)
@@ -1,21 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-ARCH_FLAGS=" -march=armv7ve -mtune=cortex-a7"
-
-FPU_FLAGS=" -mfloat-abi=hard -mfpu=neon-vfpv4 -ftree-vectorize -fomit-frame-pointer -ffast-math"
-
-$TARGET-gcc -g -O3 -gdwarf-2 -fomit-frame-pointer $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/H3-glibc/1.11.3/H3-TEST-neon/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/H3-glibc/1.11.3/H3-TEST-neon/.config
===================================================================
--- products/H3-glibc/1.11.3/H3-TEST-neon/.config (revision 75)
+++ products/H3-glibc/1.11.3/H3-TEST-neon/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=arm-h3-linux-gnueabihf
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/arm-H3-linux-glibc/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/H3-glibc/1.11.3/H3-TEST-neon/clean.sh
===================================================================
--- products/H3-glibc/1.11.3/H3-TEST-neon/clean.sh (revision 75)
+++ products/H3-glibc/1.11.3/H3-TEST-neon/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/H3-glibc/1.11.3/H3-TEST-neon/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/H3-glibc/1.11.3/H3-TEST-neon
===================================================================
--- products/H3-glibc/1.11.3/H3-TEST-neon (revision 75)
+++ products/H3-glibc/1.11.3/H3-TEST-neon (nonexistent)
Property changes on: products/H3-glibc/1.11.3/H3-TEST-neon
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/H3-glibc/1.11.3/Makefile
===================================================================
--- products/H3-glibc/1.11.3/Makefile (revision 75)
+++ products/H3-glibc/1.11.3/Makefile (nonexistent)
@@ -1,35 +0,0 @@
-
-
-COMPONENT_TARGETS = $(TOOLCHAIN_H3_GLIBC)
-
-export TOOLCHAIN_VERSION = 1.11.3
-
-include ../../../build-system/config.mk
-
-REQUIRES = core/gcc/14.2.0^full
-REQUIRES += tools/patchelf/0.18.0
-REQUIRES += core/gdb/15.1
-
-# ======= __END_OF_REQUIRES__ =======
-
-tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
-tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
-
-tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
-
-BUILD_TARGETS = $(tarball_target)
-
-PRODUCT_TARGETS = $(tarball)
-
-include ../../../build-system/core.mk
-
-
-$(tarball): $(tarball_target)
-
-$(tarball_target):
- @echo ""
- @echo "Creating $(tarball_name) tarball..."
- @cd $(TOOLCHAINS_BASE_PATH) ; \
- tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
- @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
- @touch $@
Index: products/H3-glibc/1.11.3
===================================================================
--- products/H3-glibc/1.11.3 (revision 75)
+++ products/H3-glibc/1.11.3 (nonexistent)
Property changes on: products/H3-glibc/1.11.3
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/H3-glibc/1.11.4/H3-TEST-neon/.config
===================================================================
--- products/H3-glibc/1.11.4/H3-TEST-neon/.config (nonexistent)
+++ products/H3-glibc/1.11.4/H3-TEST-neon/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=arm-h3-linux-gnueabihf
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/arm-H3-linux-glibc/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/H3-glibc/1.11.4/H3-TEST-neon/build.sh
===================================================================
--- products/H3-glibc/1.11.4/H3-TEST-neon/build.sh (nonexistent)
+++ products/H3-glibc/1.11.4/H3-TEST-neon/build.sh (revision 76)
@@ -0,0 +1,21 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+ARCH_FLAGS=" -march=armv7ve -mtune=cortex-a7"
+
+FPU_FLAGS=" -mfloat-abi=hard -mfpu=neon-vfpv4 -ftree-vectorize -fomit-frame-pointer -ffast-math"
+
+$TARGET-gcc -g -O3 -gdwarf-2 -fomit-frame-pointer $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/H3-glibc/1.11.4/H3-TEST-neon/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/H3-glibc/1.11.4/H3-TEST-neon/clean.sh
===================================================================
--- products/H3-glibc/1.11.4/H3-TEST-neon/clean.sh (nonexistent)
+++ products/H3-glibc/1.11.4/H3-TEST-neon/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/H3-glibc/1.11.4/H3-TEST-neon/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/H3-glibc/1.11.4/H3-TEST-neon/main.c
===================================================================
--- products/H3-glibc/1.11.4/H3-TEST-neon/main.c (nonexistent)
+++ products/H3-glibc/1.11.4/H3-TEST-neon/main.c (revision 76)
@@ -0,0 +1,17 @@
+
+//#include <stdlib.h>
+//#include <inttypes.h>
+
+int main()
+{
+ float d, f = 3.1415;
+
+// uint32_t a = 7, b = 3, c, r;
+
+// c = a / b;
+// r = a % b;
+
+ d = f * 2.1;
+
+ return( 0 );
+}
Index: products/H3-glibc/1.11.4/H3-TEST-neon
===================================================================
--- products/H3-glibc/1.11.4/H3-TEST-neon (nonexistent)
+++ products/H3-glibc/1.11.4/H3-TEST-neon (revision 76)
Property changes on: products/H3-glibc/1.11.4/H3-TEST-neon
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/H3-glibc/1.11.4/Makefile
===================================================================
--- products/H3-glibc/1.11.4/Makefile (nonexistent)
+++ products/H3-glibc/1.11.4/Makefile (revision 76)
@@ -0,0 +1,35 @@
+
+
+COMPONENT_TARGETS = $(TOOLCHAIN_H3_GLIBC)
+
+export TOOLCHAIN_VERSION = 1.11.4
+
+include ../../../build-system/config.mk
+
+REQUIRES = core/gcc/14.2.0^full
+REQUIRES += tools/patchelf/0.18.0
+REQUIRES += core/gdb/16.2
+
+# ======= __END_OF_REQUIRES__ =======
+
+tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
+tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
+
+tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
+
+BUILD_TARGETS = $(tarball_target)
+
+PRODUCT_TARGETS = $(tarball)
+
+include ../../../build-system/core.mk
+
+
+$(tarball): $(tarball_target)
+
+$(tarball_target):
+ @echo ""
+ @echo "Creating $(tarball_name) tarball..."
+ @cd $(TOOLCHAINS_BASE_PATH) ; \
+ tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
+ @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
+ @touch $@
Index: products/H3-glibc/1.11.4
===================================================================
--- products/H3-glibc/1.11.4 (nonexistent)
+++ products/H3-glibc/1.11.4 (revision 76)
Property changes on: products/H3-glibc/1.11.4
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/H5-glibc/1.11.3/H5-TEST/main.c
===================================================================
--- products/H5-glibc/1.11.3/H5-TEST/main.c (revision 75)
+++ products/H5-glibc/1.11.3/H5-TEST/main.c (nonexistent)
@@ -1,17 +0,0 @@
-
-//#include <stdlib.h>
-//#include <inttypes.h>
-
-int main()
-{
- float d, f = 3.1415;
-
-// uint32_t a = 7, b = 3, c, r;
-
-// c = a / b;
-// r = a % b;
-
- d = f * 2.1;
-
- return( 0 );
-}
Index: products/H5-glibc/1.11.3/H5-TEST/build.sh
===================================================================
--- products/H5-glibc/1.11.3/H5-TEST/build.sh (revision 75)
+++ products/H5-glibc/1.11.3/H5-TEST/build.sh (nonexistent)
@@ -1,19 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-ARCH_FLAGS=" -march=armv8-a -mcpu=cortex-a53"
-
-$TARGET-gcc -g -O3 -gdwarf-2 -fomit-frame-pointer $ARCH_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/H5-glibc/1.11.3/H5-TEST/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/H5-glibc/1.11.3/H5-TEST/.config
===================================================================
--- products/H5-glibc/1.11.3/H5-TEST/.config (revision 75)
+++ products/H5-glibc/1.11.3/H5-TEST/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=aarch64-h5-linux-gnu
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/aarch64-H5-linux-glibc/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/H5-glibc/1.11.3/H5-TEST/clean.sh
===================================================================
--- products/H5-glibc/1.11.3/H5-TEST/clean.sh (revision 75)
+++ products/H5-glibc/1.11.3/H5-TEST/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/H5-glibc/1.11.3/H5-TEST/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/H5-glibc/1.11.3/H5-TEST
===================================================================
--- products/H5-glibc/1.11.3/H5-TEST (revision 75)
+++ products/H5-glibc/1.11.3/H5-TEST (nonexistent)
Property changes on: products/H5-glibc/1.11.3/H5-TEST
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/H5-glibc/1.11.3/Makefile
===================================================================
--- products/H5-glibc/1.11.3/Makefile (revision 75)
+++ products/H5-glibc/1.11.3/Makefile (nonexistent)
@@ -1,35 +0,0 @@
-
-
-COMPONENT_TARGETS = $(TOOLCHAIN_H5_GLIBC)
-
-export TOOLCHAIN_VERSION = 1.11.3
-
-include ../../../build-system/config.mk
-
-REQUIRES = core/gcc/14.2.0^full
-REQUIRES += tools/patchelf/0.18.0
-REQUIRES += core/gdb/15.1
-
-# ======= __END_OF_REQUIRES__ =======
-
-tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
-tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
-
-tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
-
-BUILD_TARGETS = $(tarball_target)
-
-PRODUCT_TARGETS = $(tarball)
-
-include ../../../build-system/core.mk
-
-
-$(tarball): $(tarball_target)
-
-$(tarball_target):
- @echo ""
- @echo "Creating $(tarball_name) tarball..."
- @cd $(TOOLCHAINS_BASE_PATH) ; \
- tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
- @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
- @touch $@
Index: products/H5-glibc/1.11.3
===================================================================
--- products/H5-glibc/1.11.3 (revision 75)
+++ products/H5-glibc/1.11.3 (nonexistent)
Property changes on: products/H5-glibc/1.11.3
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/H5-glibc/1.11.4/H5-TEST/.config
===================================================================
--- products/H5-glibc/1.11.4/H5-TEST/.config (nonexistent)
+++ products/H5-glibc/1.11.4/H5-TEST/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=aarch64-h5-linux-gnu
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/aarch64-H5-linux-glibc/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/H5-glibc/1.11.4/H5-TEST/build.sh
===================================================================
--- products/H5-glibc/1.11.4/H5-TEST/build.sh (nonexistent)
+++ products/H5-glibc/1.11.4/H5-TEST/build.sh (revision 76)
@@ -0,0 +1,19 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+ARCH_FLAGS=" -march=armv8-a -mcpu=cortex-a53"
+
+$TARGET-gcc -g -O3 -gdwarf-2 -fomit-frame-pointer $ARCH_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/H5-glibc/1.11.4/H5-TEST/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/H5-glibc/1.11.4/H5-TEST/clean.sh
===================================================================
--- products/H5-glibc/1.11.4/H5-TEST/clean.sh (nonexistent)
+++ products/H5-glibc/1.11.4/H5-TEST/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/H5-glibc/1.11.4/H5-TEST/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/H5-glibc/1.11.4/H5-TEST/main.c
===================================================================
--- products/H5-glibc/1.11.4/H5-TEST/main.c (nonexistent)
+++ products/H5-glibc/1.11.4/H5-TEST/main.c (revision 76)
@@ -0,0 +1,17 @@
+
+//#include <stdlib.h>
+//#include <inttypes.h>
+
+int main()
+{
+ float d, f = 3.1415;
+
+// uint32_t a = 7, b = 3, c, r;
+
+// c = a / b;
+// r = a % b;
+
+ d = f * 2.1;
+
+ return( 0 );
+}
Index: products/H5-glibc/1.11.4/H5-TEST
===================================================================
--- products/H5-glibc/1.11.4/H5-TEST (nonexistent)
+++ products/H5-glibc/1.11.4/H5-TEST (revision 76)
Property changes on: products/H5-glibc/1.11.4/H5-TEST
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/H5-glibc/1.11.4/Makefile
===================================================================
--- products/H5-glibc/1.11.4/Makefile (nonexistent)
+++ products/H5-glibc/1.11.4/Makefile (revision 76)
@@ -0,0 +1,35 @@
+
+
+COMPONENT_TARGETS = $(TOOLCHAIN_H5_GLIBC)
+
+export TOOLCHAIN_VERSION = 1.11.4
+
+include ../../../build-system/config.mk
+
+REQUIRES = core/gcc/14.2.0^full
+REQUIRES += tools/patchelf/0.18.0
+REQUIRES += core/gdb/16.2
+
+# ======= __END_OF_REQUIRES__ =======
+
+tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
+tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
+
+tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
+
+BUILD_TARGETS = $(tarball_target)
+
+PRODUCT_TARGETS = $(tarball)
+
+include ../../../build-system/core.mk
+
+
+$(tarball): $(tarball_target)
+
+$(tarball_target):
+ @echo ""
+ @echo "Creating $(tarball_name) tarball..."
+ @cd $(TOOLCHAINS_BASE_PATH) ; \
+ tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
+ @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
+ @touch $@
Index: products/H5-glibc/1.11.4
===================================================================
--- products/H5-glibc/1.11.4 (nonexistent)
+++ products/H5-glibc/1.11.4 (revision 76)
Property changes on: products/H5-glibc/1.11.4
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/H5-newlib/1.11.3/H5-TEST-ilp32/main.c
===================================================================
--- products/H5-newlib/1.11.3/H5-TEST-ilp32/main.c (revision 75)
+++ products/H5-newlib/1.11.3/H5-TEST-ilp32/main.c (nonexistent)
@@ -1,13 +0,0 @@
-
-#include <stdlib.h>
-#include <inttypes.h>
-
-int main()
-{
- uint32_t a = 7, b = 3, c, r;
-
- c = a / b;
- r = a % b;
-
- return( 0 );
-}
Index: products/H5-newlib/1.11.3/H5-TEST-ilp32/build.sh
===================================================================
--- products/H5-newlib/1.11.3/H5-TEST-ilp32/build.sh (revision 75)
+++ products/H5-newlib/1.11.3/H5-TEST-ilp32/build.sh (nonexistent)
@@ -1,20 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-DEBUG_FLAGS="-gdwarf-2"
-ARCH_FLAGS=" -march=armv8-a -mcpu=cortex-a53 -mabi=ilp32 -mlittle-endian"
-
-$TARGET-gcc -g $DEBUG_FLAGS $ARCH_FLAGS -fomit-frame-pointer -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-$TARGET-gcc $DEBUG_FLAGS $ARCH_FLAGS -o main main.o -lc -lm -lnosys -lrdimon
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/H5-newlib/1.11.3/H5-TEST-ilp32/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/H5-newlib/1.11.3/H5-TEST-ilp32/.config
===================================================================
--- products/H5-newlib/1.11.3/H5-TEST-ilp32/.config (revision 75)
+++ products/H5-newlib/1.11.3/H5-TEST-ilp32/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=aarch64-h5-elf
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/aarch64-H5-elf-newlib/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/H5-newlib/1.11.3/H5-TEST-ilp32/clean.sh
===================================================================
--- products/H5-newlib/1.11.3/H5-TEST-ilp32/clean.sh (revision 75)
+++ products/H5-newlib/1.11.3/H5-TEST-ilp32/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/H5-newlib/1.11.3/H5-TEST-ilp32/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/H5-newlib/1.11.3/H5-TEST-ilp32
===================================================================
--- products/H5-newlib/1.11.3/H5-TEST-ilp32 (revision 75)
+++ products/H5-newlib/1.11.3/H5-TEST-ilp32 (nonexistent)
Property changes on: products/H5-newlib/1.11.3/H5-TEST-ilp32
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/H5-newlib/1.11.3/H5-TEST-lp64/main.c
===================================================================
--- products/H5-newlib/1.11.3/H5-TEST-lp64/main.c (revision 75)
+++ products/H5-newlib/1.11.3/H5-TEST-lp64/main.c (nonexistent)
@@ -1,13 +0,0 @@
-
-#include <stdlib.h>
-#include <inttypes.h>
-
-int main()
-{
- uint32_t a = 7, b = 3, c, r;
-
- c = a / b;
- r = a % b;
-
- return( 0 );
-}
Index: products/H5-newlib/1.11.3/H5-TEST-lp64/build.sh
===================================================================
--- products/H5-newlib/1.11.3/H5-TEST-lp64/build.sh (revision 75)
+++ products/H5-newlib/1.11.3/H5-TEST-lp64/build.sh (nonexistent)
@@ -1,20 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-DEBUG_FLAGS="-gdwarf-2"
-ARCH_FLAGS=" -march=armv8-a -mcpu=cortex-a53 -mabi=lp64 -mlittle-endian"
-
-$TARGET-gcc -g $DEBUG_FLAGS $ARCH_FLAGS -fomit-frame-pointer -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-$TARGET-gcc $DEBUG_FLAGS $ARCH_FLAGS -o main main.o -lc -lm -lnosys -lrdimon
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/H5-newlib/1.11.3/H5-TEST-lp64/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/H5-newlib/1.11.3/H5-TEST-lp64/.config
===================================================================
--- products/H5-newlib/1.11.3/H5-TEST-lp64/.config (revision 75)
+++ products/H5-newlib/1.11.3/H5-TEST-lp64/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=aarch64-h5-elf
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/aarch64-H5-elf-newlib/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/H5-newlib/1.11.3/H5-TEST-lp64/clean.sh
===================================================================
--- products/H5-newlib/1.11.3/H5-TEST-lp64/clean.sh (revision 75)
+++ products/H5-newlib/1.11.3/H5-TEST-lp64/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/H5-newlib/1.11.3/H5-TEST-lp64/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/H5-newlib/1.11.3/H5-TEST-lp64
===================================================================
--- products/H5-newlib/1.11.3/H5-TEST-lp64 (revision 75)
+++ products/H5-newlib/1.11.3/H5-TEST-lp64 (nonexistent)
Property changes on: products/H5-newlib/1.11.3/H5-TEST-lp64
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/H5-newlib/1.11.3/Makefile
===================================================================
--- products/H5-newlib/1.11.3/Makefile (revision 75)
+++ products/H5-newlib/1.11.3/Makefile (nonexistent)
@@ -1,34 +0,0 @@
-
-
-COMPONENT_TARGETS = $(TOOLCHAIN_H5_NEWLIB)
-
-export TOOLCHAIN_VERSION = 1.11.3
-
-include ../../../build-system/config.mk
-
-REQUIRES = core/gcc/14.2.0^full
-REQUIRES += core/gdb/15.1
-
-# ======= __END_OF_REQUIRES__ =======
-
-tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
-tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
-
-tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
-
-BUILD_TARGETS = $(tarball_target)
-
-PRODUCT_TARGETS = $(tarball)
-
-include ../../../build-system/core.mk
-
-
-$(tarball): $(tarball_target)
-
-$(tarball_target):
- @echo ""
- @echo "Creating $(tarball_name) tarball..."
- @cd $(TOOLCHAINS_BASE_PATH) ; \
- tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
- @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
- @touch $@
Index: products/H5-newlib/1.11.3
===================================================================
--- products/H5-newlib/1.11.3 (revision 75)
+++ products/H5-newlib/1.11.3 (nonexistent)
Property changes on: products/H5-newlib/1.11.3
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/H5-newlib/1.11.4/H5-TEST-ilp32/.config
===================================================================
--- products/H5-newlib/1.11.4/H5-TEST-ilp32/.config (nonexistent)
+++ products/H5-newlib/1.11.4/H5-TEST-ilp32/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=aarch64-h5-elf
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/aarch64-H5-elf-newlib/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/H5-newlib/1.11.4/H5-TEST-ilp32/build.sh
===================================================================
--- products/H5-newlib/1.11.4/H5-TEST-ilp32/build.sh (nonexistent)
+++ products/H5-newlib/1.11.4/H5-TEST-ilp32/build.sh (revision 76)
@@ -0,0 +1,20 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+DEBUG_FLAGS="-gdwarf-2"
+ARCH_FLAGS=" -march=armv8-a -mcpu=cortex-a53 -mabi=ilp32 -mlittle-endian"
+
+$TARGET-gcc -g $DEBUG_FLAGS $ARCH_FLAGS -fomit-frame-pointer -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+$TARGET-gcc $DEBUG_FLAGS $ARCH_FLAGS -o main main.o -lc -lm -lnosys -lrdimon
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/H5-newlib/1.11.4/H5-TEST-ilp32/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/H5-newlib/1.11.4/H5-TEST-ilp32/clean.sh
===================================================================
--- products/H5-newlib/1.11.4/H5-TEST-ilp32/clean.sh (nonexistent)
+++ products/H5-newlib/1.11.4/H5-TEST-ilp32/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/H5-newlib/1.11.4/H5-TEST-ilp32/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/H5-newlib/1.11.4/H5-TEST-ilp32/main.c
===================================================================
--- products/H5-newlib/1.11.4/H5-TEST-ilp32/main.c (nonexistent)
+++ products/H5-newlib/1.11.4/H5-TEST-ilp32/main.c (revision 76)
@@ -0,0 +1,13 @@
+
+#include <stdlib.h>
+#include <inttypes.h>
+
+int main()
+{
+ uint32_t a = 7, b = 3, c, r;
+
+ c = a / b;
+ r = a % b;
+
+ return( 0 );
+}
Index: products/H5-newlib/1.11.4/H5-TEST-ilp32
===================================================================
--- products/H5-newlib/1.11.4/H5-TEST-ilp32 (nonexistent)
+++ products/H5-newlib/1.11.4/H5-TEST-ilp32 (revision 76)
Property changes on: products/H5-newlib/1.11.4/H5-TEST-ilp32
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/H5-newlib/1.11.4/H5-TEST-lp64/.config
===================================================================
--- products/H5-newlib/1.11.4/H5-TEST-lp64/.config (nonexistent)
+++ products/H5-newlib/1.11.4/H5-TEST-lp64/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=aarch64-h5-elf
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/aarch64-H5-elf-newlib/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/H5-newlib/1.11.4/H5-TEST-lp64/build.sh
===================================================================
--- products/H5-newlib/1.11.4/H5-TEST-lp64/build.sh (nonexistent)
+++ products/H5-newlib/1.11.4/H5-TEST-lp64/build.sh (revision 76)
@@ -0,0 +1,20 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+DEBUG_FLAGS="-gdwarf-2"
+ARCH_FLAGS=" -march=armv8-a -mcpu=cortex-a53 -mabi=lp64 -mlittle-endian"
+
+$TARGET-gcc -g $DEBUG_FLAGS $ARCH_FLAGS -fomit-frame-pointer -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+$TARGET-gcc $DEBUG_FLAGS $ARCH_FLAGS -o main main.o -lc -lm -lnosys -lrdimon
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/H5-newlib/1.11.4/H5-TEST-lp64/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/H5-newlib/1.11.4/H5-TEST-lp64/clean.sh
===================================================================
--- products/H5-newlib/1.11.4/H5-TEST-lp64/clean.sh (nonexistent)
+++ products/H5-newlib/1.11.4/H5-TEST-lp64/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/H5-newlib/1.11.4/H5-TEST-lp64/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/H5-newlib/1.11.4/H5-TEST-lp64/main.c
===================================================================
--- products/H5-newlib/1.11.4/H5-TEST-lp64/main.c (nonexistent)
+++ products/H5-newlib/1.11.4/H5-TEST-lp64/main.c (revision 76)
@@ -0,0 +1,13 @@
+
+#include <stdlib.h>
+#include <inttypes.h>
+
+int main()
+{
+ uint32_t a = 7, b = 3, c, r;
+
+ c = a / b;
+ r = a % b;
+
+ return( 0 );
+}
Index: products/H5-newlib/1.11.4/H5-TEST-lp64
===================================================================
--- products/H5-newlib/1.11.4/H5-TEST-lp64 (nonexistent)
+++ products/H5-newlib/1.11.4/H5-TEST-lp64 (revision 76)
Property changes on: products/H5-newlib/1.11.4/H5-TEST-lp64
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/H5-newlib/1.11.4/Makefile
===================================================================
--- products/H5-newlib/1.11.4/Makefile (nonexistent)
+++ products/H5-newlib/1.11.4/Makefile (revision 76)
@@ -0,0 +1,34 @@
+
+
+COMPONENT_TARGETS = $(TOOLCHAIN_H5_NEWLIB)
+
+export TOOLCHAIN_VERSION = 1.11.4
+
+include ../../../build-system/config.mk
+
+REQUIRES = core/gcc/14.2.0^full
+REQUIRES += core/gdb/16.2
+
+# ======= __END_OF_REQUIRES__ =======
+
+tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
+tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
+
+tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
+
+BUILD_TARGETS = $(tarball_target)
+
+PRODUCT_TARGETS = $(tarball)
+
+include ../../../build-system/core.mk
+
+
+$(tarball): $(tarball_target)
+
+$(tarball_target):
+ @echo ""
+ @echo "Creating $(tarball_name) tarball..."
+ @cd $(TOOLCHAINS_BASE_PATH) ; \
+ tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
+ @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
+ @touch $@
Index: products/H5-newlib/1.11.4
===================================================================
--- products/H5-newlib/1.11.4 (nonexistent)
+++ products/H5-newlib/1.11.4 (revision 76)
Property changes on: products/H5-newlib/1.11.4
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/I586-glibc/1.11.3/I586-TEST/main.c
===================================================================
--- products/I586-glibc/1.11.3/I586-TEST/main.c (revision 75)
+++ products/I586-glibc/1.11.3/I586-TEST/main.c (nonexistent)
@@ -1,19 +0,0 @@
-
-#include <stdlib.h>
-#include <stdio.h>
-#include <inttypes.h>
-
-int main()
-{
- uint32_t a = 7, b = 3, c, r;
- double y, x = 3.5;
-
- y = x + 2.8;
-
- c = a / b;
- r = a % b;
-
- printf("\nHello, World!\n\n");
-
- return( 0 );
-}
Index: products/I586-glibc/1.11.3/I586-TEST/build.sh
===================================================================
--- products/I586-glibc/1.11.3/I586-TEST/build.sh (revision 75)
+++ products/I586-glibc/1.11.3/I586-TEST/build.sh (nonexistent)
@@ -1,17 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-$TARGET-gcc -g -gdwarf-2 -march=i586 -mtune=i586 -fomit-frame-pointer -I$TOOLCHAIN_PATH/$TARGET/sys-root/usr/include -c -o main.o main.c
-$TARGET-gcc -o main main.o
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/I586-glibc/1.11.3/I586-TEST/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/I586-glibc/1.11.3/I586-TEST/.config
===================================================================
--- products/I586-glibc/1.11.3/I586-TEST/.config (revision 75)
+++ products/I586-glibc/1.11.3/I586-TEST/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=i586-radix-linux-gnu
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/i586-PC-linux-glibc/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/I586-glibc/1.11.3/I586-TEST/clean.sh
===================================================================
--- products/I586-glibc/1.11.3/I586-TEST/clean.sh (revision 75)
+++ products/I586-glibc/1.11.3/I586-TEST/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/I586-glibc/1.11.3/I586-TEST/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/I586-glibc/1.11.3/I586-TEST
===================================================================
--- products/I586-glibc/1.11.3/I586-TEST (revision 75)
+++ products/I586-glibc/1.11.3/I586-TEST (nonexistent)
Property changes on: products/I586-glibc/1.11.3/I586-TEST
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/I586-glibc/1.11.3/Makefile
===================================================================
--- products/I586-glibc/1.11.3/Makefile (revision 75)
+++ products/I586-glibc/1.11.3/Makefile (nonexistent)
@@ -1,35 +0,0 @@
-
-
-COMPONENT_TARGETS = $(TOOLCHAIN_I586_GLIBC)
-
-export TOOLCHAIN_VERSION = 1.11.3
-
-include ../../../build-system/config.mk
-
-REQUIRES = core/gcc/14.2.0^full
-REQUIRES += tools/patchelf/0.18.0
-REQUIRES += core/gdb/15.1
-
-# ======= __END_OF_REQUIRES__ =======
-
-tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
-tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
-
-tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
-
-BUILD_TARGETS = $(tarball_target)
-
-PRODUCT_TARGETS = $(tarball)
-
-include ../../../build-system/core.mk
-
-
-$(tarball): $(tarball_target)
-
-$(tarball_target):
- @echo ""
- @echo "Creating $(tarball_name) tarball..."
- @cd $(TOOLCHAINS_BASE_PATH) ; \
- tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
- @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
- @touch $@
Index: products/I586-glibc/1.11.3
===================================================================
--- products/I586-glibc/1.11.3 (revision 75)
+++ products/I586-glibc/1.11.3 (nonexistent)
Property changes on: products/I586-glibc/1.11.3
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/I586-glibc/1.11.4/I586-TEST/.config
===================================================================
--- products/I586-glibc/1.11.4/I586-TEST/.config (nonexistent)
+++ products/I586-glibc/1.11.4/I586-TEST/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=i586-radix-linux-gnu
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/i586-PC-linux-glibc/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/I586-glibc/1.11.4/I586-TEST/build.sh
===================================================================
--- products/I586-glibc/1.11.4/I586-TEST/build.sh (nonexistent)
+++ products/I586-glibc/1.11.4/I586-TEST/build.sh (revision 76)
@@ -0,0 +1,17 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+$TARGET-gcc -g -gdwarf-2 -march=i586 -mtune=i586 -fomit-frame-pointer -I$TOOLCHAIN_PATH/$TARGET/sys-root/usr/include -c -o main.o main.c
+$TARGET-gcc -o main main.o
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/I586-glibc/1.11.4/I586-TEST/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/I586-glibc/1.11.4/I586-TEST/clean.sh
===================================================================
--- products/I586-glibc/1.11.4/I586-TEST/clean.sh (nonexistent)
+++ products/I586-glibc/1.11.4/I586-TEST/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/I586-glibc/1.11.4/I586-TEST/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/I586-glibc/1.11.4/I586-TEST/main.c
===================================================================
--- products/I586-glibc/1.11.4/I586-TEST/main.c (nonexistent)
+++ products/I586-glibc/1.11.4/I586-TEST/main.c (revision 76)
@@ -0,0 +1,19 @@
+
+#include <stdlib.h>
+#include <stdio.h>
+#include <inttypes.h>
+
+int main()
+{
+ uint32_t a = 7, b = 3, c, r;
+ double y, x = 3.5;
+
+ y = x + 2.8;
+
+ c = a / b;
+ r = a % b;
+
+ printf("\nHello, World!\n\n");
+
+ return( 0 );
+}
Index: products/I586-glibc/1.11.4/I586-TEST
===================================================================
--- products/I586-glibc/1.11.4/I586-TEST (nonexistent)
+++ products/I586-glibc/1.11.4/I586-TEST (revision 76)
Property changes on: products/I586-glibc/1.11.4/I586-TEST
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/I586-glibc/1.11.4/Makefile
===================================================================
--- products/I586-glibc/1.11.4/Makefile (nonexistent)
+++ products/I586-glibc/1.11.4/Makefile (revision 76)
@@ -0,0 +1,35 @@
+
+
+COMPONENT_TARGETS = $(TOOLCHAIN_I586_GLIBC)
+
+export TOOLCHAIN_VERSION = 1.11.4
+
+include ../../../build-system/config.mk
+
+REQUIRES = core/gcc/14.2.0^full
+REQUIRES += tools/patchelf/0.18.0
+REQUIRES += core/gdb/16.2
+
+# ======= __END_OF_REQUIRES__ =======
+
+tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
+tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
+
+tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
+
+BUILD_TARGETS = $(tarball_target)
+
+PRODUCT_TARGETS = $(tarball)
+
+include ../../../build-system/core.mk
+
+
+$(tarball): $(tarball_target)
+
+$(tarball_target):
+ @echo ""
+ @echo "Creating $(tarball_name) tarball..."
+ @cd $(TOOLCHAINS_BASE_PATH) ; \
+ tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
+ @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
+ @touch $@
Index: products/I586-glibc/1.11.4
===================================================================
--- products/I586-glibc/1.11.4 (nonexistent)
+++ products/I586-glibc/1.11.4 (revision 76)
Property changes on: products/I586-glibc/1.11.4
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/I686-glibc/1.11.3/I686-TEST/main.c
===================================================================
--- products/I686-glibc/1.11.3/I686-TEST/main.c (revision 75)
+++ products/I686-glibc/1.11.3/I686-TEST/main.c (nonexistent)
@@ -1,19 +0,0 @@
-
-#include <stdlib.h>
-#include <stdio.h>
-#include <inttypes.h>
-
-int main()
-{
- uint32_t a = 7, b = 3, c, r;
- double y, x = 3.5;
-
- y = x + 2.8;
-
- c = a / b;
- r = a % b;
-
- printf("\nHello, World!\n\n");
-
- return( 0 );
-}
Index: products/I686-glibc/1.11.3/I686-TEST/build.sh
===================================================================
--- products/I686-glibc/1.11.3/I686-TEST/build.sh (revision 75)
+++ products/I686-glibc/1.11.3/I686-TEST/build.sh (nonexistent)
@@ -1,17 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-$TARGET-gcc -g -gdwarf-2 -fomit-frame-pointer -I$TOOLCHAIN_PATH/$TARGET/sys-root/usr/include -c -o main.o main.c
-$TARGET-gcc -o main main.o
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/I686-glibc/1.11.3/I686-TEST/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/I686-glibc/1.11.3/I686-TEST/.config
===================================================================
--- products/I686-glibc/1.11.3/I686-TEST/.config (revision 75)
+++ products/I686-glibc/1.11.3/I686-TEST/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=i686-radix-linux-gnu
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/i686-PC-linux-glibc/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/I686-glibc/1.11.3/I686-TEST/clean.sh
===================================================================
--- products/I686-glibc/1.11.3/I686-TEST/clean.sh (revision 75)
+++ products/I686-glibc/1.11.3/I686-TEST/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/I686-glibc/1.11.3/I686-TEST/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/I686-glibc/1.11.3/I686-TEST
===================================================================
--- products/I686-glibc/1.11.3/I686-TEST (revision 75)
+++ products/I686-glibc/1.11.3/I686-TEST (nonexistent)
Property changes on: products/I686-glibc/1.11.3/I686-TEST
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/I686-glibc/1.11.3/Makefile
===================================================================
--- products/I686-glibc/1.11.3/Makefile (revision 75)
+++ products/I686-glibc/1.11.3/Makefile (nonexistent)
@@ -1,35 +0,0 @@
-
-
-COMPONENT_TARGETS = $(TOOLCHAIN_I686_GLIBC)
-
-export TOOLCHAIN_VERSION = 1.11.3
-
-include ../../../build-system/config.mk
-
-REQUIRES = core/gcc/14.2.0^full
-REQUIRES += tools/patchelf/0.18.0
-REQUIRES += core/gdb/15.1
-
-# ======= __END_OF_REQUIRES__ =======
-
-tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
-tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
-
-tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
-
-BUILD_TARGETS = $(tarball_target)
-
-PRODUCT_TARGETS = $(tarball)
-
-include ../../../build-system/core.mk
-
-
-$(tarball): $(tarball_target)
-
-$(tarball_target):
- @echo ""
- @echo "Creating $(tarball_name) tarball..."
- @cd $(TOOLCHAINS_BASE_PATH) ; \
- tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
- @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
- @touch $@
Index: products/I686-glibc/1.11.3
===================================================================
--- products/I686-glibc/1.11.3 (revision 75)
+++ products/I686-glibc/1.11.3 (nonexistent)
Property changes on: products/I686-glibc/1.11.3
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/I686-glibc/1.11.4/I686-TEST/.config
===================================================================
--- products/I686-glibc/1.11.4/I686-TEST/.config (nonexistent)
+++ products/I686-glibc/1.11.4/I686-TEST/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=i686-radix-linux-gnu
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/i686-PC-linux-glibc/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/I686-glibc/1.11.4/I686-TEST/build.sh
===================================================================
--- products/I686-glibc/1.11.4/I686-TEST/build.sh (nonexistent)
+++ products/I686-glibc/1.11.4/I686-TEST/build.sh (revision 76)
@@ -0,0 +1,17 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+$TARGET-gcc -g -gdwarf-2 -fomit-frame-pointer -I$TOOLCHAIN_PATH/$TARGET/sys-root/usr/include -c -o main.o main.c
+$TARGET-gcc -o main main.o
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/I686-glibc/1.11.4/I686-TEST/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/I686-glibc/1.11.4/I686-TEST/clean.sh
===================================================================
--- products/I686-glibc/1.11.4/I686-TEST/clean.sh (nonexistent)
+++ products/I686-glibc/1.11.4/I686-TEST/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/I686-glibc/1.11.4/I686-TEST/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/I686-glibc/1.11.4/I686-TEST/main.c
===================================================================
--- products/I686-glibc/1.11.4/I686-TEST/main.c (nonexistent)
+++ products/I686-glibc/1.11.4/I686-TEST/main.c (revision 76)
@@ -0,0 +1,19 @@
+
+#include <stdlib.h>
+#include <stdio.h>
+#include <inttypes.h>
+
+int main()
+{
+ uint32_t a = 7, b = 3, c, r;
+ double y, x = 3.5;
+
+ y = x + 2.8;
+
+ c = a / b;
+ r = a % b;
+
+ printf("\nHello, World!\n\n");
+
+ return( 0 );
+}
Index: products/I686-glibc/1.11.4/I686-TEST
===================================================================
--- products/I686-glibc/1.11.4/I686-TEST (nonexistent)
+++ products/I686-glibc/1.11.4/I686-TEST (revision 76)
Property changes on: products/I686-glibc/1.11.4/I686-TEST
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/I686-glibc/1.11.4/Makefile
===================================================================
--- products/I686-glibc/1.11.4/Makefile (nonexistent)
+++ products/I686-glibc/1.11.4/Makefile (revision 76)
@@ -0,0 +1,35 @@
+
+
+COMPONENT_TARGETS = $(TOOLCHAIN_I686_GLIBC)
+
+export TOOLCHAIN_VERSION = 1.11.4
+
+include ../../../build-system/config.mk
+
+REQUIRES = core/gcc/14.2.0^full
+REQUIRES += tools/patchelf/0.18.0
+REQUIRES += core/gdb/16.2
+
+# ======= __END_OF_REQUIRES__ =======
+
+tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
+tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
+
+tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
+
+BUILD_TARGETS = $(tarball_target)
+
+PRODUCT_TARGETS = $(tarball)
+
+include ../../../build-system/core.mk
+
+
+$(tarball): $(tarball_target)
+
+$(tarball_target):
+ @echo ""
+ @echo "Creating $(tarball_name) tarball..."
+ @cd $(TOOLCHAINS_BASE_PATH) ; \
+ tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
+ @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
+ @touch $@
Index: products/I686-glibc/1.11.4
===================================================================
--- products/I686-glibc/1.11.4 (nonexistent)
+++ products/I686-glibc/1.11.4 (revision 76)
Property changes on: products/I686-glibc/1.11.4
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/IMX6-glibc/1.11.3/IMX6-TEST-vfp/main.c
===================================================================
--- products/IMX6-glibc/1.11.3/IMX6-TEST-vfp/main.c (revision 75)
+++ products/IMX6-glibc/1.11.3/IMX6-TEST-vfp/main.c (nonexistent)
@@ -1,17 +0,0 @@
-
-//#include <stdlib.h>
-//#include <inttypes.h>
-
-int main()
-{
- float d, f = 3.1415;
-
-// uint32_t a = 7, b = 3, c, r;
-
-// c = a / b;
-// r = a % b;
-
- d = f * 2.1;
-
- return( 0 );
-}
Index: products/IMX6-glibc/1.11.3/IMX6-TEST-vfp/build.sh
===================================================================
--- products/IMX6-glibc/1.11.3/IMX6-TEST-vfp/build.sh (revision 75)
+++ products/IMX6-glibc/1.11.3/IMX6-TEST-vfp/build.sh (nonexistent)
@@ -1,21 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-ARCH_FLAGS=" -march=armv7-a -mtune=cortex-a9"
-
-FPU_FLAGS=" -mfpu=vfpv3 -mfloat-abi=hard"
-
-$TARGET-gcc -g -fomit-frame-pointer $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/IMX6-glibc/1.11.3/IMX6-TEST-vfp/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/IMX6-glibc/1.11.3/IMX6-TEST-vfp/.config
===================================================================
--- products/IMX6-glibc/1.11.3/IMX6-TEST-vfp/.config (revision 75)
+++ products/IMX6-glibc/1.11.3/IMX6-TEST-vfp/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=arm-imx6-linux-gnueabihf
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/arm-IMX6-linux-glibc/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/IMX6-glibc/1.11.3/IMX6-TEST-vfp/clean.sh
===================================================================
--- products/IMX6-glibc/1.11.3/IMX6-TEST-vfp/clean.sh (revision 75)
+++ products/IMX6-glibc/1.11.3/IMX6-TEST-vfp/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/IMX6-glibc/1.11.3/IMX6-TEST-vfp/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/IMX6-glibc/1.11.3/IMX6-TEST-vfp
===================================================================
--- products/IMX6-glibc/1.11.3/IMX6-TEST-vfp (revision 75)
+++ products/IMX6-glibc/1.11.3/IMX6-TEST-vfp (nonexistent)
Property changes on: products/IMX6-glibc/1.11.3/IMX6-TEST-vfp
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/IMX6-glibc/1.11.3/IMX6-TEST/main.c
===================================================================
--- products/IMX6-glibc/1.11.3/IMX6-TEST/main.c (revision 75)
+++ products/IMX6-glibc/1.11.3/IMX6-TEST/main.c (nonexistent)
@@ -1,17 +0,0 @@
-
-//#include <stdlib.h>
-//#include <inttypes.h>
-
-int main()
-{
- float d, f = 3.1415;
-
-// uint32_t a = 7, b = 3, c, r;
-
-// c = a / b;
-// r = a % b;
-
- d = f * 2.1;
-
- return( 0 );
-}
Index: products/IMX6-glibc/1.11.3/IMX6-TEST/build.sh
===================================================================
--- products/IMX6-glibc/1.11.3/IMX6-TEST/build.sh (revision 75)
+++ products/IMX6-glibc/1.11.3/IMX6-TEST/build.sh (nonexistent)
@@ -1,20 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-ARCH_FLAGS=" -march=armv7-a -mtune=cortex-a9"
-
-
-$TARGET-gcc -g -fomit-frame-pointer $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/IMX6-glibc/1.11.3/IMX6-TEST/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/IMX6-glibc/1.11.3/IMX6-TEST/.config
===================================================================
--- products/IMX6-glibc/1.11.3/IMX6-TEST/.config (revision 75)
+++ products/IMX6-glibc/1.11.3/IMX6-TEST/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=arm-imx6-linux-gnueabihf
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/arm-IMX6-linux-glibc/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/IMX6-glibc/1.11.3/IMX6-TEST/clean.sh
===================================================================
--- products/IMX6-glibc/1.11.3/IMX6-TEST/clean.sh (revision 75)
+++ products/IMX6-glibc/1.11.3/IMX6-TEST/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/IMX6-glibc/1.11.3/IMX6-TEST/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/IMX6-glibc/1.11.3/IMX6-TEST
===================================================================
--- products/IMX6-glibc/1.11.3/IMX6-TEST (revision 75)
+++ products/IMX6-glibc/1.11.3/IMX6-TEST (nonexistent)
Property changes on: products/IMX6-glibc/1.11.3/IMX6-TEST
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/IMX6-glibc/1.11.3/Makefile
===================================================================
--- products/IMX6-glibc/1.11.3/Makefile (revision 75)
+++ products/IMX6-glibc/1.11.3/Makefile (nonexistent)
@@ -1,35 +0,0 @@
-
-
-COMPONENT_TARGETS = $(TOOLCHAIN_IMX6_GLIBC)
-
-export TOOLCHAIN_VERSION = 1.11.3
-
-include ../../../build-system/config.mk
-
-REQUIRES = core/gcc/14.2.0^full
-REQUIRES += tools/patchelf/0.18.0
-REQUIRES += core/gdb/15.1
-
-# ======= __END_OF_REQUIRES__ =======
-
-tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
-tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
-
-tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
-
-BUILD_TARGETS = $(tarball_target)
-
-PRODUCT_TARGETS = $(tarball)
-
-include ../../../build-system/core.mk
-
-
-$(tarball): $(tarball_target)
-
-$(tarball_target):
- @echo ""
- @echo "Creating $(tarball_name) tarball..."
- @cd $(TOOLCHAINS_BASE_PATH) ; \
- tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
- @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
- @touch $@
Index: products/IMX6-glibc/1.11.3
===================================================================
--- products/IMX6-glibc/1.11.3 (revision 75)
+++ products/IMX6-glibc/1.11.3 (nonexistent)
Property changes on: products/IMX6-glibc/1.11.3
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/IMX6-glibc/1.11.4/IMX6-TEST/.config
===================================================================
--- products/IMX6-glibc/1.11.4/IMX6-TEST/.config (nonexistent)
+++ products/IMX6-glibc/1.11.4/IMX6-TEST/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=arm-imx6-linux-gnueabihf
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/arm-IMX6-linux-glibc/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/IMX6-glibc/1.11.4/IMX6-TEST/build.sh
===================================================================
--- products/IMX6-glibc/1.11.4/IMX6-TEST/build.sh (nonexistent)
+++ products/IMX6-glibc/1.11.4/IMX6-TEST/build.sh (revision 76)
@@ -0,0 +1,20 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+ARCH_FLAGS=" -march=armv7-a -mtune=cortex-a9"
+
+
+$TARGET-gcc -g -fomit-frame-pointer $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/IMX6-glibc/1.11.4/IMX6-TEST/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/IMX6-glibc/1.11.4/IMX6-TEST/clean.sh
===================================================================
--- products/IMX6-glibc/1.11.4/IMX6-TEST/clean.sh (nonexistent)
+++ products/IMX6-glibc/1.11.4/IMX6-TEST/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/IMX6-glibc/1.11.4/IMX6-TEST/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/IMX6-glibc/1.11.4/IMX6-TEST/main.c
===================================================================
--- products/IMX6-glibc/1.11.4/IMX6-TEST/main.c (nonexistent)
+++ products/IMX6-glibc/1.11.4/IMX6-TEST/main.c (revision 76)
@@ -0,0 +1,17 @@
+
+//#include <stdlib.h>
+//#include <inttypes.h>
+
+int main()
+{
+ float d, f = 3.1415;
+
+// uint32_t a = 7, b = 3, c, r;
+
+// c = a / b;
+// r = a % b;
+
+ d = f * 2.1;
+
+ return( 0 );
+}
Index: products/IMX6-glibc/1.11.4/IMX6-TEST
===================================================================
--- products/IMX6-glibc/1.11.4/IMX6-TEST (nonexistent)
+++ products/IMX6-glibc/1.11.4/IMX6-TEST (revision 76)
Property changes on: products/IMX6-glibc/1.11.4/IMX6-TEST
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/IMX6-glibc/1.11.4/IMX6-TEST-vfp/.config
===================================================================
--- products/IMX6-glibc/1.11.4/IMX6-TEST-vfp/.config (nonexistent)
+++ products/IMX6-glibc/1.11.4/IMX6-TEST-vfp/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=arm-imx6-linux-gnueabihf
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/arm-IMX6-linux-glibc/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/IMX6-glibc/1.11.4/IMX6-TEST-vfp/build.sh
===================================================================
--- products/IMX6-glibc/1.11.4/IMX6-TEST-vfp/build.sh (nonexistent)
+++ products/IMX6-glibc/1.11.4/IMX6-TEST-vfp/build.sh (revision 76)
@@ -0,0 +1,21 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+ARCH_FLAGS=" -march=armv7-a -mtune=cortex-a9"
+
+FPU_FLAGS=" -mfpu=vfpv3 -mfloat-abi=hard"
+
+$TARGET-gcc -g -fomit-frame-pointer $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/IMX6-glibc/1.11.4/IMX6-TEST-vfp/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/IMX6-glibc/1.11.4/IMX6-TEST-vfp/clean.sh
===================================================================
--- products/IMX6-glibc/1.11.4/IMX6-TEST-vfp/clean.sh (nonexistent)
+++ products/IMX6-glibc/1.11.4/IMX6-TEST-vfp/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/IMX6-glibc/1.11.4/IMX6-TEST-vfp/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/IMX6-glibc/1.11.4/IMX6-TEST-vfp/main.c
===================================================================
--- products/IMX6-glibc/1.11.4/IMX6-TEST-vfp/main.c (nonexistent)
+++ products/IMX6-glibc/1.11.4/IMX6-TEST-vfp/main.c (revision 76)
@@ -0,0 +1,17 @@
+
+//#include <stdlib.h>
+//#include <inttypes.h>
+
+int main()
+{
+ float d, f = 3.1415;
+
+// uint32_t a = 7, b = 3, c, r;
+
+// c = a / b;
+// r = a % b;
+
+ d = f * 2.1;
+
+ return( 0 );
+}
Index: products/IMX6-glibc/1.11.4/IMX6-TEST-vfp
===================================================================
--- products/IMX6-glibc/1.11.4/IMX6-TEST-vfp (nonexistent)
+++ products/IMX6-glibc/1.11.4/IMX6-TEST-vfp (revision 76)
Property changes on: products/IMX6-glibc/1.11.4/IMX6-TEST-vfp
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/IMX6-glibc/1.11.4/Makefile
===================================================================
--- products/IMX6-glibc/1.11.4/Makefile (nonexistent)
+++ products/IMX6-glibc/1.11.4/Makefile (revision 76)
@@ -0,0 +1,35 @@
+
+
+COMPONENT_TARGETS = $(TOOLCHAIN_IMX6_GLIBC)
+
+export TOOLCHAIN_VERSION = 1.11.4
+
+include ../../../build-system/config.mk
+
+REQUIRES = core/gcc/14.2.0^full
+REQUIRES += tools/patchelf/0.18.0
+REQUIRES += core/gdb/16.2
+
+# ======= __END_OF_REQUIRES__ =======
+
+tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
+tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
+
+tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
+
+BUILD_TARGETS = $(tarball_target)
+
+PRODUCT_TARGETS = $(tarball)
+
+include ../../../build-system/core.mk
+
+
+$(tarball): $(tarball_target)
+
+$(tarball_target):
+ @echo ""
+ @echo "Creating $(tarball_name) tarball..."
+ @cd $(TOOLCHAINS_BASE_PATH) ; \
+ tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
+ @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
+ @touch $@
Index: products/IMX6-glibc/1.11.4
===================================================================
--- products/IMX6-glibc/1.11.4 (nonexistent)
+++ products/IMX6-glibc/1.11.4 (revision 76)
Property changes on: products/IMX6-glibc/1.11.4
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/IMX6ULL-glibc/1.11.3/IMX6-TEST-vfp/main.c
===================================================================
--- products/IMX6ULL-glibc/1.11.3/IMX6-TEST-vfp/main.c (revision 75)
+++ products/IMX6ULL-glibc/1.11.3/IMX6-TEST-vfp/main.c (nonexistent)
@@ -1,17 +0,0 @@
-
-//#include <stdlib.h>
-//#include <inttypes.h>
-
-int main()
-{
- float d, f = 3.1415;
-
-// uint32_t a = 7, b = 3, c, r;
-
-// c = a / b;
-// r = a % b;
-
- d = f * 2.1;
-
- return( 0 );
-}
Index: products/IMX6ULL-glibc/1.11.3/IMX6-TEST-vfp/build.sh
===================================================================
--- products/IMX6ULL-glibc/1.11.3/IMX6-TEST-vfp/build.sh (revision 75)
+++ products/IMX6ULL-glibc/1.11.3/IMX6-TEST-vfp/build.sh (nonexistent)
@@ -1,21 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-ARCH_FLAGS=" -march=armv7-a -mtune=cortex-a7"
-
-FPU_FLAGS=" -mfpu=neon-vfpv4 -mfloat-abi=hard"
-
-$TARGET-gcc -g -fomit-frame-pointer $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/IMX6ULL-glibc/1.11.3/IMX6-TEST-vfp/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/IMX6ULL-glibc/1.11.3/IMX6-TEST-vfp/.config
===================================================================
--- products/IMX6ULL-glibc/1.11.3/IMX6-TEST-vfp/.config (revision 75)
+++ products/IMX6ULL-glibc/1.11.3/IMX6-TEST-vfp/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=arm-imx6ull-linux-gnueabihf
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/arm-IMX6ULL-linux-glibc/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/IMX6ULL-glibc/1.11.3/IMX6-TEST-vfp/clean.sh
===================================================================
--- products/IMX6ULL-glibc/1.11.3/IMX6-TEST-vfp/clean.sh (revision 75)
+++ products/IMX6ULL-glibc/1.11.3/IMX6-TEST-vfp/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/IMX6ULL-glibc/1.11.3/IMX6-TEST-vfp/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/IMX6ULL-glibc/1.11.3/IMX6-TEST-vfp
===================================================================
--- products/IMX6ULL-glibc/1.11.3/IMX6-TEST-vfp (revision 75)
+++ products/IMX6ULL-glibc/1.11.3/IMX6-TEST-vfp (nonexistent)
Property changes on: products/IMX6ULL-glibc/1.11.3/IMX6-TEST-vfp
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/IMX6ULL-glibc/1.11.3/IMX6-TEST/main.c
===================================================================
--- products/IMX6ULL-glibc/1.11.3/IMX6-TEST/main.c (revision 75)
+++ products/IMX6ULL-glibc/1.11.3/IMX6-TEST/main.c (nonexistent)
@@ -1,17 +0,0 @@
-
-//#include <stdlib.h>
-//#include <inttypes.h>
-
-int main()
-{
- float d, f = 3.1415;
-
-// uint32_t a = 7, b = 3, c, r;
-
-// c = a / b;
-// r = a % b;
-
- d = f * 2.1;
-
- return( 0 );
-}
Index: products/IMX6ULL-glibc/1.11.3/IMX6-TEST/build.sh
===================================================================
--- products/IMX6ULL-glibc/1.11.3/IMX6-TEST/build.sh (revision 75)
+++ products/IMX6ULL-glibc/1.11.3/IMX6-TEST/build.sh (nonexistent)
@@ -1,20 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-ARCH_FLAGS=" -march=armv7-a -mtune=cortex-a7"
-
-
-$TARGET-gcc -g -fomit-frame-pointer $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/IMX6ULL-glibc/1.11.3/IMX6-TEST/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/IMX6ULL-glibc/1.11.3/IMX6-TEST/.config
===================================================================
--- products/IMX6ULL-glibc/1.11.3/IMX6-TEST/.config (revision 75)
+++ products/IMX6ULL-glibc/1.11.3/IMX6-TEST/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=arm-imx6ull-linux-gnueabihf
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/arm-IMX6ULL-linux-glibc/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/IMX6ULL-glibc/1.11.3/IMX6-TEST/clean.sh
===================================================================
--- products/IMX6ULL-glibc/1.11.3/IMX6-TEST/clean.sh (revision 75)
+++ products/IMX6ULL-glibc/1.11.3/IMX6-TEST/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/IMX6ULL-glibc/1.11.3/IMX6-TEST/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/IMX6ULL-glibc/1.11.3/IMX6-TEST
===================================================================
--- products/IMX6ULL-glibc/1.11.3/IMX6-TEST (revision 75)
+++ products/IMX6ULL-glibc/1.11.3/IMX6-TEST (nonexistent)
Property changes on: products/IMX6ULL-glibc/1.11.3/IMX6-TEST
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/IMX6ULL-glibc/1.11.3/Makefile
===================================================================
--- products/IMX6ULL-glibc/1.11.3/Makefile (revision 75)
+++ products/IMX6ULL-glibc/1.11.3/Makefile (nonexistent)
@@ -1,35 +0,0 @@
-
-
-COMPONENT_TARGETS = $(TOOLCHAIN_IMX6ULL_GLIBC)
-
-export TOOLCHAIN_VERSION = 1.11.3
-
-include ../../../build-system/config.mk
-
-REQUIRES = core/gcc/14.2.0^full
-REQUIRES += tools/patchelf/0.18.0
-REQUIRES += core/gdb/15.1
-
-# ======= __END_OF_REQUIRES__ =======
-
-tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
-tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
-
-tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
-
-BUILD_TARGETS = $(tarball_target)
-
-PRODUCT_TARGETS = $(tarball)
-
-include ../../../build-system/core.mk
-
-
-$(tarball): $(tarball_target)
-
-$(tarball_target):
- @echo ""
- @echo "Creating $(tarball_name) tarball..."
- @cd $(TOOLCHAINS_BASE_PATH) ; \
- tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
- @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
- @touch $@
Index: products/IMX6ULL-glibc/1.11.3
===================================================================
--- products/IMX6ULL-glibc/1.11.3 (revision 75)
+++ products/IMX6ULL-glibc/1.11.3 (nonexistent)
Property changes on: products/IMX6ULL-glibc/1.11.3
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/IMX6ULL-glibc/1.11.4/IMX6-TEST/.config
===================================================================
--- products/IMX6ULL-glibc/1.11.4/IMX6-TEST/.config (nonexistent)
+++ products/IMX6ULL-glibc/1.11.4/IMX6-TEST/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=arm-imx6ull-linux-gnueabihf
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/arm-IMX6ULL-linux-glibc/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/IMX6ULL-glibc/1.11.4/IMX6-TEST/build.sh
===================================================================
--- products/IMX6ULL-glibc/1.11.4/IMX6-TEST/build.sh (nonexistent)
+++ products/IMX6ULL-glibc/1.11.4/IMX6-TEST/build.sh (revision 76)
@@ -0,0 +1,20 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+ARCH_FLAGS=" -march=armv7-a -mtune=cortex-a7"
+
+
+$TARGET-gcc -g -fomit-frame-pointer $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/IMX6ULL-glibc/1.11.4/IMX6-TEST/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/IMX6ULL-glibc/1.11.4/IMX6-TEST/clean.sh
===================================================================
--- products/IMX6ULL-glibc/1.11.4/IMX6-TEST/clean.sh (nonexistent)
+++ products/IMX6ULL-glibc/1.11.4/IMX6-TEST/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/IMX6ULL-glibc/1.11.4/IMX6-TEST/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/IMX6ULL-glibc/1.11.4/IMX6-TEST/main.c
===================================================================
--- products/IMX6ULL-glibc/1.11.4/IMX6-TEST/main.c (nonexistent)
+++ products/IMX6ULL-glibc/1.11.4/IMX6-TEST/main.c (revision 76)
@@ -0,0 +1,17 @@
+
+//#include <stdlib.h>
+//#include <inttypes.h>
+
+int main()
+{
+ float d, f = 3.1415;
+
+// uint32_t a = 7, b = 3, c, r;
+
+// c = a / b;
+// r = a % b;
+
+ d = f * 2.1;
+
+ return( 0 );
+}
Index: products/IMX6ULL-glibc/1.11.4/IMX6-TEST
===================================================================
--- products/IMX6ULL-glibc/1.11.4/IMX6-TEST (nonexistent)
+++ products/IMX6ULL-glibc/1.11.4/IMX6-TEST (revision 76)
Property changes on: products/IMX6ULL-glibc/1.11.4/IMX6-TEST
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/IMX6ULL-glibc/1.11.4/IMX6-TEST-vfp/.config
===================================================================
--- products/IMX6ULL-glibc/1.11.4/IMX6-TEST-vfp/.config (nonexistent)
+++ products/IMX6ULL-glibc/1.11.4/IMX6-TEST-vfp/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=arm-imx6ull-linux-gnueabihf
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/arm-IMX6ULL-linux-glibc/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/IMX6ULL-glibc/1.11.4/IMX6-TEST-vfp/build.sh
===================================================================
--- products/IMX6ULL-glibc/1.11.4/IMX6-TEST-vfp/build.sh (nonexistent)
+++ products/IMX6ULL-glibc/1.11.4/IMX6-TEST-vfp/build.sh (revision 76)
@@ -0,0 +1,21 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+ARCH_FLAGS=" -march=armv7-a -mtune=cortex-a7"
+
+FPU_FLAGS=" -mfpu=neon-vfpv4 -mfloat-abi=hard"
+
+$TARGET-gcc -g -fomit-frame-pointer $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/IMX6ULL-glibc/1.11.4/IMX6-TEST-vfp/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/IMX6ULL-glibc/1.11.4/IMX6-TEST-vfp/clean.sh
===================================================================
--- products/IMX6ULL-glibc/1.11.4/IMX6-TEST-vfp/clean.sh (nonexistent)
+++ products/IMX6ULL-glibc/1.11.4/IMX6-TEST-vfp/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/IMX6ULL-glibc/1.11.4/IMX6-TEST-vfp/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/IMX6ULL-glibc/1.11.4/IMX6-TEST-vfp/main.c
===================================================================
--- products/IMX6ULL-glibc/1.11.4/IMX6-TEST-vfp/main.c (nonexistent)
+++ products/IMX6ULL-glibc/1.11.4/IMX6-TEST-vfp/main.c (revision 76)
@@ -0,0 +1,17 @@
+
+//#include <stdlib.h>
+//#include <inttypes.h>
+
+int main()
+{
+ float d, f = 3.1415;
+
+// uint32_t a = 7, b = 3, c, r;
+
+// c = a / b;
+// r = a % b;
+
+ d = f * 2.1;
+
+ return( 0 );
+}
Index: products/IMX6ULL-glibc/1.11.4/IMX6-TEST-vfp
===================================================================
--- products/IMX6ULL-glibc/1.11.4/IMX6-TEST-vfp (nonexistent)
+++ products/IMX6ULL-glibc/1.11.4/IMX6-TEST-vfp (revision 76)
Property changes on: products/IMX6ULL-glibc/1.11.4/IMX6-TEST-vfp
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/IMX6ULL-glibc/1.11.4/Makefile
===================================================================
--- products/IMX6ULL-glibc/1.11.4/Makefile (nonexistent)
+++ products/IMX6ULL-glibc/1.11.4/Makefile (revision 76)
@@ -0,0 +1,35 @@
+
+
+COMPONENT_TARGETS = $(TOOLCHAIN_IMX6ULL_GLIBC)
+
+export TOOLCHAIN_VERSION = 1.11.4
+
+include ../../../build-system/config.mk
+
+REQUIRES = core/gcc/14.2.0^full
+REQUIRES += tools/patchelf/0.18.0
+REQUIRES += core/gdb/16.2
+
+# ======= __END_OF_REQUIRES__ =======
+
+tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
+tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
+
+tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
+
+BUILD_TARGETS = $(tarball_target)
+
+PRODUCT_TARGETS = $(tarball)
+
+include ../../../build-system/core.mk
+
+
+$(tarball): $(tarball_target)
+
+$(tarball_target):
+ @echo ""
+ @echo "Creating $(tarball_name) tarball..."
+ @cd $(TOOLCHAINS_BASE_PATH) ; \
+ tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
+ @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
+ @touch $@
Index: products/IMX6ULL-glibc/1.11.4
===================================================================
--- products/IMX6ULL-glibc/1.11.4 (nonexistent)
+++ products/IMX6ULL-glibc/1.11.4 (revision 76)
Property changes on: products/IMX6ULL-glibc/1.11.4
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/JZ47XX-glibc/1.11.3/JZ47XX-TEST/main.c
===================================================================
--- products/JZ47XX-glibc/1.11.3/JZ47XX-TEST/main.c (revision 75)
+++ products/JZ47XX-glibc/1.11.3/JZ47XX-TEST/main.c (nonexistent)
@@ -1,17 +0,0 @@
-
-#include <stdlib.h>
-#include <inttypes.h>
-
-int main()
-{
- float d, f = 3.1415;
-
- uint32_t a = 7, b = 3, c, r;
-
- c = a / b;
- r = a % b;
-
- d = f * 2.1;
-
- return( 0 );
-}
Index: products/JZ47XX-glibc/1.11.3/JZ47XX-TEST/build.sh
===================================================================
--- products/JZ47XX-glibc/1.11.3/JZ47XX-TEST/build.sh (revision 75)
+++ products/JZ47XX-glibc/1.11.3/JZ47XX-TEST/build.sh (nonexistent)
@@ -1,20 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-ARCH_FLAGS=" -march=mips32r2 -mhard-float"
-
-
-$TARGET-gcc -g -gdwarf-2 -fomit-frame-pointer $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/JZ47XX-glibc/1.11.3/JZ47XX-TEST/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/JZ47XX-glibc/1.11.3/JZ47XX-TEST/.config
===================================================================
--- products/JZ47XX-glibc/1.11.3/JZ47XX-TEST/.config (revision 75)
+++ products/JZ47XX-glibc/1.11.3/JZ47XX-TEST/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=mipsel-jz47xx-linux-gnu
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/mipsel-JZ47XX-linux-glibc/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/JZ47XX-glibc/1.11.3/JZ47XX-TEST/clean.sh
===================================================================
--- products/JZ47XX-glibc/1.11.3/JZ47XX-TEST/clean.sh (revision 75)
+++ products/JZ47XX-glibc/1.11.3/JZ47XX-TEST/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/JZ47XX-glibc/1.11.3/JZ47XX-TEST/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/JZ47XX-glibc/1.11.3/JZ47XX-TEST
===================================================================
--- products/JZ47XX-glibc/1.11.3/JZ47XX-TEST (revision 75)
+++ products/JZ47XX-glibc/1.11.3/JZ47XX-TEST (nonexistent)
Property changes on: products/JZ47XX-glibc/1.11.3/JZ47XX-TEST
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/JZ47XX-glibc/1.11.3/Makefile
===================================================================
--- products/JZ47XX-glibc/1.11.3/Makefile (revision 75)
+++ products/JZ47XX-glibc/1.11.3/Makefile (nonexistent)
@@ -1,35 +0,0 @@
-
-
-COMPONENT_TARGETS = $(TOOLCHAIN_JZ47XX_GLIBC)
-
-export TOOLCHAIN_VERSION = 1.11.3
-
-include ../../../build-system/config.mk
-
-REQUIRES = core/gcc/14.2.0^full
-REQUIRES += tools/patchelf/0.18.0
-REQUIRES += core/gdb/15.1
-
-# ======= __END_OF_REQUIRES__ =======
-
-tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
-tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
-
-tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
-
-BUILD_TARGETS = $(tarball_target)
-
-PRODUCT_TARGETS = $(tarball)
-
-include ../../../build-system/core.mk
-
-
-$(tarball): $(tarball_target)
-
-$(tarball_target):
- @echo ""
- @echo "Creating $(tarball_name) tarball..."
- @cd $(TOOLCHAINS_BASE_PATH) ; \
- tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
- @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
- @touch $@
Index: products/JZ47XX-glibc/1.11.3
===================================================================
--- products/JZ47XX-glibc/1.11.3 (revision 75)
+++ products/JZ47XX-glibc/1.11.3 (nonexistent)
Property changes on: products/JZ47XX-glibc/1.11.3
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/JZ47XX-glibc/1.11.4/JZ47XX-TEST/.config
===================================================================
--- products/JZ47XX-glibc/1.11.4/JZ47XX-TEST/.config (nonexistent)
+++ products/JZ47XX-glibc/1.11.4/JZ47XX-TEST/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=mipsel-jz47xx-linux-gnu
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/mipsel-JZ47XX-linux-glibc/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/JZ47XX-glibc/1.11.4/JZ47XX-TEST/build.sh
===================================================================
--- products/JZ47XX-glibc/1.11.4/JZ47XX-TEST/build.sh (nonexistent)
+++ products/JZ47XX-glibc/1.11.4/JZ47XX-TEST/build.sh (revision 76)
@@ -0,0 +1,20 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+ARCH_FLAGS=" -march=mips32r2 -mhard-float"
+
+
+$TARGET-gcc -g -gdwarf-2 -fomit-frame-pointer $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/JZ47XX-glibc/1.11.4/JZ47XX-TEST/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/JZ47XX-glibc/1.11.4/JZ47XX-TEST/clean.sh
===================================================================
--- products/JZ47XX-glibc/1.11.4/JZ47XX-TEST/clean.sh (nonexistent)
+++ products/JZ47XX-glibc/1.11.4/JZ47XX-TEST/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/JZ47XX-glibc/1.11.4/JZ47XX-TEST/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/JZ47XX-glibc/1.11.4/JZ47XX-TEST/main.c
===================================================================
--- products/JZ47XX-glibc/1.11.4/JZ47XX-TEST/main.c (nonexistent)
+++ products/JZ47XX-glibc/1.11.4/JZ47XX-TEST/main.c (revision 76)
@@ -0,0 +1,17 @@
+
+#include <stdlib.h>
+#include <inttypes.h>
+
+int main()
+{
+ float d, f = 3.1415;
+
+ uint32_t a = 7, b = 3, c, r;
+
+ c = a / b;
+ r = a % b;
+
+ d = f * 2.1;
+
+ return( 0 );
+}
Index: products/JZ47XX-glibc/1.11.4/JZ47XX-TEST
===================================================================
--- products/JZ47XX-glibc/1.11.4/JZ47XX-TEST (nonexistent)
+++ products/JZ47XX-glibc/1.11.4/JZ47XX-TEST (revision 76)
Property changes on: products/JZ47XX-glibc/1.11.4/JZ47XX-TEST
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/JZ47XX-glibc/1.11.4/Makefile
===================================================================
--- products/JZ47XX-glibc/1.11.4/Makefile (nonexistent)
+++ products/JZ47XX-glibc/1.11.4/Makefile (revision 76)
@@ -0,0 +1,35 @@
+
+
+COMPONENT_TARGETS = $(TOOLCHAIN_JZ47XX_GLIBC)
+
+export TOOLCHAIN_VERSION = 1.11.4
+
+include ../../../build-system/config.mk
+
+REQUIRES = core/gcc/14.2.0^full
+REQUIRES += tools/patchelf/0.18.0
+REQUIRES += core/gdb/16.2
+
+# ======= __END_OF_REQUIRES__ =======
+
+tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
+tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
+
+tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
+
+BUILD_TARGETS = $(tarball_target)
+
+PRODUCT_TARGETS = $(tarball)
+
+include ../../../build-system/core.mk
+
+
+$(tarball): $(tarball_target)
+
+$(tarball_target):
+ @echo ""
+ @echo "Creating $(tarball_name) tarball..."
+ @cd $(TOOLCHAINS_BASE_PATH) ; \
+ tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
+ @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
+ @touch $@
Index: products/JZ47XX-glibc/1.11.4
===================================================================
--- products/JZ47XX-glibc/1.11.4 (nonexistent)
+++ products/JZ47XX-glibc/1.11.4 (revision 76)
Property changes on: products/JZ47XX-glibc/1.11.4
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/M1000-glibc/1.11.3/M1000-TEST/main.c
===================================================================
--- products/M1000-glibc/1.11.3/M1000-TEST/main.c (revision 75)
+++ products/M1000-glibc/1.11.3/M1000-TEST/main.c (nonexistent)
@@ -1,17 +0,0 @@
-
-#include <stdlib.h>
-#include <inttypes.h>
-
-int main()
-{
- float d, f = 3.1415;
-
- uint32_t a = 7, b = 3, c, r;
-
- c = a / b;
- r = a % b;
-
- d = f * 2.1;
-
- return( 0 );
-}
Index: products/M1000-glibc/1.11.3/M1000-TEST/build.sh
===================================================================
--- products/M1000-glibc/1.11.3/M1000-TEST/build.sh (revision 75)
+++ products/M1000-glibc/1.11.3/M1000-TEST/build.sh (nonexistent)
@@ -1,19 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-ARCH_FLAGS=" -march=armv8-a -mcpu=cortex-a57 -mabi=lp64"
-
-$TARGET-gcc -g -O3 -gdwarf-2 -fomit-frame-pointer $ARCH_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/M1000-glibc/1.11.3/M1000-TEST/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/M1000-glibc/1.11.3/M1000-TEST/.config
===================================================================
--- products/M1000-glibc/1.11.3/M1000-TEST/.config (revision 75)
+++ products/M1000-glibc/1.11.3/M1000-TEST/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=aarch64-m1000-linux-gnu
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/aarch64-M1000-linux-glibc/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/M1000-glibc/1.11.3/M1000-TEST/clean.sh
===================================================================
--- products/M1000-glibc/1.11.3/M1000-TEST/clean.sh (revision 75)
+++ products/M1000-glibc/1.11.3/M1000-TEST/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/M1000-glibc/1.11.3/M1000-TEST/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/M1000-glibc/1.11.3/M1000-TEST
===================================================================
--- products/M1000-glibc/1.11.3/M1000-TEST (revision 75)
+++ products/M1000-glibc/1.11.3/M1000-TEST (nonexistent)
Property changes on: products/M1000-glibc/1.11.3/M1000-TEST
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/M1000-glibc/1.11.3/Makefile
===================================================================
--- products/M1000-glibc/1.11.3/Makefile (revision 75)
+++ products/M1000-glibc/1.11.3/Makefile (nonexistent)
@@ -1,35 +0,0 @@
-
-
-COMPONENT_TARGETS = $(TOOLCHAIN_M1000_GLIBC)
-
-export TOOLCHAIN_VERSION = 1.11.3
-
-include ../../../build-system/config.mk
-
-REQUIRES = core/gcc/14.2.0^full
-REQUIRES += tools/patchelf/0.18.0
-REQUIRES += core/gdb/15.1
-
-# ======= __END_OF_REQUIRES__ =======
-
-tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
-tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
-
-tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
-
-BUILD_TARGETS = $(tarball_target)
-
-PRODUCT_TARGETS = $(tarball)
-
-include ../../../build-system/core.mk
-
-
-$(tarball): $(tarball_target)
-
-$(tarball_target):
- @echo ""
- @echo "Creating $(tarball_name) tarball..."
- @cd $(TOOLCHAINS_BASE_PATH) ; \
- tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
- @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
- @touch $@
Index: products/M1000-glibc/1.11.3
===================================================================
--- products/M1000-glibc/1.11.3 (revision 75)
+++ products/M1000-glibc/1.11.3 (nonexistent)
Property changes on: products/M1000-glibc/1.11.3
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/M1000-glibc/1.11.4/M1000-TEST/.config
===================================================================
--- products/M1000-glibc/1.11.4/M1000-TEST/.config (nonexistent)
+++ products/M1000-glibc/1.11.4/M1000-TEST/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=aarch64-m1000-linux-gnu
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/aarch64-M1000-linux-glibc/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/M1000-glibc/1.11.4/M1000-TEST/build.sh
===================================================================
--- products/M1000-glibc/1.11.4/M1000-TEST/build.sh (nonexistent)
+++ products/M1000-glibc/1.11.4/M1000-TEST/build.sh (revision 76)
@@ -0,0 +1,19 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+ARCH_FLAGS=" -march=armv8-a -mcpu=cortex-a57 -mabi=lp64"
+
+$TARGET-gcc -g -O3 -gdwarf-2 -fomit-frame-pointer $ARCH_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/M1000-glibc/1.11.4/M1000-TEST/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/M1000-glibc/1.11.4/M1000-TEST/clean.sh
===================================================================
--- products/M1000-glibc/1.11.4/M1000-TEST/clean.sh (nonexistent)
+++ products/M1000-glibc/1.11.4/M1000-TEST/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/M1000-glibc/1.11.4/M1000-TEST/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/M1000-glibc/1.11.4/M1000-TEST/main.c
===================================================================
--- products/M1000-glibc/1.11.4/M1000-TEST/main.c (nonexistent)
+++ products/M1000-glibc/1.11.4/M1000-TEST/main.c (revision 76)
@@ -0,0 +1,17 @@
+
+#include <stdlib.h>
+#include <inttypes.h>
+
+int main()
+{
+ float d, f = 3.1415;
+
+ uint32_t a = 7, b = 3, c, r;
+
+ c = a / b;
+ r = a % b;
+
+ d = f * 2.1;
+
+ return( 0 );
+}
Index: products/M1000-glibc/1.11.4/M1000-TEST
===================================================================
--- products/M1000-glibc/1.11.4/M1000-TEST (nonexistent)
+++ products/M1000-glibc/1.11.4/M1000-TEST (revision 76)
Property changes on: products/M1000-glibc/1.11.4/M1000-TEST
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/M1000-glibc/1.11.4/Makefile
===================================================================
--- products/M1000-glibc/1.11.4/Makefile (nonexistent)
+++ products/M1000-glibc/1.11.4/Makefile (revision 76)
@@ -0,0 +1,35 @@
+
+
+COMPONENT_TARGETS = $(TOOLCHAIN_M1000_GLIBC)
+
+export TOOLCHAIN_VERSION = 1.11.4
+
+include ../../../build-system/config.mk
+
+REQUIRES = core/gcc/14.2.0^full
+REQUIRES += tools/patchelf/0.18.0
+REQUIRES += core/gdb/16.2
+
+# ======= __END_OF_REQUIRES__ =======
+
+tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
+tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
+
+tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
+
+BUILD_TARGETS = $(tarball_target)
+
+PRODUCT_TARGETS = $(tarball)
+
+include ../../../build-system/core.mk
+
+
+$(tarball): $(tarball_target)
+
+$(tarball_target):
+ @echo ""
+ @echo "Creating $(tarball_name) tarball..."
+ @cd $(TOOLCHAINS_BASE_PATH) ; \
+ tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
+ @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
+ @touch $@
Index: products/M1000-glibc/1.11.4
===================================================================
--- products/M1000-glibc/1.11.4 (nonexistent)
+++ products/M1000-glibc/1.11.4 (revision 76)
Property changes on: products/M1000-glibc/1.11.4
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/M1000-newlib/1.11.3/M1000-TEST-lp64/main.c
===================================================================
--- products/M1000-newlib/1.11.3/M1000-TEST-lp64/main.c (revision 75)
+++ products/M1000-newlib/1.11.3/M1000-TEST-lp64/main.c (nonexistent)
@@ -1,13 +0,0 @@
-
-#include <stdlib.h>
-#include <inttypes.h>
-
-int main()
-{
- uint32_t a = 7, b = 3, c, r;
-
- c = a / b;
- r = a % b;
-
- return( 0 );
-}
Index: products/M1000-newlib/1.11.3/M1000-TEST-lp64/build.sh
===================================================================
--- products/M1000-newlib/1.11.3/M1000-TEST-lp64/build.sh (revision 75)
+++ products/M1000-newlib/1.11.3/M1000-TEST-lp64/build.sh (nonexistent)
@@ -1,20 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-DEBUG_FLAGS="-gdwarf-2"
-ARCH_FLAGS=" -march=armv8-a -mcpu=cortex-a57 -mabi=lp64 -mlittle-endian"
-
-$TARGET-gcc -g $DEBUG_FLAGS $ARCH_FLAGS -fomit-frame-pointer -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-$TARGET-gcc $DEBUG_FLAGS $ARCH_FLAGS -o main main.o -lc -lm -lnosys -lrdimon
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/M1000-newlib/1.11.3/M1000-TEST-lp64/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/M1000-newlib/1.11.3/M1000-TEST-lp64/.config
===================================================================
--- products/M1000-newlib/1.11.3/M1000-TEST-lp64/.config (revision 75)
+++ products/M1000-newlib/1.11.3/M1000-TEST-lp64/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=aarch64-m1000-elf
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/aarch64-M1000-elf-newlib/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/M1000-newlib/1.11.3/M1000-TEST-lp64/clean.sh
===================================================================
--- products/M1000-newlib/1.11.3/M1000-TEST-lp64/clean.sh (revision 75)
+++ products/M1000-newlib/1.11.3/M1000-TEST-lp64/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/M1000-newlib/1.11.3/M1000-TEST-lp64/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/M1000-newlib/1.11.3/M1000-TEST-lp64
===================================================================
--- products/M1000-newlib/1.11.3/M1000-TEST-lp64 (revision 75)
+++ products/M1000-newlib/1.11.3/M1000-TEST-lp64 (nonexistent)
Property changes on: products/M1000-newlib/1.11.3/M1000-TEST-lp64
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/M1000-newlib/1.11.3/M1000-TEST-ilp32/main.c
===================================================================
--- products/M1000-newlib/1.11.3/M1000-TEST-ilp32/main.c (revision 75)
+++ products/M1000-newlib/1.11.3/M1000-TEST-ilp32/main.c (nonexistent)
@@ -1,13 +0,0 @@
-
-#include <stdlib.h>
-#include <inttypes.h>
-
-int main()
-{
- uint32_t a = 7, b = 3, c, r;
-
- c = a / b;
- r = a % b;
-
- return( 0 );
-}
Index: products/M1000-newlib/1.11.3/M1000-TEST-ilp32/build.sh
===================================================================
--- products/M1000-newlib/1.11.3/M1000-TEST-ilp32/build.sh (revision 75)
+++ products/M1000-newlib/1.11.3/M1000-TEST-ilp32/build.sh (nonexistent)
@@ -1,20 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-DEBUG_FLAGS="-gdwarf-2"
-ARCH_FLAGS=" -march=armv8-a -mcpu=cortex-a57 -mabi=ilp32 -mlittle-endian"
-
-$TARGET-gcc -g $DEBUG_FLAGS $ARCH_FLAGS -fomit-frame-pointer -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-$TARGET-gcc $DEBUG_FLAGS $ARCH_FLAGS -o main main.o -lc -lm -lnosys -lrdimon
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/M1000-newlib/1.11.3/M1000-TEST-ilp32/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/M1000-newlib/1.11.3/M1000-TEST-ilp32/.config
===================================================================
--- products/M1000-newlib/1.11.3/M1000-TEST-ilp32/.config (revision 75)
+++ products/M1000-newlib/1.11.3/M1000-TEST-ilp32/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=aarch64-m1000-elf
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/aarch64-M1000-elf-newlib/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/M1000-newlib/1.11.3/M1000-TEST-ilp32/clean.sh
===================================================================
--- products/M1000-newlib/1.11.3/M1000-TEST-ilp32/clean.sh (revision 75)
+++ products/M1000-newlib/1.11.3/M1000-TEST-ilp32/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/M1000-newlib/1.11.3/M1000-TEST-ilp32/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/M1000-newlib/1.11.3/M1000-TEST-ilp32
===================================================================
--- products/M1000-newlib/1.11.3/M1000-TEST-ilp32 (revision 75)
+++ products/M1000-newlib/1.11.3/M1000-TEST-ilp32 (nonexistent)
Property changes on: products/M1000-newlib/1.11.3/M1000-TEST-ilp32
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/M1000-newlib/1.11.3/Makefile
===================================================================
--- products/M1000-newlib/1.11.3/Makefile (revision 75)
+++ products/M1000-newlib/1.11.3/Makefile (nonexistent)
@@ -1,34 +0,0 @@
-
-
-COMPONENT_TARGETS = $(TOOLCHAIN_M1000_NEWLIB)
-
-export TOOLCHAIN_VERSION = 1.11.3
-
-include ../../../build-system/config.mk
-
-REQUIRES = core/gcc/14.2.0^full
-REQUIRES += core/gdb/15.1
-
-# ======= __END_OF_REQUIRES__ =======
-
-tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
-tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
-
-tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
-
-BUILD_TARGETS = $(tarball_target)
-
-PRODUCT_TARGETS = $(tarball)
-
-include ../../../build-system/core.mk
-
-
-$(tarball): $(tarball_target)
-
-$(tarball_target):
- @echo ""
- @echo "Creating $(tarball_name) tarball..."
- @cd $(TOOLCHAINS_BASE_PATH) ; \
- tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
- @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
- @touch $@
Index: products/M1000-newlib/1.11.3
===================================================================
--- products/M1000-newlib/1.11.3 (revision 75)
+++ products/M1000-newlib/1.11.3 (nonexistent)
Property changes on: products/M1000-newlib/1.11.3
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/M1000-newlib/1.11.4/M1000-TEST-ilp32/.config
===================================================================
--- products/M1000-newlib/1.11.4/M1000-TEST-ilp32/.config (nonexistent)
+++ products/M1000-newlib/1.11.4/M1000-TEST-ilp32/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=aarch64-m1000-elf
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/aarch64-M1000-elf-newlib/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/M1000-newlib/1.11.4/M1000-TEST-ilp32/build.sh
===================================================================
--- products/M1000-newlib/1.11.4/M1000-TEST-ilp32/build.sh (nonexistent)
+++ products/M1000-newlib/1.11.4/M1000-TEST-ilp32/build.sh (revision 76)
@@ -0,0 +1,20 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+DEBUG_FLAGS="-gdwarf-2"
+ARCH_FLAGS=" -march=armv8-a -mcpu=cortex-a57 -mabi=ilp32 -mlittle-endian"
+
+$TARGET-gcc -g $DEBUG_FLAGS $ARCH_FLAGS -fomit-frame-pointer -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+$TARGET-gcc $DEBUG_FLAGS $ARCH_FLAGS -o main main.o -lc -lm -lnosys -lrdimon
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/M1000-newlib/1.11.4/M1000-TEST-ilp32/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/M1000-newlib/1.11.4/M1000-TEST-ilp32/clean.sh
===================================================================
--- products/M1000-newlib/1.11.4/M1000-TEST-ilp32/clean.sh (nonexistent)
+++ products/M1000-newlib/1.11.4/M1000-TEST-ilp32/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/M1000-newlib/1.11.4/M1000-TEST-ilp32/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/M1000-newlib/1.11.4/M1000-TEST-ilp32/main.c
===================================================================
--- products/M1000-newlib/1.11.4/M1000-TEST-ilp32/main.c (nonexistent)
+++ products/M1000-newlib/1.11.4/M1000-TEST-ilp32/main.c (revision 76)
@@ -0,0 +1,13 @@
+
+#include <stdlib.h>
+#include <inttypes.h>
+
+int main()
+{
+ uint32_t a = 7, b = 3, c, r;
+
+ c = a / b;
+ r = a % b;
+
+ return( 0 );
+}
Index: products/M1000-newlib/1.11.4/M1000-TEST-ilp32
===================================================================
--- products/M1000-newlib/1.11.4/M1000-TEST-ilp32 (nonexistent)
+++ products/M1000-newlib/1.11.4/M1000-TEST-ilp32 (revision 76)
Property changes on: products/M1000-newlib/1.11.4/M1000-TEST-ilp32
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/M1000-newlib/1.11.4/M1000-TEST-lp64/.config
===================================================================
--- products/M1000-newlib/1.11.4/M1000-TEST-lp64/.config (nonexistent)
+++ products/M1000-newlib/1.11.4/M1000-TEST-lp64/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=aarch64-m1000-elf
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/aarch64-M1000-elf-newlib/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/M1000-newlib/1.11.4/M1000-TEST-lp64/build.sh
===================================================================
--- products/M1000-newlib/1.11.4/M1000-TEST-lp64/build.sh (nonexistent)
+++ products/M1000-newlib/1.11.4/M1000-TEST-lp64/build.sh (revision 76)
@@ -0,0 +1,20 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+DEBUG_FLAGS="-gdwarf-2"
+ARCH_FLAGS=" -march=armv8-a -mcpu=cortex-a57 -mabi=lp64 -mlittle-endian"
+
+$TARGET-gcc -g $DEBUG_FLAGS $ARCH_FLAGS -fomit-frame-pointer -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+$TARGET-gcc $DEBUG_FLAGS $ARCH_FLAGS -o main main.o -lc -lm -lnosys -lrdimon
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/M1000-newlib/1.11.4/M1000-TEST-lp64/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/M1000-newlib/1.11.4/M1000-TEST-lp64/clean.sh
===================================================================
--- products/M1000-newlib/1.11.4/M1000-TEST-lp64/clean.sh (nonexistent)
+++ products/M1000-newlib/1.11.4/M1000-TEST-lp64/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/M1000-newlib/1.11.4/M1000-TEST-lp64/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/M1000-newlib/1.11.4/M1000-TEST-lp64/main.c
===================================================================
--- products/M1000-newlib/1.11.4/M1000-TEST-lp64/main.c (nonexistent)
+++ products/M1000-newlib/1.11.4/M1000-TEST-lp64/main.c (revision 76)
@@ -0,0 +1,13 @@
+
+#include <stdlib.h>
+#include <inttypes.h>
+
+int main()
+{
+ uint32_t a = 7, b = 3, c, r;
+
+ c = a / b;
+ r = a % b;
+
+ return( 0 );
+}
Index: products/M1000-newlib/1.11.4/M1000-TEST-lp64
===================================================================
--- products/M1000-newlib/1.11.4/M1000-TEST-lp64 (nonexistent)
+++ products/M1000-newlib/1.11.4/M1000-TEST-lp64 (revision 76)
Property changes on: products/M1000-newlib/1.11.4/M1000-TEST-lp64
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/M1000-newlib/1.11.4/Makefile
===================================================================
--- products/M1000-newlib/1.11.4/Makefile (nonexistent)
+++ products/M1000-newlib/1.11.4/Makefile (revision 76)
@@ -0,0 +1,34 @@
+
+
+COMPONENT_TARGETS = $(TOOLCHAIN_M1000_NEWLIB)
+
+export TOOLCHAIN_VERSION = 1.11.4
+
+include ../../../build-system/config.mk
+
+REQUIRES = core/gcc/14.2.0^full
+REQUIRES += core/gdb/16.2
+
+# ======= __END_OF_REQUIRES__ =======
+
+tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
+tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
+
+tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
+
+BUILD_TARGETS = $(tarball_target)
+
+PRODUCT_TARGETS = $(tarball)
+
+include ../../../build-system/core.mk
+
+
+$(tarball): $(tarball_target)
+
+$(tarball_target):
+ @echo ""
+ @echo "Creating $(tarball_name) tarball..."
+ @cd $(TOOLCHAINS_BASE_PATH) ; \
+ tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
+ @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
+ @touch $@
Index: products/M1000-newlib/1.11.4
===================================================================
--- products/M1000-newlib/1.11.4 (nonexistent)
+++ products/M1000-newlib/1.11.4 (revision 76)
Property changes on: products/M1000-newlib/1.11.4
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/Makefile
===================================================================
--- products/Makefile (revision 75)
+++ products/Makefile (revision 76)
@@ -46,7 +46,7 @@
COMPONENT_TARGETS += $(TOOLCHAIN_X86_64_GLIBC)
-export TOOLCHAIN_VERSION = 1.11.3
+export TOOLCHAIN_VERSION = 1.11.4
include ../build-system/config.mk
@@ -53,126 +53,126 @@
ifeq ($(TOOLCHAIN),$(TOOLCHAIN_ARM32_NEWLIB))
-REQUIRES = products/ARM32-newlib/1.11.3
+REQUIRES = products/ARM32-newlib/1.11.4
endif
ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A33XX_NEWLIB))
-REQUIRES = products/A33XX-newlib/1.11.3
+REQUIRES = products/A33XX-newlib/1.11.4
endif
ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A9XX_NEWLIB))
-REQUIRES = products/A9XX-newlib/1.11.3
+REQUIRES = products/A9XX-newlib/1.11.4
endif
ifeq ($(TOOLCHAIN),$(TOOLCHAIN_H5_NEWLIB))
-REQUIRES = products/H5-newlib/1.11.3
+REQUIRES = products/H5-newlib/1.11.4
endif
ifeq ($(TOOLCHAIN),$(TOOLCHAIN_S9XX_NEWLIB))
-REQUIRES = products/S9XX-newlib/1.11.3
+REQUIRES = products/S9XX-newlib/1.11.4
endif
ifeq ($(TOOLCHAIN),$(TOOLCHAIN_RK33XX_NEWLIB))
-REQUIRES = products/RK33XX-newlib/1.11.3
+REQUIRES = products/RK33XX-newlib/1.11.4
endif
ifeq ($(TOOLCHAIN),$(TOOLCHAIN_M1000_NEWLIB))
-REQUIRES = products/M1000-newlib/1.11.3
+REQUIRES = products/M1000-newlib/1.11.4
endif
ifeq ($(TOOLCHAIN),$(TOOLCHAIN_AT91SAM7S_NEWLIB))
-REQUIRES = products/AT91SAM7S-newlib/1.11.3
+REQUIRES = products/AT91SAM7S-newlib/1.11.4
endif
ifeq ($(TOOLCHAIN),$(TOOLCHAIN_RISCV64_NEWLIB))
-REQUIRES = products/RISCV64-newlib/1.11.3
+REQUIRES = products/RISCV64-newlib/1.11.4
endif
ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A1X_GLIBC))
-REQUIRES = products/A1X-glibc/1.11.3
+REQUIRES = products/A1X-glibc/1.11.4
endif
ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A2X_GLIBC))
-REQUIRES = products/A2X-glibc/1.11.3
+REQUIRES = products/A2X-glibc/1.11.4
endif
ifeq ($(TOOLCHAIN),$(TOOLCHAIN_H3_GLIBC))
-REQUIRES = products/H3-glibc/1.11.3
+REQUIRES = products/H3-glibc/1.11.4
endif
ifeq ($(TOOLCHAIN),$(TOOLCHAIN_H5_GLIBC))
-REQUIRES = products/H5-glibc/1.11.3
+REQUIRES = products/H5-glibc/1.11.4
endif
ifeq ($(TOOLCHAIN),$(TOOLCHAIN_IMX6_GLIBC))
-REQUIRES = products/IMX6-glibc/1.11.3
+REQUIRES = products/IMX6-glibc/1.11.4
endif
ifeq ($(TOOLCHAIN),$(TOOLCHAIN_IMX6ULL_GLIBC))
-REQUIRES = products/IMX6ULL-glibc/1.11.3
+REQUIRES = products/IMX6ULL-glibc/1.11.4
endif
ifeq ($(TOOLCHAIN),$(TOOLCHAIN_JZ47XX_GLIBC))
-REQUIRES = products/JZ47XX-glibc/1.11.3
+REQUIRES = products/JZ47XX-glibc/1.11.4
endif
ifeq ($(TOOLCHAIN),$(TOOLCHAIN_P5600_GLIBC))
-REQUIRES = products/P5600-glibc/1.11.3
+REQUIRES = products/P5600-glibc/1.11.4
endif
ifeq ($(TOOLCHAIN),$(TOOLCHAIN_M1000_GLIBC))
-REQUIRES = products/M1000-glibc/1.11.3
+REQUIRES = products/M1000-glibc/1.11.4
endif
ifeq ($(TOOLCHAIN),$(TOOLCHAIN_OMAP543X_GLIBC))
-REQUIRES = products/OMAP543X-glibc/1.11.3
+REQUIRES = products/OMAP543X-glibc/1.11.4
endif
ifeq ($(TOOLCHAIN),$(TOOLCHAIN_AM335X_GLIBC))
-REQUIRES = products/AM335X-glibc/1.11.3
+REQUIRES = products/AM335X-glibc/1.11.4
endif
ifeq ($(TOOLCHAIN),$(TOOLCHAIN_RK328X_GLIBC))
-REQUIRES = products/RK328X-glibc/1.11.3
+REQUIRES = products/RK328X-glibc/1.11.4
endif
ifeq ($(TOOLCHAIN),$(TOOLCHAIN_S8XX_GLIBC))
-REQUIRES = products/S8XX-glibc/1.11.3
+REQUIRES = products/S8XX-glibc/1.11.4
endif
ifeq ($(TOOLCHAIN),$(TOOLCHAIN_S9XX_GLIBC))
-REQUIRES = products/S9XX-glibc/1.11.3
+REQUIRES = products/S9XX-glibc/1.11.4
endif
ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A9XX_GLIBC))
-REQUIRES = products/A9XX-glibc/1.11.3
+REQUIRES = products/A9XX-glibc/1.11.4
endif
ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A311X_GLIBC))
-REQUIRES = products/A311X-glibc/1.11.3
+REQUIRES = products/A311X-glibc/1.11.4
endif
ifeq ($(TOOLCHAIN),$(TOOLCHAIN_RK33XX_GLIBC))
-REQUIRES = products/RK33XX-glibc/1.11.3
+REQUIRES = products/RK33XX-glibc/1.11.4
endif
ifeq ($(TOOLCHAIN),$(TOOLCHAIN_RK339X_GLIBC))
-REQUIRES = products/RK339X-glibc/1.11.3
+REQUIRES = products/RK339X-glibc/1.11.4
endif
ifeq ($(TOOLCHAIN),$(TOOLCHAIN_RK358X_GLIBC))
-REQUIRES = products/RK358X-glibc/1.11.3
+REQUIRES = products/RK358X-glibc/1.11.4
endif
ifeq ($(TOOLCHAIN),$(TOOLCHAIN_A33XX_GLIBC))
-REQUIRES = products/A33XX-glibc/1.11.3
+REQUIRES = products/A33XX-glibc/1.11.4
endif
ifeq ($(TOOLCHAIN),$(TOOLCHAIN_PPC8_GLIBC))
-REQUIRES = products/PPC8-glibc/1.11.3
+REQUIRES = products/PPC8-glibc/1.11.4
endif
ifeq ($(TOOLCHAIN),$(TOOLCHAIN_PPC9_GLIBC))
-REQUIRES = products/PPC9-glibc/1.11.3
+REQUIRES = products/PPC9-glibc/1.11.4
endif
ifeq ($(TOOLCHAIN),$(TOOLCHAIN_POWER8_GLIBC))
-REQUIRES = products/POWER8-glibc/1.11.3
+REQUIRES = products/POWER8-glibc/1.11.4
endif
ifeq ($(TOOLCHAIN),$(TOOLCHAIN_POWER9_GLIBC))
-REQUIRES = products/POWER9-glibc/1.11.3
+REQUIRES = products/POWER9-glibc/1.11.4
endif
ifeq ($(TOOLCHAIN),$(TOOLCHAIN_POWER8LE_GLIBC))
-REQUIRES = products/POWER8LE-glibc/1.11.3
+REQUIRES = products/POWER8LE-glibc/1.11.4
endif
ifeq ($(TOOLCHAIN),$(TOOLCHAIN_POWER9LE_GLIBC))
-REQUIRES = products/POWER9LE-glibc/1.11.3
+REQUIRES = products/POWER9LE-glibc/1.11.4
endif
ifeq ($(TOOLCHAIN),$(TOOLCHAIN_RISCV64_GLIBC))
-REQUIRES = products/RISCV64-glibc/1.11.3
+REQUIRES = products/RISCV64-glibc/1.11.4
endif
ifeq ($(TOOLCHAIN),$(TOOLCHAIN_I586_GLIBC))
-REQUIRES = products/I586-glibc/1.11.3
+REQUIRES = products/I586-glibc/1.11.4
endif
ifeq ($(TOOLCHAIN),$(TOOLCHAIN_I686_GLIBC))
-REQUIRES = products/I686-glibc/1.11.3
+REQUIRES = products/I686-glibc/1.11.4
endif
ifeq ($(TOOLCHAIN),$(TOOLCHAIN_X86_64_GLIBC))
-REQUIRES = products/X86_64-glibc/1.11.3
+REQUIRES = products/X86_64-glibc/1.11.4
endif
Index: products/OMAP543X-glibc/1.11.3/OMAP543X-TEST/main.c
===================================================================
--- products/OMAP543X-glibc/1.11.3/OMAP543X-TEST/main.c (revision 75)
+++ products/OMAP543X-glibc/1.11.3/OMAP543X-TEST/main.c (nonexistent)
@@ -1,17 +0,0 @@
-
-//#include <stdlib.h>
-//#include <inttypes.h>
-
-int main()
-{
- float d, f = 3.1415;
-
-// uint32_t a = 7, b = 3, c, r;
-
-// c = a / b;
-// r = a % b;
-
- d = f * 2.1;
-
- return( 0 );
-}
Index: products/OMAP543X-glibc/1.11.3/OMAP543X-TEST/build.sh
===================================================================
--- products/OMAP543X-glibc/1.11.3/OMAP543X-TEST/build.sh (revision 75)
+++ products/OMAP543X-glibc/1.11.3/OMAP543X-TEST/build.sh (nonexistent)
@@ -1,20 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-ARCH_FLAGS=" -march=armv7ve -mtune=cortex-a15"
-
-
-$TARGET-gcc -g -O3 -fomit-frame-pointer $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/OMAP543X-glibc/1.11.3/OMAP543X-TEST/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/OMAP543X-glibc/1.11.3/OMAP543X-TEST/.config
===================================================================
--- products/OMAP543X-glibc/1.11.3/OMAP543X-TEST/.config (revision 75)
+++ products/OMAP543X-glibc/1.11.3/OMAP543X-TEST/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=arm-omap543x-linux-gnueabihf
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/arm-OMAP543X-linux-glibc/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/OMAP543X-glibc/1.11.3/OMAP543X-TEST/clean.sh
===================================================================
--- products/OMAP543X-glibc/1.11.3/OMAP543X-TEST/clean.sh (revision 75)
+++ products/OMAP543X-glibc/1.11.3/OMAP543X-TEST/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/OMAP543X-glibc/1.11.3/OMAP543X-TEST/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/OMAP543X-glibc/1.11.3/OMAP543X-TEST
===================================================================
--- products/OMAP543X-glibc/1.11.3/OMAP543X-TEST (revision 75)
+++ products/OMAP543X-glibc/1.11.3/OMAP543X-TEST (nonexistent)
Property changes on: products/OMAP543X-glibc/1.11.3/OMAP543X-TEST
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/OMAP543X-glibc/1.11.3/OMAP543X-TEST-vfp/main.c
===================================================================
--- products/OMAP543X-glibc/1.11.3/OMAP543X-TEST-vfp/main.c (revision 75)
+++ products/OMAP543X-glibc/1.11.3/OMAP543X-TEST-vfp/main.c (nonexistent)
@@ -1,17 +0,0 @@
-
-//#include <stdlib.h>
-//#include <inttypes.h>
-
-int main()
-{
- float d, f = 3.1415;
-
-// uint32_t a = 7, b = 3, c, r;
-
-// c = a / b;
-// r = a % b;
-
- d = f * 2.1;
-
- return( 0 );
-}
Index: products/OMAP543X-glibc/1.11.3/OMAP543X-TEST-vfp/build.sh
===================================================================
--- products/OMAP543X-glibc/1.11.3/OMAP543X-TEST-vfp/build.sh (revision 75)
+++ products/OMAP543X-glibc/1.11.3/OMAP543X-TEST-vfp/build.sh (nonexistent)
@@ -1,20 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-ARCH_FLAGS=" -march=armv7ve -mtune=cortex-a15"
-FPU_FLAGS=" -mfloat-abi=hard -mfpu=neon-vfpv4 -ffast-math"
-
-$TARGET-gcc -g -O3 -fomit-frame-pointer $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/OMAP543X-glibc/1.11.3/OMAP543X-TEST-vfp/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/OMAP543X-glibc/1.11.3/OMAP543X-TEST-vfp/.config
===================================================================
--- products/OMAP543X-glibc/1.11.3/OMAP543X-TEST-vfp/.config (revision 75)
+++ products/OMAP543X-glibc/1.11.3/OMAP543X-TEST-vfp/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=arm-omap543x-linux-gnueabihf
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/arm-OMAP543X-linux-glibc/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/OMAP543X-glibc/1.11.3/OMAP543X-TEST-vfp/clean.sh
===================================================================
--- products/OMAP543X-glibc/1.11.3/OMAP543X-TEST-vfp/clean.sh (revision 75)
+++ products/OMAP543X-glibc/1.11.3/OMAP543X-TEST-vfp/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/OMAP543X-glibc/1.11.3/OMAP543X-TEST-vfp/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/OMAP543X-glibc/1.11.3/OMAP543X-TEST-vfp
===================================================================
--- products/OMAP543X-glibc/1.11.3/OMAP543X-TEST-vfp (revision 75)
+++ products/OMAP543X-glibc/1.11.3/OMAP543X-TEST-vfp (nonexistent)
Property changes on: products/OMAP543X-glibc/1.11.3/OMAP543X-TEST-vfp
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/OMAP543X-glibc/1.11.3/Makefile
===================================================================
--- products/OMAP543X-glibc/1.11.3/Makefile (revision 75)
+++ products/OMAP543X-glibc/1.11.3/Makefile (nonexistent)
@@ -1,35 +0,0 @@
-
-
-COMPONENT_TARGETS = $(TOOLCHAIN_OMAP543X_GLIBC)
-
-export TOOLCHAIN_VERSION = 1.11.3
-
-include ../../../build-system/config.mk
-
-REQUIRES = core/gcc/14.2.0^full
-REQUIRES += tools/patchelf/0.18.0
-REQUIRES += core/gdb/15.1
-
-# ======= __END_OF_REQUIRES__ =======
-
-tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
-tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
-
-tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
-
-BUILD_TARGETS = $(tarball_target)
-
-PRODUCT_TARGETS = $(tarball)
-
-include ../../../build-system/core.mk
-
-
-$(tarball): $(tarball_target)
-
-$(tarball_target):
- @echo ""
- @echo "Creating $(tarball_name) tarball..."
- @cd $(TOOLCHAINS_BASE_PATH) ; \
- tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
- @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
- @touch $@
Index: products/OMAP543X-glibc/1.11.3
===================================================================
--- products/OMAP543X-glibc/1.11.3 (revision 75)
+++ products/OMAP543X-glibc/1.11.3 (nonexistent)
Property changes on: products/OMAP543X-glibc/1.11.3
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/OMAP543X-glibc/1.11.4/Makefile
===================================================================
--- products/OMAP543X-glibc/1.11.4/Makefile (nonexistent)
+++ products/OMAP543X-glibc/1.11.4/Makefile (revision 76)
@@ -0,0 +1,35 @@
+
+
+COMPONENT_TARGETS = $(TOOLCHAIN_OMAP543X_GLIBC)
+
+export TOOLCHAIN_VERSION = 1.11.4
+
+include ../../../build-system/config.mk
+
+REQUIRES = core/gcc/14.2.0^full
+REQUIRES += tools/patchelf/0.18.0
+REQUIRES += core/gdb/16.2
+
+# ======= __END_OF_REQUIRES__ =======
+
+tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
+tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
+
+tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
+
+BUILD_TARGETS = $(tarball_target)
+
+PRODUCT_TARGETS = $(tarball)
+
+include ../../../build-system/core.mk
+
+
+$(tarball): $(tarball_target)
+
+$(tarball_target):
+ @echo ""
+ @echo "Creating $(tarball_name) tarball..."
+ @cd $(TOOLCHAINS_BASE_PATH) ; \
+ tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
+ @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
+ @touch $@
Index: products/OMAP543X-glibc/1.11.4/OMAP543X-TEST/.config
===================================================================
--- products/OMAP543X-glibc/1.11.4/OMAP543X-TEST/.config (nonexistent)
+++ products/OMAP543X-glibc/1.11.4/OMAP543X-TEST/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=arm-omap543x-linux-gnueabihf
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/arm-OMAP543X-linux-glibc/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/OMAP543X-glibc/1.11.4/OMAP543X-TEST/build.sh
===================================================================
--- products/OMAP543X-glibc/1.11.4/OMAP543X-TEST/build.sh (nonexistent)
+++ products/OMAP543X-glibc/1.11.4/OMAP543X-TEST/build.sh (revision 76)
@@ -0,0 +1,20 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+ARCH_FLAGS=" -march=armv7ve -mtune=cortex-a15"
+
+
+$TARGET-gcc -g -O3 -fomit-frame-pointer $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/OMAP543X-glibc/1.11.4/OMAP543X-TEST/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/OMAP543X-glibc/1.11.4/OMAP543X-TEST/clean.sh
===================================================================
--- products/OMAP543X-glibc/1.11.4/OMAP543X-TEST/clean.sh (nonexistent)
+++ products/OMAP543X-glibc/1.11.4/OMAP543X-TEST/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/OMAP543X-glibc/1.11.4/OMAP543X-TEST/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/OMAP543X-glibc/1.11.4/OMAP543X-TEST/main.c
===================================================================
--- products/OMAP543X-glibc/1.11.4/OMAP543X-TEST/main.c (nonexistent)
+++ products/OMAP543X-glibc/1.11.4/OMAP543X-TEST/main.c (revision 76)
@@ -0,0 +1,17 @@
+
+//#include <stdlib.h>
+//#include <inttypes.h>
+
+int main()
+{
+ float d, f = 3.1415;
+
+// uint32_t a = 7, b = 3, c, r;
+
+// c = a / b;
+// r = a % b;
+
+ d = f * 2.1;
+
+ return( 0 );
+}
Index: products/OMAP543X-glibc/1.11.4/OMAP543X-TEST
===================================================================
--- products/OMAP543X-glibc/1.11.4/OMAP543X-TEST (nonexistent)
+++ products/OMAP543X-glibc/1.11.4/OMAP543X-TEST (revision 76)
Property changes on: products/OMAP543X-glibc/1.11.4/OMAP543X-TEST
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/OMAP543X-glibc/1.11.4/OMAP543X-TEST-vfp/.config
===================================================================
--- products/OMAP543X-glibc/1.11.4/OMAP543X-TEST-vfp/.config (nonexistent)
+++ products/OMAP543X-glibc/1.11.4/OMAP543X-TEST-vfp/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=arm-omap543x-linux-gnueabihf
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/arm-OMAP543X-linux-glibc/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/OMAP543X-glibc/1.11.4/OMAP543X-TEST-vfp/build.sh
===================================================================
--- products/OMAP543X-glibc/1.11.4/OMAP543X-TEST-vfp/build.sh (nonexistent)
+++ products/OMAP543X-glibc/1.11.4/OMAP543X-TEST-vfp/build.sh (revision 76)
@@ -0,0 +1,20 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+ARCH_FLAGS=" -march=armv7ve -mtune=cortex-a15"
+FPU_FLAGS=" -mfloat-abi=hard -mfpu=neon-vfpv4 -ffast-math"
+
+$TARGET-gcc -g -O3 -fomit-frame-pointer $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/OMAP543X-glibc/1.11.4/OMAP543X-TEST-vfp/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/OMAP543X-glibc/1.11.4/OMAP543X-TEST-vfp/clean.sh
===================================================================
--- products/OMAP543X-glibc/1.11.4/OMAP543X-TEST-vfp/clean.sh (nonexistent)
+++ products/OMAP543X-glibc/1.11.4/OMAP543X-TEST-vfp/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/OMAP543X-glibc/1.11.4/OMAP543X-TEST-vfp/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/OMAP543X-glibc/1.11.4/OMAP543X-TEST-vfp/main.c
===================================================================
--- products/OMAP543X-glibc/1.11.4/OMAP543X-TEST-vfp/main.c (nonexistent)
+++ products/OMAP543X-glibc/1.11.4/OMAP543X-TEST-vfp/main.c (revision 76)
@@ -0,0 +1,17 @@
+
+//#include <stdlib.h>
+//#include <inttypes.h>
+
+int main()
+{
+ float d, f = 3.1415;
+
+// uint32_t a = 7, b = 3, c, r;
+
+// c = a / b;
+// r = a % b;
+
+ d = f * 2.1;
+
+ return( 0 );
+}
Index: products/OMAP543X-glibc/1.11.4/OMAP543X-TEST-vfp
===================================================================
--- products/OMAP543X-glibc/1.11.4/OMAP543X-TEST-vfp (nonexistent)
+++ products/OMAP543X-glibc/1.11.4/OMAP543X-TEST-vfp (revision 76)
Property changes on: products/OMAP543X-glibc/1.11.4/OMAP543X-TEST-vfp
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/OMAP543X-glibc/1.11.4
===================================================================
--- products/OMAP543X-glibc/1.11.4 (nonexistent)
+++ products/OMAP543X-glibc/1.11.4 (revision 76)
Property changes on: products/OMAP543X-glibc/1.11.4
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/P5600-glibc/1.11.3/P5600-TEST/main.c
===================================================================
--- products/P5600-glibc/1.11.3/P5600-TEST/main.c (revision 75)
+++ products/P5600-glibc/1.11.3/P5600-TEST/main.c (nonexistent)
@@ -1,17 +0,0 @@
-
-#include <stdlib.h>
-#include <inttypes.h>
-
-int main()
-{
- float d, f = 3.1415;
-
- uint32_t a = 7, b = 3, c, r;
-
- c = a / b;
- r = a % b;
-
- d = f * 2.1;
-
- return( 0 );
-}
Index: products/P5600-glibc/1.11.3/P5600-TEST/build.sh
===================================================================
--- products/P5600-glibc/1.11.3/P5600-TEST/build.sh (revision 75)
+++ products/P5600-glibc/1.11.3/P5600-TEST/build.sh (nonexistent)
@@ -1,20 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-ARCH_FLAGS=" -march=mips32r5 -mtune=p5600 -mhard-float"
-
-
-$TARGET-gcc -g -gdwarf-2 -fomit-frame-pointer $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/P5600-glibc/1.11.3/P5600-TEST/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/P5600-glibc/1.11.3/P5600-TEST/.config
===================================================================
--- products/P5600-glibc/1.11.3/P5600-TEST/.config (revision 75)
+++ products/P5600-glibc/1.11.3/P5600-TEST/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=mipsel-p5600-linux-gnu
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/mipsel-P5600-linux-glibc/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/P5600-glibc/1.11.3/P5600-TEST/clean.sh
===================================================================
--- products/P5600-glibc/1.11.3/P5600-TEST/clean.sh (revision 75)
+++ products/P5600-glibc/1.11.3/P5600-TEST/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/P5600-glibc/1.11.3/P5600-TEST/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/P5600-glibc/1.11.3/P5600-TEST
===================================================================
--- products/P5600-glibc/1.11.3/P5600-TEST (revision 75)
+++ products/P5600-glibc/1.11.3/P5600-TEST (nonexistent)
Property changes on: products/P5600-glibc/1.11.3/P5600-TEST
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/P5600-glibc/1.11.3/Makefile
===================================================================
--- products/P5600-glibc/1.11.3/Makefile (revision 75)
+++ products/P5600-glibc/1.11.3/Makefile (nonexistent)
@@ -1,35 +0,0 @@
-
-
-COMPONENT_TARGETS = $(TOOLCHAIN_P5600_GLIBC)
-
-export TOOLCHAIN_VERSION = 1.11.3
-
-include ../../../build-system/config.mk
-
-REQUIRES = core/gcc/14.2.0^full
-REQUIRES += tools/patchelf/0.18.0
-REQUIRES += core/gdb/15.1
-
-# ======= __END_OF_REQUIRES__ =======
-
-tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
-tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
-
-tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
-
-BUILD_TARGETS = $(tarball_target)
-
-PRODUCT_TARGETS = $(tarball)
-
-include ../../../build-system/core.mk
-
-
-$(tarball): $(tarball_target)
-
-$(tarball_target):
- @echo ""
- @echo "Creating $(tarball_name) tarball..."
- @cd $(TOOLCHAINS_BASE_PATH) ; \
- tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
- @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
- @touch $@
Index: products/P5600-glibc/1.11.3
===================================================================
--- products/P5600-glibc/1.11.3 (revision 75)
+++ products/P5600-glibc/1.11.3 (nonexistent)
Property changes on: products/P5600-glibc/1.11.3
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/P5600-glibc/1.11.4/Makefile
===================================================================
--- products/P5600-glibc/1.11.4/Makefile (nonexistent)
+++ products/P5600-glibc/1.11.4/Makefile (revision 76)
@@ -0,0 +1,35 @@
+
+
+COMPONENT_TARGETS = $(TOOLCHAIN_P5600_GLIBC)
+
+export TOOLCHAIN_VERSION = 1.11.4
+
+include ../../../build-system/config.mk
+
+REQUIRES = core/gcc/14.2.0^full
+REQUIRES += tools/patchelf/0.18.0
+REQUIRES += core/gdb/16.2
+
+# ======= __END_OF_REQUIRES__ =======
+
+tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
+tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
+
+tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
+
+BUILD_TARGETS = $(tarball_target)
+
+PRODUCT_TARGETS = $(tarball)
+
+include ../../../build-system/core.mk
+
+
+$(tarball): $(tarball_target)
+
+$(tarball_target):
+ @echo ""
+ @echo "Creating $(tarball_name) tarball..."
+ @cd $(TOOLCHAINS_BASE_PATH) ; \
+ tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
+ @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
+ @touch $@
Index: products/P5600-glibc/1.11.4/P5600-TEST/.config
===================================================================
--- products/P5600-glibc/1.11.4/P5600-TEST/.config (nonexistent)
+++ products/P5600-glibc/1.11.4/P5600-TEST/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=mipsel-p5600-linux-gnu
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/mipsel-P5600-linux-glibc/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/P5600-glibc/1.11.4/P5600-TEST/build.sh
===================================================================
--- products/P5600-glibc/1.11.4/P5600-TEST/build.sh (nonexistent)
+++ products/P5600-glibc/1.11.4/P5600-TEST/build.sh (revision 76)
@@ -0,0 +1,20 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+ARCH_FLAGS=" -march=mips32r5 -mtune=p5600 -mhard-float"
+
+
+$TARGET-gcc -g -gdwarf-2 -fomit-frame-pointer $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/P5600-glibc/1.11.4/P5600-TEST/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/P5600-glibc/1.11.4/P5600-TEST/clean.sh
===================================================================
--- products/P5600-glibc/1.11.4/P5600-TEST/clean.sh (nonexistent)
+++ products/P5600-glibc/1.11.4/P5600-TEST/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/P5600-glibc/1.11.4/P5600-TEST/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/P5600-glibc/1.11.4/P5600-TEST/main.c
===================================================================
--- products/P5600-glibc/1.11.4/P5600-TEST/main.c (nonexistent)
+++ products/P5600-glibc/1.11.4/P5600-TEST/main.c (revision 76)
@@ -0,0 +1,17 @@
+
+#include <stdlib.h>
+#include <inttypes.h>
+
+int main()
+{
+ float d, f = 3.1415;
+
+ uint32_t a = 7, b = 3, c, r;
+
+ c = a / b;
+ r = a % b;
+
+ d = f * 2.1;
+
+ return( 0 );
+}
Index: products/P5600-glibc/1.11.4/P5600-TEST
===================================================================
--- products/P5600-glibc/1.11.4/P5600-TEST (nonexistent)
+++ products/P5600-glibc/1.11.4/P5600-TEST (revision 76)
Property changes on: products/P5600-glibc/1.11.4/P5600-TEST
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/P5600-glibc/1.11.4
===================================================================
--- products/P5600-glibc/1.11.4 (nonexistent)
+++ products/P5600-glibc/1.11.4 (revision 76)
Property changes on: products/P5600-glibc/1.11.4
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/POWER8-glibc/1.11.3/Makefile
===================================================================
--- products/POWER8-glibc/1.11.3/Makefile (revision 75)
+++ products/POWER8-glibc/1.11.3/Makefile (nonexistent)
@@ -1,35 +0,0 @@
-
-
-COMPONENT_TARGETS = $(TOOLCHAIN_POWER8_GLIBC)
-
-export TOOLCHAIN_VERSION = 1.11.3
-
-include ../../../build-system/config.mk
-
-REQUIRES = core/gcc/14.2.0^full
-REQUIRES += tools/patchelf/0.18.0
-REQUIRES += core/gdb/15.1
-
-# ======= __END_OF_REQUIRES__ =======
-
-tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
-tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
-
-tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
-
-BUILD_TARGETS = $(tarball_target)
-
-PRODUCT_TARGETS = $(tarball)
-
-include ../../../build-system/core.mk
-
-
-$(tarball): $(tarball_target)
-
-$(tarball_target):
- @echo ""
- @echo "Creating $(tarball_name) tarball..."
- @cd $(TOOLCHAINS_BASE_PATH) ; \
- tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
- @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
- @touch $@
Index: products/POWER8-glibc/1.11.3/POWER8-TEST/main.c
===================================================================
--- products/POWER8-glibc/1.11.3/POWER8-TEST/main.c (revision 75)
+++ products/POWER8-glibc/1.11.3/POWER8-TEST/main.c (nonexistent)
@@ -1,17 +0,0 @@
-
-#include <stdlib.h>
-#include <inttypes.h>
-
-int main()
-{
- float d, f = 3.1415;
-
- uint32_t a = 7, b = 3, c, r;
-
- c = a / b;
- r = a % b;
-
- d = f * 2.1;
-
- return( 0 );
-}
Index: products/POWER8-glibc/1.11.3/POWER8-TEST/build.sh
===================================================================
--- products/POWER8-glibc/1.11.3/POWER8-TEST/build.sh (revision 75)
+++ products/POWER8-glibc/1.11.3/POWER8-TEST/build.sh (nonexistent)
@@ -1,20 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-ARCH_FLAGS=" -g -O3 -mcpu=power8 -mlong-double-128"
-
-
-$TARGET-gcc -g -gdwarf-2 -fomit-frame-pointer $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/POWER8-glibc/1.11.3/POWER8-TEST/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/POWER8-glibc/1.11.3/POWER8-TEST/32/main.c
===================================================================
--- products/POWER8-glibc/1.11.3/POWER8-TEST/32/main.c (revision 75)
+++ products/POWER8-glibc/1.11.3/POWER8-TEST/32/main.c (nonexistent)
@@ -1,17 +0,0 @@
-
-#include <stdlib.h>
-#include <inttypes.h>
-
-int main()
-{
- float d, f = 3.1415;
-
- uint32_t a = 7, b = 3, c, r;
-
- c = a / b;
- r = a % b;
-
- d = f * 2.1;
-
- return( 0 );
-}
Index: products/POWER8-glibc/1.11.3/POWER8-TEST/32/build.sh
===================================================================
--- products/POWER8-glibc/1.11.3/POWER8-TEST/32/build.sh (revision 75)
+++ products/POWER8-glibc/1.11.3/POWER8-TEST/32/build.sh (nonexistent)
@@ -1,20 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-ARCH_FLAGS=" -g -O3 -m32 -mcpu=power8 -mlong-double-128"
-
-
-$TARGET-gcc -m32 -g -gdwarf-2 -fomit-frame-pointer $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-$TARGET-gcc -m32 $ARCH_FLAGS $FPU_FLAGS -o main main.o
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/POWER8-glibc/1.11.3/POWER8-TEST/32/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/POWER8-glibc/1.11.3/POWER8-TEST/32/.config
===================================================================
--- products/POWER8-glibc/1.11.3/POWER8-TEST/32/.config (revision 75)
+++ products/POWER8-glibc/1.11.3/POWER8-TEST/32/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=ppc64-power8-linux-gnu
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/ppc64-POWER8-linux-glibc/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/POWER8-glibc/1.11.3/POWER8-TEST/32/clean.sh
===================================================================
--- products/POWER8-glibc/1.11.3/POWER8-TEST/32/clean.sh (revision 75)
+++ products/POWER8-glibc/1.11.3/POWER8-TEST/32/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/POWER8-glibc/1.11.3/POWER8-TEST/32/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/POWER8-glibc/1.11.3/POWER8-TEST/32
===================================================================
--- products/POWER8-glibc/1.11.3/POWER8-TEST/32 (revision 75)
+++ products/POWER8-glibc/1.11.3/POWER8-TEST/32 (nonexistent)
Property changes on: products/POWER8-glibc/1.11.3/POWER8-TEST/32
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/POWER8-glibc/1.11.3/POWER8-TEST/.config
===================================================================
--- products/POWER8-glibc/1.11.3/POWER8-TEST/.config (revision 75)
+++ products/POWER8-glibc/1.11.3/POWER8-TEST/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=ppc64-power8-linux-gnu
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/ppc64-POWER8-linux-glibc/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/POWER8-glibc/1.11.3/POWER8-TEST/clean.sh
===================================================================
--- products/POWER8-glibc/1.11.3/POWER8-TEST/clean.sh (revision 75)
+++ products/POWER8-glibc/1.11.3/POWER8-TEST/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/POWER8-glibc/1.11.3/POWER8-TEST/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/POWER8-glibc/1.11.3/POWER8-TEST
===================================================================
--- products/POWER8-glibc/1.11.3/POWER8-TEST (revision 75)
+++ products/POWER8-glibc/1.11.3/POWER8-TEST (nonexistent)
Property changes on: products/POWER8-glibc/1.11.3/POWER8-TEST
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/POWER8-glibc/1.11.3
===================================================================
--- products/POWER8-glibc/1.11.3 (revision 75)
+++ products/POWER8-glibc/1.11.3 (nonexistent)
Property changes on: products/POWER8-glibc/1.11.3
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/POWER8-glibc/1.11.4/Makefile
===================================================================
--- products/POWER8-glibc/1.11.4/Makefile (nonexistent)
+++ products/POWER8-glibc/1.11.4/Makefile (revision 76)
@@ -0,0 +1,35 @@
+
+
+COMPONENT_TARGETS = $(TOOLCHAIN_POWER8_GLIBC)
+
+export TOOLCHAIN_VERSION = 1.11.4
+
+include ../../../build-system/config.mk
+
+REQUIRES = core/gcc/14.2.0^full
+REQUIRES += tools/patchelf/0.18.0
+REQUIRES += core/gdb/16.2
+
+# ======= __END_OF_REQUIRES__ =======
+
+tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
+tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
+
+tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
+
+BUILD_TARGETS = $(tarball_target)
+
+PRODUCT_TARGETS = $(tarball)
+
+include ../../../build-system/core.mk
+
+
+$(tarball): $(tarball_target)
+
+$(tarball_target):
+ @echo ""
+ @echo "Creating $(tarball_name) tarball..."
+ @cd $(TOOLCHAINS_BASE_PATH) ; \
+ tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
+ @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
+ @touch $@
Index: products/POWER8-glibc/1.11.4/POWER8-TEST/.config
===================================================================
--- products/POWER8-glibc/1.11.4/POWER8-TEST/.config (nonexistent)
+++ products/POWER8-glibc/1.11.4/POWER8-TEST/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=ppc64-power8-linux-gnu
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/ppc64-POWER8-linux-glibc/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/POWER8-glibc/1.11.4/POWER8-TEST/32/.config
===================================================================
--- products/POWER8-glibc/1.11.4/POWER8-TEST/32/.config (nonexistent)
+++ products/POWER8-glibc/1.11.4/POWER8-TEST/32/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=ppc64-power8-linux-gnu
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/ppc64-POWER8-linux-glibc/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/POWER8-glibc/1.11.4/POWER8-TEST/32/build.sh
===================================================================
--- products/POWER8-glibc/1.11.4/POWER8-TEST/32/build.sh (nonexistent)
+++ products/POWER8-glibc/1.11.4/POWER8-TEST/32/build.sh (revision 76)
@@ -0,0 +1,20 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+ARCH_FLAGS=" -g -O3 -m32 -mcpu=power8 -mlong-double-128"
+
+
+$TARGET-gcc -m32 -g -gdwarf-2 -fomit-frame-pointer $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+$TARGET-gcc -m32 $ARCH_FLAGS $FPU_FLAGS -o main main.o
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/POWER8-glibc/1.11.4/POWER8-TEST/32/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/POWER8-glibc/1.11.4/POWER8-TEST/32/clean.sh
===================================================================
--- products/POWER8-glibc/1.11.4/POWER8-TEST/32/clean.sh (nonexistent)
+++ products/POWER8-glibc/1.11.4/POWER8-TEST/32/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/POWER8-glibc/1.11.4/POWER8-TEST/32/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/POWER8-glibc/1.11.4/POWER8-TEST/32/main.c
===================================================================
--- products/POWER8-glibc/1.11.4/POWER8-TEST/32/main.c (nonexistent)
+++ products/POWER8-glibc/1.11.4/POWER8-TEST/32/main.c (revision 76)
@@ -0,0 +1,17 @@
+
+#include <stdlib.h>
+#include <inttypes.h>
+
+int main()
+{
+ float d, f = 3.1415;
+
+ uint32_t a = 7, b = 3, c, r;
+
+ c = a / b;
+ r = a % b;
+
+ d = f * 2.1;
+
+ return( 0 );
+}
Index: products/POWER8-glibc/1.11.4/POWER8-TEST/32
===================================================================
--- products/POWER8-glibc/1.11.4/POWER8-TEST/32 (nonexistent)
+++ products/POWER8-glibc/1.11.4/POWER8-TEST/32 (revision 76)
Property changes on: products/POWER8-glibc/1.11.4/POWER8-TEST/32
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/POWER8-glibc/1.11.4/POWER8-TEST/build.sh
===================================================================
--- products/POWER8-glibc/1.11.4/POWER8-TEST/build.sh (nonexistent)
+++ products/POWER8-glibc/1.11.4/POWER8-TEST/build.sh (revision 76)
@@ -0,0 +1,20 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+ARCH_FLAGS=" -g -O3 -mcpu=power8 -mlong-double-128"
+
+
+$TARGET-gcc -g -gdwarf-2 -fomit-frame-pointer $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/POWER8-glibc/1.11.4/POWER8-TEST/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/POWER8-glibc/1.11.4/POWER8-TEST/clean.sh
===================================================================
--- products/POWER8-glibc/1.11.4/POWER8-TEST/clean.sh (nonexistent)
+++ products/POWER8-glibc/1.11.4/POWER8-TEST/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/POWER8-glibc/1.11.4/POWER8-TEST/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/POWER8-glibc/1.11.4/POWER8-TEST/main.c
===================================================================
--- products/POWER8-glibc/1.11.4/POWER8-TEST/main.c (nonexistent)
+++ products/POWER8-glibc/1.11.4/POWER8-TEST/main.c (revision 76)
@@ -0,0 +1,17 @@
+
+#include <stdlib.h>
+#include <inttypes.h>
+
+int main()
+{
+ float d, f = 3.1415;
+
+ uint32_t a = 7, b = 3, c, r;
+
+ c = a / b;
+ r = a % b;
+
+ d = f * 2.1;
+
+ return( 0 );
+}
Index: products/POWER8-glibc/1.11.4/POWER8-TEST
===================================================================
--- products/POWER8-glibc/1.11.4/POWER8-TEST (nonexistent)
+++ products/POWER8-glibc/1.11.4/POWER8-TEST (revision 76)
Property changes on: products/POWER8-glibc/1.11.4/POWER8-TEST
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/POWER8-glibc/1.11.4
===================================================================
--- products/POWER8-glibc/1.11.4 (nonexistent)
+++ products/POWER8-glibc/1.11.4 (revision 76)
Property changes on: products/POWER8-glibc/1.11.4
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/POWER8LE-glibc/1.11.3/POWER8LE-TEST/main.c
===================================================================
--- products/POWER8LE-glibc/1.11.3/POWER8LE-TEST/main.c (revision 75)
+++ products/POWER8LE-glibc/1.11.3/POWER8LE-TEST/main.c (nonexistent)
@@ -1,17 +0,0 @@
-
-#include <stdlib.h>
-#include <inttypes.h>
-
-int main()
-{
- float d, f = 3.1415;
-
- uint32_t a = 7, b = 3, c, r;
-
- c = a / b;
- r = a % b;
-
- d = f * 2.1;
-
- return( 0 );
-}
Index: products/POWER8LE-glibc/1.11.3/POWER8LE-TEST/build.sh
===================================================================
--- products/POWER8LE-glibc/1.11.3/POWER8LE-TEST/build.sh (revision 75)
+++ products/POWER8LE-glibc/1.11.3/POWER8LE-TEST/build.sh (nonexistent)
@@ -1,20 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-ARCH_FLAGS=" -g -O3 -mcpu=power8 -mlong-double-128"
-
-
-$TARGET-gcc -g -gdwarf-2 -fomit-frame-pointer $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/POWER8LE-glibc/1.11.3/POWER8LE-TEST/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/POWER8LE-glibc/1.11.3/POWER8LE-TEST/.config
===================================================================
--- products/POWER8LE-glibc/1.11.3/POWER8LE-TEST/.config (revision 75)
+++ products/POWER8LE-glibc/1.11.3/POWER8LE-TEST/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=ppc64le-power8-linux-gnu
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/ppc64le-POWER8-linux-glibc/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/POWER8LE-glibc/1.11.3/POWER8LE-TEST/clean.sh
===================================================================
--- products/POWER8LE-glibc/1.11.3/POWER8LE-TEST/clean.sh (revision 75)
+++ products/POWER8LE-glibc/1.11.3/POWER8LE-TEST/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/POWER8LE-glibc/1.11.3/POWER8LE-TEST/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/POWER8LE-glibc/1.11.3/POWER8LE-TEST
===================================================================
--- products/POWER8LE-glibc/1.11.3/POWER8LE-TEST (revision 75)
+++ products/POWER8LE-glibc/1.11.3/POWER8LE-TEST (nonexistent)
Property changes on: products/POWER8LE-glibc/1.11.3/POWER8LE-TEST
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/POWER8LE-glibc/1.11.3/Makefile
===================================================================
--- products/POWER8LE-glibc/1.11.3/Makefile (revision 75)
+++ products/POWER8LE-glibc/1.11.3/Makefile (nonexistent)
@@ -1,35 +0,0 @@
-
-
-COMPONENT_TARGETS = $(TOOLCHAIN_POWER8LE_GLIBC)
-
-export TOOLCHAIN_VERSION = 1.11.3
-
-include ../../../build-system/config.mk
-
-REQUIRES = core/gcc/14.2.0^full
-REQUIRES += tools/patchelf/0.18.0
-REQUIRES += core/gdb/15.1
-
-# ======= __END_OF_REQUIRES__ =======
-
-tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
-tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
-
-tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
-
-BUILD_TARGETS = $(tarball_target)
-
-PRODUCT_TARGETS = $(tarball)
-
-include ../../../build-system/core.mk
-
-
-$(tarball): $(tarball_target)
-
-$(tarball_target):
- @echo ""
- @echo "Creating $(tarball_name) tarball..."
- @cd $(TOOLCHAINS_BASE_PATH) ; \
- tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
- @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
- @touch $@
Index: products/POWER8LE-glibc/1.11.3
===================================================================
--- products/POWER8LE-glibc/1.11.3 (revision 75)
+++ products/POWER8LE-glibc/1.11.3 (nonexistent)
Property changes on: products/POWER8LE-glibc/1.11.3
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/POWER8LE-glibc/1.11.4/Makefile
===================================================================
--- products/POWER8LE-glibc/1.11.4/Makefile (nonexistent)
+++ products/POWER8LE-glibc/1.11.4/Makefile (revision 76)
@@ -0,0 +1,35 @@
+
+
+COMPONENT_TARGETS = $(TOOLCHAIN_POWER8LE_GLIBC)
+
+export TOOLCHAIN_VERSION = 1.11.4
+
+include ../../../build-system/config.mk
+
+REQUIRES = core/gcc/14.2.0^full
+REQUIRES += tools/patchelf/0.18.0
+REQUIRES += core/gdb/16.2
+
+# ======= __END_OF_REQUIRES__ =======
+
+tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
+tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
+
+tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
+
+BUILD_TARGETS = $(tarball_target)
+
+PRODUCT_TARGETS = $(tarball)
+
+include ../../../build-system/core.mk
+
+
+$(tarball): $(tarball_target)
+
+$(tarball_target):
+ @echo ""
+ @echo "Creating $(tarball_name) tarball..."
+ @cd $(TOOLCHAINS_BASE_PATH) ; \
+ tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
+ @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
+ @touch $@
Index: products/POWER8LE-glibc/1.11.4/POWER8LE-TEST/.config
===================================================================
--- products/POWER8LE-glibc/1.11.4/POWER8LE-TEST/.config (nonexistent)
+++ products/POWER8LE-glibc/1.11.4/POWER8LE-TEST/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=ppc64le-power8-linux-gnu
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/ppc64le-POWER8-linux-glibc/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/POWER8LE-glibc/1.11.4/POWER8LE-TEST/build.sh
===================================================================
--- products/POWER8LE-glibc/1.11.4/POWER8LE-TEST/build.sh (nonexistent)
+++ products/POWER8LE-glibc/1.11.4/POWER8LE-TEST/build.sh (revision 76)
@@ -0,0 +1,20 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+ARCH_FLAGS=" -g -O3 -mcpu=power8 -mlong-double-128"
+
+
+$TARGET-gcc -g -gdwarf-2 -fomit-frame-pointer $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/POWER8LE-glibc/1.11.4/POWER8LE-TEST/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/POWER8LE-glibc/1.11.4/POWER8LE-TEST/clean.sh
===================================================================
--- products/POWER8LE-glibc/1.11.4/POWER8LE-TEST/clean.sh (nonexistent)
+++ products/POWER8LE-glibc/1.11.4/POWER8LE-TEST/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/POWER8LE-glibc/1.11.4/POWER8LE-TEST/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/POWER8LE-glibc/1.11.4/POWER8LE-TEST/main.c
===================================================================
--- products/POWER8LE-glibc/1.11.4/POWER8LE-TEST/main.c (nonexistent)
+++ products/POWER8LE-glibc/1.11.4/POWER8LE-TEST/main.c (revision 76)
@@ -0,0 +1,17 @@
+
+#include <stdlib.h>
+#include <inttypes.h>
+
+int main()
+{
+ float d, f = 3.1415;
+
+ uint32_t a = 7, b = 3, c, r;
+
+ c = a / b;
+ r = a % b;
+
+ d = f * 2.1;
+
+ return( 0 );
+}
Index: products/POWER8LE-glibc/1.11.4/POWER8LE-TEST
===================================================================
--- products/POWER8LE-glibc/1.11.4/POWER8LE-TEST (nonexistent)
+++ products/POWER8LE-glibc/1.11.4/POWER8LE-TEST (revision 76)
Property changes on: products/POWER8LE-glibc/1.11.4/POWER8LE-TEST
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/POWER8LE-glibc/1.11.4
===================================================================
--- products/POWER8LE-glibc/1.11.4 (nonexistent)
+++ products/POWER8LE-glibc/1.11.4 (revision 76)
Property changes on: products/POWER8LE-glibc/1.11.4
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/POWER9-glibc/1.11.3/Makefile
===================================================================
--- products/POWER9-glibc/1.11.3/Makefile (revision 75)
+++ products/POWER9-glibc/1.11.3/Makefile (nonexistent)
@@ -1,35 +0,0 @@
-
-
-COMPONENT_TARGETS = $(TOOLCHAIN_POWER9_GLIBC)
-
-export TOOLCHAIN_VERSION = 1.11.3
-
-include ../../../build-system/config.mk
-
-REQUIRES = core/gcc/14.2.0^full
-REQUIRES += tools/patchelf/0.18.0
-REQUIRES += core/gdb/15.1
-
-# ======= __END_OF_REQUIRES__ =======
-
-tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
-tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
-
-tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
-
-BUILD_TARGETS = $(tarball_target)
-
-PRODUCT_TARGETS = $(tarball)
-
-include ../../../build-system/core.mk
-
-
-$(tarball): $(tarball_target)
-
-$(tarball_target):
- @echo ""
- @echo "Creating $(tarball_name) tarball..."
- @cd $(TOOLCHAINS_BASE_PATH) ; \
- tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
- @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
- @touch $@
Index: products/POWER9-glibc/1.11.3/POWER9-TEST/main.c
===================================================================
--- products/POWER9-glibc/1.11.3/POWER9-TEST/main.c (revision 75)
+++ products/POWER9-glibc/1.11.3/POWER9-TEST/main.c (nonexistent)
@@ -1,17 +0,0 @@
-
-#include <stdlib.h>
-#include <inttypes.h>
-
-int main()
-{
- float d, f = 3.1415;
-
- uint32_t a = 7, b = 3, c, r;
-
- c = a / b;
- r = a % b;
-
- d = f * 2.1;
-
- return( 0 );
-}
Index: products/POWER9-glibc/1.11.3/POWER9-TEST/build.sh
===================================================================
--- products/POWER9-glibc/1.11.3/POWER9-TEST/build.sh (revision 75)
+++ products/POWER9-glibc/1.11.3/POWER9-TEST/build.sh (nonexistent)
@@ -1,20 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-ARCH_FLAGS=" -g -O3 -mcpu=power9 -mlong-double-128"
-
-
-$TARGET-gcc -g -gdwarf-2 -fomit-frame-pointer $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/POWER9-glibc/1.11.3/POWER9-TEST/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/POWER9-glibc/1.11.3/POWER9-TEST/32/main.c
===================================================================
--- products/POWER9-glibc/1.11.3/POWER9-TEST/32/main.c (revision 75)
+++ products/POWER9-glibc/1.11.3/POWER9-TEST/32/main.c (nonexistent)
@@ -1,17 +0,0 @@
-
-#include <stdlib.h>
-#include <inttypes.h>
-
-int main()
-{
- float d, f = 3.1415;
-
- uint32_t a = 7, b = 3, c, r;
-
- c = a / b;
- r = a % b;
-
- d = f * 2.1;
-
- return( 0 );
-}
Index: products/POWER9-glibc/1.11.3/POWER9-TEST/32/build.sh
===================================================================
--- products/POWER9-glibc/1.11.3/POWER9-TEST/32/build.sh (revision 75)
+++ products/POWER9-glibc/1.11.3/POWER9-TEST/32/build.sh (nonexistent)
@@ -1,20 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-ARCH_FLAGS=" -g -O3 -m32 -mcpu=power9 -mlong-double-128"
-
-
-$TARGET-gcc -m32 -g -gdwarf-2 -fomit-frame-pointer $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-$TARGET-gcc -m32 $ARCH_FLAGS $FPU_FLAGS -o main main.o
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/POWER9-glibc/1.11.3/POWER9-TEST/32/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/POWER9-glibc/1.11.3/POWER9-TEST/32/.config
===================================================================
--- products/POWER9-glibc/1.11.3/POWER9-TEST/32/.config (revision 75)
+++ products/POWER9-glibc/1.11.3/POWER9-TEST/32/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=ppc64-power9-linux-gnu
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/ppc64-POWER9-linux-glibc/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/POWER9-glibc/1.11.3/POWER9-TEST/32/clean.sh
===================================================================
--- products/POWER9-glibc/1.11.3/POWER9-TEST/32/clean.sh (revision 75)
+++ products/POWER9-glibc/1.11.3/POWER9-TEST/32/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/POWER9-glibc/1.11.3/POWER9-TEST/32/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/POWER9-glibc/1.11.3/POWER9-TEST/32
===================================================================
--- products/POWER9-glibc/1.11.3/POWER9-TEST/32 (revision 75)
+++ products/POWER9-glibc/1.11.3/POWER9-TEST/32 (nonexistent)
Property changes on: products/POWER9-glibc/1.11.3/POWER9-TEST/32
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/POWER9-glibc/1.11.3/POWER9-TEST/.config
===================================================================
--- products/POWER9-glibc/1.11.3/POWER9-TEST/.config (revision 75)
+++ products/POWER9-glibc/1.11.3/POWER9-TEST/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=ppc64-power9-linux-gnu
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/ppc64-POWER9-linux-glibc/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/POWER9-glibc/1.11.3/POWER9-TEST/clean.sh
===================================================================
--- products/POWER9-glibc/1.11.3/POWER9-TEST/clean.sh (revision 75)
+++ products/POWER9-glibc/1.11.3/POWER9-TEST/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/POWER9-glibc/1.11.3/POWER9-TEST/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/POWER9-glibc/1.11.3/POWER9-TEST
===================================================================
--- products/POWER9-glibc/1.11.3/POWER9-TEST (revision 75)
+++ products/POWER9-glibc/1.11.3/POWER9-TEST (nonexistent)
Property changes on: products/POWER9-glibc/1.11.3/POWER9-TEST
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/POWER9-glibc/1.11.3
===================================================================
--- products/POWER9-glibc/1.11.3 (revision 75)
+++ products/POWER9-glibc/1.11.3 (nonexistent)
Property changes on: products/POWER9-glibc/1.11.3
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/POWER9-glibc/1.11.4/Makefile
===================================================================
--- products/POWER9-glibc/1.11.4/Makefile (nonexistent)
+++ products/POWER9-glibc/1.11.4/Makefile (revision 76)
@@ -0,0 +1,35 @@
+
+
+COMPONENT_TARGETS = $(TOOLCHAIN_POWER9_GLIBC)
+
+export TOOLCHAIN_VERSION = 1.11.4
+
+include ../../../build-system/config.mk
+
+REQUIRES = core/gcc/14.2.0^full
+REQUIRES += tools/patchelf/0.18.0
+REQUIRES += core/gdb/16.2
+
+# ======= __END_OF_REQUIRES__ =======
+
+tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
+tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
+
+tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
+
+BUILD_TARGETS = $(tarball_target)
+
+PRODUCT_TARGETS = $(tarball)
+
+include ../../../build-system/core.mk
+
+
+$(tarball): $(tarball_target)
+
+$(tarball_target):
+ @echo ""
+ @echo "Creating $(tarball_name) tarball..."
+ @cd $(TOOLCHAINS_BASE_PATH) ; \
+ tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
+ @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
+ @touch $@
Index: products/POWER9-glibc/1.11.4/POWER9-TEST/.config
===================================================================
--- products/POWER9-glibc/1.11.4/POWER9-TEST/.config (nonexistent)
+++ products/POWER9-glibc/1.11.4/POWER9-TEST/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=ppc64-power9-linux-gnu
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/ppc64-POWER9-linux-glibc/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/POWER9-glibc/1.11.4/POWER9-TEST/32/.config
===================================================================
--- products/POWER9-glibc/1.11.4/POWER9-TEST/32/.config (nonexistent)
+++ products/POWER9-glibc/1.11.4/POWER9-TEST/32/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=ppc64-power9-linux-gnu
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/ppc64-POWER9-linux-glibc/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/POWER9-glibc/1.11.4/POWER9-TEST/32/build.sh
===================================================================
--- products/POWER9-glibc/1.11.4/POWER9-TEST/32/build.sh (nonexistent)
+++ products/POWER9-glibc/1.11.4/POWER9-TEST/32/build.sh (revision 76)
@@ -0,0 +1,20 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+ARCH_FLAGS=" -g -O3 -m32 -mcpu=power9 -mlong-double-128"
+
+
+$TARGET-gcc -m32 -g -gdwarf-2 -fomit-frame-pointer $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+$TARGET-gcc -m32 $ARCH_FLAGS $FPU_FLAGS -o main main.o
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/POWER9-glibc/1.11.4/POWER9-TEST/32/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/POWER9-glibc/1.11.4/POWER9-TEST/32/clean.sh
===================================================================
--- products/POWER9-glibc/1.11.4/POWER9-TEST/32/clean.sh (nonexistent)
+++ products/POWER9-glibc/1.11.4/POWER9-TEST/32/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/POWER9-glibc/1.11.4/POWER9-TEST/32/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/POWER9-glibc/1.11.4/POWER9-TEST/32/main.c
===================================================================
--- products/POWER9-glibc/1.11.4/POWER9-TEST/32/main.c (nonexistent)
+++ products/POWER9-glibc/1.11.4/POWER9-TEST/32/main.c (revision 76)
@@ -0,0 +1,17 @@
+
+#include <stdlib.h>
+#include <inttypes.h>
+
+int main()
+{
+ float d, f = 3.1415;
+
+ uint32_t a = 7, b = 3, c, r;
+
+ c = a / b;
+ r = a % b;
+
+ d = f * 2.1;
+
+ return( 0 );
+}
Index: products/POWER9-glibc/1.11.4/POWER9-TEST/32
===================================================================
--- products/POWER9-glibc/1.11.4/POWER9-TEST/32 (nonexistent)
+++ products/POWER9-glibc/1.11.4/POWER9-TEST/32 (revision 76)
Property changes on: products/POWER9-glibc/1.11.4/POWER9-TEST/32
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/POWER9-glibc/1.11.4/POWER9-TEST/build.sh
===================================================================
--- products/POWER9-glibc/1.11.4/POWER9-TEST/build.sh (nonexistent)
+++ products/POWER9-glibc/1.11.4/POWER9-TEST/build.sh (revision 76)
@@ -0,0 +1,20 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+ARCH_FLAGS=" -g -O3 -mcpu=power9 -mlong-double-128"
+
+
+$TARGET-gcc -g -gdwarf-2 -fomit-frame-pointer $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/POWER9-glibc/1.11.4/POWER9-TEST/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/POWER9-glibc/1.11.4/POWER9-TEST/clean.sh
===================================================================
--- products/POWER9-glibc/1.11.4/POWER9-TEST/clean.sh (nonexistent)
+++ products/POWER9-glibc/1.11.4/POWER9-TEST/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/POWER9-glibc/1.11.4/POWER9-TEST/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/POWER9-glibc/1.11.4/POWER9-TEST/main.c
===================================================================
--- products/POWER9-glibc/1.11.4/POWER9-TEST/main.c (nonexistent)
+++ products/POWER9-glibc/1.11.4/POWER9-TEST/main.c (revision 76)
@@ -0,0 +1,17 @@
+
+#include <stdlib.h>
+#include <inttypes.h>
+
+int main()
+{
+ float d, f = 3.1415;
+
+ uint32_t a = 7, b = 3, c, r;
+
+ c = a / b;
+ r = a % b;
+
+ d = f * 2.1;
+
+ return( 0 );
+}
Index: products/POWER9-glibc/1.11.4/POWER9-TEST
===================================================================
--- products/POWER9-glibc/1.11.4/POWER9-TEST (nonexistent)
+++ products/POWER9-glibc/1.11.4/POWER9-TEST (revision 76)
Property changes on: products/POWER9-glibc/1.11.4/POWER9-TEST
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/POWER9-glibc/1.11.4
===================================================================
--- products/POWER9-glibc/1.11.4 (nonexistent)
+++ products/POWER9-glibc/1.11.4 (revision 76)
Property changes on: products/POWER9-glibc/1.11.4
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/POWER9LE-glibc/1.11.3/POWER9LE-TEST/main.c
===================================================================
--- products/POWER9LE-glibc/1.11.3/POWER9LE-TEST/main.c (revision 75)
+++ products/POWER9LE-glibc/1.11.3/POWER9LE-TEST/main.c (nonexistent)
@@ -1,17 +0,0 @@
-
-#include <stdlib.h>
-#include <inttypes.h>
-
-int main()
-{
- float d, f = 3.1415;
-
- uint32_t a = 7, b = 3, c, r;
-
- c = a / b;
- r = a % b;
-
- d = f * 2.1;
-
- return( 0 );
-}
Index: products/POWER9LE-glibc/1.11.3/POWER9LE-TEST/build.sh
===================================================================
--- products/POWER9LE-glibc/1.11.3/POWER9LE-TEST/build.sh (revision 75)
+++ products/POWER9LE-glibc/1.11.3/POWER9LE-TEST/build.sh (nonexistent)
@@ -1,20 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-ARCH_FLAGS=" -g -O3 -mcpu=power9 -mlong-double-128"
-
-
-$TARGET-gcc -g -gdwarf-2 -fomit-frame-pointer $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/POWER9LE-glibc/1.11.3/POWER9LE-TEST/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/POWER9LE-glibc/1.11.3/POWER9LE-TEST/.config
===================================================================
--- products/POWER9LE-glibc/1.11.3/POWER9LE-TEST/.config (revision 75)
+++ products/POWER9LE-glibc/1.11.3/POWER9LE-TEST/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=ppc64le-power9-linux-gnu
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/ppc64le-POWER9-linux-glibc/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/POWER9LE-glibc/1.11.3/POWER9LE-TEST/clean.sh
===================================================================
--- products/POWER9LE-glibc/1.11.3/POWER9LE-TEST/clean.sh (revision 75)
+++ products/POWER9LE-glibc/1.11.3/POWER9LE-TEST/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/POWER9LE-glibc/1.11.3/POWER9LE-TEST/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/POWER9LE-glibc/1.11.3/POWER9LE-TEST
===================================================================
--- products/POWER9LE-glibc/1.11.3/POWER9LE-TEST (revision 75)
+++ products/POWER9LE-glibc/1.11.3/POWER9LE-TEST (nonexistent)
Property changes on: products/POWER9LE-glibc/1.11.3/POWER9LE-TEST
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/POWER9LE-glibc/1.11.3/Makefile
===================================================================
--- products/POWER9LE-glibc/1.11.3/Makefile (revision 75)
+++ products/POWER9LE-glibc/1.11.3/Makefile (nonexistent)
@@ -1,35 +0,0 @@
-
-
-COMPONENT_TARGETS = $(TOOLCHAIN_POWER9LE_GLIBC)
-
-export TOOLCHAIN_VERSION = 1.11.3
-
-include ../../../build-system/config.mk
-
-REQUIRES = core/gcc/14.2.0^full
-REQUIRES += tools/patchelf/0.18.0
-REQUIRES += core/gdb/15.1
-
-# ======= __END_OF_REQUIRES__ =======
-
-tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
-tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
-
-tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
-
-BUILD_TARGETS = $(tarball_target)
-
-PRODUCT_TARGETS = $(tarball)
-
-include ../../../build-system/core.mk
-
-
-$(tarball): $(tarball_target)
-
-$(tarball_target):
- @echo ""
- @echo "Creating $(tarball_name) tarball..."
- @cd $(TOOLCHAINS_BASE_PATH) ; \
- tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
- @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
- @touch $@
Index: products/POWER9LE-glibc/1.11.3
===================================================================
--- products/POWER9LE-glibc/1.11.3 (revision 75)
+++ products/POWER9LE-glibc/1.11.3 (nonexistent)
Property changes on: products/POWER9LE-glibc/1.11.3
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/POWER9LE-glibc/1.11.4/Makefile
===================================================================
--- products/POWER9LE-glibc/1.11.4/Makefile (nonexistent)
+++ products/POWER9LE-glibc/1.11.4/Makefile (revision 76)
@@ -0,0 +1,35 @@
+
+
+COMPONENT_TARGETS = $(TOOLCHAIN_POWER9LE_GLIBC)
+
+export TOOLCHAIN_VERSION = 1.11.4
+
+include ../../../build-system/config.mk
+
+REQUIRES = core/gcc/14.2.0^full
+REQUIRES += tools/patchelf/0.18.0
+REQUIRES += core/gdb/16.2
+
+# ======= __END_OF_REQUIRES__ =======
+
+tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
+tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
+
+tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
+
+BUILD_TARGETS = $(tarball_target)
+
+PRODUCT_TARGETS = $(tarball)
+
+include ../../../build-system/core.mk
+
+
+$(tarball): $(tarball_target)
+
+$(tarball_target):
+ @echo ""
+ @echo "Creating $(tarball_name) tarball..."
+ @cd $(TOOLCHAINS_BASE_PATH) ; \
+ tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
+ @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
+ @touch $@
Index: products/POWER9LE-glibc/1.11.4/POWER9LE-TEST/.config
===================================================================
--- products/POWER9LE-glibc/1.11.4/POWER9LE-TEST/.config (nonexistent)
+++ products/POWER9LE-glibc/1.11.4/POWER9LE-TEST/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=ppc64le-power9-linux-gnu
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/ppc64le-POWER9-linux-glibc/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/POWER9LE-glibc/1.11.4/POWER9LE-TEST/build.sh
===================================================================
--- products/POWER9LE-glibc/1.11.4/POWER9LE-TEST/build.sh (nonexistent)
+++ products/POWER9LE-glibc/1.11.4/POWER9LE-TEST/build.sh (revision 76)
@@ -0,0 +1,20 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+ARCH_FLAGS=" -g -O3 -mcpu=power9 -mlong-double-128"
+
+
+$TARGET-gcc -g -gdwarf-2 -fomit-frame-pointer $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/POWER9LE-glibc/1.11.4/POWER9LE-TEST/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/POWER9LE-glibc/1.11.4/POWER9LE-TEST/clean.sh
===================================================================
--- products/POWER9LE-glibc/1.11.4/POWER9LE-TEST/clean.sh (nonexistent)
+++ products/POWER9LE-glibc/1.11.4/POWER9LE-TEST/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/POWER9LE-glibc/1.11.4/POWER9LE-TEST/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/POWER9LE-glibc/1.11.4/POWER9LE-TEST/main.c
===================================================================
--- products/POWER9LE-glibc/1.11.4/POWER9LE-TEST/main.c (nonexistent)
+++ products/POWER9LE-glibc/1.11.4/POWER9LE-TEST/main.c (revision 76)
@@ -0,0 +1,17 @@
+
+#include <stdlib.h>
+#include <inttypes.h>
+
+int main()
+{
+ float d, f = 3.1415;
+
+ uint32_t a = 7, b = 3, c, r;
+
+ c = a / b;
+ r = a % b;
+
+ d = f * 2.1;
+
+ return( 0 );
+}
Index: products/POWER9LE-glibc/1.11.4/POWER9LE-TEST
===================================================================
--- products/POWER9LE-glibc/1.11.4/POWER9LE-TEST (nonexistent)
+++ products/POWER9LE-glibc/1.11.4/POWER9LE-TEST (revision 76)
Property changes on: products/POWER9LE-glibc/1.11.4/POWER9LE-TEST
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/POWER9LE-glibc/1.11.4
===================================================================
--- products/POWER9LE-glibc/1.11.4 (nonexistent)
+++ products/POWER9LE-glibc/1.11.4 (revision 76)
Property changes on: products/POWER9LE-glibc/1.11.4
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/PPC8-glibc/1.11.3/PPC8-TEST/main.c
===================================================================
--- products/PPC8-glibc/1.11.3/PPC8-TEST/main.c (revision 75)
+++ products/PPC8-glibc/1.11.3/PPC8-TEST/main.c (nonexistent)
@@ -1,17 +0,0 @@
-
-#include <stdlib.h>
-#include <inttypes.h>
-
-int main()
-{
- float d, f = 3.1415;
-
- uint32_t a = 7, b = 3, c, r;
-
- c = a / b;
- r = a % b;
-
- d = f * 2.1;
-
- return( 0 );
-}
Index: products/PPC8-glibc/1.11.3/PPC8-TEST/build.sh
===================================================================
--- products/PPC8-glibc/1.11.3/PPC8-TEST/build.sh (revision 75)
+++ products/PPC8-glibc/1.11.3/PPC8-TEST/build.sh (nonexistent)
@@ -1,20 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-ARCH_FLAGS=" -g -O3 -mcpu=power8 -mlong-double-128"
-
-
-$TARGET-gcc -g -gdwarf-2 -fomit-frame-pointer $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/PPC8-glibc/1.11.3/PPC8-TEST/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/PPC8-glibc/1.11.3/PPC8-TEST/.config
===================================================================
--- products/PPC8-glibc/1.11.3/PPC8-TEST/.config (revision 75)
+++ products/PPC8-glibc/1.11.3/PPC8-TEST/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=ppc-power8-linux-gnu
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/ppc-POWER8-linux-glibc/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/PPC8-glibc/1.11.3/PPC8-TEST/clean.sh
===================================================================
--- products/PPC8-glibc/1.11.3/PPC8-TEST/clean.sh (revision 75)
+++ products/PPC8-glibc/1.11.3/PPC8-TEST/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/PPC8-glibc/1.11.3/PPC8-TEST/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/PPC8-glibc/1.11.3/Makefile
===================================================================
--- products/PPC8-glibc/1.11.3/Makefile (revision 75)
+++ products/PPC8-glibc/1.11.3/Makefile (nonexistent)
@@ -1,35 +0,0 @@
-
-
-COMPONENT_TARGETS = $(TOOLCHAIN_PPC8_GLIBC)
-
-export TOOLCHAIN_VERSION = 1.11.3
-
-include ../../../build-system/config.mk
-
-REQUIRES = core/gcc/14.2.0^full
-REQUIRES += tools/patchelf/0.18.0
-REQUIRES += core/gdb/15.1
-
-# ======= __END_OF_REQUIRES__ =======
-
-tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
-tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
-
-tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
-
-BUILD_TARGETS = $(tarball_target)
-
-PRODUCT_TARGETS = $(tarball)
-
-include ../../../build-system/core.mk
-
-
-$(tarball): $(tarball_target)
-
-$(tarball_target):
- @echo ""
- @echo "Creating $(tarball_name) tarball..."
- @cd $(TOOLCHAINS_BASE_PATH) ; \
- tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
- @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
- @touch $@
Index: products/PPC8-glibc/1.11.4/Makefile
===================================================================
--- products/PPC8-glibc/1.11.4/Makefile (nonexistent)
+++ products/PPC8-glibc/1.11.4/Makefile (revision 76)
@@ -0,0 +1,35 @@
+
+
+COMPONENT_TARGETS = $(TOOLCHAIN_PPC8_GLIBC)
+
+export TOOLCHAIN_VERSION = 1.11.4
+
+include ../../../build-system/config.mk
+
+REQUIRES = core/gcc/14.2.0^full
+REQUIRES += tools/patchelf/0.18.0
+REQUIRES += core/gdb/16.2
+
+# ======= __END_OF_REQUIRES__ =======
+
+tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
+tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
+
+tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
+
+BUILD_TARGETS = $(tarball_target)
+
+PRODUCT_TARGETS = $(tarball)
+
+include ../../../build-system/core.mk
+
+
+$(tarball): $(tarball_target)
+
+$(tarball_target):
+ @echo ""
+ @echo "Creating $(tarball_name) tarball..."
+ @cd $(TOOLCHAINS_BASE_PATH) ; \
+ tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
+ @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
+ @touch $@
Index: products/PPC8-glibc/1.11.4/PPC8-TEST/.config
===================================================================
--- products/PPC8-glibc/1.11.4/PPC8-TEST/.config (nonexistent)
+++ products/PPC8-glibc/1.11.4/PPC8-TEST/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=ppc-power8-linux-gnu
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/ppc-POWER8-linux-glibc/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/PPC8-glibc/1.11.4/PPC8-TEST/build.sh
===================================================================
--- products/PPC8-glibc/1.11.4/PPC8-TEST/build.sh (nonexistent)
+++ products/PPC8-glibc/1.11.4/PPC8-TEST/build.sh (revision 76)
@@ -0,0 +1,20 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+ARCH_FLAGS=" -g -O3 -mcpu=power8 -mlong-double-128"
+
+
+$TARGET-gcc -g -gdwarf-2 -fomit-frame-pointer $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/PPC8-glibc/1.11.4/PPC8-TEST/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/PPC8-glibc/1.11.4/PPC8-TEST/clean.sh
===================================================================
--- products/PPC8-glibc/1.11.4/PPC8-TEST/clean.sh (nonexistent)
+++ products/PPC8-glibc/1.11.4/PPC8-TEST/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/PPC8-glibc/1.11.4/PPC8-TEST/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/PPC8-glibc/1.11.4/PPC8-TEST/main.c
===================================================================
--- products/PPC8-glibc/1.11.4/PPC8-TEST/main.c (nonexistent)
+++ products/PPC8-glibc/1.11.4/PPC8-TEST/main.c (revision 76)
@@ -0,0 +1,17 @@
+
+#include <stdlib.h>
+#include <inttypes.h>
+
+int main()
+{
+ float d, f = 3.1415;
+
+ uint32_t a = 7, b = 3, c, r;
+
+ c = a / b;
+ r = a % b;
+
+ d = f * 2.1;
+
+ return( 0 );
+}
Index: products/PPC9-glibc/1.11.3/PPC9-TEST/main.c
===================================================================
--- products/PPC9-glibc/1.11.3/PPC9-TEST/main.c (revision 75)
+++ products/PPC9-glibc/1.11.3/PPC9-TEST/main.c (nonexistent)
@@ -1,17 +0,0 @@
-
-#include <stdlib.h>
-#include <inttypes.h>
-
-int main()
-{
- float d, f = 3.1415;
-
- uint32_t a = 7, b = 3, c, r;
-
- c = a / b;
- r = a % b;
-
- d = f * 2.1;
-
- return( 0 );
-}
Index: products/PPC9-glibc/1.11.3/PPC9-TEST/build.sh
===================================================================
--- products/PPC9-glibc/1.11.3/PPC9-TEST/build.sh (revision 75)
+++ products/PPC9-glibc/1.11.3/PPC9-TEST/build.sh (nonexistent)
@@ -1,20 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-ARCH_FLAGS=" -g -O3 -mcpu=power9 -mlong-double-128"
-
-
-$TARGET-gcc -g -gdwarf-2 -fomit-frame-pointer $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/PPC9-glibc/1.11.3/PPC9-TEST/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/PPC9-glibc/1.11.3/PPC9-TEST/.config
===================================================================
--- products/PPC9-glibc/1.11.3/PPC9-TEST/.config (revision 75)
+++ products/PPC9-glibc/1.11.3/PPC9-TEST/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=ppc-power9-linux-gnu
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/ppc-POWER9-linux-glibc/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/PPC9-glibc/1.11.3/PPC9-TEST/clean.sh
===================================================================
--- products/PPC9-glibc/1.11.3/PPC9-TEST/clean.sh (revision 75)
+++ products/PPC9-glibc/1.11.3/PPC9-TEST/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/PPC9-glibc/1.11.3/PPC9-TEST/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/PPC9-glibc/1.11.3/Makefile
===================================================================
--- products/PPC9-glibc/1.11.3/Makefile (revision 75)
+++ products/PPC9-glibc/1.11.3/Makefile (nonexistent)
@@ -1,35 +0,0 @@
-
-
-COMPONENT_TARGETS = $(TOOLCHAIN_PPC9_GLIBC)
-
-export TOOLCHAIN_VERSION = 1.11.3
-
-include ../../../build-system/config.mk
-
-REQUIRES = core/gcc/14.2.0^full
-REQUIRES += tools/patchelf/0.18.0
-REQUIRES += core/gdb/15.1
-
-# ======= __END_OF_REQUIRES__ =======
-
-tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
-tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
-
-tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
-
-BUILD_TARGETS = $(tarball_target)
-
-PRODUCT_TARGETS = $(tarball)
-
-include ../../../build-system/core.mk
-
-
-$(tarball): $(tarball_target)
-
-$(tarball_target):
- @echo ""
- @echo "Creating $(tarball_name) tarball..."
- @cd $(TOOLCHAINS_BASE_PATH) ; \
- tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
- @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
- @touch $@
Index: products/PPC9-glibc/1.11.4/Makefile
===================================================================
--- products/PPC9-glibc/1.11.4/Makefile (nonexistent)
+++ products/PPC9-glibc/1.11.4/Makefile (revision 76)
@@ -0,0 +1,35 @@
+
+
+COMPONENT_TARGETS = $(TOOLCHAIN_PPC9_GLIBC)
+
+export TOOLCHAIN_VERSION = 1.11.4
+
+include ../../../build-system/config.mk
+
+REQUIRES = core/gcc/14.2.0^full
+REQUIRES += tools/patchelf/0.18.0
+REQUIRES += core/gdb/16.2
+
+# ======= __END_OF_REQUIRES__ =======
+
+tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
+tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
+
+tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
+
+BUILD_TARGETS = $(tarball_target)
+
+PRODUCT_TARGETS = $(tarball)
+
+include ../../../build-system/core.mk
+
+
+$(tarball): $(tarball_target)
+
+$(tarball_target):
+ @echo ""
+ @echo "Creating $(tarball_name) tarball..."
+ @cd $(TOOLCHAINS_BASE_PATH) ; \
+ tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
+ @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
+ @touch $@
Index: products/PPC9-glibc/1.11.4/PPC9-TEST/.config
===================================================================
--- products/PPC9-glibc/1.11.4/PPC9-TEST/.config (nonexistent)
+++ products/PPC9-glibc/1.11.4/PPC9-TEST/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=ppc-power9-linux-gnu
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/ppc-POWER9-linux-glibc/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/PPC9-glibc/1.11.4/PPC9-TEST/build.sh
===================================================================
--- products/PPC9-glibc/1.11.4/PPC9-TEST/build.sh (nonexistent)
+++ products/PPC9-glibc/1.11.4/PPC9-TEST/build.sh (revision 76)
@@ -0,0 +1,20 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+ARCH_FLAGS=" -g -O3 -mcpu=power9 -mlong-double-128"
+
+
+$TARGET-gcc -g -gdwarf-2 -fomit-frame-pointer $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/PPC9-glibc/1.11.4/PPC9-TEST/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/PPC9-glibc/1.11.4/PPC9-TEST/clean.sh
===================================================================
--- products/PPC9-glibc/1.11.4/PPC9-TEST/clean.sh (nonexistent)
+++ products/PPC9-glibc/1.11.4/PPC9-TEST/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/PPC9-glibc/1.11.4/PPC9-TEST/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/PPC9-glibc/1.11.4/PPC9-TEST/main.c
===================================================================
--- products/PPC9-glibc/1.11.4/PPC9-TEST/main.c (nonexistent)
+++ products/PPC9-glibc/1.11.4/PPC9-TEST/main.c (revision 76)
@@ -0,0 +1,17 @@
+
+#include <stdlib.h>
+#include <inttypes.h>
+
+int main()
+{
+ float d, f = 3.1415;
+
+ uint32_t a = 7, b = 3, c, r;
+
+ c = a / b;
+ r = a % b;
+
+ d = f * 2.1;
+
+ return( 0 );
+}
Index: products/RISCV64-glibc/1.11.3/rv64gc-TEST/main.c
===================================================================
--- products/RISCV64-glibc/1.11.3/rv64gc-TEST/main.c (revision 75)
+++ products/RISCV64-glibc/1.11.3/rv64gc-TEST/main.c (nonexistent)
@@ -1,18 +0,0 @@
-
-#include <stdlib.h>
-#include <inttypes.h>
-
-int main()
-{
- float f = 3.1415;
- double g = 5.0, h = 2.0, d;
- uint32_t a = 7, b = 3, c, r;
-
- d = g * h;
- c = a / b;
- r = a % b;
-
- d += f * 2.1;
-
- return( 0 );
-}
Index: products/RISCV64-glibc/1.11.3/rv64gc-TEST/build.sh
===================================================================
--- products/RISCV64-glibc/1.11.3/rv64gc-TEST/build.sh (revision 75)
+++ products/RISCV64-glibc/1.11.3/rv64gc-TEST/build.sh (nonexistent)
@@ -1,20 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-ARCH_OPTIONS=" -g -O3 -march=rv64gc -misa-spec=2.2 -mabi=lp64d -mcmodel=medany"
-
-
-$TARGET-gcc -g -gdwarf-2 -fomit-frame-pointer ${ARCH_FLAGS} -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-$TARGET-gcc ${ARCH_FLAGS} -o main main.o
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/RISCV64-glibc/1.11.3/rv64gc-TEST/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/RISCV64-glibc/1.11.3/rv64gc-TEST/.config
===================================================================
--- products/RISCV64-glibc/1.11.3/rv64gc-TEST/.config (revision 75)
+++ products/RISCV64-glibc/1.11.3/rv64gc-TEST/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=riscv64-rv64gc-linux-gnu
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/riscv64-RV64GC-linux-glibc/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/RISCV64-glibc/1.11.3/rv64gc-TEST/clean.sh
===================================================================
--- products/RISCV64-glibc/1.11.3/rv64gc-TEST/clean.sh (revision 75)
+++ products/RISCV64-glibc/1.11.3/rv64gc-TEST/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/RISCV64-glibc/1.11.3/rv64gc-TEST/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/RISCV64-glibc/1.11.3/Makefile
===================================================================
--- products/RISCV64-glibc/1.11.3/Makefile (revision 75)
+++ products/RISCV64-glibc/1.11.3/Makefile (nonexistent)
@@ -1,35 +0,0 @@
-
-
-COMPONENT_TARGETS = $(TOOLCHAIN_RISCV64_GLIBC)
-
-export TOOLCHAIN_VERSION = 1.11.3
-
-include ../../../build-system/config.mk
-
-REQUIRES = core/gcc/14.2.0^full
-REQUIRES += tools/patchelf/0.18.0
-REQUIRES += core/gdb/15.1
-
-# ======= __END_OF_REQUIRES__ =======
-
-tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
-tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
-
-tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
-
-BUILD_TARGETS = $(tarball_target)
-
-PRODUCT_TARGETS = $(tarball)
-
-include ../../../build-system/core.mk
-
-
-$(tarball): $(tarball_target)
-
-$(tarball_target):
- @echo ""
- @echo "Creating $(tarball_name) tarball..."
- @cd $(TOOLCHAINS_BASE_PATH) ; \
- tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
- @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
- @touch $@
Index: products/RISCV64-glibc/1.11.3
===================================================================
--- products/RISCV64-glibc/1.11.3 (revision 75)
+++ products/RISCV64-glibc/1.11.3 (nonexistent)
Property changes on: products/RISCV64-glibc/1.11.3
___________________________________________________________________
Deleted: svn:ignore
## -1,81 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.rk358x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/RISCV64-glibc/1.11.4/Makefile
===================================================================
--- products/RISCV64-glibc/1.11.4/Makefile (nonexistent)
+++ products/RISCV64-glibc/1.11.4/Makefile (revision 76)
@@ -0,0 +1,35 @@
+
+
+COMPONENT_TARGETS = $(TOOLCHAIN_RISCV64_GLIBC)
+
+export TOOLCHAIN_VERSION = 1.11.4
+
+include ../../../build-system/config.mk
+
+REQUIRES = core/gcc/14.2.0^full
+REQUIRES += tools/patchelf/0.18.0
+REQUIRES += core/gdb/16.2
+
+# ======= __END_OF_REQUIRES__ =======
+
+tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
+tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
+
+tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
+
+BUILD_TARGETS = $(tarball_target)
+
+PRODUCT_TARGETS = $(tarball)
+
+include ../../../build-system/core.mk
+
+
+$(tarball): $(tarball_target)
+
+$(tarball_target):
+ @echo ""
+ @echo "Creating $(tarball_name) tarball..."
+ @cd $(TOOLCHAINS_BASE_PATH) ; \
+ tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
+ @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
+ @touch $@
Index: products/RISCV64-glibc/1.11.4/rv64gc-TEST/.config
===================================================================
--- products/RISCV64-glibc/1.11.4/rv64gc-TEST/.config (nonexistent)
+++ products/RISCV64-glibc/1.11.4/rv64gc-TEST/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=riscv64-rv64gc-linux-gnu
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/riscv64-RV64GC-linux-glibc/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/RISCV64-glibc/1.11.4/rv64gc-TEST/build.sh
===================================================================
--- products/RISCV64-glibc/1.11.4/rv64gc-TEST/build.sh (nonexistent)
+++ products/RISCV64-glibc/1.11.4/rv64gc-TEST/build.sh (revision 76)
@@ -0,0 +1,20 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+ARCH_OPTIONS=" -g -O3 -march=rv64gc -misa-spec=2.2 -mabi=lp64d -mcmodel=medany"
+
+
+$TARGET-gcc -g -gdwarf-2 -fomit-frame-pointer ${ARCH_FLAGS} -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+$TARGET-gcc ${ARCH_FLAGS} -o main main.o
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/RISCV64-glibc/1.11.4/rv64gc-TEST/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/RISCV64-glibc/1.11.4/rv64gc-TEST/clean.sh
===================================================================
--- products/RISCV64-glibc/1.11.4/rv64gc-TEST/clean.sh (nonexistent)
+++ products/RISCV64-glibc/1.11.4/rv64gc-TEST/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/RISCV64-glibc/1.11.4/rv64gc-TEST/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/RISCV64-glibc/1.11.4/rv64gc-TEST/main.c
===================================================================
--- products/RISCV64-glibc/1.11.4/rv64gc-TEST/main.c (nonexistent)
+++ products/RISCV64-glibc/1.11.4/rv64gc-TEST/main.c (revision 76)
@@ -0,0 +1,18 @@
+
+#include <stdlib.h>
+#include <inttypes.h>
+
+int main()
+{
+ float f = 3.1415;
+ double g = 5.0, h = 2.0, d;
+ uint32_t a = 7, b = 3, c, r;
+
+ d = g * h;
+ c = a / b;
+ r = a % b;
+
+ d += f * 2.1;
+
+ return( 0 );
+}
Index: products/RISCV64-glibc/1.11.4
===================================================================
--- products/RISCV64-glibc/1.11.4 (nonexistent)
+++ products/RISCV64-glibc/1.11.4 (revision 76)
Property changes on: products/RISCV64-glibc/1.11.4
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,81 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.rk358x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/RISCV64-newlib/1.11.3/rv32imac-TEST/main.c
===================================================================
--- products/RISCV64-newlib/1.11.3/rv32imac-TEST/main.c (revision 75)
+++ products/RISCV64-newlib/1.11.3/rv32imac-TEST/main.c (nonexistent)
@@ -1,18 +0,0 @@
-
-#include <stdlib.h>
-#include <inttypes.h>
-
-int main()
-{
- uint32_t a = 7, b = 3, c, r;
- float pi = 3.1415, e = 2.71, f;
- double g = 5.0, h = 2.0, d;
-
- d = g * h;
- c = a / b;
- r = a % b;
-
- f = pi * e;
-
- return( 0 );
-}
Index: products/RISCV64-newlib/1.11.3/rv32imac-TEST/build.sh
===================================================================
--- products/RISCV64-newlib/1.11.3/rv32imac-TEST/build.sh (revision 75)
+++ products/RISCV64-newlib/1.11.3/rv32imac-TEST/build.sh (nonexistent)
@@ -1,19 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-ARCH_OPTIONS=" -march=rv32imac -misa-spec=2.2 -mabi=ilp32"
-
-$TARGET-gcc -g -gdwarf-2 -fomit-frame-pointer ${ARCH_OPTIONS} -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-$TARGET-gcc ${ARCH_OPTIONS} -o main main.o
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/RISCV64-newlib/1.11.3/rv32imac-TEST/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/RISCV64-newlib/1.11.3/rv32imac-TEST/.config
===================================================================
--- products/RISCV64-newlib/1.11.3/rv32imac-TEST/.config (revision 75)
+++ products/RISCV64-newlib/1.11.3/rv32imac-TEST/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=riscv64-none-elf
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/riscv64-NONE-elf-newlib/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/RISCV64-newlib/1.11.3/rv32imac-TEST/clean.sh
===================================================================
--- products/RISCV64-newlib/1.11.3/rv32imac-TEST/clean.sh (revision 75)
+++ products/RISCV64-newlib/1.11.3/rv32imac-TEST/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/RISCV64-newlib/1.11.3/rv32imac-TEST/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/RISCV64-newlib/1.11.3/rv32imafc-TEST/main.c
===================================================================
--- products/RISCV64-newlib/1.11.3/rv32imafc-TEST/main.c (revision 75)
+++ products/RISCV64-newlib/1.11.3/rv32imafc-TEST/main.c (nonexistent)
@@ -1,18 +0,0 @@
-
-#include <stdlib.h>
-#include <inttypes.h>
-
-int main()
-{
- uint32_t a = 7, b = 3, c, r;
- float pi = 3.1415, e = 2.71, f;
- double g = 5.0, h = 2.0, d;
-
- d = g * h;
- c = a / b;
- r = a % b;
-
- f = pi * e;
-
- return( 0 );
-}
Index: products/RISCV64-newlib/1.11.3/rv32imafc-TEST/build.sh
===================================================================
--- products/RISCV64-newlib/1.11.3/rv32imafc-TEST/build.sh (revision 75)
+++ products/RISCV64-newlib/1.11.3/rv32imafc-TEST/build.sh (nonexistent)
@@ -1,19 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-ARCH_OPTIONS=" -march=rv32imafc_zicsr -misa-spec=2.2 -mabi=ilp32f"
-
-$TARGET-gcc -g -gdwarf-2 -fomit-frame-pointer ${ARCH_OPTIONS} -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-$TARGET-gcc ${ARCH_OPTIONS} -o main main.o
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/RISCV64-newlib/1.11.3/rv32imafc-TEST/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/RISCV64-newlib/1.11.3/rv32imafc-TEST/.config
===================================================================
--- products/RISCV64-newlib/1.11.3/rv32imafc-TEST/.config (revision 75)
+++ products/RISCV64-newlib/1.11.3/rv32imafc-TEST/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=riscv64-none-elf
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/riscv64-NONE-elf-newlib/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/RISCV64-newlib/1.11.3/rv32imafc-TEST/clean.sh
===================================================================
--- products/RISCV64-newlib/1.11.3/rv32imafc-TEST/clean.sh (revision 75)
+++ products/RISCV64-newlib/1.11.3/rv32imafc-TEST/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/RISCV64-newlib/1.11.3/rv32imafc-TEST/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/RISCV64-newlib/1.11.3/rv64imafdc-TEST/main.c
===================================================================
--- products/RISCV64-newlib/1.11.3/rv64imafdc-TEST/main.c (revision 75)
+++ products/RISCV64-newlib/1.11.3/rv64imafdc-TEST/main.c (nonexistent)
@@ -1,18 +0,0 @@
-
-#include <stdlib.h>
-#include <inttypes.h>
-
-int main()
-{
- uint32_t a = 7, b = 3, c, r;
- float pi = 3.1415, e = 2.71, f;
- double g = 5.0, h = 2.0, d;
-
- d = g * h;
- c = a / b;
- r = a % b;
-
- f = pi * e;
-
- return( 0 );
-}
Index: products/RISCV64-newlib/1.11.3/rv64imafdc-TEST/build.sh
===================================================================
--- products/RISCV64-newlib/1.11.3/rv64imafdc-TEST/build.sh (revision 75)
+++ products/RISCV64-newlib/1.11.3/rv64imafdc-TEST/build.sh (nonexistent)
@@ -1,19 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-ARCH_OPTIONS=" -march=rv64imafdc_zicsr -misa-spec=2.2 -mabi=lp64d"
-
-$TARGET-gcc -g -gdwarf-2 -fomit-frame-pointer ${ARCH_OPTIONS} -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-$TARGET-gcc ${ARCH_OPTIONS} -o main main.o
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/RISCV64-newlib/1.11.3/rv64imafdc-TEST/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/RISCV64-newlib/1.11.3/rv64imafdc-TEST/.config
===================================================================
--- products/RISCV64-newlib/1.11.3/rv64imafdc-TEST/.config (revision 75)
+++ products/RISCV64-newlib/1.11.3/rv64imafdc-TEST/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=riscv64-none-elf
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/riscv64-NONE-elf-newlib/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/RISCV64-newlib/1.11.3/rv64imafdc-TEST/clean.sh
===================================================================
--- products/RISCV64-newlib/1.11.3/rv64imafdc-TEST/clean.sh (revision 75)
+++ products/RISCV64-newlib/1.11.3/rv64imafdc-TEST/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/RISCV64-newlib/1.11.3/rv64imafdc-TEST/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/RISCV64-newlib/1.11.3/Makefile
===================================================================
--- products/RISCV64-newlib/1.11.3/Makefile (revision 75)
+++ products/RISCV64-newlib/1.11.3/Makefile (nonexistent)
@@ -1,34 +0,0 @@
-
-
-COMPONENT_TARGETS = $(TOOLCHAIN_RISCV64_NEWLIB)
-
-export TOOLCHAIN_VERSION = 1.11.3
-
-include ../../../build-system/config.mk
-
-REQUIRES = core/gcc/14.2.0^full
-REQUIRES += core/gdb/15.1
-
-# ======= __END_OF_REQUIRES__ =======
-
-tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
-tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
-
-tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
-
-BUILD_TARGETS = $(tarball_target)
-
-PRODUCT_TARGETS = $(tarball)
-
-include ../../../build-system/core.mk
-
-
-$(tarball): $(tarball_target)
-
-$(tarball_target): $(build_requires)
- @echo ""
- @echo "Creating $(tarball_name) tarball..."
- @cd $(TOOLCHAINS_BASE_PATH) ; \
- tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
- @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
- @touch $@
Index: products/RISCV64-newlib/1.11.3
===================================================================
--- products/RISCV64-newlib/1.11.3 (revision 75)
+++ products/RISCV64-newlib/1.11.3 (nonexistent)
Property changes on: products/RISCV64-newlib/1.11.3
___________________________________________________________________
Deleted: svn:ignore
## -1,81 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.rk358x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/RISCV64-newlib/1.11.4/Makefile
===================================================================
--- products/RISCV64-newlib/1.11.4/Makefile (nonexistent)
+++ products/RISCV64-newlib/1.11.4/Makefile (revision 76)
@@ -0,0 +1,34 @@
+
+
+COMPONENT_TARGETS = $(TOOLCHAIN_RISCV64_NEWLIB)
+
+export TOOLCHAIN_VERSION = 1.11.4
+
+include ../../../build-system/config.mk
+
+REQUIRES = core/gcc/14.2.0^full
+REQUIRES += core/gdb/16.2
+
+# ======= __END_OF_REQUIRES__ =======
+
+tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
+tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
+
+tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
+
+BUILD_TARGETS = $(tarball_target)
+
+PRODUCT_TARGETS = $(tarball)
+
+include ../../../build-system/core.mk
+
+
+$(tarball): $(tarball_target)
+
+$(tarball_target): $(build_requires)
+ @echo ""
+ @echo "Creating $(tarball_name) tarball..."
+ @cd $(TOOLCHAINS_BASE_PATH) ; \
+ tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
+ @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
+ @touch $@
Index: products/RISCV64-newlib/1.11.4/rv32imac-TEST/.config
===================================================================
--- products/RISCV64-newlib/1.11.4/rv32imac-TEST/.config (nonexistent)
+++ products/RISCV64-newlib/1.11.4/rv32imac-TEST/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=riscv64-none-elf
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/riscv64-NONE-elf-newlib/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/RISCV64-newlib/1.11.4/rv32imac-TEST/build.sh
===================================================================
--- products/RISCV64-newlib/1.11.4/rv32imac-TEST/build.sh (nonexistent)
+++ products/RISCV64-newlib/1.11.4/rv32imac-TEST/build.sh (revision 76)
@@ -0,0 +1,19 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+ARCH_OPTIONS=" -march=rv32imac -misa-spec=2.2 -mabi=ilp32"
+
+$TARGET-gcc -g -gdwarf-2 -fomit-frame-pointer ${ARCH_OPTIONS} -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+$TARGET-gcc ${ARCH_OPTIONS} -o main main.o
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/RISCV64-newlib/1.11.4/rv32imac-TEST/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/RISCV64-newlib/1.11.4/rv32imac-TEST/clean.sh
===================================================================
--- products/RISCV64-newlib/1.11.4/rv32imac-TEST/clean.sh (nonexistent)
+++ products/RISCV64-newlib/1.11.4/rv32imac-TEST/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/RISCV64-newlib/1.11.4/rv32imac-TEST/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/RISCV64-newlib/1.11.4/rv32imac-TEST/main.c
===================================================================
--- products/RISCV64-newlib/1.11.4/rv32imac-TEST/main.c (nonexistent)
+++ products/RISCV64-newlib/1.11.4/rv32imac-TEST/main.c (revision 76)
@@ -0,0 +1,18 @@
+
+#include <stdlib.h>
+#include <inttypes.h>
+
+int main()
+{
+ uint32_t a = 7, b = 3, c, r;
+ float pi = 3.1415, e = 2.71, f;
+ double g = 5.0, h = 2.0, d;
+
+ d = g * h;
+ c = a / b;
+ r = a % b;
+
+ f = pi * e;
+
+ return( 0 );
+}
Index: products/RISCV64-newlib/1.11.4/rv32imafc-TEST/.config
===================================================================
--- products/RISCV64-newlib/1.11.4/rv32imafc-TEST/.config (nonexistent)
+++ products/RISCV64-newlib/1.11.4/rv32imafc-TEST/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=riscv64-none-elf
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/riscv64-NONE-elf-newlib/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/RISCV64-newlib/1.11.4/rv32imafc-TEST/build.sh
===================================================================
--- products/RISCV64-newlib/1.11.4/rv32imafc-TEST/build.sh (nonexistent)
+++ products/RISCV64-newlib/1.11.4/rv32imafc-TEST/build.sh (revision 76)
@@ -0,0 +1,19 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+ARCH_OPTIONS=" -march=rv32imafc_zicsr -misa-spec=2.2 -mabi=ilp32f"
+
+$TARGET-gcc -g -gdwarf-2 -fomit-frame-pointer ${ARCH_OPTIONS} -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+$TARGET-gcc ${ARCH_OPTIONS} -o main main.o
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/RISCV64-newlib/1.11.4/rv32imafc-TEST/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/RISCV64-newlib/1.11.4/rv32imafc-TEST/clean.sh
===================================================================
--- products/RISCV64-newlib/1.11.4/rv32imafc-TEST/clean.sh (nonexistent)
+++ products/RISCV64-newlib/1.11.4/rv32imafc-TEST/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/RISCV64-newlib/1.11.4/rv32imafc-TEST/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/RISCV64-newlib/1.11.4/rv32imafc-TEST/main.c
===================================================================
--- products/RISCV64-newlib/1.11.4/rv32imafc-TEST/main.c (nonexistent)
+++ products/RISCV64-newlib/1.11.4/rv32imafc-TEST/main.c (revision 76)
@@ -0,0 +1,18 @@
+
+#include <stdlib.h>
+#include <inttypes.h>
+
+int main()
+{
+ uint32_t a = 7, b = 3, c, r;
+ float pi = 3.1415, e = 2.71, f;
+ double g = 5.0, h = 2.0, d;
+
+ d = g * h;
+ c = a / b;
+ r = a % b;
+
+ f = pi * e;
+
+ return( 0 );
+}
Index: products/RISCV64-newlib/1.11.4/rv64imafdc-TEST/.config
===================================================================
--- products/RISCV64-newlib/1.11.4/rv64imafdc-TEST/.config (nonexistent)
+++ products/RISCV64-newlib/1.11.4/rv64imafdc-TEST/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=riscv64-none-elf
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/riscv64-NONE-elf-newlib/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/RISCV64-newlib/1.11.4/rv64imafdc-TEST/build.sh
===================================================================
--- products/RISCV64-newlib/1.11.4/rv64imafdc-TEST/build.sh (nonexistent)
+++ products/RISCV64-newlib/1.11.4/rv64imafdc-TEST/build.sh (revision 76)
@@ -0,0 +1,19 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+ARCH_OPTIONS=" -march=rv64imafdc_zicsr -misa-spec=2.2 -mabi=lp64d"
+
+$TARGET-gcc -g -gdwarf-2 -fomit-frame-pointer ${ARCH_OPTIONS} -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+$TARGET-gcc ${ARCH_OPTIONS} -o main main.o
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/RISCV64-newlib/1.11.4/rv64imafdc-TEST/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/RISCV64-newlib/1.11.4/rv64imafdc-TEST/clean.sh
===================================================================
--- products/RISCV64-newlib/1.11.4/rv64imafdc-TEST/clean.sh (nonexistent)
+++ products/RISCV64-newlib/1.11.4/rv64imafdc-TEST/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/RISCV64-newlib/1.11.4/rv64imafdc-TEST/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/RISCV64-newlib/1.11.4/rv64imafdc-TEST/main.c
===================================================================
--- products/RISCV64-newlib/1.11.4/rv64imafdc-TEST/main.c (nonexistent)
+++ products/RISCV64-newlib/1.11.4/rv64imafdc-TEST/main.c (revision 76)
@@ -0,0 +1,18 @@
+
+#include <stdlib.h>
+#include <inttypes.h>
+
+int main()
+{
+ uint32_t a = 7, b = 3, c, r;
+ float pi = 3.1415, e = 2.71, f;
+ double g = 5.0, h = 2.0, d;
+
+ d = g * h;
+ c = a / b;
+ r = a % b;
+
+ f = pi * e;
+
+ return( 0 );
+}
Index: products/RISCV64-newlib/1.11.4
===================================================================
--- products/RISCV64-newlib/1.11.4 (nonexistent)
+++ products/RISCV64-newlib/1.11.4 (revision 76)
Property changes on: products/RISCV64-newlib/1.11.4
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,81 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.rk358x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/RK328X-glibc/1.11.3/RK328X-TEST-vfp/main.c
===================================================================
--- products/RK328X-glibc/1.11.3/RK328X-TEST-vfp/main.c (revision 75)
+++ products/RK328X-glibc/1.11.3/RK328X-TEST-vfp/main.c (nonexistent)
@@ -1,17 +0,0 @@
-
-#include <stdlib.h>
-#include <inttypes.h>
-
-int main()
-{
- float d, f = 3.1415;
-
- uint32_t a = 7, b = 3, c, r;
-
- c = a / b;
- r = a % b;
-
- d = f * 2.1;
-
- return( 0 );
-}
Index: products/RK328X-glibc/1.11.3/RK328X-TEST-vfp/build.sh
===================================================================
--- products/RK328X-glibc/1.11.3/RK328X-TEST-vfp/build.sh (revision 75)
+++ products/RK328X-glibc/1.11.3/RK328X-TEST-vfp/build.sh (nonexistent)
@@ -1,21 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-ARCH_FLAGS=" -march=armv7ve -mtune=cortex-a17"
-
-FPU_FLAGS=" -mfloat-abi=hard -mfpu=neon-vfpv4 -ftree-vectorize -fomit-frame-pointer -ffast-math"
-
-$TARGET-gcc -g -O3 -gdwarf-2 -fomit-frame-pointer $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/RK328X-glibc/1.11.3/RK328X-TEST-vfp/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/RK328X-glibc/1.11.3/RK328X-TEST-vfp/.config
===================================================================
--- products/RK328X-glibc/1.11.3/RK328X-TEST-vfp/.config (revision 75)
+++ products/RK328X-glibc/1.11.3/RK328X-TEST-vfp/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=arm-rk328x-linux-gnueabihf
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/arm-RK328X-linux-glibc/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/RK328X-glibc/1.11.3/RK328X-TEST-vfp/clean.sh
===================================================================
--- products/RK328X-glibc/1.11.3/RK328X-TEST-vfp/clean.sh (revision 75)
+++ products/RK328X-glibc/1.11.3/RK328X-TEST-vfp/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/RK328X-glibc/1.11.3/RK328X-TEST-vfp/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/RK328X-glibc/1.11.3/RK328X-TEST-vfp
===================================================================
--- products/RK328X-glibc/1.11.3/RK328X-TEST-vfp (revision 75)
+++ products/RK328X-glibc/1.11.3/RK328X-TEST-vfp (nonexistent)
Property changes on: products/RK328X-glibc/1.11.3/RK328X-TEST-vfp
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/RK328X-glibc/1.11.3/Makefile
===================================================================
--- products/RK328X-glibc/1.11.3/Makefile (revision 75)
+++ products/RK328X-glibc/1.11.3/Makefile (nonexistent)
@@ -1,35 +0,0 @@
-
-
-COMPONENT_TARGETS = $(TOOLCHAIN_RK328X_GLIBC)
-
-export TOOLCHAIN_VERSION = 1.11.3
-
-include ../../../build-system/config.mk
-
-REQUIRES = core/gcc/14.2.0^full
-REQUIRES += tools/patchelf/0.18.0
-REQUIRES += core/gdb/15.1
-
-# ======= __END_OF_REQUIRES__ =======
-
-tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
-tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
-
-tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
-
-BUILD_TARGETS = $(tarball_target)
-
-PRODUCT_TARGETS = $(tarball)
-
-include ../../../build-system/core.mk
-
-
-$(tarball): $(tarball_target)
-
-$(tarball_target):
- @echo ""
- @echo "Creating $(tarball_name) tarball..."
- @cd $(TOOLCHAINS_BASE_PATH) ; \
- tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
- @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
- @touch $@
Index: products/RK328X-glibc/1.11.3
===================================================================
--- products/RK328X-glibc/1.11.3 (revision 75)
+++ products/RK328X-glibc/1.11.3 (nonexistent)
Property changes on: products/RK328X-glibc/1.11.3
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/RK328X-glibc/1.11.4/Makefile
===================================================================
--- products/RK328X-glibc/1.11.4/Makefile (nonexistent)
+++ products/RK328X-glibc/1.11.4/Makefile (revision 76)
@@ -0,0 +1,35 @@
+
+
+COMPONENT_TARGETS = $(TOOLCHAIN_RK328X_GLIBC)
+
+export TOOLCHAIN_VERSION = 1.11.4
+
+include ../../../build-system/config.mk
+
+REQUIRES = core/gcc/14.2.0^full
+REQUIRES += tools/patchelf/0.18.0
+REQUIRES += core/gdb/16.2
+
+# ======= __END_OF_REQUIRES__ =======
+
+tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
+tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
+
+tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
+
+BUILD_TARGETS = $(tarball_target)
+
+PRODUCT_TARGETS = $(tarball)
+
+include ../../../build-system/core.mk
+
+
+$(tarball): $(tarball_target)
+
+$(tarball_target):
+ @echo ""
+ @echo "Creating $(tarball_name) tarball..."
+ @cd $(TOOLCHAINS_BASE_PATH) ; \
+ tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
+ @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
+ @touch $@
Index: products/RK328X-glibc/1.11.4/RK328X-TEST-vfp/.config
===================================================================
--- products/RK328X-glibc/1.11.4/RK328X-TEST-vfp/.config (nonexistent)
+++ products/RK328X-glibc/1.11.4/RK328X-TEST-vfp/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=arm-rk328x-linux-gnueabihf
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/arm-RK328X-linux-glibc/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/RK328X-glibc/1.11.4/RK328X-TEST-vfp/build.sh
===================================================================
--- products/RK328X-glibc/1.11.4/RK328X-TEST-vfp/build.sh (nonexistent)
+++ products/RK328X-glibc/1.11.4/RK328X-TEST-vfp/build.sh (revision 76)
@@ -0,0 +1,21 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+ARCH_FLAGS=" -march=armv7ve -mtune=cortex-a17"
+
+FPU_FLAGS=" -mfloat-abi=hard -mfpu=neon-vfpv4 -ftree-vectorize -fomit-frame-pointer -ffast-math"
+
+$TARGET-gcc -g -O3 -gdwarf-2 -fomit-frame-pointer $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/RK328X-glibc/1.11.4/RK328X-TEST-vfp/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/RK328X-glibc/1.11.4/RK328X-TEST-vfp/clean.sh
===================================================================
--- products/RK328X-glibc/1.11.4/RK328X-TEST-vfp/clean.sh (nonexistent)
+++ products/RK328X-glibc/1.11.4/RK328X-TEST-vfp/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/RK328X-glibc/1.11.4/RK328X-TEST-vfp/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/RK328X-glibc/1.11.4/RK328X-TEST-vfp/main.c
===================================================================
--- products/RK328X-glibc/1.11.4/RK328X-TEST-vfp/main.c (nonexistent)
+++ products/RK328X-glibc/1.11.4/RK328X-TEST-vfp/main.c (revision 76)
@@ -0,0 +1,17 @@
+
+#include <stdlib.h>
+#include <inttypes.h>
+
+int main()
+{
+ float d, f = 3.1415;
+
+ uint32_t a = 7, b = 3, c, r;
+
+ c = a / b;
+ r = a % b;
+
+ d = f * 2.1;
+
+ return( 0 );
+}
Index: products/RK328X-glibc/1.11.4/RK328X-TEST-vfp
===================================================================
--- products/RK328X-glibc/1.11.4/RK328X-TEST-vfp (nonexistent)
+++ products/RK328X-glibc/1.11.4/RK328X-TEST-vfp (revision 76)
Property changes on: products/RK328X-glibc/1.11.4/RK328X-TEST-vfp
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/RK328X-glibc/1.11.4
===================================================================
--- products/RK328X-glibc/1.11.4 (nonexistent)
+++ products/RK328X-glibc/1.11.4 (revision 76)
Property changes on: products/RK328X-glibc/1.11.4
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/RK339X-glibc/1.11.3/RK339X-TEST/main.c
===================================================================
--- products/RK339X-glibc/1.11.3/RK339X-TEST/main.c (revision 75)
+++ products/RK339X-glibc/1.11.3/RK339X-TEST/main.c (nonexistent)
@@ -1,17 +0,0 @@
-
-#include <stdlib.h>
-#include <inttypes.h>
-
-int main()
-{
- float d, f = 3.1415;
-
- uint32_t a = 7, b = 3, c, r;
-
- c = a / b;
- r = a % b;
-
- d = f * 2.1;
-
- return( 0 );
-}
Index: products/RK339X-glibc/1.11.3/RK339X-TEST/build.sh
===================================================================
--- products/RK339X-glibc/1.11.3/RK339X-TEST/build.sh (revision 75)
+++ products/RK339X-glibc/1.11.3/RK339X-TEST/build.sh (nonexistent)
@@ -1,19 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-ARCH_FLAGS=" -march=armv8-a -mcpu=cortex-a72.cortex-a53 -mabi=lp64"
-
-$TARGET-gcc -g -O3 -gdwarf-2 -fomit-frame-pointer $ARCH_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/RK339X-glibc/1.11.3/RK339X-TEST/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/RK339X-glibc/1.11.3/RK339X-TEST/.config
===================================================================
--- products/RK339X-glibc/1.11.3/RK339X-TEST/.config (revision 75)
+++ products/RK339X-glibc/1.11.3/RK339X-TEST/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=aarch64-rk339x-linux-gnu
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/aarch64-RK339X-linux-glibc/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/RK339X-glibc/1.11.3/RK339X-TEST/clean.sh
===================================================================
--- products/RK339X-glibc/1.11.3/RK339X-TEST/clean.sh (revision 75)
+++ products/RK339X-glibc/1.11.3/RK339X-TEST/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/RK339X-glibc/1.11.3/RK339X-TEST/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/RK339X-glibc/1.11.3/RK339X-TEST
===================================================================
--- products/RK339X-glibc/1.11.3/RK339X-TEST (revision 75)
+++ products/RK339X-glibc/1.11.3/RK339X-TEST (nonexistent)
Property changes on: products/RK339X-glibc/1.11.3/RK339X-TEST
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/RK339X-glibc/1.11.3/Makefile
===================================================================
--- products/RK339X-glibc/1.11.3/Makefile (revision 75)
+++ products/RK339X-glibc/1.11.3/Makefile (nonexistent)
@@ -1,35 +0,0 @@
-
-
-COMPONENT_TARGETS = $(TOOLCHAIN_RK339X_GLIBC)
-
-export TOOLCHAIN_VERSION = 1.11.3
-
-include ../../../build-system/config.mk
-
-REQUIRES = core/gcc/14.2.0^full
-REQUIRES += tools/patchelf/0.18.0
-REQUIRES += core/gdb/15.1
-
-# ======= __END_OF_REQUIRES__ =======
-
-tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
-tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
-
-tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
-
-BUILD_TARGETS = $(tarball_target)
-
-PRODUCT_TARGETS = $(tarball)
-
-include ../../../build-system/core.mk
-
-
-$(tarball): $(tarball_target)
-
-$(tarball_target):
- @echo ""
- @echo "Creating $(tarball_name) tarball..."
- @cd $(TOOLCHAINS_BASE_PATH) ; \
- tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
- @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
- @touch $@
Index: products/RK339X-glibc/1.11.3
===================================================================
--- products/RK339X-glibc/1.11.3 (revision 75)
+++ products/RK339X-glibc/1.11.3 (nonexistent)
Property changes on: products/RK339X-glibc/1.11.3
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/RK339X-glibc/1.11.4/Makefile
===================================================================
--- products/RK339X-glibc/1.11.4/Makefile (nonexistent)
+++ products/RK339X-glibc/1.11.4/Makefile (revision 76)
@@ -0,0 +1,35 @@
+
+
+COMPONENT_TARGETS = $(TOOLCHAIN_RK339X_GLIBC)
+
+export TOOLCHAIN_VERSION = 1.11.4
+
+include ../../../build-system/config.mk
+
+REQUIRES = core/gcc/14.2.0^full
+REQUIRES += tools/patchelf/0.18.0
+REQUIRES += core/gdb/16.2
+
+# ======= __END_OF_REQUIRES__ =======
+
+tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
+tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
+
+tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
+
+BUILD_TARGETS = $(tarball_target)
+
+PRODUCT_TARGETS = $(tarball)
+
+include ../../../build-system/core.mk
+
+
+$(tarball): $(tarball_target)
+
+$(tarball_target):
+ @echo ""
+ @echo "Creating $(tarball_name) tarball..."
+ @cd $(TOOLCHAINS_BASE_PATH) ; \
+ tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
+ @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
+ @touch $@
Index: products/RK339X-glibc/1.11.4/RK339X-TEST/.config
===================================================================
--- products/RK339X-glibc/1.11.4/RK339X-TEST/.config (nonexistent)
+++ products/RK339X-glibc/1.11.4/RK339X-TEST/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=aarch64-rk339x-linux-gnu
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/aarch64-RK339X-linux-glibc/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/RK339X-glibc/1.11.4/RK339X-TEST/build.sh
===================================================================
--- products/RK339X-glibc/1.11.4/RK339X-TEST/build.sh (nonexistent)
+++ products/RK339X-glibc/1.11.4/RK339X-TEST/build.sh (revision 76)
@@ -0,0 +1,19 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+ARCH_FLAGS=" -march=armv8-a -mcpu=cortex-a72.cortex-a53 -mabi=lp64"
+
+$TARGET-gcc -g -O3 -gdwarf-2 -fomit-frame-pointer $ARCH_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/RK339X-glibc/1.11.4/RK339X-TEST/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/RK339X-glibc/1.11.4/RK339X-TEST/clean.sh
===================================================================
--- products/RK339X-glibc/1.11.4/RK339X-TEST/clean.sh (nonexistent)
+++ products/RK339X-glibc/1.11.4/RK339X-TEST/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/RK339X-glibc/1.11.4/RK339X-TEST/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/RK339X-glibc/1.11.4/RK339X-TEST/main.c
===================================================================
--- products/RK339X-glibc/1.11.4/RK339X-TEST/main.c (nonexistent)
+++ products/RK339X-glibc/1.11.4/RK339X-TEST/main.c (revision 76)
@@ -0,0 +1,17 @@
+
+#include <stdlib.h>
+#include <inttypes.h>
+
+int main()
+{
+ float d, f = 3.1415;
+
+ uint32_t a = 7, b = 3, c, r;
+
+ c = a / b;
+ r = a % b;
+
+ d = f * 2.1;
+
+ return( 0 );
+}
Index: products/RK339X-glibc/1.11.4/RK339X-TEST
===================================================================
--- products/RK339X-glibc/1.11.4/RK339X-TEST (nonexistent)
+++ products/RK339X-glibc/1.11.4/RK339X-TEST (revision 76)
Property changes on: products/RK339X-glibc/1.11.4/RK339X-TEST
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/RK339X-glibc/1.11.4
===================================================================
--- products/RK339X-glibc/1.11.4 (nonexistent)
+++ products/RK339X-glibc/1.11.4 (revision 76)
Property changes on: products/RK339X-glibc/1.11.4
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/RK33XX-glibc/1.11.3/RK33XX-TEST/main.c
===================================================================
--- products/RK33XX-glibc/1.11.3/RK33XX-TEST/main.c (revision 75)
+++ products/RK33XX-glibc/1.11.3/RK33XX-TEST/main.c (nonexistent)
@@ -1,17 +0,0 @@
-
-#include <stdlib.h>
-#include <inttypes.h>
-
-int main()
-{
- float d, f = 3.1415;
-
- uint32_t a = 7, b = 3, c, r;
-
- c = a / b;
- r = a % b;
-
- d = f * 2.1;
-
- return( 0 );
-}
Index: products/RK33XX-glibc/1.11.3/RK33XX-TEST/build.sh
===================================================================
--- products/RK33XX-glibc/1.11.3/RK33XX-TEST/build.sh (revision 75)
+++ products/RK33XX-glibc/1.11.3/RK33XX-TEST/build.sh (nonexistent)
@@ -1,19 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-ARCH_FLAGS=" -march=armv8-a -mcpu=cortex-a53 -mabi=lp64"
-
-$TARGET-gcc -g -O3 -gdwarf-2 -fomit-frame-pointer $ARCH_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/RK33XX-glibc/1.11.3/RK33XX-TEST/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/RK33XX-glibc/1.11.3/RK33XX-TEST/.config
===================================================================
--- products/RK33XX-glibc/1.11.3/RK33XX-TEST/.config (revision 75)
+++ products/RK33XX-glibc/1.11.3/RK33XX-TEST/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=aarch64-rk33xx-linux-gnu
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/aarch64-RK33XX-linux-glibc/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/RK33XX-glibc/1.11.3/RK33XX-TEST/clean.sh
===================================================================
--- products/RK33XX-glibc/1.11.3/RK33XX-TEST/clean.sh (revision 75)
+++ products/RK33XX-glibc/1.11.3/RK33XX-TEST/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/RK33XX-glibc/1.11.3/RK33XX-TEST/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/RK33XX-glibc/1.11.3/RK33XX-TEST
===================================================================
--- products/RK33XX-glibc/1.11.3/RK33XX-TEST (revision 75)
+++ products/RK33XX-glibc/1.11.3/RK33XX-TEST (nonexistent)
Property changes on: products/RK33XX-glibc/1.11.3/RK33XX-TEST
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/RK33XX-glibc/1.11.3/Makefile
===================================================================
--- products/RK33XX-glibc/1.11.3/Makefile (revision 75)
+++ products/RK33XX-glibc/1.11.3/Makefile (nonexistent)
@@ -1,35 +0,0 @@
-
-
-COMPONENT_TARGETS = $(TOOLCHAIN_RK33XX_GLIBC)
-
-export TOOLCHAIN_VERSION = 1.11.3
-
-include ../../../build-system/config.mk
-
-REQUIRES = core/gcc/14.2.0^full
-REQUIRES += tools/patchelf/0.18.0
-REQUIRES += core/gdb/15.1
-
-# ======= __END_OF_REQUIRES__ =======
-
-tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
-tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
-
-tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
-
-BUILD_TARGETS = $(tarball_target)
-
-PRODUCT_TARGETS = $(tarball)
-
-include ../../../build-system/core.mk
-
-
-$(tarball): $(tarball_target)
-
-$(tarball_target):
- @echo ""
- @echo "Creating $(tarball_name) tarball..."
- @cd $(TOOLCHAINS_BASE_PATH) ; \
- tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
- @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
- @touch $@
Index: products/RK33XX-glibc/1.11.3
===================================================================
--- products/RK33XX-glibc/1.11.3 (revision 75)
+++ products/RK33XX-glibc/1.11.3 (nonexistent)
Property changes on: products/RK33XX-glibc/1.11.3
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/RK33XX-glibc/1.11.4/Makefile
===================================================================
--- products/RK33XX-glibc/1.11.4/Makefile (nonexistent)
+++ products/RK33XX-glibc/1.11.4/Makefile (revision 76)
@@ -0,0 +1,35 @@
+
+
+COMPONENT_TARGETS = $(TOOLCHAIN_RK33XX_GLIBC)
+
+export TOOLCHAIN_VERSION = 1.11.4
+
+include ../../../build-system/config.mk
+
+REQUIRES = core/gcc/14.2.0^full
+REQUIRES += tools/patchelf/0.18.0
+REQUIRES += core/gdb/16.2
+
+# ======= __END_OF_REQUIRES__ =======
+
+tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
+tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
+
+tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
+
+BUILD_TARGETS = $(tarball_target)
+
+PRODUCT_TARGETS = $(tarball)
+
+include ../../../build-system/core.mk
+
+
+$(tarball): $(tarball_target)
+
+$(tarball_target):
+ @echo ""
+ @echo "Creating $(tarball_name) tarball..."
+ @cd $(TOOLCHAINS_BASE_PATH) ; \
+ tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
+ @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
+ @touch $@
Index: products/RK33XX-glibc/1.11.4/RK33XX-TEST/.config
===================================================================
--- products/RK33XX-glibc/1.11.4/RK33XX-TEST/.config (nonexistent)
+++ products/RK33XX-glibc/1.11.4/RK33XX-TEST/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=aarch64-rk33xx-linux-gnu
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/aarch64-RK33XX-linux-glibc/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/RK33XX-glibc/1.11.4/RK33XX-TEST/build.sh
===================================================================
--- products/RK33XX-glibc/1.11.4/RK33XX-TEST/build.sh (nonexistent)
+++ products/RK33XX-glibc/1.11.4/RK33XX-TEST/build.sh (revision 76)
@@ -0,0 +1,19 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+ARCH_FLAGS=" -march=armv8-a -mcpu=cortex-a53 -mabi=lp64"
+
+$TARGET-gcc -g -O3 -gdwarf-2 -fomit-frame-pointer $ARCH_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/RK33XX-glibc/1.11.4/RK33XX-TEST/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/RK33XX-glibc/1.11.4/RK33XX-TEST/clean.sh
===================================================================
--- products/RK33XX-glibc/1.11.4/RK33XX-TEST/clean.sh (nonexistent)
+++ products/RK33XX-glibc/1.11.4/RK33XX-TEST/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/RK33XX-glibc/1.11.4/RK33XX-TEST/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/RK33XX-glibc/1.11.4/RK33XX-TEST/main.c
===================================================================
--- products/RK33XX-glibc/1.11.4/RK33XX-TEST/main.c (nonexistent)
+++ products/RK33XX-glibc/1.11.4/RK33XX-TEST/main.c (revision 76)
@@ -0,0 +1,17 @@
+
+#include <stdlib.h>
+#include <inttypes.h>
+
+int main()
+{
+ float d, f = 3.1415;
+
+ uint32_t a = 7, b = 3, c, r;
+
+ c = a / b;
+ r = a % b;
+
+ d = f * 2.1;
+
+ return( 0 );
+}
Index: products/RK33XX-glibc/1.11.4/RK33XX-TEST
===================================================================
--- products/RK33XX-glibc/1.11.4/RK33XX-TEST (nonexistent)
+++ products/RK33XX-glibc/1.11.4/RK33XX-TEST (revision 76)
Property changes on: products/RK33XX-glibc/1.11.4/RK33XX-TEST
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/RK33XX-glibc/1.11.4
===================================================================
--- products/RK33XX-glibc/1.11.4 (nonexistent)
+++ products/RK33XX-glibc/1.11.4 (revision 76)
Property changes on: products/RK33XX-glibc/1.11.4
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/RK33XX-newlib/1.11.3/RK33XX-TEST-ilp32/main.c
===================================================================
--- products/RK33XX-newlib/1.11.3/RK33XX-TEST-ilp32/main.c (revision 75)
+++ products/RK33XX-newlib/1.11.3/RK33XX-TEST-ilp32/main.c (nonexistent)
@@ -1,13 +0,0 @@
-
-#include <stdlib.h>
-#include <inttypes.h>
-
-int main()
-{
- uint32_t a = 7, b = 3, c, r;
-
- c = a / b;
- r = a % b;
-
- return( 0 );
-}
Index: products/RK33XX-newlib/1.11.3/RK33XX-TEST-ilp32/build.sh
===================================================================
--- products/RK33XX-newlib/1.11.3/RK33XX-TEST-ilp32/build.sh (revision 75)
+++ products/RK33XX-newlib/1.11.3/RK33XX-TEST-ilp32/build.sh (nonexistent)
@@ -1,20 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-DEBUG_FLAGS="-gdwarf-2"
-ARCH_FLAGS=" -march=armv8-a -mcpu=cortex-a53 -mabi=ilp32 -mlittle-endian"
-
-$TARGET-gcc -g $DEBUG_FLAGS $ARCH_FLAGS -fomit-frame-pointer -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-$TARGET-gcc $DEBUG_FLAGS $ARCH_FLAGS -o main main.o -lc -lm -lnosys -lrdimon
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/RK33XX-newlib/1.11.3/RK33XX-TEST-ilp32/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/RK33XX-newlib/1.11.3/RK33XX-TEST-ilp32/.config
===================================================================
--- products/RK33XX-newlib/1.11.3/RK33XX-TEST-ilp32/.config (revision 75)
+++ products/RK33XX-newlib/1.11.3/RK33XX-TEST-ilp32/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=aarch64-rk33xx-elf
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/aarch64-RK33XX-elf-newlib/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/RK33XX-newlib/1.11.3/RK33XX-TEST-ilp32/clean.sh
===================================================================
--- products/RK33XX-newlib/1.11.3/RK33XX-TEST-ilp32/clean.sh (revision 75)
+++ products/RK33XX-newlib/1.11.3/RK33XX-TEST-ilp32/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/RK33XX-newlib/1.11.3/RK33XX-TEST-ilp32/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/RK33XX-newlib/1.11.3/RK33XX-TEST-ilp32
===================================================================
--- products/RK33XX-newlib/1.11.3/RK33XX-TEST-ilp32 (revision 75)
+++ products/RK33XX-newlib/1.11.3/RK33XX-TEST-ilp32 (nonexistent)
Property changes on: products/RK33XX-newlib/1.11.3/RK33XX-TEST-ilp32
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/RK33XX-newlib/1.11.3/Makefile
===================================================================
--- products/RK33XX-newlib/1.11.3/Makefile (revision 75)
+++ products/RK33XX-newlib/1.11.3/Makefile (nonexistent)
@@ -1,34 +0,0 @@
-
-
-COMPONENT_TARGETS = $(TOOLCHAIN_RK33XX_NEWLIB)
-
-export TOOLCHAIN_VERSION = 1.11.3
-
-include ../../../build-system/config.mk
-
-REQUIRES = core/gcc/14.2.0^full
-REQUIRES += core/gdb/15.1
-
-# ======= __END_OF_REQUIRES__ =======
-
-tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
-tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
-
-tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
-
-BUILD_TARGETS = $(tarball_target)
-
-PRODUCT_TARGETS = $(tarball)
-
-include ../../../build-system/core.mk
-
-
-$(tarball): $(tarball_target)
-
-$(tarball_target):
- @echo ""
- @echo "Creating $(tarball_name) tarball..."
- @cd $(TOOLCHAINS_BASE_PATH) ; \
- tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
- @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
- @touch $@
Index: products/RK33XX-newlib/1.11.3/RK33XX-TEST-lp64/main.c
===================================================================
--- products/RK33XX-newlib/1.11.3/RK33XX-TEST-lp64/main.c (revision 75)
+++ products/RK33XX-newlib/1.11.3/RK33XX-TEST-lp64/main.c (nonexistent)
@@ -1,13 +0,0 @@
-
-#include <stdlib.h>
-#include <inttypes.h>
-
-int main()
-{
- uint32_t a = 7, b = 3, c, r;
-
- c = a / b;
- r = a % b;
-
- return( 0 );
-}
Index: products/RK33XX-newlib/1.11.3/RK33XX-TEST-lp64/build.sh
===================================================================
--- products/RK33XX-newlib/1.11.3/RK33XX-TEST-lp64/build.sh (revision 75)
+++ products/RK33XX-newlib/1.11.3/RK33XX-TEST-lp64/build.sh (nonexistent)
@@ -1,20 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-DEBUG_FLAGS="-gdwarf-2"
-ARCH_FLAGS=" -march=armv8-a -mcpu=cortex-a53 -mabi=lp64 -mlittle-endian"
-
-$TARGET-gcc -g $DEBUG_FLAGS $ARCH_FLAGS -fomit-frame-pointer -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-$TARGET-gcc $DEBUG_FLAGS $ARCH_FLAGS -o main main.o -lc -lm -lnosys -lrdimon
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/RK33XX-newlib/1.11.3/RK33XX-TEST-lp64/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/RK33XX-newlib/1.11.3/RK33XX-TEST-lp64/.config
===================================================================
--- products/RK33XX-newlib/1.11.3/RK33XX-TEST-lp64/.config (revision 75)
+++ products/RK33XX-newlib/1.11.3/RK33XX-TEST-lp64/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=aarch64-rk33xx-elf
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/aarch64-RK33XX-elf-newlib/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/RK33XX-newlib/1.11.3/RK33XX-TEST-lp64/clean.sh
===================================================================
--- products/RK33XX-newlib/1.11.3/RK33XX-TEST-lp64/clean.sh (revision 75)
+++ products/RK33XX-newlib/1.11.3/RK33XX-TEST-lp64/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/RK33XX-newlib/1.11.3/RK33XX-TEST-lp64/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/RK33XX-newlib/1.11.3/RK33XX-TEST-lp64
===================================================================
--- products/RK33XX-newlib/1.11.3/RK33XX-TEST-lp64 (revision 75)
+++ products/RK33XX-newlib/1.11.3/RK33XX-TEST-lp64 (nonexistent)
Property changes on: products/RK33XX-newlib/1.11.3/RK33XX-TEST-lp64
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/RK33XX-newlib/1.11.3
===================================================================
--- products/RK33XX-newlib/1.11.3 (revision 75)
+++ products/RK33XX-newlib/1.11.3 (nonexistent)
Property changes on: products/RK33XX-newlib/1.11.3
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/RK33XX-newlib/1.11.4/Makefile
===================================================================
--- products/RK33XX-newlib/1.11.4/Makefile (nonexistent)
+++ products/RK33XX-newlib/1.11.4/Makefile (revision 76)
@@ -0,0 +1,34 @@
+
+
+COMPONENT_TARGETS = $(TOOLCHAIN_RK33XX_NEWLIB)
+
+export TOOLCHAIN_VERSION = 1.11.4
+
+include ../../../build-system/config.mk
+
+REQUIRES = core/gcc/14.2.0^full
+REQUIRES += core/gdb/16.2
+
+# ======= __END_OF_REQUIRES__ =======
+
+tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
+tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
+
+tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
+
+BUILD_TARGETS = $(tarball_target)
+
+PRODUCT_TARGETS = $(tarball)
+
+include ../../../build-system/core.mk
+
+
+$(tarball): $(tarball_target)
+
+$(tarball_target):
+ @echo ""
+ @echo "Creating $(tarball_name) tarball..."
+ @cd $(TOOLCHAINS_BASE_PATH) ; \
+ tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
+ @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
+ @touch $@
Index: products/RK33XX-newlib/1.11.4/RK33XX-TEST-ilp32/.config
===================================================================
--- products/RK33XX-newlib/1.11.4/RK33XX-TEST-ilp32/.config (nonexistent)
+++ products/RK33XX-newlib/1.11.4/RK33XX-TEST-ilp32/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=aarch64-rk33xx-elf
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/aarch64-RK33XX-elf-newlib/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/RK33XX-newlib/1.11.4/RK33XX-TEST-ilp32/build.sh
===================================================================
--- products/RK33XX-newlib/1.11.4/RK33XX-TEST-ilp32/build.sh (nonexistent)
+++ products/RK33XX-newlib/1.11.4/RK33XX-TEST-ilp32/build.sh (revision 76)
@@ -0,0 +1,20 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+DEBUG_FLAGS="-gdwarf-2"
+ARCH_FLAGS=" -march=armv8-a -mcpu=cortex-a53 -mabi=ilp32 -mlittle-endian"
+
+$TARGET-gcc -g $DEBUG_FLAGS $ARCH_FLAGS -fomit-frame-pointer -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+$TARGET-gcc $DEBUG_FLAGS $ARCH_FLAGS -o main main.o -lc -lm -lnosys -lrdimon
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/RK33XX-newlib/1.11.4/RK33XX-TEST-ilp32/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/RK33XX-newlib/1.11.4/RK33XX-TEST-ilp32/clean.sh
===================================================================
--- products/RK33XX-newlib/1.11.4/RK33XX-TEST-ilp32/clean.sh (nonexistent)
+++ products/RK33XX-newlib/1.11.4/RK33XX-TEST-ilp32/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/RK33XX-newlib/1.11.4/RK33XX-TEST-ilp32/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/RK33XX-newlib/1.11.4/RK33XX-TEST-ilp32/main.c
===================================================================
--- products/RK33XX-newlib/1.11.4/RK33XX-TEST-ilp32/main.c (nonexistent)
+++ products/RK33XX-newlib/1.11.4/RK33XX-TEST-ilp32/main.c (revision 76)
@@ -0,0 +1,13 @@
+
+#include <stdlib.h>
+#include <inttypes.h>
+
+int main()
+{
+ uint32_t a = 7, b = 3, c, r;
+
+ c = a / b;
+ r = a % b;
+
+ return( 0 );
+}
Index: products/RK33XX-newlib/1.11.4/RK33XX-TEST-ilp32
===================================================================
--- products/RK33XX-newlib/1.11.4/RK33XX-TEST-ilp32 (nonexistent)
+++ products/RK33XX-newlib/1.11.4/RK33XX-TEST-ilp32 (revision 76)
Property changes on: products/RK33XX-newlib/1.11.4/RK33XX-TEST-ilp32
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/RK33XX-newlib/1.11.4/RK33XX-TEST-lp64/.config
===================================================================
--- products/RK33XX-newlib/1.11.4/RK33XX-TEST-lp64/.config (nonexistent)
+++ products/RK33XX-newlib/1.11.4/RK33XX-TEST-lp64/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=aarch64-rk33xx-elf
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/aarch64-RK33XX-elf-newlib/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/RK33XX-newlib/1.11.4/RK33XX-TEST-lp64/build.sh
===================================================================
--- products/RK33XX-newlib/1.11.4/RK33XX-TEST-lp64/build.sh (nonexistent)
+++ products/RK33XX-newlib/1.11.4/RK33XX-TEST-lp64/build.sh (revision 76)
@@ -0,0 +1,20 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+DEBUG_FLAGS="-gdwarf-2"
+ARCH_FLAGS=" -march=armv8-a -mcpu=cortex-a53 -mabi=lp64 -mlittle-endian"
+
+$TARGET-gcc -g $DEBUG_FLAGS $ARCH_FLAGS -fomit-frame-pointer -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+$TARGET-gcc $DEBUG_FLAGS $ARCH_FLAGS -o main main.o -lc -lm -lnosys -lrdimon
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/RK33XX-newlib/1.11.4/RK33XX-TEST-lp64/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/RK33XX-newlib/1.11.4/RK33XX-TEST-lp64/clean.sh
===================================================================
--- products/RK33XX-newlib/1.11.4/RK33XX-TEST-lp64/clean.sh (nonexistent)
+++ products/RK33XX-newlib/1.11.4/RK33XX-TEST-lp64/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/RK33XX-newlib/1.11.4/RK33XX-TEST-lp64/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/RK33XX-newlib/1.11.4/RK33XX-TEST-lp64/main.c
===================================================================
--- products/RK33XX-newlib/1.11.4/RK33XX-TEST-lp64/main.c (nonexistent)
+++ products/RK33XX-newlib/1.11.4/RK33XX-TEST-lp64/main.c (revision 76)
@@ -0,0 +1,13 @@
+
+#include <stdlib.h>
+#include <inttypes.h>
+
+int main()
+{
+ uint32_t a = 7, b = 3, c, r;
+
+ c = a / b;
+ r = a % b;
+
+ return( 0 );
+}
Index: products/RK33XX-newlib/1.11.4/RK33XX-TEST-lp64
===================================================================
--- products/RK33XX-newlib/1.11.4/RK33XX-TEST-lp64 (nonexistent)
+++ products/RK33XX-newlib/1.11.4/RK33XX-TEST-lp64 (revision 76)
Property changes on: products/RK33XX-newlib/1.11.4/RK33XX-TEST-lp64
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/RK33XX-newlib/1.11.4
===================================================================
--- products/RK33XX-newlib/1.11.4 (nonexistent)
+++ products/RK33XX-newlib/1.11.4 (revision 76)
Property changes on: products/RK33XX-newlib/1.11.4
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/RK358X-glibc/1.11.3/RK358X-TEST/main.c
===================================================================
--- products/RK358X-glibc/1.11.3/RK358X-TEST/main.c (revision 75)
+++ products/RK358X-glibc/1.11.3/RK358X-TEST/main.c (nonexistent)
@@ -1,17 +0,0 @@
-
-#include <stdlib.h>
-#include <inttypes.h>
-
-int main()
-{
- float d, f = 3.1415;
-
- uint32_t a = 7, b = 3, c, r;
-
- c = a / b;
- r = a % b;
-
- d = f * 2.1;
-
- return( 0 );
-}
Index: products/RK358X-glibc/1.11.3/RK358X-TEST/build.sh
===================================================================
--- products/RK358X-glibc/1.11.3/RK358X-TEST/build.sh (revision 75)
+++ products/RK358X-glibc/1.11.3/RK358X-TEST/build.sh (nonexistent)
@@ -1,19 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-ARCH_FLAGS=" -march=armv8.2-a -mtune=cortex-a76.cortex-a55 -mabi=lp64"
-
-$TARGET-gcc -g -O3 -gdwarf-2 -fomit-frame-pointer $ARCH_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/RK358X-glibc/1.11.3/RK358X-TEST/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/RK358X-glibc/1.11.3/RK358X-TEST/.config
===================================================================
--- products/RK358X-glibc/1.11.3/RK358X-TEST/.config (revision 75)
+++ products/RK358X-glibc/1.11.3/RK358X-TEST/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=aarch64-rk358x-linux-gnu
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/aarch64-RK358X-linux-glibc/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/RK358X-glibc/1.11.3/RK358X-TEST/clean.sh
===================================================================
--- products/RK358X-glibc/1.11.3/RK358X-TEST/clean.sh (revision 75)
+++ products/RK358X-glibc/1.11.3/RK358X-TEST/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/RK358X-glibc/1.11.3/RK358X-TEST/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/RK358X-glibc/1.11.3/Makefile
===================================================================
--- products/RK358X-glibc/1.11.3/Makefile (revision 75)
+++ products/RK358X-glibc/1.11.3/Makefile (nonexistent)
@@ -1,35 +0,0 @@
-
-
-COMPONENT_TARGETS = $(TOOLCHAIN_RK358X_GLIBC)
-
-export TOOLCHAIN_VERSION = 1.11.3
-
-include ../../../build-system/config.mk
-
-REQUIRES = core/gcc/14.2.0^full
-REQUIRES += tools/patchelf/0.18.0
-REQUIRES += core/gdb/15.1
-
-# ======= __END_OF_REQUIRES__ =======
-
-tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
-tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
-
-tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
-
-BUILD_TARGETS = $(tarball_target)
-
-PRODUCT_TARGETS = $(tarball)
-
-include ../../../build-system/core.mk
-
-
-$(tarball): $(tarball_target)
-
-$(tarball_target):
- @echo ""
- @echo "Creating $(tarball_name) tarball..."
- @cd $(TOOLCHAINS_BASE_PATH) ; \
- tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
- @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
- @touch $@
Index: products/RK358X-glibc/1.11.3
===================================================================
--- products/RK358X-glibc/1.11.3 (revision 75)
+++ products/RK358X-glibc/1.11.3 (nonexistent)
Property changes on: products/RK358X-glibc/1.11.3
___________________________________________________________________
Deleted: svn:ignore
## -1,81 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.rk358x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/RK358X-glibc/1.11.4/Makefile
===================================================================
--- products/RK358X-glibc/1.11.4/Makefile (nonexistent)
+++ products/RK358X-glibc/1.11.4/Makefile (revision 76)
@@ -0,0 +1,35 @@
+
+
+COMPONENT_TARGETS = $(TOOLCHAIN_RK358X_GLIBC)
+
+export TOOLCHAIN_VERSION = 1.11.4
+
+include ../../../build-system/config.mk
+
+REQUIRES = core/gcc/14.2.0^full
+REQUIRES += tools/patchelf/0.18.0
+REQUIRES += core/gdb/16.2
+
+# ======= __END_OF_REQUIRES__ =======
+
+tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
+tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
+
+tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
+
+BUILD_TARGETS = $(tarball_target)
+
+PRODUCT_TARGETS = $(tarball)
+
+include ../../../build-system/core.mk
+
+
+$(tarball): $(tarball_target)
+
+$(tarball_target):
+ @echo ""
+ @echo "Creating $(tarball_name) tarball..."
+ @cd $(TOOLCHAINS_BASE_PATH) ; \
+ tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
+ @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
+ @touch $@
Index: products/RK358X-glibc/1.11.4/RK358X-TEST/.config
===================================================================
--- products/RK358X-glibc/1.11.4/RK358X-TEST/.config (nonexistent)
+++ products/RK358X-glibc/1.11.4/RK358X-TEST/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=aarch64-rk358x-linux-gnu
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/aarch64-RK358X-linux-glibc/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/RK358X-glibc/1.11.4/RK358X-TEST/build.sh
===================================================================
--- products/RK358X-glibc/1.11.4/RK358X-TEST/build.sh (nonexistent)
+++ products/RK358X-glibc/1.11.4/RK358X-TEST/build.sh (revision 76)
@@ -0,0 +1,19 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+ARCH_FLAGS=" -march=armv8.2-a -mtune=cortex-a76.cortex-a55 -mabi=lp64"
+
+$TARGET-gcc -g -O3 -gdwarf-2 -fomit-frame-pointer $ARCH_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/RK358X-glibc/1.11.4/RK358X-TEST/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/RK358X-glibc/1.11.4/RK358X-TEST/clean.sh
===================================================================
--- products/RK358X-glibc/1.11.4/RK358X-TEST/clean.sh (nonexistent)
+++ products/RK358X-glibc/1.11.4/RK358X-TEST/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/RK358X-glibc/1.11.4/RK358X-TEST/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/RK358X-glibc/1.11.4/RK358X-TEST/main.c
===================================================================
--- products/RK358X-glibc/1.11.4/RK358X-TEST/main.c (nonexistent)
+++ products/RK358X-glibc/1.11.4/RK358X-TEST/main.c (revision 76)
@@ -0,0 +1,17 @@
+
+#include <stdlib.h>
+#include <inttypes.h>
+
+int main()
+{
+ float d, f = 3.1415;
+
+ uint32_t a = 7, b = 3, c, r;
+
+ c = a / b;
+ r = a % b;
+
+ d = f * 2.1;
+
+ return( 0 );
+}
Index: products/RK358X-glibc/1.11.4
===================================================================
--- products/RK358X-glibc/1.11.4 (nonexistent)
+++ products/RK358X-glibc/1.11.4 (revision 76)
Property changes on: products/RK358X-glibc/1.11.4
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,81 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.rk358x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/S8XX-glibc/1.11.3/S8XX-TEST-neon/main.c
===================================================================
--- products/S8XX-glibc/1.11.3/S8XX-TEST-neon/main.c (revision 75)
+++ products/S8XX-glibc/1.11.3/S8XX-TEST-neon/main.c (nonexistent)
@@ -1,17 +0,0 @@
-
-//#include <stdlib.h>
-//#include <inttypes.h>
-
-int main()
-{
- float d, f = 3.1415;
-
-// uint32_t a = 7, b = 3, c, r;
-
-// c = a / b;
-// r = a % b;
-
- d = f * 2.1;
-
- return( 0 );
-}
Index: products/S8XX-glibc/1.11.3/S8XX-TEST-neon/build.sh
===================================================================
--- products/S8XX-glibc/1.11.3/S8XX-TEST-neon/build.sh (revision 75)
+++ products/S8XX-glibc/1.11.3/S8XX-TEST-neon/build.sh (nonexistent)
@@ -1,21 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-ARCH_FLAGS=" -march=armv7-a -mtune=cortex-a5"
-
-FPU_FLAGS=" -mfloat-abi=hard -mfpu=neon -ftree-vectorize -fomit-frame-pointer -ffast-math"
-
-$TARGET-gcc -g -O3 -gdwarf-2 -fomit-frame-pointer $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/S8XX-glibc/1.11.3/S8XX-TEST-neon/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/S8XX-glibc/1.11.3/S8XX-TEST-neon/.config
===================================================================
--- products/S8XX-glibc/1.11.3/S8XX-TEST-neon/.config (revision 75)
+++ products/S8XX-glibc/1.11.3/S8XX-TEST-neon/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=arm-s8xx-linux-gnueabihf
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/arm-S8XX-linux-glibc/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/S8XX-glibc/1.11.3/S8XX-TEST-neon/clean.sh
===================================================================
--- products/S8XX-glibc/1.11.3/S8XX-TEST-neon/clean.sh (revision 75)
+++ products/S8XX-glibc/1.11.3/S8XX-TEST-neon/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/S8XX-glibc/1.11.3/S8XX-TEST-neon/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/S8XX-glibc/1.11.3/S8XX-TEST-neon
===================================================================
--- products/S8XX-glibc/1.11.3/S8XX-TEST-neon (revision 75)
+++ products/S8XX-glibc/1.11.3/S8XX-TEST-neon (nonexistent)
Property changes on: products/S8XX-glibc/1.11.3/S8XX-TEST-neon
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/S8XX-glibc/1.11.3/Makefile
===================================================================
--- products/S8XX-glibc/1.11.3/Makefile (revision 75)
+++ products/S8XX-glibc/1.11.3/Makefile (nonexistent)
@@ -1,35 +0,0 @@
-
-
-COMPONENT_TARGETS = $(TOOLCHAIN_S8XX_GLIBC)
-
-export TOOLCHAIN_VERSION = 1.11.3
-
-include ../../../build-system/config.mk
-
-REQUIRES = core/gcc/14.2.0^full
-REQUIRES += tools/patchelf/0.18.0
-REQUIRES += core/gdb/15.1
-
-# ======= __END_OF_REQUIRES__ =======
-
-tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
-tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
-
-tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
-
-BUILD_TARGETS = $(tarball_target)
-
-PRODUCT_TARGETS = $(tarball)
-
-include ../../../build-system/core.mk
-
-
-$(tarball): $(tarball_target)
-
-$(tarball_target):
- @echo ""
- @echo "Creating $(tarball_name) tarball..."
- @cd $(TOOLCHAINS_BASE_PATH) ; \
- tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
- @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
- @touch $@
Index: products/S8XX-glibc/1.11.3
===================================================================
--- products/S8XX-glibc/1.11.3 (revision 75)
+++ products/S8XX-glibc/1.11.3 (nonexistent)
Property changes on: products/S8XX-glibc/1.11.3
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/S8XX-glibc/1.11.4/Makefile
===================================================================
--- products/S8XX-glibc/1.11.4/Makefile (nonexistent)
+++ products/S8XX-glibc/1.11.4/Makefile (revision 76)
@@ -0,0 +1,35 @@
+
+
+COMPONENT_TARGETS = $(TOOLCHAIN_S8XX_GLIBC)
+
+export TOOLCHAIN_VERSION = 1.11.4
+
+include ../../../build-system/config.mk
+
+REQUIRES = core/gcc/14.2.0^full
+REQUIRES += tools/patchelf/0.18.0
+REQUIRES += core/gdb/16.2
+
+# ======= __END_OF_REQUIRES__ =======
+
+tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
+tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
+
+tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
+
+BUILD_TARGETS = $(tarball_target)
+
+PRODUCT_TARGETS = $(tarball)
+
+include ../../../build-system/core.mk
+
+
+$(tarball): $(tarball_target)
+
+$(tarball_target):
+ @echo ""
+ @echo "Creating $(tarball_name) tarball..."
+ @cd $(TOOLCHAINS_BASE_PATH) ; \
+ tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
+ @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
+ @touch $@
Index: products/S8XX-glibc/1.11.4/S8XX-TEST-neon/.config
===================================================================
--- products/S8XX-glibc/1.11.4/S8XX-TEST-neon/.config (nonexistent)
+++ products/S8XX-glibc/1.11.4/S8XX-TEST-neon/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=arm-s8xx-linux-gnueabihf
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/arm-S8XX-linux-glibc/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/S8XX-glibc/1.11.4/S8XX-TEST-neon/build.sh
===================================================================
--- products/S8XX-glibc/1.11.4/S8XX-TEST-neon/build.sh (nonexistent)
+++ products/S8XX-glibc/1.11.4/S8XX-TEST-neon/build.sh (revision 76)
@@ -0,0 +1,21 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+ARCH_FLAGS=" -march=armv7-a -mtune=cortex-a5"
+
+FPU_FLAGS=" -mfloat-abi=hard -mfpu=neon -ftree-vectorize -fomit-frame-pointer -ffast-math"
+
+$TARGET-gcc -g -O3 -gdwarf-2 -fomit-frame-pointer $ARCH_FLAGS $FPU_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/S8XX-glibc/1.11.4/S8XX-TEST-neon/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/S8XX-glibc/1.11.4/S8XX-TEST-neon/clean.sh
===================================================================
--- products/S8XX-glibc/1.11.4/S8XX-TEST-neon/clean.sh (nonexistent)
+++ products/S8XX-glibc/1.11.4/S8XX-TEST-neon/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/S8XX-glibc/1.11.4/S8XX-TEST-neon/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/S8XX-glibc/1.11.4/S8XX-TEST-neon/main.c
===================================================================
--- products/S8XX-glibc/1.11.4/S8XX-TEST-neon/main.c (nonexistent)
+++ products/S8XX-glibc/1.11.4/S8XX-TEST-neon/main.c (revision 76)
@@ -0,0 +1,17 @@
+
+//#include <stdlib.h>
+//#include <inttypes.h>
+
+int main()
+{
+ float d, f = 3.1415;
+
+// uint32_t a = 7, b = 3, c, r;
+
+// c = a / b;
+// r = a % b;
+
+ d = f * 2.1;
+
+ return( 0 );
+}
Index: products/S8XX-glibc/1.11.4/S8XX-TEST-neon
===================================================================
--- products/S8XX-glibc/1.11.4/S8XX-TEST-neon (nonexistent)
+++ products/S8XX-glibc/1.11.4/S8XX-TEST-neon (revision 76)
Property changes on: products/S8XX-glibc/1.11.4/S8XX-TEST-neon
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/S8XX-glibc/1.11.4
===================================================================
--- products/S8XX-glibc/1.11.4 (nonexistent)
+++ products/S8XX-glibc/1.11.4 (revision 76)
Property changes on: products/S8XX-glibc/1.11.4
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/S9XX-glibc/1.11.3/S9XX-TEST/main.c
===================================================================
--- products/S9XX-glibc/1.11.3/S9XX-TEST/main.c (revision 75)
+++ products/S9XX-glibc/1.11.3/S9XX-TEST/main.c (nonexistent)
@@ -1,17 +0,0 @@
-
-//#include <stdlib.h>
-//#include <inttypes.h>
-
-int main()
-{
- float d, f = 3.1415;
-
-// uint32_t a = 7, b = 3, c, r;
-
-// c = a / b;
-// r = a % b;
-
- d = f * 2.1;
-
- return( 0 );
-}
Index: products/S9XX-glibc/1.11.3/S9XX-TEST/build.sh
===================================================================
--- products/S9XX-glibc/1.11.3/S9XX-TEST/build.sh (revision 75)
+++ products/S9XX-glibc/1.11.3/S9XX-TEST/build.sh (nonexistent)
@@ -1,19 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-ARCH_FLAGS=" -march=armv8-a -mcpu=cortex-a53 -mabi=lp64"
-
-$TARGET-gcc -g -O3 -gdwarf-2 -fomit-frame-pointer $ARCH_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/S9XX-glibc/1.11.3/S9XX-TEST/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/S9XX-glibc/1.11.3/S9XX-TEST/.config
===================================================================
--- products/S9XX-glibc/1.11.3/S9XX-TEST/.config (revision 75)
+++ products/S9XX-glibc/1.11.3/S9XX-TEST/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=aarch64-s9xx-linux-gnu
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/aarch64-S9XX-linux-glibc/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/S9XX-glibc/1.11.3/S9XX-TEST/clean.sh
===================================================================
--- products/S9XX-glibc/1.11.3/S9XX-TEST/clean.sh (revision 75)
+++ products/S9XX-glibc/1.11.3/S9XX-TEST/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/S9XX-glibc/1.11.3/S9XX-TEST/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/S9XX-glibc/1.11.3/S9XX-TEST
===================================================================
--- products/S9XX-glibc/1.11.3/S9XX-TEST (revision 75)
+++ products/S9XX-glibc/1.11.3/S9XX-TEST (nonexistent)
Property changes on: products/S9XX-glibc/1.11.3/S9XX-TEST
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/S9XX-glibc/1.11.3/Makefile
===================================================================
--- products/S9XX-glibc/1.11.3/Makefile (revision 75)
+++ products/S9XX-glibc/1.11.3/Makefile (nonexistent)
@@ -1,35 +0,0 @@
-
-
-COMPONENT_TARGETS = $(TOOLCHAIN_S9XX_GLIBC)
-
-export TOOLCHAIN_VERSION = 1.11.3
-
-include ../../../build-system/config.mk
-
-REQUIRES = core/gcc/14.2.0^full
-REQUIRES += tools/patchelf/0.18.0
-REQUIRES += core/gdb/15.1
-
-# ======= __END_OF_REQUIRES__ =======
-
-tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
-tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
-
-tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
-
-BUILD_TARGETS = $(tarball_target)
-
-PRODUCT_TARGETS = $(tarball)
-
-include ../../../build-system/core.mk
-
-
-$(tarball): $(tarball_target)
-
-$(tarball_target):
- @echo ""
- @echo "Creating $(tarball_name) tarball..."
- @cd $(TOOLCHAINS_BASE_PATH) ; \
- tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
- @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
- @touch $@
Index: products/S9XX-glibc/1.11.3
===================================================================
--- products/S9XX-glibc/1.11.3 (revision 75)
+++ products/S9XX-glibc/1.11.3 (nonexistent)
Property changes on: products/S9XX-glibc/1.11.3
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/S9XX-glibc/1.11.4/Makefile
===================================================================
--- products/S9XX-glibc/1.11.4/Makefile (nonexistent)
+++ products/S9XX-glibc/1.11.4/Makefile (revision 76)
@@ -0,0 +1,35 @@
+
+
+COMPONENT_TARGETS = $(TOOLCHAIN_S9XX_GLIBC)
+
+export TOOLCHAIN_VERSION = 1.11.4
+
+include ../../../build-system/config.mk
+
+REQUIRES = core/gcc/14.2.0^full
+REQUIRES += tools/patchelf/0.18.0
+REQUIRES += core/gdb/16.2
+
+# ======= __END_OF_REQUIRES__ =======
+
+tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
+tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
+
+tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
+
+BUILD_TARGETS = $(tarball_target)
+
+PRODUCT_TARGETS = $(tarball)
+
+include ../../../build-system/core.mk
+
+
+$(tarball): $(tarball_target)
+
+$(tarball_target):
+ @echo ""
+ @echo "Creating $(tarball_name) tarball..."
+ @cd $(TOOLCHAINS_BASE_PATH) ; \
+ tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
+ @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
+ @touch $@
Index: products/S9XX-glibc/1.11.4/S9XX-TEST/.config
===================================================================
--- products/S9XX-glibc/1.11.4/S9XX-TEST/.config (nonexistent)
+++ products/S9XX-glibc/1.11.4/S9XX-TEST/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=aarch64-s9xx-linux-gnu
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/aarch64-S9XX-linux-glibc/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/S9XX-glibc/1.11.4/S9XX-TEST/build.sh
===================================================================
--- products/S9XX-glibc/1.11.4/S9XX-TEST/build.sh (nonexistent)
+++ products/S9XX-glibc/1.11.4/S9XX-TEST/build.sh (revision 76)
@@ -0,0 +1,19 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+ARCH_FLAGS=" -march=armv8-a -mcpu=cortex-a53 -mabi=lp64"
+
+$TARGET-gcc -g -O3 -gdwarf-2 -fomit-frame-pointer $ARCH_FLAGS -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+$TARGET-gcc $ARCH_FLAGS $FPU_FLAGS -o main main.o
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/S9XX-glibc/1.11.4/S9XX-TEST/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/S9XX-glibc/1.11.4/S9XX-TEST/clean.sh
===================================================================
--- products/S9XX-glibc/1.11.4/S9XX-TEST/clean.sh (nonexistent)
+++ products/S9XX-glibc/1.11.4/S9XX-TEST/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/S9XX-glibc/1.11.4/S9XX-TEST/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/S9XX-glibc/1.11.4/S9XX-TEST/main.c
===================================================================
--- products/S9XX-glibc/1.11.4/S9XX-TEST/main.c (nonexistent)
+++ products/S9XX-glibc/1.11.4/S9XX-TEST/main.c (revision 76)
@@ -0,0 +1,17 @@
+
+//#include <stdlib.h>
+//#include <inttypes.h>
+
+int main()
+{
+ float d, f = 3.1415;
+
+// uint32_t a = 7, b = 3, c, r;
+
+// c = a / b;
+// r = a % b;
+
+ d = f * 2.1;
+
+ return( 0 );
+}
Index: products/S9XX-glibc/1.11.4/S9XX-TEST
===================================================================
--- products/S9XX-glibc/1.11.4/S9XX-TEST (nonexistent)
+++ products/S9XX-glibc/1.11.4/S9XX-TEST (revision 76)
Property changes on: products/S9XX-glibc/1.11.4/S9XX-TEST
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/S9XX-glibc/1.11.4
===================================================================
--- products/S9XX-glibc/1.11.4 (nonexistent)
+++ products/S9XX-glibc/1.11.4 (revision 76)
Property changes on: products/S9XX-glibc/1.11.4
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/S9XX-newlib/1.11.3/S9XX-TEST-lp64/main.c
===================================================================
--- products/S9XX-newlib/1.11.3/S9XX-TEST-lp64/main.c (revision 75)
+++ products/S9XX-newlib/1.11.3/S9XX-TEST-lp64/main.c (nonexistent)
@@ -1,13 +0,0 @@
-
-#include <stdlib.h>
-#include <inttypes.h>
-
-int main()
-{
- uint32_t a = 7, b = 3, c, r;
-
- c = a / b;
- r = a % b;
-
- return( 0 );
-}
Index: products/S9XX-newlib/1.11.3/S9XX-TEST-lp64/build.sh
===================================================================
--- products/S9XX-newlib/1.11.3/S9XX-TEST-lp64/build.sh (revision 75)
+++ products/S9XX-newlib/1.11.3/S9XX-TEST-lp64/build.sh (nonexistent)
@@ -1,20 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-DEBUG_FLAGS="-gdwarf-2"
-ARCH_FLAGS="-march=armv8-a -mcpu=cortex-a53 -mabi=lp64 -mlittle-endian"
-
-$TARGET-gcc -g $DEBUG_FLAGS $ARCH_FLAGS -fomit-frame-pointer -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-$TARGET-gcc $DEBUG_FLAGS $ARCH_FLAGS -o main main.o -lc -lm -lnosys -lrdimon
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/S9XX-newlib/1.11.3/S9XX-TEST-lp64/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/S9XX-newlib/1.11.3/S9XX-TEST-lp64/.config
===================================================================
--- products/S9XX-newlib/1.11.3/S9XX-TEST-lp64/.config (revision 75)
+++ products/S9XX-newlib/1.11.3/S9XX-TEST-lp64/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=aarch64-s9xx-elf
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/aarch64-S9XX-elf-newlib/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/S9XX-newlib/1.11.3/S9XX-TEST-lp64/clean.sh
===================================================================
--- products/S9XX-newlib/1.11.3/S9XX-TEST-lp64/clean.sh (revision 75)
+++ products/S9XX-newlib/1.11.3/S9XX-TEST-lp64/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/S9XX-newlib/1.11.3/S9XX-TEST-lp64/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/S9XX-newlib/1.11.3/S9XX-TEST-lp64
===================================================================
--- products/S9XX-newlib/1.11.3/S9XX-TEST-lp64 (revision 75)
+++ products/S9XX-newlib/1.11.3/S9XX-TEST-lp64 (nonexistent)
Property changes on: products/S9XX-newlib/1.11.3/S9XX-TEST-lp64
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/S9XX-newlib/1.11.3/S9XX-TEST-ilp32/main.c
===================================================================
--- products/S9XX-newlib/1.11.3/S9XX-TEST-ilp32/main.c (revision 75)
+++ products/S9XX-newlib/1.11.3/S9XX-TEST-ilp32/main.c (nonexistent)
@@ -1,13 +0,0 @@
-
-#include <stdlib.h>
-#include <inttypes.h>
-
-int main()
-{
- uint32_t a = 7, b = 3, c, r;
-
- c = a / b;
- r = a % b;
-
- return( 0 );
-}
Index: products/S9XX-newlib/1.11.3/S9XX-TEST-ilp32/build.sh
===================================================================
--- products/S9XX-newlib/1.11.3/S9XX-TEST-ilp32/build.sh (revision 75)
+++ products/S9XX-newlib/1.11.3/S9XX-TEST-ilp32/build.sh (nonexistent)
@@ -1,20 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-DEBUG_FLAGS="-gdwarf-2"
-ARCH_FLAGS="-march=armv8-a -mcpu=cortex-a53 -mabi=ilp32 -mlittle-endian"
-
-$TARGET-gcc -g $DEBUG_FLAGS $ARCH_FLAGS -fomit-frame-pointer -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
-$TARGET-gcc $DEBUG_FLAGS $ARCH_FLAGS -o main main.o -lc -lm -lnosys -lrdimon
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/S9XX-newlib/1.11.3/S9XX-TEST-ilp32/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/S9XX-newlib/1.11.3/S9XX-TEST-ilp32/.config
===================================================================
--- products/S9XX-newlib/1.11.3/S9XX-TEST-ilp32/.config (revision 75)
+++ products/S9XX-newlib/1.11.3/S9XX-TEST-ilp32/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=aarch64-s9xx-elf
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/aarch64-S9XX-elf-newlib/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/S9XX-newlib/1.11.3/S9XX-TEST-ilp32/clean.sh
===================================================================
--- products/S9XX-newlib/1.11.3/S9XX-TEST-ilp32/clean.sh (revision 75)
+++ products/S9XX-newlib/1.11.3/S9XX-TEST-ilp32/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/S9XX-newlib/1.11.3/S9XX-TEST-ilp32/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/S9XX-newlib/1.11.3/S9XX-TEST-ilp32
===================================================================
--- products/S9XX-newlib/1.11.3/S9XX-TEST-ilp32 (revision 75)
+++ products/S9XX-newlib/1.11.3/S9XX-TEST-ilp32 (nonexistent)
Property changes on: products/S9XX-newlib/1.11.3/S9XX-TEST-ilp32
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/S9XX-newlib/1.11.3/Makefile
===================================================================
--- products/S9XX-newlib/1.11.3/Makefile (revision 75)
+++ products/S9XX-newlib/1.11.3/Makefile (nonexistent)
@@ -1,34 +0,0 @@
-
-
-COMPONENT_TARGETS = $(TOOLCHAIN_S9XX_NEWLIB)
-
-export TOOLCHAIN_VERSION = 1.11.3
-
-include ../../../build-system/config.mk
-
-REQUIRES = core/gcc/14.2.0^full
-REQUIRES += core/gdb/15.1
-
-# ======= __END_OF_REQUIRES__ =======
-
-tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
-tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
-
-tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
-
-BUILD_TARGETS = $(tarball_target)
-
-PRODUCT_TARGETS = $(tarball)
-
-include ../../../build-system/core.mk
-
-
-$(tarball): $(tarball_target)
-
-$(tarball_target):
- @echo ""
- @echo "Creating $(tarball_name) tarball..."
- @cd $(TOOLCHAINS_BASE_PATH) ; \
- tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
- @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
- @touch $@
Index: products/S9XX-newlib/1.11.3
===================================================================
--- products/S9XX-newlib/1.11.3 (revision 75)
+++ products/S9XX-newlib/1.11.3 (nonexistent)
Property changes on: products/S9XX-newlib/1.11.3
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/S9XX-newlib/1.11.4/Makefile
===================================================================
--- products/S9XX-newlib/1.11.4/Makefile (nonexistent)
+++ products/S9XX-newlib/1.11.4/Makefile (revision 76)
@@ -0,0 +1,34 @@
+
+
+COMPONENT_TARGETS = $(TOOLCHAIN_S9XX_NEWLIB)
+
+export TOOLCHAIN_VERSION = 1.11.4
+
+include ../../../build-system/config.mk
+
+REQUIRES = core/gcc/14.2.0^full
+REQUIRES += core/gdb/16.2
+
+# ======= __END_OF_REQUIRES__ =======
+
+tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
+tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
+
+tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
+
+BUILD_TARGETS = $(tarball_target)
+
+PRODUCT_TARGETS = $(tarball)
+
+include ../../../build-system/core.mk
+
+
+$(tarball): $(tarball_target)
+
+$(tarball_target):
+ @echo ""
+ @echo "Creating $(tarball_name) tarball..."
+ @cd $(TOOLCHAINS_BASE_PATH) ; \
+ tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
+ @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
+ @touch $@
Index: products/S9XX-newlib/1.11.4/S9XX-TEST-ilp32/.config
===================================================================
--- products/S9XX-newlib/1.11.4/S9XX-TEST-ilp32/.config (nonexistent)
+++ products/S9XX-newlib/1.11.4/S9XX-TEST-ilp32/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=aarch64-s9xx-elf
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/aarch64-S9XX-elf-newlib/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/S9XX-newlib/1.11.4/S9XX-TEST-ilp32/build.sh
===================================================================
--- products/S9XX-newlib/1.11.4/S9XX-TEST-ilp32/build.sh (nonexistent)
+++ products/S9XX-newlib/1.11.4/S9XX-TEST-ilp32/build.sh (revision 76)
@@ -0,0 +1,20 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+DEBUG_FLAGS="-gdwarf-2"
+ARCH_FLAGS="-march=armv8-a -mcpu=cortex-a53 -mabi=ilp32 -mlittle-endian"
+
+$TARGET-gcc -g $DEBUG_FLAGS $ARCH_FLAGS -fomit-frame-pointer -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+$TARGET-gcc $DEBUG_FLAGS $ARCH_FLAGS -o main main.o -lc -lm -lnosys -lrdimon
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/S9XX-newlib/1.11.4/S9XX-TEST-ilp32/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/S9XX-newlib/1.11.4/S9XX-TEST-ilp32/clean.sh
===================================================================
--- products/S9XX-newlib/1.11.4/S9XX-TEST-ilp32/clean.sh (nonexistent)
+++ products/S9XX-newlib/1.11.4/S9XX-TEST-ilp32/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/S9XX-newlib/1.11.4/S9XX-TEST-ilp32/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/S9XX-newlib/1.11.4/S9XX-TEST-ilp32/main.c
===================================================================
--- products/S9XX-newlib/1.11.4/S9XX-TEST-ilp32/main.c (nonexistent)
+++ products/S9XX-newlib/1.11.4/S9XX-TEST-ilp32/main.c (revision 76)
@@ -0,0 +1,13 @@
+
+#include <stdlib.h>
+#include <inttypes.h>
+
+int main()
+{
+ uint32_t a = 7, b = 3, c, r;
+
+ c = a / b;
+ r = a % b;
+
+ return( 0 );
+}
Index: products/S9XX-newlib/1.11.4/S9XX-TEST-ilp32
===================================================================
--- products/S9XX-newlib/1.11.4/S9XX-TEST-ilp32 (nonexistent)
+++ products/S9XX-newlib/1.11.4/S9XX-TEST-ilp32 (revision 76)
Property changes on: products/S9XX-newlib/1.11.4/S9XX-TEST-ilp32
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/S9XX-newlib/1.11.4/S9XX-TEST-lp64/.config
===================================================================
--- products/S9XX-newlib/1.11.4/S9XX-TEST-lp64/.config (nonexistent)
+++ products/S9XX-newlib/1.11.4/S9XX-TEST-lp64/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=aarch64-s9xx-elf
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/aarch64-S9XX-elf-newlib/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/S9XX-newlib/1.11.4/S9XX-TEST-lp64/build.sh
===================================================================
--- products/S9XX-newlib/1.11.4/S9XX-TEST-lp64/build.sh (nonexistent)
+++ products/S9XX-newlib/1.11.4/S9XX-TEST-lp64/build.sh (revision 76)
@@ -0,0 +1,20 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+DEBUG_FLAGS="-gdwarf-2"
+ARCH_FLAGS="-march=armv8-a -mcpu=cortex-a53 -mabi=lp64 -mlittle-endian"
+
+$TARGET-gcc -g $DEBUG_FLAGS $ARCH_FLAGS -fomit-frame-pointer -I$TOOLCHAIN_PATH/$TARGET/include -c -o main.o main.c
+$TARGET-gcc $DEBUG_FLAGS $ARCH_FLAGS -o main main.o -lc -lm -lnosys -lrdimon
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/S9XX-newlib/1.11.4/S9XX-TEST-lp64/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/S9XX-newlib/1.11.4/S9XX-TEST-lp64/clean.sh
===================================================================
--- products/S9XX-newlib/1.11.4/S9XX-TEST-lp64/clean.sh (nonexistent)
+++ products/S9XX-newlib/1.11.4/S9XX-TEST-lp64/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/S9XX-newlib/1.11.4/S9XX-TEST-lp64/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/S9XX-newlib/1.11.4/S9XX-TEST-lp64/main.c
===================================================================
--- products/S9XX-newlib/1.11.4/S9XX-TEST-lp64/main.c (nonexistent)
+++ products/S9XX-newlib/1.11.4/S9XX-TEST-lp64/main.c (revision 76)
@@ -0,0 +1,13 @@
+
+#include <stdlib.h>
+#include <inttypes.h>
+
+int main()
+{
+ uint32_t a = 7, b = 3, c, r;
+
+ c = a / b;
+ r = a % b;
+
+ return( 0 );
+}
Index: products/S9XX-newlib/1.11.4/S9XX-TEST-lp64
===================================================================
--- products/S9XX-newlib/1.11.4/S9XX-TEST-lp64 (nonexistent)
+++ products/S9XX-newlib/1.11.4/S9XX-TEST-lp64 (revision 76)
Property changes on: products/S9XX-newlib/1.11.4/S9XX-TEST-lp64
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/S9XX-newlib/1.11.4
===================================================================
--- products/S9XX-newlib/1.11.4 (nonexistent)
+++ products/S9XX-newlib/1.11.4 (revision 76)
Property changes on: products/S9XX-newlib/1.11.4
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/X86_64-glibc/1.11.3/X86_64-TEST-go/build.sh
===================================================================
--- products/X86_64-glibc/1.11.3/X86_64-TEST-go/build.sh (revision 75)
+++ products/X86_64-glibc/1.11.3/X86_64-TEST-go/build.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-#
-# Build:
-#
-$TOOLCHAIN_PATH/bin/$TARGET-gccgo -v -g -o main main.go
Property changes on: products/X86_64-glibc/1.11.3/X86_64-TEST-go/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/X86_64-glibc/1.11.3/X86_64-TEST-go/run.sh
===================================================================
--- products/X86_64-glibc/1.11.3/X86_64-TEST-go/run.sh (revision 75)
+++ products/X86_64-glibc/1.11.3/X86_64-TEST-go/run.sh (nonexistent)
@@ -1,14 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-#
-# Run:
-#
-if [ -x ./main ] ; then
- $TOOLCHAIN_PATH/$TARGET/sys-root/lib/ld-linux-x86-64.so.2 \
- --library-path $TOOLCHAIN_PATH/$TARGET/lib:$TOOLCHAIN_PATH/$TARGET/sys-root/lib:$TOOLCHAIN_PATH/$TARGET/sys-root/usr/lib \
- ./main
-fi
Property changes on: products/X86_64-glibc/1.11.3/X86_64-TEST-go/run.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/X86_64-glibc/1.11.3/X86_64-TEST-go/main.go
===================================================================
--- products/X86_64-glibc/1.11.3/X86_64-TEST-go/main.go (revision 75)
+++ products/X86_64-glibc/1.11.3/X86_64-TEST-go/main.go (nonexistent)
@@ -1,8 +0,0 @@
-
-package main
-
-import "fmt"
-
-func main() {
- fmt.Println("Hello, World!")
-}
Index: products/X86_64-glibc/1.11.3/X86_64-TEST-go/.config
===================================================================
--- products/X86_64-glibc/1.11.3/X86_64-TEST-go/.config (revision 75)
+++ products/X86_64-glibc/1.11.3/X86_64-TEST-go/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=x86_64-radix-linux-gnu
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/x86_64-PC-linux-glibc/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/X86_64-glibc/1.11.3/X86_64-TEST-go/clean.sh
===================================================================
--- products/X86_64-glibc/1.11.3/X86_64-TEST-go/clean.sh (revision 75)
+++ products/X86_64-glibc/1.11.3/X86_64-TEST-go/clean.sh (nonexistent)
@@ -1,3 +0,0 @@
-#!/bin/bash
-
-rm -f main
Property changes on: products/X86_64-glibc/1.11.3/X86_64-TEST-go/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/X86_64-glibc/1.11.3/X86_64-TEST/main.c
===================================================================
--- products/X86_64-glibc/1.11.3/X86_64-TEST/main.c (revision 75)
+++ products/X86_64-glibc/1.11.3/X86_64-TEST/main.c (nonexistent)
@@ -1,19 +0,0 @@
-
-#include <stdlib.h>
-#include <stdio.h>
-#include <inttypes.h>
-
-int main()
-{
- uint32_t a = 7, b = 3, c, r;
- double y, x = 3.5;
-
- y = x + 2.8;
-
- c = a / b;
- r = a % b;
-
- printf("\nHello, World!\n\n");
-
- return( 0 );
-}
Index: products/X86_64-glibc/1.11.3/X86_64-TEST/build.sh
===================================================================
--- products/X86_64-glibc/1.11.3/X86_64-TEST/build.sh (revision 75)
+++ products/X86_64-glibc/1.11.3/X86_64-TEST/build.sh (nonexistent)
@@ -1,17 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-$TARGET-gcc -g -gdwarf-2 -fomit-frame-pointer -I$TOOLCHAIN_PATH/$TARGET/sys-root/usr/include -c -o main.o main.c
-$TARGET-gcc -o main main.o
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/X86_64-glibc/1.11.3/X86_64-TEST/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/X86_64-glibc/1.11.3/X86_64-TEST/32/main.c
===================================================================
--- products/X86_64-glibc/1.11.3/X86_64-TEST/32/main.c (revision 75)
+++ products/X86_64-glibc/1.11.3/X86_64-TEST/32/main.c (nonexistent)
@@ -1,19 +0,0 @@
-
-#include <stdlib.h>
-#include <stdio.h>
-#include <inttypes.h>
-
-int main()
-{
- uint32_t a = 7, b = 3, c, r;
- double y, x = 3.5;
-
- y = x + 2.8;
-
- c = a / b;
- r = a % b;
-
- printf("\nHello, World!\n\n");
-
- return( 0 );
-}
Index: products/X86_64-glibc/1.11.3/X86_64-TEST/32/build.sh
===================================================================
--- products/X86_64-glibc/1.11.3/X86_64-TEST/32/build.sh (revision 75)
+++ products/X86_64-glibc/1.11.3/X86_64-TEST/32/build.sh (nonexistent)
@@ -1,17 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-$TARGET-gcc -m32 -g -gdwarf-2 -fomit-frame-pointer -I$TOOLCHAIN_PATH/$TARGET/sys-root/usr/include -c -o main.o main.c
-$TARGET-gcc -m32 -o main main.o
-
-$TARGET-objdump -x main > main.map
-
-$TARGET-strip main -o main.elf
-
-$TARGET-objcopy -O srec main.elf main.srec
-$TARGET-objcopy -O ihex main.elf main.hex
-$TARGET-objdump -S -d main.o > main.asm
-$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/X86_64-glibc/1.11.3/X86_64-TEST/32/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/X86_64-glibc/1.11.3/X86_64-TEST/32/.config
===================================================================
--- products/X86_64-glibc/1.11.3/X86_64-TEST/32/.config (revision 75)
+++ products/X86_64-glibc/1.11.3/X86_64-TEST/32/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=x86_64-radix-linux-gnu
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/x86_64-PC-linux-glibc/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/X86_64-glibc/1.11.3/X86_64-TEST/32/clean.sh
===================================================================
--- products/X86_64-glibc/1.11.3/X86_64-TEST/32/clean.sh (revision 75)
+++ products/X86_64-glibc/1.11.3/X86_64-TEST/32/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/X86_64-glibc/1.11.3/X86_64-TEST/32/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/X86_64-glibc/1.11.3/X86_64-TEST/32
===================================================================
--- products/X86_64-glibc/1.11.3/X86_64-TEST/32 (revision 75)
+++ products/X86_64-glibc/1.11.3/X86_64-TEST/32 (nonexistent)
Property changes on: products/X86_64-glibc/1.11.3/X86_64-TEST/32
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/X86_64-glibc/1.11.3/X86_64-TEST/.config
===================================================================
--- products/X86_64-glibc/1.11.3/X86_64-TEST/.config (revision 75)
+++ products/X86_64-glibc/1.11.3/X86_64-TEST/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=x86_64-radix-linux-gnu
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/x86_64-PC-linux-glibc/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/X86_64-glibc/1.11.3/X86_64-TEST/clean.sh
===================================================================
--- products/X86_64-glibc/1.11.3/X86_64-TEST/clean.sh (revision 75)
+++ products/X86_64-glibc/1.11.3/X86_64-TEST/clean.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-rm -f full.program.asm
-rm -f main
-rm -f main.asm
-rm -f main.elf
-rm -f main.hex
-rm -f main.map
-rm -f main.o
-rm -f main.srec
Property changes on: products/X86_64-glibc/1.11.3/X86_64-TEST/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/X86_64-glibc/1.11.3/X86_64-TEST
===================================================================
--- products/X86_64-glibc/1.11.3/X86_64-TEST (revision 75)
+++ products/X86_64-glibc/1.11.3/X86_64-TEST (nonexistent)
Property changes on: products/X86_64-glibc/1.11.3/X86_64-TEST
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/X86_64-glibc/1.11.3/X86_64-TEST-modula2/build.sh
===================================================================
--- products/X86_64-glibc/1.11.3/X86_64-TEST-modula2/build.sh (revision 75)
+++ products/X86_64-glibc/1.11.3/X86_64-TEST-modula2/build.sh (nonexistent)
@@ -1,10 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-#
-# Build:
-#
-$TOOLCHAIN_PATH/bin/$TARGET-gm2 -v -g -o main main.mod
Property changes on: products/X86_64-glibc/1.11.3/X86_64-TEST-modula2/build.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/X86_64-glibc/1.11.3/X86_64-TEST-modula2/run.sh
===================================================================
--- products/X86_64-glibc/1.11.3/X86_64-TEST-modula2/run.sh (revision 75)
+++ products/X86_64-glibc/1.11.3/X86_64-TEST-modula2/run.sh (nonexistent)
@@ -1,14 +0,0 @@
-#!/bin/bash
-
-. ./.config
-
-export PATH=$TOOLCHAIN_PATH/bin:$PATH
-
-#
-# Run:
-#
-if [ -x ./main ] ; then
- $TOOLCHAIN_PATH/$TARGET/sys-root/lib/ld-linux-x86-64.so.2 \
- --library-path $TOOLCHAIN_PATH/$TARGET/lib:$TOOLCHAIN_PATH/$TARGET/sys-root/lib:$TOOLCHAIN_PATH/$TARGET/sys-root/usr/lib \
- ./main
-fi
Property changes on: products/X86_64-glibc/1.11.3/X86_64-TEST-modula2/run.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/X86_64-glibc/1.11.3/X86_64-TEST-modula2/main.mod
===================================================================
--- products/X86_64-glibc/1.11.3/X86_64-TEST-modula2/main.mod (revision 75)
+++ products/X86_64-glibc/1.11.3/X86_64-TEST-modula2/main.mod (nonexistent)
@@ -1,8 +0,0 @@
-
-MODULE hello ;
-
-FROM StrIO IMPORT WriteString, WriteLn ;
-
-BEGIN
- WriteString ('hello world') ; WriteLn
-END hello.
Index: products/X86_64-glibc/1.11.3/X86_64-TEST-modula2/.config
===================================================================
--- products/X86_64-glibc/1.11.3/X86_64-TEST-modula2/.config (revision 75)
+++ products/X86_64-glibc/1.11.3/X86_64-TEST-modula2/.config (nonexistent)
@@ -1,22 +0,0 @@
-#!/bin/bash
-
-#################################################################
-#
-# default common variables:
-#
-if test -z "$HOST"; then
- export HOST=x86_64-pc-linux-gnu
-fi
-
-if test -z "$TARGET"; then
- export TARGET=x86_64-radix-linux-gnu
-fi
-
-if test -z "$TOOLCHAIN_PATH"; then
- export TOOLCHAIN_PATH=/opt/toolchains/x86_64-PC-linux-glibc/1.11.3
-fi
-
-#
-# END of default common variables.
-#
-#################################################################
Index: products/X86_64-glibc/1.11.3/X86_64-TEST-modula2/clean.sh
===================================================================
--- products/X86_64-glibc/1.11.3/X86_64-TEST-modula2/clean.sh (revision 75)
+++ products/X86_64-glibc/1.11.3/X86_64-TEST-modula2/clean.sh (nonexistent)
@@ -1,3 +0,0 @@
-#!/bin/bash
-
-rm -f main
Property changes on: products/X86_64-glibc/1.11.3/X86_64-TEST-modula2/clean.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: products/X86_64-glibc/1.11.3/Makefile
===================================================================
--- products/X86_64-glibc/1.11.3/Makefile (revision 75)
+++ products/X86_64-glibc/1.11.3/Makefile (nonexistent)
@@ -1,35 +0,0 @@
-
-
-COMPONENT_TARGETS = $(TOOLCHAIN_X86_64_GLIBC)
-
-export TOOLCHAIN_VERSION = 1.11.3
-
-include ../../../build-system/config.mk
-
-REQUIRES = core/gcc/14.2.0^full
-REQUIRES += tools/patchelf/0.18.0
-REQUIRES += core/gdb/15.1
-
-# ======= __END_OF_REQUIRES__ =======
-
-tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
-tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
-
-tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
-
-BUILD_TARGETS = $(tarball_target)
-
-PRODUCT_TARGETS = $(tarball)
-
-include ../../../build-system/core.mk
-
-
-$(tarball): $(tarball_target)
-
-$(tarball_target):
- @echo ""
- @echo "Creating $(tarball_name) tarball..."
- @cd $(TOOLCHAINS_BASE_PATH) ; \
- tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
- @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
- @touch $@
Index: products/X86_64-glibc/1.11.3
===================================================================
--- products/X86_64-glibc/1.11.3 (revision 75)
+++ products/X86_64-glibc/1.11.3 (nonexistent)
Property changes on: products/X86_64-glibc/1.11.3
___________________________________________________________________
Deleted: svn:ignore
## -1,80 +0,0 ##
-
-# Target build dirs
-.noarch
-.host
-
-.arm32-newlib
-.a33xx-newlib
-.a9xx-newlib
-.h5-newlib
-.s9xx-newlib
-.rk33xx-newlib
-.m1000-newlib
-.riscv64-newlib
-.at91sam7s-newlib
-
-.a1x-glibc
-.a2x-glibc
-.a311x-glibc
-.h3-glibc
-.h5-glibc
-.imx6-glibc
-.imx6ull-glibc
-.jz47xx-glibc
-.p5600-glibc
-.m1000-glibc
-.omap543x-glibc
-.am335x-glibc
-.rk328x-glibc
-.s8xx-glibc
-.s9xx-glibc
-.a9xx-glibc
-.rk33xx-glibc
-.rk339x-glibc
-.a33xx-glibc
-.power8-glibc
-.power9-glibc
-.power8le-glibc
-.power9le-glibc
-.riscv64-glibc
-.i586-glibc
-.i686-glibc
-.x86_64-glibc
-
-# Hidden files (each file)
-.makefile
-.src_requires
-.src_requires_depend
-.dist
-
-# Destinations
-dist
-
-
-# Tarballs
-*.gz
-*.bz2
-*.xz
-*.tgz
-*.txz
-
-# Signatures
-*.asc
-*.sig
-*.sign
-*.sha1sum
-
-# Patches
-*.patch
-
-# Text files
-*.txt
-
-# Default linux config files
-*.defconfig
-
-# Object Files
-*.[ao]
-
-# backup copies
-*~
Index: products/X86_64-glibc/1.11.4/Makefile
===================================================================
--- products/X86_64-glibc/1.11.4/Makefile (nonexistent)
+++ products/X86_64-glibc/1.11.4/Makefile (revision 76)
@@ -0,0 +1,35 @@
+
+
+COMPONENT_TARGETS = $(TOOLCHAIN_X86_64_GLIBC)
+
+export TOOLCHAIN_VERSION = 1.11.4
+
+include ../../../build-system/config.mk
+
+REQUIRES = core/gcc/14.2.0^full
+REQUIRES += tools/patchelf/0.18.0
+REQUIRES += core/gdb/16.2
+
+# ======= __END_OF_REQUIRES__ =======
+
+tarball_name = $(TOOLCHAIN_DIR)-$(TOOLCHAIN_VERSION).tar.xz
+tarball = $(TARGET_BUILD_DIR)/$(tarball_name)
+
+tarball_target = $(TARGET_BUILD_DIR)/.tarball-created
+
+BUILD_TARGETS = $(tarball_target)
+
+PRODUCT_TARGETS = $(tarball)
+
+include ../../../build-system/core.mk
+
+
+$(tarball): $(tarball_target)
+
+$(tarball_target):
+ @echo ""
+ @echo "Creating $(tarball_name) tarball..."
+ @cd $(TOOLCHAINS_BASE_PATH) ; \
+ tar -cf - $(TOOLCHAIN_DIR)/$(TOOLCHAIN_VERSION) | xz --threads=0 > $(tarball_name)
+ @mv $(TOOLCHAINS_BASE_PATH)/$(tarball_name) $(TARGET_BUILD_DIR)
+ @touch $@
Index: products/X86_64-glibc/1.11.4/X86_64-TEST/.config
===================================================================
--- products/X86_64-glibc/1.11.4/X86_64-TEST/.config (nonexistent)
+++ products/X86_64-glibc/1.11.4/X86_64-TEST/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=x86_64-radix-linux-gnu
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/x86_64-PC-linux-glibc/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/X86_64-glibc/1.11.4/X86_64-TEST/32/.config
===================================================================
--- products/X86_64-glibc/1.11.4/X86_64-TEST/32/.config (nonexistent)
+++ products/X86_64-glibc/1.11.4/X86_64-TEST/32/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=x86_64-radix-linux-gnu
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/x86_64-PC-linux-glibc/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/X86_64-glibc/1.11.4/X86_64-TEST/32/build.sh
===================================================================
--- products/X86_64-glibc/1.11.4/X86_64-TEST/32/build.sh (nonexistent)
+++ products/X86_64-glibc/1.11.4/X86_64-TEST/32/build.sh (revision 76)
@@ -0,0 +1,17 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+$TARGET-gcc -m32 -g -gdwarf-2 -fomit-frame-pointer -I$TOOLCHAIN_PATH/$TARGET/sys-root/usr/include -c -o main.o main.c
+$TARGET-gcc -m32 -o main main.o
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/X86_64-glibc/1.11.4/X86_64-TEST/32/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/X86_64-glibc/1.11.4/X86_64-TEST/32/clean.sh
===================================================================
--- products/X86_64-glibc/1.11.4/X86_64-TEST/32/clean.sh (nonexistent)
+++ products/X86_64-glibc/1.11.4/X86_64-TEST/32/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/X86_64-glibc/1.11.4/X86_64-TEST/32/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/X86_64-glibc/1.11.4/X86_64-TEST/32/main.c
===================================================================
--- products/X86_64-glibc/1.11.4/X86_64-TEST/32/main.c (nonexistent)
+++ products/X86_64-glibc/1.11.4/X86_64-TEST/32/main.c (revision 76)
@@ -0,0 +1,19 @@
+
+#include <stdlib.h>
+#include <stdio.h>
+#include <inttypes.h>
+
+int main()
+{
+ uint32_t a = 7, b = 3, c, r;
+ double y, x = 3.5;
+
+ y = x + 2.8;
+
+ c = a / b;
+ r = a % b;
+
+ printf("\nHello, World!\n\n");
+
+ return( 0 );
+}
Index: products/X86_64-glibc/1.11.4/X86_64-TEST/32
===================================================================
--- products/X86_64-glibc/1.11.4/X86_64-TEST/32 (nonexistent)
+++ products/X86_64-glibc/1.11.4/X86_64-TEST/32 (revision 76)
Property changes on: products/X86_64-glibc/1.11.4/X86_64-TEST/32
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/X86_64-glibc/1.11.4/X86_64-TEST/build.sh
===================================================================
--- products/X86_64-glibc/1.11.4/X86_64-TEST/build.sh (nonexistent)
+++ products/X86_64-glibc/1.11.4/X86_64-TEST/build.sh (revision 76)
@@ -0,0 +1,17 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+$TARGET-gcc -g -gdwarf-2 -fomit-frame-pointer -I$TOOLCHAIN_PATH/$TARGET/sys-root/usr/include -c -o main.o main.c
+$TARGET-gcc -o main main.o
+
+$TARGET-objdump -x main > main.map
+
+$TARGET-strip main -o main.elf
+
+$TARGET-objcopy -O srec main.elf main.srec
+$TARGET-objcopy -O ihex main.elf main.hex
+$TARGET-objdump -S -d main.o > main.asm
+$TARGET-objdump -S -d main > full.program.asm
Property changes on: products/X86_64-glibc/1.11.4/X86_64-TEST/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/X86_64-glibc/1.11.4/X86_64-TEST/clean.sh
===================================================================
--- products/X86_64-glibc/1.11.4/X86_64-TEST/clean.sh (nonexistent)
+++ products/X86_64-glibc/1.11.4/X86_64-TEST/clean.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+rm -f full.program.asm
+rm -f main
+rm -f main.asm
+rm -f main.elf
+rm -f main.hex
+rm -f main.map
+rm -f main.o
+rm -f main.srec
Property changes on: products/X86_64-glibc/1.11.4/X86_64-TEST/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/X86_64-glibc/1.11.4/X86_64-TEST/main.c
===================================================================
--- products/X86_64-glibc/1.11.4/X86_64-TEST/main.c (nonexistent)
+++ products/X86_64-glibc/1.11.4/X86_64-TEST/main.c (revision 76)
@@ -0,0 +1,19 @@
+
+#include <stdlib.h>
+#include <stdio.h>
+#include <inttypes.h>
+
+int main()
+{
+ uint32_t a = 7, b = 3, c, r;
+ double y, x = 3.5;
+
+ y = x + 2.8;
+
+ c = a / b;
+ r = a % b;
+
+ printf("\nHello, World!\n\n");
+
+ return( 0 );
+}
Index: products/X86_64-glibc/1.11.4/X86_64-TEST
===================================================================
--- products/X86_64-glibc/1.11.4/X86_64-TEST (nonexistent)
+++ products/X86_64-glibc/1.11.4/X86_64-TEST (revision 76)
Property changes on: products/X86_64-glibc/1.11.4/X86_64-TEST
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: products/X86_64-glibc/1.11.4/X86_64-TEST-go/.config
===================================================================
--- products/X86_64-glibc/1.11.4/X86_64-TEST-go/.config (nonexistent)
+++ products/X86_64-glibc/1.11.4/X86_64-TEST-go/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=x86_64-radix-linux-gnu
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/x86_64-PC-linux-glibc/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/X86_64-glibc/1.11.4/X86_64-TEST-go/build.sh
===================================================================
--- products/X86_64-glibc/1.11.4/X86_64-TEST-go/build.sh (nonexistent)
+++ products/X86_64-glibc/1.11.4/X86_64-TEST-go/build.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+#
+# Build:
+#
+$TOOLCHAIN_PATH/bin/$TARGET-gccgo -v -g -o main main.go
Property changes on: products/X86_64-glibc/1.11.4/X86_64-TEST-go/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/X86_64-glibc/1.11.4/X86_64-TEST-go/clean.sh
===================================================================
--- products/X86_64-glibc/1.11.4/X86_64-TEST-go/clean.sh (nonexistent)
+++ products/X86_64-glibc/1.11.4/X86_64-TEST-go/clean.sh (revision 76)
@@ -0,0 +1,3 @@
+#!/bin/bash
+
+rm -f main
Property changes on: products/X86_64-glibc/1.11.4/X86_64-TEST-go/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/X86_64-glibc/1.11.4/X86_64-TEST-go/main.go
===================================================================
--- products/X86_64-glibc/1.11.4/X86_64-TEST-go/main.go (nonexistent)
+++ products/X86_64-glibc/1.11.4/X86_64-TEST-go/main.go (revision 76)
@@ -0,0 +1,8 @@
+
+package main
+
+import "fmt"
+
+func main() {
+ fmt.Println("Hello, World!")
+}
Index: products/X86_64-glibc/1.11.4/X86_64-TEST-go/run.sh
===================================================================
--- products/X86_64-glibc/1.11.4/X86_64-TEST-go/run.sh (nonexistent)
+++ products/X86_64-glibc/1.11.4/X86_64-TEST-go/run.sh (revision 76)
@@ -0,0 +1,14 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+#
+# Run:
+#
+if [ -x ./main ] ; then
+ $TOOLCHAIN_PATH/$TARGET/sys-root/lib/ld-linux-x86-64.so.2 \
+ --library-path $TOOLCHAIN_PATH/$TARGET/lib:$TOOLCHAIN_PATH/$TARGET/sys-root/lib:$TOOLCHAIN_PATH/$TARGET/sys-root/usr/lib \
+ ./main
+fi
Property changes on: products/X86_64-glibc/1.11.4/X86_64-TEST-go/run.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/X86_64-glibc/1.11.4/X86_64-TEST-modula2/.config
===================================================================
--- products/X86_64-glibc/1.11.4/X86_64-TEST-modula2/.config (nonexistent)
+++ products/X86_64-glibc/1.11.4/X86_64-TEST-modula2/.config (revision 76)
@@ -0,0 +1,22 @@
+#!/bin/bash
+
+#################################################################
+#
+# default common variables:
+#
+if test -z "$HOST"; then
+ export HOST=x86_64-pc-linux-gnu
+fi
+
+if test -z "$TARGET"; then
+ export TARGET=x86_64-radix-linux-gnu
+fi
+
+if test -z "$TOOLCHAIN_PATH"; then
+ export TOOLCHAIN_PATH=/opt/toolchains/x86_64-PC-linux-glibc/1.11.4
+fi
+
+#
+# END of default common variables.
+#
+#################################################################
Index: products/X86_64-glibc/1.11.4/X86_64-TEST-modula2/build.sh
===================================================================
--- products/X86_64-glibc/1.11.4/X86_64-TEST-modula2/build.sh (nonexistent)
+++ products/X86_64-glibc/1.11.4/X86_64-TEST-modula2/build.sh (revision 76)
@@ -0,0 +1,10 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+#
+# Build:
+#
+$TOOLCHAIN_PATH/bin/$TARGET-gm2 -v -g -o main main.mod
Property changes on: products/X86_64-glibc/1.11.4/X86_64-TEST-modula2/build.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/X86_64-glibc/1.11.4/X86_64-TEST-modula2/clean.sh
===================================================================
--- products/X86_64-glibc/1.11.4/X86_64-TEST-modula2/clean.sh (nonexistent)
+++ products/X86_64-glibc/1.11.4/X86_64-TEST-modula2/clean.sh (revision 76)
@@ -0,0 +1,3 @@
+#!/bin/bash
+
+rm -f main
Property changes on: products/X86_64-glibc/1.11.4/X86_64-TEST-modula2/clean.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/X86_64-glibc/1.11.4/X86_64-TEST-modula2/main.mod
===================================================================
--- products/X86_64-glibc/1.11.4/X86_64-TEST-modula2/main.mod (nonexistent)
+++ products/X86_64-glibc/1.11.4/X86_64-TEST-modula2/main.mod (revision 76)
@@ -0,0 +1,8 @@
+
+MODULE hello ;
+
+FROM StrIO IMPORT WriteString, WriteLn ;
+
+BEGIN
+ WriteString ('hello world') ; WriteLn
+END hello.
Index: products/X86_64-glibc/1.11.4/X86_64-TEST-modula2/run.sh
===================================================================
--- products/X86_64-glibc/1.11.4/X86_64-TEST-modula2/run.sh (nonexistent)
+++ products/X86_64-glibc/1.11.4/X86_64-TEST-modula2/run.sh (revision 76)
@@ -0,0 +1,14 @@
+#!/bin/bash
+
+. ./.config
+
+export PATH=$TOOLCHAIN_PATH/bin:$PATH
+
+#
+# Run:
+#
+if [ -x ./main ] ; then
+ $TOOLCHAIN_PATH/$TARGET/sys-root/lib/ld-linux-x86-64.so.2 \
+ --library-path $TOOLCHAIN_PATH/$TARGET/lib:$TOOLCHAIN_PATH/$TARGET/sys-root/lib:$TOOLCHAIN_PATH/$TARGET/sys-root/usr/lib \
+ ./main
+fi
Property changes on: products/X86_64-glibc/1.11.4/X86_64-TEST-modula2/run.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: products/X86_64-glibc/1.11.4
===================================================================
--- products/X86_64-glibc/1.11.4 (nonexistent)
+++ products/X86_64-glibc/1.11.4 (revision 76)
Property changes on: products/X86_64-glibc/1.11.4
___________________________________________________________________
Added: svn:ignore
## -0,0 +1,80 ##
+
+# Target build dirs
+.noarch
+.host
+
+.arm32-newlib
+.a33xx-newlib
+.a9xx-newlib
+.h5-newlib
+.s9xx-newlib
+.rk33xx-newlib
+.m1000-newlib
+.riscv64-newlib
+.at91sam7s-newlib
+
+.a1x-glibc
+.a2x-glibc
+.a311x-glibc
+.h3-glibc
+.h5-glibc
+.imx6-glibc
+.imx6ull-glibc
+.jz47xx-glibc
+.p5600-glibc
+.m1000-glibc
+.omap543x-glibc
+.am335x-glibc
+.rk328x-glibc
+.s8xx-glibc
+.s9xx-glibc
+.a9xx-glibc
+.rk33xx-glibc
+.rk339x-glibc
+.a33xx-glibc
+.power8-glibc
+.power9-glibc
+.power8le-glibc
+.power9le-glibc
+.riscv64-glibc
+.i586-glibc
+.i686-glibc
+.x86_64-glibc
+
+# Hidden files (each file)
+.makefile
+.src_requires
+.src_requires_depend
+.dist
+
+# Destinations
+dist
+
+
+# Tarballs
+*.gz
+*.bz2
+*.xz
+*.tgz
+*.txz
+
+# Signatures
+*.asc
+*.sig
+*.sign
+*.sha1sum
+
+# Patches
+*.patch
+
+# Text files
+*.txt
+
+# Default linux config files
+*.defconfig
+
+# Object Files
+*.[ao]
+
+# backup copies
+*~
Index: sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/file.list
===================================================================
--- sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/file.list (revision 75)
+++ sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/file.list (nonexistent)
@@ -1,26 +0,0 @@
-binutils-2.43.1/ld/testsuite/ld-elfvers/vers24.rd
-binutils-2.43.1/ld/testsuite/ld-plugin/plugin-10.d
-binutils-2.43.1/ld/testsuite/ld-plugin/plugin-11.d
-binutils-2.43.1/ld/testsuite/ld-plugin/plugin-13.d
-binutils-2.43.1/ld/testsuite/ld-plugin/plugin-14.d
-binutils-2.43.1/ld/testsuite/ld-plugin/plugin-15.d
-binutils-2.43.1/ld/testsuite/ld-plugin/plugin-16.d
-binutils-2.43.1/ld/testsuite/ld-plugin/plugin-17.d
-binutils-2.43.1/ld/testsuite/ld-plugin/plugin-18.d
-binutils-2.43.1/ld/testsuite/ld-plugin/plugin-19.d
-binutils-2.43.1/ld/testsuite/ld-plugin/plugin-20.d
-binutils-2.43.1/ld/testsuite/ld-plugin/plugin-21.d
-binutils-2.43.1/ld/testsuite/ld-plugin/plugin-22.d
-binutils-2.43.1/ld/testsuite/ld-plugin/plugin-23.d
-binutils-2.43.1/ld/testsuite/ld-plugin/plugin-24.d
-binutils-2.43.1/ld/testsuite/ld-plugin/plugin-25.d
-binutils-2.43.1/ld/testsuite/ld-plugin/plugin-28.d
-binutils-2.43.1/ld/testsuite/ld-plugin/plugin-29.d
-binutils-2.43.1/ld/testsuite/ld-plugin/plugin-30.d
-binutils-2.43.1/ld/testsuite/ld-plugin/plugin-6.d
-binutils-2.43.1/ld/testsuite/ld-plugin/plugin-7.d
-binutils-2.43.1/ld/testsuite/ld-plugin/plugin-8.d
-binutils-2.43.1/ld/testsuite/ld-plugin/plugin-9.d
-binutils-2.43.1/ld/testsuite/ld-plugin/plugin.exp
-binutils-2.43.1/ld/testsuite/ld-plugin/pr20070.d
-binutils-2.43.1/ld/testsuite/ld-srec/srec.exp
Index: sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/create.patch.sh
===================================================================
--- sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/create.patch.sh (revision 75)
+++ sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/create.patch.sh (nonexistent)
@@ -1,15 +0,0 @@
-#!/bin/bash
-
-VERSION=2.43.1
-
-tar --files-from=file.list -xJvf ../binutils-$VERSION.tar.xz
-mv binutils-$VERSION binutils-$VERSION-orig
-
-cp -rf ./binutils-$VERSION-new ./binutils-$VERSION
-
-diff --unified -Nr binutils-$VERSION-orig binutils-$VERSION > binutils-$VERSION-testsuite-failures.patch
-
-mv binutils-$VERSION-testsuite-failures.patch ../patches
-
-rm -rf ./binutils-$VERSION
-rm -rf ./binutils-$VERSION-orig
Property changes on: sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/create.patch.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-srec/srec.exp
===================================================================
--- sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-srec/srec.exp (revision 75)
+++ sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-srec/srec.exp (nonexistent)
@@ -1,490 +0,0 @@
-# Test linking directly to S-records.
-# By Ian Lance Taylor, Cygnus Support.
-# Copyright (C) 1999-2024 Free Software Foundation, Inc.
-#
-# This file is part of the GNU Binutils.
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 3 of the License, or
-# (at your option) any later version.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this program; if not, write to the Free Software
-# Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston,
-# MA 02110-1301, USA.
-
-# Get the offset from an S-record line to the start of the data.
-
-return
-
-proc srec_off { l } {
- if [string match "S1*" $l] {
- return 8
- } else { if [string match "S2*" $l] {
- return 10
- } else { if [string match "S3*" $l] {
- return 12
- } else {
- return -1
- } } }
-}
-
-# See if an S-record line contains only zero data.
-
-proc srec_zero { l } {
- if [string match "S\[0789\]*" $l] {
- return 1
- }
-
- # Strip the address and checksum.
- if [string match "S\[123\]*" $l] {
- set l [string range $l [srec_off $l] [expr [string length $l] - 3]]
- } else {
- return 0
- }
-
- # The rest must be zero.
- return [string match "" [string trim $l "0"]]
-}
-
-# Get the address of an S-record line.
-
-proc srec_addr { l } {
- if [string match "S\[123\]*" $l] {
- set addr [string range $l 4 [expr [srec_off $l] - 1]]
- } else {
- return -1
- }
-
- return "0x$addr"
-}
-
-# Get the number of data bytes in an S-record line.
-
-proc srec_len { l } {
- if ![string match "S\[123\]*" $l] {
- return 0
- }
-
- return [expr "0x[string range $l 2 3]" - ([srec_off $l] - 4) / 2 - 1]
-}
-
-# Extract bytes from an S-record line.
-
-proc srec_extract { l start len } {
- set off [srec_off $l]
- set rlen [srec_len $l]
- set stop [expr $start + $len]
- if { $stop > $rlen } {
- set stop [expr $rlen]
- }
- set start [expr $start * 2 + $off]
- set stop [expr $stop * 2 + $off - 1]
- return [string range $l $start $stop]
-}
-
-# See if a range of bytes in an S-record line is all zeroes.
-
-proc srec_zero_range { l start len } {
- return [string match "" [string trim [srec_extract $l $start $len] "0"]]
-}
-
-# Trim an S-record line such that the specified number of bytes remain
-# at the end.
-
-proc srec_trim { l leave } {
- set off [srec_off $l]
- set addr [srec_addr $l]
- set len [srec_len $l]
-
- if { $leave >= $len } {
- return $l
- }
-
- set s1 [string range $l 0 1]
- set s2 [format "%02x" [expr ($off - 4) / 2 + $leave + 1]]
- set s3 [format "%0[expr $off - 4]x" [expr $addr + $len - $leave]]
- set s4 [string range $l [expr [string length $l] - ($leave * 2) - 2] end]
- set s "${s1}${s2}${s3}${s4}"
-
- verbose "srec_trim { '$l' $leave } returning '$s'" 2
-
- return $s
-}
-
-# Report failure when comparing S-record lines
-
-proc srec_compare_fail { which l1 l2 } {
- send_log "comparison failure $which:\n$l1\n$l2\n"
- verbose "comparison failure $which:\n$l1\n$l2"
-}
-
-# Compare S-record files. We don't want to fuss about things like
-# extra zeroes. Note that BFD always sorts S-records by address.
-
-proc srec_compare { f1 f2 } {
- set e1 [gets $f1 l1]
- set e2 [gets $f2 l2]
-
- while { $e1 != -1 } {
- set l1 [string trimright $l1 "\r\n"]
- set l2 [string trimright $l2 "\r\n"]
- if { $e2 == -1 } {
- # If l1 contains data, it must be zero.
- if ![srec_zero $l1] {
- send_log "data after EOF: $l1\n"
- verbose "data after EOF: $l1"
- return 0
- }
- } else { if { [string compare $l1 $l2] == 0 } {
- set e1 [gets $f1 l1]
- set e2 [gets $f2 l2]
- } else { if { [srec_zero $l1] } {
- set e1 [gets $f1 l1]
- } else { if { [srec_zero $l2] } {
- set e2 [gets $f2 l2]
- } else {
- # The strings are not the same, and neither is all zeroes.
- set a1 [srec_addr $l1]
- set n1 [srec_len $l1]
- set a2 [srec_addr $l2]
- set n2 [srec_len $l2]
-
- if { $a1 < $a2 && ![srec_zero_range $l1 0 [expr $a2 - $a1]] } {
- verbose "$a1 $a2 [srec_extract $l1 0 [expr $a2 - $a1]]" 2
- srec_compare_fail 1 $l1 $l2
- return 0
- }
- if { $a2 < $a1 && ![srec_zero_range $l2 0 [expr $a1 - $a2]] } {
- srec_compare_fail 2 $l1 $l2
- return 0
- }
-
- # Here we know that any initial data in both lines is
- # zero. Now make sure that any overlapping data matches.
- if { $a1 < $a2 } {
- set os1 [expr $a2 - $a1]
- set os2 0
- } else {
- set os1 0
- set os2 [expr $a1 - $a2]
- }
- if { $a1 + $n1 < $a2 + $n2 } {
- set ol [expr $n1 - $os1]
- } else {
- set ol [expr $n2 - $os2]
- }
-
- set x1 [srec_extract $l1 $os1 $ol]
- set x2 [srec_extract $l2 $os2 $ol]
- if { [string compare $x1 $x2] != 0 } {
- verbose "$os1 $ol $x1" 2
- verbose "$os2 $ol $x2" 2
- srec_compare_fail 3 $l1 $l2
- return 0
- }
-
- # These strings match. Trim the data from the larger
- # string, read a new copy of the smaller string, and
- # continue.
- if { $a1 + $n1 < $a2 + $n2 } {
- set l2 [srec_trim $l2 [expr ($a2 + $n2) - ($a1 + $n1)]]
- set e1 [gets $f1 l1]
- } else { if { $a1 + $n1 > $a2 + $n2 } {
- set l1 [srec_trim $l1 [expr ($a1 + $n1) - ($a2 + $n2)]]
- set e2 [gets $f2 l2]
- } else {
- set e1 [gets $f1 l1]
- set e2 [gets $f2 l2]
- } }
- } } } }
- }
-
- # We've reached the end of the first file. The remainder of the
- # second file must contain only zeroes.
- while { $e2 != -1 } {
- set l2 [string trimright $l2 "\r\n"]
- if ![srec_zero $l2] {
- send_log "data after EOF: $l2\n"
- verbose "data after EOF: $l2"
- return 0
- }
- set e2 [gets $f2 l2]
- }
-
- return 1
-}
-
-# Link twice, objcopy, and compare
-
-proc run_srec_test { test objs } {
- global ld
- global objcopy
- global sizeof_headers
- global host_triplet
-
- # Tell the ELF linker to not do anything clever with .eh_frame,
- # not to put anything in small data, and define various symbols.
- set flags "--traditional-format -G 0 -e 0 "
- append flags [ld_link_defsyms]
-
- # If the linker script uses SIZEOF_HEADERS, use a -Ttext argument
- # to force both the normal link and the S-record link to be put in
- # the same place. We don't always use -Ttext because it interacts
- # poorly with a.out.
-
- if { $sizeof_headers } {
- append flags " -Ttext 0x1000"
- if [is_pecoff_format] {
- append flags " --image-base 0"
- }
- }
-
- # ARM targets cannot convert format in the linker
- # using the --oformat command line switch
- if {[istarget aarch64*-*-*] || \
- [istarget arm*-*-*]} {
- setup_xfail "aarch64-*-*"
- setup_xfail "aarch64_be-*-*"
- setup_xfail "arm*-*-*"
- }
-
- # The AVR target does not correctly process
- # relocs when output format is not ELF.
- if [istarget avr-*-*] {
- setup_xfail "avr-*-*"
- }
-
- # Epiphany needs some help too
- if [istarget epiphany*-*-*] {
- set flags "$flags --defsym _start=00000060"
- setup_xfail "epiphany*-*-*"
- }
-
- if [istarget m681*-*-*] {
- set flags "$flags --defsym _start=0xc000"
- setup_xfail "m681*-*-*"
- }
-
- if [istarget m68hc1*-*-*] {
- set flags "$flags --defsym _start=0xc000"
- setup_xfail "m68hc1*-*-*"
- }
-
- if [istarget m9s12x*-*-*] {
- set flags "$flags --defsym _start=0xc000"
- setup_xfail "m9s12x*-*-*"
- }
-
- # MSP430 targets always relax.
- if [istarget msp430*-*-*] {
- setup_xfail "msp430*-*-*"
- }
-
- # The RISC-V target does not correctly process
- # relocs when output format is not ELF.
- if [istarget riscv*-*-*] {
- setup_xfail "riscv*-*-*"
- }
-
- # LoongArch targets cannot convert format in the linker
- # using the --oformat command line switch
- if [istarget loongarch*-*-*] {
- setup_xfail "loongarch*-*-*"
- }
-
- # V850 targets need libgcc.a
- if [istarget v850*-*-elf] {
- set objs "$objs -L ../gcc -lgcc"
- }
-
- # Xtensa ELF targets relax by default; S-Record linker does not
- if [istarget xtensa*-*-*] {
- append flags " -no-relax"
- }
-
- # PRU ELF target relaxes by default; S-Record linker does not
- if [istarget pru*-*-*] {
- append flags " -no-relax"
- }
-
- if { ![ld_link $ld tmpdir/sr1 "$flags $objs"] \
- || ![ld_link $ld tmpdir/sr2.sr "$flags --oformat srec $objs"] } {
- fail $test
- return
- }
-
- send_log "$objcopy -O srec tmpdir/sr1 tmpdir/sr1.sr\n"
- set exec_output [run_host_cmd "$objcopy" "-O srec tmpdir/sr1 tmpdir/sr1.sr"]
- set exec_output [prune_warnings $exec_output]
- if ![string match "" $exec_output] {
- send_log "$exec_output\n"
- verbose "$exec_output"
- fail $test
- return
- }
-
- set f1 [open tmpdir/sr1.sr r]
- set f2 [open tmpdir/sr2.sr r]
- if [srec_compare $f1 $f2] {
- pass $test
- } else {
- fail $test
- }
- close $f1
- close $f2
-}
-
-set test1 "S-records"
-set test2 "S-records with constructors"
-
-# See whether the default linker script uses SIZEOF_HEADERS.
-set exec_output [run_host_cmd "$ld" "--verbose"]
-set sizeof_headers [string match "*SIZEOF_HEADERS*" $exec_output]
-
-# First test linking a C program. We don't require any libraries. We
-# link it normally, and objcopy to the S-record format, and then link
-# directly to the S-record format, and require that the two files
-# contain the same data.
-
-if { ![check_compiler_available] } {
- untested $test1
- untested $test2
- return
-}
-
-# Pass -fplt to CC and CXX since -fno-plt doesn't work with S-records
-# tests. Also add $NOPIE_CFLAGS and $NOPIE_LDFLAGS if PIE doesn't work
-# with S-records. Also add $NOCF_PROTECTION_CFLAGS for S-records.
-# Also add $NOSANITIZE_CFLAGS for S-records.
-set old_CFLAGS "$CFLAGS_FOR_TARGET"
-append CFLAGS_FOR_TARGET " $PLT_CFLAGS $NOPIE_CFLAGS $NOPIE_LDFLAGS $NOCF_PROTECTION_CFLAGS $NOSANITIZE_CFLAGS $NOLTO_CFLAGS"
-set old_CXXFLAGS "$CXXFLAGS_FOR_TARGET"
-append CXXFLAGS_FOR_TARGET " $PLT_CFLAGS $NOPIE_CFLAGS $NOPIE_LDFLAGS $NOCF_PROTECTION_CFLAGS $NOSANITIZE_CFLAGS $NOLTO_CFLAGS"
-
-# S-records can't handle .note.gnu.property sections.
-if { [is_elf_format] \
- && ([istarget "i?86-*-*"] || [istarget "x86_64-*-*"]) } {
- append CFLAGS_FOR_TARGET " -Wa,-mx86-used-note=no"
- append CXXFLAGS_FOR_TARGET " -Wa,-mx86-used-note=no"
-}
-
-if { ![ld_compile $CC_FOR_TARGET $srcdir/$subdir/sr1.c tmpdir/sr1.o] \
- || ![ld_compile $CC_FOR_TARGET $srcdir/$subdir/sr2.c tmpdir/sr2.o] } {
- unsupported $test1
- unsupported $test2
- set CFLAGS_FOR_TARGET "$old_CFLAGS"
- set CXXFLAGS_FOR_TARGET "$old_CXXFLAGS"
- return
-}
-
-# The i386-aout target is confused: the linker does not put the
-# sections where objdump finds them. I don't know which is wrong.
-setup_xfail "i*86-*-aout*"
-
-# These tests fail on the native MIPS ELF targets because the GP value
-# in the .reginfo section is not updated when the S-record version is
-# written out. The mips-elf target itself does not use a .reginfo section.
-setup_xfail "mips*-*-irix5*" "mips*-*-irix6*" "mips*-*-linux*"
-
-# The S-record linker doesn't do the magic TOC handling that XCOFF
-# linkers do.
-if [is_xcoff_format] {
- setup_xfail *-*-*
-}
-
-# The S-record linker is not supported for ARC.
-setup_xfail "arc*-*-*"
-
-# The S-record linker doesn't build ARM/Thumb stubs.
-setup_xfail "arm-*-coff"
-setup_xfail "arm-*-pe*"
-# setup_xfail "arm-*elf*"
-setup_xfail "arm*-*-linux*"
-
-# The S-record linker doesn't include the .{zda} sections.
-setup_xfail "v850*-*-elf"
-
-# The S-record linker doesn't handle Alpha Elf relaxation.
-setup_xfail "alpha*-*-elf*" "alpha*-*-linux-*" "alpha*-*-gnu*"
-setup_xfail "alpha*-*-netbsd*"
-
-# The S-record linker hasn't any hope of coping with HPPA relocs.
-# Or MeP complex relocs.
-setup_xfail "hppa*-*-*" "mep-*-*"
-
-# The S-record linker doesn't handle IA64 Elf relaxation.
-setup_xfail "ia64-*-*"
-
-# The S-record linker doesn't support the special PE headers - the PE
-# emulation tries to write pe-specific information to the PE headers
-# in the output bfd, but it's not a PE bfd (it's an srec bfd)
-setup_xfail "*-*-cygwin*" "*-*-mingw*" "*-*-pe*" "*-*-winnt*"
-setup_xfail "score-*-*"
-
-# The S-record linker doesn't support Blackfin ELF FDPIC ABI.
-setup_xfail "bfin-*-linux-uclibc"
-
-# On tile, we appear to be getting some random-seeming zeroing or 24-bit
-# rightshifts (!) in the output when directly generating S-records from
-# the linker. Not clear what could be causing this but we don't
-# anticipate creating s-records (and could always use objcopy to
-# generate the format if need be).
-setup_xfail "tile*-*-*"
-
-# The S-record linker is not supported for C-SKY.
-setup_xfail "csky*-*-*"
-
-# The S-record linker is not supported for eBPF.
-setup_xfail "bpf-*-*"
-
-run_srec_test $test1 "tmpdir/sr1.o tmpdir/sr2.o"
-
-# Now try linking a C++ program with global constructors and
-# destructors. Note that since we are not linking against any
-# libraries, this program won't actually work or anything.
-
-if { ![is_remote host] && [which $CXX_FOR_TARGET] == 0 } {
- untested $test2
- set CFLAGS_FOR_TARGET "$old_CFLAGS"
- set CXXFLAGS_FOR_TARGET "$old_CXXFLAGS"
- return
-}
-
-if ![ld_compile "$CXX_FOR_TARGET -fno-exceptions" $srcdir/$subdir/sr3.cc tmpdir/sr3.o] {
- unsupported $test2
- set CFLAGS_FOR_TARGET "$old_CFLAGS"
- set CXXFLAGS_FOR_TARGET "$old_CXXFLAGS"
- return
-}
-
-# See above.
-setup_xfail "i*86-*-aout*"
-setup_xfail "mips*-*-irix5*" "mips*-*-irix6*" "mips*-*-linux*"
-if [is_xcoff_format] {
- setup_xfail *-*-*
-}
-setup_xfail "arc*-*-*"
-setup_xfail "arm*-*-*"
-setup_xfail "v850*-*-elf"
-setup_xfail "alpha*-*-elf*" "alpha*-*-linux-*" "alpha*-*-gnu*"
-setup_xfail "alpha*-*-netbsd*"
-setup_xfail "hppa*-*-*" "mep-*-*"
-setup_xfail "ia64-*-*"
-setup_xfail "*-*-cygwin*" "*-*-mingw*" "*-*-pe*" "*-*-winnt*"
-setup_xfail "score-*-*"
-setup_xfail "bfin-*-linux-uclibc"
-setup_xfail "tile*-*-*"
-setup_xfail "csky*-*-*"
-setup_xfail "bpf-*-*"
-
-run_srec_test $test2 "tmpdir/sr3.o"
-
-set CFLAGS_FOR_TARGET "$old_CFLAGS"
-set CXXFLAGS_FOR_TARGET "$old_CXXFLAGS"
Index: sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-elfvers/vers24.rd
===================================================================
--- sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-elfvers/vers24.rd (revision 75)
+++ sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-elfvers/vers24.rd (nonexistent)
@@ -1,15 +0,0 @@
-Relocation section .*
-# Ensure there is a dynamic relocation against x
-#...
-[0-9a-f]+ +[0-9a-f]+ R_.* +_?x@VERS.0(| \+ 0)
-#...
-Symbol table '.dynsym' contains [0-9]+ entries:
-# And ensure the dynamic symbol table contains at least x@VERS.0
-# and foo@@VERS.0 symbols
-#...
- +[0-9]+: [0-9a-f]+ +(4 +OBJECT +GLOBAL +DEFAULT +[0-9]+ _?x|[0-9]+ +FUNC +GLOBAL +DEFAULT .* [0-9]+ _?foo@)@VERS\.0.*
-#...
- +[0-9]+: [0-9a-f]+ +(4 +OBJECT +GLOBAL +DEFAULT +[0-9]+ _?x|[0-9]+ +FUNC +GLOBAL +DEFAULT .* [0-9]+ _?foo@)@VERS\.0.*
-#...
-Symbol table '.symtab' contains [0-9]+ entries:
-#pass
Index: sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-30.d
===================================================================
--- sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-30.d (revision 75)
+++ sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-30.d (nonexistent)
@@ -1,28 +0,0 @@
-Hello from testplugin.
-.*: LDPT_MESSAGE func@0x.*
-.*: LDPT_API_VERSION value 0x1 \(1\)
-.*: LDPT_GNU_LD_VERSION value 0x.*
-.*: LDPT_LINKER_OUTPUT value 0x1 \(1\)
-.*: LDPT_OUTPUT_NAME 'tmpdir/main.x'
-.*: LDPT_REGISTER_CLAIM_FILE_HOOK func@0x.*
-.*: LDPT_REGISTER_CLAIM_FILE_HOOK_V2 func@0x.*
-.*: LDPT_REGISTER_ALL_SYMBOLS_READ_HOOK func@0x.*
-.*: LDPT_REGISTER_CLEANUP_HOOK func@0x.*
-.*: LDPT_ADD_SYMBOLS func@0x.*
-.*: LDPT_GET_INPUT_FILE func@0x.*
-.*: LDPT_GET_VIEW func@0x.*
-.*: LDPT_RELEASE_INPUT_FILE func@0x.*
-.*: LDPT_GET_SYMBOLS func@0x.*
-.*: LDPT_GET_SYMBOLS_V2 func@0x.*
-.*: LDPT_ADD_INPUT_FILE func@0x.*
-.*: LDPT_ADD_INPUT_LIBRARY func@0x.*
-.*: LDPT_SET_EXTRA_LIBRARY_PATH func@0x.*
-.*: LDPT_OPTION 'registerclaimfile'
-.*: LDPT_OPTION 'read:8'
-.*: LDPT_NULL value 0x0 \(0\)
-#...
-hook called: claim_file tmpdir/main.o \[@0/.* not claimed
-hook called: claim_file tmpdir/func.o \[@0/.* not claimed
-hook called: claim_file tmpdir/text.o \[@0/.* not claimed
-hook called: claim_file tmpdir/libempty.a \[@.* not claimed
-#pass
Index: sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-10.d
===================================================================
--- sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-10.d (revision 75)
+++ sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-10.d (nonexistent)
@@ -1,40 +0,0 @@
-Hello from testplugin.
-.*: LDPT_MESSAGE func@0x.*
-.*: LDPT_API_VERSION value 0x1 \(1\)
-.*: LDPT_GNU_LD_VERSION value 0x.*
-.*: LDPT_LINKER_OUTPUT value 0x1 \(1\)
-.*: LDPT_OUTPUT_NAME 'tmpdir/main.x'
-.*: LDPT_REGISTER_CLAIM_FILE_HOOK func@0x.*
-.*: LDPT_REGISTER_CLAIM_FILE_HOOK_V2 func@0x.*
-.*: LDPT_REGISTER_ALL_SYMBOLS_READ_HOOK func@0x.*
-.*: LDPT_REGISTER_CLEANUP_HOOK func@0x.*
-.*: LDPT_ADD_SYMBOLS func@0x.*
-.*: LDPT_GET_INPUT_FILE func@0x.*
-.*: LDPT_GET_VIEW func@0x.*
-.*: LDPT_RELEASE_INPUT_FILE func@0x.*
-.*: LDPT_GET_SYMBOLS func@0x.*
-.*: LDPT_GET_SYMBOLS_V2 func@0x.*
-.*: LDPT_ADD_INPUT_FILE func@0x.*
-.*: LDPT_ADD_INPUT_LIBRARY func@0x.*
-.*: LDPT_SET_EXTRA_LIBRARY_PATH func@0x.*
-.*: LDPT_OPTION 'registerclaimfile'
-.*: LDPT_OPTION 'registerallsymbolsread'
-.*: LDPT_OPTION 'registercleanup'
-.*: LDPT_OPTION 'claim:tmpdir/func.o'
-.*: LDPT_OPTION 'sym:_?func::0:0:0'
-.*: LDPT_OPTION 'sym:_?func2::0:0:0'
-.*: LDPT_OPTION 'dumpresolutions'
-.*: LDPT_OPTION 'add:tmpdir/func.o'
-.*: LDPT_NULL value 0x0 \(0\)
-#...
-hook called: claim_file tmpdir/main.o \[@0/.* not claimed
-hook called: claim_file tmpdir/func.o \[@0/.* CLAIMED
-#...
-hook called: claim_file tmpdir[/\\]libtext.a \[@.* not claimed
-#...
-hook called: all symbols read.
-Sym: '_?func' Resolution: LDPR_PREVAILING_DEF_IRONLY
-Sym: '_?func2' Resolution: LDPR_PREVAILING_DEF_IRONLY
-#...
-hook called: cleanup.
-#...
Index: sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-20.d
===================================================================
--- sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-20.d (revision 75)
+++ sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-20.d (nonexistent)
@@ -1,6 +0,0 @@
-hook called: all symbols read.
-Input: func.c \(tmpdir[/\\]libfunc.a\)
-Sym: '_?func' Resolution: LDPR_PREVAILING_DEF.*
-Sym: '_?func' Resolution: LDPR_PREVAILING_DEF.*
-#...
-hook called: cleanup.
Index: sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-11.d
===================================================================
--- sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-11.d (revision 75)
+++ sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-11.d (nonexistent)
@@ -1,44 +0,0 @@
-Hello from testplugin.
-.*: LDPT_MESSAGE func@0x.*
-.*: LDPT_API_VERSION value 0x1 \(1\)
-.*: LDPT_GNU_LD_VERSION value 0x.*
-.*: LDPT_LINKER_OUTPUT value 0x1 \(1\)
-.*: LDPT_OUTPUT_NAME 'tmpdir/main.x'
-.*: LDPT_REGISTER_CLAIM_FILE_HOOK func@0x.*
-.*: LDPT_REGISTER_CLAIM_FILE_HOOK_V2 func@0x.*
-.*: LDPT_REGISTER_ALL_SYMBOLS_READ_HOOK func@0x.*
-.*: LDPT_REGISTER_CLEANUP_HOOK func@0x.*
-.*: LDPT_ADD_SYMBOLS func@0x.*
-.*: LDPT_GET_INPUT_FILE func@0x.*
-.*: LDPT_GET_VIEW func@0x.*
-.*: LDPT_RELEASE_INPUT_FILE func@0x.*
-.*: LDPT_GET_SYMBOLS func@0x.*
-.*: LDPT_GET_SYMBOLS_V2 func@0x.*
-.*: LDPT_ADD_INPUT_FILE func@0x.*
-.*: LDPT_ADD_INPUT_LIBRARY func@0x.*
-.*: LDPT_SET_EXTRA_LIBRARY_PATH func@0x.*
-.*: LDPT_OPTION 'registerclaimfile'
-.*: LDPT_OPTION 'registerallsymbolsread'
-.*: LDPT_OPTION 'registercleanup'
-.*: LDPT_OPTION 'claim:tmpdir/func.o'
-.*: LDPT_OPTION 'sym:_?func::0:0:0'
-.*: LDPT_OPTION 'sym:_?func2::0:0:0'
-.*: LDPT_OPTION 'dumpresolutions'
-.*: LDPT_OPTION 'add:tmpdir/func.o'
-.*: LDPT_OPTION 'claim:tmpdir/libtext.a'
-.*: LDPT_OPTION 'sym:_?text::0:0:0'
-.*: LDPT_OPTION 'add:tmpdir/text.o'
-.*: LDPT_NULL value 0x0 \(0\)
-#...
-hook called: claim_file tmpdir/main.o \[@0/.* not claimed
-hook called: claim_file tmpdir/func.o \[@0/.* CLAIMED
-#...
-hook called: claim_file tmpdir[/\\]libtext.a \[@.* CLAIMED
-#...
-hook called: all symbols read.
-Sym: '_?func' Resolution: LDPR_PREVAILING_DEF_IRONLY
-Sym: '_?func2' Resolution: LDPR_PREVAILING_DEF_IRONLY
-Sym: '_?text' Resolution: LDPR_PREVAILING_DEF_IRONLY
-#...
-hook called: cleanup.
-#...
Index: sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-21.d
===================================================================
--- sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-21.d (revision 75)
+++ sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-21.d (nonexistent)
@@ -1,6 +0,0 @@
-hook called: all symbols read.
-Input: .*/ld/testsuite/ld-plugin/func.c \(.*/ld/testsuite/ld-plugin/func.c\)
-Sym: '_?func' Resolution: LDPR_PREVAILING_DEF.*
-Sym: '_?func' Resolution: LDPR_PREVAILING_DEF.*
-#...
-hook called: cleanup.
Index: sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-22.d
===================================================================
--- sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-22.d (revision 75)
+++ sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-22.d (nonexistent)
@@ -1,6 +0,0 @@
-Claimed: tmpdir[/\\]libfunc.a \[@.*
-hook called: all symbols read.
-Sym: '_?func' Resolution: LDPR_PREVAILING_DEF.*
-Sym: '_?func' Resolution: LDPR_PREVAILING_DEF.*
-#...
-hook called: cleanup.
Index: sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-13.d
===================================================================
--- sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-13.d (revision 75)
+++ sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-13.d (nonexistent)
@@ -1,26 +0,0 @@
-Hello from testplugin.
-.*: LDPT_MESSAGE func@0x.*
-.*: LDPT_API_VERSION value 0x1 \(1\)
-.*: LDPT_GNU_LD_VERSION value 0x.*
-.*: LDPT_LINKER_OUTPUT value 0x1 \(1\)
-.*: LDPT_OUTPUT_NAME 'tmpdir/main.x'
-.*: LDPT_REGISTER_CLAIM_FILE_HOOK func@0x.*
-.*: LDPT_REGISTER_CLAIM_FILE_HOOK_V2 func@0x.*
-.*: LDPT_REGISTER_ALL_SYMBOLS_READ_HOOK func@0x.*
-.*: LDPT_REGISTER_CLEANUP_HOOK func@0x.*
-.*: LDPT_ADD_SYMBOLS func@0x.*
-.*: LDPT_GET_INPUT_FILE func@0x.*
-.*: LDPT_GET_VIEW func@0x.*
-.*: LDPT_RELEASE_INPUT_FILE func@0x.*
-.*: LDPT_GET_SYMBOLS func@0x.*
-.*: LDPT_GET_SYMBOLS_V2 func@0x.*
-.*: LDPT_ADD_INPUT_FILE func@0x.*
-.*: LDPT_ADD_INPUT_LIBRARY func@0x.*
-.*: LDPT_SET_EXTRA_LIBRARY_PATH func@0x.*
-.*: LDPT_OPTION 'registerclaimfile'
-.*: LDPT_OPTION 'claim:.*/ld/testsuite/ld-plugin/func.c'
-.*: LDPT_NULL value 0x0 \(0\)
-hook called: claim_file tmpdir/main.o \[@0/.* not claimed
-hook called: claim_file .*/ld/testsuite/ld-plugin/func.c \[@0/.* CLAIMED
-hook called: claim_file tmpdir/text.o \[@0/.* not claimed
-#...
Index: sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-23.d
===================================================================
--- sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-23.d (revision 75)
+++ sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-23.d (nonexistent)
@@ -1,6 +0,0 @@
-Claimed: .*/ld/testsuite/ld-plugin/func.c \[@0.*
-hook called: all symbols read.
-Sym: '_?func' Resolution: LDPR_PREVAILING_DEF.*
-Sym: '_?func' Resolution: LDPR_PREVAILING_DEF.*
-#...
-hook called: cleanup.
Index: sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-14.d
===================================================================
--- sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-14.d (revision 75)
+++ sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-14.d (nonexistent)
@@ -1,33 +0,0 @@
-Hello from testplugin.
-.*: LDPT_MESSAGE func@0x.*
-.*: LDPT_API_VERSION value 0x1 \(1\)
-.*: LDPT_GNU_LD_VERSION value 0x.*
-.*: LDPT_LINKER_OUTPUT value 0x1 \(1\)
-.*: LDPT_OUTPUT_NAME 'tmpdir/main.x'
-.*: LDPT_REGISTER_CLAIM_FILE_HOOK func@0x.*
-.*: LDPT_REGISTER_CLAIM_FILE_HOOK_V2 func@0x.*
-.*: LDPT_REGISTER_ALL_SYMBOLS_READ_HOOK func@0x.*
-.*: LDPT_REGISTER_CLEANUP_HOOK func@0x.*
-.*: LDPT_ADD_SYMBOLS func@0x.*
-.*: LDPT_GET_INPUT_FILE func@0x.*
-.*: LDPT_GET_VIEW func@0x.*
-.*: LDPT_RELEASE_INPUT_FILE func@0x.*
-.*: LDPT_GET_SYMBOLS func@0x.*
-.*: LDPT_GET_SYMBOLS_V2 func@0x.*
-.*: LDPT_ADD_INPUT_FILE func@0x.*
-.*: LDPT_ADD_INPUT_LIBRARY func@0x.*
-.*: LDPT_SET_EXTRA_LIBRARY_PATH func@0x.*
-.*: LDPT_OPTION 'registerclaimfile'
-.*: LDPT_OPTION 'registerallsymbolsread'
-.*: LDPT_OPTION 'registercleanup'
-.*: LDPT_OPTION 'claim:.*/ld/testsuite/ld-plugin/func.c'
-.*: LDPT_NULL value 0x0 \(0\)
-#...
-hook called: claim_file tmpdir/main.o \[@0/.* not claimed
-hook called: claim_file .*/ld/testsuite/ld-plugin/func.c \[@0/.* CLAIMED
-hook called: claim_file tmpdir/text.o \[@0/.* not claimed
-#...
-hook called: all symbols read.
-#...
-hook called: cleanup.
-#...
Index: sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-24.d
===================================================================
--- sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-24.d (revision 75)
+++ sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-24.d (nonexistent)
@@ -1,6 +0,0 @@
-hook called: all symbols read.
-Input: .*/ld/testsuite/ld-plugin/func.c \(.*/ld/testsuite/ld-plugin/func.c\)
-Sym: '_?func' Resolution: LDPR_PREVAILING_DEF.*
-Sym: '_?func' Resolution: LDPR_PREVAILING_DEF.*
-#...
-hook called: cleanup.
Index: sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-15.d
===================================================================
--- sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-15.d (revision 75)
+++ sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-15.d (nonexistent)
@@ -1,34 +0,0 @@
-Hello from testplugin.
-.*: LDPT_MESSAGE func@0x.*
-.*: LDPT_API_VERSION value 0x1 \(1\)
-.*: LDPT_GNU_LD_VERSION value 0x.*
-.*: LDPT_LINKER_OUTPUT value 0x1 \(1\)
-.*: LDPT_OUTPUT_NAME 'tmpdir/main.x'
-.*: LDPT_REGISTER_CLAIM_FILE_HOOK func@0x.*
-.*: LDPT_REGISTER_CLAIM_FILE_HOOK_V2 func@0x.*
-.*: LDPT_REGISTER_ALL_SYMBOLS_READ_HOOK func@0x.*
-.*: LDPT_REGISTER_CLEANUP_HOOK func@0x.*
-.*: LDPT_ADD_SYMBOLS func@0x.*
-.*: LDPT_GET_INPUT_FILE func@0x.*
-.*: LDPT_GET_VIEW func@0x.*
-.*: LDPT_RELEASE_INPUT_FILE func@0x.*
-.*: LDPT_GET_SYMBOLS func@0x.*
-.*: LDPT_GET_SYMBOLS_V2 func@0x.*
-.*: LDPT_ADD_INPUT_FILE func@0x.*
-.*: LDPT_ADD_INPUT_LIBRARY func@0x.*
-.*: LDPT_SET_EXTRA_LIBRARY_PATH func@0x.*
-.*: LDPT_OPTION 'registerclaimfile'
-.*: LDPT_OPTION 'registerallsymbolsread'
-.*: LDPT_OPTION 'registercleanup'
-.*: LDPT_OPTION 'claim:.*/ld/testsuite/ld-plugin/func.c'
-.*: LDPT_OPTION 'sym:_?func::0:0:0'
-.*: LDPT_NULL value 0x0 \(0\)
-#...
-hook called: claim_file tmpdir/main.o \[@0/.* not claimed
-hook called: claim_file .*/ld/testsuite/ld-plugin/func.c \[@0/.* CLAIMED
-hook called: claim_file tmpdir/text.o \[@0/.* not claimed
-#...
-hook called: all symbols read.
-#...
-hook called: cleanup.
-#...
Index: sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-25.d
===================================================================
--- sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-25.d (revision 75)
+++ sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-25.d (nonexistent)
@@ -1,6 +0,0 @@
-Claimed: .*/ld/testsuite/ld-plugin/func.c \[@0.*
-hook called: all symbols read.
-Sym: '_?func' Resolution: LDPR_PREVAILING_DEF.*
-Sym: '_?func' Resolution: LDPR_PREVAILING_DEF.*
-#...
-hook called: cleanup.
Index: sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-16.d
===================================================================
--- sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-16.d (revision 75)
+++ sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-16.d (nonexistent)
@@ -1,38 +0,0 @@
-Hello from testplugin.
-.*: LDPT_MESSAGE func@0x.*
-.*: LDPT_API_VERSION value 0x1 \(1\)
-.*: LDPT_GNU_LD_VERSION value 0x.*
-.*: LDPT_LINKER_OUTPUT value 0x1 \(1\)
-.*: LDPT_OUTPUT_NAME 'tmpdir/main.x'
-.*: LDPT_REGISTER_CLAIM_FILE_HOOK func@0x.*
-.*: LDPT_REGISTER_CLAIM_FILE_HOOK_V2 func@0x.*
-.*: LDPT_REGISTER_ALL_SYMBOLS_READ_HOOK func@0x.*
-.*: LDPT_REGISTER_CLEANUP_HOOK func@0x.*
-.*: LDPT_ADD_SYMBOLS func@0x.*
-.*: LDPT_GET_INPUT_FILE func@0x.*
-.*: LDPT_GET_VIEW func@0x.*
-.*: LDPT_RELEASE_INPUT_FILE func@0x.*
-.*: LDPT_GET_SYMBOLS func@0x.*
-.*: LDPT_GET_SYMBOLS_V2 func@0x.*
-.*: LDPT_ADD_INPUT_FILE func@0x.*
-.*: LDPT_ADD_INPUT_LIBRARY func@0x.*
-.*: LDPT_SET_EXTRA_LIBRARY_PATH func@0x.*
-.*: LDPT_OPTION 'registerclaimfile'
-.*: LDPT_OPTION 'registerallsymbolsread'
-.*: LDPT_OPTION 'registercleanup'
-.*: LDPT_OPTION 'claim:.*/ld/testsuite/ld-plugin/func.c'
-.*: LDPT_OPTION 'sym:_?func::0:0:0'
-.*: LDPT_OPTION 'sym:_?func2::0:0:0'
-.*: LDPT_OPTION 'dumpresolutions'
-.*: LDPT_NULL value 0x0 \(0\)
-#...
-hook called: claim_file tmpdir/main.o \[@0/.* not claimed
-hook called: claim_file .*/ld/testsuite/ld-plugin/func.c \[@0/.* CLAIMED
-hook called: claim_file tmpdir/text.o \[@0/.* not claimed
-#...
-hook called: all symbols read.
-Sym: '_?func' Resolution: LDPR_PREVAILING_DEF_IRONLY
-Sym: '_?func2' Resolution: LDPR_PREVAILING_DEF_IRONLY
-#...
-hook called: cleanup.
-#...
Index: sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin.exp
===================================================================
--- sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin.exp (revision 75)
+++ sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin.exp (nonexistent)
@@ -1,403 +0,0 @@
-# Expect script for ld-plugin tests
-# Copyright (C) 2010-2024 Free Software Foundation, Inc.
-#
-# This file is part of the GNU Binutils.
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 3 of the License, or
-# (at your option) any later version.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this program; if not, write to the Free Software
-# Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston,
-# MA 02110-1301, USA.
-
-# These tests require the plugin API to be configured in.
-if ![check_plugin_api_available] {
- return
-}
-
-# And a compiler to be available.
-set can_compile 1
-if { ![check_compiler_available] } {
- # Don't fail immediately,
- set can_compile 0
-}
-
-pass "plugin API enabled"
-
-# Look for the name we can dlopen in the test plugin's libtool control script.
-set plugin_name [file_contents "$base_dir/libldtestplug.la"]
-set plugin_name [regsub "'.*" [regsub ".*dlname='" "$plugin_name" ""] ""]
-# Even though the API supports plugins it does not mean that the
-# linker was configured with --enable-plugins. Check for that here.
-if { $plugin_name == "" } {
- verbose "The linker is not configured to support plugins"
- return
-}
-verbose "plugin name is '$plugin_name'"
-
-set plugin2_name [file_contents "$base_dir/libldtestplug2.la"]
-set plugin2_name [regsub "'.*" [regsub ".*dlname='" "$plugin2_name" ""] ""]
-verbose "plugin2 name is '$plugin2_name'"
-
-set plugin3_name [file_contents "$base_dir/libldtestplug3.la"]
-set plugin3_name [regsub "'.*" [regsub ".*dlname='" "$plugin3_name" ""] ""]
-verbose "plugin3 name is '$plugin3_name'"
-
-set plugin4_name [file_contents "$base_dir/libldtestplug4.la"]
-set plugin4_name [regsub "'.*" [regsub ".*dlname='" "$plugin4_name" ""] ""]
-verbose "plugin4 name is '$plugin4_name'"
-
-# Use libtool to find full path to plugin rather than worrying
-# about run paths or anything like that.
-catch "exec $base_dir/libtool --config" lt_config
-verbose "Full lt config: $lt_config" 3
-# Look for "objdir=.libs"
-regexp -line "^objdir=.*$" "$lt_config" lt_objdir
-verbose "lt_objdir line is '$lt_objdir'" 3
-set lt_objdir [regsub "objdir=" "$lt_objdir" ""]
-set plugin_path "$base_dir/$lt_objdir/$plugin_name"
-set plugin2_path "$base_dir/$lt_objdir/$plugin2_name"
-set plugin3_path "$base_dir/$lt_objdir/$plugin3_name"
-set plugin4_path "$base_dir/$lt_objdir/$plugin4_name"
-verbose "Full plugin path $plugin_path" 2
-verbose "Full plugin2 path $plugin2_path" 2
-verbose "Full plugin3 path $plugin3_path" 2
-verbose "Full plugin4 path $plugin4_path" 2
-
-set regclm "-plugin-opt registerclaimfile"
-set regas "-plugin-opt registerallsymbolsread"
-set regassilent "-plugin-opt registerallsymbolsreadsilent"
-set regcln "-plugin-opt registercleanup"
-
-# In order to define symbols in plugin options in the list of tests below,
-# we need to know if the platform prepends an underscore to C symbols,
-# which we find out by compiling the test objects now. If there is any
-# error compiling, we defer reporting it until after the list of tests has
-# been initialised, so that we can use the names in the list to report;
-# otherwise, we scan one of the files with 'nm' and look for a known symbol
-# in the output to see if it is prefixed or not.
-set failed_compile 0
-set _ ""
-set plugin_nm_output ""
-set old_CFLAGS "$CFLAGS_FOR_TARGET"
-append CFLAGS_FOR_TARGET " $NOSANITIZE_CFLAGS $NOLTO_CFLAGS"
-if { [istarget m681*-*-*] || [istarget m68hc1*-*-*] || [istarget m9s12x*-*-*] } {
- # otherwise get FAILS due to _.frame
- append CFLAGS_FOR_TARGET " -fomit-frame-pointer"
-}
-
-if { $can_compile && \
- (![ld_compile $CC_FOR_TARGET $srcdir/$subdir/main.c tmpdir/main.o] \
- || ![ld_compile $CC_FOR_TARGET $srcdir/$subdir/func.c tmpdir/func.o] \
- || ![ld_compile $CC_FOR_TARGET $srcdir/$subdir/text.c tmpdir/text.o] \
- || ![ld_compile $CC_FOR_TARGET $srcdir/$subdir/pr20070a.c tmpdir/pr20070a.o] \
- || ![ld_compile $CC_FOR_TARGET $srcdir/$subdir/dummy.s tmpdir/dummy.o] \
- || ![ld_compile $CC_FOR_TARGET $srcdir/$subdir/pr17973.s tmpdir/pr17973.o]) } {
- # Defer fail until we have list of tests set.
- set failed_compile 1
-}
-
-set dotsym 0
-if { $can_compile && !$failed_compile } {
- # Find out if symbols have prefix on this platform before setting tests.
- catch "exec $NM tmpdir/func.o" plugin_nm_output
- if { [regexp "_func" "$plugin_nm_output"] } {
- set _ "_"
- }
- if { [regexp "\\.func" "$plugin_nm_output"] } {
- set dotsym 1
- }
-}
-
-# I do not know why, but the underscore prefix test is going
-# wrong on ppc64le targets. So override it here.
-if { [istarget powerpc*-*-linux*] || [istarget x86_64*-*-linux*] } {
- set _ ""
-}
-
-set testobjfiles "tmpdir/main.o tmpdir/func.o tmpdir/text.o"
-set testobjfiles_notext "tmpdir/main.o tmpdir/func.o"
-set testsrcfiles "tmpdir/main.o $srcdir/$subdir/func.c tmpdir/text.o"
-set testsrcfiles_notext "tmpdir/main.o $srcdir/$subdir/func.c"
-# Rather than having libs we just define dummy values for anything
-# we may need to link a target exe; we aren't going to run it anyway.
-set libs "[ld_link_defsyms] --defsym ${_}printf=${_}main --defsym ${_}puts=${_}main"
-if { $dotsym } {
- append libs " --defsym .printf=.main --defsym .puts=.main"
-}
-if [is_pecoff_format] {
- #otherwise relocs overflow to symbols defined on the command line
- append libs " --image-base=0x10000000"
-}
-
-set plugin_tests [list \
- [list "load plugin" "-plugin $plugin_path \
- $testobjfiles $libs" "" "" "" {{ld plugin-1.d}} "main.x" ] \
- [list "fail plugin onload" "-plugin $plugin_path -plugin-opt failonload \
- $testobjfiles $libs" "" "" "" {{ld plugin-2.d}} "main.x" ] \
- [list "fail plugin allsymbolsread" "-plugin $plugin_path $regas \
- -plugin-opt failallsymbolsread \
- $testobjfiles $libs" "" "" "" {{ld plugin-3.d}} "main.x" ] \
- [list "fail plugin cleanup" "-plugin $plugin_path -plugin-opt failcleanup \
- $regcln \
- $testobjfiles $libs" "" "" "" {{ld plugin-4.d}} "main.x" ] \
- [list "plugin all hooks" "-plugin $plugin_path $regclm $regas $regcln \
- $testobjfiles $libs" "" "" "" {{ld plugin-5.d}} "main.x" ] \
- [list "plugin claimfile lost symbol" "-plugin $plugin_path $regclm \
- $regas $regcln -plugin-opt claim:tmpdir/func.o \
- $testobjfiles $libs" "" "" "" {{ld plugin-6.d}} "main.x" ] \
- [list "plugin claimfile replace symbol" "-plugin $plugin_path $regclm \
- $regas $regcln -plugin-opt claim:tmpdir/func.o \
- -plugin-opt sym:${_}func::0:0:0 \
- $testobjfiles $libs" "" "" "" {{ld plugin-7.d}} "main.x" ] \
- [list "plugin claimfile resolve symbol" "-plugin $plugin_path $regclm \
- $regas $regcln -plugin-opt claim:tmpdir/func.o \
- -plugin-opt sym:${_}func::0:0:0 \
- -plugin-opt sym:${_}func2::0:0:0 \
- -plugin-opt dumpresolutions \
- $testobjfiles $libs" "" "" "" {{ld plugin-8.d}} "main.x" ] \
- [list "plugin claimfile replace file" "-plugin $plugin_path $regclm \
- $regas $regcln -plugin-opt claim:tmpdir/func.o \
- -plugin-opt sym:${_}func::0:0:0 \
- -plugin-opt sym:${_}func2::0:0:0 \
- -plugin-opt dumpresolutions \
- -plugin-opt add:tmpdir/func.o \
- $testobjfiles $libs" "" "" "" {{ld plugin-9.d}} "main.x" ] \
- [list "load plugin with source" "-plugin $plugin_path $regclm \
- -plugin-opt claim:$srcdir/$subdir/func.c \
- $testsrcfiles $libs" "" "" "" {{ld plugin-13.d}} "main.x" ] \
- [list "plugin claimfile lost symbol with source" \
- "-plugin $plugin_path $regclm $regas $regcln \
- -plugin-opt claim:$srcdir/$subdir/func.c \
- $testsrcfiles $libs" "" "" "" {{ld plugin-14.d}} "main.x" ] \
- [list "plugin claimfile replace symbol with source" \
- "-plugin $plugin_path $regclm $regas $regcln \
- -plugin-opt claim:$srcdir/$subdir/func.c \
- -plugin-opt sym:${_}func::0:0:0 \
- $testsrcfiles $libs" "" "" "" {{ld plugin-15.d}} "main.x" ] \
- [list "plugin claimfile resolve symbol with source" \
- "-plugin $plugin_path $regclm $regas $regcln \
- -plugin-opt claim:$srcdir/$subdir/func.c \
- -plugin-opt sym:${_}func::0:0:0 \
- -plugin-opt sym:${_}func2::0:0:0 \
- -plugin-opt dumpresolutions \
- $testsrcfiles $libs" "" "" "" {{ld plugin-16.d}} "main.x" ] \
- [list "plugin claimfile replace file with source" \
- "-plugin $plugin_path $regclm $regas $regcln \
- -plugin-opt claim:$srcdir/$subdir/func.c \
- -plugin-opt sym:${_}func::0:0:0 \
- -plugin-opt sym:${_}func2::0:0:0 \
- -plugin-opt dumpresolutions \
- -plugin-opt add:tmpdir/func.o \
- $testsrcfiles $libs" "" "" "" {{ld plugin-17.d}} "main.x" ] \
- [list "load plugin with source not claimed" "-plugin $plugin_path $regclm \
- $testsrcfiles $libs" "" "" "" {{ld plugin-26.d}} "main.x" ] \
- [list "plugin fatal error" "-plugin $plugin2_path -plugin-opt fatal \
- $testobjfiles $libs" "" "" "" {{ld plugin-27.d}} "main.x" ] \
- [list "plugin error" "-plugin $plugin2_path -plugin-opt error \
- $testobjfiles $libs" "" "" "" {{ld plugin-28.d}} "main.x" ] \
- [list "plugin warning" "-plugin $plugin2_path -plugin-opt warning \
- $testobjfiles $libs" "" "" "" {{ld plugin-29.d}} "main.x" ] \
-]
-
-if [check_shared_lib_support] {
- lappend plugin_tests [list "PR ld/17973" "-plugin $plugin2_path -shared $regassilent \
- -plugin-opt add:tmpdir/pr17973.o \
- tmpdir/dummy.o" "" "" "" {{readelf -sW pr17973.d}} "main.x" ]
-}
-
-
-set plugin_lib_tests [list \
- [list "plugin ignore lib" "-plugin $plugin_path $regclm \
- $regas $regcln -plugin-opt claim:tmpdir/func.o \
- -plugin-opt sym:${_}func::0:0:0 \
- -plugin-opt sym:${_}func2::0:0:0 \
- -plugin-opt dumpresolutions \
- -plugin-opt add:tmpdir/func.o \
- $testobjfiles_notext -Ltmpdir -ltext $libs" "" "" "" {{ld plugin-10.d}} "main.x" ] \
- [list "plugin claimfile replace lib" "-plugin $plugin_path $regclm \
- $regas $regcln -plugin-opt claim:tmpdir/func.o \
- -plugin-opt sym:${_}func::0:0:0 \
- -plugin-opt sym:${_}func2::0:0:0 \
- -plugin-opt dumpresolutions \
- -plugin-opt add:tmpdir/func.o \
- -plugin-opt claim:tmpdir/libtext.a \
- -plugin-opt sym:${_}text::0:0:0 \
- -plugin-opt add:tmpdir/text.o \
- $testobjfiles_notext -Ltmpdir -ltext $libs" "" "" "" {{ld plugin-11.d}} "main.x" ] \
- [list "plugin ignore lib with source" \
- "-plugin $plugin_path $regclm $regas $regcln \
- -plugin-opt claim:$srcdir/$subdir/func.c \
- -plugin-opt sym:${_}func::0:0:0 \
- -plugin-opt sym:${_}func2::0:0:0 \
- -plugin-opt dumpresolutions \
- -plugin-opt add:tmpdir/func.o \
- $testsrcfiles_notext -Ltmpdir -ltext $libs" "" "" "" {{ld plugin-18.d}} "main.x" ] \
- [list "plugin claimfile replace lib with source" \
- "-plugin $plugin_path $regclm $regas $regcln \
- -plugin-opt claim:$srcdir/$subdir/func.c \
- -plugin-opt sym:${_}func::0:0:0 \
- -plugin-opt sym:${_}func2::0:0:0 \
- -plugin-opt dumpresolutions \
- -plugin-opt add:tmpdir/func.o \
- -plugin-opt claim:tmpdir/libtext.a \
- -plugin-opt sym:${_}text::0:0:0 \
- -plugin-opt add:tmpdir/text.o \
- $testsrcfiles_notext -Ltmpdir -ltext $libs" "" "" "" {{ld plugin-19.d}} "main.x" ] \
- [list "plugin with empty archive" \
- "-plugin $plugin_path $regclm \
- -plugin-opt read:8 \
- $testobjfiles tmpdir/libempty.a $libs" "" "" "" {{ld plugin-30.d}} "main.x" ] \
-]
-
-set plugin_extra_elf_tests [list \
- [list "plugin set symbol visibility" "-plugin $plugin_path $regclm \
- $regas $regcln -plugin-opt claim:tmpdir/func.o \
- -plugin-opt sym:${_}func::0:0:0 \
- -plugin-opt sym:${_}func1::0:1:0 \
- -plugin-opt sym:${_}func2::0:2:0 \
- -plugin-opt sym:${_}func3::0:3:0 \
- -plugin-opt dumpresolutions \
- -plugin-opt add:tmpdir/func.o \
- -plugin-opt add:tmpdir/func1p.o \
- -plugin-opt add:tmpdir/func2i.o \
- -plugin-opt add:tmpdir/func3h.o \
- $testobjfiles $libs --verbose=2" "" "" "" {{ld plugin-12.d} \
- {readelf -s plugin-vis-1.d}} "main.x" ] \
- [list "plugin set symbol visibility with source" \
- "-plugin $plugin_path $regclm $regas $regcln \
- -plugin-opt claim:$srcdir/$subdir/func.c \
- -plugin-opt sym:${_}func::0:0:0 \
- -plugin-opt sym:${_}func1::0:1:0 \
- -plugin-opt sym:${_}func2::0:2:0 \
- -plugin-opt sym:${_}func3::0:3:0 \
- -plugin-opt dumpresolutions \
- -plugin-opt add:tmpdir/func.o \
- -plugin-opt add:tmpdir/func1p.o \
- -plugin-opt add:tmpdir/func2i.o \
- -plugin-opt add:tmpdir/func3h.o \
- $testsrcfiles $libs --verbose=2" "" "" "" {{ld plugin-12.d} \
- {readelf -s plugin-vis-1.d}} "main.x" ] \
-]
-
-if { !$can_compile || $failed_compile } {
- foreach testitem $plugin_tests {
- unsupported [lindex $testitem 0]
- }
- if { [is_elf_format] } {
- foreach testitem $plugin_extra_elf_tests {
- unsupported [lindex $testitem 0]
- }
- }
- set CFLAGS_FOR_TARGET "$old_CFLAGS"
- return
-}
-
-run_ld_link_tests $plugin_tests
-
-if { [is_elf_format] \
- && [ld_compile $CC_FOR_TARGET $srcdir/$subdir/func1p.c tmpdir/func1p.o] \
- && [ld_compile $CC_FOR_TARGET $srcdir/$subdir/func2i.c tmpdir/func2i.o] \
- && [ld_compile $CC_FOR_TARGET $srcdir/$subdir/func3h.c tmpdir/func3h.o] } {
- run_ld_link_tests $plugin_extra_elf_tests
-}
-
-if {![ar_simple_create $ar "" "tmpdir/libtext.a" "tmpdir/text.o"] || \
- ![ar_simple_create $ar "" "tmpdir/libempty.a" ""]} {
- foreach testitem $plugin_lib_tests {
- unsupported [lindex $testitem 0]
- }
-} else {
- run_ld_link_tests $plugin_lib_tests
-}
-
-set plugin_src_tests [list \
- [list "plugin 2 with source lib" \
- "-plugin $plugin2_path $regclm $regas $regcln \
- -plugin-opt dumpresolutions \
- tmpdir/main.o -Ltmpdir -ltext -lfunc $libs" "" "" "" {{ld plugin-20.d}} "main.x" ] \
- [list "load plugin 2 with source" \
- "-plugin $plugin2_path $regclm $regas $regcln \
- -plugin-opt dumpresolutions \
- $testsrcfiles $libs" "" "" "" {{ld plugin-21.d}} "main.x" ] \
- [list "load plugin 2 with source and -r" \
- "-r -plugin $plugin2_path $regclm $regas $regcln \
- -plugin-opt dumpresolutions \
- $testsrcfiles $libs" "" "" "" {{ld plugin-24.d}} "main.x" ] \
- [list "plugin 3 with source lib" \
- "-plugin $plugin3_path $regclm $regas $regcln \
- -plugin-opt dumpresolutions \
- tmpdir/main.o -Ltmpdir -ltext -lfunc $libs" "" "" "" {{ld plugin-22.d}} "main.x" ] \
- [list "load plugin 3 with source" \
- "-plugin $plugin3_path $regclm $regas $regcln \
- -plugin-opt dumpresolutions \
- $testsrcfiles $libs" "" "" "" {{ld plugin-23.d}} "main.x" ] \
- [list "load plugin 3 with source and -r" \
- "-r -plugin $plugin3_path $regclm $regas $regcln \
- -plugin-opt dumpresolutions \
- $testsrcfiles $libs" "" "" "" {{ld plugin-25.d}} "main.x" ] \
-]
-
-# Check if nm --plugin works.
-set testname "nm --plugin"
-set nm_plugin "$NM --plugin $plugin2_path $srcdir/$subdir/func.c"
-catch "exec $nm_plugin" plugin_nm_output
-send_log "$nm_plugin\n"
-send_log "$plugin_nm_output\n"
-if { [regexp "0+ T func" "$plugin_nm_output"] &&
- [regexp "0+ T _func" "$plugin_nm_output"] } {
- pass $testname
-} else {
- fail $testname
-}
-
-# Check if ar --plugin works.
-file delete tmpdir/libfunc.a
-if [ar_simple_create $ar "--plugin $plugin2_path" "tmpdir/libfunc.a" \
- "tmpdir/main.o $srcdir/$subdir/func.c"] {
- set testname "ar --plugin"
- set nm_plugin "$NM -s --plugin $plugin2_path tmpdir/libfunc.a"
- catch "exec $nm_plugin" plugin_nm_output
- send_log "$nm_plugin\n"
- send_log "$plugin_nm_output\n"
- if { [regexp "func in func.c" "$plugin_nm_output"] &&
- [regexp "_func in func.c" "$plugin_nm_output"] } {
- pass $testname
- run_ld_link_tests $plugin_src_tests
- } else {
- fail $testname
- }
-} else {
- foreach testitem $plugin_src_tests {
- unsupported [lindex $testitem 0]
- }
-}
-
-file delete tmpdir/libpr20070.a
-if [ar_simple_create $ar "--plugin $plugin4_path" "tmpdir/libpr20070.a" \
- "$srcdir/$subdir/pr20070b.c"] {
- run_ld_link_tests [list \
- [list \
- "PR ld/20070" \
- "-Bstatic -plugin $plugin4_path $regclm \
- $regas $regcln \
- -plugin-opt claim:$srcdir/$subdir/pr20070b.c \
- -plugin-opt claim:tmpdir/libpr20070.a \
- -plugin-opt dumpresolutions \
- tmpdir/pr20070a.o tmpdir/text.o tmpdir/libpr20070.a $libs" \
- "" "" "" {{ld pr20070.d}} "pr20070.x" \
- ] \
- ]
-} else {
- unsupported "PR ld/20070"
-}
-
-set CFLAGS_FOR_TARGET "$old_CFLAGS"
Index: sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-17.d
===================================================================
--- sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-17.d (revision 75)
+++ sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-17.d (nonexistent)
@@ -1,39 +0,0 @@
-Hello from testplugin.
-.*: LDPT_MESSAGE func@0x.*
-.*: LDPT_API_VERSION value 0x1 \(1\)
-.*: LDPT_GNU_LD_VERSION value 0x.*
-.*: LDPT_LINKER_OUTPUT value 0x1 \(1\)
-.*: LDPT_OUTPUT_NAME 'tmpdir/main.x'
-.*: LDPT_REGISTER_CLAIM_FILE_HOOK func@0x.*
-.*: LDPT_REGISTER_CLAIM_FILE_HOOK_V2 func@0x.*
-.*: LDPT_REGISTER_ALL_SYMBOLS_READ_HOOK func@0x.*
-.*: LDPT_REGISTER_CLEANUP_HOOK func@0x.*
-.*: LDPT_ADD_SYMBOLS func@0x.*
-.*: LDPT_GET_INPUT_FILE func@0x.*
-.*: LDPT_GET_VIEW func@0x.*
-.*: LDPT_RELEASE_INPUT_FILE func@0x.*
-.*: LDPT_GET_SYMBOLS func@0x.*
-.*: LDPT_GET_SYMBOLS_V2 func@0x.*
-.*: LDPT_ADD_INPUT_FILE func@0x.*
-.*: LDPT_ADD_INPUT_LIBRARY func@0x.*
-.*: LDPT_SET_EXTRA_LIBRARY_PATH func@0x.*
-.*: LDPT_OPTION 'registerclaimfile'
-.*: LDPT_OPTION 'registerallsymbolsread'
-.*: LDPT_OPTION 'registercleanup'
-.*: LDPT_OPTION 'claim:.*/ld/testsuite/ld-plugin/func.c'
-.*: LDPT_OPTION 'sym:_?func::0:0:0'
-.*: LDPT_OPTION 'sym:_?func2::0:0:0'
-.*: LDPT_OPTION 'dumpresolutions'
-.*: LDPT_OPTION 'add:tmpdir/func.o'
-.*: LDPT_NULL value 0x0 \(0\)
-#...
-hook called: claim_file tmpdir/main.o \[@0/.* not claimed
-hook called: claim_file .*/ld/testsuite/ld-plugin/func.c \[@0/.* CLAIMED
-hook called: claim_file tmpdir/text.o \[@0/.* not claimed
-#...
-hook called: all symbols read.
-Sym: '_?func' Resolution: LDPR_PREVAILING_DEF_IRONLY
-Sym: '_?func2' Resolution: LDPR_PREVAILING_DEF_IRONLY
-#...
-hook called: cleanup.
-#...
Index: sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-28.d
===================================================================
--- sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-28.d (revision 75)
+++ sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-28.d (nonexistent)
@@ -1,2 +0,0 @@
-.*: error: Error
-#...
Index: sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-18.d
===================================================================
--- sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-18.d (revision 75)
+++ sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-18.d (nonexistent)
@@ -1,40 +0,0 @@
-Hello from testplugin.
-.*: LDPT_MESSAGE func@0x.*
-.*: LDPT_API_VERSION value 0x1 \(1\)
-.*: LDPT_GNU_LD_VERSION value 0x.*
-.*: LDPT_LINKER_OUTPUT value 0x1 \(1\)
-.*: LDPT_OUTPUT_NAME 'tmpdir/main.x'
-.*: LDPT_REGISTER_CLAIM_FILE_HOOK func@0x.*
-.*: LDPT_REGISTER_CLAIM_FILE_HOOK_V2 func@0x.*
-.*: LDPT_REGISTER_ALL_SYMBOLS_READ_HOOK func@0x.*
-.*: LDPT_REGISTER_CLEANUP_HOOK func@0x.*
-.*: LDPT_ADD_SYMBOLS func@0x.*
-.*: LDPT_GET_INPUT_FILE func@0x.*
-.*: LDPT_GET_VIEW func@0x.*
-.*: LDPT_RELEASE_INPUT_FILE func@0x.*
-.*: LDPT_GET_SYMBOLS func@0x.*
-.*: LDPT_GET_SYMBOLS_V2 func@0x.*
-.*: LDPT_ADD_INPUT_FILE func@0x.*
-.*: LDPT_ADD_INPUT_LIBRARY func@0x.*
-.*: LDPT_SET_EXTRA_LIBRARY_PATH func@0x.*
-.*: LDPT_OPTION 'registerclaimfile'
-.*: LDPT_OPTION 'registerallsymbolsread'
-.*: LDPT_OPTION 'registercleanup'
-.*: LDPT_OPTION 'claim:.*/ld/testsuite/ld-plugin/func.c'
-.*: LDPT_OPTION 'sym:_?func::0:0:0'
-.*: LDPT_OPTION 'sym:_?func2::0:0:0'
-.*: LDPT_OPTION 'dumpresolutions'
-.*: LDPT_OPTION 'add:tmpdir/func.o'
-.*: LDPT_NULL value 0x0 \(0\)
-#...
-hook called: claim_file tmpdir/main.o \[@0/.* not claimed
-hook called: claim_file .*/ld/testsuite/ld-plugin/func.c \[@0/.* CLAIMED
-#...
-hook called: claim_file tmpdir[/\\]libtext.a \[@.* not claimed
-#...
-hook called: all symbols read.
-Sym: '_?func' Resolution: LDPR_PREVAILING_DEF_IRONLY
-Sym: '_?func2' Resolution: LDPR_PREVAILING_DEF_IRONLY
-#...
-hook called: cleanup.
-#...
Index: sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-19.d
===================================================================
--- sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-19.d (revision 75)
+++ sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-19.d (nonexistent)
@@ -1,44 +0,0 @@
-Hello from testplugin.
-.*: LDPT_MESSAGE func@0x.*
-.*: LDPT_API_VERSION value 0x1 \(1\)
-.*: LDPT_GNU_LD_VERSION value 0x.*
-.*: LDPT_LINKER_OUTPUT value 0x1 \(1\)
-.*: LDPT_OUTPUT_NAME 'tmpdir/main.x'
-.*: LDPT_REGISTER_CLAIM_FILE_HOOK func@0x.*
-.*: LDPT_REGISTER_CLAIM_FILE_HOOK_V2 func@0x.*
-.*: LDPT_REGISTER_ALL_SYMBOLS_READ_HOOK func@0x.*
-.*: LDPT_REGISTER_CLEANUP_HOOK func@0x.*
-.*: LDPT_ADD_SYMBOLS func@0x.*
-.*: LDPT_GET_INPUT_FILE func@0x.*
-.*: LDPT_GET_VIEW func@0x.*
-.*: LDPT_RELEASE_INPUT_FILE func@0x.*
-.*: LDPT_GET_SYMBOLS func@0x.*
-.*: LDPT_GET_SYMBOLS_V2 func@0x.*
-.*: LDPT_ADD_INPUT_FILE func@0x.*
-.*: LDPT_ADD_INPUT_LIBRARY func@0x.*
-.*: LDPT_SET_EXTRA_LIBRARY_PATH func@0x.*
-.*: LDPT_OPTION 'registerclaimfile'
-.*: LDPT_OPTION 'registerallsymbolsread'
-.*: LDPT_OPTION 'registercleanup'
-.*: LDPT_OPTION 'claim:.*/ld/testsuite/ld-plugin/func.c'
-.*: LDPT_OPTION 'sym:_?func::0:0:0'
-.*: LDPT_OPTION 'sym:_?func2::0:0:0'
-.*: LDPT_OPTION 'dumpresolutions'
-.*: LDPT_OPTION 'add:tmpdir/func.o'
-.*: LDPT_OPTION 'claim:tmpdir/libtext.a'
-.*: LDPT_OPTION 'sym:_?text::0:0:0'
-.*: LDPT_OPTION 'add:tmpdir/text.o'
-.*: LDPT_NULL value 0x0 \(0\)
-#...
-hook called: claim_file tmpdir/main.o \[@0/.* not claimed
-hook called: claim_file .*/ld/testsuite/ld-plugin/func.c \[@0/.* CLAIMED
-#...
-hook called: claim_file tmpdir[/\\]libtext.a \[@.* CLAIMED
-#...
-hook called: all symbols read.
-Sym: '_?func' Resolution: LDPR_PREVAILING_DEF_IRONLY
-Sym: '_?func2' Resolution: LDPR_PREVAILING_DEF_IRONLY
-Sym: '_?text' Resolution: LDPR_PREVAILING_DEF_IRONLY
-#...
-hook called: cleanup.
-#...
Index: sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-29.d
===================================================================
--- sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-29.d (revision 75)
+++ sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-29.d (nonexistent)
@@ -1,2 +0,0 @@
-.*: warning: Warning
-#...
Index: sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/pr20070.d
===================================================================
--- sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/pr20070.d (revision 75)
+++ sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/pr20070.d (nonexistent)
@@ -1,10 +0,0 @@
-hook called: all symbols read.
-Input: pr20070b.c \(tmpdir/libpr20070.a\)
-Sym: 'def' Resolution: LDPR_PREVAILING_DEF_IRONLY
-Sym: 'weakdef' Resolution: LDPR_PREVAILING_DEF_IRONLY
-Sym: 'undef' Resolution: LDPR_UNDEF
-Sym: 'weakundef' Resolution: LDPR_UNDEF
-Sym: 'common' Resolution: LDPR_PREVAILING_DEF_IRONLY
-#...
-hook called: cleanup.
-#...
Index: sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-6.d
===================================================================
--- sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-6.d (revision 75)
+++ sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-6.d (nonexistent)
@@ -1,33 +0,0 @@
-Hello from testplugin.
-.*: LDPT_MESSAGE func@0x.*
-.*: LDPT_API_VERSION value 0x1 \(1\)
-.*: LDPT_GNU_LD_VERSION value 0x.*
-.*: LDPT_LINKER_OUTPUT value 0x1 \(1\)
-.*: LDPT_OUTPUT_NAME 'tmpdir/main.x'
-.*: LDPT_REGISTER_CLAIM_FILE_HOOK func@0x.*
-.*: LDPT_REGISTER_CLAIM_FILE_HOOK_V2 func@0x.*
-.*: LDPT_REGISTER_ALL_SYMBOLS_READ_HOOK func@0x.*
-.*: LDPT_REGISTER_CLEANUP_HOOK func@0x.*
-.*: LDPT_ADD_SYMBOLS func@0x.*
-.*: LDPT_GET_INPUT_FILE func@0x.*
-.*: LDPT_GET_VIEW func@0x.*
-.*: LDPT_RELEASE_INPUT_FILE func@0x.*
-.*: LDPT_GET_SYMBOLS func@0x.*
-.*: LDPT_GET_SYMBOLS_V2 func@0x.*
-.*: LDPT_ADD_INPUT_FILE func@0x.*
-.*: LDPT_ADD_INPUT_LIBRARY func@0x.*
-.*: LDPT_SET_EXTRA_LIBRARY_PATH func@0x.*
-.*: LDPT_OPTION 'registerclaimfile'
-.*: LDPT_OPTION 'registerallsymbolsread'
-.*: LDPT_OPTION 'registercleanup'
-.*: LDPT_OPTION 'claim:tmpdir/func.o'
-.*: LDPT_NULL value 0x0 \(0\)
-#...
-hook called: claim_file tmpdir/main.o \[@0/.* not claimed
-hook called: claim_file tmpdir/func.o \[@0/.* CLAIMED
-hook called: claim_file tmpdir/text.o \[@0/.* not claimed
-#...
-hook called: all symbols read.
-#...
-hook called: cleanup.
-#...
Index: sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-7.d
===================================================================
--- sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-7.d (revision 75)
+++ sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-7.d (nonexistent)
@@ -1,34 +0,0 @@
-Hello from testplugin.
-.*: LDPT_MESSAGE func@0x.*
-.*: LDPT_API_VERSION value 0x1 \(1\)
-.*: LDPT_GNU_LD_VERSION value 0x.*
-.*: LDPT_LINKER_OUTPUT value 0x1 \(1\)
-.*: LDPT_OUTPUT_NAME 'tmpdir/main.x'
-.*: LDPT_REGISTER_CLAIM_FILE_HOOK func@0x.*
-.*: LDPT_REGISTER_CLAIM_FILE_HOOK_V2 func@0x.*
-.*: LDPT_REGISTER_ALL_SYMBOLS_READ_HOOK func@0x.*
-.*: LDPT_REGISTER_CLEANUP_HOOK func@0x.*
-.*: LDPT_ADD_SYMBOLS func@0x.*
-.*: LDPT_GET_INPUT_FILE func@0x.*
-.*: LDPT_GET_VIEW func@0x.*
-.*: LDPT_RELEASE_INPUT_FILE func@0x.*
-.*: LDPT_GET_SYMBOLS func@0x.*
-.*: LDPT_GET_SYMBOLS_V2 func@0x.*
-.*: LDPT_ADD_INPUT_FILE func@0x.*
-.*: LDPT_ADD_INPUT_LIBRARY func@0x.*
-.*: LDPT_SET_EXTRA_LIBRARY_PATH func@0x.*
-.*: LDPT_OPTION 'registerclaimfile'
-.*: LDPT_OPTION 'registerallsymbolsread'
-.*: LDPT_OPTION 'registercleanup'
-.*: LDPT_OPTION 'claim:tmpdir/func.o'
-.*: LDPT_OPTION 'sym:_?func::0:0:0'
-.*: LDPT_NULL value 0x0 \(0\)
-#...
-hook called: claim_file tmpdir/main.o \[@0/.* not claimed
-hook called: claim_file tmpdir/func.o \[@0/.* CLAIMED
-hook called: claim_file tmpdir/text.o \[@0/.* not claimed
-#...
-hook called: all symbols read.
-#...
-hook called: cleanup.
-#...
Index: sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-8.d
===================================================================
--- sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-8.d (revision 75)
+++ sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-8.d (nonexistent)
@@ -1,38 +0,0 @@
-Hello from testplugin.
-.*: LDPT_MESSAGE func@0x.*
-.*: LDPT_API_VERSION value 0x1 \(1\)
-.*: LDPT_GNU_LD_VERSION value 0x.*
-.*: LDPT_LINKER_OUTPUT value 0x1 \(1\)
-.*: LDPT_OUTPUT_NAME 'tmpdir/main.x'
-.*: LDPT_REGISTER_CLAIM_FILE_HOOK func@0x.*
-.*: LDPT_REGISTER_CLAIM_FILE_HOOK_V2 func@0x.*
-.*: LDPT_REGISTER_ALL_SYMBOLS_READ_HOOK func@0x.*
-.*: LDPT_REGISTER_CLEANUP_HOOK func@0x.*
-.*: LDPT_ADD_SYMBOLS func@0x.*
-.*: LDPT_GET_INPUT_FILE func@0x.*
-.*: LDPT_GET_VIEW func@0x.*
-.*: LDPT_RELEASE_INPUT_FILE func@0x.*
-.*: LDPT_GET_SYMBOLS func@0x.*
-.*: LDPT_GET_SYMBOLS_V2 func@0x.*
-.*: LDPT_ADD_INPUT_FILE func@0x.*
-.*: LDPT_ADD_INPUT_LIBRARY func@0x.*
-.*: LDPT_SET_EXTRA_LIBRARY_PATH func@0x.*
-.*: LDPT_OPTION 'registerclaimfile'
-.*: LDPT_OPTION 'registerallsymbolsread'
-.*: LDPT_OPTION 'registercleanup'
-.*: LDPT_OPTION 'claim:tmpdir/func.o'
-.*: LDPT_OPTION 'sym:_?func::0:0:0'
-.*: LDPT_OPTION 'sym:_?func2::0:0:0'
-.*: LDPT_OPTION 'dumpresolutions'
-.*: LDPT_NULL value 0x0 \(0\)
-#...
-hook called: claim_file tmpdir/main.o \[@0/.* not claimed
-hook called: claim_file tmpdir/func.o \[@0/.* CLAIMED
-hook called: claim_file tmpdir/text.o \[@0/.* not claimed
-#...
-hook called: all symbols read.
-Sym: '_?func' Resolution: LDPR_PREVAILING_DEF
-Sym: '_?func2' Resolution: LDPR_PREVAILING_DEF_IRONLY
-#...
-hook called: cleanup.
-#...
Index: sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-9.d
===================================================================
--- sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-9.d (revision 75)
+++ sources/GNU/binutils/create-2.43.1-testsuite-failures-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/plugin-9.d (nonexistent)
@@ -1,39 +0,0 @@
-Hello from testplugin.
-.*: LDPT_MESSAGE func@0x.*
-.*: LDPT_API_VERSION value 0x1 \(1\)
-.*: LDPT_GNU_LD_VERSION value 0x.*
-.*: LDPT_LINKER_OUTPUT value 0x1 \(1\)
-.*: LDPT_OUTPUT_NAME 'tmpdir/main.x'
-.*: LDPT_REGISTER_CLAIM_FILE_HOOK func@0x.*
-.*: LDPT_REGISTER_CLAIM_FILE_HOOK_V2 func@0x.*
-.*: LDPT_REGISTER_ALL_SYMBOLS_READ_HOOK func@0x.*
-.*: LDPT_REGISTER_CLEANUP_HOOK func@0x.*
-.*: LDPT_ADD_SYMBOLS func@0x.*
-.*: LDPT_GET_INPUT_FILE func@0x.*
-.*: LDPT_GET_VIEW func@0x.*
-.*: LDPT_RELEASE_INPUT_FILE func@0x.*
-.*: LDPT_GET_SYMBOLS func@0x.*
-.*: LDPT_GET_SYMBOLS_V2 func@0x.*
-.*: LDPT_ADD_INPUT_FILE func@0x.*
-.*: LDPT_ADD_INPUT_LIBRARY func@0x.*
-.*: LDPT_SET_EXTRA_LIBRARY_PATH func@0x.*
-.*: LDPT_OPTION 'registerclaimfile'
-.*: LDPT_OPTION 'registerallsymbolsread'
-.*: LDPT_OPTION 'registercleanup'
-.*: LDPT_OPTION 'claim:tmpdir/func.o'
-.*: LDPT_OPTION 'sym:_?func::0:0:0'
-.*: LDPT_OPTION 'sym:_?func2::0:0:0'
-.*: LDPT_OPTION 'dumpresolutions'
-.*: LDPT_OPTION 'add:tmpdir/func.o'
-.*: LDPT_NULL value 0x0 \(0\)
-#...
-hook called: claim_file tmpdir/main.o \[@0/.* not claimed
-hook called: claim_file tmpdir/func.o \[@0/.* CLAIMED
-hook called: claim_file tmpdir/text.o \[@0/.* not claimed
-#...
-hook called: all symbols read.
-Sym: '_?func' Resolution: LDPR_PREVAILING_DEF_IRONLY
-Sym: '_?func2' Resolution: LDPR_PREVAILING_DEF_IRONLY
-#...
-hook called: cleanup.
-#...
Index: sources/GNU/binutils/create-2.43.1-export-demangle-patch/file.list
===================================================================
--- sources/GNU/binutils/create-2.43.1-export-demangle-patch/file.list (revision 75)
+++ sources/GNU/binutils/create-2.43.1-export-demangle-patch/file.list (nonexistent)
@@ -1,2 +0,0 @@
-binutils-2.43.1/bfd/Makefile.am
-binutils-2.43.1/bfd/Makefile.in
Index: sources/GNU/binutils/create-2.43.1-export-demangle-patch/create.patch.sh
===================================================================
--- sources/GNU/binutils/create-2.43.1-export-demangle-patch/create.patch.sh (revision 75)
+++ sources/GNU/binutils/create-2.43.1-export-demangle-patch/create.patch.sh (nonexistent)
@@ -1,15 +0,0 @@
-#!/bin/bash
-
-VERSION=2.43.1
-
-tar --files-from=file.list -xJvf ../binutils-$VERSION.tar.xz
-mv binutils-$VERSION binutils-$VERSION-orig
-
-cp -rf ./binutils-$VERSION-new ./binutils-$VERSION
-
-diff --unified -Nr binutils-$VERSION-orig binutils-$VERSION > binutils-$VERSION-export-demangle.patch
-
-mv binutils-$VERSION-export-demangle.patch ../patches
-
-rm -rf ./binutils-$VERSION
-rm -rf ./binutils-$VERSION-orig
Property changes on: sources/GNU/binutils/create-2.43.1-export-demangle-patch/create.patch.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: sources/GNU/binutils/create-2.43.1-export-demangle-patch/binutils-2.43.1-new/bfd/Makefile.in
===================================================================
--- sources/GNU/binutils/create-2.43.1-export-demangle-patch/binutils-2.43.1-new/bfd/Makefile.in (revision 75)
+++ sources/GNU/binutils/create-2.43.1-export-demangle-patch/binutils-2.43.1-new/bfd/Makefile.in (nonexistent)
@@ -1,2542 +0,0 @@
-# Makefile.in generated by automake 1.15.1 from Makefile.am.
-# @configure_input@
-
-# Copyright (C) 1994-2017 Free Software Foundation, Inc.
-
-# This Makefile.in is free software; the Free Software Foundation
-# gives unlimited permission to copy and/or distribute it,
-# with or without modifications, as long as this notice is preserved.
-
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
-# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
-# PARTICULAR PURPOSE.
-
-@SET_MAKE@
-
-#
-# Copyright (C) 2012-2024 Free Software Foundation, Inc.
-#
-# This file is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 3 of the License, or
-# (at your option) any later version.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this program; see the file COPYING3. If not see
-# <http://www.gnu.org/licenses/>.
-#
-
-
-VPATH = @srcdir@
-am__is_gnu_make = { \
- if test -z '$(MAKELEVEL)'; then \
- false; \
- elif test -n '$(MAKE_HOST)'; then \
- true; \
- elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \
- true; \
- else \
- false; \
- fi; \
-}
-am__make_running_with_option = \
- case $${target_option-} in \
- ?) ;; \
- *) echo "am__make_running_with_option: internal error: invalid" \
- "target option '$${target_option-}' specified" >&2; \
- exit 1;; \
- esac; \
- has_opt=no; \
- sane_makeflags=$$MAKEFLAGS; \
- if $(am__is_gnu_make); then \
- sane_makeflags=$$MFLAGS; \
- else \
- case $$MAKEFLAGS in \
- *\\[\ \ ]*) \
- bs=\\; \
- sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
- | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
- esac; \
- fi; \
- skip_next=no; \
- strip_trailopt () \
- { \
- flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
- }; \
- for flg in $$sane_makeflags; do \
- test $$skip_next = yes && { skip_next=no; continue; }; \
- case $$flg in \
- *=*|--*) continue;; \
- -*I) strip_trailopt 'I'; skip_next=yes;; \
- -*I?*) strip_trailopt 'I';; \
- -*O) strip_trailopt 'O'; skip_next=yes;; \
- -*O?*) strip_trailopt 'O';; \
- -*l) strip_trailopt 'l'; skip_next=yes;; \
- -*l?*) strip_trailopt 'l';; \
- -[dEDm]) skip_next=yes;; \
- -[JT]) skip_next=yes;; \
- esac; \
- case $$flg in \
- *$$target_option*) has_opt=yes; break;; \
- esac; \
- done; \
- test $$has_opt = yes
-am__make_dryrun = (target_option=n; $(am__make_running_with_option))
-am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
-pkgdatadir = $(datadir)/@PACKAGE@
-pkgincludedir = $(includedir)/@PACKAGE@
-pkglibdir = $(libdir)/@PACKAGE@
-pkglibexecdir = $(libexecdir)/@PACKAGE@
-am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
-install_sh_DATA = $(install_sh) -c -m 644
-install_sh_PROGRAM = $(install_sh) -c
-install_sh_SCRIPT = $(install_sh) -c
-INSTALL_HEADER = $(INSTALL_DATA)
-transform = $(program_transform_name)
-NORMAL_INSTALL = :
-PRE_INSTALL = :
-POST_INSTALL = :
-NORMAL_UNINSTALL = :
-PRE_UNINSTALL = :
-POST_UNINSTALL = :
-build_triplet = @build@
-host_triplet = @host@
-target_triplet = @target@
-@INSTALL_LIBBFD_FALSE@am__append_1 = -rpath $(rpath_bfdlibdir)
-@PLUGINS_TRUE@am__append_2 = $(INCDIR)/plugin-api.h
-subdir = .
-ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
-am__aclocal_m4_deps = $(top_srcdir)/../config/acx.m4 \
- $(top_srcdir)/../config/bfd64.m4 \
- $(top_srcdir)/../config/depstand.m4 \
- $(top_srcdir)/../config/gettext-sister.m4 \
- $(top_srcdir)/../config/gettext.m4 \
- $(top_srcdir)/../config/iconv.m4 \
- $(top_srcdir)/../config/intlmacosx.m4 \
- $(top_srcdir)/../config/jobserver.m4 \
- $(top_srcdir)/../config/largefile.m4 \
- $(top_srcdir)/../config/lead-dot.m4 \
- $(top_srcdir)/../config/lib-ld.m4 \
- $(top_srcdir)/../config/lib-link.m4 \
- $(top_srcdir)/../config/lib-prefix.m4 \
- $(top_srcdir)/../config/mmap.m4 $(top_srcdir)/../config/nls.m4 \
- $(top_srcdir)/../config/override.m4 \
- $(top_srcdir)/../config/pkg.m4 \
- $(top_srcdir)/../config/plugins.m4 \
- $(top_srcdir)/../config/po.m4 \
- $(top_srcdir)/../config/progtest.m4 \
- $(top_srcdir)/../config/zlib.m4 \
- $(top_srcdir)/../config/zstd.m4 $(top_srcdir)/../libtool.m4 \
- $(top_srcdir)/../ltoptions.m4 $(top_srcdir)/../ltsugar.m4 \
- $(top_srcdir)/../ltversion.m4 $(top_srcdir)/../lt~obsolete.m4 \
- $(top_srcdir)/ax_tls.m4 $(top_srcdir)/bfd.m4 \
- $(top_srcdir)/warning.m4 $(top_srcdir)/acinclude.m4 \
- $(top_srcdir)/version.m4 $(top_srcdir)/configure.ac
-am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
- $(ACLOCAL_M4)
-DIST_COMMON = $(srcdir)/Makefile.am $(top_srcdir)/configure \
- $(am__configure_deps) $(am__bfdinclude_HEADERS_DIST)
-am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \
- configure.lineno config.status.lineno
-mkinstalldirs = $(SHELL) $(top_srcdir)/../mkinstalldirs
-CONFIG_HEADER = config.h
-CONFIG_CLEAN_FILES = bfd-in3.h po/Makefile.in
-CONFIG_CLEAN_VPATH_FILES =
-am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
-am__vpath_adj = case $$p in \
- $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \
- *) f=$$p;; \
- esac;
-am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`;
-am__install_max = 40
-am__nobase_strip_setup = \
- srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'`
-am__nobase_strip = \
- for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||"
-am__nobase_list = $(am__nobase_strip_setup); \
- for p in $$list; do echo "$$p $$p"; done | \
- sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \
- $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \
- if (++n[$$2] == $(am__install_max)) \
- { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \
- END { for (dir in files) print dir, files[dir] }'
-am__base_list = \
- sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \
- sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g'
-am__uninstall_files_from_dir = { \
- test -z "$$files" \
- || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \
- || { echo " ( cd '$$dir' && rm -f" $$files ")"; \
- $(am__cd) "$$dir" && rm -f $$files; }; \
- }
-am__installdirs = "$(DESTDIR)$(bfdlibdir)" "$(DESTDIR)$(infodir)" \
- "$(DESTDIR)$(bfdincludedir)"
-LTLIBRARIES = $(bfdlib_LTLIBRARIES) $(noinst_LTLIBRARIES)
-am__DEPENDENCIES_1 =
-am__objects_1 = archive.lo archures.lo bfd.lo bfdio.lo cache.lo \
- coff-bfd.lo compress.lo corefile.lo elf-properties.lo \
- format.lo hash.lo libbfd.lo linker.lo merge.lo opncls.lo \
- reloc.lo section.lo simple.lo stab-syms.lo stabs.lo syms.lo \
- targets.lo binary.lo ihex.lo srec.lo tekhex.lo verilog.lo
-am_libbfd_la_OBJECTS = $(am__objects_1)
-libbfd_la_OBJECTS = $(am_libbfd_la_OBJECTS)
-AM_V_lt = $(am__v_lt_@AM_V@)
-am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@)
-am__v_lt_0 = --silent
-am__v_lt_1 =
-libbfd_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
- $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
- $(libbfd_la_LDFLAGS) $(LDFLAGS) -o $@
-@INSTALL_LIBBFD_FALSE@am_libbfd_la_rpath =
-@INSTALL_LIBBFD_TRUE@am_libbfd_la_rpath = -rpath $(bfdlibdir)
-AM_V_P = $(am__v_P_@AM_V@)
-am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
-am__v_P_0 = false
-am__v_P_1 = :
-AM_V_GEN = $(am__v_GEN_@AM_V@)
-am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
-am__v_GEN_0 = @echo " GEN " $@;
-am__v_GEN_1 =
-AM_V_at = $(am__v_at_@AM_V@)
-am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
-am__v_at_0 = @
-am__v_at_1 =
-DEFAULT_INCLUDES = -I.@am__isrc@
-depcomp = $(SHELL) $(top_srcdir)/../depcomp
-am__depfiles_maybe = depfiles
-am__mv = mv -f
-COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
- $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
-LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
- $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \
- $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \
- $(AM_CFLAGS) $(CFLAGS)
-AM_V_CC = $(am__v_CC_@AM_V@)
-am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@)
-am__v_CC_0 = @echo " CC " $@;
-am__v_CC_1 =
-CCLD = $(CC)
-LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
- $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
- $(AM_LDFLAGS) $(LDFLAGS) -o $@
-AM_V_CCLD = $(am__v_CCLD_@AM_V@)
-am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@)
-am__v_CCLD_0 = @echo " CCLD " $@;
-am__v_CCLD_1 =
-SOURCES = $(libbfd_la_SOURCES) $(EXTRA_libbfd_la_SOURCES)
-AM_V_DVIPS = $(am__v_DVIPS_@AM_V@)
-am__v_DVIPS_ = $(am__v_DVIPS_@AM_DEFAULT_V@)
-am__v_DVIPS_0 = @echo " DVIPS " $@;
-am__v_DVIPS_1 =
-AM_V_MAKEINFO = $(am__v_MAKEINFO_@AM_V@)
-am__v_MAKEINFO_ = $(am__v_MAKEINFO_@AM_DEFAULT_V@)
-am__v_MAKEINFO_0 = @echo " MAKEINFO" $@;
-am__v_MAKEINFO_1 =
-AM_V_INFOHTML = $(am__v_INFOHTML_@AM_V@)
-am__v_INFOHTML_ = $(am__v_INFOHTML_@AM_DEFAULT_V@)
-am__v_INFOHTML_0 = @echo " INFOHTML" $@;
-am__v_INFOHTML_1 =
-AM_V_TEXI2DVI = $(am__v_TEXI2DVI_@AM_V@)
-am__v_TEXI2DVI_ = $(am__v_TEXI2DVI_@AM_DEFAULT_V@)
-am__v_TEXI2DVI_0 = @echo " TEXI2DVI" $@;
-am__v_TEXI2DVI_1 =
-AM_V_TEXI2PDF = $(am__v_TEXI2PDF_@AM_V@)
-am__v_TEXI2PDF_ = $(am__v_TEXI2PDF_@AM_DEFAULT_V@)
-am__v_TEXI2PDF_0 = @echo " TEXI2PDF" $@;
-am__v_TEXI2PDF_1 =
-AM_V_texinfo = $(am__v_texinfo_@AM_V@)
-am__v_texinfo_ = $(am__v_texinfo_@AM_DEFAULT_V@)
-am__v_texinfo_0 = -q
-am__v_texinfo_1 =
-AM_V_texidevnull = $(am__v_texidevnull_@AM_V@)
-am__v_texidevnull_ = $(am__v_texidevnull_@AM_DEFAULT_V@)
-am__v_texidevnull_0 = > /dev/null
-am__v_texidevnull_1 =
-am__dirstamp = $(am__leading_dot)dirstamp
-INFO_DEPS = doc/bfd.info
-am__TEXINFO_TEX_DIR = $(srcdir)
-DVIS = doc/bfd.dvi
-PDFS = doc/bfd.pdf
-PSS = doc/bfd.ps
-HTMLS = doc/bfd.html
-TEXINFOS = doc/bfd.texi
-TEXI2PDF = $(TEXI2DVI) --pdf --batch
-MAKEINFOHTML = $(MAKEINFO) --html
-AM_MAKEINFOHTMLFLAGS = $(AM_MAKEINFOFLAGS)
-DVIPS = dvips
-RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \
- ctags-recursive dvi-recursive html-recursive info-recursive \
- install-data-recursive install-dvi-recursive \
- install-exec-recursive install-html-recursive \
- install-info-recursive install-pdf-recursive \
- install-ps-recursive install-recursive installcheck-recursive \
- installdirs-recursive pdf-recursive ps-recursive \
- tags-recursive uninstall-recursive
-am__can_run_installinfo = \
- case $$AM_UPDATE_INFO_DIR in \
- n|no|NO) false;; \
- *) (install-info --version) >/dev/null 2>&1;; \
- esac
-am__bfdinclude_HEADERS_DIST = $(INCDIR)/plugin-api.h bfd.h \
- $(INCDIR)/ansidecl.h $(INCDIR)/symcat.h \
- $(INCDIR)/diagnostics.h $(INCDIR)/bfdlink.h $(INCDIR)/demangle.h
-HEADERS = $(bfdinclude_HEADERS)
-RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \
- distclean-recursive maintainer-clean-recursive
-am__recursive_targets = \
- $(RECURSIVE_TARGETS) \
- $(RECURSIVE_CLEAN_TARGETS) \
- $(am__extra_recursive_targets)
-AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \
- cscope
-am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) \
- $(LISP)config.in
-# Read a list of newline-separated strings from the standard input,
-# and print each of them once, without duplicates. Input order is
-# *not* preserved.
-am__uniquify_input = $(AWK) '\
- BEGIN { nonempty = 0; } \
- { items[$$0] = 1; nonempty = 1; } \
- END { if (nonempty) { for (i in items) print i; }; } \
-'
-# Make sure the list of sources is unique. This is necessary because,
-# e.g., the same source file might be shared among _SOURCES variables
-# for different programs/libraries.
-am__define_uniq_tagged_files = \
- list='$(am__tagged_files)'; \
- unique=`for i in $$list; do \
- if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
- done | $(am__uniquify_input)`
-ETAGS = etags
-CTAGS = ctags
-CSCOPE = cscope
-DIST_SUBDIRS = $(SUBDIRS)
-ACLOCAL = @ACLOCAL@
-AMTAR = @AMTAR@
-AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
-AR = @AR@
-AUTOCONF = @AUTOCONF@
-AUTOHEADER = @AUTOHEADER@
-AUTOMAKE = @AUTOMAKE@
-AWK = @AWK@
-CATALOGS = @CATALOGS@
-CATOBJEXT = @CATOBJEXT@
-CC = @CC@
-CCDEPMODE = @CCDEPMODE@
-CC_FOR_BUILD = @CC_FOR_BUILD@
-CFLAGS = @CFLAGS@
-COREFILE = @COREFILE@
-COREFLAG = @COREFLAG@
-CPP = @CPP@
-CPPFLAGS = @CPPFLAGS@
-CYGPATH_W = @CYGPATH_W@
-DATADIRNAME = @DATADIRNAME@
-DEBUGDIR = @DEBUGDIR@
-DEFS = @DEFS@
-DEPDIR = @DEPDIR@
-DSYMUTIL = @DSYMUTIL@
-DUMPBIN = @DUMPBIN@
-ECHO_C = @ECHO_C@
-ECHO_N = @ECHO_N@
-ECHO_T = @ECHO_T@
-EGREP = @EGREP@
-EXEEXT = @EXEEXT@
-EXEEXT_FOR_BUILD = @EXEEXT_FOR_BUILD@
-FGREP = @FGREP@
-GENCAT = @GENCAT@
-GMSGFMT = @GMSGFMT@
-GREP = @GREP@
-HDEFINES = @HDEFINES@
-INCINTL = @INCINTL@
-INSTALL = @INSTALL@
-INSTALL_DATA = @INSTALL_DATA@
-INSTALL_PROGRAM = @INSTALL_PROGRAM@
-INSTALL_SCRIPT = @INSTALL_SCRIPT@
-INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
-INSTOBJEXT = @INSTOBJEXT@
-INTLLIBS = @INTLLIBS@
-INTL_MACOSX_LIBS = @INTL_MACOSX_LIBS@
-LARGEFILE_CPPFLAGS = @LARGEFILE_CPPFLAGS@
-LD = @LD@
-LDFLAGS = @LDFLAGS@
-LIBICONV = @LIBICONV@
-LIBINTL = @LIBINTL@
-LIBINTL_DEP = @LIBINTL_DEP@
-LIBM = @LIBM@
-LIBOBJS = @LIBOBJS@
-LIBS = @LIBS@
-LIBTOOL = @LIBTOOL@
-LIPO = @LIPO@
-LN_S = @LN_S@
-LTLIBICONV = @LTLIBICONV@
-LTLIBINTL = @LTLIBINTL@
-LTLIBOBJS = @LTLIBOBJS@
-MAINT = @MAINT@
-MAKEINFO = @MAKEINFO@
-MKDIR_P = @MKDIR_P@
-MKINSTALLDIRS = @MKINSTALLDIRS@
-MSGFMT = @MSGFMT@
-MSGMERGE = @MSGMERGE@
-NM = @NM@
-NMEDIT = @NMEDIT@
-NO_WERROR = @NO_WERROR@
-OBJDUMP = @OBJDUMP@
-OBJEXT = @OBJEXT@
-OTOOL = @OTOOL@
-OTOOL64 = @OTOOL64@
-PACKAGE = @PACKAGE@
-PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
-PACKAGE_NAME = @PACKAGE_NAME@
-PACKAGE_STRING = @PACKAGE_STRING@
-PACKAGE_TARNAME = @PACKAGE_TARNAME@
-PACKAGE_URL = @PACKAGE_URL@
-PACKAGE_VERSION = @PACKAGE_VERSION@
-PATH_SEPARATOR = @PATH_SEPARATOR@
-PKGVERSION = @PKGVERSION@
-PKG_CONFIG = @PKG_CONFIG@
-PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@
-PKG_CONFIG_PATH = @PKG_CONFIG_PATH@
-POSUB = @POSUB@
-RANLIB = @RANLIB@
-REPORT_BUGS_TEXI = @REPORT_BUGS_TEXI@
-REPORT_BUGS_TO = @REPORT_BUGS_TO@
-SED = @SED@
-SET_MAKE = @SET_MAKE@
-SHARED_LDFLAGS = @SHARED_LDFLAGS@
-SHARED_LIBADD = @SHARED_LIBADD@
-SHELL = @SHELL@
-STRIP = @STRIP@
-TDEFINES = @TDEFINES@
-USE_NLS = @USE_NLS@
-VERSION = @VERSION@
-WARN_CFLAGS = @WARN_CFLAGS@
-WARN_CFLAGS_FOR_BUILD = @WARN_CFLAGS_FOR_BUILD@
-WARN_WRITE_STRINGS = @WARN_WRITE_STRINGS@
-XGETTEXT = @XGETTEXT@
-ZSTD_CFLAGS = @ZSTD_CFLAGS@
-ZSTD_LIBS = @ZSTD_LIBS@
-abs_builddir = @abs_builddir@
-abs_srcdir = @abs_srcdir@
-abs_top_builddir = @abs_top_builddir@
-abs_top_srcdir = @abs_top_srcdir@
-ac_ct_CC = @ac_ct_CC@
-ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
-all_backends = @all_backends@
-am__include = @am__include@
-am__leading_dot = @am__leading_dot@
-am__quote = @am__quote@
-am__tar = @am__tar@
-am__untar = @am__untar@
-bfd64_libs = @bfd64_libs@
-bfd_backends = @bfd_backends@
-bfd_default_target_size = @bfd_default_target_size@
-bfd_file_ptr = @bfd_file_ptr@
-bfd_machines = @bfd_machines@
-bfd_ufile_ptr = @bfd_ufile_ptr@
-@INSTALL_LIBBFD_FALSE@bfdincludedir =
-@INSTALL_LIBBFD_TRUE@bfdincludedir = @bfdincludedir@
-# Empty these so that the respective installation directories will not be created.
-@INSTALL_LIBBFD_FALSE@bfdlibdir =
-@INSTALL_LIBBFD_TRUE@bfdlibdir = @bfdlibdir@
-bindir = @bindir@
-build = @build@
-build_alias = @build_alias@
-build_cpu = @build_cpu@
-build_os = @build_os@
-build_vendor = @build_vendor@
-builddir = @builddir@
-datadir = @datadir@
-datarootdir = @datarootdir@
-docdir = @docdir@
-dvidir = @dvidir@
-exec_prefix = @exec_prefix@
-havevecs = @havevecs@
-host = @host@
-host_alias = @host_alias@
-host_cpu = @host_cpu@
-host_noncanonical = @host_noncanonical@
-host_os = @host_os@
-host_vendor = @host_vendor@
-htmldir = @htmldir@
-includedir = @includedir@
-infodir = @infodir@
-install_sh = @install_sh@
-libdir = @libdir@
-libexecdir = @libexecdir@
-localedir = @localedir@
-localstatedir = @localstatedir@
-lt_cv_dlopen_libs = @lt_cv_dlopen_libs@
-mandir = @mandir@
-mkdir_p = @mkdir_p@
-oldincludedir = @oldincludedir@
-pdfdir = @pdfdir@
-prefix = @prefix@
-program_transform_name = @program_transform_name@
-psdir = @psdir@
-sbindir = @sbindir@
-sharedstatedir = @sharedstatedir@
-srcdir = @srcdir@
-supports_plugins = @supports_plugins@
-sysconfdir = @sysconfdir@
-target = @target@
-target_alias = @target_alias@
-target_cpu = @target_cpu@
-target_noncanonical = @target_noncanonical@
-target_os = @target_os@
-target_vendor = @target_vendor@
-tdefaults = @tdefaults@
-top_build_prefix = @top_build_prefix@
-top_builddir = @top_builddir@
-top_srcdir = @top_srcdir@
-wordsize = @wordsize@
-zlibdir = @zlibdir@
-zlibinc = @zlibinc@
-AUTOMAKE_OPTIONS = no-dist foreign info-in-builddir no-texinfo.tex
-ACLOCAL_AMFLAGS = -I . -I .. -I ../config
-MOSTLYCLEANFILES = ofiles stamp-ofiles $(MKDOC) doc/*.o doc/*.stamp
-CLEANFILES = bfd.h dep.sed stmp-bfd-h DEP DEPA DEP1 DEP2 stmp-bin2-h \
- stmp-lbfd-h stmp-lcoff-h
-DISTCLEANFILES = $(BUILD_CFILES) $(BUILD_HFILES) libtool-soversion \
- doc/bfd.?? doc/bfd.??? texput.log
-MAINTAINERCLEANFILES = $(DOCFILES) doc/bfd.info
-INCDIR = $(srcdir)/../include
-CSEARCH = -I. -I$(srcdir) -I$(INCDIR)
-SUBDIRS = po
-bfddocdir = doc
-libbfd_la_LDFLAGS = $(am__append_1) -release `cat libtool-soversion` \
- @SHARED_LDFLAGS@ $(am__empty)
-@INSTALL_LIBBFD_TRUE@bfdlib_LTLIBRARIES = libbfd.la
-@INSTALL_LIBBFD_FALSE@bfdinclude_HEADERS = $(am__append_2)
-@INSTALL_LIBBFD_TRUE@bfdinclude_HEADERS = $(BFD_H) \
-@INSTALL_LIBBFD_TRUE@ $(INCDIR)/ansidecl.h $(INCDIR)/symcat.h \
-@INSTALL_LIBBFD_TRUE@ $(INCDIR)/diagnostics.h $(INCDIR)/demangle.h \
-@INSTALL_LIBBFD_TRUE@ $(INCDIR)/bfdlink.h $(am__append_2)
-@INSTALL_LIBBFD_FALSE@rpath_bfdlibdir = @bfdlibdir@
-@INSTALL_LIBBFD_FALSE@noinst_LTLIBRARIES = libbfd.la
-
-# This is where we get zlib from. zlibdir is -L../zlib and zlibinc is
-# -I../zlib, unless we were configured with --with-system-zlib, in which
-# case both are empty.
-ZLIB = @zlibdir@ -lz
-ZLIBINC = @zlibinc@
-AM_CFLAGS = $(WARN_CFLAGS) $(ZLIBINC) $(ZSTD_CFLAGS)
-AM_CPPFLAGS = -DBINDIR='"$(bindir)"' -DLIBDIR='"$(libdir)"' \
- @LARGEFILE_CPPFLAGS@ @HDEFINES@ @COREFLAG@ @TDEFINES@ \
- $(CSEARCH) $(CSWITCHES) $(HAVEVECS) @INCINTL@
-@PLUGINS_TRUE@LIBDL = @lt_cv_dlopen_libs@
-
-# bfd.h goes here, for now
-BFD_H = bfd.h
-
-# Jim Kingdon notes:
-# Writing S-records should be included in all (or at least most)
-# *-*-coff, *-*-aout, etc., configurations, because people will want to
-# be able to use objcopy to create S-records. (S-records are not useful
-# for the debugger, so if you are downloading things as S-records you
-# need two copies of the executable, one to download and one for the
-# debugger).
-BFD32_LIBS = \
- archive.lo archures.lo bfd.lo bfdio.lo cache.lo \
- coff-bfd.lo compress.lo corefile.lo elf-properties.lo format.lo \
- hash.lo libbfd.lo linker.lo merge.lo opncls.lo reloc.lo \
- section.lo simple.lo stab-syms.lo stabs.lo syms.lo targets.lo \
- binary.lo ihex.lo srec.lo tekhex.lo verilog.lo
-
-BFD64_LIBS = archive64.lo
-BFD32_LIBS_CFILES = \
- archive.c archures.c bfd.c bfdio.c cache.c coff-bfd.c \
- compress.c corefile.c elf-properties.c format.c hash.c \
- libbfd.c linker.c merge.c opncls.c reloc.c \
- section.c simple.c stab-syms.c stabs.c syms.c targets.c \
- binary.c ihex.c srec.c tekhex.c verilog.c
-
-BFD64_LIBS_CFILES = archive64.c
-
-# This list is alphabetized to make it easier to keep in sync
-# with the decls and initializer in archures.c.
-ALL_MACHINES = \
- cpu-aarch64.lo \
- cpu-alpha.lo \
- cpu-amdgcn.lo \
- cpu-arc.lo \
- cpu-arm.lo \
- cpu-avr.lo \
- cpu-bfin.lo \
- cpu-bpf.lo \
- cpu-cr16.lo \
- cpu-cris.lo \
- cpu-crx.lo \
- cpu-csky.lo \
- cpu-d10v.lo \
- cpu-d30v.lo \
- cpu-dlx.lo \
- cpu-epiphany.lo \
- cpu-fr30.lo \
- cpu-frv.lo \
- cpu-ft32.lo \
- cpu-h8300.lo \
- cpu-hppa.lo \
- cpu-i386.lo \
- cpu-ia64.lo \
- cpu-iamcu.lo \
- cpu-ip2k.lo \
- cpu-iq2000.lo \
- cpu-kvx.lo \
- cpu-lm32.lo \
- cpu-loongarch.lo \
- cpu-m10200.lo \
- cpu-m10300.lo \
- cpu-m32c.lo \
- cpu-m32r.lo \
- cpu-m68hc11.lo \
- cpu-m68hc12.lo \
- cpu-m68k.lo \
- cpu-m9s12x.lo \
- cpu-m9s12xg.lo \
- cpu-mcore.lo \
- cpu-mep.lo \
- cpu-metag.lo \
- cpu-microblaze.lo \
- cpu-mips.lo \
- cpu-mmix.lo \
- cpu-moxie.lo \
- cpu-msp430.lo \
- cpu-mt.lo \
- cpu-nds32.lo \
- cpu-nfp.lo \
- cpu-nios2.lo \
- cpu-ns32k.lo \
- cpu-or1k.lo \
- cpu-pdp11.lo \
- cpu-pj.lo \
- cpu-powerpc.lo \
- cpu-pru.lo \
- cpu-riscv.lo \
- cpu-rl78.lo \
- cpu-rs6000.lo \
- cpu-rx.lo \
- cpu-s12z.lo \
- cpu-s390.lo \
- cpu-score.lo \
- cpu-sh.lo \
- cpu-sparc.lo \
- cpu-spu.lo \
- cpu-tic30.lo \
- cpu-tic4x.lo \
- cpu-tic54x.lo \
- cpu-tic6x.lo \
- cpu-tilegx.lo \
- cpu-tilepro.lo \
- cpu-v850.lo \
- cpu-v850_rh850.lo \
- cpu-vax.lo \
- cpu-visium.lo \
- cpu-wasm32.lo \
- cpu-xgate.lo \
- cpu-xstormy16.lo \
- cpu-xtensa.lo \
- cpu-z80.lo \
- cpu-z8k.lo
-
-ALL_MACHINES_CFILES = \
- cpu-aarch64.c \
- cpu-alpha.c \
- cpu-amdgcn.c \
- cpu-arc.c \
- cpu-arm.c \
- cpu-avr.c \
- cpu-bfin.c \
- cpu-bpf.c \
- cpu-cr16.c \
- cpu-cris.c \
- cpu-crx.c \
- cpu-csky.c \
- cpu-d10v.c \
- cpu-d30v.c \
- cpu-dlx.c \
- cpu-epiphany.c \
- cpu-fr30.c \
- cpu-frv.c \
- cpu-ft32.c \
- cpu-h8300.c \
- cpu-hppa.c \
- cpu-i386.c \
- cpu-ia64.c \
- cpu-iamcu.c \
- cpu-ip2k.c \
- cpu-iq2000.c \
- cpu-kvx.c \
- cpu-lm32.c \
- cpu-loongarch.c \
- cpu-m10200.c \
- cpu-m10300.c \
- cpu-m32c.c \
- cpu-m32r.c \
- cpu-m68hc11.c \
- cpu-m68hc12.c \
- cpu-m68k.c \
- cpu-m9s12x.c \
- cpu-m9s12xg.c \
- cpu-mcore.c \
- cpu-mep.c \
- cpu-metag.c \
- cpu-microblaze.c \
- cpu-mips.c \
- cpu-mmix.c \
- cpu-moxie.c \
- cpu-msp430.c \
- cpu-mt.c \
- cpu-nds32.c \
- cpu-nfp.c \
- cpu-nios2.c \
- cpu-ns32k.c \
- cpu-or1k.c \
- cpu-pdp11.c \
- cpu-pj.c \
- cpu-powerpc.c \
- cpu-pru.c \
- cpu-riscv.c \
- cpu-rl78.c \
- cpu-rs6000.c \
- cpu-rx.c \
- cpu-s12z.c \
- cpu-s390.c \
- cpu-score.c \
- cpu-sh.c \
- cpu-sparc.c \
- cpu-spu.c \
- cpu-tic30.c \
- cpu-tic4x.c \
- cpu-tic54x.c \
- cpu-tic6x.c \
- cpu-tilegx.c \
- cpu-tilepro.c \
- cpu-v850.c \
- cpu-v850_rh850.c \
- cpu-vax.c \
- cpu-visium.c \
- cpu-wasm32.c \
- cpu-xgate.c \
- cpu-xstormy16.c \
- cpu-xtensa.c \
- cpu-z80.c \
- cpu-z8k.c
-
-
-# The .o files needed by all of the 32 bit vectors that are configured into
-# target_vector in targets.c if configured with --enable-targets=all.
-BFD32_BACKENDS = \
- aout-cris.lo \
- aout-ns32k.lo \
- aout32.lo \
- cf-i386lynx.lo \
- coff-go32.lo \
- coff-i386.lo \
- coff-mips.lo \
- coff-rs6000.lo \
- coff-sh.lo \
- coff-stgo32.lo \
- coff-tic30.lo \
- coff-tic4x.lo \
- coff-tic54x.lo \
- coff-z80.lo \
- coff-z8k.lo \
- coffgen.lo \
- cofflink.lo \
- dwarf1.lo \
- dwarf2.lo \
- ecoff.lo \
- ecofflink.lo \
- elf-attrs.lo \
- elf-eh-frame.lo \
- elf-ifunc.lo \
- elf-m10200.lo \
- elf-m10300.lo \
- elf-nacl.lo \
- elf-sframe.lo \
- elf-strtab.lo \
- elf-vxworks.lo \
- elf.lo \
- elf32-am33lin.lo \
- elf32-arc.lo \
- elf32-arm.lo \
- elf32-avr.lo \
- elf32-bfin.lo \
- elf32-cr16.lo \
- elf32-cris.lo \
- elf32-crx.lo \
- elf32-csky.lo \
- elf32-d10v.lo \
- elf32-d30v.lo \
- elf32-dlx.lo \
- elf32-epiphany.lo \
- elf32-fr30.lo \
- elf32-frv.lo \
- elf32-ft32.lo \
- elf32-gen.lo \
- elf32-h8300.lo \
- elf32-hppa.lo \
- elf32-i386.lo \
- elf32-ip2k.lo \
- elf32-iq2000.lo \
- elf32-lm32.lo \
- elf32-m32c.lo \
- elf32-m32r.lo \
- elf32-m68hc11.lo \
- elf32-m68hc12.lo \
- elf32-m68hc1x.lo \
- elf32-m68k.lo \
- elf32-mcore.lo \
- elf32-mep.lo \
- elf32-metag.lo \
- elf32-microblaze.lo \
- elf32-moxie.lo \
- elf32-msp430.lo \
- elf32-mt.lo \
- elf32-nds32.lo \
- elf32-nios2.lo \
- elf32-or1k.lo \
- elf32-pj.lo \
- elf32-ppc.lo \
- elf32-pru.lo \
- elf32-rl78.lo \
- elf32-rx.lo \
- elf32-s12z.lo \
- elf32-s390.lo \
- elf32-sh.lo \
- elf32-sparc.lo \
- elf32-spu.lo \
- elf32-tic6x.lo \
- elf32-tilegx.lo \
- elf32-tilepro.lo \
- elf32-v850.lo \
- elf32-vax.lo \
- elf32-visium.lo \
- elf32-wasm32.lo \
- elf32-xgate.lo \
- elf32-xstormy16.lo \
- elf32-xtensa.lo \
- elf32-z80.lo \
- elf32.lo \
- elflink.lo \
- elfxx-sparc.lo \
- elfxx-tilegx.lo \
- elfxx-x86.lo \
- i386aout.lo \
- i386bsd.lo \
- i386lynx.lo \
- i386msdos.lo \
- mach-o-arm.lo \
- mach-o-i386.lo \
- mach-o.lo \
- ns32knetbsd.lo \
- pc532-mach.lo \
- pdb.lo \
- pdp11.lo \
- pe-arm-wince.lo \
- pe-arm.lo \
- pe-i386.lo \
- pe-mcore.lo \
- pe-sh.lo \
- pef.lo \
- pei-arm-wince.lo \
- pei-arm.lo \
- pei-i386.lo \
- pei-mcore.lo \
- pei-sh.lo \
- peigen.lo \
- plugin.lo \
- ppcboot.lo \
- reloc16.lo \
- som.lo \
- vax1knetbsd.lo \
- vaxnetbsd.lo \
- vms-lib.lo \
- vms-misc.lo \
- wasm-module.lo \
- xcofflink.lo \
- xsym.lo \
- xtensa-dynconfig.lo \
- xtensa-isa.lo \
- xtensa-modules.lo
-
-BFD32_BACKENDS_CFILES = \
- aout-cris.c \
- aout-ns32k.c \
- aout32.c \
- cf-i386lynx.c \
- coff-go32.c \
- coff-i386.c \
- coff-mips.c \
- coff-rs6000.c \
- coff-sh.c \
- coff-stgo32.c \
- coff-tic30.c \
- coff-tic4x.c \
- coff-tic54x.c \
- coff-z80.c \
- coff-z8k.c \
- coffgen.c \
- cofflink.c \
- dwarf1.c \
- dwarf2.c \
- ecoff.c \
- ecofflink.c \
- elf-attrs.c \
- elf-eh-frame.c \
- elf-ifunc.c \
- elf-m10200.c \
- elf-m10300.c \
- elf-nacl.c \
- elf-sframe.c \
- elf-strtab.c \
- elf-vxworks.c \
- elf.c \
- elf32-am33lin.c \
- elf32-arc.c \
- elf32-arm.c \
- elf32-avr.c \
- elf32-bfin.c \
- elf32-cr16.c \
- elf32-cris.c \
- elf32-crx.c \
- elf32-csky.c \
- elf32-d10v.c \
- elf32-d30v.c \
- elf32-dlx.c \
- elf32-epiphany.c \
- elf32-fr30.c \
- elf32-frv.c \
- elf32-ft32.c \
- elf32-gen.c \
- elf32-h8300.c \
- elf32-hppa.c \
- elf32-i386.c \
- elf32-ip2k.c \
- elf32-iq2000.c \
- elf32-lm32.c \
- elf32-m32c.c \
- elf32-m32r.c \
- elf32-m68hc11.c \
- elf32-m68hc12.c \
- elf32-m68hc1x.c \
- elf32-m68k.c \
- elf32-mcore.c \
- elf32-mep.c \
- elf32-metag.c \
- elf32-microblaze.c \
- elf32-moxie.c \
- elf32-msp430.c \
- elf32-mt.c \
- elf32-nds32.c \
- elf32-nios2.c \
- elf32-or1k.c \
- elf32-pj.c \
- elf32-ppc.c \
- elf32-pru.c \
- elf32-rl78.c \
- elf32-rx.c \
- elf32-s12z.c \
- elf32-s390.c \
- elf32-sh.c \
- elf32-sparc.c \
- elf32-spu.c \
- elf32-tic6x.c \
- elf32-tilegx.c \
- elf32-tilepro.c \
- elf32-v850.c \
- elf32-vax.c \
- elf32-visium.c \
- elf32-wasm32.c \
- elf32-xgate.c \
- elf32-xstormy16.c \
- elf32-xtensa.c \
- elf32-z80.c \
- elf32.c \
- elflink.c \
- elfxx-sparc.c \
- elfxx-tilegx.c \
- elfxx-x86.c \
- i386aout.c \
- i386bsd.c \
- i386lynx.c \
- i386msdos.c \
- mach-o-arm.c \
- mach-o-i386.c \
- mach-o.c \
- ns32knetbsd.c \
- pc532-mach.c \
- pdb.c \
- pdp11.c \
- pe-arm-wince.c \
- pe-arm.c \
- pe-i386.c \
- pe-mcore.c \
- pe-sh.c \
- pef.c \
- pei-arm-wince.c \
- pei-arm.c \
- pei-i386.c \
- pei-mcore.c \
- pei-sh.c \
- plugin.c \
- ppcboot.c \
- reloc16.c \
- som.c \
- vax1knetbsd.c \
- vaxnetbsd.c \
- vms-lib.c \
- vms-misc.c \
- wasm-module.c \
- xcofflink.c \
- xsym.c \
- xtensa-dynconfig.c \
- xtensa-isa.c \
- xtensa-modules.c
-
-
-# The .o files needed by all of the 64 bit vectors that are configured into
-# target_vector in targets.c if configured with --enable-targets=all
-# and --enable-64-bit-bfd.
-# elf32-ia64.c requires a 64-bit bfd_vma, and hence can not be put in
-# BFD32_BACKENDS.
-BFD64_BACKENDS = \
- aix5ppc-core.lo \
- aout64.lo \
- coff-alpha.lo \
- coff-x86_64.lo \
- coff64-rs6000.lo \
- elf32-aarch64.lo \
- elf32-ia64.lo \
- elf32-kvx.lo \
- elf32-loongarch.lo \
- elf32-mips.lo \
- elf32-riscv.lo \
- elf32-score.lo \
- elf32-score7.lo \
- elf64-aarch64.lo \
- elf64-alpha.lo \
- elf64-amdgcn.lo \
- elf64-bpf.lo \
- elf64-gen.lo \
- elf64-hppa.lo \
- elf64-ia64-vms.lo \
- elf64-ia64.lo \
- elf64-kvx.lo \
- elf64-loongarch.lo \
- elf64-mips.lo \
- elf64-mmix.lo \
- elf64-nfp.lo \
- elf64-ppc.lo \
- elf64-riscv.lo \
- elf64-s390.lo \
- elf64-sparc.lo \
- elf64-tilegx.lo \
- elf64-x86-64.lo \
- elf64.lo \
- elfn32-mips.lo \
- elfxx-aarch64.lo \
- elfxx-ia64.lo \
- elfxx-kvx.lo \
- elfxx-loongarch.lo \
- elfxx-mips.lo \
- elfxx-riscv.lo \
- elfxx-x86.lo \
- mach-o-aarch64.lo \
- mach-o-x86-64.lo \
- mmo.lo \
- pe-aarch64.lo \
- pe-aarch64igen.lo \
- pe-loongarch64igen.lo \
- pe-riscv64igen.lo \
- pe-x86_64.lo \
- pei-aarch64.lo \
- pei-ia64.lo \
- pei-loongarch64.lo \
- pei-riscv64.lo \
- pei-x86_64.lo \
- pepigen.lo \
- pex64igen.lo \
- vms-alpha.lo
-
-BFD64_BACKENDS_CFILES = \
- aix5ppc-core.c \
- aout64.c \
- coff-alpha.c \
- coff-x86_64.c \
- coff64-rs6000.c \
- elf32-mips.c \
- elf32-score.c \
- elf32-score7.c \
- elf64-alpha.c \
- elf64-amdgcn.c \
- elf64-bpf.c \
- elf64-gen.c \
- elf64-hppa.c \
- elf64-ia64-vms.c \
- elf64-mips.c \
- elf64-mmix.c \
- elf64-nfp.c \
- elf64-ppc.c \
- elf64-s390.c \
- elf64-sparc.c \
- elf64-tilegx.c \
- elf64-x86-64.c \
- elf64.c \
- elfn32-mips.c \
- elfxx-aarch64.c \
- elfxx-ia64.c \
- elfxx-kvx.c \
- elfxx-loongarch.c \
- elfxx-mips.c \
- elfxx-riscv.c \
- elfxx-x86.c \
- mach-o-aarch64.c \
- mach-o-x86-64.c \
- mmo.c \
- pe-aarch64.c \
- pe-x86_64.c \
- pei-aarch64.c \
- pei-ia64.c \
- pei-loongarch64.c \
- pei-riscv64.c \
- pei-x86_64.c \
- vms-alpha.c
-
-OPTIONAL_BACKENDS = \
- cisco-core.lo \
- hpux-core.lo \
- irix-core.lo \
- lynx-core.lo \
- netbsd-core.lo \
- osf-core.lo \
- rs6000-core.lo \
- trad-core.lo
-
-OPTIONAL_BACKENDS_CFILES = \
- cisco-core.c \
- hpux-core.c \
- irix-core.c \
- lynx-core.c \
- netbsd-core.c \
- osf-core.c \
- rs6000-core.c \
- trad-core.c
-
-
-# Reconfigure if config.bfd or configure.host changes.
-# development.sh is used to determine -Werror default.
-CONFIG_STATUS_DEPENDENCIES = \
- $(srcdir)/config.bfd \
- $(srcdir)/configure.host \
- $(srcdir)/development.sh
-
-
-# These are defined by configure:
-WORDSIZE = @wordsize@
-ALL_BACKENDS = @all_backends@
-BFD_BACKENDS = @bfd_backends@
-BFD_MACHINES = @bfd_machines@
-TDEFAULTS = @tdefaults@
-HAVEVECS = @havevecs@
-
-# C source files that correspond to .o's.
-SOURCE_CFILES = \
- $(BFD32_LIBS_CFILES) \
- $(BFD64_LIBS_CFILES) \
- $(ALL_MACHINES_CFILES) \
- $(BFD32_BACKENDS_CFILES) \
- $(BFD64_BACKENDS_CFILES) \
- $(OPTIONAL_BACKENDS_CFILES)
-
-BUILD_CFILES = \
- elf32-aarch64.c elf64-aarch64.c \
- elf32-kvx.c elf64-kvx.c \
- elf32-ia64.c elf64-ia64.c \
- elf32-loongarch.c elf64-loongarch.c \
- elf32-riscv.c elf64-riscv.c \
- peigen.c pepigen.c pex64igen.c pe-aarch64igen.c pe-loongarch64igen.c \
- pe-riscv64igen.c
-
-CFILES = $(SOURCE_CFILES) $(BUILD_CFILES)
-SOURCE_HFILES = \
- aout-target.h aoutx.h arc-got.h arc-plt.h \
- coff-arm.h coff-bfd.h coffcode.h coffswap.h \
- cpu-aarch64.h cpu-arm.h cpu-h8300.h cpu-m68k.h cpu-riscv.h \
- ecoff-bfd.h ecoffswap.h \
- elf32-arm.h elf32-avr.h elf32-bfin.h elf32-cr16.h elf32-csky.h \
- elf32-dlx.h elf32-hppa.h elf32-m68hc1x.h elf32-m68k.h \
- elf32-metag.h elf32-nds32.h elf32-nios2.h elf32-ppc.h \
- elf32-rx.h elf32-score.h elf32-sh-relocs.h elf32-spu.h \
- elf32-tic6x.h elf32-tilegx.h elf32-tilepro.h elf32-v850.h \
- elf64-hppa.h elf64-ppc.h elf64-tilegx.h \
- elf-bfd.h elfcode.h elfcore.h elf-hppa.h elf-linker-x86.h \
- elf-linux-core.h elf-nacl.h elf-s390.h elf-vxworks.h \
- elfxx-aarch64.h elfxx-ia64.h elfxx-mips.h elfxx-riscv.h \
- elfxx-sparc.h elfxx-tilegx.h elfxx-x86.h elfxx-loongarch.h \
- genlink.h go32stub.h \
- libaout.h libbfd.h libcoff.h libecoff.h libhppa.h \
- libpei.h libxcoff.h \
- mach-o.h \
- netbsd.h ns32k.h \
- pef.h pef-traceback.h peicode.h plugin.h \
- som.h sysdep.h \
- version.h vms.h \
- wasm-module.h \
- xcofflink.h xsym.h
-
-BUILD_HFILES = \
- bfdver.h elf32-target.h elf64-target.h targmatch.h
-
-
-# Ensure they are built early:
-BUILT_SOURCES = $(BUILD_HFILES) @MAINT@ $(BUILD_CFILES)
-HFILES = $(SOURCE_HFILES) $(BUILD_HFILES)
-BFD_H_DEPS = $(INCDIR)/ansidecl.h $(INCDIR)/symcat.h $(INCDIR)/diagnostics.h
-LOCAL_H_DEPS = libbfd.h sysdep.h config.h
-SRC_POTFILES = $(SOURCE_CFILES) $(SOURCE_HFILES)
-BLD_POTFILES = $(BUILD_CFILES) $(BUILD_HFILES)
-
-# Various kinds of .o files to put in libbfd.a:
-# BFD_BACKENDS Routines the configured targets need.
-# BFD_MACHINES Architecture-specific routines the configured targets need.
-# COREFILE Core file routines for a native configuration
-# bfd64_libs Routines for 64bit support
-OFILES = $(BFD_BACKENDS) $(BFD_MACHINES) @COREFILE@ @bfd64_libs@
-
-# Since BFD64_LIBS is optional and we can't have substitution in
-# libbfd_la_SOURCES, we put BFD64_LIBS in OFILES instead.
-# However, list all sources in EXTRA_libbfd_la_SOURCES so the
-# dependency tracking fragments are picked up in the Makefile.
-libbfd_la_SOURCES = $(BFD32_LIBS_CFILES)
-EXTRA_libbfd_la_SOURCES = $(CFILES)
-libbfd_la_DEPENDENCIES = $(OFILES) ofiles ../libsframe/libsframe.la
-libbfd_la_LIBADD = `cat ofiles` @SHARED_LIBADD@ $(LIBDL) $(ZLIB) $(ZSTD_LIBS) ../libsframe/libsframe.la
-BFD_H_FILES = bfd-in.h libbfd.c hash.c section.c syms.c \
- archive.c archures.c bfd.c bfdio.c \
- cache.c compress.c corefile.c format.c linker.c opncls.c \
- reloc.c simple.c stab-syms.c stabs.c targets.c
-
-BFD64_H_FILES = archive64.c
-LIBBFD_H_FILES = libbfd-in.h libbfd.c bfd.c bfdio.c \
- archive.c archures.c cache.c hash.c linker.c opncls.c \
- reloc.c section.c stabs.c targets.c
-
-LIBCOFF_H_FILES = libcoff-in.h coffcode.h
-
-# We only rebuild the header files automatically if we have been
-# configured with --enable-maintainer-mode.
-REGEN_HEADER = \
- ( \
- set -e; \
- echo "$$H_FILES" | sed -f $(srcdir)/doc/header.sed; \
- for file in $$H_FILES; do \
- file="$(srcdir)/$$file"; \
- case $$file in \
- *-in.h) cat $$file;; \
- *) echo $$file | sed -e 's,.*/,,' -e 's,^,/* Extracted from ,' \
- -e 's,$$,. */,'; \
- $(MKDOC) $$CHEW_FLAGS -f $(srcdir)/doc/proto.str < $$file;; \
- esac; \
- done; \
- echo "\#ifdef __cplusplus"; \
- echo "}"; \
- echo "\#endif"; \
- echo "\#endif"; \
- )
-
-DOCFILES = \
- doc/aoutx.texi \
- doc/archive.texi \
- doc/archures.texi \
- doc/bfdio.texi \
- doc/bfdt.texi \
- doc/bfdver.texi \
- doc/cache.texi \
- doc/coffcode.texi \
- doc/corefile.texi \
- doc/elfcode.texi \
- doc/elf.texi \
- doc/format.texi \
- doc/hash.texi \
- doc/libbfd.texi \
- doc/linker.texi \
- doc/mmo.texi \
- doc/opncls.texi \
- doc/reloc.texi \
- doc/section.texi \
- doc/syms.texi \
- doc/targets.texi
-
-
-# SRCDOC, SRCPROT, SRCIPROT only used to sidestep Sun Make bug in interaction
-# between VPATH and suffix rules. If you use GNU Make, perhaps other Makes,
-# you don't need these three:
-SRCDOC = \
- $(srcdir)/aoutx.h $(srcdir)/archive.c \
- $(srcdir)/archures.c $(srcdir)/bfd.c \
- $(srcdir)/cache.c $(srcdir)/coffcode.h \
- $(srcdir)/corefile.c $(srcdir)/elf.c \
- $(srcdir)/elfcode.h $(srcdir)/format.c \
- $(srcdir)/libbfd.c $(srcdir)/opncls.c \
- $(srcdir)/reloc.c $(srcdir)/section.c \
- $(srcdir)/syms.c $(srcdir)/targets.c \
- $(srcdir)/hash.c $(srcdir)/linker.c \
- $(srcdir)/mmo.c
-
-SRCPROT = $(srcdir)/archive.c $(srcdir)/archures.c \
- $(srcdir)/bfd.c $(srcdir)/coffcode.h $(srcdir)/corefile.c \
- $(srcdir)/format.c $(srcdir)/libbfd.c \
- $(srcdir)/opncls.c $(srcdir)/reloc.c \
- $(srcdir)/section.c $(srcdir)/syms.c \
- $(srcdir)/targets.c
-
-SRCIPROT = $(srcdir)/cache.c $(srcdir)/libbfd.c \
- $(srcdir)/bfdio.c \
- $(srcdir)/reloc.c $(srcdir)/cpu-h8300.c \
- $(srcdir)/archures.c
-
-TEXIDIR = $(srcdir)/../texinfo/fsf
-info_TEXINFOS = doc/bfd.texi
-doc_bfd_TEXINFOS = $(DOCFILES) doc/bfdsumm.texi
-AM_MAKEINFOFLAGS = --no-split -I "$(srcdir)/doc" -I doc
-TEXI2DVI = texi2dvi -I "$(srcdir)/doc" -I doc
-MKDOC = doc/chew$(EXEEXT_FOR_BUILD)
-
-# We can't replace these rules with an implicit rule, because
-# makes without VPATH support couldn't find the .h files in `..'.
-
-# We do not depend on chew directly so that we can distribute the info
-# files, and permit people to rebuild them, without requiring the makeinfo
-# program. If somebody tries to rebuild info, but none of the .texi files
-# have changed, then nothing will be rebuilt.
-REGEN_TEXI = \
- ( \
- set -e; \
- $(MKDOC) -f $(srcdir)/doc/doc.str < $< > $@.tmp; \
- texi=$@; \
- texi=$${texi%.stamp}.texi; \
- test -e $$texi || test ! -f $(srcdir)/$$texi || $(LN_S) $(srcdir)/$$texi .; \
- $(SHELL) $(srcdir)/../move-if-change $@.tmp $$texi; \
- touch $@; \
- )
-
-noinst_TEXINFOS = doc/bfdint.texi
-all: $(BUILT_SOURCES) config.h
- $(MAKE) $(AM_MAKEFLAGS) all-recursive
-
-.SUFFIXES:
-.SUFFIXES: .c .dvi .lo .o .obj .ps
-am--refresh: Makefile
- @:
-$(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(srcdir)/doc/local.mk $(am__configure_deps)
- @for dep in $?; do \
- case '$(am__configure_deps)' in \
- *$$dep*) \
- echo ' cd $(srcdir) && $(AUTOMAKE) --foreign'; \
- $(am__cd) $(srcdir) && $(AUTOMAKE) --foreign \
- && exit 0; \
- exit 1;; \
- esac; \
- done; \
- echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign Makefile'; \
- $(am__cd) $(top_srcdir) && \
- $(AUTOMAKE) --foreign Makefile
-Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
- @case '$?' in \
- *config.status*) \
- echo ' $(SHELL) ./config.status'; \
- $(SHELL) ./config.status;; \
- *) \
- echo ' cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe)'; \
- cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe);; \
- esac;
-$(srcdir)/doc/local.mk $(am__empty):
-
-$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
- $(SHELL) ./config.status --recheck
-
-$(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps)
- $(am__cd) $(srcdir) && $(AUTOCONF)
-$(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps)
- $(am__cd) $(srcdir) && $(ACLOCAL) $(ACLOCAL_AMFLAGS)
-$(am__aclocal_m4_deps):
-
-config.h: stamp-h1
- @test -f $@ || rm -f stamp-h1
- @test -f $@ || $(MAKE) $(AM_MAKEFLAGS) stamp-h1
-
-stamp-h1: $(srcdir)/config.in $(top_builddir)/config.status
- @rm -f stamp-h1
- cd $(top_builddir) && $(SHELL) ./config.status config.h
-$(srcdir)/config.in: @MAINTAINER_MODE_TRUE@ $(am__configure_deps)
- ($(am__cd) $(top_srcdir) && $(AUTOHEADER))
- rm -f stamp-h1
- touch $@
-
-distclean-hdr:
- -rm -f config.h stamp-h1
-bfd-in3.h: $(top_builddir)/config.status $(srcdir)/bfd-in2.h
- cd $(top_builddir) && $(SHELL) ./config.status $@
-po/Makefile.in: $(top_builddir)/config.status $(top_srcdir)/po/Make-in
- cd $(top_builddir) && $(SHELL) ./config.status $@
-
-install-bfdlibLTLIBRARIES: $(bfdlib_LTLIBRARIES)
- @$(NORMAL_INSTALL)
- @list='$(bfdlib_LTLIBRARIES)'; test -n "$(bfdlibdir)" || list=; \
- list2=; for p in $$list; do \
- if test -f $$p; then \
- list2="$$list2 $$p"; \
- else :; fi; \
- done; \
- test -z "$$list2" || { \
- echo " $(MKDIR_P) '$(DESTDIR)$(bfdlibdir)'"; \
- $(MKDIR_P) "$(DESTDIR)$(bfdlibdir)" || exit 1; \
- echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 '$(DESTDIR)$(bfdlibdir)'"; \
- $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 "$(DESTDIR)$(bfdlibdir)"; \
- }
-
-uninstall-bfdlibLTLIBRARIES:
- @$(NORMAL_UNINSTALL)
- @list='$(bfdlib_LTLIBRARIES)'; test -n "$(bfdlibdir)" || list=; \
- for p in $$list; do \
- $(am__strip_dir) \
- echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f '$(DESTDIR)$(bfdlibdir)/$$f'"; \
- $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f "$(DESTDIR)$(bfdlibdir)/$$f"; \
- done
-
-clean-bfdlibLTLIBRARIES:
- -test -z "$(bfdlib_LTLIBRARIES)" || rm -f $(bfdlib_LTLIBRARIES)
- @list='$(bfdlib_LTLIBRARIES)'; \
- locs=`for p in $$list; do echo $$p; done | \
- sed 's|^[^/]*$$|.|; s|/[^/]*$$||; s|$$|/so_locations|' | \
- sort -u`; \
- test -z "$$locs" || { \
- echo rm -f $${locs}; \
- rm -f $${locs}; \
- }
-
-clean-noinstLTLIBRARIES:
- -test -z "$(noinst_LTLIBRARIES)" || rm -f $(noinst_LTLIBRARIES)
- @list='$(noinst_LTLIBRARIES)'; \
- locs=`for p in $$list; do echo $$p; done | \
- sed 's|^[^/]*$$|.|; s|/[^/]*$$||; s|$$|/so_locations|' | \
- sort -u`; \
- test -z "$$locs" || { \
- echo rm -f $${locs}; \
- rm -f $${locs}; \
- }
-
-libbfd.la: $(libbfd_la_OBJECTS) $(libbfd_la_DEPENDENCIES) $(EXTRA_libbfd_la_DEPENDENCIES)
- $(AM_V_CCLD)$(libbfd_la_LINK) $(am_libbfd_la_rpath) $(libbfd_la_OBJECTS) $(libbfd_la_LIBADD) $(LIBS)
-
-mostlyclean-compile:
- -rm -f *.$(OBJEXT)
-
-distclean-compile:
- -rm -f *.tab.c
-
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/aix5ppc-core.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/aout-cris.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/aout-ns32k.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/aout32.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/aout64.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/archive.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/archive64.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/archures.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/bfd.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/bfdio.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/binary.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cache.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cf-i386lynx.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cisco-core.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/coff-alpha.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/coff-bfd.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/coff-go32.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/coff-i386.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/coff-mips.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/coff-rs6000.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/coff-sh.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/coff-stgo32.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/coff-tic30.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/coff-tic4x.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/coff-tic54x.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/coff-x86_64.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/coff-z80.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/coff-z8k.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/coff64-rs6000.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/coffgen.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cofflink.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/compress.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/corefile.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-aarch64.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-alpha.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-amdgcn.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-arc.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-arm.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-avr.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-bfin.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-bpf.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-cr16.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-cris.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-crx.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-csky.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-d10v.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-d30v.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-dlx.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-epiphany.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-fr30.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-frv.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-ft32.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-h8300.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-hppa.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-i386.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-ia64.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-iamcu.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-ip2k.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-iq2000.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-kvx.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-lm32.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-loongarch.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-m10200.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-m10300.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-m32c.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-m32r.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-m68hc11.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-m68hc12.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-m68k.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-m9s12x.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-m9s12xg.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-mcore.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-mep.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-metag.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-microblaze.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-mips.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-mmix.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-moxie.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-msp430.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-mt.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-nds32.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-nfp.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-nios2.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-ns32k.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-or1k.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-pdp11.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-pj.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-powerpc.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-pru.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-riscv.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-rl78.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-rs6000.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-rx.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-s12z.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-s390.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-score.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-sh.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-sparc.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-spu.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-tic30.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-tic4x.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-tic54x.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-tic6x.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-tilegx.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-tilepro.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-v850.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-v850_rh850.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-vax.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-visium.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-wasm32.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-xgate.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-xstormy16.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-xtensa.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-z80.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-z8k.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/dwarf1.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/dwarf2.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ecoff.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ecofflink.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf-attrs.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf-eh-frame.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf-ifunc.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf-m10200.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf-m10300.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf-nacl.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf-properties.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf-sframe.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf-strtab.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf-vxworks.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-aarch64.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-am33lin.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-arc.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-arm.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-avr.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-bfin.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-cr16.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-cris.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-crx.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-csky.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-d10v.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-d30v.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-dlx.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-epiphany.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-fr30.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-frv.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-ft32.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-gen.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-h8300.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-hppa.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-i386.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-ia64.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-ip2k.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-iq2000.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-kvx.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-lm32.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-loongarch.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-m32c.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-m32r.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-m68hc11.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-m68hc12.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-m68hc1x.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-m68k.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-mcore.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-mep.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-metag.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-microblaze.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-mips.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-moxie.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-msp430.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-mt.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-nds32.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-nios2.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-or1k.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-pj.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-ppc.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-pru.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-riscv.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-rl78.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-rx.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-s12z.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-s390.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-score.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-score7.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-sh.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-sparc.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-spu.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-tic6x.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-tilegx.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-tilepro.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-v850.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-vax.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-visium.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-wasm32.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-xgate.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-xstormy16.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-xtensa.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-z80.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf64-aarch64.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf64-alpha.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf64-amdgcn.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf64-bpf.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf64-gen.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf64-hppa.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf64-ia64-vms.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf64-ia64.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf64-kvx.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf64-loongarch.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf64-mips.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf64-mmix.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf64-nfp.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf64-ppc.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf64-riscv.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf64-s390.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf64-sparc.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf64-tilegx.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf64-x86-64.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf64.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elflink.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elfn32-mips.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elfxx-aarch64.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elfxx-ia64.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elfxx-kvx.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elfxx-loongarch.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elfxx-mips.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elfxx-riscv.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elfxx-sparc.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elfxx-tilegx.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elfxx-x86.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/format.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/hash.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/hpux-core.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/i386aout.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/i386bsd.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/i386lynx.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/i386msdos.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ihex.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/irix-core.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libbfd.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/linker.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/lynx-core.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mach-o-aarch64.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mach-o-arm.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mach-o-i386.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mach-o-x86-64.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mach-o.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/merge.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mmo.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/netbsd-core.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ns32knetbsd.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/opncls.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/osf-core.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pc532-mach.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pdb.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pdp11.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pe-aarch64.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pe-aarch64igen.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pe-arm-wince.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pe-arm.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pe-i386.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pe-loongarch64igen.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pe-mcore.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pe-riscv64igen.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pe-sh.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pe-x86_64.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pef.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pei-aarch64.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pei-arm-wince.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pei-arm.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pei-i386.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pei-ia64.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pei-loongarch64.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pei-mcore.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pei-riscv64.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pei-sh.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pei-x86_64.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/peigen.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pepigen.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pex64igen.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/plugin.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ppcboot.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/reloc.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/reloc16.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/rs6000-core.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/section.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/simple.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/som.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/srec.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/stab-syms.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/stabs.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/syms.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/targets.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tekhex.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/trad-core.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/vax1knetbsd.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/vaxnetbsd.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/verilog.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/vms-alpha.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/vms-lib.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/vms-misc.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/wasm-module.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/xcofflink.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/xsym.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/xtensa-dynconfig.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/xtensa-isa.Plo@am__quote@
-@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/xtensa-modules.Plo@am__quote@
-
-.c.o:
-@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
-@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
-@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ $<
-
-.c.obj:
-@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
-@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
-@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
-
-.c.lo:
-@am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
-@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
-@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LTCOMPILE) -c -o $@ $<
-
-mostlyclean-libtool:
- -rm -f *.lo
-
-clean-libtool:
- -rm -rf .libs _libs
-
-distclean-libtool:
- -rm -f libtool config.lt
-doc/$(am__dirstamp):
- @$(MKDIR_P) doc
- @: > doc/$(am__dirstamp)
-
-doc/bfd.info: doc/bfd.texi $(doc_bfd_TEXINFOS)
- @test -f doc/$(am__dirstamp) || $(MAKE) $(AM_MAKEFLAGS) doc/$(am__dirstamp)
- $(AM_V_MAKEINFO)restore=: && backupdir="$(am__leading_dot)am$$$$" && \
- rm -rf $$backupdir && mkdir $$backupdir && \
- if ($(MAKEINFO) --version) >/dev/null 2>&1; then \
- for f in $@ $@-[0-9] $@-[0-9][0-9] $(@:.info=).i[0-9] $(@:.info=).i[0-9][0-9]; do \
- if test -f $$f; then mv $$f $$backupdir; restore=mv; else :; fi; \
- done; \
- else :; fi && \
- if $(MAKEINFO) $(AM_MAKEINFOFLAGS) $(MAKEINFOFLAGS) -I doc -I $(srcdir)/doc \
- -o $@ `test -f 'doc/bfd.texi' || echo '$(srcdir)/'`doc/bfd.texi; \
- then \
- rc=0; \
- else \
- rc=$$?; \
- $$restore $$backupdir/* `echo "./$@" | sed 's|[^/]*$$||'`; \
- fi; \
- rm -rf $$backupdir; exit $$rc
-
-doc/bfd.dvi: doc/bfd.texi $(doc_bfd_TEXINFOS) doc/$(am__dirstamp)
- $(AM_V_TEXI2DVI)TEXINPUTS="$(am__TEXINFO_TEX_DIR)$(PATH_SEPARATOR)$$TEXINPUTS" \
- MAKEINFO='$(MAKEINFO) $(AM_MAKEINFOFLAGS) $(MAKEINFOFLAGS) -I doc -I $(srcdir)/doc' \
- $(TEXI2DVI) $(AM_V_texinfo) --build-dir=$(@:.dvi=.t2d) -o $@ $(AM_V_texidevnull) \
- `test -f 'doc/bfd.texi' || echo '$(srcdir)/'`doc/bfd.texi
-
-doc/bfd.pdf: doc/bfd.texi $(doc_bfd_TEXINFOS) doc/$(am__dirstamp)
- $(AM_V_TEXI2PDF)TEXINPUTS="$(am__TEXINFO_TEX_DIR)$(PATH_SEPARATOR)$$TEXINPUTS" \
- MAKEINFO='$(MAKEINFO) $(AM_MAKEINFOFLAGS) $(MAKEINFOFLAGS) -I doc -I $(srcdir)/doc' \
- $(TEXI2PDF) $(AM_V_texinfo) --build-dir=$(@:.pdf=.t2p) -o $@ $(AM_V_texidevnull) \
- `test -f 'doc/bfd.texi' || echo '$(srcdir)/'`doc/bfd.texi
-
-doc/bfd.html: doc/bfd.texi $(doc_bfd_TEXINFOS) doc/$(am__dirstamp)
- $(AM_V_MAKEINFO)rm -rf $(@:.html=.htp)
- $(AM_V_at)if $(MAKEINFOHTML) $(AM_MAKEINFOHTMLFLAGS) $(MAKEINFOFLAGS) -I doc -I $(srcdir)/doc \
- -o $(@:.html=.htp) `test -f 'doc/bfd.texi' || echo '$(srcdir)/'`doc/bfd.texi; \
- then \
- rm -rf $@ && mv $(@:.html=.htp) $@; \
- else \
- rm -rf $(@:.html=.htp); exit 1; \
- fi
-.dvi.ps:
- $(AM_V_DVIPS)TEXINPUTS="$(am__TEXINFO_TEX_DIR)$(PATH_SEPARATOR)$$TEXINPUTS" \
- $(DVIPS) $(AM_V_texinfo) -o $@ $<
-
-uninstall-dvi-am:
- @$(NORMAL_UNINSTALL)
- @list='$(DVIS)'; test -n "$(dvidir)" || list=; \
- for p in $$list; do \
- $(am__strip_dir) \
- echo " rm -f '$(DESTDIR)$(dvidir)/$$f'"; \
- rm -f "$(DESTDIR)$(dvidir)/$$f"; \
- done
-
-uninstall-html-am:
- @$(NORMAL_UNINSTALL)
- @list='$(HTMLS)'; test -n "$(htmldir)" || list=; \
- for p in $$list; do \
- $(am__strip_dir) \
- echo " rm -rf '$(DESTDIR)$(htmldir)/$$f'"; \
- rm -rf "$(DESTDIR)$(htmldir)/$$f"; \
- done
-
-uninstall-info-am:
- @$(PRE_UNINSTALL)
- @if test -d '$(DESTDIR)$(infodir)' && $(am__can_run_installinfo); then \
- list='$(INFO_DEPS)'; \
- for file in $$list; do \
- relfile=`echo "$$file" | sed 's|^.*/||'`; \
- echo " install-info --info-dir='$(DESTDIR)$(infodir)' --remove '$(DESTDIR)$(infodir)/$$relfile'"; \
- if install-info --info-dir="$(DESTDIR)$(infodir)" --remove "$(DESTDIR)$(infodir)/$$relfile"; \
- then :; else test ! -f "$(DESTDIR)$(infodir)/$$relfile" || exit 1; fi; \
- done; \
- else :; fi
- @$(NORMAL_UNINSTALL)
- @list='$(INFO_DEPS)'; \
- for file in $$list; do \
- relfile=`echo "$$file" | sed 's|^.*/||'`; \
- relfile_i=`echo "$$relfile" | sed 's|\.info$$||;s|$$|.i|'`; \
- (if test -d "$(DESTDIR)$(infodir)" && cd "$(DESTDIR)$(infodir)"; then \
- echo " cd '$(DESTDIR)$(infodir)' && rm -f $$relfile $$relfile-[0-9] $$relfile-[0-9][0-9] $$relfile_i[0-9] $$relfile_i[0-9][0-9]"; \
- rm -f $$relfile $$relfile-[0-9] $$relfile-[0-9][0-9] $$relfile_i[0-9] $$relfile_i[0-9][0-9]; \
- else :; fi); \
- done
-
-uninstall-pdf-am:
- @$(NORMAL_UNINSTALL)
- @list='$(PDFS)'; test -n "$(pdfdir)" || list=; \
- for p in $$list; do \
- $(am__strip_dir) \
- echo " rm -f '$(DESTDIR)$(pdfdir)/$$f'"; \
- rm -f "$(DESTDIR)$(pdfdir)/$$f"; \
- done
-
-uninstall-ps-am:
- @$(NORMAL_UNINSTALL)
- @list='$(PSS)'; test -n "$(psdir)" || list=; \
- for p in $$list; do \
- $(am__strip_dir) \
- echo " rm -f '$(DESTDIR)$(psdir)/$$f'"; \
- rm -f "$(DESTDIR)$(psdir)/$$f"; \
- done
-
-dist-info: $(INFO_DEPS)
- @srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; \
- list='$(INFO_DEPS)'; \
- for base in $$list; do \
- case $$base in \
- $(srcdir)/*) base=`echo "$$base" | sed "s|^$$srcdirstrip/||"`;; \
- esac; \
- if test -f $$base; then d=.; else d=$(srcdir); fi; \
- base_i=`echo "$$base" | sed 's|\.info$$||;s|$$|.i|'`; \
- for file in $$d/$$base $$d/$$base-[0-9] $$d/$$base-[0-9][0-9] $$d/$$base_i[0-9] $$d/$$base_i[0-9][0-9]; do \
- if test -f $$file; then \
- relfile=`expr "$$file" : "$$d/\(.*\)"`; \
- test -f "$(distdir)/$$relfile" || \
- cp -p $$file "$(distdir)/$$relfile"; \
- else :; fi; \
- done; \
- done
-
-mostlyclean-aminfo:
- -rm -rf doc/bfd.t2d doc/bfd.t2p
-
-clean-aminfo:
- -test -z "doc/bfd.dvi doc/bfd.pdf doc/bfd.ps doc/bfd.html" \
- || rm -rf doc/bfd.dvi doc/bfd.pdf doc/bfd.ps doc/bfd.html
-
-maintainer-clean-aminfo:
- @list='$(INFO_DEPS)'; for i in $$list; do \
- i_i=`echo "$$i" | sed 's|\.info$$||;s|$$|.i|'`; \
- echo " rm -f $$i $$i-[0-9] $$i-[0-9][0-9] $$i_i[0-9] $$i_i[0-9][0-9]"; \
- rm -f $$i $$i-[0-9] $$i-[0-9][0-9] $$i_i[0-9] $$i_i[0-9][0-9]; \
- done
-install-bfdincludeHEADERS: $(bfdinclude_HEADERS)
- @$(NORMAL_INSTALL)
- @list='$(bfdinclude_HEADERS)'; test -n "$(bfdincludedir)" || list=; \
- if test -n "$$list"; then \
- echo " $(MKDIR_P) '$(DESTDIR)$(bfdincludedir)'"; \
- $(MKDIR_P) "$(DESTDIR)$(bfdincludedir)" || exit 1; \
- fi; \
- for p in $$list; do \
- if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
- echo "$$d$$p"; \
- done | $(am__base_list) | \
- while read files; do \
- echo " $(INSTALL_HEADER) $$files '$(DESTDIR)$(bfdincludedir)'"; \
- $(INSTALL_HEADER) $$files "$(DESTDIR)$(bfdincludedir)" || exit $$?; \
- done
-
-uninstall-bfdincludeHEADERS:
- @$(NORMAL_UNINSTALL)
- @list='$(bfdinclude_HEADERS)'; test -n "$(bfdincludedir)" || list=; \
- files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \
- dir='$(DESTDIR)$(bfdincludedir)'; $(am__uninstall_files_from_dir)
-
-# This directory's subdirectories are mostly independent; you can cd
-# into them and run 'make' without going through this Makefile.
-# To change the values of 'make' variables: instead of editing Makefiles,
-# (1) if the variable is set in 'config.status', edit 'config.status'
-# (which will cause the Makefiles to be regenerated when you run 'make');
-# (2) otherwise, pass the desired values on the 'make' command line.
-$(am__recursive_targets):
- @fail=; \
- if $(am__make_keepgoing); then \
- failcom='fail=yes'; \
- else \
- failcom='exit 1'; \
- fi; \
- dot_seen=no; \
- target=`echo $@ | sed s/-recursive//`; \
- case "$@" in \
- distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \
- *) list='$(SUBDIRS)' ;; \
- esac; \
- for subdir in $$list; do \
- echo "Making $$target in $$subdir"; \
- if test "$$subdir" = "."; then \
- dot_seen=yes; \
- local_target="$$target-am"; \
- else \
- local_target="$$target"; \
- fi; \
- ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
- || eval $$failcom; \
- done; \
- if test "$$dot_seen" = "no"; then \
- $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \
- fi; test -z "$$fail"
-
-ID: $(am__tagged_files)
- $(am__define_uniq_tagged_files); mkid -fID $$unique
-tags: tags-recursive
-TAGS: tags
-
-tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
- set x; \
- here=`pwd`; \
- if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \
- include_option=--etags-include; \
- empty_fix=.; \
- else \
- include_option=--include; \
- empty_fix=; \
- fi; \
- list='$(SUBDIRS)'; for subdir in $$list; do \
- if test "$$subdir" = .; then :; else \
- test ! -f $$subdir/TAGS || \
- set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \
- fi; \
- done; \
- $(am__define_uniq_tagged_files); \
- shift; \
- if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
- test -n "$$unique" || unique=$$empty_fix; \
- if test $$# -gt 0; then \
- $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
- "$$@" $$unique; \
- else \
- $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
- $$unique; \
- fi; \
- fi
-ctags: ctags-recursive
-
-CTAGS: ctags
-ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
- $(am__define_uniq_tagged_files); \
- test -z "$(CTAGS_ARGS)$$unique" \
- || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
- $$unique
-
-GTAGS:
- here=`$(am__cd) $(top_builddir) && pwd` \
- && $(am__cd) $(top_srcdir) \
- && gtags -i $(GTAGS_ARGS) "$$here"
-cscope: cscope.files
- test ! -s cscope.files \
- || $(CSCOPE) -b -q $(AM_CSCOPEFLAGS) $(CSCOPEFLAGS) -i cscope.files $(CSCOPE_ARGS)
-clean-cscope:
- -rm -f cscope.files
-cscope.files: clean-cscope cscopelist
-cscopelist: cscopelist-recursive
-
-cscopelist-am: $(am__tagged_files)
- list='$(am__tagged_files)'; \
- case "$(srcdir)" in \
- [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
- *) sdir=$(subdir)/$(srcdir) ;; \
- esac; \
- for i in $$list; do \
- if test -f "$$i"; then \
- echo "$(subdir)/$$i"; \
- else \
- echo "$$sdir/$$i"; \
- fi; \
- done >> $(top_builddir)/cscope.files
-
-distclean-tags:
- -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
- -rm -f cscope.out cscope.in.out cscope.po.out cscope.files
-check-am: all-am
-check: $(BUILT_SOURCES)
- $(MAKE) $(AM_MAKEFLAGS) check-recursive
-all-am: Makefile $(INFO_DEPS) $(LTLIBRARIES) $(HEADERS) config.h
-installdirs: installdirs-recursive
-installdirs-am:
- for dir in "$(DESTDIR)$(bfdlibdir)" "$(DESTDIR)$(infodir)" "$(DESTDIR)$(bfdincludedir)"; do \
- test -z "$$dir" || $(MKDIR_P) "$$dir"; \
- done
-install: $(BUILT_SOURCES)
- $(MAKE) $(AM_MAKEFLAGS) install-recursive
-install-exec: install-exec-recursive
-install-data: install-data-recursive
-uninstall: uninstall-recursive
-
-install-am: all-am
- @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
-
-installcheck: installcheck-recursive
-install-strip:
- if test -z '$(STRIP)'; then \
- $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
- install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
- install; \
- else \
- $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
- install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
- "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
- fi
-mostlyclean-generic:
- -test -z "$(MOSTLYCLEANFILES)" || rm -f $(MOSTLYCLEANFILES)
-
-clean-generic:
- -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES)
-
-distclean-generic:
- -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
- -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
- -rm -f doc/$(am__dirstamp)
- -test -z "$(DISTCLEANFILES)" || rm -f $(DISTCLEANFILES)
-
-maintainer-clean-generic:
- @echo "This command is intended for maintainers to use"
- @echo "it deletes files that may require special tools to rebuild."
- -test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES)
- -test -z "$(MAINTAINERCLEANFILES)" || rm -f $(MAINTAINERCLEANFILES)
-clean: clean-recursive
-
-clean-am: clean-aminfo clean-bfdlibLTLIBRARIES clean-generic \
- clean-libtool clean-noinstLTLIBRARIES mostlyclean-am
-
-distclean: distclean-recursive
- -rm -f $(am__CONFIG_DISTCLEAN_FILES)
- -rm -rf ./$(DEPDIR)
- -rm -f Makefile
-distclean-am: clean-am distclean-compile distclean-generic \
- distclean-hdr distclean-libtool distclean-tags
-
-dvi: dvi-recursive
-
-dvi-am: $(DVIS)
-
-html: html-recursive
-
-html-am: $(HTMLS) html-local
-
-info: info-recursive
-
-info-am: $(INFO_DEPS)
-
-install-data-am: install-bfdincludeHEADERS install-bfdlibLTLIBRARIES \
- install-info-am
-
-install-dvi: install-dvi-recursive
-
-install-dvi-am: $(DVIS)
- @$(NORMAL_INSTALL)
- @list='$(DVIS)'; test -n "$(dvidir)" || list=; \
- if test -n "$$list"; then \
- echo " $(MKDIR_P) '$(DESTDIR)$(dvidir)'"; \
- $(MKDIR_P) "$(DESTDIR)$(dvidir)" || exit 1; \
- fi; \
- for p in $$list; do \
- if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
- echo "$$d$$p"; \
- done | $(am__base_list) | \
- while read files; do \
- echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(dvidir)'"; \
- $(INSTALL_DATA) $$files "$(DESTDIR)$(dvidir)" || exit $$?; \
- done
-install-exec-am:
-
-install-html: install-html-recursive
-
-install-html-am: $(HTMLS)
- @$(NORMAL_INSTALL)
- @list='$(HTMLS)'; list2=; test -n "$(htmldir)" || list=; \
- if test -n "$$list"; then \
- echo " $(MKDIR_P) '$(DESTDIR)$(htmldir)'"; \
- $(MKDIR_P) "$(DESTDIR)$(htmldir)" || exit 1; \
- fi; \
- for p in $$list; do \
- if test -f "$$p" || test -d "$$p"; then d=; else d="$(srcdir)/"; fi; \
- $(am__strip_dir) \
- d2=$$d$$p; \
- if test -d "$$d2"; then \
- echo " $(MKDIR_P) '$(DESTDIR)$(htmldir)/$$f'"; \
- $(MKDIR_P) "$(DESTDIR)$(htmldir)/$$f" || exit 1; \
- echo " $(INSTALL_DATA) '$$d2'/* '$(DESTDIR)$(htmldir)/$$f'"; \
- $(INSTALL_DATA) "$$d2"/* "$(DESTDIR)$(htmldir)/$$f" || exit $$?; \
- else \
- list2="$$list2 $$d2"; \
- fi; \
- done; \
- test -z "$$list2" || { echo "$$list2" | $(am__base_list) | \
- while read files; do \
- echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(htmldir)'"; \
- $(INSTALL_DATA) $$files "$(DESTDIR)$(htmldir)" || exit $$?; \
- done; }
-install-info: install-info-recursive
-
-install-info-am: $(INFO_DEPS)
- @$(NORMAL_INSTALL)
- @srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; \
- list='$(INFO_DEPS)'; test -n "$(infodir)" || list=; \
- if test -n "$$list"; then \
- echo " $(MKDIR_P) '$(DESTDIR)$(infodir)'"; \
- $(MKDIR_P) "$(DESTDIR)$(infodir)" || exit 1; \
- fi; \
- for file in $$list; do \
- case $$file in \
- $(srcdir)/*) file=`echo "$$file" | sed "s|^$$srcdirstrip/||"`;; \
- esac; \
- if test -f $$file; then d=.; else d=$(srcdir); fi; \
- file_i=`echo "$$file" | sed 's|\.info$$||;s|$$|.i|'`; \
- for ifile in $$d/$$file $$d/$$file-[0-9] $$d/$$file-[0-9][0-9] \
- $$d/$$file_i[0-9] $$d/$$file_i[0-9][0-9] ; do \
- if test -f $$ifile; then \
- echo "$$ifile"; \
- else : ; fi; \
- done; \
- done | $(am__base_list) | \
- while read files; do \
- echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(infodir)'"; \
- $(INSTALL_DATA) $$files "$(DESTDIR)$(infodir)" || exit $$?; done
- @$(POST_INSTALL)
- @if $(am__can_run_installinfo); then \
- list='$(INFO_DEPS)'; test -n "$(infodir)" || list=; \
- for file in $$list; do \
- relfile=`echo "$$file" | sed 's|^.*/||'`; \
- echo " install-info --info-dir='$(DESTDIR)$(infodir)' '$(DESTDIR)$(infodir)/$$relfile'";\
- install-info --info-dir="$(DESTDIR)$(infodir)" "$(DESTDIR)$(infodir)/$$relfile" || :;\
- done; \
- else : ; fi
-install-man:
-
-install-pdf: install-pdf-recursive
-
-install-pdf-am: $(PDFS)
- @$(NORMAL_INSTALL)
- @list='$(PDFS)'; test -n "$(pdfdir)" || list=; \
- if test -n "$$list"; then \
- echo " $(MKDIR_P) '$(DESTDIR)$(pdfdir)'"; \
- $(MKDIR_P) "$(DESTDIR)$(pdfdir)" || exit 1; \
- fi; \
- for p in $$list; do \
- if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
- echo "$$d$$p"; \
- done | $(am__base_list) | \
- while read files; do \
- echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(pdfdir)'"; \
- $(INSTALL_DATA) $$files "$(DESTDIR)$(pdfdir)" || exit $$?; done
-install-ps: install-ps-recursive
-
-install-ps-am: $(PSS)
- @$(NORMAL_INSTALL)
- @list='$(PSS)'; test -n "$(psdir)" || list=; \
- if test -n "$$list"; then \
- echo " $(MKDIR_P) '$(DESTDIR)$(psdir)'"; \
- $(MKDIR_P) "$(DESTDIR)$(psdir)" || exit 1; \
- fi; \
- for p in $$list; do \
- if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
- echo "$$d$$p"; \
- done | $(am__base_list) | \
- while read files; do \
- echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(psdir)'"; \
- $(INSTALL_DATA) $$files "$(DESTDIR)$(psdir)" || exit $$?; done
-installcheck-am:
-
-maintainer-clean: maintainer-clean-recursive
- -rm -f $(am__CONFIG_DISTCLEAN_FILES)
- -rm -rf $(top_srcdir)/autom4te.cache
- -rm -rf ./$(DEPDIR)
- -rm -f Makefile
-maintainer-clean-am: distclean-am maintainer-clean-aminfo \
- maintainer-clean-generic
-
-mostlyclean: mostlyclean-recursive
-
-mostlyclean-am: mostlyclean-aminfo mostlyclean-compile \
- mostlyclean-generic mostlyclean-libtool
-
-pdf: pdf-recursive
-
-pdf-am: $(PDFS)
-
-ps: ps-recursive
-
-ps-am: $(PSS)
-
-uninstall-am: uninstall-bfdincludeHEADERS uninstall-bfdlibLTLIBRARIES \
- uninstall-dvi-am uninstall-html-am uninstall-info-am \
- uninstall-pdf-am uninstall-ps-am
-
-.MAKE: $(am__recursive_targets) all check install install-am \
- install-strip
-
-.PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am \
- am--refresh check check-am clean clean-aminfo \
- clean-bfdlibLTLIBRARIES clean-cscope clean-generic \
- clean-libtool clean-noinstLTLIBRARIES cscope cscopelist-am \
- ctags ctags-am dist-info distclean distclean-compile \
- distclean-generic distclean-hdr distclean-libtool \
- distclean-tags dvi dvi-am html html-am html-local info info-am \
- install install-am install-bfdincludeHEADERS \
- install-bfdlibLTLIBRARIES install-data install-data-am \
- install-dvi install-dvi-am install-exec install-exec-am \
- install-html install-html-am install-info install-info-am \
- install-man install-pdf install-pdf-am install-ps \
- install-ps-am install-strip installcheck installcheck-am \
- installdirs installdirs-am maintainer-clean \
- maintainer-clean-aminfo maintainer-clean-generic mostlyclean \
- mostlyclean-aminfo mostlyclean-compile mostlyclean-generic \
- mostlyclean-libtool pdf pdf-am ps ps-am tags tags-am uninstall \
- uninstall-am uninstall-bfdincludeHEADERS \
- uninstall-bfdlibLTLIBRARIES uninstall-dvi-am uninstall-html-am \
- uninstall-info-am uninstall-pdf-am uninstall-ps-am
-
-.PRECIOUS: Makefile
-
-$(BFD32_LIBS) \
- $(BFD64_LIBS) \
- $(ALL_MACHINES) \
- $(BFD32_BACKENDS) \
- $(BFD64_BACKENDS) \
- $(OPTIONAL_BACKENDS): $(BFD_H) $(BFD_H_DEPS) $(LOCAL_H_DEPS)
-
-po/SRC-POTFILES.in: @MAINT@ Makefile
- for file in $(SRC_POTFILES); do echo $$file; done \
- | LC_ALL=C sort | uniq > tmp.src \
- && mv tmp.src $(srcdir)/po/SRC-POTFILES.in
-
-po/BLD-POTFILES.in: @MAINT@ Makefile
- for file in $(BLD_POTFILES); do echo $$file; done \
- | LC_ALL=C sort | uniq > tmp.bld \
- && mv tmp.bld $(srcdir)/po/BLD-POTFILES.in
-
-all diststuff: info
-
-stamp-ofiles: Makefile
- rm -f tofiles
- f=""; \
- for i in $(OFILES) ; do \
- case " $$f " in \
- *" $$i "*) ;; \
- *) f="$$f $$i" ;; \
- esac ; \
- done ; \
- echo $$f > tofiles
- $(SHELL) $(srcdir)/../move-if-change tofiles ofiles
- touch stamp-ofiles
-
-ofiles: stamp-ofiles ; @true
-
-# This file holds an array associating configuration triplets and
-# vector names. It is built from config.bfd. It is not compiled by
-# itself, but is included by targets.c.
-targmatch.h: config.bfd targmatch.sed
- $(AM_V_at)rm -f targmatch.new
- $(AM_V_GEN)$(SED) -f $(srcdir)/targmatch.sed < $(srcdir)/config.bfd > targmatch.new
- $(AM_V_at)mv -f targmatch.new targmatch.h
-
-# When compiling archures.c and targets.c, supply the default target
-# info from configure.
-
-targets.lo: targets.c Makefile
-@am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $(TDEFAULTS) $(srcdir)/targets.c
-@am__fastdepCC_TRUE@ $(AM_V_at)mv -f $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
-@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='targets.c' object='$@' libtool=yes @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@ $(AM_V_CC)$(LTCOMPILE) -c -o $@ $(TDEFAULTS) $(srcdir)/targets.c
-
-archures.lo: archures.c Makefile
-@am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $(TDEFAULTS) $(srcdir)/archures.c
-@am__fastdepCC_TRUE@ $(AM_V_at)mv -f $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
-@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='archures.c' object='$@' libtool=yes @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@ $(AM_V_CC)$(LTCOMPILE) -c -o $@ $(TDEFAULTS) $(srcdir)/archures.c
-
-dwarf2.lo: dwarf2.c Makefile
-@am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ -DDEBUGDIR=\"$(DEBUGDIR)\" $(srcdir)/dwarf2.c
-@am__fastdepCC_TRUE@ $(AM_V_at)mv -f $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
-@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='dwarf2.c' object='$@' libtool=yes @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@ $(AM_V_CC)$(LTCOMPILE) -c -o $@ -DDEBUGDIR=\"$(DEBUGDIR)\" $(srcdir)/dwarf2.c
-
-elf32-target.h : elfxx-target.h
- $(AM_V_GEN)$(SED) -e s/NN/32/g < $< > $@
-
-elf64-target.h : elfxx-target.h
- $(AM_V_GEN)$(SED) -e s/NN/64/g < $< > $@
-
-elf32-aarch64.c : elfnn-aarch64.c
- $(AM_V_at)echo "#line 1 \"$<\"" > $@
- $(AM_V_GEN)$(SED) -e s/NN/32/g < $< >> $@
-
-elf64-aarch64.c : elfnn-aarch64.c
- $(AM_V_at)echo "#line 1 \"$<\"" > $@
- $(AM_V_GEN)$(SED) -e s/NN/64/g < $< >> $@
-
-elf32-ia64.c : elfnn-ia64.c
- $(AM_V_at)echo "#line 1 \"$<\"" > $@
- $(AM_V_GEN)$(SED) -e s/NN/32/g < $< >> $@
-
-elf64-ia64.c : elfnn-ia64.c
- $(AM_V_at)echo "#line 1 \"$<\"" > $@
- $(AM_V_GEN)$(SED) -e s/NN/64/g < $< >> $@
-
-elf32-kvx.c : elfnn-kvx.c
- $(AM_V_at)echo "#line 1 \"$<\"" > $@
- $(AM_V_GEN)$(SED) -e s/NN/32/g < $< >> $@
-
-elf64-kvx.c : elfnn-kvx.c
- $(AM_V_at)echo "#line 1 \"$<\"" > $@
- $(AM_V_GEN)$(SED) -e s/NN/64/g < $< >> $@
-
-elf32-loongarch.c : elfnn-loongarch.c
- $(AM_V_at)echo "#line 1 \"$<\"" > $@
- $(AM_V_GEN)$(SED) -e s/NN/32/g < $< >> $@
-
-elf64-loongarch.c : elfnn-loongarch.c
- $(AM_V_at)echo "#line 1 \"$<\"" > $@
- $(AM_V_GEN)$(SED) -e s/NN/64/g < $< >> $@
-
-elf32-riscv.c : elfnn-riscv.c
- $(AM_V_at)echo "#line 1 \"$<\"" > $@
- $(AM_V_GEN)$(SED) -e s/NN/32/g < $< >> $@
-
-elf64-riscv.c : elfnn-riscv.c
- $(AM_V_at)echo "#line 1 \"$<\"" > $@
- $(AM_V_GEN)$(SED) -e s/NN/64/g < $< >> $@
-
-peigen.c : peXXigen.c
- $(AM_V_at)echo "#line 1 \"$<\"" > $@
- $(AM_V_GEN)$(SED) -e s/XX/pe/g < $< >> $@
-
-pepigen.c : peXXigen.c
- $(AM_V_at)echo "#line 1 \"$<\"" > $@
- $(AM_V_GEN)$(SED) -e s/XX/pep/g < $< >> $@
-
-pex64igen.c: peXXigen.c
- $(AM_V_at)echo "#line 1 \"$<\"" > $@
- $(AM_V_GEN)$(SED) -e s/XX/pex64/g < $< >> $@
-
-pe-aarch64igen.c: peXXigen.c
- $(AM_V_at)echo "#line 1 \"$<\"" > $@
- $(AM_V_GEN)$(SED) -e s/XX/peAArch64/g < $< >> $@
-
-pe-loongarch64igen.c: peXXigen.c
- $(AM_V_at)echo "#line 1 \"$<\"" > $@
- $(AM_V_GEN)$(SED) -e s/XX/peLoongArch64/g < $< >> $@
-
-pe-riscv64igen.c: peXXigen.c
- $(AM_V_at)echo "#line 1 \"peXXigen.c\"" > $@
- $(AM_V_GEN)$(SED) -e s/XX/peRiscV64/g < $< >> $@
-
-host-aout.lo: Makefile
-
-# The following program can be used to generate a simple config file
-# which can be folded into an h-XXX file for a new host, with some editing.
-aout-params.h: gen-aout
- ./gen-aout host > aout-params.h
-gen-aout: $(srcdir)/gen-aout.c Makefile
- $(CC) -o gen-aout $(CFLAGS) $(LFLAGS) $(srcdir)/gen-aout.c
-
-$(BFD_H): stmp-bfd-h ; @true
-
-stmp-bfd-h: bfd-in3.h
- rm -f bfd-tmp.h
- cp bfd-in3.h bfd-tmp.h
- $(SHELL) $(srcdir)/../move-if-change bfd-tmp.h $(BFD_H)
- rm -f bfd-tmp.h
- touch stmp-bfd-h
-
-headers: stmp-bin2-h stmp-lbfd-h stmp-lcoff-h
-
-$(srcdir)/bfd-in2.h: @MAINT@ stmp-bin2-h ; @true
-stmp-bin2-h: $(BFD_H_FILES) $(BFD64_H_FILES) $(MKDOC)
- $(AM_V_GEN)H_FILES="$(BFD_H_FILES)" CHEW_FLAGS= ; $(REGEN_HEADER) > bfd-in2.h-new
- $(AM_V_at)$(SHELL) $(srcdir)/../move-if-change bfd-in2.h-new $(srcdir)/bfd-in2.h
- $(AM_V_at)touch stmp-bin2-h
-
-$(srcdir)/libbfd.h: @MAINT@ stmp-lbfd-h ; @true
-stmp-lbfd-h: $(LIBBFD_H_FILES) $(MKDOC)
- $(AM_V_GEN)H_FILES="$(LIBBFD_H_FILES)" CHEW_FLAGS=-i ; $(REGEN_HEADER) > libbfd.h-new
- $(AM_V_at)$(SHELL) $(srcdir)/../move-if-change libbfd.h-new $(srcdir)/libbfd.h
- $(AM_V_at)touch stmp-lbfd-h
-
-$(srcdir)/libcoff.h: @MAINT@ stmp-lcoff-h ; @true
-stmp-lcoff-h: $(LIBCOFF_H_FILES) $(MKDOC)
- $(AM_V_GEN)H_FILES="$(LIBCOFF_H_FILES)" CHEW_FLAGS=-i ; $(REGEN_HEADER) > libcoff.h-new
- $(AM_V_at)$(SHELL) $(srcdir)/../move-if-change libcoff.h-new $(srcdir)/libcoff.h
- $(AM_V_at)touch stmp-lcoff-h
-
-bfdver.h: $(srcdir)/version.h $(srcdir)/development.sh $(srcdir)/Makefile.in
- $(AM_V_GEN)\
- bfd_version=`echo "$(VERSION)" | $(SED) -e 's/\([^\.]*\)\.*\([^\.]*\)\.*\([^\.]*\)\.*\([^\.]*\)\.*\([^\.]*\).*/\1.00\2.00\3.00\4.00\5/' -e 's/\([^\.]*\)\..*\(..\)\..*\(..\)\..*\(..\)\..*\(..\)$$/\1\2\3\4\5/'` ;\
- bfd_version_string="\"$(VERSION)\"" ;\
- bfd_soversion="$(VERSION)" ;\
- bfd_version_package="\"$(PKGVERSION)\"" ;\
- report_bugs_to="\"$(REPORT_BUGS_TO)\"" ;\
- . $(srcdir)/development.sh ;\
- if test "$$development" = true ; then \
- bfd_version_date=`$(SED) -n -e 's/.*DATE //p' < $(srcdir)/version.h` ;\
- bfd_version_string="\"$(VERSION).$${bfd_version_date}\"" ;\
- bfd_soversion="$(VERSION).$${bfd_version_date}" ;\
- fi ;\
- $(SED) -e "s,@bfd_version@,$$bfd_version," \
- -e "s,@bfd_version_string@,$$bfd_version_string," \
- -e "s,@bfd_version_package@,$$bfd_version_package," \
- -e "s,@report_bugs_to@,$$report_bugs_to," \
- < $(srcdir)/version.h > $@; \
- echo "$${bfd_soversion}" > libtool-soversion
-
-# Disable -Werror, if it has been enabled, since coffswap.h won't
-# compile with gcc 4.5 and above.
-coff-tic4x.lo: coff-tic4x.c
-@am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< $(NO_WERROR)
-@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
-@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@ $(AM_V_CC)$(LTCOMPILE) -c -o $@ $< $(NO_WERROR)
-
-coff-tic54x.lo: coff-tic54x.c
-@am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< $(NO_WERROR)
-@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
-@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@ $(AM_V_CC)$(LTCOMPILE) -c -o $@ $< $(NO_WERROR)
-
-$(MKDOC): doc/chew.stamp ; @true
-doc/chew.stamp: $(srcdir)/doc/chew.c doc/$(am__dirstamp)
- $(AM_V_CCLD)$(CC_FOR_BUILD) -o doc/chw$$$$$(EXEEXT_FOR_BUILD) $(CFLAGS_FOR_BUILD) \
- $(CPPFLAGS_FOR_BUILD) $(LDFLAGS_FOR_BUILD) \
- -I. -I$(srcdir) -Idoc -I$(srcdir)/../include -I$(srcdir)/../intl -I../intl \
- $(srcdir)/doc/chew.c && \
- $(SHELL) $(srcdir)/../move-if-change \
- doc/chw$$$$$(EXEEXT_FOR_BUILD) $(MKDOC) && \
- touch $@
-
-.PRECIOUS: doc/%.stamp
-doc/%.texi: doc/%.stamp ; @true
-doc/%.stamp: $(srcdir)/%.c $(srcdir)/doc/doc.str $(MKDOC) doc/$(am__dirstamp)
- $(AM_V_GEN)$(REGEN_TEXI)
-doc/%.stamp: $(srcdir)/%.h $(srcdir)/doc/doc.str $(MKDOC) doc/$(am__dirstamp)
- $(AM_V_GEN)$(REGEN_TEXI)
-
-# Avoid the %.stamp generating a builddir/bfd.texi that overrides the
-# srcdir/ as well as regenerating doc/bfd.info for each make run.
-doc/bfd.stamp: $(srcdir)/doc/bfd.texi ; $(AM_V_at)touch $@
-
-# We use bfdt.texi, rather than bfd.texi, to avoid conflicting with
-# bfd.texi on an 8.3 filesystem.
-doc/bfdt.stamp: $(srcdir)/bfd.c $(srcdir)/doc/doc.str $(MKDOC) doc/$(am__dirstamp)
- $(AM_V_GEN)$(REGEN_TEXI)
-
-doc/bfdver.texi: $(srcdir)/Makefile.in
- $(AM_V_GEN)\
- $(MKDIR_P) $(@D); \
- echo "@set VERSION $(VERSION)" > $@; \
- if test -n "$(PKGVERSION)"; then \
- echo "@set VERSION_PACKAGE $(PKGVERSION)" >> $@; \
- fi; \
- echo "@set UPDATED `date '+%B %Y'`" >> $@; \
- if test -n "$(REPORT_BUGS_TEXI)"; then \
- echo "@set BUGURL $(REPORT_BUGS_TEXI)" >> $@; \
- fi
-
-html-local: doc/bfd/index.html
-doc/bfd/index.html: doc/bfd.texi $(bfd_TEXINFOS) doc/$(am__dirstamp)
- $(AM_V_at)$(MAKEINFOHTML) $(AM_MAKEINFOHTMLFLAGS) $(MAKEINFOFLAGS) \
- --split=node -o doc/bfd $(srcdir)/doc/bfd.texi
-
-# Tell versions [3.59,3.63) of GNU make to not export all variables.
-# Otherwise a system limit (for SysV at least) may be exceeded.
-.NOEXPORT:
Index: sources/GNU/binutils/create-2.43.1-export-demangle-patch/binutils-2.43.1-new/bfd/Makefile.am
===================================================================
--- sources/GNU/binutils/create-2.43.1-export-demangle-patch/binutils-2.43.1-new/bfd/Makefile.am (revision 75)
+++ sources/GNU/binutils/create-2.43.1-export-demangle-patch/binutils-2.43.1-new/bfd/Makefile.am (nonexistent)
@@ -1,1025 +0,0 @@
-## Process this file with automake to generate Makefile.in
-#
-# Copyright (C) 2012-2024 Free Software Foundation, Inc.
-#
-# This file is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 3 of the License, or
-# (at your option) any later version.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this program; see the file COPYING3. If not see
-# <http://www.gnu.org/licenses/>.
-#
-
-AUTOMAKE_OPTIONS = no-dist foreign info-in-builddir no-texinfo.tex
-ACLOCAL_AMFLAGS = -I . -I .. -I ../config
-
-MOSTLYCLEANFILES =
-CLEANFILES =
-DISTCLEANFILES =
-MAINTAINERCLEANFILES =
-
-INCDIR = $(srcdir)/../include
-CSEARCH = -I. -I$(srcdir) -I$(INCDIR)
-
-SUBDIRS = po
-
-bfddocdir = doc
-
-libbfd_la_LDFLAGS =
-if INSTALL_LIBBFD
-bfdlibdir = @bfdlibdir@
-bfdincludedir = @bfdincludedir@
-bfdlib_LTLIBRARIES = libbfd.la
-bfdinclude_HEADERS = $(BFD_H) $(INCDIR)/ansidecl.h $(INCDIR)/symcat.h \
- $(INCDIR)/diagnostics.h $(INCDIR)/bfdlink.h $(INCDIR)/demangle.h
-else !INSTALL_LIBBFD
-# Empty these so that the respective installation directories will not be created.
-bfdlibdir =
-bfdincludedir =
-bfdinclude_HEADERS =
-rpath_bfdlibdir = @bfdlibdir@
-noinst_LTLIBRARIES = libbfd.la
-libbfd_la_LDFLAGS += -rpath $(rpath_bfdlibdir)
-endif
-
-# This is where we get zlib from. zlibdir is -L../zlib and zlibinc is
-# -I../zlib, unless we were configured with --with-system-zlib, in which
-# case both are empty.
-ZLIB = @zlibdir@ -lz
-ZLIBINC = @zlibinc@
-
-WARN_CFLAGS = @WARN_CFLAGS@
-NO_WERROR = @NO_WERROR@
-AM_CFLAGS = $(WARN_CFLAGS) $(ZLIBINC) $(ZSTD_CFLAGS)
-AM_CPPFLAGS = -DBINDIR='"$(bindir)"' -DLIBDIR='"$(libdir)"' @LARGEFILE_CPPFLAGS@
-if PLUGINS
-bfdinclude_HEADERS += $(INCDIR)/plugin-api.h
-LIBDL = @lt_cv_dlopen_libs@
-endif
-
-# bfd.h goes here, for now
-BFD_H = bfd.h
-
-# Jim Kingdon notes:
-# Writing S-records should be included in all (or at least most)
-# *-*-coff, *-*-aout, etc., configurations, because people will want to
-# be able to use objcopy to create S-records. (S-records are not useful
-# for the debugger, so if you are downloading things as S-records you
-# need two copies of the executable, one to download and one for the
-# debugger).
-BFD32_LIBS = \
- archive.lo archures.lo bfd.lo bfdio.lo cache.lo \
- coff-bfd.lo compress.lo corefile.lo elf-properties.lo format.lo \
- hash.lo libbfd.lo linker.lo merge.lo opncls.lo reloc.lo \
- section.lo simple.lo stab-syms.lo stabs.lo syms.lo targets.lo \
- binary.lo ihex.lo srec.lo tekhex.lo verilog.lo
-
-BFD64_LIBS = archive64.lo
-
-BFD32_LIBS_CFILES = \
- archive.c archures.c bfd.c bfdio.c cache.c coff-bfd.c \
- compress.c corefile.c elf-properties.c format.c hash.c \
- libbfd.c linker.c merge.c opncls.c reloc.c \
- section.c simple.c stab-syms.c stabs.c syms.c targets.c \
- binary.c ihex.c srec.c tekhex.c verilog.c
-
-BFD64_LIBS_CFILES = archive64.c
-
-# This list is alphabetized to make it easier to keep in sync
-# with the decls and initializer in archures.c.
-ALL_MACHINES = \
- cpu-aarch64.lo \
- cpu-alpha.lo \
- cpu-amdgcn.lo \
- cpu-arc.lo \
- cpu-arm.lo \
- cpu-avr.lo \
- cpu-bfin.lo \
- cpu-bpf.lo \
- cpu-cr16.lo \
- cpu-cris.lo \
- cpu-crx.lo \
- cpu-csky.lo \
- cpu-d10v.lo \
- cpu-d30v.lo \
- cpu-dlx.lo \
- cpu-epiphany.lo \
- cpu-fr30.lo \
- cpu-frv.lo \
- cpu-ft32.lo \
- cpu-h8300.lo \
- cpu-hppa.lo \
- cpu-i386.lo \
- cpu-ia64.lo \
- cpu-iamcu.lo \
- cpu-ip2k.lo \
- cpu-iq2000.lo \
- cpu-kvx.lo \
- cpu-lm32.lo \
- cpu-loongarch.lo \
- cpu-m10200.lo \
- cpu-m10300.lo \
- cpu-m32c.lo \
- cpu-m32r.lo \
- cpu-m68hc11.lo \
- cpu-m68hc12.lo \
- cpu-m68k.lo \
- cpu-m9s12x.lo \
- cpu-m9s12xg.lo \
- cpu-mcore.lo \
- cpu-mep.lo \
- cpu-metag.lo \
- cpu-microblaze.lo \
- cpu-mips.lo \
- cpu-mmix.lo \
- cpu-moxie.lo \
- cpu-msp430.lo \
- cpu-mt.lo \
- cpu-nds32.lo \
- cpu-nfp.lo \
- cpu-nios2.lo \
- cpu-ns32k.lo \
- cpu-or1k.lo \
- cpu-pdp11.lo \
- cpu-pj.lo \
- cpu-powerpc.lo \
- cpu-pru.lo \
- cpu-riscv.lo \
- cpu-rl78.lo \
- cpu-rs6000.lo \
- cpu-rx.lo \
- cpu-s12z.lo \
- cpu-s390.lo \
- cpu-score.lo \
- cpu-sh.lo \
- cpu-sparc.lo \
- cpu-spu.lo \
- cpu-tic30.lo \
- cpu-tic4x.lo \
- cpu-tic54x.lo \
- cpu-tic6x.lo \
- cpu-tilegx.lo \
- cpu-tilepro.lo \
- cpu-v850.lo \
- cpu-v850_rh850.lo \
- cpu-vax.lo \
- cpu-visium.lo \
- cpu-wasm32.lo \
- cpu-xgate.lo \
- cpu-xstormy16.lo \
- cpu-xtensa.lo \
- cpu-z80.lo \
- cpu-z8k.lo
-
-ALL_MACHINES_CFILES = \
- cpu-aarch64.c \
- cpu-alpha.c \
- cpu-amdgcn.c \
- cpu-arc.c \
- cpu-arm.c \
- cpu-avr.c \
- cpu-bfin.c \
- cpu-bpf.c \
- cpu-cr16.c \
- cpu-cris.c \
- cpu-crx.c \
- cpu-csky.c \
- cpu-d10v.c \
- cpu-d30v.c \
- cpu-dlx.c \
- cpu-epiphany.c \
- cpu-fr30.c \
- cpu-frv.c \
- cpu-ft32.c \
- cpu-h8300.c \
- cpu-hppa.c \
- cpu-i386.c \
- cpu-ia64.c \
- cpu-iamcu.c \
- cpu-ip2k.c \
- cpu-iq2000.c \
- cpu-kvx.c \
- cpu-lm32.c \
- cpu-loongarch.c \
- cpu-m10200.c \
- cpu-m10300.c \
- cpu-m32c.c \
- cpu-m32r.c \
- cpu-m68hc11.c \
- cpu-m68hc12.c \
- cpu-m68k.c \
- cpu-m9s12x.c \
- cpu-m9s12xg.c \
- cpu-mcore.c \
- cpu-mep.c \
- cpu-metag.c \
- cpu-microblaze.c \
- cpu-mips.c \
- cpu-mmix.c \
- cpu-moxie.c \
- cpu-msp430.c \
- cpu-mt.c \
- cpu-nds32.c \
- cpu-nfp.c \
- cpu-nios2.c \
- cpu-ns32k.c \
- cpu-or1k.c \
- cpu-pdp11.c \
- cpu-pj.c \
- cpu-powerpc.c \
- cpu-pru.c \
- cpu-riscv.c \
- cpu-rl78.c \
- cpu-rs6000.c \
- cpu-rx.c \
- cpu-s12z.c \
- cpu-s390.c \
- cpu-score.c \
- cpu-sh.c \
- cpu-sparc.c \
- cpu-spu.c \
- cpu-tic30.c \
- cpu-tic4x.c \
- cpu-tic54x.c \
- cpu-tic6x.c \
- cpu-tilegx.c \
- cpu-tilepro.c \
- cpu-v850.c \
- cpu-v850_rh850.c \
- cpu-vax.c \
- cpu-visium.c \
- cpu-wasm32.c \
- cpu-xgate.c \
- cpu-xstormy16.c \
- cpu-xtensa.c \
- cpu-z80.c \
- cpu-z8k.c
-
-# The .o files needed by all of the 32 bit vectors that are configured into
-# target_vector in targets.c if configured with --enable-targets=all.
-BFD32_BACKENDS = \
- aout-cris.lo \
- aout-ns32k.lo \
- aout32.lo \
- cf-i386lynx.lo \
- coff-go32.lo \
- coff-i386.lo \
- coff-mips.lo \
- coff-rs6000.lo \
- coff-sh.lo \
- coff-stgo32.lo \
- coff-tic30.lo \
- coff-tic4x.lo \
- coff-tic54x.lo \
- coff-z80.lo \
- coff-z8k.lo \
- coffgen.lo \
- cofflink.lo \
- dwarf1.lo \
- dwarf2.lo \
- ecoff.lo \
- ecofflink.lo \
- elf-attrs.lo \
- elf-eh-frame.lo \
- elf-ifunc.lo \
- elf-m10200.lo \
- elf-m10300.lo \
- elf-nacl.lo \
- elf-sframe.lo \
- elf-strtab.lo \
- elf-vxworks.lo \
- elf.lo \
- elf32-am33lin.lo \
- elf32-arc.lo \
- elf32-arm.lo \
- elf32-avr.lo \
- elf32-bfin.lo \
- elf32-cr16.lo \
- elf32-cris.lo \
- elf32-crx.lo \
- elf32-csky.lo \
- elf32-d10v.lo \
- elf32-d30v.lo \
- elf32-dlx.lo \
- elf32-epiphany.lo \
- elf32-fr30.lo \
- elf32-frv.lo \
- elf32-ft32.lo \
- elf32-gen.lo \
- elf32-h8300.lo \
- elf32-hppa.lo \
- elf32-i386.lo \
- elf32-ip2k.lo \
- elf32-iq2000.lo \
- elf32-lm32.lo \
- elf32-m32c.lo \
- elf32-m32r.lo \
- elf32-m68hc11.lo \
- elf32-m68hc12.lo \
- elf32-m68hc1x.lo \
- elf32-m68k.lo \
- elf32-mcore.lo \
- elf32-mep.lo \
- elf32-metag.lo \
- elf32-microblaze.lo \
- elf32-moxie.lo \
- elf32-msp430.lo \
- elf32-mt.lo \
- elf32-nds32.lo \
- elf32-nios2.lo \
- elf32-or1k.lo \
- elf32-pj.lo \
- elf32-ppc.lo \
- elf32-pru.lo \
- elf32-rl78.lo \
- elf32-rx.lo \
- elf32-s12z.lo \
- elf32-s390.lo \
- elf32-sh.lo \
- elf32-sparc.lo \
- elf32-spu.lo \
- elf32-tic6x.lo \
- elf32-tilegx.lo \
- elf32-tilepro.lo \
- elf32-v850.lo \
- elf32-vax.lo \
- elf32-visium.lo \
- elf32-wasm32.lo \
- elf32-xgate.lo \
- elf32-xstormy16.lo \
- elf32-xtensa.lo \
- elf32-z80.lo \
- elf32.lo \
- elflink.lo \
- elfxx-sparc.lo \
- elfxx-tilegx.lo \
- elfxx-x86.lo \
- i386aout.lo \
- i386bsd.lo \
- i386lynx.lo \
- i386msdos.lo \
- mach-o-arm.lo \
- mach-o-i386.lo \
- mach-o.lo \
- ns32knetbsd.lo \
- pc532-mach.lo \
- pdb.lo \
- pdp11.lo \
- pe-arm-wince.lo \
- pe-arm.lo \
- pe-i386.lo \
- pe-mcore.lo \
- pe-sh.lo \
- pef.lo \
- pei-arm-wince.lo \
- pei-arm.lo \
- pei-i386.lo \
- pei-mcore.lo \
- pei-sh.lo \
- peigen.lo \
- plugin.lo \
- ppcboot.lo \
- reloc16.lo \
- som.lo \
- vax1knetbsd.lo \
- vaxnetbsd.lo \
- vms-lib.lo \
- vms-misc.lo \
- wasm-module.lo \
- xcofflink.lo \
- xsym.lo \
- xtensa-dynconfig.lo \
- xtensa-isa.lo \
- xtensa-modules.lo
-
-BFD32_BACKENDS_CFILES = \
- aout-cris.c \
- aout-ns32k.c \
- aout32.c \
- cf-i386lynx.c \
- coff-go32.c \
- coff-i386.c \
- coff-mips.c \
- coff-rs6000.c \
- coff-sh.c \
- coff-stgo32.c \
- coff-tic30.c \
- coff-tic4x.c \
- coff-tic54x.c \
- coff-z80.c \
- coff-z8k.c \
- coffgen.c \
- cofflink.c \
- dwarf1.c \
- dwarf2.c \
- ecoff.c \
- ecofflink.c \
- elf-attrs.c \
- elf-eh-frame.c \
- elf-ifunc.c \
- elf-m10200.c \
- elf-m10300.c \
- elf-nacl.c \
- elf-sframe.c \
- elf-strtab.c \
- elf-vxworks.c \
- elf.c \
- elf32-am33lin.c \
- elf32-arc.c \
- elf32-arm.c \
- elf32-avr.c \
- elf32-bfin.c \
- elf32-cr16.c \
- elf32-cris.c \
- elf32-crx.c \
- elf32-csky.c \
- elf32-d10v.c \
- elf32-d30v.c \
- elf32-dlx.c \
- elf32-epiphany.c \
- elf32-fr30.c \
- elf32-frv.c \
- elf32-ft32.c \
- elf32-gen.c \
- elf32-h8300.c \
- elf32-hppa.c \
- elf32-i386.c \
- elf32-ip2k.c \
- elf32-iq2000.c \
- elf32-lm32.c \
- elf32-m32c.c \
- elf32-m32r.c \
- elf32-m68hc11.c \
- elf32-m68hc12.c \
- elf32-m68hc1x.c \
- elf32-m68k.c \
- elf32-mcore.c \
- elf32-mep.c \
- elf32-metag.c \
- elf32-microblaze.c \
- elf32-moxie.c \
- elf32-msp430.c \
- elf32-mt.c \
- elf32-nds32.c \
- elf32-nios2.c \
- elf32-or1k.c \
- elf32-pj.c \
- elf32-ppc.c \
- elf32-pru.c \
- elf32-rl78.c \
- elf32-rx.c \
- elf32-s12z.c \
- elf32-s390.c \
- elf32-sh.c \
- elf32-sparc.c \
- elf32-spu.c \
- elf32-tic6x.c \
- elf32-tilegx.c \
- elf32-tilepro.c \
- elf32-v850.c \
- elf32-vax.c \
- elf32-visium.c \
- elf32-wasm32.c \
- elf32-xgate.c \
- elf32-xstormy16.c \
- elf32-xtensa.c \
- elf32-z80.c \
- elf32.c \
- elflink.c \
- elfxx-sparc.c \
- elfxx-tilegx.c \
- elfxx-x86.c \
- i386aout.c \
- i386bsd.c \
- i386lynx.c \
- i386msdos.c \
- mach-o-arm.c \
- mach-o-i386.c \
- mach-o.c \
- ns32knetbsd.c \
- pc532-mach.c \
- pdb.c \
- pdp11.c \
- pe-arm-wince.c \
- pe-arm.c \
- pe-i386.c \
- pe-mcore.c \
- pe-sh.c \
- pef.c \
- pei-arm-wince.c \
- pei-arm.c \
- pei-i386.c \
- pei-mcore.c \
- pei-sh.c \
- plugin.c \
- ppcboot.c \
- reloc16.c \
- som.c \
- vax1knetbsd.c \
- vaxnetbsd.c \
- vms-lib.c \
- vms-misc.c \
- wasm-module.c \
- xcofflink.c \
- xsym.c \
- xtensa-dynconfig.c \
- xtensa-isa.c \
- xtensa-modules.c
-
-# The .o files needed by all of the 64 bit vectors that are configured into
-# target_vector in targets.c if configured with --enable-targets=all
-# and --enable-64-bit-bfd.
-# elf32-ia64.c requires a 64-bit bfd_vma, and hence can not be put in
-# BFD32_BACKENDS.
-BFD64_BACKENDS = \
- aix5ppc-core.lo \
- aout64.lo \
- coff-alpha.lo \
- coff-x86_64.lo \
- coff64-rs6000.lo \
- elf32-aarch64.lo \
- elf32-ia64.lo \
- elf32-kvx.lo \
- elf32-loongarch.lo \
- elf32-mips.lo \
- elf32-riscv.lo \
- elf32-score.lo \
- elf32-score7.lo \
- elf64-aarch64.lo \
- elf64-alpha.lo \
- elf64-amdgcn.lo \
- elf64-bpf.lo \
- elf64-gen.lo \
- elf64-hppa.lo \
- elf64-ia64-vms.lo \
- elf64-ia64.lo \
- elf64-kvx.lo \
- elf64-loongarch.lo \
- elf64-mips.lo \
- elf64-mmix.lo \
- elf64-nfp.lo \
- elf64-ppc.lo \
- elf64-riscv.lo \
- elf64-s390.lo \
- elf64-sparc.lo \
- elf64-tilegx.lo \
- elf64-x86-64.lo \
- elf64.lo \
- elfn32-mips.lo \
- elfxx-aarch64.lo \
- elfxx-ia64.lo \
- elfxx-kvx.lo \
- elfxx-loongarch.lo \
- elfxx-mips.lo \
- elfxx-riscv.lo \
- elfxx-x86.lo \
- mach-o-aarch64.lo \
- mach-o-x86-64.lo \
- mmo.lo \
- pe-aarch64.lo \
- pe-aarch64igen.lo \
- pe-loongarch64igen.lo \
- pe-riscv64igen.lo \
- pe-x86_64.lo \
- pei-aarch64.lo \
- pei-ia64.lo \
- pei-loongarch64.lo \
- pei-riscv64.lo \
- pei-x86_64.lo \
- pepigen.lo \
- pex64igen.lo \
- vms-alpha.lo
-
-BFD64_BACKENDS_CFILES = \
- aix5ppc-core.c \
- aout64.c \
- coff-alpha.c \
- coff-x86_64.c \
- coff64-rs6000.c \
- elf32-mips.c \
- elf32-score.c \
- elf32-score7.c \
- elf64-alpha.c \
- elf64-amdgcn.c \
- elf64-bpf.c \
- elf64-gen.c \
- elf64-hppa.c \
- elf64-ia64-vms.c \
- elf64-mips.c \
- elf64-mmix.c \
- elf64-nfp.c \
- elf64-ppc.c \
- elf64-s390.c \
- elf64-sparc.c \
- elf64-tilegx.c \
- elf64-x86-64.c \
- elf64.c \
- elfn32-mips.c \
- elfxx-aarch64.c \
- elfxx-ia64.c \
- elfxx-kvx.c \
- elfxx-loongarch.c \
- elfxx-mips.c \
- elfxx-riscv.c \
- elfxx-x86.c \
- mach-o-aarch64.c \
- mach-o-x86-64.c \
- mmo.c \
- pe-aarch64.c \
- pe-x86_64.c \
- pei-aarch64.c \
- pei-ia64.c \
- pei-loongarch64.c \
- pei-riscv64.c \
- pei-x86_64.c \
- vms-alpha.c
-
-OPTIONAL_BACKENDS = \
- cisco-core.lo \
- hpux-core.lo \
- irix-core.lo \
- lynx-core.lo \
- netbsd-core.lo \
- osf-core.lo \
- rs6000-core.lo \
- trad-core.lo
-
-OPTIONAL_BACKENDS_CFILES = \
- cisco-core.c \
- hpux-core.c \
- irix-core.c \
- lynx-core.c \
- netbsd-core.c \
- osf-core.c \
- rs6000-core.c \
- trad-core.c
-
-# Reconfigure if config.bfd or configure.host changes.
-# development.sh is used to determine -Werror default.
-CONFIG_STATUS_DEPENDENCIES = \
- $(srcdir)/config.bfd \
- $(srcdir)/configure.host \
- $(srcdir)/development.sh
-
-# These are defined by configure:
-WORDSIZE = @wordsize@
-ALL_BACKENDS = @all_backends@
-BFD_BACKENDS = @bfd_backends@
-BFD_MACHINES = @bfd_machines@
-TDEFAULTS = @tdefaults@
-HAVEVECS = @havevecs@
-
-AM_CPPFLAGS += @HDEFINES@ @COREFLAG@ @TDEFINES@ $(CSEARCH) $(CSWITCHES) \
- $(HAVEVECS) @INCINTL@
-
-# C source files that correspond to .o's.
-SOURCE_CFILES = \
- $(BFD32_LIBS_CFILES) \
- $(BFD64_LIBS_CFILES) \
- $(ALL_MACHINES_CFILES) \
- $(BFD32_BACKENDS_CFILES) \
- $(BFD64_BACKENDS_CFILES) \
- $(OPTIONAL_BACKENDS_CFILES)
-
-BUILD_CFILES = \
- elf32-aarch64.c elf64-aarch64.c \
- elf32-kvx.c elf64-kvx.c \
- elf32-ia64.c elf64-ia64.c \
- elf32-loongarch.c elf64-loongarch.c \
- elf32-riscv.c elf64-riscv.c \
- peigen.c pepigen.c pex64igen.c pe-aarch64igen.c pe-loongarch64igen.c \
- pe-riscv64igen.c
-
-CFILES = $(SOURCE_CFILES) $(BUILD_CFILES)
-
-## This is a list of all .h files in the source tree minus those that
-## are processed to produce other .h files
-SOURCE_HFILES = \
- aout-target.h aoutx.h arc-got.h arc-plt.h \
- coff-arm.h coff-bfd.h coffcode.h coffswap.h \
- cpu-aarch64.h cpu-arm.h cpu-h8300.h cpu-m68k.h cpu-riscv.h \
- ecoff-bfd.h ecoffswap.h \
- elf32-arm.h elf32-avr.h elf32-bfin.h elf32-cr16.h elf32-csky.h \
- elf32-dlx.h elf32-hppa.h elf32-m68hc1x.h elf32-m68k.h \
- elf32-metag.h elf32-nds32.h elf32-nios2.h elf32-ppc.h \
- elf32-rx.h elf32-score.h elf32-sh-relocs.h elf32-spu.h \
- elf32-tic6x.h elf32-tilegx.h elf32-tilepro.h elf32-v850.h \
- elf64-hppa.h elf64-ppc.h elf64-tilegx.h \
- elf-bfd.h elfcode.h elfcore.h elf-hppa.h elf-linker-x86.h \
- elf-linux-core.h elf-nacl.h elf-s390.h elf-vxworks.h \
- elfxx-aarch64.h elfxx-ia64.h elfxx-mips.h elfxx-riscv.h \
- elfxx-sparc.h elfxx-tilegx.h elfxx-x86.h elfxx-loongarch.h \
- genlink.h go32stub.h \
- libaout.h libbfd.h libcoff.h libecoff.h libhppa.h \
- libpei.h libxcoff.h \
- mach-o.h \
- netbsd.h ns32k.h \
- pef.h pef-traceback.h peicode.h plugin.h \
- som.h sysdep.h \
- version.h vms.h \
- wasm-module.h \
- xcofflink.h xsym.h
-
-## ... and .h files which are in the build tree, minus config.h and bfd.h
-BUILD_HFILES = \
- bfdver.h elf32-target.h elf64-target.h targmatch.h
-
-# Ensure they are built early:
-BUILT_SOURCES = $(BUILD_HFILES) @MAINT@ $(BUILD_CFILES)
-
-HFILES = $(SOURCE_HFILES) $(BUILD_HFILES)
-
-BFD_H_DEPS = $(INCDIR)/ansidecl.h $(INCDIR)/symcat.h $(INCDIR)/diagnostics.h
-LOCAL_H_DEPS = libbfd.h sysdep.h config.h
-$(BFD32_LIBS) \
- $(BFD64_LIBS) \
- $(ALL_MACHINES) \
- $(BFD32_BACKENDS) \
- $(BFD64_BACKENDS) \
- $(OPTIONAL_BACKENDS): $(BFD_H) $(BFD_H_DEPS) $(LOCAL_H_DEPS)
-
-SRC_POTFILES = $(SOURCE_CFILES) $(SOURCE_HFILES)
-BLD_POTFILES = $(BUILD_CFILES) $(BUILD_HFILES)
-
-po/SRC-POTFILES.in: @MAINT@ Makefile
- for file in $(SRC_POTFILES); do echo $$file; done \
- | LC_ALL=C sort | uniq > tmp.src \
- && mv tmp.src $(srcdir)/po/SRC-POTFILES.in
-
-po/BLD-POTFILES.in: @MAINT@ Makefile
- for file in $(BLD_POTFILES); do echo $$file; done \
- | LC_ALL=C sort | uniq > tmp.bld \
- && mv tmp.bld $(srcdir)/po/BLD-POTFILES.in
-
-all diststuff: info
-
-# Various kinds of .o files to put in libbfd.a:
-# BFD_BACKENDS Routines the configured targets need.
-# BFD_MACHINES Architecture-specific routines the configured targets need.
-# COREFILE Core file routines for a native configuration
-# bfd64_libs Routines for 64bit support
-OFILES = $(BFD_BACKENDS) $(BFD_MACHINES) @COREFILE@ @bfd64_libs@
-
-stamp-ofiles: Makefile
- rm -f tofiles
- f=""; \
- for i in $(OFILES) ; do \
- case " $$f " in \
- *" $$i "*) ;; \
- *) f="$$f $$i" ;; \
- esac ; \
- done ; \
- echo $$f > tofiles
- $(SHELL) $(srcdir)/../move-if-change tofiles ofiles
- touch stamp-ofiles
-
-ofiles: stamp-ofiles ; @true
-
-# Since BFD64_LIBS is optional and we can't have substitution in
-# libbfd_la_SOURCES, we put BFD64_LIBS in OFILES instead.
-# However, list all sources in EXTRA_libbfd_la_SOURCES so the
-# dependency tracking fragments are picked up in the Makefile.
-libbfd_la_SOURCES = $(BFD32_LIBS_CFILES)
-EXTRA_libbfd_la_SOURCES = $(CFILES)
-libbfd_la_DEPENDENCIES = $(OFILES) ofiles ../libsframe/libsframe.la
-libbfd_la_LIBADD = `cat ofiles` @SHARED_LIBADD@ $(LIBDL) $(ZLIB) $(ZSTD_LIBS) ../libsframe/libsframe.la
-libbfd_la_LDFLAGS += -release `cat libtool-soversion` @SHARED_LDFLAGS@
-
-# This file holds an array associating configuration triplets and
-# vector names. It is built from config.bfd. It is not compiled by
-# itself, but is included by targets.c.
-targmatch.h: config.bfd targmatch.sed
- $(AM_V_at)rm -f targmatch.new
- $(AM_V_GEN)$(SED) -f $(srcdir)/targmatch.sed < $(srcdir)/config.bfd > targmatch.new
- $(AM_V_at)mv -f targmatch.new targmatch.h
-
-# When compiling archures.c and targets.c, supply the default target
-# info from configure.
-
-targets.lo: targets.c Makefile
-if am__fastdepCC
- $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $(TDEFAULTS) $(srcdir)/targets.c
- $(AM_V_at)mv -f $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
-else
-if AMDEP
- source='targets.c' object='$@' libtool=yes @AMDEPBACKSLASH@
- DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-endif
- $(AM_V_CC)$(LTCOMPILE) -c -o $@ $(TDEFAULTS) $(srcdir)/targets.c
-endif
-
-archures.lo: archures.c Makefile
-if am__fastdepCC
- $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $(TDEFAULTS) $(srcdir)/archures.c
- $(AM_V_at)mv -f $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
-else
-if AMDEP
- source='archures.c' object='$@' libtool=yes @AMDEPBACKSLASH@
- DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-endif
- $(AM_V_CC)$(LTCOMPILE) -c -o $@ $(TDEFAULTS) $(srcdir)/archures.c
-endif
-
-dwarf2.lo: dwarf2.c Makefile
-if am__fastdepCC
- $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ -DDEBUGDIR=\"$(DEBUGDIR)\" $(srcdir)/dwarf2.c
- $(AM_V_at)mv -f $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
-else
-if AMDEP
- source='dwarf2.c' object='$@' libtool=yes @AMDEPBACKSLASH@
- DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-endif
- $(AM_V_CC)$(LTCOMPILE) -c -o $@ -DDEBUGDIR=\"$(DEBUGDIR)\" $(srcdir)/dwarf2.c
-endif
-
-elf32-target.h : elfxx-target.h
- $(AM_V_GEN)$(SED) -e s/NN/32/g < $< > $@
-
-elf64-target.h : elfxx-target.h
- $(AM_V_GEN)$(SED) -e s/NN/64/g < $< > $@
-
-elf32-aarch64.c : elfnn-aarch64.c
- $(AM_V_at)echo "#line 1 \"$<\"" > $@
- $(AM_V_GEN)$(SED) -e s/NN/32/g < $< >> $@
-
-elf64-aarch64.c : elfnn-aarch64.c
- $(AM_V_at)echo "#line 1 \"$<\"" > $@
- $(AM_V_GEN)$(SED) -e s/NN/64/g < $< >> $@
-
-elf32-ia64.c : elfnn-ia64.c
- $(AM_V_at)echo "#line 1 \"$<\"" > $@
- $(AM_V_GEN)$(SED) -e s/NN/32/g < $< >> $@
-
-elf64-ia64.c : elfnn-ia64.c
- $(AM_V_at)echo "#line 1 \"$<\"" > $@
- $(AM_V_GEN)$(SED) -e s/NN/64/g < $< >> $@
-
-elf32-kvx.c : elfnn-kvx.c
- $(AM_V_at)echo "#line 1 \"$<\"" > $@
- $(AM_V_GEN)$(SED) -e s/NN/32/g < $< >> $@
-
-elf64-kvx.c : elfnn-kvx.c
- $(AM_V_at)echo "#line 1 \"$<\"" > $@
- $(AM_V_GEN)$(SED) -e s/NN/64/g < $< >> $@
-
-elf32-loongarch.c : elfnn-loongarch.c
- $(AM_V_at)echo "#line 1 \"$<\"" > $@
- $(AM_V_GEN)$(SED) -e s/NN/32/g < $< >> $@
-
-elf64-loongarch.c : elfnn-loongarch.c
- $(AM_V_at)echo "#line 1 \"$<\"" > $@
- $(AM_V_GEN)$(SED) -e s/NN/64/g < $< >> $@
-
-elf32-riscv.c : elfnn-riscv.c
- $(AM_V_at)echo "#line 1 \"$<\"" > $@
- $(AM_V_GEN)$(SED) -e s/NN/32/g < $< >> $@
-
-elf64-riscv.c : elfnn-riscv.c
- $(AM_V_at)echo "#line 1 \"$<\"" > $@
- $(AM_V_GEN)$(SED) -e s/NN/64/g < $< >> $@
-
-peigen.c : peXXigen.c
- $(AM_V_at)echo "#line 1 \"$<\"" > $@
- $(AM_V_GEN)$(SED) -e s/XX/pe/g < $< >> $@
-
-pepigen.c : peXXigen.c
- $(AM_V_at)echo "#line 1 \"$<\"" > $@
- $(AM_V_GEN)$(SED) -e s/XX/pep/g < $< >> $@
-
-pex64igen.c: peXXigen.c
- $(AM_V_at)echo "#line 1 \"$<\"" > $@
- $(AM_V_GEN)$(SED) -e s/XX/pex64/g < $< >> $@
-
-pe-aarch64igen.c: peXXigen.c
- $(AM_V_at)echo "#line 1 \"$<\"" > $@
- $(AM_V_GEN)$(SED) -e s/XX/peAArch64/g < $< >> $@
-
-pe-loongarch64igen.c: peXXigen.c
- $(AM_V_at)echo "#line 1 \"$<\"" > $@
- $(AM_V_GEN)$(SED) -e s/XX/peLoongArch64/g < $< >> $@
-
-pe-riscv64igen.c: peXXigen.c
- $(AM_V_at)echo "#line 1 \"peXXigen.c\"" > $@
- $(AM_V_GEN)$(SED) -e s/XX/peRiscV64/g < $< >> $@
-
-host-aout.lo: Makefile
-
-# The following program can be used to generate a simple config file
-# which can be folded into an h-XXX file for a new host, with some editing.
-aout-params.h: gen-aout
- ./gen-aout host > aout-params.h
-gen-aout: $(srcdir)/gen-aout.c Makefile
- $(CC) -o gen-aout $(CFLAGS) $(LFLAGS) $(srcdir)/gen-aout.c
-
-$(BFD_H): stmp-bfd-h ; @true
-
-stmp-bfd-h: bfd-in3.h
- rm -f bfd-tmp.h
- cp bfd-in3.h bfd-tmp.h
- $(SHELL) $(srcdir)/../move-if-change bfd-tmp.h $(BFD_H)
- rm -f bfd-tmp.h
- touch stmp-bfd-h
-
-BFD_H_FILES = bfd-in.h libbfd.c hash.c section.c syms.c \
- archive.c archures.c bfd.c bfdio.c \
- cache.c compress.c corefile.c format.c linker.c opncls.c \
- reloc.c simple.c stab-syms.c stabs.c targets.c
-BFD64_H_FILES = archive64.c
-LIBBFD_H_FILES = libbfd-in.h libbfd.c bfd.c bfdio.c \
- archive.c archures.c cache.c hash.c linker.c opncls.c \
- reloc.c section.c stabs.c targets.c
-LIBCOFF_H_FILES = libcoff-in.h coffcode.h
-
-headers: stmp-bin2-h stmp-lbfd-h stmp-lcoff-h
-
-# We only rebuild the header files automatically if we have been
-# configured with --enable-maintainer-mode.
-
-REGEN_HEADER = \
- ( \
- set -e; \
- echo "$$H_FILES" | sed -f $(srcdir)/doc/header.sed; \
- for file in $$H_FILES; do \
- file="$(srcdir)/$$file"; \
- case $$file in \
- *-in.h) cat $$file;; \
- *) echo $$file | sed -e 's,.*/,,' -e 's,^,/* Extracted from ,' \
- -e 's,$$,. */,'; \
- $(MKDOC) $$CHEW_FLAGS -f $(srcdir)/doc/proto.str < $$file;; \
- esac; \
- done; \
- echo "\#ifdef __cplusplus"; \
- echo "}"; \
- echo "\#endif"; \
- echo "\#endif"; \
- )
-
-$(srcdir)/bfd-in2.h: @MAINT@ stmp-bin2-h ; @true
-stmp-bin2-h: $(BFD_H_FILES) $(BFD64_H_FILES) $(MKDOC)
- $(AM_V_GEN)H_FILES="$(BFD_H_FILES)" CHEW_FLAGS= ; $(REGEN_HEADER) > bfd-in2.h-new
- $(AM_V_at)$(SHELL) $(srcdir)/../move-if-change bfd-in2.h-new $(srcdir)/bfd-in2.h
- $(AM_V_at)touch stmp-bin2-h
-
-$(srcdir)/libbfd.h: @MAINT@ stmp-lbfd-h ; @true
-stmp-lbfd-h: $(LIBBFD_H_FILES) $(MKDOC)
- $(AM_V_GEN)H_FILES="$(LIBBFD_H_FILES)" CHEW_FLAGS=-i ; $(REGEN_HEADER) > libbfd.h-new
- $(AM_V_at)$(SHELL) $(srcdir)/../move-if-change libbfd.h-new $(srcdir)/libbfd.h
- $(AM_V_at)touch stmp-lbfd-h
-
-$(srcdir)/libcoff.h: @MAINT@ stmp-lcoff-h ; @true
-stmp-lcoff-h: $(LIBCOFF_H_FILES) $(MKDOC)
- $(AM_V_GEN)H_FILES="$(LIBCOFF_H_FILES)" CHEW_FLAGS=-i ; $(REGEN_HEADER) > libcoff.h-new
- $(AM_V_at)$(SHELL) $(srcdir)/../move-if-change libcoff.h-new $(srcdir)/libcoff.h
- $(AM_V_at)touch stmp-lcoff-h
-
-MOSTLYCLEANFILES += ofiles stamp-ofiles
-
-CLEANFILES += bfd.h dep.sed stmp-bfd-h DEP DEPA DEP1 DEP2 \
- stmp-bin2-h stmp-lbfd-h stmp-lcoff-h
-
-DISTCLEANFILES += $(BUILD_CFILES) $(BUILD_HFILES) libtool-soversion
-
-bfdver.h: $(srcdir)/version.h $(srcdir)/development.sh $(srcdir)/Makefile.in
- $(AM_V_GEN)\
- bfd_version=`echo "$(VERSION)" | $(SED) -e 's/\([^\.]*\)\.*\([^\.]*\)\.*\([^\.]*\)\.*\([^\.]*\)\.*\([^\.]*\).*/\1.00\2.00\3.00\4.00\5/' -e 's/\([^\.]*\)\..*\(..\)\..*\(..\)\..*\(..\)\..*\(..\)$$/\1\2\3\4\5/'` ;\
- bfd_version_string="\"$(VERSION)\"" ;\
- bfd_soversion="$(VERSION)" ;\
- bfd_version_package="\"$(PKGVERSION)\"" ;\
- report_bugs_to="\"$(REPORT_BUGS_TO)\"" ;\
- . $(srcdir)/development.sh ;\
- if test "$$development" = true ; then \
- bfd_version_date=`$(SED) -n -e 's/.*DATE //p' < $(srcdir)/version.h` ;\
- bfd_version_string="\"$(VERSION).$${bfd_version_date}\"" ;\
- bfd_soversion="$(VERSION).$${bfd_version_date}" ;\
- fi ;\
- $(SED) -e "s,@bfd_version@,$$bfd_version," \
- -e "s,@bfd_version_string@,$$bfd_version_string," \
- -e "s,@bfd_version_package@,$$bfd_version_package," \
- -e "s,@report_bugs_to@,$$report_bugs_to," \
- < $(srcdir)/version.h > $@; \
- echo "$${bfd_soversion}" > libtool-soversion
-
-# Disable -Werror, if it has been enabled, since coffswap.h won't
-# compile with gcc 4.5 and above.
-coff-tic4x.lo: coff-tic4x.c
-@am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< $(NO_WERROR)
-@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
-@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@ $(AM_V_CC)$(LTCOMPILE) -c -o $@ $< $(NO_WERROR)
-
-coff-tic54x.lo: coff-tic54x.c
-@am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< $(NO_WERROR)
-@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
-@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
-@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@ $(AM_V_CC)$(LTCOMPILE) -c -o $@ $< $(NO_WERROR)
-
-include doc/local.mk
Index: sources/GNU/binutils/create-2.43.1-no-config-check-patch/file.list
===================================================================
--- sources/GNU/binutils/create-2.43.1-no-config-check-patch/file.list (revision 75)
+++ sources/GNU/binutils/create-2.43.1-no-config-check-patch/file.list (nonexistent)
@@ -1,2 +0,0 @@
-binutils-2.43.1/bfd/bfd-in.h
-binutils-2.43.1/bfd/bfd-in2.h
Index: sources/GNU/binutils/create-2.43.1-no-config-check-patch/create.patch.sh
===================================================================
--- sources/GNU/binutils/create-2.43.1-no-config-check-patch/create.patch.sh (revision 75)
+++ sources/GNU/binutils/create-2.43.1-no-config-check-patch/create.patch.sh (nonexistent)
@@ -1,15 +0,0 @@
-#!/bin/bash
-
-VERSION=2.43.1
-
-tar --files-from=file.list -xJvf ../binutils-$VERSION.tar.xz
-mv binutils-$VERSION binutils-$VERSION-orig
-
-cp -rf ./binutils-$VERSION-new ./binutils-$VERSION
-
-diff --unified -Nr binutils-$VERSION-orig binutils-$VERSION > binutils-$VERSION-no-config-check.patch
-
-mv binutils-$VERSION-no-config-check.patch ../patches
-
-rm -rf ./binutils-$VERSION
-rm -rf ./binutils-$VERSION-orig
Property changes on: sources/GNU/binutils/create-2.43.1-no-config-check-patch/create.patch.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: sources/GNU/binutils/create-2.43.1-no-config-check-patch/binutils-2.43.1-new/bfd/bfd-in.h
===================================================================
--- sources/GNU/binutils/create-2.43.1-no-config-check-patch/binutils-2.43.1-new/bfd/bfd-in.h (revision 75)
+++ sources/GNU/binutils/create-2.43.1-no-config-check-patch/binutils-2.43.1-new/bfd/bfd-in.h (nonexistent)
@@ -1,156 +0,0 @@
-/* Main header file for the bfd library -- portable access to object files.
-
- Copyright (C) 1990-2024 Free Software Foundation, Inc.
-
- Contributed by Cygnus Support.
-
- This file is part of BFD, the Binary File Descriptor library.
-
- This program is free software; you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation; either version 3 of the License, or
- (at your option) any later version.
-
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program; if not, write to the Free Software
- Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA. */
-
-#ifndef __BFD_H_SEEN__
-#define __BFD_H_SEEN__
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-#include "ansidecl.h"
-#include "symcat.h"
-#include <stdint.h>
-#include <stdbool.h>
-#include <time.h>
-#include "diagnostics.h"
-#include <stdarg.h>
-#include <string.h>
-#include <sys/stat.h>
-
-#if defined (__STDC__) || defined (ALMOST_STDC) || defined (HAVE_STRINGIZE)
-#ifndef SABER
-/* This hack is to avoid a problem with some strict ANSI C preprocessors.
- The problem is, "32_" is not a valid preprocessing token, and we don't
- want extra underscores (e.g., "nlm_32_"). The XCONCAT2 macro will
- cause the inner CONCAT2 macros to be evaluated first, producing
- still-valid pp-tokens. Then the final concatenation can be done. */
-#undef CONCAT4
-#define CONCAT4(a,b,c,d) XCONCAT2(CONCAT2(a,b),CONCAT2(c,d))
-#endif
-#endif
-
-/* This is a utility macro to handle the situation where the code
- wants to place a constant string into the code, followed by a
- comma and then the length of the string. Doing this by hand
- is error prone, so using this macro is safer. */
-#define STRING_COMMA_LEN(STR) (STR), (sizeof (STR) - 1)
-
-#define BFD_SUPPORTS_PLUGINS @supports_plugins@
-
-/* The word size used by BFD on the host. This may be 64 with a 32
- bit target if the host is 64 bit, or if other 64 bit targets have
- been selected with --enable-targets, or if --enable-64-bit-bfd. */
-#define BFD_ARCH_SIZE @wordsize@
-
-/* The word size of the default bfd target. */
-#define BFD_DEFAULT_TARGET_SIZE @bfd_default_target_size@
-
-#include <inttypes.h>
-
-#if BFD_ARCH_SIZE >= 64
-#define BFD64
-#endif
-
-/* Boolean type used in bfd.
- General rule: Functions which are bfd_boolean return TRUE on
- success and FALSE on failure (unless they're a predicate). */
-
-#ifdef POISON_BFD_BOOLEAN
-# pragma GCC poison bfd_boolean
-#else
-# define bfd_boolean bool
-# undef FALSE
-# undef TRUE
-# define FALSE 0
-# define TRUE 1
-#endif
-
-/* Silence "applying zero offset to null pointer" UBSAN warnings. */
-#define PTR_ADD(P,A) ((A) != 0 ? (P) + (A) : (P))
-/* Also prevent non-zero offsets from being applied to a null pointer. */
-#define NPTR_ADD(P,A) ((P) != NULL ? (P) + (A) : (P))
-
-#ifdef BFD64
-
-/* Represent a target address. Also used as a generic unsigned type
- which is guaranteed to be big enough to hold any arithmetic types
- we need to deal with. */
-typedef uint64_t bfd_vma;
-
-/* A generic signed type which is guaranteed to be big enough to hold any
- arithmetic types we need to deal with. Can be assumed to be compatible
- with bfd_vma in the same way that signed and unsigned ints are compatible
- (as parameters, in assignment, etc). */
-typedef int64_t bfd_signed_vma;
-
-typedef uint64_t bfd_size_type;
-typedef uint64_t symvalue;
-
-#else /* not BFD64 */
-
-typedef uint32_t bfd_vma;
-typedef int32_t bfd_signed_vma;
-typedef uint32_t bfd_size_type;
-typedef uint32_t symvalue;
-
-#endif /* not BFD64 */
-
-#define HALF_BFD_SIZE_TYPE \
- (((bfd_size_type) 1) << (8 * sizeof (bfd_size_type) / 2))
-
-/* An offset into a file. BFD always uses the largest possible offset
- based on the build time availability of fseek, fseeko, or fseeko64. */
-typedef @bfd_file_ptr@ file_ptr;
-typedef @bfd_ufile_ptr@ ufile_ptr;
-
-typedef uint32_t flagword; /* 32 bits of flags */
-typedef uint8_t bfd_byte;
-
-/* Forward declarations. */
-typedef struct bfd bfd;
-struct bfd_link_info;
-struct bfd_link_hash_entry;
-typedef struct bfd_section *sec_ptr;
-typedef struct reloc_cache_entry arelent;
-struct orl;
-
-#define align_power(addr, align) \
- (((addr) + ((bfd_vma) 1 << (align)) - 1) & (-((bfd_vma) 1 << (align))))
-
-/* Align an address upward to a boundary, expressed as a number of bytes.
- E.g. align to an 8-byte boundary with argument of 8. Take care never
- to wrap around if the address is within boundary-1 of the end of the
- address space. */
-#define BFD_ALIGN(this, boundary) \
- ((((bfd_vma) (this) + (boundary) - 1) >= (bfd_vma) (this)) \
- ? (((bfd_vma) (this) + ((boundary) - 1)) & ~ (bfd_vma) ((boundary)-1)) \
- : ~ (bfd_vma) 0)
-
-/* Return TRUE if the start of STR matches PREFIX, FALSE otherwise. */
-
-static inline bool
-startswith (const char *str, const char *prefix)
-{
- return strncmp (str, prefix, strlen (prefix)) == 0;
-}
-
Index: sources/GNU/binutils/create-2.43.1-no-config-check-patch/binutils-2.43.1-new/bfd/bfd-in2.h
===================================================================
--- sources/GNU/binutils/create-2.43.1-no-config-check-patch/binutils-2.43.1-new/bfd/bfd-in2.h (revision 75)
+++ sources/GNU/binutils/create-2.43.1-no-config-check-patch/binutils-2.43.1-new/bfd/bfd-in2.h (nonexistent)
@@ -1,8096 +0,0 @@
-/* DO NOT EDIT! -*- buffer-read-only: t -*- This file is automatically
- generated from "bfd-in.h", "libbfd.c", "hash.c", "section.c",
- "syms.c", "archive.c", "archures.c", "bfd.c", "bfdio.c", "cache.c",
- "compress.c", "corefile.c", "format.c", "linker.c", "opncls.c",
- "reloc.c", "simple.c", "stab-syms.c", "stabs.c" and "targets.c".
- Run "make headers" in your build bfd/ to regenerate. */
-
-/* Main header file for the bfd library -- portable access to object files.
-
- Copyright (C) 1990-2024 Free Software Foundation, Inc.
-
- Contributed by Cygnus Support.
-
- This file is part of BFD, the Binary File Descriptor library.
-
- This program is free software; you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation; either version 3 of the License, or
- (at your option) any later version.
-
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program; if not, write to the Free Software
- Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA. */
-
-#ifndef __BFD_H_SEEN__
-#define __BFD_H_SEEN__
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-#include "ansidecl.h"
-#include "symcat.h"
-#include <stdint.h>
-#include <stdbool.h>
-#include <time.h>
-#include "diagnostics.h"
-#include <stdarg.h>
-#include <string.h>
-#include <sys/stat.h>
-
-#if defined (__STDC__) || defined (ALMOST_STDC) || defined (HAVE_STRINGIZE)
-#ifndef SABER
-/* This hack is to avoid a problem with some strict ANSI C preprocessors.
- The problem is, "32_" is not a valid preprocessing token, and we don't
- want extra underscores (e.g., "nlm_32_"). The XCONCAT2 macro will
- cause the inner CONCAT2 macros to be evaluated first, producing
- still-valid pp-tokens. Then the final concatenation can be done. */
-#undef CONCAT4
-#define CONCAT4(a,b,c,d) XCONCAT2(CONCAT2(a,b),CONCAT2(c,d))
-#endif
-#endif
-
-/* This is a utility macro to handle the situation where the code
- wants to place a constant string into the code, followed by a
- comma and then the length of the string. Doing this by hand
- is error prone, so using this macro is safer. */
-#define STRING_COMMA_LEN(STR) (STR), (sizeof (STR) - 1)
-
-#define BFD_SUPPORTS_PLUGINS @supports_plugins@
-
-/* The word size used by BFD on the host. This may be 64 with a 32
- bit target if the host is 64 bit, or if other 64 bit targets have
- been selected with --enable-targets, or if --enable-64-bit-bfd. */
-#define BFD_ARCH_SIZE @wordsize@
-
-/* The word size of the default bfd target. */
-#define BFD_DEFAULT_TARGET_SIZE @bfd_default_target_size@
-
-#include <inttypes.h>
-
-#if BFD_ARCH_SIZE >= 64
-#define BFD64
-#endif
-
-/* Boolean type used in bfd.
- General rule: Functions which are bfd_boolean return TRUE on
- success and FALSE on failure (unless they're a predicate). */
-
-#ifdef POISON_BFD_BOOLEAN
-# pragma GCC poison bfd_boolean
-#else
-# define bfd_boolean bool
-# undef FALSE
-# undef TRUE
-# define FALSE 0
-# define TRUE 1
-#endif
-
-/* Silence "applying zero offset to null pointer" UBSAN warnings. */
-#define PTR_ADD(P,A) ((A) != 0 ? (P) + (A) : (P))
-/* Also prevent non-zero offsets from being applied to a null pointer. */
-#define NPTR_ADD(P,A) ((P) != NULL ? (P) + (A) : (P))
-
-#ifdef BFD64
-
-/* Represent a target address. Also used as a generic unsigned type
- which is guaranteed to be big enough to hold any arithmetic types
- we need to deal with. */
-typedef uint64_t bfd_vma;
-
-/* A generic signed type which is guaranteed to be big enough to hold any
- arithmetic types we need to deal with. Can be assumed to be compatible
- with bfd_vma in the same way that signed and unsigned ints are compatible
- (as parameters, in assignment, etc). */
-typedef int64_t bfd_signed_vma;
-
-typedef uint64_t bfd_size_type;
-typedef uint64_t symvalue;
-
-#else /* not BFD64 */
-
-typedef uint32_t bfd_vma;
-typedef int32_t bfd_signed_vma;
-typedef uint32_t bfd_size_type;
-typedef uint32_t symvalue;
-
-#endif /* not BFD64 */
-
-#define HALF_BFD_SIZE_TYPE \
- (((bfd_size_type) 1) << (8 * sizeof (bfd_size_type) / 2))
-
-/* An offset into a file. BFD always uses the largest possible offset
- based on the build time availability of fseek, fseeko, or fseeko64. */
-typedef @bfd_file_ptr@ file_ptr;
-typedef @bfd_ufile_ptr@ ufile_ptr;
-
-typedef uint32_t flagword; /* 32 bits of flags */
-typedef uint8_t bfd_byte;
-
-/* Forward declarations. */
-typedef struct bfd bfd;
-struct bfd_link_info;
-struct bfd_link_hash_entry;
-typedef struct bfd_section *sec_ptr;
-typedef struct reloc_cache_entry arelent;
-struct orl;
-
-#define align_power(addr, align) \
- (((addr) + ((bfd_vma) 1 << (align)) - 1) & (-((bfd_vma) 1 << (align))))
-
-/* Align an address upward to a boundary, expressed as a number of bytes.
- E.g. align to an 8-byte boundary with argument of 8. Take care never
- to wrap around if the address is within boundary-1 of the end of the
- address space. */
-#define BFD_ALIGN(this, boundary) \
- ((((bfd_vma) (this) + (boundary) - 1) >= (bfd_vma) (this)) \
- ? (((bfd_vma) (this) + ((boundary) - 1)) & ~ (bfd_vma) ((boundary)-1)) \
- : ~ (bfd_vma) 0)
-
-/* Return TRUE if the start of STR matches PREFIX, FALSE otherwise. */
-
-static inline bool
-startswith (const char *str, const char *prefix)
-{
- return strncmp (str, prefix, strlen (prefix)) == 0;
-}
-
-/* Extracted from libbfd.c. */
-void *bfd_alloc (bfd *abfd, bfd_size_type wanted);
-
-void *bfd_zalloc (bfd *abfd, bfd_size_type wanted);
-
-void bfd_release (bfd *, void *);
-
-
-/* Byte swapping macros for user section data. */
-
-#define bfd_put_8(abfd, val, ptr) \
- ((void) (*((bfd_byte *) (ptr)) = (val) & 0xff))
-#define bfd_put_signed_8 \
- bfd_put_8
-#define bfd_get_8(abfd, ptr) \
- ((bfd_vma) *(const bfd_byte *) (ptr) & 0xff)
-#define bfd_get_signed_8(abfd, ptr) \
- ((((bfd_signed_vma) *(const bfd_byte *) (ptr) & 0xff) ^ 0x80) - 0x80)
-
-#define bfd_put_16(abfd, val, ptr) \
- BFD_SEND (abfd, bfd_putx16, ((val),(ptr)))
-#define bfd_put_signed_16 \
- bfd_put_16
-#define bfd_get_16(abfd, ptr) \
- BFD_SEND (abfd, bfd_getx16, (ptr))
-#define bfd_get_signed_16(abfd, ptr) \
- BFD_SEND (abfd, bfd_getx_signed_16, (ptr))
-
-#define bfd_put_24(abfd, val, ptr) \
- do \
- if (bfd_big_endian (abfd)) \
- bfd_putb24 ((val), (ptr)); \
- else \
- bfd_putl24 ((val), (ptr)); \
- while (0)
-
-bfd_vma bfd_getb24 (const void *p);
-bfd_vma bfd_getl24 (const void *p);
-
-#define bfd_get_24(abfd, ptr) \
- (bfd_big_endian (abfd) ? bfd_getb24 (ptr) : bfd_getl24 (ptr))
-
-#define bfd_put_32(abfd, val, ptr) \
- BFD_SEND (abfd, bfd_putx32, ((val),(ptr)))
-#define bfd_put_signed_32 \
- bfd_put_32
-#define bfd_get_32(abfd, ptr) \
- BFD_SEND (abfd, bfd_getx32, (ptr))
-#define bfd_get_signed_32(abfd, ptr) \
- BFD_SEND (abfd, bfd_getx_signed_32, (ptr))
-
-#define bfd_put_64(abfd, val, ptr) \
- BFD_SEND (abfd, bfd_putx64, ((val), (ptr)))
-#define bfd_put_signed_64 \
- bfd_put_64
-#define bfd_get_64(abfd, ptr) \
- BFD_SEND (abfd, bfd_getx64, (ptr))
-#define bfd_get_signed_64(abfd, ptr) \
- BFD_SEND (abfd, bfd_getx_signed_64, (ptr))
-
-#define bfd_get(bits, abfd, ptr) \
- ((bits) == 8 ? bfd_get_8 (abfd, ptr) \
- : (bits) == 16 ? bfd_get_16 (abfd, ptr) \
- : (bits) == 32 ? bfd_get_32 (abfd, ptr) \
- : (bits) == 64 ? bfd_get_64 (abfd, ptr) \
- : (abort (), (bfd_vma) - 1))
-
-#define bfd_put(bits, abfd, val, ptr) \
- ((bits) == 8 ? bfd_put_8 (abfd, val, ptr) \
- : (bits) == 16 ? bfd_put_16 (abfd, val, ptr) \
- : (bits) == 32 ? bfd_put_32 (abfd, val, ptr) \
- : (bits) == 64 ? bfd_put_64 (abfd, val, ptr) \
- : (abort (), (void) 0))
-
-
-/* Byte swapping macros for file header data. */
-
-#define bfd_h_put_8(abfd, val, ptr) \
- bfd_put_8 (abfd, val, ptr)
-#define bfd_h_put_signed_8(abfd, val, ptr) \
- bfd_put_8 (abfd, val, ptr)
-#define bfd_h_get_8(abfd, ptr) \
- bfd_get_8 (abfd, ptr)
-#define bfd_h_get_signed_8(abfd, ptr) \
- bfd_get_signed_8 (abfd, ptr)
-
-#define bfd_h_put_16(abfd, val, ptr) \
- BFD_SEND (abfd, bfd_h_putx16, (val, ptr))
-#define bfd_h_put_signed_16 \
- bfd_h_put_16
-#define bfd_h_get_16(abfd, ptr) \
- BFD_SEND (abfd, bfd_h_getx16, (ptr))
-#define bfd_h_get_signed_16(abfd, ptr) \
- BFD_SEND (abfd, bfd_h_getx_signed_16, (ptr))
-
-#define bfd_h_put_32(abfd, val, ptr) \
- BFD_SEND (abfd, bfd_h_putx32, (val, ptr))
-#define bfd_h_put_signed_32 \
- bfd_h_put_32
-#define bfd_h_get_32(abfd, ptr) \
- BFD_SEND (abfd, bfd_h_getx32, (ptr))
-#define bfd_h_get_signed_32(abfd, ptr) \
- BFD_SEND (abfd, bfd_h_getx_signed_32, (ptr))
-
-#define bfd_h_put_64(abfd, val, ptr) \
- BFD_SEND (abfd, bfd_h_putx64, (val, ptr))
-#define bfd_h_put_signed_64 \
- bfd_h_put_64
-#define bfd_h_get_64(abfd, ptr) \
- BFD_SEND (abfd, bfd_h_getx64, (ptr))
-#define bfd_h_get_signed_64(abfd, ptr) \
- BFD_SEND (abfd, bfd_h_getx_signed_64, (ptr))
-
-/* Aliases for the above, which should eventually go away. */
-
-#define H_PUT_64 bfd_h_put_64
-#define H_PUT_32 bfd_h_put_32
-#define H_PUT_16 bfd_h_put_16
-#define H_PUT_8 bfd_h_put_8
-#define H_PUT_S64 bfd_h_put_signed_64
-#define H_PUT_S32 bfd_h_put_signed_32
-#define H_PUT_S16 bfd_h_put_signed_16
-#define H_PUT_S8 bfd_h_put_signed_8
-#define H_GET_64 bfd_h_get_64
-#define H_GET_32 bfd_h_get_32
-#define H_GET_16 bfd_h_get_16
-#define H_GET_8 bfd_h_get_8
-#define H_GET_S64 bfd_h_get_signed_64
-#define H_GET_S32 bfd_h_get_signed_32
-#define H_GET_S16 bfd_h_get_signed_16
-#define H_GET_S8 bfd_h_get_signed_8
-
-
-uint64_t bfd_getb64 (const void *);
-uint64_t bfd_getl64 (const void *);
-int64_t bfd_getb_signed_64 (const void *);
-int64_t bfd_getl_signed_64 (const void *);
-bfd_vma bfd_getb32 (const void *);
-bfd_vma bfd_getl32 (const void *);
-bfd_signed_vma bfd_getb_signed_32 (const void *);
-bfd_signed_vma bfd_getl_signed_32 (const void *);
-bfd_vma bfd_getb16 (const void *);
-bfd_vma bfd_getl16 (const void *);
-bfd_signed_vma bfd_getb_signed_16 (const void *);
-bfd_signed_vma bfd_getl_signed_16 (const void *);
-void bfd_putb64 (uint64_t, void *);
-void bfd_putl64 (uint64_t, void *);
-void bfd_putb32 (bfd_vma, void *);
-void bfd_putl32 (bfd_vma, void *);
-void bfd_putb24 (bfd_vma, void *);
-void bfd_putl24 (bfd_vma, void *);
-void bfd_putb16 (bfd_vma, void *);
-void bfd_putl16 (bfd_vma, void *);
-uint64_t bfd_get_bits (const void *, int, bool);
-void bfd_put_bits (uint64_t, void *, int, bool);
-
-/* Extracted from hash.c. */
-/* An element in the hash table. Most uses will actually use a larger
- structure, and an instance of this will be the first field. */
-
-struct bfd_hash_entry
-{
- /* Next entry for this hash code. */
- struct bfd_hash_entry *next;
- /* String being hashed. */
- const char *string;
- /* Hash code. This is the full hash code, not the index into the
- table. */
- unsigned long hash;
-};
-
-/* A hash table. */
-
-struct bfd_hash_table
-{
- /* The hash array. */
- struct bfd_hash_entry **table;
- /* A function used to create new elements in the hash table. The
- first entry is itself a pointer to an element. When this
- function is first invoked, this pointer will be NULL. However,
- having the pointer permits a hierarchy of method functions to be
- built each of which calls the function in the superclass. Thus
- each function should be written to allocate a new block of memory
- only if the argument is NULL. */
- struct bfd_hash_entry *(*newfunc)
- (struct bfd_hash_entry *, struct bfd_hash_table *, const char *);
- /* An objalloc for this hash table. This is a struct objalloc *,
- but we use void * to avoid requiring the inclusion of objalloc.h. */
- void *memory;
- /* The number of slots in the hash table. */
- unsigned int size;
- /* The number of entries in the hash table. */
- unsigned int count;
- /* The size of elements. */
- unsigned int entsize;
- /* If non-zero, don't grow the hash table. */
- unsigned int frozen:1;
-};
-
-bool bfd_hash_table_init_n
- (struct bfd_hash_table *,
- struct bfd_hash_entry *(* /*newfunc*/)
- (struct bfd_hash_entry *, struct bfd_hash_table *, const char *),
- unsigned int /*entsize*/, unsigned int /*size*/);
-
-bool bfd_hash_table_init
- (struct bfd_hash_table *,
- struct bfd_hash_entry *(* /*newfunc*/)
- (struct bfd_hash_entry *, struct bfd_hash_table *, const char *),
- unsigned int /*entsize*/);
-
-void bfd_hash_table_free (struct bfd_hash_table *);
-
-struct bfd_hash_entry *bfd_hash_lookup
- (struct bfd_hash_table *, const char *,
- bool /*create*/, bool /*copy*/);
-
-struct bfd_hash_entry *bfd_hash_insert
- (struct bfd_hash_table *,
- const char *,
- unsigned long /*hash*/);
-
-void bfd_hash_rename (struct bfd_hash_table *,
- const char *,
- struct bfd_hash_entry *);
-
-void bfd_hash_replace (struct bfd_hash_table *,
- struct bfd_hash_entry * /*old*/,
- struct bfd_hash_entry * /*new*/);
-
-void *bfd_hash_allocate (struct bfd_hash_table *,
- unsigned int /*size*/);
-
-struct bfd_hash_entry *bfd_hash_newfunc
- (struct bfd_hash_entry *,
- struct bfd_hash_table *,
- const char *);
-
-void bfd_hash_traverse
- (struct bfd_hash_table *,
- bool (*) (struct bfd_hash_entry *, void *),
- void *);
-
-unsigned int bfd_hash_set_default_size (unsigned int);
-
-/* Extracted from section.c. */
-/* Linenumber stuff. */
-typedef struct lineno_cache_entry
-{
- unsigned int line_number; /* Linenumber from start of function. */
- union
- {
- struct bfd_symbol *sym; /* Function name. */
- bfd_vma offset; /* Offset into section. */
- } u;
-}
-alent;
-
-typedef struct bfd_section
-{
- /* The name of the section; the name isn't a copy, the pointer is
- the same as that passed to bfd_make_section. */
- const char *name;
-
- /* The next section in the list belonging to the BFD, or NULL. */
- struct bfd_section *next;
-
- /* The previous section in the list belonging to the BFD, or NULL. */
- struct bfd_section *prev;
-
- /* A unique sequence number. */
- unsigned int id;
-
- /* A unique section number which can be used by assembler to
- distinguish different sections with the same section name. */
- unsigned int section_id;
-
- /* Which section in the bfd; 0..n-1 as sections are created in a bfd. */
- unsigned int index;
-
- /* The field flags contains attributes of the section. Some
- flags are read in from the object file, and some are
- synthesized from other information. */
- flagword flags;
-
-#define SEC_NO_FLAGS 0x0
-
- /* Tells the OS to allocate space for this section when loading.
- This is clear for a section containing debug information only. */
-#define SEC_ALLOC 0x1
-
- /* Tells the OS to load the section from the file when loading.
- This is clear for a .bss section. */
-#define SEC_LOAD 0x2
-
- /* The section contains data still to be relocated, so there is
- some relocation information too. */
-#define SEC_RELOC 0x4
-
- /* A signal to the OS that the section contains read only data. */
-#define SEC_READONLY 0x8
-
- /* The section contains code only. */
-#define SEC_CODE 0x10
-
- /* The section contains data only. */
-#define SEC_DATA 0x20
-
- /* The section will reside in ROM. */
-#define SEC_ROM 0x40
-
- /* The section contains constructor information. This section
- type is used by the linker to create lists of constructors and
- destructors used by <<g++>>. When a back end sees a symbol
- which should be used in a constructor list, it creates a new
- section for the type of name (e.g., <<__CTOR_LIST__>>), attaches
- the symbol to it, and builds a relocation. To build the lists
- of constructors, all the linker has to do is catenate all the
- sections called <<__CTOR_LIST__>> and relocate the data
- contained within - exactly the operations it would peform on
- standard data. */
-#define SEC_CONSTRUCTOR 0x80
-
- /* The section has contents - a data section could be
- <<SEC_ALLOC>> | <<SEC_HAS_CONTENTS>>; a debug section could be
- <<SEC_HAS_CONTENTS>> */
-#define SEC_HAS_CONTENTS 0x100
-
- /* An instruction to the linker to not output the section
- even if it has information which would normally be written. */
-#define SEC_NEVER_LOAD 0x200
-
- /* The section contains thread local data. */
-#define SEC_THREAD_LOCAL 0x400
-
- /* The section's size is fixed. Generic linker code will not
- recalculate it and it is up to whoever has set this flag to
- get the size right. */
-#define SEC_FIXED_SIZE 0x800
-
- /* The section contains common symbols (symbols may be defined
- multiple times, the value of a symbol is the amount of
- space it requires, and the largest symbol value is the one
- used). Most targets have exactly one of these (which we
- translate to bfd_com_section_ptr), but ECOFF has two. */
-#define SEC_IS_COMMON 0x1000
-
- /* The section contains only debugging information. For
- example, this is set for ELF .debug and .stab sections.
- strip tests this flag to see if a section can be
- discarded. */
-#define SEC_DEBUGGING 0x2000
-
- /* The contents of this section are held in memory pointed to
- by the contents field. This is checked by bfd_get_section_contents,
- and the data is retrieved from memory if appropriate. */
-#define SEC_IN_MEMORY 0x4000
-
- /* The contents of this section are to be excluded by the
- linker for executable and shared objects unless those
- objects are to be further relocated. */
-#define SEC_EXCLUDE 0x8000
-
- /* The contents of this section are to be sorted based on the sum of
- the symbol and addend values specified by the associated relocation
- entries. Entries without associated relocation entries will be
- appended to the end of the section in an unspecified order. */
-#define SEC_SORT_ENTRIES 0x10000
-
- /* When linking, duplicate sections of the same name should be
- discarded, rather than being combined into a single section as
- is usually done. This is similar to how common symbols are
- handled. See SEC_LINK_DUPLICATES below. */
-#define SEC_LINK_ONCE 0x20000
-
- /* If SEC_LINK_ONCE is set, this bitfield describes how the linker
- should handle duplicate sections. */
-#define SEC_LINK_DUPLICATES 0xc0000
-
- /* This value for SEC_LINK_DUPLICATES means that duplicate
- sections with the same name should simply be discarded. */
-#define SEC_LINK_DUPLICATES_DISCARD 0x0
-
- /* This value for SEC_LINK_DUPLICATES means that the linker
- should warn if there are any duplicate sections, although
- it should still only link one copy. */
-#define SEC_LINK_DUPLICATES_ONE_ONLY 0x40000
-
- /* This value for SEC_LINK_DUPLICATES means that the linker
- should warn if any duplicate sections are a different size. */
-#define SEC_LINK_DUPLICATES_SAME_SIZE 0x80000
-
- /* This value for SEC_LINK_DUPLICATES means that the linker
- should warn if any duplicate sections contain different
- contents. */
-#define SEC_LINK_DUPLICATES_SAME_CONTENTS \
- (SEC_LINK_DUPLICATES_ONE_ONLY | SEC_LINK_DUPLICATES_SAME_SIZE)
-
- /* This section was created by the linker as part of dynamic
- relocation or other arcane processing. It is skipped when
- going through the first-pass output, trusting that someone
- else up the line will take care of it later. */
-#define SEC_LINKER_CREATED 0x100000
-
- /* This section contains a section ID to distinguish different
- sections with the same section name. */
-#define SEC_ASSEMBLER_SECTION_ID 0x100000
-
- /* This section should not be subject to garbage collection.
- Also set to inform the linker that this section should not be
- listed in the link map as discarded. */
-#define SEC_KEEP 0x200000
-
- /* This section contains "short" data, and should be placed
- "near" the GP. */
-#define SEC_SMALL_DATA 0x400000
-
- /* Attempt to merge identical entities in the section.
- Entity size is given in the entsize field. */
-#define SEC_MERGE 0x800000
-
- /* If given with SEC_MERGE, entities to merge are zero terminated
- strings where entsize specifies character size instead of fixed
- size entries. */
-#define SEC_STRINGS 0x1000000
-
- /* This section contains data about section groups. */
-#define SEC_GROUP 0x2000000
-
- /* The section is a COFF shared library section. This flag is
- only for the linker. If this type of section appears in
- the input file, the linker must copy it to the output file
- without changing the vma or size. FIXME: Although this
- was originally intended to be general, it really is COFF
- specific (and the flag was renamed to indicate this). It
- might be cleaner to have some more general mechanism to
- allow the back end to control what the linker does with
- sections. */
-#define SEC_COFF_SHARED_LIBRARY 0x4000000
-
- /* This input section should be copied to output in reverse order
- as an array of pointers. This is for ELF linker internal use
- only. */
-#define SEC_ELF_REVERSE_COPY 0x4000000
-
- /* This section contains data which may be shared with other
- executables or shared objects. This is for COFF only. */
-#define SEC_COFF_SHARED 0x8000000
-
- /* Indicate that section has the purecode flag set. */
-#define SEC_ELF_PURECODE 0x8000000
-
- /* When a section with this flag is being linked, then if the size of
- the input section is less than a page, it should not cross a page
- boundary. If the size of the input section is one page or more,
- it should be aligned on a page boundary. This is for TI
- TMS320C54X only. */
-#define SEC_TIC54X_BLOCK 0x10000000
-
- /* This section has the SHF_X86_64_LARGE flag. This is ELF x86-64 only. */
-#define SEC_ELF_LARGE 0x10000000
-
- /* Conditionally link this section; do not link if there are no
- references found to any symbol in the section. This is for TI
- TMS320C54X only. */
-#define SEC_TIC54X_CLINK 0x20000000
-
- /* This section contains vliw code. This is for Toshiba MeP only. */
-#define SEC_MEP_VLIW 0x20000000
-
- /* All symbols, sizes and relocations in this section are octets
- instead of bytes. Required for DWARF debug sections as DWARF
- information is organized in octets, not bytes. */
-#define SEC_ELF_OCTETS 0x40000000
-
- /* Indicate that section has the no read flag set. This happens
- when memory read flag isn't set. */
-#define SEC_COFF_NOREAD 0x40000000
-
- /* End of section flags. */
-
- /* Some internal packed boolean fields. */
-
- /* See the vma field. */
- unsigned int user_set_vma : 1;
-
- /* A mark flag used by some of the linker backends. */
- unsigned int linker_mark : 1;
-
- /* Another mark flag used by some of the linker backends. Set for
- output sections that have an input section. */
- unsigned int linker_has_input : 1;
-
- /* Mark flag used by some linker backends for garbage collection. */
- unsigned int gc_mark : 1;
-
- /* Section compression status. */
- unsigned int compress_status : 2;
-#define COMPRESS_SECTION_NONE 0
-#define COMPRESS_SECTION_DONE 1
-#define DECOMPRESS_SECTION_ZLIB 2
-#define DECOMPRESS_SECTION_ZSTD 3
-
- /* The following flags are used by the ELF linker. */
-
- /* Mark sections which have been allocated to segments. */
- unsigned int segment_mark : 1;
-
- /* Type of sec_info information. */
- unsigned int sec_info_type:3;
-#define SEC_INFO_TYPE_NONE 0
-#define SEC_INFO_TYPE_STABS 1
-#define SEC_INFO_TYPE_MERGE 2
-#define SEC_INFO_TYPE_EH_FRAME 3
-#define SEC_INFO_TYPE_JUST_SYMS 4
-#define SEC_INFO_TYPE_TARGET 5
-#define SEC_INFO_TYPE_EH_FRAME_ENTRY 6
-#define SEC_INFO_TYPE_SFRAME 7
-
- /* Nonzero if this section uses RELA relocations, rather than REL. */
- unsigned int use_rela_p:1;
-
- /* Nonzero if this section contents are mmapped, rather than malloced. */
- unsigned int mmapped_p:1;
-
- /* Bits used by various backends. The generic code doesn't touch
- these fields. */
-
- unsigned int sec_flg0:1;
- unsigned int sec_flg1:1;
- unsigned int sec_flg2:1;
- unsigned int sec_flg3:1;
- unsigned int sec_flg4:1;
- unsigned int sec_flg5:1;
-
- /* End of internal packed boolean fields. */
-
- /* The virtual memory address of the section - where it will be
- at run time. The symbols are relocated against this. The
- user_set_vma flag is maintained by bfd; if it's not set, the
- backend can assign addresses (for example, in <<a.out>>, where
- the default address for <<.data>> is dependent on the specific
- target and various flags). */
- bfd_vma vma;
-
- /* The load address of the section - where it would be in a
- rom image; really only used for writing section header
- information. */
- bfd_vma lma;
-
- /* The size of the section in *octets*, as it will be output.
- Contains a value even if the section has no contents (e.g., the
- size of <<.bss>>). */
- bfd_size_type size;
-
- /* For input sections, the original size on disk of the section, in
- octets. This field should be set for any section whose size is
- changed by linker relaxation. It is required for sections where
- the linker relaxation scheme doesn't cache altered section and
- reloc contents (stabs, eh_frame, SEC_MERGE, some coff relaxing
- targets), and thus the original size needs to be kept to read the
- section multiple times. For output sections, rawsize holds the
- section size calculated on a previous linker relaxation pass. */
- bfd_size_type rawsize;
-
- /* The compressed size of the section in octets. */
- bfd_size_type compressed_size;
-
- /* If this section is going to be output, then this value is the
- offset in *bytes* into the output section of the first byte in the
- input section (byte ==> smallest addressable unit on the
- target). In most cases, if this was going to start at the
- 100th octet (8-bit quantity) in the output section, this value
- would be 100. However, if the target byte size is 16 bits
- (bfd_octets_per_byte is "2"), this value would be 50. */
- bfd_vma output_offset;
-
- /* The output section through which to map on output. */
- struct bfd_section *output_section;
-
- /* If an input section, a pointer to a vector of relocation
- records for the data in this section. */
- struct reloc_cache_entry *relocation;
-
- /* If an output section, a pointer to a vector of pointers to
- relocation records for the data in this section. */
- struct reloc_cache_entry **orelocation;
-
- /* The number of relocation records in one of the above. */
- unsigned reloc_count;
-
- /* The alignment requirement of the section, as an exponent of 2 -
- e.g., 3 aligns to 2^3 (or 8). */
- unsigned int alignment_power;
-
- /* Information below is back end specific - and not always used
- or updated. */
-
- /* File position of section data. */
- file_ptr filepos;
-
- /* File position of relocation info. */
- file_ptr rel_filepos;
-
- /* File position of line data. */
- file_ptr line_filepos;
-
- /* Pointer to data for applications. */
- void *userdata;
-
- /* If the SEC_IN_MEMORY flag is set, this points to the actual
- contents. */
- bfd_byte *contents;
-
- /* Attached line number information. */
- alent *lineno;
-
- /* Number of line number records. */
- unsigned int lineno_count;
-
- /* Entity size for merging purposes. */
- unsigned int entsize;
-
- /* Points to the kept section if this section is a link-once section,
- and is discarded. */
- struct bfd_section *kept_section;
-
- /* When a section is being output, this value changes as more
- linenumbers are written out. */
- file_ptr moving_line_filepos;
-
- /* What the section number is in the target world. */
- int target_index;
-
- void *used_by_bfd;
-
- /* If this is a constructor section then here is a list of the
- relocations created to relocate items within it. */
- struct relent_chain *constructor_chain;
-
- /* The BFD which owns the section. */
- bfd *owner;
-
- /* A symbol which points at this section only. */
- struct bfd_symbol *symbol;
- struct bfd_symbol **symbol_ptr_ptr;
-
- /* Early in the link process, map_head and map_tail are used to build
- a list of input sections attached to an output section. Later,
- output sections use these fields for a list of bfd_link_order
- structs. The linked_to_symbol_name field is for ELF assembler
- internal use. */
- union {
- struct bfd_link_order *link_order;
- struct bfd_section *s;
- const char *linked_to_symbol_name;
- } map_head, map_tail;
-
- /* Points to the output section this section is already assigned to,
- if any. This is used when support for non-contiguous memory
- regions is enabled. */
- struct bfd_section *already_assigned;
-
- /* Explicitly specified section type, if non-zero. */
- unsigned int type;
-
-} asection;
-
-static inline const char *
-bfd_section_name (const asection *sec)
-{
- return sec->name;
-}
-
-static inline bfd_size_type
-bfd_section_size (const asection *sec)
-{
- return sec->size;
-}
-
-static inline bfd_vma
-bfd_section_vma (const asection *sec)
-{
- return sec->vma;
-}
-
-static inline bfd_vma
-bfd_section_lma (const asection *sec)
-{
- return sec->lma;
-}
-
-static inline unsigned int
-bfd_section_alignment (const asection *sec)
-{
- return sec->alignment_power;
-}
-
-static inline flagword
-bfd_section_flags (const asection *sec)
-{
- return sec->flags;
-}
-
-static inline void *
-bfd_section_userdata (const asection *sec)
-{
- return sec->userdata;
-}
-static inline bool
-bfd_is_com_section (const asection *sec)
-{
- return (sec->flags & SEC_IS_COMMON) != 0;
-}
-
-/* Note: the following are provided as inline functions rather than macros
- because not all callers use the return value. A macro implementation
- would use a comma expression, eg: "((ptr)->foo = val, TRUE)" and some
- compilers will complain about comma expressions that have no effect. */
-static inline bool
-bfd_set_section_userdata (asection *sec, void *val)
-{
- sec->userdata = val;
- return true;
-}
-
-static inline bool
-bfd_set_section_vma (asection *sec, bfd_vma val)
-{
- sec->vma = sec->lma = val;
- sec->user_set_vma = true;
- return true;
-}
-
-static inline bool
-bfd_set_section_lma (asection *sec, bfd_vma val)
-{
- sec->lma = val;
- return true;
-}
-
-static inline bool
-bfd_set_section_alignment (asection *sec, unsigned int val)
-{
- if (val >= sizeof (bfd_vma) * 8 - 1)
- return false;
- sec->alignment_power = val;
- return true;
-}
-
-/* These sections are global, and are managed by BFD. The application
- and target back end are not permitted to change the values in
- these sections. */
-extern asection _bfd_std_section[4];
-
-#define BFD_ABS_SECTION_NAME "*ABS*"
-#define BFD_UND_SECTION_NAME "*UND*"
-#define BFD_COM_SECTION_NAME "*COM*"
-#define BFD_IND_SECTION_NAME "*IND*"
-
-/* Pointer to the common section. */
-#define bfd_com_section_ptr (&_bfd_std_section[0])
-/* Pointer to the undefined section. */
-#define bfd_und_section_ptr (&_bfd_std_section[1])
-/* Pointer to the absolute section. */
-#define bfd_abs_section_ptr (&_bfd_std_section[2])
-/* Pointer to the indirect section. */
-#define bfd_ind_section_ptr (&_bfd_std_section[3])
-
-static inline bool
-bfd_is_und_section (const asection *sec)
-{
- return sec == bfd_und_section_ptr;
-}
-
-static inline bool
-bfd_is_abs_section (const asection *sec)
-{
- return sec == bfd_abs_section_ptr;
-}
-
-static inline bool
-bfd_is_ind_section (const asection *sec)
-{
- return sec == bfd_ind_section_ptr;
-}
-
-static inline bool
-bfd_is_const_section (const asection *sec)
-{
- return (sec >= _bfd_std_section
- && sec < _bfd_std_section + (sizeof (_bfd_std_section)
- / sizeof (_bfd_std_section[0])));
-}
-
-/* Return TRUE if input section SEC has been discarded. */
-static inline bool
-discarded_section (const asection *sec)
-{
- return (!bfd_is_abs_section (sec)
- && bfd_is_abs_section (sec->output_section)
- && sec->sec_info_type != SEC_INFO_TYPE_MERGE
- && sec->sec_info_type != SEC_INFO_TYPE_JUST_SYMS);
-}
-
-#define BFD_FAKE_SECTION(SEC, SYM, NAME, IDX, FLAGS) \
- /* name, next, prev, id, section_id, index, flags, user_set_vma, */ \
- { NAME, NULL, NULL, IDX, 0, 0, FLAGS, 0, \
- \
- /* linker_mark, linker_has_input, gc_mark, decompress_status, */ \
- 0, 0, 1, 0, \
- \
- /* segment_mark, sec_info_type, use_rela_p, mmapped_p, */ \
- 0, 0, 0, 0, \
- \
- /* sec_flg0, sec_flg1, sec_flg2, sec_flg3, sec_flg4, sec_flg5, */ \
- 0, 0, 0, 0, 0, 0, \
- \
- /* vma, lma, size, rawsize, compressed_size, */ \
- 0, 0, 0, 0, 0, \
- \
- /* output_offset, output_section, relocation, orelocation, */ \
- 0, &SEC, NULL, NULL, \
- \
- /* reloc_count, alignment_power, filepos, rel_filepos, */ \
- 0, 0, 0, 0, \
- \
- /* line_filepos, userdata, contents, lineno, lineno_count, */ \
- 0, NULL, NULL, NULL, 0, \
- \
- /* entsize, kept_section, moving_line_filepos, */ \
- 0, NULL, 0, \
- \
- /* target_index, used_by_bfd, constructor_chain, owner, */ \
- 0, NULL, NULL, NULL, \
- \
- /* symbol, symbol_ptr_ptr, */ \
- (struct bfd_symbol *) SYM, &SEC.symbol, \
- \
- /* map_head, map_tail, already_assigned, type */ \
- { NULL }, { NULL }, NULL, 0 \
- \
- }
-
-/* We use a macro to initialize the static asymbol structures because
- traditional C does not permit us to initialize a union member while
- gcc warns if we don't initialize it.
- the_bfd, name, value, attr, section [, udata] */
-#ifdef __STDC__
-#define GLOBAL_SYM_INIT(NAME, SECTION) \
- { 0, NAME, 0, BSF_SECTION_SYM, SECTION, { 0 }}
-#else
-#define GLOBAL_SYM_INIT(NAME, SECTION) \
- { 0, NAME, 0, BSF_SECTION_SYM, SECTION }
-#endif
-
-void bfd_section_list_clear (bfd *);
-
-asection *bfd_get_section_by_name (bfd *abfd, const char *name);
-
-asection *bfd_get_next_section_by_name (bfd *ibfd, asection *sec);
-
-asection *bfd_get_linker_section (bfd *abfd, const char *name);
-
-asection *bfd_get_section_by_name_if
- (bfd *abfd,
- const char *name,
- bool (*func) (bfd *abfd, asection *sect, void *obj),
- void *obj);
-
-char *bfd_get_unique_section_name
- (bfd *abfd, const char *templat, int *count);
-
-asection *bfd_make_section_old_way (bfd *abfd, const char *name);
-
-asection *bfd_make_section_anyway_with_flags
- (bfd *abfd, const char *name, flagword flags);
-
-asection *bfd_make_section_anyway (bfd *abfd, const char *name);
-
-asection *bfd_make_section_with_flags
- (bfd *, const char *name, flagword flags);
-
-asection *bfd_make_section (bfd *, const char *name);
-
-bool bfd_set_section_flags (asection *sec, flagword flags);
-
-void bfd_rename_section
- (asection *sec, const char *newname);
-
-void bfd_map_over_sections
- (bfd *abfd,
- void (*func) (bfd *abfd, asection *sect, void *obj),
- void *obj);
-
-asection *bfd_sections_find_if
- (bfd *abfd,
- bool (*operation) (bfd *abfd, asection *sect, void *obj),
- void *obj);
-
-bool bfd_set_section_size (asection *sec, bfd_size_type val);
-
-bool bfd_set_section_contents
- (bfd *abfd, asection *section, const void *data,
- file_ptr offset, bfd_size_type count);
-
-bool bfd_get_section_contents
- (bfd *abfd, asection *section, void *location, file_ptr offset,
- bfd_size_type count);
-
-bool bfd_malloc_and_get_section
- (bfd *abfd, asection *section, bfd_byte **buf);
-
-bool bfd_copy_private_section_data
- (bfd *ibfd, asection *isec, bfd *obfd, asection *osec);
-
-#define bfd_copy_private_section_data(ibfd, isection, obfd, osection) \
- BFD_SEND (obfd, _bfd_copy_private_section_data, \
- (ibfd, isection, obfd, osection))
-bool bfd_generic_is_group_section (bfd *, const asection *sec);
-
-const char *bfd_generic_group_name (bfd *, const asection *sec);
-
-bool bfd_generic_discard_group (bfd *abfd, asection *group);
-
-bool bfd_section_size_insane (bfd *abfd, asection *sec);
-
-/* Extracted from syms.c. */
-typedef struct bfd_symbol
-{
- /* A pointer to the BFD which owns the symbol. This information
- is necessary so that a back end can work out what additional
- information (invisible to the application writer) is carried
- with the symbol.
-
- This field is *almost* redundant, since you can use section->owner
- instead, except that some symbols point to the global sections
- bfd_{abs,com,und}_section. This could be fixed by making
- these globals be per-bfd (or per-target-flavor). FIXME. */
- struct bfd *the_bfd; /* Use bfd_asymbol_bfd(sym) to access this field. */
-
- /* The text of the symbol. The name is left alone, and not copied; the
- application may not alter it. */
- const char *name;
-
- /* The value of the symbol. This really should be a union of a
- numeric value with a pointer, since some flags indicate that
- a pointer to another symbol is stored here. */
- symvalue value;
-
- /* Attributes of a symbol. */
-#define BSF_NO_FLAGS 0
-
- /* The symbol has local scope; <<static>> in <<C>>. The value
- is the offset into the section of the data. */
-#define BSF_LOCAL (1 << 0)
-
- /* The symbol has global scope; initialized data in <<C>>. The
- value is the offset into the section of the data. */
-#define BSF_GLOBAL (1 << 1)
-
- /* The symbol has global scope and is exported. The value is
- the offset into the section of the data. */
-#define BSF_EXPORT BSF_GLOBAL /* No real difference. */
-
- /* A normal C symbol would be one of:
- <<BSF_LOCAL>>, <<BSF_UNDEFINED>> or <<BSF_GLOBAL>>. */
-
- /* The symbol is a debugging record. The value has an arbitrary
- meaning, unless BSF_DEBUGGING_RELOC is also set. */
-#define BSF_DEBUGGING (1 << 2)
-
- /* The symbol denotes a function entry point. Used in ELF,
- perhaps others someday. */
-#define BSF_FUNCTION (1 << 3)
-
- /* Used by the linker. */
-#define BSF_KEEP (1 << 5)
-
- /* An ELF common symbol. */
-#define BSF_ELF_COMMON (1 << 6)
-
- /* A weak global symbol, overridable without warnings by
- a regular global symbol of the same name. */
-#define BSF_WEAK (1 << 7)
-
- /* This symbol was created to point to a section, e.g. ELF's
- STT_SECTION symbols. */
-#define BSF_SECTION_SYM (1 << 8)
-
- /* The symbol used to be a common symbol, but now it is
- allocated. */
-#define BSF_OLD_COMMON (1 << 9)
-
- /* In some files the type of a symbol sometimes alters its
- location in an output file - ie in coff a <<ISFCN>> symbol
- which is also <<C_EXT>> symbol appears where it was
- declared and not at the end of a section. This bit is set
- by the target BFD part to convey this information. */
-#define BSF_NOT_AT_END (1 << 10)
-
- /* Signal that the symbol is the label of constructor section. */
-#define BSF_CONSTRUCTOR (1 << 11)
-
- /* Signal that the symbol is a warning symbol. The name is a
- warning. The name of the next symbol is the one to warn about;
- if a reference is made to a symbol with the same name as the next
- symbol, a warning is issued by the linker. */
-#define BSF_WARNING (1 << 12)
-
- /* Signal that the symbol is indirect. This symbol is an indirect
- pointer to the symbol with the same name as the next symbol. */
-#define BSF_INDIRECT (1 << 13)
-
- /* BSF_FILE marks symbols that contain a file name. This is used
- for ELF STT_FILE symbols. */
-#define BSF_FILE (1 << 14)
-
- /* Symbol is from dynamic linking information. */
-#define BSF_DYNAMIC (1 << 15)
-
- /* The symbol denotes a data object. Used in ELF, and perhaps
- others someday. */
-#define BSF_OBJECT (1 << 16)
-
- /* This symbol is a debugging symbol. The value is the offset
- into the section of the data. BSF_DEBUGGING should be set
- as well. */
-#define BSF_DEBUGGING_RELOC (1 << 17)
-
- /* This symbol is thread local. Used in ELF. */
-#define BSF_THREAD_LOCAL (1 << 18)
-
- /* This symbol represents a complex relocation expression,
- with the expression tree serialized in the symbol name. */
-#define BSF_RELC (1 << 19)
-
- /* This symbol represents a signed complex relocation expression,
- with the expression tree serialized in the symbol name. */
-#define BSF_SRELC (1 << 20)
-
- /* This symbol was created by bfd_get_synthetic_symtab. */
-#define BSF_SYNTHETIC (1 << 21)
-
- /* This symbol is an indirect code object. Unrelated to BSF_INDIRECT.
- The dynamic linker will compute the value of this symbol by
- calling the function that it points to. BSF_FUNCTION must
- also be also set. */
-#define BSF_GNU_INDIRECT_FUNCTION (1 << 22)
- /* This symbol is a globally unique data object. The dynamic linker
- will make sure that in the entire process there is just one symbol
- with this name and type in use. BSF_OBJECT must also be set. */
-#define BSF_GNU_UNIQUE (1 << 23)
-
- /* This section symbol should be included in the symbol table. */
-#define BSF_SECTION_SYM_USED (1 << 24)
-
- flagword flags;
-
- /* A pointer to the section to which this symbol is
- relative. This will always be non NULL, there are special
- sections for undefined and absolute symbols. */
- struct bfd_section *section;
-
- /* Back end special data. */
- union
- {
- void *p;
- bfd_vma i;
- }
- udata;
-}
-asymbol;
-
-typedef enum bfd_print_symbol
-{
- bfd_print_symbol_name,
- bfd_print_symbol_more,
- bfd_print_symbol_all
-} bfd_print_symbol_type;
-
-/* Information about a symbol that nm needs. */
-
-typedef struct _symbol_info
-{
- symvalue value;
- char type;
- const char *name; /* Symbol name. */
- unsigned char stab_type; /* Stab type. */
- char stab_other; /* Stab other. */
- short stab_desc; /* Stab desc. */
- const char *stab_name; /* String for stab type. */
-} symbol_info;
-
-#define bfd_get_symtab_upper_bound(abfd) \
- BFD_SEND (abfd, _bfd_get_symtab_upper_bound, (abfd))
-
-bool bfd_is_local_label (bfd *abfd, asymbol *sym);
-
-bool bfd_is_local_label_name (bfd *abfd, const char *name);
-
-#define bfd_is_local_label_name(abfd, name) \
- BFD_SEND (abfd, _bfd_is_local_label_name, (abfd, name))
-
-bool bfd_is_target_special_symbol (bfd *abfd, asymbol *sym);
-
-#define bfd_is_target_special_symbol(abfd, sym) \
- BFD_SEND (abfd, _bfd_is_target_special_symbol, (abfd, sym))
-
-#define bfd_canonicalize_symtab(abfd, location) \
- BFD_SEND (abfd, _bfd_canonicalize_symtab, (abfd, location))
-
-bool bfd_set_symtab
- (bfd *abfd, asymbol **location, unsigned int count);
-
-void bfd_print_symbol_vandf (bfd *abfd, void *file, asymbol *symbol);
-
-#define bfd_make_empty_symbol(abfd) \
- BFD_SEND (abfd, _bfd_make_empty_symbol, (abfd))
-
-asymbol *_bfd_generic_make_empty_symbol (bfd *);
-
-#define bfd_make_debug_symbol(abfd) \
- BFD_SEND (abfd, _bfd_make_debug_symbol, (abfd))
-
-int bfd_decode_symclass (asymbol *symbol);
-
-bool bfd_is_undefined_symclass (int symclass);
-
-void bfd_symbol_info (asymbol *symbol, symbol_info *ret);
-
-bool bfd_copy_private_symbol_data
- (bfd *ibfd, asymbol *isym, bfd *obfd, asymbol *osym);
-
-#define bfd_copy_private_symbol_data(ibfd, isymbol, obfd, osymbol) \
- BFD_SEND (obfd, _bfd_copy_private_symbol_data, \
- (ibfd, isymbol, obfd, osymbol))
-
-/* Extracted from archive.c. */
-/* A canonical archive symbol. */
-/* This is a type pun with struct symdef/struct ranlib on purpose! */
-typedef struct carsym
-{
- const char *name;
- file_ptr file_offset; /* Look here to find the file. */
-}
-carsym;
-
-/* A count of carsyms (canonical archive symbols). */
- typedef unsigned long symindex;
-#define BFD_NO_MORE_SYMBOLS ((symindex) ~0)
-
-symindex bfd_get_next_mapent
- (bfd *abfd, symindex previous, carsym **sym);
-
-bool bfd_set_archive_head (bfd *output, bfd *new_head);
-
-bfd *bfd_openr_next_archived_file (bfd *archive, bfd *previous);
-
-/* Extracted from archures.c. */
-enum bfd_architecture
-{
- bfd_arch_unknown, /* File arch not known. */
- bfd_arch_obscure, /* Arch known, not one of these. */
- bfd_arch_m68k, /* Motorola 68xxx. */
-#define bfd_mach_m68000 1
-#define bfd_mach_m68008 2
-#define bfd_mach_m68010 3
-#define bfd_mach_m68020 4
-#define bfd_mach_m68030 5
-#define bfd_mach_m68040 6
-#define bfd_mach_m68060 7
-#define bfd_mach_cpu32 8
-#define bfd_mach_fido 9
-#define bfd_mach_mcf_isa_a_nodiv 10
-#define bfd_mach_mcf_isa_a 11
-#define bfd_mach_mcf_isa_a_mac 12
-#define bfd_mach_mcf_isa_a_emac 13
-#define bfd_mach_mcf_isa_aplus 14
-#define bfd_mach_mcf_isa_aplus_mac 15
-#define bfd_mach_mcf_isa_aplus_emac 16
-#define bfd_mach_mcf_isa_b_nousp 17
-#define bfd_mach_mcf_isa_b_nousp_mac 18
-#define bfd_mach_mcf_isa_b_nousp_emac 19
-#define bfd_mach_mcf_isa_b 20
-#define bfd_mach_mcf_isa_b_mac 21
-#define bfd_mach_mcf_isa_b_emac 22
-#define bfd_mach_mcf_isa_b_float 23
-#define bfd_mach_mcf_isa_b_float_mac 24
-#define bfd_mach_mcf_isa_b_float_emac 25
-#define bfd_mach_mcf_isa_c 26
-#define bfd_mach_mcf_isa_c_mac 27
-#define bfd_mach_mcf_isa_c_emac 28
-#define bfd_mach_mcf_isa_c_nodiv 29
-#define bfd_mach_mcf_isa_c_nodiv_mac 30
-#define bfd_mach_mcf_isa_c_nodiv_emac 31
- bfd_arch_vax, /* DEC Vax. */
-
- bfd_arch_or1k, /* OpenRISC 1000. */
-#define bfd_mach_or1k 1
-#define bfd_mach_or1knd 2
-
- bfd_arch_sparc, /* SPARC. */
-#define bfd_mach_sparc 1
-/* The difference between v8plus and v9 is that v9 is a true 64 bit env. */
-#define bfd_mach_sparc_sparclet 2
-#define bfd_mach_sparc_sparclite 3
-#define bfd_mach_sparc_v8plus 4
-#define bfd_mach_sparc_v8plusa 5 /* with ultrasparc add'ns. */
-#define bfd_mach_sparc_sparclite_le 6
-#define bfd_mach_sparc_v9 7
-#define bfd_mach_sparc_v9a 8 /* with ultrasparc add'ns. */
-#define bfd_mach_sparc_v8plusb 9 /* with cheetah add'ns. */
-#define bfd_mach_sparc_v9b 10 /* with cheetah add'ns. */
-#define bfd_mach_sparc_v8plusc 11 /* with UA2005 and T1 add'ns. */
-#define bfd_mach_sparc_v9c 12 /* with UA2005 and T1 add'ns. */
-#define bfd_mach_sparc_v8plusd 13 /* with UA2007 and T3 add'ns. */
-#define bfd_mach_sparc_v9d 14 /* with UA2007 and T3 add'ns. */
-#define bfd_mach_sparc_v8pluse 15 /* with OSA2001 and T4 add'ns (no IMA). */
-#define bfd_mach_sparc_v9e 16 /* with OSA2001 and T4 add'ns (no IMA). */
-#define bfd_mach_sparc_v8plusv 17 /* with OSA2011 and T4 and IMA and FJMAU add'ns. */
-#define bfd_mach_sparc_v9v 18 /* with OSA2011 and T4 and IMA and FJMAU add'ns. */
-#define bfd_mach_sparc_v8plusm 19 /* with OSA2015 and M7 add'ns. */
-#define bfd_mach_sparc_v9m 20 /* with OSA2015 and M7 add'ns. */
-#define bfd_mach_sparc_v8plusm8 21 /* with OSA2017 and M8 add'ns. */
-#define bfd_mach_sparc_v9m8 22 /* with OSA2017 and M8 add'ns. */
-/* Nonzero if MACH has the v9 instruction set. */
-#define bfd_mach_sparc_v9_p(mach) \
- ((mach) >= bfd_mach_sparc_v8plus && (mach) <= bfd_mach_sparc_v9m8 \
- && (mach) != bfd_mach_sparc_sparclite_le)
-/* Nonzero if MACH is a 64 bit sparc architecture. */
-#define bfd_mach_sparc_64bit_p(mach) \
- ((mach) >= bfd_mach_sparc_v9 \
- && (mach) != bfd_mach_sparc_v8plusb \
- && (mach) != bfd_mach_sparc_v8plusc \
- && (mach) != bfd_mach_sparc_v8plusd \
- && (mach) != bfd_mach_sparc_v8pluse \
- && (mach) != bfd_mach_sparc_v8plusv \
- && (mach) != bfd_mach_sparc_v8plusm \
- && (mach) != bfd_mach_sparc_v8plusm8)
- bfd_arch_spu, /* PowerPC SPU. */
-#define bfd_mach_spu 256
- bfd_arch_mips, /* MIPS Rxxxx. */
-#define bfd_mach_mips3000 3000
-#define bfd_mach_mips3900 3900
-#define bfd_mach_mips4000 4000
-#define bfd_mach_mips4010 4010
-#define bfd_mach_mips4100 4100
-#define bfd_mach_mips4111 4111
-#define bfd_mach_mips4120 4120
-#define bfd_mach_mips4300 4300
-#define bfd_mach_mips4400 4400
-#define bfd_mach_mips4600 4600
-#define bfd_mach_mips4650 4650
-#define bfd_mach_mips5000 5000
-#define bfd_mach_mips5400 5400
-#define bfd_mach_mips5500 5500
-#define bfd_mach_mips5900 5900
-#define bfd_mach_mips6000 6000
-#define bfd_mach_mips7000 7000
-#define bfd_mach_mips8000 8000
-#define bfd_mach_mips9000 9000
-#define bfd_mach_mips10000 10000
-#define bfd_mach_mips12000 12000
-#define bfd_mach_mips14000 14000
-#define bfd_mach_mips16000 16000
-#define bfd_mach_mips16 16
-#define bfd_mach_mips5 5
-#define bfd_mach_mips_allegrex 10111431 /* octal 'AL', 31. */
-#define bfd_mach_mips_loongson_2e 3001
-#define bfd_mach_mips_loongson_2f 3002
-#define bfd_mach_mips_gs464 3003
-#define bfd_mach_mips_gs464e 3004
-#define bfd_mach_mips_gs264e 3005
-#define bfd_mach_mips_sb1 12310201 /* octal 'SB', 01. */
-#define bfd_mach_mips_octeon 6501
-#define bfd_mach_mips_octeonp 6601
-#define bfd_mach_mips_octeon2 6502
-#define bfd_mach_mips_octeon3 6503
-#define bfd_mach_mips_xlr 887682 /* decimal 'XLR'. */
-#define bfd_mach_mips_interaptiv_mr2 736550 /* decimal 'IA2'. */
-#define bfd_mach_mipsisa32 32
-#define bfd_mach_mipsisa32r2 33
-#define bfd_mach_mipsisa32r3 34
-#define bfd_mach_mipsisa32r5 36
-#define bfd_mach_mipsisa32r6 37
-#define bfd_mach_mipsisa64 64
-#define bfd_mach_mipsisa64r2 65
-#define bfd_mach_mipsisa64r3 66
-#define bfd_mach_mipsisa64r5 68
-#define bfd_mach_mipsisa64r6 69
-#define bfd_mach_mips_micromips 96
- bfd_arch_i386, /* Intel 386. */
-#define bfd_mach_i386_intel_syntax (1 << 0)
-#define bfd_mach_i386_i8086 (1 << 1)
-#define bfd_mach_i386_i386 (1 << 2)
-#define bfd_mach_x86_64 (1 << 3)
-#define bfd_mach_x64_32 (1 << 4)
-#define bfd_mach_i386_i386_intel_syntax (bfd_mach_i386_i386 | bfd_mach_i386_intel_syntax)
-#define bfd_mach_x86_64_intel_syntax (bfd_mach_x86_64 | bfd_mach_i386_intel_syntax)
-#define bfd_mach_x64_32_intel_syntax (bfd_mach_x64_32 | bfd_mach_i386_intel_syntax)
- bfd_arch_iamcu, /* Intel MCU. */
-#define bfd_mach_iamcu (1 << 8)
-#define bfd_mach_i386_iamcu (bfd_mach_i386_i386 | bfd_mach_iamcu)
-#define bfd_mach_i386_iamcu_intel_syntax (bfd_mach_i386_iamcu | bfd_mach_i386_intel_syntax)
- bfd_arch_romp, /* IBM ROMP PC/RT. */
- bfd_arch_convex, /* Convex. */
- bfd_arch_m98k, /* Motorola 98xxx. */
- bfd_arch_pyramid, /* Pyramid Technology. */
- bfd_arch_h8300, /* Renesas H8/300 (formerly Hitachi H8/300). */
-#define bfd_mach_h8300 1
-#define bfd_mach_h8300h 2
-#define bfd_mach_h8300s 3
-#define bfd_mach_h8300hn 4
-#define bfd_mach_h8300sn 5
-#define bfd_mach_h8300sx 6
-#define bfd_mach_h8300sxn 7
- bfd_arch_pdp11, /* DEC PDP-11. */
- bfd_arch_powerpc, /* PowerPC. */
-#define bfd_mach_ppc 32
-#define bfd_mach_ppc64 64
-#define bfd_mach_ppc_403 403
-#define bfd_mach_ppc_403gc 4030
-#define bfd_mach_ppc_405 405
-#define bfd_mach_ppc_505 505
-#define bfd_mach_ppc_601 601
-#define bfd_mach_ppc_602 602
-#define bfd_mach_ppc_603 603
-#define bfd_mach_ppc_ec603e 6031
-#define bfd_mach_ppc_604 604
-#define bfd_mach_ppc_620 620
-#define bfd_mach_ppc_630 630
-#define bfd_mach_ppc_750 750
-#define bfd_mach_ppc_860 860
-#define bfd_mach_ppc_a35 35
-#define bfd_mach_ppc_rs64ii 642
-#define bfd_mach_ppc_rs64iii 643
-#define bfd_mach_ppc_7400 7400
-#define bfd_mach_ppc_e500 500
-#define bfd_mach_ppc_e500mc 5001
-#define bfd_mach_ppc_e500mc64 5005
-#define bfd_mach_ppc_e5500 5006
-#define bfd_mach_ppc_e6500 5007
-#define bfd_mach_ppc_titan 83
-#define bfd_mach_ppc_vle 84
- bfd_arch_rs6000, /* IBM RS/6000. */
-#define bfd_mach_rs6k 6000
-#define bfd_mach_rs6k_rs1 6001
-#define bfd_mach_rs6k_rsc 6003
-#define bfd_mach_rs6k_rs2 6002
- bfd_arch_hppa, /* HP PA RISC. */
-#define bfd_mach_hppa10 10
-#define bfd_mach_hppa11 11
-#define bfd_mach_hppa20 20
-#define bfd_mach_hppa20w 25
- bfd_arch_d10v, /* Mitsubishi D10V. */
-#define bfd_mach_d10v 1
-#define bfd_mach_d10v_ts2 2
-#define bfd_mach_d10v_ts3 3
- bfd_arch_d30v, /* Mitsubishi D30V. */
- bfd_arch_dlx, /* DLX. */
- bfd_arch_m68hc11, /* Motorola 68HC11. */
- bfd_arch_m68hc12, /* Motorola 68HC12. */
-#define bfd_mach_m6812_default 0
-#define bfd_mach_m6812 1
-#define bfd_mach_m6812s 2
- bfd_arch_m9s12x, /* Freescale S12X. */
- bfd_arch_m9s12xg, /* Freescale XGATE. */
- bfd_arch_s12z, /* Freescale S12Z. */
-#define bfd_mach_s12z_default 0
- bfd_arch_z8k, /* Zilog Z8000. */
-#define bfd_mach_z8001 1
-#define bfd_mach_z8002 2
- bfd_arch_sh, /* Renesas / SuperH SH (formerly Hitachi SH). */
-#define bfd_mach_sh 1
-#define bfd_mach_sh2 0x20
-#define bfd_mach_sh_dsp 0x2d
-#define bfd_mach_sh2a 0x2a
-#define bfd_mach_sh2a_nofpu 0x2b
-#define bfd_mach_sh2a_nofpu_or_sh4_nommu_nofpu 0x2a1
-#define bfd_mach_sh2a_nofpu_or_sh3_nommu 0x2a2
-#define bfd_mach_sh2a_or_sh4 0x2a3
-#define bfd_mach_sh2a_or_sh3e 0x2a4
-#define bfd_mach_sh2e 0x2e
-#define bfd_mach_sh3 0x30
-#define bfd_mach_sh3_nommu 0x31
-#define bfd_mach_sh3_dsp 0x3d
-#define bfd_mach_sh3e 0x3e
-#define bfd_mach_sh4 0x40
-#define bfd_mach_sh4_nofpu 0x41
-#define bfd_mach_sh4_nommu_nofpu 0x42
-#define bfd_mach_sh4a 0x4a
-#define bfd_mach_sh4a_nofpu 0x4b
-#define bfd_mach_sh4al_dsp 0x4d
- bfd_arch_alpha, /* Dec Alpha. */
-#define bfd_mach_alpha_ev4 0x10
-#define bfd_mach_alpha_ev5 0x20
-#define bfd_mach_alpha_ev6 0x30
- bfd_arch_arm, /* Advanced Risc Machines ARM. */
-#define bfd_mach_arm_unknown 0
-#define bfd_mach_arm_2 1
-#define bfd_mach_arm_2a 2
-#define bfd_mach_arm_3 3
-#define bfd_mach_arm_3M 4
-#define bfd_mach_arm_4 5
-#define bfd_mach_arm_4T 6
-#define bfd_mach_arm_5 7
-#define bfd_mach_arm_5T 8
-#define bfd_mach_arm_5TE 9
-#define bfd_mach_arm_XScale 10
-#define bfd_mach_arm_ep9312 11
-#define bfd_mach_arm_iWMMXt 12
-#define bfd_mach_arm_iWMMXt2 13
-#define bfd_mach_arm_5TEJ 14
-#define bfd_mach_arm_6 15
-#define bfd_mach_arm_6KZ 16
-#define bfd_mach_arm_6T2 17
-#define bfd_mach_arm_6K 18
-#define bfd_mach_arm_7 19
-#define bfd_mach_arm_6M 20
-#define bfd_mach_arm_6SM 21
-#define bfd_mach_arm_7EM 22
-#define bfd_mach_arm_8 23
-#define bfd_mach_arm_8R 24
-#define bfd_mach_arm_8M_BASE 25
-#define bfd_mach_arm_8M_MAIN 26
-#define bfd_mach_arm_8_1M_MAIN 27
-#define bfd_mach_arm_9 28
- bfd_arch_nds32, /* Andes NDS32. */
-#define bfd_mach_n1 1
-#define bfd_mach_n1h 2
-#define bfd_mach_n1h_v2 3
-#define bfd_mach_n1h_v3 4
-#define bfd_mach_n1h_v3m 5
- bfd_arch_ns32k, /* National Semiconductors ns32000. */
- bfd_arch_tic30, /* Texas Instruments TMS320C30. */
- bfd_arch_tic4x, /* Texas Instruments TMS320C3X/4X. */
-#define bfd_mach_tic3x 30
-#define bfd_mach_tic4x 40
- bfd_arch_tic54x, /* Texas Instruments TMS320C54X. */
- bfd_arch_tic6x, /* Texas Instruments TMS320C6X. */
- bfd_arch_v850, /* NEC V850. */
- bfd_arch_v850_rh850,/* NEC V850 (using RH850 ABI). */
-#define bfd_mach_v850 1
-#define bfd_mach_v850e 'E'
-#define bfd_mach_v850e1 '1'
-#define bfd_mach_v850e2 0x4532
-#define bfd_mach_v850e2v3 0x45325633
-#define bfd_mach_v850e3v5 0x45335635 /* ('E'|'3'|'V'|'5'). */
- bfd_arch_arc, /* ARC Cores. */
-#define bfd_mach_arc_a4 0
-#define bfd_mach_arc_a5 1
-#define bfd_mach_arc_arc600 2
-#define bfd_mach_arc_arc601 4
-#define bfd_mach_arc_arc700 3
-#define bfd_mach_arc_arcv2 5
- bfd_arch_m32c, /* Renesas M16C/M32C. */
-#define bfd_mach_m16c 0x75
-#define bfd_mach_m32c 0x78
- bfd_arch_m32r, /* Renesas M32R (formerly Mitsubishi M32R/D). */
-#define bfd_mach_m32r 1 /* For backwards compatibility. */
-#define bfd_mach_m32rx 'x'
-#define bfd_mach_m32r2 '2'
- bfd_arch_mn10200, /* Matsushita MN10200. */
- bfd_arch_mn10300, /* Matsushita MN10300. */
-#define bfd_mach_mn10300 300
-#define bfd_mach_am33 330
-#define bfd_mach_am33_2 332
- bfd_arch_fr30,
-#define bfd_mach_fr30 0x46523330
- bfd_arch_frv,
-#define bfd_mach_frv 1
-#define bfd_mach_frvsimple 2
-#define bfd_mach_fr300 300
-#define bfd_mach_fr400 400
-#define bfd_mach_fr450 450
-#define bfd_mach_frvtomcat 499 /* fr500 prototype. */
-#define bfd_mach_fr500 500
-#define bfd_mach_fr550 550
- bfd_arch_moxie, /* The moxie processor. */
-#define bfd_mach_moxie 1
- bfd_arch_ft32, /* The ft32 processor. */
-#define bfd_mach_ft32 1
-#define bfd_mach_ft32b 2
- bfd_arch_mcore,
- bfd_arch_mep,
-#define bfd_mach_mep 1
-#define bfd_mach_mep_h1 0x6831
-#define bfd_mach_mep_c5 0x6335
- bfd_arch_metag,
-#define bfd_mach_metag 1
- bfd_arch_ia64, /* HP/Intel ia64. */
-#define bfd_mach_ia64_elf64 64
-#define bfd_mach_ia64_elf32 32
- bfd_arch_ip2k, /* Ubicom IP2K microcontrollers. */
-#define bfd_mach_ip2022 1
-#define bfd_mach_ip2022ext 2
- bfd_arch_iq2000, /* Vitesse IQ2000. */
-#define bfd_mach_iq2000 1
-#define bfd_mach_iq10 2
- bfd_arch_bpf, /* Linux eBPF. */
-#define bfd_mach_bpf 1
-#define bfd_mach_xbpf 2
- bfd_arch_epiphany, /* Adapteva EPIPHANY. */
-#define bfd_mach_epiphany16 1
-#define bfd_mach_epiphany32 2
- bfd_arch_mt,
-#define bfd_mach_ms1 1
-#define bfd_mach_mrisc2 2
-#define bfd_mach_ms2 3
- bfd_arch_pj,
- bfd_arch_avr, /* Atmel AVR microcontrollers. */
-#define bfd_mach_avr1 1
-#define bfd_mach_avr2 2
-#define bfd_mach_avr25 25
-#define bfd_mach_avr3 3
-#define bfd_mach_avr31 31
-#define bfd_mach_avr35 35
-#define bfd_mach_avr4 4
-#define bfd_mach_avr5 5
-#define bfd_mach_avr51 51
-#define bfd_mach_avr6 6
-#define bfd_mach_avrtiny 100
-#define bfd_mach_avrxmega1 101
-#define bfd_mach_avrxmega2 102
-#define bfd_mach_avrxmega3 103
-#define bfd_mach_avrxmega4 104
-#define bfd_mach_avrxmega5 105
-#define bfd_mach_avrxmega6 106
-#define bfd_mach_avrxmega7 107
- bfd_arch_bfin, /* ADI Blackfin. */
-#define bfd_mach_bfin 1
- bfd_arch_cr16, /* National Semiconductor CompactRISC (ie CR16). */
-#define bfd_mach_cr16 1
- bfd_arch_crx, /* National Semiconductor CRX. */
-#define bfd_mach_crx 1
- bfd_arch_cris, /* Axis CRIS. */
-#define bfd_mach_cris_v0_v10 255
-#define bfd_mach_cris_v32 32
-#define bfd_mach_cris_v10_v32 1032
- bfd_arch_riscv,
-#define bfd_mach_riscv32 132
-#define bfd_mach_riscv64 164
- bfd_arch_rl78,
-#define bfd_mach_rl78 0x75
- bfd_arch_rx, /* Renesas RX. */
-#define bfd_mach_rx 0x75
-#define bfd_mach_rx_v2 0x76
-#define bfd_mach_rx_v3 0x77
- bfd_arch_s390, /* IBM s390. */
-#define bfd_mach_s390_31 31
-#define bfd_mach_s390_64 64
- bfd_arch_score, /* Sunplus score. */
-#define bfd_mach_score3 3
-#define bfd_mach_score7 7
- bfd_arch_mmix, /* Donald Knuth's educational processor. */
- bfd_arch_xstormy16,
-#define bfd_mach_xstormy16 1
- bfd_arch_msp430, /* Texas Instruments MSP430 architecture. */
-#define bfd_mach_msp11 11
-#define bfd_mach_msp110 110
-#define bfd_mach_msp12 12
-#define bfd_mach_msp13 13
-#define bfd_mach_msp14 14
-#define bfd_mach_msp15 15
-#define bfd_mach_msp16 16
-#define bfd_mach_msp20 20
-#define bfd_mach_msp21 21
-#define bfd_mach_msp22 22
-#define bfd_mach_msp23 23
-#define bfd_mach_msp24 24
-#define bfd_mach_msp26 26
-#define bfd_mach_msp31 31
-#define bfd_mach_msp32 32
-#define bfd_mach_msp33 33
-#define bfd_mach_msp41 41
-#define bfd_mach_msp42 42
-#define bfd_mach_msp43 43
-#define bfd_mach_msp44 44
-#define bfd_mach_msp430x 45
-#define bfd_mach_msp46 46
-#define bfd_mach_msp47 47
-#define bfd_mach_msp54 54
- bfd_arch_xgate, /* Freescale XGATE. */
-#define bfd_mach_xgate 1
- bfd_arch_xtensa, /* Tensilica's Xtensa cores. */
-#define bfd_mach_xtensa 1
- bfd_arch_z80,
-/* Zilog Z80 without undocumented opcodes. */
-#define bfd_mach_z80strict 1
-/* Zilog Z180: successor with additional instructions, but without
- halves of ix and iy. */
-#define bfd_mach_z180 2
-/* Zilog Z80 with ixl, ixh, iyl, and iyh. */
-#define bfd_mach_z80 3
-/* Zilog eZ80 (successor of Z80 & Z180) in Z80 (16-bit address) mode. */
-#define bfd_mach_ez80_z80 4
-/* Zilog eZ80 (successor of Z80 & Z180) in ADL (24-bit address) mode. */
-#define bfd_mach_ez80_adl 5
-/* Z80N */
-#define bfd_mach_z80n 6
-/* Zilog Z80 with all undocumented instructions. */
-#define bfd_mach_z80full 7
-/* GameBoy Z80 (reduced instruction set). */
-#define bfd_mach_gbz80 8
-/* ASCII R800: successor with multiplication. */
-#define bfd_mach_r800 11
- bfd_arch_lm32, /* Lattice Mico32. */
-#define bfd_mach_lm32 1
- bfd_arch_microblaze,/* Xilinx MicroBlaze. */
- bfd_arch_kvx, /* Kalray VLIW core of the MPPA processor family */
-#define bfd_mach_kv3_unknown 0
-#define bfd_mach_kv3_1 1
-#define bfd_mach_kv3_1_64 2
-#define bfd_mach_kv3_1_usr 3
-#define bfd_mach_kv3_2 4
-#define bfd_mach_kv3_2_64 5
-#define bfd_mach_kv3_2_usr 6
-#define bfd_mach_kv4_1 7
-#define bfd_mach_kv4_1_64 8
-#define bfd_mach_kv4_1_usr 9
- bfd_arch_tilepro, /* Tilera TILEPro. */
- bfd_arch_tilegx, /* Tilera TILE-Gx. */
-#define bfd_mach_tilepro 1
-#define bfd_mach_tilegx 1
-#define bfd_mach_tilegx32 2
- bfd_arch_aarch64, /* AArch64. */
-#define bfd_mach_aarch64 0
-#define bfd_mach_aarch64_8R 1
-#define bfd_mach_aarch64_ilp32 32
-#define bfd_mach_aarch64_llp64 64
- bfd_arch_nios2, /* Nios II. */
-#define bfd_mach_nios2 0
-#define bfd_mach_nios2r1 1
-#define bfd_mach_nios2r2 2
- bfd_arch_visium, /* Visium. */
-#define bfd_mach_visium 1
- bfd_arch_wasm32, /* WebAssembly. */
-#define bfd_mach_wasm32 1
- bfd_arch_pru, /* PRU. */
-#define bfd_mach_pru 0
- bfd_arch_nfp, /* Netronome Flow Processor */
-#define bfd_mach_nfp3200 0x3200
-#define bfd_mach_nfp6000 0x6000
- bfd_arch_csky, /* C-SKY. */
-#define bfd_mach_ck_unknown 0
-#define bfd_mach_ck510 1
-#define bfd_mach_ck610 2
-#define bfd_mach_ck801 3
-#define bfd_mach_ck802 4
-#define bfd_mach_ck803 5
-#define bfd_mach_ck807 6
-#define bfd_mach_ck810 7
-#define bfd_mach_ck860 8
- bfd_arch_loongarch, /* LoongArch */
-#define bfd_mach_loongarch32 1
-#define bfd_mach_loongarch64 2
- bfd_arch_amdgcn, /* AMDGCN */
-#define bfd_mach_amdgcn_unknown 0x000
-#define bfd_mach_amdgcn_gfx900 0x02c
-#define bfd_mach_amdgcn_gfx904 0x02e
-#define bfd_mach_amdgcn_gfx906 0x02f
-#define bfd_mach_amdgcn_gfx908 0x030
-#define bfd_mach_amdgcn_gfx90a 0x03f
-#define bfd_mach_amdgcn_gfx1010 0x033
-#define bfd_mach_amdgcn_gfx1011 0x034
-#define bfd_mach_amdgcn_gfx1012 0x035
-#define bfd_mach_amdgcn_gfx1030 0x036
-#define bfd_mach_amdgcn_gfx1031 0x037
-#define bfd_mach_amdgcn_gfx1032 0x038
-#define bfd_mach_amdgcn_gfx1100 0x041
-#define bfd_mach_amdgcn_gfx1101 0x046
-#define bfd_mach_amdgcn_gfx1102 0x047
- bfd_arch_last
- };
-
-typedef struct bfd_arch_info
-{
- int bits_per_word;
- int bits_per_address;
- int bits_per_byte;
- enum bfd_architecture arch;
- unsigned long mach;
- const char *arch_name;
- const char *printable_name;
- unsigned int section_align_power;
- /* TRUE if this is the default machine for the architecture.
- The default arch should be the first entry for an arch so that
- all the entries for that arch can be accessed via <<next>>. */
- bool the_default;
- const struct bfd_arch_info * (*compatible) (const struct bfd_arch_info *,
- const struct bfd_arch_info *);
-
- bool (*scan) (const struct bfd_arch_info *, const char *);
-
- /* Allocate via bfd_malloc and return a fill buffer of size COUNT. If
- IS_BIGENDIAN is TRUE, the order of bytes is big endian. If CODE is
- TRUE, the buffer contains code. */
- void *(*fill) (bfd_size_type count, bool is_bigendian, bool code);
-
- const struct bfd_arch_info *next;
-
- /* On some architectures the offset for a relocation can point into
- the middle of an instruction. This field specifies the maximum
- offset such a relocation can have (in octets). This affects the
- behaviour of the disassembler, since a value greater than zero
- means that it may need to disassemble an instruction twice, once
- to get its length and then a second time to display it. If the
- value is negative then this has to be done for every single
- instruction, regardless of the offset of the reloc. */
- signed int max_reloc_offset_into_insn;
-}
-bfd_arch_info_type;
-
-const char *bfd_printable_name (bfd *abfd);
-
-const bfd_arch_info_type *bfd_scan_arch (const char *string);
-
-const char **bfd_arch_list (void);
-
-const bfd_arch_info_type *bfd_arch_get_compatible
- (const bfd *abfd, const bfd *bbfd, bool accept_unknowns);
-
-void bfd_set_arch_info (bfd *abfd, const bfd_arch_info_type *arg);
-
-bool bfd_default_set_arch_mach
- (bfd *abfd, enum bfd_architecture arch, unsigned long mach);
-
-enum bfd_architecture bfd_get_arch (const bfd *abfd);
-
-unsigned long bfd_get_mach (const bfd *abfd);
-
-unsigned int bfd_arch_bits_per_byte (const bfd *abfd);
-
-unsigned int bfd_arch_bits_per_address (const bfd *abfd);
-
-const bfd_arch_info_type *bfd_get_arch_info (bfd *abfd);
-
-const bfd_arch_info_type *bfd_lookup_arch
- (enum bfd_architecture arch, unsigned long machine);
-
-const char *bfd_printable_arch_mach
- (enum bfd_architecture arch, unsigned long machine);
-
-unsigned int bfd_octets_per_byte (const bfd *abfd,
- const asection *sec);
-
-unsigned int bfd_arch_mach_octets_per_byte
- (enum bfd_architecture arch, unsigned long machine);
-
-/* Extracted from bfd.c. */
-typedef enum bfd_format
- {
- bfd_unknown = 0, /* File format is unknown. */
- bfd_object, /* Linker/assembler/compiler output. */
- bfd_archive, /* Object archive file. */
- bfd_core, /* Core dump. */
- bfd_type_end /* Marks the end; don't use it! */
- }
-bfd_format;
-
-enum bfd_direction
- {
- no_direction = 0,
- read_direction = 1,
- write_direction = 2,
- both_direction = 3
- };
-
-enum bfd_last_io
- {
- bfd_io_seek = 0,
- bfd_io_read = 1,
- bfd_io_write = 2,
- bfd_io_force = 3
- };
-
-enum bfd_plugin_format
- {
- bfd_plugin_unknown = 0,
- bfd_plugin_yes = 1,
- bfd_plugin_yes_unused = 2,
- bfd_plugin_no = 3
- };
-
-struct bfd_build_id
- {
- bfd_size_type size;
- bfd_byte data[1];
- };
-
-enum bfd_lto_object_type
- {
- lto_non_object, /* Not an LTO object. */
- lto_non_ir_object, /* An object without LTO IR. */
- lto_slim_ir_object, /* A slim LTO IR object. */
- lto_fat_ir_object /* A fat LTO IR object. */
- };
-
-struct bfd_mmapped_entry
- {
- void *addr;
- size_t size;
- };
-
-struct bfd_mmapped
- {
- struct bfd_mmapped *next;
- unsigned int max_entry;
- unsigned int next_entry;
- struct bfd_mmapped_entry entries[1];
- };
-
-struct bfd
-{
- /* The filename the application opened the BFD with. */
- const char *filename;
-
- /* A pointer to the target jump table. */
- const struct bfd_target *xvec;
-
- /* The IOSTREAM, and corresponding IO vector that provide access
- to the file backing the BFD. */
- void *iostream;
- const struct bfd_iovec *iovec;
-
- /* The caching routines use these to maintain a
- least-recently-used list of BFDs. */
- struct bfd *lru_prev, *lru_next;
-
- /* Track current file position (or current buffer offset for
- in-memory BFDs). When a file is closed by the caching routines,
- BFD retains state information on the file here. */
- ufile_ptr where;
-
- /* File modified time, if mtime_set is TRUE. */
- long mtime;
-
- /* A unique identifier of the BFD */
- unsigned int id;
-
- /* Format_specific flags. */
- flagword flags;
-
- /* Values that may appear in the flags field of a BFD. These also
- appear in the object_flags field of the bfd_target structure, where
- they indicate the set of flags used by that backend (not all flags
- are meaningful for all object file formats) (FIXME: at the moment,
- the object_flags values have mostly just been copied from backend
- to another, and are not necessarily correct). */
-
-#define BFD_NO_FLAGS 0x0
-
- /* BFD contains relocation entries. */
-#define HAS_RELOC 0x1
-
- /* BFD is directly executable. */
-#define EXEC_P 0x2
-
- /* BFD has line number information (basically used for F_LNNO in a
- COFF header). */
-#define HAS_LINENO 0x4
-
- /* BFD has debugging information. */
-#define HAS_DEBUG 0x08
-
- /* BFD has symbols. */
-#define HAS_SYMS 0x10
-
- /* BFD has local symbols (basically used for F_LSYMS in a COFF
- header). */
-#define HAS_LOCALS 0x20
-
- /* BFD is a dynamic object. */
-#define DYNAMIC 0x40
-
- /* Text section is write protected (if D_PAGED is not set, this is
- like an a.out NMAGIC file) (the linker sets this by default, but
- clears it for -r or -N). */
-#define WP_TEXT 0x80
-
- /* BFD is dynamically paged (this is like an a.out ZMAGIC file) (the
- linker sets this by default, but clears it for -r or -n or -N). */
-#define D_PAGED 0x100
-
- /* BFD is relaxable (this means that bfd_relax_section may be able to
- do something) (sometimes bfd_relax_section can do something even if
- this is not set). */
-#define BFD_IS_RELAXABLE 0x200
-
- /* This may be set before writing out a BFD to request using a
- traditional format. For example, this is used to request that when
- writing out an a.out object the symbols not be hashed to eliminate
- duplicates. */
-#define BFD_TRADITIONAL_FORMAT 0x400
-
- /* This flag indicates that the BFD contents are actually cached
- in memory. If this is set, iostream points to a malloc'd
- bfd_in_memory struct. */
-#define BFD_IN_MEMORY 0x800
-
- /* This BFD has been created by the linker and doesn't correspond
- to any input file. */
-#define BFD_LINKER_CREATED 0x1000
-
- /* This may be set before writing out a BFD to request that it
- be written using values for UIDs, GIDs, timestamps, etc. that
- will be consistent from run to run. */
-#define BFD_DETERMINISTIC_OUTPUT 0x2000
-
- /* Compress sections in this BFD. */
-#define BFD_COMPRESS 0x4000
-
- /* Decompress sections in this BFD. */
-#define BFD_DECOMPRESS 0x8000
-
- /* BFD is a dummy, for plugins. */
-#define BFD_PLUGIN 0x10000
-
- /* Compress sections in this BFD with SHF_COMPRESSED from gABI. */
-#define BFD_COMPRESS_GABI 0x20000
-
- /* Convert ELF common symbol type to STT_COMMON or STT_OBJECT in this
- BFD. */
-#define BFD_CONVERT_ELF_COMMON 0x40000
-
- /* Use the ELF STT_COMMON type in this BFD. */
-#define BFD_USE_ELF_STT_COMMON 0x80000
-
- /* Put pathnames into archives (non-POSIX). */
-#define BFD_ARCHIVE_FULL_PATH 0x100000
-
-#define BFD_CLOSED_BY_CACHE 0x200000
- /* Compress sections in this BFD with SHF_COMPRESSED zstd. */
-#define BFD_COMPRESS_ZSTD 0x400000
-
- /* Don't generate ELF section header. */
-#define BFD_NO_SECTION_HEADER 0x800000
-
- /* Flags bits which are for BFD use only. */
-#define BFD_FLAGS_FOR_BFD_USE_MASK \
- (BFD_IN_MEMORY | BFD_COMPRESS | BFD_DECOMPRESS | BFD_LINKER_CREATED \
- | BFD_PLUGIN | BFD_TRADITIONAL_FORMAT | BFD_DETERMINISTIC_OUTPUT \
- | BFD_COMPRESS_GABI | BFD_CONVERT_ELF_COMMON | BFD_USE_ELF_STT_COMMON \
- | BFD_NO_SECTION_HEADER)
-
- /* The format which belongs to the BFD. (object, core, etc.) */
- ENUM_BITFIELD (bfd_format) format : 3;
-
- /* The direction with which the BFD was opened. */
- ENUM_BITFIELD (bfd_direction) direction : 2;
-
- /* POSIX.1-2017 (IEEE Std 1003.1) says of fopen : "When a file is
- opened with update mode ('+' as the second or third character in
- the mode argument), both input and output may be performed on
- the associated stream. However, the application shall ensure
- that output is not directly followed by input without an
- intervening call to fflush() or to a file positioning function
- (fseek(), fsetpos(), or rewind()), and input is not directly
- followed by output without an intervening call to a file
- positioning function, unless the input operation encounters
- end-of-file."
- This field tracks the last IO operation, so that bfd can insert
- a seek when IO direction changes. */
- ENUM_BITFIELD (bfd_last_io) last_io : 2;
-
- /* Is the file descriptor being cached? That is, can it be closed as
- needed, and re-opened when accessed later? */
- unsigned int cacheable : 1;
-
- /* Marks whether there was a default target specified when the
- BFD was opened. This is used to select which matching algorithm
- to use to choose the back end. */
- unsigned int target_defaulted : 1;
-
- /* ... and here: (``once'' means at least once). */
- unsigned int opened_once : 1;
-
- /* Set if we have a locally maintained mtime value, rather than
- getting it from the file each time. */
- unsigned int mtime_set : 1;
-
- /* Flag set if symbols from this BFD should not be exported. */
- unsigned int no_export : 1;
-
- /* Remember when output has begun, to stop strange things
- from happening. */
- unsigned int output_has_begun : 1;
-
- /* Have archive map. */
- unsigned int has_armap : 1;
-
- /* Set if this is a thin archive. */
- unsigned int is_thin_archive : 1;
-
- /* Set if this archive should not cache element positions. */
- unsigned int no_element_cache : 1;
-
- /* Set if only required symbols should be added in the link hash table for
- this object. Used by VMS linkers. */
- unsigned int selective_search : 1;
-
- /* Set if this is the linker output BFD. */
- unsigned int is_linker_output : 1;
-
- /* Set if this is the linker input BFD. */
- unsigned int is_linker_input : 1;
-
- /* If this is an input for a compiler plug-in library. */
- ENUM_BITFIELD (bfd_plugin_format) plugin_format : 2;
-
- /* Set if this is a plugin output file. */
- unsigned int lto_output : 1;
-
- /* Do not attempt to modify this file. Set when detecting errors
- that BFD is not prepared to handle for objcopy/strip. */
- unsigned int read_only : 1;
-
- /* LTO object type. */
- ENUM_BITFIELD (bfd_lto_object_type) lto_type : 2;
-
- /* Set if this BFD is currently being processed by
- bfd_check_format_matches. This is checked by the cache to
- avoid closing the BFD in this case. This should only be
- examined or modified while the BFD lock is held. */
- unsigned int in_format_matches : 1;
-
- /* Set to dummy BFD created when claimed by a compiler plug-in
- library. */
- bfd *plugin_dummy_bfd;
-
- /* The offset of this bfd in the file, typically 0 if it is not
- contained in an archive. */
- ufile_ptr origin;
-
- /* The origin in the archive of the proxy entry. This will
- normally be the same as origin, except for thin archives,
- when it will contain the current offset of the proxy in the
- thin archive rather than the offset of the bfd in its actual
- container. */
- ufile_ptr proxy_origin;
-
- /* A hash table for section names. */
- struct bfd_hash_table section_htab;
-
- /* Pointer to linked list of sections. */
- struct bfd_section *sections;
-
- /* The last section on the section list. */
- struct bfd_section *section_last;
-
- /* The number of sections. */
- unsigned int section_count;
-
- /* The archive plugin file descriptor. */
- int archive_plugin_fd;
-
- /* The number of opens on the archive plugin file descriptor. */
- unsigned int archive_plugin_fd_open_count;
-
- /* A field used by _bfd_generic_link_add_archive_symbols. This will
- be used only for archive elements. */
- int archive_pass;
-
- /* The total size of memory from bfd_alloc. */
- bfd_size_type alloc_size;
-
- /* Stuff only useful for object files:
- The start address. */
- bfd_vma start_address;
-
- /* Symbol table for output BFD (with symcount entries).
- Also used by the linker to cache input BFD symbols. */
- struct bfd_symbol **outsymbols;
-
- /* Used for input and output. */
- unsigned int symcount;
-
- /* Used for slurped dynamic symbol tables. */
- unsigned int dynsymcount;
-
- /* Pointer to structure which contains architecture information. */
- const struct bfd_arch_info *arch_info;
-
- /* Cached length of file for bfd_get_size. 0 until bfd_get_size is
- called, 1 if stat returns an error or the file size is too large to
- return in ufile_ptr. Both 0 and 1 should be treated as "unknown". */
- ufile_ptr size;
-
- /* Stuff only useful for archives. */
- void *arelt_data;
- struct bfd *my_archive; /* The containing archive BFD. */
- struct bfd *archive_next; /* The next BFD in the archive. */
- struct bfd *archive_head; /* The first BFD in the archive. */
- struct bfd *nested_archives; /* List of nested archive in a flattened
- thin archive. */
-
- union {
- /* For input BFDs, a chain of BFDs involved in a link. */
- struct bfd *next;
- /* For output BFD, the linker hash table. */
- struct bfd_link_hash_table *hash;
- } link;
-
- /* Used by the back end to hold private data. */
- union
- {
- struct aout_data_struct *aout_data;
- struct artdata *aout_ar_data;
- struct coff_tdata *coff_obj_data;
- struct pe_tdata *pe_obj_data;
- struct xcoff_tdata *xcoff_obj_data;
- struct ecoff_tdata *ecoff_obj_data;
- struct srec_data_struct *srec_data;
- struct verilog_data_struct *verilog_data;
- struct ihex_data_struct *ihex_data;
- struct tekhex_data_struct *tekhex_data;
- struct elf_obj_tdata *elf_obj_data;
- struct mmo_data_struct *mmo_data;
- struct trad_core_struct *trad_core_data;
- struct som_data_struct *som_data;
- struct hpux_core_struct *hpux_core_data;
- struct hppabsd_core_struct *hppabsd_core_data;
- struct sgi_core_struct *sgi_core_data;
- struct lynx_core_struct *lynx_core_data;
- struct osf_core_struct *osf_core_data;
- struct cisco_core_struct *cisco_core_data;
- struct netbsd_core_struct *netbsd_core_data;
- struct mach_o_data_struct *mach_o_data;
- struct mach_o_fat_data_struct *mach_o_fat_data;
- struct plugin_data_struct *plugin_data;
- struct bfd_pef_data_struct *pef_data;
- struct bfd_pef_xlib_data_struct *pef_xlib_data;
- struct bfd_sym_data_struct *sym_data;
- void *any;
- }
- tdata;
-
- /* Used by the application to hold private data. */
- void *usrdata;
-
- /* Where all the allocated stuff under this BFD goes. This is a
- struct objalloc *, but we use void * to avoid requiring the inclusion
- of objalloc.h. */
- void *memory;
-
- /* For input BFDs, the build ID, if the object has one. */
- const struct bfd_build_id *build_id;
-
- /* For input BFDs, mmapped entries. */
- struct bfd_mmapped *mmapped;
-};
-
-static inline const char *
-bfd_get_filename (const bfd *abfd)
-{
- return abfd->filename;
-}
-
-static inline bool
-bfd_get_cacheable (const bfd *abfd)
-{
- return abfd->cacheable;
-}
-
-static inline enum bfd_format
-bfd_get_format (const bfd *abfd)
-{
- return abfd->format;
-}
-
-static inline enum bfd_lto_object_type
-bfd_get_lto_type (const bfd *abfd)
-{
- return abfd->lto_type;
-}
-
-static inline flagword
-bfd_get_file_flags (const bfd *abfd)
-{
- return abfd->flags;
-}
-
-static inline bfd_vma
-bfd_get_start_address (const bfd *abfd)
-{
- return abfd->start_address;
-}
-
-static inline unsigned int
-bfd_get_symcount (const bfd *abfd)
-{
- return abfd->symcount;
-}
-
-static inline unsigned int
-bfd_get_dynamic_symcount (const bfd *abfd)
-{
- return abfd->dynsymcount;
-}
-
-static inline struct bfd_symbol **
-bfd_get_outsymbols (const bfd *abfd)
-{
- return abfd->outsymbols;
-}
-
-static inline unsigned int
-bfd_count_sections (const bfd *abfd)
-{
- return abfd->section_count;
-}
-
-static inline bool
-bfd_has_map (const bfd *abfd)
-{
- return abfd->has_armap;
-}
-
-static inline bool
-bfd_is_thin_archive (const bfd *abfd)
-{
- return abfd->is_thin_archive;
-}
-
-static inline void *
-bfd_usrdata (const bfd *abfd)
-{
- return abfd->usrdata;
-}
-
-/* See note beside bfd_set_section_userdata. */
-static inline bool
-bfd_set_cacheable (bfd * abfd, bool val)
-{
- abfd->cacheable = val;
- return true;
-}
-
-static inline void
-bfd_set_thin_archive (bfd *abfd, bool val)
-{
- abfd->is_thin_archive = val;
-}
-
-static inline void
-bfd_set_usrdata (bfd *abfd, void *val)
-{
- abfd->usrdata = val;
-}
-
-static inline asection *
-bfd_asymbol_section (const asymbol *sy)
-{
- return sy->section;
-}
-
-static inline bfd_vma
-bfd_asymbol_value (const asymbol *sy)
-{
- return sy->section->vma + sy->value;
-}
-
-static inline const char *
-bfd_asymbol_name (const asymbol *sy)
-{
- return sy->name;
-}
-
-static inline struct bfd *
-bfd_asymbol_bfd (const asymbol *sy)
-{
- return sy->the_bfd;
-}
-
-static inline void
-bfd_set_asymbol_name (asymbol *sy, const char *name)
-{
- sy->name = name;
-}
-
-/* For input sections return the original size on disk of the
- section. For output sections return the current size. */
-static inline bfd_size_type
-bfd_get_section_limit_octets (const bfd *abfd, const asection *sec)
-{
- if (abfd->direction != write_direction && sec->rawsize != 0)
- return sec->rawsize;
- return sec->size;
-}
-
-/* Find the address one past the end of SEC. */
-static inline bfd_size_type
-bfd_get_section_limit (const bfd *abfd, const asection *sec)
-{
- return (bfd_get_section_limit_octets (abfd, sec)
- / bfd_octets_per_byte (abfd, sec));
-}
-
-/* For input sections return the larger of the current size and the
- original size on disk of the section. For output sections return
- the current size. */
-static inline bfd_size_type
-bfd_get_section_alloc_size (const bfd *abfd, const asection *sec)
-{
- if (abfd->direction != write_direction && sec->rawsize > sec->size)
- return sec->rawsize;
- return sec->size;
-}
-
-/* Functions to handle insertion and deletion of a bfd's sections. These
- only handle the list pointers, ie. do not adjust section_count,
- target_index etc. */
-static inline void
-bfd_section_list_remove (bfd *abfd, asection *s)
-{
- asection *next = s->next;
- asection *prev = s->prev;
- if (prev)
- prev->next = next;
- else
- abfd->sections = next;
- if (next)
- next->prev = prev;
- else
- abfd->section_last = prev;
-}
-
-static inline void
-bfd_section_list_append (bfd *abfd, asection *s)
-{
- s->next = 0;
- if (abfd->section_last)
- {
- s->prev = abfd->section_last;
- abfd->section_last->next = s;
- }
- else
- {
- s->prev = 0;
- abfd->sections = s;
- }
- abfd->section_last = s;
-}
-
-static inline void
-bfd_section_list_prepend (bfd *abfd, asection *s)
-{
- s->prev = 0;
- if (abfd->sections)
- {
- s->next = abfd->sections;
- abfd->sections->prev = s;
- }
- else
- {
- s->next = 0;
- abfd->section_last = s;
- }
- abfd->sections = s;
-}
-
-static inline void
-bfd_section_list_insert_after (bfd *abfd, asection *a, asection *s)
-{
- asection *next = a->next;
- s->next = next;
- s->prev = a;
- a->next = s;
- if (next)
- next->prev = s;
- else
- abfd->section_last = s;
-}
-
-static inline void
-bfd_section_list_insert_before (bfd *abfd, asection *b, asection *s)
-{
- asection *prev = b->prev;
- s->prev = prev;
- s->next = b;
- b->prev = s;
- if (prev)
- prev->next = s;
- else
- abfd->sections = s;
-}
-
-static inline bool
-bfd_section_removed_from_list (const bfd *abfd, const asection *s)
-{
- return s->next ? s->next->prev != s : abfd->section_last != s;
-}
-
-typedef enum bfd_error
-{
- bfd_error_no_error = 0,
- bfd_error_system_call,
- bfd_error_invalid_target,
- bfd_error_wrong_format,
- bfd_error_wrong_object_format,
- bfd_error_invalid_operation,
- bfd_error_no_memory,
- bfd_error_no_symbols,
- bfd_error_no_armap,
- bfd_error_no_more_archived_files,
- bfd_error_malformed_archive,
- bfd_error_missing_dso,
- bfd_error_file_not_recognized,
- bfd_error_file_ambiguously_recognized,
- bfd_error_no_contents,
- bfd_error_nonrepresentable_section,
- bfd_error_no_debug_section,
- bfd_error_bad_value,
- bfd_error_file_truncated,
- bfd_error_file_too_big,
- bfd_error_sorry,
- bfd_error_on_input,
- bfd_error_invalid_error_code
-}
-bfd_error_type;
-
-bfd_error_type bfd_get_error (void);
-
-void bfd_set_error (bfd_error_type error_tag);
-
-void bfd_set_input_error (bfd *input, bfd_error_type error_tag);
-
-const char *bfd_errmsg (bfd_error_type error_tag);
-
-void bfd_perror (const char *message);
-
-typedef void (*bfd_error_handler_type) (const char *, va_list);
-
-typedef int (*bfd_print_callback) (void *, const char *, ...);
-void bfd_print_error (bfd_print_callback print_func,
- void *stream, const char *fmt, va_list ap);
-
-void _bfd_error_handler (const char *fmt, ...) ATTRIBUTE_PRINTF_1;
-
-bfd_error_handler_type bfd_set_error_handler (bfd_error_handler_type);
-
-void bfd_set_error_program_name (const char *);
-
-typedef void (*bfd_assert_handler_type) (const char *bfd_formatmsg,
- const char *bfd_version,
- const char *bfd_file,
- int bfd_line);
-
-bfd_assert_handler_type bfd_set_assert_handler (bfd_assert_handler_type);
-
-unsigned int bfd_init (void);
-
-/* Value returned by bfd_init. */
-#define BFD_INIT_MAGIC (sizeof (struct bfd_section))
-
-typedef bool (*bfd_lock_unlock_fn_type) (void *);
-bool bfd_thread_init
- (bfd_lock_unlock_fn_type lock,
- bfd_lock_unlock_fn_type unlock,
- void *data);
-
-void bfd_thread_cleanup (void);
-
-long bfd_get_reloc_upper_bound (bfd *abfd, asection *sect);
-
-long bfd_canonicalize_reloc
- (bfd *abfd, asection *sec, arelent **loc, asymbol **syms);
-
-void bfd_set_reloc
- (bfd *abfd, asection *sec, arelent **rel, unsigned int count);
-
-#define bfd_set_reloc(abfd, asect, location, count) \
- BFD_SEND (abfd, _bfd_set_reloc, (abfd, asect, location, count))
-bool bfd_set_file_flags (bfd *abfd, flagword flags);
-
-int bfd_get_arch_size (bfd *abfd);
-
-int bfd_get_sign_extend_vma (bfd *abfd);
-
-bool bfd_set_start_address (bfd *abfd, bfd_vma vma);
-
-unsigned int bfd_get_gp_size (bfd *abfd);
-
-void bfd_set_gp_size (bfd *abfd, unsigned int i);
-
-void bfd_set_gp_value (bfd *abfd, bfd_vma v);
-
-bfd_vma bfd_scan_vma (const char *string, const char **end, int base);
-
-bool bfd_copy_private_header_data (bfd *ibfd, bfd *obfd);
-
-#define bfd_copy_private_header_data(ibfd, obfd) \
- BFD_SEND (obfd, _bfd_copy_private_header_data, \
- (ibfd, obfd))
-bool bfd_copy_private_bfd_data (bfd *ibfd, bfd *obfd);
-
-#define bfd_copy_private_bfd_data(ibfd, obfd) \
- BFD_SEND (obfd, _bfd_copy_private_bfd_data, \
- (ibfd, obfd))
-bool bfd_set_private_flags (bfd *abfd, flagword flags);
-
-#define bfd_set_private_flags(abfd, flags) \
- BFD_SEND (abfd, _bfd_set_private_flags, (abfd, flags))
-#define bfd_sizeof_headers(abfd, info) \
- BFD_SEND (abfd, _bfd_sizeof_headers, (abfd, info))
-
-#define bfd_find_nearest_line(abfd, sec, syms, off, file, func, line) \
- BFD_SEND (abfd, _bfd_find_nearest_line, \
- (abfd, syms, sec, off, file, func, line, NULL))
-
-#define bfd_find_nearest_line_with_alt(abfd, alt_filename, sec, syms, off, \
- file, func, line, disc) \
- BFD_SEND (abfd, _bfd_find_nearest_line_with_alt, \
- (abfd, alt_filename, syms, sec, off, file, func, line, disc))
-
-#define bfd_find_nearest_line_discriminator(abfd, sec, syms, off, file, func, \
- line, disc) \
- BFD_SEND (abfd, _bfd_find_nearest_line, \
- (abfd, syms, sec, off, file, func, line, disc))
-
-#define bfd_find_line(abfd, syms, sym, file, line) \
- BFD_SEND (abfd, _bfd_find_line, \
- (abfd, syms, sym, file, line))
-
-#define bfd_find_inliner_info(abfd, file, func, line) \
- BFD_SEND (abfd, _bfd_find_inliner_info, \
- (abfd, file, func, line))
-
-#define bfd_debug_info_start(abfd) \
- BFD_SEND (abfd, _bfd_debug_info_start, (abfd))
-
-#define bfd_debug_info_end(abfd) \
- BFD_SEND (abfd, _bfd_debug_info_end, (abfd))
-
-#define bfd_debug_info_accumulate(abfd, section) \
- BFD_SEND (abfd, _bfd_debug_info_accumulate, (abfd, section))
-
-#define bfd_stat_arch_elt(abfd, stat) \
- BFD_SEND (abfd->my_archive ? abfd->my_archive : abfd, \
- _bfd_stat_arch_elt, (abfd, stat))
-
-#define bfd_update_armap_timestamp(abfd) \
- BFD_SEND (abfd, _bfd_update_armap_timestamp, (abfd))
-
-#define bfd_set_arch_mach(abfd, arch, mach)\
- BFD_SEND ( abfd, _bfd_set_arch_mach, (abfd, arch, mach))
-
-#define bfd_relax_section(abfd, section, link_info, again) \
- BFD_SEND (abfd, _bfd_relax_section, (abfd, section, link_info, again))
-
-#define bfd_gc_sections(abfd, link_info) \
- BFD_SEND (abfd, _bfd_gc_sections, (abfd, link_info))
-
-#define bfd_lookup_section_flags(link_info, flag_info, section) \
- BFD_SEND (abfd, _bfd_lookup_section_flags, (link_info, flag_info, section))
-
-#define bfd_merge_sections(abfd, link_info) \
- BFD_SEND (abfd, _bfd_merge_sections, (abfd, link_info))
-
-#define bfd_is_group_section(abfd, sec) \
- BFD_SEND (abfd, _bfd_is_group_section, (abfd, sec))
-
-#define bfd_group_name(abfd, sec) \
- BFD_SEND (abfd, _bfd_group_name, (abfd, sec))
-
-#define bfd_discard_group(abfd, sec) \
- BFD_SEND (abfd, _bfd_discard_group, (abfd, sec))
-
-#define bfd_link_hash_table_create(abfd) \
- BFD_SEND (abfd, _bfd_link_hash_table_create, (abfd))
-
-#define bfd_link_add_symbols(abfd, info) \
- BFD_SEND (abfd, _bfd_link_add_symbols, (abfd, info))
-
-#define bfd_link_just_syms(abfd, sec, info) \
- BFD_SEND (abfd, _bfd_link_just_syms, (sec, info))
-
-#define bfd_final_link(abfd, info) \
- BFD_SEND (abfd, _bfd_final_link, (abfd, info))
-
-#define bfd_free_cached_info(abfd) \
- BFD_SEND (abfd, _bfd_free_cached_info, (abfd))
-
-#define bfd_get_dynamic_symtab_upper_bound(abfd) \
- BFD_SEND (abfd, _bfd_get_dynamic_symtab_upper_bound, (abfd))
-
-#define bfd_print_private_bfd_data(abfd, file)\
- BFD_SEND (abfd, _bfd_print_private_bfd_data, (abfd, file))
-
-#define bfd_canonicalize_dynamic_symtab(abfd, asymbols) \
- BFD_SEND (abfd, _bfd_canonicalize_dynamic_symtab, (abfd, asymbols))
-
-#define bfd_get_synthetic_symtab(abfd, count, syms, dyncount, dynsyms, ret) \
- BFD_SEND (abfd, _bfd_get_synthetic_symtab, (abfd, count, syms, \
- dyncount, dynsyms, ret))
-
-#define bfd_get_dynamic_reloc_upper_bound(abfd) \
- BFD_SEND (abfd, _bfd_get_dynamic_reloc_upper_bound, (abfd))
-
-#define bfd_canonicalize_dynamic_reloc(abfd, arels, asyms) \
- BFD_SEND (abfd, _bfd_canonicalize_dynamic_reloc, (abfd, arels, asyms))
-
-bfd_byte *bfd_get_relocated_section_contents
- (bfd *, struct bfd_link_info *, struct bfd_link_order *, bfd_byte *,
- bool, asymbol **);
-
-bool bfd_record_phdr
- (bfd *, unsigned long, bool, flagword, bool, bfd_vma,
- bool, bool, unsigned int, struct bfd_section **);
-
-void bfd_sprintf_vma (bfd *, char *, bfd_vma);
-void bfd_fprintf_vma (bfd *, void *, bfd_vma);
-
-#define bfd_printf_vma(abfd,x) bfd_fprintf_vma (abfd, stdout, x)
-
-bool bfd_alt_mach_code (bfd *abfd, int alternative);
-
-bfd_vma bfd_emul_get_maxpagesize (const char *);
-
-bfd_vma bfd_emul_get_commonpagesize (const char *);
-
-char *bfd_demangle (bfd *, const char *, int);
-
-/* Extracted from bfdio.c. */
-bfd_size_type bfd_read (void *, bfd_size_type, bfd *)
-ATTRIBUTE_WARN_UNUSED_RESULT;
-
-bfd_size_type bfd_write (const void *, bfd_size_type, bfd *)
-ATTRIBUTE_WARN_UNUSED_RESULT;
-
-file_ptr bfd_tell (bfd *) ATTRIBUTE_WARN_UNUSED_RESULT;
-
-int bfd_flush (bfd *);
-
-int bfd_stat (bfd *, struct stat *) ATTRIBUTE_WARN_UNUSED_RESULT;
-
-int bfd_seek (bfd *, file_ptr, int) ATTRIBUTE_WARN_UNUSED_RESULT;
-
-long bfd_get_mtime (bfd *abfd);
-
-ufile_ptr bfd_get_size (bfd *abfd);
-
-ufile_ptr bfd_get_file_size (bfd *abfd);
-
-void *bfd_mmap (bfd *abfd, void *addr, size_t len,
- int prot, int flags, file_ptr offset,
- void **map_addr, size_t *map_len)
-ATTRIBUTE_WARN_UNUSED_RESULT;
-
-time_t bfd_get_current_time (time_t now);
-
-/* Extracted from cache.c. */
-bool bfd_cache_close (bfd *abfd);
-
-bool bfd_cache_close_all (void);
-
-unsigned bfd_cache_size (void);
-
-/* Extracted from compress.c. */
-/* Types of compressed DWARF debug sections. */
-enum compressed_debug_section_type
-{
- COMPRESS_DEBUG_NONE = 0,
- COMPRESS_DEBUG_GNU_ZLIB = 1 << 1,
- COMPRESS_DEBUG_GABI_ZLIB = 1 << 2,
- COMPRESS_DEBUG_ZSTD = 1 << 3,
- COMPRESS_UNKNOWN = 1 << 4
-};
-
-/* Tuple for compressed_debug_section_type and their name. */
-struct compressed_type_tuple
-{
- enum compressed_debug_section_type type;
- const char *name;
-};
-
-/* Compression header ch_type values. */
-enum compression_type
-{
- ch_none = 0,
- ch_compress_zlib = 1 , /* Compressed with zlib. */
- ch_compress_zstd = 2 /* Compressed with zstd (www.zstandard.org). */
-};
-
-static inline char *
-bfd_debug_name_to_zdebug (bfd *abfd, const char *name)
-{
- size_t len = strlen (name);
- char *new_name = (char *) bfd_alloc (abfd, len + 2);
- if (new_name == NULL)
- return NULL;
- new_name[0] = '.';
- new_name[1] = 'z';
- memcpy (new_name + 2, name + 1, len);
- return new_name;
-}
-
-static inline char *
-bfd_zdebug_name_to_debug (bfd *abfd, const char *name)
-{
- size_t len = strlen (name);
- char *new_name = (char *) bfd_alloc (abfd, len);
- if (new_name == NULL)
- return NULL;
- new_name[0] = '.';
- memcpy (new_name + 1, name + 2, len - 1);
- return new_name;
-}
-
-enum compressed_debug_section_type
-bfd_get_compression_algorithm (const char *name);
-
-const char *bfd_get_compression_algorithm_name
- (enum compressed_debug_section_type type);
-
-void bfd_update_compression_header
- (bfd *abfd, bfd_byte *contents, asection *sec);
-
-int bfd_get_compression_header_size (bfd *abfd, asection *sec);
-
-bool bfd_convert_section_setup
- (bfd *ibfd, asection *isec, bfd *obfd,
- const char **new_name, bfd_size_type *new_size);
-
-bool bfd_convert_section_contents
- (bfd *ibfd, asection *isec, bfd *obfd,
- bfd_byte **ptr, bfd_size_type *ptr_size);
-
-bool bfd_get_full_section_contents
- (bfd *abfd, asection *section, bfd_byte **ptr);
-
-bool bfd_is_section_compressed_info
- (bfd *abfd, asection *section,
- int *compression_header_size_p,
- bfd_size_type *uncompressed_size_p,
- unsigned int *uncompressed_alignment_power_p,
- enum compression_type *ch_type);
-
-bool bfd_is_section_compressed
- (bfd *abfd, asection *section);
-
-bool bfd_init_section_decompress_status
- (bfd *abfd, asection *section);
-
-bool bfd_init_section_compress_status
- (bfd *abfd, asection *section);
-
-bool bfd_compress_section
- (bfd *abfd, asection *section, bfd_byte *uncompressed_buffer);
-
-/* Extracted from corefile.c. */
-const char *bfd_core_file_failing_command (bfd *abfd);
-
-int bfd_core_file_failing_signal (bfd *abfd);
-
-int bfd_core_file_pid (bfd *abfd);
-
-bool core_file_matches_executable_p
- (bfd *core_bfd, bfd *exec_bfd);
-
-bool generic_core_file_matches_executable_p
- (bfd *core_bfd, bfd *exec_bfd);
-
-/* Extracted from format.c. */
-bool bfd_check_format (bfd *abfd, bfd_format format);
-
-bool bfd_check_format_matches
- (bfd *abfd, bfd_format format, char ***matching);
-
-bool bfd_set_format (bfd *abfd, bfd_format format);
-
-const char *bfd_format_string (bfd_format format);
-
-/* Extracted from linker.c. */
-/* Return TRUE if the symbol described by a linker hash entry H
- is going to be absolute. Linker-script defined symbols can be
- converted from absolute to section-relative ones late in the
- link. Use this macro to correctly determine whether the symbol
- will actually end up absolute in output. */
-#define bfd_is_abs_symbol(H) \
- (((H)->type == bfd_link_hash_defined \
- || (H)->type == bfd_link_hash_defweak) \
- && bfd_is_abs_section ((H)->u.def.section) \
- && !(H)->rel_from_abs)
-
-bool bfd_link_split_section (bfd *abfd, asection *sec);
-
-#define bfd_link_split_section(abfd, sec) \
- BFD_SEND (abfd, _bfd_link_split_section, (abfd, sec))
-
-bool bfd_section_already_linked (bfd *abfd,
- asection *sec,
- struct bfd_link_info *info);
-
-#define bfd_section_already_linked(abfd, sec, info) \
- BFD_SEND (abfd, _section_already_linked, (abfd, sec, info))
-
-bool bfd_generic_define_common_symbol
- (bfd *output_bfd, struct bfd_link_info *info,
- struct bfd_link_hash_entry *h);
-
-#define bfd_define_common_symbol(output_bfd, info, h) \
- BFD_SEND (output_bfd, _bfd_define_common_symbol, (output_bfd, info, h))
-
-void _bfd_generic_link_hide_symbol
- (bfd *output_bfd, struct bfd_link_info *info,
- struct bfd_link_hash_entry *h);
-
-#define bfd_link_hide_symbol(output_bfd, info, h) \
- BFD_SEND (output_bfd, _bfd_link_hide_symbol, (output_bfd, info, h))
-
-struct bfd_link_hash_entry *bfd_generic_define_start_stop
- (struct bfd_link_info *info,
- const char *symbol, asection *sec);
-
-#define bfd_define_start_stop(output_bfd, info, symbol, sec) \
- BFD_SEND (output_bfd, _bfd_define_start_stop, (info, symbol, sec))
-
-struct bfd_elf_version_tree * bfd_find_version_for_sym
- (struct bfd_elf_version_tree *verdefs,
- const char *sym_name, bool *hide);
-
-bool bfd_hide_sym_by_version
- (struct bfd_elf_version_tree *verdefs, const char *sym_name);
-
-bool bfd_link_check_relocs
- (bfd *abfd, struct bfd_link_info *info);
-
-bool _bfd_generic_link_check_relocs
- (bfd *abfd, struct bfd_link_info *info);
-
-bool bfd_merge_private_bfd_data
- (bfd *ibfd, struct bfd_link_info *info);
-
-#define bfd_merge_private_bfd_data(ibfd, info) \
- BFD_SEND ((info)->output_bfd, _bfd_merge_private_bfd_data, \
- (ibfd, info))
-
-/* Extracted from opncls.c. */
-/* Set to N to open the next N BFDs using an alternate id space. */
-extern unsigned int bfd_use_reserved_id;
-
-bfd *bfd_fopen (const char *filename, const char *target,
- const char *mode, int fd);
-
-bfd *bfd_openr (const char *filename, const char *target);
-
-bfd *bfd_fdopenr (const char *filename, const char *target, int fd);
-
-bfd *bfd_fdopenw (const char *filename, const char *target, int fd);
-
-bfd *bfd_openstreamr (const char * filename, const char * target,
- void * stream);
-
-bfd *bfd_openr_iovec (const char *filename, const char *target,
- void *(*open_func) (struct bfd *nbfd,
- void *open_closure),
- void *open_closure,
- file_ptr (*pread_func) (struct bfd *nbfd,
- void *stream,
- void *buf,
- file_ptr nbytes,
- file_ptr offset),
- int (*close_func) (struct bfd *nbfd,
- void *stream),
- int (*stat_func) (struct bfd *abfd,
- void *stream,
- struct stat *sb));
-
-bfd *bfd_openw (const char *filename, const char *target);
-
-bfd *bfd_elf_bfd_from_remote_memory
- (bfd *templ, bfd_vma ehdr_vma, bfd_size_type size, bfd_vma *loadbasep,
- int (*target_read_memory)
- (bfd_vma vma, bfd_byte *myaddr, bfd_size_type len));
-
-bool bfd_close (bfd *abfd);
-
-bool bfd_close_all_done (bfd *);
-
-bfd *bfd_create (const char *filename, bfd *templ);
-
-bool bfd_make_writable (bfd *abfd);
-
-bool bfd_make_readable (bfd *abfd);
-
-uint32_t bfd_calc_gnu_debuglink_crc32
- (uint32_t crc, const bfd_byte *buf, bfd_size_type len);
-
-char *bfd_get_debug_link_info (bfd *abfd, uint32_t *crc32_out);
-
-char *bfd_get_alt_debug_link_info (bfd * abfd,
- bfd_size_type *buildid_len,
- bfd_byte **buildid_out);
-
-char *bfd_follow_gnu_debuglink (bfd *abfd, const char *dir);
-
-char *bfd_follow_gnu_debugaltlink (bfd *abfd, const char *dir);
-
-struct bfd_section *bfd_create_gnu_debuglink_section
- (bfd *abfd, const char *filename);
-
-bool bfd_fill_in_gnu_debuglink_section
- (bfd *abfd, struct bfd_section *sect, const char *filename);
-
-char *bfd_follow_build_id_debuglink (bfd *abfd, const char *dir);
-
-const char *bfd_set_filename (bfd *abfd, const char *filename);
-
-/* Extracted from reloc.c. */
-typedef enum bfd_reloc_status
-{
- /* No errors detected. Note - the value 2 is used so that it
- will not be mistaken for the boolean TRUE or FALSE values. */
- bfd_reloc_ok = 2,
-
- /* The relocation was performed, but there was an overflow. */
- bfd_reloc_overflow,
-
- /* The address to relocate was not within the section supplied. */
- bfd_reloc_outofrange,
-
- /* Used by special functions. */
- bfd_reloc_continue,
-
- /* Unsupported relocation size requested. */
- bfd_reloc_notsupported,
-
- /* Target specific meaning. */
- bfd_reloc_other,
-
- /* The symbol to relocate against was undefined. */
- bfd_reloc_undefined,
-
- /* The relocation was performed, but may not be ok. If this type is
- returned, the error_message argument to bfd_perform_relocation
- will be set. */
- bfd_reloc_dangerous
- }
- bfd_reloc_status_type;
-
-typedef const struct reloc_howto_struct reloc_howto_type;
-
-struct reloc_cache_entry
-{
- /* A pointer into the canonical table of pointers. */
- struct bfd_symbol **sym_ptr_ptr;
-
- /* offset in section. */
- bfd_size_type address;
-
- /* addend for relocation value. */
- bfd_vma addend;
-
- /* Pointer to how to perform the required relocation. */
- reloc_howto_type *howto;
-
-};
-
-enum complain_overflow
-{
- /* Do not complain on overflow. */
- complain_overflow_dont,
-
- /* Complain if the value overflows when considered as a signed
- number one bit larger than the field. ie. A bitfield of N bits
- is allowed to represent -2**n to 2**n-1. */
- complain_overflow_bitfield,
-
- /* Complain if the value overflows when considered as a signed
- number. */
- complain_overflow_signed,
-
- /* Complain if the value overflows when considered as an
- unsigned number. */
- complain_overflow_unsigned
-};
-
-struct reloc_howto_struct
-{
- /* The type field has mainly a documentary use - the back end can
- do what it wants with it, though normally the back end's idea of
- an external reloc number is stored in this field. */
- unsigned int type;
-
- /* The size of the item to be relocated in bytes. */
- unsigned int size:4;
-
- /* The number of bits in the field to be relocated. This is used
- when doing overflow checking. */
- unsigned int bitsize:7;
-
- /* The value the final relocation is shifted right by. This drops
- unwanted data from the relocation. */
- unsigned int rightshift:6;
-
- /* The bit position of the reloc value in the destination.
- The relocated value is left shifted by this amount. */
- unsigned int bitpos:6;
-
- /* What type of overflow error should be checked for when
- relocating. */
- ENUM_BITFIELD (complain_overflow) complain_on_overflow:2;
-
- /* The relocation value should be negated before applying. */
- unsigned int negate:1;
-
- /* The relocation is relative to the item being relocated. */
- unsigned int pc_relative:1;
-
- /* Some formats record a relocation addend in the section contents
- rather than with the relocation. For ELF formats this is the
- distinction between USE_REL and USE_RELA (though the code checks
- for USE_REL == 1/0). The value of this field is TRUE if the
- addend is recorded with the section contents; when performing a
- partial link (ld -r) the section contents (the data) will be
- modified. The value of this field is FALSE if addends are
- recorded with the relocation (in arelent.addend); when performing
- a partial link the relocation will be modified.
- All relocations for all ELF USE_RELA targets should set this field
- to FALSE (values of TRUE should be looked on with suspicion).
- However, the converse is not true: not all relocations of all ELF
- USE_REL targets set this field to TRUE. Why this is so is peculiar
- to each particular target. For relocs that aren't used in partial
- links (e.g. GOT stuff) it doesn't matter what this is set to. */
- unsigned int partial_inplace:1;
-
- /* When some formats create PC relative instructions, they leave
- the value of the pc of the place being relocated in the offset
- slot of the instruction, so that a PC relative relocation can
- be made just by adding in an ordinary offset (e.g., sun3 a.out).
- Some formats leave the displacement part of an instruction
- empty (e.g., ELF); this flag signals the fact. */
- unsigned int pcrel_offset:1;
-
- /* Whether bfd_install_relocation should just install the addend,
- or should follow the practice of some older object formats and
- install a value including the symbol. */
- unsigned int install_addend:1;
-
- /* src_mask selects the part of the instruction (or data) to be used
- in the relocation sum. If the target relocations don't have an
- addend in the reloc, eg. ELF USE_REL, src_mask will normally equal
- dst_mask to extract the addend from the section contents. If
- relocations do have an addend in the reloc, eg. ELF USE_RELA, this
- field should normally be zero. Non-zero values for ELF USE_RELA
- targets should be viewed with suspicion as normally the value in
- the dst_mask part of the section contents should be ignored. */
- bfd_vma src_mask;
-
- /* dst_mask selects which parts of the instruction (or data) are
- replaced with a relocated value. */
- bfd_vma dst_mask;
-
- /* If this field is non null, then the supplied function is
- called rather than the normal function. This allows really
- strange relocation methods to be accommodated. */
- bfd_reloc_status_type (*special_function)
- (bfd *, arelent *, struct bfd_symbol *, void *, asection *,
- bfd *, char **);
-
- /* The textual name of the relocation type. */
- const char *name;
-};
-
-#define HOWTO_INSTALL_ADDEND 0
-#define HOWTO_RSIZE(sz) ((sz) < 0 ? -(sz) : (sz))
-#define HOWTO(type, right, size, bits, pcrel, left, ovf, func, name, \
- inplace, src_mask, dst_mask, pcrel_off) \
- { (unsigned) type, HOWTO_RSIZE (size), bits, right, left, ovf, \
- size < 0, pcrel, inplace, pcrel_off, HOWTO_INSTALL_ADDEND, \
- src_mask, dst_mask, func, name }
-#define EMPTY_HOWTO(C) \
- HOWTO ((C), 0, 1, 0, false, 0, complain_overflow_dont, NULL, \
- NULL, false, 0, 0, false)
-
-static inline unsigned int
-bfd_get_reloc_size (reloc_howto_type *howto)
-{
- return howto->size;
-}
-
-typedef struct relent_chain
-{
- arelent relent;
- struct relent_chain *next;
-}
-arelent_chain;
-
-bfd_reloc_status_type bfd_check_overflow
- (enum complain_overflow how,
- unsigned int bitsize,
- unsigned int rightshift,
- unsigned int addrsize,
- bfd_vma relocation);
-
-bool bfd_reloc_offset_in_range
- (reloc_howto_type *howto,
- bfd *abfd,
- asection *section,
- bfd_size_type offset);
-
-bfd_reloc_status_type bfd_perform_relocation
- (bfd *abfd,
- arelent *reloc_entry,
- void *data,
- asection *input_section,
- bfd *output_bfd,
- char **error_message);
-
-bfd_reloc_status_type bfd_install_relocation
- (bfd *abfd,
- arelent *reloc_entry,
- void *data, bfd_vma data_start,
- asection *input_section,
- char **error_message);
-
-enum bfd_reloc_code_real
-{
- _dummy_first_bfd_reloc_code_real,
-
-
- /* Basic absolute relocations of N bits. */
- BFD_RELOC_64,
- BFD_RELOC_32,
- BFD_RELOC_26,
- BFD_RELOC_24,
- BFD_RELOC_16,
- BFD_RELOC_14,
- BFD_RELOC_8,
-
- /* PC-relative relocations. Sometimes these are relative to the
- address of the relocation itself; sometimes they are relative to the
- start of the section containing the relocation. It depends on the
- specific target. */
- BFD_RELOC_64_PCREL,
- BFD_RELOC_32_PCREL,
- BFD_RELOC_24_PCREL,
- BFD_RELOC_16_PCREL,
- BFD_RELOC_12_PCREL,
- BFD_RELOC_8_PCREL,
-
- /* Section relative relocations. Some targets need this for DWARF2. */
- BFD_RELOC_32_SECREL,
- BFD_RELOC_16_SECIDX,
-
- /* For ELF. */
- BFD_RELOC_32_GOT_PCREL,
- BFD_RELOC_16_GOT_PCREL,
- BFD_RELOC_8_GOT_PCREL,
- BFD_RELOC_32_GOTOFF,
- BFD_RELOC_16_GOTOFF,
- BFD_RELOC_LO16_GOTOFF,
- BFD_RELOC_HI16_GOTOFF,
- BFD_RELOC_HI16_S_GOTOFF,
- BFD_RELOC_8_GOTOFF,
- BFD_RELOC_64_PLT_PCREL,
- BFD_RELOC_32_PLT_PCREL,
- BFD_RELOC_24_PLT_PCREL,
- BFD_RELOC_16_PLT_PCREL,
- BFD_RELOC_8_PLT_PCREL,
- BFD_RELOC_64_PLTOFF,
- BFD_RELOC_32_PLTOFF,
- BFD_RELOC_16_PLTOFF,
- BFD_RELOC_LO16_PLTOFF,
- BFD_RELOC_HI16_PLTOFF,
- BFD_RELOC_HI16_S_PLTOFF,
- BFD_RELOC_8_PLTOFF,
-
- /* Size relocations. */
- BFD_RELOC_SIZE32,
- BFD_RELOC_SIZE64,
-
- /* Relocations used by 68K ELF. */
- BFD_RELOC_68K_GLOB_DAT,
- BFD_RELOC_68K_JMP_SLOT,
- BFD_RELOC_68K_RELATIVE,
- BFD_RELOC_68K_TLS_GD32,
- BFD_RELOC_68K_TLS_GD16,
- BFD_RELOC_68K_TLS_GD8,
- BFD_RELOC_68K_TLS_LDM32,
- BFD_RELOC_68K_TLS_LDM16,
- BFD_RELOC_68K_TLS_LDM8,
- BFD_RELOC_68K_TLS_LDO32,
- BFD_RELOC_68K_TLS_LDO16,
- BFD_RELOC_68K_TLS_LDO8,
- BFD_RELOC_68K_TLS_IE32,
- BFD_RELOC_68K_TLS_IE16,
- BFD_RELOC_68K_TLS_IE8,
- BFD_RELOC_68K_TLS_LE32,
- BFD_RELOC_68K_TLS_LE16,
- BFD_RELOC_68K_TLS_LE8,
-
- /* Linkage-table relative. */
- BFD_RELOC_32_BASEREL,
- BFD_RELOC_16_BASEREL,
- BFD_RELOC_LO16_BASEREL,
- BFD_RELOC_HI16_BASEREL,
- BFD_RELOC_HI16_S_BASEREL,
- BFD_RELOC_8_BASEREL,
- BFD_RELOC_RVA,
-
- /* Absolute 8-bit relocation, but used to form an address like 0xFFnn. */
- BFD_RELOC_8_FFnn,
-
- /* These PC-relative relocations are stored as word displacements --
- i.e., byte displacements shifted right two bits. The 30-bit word
- displacement (<<32_PCREL_S2>> -- 32 bits, shifted 2) is used on the
- SPARC. (SPARC tools generally refer to this as <<WDISP30>>.) The
- signed 16-bit displacement is used on the MIPS, and the 23-bit
- displacement is used on the Alpha. */
- BFD_RELOC_32_PCREL_S2,
- BFD_RELOC_16_PCREL_S2,
- BFD_RELOC_23_PCREL_S2,
-
- /* High 22 bits and low 10 bits of 32-bit value, placed into lower bits
- of the target word. These are used on the SPARC. */
- BFD_RELOC_HI22,
- BFD_RELOC_LO10,
-
- /* For systems that allocate a Global Pointer register, these are
- displacements off that register. These relocation types are
- handled specially, because the value the register will have is
- decided relatively late. */
- BFD_RELOC_GPREL16,
- BFD_RELOC_GPREL32,
-
- /* SPARC ELF relocations. There is probably some overlap with other
- relocation types already defined. */
- BFD_RELOC_NONE,
- BFD_RELOC_SPARC_WDISP22,
- BFD_RELOC_SPARC22,
- BFD_RELOC_SPARC13,
- BFD_RELOC_SPARC_GOT10,
- BFD_RELOC_SPARC_GOT13,
- BFD_RELOC_SPARC_GOT22,
- BFD_RELOC_SPARC_PC10,
- BFD_RELOC_SPARC_PC22,
- BFD_RELOC_SPARC_WPLT30,
- BFD_RELOC_SPARC_COPY,
- BFD_RELOC_SPARC_GLOB_DAT,
- BFD_RELOC_SPARC_JMP_SLOT,
- BFD_RELOC_SPARC_RELATIVE,
- BFD_RELOC_SPARC_UA16,
- BFD_RELOC_SPARC_UA32,
- BFD_RELOC_SPARC_UA64,
- BFD_RELOC_SPARC_GOTDATA_HIX22,
- BFD_RELOC_SPARC_GOTDATA_LOX10,
- BFD_RELOC_SPARC_GOTDATA_OP_HIX22,
- BFD_RELOC_SPARC_GOTDATA_OP_LOX10,
- BFD_RELOC_SPARC_GOTDATA_OP,
- BFD_RELOC_SPARC_JMP_IREL,
- BFD_RELOC_SPARC_IRELATIVE,
-
- /* I think these are specific to SPARC a.out (e.g., Sun 4). */
- BFD_RELOC_SPARC_BASE13,
- BFD_RELOC_SPARC_BASE22,
-
- /* SPARC64 relocations. */
-#define BFD_RELOC_SPARC_64 BFD_RELOC_64
- BFD_RELOC_SPARC_10,
- BFD_RELOC_SPARC_11,
- BFD_RELOC_SPARC_OLO10,
- BFD_RELOC_SPARC_HH22,
- BFD_RELOC_SPARC_HM10,
- BFD_RELOC_SPARC_LM22,
- BFD_RELOC_SPARC_PC_HH22,
- BFD_RELOC_SPARC_PC_HM10,
- BFD_RELOC_SPARC_PC_LM22,
- BFD_RELOC_SPARC_WDISP16,
- BFD_RELOC_SPARC_WDISP19,
- BFD_RELOC_SPARC_7,
- BFD_RELOC_SPARC_6,
- BFD_RELOC_SPARC_5,
-#define BFD_RELOC_SPARC_DISP64 BFD_RELOC_64_PCREL
- BFD_RELOC_SPARC_PLT32,
- BFD_RELOC_SPARC_PLT64,
- BFD_RELOC_SPARC_HIX22,
- BFD_RELOC_SPARC_LOX10,
- BFD_RELOC_SPARC_H44,
- BFD_RELOC_SPARC_M44,
- BFD_RELOC_SPARC_L44,
- BFD_RELOC_SPARC_REGISTER,
- BFD_RELOC_SPARC_H34,
- BFD_RELOC_SPARC_SIZE32,
- BFD_RELOC_SPARC_SIZE64,
- BFD_RELOC_SPARC_WDISP10,
-
- /* SPARC little endian relocation. */
- BFD_RELOC_SPARC_REV32,
-
- /* SPARC TLS relocations. */
- BFD_RELOC_SPARC_TLS_GD_HI22,
- BFD_RELOC_SPARC_TLS_GD_LO10,
- BFD_RELOC_SPARC_TLS_GD_ADD,
- BFD_RELOC_SPARC_TLS_GD_CALL,
- BFD_RELOC_SPARC_TLS_LDM_HI22,
- BFD_RELOC_SPARC_TLS_LDM_LO10,
- BFD_RELOC_SPARC_TLS_LDM_ADD,
- BFD_RELOC_SPARC_TLS_LDM_CALL,
- BFD_RELOC_SPARC_TLS_LDO_HIX22,
- BFD_RELOC_SPARC_TLS_LDO_LOX10,
- BFD_RELOC_SPARC_TLS_LDO_ADD,
- BFD_RELOC_SPARC_TLS_IE_HI22,
- BFD_RELOC_SPARC_TLS_IE_LO10,
- BFD_RELOC_SPARC_TLS_IE_LD,
- BFD_RELOC_SPARC_TLS_IE_LDX,
- BFD_RELOC_SPARC_TLS_IE_ADD,
- BFD_RELOC_SPARC_TLS_LE_HIX22,
- BFD_RELOC_SPARC_TLS_LE_LOX10,
- BFD_RELOC_SPARC_TLS_DTPMOD32,
- BFD_RELOC_SPARC_TLS_DTPMOD64,
- BFD_RELOC_SPARC_TLS_DTPOFF32,
- BFD_RELOC_SPARC_TLS_DTPOFF64,
- BFD_RELOC_SPARC_TLS_TPOFF32,
- BFD_RELOC_SPARC_TLS_TPOFF64,
-
- /* SPU Relocations. */
- BFD_RELOC_SPU_IMM7,
- BFD_RELOC_SPU_IMM8,
- BFD_RELOC_SPU_IMM10,
- BFD_RELOC_SPU_IMM10W,
- BFD_RELOC_SPU_IMM16,
- BFD_RELOC_SPU_IMM16W,
- BFD_RELOC_SPU_IMM18,
- BFD_RELOC_SPU_PCREL9a,
- BFD_RELOC_SPU_PCREL9b,
- BFD_RELOC_SPU_PCREL16,
- BFD_RELOC_SPU_LO16,
- BFD_RELOC_SPU_HI16,
- BFD_RELOC_SPU_PPU32,
- BFD_RELOC_SPU_PPU64,
- BFD_RELOC_SPU_ADD_PIC,
-
- /* Alpha ECOFF and ELF relocations. Some of these treat the symbol or
- "addend" in some special way.
- For GPDISP_HI16 ("gpdisp") relocations, the symbol is ignored when
- writing; when reading, it will be the absolute section symbol. The
- addend is the displacement in bytes of the "lda" instruction from
- the "ldah" instruction (which is at the address of this reloc). */
- BFD_RELOC_ALPHA_GPDISP_HI16,
-
- /* For GPDISP_LO16 ("ignore") relocations, the symbol is handled as
- with GPDISP_HI16 relocs. The addend is ignored when writing the
- relocations out, and is filled in with the file's GP value on
- reading, for convenience. */
- BFD_RELOC_ALPHA_GPDISP_LO16,
-
- /* The ELF GPDISP relocation is exactly the same as the GPDISP_HI16
- relocation except that there is no accompanying GPDISP_LO16
- relocation. */
- BFD_RELOC_ALPHA_GPDISP,
-
- /* The Alpha LITERAL/LITUSE relocs are produced by a symbol reference;
- the assembler turns it into a LDQ instruction to load the address of
- the symbol, and then fills in a register in the real instruction.
-
- The LITERAL reloc, at the LDQ instruction, refers to the .lita
- section symbol. The addend is ignored when writing, but is filled
- in with the file's GP value on reading, for convenience, as with the
- GPDISP_LO16 reloc.
-
- The ELF_LITERAL reloc is somewhere between 16_GOTOFF and GPDISP_LO16.
- It should refer to the symbol to be referenced, as with 16_GOTOFF,
- but it generates output not based on the position within the .got
- section, but relative to the GP value chosen for the file during the
- final link stage.
-
- The LITUSE reloc, on the instruction using the loaded address, gives
- information to the linker that it might be able to use to optimize
- away some literal section references. The symbol is ignored (read
- as the absolute section symbol), and the "addend" indicates the type
- of instruction using the register:
- 1 - "memory" fmt insn
- 2 - byte-manipulation (byte offset reg)
- 3 - jsr (target of branch) */
- BFD_RELOC_ALPHA_LITERAL,
- BFD_RELOC_ALPHA_ELF_LITERAL,
- BFD_RELOC_ALPHA_LITUSE,
-
- /* The HINT relocation indicates a value that should be filled into the
- "hint" field of a jmp/jsr/ret instruction, for possible branch-
- prediction logic which may be provided on some processors. */
- BFD_RELOC_ALPHA_HINT,
-
- /* The LINKAGE relocation outputs a linkage pair in the object file,
- which is filled by the linker. */
- BFD_RELOC_ALPHA_LINKAGE,
-
- /* The CODEADDR relocation outputs a STO_CA in the object file,
- which is filled by the linker. */
- BFD_RELOC_ALPHA_CODEADDR,
-
- /* The GPREL_HI/LO relocations together form a 32-bit offset from the
- GP register. */
- BFD_RELOC_ALPHA_GPREL_HI16,
- BFD_RELOC_ALPHA_GPREL_LO16,
-
- /* Like BFD_RELOC_23_PCREL_S2, except that the source and target must
- share a common GP, and the target address is adjusted for
- STO_ALPHA_STD_GPLOAD. */
- BFD_RELOC_ALPHA_BRSGP,
-
- /* The NOP relocation outputs a NOP if the longword displacement
- between two procedure entry points is < 2^21. */
- BFD_RELOC_ALPHA_NOP,
-
- /* The BSR relocation outputs a BSR if the longword displacement
- between two procedure entry points is < 2^21. */
- BFD_RELOC_ALPHA_BSR,
-
- /* The LDA relocation outputs a LDA if the longword displacement
- between two procedure entry points is < 2^16. */
- BFD_RELOC_ALPHA_LDA,
-
- /* The BOH relocation outputs a BSR if the longword displacement
- between two procedure entry points is < 2^21, or else a hint. */
- BFD_RELOC_ALPHA_BOH,
-
- /* Alpha thread-local storage relocations. */
- BFD_RELOC_ALPHA_TLSGD,
- BFD_RELOC_ALPHA_TLSLDM,
- BFD_RELOC_ALPHA_DTPMOD64,
- BFD_RELOC_ALPHA_GOTDTPREL16,
- BFD_RELOC_ALPHA_DTPREL64,
- BFD_RELOC_ALPHA_DTPREL_HI16,
- BFD_RELOC_ALPHA_DTPREL_LO16,
- BFD_RELOC_ALPHA_DTPREL16,
- BFD_RELOC_ALPHA_GOTTPREL16,
- BFD_RELOC_ALPHA_TPREL64,
- BFD_RELOC_ALPHA_TPREL_HI16,
- BFD_RELOC_ALPHA_TPREL_LO16,
- BFD_RELOC_ALPHA_TPREL16,
-
- /* The MIPS jump instruction. */
- BFD_RELOC_MIPS_JMP,
- BFD_RELOC_MICROMIPS_JMP,
-
- /* The MIPS16 jump instruction. */
- BFD_RELOC_MIPS16_JMP,
-
- /* MIPS16 GP relative reloc. */
- BFD_RELOC_MIPS16_GPREL,
-
- /* High 16 bits of 32-bit value; simple reloc. */
- BFD_RELOC_HI16,
-
- /* High 16 bits of 32-bit value but the low 16 bits will be sign
- extended and added to form the final result. If the low 16
- bits form a negative number, we need to add one to the high value
- to compensate for the borrow when the low bits are added. */
- BFD_RELOC_HI16_S,
-
- /* Low 16 bits. */
- BFD_RELOC_LO16,
-
- /* High 16 bits of 32-bit pc-relative value. */
- BFD_RELOC_HI16_PCREL,
-
- /* High 16 bits of 32-bit pc-relative value, adjusted. */
- BFD_RELOC_HI16_S_PCREL,
-
- /* Low 16 bits of pc-relative value. */
- BFD_RELOC_LO16_PCREL,
-
- /* Equivalent of BFD_RELOC_MIPS_*, but with the MIPS16 layout of
- 16-bit immediate fields. */
- BFD_RELOC_MIPS16_GOT16,
- BFD_RELOC_MIPS16_CALL16,
-
- /* MIPS16 high 16 bits of 32-bit value. */
- BFD_RELOC_MIPS16_HI16,
-
- /* MIPS16 high 16 bits of 32-bit value but the low 16 bits will be sign
- extended and added to form the final result. If the low 16
- bits form a negative number, we need to add one to the high value
- to compensate for the borrow when the low bits are added. */
- BFD_RELOC_MIPS16_HI16_S,
-
- /* MIPS16 low 16 bits. */
- BFD_RELOC_MIPS16_LO16,
-
- /* MIPS16 TLS relocations. */
- BFD_RELOC_MIPS16_TLS_GD,
- BFD_RELOC_MIPS16_TLS_LDM,
- BFD_RELOC_MIPS16_TLS_DTPREL_HI16,
- BFD_RELOC_MIPS16_TLS_DTPREL_LO16,
- BFD_RELOC_MIPS16_TLS_GOTTPREL,
- BFD_RELOC_MIPS16_TLS_TPREL_HI16,
- BFD_RELOC_MIPS16_TLS_TPREL_LO16,
-
- /* Relocation against a MIPS literal section. */
- BFD_RELOC_MIPS_LITERAL,
- BFD_RELOC_MICROMIPS_LITERAL,
-
- /* microMIPS PC-relative relocations. */
- BFD_RELOC_MICROMIPS_7_PCREL_S1,
- BFD_RELOC_MICROMIPS_10_PCREL_S1,
- BFD_RELOC_MICROMIPS_16_PCREL_S1,
-
- /* MIPS16 PC-relative relocation. */
- BFD_RELOC_MIPS16_16_PCREL_S1,
-
- /* MIPS PC-relative relocations. */
- BFD_RELOC_MIPS_21_PCREL_S2,
- BFD_RELOC_MIPS_26_PCREL_S2,
- BFD_RELOC_MIPS_18_PCREL_S3,
- BFD_RELOC_MIPS_19_PCREL_S2,
-
- /* microMIPS versions of generic BFD relocs. */
- BFD_RELOC_MICROMIPS_GPREL16,
- BFD_RELOC_MICROMIPS_HI16,
- BFD_RELOC_MICROMIPS_HI16_S,
- BFD_RELOC_MICROMIPS_LO16,
-
- /* MIPS ELF relocations. */
- BFD_RELOC_MIPS_GOT16,
- BFD_RELOC_MICROMIPS_GOT16,
- BFD_RELOC_MIPS_CALL16,
- BFD_RELOC_MICROMIPS_CALL16,
- BFD_RELOC_MIPS_GOT_HI16,
- BFD_RELOC_MICROMIPS_GOT_HI16,
- BFD_RELOC_MIPS_GOT_LO16,
- BFD_RELOC_MICROMIPS_GOT_LO16,
- BFD_RELOC_MIPS_CALL_HI16,
- BFD_RELOC_MICROMIPS_CALL_HI16,
- BFD_RELOC_MIPS_CALL_LO16,
- BFD_RELOC_MICROMIPS_CALL_LO16,
- BFD_RELOC_MIPS_SUB,
- BFD_RELOC_MICROMIPS_SUB,
- BFD_RELOC_MIPS_GOT_PAGE,
- BFD_RELOC_MICROMIPS_GOT_PAGE,
- BFD_RELOC_MIPS_GOT_OFST,
- BFD_RELOC_MICROMIPS_GOT_OFST,
- BFD_RELOC_MIPS_GOT_DISP,
- BFD_RELOC_MICROMIPS_GOT_DISP,
- BFD_RELOC_MIPS_SHIFT5,
- BFD_RELOC_MIPS_SHIFT6,
- BFD_RELOC_MIPS_INSERT_A,
- BFD_RELOC_MIPS_INSERT_B,
- BFD_RELOC_MIPS_DELETE,
- BFD_RELOC_MIPS_HIGHEST,
- BFD_RELOC_MICROMIPS_HIGHEST,
- BFD_RELOC_MIPS_HIGHER,
- BFD_RELOC_MICROMIPS_HIGHER,
- BFD_RELOC_MIPS_SCN_DISP,
- BFD_RELOC_MICROMIPS_SCN_DISP,
- BFD_RELOC_MIPS_16,
- BFD_RELOC_MIPS_RELGOT,
- BFD_RELOC_MIPS_JALR,
- BFD_RELOC_MICROMIPS_JALR,
- BFD_RELOC_MIPS_TLS_DTPMOD32,
- BFD_RELOC_MIPS_TLS_DTPREL32,
- BFD_RELOC_MIPS_TLS_DTPMOD64,
- BFD_RELOC_MIPS_TLS_DTPREL64,
- BFD_RELOC_MIPS_TLS_GD,
- BFD_RELOC_MICROMIPS_TLS_GD,
- BFD_RELOC_MIPS_TLS_LDM,
- BFD_RELOC_MICROMIPS_TLS_LDM,
- BFD_RELOC_MIPS_TLS_DTPREL_HI16,
- BFD_RELOC_MICROMIPS_TLS_DTPREL_HI16,
- BFD_RELOC_MIPS_TLS_DTPREL_LO16,
- BFD_RELOC_MICROMIPS_TLS_DTPREL_LO16,
- BFD_RELOC_MIPS_TLS_GOTTPREL,
- BFD_RELOC_MICROMIPS_TLS_GOTTPREL,
- BFD_RELOC_MIPS_TLS_TPREL32,
- BFD_RELOC_MIPS_TLS_TPREL64,
- BFD_RELOC_MIPS_TLS_TPREL_HI16,
- BFD_RELOC_MICROMIPS_TLS_TPREL_HI16,
- BFD_RELOC_MIPS_TLS_TPREL_LO16,
- BFD_RELOC_MICROMIPS_TLS_TPREL_LO16,
- BFD_RELOC_MIPS_EH,
-
- /* MIPS ELF relocations (VxWorks and PLT extensions). */
- BFD_RELOC_MIPS_COPY,
- BFD_RELOC_MIPS_JUMP_SLOT,
-
- /* Moxie ELF relocations. */
- BFD_RELOC_MOXIE_10_PCREL,
-
- /* FT32 ELF relocations. */
- BFD_RELOC_FT32_10,
- BFD_RELOC_FT32_20,
- BFD_RELOC_FT32_17,
- BFD_RELOC_FT32_18,
- BFD_RELOC_FT32_RELAX,
- BFD_RELOC_FT32_SC0,
- BFD_RELOC_FT32_SC1,
- BFD_RELOC_FT32_15,
- BFD_RELOC_FT32_DIFF32,
-
- /* Fujitsu Frv Relocations. */
- BFD_RELOC_FRV_LABEL16,
- BFD_RELOC_FRV_LABEL24,
- BFD_RELOC_FRV_LO16,
- BFD_RELOC_FRV_HI16,
- BFD_RELOC_FRV_GPREL12,
- BFD_RELOC_FRV_GPRELU12,
- BFD_RELOC_FRV_GPREL32,
- BFD_RELOC_FRV_GPRELHI,
- BFD_RELOC_FRV_GPRELLO,
- BFD_RELOC_FRV_GOT12,
- BFD_RELOC_FRV_GOTHI,
- BFD_RELOC_FRV_GOTLO,
- BFD_RELOC_FRV_FUNCDESC,
- BFD_RELOC_FRV_FUNCDESC_GOT12,
- BFD_RELOC_FRV_FUNCDESC_GOTHI,
- BFD_RELOC_FRV_FUNCDESC_GOTLO,
- BFD_RELOC_FRV_FUNCDESC_VALUE,
- BFD_RELOC_FRV_FUNCDESC_GOTOFF12,
- BFD_RELOC_FRV_FUNCDESC_GOTOFFHI,
- BFD_RELOC_FRV_FUNCDESC_GOTOFFLO,
- BFD_RELOC_FRV_GOTOFF12,
- BFD_RELOC_FRV_GOTOFFHI,
- BFD_RELOC_FRV_GOTOFFLO,
- BFD_RELOC_FRV_GETTLSOFF,
- BFD_RELOC_FRV_TLSDESC_VALUE,
- BFD_RELOC_FRV_GOTTLSDESC12,
- BFD_RELOC_FRV_GOTTLSDESCHI,
- BFD_RELOC_FRV_GOTTLSDESCLO,
- BFD_RELOC_FRV_TLSMOFF12,
- BFD_RELOC_FRV_TLSMOFFHI,
- BFD_RELOC_FRV_TLSMOFFLO,
- BFD_RELOC_FRV_GOTTLSOFF12,
- BFD_RELOC_FRV_GOTTLSOFFHI,
- BFD_RELOC_FRV_GOTTLSOFFLO,
- BFD_RELOC_FRV_TLSOFF,
- BFD_RELOC_FRV_TLSDESC_RELAX,
- BFD_RELOC_FRV_GETTLSOFF_RELAX,
- BFD_RELOC_FRV_TLSOFF_RELAX,
- BFD_RELOC_FRV_TLSMOFF,
-
- /* This is a 24bit GOT-relative reloc for the mn10300. */
- BFD_RELOC_MN10300_GOTOFF24,
-
- /* This is a 32bit GOT-relative reloc for the mn10300, offset by two
- bytes in the instruction. */
- BFD_RELOC_MN10300_GOT32,
-
- /* This is a 24bit GOT-relative reloc for the mn10300, offset by two
- bytes in the instruction. */
- BFD_RELOC_MN10300_GOT24,
-
- /* This is a 16bit GOT-relative reloc for the mn10300, offset by two
- bytes in the instruction. */
- BFD_RELOC_MN10300_GOT16,
-
- /* Copy symbol at runtime. */
- BFD_RELOC_MN10300_COPY,
-
- /* Create GOT entry. */
- BFD_RELOC_MN10300_GLOB_DAT,
-
- /* Create PLT entry. */
- BFD_RELOC_MN10300_JMP_SLOT,
-
- /* Adjust by program base. */
- BFD_RELOC_MN10300_RELATIVE,
-
- /* Together with another reloc targeted at the same location, allows
- for a value that is the difference of two symbols in the same
- section. */
- BFD_RELOC_MN10300_SYM_DIFF,
-
- /* The addend of this reloc is an alignment power that must be honoured
- at the offset's location, regardless of linker relaxation. */
- BFD_RELOC_MN10300_ALIGN,
-
- /* Various TLS-related relocations. */
- BFD_RELOC_MN10300_TLS_GD,
- BFD_RELOC_MN10300_TLS_LD,
- BFD_RELOC_MN10300_TLS_LDO,
- BFD_RELOC_MN10300_TLS_GOTIE,
- BFD_RELOC_MN10300_TLS_IE,
- BFD_RELOC_MN10300_TLS_LE,
- BFD_RELOC_MN10300_TLS_DTPMOD,
- BFD_RELOC_MN10300_TLS_DTPOFF,
- BFD_RELOC_MN10300_TLS_TPOFF,
-
- /* This is a 32bit pcrel reloc for the mn10300, offset by two bytes in
- the instruction. */
- BFD_RELOC_MN10300_32_PCREL,
-
- /* This is a 16bit pcrel reloc for the mn10300, offset by two bytes in
- the instruction. */
- BFD_RELOC_MN10300_16_PCREL,
-
- /* i386/elf relocations. */
- BFD_RELOC_386_GOT32,
- BFD_RELOC_386_PLT32,
- BFD_RELOC_386_COPY,
- BFD_RELOC_386_GLOB_DAT,
- BFD_RELOC_386_JUMP_SLOT,
- BFD_RELOC_386_RELATIVE,
- BFD_RELOC_386_GOTOFF,
- BFD_RELOC_386_GOTPC,
- BFD_RELOC_386_TLS_TPOFF,
- BFD_RELOC_386_TLS_IE,
- BFD_RELOC_386_TLS_GOTIE,
- BFD_RELOC_386_TLS_LE,
- BFD_RELOC_386_TLS_GD,
- BFD_RELOC_386_TLS_LDM,
- BFD_RELOC_386_TLS_LDO_32,
- BFD_RELOC_386_TLS_IE_32,
- BFD_RELOC_386_TLS_LE_32,
- BFD_RELOC_386_TLS_DTPMOD32,
- BFD_RELOC_386_TLS_DTPOFF32,
- BFD_RELOC_386_TLS_TPOFF32,
- BFD_RELOC_386_TLS_GOTDESC,
- BFD_RELOC_386_TLS_DESC_CALL,
- BFD_RELOC_386_TLS_DESC,
- BFD_RELOC_386_IRELATIVE,
- BFD_RELOC_386_GOT32X,
-
- /* x86-64/elf relocations. */
- BFD_RELOC_X86_64_GOT32,
- BFD_RELOC_X86_64_PLT32,
- BFD_RELOC_X86_64_COPY,
- BFD_RELOC_X86_64_GLOB_DAT,
- BFD_RELOC_X86_64_JUMP_SLOT,
- BFD_RELOC_X86_64_RELATIVE,
- BFD_RELOC_X86_64_GOTPCREL,
- BFD_RELOC_X86_64_32S,
- BFD_RELOC_X86_64_DTPMOD64,
- BFD_RELOC_X86_64_DTPOFF64,
- BFD_RELOC_X86_64_TPOFF64,
- BFD_RELOC_X86_64_TLSGD,
- BFD_RELOC_X86_64_TLSLD,
- BFD_RELOC_X86_64_DTPOFF32,
- BFD_RELOC_X86_64_GOTTPOFF,
- BFD_RELOC_X86_64_TPOFF32,
- BFD_RELOC_X86_64_GOTOFF64,
- BFD_RELOC_X86_64_GOTPC32,
- BFD_RELOC_X86_64_GOT64,
- BFD_RELOC_X86_64_GOTPCREL64,
- BFD_RELOC_X86_64_GOTPC64,
- BFD_RELOC_X86_64_GOTPLT64,
- BFD_RELOC_X86_64_PLTOFF64,
- BFD_RELOC_X86_64_GOTPC32_TLSDESC,
- BFD_RELOC_X86_64_TLSDESC_CALL,
- BFD_RELOC_X86_64_TLSDESC,
- BFD_RELOC_X86_64_IRELATIVE,
- BFD_RELOC_X86_64_PC32_BND,
- BFD_RELOC_X86_64_PLT32_BND,
- BFD_RELOC_X86_64_GOTPCRELX,
- BFD_RELOC_X86_64_REX_GOTPCRELX,
- BFD_RELOC_X86_64_CODE_4_GOTPCRELX,
- BFD_RELOC_X86_64_CODE_4_GOTTPOFF,
- BFD_RELOC_X86_64_CODE_4_GOTPC32_TLSDESC,
- BFD_RELOC_X86_64_CODE_5_GOTPCRELX,
- BFD_RELOC_X86_64_CODE_5_GOTTPOFF,
- BFD_RELOC_X86_64_CODE_5_GOTPC32_TLSDESC,
- BFD_RELOC_X86_64_CODE_6_GOTPCRELX,
- BFD_RELOC_X86_64_CODE_6_GOTTPOFF,
- BFD_RELOC_X86_64_CODE_6_GOTPC32_TLSDESC,
-
- /* ns32k relocations. */
- BFD_RELOC_NS32K_IMM_8,
- BFD_RELOC_NS32K_IMM_16,
- BFD_RELOC_NS32K_IMM_32,
- BFD_RELOC_NS32K_IMM_8_PCREL,
- BFD_RELOC_NS32K_IMM_16_PCREL,
- BFD_RELOC_NS32K_IMM_32_PCREL,
- BFD_RELOC_NS32K_DISP_8,
- BFD_RELOC_NS32K_DISP_16,
- BFD_RELOC_NS32K_DISP_32,
- BFD_RELOC_NS32K_DISP_8_PCREL,
- BFD_RELOC_NS32K_DISP_16_PCREL,
- BFD_RELOC_NS32K_DISP_32_PCREL,
-
- /* PDP11 relocations. */
- BFD_RELOC_PDP11_DISP_8_PCREL,
- BFD_RELOC_PDP11_DISP_6_PCREL,
-
- /* Picojava relocs. Not all of these appear in object files. */
- BFD_RELOC_PJ_CODE_HI16,
- BFD_RELOC_PJ_CODE_LO16,
- BFD_RELOC_PJ_CODE_DIR16,
- BFD_RELOC_PJ_CODE_DIR32,
- BFD_RELOC_PJ_CODE_REL16,
- BFD_RELOC_PJ_CODE_REL32,
-
- /* Power(rs6000) and PowerPC relocations. */
- BFD_RELOC_PPC_B26,
- BFD_RELOC_PPC_BA26,
- BFD_RELOC_PPC_TOC16,
- BFD_RELOC_PPC_TOC16_LO,
- BFD_RELOC_PPC_TOC16_HI,
- BFD_RELOC_PPC_B16,
- BFD_RELOC_PPC_B16_BRTAKEN,
- BFD_RELOC_PPC_B16_BRNTAKEN,
- BFD_RELOC_PPC_BA16,
- BFD_RELOC_PPC_BA16_BRTAKEN,
- BFD_RELOC_PPC_BA16_BRNTAKEN,
- BFD_RELOC_PPC_COPY,
- BFD_RELOC_PPC_GLOB_DAT,
- BFD_RELOC_PPC_JMP_SLOT,
- BFD_RELOC_PPC_RELATIVE,
- BFD_RELOC_PPC_LOCAL24PC,
- BFD_RELOC_PPC_EMB_NADDR32,
- BFD_RELOC_PPC_EMB_NADDR16,
- BFD_RELOC_PPC_EMB_NADDR16_LO,
- BFD_RELOC_PPC_EMB_NADDR16_HI,
- BFD_RELOC_PPC_EMB_NADDR16_HA,
- BFD_RELOC_PPC_EMB_SDAI16,
- BFD_RELOC_PPC_EMB_SDA2I16,
- BFD_RELOC_PPC_EMB_SDA2REL,
- BFD_RELOC_PPC_EMB_SDA21,
- BFD_RELOC_PPC_EMB_MRKREF,
- BFD_RELOC_PPC_EMB_RELSEC16,
- BFD_RELOC_PPC_EMB_RELST_LO,
- BFD_RELOC_PPC_EMB_RELST_HI,
- BFD_RELOC_PPC_EMB_RELST_HA,
- BFD_RELOC_PPC_EMB_BIT_FLD,
- BFD_RELOC_PPC_EMB_RELSDA,
- BFD_RELOC_PPC_VLE_REL8,
- BFD_RELOC_PPC_VLE_REL15,
- BFD_RELOC_PPC_VLE_REL24,
- BFD_RELOC_PPC_VLE_LO16A,
- BFD_RELOC_PPC_VLE_LO16D,
- BFD_RELOC_PPC_VLE_HI16A,
- BFD_RELOC_PPC_VLE_HI16D,
- BFD_RELOC_PPC_VLE_HA16A,
- BFD_RELOC_PPC_VLE_HA16D,
- BFD_RELOC_PPC_VLE_SDA21,
- BFD_RELOC_PPC_VLE_SDA21_LO,
- BFD_RELOC_PPC_VLE_SDAREL_LO16A,
- BFD_RELOC_PPC_VLE_SDAREL_LO16D,
- BFD_RELOC_PPC_VLE_SDAREL_HI16A,
- BFD_RELOC_PPC_VLE_SDAREL_HI16D,
- BFD_RELOC_PPC_VLE_SDAREL_HA16A,
- BFD_RELOC_PPC_VLE_SDAREL_HA16D,
- BFD_RELOC_PPC_16DX_HA,
- BFD_RELOC_PPC_REL16DX_HA,
- BFD_RELOC_PPC_NEG,
- BFD_RELOC_PPC64_HIGHER,
- BFD_RELOC_PPC64_HIGHER_S,
- BFD_RELOC_PPC64_HIGHEST,
- BFD_RELOC_PPC64_HIGHEST_S,
- BFD_RELOC_PPC64_TOC16_LO,
- BFD_RELOC_PPC64_TOC16_HI,
- BFD_RELOC_PPC64_TOC16_HA,
- BFD_RELOC_PPC64_TOC,
- BFD_RELOC_PPC64_PLTGOT16,
- BFD_RELOC_PPC64_PLTGOT16_LO,
- BFD_RELOC_PPC64_PLTGOT16_HI,
- BFD_RELOC_PPC64_PLTGOT16_HA,
- BFD_RELOC_PPC64_ADDR16_DS,
- BFD_RELOC_PPC64_ADDR16_LO_DS,
- BFD_RELOC_PPC64_GOT16_DS,
- BFD_RELOC_PPC64_GOT16_LO_DS,
- BFD_RELOC_PPC64_PLT16_LO_DS,
- BFD_RELOC_PPC64_SECTOFF_DS,
- BFD_RELOC_PPC64_SECTOFF_LO_DS,
- BFD_RELOC_PPC64_TOC16_DS,
- BFD_RELOC_PPC64_TOC16_LO_DS,
- BFD_RELOC_PPC64_PLTGOT16_DS,
- BFD_RELOC_PPC64_PLTGOT16_LO_DS,
- BFD_RELOC_PPC64_ADDR16_HIGH,
- BFD_RELOC_PPC64_ADDR16_HIGHA,
- BFD_RELOC_PPC64_REL16_HIGH,
- BFD_RELOC_PPC64_REL16_HIGHA,
- BFD_RELOC_PPC64_REL16_HIGHER,
- BFD_RELOC_PPC64_REL16_HIGHERA,
- BFD_RELOC_PPC64_REL16_HIGHEST,
- BFD_RELOC_PPC64_REL16_HIGHESTA,
- BFD_RELOC_PPC64_ADDR64_LOCAL,
- BFD_RELOC_PPC64_ENTRY,
- BFD_RELOC_PPC64_REL24_NOTOC,
- BFD_RELOC_PPC64_REL24_P9NOTOC,
- BFD_RELOC_PPC64_D34,
- BFD_RELOC_PPC64_D34_LO,
- BFD_RELOC_PPC64_D34_HI30,
- BFD_RELOC_PPC64_D34_HA30,
- BFD_RELOC_PPC64_PCREL34,
- BFD_RELOC_PPC64_GOT_PCREL34,
- BFD_RELOC_PPC64_PLT_PCREL34,
- BFD_RELOC_PPC64_ADDR16_HIGHER34,
- BFD_RELOC_PPC64_ADDR16_HIGHERA34,
- BFD_RELOC_PPC64_ADDR16_HIGHEST34,
- BFD_RELOC_PPC64_ADDR16_HIGHESTA34,
- BFD_RELOC_PPC64_REL16_HIGHER34,
- BFD_RELOC_PPC64_REL16_HIGHERA34,
- BFD_RELOC_PPC64_REL16_HIGHEST34,
- BFD_RELOC_PPC64_REL16_HIGHESTA34,
- BFD_RELOC_PPC64_D28,
- BFD_RELOC_PPC64_PCREL28,
-
- /* PowerPC and PowerPC64 thread-local storage relocations. */
- BFD_RELOC_PPC_TLS,
- BFD_RELOC_PPC_TLSGD,
- BFD_RELOC_PPC_TLSLD,
- BFD_RELOC_PPC_TLSLE,
- BFD_RELOC_PPC_TLSIE,
- BFD_RELOC_PPC_TLSM,
- BFD_RELOC_PPC_TLSML,
- BFD_RELOC_PPC_DTPMOD,
- BFD_RELOC_PPC_TPREL16,
- BFD_RELOC_PPC_TPREL16_LO,
- BFD_RELOC_PPC_TPREL16_HI,
- BFD_RELOC_PPC_TPREL16_HA,
- BFD_RELOC_PPC_TPREL,
- BFD_RELOC_PPC_DTPREL16,
- BFD_RELOC_PPC_DTPREL16_LO,
- BFD_RELOC_PPC_DTPREL16_HI,
- BFD_RELOC_PPC_DTPREL16_HA,
- BFD_RELOC_PPC_DTPREL,
- BFD_RELOC_PPC_GOT_TLSGD16,
- BFD_RELOC_PPC_GOT_TLSGD16_LO,
- BFD_RELOC_PPC_GOT_TLSGD16_HI,
- BFD_RELOC_PPC_GOT_TLSGD16_HA,
- BFD_RELOC_PPC_GOT_TLSLD16,
- BFD_RELOC_PPC_GOT_TLSLD16_LO,
- BFD_RELOC_PPC_GOT_TLSLD16_HI,
- BFD_RELOC_PPC_GOT_TLSLD16_HA,
- BFD_RELOC_PPC_GOT_TPREL16,
- BFD_RELOC_PPC_GOT_TPREL16_LO,
- BFD_RELOC_PPC_GOT_TPREL16_HI,
- BFD_RELOC_PPC_GOT_TPREL16_HA,
- BFD_RELOC_PPC_GOT_DTPREL16,
- BFD_RELOC_PPC_GOT_DTPREL16_LO,
- BFD_RELOC_PPC_GOT_DTPREL16_HI,
- BFD_RELOC_PPC_GOT_DTPREL16_HA,
- BFD_RELOC_PPC64_TLSGD,
- BFD_RELOC_PPC64_TLSLD,
- BFD_RELOC_PPC64_TLSLE,
- BFD_RELOC_PPC64_TLSIE,
- BFD_RELOC_PPC64_TLSM,
- BFD_RELOC_PPC64_TLSML,
- BFD_RELOC_PPC64_TPREL16_DS,
- BFD_RELOC_PPC64_TPREL16_LO_DS,
- BFD_RELOC_PPC64_TPREL16_HIGH,
- BFD_RELOC_PPC64_TPREL16_HIGHA,
- BFD_RELOC_PPC64_TPREL16_HIGHER,
- BFD_RELOC_PPC64_TPREL16_HIGHERA,
- BFD_RELOC_PPC64_TPREL16_HIGHEST,
- BFD_RELOC_PPC64_TPREL16_HIGHESTA,
- BFD_RELOC_PPC64_DTPREL16_DS,
- BFD_RELOC_PPC64_DTPREL16_LO_DS,
- BFD_RELOC_PPC64_DTPREL16_HIGH,
- BFD_RELOC_PPC64_DTPREL16_HIGHA,
- BFD_RELOC_PPC64_DTPREL16_HIGHER,
- BFD_RELOC_PPC64_DTPREL16_HIGHERA,
- BFD_RELOC_PPC64_DTPREL16_HIGHEST,
- BFD_RELOC_PPC64_DTPREL16_HIGHESTA,
- BFD_RELOC_PPC64_TPREL34,
- BFD_RELOC_PPC64_DTPREL34,
- BFD_RELOC_PPC64_GOT_TLSGD_PCREL34,
- BFD_RELOC_PPC64_GOT_TLSLD_PCREL34,
- BFD_RELOC_PPC64_GOT_TPREL_PCREL34,
- BFD_RELOC_PPC64_GOT_DTPREL_PCREL34,
- BFD_RELOC_PPC64_TLS_PCREL,
-
- /* IBM 370/390 relocations. */
- BFD_RELOC_I370_D12,
-
- /* The type of reloc used to build a constructor table - at the moment
- probably a 32 bit wide absolute relocation, but the target can choose.
- It generally does map to one of the other relocation types. */
- BFD_RELOC_CTOR,
-
- /* ARM 26 bit pc-relative branch. The lowest two bits must be zero and
- are not stored in the instruction. */
- BFD_RELOC_ARM_PCREL_BRANCH,
-
- /* ARM 26 bit pc-relative branch. The lowest bit must be zero and is
- not stored in the instruction. The 2nd lowest bit comes from a 1 bit
- field in the instruction. */
- BFD_RELOC_ARM_PCREL_BLX,
-
- /* Thumb 22 bit pc-relative branch. The lowest bit must be zero and is
- not stored in the instruction. The 2nd lowest bit comes from a 1 bit
- field in the instruction. */
- BFD_RELOC_THUMB_PCREL_BLX,
-
- /* ARM 26-bit pc-relative branch for an unconditional BL or BLX
- instruction. */
- BFD_RELOC_ARM_PCREL_CALL,
-
- /* ARM 26-bit pc-relative branch for B or conditional BL instruction. */
- BFD_RELOC_ARM_PCREL_JUMP,
-
- /* ARM 5-bit pc-relative branch for Branch Future instructions. */
- BFD_RELOC_THUMB_PCREL_BRANCH5,
-
- /* ARM 6-bit pc-relative branch for BFCSEL instruction. */
- BFD_RELOC_THUMB_PCREL_BFCSEL,
-
- /* ARM 17-bit pc-relative branch for Branch Future instructions. */
- BFD_RELOC_ARM_THUMB_BF17,
-
- /* ARM 13-bit pc-relative branch for BFCSEL instruction. */
- BFD_RELOC_ARM_THUMB_BF13,
-
- /* ARM 19-bit pc-relative branch for Branch Future Link instruction. */
- BFD_RELOC_ARM_THUMB_BF19,
-
- /* ARM 12-bit pc-relative branch for Low Overhead Loop instructions. */
- BFD_RELOC_ARM_THUMB_LOOP12,
-
- /* Thumb 7-, 9-, 12-, 20-, 23-, and 25-bit pc-relative branches.
- The lowest bit must be zero and is not stored in the instruction.
- Note that the corresponding ELF R_ARM_THM_JUMPnn constant has an
- "nn" one smaller in all cases. Note further that BRANCH23
- corresponds to R_ARM_THM_CALL. */
- BFD_RELOC_THUMB_PCREL_BRANCH7,
- BFD_RELOC_THUMB_PCREL_BRANCH9,
- BFD_RELOC_THUMB_PCREL_BRANCH12,
- BFD_RELOC_THUMB_PCREL_BRANCH20,
- BFD_RELOC_THUMB_PCREL_BRANCH23,
- BFD_RELOC_THUMB_PCREL_BRANCH25,
-
- /* 12-bit immediate offset, used in ARM-format ldr and str instructions. */
- BFD_RELOC_ARM_OFFSET_IMM,
-
- /* 5-bit immediate offset, used in Thumb-format ldr and str instructions. */
- BFD_RELOC_ARM_THUMB_OFFSET,
-
- /* Pc-relative or absolute relocation depending on target. Used for
- entries in .init_array sections. */
- BFD_RELOC_ARM_TARGET1,
-
- /* Read-only segment base relative address. */
- BFD_RELOC_ARM_ROSEGREL32,
-
- /* Data segment base relative address. */
- BFD_RELOC_ARM_SBREL32,
-
- /* This reloc is used for references to RTTI data from exception
- handling tables. The actual definition depends on the target. It
- may be a pc-relative or some form of GOT-indirect relocation. */
- BFD_RELOC_ARM_TARGET2,
-
- /* 31-bit PC relative address. */
- BFD_RELOC_ARM_PREL31,
-
- /* Low and High halfword relocations for MOVW and MOVT instructions. */
- BFD_RELOC_ARM_MOVW,
- BFD_RELOC_ARM_MOVT,
- BFD_RELOC_ARM_MOVW_PCREL,
- BFD_RELOC_ARM_MOVT_PCREL,
- BFD_RELOC_ARM_THUMB_MOVW,
- BFD_RELOC_ARM_THUMB_MOVT,
- BFD_RELOC_ARM_THUMB_MOVW_PCREL,
- BFD_RELOC_ARM_THUMB_MOVT_PCREL,
-
- /* ARM FDPIC specific relocations. */
- BFD_RELOC_ARM_GOTFUNCDESC,
- BFD_RELOC_ARM_GOTOFFFUNCDESC,
- BFD_RELOC_ARM_FUNCDESC,
- BFD_RELOC_ARM_FUNCDESC_VALUE,
- BFD_RELOC_ARM_TLS_GD32_FDPIC,
- BFD_RELOC_ARM_TLS_LDM32_FDPIC,
- BFD_RELOC_ARM_TLS_IE32_FDPIC,
-
- /* Relocations for setting up GOTs and PLTs for shared libraries. */
- BFD_RELOC_ARM_JUMP_SLOT,
- BFD_RELOC_ARM_GLOB_DAT,
- BFD_RELOC_ARM_GOT32,
- BFD_RELOC_ARM_PLT32,
- BFD_RELOC_ARM_RELATIVE,
- BFD_RELOC_ARM_GOTOFF,
- BFD_RELOC_ARM_GOTPC,
- BFD_RELOC_ARM_GOT_PREL,
-
- /* ARM thread-local storage relocations. */
- BFD_RELOC_ARM_TLS_GD32,
- BFD_RELOC_ARM_TLS_LDO32,
- BFD_RELOC_ARM_TLS_LDM32,
- BFD_RELOC_ARM_TLS_DTPOFF32,
- BFD_RELOC_ARM_TLS_DTPMOD32,
- BFD_RELOC_ARM_TLS_TPOFF32,
- BFD_RELOC_ARM_TLS_IE32,
- BFD_RELOC_ARM_TLS_LE32,
- BFD_RELOC_ARM_TLS_GOTDESC,
- BFD_RELOC_ARM_TLS_CALL,
- BFD_RELOC_ARM_THM_TLS_CALL,
- BFD_RELOC_ARM_TLS_DESCSEQ,
- BFD_RELOC_ARM_THM_TLS_DESCSEQ,
- BFD_RELOC_ARM_TLS_DESC,
-
- /* ARM group relocations. */
- BFD_RELOC_ARM_ALU_PC_G0_NC,
- BFD_RELOC_ARM_ALU_PC_G0,
- BFD_RELOC_ARM_ALU_PC_G1_NC,
- BFD_RELOC_ARM_ALU_PC_G1,
- BFD_RELOC_ARM_ALU_PC_G2,
- BFD_RELOC_ARM_LDR_PC_G0,
- BFD_RELOC_ARM_LDR_PC_G1,
- BFD_RELOC_ARM_LDR_PC_G2,
- BFD_RELOC_ARM_LDRS_PC_G0,
- BFD_RELOC_ARM_LDRS_PC_G1,
- BFD_RELOC_ARM_LDRS_PC_G2,
- BFD_RELOC_ARM_LDC_PC_G0,
- BFD_RELOC_ARM_LDC_PC_G1,
- BFD_RELOC_ARM_LDC_PC_G2,
- BFD_RELOC_ARM_ALU_SB_G0_NC,
- BFD_RELOC_ARM_ALU_SB_G0,
- BFD_RELOC_ARM_ALU_SB_G1_NC,
- BFD_RELOC_ARM_ALU_SB_G1,
- BFD_RELOC_ARM_ALU_SB_G2,
- BFD_RELOC_ARM_LDR_SB_G0,
- BFD_RELOC_ARM_LDR_SB_G1,
- BFD_RELOC_ARM_LDR_SB_G2,
- BFD_RELOC_ARM_LDRS_SB_G0,
- BFD_RELOC_ARM_LDRS_SB_G1,
- BFD_RELOC_ARM_LDRS_SB_G2,
- BFD_RELOC_ARM_LDC_SB_G0,
- BFD_RELOC_ARM_LDC_SB_G1,
- BFD_RELOC_ARM_LDC_SB_G2,
-
- /* Annotation of BX instructions. */
- BFD_RELOC_ARM_V4BX,
-
- /* ARM support for STT_GNU_IFUNC. */
- BFD_RELOC_ARM_IRELATIVE,
-
- /* Thumb1 relocations to support execute-only code. */
- BFD_RELOC_ARM_THUMB_ALU_ABS_G0_NC,
- BFD_RELOC_ARM_THUMB_ALU_ABS_G1_NC,
- BFD_RELOC_ARM_THUMB_ALU_ABS_G2_NC,
- BFD_RELOC_ARM_THUMB_ALU_ABS_G3_NC,
-
- /* These relocs are only used within the ARM assembler. They are not
- (at present) written to any object files. */
- BFD_RELOC_ARM_IMMEDIATE,
- BFD_RELOC_ARM_ADRL_IMMEDIATE,
- BFD_RELOC_ARM_T32_IMMEDIATE,
- BFD_RELOC_ARM_T32_ADD_IMM,
- BFD_RELOC_ARM_T32_IMM12,
- BFD_RELOC_ARM_T32_ADD_PC12,
- BFD_RELOC_ARM_SHIFT_IMM,
- BFD_RELOC_ARM_SMC,
- BFD_RELOC_ARM_HVC,
- BFD_RELOC_ARM_SWI,
- BFD_RELOC_ARM_MULTI,
- BFD_RELOC_ARM_CP_OFF_IMM,
- BFD_RELOC_ARM_CP_OFF_IMM_S2,
- BFD_RELOC_ARM_T32_CP_OFF_IMM,
- BFD_RELOC_ARM_T32_CP_OFF_IMM_S2,
- BFD_RELOC_ARM_T32_VLDR_VSTR_OFF_IMM,
- BFD_RELOC_ARM_ADR_IMM,
- BFD_RELOC_ARM_LDR_IMM,
- BFD_RELOC_ARM_LITERAL,
- BFD_RELOC_ARM_IN_POOL,
- BFD_RELOC_ARM_OFFSET_IMM8,
- BFD_RELOC_ARM_T32_OFFSET_U8,
- BFD_RELOC_ARM_T32_OFFSET_IMM,
- BFD_RELOC_ARM_HWLITERAL,
- BFD_RELOC_ARM_THUMB_ADD,
- BFD_RELOC_ARM_THUMB_IMM,
- BFD_RELOC_ARM_THUMB_SHIFT,
-
- /* Renesas / SuperH SH relocs. Not all of these appear in object files. */
- BFD_RELOC_SH_PCDISP8BY2,
- BFD_RELOC_SH_PCDISP12BY2,
- BFD_RELOC_SH_IMM3,
- BFD_RELOC_SH_IMM3U,
- BFD_RELOC_SH_DISP12,
- BFD_RELOC_SH_DISP12BY2,
- BFD_RELOC_SH_DISP12BY4,
- BFD_RELOC_SH_DISP12BY8,
- BFD_RELOC_SH_DISP20,
- BFD_RELOC_SH_DISP20BY8,
- BFD_RELOC_SH_IMM4,
- BFD_RELOC_SH_IMM4BY2,
- BFD_RELOC_SH_IMM4BY4,
- BFD_RELOC_SH_IMM8,
- BFD_RELOC_SH_IMM8BY2,
- BFD_RELOC_SH_IMM8BY4,
- BFD_RELOC_SH_PCRELIMM8BY2,
- BFD_RELOC_SH_PCRELIMM8BY4,
- BFD_RELOC_SH_SWITCH16,
- BFD_RELOC_SH_SWITCH32,
- BFD_RELOC_SH_USES,
- BFD_RELOC_SH_COUNT,
- BFD_RELOC_SH_ALIGN,
- BFD_RELOC_SH_CODE,
- BFD_RELOC_SH_DATA,
- BFD_RELOC_SH_LABEL,
- BFD_RELOC_SH_LOOP_START,
- BFD_RELOC_SH_LOOP_END,
- BFD_RELOC_SH_COPY,
- BFD_RELOC_SH_GLOB_DAT,
- BFD_RELOC_SH_JMP_SLOT,
- BFD_RELOC_SH_RELATIVE,
- BFD_RELOC_SH_GOTPC,
- BFD_RELOC_SH_GOT_LOW16,
- BFD_RELOC_SH_GOT_MEDLOW16,
- BFD_RELOC_SH_GOT_MEDHI16,
- BFD_RELOC_SH_GOT_HI16,
- BFD_RELOC_SH_GOTPLT_LOW16,
- BFD_RELOC_SH_GOTPLT_MEDLOW16,
- BFD_RELOC_SH_GOTPLT_MEDHI16,
- BFD_RELOC_SH_GOTPLT_HI16,
- BFD_RELOC_SH_PLT_LOW16,
- BFD_RELOC_SH_PLT_MEDLOW16,
- BFD_RELOC_SH_PLT_MEDHI16,
- BFD_RELOC_SH_PLT_HI16,
- BFD_RELOC_SH_GOTOFF_LOW16,
- BFD_RELOC_SH_GOTOFF_MEDLOW16,
- BFD_RELOC_SH_GOTOFF_MEDHI16,
- BFD_RELOC_SH_GOTOFF_HI16,
- BFD_RELOC_SH_GOTPC_LOW16,
- BFD_RELOC_SH_GOTPC_MEDLOW16,
- BFD_RELOC_SH_GOTPC_MEDHI16,
- BFD_RELOC_SH_GOTPC_HI16,
- BFD_RELOC_SH_COPY64,
- BFD_RELOC_SH_GLOB_DAT64,
- BFD_RELOC_SH_JMP_SLOT64,
- BFD_RELOC_SH_RELATIVE64,
- BFD_RELOC_SH_GOT10BY4,
- BFD_RELOC_SH_GOT10BY8,
- BFD_RELOC_SH_GOTPLT10BY4,
- BFD_RELOC_SH_GOTPLT10BY8,
- BFD_RELOC_SH_GOTPLT32,
- BFD_RELOC_SH_SHMEDIA_CODE,
- BFD_RELOC_SH_IMMU5,
- BFD_RELOC_SH_IMMS6,
- BFD_RELOC_SH_IMMS6BY32,
- BFD_RELOC_SH_IMMU6,
- BFD_RELOC_SH_IMMS10,
- BFD_RELOC_SH_IMMS10BY2,
- BFD_RELOC_SH_IMMS10BY4,
- BFD_RELOC_SH_IMMS10BY8,
- BFD_RELOC_SH_IMMS16,
- BFD_RELOC_SH_IMMU16,
- BFD_RELOC_SH_IMM_LOW16,
- BFD_RELOC_SH_IMM_LOW16_PCREL,
- BFD_RELOC_SH_IMM_MEDLOW16,
- BFD_RELOC_SH_IMM_MEDLOW16_PCREL,
- BFD_RELOC_SH_IMM_MEDHI16,
- BFD_RELOC_SH_IMM_MEDHI16_PCREL,
- BFD_RELOC_SH_IMM_HI16,
- BFD_RELOC_SH_IMM_HI16_PCREL,
- BFD_RELOC_SH_PT_16,
- BFD_RELOC_SH_TLS_GD_32,
- BFD_RELOC_SH_TLS_LD_32,
- BFD_RELOC_SH_TLS_LDO_32,
- BFD_RELOC_SH_TLS_IE_32,
- BFD_RELOC_SH_TLS_LE_32,
- BFD_RELOC_SH_TLS_DTPMOD32,
- BFD_RELOC_SH_TLS_DTPOFF32,
- BFD_RELOC_SH_TLS_TPOFF32,
- BFD_RELOC_SH_GOT20,
- BFD_RELOC_SH_GOTOFF20,
- BFD_RELOC_SH_GOTFUNCDESC,
- BFD_RELOC_SH_GOTFUNCDESC20,
- BFD_RELOC_SH_GOTOFFFUNCDESC,
- BFD_RELOC_SH_GOTOFFFUNCDESC20,
- BFD_RELOC_SH_FUNCDESC,
-
- /* ARC relocs. */
- BFD_RELOC_ARC_NONE,
- BFD_RELOC_ARC_8,
- BFD_RELOC_ARC_16,
- BFD_RELOC_ARC_24,
- BFD_RELOC_ARC_32,
- BFD_RELOC_ARC_N8,
- BFD_RELOC_ARC_N16,
- BFD_RELOC_ARC_N24,
- BFD_RELOC_ARC_N32,
- BFD_RELOC_ARC_SDA,
- BFD_RELOC_ARC_SECTOFF,
- BFD_RELOC_ARC_S21H_PCREL,
- BFD_RELOC_ARC_S21W_PCREL,
- BFD_RELOC_ARC_S25H_PCREL,
- BFD_RELOC_ARC_S25W_PCREL,
- BFD_RELOC_ARC_SDA32,
- BFD_RELOC_ARC_SDA_LDST,
- BFD_RELOC_ARC_SDA_LDST1,
- BFD_RELOC_ARC_SDA_LDST2,
- BFD_RELOC_ARC_SDA16_LD,
- BFD_RELOC_ARC_SDA16_LD1,
- BFD_RELOC_ARC_SDA16_LD2,
- BFD_RELOC_ARC_S13_PCREL,
- BFD_RELOC_ARC_W,
- BFD_RELOC_ARC_32_ME,
- BFD_RELOC_ARC_32_ME_S,
- BFD_RELOC_ARC_N32_ME,
- BFD_RELOC_ARC_SECTOFF_ME,
- BFD_RELOC_ARC_SDA32_ME,
- BFD_RELOC_ARC_W_ME,
- BFD_RELOC_AC_SECTOFF_U8,
- BFD_RELOC_AC_SECTOFF_U8_1,
- BFD_RELOC_AC_SECTOFF_U8_2,
- BFD_RELOC_AC_SECTOFF_S9,
- BFD_RELOC_AC_SECTOFF_S9_1,
- BFD_RELOC_AC_SECTOFF_S9_2,
- BFD_RELOC_ARC_SECTOFF_ME_1,
- BFD_RELOC_ARC_SECTOFF_ME_2,
- BFD_RELOC_ARC_SECTOFF_1,
- BFD_RELOC_ARC_SECTOFF_2,
- BFD_RELOC_ARC_SDA_12,
- BFD_RELOC_ARC_SDA16_ST2,
- BFD_RELOC_ARC_32_PCREL,
- BFD_RELOC_ARC_PC32,
- BFD_RELOC_ARC_GOT32,
- BFD_RELOC_ARC_GOTPC32,
- BFD_RELOC_ARC_PLT32,
- BFD_RELOC_ARC_COPY,
- BFD_RELOC_ARC_GLOB_DAT,
- BFD_RELOC_ARC_JMP_SLOT,
- BFD_RELOC_ARC_RELATIVE,
- BFD_RELOC_ARC_GOTOFF,
- BFD_RELOC_ARC_GOTPC,
- BFD_RELOC_ARC_S21W_PCREL_PLT,
- BFD_RELOC_ARC_S25H_PCREL_PLT,
- BFD_RELOC_ARC_TLS_DTPMOD,
- BFD_RELOC_ARC_TLS_TPOFF,
- BFD_RELOC_ARC_TLS_GD_GOT,
- BFD_RELOC_ARC_TLS_GD_LD,
- BFD_RELOC_ARC_TLS_GD_CALL,
- BFD_RELOC_ARC_TLS_IE_GOT,
- BFD_RELOC_ARC_TLS_DTPOFF,
- BFD_RELOC_ARC_TLS_DTPOFF_S9,
- BFD_RELOC_ARC_TLS_LE_S9,
- BFD_RELOC_ARC_TLS_LE_32,
- BFD_RELOC_ARC_S25W_PCREL_PLT,
- BFD_RELOC_ARC_S21H_PCREL_PLT,
- BFD_RELOC_ARC_NPS_CMEM16,
- BFD_RELOC_ARC_JLI_SECTOFF,
-
- /* ADI Blackfin 16 bit immediate absolute reloc. */
- BFD_RELOC_BFIN_16_IMM,
-
- /* ADI Blackfin 16 bit immediate absolute reloc higher 16 bits. */
- BFD_RELOC_BFIN_16_HIGH,
-
- /* ADI Blackfin 'a' part of LSETUP. */
- BFD_RELOC_BFIN_4_PCREL,
-
- /* ADI Blackfin. */
- BFD_RELOC_BFIN_5_PCREL,
-
- /* ADI Blackfin 16 bit immediate absolute reloc lower 16 bits. */
- BFD_RELOC_BFIN_16_LOW,
-
- /* ADI Blackfin. */
- BFD_RELOC_BFIN_10_PCREL,
-
- /* ADI Blackfin 'b' part of LSETUP. */
- BFD_RELOC_BFIN_11_PCREL,
-
- /* ADI Blackfin. */
- BFD_RELOC_BFIN_12_PCREL_JUMP,
-
- /* ADI Blackfin Short jump, pcrel. */
- BFD_RELOC_BFIN_12_PCREL_JUMP_S,
-
- /* ADI Blackfin Call.x not implemented. */
- BFD_RELOC_BFIN_24_PCREL_CALL_X,
-
- /* ADI Blackfin Long Jump pcrel. */
- BFD_RELOC_BFIN_24_PCREL_JUMP_L,
-
- /* ADI Blackfin FD-PIC relocations. */
- BFD_RELOC_BFIN_GOT17M4,
- BFD_RELOC_BFIN_GOTHI,
- BFD_RELOC_BFIN_GOTLO,
- BFD_RELOC_BFIN_FUNCDESC,
- BFD_RELOC_BFIN_FUNCDESC_GOT17M4,
- BFD_RELOC_BFIN_FUNCDESC_GOTHI,
- BFD_RELOC_BFIN_FUNCDESC_GOTLO,
- BFD_RELOC_BFIN_FUNCDESC_VALUE,
- BFD_RELOC_BFIN_FUNCDESC_GOTOFF17M4,
- BFD_RELOC_BFIN_FUNCDESC_GOTOFFHI,
- BFD_RELOC_BFIN_FUNCDESC_GOTOFFLO,
- BFD_RELOC_BFIN_GOTOFF17M4,
- BFD_RELOC_BFIN_GOTOFFHI,
- BFD_RELOC_BFIN_GOTOFFLO,
-
- /* ADI Blackfin GOT relocation. */
- BFD_RELOC_BFIN_GOT,
-
- /* ADI Blackfin PLTPC relocation. */
- BFD_RELOC_BFIN_PLTPC,
-
- /* ADI Blackfin arithmetic relocation. */
- BFD_ARELOC_BFIN_PUSH,
-
- /* ADI Blackfin arithmetic relocation. */
- BFD_ARELOC_BFIN_CONST,
-
- /* ADI Blackfin arithmetic relocation. */
- BFD_ARELOC_BFIN_ADD,
-
- /* ADI Blackfin arithmetic relocation. */
- BFD_ARELOC_BFIN_SUB,
-
- /* ADI Blackfin arithmetic relocation. */
- BFD_ARELOC_BFIN_MULT,
-
- /* ADI Blackfin arithmetic relocation. */
- BFD_ARELOC_BFIN_DIV,
-
- /* ADI Blackfin arithmetic relocation. */
- BFD_ARELOC_BFIN_MOD,
-
- /* ADI Blackfin arithmetic relocation. */
- BFD_ARELOC_BFIN_LSHIFT,
-
- /* ADI Blackfin arithmetic relocation. */
- BFD_ARELOC_BFIN_RSHIFT,
-
- /* ADI Blackfin arithmetic relocation. */
- BFD_ARELOC_BFIN_AND,
-
- /* ADI Blackfin arithmetic relocation. */
- BFD_ARELOC_BFIN_OR,
-
- /* ADI Blackfin arithmetic relocation. */
- BFD_ARELOC_BFIN_XOR,
-
- /* ADI Blackfin arithmetic relocation. */
- BFD_ARELOC_BFIN_LAND,
-
- /* ADI Blackfin arithmetic relocation. */
- BFD_ARELOC_BFIN_LOR,
-
- /* ADI Blackfin arithmetic relocation. */
- BFD_ARELOC_BFIN_LEN,
-
- /* ADI Blackfin arithmetic relocation. */
- BFD_ARELOC_BFIN_NEG,
-
- /* ADI Blackfin arithmetic relocation. */
- BFD_ARELOC_BFIN_COMP,
-
- /* ADI Blackfin arithmetic relocation. */
- BFD_ARELOC_BFIN_PAGE,
-
- /* ADI Blackfin arithmetic relocation. */
- BFD_ARELOC_BFIN_HWPAGE,
-
- /* ADI Blackfin arithmetic relocation. */
- BFD_ARELOC_BFIN_ADDR,
-
- /* Mitsubishi D10V relocs.
- This is a 10-bit reloc with the right 2 bits assumed to be 0. */
- BFD_RELOC_D10V_10_PCREL_R,
-
- /* Mitsubishi D10V relocs.
- This is a 10-bit reloc with the right 2 bits assumed to be 0. This
- is the same as the previous reloc except it is in the left
- container, i.e., shifted left 15 bits. */
- BFD_RELOC_D10V_10_PCREL_L,
-
- /* This is an 18-bit reloc with the right 2 bits assumed to be 0. */
- BFD_RELOC_D10V_18,
-
- /* This is an 18-bit reloc with the right 2 bits assumed to be 0. */
- BFD_RELOC_D10V_18_PCREL,
-
- /* Mitsubishi D30V relocs.
- This is a 6-bit absolute reloc. */
- BFD_RELOC_D30V_6,
-
- /* This is a 6-bit pc-relative reloc with the right 3 bits assumed to
- be 0. */
- BFD_RELOC_D30V_9_PCREL,
-
- /* This is a 6-bit pc-relative reloc with the right 3 bits assumed to
- be 0. Same as the previous reloc but on the right side of the
- container. */
- BFD_RELOC_D30V_9_PCREL_R,
-
- /* This is a 12-bit absolute reloc with the right 3 bitsassumed to
- be 0. */
- BFD_RELOC_D30V_15,
-
- /* This is a 12-bit pc-relative reloc with the right 3 bits assumed to
- be 0. */
- BFD_RELOC_D30V_15_PCREL,
-
- /* This is a 12-bit pc-relative reloc with the right 3 bits assumed to
- be 0. Same as the previous reloc but on the right side of the
- container. */
- BFD_RELOC_D30V_15_PCREL_R,
-
- /* This is an 18-bit absolute reloc with the right 3 bits assumed to
- be 0. */
- BFD_RELOC_D30V_21,
-
- /* This is an 18-bit pc-relative reloc with the right 3 bits assumed to
- be 0. */
- BFD_RELOC_D30V_21_PCREL,
-
- /* This is an 18-bit pc-relative reloc with the right 3 bits assumed to
- be 0. Same as the previous reloc but on the right side of the
- container. */
- BFD_RELOC_D30V_21_PCREL_R,
-
- /* This is a 32-bit absolute reloc. */
- BFD_RELOC_D30V_32,
-
- /* This is a 32-bit pc-relative reloc. */
- BFD_RELOC_D30V_32_PCREL,
-
- /* DLX relocs. */
- BFD_RELOC_DLX_HI16_S,
- BFD_RELOC_DLX_LO16,
- BFD_RELOC_DLX_JMP26,
-
- /* Renesas M16C/M32C Relocations. */
- BFD_RELOC_M32C_HI8,
- BFD_RELOC_M32C_RL_JUMP,
- BFD_RELOC_M32C_RL_1ADDR,
- BFD_RELOC_M32C_RL_2ADDR,
-
- /* Renesas M32R (formerly Mitsubishi M32R) relocs.
- This is a 24 bit absolute address. */
- BFD_RELOC_M32R_24,
-
- /* This is a 10-bit pc-relative reloc with the right 2 bits assumed to
- be 0. */
- BFD_RELOC_M32R_10_PCREL,
-
- /* This is an 18-bit reloc with the right 2 bits assumed to be 0. */
- BFD_RELOC_M32R_18_PCREL,
-
- /* This is a 26-bit reloc with the right 2 bits assumed to be 0. */
- BFD_RELOC_M32R_26_PCREL,
-
- /* This is a 16-bit reloc containing the high 16 bits of an address
- used when the lower 16 bits are treated as unsigned. */
- BFD_RELOC_M32R_HI16_ULO,
-
- /* This is a 16-bit reloc containing the high 16 bits of an address
- used when the lower 16 bits are treated as signed. */
- BFD_RELOC_M32R_HI16_SLO,
-
- /* This is a 16-bit reloc containing the lower 16 bits of an address. */
- BFD_RELOC_M32R_LO16,
-
- /* This is a 16-bit reloc containing the small data area offset for use
- in add3, load, and store instructions. */
- BFD_RELOC_M32R_SDA16,
-
- /* For PIC. */
- BFD_RELOC_M32R_GOT24,
- BFD_RELOC_M32R_26_PLTREL,
- BFD_RELOC_M32R_COPY,
- BFD_RELOC_M32R_GLOB_DAT,
- BFD_RELOC_M32R_JMP_SLOT,
- BFD_RELOC_M32R_RELATIVE,
- BFD_RELOC_M32R_GOTOFF,
- BFD_RELOC_M32R_GOTOFF_HI_ULO,
- BFD_RELOC_M32R_GOTOFF_HI_SLO,
- BFD_RELOC_M32R_GOTOFF_LO,
- BFD_RELOC_M32R_GOTPC24,
- BFD_RELOC_M32R_GOT16_HI_ULO,
- BFD_RELOC_M32R_GOT16_HI_SLO,
- BFD_RELOC_M32R_GOT16_LO,
- BFD_RELOC_M32R_GOTPC_HI_ULO,
- BFD_RELOC_M32R_GOTPC_HI_SLO,
- BFD_RELOC_M32R_GOTPC_LO,
-
- /* NDS32 relocs.
- This is a 20 bit absolute address. */
- BFD_RELOC_NDS32_20,
-
- /* This is a 9-bit pc-relative reloc with the right 1 bit assumed to
- be 0. */
- BFD_RELOC_NDS32_9_PCREL,
-
- /* This is a 9-bit pc-relative reloc with the right 1 bit assumed to
- be 0. */
- BFD_RELOC_NDS32_WORD_9_PCREL,
-
- /* This is an 15-bit reloc with the right 1 bit assumed to be 0. */
- BFD_RELOC_NDS32_15_PCREL,
-
- /* This is an 17-bit reloc with the right 1 bit assumed to be 0. */
- BFD_RELOC_NDS32_17_PCREL,
-
- /* This is a 25-bit reloc with the right 1 bit assumed to be 0. */
- BFD_RELOC_NDS32_25_PCREL,
-
- /* This is a 20-bit reloc containing the high 20 bits of an address
- used with the lower 12 bits. */
- BFD_RELOC_NDS32_HI20,
-
- /* This is a 12-bit reloc containing the lower 12 bits of an address
- then shift right by 3. This is used with ldi,sdi. */
- BFD_RELOC_NDS32_LO12S3,
-
- /* This is a 12-bit reloc containing the lower 12 bits of an address
- then shift left by 2. This is used with lwi,swi. */
- BFD_RELOC_NDS32_LO12S2,
-
- /* This is a 12-bit reloc containing the lower 12 bits of an address
- then shift left by 1. This is used with lhi,shi. */
- BFD_RELOC_NDS32_LO12S1,
-
- /* This is a 12-bit reloc containing the lower 12 bits of an address
- then shift left by 0. This is used with lbisbi. */
- BFD_RELOC_NDS32_LO12S0,
-
- /* This is a 12-bit reloc containing the lower 12 bits of an address
- then shift left by 0. This is only used with branch relaxations. */
- BFD_RELOC_NDS32_LO12S0_ORI,
-
- /* This is a 15-bit reloc containing the small data area 18-bit signed
- offset and shift left by 3 for use in ldi, sdi. */
- BFD_RELOC_NDS32_SDA15S3,
-
- /* This is a 15-bit reloc containing the small data area 17-bit signed
- offset and shift left by 2 for use in lwi, swi. */
- BFD_RELOC_NDS32_SDA15S2,
-
- /* This is a 15-bit reloc containing the small data area 16-bit signed
- offset and shift left by 1 for use in lhi, shi. */
- BFD_RELOC_NDS32_SDA15S1,
-
- /* This is a 15-bit reloc containing the small data area 15-bit signed
- offset and shift left by 0 for use in lbi, sbi. */
- BFD_RELOC_NDS32_SDA15S0,
-
- /* This is a 16-bit reloc containing the small data area 16-bit signed
- offset and shift left by 3. */
- BFD_RELOC_NDS32_SDA16S3,
-
- /* This is a 17-bit reloc containing the small data area 17-bit signed
- offset and shift left by 2 for use in lwi.gp, swi.gp. */
- BFD_RELOC_NDS32_SDA17S2,
-
- /* This is a 18-bit reloc containing the small data area 18-bit signed
- offset and shift left by 1 for use in lhi.gp, shi.gp. */
- BFD_RELOC_NDS32_SDA18S1,
-
- /* This is a 19-bit reloc containing the small data area 19-bit signed
- offset and shift left by 0 for use in lbi.gp, sbi.gp. */
- BFD_RELOC_NDS32_SDA19S0,
-
- /* For PIC. */
- BFD_RELOC_NDS32_GOT20,
- BFD_RELOC_NDS32_9_PLTREL,
- BFD_RELOC_NDS32_25_PLTREL,
- BFD_RELOC_NDS32_COPY,
- BFD_RELOC_NDS32_GLOB_DAT,
- BFD_RELOC_NDS32_JMP_SLOT,
- BFD_RELOC_NDS32_RELATIVE,
- BFD_RELOC_NDS32_GOTOFF,
- BFD_RELOC_NDS32_GOTOFF_HI20,
- BFD_RELOC_NDS32_GOTOFF_LO12,
- BFD_RELOC_NDS32_GOTPC20,
- BFD_RELOC_NDS32_GOT_HI20,
- BFD_RELOC_NDS32_GOT_LO12,
- BFD_RELOC_NDS32_GOTPC_HI20,
- BFD_RELOC_NDS32_GOTPC_LO12,
-
- /* For relax. */
- BFD_RELOC_NDS32_INSN16,
- BFD_RELOC_NDS32_LABEL,
- BFD_RELOC_NDS32_LONGCALL1,
- BFD_RELOC_NDS32_LONGCALL2,
- BFD_RELOC_NDS32_LONGCALL3,
- BFD_RELOC_NDS32_LONGJUMP1,
- BFD_RELOC_NDS32_LONGJUMP2,
- BFD_RELOC_NDS32_LONGJUMP3,
- BFD_RELOC_NDS32_LOADSTORE,
- BFD_RELOC_NDS32_9_FIXED,
- BFD_RELOC_NDS32_15_FIXED,
- BFD_RELOC_NDS32_17_FIXED,
- BFD_RELOC_NDS32_25_FIXED,
- BFD_RELOC_NDS32_LONGCALL4,
- BFD_RELOC_NDS32_LONGCALL5,
- BFD_RELOC_NDS32_LONGCALL6,
- BFD_RELOC_NDS32_LONGJUMP4,
- BFD_RELOC_NDS32_LONGJUMP5,
- BFD_RELOC_NDS32_LONGJUMP6,
- BFD_RELOC_NDS32_LONGJUMP7,
-
- /* For PIC. */
- BFD_RELOC_NDS32_PLTREL_HI20,
- BFD_RELOC_NDS32_PLTREL_LO12,
- BFD_RELOC_NDS32_PLT_GOTREL_HI20,
- BFD_RELOC_NDS32_PLT_GOTREL_LO12,
-
- /* For floating point. */
- BFD_RELOC_NDS32_SDA12S2_DP,
- BFD_RELOC_NDS32_SDA12S2_SP,
- BFD_RELOC_NDS32_LO12S2_DP,
- BFD_RELOC_NDS32_LO12S2_SP,
-
- /* For dwarf2 debug_line. */
- BFD_RELOC_NDS32_DWARF2_OP1,
- BFD_RELOC_NDS32_DWARF2_OP2,
- BFD_RELOC_NDS32_DWARF2_LEB,
-
- /* For eliminating 16-bit instructions. */
- BFD_RELOC_NDS32_UPDATE_TA,
-
- /* For PIC object relaxation. */
- BFD_RELOC_NDS32_PLT_GOTREL_LO20,
- BFD_RELOC_NDS32_PLT_GOTREL_LO15,
- BFD_RELOC_NDS32_PLT_GOTREL_LO19,
- BFD_RELOC_NDS32_GOT_LO15,
- BFD_RELOC_NDS32_GOT_LO19,
- BFD_RELOC_NDS32_GOTOFF_LO15,
- BFD_RELOC_NDS32_GOTOFF_LO19,
- BFD_RELOC_NDS32_GOT15S2,
- BFD_RELOC_NDS32_GOT17S2,
-
- /* NDS32 relocs.
- This is a 5 bit absolute address. */
- BFD_RELOC_NDS32_5,
-
- /* This is a 10-bit unsigned pc-relative reloc with the right 1 bit
- assumed to be 0. */
- BFD_RELOC_NDS32_10_UPCREL,
-
- /* If fp were omitted, fp can used as another gp. */
- BFD_RELOC_NDS32_SDA_FP7U2_RELA,
-
- /* Relaxation relative relocation types. */
- BFD_RELOC_NDS32_RELAX_ENTRY,
- BFD_RELOC_NDS32_GOT_SUFF,
- BFD_RELOC_NDS32_GOTOFF_SUFF,
- BFD_RELOC_NDS32_PLT_GOT_SUFF,
- BFD_RELOC_NDS32_MULCALL_SUFF,
- BFD_RELOC_NDS32_PTR,
- BFD_RELOC_NDS32_PTR_COUNT,
- BFD_RELOC_NDS32_PTR_RESOLVED,
- BFD_RELOC_NDS32_PLTBLOCK,
- BFD_RELOC_NDS32_RELAX_REGION_BEGIN,
- BFD_RELOC_NDS32_RELAX_REGION_END,
- BFD_RELOC_NDS32_MINUEND,
- BFD_RELOC_NDS32_SUBTRAHEND,
- BFD_RELOC_NDS32_DIFF8,
- BFD_RELOC_NDS32_DIFF16,
- BFD_RELOC_NDS32_DIFF32,
- BFD_RELOC_NDS32_DIFF_ULEB128,
- BFD_RELOC_NDS32_EMPTY,
-
- /* This is a 25 bit absolute address. */
- BFD_RELOC_NDS32_25_ABS,
-
- /* For ex9 and ifc using. */
- BFD_RELOC_NDS32_DATA,
- BFD_RELOC_NDS32_TRAN,
- BFD_RELOC_NDS32_17IFC_PCREL,
- BFD_RELOC_NDS32_10IFCU_PCREL,
-
- /* For TLS. */
- BFD_RELOC_NDS32_TPOFF,
- BFD_RELOC_NDS32_GOTTPOFF,
- BFD_RELOC_NDS32_TLS_LE_HI20,
- BFD_RELOC_NDS32_TLS_LE_LO12,
- BFD_RELOC_NDS32_TLS_LE_20,
- BFD_RELOC_NDS32_TLS_LE_15S0,
- BFD_RELOC_NDS32_TLS_LE_15S1,
- BFD_RELOC_NDS32_TLS_LE_15S2,
- BFD_RELOC_NDS32_TLS_LE_ADD,
- BFD_RELOC_NDS32_TLS_LE_LS,
- BFD_RELOC_NDS32_TLS_IE_HI20,
- BFD_RELOC_NDS32_TLS_IE_LO12,
- BFD_RELOC_NDS32_TLS_IE_LO12S2,
- BFD_RELOC_NDS32_TLS_IEGP_HI20,
- BFD_RELOC_NDS32_TLS_IEGP_LO12,
- BFD_RELOC_NDS32_TLS_IEGP_LO12S2,
- BFD_RELOC_NDS32_TLS_IEGP_LW,
- BFD_RELOC_NDS32_TLS_DESC,
- BFD_RELOC_NDS32_TLS_DESC_HI20,
- BFD_RELOC_NDS32_TLS_DESC_LO12,
- BFD_RELOC_NDS32_TLS_DESC_20,
- BFD_RELOC_NDS32_TLS_DESC_SDA17S2,
- BFD_RELOC_NDS32_TLS_DESC_ADD,
- BFD_RELOC_NDS32_TLS_DESC_FUNC,
- BFD_RELOC_NDS32_TLS_DESC_CALL,
- BFD_RELOC_NDS32_TLS_DESC_MEM,
- BFD_RELOC_NDS32_REMOVE,
- BFD_RELOC_NDS32_GROUP,
-
- /* For floating load store relaxation. */
- BFD_RELOC_NDS32_LSI,
-
- /* This is a 9-bit reloc. */
- BFD_RELOC_V850_9_PCREL,
-
- /* This is a 22-bit reloc. */
- BFD_RELOC_V850_22_PCREL,
-
- /* This is a 16 bit offset from the short data area pointer. */
- BFD_RELOC_V850_SDA_16_16_OFFSET,
-
- /* This is a 16 bit offset (of which only 15 bits are used) from the
- short data area pointer. */
- BFD_RELOC_V850_SDA_15_16_OFFSET,
-
- /* This is a 16 bit offset from the zero data area pointer. */
- BFD_RELOC_V850_ZDA_16_16_OFFSET,
-
- /* This is a 16 bit offset (of which only 15 bits are used) from the
- zero data area pointer. */
- BFD_RELOC_V850_ZDA_15_16_OFFSET,
-
- /* This is an 8 bit offset (of which only 6 bits are used) from the
- tiny data area pointer. */
- BFD_RELOC_V850_TDA_6_8_OFFSET,
-
- /* This is an 8bit offset (of which only 7 bits are used) from the tiny
- data area pointer. */
- BFD_RELOC_V850_TDA_7_8_OFFSET,
-
- /* This is a 7 bit offset from the tiny data area pointer. */
- BFD_RELOC_V850_TDA_7_7_OFFSET,
-
- /* This is a 16 bit offset from the tiny data area pointer. */
- BFD_RELOC_V850_TDA_16_16_OFFSET,
-
- /* This is a 5 bit offset (of which only 4 bits are used) from the tiny
- data area pointer. */
- BFD_RELOC_V850_TDA_4_5_OFFSET,
-
- /* This is a 4 bit offset from the tiny data area pointer. */
- BFD_RELOC_V850_TDA_4_4_OFFSET,
-
- /* This is a 16 bit offset from the short data area pointer, with the
- bits placed non-contiguously in the instruction. */
- BFD_RELOC_V850_SDA_16_16_SPLIT_OFFSET,
-
- /* This is a 16 bit offset from the zero data area pointer, with the
- bits placed non-contiguously in the instruction. */
- BFD_RELOC_V850_ZDA_16_16_SPLIT_OFFSET,
-
- /* This is a 6 bit offset from the call table base pointer. */
- BFD_RELOC_V850_CALLT_6_7_OFFSET,
-
- /* This is a 16 bit offset from the call table base pointer. */
- BFD_RELOC_V850_CALLT_16_16_OFFSET,
-
- /* Used for relaxing indirect function calls. */
- BFD_RELOC_V850_LONGCALL,
-
- /* Used for relaxing indirect jumps. */
- BFD_RELOC_V850_LONGJUMP,
-
- /* Used to maintain alignment whilst relaxing. */
- BFD_RELOC_V850_ALIGN,
-
- /* This is a variation of BFD_RELOC_LO16 that can be used in v850e
- ld.bu instructions. */
- BFD_RELOC_V850_LO16_SPLIT_OFFSET,
-
- /* This is a 16-bit reloc. */
- BFD_RELOC_V850_16_PCREL,
-
- /* This is a 17-bit reloc. */
- BFD_RELOC_V850_17_PCREL,
-
- /* This is a 23-bit reloc. */
- BFD_RELOC_V850_23,
-
- /* This is a 32-bit reloc. */
- BFD_RELOC_V850_32_PCREL,
-
- /* This is a 32-bit reloc. */
- BFD_RELOC_V850_32_ABS,
-
- /* This is a 16-bit reloc. */
- BFD_RELOC_V850_16_SPLIT_OFFSET,
-
- /* This is a 16-bit reloc. */
- BFD_RELOC_V850_16_S1,
-
- /* Low 16 bits. 16 bit shifted by 1. */
- BFD_RELOC_V850_LO16_S1,
-
- /* This is a 16 bit offset from the call table base pointer. */
- BFD_RELOC_V850_CALLT_15_16_OFFSET,
-
- /* DSO relocations. */
- BFD_RELOC_V850_32_GOTPCREL,
- BFD_RELOC_V850_16_GOT,
- BFD_RELOC_V850_32_GOT,
- BFD_RELOC_V850_22_PLT_PCREL,
- BFD_RELOC_V850_32_PLT_PCREL,
- BFD_RELOC_V850_COPY,
- BFD_RELOC_V850_GLOB_DAT,
- BFD_RELOC_V850_JMP_SLOT,
- BFD_RELOC_V850_RELATIVE,
- BFD_RELOC_V850_16_GOTOFF,
- BFD_RELOC_V850_32_GOTOFF,
-
- /* Start code. */
- BFD_RELOC_V850_CODE,
-
- /* Start data in text. */
- BFD_RELOC_V850_DATA,
-
- /* This is a 8bit DP reloc for the tms320c30, where the most
- significant 8 bits of a 24 bit word are placed into the least
- significant 8 bits of the opcode. */
- BFD_RELOC_TIC30_LDP,
-
- /* This is a 7bit reloc for the tms320c54x, where the least
- significant 7 bits of a 16 bit word are placed into the least
- significant 7 bits of the opcode. */
- BFD_RELOC_TIC54X_PARTLS7,
-
- /* This is a 9bit DP reloc for the tms320c54x, where the most
- significant 9 bits of a 16 bit word are placed into the least
- significant 9 bits of the opcode. */
- BFD_RELOC_TIC54X_PARTMS9,
-
- /* This is an extended address 23-bit reloc for the tms320c54x. */
- BFD_RELOC_TIC54X_23,
-
- /* This is a 16-bit reloc for the tms320c54x, where the least
- significant 16 bits of a 23-bit extended address are placed into
- the opcode. */
- BFD_RELOC_TIC54X_16_OF_23,
-
- /* This is a reloc for the tms320c54x, where the most
- significant 7 bits of a 23-bit extended address are placed into
- the opcode. */
- BFD_RELOC_TIC54X_MS7_OF_23,
-
- /* TMS320C6000 relocations. */
- BFD_RELOC_C6000_PCR_S21,
- BFD_RELOC_C6000_PCR_S12,
- BFD_RELOC_C6000_PCR_S10,
- BFD_RELOC_C6000_PCR_S7,
- BFD_RELOC_C6000_ABS_S16,
- BFD_RELOC_C6000_ABS_L16,
- BFD_RELOC_C6000_ABS_H16,
- BFD_RELOC_C6000_SBR_U15_B,
- BFD_RELOC_C6000_SBR_U15_H,
- BFD_RELOC_C6000_SBR_U15_W,
- BFD_RELOC_C6000_SBR_S16,
- BFD_RELOC_C6000_SBR_L16_B,
- BFD_RELOC_C6000_SBR_L16_H,
- BFD_RELOC_C6000_SBR_L16_W,
- BFD_RELOC_C6000_SBR_H16_B,
- BFD_RELOC_C6000_SBR_H16_H,
- BFD_RELOC_C6000_SBR_H16_W,
- BFD_RELOC_C6000_SBR_GOT_U15_W,
- BFD_RELOC_C6000_SBR_GOT_L16_W,
- BFD_RELOC_C6000_SBR_GOT_H16_W,
- BFD_RELOC_C6000_DSBT_INDEX,
- BFD_RELOC_C6000_PREL31,
- BFD_RELOC_C6000_COPY,
- BFD_RELOC_C6000_JUMP_SLOT,
- BFD_RELOC_C6000_EHTYPE,
- BFD_RELOC_C6000_PCR_H16,
- BFD_RELOC_C6000_PCR_L16,
- BFD_RELOC_C6000_ALIGN,
- BFD_RELOC_C6000_FPHEAD,
- BFD_RELOC_C6000_NOCMP,
-
- /* This is a 48 bit reloc for the FR30 that stores 32 bits. */
- BFD_RELOC_FR30_48,
-
- /* This is a 32 bit reloc for the FR30 that stores 20 bits split up
- into two sections. */
- BFD_RELOC_FR30_20,
-
- /* This is a 16 bit reloc for the FR30 that stores a 6 bit word offset
- in 4 bits. */
- BFD_RELOC_FR30_6_IN_4,
-
- /* This is a 16 bit reloc for the FR30 that stores an 8 bit byte offset
- into 8 bits. */
- BFD_RELOC_FR30_8_IN_8,
-
- /* This is a 16 bit reloc for the FR30 that stores a 9 bit short offset
- into 8 bits. */
- BFD_RELOC_FR30_9_IN_8,
-
- /* This is a 16 bit reloc for the FR30 that stores a 10 bit word offset
- into 8 bits. */
- BFD_RELOC_FR30_10_IN_8,
-
- /* This is a 16 bit reloc for the FR30 that stores a 9 bit pc relative
- short offset into 8 bits. */
- BFD_RELOC_FR30_9_PCREL,
-
- /* This is a 16 bit reloc for the FR30 that stores a 12 bit pc relative
- short offset into 11 bits. */
- BFD_RELOC_FR30_12_PCREL,
-
- /* Motorola Mcore relocations. */
- BFD_RELOC_MCORE_PCREL_IMM8BY4,
- BFD_RELOC_MCORE_PCREL_IMM11BY2,
- BFD_RELOC_MCORE_PCREL_IMM4BY2,
- BFD_RELOC_MCORE_PCREL_32,
- BFD_RELOC_MCORE_PCREL_JSR_IMM11BY2,
- BFD_RELOC_MCORE_RVA,
-
- /* Toshiba Media Processor Relocations. */
- BFD_RELOC_MEP_8,
- BFD_RELOC_MEP_16,
- BFD_RELOC_MEP_32,
- BFD_RELOC_MEP_PCREL8A2,
- BFD_RELOC_MEP_PCREL12A2,
- BFD_RELOC_MEP_PCREL17A2,
- BFD_RELOC_MEP_PCREL24A2,
- BFD_RELOC_MEP_PCABS24A2,
- BFD_RELOC_MEP_LOW16,
- BFD_RELOC_MEP_HI16U,
- BFD_RELOC_MEP_HI16S,
- BFD_RELOC_MEP_GPREL,
- BFD_RELOC_MEP_TPREL,
- BFD_RELOC_MEP_TPREL7,
- BFD_RELOC_MEP_TPREL7A2,
- BFD_RELOC_MEP_TPREL7A4,
- BFD_RELOC_MEP_UIMM24,
- BFD_RELOC_MEP_ADDR24A4,
- BFD_RELOC_MEP_GNU_VTINHERIT,
- BFD_RELOC_MEP_GNU_VTENTRY,
-
- /* Imagination Technologies Meta relocations. */
- BFD_RELOC_METAG_HIADDR16,
- BFD_RELOC_METAG_LOADDR16,
- BFD_RELOC_METAG_RELBRANCH,
- BFD_RELOC_METAG_GETSETOFF,
- BFD_RELOC_METAG_HIOG,
- BFD_RELOC_METAG_LOOG,
- BFD_RELOC_METAG_REL8,
- BFD_RELOC_METAG_REL16,
- BFD_RELOC_METAG_HI16_GOTOFF,
- BFD_RELOC_METAG_LO16_GOTOFF,
- BFD_RELOC_METAG_GETSET_GOTOFF,
- BFD_RELOC_METAG_GETSET_GOT,
- BFD_RELOC_METAG_HI16_GOTPC,
- BFD_RELOC_METAG_LO16_GOTPC,
- BFD_RELOC_METAG_HI16_PLT,
- BFD_RELOC_METAG_LO16_PLT,
- BFD_RELOC_METAG_RELBRANCH_PLT,
- BFD_RELOC_METAG_GOTOFF,
- BFD_RELOC_METAG_PLT,
- BFD_RELOC_METAG_COPY,
- BFD_RELOC_METAG_JMP_SLOT,
- BFD_RELOC_METAG_RELATIVE,
- BFD_RELOC_METAG_GLOB_DAT,
- BFD_RELOC_METAG_TLS_GD,
- BFD_RELOC_METAG_TLS_LDM,
- BFD_RELOC_METAG_TLS_LDO_HI16,
- BFD_RELOC_METAG_TLS_LDO_LO16,
- BFD_RELOC_METAG_TLS_LDO,
- BFD_RELOC_METAG_TLS_IE,
- BFD_RELOC_METAG_TLS_IENONPIC,
- BFD_RELOC_METAG_TLS_IENONPIC_HI16,
- BFD_RELOC_METAG_TLS_IENONPIC_LO16,
- BFD_RELOC_METAG_TLS_TPOFF,
- BFD_RELOC_METAG_TLS_DTPMOD,
- BFD_RELOC_METAG_TLS_DTPOFF,
- BFD_RELOC_METAG_TLS_LE,
- BFD_RELOC_METAG_TLS_LE_HI16,
- BFD_RELOC_METAG_TLS_LE_LO16,
-
- /* These are relocations for the GETA instruction. */
- BFD_RELOC_MMIX_GETA,
- BFD_RELOC_MMIX_GETA_1,
- BFD_RELOC_MMIX_GETA_2,
- BFD_RELOC_MMIX_GETA_3,
-
- /* These are relocations for a conditional branch instruction. */
- BFD_RELOC_MMIX_CBRANCH,
- BFD_RELOC_MMIX_CBRANCH_J,
- BFD_RELOC_MMIX_CBRANCH_1,
- BFD_RELOC_MMIX_CBRANCH_2,
- BFD_RELOC_MMIX_CBRANCH_3,
-
- /* These are relocations for the PUSHJ instruction. */
- BFD_RELOC_MMIX_PUSHJ,
- BFD_RELOC_MMIX_PUSHJ_1,
- BFD_RELOC_MMIX_PUSHJ_2,
- BFD_RELOC_MMIX_PUSHJ_3,
- BFD_RELOC_MMIX_PUSHJ_STUBBABLE,
-
- /* These are relocations for the JMP instruction. */
- BFD_RELOC_MMIX_JMP,
- BFD_RELOC_MMIX_JMP_1,
- BFD_RELOC_MMIX_JMP_2,
- BFD_RELOC_MMIX_JMP_3,
-
- /* This is a relocation for a relative address as in a GETA instruction
- or a branch. */
- BFD_RELOC_MMIX_ADDR19,
-
- /* This is a relocation for a relative address as in a JMP instruction. */
- BFD_RELOC_MMIX_ADDR27,
-
- /* This is a relocation for an instruction field that may be a general
- register or a value 0..255. */
- BFD_RELOC_MMIX_REG_OR_BYTE,
-
- /* This is a relocation for an instruction field that may be a general
- register. */
- BFD_RELOC_MMIX_REG,
-
- /* This is a relocation for two instruction fields holding a register
- and an offset, the equivalent of the relocation. */
- BFD_RELOC_MMIX_BASE_PLUS_OFFSET,
-
- /* This relocation is an assertion that the expression is not allocated
- as a global register. It does not modify contents. */
- BFD_RELOC_MMIX_LOCAL,
-
- /* This is a 16 bit reloc for the AVR that stores 8 bit pc relative
- short offset into 7 bits. */
- BFD_RELOC_AVR_7_PCREL,
-
- /* This is a 16 bit reloc for the AVR that stores 13 bit pc relative
- short offset into 12 bits. */
- BFD_RELOC_AVR_13_PCREL,
-
- /* This is a 16 bit reloc for the AVR that stores 17 bit value (usually
- program memory address) into 16 bits. */
- BFD_RELOC_AVR_16_PM,
-
- /* This is a 16 bit reloc for the AVR that stores 8 bit value (usually
- data memory address) into 8 bit immediate value of LDI insn. */
- BFD_RELOC_AVR_LO8_LDI,
-
- /* This is a 16 bit reloc for the AVR that stores 8 bit value (high 8 bit
- of data memory address) into 8 bit immediate value of LDI insn. */
- BFD_RELOC_AVR_HI8_LDI,
-
- /* This is a 16 bit reloc for the AVR that stores 8 bit value (most
- high 8 bit of program memory address) into 8 bit immediate value of
- LDI insn. */
- BFD_RELOC_AVR_HH8_LDI,
-
- /* This is a 16 bit reloc for the AVR that stores 8 bit value (most
- high 8 bit of 32 bit value) into 8 bit immediate value of LDI insn. */
- BFD_RELOC_AVR_MS8_LDI,
-
- /* This is a 16 bit reloc for the AVR that stores negated 8 bit value
- (usually data memory address) into 8 bit immediate value of SUBI insn. */
- BFD_RELOC_AVR_LO8_LDI_NEG,
-
- /* This is a 16 bit reloc for the AVR that stores negated 8 bit value
- (high 8 bit of data memory address) into 8 bit immediate value of
- SUBI insn. */
- BFD_RELOC_AVR_HI8_LDI_NEG,
-
- /* This is a 16 bit reloc for the AVR that stores negated 8 bit value
- (most high 8 bit of program memory address) into 8 bit immediate
- value of LDI or SUBI insn. */
- BFD_RELOC_AVR_HH8_LDI_NEG,
-
- /* This is a 16 bit reloc for the AVR that stores negated 8 bit value
- (msb of 32 bit value) into 8 bit immediate value of LDI insn. */
- BFD_RELOC_AVR_MS8_LDI_NEG,
-
- /* This is a 16 bit reloc for the AVR that stores 8 bit value (usually
- command address) into 8 bit immediate value of LDI insn. */
- BFD_RELOC_AVR_LO8_LDI_PM,
-
- /* This is a 16 bit reloc for the AVR that stores 8 bit value
- (command address) into 8 bit immediate value of LDI insn. If the
- address is beyond the 128k boundary, the linker inserts a jump stub
- for this reloc in the lower 128k. */
- BFD_RELOC_AVR_LO8_LDI_GS,
-
- /* This is a 16 bit reloc for the AVR that stores 8 bit value (high 8 bit
- of command address) into 8 bit immediate value of LDI insn. */
- BFD_RELOC_AVR_HI8_LDI_PM,
-
- /* This is a 16 bit reloc for the AVR that stores 8 bit value (high 8 bit
- of command address) into 8 bit immediate value of LDI insn. If the
- address is beyond the 128k boundary, the linker inserts a jump stub
- for this reloc below 128k. */
- BFD_RELOC_AVR_HI8_LDI_GS,
-
- /* This is a 16 bit reloc for the AVR that stores 8 bit value (most
- high 8 bit of command address) into 8 bit immediate value of LDI
- insn. */
- BFD_RELOC_AVR_HH8_LDI_PM,
-
- /* This is a 16 bit reloc for the AVR that stores negated 8 bit value
- (usually command address) into 8 bit immediate value of SUBI insn. */
- BFD_RELOC_AVR_LO8_LDI_PM_NEG,
-
- /* This is a 16 bit reloc for the AVR that stores negated 8 bit value
- (high 8 bit of 16 bit command address) into 8 bit immediate value
- of SUBI insn. */
- BFD_RELOC_AVR_HI8_LDI_PM_NEG,
-
- /* This is a 16 bit reloc for the AVR that stores negated 8 bit value
- (high 6 bit of 22 bit command address) into 8 bit immediate
- value of SUBI insn. */
- BFD_RELOC_AVR_HH8_LDI_PM_NEG,
-
- /* This is a 32 bit reloc for the AVR that stores 23 bit value
- into 22 bits. */
- BFD_RELOC_AVR_CALL,
-
- /* This is a 16 bit reloc for the AVR that stores all needed bits
- for absolute addressing with ldi with overflow check to linktime. */
- BFD_RELOC_AVR_LDI,
-
- /* This is a 6 bit reloc for the AVR that stores offset for ldd/std
- instructions. */
- BFD_RELOC_AVR_6,
-
- /* This is a 6 bit reloc for the AVR that stores offset for adiw/sbiw
- instructions. */
- BFD_RELOC_AVR_6_ADIW,
-
- /* This is a 8 bit reloc for the AVR that stores bits 0..7 of a symbol
- in .byte lo8(symbol). */
- BFD_RELOC_AVR_8_LO,
-
- /* This is a 8 bit reloc for the AVR that stores bits 8..15 of a symbol
- in .byte hi8(symbol). */
- BFD_RELOC_AVR_8_HI,
-
- /* This is a 8 bit reloc for the AVR that stores bits 16..23 of a symbol
- in .byte hlo8(symbol). */
- BFD_RELOC_AVR_8_HLO,
-
- /* AVR relocations to mark the difference of two local symbols.
- These are only needed to support linker relaxation and can be ignored
- when not relaxing. The field is set to the value of the difference
- assuming no relaxation. The relocation encodes the position of the
- second symbol so the linker can determine whether to adjust the field
- value. */
- BFD_RELOC_AVR_DIFF8,
- BFD_RELOC_AVR_DIFF16,
- BFD_RELOC_AVR_DIFF32,
-
- /* This is a 7 bit reloc for the AVR that stores SRAM address for 16bit
- lds and sts instructions supported only tiny core. */
- BFD_RELOC_AVR_LDS_STS_16,
-
- /* This is a 6 bit reloc for the AVR that stores an I/O register
- number for the IN and OUT instructions. */
- BFD_RELOC_AVR_PORT6,
-
- /* This is a 5 bit reloc for the AVR that stores an I/O register
- number for the SBIC, SBIS, SBI and CBI instructions. */
- BFD_RELOC_AVR_PORT5,
-
- /* RISC-V relocations. */
- BFD_RELOC_RISCV_HI20,
- BFD_RELOC_RISCV_PCREL_HI20,
- BFD_RELOC_RISCV_PCREL_LO12_I,
- BFD_RELOC_RISCV_PCREL_LO12_S,
- BFD_RELOC_RISCV_LO12_I,
- BFD_RELOC_RISCV_LO12_S,
- BFD_RELOC_RISCV_GPREL12_I,
- BFD_RELOC_RISCV_GPREL12_S,
- BFD_RELOC_RISCV_TPREL_HI20,
- BFD_RELOC_RISCV_TPREL_LO12_I,
- BFD_RELOC_RISCV_TPREL_LO12_S,
- BFD_RELOC_RISCV_TPREL_ADD,
- BFD_RELOC_RISCV_CALL,
- BFD_RELOC_RISCV_CALL_PLT,
- BFD_RELOC_RISCV_ADD8,
- BFD_RELOC_RISCV_ADD16,
- BFD_RELOC_RISCV_ADD32,
- BFD_RELOC_RISCV_ADD64,
- BFD_RELOC_RISCV_SUB8,
- BFD_RELOC_RISCV_SUB16,
- BFD_RELOC_RISCV_SUB32,
- BFD_RELOC_RISCV_SUB64,
- BFD_RELOC_RISCV_GOT_HI20,
- BFD_RELOC_RISCV_TLS_GOT_HI20,
- BFD_RELOC_RISCV_TLS_GD_HI20,
- BFD_RELOC_RISCV_JMP,
- BFD_RELOC_RISCV_TLS_DTPMOD32,
- BFD_RELOC_RISCV_TLS_DTPREL32,
- BFD_RELOC_RISCV_TLS_DTPMOD64,
- BFD_RELOC_RISCV_TLS_DTPREL64,
- BFD_RELOC_RISCV_TLS_TPREL32,
- BFD_RELOC_RISCV_TLS_TPREL64,
- BFD_RELOC_RISCV_TLSDESC_HI20,
- BFD_RELOC_RISCV_TLSDESC_LOAD_LO12,
- BFD_RELOC_RISCV_TLSDESC_ADD_LO12,
- BFD_RELOC_RISCV_TLSDESC_CALL,
- BFD_RELOC_RISCV_ALIGN,
- BFD_RELOC_RISCV_RVC_BRANCH,
- BFD_RELOC_RISCV_RVC_JUMP,
- BFD_RELOC_RISCV_RELAX,
- BFD_RELOC_RISCV_CFA,
- BFD_RELOC_RISCV_SUB6,
- BFD_RELOC_RISCV_SET6,
- BFD_RELOC_RISCV_SET8,
- BFD_RELOC_RISCV_SET16,
- BFD_RELOC_RISCV_SET32,
- BFD_RELOC_RISCV_32_PCREL,
- BFD_RELOC_RISCV_SET_ULEB128,
- BFD_RELOC_RISCV_SUB_ULEB128,
-
- /* Renesas RL78 Relocations. */
- BFD_RELOC_RL78_NEG8,
- BFD_RELOC_RL78_NEG16,
- BFD_RELOC_RL78_NEG24,
- BFD_RELOC_RL78_NEG32,
- BFD_RELOC_RL78_16_OP,
- BFD_RELOC_RL78_24_OP,
- BFD_RELOC_RL78_32_OP,
- BFD_RELOC_RL78_8U,
- BFD_RELOC_RL78_16U,
- BFD_RELOC_RL78_24U,
- BFD_RELOC_RL78_DIR3U_PCREL,
- BFD_RELOC_RL78_DIFF,
- BFD_RELOC_RL78_GPRELB,
- BFD_RELOC_RL78_GPRELW,
- BFD_RELOC_RL78_GPRELL,
- BFD_RELOC_RL78_SYM,
- BFD_RELOC_RL78_OP_SUBTRACT,
- BFD_RELOC_RL78_OP_NEG,
- BFD_RELOC_RL78_OP_AND,
- BFD_RELOC_RL78_OP_SHRA,
- BFD_RELOC_RL78_ABS8,
- BFD_RELOC_RL78_ABS16,
- BFD_RELOC_RL78_ABS16_REV,
- BFD_RELOC_RL78_ABS32,
- BFD_RELOC_RL78_ABS32_REV,
- BFD_RELOC_RL78_ABS16U,
- BFD_RELOC_RL78_ABS16UW,
- BFD_RELOC_RL78_ABS16UL,
- BFD_RELOC_RL78_RELAX,
- BFD_RELOC_RL78_HI16,
- BFD_RELOC_RL78_HI8,
- BFD_RELOC_RL78_LO16,
- BFD_RELOC_RL78_CODE,
- BFD_RELOC_RL78_SADDR,
-
- /* Renesas RX Relocations. */
- BFD_RELOC_RX_NEG8,
- BFD_RELOC_RX_NEG16,
- BFD_RELOC_RX_NEG24,
- BFD_RELOC_RX_NEG32,
- BFD_RELOC_RX_16_OP,
- BFD_RELOC_RX_24_OP,
- BFD_RELOC_RX_32_OP,
- BFD_RELOC_RX_8U,
- BFD_RELOC_RX_16U,
- BFD_RELOC_RX_24U,
- BFD_RELOC_RX_DIR3U_PCREL,
- BFD_RELOC_RX_DIFF,
- BFD_RELOC_RX_GPRELB,
- BFD_RELOC_RX_GPRELW,
- BFD_RELOC_RX_GPRELL,
- BFD_RELOC_RX_SYM,
- BFD_RELOC_RX_OP_SUBTRACT,
- BFD_RELOC_RX_OP_NEG,
- BFD_RELOC_RX_ABS8,
- BFD_RELOC_RX_ABS16,
- BFD_RELOC_RX_ABS16_REV,
- BFD_RELOC_RX_ABS32,
- BFD_RELOC_RX_ABS32_REV,
- BFD_RELOC_RX_ABS16U,
- BFD_RELOC_RX_ABS16UW,
- BFD_RELOC_RX_ABS16UL,
- BFD_RELOC_RX_RELAX,
-
- /* Direct 12 bit. */
- BFD_RELOC_390_12,
-
- /* 12 bit GOT offset. */
- BFD_RELOC_390_GOT12,
-
- /* 32 bit PC relative PLT address. */
- BFD_RELOC_390_PLT32,
-
- /* Copy symbol at runtime. */
- BFD_RELOC_390_COPY,
-
- /* Create GOT entry. */
- BFD_RELOC_390_GLOB_DAT,
-
- /* Create PLT entry. */
- BFD_RELOC_390_JMP_SLOT,
-
- /* Adjust by program base. */
- BFD_RELOC_390_RELATIVE,
-
- /* 32 bit PC relative offset to GOT. */
- BFD_RELOC_390_GOTPC,
-
- /* 16 bit GOT offset. */
- BFD_RELOC_390_GOT16,
-
- /* PC relative 12 bit shifted by 1. */
- BFD_RELOC_390_PC12DBL,
-
- /* 12 bit PC rel. PLT shifted by 1. */
- BFD_RELOC_390_PLT12DBL,
-
- /* PC relative 16 bit shifted by 1. */
- BFD_RELOC_390_PC16DBL,
-
- /* 16 bit PC rel. PLT shifted by 1. */
- BFD_RELOC_390_PLT16DBL,
-
- /* PC relative 24 bit shifted by 1. */
- BFD_RELOC_390_PC24DBL,
-
- /* 24 bit PC rel. PLT shifted by 1. */
- BFD_RELOC_390_PLT24DBL,
-
- /* PC relative 32 bit shifted by 1. */
- BFD_RELOC_390_PC32DBL,
-
- /* 32 bit PC rel. PLT shifted by 1. */
- BFD_RELOC_390_PLT32DBL,
-
- /* 32 bit PC rel. GOT shifted by 1. */
- BFD_RELOC_390_GOTPCDBL,
-
- /* 64 bit GOT offset. */
- BFD_RELOC_390_GOT64,
-
- /* 64 bit PC relative PLT address. */
- BFD_RELOC_390_PLT64,
-
- /* 32 bit rel. offset to GOT entry. */
- BFD_RELOC_390_GOTENT,
-
- /* 64 bit offset to GOT. */
- BFD_RELOC_390_GOTOFF64,
-
- /* 12-bit offset to symbol-entry within GOT, with PLT handling. */
- BFD_RELOC_390_GOTPLT12,
-
- /* 16-bit offset to symbol-entry within GOT, with PLT handling. */
- BFD_RELOC_390_GOTPLT16,
-
- /* 32-bit offset to symbol-entry within GOT, with PLT handling. */
- BFD_RELOC_390_GOTPLT32,
-
- /* 64-bit offset to symbol-entry within GOT, with PLT handling. */
- BFD_RELOC_390_GOTPLT64,
-
- /* 32-bit rel. offset to symbol-entry within GOT, with PLT handling. */
- BFD_RELOC_390_GOTPLTENT,
-
- /* 16-bit rel. offset from the GOT to a PLT entry. */
- BFD_RELOC_390_PLTOFF16,
-
- /* 32-bit rel. offset from the GOT to a PLT entry. */
- BFD_RELOC_390_PLTOFF32,
-
- /* 64-bit rel. offset from the GOT to a PLT entry. */
- BFD_RELOC_390_PLTOFF64,
-
- /* s390 tls relocations. */
- BFD_RELOC_390_TLS_LOAD,
- BFD_RELOC_390_TLS_GDCALL,
- BFD_RELOC_390_TLS_LDCALL,
- BFD_RELOC_390_TLS_GD32,
- BFD_RELOC_390_TLS_GD64,
- BFD_RELOC_390_TLS_GOTIE12,
- BFD_RELOC_390_TLS_GOTIE32,
- BFD_RELOC_390_TLS_GOTIE64,
- BFD_RELOC_390_TLS_LDM32,
- BFD_RELOC_390_TLS_LDM64,
- BFD_RELOC_390_TLS_IE32,
- BFD_RELOC_390_TLS_IE64,
- BFD_RELOC_390_TLS_IEENT,
- BFD_RELOC_390_TLS_LE32,
- BFD_RELOC_390_TLS_LE64,
- BFD_RELOC_390_TLS_LDO32,
- BFD_RELOC_390_TLS_LDO64,
- BFD_RELOC_390_TLS_DTPMOD,
- BFD_RELOC_390_TLS_DTPOFF,
- BFD_RELOC_390_TLS_TPOFF,
-
- /* Long displacement extension. */
- BFD_RELOC_390_20,
- BFD_RELOC_390_GOT20,
- BFD_RELOC_390_GOTPLT20,
- BFD_RELOC_390_TLS_GOTIE20,
-
- /* STT_GNU_IFUNC relocation. */
- BFD_RELOC_390_IRELATIVE,
-
- /* Score relocations.
- Low 16 bit for load/store. */
- BFD_RELOC_SCORE_GPREL15,
-
- /* This is a 24-bit reloc with the right 1 bit assumed to be 0. */
- BFD_RELOC_SCORE_DUMMY2,
- BFD_RELOC_SCORE_JMP,
-
- /* This is a 19-bit reloc with the right 1 bit assumed to be 0. */
- BFD_RELOC_SCORE_BRANCH,
-
- /* This is a 32-bit reloc for 48-bit instructions. */
- BFD_RELOC_SCORE_IMM30,
-
- /* This is a 32-bit reloc for 48-bit instructions. */
- BFD_RELOC_SCORE_IMM32,
-
- /* This is a 11-bit reloc with the right 1 bit assumed to be 0. */
- BFD_RELOC_SCORE16_JMP,
-
- /* This is a 8-bit reloc with the right 1 bit assumed to be 0. */
- BFD_RELOC_SCORE16_BRANCH,
-
- /* This is a 9-bit reloc with the right 1 bit assumed to be 0. */
- BFD_RELOC_SCORE_BCMP,
-
- /* Undocumented Score relocs. */
- BFD_RELOC_SCORE_GOT15,
- BFD_RELOC_SCORE_GOT_LO16,
- BFD_RELOC_SCORE_CALL15,
- BFD_RELOC_SCORE_DUMMY_HI16,
-
- /* Scenix IP2K - 9-bit register number / data address. */
- BFD_RELOC_IP2K_FR9,
-
- /* Scenix IP2K - 4-bit register/data bank number. */
- BFD_RELOC_IP2K_BANK,
-
- /* Scenix IP2K - low 13 bits of instruction word address. */
- BFD_RELOC_IP2K_ADDR16CJP,
-
- /* Scenix IP2K - high 3 bits of instruction word address. */
- BFD_RELOC_IP2K_PAGE3,
-
- /* Scenix IP2K - ext/low/high 8 bits of data address. */
- BFD_RELOC_IP2K_LO8DATA,
- BFD_RELOC_IP2K_HI8DATA,
- BFD_RELOC_IP2K_EX8DATA,
-
- /* Scenix IP2K - low/high 8 bits of instruction word address. */
- BFD_RELOC_IP2K_LO8INSN,
- BFD_RELOC_IP2K_HI8INSN,
-
- /* Scenix IP2K - even/odd PC modifier to modify snb pcl.0. */
- BFD_RELOC_IP2K_PC_SKIP,
-
- /* Scenix IP2K - 16 bit word address in text section. */
- BFD_RELOC_IP2K_TEXT,
-
- /* Scenix IP2K - 7-bit sp or dp offset. */
- BFD_RELOC_IP2K_FR_OFFSET,
-
- /* Scenix VPE4K coprocessor - data/insn-space addressing. */
- BFD_RELOC_VPE4KMATH_DATA,
- BFD_RELOC_VPE4KMATH_INSN,
-
- /* These two relocations are used by the linker to determine which of
- the entries in a C++ virtual function table are actually used. When
- the --gc-sections option is given, the linker will zero out the
- entries that are not used, so that the code for those functions need
- not be included in the output.
-
- VTABLE_INHERIT is a zero-space relocation used to describe to the
- linker the inheritance tree of a C++ virtual function table. The
- relocation's symbol should be the parent class' vtable, and the
- relocation should be located at the child vtable.
-
- VTABLE_ENTRY is a zero-space relocation that describes the use of a
- virtual function table entry. The reloc's symbol should refer to
- the table of the class mentioned in the code. Off of that base, an
- offset describes the entry that is being used. For Rela hosts, this
- offset is stored in the reloc's addend. For Rel hosts, we are
- forced to put this offset in the reloc's section offset. */
- BFD_RELOC_VTABLE_INHERIT,
- BFD_RELOC_VTABLE_ENTRY,
-
- /* Intel IA64 Relocations. */
- BFD_RELOC_IA64_IMM14,
- BFD_RELOC_IA64_IMM22,
- BFD_RELOC_IA64_IMM64,
- BFD_RELOC_IA64_DIR32MSB,
- BFD_RELOC_IA64_DIR32LSB,
- BFD_RELOC_IA64_DIR64MSB,
- BFD_RELOC_IA64_DIR64LSB,
- BFD_RELOC_IA64_GPREL22,
- BFD_RELOC_IA64_GPREL64I,
- BFD_RELOC_IA64_GPREL32MSB,
- BFD_RELOC_IA64_GPREL32LSB,
- BFD_RELOC_IA64_GPREL64MSB,
- BFD_RELOC_IA64_GPREL64LSB,
- BFD_RELOC_IA64_LTOFF22,
- BFD_RELOC_IA64_LTOFF64I,
- BFD_RELOC_IA64_PLTOFF22,
- BFD_RELOC_IA64_PLTOFF64I,
- BFD_RELOC_IA64_PLTOFF64MSB,
- BFD_RELOC_IA64_PLTOFF64LSB,
- BFD_RELOC_IA64_FPTR64I,
- BFD_RELOC_IA64_FPTR32MSB,
- BFD_RELOC_IA64_FPTR32LSB,
- BFD_RELOC_IA64_FPTR64MSB,
- BFD_RELOC_IA64_FPTR64LSB,
- BFD_RELOC_IA64_PCREL21B,
- BFD_RELOC_IA64_PCREL21BI,
- BFD_RELOC_IA64_PCREL21M,
- BFD_RELOC_IA64_PCREL21F,
- BFD_RELOC_IA64_PCREL22,
- BFD_RELOC_IA64_PCREL60B,
- BFD_RELOC_IA64_PCREL64I,
- BFD_RELOC_IA64_PCREL32MSB,
- BFD_RELOC_IA64_PCREL32LSB,
- BFD_RELOC_IA64_PCREL64MSB,
- BFD_RELOC_IA64_PCREL64LSB,
- BFD_RELOC_IA64_LTOFF_FPTR22,
- BFD_RELOC_IA64_LTOFF_FPTR64I,
- BFD_RELOC_IA64_LTOFF_FPTR32MSB,
- BFD_RELOC_IA64_LTOFF_FPTR32LSB,
- BFD_RELOC_IA64_LTOFF_FPTR64MSB,
- BFD_RELOC_IA64_LTOFF_FPTR64LSB,
- BFD_RELOC_IA64_SEGREL32MSB,
- BFD_RELOC_IA64_SEGREL32LSB,
- BFD_RELOC_IA64_SEGREL64MSB,
- BFD_RELOC_IA64_SEGREL64LSB,
- BFD_RELOC_IA64_SECREL32MSB,
- BFD_RELOC_IA64_SECREL32LSB,
- BFD_RELOC_IA64_SECREL64MSB,
- BFD_RELOC_IA64_SECREL64LSB,
- BFD_RELOC_IA64_REL32MSB,
- BFD_RELOC_IA64_REL32LSB,
- BFD_RELOC_IA64_REL64MSB,
- BFD_RELOC_IA64_REL64LSB,
- BFD_RELOC_IA64_LTV32MSB,
- BFD_RELOC_IA64_LTV32LSB,
- BFD_RELOC_IA64_LTV64MSB,
- BFD_RELOC_IA64_LTV64LSB,
- BFD_RELOC_IA64_IPLTMSB,
- BFD_RELOC_IA64_IPLTLSB,
- BFD_RELOC_IA64_COPY,
- BFD_RELOC_IA64_LTOFF22X,
- BFD_RELOC_IA64_LDXMOV,
- BFD_RELOC_IA64_TPREL14,
- BFD_RELOC_IA64_TPREL22,
- BFD_RELOC_IA64_TPREL64I,
- BFD_RELOC_IA64_TPREL64MSB,
- BFD_RELOC_IA64_TPREL64LSB,
- BFD_RELOC_IA64_LTOFF_TPREL22,
- BFD_RELOC_IA64_DTPMOD64MSB,
- BFD_RELOC_IA64_DTPMOD64LSB,
- BFD_RELOC_IA64_LTOFF_DTPMOD22,
- BFD_RELOC_IA64_DTPREL14,
- BFD_RELOC_IA64_DTPREL22,
- BFD_RELOC_IA64_DTPREL64I,
- BFD_RELOC_IA64_DTPREL32MSB,
- BFD_RELOC_IA64_DTPREL32LSB,
- BFD_RELOC_IA64_DTPREL64MSB,
- BFD_RELOC_IA64_DTPREL64LSB,
- BFD_RELOC_IA64_LTOFF_DTPREL22,
-
- /* Motorola 68HC11 reloc.
- This is the 8 bit high part of an absolute address. */
- BFD_RELOC_M68HC11_HI8,
-
- /* Motorola 68HC11 reloc.
- This is the 8 bit low part of an absolute address. */
- BFD_RELOC_M68HC11_LO8,
-
- /* Motorola 68HC11 reloc.
- This is the 3 bit of a value. */
- BFD_RELOC_M68HC11_3B,
-
- /* Motorola 68HC11 reloc.
- This reloc marks the beginning of a jump/call instruction.
- It is used for linker relaxation to correctly identify beginning
- of instruction and change some branches to use PC-relative
- addressing mode. */
- BFD_RELOC_M68HC11_RL_JUMP,
-
- /* Motorola 68HC11 reloc.
- This reloc marks a group of several instructions that gcc generates
- and for which the linker relaxation pass can modify and/or remove
- some of them. */
- BFD_RELOC_M68HC11_RL_GROUP,
-
- /* Motorola 68HC11 reloc.
- This is the 16-bit lower part of an address. It is used for 'call'
- instruction to specify the symbol address without any special
- transformation (due to memory bank window). */
- BFD_RELOC_M68HC11_LO16,
-
- /* Motorola 68HC11 reloc.
- This is a 8-bit reloc that specifies the page number of an address.
- It is used by 'call' instruction to specify the page number of
- the symbol. */
- BFD_RELOC_M68HC11_PAGE,
-
- /* Motorola 68HC11 reloc.
- This is a 24-bit reloc that represents the address with a 16-bit
- value and a 8-bit page number. The symbol address is transformed
- to follow the 16K memory bank of 68HC12 (seen as mapped in the
- window). */
- BFD_RELOC_M68HC11_24,
-
- /* Motorola 68HC12 reloc.
- This is the 5 bits of a value. */
- BFD_RELOC_M68HC12_5B,
-
- /* Freescale XGATE reloc.
- This reloc marks the beginning of a bra/jal instruction. */
- BFD_RELOC_XGATE_RL_JUMP,
-
- /* Freescale XGATE reloc.
- This reloc marks a group of several instructions that gcc generates
- and for which the linker relaxation pass can modify and/or remove
- some of them. */
- BFD_RELOC_XGATE_RL_GROUP,
-
- /* Freescale XGATE reloc.
- This is the 16-bit lower part of an address. It is used for the
- '16-bit' instructions. */
- BFD_RELOC_XGATE_LO16,
-
- /* Freescale XGATE reloc. */
- BFD_RELOC_XGATE_GPAGE,
-
- /* Freescale XGATE reloc. */
- BFD_RELOC_XGATE_24,
-
- /* Freescale XGATE reloc.
- This is a 9-bit pc-relative reloc. */
- BFD_RELOC_XGATE_PCREL_9,
-
- /* Freescale XGATE reloc.
- This is a 10-bit pc-relative reloc. */
- BFD_RELOC_XGATE_PCREL_10,
-
- /* Freescale XGATE reloc.
- This is the 16-bit lower part of an address. It is used for the
- '16-bit' instructions. */
- BFD_RELOC_XGATE_IMM8_LO,
-
- /* Freescale XGATE reloc.
- This is the 16-bit higher part of an address. It is used for the
- '16-bit' instructions. */
- BFD_RELOC_XGATE_IMM8_HI,
-
- /* Freescale XGATE reloc.
- This is a 3-bit pc-relative reloc. */
- BFD_RELOC_XGATE_IMM3,
-
- /* Freescale XGATE reloc.
- This is a 4-bit pc-relative reloc. */
- BFD_RELOC_XGATE_IMM4,
-
- /* Freescale XGATE reloc.
- This is a 5-bit pc-relative reloc. */
- BFD_RELOC_XGATE_IMM5,
-
- /* Motorola 68HC12 reloc.
- This is the 9 bits of a value. */
- BFD_RELOC_M68HC12_9B,
-
- /* Motorola 68HC12 reloc.
- This is the 16 bits of a value. */
- BFD_RELOC_M68HC12_16B,
-
- /* Motorola 68HC12/XGATE reloc.
- This is a PCREL9 branch. */
- BFD_RELOC_M68HC12_9_PCREL,
-
- /* Motorola 68HC12/XGATE reloc.
- This is a PCREL10 branch. */
- BFD_RELOC_M68HC12_10_PCREL,
-
- /* Motorola 68HC12/XGATE reloc.
- This is the 8 bit low part of an absolute address and immediately
- precedes a matching HI8XG part. */
- BFD_RELOC_M68HC12_LO8XG,
-
- /* Motorola 68HC12/XGATE reloc.
- This is the 8 bit high part of an absolute address and immediately
- follows a matching LO8XG part. */
- BFD_RELOC_M68HC12_HI8XG,
-
- /* Freescale S12Z reloc.
- This is a 15 bit relative address. If the most significant bits are
- all zero then it may be truncated to 8 bits. */
- BFD_RELOC_S12Z_15_PCREL,
-
- /* NS CR16 Relocations. */
- BFD_RELOC_CR16_NUM8,
- BFD_RELOC_CR16_NUM16,
- BFD_RELOC_CR16_NUM32,
- BFD_RELOC_CR16_NUM32a,
- BFD_RELOC_CR16_REGREL0,
- BFD_RELOC_CR16_REGREL4,
- BFD_RELOC_CR16_REGREL4a,
- BFD_RELOC_CR16_REGREL14,
- BFD_RELOC_CR16_REGREL14a,
- BFD_RELOC_CR16_REGREL16,
- BFD_RELOC_CR16_REGREL20,
- BFD_RELOC_CR16_REGREL20a,
- BFD_RELOC_CR16_ABS20,
- BFD_RELOC_CR16_ABS24,
- BFD_RELOC_CR16_IMM4,
- BFD_RELOC_CR16_IMM8,
- BFD_RELOC_CR16_IMM16,
- BFD_RELOC_CR16_IMM20,
- BFD_RELOC_CR16_IMM24,
- BFD_RELOC_CR16_IMM32,
- BFD_RELOC_CR16_IMM32a,
- BFD_RELOC_CR16_DISP4,
- BFD_RELOC_CR16_DISP8,
- BFD_RELOC_CR16_DISP16,
- BFD_RELOC_CR16_DISP20,
- BFD_RELOC_CR16_DISP24,
- BFD_RELOC_CR16_DISP24a,
- BFD_RELOC_CR16_SWITCH8,
- BFD_RELOC_CR16_SWITCH16,
- BFD_RELOC_CR16_SWITCH32,
- BFD_RELOC_CR16_GOT_REGREL20,
- BFD_RELOC_CR16_GOTC_REGREL20,
- BFD_RELOC_CR16_GLOB_DAT,
-
- /* NS CRX Relocations. */
- BFD_RELOC_CRX_REL4,
- BFD_RELOC_CRX_REL8,
- BFD_RELOC_CRX_REL8_CMP,
- BFD_RELOC_CRX_REL16,
- BFD_RELOC_CRX_REL24,
- BFD_RELOC_CRX_REL32,
- BFD_RELOC_CRX_REGREL12,
- BFD_RELOC_CRX_REGREL22,
- BFD_RELOC_CRX_REGREL28,
- BFD_RELOC_CRX_REGREL32,
- BFD_RELOC_CRX_ABS16,
- BFD_RELOC_CRX_ABS32,
- BFD_RELOC_CRX_NUM8,
- BFD_RELOC_CRX_NUM16,
- BFD_RELOC_CRX_NUM32,
- BFD_RELOC_CRX_IMM16,
- BFD_RELOC_CRX_IMM32,
- BFD_RELOC_CRX_SWITCH8,
- BFD_RELOC_CRX_SWITCH16,
- BFD_RELOC_CRX_SWITCH32,
-
- /* These relocs are only used within the CRIS assembler. They are not
- (at present) written to any object files. */
- BFD_RELOC_CRIS_BDISP8,
- BFD_RELOC_CRIS_UNSIGNED_5,
- BFD_RELOC_CRIS_SIGNED_6,
- BFD_RELOC_CRIS_UNSIGNED_6,
- BFD_RELOC_CRIS_SIGNED_8,
- BFD_RELOC_CRIS_UNSIGNED_8,
- BFD_RELOC_CRIS_SIGNED_16,
- BFD_RELOC_CRIS_UNSIGNED_16,
- BFD_RELOC_CRIS_LAPCQ_OFFSET,
- BFD_RELOC_CRIS_UNSIGNED_4,
-
- /* Relocs used in ELF shared libraries for CRIS. */
- BFD_RELOC_CRIS_COPY,
- BFD_RELOC_CRIS_GLOB_DAT,
- BFD_RELOC_CRIS_JUMP_SLOT,
- BFD_RELOC_CRIS_RELATIVE,
-
- /* 32-bit offset to symbol-entry within GOT. */
- BFD_RELOC_CRIS_32_GOT,
-
- /* 16-bit offset to symbol-entry within GOT. */
- BFD_RELOC_CRIS_16_GOT,
-
- /* 32-bit offset to symbol-entry within GOT, with PLT handling. */
- BFD_RELOC_CRIS_32_GOTPLT,
-
- /* 16-bit offset to symbol-entry within GOT, with PLT handling. */
- BFD_RELOC_CRIS_16_GOTPLT,
-
- /* 32-bit offset to symbol, relative to GOT. */
- BFD_RELOC_CRIS_32_GOTREL,
-
- /* 32-bit offset to symbol with PLT entry, relative to GOT. */
- BFD_RELOC_CRIS_32_PLT_GOTREL,
-
- /* 32-bit offset to symbol with PLT entry, relative to this
- relocation. */
- BFD_RELOC_CRIS_32_PLT_PCREL,
-
- /* Relocs used in TLS code for CRIS. */
- BFD_RELOC_CRIS_32_GOT_GD,
- BFD_RELOC_CRIS_16_GOT_GD,
- BFD_RELOC_CRIS_32_GD,
- BFD_RELOC_CRIS_DTP,
- BFD_RELOC_CRIS_32_DTPREL,
- BFD_RELOC_CRIS_16_DTPREL,
- BFD_RELOC_CRIS_32_GOT_TPREL,
- BFD_RELOC_CRIS_16_GOT_TPREL,
- BFD_RELOC_CRIS_32_TPREL,
- BFD_RELOC_CRIS_16_TPREL,
- BFD_RELOC_CRIS_DTPMOD,
- BFD_RELOC_CRIS_32_IE,
-
- /* OpenRISC 1000 Relocations. */
- BFD_RELOC_OR1K_REL_26,
- BFD_RELOC_OR1K_SLO16,
- BFD_RELOC_OR1K_PCREL_PG21,
- BFD_RELOC_OR1K_LO13,
- BFD_RELOC_OR1K_SLO13,
- BFD_RELOC_OR1K_GOTPC_HI16,
- BFD_RELOC_OR1K_GOTPC_LO16,
- BFD_RELOC_OR1K_GOT_AHI16,
- BFD_RELOC_OR1K_GOT16,
- BFD_RELOC_OR1K_GOT_PG21,
- BFD_RELOC_OR1K_GOT_LO13,
- BFD_RELOC_OR1K_PLT26,
- BFD_RELOC_OR1K_PLTA26,
- BFD_RELOC_OR1K_GOTOFF_SLO16,
- BFD_RELOC_OR1K_COPY,
- BFD_RELOC_OR1K_GLOB_DAT,
- BFD_RELOC_OR1K_JMP_SLOT,
- BFD_RELOC_OR1K_RELATIVE,
- BFD_RELOC_OR1K_TLS_GD_HI16,
- BFD_RELOC_OR1K_TLS_GD_LO16,
- BFD_RELOC_OR1K_TLS_GD_PG21,
- BFD_RELOC_OR1K_TLS_GD_LO13,
- BFD_RELOC_OR1K_TLS_LDM_HI16,
- BFD_RELOC_OR1K_TLS_LDM_LO16,
- BFD_RELOC_OR1K_TLS_LDM_PG21,
- BFD_RELOC_OR1K_TLS_LDM_LO13,
- BFD_RELOC_OR1K_TLS_LDO_HI16,
- BFD_RELOC_OR1K_TLS_LDO_LO16,
- BFD_RELOC_OR1K_TLS_IE_HI16,
- BFD_RELOC_OR1K_TLS_IE_AHI16,
- BFD_RELOC_OR1K_TLS_IE_LO16,
- BFD_RELOC_OR1K_TLS_IE_PG21,
- BFD_RELOC_OR1K_TLS_IE_LO13,
- BFD_RELOC_OR1K_TLS_LE_HI16,
- BFD_RELOC_OR1K_TLS_LE_AHI16,
- BFD_RELOC_OR1K_TLS_LE_LO16,
- BFD_RELOC_OR1K_TLS_LE_SLO16,
- BFD_RELOC_OR1K_TLS_TPOFF,
- BFD_RELOC_OR1K_TLS_DTPOFF,
- BFD_RELOC_OR1K_TLS_DTPMOD,
-
- /* H8 elf Relocations. */
- BFD_RELOC_H8_DIR16A8,
- BFD_RELOC_H8_DIR16R8,
- BFD_RELOC_H8_DIR24A8,
- BFD_RELOC_H8_DIR24R8,
- BFD_RELOC_H8_DIR32A16,
- BFD_RELOC_H8_DISP32A16,
-
- /* Sony Xstormy16 Relocations. */
- BFD_RELOC_XSTORMY16_REL_12,
- BFD_RELOC_XSTORMY16_12,
- BFD_RELOC_XSTORMY16_24,
- BFD_RELOC_XSTORMY16_FPTR16,
-
- /* Self-describing complex relocations. */
- BFD_RELOC_RELC,
-
- /* Relocations used by VAX ELF. */
- BFD_RELOC_VAX_GLOB_DAT,
- BFD_RELOC_VAX_JMP_SLOT,
- BFD_RELOC_VAX_RELATIVE,
-
- /* Morpho MT - 16 bit immediate relocation. */
- BFD_RELOC_MT_PC16,
-
- /* Morpho MT - Hi 16 bits of an address. */
- BFD_RELOC_MT_HI16,
-
- /* Morpho MT - Low 16 bits of an address. */
- BFD_RELOC_MT_LO16,
-
- /* Morpho MT - Used to tell the linker which vtable entries are used. */
- BFD_RELOC_MT_GNU_VTINHERIT,
-
- /* Morpho MT - Used to tell the linker which vtable entries are used. */
- BFD_RELOC_MT_GNU_VTENTRY,
-
- /* Morpho MT - 8 bit immediate relocation. */
- BFD_RELOC_MT_PCINSN8,
-
- /* msp430 specific relocation codes. */
- BFD_RELOC_MSP430_10_PCREL,
- BFD_RELOC_MSP430_16_PCREL,
- BFD_RELOC_MSP430_16,
- BFD_RELOC_MSP430_16_PCREL_BYTE,
- BFD_RELOC_MSP430_16_BYTE,
- BFD_RELOC_MSP430_2X_PCREL,
- BFD_RELOC_MSP430_RL_PCREL,
- BFD_RELOC_MSP430_ABS8,
- BFD_RELOC_MSP430X_PCR20_EXT_SRC,
- BFD_RELOC_MSP430X_PCR20_EXT_DST,
- BFD_RELOC_MSP430X_PCR20_EXT_ODST,
- BFD_RELOC_MSP430X_ABS20_EXT_SRC,
- BFD_RELOC_MSP430X_ABS20_EXT_DST,
- BFD_RELOC_MSP430X_ABS20_EXT_ODST,
- BFD_RELOC_MSP430X_ABS20_ADR_SRC,
- BFD_RELOC_MSP430X_ABS20_ADR_DST,
- BFD_RELOC_MSP430X_PCR16,
- BFD_RELOC_MSP430X_PCR20_CALL,
- BFD_RELOC_MSP430X_ABS16,
- BFD_RELOC_MSP430_ABS_HI16,
- BFD_RELOC_MSP430_PREL31,
- BFD_RELOC_MSP430_SYM_DIFF,
- BFD_RELOC_MSP430_SET_ULEB128,
- BFD_RELOC_MSP430_SUB_ULEB128,
-
- /* Relocations used by the Altera Nios II core. */
- BFD_RELOC_NIOS2_S16,
- BFD_RELOC_NIOS2_U16,
- BFD_RELOC_NIOS2_CALL26,
- BFD_RELOC_NIOS2_IMM5,
- BFD_RELOC_NIOS2_CACHE_OPX,
- BFD_RELOC_NIOS2_IMM6,
- BFD_RELOC_NIOS2_IMM8,
- BFD_RELOC_NIOS2_HI16,
- BFD_RELOC_NIOS2_LO16,
- BFD_RELOC_NIOS2_HIADJ16,
- BFD_RELOC_NIOS2_GPREL,
- BFD_RELOC_NIOS2_UJMP,
- BFD_RELOC_NIOS2_CJMP,
- BFD_RELOC_NIOS2_CALLR,
- BFD_RELOC_NIOS2_ALIGN,
- BFD_RELOC_NIOS2_GOT16,
- BFD_RELOC_NIOS2_CALL16,
- BFD_RELOC_NIOS2_GOTOFF_LO,
- BFD_RELOC_NIOS2_GOTOFF_HA,
- BFD_RELOC_NIOS2_PCREL_LO,
- BFD_RELOC_NIOS2_PCREL_HA,
- BFD_RELOC_NIOS2_TLS_GD16,
- BFD_RELOC_NIOS2_TLS_LDM16,
- BFD_RELOC_NIOS2_TLS_LDO16,
- BFD_RELOC_NIOS2_TLS_IE16,
- BFD_RELOC_NIOS2_TLS_LE16,
- BFD_RELOC_NIOS2_TLS_DTPMOD,
- BFD_RELOC_NIOS2_TLS_DTPREL,
- BFD_RELOC_NIOS2_TLS_TPREL,
- BFD_RELOC_NIOS2_COPY,
- BFD_RELOC_NIOS2_GLOB_DAT,
- BFD_RELOC_NIOS2_JUMP_SLOT,
- BFD_RELOC_NIOS2_RELATIVE,
- BFD_RELOC_NIOS2_GOTOFF,
- BFD_RELOC_NIOS2_CALL26_NOAT,
- BFD_RELOC_NIOS2_GOT_LO,
- BFD_RELOC_NIOS2_GOT_HA,
- BFD_RELOC_NIOS2_CALL_LO,
- BFD_RELOC_NIOS2_CALL_HA,
- BFD_RELOC_NIOS2_R2_S12,
- BFD_RELOC_NIOS2_R2_I10_1_PCREL,
- BFD_RELOC_NIOS2_R2_T1I7_1_PCREL,
- BFD_RELOC_NIOS2_R2_T1I7_2,
- BFD_RELOC_NIOS2_R2_T2I4,
- BFD_RELOC_NIOS2_R2_T2I4_1,
- BFD_RELOC_NIOS2_R2_T2I4_2,
- BFD_RELOC_NIOS2_R2_X1I7_2,
- BFD_RELOC_NIOS2_R2_X2L5,
- BFD_RELOC_NIOS2_R2_F1I5_2,
- BFD_RELOC_NIOS2_R2_L5I4X1,
- BFD_RELOC_NIOS2_R2_T1X1I6,
- BFD_RELOC_NIOS2_R2_T1X1I6_2,
-
- /* PRU LDI 16-bit unsigned data-memory relocation. */
- BFD_RELOC_PRU_U16,
-
- /* PRU LDI 16-bit unsigned instruction-memory relocation. */
- BFD_RELOC_PRU_U16_PMEMIMM,
-
- /* PRU relocation for two consecutive LDI load instructions that load a
- 32 bit value into a register. If the higher bits are all zero, then
- the second instruction may be relaxed. */
- BFD_RELOC_PRU_LDI32,
-
- /* PRU QBBx 10-bit signed PC-relative relocation. */
- BFD_RELOC_PRU_S10_PCREL,
-
- /* PRU 8-bit unsigned relocation used for the LOOP instruction. */
- BFD_RELOC_PRU_U8_PCREL,
-
- /* PRU Program Memory relocations. Used to convert from byte
- addressing to 32-bit word addressing. */
- BFD_RELOC_PRU_32_PMEM,
- BFD_RELOC_PRU_16_PMEM,
-
- /* PRU relocations to mark the difference of two local symbols.
- These are only needed to support linker relaxation and can be
- ignored when not relaxing. The field is set to the value of the
- difference assuming no relaxation. The relocation encodes the
- position of the second symbol so the linker can determine whether to
- adjust the field value. The PMEM variants encode the word
- difference, instead of byte difference between symbols. */
- BFD_RELOC_PRU_GNU_DIFF8,
- BFD_RELOC_PRU_GNU_DIFF16,
- BFD_RELOC_PRU_GNU_DIFF32,
- BFD_RELOC_PRU_GNU_DIFF16_PMEM,
- BFD_RELOC_PRU_GNU_DIFF32_PMEM,
-
- /* IQ2000 Relocations. */
- BFD_RELOC_IQ2000_OFFSET_16,
- BFD_RELOC_IQ2000_OFFSET_21,
- BFD_RELOC_IQ2000_UHI16,
-
- /* Special Xtensa relocation used only by PLT entries in ELF shared
- objects to indicate that the runtime linker should set the value
- to one of its own internal functions or data structures. */
- BFD_RELOC_XTENSA_RTLD,
-
- /* Xtensa relocations for ELF shared objects. */
- BFD_RELOC_XTENSA_GLOB_DAT,
- BFD_RELOC_XTENSA_JMP_SLOT,
- BFD_RELOC_XTENSA_RELATIVE,
-
- /* Xtensa relocation used in ELF object files for symbols that may
- require PLT entries. Otherwise, this is just a generic 32-bit
- relocation. */
- BFD_RELOC_XTENSA_PLT,
-
- /* Xtensa relocations for backward compatibility. These have been
- replaced by BFD_RELOC_XTENSA_PDIFF and BFD_RELOC_XTENSA_NDIFF.
- Xtensa relocations to mark the difference of two local symbols.
- These are only needed to support linker relaxation and can be
- ignored when not relaxing. The field is set to the value of the
- difference assuming no relaxation. The relocation encodes the
- position of the first symbol so the linker can determine whether to
- adjust the field value. */
- BFD_RELOC_XTENSA_DIFF8,
- BFD_RELOC_XTENSA_DIFF16,
- BFD_RELOC_XTENSA_DIFF32,
-
- /* Generic Xtensa relocations for instruction operands. Only the slot
- number is encoded in the relocation. The relocation applies to the
- last PC-relative immediate operand, or if there are no PC-relative
- immediates, to the last immediate operand. */
- BFD_RELOC_XTENSA_SLOT0_OP,
- BFD_RELOC_XTENSA_SLOT1_OP,
- BFD_RELOC_XTENSA_SLOT2_OP,
- BFD_RELOC_XTENSA_SLOT3_OP,
- BFD_RELOC_XTENSA_SLOT4_OP,
- BFD_RELOC_XTENSA_SLOT5_OP,
- BFD_RELOC_XTENSA_SLOT6_OP,
- BFD_RELOC_XTENSA_SLOT7_OP,
- BFD_RELOC_XTENSA_SLOT8_OP,
- BFD_RELOC_XTENSA_SLOT9_OP,
- BFD_RELOC_XTENSA_SLOT10_OP,
- BFD_RELOC_XTENSA_SLOT11_OP,
- BFD_RELOC_XTENSA_SLOT12_OP,
- BFD_RELOC_XTENSA_SLOT13_OP,
- BFD_RELOC_XTENSA_SLOT14_OP,
-
- /* Alternate Xtensa relocations. Only the slot is encoded in the
- relocation. The meaning of these relocations is opcode-specific. */
- BFD_RELOC_XTENSA_SLOT0_ALT,
- BFD_RELOC_XTENSA_SLOT1_ALT,
- BFD_RELOC_XTENSA_SLOT2_ALT,
- BFD_RELOC_XTENSA_SLOT3_ALT,
- BFD_RELOC_XTENSA_SLOT4_ALT,
- BFD_RELOC_XTENSA_SLOT5_ALT,
- BFD_RELOC_XTENSA_SLOT6_ALT,
- BFD_RELOC_XTENSA_SLOT7_ALT,
- BFD_RELOC_XTENSA_SLOT8_ALT,
- BFD_RELOC_XTENSA_SLOT9_ALT,
- BFD_RELOC_XTENSA_SLOT10_ALT,
- BFD_RELOC_XTENSA_SLOT11_ALT,
- BFD_RELOC_XTENSA_SLOT12_ALT,
- BFD_RELOC_XTENSA_SLOT13_ALT,
- BFD_RELOC_XTENSA_SLOT14_ALT,
-
- /* Xtensa relocations for backward compatibility. These have all been
- replaced by BFD_RELOC_XTENSA_SLOT0_OP. */
- BFD_RELOC_XTENSA_OP0,
- BFD_RELOC_XTENSA_OP1,
- BFD_RELOC_XTENSA_OP2,
-
- /* Xtensa relocation to mark that the assembler expanded the
- instructions from an original target. The expansion size is
- encoded in the reloc size. */
- BFD_RELOC_XTENSA_ASM_EXPAND,
-
- /* Xtensa relocation to mark that the linker should simplify
- assembler-expanded instructions. This is commonly used
- internally by the linker after analysis of a
- BFD_RELOC_XTENSA_ASM_EXPAND. */
- BFD_RELOC_XTENSA_ASM_SIMPLIFY,
-
- /* Xtensa TLS relocations. */
- BFD_RELOC_XTENSA_TLSDESC_FN,
- BFD_RELOC_XTENSA_TLSDESC_ARG,
- BFD_RELOC_XTENSA_TLS_DTPOFF,
- BFD_RELOC_XTENSA_TLS_TPOFF,
- BFD_RELOC_XTENSA_TLS_FUNC,
- BFD_RELOC_XTENSA_TLS_ARG,
- BFD_RELOC_XTENSA_TLS_CALL,
-
- /* Xtensa relocations to mark the difference of two local symbols.
- These are only needed to support linker relaxation and can be
- ignored when not relaxing. The field is set to the value of the
- difference assuming no relaxation. The relocation encodes the
- position of the subtracted symbol so the linker can determine
- whether to adjust the field value. PDIFF relocations are used for
- positive differences, NDIFF relocations are used for negative
- differences. The difference value is treated as unsigned with these
- relocation types, giving full 8/16 value ranges. */
- BFD_RELOC_XTENSA_PDIFF8,
- BFD_RELOC_XTENSA_PDIFF16,
- BFD_RELOC_XTENSA_PDIFF32,
- BFD_RELOC_XTENSA_NDIFF8,
- BFD_RELOC_XTENSA_NDIFF16,
- BFD_RELOC_XTENSA_NDIFF32,
-
- /* 8 bit signed offset in (ix+d) or (iy+d). */
- BFD_RELOC_Z80_DISP8,
-
- /* First 8 bits of multibyte (32, 24 or 16 bit) value. */
- BFD_RELOC_Z80_BYTE0,
-
- /* Second 8 bits of multibyte (32, 24 or 16 bit) value. */
- BFD_RELOC_Z80_BYTE1,
-
- /* Third 8 bits of multibyte (32 or 24 bit) value. */
- BFD_RELOC_Z80_BYTE2,
-
- /* Fourth 8 bits of multibyte (32 bit) value. */
- BFD_RELOC_Z80_BYTE3,
-
- /* Lowest 16 bits of multibyte (32 or 24 bit) value. */
- BFD_RELOC_Z80_WORD0,
-
- /* Highest 16 bits of multibyte (32 or 24 bit) value. */
- BFD_RELOC_Z80_WORD1,
-
- /* Like BFD_RELOC_16 but big-endian. */
- BFD_RELOC_Z80_16_BE,
-
- /* DJNZ offset. */
- BFD_RELOC_Z8K_DISP7,
-
- /* CALR offset. */
- BFD_RELOC_Z8K_CALLR,
-
- /* 4 bit value. */
- BFD_RELOC_Z8K_IMM4L,
-
- /* Lattice Mico32 relocations. */
- BFD_RELOC_LM32_CALL,
- BFD_RELOC_LM32_BRANCH,
- BFD_RELOC_LM32_16_GOT,
- BFD_RELOC_LM32_GOTOFF_HI16,
- BFD_RELOC_LM32_GOTOFF_LO16,
- BFD_RELOC_LM32_COPY,
- BFD_RELOC_LM32_GLOB_DAT,
- BFD_RELOC_LM32_JMP_SLOT,
- BFD_RELOC_LM32_RELATIVE,
-
- /* Difference between two section addreses. Must be followed by a
- BFD_RELOC_MACH_O_PAIR. */
- BFD_RELOC_MACH_O_SECTDIFF,
-
- /* Like BFD_RELOC_MACH_O_SECTDIFF but with a local symbol. */
- BFD_RELOC_MACH_O_LOCAL_SECTDIFF,
-
- /* Pair of relocation. Contains the first symbol. */
- BFD_RELOC_MACH_O_PAIR,
-
- /* Symbol will be substracted. Must be followed by a BFD_RELOC_32. */
- BFD_RELOC_MACH_O_SUBTRACTOR32,
-
- /* Symbol will be substracted. Must be followed by a BFD_RELOC_64. */
- BFD_RELOC_MACH_O_SUBTRACTOR64,
-
- /* PCREL relocations. They are marked as branch to create PLT entry if
- required. */
- BFD_RELOC_MACH_O_X86_64_BRANCH32,
- BFD_RELOC_MACH_O_X86_64_BRANCH8,
-
- /* Used when referencing a GOT entry. */
- BFD_RELOC_MACH_O_X86_64_GOT,
-
- /* Used when loading a GOT entry with movq. It is specially marked so
- that the linker could optimize the movq to a leaq if possible. */
- BFD_RELOC_MACH_O_X86_64_GOT_LOAD,
-
- /* Same as BFD_RELOC_32_PCREL but with an implicit -1 addend. */
- BFD_RELOC_MACH_O_X86_64_PCREL32_1,
-
- /* Same as BFD_RELOC_32_PCREL but with an implicit -2 addend. */
- BFD_RELOC_MACH_O_X86_64_PCREL32_2,
-
- /* Same as BFD_RELOC_32_PCREL but with an implicit -4 addend. */
- BFD_RELOC_MACH_O_X86_64_PCREL32_4,
-
- /* Used when referencing a TLV entry. */
- BFD_RELOC_MACH_O_X86_64_TLV,
-
- /* Addend for PAGE or PAGEOFF. */
- BFD_RELOC_MACH_O_ARM64_ADDEND,
-
- /* Relative offset to page of GOT slot. */
- BFD_RELOC_MACH_O_ARM64_GOT_LOAD_PAGE21,
-
- /* Relative offset within page of GOT slot. */
- BFD_RELOC_MACH_O_ARM64_GOT_LOAD_PAGEOFF12,
-
- /* Address of a GOT entry. */
- BFD_RELOC_MACH_O_ARM64_POINTER_TO_GOT,
-
- /* This is a 32 bit reloc for the microblaze that stores the low 16
- bits of a value. */
- BFD_RELOC_MICROBLAZE_32_LO,
-
- /* This is a 32 bit pc-relative reloc for the microblaze that stores
- the low 16 bits of a value. */
- BFD_RELOC_MICROBLAZE_32_LO_PCREL,
-
- /* This is a 32 bit reloc for the microblaze that stores a value
- relative to the read-only small data area anchor. */
- BFD_RELOC_MICROBLAZE_32_ROSDA,
-
- /* This is a 32 bit reloc for the microblaze that stores a value
- relative to the read-write small data area anchor. */
- BFD_RELOC_MICROBLAZE_32_RWSDA,
-
- /* This is a 32 bit reloc for the microblaze to handle expressions of
- the form "Symbol Op Symbol". */
- BFD_RELOC_MICROBLAZE_32_SYM_OP_SYM,
-
- /* This is a 32 bit reloc that stores the 32 bit pc relative value in
- two words (with an imm instruction). No relocation is done here -
- only used for relaxing. */
- BFD_RELOC_MICROBLAZE_32_NONE,
-
- /* This is a 64 bit reloc that stores the 32 bit pc relative value in
- two words (with an imm instruction). No relocation is done here -
- only used for relaxing. */
- BFD_RELOC_MICROBLAZE_64_NONE,
-
- /* This is a 64 bit reloc that stores the 32 bit pc relative value in
- two words (with an imm instruction). The relocation is PC-relative
- GOT offset. */
- BFD_RELOC_MICROBLAZE_64_GOTPC,
-
- /* This is a 64 bit reloc that stores the 32 bit pc relative value in
- two words (with an imm instruction). The relocation is GOT offset. */
- BFD_RELOC_MICROBLAZE_64_GOT,
-
- /* This is a 64 bit reloc that stores the 32 bit pc relative value in
- two words (with an imm instruction). The relocation is PC-relative
- offset into PLT. */
- BFD_RELOC_MICROBLAZE_64_PLT,
-
- /* This is a 64 bit reloc that stores the 32 bit GOT relative value in
- two words (with an imm instruction). The relocation is relative
- offset from _GLOBAL_OFFSET_TABLE_. */
- BFD_RELOC_MICROBLAZE_64_GOTOFF,
-
- /* This is a 32 bit reloc that stores the 32 bit GOT relative value in
- a word. The relocation is relative offset from
- _GLOBAL_OFFSET_TABLE_. */
- BFD_RELOC_MICROBLAZE_32_GOTOFF,
-
- /* This is used to tell the dynamic linker to copy the value out of
- the dynamic object into the runtime process image. */
- BFD_RELOC_MICROBLAZE_COPY,
-
- /* Unused Reloc. */
- BFD_RELOC_MICROBLAZE_64_TLS,
-
- /* This is a 64 bit reloc that stores the 32 bit GOT relative value
- of the GOT TLS GD info entry in two words (with an imm instruction).
- The relocation is GOT offset. */
- BFD_RELOC_MICROBLAZE_64_TLSGD,
-
- /* This is a 64 bit reloc that stores the 32 bit GOT relative value
- of the GOT TLS LD info entry in two words (with an imm instruction).
- The relocation is GOT offset. */
- BFD_RELOC_MICROBLAZE_64_TLSLD,
-
- /* This is a 32 bit reloc that stores the Module ID to GOT(n). */
- BFD_RELOC_MICROBLAZE_32_TLSDTPMOD,
-
- /* This is a 32 bit reloc that stores TLS offset to GOT(n+1). */
- BFD_RELOC_MICROBLAZE_32_TLSDTPREL,
-
- /* This is a 32 bit reloc for storing TLS offset to two words (uses imm
- instruction). */
- BFD_RELOC_MICROBLAZE_64_TLSDTPREL,
-
- /* This is a 64 bit reloc that stores 32-bit thread pointer relative
- offset to two words (uses imm instruction). */
- BFD_RELOC_MICROBLAZE_64_TLSGOTTPREL,
-
- /* This is a 64 bit reloc that stores 32-bit thread pointer relative
- offset to two words (uses imm instruction). */
- BFD_RELOC_MICROBLAZE_64_TLSTPREL,
-
- /* This is a 64 bit reloc that stores the 32 bit pc relative value in
- two words (with an imm instruction). The relocation is PC-relative
- offset from start of TEXT. */
- BFD_RELOC_MICROBLAZE_64_TEXTPCREL,
-
- /* This is a 64 bit reloc that stores the 32 bit offset value in two
- words (with an imm instruction). The relocation is relative offset
- from start of TEXT. */
- BFD_RELOC_MICROBLAZE_64_TEXTREL,
-
- /* KVX pseudo relocation code to mark the start of the KVX relocation
- enumerators. N.B. the order of the enumerators is important as
- several tables in the KVX bfd backend are indexed by these
- enumerators; make sure they are all synced. */
- BFD_RELOC_KVX_RELOC_START,
-
- /* KVX null relocation code. */
- BFD_RELOC_KVX_NONE,
-
- /* KVX Relocations. */
- BFD_RELOC_KVX_16,
- BFD_RELOC_KVX_32,
- BFD_RELOC_KVX_64,
- BFD_RELOC_KVX_S16_PCREL,
- BFD_RELOC_KVX_PCREL17,
- BFD_RELOC_KVX_PCREL27,
- BFD_RELOC_KVX_32_PCREL,
- BFD_RELOC_KVX_S37_PCREL_LO10,
- BFD_RELOC_KVX_S37_PCREL_UP27,
- BFD_RELOC_KVX_S43_PCREL_LO10,
- BFD_RELOC_KVX_S43_PCREL_UP27,
- BFD_RELOC_KVX_S43_PCREL_EX6,
- BFD_RELOC_KVX_S64_PCREL_LO10,
- BFD_RELOC_KVX_S64_PCREL_UP27,
- BFD_RELOC_KVX_S64_PCREL_EX27,
- BFD_RELOC_KVX_64_PCREL,
- BFD_RELOC_KVX_S16,
- BFD_RELOC_KVX_S32_LO5,
- BFD_RELOC_KVX_S32_UP27,
- BFD_RELOC_KVX_S37_LO10,
- BFD_RELOC_KVX_S37_UP27,
- BFD_RELOC_KVX_S37_GOTOFF_LO10,
- BFD_RELOC_KVX_S37_GOTOFF_UP27,
- BFD_RELOC_KVX_S43_GOTOFF_LO10,
- BFD_RELOC_KVX_S43_GOTOFF_UP27,
- BFD_RELOC_KVX_S43_GOTOFF_EX6,
- BFD_RELOC_KVX_32_GOTOFF,
- BFD_RELOC_KVX_64_GOTOFF,
- BFD_RELOC_KVX_32_GOT,
- BFD_RELOC_KVX_S37_GOT_LO10,
- BFD_RELOC_KVX_S37_GOT_UP27,
- BFD_RELOC_KVX_S43_GOT_LO10,
- BFD_RELOC_KVX_S43_GOT_UP27,
- BFD_RELOC_KVX_S43_GOT_EX6,
- BFD_RELOC_KVX_64_GOT,
- BFD_RELOC_KVX_GLOB_DAT,
- BFD_RELOC_KVX_COPY,
- BFD_RELOC_KVX_JMP_SLOT,
- BFD_RELOC_KVX_RELATIVE,
- BFD_RELOC_KVX_S43_LO10,
- BFD_RELOC_KVX_S43_UP27,
- BFD_RELOC_KVX_S43_EX6,
- BFD_RELOC_KVX_S64_LO10,
- BFD_RELOC_KVX_S64_UP27,
- BFD_RELOC_KVX_S64_EX27,
- BFD_RELOC_KVX_S37_GOTADDR_LO10,
- BFD_RELOC_KVX_S37_GOTADDR_UP27,
- BFD_RELOC_KVX_S43_GOTADDR_LO10,
- BFD_RELOC_KVX_S43_GOTADDR_UP27,
- BFD_RELOC_KVX_S43_GOTADDR_EX6,
- BFD_RELOC_KVX_S64_GOTADDR_LO10,
- BFD_RELOC_KVX_S64_GOTADDR_UP27,
- BFD_RELOC_KVX_S64_GOTADDR_EX27,
- BFD_RELOC_KVX_64_DTPMOD,
- BFD_RELOC_KVX_64_DTPOFF,
- BFD_RELOC_KVX_S37_TLS_DTPOFF_LO10,
- BFD_RELOC_KVX_S37_TLS_DTPOFF_UP27,
- BFD_RELOC_KVX_S43_TLS_DTPOFF_LO10,
- BFD_RELOC_KVX_S43_TLS_DTPOFF_UP27,
- BFD_RELOC_KVX_S43_TLS_DTPOFF_EX6,
- BFD_RELOC_KVX_S37_TLS_GD_LO10,
- BFD_RELOC_KVX_S37_TLS_GD_UP27,
- BFD_RELOC_KVX_S43_TLS_GD_LO10,
- BFD_RELOC_KVX_S43_TLS_GD_UP27,
- BFD_RELOC_KVX_S43_TLS_GD_EX6,
- BFD_RELOC_KVX_S37_TLS_LD_LO10,
- BFD_RELOC_KVX_S37_TLS_LD_UP27,
- BFD_RELOC_KVX_S43_TLS_LD_LO10,
- BFD_RELOC_KVX_S43_TLS_LD_UP27,
- BFD_RELOC_KVX_S43_TLS_LD_EX6,
- BFD_RELOC_KVX_64_TPOFF,
- BFD_RELOC_KVX_S37_TLS_IE_LO10,
- BFD_RELOC_KVX_S37_TLS_IE_UP27,
- BFD_RELOC_KVX_S43_TLS_IE_LO10,
- BFD_RELOC_KVX_S43_TLS_IE_UP27,
- BFD_RELOC_KVX_S43_TLS_IE_EX6,
- BFD_RELOC_KVX_S37_TLS_LE_LO10,
- BFD_RELOC_KVX_S37_TLS_LE_UP27,
- BFD_RELOC_KVX_S43_TLS_LE_LO10,
- BFD_RELOC_KVX_S43_TLS_LE_UP27,
- BFD_RELOC_KVX_S43_TLS_LE_EX6,
- BFD_RELOC_KVX_8,
-
- /* KVX pseudo relocation code to mark the end of the KVX relocation
- enumerators that have direct mapping to ELF reloc codes. There are
- a few more enumerators after this one; those are mainly used by the
- KVX assembler for the internal fixup or to select one of the above
- enumerators. */
- BFD_RELOC_KVX_RELOC_END,
-
- /* AArch64 pseudo relocation code to mark the start of the AArch64
- relocation enumerators. N.B. the order of the enumerators is
- important as several tables in the AArch64 bfd backend are indexed
- by these enumerators; make sure they are all synced. */
- BFD_RELOC_AARCH64_RELOC_START,
-
- /* Deprecated AArch64 null relocation code. */
- BFD_RELOC_AARCH64_NULL,
-
- /* AArch64 null relocation code. */
- BFD_RELOC_AARCH64_NONE,
-
- /* Basic absolute relocations of N bits. These are equivalent to
- BFD_RELOC_N and they were added to assist the indexing of the howto
- table. */
- BFD_RELOC_AARCH64_64,
- BFD_RELOC_AARCH64_32,
- BFD_RELOC_AARCH64_16,
-
- /* PC-relative relocations. These are equivalent to BFD_RELOC_N_PCREL
- and they were added to assist the indexing of the howto table. */
- BFD_RELOC_AARCH64_64_PCREL,
- BFD_RELOC_AARCH64_32_PCREL,
- BFD_RELOC_AARCH64_16_PCREL,
-
- /* AArch64 MOV[NZK] instruction with most significant bits 0 to 15 of
- an unsigned address/value. */
- BFD_RELOC_AARCH64_MOVW_G0,
-
- /* AArch64 MOV[NZK] instruction with less significant bits 0 to 15 of
- an address/value. No overflow checking. */
- BFD_RELOC_AARCH64_MOVW_G0_NC,
-
- /* AArch64 MOV[NZK] instruction with most significant bits 16 to 31 of
- an unsigned address/value. */
- BFD_RELOC_AARCH64_MOVW_G1,
-
- /* AArch64 MOV[NZK] instruction with less significant bits 16 to 31 of
- an address/value. No overflow checking. */
- BFD_RELOC_AARCH64_MOVW_G1_NC,
-
- /* AArch64 MOV[NZK] instruction with most significant bits 32 to 47 of
- an unsigned address/value. */
- BFD_RELOC_AARCH64_MOVW_G2,
-
- /* AArch64 MOV[NZK] instruction with less significant bits 32 to 47 of
- an address/value. No overflow checking. */
- BFD_RELOC_AARCH64_MOVW_G2_NC,
-
- /* AArch64 MOV[NZK] instruction with most signficant bits 48 to 64 of a
- signed or unsigned address/value. */
- BFD_RELOC_AARCH64_MOVW_G3,
-
- /* AArch64 MOV[NZ] instruction with most significant bits 0 to 15 of a
- signed value. Changes instruction to MOVZ or MOVN depending on the
- value's sign. */
- BFD_RELOC_AARCH64_MOVW_G0_S,
-
- /* AArch64 MOV[NZ] instruction with most significant bits 16 to 31 of a
- signed value. Changes instruction to MOVZ or MOVN depending on the
- value's sign. */
- BFD_RELOC_AARCH64_MOVW_G1_S,
-
- /* AArch64 MOV[NZ] instruction with most significant bits 32 to 47 of a
- signed value. Changes instruction to MOVZ or MOVN depending on the
- value's sign. */
- BFD_RELOC_AARCH64_MOVW_G2_S,
-
- /* AArch64 MOV[NZ] instruction with most significant bits 0 to 15 of a
- signed value. Changes instruction to MOVZ or MOVN depending on the
- value's sign. */
- BFD_RELOC_AARCH64_MOVW_PREL_G0,
-
- /* AArch64 MOV[NZ] instruction with most significant bits 0 to 15 of a
- signed value. Changes instruction to MOVZ or MOVN depending on the
- value's sign. */
- BFD_RELOC_AARCH64_MOVW_PREL_G0_NC,
-
- /* AArch64 MOVK instruction with most significant bits 16 to 31 of a
- signed value. */
- BFD_RELOC_AARCH64_MOVW_PREL_G1,
-
- /* AArch64 MOVK instruction with most significant bits 16 to 31 of a
- signed value. */
- BFD_RELOC_AARCH64_MOVW_PREL_G1_NC,
-
- /* AArch64 MOVK instruction with most significant bits 32 to 47 of a
- signed value. */
- BFD_RELOC_AARCH64_MOVW_PREL_G2,
-
- /* AArch64 MOVK instruction with most significant bits 32 to 47 of a
- signed value. */
- BFD_RELOC_AARCH64_MOVW_PREL_G2_NC,
-
- /* AArch64 MOVK instruction with most significant bits 47 to 63 of a
- signed value. */
- BFD_RELOC_AARCH64_MOVW_PREL_G3,
-
- /* AArch64 Load Literal instruction, holding a 19 bit pc-relative word
- offset. The lowest two bits must be zero and are not stored in the
- instruction, giving a 21 bit signed byte offset. */
- BFD_RELOC_AARCH64_LD_LO19_PCREL,
-
- /* AArch64 ADR instruction, holding a simple 21 bit pc-relative byte
- offset. */
- BFD_RELOC_AARCH64_ADR_LO21_PCREL,
-
- /* AArch64 ADRP instruction, with bits 12 to 32 of a pc-relative page
- offset, giving a 4KB aligned page base address. */
- BFD_RELOC_AARCH64_ADR_HI21_PCREL,
-
- /* AArch64 ADRP instruction, with bits 12 to 32 of a pc-relative page
- offset, giving a 4KB aligned page base address, but with no overflow
- checking. */
- BFD_RELOC_AARCH64_ADR_HI21_NC_PCREL,
-
- /* AArch64 ADD immediate instruction, holding bits 0 to 11 of the
- address. Used in conjunction with BFD_RELOC_AARCH64_ADR_HI21_PCREL. */
- BFD_RELOC_AARCH64_ADD_LO12,
-
- /* AArch64 8-bit load/store instruction, holding bits 0 to 11 of the
- address. Used in conjunction with BFD_RELOC_AARCH64_ADR_HI21_PCREL. */
- BFD_RELOC_AARCH64_LDST8_LO12,
-
- /* AArch64 14 bit pc-relative test bit and branch.
- The lowest two bits must be zero and are not stored in the
- instruction, giving a 16 bit signed byte offset. */
- BFD_RELOC_AARCH64_TSTBR14,
-
- /* AArch64 19 bit pc-relative conditional branch and compare & branch.
- The lowest two bits must be zero and are not stored in the
- instruction, giving a 21 bit signed byte offset. */
- BFD_RELOC_AARCH64_BRANCH19,
-
- /* AArch64 26 bit pc-relative unconditional branch.
- The lowest two bits must be zero and are not stored in the
- instruction, giving a 28 bit signed byte offset. */
- BFD_RELOC_AARCH64_JUMP26,
-
- /* AArch64 26 bit pc-relative unconditional branch and link.
- The lowest two bits must be zero and are not stored in the
- instruction, giving a 28 bit signed byte offset. */
- BFD_RELOC_AARCH64_CALL26,
-
- /* AArch64 16-bit load/store instruction, holding bits 0 to 11 of the
- address. Used in conjunction with BFD_RELOC_AARCH64_ADR_HI21_PCREL. */
- BFD_RELOC_AARCH64_LDST16_LO12,
-
- /* AArch64 32-bit load/store instruction, holding bits 0 to 11 of the
- address. Used in conjunction with BFD_RELOC_AARCH64_ADR_HI21_PCREL. */
- BFD_RELOC_AARCH64_LDST32_LO12,
-
- /* AArch64 64-bit load/store instruction, holding bits 0 to 11 of the
- address. Used in conjunction with BFD_RELOC_AARCH64_ADR_HI21_PCREL. */
- BFD_RELOC_AARCH64_LDST64_LO12,
-
- /* AArch64 128-bit load/store instruction, holding bits 0 to 11 of the
- address. Used in conjunction with BFD_RELOC_AARCH64_ADR_HI21_PCREL. */
- BFD_RELOC_AARCH64_LDST128_LO12,
-
- /* AArch64 Load Literal instruction, holding a 19 bit PC relative word
- offset of the global offset table entry for a symbol. The lowest
- two bits must be zero and are not stored in the instruction, giving
- a 21 bit signed byte offset. This relocation type requires signed
- overflow checking. */
- BFD_RELOC_AARCH64_GOT_LD_PREL19,
-
- /* Get to the page base of the global offset table entry for a symbol
- as part of an ADRP instruction using a 21 bit PC relative value.
- Used in conjunction with BFD_RELOC_AARCH64_LD64_GOT_LO12_NC. */
- BFD_RELOC_AARCH64_ADR_GOT_PAGE,
-
- /* Unsigned 12 bit byte offset for 64 bit load/store from the page of
- the GOT entry for this symbol. Used in conjunction with
- BFD_RELOC_AARCH64_ADR_GOT_PAGE. Valid in LP64 ABI only. */
- BFD_RELOC_AARCH64_LD64_GOT_LO12_NC,
-
- /* Unsigned 12 bit byte offset for 32 bit load/store from the page of
- the GOT entry for this symbol. Used in conjunction with
- BFD_RELOC_AARCH64_ADR_GOT_PAGE. Valid in ILP32 ABI only. */
- BFD_RELOC_AARCH64_LD32_GOT_LO12_NC,
-
- /* Unsigned 16 bit byte offset for 64 bit load/store from the GOT entry
- for this symbol. Valid in LP64 ABI only. */
- BFD_RELOC_AARCH64_MOVW_GOTOFF_G0_NC,
-
- /* Unsigned 16 bit byte higher offset for 64 bit load/store from the
- GOT entry for this symbol. Valid in LP64 ABI only. */
- BFD_RELOC_AARCH64_MOVW_GOTOFF_G1,
-
- /* Unsigned 15 bit byte offset for 64 bit load/store from the page of
- the GOT entry for this symbol. Valid in LP64 ABI only. */
- BFD_RELOC_AARCH64_LD64_GOTOFF_LO15,
-
- /* Scaled 14 bit byte offset to the page base of the global offset
- table. */
- BFD_RELOC_AARCH64_LD32_GOTPAGE_LO14,
-
- /* Scaled 15 bit byte offset to the page base of the global offset
- table. */
- BFD_RELOC_AARCH64_LD64_GOTPAGE_LO15,
-
- /* Get to the page base of the global offset table entry for a symbols
- tls_index structure as part of an adrp instruction using a 21 bit PC
- relative value. Used in conjunction with
- BFD_RELOC_AARCH64_TLSGD_ADD_LO12_NC. */
- BFD_RELOC_AARCH64_TLSGD_ADR_PAGE21,
-
- /* AArch64 TLS General Dynamic. */
- BFD_RELOC_AARCH64_TLSGD_ADR_PREL21,
-
- /* Unsigned 12 bit byte offset to global offset table entry for a
- symbol's tls_index structure. Used in conjunction with
- BFD_RELOC_AARCH64_TLSGD_ADR_PAGE21. */
- BFD_RELOC_AARCH64_TLSGD_ADD_LO12_NC,
-
- /* AArch64 TLS General Dynamic relocation. */
- BFD_RELOC_AARCH64_TLSGD_MOVW_G0_NC,
-
- /* AArch64 TLS General Dynamic relocation. */
- BFD_RELOC_AARCH64_TLSGD_MOVW_G1,
-
- /* AArch64 TLS INITIAL EXEC relocation. */
- BFD_RELOC_AARCH64_TLSIE_ADR_GOTTPREL_PAGE21,
-
- /* AArch64 TLS INITIAL EXEC relocation. */
- BFD_RELOC_AARCH64_TLSIE_LD64_GOTTPREL_LO12_NC,
-
- /* AArch64 TLS INITIAL EXEC relocation. */
- BFD_RELOC_AARCH64_TLSIE_LD32_GOTTPREL_LO12_NC,
-
- /* AArch64 TLS INITIAL EXEC relocation. */
- BFD_RELOC_AARCH64_TLSIE_LD_GOTTPREL_PREL19,
-
- /* AArch64 TLS INITIAL EXEC relocation. */
- BFD_RELOC_AARCH64_TLSIE_MOVW_GOTTPREL_G0_NC,
-
- /* AArch64 TLS INITIAL EXEC relocation. */
- BFD_RELOC_AARCH64_TLSIE_MOVW_GOTTPREL_G1,
-
- /* bit[23:12] of byte offset to module TLS base address. */
- BFD_RELOC_AARCH64_TLSLD_ADD_DTPREL_HI12,
-
- /* Unsigned 12 bit byte offset to module TLS base address. */
- BFD_RELOC_AARCH64_TLSLD_ADD_DTPREL_LO12,
-
- /* No overflow check version of
- BFD_RELOC_AARCH64_TLSLD_ADD_DTPREL_LO12. */
- BFD_RELOC_AARCH64_TLSLD_ADD_DTPREL_LO12_NC,
-
- /* Unsigned 12 bit byte offset to global offset table entry for a
- symbol's tls_index structure. Used in conjunction with
- BFD_RELOC_AARCH64_TLSLD_ADR_PAGE21. */
- BFD_RELOC_AARCH64_TLSLD_ADD_LO12_NC,
-
- /* GOT entry page address for AArch64 TLS Local Dynamic, used with ADRP
- instruction. */
- BFD_RELOC_AARCH64_TLSLD_ADR_PAGE21,
-
- /* GOT entry address for AArch64 TLS Local Dynamic, used with ADR
- instruction. */
- BFD_RELOC_AARCH64_TLSLD_ADR_PREL21,
-
- /* bit[11:1] of byte offset to module TLS base address, encoded in ldst
- instructions. */
- BFD_RELOC_AARCH64_TLSLD_LDST16_DTPREL_LO12,
-
- /* Similar to BFD_RELOC_AARCH64_TLSLD_LDST16_DTPREL_LO12, but no
- overflow check. */
- BFD_RELOC_AARCH64_TLSLD_LDST16_DTPREL_LO12_NC,
-
- /* bit[11:2] of byte offset to module TLS base address, encoded in ldst
- instructions. */
- BFD_RELOC_AARCH64_TLSLD_LDST32_DTPREL_LO12,
-
- /* Similar to BFD_RELOC_AARCH64_TLSLD_LDST32_DTPREL_LO12, but no
- overflow check. */
- BFD_RELOC_AARCH64_TLSLD_LDST32_DTPREL_LO12_NC,
-
- /* bit[11:3] of byte offset to module TLS base address, encoded in ldst
- instructions. */
- BFD_RELOC_AARCH64_TLSLD_LDST64_DTPREL_LO12,
-
- /* Similar to BFD_RELOC_AARCH64_TLSLD_LDST64_DTPREL_LO12, but no
- overflow check. */
- BFD_RELOC_AARCH64_TLSLD_LDST64_DTPREL_LO12_NC,
-
- /* bit[11:0] of byte offset to module TLS base address, encoded in ldst
- instructions. */
- BFD_RELOC_AARCH64_TLSLD_LDST8_DTPREL_LO12,
-
- /* Similar to BFD_RELOC_AARCH64_TLSLD_LDST8_DTPREL_LO12, but no
- overflow check. */
- BFD_RELOC_AARCH64_TLSLD_LDST8_DTPREL_LO12_NC,
-
- /* bit[15:0] of byte offset to module TLS base address. */
- BFD_RELOC_AARCH64_TLSLD_MOVW_DTPREL_G0,
-
- /* No overflow check version of BFD_RELOC_AARCH64_TLSLD_MOVW_DTPREL_G0. */
- BFD_RELOC_AARCH64_TLSLD_MOVW_DTPREL_G0_NC,
-
- /* bit[31:16] of byte offset to module TLS base address. */
- BFD_RELOC_AARCH64_TLSLD_MOVW_DTPREL_G1,
-
- /* No overflow check version of BFD_RELOC_AARCH64_TLSLD_MOVW_DTPREL_G1. */
- BFD_RELOC_AARCH64_TLSLD_MOVW_DTPREL_G1_NC,
-
- /* bit[47:32] of byte offset to module TLS base address. */
- BFD_RELOC_AARCH64_TLSLD_MOVW_DTPREL_G2,
-
- /* AArch64 TLS LOCAL EXEC relocation. */
- BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G2,
-
- /* AArch64 TLS LOCAL EXEC relocation. */
- BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G1,
-
- /* AArch64 TLS LOCAL EXEC relocation. */
- BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G1_NC,
-
- /* AArch64 TLS LOCAL EXEC relocation. */
- BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G0,
-
- /* AArch64 TLS LOCAL EXEC relocation. */
- BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G0_NC,
-
- /* AArch64 TLS LOCAL EXEC relocation. */
- BFD_RELOC_AARCH64_TLSLE_ADD_TPREL_HI12,
-
- /* AArch64 TLS LOCAL EXEC relocation. */
- BFD_RELOC_AARCH64_TLSLE_ADD_TPREL_LO12,
-
- /* AArch64 TLS LOCAL EXEC relocation. */
- BFD_RELOC_AARCH64_TLSLE_ADD_TPREL_LO12_NC,
-
- /* bit[11:1] of byte offset to module TLS base address, encoded in ldst
- instructions. */
- BFD_RELOC_AARCH64_TLSLE_LDST16_TPREL_LO12,
-
- /* Similar to BFD_RELOC_AARCH64_TLSLE_LDST16_TPREL_LO12, but no
- overflow check. */
- BFD_RELOC_AARCH64_TLSLE_LDST16_TPREL_LO12_NC,
-
- /* bit[11:2] of byte offset to module TLS base address, encoded in ldst
- instructions. */
- BFD_RELOC_AARCH64_TLSLE_LDST32_TPREL_LO12,
-
- /* Similar to BFD_RELOC_AARCH64_TLSLE_LDST32_TPREL_LO12, but no
- overflow check. */
- BFD_RELOC_AARCH64_TLSLE_LDST32_TPREL_LO12_NC,
-
- /* bit[11:3] of byte offset to module TLS base address, encoded in ldst
- instructions. */
- BFD_RELOC_AARCH64_TLSLE_LDST64_TPREL_LO12,
-
- /* Similar to BFD_RELOC_AARCH64_TLSLE_LDST64_TPREL_LO12, but no
- overflow check. */
- BFD_RELOC_AARCH64_TLSLE_LDST64_TPREL_LO12_NC,
-
- /* bit[11:0] of byte offset to module TLS base address, encoded in ldst
- instructions. */
- BFD_RELOC_AARCH64_TLSLE_LDST8_TPREL_LO12,
-
- /* Similar to BFD_RELOC_AARCH64_TLSLE_LDST8_TPREL_LO12, but no overflow
- check. */
- BFD_RELOC_AARCH64_TLSLE_LDST8_TPREL_LO12_NC,
-
- /* AArch64 TLS DESC relocations. */
- BFD_RELOC_AARCH64_TLSDESC_LD_PREL19,
- BFD_RELOC_AARCH64_TLSDESC_ADR_PREL21,
- BFD_RELOC_AARCH64_TLSDESC_ADR_PAGE21,
- BFD_RELOC_AARCH64_TLSDESC_LD64_LO12,
- BFD_RELOC_AARCH64_TLSDESC_LD32_LO12_NC,
- BFD_RELOC_AARCH64_TLSDESC_ADD_LO12,
- BFD_RELOC_AARCH64_TLSDESC_OFF_G1,
- BFD_RELOC_AARCH64_TLSDESC_OFF_G0_NC,
- BFD_RELOC_AARCH64_TLSDESC_LDR,
- BFD_RELOC_AARCH64_TLSDESC_ADD,
- BFD_RELOC_AARCH64_TLSDESC_CALL,
-
- /* AArch64 DSO relocations. */
- BFD_RELOC_AARCH64_COPY,
- BFD_RELOC_AARCH64_GLOB_DAT,
- BFD_RELOC_AARCH64_JUMP_SLOT,
- BFD_RELOC_AARCH64_RELATIVE,
-
- /* AArch64 TLS relocations. */
- BFD_RELOC_AARCH64_TLS_DTPMOD,
- BFD_RELOC_AARCH64_TLS_DTPREL,
- BFD_RELOC_AARCH64_TLS_TPREL,
- BFD_RELOC_AARCH64_TLSDESC,
-
- /* AArch64 support for STT_GNU_IFUNC. */
- BFD_RELOC_AARCH64_IRELATIVE,
-
- /* AArch64 pseudo relocation code to mark the end of the AArch64
- relocation enumerators that have direct mapping to ELF reloc codes.
- There are a few more enumerators after this one; those are mainly
- used by the AArch64 assembler for the internal fixup or to select
- one of the above enumerators. */
- BFD_RELOC_AARCH64_RELOC_END,
-
- /* AArch64 pseudo relocation code to be used internally by the AArch64
- assembler and not (currently) written to any object files. */
- BFD_RELOC_AARCH64_GAS_INTERNAL_FIXUP,
-
- /* AArch64 unspecified load/store instruction, holding bits 0 to 11 of the
- address. Used in conjunction with BFD_RELOC_AARCH64_ADR_HI21_PCREL. */
- BFD_RELOC_AARCH64_LDST_LO12,
-
- /* AArch64 pseudo relocation code for TLS local dynamic mode. It's to
- be used internally by the AArch64 assembler and not (currently)
- written to any object files. */
- BFD_RELOC_AARCH64_TLSLD_LDST_DTPREL_LO12,
-
- /* Similar to BFD_RELOC_AARCH64_TLSLD_LDST_DTPREL_LO12, but no overflow
- check. */
- BFD_RELOC_AARCH64_TLSLD_LDST_DTPREL_LO12_NC,
-
- /* AArch64 pseudo relocation code for TLS local exec mode. It's to be
- used internally by the AArch64 assembler and not (currently) written
- to any object files. */
- BFD_RELOC_AARCH64_TLSLE_LDST_TPREL_LO12,
-
- /* Similar to BFD_RELOC_AARCH64_TLSLE_LDST_TPREL_LO12, but no overflow
- check. */
- BFD_RELOC_AARCH64_TLSLE_LDST_TPREL_LO12_NC,
-
- /* AArch64 pseudo relocation code to be used internally by the AArch64
- assembler and not (currently) written to any object files. */
- BFD_RELOC_AARCH64_LD_GOT_LO12_NC,
-
- /* AArch64 pseudo relocation code to be used internally by the AArch64
- assembler and not (currently) written to any object files. */
- BFD_RELOC_AARCH64_TLSIE_LD_GOTTPREL_LO12_NC,
-
- /* AArch64 pseudo relocation code to be used internally by the AArch64
- assembler and not (currently) written to any object files. */
- BFD_RELOC_AARCH64_TLSDESC_LD_LO12_NC,
-
- /* Tilera TILEPro Relocations. */
- BFD_RELOC_TILEPRO_COPY,
- BFD_RELOC_TILEPRO_GLOB_DAT,
- BFD_RELOC_TILEPRO_JMP_SLOT,
- BFD_RELOC_TILEPRO_RELATIVE,
- BFD_RELOC_TILEPRO_BROFF_X1,
- BFD_RELOC_TILEPRO_JOFFLONG_X1,
- BFD_RELOC_TILEPRO_JOFFLONG_X1_PLT,
- BFD_RELOC_TILEPRO_IMM8_X0,
- BFD_RELOC_TILEPRO_IMM8_Y0,
- BFD_RELOC_TILEPRO_IMM8_X1,
- BFD_RELOC_TILEPRO_IMM8_Y1,
- BFD_RELOC_TILEPRO_DEST_IMM8_X1,
- BFD_RELOC_TILEPRO_MT_IMM15_X1,
- BFD_RELOC_TILEPRO_MF_IMM15_X1,
- BFD_RELOC_TILEPRO_IMM16_X0,
- BFD_RELOC_TILEPRO_IMM16_X1,
- BFD_RELOC_TILEPRO_IMM16_X0_LO,
- BFD_RELOC_TILEPRO_IMM16_X1_LO,
- BFD_RELOC_TILEPRO_IMM16_X0_HI,
- BFD_RELOC_TILEPRO_IMM16_X1_HI,
- BFD_RELOC_TILEPRO_IMM16_X0_HA,
- BFD_RELOC_TILEPRO_IMM16_X1_HA,
- BFD_RELOC_TILEPRO_IMM16_X0_PCREL,
- BFD_RELOC_TILEPRO_IMM16_X1_PCREL,
- BFD_RELOC_TILEPRO_IMM16_X0_LO_PCREL,
- BFD_RELOC_TILEPRO_IMM16_X1_LO_PCREL,
- BFD_RELOC_TILEPRO_IMM16_X0_HI_PCREL,
- BFD_RELOC_TILEPRO_IMM16_X1_HI_PCREL,
- BFD_RELOC_TILEPRO_IMM16_X0_HA_PCREL,
- BFD_RELOC_TILEPRO_IMM16_X1_HA_PCREL,
- BFD_RELOC_TILEPRO_IMM16_X0_GOT,
- BFD_RELOC_TILEPRO_IMM16_X1_GOT,
- BFD_RELOC_TILEPRO_IMM16_X0_GOT_LO,
- BFD_RELOC_TILEPRO_IMM16_X1_GOT_LO,
- BFD_RELOC_TILEPRO_IMM16_X0_GOT_HI,
- BFD_RELOC_TILEPRO_IMM16_X1_GOT_HI,
- BFD_RELOC_TILEPRO_IMM16_X0_GOT_HA,
- BFD_RELOC_TILEPRO_IMM16_X1_GOT_HA,
- BFD_RELOC_TILEPRO_MMSTART_X0,
- BFD_RELOC_TILEPRO_MMEND_X0,
- BFD_RELOC_TILEPRO_MMSTART_X1,
- BFD_RELOC_TILEPRO_MMEND_X1,
- BFD_RELOC_TILEPRO_SHAMT_X0,
- BFD_RELOC_TILEPRO_SHAMT_X1,
- BFD_RELOC_TILEPRO_SHAMT_Y0,
- BFD_RELOC_TILEPRO_SHAMT_Y1,
- BFD_RELOC_TILEPRO_TLS_GD_CALL,
- BFD_RELOC_TILEPRO_IMM8_X0_TLS_GD_ADD,
- BFD_RELOC_TILEPRO_IMM8_X1_TLS_GD_ADD,
- BFD_RELOC_TILEPRO_IMM8_Y0_TLS_GD_ADD,
- BFD_RELOC_TILEPRO_IMM8_Y1_TLS_GD_ADD,
- BFD_RELOC_TILEPRO_TLS_IE_LOAD,
- BFD_RELOC_TILEPRO_IMM16_X0_TLS_GD,
- BFD_RELOC_TILEPRO_IMM16_X1_TLS_GD,
- BFD_RELOC_TILEPRO_IMM16_X0_TLS_GD_LO,
- BFD_RELOC_TILEPRO_IMM16_X1_TLS_GD_LO,
- BFD_RELOC_TILEPRO_IMM16_X0_TLS_GD_HI,
- BFD_RELOC_TILEPRO_IMM16_X1_TLS_GD_HI,
- BFD_RELOC_TILEPRO_IMM16_X0_TLS_GD_HA,
- BFD_RELOC_TILEPRO_IMM16_X1_TLS_GD_HA,
- BFD_RELOC_TILEPRO_IMM16_X0_TLS_IE,
- BFD_RELOC_TILEPRO_IMM16_X1_TLS_IE,
- BFD_RELOC_TILEPRO_IMM16_X0_TLS_IE_LO,
- BFD_RELOC_TILEPRO_IMM16_X1_TLS_IE_LO,
- BFD_RELOC_TILEPRO_IMM16_X0_TLS_IE_HI,
- BFD_RELOC_TILEPRO_IMM16_X1_TLS_IE_HI,
- BFD_RELOC_TILEPRO_IMM16_X0_TLS_IE_HA,
- BFD_RELOC_TILEPRO_IMM16_X1_TLS_IE_HA,
- BFD_RELOC_TILEPRO_TLS_DTPMOD32,
- BFD_RELOC_TILEPRO_TLS_DTPOFF32,
- BFD_RELOC_TILEPRO_TLS_TPOFF32,
- BFD_RELOC_TILEPRO_IMM16_X0_TLS_LE,
- BFD_RELOC_TILEPRO_IMM16_X1_TLS_LE,
- BFD_RELOC_TILEPRO_IMM16_X0_TLS_LE_LO,
- BFD_RELOC_TILEPRO_IMM16_X1_TLS_LE_LO,
- BFD_RELOC_TILEPRO_IMM16_X0_TLS_LE_HI,
- BFD_RELOC_TILEPRO_IMM16_X1_TLS_LE_HI,
- BFD_RELOC_TILEPRO_IMM16_X0_TLS_LE_HA,
- BFD_RELOC_TILEPRO_IMM16_X1_TLS_LE_HA,
-
- /* Tilera TILE-Gx Relocations. */
- BFD_RELOC_TILEGX_HW0,
- BFD_RELOC_TILEGX_HW1,
- BFD_RELOC_TILEGX_HW2,
- BFD_RELOC_TILEGX_HW3,
- BFD_RELOC_TILEGX_HW0_LAST,
- BFD_RELOC_TILEGX_HW1_LAST,
- BFD_RELOC_TILEGX_HW2_LAST,
- BFD_RELOC_TILEGX_COPY,
- BFD_RELOC_TILEGX_GLOB_DAT,
- BFD_RELOC_TILEGX_JMP_SLOT,
- BFD_RELOC_TILEGX_RELATIVE,
- BFD_RELOC_TILEGX_BROFF_X1,
- BFD_RELOC_TILEGX_JUMPOFF_X1,
- BFD_RELOC_TILEGX_JUMPOFF_X1_PLT,
- BFD_RELOC_TILEGX_IMM8_X0,
- BFD_RELOC_TILEGX_IMM8_Y0,
- BFD_RELOC_TILEGX_IMM8_X1,
- BFD_RELOC_TILEGX_IMM8_Y1,
- BFD_RELOC_TILEGX_DEST_IMM8_X1,
- BFD_RELOC_TILEGX_MT_IMM14_X1,
- BFD_RELOC_TILEGX_MF_IMM14_X1,
- BFD_RELOC_TILEGX_MMSTART_X0,
- BFD_RELOC_TILEGX_MMEND_X0,
- BFD_RELOC_TILEGX_SHAMT_X0,
- BFD_RELOC_TILEGX_SHAMT_X1,
- BFD_RELOC_TILEGX_SHAMT_Y0,
- BFD_RELOC_TILEGX_SHAMT_Y1,
- BFD_RELOC_TILEGX_IMM16_X0_HW0,
- BFD_RELOC_TILEGX_IMM16_X1_HW0,
- BFD_RELOC_TILEGX_IMM16_X0_HW1,
- BFD_RELOC_TILEGX_IMM16_X1_HW1,
- BFD_RELOC_TILEGX_IMM16_X0_HW2,
- BFD_RELOC_TILEGX_IMM16_X1_HW2,
- BFD_RELOC_TILEGX_IMM16_X0_HW3,
- BFD_RELOC_TILEGX_IMM16_X1_HW3,
- BFD_RELOC_TILEGX_IMM16_X0_HW0_LAST,
- BFD_RELOC_TILEGX_IMM16_X1_HW0_LAST,
- BFD_RELOC_TILEGX_IMM16_X0_HW1_LAST,
- BFD_RELOC_TILEGX_IMM16_X1_HW1_LAST,
- BFD_RELOC_TILEGX_IMM16_X0_HW2_LAST,
- BFD_RELOC_TILEGX_IMM16_X1_HW2_LAST,
- BFD_RELOC_TILEGX_IMM16_X0_HW0_PCREL,
- BFD_RELOC_TILEGX_IMM16_X1_HW0_PCREL,
- BFD_RELOC_TILEGX_IMM16_X0_HW1_PCREL,
- BFD_RELOC_TILEGX_IMM16_X1_HW1_PCREL,
- BFD_RELOC_TILEGX_IMM16_X0_HW2_PCREL,
- BFD_RELOC_TILEGX_IMM16_X1_HW2_PCREL,
- BFD_RELOC_TILEGX_IMM16_X0_HW3_PCREL,
- BFD_RELOC_TILEGX_IMM16_X1_HW3_PCREL,
- BFD_RELOC_TILEGX_IMM16_X0_HW0_LAST_PCREL,
- BFD_RELOC_TILEGX_IMM16_X1_HW0_LAST_PCREL,
- BFD_RELOC_TILEGX_IMM16_X0_HW1_LAST_PCREL,
- BFD_RELOC_TILEGX_IMM16_X1_HW1_LAST_PCREL,
- BFD_RELOC_TILEGX_IMM16_X0_HW2_LAST_PCREL,
- BFD_RELOC_TILEGX_IMM16_X1_HW2_LAST_PCREL,
- BFD_RELOC_TILEGX_IMM16_X0_HW0_GOT,
- BFD_RELOC_TILEGX_IMM16_X1_HW0_GOT,
- BFD_RELOC_TILEGX_IMM16_X0_HW0_PLT_PCREL,
- BFD_RELOC_TILEGX_IMM16_X1_HW0_PLT_PCREL,
- BFD_RELOC_TILEGX_IMM16_X0_HW1_PLT_PCREL,
- BFD_RELOC_TILEGX_IMM16_X1_HW1_PLT_PCREL,
- BFD_RELOC_TILEGX_IMM16_X0_HW2_PLT_PCREL,
- BFD_RELOC_TILEGX_IMM16_X1_HW2_PLT_PCREL,
- BFD_RELOC_TILEGX_IMM16_X0_HW0_LAST_GOT,
- BFD_RELOC_TILEGX_IMM16_X1_HW0_LAST_GOT,
- BFD_RELOC_TILEGX_IMM16_X0_HW1_LAST_GOT,
- BFD_RELOC_TILEGX_IMM16_X1_HW1_LAST_GOT,
- BFD_RELOC_TILEGX_IMM16_X0_HW3_PLT_PCREL,
- BFD_RELOC_TILEGX_IMM16_X1_HW3_PLT_PCREL,
- BFD_RELOC_TILEGX_IMM16_X0_HW0_TLS_GD,
- BFD_RELOC_TILEGX_IMM16_X1_HW0_TLS_GD,
- BFD_RELOC_TILEGX_IMM16_X0_HW0_TLS_LE,
- BFD_RELOC_TILEGX_IMM16_X1_HW0_TLS_LE,
- BFD_RELOC_TILEGX_IMM16_X0_HW0_LAST_TLS_LE,
- BFD_RELOC_TILEGX_IMM16_X1_HW0_LAST_TLS_LE,
- BFD_RELOC_TILEGX_IMM16_X0_HW1_LAST_TLS_LE,
- BFD_RELOC_TILEGX_IMM16_X1_HW1_LAST_TLS_LE,
- BFD_RELOC_TILEGX_IMM16_X0_HW0_LAST_TLS_GD,
- BFD_RELOC_TILEGX_IMM16_X1_HW0_LAST_TLS_GD,
- BFD_RELOC_TILEGX_IMM16_X0_HW1_LAST_TLS_GD,
- BFD_RELOC_TILEGX_IMM16_X1_HW1_LAST_TLS_GD,
- BFD_RELOC_TILEGX_IMM16_X0_HW0_TLS_IE,
- BFD_RELOC_TILEGX_IMM16_X1_HW0_TLS_IE,
- BFD_RELOC_TILEGX_IMM16_X0_HW0_LAST_PLT_PCREL,
- BFD_RELOC_TILEGX_IMM16_X1_HW0_LAST_PLT_PCREL,
- BFD_RELOC_TILEGX_IMM16_X0_HW1_LAST_PLT_PCREL,
- BFD_RELOC_TILEGX_IMM16_X1_HW1_LAST_PLT_PCREL,
- BFD_RELOC_TILEGX_IMM16_X0_HW2_LAST_PLT_PCREL,
- BFD_RELOC_TILEGX_IMM16_X1_HW2_LAST_PLT_PCREL,
- BFD_RELOC_TILEGX_IMM16_X0_HW0_LAST_TLS_IE,
- BFD_RELOC_TILEGX_IMM16_X1_HW0_LAST_TLS_IE,
- BFD_RELOC_TILEGX_IMM16_X0_HW1_LAST_TLS_IE,
- BFD_RELOC_TILEGX_IMM16_X1_HW1_LAST_TLS_IE,
- BFD_RELOC_TILEGX_TLS_DTPMOD64,
- BFD_RELOC_TILEGX_TLS_DTPOFF64,
- BFD_RELOC_TILEGX_TLS_TPOFF64,
- BFD_RELOC_TILEGX_TLS_DTPMOD32,
- BFD_RELOC_TILEGX_TLS_DTPOFF32,
- BFD_RELOC_TILEGX_TLS_TPOFF32,
- BFD_RELOC_TILEGX_TLS_GD_CALL,
- BFD_RELOC_TILEGX_IMM8_X0_TLS_GD_ADD,
- BFD_RELOC_TILEGX_IMM8_X1_TLS_GD_ADD,
- BFD_RELOC_TILEGX_IMM8_Y0_TLS_GD_ADD,
- BFD_RELOC_TILEGX_IMM8_Y1_TLS_GD_ADD,
- BFD_RELOC_TILEGX_TLS_IE_LOAD,
- BFD_RELOC_TILEGX_IMM8_X0_TLS_ADD,
- BFD_RELOC_TILEGX_IMM8_X1_TLS_ADD,
- BFD_RELOC_TILEGX_IMM8_Y0_TLS_ADD,
- BFD_RELOC_TILEGX_IMM8_Y1_TLS_ADD,
-
- /* Linux eBPF relocations. */
- BFD_RELOC_BPF_64,
- BFD_RELOC_BPF_DISP32,
- BFD_RELOC_BPF_DISPCALL32,
- BFD_RELOC_BPF_DISP16,
-
- /* Adapteva EPIPHANY - 8 bit signed pc-relative displacement. */
- BFD_RELOC_EPIPHANY_SIMM8,
-
- /* Adapteva EPIPHANY - 24 bit signed pc-relative displacement. */
- BFD_RELOC_EPIPHANY_SIMM24,
-
- /* Adapteva EPIPHANY - 16 most-significant bits of absolute address. */
- BFD_RELOC_EPIPHANY_HIGH,
-
- /* Adapteva EPIPHANY - 16 least-significant bits of absolute address. */
- BFD_RELOC_EPIPHANY_LOW,
-
- /* Adapteva EPIPHANY - 11 bit signed number - add/sub immediate. */
- BFD_RELOC_EPIPHANY_SIMM11,
-
- /* Adapteva EPIPHANY - 11 bit sign-magnitude number (ld/st
- displacement). */
- BFD_RELOC_EPIPHANY_IMM11,
-
- /* Adapteva EPIPHANY - 8 bit immediate for 16 bit mov instruction. */
- BFD_RELOC_EPIPHANY_IMM8,
-
- /* Visium Relocations. */
- BFD_RELOC_VISIUM_HI16,
- BFD_RELOC_VISIUM_LO16,
- BFD_RELOC_VISIUM_IM16,
- BFD_RELOC_VISIUM_REL16,
- BFD_RELOC_VISIUM_HI16_PCREL,
- BFD_RELOC_VISIUM_LO16_PCREL,
- BFD_RELOC_VISIUM_IM16_PCREL,
-
- /* WebAssembly relocations. */
- BFD_RELOC_WASM32_LEB128,
- BFD_RELOC_WASM32_LEB128_GOT,
- BFD_RELOC_WASM32_LEB128_GOT_CODE,
- BFD_RELOC_WASM32_LEB128_PLT,
- BFD_RELOC_WASM32_PLT_INDEX,
- BFD_RELOC_WASM32_ABS32_CODE,
- BFD_RELOC_WASM32_COPY,
- BFD_RELOC_WASM32_CODE_POINTER,
- BFD_RELOC_WASM32_INDEX,
- BFD_RELOC_WASM32_PLT_SIG,
-
- /* C-SKY relocations. */
- BFD_RELOC_CKCORE_NONE,
- BFD_RELOC_CKCORE_ADDR32,
- BFD_RELOC_CKCORE_PCREL_IMM8BY4,
- BFD_RELOC_CKCORE_PCREL_IMM11BY2,
- BFD_RELOC_CKCORE_PCREL_IMM4BY2,
- BFD_RELOC_CKCORE_PCREL32,
- BFD_RELOC_CKCORE_PCREL_JSR_IMM11BY2,
- BFD_RELOC_CKCORE_GNU_VTINHERIT,
- BFD_RELOC_CKCORE_GNU_VTENTRY,
- BFD_RELOC_CKCORE_RELATIVE,
- BFD_RELOC_CKCORE_COPY,
- BFD_RELOC_CKCORE_GLOB_DAT,
- BFD_RELOC_CKCORE_JUMP_SLOT,
- BFD_RELOC_CKCORE_GOTOFF,
- BFD_RELOC_CKCORE_GOTPC,
- BFD_RELOC_CKCORE_GOT32,
- BFD_RELOC_CKCORE_PLT32,
- BFD_RELOC_CKCORE_ADDRGOT,
- BFD_RELOC_CKCORE_ADDRPLT,
- BFD_RELOC_CKCORE_PCREL_IMM26BY2,
- BFD_RELOC_CKCORE_PCREL_IMM16BY2,
- BFD_RELOC_CKCORE_PCREL_IMM16BY4,
- BFD_RELOC_CKCORE_PCREL_IMM10BY2,
- BFD_RELOC_CKCORE_PCREL_IMM10BY4,
- BFD_RELOC_CKCORE_ADDR_HI16,
- BFD_RELOC_CKCORE_ADDR_LO16,
- BFD_RELOC_CKCORE_GOTPC_HI16,
- BFD_RELOC_CKCORE_GOTPC_LO16,
- BFD_RELOC_CKCORE_GOTOFF_HI16,
- BFD_RELOC_CKCORE_GOTOFF_LO16,
- BFD_RELOC_CKCORE_GOT12,
- BFD_RELOC_CKCORE_GOT_HI16,
- BFD_RELOC_CKCORE_GOT_LO16,
- BFD_RELOC_CKCORE_PLT12,
- BFD_RELOC_CKCORE_PLT_HI16,
- BFD_RELOC_CKCORE_PLT_LO16,
- BFD_RELOC_CKCORE_ADDRGOT_HI16,
- BFD_RELOC_CKCORE_ADDRGOT_LO16,
- BFD_RELOC_CKCORE_ADDRPLT_HI16,
- BFD_RELOC_CKCORE_ADDRPLT_LO16,
- BFD_RELOC_CKCORE_PCREL_JSR_IMM26BY2,
- BFD_RELOC_CKCORE_TOFFSET_LO16,
- BFD_RELOC_CKCORE_DOFFSET_LO16,
- BFD_RELOC_CKCORE_PCREL_IMM18BY2,
- BFD_RELOC_CKCORE_DOFFSET_IMM18,
- BFD_RELOC_CKCORE_DOFFSET_IMM18BY2,
- BFD_RELOC_CKCORE_DOFFSET_IMM18BY4,
- BFD_RELOC_CKCORE_GOTOFF_IMM18,
- BFD_RELOC_CKCORE_GOT_IMM18BY4,
- BFD_RELOC_CKCORE_PLT_IMM18BY4,
- BFD_RELOC_CKCORE_PCREL_IMM7BY4,
- BFD_RELOC_CKCORE_TLS_LE32,
- BFD_RELOC_CKCORE_TLS_IE32,
- BFD_RELOC_CKCORE_TLS_GD32,
- BFD_RELOC_CKCORE_TLS_LDM32,
- BFD_RELOC_CKCORE_TLS_LDO32,
- BFD_RELOC_CKCORE_TLS_DTPMOD32,
- BFD_RELOC_CKCORE_TLS_DTPOFF32,
- BFD_RELOC_CKCORE_TLS_TPOFF32,
- BFD_RELOC_CKCORE_PCREL_FLRW_IMM8BY4,
- BFD_RELOC_CKCORE_NOJSRI,
- BFD_RELOC_CKCORE_CALLGRAPH,
- BFD_RELOC_CKCORE_IRELATIVE,
- BFD_RELOC_CKCORE_PCREL_BLOOP_IMM4BY4,
- BFD_RELOC_CKCORE_PCREL_BLOOP_IMM12BY4,
-
- /* S12Z relocations. */
- BFD_RELOC_S12Z_OPR,
-
- /* LARCH relocations. */
- BFD_RELOC_LARCH_TLS_DTPMOD32,
- BFD_RELOC_LARCH_TLS_DTPREL32,
- BFD_RELOC_LARCH_TLS_DTPMOD64,
- BFD_RELOC_LARCH_TLS_DTPREL64,
- BFD_RELOC_LARCH_TLS_TPREL32,
- BFD_RELOC_LARCH_TLS_TPREL64,
- BFD_RELOC_LARCH_TLS_DESC32,
- BFD_RELOC_LARCH_TLS_DESC64,
- BFD_RELOC_LARCH_MARK_LA,
- BFD_RELOC_LARCH_MARK_PCREL,
- BFD_RELOC_LARCH_SOP_PUSH_PCREL,
- BFD_RELOC_LARCH_SOP_PUSH_ABSOLUTE,
- BFD_RELOC_LARCH_SOP_PUSH_DUP,
- BFD_RELOC_LARCH_SOP_PUSH_GPREL,
- BFD_RELOC_LARCH_SOP_PUSH_TLS_TPREL,
- BFD_RELOC_LARCH_SOP_PUSH_TLS_GOT,
- BFD_RELOC_LARCH_SOP_PUSH_TLS_GD,
- BFD_RELOC_LARCH_SOP_PUSH_PLT_PCREL,
- BFD_RELOC_LARCH_SOP_ASSERT,
- BFD_RELOC_LARCH_SOP_NOT,
- BFD_RELOC_LARCH_SOP_SUB,
- BFD_RELOC_LARCH_SOP_SL,
- BFD_RELOC_LARCH_SOP_SR,
- BFD_RELOC_LARCH_SOP_ADD,
- BFD_RELOC_LARCH_SOP_AND,
- BFD_RELOC_LARCH_SOP_IF_ELSE,
- BFD_RELOC_LARCH_SOP_POP_32_S_10_5,
- BFD_RELOC_LARCH_SOP_POP_32_U_10_12,
- BFD_RELOC_LARCH_SOP_POP_32_S_10_12,
- BFD_RELOC_LARCH_SOP_POP_32_S_10_16,
- BFD_RELOC_LARCH_SOP_POP_32_S_10_16_S2,
- BFD_RELOC_LARCH_SOP_POP_32_S_5_20,
- BFD_RELOC_LARCH_SOP_POP_32_S_0_5_10_16_S2,
- BFD_RELOC_LARCH_SOP_POP_32_S_0_10_10_16_S2,
- BFD_RELOC_LARCH_SOP_POP_32_U,
- BFD_RELOC_LARCH_ADD8,
- BFD_RELOC_LARCH_ADD16,
- BFD_RELOC_LARCH_ADD24,
- BFD_RELOC_LARCH_ADD32,
- BFD_RELOC_LARCH_ADD64,
- BFD_RELOC_LARCH_SUB8,
- BFD_RELOC_LARCH_SUB16,
- BFD_RELOC_LARCH_SUB24,
- BFD_RELOC_LARCH_SUB32,
- BFD_RELOC_LARCH_SUB64,
- BFD_RELOC_LARCH_B16,
- BFD_RELOC_LARCH_B21,
- BFD_RELOC_LARCH_B26,
- BFD_RELOC_LARCH_ABS_HI20,
- BFD_RELOC_LARCH_ABS_LO12,
- BFD_RELOC_LARCH_ABS64_LO20,
- BFD_RELOC_LARCH_ABS64_HI12,
- BFD_RELOC_LARCH_PCALA_HI20,
- BFD_RELOC_LARCH_PCALA_LO12,
- BFD_RELOC_LARCH_PCALA64_LO20,
- BFD_RELOC_LARCH_PCALA64_HI12,
- BFD_RELOC_LARCH_GOT_PC_HI20,
- BFD_RELOC_LARCH_GOT_PC_LO12,
- BFD_RELOC_LARCH_GOT64_PC_LO20,
- BFD_RELOC_LARCH_GOT64_PC_HI12,
- BFD_RELOC_LARCH_GOT_HI20,
- BFD_RELOC_LARCH_GOT_LO12,
- BFD_RELOC_LARCH_GOT64_LO20,
- BFD_RELOC_LARCH_GOT64_HI12,
- BFD_RELOC_LARCH_TLS_LE_HI20,
- BFD_RELOC_LARCH_TLS_LE_LO12,
- BFD_RELOC_LARCH_TLS_LE64_LO20,
- BFD_RELOC_LARCH_TLS_LE64_HI12,
- BFD_RELOC_LARCH_TLS_IE_PC_HI20,
- BFD_RELOC_LARCH_TLS_IE_PC_LO12,
- BFD_RELOC_LARCH_TLS_IE64_PC_LO20,
- BFD_RELOC_LARCH_TLS_IE64_PC_HI12,
- BFD_RELOC_LARCH_TLS_IE_HI20,
- BFD_RELOC_LARCH_TLS_IE_LO12,
- BFD_RELOC_LARCH_TLS_IE64_LO20,
- BFD_RELOC_LARCH_TLS_IE64_HI12,
- BFD_RELOC_LARCH_TLS_LD_PC_HI20,
- BFD_RELOC_LARCH_TLS_LD_HI20,
- BFD_RELOC_LARCH_TLS_GD_PC_HI20,
- BFD_RELOC_LARCH_TLS_GD_HI20,
- BFD_RELOC_LARCH_32_PCREL,
- BFD_RELOC_LARCH_RELAX,
- BFD_RELOC_LARCH_DELETE,
- BFD_RELOC_LARCH_ALIGN,
- BFD_RELOC_LARCH_PCREL20_S2,
- BFD_RELOC_LARCH_CFA,
- BFD_RELOC_LARCH_ADD6,
- BFD_RELOC_LARCH_SUB6,
- BFD_RELOC_LARCH_ADD_ULEB128,
- BFD_RELOC_LARCH_SUB_ULEB128,
- BFD_RELOC_LARCH_64_PCREL,
- BFD_RELOC_LARCH_CALL36,
- BFD_RELOC_LARCH_TLS_DESC_PC_HI20,
- BFD_RELOC_LARCH_TLS_DESC_PC_LO12,
- BFD_RELOC_LARCH_TLS_DESC64_PC_LO20,
- BFD_RELOC_LARCH_TLS_DESC64_PC_HI12,
- BFD_RELOC_LARCH_TLS_DESC_HI20,
- BFD_RELOC_LARCH_TLS_DESC_LO12,
- BFD_RELOC_LARCH_TLS_DESC64_LO20,
- BFD_RELOC_LARCH_TLS_DESC64_HI12,
- BFD_RELOC_LARCH_TLS_DESC_LD,
- BFD_RELOC_LARCH_TLS_DESC_CALL,
- BFD_RELOC_LARCH_TLS_LE_HI20_R,
- BFD_RELOC_LARCH_TLS_LE_ADD_R,
- BFD_RELOC_LARCH_TLS_LE_LO12_R,
- BFD_RELOC_LARCH_TLS_LD_PCREL20_S2,
- BFD_RELOC_LARCH_TLS_GD_PCREL20_S2,
- BFD_RELOC_LARCH_TLS_DESC_PCREL20_S2,
- BFD_RELOC_UNUSED
-};
-typedef enum bfd_reloc_code_real bfd_reloc_code_real_type;
-
-reloc_howto_type *bfd_reloc_type_lookup
- (bfd *abfd, bfd_reloc_code_real_type code);
-reloc_howto_type *bfd_reloc_name_lookup
- (bfd *abfd, const char *reloc_name);
-
-const char *bfd_get_reloc_code_name (bfd_reloc_code_real_type code);
-
-/* Extracted from simple.c. */
-bfd_byte *bfd_simple_get_relocated_section_contents
- (bfd *abfd, asection *sec, bfd_byte *outbuf, asymbol **symbol_table);
-
-/* Extracted from stab-syms.c. */
-const char *bfd_get_stab_name (int);
-
-/* Extracted from stabs.c. */
-/* This structure is used to keep track of stabs in sections
- information while linking. */
-
-struct stab_info
-{
- /* A hash table used to hold stabs strings. */
- struct bfd_strtab_hash *strings;
- /* The header file hash table. */
- struct bfd_hash_table includes;
- /* The first .stabstr section. */
- struct bfd_section *stabstr;
-};
-
-/* Extracted from targets.c. */
-#define BFD_SEND(bfd, message, arglist) \
- ((*((bfd)->xvec->message)) arglist)
-
-#ifdef DEBUG_BFD_SEND
-#undef BFD_SEND
-#define BFD_SEND(bfd, message, arglist) \
- (((bfd) && (bfd)->xvec && (bfd)->xvec->message) ? \
- ((*((bfd)->xvec->message)) arglist) : \
- (bfd_assert (__FILE__,__LINE__), NULL))
-#endif
-#define BFD_SEND_FMT(bfd, message, arglist) \
- (((bfd)->xvec->message[(int) ((bfd)->format)]) arglist)
-
-#ifdef DEBUG_BFD_SEND
-#undef BFD_SEND_FMT
-#define BFD_SEND_FMT(bfd, message, arglist) \
- (((bfd) && (bfd)->xvec && (bfd)->xvec->message) ? \
- (((bfd)->xvec->message[(int) ((bfd)->format)]) arglist) : \
- (bfd_assert (__FILE__,__LINE__), NULL))
-#endif
-
-/* Defined to TRUE if unused section symbol should be kept. */
-#ifndef TARGET_KEEP_UNUSED_SECTION_SYMBOLS
-#define TARGET_KEEP_UNUSED_SECTION_SYMBOLS true
-#endif
-
-enum bfd_flavour
-{
- /* N.B. Update bfd_flavour_name if you change this. */
- bfd_target_unknown_flavour,
- bfd_target_aout_flavour,
- bfd_target_coff_flavour,
- bfd_target_ecoff_flavour,
- bfd_target_xcoff_flavour,
- bfd_target_elf_flavour,
- bfd_target_tekhex_flavour,
- bfd_target_srec_flavour,
- bfd_target_verilog_flavour,
- bfd_target_ihex_flavour,
- bfd_target_som_flavour,
- bfd_target_msdos_flavour,
- bfd_target_evax_flavour,
- bfd_target_mmo_flavour,
- bfd_target_mach_o_flavour,
- bfd_target_pef_flavour,
- bfd_target_pef_xlib_flavour,
- bfd_target_sym_flavour
-};
-
-enum bfd_endian { BFD_ENDIAN_BIG, BFD_ENDIAN_LITTLE, BFD_ENDIAN_UNKNOWN };
-
-/* Forward declarations. */
-struct flag_info;
-typedef void (*bfd_cleanup) (bfd *);
-
-typedef struct bfd_target
-{
- /* Identifies the kind of target, e.g., SunOS4, Ultrix, etc. */
- const char *name;
-
- /* The "flavour" of a back end is a general indication about
- the contents of a file. */
- enum bfd_flavour flavour;
-
- /* The order of bytes within the data area of a file. */
- enum bfd_endian byteorder;
-
- /* The order of bytes within the header parts of a file. */
- enum bfd_endian header_byteorder;
-
- /* A mask of all the flags which an executable may have set -
- from the set <<BFD_NO_FLAGS>>, <<HAS_RELOC>>, ...<<D_PAGED>>. */
- flagword object_flags;
-
- /* A mask of all the flags which a section may have set - from
- the set <<SEC_NO_FLAGS>>, <<SEC_ALLOC>>, ...<<SET_NEVER_LOAD>>. */
- flagword section_flags;
-
- /* The character normally found at the front of a symbol.
- (if any), perhaps `_'. */
- char symbol_leading_char;
-
- /* The pad character for file names within an archive header. */
- char ar_pad_char;
-
- /* The maximum number of characters in an archive header. */
- unsigned char ar_max_namelen;
-
- /* How well this target matches, used to select between various
- possible targets when more than one target matches. */
- unsigned char match_priority;
-
- /* TRUE if unused section symbols should be kept. */
- bool keep_unused_section_symbols;
-
- /* Entries for byte swapping for data. These are different from the
- other entry points, since they don't take a BFD as the first argument.
- Certain other handlers could do the same. */
- uint64_t (*bfd_getx64) (const void *);
- int64_t (*bfd_getx_signed_64) (const void *);
- void (*bfd_putx64) (uint64_t, void *);
- bfd_vma (*bfd_getx32) (const void *);
- bfd_signed_vma (*bfd_getx_signed_32) (const void *);
- void (*bfd_putx32) (bfd_vma, void *);
- bfd_vma (*bfd_getx16) (const void *);
- bfd_signed_vma (*bfd_getx_signed_16) (const void *);
- void (*bfd_putx16) (bfd_vma, void *);
-
- /* Byte swapping for the headers. */
- uint64_t (*bfd_h_getx64) (const void *);
- int64_t (*bfd_h_getx_signed_64) (const void *);
- void (*bfd_h_putx64) (uint64_t, void *);
- bfd_vma (*bfd_h_getx32) (const void *);
- bfd_signed_vma (*bfd_h_getx_signed_32) (const void *);
- void (*bfd_h_putx32) (bfd_vma, void *);
- bfd_vma (*bfd_h_getx16) (const void *);
- bfd_signed_vma (*bfd_h_getx_signed_16) (const void *);
- void (*bfd_h_putx16) (bfd_vma, void *);
-
- /* Format dependent routines: these are vectors of entry points
- within the target vector structure, one for each format to check. */
-
- /* Check the format of a file being read. Return a <<bfd_cleanup>> on
- success or zero on failure. */
- bfd_cleanup (*_bfd_check_format[bfd_type_end]) (bfd *);
-
- /* Set the format of a file being written. */
- bool (*_bfd_set_format[bfd_type_end]) (bfd *);
-
- /* Write cached information into a file being written, at <<bfd_close>>. */
- bool (*_bfd_write_contents[bfd_type_end]) (bfd *);
-
- /* Generic entry points. */
-#define BFD_JUMP_TABLE_GENERIC(NAME) \
- NAME##_close_and_cleanup, \
- NAME##_bfd_free_cached_info, \
- NAME##_new_section_hook, \
- NAME##_get_section_contents
-
- /* Called when the BFD is being closed to do any necessary cleanup. */
- bool (*_close_and_cleanup) (bfd *);
- /* Ask the BFD to free all cached information. */
- bool (*_bfd_free_cached_info) (bfd *);
- /* Called when a new section is created. */
- bool (*_new_section_hook) (bfd *, sec_ptr);
- /* Read the contents of a section. */
- bool (*_bfd_get_section_contents) (bfd *, sec_ptr, void *, file_ptr,
- bfd_size_type);
-
- /* Entry points to copy private data. */
-#define BFD_JUMP_TABLE_COPY(NAME) \
- NAME##_bfd_copy_private_bfd_data, \
- NAME##_bfd_merge_private_bfd_data, \
- NAME##_init_private_section_data, \
- NAME##_bfd_copy_private_section_data, \
- NAME##_bfd_copy_private_symbol_data, \
- NAME##_bfd_copy_private_header_data, \
- NAME##_bfd_set_private_flags, \
- NAME##_bfd_print_private_bfd_data
-
- /* Called to copy BFD general private data from one object file
- to another. */
- bool (*_bfd_copy_private_bfd_data) (bfd *, bfd *);
- /* Called to merge BFD general private data from one object file
- to a common output file when linking. */
- bool (*_bfd_merge_private_bfd_data) (bfd *, struct bfd_link_info *);
- /* Called to initialize BFD private section data from one object file
- to another. */
-#define bfd_init_private_section_data(ibfd, isec, obfd, osec, link_info) \
- BFD_SEND (obfd, _bfd_init_private_section_data, \
- (ibfd, isec, obfd, osec, link_info))
- bool (*_bfd_init_private_section_data) (bfd *, sec_ptr, bfd *, sec_ptr,
- struct bfd_link_info *);
- /* Called to copy BFD private section data from one object file
- to another. */
- bool (*_bfd_copy_private_section_data) (bfd *, sec_ptr, bfd *, sec_ptr);
- /* Called to copy BFD private symbol data from one symbol
- to another. */
- bool (*_bfd_copy_private_symbol_data) (bfd *, asymbol *,
- bfd *, asymbol *);
- /* Called to copy BFD private header data from one object file
- to another. */
- bool (*_bfd_copy_private_header_data) (bfd *, bfd *);
- /* Called to set private backend flags. */
- bool (*_bfd_set_private_flags) (bfd *, flagword);
-
- /* Called to print private BFD data. */
- bool (*_bfd_print_private_bfd_data) (bfd *, void *);
-
- /* Core file entry points. */
-#define BFD_JUMP_TABLE_CORE(NAME) \
- NAME##_core_file_failing_command, \
- NAME##_core_file_failing_signal, \
- NAME##_core_file_matches_executable_p, \
- NAME##_core_file_pid
-
- char *(*_core_file_failing_command) (bfd *);
- int (*_core_file_failing_signal) (bfd *);
- bool (*_core_file_matches_executable_p) (bfd *, bfd *);
- int (*_core_file_pid) (bfd *);
-
- /* Archive entry points. */
-#define BFD_JUMP_TABLE_ARCHIVE(NAME) \
- NAME##_slurp_armap, \
- NAME##_slurp_extended_name_table, \
- NAME##_construct_extended_name_table, \
- NAME##_truncate_arname, \
- NAME##_write_armap, \
- NAME##_read_ar_hdr, \
- NAME##_write_ar_hdr, \
- NAME##_openr_next_archived_file, \
- NAME##_get_elt_at_index, \
- NAME##_generic_stat_arch_elt, \
- NAME##_update_armap_timestamp
-
- bool (*_bfd_slurp_armap) (bfd *);
- bool (*_bfd_slurp_extended_name_table) (bfd *);
- bool (*_bfd_construct_extended_name_table) (bfd *, char **,
- bfd_size_type *,
- const char **);
- void (*_bfd_truncate_arname) (bfd *, const char *, char *);
- bool (*write_armap) (bfd *, unsigned, struct orl *, unsigned, int);
- void *(*_bfd_read_ar_hdr_fn) (bfd *);
- bool (*_bfd_write_ar_hdr_fn) (bfd *, bfd *);
- bfd *(*openr_next_archived_file) (bfd *, bfd *);
-#define bfd_get_elt_at_index(b,i) \
- BFD_SEND (b, _bfd_get_elt_at_index, (b,i))
- bfd *(*_bfd_get_elt_at_index) (bfd *, symindex);
- int (*_bfd_stat_arch_elt) (bfd *, struct stat *);
- bool (*_bfd_update_armap_timestamp) (bfd *);
-
- /* Entry points used for symbols. */
-#define BFD_JUMP_TABLE_SYMBOLS(NAME) \
- NAME##_get_symtab_upper_bound, \
- NAME##_canonicalize_symtab, \
- NAME##_make_empty_symbol, \
- NAME##_print_symbol, \
- NAME##_get_symbol_info, \
- NAME##_get_symbol_version_string, \
- NAME##_bfd_is_local_label_name, \
- NAME##_bfd_is_target_special_symbol, \
- NAME##_get_lineno, \
- NAME##_find_nearest_line, \
- NAME##_find_nearest_line_with_alt, \
- NAME##_find_line, \
- NAME##_find_inliner_info, \
- NAME##_bfd_make_debug_symbol, \
- NAME##_read_minisymbols, \
- NAME##_minisymbol_to_symbol
-
- long (*_bfd_get_symtab_upper_bound) (bfd *);
- long (*_bfd_canonicalize_symtab) (bfd *, struct bfd_symbol **);
- struct bfd_symbol *
- (*_bfd_make_empty_symbol) (bfd *);
- void (*_bfd_print_symbol) (bfd *, void *, struct bfd_symbol *,
- bfd_print_symbol_type);
-#define bfd_print_symbol(b,p,s,e) \
- BFD_SEND (b, _bfd_print_symbol, (b,p,s,e))
- void (*_bfd_get_symbol_info) (bfd *, struct bfd_symbol *, symbol_info *);
-#define bfd_get_symbol_info(b,p,e) \
- BFD_SEND (b, _bfd_get_symbol_info, (b,p,e))
- const char *
- (*_bfd_get_symbol_version_string) (bfd *, struct bfd_symbol *,
- bool, bool *);
-#define bfd_get_symbol_version_string(b,s,p,h) \
- BFD_SEND (b, _bfd_get_symbol_version_string, (b,s,p,h))
- bool (*_bfd_is_local_label_name) (bfd *, const char *);
- bool (*_bfd_is_target_special_symbol) (bfd *, asymbol *);
- alent *
- (*_get_lineno) (bfd *, struct bfd_symbol *);
- bool (*_bfd_find_nearest_line) (bfd *, struct bfd_symbol **,
- struct bfd_section *, bfd_vma,
- const char **, const char **,
- unsigned int *, unsigned int *);
- bool (*_bfd_find_nearest_line_with_alt) (bfd *, const char *,
- struct bfd_symbol **,
- struct bfd_section *, bfd_vma,
- const char **, const char **,
- unsigned int *, unsigned int *);
- bool (*_bfd_find_line) (bfd *, struct bfd_symbol **,
- struct bfd_symbol *, const char **,
- unsigned int *);
- bool (*_bfd_find_inliner_info)
- (bfd *, const char **, const char **, unsigned int *);
- /* Back-door to allow format-aware applications to create debug symbols
- while using BFD for everything else. Currently used by the assembler
- when creating COFF files. */
- asymbol *
- (*_bfd_make_debug_symbol) (bfd *);
-#define bfd_read_minisymbols(b, d, m, s) \
- BFD_SEND (b, _read_minisymbols, (b, d, m, s))
- long (*_read_minisymbols) (bfd *, bool, void **, unsigned int *);
-#define bfd_minisymbol_to_symbol(b, d, m, f) \
- BFD_SEND (b, _minisymbol_to_symbol, (b, d, m, f))
- asymbol *
- (*_minisymbol_to_symbol) (bfd *, bool, const void *, asymbol *);
-
- /* Routines for relocs. */
-#define BFD_JUMP_TABLE_RELOCS(NAME) \
- NAME##_get_reloc_upper_bound, \
- NAME##_canonicalize_reloc, \
- NAME##_set_reloc, \
- NAME##_bfd_reloc_type_lookup, \
- NAME##_bfd_reloc_name_lookup
-
- long (*_get_reloc_upper_bound) (bfd *, sec_ptr);
- long (*_bfd_canonicalize_reloc) (bfd *, sec_ptr, arelent **,
- struct bfd_symbol **);
- void (*_bfd_set_reloc) (bfd *, sec_ptr, arelent **, unsigned int);
- /* See documentation on reloc types. */
- reloc_howto_type *
- (*reloc_type_lookup) (bfd *, bfd_reloc_code_real_type);
- reloc_howto_type *
- (*reloc_name_lookup) (bfd *, const char *);
-
- /* Routines used when writing an object file. */
-#define BFD_JUMP_TABLE_WRITE(NAME) \
- NAME##_set_arch_mach, \
- NAME##_set_section_contents
-
- bool (*_bfd_set_arch_mach) (bfd *, enum bfd_architecture,
- unsigned long);
- bool (*_bfd_set_section_contents) (bfd *, sec_ptr, const void *,
- file_ptr, bfd_size_type);
-
- /* Routines used by the linker. */
-#define BFD_JUMP_TABLE_LINK(NAME) \
- NAME##_sizeof_headers, \
- NAME##_bfd_get_relocated_section_contents, \
- NAME##_bfd_relax_section, \
- NAME##_bfd_link_hash_table_create, \
- NAME##_bfd_link_add_symbols, \
- NAME##_bfd_link_just_syms, \
- NAME##_bfd_copy_link_hash_symbol_type, \
- NAME##_bfd_final_link, \
- NAME##_bfd_link_split_section, \
- NAME##_bfd_link_check_relocs, \
- NAME##_bfd_gc_sections, \
- NAME##_bfd_lookup_section_flags, \
- NAME##_bfd_merge_sections, \
- NAME##_bfd_is_group_section, \
- NAME##_bfd_group_name, \
- NAME##_bfd_discard_group, \
- NAME##_section_already_linked, \
- NAME##_bfd_define_common_symbol, \
- NAME##_bfd_link_hide_symbol, \
- NAME##_bfd_define_start_stop
-
- int (*_bfd_sizeof_headers) (bfd *, struct bfd_link_info *);
- bfd_byte *
- (*_bfd_get_relocated_section_contents) (bfd *,
- struct bfd_link_info *,
- struct bfd_link_order *,
- bfd_byte *, bool,
- struct bfd_symbol **);
-
- bool (*_bfd_relax_section) (bfd *, struct bfd_section *,
- struct bfd_link_info *, bool *);
-
- /* Create a hash table for the linker. Different backends store
- different information in this table. */
- struct bfd_link_hash_table *
- (*_bfd_link_hash_table_create) (bfd *);
-
- /* Add symbols from this object file into the hash table. */
- bool (*_bfd_link_add_symbols) (bfd *, struct bfd_link_info *);
-
- /* Indicate that we are only retrieving symbol values from this section. */
- void (*_bfd_link_just_syms) (asection *, struct bfd_link_info *);
-
- /* Copy the symbol type and other attributes for a linker script
- assignment of one symbol to another. */
-#define bfd_copy_link_hash_symbol_type(b, t, f) \
- BFD_SEND (b, _bfd_copy_link_hash_symbol_type, (b, t, f))
- void (*_bfd_copy_link_hash_symbol_type) (bfd *,
- struct bfd_link_hash_entry *,
- struct bfd_link_hash_entry *);
-
- /* Do a link based on the link_order structures attached to each
- section of the BFD. */
- bool (*_bfd_final_link) (bfd *, struct bfd_link_info *);
-
- /* Should this section be split up into smaller pieces during linking. */
- bool (*_bfd_link_split_section) (bfd *, struct bfd_section *);
-
- /* Check the relocations in the bfd for validity. */
- bool (* _bfd_link_check_relocs)(bfd *, struct bfd_link_info *);
-
- /* Remove sections that are not referenced from the output. */
- bool (*_bfd_gc_sections) (bfd *, struct bfd_link_info *);
-
- /* Sets the bitmask of allowed and disallowed section flags. */
- bool (*_bfd_lookup_section_flags) (struct bfd_link_info *,
- struct flag_info *, asection *);
-
- /* Attempt to merge SEC_MERGE sections. */
- bool (*_bfd_merge_sections) (bfd *, struct bfd_link_info *);
-
- /* Is this section a member of a group? */
- bool (*_bfd_is_group_section) (bfd *, const struct bfd_section *);
-
- /* The group name, if section is a member of a group. */
- const char *(*_bfd_group_name) (bfd *, const struct bfd_section *);
-
- /* Discard members of a group. */
- bool (*_bfd_discard_group) (bfd *, struct bfd_section *);
-
- /* Check if SEC has been already linked during a reloceatable or
- final link. */
- bool (*_section_already_linked) (bfd *, asection *,
- struct bfd_link_info *);
-
- /* Define a common symbol. */
- bool (*_bfd_define_common_symbol) (bfd *, struct bfd_link_info *,
- struct bfd_link_hash_entry *);
-
- /* Hide a symbol. */
- void (*_bfd_link_hide_symbol) (bfd *, struct bfd_link_info *,
- struct bfd_link_hash_entry *);
-
- /* Define a __start, __stop, .startof. or .sizeof. symbol. */
- struct bfd_link_hash_entry *
- (*_bfd_define_start_stop) (struct bfd_link_info *, const char *,
- asection *);
-
- /* Routines to handle dynamic symbols and relocs. */
-#define BFD_JUMP_TABLE_DYNAMIC(NAME) \
- NAME##_get_dynamic_symtab_upper_bound, \
- NAME##_canonicalize_dynamic_symtab, \
- NAME##_get_synthetic_symtab, \
- NAME##_get_dynamic_reloc_upper_bound, \
- NAME##_canonicalize_dynamic_reloc
-
- /* Get the amount of memory required to hold the dynamic symbols. */
- long (*_bfd_get_dynamic_symtab_upper_bound) (bfd *);
- /* Read in the dynamic symbols. */
- long (*_bfd_canonicalize_dynamic_symtab) (bfd *, struct bfd_symbol **);
- /* Create synthetized symbols. */
- long (*_bfd_get_synthetic_symtab) (bfd *, long, struct bfd_symbol **,
- long, struct bfd_symbol **,
- struct bfd_symbol **);
- /* Get the amount of memory required to hold the dynamic relocs. */
- long (*_bfd_get_dynamic_reloc_upper_bound) (bfd *);
- /* Read in the dynamic relocs. */
- long (*_bfd_canonicalize_dynamic_reloc) (bfd *, arelent **,
- struct bfd_symbol **);
-
- /* Opposite endian version of this target. */
- const struct bfd_target *alternative_target;
-
- /* Data for use by back-end routines, which isn't
- generic enough to belong in this structure. */
- const void *backend_data;
-
-} bfd_target;
-
-static inline const char *
-bfd_get_target (const bfd *abfd)
-{
- return abfd->xvec->name;
-}
-
-static inline enum bfd_flavour
-bfd_get_flavour (const bfd *abfd)
-{
- return abfd->xvec->flavour;
-}
-
-static inline flagword
-bfd_applicable_file_flags (const bfd *abfd)
-{
- return abfd->xvec->object_flags;
-}
-
-static inline bool
-bfd_family_coff (const bfd *abfd)
-{
- return (bfd_get_flavour (abfd) == bfd_target_coff_flavour
- || bfd_get_flavour (abfd) == bfd_target_xcoff_flavour);
-}
-
-static inline bool
-bfd_big_endian (const bfd *abfd)
-{
- return abfd->xvec->byteorder == BFD_ENDIAN_BIG;
-}
-static inline bool
-bfd_little_endian (const bfd *abfd)
-{
- return abfd->xvec->byteorder == BFD_ENDIAN_LITTLE;
-}
-
-static inline bool
-bfd_header_big_endian (const bfd *abfd)
-{
- return abfd->xvec->header_byteorder == BFD_ENDIAN_BIG;
-}
-
-static inline bool
-bfd_header_little_endian (const bfd *abfd)
-{
- return abfd->xvec->header_byteorder == BFD_ENDIAN_LITTLE;
-}
-
-static inline flagword
-bfd_applicable_section_flags (const bfd *abfd)
-{
- return abfd->xvec->section_flags;
-}
-
-static inline char
-bfd_get_symbol_leading_char (const bfd *abfd)
-{
- return abfd->xvec->symbol_leading_char;
-}
-
-static inline enum bfd_flavour
-bfd_asymbol_flavour (const asymbol *sy)
-{
- if ((sy->flags & BSF_SYNTHETIC) != 0)
- return bfd_target_unknown_flavour;
- return sy->the_bfd->xvec->flavour;
-}
-
-static inline bool
-bfd_keep_unused_section_symbols (const bfd *abfd)
-{
- return abfd->xvec->keep_unused_section_symbols;
-}
-
-bool bfd_set_default_target (const char *name);
-
-const bfd_target *bfd_find_target (const char *target_name, bfd *abfd);
-
-const bfd_target *bfd_get_target_info (const char *target_name,
- bfd *abfd,
- bool *is_bigendian,
- int *underscoring,
- const char **def_target_arch);
-
-const char ** bfd_target_list (void);
-
-const bfd_target *bfd_iterate_over_targets
- (int (*func) (const bfd_target *, void *),
- void *data);
-
-const char *bfd_flavour_name (enum bfd_flavour flavour);
-
-#ifdef __cplusplus
-}
-#endif
-#endif
Index: sources/GNU/binutils/create-2.43.1-not-link-static-libstdc++-patch/file.list
===================================================================
--- sources/GNU/binutils/create-2.43.1-not-link-static-libstdc++-patch/file.list (revision 75)
+++ sources/GNU/binutils/create-2.43.1-not-link-static-libstdc++-patch/file.list (nonexistent)
@@ -1,2 +0,0 @@
-binutils-2.43.1/configure
-binutils-2.43.1/configure.ac
Index: sources/GNU/binutils/create-2.43.1-not-link-static-libstdc++-patch/create.patch.sh
===================================================================
--- sources/GNU/binutils/create-2.43.1-not-link-static-libstdc++-patch/create.patch.sh (revision 75)
+++ sources/GNU/binutils/create-2.43.1-not-link-static-libstdc++-patch/create.patch.sh (nonexistent)
@@ -1,15 +0,0 @@
-#!/bin/bash
-
-VERSION=2.43.1
-
-tar --files-from=file.list -xJvf ../binutils-$VERSION.tar.xz
-mv binutils-$VERSION binutils-$VERSION-orig
-
-cp -rf ./binutils-$VERSION-new ./binutils-$VERSION
-
-diff --unified -Nr binutils-$VERSION-orig binutils-$VERSION > binutils-$VERSION-not-link-static-libstdc++.patch
-
-mv binutils-$VERSION-not-link-static-libstdc++.patch ../patches
-
-rm -rf ./binutils-$VERSION
-rm -rf ./binutils-$VERSION-orig
Property changes on: sources/GNU/binutils/create-2.43.1-not-link-static-libstdc++-patch/create.patch.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: sources/GNU/binutils/create-2.43.1-not-link-static-libstdc++-patch/binutils-2.43.1-new/configure
===================================================================
--- sources/GNU/binutils/create-2.43.1-not-link-static-libstdc++-patch/binutils-2.43.1-new/configure (revision 75)
+++ sources/GNU/binutils/create-2.43.1-not-link-static-libstdc++-patch/binutils-2.43.1-new/configure (nonexistent)
@@ -1,20101 +0,0 @@
-#! /bin/sh
-# Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.69.
-#
-#
-# Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc.
-#
-#
-# This configure script is free software; the Free Software Foundation
-# gives unlimited permission to copy, distribute and modify it.
-## -------------------- ##
-## M4sh Initialization. ##
-## -------------------- ##
-
-# Be more Bourne compatible
-DUALCASE=1; export DUALCASE # for MKS sh
-if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
- emulate sh
- NULLCMD=:
- # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
- # is contrary to our usage. Disable this feature.
- alias -g '${1+"$@"}'='"$@"'
- setopt NO_GLOB_SUBST
-else
- case `(set -o) 2>/dev/null` in #(
- *posix*) :
- set -o posix ;; #(
- *) :
- ;;
-esac
-fi
-
-
-as_nl='
-'
-export as_nl
-# Printing a long string crashes Solaris 7 /usr/bin/printf.
-as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
-as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
-as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
-# Prefer a ksh shell builtin over an external printf program on Solaris,
-# but without wasting forks for bash or zsh.
-if test -z "$BASH_VERSION$ZSH_VERSION" \
- && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
- as_echo='print -r --'
- as_echo_n='print -rn --'
-elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
- as_echo='printf %s\n'
- as_echo_n='printf %s'
-else
- if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
- as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
- as_echo_n='/usr/ucb/echo -n'
- else
- as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
- as_echo_n_body='eval
- arg=$1;
- case $arg in #(
- *"$as_nl"*)
- expr "X$arg" : "X\\(.*\\)$as_nl";
- arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
- esac;
- expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
- '
- export as_echo_n_body
- as_echo_n='sh -c $as_echo_n_body as_echo'
- fi
- export as_echo_body
- as_echo='sh -c $as_echo_body as_echo'
-fi
-
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- PATH_SEPARATOR=:
- (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
- (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
- PATH_SEPARATOR=';'
- }
-fi
-
-
-# IFS
-# We need space, tab and new line, in precisely that order. Quoting is
-# there to prevent editors from complaining about space-tab.
-# (If _AS_PATH_WALK were called with IFS unset, it would disable word
-# splitting by setting IFS to empty value.)
-IFS=" "" $as_nl"
-
-# Find who we are. Look in the path if we contain no directory separator.
-as_myself=
-case $0 in #((
- *[\\/]* ) as_myself=$0 ;;
- *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
- done
-IFS=$as_save_IFS
-
- ;;
-esac
-# We did not find ourselves, most probably we were run as `sh COMMAND'
-# in which case we are not to be found in the path.
-if test "x$as_myself" = x; then
- as_myself=$0
-fi
-if test ! -f "$as_myself"; then
- $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
- exit 1
-fi
-
-# Unset variables that we do not need and which cause bugs (e.g. in
-# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
-# suppresses any "Segmentation fault" message there. '((' could
-# trigger a bug in pdksh 5.2.14.
-for as_var in BASH_ENV ENV MAIL MAILPATH
-do eval test x\${$as_var+set} = xset \
- && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
-done
-PS1='$ '
-PS2='> '
-PS4='+ '
-
-# NLS nuisances.
-LC_ALL=C
-export LC_ALL
-LANGUAGE=C
-export LANGUAGE
-
-# CDPATH.
-(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
-
-# Use a proper internal environment variable to ensure we don't fall
- # into an infinite loop, continuously re-executing ourselves.
- if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then
- _as_can_reexec=no; export _as_can_reexec;
- # We cannot yet assume a decent shell, so we have to provide a
-# neutralization value for shells without unset; and this also
-# works around shells that cannot unset nonexistent variables.
-# Preserve -v and -x to the replacement shell.
-BASH_ENV=/dev/null
-ENV=/dev/null
-(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
-case $- in # ((((
- *v*x* | *x*v* ) as_opts=-vx ;;
- *v* ) as_opts=-v ;;
- *x* ) as_opts=-x ;;
- * ) as_opts= ;;
-esac
-exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
-# Admittedly, this is quite paranoid, since all the known shells bail
-# out after a failed `exec'.
-$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
-as_fn_exit 255
- fi
- # We don't want this to propagate to other subprocesses.
- { _as_can_reexec=; unset _as_can_reexec;}
-if test "x$CONFIG_SHELL" = x; then
- as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
- emulate sh
- NULLCMD=:
- # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
- # is contrary to our usage. Disable this feature.
- alias -g '\${1+\"\$@\"}'='\"\$@\"'
- setopt NO_GLOB_SUBST
-else
- case \`(set -o) 2>/dev/null\` in #(
- *posix*) :
- set -o posix ;; #(
- *) :
- ;;
-esac
-fi
-"
- as_required="as_fn_return () { (exit \$1); }
-as_fn_success () { as_fn_return 0; }
-as_fn_failure () { as_fn_return 1; }
-as_fn_ret_success () { return 0; }
-as_fn_ret_failure () { return 1; }
-
-exitcode=0
-as_fn_success || { exitcode=1; echo as_fn_success failed.; }
-as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
-as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
-as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
-if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
-
-else
- exitcode=1; echo positional parameters were not saved.
-fi
-test x\$exitcode = x0 || exit 1
-test -x / || exit 1"
- as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
- as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
- eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
- test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
-test \$(( 1 + 1 )) = 2 || exit 1"
- if (eval "$as_required") 2>/dev/null; then :
- as_have_required=yes
-else
- as_have_required=no
-fi
- if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
-
-else
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-as_found=false
-for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- as_found=:
- case $as_dir in #(
- /*)
- for as_base in sh bash ksh sh5; do
- # Try only shells that exist, to save several forks.
- as_shell=$as_dir/$as_base
- if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
- { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
- CONFIG_SHELL=$as_shell as_have_required=yes
- if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
- break 2
-fi
-fi
- done;;
- esac
- as_found=false
-done
-$as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
- { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
- CONFIG_SHELL=$SHELL as_have_required=yes
-fi; }
-IFS=$as_save_IFS
-
-
- if test "x$CONFIG_SHELL" != x; then :
- export CONFIG_SHELL
- # We cannot yet assume a decent shell, so we have to provide a
-# neutralization value for shells without unset; and this also
-# works around shells that cannot unset nonexistent variables.
-# Preserve -v and -x to the replacement shell.
-BASH_ENV=/dev/null
-ENV=/dev/null
-(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
-case $- in # ((((
- *v*x* | *x*v* ) as_opts=-vx ;;
- *v* ) as_opts=-v ;;
- *x* ) as_opts=-x ;;
- * ) as_opts= ;;
-esac
-exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
-# Admittedly, this is quite paranoid, since all the known shells bail
-# out after a failed `exec'.
-$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
-exit 255
-fi
-
- if test x$as_have_required = xno; then :
- $as_echo "$0: This script requires a shell more modern than all"
- $as_echo "$0: the shells that I found on your system."
- if test x${ZSH_VERSION+set} = xset ; then
- $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
- $as_echo "$0: be upgraded to zsh 4.3.4 or later."
- else
- $as_echo "$0: Please tell bug-autoconf@gnu.org about your system,
-$0: including any error possibly output before this
-$0: message. Then install a modern shell, or manually run
-$0: the script under such a shell if you do have one."
- fi
- exit 1
-fi
-fi
-fi
-SHELL=${CONFIG_SHELL-/bin/sh}
-export SHELL
-# Unset more variables known to interfere with behavior of common tools.
-CLICOLOR_FORCE= GREP_OPTIONS=
-unset CLICOLOR_FORCE GREP_OPTIONS
-
-## --------------------- ##
-## M4sh Shell Functions. ##
-## --------------------- ##
-# as_fn_unset VAR
-# ---------------
-# Portably unset VAR.
-as_fn_unset ()
-{
- { eval $1=; unset $1;}
-}
-as_unset=as_fn_unset
-
-# as_fn_set_status STATUS
-# -----------------------
-# Set $? to STATUS, without forking.
-as_fn_set_status ()
-{
- return $1
-} # as_fn_set_status
-
-# as_fn_exit STATUS
-# -----------------
-# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
-as_fn_exit ()
-{
- set +e
- as_fn_set_status $1
- exit $1
-} # as_fn_exit
-
-# as_fn_mkdir_p
-# -------------
-# Create "$as_dir" as a directory, including parents if necessary.
-as_fn_mkdir_p ()
-{
-
- case $as_dir in #(
- -*) as_dir=./$as_dir;;
- esac
- test -d "$as_dir" || eval $as_mkdir_p || {
- as_dirs=
- while :; do
- case $as_dir in #(
- *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
- *) as_qdir=$as_dir;;
- esac
- as_dirs="'$as_qdir' $as_dirs"
- as_dir=`$as_dirname -- "$as_dir" ||
-$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$as_dir" : 'X\(//\)[^/]' \| \
- X"$as_dir" : 'X\(//\)$' \| \
- X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$as_dir" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
- test -d "$as_dir" && break
- done
- test -z "$as_dirs" || eval "mkdir $as_dirs"
- } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
-
-
-} # as_fn_mkdir_p
-
-# as_fn_executable_p FILE
-# -----------------------
-# Test if FILE is an executable regular file.
-as_fn_executable_p ()
-{
- test -f "$1" && test -x "$1"
-} # as_fn_executable_p
-# as_fn_append VAR VALUE
-# ----------------------
-# Append the text in VALUE to the end of the definition contained in VAR. Take
-# advantage of any shell optimizations that allow amortized linear growth over
-# repeated appends, instead of the typical quadratic growth present in naive
-# implementations.
-if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
- eval 'as_fn_append ()
- {
- eval $1+=\$2
- }'
-else
- as_fn_append ()
- {
- eval $1=\$$1\$2
- }
-fi # as_fn_append
-
-# as_fn_arith ARG...
-# ------------------
-# Perform arithmetic evaluation on the ARGs, and store the result in the
-# global $as_val. Take advantage of shells that can avoid forks. The arguments
-# must be portable across $(()) and expr.
-if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
- eval 'as_fn_arith ()
- {
- as_val=$(( $* ))
- }'
-else
- as_fn_arith ()
- {
- as_val=`expr "$@" || test $? -eq 1`
- }
-fi # as_fn_arith
-
-
-# as_fn_error STATUS ERROR [LINENO LOG_FD]
-# ----------------------------------------
-# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
-# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
-# script with STATUS, using 1 if that was 0.
-as_fn_error ()
-{
- as_status=$1; test $as_status -eq 0 && as_status=1
- if test "$4"; then
- as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
- fi
- $as_echo "$as_me: error: $2" >&2
- as_fn_exit $as_status
-} # as_fn_error
-
-if expr a : '\(a\)' >/dev/null 2>&1 &&
- test "X`expr 00001 : '.*\(...\)'`" = X001; then
- as_expr=expr
-else
- as_expr=false
-fi
-
-if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
- as_basename=basename
-else
- as_basename=false
-fi
-
-if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
- as_dirname=dirname
-else
- as_dirname=false
-fi
-
-as_me=`$as_basename -- "$0" ||
-$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
- X"$0" : 'X\(//\)$' \| \
- X"$0" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X/"$0" |
- sed '/^.*\/\([^/][^/]*\)\/*$/{
- s//\1/
- q
- }
- /^X\/\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\/\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
-
-# Avoid depending upon Character Ranges.
-as_cr_letters='abcdefghijklmnopqrstuvwxyz'
-as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
-as_cr_Letters=$as_cr_letters$as_cr_LETTERS
-as_cr_digits='0123456789'
-as_cr_alnum=$as_cr_Letters$as_cr_digits
-
-
- as_lineno_1=$LINENO as_lineno_1a=$LINENO
- as_lineno_2=$LINENO as_lineno_2a=$LINENO
- eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
- test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
- # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-)
- sed -n '
- p
- /[$]LINENO/=
- ' <$as_myself |
- sed '
- s/[$]LINENO.*/&-/
- t lineno
- b
- :lineno
- N
- :loop
- s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
- t loop
- s/-\n.*//
- ' >$as_me.lineno &&
- chmod +x "$as_me.lineno" ||
- { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
-
- # If we had to re-execute with $CONFIG_SHELL, we're ensured to have
- # already done that, so ensure we don't try to do so again and fall
- # in an infinite loop. This has already happened in practice.
- _as_can_reexec=no; export _as_can_reexec
- # Don't try to exec as it changes $[0], causing all sort of problems
- # (the dirname of $[0] is not the place where we might find the
- # original and so on. Autoconf is especially sensitive to this).
- . "./$as_me.lineno"
- # Exit status is that of the last command.
- exit
-}
-
-ECHO_C= ECHO_N= ECHO_T=
-case `echo -n x` in #(((((
--n*)
- case `echo 'xy\c'` in
- *c*) ECHO_T=' ';; # ECHO_T is single tab character.
- xy) ECHO_C='\c';;
- *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
- ECHO_T=' ';;
- esac;;
-*)
- ECHO_N='-n';;
-esac
-
-rm -f conf$$ conf$$.exe conf$$.file
-if test -d conf$$.dir; then
- rm -f conf$$.dir/conf$$.file
-else
- rm -f conf$$.dir
- mkdir conf$$.dir 2>/dev/null
-fi
-if (echo >conf$$.file) 2>/dev/null; then
- if ln -s conf$$.file conf$$ 2>/dev/null; then
- as_ln_s='ln -s'
- # ... but there are two gotchas:
- # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
- # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
- # In both cases, we have to default to `cp -pR'.
- ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
- as_ln_s='cp -pR'
- elif ln conf$$.file conf$$ 2>/dev/null; then
- as_ln_s=ln
- else
- as_ln_s='cp -pR'
- fi
-else
- as_ln_s='cp -pR'
-fi
-rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
-rmdir conf$$.dir 2>/dev/null
-
-if mkdir -p . 2>/dev/null; then
- as_mkdir_p='mkdir -p "$as_dir"'
-else
- test -d ./-p && rmdir ./-p
- as_mkdir_p=false
-fi
-
-as_test_x='test -x'
-as_executable_p=as_fn_executable_p
-
-# Sed expression to map a string onto a valid CPP name.
-as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
-
-# Sed expression to map a string onto a valid variable name.
-as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
-
-
-test -n "$DJDIR" || exec 7<&0 </dev/null
-exec 6>&1
-
-# Name of the host.
-# hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status,
-# so uname gets run too.
-ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
-
-#
-# Initializations.
-#
-ac_default_prefix=/usr/local
-ac_clean_files=
-ac_config_libobj_dir=.
-LIBOBJS=
-cross_compiling=no
-subdirs=
-MFLAGS=
-MAKEFLAGS=
-
-# Identity of this package.
-PACKAGE_NAME=
-PACKAGE_TARNAME=
-PACKAGE_VERSION=
-PACKAGE_STRING=
-PACKAGE_BUGREPORT=
-PACKAGE_URL=
-
-ac_unique_file="move-if-change"
-enable_option_checking=no
-ac_subst_vars='LTLIBOBJS
-LIBOBJS
-compare_exclusions
-stage2_werror_flag
-stage1_checking
-stage1_cflags
-MAINT
-MAINTAINER_MODE_FALSE
-MAINTAINER_MODE_TRUE
-COMPILER_NM_FOR_TARGET
-COMPILER_LD_FOR_TARGET
-COMPILER_AS_FOR_TARGET
-FLAGS_FOR_TARGET
-RAW_CXX_FOR_TARGET
-WINDMC_FOR_TARGET
-WINDRES_FOR_TARGET
-STRIP_FOR_TARGET
-READELF_FOR_TARGET
-RANLIB_FOR_TARGET
-OTOOL_FOR_TARGET
-OBJDUMP_FOR_TARGET
-OBJCOPY_FOR_TARGET
-NM_FOR_TARGET
-LIPO_FOR_TARGET
-LD_FOR_TARGET
-DSYMUTIL_FOR_TARGET
-DLLTOOL_FOR_TARGET
-AS_FOR_TARGET
-AR_FOR_TARGET
-GM2_FOR_TARGET
-GDC_FOR_TARGET
-GOC_FOR_TARGET
-GFORTRAN_FOR_TARGET
-GCC_FOR_TARGET
-CXX_FOR_TARGET
-CC_FOR_TARGET
-RANLIB_PLUGIN_OPTION
-AR_PLUGIN_OPTION
-PKG_CONFIG_PATH
-GDCFLAGS
-READELF
-OTOOL
-OBJDUMP
-OBJCOPY
-WINDMC
-WINDRES
-STRIP
-RANLIB
-NM
-LIPO
-LD
-DSYMUTIL
-DLLTOOL
-AS
-AR
-RUNTEST
-EXPECT
-MAKEINFO
-FLEX
-LEX
-M4
-BISON
-YACC
-WINDRES_FOR_BUILD
-WINDMC_FOR_BUILD
-RANLIB_FOR_BUILD
-NM_FOR_BUILD
-LD_FOR_BUILD
-LDFLAGS_FOR_BUILD
-GDC_FOR_BUILD
-GOC_FOR_BUILD
-GFORTRAN_FOR_BUILD
-DSYMUTIL_FOR_BUILD
-DLLTOOL_FOR_BUILD
-CXX_FOR_BUILD
-CXXFLAGS_FOR_BUILD
-CPPFLAGS_FOR_BUILD
-CPP_FOR_BUILD
-CFLAGS_FOR_BUILD
-CC_FOR_BUILD
-AS_FOR_BUILD
-AR_FOR_BUILD
-target_configdirs
-configdirs
-build_configdirs
-INSTALL_GDB_TK
-GDB_TK
-CONFIGURE_GDB_TK
-build_tooldir
-tooldir
-GCC_SHLIB_SUBDIR
-RPATH_ENVVAR
-target_configargs
-host_configargs
-build_configargs
-BUILD_CONFIG
-LDFLAGS_FOR_TARGET
-CXXFLAGS_FOR_TARGET
-CFLAGS_FOR_TARGET
-DEBUG_PREFIX_CFLAGS_FOR_TARGET
-SYSROOT_CFLAGS_FOR_TARGET
-get_gcc_base_ver
-extra_host_zlib_configure_flags
-extra_host_libiberty_configure_flags
-stage1_languages
-host_libs_picflag
-PICFLAG
-host_shared
-gcc_host_pie
-host_pie
-extra_linker_plugin_flags
-extra_linker_plugin_configure_flags
-islinc
-isllibs
-poststage1_ldflags
-poststage1_libs
-stage1_ldflags
-stage1_libs
-extra_isl_gmp_configure_flags
-extra_mpc_mpfr_configure_flags
-extra_mpc_gmp_configure_flags
-extra_mpfr_configure_flags
-gmpinc
-gmplibs
-PGO_BUILD_LTO_CFLAGS
-PGO_BUILD_USE_CFLAGS
-PGO_BUILD_GEN_CFLAGS
-HAVE_CXX11_FOR_BUILD
-HAVE_CXX11
-do_compare
-GDC
-GNATMAKE
-GNATBIND
-ac_ct_CXX
-CXXFLAGS
-CXX
-OBJEXT
-EXEEXT
-ac_ct_CC
-CPPFLAGS
-LDFLAGS
-CFLAGS
-CC
-target_subdir
-host_subdir
-build_subdir
-build_libsubdir
-AWK
-SED
-LN_S
-LN
-INSTALL_DATA
-INSTALL_SCRIPT
-INSTALL_PROGRAM
-target_os
-target_vendor
-target_cpu
-target
-host_os
-host_vendor
-host_cpu
-host
-target_noncanonical
-host_noncanonical
-build_noncanonical
-build_os
-build_vendor
-build_cpu
-build
-TOPLEVEL_CONFIGURE_ARGUMENTS
-target_alias
-host_alias
-build_alias
-LIBS
-ECHO_T
-ECHO_N
-ECHO_C
-DEFS
-mandir
-localedir
-libdir
-psdir
-pdfdir
-dvidir
-htmldir
-infodir
-docdir
-oldincludedir
-includedir
-localstatedir
-sharedstatedir
-sysconfdir
-datadir
-datarootdir
-libexecdir
-sbindir
-bindir
-program_transform_name
-prefix
-exec_prefix
-PACKAGE_URL
-PACKAGE_BUGREPORT
-PACKAGE_STRING
-PACKAGE_VERSION
-PACKAGE_TARNAME
-PACKAGE_NAME
-PATH_SEPARATOR
-SHELL'
-ac_subst_files='serialization_dependencies
-host_makefile_frag
-target_makefile_frag
-alphaieee_frag
-ospace_frag'
-ac_user_opts='
-enable_option_checking
-with_build_libsubdir
-with_system_zlib
-with_zstd
-enable_as_accelerator_for
-enable_offload_targets
-enable_offload_defaulted
-enable_gold
-enable_ld
-enable_gprofng
-enable_compressed_debug_sections
-enable_default_compressed_debug_sections_algorithm
-enable_year2038
-enable_libquadmath
-enable_libquadmath_support
-enable_libada
-enable_libgm2
-enable_libssp
-enable_libstdcxx
-enable_bootstrap
-enable_pgo_build
-with_mpc
-with_mpc_include
-with_mpc_lib
-with_mpfr
-with_mpfr_include
-with_mpfr_lib
-with_gmp
-with_gmp_include
-with_gmp_lib
-with_stage1_libs
-with_static_standard_libraries
-with_stage1_ldflags
-with_boot_libs
-with_boot_ldflags
-with_isl
-with_isl_include
-with_isl_lib
-enable_isl_version_check
-enable_lto
-enable_linker_plugin_configure_flags
-enable_linker_plugin_flags
-enable_host_pie
-enable_host_shared
-enable_stage1_languages
-enable_objc_gc
-with_target_bdw_gc
-with_target_bdw_gc_include
-with_target_bdw_gc_lib
-with_gcc_major_version_only
-with_build_sysroot
-with_debug_prefix_map
-with_build_config
-enable_vtable_verify
-enable_serial_configure
-with_build_time_tools
-enable_maintainer_mode
-enable_stage1_checking
-enable_werror
-'
- ac_precious_vars='build_alias
-host_alias
-target_alias
-CC
-CFLAGS
-LDFLAGS
-LIBS
-CPPFLAGS
-CXX
-CXXFLAGS
-CCC
-build_configargs
-host_configargs
-target_configargs
-AR
-AS
-DLLTOOL
-DSYMUTIL
-LD
-LIPO
-NM
-RANLIB
-STRIP
-WINDRES
-WINDMC
-OBJCOPY
-OBJDUMP
-OTOOL
-READELF
-CC_FOR_TARGET
-CXX_FOR_TARGET
-GCC_FOR_TARGET
-GFORTRAN_FOR_TARGET
-GOC_FOR_TARGET
-GDC_FOR_TARGET
-GM2_FOR_TARGET
-AR_FOR_TARGET
-AS_FOR_TARGET
-DLLTOOL_FOR_TARGET
-DSYMUTIL_FOR_TARGET
-LD_FOR_TARGET
-LIPO_FOR_TARGET
-NM_FOR_TARGET
-OBJCOPY_FOR_TARGET
-OBJDUMP_FOR_TARGET
-OTOOL_FOR_TARGET
-RANLIB_FOR_TARGET
-READELF_FOR_TARGET
-STRIP_FOR_TARGET
-WINDRES_FOR_TARGET
-WINDMC_FOR_TARGET'
-
-
-# Initialize some variables set by options.
-ac_init_help=
-ac_init_version=false
-ac_unrecognized_opts=
-ac_unrecognized_sep=
-# The variables have the same names as the options, with
-# dashes changed to underlines.
-cache_file=/dev/null
-exec_prefix=NONE
-no_create=
-no_recursion=
-prefix=NONE
-program_prefix=NONE
-program_suffix=NONE
-program_transform_name=s,x,x,
-silent=
-site=
-srcdir=
-verbose=
-x_includes=NONE
-x_libraries=NONE
-
-# Installation directory options.
-# These are left unexpanded so users can "make install exec_prefix=/foo"
-# and all the variables that are supposed to be based on exec_prefix
-# by default will actually change.
-# Use braces instead of parens because sh, perl, etc. also accept them.
-# (The list follows the same order as the GNU Coding Standards.)
-bindir='${exec_prefix}/bin'
-sbindir='${exec_prefix}/sbin'
-libexecdir='${exec_prefix}/libexec'
-datarootdir='${prefix}/share'
-datadir='${datarootdir}'
-sysconfdir='${prefix}/etc'
-sharedstatedir='${prefix}/com'
-localstatedir='${prefix}/var'
-includedir='${prefix}/include'
-oldincludedir='/usr/include'
-docdir='${datarootdir}/doc/${PACKAGE}'
-infodir='${datarootdir}/info'
-htmldir='${docdir}'
-dvidir='${docdir}'
-pdfdir='${docdir}'
-psdir='${docdir}'
-libdir='${exec_prefix}/lib'
-localedir='${datarootdir}/locale'
-mandir='${datarootdir}/man'
-
-ac_prev=
-ac_dashdash=
-for ac_option
-do
- # If the previous option needs an argument, assign it.
- if test -n "$ac_prev"; then
- eval $ac_prev=\$ac_option
- ac_prev=
- continue
- fi
-
- case $ac_option in
- *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
- *=) ac_optarg= ;;
- *) ac_optarg=yes ;;
- esac
-
- # Accept the important Cygnus configure options, so we can diagnose typos.
-
- case $ac_dashdash$ac_option in
- --)
- ac_dashdash=yes ;;
-
- -bindir | --bindir | --bindi | --bind | --bin | --bi)
- ac_prev=bindir ;;
- -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
- bindir=$ac_optarg ;;
-
- -build | --build | --buil | --bui | --bu)
- ac_prev=build_alias ;;
- -build=* | --build=* | --buil=* | --bui=* | --bu=*)
- build_alias=$ac_optarg ;;
-
- -cache-file | --cache-file | --cache-fil | --cache-fi \
- | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
- ac_prev=cache_file ;;
- -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
- | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
- cache_file=$ac_optarg ;;
-
- --config-cache | -C)
- cache_file=config.cache ;;
-
- -datadir | --datadir | --datadi | --datad)
- ac_prev=datadir ;;
- -datadir=* | --datadir=* | --datadi=* | --datad=*)
- datadir=$ac_optarg ;;
-
- -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
- | --dataroo | --dataro | --datar)
- ac_prev=datarootdir ;;
- -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
- | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
- datarootdir=$ac_optarg ;;
-
- -disable-* | --disable-*)
- ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
- # Reject names that are not valid shell variable names.
- expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
- as_fn_error $? "invalid feature name: $ac_useropt"
- ac_useropt_orig=$ac_useropt
- ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
- case $ac_user_opts in
- *"
-"enable_$ac_useropt"
-"*) ;;
- *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
- ac_unrecognized_sep=', ';;
- esac
- eval enable_$ac_useropt=no ;;
-
- -docdir | --docdir | --docdi | --doc | --do)
- ac_prev=docdir ;;
- -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
- docdir=$ac_optarg ;;
-
- -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
- ac_prev=dvidir ;;
- -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
- dvidir=$ac_optarg ;;
-
- -enable-* | --enable-*)
- ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
- # Reject names that are not valid shell variable names.
- expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
- as_fn_error $? "invalid feature name: $ac_useropt"
- ac_useropt_orig=$ac_useropt
- ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
- case $ac_user_opts in
- *"
-"enable_$ac_useropt"
-"*) ;;
- *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
- ac_unrecognized_sep=', ';;
- esac
- eval enable_$ac_useropt=\$ac_optarg ;;
-
- -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
- | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
- | --exec | --exe | --ex)
- ac_prev=exec_prefix ;;
- -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
- | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
- | --exec=* | --exe=* | --ex=*)
- exec_prefix=$ac_optarg ;;
-
- -gas | --gas | --ga | --g)
- # Obsolete; use --with-gas.
- with_gas=yes ;;
-
- -help | --help | --hel | --he | -h)
- ac_init_help=long ;;
- -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
- ac_init_help=recursive ;;
- -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
- ac_init_help=short ;;
-
- -host | --host | --hos | --ho)
- ac_prev=host_alias ;;
- -host=* | --host=* | --hos=* | --ho=*)
- host_alias=$ac_optarg ;;
-
- -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
- ac_prev=htmldir ;;
- -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
- | --ht=*)
- htmldir=$ac_optarg ;;
-
- -includedir | --includedir | --includedi | --included | --include \
- | --includ | --inclu | --incl | --inc)
- ac_prev=includedir ;;
- -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
- | --includ=* | --inclu=* | --incl=* | --inc=*)
- includedir=$ac_optarg ;;
-
- -infodir | --infodir | --infodi | --infod | --info | --inf)
- ac_prev=infodir ;;
- -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
- infodir=$ac_optarg ;;
-
- -libdir | --libdir | --libdi | --libd)
- ac_prev=libdir ;;
- -libdir=* | --libdir=* | --libdi=* | --libd=*)
- libdir=$ac_optarg ;;
-
- -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
- | --libexe | --libex | --libe)
- ac_prev=libexecdir ;;
- -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
- | --libexe=* | --libex=* | --libe=*)
- libexecdir=$ac_optarg ;;
-
- -localedir | --localedir | --localedi | --localed | --locale)
- ac_prev=localedir ;;
- -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
- localedir=$ac_optarg ;;
-
- -localstatedir | --localstatedir | --localstatedi | --localstated \
- | --localstate | --localstat | --localsta | --localst | --locals)
- ac_prev=localstatedir ;;
- -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
- | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
- localstatedir=$ac_optarg ;;
-
- -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
- ac_prev=mandir ;;
- -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
- mandir=$ac_optarg ;;
-
- -nfp | --nfp | --nf)
- # Obsolete; use --without-fp.
- with_fp=no ;;
-
- -no-create | --no-create | --no-creat | --no-crea | --no-cre \
- | --no-cr | --no-c | -n)
- no_create=yes ;;
-
- -no-recursion | --no-recursion | --no-recursio | --no-recursi \
- | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
- no_recursion=yes ;;
-
- -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
- | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
- | --oldin | --oldi | --old | --ol | --o)
- ac_prev=oldincludedir ;;
- -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
- | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
- | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
- oldincludedir=$ac_optarg ;;
-
- -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
- ac_prev=prefix ;;
- -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
- prefix=$ac_optarg ;;
-
- -program-prefix | --program-prefix | --program-prefi | --program-pref \
- | --program-pre | --program-pr | --program-p)
- ac_prev=program_prefix ;;
- -program-prefix=* | --program-prefix=* | --program-prefi=* \
- | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
- program_prefix=$ac_optarg ;;
-
- -program-suffix | --program-suffix | --program-suffi | --program-suff \
- | --program-suf | --program-su | --program-s)
- ac_prev=program_suffix ;;
- -program-suffix=* | --program-suffix=* | --program-suffi=* \
- | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
- program_suffix=$ac_optarg ;;
-
- -program-transform-name | --program-transform-name \
- | --program-transform-nam | --program-transform-na \
- | --program-transform-n | --program-transform- \
- | --program-transform | --program-transfor \
- | --program-transfo | --program-transf \
- | --program-trans | --program-tran \
- | --progr-tra | --program-tr | --program-t)
- ac_prev=program_transform_name ;;
- -program-transform-name=* | --program-transform-name=* \
- | --program-transform-nam=* | --program-transform-na=* \
- | --program-transform-n=* | --program-transform-=* \
- | --program-transform=* | --program-transfor=* \
- | --program-transfo=* | --program-transf=* \
- | --program-trans=* | --program-tran=* \
- | --progr-tra=* | --program-tr=* | --program-t=*)
- program_transform_name=$ac_optarg ;;
-
- -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
- ac_prev=pdfdir ;;
- -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
- pdfdir=$ac_optarg ;;
-
- -psdir | --psdir | --psdi | --psd | --ps)
- ac_prev=psdir ;;
- -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
- psdir=$ac_optarg ;;
-
- -q | -quiet | --quiet | --quie | --qui | --qu | --q \
- | -silent | --silent | --silen | --sile | --sil)
- silent=yes ;;
-
- -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
- ac_prev=sbindir ;;
- -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
- | --sbi=* | --sb=*)
- sbindir=$ac_optarg ;;
-
- -sharedstatedir | --sharedstatedir | --sharedstatedi \
- | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
- | --sharedst | --shareds | --shared | --share | --shar \
- | --sha | --sh)
- ac_prev=sharedstatedir ;;
- -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
- | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
- | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
- | --sha=* | --sh=*)
- sharedstatedir=$ac_optarg ;;
-
- -site | --site | --sit)
- ac_prev=site ;;
- -site=* | --site=* | --sit=*)
- site=$ac_optarg ;;
-
- -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
- ac_prev=srcdir ;;
- -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
- srcdir=$ac_optarg ;;
-
- -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
- | --syscon | --sysco | --sysc | --sys | --sy)
- ac_prev=sysconfdir ;;
- -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
- | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
- sysconfdir=$ac_optarg ;;
-
- -target | --target | --targe | --targ | --tar | --ta | --t)
- ac_prev=target_alias ;;
- -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
- target_alias=$ac_optarg ;;
-
- -v | -verbose | --verbose | --verbos | --verbo | --verb)
- verbose=yes ;;
-
- -version | --version | --versio | --versi | --vers | -V)
- ac_init_version=: ;;
-
- -with-* | --with-*)
- ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
- # Reject names that are not valid shell variable names.
- expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
- as_fn_error $? "invalid package name: $ac_useropt"
- ac_useropt_orig=$ac_useropt
- ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
- case $ac_user_opts in
- *"
-"with_$ac_useropt"
-"*) ;;
- *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
- ac_unrecognized_sep=', ';;
- esac
- eval with_$ac_useropt=\$ac_optarg ;;
-
- -without-* | --without-*)
- ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
- # Reject names that are not valid shell variable names.
- expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
- as_fn_error $? "invalid package name: $ac_useropt"
- ac_useropt_orig=$ac_useropt
- ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
- case $ac_user_opts in
- *"
-"with_$ac_useropt"
-"*) ;;
- *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
- ac_unrecognized_sep=', ';;
- esac
- eval with_$ac_useropt=no ;;
-
- --x)
- # Obsolete; use --with-x.
- with_x=yes ;;
-
- -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
- | --x-incl | --x-inc | --x-in | --x-i)
- ac_prev=x_includes ;;
- -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
- | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
- x_includes=$ac_optarg ;;
-
- -x-libraries | --x-libraries | --x-librarie | --x-librari \
- | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
- ac_prev=x_libraries ;;
- -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
- | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
- x_libraries=$ac_optarg ;;
-
- -*) as_fn_error $? "unrecognized option: \`$ac_option'
-Try \`$0 --help' for more information"
- ;;
-
- *=*)
- ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
- # Reject names that are not valid shell variable names.
- case $ac_envvar in #(
- '' | [0-9]* | *[!_$as_cr_alnum]* )
- as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
- esac
- eval $ac_envvar=\$ac_optarg
- export $ac_envvar ;;
-
- *)
- # FIXME: should be removed in autoconf 3.0.
- $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
- expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
- $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
- : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
- ;;
-
- esac
-done
-
-if test -n "$ac_prev"; then
- ac_option=--`echo $ac_prev | sed 's/_/-/g'`
- as_fn_error $? "missing argument to $ac_option"
-fi
-
-if test -n "$ac_unrecognized_opts"; then
- case $enable_option_checking in
- no) ;;
- fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
- *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
- esac
-fi
-
-# Check all directory arguments for consistency.
-for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
- datadir sysconfdir sharedstatedir localstatedir includedir \
- oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
- libdir localedir mandir
-do
- eval ac_val=\$$ac_var
- # Remove trailing slashes.
- case $ac_val in
- */ )
- ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
- eval $ac_var=\$ac_val;;
- esac
- # Be sure to have absolute directory names.
- case $ac_val in
- [\\/$]* | ?:[\\/]* ) continue;;
- NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
- esac
- as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
-done
-
-# There might be people who depend on the old broken behavior: `$host'
-# used to hold the argument of --host etc.
-# FIXME: To remove some day.
-build=$build_alias
-host=$host_alias
-target=$target_alias
-
-# FIXME: To remove some day.
-if test "x$host_alias" != x; then
- if test "x$build_alias" = x; then
- cross_compiling=maybe
- elif test "x$build_alias" != "x$host_alias"; then
- cross_compiling=yes
- fi
-fi
-
-ac_tool_prefix=
-test -n "$host_alias" && ac_tool_prefix=$host_alias-
-
-test "$silent" = yes && exec 6>/dev/null
-
-
-ac_pwd=`pwd` && test -n "$ac_pwd" &&
-ac_ls_di=`ls -di .` &&
-ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
- as_fn_error $? "working directory cannot be determined"
-test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
- as_fn_error $? "pwd does not report name of working directory"
-
-
-# Find the source files, if location was not specified.
-if test -z "$srcdir"; then
- ac_srcdir_defaulted=yes
- # Try the directory containing this script, then the parent directory.
- ac_confdir=`$as_dirname -- "$as_myself" ||
-$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$as_myself" : 'X\(//\)[^/]' \| \
- X"$as_myself" : 'X\(//\)$' \| \
- X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$as_myself" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
- srcdir=$ac_confdir
- if test ! -r "$srcdir/$ac_unique_file"; then
- srcdir=..
- fi
-else
- ac_srcdir_defaulted=no
-fi
-if test ! -r "$srcdir/$ac_unique_file"; then
- test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
- as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
-fi
-ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
-ac_abs_confdir=`(
- cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
- pwd)`
-# When building in place, set srcdir=.
-if test "$ac_abs_confdir" = "$ac_pwd"; then
- srcdir=.
-fi
-# Remove unnecessary trailing slashes from srcdir.
-# Double slashes in file names in object file debugging info
-# mess up M-x gdb in Emacs.
-case $srcdir in
-*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
-esac
-case $srcdir in
- *" "*)
- as_fn_error $? "path to source, $srcdir, contains spaces"
- ;;
-esac
-ac_subdirs_all=`cd $srcdir && echo */configure | sed 's,/configure,,g'`
-
-for ac_var in $ac_precious_vars; do
- eval ac_env_${ac_var}_set=\${${ac_var}+set}
- eval ac_env_${ac_var}_value=\$${ac_var}
- eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
- eval ac_cv_env_${ac_var}_value=\$${ac_var}
-done
-
-#
-# Report the --help message.
-#
-if test "$ac_init_help" = "long"; then
- # Omit some internal or obsolete options to make the list less imposing.
- # This message is too long to be a string in the A/UX 3.1 sh.
- cat <<_ACEOF
-\`configure' configures this package to adapt to many kinds of systems.
-
-Usage: $0 [OPTION]... [VAR=VALUE]...
-
-To assign environment variables (e.g., CC, CFLAGS...), specify them as
-VAR=VALUE. See below for descriptions of some of the useful variables.
-
-Defaults for the options are specified in brackets.
-
-Configuration:
- -h, --help display this help and exit
- --help=short display options specific to this package
- --help=recursive display the short help of all the included packages
- -V, --version display version information and exit
- -q, --quiet, --silent do not print \`checking ...' messages
- --cache-file=FILE cache test results in FILE [disabled]
- -C, --config-cache alias for \`--cache-file=config.cache'
- -n, --no-create do not create output files
- --srcdir=DIR find the sources in DIR [configure dir or \`..']
-
-Installation directories:
- --prefix=PREFIX install architecture-independent files in PREFIX
- [$ac_default_prefix]
- --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
- [PREFIX]
-
-By default, \`make install' will install all the files in
-\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
-an installation prefix other than \`$ac_default_prefix' using \`--prefix',
-for instance \`--prefix=\$HOME'.
-
-For better control, use the options below.
-
-Fine tuning of the installation directories:
- --bindir=DIR user executables [EPREFIX/bin]
- --sbindir=DIR system admin executables [EPREFIX/sbin]
- --libexecdir=DIR program executables [EPREFIX/libexec]
- --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
- --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
- --localstatedir=DIR modifiable single-machine data [PREFIX/var]
- --libdir=DIR object code libraries [EPREFIX/lib]
- --includedir=DIR C header files [PREFIX/include]
- --oldincludedir=DIR C header files for non-gcc [/usr/include]
- --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
- --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
- --infodir=DIR info documentation [DATAROOTDIR/info]
- --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
- --mandir=DIR man documentation [DATAROOTDIR/man]
- --docdir=DIR documentation root [DATAROOTDIR/doc/PACKAGE]
- --htmldir=DIR html documentation [DOCDIR]
- --dvidir=DIR dvi documentation [DOCDIR]
- --pdfdir=DIR pdf documentation [DOCDIR]
- --psdir=DIR ps documentation [DOCDIR]
-_ACEOF
-
- cat <<\_ACEOF
-
-Program names:
- --program-prefix=PREFIX prepend PREFIX to installed program names
- --program-suffix=SUFFIX append SUFFIX to installed program names
- --program-transform-name=PROGRAM run sed PROGRAM on installed program names
-
-System types:
- --build=BUILD configure for building on BUILD [guessed]
- --host=HOST cross-compile to build programs to run on HOST [BUILD]
- --target=TARGET configure for building compilers for TARGET [HOST]
-_ACEOF
-fi
-
-if test -n "$ac_init_help"; then
-
- cat <<\_ACEOF
-
-Optional Features:
- --disable-option-checking ignore unrecognized --enable/--with options
- --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
- --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
- --enable-as-accelerator-for=ARG
- build as offload target compiler. Specify offload
- host triple by ARG
- --enable-offload-targets=LIST
- enable offloading to devices from comma-separated
- LIST of TARGET[=DIR]. Use optional path to find
- offload target compiler during the build
- --enable-offload-defaulted
- If enabled, configured but not installed offload compilers and
- libgomp plugins are silently ignored. Useful for distribution
- compilers where those are in separate optional packages.
-
- --enable-gold[=ARG] build gold [ARG={default,yes,no}]
- --enable-ld[=ARG] build ld [ARG={default,yes,no}]
- --enable-gprofng[=ARG] build gprofng [ARG={yes,no}]
- --enable-compressed-debug-sections={all,gas,gold,ld,none}
- Enable compressed debug sections for gas, gold or ld
- by default
- --enable-default-compressed-debug-sections-algorithm={zlib,zstd}
- Default compression algorithm for
- --enable-compressed-debug-sections.
- --enable-year2038 enable support for timestamps past the year 2038
- --disable-libquadmath do not build libquadmath directory
- --disable-libquadmath-support
- disable libquadmath support for Fortran
- --enable-libada build libada directory
- --enable-libgm2 build libgm2 directory
- --enable-libssp build libssp directory
- --disable-libstdcxx do not build libstdc++-v3 directory
- --enable-bootstrap enable bootstrapping [yes if native build]
- --enable-pgo-build[=lto]
- enable the PGO build
- --disable-isl-version-check
- disable check for isl version
- --enable-lto enable link time optimization support
- --enable-linker-plugin-configure-flags=FLAGS
- additional flags for configuring linker plugins
- [none]
- --enable-linker-plugin-flags=FLAGS
- additional flags for configuring and building linker
- plugins [none]
- --enable-host-pie build position independent host executables
- --enable-host-shared build host code as shared libraries
- --enable-stage1-languages[=all]
- choose additional languages to build during stage1.
- Mostly useful for compiler development
- --enable-objc-gc enable use of Boehm's garbage collector with the GNU
- Objective-C runtime
- --enable-vtable-verify Enable vtable verification feature
- --enable-serial-[{host,target,build}-]configure
- force sequential configuration of sub-packages for
- the host, target or build machine, or all
- sub-packages
- --enable-maintainer-mode
- enable make rules and dependencies not useful (and
- sometimes confusing) to the casual installer
- --enable-stage1-checking[=all]
- choose additional checking for stage1 of the
- compiler
- --enable-werror enable -Werror in bootstrap stage2 and later
-
-Optional Packages:
- --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
- --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
- --with-build-libsubdir=DIR Directory where to find libraries for build system
- --with-system-zlib use installed libz
- --with-zstd Support zstd compressed debug sections
- (default=auto)
- --with-mpc=PATH specify prefix directory for installed MPC package.
- Equivalent to --with-mpc-include=PATH/include plus
- --with-mpc-lib=PATH/lib
- --with-mpc-include=PATH specify directory for installed MPC include files
- --with-mpc-lib=PATH specify directory for the installed MPC library
- --with-mpfr=PATH specify prefix directory for installed MPFR package.
- Equivalent to --with-mpfr-include=PATH/include plus
- --with-mpfr-lib=PATH/lib
- --with-mpfr-include=PATH
- specify directory for installed MPFR include files
- --with-mpfr-lib=PATH specify directory for the installed MPFR library
- --with-gmp=PATH specify prefix directory for the installed GMP
- package. Equivalent to
- --with-gmp-include=PATH/include plus
- --with-gmp-lib=PATH/lib
- --with-gmp-include=PATH specify directory for installed GMP include files
- --with-gmp-lib=PATH specify directory for the installed GMP library
- --with-stage1-libs=LIBS libraries for stage1
- --with-static-standard-libraries
- use -static-libstdc++ and -static-libgcc
- (default=auto)
- --with-stage1-ldflags=FLAGS
- linker flags for stage1
- --with-boot-libs=LIBS libraries for stage2 and later
- --with-boot-ldflags=FLAGS
- linker flags for stage2 and later
- --with-isl=PATH Specify prefix directory for the installed isl
- package. Equivalent to
- --with-isl-include=PATH/include plus
- --with-isl-lib=PATH/lib
- --with-isl-include=PATH Specify directory for installed isl include files
- --with-isl-lib=PATH Specify the directory for the installed isl library
- --with-target-bdw-gc=PATHLIST
- specify prefix directory for installed bdw-gc
- package. Equivalent to
- --with-target-bdw-gc-include=PATH/include plus
- --with-target-bdw-gc-lib=PATH/lib
- --with-target-bdw-gc-include=PATHLIST
- specify directories for installed bdw-gc include
- files
- --with-target-bdw-gc-lib=PATHLIST
- specify directories for installed bdw-gc library
- --with-gcc-major-version-only
- use only GCC major number in filesystem paths
- --with-build-sysroot=SYSROOT
- use sysroot as the system root during the build
- --with-debug-prefix-map='A=B C=D ...'
- map A to B, C to D ... in debug information
- --with-build-config='NAME NAME2...'
- use config/NAME.mk build configuration
- --with-build-time-tools=PATH
- use given path to find target tools during the build
-
-Some influential environment variables:
- CC C compiler command
- CFLAGS C compiler flags
- LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
- nonstandard directory <lib dir>
- LIBS libraries to pass to the linker, e.g. -l<library>
- CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
- you have headers in a nonstandard directory <include dir>
- CXX C++ compiler command
- CXXFLAGS C++ compiler flags
- build_configargs
- additional configure arguments for build directories
- host_configargs
- additional configure arguments for host directories
- target_configargs
- additional configure arguments for target directories
- AR AR for the host
- AS AS for the host
- DLLTOOL DLLTOOL for the host
- DSYMUTIL DSYMUTIL for the host
- LD LD for the host
- LIPO LIPO for the host
- NM NM for the host
- RANLIB RANLIB for the host
- STRIP STRIP for the host
- WINDRES WINDRES for the host
- WINDMC WINDMC for the host
- OBJCOPY OBJCOPY for the host
- OBJDUMP OBJDUMP for the host
- OTOOL OTOOL for the host
- READELF READELF for the host
- CC_FOR_TARGET
- CC for the target
- CXX_FOR_TARGET
- CXX for the target
- GCC_FOR_TARGET
- GCC for the target
- GFORTRAN_FOR_TARGET
- GFORTRAN for the target
- GOC_FOR_TARGET
- GOC for the target
- GDC_FOR_TARGET
- GDC for the target
- GM2_FOR_TARGET
- GM2 for the target
- AR_FOR_TARGET
- AR for the target
- AS_FOR_TARGET
- AS for the target
- DLLTOOL_FOR_TARGET
- DLLTOOL for the target
- DSYMUTIL_FOR_TARGET
- DSYMUTIL for the target
- LD_FOR_TARGET
- LD for the target
- LIPO_FOR_TARGET
- LIPO for the target
- NM_FOR_TARGET
- NM for the target
- OBJCOPY_FOR_TARGET
- OBJCOPY for the target
- OBJDUMP_FOR_TARGET
- OBJDUMP for the target
- OTOOL_FOR_TARGET
- OTOOL for the target
- RANLIB_FOR_TARGET
- RANLIB for the target
- READELF_FOR_TARGET
- READELF for the target
- STRIP_FOR_TARGET
- STRIP for the target
- WINDRES_FOR_TARGET
- WINDRES for the target
- WINDMC_FOR_TARGET
- WINDMC for the target
-
-Use these variables to override the choices made by `configure' or to help
-it to find libraries and programs with nonstandard names/locations.
-
-Report bugs to the package provider.
-_ACEOF
-ac_status=$?
-fi
-
-if test "$ac_init_help" = "recursive"; then
- # If there are subdirs, report their specific --help.
- for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
- test -d "$ac_dir" ||
- { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
- continue
- ac_builddir=.
-
-case "$ac_dir" in
-.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
-*)
- ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
- # A ".." for each directory in $ac_dir_suffix.
- ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
- case $ac_top_builddir_sub in
- "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
- *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
- esac ;;
-esac
-ac_abs_top_builddir=$ac_pwd
-ac_abs_builddir=$ac_pwd$ac_dir_suffix
-# for backward compatibility:
-ac_top_builddir=$ac_top_build_prefix
-
-case $srcdir in
- .) # We are building in place.
- ac_srcdir=.
- ac_top_srcdir=$ac_top_builddir_sub
- ac_abs_top_srcdir=$ac_pwd ;;
- [\\/]* | ?:[\\/]* ) # Absolute name.
- ac_srcdir=$srcdir$ac_dir_suffix;
- ac_top_srcdir=$srcdir
- ac_abs_top_srcdir=$srcdir ;;
- *) # Relative name.
- ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
- ac_top_srcdir=$ac_top_build_prefix$srcdir
- ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
-esac
-ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
-
- cd "$ac_dir" || { ac_status=$?; continue; }
- # Check for guested configure.
- if test -f "$ac_srcdir/configure.gnu"; then
- echo &&
- $SHELL "$ac_srcdir/configure.gnu" --help=recursive
- elif test -f "$ac_srcdir/configure"; then
- echo &&
- $SHELL "$ac_srcdir/configure" --help=recursive
- else
- $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
- fi || ac_status=$?
- cd "$ac_pwd" || { ac_status=$?; break; }
- done
-fi
-
-test -n "$ac_init_help" && exit $ac_status
-if $ac_init_version; then
- cat <<\_ACEOF
-configure
-generated by GNU Autoconf 2.69
-
-Copyright (C) 2012 Free Software Foundation, Inc.
-This configure script is free software; the Free Software Foundation
-gives unlimited permission to copy, distribute and modify it.
-_ACEOF
- exit
-fi
-
-## ------------------------ ##
-## Autoconf initialization. ##
-## ------------------------ ##
-
-# ac_fn_c_try_compile LINENO
-# --------------------------
-# Try to compile conftest.$ac_ext, and return whether this succeeded.
-ac_fn_c_try_compile ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- rm -f conftest.$ac_objext
- if { { ac_try="$ac_compile"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_compile") 2>conftest.err
- ac_status=$?
- if test -s conftest.err; then
- grep -v '^ *+' conftest.err >conftest.er1
- cat conftest.er1 >&5
- mv -f conftest.er1 conftest.err
- fi
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && {
- test -z "$ac_c_werror_flag" ||
- test ! -s conftest.err
- } && test -s conftest.$ac_objext; then :
- ac_retval=0
-else
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
- ac_retval=1
-fi
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
- as_fn_set_status $ac_retval
-
-} # ac_fn_c_try_compile
-
-# ac_fn_cxx_try_compile LINENO
-# ----------------------------
-# Try to compile conftest.$ac_ext, and return whether this succeeded.
-ac_fn_cxx_try_compile ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- rm -f conftest.$ac_objext
- if { { ac_try="$ac_compile"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_compile") 2>conftest.err
- ac_status=$?
- if test -s conftest.err; then
- grep -v '^ *+' conftest.err >conftest.er1
- cat conftest.er1 >&5
- mv -f conftest.er1 conftest.err
- fi
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && {
- test -z "$ac_cxx_werror_flag" ||
- test ! -s conftest.err
- } && test -s conftest.$ac_objext; then :
- ac_retval=0
-else
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
- ac_retval=1
-fi
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
- as_fn_set_status $ac_retval
-
-} # ac_fn_cxx_try_compile
-
-# ac_fn_cxx_try_link LINENO
-# -------------------------
-# Try to link conftest.$ac_ext, and return whether this succeeded.
-ac_fn_cxx_try_link ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- rm -f conftest.$ac_objext conftest$ac_exeext
- if { { ac_try="$ac_link"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_link") 2>conftest.err
- ac_status=$?
- if test -s conftest.err; then
- grep -v '^ *+' conftest.err >conftest.er1
- cat conftest.er1 >&5
- mv -f conftest.er1 conftest.err
- fi
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && {
- test -z "$ac_cxx_werror_flag" ||
- test ! -s conftest.err
- } && test -s conftest$ac_exeext && {
- test "$cross_compiling" = yes ||
- test -x conftest$ac_exeext
- }; then :
- ac_retval=0
-else
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
- ac_retval=1
-fi
- # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
- # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
- # interfere with the next link command; also delete a directory that is
- # left behind by Apple's compiler. We do this before executing the actions.
- rm -rf conftest.dSYM conftest_ipa8_conftest.oo
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
- as_fn_set_status $ac_retval
-
-} # ac_fn_cxx_try_link
-
-# ac_fn_c_try_link LINENO
-# -----------------------
-# Try to link conftest.$ac_ext, and return whether this succeeded.
-ac_fn_c_try_link ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- rm -f conftest.$ac_objext conftest$ac_exeext
- if { { ac_try="$ac_link"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_link") 2>conftest.err
- ac_status=$?
- if test -s conftest.err; then
- grep -v '^ *+' conftest.err >conftest.er1
- cat conftest.er1 >&5
- mv -f conftest.er1 conftest.err
- fi
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && {
- test -z "$ac_c_werror_flag" ||
- test ! -s conftest.err
- } && test -s conftest$ac_exeext && {
- test "$cross_compiling" = yes ||
- test -x conftest$ac_exeext
- }; then :
- ac_retval=0
-else
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
- ac_retval=1
-fi
- # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
- # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
- # interfere with the next link command; also delete a directory that is
- # left behind by Apple's compiler. We do this before executing the actions.
- rm -rf conftest.dSYM conftest_ipa8_conftest.oo
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
- as_fn_set_status $ac_retval
-
-} # ac_fn_c_try_link
-cat >config.log <<_ACEOF
-This file contains any messages produced by compilers while
-running configure, to aid debugging if configure makes a mistake.
-
-It was created by $as_me, which was
-generated by GNU Autoconf 2.69. Invocation command line was
-
- $ $0 $@
-
-_ACEOF
-exec 5>>config.log
-{
-cat <<_ASUNAME
-## --------- ##
-## Platform. ##
-## --------- ##
-
-hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
-uname -m = `(uname -m) 2>/dev/null || echo unknown`
-uname -r = `(uname -r) 2>/dev/null || echo unknown`
-uname -s = `(uname -s) 2>/dev/null || echo unknown`
-uname -v = `(uname -v) 2>/dev/null || echo unknown`
-
-/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
-/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
-
-/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
-/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
-/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
-/usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
-/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
-/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
-/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
-
-_ASUNAME
-
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- $as_echo "PATH: $as_dir"
- done
-IFS=$as_save_IFS
-
-} >&5
-
-cat >&5 <<_ACEOF
-
-
-## ----------- ##
-## Core tests. ##
-## ----------- ##
-
-_ACEOF
-
-
-# Keep a trace of the command line.
-# Strip out --no-create and --no-recursion so they do not pile up.
-# Strip out --silent because we don't want to record it for future runs.
-# Also quote any args containing shell meta-characters.
-# Make two passes to allow for proper duplicate-argument suppression.
-ac_configure_args=
-ac_configure_args0=
-ac_configure_args1=
-ac_must_keep_next=false
-for ac_pass in 1 2
-do
- for ac_arg
- do
- case $ac_arg in
- -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
- -q | -quiet | --quiet | --quie | --qui | --qu | --q \
- | -silent | --silent | --silen | --sile | --sil)
- continue ;;
- *\'*)
- ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
- esac
- case $ac_pass in
- 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
- 2)
- as_fn_append ac_configure_args1 " '$ac_arg'"
- if test $ac_must_keep_next = true; then
- ac_must_keep_next=false # Got value, back to normal.
- else
- case $ac_arg in
- *=* | --config-cache | -C | -disable-* | --disable-* \
- | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
- | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
- | -with-* | --with-* | -without-* | --without-* | --x)
- case "$ac_configure_args0 " in
- "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
- esac
- ;;
- -* ) ac_must_keep_next=true ;;
- esac
- fi
- as_fn_append ac_configure_args " '$ac_arg'"
- ;;
- esac
- done
-done
-{ ac_configure_args0=; unset ac_configure_args0;}
-{ ac_configure_args1=; unset ac_configure_args1;}
-
-# When interrupted or exit'd, cleanup temporary files, and complete
-# config.log. We remove comments because anyway the quotes in there
-# would cause problems or look ugly.
-# WARNING: Use '\'' to represent an apostrophe within the trap.
-# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
-trap 'exit_status=$?
- # Save into config.log some information that might help in debugging.
- {
- echo
-
- $as_echo "## ---------------- ##
-## Cache variables. ##
-## ---------------- ##"
- echo
- # The following way of writing the cache mishandles newlines in values,
-(
- for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
- eval ac_val=\$$ac_var
- case $ac_val in #(
- *${as_nl}*)
- case $ac_var in #(
- *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
-$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
- esac
- case $ac_var in #(
- _ | IFS | as_nl) ;; #(
- BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
- *) { eval $ac_var=; unset $ac_var;} ;;
- esac ;;
- esac
- done
- (set) 2>&1 |
- case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
- *${as_nl}ac_space=\ *)
- sed -n \
- "s/'\''/'\''\\\\'\'''\''/g;
- s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
- ;; #(
- *)
- sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
- ;;
- esac |
- sort
-)
- echo
-
- $as_echo "## ----------------- ##
-## Output variables. ##
-## ----------------- ##"
- echo
- for ac_var in $ac_subst_vars
- do
- eval ac_val=\$$ac_var
- case $ac_val in
- *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
- esac
- $as_echo "$ac_var='\''$ac_val'\''"
- done | sort
- echo
-
- if test -n "$ac_subst_files"; then
- $as_echo "## ------------------- ##
-## File substitutions. ##
-## ------------------- ##"
- echo
- for ac_var in $ac_subst_files
- do
- eval ac_val=\$$ac_var
- case $ac_val in
- *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
- esac
- $as_echo "$ac_var='\''$ac_val'\''"
- done | sort
- echo
- fi
-
- if test -s confdefs.h; then
- $as_echo "## ----------- ##
-## confdefs.h. ##
-## ----------- ##"
- echo
- cat confdefs.h
- echo
- fi
- test "$ac_signal" != 0 &&
- $as_echo "$as_me: caught signal $ac_signal"
- $as_echo "$as_me: exit $exit_status"
- } >&5
- rm -f core *.core core.conftest.* &&
- rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
- exit $exit_status
-' 0
-for ac_signal in 1 2 13 15; do
- trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
-done
-ac_signal=0
-
-# confdefs.h avoids OS command line length limits that DEFS can exceed.
-rm -f -r conftest* confdefs.h
-
-$as_echo "/* confdefs.h */" > confdefs.h
-
-# Predefined preprocessor variables.
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_NAME "$PACKAGE_NAME"
-_ACEOF
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
-_ACEOF
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_VERSION "$PACKAGE_VERSION"
-_ACEOF
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_STRING "$PACKAGE_STRING"
-_ACEOF
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
-_ACEOF
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_URL "$PACKAGE_URL"
-_ACEOF
-
-
-# Let the site file select an alternate cache file if it wants to.
-# Prefer an explicitly selected file to automatically selected ones.
-ac_site_file1=NONE
-ac_site_file2=NONE
-if test -n "$CONFIG_SITE"; then
- # We do not want a PATH search for config.site.
- case $CONFIG_SITE in #((
- -*) ac_site_file1=./$CONFIG_SITE;;
- */*) ac_site_file1=$CONFIG_SITE;;
- *) ac_site_file1=./$CONFIG_SITE;;
- esac
-elif test "x$prefix" != xNONE; then
- ac_site_file1=$prefix/share/config.site
- ac_site_file2=$prefix/etc/config.site
-else
- ac_site_file1=$ac_default_prefix/share/config.site
- ac_site_file2=$ac_default_prefix/etc/config.site
-fi
-for ac_site_file in "$ac_site_file1" "$ac_site_file2"
-do
- test "x$ac_site_file" = xNONE && continue
- if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
-$as_echo "$as_me: loading site script $ac_site_file" >&6;}
- sed 's/^/| /' "$ac_site_file" >&5
- . "$ac_site_file" \
- || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "failed to load site script $ac_site_file
-See \`config.log' for more details" "$LINENO" 5; }
- fi
-done
-
-if test -r "$cache_file"; then
- # Some versions of bash will fail to source /dev/null (special files
- # actually), so we avoid doing that. DJGPP emulates it as a regular file.
- if test /dev/null != "$cache_file" && test -f "$cache_file"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
-$as_echo "$as_me: loading cache $cache_file" >&6;}
- case $cache_file in
- [\\/]* | ?:[\\/]* ) . "$cache_file";;
- *) . "./$cache_file";;
- esac
- fi
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
-$as_echo "$as_me: creating cache $cache_file" >&6;}
- >$cache_file
-fi
-
-# Check that the precious variables saved in the cache have kept the same
-# value.
-ac_cache_corrupted=false
-for ac_var in $ac_precious_vars; do
- eval ac_old_set=\$ac_cv_env_${ac_var}_set
- eval ac_new_set=\$ac_env_${ac_var}_set
- eval ac_old_val=\$ac_cv_env_${ac_var}_value
- eval ac_new_val=\$ac_env_${ac_var}_value
- case $ac_old_set,$ac_new_set in
- set,)
- { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
-$as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
- ac_cache_corrupted=: ;;
- ,set)
- { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
-$as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
- ac_cache_corrupted=: ;;
- ,);;
- *)
- if test "x$ac_old_val" != "x$ac_new_val"; then
- # differences in whitespace do not lead to failure.
- ac_old_val_w=`echo x $ac_old_val`
- ac_new_val_w=`echo x $ac_new_val`
- if test "$ac_old_val_w" != "$ac_new_val_w"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
-$as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
- ac_cache_corrupted=:
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
-$as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
- eval $ac_var=\$ac_old_val
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
-$as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
-$as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
- fi;;
- esac
- # Pass precious variables to config.status.
- if test "$ac_new_set" = set; then
- case $ac_new_val in
- *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
- *) ac_arg=$ac_var=$ac_new_val ;;
- esac
- case " $ac_configure_args " in
- *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
- *) as_fn_append ac_configure_args " '$ac_arg'" ;;
- esac
- fi
-done
-if $ac_cache_corrupted; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
-$as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
- as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
-fi
-## -------------------- ##
-## Main body of script. ##
-## -------------------- ##
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-
-
-
-
-
-
-
-
-progname=$0
-# if PWD already has a value, it is probably wrong.
-if test -n "$PWD" ; then PWD=`${PWDCMD-pwd}`; fi
-
-# Export original configure arguments for use by sub-configures.
-# Quote arguments with shell meta charatcers.
-TOPLEVEL_CONFIGURE_ARGUMENTS=
-set -- "$progname" "$@"
-for ac_arg
-do
- case "$ac_arg" in
- *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\']*)
- ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"`
- # if the argument is of the form -foo=baz, quote the baz part only
- ac_arg=`echo "'$ac_arg'" | sed "s/^'\([-a-zA-Z0-9]*=\)/\\1'/"` ;;
- *) ;;
- esac
- # Add the quoted argument to the list.
- TOPLEVEL_CONFIGURE_ARGUMENTS="$TOPLEVEL_CONFIGURE_ARGUMENTS $ac_arg"
-done
-if test "$silent" = yes; then
- TOPLEVEL_CONFIGURE_ARGUMENTS="$TOPLEVEL_CONFIGURE_ARGUMENTS --silent"
-fi
-# Remove the initial space we just introduced and, as these will be
-# expanded by make, quote '$'.
-TOPLEVEL_CONFIGURE_ARGUMENTS=`echo "x$TOPLEVEL_CONFIGURE_ARGUMENTS" | sed -e 's/^x *//' -e 's,\\$,$$,g'`
-
-
-# Find the build, host, and target systems.
-ac_aux_dir=
-for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
- if test -f "$ac_dir/install-sh"; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install-sh -c"
- break
- elif test -f "$ac_dir/install.sh"; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install.sh -c"
- break
- elif test -f "$ac_dir/shtool"; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/shtool install -c"
- break
- fi
-done
-if test -z "$ac_aux_dir"; then
- as_fn_error $? "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5
-fi
-
-# These three variables are undocumented and unsupported,
-# and are intended to be withdrawn in a future Autoconf release.
-# They can cause serious problems if a builder's source tree is in a directory
-# whose full name contains unusual characters.
-ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
-ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
-ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
-
-
-# Make sure we can run config.sub.
-$SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
- as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
-$as_echo_n "checking build system type... " >&6; }
-if ${ac_cv_build+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_build_alias=$build_alias
-test "x$ac_build_alias" = x &&
- ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
-test "x$ac_build_alias" = x &&
- as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
-ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
- as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
-$as_echo "$ac_cv_build" >&6; }
-case $ac_cv_build in
-*-*-*) ;;
-*) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
-esac
-build=$ac_cv_build
-ac_save_IFS=$IFS; IFS='-'
-set x $ac_cv_build
-shift
-build_cpu=$1
-build_vendor=$2
-shift; shift
-# Remember, the first character of IFS is used to create $*,
-# except with old shells:
-build_os=$*
-IFS=$ac_save_IFS
-case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
-
-
- case ${build_alias} in
- "") build_noncanonical=${build} ;;
- *) build_noncanonical=${build_alias} ;;
-esac
-
-
-
- case ${host_alias} in
- "") host_noncanonical=${build_noncanonical} ;;
- *) host_noncanonical=${host_alias} ;;
-esac
-
-
-
- case ${target_alias} in
- "") target_noncanonical=${host_noncanonical} ;;
- *) target_noncanonical=${target_alias} ;;
-esac
-
-
-
-
-test "$host_noncanonical" = "$target_noncanonical" &&
- test "$program_prefix$program_suffix$program_transform_name" = \
- NONENONEs,x,x, &&
- program_transform_name=s,y,y,
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
-$as_echo_n "checking host system type... " >&6; }
-if ${ac_cv_host+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test "x$host_alias" = x; then
- ac_cv_host=$ac_cv_build
-else
- ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
- as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
-$as_echo "$ac_cv_host" >&6; }
-case $ac_cv_host in
-*-*-*) ;;
-*) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
-esac
-host=$ac_cv_host
-ac_save_IFS=$IFS; IFS='-'
-set x $ac_cv_host
-shift
-host_cpu=$1
-host_vendor=$2
-shift; shift
-# Remember, the first character of IFS is used to create $*,
-# except with old shells:
-host_os=$*
-IFS=$ac_save_IFS
-case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking target system type" >&5
-$as_echo_n "checking target system type... " >&6; }
-if ${ac_cv_target+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test "x$target_alias" = x; then
- ac_cv_target=$ac_cv_host
-else
- ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` ||
- as_fn_error $? "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5
-$as_echo "$ac_cv_target" >&6; }
-case $ac_cv_target in
-*-*-*) ;;
-*) as_fn_error $? "invalid value of canonical target" "$LINENO" 5;;
-esac
-target=$ac_cv_target
-ac_save_IFS=$IFS; IFS='-'
-set x $ac_cv_target
-shift
-target_cpu=$1
-target_vendor=$2
-shift; shift
-# Remember, the first character of IFS is used to create $*,
-# except with old shells:
-target_os=$*
-IFS=$ac_save_IFS
-case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac
-
-
-# The aliases save the names the user supplied, while $host etc.
-# will get canonicalized.
-test -n "$target_alias" &&
- test "$program_prefix$program_suffix$program_transform_name" = \
- NONENONEs,x,x, &&
- program_prefix=${target_alias}-
-test "$program_prefix" != NONE &&
- program_transform_name="s&^&$program_prefix&;$program_transform_name"
-# Use a double $ so make ignores it.
-test "$program_suffix" != NONE &&
- program_transform_name="s&\$&$program_suffix&;$program_transform_name"
-# Double any \ or $.
-# By default was `s,x,x', remove it if useless.
-ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
-program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
-
-
-
-# Get 'install' or 'install-sh' and its variants.
-# Find a good install program. We prefer a C program (faster),
-# so one script is as good as another. But avoid the broken or
-# incompatible versions:
-# SysV /etc/install, /usr/sbin/install
-# SunOS /usr/etc/install
-# IRIX /sbin/install
-# AIX /bin/install
-# AmigaOS /C/install, which installs bootblocks on floppy discs
-# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
-# AFS /usr/afsws/bin/install, which mishandles nonexistent args
-# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
-# OS/2's system install, which has a completely different semantic
-# ./install, which can be erroneously created by make from ./install.sh.
-# Reject install programs that cannot install multiple files.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
-$as_echo_n "checking for a BSD-compatible install... " >&6; }
-if test -z "$INSTALL"; then
-if ${ac_cv_path_install+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- # Account for people who put trailing slashes in PATH elements.
-case $as_dir/ in #((
- ./ | .// | /[cC]/* | \
- /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
- ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
- /usr/ucb/* ) ;;
- *)
- # OSF1 and SCO ODT 3.0 have their own names for install.
- # Don't use installbsd from OSF since it installs stuff as root
- # by default.
- for ac_prog in ginstall scoinst install; do
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
- if test $ac_prog = install &&
- grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
- # AIX install. It has an incompatible calling convention.
- :
- elif test $ac_prog = install &&
- grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
- # program-specific install script used by HP pwplus--don't use.
- :
- else
- rm -rf conftest.one conftest.two conftest.dir
- echo one > conftest.one
- echo two > conftest.two
- mkdir conftest.dir
- if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
- test -s conftest.one && test -s conftest.two &&
- test -s conftest.dir/conftest.one &&
- test -s conftest.dir/conftest.two
- then
- ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
- break 3
- fi
- fi
- fi
- done
- done
- ;;
-esac
-
- done
-IFS=$as_save_IFS
-
-rm -rf conftest.one conftest.two conftest.dir
-
-fi
- if test "${ac_cv_path_install+set}" = set; then
- INSTALL=$ac_cv_path_install
- else
- # As a last resort, use the slow shell script. Don't cache a
- # value for INSTALL within a source directory, because that will
- # break other packages using the cache if that directory is
- # removed, or if the value is a relative name.
- INSTALL=$ac_install_sh
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
-$as_echo "$INSTALL" >&6; }
-
-# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
-# It thinks the first close brace ends the variable substitution.
-test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
-
-test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
-
-test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln works" >&5
-$as_echo_n "checking whether ln works... " >&6; }
-if ${acx_cv_prog_LN+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- rm -f conftestdata_t
-echo >conftestdata_f
-if ln conftestdata_f conftestdata_t 2>/dev/null
-then
- acx_cv_prog_LN=ln
-else
- acx_cv_prog_LN=no
-fi
-rm -f conftestdata_f conftestdata_t
-
-fi
-if test $acx_cv_prog_LN = no; then
- LN="cp"
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN" >&5
-$as_echo "no, using $LN" >&6; }
-else
- LN="$acx_cv_prog_LN"
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
-$as_echo_n "checking whether ln -s works... " >&6; }
-LN_S=$as_ln_s
-if test "$LN_S" = "ln -s"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
-$as_echo "no, using $LN_S" >&6; }
-fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
-$as_echo_n "checking for a sed that does not truncate output... " >&6; }
-if ${ac_cv_path_SED+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
- for ac_i in 1 2 3 4 5 6 7; do
- ac_script="$ac_script$as_nl$ac_script"
- done
- echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
- { ac_script=; unset ac_script;}
- if test -z "$SED"; then
- ac_path_SED_found=false
- # Loop through the user's path and test for each of PROGNAME-LIST
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_prog in sed gsed; do
- for ac_exec_ext in '' $ac_executable_extensions; do
- ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
- as_fn_executable_p "$ac_path_SED" || continue
-# Check for GNU ac_path_SED and select it if it is found.
- # Check for GNU $ac_path_SED
-case `"$ac_path_SED" --version 2>&1` in
-*GNU*)
- ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
-*)
- ac_count=0
- $as_echo_n 0123456789 >"conftest.in"
- while :
- do
- cat "conftest.in" "conftest.in" >"conftest.tmp"
- mv "conftest.tmp" "conftest.in"
- cp "conftest.in" "conftest.nl"
- $as_echo '' >> "conftest.nl"
- "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
- diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
- as_fn_arith $ac_count + 1 && ac_count=$as_val
- if test $ac_count -gt ${ac_path_SED_max-0}; then
- # Best one so far, save it but keep looking for a better one
- ac_cv_path_SED="$ac_path_SED"
- ac_path_SED_max=$ac_count
- fi
- # 10*(2^10) chars as input seems more than enough
- test $ac_count -gt 10 && break
- done
- rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
-esac
-
- $ac_path_SED_found && break 3
- done
- done
- done
-IFS=$as_save_IFS
- if test -z "$ac_cv_path_SED"; then
- as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
- fi
-else
- ac_cv_path_SED=$SED
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
-$as_echo "$ac_cv_path_SED" >&6; }
- SED="$ac_cv_path_SED"
- rm -f conftest.sed
-
-for ac_prog in gawk mawk nawk awk
-do
- # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_AWK+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$AWK"; then
- ac_cv_prog_AWK="$AWK" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_AWK="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-AWK=$ac_cv_prog_AWK
-if test -n "$AWK"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
-$as_echo "$AWK" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$AWK" && break
-done
-
-
-srcpwd=`cd ${srcdir} ; ${PWDCMD-pwd}`
-
-# We pass INSTALL explicitly to sub-makes. Make sure that it is not
-# a relative path.
-if test "$INSTALL" = "${srcdir}/install-sh -c"; then
- INSTALL="${srcpwd}/install-sh -c"
-fi
-
-# Set srcdir to "." if that's what it is.
-# This is important for multilib support.
-pwd=`${PWDCMD-pwd}`
-if test "${pwd}" = "${srcpwd}" ; then
- srcdir=.
-fi
-
-topsrcdir=$srcpwd
-
-extra_host_args=
-
-### To add a new directory to the tree, first choose whether it is a target
-### or a host dependent tool. Then put it into the appropriate list
-### (library or tools, host or target), doing a dependency sort.
-
-# Subdirs will be configured in the order listed in build_configdirs,
-# configdirs, or target_configdirs; see the serialization section below.
-
-# Dependency sorting is only needed when *configuration* must be done in
-# a particular order. In all cases a dependency should be specified in
-# the Makefile, whether or not it's implicitly specified here.
-
-# Double entries in build_configdirs, configdirs, or target_configdirs may
-# cause circular dependencies and break everything horribly.
-
-# these library is used by various programs built for the build
-# environment
-#
-build_libs="build-libiberty build-libcpp"
-
-# these tools are built for the build environment
-build_tools="build-texinfo build-flex build-bison build-m4 build-fixincludes"
-
-# these libraries are used by various programs built for the host environment
-#f
-host_libs="gettext libiberty opcodes bfd readline tcl tk itcl libgui zlib libbacktrace libcpp libcody libdecnumber gmp mpfr mpc isl libiconv libctf libsframe libgrust "
-
-# these tools are built for the host environment
-# Note, the powerpc-eabi build depends on sim occurring before gdb in order to
-# know that we are building the simulator.
-# binutils, gas and ld appear in that order because it makes sense to run
-# "make check" in that particular order.
-# If --enable-gold is used, "gold" may replace "ld".
-host_tools="texinfo flex bison binutils gas ld fixincludes gcc cgen sid sim gdb gdbserver gprof etc expect dejagnu m4 utils guile fastjar gnattools libcc1 gm2tools gotools c++tools"
-
-# these libraries are built for the target environment, and are built after
-# the host libraries and the host tools (which may be a cross compiler)
-# Note that libiberty is not a target library.
-target_libraries="target-libgcc \
- target-libbacktrace \
- target-libgloss \
- target-newlib \
- target-libgomp \
- target-libatomic \
- target-libitm \
- target-libstdc++-v3 \
- target-libsanitizer \
- target-libvtv \
- target-libssp \
- target-libquadmath \
- target-libgfortran \
- target-libffi \
- target-libobjc \
- target-libada \
- target-libgm2 \
- target-libgo \
- target-libgrust \
- target-libphobos \
- target-zlib"
-
-# these tools are built using the target libraries, and are intended to
-# run only in the target environment
-#
-# note: any program that *uses* libraries that are in the "target_libraries"
-# list belongs in this list.
-#
-target_tools="target-rda"
-
-################################################################################
-
-## All tools belong in one of the four categories, and are assigned above
-## We assign ${configdirs} this way to remove all embedded newlines. This
-## is important because configure will choke if they ever get through.
-## ${configdirs} is directories we build using the host tools.
-## ${target_configdirs} is directories we build using the target tools.
-configdirs=`echo ${host_libs} ${host_tools}`
-target_configdirs=`echo ${target_libraries} ${target_tools}`
-build_configdirs=`echo ${build_libs} ${build_tools}`
-
-
-
-################################################################################
-
-srcname="gnu development package"
-
-# This gets set non-empty for some net releases of packages.
-appdirs=""
-
-# Define is_cross_compiler to save on calls to 'test'.
-is_cross_compiler=
-if test x"${host}" = x"${target}" ; then
- is_cross_compiler=no
-else
- is_cross_compiler=yes
-fi
-
-# Find the build and target subdir names.
-
-# post-stage1 host modules use a different CC_FOR_BUILD so, in order to
-# have matching libraries, they should use host libraries: Makefile.tpl
-# arranges to pass --with-build-libsubdir=$(HOST_SUBDIR).
-# However, they still use the build modules, because the corresponding
-# host modules (e.g. bison) are only built for the host when bootstrap
-# finishes. So:
-# - build_subdir is where we find build modules, and never changes.
-# - build_libsubdir is where we find build libraries, and can be overridden.
-
-# Prefix 'build-' so this never conflicts with target_subdir.
-build_subdir="build-${build_noncanonical}"
-
-# Check whether --with-build-libsubdir was given.
-if test "${with_build_libsubdir+set}" = set; then :
- withval=$with_build_libsubdir; build_libsubdir="$withval"
-else
- build_libsubdir="$build_subdir"
-fi
-
-# --srcdir=. covers the toplevel, while "test -d" covers the subdirectories
-if ( test $srcdir = . && test -d gcc ) \
- || test -d $srcdir/../host-${host_noncanonical}; then
- host_subdir="host-${host_noncanonical}"
-else
- host_subdir=.
-fi
-# No prefix.
-target_subdir=${target_noncanonical}
-
-# Be sure to cover against remnants of an in-tree build.
-if test $srcdir != . && test -d $srcdir/host-${host_noncanonical}; then
- as_fn_error $? "building out of tree but $srcdir contains host-${host_noncanonical}.
-Use a pristine source tree when building in a separate tree" "$LINENO" 5
-fi
-
-# Skipdirs are removed silently.
-skipdirs=
-# Noconfigdirs are removed loudly.
-noconfigdirs=""
-
-use_gnu_ld=
-# Make sure we don't let GNU ld be added if we didn't want it.
-if test x$with_gnu_ld = xno ; then
- use_gnu_ld=no
- noconfigdirs="$noconfigdirs ld gold"
-fi
-
-use_gnu_as=
-# Make sure we don't let GNU as be added if we didn't want it.
-if test x$with_gnu_as = xno ; then
- use_gnu_as=no
- noconfigdirs="$noconfigdirs gas"
-fi
-
-use_included_zlib=
-
-# Check whether --with-system-zlib was given.
-if test "${with_system_zlib+set}" = set; then :
- withval=$with_system_zlib;
-fi
-
-# Make sure we don't let ZLIB be added if we didn't want it.
-if test x$with_system_zlib = xyes ; then
- use_included_zlib=no
- noconfigdirs="$noconfigdirs zlib"
-fi
-
-# Don't compile the bundled readline/libreadline.a if --with-system-readline
-# is provided.
-if test x$with_system_readline = xyes ; then
- noconfigdirs="$noconfigdirs readline"
-fi
-
-
-# Check whether --with-zstd was given.
-if test "${with_zstd+set}" = set; then :
- withval=$with_zstd;
-fi
-
-
-# some tools are so dependent upon X11 that if we're not building with X,
-# it's not even worth trying to configure, much less build, that tool.
-
-case ${with_x} in
- yes | "") ;; # the default value for this tree is that X11 is available
- no)
- skipdirs="${skipdirs} tk itcl libgui"
- # We won't be able to build gdbtk without X.
- enable_gdbtk=no
- ;;
- *) echo "*** bad value \"${with_x}\" for -with-x flag; ignored" 1>&2 ;;
-esac
-
-# Some are only suitable for cross toolchains.
-# Remove these if host=target.
-cross_only="target-libgloss target-newlib target-opcodes"
-
-case $is_cross_compiler in
- no) skipdirs="${skipdirs} ${cross_only}" ;;
-esac
-
-# If both --with-headers and --with-libs are specified, default to
-# --without-newlib.
-if test x"${with_headers}" != x && test x"${with_headers}" != xno \
- && test x"${with_libs}" != x && test x"${with_libs}" != xno ; then
- if test x"${with_newlib}" = x ; then
- with_newlib=no
- fi
-fi
-
-# Recognize --with-newlib/--without-newlib.
-case ${with_newlib} in
- no) skipdirs="${skipdirs} target-newlib" ;;
- yes) skipdirs=`echo " ${skipdirs} " | sed -e 's/ target-newlib / /'` ;;
-esac
-
-# Check whether --enable-as-accelerator-for was given.
-if test "${enable_as_accelerator_for+set}" = set; then :
- enableval=$enable_as_accelerator_for;
-fi
-
-
-# Check whether --enable-offload-targets was given.
-if test "${enable_offload_targets+set}" = set; then :
- enableval=$enable_offload_targets;
- if test x"$enable_offload_targets" = x; then
- as_fn_error $? "no offload targets specified" "$LINENO" 5
- fi
-
-else
- enable_offload_targets=
-fi
-
-
-# Check whether --enable-offload-defaulted was given.
-if test "${enable_offload_defaulted+set}" = set; then :
- enableval=$enable_offload_defaulted; enable_offload_defaulted=$enableval
-else
- enable_offload_defaulted=
-fi
-
-
-# Handle --enable-gold, --enable-ld.
-# --disable-gold [--enable-ld]
-# Build only ld. Default option.
-# --enable-gold [--enable-ld]
-# Build both gold and ld. Install gold as "ld.gold", install ld
-# as "ld.bfd" and "ld".
-# --enable-gold=default [--enable-ld]
-# Build both gold and ld. Install gold as "ld.gold" and "ld",
-# install ld as "ld.bfd".
-# --enable-gold[=default] --disable-ld
-# Build only gold, which is then installed as both "ld.gold" and "ld".
-# --enable-gold --enable-ld=default
-# Build both gold (installed as "ld.gold") and ld (installed as "ld"
-# and ld.bfd).
-# In other words, ld is default
-# --enable-gold=default --enable-ld=default
-# Error.
-
-default_ld=
-# Check whether --enable-gold was given.
-if test "${enable_gold+set}" = set; then :
- enableval=$enable_gold; ENABLE_GOLD=$enableval
-else
- ENABLE_GOLD=no
-fi
-
-case "${ENABLE_GOLD}" in
- yes|default)
- # Check for ELF target.
- is_elf=no
- case "${target}" in
- *-*-elf* | *-*-sysv4* | *-*-unixware* | *-*-eabi* | hppa*64*-*-hpux* \
- | *-*-linux* | *-*-gnu* | frv-*-uclinux* | *-*-irix5* | *-*-irix6* \
- | *-*-netbsd* | *-*-openbsd* | *-*-freebsd* | *-*-dragonfly* \
- | *-*-solaris2* | *-*-nto* | *-*-nacl* | *-*-haiku*)
- case "${target}" in
- *-*-linux*aout* | *-*-linux*oldld*)
- ;;
- *)
- is_elf=yes
- ;;
- esac
- esac
-
- if test "$is_elf" = "yes"; then
- # Check for target supported by gold.
- case "${target}" in
- i?86-*-* | x86_64-*-* | sparc*-*-* | powerpc*-*-* | arm*-*-* \
- | aarch64*-*-* | tilegx*-*-* | mips*-*-* | s390*-*-* | loongarch*-*-*)
- configdirs="$configdirs gold"
- if test x${ENABLE_GOLD} = xdefault; then
- default_ld=gold
- fi
- ENABLE_GOLD=yes
- ;;
- esac
- fi
- ;;
- no)
- ;;
- *)
- as_fn_error $? "invalid --enable-gold argument" "$LINENO" 5
- ;;
-esac
-
-# Check whether --enable-ld was given.
-if test "${enable_ld+set}" = set; then :
- enableval=$enable_ld; ENABLE_LD=$enableval
-else
- ENABLE_LD=yes
-fi
-
-
-case "${ENABLE_LD}" in
- default)
- if test x${default_ld} != x; then
- as_fn_error $? "either gold or ld can be the default ld" "$LINENO" 5
- fi
- ;;
- yes)
- ;;
- no)
- if test x${ENABLE_GOLD} != xyes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: neither ld nor gold are enabled" >&5
-$as_echo "$as_me: WARNING: neither ld nor gold are enabled" >&2;}
- fi
- configdirs=`echo " ${configdirs} " | sed -e 's/ ld / /'`
- ;;
- *)
- as_fn_error $? "invalid --enable-ld argument" "$LINENO" 5
- ;;
-esac
-
-# Check whether --enable-gprofng was given.
-if test "${enable_gprofng+set}" = set; then :
- enableval=$enable_gprofng; enable_gprofng=$enableval
-else
- enable_gprofng=yes
-fi
-
-if test "$enable_gprofng" = "yes"; then
- case "${target}" in
- x86_64-*-linux* | i?86-*-linux* | aarch64-*-linux* | riscv64-*-linux*)
- configdirs="$configdirs gprofng"
- ;;
- esac
-fi
-
-
-# PR gas/19109
-# Decide the default method for compressing debug sections.
-# Provide a configure time option to override our default.
-# Check whether --enable-compressed_debug_sections was given.
-if test "${enable_compressed_debug_sections+set}" = set; then :
- enableval=$enable_compressed_debug_sections;
- if test x"$enable_compressed_debug_sections" = xyes; then
- as_fn_error $? "no program with compressed debug sections specified" "$LINENO" 5
- fi
-
-else
- enable_compressed_debug_sections=
-fi
-
-
-# Select default compression algorithm.
-# Check whether --enable-default_compressed_debug_sections_algorithm was given.
-if test "${enable_default_compressed_debug_sections_algorithm+set}" = set; then :
- enableval=$enable_default_compressed_debug_sections_algorithm;
-else
- default_compressed_debug_sections_algorithm=
-fi
-
-
-# Configure extra directories which are host specific
-
-case "${host}" in
- *-cygwin*)
- configdirs="$configdirs libtermcap" ;;
-esac
-
-# A target can indicate whether a language isn't supported for some reason.
-# Only spaces may be used in this macro; not newlines or tabs.
-unsupported_languages=
-
-# Remove more programs from consideration, based on the host or
-# target this usually means that a port of the program doesn't
-# exist yet.
-
-case "${host}" in
- i[3456789]86-*-msdosdjgpp*)
- noconfigdirs="$noconfigdirs tcl tk itcl"
- ;;
-esac
-
-# Default to --disable-year2038 until we can handle differences between
-# projects that use gnulib (which understands year 2038) and projects that
-# do not (like BFD).
-# Check whether --enable-year2038 was given.
-if test "${enable_year2038+set}" = set; then :
- enableval=$enable_year2038; ENABLE_YEAR2038=$enableval
-else
- ENABLE_YEAR2038=no
-fi
-
-enable_year2038=
-if test "${ENABLE_YEAR2038}" = "no" ; then
- enable_year2038=no
-fi
-
-# Check whether --enable-libquadmath was given.
-if test "${enable_libquadmath+set}" = set; then :
- enableval=$enable_libquadmath; ENABLE_LIBQUADMATH=$enableval
-else
- ENABLE_LIBQUADMATH=yes
-fi
-
-if test "${ENABLE_LIBQUADMATH}" = "no" ; then
- noconfigdirs="$noconfigdirs target-libquadmath"
-fi
-
-
-# Check whether --enable-libquadmath-support was given.
-if test "${enable_libquadmath_support+set}" = set; then :
- enableval=$enable_libquadmath_support; ENABLE_LIBQUADMATH_SUPPORT=$enableval
-else
- ENABLE_LIBQUADMATH_SUPPORT=yes
-fi
-
-enable_libquadmath_support=
-if test "${ENABLE_LIBQUADMATH_SUPPORT}" = "no" ; then
- enable_libquadmath_support=no
-fi
-
-
-# Check whether --enable-libada was given.
-if test "${enable_libada+set}" = set; then :
- enableval=$enable_libada; ENABLE_LIBADA=$enableval
-else
- ENABLE_LIBADA=yes
-fi
-
-if test "${ENABLE_LIBADA}" != "yes" ; then
- noconfigdirs="$noconfigdirs gnattools"
-fi
-
-# Check whether --enable-libgm2 was given.
-if test "${enable_libgm2+set}" = set; then :
- enableval=$enable_libgm2; ENABLE_LIBGM2=$enableval
-else
- ENABLE_LIBGM2=no
-fi
-
-if test "${ENABLE_LIBGM2}" != "yes" ; then
- noconfigdirs="$noconfigdirs gm2tools"
-fi
-
-# Check whether --enable-libssp was given.
-if test "${enable_libssp+set}" = set; then :
- enableval=$enable_libssp; ENABLE_LIBSSP=$enableval
-else
- ENABLE_LIBSSP=yes
-fi
-
-
-# Check whether --enable-libstdcxx was given.
-if test "${enable_libstdcxx+set}" = set; then :
- enableval=$enable_libstdcxx; ENABLE_LIBSTDCXX=$enableval
-else
- ENABLE_LIBSTDCXX=default
-fi
-
-if test "${ENABLE_LIBSTDCXX}" = "no" ; then
- noconfigdirs="$noconfigdirs target-libstdc++-v3"
-fi
-
-# Enable libgomp by default on hosted POSIX systems, and a few others.
-if test x$enable_libgomp = x ; then
- case "${target}" in
- *-*-linux* | *-*-gnu* | *-*-k*bsd*-gnu | *-*-kopensolaris*-gnu)
- ;;
- *-*-netbsd* | *-*-freebsd* | *-*-openbsd* | *-*-dragonfly*)
- ;;
- *-*-solaris2* | *-*-hpux11*)
- ;;
- *-*-darwin* | *-*-aix*)
- ;;
- nvptx*-*-* | amdgcn*-*-*)
- ;;
- *)
- noconfigdirs="$noconfigdirs target-libgomp"
- ;;
- esac
-fi
-
-# Disable libatomic on unsupported systems.
-if test -d ${srcdir}/libatomic; then
- if test x$enable_libatomic = x; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libatomic support" >&5
-$as_echo_n "checking for libatomic support... " >&6; }
- if (srcdir=${srcdir}/libatomic; \
- . ${srcdir}/configure.tgt; \
- test -n "$UNSUPPORTED")
- then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- noconfigdirs="$noconfigdirs target-libatomic"
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- fi
- fi
-fi
-
-# Disable libitm on unsupported systems.
-if test -d ${srcdir}/libitm; then
- if test x$enable_libitm = x; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libitm support" >&5
-$as_echo_n "checking for libitm support... " >&6; }
- if (srcdir=${srcdir}/libitm; \
- . ${srcdir}/configure.tgt; \
- test -n "$UNSUPPORTED")
- then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- noconfigdirs="$noconfigdirs target-libitm"
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- fi
- fi
-fi
-
-# Disable libsanitizer on unsupported systems.
-if test -d ${srcdir}/libsanitizer; then
- if test x$enable_libsanitizer = x; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libsanitizer support" >&5
-$as_echo_n "checking for libsanitizer support... " >&6; }
- if (srcdir=${srcdir}/libsanitizer; \
- . ${srcdir}/configure.tgt; \
- test -n "$UNSUPPORTED")
- then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- noconfigdirs="$noconfigdirs target-libsanitizer"
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- fi
- fi
-fi
-
-# Disable libvtv on unsupported systems.
-if test -d ${srcdir}/libvtv; then
- if test x$enable_libvtv = x; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libvtv support" >&5
-$as_echo_n "checking for libvtv support... " >&6; }
- if (srcdir=${srcdir}/libvtv; \
- . ${srcdir}/configure.tgt; \
- test "$VTV_SUPPORTED" != "yes")
- then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- noconfigdirs="$noconfigdirs target-libvtv"
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- fi
- fi
-fi
-
-# Disable libquadmath for some systems.
-case "${target}" in
- avr-*-*)
- noconfigdirs="$noconfigdirs target-libquadmath"
- ;;
- # libquadmath is unused on AIX and libquadmath build process use of
- # LD_LIBRARY_PATH can break AIX bootstrap.
- powerpc-*-aix* | rs6000-*-aix*)
- noconfigdirs="$noconfigdirs target-libquadmath"
- ;;
-esac
-
-# Disable libssp for some systems.
-case "${target}" in
- avr-*-*)
- # No hosted I/O support.
- noconfigdirs="$noconfigdirs target-libssp"
- ;;
- bpf-*-*)
- noconfigdirs="$noconfigdirs target-libssp"
- ;;
- powerpc-*-aix* | rs6000-*-aix*)
- noconfigdirs="$noconfigdirs target-libssp"
- ;;
- pru-*-*)
- # No hosted I/O support.
- noconfigdirs="$noconfigdirs target-libssp"
- ;;
- rl78-*-*)
- # libssp uses a misaligned load to trigger a fault, but the RL78
- # doesn't fault for those - instead, it gives a build-time error
- # for explicit misaligned loads.
- noconfigdirs="$noconfigdirs target-libssp"
- ;;
- visium-*-*)
- # No hosted I/O support.
- noconfigdirs="$noconfigdirs target-libssp"
- ;;
-esac
-
-# Disable libstdc++-v3 for some systems.
-# Allow user to override this if they pass --enable-libstdcxx
-if test "${ENABLE_LIBSTDCXX}" = "default" ; then
- case "${target}" in
- *-*-vxworks*)
- # VxWorks uses the Dinkumware C++ library.
- noconfigdirs="$noconfigdirs target-libstdc++-v3"
- ;;
- amdgcn*-*-*)
- # Not ported/fails to build when using newlib.
- noconfigdirs="$noconfigdirs target-libstdc++-v3"
- ;;
- arm*-wince-pe*)
- # the C++ libraries don't build on top of CE's C libraries
- noconfigdirs="$noconfigdirs target-libstdc++-v3"
- ;;
- avr-*-*)
- noconfigdirs="$noconfigdirs target-libstdc++-v3"
- ;;
- bpf-*-*)
- noconfigdirs="$noconfigdirs target-libstdc++-v3"
- ;;
- ft32-*-*)
- noconfigdirs="$noconfigdirs target-libstdc++-v3"
- ;;
- esac
-fi
-
-# Disable C++ on systems where it is known to not work.
-# For testing, you can override this with --enable-languages=c++.
-case ,${enable_languages}, in
- *,c++,*)
- ;;
- *)
- case "${target}" in
- bpf-*-*)
- unsupported_languages="$unsupported_languages c++"
- ;;
- esac
- ;;
-esac
-
-# Disable Objc on systems where it is known to not work.
-# For testing, you can override this with --enable-languages=objc.
-case ,${enable_languages}, in
- *,objc,*)
- ;;
- *)
- case "${target}" in
- bpf-*-*)
- unsupported_languages="$unsupported_languages objc"
- ;;
- esac
- ;;
-esac
-
-# Disable D on systems where it is known to not work.
-# For testing, you can override this with --enable-languages=d.
-case ,${enable_languages}, in
- *,d,*)
- ;;
- *)
- case "${target}" in
- bpf-*-*)
- unsupported_languages="$unsupported_languages d"
- ;;
- esac
- ;;
-esac
-
-# Disable libphobos on unsupported systems.
-# For testing, you can override this with --enable-libphobos.
-if test -d ${srcdir}/libphobos; then
- if test x$enable_libphobos = x; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libphobos support" >&5
-$as_echo_n "checking for libphobos support... " >&6; }
- if (srcdir=${srcdir}/libphobos; \
- . ${srcdir}/configure.tgt; \
- test "$LIBPHOBOS_SUPPORTED" != "yes")
- then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- noconfigdirs="$noconfigdirs target-libphobos"
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- fi
- fi
-fi
-
-# Disable Fortran for some systems.
-case "${target}" in
- mmix-*-*)
- # See <http://gcc.gnu.org/ml/gcc-patches/2004-11/msg00572.html>.
- unsupported_languages="$unsupported_languages fortran"
- ;;
- bpf-*-*)
- unsupported_languages="$unsupported_languages fortran"
- ;;
-esac
-
-# Disable libffi for some systems.
-case "${target}" in
- powerpc-*-darwin*)
- ;;
- i[3456789]86-*-darwin*)
- ;;
- x86_64-*-darwin[912]*)
- ;;
- *-*-darwin*)
- noconfigdirs="$noconfigdirs target-libffi"
- ;;
- *-*-netware*)
- noconfigdirs="$noconfigdirs target-libffi"
- ;;
- *-*-phoenix*)
- noconfigdirs="$noconfigdirs target-libffi"
- ;;
- *-*-rtems*)
- noconfigdirs="$noconfigdirs target-libffi"
- ;;
- *-*-tpf*)
- noconfigdirs="$noconfigdirs target-libffi"
- ;;
- *-*-uclinux*)
- noconfigdirs="$noconfigdirs target-libffi"
- ;;
- *-*-vxworks*)
- noconfigdirs="$noconfigdirs target-libffi"
- ;;
- aarch64*-*-freebsd*)
- noconfigdirs="$noconfigdirs target-libffi"
- ;;
- alpha*-*-*vms*)
- noconfigdirs="$noconfigdirs target-libffi"
- ;;
- arm*-*-freebsd*)
- noconfigdirs="$noconfigdirs target-libffi"
- ;;
- arm-wince-pe)
- noconfigdirs="$noconfigdirs target-libffi"
- ;;
- arm*-*-symbianelf*)
- noconfigdirs="$noconfigdirs target-libffi"
- ;;
- bpf-*-*)
- noconfigdirs="$noconfigdirs target-libffi"
- ;;
- cris-*-* | crisv32-*-*)
- case "${target}" in
- *-*-linux*)
- ;;
- *) # See PR46792 regarding target-libffi.
- noconfigdirs="$noconfigdirs target-libffi";;
- esac
- ;;
- hppa*64*-*-hpux*)
- noconfigdirs="$noconfigdirs target-libffi"
- ;;
- hppa*-hp-hpux11*)
- ;;
- hppa*-*-hpux*)
- noconfigdirs="$noconfigdirs target-libffi"
- ;;
- ia64*-*-*vms*)
- noconfigdirs="$noconfigdirs target-libffi"
- ;;
- i[3456789]86-w64-mingw*)
- noconfigdirs="$noconfigdirs target-libffi"
- ;;
- i[3456789]86-*-mingw*)
- noconfigdirs="$noconfigdirs target-libffi"
- ;;
- x86_64-*-mingw*)
- noconfigdirs="$noconfigdirs target-libffi"
- ;;
- mmix-*-*)
- noconfigdirs="$noconfigdirs target-libffi"
- ;;
- powerpc-*-aix*)
- ;;
- rs6000-*-aix*)
- ;;
- ft32-*-*)
- noconfigdirs="$noconfigdirs target-libffi"
- ;;
- *-*-lynxos*)
- noconfigdirs="$noconfigdirs target-libffi"
- ;;
-esac
-
-# Disable the go frontend on systems where it is known to not work. Please keep
-# this in sync with contrib/config-list.mk.
-case "${target}" in
-*-*-darwin* | *-*-cygwin* | *-*-mingw* | bpf-* )
- unsupported_languages="$unsupported_languages go"
- ;;
-esac
-
-# Only allow gdbserver on some systems.
-if test -d ${srcdir}/gdbserver; then
- if test x$enable_gdbserver = x; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gdbserver support" >&5
-$as_echo_n "checking for gdbserver support... " >&6; }
- if (srcdir=${srcdir}/gdbserver; \
- . ${srcdir}/configure.srv; \
- test -n "$UNSUPPORTED")
- then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- noconfigdirs="$noconfigdirs gdbserver"
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- fi
- fi
-fi
-
-# Disable libgo for some systems where it is known to not work.
-# For testing, you can easily override this with --enable-libgo.
-if test x$enable_libgo = x; then
- case "${target}" in
- *-*-darwin*)
- # PR 46986
- noconfigdirs="$noconfigdirs target-libgo"
- ;;
- *-*-cygwin* | *-*-mingw*)
- noconfigdirs="$noconfigdirs target-libgo"
- ;;
- bpf-*-*)
- noconfigdirs="$noconfigdirs target-libgo"
- ;;
- esac
-fi
-
-# Default libgloss CPU subdirectory.
-libgloss_dir="$target_cpu"
-
-case "${target}" in
- sh*-*-pe|mips*-*-pe|*arm-wince-pe)
- libgloss_dir=wince
- ;;
- aarch64*-*-* )
- libgloss_dir=aarch64
- ;;
- arm*-*-*)
- libgloss_dir=arm
- ;;
- cris-*-* | crisv32-*-*)
- libgloss_dir=cris
- ;;
- kvx-*-elf)
- libgloss_dir=kvx-elf
- ;;
- kvx-*-mbr)
- libgloss_dir=kvx-mbr
- ;;
- kvx-*-cos)
- libgloss_dir=kvx-cos
- ;;
- hppa*-*-*)
- libgloss_dir=pa
- ;;
- i[3456789]86-*-*)
- libgloss_dir=i386
- ;;
- loongarch*-*-*)
- libgloss_dir=loongarch
- ;;
- m68hc11-*-*|m6811-*-*|m68hc12-*-*|m6812-*-*)
- libgloss_dir=m68hc11
- ;;
- m68*-*-* | fido-*-*)
- libgloss_dir=m68k
- ;;
- mips*-*-*)
- libgloss_dir=mips
- ;;
- powerpc*-*-*)
- libgloss_dir=rs6000
- ;;
- pru-*-*)
- libgloss_dir=pru
- ;;
- sparc*-*-*)
- libgloss_dir=sparc
- ;;
-esac
-
-# Disable newlib and libgloss for various target OSes.
-case "${target}" in
- alpha*-dec-osf*)
- noconfigdirs="$noconfigdirs target-newlib target-libgloss"
- ;;
- i[3456789]86-*-linux*)
- # This section makes it possible to build newlib natively on linux.
- # If we are using a cross compiler then don't configure newlib.
- if test x${is_cross_compiler} != xno ; then
- noconfigdirs="$noconfigdirs target-newlib"
- fi
- noconfigdirs="$noconfigdirs target-libgloss"
- # If we are not using a cross compiler, do configure newlib.
- # Note however, that newlib will only be configured in this situation
- # if the --with-newlib option has been given, because otherwise
- # 'target-newlib' will appear in skipdirs.
- ;;
- i[3456789]86-*-rdos*)
- noconfigdirs="$noconfigdirs target-newlib target-libgloss"
- ;;
- sh*-*-pe|mips*-*-pe|arm-wince-pe)
- noconfigdirs="$noconfigdirs target-newlib target-libgloss"
- ;;
- sparc-*-sunos4*)
- noconfigdirs="$noconfigdirs target-newlib target-libgloss"
- ;;
- bpf-*-*)
- noconfigdirs="$noconfigdirs target-newlib target-libgloss"
- ;;
- *-*-aix*)
- noconfigdirs="$noconfigdirs target-newlib target-libgloss"
- ;;
- *-*-beos*)
- noconfigdirs="$noconfigdirs target-newlib target-libgloss"
- ;;
- *-*-chorusos)
- noconfigdirs="$noconfigdirs target-newlib target-libgloss"
- ;;
- *-*-dragonfly*)
- noconfigdirs="$noconfigdirs target-newlib target-libgloss"
- ;;
- *-*-freebsd*)
- noconfigdirs="$noconfigdirs target-newlib target-libgloss"
- ;;
- *-*-linux* | *-*-gnu* | *-*-k*bsd*-gnu | *-*-kopensolaris*-gnu)
- noconfigdirs="$noconfigdirs target-newlib target-libgloss"
- ;;
- *-*-lynxos*)
- noconfigdirs="$noconfigdirs target-newlib target-libgloss"
- ;;
- *-*-mingw*)
- noconfigdirs="$noconfigdirs target-newlib target-libgloss"
- ;;
- *-*-netbsd*)
- noconfigdirs="$noconfigdirs target-newlib target-libgloss"
- ;;
- *-*-netware*)
- noconfigdirs="$noconfigdirs target-newlib target-libgloss"
- ;;
- *-*-tpf*)
- noconfigdirs="$noconfigdirs target-newlib target-libgloss"
- ;;
- *-*-uclinux*)
- noconfigdirs="$noconfigdirs target-newlib target-libgloss"
- ;;
- *-*-vxworks*)
- noconfigdirs="$noconfigdirs target-newlib target-libgloss"
- ;;
-esac
-
-case "${target}" in
- *-*-chorusos)
- ;;
- aarch64-*-darwin*)
- noconfigdirs="$noconfigdirs ld gas gdb gprof"
- noconfigdirs="$noconfigdirs sim target-rda"
- ;;
- amdgcn*-*-*)
- ;;
- arm-*-darwin*)
- noconfigdirs="$noconfigdirs ld gas gdb gprof"
- noconfigdirs="$noconfigdirs sim target-rda"
- ;;
- powerpc-*-darwin*)
- noconfigdirs="$noconfigdirs ld gas gdb gprof"
- noconfigdirs="$noconfigdirs sim target-rda"
- ;;
- i[3456789]86-*-darwin*)
- noconfigdirs="$noconfigdirs ld gprof"
- noconfigdirs="$noconfigdirs sim target-rda"
- ;;
- x86_64-*-darwin[912]*)
- noconfigdirs="$noconfigdirs ld gas gprof"
- noconfigdirs="$noconfigdirs sim target-rda"
- ;;
- *-*-darwin*)
- noconfigdirs="$noconfigdirs ld gas gdb gprof"
- noconfigdirs="$noconfigdirs sim target-rda"
- ;;
- *-*-dragonfly*)
- ;;
- *-*-freebsd*)
- if test "x$with_gmp" = x \
- && ! test -d ${srcdir}/gmp \
- && test -f /usr/local/include/gmp.h; then
- with_gmp=/usr/local
- fi
- ;;
- *-*-kaos*)
- # Remove unsupported stuff on all kaOS configurations.
- noconfigdirs="$noconfigdirs target-libgloss"
- ;;
- *-*-netbsd*)
- ;;
- *-*-netware*)
- ;;
- *-*-phoenix*)
- noconfigdirs="$noconfigdirs target-libgloss"
- ;;
- *-*-rtems*)
- noconfigdirs="$noconfigdirs target-libgloss"
- ;;
- # The tpf target doesn't support gdb yet.
- *-*-tpf*)
- noconfigdirs="$noconfigdirs gdb tcl tk libgui itcl"
- ;;
- *-*-uclinux*)
- noconfigdirs="$noconfigdirs target-rda"
- ;;
- *-*-vxworks*)
- ;;
- alpha*-dec-osf*)
- # ld works, but does not support shared libraries.
- # gas doesn't generate exception information.
- noconfigdirs="$noconfigdirs gas ld"
- ;;
- alpha*-*-*vms*)
- noconfigdirs="$noconfigdirs gdb target-newlib target-libgloss"
- ;;
- alpha*-*-*)
- # newlib is not 64 bit ready
- noconfigdirs="$noconfigdirs target-newlib target-libgloss"
- ;;
- bpf-*-*)
- noconfigdirs="$noconfigdirs target-libobjc target-libbacktrace"
- ;;
- sh*-*-pe|mips*-*-pe|*arm-wince-pe)
- noconfigdirs="$noconfigdirs tcl tk itcl libgui sim"
- ;;
- arc*-*-*)
- noconfigdirs="$noconfigdirs sim"
- ;;
- arm-*-pe*)
- noconfigdirs="$noconfigdirs target-libgloss"
- ;;
- arm-*-riscix*)
- noconfigdirs="$noconfigdirs ld target-libgloss"
- ;;
- avr-*-*)
- if test x${with_avrlibc} != xno; then
- noconfigdirs="$noconfigdirs target-newlib target-libgloss"
- fi
- ;;
- c4x-*-* | tic4x-*-*)
- noconfigdirs="$noconfigdirs target-libgloss"
- ;;
- tic54x-*-*)
- noconfigdirs="$noconfigdirs target-libgloss gdb"
- ;;
- d10v-*-*)
- noconfigdirs="$noconfigdirs target-libgloss"
- ;;
- d30v-*-*)
- noconfigdirs="$noconfigdirs gdb"
- ;;
- fr30-*-elf*)
- noconfigdirs="$noconfigdirs gdb"
- ;;
- ft32-*-*)
- noconfigdirs="$noconfigdirs target-rda gprof"
- ;;
- moxie-*-*)
- noconfigdirs="$noconfigdirs"
- ;;
- h8300*-*-*)
- noconfigdirs="$noconfigdirs target-libgloss"
- ;;
- h8500-*-*)
- noconfigdirs="$noconfigdirs target-libgloss"
- ;;
- hppa1.1-*-osf* | hppa1.1-*-bsd* )
- ;;
- hppa*64*-*-hpux*)
- noconfigdirs="$noconfigdirs gdb"
- ;;
- hppa*-*-hpux11*)
- noconfigdirs="$noconfigdirs gdb ld"
- ;;
- hppa*64*-*-linux*)
- ;;
- hppa*-*-linux*)
- ;;
- hppa*-*-*elf* | \
- hppa*-*-lites* | \
- hppa*-*-openbsd* | \
- hppa*64*-*-*)
- ;;
- hppa*-*-pro*)
- ;;
- hppa*-*-*)
- noconfigdirs="$noconfigdirs ld"
- ;;
- i960-*-*)
- noconfigdirs="$noconfigdirs gdb"
- ;;
- ia64*-*-elf*)
- # No gdb support yet.
- noconfigdirs="$noconfigdirs readline libgui itcl gdb"
- ;;
- ia64*-**-hpux*)
- # No ld support yet.
- noconfigdirs="$noconfigdirs gdb libgui itcl ld"
- ;;
- ia64*-*-*vms*)
- # No ld support yet.
- noconfigdirs="$noconfigdirs libgui itcl ld"
- ;;
- i[3456789]86-w64-mingw*)
- ;;
- i[3456789]86-*-mingw*)
- target_configdirs="$target_configdirs target-winsup"
- ;;
- *-*-cygwin*)
- target_configdirs="$target_configdirs target-libtermcap target-winsup"
- noconfigdirs="$noconfigdirs target-libgloss"
- # always build newlib if winsup directory is present.
- if test -d "$srcdir/winsup/cygwin"; then
- skipdirs=`echo " ${skipdirs} " | sed -e 's/ target-newlib / /'`
- elif test -d "$srcdir/newlib"; then
- echo "Warning: winsup/cygwin is missing so newlib can't be built."
- fi
- ;;
- i[3456789]86-*-pe)
- noconfigdirs="$noconfigdirs target-libgloss"
- ;;
- i[3456789]86-*-sco3.2v5*)
- # The linker does not yet know about weak symbols in COFF,
- # and is not configured to handle mixed ELF and COFF.
- noconfigdirs="$noconfigdirs ld target-libgloss"
- ;;
- i[3456789]86-*-sco*)
- noconfigdirs="$noconfigdirs gprof target-libgloss"
- ;;
- i[3456789]86-*-solaris2* | x86_64-*-solaris2.1[0-9]*)
- noconfigdirs="$noconfigdirs target-libgloss"
- ;;
- i[3456789]86-*-sysv4*)
- noconfigdirs="$noconfigdirs target-libgloss"
- ;;
- i[3456789]86-*-beos*)
- noconfigdirs="$noconfigdirs gdb"
- ;;
- i[3456789]86-*-rdos*)
- noconfigdirs="$noconfigdirs gdb"
- ;;
- kvx-*-*)
- noconfigdirs="$noconfigdirs gdb gdbserver sim"
- ;;
- mmix-*-*)
- noconfigdirs="$noconfigdirs gdb"
- ;;
- mt-*-*)
- noconfigdirs="$noconfigdirs sim"
- ;;
- nfp-*-*)
- noconfigdirs="$noconfigdirs ld gas gdb gprof sim"
- noconfigdirs="$noconfigdirs $target_libraries"
- ;;
- pdp11-*-*)
- noconfigdirs="$noconfigdirs gdb gprof"
- ;;
- powerpc-*-aix*)
- # copied from rs6000-*-* entry
- noconfigdirs="$noconfigdirs gprof"
- ;;
- powerpc*-*-winnt* | powerpc*-*-pe*)
- target_configdirs="$target_configdirs target-winsup"
- noconfigdirs="$noconfigdirs gdb tcl tk target-libgloss itcl"
- # always build newlib.
- skipdirs=`echo " ${skipdirs} " | sed -e 's/ target-newlib / /'`
- ;;
- # This is temporary until we can link against shared libraries
- powerpcle-*-solaris*)
- noconfigdirs="$noconfigdirs gdb sim tcl tk itcl"
- ;;
- powerpc-*-beos*)
- noconfigdirs="$noconfigdirs gdb"
- ;;
- rs6000-*-lynxos*)
- noconfigdirs="$noconfigdirs gprof"
- ;;
- rs6000-*-aix*)
- noconfigdirs="$noconfigdirs gprof"
- ;;
- rs6000-*-*)
- noconfigdirs="$noconfigdirs gprof"
- ;;
- m68k-apollo-*)
- noconfigdirs="$noconfigdirs ld binutils gprof target-libgloss"
- ;;
- microblaze*)
- noconfigdirs="$noconfigdirs gprof"
- ;;
- mips*-sde-elf* | mips*-mti-elf* | mips*-img-elf*)
- if test x$with_newlib = xyes; then
- noconfigdirs="$noconfigdirs gprof"
- fi
- ;;
- mips*-*-irix5*)
- noconfigdirs="$noconfigdirs gprof target-libgloss"
- ;;
- mips*-*-irix6*)
- noconfigdirs="$noconfigdirs gprof target-libgloss"
- ;;
- mips*-*-bsd*)
- noconfigdirs="$noconfigdirs ld gas gprof target-libgloss"
- ;;
- mips*-*-linux*)
- ;;
- mips*-*-ultrix* | mips*-*-osf* | mips*-*-ecoff* | mips*-*-pe* \
- | mips*-*-irix* | mips*-*-lnews* | mips*-*-riscos*)
- noconfigdirs="$noconfigdirs ld gas gprof"
- ;;
- mips*-*-*)
- noconfigdirs="$noconfigdirs gprof"
- ;;
- nvptx*-*-*)
- noconfigdirs="$noconfigdirs target-libssp target-libstdc++-v3 target-libobjc"
- ;;
- sh-*-*)
- case "${target}" in
- sh*-*-elf)
- ;;
- *)
- noconfigdirs="$noconfigdirs target-libgloss" ;;
- esac
- ;;
- sparc-*-sunos4*)
- if test x${is_cross_compiler} = xno ; then
- use_gnu_ld=no
- fi
- ;;
- tic6x-*-*)
- noconfigdirs="$noconfigdirs sim"
- ;;
- tilepro*-*-* | tilegx*-*-*)
- noconfigdirs="$noconfigdirs sim"
- ;;
- v810-*-*)
- noconfigdirs="$noconfigdirs bfd binutils gas gdb ld opcodes target-libgloss"
- ;;
- vax-*-*)
- noconfigdirs="$noconfigdirs target-newlib target-libgloss"
- ;;
- wasm32-*-*)
- noconfigdirs="$noconfigdirs ld"
- ;;
- loongarch*-*-linux*)
- ;;
- loongarch*-*-*)
- noconfigdirs="$noconfigdirs gprof"
- ;;
-esac
-
-# If we aren't building newlib, then don't build libgloss, since libgloss
-# depends upon some newlib header files.
-case "${noconfigdirs}" in
- *target-libgloss*) ;;
- *target-newlib*) noconfigdirs="$noconfigdirs target-libgloss" ;;
-esac
-
-# Work in distributions that contain no compiler tools, like Autoconf.
-host_makefile_frag=/dev/null
-if test -d ${srcdir}/config ; then
-case "${host}" in
- i[3456789]86-*-msdosdjgpp*)
- host_makefile_frag="config/mh-djgpp"
- ;;
- *-cygwin*)
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking to see if cat works as expected" >&5
-$as_echo_n "checking to see if cat works as expected... " >&6; }
-echo a >cygwin-cat-check
-if test `cat cygwin-cat-check` = a ; then
- rm cygwin-cat-check
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-else
- rm cygwin-cat-check
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- as_fn_error $? "The cat command does not ignore carriage return characters.
- Please either mount the build directory in binary mode or run the following
- commands before running any configure script:
-set -o igncr
-export SHELLOPTS
- " "$LINENO" 5
-fi
-
- host_makefile_frag="config/mh-cygwin"
- ;;
- *-mingw*)
- host_makefile_frag="config/mh-mingw"
- ;;
- alpha*-linux*)
- host_makefile_frag="config/mh-alpha-linux"
- ;;
- hppa*-hp-hpux*)
- host_makefile_frag="config/mh-pa"
- ;;
- hppa*-*)
- host_makefile_frag="config/mh-pa"
- ;;
- i?86-*-darwin[89]* | i?86-*-darwin1[0-7]* | powerpc*-*-darwin*)
- host_makefile_frag="config/mh-darwin"
- ;;
- powerpc-*-aix*)
- host_makefile_frag="config/mh-ppc-aix"
- ;;
- rs6000-*-aix*)
- host_makefile_frag="config/mh-ppc-aix"
- ;;
-esac
-fi
-
-if test "${build}" != "${host}" ; then
- AR_FOR_BUILD=${AR_FOR_BUILD-ar}
- AS_FOR_BUILD=${AS_FOR_BUILD-as}
- CC_FOR_BUILD=${CC_FOR_BUILD-gcc}
- CPP_FOR_BUILD="${CPP_FOR_BUILD-\$(CC_FOR_BUILD) -E}"
- CXX_FOR_BUILD=${CXX_FOR_BUILD-g++}
- DSYMUTIL_FOR_BUILD=${DSYMUTIL_FOR_BUILD-dsymutil}
- GFORTRAN_FOR_BUILD=${GFORTRAN_FOR_BUILD-gfortran}
- GOC_FOR_BUILD=${GOC_FOR_BUILD-gccgo}
- GDC_FOR_BUILD=${GDC_FOR_BUILD-gdc}
- DLLTOOL_FOR_BUILD=${DLLTOOL_FOR_BUILD-dlltool}
- LD_FOR_BUILD=${LD_FOR_BUILD-ld}
- NM_FOR_BUILD=${NM_FOR_BUILD-nm}
- RANLIB_FOR_BUILD=${RANLIB_FOR_BUILD-ranlib}
- WINDRES_FOR_BUILD=${WINDRES_FOR_BUILD-windres}
- WINDMC_FOR_BUILD=${WINDMC_FOR_BUILD-windmc}
-else
- AR_FOR_BUILD="\$(AR)"
- AS_FOR_BUILD="\$(AS)"
- CC_FOR_BUILD="\$(CC)"
- CXX_FOR_BUILD="\$(CXX)"
- DSYMUTIL_FOR_BUILD="\$(DSYMUTIL)"
- GFORTRAN_FOR_BUILD="\$(GFORTRAN)"
- GOC_FOR_BUILD="\$(GOC)"
- GDC_FOR_BUILD="\$(GDC)"
- DLLTOOL_FOR_BUILD="\$(DLLTOOL)"
- LD_FOR_BUILD="\$(LD)"
- NM_FOR_BUILD="\$(NM)"
- RANLIB_FOR_BUILD="\$(RANLIB)"
- WINDRES_FOR_BUILD="\$(WINDRES)"
- WINDMC_FOR_BUILD="\$(WINDMC)"
-fi
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
-set dummy ${ac_tool_prefix}gcc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_CC="${ac_tool_prefix}gcc"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
-$as_echo "$CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_CC"; then
- ac_ct_CC=$CC
- # Extract the first word of "gcc", so it can be a program name with args.
-set dummy gcc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_CC"; then
- ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_CC="gcc"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_CC=$ac_cv_prog_ac_ct_CC
-if test -n "$ac_ct_CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
-$as_echo "$ac_ct_CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_CC" = x; then
- CC=""
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- CC=$ac_ct_CC
- fi
-else
- CC="$ac_cv_prog_CC"
-fi
-
-if test -z "$CC"; then
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
-set dummy ${ac_tool_prefix}cc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_CC="${ac_tool_prefix}cc"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
-$as_echo "$CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
-fi
-if test -z "$CC"; then
- # Extract the first word of "cc", so it can be a program name with args.
-set dummy cc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
- ac_prog_rejected=no
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
- ac_prog_rejected=yes
- continue
- fi
- ac_cv_prog_CC="cc"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-if test $ac_prog_rejected = yes; then
- # We found a bogon in the path, so make sure we never use it.
- set dummy $ac_cv_prog_CC
- shift
- if test $# != 0; then
- # We chose a different compiler from the bogus one.
- # However, it has the same basename, so the bogon will be chosen
- # first if we set CC to just the basename; use the full file name.
- shift
- ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
- fi
-fi
-fi
-fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
-$as_echo "$CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$CC"; then
- if test -n "$ac_tool_prefix"; then
- for ac_prog in cl.exe
- do
- # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
-set dummy $ac_tool_prefix$ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
-$as_echo "$CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$CC" && break
- done
-fi
-if test -z "$CC"; then
- ac_ct_CC=$CC
- for ac_prog in cl.exe
-do
- # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_CC"; then
- ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_CC="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_CC=$ac_cv_prog_ac_ct_CC
-if test -n "$ac_ct_CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
-$as_echo "$ac_ct_CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$ac_ct_CC" && break
-done
-
- if test "x$ac_ct_CC" = x; then
- CC=""
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- CC=$ac_ct_CC
- fi
-fi
-
-fi
-
-
-test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "no acceptable C compiler found in \$PATH
-See \`config.log' for more details" "$LINENO" 5; }
-
-# Provide some information about the compiler.
-$as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
-set X $ac_compile
-ac_compiler=$2
-for ac_option in --version -v -V -qversion; do
- { { ac_try="$ac_compiler $ac_option >&5"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_compiler $ac_option >&5") 2>conftest.err
- ac_status=$?
- if test -s conftest.err; then
- sed '10a\
-... rest of stderr output deleted ...
- 10q' conftest.err >conftest.er1
- cat conftest.er1 >&5
- fi
- rm -f conftest.er1 conftest.err
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }
-done
-
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-ac_clean_files_save=$ac_clean_files
-ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
-# Try to create an executable without -o first, disregard a.out.
-# It will help us diagnose broken compilers, and finding out an intuition
-# of exeext.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
-$as_echo_n "checking whether the C compiler works... " >&6; }
-ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
-
-# The possible output files:
-ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
-
-ac_rmfiles=
-for ac_file in $ac_files
-do
- case $ac_file in
- *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
- * ) ac_rmfiles="$ac_rmfiles $ac_file";;
- esac
-done
-rm -f $ac_rmfiles
-
-if { { ac_try="$ac_link_default"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_link_default") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then :
- # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
-# So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
-# in a Makefile. We should not override ac_cv_exeext if it was cached,
-# so that the user can short-circuit this test for compilers unknown to
-# Autoconf.
-for ac_file in $ac_files ''
-do
- test -f "$ac_file" || continue
- case $ac_file in
- *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
- ;;
- [ab].out )
- # We found the default executable, but exeext='' is most
- # certainly right.
- break;;
- *.* )
- if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
- then :; else
- ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
- fi
- # We set ac_cv_exeext here because the later test for it is not
- # safe: cross compilers may not add the suffix if given an `-o'
- # argument, so we may need to know it at that point already.
- # Even if this section looks crufty: it has the advantage of
- # actually working.
- break;;
- * )
- break;;
- esac
-done
-test "$ac_cv_exeext" = no && ac_cv_exeext=
-
-else
- ac_file=''
-fi
-if test -z "$ac_file"; then :
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-$as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error 77 "C compiler cannot create executables
-See \`config.log' for more details" "$LINENO" 5; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
-$as_echo_n "checking for C compiler default output file name... " >&6; }
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
-$as_echo "$ac_file" >&6; }
-ac_exeext=$ac_cv_exeext
-
-rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
-ac_clean_files=$ac_clean_files_save
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
-$as_echo_n "checking for suffix of executables... " >&6; }
-if { { ac_try="$ac_link"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_link") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then :
- # If both `conftest.exe' and `conftest' are `present' (well, observable)
-# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
-# work properly (i.e., refer to `conftest.exe'), while it won't with
-# `rm'.
-for ac_file in conftest.exe conftest conftest.*; do
- test -f "$ac_file" || continue
- case $ac_file in
- *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
- *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
- break;;
- * ) break;;
- esac
-done
-else
- { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "cannot compute suffix of executables: cannot compile and link
-See \`config.log' for more details" "$LINENO" 5; }
-fi
-rm -f conftest conftest$ac_cv_exeext
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
-$as_echo "$ac_cv_exeext" >&6; }
-
-rm -f conftest.$ac_ext
-EXEEXT=$ac_cv_exeext
-ac_exeext=$EXEEXT
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <stdio.h>
-int
-main ()
-{
-FILE *f = fopen ("conftest.out", "w");
- return ferror (f) || fclose (f) != 0;
-
- ;
- return 0;
-}
-_ACEOF
-ac_clean_files="$ac_clean_files conftest.out"
-# Check that the compiler produces executables we can run. If not, either
-# the compiler is broken, or we cross compile.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
-$as_echo_n "checking whether we are cross compiling... " >&6; }
-if test "$cross_compiling" != yes; then
- { { ac_try="$ac_link"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_link") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }
- if { ac_try='./conftest$ac_cv_exeext'
- { { case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_try") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; }; then
- cross_compiling=no
- else
- if test "$cross_compiling" = maybe; then
- cross_compiling=yes
- else
- { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "cannot run C compiled programs.
-If you meant to cross compile, use \`--host'.
-See \`config.log' for more details" "$LINENO" 5; }
- fi
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
-$as_echo "$cross_compiling" >&6; }
-
-rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
-ac_clean_files=$ac_clean_files_save
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
-$as_echo_n "checking for suffix of object files... " >&6; }
-if ${ac_cv_objext+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-rm -f conftest.o conftest.obj
-if { { ac_try="$ac_compile"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_compile") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then :
- for ac_file in conftest.o conftest.obj conftest.*; do
- test -f "$ac_file" || continue;
- case $ac_file in
- *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
- *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
- break;;
- esac
-done
-else
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "cannot compute suffix of object files: cannot compile
-See \`config.log' for more details" "$LINENO" 5; }
-fi
-rm -f conftest.$ac_cv_objext conftest.$ac_ext
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
-$as_echo "$ac_cv_objext" >&6; }
-OBJEXT=$ac_cv_objext
-ac_objext=$OBJEXT
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
-$as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
-if ${ac_cv_c_compiler_gnu+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-#ifndef __GNUC__
- choke me
-#endif
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_compiler_gnu=yes
-else
- ac_compiler_gnu=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-ac_cv_c_compiler_gnu=$ac_compiler_gnu
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
-$as_echo "$ac_cv_c_compiler_gnu" >&6; }
-if test $ac_compiler_gnu = yes; then
- GCC=yes
-else
- GCC=
-fi
-ac_test_CFLAGS=${CFLAGS+set}
-ac_save_CFLAGS=$CFLAGS
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
-$as_echo_n "checking whether $CC accepts -g... " >&6; }
-if ${ac_cv_prog_cc_g+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_save_c_werror_flag=$ac_c_werror_flag
- ac_c_werror_flag=yes
- ac_cv_prog_cc_g=no
- CFLAGS="-g"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_prog_cc_g=yes
-else
- CFLAGS=""
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
-
-else
- ac_c_werror_flag=$ac_save_c_werror_flag
- CFLAGS="-g"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_prog_cc_g=yes
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- ac_c_werror_flag=$ac_save_c_werror_flag
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
-$as_echo "$ac_cv_prog_cc_g" >&6; }
-if test "$ac_test_CFLAGS" = set; then
- CFLAGS=$ac_save_CFLAGS
-elif test $ac_cv_prog_cc_g = yes; then
- if test "$GCC" = yes; then
- CFLAGS="-g -O2"
- else
- CFLAGS="-g"
- fi
-else
- if test "$GCC" = yes; then
- CFLAGS="-O2"
- else
- CFLAGS=
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
-$as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
-if ${ac_cv_prog_cc_c89+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_cv_prog_cc_c89=no
-ac_save_CC=$CC
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <stdarg.h>
-#include <stdio.h>
-struct stat;
-/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
-struct buf { int x; };
-FILE * (*rcsopen) (struct buf *, struct stat *, int);
-static char *e (p, i)
- char **p;
- int i;
-{
- return p[i];
-}
-static char *f (char * (*g) (char **, int), char **p, ...)
-{
- char *s;
- va_list v;
- va_start (v,p);
- s = g (p, va_arg (v,int));
- va_end (v);
- return s;
-}
-
-/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
- function prototypes and stuff, but not '\xHH' hex character constants.
- These don't provoke an error unfortunately, instead are silently treated
- as 'x'. The following induces an error, until -std is added to get
- proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
- array size at least. It's necessary to write '\x00'==0 to get something
- that's true only with -std. */
-int osf4_cc_array ['\x00' == 0 ? 1 : -1];
-
-/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
- inside strings and character constants. */
-#define FOO(x) 'x'
-int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
-
-int test (int i, double x);
-struct s1 {int (*f) (int a);};
-struct s2 {int (*f) (double a);};
-int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
-int argc;
-char **argv;
-int
-main ()
-{
-return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
- ;
- return 0;
-}
-_ACEOF
-for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
- -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
-do
- CC="$ac_save_CC $ac_arg"
- if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_prog_cc_c89=$ac_arg
-fi
-rm -f core conftest.err conftest.$ac_objext
- test "x$ac_cv_prog_cc_c89" != "xno" && break
-done
-rm -f conftest.$ac_ext
-CC=$ac_save_CC
-
-fi
-# AC_CACHE_VAL
-case "x$ac_cv_prog_cc_c89" in
- x)
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
-$as_echo "none needed" >&6; } ;;
- xno)
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
-$as_echo "unsupported" >&6; } ;;
- *)
- CC="$CC $ac_cv_prog_cc_c89"
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
-$as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
-esac
-if test "x$ac_cv_prog_cc_c89" != xno; then :
-
-fi
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C99" >&5
-$as_echo_n "checking for $CC option to accept ISO C99... " >&6; }
-if ${ac_cv_prog_cc_c99+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_cv_prog_cc_c99=no
-ac_save_CC=$CC
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <stdarg.h>
-#include <stdbool.h>
-#include <stdlib.h>
-#include <wchar.h>
-#include <stdio.h>
-
-// Check varargs macros. These examples are taken from C99 6.10.3.5.
-#define debug(...) fprintf (stderr, __VA_ARGS__)
-#define showlist(...) puts (#__VA_ARGS__)
-#define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__))
-static void
-test_varargs_macros (void)
-{
- int x = 1234;
- int y = 5678;
- debug ("Flag");
- debug ("X = %d\n", x);
- showlist (The first, second, and third items.);
- report (x>y, "x is %d but y is %d", x, y);
-}
-
-// Check long long types.
-#define BIG64 18446744073709551615ull
-#define BIG32 4294967295ul
-#define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0)
-#if !BIG_OK
- your preprocessor is broken;
-#endif
-#if BIG_OK
-#else
- your preprocessor is broken;
-#endif
-static long long int bignum = -9223372036854775807LL;
-static unsigned long long int ubignum = BIG64;
-
-struct incomplete_array
-{
- int datasize;
- double data[];
-};
-
-struct named_init {
- int number;
- const wchar_t *name;
- double average;
-};
-
-typedef const char *ccp;
-
-static inline int
-test_restrict (ccp restrict text)
-{
- // See if C++-style comments work.
- // Iterate through items via the restricted pointer.
- // Also check for declarations in for loops.
- for (unsigned int i = 0; *(text+i) != '\0'; ++i)
- continue;
- return 0;
-}
-
-// Check varargs and va_copy.
-static void
-test_varargs (const char *format, ...)
-{
- va_list args;
- va_start (args, format);
- va_list args_copy;
- va_copy (args_copy, args);
-
- const char *str;
- int number;
- float fnumber;
-
- while (*format)
- {
- switch (*format++)
- {
- case 's': // string
- str = va_arg (args_copy, const char *);
- break;
- case 'd': // int
- number = va_arg (args_copy, int);
- break;
- case 'f': // float
- fnumber = va_arg (args_copy, double);
- break;
- default:
- break;
- }
- }
- va_end (args_copy);
- va_end (args);
-}
-
-int
-main ()
-{
-
- // Check bool.
- _Bool success = false;
-
- // Check restrict.
- if (test_restrict ("String literal") == 0)
- success = true;
- char *restrict newvar = "Another string";
-
- // Check varargs.
- test_varargs ("s, d' f .", "string", 65, 34.234);
- test_varargs_macros ();
-
- // Check flexible array members.
- struct incomplete_array *ia =
- malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10));
- ia->datasize = 10;
- for (int i = 0; i < ia->datasize; ++i)
- ia->data[i] = i * 1.234;
-
- // Check named initializers.
- struct named_init ni = {
- .number = 34,
- .name = L"Test wide string",
- .average = 543.34343,
- };
-
- ni.number = 58;
-
- int dynamic_array[ni.number];
- dynamic_array[ni.number - 1] = 543;
-
- // work around unused variable warnings
- return (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == 'x'
- || dynamic_array[ni.number - 1] != 543);
-
- ;
- return 0;
-}
-_ACEOF
-for ac_arg in '' -std=gnu99 -std=c99 -c99 -AC99 -D_STDC_C99= -qlanglvl=extc99
-do
- CC="$ac_save_CC $ac_arg"
- if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_prog_cc_c99=$ac_arg
-fi
-rm -f core conftest.err conftest.$ac_objext
- test "x$ac_cv_prog_cc_c99" != "xno" && break
-done
-rm -f conftest.$ac_ext
-CC=$ac_save_CC
-
-fi
-# AC_CACHE_VAL
-case "x$ac_cv_prog_cc_c99" in
- x)
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
-$as_echo "none needed" >&6; } ;;
- xno)
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
-$as_echo "unsupported" >&6; } ;;
- *)
- CC="$CC $ac_cv_prog_cc_c99"
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5
-$as_echo "$ac_cv_prog_cc_c99" >&6; } ;;
-esac
-if test "x$ac_cv_prog_cc_c99" != xno; then :
-
-fi
-
-
-ac_ext=cpp
-ac_cpp='$CXXCPP $CPPFLAGS'
-ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
-if test -z "$CXX"; then
- if test -n "$CCC"; then
- CXX=$CCC
- else
- if test -n "$ac_tool_prefix"; then
- for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC
- do
- # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
-set dummy $ac_tool_prefix$ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CXX+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$CXX"; then
- ac_cv_prog_CXX="$CXX" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_CXX="$ac_tool_prefix$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-CXX=$ac_cv_prog_CXX
-if test -n "$CXX"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5
-$as_echo "$CXX" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$CXX" && break
- done
-fi
-if test -z "$CXX"; then
- ac_ct_CXX=$CXX
- for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC
-do
- # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_CXX+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_CXX"; then
- ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_CXX="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_CXX=$ac_cv_prog_ac_ct_CXX
-if test -n "$ac_ct_CXX"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5
-$as_echo "$ac_ct_CXX" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$ac_ct_CXX" && break
-done
-
- if test "x$ac_ct_CXX" = x; then
- CXX="g++"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- CXX=$ac_ct_CXX
- fi
-fi
-
- fi
-fi
-# Provide some information about the compiler.
-$as_echo "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5
-set X $ac_compile
-ac_compiler=$2
-for ac_option in --version -v -V -qversion; do
- { { ac_try="$ac_compiler $ac_option >&5"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_compiler $ac_option >&5") 2>conftest.err
- ac_status=$?
- if test -s conftest.err; then
- sed '10a\
-... rest of stderr output deleted ...
- 10q' conftest.err >conftest.er1
- cat conftest.er1 >&5
- fi
- rm -f conftest.er1 conftest.err
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }
-done
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C++ compiler" >&5
-$as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; }
-if ${ac_cv_cxx_compiler_gnu+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-#ifndef __GNUC__
- choke me
-#endif
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_cxx_try_compile "$LINENO"; then :
- ac_compiler_gnu=yes
-else
- ac_compiler_gnu=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-ac_cv_cxx_compiler_gnu=$ac_compiler_gnu
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5
-$as_echo "$ac_cv_cxx_compiler_gnu" >&6; }
-if test $ac_compiler_gnu = yes; then
- GXX=yes
-else
- GXX=
-fi
-ac_test_CXXFLAGS=${CXXFLAGS+set}
-ac_save_CXXFLAGS=$CXXFLAGS
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5
-$as_echo_n "checking whether $CXX accepts -g... " >&6; }
-if ${ac_cv_prog_cxx_g+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_save_cxx_werror_flag=$ac_cxx_werror_flag
- ac_cxx_werror_flag=yes
- ac_cv_prog_cxx_g=no
- CXXFLAGS="-g"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_cxx_try_compile "$LINENO"; then :
- ac_cv_prog_cxx_g=yes
-else
- CXXFLAGS=""
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_cxx_try_compile "$LINENO"; then :
-
-else
- ac_cxx_werror_flag=$ac_save_cxx_werror_flag
- CXXFLAGS="-g"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_cxx_try_compile "$LINENO"; then :
- ac_cv_prog_cxx_g=yes
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- ac_cxx_werror_flag=$ac_save_cxx_werror_flag
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5
-$as_echo "$ac_cv_prog_cxx_g" >&6; }
-if test "$ac_test_CXXFLAGS" = set; then
- CXXFLAGS=$ac_save_CXXFLAGS
-elif test $ac_cv_prog_cxx_g = yes; then
- if test "$GXX" = yes; then
- CXXFLAGS="-g -O2"
- else
- CXXFLAGS="-g"
- fi
-else
- if test "$GXX" = yes; then
- CXXFLAGS="-O2"
- else
- CXXFLAGS=
- fi
-fi
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-
-# We must set the default linker to the linker used by gcc for the correct
-# operation of libtool. If LD is not defined and we are using gcc, try to
-# set the LD default to the ld used by gcc.
-if test -z "$LD"; then
- if test "$GCC" = yes; then
- case $build in
- *-*-mingw*)
- gcc_prog_ld=`$CC -print-prog-name=ld 2>&1 | tr -d '\015'` ;;
- *)
- gcc_prog_ld=`$CC -print-prog-name=ld 2>&1` ;;
- esac
- case $gcc_prog_ld in
- # Accept absolute paths.
- [\\/]* | [A-Za-z]:[\\/]*)
- LD="$gcc_prog_ld" ;;
- esac
- fi
-fi
-
-
-
-if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}gnatbind", so it can be a program name with args.
-set dummy ${ac_tool_prefix}gnatbind; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_GNATBIND+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$GNATBIND"; then
- ac_cv_prog_GNATBIND="$GNATBIND" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_GNATBIND="${ac_tool_prefix}gnatbind"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-GNATBIND=$ac_cv_prog_GNATBIND
-if test -n "$GNATBIND"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNATBIND" >&5
-$as_echo "$GNATBIND" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_GNATBIND"; then
- ac_ct_GNATBIND=$GNATBIND
- # Extract the first word of "gnatbind", so it can be a program name with args.
-set dummy gnatbind; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_GNATBIND+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_GNATBIND"; then
- ac_cv_prog_ac_ct_GNATBIND="$ac_ct_GNATBIND" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_GNATBIND="gnatbind"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_GNATBIND=$ac_cv_prog_ac_ct_GNATBIND
-if test -n "$ac_ct_GNATBIND"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_GNATBIND" >&5
-$as_echo "$ac_ct_GNATBIND" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_GNATBIND" = x; then
- GNATBIND="no"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- GNATBIND=$ac_ct_GNATBIND
- fi
-else
- GNATBIND="$ac_cv_prog_GNATBIND"
-fi
-
-if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}gnatmake", so it can be a program name with args.
-set dummy ${ac_tool_prefix}gnatmake; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_GNATMAKE+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$GNATMAKE"; then
- ac_cv_prog_GNATMAKE="$GNATMAKE" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_GNATMAKE="${ac_tool_prefix}gnatmake"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-GNATMAKE=$ac_cv_prog_GNATMAKE
-if test -n "$GNATMAKE"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNATMAKE" >&5
-$as_echo "$GNATMAKE" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_GNATMAKE"; then
- ac_ct_GNATMAKE=$GNATMAKE
- # Extract the first word of "gnatmake", so it can be a program name with args.
-set dummy gnatmake; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_GNATMAKE+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_GNATMAKE"; then
- ac_cv_prog_ac_ct_GNATMAKE="$ac_ct_GNATMAKE" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_GNATMAKE="gnatmake"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_GNATMAKE=$ac_cv_prog_ac_ct_GNATMAKE
-if test -n "$ac_ct_GNATMAKE"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_GNATMAKE" >&5
-$as_echo "$ac_ct_GNATMAKE" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_GNATMAKE" = x; then
- GNATMAKE="no"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- GNATMAKE=$ac_ct_GNATMAKE
- fi
-else
- GNATMAKE="$ac_cv_prog_GNATMAKE"
-fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether compiler driver understands Ada and is recent enough" >&5
-$as_echo_n "checking whether compiler driver understands Ada and is recent enough... " >&6; }
-if ${acx_cv_cc_gcc_supports_ada+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat >conftest.adb <<EOF
-pragma Warnings (Off);
-with System.CRTL;
-pragma Warnings (On);
-use type System.CRTL.int64;
-procedure conftest is begin null; end conftest;
-EOF
-acx_cv_cc_gcc_supports_ada=no
-# There is a bug in old released versions of GCC which causes the
-# driver to exit successfully when the appropriate language module
-# has not been installed. This is fixed in 2.95.4, 3.0.2, and 3.1.
-# Therefore we must check for the error message as well as an
-# unsuccessful exit.
-# Other compilers, like HP Tru64 UNIX cc, exit successfully when
-# given a .adb file, but produce no object file. So we must check
-# if an object file was really produced to guard against this.
-errors=`(${CC} -c conftest.adb) 2>&1 || echo failure`
-if test x"$errors" = x && test -f conftest.$ac_objext; then
- acx_cv_cc_gcc_supports_ada=yes
-fi
-rm -f conftest.*
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $acx_cv_cc_gcc_supports_ada" >&5
-$as_echo "$acx_cv_cc_gcc_supports_ada" >&6; }
-
-if test "x$GNATBIND" != xno && test "x$GNATMAKE" != xno && test x$acx_cv_cc_gcc_supports_ada != xno; then
- have_gnat=yes
-else
- have_gnat=no
-fi
-
-
-
-if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}gdc", so it can be a program name with args.
-set dummy ${ac_tool_prefix}gdc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_GDC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$GDC"; then
- ac_cv_prog_GDC="$GDC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_GDC="${ac_tool_prefix}gdc"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-GDC=$ac_cv_prog_GDC
-if test -n "$GDC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GDC" >&5
-$as_echo "$GDC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_GDC"; then
- ac_ct_GDC=$GDC
- # Extract the first word of "gdc", so it can be a program name with args.
-set dummy gdc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_GDC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_GDC"; then
- ac_cv_prog_ac_ct_GDC="$ac_ct_GDC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_GDC="gdc"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_GDC=$ac_cv_prog_ac_ct_GDC
-if test -n "$ac_ct_GDC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_GDC" >&5
-$as_echo "$ac_ct_GDC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_GDC" = x; then
- GDC="no"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- GDC=$ac_ct_GDC
- fi
-else
- GDC="$ac_cv_prog_GDC"
-fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the D compiler works" >&5
-$as_echo_n "checking whether the D compiler works... " >&6; }
-if ${acx_cv_d_compiler_works+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat >conftest.d <<EOF
-module conftest; int main() { return 0; }
-EOF
-acx_cv_d_compiler_works=no
-if test "x$GDC" != xno; then
- errors=`(${GDC} -c conftest.d) 2>&1 || echo failure`
- if test x"$errors" = x && test -f conftest.$ac_objext; then
- acx_cv_d_compiler_works=yes
- fi
- rm -f conftest.*
-fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $acx_cv_d_compiler_works" >&5
-$as_echo "$acx_cv_d_compiler_works" >&6; }
-if test "x$GDC" != xno && test x$acx_cv_d_compiler_works != xno; then
- have_gdc=yes
-else
- have_gdc=no
-fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to compare bootstrapped objects" >&5
-$as_echo_n "checking how to compare bootstrapped objects... " >&6; }
-if ${gcc_cv_prog_cmp_skip+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- echo abfoo >t1
- echo cdfoo >t2
- gcc_cv_prog_cmp_skip='tail -c +17 $$f1 > tmp-foo1; tail -c +17 $$f2 > tmp-foo2; cmp tmp-foo1 tmp-foo2'
- if cmp t1 t2 2 2 > /dev/null 2>&1; then
- if cmp t1 t2 1 1 > /dev/null 2>&1; then
- :
- else
- gcc_cv_prog_cmp_skip='cmp $$f1 $$f2 16 16'
- fi
- fi
- if cmp --ignore-initial=2 t1 t2 > /dev/null 2>&1; then
- if cmp --ignore-initial=1 t1 t2 > /dev/null 2>&1; then
- :
- else
- gcc_cv_prog_cmp_skip='cmp --ignore-initial=16 $$f1 $$f2'
- fi
- fi
- rm t1 t2
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_prog_cmp_skip" >&5
-$as_echo "$gcc_cv_prog_cmp_skip" >&6; }
-do_compare="$gcc_cv_prog_cmp_skip"
-
-
-
-# Check whether --enable-bootstrap was given.
-if test "${enable_bootstrap+set}" = set; then :
- enableval=$enable_bootstrap;
-else
- enable_bootstrap=default
-fi
-
-
-# Issue errors and warnings for invalid/strange bootstrap combinations.
-if test -r $srcdir/gcc/configure; then
- have_compiler=yes
-else
- have_compiler=no
-fi
-
-case "$have_compiler:$host:$target:$enable_bootstrap" in
- *:*:*:no) ;;
-
- # Default behavior. Enable bootstrap if we have a compiler
- # and we are in a native configuration.
- yes:$build:$build:default)
- enable_bootstrap=yes ;;
-
- *:*:*:default)
- enable_bootstrap=no ;;
-
- # We have a compiler and we are in a native configuration, bootstrap is ok
- yes:$build:$build:yes)
- ;;
-
- # Other configurations, but we have a compiler. Assume the user knows
- # what he's doing.
- yes:*:*:yes)
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: trying to bootstrap a cross compiler" >&5
-$as_echo "$as_me: WARNING: trying to bootstrap a cross compiler" >&2;}
- ;;
-
- # No compiler: if they passed --enable-bootstrap explicitly, fail
- no:*:*:yes)
- as_fn_error $? "cannot bootstrap without a compiler" "$LINENO" 5 ;;
-
- # Fail if wrong command line
- *)
- as_fn_error $? "invalid option for --enable-bootstrap" "$LINENO" 5
- ;;
-esac
-
-# When bootstrapping with GCC, build stage 1 in C++11 mode to ensure that a
-# C++11 compiler can still start the bootstrap. Otherwise, if building GCC,
-# require C++11 (or higher).
-if test "$enable_bootstrap:$GXX" = "yes:yes"; then
- CXX="$CXX -std=c++11"
-elif test "$have_compiler" = yes; then
- ax_cxx_compile_alternatives="11 0x" ax_cxx_compile_cxx11_required=true
- ac_ext=cpp
-ac_cpp='$CXXCPP $CPPFLAGS'
-ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
- ac_success=no
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX supports C++11 features by default" >&5
-$as_echo_n "checking whether $CXX supports C++11 features by default... " >&6; }
-if ${ax_cv_cxx_compile_cxx11+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-
-// If the compiler admits that it is not ready for C++11, why torture it?
-// Hopefully, this will speed up the test.
-
-#ifndef __cplusplus
-
-#error "This is not a C++ compiler"
-
-#elif __cplusplus < 201103L
-
-#error "This is not a C++11 compiler"
-
-#else
-
-namespace cxx11
-{
-
- namespace test_static_assert
- {
-
- template <typename T>
- struct check
- {
- static_assert(sizeof(int) <= sizeof(T), "not big enough");
- };
-
- }
-
- namespace test_final_override
- {
-
- struct Base
- {
- virtual ~Base() {}
- virtual void f() {}
- };
-
- struct Derived : public Base
- {
- virtual ~Derived() override {}
- virtual void f() override {}
- };
-
- }
-
- namespace test_double_right_angle_brackets
- {
-
- template < typename T >
- struct check {};
-
- typedef check<void> single_type;
- typedef check<check<void>> double_type;
- typedef check<check<check<void>>> triple_type;
- typedef check<check<check<check<void>>>> quadruple_type;
-
- }
-
- namespace test_decltype
- {
-
- int
- f()
- {
- int a = 1;
- decltype(a) b = 2;
- return a + b;
- }
-
- }
-
- namespace test_type_deduction
- {
-
- template < typename T1, typename T2 >
- struct is_same
- {
- static const bool value = false;
- };
-
- template < typename T >
- struct is_same<T, T>
- {
- static const bool value = true;
- };
-
- template < typename T1, typename T2 >
- auto
- add(T1 a1, T2 a2) -> decltype(a1 + a2)
- {
- return a1 + a2;
- }
-
- int
- test(const int c, volatile int v)
- {
- static_assert(is_same<int, decltype(0)>::value == true, "");
- static_assert(is_same<int, decltype(c)>::value == false, "");
- static_assert(is_same<int, decltype(v)>::value == false, "");
- auto ac = c;
- auto av = v;
- auto sumi = ac + av + 'x';
- auto sumf = ac + av + 1.0;
- static_assert(is_same<int, decltype(ac)>::value == true, "");
- static_assert(is_same<int, decltype(av)>::value == true, "");
- static_assert(is_same<int, decltype(sumi)>::value == true, "");
- static_assert(is_same<int, decltype(sumf)>::value == false, "");
- static_assert(is_same<int, decltype(add(c, v))>::value == true, "");
- return (sumf > 0.0) ? sumi : add(c, v);
- }
-
- }
-
- namespace test_noexcept
- {
-
- int f() { return 0; }
- int g() noexcept { return 0; }
-
- static_assert(noexcept(f()) == false, "");
- static_assert(noexcept(g()) == true, "");
-
- }
-
- namespace test_constexpr
- {
-
- template < typename CharT >
- unsigned long constexpr
- strlen_c_r(const CharT *const s, const unsigned long acc) noexcept
- {
- return *s ? strlen_c_r(s + 1, acc + 1) : acc;
- }
-
- template < typename CharT >
- unsigned long constexpr
- strlen_c(const CharT *const s) noexcept
- {
- return strlen_c_r(s, 0UL);
- }
-
- static_assert(strlen_c("") == 0UL, "");
- static_assert(strlen_c("1") == 1UL, "");
- static_assert(strlen_c("example") == 7UL, "");
- static_assert(strlen_c("another\0example") == 7UL, "");
-
- }
-
- namespace test_rvalue_references
- {
-
- template < int N >
- struct answer
- {
- static constexpr int value = N;
- };
-
- answer<1> f(int&) { return answer<1>(); }
- answer<2> f(const int&) { return answer<2>(); }
- answer<3> f(int&&) { return answer<3>(); }
-
- void
- test()
- {
- int i = 0;
- const int c = 0;
- static_assert(decltype(f(i))::value == 1, "");
- static_assert(decltype(f(c))::value == 2, "");
- static_assert(decltype(f(0))::value == 3, "");
- }
-
- }
-
- namespace test_uniform_initialization
- {
-
- struct test
- {
- static const int zero {};
- static const int one {1};
- };
-
- static_assert(test::zero == 0, "");
- static_assert(test::one == 1, "");
-
- }
-
- namespace test_lambdas
- {
-
- void
- test1()
- {
- auto lambda1 = [](){};
- auto lambda2 = lambda1;
- lambda1();
- lambda2();
- }
-
- int
- test2()
- {
- auto a = [](int i, int j){ return i + j; }(1, 2);
- auto b = []() -> int { return '0'; }();
- auto c = [=](){ return a + b; }();
- auto d = [&](){ return c; }();
- auto e = [a, &b](int x) mutable {
- const auto identity = [](int y){ return y; };
- for (auto i = 0; i < a; ++i)
- a += b--;
- return x + identity(a + b);
- }(0);
- return a + b + c + d + e;
- }
-
- int
- test3()
- {
- const auto nullary = [](){ return 0; };
- const auto unary = [](int x){ return x; };
- using nullary_t = decltype(nullary);
- using unary_t = decltype(unary);
- const auto higher1st = [](nullary_t f){ return f(); };
- const auto higher2nd = [unary](nullary_t f1){
- return [unary, f1](unary_t f2){ return f2(unary(f1())); };
- };
- return higher1st(nullary) + higher2nd(nullary)(unary);
- }
-
- }
-
- namespace test_variadic_templates
- {
-
- template <int...>
- struct sum;
-
- template <int N0, int... N1toN>
- struct sum<N0, N1toN...>
- {
- static constexpr auto value = N0 + sum<N1toN...>::value;
- };
-
- template <>
- struct sum<>
- {
- static constexpr auto value = 0;
- };
-
- static_assert(sum<>::value == 0, "");
- static_assert(sum<1>::value == 1, "");
- static_assert(sum<23>::value == 23, "");
- static_assert(sum<1, 2>::value == 3, "");
- static_assert(sum<5, 5, 11>::value == 21, "");
- static_assert(sum<2, 3, 5, 7, 11, 13>::value == 41, "");
-
- }
-
- // http://stackoverflow.com/questions/13728184/template-aliases-and-sfinae
- // Clang 3.1 fails with headers of libstd++ 4.8.3 when using std::function
- // because of this.
- namespace test_template_alias_sfinae
- {
-
- struct foo {};
-
- template<typename T>
- using member = typename T::member_type;
-
- template<typename T>
- void func(...) {}
-
- template<typename T>
- void func(member<T>*) {}
-
- void test();
-
- void test() { func<foo>(0); }
-
- }
-
-} // namespace cxx11
-
-#endif // __cplusplus >= 201103L
-
-
-
-_ACEOF
-if ac_fn_cxx_try_compile "$LINENO"; then :
- ax_cv_cxx_compile_cxx11=yes
-else
- ax_cv_cxx_compile_cxx11=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_cxx_compile_cxx11" >&5
-$as_echo "$ax_cv_cxx_compile_cxx11" >&6; }
- if test x$ax_cv_cxx_compile_cxx11 = xyes; then
- ac_success=yes
- fi
-
- if test x$ac_success = xno; then
- for alternative in ${ax_cxx_compile_alternatives}; do
- switch="-std=gnu++${alternative}"
- cachevar=`$as_echo "ax_cv_cxx_compile_cxx11_$switch" | $as_tr_sh`
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX supports C++11 features with $switch" >&5
-$as_echo_n "checking whether $CXX supports C++11 features with $switch... " >&6; }
-if eval \${$cachevar+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_save_CXX="$CXX"
- CXX="$CXX $switch"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-
-// If the compiler admits that it is not ready for C++11, why torture it?
-// Hopefully, this will speed up the test.
-
-#ifndef __cplusplus
-
-#error "This is not a C++ compiler"
-
-#elif __cplusplus < 201103L
-
-#error "This is not a C++11 compiler"
-
-#else
-
-namespace cxx11
-{
-
- namespace test_static_assert
- {
-
- template <typename T>
- struct check
- {
- static_assert(sizeof(int) <= sizeof(T), "not big enough");
- };
-
- }
-
- namespace test_final_override
- {
-
- struct Base
- {
- virtual ~Base() {}
- virtual void f() {}
- };
-
- struct Derived : public Base
- {
- virtual ~Derived() override {}
- virtual void f() override {}
- };
-
- }
-
- namespace test_double_right_angle_brackets
- {
-
- template < typename T >
- struct check {};
-
- typedef check<void> single_type;
- typedef check<check<void>> double_type;
- typedef check<check<check<void>>> triple_type;
- typedef check<check<check<check<void>>>> quadruple_type;
-
- }
-
- namespace test_decltype
- {
-
- int
- f()
- {
- int a = 1;
- decltype(a) b = 2;
- return a + b;
- }
-
- }
-
- namespace test_type_deduction
- {
-
- template < typename T1, typename T2 >
- struct is_same
- {
- static const bool value = false;
- };
-
- template < typename T >
- struct is_same<T, T>
- {
- static const bool value = true;
- };
-
- template < typename T1, typename T2 >
- auto
- add(T1 a1, T2 a2) -> decltype(a1 + a2)
- {
- return a1 + a2;
- }
-
- int
- test(const int c, volatile int v)
- {
- static_assert(is_same<int, decltype(0)>::value == true, "");
- static_assert(is_same<int, decltype(c)>::value == false, "");
- static_assert(is_same<int, decltype(v)>::value == false, "");
- auto ac = c;
- auto av = v;
- auto sumi = ac + av + 'x';
- auto sumf = ac + av + 1.0;
- static_assert(is_same<int, decltype(ac)>::value == true, "");
- static_assert(is_same<int, decltype(av)>::value == true, "");
- static_assert(is_same<int, decltype(sumi)>::value == true, "");
- static_assert(is_same<int, decltype(sumf)>::value == false, "");
- static_assert(is_same<int, decltype(add(c, v))>::value == true, "");
- return (sumf > 0.0) ? sumi : add(c, v);
- }
-
- }
-
- namespace test_noexcept
- {
-
- int f() { return 0; }
- int g() noexcept { return 0; }
-
- static_assert(noexcept(f()) == false, "");
- static_assert(noexcept(g()) == true, "");
-
- }
-
- namespace test_constexpr
- {
-
- template < typename CharT >
- unsigned long constexpr
- strlen_c_r(const CharT *const s, const unsigned long acc) noexcept
- {
- return *s ? strlen_c_r(s + 1, acc + 1) : acc;
- }
-
- template < typename CharT >
- unsigned long constexpr
- strlen_c(const CharT *const s) noexcept
- {
- return strlen_c_r(s, 0UL);
- }
-
- static_assert(strlen_c("") == 0UL, "");
- static_assert(strlen_c("1") == 1UL, "");
- static_assert(strlen_c("example") == 7UL, "");
- static_assert(strlen_c("another\0example") == 7UL, "");
-
- }
-
- namespace test_rvalue_references
- {
-
- template < int N >
- struct answer
- {
- static constexpr int value = N;
- };
-
- answer<1> f(int&) { return answer<1>(); }
- answer<2> f(const int&) { return answer<2>(); }
- answer<3> f(int&&) { return answer<3>(); }
-
- void
- test()
- {
- int i = 0;
- const int c = 0;
- static_assert(decltype(f(i))::value == 1, "");
- static_assert(decltype(f(c))::value == 2, "");
- static_assert(decltype(f(0))::value == 3, "");
- }
-
- }
-
- namespace test_uniform_initialization
- {
-
- struct test
- {
- static const int zero {};
- static const int one {1};
- };
-
- static_assert(test::zero == 0, "");
- static_assert(test::one == 1, "");
-
- }
-
- namespace test_lambdas
- {
-
- void
- test1()
- {
- auto lambda1 = [](){};
- auto lambda2 = lambda1;
- lambda1();
- lambda2();
- }
-
- int
- test2()
- {
- auto a = [](int i, int j){ return i + j; }(1, 2);
- auto b = []() -> int { return '0'; }();
- auto c = [=](){ return a + b; }();
- auto d = [&](){ return c; }();
- auto e = [a, &b](int x) mutable {
- const auto identity = [](int y){ return y; };
- for (auto i = 0; i < a; ++i)
- a += b--;
- return x + identity(a + b);
- }(0);
- return a + b + c + d + e;
- }
-
- int
- test3()
- {
- const auto nullary = [](){ return 0; };
- const auto unary = [](int x){ return x; };
- using nullary_t = decltype(nullary);
- using unary_t = decltype(unary);
- const auto higher1st = [](nullary_t f){ return f(); };
- const auto higher2nd = [unary](nullary_t f1){
- return [unary, f1](unary_t f2){ return f2(unary(f1())); };
- };
- return higher1st(nullary) + higher2nd(nullary)(unary);
- }
-
- }
-
- namespace test_variadic_templates
- {
-
- template <int...>
- struct sum;
-
- template <int N0, int... N1toN>
- struct sum<N0, N1toN...>
- {
- static constexpr auto value = N0 + sum<N1toN...>::value;
- };
-
- template <>
- struct sum<>
- {
- static constexpr auto value = 0;
- };
-
- static_assert(sum<>::value == 0, "");
- static_assert(sum<1>::value == 1, "");
- static_assert(sum<23>::value == 23, "");
- static_assert(sum<1, 2>::value == 3, "");
- static_assert(sum<5, 5, 11>::value == 21, "");
- static_assert(sum<2, 3, 5, 7, 11, 13>::value == 41, "");
-
- }
-
- // http://stackoverflow.com/questions/13728184/template-aliases-and-sfinae
- // Clang 3.1 fails with headers of libstd++ 4.8.3 when using std::function
- // because of this.
- namespace test_template_alias_sfinae
- {
-
- struct foo {};
-
- template<typename T>
- using member = typename T::member_type;
-
- template<typename T>
- void func(...) {}
-
- template<typename T>
- void func(member<T>*) {}
-
- void test();
-
- void test() { func<foo>(0); }
-
- }
-
-} // namespace cxx11
-
-#endif // __cplusplus >= 201103L
-
-
-
-_ACEOF
-if ac_fn_cxx_try_compile "$LINENO"; then :
- eval $cachevar=yes
-else
- eval $cachevar=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- CXX="$ac_save_CXX"
-fi
-eval ac_res=\$$cachevar
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
- if eval test x\$$cachevar = xyes; then
- CXX="$CXX $switch"
- if test -n "$CXXCPP" ; then
- CXXCPP="$CXXCPP $switch"
- fi
- ac_success=yes
- break
- fi
- done
- fi
-
- if test x$ac_success = xno; then
- for alternative in ${ax_cxx_compile_alternatives}; do
- for switch in -std=c++${alternative} +std=c++${alternative} "-h std=c++${alternative}"; do
- cachevar=`$as_echo "ax_cv_cxx_compile_cxx11_$switch" | $as_tr_sh`
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX supports C++11 features with $switch" >&5
-$as_echo_n "checking whether $CXX supports C++11 features with $switch... " >&6; }
-if eval \${$cachevar+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_save_CXX="$CXX"
- CXX="$CXX $switch"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-
-// If the compiler admits that it is not ready for C++11, why torture it?
-// Hopefully, this will speed up the test.
-
-#ifndef __cplusplus
-
-#error "This is not a C++ compiler"
-
-#elif __cplusplus < 201103L
-
-#error "This is not a C++11 compiler"
-
-#else
-
-namespace cxx11
-{
-
- namespace test_static_assert
- {
-
- template <typename T>
- struct check
- {
- static_assert(sizeof(int) <= sizeof(T), "not big enough");
- };
-
- }
-
- namespace test_final_override
- {
-
- struct Base
- {
- virtual ~Base() {}
- virtual void f() {}
- };
-
- struct Derived : public Base
- {
- virtual ~Derived() override {}
- virtual void f() override {}
- };
-
- }
-
- namespace test_double_right_angle_brackets
- {
-
- template < typename T >
- struct check {};
-
- typedef check<void> single_type;
- typedef check<check<void>> double_type;
- typedef check<check<check<void>>> triple_type;
- typedef check<check<check<check<void>>>> quadruple_type;
-
- }
-
- namespace test_decltype
- {
-
- int
- f()
- {
- int a = 1;
- decltype(a) b = 2;
- return a + b;
- }
-
- }
-
- namespace test_type_deduction
- {
-
- template < typename T1, typename T2 >
- struct is_same
- {
- static const bool value = false;
- };
-
- template < typename T >
- struct is_same<T, T>
- {
- static const bool value = true;
- };
-
- template < typename T1, typename T2 >
- auto
- add(T1 a1, T2 a2) -> decltype(a1 + a2)
- {
- return a1 + a2;
- }
-
- int
- test(const int c, volatile int v)
- {
- static_assert(is_same<int, decltype(0)>::value == true, "");
- static_assert(is_same<int, decltype(c)>::value == false, "");
- static_assert(is_same<int, decltype(v)>::value == false, "");
- auto ac = c;
- auto av = v;
- auto sumi = ac + av + 'x';
- auto sumf = ac + av + 1.0;
- static_assert(is_same<int, decltype(ac)>::value == true, "");
- static_assert(is_same<int, decltype(av)>::value == true, "");
- static_assert(is_same<int, decltype(sumi)>::value == true, "");
- static_assert(is_same<int, decltype(sumf)>::value == false, "");
- static_assert(is_same<int, decltype(add(c, v))>::value == true, "");
- return (sumf > 0.0) ? sumi : add(c, v);
- }
-
- }
-
- namespace test_noexcept
- {
-
- int f() { return 0; }
- int g() noexcept { return 0; }
-
- static_assert(noexcept(f()) == false, "");
- static_assert(noexcept(g()) == true, "");
-
- }
-
- namespace test_constexpr
- {
-
- template < typename CharT >
- unsigned long constexpr
- strlen_c_r(const CharT *const s, const unsigned long acc) noexcept
- {
- return *s ? strlen_c_r(s + 1, acc + 1) : acc;
- }
-
- template < typename CharT >
- unsigned long constexpr
- strlen_c(const CharT *const s) noexcept
- {
- return strlen_c_r(s, 0UL);
- }
-
- static_assert(strlen_c("") == 0UL, "");
- static_assert(strlen_c("1") == 1UL, "");
- static_assert(strlen_c("example") == 7UL, "");
- static_assert(strlen_c("another\0example") == 7UL, "");
-
- }
-
- namespace test_rvalue_references
- {
-
- template < int N >
- struct answer
- {
- static constexpr int value = N;
- };
-
- answer<1> f(int&) { return answer<1>(); }
- answer<2> f(const int&) { return answer<2>(); }
- answer<3> f(int&&) { return answer<3>(); }
-
- void
- test()
- {
- int i = 0;
- const int c = 0;
- static_assert(decltype(f(i))::value == 1, "");
- static_assert(decltype(f(c))::value == 2, "");
- static_assert(decltype(f(0))::value == 3, "");
- }
-
- }
-
- namespace test_uniform_initialization
- {
-
- struct test
- {
- static const int zero {};
- static const int one {1};
- };
-
- static_assert(test::zero == 0, "");
- static_assert(test::one == 1, "");
-
- }
-
- namespace test_lambdas
- {
-
- void
- test1()
- {
- auto lambda1 = [](){};
- auto lambda2 = lambda1;
- lambda1();
- lambda2();
- }
-
- int
- test2()
- {
- auto a = [](int i, int j){ return i + j; }(1, 2);
- auto b = []() -> int { return '0'; }();
- auto c = [=](){ return a + b; }();
- auto d = [&](){ return c; }();
- auto e = [a, &b](int x) mutable {
- const auto identity = [](int y){ return y; };
- for (auto i = 0; i < a; ++i)
- a += b--;
- return x + identity(a + b);
- }(0);
- return a + b + c + d + e;
- }
-
- int
- test3()
- {
- const auto nullary = [](){ return 0; };
- const auto unary = [](int x){ return x; };
- using nullary_t = decltype(nullary);
- using unary_t = decltype(unary);
- const auto higher1st = [](nullary_t f){ return f(); };
- const auto higher2nd = [unary](nullary_t f1){
- return [unary, f1](unary_t f2){ return f2(unary(f1())); };
- };
- return higher1st(nullary) + higher2nd(nullary)(unary);
- }
-
- }
-
- namespace test_variadic_templates
- {
-
- template <int...>
- struct sum;
-
- template <int N0, int... N1toN>
- struct sum<N0, N1toN...>
- {
- static constexpr auto value = N0 + sum<N1toN...>::value;
- };
-
- template <>
- struct sum<>
- {
- static constexpr auto value = 0;
- };
-
- static_assert(sum<>::value == 0, "");
- static_assert(sum<1>::value == 1, "");
- static_assert(sum<23>::value == 23, "");
- static_assert(sum<1, 2>::value == 3, "");
- static_assert(sum<5, 5, 11>::value == 21, "");
- static_assert(sum<2, 3, 5, 7, 11, 13>::value == 41, "");
-
- }
-
- // http://stackoverflow.com/questions/13728184/template-aliases-and-sfinae
- // Clang 3.1 fails with headers of libstd++ 4.8.3 when using std::function
- // because of this.
- namespace test_template_alias_sfinae
- {
-
- struct foo {};
-
- template<typename T>
- using member = typename T::member_type;
-
- template<typename T>
- void func(...) {}
-
- template<typename T>
- void func(member<T>*) {}
-
- void test();
-
- void test() { func<foo>(0); }
-
- }
-
-} // namespace cxx11
-
-#endif // __cplusplus >= 201103L
-
-
-
-_ACEOF
-if ac_fn_cxx_try_compile "$LINENO"; then :
- eval $cachevar=yes
-else
- eval $cachevar=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- CXX="$ac_save_CXX"
-fi
-eval ac_res=\$$cachevar
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
- if eval test x\$$cachevar = xyes; then
- CXX="$CXX $switch"
- if test -n "$CXXCPP" ; then
- CXXCPP="$CXXCPP $switch"
- fi
- ac_success=yes
- break
- fi
- done
- if test x$ac_success = xyes; then
- break
- fi
- done
- fi
-
- ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
- if test x$ax_cxx_compile_cxx11_required = xtrue; then
- if test x$ac_success = xno; then
- as_fn_error $? "*** A compiler with support for C++11 language features is required." "$LINENO" 5
- fi
- fi
- if test x$ac_success = xno; then
- HAVE_CXX11=0
- { $as_echo "$as_me:${as_lineno-$LINENO}: No compiler with C++11 support was found" >&5
-$as_echo "$as_me: No compiler with C++11 support was found" >&6;}
- else
- HAVE_CXX11=1
-
-$as_echo "#define HAVE_CXX11 1" >>confdefs.h
-
- fi
-
-
-
- if test "${build}" != "${host}"; then
- ax_cxx_compile_alternatives="11 0x" ax_cxx_compile_cxx11_required=true
- ac_ext=cpp
-ac_cpp='$CXXCPP $CPPFLAGS'
-ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
- ac_success=no
- ax_cv_cxx_compile_cxx11_orig_cxx="$CXX"
- ax_cv_cxx_compile_cxx11_orig_cxxflags="$CXXFLAGS"
- ax_cv_cxx_compile_cxx11_orig_cppflags="$CPPFLAGS"
- CXX="$CXX_FOR_BUILD"
- CXXFLAGS="$CXXFLAGS_FOR_BUILD"
- CPPFLAGS="$CPPFLAGS_FOR_BUILD"
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX supports C++11 features by default" >&5
-$as_echo_n "checking whether $CXX supports C++11 features by default... " >&6; }
-if ${ax_cv_cxx_compile_cxx11_FOR_BUILD+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-
-// If the compiler admits that it is not ready for C++11, why torture it?
-// Hopefully, this will speed up the test.
-
-#ifndef __cplusplus
-
-#error "This is not a C++ compiler"
-
-#elif __cplusplus < 201103L
-
-#error "This is not a C++11 compiler"
-
-#else
-
-namespace cxx11
-{
-
- namespace test_static_assert
- {
-
- template <typename T>
- struct check
- {
- static_assert(sizeof(int) <= sizeof(T), "not big enough");
- };
-
- }
-
- namespace test_final_override
- {
-
- struct Base
- {
- virtual ~Base() {}
- virtual void f() {}
- };
-
- struct Derived : public Base
- {
- virtual ~Derived() override {}
- virtual void f() override {}
- };
-
- }
-
- namespace test_double_right_angle_brackets
- {
-
- template < typename T >
- struct check {};
-
- typedef check<void> single_type;
- typedef check<check<void>> double_type;
- typedef check<check<check<void>>> triple_type;
- typedef check<check<check<check<void>>>> quadruple_type;
-
- }
-
- namespace test_decltype
- {
-
- int
- f()
- {
- int a = 1;
- decltype(a) b = 2;
- return a + b;
- }
-
- }
-
- namespace test_type_deduction
- {
-
- template < typename T1, typename T2 >
- struct is_same
- {
- static const bool value = false;
- };
-
- template < typename T >
- struct is_same<T, T>
- {
- static const bool value = true;
- };
-
- template < typename T1, typename T2 >
- auto
- add(T1 a1, T2 a2) -> decltype(a1 + a2)
- {
- return a1 + a2;
- }
-
- int
- test(const int c, volatile int v)
- {
- static_assert(is_same<int, decltype(0)>::value == true, "");
- static_assert(is_same<int, decltype(c)>::value == false, "");
- static_assert(is_same<int, decltype(v)>::value == false, "");
- auto ac = c;
- auto av = v;
- auto sumi = ac + av + 'x';
- auto sumf = ac + av + 1.0;
- static_assert(is_same<int, decltype(ac)>::value == true, "");
- static_assert(is_same<int, decltype(av)>::value == true, "");
- static_assert(is_same<int, decltype(sumi)>::value == true, "");
- static_assert(is_same<int, decltype(sumf)>::value == false, "");
- static_assert(is_same<int, decltype(add(c, v))>::value == true, "");
- return (sumf > 0.0) ? sumi : add(c, v);
- }
-
- }
-
- namespace test_noexcept
- {
-
- int f() { return 0; }
- int g() noexcept { return 0; }
-
- static_assert(noexcept(f()) == false, "");
- static_assert(noexcept(g()) == true, "");
-
- }
-
- namespace test_constexpr
- {
-
- template < typename CharT >
- unsigned long constexpr
- strlen_c_r(const CharT *const s, const unsigned long acc) noexcept
- {
- return *s ? strlen_c_r(s + 1, acc + 1) : acc;
- }
-
- template < typename CharT >
- unsigned long constexpr
- strlen_c(const CharT *const s) noexcept
- {
- return strlen_c_r(s, 0UL);
- }
-
- static_assert(strlen_c("") == 0UL, "");
- static_assert(strlen_c("1") == 1UL, "");
- static_assert(strlen_c("example") == 7UL, "");
- static_assert(strlen_c("another\0example") == 7UL, "");
-
- }
-
- namespace test_rvalue_references
- {
-
- template < int N >
- struct answer
- {
- static constexpr int value = N;
- };
-
- answer<1> f(int&) { return answer<1>(); }
- answer<2> f(const int&) { return answer<2>(); }
- answer<3> f(int&&) { return answer<3>(); }
-
- void
- test()
- {
- int i = 0;
- const int c = 0;
- static_assert(decltype(f(i))::value == 1, "");
- static_assert(decltype(f(c))::value == 2, "");
- static_assert(decltype(f(0))::value == 3, "");
- }
-
- }
-
- namespace test_uniform_initialization
- {
-
- struct test
- {
- static const int zero {};
- static const int one {1};
- };
-
- static_assert(test::zero == 0, "");
- static_assert(test::one == 1, "");
-
- }
-
- namespace test_lambdas
- {
-
- void
- test1()
- {
- auto lambda1 = [](){};
- auto lambda2 = lambda1;
- lambda1();
- lambda2();
- }
-
- int
- test2()
- {
- auto a = [](int i, int j){ return i + j; }(1, 2);
- auto b = []() -> int { return '0'; }();
- auto c = [=](){ return a + b; }();
- auto d = [&](){ return c; }();
- auto e = [a, &b](int x) mutable {
- const auto identity = [](int y){ return y; };
- for (auto i = 0; i < a; ++i)
- a += b--;
- return x + identity(a + b);
- }(0);
- return a + b + c + d + e;
- }
-
- int
- test3()
- {
- const auto nullary = [](){ return 0; };
- const auto unary = [](int x){ return x; };
- using nullary_t = decltype(nullary);
- using unary_t = decltype(unary);
- const auto higher1st = [](nullary_t f){ return f(); };
- const auto higher2nd = [unary](nullary_t f1){
- return [unary, f1](unary_t f2){ return f2(unary(f1())); };
- };
- return higher1st(nullary) + higher2nd(nullary)(unary);
- }
-
- }
-
- namespace test_variadic_templates
- {
-
- template <int...>
- struct sum;
-
- template <int N0, int... N1toN>
- struct sum<N0, N1toN...>
- {
- static constexpr auto value = N0 + sum<N1toN...>::value;
- };
-
- template <>
- struct sum<>
- {
- static constexpr auto value = 0;
- };
-
- static_assert(sum<>::value == 0, "");
- static_assert(sum<1>::value == 1, "");
- static_assert(sum<23>::value == 23, "");
- static_assert(sum<1, 2>::value == 3, "");
- static_assert(sum<5, 5, 11>::value == 21, "");
- static_assert(sum<2, 3, 5, 7, 11, 13>::value == 41, "");
-
- }
-
- // http://stackoverflow.com/questions/13728184/template-aliases-and-sfinae
- // Clang 3.1 fails with headers of libstd++ 4.8.3 when using std::function
- // because of this.
- namespace test_template_alias_sfinae
- {
-
- struct foo {};
-
- template<typename T>
- using member = typename T::member_type;
-
- template<typename T>
- void func(...) {}
-
- template<typename T>
- void func(member<T>*) {}
-
- void test();
-
- void test() { func<foo>(0); }
-
- }
-
-} // namespace cxx11
-
-#endif // __cplusplus >= 201103L
-
-
-
-_ACEOF
-if ac_fn_cxx_try_compile "$LINENO"; then :
- ax_cv_cxx_compile_cxx11_FOR_BUILD=yes
-else
- ax_cv_cxx_compile_cxx11_FOR_BUILD=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_cxx_compile_cxx11_FOR_BUILD" >&5
-$as_echo "$ax_cv_cxx_compile_cxx11_FOR_BUILD" >&6; }
- if test x$ax_cv_cxx_compile_cxx11_FOR_BUILD = xyes; then
- ac_success=yes
- fi
-
- if test x$ac_success = xno; then
- for alternative in ${ax_cxx_compile_alternatives}; do
- switch="-std=gnu++${alternative}"
- cachevar=`$as_echo "ax_cv_cxx_compile_cxx11_FOR_BUILD_$switch" | $as_tr_sh`
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX supports C++11 features with $switch" >&5
-$as_echo_n "checking whether $CXX supports C++11 features with $switch... " >&6; }
-if eval \${$cachevar+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_save_CXX="$CXX"
- CXX="$CXX $switch"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-
-// If the compiler admits that it is not ready for C++11, why torture it?
-// Hopefully, this will speed up the test.
-
-#ifndef __cplusplus
-
-#error "This is not a C++ compiler"
-
-#elif __cplusplus < 201103L
-
-#error "This is not a C++11 compiler"
-
-#else
-
-namespace cxx11
-{
-
- namespace test_static_assert
- {
-
- template <typename T>
- struct check
- {
- static_assert(sizeof(int) <= sizeof(T), "not big enough");
- };
-
- }
-
- namespace test_final_override
- {
-
- struct Base
- {
- virtual ~Base() {}
- virtual void f() {}
- };
-
- struct Derived : public Base
- {
- virtual ~Derived() override {}
- virtual void f() override {}
- };
-
- }
-
- namespace test_double_right_angle_brackets
- {
-
- template < typename T >
- struct check {};
-
- typedef check<void> single_type;
- typedef check<check<void>> double_type;
- typedef check<check<check<void>>> triple_type;
- typedef check<check<check<check<void>>>> quadruple_type;
-
- }
-
- namespace test_decltype
- {
-
- int
- f()
- {
- int a = 1;
- decltype(a) b = 2;
- return a + b;
- }
-
- }
-
- namespace test_type_deduction
- {
-
- template < typename T1, typename T2 >
- struct is_same
- {
- static const bool value = false;
- };
-
- template < typename T >
- struct is_same<T, T>
- {
- static const bool value = true;
- };
-
- template < typename T1, typename T2 >
- auto
- add(T1 a1, T2 a2) -> decltype(a1 + a2)
- {
- return a1 + a2;
- }
-
- int
- test(const int c, volatile int v)
- {
- static_assert(is_same<int, decltype(0)>::value == true, "");
- static_assert(is_same<int, decltype(c)>::value == false, "");
- static_assert(is_same<int, decltype(v)>::value == false, "");
- auto ac = c;
- auto av = v;
- auto sumi = ac + av + 'x';
- auto sumf = ac + av + 1.0;
- static_assert(is_same<int, decltype(ac)>::value == true, "");
- static_assert(is_same<int, decltype(av)>::value == true, "");
- static_assert(is_same<int, decltype(sumi)>::value == true, "");
- static_assert(is_same<int, decltype(sumf)>::value == false, "");
- static_assert(is_same<int, decltype(add(c, v))>::value == true, "");
- return (sumf > 0.0) ? sumi : add(c, v);
- }
-
- }
-
- namespace test_noexcept
- {
-
- int f() { return 0; }
- int g() noexcept { return 0; }
-
- static_assert(noexcept(f()) == false, "");
- static_assert(noexcept(g()) == true, "");
-
- }
-
- namespace test_constexpr
- {
-
- template < typename CharT >
- unsigned long constexpr
- strlen_c_r(const CharT *const s, const unsigned long acc) noexcept
- {
- return *s ? strlen_c_r(s + 1, acc + 1) : acc;
- }
-
- template < typename CharT >
- unsigned long constexpr
- strlen_c(const CharT *const s) noexcept
- {
- return strlen_c_r(s, 0UL);
- }
-
- static_assert(strlen_c("") == 0UL, "");
- static_assert(strlen_c("1") == 1UL, "");
- static_assert(strlen_c("example") == 7UL, "");
- static_assert(strlen_c("another\0example") == 7UL, "");
-
- }
-
- namespace test_rvalue_references
- {
-
- template < int N >
- struct answer
- {
- static constexpr int value = N;
- };
-
- answer<1> f(int&) { return answer<1>(); }
- answer<2> f(const int&) { return answer<2>(); }
- answer<3> f(int&&) { return answer<3>(); }
-
- void
- test()
- {
- int i = 0;
- const int c = 0;
- static_assert(decltype(f(i))::value == 1, "");
- static_assert(decltype(f(c))::value == 2, "");
- static_assert(decltype(f(0))::value == 3, "");
- }
-
- }
-
- namespace test_uniform_initialization
- {
-
- struct test
- {
- static const int zero {};
- static const int one {1};
- };
-
- static_assert(test::zero == 0, "");
- static_assert(test::one == 1, "");
-
- }
-
- namespace test_lambdas
- {
-
- void
- test1()
- {
- auto lambda1 = [](){};
- auto lambda2 = lambda1;
- lambda1();
- lambda2();
- }
-
- int
- test2()
- {
- auto a = [](int i, int j){ return i + j; }(1, 2);
- auto b = []() -> int { return '0'; }();
- auto c = [=](){ return a + b; }();
- auto d = [&](){ return c; }();
- auto e = [a, &b](int x) mutable {
- const auto identity = [](int y){ return y; };
- for (auto i = 0; i < a; ++i)
- a += b--;
- return x + identity(a + b);
- }(0);
- return a + b + c + d + e;
- }
-
- int
- test3()
- {
- const auto nullary = [](){ return 0; };
- const auto unary = [](int x){ return x; };
- using nullary_t = decltype(nullary);
- using unary_t = decltype(unary);
- const auto higher1st = [](nullary_t f){ return f(); };
- const auto higher2nd = [unary](nullary_t f1){
- return [unary, f1](unary_t f2){ return f2(unary(f1())); };
- };
- return higher1st(nullary) + higher2nd(nullary)(unary);
- }
-
- }
-
- namespace test_variadic_templates
- {
-
- template <int...>
- struct sum;
-
- template <int N0, int... N1toN>
- struct sum<N0, N1toN...>
- {
- static constexpr auto value = N0 + sum<N1toN...>::value;
- };
-
- template <>
- struct sum<>
- {
- static constexpr auto value = 0;
- };
-
- static_assert(sum<>::value == 0, "");
- static_assert(sum<1>::value == 1, "");
- static_assert(sum<23>::value == 23, "");
- static_assert(sum<1, 2>::value == 3, "");
- static_assert(sum<5, 5, 11>::value == 21, "");
- static_assert(sum<2, 3, 5, 7, 11, 13>::value == 41, "");
-
- }
-
- // http://stackoverflow.com/questions/13728184/template-aliases-and-sfinae
- // Clang 3.1 fails with headers of libstd++ 4.8.3 when using std::function
- // because of this.
- namespace test_template_alias_sfinae
- {
-
- struct foo {};
-
- template<typename T>
- using member = typename T::member_type;
-
- template<typename T>
- void func(...) {}
-
- template<typename T>
- void func(member<T>*) {}
-
- void test();
-
- void test() { func<foo>(0); }
-
- }
-
-} // namespace cxx11
-
-#endif // __cplusplus >= 201103L
-
-
-
-_ACEOF
-if ac_fn_cxx_try_compile "$LINENO"; then :
- eval $cachevar=yes
-else
- eval $cachevar=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- CXX="$ac_save_CXX"
-fi
-eval ac_res=\$$cachevar
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
- if eval test x\$$cachevar = xyes; then
- CXX="$CXX $switch"
- if test -n "$CXXCPP" ; then
- CXXCPP="$CXXCPP $switch"
- fi
- ac_success=yes
- break
- fi
- done
- fi
-
- if test x$ac_success = xno; then
- for alternative in ${ax_cxx_compile_alternatives}; do
- for switch in -std=c++${alternative} +std=c++${alternative} "-h std=c++${alternative}"; do
- cachevar=`$as_echo "ax_cv_cxx_compile_cxx11_FOR_BUILD_$switch" | $as_tr_sh`
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX supports C++11 features with $switch" >&5
-$as_echo_n "checking whether $CXX supports C++11 features with $switch... " >&6; }
-if eval \${$cachevar+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_save_CXX="$CXX"
- CXX="$CXX $switch"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-
-// If the compiler admits that it is not ready for C++11, why torture it?
-// Hopefully, this will speed up the test.
-
-#ifndef __cplusplus
-
-#error "This is not a C++ compiler"
-
-#elif __cplusplus < 201103L
-
-#error "This is not a C++11 compiler"
-
-#else
-
-namespace cxx11
-{
-
- namespace test_static_assert
- {
-
- template <typename T>
- struct check
- {
- static_assert(sizeof(int) <= sizeof(T), "not big enough");
- };
-
- }
-
- namespace test_final_override
- {
-
- struct Base
- {
- virtual ~Base() {}
- virtual void f() {}
- };
-
- struct Derived : public Base
- {
- virtual ~Derived() override {}
- virtual void f() override {}
- };
-
- }
-
- namespace test_double_right_angle_brackets
- {
-
- template < typename T >
- struct check {};
-
- typedef check<void> single_type;
- typedef check<check<void>> double_type;
- typedef check<check<check<void>>> triple_type;
- typedef check<check<check<check<void>>>> quadruple_type;
-
- }
-
- namespace test_decltype
- {
-
- int
- f()
- {
- int a = 1;
- decltype(a) b = 2;
- return a + b;
- }
-
- }
-
- namespace test_type_deduction
- {
-
- template < typename T1, typename T2 >
- struct is_same
- {
- static const bool value = false;
- };
-
- template < typename T >
- struct is_same<T, T>
- {
- static const bool value = true;
- };
-
- template < typename T1, typename T2 >
- auto
- add(T1 a1, T2 a2) -> decltype(a1 + a2)
- {
- return a1 + a2;
- }
-
- int
- test(const int c, volatile int v)
- {
- static_assert(is_same<int, decltype(0)>::value == true, "");
- static_assert(is_same<int, decltype(c)>::value == false, "");
- static_assert(is_same<int, decltype(v)>::value == false, "");
- auto ac = c;
- auto av = v;
- auto sumi = ac + av + 'x';
- auto sumf = ac + av + 1.0;
- static_assert(is_same<int, decltype(ac)>::value == true, "");
- static_assert(is_same<int, decltype(av)>::value == true, "");
- static_assert(is_same<int, decltype(sumi)>::value == true, "");
- static_assert(is_same<int, decltype(sumf)>::value == false, "");
- static_assert(is_same<int, decltype(add(c, v))>::value == true, "");
- return (sumf > 0.0) ? sumi : add(c, v);
- }
-
- }
-
- namespace test_noexcept
- {
-
- int f() { return 0; }
- int g() noexcept { return 0; }
-
- static_assert(noexcept(f()) == false, "");
- static_assert(noexcept(g()) == true, "");
-
- }
-
- namespace test_constexpr
- {
-
- template < typename CharT >
- unsigned long constexpr
- strlen_c_r(const CharT *const s, const unsigned long acc) noexcept
- {
- return *s ? strlen_c_r(s + 1, acc + 1) : acc;
- }
-
- template < typename CharT >
- unsigned long constexpr
- strlen_c(const CharT *const s) noexcept
- {
- return strlen_c_r(s, 0UL);
- }
-
- static_assert(strlen_c("") == 0UL, "");
- static_assert(strlen_c("1") == 1UL, "");
- static_assert(strlen_c("example") == 7UL, "");
- static_assert(strlen_c("another\0example") == 7UL, "");
-
- }
-
- namespace test_rvalue_references
- {
-
- template < int N >
- struct answer
- {
- static constexpr int value = N;
- };
-
- answer<1> f(int&) { return answer<1>(); }
- answer<2> f(const int&) { return answer<2>(); }
- answer<3> f(int&&) { return answer<3>(); }
-
- void
- test()
- {
- int i = 0;
- const int c = 0;
- static_assert(decltype(f(i))::value == 1, "");
- static_assert(decltype(f(c))::value == 2, "");
- static_assert(decltype(f(0))::value == 3, "");
- }
-
- }
-
- namespace test_uniform_initialization
- {
-
- struct test
- {
- static const int zero {};
- static const int one {1};
- };
-
- static_assert(test::zero == 0, "");
- static_assert(test::one == 1, "");
-
- }
-
- namespace test_lambdas
- {
-
- void
- test1()
- {
- auto lambda1 = [](){};
- auto lambda2 = lambda1;
- lambda1();
- lambda2();
- }
-
- int
- test2()
- {
- auto a = [](int i, int j){ return i + j; }(1, 2);
- auto b = []() -> int { return '0'; }();
- auto c = [=](){ return a + b; }();
- auto d = [&](){ return c; }();
- auto e = [a, &b](int x) mutable {
- const auto identity = [](int y){ return y; };
- for (auto i = 0; i < a; ++i)
- a += b--;
- return x + identity(a + b);
- }(0);
- return a + b + c + d + e;
- }
-
- int
- test3()
- {
- const auto nullary = [](){ return 0; };
- const auto unary = [](int x){ return x; };
- using nullary_t = decltype(nullary);
- using unary_t = decltype(unary);
- const auto higher1st = [](nullary_t f){ return f(); };
- const auto higher2nd = [unary](nullary_t f1){
- return [unary, f1](unary_t f2){ return f2(unary(f1())); };
- };
- return higher1st(nullary) + higher2nd(nullary)(unary);
- }
-
- }
-
- namespace test_variadic_templates
- {
-
- template <int...>
- struct sum;
-
- template <int N0, int... N1toN>
- struct sum<N0, N1toN...>
- {
- static constexpr auto value = N0 + sum<N1toN...>::value;
- };
-
- template <>
- struct sum<>
- {
- static constexpr auto value = 0;
- };
-
- static_assert(sum<>::value == 0, "");
- static_assert(sum<1>::value == 1, "");
- static_assert(sum<23>::value == 23, "");
- static_assert(sum<1, 2>::value == 3, "");
- static_assert(sum<5, 5, 11>::value == 21, "");
- static_assert(sum<2, 3, 5, 7, 11, 13>::value == 41, "");
-
- }
-
- // http://stackoverflow.com/questions/13728184/template-aliases-and-sfinae
- // Clang 3.1 fails with headers of libstd++ 4.8.3 when using std::function
- // because of this.
- namespace test_template_alias_sfinae
- {
-
- struct foo {};
-
- template<typename T>
- using member = typename T::member_type;
-
- template<typename T>
- void func(...) {}
-
- template<typename T>
- void func(member<T>*) {}
-
- void test();
-
- void test() { func<foo>(0); }
-
- }
-
-} // namespace cxx11
-
-#endif // __cplusplus >= 201103L
-
-
-
-_ACEOF
-if ac_fn_cxx_try_compile "$LINENO"; then :
- eval $cachevar=yes
-else
- eval $cachevar=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- CXX="$ac_save_CXX"
-fi
-eval ac_res=\$$cachevar
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
- if eval test x\$$cachevar = xyes; then
- CXX="$CXX $switch"
- if test -n "$CXXCPP" ; then
- CXXCPP="$CXXCPP $switch"
- fi
- ac_success=yes
- break
- fi
- done
- if test x$ac_success = xyes; then
- break
- fi
- done
- fi
- CXX_FOR_BUILD="$CXX"
- CXXFLAGS_FOR_BUILD="$CXXFLAGS"
- CPPFLAGS_FOR_BUILD="$CPPFLAGS"
- CXX="$ax_cv_cxx_compile_cxx11_orig_cxx"
- CXXFLAGS="$ax_cv_cxx_compile_cxx11_orig_cxxflags"
- CPPFLAGS="$ax_cv_cxx_compile_cxx11_orig_cppflags"
- ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
- if test x$ax_cxx_compile_cxx11_required = xtrue; then
- if test x$ac_success = xno; then
- as_fn_error $? "*** A compiler with support for C++11 language features is required." "$LINENO" 5
- fi
- fi
- if test x$ac_success = xno; then
- HAVE_CXX11_FOR_BUILD=0
- { $as_echo "$as_me:${as_lineno-$LINENO}: No compiler with C++11 support was found" >&5
-$as_echo "$as_me: No compiler with C++11 support was found" >&6;}
- else
- HAVE_CXX11_FOR_BUILD=1
-
-$as_echo "#define HAVE_CXX11_FOR_BUILD 1" >>confdefs.h
-
- fi
-
-
- fi
-fi
-
-# Check whether --enable-pgo-build was given.
-if test "${enable_pgo_build+set}" = set; then :
- enableval=$enable_pgo_build; enable_pgo_build=$enableval
-else
- enable_pgo_build=no
-fi
-
-
-# Issue errors and warnings for invalid/strange PGO build combinations.
-case "$have_compiler:$host:$target:$enable_pgo_build" in
- *:*:*:no) ;;
-
- # Allow the PGO build only if we aren't building a compiler and
- # we are in a native configuration.
- no:$build:$build:yes | no:$build:$build:lto) ;;
-
- # Disallow the PGO bootstrap if we are building a compiler.
- yes:*:*:yes | yes:*:*:lto)
- as_fn_error $? "cannot perform the PGO bootstrap when building a compiler" "$LINENO" 5 ;;
-
- *)
- as_fn_error $? "invalid option for --enable-pgo-build" "$LINENO" 5
- ;;
-esac
-
-if test "$enable_pgo_build" != "no"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the compiler supports -fprofile-generate" >&5
-$as_echo_n "checking whether the compiler supports -fprofile-generate... " >&6; }
- old_CFLAGS="$CFLAGS"
- PGO_BUILD_GEN_CFLAGS="-fprofile-generate"
- CFLAGS="$CFLAGS $PGO_BUILD_CFLAGS"
-
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-int foo;
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
-
-else
- PGO_BUILD_GEN_CFLAGS=
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- CFLAGS="$old_CFLAGS"
- if test -n "$PGO_BUILD_GEN_CFLAGS"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- PGO_BUILD_USE_CFLAGS="-fprofile-use"
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- as_fn_error $? "cannot perform the PGO build without -fprofile-generate" "$LINENO" 5
- fi
-
- if test "$enable_pgo_build" = "lto"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the compiler supports -flto=jobserver -ffat-lto-objects" >&5
-$as_echo_n "checking whether the compiler supports -flto=jobserver -ffat-lto-objects... " >&6; }
- old_CFLAGS="$CFLAGS"
- PGO_BUILD_LTO_CFLAGS="-flto=jobserver -ffat-lto-objects"
- CFLAGS="$CFLAGS $PGO_BUILD_LTO_CFLAGS"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-int foo;
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
-
-else
- PGO_BUILD_LTO_CFLAGS=
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- CFLAGS="$old_CFLAGS"
- if test -n "$PGO_BUILD_LTO_CFLAGS"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: LTO is disabled for the PGO build" >&5
-$as_echo "$as_me: WARNING: LTO is disabled for the PGO build" >&2;}
- fi
- fi
-fi
-
-
-
-
-# Used for setting $lt_cv_objdir
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for objdir" >&5
-$as_echo_n "checking for objdir... " >&6; }
-if ${lt_cv_objdir+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- rm -f .libs 2>/dev/null
-mkdir .libs 2>/dev/null
-if test -d .libs; then
- lt_cv_objdir=.libs
-else
- # MS-DOS does not allow filenames that begin with a dot.
- lt_cv_objdir=_libs
-fi
-rmdir .libs 2>/dev/null
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_objdir" >&5
-$as_echo "$lt_cv_objdir" >&6; }
-objdir=$lt_cv_objdir
-
-
-
-
-
-cat >>confdefs.h <<_ACEOF
-#define LT_OBJDIR "$lt_cv_objdir/"
-_ACEOF
-
-
-
-# Check for GMP, MPFR and MPC
-require_gmp=no
-require_mpc=no
-if test -d ${srcdir}/gcc ; then
- require_gmp=yes
- require_mpc=yes
-fi
-if test -d ${srcdir}/gdb ; then
- if test "x$enable_gdb" != xno; then
- require_gmp=yes
- fi
-fi
-
-gmplibs="-lmpfr -lgmp"
-if test x"$require_mpc" = "xyes" ; then
- gmplibs="-lmpc $gmplibs"
-fi
-gmpinc=
-have_gmp=no
-
-# Specify a location for mpc
-# check for this first so it ends up on the link line before mpfr.
-
-# Check whether --with-mpc was given.
-if test "${with_mpc+set}" = set; then :
- withval=$with_mpc;
-fi
-
-
-# Check whether --with-mpc-include was given.
-if test "${with_mpc_include+set}" = set; then :
- withval=$with_mpc_include;
-fi
-
-
-# Check whether --with-mpc-lib was given.
-if test "${with_mpc_lib+set}" = set; then :
- withval=$with_mpc_lib;
-fi
-
-
-if test "x$with_mpc" != x; then
- gmplibs="-L$with_mpc/lib $gmplibs"
- gmpinc="-I$with_mpc/include $gmpinc"
-fi
-if test "x$with_mpc_include" != x; then
- gmpinc="-I$with_mpc_include $gmpinc"
-fi
-if test "x$with_mpc_lib" != x; then
- gmplibs="-L$with_mpc_lib $gmplibs"
-fi
-if test "x$with_mpc$with_mpc_include$with_mpc_lib" = x && test -d ${srcdir}/mpc; then
- gmplibs='-L$$r/$(HOST_SUBDIR)/mpc/src/'"$lt_cv_objdir $gmplibs"
- gmpinc='-I$$s/mpc/src '"$gmpinc"
- # Do not test the mpc version. Assume that it is sufficient, since
- # it is in the source tree, and the library has not been built yet
- # but it would be included on the link line in the version check below
- # hence making the test fail.
- have_gmp=yes
-fi
-
-# Specify a location for mpfr
-# check for this first so it ends up on the link line before gmp.
-
-# Check whether --with-mpfr was given.
-if test "${with_mpfr+set}" = set; then :
- withval=$with_mpfr;
-fi
-
-
-# Check whether --with-mpfr-include was given.
-if test "${with_mpfr_include+set}" = set; then :
- withval=$with_mpfr_include;
-fi
-
-
-# Check whether --with-mpfr-lib was given.
-if test "${with_mpfr_lib+set}" = set; then :
- withval=$with_mpfr_lib;
-fi
-
-
-if test "x$with_mpfr" != x; then
- gmplibs="-L$with_mpfr/lib $gmplibs"
- gmpinc="-I$with_mpfr/include $gmpinc"
-fi
-if test "x$with_mpfr_include" != x; then
- gmpinc="-I$with_mpfr_include $gmpinc"
-fi
-if test "x$with_mpfr_lib" != x; then
- gmplibs="-L$with_mpfr_lib $gmplibs"
-fi
-if test "x$with_mpfr$with_mpfr_include$with_mpfr_lib" = x && test -d ${srcdir}/mpfr; then
- # MPFR v3.1.0 moved the sources into a src sub-directory.
- if ! test -d ${srcdir}/mpfr/src; then
- as_fn_error $? "Building GCC with MPFR in the source tree is only handled for MPFR 3.1.0+." "$LINENO" 5
- fi
- gmplibs='-L$$r/$(HOST_SUBDIR)/mpfr/src/'"$lt_cv_objdir $gmplibs"
- gmpinc='-I$$r/$(HOST_SUBDIR)/mpfr/src -I$$s/mpfr/src '"$gmpinc"
- extra_mpc_mpfr_configure_flags='--with-mpfr-include=$$s/mpfr/src --with-mpfr-lib=$$r/$(HOST_SUBDIR)/mpfr/src/'"$lt_cv_objdir"
- # Do not test the mpfr version. Assume that it is sufficient, since
- # it is in the source tree, and the library has not been built yet
- # but it would be included on the link line in the version check below
- # hence making the test fail.
- have_gmp=yes
-fi
-
-# Specify a location for gmp
-
-# Check whether --with-gmp was given.
-if test "${with_gmp+set}" = set; then :
- withval=$with_gmp;
-fi
-
-
-# Check whether --with-gmp-include was given.
-if test "${with_gmp_include+set}" = set; then :
- withval=$with_gmp_include;
-fi
-
-
-# Check whether --with-gmp-lib was given.
-if test "${with_gmp_lib+set}" = set; then :
- withval=$with_gmp_lib;
-fi
-
-
-
-if test "x$with_gmp" != x; then
- gmplibs="-L$with_gmp/lib $gmplibs"
- gmpinc="-I$with_gmp/include $gmpinc"
-fi
-if test "x$with_gmp_include" != x; then
- gmpinc="-I$with_gmp_include $gmpinc"
-fi
-if test "x$with_gmp_lib" != x; then
- gmplibs="-L$with_gmp_lib $gmplibs"
-fi
-if test "x$with_gmp$with_gmp_include$with_gmp_lib" = x && test -d ${srcdir}/gmp; then
- gmplibs='-L$$r/$(HOST_SUBDIR)/gmp/'"$lt_cv_objdir $gmplibs"
- gmpinc='-I$$r/$(HOST_SUBDIR)/gmp -I$$s/gmp '"$gmpinc"
- extra_mpfr_configure_flags='--with-gmp-include=$$r/$(HOST_SUBDIR)/gmp --with-gmp-lib=$$r/$(HOST_SUBDIR)/gmp/'"$lt_cv_objdir"
- extra_mpc_gmp_configure_flags='--with-gmp-include=$$r/$(HOST_SUBDIR)/gmp --with-gmp-lib=$$r/$(HOST_SUBDIR)/gmp/'"$lt_cv_objdir"
- extra_isl_gmp_configure_flags='--with-gmp-builddir=$$r/$(HOST_SUBDIR)/gmp'
- # Do not test the gmp version. Assume that it is sufficient, since
- # it is in the source tree, and the library has not been built yet
- # but it would be included on the link line in the version check below
- # hence making the test fail.
- have_gmp=yes
-fi
-
-if test "x$require_gmp" = xyes && test "x$have_gmp" = xno; then
- have_gmp=yes
- saved_CFLAGS="$CFLAGS"
- CFLAGS="$CFLAGS $gmpinc"
- # Check for the recommended and required versions of GMP.
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the correct version of gmp.h" >&5
-$as_echo_n "checking for the correct version of gmp.h... " >&6; }
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include "gmp.h"
-int
-main ()
-{
-
- #define GCC_GMP_VERSION_NUM(a,b,c) (((a) << 16L) | ((b) << 8) | (c))
- #define GCC_GMP_VERSION GCC_GMP_VERSION_NUM(__GNU_MP_VERSION,__GNU_MP_VERSION_MINOR,__GNU_MP_VERSION_PATCHLEVEL)
- #if GCC_GMP_VERSION < GCC_GMP_VERSION_NUM(4,2,3)
- choke me
- #endif
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <gmp.h>
-int
-main ()
-{
-
- #define GCC_GMP_VERSION_NUM(a,b,c) (((a) << 16L) | ((b) << 8) | (c))
- #define GCC_GMP_VERSION GCC_GMP_VERSION_NUM(__GNU_MP_VERSION,__GNU_MP_VERSION_MINOR,__GNU_MP_VERSION_PATCHLEVEL)
- #if GCC_GMP_VERSION < GCC_GMP_VERSION_NUM(4,3,2)
- choke me
- #endif
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: buggy but acceptable" >&5
-$as_echo "buggy but acceptable" >&6; }
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }; have_gmp=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-
- # If we have GMP, check the MPFR version.
- if test x"$have_gmp" = xyes; then
- # Check for the recommended and required versions of MPFR.
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the correct version of mpfr.h" >&5
-$as_echo_n "checking for the correct version of mpfr.h... " >&6; }
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <gmp.h>
- #include <mpfr.h>
-int
-main ()
-{
-
- #if MPFR_VERSION < MPFR_VERSION_NUM(3,1,0)
- choke me
- #endif
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <gmp.h>
- #include <mpfr.h>
-int
-main ()
-{
-
- #if MPFR_VERSION < MPFR_VERSION_NUM(3,1,6)
- choke me
- #endif
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: buggy but acceptable" >&5
-$as_echo "buggy but acceptable" >&6; }
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }; have_gmp=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- fi
-
- # Check for the MPC header version.
- if test "x$require_mpc" = xyes && test x"$have_gmp" = xyes ; then
- # Check for the recommended and required versions of MPC.
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the correct version of mpc.h" >&5
-$as_echo_n "checking for the correct version of mpc.h... " >&6; }
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <mpc.h>
-int
-main ()
-{
-
- #if MPC_VERSION < MPC_VERSION_NUM(0,8,0)
- choke me
- #endif
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <mpc.h>
-int
-main ()
-{
-
- #if MPC_VERSION < MPC_VERSION_NUM(0,8,1)
- choke me
- #endif
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: buggy but acceptable" >&5
-$as_echo "buggy but acceptable" >&6; }
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }; have_gmp=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- fi
-
- # Now check the MPFR library.
- if test x"$have_gmp" = xyes; then
- saved_LIBS="$LIBS"
- LIBS="$LIBS $gmplibs"
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the correct version of the gmp/mpfr libraries" >&5
-$as_echo_n "checking for the correct version of the gmp/mpfr libraries... " >&6; }
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <mpfr.h>
-int
-main ()
-{
-
- mpfr_t n;
- mpfr_t x;
- int t;
- mpfr_init (n);
- mpfr_init (x);
- mpfr_atan2 (n, n, x, MPFR_RNDN);
- mpfr_erfc (n, x, MPFR_RNDN);
- mpfr_subnormalize (x, t, MPFR_RNDN);
- mpfr_clear(n);
- mpfr_clear(x);
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }; have_gmp=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LIBS="$saved_LIBS"
- fi
-
- # Now check the MPC library
- if test "x$require_mpc" = xyes && test x"$have_gmp" = xyes; then
- saved_LIBS="$LIBS"
- LIBS="$LIBS $gmplibs"
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the correct version of the mpc libraries" >&5
-$as_echo_n "checking for the correct version of the mpc libraries... " >&6; }
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <mpc.h>
-int
-main ()
-{
-
- mpc_t c;
- mpc_init2 (c, 53);
- mpc_set_ui_ui (c, 1, 1, MPC_RNDNN);
- mpc_cosh (c, c, MPC_RNDNN);
- mpc_pow (c, c, c, MPC_RNDNN);
- mpc_acosh (c, c, MPC_RNDNN);
- mpc_clear (c);
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }; have_gmp=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LIBS="$saved_LIBS"
- fi
-
- CFLAGS="$saved_CFLAGS"
-
-# The library versions listed in the error message below should match
-# the HARD-minimums enforced above.
- if test x$have_gmp != xyes; then
- if test -d ${srcdir}/gcc ; then
- as_fn_error $? "Building GCC requires GMP 4.2+, MPFR 3.1.0+ and MPC 0.8.0+.
-Try the --with-gmp, --with-mpfr and/or --with-mpc options to specify
-their locations. Source code for these libraries can be found at
-their respective hosting sites as well as at
-https://gcc.gnu.org/pub/gcc/infrastructure/. See also
-http://gcc.gnu.org/install/prerequisites.html for additional info. If
-you obtained GMP, MPFR and/or MPC from a vendor distribution package,
-make sure that you have installed both the libraries and the header
-files. They may be located in separate packages." "$LINENO" 5
- else
- as_fn_error $? "Building GDB requires GMP 4.2+, and MPFR 3.1.0+.
-Try the --with-gmp and/or --with-mpfr options to specify
-their locations. If you obtained GMP and/or MPFR from a vendor
-distribution package, make sure that you have installed both the libraries
-and the header files. They may be located in separate packages." "$LINENO" 5
- fi
- fi
-fi
-
-# Flags needed for both GMP, MPFR and/or MPC.
-
-
-
-
-
-
-
-# Libraries to use for stage1 or when not bootstrapping.
-
-# Check whether --with-stage1-libs was given.
-if test "${with_stage1_libs+set}" = set; then :
- withval=$with_stage1_libs; if test "$withval" = "no" -o "$withval" = "yes"; then
- stage1_libs=
- else
- stage1_libs=$withval
- fi
-else
- stage1_libs=
-fi
-
-
-
-# Whether or not to use -static-libstdc++ and -static-libgcc. The
-# default is yes if gcc is being built; no otherwise. The reason for
-# this default is that gdb is sometimes linked against GNU Source
-# Highlight, which is a shared library that uses C++ exceptions. In
-# this case, -static-libstdc++ will cause crashes.
-
-# Check whether --with-static-standard-libraries was given.
-if test "${with_static_standard_libraries+set}" = set; then :
- withval=$with_static_standard_libraries;
-else
- with_static_standard_libraries=auto
-fi
-
-if test "$with_static_standard_libraries" = auto; then
- with_static_standard_libraries=$have_compiler
-fi
-
-# Linker flags to use for stage1 or when not bootstrapping.
-
-# Check whether --with-stage1-ldflags was given.
-if test "${with_stage1_ldflags+set}" = set; then :
- withval=$with_stage1_ldflags; if test "$withval" = "no" -o "$withval" = "yes"; then
- stage1_ldflags=
- else
- stage1_ldflags=$withval
- fi
-else
- stage1_ldflags=
- # In stage 1, default to linking libstdc++ and libgcc statically with GCC
- # if supported. But if the user explicitly specified the libraries to use,
- # trust that they are doing what they want.
- if test "$with_static_standard_libraries" = yes -a "$stage1_libs" = "" \
- -a "$have_static_libs" = yes; then
- stage1_ldflags="-static-libstdc++ -static-libgcc"
- fi
-fi
-
-
-
-# Libraries to use for stage2 and later builds.
-
-# Check whether --with-boot-libs was given.
-if test "${with_boot_libs+set}" = set; then :
- withval=$with_boot_libs; if test "$withval" = "no" -o "$withval" = "yes"; then
- poststage1_libs=
- else
- poststage1_libs=$withval
- fi
-else
- poststage1_libs=
-fi
-
-
-
-# Linker flags to use for stage2 and later builds.
-
-# Check whether --with-boot-ldflags was given.
-if test "${with_boot_ldflags+set}" = set; then :
- withval=$with_boot_ldflags; if test "$withval" = "no" -o "$withval" = "yes"; then
- poststage1_ldflags=
- else
- poststage1_ldflags=$withval
- fi
-else
- poststage1_ldflags=
- # In stages 2 and 3, default to linking libstdc++ and libgcc
- # statically. But if the user explicitly specified the libraries to
- # use, trust that they are doing what they want.
- if test "$poststage1_libs" = ""; then
- poststage1_ldflags="-static-libstdc++ -static-libgcc"
- fi
-fi
-
-case $target in
- *-darwin2* | *-darwin1[56789]*)
- # For these versions, we default to using embedded rpaths.
- if test "x$enable_darwin_at_rpath" != "xno"; then
- poststage1_ldflags="$poststage1_ldflags -nodefaultrpaths"
- fi
- ;;
- *-darwin*)
- # For these versions, we only use embedded rpaths on demand.
- if test "x$enable_darwin_at_rpath" = "xyes"; then
- poststage1_ldflags="$poststage1_ldflags -nodefaultrpaths"
- fi
- ;;
-esac
-
-
-# GCC GRAPHITE dependency isl.
-# Basic setup is inlined here, actual checks are in config/isl.m4
-
-
-# Check whether --with-isl was given.
-if test "${with_isl+set}" = set; then :
- withval=$with_isl;
-fi
-
-
-# Treat --without-isl as a request to disable
-# GRAPHITE support and skip all following checks.
-if test "x$with_isl" != "xno"; then
- # Check for isl
-
-
-# Check whether --with-isl-include was given.
-if test "${with_isl_include+set}" = set; then :
- withval=$with_isl_include;
-fi
-
-
-# Check whether --with-isl-lib was given.
-if test "${with_isl_lib+set}" = set; then :
- withval=$with_isl_lib;
-fi
-
-
- # Check whether --enable-isl-version-check was given.
-if test "${enable_isl_version_check+set}" = set; then :
- enableval=$enable_isl_version_check; ENABLE_ISL_CHECK=$enableval
-else
- ENABLE_ISL_CHECK=yes
-fi
-
-
- # Initialize isllibs and islinc.
- case $with_isl in
- no)
- isllibs=
- islinc=
- ;;
- "" | yes)
- ;;
- *)
- isllibs="-L$with_isl/lib"
- islinc="-I$with_isl/include"
- ;;
- esac
- if test "x${with_isl_include}" != x ; then
- islinc="-I$with_isl_include"
- fi
- if test "x${with_isl_lib}" != x; then
- isllibs="-L$with_isl_lib"
- fi
- if test "x${islinc}" = x && test "x${isllibs}" = x \
- && test -d ${srcdir}/isl; then
- isllibs='-L$$r/$(HOST_SUBDIR)/isl/'"$lt_cv_objdir"' '
- islinc='-I$$r/$(HOST_SUBDIR)/isl/include -I$$s/isl/include'
- ENABLE_ISL_CHECK=no
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using in-tree isl, disabling version check" >&5
-$as_echo "$as_me: WARNING: using in-tree isl, disabling version check" >&2;}
- fi
-
- isllibs="${isllibs} -lisl"
-
-
-
- if test "${ENABLE_ISL_CHECK}" = yes ; then
- _isl_saved_CFLAGS=$CFLAGS
- _isl_saved_LDFLAGS=$LDFLAGS
- _isl_saved_LIBS=$LIBS
-
- CFLAGS="${_isl_saved_CFLAGS} ${islinc} ${gmpinc}"
- LDFLAGS="${_isl_saved_LDFLAGS} ${isllibs} ${gmplibs}"
- LIBS="${_isl_saved_LIBS} -lisl -lgmp"
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for isl 0.15 or later" >&5
-$as_echo_n "checking for isl 0.15 or later... " >&6; }
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <isl/schedule.h>
-int
-main ()
-{
-isl_options_set_schedule_serialize_sccs (NULL, 0);
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- gcc_cv_isl=yes
-else
- gcc_cv_isl=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_isl" >&5
-$as_echo "$gcc_cv_isl" >&6; }
-
- if test "${gcc_cv_isl}" = no ; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: required isl version is 0.15 or later" >&5
-$as_echo "required isl version is 0.15 or later" >&6; }
- fi
-
- CFLAGS=$_isl_saved_CFLAGS
- LDFLAGS=$_isl_saved_LDFLAGS
- LIBS=$_isl_saved_LIBS
- fi
-
-
-
-
-
-
- if test "x${with_isl}" = xno; then
- graphite_requested=no
- elif test "x${with_isl}" != x \
- || test "x${with_isl_include}" != x \
- || test "x${with_isl_lib}" != x ; then
- graphite_requested=yes
- else
- graphite_requested=no
- fi
-
-
-
- if test "${gcc_cv_isl}" = no ; then
- isllibs=
- islinc=
- fi
-
- if test "${graphite_requested}" = yes \
- && test "x${isllibs}" = x \
- && test "x${islinc}" = x ; then
-
- as_fn_error $? "Unable to find a usable isl. See config.log for details." "$LINENO" 5
- fi
-
-
-fi
-
-# If the isl check failed, disable builds of in-tree variant of isl
-if test "x$with_isl" = xno ||
- test "x$gcc_cv_isl" = xno; then
- noconfigdirs="$noconfigdirs isl"
- islinc=
-fi
-
-
-
-
-# Check for LTO support.
-# Check whether --enable-lto was given.
-if test "${enable_lto+set}" = set; then :
- enableval=$enable_lto; enable_lto=$enableval
-else
- enable_lto=yes; default_enable_lto=yes
-fi
-
-
-
-
-
-target_elf=no
-case $target in
- *-darwin* | *-aix* | *-cygwin* | *-mingw* | *-aout* | *-*coff* | \
- *-msdosdjgpp* | *-vms* | *-wince* | *-*-pe* | \
- alpha*-dec-osf* | *-interix* | hppa[12]*-*-hpux* | \
- nvptx-*-none)
- target_elf=no
- ;;
- *)
- target_elf=yes
- ;;
-esac
-
-if test $target_elf = yes; then :
- # ELF platforms build the lto-plugin always.
- build_lto_plugin=yes
-
-else
- if test x"$default_enable_lto" = x"yes" ; then
- case $target in
- *-apple-darwin[912]* | *-cygwin* | *-mingw* | *djgpp*) ;;
- # On other non-ELF platforms, LTO has yet to be validated.
- *) enable_lto=no ;;
- esac
- else
- # Apart from ELF platforms, only Windows and Darwin support LTO so far.
- # It would also be nice to check the binutils support, but we don't
- # have gcc_GAS_CHECK_FEATURE available here. For now, we'll just
- # warn during gcc/ subconfigure; unless you're bootstrapping with
- # -flto it won't be needed until after installation anyway.
- case $target in
- *-cygwin* | *-mingw* | *-apple-darwin* | *djgpp*) ;;
- *) if test x"$enable_lto" = x"yes"; then
- as_fn_error $? "LTO support is not enabled for this target." "$LINENO" 5
- fi
- ;;
- esac
- fi
- # Among non-ELF, only Windows platforms support the lto-plugin so far.
- # Build it unless LTO was explicitly disabled.
- case $target in
- *-cygwin* | *-mingw*) build_lto_plugin=$enable_lto ;;
- *) ;;
- esac
-
-fi
-
-
-# Check whether --enable-linker-plugin-configure-flags was given.
-if test "${enable_linker_plugin_configure_flags+set}" = set; then :
- enableval=$enable_linker_plugin_configure_flags; extra_linker_plugin_configure_flags=$enableval
-else
- extra_linker_plugin_configure_flags=
-fi
-
-
-# Check whether --enable-linker-plugin-flags was given.
-if test "${enable_linker_plugin_flags+set}" = set; then :
- enableval=$enable_linker_plugin_flags; extra_linker_plugin_flags=$enableval
-else
- extra_linker_plugin_flags=
-fi
-
-
-
-# Handle --enable-host-pie
-# If host PIE executables are the default (or must be forced on) for some host,
-# we must pass that configuration to the gcc directory.
-gcc_host_pie=
-# Check whether --enable-host-pie was given.
-if test "${enable_host_pie+set}" = set; then :
- enableval=$enable_host_pie; host_pie=$enableval
- case $host in
- *-*-darwin2*)
- if test x$host_pie != xyes ; then
- # for Darwin20+ this is required.
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: PIE executables are required for the configured host, host-pie setting ignored." >&5
-$as_echo "$as_me: WARNING: PIE executables are required for the configured host, host-pie setting ignored." >&2;}
- host_pie=yes
- gcc_host_pie=--enable-host-pie
- fi ;;
- *) ;;
- esac
-else
- case $host in
- *-*-darwin2*)
- # Default to PIE (mandatory for aarch64).
- host_pie=yes
- gcc_host_pie=--enable-host-pie
- ;;
- *) host_pie=no ;;
- esac
-fi
-
-
-
-
-
-# Enable --enable-host-shared.
-# Checked early to determine whether jit is an 'all' language
-# Check whether --enable-host-shared was given.
-if test "${enable_host_shared+set}" = set; then :
- enableval=$enable_host_shared; host_shared=$enableval
- case $host in
- x86_64-*-darwin* | aarch64-*-darwin*)
- if test x$host_shared != xyes ; then
- # PIC is the default, and actually cannot be switched off.
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: PIC code is required for the configured host; host-shared setting ignored." >&5
-$as_echo "$as_me: WARNING: PIC code is required for the configured host; host-shared setting ignored." >&2;}
- host_shared=yes
- fi ;;
- *-*-darwin*)
- if test x$host_pie = xyes -a x$host_shared != xyes ; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: PIC code is required for PIE host executables host-shared setting ignored." >&5
-$as_echo "$as_me: WARNING: PIC code is required for PIE host executables host-shared setting ignored." >&2;}
- host_shared=yes
- fi ;;
- *) ;;
- esac
-else
- case $host in
- # 64B x86_64 and Aarch64 Darwin default to PIC.
- x86_64-*-darwin* | aarch64-*-darwin*) host_shared=yes ;;
- # 32B and powerpc64 Darwin must use PIC to link PIE exes.
- *-*-darwin*) host_shared=$host_pie ;;
- *) host_shared=no;;
- esac
-fi
-
-
-
-
-if test x$host_shared = xyes; then
- case $host in
- *-*-darwin*)
- # Since host shared is the default for 64b Darwin, and also enabled for
- # host_pie, ensure that we present the PIE flag when host_pie is active.
- if test x$host_pie = xyes; then
- PICFLAG=-fPIE
- fi
- ;;
- *)
- PICFLAG=-fPIC
- ;;
- esac
-elif test x$host_pie = xyes; then
- PICFLAG=-fPIE
-else
- PICFLAG=
-fi
-
-
-
-# If we are building PIC/PIE host executables, and we are building dependent
-# libs (e.g. GMP) in-tree those libs need to be configured to generate PIC
-# code.
-host_libs_picflag=
-if test "$host_shared" = "yes" -o "$host_pie" = "yes"; then
-host_libs_picflag='--with-pic'
-fi
-
-
-# By default, C and C++ are the only stage 1 languages.
-stage1_languages=,c,
-
-# Target libraries that we bootstrap.
-bootstrap_target_libs=,target-libgcc,
-
-# Figure out what language subdirectories are present.
-# Look if the user specified --enable-languages="..."; if not, use
-# the environment variable $LANGUAGES if defined. $LANGUAGES might
-# go away some day.
-# NB: embedded tabs in this IF block -- do not untabify
-if test -d ${srcdir}/gcc; then
- if test x"${enable_languages+set}" != xset; then
- if test x"${LANGUAGES+set}" = xset; then
- enable_languages="${LANGUAGES}"
- echo configure.ac: warning: setting LANGUAGES is deprecated, use --enable-languages instead 1>&2
- else
- enable_languages=default
- fi
- else
- if test x"${enable_languages}" = x ||
- test x"${enable_languages}" = xyes;
- then
- echo configure.ac: --enable-languages needs at least one language argument 1>&2
- exit 1
- fi
- fi
- enable_languages=`echo "${enable_languages}" | sed -e 's/[ ,][ ,]*/,/g' -e 's/,$//'`
-
- # 'f95' is the old name for the 'fortran' language. We issue a warning
- # and make the substitution.
- case ,${enable_languages}, in
- *,f95,*)
- echo configure.ac: warning: 'f95' as language name is deprecated, use 'fortran' instead 1>&2
- enable_languages=`echo "${enable_languages}" | sed -e 's/f95/fortran/g'`
- ;;
- esac
-
- # If bootstrapping, C++ must be enabled.
- case ",$enable_languages,:$enable_bootstrap" in
- *,c++,*:*) ;;
- *:yes)
- if test -f ${srcdir}/gcc/cp/config-lang.in; then
- enable_languages="${enable_languages},c++"
- else
- as_fn_error $? "bootstrapping requires c++ sources" "$LINENO" 5
- fi
- ;;
- esac
-
- # First scan to see if an enabled language requires some other language.
- # We assume that a given config-lang.in will list all the language
- # front ends it requires, even if some are required indirectly.
- for lang_frag in ${srcdir}/gcc/*/config-lang.in .. ; do
- case ${lang_frag} in
- ..) ;;
- # The odd quoting in the next line works around
- # an apparent bug in bash 1.12 on linux.
- ${srcdir}/gcc/[*]/config-lang.in) ;;
- *)
- # From the config-lang.in, get $language, $lang_requires, and
- # $lang_requires_boot_languages.
- language=
- lang_requires=
- lang_requires_boot_languages=
- # set srcdir during sourcing lang_frag to the gcc dir.
- # Sadly overriding srcdir on the . line doesn't work in plain sh as it
- # polutes this shell
- saved_srcdir=${srcdir}
- srcdir=${srcdir}/gcc . ${lang_frag}
- srcdir=${saved_srcdir}
- for other in ${lang_requires} ${lang_requires_boot_languages}; do
- case ,${enable_languages}, in
- *,$other,*) ;;
- *,default,*) ;;
- *,all,*) ;;
- *,$language,*)
- echo " \`$other' language required by \`$language'; enabling" 1>&2
- enable_languages="${enable_languages},${other}"
- ;;
- esac
- done
- for other in ${lang_requires_boot_languages} ; do
- if test "$other" != "c"; then
- case ,${enable_stage1_languages}, in
- *,$other,*) ;;
- *,default,*) ;;
- *,all,*) ;;
- *)
- case ,${enable_languages}, in
- *,$language,*)
- echo " '$other' language required by '$language' in stage 1; enabling" 1>&2
- enable_stage1_languages="$enable_stage1_languages,${other}"
- ;;
- esac
- ;;
- esac
- fi
- done
- ;;
- esac
- done
-
- new_enable_languages=,c,
-
- # If LTO is enabled, add the LTO front end.
- if test "$enable_lto" = "yes" ; then
- case ,${enable_languages}, in
- *,lto,*) ;;
- *) enable_languages="${enable_languages},lto" ;;
- esac
- if test "${build_lto_plugin}" = "yes" ; then
- configdirs="$configdirs lto-plugin"
- fi
- fi
-
- # If we're building an offloading compiler, add the LTO front end.
- if test x"$enable_as_accelerator_for" != x ; then
- case ,${enable_languages}, in
- *,lto,*) ;;
- *) enable_languages="${enable_languages},lto" ;;
- esac
- fi
-
- missing_languages=`echo ",$enable_languages," | sed -e s/,default,/,/ -e s/,all,/,/ -e s/,c,/,/ `
- potential_languages=,c,
-
- enabled_target_libs=
- disabled_target_libs=
-
- for lang_frag in ${srcdir}/gcc/*/config-lang.in .. ; do
- case ${lang_frag} in
- ..) ;;
- # The odd quoting in the next line works around
- # an apparent bug in bash 1.12 on linux.
- ${srcdir}/gcc/[*]/config-lang.in) ;;
- *)
- # From the config-lang.in, get $language, $target_libs,
- # $lang_dirs, $boot_language, and $build_by_default
- language=
- target_libs=
- lang_dirs=
- subdir_requires=
- boot_language=no
- build_by_default=yes
- # set srcdir during sourcing. See above about save & restore
- saved_srcdir=${srcdir}
- srcdir=${srcdir}/gcc . ${lang_frag}
- srcdir=${saved_srcdir}
- if test x${language} = x; then
- echo "${lang_frag} doesn't set \$language." 1>&2
- exit 1
- fi
-
- if test "$language" = "c++"; then
- boot_language=yes
- fi
-
- add_this_lang=no
- # C is always enabled, so no need to add it again
- if test "$language" != "c"; then
- case ,${enable_languages}, in
- *,${language},*)
- # Language was explicitly selected; include it
- add_this_lang=yes
- ;;
- *,all,*)
- # All languages are enabled
- add_this_lang=all
- ;;
- *,default,*)
- # 'default' was selected, select it if it is a default language
- add_this_lang=${build_by_default}
- ;;
- esac
- fi
-
- # Disable languages that need other directories if these aren't available.
- for i in $subdir_requires; do
- test -f "$srcdir/gcc/$i/config-lang.in" && continue
- case ${add_this_lang} in
- yes)
- # Specifically requested language; tell them.
- as_fn_error $? "The gcc/$i directory contains parts of $language but is missing" "$LINENO" 5
- ;;
- all)
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: The gcc/$i directory contains parts of $language but is missing" >&5
-$as_echo "$as_me: WARNING: The gcc/$i directory contains parts of $language but is missing" >&2;}
- add_this_lang=unsupported
- ;;
- *)
- # Silently disable.
- add_this_lang=unsupported
- ;;
- esac
- done
-
- # Disable Ada if no preexisting GNAT is available.
- case ${add_this_lang}:${language}:${have_gnat} in
- yes:ada:no)
- # Specifically requested language; tell them.
- as_fn_error $? "GNAT is required to build $language" "$LINENO" 5
- ;;
- all:ada:no)
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: GNAT is required to build $language" >&5
-$as_echo "$as_me: WARNING: GNAT is required to build $language" >&2;}
- add_this_lang=unsupported
- ;;
- *:ada:no)
- # Silently disable.
- add_this_lang=unsupported
- ;;
- esac
-
- # Disable D if no preexisting GDC is available.
- case ${add_this_lang}:${language}:${have_gdc} in
- yes:d:no)
- # Specifically requested language; tell them.
- as_fn_error $? "GDC is required to build $language" "$LINENO" 5
- ;;
- all:d:no)
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: GDC is required to build $language" >&5
-$as_echo "$as_me: WARNING: GDC is required to build $language" >&2;}
- add_this_lang=unsupported
- ;;
- *:d:no)
- # Silently disable.
- add_this_lang=unsupported
- ;;
- esac
-
- # Disable jit if -enable-host-shared not specified
- # but not if building for Mingw. All code in Windows
- # is position independent code (PIC).
- case $target in
- *mingw*) ;;
- *)
- case ${add_this_lang}:${language}:${host_shared} in
- yes:jit:no)
- # PR jit/64780: explicitly specify --enable-host-shared
- as_fn_error $? "
-Enabling language \"jit\" requires --enable-host-shared.
-
---enable-host-shared typically slows the rest of the compiler down by
-a few %, so you must explicitly enable it.
-
-If you want to build both the jit and the regular compiler, it is often
-best to do this via two separate configure/builds, in separate
-directories, to avoid imposing the performance cost of
---enable-host-shared on the regular compiler." "$LINENO" 5
- ;;
- all:jit:no)
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --enable-host-shared required to build $language" >&5
-$as_echo "$as_me: WARNING: --enable-host-shared required to build $language" >&2;}
- add_this_lang=unsupported
- ;;
- *:jit:no)
- # Silently disable.
- add_this_lang=unsupported
- ;;
- esac
- ;;
- esac
-
- # Disable a language that is unsupported by the target.
- case "${add_this_lang}: $unsupported_languages " in
- no:*) ;;
- unsupported:*) ;;
- *:*" $language "*)
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: ${language} not supported for this target" >&5
-$as_echo "$as_me: WARNING: ${language} not supported for this target" >&2;}
- add_this_lang=unsupported
- ;;
- esac
-
- case $add_this_lang in
- unsupported)
- # Remove language-dependent dirs.
- disabled_target_libs="$disabled_target_libs $target_libs"
- noconfigdirs="$noconfigdirs $lang_dirs"
- ;;
- no)
- # Remove language-dependent dirs; still show language as supported.
- disabled_target_libs="$disabled_target_libs $target_libs"
- noconfigdirs="$noconfigdirs $lang_dirs"
- potential_languages="${potential_languages}${language},"
- ;;
- all|yes)
- new_enable_languages="${new_enable_languages}${language},"
- potential_languages="${potential_languages}${language},"
- missing_languages=`echo "$missing_languages" | sed "s/,$language,/,/"`
- enabled_target_libs="$enabled_target_libs $target_libs"
- case "${boot_language}:,$enable_stage1_languages," in
- yes:* | *:*,$language,* | *:*,yes, | *:*,all,)
- # Add to (comma-separated) list of stage 1 languages.
- case ",$stage1_languages," in
- *,$language,* | ,yes, | ,all,) ;;
- *) stage1_languages="${stage1_languages}${language}," ;;
- esac
- # We need to bootstrap any supporting libraries.
- bootstrap_target_libs=`echo "${bootstrap_target_libs}${target_libs}," | sed "s/ /,/g"`
- ;;
- esac
- ;;
- esac
- ;;
- esac
- done
-
- # Add target libraries which are only needed for disabled languages
- # to noconfigdirs.
- if test -n "$disabled_target_libs"; then
- for dir in $disabled_target_libs; do
- case " $enabled_target_libs " in
- *" ${dir} "*) ;;
- *) noconfigdirs="$noconfigdirs $dir" ;;
- esac
- done
- fi
-
- # Check whether --enable-stage1-languages was given.
-if test "${enable_stage1_languages+set}" = set; then :
- enableval=$enable_stage1_languages; case ,${enable_stage1_languages}, in
- ,no,|,,)
- # Set it to something that will have no effect in the loop below
- enable_stage1_languages=c ;;
- ,yes,)
- enable_stage1_languages=`echo $new_enable_languages | \
- sed -e "s/^,//" -e "s/,$//" ` ;;
- *,all,*)
- enable_stage1_languages=`echo ,$enable_stage1_languages, | \
- sed -e "s/,all,/$new_enable_languages/" -e "s/^,//" -e "s/,$//" ` ;;
- esac
-
- # Add "good" languages from enable_stage1_languages to stage1_languages,
- # while "bad" languages go in missing_languages. Leave no duplicates.
- for i in `echo $enable_stage1_languages | sed 's/,/ /g' `; do
- case $potential_languages in
- *,$i,*)
- case $stage1_languages in
- *,$i,*) ;;
- *) stage1_languages="$stage1_languages$i," ;;
- esac ;;
- *)
- case $missing_languages in
- *,$i,*) ;;
- *) missing_languages="$missing_languages$i," ;;
- esac ;;
- esac
- done
-fi
-
-
- # Remove leading/trailing commas that were added for simplicity
- potential_languages=`echo "$potential_languages" | sed -e "s/^,//" -e "s/,$//"`
- missing_languages=`echo "$missing_languages" | sed -e "s/^,//" -e "s/,$//"`
- stage1_languages=`echo "$stage1_languages" | sed -e "s/^,//" -e "s/,$//"`
- new_enable_languages=`echo "$new_enable_languages" | sed -e "s/^,//" -e "s/,$//"`
-
- if test "x$missing_languages" != x; then
- as_fn_error $? "
-The following requested languages could not be built: ${missing_languages}
-Supported languages are: ${potential_languages}" "$LINENO" 5
- fi
- if test "x$new_enable_languages" != "x$enable_languages"; then
- echo The following languages will be built: ${new_enable_languages}
- enable_languages="$new_enable_languages"
- fi
-
-
- ac_configure_args=`echo " $ac_configure_args" | sed -e "s/ '--enable-languages=[^ ]*'//g" -e "s/$/ '--enable-languages="$enable_languages"'/" `
-fi
-
-# Handle --disable-<component> generically.
-for dir in $configdirs $build_configdirs $target_configdirs ; do
- dirname=`echo $dir | sed -e s/target-//g -e s/build-//g -e s/-/_/g`
- varname=`echo $dirname | sed -e s/+/_/g`
- if eval test x\${enable_${varname}} "=" xno ; then
- noconfigdirs="$noconfigdirs $dir"
- fi
-done
-
-# Check for Boehm's garbage collector
-# Check whether --enable-objc-gc was given.
-if test "${enable_objc_gc+set}" = set; then :
- enableval=$enable_objc_gc;
-fi
-
-
-# Check whether --with-target-bdw-gc was given.
-if test "${with_target_bdw_gc+set}" = set; then :
- withval=$with_target_bdw_gc;
-fi
-
-
-# Check whether --with-target-bdw-gc-include was given.
-if test "${with_target_bdw_gc_include+set}" = set; then :
- withval=$with_target_bdw_gc_include;
-fi
-
-
-# Check whether --with-target-bdw-gc-lib was given.
-if test "${with_target_bdw_gc_lib+set}" = set; then :
- withval=$with_target_bdw_gc_lib;
-fi
-
-
-case ,${enable_languages},:${enable_objc_gc} in *,objc,*:yes|*,objc,*:auto)
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bdw garbage collector" >&5
-$as_echo_n "checking for bdw garbage collector... " >&6; }
- if test "x$with_target_bdw_gc$with_target_bdw_gc_include$with_target_bdw_gc_lib" = x; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: using bdw-gc in default locations" >&5
-$as_echo "using bdw-gc in default locations" >&6; }
- else
- if test "x$with_target_bdw_gc_include" = x && test "x$with_target_bdw_gc_lib" != x; then
- as_fn_error $? "found --with-target-bdw-gc-lib but --with-target-bdw-gc-include missing" "$LINENO" 5
- elif test "x$with_target_bdw_gc_include" != x && test "x$with_target_bdw_gc_lib" = x; then
- as_fn_error $? "found --with-target-bdw-gc-include but --with-target-bdw-gc-lib missing" "$LINENO" 5
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: using paths configured with --with-target-bdw-gc options" >&5
-$as_echo "using paths configured with --with-target-bdw-gc options" >&6; }
- fi
- fi
-esac
-
-# Disable libitm, libsanitizer, libvtv if we're not building C++
-case ,${enable_languages}, in
- *,c++,*)
- # Disable libitm, libsanitizer if we're not building libstdc++
- case "${noconfigdirs}" in
- *target-libstdc++-v3*)
- noconfigdirs="$noconfigdirs target-libitm target-libsanitizer"
- ;;
- *) ;;
- esac
- ;;
- *)
- noconfigdirs="$noconfigdirs target-libitm target-libsanitizer target-libvtv"
- ;;
-esac
-
-case ,${enable_languages}, in
- *,rust,*)
- case " ${noconfigdirs} " in
- *\ target-libstdc++-v3\ *)
- # Disable target libgrust if we're not building target libstdc++.
- noconfigdirs="$noconfigdirs target-libgrust"
- ;;
- esac
- ;;
-esac
-
-# If gcc/ is not in the source tree then we'll not be building a
-# target compiler, assume in that case we don't want to build any
-# target libraries or tools.
-#
-# This was added primarily for the benefit for binutils-gdb who reuse
-# this configure script, but don't always have target tools available.
-if test ! -d ${srcdir}/gcc; then
- skipdirs="${skipdirs} ${target_configdirs}"
-fi
-
-# Remove the entries in $skipdirs and $noconfigdirs from $configdirs,
-# $build_configdirs and $target_configdirs.
-# If we have the source for $noconfigdirs entries, add them to $notsupp.
-
-notsupp=""
-for dir in . $skipdirs $noconfigdirs ; do
- dirname=`echo $dir | sed -e s/target-//g -e s/build-//g`
- if test $dir != . && echo " ${configdirs} " | grep " ${dir} " >/dev/null 2>&1; then
- configdirs=`echo " ${configdirs} " | sed -e "s/ ${dir} / /"`
- if test -r $srcdir/$dirname/configure ; then
- if echo " ${skipdirs} " | grep " ${dir} " >/dev/null 2>&1; then
- true
- else
- notsupp="$notsupp $dir"
- fi
- fi
- fi
- if test $dir != . && echo " ${build_configdirs} " | grep " ${dir} " >/dev/null 2>&1; then
- build_configdirs=`echo " ${build_configdirs} " | sed -e "s/ ${dir} / /"`
- if test -r $srcdir/$dirname/configure ; then
- if echo " ${skipdirs} " | grep " ${dir} " >/dev/null 2>&1; then
- true
- else
- notsupp="$notsupp $dir"
- fi
- fi
- fi
- if test $dir != . && echo " ${target_configdirs} " | grep " ${dir} " >/dev/null 2>&1; then
- target_configdirs=`echo " ${target_configdirs} " | sed -e "s/ ${dir} / /"`
- if test -r $srcdir/$dirname/configure ; then
- if echo " ${skipdirs} " | grep " ${dir} " >/dev/null 2>&1; then
- true
- else
- notsupp="$notsupp $dir"
- fi
- fi
- fi
-done
-
-# Quietly strip out all directories which aren't configurable in this tree.
-# This relies on all configurable subdirectories being autoconfiscated, which
-# is now the case.
-build_configdirs_all="$build_configdirs"
-build_configdirs=
-for i in ${build_configdirs_all} ; do
- j=`echo $i | sed -e s/build-//g`
- if test -f ${srcdir}/$j/configure ; then
- build_configdirs="${build_configdirs} $i"
- fi
-done
-
-configdirs_all="$configdirs"
-configdirs=
-for i in ${configdirs_all} ; do
- if test -f ${srcdir}/$i/configure ; then
- configdirs="${configdirs} $i"
- fi
-done
-
-target_configdirs_all="$target_configdirs"
-target_configdirs=
-for i in ${target_configdirs_all} ; do
- j=`echo $i | sed -e s/target-//g`
- if test -f ${srcdir}/$j/configure ; then
- target_configdirs="${target_configdirs} $i"
- fi
-done
-
-# libiberty-linker-plugin is special: it doesn't have its own source directory,
-# so we have to add it after the preceding checks.
-if test x"$extra_linker_plugin_flags$extra_linker_plugin_configure_flags" != x
-then
- case " $configdirs " in
- *" libiberty "*)
- # If we can build libiberty, we can also build libiberty-linker-plugin.
- configdirs="$configdirs libiberty-linker-plugin"
- extra_linker_plugin_configure_flags="$extra_linker_plugin_configure_flags \
- --with-libiberty=../libiberty-linker-plugin";;
- *)
- as_fn_error $? "libiberty missing" "$LINENO" 5;;
- esac
-fi
-
-# Sometimes we have special requirements for the host libiberty.
-extra_host_libiberty_configure_flags=
-case " $configdirs " in
- *" lto-plugin "* | *" libcc1 "* | *" gdbserver "*)
- # When these are to be built as shared libraries, the same applies to
- # libiberty.
- extra_host_libiberty_configure_flags=--enable-shared
- ;;
-esac
-
-
-# Sometimes we have special requirements for the host zlib.
-extra_host_zlib_configure_flags=
-case " $configdirs " in
- *" bfd "*)
- # When bfd is to be built as a shared library, the same applies to
- # zlib.
- if test "$enable_shared" = "yes"; then
- extra_host_zlib_configure_flags=--enable-host-shared
- fi
- ;;
-esac
-
-
-# Produce a warning message for the subdirs we can't configure.
-# This isn't especially interesting in the Cygnus tree, but in the individual
-# FSF releases, it's important to let people know when their machine isn't
-# supported by the one or two programs in a package.
-
-if test -n "${notsupp}" && test -z "${norecursion}" ; then
- # If $appdirs is non-empty, at least one of those directories must still
- # be configured, or we error out. (E.g., if the gas release supports a
- # specified target in some subdirs but not the gas subdir, we shouldn't
- # pretend that all is well.)
- if test -n "$appdirs" ; then
- for dir in $appdirs ; do
- if test -r $dir/Makefile.in ; then
- if echo " ${configdirs} " | grep " ${dir} " >/dev/null 2>&1; then
- appdirs=""
- break
- fi
- if echo " ${target_configdirs} " | grep " target-${dir} " >/dev/null 2>&1; then
- appdirs=""
- break
- fi
- fi
- done
- if test -n "$appdirs" ; then
- echo "*** This configuration is not supported by this package." 1>&2
- exit 1
- fi
- fi
- # Okay, some application will build, or we don't care to check. Still
- # notify of subdirs not getting built.
- echo "*** This configuration is not supported in the following subdirectories:" 1>&2
- echo " ${notsupp}" 1>&2
- echo " (Any other directories should still work fine.)" 1>&2
-fi
-
-case "$host" in
- *msdosdjgpp*)
- enable_gdbtk=no ;;
-esac
-
-# To find our prefix, in gcc_cv_tool_prefix.
-
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-
-
- get_gcc_base_ver="cat"
-
-# Check whether --with-gcc-major-version-only was given.
-if test "${with_gcc_major_version_only+set}" = set; then :
- withval=$with_gcc_major_version_only; if test x$with_gcc_major_version_only = xyes ; then
- get_gcc_base_ver="sed -e 's/^\([0-9]*\).*/\1/'"
- fi
-
-fi
-
-
-
-
-
-
-if test "x$exec_prefix" = xNONE; then
- if test "x$prefix" = xNONE; then
- gcc_cv_tool_prefix=$ac_default_prefix
- else
- gcc_cv_tool_prefix=$prefix
- fi
-else
- gcc_cv_tool_prefix=$exec_prefix
-fi
-
-# If there is no compiler in the tree, use the PATH only. In any
-# case, if there is no compiler in the tree nobody should use
-# AS_FOR_TARGET and LD_FOR_TARGET.
-if test x$host = x$build && test -f $srcdir/gcc/BASE-VER; then
- if test x$with_gcc_major_version_only = xyes ; then
- gcc_version=`sed -e 's/^\([0-9]*\).*$/\1/' $srcdir/gcc/BASE-VER`
- else
- gcc_version=`cat $srcdir/gcc/BASE-VER`
- fi
- gcc_cv_tool_dirs="$gcc_cv_tool_prefix/libexec/gcc/$target_noncanonical/$gcc_version$PATH_SEPARATOR"
- gcc_cv_tool_dirs="$gcc_cv_tool_dirs$gcc_cv_tool_prefix/libexec/gcc/$target_noncanonical$PATH_SEPARATOR"
- gcc_cv_tool_dirs="$gcc_cv_tool_dirs/usr/lib/gcc/$target_noncanonical/$gcc_version$PATH_SEPARATOR"
- gcc_cv_tool_dirs="$gcc_cv_tool_dirs/usr/lib/gcc/$target_noncanonical$PATH_SEPARATOR"
- gcc_cv_tool_dirs="$gcc_cv_tool_dirs$gcc_cv_tool_prefix/$target_noncanonical/bin/$target_noncanonical/$gcc_version$PATH_SEPARATOR"
- gcc_cv_tool_dirs="$gcc_cv_tool_dirs$gcc_cv_tool_prefix/$target_noncanonical/bin$PATH_SEPARATOR"
-else
- gcc_cv_tool_dirs=
-fi
-
-if test x$build = x$target && test -n "$md_exec_prefix"; then
- gcc_cv_tool_dirs="$gcc_cv_tool_dirs$md_exec_prefix$PATH_SEPARATOR"
-fi
-
-
-
-copy_dirs=
-
-
-# Check whether --with-build-sysroot was given.
-if test "${with_build_sysroot+set}" = set; then :
- withval=$with_build_sysroot; if test x"$withval" != x ; then
- SYSROOT_CFLAGS_FOR_TARGET="--sysroot=$withval"
- fi
-else
- SYSROOT_CFLAGS_FOR_TARGET=
-fi
-
-
-
-
-# Check whether --with-debug-prefix-map was given.
-if test "${with_debug_prefix_map+set}" = set; then :
- withval=$with_debug_prefix_map; if test x"$withval" != x; then
- DEBUG_PREFIX_CFLAGS_FOR_TARGET=
- for debug_map in $withval; do
- DEBUG_PREFIX_CFLAGS_FOR_TARGET="$DEBUG_PREFIX_CFLAGS_FOR_TARGET -fdebug-prefix-map=$debug_map"
- done
- fi
-else
- DEBUG_PREFIX_CFLAGS_FOR_TARGET=
-fi
-
-
-
-# During gcc bootstrap, if we use some random cc for stage1 then CFLAGS
-# might be empty or "-g". We don't require a C++ compiler, so CXXFLAGS
-# might also be empty (or "-g", if a non-GCC C++ compiler is in the path).
-# We want to ensure that TARGET libraries (which we know are built with
-# gcc) are built with "-O2 -g", so include those options when setting
-# CFLAGS_FOR_TARGET and CXXFLAGS_FOR_TARGET.
-if test "x$CFLAGS_FOR_TARGET" = x; then
- if test "x${is_cross_compiler}" = xyes; then
- CFLAGS_FOR_TARGET="-g -O2"
- else
- CFLAGS_FOR_TARGET=$CFLAGS
- case " $CFLAGS " in
- *" -O2 "*) ;;
- *) CFLAGS_FOR_TARGET="-O2 $CFLAGS_FOR_TARGET" ;;
- esac
- case " $CFLAGS " in
- *" -g "* | *" -g3 "*) ;;
- *) CFLAGS_FOR_TARGET="-g $CFLAGS_FOR_TARGET" ;;
- esac
- fi
-fi
-
-
-if test "x$CXXFLAGS_FOR_TARGET" = x; then
- if test "x${is_cross_compiler}" = xyes; then
- CXXFLAGS_FOR_TARGET="-g -O2"
- else
- CXXFLAGS_FOR_TARGET=$CXXFLAGS
- case " $CXXFLAGS " in
- *" -O2 "*) ;;
- *) CXXFLAGS_FOR_TARGET="-O2 $CXXFLAGS_FOR_TARGET" ;;
- esac
- case " $CXXFLAGS " in
- *" -g "* | *" -g3 "*) ;;
- *) CXXFLAGS_FOR_TARGET="-g $CXXFLAGS_FOR_TARGET" ;;
- esac
- fi
-fi
-
-
-
-
-# Handle --with-headers=XXX. If the value is not "yes", the contents of
-# the named directory are copied to $(tooldir)/sys-include.
-if test x"${with_headers}" != x && test x"${with_headers}" != xno ; then
- if test x${is_cross_compiler} = xno ; then
- echo 1>&2 '***' --with-headers is only supported when cross compiling
- exit 1
- fi
- if test x"${with_headers}" != xyes ; then
- x=${gcc_cv_tool_prefix}
- copy_dirs="${copy_dirs} ${with_headers} $x/${target_noncanonical}/sys-include"
- fi
-fi
-
-# Handle --with-libs=XXX. If the value is not "yes", the contents of
-# the name directories are copied to $(tooldir)/lib. Multiple directories
-# are permitted.
-if test x"${with_libs}" != x && test x"${with_libs}" != xno ; then
- if test x${is_cross_compiler} = xno ; then
- echo 1>&2 '***' --with-libs is only supported when cross compiling
- exit 1
- fi
- if test x"${with_libs}" != xyes ; then
- # Copy the libraries in reverse order, so that files in the first named
- # library override files in subsequent libraries.
- x=${gcc_cv_tool_prefix}
- for l in ${with_libs}; do
- copy_dirs="$l $x/${target_noncanonical}/lib ${copy_dirs}"
- done
- fi
-fi
-
-# Set with_gnu_as, with_gnu_ld, and with_system_zlib as appropriate.
-#
-# This is done by determining whether or not the appropriate directory
-# is available, and by checking whether or not specific configurations
-# have requested that this magic not happen.
-#
-# The command line options always override the explicit settings in
-# configure.ac, and the settings in configure.ac override this magic.
-#
-# If the default for a toolchain is to use GNU as and ld, and you don't
-# want to do that, then you should use the --without-gnu-as and
-# --without-gnu-ld options for the configure script. Similarly, if
-# the default is to use the included zlib and you don't want to do that,
-# you should use the --with-system-zlib option for the configure script.
-
-if test x${use_gnu_as} = x &&
- echo " ${configdirs} " | grep " gas " > /dev/null 2>&1 ; then
- with_gnu_as=yes
- extra_host_args="$extra_host_args --with-gnu-as"
-fi
-
-if test x${use_gnu_ld} = x &&
- echo " ${configdirs} " | egrep " (go)?ld " > /dev/null 2>&1 ; then
- with_gnu_ld=yes
- extra_host_args="$extra_host_args --with-gnu-ld"
-fi
-
-if test x${use_included_zlib} = x &&
- echo " ${configdirs} " | grep " zlib " > /dev/null 2>&1 ; then
- :
-else
- with_system_zlib=yes
- extra_host_args="$extra_host_args --with-system-zlib"
-fi
-
-# If using newlib, add --with-newlib to the extra_host_args so that gcc/configure
-# can detect this case.
-
-if test x${with_newlib} != xno && echo " ${target_configdirs} " | grep " target-newlib " > /dev/null 2>&1 ; then
- with_newlib=yes
- extra_host_args="$extra_host_args --with-newlib"
-fi
-
-# Handle ${copy_dirs}
-set fnord ${copy_dirs}
-shift
-while test $# != 0 ; do
- if test -f $2/COPIED && test x"`cat $2/COPIED`" = x"$1" ; then
- :
- else
- echo Copying $1 to $2
-
- # Use the install script to create the directory and all required
- # parent directories.
- if test -d $2 ; then
- :
- else
- echo >config.temp
- ${srcdir}/install-sh -c -m 644 config.temp $2/COPIED
- fi
-
- # Copy the directory, assuming we have tar.
- # FIXME: Should we use B in the second tar? Not all systems support it.
- (cd $1; tar -cf - .) | (cd $2; tar -xpf -)
-
- # It is the responsibility of the user to correctly adjust all
- # symlinks. If somebody can figure out how to handle them correctly
- # here, feel free to add the code.
-
- echo $1 > $2/COPIED
- fi
- shift; shift
-done
-
-# Determine a target-dependent exec_prefix that the installed
-# gcc will search in. Keep this list sorted by triplet, with
-# the *-*-osname triplets last.
-md_exec_prefix=
-case "${target}" in
- i[34567]86-pc-msdosdjgpp*)
- md_exec_prefix=/dev/env/DJDIR/bin
- ;;
- *-*-hpux* | \
- *-*-nto-qnx* | \
- *-*-solaris2*)
- md_exec_prefix=/usr/ccs/bin
- ;;
-esac
-
-extra_arflags_for_target=
-extra_nmflags_for_target=
-extra_ranlibflags_for_target=
-target_makefile_frag=/dev/null
-case "${target}" in
- spu-*-*)
- target_makefile_frag="config/mt-spu"
- ;;
- loongarch*-*linux* | loongarch*-*gnu*)
- target_makefile_frag="config/mt-loongarch-gnu"
- ;;
- loongarch*-*elf*)
- target_makefile_frag="config/mt-loongarch-elf"
- ;;
- mips*-sde-elf* | mips*-mti-elf* | mips*-img-elf*)
- target_makefile_frag="config/mt-sde"
- ;;
- mipsisa*-*-elfoabi*)
- target_makefile_frag="config/mt-mips-elfoabi"
- ;;
- mips*-*-*linux* | mips*-*-gnu*)
- target_makefile_frag="config/mt-mips-gnu"
- ;;
- nios2-*-elf*)
- target_makefile_frag="config/mt-nios2-elf"
- ;;
- *-*-linux-android*)
- target_makefile_frag="config/mt-android"
- ;;
- *-*-linux* | *-*-gnu* | *-*-k*bsd*-gnu | *-*-kopensolaris*-gnu)
- target_makefile_frag="config/mt-gnu"
- ;;
- *-*-aix4.[3456789]* | *-*-aix[56789].*)
- # nm and ar from AIX 4.3 and above require -X32_64 flag to all ar and nm
- # commands to handle both 32-bit and 64-bit objects. These flags are
- # harmless if we're using GNU nm or ar.
- extra_arflags_for_target=" -X32_64"
- extra_nmflags_for_target=" -B -X32_64"
- ;;
-esac
-
-alphaieee_frag=/dev/null
-case $target in
- alpha*-*-*)
- # This just makes sure to use the -mieee option to build target libs.
- # This should probably be set individually by each library.
- alphaieee_frag="config/mt-alphaieee"
- ;;
-esac
-
-# If --enable-target-optspace always use -Os instead of -O2 to build
-# the target libraries, similarly if it is not specified, use -Os
-# on selected platforms.
-ospace_frag=/dev/null
-case "${enable_target_optspace}:${target}" in
- yes:*)
- ospace_frag="config/mt-ospace"
- ;;
- :d30v-*)
- ospace_frag="config/mt-d30v"
- ;;
- :m32r-* | :d10v-* | :fr30-* | :i?86*-*-elfiamcu)
- ospace_frag="config/mt-ospace"
- ;;
- no:* | :*)
- ;;
- *)
- echo "*** bad value \"${enable_target_optspace}\" for --enable-target-optspace flag; ignored" 1>&2
- ;;
-esac
-
-# Some systems (e.g., one of the i386-aix systems the gas testers are
-# using) don't handle "\$" correctly, so don't use it here.
-tooldir='${exec_prefix}'/${target_noncanonical}
-build_tooldir=${tooldir}
-
-# Create a .gdbinit file which runs the one in srcdir
-# and tells GDB to look there for source files.
-
-if test -r ${srcdir}/.gdbinit ; then
- case ${srcdir} in
- .) ;;
- *) cat > ./.gdbinit <<EOF
-# ${NO_EDIT}
-dir ${srcdir}
-dir .
-source ${srcdir}/.gdbinit
-EOF
- ;;
- esac
-fi
-
-# Make sure that the compiler is able to generate an executable. If it
-# can't, we are probably in trouble. We don't care whether we can run the
-# executable--we might be using a cross compiler--we only care whether it
-# can be created. At this point the main configure script has set CC.
-we_are_ok=no
-echo "int main () { return 0; }" > conftest.c
-${CC} -o conftest ${CFLAGS} ${CPPFLAGS} ${LDFLAGS} conftest.c
-if test $? = 0 ; then
- if test -s conftest || test -s conftest.exe ; then
- we_are_ok=yes
- fi
-fi
-case $we_are_ok in
- no)
- echo 1>&2 "*** The command '${CC} -o conftest ${CFLAGS} ${CPPFLAGS} ${LDFLAGS} conftest.c' failed."
- echo 1>&2 "*** You must set the environment variable CC to a working compiler."
- rm -f conftest*
- exit 1
- ;;
-esac
-rm -f conftest*
-
-# Decide which environment variable is used to find dynamic libraries.
-case "${host}" in
- *-*-hpux*) RPATH_ENVVAR=SHLIB_PATH ;;
- *-*-darwin*) RPATH_ENVVAR=DYLD_LIBRARY_PATH ;;
- *-*-mingw* | *-*-cygwin ) RPATH_ENVVAR=PATH ;;
- *) RPATH_ENVVAR=LD_LIBRARY_PATH ;;
-esac
-
-# On systems where the dynamic library environment variable is PATH,
-# gcc/ will put dynamic libraries into a subdirectory to avoid adding
-# built executables to PATH.
-if test "$RPATH_ENVVAR" = PATH; then
- GCC_SHLIB_SUBDIR=/shlib
-else
- GCC_SHLIB_SUBDIR=
-fi
-
-# Adjust the toplevel makefile according to whether bootstrap was selected.
-case $enable_bootstrap in
- yes)
- bootstrap_suffix=bootstrap
- BUILD_CONFIG=bootstrap-debug
- ;;
- no)
- bootstrap_suffix=no-bootstrap
- BUILD_CONFIG=
- ;;
-esac
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for default BUILD_CONFIG" >&5
-$as_echo_n "checking for default BUILD_CONFIG... " >&6; }
-
-
-# Check whether --with-build-config was given.
-if test "${with_build_config+set}" = set; then :
- withval=$with_build_config; case $with_build_config in
- yes) with_build_config= ;;
- no) with_build_config= BUILD_CONFIG= ;;
- esac
-fi
-
-
-if test "x${with_build_config}" != x; then
- BUILD_CONFIG=$with_build_config
-else
- case $BUILD_CONFIG in
- bootstrap-debug)
- if echo "int f (void) { return 0; }" > conftest.c &&
- ${CC} -c conftest.c &&
- mv conftest.o conftest.o.g0 &&
- ${CC} -c -g conftest.c &&
- mv conftest.o conftest.o.g &&
- ${srcdir}/contrib/compare-debug conftest.o.g0 conftest.o.g > /dev/null 2>&1; then
- :
- else
- BUILD_CONFIG=
- fi
- rm -f conftest.c conftest.o conftest.o.g0 conftest.o.g
- ;;
- esac
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CONFIG" >&5
-$as_echo "$BUILD_CONFIG" >&6; }
-
-
-# Use same top-level configure hooks in libgcc/libstdc++/libvtv.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for --enable-vtable-verify" >&5
-$as_echo_n "checking for --enable-vtable-verify... " >&6; }
-# Check whether --enable-vtable-verify was given.
-if test "${enable_vtable_verify+set}" = set; then :
- enableval=$enable_vtable_verify; case "$enableval" in
- yes) enable_vtable_verify=yes ;;
- no) enable_vtable_verify=no ;;
- *) enable_vtable_verify=no;;
- esac
-else
- enable_vtable_verify=no
-fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_vtable_verify" >&5
-$as_echo "$enable_vtable_verify" >&6; }
-
-# Record target_configdirs and the configure arguments for target and
-# build configuration in Makefile.
-target_configdirs=`echo "${target_configdirs}" | sed -e 's/target-//g'`
-build_configdirs=`echo "${build_configdirs}" | sed -e 's/build-//g'`
-bootstrap_fixincludes=no
-
-# If we are building libgomp, bootstrap it.
-if echo " ${target_configdirs} " | grep " libgomp " > /dev/null 2>&1 ; then
- bootstrap_target_libs=${bootstrap_target_libs}target-libgomp,
-fi
-
-# If we are building libsanitizer and $BUILD_CONFIG contains bootstrap-asan
-# or bootstrap-ubsan, bootstrap it.
-if echo " ${target_configdirs} " | grep " libsanitizer " > /dev/null 2>&1; then
- case "$BUILD_CONFIG" in
- *bootstrap-hwasan* | *bootstrap-asan* | *bootstrap-ubsan* )
- bootstrap_target_libs=${bootstrap_target_libs}target-libsanitizer,
- bootstrap_fixincludes=yes
- ;;
- esac
-fi
-
-# If we are building libvtv and --enable-vtable-verify, bootstrap it.
-if echo " ${target_configdirs} " | grep " libvtv " > /dev/null 2>&1 &&
- test "$enable_vtable_verify" != no; then
- bootstrap_target_libs=${bootstrap_target_libs}target-libvtv,
-fi
-
-# If we are building libatomic and the list of enabled languages includes the
-# D frontend, bootstrap it.
-if echo " ${target_configdirs} " | grep " libatomic " > /dev/null 2>&1; then
- case ,${enable_languages}, in
- *,d,*)
- bootstrap_target_libs=${bootstrap_target_libs}target-libatomic,
- ;;
- esac
-fi
-
-# Determine whether gdb needs tk/tcl or not.
-# Use 'maybe' since enable_gdbtk might be true even if tk isn't available
-# and in that case we want gdb to be built without tk. Ugh!
-# In fact I believe gdb is the *only* package directly dependent on tk,
-# so we should be able to put the 'maybe's in unconditionally and
-# leave out the maybe dependencies when enable_gdbtk is false. I'm not
-# 100% sure that that's safe though.
-
-gdb_tk="maybe-all-tcl maybe-all-tk maybe-all-itcl maybe-all-libgui"
-case "$enable_gdbtk" in
- no)
- GDB_TK="" ;;
- yes)
- GDB_TK="${gdb_tk}" ;;
- *)
- # Only add the dependency on gdbtk when GDBtk is part of the gdb
- # distro. Eventually someone will fix this and move Insight, nee
- # gdbtk to a separate directory.
- if test -d ${srcdir}/gdb/gdbtk ; then
- GDB_TK="${gdb_tk}"
- else
- GDB_TK=""
- fi
- ;;
-esac
-CONFIGURE_GDB_TK=`echo ${GDB_TK} | sed s/-all-/-configure-/g`
-INSTALL_GDB_TK=`echo ${GDB_TK} | sed s/-all-/-install-/g`
-
-# gdb and gdbserver depend on gnulib and gdbsupport, but as nothing
-# else does, only include them if one of these is built. The Makefile
-# provides the ordering, so it's enough here to add to the list.
-case " ${configdirs} " in
- *\ gdb\ *)
- configdirs="${configdirs} gnulib gdbsupport"
- ;;
- *\ gdbserver\ *)
- configdirs="${configdirs} gnulib gdbsupport"
- ;;
- *\ sim\ *)
- configdirs="${configdirs} gnulib"
- ;;
-esac
-
-# Strip out unwanted targets.
-
-# While at that, we remove Makefiles if we were started for recursive
-# configuration, so that the top-level Makefile reconfigures them,
-# like we used to do when configure itself was recursive.
-
-# Loop over modules. We used to use the "$extrasub" feature from Autoconf
-# but now we're fixing up the Makefile ourselves with the additional
-# commands passed to AC_CONFIG_FILES. Use separate variables
-# extrasub-{build,host,target} not because there is any reason to split
-# the substitutions up that way, but only to remain below the limit of
-# 99 commands in a script, for HP-UX sed.
-
-# Do not nest @if/@endif or @unless/@endunless pairs, because
-# configure will not warn you at all.
-
-case "$enable_bootstrap:$ENABLE_GOLD: $configdirs :,$stage1_languages," in
- yes:yes:*\ gold\ *:*,c++,*) ;;
- yes:yes:*\ gold\ *:*)
- as_fn_error $? "in a combined tree, bootstrapping with --enable-gold requires c++ in stage1_languages" "$LINENO" 5
- ;;
-esac
-
-extrasub_build=
-for module in ${build_configdirs} ; do
- if test -z "${no_recursion}" \
- && test -f ${build_subdir}/${module}/Makefile; then
- echo 1>&2 "*** removing ${build_subdir}/${module}/Makefile to force reconfigure"
- rm -f ${build_subdir}/${module}/Makefile
- fi
- extrasub_build="$extrasub_build
-/^@if build-$module\$/d
-/^@endif build-$module\$/d
-/^@unless build-$module\$/,/^@endunless build-$module\$/d
-/^@if build-$module-$bootstrap_suffix\$/d
-/^@endif build-$module-$bootstrap_suffix\$/d
-/^@unless build-$module-$bootstrap_suffix\$/,/^@endunless build-$module-$bootstrap_suffix\$/d"
-done
-extrasub_host=
-for module in ${configdirs} ; do
- if test -z "${no_recursion}"; then
- for file in stage*-${module}/Makefile prev-${module}/Makefile ${module}/Makefile; do
- if test -f ${file}; then
- echo 1>&2 "*** removing ${file} to force reconfigure"
- rm -f ${file}
- fi
- done
- fi
- case ${module},${bootstrap_fixincludes} in
- fixincludes,no) host_bootstrap_suffix=no-bootstrap ;;
- *) host_bootstrap_suffix=$bootstrap_suffix ;;
- esac
- extrasub_host="$extrasub_host
-/^@if $module\$/d
-/^@endif $module\$/d
-/^@unless $module\$/,/^@endunless $module\$/d
-/^@if $module-$host_bootstrap_suffix\$/d
-/^@endif $module-$host_bootstrap_suffix\$/d
-/^@unless $module-$host_bootstrap_suffix\$/,/^@endunless $module-$host_bootstrap_suffix\$/d"
-done
-extrasub_target=
-for module in ${target_configdirs} ; do
- if test -z "${no_recursion}" \
- && test -f ${target_subdir}/${module}/Makefile; then
- echo 1>&2 "*** removing ${target_subdir}/${module}/Makefile to force reconfigure"
- rm -f ${target_subdir}/${module}/Makefile
- fi
-
- # We only bootstrap target libraries listed in bootstrap_target_libs.
- case $bootstrap_target_libs in
- *,target-$module,*) target_bootstrap_suffix=$bootstrap_suffix ;;
- *) target_bootstrap_suffix=no-bootstrap ;;
- esac
-
- extrasub_target="$extrasub_target
-/^@if target-$module\$/d
-/^@endif target-$module\$/d
-/^@unless target-$module\$/,/^@endunless target-$module\$/d
-/^@if target-$module-$target_bootstrap_suffix\$/d
-/^@endif target-$module-$target_bootstrap_suffix\$/d
-/^@unless target-$module-$target_bootstrap_suffix\$/,/^@endunless target-$module-$target_bootstrap_suffix\$/d"
-done
-
-# Do the final fixup along with target modules.
-extrasub_target="$extrasub_target
-/^@if /,/^@endif /d
-/^@unless /d
-/^@endunless /d"
-
-if test "$enable_pgo_build" != "no"; then
- extrasub_build="$extrasub_build
-/^@if pgo-build\$/d
-/^@endif pgo-build\$/d"
-fi
-
-# Create the serialization dependencies. This uses a temporary file.
-
-# Check whether --enable-serial-configure was given.
-if test "${enable_serial_configure+set}" = set; then :
- enableval=$enable_serial_configure;
-fi
-
-
-case ${enable_serial_configure} in
- yes)
- enable_serial_build_configure=yes
- enable_serial_host_configure=yes
- enable_serial_target_configure=yes
- ;;
-esac
-
-# These force 'configure's to be done one at a time, to avoid problems
-# with contention over a shared config.cache.
-rm -f serdep.tmp
-if test "x${enable_serial_build_configure}" = xyes || test "x${enable_serial_host_configure}" = xyes || test "x${enable_serial_target_configure}" = xyes; then
-echo '# serdep.tmp' > serdep.tmp
-fi
-olditem=
-test "x${enable_serial_build_configure}" = xyes &&
-for item in ${build_configdirs} ; do
- case ${olditem} in
- "") ;;
- *) echo "configure-build-${item}: configure-build-${olditem}" >> serdep.tmp ;;
- esac
- olditem=${item}
-done
-olditem=
-test "x${enable_serial_host_configure}" = xyes &&
-for item in ${configdirs} ; do
- case ${olditem} in
- "") ;;
- *) echo "configure-${item}: configure-${olditem}" >> serdep.tmp ;;
- esac
- olditem=${item}
-done
-olditem=
-test "x${enable_serial_target_configure}" = xyes &&
-for item in ${target_configdirs} ; do
- case ${olditem} in
- "") ;;
- *) echo "configure-target-${item}: configure-target-${olditem}" >> serdep.tmp ;;
- esac
- olditem=${item}
-done
-serialization_dependencies=serdep.tmp
-
-
-# Base args. Strip norecursion, cache-file, srcdir, host, build,
-# target, nonopt, and variable assignments. These are the ones we
-# might not want to pass down to subconfigures. The exception being
-# --cache-file=/dev/null, which is used to turn off the use of cache
-# files altogether, and which should be passed on to subconfigures.
-# Also strip program-prefix, program-suffix, and program-transform-name,
-# so that we can pass down a consistent program-transform-name.
-hbaseargs=
-bbaseargs=
-tbaseargs=
-keep_next=no
-skip_next=no
-eval "set -- $ac_configure_args"
-for ac_arg
-do
- if test X"$skip_next" = X"yes"; then
- skip_next=no
- continue
- fi
- if test X"$keep_next" = X"yes"; then
- case $ac_arg in
- *\'*)
- ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
- esac
- hbaseargs="$hbaseargs '$ac_arg'"
- bbaseargs="$bbaseargs '$ac_arg'"
- tbaseargs="$tbaseargs '$ac_arg'"
- keep_next=no
- continue
- fi
-
- # Handle separated arguments. Based on the logic generated by
- # autoconf 2.59.
- case $ac_arg in
- *=* | --config-cache | -C | -disable-* | --disable-* \
- | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
- | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
- | -with-* | --with-* | -without-* | --without-* | --x)
- separate_arg=no
- ;;
- -*)
- separate_arg=yes
- ;;
- *)
- separate_arg=no
- ;;
- esac
-
- skip_targ=no
- skip_barg=no
- case $ac_arg in
-
- --with-* | --without-*)
- libopt=`echo "$ac_arg" | sed -e 's,^--[^-_]*[-_],,' -e 's,=.*$,,'`
-
- case $libopt in
- *[-_]include)
- lib=`echo "$libopt" | sed 's,[-_]include$,,'`
- ;;
- *[-_]lib)
- lib=`echo "$libopt" | sed 's,[-_]lib$,,'`
- ;;
- *[-_]prefix)
- lib=`echo "$libopt" | sed 's,[-_]prefix$,,'`
- ;;
- *[-_]type)
- lib=`echo "$libopt" | sed 's,[-_]type$,,'`
- ;;
- *)
- lib=$libopt
- ;;
- esac
-
-
- case $lib in
- mpc | mpfr | gmp | isl)
- # If we're processing --with-$lib, --with-$lib-include or
- # --with-$lib-lib, for one of the libs above, and target is
- # different from host, don't pass the current argument to any
- # target library's configure.
- if test x$is_cross_compiler = xyes; then
- skip_targ=yes
- fi
- ;;
- libintl | libiconv)
- # We don't want libintl (and co.) in anything but the host arguments.
- skip_targ=yes
- skip_barg=yes
- ;;
- esac
- ;;
- esac
-
- case "$ac_arg" in
- --cache-file=/dev/null | \
- -cache-file=/dev/null )
- # Handled here to avoid the test to skip args below.
- hbaseargs="$hbaseargs '$ac_arg'"
- bbaseargs="$bbaseargs '$ac_arg'"
- tbaseargs="$tbaseargs '$ac_arg'"
- # Assert: $separate_arg should always be no.
- keep_next=$separate_arg
- ;;
- --no*)
- continue
- ;;
- --c* | \
- --sr* | \
- --ho* | \
- --bu* | \
- --t* | \
- --program-* | \
- -cache_file* | \
- -srcdir* | \
- -host* | \
- -build* | \
- -target* | \
- -program-prefix* | \
- -program-suffix* | \
- -program-transform-name* )
- skip_next=$separate_arg
- continue
- ;;
- -*)
- # An option. Add it.
- case $ac_arg in
- *\'*)
- ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
- esac
- hbaseargs="$hbaseargs '$ac_arg'"
- if test X"$skip_barg" = Xno; then
- bbaseargs="$bbaseargs '$ac_arg'"
- fi
- if test X"$skip_targ" = Xno; then
- tbaseargs="$tbaseargs '$ac_arg'"
- fi
- keep_next=$separate_arg
- ;;
- *)
- # Either a variable assignment, or a nonopt (triplet). Don't
- # pass it down; let the Makefile handle this.
- continue
- ;;
- esac
-done
-# Remove the initial space we just introduced and, as these will be
-# expanded by make, quote '$'.
-hbaseargs=`echo "x$hbaseargs" | sed -e 's/^x *//' -e 's,\\$,$$,g'`
-bbaseargs=`echo "x$bbaseargs" | sed -e 's/^x *//' -e 's,\\$,$$,g'`
-
-# Add in --program-transform-name, after --program-prefix and
-# --program-suffix have been applied to it. Autoconf has already
-# doubled dollar signs and backslashes in program_transform_name; we want
-# the backslashes un-doubled, and then the entire thing wrapped in single
-# quotes, because this will be expanded first by make and then by the shell.
-# Also, because we want to override the logic in subdir configure scripts to
-# choose program_transform_name, replace any s,x,x, with s,y,y,.
-sed -e "s,\\\\\\\\,\\\\,g; s,','\\\\'',g; s/s,x,x,/s,y,y,/" <<EOF_SED > conftestsed.out
-${program_transform_name}
-EOF_SED
-gcc_transform_name=`cat conftestsed.out`
-rm -f conftestsed.out
-hbaseargs="$hbaseargs --program-transform-name='${gcc_transform_name}'"
-bbaseargs="$bbaseargs --program-transform-name='${gcc_transform_name}'"
-tbaseargs="$tbaseargs --program-transform-name='${gcc_transform_name}'"
-if test "$silent" = yes; then
- bbaseargs="$bbaseargs --silent"
- hbaseargs="$hbaseargs --silent"
- tbaseargs="$tbaseargs --silent"
-fi
-
-bbaseargs="$bbaseargs --disable-option-checking"
-hbaseargs="$hbaseargs --disable-option-checking"
-tbaseargs="$tbaseargs --disable-option-checking"
-
-if test "$enable_year2038" = no; then
- bbaseargs="$bbaseargs --disable-year2038"
- hbaseargs="$hbaseargs --disable-year2038"
- tbaseargs="$tbaseargs --disable-year2038"
-fi
-
-# Record and document user additions to sub configure arguments.
-
-
-
-
-# For the build-side libraries, we just need to pretend we're native,
-# and not use the same cache file. Multilibs are neither needed nor
-# desired. We can't even use the same cache file for all build-side
-# libraries, as they're compiled differently; some with C, some with
-# C++ or with different feature-enabling options.
-build_configargs="$build_configargs --cache-file=./config.cache ${bbaseargs}"
-
-# For host modules, accept cache file option, or specification as blank.
-case "${cache_file}" in
-"") # empty
- cache_file_option="" ;;
-/* | [A-Za-z]:[\\/]* ) # absolute path
- cache_file_option="--cache-file=${cache_file}" ;;
-*) # relative path
- cache_file_option="--cache-file=../${cache_file}" ;;
-esac
-
-# Host dirs don't like to share a cache file either, horribly enough.
-# This seems to be due to autoconf 2.5x stupidity.
-host_configargs="$host_configargs --cache-file=./config.cache ${extra_host_args} ${hbaseargs}"
-
-target_configargs="$target_configargs ${tbaseargs}"
-
-# Passing a --with-cross-host argument lets the target libraries know
-# whether they are being built with a cross-compiler or being built
-# native. However, it would be better to use other mechanisms to make the
-# sorts of decisions they want to make on this basis. Please consider
-# this option to be deprecated. FIXME.
-if test x${is_cross_compiler} = xyes ; then
- target_configargs="--with-cross-host=${host_noncanonical} ${target_configargs}"
-fi
-
-# Special user-friendly check for native x86_64-linux build, if
-# multilib is not explicitly enabled.
-case "$target:$have_compiler:$host:$target:$enable_multilib" in
- x86_64-*linux*:yes:$build:$build:)
- # Make sure we have a development environment that handles 32-bit
- dev64=no
- echo "int main () { return 0; }" > conftest.c
- ${CC} -m32 -o conftest ${CFLAGS} ${CPPFLAGS} ${LDFLAGS} conftest.c
- if test $? = 0 ; then
- if test -s conftest || test -s conftest.exe ; then
- dev64=yes
- fi
- fi
- rm -f conftest*
- if test x${dev64} != xyes ; then
- as_fn_error $? "I suspect your system does not have 32-bit development libraries (libc and headers). If you have them, rerun configure with --enable-multilib. If you do not have them, and want to build a 64-bit-only compiler, rerun configure with --disable-multilib." "$LINENO" 5
- fi
- ;;
-esac
-
-# Default to --enable-multilib.
-if test x${enable_multilib} = x ; then
- target_configargs="--enable-multilib ${target_configargs}"
-fi
-
-# Pass --with-newlib if appropriate. Note that target_configdirs has
-# changed from the earlier setting of with_newlib.
-if test x${with_newlib} != xno && echo " ${target_configdirs} " | grep " newlib " > /dev/null 2>&1 && test -d ${srcdir}/newlib ; then
- target_configargs="--with-newlib ${target_configargs}"
-fi
-
-# Different target subdirs use different values of certain variables
-# (notably CXX). Worse, multilibs use *lots* of different values.
-# Worse yet, autoconf 2.5x makes some of these 'precious', meaning that
-# it doesn't automatically accept command-line overrides of them.
-# This means it's not safe for target subdirs to share a cache file,
-# which is disgusting, but there you have it. Hopefully this can be
-# fixed in future. It's still worthwhile to use a cache file for each
-# directory. I think.
-
-# Pass the appropriate --build, --host, --target and --cache-file arguments.
-# We need to pass --target, as newer autoconf's requires consistency
-# for target_alias and gcc doesn't manage it consistently.
-target_configargs="--cache-file=./config.cache ${target_configargs}"
-
-FLAGS_FOR_TARGET=
-case " $target_configdirs " in
- *" newlib "*)
- case " $target_configargs " in
- *" --with-newlib "*)
- case "$target" in
- *-cygwin*)
- FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -L$$r/$(TARGET_SUBDIR)/winsup/cygwin -isystem $$s/winsup/cygwin/include'
- ;;
- esac
-
- # If we're not building GCC, don't discard standard headers.
- if test -d ${srcdir}/gcc; then
- FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -nostdinc'
-
- if test "${build}" != "${host}"; then
- # On Canadian crosses, CC_FOR_TARGET will have already been set
- # by `configure', so we won't have an opportunity to add -Bgcc/
- # to it. This is right: we don't want to search that directory
- # for binaries, but we want the header files in there, so add
- # them explicitly.
- FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -isystem $$r/$(HOST_SUBDIR)/gcc/include -isystem $$r/$(HOST_SUBDIR)/gcc/include-fixed'
-
- # Someone might think of using the pre-installed headers on
- # Canadian crosses, in case the installed compiler is not fully
- # compatible with the compiler being built. In this case, it
- # would be better to flag an error than risking having
- # incompatible object files being constructed. We can't
- # guarantee that an error will be flagged, but let's hope the
- # compiler will do it, when presented with incompatible header
- # files.
- fi
- fi
-
- case "${target}-${is_cross_compiler}" in
- i[3456789]86-*-linux*-no)
- # Here host == target, so we don't need to build gcc,
- # so we don't want to discard standard headers.
- FLAGS_FOR_TARGET=`echo " $FLAGS_FOR_TARGET " | sed -e 's/ -nostdinc / /'`
- ;;
- *)
- # If we're building newlib, use its generic headers last, but search
- # for any libc-related directories first (so make it the last -B
- # switch).
- FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -B$$r/$(TARGET_SUBDIR)/newlib/ -isystem $$r/$(TARGET_SUBDIR)/newlib/targ-include -isystem $$s/newlib/libc/include'
-
- # If we're building libgloss, find the startup file, simulator library
- # and linker script.
- case " $target_configdirs " in
- *" libgloss "*)
- # Look for startup file, simulator library and maybe linker script.
- FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -B$$r/$(TARGET_SUBDIR)/libgloss/'"$libgloss_dir"
- # Look for libnosys.a in case the target needs it.
- FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -L$$r/$(TARGET_SUBDIR)/libgloss/libnosys'
- # Most targets have the linker script in the source directory.
- FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -L$$s/libgloss/'"$libgloss_dir"
- ;;
- esac
- ;;
- esac
- ;;
- esac
- ;;
-esac
-
-case "$target" in
- x86_64-*mingw* | *-w64-mingw*)
- # MinGW-w64 does not use newlib, nor does it use winsup. It may,
- # however, use a symlink named 'mingw' in ${prefix} .
- FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -L${prefix}/${target}/lib -L${prefix}/mingw/lib -isystem ${prefix}/${target}/include -isystem ${prefix}/mingw/include'
- ;;
- *-mingw*)
- # MinGW can't be handled as Cygwin above since it does not use newlib.
- FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -L$$r/$(TARGET_SUBDIR)/winsup/mingw -L$$r/$(TARGET_SUBDIR)/winsup/w32api/lib -isystem $$s/winsup/mingw/include -isystem $$s/winsup/w32api/include'
- ;;
-esac
-
-# Allow the user to override the flags for
-# our build compiler if desired.
-if test x"${build}" = x"${host}" ; then
- CFLAGS_FOR_BUILD=${CFLAGS_FOR_BUILD-${CFLAGS}}
- CPPFLAGS_FOR_BUILD=${CPPFLAGS_FOR_BUILD-${CPPFLAGS}}
- CXXFLAGS_FOR_BUILD=${CXXFLAGS_FOR_BUILD-${CXXFLAGS}}
- LDFLAGS_FOR_BUILD=${LDFLAGS_FOR_BUILD-${LDFLAGS}}
-fi
-
-# On Canadian crosses, we'll be searching the right directories for
-# the previously-installed cross compiler, so don't bother to add
-# flags for directories within the install tree of the compiler
-# being built; programs in there won't even run.
-if test "${build}" = "${host}" && test -d ${srcdir}/gcc; then
- # Search for pre-installed headers if nothing else fits.
- FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -B$(build_tooldir)/bin/ -B$(build_tooldir)/lib/ -isystem $(build_tooldir)/include -isystem $(build_tooldir)/sys-include'
-fi
-
-if test "x${use_gnu_ld}" = x &&
- echo " ${configdirs} " | grep " ld " > /dev/null ; then
- # Arrange for us to find uninstalled linker scripts.
- FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -L$$r/$(HOST_SUBDIR)/ld'
-fi
-
-# Search for other target-specific linker scripts and such.
-case "${target}" in
- mep*)
- FLAGS_FOR_TARGET="$FLAGS_FOR_TARGET -mlibrary"
- ;;
- # The VxWorks support for shared libraries is getting in
- # incrementally. Make sure it doesn't get activated implicitly:
- *vxworks*)
- if test "${enable_shared-unset}" = unset ; then
- enable_shared=no
- # So the build of libraries knows ...
- target_configargs="${target_configargs} --disable-shared"
- # So gcc knows ...
- host_configargs="${host_configargs} --disable-shared"
- fi
- ;;
-esac
-
-# Makefile fragments.
-for frag in host_makefile_frag target_makefile_frag alphaieee_frag ospace_frag;
-do
- eval fragval=\$$frag
- if test $fragval != /dev/null; then
- eval $frag=${srcdir}/$fragval
- fi
-done
-
-
-
-
-
-# Miscellanea: directories, flags, etc.
-
-
-
-
-
-
-
-
-# Build module lists & subconfigure args.
-
-
-
-# Host module lists & subconfigure args.
-
-
-
-
-# Target module lists & subconfigure args.
-
-
-
-# Build tools.
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-# Generate default definitions for YACC, M4, LEX and other programs that run
-# on the build machine. These are used if the Makefile can't locate these
-# programs in objdir.
-MISSING=`cd $ac_aux_dir && ${PWDCMD-pwd}`/missing
-
-for ac_prog in 'bison -y' byacc yacc
-do
- # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_YACC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$YACC"; then
- ac_cv_prog_YACC="$YACC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_YACC="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-YACC=$ac_cv_prog_YACC
-if test -n "$YACC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $YACC" >&5
-$as_echo "$YACC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$YACC" && break
-done
-test -n "$YACC" || YACC="$MISSING bison -y"
-
-case " $build_configdirs " in
- *" bison "*) YACC='$$r/$(BUILD_SUBDIR)/bison/tests/bison -y' ;;
-esac
-
-for ac_prog in bison
-do
- # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_BISON+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$BISON"; then
- ac_cv_prog_BISON="$BISON" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_BISON="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-BISON=$ac_cv_prog_BISON
-if test -n "$BISON"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BISON" >&5
-$as_echo "$BISON" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$BISON" && break
-done
-test -n "$BISON" || BISON="$MISSING bison"
-
-case " $build_configdirs " in
- *" bison "*) BISON='$$r/$(BUILD_SUBDIR)/bison/tests/bison' ;;
-esac
-
-for ac_prog in gm4 gnum4 m4
-do
- # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_M4+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$M4"; then
- ac_cv_prog_M4="$M4" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_M4="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-M4=$ac_cv_prog_M4
-if test -n "$M4"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $M4" >&5
-$as_echo "$M4" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$M4" && break
-done
-test -n "$M4" || M4="$MISSING m4"
-
-case " $build_configdirs " in
- *" m4 "*) M4='$$r/$(BUILD_SUBDIR)/m4/m4' ;;
-esac
-
-for ac_prog in flex lex
-do
- # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_LEX+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$LEX"; then
- ac_cv_prog_LEX="$LEX" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_LEX="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-LEX=$ac_cv_prog_LEX
-if test -n "$LEX"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LEX" >&5
-$as_echo "$LEX" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$LEX" && break
-done
-test -n "$LEX" || LEX="$MISSING flex"
-
-case " $build_configdirs " in
- *" flex "*) LEX='$$r/$(BUILD_SUBDIR)/flex/flex' ;;
- *" lex "*) LEX='$$r/$(BUILD_SUBDIR)/lex/lex' ;;
-esac
-
-for ac_prog in flex
-do
- # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_FLEX+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$FLEX"; then
- ac_cv_prog_FLEX="$FLEX" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_FLEX="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-FLEX=$ac_cv_prog_FLEX
-if test -n "$FLEX"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FLEX" >&5
-$as_echo "$FLEX" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$FLEX" && break
-done
-test -n "$FLEX" || FLEX="$MISSING flex"
-
-case " $build_configdirs " in
- *" flex "*) FLEX='$$r/$(BUILD_SUBDIR)/flex/flex' ;;
-esac
-
-for ac_prog in makeinfo
-do
- # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_MAKEINFO+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$MAKEINFO"; then
- ac_cv_prog_MAKEINFO="$MAKEINFO" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_MAKEINFO="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-MAKEINFO=$ac_cv_prog_MAKEINFO
-if test -n "$MAKEINFO"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAKEINFO" >&5
-$as_echo "$MAKEINFO" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$MAKEINFO" && break
-done
-test -n "$MAKEINFO" || MAKEINFO="$MISSING makeinfo"
-
-case " $build_configdirs " in
- *" texinfo "*) MAKEINFO='$$r/$(BUILD_SUBDIR)/texinfo/makeinfo/makeinfo' ;;
- *)
-
- # For an installed makeinfo, we require it to be from texinfo 4.7 or
- # higher, else we use the "missing" dummy.
- if ${MAKEINFO} --version \
- | egrep 'texinfo[^0-9]*(4\.([7-9]|[1-9][0-9])|[5-9]|[1-9][0-9])' >/dev/null 2>&1; then
- :
- else
- MAKEINFO="$MISSING makeinfo"
- fi
- ;;
-
-esac
-
-# FIXME: expect and dejagnu may become build tools?
-
-for ac_prog in expect
-do
- # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_EXPECT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$EXPECT"; then
- ac_cv_prog_EXPECT="$EXPECT" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_EXPECT="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-EXPECT=$ac_cv_prog_EXPECT
-if test -n "$EXPECT"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXPECT" >&5
-$as_echo "$EXPECT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$EXPECT" && break
-done
-test -n "$EXPECT" || EXPECT="expect"
-
-case " $configdirs " in
- *" expect "*)
- test $host = $build && EXPECT='$$r/$(HOST_SUBDIR)/expect/expect'
- ;;
-esac
-
-for ac_prog in runtest
-do
- # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_RUNTEST+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$RUNTEST"; then
- ac_cv_prog_RUNTEST="$RUNTEST" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_RUNTEST="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-RUNTEST=$ac_cv_prog_RUNTEST
-if test -n "$RUNTEST"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RUNTEST" >&5
-$as_echo "$RUNTEST" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$RUNTEST" && break
-done
-test -n "$RUNTEST" || RUNTEST="runtest"
-
-case " $configdirs " in
- *" dejagnu "*)
- test $host = $build && RUNTEST='$$s/$(HOST_SUBDIR)/dejagnu/runtest'
- ;;
-esac
-
-
-# Host tools.
-ncn_tool_prefix=
-test -n "$host_alias" && ncn_tool_prefix=$host_alias-
-ncn_target_tool_prefix=
-test -n "$target_alias" && ncn_target_tool_prefix=$target_alias-
-
-
-
-if test -n "$AR"; then
- ac_cv_prog_AR=$AR
-elif test -n "$ac_cv_prog_AR"; then
- AR=$ac_cv_prog_AR
-fi
-
-if test -n "$ac_cv_prog_AR"; then
- for ncn_progname in ar; do
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_AR+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$AR"; then
- ac_cv_prog_AR="$AR" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_AR="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-AR=$ac_cv_prog_AR
-if test -n "$AR"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
-$as_echo "$AR" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- done
-fi
-
-for ncn_progname in ar; do
- if test -n "$ncn_tool_prefix"; then
- # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_AR+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$AR"; then
- ac_cv_prog_AR="$AR" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_AR="${ncn_tool_prefix}${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-AR=$ac_cv_prog_AR
-if test -n "$AR"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
-$as_echo "$AR" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- if test -z "$ac_cv_prog_AR" && test $build = $host ; then
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_AR+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$AR"; then
- ac_cv_prog_AR="$AR" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_AR="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-AR=$ac_cv_prog_AR
-if test -n "$AR"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
-$as_echo "$AR" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- test -n "$ac_cv_prog_AR" && break
-done
-
-if test -z "$ac_cv_prog_AR" ; then
- set dummy ar
- if test $build = $host ; then
- AR="$2"
- else
- AR="${ncn_tool_prefix}$2"
- fi
-fi
-
-
-
-if test -n "$AS"; then
- ac_cv_prog_AS=$AS
-elif test -n "$ac_cv_prog_AS"; then
- AS=$ac_cv_prog_AS
-fi
-
-if test -n "$ac_cv_prog_AS"; then
- for ncn_progname in as; do
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_AS+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$AS"; then
- ac_cv_prog_AS="$AS" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_AS="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-AS=$ac_cv_prog_AS
-if test -n "$AS"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5
-$as_echo "$AS" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- done
-fi
-
-for ncn_progname in as; do
- if test -n "$ncn_tool_prefix"; then
- # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_AS+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$AS"; then
- ac_cv_prog_AS="$AS" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_AS="${ncn_tool_prefix}${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-AS=$ac_cv_prog_AS
-if test -n "$AS"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5
-$as_echo "$AS" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- if test -z "$ac_cv_prog_AS" && test $build = $host ; then
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_AS+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$AS"; then
- ac_cv_prog_AS="$AS" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_AS="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-AS=$ac_cv_prog_AS
-if test -n "$AS"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5
-$as_echo "$AS" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- test -n "$ac_cv_prog_AS" && break
-done
-
-if test -z "$ac_cv_prog_AS" ; then
- set dummy as
- if test $build = $host ; then
- AS="$2"
- else
- AS="${ncn_tool_prefix}$2"
- fi
-fi
-
-
-
-if test -n "$DLLTOOL"; then
- ac_cv_prog_DLLTOOL=$DLLTOOL
-elif test -n "$ac_cv_prog_DLLTOOL"; then
- DLLTOOL=$ac_cv_prog_DLLTOOL
-fi
-
-if test -n "$ac_cv_prog_DLLTOOL"; then
- for ncn_progname in dlltool; do
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_DLLTOOL+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$DLLTOOL"; then
- ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_DLLTOOL="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-DLLTOOL=$ac_cv_prog_DLLTOOL
-if test -n "$DLLTOOL"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5
-$as_echo "$DLLTOOL" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- done
-fi
-
-for ncn_progname in dlltool; do
- if test -n "$ncn_tool_prefix"; then
- # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_DLLTOOL+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$DLLTOOL"; then
- ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_DLLTOOL="${ncn_tool_prefix}${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-DLLTOOL=$ac_cv_prog_DLLTOOL
-if test -n "$DLLTOOL"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5
-$as_echo "$DLLTOOL" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- if test -z "$ac_cv_prog_DLLTOOL" && test $build = $host ; then
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_DLLTOOL+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$DLLTOOL"; then
- ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_DLLTOOL="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-DLLTOOL=$ac_cv_prog_DLLTOOL
-if test -n "$DLLTOOL"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL" >&5
-$as_echo "$DLLTOOL" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- test -n "$ac_cv_prog_DLLTOOL" && break
-done
-
-if test -z "$ac_cv_prog_DLLTOOL" ; then
- set dummy dlltool
- if test $build = $host ; then
- DLLTOOL="$2"
- else
- DLLTOOL="${ncn_tool_prefix}$2"
- fi
-fi
-
-
-
-if test -n "$DSYMUTIL"; then
- ac_cv_prog_DSYMUTIL=$DSYMUTIL
-elif test -n "$ac_cv_prog_DSYMUTIL"; then
- DSYMUTIL=$ac_cv_prog_DSYMUTIL
-fi
-
-if test -n "$ac_cv_prog_DSYMUTIL"; then
- for ncn_progname in dsymutil; do
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_DSYMUTIL+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$DSYMUTIL"; then
- ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_DSYMUTIL="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-DSYMUTIL=$ac_cv_prog_DSYMUTIL
-if test -n "$DSYMUTIL"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5
-$as_echo "$DSYMUTIL" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- done
-fi
-
-for ncn_progname in dsymutil; do
- if test -n "$ncn_tool_prefix"; then
- # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_DSYMUTIL+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$DSYMUTIL"; then
- ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_DSYMUTIL="${ncn_tool_prefix}${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-DSYMUTIL=$ac_cv_prog_DSYMUTIL
-if test -n "$DSYMUTIL"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5
-$as_echo "$DSYMUTIL" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- if test -z "$ac_cv_prog_DSYMUTIL" && test $build = $host ; then
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_DSYMUTIL+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$DSYMUTIL"; then
- ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_DSYMUTIL="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-DSYMUTIL=$ac_cv_prog_DSYMUTIL
-if test -n "$DSYMUTIL"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5
-$as_echo "$DSYMUTIL" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- test -n "$ac_cv_prog_DSYMUTIL" && break
-done
-
-if test -z "$ac_cv_prog_DSYMUTIL" ; then
- set dummy dsymutil
- if test $build = $host ; then
- DSYMUTIL="$2"
- else
- DSYMUTIL="${ncn_tool_prefix}$2"
- fi
-fi
-
-
-
-if test -n "$LD"; then
- ac_cv_prog_LD=$LD
-elif test -n "$ac_cv_prog_LD"; then
- LD=$ac_cv_prog_LD
-fi
-
-if test -n "$ac_cv_prog_LD"; then
- for ncn_progname in ld; do
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_LD+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$LD"; then
- ac_cv_prog_LD="$LD" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_LD="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-LD=$ac_cv_prog_LD
-if test -n "$LD"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
-$as_echo "$LD" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- done
-fi
-
-for ncn_progname in ld; do
- if test -n "$ncn_tool_prefix"; then
- # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_LD+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$LD"; then
- ac_cv_prog_LD="$LD" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_LD="${ncn_tool_prefix}${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-LD=$ac_cv_prog_LD
-if test -n "$LD"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
-$as_echo "$LD" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- if test -z "$ac_cv_prog_LD" && test $build = $host ; then
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_LD+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$LD"; then
- ac_cv_prog_LD="$LD" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_LD="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-LD=$ac_cv_prog_LD
-if test -n "$LD"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
-$as_echo "$LD" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- test -n "$ac_cv_prog_LD" && break
-done
-
-if test -z "$ac_cv_prog_LD" ; then
- set dummy ld
- if test $build = $host ; then
- LD="$2"
- else
- LD="${ncn_tool_prefix}$2"
- fi
-fi
-
-
-
-if test -n "$LIPO"; then
- ac_cv_prog_LIPO=$LIPO
-elif test -n "$ac_cv_prog_LIPO"; then
- LIPO=$ac_cv_prog_LIPO
-fi
-
-if test -n "$ac_cv_prog_LIPO"; then
- for ncn_progname in lipo; do
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_LIPO+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$LIPO"; then
- ac_cv_prog_LIPO="$LIPO" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_LIPO="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-LIPO=$ac_cv_prog_LIPO
-if test -n "$LIPO"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5
-$as_echo "$LIPO" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- done
-fi
-
-for ncn_progname in lipo; do
- if test -n "$ncn_tool_prefix"; then
- # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_LIPO+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$LIPO"; then
- ac_cv_prog_LIPO="$LIPO" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_LIPO="${ncn_tool_prefix}${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-LIPO=$ac_cv_prog_LIPO
-if test -n "$LIPO"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5
-$as_echo "$LIPO" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- if test -z "$ac_cv_prog_LIPO" && test $build = $host ; then
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_LIPO+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$LIPO"; then
- ac_cv_prog_LIPO="$LIPO" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_LIPO="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-LIPO=$ac_cv_prog_LIPO
-if test -n "$LIPO"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5
-$as_echo "$LIPO" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- test -n "$ac_cv_prog_LIPO" && break
-done
-
-if test -z "$ac_cv_prog_LIPO" ; then
- set dummy lipo
- if test $build = $host ; then
- LIPO="$2"
- else
- LIPO="${ncn_tool_prefix}$2"
- fi
-fi
-
-
-
-if test -n "$NM"; then
- ac_cv_prog_NM=$NM
-elif test -n "$ac_cv_prog_NM"; then
- NM=$ac_cv_prog_NM
-fi
-
-if test -n "$ac_cv_prog_NM"; then
- for ncn_progname in nm; do
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_NM+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$NM"; then
- ac_cv_prog_NM="$NM" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_NM="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-NM=$ac_cv_prog_NM
-if test -n "$NM"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5
-$as_echo "$NM" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- done
-fi
-
-for ncn_progname in nm; do
- if test -n "$ncn_tool_prefix"; then
- # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_NM+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$NM"; then
- ac_cv_prog_NM="$NM" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_NM="${ncn_tool_prefix}${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-NM=$ac_cv_prog_NM
-if test -n "$NM"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5
-$as_echo "$NM" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- if test -z "$ac_cv_prog_NM" && test $build = $host ; then
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_NM+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$NM"; then
- ac_cv_prog_NM="$NM" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_NM="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-NM=$ac_cv_prog_NM
-if test -n "$NM"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5
-$as_echo "$NM" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- test -n "$ac_cv_prog_NM" && break
-done
-
-if test -z "$ac_cv_prog_NM" ; then
- set dummy nm
- if test $build = $host ; then
- NM="$2"
- else
- NM="${ncn_tool_prefix}$2"
- fi
-fi
-
-
-
-if test -n "$RANLIB"; then
- ac_cv_prog_RANLIB=$RANLIB
-elif test -n "$ac_cv_prog_RANLIB"; then
- RANLIB=$ac_cv_prog_RANLIB
-fi
-
-if test -n "$ac_cv_prog_RANLIB"; then
- for ncn_progname in ranlib; do
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_RANLIB+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$RANLIB"; then
- ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_RANLIB="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-RANLIB=$ac_cv_prog_RANLIB
-if test -n "$RANLIB"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
-$as_echo "$RANLIB" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- done
-fi
-
-for ncn_progname in ranlib; do
- if test -n "$ncn_tool_prefix"; then
- # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_RANLIB+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$RANLIB"; then
- ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_RANLIB="${ncn_tool_prefix}${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-RANLIB=$ac_cv_prog_RANLIB
-if test -n "$RANLIB"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
-$as_echo "$RANLIB" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- if test -z "$ac_cv_prog_RANLIB" && test $build = $host ; then
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_RANLIB+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$RANLIB"; then
- ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_RANLIB="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-RANLIB=$ac_cv_prog_RANLIB
-if test -n "$RANLIB"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
-$as_echo "$RANLIB" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- test -n "$ac_cv_prog_RANLIB" && break
-done
-
-if test -z "$ac_cv_prog_RANLIB" ; then
- RANLIB="true"
-fi
-
-
-
-if test -n "$STRIP"; then
- ac_cv_prog_STRIP=$STRIP
-elif test -n "$ac_cv_prog_STRIP"; then
- STRIP=$ac_cv_prog_STRIP
-fi
-
-if test -n "$ac_cv_prog_STRIP"; then
- for ncn_progname in strip; do
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_STRIP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$STRIP"; then
- ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_STRIP="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-STRIP=$ac_cv_prog_STRIP
-if test -n "$STRIP"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
-$as_echo "$STRIP" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- done
-fi
-
-for ncn_progname in strip; do
- if test -n "$ncn_tool_prefix"; then
- # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_STRIP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$STRIP"; then
- ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_STRIP="${ncn_tool_prefix}${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-STRIP=$ac_cv_prog_STRIP
-if test -n "$STRIP"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
-$as_echo "$STRIP" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- if test -z "$ac_cv_prog_STRIP" && test $build = $host ; then
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_STRIP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$STRIP"; then
- ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_STRIP="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-STRIP=$ac_cv_prog_STRIP
-if test -n "$STRIP"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
-$as_echo "$STRIP" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- test -n "$ac_cv_prog_STRIP" && break
-done
-
-if test -z "$ac_cv_prog_STRIP" ; then
- STRIP="true"
-fi
-
-
-
-if test -n "$WINDRES"; then
- ac_cv_prog_WINDRES=$WINDRES
-elif test -n "$ac_cv_prog_WINDRES"; then
- WINDRES=$ac_cv_prog_WINDRES
-fi
-
-if test -n "$ac_cv_prog_WINDRES"; then
- for ncn_progname in windres; do
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_WINDRES+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$WINDRES"; then
- ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_WINDRES="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-WINDRES=$ac_cv_prog_WINDRES
-if test -n "$WINDRES"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDRES" >&5
-$as_echo "$WINDRES" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- done
-fi
-
-for ncn_progname in windres; do
- if test -n "$ncn_tool_prefix"; then
- # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_WINDRES+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$WINDRES"; then
- ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_WINDRES="${ncn_tool_prefix}${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-WINDRES=$ac_cv_prog_WINDRES
-if test -n "$WINDRES"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDRES" >&5
-$as_echo "$WINDRES" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- if test -z "$ac_cv_prog_WINDRES" && test $build = $host ; then
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_WINDRES+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$WINDRES"; then
- ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_WINDRES="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-WINDRES=$ac_cv_prog_WINDRES
-if test -n "$WINDRES"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDRES" >&5
-$as_echo "$WINDRES" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- test -n "$ac_cv_prog_WINDRES" && break
-done
-
-if test -z "$ac_cv_prog_WINDRES" ; then
- set dummy windres
- if test $build = $host ; then
- WINDRES="$2"
- else
- WINDRES="${ncn_tool_prefix}$2"
- fi
-fi
-
-
-
-if test -n "$WINDMC"; then
- ac_cv_prog_WINDMC=$WINDMC
-elif test -n "$ac_cv_prog_WINDMC"; then
- WINDMC=$ac_cv_prog_WINDMC
-fi
-
-if test -n "$ac_cv_prog_WINDMC"; then
- for ncn_progname in windmc; do
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_WINDMC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$WINDMC"; then
- ac_cv_prog_WINDMC="$WINDMC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_WINDMC="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-WINDMC=$ac_cv_prog_WINDMC
-if test -n "$WINDMC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDMC" >&5
-$as_echo "$WINDMC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- done
-fi
-
-for ncn_progname in windmc; do
- if test -n "$ncn_tool_prefix"; then
- # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_WINDMC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$WINDMC"; then
- ac_cv_prog_WINDMC="$WINDMC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_WINDMC="${ncn_tool_prefix}${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-WINDMC=$ac_cv_prog_WINDMC
-if test -n "$WINDMC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDMC" >&5
-$as_echo "$WINDMC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- if test -z "$ac_cv_prog_WINDMC" && test $build = $host ; then
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_WINDMC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$WINDMC"; then
- ac_cv_prog_WINDMC="$WINDMC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_WINDMC="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-WINDMC=$ac_cv_prog_WINDMC
-if test -n "$WINDMC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDMC" >&5
-$as_echo "$WINDMC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- test -n "$ac_cv_prog_WINDMC" && break
-done
-
-if test -z "$ac_cv_prog_WINDMC" ; then
- set dummy windmc
- if test $build = $host ; then
- WINDMC="$2"
- else
- WINDMC="${ncn_tool_prefix}$2"
- fi
-fi
-
-
-
-if test -n "$OBJCOPY"; then
- ac_cv_prog_OBJCOPY=$OBJCOPY
-elif test -n "$ac_cv_prog_OBJCOPY"; then
- OBJCOPY=$ac_cv_prog_OBJCOPY
-fi
-
-if test -n "$ac_cv_prog_OBJCOPY"; then
- for ncn_progname in objcopy; do
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_OBJCOPY+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$OBJCOPY"; then
- ac_cv_prog_OBJCOPY="$OBJCOPY" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_OBJCOPY="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-OBJCOPY=$ac_cv_prog_OBJCOPY
-if test -n "$OBJCOPY"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5
-$as_echo "$OBJCOPY" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- done
-fi
-
-for ncn_progname in objcopy; do
- if test -n "$ncn_tool_prefix"; then
- # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_OBJCOPY+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$OBJCOPY"; then
- ac_cv_prog_OBJCOPY="$OBJCOPY" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_OBJCOPY="${ncn_tool_prefix}${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-OBJCOPY=$ac_cv_prog_OBJCOPY
-if test -n "$OBJCOPY"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5
-$as_echo "$OBJCOPY" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- if test -z "$ac_cv_prog_OBJCOPY" && test $build = $host ; then
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_OBJCOPY+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$OBJCOPY"; then
- ac_cv_prog_OBJCOPY="$OBJCOPY" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_OBJCOPY="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-OBJCOPY=$ac_cv_prog_OBJCOPY
-if test -n "$OBJCOPY"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5
-$as_echo "$OBJCOPY" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- test -n "$ac_cv_prog_OBJCOPY" && break
-done
-
-if test -z "$ac_cv_prog_OBJCOPY" ; then
- set dummy objcopy
- if test $build = $host ; then
- OBJCOPY="$2"
- else
- OBJCOPY="${ncn_tool_prefix}$2"
- fi
-fi
-
-
-
-if test -n "$OBJDUMP"; then
- ac_cv_prog_OBJDUMP=$OBJDUMP
-elif test -n "$ac_cv_prog_OBJDUMP"; then
- OBJDUMP=$ac_cv_prog_OBJDUMP
-fi
-
-if test -n "$ac_cv_prog_OBJDUMP"; then
- for ncn_progname in objdump; do
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_OBJDUMP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$OBJDUMP"; then
- ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_OBJDUMP="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-OBJDUMP=$ac_cv_prog_OBJDUMP
-if test -n "$OBJDUMP"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
-$as_echo "$OBJDUMP" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- done
-fi
-
-for ncn_progname in objdump; do
- if test -n "$ncn_tool_prefix"; then
- # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_OBJDUMP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$OBJDUMP"; then
- ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_OBJDUMP="${ncn_tool_prefix}${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-OBJDUMP=$ac_cv_prog_OBJDUMP
-if test -n "$OBJDUMP"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
-$as_echo "$OBJDUMP" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- if test -z "$ac_cv_prog_OBJDUMP" && test $build = $host ; then
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_OBJDUMP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$OBJDUMP"; then
- ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_OBJDUMP="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-OBJDUMP=$ac_cv_prog_OBJDUMP
-if test -n "$OBJDUMP"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
-$as_echo "$OBJDUMP" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- test -n "$ac_cv_prog_OBJDUMP" && break
-done
-
-if test -z "$ac_cv_prog_OBJDUMP" ; then
- set dummy objdump
- if test $build = $host ; then
- OBJDUMP="$2"
- else
- OBJDUMP="${ncn_tool_prefix}$2"
- fi
-fi
-
-
-
-if test -n "$OTOOL"; then
- ac_cv_prog_OTOOL=$OTOOL
-elif test -n "$ac_cv_prog_OTOOL"; then
- OTOOL=$ac_cv_prog_OTOOL
-fi
-
-if test -n "$ac_cv_prog_OTOOL"; then
- for ncn_progname in otool; do
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_OTOOL+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$OTOOL"; then
- ac_cv_prog_OTOOL="$OTOOL" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_OTOOL="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-OTOOL=$ac_cv_prog_OTOOL
-if test -n "$OTOOL"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5
-$as_echo "$OTOOL" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- done
-fi
-
-for ncn_progname in otool; do
- if test -n "$ncn_tool_prefix"; then
- # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_OTOOL+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$OTOOL"; then
- ac_cv_prog_OTOOL="$OTOOL" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_OTOOL="${ncn_tool_prefix}${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-OTOOL=$ac_cv_prog_OTOOL
-if test -n "$OTOOL"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5
-$as_echo "$OTOOL" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- if test -z "$ac_cv_prog_OTOOL" && test $build = $host ; then
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_OTOOL+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$OTOOL"; then
- ac_cv_prog_OTOOL="$OTOOL" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_OTOOL="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-OTOOL=$ac_cv_prog_OTOOL
-if test -n "$OTOOL"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5
-$as_echo "$OTOOL" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- test -n "$ac_cv_prog_OTOOL" && break
-done
-
-if test -z "$ac_cv_prog_OTOOL" ; then
- set dummy otool
- if test $build = $host ; then
- OTOOL="$2"
- else
- OTOOL="${ncn_tool_prefix}$2"
- fi
-fi
-
-
-
-if test -n "$READELF"; then
- ac_cv_prog_READELF=$READELF
-elif test -n "$ac_cv_prog_READELF"; then
- READELF=$ac_cv_prog_READELF
-fi
-
-if test -n "$ac_cv_prog_READELF"; then
- for ncn_progname in readelf; do
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_READELF+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$READELF"; then
- ac_cv_prog_READELF="$READELF" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_READELF="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-READELF=$ac_cv_prog_READELF
-if test -n "$READELF"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5
-$as_echo "$READELF" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- done
-fi
-
-for ncn_progname in readelf; do
- if test -n "$ncn_tool_prefix"; then
- # Extract the first word of "${ncn_tool_prefix}${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_tool_prefix}${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_READELF+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$READELF"; then
- ac_cv_prog_READELF="$READELF" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_READELF="${ncn_tool_prefix}${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-READELF=$ac_cv_prog_READELF
-if test -n "$READELF"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5
-$as_echo "$READELF" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- if test -z "$ac_cv_prog_READELF" && test $build = $host ; then
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_READELF+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$READELF"; then
- ac_cv_prog_READELF="$READELF" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_READELF="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-READELF=$ac_cv_prog_READELF
-if test -n "$READELF"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5
-$as_echo "$READELF" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- test -n "$ac_cv_prog_READELF" && break
-done
-
-if test -z "$ac_cv_prog_READELF" ; then
- set dummy readelf
- if test $build = $host ; then
- READELF="$2"
- else
- READELF="${ncn_tool_prefix}$2"
- fi
-fi
-
-
-
-
-
-
-
-GDCFLAGS=${GDCFLAGS-${CFLAGS}}
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for -plugin option" >&5
-$as_echo_n "checking for -plugin option... " >&6; }
-
-plugin_names="liblto_plugin.so liblto_plugin-0.dll cyglto_plugin-0.dll"
-plugin_option=
-for plugin in $plugin_names; do
- plugin_so=`${CC} ${CFLAGS} --print-prog-name $plugin`
- if test x$plugin_so = x$plugin; then
- plugin_so=`${CC} ${CFLAGS} --print-file-name $plugin`
- fi
- if test x$plugin_so != x$plugin; then
- plugin_option="--plugin $plugin_so"
- break
- fi
-done
-if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
-set dummy ${ac_tool_prefix}ar; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_AR+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$AR"; then
- ac_cv_prog_AR="$AR" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_AR="${ac_tool_prefix}ar"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-AR=$ac_cv_prog_AR
-if test -n "$AR"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
-$as_echo "$AR" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_AR"; then
- ac_ct_AR=$AR
- # Extract the first word of "ar", so it can be a program name with args.
-set dummy ar; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_AR+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_AR"; then
- ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_AR="ar"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_AR=$ac_cv_prog_ac_ct_AR
-if test -n "$ac_ct_AR"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
-$as_echo "$ac_ct_AR" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_AR" = x; then
- AR=""
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- AR=$ac_ct_AR
- fi
-else
- AR="$ac_cv_prog_AR"
-fi
-
-if test "${AR}" = "" ; then
- as_fn_error $? "Required archive tool 'ar' not found on PATH." "$LINENO" 5
-fi
-touch conftest.c
-${AR} $plugin_option rc conftest.a conftest.c
-if test "$?" != 0; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed: $AR $plugin_option rc" >&5
-$as_echo "$as_me: WARNING: Failed: $AR $plugin_option rc" >&2;}
- plugin_option=
-fi
-rm -f conftest.*
-if test -n "$plugin_option"; then
- PLUGIN_OPTION="$plugin_option"
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $plugin_option" >&5
-$as_echo "$plugin_option" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-AR_PLUGIN_OPTION=
-RANLIB_PLUGIN_OPTION=
-if test -n "$PLUGIN_OPTION"; then
- if $AR --help 2>&1 | grep -q "\--plugin"; then
- AR_PLUGIN_OPTION="$PLUGIN_OPTION"
- fi
- if $RANLIB --help 2>&1 | grep -q "\--plugin"; then
- RANLIB_PLUGIN_OPTION="$PLUGIN_OPTION"
- fi
-fi
-
-
-
-# Target tools.
-
-# Check whether --with-build-time-tools was given.
-if test "${with_build_time_tools+set}" = set; then :
- withval=$with_build_time_tools; case x"$withval" in
- x/*) ;;
- *)
- with_build_time_tools=
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: argument to --with-build-time-tools must be an absolute path" >&5
-$as_echo "$as_me: WARNING: argument to --with-build-time-tools must be an absolute path" >&2;}
- ;;
- esac
-else
- with_build_time_tools=
-fi
-
-
-
-
-if test -n "$CC_FOR_TARGET"; then
- ac_cv_prog_CC_FOR_TARGET=$CC_FOR_TARGET
-elif test -n "$ac_cv_prog_CC_FOR_TARGET"; then
- CC_FOR_TARGET=$ac_cv_prog_CC_FOR_TARGET
-fi
-
-if test -n "$ac_cv_prog_CC_FOR_TARGET"; then
- for ncn_progname in cc gcc; do
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CC_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$CC_FOR_TARGET"; then
- ac_cv_prog_CC_FOR_TARGET="$CC_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_CC_FOR_TARGET="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-CC_FOR_TARGET=$ac_cv_prog_CC_FOR_TARGET
-if test -n "$CC_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC_FOR_TARGET" >&5
-$as_echo "$CC_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- done
-fi
-
-if test -z "$ac_cv_prog_CC_FOR_TARGET" && test -n "$with_build_time_tools"; then
- for ncn_progname in cc gcc; do
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
-$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
- if test -x $with_build_time_tools/${ncn_progname}; then
- ac_cv_prog_CC_FOR_TARGET=$with_build_time_tools/${ncn_progname}
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- break
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- fi
- done
-fi
-
-if test -z "$ac_cv_prog_CC_FOR_TARGET"; then
- for ncn_progname in cc gcc; do
- if test -n "$ncn_target_tool_prefix"; then
- # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CC_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$CC_FOR_TARGET"; then
- ac_cv_prog_CC_FOR_TARGET="$CC_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_CC_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-CC_FOR_TARGET=$ac_cv_prog_CC_FOR_TARGET
-if test -n "$CC_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC_FOR_TARGET" >&5
-$as_echo "$CC_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- if test -z "$ac_cv_prog_CC_FOR_TARGET" && test $build = $target ; then
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CC_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$CC_FOR_TARGET"; then
- ac_cv_prog_CC_FOR_TARGET="$CC_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_CC_FOR_TARGET="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-CC_FOR_TARGET=$ac_cv_prog_CC_FOR_TARGET
-if test -n "$CC_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC_FOR_TARGET" >&5
-$as_echo "$CC_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- test -n "$ac_cv_prog_CC_FOR_TARGET" && break
- done
-fi
-
-if test -z "$ac_cv_prog_CC_FOR_TARGET" ; then
- set dummy cc gcc
- if test $build = $target ; then
- CC_FOR_TARGET="$2"
- else
- CC_FOR_TARGET="${ncn_target_tool_prefix}$2"
- fi
-else
- CC_FOR_TARGET="$ac_cv_prog_CC_FOR_TARGET"
-fi
-
-
-
-if test -n "$CXX_FOR_TARGET"; then
- ac_cv_prog_CXX_FOR_TARGET=$CXX_FOR_TARGET
-elif test -n "$ac_cv_prog_CXX_FOR_TARGET"; then
- CXX_FOR_TARGET=$ac_cv_prog_CXX_FOR_TARGET
-fi
-
-if test -n "$ac_cv_prog_CXX_FOR_TARGET"; then
- for ncn_progname in c++ g++ cxx gxx; do
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CXX_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$CXX_FOR_TARGET"; then
- ac_cv_prog_CXX_FOR_TARGET="$CXX_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_CXX_FOR_TARGET="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-CXX_FOR_TARGET=$ac_cv_prog_CXX_FOR_TARGET
-if test -n "$CXX_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX_FOR_TARGET" >&5
-$as_echo "$CXX_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- done
-fi
-
-if test -z "$ac_cv_prog_CXX_FOR_TARGET" && test -n "$with_build_time_tools"; then
- for ncn_progname in c++ g++ cxx gxx; do
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
-$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
- if test -x $with_build_time_tools/${ncn_progname}; then
- ac_cv_prog_CXX_FOR_TARGET=$with_build_time_tools/${ncn_progname}
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- break
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- fi
- done
-fi
-
-if test -z "$ac_cv_prog_CXX_FOR_TARGET"; then
- for ncn_progname in c++ g++ cxx gxx; do
- if test -n "$ncn_target_tool_prefix"; then
- # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CXX_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$CXX_FOR_TARGET"; then
- ac_cv_prog_CXX_FOR_TARGET="$CXX_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_CXX_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-CXX_FOR_TARGET=$ac_cv_prog_CXX_FOR_TARGET
-if test -n "$CXX_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX_FOR_TARGET" >&5
-$as_echo "$CXX_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- if test -z "$ac_cv_prog_CXX_FOR_TARGET" && test $build = $target ; then
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CXX_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$CXX_FOR_TARGET"; then
- ac_cv_prog_CXX_FOR_TARGET="$CXX_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_CXX_FOR_TARGET="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-CXX_FOR_TARGET=$ac_cv_prog_CXX_FOR_TARGET
-if test -n "$CXX_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX_FOR_TARGET" >&5
-$as_echo "$CXX_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- test -n "$ac_cv_prog_CXX_FOR_TARGET" && break
- done
-fi
-
-if test -z "$ac_cv_prog_CXX_FOR_TARGET" ; then
- set dummy c++ g++ cxx gxx
- if test $build = $target ; then
- CXX_FOR_TARGET="$2"
- else
- CXX_FOR_TARGET="${ncn_target_tool_prefix}$2"
- fi
-else
- CXX_FOR_TARGET="$ac_cv_prog_CXX_FOR_TARGET"
-fi
-
-
-
-if test -n "$GCC_FOR_TARGET"; then
- ac_cv_prog_GCC_FOR_TARGET=$GCC_FOR_TARGET
-elif test -n "$ac_cv_prog_GCC_FOR_TARGET"; then
- GCC_FOR_TARGET=$ac_cv_prog_GCC_FOR_TARGET
-fi
-
-if test -n "$ac_cv_prog_GCC_FOR_TARGET"; then
- for ncn_progname in gcc; do
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_GCC_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$GCC_FOR_TARGET"; then
- ac_cv_prog_GCC_FOR_TARGET="$GCC_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_GCC_FOR_TARGET="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-GCC_FOR_TARGET=$ac_cv_prog_GCC_FOR_TARGET
-if test -n "$GCC_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GCC_FOR_TARGET" >&5
-$as_echo "$GCC_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- done
-fi
-
-if test -z "$ac_cv_prog_GCC_FOR_TARGET" && test -n "$with_build_time_tools"; then
- for ncn_progname in gcc; do
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
-$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
- if test -x $with_build_time_tools/${ncn_progname}; then
- ac_cv_prog_GCC_FOR_TARGET=$with_build_time_tools/${ncn_progname}
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- break
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- fi
- done
-fi
-
-if test -z "$ac_cv_prog_GCC_FOR_TARGET"; then
- for ncn_progname in gcc; do
- if test -n "$ncn_target_tool_prefix"; then
- # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_GCC_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$GCC_FOR_TARGET"; then
- ac_cv_prog_GCC_FOR_TARGET="$GCC_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_GCC_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-GCC_FOR_TARGET=$ac_cv_prog_GCC_FOR_TARGET
-if test -n "$GCC_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GCC_FOR_TARGET" >&5
-$as_echo "$GCC_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- if test -z "$ac_cv_prog_GCC_FOR_TARGET" && test $build = $target ; then
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_GCC_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$GCC_FOR_TARGET"; then
- ac_cv_prog_GCC_FOR_TARGET="$GCC_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_GCC_FOR_TARGET="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-GCC_FOR_TARGET=$ac_cv_prog_GCC_FOR_TARGET
-if test -n "$GCC_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GCC_FOR_TARGET" >&5
-$as_echo "$GCC_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- test -n "$ac_cv_prog_GCC_FOR_TARGET" && break
- done
-fi
-
-if test -z "$ac_cv_prog_GCC_FOR_TARGET" ; then
- GCC_FOR_TARGET="${CC_FOR_TARGET}"
-else
- GCC_FOR_TARGET="$ac_cv_prog_GCC_FOR_TARGET"
-fi
-
-
-
-if test -n "$GFORTRAN_FOR_TARGET"; then
- ac_cv_prog_GFORTRAN_FOR_TARGET=$GFORTRAN_FOR_TARGET
-elif test -n "$ac_cv_prog_GFORTRAN_FOR_TARGET"; then
- GFORTRAN_FOR_TARGET=$ac_cv_prog_GFORTRAN_FOR_TARGET
-fi
-
-if test -n "$ac_cv_prog_GFORTRAN_FOR_TARGET"; then
- for ncn_progname in gfortran; do
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_GFORTRAN_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$GFORTRAN_FOR_TARGET"; then
- ac_cv_prog_GFORTRAN_FOR_TARGET="$GFORTRAN_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_GFORTRAN_FOR_TARGET="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-GFORTRAN_FOR_TARGET=$ac_cv_prog_GFORTRAN_FOR_TARGET
-if test -n "$GFORTRAN_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GFORTRAN_FOR_TARGET" >&5
-$as_echo "$GFORTRAN_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- done
-fi
-
-if test -z "$ac_cv_prog_GFORTRAN_FOR_TARGET" && test -n "$with_build_time_tools"; then
- for ncn_progname in gfortran; do
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
-$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
- if test -x $with_build_time_tools/${ncn_progname}; then
- ac_cv_prog_GFORTRAN_FOR_TARGET=$with_build_time_tools/${ncn_progname}
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- break
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- fi
- done
-fi
-
-if test -z "$ac_cv_prog_GFORTRAN_FOR_TARGET"; then
- for ncn_progname in gfortran; do
- if test -n "$ncn_target_tool_prefix"; then
- # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_GFORTRAN_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$GFORTRAN_FOR_TARGET"; then
- ac_cv_prog_GFORTRAN_FOR_TARGET="$GFORTRAN_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_GFORTRAN_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-GFORTRAN_FOR_TARGET=$ac_cv_prog_GFORTRAN_FOR_TARGET
-if test -n "$GFORTRAN_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GFORTRAN_FOR_TARGET" >&5
-$as_echo "$GFORTRAN_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- if test -z "$ac_cv_prog_GFORTRAN_FOR_TARGET" && test $build = $target ; then
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_GFORTRAN_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$GFORTRAN_FOR_TARGET"; then
- ac_cv_prog_GFORTRAN_FOR_TARGET="$GFORTRAN_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_GFORTRAN_FOR_TARGET="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-GFORTRAN_FOR_TARGET=$ac_cv_prog_GFORTRAN_FOR_TARGET
-if test -n "$GFORTRAN_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GFORTRAN_FOR_TARGET" >&5
-$as_echo "$GFORTRAN_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- test -n "$ac_cv_prog_GFORTRAN_FOR_TARGET" && break
- done
-fi
-
-if test -z "$ac_cv_prog_GFORTRAN_FOR_TARGET" ; then
- set dummy gfortran
- if test $build = $target ; then
- GFORTRAN_FOR_TARGET="$2"
- else
- GFORTRAN_FOR_TARGET="${ncn_target_tool_prefix}$2"
- fi
-else
- GFORTRAN_FOR_TARGET="$ac_cv_prog_GFORTRAN_FOR_TARGET"
-fi
-
-
-
-if test -n "$GOC_FOR_TARGET"; then
- ac_cv_prog_GOC_FOR_TARGET=$GOC_FOR_TARGET
-elif test -n "$ac_cv_prog_GOC_FOR_TARGET"; then
- GOC_FOR_TARGET=$ac_cv_prog_GOC_FOR_TARGET
-fi
-
-if test -n "$ac_cv_prog_GOC_FOR_TARGET"; then
- for ncn_progname in gccgo; do
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_GOC_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$GOC_FOR_TARGET"; then
- ac_cv_prog_GOC_FOR_TARGET="$GOC_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_GOC_FOR_TARGET="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-GOC_FOR_TARGET=$ac_cv_prog_GOC_FOR_TARGET
-if test -n "$GOC_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GOC_FOR_TARGET" >&5
-$as_echo "$GOC_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- done
-fi
-
-if test -z "$ac_cv_prog_GOC_FOR_TARGET" && test -n "$with_build_time_tools"; then
- for ncn_progname in gccgo; do
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
-$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
- if test -x $with_build_time_tools/${ncn_progname}; then
- ac_cv_prog_GOC_FOR_TARGET=$with_build_time_tools/${ncn_progname}
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- break
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- fi
- done
-fi
-
-if test -z "$ac_cv_prog_GOC_FOR_TARGET"; then
- for ncn_progname in gccgo; do
- if test -n "$ncn_target_tool_prefix"; then
- # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_GOC_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$GOC_FOR_TARGET"; then
- ac_cv_prog_GOC_FOR_TARGET="$GOC_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_GOC_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-GOC_FOR_TARGET=$ac_cv_prog_GOC_FOR_TARGET
-if test -n "$GOC_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GOC_FOR_TARGET" >&5
-$as_echo "$GOC_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- if test -z "$ac_cv_prog_GOC_FOR_TARGET" && test $build = $target ; then
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_GOC_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$GOC_FOR_TARGET"; then
- ac_cv_prog_GOC_FOR_TARGET="$GOC_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_GOC_FOR_TARGET="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-GOC_FOR_TARGET=$ac_cv_prog_GOC_FOR_TARGET
-if test -n "$GOC_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GOC_FOR_TARGET" >&5
-$as_echo "$GOC_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- test -n "$ac_cv_prog_GOC_FOR_TARGET" && break
- done
-fi
-
-if test -z "$ac_cv_prog_GOC_FOR_TARGET" ; then
- set dummy gccgo
- if test $build = $target ; then
- GOC_FOR_TARGET="$2"
- else
- GOC_FOR_TARGET="${ncn_target_tool_prefix}$2"
- fi
-else
- GOC_FOR_TARGET="$ac_cv_prog_GOC_FOR_TARGET"
-fi
-
-
-
-if test -n "$GDC_FOR_TARGET"; then
- ac_cv_prog_GDC_FOR_TARGET=$GDC_FOR_TARGET
-elif test -n "$ac_cv_prog_GDC_FOR_TARGET"; then
- GDC_FOR_TARGET=$ac_cv_prog_GDC_FOR_TARGET
-fi
-
-if test -n "$ac_cv_prog_GDC_FOR_TARGET"; then
- for ncn_progname in gdc; do
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_GDC_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$GDC_FOR_TARGET"; then
- ac_cv_prog_GDC_FOR_TARGET="$GDC_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_GDC_FOR_TARGET="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-GDC_FOR_TARGET=$ac_cv_prog_GDC_FOR_TARGET
-if test -n "$GDC_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GDC_FOR_TARGET" >&5
-$as_echo "$GDC_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- done
-fi
-
-if test -z "$ac_cv_prog_GDC_FOR_TARGET" && test -n "$with_build_time_tools"; then
- for ncn_progname in gdc; do
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
-$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
- if test -x $with_build_time_tools/${ncn_progname}; then
- ac_cv_prog_GDC_FOR_TARGET=$with_build_time_tools/${ncn_progname}
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- break
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- fi
- done
-fi
-
-if test -z "$ac_cv_prog_GDC_FOR_TARGET"; then
- for ncn_progname in gdc; do
- if test -n "$ncn_target_tool_prefix"; then
- # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_GDC_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$GDC_FOR_TARGET"; then
- ac_cv_prog_GDC_FOR_TARGET="$GDC_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_GDC_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-GDC_FOR_TARGET=$ac_cv_prog_GDC_FOR_TARGET
-if test -n "$GDC_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GDC_FOR_TARGET" >&5
-$as_echo "$GDC_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- if test -z "$ac_cv_prog_GDC_FOR_TARGET" && test $build = $target ; then
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_GDC_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$GDC_FOR_TARGET"; then
- ac_cv_prog_GDC_FOR_TARGET="$GDC_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_GDC_FOR_TARGET="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-GDC_FOR_TARGET=$ac_cv_prog_GDC_FOR_TARGET
-if test -n "$GDC_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GDC_FOR_TARGET" >&5
-$as_echo "$GDC_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- test -n "$ac_cv_prog_GDC_FOR_TARGET" && break
- done
-fi
-
-if test -z "$ac_cv_prog_GDC_FOR_TARGET" ; then
- set dummy gdc
- if test $build = $target ; then
- GDC_FOR_TARGET="$2"
- else
- GDC_FOR_TARGET="${ncn_target_tool_prefix}$2"
- fi
-else
- GDC_FOR_TARGET="$ac_cv_prog_GDC_FOR_TARGET"
-fi
-
-
-
-if test -n "$GM2_FOR_TARGET"; then
- ac_cv_prog_GM2_FOR_TARGET=$GM2_FOR_TARGET
-elif test -n "$ac_cv_prog_GM2_FOR_TARGET"; then
- GM2_FOR_TARGET=$ac_cv_prog_GM2_FOR_TARGET
-fi
-
-if test -n "$ac_cv_prog_GM2_FOR_TARGET"; then
- for ncn_progname in gm2; do
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_GM2_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$GM2_FOR_TARGET"; then
- ac_cv_prog_GM2_FOR_TARGET="$GM2_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_GM2_FOR_TARGET="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-GM2_FOR_TARGET=$ac_cv_prog_GM2_FOR_TARGET
-if test -n "$GM2_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GM2_FOR_TARGET" >&5
-$as_echo "$GM2_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- done
-fi
-
-if test -z "$ac_cv_prog_GM2_FOR_TARGET" && test -n "$with_build_time_tools"; then
- for ncn_progname in gm2; do
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
-$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
- if test -x $with_build_time_tools/${ncn_progname}; then
- ac_cv_prog_GM2_FOR_TARGET=$with_build_time_tools/${ncn_progname}
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- break
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- fi
- done
-fi
-
-if test -z "$ac_cv_prog_GM2_FOR_TARGET"; then
- for ncn_progname in gm2; do
- if test -n "$ncn_target_tool_prefix"; then
- # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_GM2_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$GM2_FOR_TARGET"; then
- ac_cv_prog_GM2_FOR_TARGET="$GM2_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_GM2_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-GM2_FOR_TARGET=$ac_cv_prog_GM2_FOR_TARGET
-if test -n "$GM2_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GM2_FOR_TARGET" >&5
-$as_echo "$GM2_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- if test -z "$ac_cv_prog_GM2_FOR_TARGET" && test $build = $target ; then
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_GM2_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$GM2_FOR_TARGET"; then
- ac_cv_prog_GM2_FOR_TARGET="$GM2_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_GM2_FOR_TARGET="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-GM2_FOR_TARGET=$ac_cv_prog_GM2_FOR_TARGET
-if test -n "$GM2_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GM2_FOR_TARGET" >&5
-$as_echo "$GM2_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- test -n "$ac_cv_prog_GM2_FOR_TARGET" && break
- done
-fi
-
-if test -z "$ac_cv_prog_GM2_FOR_TARGET" ; then
- set dummy gm2
- if test $build = $target ; then
- GM2_FOR_TARGET="$2"
- else
- GM2_FOR_TARGET="${ncn_target_tool_prefix}$2"
- fi
-else
- GM2_FOR_TARGET="$ac_cv_prog_GM2_FOR_TARGET"
-fi
-
-
-
-cat > conftest.c << \EOF
-#ifdef __GNUC__
- gcc_yay;
-#endif
-EOF
-if ($GCC_FOR_TARGET -E conftest.c | grep gcc_yay) > /dev/null 2>&1; then
- have_gcc_for_target=yes
-else
- GCC_FOR_TARGET=${ncn_target_tool_prefix}gcc
- have_gcc_for_target=no
-fi
-rm conftest.c
-
-
-
-
-if test -z "$ac_cv_path_AR_FOR_TARGET" ; then
- if test -n "$with_build_time_tools"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ar in $with_build_time_tools" >&5
-$as_echo_n "checking for ar in $with_build_time_tools... " >&6; }
- if test -x $with_build_time_tools/ar; then
- AR_FOR_TARGET=`cd $with_build_time_tools && pwd`/ar
- ac_cv_path_AR_FOR_TARGET=$AR_FOR_TARGET
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_AR_FOR_TARGET" >&5
-$as_echo "$ac_cv_path_AR_FOR_TARGET" >&6; }
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- fi
- elif test $build != $host && test $have_gcc_for_target = yes; then
- AR_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=ar`
- test $AR_FOR_TARGET = ar && AR_FOR_TARGET=
- test -n "$AR_FOR_TARGET" && ac_cv_path_AR_FOR_TARGET=$AR_FOR_TARGET
- fi
-fi
-if test -z "$ac_cv_path_AR_FOR_TARGET" && test -n "$gcc_cv_tool_dirs"; then
- # Extract the first word of "ar", so it can be a program name with args.
-set dummy ar; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_AR_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $AR_FOR_TARGET in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_AR_FOR_TARGET="$AR_FOR_TARGET" # Let the user override the test with a path.
- ;;
- *)
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $gcc_cv_tool_dirs
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_path_AR_FOR_TARGET="$as_dir/$ac_word$ac_exec_ext"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
- ;;
-esac
-fi
-AR_FOR_TARGET=$ac_cv_path_AR_FOR_TARGET
-if test -n "$AR_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR_FOR_TARGET" >&5
-$as_echo "$AR_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_path_AR_FOR_TARGET" ; then
-
-
-if test -n "$AR_FOR_TARGET"; then
- ac_cv_prog_AR_FOR_TARGET=$AR_FOR_TARGET
-elif test -n "$ac_cv_prog_AR_FOR_TARGET"; then
- AR_FOR_TARGET=$ac_cv_prog_AR_FOR_TARGET
-fi
-
-if test -n "$ac_cv_prog_AR_FOR_TARGET"; then
- for ncn_progname in ar; do
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_AR_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$AR_FOR_TARGET"; then
- ac_cv_prog_AR_FOR_TARGET="$AR_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_AR_FOR_TARGET="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-AR_FOR_TARGET=$ac_cv_prog_AR_FOR_TARGET
-if test -n "$AR_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR_FOR_TARGET" >&5
-$as_echo "$AR_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- done
-fi
-
-if test -z "$ac_cv_prog_AR_FOR_TARGET" && test -n "$with_build_time_tools"; then
- for ncn_progname in ar; do
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
-$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
- if test -x $with_build_time_tools/${ncn_progname}; then
- ac_cv_prog_AR_FOR_TARGET=$with_build_time_tools/${ncn_progname}
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- break
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- fi
- done
-fi
-
-if test -z "$ac_cv_prog_AR_FOR_TARGET"; then
- for ncn_progname in ar; do
- if test -n "$ncn_target_tool_prefix"; then
- # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_AR_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$AR_FOR_TARGET"; then
- ac_cv_prog_AR_FOR_TARGET="$AR_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_AR_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-AR_FOR_TARGET=$ac_cv_prog_AR_FOR_TARGET
-if test -n "$AR_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR_FOR_TARGET" >&5
-$as_echo "$AR_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- if test -z "$ac_cv_prog_AR_FOR_TARGET" && test $build = $target ; then
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_AR_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$AR_FOR_TARGET"; then
- ac_cv_prog_AR_FOR_TARGET="$AR_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_AR_FOR_TARGET="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-AR_FOR_TARGET=$ac_cv_prog_AR_FOR_TARGET
-if test -n "$AR_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR_FOR_TARGET" >&5
-$as_echo "$AR_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- test -n "$ac_cv_prog_AR_FOR_TARGET" && break
- done
-fi
-
-if test -z "$ac_cv_prog_AR_FOR_TARGET" ; then
- set dummy ar
- if test $build = $target ; then
- AR_FOR_TARGET="$2"
- else
- AR_FOR_TARGET="${ncn_target_tool_prefix}$2"
- fi
-else
- AR_FOR_TARGET="$ac_cv_prog_AR_FOR_TARGET"
-fi
-
-else
- AR_FOR_TARGET=$ac_cv_path_AR_FOR_TARGET
-fi
-
-
-
-
-if test -z "$ac_cv_path_AS_FOR_TARGET" ; then
- if test -n "$with_build_time_tools"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for as in $with_build_time_tools" >&5
-$as_echo_n "checking for as in $with_build_time_tools... " >&6; }
- if test -x $with_build_time_tools/as; then
- AS_FOR_TARGET=`cd $with_build_time_tools && pwd`/as
- ac_cv_path_AS_FOR_TARGET=$AS_FOR_TARGET
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_AS_FOR_TARGET" >&5
-$as_echo "$ac_cv_path_AS_FOR_TARGET" >&6; }
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- fi
- elif test $build != $host && test $have_gcc_for_target = yes; then
- AS_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=as`
- test $AS_FOR_TARGET = as && AS_FOR_TARGET=
- test -n "$AS_FOR_TARGET" && ac_cv_path_AS_FOR_TARGET=$AS_FOR_TARGET
- fi
-fi
-if test -z "$ac_cv_path_AS_FOR_TARGET" && test -n "$gcc_cv_tool_dirs"; then
- # Extract the first word of "as", so it can be a program name with args.
-set dummy as; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_AS_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $AS_FOR_TARGET in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_AS_FOR_TARGET="$AS_FOR_TARGET" # Let the user override the test with a path.
- ;;
- *)
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $gcc_cv_tool_dirs
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_path_AS_FOR_TARGET="$as_dir/$ac_word$ac_exec_ext"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
- ;;
-esac
-fi
-AS_FOR_TARGET=$ac_cv_path_AS_FOR_TARGET
-if test -n "$AS_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS_FOR_TARGET" >&5
-$as_echo "$AS_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_path_AS_FOR_TARGET" ; then
-
-
-if test -n "$AS_FOR_TARGET"; then
- ac_cv_prog_AS_FOR_TARGET=$AS_FOR_TARGET
-elif test -n "$ac_cv_prog_AS_FOR_TARGET"; then
- AS_FOR_TARGET=$ac_cv_prog_AS_FOR_TARGET
-fi
-
-if test -n "$ac_cv_prog_AS_FOR_TARGET"; then
- for ncn_progname in as; do
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_AS_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$AS_FOR_TARGET"; then
- ac_cv_prog_AS_FOR_TARGET="$AS_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_AS_FOR_TARGET="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-AS_FOR_TARGET=$ac_cv_prog_AS_FOR_TARGET
-if test -n "$AS_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS_FOR_TARGET" >&5
-$as_echo "$AS_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- done
-fi
-
-if test -z "$ac_cv_prog_AS_FOR_TARGET" && test -n "$with_build_time_tools"; then
- for ncn_progname in as; do
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
-$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
- if test -x $with_build_time_tools/${ncn_progname}; then
- ac_cv_prog_AS_FOR_TARGET=$with_build_time_tools/${ncn_progname}
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- break
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- fi
- done
-fi
-
-if test -z "$ac_cv_prog_AS_FOR_TARGET"; then
- for ncn_progname in as; do
- if test -n "$ncn_target_tool_prefix"; then
- # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_AS_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$AS_FOR_TARGET"; then
- ac_cv_prog_AS_FOR_TARGET="$AS_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_AS_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-AS_FOR_TARGET=$ac_cv_prog_AS_FOR_TARGET
-if test -n "$AS_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS_FOR_TARGET" >&5
-$as_echo "$AS_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- if test -z "$ac_cv_prog_AS_FOR_TARGET" && test $build = $target ; then
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_AS_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$AS_FOR_TARGET"; then
- ac_cv_prog_AS_FOR_TARGET="$AS_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_AS_FOR_TARGET="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-AS_FOR_TARGET=$ac_cv_prog_AS_FOR_TARGET
-if test -n "$AS_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS_FOR_TARGET" >&5
-$as_echo "$AS_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- test -n "$ac_cv_prog_AS_FOR_TARGET" && break
- done
-fi
-
-if test -z "$ac_cv_prog_AS_FOR_TARGET" ; then
- set dummy as
- if test $build = $target ; then
- AS_FOR_TARGET="$2"
- else
- AS_FOR_TARGET="${ncn_target_tool_prefix}$2"
- fi
-else
- AS_FOR_TARGET="$ac_cv_prog_AS_FOR_TARGET"
-fi
-
-else
- AS_FOR_TARGET=$ac_cv_path_AS_FOR_TARGET
-fi
-
-
-
-
-if test -z "$ac_cv_path_DLLTOOL_FOR_TARGET" ; then
- if test -n "$with_build_time_tools"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlltool in $with_build_time_tools" >&5
-$as_echo_n "checking for dlltool in $with_build_time_tools... " >&6; }
- if test -x $with_build_time_tools/dlltool; then
- DLLTOOL_FOR_TARGET=`cd $with_build_time_tools && pwd`/dlltool
- ac_cv_path_DLLTOOL_FOR_TARGET=$DLLTOOL_FOR_TARGET
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_DLLTOOL_FOR_TARGET" >&5
-$as_echo "$ac_cv_path_DLLTOOL_FOR_TARGET" >&6; }
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- fi
- elif test $build != $host && test $have_gcc_for_target = yes; then
- DLLTOOL_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=dlltool`
- test $DLLTOOL_FOR_TARGET = dlltool && DLLTOOL_FOR_TARGET=
- test -n "$DLLTOOL_FOR_TARGET" && ac_cv_path_DLLTOOL_FOR_TARGET=$DLLTOOL_FOR_TARGET
- fi
-fi
-if test -z "$ac_cv_path_DLLTOOL_FOR_TARGET" && test -n "$gcc_cv_tool_dirs"; then
- # Extract the first word of "dlltool", so it can be a program name with args.
-set dummy dlltool; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_DLLTOOL_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $DLLTOOL_FOR_TARGET in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_DLLTOOL_FOR_TARGET="$DLLTOOL_FOR_TARGET" # Let the user override the test with a path.
- ;;
- *)
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $gcc_cv_tool_dirs
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_path_DLLTOOL_FOR_TARGET="$as_dir/$ac_word$ac_exec_ext"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
- ;;
-esac
-fi
-DLLTOOL_FOR_TARGET=$ac_cv_path_DLLTOOL_FOR_TARGET
-if test -n "$DLLTOOL_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL_FOR_TARGET" >&5
-$as_echo "$DLLTOOL_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_path_DLLTOOL_FOR_TARGET" ; then
-
-
-if test -n "$DLLTOOL_FOR_TARGET"; then
- ac_cv_prog_DLLTOOL_FOR_TARGET=$DLLTOOL_FOR_TARGET
-elif test -n "$ac_cv_prog_DLLTOOL_FOR_TARGET"; then
- DLLTOOL_FOR_TARGET=$ac_cv_prog_DLLTOOL_FOR_TARGET
-fi
-
-if test -n "$ac_cv_prog_DLLTOOL_FOR_TARGET"; then
- for ncn_progname in dlltool; do
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_DLLTOOL_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$DLLTOOL_FOR_TARGET"; then
- ac_cv_prog_DLLTOOL_FOR_TARGET="$DLLTOOL_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_DLLTOOL_FOR_TARGET="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-DLLTOOL_FOR_TARGET=$ac_cv_prog_DLLTOOL_FOR_TARGET
-if test -n "$DLLTOOL_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL_FOR_TARGET" >&5
-$as_echo "$DLLTOOL_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- done
-fi
-
-if test -z "$ac_cv_prog_DLLTOOL_FOR_TARGET" && test -n "$with_build_time_tools"; then
- for ncn_progname in dlltool; do
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
-$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
- if test -x $with_build_time_tools/${ncn_progname}; then
- ac_cv_prog_DLLTOOL_FOR_TARGET=$with_build_time_tools/${ncn_progname}
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- break
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- fi
- done
-fi
-
-if test -z "$ac_cv_prog_DLLTOOL_FOR_TARGET"; then
- for ncn_progname in dlltool; do
- if test -n "$ncn_target_tool_prefix"; then
- # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_DLLTOOL_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$DLLTOOL_FOR_TARGET"; then
- ac_cv_prog_DLLTOOL_FOR_TARGET="$DLLTOOL_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_DLLTOOL_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-DLLTOOL_FOR_TARGET=$ac_cv_prog_DLLTOOL_FOR_TARGET
-if test -n "$DLLTOOL_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL_FOR_TARGET" >&5
-$as_echo "$DLLTOOL_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- if test -z "$ac_cv_prog_DLLTOOL_FOR_TARGET" && test $build = $target ; then
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_DLLTOOL_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$DLLTOOL_FOR_TARGET"; then
- ac_cv_prog_DLLTOOL_FOR_TARGET="$DLLTOOL_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_DLLTOOL_FOR_TARGET="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-DLLTOOL_FOR_TARGET=$ac_cv_prog_DLLTOOL_FOR_TARGET
-if test -n "$DLLTOOL_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DLLTOOL_FOR_TARGET" >&5
-$as_echo "$DLLTOOL_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- test -n "$ac_cv_prog_DLLTOOL_FOR_TARGET" && break
- done
-fi
-
-if test -z "$ac_cv_prog_DLLTOOL_FOR_TARGET" ; then
- set dummy dlltool
- if test $build = $target ; then
- DLLTOOL_FOR_TARGET="$2"
- else
- DLLTOOL_FOR_TARGET="${ncn_target_tool_prefix}$2"
- fi
-else
- DLLTOOL_FOR_TARGET="$ac_cv_prog_DLLTOOL_FOR_TARGET"
-fi
-
-else
- DLLTOOL_FOR_TARGET=$ac_cv_path_DLLTOOL_FOR_TARGET
-fi
-
-
-
-
-if test -z "$ac_cv_path_DSYMUTIL_FOR_TARGET" ; then
- if test -n "$with_build_time_tools"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dsymutil in $with_build_time_tools" >&5
-$as_echo_n "checking for dsymutil in $with_build_time_tools... " >&6; }
- if test -x $with_build_time_tools/dsymutil; then
- DSYMUTIL_FOR_TARGET=`cd $with_build_time_tools && pwd`/dsymutil
- ac_cv_path_DSYMUTIL_FOR_TARGET=$DSYMUTIL_FOR_TARGET
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_DSYMUTIL_FOR_TARGET" >&5
-$as_echo "$ac_cv_path_DSYMUTIL_FOR_TARGET" >&6; }
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- fi
- elif test $build != $host && test $have_gcc_for_target = yes; then
- DSYMUTIL_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=dsymutil`
- test $DSYMUTIL_FOR_TARGET = dsymutil && DSYMUTIL_FOR_TARGET=
- test -n "$DSYMUTIL_FOR_TARGET" && ac_cv_path_DSYMUTIL_FOR_TARGET=$DSYMUTIL_FOR_TARGET
- fi
-fi
-if test -z "$ac_cv_path_DSYMUTIL_FOR_TARGET" && test -n "$gcc_cv_tool_dirs"; then
- # Extract the first word of "dsymutil", so it can be a program name with args.
-set dummy dsymutil; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_DSYMUTIL_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $DSYMUTIL_FOR_TARGET in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_DSYMUTIL_FOR_TARGET="$DSYMUTIL_FOR_TARGET" # Let the user override the test with a path.
- ;;
- *)
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $gcc_cv_tool_dirs
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_path_DSYMUTIL_FOR_TARGET="$as_dir/$ac_word$ac_exec_ext"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
- ;;
-esac
-fi
-DSYMUTIL_FOR_TARGET=$ac_cv_path_DSYMUTIL_FOR_TARGET
-if test -n "$DSYMUTIL_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL_FOR_TARGET" >&5
-$as_echo "$DSYMUTIL_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_path_DSYMUTIL_FOR_TARGET" ; then
-
-
-if test -n "$DSYMUTIL_FOR_TARGET"; then
- ac_cv_prog_DSYMUTIL_FOR_TARGET=$DSYMUTIL_FOR_TARGET
-elif test -n "$ac_cv_prog_DSYMUTIL_FOR_TARGET"; then
- DSYMUTIL_FOR_TARGET=$ac_cv_prog_DSYMUTIL_FOR_TARGET
-fi
-
-if test -n "$ac_cv_prog_DSYMUTIL_FOR_TARGET"; then
- for ncn_progname in dsymutil; do
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_DSYMUTIL_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$DSYMUTIL_FOR_TARGET"; then
- ac_cv_prog_DSYMUTIL_FOR_TARGET="$DSYMUTIL_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_DSYMUTIL_FOR_TARGET="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-DSYMUTIL_FOR_TARGET=$ac_cv_prog_DSYMUTIL_FOR_TARGET
-if test -n "$DSYMUTIL_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL_FOR_TARGET" >&5
-$as_echo "$DSYMUTIL_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- done
-fi
-
-if test -z "$ac_cv_prog_DSYMUTIL_FOR_TARGET" && test -n "$with_build_time_tools"; then
- for ncn_progname in dsymutil; do
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
-$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
- if test -x $with_build_time_tools/${ncn_progname}; then
- ac_cv_prog_DSYMUTIL_FOR_TARGET=$with_build_time_tools/${ncn_progname}
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- break
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- fi
- done
-fi
-
-if test -z "$ac_cv_prog_DSYMUTIL_FOR_TARGET"; then
- for ncn_progname in dsymutil; do
- if test -n "$ncn_target_tool_prefix"; then
- # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_DSYMUTIL_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$DSYMUTIL_FOR_TARGET"; then
- ac_cv_prog_DSYMUTIL_FOR_TARGET="$DSYMUTIL_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_DSYMUTIL_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-DSYMUTIL_FOR_TARGET=$ac_cv_prog_DSYMUTIL_FOR_TARGET
-if test -n "$DSYMUTIL_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL_FOR_TARGET" >&5
-$as_echo "$DSYMUTIL_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- if test -z "$ac_cv_prog_DSYMUTIL_FOR_TARGET" && test $build = $target ; then
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_DSYMUTIL_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$DSYMUTIL_FOR_TARGET"; then
- ac_cv_prog_DSYMUTIL_FOR_TARGET="$DSYMUTIL_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_DSYMUTIL_FOR_TARGET="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-DSYMUTIL_FOR_TARGET=$ac_cv_prog_DSYMUTIL_FOR_TARGET
-if test -n "$DSYMUTIL_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL_FOR_TARGET" >&5
-$as_echo "$DSYMUTIL_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- test -n "$ac_cv_prog_DSYMUTIL_FOR_TARGET" && break
- done
-fi
-
-if test -z "$ac_cv_prog_DSYMUTIL_FOR_TARGET" ; then
- set dummy dsymutil
- if test $build = $target ; then
- DSYMUTIL_FOR_TARGET="$2"
- else
- DSYMUTIL_FOR_TARGET="${ncn_target_tool_prefix}$2"
- fi
-else
- DSYMUTIL_FOR_TARGET="$ac_cv_prog_DSYMUTIL_FOR_TARGET"
-fi
-
-else
- DSYMUTIL_FOR_TARGET=$ac_cv_path_DSYMUTIL_FOR_TARGET
-fi
-
-
-
-
-if test -z "$ac_cv_path_LD_FOR_TARGET" ; then
- if test -n "$with_build_time_tools"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld in $with_build_time_tools" >&5
-$as_echo_n "checking for ld in $with_build_time_tools... " >&6; }
- if test -x $with_build_time_tools/ld; then
- LD_FOR_TARGET=`cd $with_build_time_tools && pwd`/ld
- ac_cv_path_LD_FOR_TARGET=$LD_FOR_TARGET
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_LD_FOR_TARGET" >&5
-$as_echo "$ac_cv_path_LD_FOR_TARGET" >&6; }
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- fi
- elif test $build != $host && test $have_gcc_for_target = yes; then
- LD_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=ld`
- test $LD_FOR_TARGET = ld && LD_FOR_TARGET=
- test -n "$LD_FOR_TARGET" && ac_cv_path_LD_FOR_TARGET=$LD_FOR_TARGET
- fi
-fi
-if test -z "$ac_cv_path_LD_FOR_TARGET" && test -n "$gcc_cv_tool_dirs"; then
- # Extract the first word of "ld", so it can be a program name with args.
-set dummy ld; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_LD_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $LD_FOR_TARGET in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_LD_FOR_TARGET="$LD_FOR_TARGET" # Let the user override the test with a path.
- ;;
- *)
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $gcc_cv_tool_dirs
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_path_LD_FOR_TARGET="$as_dir/$ac_word$ac_exec_ext"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
- ;;
-esac
-fi
-LD_FOR_TARGET=$ac_cv_path_LD_FOR_TARGET
-if test -n "$LD_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD_FOR_TARGET" >&5
-$as_echo "$LD_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_path_LD_FOR_TARGET" ; then
-
-
-if test -n "$LD_FOR_TARGET"; then
- ac_cv_prog_LD_FOR_TARGET=$LD_FOR_TARGET
-elif test -n "$ac_cv_prog_LD_FOR_TARGET"; then
- LD_FOR_TARGET=$ac_cv_prog_LD_FOR_TARGET
-fi
-
-if test -n "$ac_cv_prog_LD_FOR_TARGET"; then
- for ncn_progname in ld; do
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_LD_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$LD_FOR_TARGET"; then
- ac_cv_prog_LD_FOR_TARGET="$LD_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_LD_FOR_TARGET="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-LD_FOR_TARGET=$ac_cv_prog_LD_FOR_TARGET
-if test -n "$LD_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD_FOR_TARGET" >&5
-$as_echo "$LD_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- done
-fi
-
-if test -z "$ac_cv_prog_LD_FOR_TARGET" && test -n "$with_build_time_tools"; then
- for ncn_progname in ld; do
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
-$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
- if test -x $with_build_time_tools/${ncn_progname}; then
- ac_cv_prog_LD_FOR_TARGET=$with_build_time_tools/${ncn_progname}
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- break
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- fi
- done
-fi
-
-if test -z "$ac_cv_prog_LD_FOR_TARGET"; then
- for ncn_progname in ld; do
- if test -n "$ncn_target_tool_prefix"; then
- # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_LD_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$LD_FOR_TARGET"; then
- ac_cv_prog_LD_FOR_TARGET="$LD_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_LD_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-LD_FOR_TARGET=$ac_cv_prog_LD_FOR_TARGET
-if test -n "$LD_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD_FOR_TARGET" >&5
-$as_echo "$LD_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- if test -z "$ac_cv_prog_LD_FOR_TARGET" && test $build = $target ; then
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_LD_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$LD_FOR_TARGET"; then
- ac_cv_prog_LD_FOR_TARGET="$LD_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_LD_FOR_TARGET="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-LD_FOR_TARGET=$ac_cv_prog_LD_FOR_TARGET
-if test -n "$LD_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD_FOR_TARGET" >&5
-$as_echo "$LD_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- test -n "$ac_cv_prog_LD_FOR_TARGET" && break
- done
-fi
-
-if test -z "$ac_cv_prog_LD_FOR_TARGET" ; then
- set dummy ld
- if test $build = $target ; then
- LD_FOR_TARGET="$2"
- else
- LD_FOR_TARGET="${ncn_target_tool_prefix}$2"
- fi
-else
- LD_FOR_TARGET="$ac_cv_prog_LD_FOR_TARGET"
-fi
-
-else
- LD_FOR_TARGET=$ac_cv_path_LD_FOR_TARGET
-fi
-
-
-
-
-if test -z "$ac_cv_path_LIPO_FOR_TARGET" ; then
- if test -n "$with_build_time_tools"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lipo in $with_build_time_tools" >&5
-$as_echo_n "checking for lipo in $with_build_time_tools... " >&6; }
- if test -x $with_build_time_tools/lipo; then
- LIPO_FOR_TARGET=`cd $with_build_time_tools && pwd`/lipo
- ac_cv_path_LIPO_FOR_TARGET=$LIPO_FOR_TARGET
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_LIPO_FOR_TARGET" >&5
-$as_echo "$ac_cv_path_LIPO_FOR_TARGET" >&6; }
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- fi
- elif test $build != $host && test $have_gcc_for_target = yes; then
- LIPO_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=lipo`
- test $LIPO_FOR_TARGET = lipo && LIPO_FOR_TARGET=
- test -n "$LIPO_FOR_TARGET" && ac_cv_path_LIPO_FOR_TARGET=$LIPO_FOR_TARGET
- fi
-fi
-if test -z "$ac_cv_path_LIPO_FOR_TARGET" && test -n "$gcc_cv_tool_dirs"; then
- # Extract the first word of "lipo", so it can be a program name with args.
-set dummy lipo; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_LIPO_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $LIPO_FOR_TARGET in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_LIPO_FOR_TARGET="$LIPO_FOR_TARGET" # Let the user override the test with a path.
- ;;
- *)
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $gcc_cv_tool_dirs
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_path_LIPO_FOR_TARGET="$as_dir/$ac_word$ac_exec_ext"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
- ;;
-esac
-fi
-LIPO_FOR_TARGET=$ac_cv_path_LIPO_FOR_TARGET
-if test -n "$LIPO_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO_FOR_TARGET" >&5
-$as_echo "$LIPO_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_path_LIPO_FOR_TARGET" ; then
-
-
-if test -n "$LIPO_FOR_TARGET"; then
- ac_cv_prog_LIPO_FOR_TARGET=$LIPO_FOR_TARGET
-elif test -n "$ac_cv_prog_LIPO_FOR_TARGET"; then
- LIPO_FOR_TARGET=$ac_cv_prog_LIPO_FOR_TARGET
-fi
-
-if test -n "$ac_cv_prog_LIPO_FOR_TARGET"; then
- for ncn_progname in lipo; do
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_LIPO_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$LIPO_FOR_TARGET"; then
- ac_cv_prog_LIPO_FOR_TARGET="$LIPO_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_LIPO_FOR_TARGET="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-LIPO_FOR_TARGET=$ac_cv_prog_LIPO_FOR_TARGET
-if test -n "$LIPO_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO_FOR_TARGET" >&5
-$as_echo "$LIPO_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- done
-fi
-
-if test -z "$ac_cv_prog_LIPO_FOR_TARGET" && test -n "$with_build_time_tools"; then
- for ncn_progname in lipo; do
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
-$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
- if test -x $with_build_time_tools/${ncn_progname}; then
- ac_cv_prog_LIPO_FOR_TARGET=$with_build_time_tools/${ncn_progname}
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- break
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- fi
- done
-fi
-
-if test -z "$ac_cv_prog_LIPO_FOR_TARGET"; then
- for ncn_progname in lipo; do
- if test -n "$ncn_target_tool_prefix"; then
- # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_LIPO_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$LIPO_FOR_TARGET"; then
- ac_cv_prog_LIPO_FOR_TARGET="$LIPO_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_LIPO_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-LIPO_FOR_TARGET=$ac_cv_prog_LIPO_FOR_TARGET
-if test -n "$LIPO_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO_FOR_TARGET" >&5
-$as_echo "$LIPO_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- if test -z "$ac_cv_prog_LIPO_FOR_TARGET" && test $build = $target ; then
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_LIPO_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$LIPO_FOR_TARGET"; then
- ac_cv_prog_LIPO_FOR_TARGET="$LIPO_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_LIPO_FOR_TARGET="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-LIPO_FOR_TARGET=$ac_cv_prog_LIPO_FOR_TARGET
-if test -n "$LIPO_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO_FOR_TARGET" >&5
-$as_echo "$LIPO_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- test -n "$ac_cv_prog_LIPO_FOR_TARGET" && break
- done
-fi
-
-if test -z "$ac_cv_prog_LIPO_FOR_TARGET" ; then
- set dummy lipo
- if test $build = $target ; then
- LIPO_FOR_TARGET="$2"
- else
- LIPO_FOR_TARGET="${ncn_target_tool_prefix}$2"
- fi
-else
- LIPO_FOR_TARGET="$ac_cv_prog_LIPO_FOR_TARGET"
-fi
-
-else
- LIPO_FOR_TARGET=$ac_cv_path_LIPO_FOR_TARGET
-fi
-
-
-
-
-if test -z "$ac_cv_path_NM_FOR_TARGET" ; then
- if test -n "$with_build_time_tools"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nm in $with_build_time_tools" >&5
-$as_echo_n "checking for nm in $with_build_time_tools... " >&6; }
- if test -x $with_build_time_tools/nm; then
- NM_FOR_TARGET=`cd $with_build_time_tools && pwd`/nm
- ac_cv_path_NM_FOR_TARGET=$NM_FOR_TARGET
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_NM_FOR_TARGET" >&5
-$as_echo "$ac_cv_path_NM_FOR_TARGET" >&6; }
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- fi
- elif test $build != $host && test $have_gcc_for_target = yes; then
- NM_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=nm`
- test $NM_FOR_TARGET = nm && NM_FOR_TARGET=
- test -n "$NM_FOR_TARGET" && ac_cv_path_NM_FOR_TARGET=$NM_FOR_TARGET
- fi
-fi
-if test -z "$ac_cv_path_NM_FOR_TARGET" && test -n "$gcc_cv_tool_dirs"; then
- # Extract the first word of "nm", so it can be a program name with args.
-set dummy nm; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_NM_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $NM_FOR_TARGET in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_NM_FOR_TARGET="$NM_FOR_TARGET" # Let the user override the test with a path.
- ;;
- *)
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $gcc_cv_tool_dirs
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_path_NM_FOR_TARGET="$as_dir/$ac_word$ac_exec_ext"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
- ;;
-esac
-fi
-NM_FOR_TARGET=$ac_cv_path_NM_FOR_TARGET
-if test -n "$NM_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM_FOR_TARGET" >&5
-$as_echo "$NM_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_path_NM_FOR_TARGET" ; then
-
-
-if test -n "$NM_FOR_TARGET"; then
- ac_cv_prog_NM_FOR_TARGET=$NM_FOR_TARGET
-elif test -n "$ac_cv_prog_NM_FOR_TARGET"; then
- NM_FOR_TARGET=$ac_cv_prog_NM_FOR_TARGET
-fi
-
-if test -n "$ac_cv_prog_NM_FOR_TARGET"; then
- for ncn_progname in nm; do
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_NM_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$NM_FOR_TARGET"; then
- ac_cv_prog_NM_FOR_TARGET="$NM_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_NM_FOR_TARGET="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-NM_FOR_TARGET=$ac_cv_prog_NM_FOR_TARGET
-if test -n "$NM_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM_FOR_TARGET" >&5
-$as_echo "$NM_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- done
-fi
-
-if test -z "$ac_cv_prog_NM_FOR_TARGET" && test -n "$with_build_time_tools"; then
- for ncn_progname in nm; do
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
-$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
- if test -x $with_build_time_tools/${ncn_progname}; then
- ac_cv_prog_NM_FOR_TARGET=$with_build_time_tools/${ncn_progname}
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- break
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- fi
- done
-fi
-
-if test -z "$ac_cv_prog_NM_FOR_TARGET"; then
- for ncn_progname in nm; do
- if test -n "$ncn_target_tool_prefix"; then
- # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_NM_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$NM_FOR_TARGET"; then
- ac_cv_prog_NM_FOR_TARGET="$NM_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_NM_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-NM_FOR_TARGET=$ac_cv_prog_NM_FOR_TARGET
-if test -n "$NM_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM_FOR_TARGET" >&5
-$as_echo "$NM_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- if test -z "$ac_cv_prog_NM_FOR_TARGET" && test $build = $target ; then
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_NM_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$NM_FOR_TARGET"; then
- ac_cv_prog_NM_FOR_TARGET="$NM_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_NM_FOR_TARGET="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-NM_FOR_TARGET=$ac_cv_prog_NM_FOR_TARGET
-if test -n "$NM_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM_FOR_TARGET" >&5
-$as_echo "$NM_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- test -n "$ac_cv_prog_NM_FOR_TARGET" && break
- done
-fi
-
-if test -z "$ac_cv_prog_NM_FOR_TARGET" ; then
- set dummy nm
- if test $build = $target ; then
- NM_FOR_TARGET="$2"
- else
- NM_FOR_TARGET="${ncn_target_tool_prefix}$2"
- fi
-else
- NM_FOR_TARGET="$ac_cv_prog_NM_FOR_TARGET"
-fi
-
-else
- NM_FOR_TARGET=$ac_cv_path_NM_FOR_TARGET
-fi
-
-
-
-
-if test -z "$ac_cv_path_OBJCOPY_FOR_TARGET" ; then
- if test -n "$with_build_time_tools"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for objcopy in $with_build_time_tools" >&5
-$as_echo_n "checking for objcopy in $with_build_time_tools... " >&6; }
- if test -x $with_build_time_tools/objcopy; then
- OBJCOPY_FOR_TARGET=`cd $with_build_time_tools && pwd`/objcopy
- ac_cv_path_OBJCOPY_FOR_TARGET=$OBJCOPY_FOR_TARGET
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_OBJCOPY_FOR_TARGET" >&5
-$as_echo "$ac_cv_path_OBJCOPY_FOR_TARGET" >&6; }
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- fi
- elif test $build != $host && test $have_gcc_for_target = yes; then
- OBJCOPY_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=objcopy`
- test $OBJCOPY_FOR_TARGET = objcopy && OBJCOPY_FOR_TARGET=
- test -n "$OBJCOPY_FOR_TARGET" && ac_cv_path_OBJCOPY_FOR_TARGET=$OBJCOPY_FOR_TARGET
- fi
-fi
-if test -z "$ac_cv_path_OBJCOPY_FOR_TARGET" && test -n "$gcc_cv_tool_dirs"; then
- # Extract the first word of "objcopy", so it can be a program name with args.
-set dummy objcopy; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_OBJCOPY_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $OBJCOPY_FOR_TARGET in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_OBJCOPY_FOR_TARGET="$OBJCOPY_FOR_TARGET" # Let the user override the test with a path.
- ;;
- *)
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $gcc_cv_tool_dirs
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_path_OBJCOPY_FOR_TARGET="$as_dir/$ac_word$ac_exec_ext"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
- ;;
-esac
-fi
-OBJCOPY_FOR_TARGET=$ac_cv_path_OBJCOPY_FOR_TARGET
-if test -n "$OBJCOPY_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY_FOR_TARGET" >&5
-$as_echo "$OBJCOPY_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_path_OBJCOPY_FOR_TARGET" ; then
-
-
-if test -n "$OBJCOPY_FOR_TARGET"; then
- ac_cv_prog_OBJCOPY_FOR_TARGET=$OBJCOPY_FOR_TARGET
-elif test -n "$ac_cv_prog_OBJCOPY_FOR_TARGET"; then
- OBJCOPY_FOR_TARGET=$ac_cv_prog_OBJCOPY_FOR_TARGET
-fi
-
-if test -n "$ac_cv_prog_OBJCOPY_FOR_TARGET"; then
- for ncn_progname in objcopy; do
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_OBJCOPY_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$OBJCOPY_FOR_TARGET"; then
- ac_cv_prog_OBJCOPY_FOR_TARGET="$OBJCOPY_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_OBJCOPY_FOR_TARGET="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-OBJCOPY_FOR_TARGET=$ac_cv_prog_OBJCOPY_FOR_TARGET
-if test -n "$OBJCOPY_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY_FOR_TARGET" >&5
-$as_echo "$OBJCOPY_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- done
-fi
-
-if test -z "$ac_cv_prog_OBJCOPY_FOR_TARGET" && test -n "$with_build_time_tools"; then
- for ncn_progname in objcopy; do
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
-$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
- if test -x $with_build_time_tools/${ncn_progname}; then
- ac_cv_prog_OBJCOPY_FOR_TARGET=$with_build_time_tools/${ncn_progname}
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- break
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- fi
- done
-fi
-
-if test -z "$ac_cv_prog_OBJCOPY_FOR_TARGET"; then
- for ncn_progname in objcopy; do
- if test -n "$ncn_target_tool_prefix"; then
- # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_OBJCOPY_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$OBJCOPY_FOR_TARGET"; then
- ac_cv_prog_OBJCOPY_FOR_TARGET="$OBJCOPY_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_OBJCOPY_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-OBJCOPY_FOR_TARGET=$ac_cv_prog_OBJCOPY_FOR_TARGET
-if test -n "$OBJCOPY_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY_FOR_TARGET" >&5
-$as_echo "$OBJCOPY_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- if test -z "$ac_cv_prog_OBJCOPY_FOR_TARGET" && test $build = $target ; then
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_OBJCOPY_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$OBJCOPY_FOR_TARGET"; then
- ac_cv_prog_OBJCOPY_FOR_TARGET="$OBJCOPY_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_OBJCOPY_FOR_TARGET="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-OBJCOPY_FOR_TARGET=$ac_cv_prog_OBJCOPY_FOR_TARGET
-if test -n "$OBJCOPY_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY_FOR_TARGET" >&5
-$as_echo "$OBJCOPY_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- test -n "$ac_cv_prog_OBJCOPY_FOR_TARGET" && break
- done
-fi
-
-if test -z "$ac_cv_prog_OBJCOPY_FOR_TARGET" ; then
- set dummy objcopy
- if test $build = $target ; then
- OBJCOPY_FOR_TARGET="$2"
- else
- OBJCOPY_FOR_TARGET="${ncn_target_tool_prefix}$2"
- fi
-else
- OBJCOPY_FOR_TARGET="$ac_cv_prog_OBJCOPY_FOR_TARGET"
-fi
-
-else
- OBJCOPY_FOR_TARGET=$ac_cv_path_OBJCOPY_FOR_TARGET
-fi
-
-
-
-
-if test -z "$ac_cv_path_OBJDUMP_FOR_TARGET" ; then
- if test -n "$with_build_time_tools"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for objdump in $with_build_time_tools" >&5
-$as_echo_n "checking for objdump in $with_build_time_tools... " >&6; }
- if test -x $with_build_time_tools/objdump; then
- OBJDUMP_FOR_TARGET=`cd $with_build_time_tools && pwd`/objdump
- ac_cv_path_OBJDUMP_FOR_TARGET=$OBJDUMP_FOR_TARGET
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_OBJDUMP_FOR_TARGET" >&5
-$as_echo "$ac_cv_path_OBJDUMP_FOR_TARGET" >&6; }
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- fi
- elif test $build != $host && test $have_gcc_for_target = yes; then
- OBJDUMP_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=objdump`
- test $OBJDUMP_FOR_TARGET = objdump && OBJDUMP_FOR_TARGET=
- test -n "$OBJDUMP_FOR_TARGET" && ac_cv_path_OBJDUMP_FOR_TARGET=$OBJDUMP_FOR_TARGET
- fi
-fi
-if test -z "$ac_cv_path_OBJDUMP_FOR_TARGET" && test -n "$gcc_cv_tool_dirs"; then
- # Extract the first word of "objdump", so it can be a program name with args.
-set dummy objdump; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_OBJDUMP_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $OBJDUMP_FOR_TARGET in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_OBJDUMP_FOR_TARGET="$OBJDUMP_FOR_TARGET" # Let the user override the test with a path.
- ;;
- *)
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $gcc_cv_tool_dirs
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_path_OBJDUMP_FOR_TARGET="$as_dir/$ac_word$ac_exec_ext"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
- ;;
-esac
-fi
-OBJDUMP_FOR_TARGET=$ac_cv_path_OBJDUMP_FOR_TARGET
-if test -n "$OBJDUMP_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP_FOR_TARGET" >&5
-$as_echo "$OBJDUMP_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_path_OBJDUMP_FOR_TARGET" ; then
-
-
-if test -n "$OBJDUMP_FOR_TARGET"; then
- ac_cv_prog_OBJDUMP_FOR_TARGET=$OBJDUMP_FOR_TARGET
-elif test -n "$ac_cv_prog_OBJDUMP_FOR_TARGET"; then
- OBJDUMP_FOR_TARGET=$ac_cv_prog_OBJDUMP_FOR_TARGET
-fi
-
-if test -n "$ac_cv_prog_OBJDUMP_FOR_TARGET"; then
- for ncn_progname in objdump; do
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_OBJDUMP_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$OBJDUMP_FOR_TARGET"; then
- ac_cv_prog_OBJDUMP_FOR_TARGET="$OBJDUMP_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_OBJDUMP_FOR_TARGET="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-OBJDUMP_FOR_TARGET=$ac_cv_prog_OBJDUMP_FOR_TARGET
-if test -n "$OBJDUMP_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP_FOR_TARGET" >&5
-$as_echo "$OBJDUMP_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- done
-fi
-
-if test -z "$ac_cv_prog_OBJDUMP_FOR_TARGET" && test -n "$with_build_time_tools"; then
- for ncn_progname in objdump; do
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
-$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
- if test -x $with_build_time_tools/${ncn_progname}; then
- ac_cv_prog_OBJDUMP_FOR_TARGET=$with_build_time_tools/${ncn_progname}
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- break
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- fi
- done
-fi
-
-if test -z "$ac_cv_prog_OBJDUMP_FOR_TARGET"; then
- for ncn_progname in objdump; do
- if test -n "$ncn_target_tool_prefix"; then
- # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_OBJDUMP_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$OBJDUMP_FOR_TARGET"; then
- ac_cv_prog_OBJDUMP_FOR_TARGET="$OBJDUMP_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_OBJDUMP_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-OBJDUMP_FOR_TARGET=$ac_cv_prog_OBJDUMP_FOR_TARGET
-if test -n "$OBJDUMP_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP_FOR_TARGET" >&5
-$as_echo "$OBJDUMP_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- if test -z "$ac_cv_prog_OBJDUMP_FOR_TARGET" && test $build = $target ; then
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_OBJDUMP_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$OBJDUMP_FOR_TARGET"; then
- ac_cv_prog_OBJDUMP_FOR_TARGET="$OBJDUMP_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_OBJDUMP_FOR_TARGET="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-OBJDUMP_FOR_TARGET=$ac_cv_prog_OBJDUMP_FOR_TARGET
-if test -n "$OBJDUMP_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP_FOR_TARGET" >&5
-$as_echo "$OBJDUMP_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- test -n "$ac_cv_prog_OBJDUMP_FOR_TARGET" && break
- done
-fi
-
-if test -z "$ac_cv_prog_OBJDUMP_FOR_TARGET" ; then
- set dummy objdump
- if test $build = $target ; then
- OBJDUMP_FOR_TARGET="$2"
- else
- OBJDUMP_FOR_TARGET="${ncn_target_tool_prefix}$2"
- fi
-else
- OBJDUMP_FOR_TARGET="$ac_cv_prog_OBJDUMP_FOR_TARGET"
-fi
-
-else
- OBJDUMP_FOR_TARGET=$ac_cv_path_OBJDUMP_FOR_TARGET
-fi
-
-
-
-
-if test -z "$ac_cv_path_OTOOL_FOR_TARGET" ; then
- if test -n "$with_build_time_tools"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for otool in $with_build_time_tools" >&5
-$as_echo_n "checking for otool in $with_build_time_tools... " >&6; }
- if test -x $with_build_time_tools/otool; then
- OTOOL_FOR_TARGET=`cd $with_build_time_tools && pwd`/otool
- ac_cv_path_OTOOL_FOR_TARGET=$OTOOL_FOR_TARGET
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_OTOOL_FOR_TARGET" >&5
-$as_echo "$ac_cv_path_OTOOL_FOR_TARGET" >&6; }
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- fi
- elif test $build != $host && test $have_gcc_for_target = yes; then
- OTOOL_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=otool`
- test $OTOOL_FOR_TARGET = otool && OTOOL_FOR_TARGET=
- test -n "$OTOOL_FOR_TARGET" && ac_cv_path_OTOOL_FOR_TARGET=$OTOOL_FOR_TARGET
- fi
-fi
-if test -z "$ac_cv_path_OTOOL_FOR_TARGET" && test -n "$gcc_cv_tool_dirs"; then
- # Extract the first word of "otool", so it can be a program name with args.
-set dummy otool; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_OTOOL_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $OTOOL_FOR_TARGET in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_OTOOL_FOR_TARGET="$OTOOL_FOR_TARGET" # Let the user override the test with a path.
- ;;
- *)
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $gcc_cv_tool_dirs
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_path_OTOOL_FOR_TARGET="$as_dir/$ac_word$ac_exec_ext"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
- ;;
-esac
-fi
-OTOOL_FOR_TARGET=$ac_cv_path_OTOOL_FOR_TARGET
-if test -n "$OTOOL_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL_FOR_TARGET" >&5
-$as_echo "$OTOOL_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_path_OTOOL_FOR_TARGET" ; then
-
-
-if test -n "$OTOOL_FOR_TARGET"; then
- ac_cv_prog_OTOOL_FOR_TARGET=$OTOOL_FOR_TARGET
-elif test -n "$ac_cv_prog_OTOOL_FOR_TARGET"; then
- OTOOL_FOR_TARGET=$ac_cv_prog_OTOOL_FOR_TARGET
-fi
-
-if test -n "$ac_cv_prog_OTOOL_FOR_TARGET"; then
- for ncn_progname in otool; do
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_OTOOL_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$OTOOL_FOR_TARGET"; then
- ac_cv_prog_OTOOL_FOR_TARGET="$OTOOL_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_OTOOL_FOR_TARGET="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-OTOOL_FOR_TARGET=$ac_cv_prog_OTOOL_FOR_TARGET
-if test -n "$OTOOL_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL_FOR_TARGET" >&5
-$as_echo "$OTOOL_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- done
-fi
-
-if test -z "$ac_cv_prog_OTOOL_FOR_TARGET" && test -n "$with_build_time_tools"; then
- for ncn_progname in otool; do
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
-$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
- if test -x $with_build_time_tools/${ncn_progname}; then
- ac_cv_prog_OTOOL_FOR_TARGET=$with_build_time_tools/${ncn_progname}
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- break
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- fi
- done
-fi
-
-if test -z "$ac_cv_prog_OTOOL_FOR_TARGET"; then
- for ncn_progname in otool; do
- if test -n "$ncn_target_tool_prefix"; then
- # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_OTOOL_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$OTOOL_FOR_TARGET"; then
- ac_cv_prog_OTOOL_FOR_TARGET="$OTOOL_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_OTOOL_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-OTOOL_FOR_TARGET=$ac_cv_prog_OTOOL_FOR_TARGET
-if test -n "$OTOOL_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL_FOR_TARGET" >&5
-$as_echo "$OTOOL_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- if test -z "$ac_cv_prog_OTOOL_FOR_TARGET" && test $build = $target ; then
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_OTOOL_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$OTOOL_FOR_TARGET"; then
- ac_cv_prog_OTOOL_FOR_TARGET="$OTOOL_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_OTOOL_FOR_TARGET="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-OTOOL_FOR_TARGET=$ac_cv_prog_OTOOL_FOR_TARGET
-if test -n "$OTOOL_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL_FOR_TARGET" >&5
-$as_echo "$OTOOL_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- test -n "$ac_cv_prog_OTOOL_FOR_TARGET" && break
- done
-fi
-
-if test -z "$ac_cv_prog_OTOOL_FOR_TARGET" ; then
- set dummy otool
- if test $build = $target ; then
- OTOOL_FOR_TARGET="$2"
- else
- OTOOL_FOR_TARGET="${ncn_target_tool_prefix}$2"
- fi
-else
- OTOOL_FOR_TARGET="$ac_cv_prog_OTOOL_FOR_TARGET"
-fi
-
-else
- OTOOL_FOR_TARGET=$ac_cv_path_OTOOL_FOR_TARGET
-fi
-
-
-
-
-if test -z "$ac_cv_path_RANLIB_FOR_TARGET" ; then
- if test -n "$with_build_time_tools"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ranlib in $with_build_time_tools" >&5
-$as_echo_n "checking for ranlib in $with_build_time_tools... " >&6; }
- if test -x $with_build_time_tools/ranlib; then
- RANLIB_FOR_TARGET=`cd $with_build_time_tools && pwd`/ranlib
- ac_cv_path_RANLIB_FOR_TARGET=$RANLIB_FOR_TARGET
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_RANLIB_FOR_TARGET" >&5
-$as_echo "$ac_cv_path_RANLIB_FOR_TARGET" >&6; }
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- fi
- elif test $build != $host && test $have_gcc_for_target = yes; then
- RANLIB_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=ranlib`
- test $RANLIB_FOR_TARGET = ranlib && RANLIB_FOR_TARGET=
- test -n "$RANLIB_FOR_TARGET" && ac_cv_path_RANLIB_FOR_TARGET=$RANLIB_FOR_TARGET
- fi
-fi
-if test -z "$ac_cv_path_RANLIB_FOR_TARGET" && test -n "$gcc_cv_tool_dirs"; then
- # Extract the first word of "ranlib", so it can be a program name with args.
-set dummy ranlib; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_RANLIB_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $RANLIB_FOR_TARGET in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_RANLIB_FOR_TARGET="$RANLIB_FOR_TARGET" # Let the user override the test with a path.
- ;;
- *)
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $gcc_cv_tool_dirs
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_path_RANLIB_FOR_TARGET="$as_dir/$ac_word$ac_exec_ext"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
- ;;
-esac
-fi
-RANLIB_FOR_TARGET=$ac_cv_path_RANLIB_FOR_TARGET
-if test -n "$RANLIB_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB_FOR_TARGET" >&5
-$as_echo "$RANLIB_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_path_RANLIB_FOR_TARGET" ; then
-
-
-if test -n "$RANLIB_FOR_TARGET"; then
- ac_cv_prog_RANLIB_FOR_TARGET=$RANLIB_FOR_TARGET
-elif test -n "$ac_cv_prog_RANLIB_FOR_TARGET"; then
- RANLIB_FOR_TARGET=$ac_cv_prog_RANLIB_FOR_TARGET
-fi
-
-if test -n "$ac_cv_prog_RANLIB_FOR_TARGET"; then
- for ncn_progname in ranlib; do
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_RANLIB_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$RANLIB_FOR_TARGET"; then
- ac_cv_prog_RANLIB_FOR_TARGET="$RANLIB_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_RANLIB_FOR_TARGET="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-RANLIB_FOR_TARGET=$ac_cv_prog_RANLIB_FOR_TARGET
-if test -n "$RANLIB_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB_FOR_TARGET" >&5
-$as_echo "$RANLIB_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- done
-fi
-
-if test -z "$ac_cv_prog_RANLIB_FOR_TARGET" && test -n "$with_build_time_tools"; then
- for ncn_progname in ranlib; do
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
-$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
- if test -x $with_build_time_tools/${ncn_progname}; then
- ac_cv_prog_RANLIB_FOR_TARGET=$with_build_time_tools/${ncn_progname}
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- break
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- fi
- done
-fi
-
-if test -z "$ac_cv_prog_RANLIB_FOR_TARGET"; then
- for ncn_progname in ranlib; do
- if test -n "$ncn_target_tool_prefix"; then
- # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_RANLIB_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$RANLIB_FOR_TARGET"; then
- ac_cv_prog_RANLIB_FOR_TARGET="$RANLIB_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_RANLIB_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-RANLIB_FOR_TARGET=$ac_cv_prog_RANLIB_FOR_TARGET
-if test -n "$RANLIB_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB_FOR_TARGET" >&5
-$as_echo "$RANLIB_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- if test -z "$ac_cv_prog_RANLIB_FOR_TARGET" && test $build = $target ; then
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_RANLIB_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$RANLIB_FOR_TARGET"; then
- ac_cv_prog_RANLIB_FOR_TARGET="$RANLIB_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_RANLIB_FOR_TARGET="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-RANLIB_FOR_TARGET=$ac_cv_prog_RANLIB_FOR_TARGET
-if test -n "$RANLIB_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB_FOR_TARGET" >&5
-$as_echo "$RANLIB_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- test -n "$ac_cv_prog_RANLIB_FOR_TARGET" && break
- done
-fi
-
-if test -z "$ac_cv_prog_RANLIB_FOR_TARGET" ; then
- set dummy ranlib
- if test $build = $target ; then
- RANLIB_FOR_TARGET="$2"
- else
- RANLIB_FOR_TARGET="${ncn_target_tool_prefix}$2"
- fi
-else
- RANLIB_FOR_TARGET="$ac_cv_prog_RANLIB_FOR_TARGET"
-fi
-
-else
- RANLIB_FOR_TARGET=$ac_cv_path_RANLIB_FOR_TARGET
-fi
-
-
-
-
-if test -z "$ac_cv_path_READELF_FOR_TARGET" ; then
- if test -n "$with_build_time_tools"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for readelf in $with_build_time_tools" >&5
-$as_echo_n "checking for readelf in $with_build_time_tools... " >&6; }
- if test -x $with_build_time_tools/readelf; then
- READELF_FOR_TARGET=`cd $with_build_time_tools && pwd`/readelf
- ac_cv_path_READELF_FOR_TARGET=$READELF_FOR_TARGET
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_READELF_FOR_TARGET" >&5
-$as_echo "$ac_cv_path_READELF_FOR_TARGET" >&6; }
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- fi
- elif test $build != $host && test $have_gcc_for_target = yes; then
- READELF_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=readelf`
- test $READELF_FOR_TARGET = readelf && READELF_FOR_TARGET=
- test -n "$READELF_FOR_TARGET" && ac_cv_path_READELF_FOR_TARGET=$READELF_FOR_TARGET
- fi
-fi
-if test -z "$ac_cv_path_READELF_FOR_TARGET" && test -n "$gcc_cv_tool_dirs"; then
- # Extract the first word of "readelf", so it can be a program name with args.
-set dummy readelf; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_READELF_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $READELF_FOR_TARGET in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_READELF_FOR_TARGET="$READELF_FOR_TARGET" # Let the user override the test with a path.
- ;;
- *)
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $gcc_cv_tool_dirs
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_path_READELF_FOR_TARGET="$as_dir/$ac_word$ac_exec_ext"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
- ;;
-esac
-fi
-READELF_FOR_TARGET=$ac_cv_path_READELF_FOR_TARGET
-if test -n "$READELF_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF_FOR_TARGET" >&5
-$as_echo "$READELF_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_path_READELF_FOR_TARGET" ; then
-
-
-if test -n "$READELF_FOR_TARGET"; then
- ac_cv_prog_READELF_FOR_TARGET=$READELF_FOR_TARGET
-elif test -n "$ac_cv_prog_READELF_FOR_TARGET"; then
- READELF_FOR_TARGET=$ac_cv_prog_READELF_FOR_TARGET
-fi
-
-if test -n "$ac_cv_prog_READELF_FOR_TARGET"; then
- for ncn_progname in readelf; do
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_READELF_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$READELF_FOR_TARGET"; then
- ac_cv_prog_READELF_FOR_TARGET="$READELF_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_READELF_FOR_TARGET="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-READELF_FOR_TARGET=$ac_cv_prog_READELF_FOR_TARGET
-if test -n "$READELF_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF_FOR_TARGET" >&5
-$as_echo "$READELF_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- done
-fi
-
-if test -z "$ac_cv_prog_READELF_FOR_TARGET" && test -n "$with_build_time_tools"; then
- for ncn_progname in readelf; do
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
-$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
- if test -x $with_build_time_tools/${ncn_progname}; then
- ac_cv_prog_READELF_FOR_TARGET=$with_build_time_tools/${ncn_progname}
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- break
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- fi
- done
-fi
-
-if test -z "$ac_cv_prog_READELF_FOR_TARGET"; then
- for ncn_progname in readelf; do
- if test -n "$ncn_target_tool_prefix"; then
- # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_READELF_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$READELF_FOR_TARGET"; then
- ac_cv_prog_READELF_FOR_TARGET="$READELF_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_READELF_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-READELF_FOR_TARGET=$ac_cv_prog_READELF_FOR_TARGET
-if test -n "$READELF_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF_FOR_TARGET" >&5
-$as_echo "$READELF_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- if test -z "$ac_cv_prog_READELF_FOR_TARGET" && test $build = $target ; then
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_READELF_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$READELF_FOR_TARGET"; then
- ac_cv_prog_READELF_FOR_TARGET="$READELF_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_READELF_FOR_TARGET="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-READELF_FOR_TARGET=$ac_cv_prog_READELF_FOR_TARGET
-if test -n "$READELF_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF_FOR_TARGET" >&5
-$as_echo "$READELF_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- test -n "$ac_cv_prog_READELF_FOR_TARGET" && break
- done
-fi
-
-if test -z "$ac_cv_prog_READELF_FOR_TARGET" ; then
- set dummy readelf
- if test $build = $target ; then
- READELF_FOR_TARGET="$2"
- else
- READELF_FOR_TARGET="${ncn_target_tool_prefix}$2"
- fi
-else
- READELF_FOR_TARGET="$ac_cv_prog_READELF_FOR_TARGET"
-fi
-
-else
- READELF_FOR_TARGET=$ac_cv_path_READELF_FOR_TARGET
-fi
-
-
-
-
-if test -z "$ac_cv_path_STRIP_FOR_TARGET" ; then
- if test -n "$with_build_time_tools"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for strip in $with_build_time_tools" >&5
-$as_echo_n "checking for strip in $with_build_time_tools... " >&6; }
- if test -x $with_build_time_tools/strip; then
- STRIP_FOR_TARGET=`cd $with_build_time_tools && pwd`/strip
- ac_cv_path_STRIP_FOR_TARGET=$STRIP_FOR_TARGET
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_STRIP_FOR_TARGET" >&5
-$as_echo "$ac_cv_path_STRIP_FOR_TARGET" >&6; }
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- fi
- elif test $build != $host && test $have_gcc_for_target = yes; then
- STRIP_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=strip`
- test $STRIP_FOR_TARGET = strip && STRIP_FOR_TARGET=
- test -n "$STRIP_FOR_TARGET" && ac_cv_path_STRIP_FOR_TARGET=$STRIP_FOR_TARGET
- fi
-fi
-if test -z "$ac_cv_path_STRIP_FOR_TARGET" && test -n "$gcc_cv_tool_dirs"; then
- # Extract the first word of "strip", so it can be a program name with args.
-set dummy strip; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_STRIP_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $STRIP_FOR_TARGET in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_STRIP_FOR_TARGET="$STRIP_FOR_TARGET" # Let the user override the test with a path.
- ;;
- *)
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $gcc_cv_tool_dirs
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_path_STRIP_FOR_TARGET="$as_dir/$ac_word$ac_exec_ext"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
- ;;
-esac
-fi
-STRIP_FOR_TARGET=$ac_cv_path_STRIP_FOR_TARGET
-if test -n "$STRIP_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP_FOR_TARGET" >&5
-$as_echo "$STRIP_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_path_STRIP_FOR_TARGET" ; then
-
-
-if test -n "$STRIP_FOR_TARGET"; then
- ac_cv_prog_STRIP_FOR_TARGET=$STRIP_FOR_TARGET
-elif test -n "$ac_cv_prog_STRIP_FOR_TARGET"; then
- STRIP_FOR_TARGET=$ac_cv_prog_STRIP_FOR_TARGET
-fi
-
-if test -n "$ac_cv_prog_STRIP_FOR_TARGET"; then
- for ncn_progname in strip; do
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_STRIP_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$STRIP_FOR_TARGET"; then
- ac_cv_prog_STRIP_FOR_TARGET="$STRIP_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_STRIP_FOR_TARGET="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-STRIP_FOR_TARGET=$ac_cv_prog_STRIP_FOR_TARGET
-if test -n "$STRIP_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP_FOR_TARGET" >&5
-$as_echo "$STRIP_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- done
-fi
-
-if test -z "$ac_cv_prog_STRIP_FOR_TARGET" && test -n "$with_build_time_tools"; then
- for ncn_progname in strip; do
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
-$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
- if test -x $with_build_time_tools/${ncn_progname}; then
- ac_cv_prog_STRIP_FOR_TARGET=$with_build_time_tools/${ncn_progname}
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- break
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- fi
- done
-fi
-
-if test -z "$ac_cv_prog_STRIP_FOR_TARGET"; then
- for ncn_progname in strip; do
- if test -n "$ncn_target_tool_prefix"; then
- # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_STRIP_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$STRIP_FOR_TARGET"; then
- ac_cv_prog_STRIP_FOR_TARGET="$STRIP_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_STRIP_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-STRIP_FOR_TARGET=$ac_cv_prog_STRIP_FOR_TARGET
-if test -n "$STRIP_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP_FOR_TARGET" >&5
-$as_echo "$STRIP_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- if test -z "$ac_cv_prog_STRIP_FOR_TARGET" && test $build = $target ; then
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_STRIP_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$STRIP_FOR_TARGET"; then
- ac_cv_prog_STRIP_FOR_TARGET="$STRIP_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_STRIP_FOR_TARGET="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-STRIP_FOR_TARGET=$ac_cv_prog_STRIP_FOR_TARGET
-if test -n "$STRIP_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP_FOR_TARGET" >&5
-$as_echo "$STRIP_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- test -n "$ac_cv_prog_STRIP_FOR_TARGET" && break
- done
-fi
-
-if test -z "$ac_cv_prog_STRIP_FOR_TARGET" ; then
- set dummy strip
- if test $build = $target ; then
- STRIP_FOR_TARGET="$2"
- else
- STRIP_FOR_TARGET="${ncn_target_tool_prefix}$2"
- fi
-else
- STRIP_FOR_TARGET="$ac_cv_prog_STRIP_FOR_TARGET"
-fi
-
-else
- STRIP_FOR_TARGET=$ac_cv_path_STRIP_FOR_TARGET
-fi
-
-
-
-
-if test -z "$ac_cv_path_WINDRES_FOR_TARGET" ; then
- if test -n "$with_build_time_tools"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for windres in $with_build_time_tools" >&5
-$as_echo_n "checking for windres in $with_build_time_tools... " >&6; }
- if test -x $with_build_time_tools/windres; then
- WINDRES_FOR_TARGET=`cd $with_build_time_tools && pwd`/windres
- ac_cv_path_WINDRES_FOR_TARGET=$WINDRES_FOR_TARGET
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_WINDRES_FOR_TARGET" >&5
-$as_echo "$ac_cv_path_WINDRES_FOR_TARGET" >&6; }
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- fi
- elif test $build != $host && test $have_gcc_for_target = yes; then
- WINDRES_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=windres`
- test $WINDRES_FOR_TARGET = windres && WINDRES_FOR_TARGET=
- test -n "$WINDRES_FOR_TARGET" && ac_cv_path_WINDRES_FOR_TARGET=$WINDRES_FOR_TARGET
- fi
-fi
-if test -z "$ac_cv_path_WINDRES_FOR_TARGET" && test -n "$gcc_cv_tool_dirs"; then
- # Extract the first word of "windres", so it can be a program name with args.
-set dummy windres; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_WINDRES_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $WINDRES_FOR_TARGET in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_WINDRES_FOR_TARGET="$WINDRES_FOR_TARGET" # Let the user override the test with a path.
- ;;
- *)
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $gcc_cv_tool_dirs
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_path_WINDRES_FOR_TARGET="$as_dir/$ac_word$ac_exec_ext"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
- ;;
-esac
-fi
-WINDRES_FOR_TARGET=$ac_cv_path_WINDRES_FOR_TARGET
-if test -n "$WINDRES_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDRES_FOR_TARGET" >&5
-$as_echo "$WINDRES_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_path_WINDRES_FOR_TARGET" ; then
-
-
-if test -n "$WINDRES_FOR_TARGET"; then
- ac_cv_prog_WINDRES_FOR_TARGET=$WINDRES_FOR_TARGET
-elif test -n "$ac_cv_prog_WINDRES_FOR_TARGET"; then
- WINDRES_FOR_TARGET=$ac_cv_prog_WINDRES_FOR_TARGET
-fi
-
-if test -n "$ac_cv_prog_WINDRES_FOR_TARGET"; then
- for ncn_progname in windres; do
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_WINDRES_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$WINDRES_FOR_TARGET"; then
- ac_cv_prog_WINDRES_FOR_TARGET="$WINDRES_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_WINDRES_FOR_TARGET="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-WINDRES_FOR_TARGET=$ac_cv_prog_WINDRES_FOR_TARGET
-if test -n "$WINDRES_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDRES_FOR_TARGET" >&5
-$as_echo "$WINDRES_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- done
-fi
-
-if test -z "$ac_cv_prog_WINDRES_FOR_TARGET" && test -n "$with_build_time_tools"; then
- for ncn_progname in windres; do
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
-$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
- if test -x $with_build_time_tools/${ncn_progname}; then
- ac_cv_prog_WINDRES_FOR_TARGET=$with_build_time_tools/${ncn_progname}
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- break
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- fi
- done
-fi
-
-if test -z "$ac_cv_prog_WINDRES_FOR_TARGET"; then
- for ncn_progname in windres; do
- if test -n "$ncn_target_tool_prefix"; then
- # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_WINDRES_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$WINDRES_FOR_TARGET"; then
- ac_cv_prog_WINDRES_FOR_TARGET="$WINDRES_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_WINDRES_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-WINDRES_FOR_TARGET=$ac_cv_prog_WINDRES_FOR_TARGET
-if test -n "$WINDRES_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDRES_FOR_TARGET" >&5
-$as_echo "$WINDRES_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- if test -z "$ac_cv_prog_WINDRES_FOR_TARGET" && test $build = $target ; then
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_WINDRES_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$WINDRES_FOR_TARGET"; then
- ac_cv_prog_WINDRES_FOR_TARGET="$WINDRES_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_WINDRES_FOR_TARGET="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-WINDRES_FOR_TARGET=$ac_cv_prog_WINDRES_FOR_TARGET
-if test -n "$WINDRES_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDRES_FOR_TARGET" >&5
-$as_echo "$WINDRES_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- test -n "$ac_cv_prog_WINDRES_FOR_TARGET" && break
- done
-fi
-
-if test -z "$ac_cv_prog_WINDRES_FOR_TARGET" ; then
- set dummy windres
- if test $build = $target ; then
- WINDRES_FOR_TARGET="$2"
- else
- WINDRES_FOR_TARGET="${ncn_target_tool_prefix}$2"
- fi
-else
- WINDRES_FOR_TARGET="$ac_cv_prog_WINDRES_FOR_TARGET"
-fi
-
-else
- WINDRES_FOR_TARGET=$ac_cv_path_WINDRES_FOR_TARGET
-fi
-
-
-
-
-if test -z "$ac_cv_path_WINDMC_FOR_TARGET" ; then
- if test -n "$with_build_time_tools"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for windmc in $with_build_time_tools" >&5
-$as_echo_n "checking for windmc in $with_build_time_tools... " >&6; }
- if test -x $with_build_time_tools/windmc; then
- WINDMC_FOR_TARGET=`cd $with_build_time_tools && pwd`/windmc
- ac_cv_path_WINDMC_FOR_TARGET=$WINDMC_FOR_TARGET
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_WINDMC_FOR_TARGET" >&5
-$as_echo "$ac_cv_path_WINDMC_FOR_TARGET" >&6; }
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- fi
- elif test $build != $host && test $have_gcc_for_target = yes; then
- WINDMC_FOR_TARGET=`$GCC_FOR_TARGET --print-prog-name=windmc`
- test $WINDMC_FOR_TARGET = windmc && WINDMC_FOR_TARGET=
- test -n "$WINDMC_FOR_TARGET" && ac_cv_path_WINDMC_FOR_TARGET=$WINDMC_FOR_TARGET
- fi
-fi
-if test -z "$ac_cv_path_WINDMC_FOR_TARGET" && test -n "$gcc_cv_tool_dirs"; then
- # Extract the first word of "windmc", so it can be a program name with args.
-set dummy windmc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_WINDMC_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $WINDMC_FOR_TARGET in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_WINDMC_FOR_TARGET="$WINDMC_FOR_TARGET" # Let the user override the test with a path.
- ;;
- *)
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $gcc_cv_tool_dirs
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_path_WINDMC_FOR_TARGET="$as_dir/$ac_word$ac_exec_ext"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
- ;;
-esac
-fi
-WINDMC_FOR_TARGET=$ac_cv_path_WINDMC_FOR_TARGET
-if test -n "$WINDMC_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDMC_FOR_TARGET" >&5
-$as_echo "$WINDMC_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_path_WINDMC_FOR_TARGET" ; then
-
-
-if test -n "$WINDMC_FOR_TARGET"; then
- ac_cv_prog_WINDMC_FOR_TARGET=$WINDMC_FOR_TARGET
-elif test -n "$ac_cv_prog_WINDMC_FOR_TARGET"; then
- WINDMC_FOR_TARGET=$ac_cv_prog_WINDMC_FOR_TARGET
-fi
-
-if test -n "$ac_cv_prog_WINDMC_FOR_TARGET"; then
- for ncn_progname in windmc; do
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_WINDMC_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$WINDMC_FOR_TARGET"; then
- ac_cv_prog_WINDMC_FOR_TARGET="$WINDMC_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_WINDMC_FOR_TARGET="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-WINDMC_FOR_TARGET=$ac_cv_prog_WINDMC_FOR_TARGET
-if test -n "$WINDMC_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDMC_FOR_TARGET" >&5
-$as_echo "$WINDMC_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- done
-fi
-
-if test -z "$ac_cv_prog_WINDMC_FOR_TARGET" && test -n "$with_build_time_tools"; then
- for ncn_progname in windmc; do
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ncn_progname} in $with_build_time_tools" >&5
-$as_echo_n "checking for ${ncn_progname} in $with_build_time_tools... " >&6; }
- if test -x $with_build_time_tools/${ncn_progname}; then
- ac_cv_prog_WINDMC_FOR_TARGET=$with_build_time_tools/${ncn_progname}
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- break
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- fi
- done
-fi
-
-if test -z "$ac_cv_prog_WINDMC_FOR_TARGET"; then
- for ncn_progname in windmc; do
- if test -n "$ncn_target_tool_prefix"; then
- # Extract the first word of "${ncn_target_tool_prefix}${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_target_tool_prefix}${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_WINDMC_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$WINDMC_FOR_TARGET"; then
- ac_cv_prog_WINDMC_FOR_TARGET="$WINDMC_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_WINDMC_FOR_TARGET="${ncn_target_tool_prefix}${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-WINDMC_FOR_TARGET=$ac_cv_prog_WINDMC_FOR_TARGET
-if test -n "$WINDMC_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDMC_FOR_TARGET" >&5
-$as_echo "$WINDMC_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- if test -z "$ac_cv_prog_WINDMC_FOR_TARGET" && test $build = $target ; then
- # Extract the first word of "${ncn_progname}", so it can be a program name with args.
-set dummy ${ncn_progname}; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_WINDMC_FOR_TARGET+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$WINDMC_FOR_TARGET"; then
- ac_cv_prog_WINDMC_FOR_TARGET="$WINDMC_FOR_TARGET" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_WINDMC_FOR_TARGET="${ncn_progname}"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-WINDMC_FOR_TARGET=$ac_cv_prog_WINDMC_FOR_TARGET
-if test -n "$WINDMC_FOR_TARGET"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDMC_FOR_TARGET" >&5
-$as_echo "$WINDMC_FOR_TARGET" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
- test -n "$ac_cv_prog_WINDMC_FOR_TARGET" && break
- done
-fi
-
-if test -z "$ac_cv_prog_WINDMC_FOR_TARGET" ; then
- set dummy windmc
- if test $build = $target ; then
- WINDMC_FOR_TARGET="$2"
- else
- WINDMC_FOR_TARGET="${ncn_target_tool_prefix}$2"
- fi
-else
- WINDMC_FOR_TARGET="$ac_cv_prog_WINDMC_FOR_TARGET"
-fi
-
-else
- WINDMC_FOR_TARGET=$ac_cv_path_WINDMC_FOR_TARGET
-fi
-
-
-RAW_CXX_FOR_TARGET="$CXX_FOR_TARGET"
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target ar" >&5
-$as_echo_n "checking where to find the target ar... " >&6; }
-if test "x${build}" != "x${host}" ; then
- if expr "x$AR_FOR_TARGET" : "x/" > /dev/null; then
- # We already found the complete path
- ac_dir=`dirname $AR_FOR_TARGET`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
-$as_echo "pre-installed in $ac_dir" >&6; }
- else
- # Canadian cross, just use what we found
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
-$as_echo "pre-installed" >&6; }
- fi
-else
- ok=yes
- case " ${configdirs} " in
- *" binutils "*) ;;
- *) ok=no ;;
- esac
-
- if test $ok = yes; then
- # An in-tree tool is available and we can use it
- AR_FOR_TARGET='$$r/$(HOST_SUBDIR)/binutils/ar'
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
-$as_echo "just compiled" >&6; }
- elif expr "x$AR_FOR_TARGET" : "x/" > /dev/null; then
- # We already found the complete path
- ac_dir=`dirname $AR_FOR_TARGET`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
-$as_echo "pre-installed in $ac_dir" >&6; }
- elif test "x$target" = "x$host"; then
- # We can use an host tool
- AR_FOR_TARGET='$(AR)'
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
-$as_echo "host tool" >&6; }
- else
- # We need a cross tool
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
-$as_echo "pre-installed" >&6; }
- fi
-fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target as" >&5
-$as_echo_n "checking where to find the target as... " >&6; }
-if test "x${build}" != "x${host}" ; then
- if expr "x$AS_FOR_TARGET" : "x/" > /dev/null; then
- # We already found the complete path
- ac_dir=`dirname $AS_FOR_TARGET`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
-$as_echo "pre-installed in $ac_dir" >&6; }
- else
- # Canadian cross, just use what we found
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
-$as_echo "pre-installed" >&6; }
- fi
-else
- ok=yes
- case " ${configdirs} " in
- *" gas "*) ;;
- *) ok=no ;;
- esac
-
- if test $ok = yes; then
- # An in-tree tool is available and we can use it
- AS_FOR_TARGET='$$r/$(HOST_SUBDIR)/gas/as-new'
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
-$as_echo "just compiled" >&6; }
- elif expr "x$AS_FOR_TARGET" : "x/" > /dev/null; then
- # We already found the complete path
- ac_dir=`dirname $AS_FOR_TARGET`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
-$as_echo "pre-installed in $ac_dir" >&6; }
- elif test "x$target" = "x$host"; then
- # We can use an host tool
- AS_FOR_TARGET='$(AS)'
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
-$as_echo "host tool" >&6; }
- else
- # We need a cross tool
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
-$as_echo "pre-installed" >&6; }
- fi
-fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target cc" >&5
-$as_echo_n "checking where to find the target cc... " >&6; }
-if test "x${build}" != "x${host}" ; then
- if expr "x$CC_FOR_TARGET" : "x/" > /dev/null; then
- # We already found the complete path
- ac_dir=`dirname $CC_FOR_TARGET`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
-$as_echo "pre-installed in $ac_dir" >&6; }
- else
- # Canadian cross, just use what we found
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
-$as_echo "pre-installed" >&6; }
- fi
-else
- ok=yes
- case " ${configdirs} " in
- *" gcc "*) ;;
- *) ok=no ;;
- esac
-
- if test $ok = yes; then
- # An in-tree tool is available and we can use it
- CC_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/xgcc -B$$r/$(HOST_SUBDIR)/gcc/'
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
-$as_echo "just compiled" >&6; }
- elif expr "x$CC_FOR_TARGET" : "x/" > /dev/null; then
- # We already found the complete path
- ac_dir=`dirname $CC_FOR_TARGET`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
-$as_echo "pre-installed in $ac_dir" >&6; }
- elif test "x$target" = "x$host"; then
- # We can use an host tool
- CC_FOR_TARGET='$(CC)'
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
-$as_echo "host tool" >&6; }
- else
- # We need a cross tool
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
-$as_echo "pre-installed" >&6; }
- fi
-fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target c++" >&5
-$as_echo_n "checking where to find the target c++... " >&6; }
-if test "x${build}" != "x${host}" ; then
- if expr "x$CXX_FOR_TARGET" : "x/" > /dev/null; then
- # We already found the complete path
- ac_dir=`dirname $CXX_FOR_TARGET`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
-$as_echo "pre-installed in $ac_dir" >&6; }
- else
- # Canadian cross, just use what we found
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
-$as_echo "pre-installed" >&6; }
- fi
-else
- ok=yes
- case " ${configdirs} " in
- *" gcc "*) ;;
- *) ok=no ;;
- esac
- case ,${enable_languages}, in
- *,c++,*) ;;
- *) ok=no ;;
- esac
- if test $ok = yes; then
- # An in-tree tool is available and we can use it
- CXX_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/xg++ -B$$r/$(HOST_SUBDIR)/gcc/ -nostdinc++ `if test -f $$r/$(TARGET_SUBDIR)/libstdc++-v3/scripts/testsuite_flags; then $(SHELL) $$r/$(TARGET_SUBDIR)/libstdc++-v3/scripts/testsuite_flags --build-includes; else echo -funconfigured-libstdc++-v3 ; fi` -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src/.libs -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/libsupc++/.libs'
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
-$as_echo "just compiled" >&6; }
- elif expr "x$CXX_FOR_TARGET" : "x/" > /dev/null; then
- # We already found the complete path
- ac_dir=`dirname $CXX_FOR_TARGET`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
-$as_echo "pre-installed in $ac_dir" >&6; }
- elif test "x$target" = "x$host"; then
- # We can use an host tool
- CXX_FOR_TARGET='$(CXX)'
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
-$as_echo "host tool" >&6; }
- else
- # We need a cross tool
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
-$as_echo "pre-installed" >&6; }
- fi
-fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target c++ for libstdc++" >&5
-$as_echo_n "checking where to find the target c++ for libstdc++... " >&6; }
-if test "x${build}" != "x${host}" ; then
- if expr "x$RAW_CXX_FOR_TARGET" : "x/" > /dev/null; then
- # We already found the complete path
- ac_dir=`dirname $RAW_CXX_FOR_TARGET`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
-$as_echo "pre-installed in $ac_dir" >&6; }
- else
- # Canadian cross, just use what we found
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
-$as_echo "pre-installed" >&6; }
- fi
-else
- ok=yes
- case " ${configdirs} " in
- *" gcc "*) ;;
- *) ok=no ;;
- esac
- case ,${enable_languages}, in
- *,c++,*) ;;
- *) ok=no ;;
- esac
- if test $ok = yes; then
- # An in-tree tool is available and we can use it
- RAW_CXX_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/xgcc -shared-libgcc -B$$r/$(HOST_SUBDIR)/gcc -nostdinc++ -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src/.libs -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/libsupc++/.libs'
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
-$as_echo "just compiled" >&6; }
- elif expr "x$RAW_CXX_FOR_TARGET" : "x/" > /dev/null; then
- # We already found the complete path
- ac_dir=`dirname $RAW_CXX_FOR_TARGET`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
-$as_echo "pre-installed in $ac_dir" >&6; }
- elif test "x$target" = "x$host"; then
- # We can use an host tool
- RAW_CXX_FOR_TARGET='$(CXX)'
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
-$as_echo "host tool" >&6; }
- else
- # We need a cross tool
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
-$as_echo "pre-installed" >&6; }
- fi
-fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target dlltool" >&5
-$as_echo_n "checking where to find the target dlltool... " >&6; }
-if test "x${build}" != "x${host}" ; then
- if expr "x$DLLTOOL_FOR_TARGET" : "x/" > /dev/null; then
- # We already found the complete path
- ac_dir=`dirname $DLLTOOL_FOR_TARGET`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
-$as_echo "pre-installed in $ac_dir" >&6; }
- else
- # Canadian cross, just use what we found
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
-$as_echo "pre-installed" >&6; }
- fi
-else
- ok=yes
- case " ${configdirs} " in
- *" binutils "*) ;;
- *) ok=no ;;
- esac
-
- if test $ok = yes; then
- # An in-tree tool is available and we can use it
- DLLTOOL_FOR_TARGET='$$r/$(HOST_SUBDIR)/binutils/dlltool'
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
-$as_echo "just compiled" >&6; }
- elif expr "x$DLLTOOL_FOR_TARGET" : "x/" > /dev/null; then
- # We already found the complete path
- ac_dir=`dirname $DLLTOOL_FOR_TARGET`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
-$as_echo "pre-installed in $ac_dir" >&6; }
- elif test "x$target" = "x$host"; then
- # We can use an host tool
- DLLTOOL_FOR_TARGET='$(DLLTOOL)'
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
-$as_echo "host tool" >&6; }
- else
- # We need a cross tool
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
-$as_echo "pre-installed" >&6; }
- fi
-fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target dsymutil" >&5
-$as_echo_n "checking where to find the target dsymutil... " >&6; }
-if test "x${build}" != "x${host}" ; then
- if expr "x$DSYMUTIL_FOR_TARGET" : "x/" > /dev/null; then
- # We already found the complete path
- ac_dir=`dirname $DSYMUTIL_FOR_TARGET`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
-$as_echo "pre-installed in $ac_dir" >&6; }
- else
- # Canadian cross, just use what we found
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
-$as_echo "pre-installed" >&6; }
- fi
-else
- if expr "x$DSYMUTIL_FOR_TARGET" : "x/" > /dev/null; then
- # We already found the complete path
- ac_dir=`dirname $DSYMUTIL_FOR_TARGET`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
-$as_echo "pre-installed in $ac_dir" >&6; }
- elif test "x$target" = "x$host"; then
- # We can use an host tool
- DSYMUTIL_FOR_TARGET='$(DSYMUTIL)'
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
-$as_echo "host tool" >&6; }
- else
- # We need a cross tool
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
-$as_echo "pre-installed" >&6; }
- fi
-fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target gcc" >&5
-$as_echo_n "checking where to find the target gcc... " >&6; }
-if test "x${build}" != "x${host}" ; then
- if expr "x$GCC_FOR_TARGET" : "x/" > /dev/null; then
- # We already found the complete path
- ac_dir=`dirname $GCC_FOR_TARGET`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
-$as_echo "pre-installed in $ac_dir" >&6; }
- else
- # Canadian cross, just use what we found
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
-$as_echo "pre-installed" >&6; }
- fi
-else
- ok=yes
- case " ${configdirs} " in
- *" gcc "*) ;;
- *) ok=no ;;
- esac
-
- if test $ok = yes; then
- # An in-tree tool is available and we can use it
- GCC_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/xgcc -B$$r/$(HOST_SUBDIR)/gcc/'
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
-$as_echo "just compiled" >&6; }
- elif expr "x$GCC_FOR_TARGET" : "x/" > /dev/null; then
- # We already found the complete path
- ac_dir=`dirname $GCC_FOR_TARGET`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
-$as_echo "pre-installed in $ac_dir" >&6; }
- elif test "x$target" = "x$host"; then
- # We can use an host tool
- GCC_FOR_TARGET='$()'
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
-$as_echo "host tool" >&6; }
- else
- # We need a cross tool
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
-$as_echo "pre-installed" >&6; }
- fi
-fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target gfortran" >&5
-$as_echo_n "checking where to find the target gfortran... " >&6; }
-if test "x${build}" != "x${host}" ; then
- if expr "x$GFORTRAN_FOR_TARGET" : "x/" > /dev/null; then
- # We already found the complete path
- ac_dir=`dirname $GFORTRAN_FOR_TARGET`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
-$as_echo "pre-installed in $ac_dir" >&6; }
- else
- # Canadian cross, just use what we found
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
-$as_echo "pre-installed" >&6; }
- fi
-else
- ok=yes
- case " ${configdirs} " in
- *" gcc "*) ;;
- *) ok=no ;;
- esac
- case ,${enable_languages}, in
- *,fortran,*) ;;
- *) ok=no ;;
- esac
- if test $ok = yes; then
- # An in-tree tool is available and we can use it
- GFORTRAN_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/gfortran -B$$r/$(HOST_SUBDIR)/gcc/'
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
-$as_echo "just compiled" >&6; }
- elif expr "x$GFORTRAN_FOR_TARGET" : "x/" > /dev/null; then
- # We already found the complete path
- ac_dir=`dirname $GFORTRAN_FOR_TARGET`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
-$as_echo "pre-installed in $ac_dir" >&6; }
- elif test "x$target" = "x$host"; then
- # We can use an host tool
- GFORTRAN_FOR_TARGET='$(GFORTRAN)'
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
-$as_echo "host tool" >&6; }
- else
- # We need a cross tool
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
-$as_echo "pre-installed" >&6; }
- fi
-fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target gccgo" >&5
-$as_echo_n "checking where to find the target gccgo... " >&6; }
-if test "x${build}" != "x${host}" ; then
- if expr "x$GOC_FOR_TARGET" : "x/" > /dev/null; then
- # We already found the complete path
- ac_dir=`dirname $GOC_FOR_TARGET`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
-$as_echo "pre-installed in $ac_dir" >&6; }
- else
- # Canadian cross, just use what we found
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
-$as_echo "pre-installed" >&6; }
- fi
-else
- ok=yes
- case " ${configdirs} " in
- *" gcc "*) ;;
- *) ok=no ;;
- esac
- case ,${enable_languages}, in
- *,go,*) ;;
- *) ok=no ;;
- esac
- if test $ok = yes; then
- # An in-tree tool is available and we can use it
- GOC_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/gccgo -B$$r/$(HOST_SUBDIR)/gcc/'
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
-$as_echo "just compiled" >&6; }
- elif expr "x$GOC_FOR_TARGET" : "x/" > /dev/null; then
- # We already found the complete path
- ac_dir=`dirname $GOC_FOR_TARGET`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
-$as_echo "pre-installed in $ac_dir" >&6; }
- elif test "x$target" = "x$host"; then
- # We can use an host tool
- GOC_FOR_TARGET='$(GOC)'
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
-$as_echo "host tool" >&6; }
- else
- # We need a cross tool
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
-$as_echo "pre-installed" >&6; }
- fi
-fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target gdc" >&5
-$as_echo_n "checking where to find the target gdc... " >&6; }
-if test "x${build}" != "x${host}" ; then
- if expr "x$GDC_FOR_TARGET" : "x/" > /dev/null; then
- # We already found the complete path
- ac_dir=`dirname $GDC_FOR_TARGET`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
-$as_echo "pre-installed in $ac_dir" >&6; }
- else
- # Canadian cross, just use what we found
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
-$as_echo "pre-installed" >&6; }
- fi
-else
- ok=yes
- case " ${configdirs} " in
- *" gcc "*) ;;
- *) ok=no ;;
- esac
- case ,${enable_languages}, in
- *,d,*) ;;
- *) ok=no ;;
- esac
- if test $ok = yes; then
- # An in-tree tool is available and we can use it
- GDC_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/gdc -B$$r/$(HOST_SUBDIR)/gcc/'
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
-$as_echo "just compiled" >&6; }
- elif expr "x$GDC_FOR_TARGET" : "x/" > /dev/null; then
- # We already found the complete path
- ac_dir=`dirname $GDC_FOR_TARGET`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
-$as_echo "pre-installed in $ac_dir" >&6; }
- elif test "x$target" = "x$host"; then
- # We can use an host tool
- GDC_FOR_TARGET='$(GDC)'
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
-$as_echo "host tool" >&6; }
- else
- # We need a cross tool
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
-$as_echo "pre-installed" >&6; }
- fi
-fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target gm2" >&5
-$as_echo_n "checking where to find the target gm2... " >&6; }
-if test "x${build}" != "x${host}" ; then
- if expr "x$GM2_FOR_TARGET" : "x/" > /dev/null; then
- # We already found the complete path
- ac_dir=`dirname $GM2_FOR_TARGET`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
-$as_echo "pre-installed in $ac_dir" >&6; }
- else
- # Canadian cross, just use what we found
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
-$as_echo "pre-installed" >&6; }
- fi
-else
- ok=yes
- case " ${configdirs} " in
- *" gcc "*) ;;
- *) ok=no ;;
- esac
- case ,${enable_languages}, in
- *,m2,*) ;;
- *) ok=no ;;
- esac
- if test $ok = yes; then
- # An in-tree tool is available and we can use it
- GM2_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/gm2 -B$$r/$(HOST_SUBDIR)/gcc/'
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
-$as_echo "just compiled" >&6; }
- elif expr "x$GM2_FOR_TARGET" : "x/" > /dev/null; then
- # We already found the complete path
- ac_dir=`dirname $GM2_FOR_TARGET`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
-$as_echo "pre-installed in $ac_dir" >&6; }
- elif test "x$target" = "x$host"; then
- # We can use an host tool
- GM2_FOR_TARGET='$(GM2)'
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
-$as_echo "host tool" >&6; }
- else
- # We need a cross tool
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
-$as_echo "pre-installed" >&6; }
- fi
-fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target ld" >&5
-$as_echo_n "checking where to find the target ld... " >&6; }
-if test "x${build}" != "x${host}" ; then
- if expr "x$LD_FOR_TARGET" : "x/" > /dev/null; then
- # We already found the complete path
- ac_dir=`dirname $LD_FOR_TARGET`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
-$as_echo "pre-installed in $ac_dir" >&6; }
- else
- # Canadian cross, just use what we found
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
-$as_echo "pre-installed" >&6; }
- fi
-else
- ok=yes
- case " ${configdirs} " in
- *" ld "*) ;;
- *) ok=no ;;
- esac
-
- if test $ok = yes; then
- # An in-tree tool is available and we can use it
- LD_FOR_TARGET='$$r/$(HOST_SUBDIR)/ld/ld-new'
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
-$as_echo "just compiled" >&6; }
- elif expr "x$LD_FOR_TARGET" : "x/" > /dev/null; then
- # We already found the complete path
- ac_dir=`dirname $LD_FOR_TARGET`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
-$as_echo "pre-installed in $ac_dir" >&6; }
- elif test "x$target" = "x$host"; then
- # We can use an host tool
- LD_FOR_TARGET='$(LD)'
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
-$as_echo "host tool" >&6; }
- else
- # We need a cross tool
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
-$as_echo "pre-installed" >&6; }
- fi
-fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target lipo" >&5
-$as_echo_n "checking where to find the target lipo... " >&6; }
-if test "x${build}" != "x${host}" ; then
- if expr "x$LIPO_FOR_TARGET" : "x/" > /dev/null; then
- # We already found the complete path
- ac_dir=`dirname $LIPO_FOR_TARGET`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
-$as_echo "pre-installed in $ac_dir" >&6; }
- else
- # Canadian cross, just use what we found
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
-$as_echo "pre-installed" >&6; }
- fi
-else
- if expr "x$LIPO_FOR_TARGET" : "x/" > /dev/null; then
- # We already found the complete path
- ac_dir=`dirname $LIPO_FOR_TARGET`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
-$as_echo "pre-installed in $ac_dir" >&6; }
- elif test "x$target" = "x$host"; then
- # We can use an host tool
- LIPO_FOR_TARGET='$(LIPO)'
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
-$as_echo "host tool" >&6; }
- else
- # We need a cross tool
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
-$as_echo "pre-installed" >&6; }
- fi
-fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target nm" >&5
-$as_echo_n "checking where to find the target nm... " >&6; }
-if test "x${build}" != "x${host}" ; then
- if expr "x$NM_FOR_TARGET" : "x/" > /dev/null; then
- # We already found the complete path
- ac_dir=`dirname $NM_FOR_TARGET`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
-$as_echo "pre-installed in $ac_dir" >&6; }
- else
- # Canadian cross, just use what we found
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
-$as_echo "pre-installed" >&6; }
- fi
-else
- ok=yes
- case " ${configdirs} " in
- *" binutils "*) ;;
- *) ok=no ;;
- esac
-
- if test $ok = yes; then
- # An in-tree tool is available and we can use it
- NM_FOR_TARGET='$$r/$(HOST_SUBDIR)/binutils/nm-new'
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
-$as_echo "just compiled" >&6; }
- elif expr "x$NM_FOR_TARGET" : "x/" > /dev/null; then
- # We already found the complete path
- ac_dir=`dirname $NM_FOR_TARGET`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
-$as_echo "pre-installed in $ac_dir" >&6; }
- elif test "x$target" = "x$host"; then
- # We can use an host tool
- NM_FOR_TARGET='$(NM)'
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
-$as_echo "host tool" >&6; }
- else
- # We need a cross tool
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
-$as_echo "pre-installed" >&6; }
- fi
-fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target objcopy" >&5
-$as_echo_n "checking where to find the target objcopy... " >&6; }
-if test "x${build}" != "x${host}" ; then
- if expr "x$OBJCOPY_FOR_TARGET" : "x/" > /dev/null; then
- # We already found the complete path
- ac_dir=`dirname $OBJCOPY_FOR_TARGET`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
-$as_echo "pre-installed in $ac_dir" >&6; }
- else
- # Canadian cross, just use what we found
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
-$as_echo "pre-installed" >&6; }
- fi
-else
- ok=yes
- case " ${configdirs} " in
- *" binutils "*) ;;
- *) ok=no ;;
- esac
-
- if test $ok = yes; then
- # An in-tree tool is available and we can use it
- OBJCOPY_FOR_TARGET='$$r/$(HOST_SUBDIR)/binutils/objcopy'
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
-$as_echo "just compiled" >&6; }
- elif expr "x$OBJCOPY_FOR_TARGET" : "x/" > /dev/null; then
- # We already found the complete path
- ac_dir=`dirname $OBJCOPY_FOR_TARGET`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
-$as_echo "pre-installed in $ac_dir" >&6; }
- elif test "x$target" = "x$host"; then
- # We can use an host tool
- OBJCOPY_FOR_TARGET='$(OBJCOPY)'
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
-$as_echo "host tool" >&6; }
- else
- # We need a cross tool
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
-$as_echo "pre-installed" >&6; }
- fi
-fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target objdump" >&5
-$as_echo_n "checking where to find the target objdump... " >&6; }
-if test "x${build}" != "x${host}" ; then
- if expr "x$OBJDUMP_FOR_TARGET" : "x/" > /dev/null; then
- # We already found the complete path
- ac_dir=`dirname $OBJDUMP_FOR_TARGET`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
-$as_echo "pre-installed in $ac_dir" >&6; }
- else
- # Canadian cross, just use what we found
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
-$as_echo "pre-installed" >&6; }
- fi
-else
- ok=yes
- case " ${configdirs} " in
- *" binutils "*) ;;
- *) ok=no ;;
- esac
-
- if test $ok = yes; then
- # An in-tree tool is available and we can use it
- OBJDUMP_FOR_TARGET='$$r/$(HOST_SUBDIR)/binutils/objdump'
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
-$as_echo "just compiled" >&6; }
- elif expr "x$OBJDUMP_FOR_TARGET" : "x/" > /dev/null; then
- # We already found the complete path
- ac_dir=`dirname $OBJDUMP_FOR_TARGET`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
-$as_echo "pre-installed in $ac_dir" >&6; }
- elif test "x$target" = "x$host"; then
- # We can use an host tool
- OBJDUMP_FOR_TARGET='$(OBJDUMP)'
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
-$as_echo "host tool" >&6; }
- else
- # We need a cross tool
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
-$as_echo "pre-installed" >&6; }
- fi
-fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target otool" >&5
-$as_echo_n "checking where to find the target otool... " >&6; }
-if test "x${build}" != "x${host}" ; then
- if expr "x$OTOOL_FOR_TARGET" : "x/" > /dev/null; then
- # We already found the complete path
- ac_dir=`dirname $OTOOL_FOR_TARGET`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
-$as_echo "pre-installed in $ac_dir" >&6; }
- else
- # Canadian cross, just use what we found
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
-$as_echo "pre-installed" >&6; }
- fi
-else
- if expr "x$OTOOL_FOR_TARGET" : "x/" > /dev/null; then
- # We already found the complete path
- ac_dir=`dirname $OTOOL_FOR_TARGET`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
-$as_echo "pre-installed in $ac_dir" >&6; }
- elif test "x$target" = "x$host"; then
- # We can use an host tool
- OTOOL_FOR_TARGET='$(OTOOL)'
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
-$as_echo "host tool" >&6; }
- else
- # We need a cross tool
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
-$as_echo "pre-installed" >&6; }
- fi
-fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target ranlib" >&5
-$as_echo_n "checking where to find the target ranlib... " >&6; }
-if test "x${build}" != "x${host}" ; then
- if expr "x$RANLIB_FOR_TARGET" : "x/" > /dev/null; then
- # We already found the complete path
- ac_dir=`dirname $RANLIB_FOR_TARGET`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
-$as_echo "pre-installed in $ac_dir" >&6; }
- else
- # Canadian cross, just use what we found
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
-$as_echo "pre-installed" >&6; }
- fi
-else
- ok=yes
- case " ${configdirs} " in
- *" binutils "*) ;;
- *) ok=no ;;
- esac
-
- if test $ok = yes; then
- # An in-tree tool is available and we can use it
- RANLIB_FOR_TARGET='$$r/$(HOST_SUBDIR)/binutils/ranlib'
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
-$as_echo "just compiled" >&6; }
- elif expr "x$RANLIB_FOR_TARGET" : "x/" > /dev/null; then
- # We already found the complete path
- ac_dir=`dirname $RANLIB_FOR_TARGET`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
-$as_echo "pre-installed in $ac_dir" >&6; }
- elif test "x$target" = "x$host"; then
- # We can use an host tool
- RANLIB_FOR_TARGET='$(RANLIB)'
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
-$as_echo "host tool" >&6; }
- else
- # We need a cross tool
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
-$as_echo "pre-installed" >&6; }
- fi
-fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target readelf" >&5
-$as_echo_n "checking where to find the target readelf... " >&6; }
-if test "x${build}" != "x${host}" ; then
- if expr "x$READELF_FOR_TARGET" : "x/" > /dev/null; then
- # We already found the complete path
- ac_dir=`dirname $READELF_FOR_TARGET`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
-$as_echo "pre-installed in $ac_dir" >&6; }
- else
- # Canadian cross, just use what we found
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
-$as_echo "pre-installed" >&6; }
- fi
-else
- ok=yes
- case " ${configdirs} " in
- *" binutils "*) ;;
- *) ok=no ;;
- esac
-
- if test $ok = yes; then
- # An in-tree tool is available and we can use it
- READELF_FOR_TARGET='$$r/$(HOST_SUBDIR)/binutils/readelf'
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
-$as_echo "just compiled" >&6; }
- elif expr "x$READELF_FOR_TARGET" : "x/" > /dev/null; then
- # We already found the complete path
- ac_dir=`dirname $READELF_FOR_TARGET`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
-$as_echo "pre-installed in $ac_dir" >&6; }
- elif test "x$target" = "x$host"; then
- # We can use an host tool
- READELF_FOR_TARGET='$(READELF)'
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
-$as_echo "host tool" >&6; }
- else
- # We need a cross tool
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
-$as_echo "pre-installed" >&6; }
- fi
-fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target strip" >&5
-$as_echo_n "checking where to find the target strip... " >&6; }
-if test "x${build}" != "x${host}" ; then
- if expr "x$STRIP_FOR_TARGET" : "x/" > /dev/null; then
- # We already found the complete path
- ac_dir=`dirname $STRIP_FOR_TARGET`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
-$as_echo "pre-installed in $ac_dir" >&6; }
- else
- # Canadian cross, just use what we found
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
-$as_echo "pre-installed" >&6; }
- fi
-else
- ok=yes
- case " ${configdirs} " in
- *" binutils "*) ;;
- *) ok=no ;;
- esac
-
- if test $ok = yes; then
- # An in-tree tool is available and we can use it
- STRIP_FOR_TARGET='$$r/$(HOST_SUBDIR)/binutils/strip-new'
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
-$as_echo "just compiled" >&6; }
- elif expr "x$STRIP_FOR_TARGET" : "x/" > /dev/null; then
- # We already found the complete path
- ac_dir=`dirname $STRIP_FOR_TARGET`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
-$as_echo "pre-installed in $ac_dir" >&6; }
- elif test "x$target" = "x$host"; then
- # We can use an host tool
- STRIP_FOR_TARGET='$(STRIP)'
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
-$as_echo "host tool" >&6; }
- else
- # We need a cross tool
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
-$as_echo "pre-installed" >&6; }
- fi
-fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target windres" >&5
-$as_echo_n "checking where to find the target windres... " >&6; }
-if test "x${build}" != "x${host}" ; then
- if expr "x$WINDRES_FOR_TARGET" : "x/" > /dev/null; then
- # We already found the complete path
- ac_dir=`dirname $WINDRES_FOR_TARGET`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
-$as_echo "pre-installed in $ac_dir" >&6; }
- else
- # Canadian cross, just use what we found
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
-$as_echo "pre-installed" >&6; }
- fi
-else
- ok=yes
- case " ${configdirs} " in
- *" binutils "*) ;;
- *) ok=no ;;
- esac
-
- if test $ok = yes; then
- # An in-tree tool is available and we can use it
- WINDRES_FOR_TARGET='$$r/$(HOST_SUBDIR)/binutils/windres'
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
-$as_echo "just compiled" >&6; }
- elif expr "x$WINDRES_FOR_TARGET" : "x/" > /dev/null; then
- # We already found the complete path
- ac_dir=`dirname $WINDRES_FOR_TARGET`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
-$as_echo "pre-installed in $ac_dir" >&6; }
- elif test "x$target" = "x$host"; then
- # We can use an host tool
- WINDRES_FOR_TARGET='$(WINDRES)'
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
-$as_echo "host tool" >&6; }
- else
- # We need a cross tool
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
-$as_echo "pre-installed" >&6; }
- fi
-fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking where to find the target windmc" >&5
-$as_echo_n "checking where to find the target windmc... " >&6; }
-if test "x${build}" != "x${host}" ; then
- if expr "x$WINDMC_FOR_TARGET" : "x/" > /dev/null; then
- # We already found the complete path
- ac_dir=`dirname $WINDMC_FOR_TARGET`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
-$as_echo "pre-installed in $ac_dir" >&6; }
- else
- # Canadian cross, just use what we found
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
-$as_echo "pre-installed" >&6; }
- fi
-else
- ok=yes
- case " ${configdirs} " in
- *" binutils "*) ;;
- *) ok=no ;;
- esac
-
- if test $ok = yes; then
- # An in-tree tool is available and we can use it
- WINDMC_FOR_TARGET='$$r/$(HOST_SUBDIR)/binutils/windmc'
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: just compiled" >&5
-$as_echo "just compiled" >&6; }
- elif expr "x$WINDMC_FOR_TARGET" : "x/" > /dev/null; then
- # We already found the complete path
- ac_dir=`dirname $WINDMC_FOR_TARGET`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed in $ac_dir" >&5
-$as_echo "pre-installed in $ac_dir" >&6; }
- elif test "x$target" = "x$host"; then
- # We can use an host tool
- WINDMC_FOR_TARGET='$(WINDMC)'
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: host tool" >&5
-$as_echo "host tool" >&6; }
- else
- # We need a cross tool
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: pre-installed" >&5
-$as_echo "pre-installed" >&6; }
- fi
-fi
-
-
-
-
-
-# Certain tools may need extra flags.
-AR_FOR_TARGET=${AR_FOR_TARGET}${extra_arflags_for_target}
-RANLIB_FOR_TARGET=${RANLIB_FOR_TARGET}${extra_ranlibflags_for_target}
-NM_FOR_TARGET=${NM_FOR_TARGET}${extra_nmflags_for_target}
-
-# When building target libraries, except in a Canadian cross, we use
-# the same toolchain as the compiler we just built.
-COMPILER_AS_FOR_TARGET='$(AS_FOR_TARGET)'
-COMPILER_LD_FOR_TARGET='$(LD_FOR_TARGET)'
-COMPILER_NM_FOR_TARGET='$(NM_FOR_TARGET)'
-if test $host = $build; then
- case " $configdirs " in
- *" gcc "*)
- COMPILER_AS_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/as'
- COMPILER_LD_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/collect-ld'
- COMPILER_NM_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/nm'${extra_nmflags_for_target}
- ;;
- esac
-fi
-
-
-
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable maintainer-specific portions of Makefiles" >&5
-$as_echo_n "checking whether to enable maintainer-specific portions of Makefiles... " >&6; }
-# Check whether --enable-maintainer-mode was given.
-if test "${enable_maintainer_mode+set}" = set; then :
- enableval=$enable_maintainer_mode; USE_MAINTAINER_MODE=$enableval
-else
- USE_MAINTAINER_MODE=no
-fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_MAINTAINER_MODE" >&5
-$as_echo "$USE_MAINTAINER_MODE" >&6; }
-
-
-if test "$USE_MAINTAINER_MODE" = yes; then
- MAINTAINER_MODE_TRUE=
- MAINTAINER_MODE_FALSE='#'
-else
- MAINTAINER_MODE_TRUE='#'
- MAINTAINER_MODE_FALSE=
-fi
-MAINT=$MAINTAINER_MODE_TRUE
-
-# ---------------------
-# GCC bootstrap support
-# ---------------------
-
-# Stage specific cflags for build.
-stage1_cflags="-g"
-case $build in
- vax-*-*)
- case ${GCC} in
- yes) stage1_cflags="-g -Wa,-J" ;;
- *) stage1_cflags="-g -J" ;;
- esac ;;
-esac
-
-
-
-# Enable --enable-checking in stage1 of the compiler.
-# Check whether --enable-stage1-checking was given.
-if test "${enable_stage1_checking+set}" = set; then :
- enableval=$enable_stage1_checking; stage1_checking=--enable-checking=${enable_stage1_checking}
-else
- if test "x$enable_checking" = xno || test "x$enable_checking" = x; then
- # For --disable-checking or implicit --enable-checking=release, avoid
- # setting --enable-checking=gc in the default stage1 checking for LTO
- # bootstraps. See PR62077.
- case $BUILD_CONFIG in
- *lto*)
- stage1_checking=--enable-checking=release,misc,gimple,rtlflag,tree,types;;
- *)
- stage1_checking=--enable-checking=yes,types;;
- esac
- if test "x$enable_checking" = x && \
- test -d ${srcdir}/gcc && \
- test x"`cat ${srcdir}/gcc/DEV-PHASE`" = xexperimental; then
- stage1_checking=--enable-checking=yes,types,extra
- fi
-else
- stage1_checking=--enable-checking=$enable_checking,types
-fi
-fi
-
-
-
-# Enable -Werror in bootstrap stage2 and later.
-# Check whether --enable-werror was given.
-if test "${enable_werror+set}" = set; then :
- enableval=$enable_werror;
-case ${enable_werror} in
- yes) stage2_werror_flag="--enable-werror-always" ;;
- *) stage2_werror_flag="" ;;
-esac
-
-else
-
-if test -d ${srcdir}/gcc && test x"`cat $srcdir/gcc/DEV-PHASE`" = xexperimental; then
- case $BUILD_CONFIG in
- bootstrap-debug)
- stage2_werror_flag="--enable-werror-always" ;;
- "")
- stage2_werror_flag="--enable-werror-always" ;;
- esac
-fi
-
-fi
-
-
-
-
-# Specify what files to not compare during bootstrap.
-
-compare_exclusions="gcc/cc*-checksum\$(objext) | gcc/ada/*tools/*"
-compare_exclusions="$compare_exclusions | gcc/m2/gm2-compiler-boot/M2Version*"
-compare_exclusions="$compare_exclusions | gcc/m2/gm2-compiler-boot/SYSTEM*"
-compare_exclusions="$compare_exclusions | gcc/m2/gm2version*"
-case "$target" in
- hppa*64*-*-hpux*) ;;
- powerpc*-ibm-aix*) compare_exclusions="$compare_exclusions | *libgomp*\$(objext)" ;;
-esac
-
-
-ac_config_files="$ac_config_files Makefile"
-
-cat >confcache <<\_ACEOF
-# This file is a shell script that caches the results of configure
-# tests run on this system so they can be shared between configure
-# scripts and configure runs, see configure's option --config-cache.
-# It is not useful on other systems. If it contains results you don't
-# want to keep, you may remove or edit it.
-#
-# config.status only pays attention to the cache file if you give it
-# the --recheck option to rerun configure.
-#
-# `ac_cv_env_foo' variables (set or unset) will be overridden when
-# loading this file, other *unset* `ac_cv_foo' will be assigned the
-# following values.
-
-_ACEOF
-
-# The following way of writing the cache mishandles newlines in values,
-# but we know of no workaround that is simple, portable, and efficient.
-# So, we kill variables containing newlines.
-# Ultrix sh set writes to stderr and can't be redirected directly,
-# and sets the high bit in the cache file unless we assign to the vars.
-(
- for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
- eval ac_val=\$$ac_var
- case $ac_val in #(
- *${as_nl}*)
- case $ac_var in #(
- *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
-$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
- esac
- case $ac_var in #(
- _ | IFS | as_nl) ;; #(
- BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
- *) { eval $ac_var=; unset $ac_var;} ;;
- esac ;;
- esac
- done
-
- (set) 2>&1 |
- case $as_nl`(ac_space=' '; set) 2>&1` in #(
- *${as_nl}ac_space=\ *)
- # `set' does not quote correctly, so add quotes: double-quote
- # substitution turns \\\\ into \\, and sed turns \\ into \.
- sed -n \
- "s/'/'\\\\''/g;
- s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
- ;; #(
- *)
- # `set' quotes correctly as required by POSIX, so do not add quotes.
- sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
- ;;
- esac |
- sort
-) |
- sed '
- /^ac_cv_env_/b end
- t clear
- :clear
- s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
- t end
- s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
- :end' >>confcache
-if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
- if test -w "$cache_file"; then
- if test "x$cache_file" != "x/dev/null"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
-$as_echo "$as_me: updating cache $cache_file" >&6;}
- if test ! -f "$cache_file" || test -h "$cache_file"; then
- cat confcache >"$cache_file"
- else
- case $cache_file in #(
- */* | ?:*)
- mv -f confcache "$cache_file"$$ &&
- mv -f "$cache_file"$$ "$cache_file" ;; #(
- *)
- mv -f confcache "$cache_file" ;;
- esac
- fi
- fi
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
-$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
- fi
-fi
-rm -f confcache
-
-test "x$prefix" = xNONE && prefix=$ac_default_prefix
-# Let make expand exec_prefix.
-test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
-
-# Transform confdefs.h into DEFS.
-# Protect against shell expansion while executing Makefile rules.
-# Protect against Makefile macro expansion.
-#
-# If the first sed substitution is executed (which looks for macros that
-# take arguments), then branch to the quote section. Otherwise,
-# look for a macro that doesn't take arguments.
-ac_script='
-:mline
-/\\$/{
- N
- s,\\\n,,
- b mline
-}
-t clear
-:clear
-s/^[ ]*#[ ]*define[ ][ ]*\([^ (][^ (]*([^)]*)\)[ ]*\(.*\)/-D\1=\2/g
-t quote
-s/^[ ]*#[ ]*define[ ][ ]*\([^ ][^ ]*\)[ ]*\(.*\)/-D\1=\2/g
-t quote
-b any
-:quote
-s/[ `~#$^&*(){}\\|;'\''"<>?]/\\&/g
-s/\[/\\&/g
-s/\]/\\&/g
-s/\$/$$/g
-H
-:any
-${
- g
- s/^\n//
- s/\n/ /g
- p
-}
-'
-DEFS=`sed -n "$ac_script" confdefs.h`
-
-
-ac_libobjs=
-ac_ltlibobjs=
-U=
-for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
- # 1. Remove the extension, and $U if already installed.
- ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
- ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
- # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
- # will be set to the directory where LIBOBJS objects are built.
- as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
- as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
-done
-LIBOBJS=$ac_libobjs
-
-LTLIBOBJS=$ac_ltlibobjs
-
-
-
-: "${CONFIG_STATUS=./config.status}"
-ac_write_fail=0
-ac_clean_files_save=$ac_clean_files
-ac_clean_files="$ac_clean_files $CONFIG_STATUS"
-{ $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
-$as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
-as_write_fail=0
-cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
-#! $SHELL
-# Generated by $as_me.
-# Run this file to recreate the current configuration.
-# Compiler output produced by configure, useful for debugging
-# configure, is in config.log if it exists.
-
-debug=false
-ac_cs_recheck=false
-ac_cs_silent=false
-
-SHELL=\${CONFIG_SHELL-$SHELL}
-export SHELL
-_ASEOF
-cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
-## -------------------- ##
-## M4sh Initialization. ##
-## -------------------- ##
-
-# Be more Bourne compatible
-DUALCASE=1; export DUALCASE # for MKS sh
-if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
- emulate sh
- NULLCMD=:
- # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
- # is contrary to our usage. Disable this feature.
- alias -g '${1+"$@"}'='"$@"'
- setopt NO_GLOB_SUBST
-else
- case `(set -o) 2>/dev/null` in #(
- *posix*) :
- set -o posix ;; #(
- *) :
- ;;
-esac
-fi
-
-
-as_nl='
-'
-export as_nl
-# Printing a long string crashes Solaris 7 /usr/bin/printf.
-as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
-as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
-as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
-# Prefer a ksh shell builtin over an external printf program on Solaris,
-# but without wasting forks for bash or zsh.
-if test -z "$BASH_VERSION$ZSH_VERSION" \
- && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
- as_echo='print -r --'
- as_echo_n='print -rn --'
-elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
- as_echo='printf %s\n'
- as_echo_n='printf %s'
-else
- if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
- as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
- as_echo_n='/usr/ucb/echo -n'
- else
- as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
- as_echo_n_body='eval
- arg=$1;
- case $arg in #(
- *"$as_nl"*)
- expr "X$arg" : "X\\(.*\\)$as_nl";
- arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
- esac;
- expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
- '
- export as_echo_n_body
- as_echo_n='sh -c $as_echo_n_body as_echo'
- fi
- export as_echo_body
- as_echo='sh -c $as_echo_body as_echo'
-fi
-
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- PATH_SEPARATOR=:
- (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
- (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
- PATH_SEPARATOR=';'
- }
-fi
-
-
-# IFS
-# We need space, tab and new line, in precisely that order. Quoting is
-# there to prevent editors from complaining about space-tab.
-# (If _AS_PATH_WALK were called with IFS unset, it would disable word
-# splitting by setting IFS to empty value.)
-IFS=" "" $as_nl"
-
-# Find who we are. Look in the path if we contain no directory separator.
-as_myself=
-case $0 in #((
- *[\\/]* ) as_myself=$0 ;;
- *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
- done
-IFS=$as_save_IFS
-
- ;;
-esac
-# We did not find ourselves, most probably we were run as `sh COMMAND'
-# in which case we are not to be found in the path.
-if test "x$as_myself" = x; then
- as_myself=$0
-fi
-if test ! -f "$as_myself"; then
- $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
- exit 1
-fi
-
-# Unset variables that we do not need and which cause bugs (e.g. in
-# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
-# suppresses any "Segmentation fault" message there. '((' could
-# trigger a bug in pdksh 5.2.14.
-for as_var in BASH_ENV ENV MAIL MAILPATH
-do eval test x\${$as_var+set} = xset \
- && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
-done
-PS1='$ '
-PS2='> '
-PS4='+ '
-
-# NLS nuisances.
-LC_ALL=C
-export LC_ALL
-LANGUAGE=C
-export LANGUAGE
-
-# CDPATH.
-(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
-
-
-# as_fn_error STATUS ERROR [LINENO LOG_FD]
-# ----------------------------------------
-# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
-# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
-# script with STATUS, using 1 if that was 0.
-as_fn_error ()
-{
- as_status=$1; test $as_status -eq 0 && as_status=1
- if test "$4"; then
- as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
- fi
- $as_echo "$as_me: error: $2" >&2
- as_fn_exit $as_status
-} # as_fn_error
-
-
-# as_fn_set_status STATUS
-# -----------------------
-# Set $? to STATUS, without forking.
-as_fn_set_status ()
-{
- return $1
-} # as_fn_set_status
-
-# as_fn_exit STATUS
-# -----------------
-# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
-as_fn_exit ()
-{
- set +e
- as_fn_set_status $1
- exit $1
-} # as_fn_exit
-
-# as_fn_unset VAR
-# ---------------
-# Portably unset VAR.
-as_fn_unset ()
-{
- { eval $1=; unset $1;}
-}
-as_unset=as_fn_unset
-# as_fn_append VAR VALUE
-# ----------------------
-# Append the text in VALUE to the end of the definition contained in VAR. Take
-# advantage of any shell optimizations that allow amortized linear growth over
-# repeated appends, instead of the typical quadratic growth present in naive
-# implementations.
-if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
- eval 'as_fn_append ()
- {
- eval $1+=\$2
- }'
-else
- as_fn_append ()
- {
- eval $1=\$$1\$2
- }
-fi # as_fn_append
-
-# as_fn_arith ARG...
-# ------------------
-# Perform arithmetic evaluation on the ARGs, and store the result in the
-# global $as_val. Take advantage of shells that can avoid forks. The arguments
-# must be portable across $(()) and expr.
-if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
- eval 'as_fn_arith ()
- {
- as_val=$(( $* ))
- }'
-else
- as_fn_arith ()
- {
- as_val=`expr "$@" || test $? -eq 1`
- }
-fi # as_fn_arith
-
-
-if expr a : '\(a\)' >/dev/null 2>&1 &&
- test "X`expr 00001 : '.*\(...\)'`" = X001; then
- as_expr=expr
-else
- as_expr=false
-fi
-
-if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
- as_basename=basename
-else
- as_basename=false
-fi
-
-if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
- as_dirname=dirname
-else
- as_dirname=false
-fi
-
-as_me=`$as_basename -- "$0" ||
-$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
- X"$0" : 'X\(//\)$' \| \
- X"$0" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X/"$0" |
- sed '/^.*\/\([^/][^/]*\)\/*$/{
- s//\1/
- q
- }
- /^X\/\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\/\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
-
-# Avoid depending upon Character Ranges.
-as_cr_letters='abcdefghijklmnopqrstuvwxyz'
-as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
-as_cr_Letters=$as_cr_letters$as_cr_LETTERS
-as_cr_digits='0123456789'
-as_cr_alnum=$as_cr_Letters$as_cr_digits
-
-ECHO_C= ECHO_N= ECHO_T=
-case `echo -n x` in #(((((
--n*)
- case `echo 'xy\c'` in
- *c*) ECHO_T=' ';; # ECHO_T is single tab character.
- xy) ECHO_C='\c';;
- *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
- ECHO_T=' ';;
- esac;;
-*)
- ECHO_N='-n';;
-esac
-
-rm -f conf$$ conf$$.exe conf$$.file
-if test -d conf$$.dir; then
- rm -f conf$$.dir/conf$$.file
-else
- rm -f conf$$.dir
- mkdir conf$$.dir 2>/dev/null
-fi
-if (echo >conf$$.file) 2>/dev/null; then
- if ln -s conf$$.file conf$$ 2>/dev/null; then
- as_ln_s='ln -s'
- # ... but there are two gotchas:
- # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
- # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
- # In both cases, we have to default to `cp -pR'.
- ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
- as_ln_s='cp -pR'
- elif ln conf$$.file conf$$ 2>/dev/null; then
- as_ln_s=ln
- else
- as_ln_s='cp -pR'
- fi
-else
- as_ln_s='cp -pR'
-fi
-rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
-rmdir conf$$.dir 2>/dev/null
-
-
-# as_fn_mkdir_p
-# -------------
-# Create "$as_dir" as a directory, including parents if necessary.
-as_fn_mkdir_p ()
-{
-
- case $as_dir in #(
- -*) as_dir=./$as_dir;;
- esac
- test -d "$as_dir" || eval $as_mkdir_p || {
- as_dirs=
- while :; do
- case $as_dir in #(
- *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
- *) as_qdir=$as_dir;;
- esac
- as_dirs="'$as_qdir' $as_dirs"
- as_dir=`$as_dirname -- "$as_dir" ||
-$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$as_dir" : 'X\(//\)[^/]' \| \
- X"$as_dir" : 'X\(//\)$' \| \
- X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$as_dir" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
- test -d "$as_dir" && break
- done
- test -z "$as_dirs" || eval "mkdir $as_dirs"
- } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
-
-
-} # as_fn_mkdir_p
-if mkdir -p . 2>/dev/null; then
- as_mkdir_p='mkdir -p "$as_dir"'
-else
- test -d ./-p && rmdir ./-p
- as_mkdir_p=false
-fi
-
-
-# as_fn_executable_p FILE
-# -----------------------
-# Test if FILE is an executable regular file.
-as_fn_executable_p ()
-{
- test -f "$1" && test -x "$1"
-} # as_fn_executable_p
-as_test_x='test -x'
-as_executable_p=as_fn_executable_p
-
-# Sed expression to map a string onto a valid CPP name.
-as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
-
-# Sed expression to map a string onto a valid variable name.
-as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
-
-
-exec 6>&1
-## ----------------------------------- ##
-## Main body of $CONFIG_STATUS script. ##
-## ----------------------------------- ##
-_ASEOF
-test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
-
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-# Save the log message, to keep $0 and so on meaningful, and to
-# report actual input values of CONFIG_FILES etc. instead of their
-# values after options handling.
-ac_log="
-This file was extended by $as_me, which was
-generated by GNU Autoconf 2.69. Invocation command line was
-
- CONFIG_FILES = $CONFIG_FILES
- CONFIG_HEADERS = $CONFIG_HEADERS
- CONFIG_LINKS = $CONFIG_LINKS
- CONFIG_COMMANDS = $CONFIG_COMMANDS
- $ $0 $@
-
-on `(hostname || uname -n) 2>/dev/null | sed 1q`
-"
-
-_ACEOF
-
-case $ac_config_files in *"
-"*) set x $ac_config_files; shift; ac_config_files=$*;;
-esac
-
-
-
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-# Files that config.status was made for.
-config_files="$ac_config_files"
-
-_ACEOF
-
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-ac_cs_usage="\
-\`$as_me' instantiates files and other configuration actions
-from templates according to the current configuration. Unless the files
-and actions are specified as TAGs, all are instantiated by default.
-
-Usage: $0 [OPTION]... [TAG]...
-
- -h, --help print this help, then exit
- -V, --version print version number and configuration settings, then exit
- --config print configuration, then exit
- -q, --quiet, --silent
- do not print progress messages
- -d, --debug don't remove temporary files
- --recheck update $as_me by reconfiguring in the same conditions
- --file=FILE[:TEMPLATE]
- instantiate the configuration file FILE
-
-Configuration files:
-$config_files
-
-Report bugs to the package provider."
-
-_ACEOF
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
-ac_cs_version="\\
-config.status
-configured by $0, generated by GNU Autoconf 2.69,
- with options \\"\$ac_cs_config\\"
-
-Copyright (C) 2012 Free Software Foundation, Inc.
-This config.status script is free software; the Free Software Foundation
-gives unlimited permission to copy, distribute and modify it."
-
-ac_pwd='$ac_pwd'
-srcdir='$srcdir'
-INSTALL='$INSTALL'
-AWK='$AWK'
-test -n "\$AWK" || AWK=awk
-_ACEOF
-
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-# The default lists apply if the user does not specify any file.
-ac_need_defaults=:
-while test $# != 0
-do
- case $1 in
- --*=?*)
- ac_option=`expr "X$1" : 'X\([^=]*\)='`
- ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
- ac_shift=:
- ;;
- --*=)
- ac_option=`expr "X$1" : 'X\([^=]*\)='`
- ac_optarg=
- ac_shift=:
- ;;
- *)
- ac_option=$1
- ac_optarg=$2
- ac_shift=shift
- ;;
- esac
-
- case $ac_option in
- # Handling of the options.
- -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
- ac_cs_recheck=: ;;
- --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
- $as_echo "$ac_cs_version"; exit ;;
- --config | --confi | --conf | --con | --co | --c )
- $as_echo "$ac_cs_config"; exit ;;
- --debug | --debu | --deb | --de | --d | -d )
- debug=: ;;
- --file | --fil | --fi | --f )
- $ac_shift
- case $ac_optarg in
- *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
- '') as_fn_error $? "missing file argument" ;;
- esac
- as_fn_append CONFIG_FILES " '$ac_optarg'"
- ac_need_defaults=false;;
- --he | --h | --help | --hel | -h )
- $as_echo "$ac_cs_usage"; exit ;;
- -q | -quiet | --quiet | --quie | --qui | --qu | --q \
- | -silent | --silent | --silen | --sile | --sil | --si | --s)
- ac_cs_silent=: ;;
-
- # This is an error.
- -*) as_fn_error $? "unrecognized option: \`$1'
-Try \`$0 --help' for more information." ;;
-
- *) as_fn_append ac_config_targets " $1"
- ac_need_defaults=false ;;
-
- esac
- shift
-done
-
-ac_configure_extra_args=
-
-if $ac_cs_silent; then
- exec 6>/dev/null
- ac_configure_extra_args="$ac_configure_extra_args --silent"
-fi
-
-_ACEOF
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-if \$ac_cs_recheck; then
- set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
- shift
- \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
- CONFIG_SHELL='$SHELL'
- export CONFIG_SHELL
- exec "\$@"
-fi
-
-_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-exec 5>>config.log
-{
- echo
- sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
-## Running $as_me. ##
-_ASBOX
- $as_echo "$ac_log"
-} >&5
-
-_ACEOF
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-#
-# INIT-COMMANDS
-#
-extrasub_build="$extrasub_build"
- extrasub_host="$extrasub_host"
- extrasub_target="$extrasub_target"
-
-_ACEOF
-
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-
-# Handling of arguments.
-for ac_config_target in $ac_config_targets
-do
- case $ac_config_target in
- "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
-
- *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
- esac
-done
-
-
-# If the user did not use the arguments to specify the items to instantiate,
-# then the envvar interface is used. Set only those that are not.
-# We use the long form for the default assignment because of an extremely
-# bizarre bug on SunOS 4.1.3.
-if $ac_need_defaults; then
- test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
-fi
-
-# Have a temporary directory for convenience. Make it in the build tree
-# simply because there is no reason against having it here, and in addition,
-# creating and moving files from /tmp can sometimes cause problems.
-# Hook for its removal unless debugging.
-# Note that there is a small window in which the directory will not be cleaned:
-# after its creation but before its name has been assigned to `$tmp'.
-$debug ||
-{
- tmp= ac_tmp=
- trap 'exit_status=$?
- : "${ac_tmp:=$tmp}"
- { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
-' 0
- trap 'as_fn_exit 1' 1 2 13 15
-}
-# Create a (secure) tmp directory for tmp files.
-
-{
- tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
- test -d "$tmp"
-} ||
-{
- tmp=./conf$$-$RANDOM
- (umask 077 && mkdir "$tmp")
-} || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
-ac_tmp=$tmp
-
-# Set up the scripts for CONFIG_FILES section.
-# No need to generate them if there are no CONFIG_FILES.
-# This happens for instance with `./config.status config.h'.
-if test -n "$CONFIG_FILES"; then
-
-if $AWK 'BEGIN { getline <"/dev/null" }' </dev/null 2>/dev/null; then
- ac_cs_awk_getline=:
- ac_cs_awk_pipe_init=
- ac_cs_awk_read_file='
- while ((getline aline < (F[key])) > 0)
- print(aline)
- close(F[key])'
- ac_cs_awk_pipe_fini=
-else
- ac_cs_awk_getline=false
- ac_cs_awk_pipe_init="print \"cat <<'|#_!!_#|' &&\""
- ac_cs_awk_read_file='
- print "|#_!!_#|"
- print "cat " F[key] " &&"
- '$ac_cs_awk_pipe_init
- # The final `:' finishes the AND list.
- ac_cs_awk_pipe_fini='END { print "|#_!!_#|"; print ":" }'
-fi
-ac_cr=`echo X | tr X '\015'`
-# On cygwin, bash can eat \r inside `` if the user requested igncr.
-# But we know of no other shell where ac_cr would be empty at this
-# point, so we can use a bashism as a fallback.
-if test "x$ac_cr" = x; then
- eval ac_cr=\$\'\\r\'
-fi
-ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
-if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
- ac_cs_awk_cr='\\r'
-else
- ac_cs_awk_cr=$ac_cr
-fi
-
-echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
-_ACEOF
-
-# Create commands to substitute file output variables.
-{
- echo "cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1" &&
- echo 'cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&' &&
- echo "$ac_subst_files" | sed 's/.*/F["&"]="$&"/' &&
- echo "_ACAWK" &&
- echo "_ACEOF"
-} >conf$$files.sh &&
-. ./conf$$files.sh ||
- as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
-rm -f conf$$files.sh
-
-{
- echo "cat >conf$$subs.awk <<_ACEOF" &&
- echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
- echo "_ACEOF"
-} >conf$$subs.sh ||
- as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
-ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
-ac_delim='%!_!# '
-for ac_last_try in false false false false false :; do
- . ./conf$$subs.sh ||
- as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
-
- ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
- if test $ac_delim_n = $ac_delim_num; then
- break
- elif $ac_last_try; then
- as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
- else
- ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
- fi
-done
-rm -f conf$$subs.sh
-
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
-_ACEOF
-sed -n '
-h
-s/^/S["/; s/!.*/"]=/
-p
-g
-s/^[^!]*!//
-:repl
-t repl
-s/'"$ac_delim"'$//
-t delim
-:nl
-h
-s/\(.\{148\}\)..*/\1/
-t more1
-s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
-p
-n
-b repl
-:more1
-s/["\\]/\\&/g; s/^/"/; s/$/"\\/
-p
-g
-s/.\{148\}//
-t nl
-:delim
-h
-s/\(.\{148\}\)..*/\1/
-t more2
-s/["\\]/\\&/g; s/^/"/; s/$/"/
-p
-b
-:more2
-s/["\\]/\\&/g; s/^/"/; s/$/"\\/
-p
-g
-s/.\{148\}//
-t delim
-' <conf$$subs.awk | sed '
-/^[^""]/{
- N
- s/\n//
-}
-' >>$CONFIG_STATUS || ac_write_fail=1
-rm -f conf$$subs.awk
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-_ACAWK
-cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
- for (key in S) S_is_set[key] = 1
- FS = ""
- \$ac_cs_awk_pipe_init
-}
-{
- line = $ 0
- nfields = split(line, field, "@")
- substed = 0
- len = length(field[1])
- for (i = 2; i < nfields; i++) {
- key = field[i]
- keylen = length(key)
- if (S_is_set[key]) {
- value = S[key]
- line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
- len += length(value) + length(field[++i])
- substed = 1
- } else
- len += 1 + keylen
- }
- if (nfields == 3 && !substed) {
- key = field[2]
- if (F[key] != "" && line ~ /^[ ]*@.*@[ ]*$/) {
- \$ac_cs_awk_read_file
- next
- }
- }
- print line
-}
-\$ac_cs_awk_pipe_fini
-_ACAWK
-_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
- sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
-else
- cat
-fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
- || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
-_ACEOF
-
-# VPATH may cause trouble with some makes, so we remove sole $(srcdir),
-# ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
-# trailing colons and then remove the whole line if VPATH becomes empty
-# (actually we leave an empty line to preserve line numbers).
-if test "x$srcdir" = x.; then
- ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{
-h
-s///
-s/^/:/
-s/[ ]*$/:/
-s/:\$(srcdir):/:/g
-s/:\${srcdir}:/:/g
-s/:@srcdir@:/:/g
-s/^:*//
-s/:*$//
-x
-s/\(=[ ]*\).*/\1/
-G
-s/\n//
-s/^[^=]*=[ ]*$//
-}'
-fi
-
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-fi # test -n "$CONFIG_FILES"
-
-
-eval set X " :F $CONFIG_FILES "
-shift
-for ac_tag
-do
- case $ac_tag in
- :[FHLC]) ac_mode=$ac_tag; continue;;
- esac
- case $ac_mode$ac_tag in
- :[FHL]*:*);;
- :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
- :[FH]-) ac_tag=-:-;;
- :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
- esac
- ac_save_IFS=$IFS
- IFS=:
- set x $ac_tag
- IFS=$ac_save_IFS
- shift
- ac_file=$1
- shift
-
- case $ac_mode in
- :L) ac_source=$1;;
- :[FH])
- ac_file_inputs=
- for ac_f
- do
- case $ac_f in
- -) ac_f="$ac_tmp/stdin";;
- *) # Look for the file first in the build tree, then in the source tree
- # (if the path is not absolute). The absolute path cannot be DOS-style,
- # because $ac_f cannot contain `:'.
- test -f "$ac_f" ||
- case $ac_f in
- [\\/$]*) false;;
- *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
- esac ||
- as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
- esac
- case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
- as_fn_append ac_file_inputs " '$ac_f'"
- done
-
- # Let's still pretend it is `configure' which instantiates (i.e., don't
- # use $as_me), people would be surprised to read:
- # /* config.h. Generated by config.status. */
- configure_input='Generated from '`
- $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
- `' by configure.'
- if test x"$ac_file" != x-; then
- configure_input="$ac_file. $configure_input"
- { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
-$as_echo "$as_me: creating $ac_file" >&6;}
- fi
- # Neutralize special characters interpreted by sed in replacement strings.
- case $configure_input in #(
- *\&* | *\|* | *\\* )
- ac_sed_conf_input=`$as_echo "$configure_input" |
- sed 's/[\\\\&|]/\\\\&/g'`;; #(
- *) ac_sed_conf_input=$configure_input;;
- esac
-
- case $ac_tag in
- *:-:* | *:-) cat >"$ac_tmp/stdin" \
- || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
- esac
- ;;
- esac
-
- ac_dir=`$as_dirname -- "$ac_file" ||
-$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$ac_file" : 'X\(//\)[^/]' \| \
- X"$ac_file" : 'X\(//\)$' \| \
- X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$ac_file" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
- as_dir="$ac_dir"; as_fn_mkdir_p
- ac_builddir=.
-
-case "$ac_dir" in
-.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
-*)
- ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
- # A ".." for each directory in $ac_dir_suffix.
- ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
- case $ac_top_builddir_sub in
- "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
- *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
- esac ;;
-esac
-ac_abs_top_builddir=$ac_pwd
-ac_abs_builddir=$ac_pwd$ac_dir_suffix
-# for backward compatibility:
-ac_top_builddir=$ac_top_build_prefix
-
-case $srcdir in
- .) # We are building in place.
- ac_srcdir=.
- ac_top_srcdir=$ac_top_builddir_sub
- ac_abs_top_srcdir=$ac_pwd ;;
- [\\/]* | ?:[\\/]* ) # Absolute name.
- ac_srcdir=$srcdir$ac_dir_suffix;
- ac_top_srcdir=$srcdir
- ac_abs_top_srcdir=$srcdir ;;
- *) # Relative name.
- ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
- ac_top_srcdir=$ac_top_build_prefix$srcdir
- ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
-esac
-ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
-
-
- case $ac_mode in
- :F)
- #
- # CONFIG_FILE
- #
-
- case $INSTALL in
- [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
- *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
- esac
-_ACEOF
-
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-# If the template does not know about datarootdir, expand it.
-# FIXME: This hack should be removed a few years after 2.60.
-ac_datarootdir_hack=; ac_datarootdir_seen=
-ac_sed_dataroot='
-/datarootdir/ {
- p
- q
-}
-/@datadir@/p
-/@docdir@/p
-/@infodir@/p
-/@localedir@/p
-/@mandir@/p'
-case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
-*datarootdir*) ac_datarootdir_seen=yes;;
-*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
-$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
-_ACEOF
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
- ac_datarootdir_hack='
- s&@datadir@&$datadir&g
- s&@docdir@&$docdir&g
- s&@infodir@&$infodir&g
- s&@localedir@&$localedir&g
- s&@mandir@&$mandir&g
- s&\\\${datarootdir}&$datarootdir&g' ;;
-esac
-_ACEOF
-
-# Neutralize VPATH when `$srcdir' = `.'.
-# Shell code in configure.ac might set extrasub.
-# FIXME: do we really want to maintain this feature?
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-ac_sed_extra="$ac_vpsub
-$extrasub
-_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-:t
-/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
-s|@configure_input@|$ac_sed_conf_input|;t t
-s&@top_builddir@&$ac_top_builddir_sub&;t t
-s&@top_build_prefix@&$ac_top_build_prefix&;t t
-s&@srcdir@&$ac_srcdir&;t t
-s&@abs_srcdir@&$ac_abs_srcdir&;t t
-s&@top_srcdir@&$ac_top_srcdir&;t t
-s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
-s&@builddir@&$ac_builddir&;t t
-s&@abs_builddir@&$ac_abs_builddir&;t t
-s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
-s&@INSTALL@&$ac_INSTALL&;t t
-$ac_datarootdir_hack
-"
-eval sed \"\$ac_sed_extra\" "$ac_file_inputs" |
-if $ac_cs_awk_getline; then
- $AWK -f "$ac_tmp/subs.awk"
-else
- $AWK -f "$ac_tmp/subs.awk" | $SHELL
-fi \
- >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
-
-test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
- { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
- { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \
- "$ac_tmp/out"`; test -z "$ac_out"; } &&
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
-which seems to be undefined. Please make sure it is defined" >&5
-$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
-which seems to be undefined. Please make sure it is defined" >&2;}
-
- rm -f "$ac_tmp/stdin"
- case $ac_file in
- -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
- *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
- esac \
- || as_fn_error $? "could not create $ac_file" "$LINENO" 5
- ;;
-
-
-
- esac
-
-
- case $ac_file$ac_mode in
- "Makefile":F) sed "$extrasub_build" Makefile |
- sed "$extrasub_host" |
- sed "$extrasub_target" > mf$$
- mv -f mf$$ Makefile ;;
-
- esac
-done # for ac_tag
-
-
-as_fn_exit 0
-_ACEOF
-ac_clean_files=$ac_clean_files_save
-
-test $ac_write_fail = 0 ||
- as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
-
-
-# configure is writing to config.log, and then calls config.status.
-# config.status does its own redirection, appending to config.log.
-# Unfortunately, on DOS this fails, as config.log is still kept open
-# by configure, so config.status won't be able to write to it; its
-# output is simply discarded. So we exec the FD to /dev/null,
-# effectively closing config.log, so it can be properly (re)opened and
-# appended to by config.status. When coming back to configure, we
-# need to make the FD available again.
-if test "$no_create" != yes; then
- ac_cs_success=:
- ac_config_status_args=
- test "$silent" = yes &&
- ac_config_status_args="$ac_config_status_args --quiet"
- exec 5>/dev/null
- $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
- exec 5>>config.log
- # Use ||, not &&, to avoid exiting from the if with $? = 1, which
- # would make configure fail if this is the last instruction.
- $ac_cs_success || as_fn_exit 1
-fi
-if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
-$as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
-fi
-
Property changes on: sources/GNU/binutils/create-2.43.1-not-link-static-libstdc++-patch/binutils-2.43.1-new/configure
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: sources/GNU/binutils/create-2.43.1-not-link-static-libstdc++-patch/binutils-2.43.1-new/configure.ac
===================================================================
--- sources/GNU/binutils/create-2.43.1-not-link-static-libstdc++-patch/binutils-2.43.1-new/configure.ac (revision 75)
+++ sources/GNU/binutils/create-2.43.1-not-link-static-libstdc++-patch/binutils-2.43.1-new/configure.ac (nonexistent)
@@ -1,3988 +0,0 @@
-# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000,
-# 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012,
-# 2014, 2015, 2016, 2019, 2022 Free Software Foundation, Inc.
-#
-# This file is free software; you can redistribute it and/or modify it
-# under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 3 of the License, or
-# (at your option) any later version.
-#
-# This program is distributed in the hope that it will be useful, but
-# WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-# General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this program; see the file COPYING3. If not see
-# <http://www.gnu.org/licenses/>.
-
-##############################################################################
-### WARNING: this file contains embedded tabs. Do not run untabify on this file.
-
-m4_include(config/acx.m4)
-m4_include(config/override.m4)
-m4_include(config/proginstall.m4)
-m4_include(config/elf.m4)
-m4_include(config/ax_cxx_compile_stdcxx.m4)
-m4_include(config/gcc-plugin.m4)
-m4_include([libtool.m4])
-m4_include([ltoptions.m4])
-m4_include([ltsugar.m4])
-m4_include([ltversion.m4])
-m4_include([lt~obsolete.m4])
-m4_include([config/isl.m4])
-
-AC_INIT
-AC_CONFIG_SRCDIR([move-if-change])
-AC_DISABLE_OPTION_CHECKING
-
-progname=$0
-# if PWD already has a value, it is probably wrong.
-if test -n "$PWD" ; then PWD=`${PWDCMD-pwd}`; fi
-
-# Export original configure arguments for use by sub-configures.
-# Quote arguments with shell meta charatcers.
-TOPLEVEL_CONFIGURE_ARGUMENTS=
-set -- "$progname" "$@"
-for ac_arg
-do
- case "$ac_arg" in
- *" "*|*" "*|*[[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\']]*)
- ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"`
- # if the argument is of the form -foo=baz, quote the baz part only
- ac_arg=`echo "'$ac_arg'" | sed "s/^'\([[-a-zA-Z0-9]]*=\)/\\1'/"` ;;
- *) ;;
- esac
- # Add the quoted argument to the list.
- TOPLEVEL_CONFIGURE_ARGUMENTS="$TOPLEVEL_CONFIGURE_ARGUMENTS $ac_arg"
-done
-if test "$silent" = yes; then
- TOPLEVEL_CONFIGURE_ARGUMENTS="$TOPLEVEL_CONFIGURE_ARGUMENTS --silent"
-fi
-# Remove the initial space we just introduced and, as these will be
-# expanded by make, quote '$'.
-TOPLEVEL_CONFIGURE_ARGUMENTS=`echo "x$TOPLEVEL_CONFIGURE_ARGUMENTS" | sed -e 's/^x *//' -e 's,\\$,$$,g'`
-AC_SUBST(TOPLEVEL_CONFIGURE_ARGUMENTS)
-
-# Find the build, host, and target systems.
-ACX_NONCANONICAL_BUILD
-ACX_NONCANONICAL_HOST
-ACX_NONCANONICAL_TARGET
-
-dnl Autoconf 2.5x and later will set a default program prefix if
-dnl --target was used, even if it was the same as --host. Disable
-dnl that behavior. This must be done before AC_CANONICAL_TARGET
-dnl to take effect.
-test "$host_noncanonical" = "$target_noncanonical" &&
- test "$program_prefix$program_suffix$program_transform_name" = \
- NONENONEs,x,x, &&
- program_transform_name=s,y,y,
-
-AC_CANONICAL_TARGET
-AC_ARG_PROGRAM
-
-m4_pattern_allow([^AS_FOR_TARGET$])dnl
-m4_pattern_allow([^AS_FOR_BUILD$])dnl
-
-# Get 'install' or 'install-sh' and its variants.
-AC_PROG_INSTALL
-ACX_PROG_LN
-AC_PROG_LN_S
-AC_PROG_SED
-AC_PROG_AWK
-
-srcpwd=`cd ${srcdir} ; ${PWDCMD-pwd}`
-
-# We pass INSTALL explicitly to sub-makes. Make sure that it is not
-# a relative path.
-if test "$INSTALL" = "${srcdir}/install-sh -c"; then
- INSTALL="${srcpwd}/install-sh -c"
-fi
-
-# Set srcdir to "." if that's what it is.
-# This is important for multilib support.
-pwd=`${PWDCMD-pwd}`
-if test "${pwd}" = "${srcpwd}" ; then
- srcdir=.
-fi
-
-topsrcdir=$srcpwd
-
-extra_host_args=
-
-### To add a new directory to the tree, first choose whether it is a target
-### or a host dependent tool. Then put it into the appropriate list
-### (library or tools, host or target), doing a dependency sort.
-
-# Subdirs will be configured in the order listed in build_configdirs,
-# configdirs, or target_configdirs; see the serialization section below.
-
-# Dependency sorting is only needed when *configuration* must be done in
-# a particular order. In all cases a dependency should be specified in
-# the Makefile, whether or not it's implicitly specified here.
-
-# Double entries in build_configdirs, configdirs, or target_configdirs may
-# cause circular dependencies and break everything horribly.
-
-# these library is used by various programs built for the build
-# environment
-#
-build_libs="build-libiberty build-libcpp"
-
-# these tools are built for the build environment
-build_tools="build-texinfo build-flex build-bison build-m4 build-fixincludes"
-
-# these libraries are used by various programs built for the host environment
-#f
-host_libs="gettext libiberty opcodes bfd readline tcl tk itcl libgui zlib libbacktrace libcpp libcody libdecnumber gmp mpfr mpc isl libiconv libctf libsframe libgrust "
-
-# these tools are built for the host environment
-# Note, the powerpc-eabi build depends on sim occurring before gdb in order to
-# know that we are building the simulator.
-# binutils, gas and ld appear in that order because it makes sense to run
-# "make check" in that particular order.
-# If --enable-gold is used, "gold" may replace "ld".
-host_tools="flex bison binutils gas ld fixincludes gcc cgen sid sim gdb gdbserver gprof etc expect dejagnu m4 utils guile fastjar gnattools libcc1 gm2tools gotools c++tools"
-
-# these libraries are built for the target environment, and are built after
-# the host libraries and the host tools (which may be a cross compiler)
-# Note that libiberty is not a target library.
-target_libraries="target-libgcc \
- target-libbacktrace \
- target-libgloss \
- target-newlib \
- target-libgomp \
- target-libatomic \
- target-libitm \
- target-libstdc++-v3 \
- target-libsanitizer \
- target-libvtv \
- target-libssp \
- target-libquadmath \
- target-libgfortran \
- target-libffi \
- target-libobjc \
- target-libada \
- target-libgm2 \
- target-libgo \
- target-libgrust \
- target-libphobos \
- target-zlib"
-
-# these tools are built using the target libraries, and are intended to
-# run only in the target environment
-#
-# note: any program that *uses* libraries that are in the "target_libraries"
-# list belongs in this list.
-#
-target_tools="target-rda"
-
-################################################################################
-
-## All tools belong in one of the four categories, and are assigned above
-## We assign ${configdirs} this way to remove all embedded newlines. This
-## is important because configure will choke if they ever get through.
-## ${configdirs} is directories we build using the host tools.
-## ${target_configdirs} is directories we build using the target tools.
-configdirs=`echo ${host_libs} ${host_tools}`
-target_configdirs=`echo ${target_libraries} ${target_tools}`
-build_configdirs=`echo ${build_libs} ${build_tools}`
-
-m4_divert_text([PARSE_ARGS],
-[case $srcdir in
- *" "*)
-m4_pushdef([AS_MESSAGE_LOG_FD], [])dnl
- AC_MSG_ERROR([path to source, $srcdir, contains spaces])
-m4_popdef([AS_MESSAGE_LOG_FD])dnl
- ;;
-esac
-ac_subdirs_all=`cd $srcdir && echo */configure | sed 's,/configure,,g'`
-])
-
-################################################################################
-
-srcname="gnu development package"
-
-# This gets set non-empty for some net releases of packages.
-appdirs=""
-
-# Define is_cross_compiler to save on calls to 'test'.
-is_cross_compiler=
-if test x"${host}" = x"${target}" ; then
- is_cross_compiler=no
-else
- is_cross_compiler=yes
-fi
-
-# Find the build and target subdir names.
-GCC_TOPLEV_SUBDIRS
-# Be sure to cover against remnants of an in-tree build.
-if test $srcdir != . && test -d $srcdir/host-${host_noncanonical}; then
- AC_MSG_ERROR([building out of tree but $srcdir contains host-${host_noncanonical}.
-Use a pristine source tree when building in a separate tree])
-fi
-
-# Skipdirs are removed silently.
-skipdirs=
-# Noconfigdirs are removed loudly.
-noconfigdirs=""
-
-use_gnu_ld=
-# Make sure we don't let GNU ld be added if we didn't want it.
-if test x$with_gnu_ld = xno ; then
- use_gnu_ld=no
- noconfigdirs="$noconfigdirs ld gold"
-fi
-
-use_gnu_as=
-# Make sure we don't let GNU as be added if we didn't want it.
-if test x$with_gnu_as = xno ; then
- use_gnu_as=no
- noconfigdirs="$noconfigdirs gas"
-fi
-
-use_included_zlib=
-AC_ARG_WITH(system-zlib,
-[AS_HELP_STRING([--with-system-zlib], [use installed libz])])
-# Make sure we don't let ZLIB be added if we didn't want it.
-if test x$with_system_zlib = xyes ; then
- use_included_zlib=no
- noconfigdirs="$noconfigdirs zlib"
-fi
-
-# Don't compile the bundled readline/libreadline.a if --with-system-readline
-# is provided.
-if test x$with_system_readline = xyes ; then
- noconfigdirs="$noconfigdirs readline"
-fi
-
-AC_ARG_WITH(zstd,
-[AS_HELP_STRING([--with-zstd], [Support zstd compressed debug sections (default=auto)])])
-
-# some tools are so dependent upon X11 that if we're not building with X,
-# it's not even worth trying to configure, much less build, that tool.
-
-case ${with_x} in
- yes | "") ;; # the default value for this tree is that X11 is available
- no)
- skipdirs="${skipdirs} tk itcl libgui"
- # We won't be able to build gdbtk without X.
- enable_gdbtk=no
- ;;
- *) echo "*** bad value \"${with_x}\" for -with-x flag; ignored" 1>&2 ;;
-esac
-
-# Some are only suitable for cross toolchains.
-# Remove these if host=target.
-cross_only="target-libgloss target-newlib target-opcodes"
-
-case $is_cross_compiler in
- no) skipdirs="${skipdirs} ${cross_only}" ;;
-esac
-
-# If both --with-headers and --with-libs are specified, default to
-# --without-newlib.
-if test x"${with_headers}" != x && test x"${with_headers}" != xno \
- && test x"${with_libs}" != x && test x"${with_libs}" != xno ; then
- if test x"${with_newlib}" = x ; then
- with_newlib=no
- fi
-fi
-
-# Recognize --with-newlib/--without-newlib.
-case ${with_newlib} in
- no) skipdirs="${skipdirs} target-newlib" ;;
- yes) skipdirs=`echo " ${skipdirs} " | sed -e 's/ target-newlib / /'` ;;
-esac
-
-AC_ARG_ENABLE(as-accelerator-for,
-[AS_HELP_STRING([--enable-as-accelerator-for=ARG],
- [build as offload target compiler.
- Specify offload host triple by ARG])])
-
-AC_ARG_ENABLE(offload-targets,
-[AS_HELP_STRING([--enable-offload-targets=LIST],
- [enable offloading to devices from comma-separated LIST of
- TARGET[=DIR]. Use optional path to find offload target compiler
- during the build])],
-[
- if test x"$enable_offload_targets" = x; then
- AC_MSG_ERROR([no offload targets specified])
- fi
-], [enable_offload_targets=])
-
-AC_ARG_ENABLE(offload-defaulted,
-[AS_HELP_STRING([--enable-offload-defaulted]
- [If enabled, configured but not installed offload compilers and
- libgomp plugins are silently ignored. Useful for distribution
- compilers where those are in separate optional packages.])],
-[enable_offload_defaulted=$enableval],
-[enable_offload_defaulted=])
-
-# Handle --enable-gold, --enable-ld.
-# --disable-gold [--enable-ld]
-# Build only ld. Default option.
-# --enable-gold [--enable-ld]
-# Build both gold and ld. Install gold as "ld.gold", install ld
-# as "ld.bfd" and "ld".
-# --enable-gold=default [--enable-ld]
-# Build both gold and ld. Install gold as "ld.gold" and "ld",
-# install ld as "ld.bfd".
-# --enable-gold[=default] --disable-ld
-# Build only gold, which is then installed as both "ld.gold" and "ld".
-# --enable-gold --enable-ld=default
-# Build both gold (installed as "ld.gold") and ld (installed as "ld"
-# and ld.bfd).
-# In other words, ld is default
-# --enable-gold=default --enable-ld=default
-# Error.
-
-default_ld=
-AC_ARG_ENABLE(gold,
-[AS_HELP_STRING([[--enable-gold[=ARG]]],
- [build gold @<:@ARG={default,yes,no}@:>@])],
-ENABLE_GOLD=$enableval,
-ENABLE_GOLD=no)
-case "${ENABLE_GOLD}" in
- yes|default)
- # Check for ELF target.
- is_elf=no
- case "${target}" in
- *-*-elf* | *-*-sysv4* | *-*-unixware* | *-*-eabi* | hppa*64*-*-hpux* \
- | *-*-linux* | *-*-gnu* | frv-*-uclinux* | *-*-irix5* | *-*-irix6* \
- | *-*-netbsd* | *-*-openbsd* | *-*-freebsd* | *-*-dragonfly* \
- | *-*-solaris2* | *-*-nto* | *-*-nacl* | *-*-haiku*)
- case "${target}" in
- *-*-linux*aout* | *-*-linux*oldld*)
- ;;
- *)
- is_elf=yes
- ;;
- esac
- esac
-
- if test "$is_elf" = "yes"; then
- # Check for target supported by gold.
- case "${target}" in
- i?86-*-* | x86_64-*-* | sparc*-*-* | powerpc*-*-* | arm*-*-* \
- | aarch64*-*-* | tilegx*-*-* | mips*-*-* | s390*-*-* | loongarch*-*-*)
- configdirs="$configdirs gold"
- if test x${ENABLE_GOLD} = xdefault; then
- default_ld=gold
- fi
- ENABLE_GOLD=yes
- ;;
- esac
- fi
- ;;
- no)
- ;;
- *)
- AC_MSG_ERROR([invalid --enable-gold argument])
- ;;
-esac
-
-AC_ARG_ENABLE(ld,
-[AS_HELP_STRING([[--enable-ld[=ARG]]],
- [build ld @<:@ARG={default,yes,no}@:>@])],
-ENABLE_LD=$enableval,
-ENABLE_LD=yes)
-
-case "${ENABLE_LD}" in
- default)
- if test x${default_ld} != x; then
- AC_MSG_ERROR([either gold or ld can be the default ld])
- fi
- ;;
- yes)
- ;;
- no)
- if test x${ENABLE_GOLD} != xyes; then
- AC_MSG_WARN([neither ld nor gold are enabled])
- fi
- configdirs=`echo " ${configdirs} " | sed -e 's/ ld / /'`
- ;;
- *)
- AC_MSG_ERROR([invalid --enable-ld argument])
- ;;
-esac
-
-AC_ARG_ENABLE(gprofng,
-[AS_HELP_STRING([[--enable-gprofng[=ARG]]],
- [build gprofng @<:@ARG={yes,no}@:>@])],
-enable_gprofng=$enableval,
-enable_gprofng=yes)
-if test "$enable_gprofng" = "yes"; then
- case "${target}" in
- x86_64-*-linux* | i?86-*-linux* | aarch64-*-linux* | riscv64-*-linux*)
- configdirs="$configdirs gprofng"
- ;;
- esac
-fi
-
-
-# PR gas/19109
-# Decide the default method for compressing debug sections.
-# Provide a configure time option to override our default.
-AC_ARG_ENABLE(compressed_debug_sections,
-[AS_HELP_STRING([--enable-compressed-debug-sections={all,gas,gold,ld,none}],
- [Enable compressed debug sections for gas, gold or ld by
- default])],
-[
- if test x"$enable_compressed_debug_sections" = xyes; then
- AC_MSG_ERROR([no program with compressed debug sections specified])
- fi
-], [enable_compressed_debug_sections=])
-
-# Select default compression algorithm.
-AC_ARG_ENABLE(default_compressed_debug_sections_algorithm,
-[AS_HELP_STRING([--enable-default-compressed-debug-sections-algorithm={zlib,zstd}],
- [Default compression algorithm for --enable-compressed-debug-sections.])],
-[], [default_compressed_debug_sections_algorithm=])
-
-# Configure extra directories which are host specific
-
-case "${host}" in
- *-cygwin*)
- configdirs="$configdirs libtermcap" ;;
-esac
-
-# A target can indicate whether a language isn't supported for some reason.
-# Only spaces may be used in this macro; not newlines or tabs.
-unsupported_languages=
-
-# Remove more programs from consideration, based on the host or
-# target this usually means that a port of the program doesn't
-# exist yet.
-
-case "${host}" in
- i[[3456789]]86-*-msdosdjgpp*)
- noconfigdirs="$noconfigdirs tcl tk itcl"
- ;;
-esac
-
-# Default to --disable-year2038 until we can handle differences between
-# projects that use gnulib (which understands year 2038) and projects that
-# do not (like BFD).
-AC_ARG_ENABLE(year2038,
-AS_HELP_STRING([--enable-year2038],
- [enable support for timestamps past the year 2038]),
-ENABLE_YEAR2038=$enableval,
-ENABLE_YEAR2038=no)
-enable_year2038=
-if test "${ENABLE_YEAR2038}" = "no" ; then
- enable_year2038=no
-fi
-
-AC_ARG_ENABLE(libquadmath,
-AS_HELP_STRING([--disable-libquadmath],
- [do not build libquadmath directory]),
-ENABLE_LIBQUADMATH=$enableval,
-ENABLE_LIBQUADMATH=yes)
-if test "${ENABLE_LIBQUADMATH}" = "no" ; then
- noconfigdirs="$noconfigdirs target-libquadmath"
-fi
-
-
-AC_ARG_ENABLE(libquadmath-support,
-AS_HELP_STRING([--disable-libquadmath-support],
- [disable libquadmath support for Fortran]),
-ENABLE_LIBQUADMATH_SUPPORT=$enableval,
-ENABLE_LIBQUADMATH_SUPPORT=yes)
-enable_libquadmath_support=
-if test "${ENABLE_LIBQUADMATH_SUPPORT}" = "no" ; then
- enable_libquadmath_support=no
-fi
-
-
-AC_ARG_ENABLE(libada,
-[AS_HELP_STRING([--enable-libada], [build libada directory])],
-ENABLE_LIBADA=$enableval,
-ENABLE_LIBADA=yes)
-if test "${ENABLE_LIBADA}" != "yes" ; then
- noconfigdirs="$noconfigdirs gnattools"
-fi
-
-AC_ARG_ENABLE(libgm2,
-[AS_HELP_STRING([--enable-libgm2], [build libgm2 directory])],
-ENABLE_LIBGM2=$enableval,
-ENABLE_LIBGM2=no)
-if test "${ENABLE_LIBGM2}" != "yes" ; then
- noconfigdirs="$noconfigdirs gm2tools"
-fi
-
-AC_ARG_ENABLE(libssp,
-[AS_HELP_STRING([--enable-libssp], [build libssp directory])],
-ENABLE_LIBSSP=$enableval,
-ENABLE_LIBSSP=yes)
-
-AC_ARG_ENABLE(libstdcxx,
-AS_HELP_STRING([--disable-libstdcxx],
- [do not build libstdc++-v3 directory]),
-ENABLE_LIBSTDCXX=$enableval,
-ENABLE_LIBSTDCXX=default)
-[if test "${ENABLE_LIBSTDCXX}" = "no" ; then
- noconfigdirs="$noconfigdirs target-libstdc++-v3"
-fi]
-
-# Enable libgomp by default on hosted POSIX systems, and a few others.
-if test x$enable_libgomp = x ; then
- case "${target}" in
- *-*-linux* | *-*-gnu* | *-*-k*bsd*-gnu | *-*-kopensolaris*-gnu)
- ;;
- *-*-netbsd* | *-*-freebsd* | *-*-openbsd* | *-*-dragonfly*)
- ;;
- *-*-solaris2* | *-*-hpux11*)
- ;;
- *-*-darwin* | *-*-aix*)
- ;;
- nvptx*-*-* | amdgcn*-*-*)
- ;;
- *)
- noconfigdirs="$noconfigdirs target-libgomp"
- ;;
- esac
-fi
-
-# Disable libatomic on unsupported systems.
-if test -d ${srcdir}/libatomic; then
- if test x$enable_libatomic = x; then
- AC_MSG_CHECKING([for libatomic support])
- if (srcdir=${srcdir}/libatomic; \
- . ${srcdir}/configure.tgt; \
- test -n "$UNSUPPORTED")
- then
- AC_MSG_RESULT([no])
- noconfigdirs="$noconfigdirs target-libatomic"
- else
- AC_MSG_RESULT([yes])
- fi
- fi
-fi
-
-# Disable libitm on unsupported systems.
-if test -d ${srcdir}/libitm; then
- if test x$enable_libitm = x; then
- AC_MSG_CHECKING([for libitm support])
- if (srcdir=${srcdir}/libitm; \
- . ${srcdir}/configure.tgt; \
- test -n "$UNSUPPORTED")
- then
- AC_MSG_RESULT([no])
- noconfigdirs="$noconfigdirs target-libitm"
- else
- AC_MSG_RESULT([yes])
- fi
- fi
-fi
-
-# Disable libsanitizer on unsupported systems.
-if test -d ${srcdir}/libsanitizer; then
- if test x$enable_libsanitizer = x; then
- AC_MSG_CHECKING([for libsanitizer support])
- if (srcdir=${srcdir}/libsanitizer; \
- . ${srcdir}/configure.tgt; \
- test -n "$UNSUPPORTED")
- then
- AC_MSG_RESULT([no])
- noconfigdirs="$noconfigdirs target-libsanitizer"
- else
- AC_MSG_RESULT([yes])
- fi
- fi
-fi
-
-# Disable libvtv on unsupported systems.
-if test -d ${srcdir}/libvtv; then
- if test x$enable_libvtv = x; then
- AC_MSG_CHECKING([for libvtv support])
- if (srcdir=${srcdir}/libvtv; \
- . ${srcdir}/configure.tgt; \
- test "$VTV_SUPPORTED" != "yes")
- then
- AC_MSG_RESULT([no])
- noconfigdirs="$noconfigdirs target-libvtv"
- else
- AC_MSG_RESULT([yes])
- fi
- fi
-fi
-
-# Disable libquadmath for some systems.
-case "${target}" in
- avr-*-*)
- noconfigdirs="$noconfigdirs target-libquadmath"
- ;;
- # libquadmath is unused on AIX and libquadmath build process use of
- # LD_LIBRARY_PATH can break AIX bootstrap.
- powerpc-*-aix* | rs6000-*-aix*)
- noconfigdirs="$noconfigdirs target-libquadmath"
- ;;
-esac
-
-# Disable libssp for some systems.
-case "${target}" in
- avr-*-*)
- # No hosted I/O support.
- noconfigdirs="$noconfigdirs target-libssp"
- ;;
- bpf-*-*)
- noconfigdirs="$noconfigdirs target-libssp"
- ;;
- powerpc-*-aix* | rs6000-*-aix*)
- noconfigdirs="$noconfigdirs target-libssp"
- ;;
- pru-*-*)
- # No hosted I/O support.
- noconfigdirs="$noconfigdirs target-libssp"
- ;;
- rl78-*-*)
- # libssp uses a misaligned load to trigger a fault, but the RL78
- # doesn't fault for those - instead, it gives a build-time error
- # for explicit misaligned loads.
- noconfigdirs="$noconfigdirs target-libssp"
- ;;
- visium-*-*)
- # No hosted I/O support.
- noconfigdirs="$noconfigdirs target-libssp"
- ;;
-esac
-
-# Disable libstdc++-v3 for some systems.
-# Allow user to override this if they pass --enable-libstdcxx
-if test "${ENABLE_LIBSTDCXX}" = "default" ; then
- case "${target}" in
- *-*-vxworks*)
- # VxWorks uses the Dinkumware C++ library.
- noconfigdirs="$noconfigdirs target-libstdc++-v3"
- ;;
- amdgcn*-*-*)
- # Not ported/fails to build when using newlib.
- noconfigdirs="$noconfigdirs target-libstdc++-v3"
- ;;
- arm*-wince-pe*)
- # the C++ libraries don't build on top of CE's C libraries
- noconfigdirs="$noconfigdirs target-libstdc++-v3"
- ;;
- avr-*-*)
- noconfigdirs="$noconfigdirs target-libstdc++-v3"
- ;;
- bpf-*-*)
- noconfigdirs="$noconfigdirs target-libstdc++-v3"
- ;;
- ft32-*-*)
- noconfigdirs="$noconfigdirs target-libstdc++-v3"
- ;;
- esac
-fi
-
-# Disable C++ on systems where it is known to not work.
-# For testing, you can override this with --enable-languages=c++.
-case ,${enable_languages}, in
- *,c++,*)
- ;;
- *)
- case "${target}" in
- bpf-*-*)
- unsupported_languages="$unsupported_languages c++"
- ;;
- esac
- ;;
-esac
-
-# Disable Objc on systems where it is known to not work.
-# For testing, you can override this with --enable-languages=objc.
-case ,${enable_languages}, in
- *,objc,*)
- ;;
- *)
- case "${target}" in
- bpf-*-*)
- unsupported_languages="$unsupported_languages objc"
- ;;
- esac
- ;;
-esac
-
-# Disable D on systems where it is known to not work.
-# For testing, you can override this with --enable-languages=d.
-case ,${enable_languages}, in
- *,d,*)
- ;;
- *)
- case "${target}" in
- bpf-*-*)
- unsupported_languages="$unsupported_languages d"
- ;;
- esac
- ;;
-esac
-
-# Disable libphobos on unsupported systems.
-# For testing, you can override this with --enable-libphobos.
-if test -d ${srcdir}/libphobos; then
- if test x$enable_libphobos = x; then
- AC_MSG_CHECKING([for libphobos support])
- if (srcdir=${srcdir}/libphobos; \
- . ${srcdir}/configure.tgt; \
- test "$LIBPHOBOS_SUPPORTED" != "yes")
- then
- AC_MSG_RESULT([no])
- noconfigdirs="$noconfigdirs target-libphobos"
- else
- AC_MSG_RESULT([yes])
- fi
- fi
-fi
-
-# Disable Fortran for some systems.
-case "${target}" in
- mmix-*-*)
- # See <http://gcc.gnu.org/ml/gcc-patches/2004-11/msg00572.html>.
- unsupported_languages="$unsupported_languages fortran"
- ;;
- bpf-*-*)
- unsupported_languages="$unsupported_languages fortran"
- ;;
-esac
-
-# Disable libffi for some systems.
-case "${target}" in
- powerpc-*-darwin*)
- ;;
- i[[3456789]]86-*-darwin*)
- ;;
- x86_64-*-darwin[[912]]*)
- ;;
- *-*-darwin*)
- noconfigdirs="$noconfigdirs target-libffi"
- ;;
- *-*-netware*)
- noconfigdirs="$noconfigdirs target-libffi"
- ;;
- *-*-phoenix*)
- noconfigdirs="$noconfigdirs target-libffi"
- ;;
- *-*-rtems*)
- noconfigdirs="$noconfigdirs target-libffi"
- ;;
- *-*-tpf*)
- noconfigdirs="$noconfigdirs target-libffi"
- ;;
- *-*-uclinux*)
- noconfigdirs="$noconfigdirs target-libffi"
- ;;
- *-*-vxworks*)
- noconfigdirs="$noconfigdirs target-libffi"
- ;;
- aarch64*-*-freebsd*)
- noconfigdirs="$noconfigdirs target-libffi"
- ;;
- alpha*-*-*vms*)
- noconfigdirs="$noconfigdirs target-libffi"
- ;;
- arm*-*-freebsd*)
- noconfigdirs="$noconfigdirs target-libffi"
- ;;
- arm-wince-pe)
- noconfigdirs="$noconfigdirs target-libffi"
- ;;
- arm*-*-symbianelf*)
- noconfigdirs="$noconfigdirs target-libffi"
- ;;
- bpf-*-*)
- noconfigdirs="$noconfigdirs target-libffi"
- ;;
- cris-*-* | crisv32-*-*)
- case "${target}" in
- *-*-linux*)
- ;;
- *) # See PR46792 regarding target-libffi.
- noconfigdirs="$noconfigdirs target-libffi";;
- esac
- ;;
- hppa*64*-*-hpux*)
- noconfigdirs="$noconfigdirs target-libffi"
- ;;
- hppa*-hp-hpux11*)
- ;;
- hppa*-*-hpux*)
- noconfigdirs="$noconfigdirs target-libffi"
- ;;
- ia64*-*-*vms*)
- noconfigdirs="$noconfigdirs target-libffi"
- ;;
- i[[3456789]]86-w64-mingw*)
- noconfigdirs="$noconfigdirs target-libffi"
- ;;
- i[[3456789]]86-*-mingw*)
- noconfigdirs="$noconfigdirs target-libffi"
- ;;
- x86_64-*-mingw*)
- noconfigdirs="$noconfigdirs target-libffi"
- ;;
- mmix-*-*)
- noconfigdirs="$noconfigdirs target-libffi"
- ;;
- powerpc-*-aix*)
- ;;
- rs6000-*-aix*)
- ;;
- ft32-*-*)
- noconfigdirs="$noconfigdirs target-libffi"
- ;;
- *-*-lynxos*)
- noconfigdirs="$noconfigdirs target-libffi"
- ;;
-esac
-
-# Disable the go frontend on systems where it is known to not work. Please keep
-# this in sync with contrib/config-list.mk.
-case "${target}" in
-*-*-darwin* | *-*-cygwin* | *-*-mingw* | bpf-* )
- unsupported_languages="$unsupported_languages go"
- ;;
-esac
-
-# Only allow gdbserver on some systems.
-if test -d ${srcdir}/gdbserver; then
- if test x$enable_gdbserver = x; then
- AC_MSG_CHECKING([for gdbserver support])
- if (srcdir=${srcdir}/gdbserver; \
- . ${srcdir}/configure.srv; \
- test -n "$UNSUPPORTED")
- then
- AC_MSG_RESULT([no])
- noconfigdirs="$noconfigdirs gdbserver"
- else
- AC_MSG_RESULT([yes])
- fi
- fi
-fi
-
-# Disable libgo for some systems where it is known to not work.
-# For testing, you can easily override this with --enable-libgo.
-if test x$enable_libgo = x; then
- case "${target}" in
- *-*-darwin*)
- # PR 46986
- noconfigdirs="$noconfigdirs target-libgo"
- ;;
- *-*-cygwin* | *-*-mingw*)
- noconfigdirs="$noconfigdirs target-libgo"
- ;;
- bpf-*-*)
- noconfigdirs="$noconfigdirs target-libgo"
- ;;
- esac
-fi
-
-# Default libgloss CPU subdirectory.
-libgloss_dir="$target_cpu"
-
-case "${target}" in
- sh*-*-pe|mips*-*-pe|*arm-wince-pe)
- libgloss_dir=wince
- ;;
- aarch64*-*-* )
- libgloss_dir=aarch64
- ;;
- arm*-*-*)
- libgloss_dir=arm
- ;;
- cris-*-* | crisv32-*-*)
- libgloss_dir=cris
- ;;
- kvx-*-elf)
- libgloss_dir=kvx-elf
- ;;
- kvx-*-mbr)
- libgloss_dir=kvx-mbr
- ;;
- kvx-*-cos)
- libgloss_dir=kvx-cos
- ;;
- hppa*-*-*)
- libgloss_dir=pa
- ;;
- i[[3456789]]86-*-*)
- libgloss_dir=i386
- ;;
- loongarch*-*-*)
- libgloss_dir=loongarch
- ;;
- m68hc11-*-*|m6811-*-*|m68hc12-*-*|m6812-*-*)
- libgloss_dir=m68hc11
- ;;
- m68*-*-* | fido-*-*)
- libgloss_dir=m68k
- ;;
- mips*-*-*)
- libgloss_dir=mips
- ;;
- powerpc*-*-*)
- libgloss_dir=rs6000
- ;;
- pru-*-*)
- libgloss_dir=pru
- ;;
- sparc*-*-*)
- libgloss_dir=sparc
- ;;
-esac
-
-# Disable newlib and libgloss for various target OSes.
-case "${target}" in
- alpha*-dec-osf*)
- noconfigdirs="$noconfigdirs target-newlib target-libgloss"
- ;;
- i[[3456789]]86-*-linux*)
- # This section makes it possible to build newlib natively on linux.
- # If we are using a cross compiler then don't configure newlib.
- if test x${is_cross_compiler} != xno ; then
- noconfigdirs="$noconfigdirs target-newlib"
- fi
- noconfigdirs="$noconfigdirs target-libgloss"
- # If we are not using a cross compiler, do configure newlib.
- # Note however, that newlib will only be configured in this situation
- # if the --with-newlib option has been given, because otherwise
- # 'target-newlib' will appear in skipdirs.
- ;;
- i[[3456789]]86-*-rdos*)
- noconfigdirs="$noconfigdirs target-newlib target-libgloss"
- ;;
- sh*-*-pe|mips*-*-pe|arm-wince-pe)
- noconfigdirs="$noconfigdirs target-newlib target-libgloss"
- ;;
- sparc-*-sunos4*)
- noconfigdirs="$noconfigdirs target-newlib target-libgloss"
- ;;
- bpf-*-*)
- noconfigdirs="$noconfigdirs target-newlib target-libgloss"
- ;;
- *-*-aix*)
- noconfigdirs="$noconfigdirs target-newlib target-libgloss"
- ;;
- *-*-beos*)
- noconfigdirs="$noconfigdirs target-newlib target-libgloss"
- ;;
- *-*-chorusos)
- noconfigdirs="$noconfigdirs target-newlib target-libgloss"
- ;;
- *-*-dragonfly*)
- noconfigdirs="$noconfigdirs target-newlib target-libgloss"
- ;;
- *-*-freebsd*)
- noconfigdirs="$noconfigdirs target-newlib target-libgloss"
- ;;
- *-*-linux* | *-*-gnu* | *-*-k*bsd*-gnu | *-*-kopensolaris*-gnu)
- noconfigdirs="$noconfigdirs target-newlib target-libgloss"
- ;;
- *-*-lynxos*)
- noconfigdirs="$noconfigdirs target-newlib target-libgloss"
- ;;
- *-*-mingw*)
- noconfigdirs="$noconfigdirs target-newlib target-libgloss"
- ;;
- *-*-netbsd*)
- noconfigdirs="$noconfigdirs target-newlib target-libgloss"
- ;;
- *-*-netware*)
- noconfigdirs="$noconfigdirs target-newlib target-libgloss"
- ;;
- *-*-tpf*)
- noconfigdirs="$noconfigdirs target-newlib target-libgloss"
- ;;
- *-*-uclinux*)
- noconfigdirs="$noconfigdirs target-newlib target-libgloss"
- ;;
- *-*-vxworks*)
- noconfigdirs="$noconfigdirs target-newlib target-libgloss"
- ;;
-esac
-
-case "${target}" in
- *-*-chorusos)
- ;;
- aarch64-*-darwin*)
- noconfigdirs="$noconfigdirs ld gas gdb gprof"
- noconfigdirs="$noconfigdirs sim target-rda"
- ;;
- amdgcn*-*-*)
- ;;
- arm-*-darwin*)
- noconfigdirs="$noconfigdirs ld gas gdb gprof"
- noconfigdirs="$noconfigdirs sim target-rda"
- ;;
- powerpc-*-darwin*)
- noconfigdirs="$noconfigdirs ld gas gdb gprof"
- noconfigdirs="$noconfigdirs sim target-rda"
- ;;
- i[[3456789]]86-*-darwin*)
- noconfigdirs="$noconfigdirs ld gprof"
- noconfigdirs="$noconfigdirs sim target-rda"
- ;;
- x86_64-*-darwin[[912]]*)
- noconfigdirs="$noconfigdirs ld gas gprof"
- noconfigdirs="$noconfigdirs sim target-rda"
- ;;
- *-*-darwin*)
- noconfigdirs="$noconfigdirs ld gas gdb gprof"
- noconfigdirs="$noconfigdirs sim target-rda"
- ;;
- *-*-dragonfly*)
- ;;
- *-*-freebsd*)
- if test "x$with_gmp" = x \
- && ! test -d ${srcdir}/gmp \
- && test -f /usr/local/include/gmp.h; then
- with_gmp=/usr/local
- fi
- ;;
- *-*-kaos*)
- # Remove unsupported stuff on all kaOS configurations.
- noconfigdirs="$noconfigdirs target-libgloss"
- ;;
- *-*-netbsd*)
- ;;
- *-*-netware*)
- ;;
- *-*-phoenix*)
- noconfigdirs="$noconfigdirs target-libgloss"
- ;;
- *-*-rtems*)
- noconfigdirs="$noconfigdirs target-libgloss"
- ;;
- # The tpf target doesn't support gdb yet.
- *-*-tpf*)
- noconfigdirs="$noconfigdirs gdb tcl tk libgui itcl"
- ;;
- *-*-uclinux*)
- noconfigdirs="$noconfigdirs target-rda"
- ;;
- *-*-vxworks*)
- ;;
- alpha*-dec-osf*)
- # ld works, but does not support shared libraries.
- # gas doesn't generate exception information.
- noconfigdirs="$noconfigdirs gas ld"
- ;;
- alpha*-*-*vms*)
- noconfigdirs="$noconfigdirs gdb target-newlib target-libgloss"
- ;;
- alpha*-*-*)
- # newlib is not 64 bit ready
- noconfigdirs="$noconfigdirs target-newlib target-libgloss"
- ;;
- bpf-*-*)
- noconfigdirs="$noconfigdirs target-libobjc target-libbacktrace"
- ;;
- sh*-*-pe|mips*-*-pe|*arm-wince-pe)
- noconfigdirs="$noconfigdirs tcl tk itcl libgui sim"
- ;;
- arc*-*-*)
- noconfigdirs="$noconfigdirs sim"
- ;;
- arm-*-pe*)
- noconfigdirs="$noconfigdirs target-libgloss"
- ;;
- arm-*-riscix*)
- noconfigdirs="$noconfigdirs ld target-libgloss"
- ;;
- avr-*-*)
- if test x${with_avrlibc} != xno; then
- noconfigdirs="$noconfigdirs target-newlib target-libgloss"
- fi
- ;;
- c4x-*-* | tic4x-*-*)
- noconfigdirs="$noconfigdirs target-libgloss"
- ;;
- tic54x-*-*)
- noconfigdirs="$noconfigdirs target-libgloss gdb"
- ;;
- d10v-*-*)
- noconfigdirs="$noconfigdirs target-libgloss"
- ;;
- d30v-*-*)
- noconfigdirs="$noconfigdirs gdb"
- ;;
- fr30-*-elf*)
- noconfigdirs="$noconfigdirs gdb"
- ;;
- ft32-*-*)
- noconfigdirs="$noconfigdirs target-rda gprof"
- ;;
- moxie-*-*)
- noconfigdirs="$noconfigdirs"
- ;;
- h8300*-*-*)
- noconfigdirs="$noconfigdirs target-libgloss"
- ;;
- h8500-*-*)
- noconfigdirs="$noconfigdirs target-libgloss"
- ;;
- hppa1.1-*-osf* | hppa1.1-*-bsd* )
- ;;
- hppa*64*-*-hpux*)
- noconfigdirs="$noconfigdirs gdb"
- ;;
- hppa*-*-hpux11*)
- noconfigdirs="$noconfigdirs gdb ld"
- ;;
- hppa*64*-*-linux*)
- ;;
- hppa*-*-linux*)
- ;;
- hppa*-*-*elf* | \
- hppa*-*-lites* | \
- hppa*-*-openbsd* | \
- hppa*64*-*-*)
- ;;
- hppa*-*-pro*)
- ;;
- hppa*-*-*)
- noconfigdirs="$noconfigdirs ld"
- ;;
- i960-*-*)
- noconfigdirs="$noconfigdirs gdb"
- ;;
- ia64*-*-elf*)
- # No gdb support yet.
- noconfigdirs="$noconfigdirs readline libgui itcl gdb"
- ;;
- ia64*-**-hpux*)
- # No ld support yet.
- noconfigdirs="$noconfigdirs gdb libgui itcl ld"
- ;;
- ia64*-*-*vms*)
- # No ld support yet.
- noconfigdirs="$noconfigdirs libgui itcl ld"
- ;;
- i[[3456789]]86-w64-mingw*)
- ;;
- i[[3456789]]86-*-mingw*)
- target_configdirs="$target_configdirs target-winsup"
- ;;
- *-*-cygwin*)
- target_configdirs="$target_configdirs target-libtermcap target-winsup"
- noconfigdirs="$noconfigdirs target-libgloss"
- # always build newlib if winsup directory is present.
- if test -d "$srcdir/winsup/cygwin"; then
- skipdirs=`echo " ${skipdirs} " | sed -e 's/ target-newlib / /'`
- elif test -d "$srcdir/newlib"; then
- echo "Warning: winsup/cygwin is missing so newlib can't be built."
- fi
- ;;
- i[[3456789]]86-*-pe)
- noconfigdirs="$noconfigdirs target-libgloss"
- ;;
- i[[3456789]]86-*-sco3.2v5*)
- # The linker does not yet know about weak symbols in COFF,
- # and is not configured to handle mixed ELF and COFF.
- noconfigdirs="$noconfigdirs ld target-libgloss"
- ;;
- i[[3456789]]86-*-sco*)
- noconfigdirs="$noconfigdirs gprof target-libgloss"
- ;;
- i[[3456789]]86-*-solaris2* | x86_64-*-solaris2.1[[0-9]]*)
- noconfigdirs="$noconfigdirs target-libgloss"
- ;;
- i[[3456789]]86-*-sysv4*)
- noconfigdirs="$noconfigdirs target-libgloss"
- ;;
- i[[3456789]]86-*-beos*)
- noconfigdirs="$noconfigdirs gdb"
- ;;
- i[[3456789]]86-*-rdos*)
- noconfigdirs="$noconfigdirs gdb"
- ;;
- kvx-*-*)
- noconfigdirs="$noconfigdirs gdb gdbserver sim"
- ;;
- mmix-*-*)
- noconfigdirs="$noconfigdirs gdb"
- ;;
- mt-*-*)
- noconfigdirs="$noconfigdirs sim"
- ;;
- nfp-*-*)
- noconfigdirs="$noconfigdirs ld gas gdb gprof sim"
- noconfigdirs="$noconfigdirs $target_libraries"
- ;;
- pdp11-*-*)
- noconfigdirs="$noconfigdirs gdb gprof"
- ;;
- powerpc-*-aix*)
- # copied from rs6000-*-* entry
- noconfigdirs="$noconfigdirs gprof"
- ;;
- powerpc*-*-winnt* | powerpc*-*-pe*)
- target_configdirs="$target_configdirs target-winsup"
- noconfigdirs="$noconfigdirs gdb tcl tk target-libgloss itcl"
- # always build newlib.
- skipdirs=`echo " ${skipdirs} " | sed -e 's/ target-newlib / /'`
- ;;
- # This is temporary until we can link against shared libraries
- powerpcle-*-solaris*)
- noconfigdirs="$noconfigdirs gdb sim tcl tk itcl"
- ;;
- powerpc-*-beos*)
- noconfigdirs="$noconfigdirs gdb"
- ;;
- rs6000-*-lynxos*)
- noconfigdirs="$noconfigdirs gprof"
- ;;
- rs6000-*-aix*)
- noconfigdirs="$noconfigdirs gprof"
- ;;
- rs6000-*-*)
- noconfigdirs="$noconfigdirs gprof"
- ;;
- m68k-apollo-*)
- noconfigdirs="$noconfigdirs ld binutils gprof target-libgloss"
- ;;
- microblaze*)
- noconfigdirs="$noconfigdirs gprof"
- ;;
- mips*-sde-elf* | mips*-mti-elf* | mips*-img-elf*)
- if test x$with_newlib = xyes; then
- noconfigdirs="$noconfigdirs gprof"
- fi
- ;;
- mips*-*-irix5*)
- noconfigdirs="$noconfigdirs gprof target-libgloss"
- ;;
- mips*-*-irix6*)
- noconfigdirs="$noconfigdirs gprof target-libgloss"
- ;;
- mips*-*-bsd*)
- noconfigdirs="$noconfigdirs ld gas gprof target-libgloss"
- ;;
- mips*-*-linux*)
- ;;
- mips*-*-ultrix* | mips*-*-osf* | mips*-*-ecoff* | mips*-*-pe* \
- | mips*-*-irix* | mips*-*-lnews* | mips*-*-riscos*)
- noconfigdirs="$noconfigdirs ld gas gprof"
- ;;
- mips*-*-*)
- noconfigdirs="$noconfigdirs gprof"
- ;;
- nvptx*-*-*)
- noconfigdirs="$noconfigdirs target-libssp target-libstdc++-v3 target-libobjc"
- ;;
- sh-*-*)
- case "${target}" in
- sh*-*-elf)
- ;;
- *)
- noconfigdirs="$noconfigdirs target-libgloss" ;;
- esac
- ;;
- sparc-*-sunos4*)
- if test x${is_cross_compiler} = xno ; then
- use_gnu_ld=no
- fi
- ;;
- tic6x-*-*)
- noconfigdirs="$noconfigdirs sim"
- ;;
- tilepro*-*-* | tilegx*-*-*)
- noconfigdirs="$noconfigdirs sim"
- ;;
- v810-*-*)
- noconfigdirs="$noconfigdirs bfd binutils gas gdb ld opcodes target-libgloss"
- ;;
- vax-*-*)
- noconfigdirs="$noconfigdirs target-newlib target-libgloss"
- ;;
- wasm32-*-*)
- noconfigdirs="$noconfigdirs ld"
- ;;
- loongarch*-*-linux*)
- ;;
- loongarch*-*-*)
- noconfigdirs="$noconfigdirs gprof"
- ;;
-esac
-
-# If we aren't building newlib, then don't build libgloss, since libgloss
-# depends upon some newlib header files.
-case "${noconfigdirs}" in
- *target-libgloss*) ;;
- *target-newlib*) noconfigdirs="$noconfigdirs target-libgloss" ;;
-esac
-
-# Work in distributions that contain no compiler tools, like Autoconf.
-host_makefile_frag=/dev/null
-if test -d ${srcdir}/config ; then
-case "${host}" in
- i[[3456789]]86-*-msdosdjgpp*)
- host_makefile_frag="config/mh-djgpp"
- ;;
- *-cygwin*)
- ACX_CHECK_CYGWIN_CAT_WORKS
- host_makefile_frag="config/mh-cygwin"
- ;;
- *-mingw*)
- host_makefile_frag="config/mh-mingw"
- ;;
- alpha*-linux*)
- host_makefile_frag="config/mh-alpha-linux"
- ;;
- hppa*-hp-hpux*)
- host_makefile_frag="config/mh-pa"
- ;;
- hppa*-*)
- host_makefile_frag="config/mh-pa"
- ;;
- i?86-*-darwin[[89]]* | i?86-*-darwin1[[0-7]]* | powerpc*-*-darwin*)
- host_makefile_frag="config/mh-darwin"
- ;;
- powerpc-*-aix*)
- host_makefile_frag="config/mh-ppc-aix"
- ;;
- rs6000-*-aix*)
- host_makefile_frag="config/mh-ppc-aix"
- ;;
-esac
-fi
-
-if test "${build}" != "${host}" ; then
- AR_FOR_BUILD=${AR_FOR_BUILD-ar}
- AS_FOR_BUILD=${AS_FOR_BUILD-as}
- CC_FOR_BUILD=${CC_FOR_BUILD-gcc}
- CPP_FOR_BUILD="${CPP_FOR_BUILD-\$(CC_FOR_BUILD) -E}"
- CXX_FOR_BUILD=${CXX_FOR_BUILD-g++}
- DSYMUTIL_FOR_BUILD=${DSYMUTIL_FOR_BUILD-dsymutil}
- GFORTRAN_FOR_BUILD=${GFORTRAN_FOR_BUILD-gfortran}
- GOC_FOR_BUILD=${GOC_FOR_BUILD-gccgo}
- GDC_FOR_BUILD=${GDC_FOR_BUILD-gdc}
- DLLTOOL_FOR_BUILD=${DLLTOOL_FOR_BUILD-dlltool}
- LD_FOR_BUILD=${LD_FOR_BUILD-ld}
- NM_FOR_BUILD=${NM_FOR_BUILD-nm}
- RANLIB_FOR_BUILD=${RANLIB_FOR_BUILD-ranlib}
- WINDRES_FOR_BUILD=${WINDRES_FOR_BUILD-windres}
- WINDMC_FOR_BUILD=${WINDMC_FOR_BUILD-windmc}
-else
- AR_FOR_BUILD="\$(AR)"
- AS_FOR_BUILD="\$(AS)"
- CC_FOR_BUILD="\$(CC)"
- CXX_FOR_BUILD="\$(CXX)"
- DSYMUTIL_FOR_BUILD="\$(DSYMUTIL)"
- GFORTRAN_FOR_BUILD="\$(GFORTRAN)"
- GOC_FOR_BUILD="\$(GOC)"
- GDC_FOR_BUILD="\$(GDC)"
- DLLTOOL_FOR_BUILD="\$(DLLTOOL)"
- LD_FOR_BUILD="\$(LD)"
- NM_FOR_BUILD="\$(NM)"
- RANLIB_FOR_BUILD="\$(RANLIB)"
- WINDRES_FOR_BUILD="\$(WINDRES)"
- WINDMC_FOR_BUILD="\$(WINDMC)"
-fi
-
-AC_PROG_CC_C99
-AC_PROG_CXX
-
-# We must set the default linker to the linker used by gcc for the correct
-# operation of libtool. If LD is not defined and we are using gcc, try to
-# set the LD default to the ld used by gcc.
-if test -z "$LD"; then
- if test "$GCC" = yes; then
- case $build in
- *-*-mingw*)
- gcc_prog_ld=`$CC -print-prog-name=ld 2>&1 | tr -d '\015'` ;;
- *)
- gcc_prog_ld=`$CC -print-prog-name=ld 2>&1` ;;
- esac
- case $gcc_prog_ld in
- # Accept absolute paths.
- [[\\/]* | [A-Za-z]:[\\/]*)]
- LD="$gcc_prog_ld" ;;
- esac
- fi
-fi
-
-ACX_PROG_GNAT
-ACX_PROG_GDC
-ACX_PROG_CMP_IGNORE_INITIAL
-
-AC_ARG_ENABLE([bootstrap],
-[AS_HELP_STRING([--enable-bootstrap],
- [enable bootstrapping @<:@yes if native build@:>@])],,
-enable_bootstrap=default)
-
-# Issue errors and warnings for invalid/strange bootstrap combinations.
-if test -r $srcdir/gcc/configure; then
- have_compiler=yes
-else
- have_compiler=no
-fi
-
-case "$have_compiler:$host:$target:$enable_bootstrap" in
- *:*:*:no) ;;
-
- # Default behavior. Enable bootstrap if we have a compiler
- # and we are in a native configuration.
- yes:$build:$build:default)
- enable_bootstrap=yes ;;
-
- *:*:*:default)
- enable_bootstrap=no ;;
-
- # We have a compiler and we are in a native configuration, bootstrap is ok
- yes:$build:$build:yes)
- ;;
-
- # Other configurations, but we have a compiler. Assume the user knows
- # what he's doing.
- yes:*:*:yes)
- AC_MSG_WARN([trying to bootstrap a cross compiler])
- ;;
-
- # No compiler: if they passed --enable-bootstrap explicitly, fail
- no:*:*:yes)
- AC_MSG_ERROR([cannot bootstrap without a compiler]) ;;
-
- # Fail if wrong command line
- *)
- AC_MSG_ERROR([invalid option for --enable-bootstrap])
- ;;
-esac
-
-# When bootstrapping with GCC, build stage 1 in C++11 mode to ensure that a
-# C++11 compiler can still start the bootstrap. Otherwise, if building GCC,
-# require C++11 (or higher).
-if test "$enable_bootstrap:$GXX" = "yes:yes"; then
- CXX="$CXX -std=c++11"
-elif test "$have_compiler" = yes; then
- AX_CXX_COMPILE_STDCXX(11)
-
- if test "${build}" != "${host}"; then
- AX_CXX_COMPILE_STDCXX(11, [], [], [_FOR_BUILD])
- fi
-fi
-
-AC_ARG_ENABLE([pgo-build],
-[AS_HELP_STRING([--enable-pgo-build[[=lto]]],
- [enable the PGO build])],
-[enable_pgo_build=$enableval],
-[enable_pgo_build=no])
-
-# Issue errors and warnings for invalid/strange PGO build combinations.
-case "$have_compiler:$host:$target:$enable_pgo_build" in
- *:*:*:no) ;;
-
- # Allow the PGO build only if we aren't building a compiler and
- # we are in a native configuration.
- no:$build:$build:yes | no:$build:$build:lto) ;;
-
- # Disallow the PGO bootstrap if we are building a compiler.
- yes:*:*:yes | yes:*:*:lto)
- AC_MSG_ERROR([cannot perform the PGO bootstrap when building a compiler]) ;;
-
- *)
- AC_MSG_ERROR([invalid option for --enable-pgo-build])
- ;;
-esac
-
-if test "$enable_pgo_build" != "no"; then
- AC_MSG_CHECKING([whether the compiler supports -fprofile-generate])
- old_CFLAGS="$CFLAGS"
- PGO_BUILD_GEN_CFLAGS="-fprofile-generate"
- CFLAGS="$CFLAGS $PGO_BUILD_CFLAGS"
- AC_COMPILE_IFELSE([AC_LANG_SOURCE([int foo;])],,
- [PGO_BUILD_GEN_CFLAGS=])
- CFLAGS="$old_CFLAGS"
- if test -n "$PGO_BUILD_GEN_CFLAGS"; then
- AC_MSG_RESULT([yes])
- PGO_BUILD_USE_CFLAGS="-fprofile-use"
- else
- AC_MSG_RESULT([no])
- AC_MSG_ERROR([cannot perform the PGO build without -fprofile-generate])
- fi
-
- if test "$enable_pgo_build" = "lto"; then
- AC_MSG_CHECKING([whether the compiler supports -flto=jobserver -ffat-lto-objects])
- old_CFLAGS="$CFLAGS"
- PGO_BUILD_LTO_CFLAGS="-flto=jobserver -ffat-lto-objects"
- CFLAGS="$CFLAGS $PGO_BUILD_LTO_CFLAGS"
- AC_COMPILE_IFELSE([AC_LANG_SOURCE([int foo;])],,
- [PGO_BUILD_LTO_CFLAGS=])
- CFLAGS="$old_CFLAGS"
- if test -n "$PGO_BUILD_LTO_CFLAGS"; then
- AC_MSG_RESULT([yes])
- else
- AC_MSG_RESULT([no])
- AC_MSG_WARN([LTO is disabled for the PGO build])
- fi
- fi
-fi
-AC_SUBST(PGO_BUILD_GEN_CFLAGS)
-AC_SUBST(PGO_BUILD_USE_CFLAGS)
-AC_SUBST(PGO_BUILD_LTO_CFLAGS)
-
-# Used for setting $lt_cv_objdir
-_LT_CHECK_OBJDIR
-
-# Check for GMP, MPFR and MPC
-require_gmp=no
-require_mpc=no
-if test -d ${srcdir}/gcc ; then
- require_gmp=yes
- require_mpc=yes
-fi
-if test -d ${srcdir}/gdb ; then
- if test "x$enable_gdb" != xno; then
- require_gmp=yes
- fi
-fi
-
-gmplibs="-lmpfr -lgmp"
-if test x"$require_mpc" = "xyes" ; then
- gmplibs="-lmpc $gmplibs"
-fi
-gmpinc=
-have_gmp=no
-
-# Specify a location for mpc
-# check for this first so it ends up on the link line before mpfr.
-AC_ARG_WITH(mpc,
-[AS_HELP_STRING([--with-mpc=PATH],
- [specify prefix directory for installed MPC package.
- Equivalent to --with-mpc-include=PATH/include
- plus --with-mpc-lib=PATH/lib])])
-AC_ARG_WITH(mpc-include,
-[AS_HELP_STRING([--with-mpc-include=PATH],
- [specify directory for installed MPC include files])])
-AC_ARG_WITH(mpc-lib,
-[AS_HELP_STRING([--with-mpc-lib=PATH],
- [specify directory for the installed MPC library])])
-
-if test "x$with_mpc" != x; then
- gmplibs="-L$with_mpc/lib $gmplibs"
- gmpinc="-I$with_mpc/include $gmpinc"
-fi
-if test "x$with_mpc_include" != x; then
- gmpinc="-I$with_mpc_include $gmpinc"
-fi
-if test "x$with_mpc_lib" != x; then
- gmplibs="-L$with_mpc_lib $gmplibs"
-fi
-if test "x$with_mpc$with_mpc_include$with_mpc_lib" = x && test -d ${srcdir}/mpc; then
- gmplibs='-L$$r/$(HOST_SUBDIR)/mpc/src/'"$lt_cv_objdir $gmplibs"
- gmpinc='-I$$s/mpc/src '"$gmpinc"
- # Do not test the mpc version. Assume that it is sufficient, since
- # it is in the source tree, and the library has not been built yet
- # but it would be included on the link line in the version check below
- # hence making the test fail.
- have_gmp=yes
-fi
-
-# Specify a location for mpfr
-# check for this first so it ends up on the link line before gmp.
-AC_ARG_WITH(mpfr,
-[AS_HELP_STRING([--with-mpfr=PATH],
- [specify prefix directory for installed MPFR package.
- Equivalent to --with-mpfr-include=PATH/include
- plus --with-mpfr-lib=PATH/lib])])
-AC_ARG_WITH(mpfr-include,
-[AS_HELP_STRING([--with-mpfr-include=PATH],
- [specify directory for installed MPFR include files])])
-AC_ARG_WITH(mpfr-lib,
-[AS_HELP_STRING([--with-mpfr-lib=PATH],
- [specify directory for the installed MPFR library])])
-
-if test "x$with_mpfr" != x; then
- gmplibs="-L$with_mpfr/lib $gmplibs"
- gmpinc="-I$with_mpfr/include $gmpinc"
-fi
-if test "x$with_mpfr_include" != x; then
- gmpinc="-I$with_mpfr_include $gmpinc"
-fi
-if test "x$with_mpfr_lib" != x; then
- gmplibs="-L$with_mpfr_lib $gmplibs"
-fi
-if test "x$with_mpfr$with_mpfr_include$with_mpfr_lib" = x && test -d ${srcdir}/mpfr; then
- # MPFR v3.1.0 moved the sources into a src sub-directory.
- if ! test -d ${srcdir}/mpfr/src; then
- AC_MSG_ERROR([dnl
-Building GCC with MPFR in the source tree is only handled for MPFR 3.1.0+.])
- fi
- gmplibs='-L$$r/$(HOST_SUBDIR)/mpfr/src/'"$lt_cv_objdir $gmplibs"
- gmpinc='-I$$r/$(HOST_SUBDIR)/mpfr/src -I$$s/mpfr/src '"$gmpinc"
- extra_mpc_mpfr_configure_flags='--with-mpfr-include=$$s/mpfr/src --with-mpfr-lib=$$r/$(HOST_SUBDIR)/mpfr/src/'"$lt_cv_objdir"
- # Do not test the mpfr version. Assume that it is sufficient, since
- # it is in the source tree, and the library has not been built yet
- # but it would be included on the link line in the version check below
- # hence making the test fail.
- have_gmp=yes
-fi
-
-# Specify a location for gmp
-AC_ARG_WITH(gmp,
-[AS_HELP_STRING([--with-gmp=PATH],
- [specify prefix directory for the installed GMP package.
- Equivalent to --with-gmp-include=PATH/include
- plus --with-gmp-lib=PATH/lib])])
-AC_ARG_WITH(gmp-include,
-[AS_HELP_STRING([--with-gmp-include=PATH],
- [specify directory for installed GMP include files])])
-AC_ARG_WITH(gmp-lib,
-[AS_HELP_STRING([--with-gmp-lib=PATH],
- [specify directory for the installed GMP library])])
-
-
-if test "x$with_gmp" != x; then
- gmplibs="-L$with_gmp/lib $gmplibs"
- gmpinc="-I$with_gmp/include $gmpinc"
-fi
-if test "x$with_gmp_include" != x; then
- gmpinc="-I$with_gmp_include $gmpinc"
-fi
-if test "x$with_gmp_lib" != x; then
- gmplibs="-L$with_gmp_lib $gmplibs"
-fi
-if test "x$with_gmp$with_gmp_include$with_gmp_lib" = x && test -d ${srcdir}/gmp; then
- gmplibs='-L$$r/$(HOST_SUBDIR)/gmp/'"$lt_cv_objdir $gmplibs"
- gmpinc='-I$$r/$(HOST_SUBDIR)/gmp -I$$s/gmp '"$gmpinc"
- extra_mpfr_configure_flags='--with-gmp-include=$$r/$(HOST_SUBDIR)/gmp --with-gmp-lib=$$r/$(HOST_SUBDIR)/gmp/'"$lt_cv_objdir"
- extra_mpc_gmp_configure_flags='--with-gmp-include=$$r/$(HOST_SUBDIR)/gmp --with-gmp-lib=$$r/$(HOST_SUBDIR)/gmp/'"$lt_cv_objdir"
- extra_isl_gmp_configure_flags='--with-gmp-builddir=$$r/$(HOST_SUBDIR)/gmp'
- # Do not test the gmp version. Assume that it is sufficient, since
- # it is in the source tree, and the library has not been built yet
- # but it would be included on the link line in the version check below
- # hence making the test fail.
- have_gmp=yes
-fi
-
-if test "x$require_gmp" = xyes && test "x$have_gmp" = xno; then
- have_gmp=yes
- saved_CFLAGS="$CFLAGS"
- CFLAGS="$CFLAGS $gmpinc"
- # Check for the recommended and required versions of GMP.
- AC_MSG_CHECKING([for the correct version of gmp.h])
- AC_TRY_COMPILE([#include "gmp.h"],[
- #define GCC_GMP_VERSION_NUM(a,b,c) (((a) << 16L) | ((b) << 8) | (c))
- #define GCC_GMP_VERSION GCC_GMP_VERSION_NUM(__GNU_MP_VERSION,__GNU_MP_VERSION_MINOR,__GNU_MP_VERSION_PATCHLEVEL)
- #if GCC_GMP_VERSION < GCC_GMP_VERSION_NUM(4,2,3)
- choke me
- #endif
- ], [AC_TRY_COMPILE([#include <gmp.h>],[
- #define GCC_GMP_VERSION_NUM(a,b,c) (((a) << 16L) | ((b) << 8) | (c))
- #define GCC_GMP_VERSION GCC_GMP_VERSION_NUM(__GNU_MP_VERSION,__GNU_MP_VERSION_MINOR,__GNU_MP_VERSION_PATCHLEVEL)
- #if GCC_GMP_VERSION < GCC_GMP_VERSION_NUM(4,3,2)
- choke me
- #endif
- ], [AC_MSG_RESULT([yes])], [AC_MSG_RESULT([buggy but acceptable])])],
- [AC_MSG_RESULT([no]); have_gmp=no])
-
- # If we have GMP, check the MPFR version.
- if test x"$have_gmp" = xyes; then
- # Check for the recommended and required versions of MPFR.
- AC_MSG_CHECKING([for the correct version of mpfr.h])
- AC_TRY_COMPILE([#include <gmp.h>
- #include <mpfr.h>],[
- #if MPFR_VERSION < MPFR_VERSION_NUM(3,1,0)
- choke me
- #endif
- ], [AC_TRY_COMPILE([#include <gmp.h>
- #include <mpfr.h>],[
- #if MPFR_VERSION < MPFR_VERSION_NUM(3,1,6)
- choke me
- #endif
- ], [AC_MSG_RESULT([yes])], [AC_MSG_RESULT([buggy but acceptable])])],
- [AC_MSG_RESULT([no]); have_gmp=no])
- fi
-
- # Check for the MPC header version.
- if test "x$require_mpc" = xyes && test x"$have_gmp" = xyes ; then
- # Check for the recommended and required versions of MPC.
- AC_MSG_CHECKING([for the correct version of mpc.h])
- AC_TRY_COMPILE([#include <mpc.h>],[
- #if MPC_VERSION < MPC_VERSION_NUM(0,8,0)
- choke me
- #endif
- ], [AC_TRY_COMPILE([#include <mpc.h>],[
- #if MPC_VERSION < MPC_VERSION_NUM(0,8,1)
- choke me
- #endif
- ], [AC_MSG_RESULT([yes])], [AC_MSG_RESULT([buggy but acceptable])])],
- [AC_MSG_RESULT([no]); have_gmp=no])
- fi
-
- # Now check the MPFR library.
- if test x"$have_gmp" = xyes; then
- saved_LIBS="$LIBS"
- LIBS="$LIBS $gmplibs"
- AC_MSG_CHECKING([for the correct version of the gmp/mpfr libraries])
- AC_TRY_LINK([#include <mpfr.h>],[
- mpfr_t n;
- mpfr_t x;
- int t;
- mpfr_init (n);
- mpfr_init (x);
- mpfr_atan2 (n, n, x, MPFR_RNDN);
- mpfr_erfc (n, x, MPFR_RNDN);
- mpfr_subnormalize (x, t, MPFR_RNDN);
- mpfr_clear(n);
- mpfr_clear(x);
- ], [AC_MSG_RESULT([yes])], [AC_MSG_RESULT([no]); have_gmp=no])
- LIBS="$saved_LIBS"
- fi
-
- # Now check the MPC library
- if test "x$require_mpc" = xyes && test x"$have_gmp" = xyes; then
- saved_LIBS="$LIBS"
- LIBS="$LIBS $gmplibs"
- AC_MSG_CHECKING([for the correct version of the mpc libraries])
- AC_TRY_LINK([#include <mpc.h>],[
- mpc_t c;
- mpc_init2 (c, 53);
- mpc_set_ui_ui (c, 1, 1, MPC_RNDNN);
- mpc_cosh (c, c, MPC_RNDNN);
- mpc_pow (c, c, c, MPC_RNDNN);
- mpc_acosh (c, c, MPC_RNDNN);
- mpc_clear (c);
- ], [AC_MSG_RESULT([yes])], [AC_MSG_RESULT([no]); have_gmp=no])
- LIBS="$saved_LIBS"
- fi
-
- CFLAGS="$saved_CFLAGS"
-
-# The library versions listed in the error message below should match
-# the HARD-minimums enforced above.
- if test x$have_gmp != xyes; then
- if test -d ${srcdir}/gcc ; then
- AC_MSG_ERROR([Building GCC requires GMP 4.2+, MPFR 3.1.0+ and MPC 0.8.0+.
-Try the --with-gmp, --with-mpfr and/or --with-mpc options to specify
-their locations. Source code for these libraries can be found at
-their respective hosting sites as well as at
-https://gcc.gnu.org/pub/gcc/infrastructure/. See also
-http://gcc.gnu.org/install/prerequisites.html for additional info. If
-you obtained GMP, MPFR and/or MPC from a vendor distribution package,
-make sure that you have installed both the libraries and the header
-files. They may be located in separate packages.])
- else
- AC_MSG_ERROR([Building GDB requires GMP 4.2+, and MPFR 3.1.0+.
-Try the --with-gmp and/or --with-mpfr options to specify
-their locations. If you obtained GMP and/or MPFR from a vendor
-distribution package, make sure that you have installed both the libraries
-and the header files. They may be located in separate packages.])
- fi
- fi
-fi
-
-# Flags needed for both GMP, MPFR and/or MPC.
-AC_SUBST(gmplibs)
-AC_SUBST(gmpinc)
-AC_SUBST(extra_mpfr_configure_flags)
-AC_SUBST(extra_mpc_gmp_configure_flags)
-AC_SUBST(extra_mpc_mpfr_configure_flags)
-AC_SUBST(extra_isl_gmp_configure_flags)
-
-# Libraries to use for stage1 or when not bootstrapping.
-AC_ARG_WITH(stage1-libs,
-[AS_HELP_STRING([--with-stage1-libs=LIBS], [libraries for stage1])],
-[if test "$withval" = "no" -o "$withval" = "yes"; then
- stage1_libs=
- else
- stage1_libs=$withval
- fi],
-[stage1_libs=])
-AC_SUBST(stage1_libs)
-
-# Whether or not to use -static-libstdc++ and -static-libgcc. The
-# default is yes if gcc is being built; no otherwise. The reason for
-# this default is that gdb is sometimes linked against GNU Source
-# Highlight, which is a shared library that uses C++ exceptions. In
-# this case, -static-libstdc++ will cause crashes.
-AC_ARG_WITH(static-standard-libraries,
-[AS_HELP_STRING([--with-static-standard-libraries],
- [use -static-libstdc++ and -static-libgcc (default=auto)])],
-[], [with_static_standard_libraries=auto])
-if test "$with_static_standard_libraries" = auto; then
- with_static_standard_libraries=$have_compiler
-fi
-
-# Linker flags to use for stage1 or when not bootstrapping.
-AC_ARG_WITH(stage1-ldflags,
-[AS_HELP_STRING([--with-stage1-ldflags=FLAGS], [linker flags for stage1])],
-[if test "$withval" = "no" -o "$withval" = "yes"; then
- stage1_ldflags=
- else
- stage1_ldflags=$withval
- fi],
-[stage1_ldflags=
- # In stage 1, default to linking libstdc++ and libgcc statically with GCC
- # if supported. But if the user explicitly specified the libraries to use,
- # trust that they are doing what they want.
- if test "$with_static_standard_libraries" = yes -a "$stage1_libs" = "" \
- -a "$have_static_libs" = yes; then
- stage1_ldflags="-static-libstdc++ -static-libgcc"
- fi])
-AC_SUBST(stage1_ldflags)
-
-# Libraries to use for stage2 and later builds.
-AC_ARG_WITH(boot-libs,
-[AS_HELP_STRING([--with-boot-libs=LIBS], [libraries for stage2 and later])],
-[if test "$withval" = "no" -o "$withval" = "yes"; then
- poststage1_libs=
- else
- poststage1_libs=$withval
- fi],
-[poststage1_libs=])
-AC_SUBST(poststage1_libs)
-
-# Linker flags to use for stage2 and later builds.
-AC_ARG_WITH(boot-ldflags,
-[AS_HELP_STRING([--with-boot-ldflags=FLAGS],
- [linker flags for stage2 and later])],
-[if test "$withval" = "no" -o "$withval" = "yes"; then
- poststage1_ldflags=
- else
- poststage1_ldflags=$withval
- fi],
-[poststage1_ldflags=
- # In stages 2 and 3, default to linking libstdc++ and libgcc
- # statically. But if the user explicitly specified the libraries to
- # use, trust that they are doing what they want.
- if test "$poststage1_libs" = ""; then
- poststage1_ldflags="-static-libstdc++ -static-libgcc"
- fi])
-case $target in
- *-darwin2* | *-darwin1[[56789]]*)
- # For these versions, we default to using embedded rpaths.
- if test "x$enable_darwin_at_rpath" != "xno"; then
- poststage1_ldflags="$poststage1_ldflags -nodefaultrpaths"
- fi
- ;;
- *-darwin*)
- # For these versions, we only use embedded rpaths on demand.
- if test "x$enable_darwin_at_rpath" = "xyes"; then
- poststage1_ldflags="$poststage1_ldflags -nodefaultrpaths"
- fi
- ;;
-esac
-AC_SUBST(poststage1_ldflags)
-
-# GCC GRAPHITE dependency isl.
-# Basic setup is inlined here, actual checks are in config/isl.m4
-
-AC_ARG_WITH(isl,
- [AS_HELP_STRING(
- [--with-isl=PATH],
- [Specify prefix directory for the installed isl package.
- Equivalent to --with-isl-include=PATH/include
- plus --with-isl-lib=PATH/lib])])
-
-# Treat --without-isl as a request to disable
-# GRAPHITE support and skip all following checks.
-if test "x$with_isl" != "xno"; then
- # Check for isl
- dnl Provide configure switches and initialize islinc & isllibs
- dnl with user input.
- ISL_INIT_FLAGS
- dnl The versions of isl that work for Graphite
- ISL_CHECK_VERSION()
- dnl Only execute fail-action, if isl has been requested.
- ISL_IF_FAILED([
- AC_MSG_ERROR([Unable to find a usable isl. See config.log for details.])])
-fi
-
-# If the isl check failed, disable builds of in-tree variant of isl
-if test "x$with_isl" = xno ||
- test "x$gcc_cv_isl" = xno; then
- noconfigdirs="$noconfigdirs isl"
- islinc=
-fi
-
-AC_SUBST(isllibs)
-AC_SUBST(islinc)
-
-# Check for LTO support.
-AC_ARG_ENABLE(lto,
-[AS_HELP_STRING([--enable-lto], [enable link time optimization support])],
-enable_lto=$enableval,
-enable_lto=yes; default_enable_lto=yes)
-
-ACX_ELF_TARGET_IFELSE([# ELF platforms build the lto-plugin always.
- build_lto_plugin=yes
-],[if test x"$default_enable_lto" = x"yes" ; then
- case $target in
- *-apple-darwin[[912]]* | *-cygwin* | *-mingw* | *djgpp*) ;;
- # On other non-ELF platforms, LTO has yet to be validated.
- *) enable_lto=no ;;
- esac
- else
- # Apart from ELF platforms, only Windows and Darwin support LTO so far.
- # It would also be nice to check the binutils support, but we don't
- # have gcc_GAS_CHECK_FEATURE available here. For now, we'll just
- # warn during gcc/ subconfigure; unless you're bootstrapping with
- # -flto it won't be needed until after installation anyway.
- case $target in
- *-cygwin* | *-mingw* | *-apple-darwin* | *djgpp*) ;;
- *) if test x"$enable_lto" = x"yes"; then
- AC_MSG_ERROR([LTO support is not enabled for this target.])
- fi
- ;;
- esac
- fi
- # Among non-ELF, only Windows platforms support the lto-plugin so far.
- # Build it unless LTO was explicitly disabled.
- case $target in
- *-cygwin* | *-mingw*) build_lto_plugin=$enable_lto ;;
- *) ;;
- esac
-])
-
-AC_ARG_ENABLE(linker-plugin-configure-flags,
- [AS_HELP_STRING([[--enable-linker-plugin-configure-flags=FLAGS]],
- [additional flags for configuring linker plugins @<:@none@:>@])],
- extra_linker_plugin_configure_flags=$enableval,
- extra_linker_plugin_configure_flags=)
-AC_SUBST(extra_linker_plugin_configure_flags)
-AC_ARG_ENABLE(linker-plugin-flags,
- [AS_HELP_STRING([[--enable-linker-plugin-flags=FLAGS]],
- [additional flags for configuring and building linker plugins @<:@none@:>@])],
- extra_linker_plugin_flags=$enableval,
- extra_linker_plugin_flags=)
-AC_SUBST(extra_linker_plugin_flags)
-
-# Handle --enable-host-pie
-# If host PIE executables are the default (or must be forced on) for some host,
-# we must pass that configuration to the gcc directory.
-gcc_host_pie=
-AC_ARG_ENABLE(host-pie,
-[AS_HELP_STRING([--enable-host-pie],
- [build position independent host executables])],
-[host_pie=$enableval
- case $host in
- *-*-darwin2*)
- if test x$host_pie != xyes ; then
- # for Darwin20+ this is required.
- AC_MSG_WARN([PIE executables are required for the configured host, host-pie setting ignored.])
- host_pie=yes
- gcc_host_pie=--enable-host-pie
- fi ;;
- *) ;;
- esac],
-[case $host in
- *-*-darwin2*)
- # Default to PIE (mandatory for aarch64).
- host_pie=yes
- gcc_host_pie=--enable-host-pie
- ;;
- *) host_pie=no ;;
- esac])
-
-AC_SUBST(host_pie)
-AC_SUBST(gcc_host_pie)
-
-# Enable --enable-host-shared.
-# Checked early to determine whether jit is an 'all' language
-AC_ARG_ENABLE(host-shared,
-[AS_HELP_STRING([--enable-host-shared],
- [build host code as shared libraries])],
-[host_shared=$enableval
- case $host in
- x86_64-*-darwin* | aarch64-*-darwin*)
- if test x$host_shared != xyes ; then
- # PIC is the default, and actually cannot be switched off.
- AC_MSG_WARN([PIC code is required for the configured host; host-shared setting ignored.])
- host_shared=yes
- fi ;;
- *-*-darwin*)
- if test x$host_pie = xyes -a x$host_shared != xyes ; then
- AC_MSG_WARN([PIC code is required for PIE host executables host-shared setting ignored.])
- host_shared=yes
- fi ;;
- *) ;;
- esac],
-[case $host in
- # 64B x86_64 and Aarch64 Darwin default to PIC.
- x86_64-*-darwin* | aarch64-*-darwin*) host_shared=yes ;;
- # 32B and powerpc64 Darwin must use PIC to link PIE exes.
- *-*-darwin*) host_shared=$host_pie ;;
- *) host_shared=no;;
- esac])
-
-AC_SUBST(host_shared)
-
-if test x$host_shared = xyes; then
- case $host in
- *-*-darwin*)
- # Since host shared is the default for 64b Darwin, and also enabled for
- # host_pie, ensure that we present the PIE flag when host_pie is active.
- if test x$host_pie = xyes; then
- PICFLAG=-fPIE
- fi
- ;;
- *)
- PICFLAG=-fPIC
- ;;
- esac
-elif test x$host_pie = xyes; then
- PICFLAG=-fPIE
-else
- PICFLAG=
-fi
-
-AC_SUBST(PICFLAG)
-
-# If we are building PIC/PIE host executables, and we are building dependent
-# libs (e.g. GMP) in-tree those libs need to be configured to generate PIC
-# code.
-host_libs_picflag=
-if test "$host_shared" = "yes" -o "$host_pie" = "yes"; then
-host_libs_picflag='--with-pic'
-fi
-AC_SUBST(host_libs_picflag)
-
-# By default, C and C++ are the only stage 1 languages.
-stage1_languages=,c,
-
-# Target libraries that we bootstrap.
-bootstrap_target_libs=,target-libgcc,
-
-# Figure out what language subdirectories are present.
-# Look if the user specified --enable-languages="..."; if not, use
-# the environment variable $LANGUAGES if defined. $LANGUAGES might
-# go away some day.
-# NB: embedded tabs in this IF block -- do not untabify
-if test -d ${srcdir}/gcc; then
- if test x"${enable_languages+set}" != xset; then
- if test x"${LANGUAGES+set}" = xset; then
- enable_languages="${LANGUAGES}"
- echo configure.ac: warning: setting LANGUAGES is deprecated, use --enable-languages instead 1>&2
- else
- enable_languages=default
- fi
- else
- if test x"${enable_languages}" = x ||
- test x"${enable_languages}" = xyes;
- then
- echo configure.ac: --enable-languages needs at least one language argument 1>&2
- exit 1
- fi
- fi
- enable_languages=`echo "${enable_languages}" | sed -e 's/[[ ,]][[ ,]]*/,/g' -e 's/,$//'`
-
- # 'f95' is the old name for the 'fortran' language. We issue a warning
- # and make the substitution.
- case ,${enable_languages}, in
- *,f95,*)
- echo configure.ac: warning: 'f95' as language name is deprecated, use 'fortran' instead 1>&2
- enable_languages=`echo "${enable_languages}" | sed -e 's/f95/fortran/g'`
- ;;
- esac
-
- # If bootstrapping, C++ must be enabled.
- case ",$enable_languages,:$enable_bootstrap" in
- *,c++,*:*) ;;
- *:yes)
- if test -f ${srcdir}/gcc/cp/config-lang.in; then
- enable_languages="${enable_languages},c++"
- else
- AC_MSG_ERROR([bootstrapping requires c++ sources])
- fi
- ;;
- esac
-
- # First scan to see if an enabled language requires some other language.
- # We assume that a given config-lang.in will list all the language
- # front ends it requires, even if some are required indirectly.
- for lang_frag in ${srcdir}/gcc/*/config-lang.in .. ; do
- case ${lang_frag} in
- ..) ;;
- # The odd quoting in the next line works around
- # an apparent bug in bash 1.12 on linux.
- ${srcdir}/gcc/[[*]]/config-lang.in) ;;
- *)
- # From the config-lang.in, get $language, $lang_requires, and
- # $lang_requires_boot_languages.
- language=
- lang_requires=
- lang_requires_boot_languages=
- # set srcdir during sourcing lang_frag to the gcc dir.
- # Sadly overriding srcdir on the . line doesn't work in plain sh as it
- # polutes this shell
- saved_srcdir=${srcdir}
- srcdir=${srcdir}/gcc . ${lang_frag}
- srcdir=${saved_srcdir}
- for other in ${lang_requires} ${lang_requires_boot_languages}; do
- case ,${enable_languages}, in
- *,$other,*) ;;
- *,default,*) ;;
- *,all,*) ;;
- *,$language,*)
- echo " \`$other' language required by \`$language'; enabling" 1>&2
- enable_languages="${enable_languages},${other}"
- ;;
- esac
- done
- for other in ${lang_requires_boot_languages} ; do
- if test "$other" != "c"; then
- case ,${enable_stage1_languages}, in
- *,$other,*) ;;
- *,default,*) ;;
- *,all,*) ;;
- *)
- case ,${enable_languages}, in
- *,$language,*)
- echo " '$other' language required by '$language' in stage 1; enabling" 1>&2
- enable_stage1_languages="$enable_stage1_languages,${other}"
- ;;
- esac
- ;;
- esac
- fi
- done
- ;;
- esac
- done
-
- new_enable_languages=,c,
-
- # If LTO is enabled, add the LTO front end.
- if test "$enable_lto" = "yes" ; then
- case ,${enable_languages}, in
- *,lto,*) ;;
- *) enable_languages="${enable_languages},lto" ;;
- esac
- if test "${build_lto_plugin}" = "yes" ; then
- configdirs="$configdirs lto-plugin"
- fi
- fi
-
- # If we're building an offloading compiler, add the LTO front end.
- if test x"$enable_as_accelerator_for" != x ; then
- case ,${enable_languages}, in
- *,lto,*) ;;
- *) enable_languages="${enable_languages},lto" ;;
- esac
- fi
-
- missing_languages=`echo ",$enable_languages," | sed -e s/,default,/,/ -e s/,all,/,/ -e s/,c,/,/ `
- potential_languages=,c,
-
- enabled_target_libs=
- disabled_target_libs=
-
- for lang_frag in ${srcdir}/gcc/*/config-lang.in .. ; do
- case ${lang_frag} in
- ..) ;;
- # The odd quoting in the next line works around
- # an apparent bug in bash 1.12 on linux.
- ${srcdir}/gcc/[[*]]/config-lang.in) ;;
- *)
- # From the config-lang.in, get $language, $target_libs,
- # $lang_dirs, $boot_language, and $build_by_default
- language=
- target_libs=
- lang_dirs=
- subdir_requires=
- boot_language=no
- build_by_default=yes
- # set srcdir during sourcing. See above about save & restore
- saved_srcdir=${srcdir}
- srcdir=${srcdir}/gcc . ${lang_frag}
- srcdir=${saved_srcdir}
- if test x${language} = x; then
- echo "${lang_frag} doesn't set \$language." 1>&2
- exit 1
- fi
-
- if test "$language" = "c++"; then
- boot_language=yes
- fi
-
- add_this_lang=no
- # C is always enabled, so no need to add it again
- if test "$language" != "c"; then
- case ,${enable_languages}, in
- *,${language},*)
- # Language was explicitly selected; include it
- add_this_lang=yes
- ;;
- *,all,*)
- # All languages are enabled
- add_this_lang=all
- ;;
- *,default,*)
- # 'default' was selected, select it if it is a default language
- add_this_lang=${build_by_default}
- ;;
- esac
- fi
-
- # Disable languages that need other directories if these aren't available.
- for i in $subdir_requires; do
- test -f "$srcdir/gcc/$i/config-lang.in" && continue
- case ${add_this_lang} in
- yes)
- # Specifically requested language; tell them.
- AC_MSG_ERROR([The gcc/$i directory contains parts of $language but is missing])
- ;;
- all)
- AC_MSG_WARN([The gcc/$i directory contains parts of $language but is missing])
- add_this_lang=unsupported
- ;;
- *)
- # Silently disable.
- add_this_lang=unsupported
- ;;
- esac
- done
-
- # Disable Ada if no preexisting GNAT is available.
- case ${add_this_lang}:${language}:${have_gnat} in
- yes:ada:no)
- # Specifically requested language; tell them.
- AC_MSG_ERROR([GNAT is required to build $language])
- ;;
- all:ada:no)
- AC_MSG_WARN([GNAT is required to build $language])
- add_this_lang=unsupported
- ;;
- *:ada:no)
- # Silently disable.
- add_this_lang=unsupported
- ;;
- esac
-
- # Disable D if no preexisting GDC is available.
- case ${add_this_lang}:${language}:${have_gdc} in
- yes:d:no)
- # Specifically requested language; tell them.
- AC_MSG_ERROR([GDC is required to build $language])
- ;;
- all:d:no)
- AC_MSG_WARN([GDC is required to build $language])
- add_this_lang=unsupported
- ;;
- *:d:no)
- # Silently disable.
- add_this_lang=unsupported
- ;;
- esac
-
- # Disable jit if -enable-host-shared not specified
- # but not if building for Mingw. All code in Windows
- # is position independent code (PIC).
- case $target in
- *mingw*) ;;
- *)
- case ${add_this_lang}:${language}:${host_shared} in
- yes:jit:no)
- # PR jit/64780: explicitly specify --enable-host-shared
- AC_MSG_ERROR([
-Enabling language "jit" requires --enable-host-shared.
-
---enable-host-shared typically slows the rest of the compiler down by
-a few %, so you must explicitly enable it.
-
-If you want to build both the jit and the regular compiler, it is often
-best to do this via two separate configure/builds, in separate
-directories, to avoid imposing the performance cost of
---enable-host-shared on the regular compiler.])
- ;;
- all:jit:no)
- AC_MSG_WARN([--enable-host-shared required to build $language])
- add_this_lang=unsupported
- ;;
- *:jit:no)
- # Silently disable.
- add_this_lang=unsupported
- ;;
- esac
- ;;
- esac
-
- # Disable a language that is unsupported by the target.
- case "${add_this_lang}: $unsupported_languages " in
- no:*) ;;
- unsupported:*) ;;
- *:*" $language "*)
- AC_MSG_WARN([${language} not supported for this target])
- add_this_lang=unsupported
- ;;
- esac
-
- case $add_this_lang in
- unsupported)
- # Remove language-dependent dirs.
- disabled_target_libs="$disabled_target_libs $target_libs"
- noconfigdirs="$noconfigdirs $lang_dirs"
- ;;
- no)
- # Remove language-dependent dirs; still show language as supported.
- disabled_target_libs="$disabled_target_libs $target_libs"
- noconfigdirs="$noconfigdirs $lang_dirs"
- potential_languages="${potential_languages}${language},"
- ;;
- all|yes)
- new_enable_languages="${new_enable_languages}${language},"
- potential_languages="${potential_languages}${language},"
- missing_languages=`echo "$missing_languages" | sed "s/,$language,/,/"`
- enabled_target_libs="$enabled_target_libs $target_libs"
- case "${boot_language}:,$enable_stage1_languages," in
- yes:* | *:*,$language,* | *:*,yes, | *:*,all,)
- # Add to (comma-separated) list of stage 1 languages.
- case ",$stage1_languages," in
- *,$language,* | ,yes, | ,all,) ;;
- *) stage1_languages="${stage1_languages}${language}," ;;
- esac
- # We need to bootstrap any supporting libraries.
- bootstrap_target_libs=`echo "${bootstrap_target_libs}${target_libs}," | sed "s/ /,/g"`
- ;;
- esac
- ;;
- esac
- ;;
- esac
- done
-
- # Add target libraries which are only needed for disabled languages
- # to noconfigdirs.
- if test -n "$disabled_target_libs"; then
- for dir in $disabled_target_libs; do
- case " $enabled_target_libs " in
- *" ${dir} "*) ;;
- *) noconfigdirs="$noconfigdirs $dir" ;;
- esac
- done
- fi
-
- AC_ARG_ENABLE(stage1-languages,
- [AS_HELP_STRING([[--enable-stage1-languages[=all]]],
- [choose additional languages to build during
- stage1. Mostly useful for compiler development])],
- [case ,${enable_stage1_languages}, in
- ,no,|,,)
- # Set it to something that will have no effect in the loop below
- enable_stage1_languages=c ;;
- ,yes,)
- enable_stage1_languages=`echo $new_enable_languages | \
- sed -e "s/^,//" -e "s/,$//" ` ;;
- *,all,*)
- enable_stage1_languages=`echo ,$enable_stage1_languages, | \
- sed -e "s/,all,/$new_enable_languages/" -e "s/^,//" -e "s/,$//" ` ;;
- esac
-
- # Add "good" languages from enable_stage1_languages to stage1_languages,
- # while "bad" languages go in missing_languages. Leave no duplicates.
- for i in `echo $enable_stage1_languages | sed 's/,/ /g' `; do
- case $potential_languages in
- *,$i,*)
- case $stage1_languages in
- *,$i,*) ;;
- *) stage1_languages="$stage1_languages$i," ;;
- esac ;;
- *)
- case $missing_languages in
- *,$i,*) ;;
- *) missing_languages="$missing_languages$i," ;;
- esac ;;
- esac
- done])
-
- # Remove leading/trailing commas that were added for simplicity
- potential_languages=`echo "$potential_languages" | sed -e "s/^,//" -e "s/,$//"`
- missing_languages=`echo "$missing_languages" | sed -e "s/^,//" -e "s/,$//"`
- stage1_languages=`echo "$stage1_languages" | sed -e "s/^,//" -e "s/,$//"`
- new_enable_languages=`echo "$new_enable_languages" | sed -e "s/^,//" -e "s/,$//"`
-
- if test "x$missing_languages" != x; then
- AC_MSG_ERROR([
-The following requested languages could not be built: ${missing_languages}
-Supported languages are: ${potential_languages}])
- fi
- if test "x$new_enable_languages" != "x$enable_languages"; then
- echo The following languages will be built: ${new_enable_languages}
- enable_languages="$new_enable_languages"
- fi
-
- AC_SUBST(stage1_languages)
- ac_configure_args=`echo " $ac_configure_args" | sed -e "s/ '--enable-languages=[[^ ]]*'//g" -e "s/$/ '--enable-languages="$enable_languages"'/" `
-fi
-
-# Handle --disable-<component> generically.
-for dir in $configdirs $build_configdirs $target_configdirs ; do
- dirname=`echo $dir | sed -e s/target-//g -e s/build-//g -e s/-/_/g`
- varname=`echo $dirname | sed -e s/+/_/g`
- if eval test x\${enable_${varname}} "=" xno ; then
- noconfigdirs="$noconfigdirs $dir"
- fi
-done
-
-# Check for Boehm's garbage collector
-AC_ARG_ENABLE(objc-gc,
-[AS_HELP_STRING([--enable-objc-gc],
- [enable use of Boehm's garbage collector with the
- GNU Objective-C runtime])])
-AC_ARG_WITH([target-bdw-gc],
-[AS_HELP_STRING([--with-target-bdw-gc=PATHLIST],
- [specify prefix directory for installed bdw-gc package.
- Equivalent to --with-target-bdw-gc-include=PATH/include
- plus --with-target-bdw-gc-lib=PATH/lib])])
-AC_ARG_WITH([target-bdw-gc-include],
-[AS_HELP_STRING([--with-target-bdw-gc-include=PATHLIST],
- [specify directories for installed bdw-gc include files])])
-AC_ARG_WITH([target-bdw-gc-lib],
-[AS_HELP_STRING([--with-target-bdw-gc-lib=PATHLIST],
- [specify directories for installed bdw-gc library])])
-
-case ,${enable_languages},:${enable_objc_gc} in *,objc,*:yes|*,objc,*:auto)
- AC_MSG_CHECKING([for bdw garbage collector])
- if test "x$with_target_bdw_gc$with_target_bdw_gc_include$with_target_bdw_gc_lib" = x; then
- dnl no bdw-gw options, assume default locations
- AC_MSG_RESULT([using bdw-gc in default locations])
- else
- dnl bdw-gw options, first error checking, complete checking in libobjc
- if test "x$with_target_bdw_gc_include" = x && test "x$with_target_bdw_gc_lib" != x; then
- AC_MSG_ERROR([found --with-target-bdw-gc-lib but --with-target-bdw-gc-include missing])
- elif test "x$with_target_bdw_gc_include" != x && test "x$with_target_bdw_gc_lib" = x; then
- AC_MSG_ERROR([found --with-target-bdw-gc-include but --with-target-bdw-gc-lib missing])
- else
- AC_MSG_RESULT([using paths configured with --with-target-bdw-gc options])
- fi
- fi
-esac
-
-# Disable libitm, libsanitizer, libvtv if we're not building C++
-case ,${enable_languages}, in
- *,c++,*)
- # Disable libitm, libsanitizer if we're not building libstdc++
- case "${noconfigdirs}" in
- *target-libstdc++-v3*)
- noconfigdirs="$noconfigdirs target-libitm target-libsanitizer"
- ;;
- *) ;;
- esac
- ;;
- *)
- noconfigdirs="$noconfigdirs target-libitm target-libsanitizer target-libvtv"
- ;;
-esac
-
-case ,${enable_languages}, in
- *,rust,*)
- case " ${noconfigdirs} " in
- *\ target-libstdc++-v3\ *)
- # Disable target libgrust if we're not building target libstdc++.
- noconfigdirs="$noconfigdirs target-libgrust"
- ;;
- esac
- ;;
-esac
-
-# If gcc/ is not in the source tree then we'll not be building a
-# target compiler, assume in that case we don't want to build any
-# target libraries or tools.
-#
-# This was added primarily for the benefit for binutils-gdb who reuse
-# this configure script, but don't always have target tools available.
-if test ! -d ${srcdir}/gcc; then
- skipdirs="${skipdirs} ${target_configdirs}"
-fi
-
-# Remove the entries in $skipdirs and $noconfigdirs from $configdirs,
-# $build_configdirs and $target_configdirs.
-# If we have the source for $noconfigdirs entries, add them to $notsupp.
-
-notsupp=""
-for dir in . $skipdirs $noconfigdirs ; do
- dirname=`echo $dir | sed -e s/target-//g -e s/build-//g`
- if test $dir != . && echo " ${configdirs} " | grep " ${dir} " >/dev/null 2>&1; then
- configdirs=`echo " ${configdirs} " | sed -e "s/ ${dir} / /"`
- if test -r $srcdir/$dirname/configure ; then
- if echo " ${skipdirs} " | grep " ${dir} " >/dev/null 2>&1; then
- true
- else
- notsupp="$notsupp $dir"
- fi
- fi
- fi
- if test $dir != . && echo " ${build_configdirs} " | grep " ${dir} " >/dev/null 2>&1; then
- build_configdirs=`echo " ${build_configdirs} " | sed -e "s/ ${dir} / /"`
- if test -r $srcdir/$dirname/configure ; then
- if echo " ${skipdirs} " | grep " ${dir} " >/dev/null 2>&1; then
- true
- else
- notsupp="$notsupp $dir"
- fi
- fi
- fi
- if test $dir != . && echo " ${target_configdirs} " | grep " ${dir} " >/dev/null 2>&1; then
- target_configdirs=`echo " ${target_configdirs} " | sed -e "s/ ${dir} / /"`
- if test -r $srcdir/$dirname/configure ; then
- if echo " ${skipdirs} " | grep " ${dir} " >/dev/null 2>&1; then
- true
- else
- notsupp="$notsupp $dir"
- fi
- fi
- fi
-done
-
-# Quietly strip out all directories which aren't configurable in this tree.
-# This relies on all configurable subdirectories being autoconfiscated, which
-# is now the case.
-build_configdirs_all="$build_configdirs"
-build_configdirs=
-for i in ${build_configdirs_all} ; do
- j=`echo $i | sed -e s/build-//g`
- if test -f ${srcdir}/$j/configure ; then
- build_configdirs="${build_configdirs} $i"
- fi
-done
-
-configdirs_all="$configdirs"
-configdirs=
-for i in ${configdirs_all} ; do
- if test -f ${srcdir}/$i/configure ; then
- configdirs="${configdirs} $i"
- fi
-done
-
-target_configdirs_all="$target_configdirs"
-target_configdirs=
-for i in ${target_configdirs_all} ; do
- j=`echo $i | sed -e s/target-//g`
- if test -f ${srcdir}/$j/configure ; then
- target_configdirs="${target_configdirs} $i"
- fi
-done
-
-# libiberty-linker-plugin is special: it doesn't have its own source directory,
-# so we have to add it after the preceding checks.
-if test x"$extra_linker_plugin_flags$extra_linker_plugin_configure_flags" != x
-then
- case " $configdirs " in
- *" libiberty "*)
- # If we can build libiberty, we can also build libiberty-linker-plugin.
- configdirs="$configdirs libiberty-linker-plugin"
- extra_linker_plugin_configure_flags="$extra_linker_plugin_configure_flags \
- --with-libiberty=../libiberty-linker-plugin";;
- *)
- AC_MSG_ERROR([libiberty missing]);;
- esac
-fi
-
-# Sometimes we have special requirements for the host libiberty.
-extra_host_libiberty_configure_flags=
-case " $configdirs " in
- *" lto-plugin "* | *" libcc1 "* | *" gdbserver "*)
- # When these are to be built as shared libraries, the same applies to
- # libiberty.
- extra_host_libiberty_configure_flags=--enable-shared
- ;;
-esac
-AC_SUBST(extra_host_libiberty_configure_flags)
-
-# Sometimes we have special requirements for the host zlib.
-extra_host_zlib_configure_flags=
-case " $configdirs " in
- *" bfd "*)
- # When bfd is to be built as a shared library, the same applies to
- # zlib.
- if test "$enable_shared" = "yes"; then
- extra_host_zlib_configure_flags=--enable-host-shared
- fi
- ;;
-esac
-AC_SUBST(extra_host_zlib_configure_flags)
-
-# Produce a warning message for the subdirs we can't configure.
-# This isn't especially interesting in the Cygnus tree, but in the individual
-# FSF releases, it's important to let people know when their machine isn't
-# supported by the one or two programs in a package.
-
-if test -n "${notsupp}" && test -z "${norecursion}" ; then
- # If $appdirs is non-empty, at least one of those directories must still
- # be configured, or we error out. (E.g., if the gas release supports a
- # specified target in some subdirs but not the gas subdir, we shouldn't
- # pretend that all is well.)
- if test -n "$appdirs" ; then
- for dir in $appdirs ; do
- if test -r $dir/Makefile.in ; then
- if echo " ${configdirs} " | grep " ${dir} " >/dev/null 2>&1; then
- appdirs=""
- break
- fi
- if echo " ${target_configdirs} " | grep " target-${dir} " >/dev/null 2>&1; then
- appdirs=""
- break
- fi
- fi
- done
- if test -n "$appdirs" ; then
- echo "*** This configuration is not supported by this package." 1>&2
- exit 1
- fi
- fi
- # Okay, some application will build, or we don't care to check. Still
- # notify of subdirs not getting built.
- echo "*** This configuration is not supported in the following subdirectories:" 1>&2
- echo " ${notsupp}" 1>&2
- echo " (Any other directories should still work fine.)" 1>&2
-fi
-
-case "$host" in
- *msdosdjgpp*)
- enable_gdbtk=no ;;
-esac
-
-# To find our prefix, in gcc_cv_tool_prefix.
-ACX_TOOL_DIRS
-
-copy_dirs=
-
-AC_ARG_WITH([build-sysroot],
- [AS_HELP_STRING([--with-build-sysroot=SYSROOT],
- [use sysroot as the system root during the build])],
- [if test x"$withval" != x ; then
- SYSROOT_CFLAGS_FOR_TARGET="--sysroot=$withval"
- fi],
- [SYSROOT_CFLAGS_FOR_TARGET=])
-AC_SUBST(SYSROOT_CFLAGS_FOR_TARGET)
-
-AC_ARG_WITH([debug-prefix-map],
- [AS_HELP_STRING([--with-debug-prefix-map='A=B C=D ...'],
- [map A to B, C to D ... in debug information])],
- [if test x"$withval" != x; then
- DEBUG_PREFIX_CFLAGS_FOR_TARGET=
- for debug_map in $withval; do
- DEBUG_PREFIX_CFLAGS_FOR_TARGET="$DEBUG_PREFIX_CFLAGS_FOR_TARGET -fdebug-prefix-map=$debug_map"
- done
- fi],
- [DEBUG_PREFIX_CFLAGS_FOR_TARGET=])
-AC_SUBST(DEBUG_PREFIX_CFLAGS_FOR_TARGET)
-
-# During gcc bootstrap, if we use some random cc for stage1 then CFLAGS
-# might be empty or "-g". We don't require a C++ compiler, so CXXFLAGS
-# might also be empty (or "-g", if a non-GCC C++ compiler is in the path).
-# We want to ensure that TARGET libraries (which we know are built with
-# gcc) are built with "-O2 -g", so include those options when setting
-# CFLAGS_FOR_TARGET and CXXFLAGS_FOR_TARGET.
-if test "x$CFLAGS_FOR_TARGET" = x; then
- if test "x${is_cross_compiler}" = xyes; then
- CFLAGS_FOR_TARGET="-g -O2"
- else
- CFLAGS_FOR_TARGET=$CFLAGS
- case " $CFLAGS " in
- *" -O2 "*) ;;
- *) CFLAGS_FOR_TARGET="-O2 $CFLAGS_FOR_TARGET" ;;
- esac
- case " $CFLAGS " in
- *" -g "* | *" -g3 "*) ;;
- *) CFLAGS_FOR_TARGET="-g $CFLAGS_FOR_TARGET" ;;
- esac
- fi
-fi
-AC_SUBST(CFLAGS_FOR_TARGET)
-
-if test "x$CXXFLAGS_FOR_TARGET" = x; then
- if test "x${is_cross_compiler}" = xyes; then
- CXXFLAGS_FOR_TARGET="-g -O2"
- else
- CXXFLAGS_FOR_TARGET=$CXXFLAGS
- case " $CXXFLAGS " in
- *" -O2 "*) ;;
- *) CXXFLAGS_FOR_TARGET="-O2 $CXXFLAGS_FOR_TARGET" ;;
- esac
- case " $CXXFLAGS " in
- *" -g "* | *" -g3 "*) ;;
- *) CXXFLAGS_FOR_TARGET="-g $CXXFLAGS_FOR_TARGET" ;;
- esac
- fi
-fi
-AC_SUBST(CXXFLAGS_FOR_TARGET)
-
-AC_SUBST(LDFLAGS_FOR_TARGET)
-
-# Handle --with-headers=XXX. If the value is not "yes", the contents of
-# the named directory are copied to $(tooldir)/sys-include.
-if test x"${with_headers}" != x && test x"${with_headers}" != xno ; then
- if test x${is_cross_compiler} = xno ; then
- echo 1>&2 '***' --with-headers is only supported when cross compiling
- exit 1
- fi
- if test x"${with_headers}" != xyes ; then
- x=${gcc_cv_tool_prefix}
- copy_dirs="${copy_dirs} ${with_headers} $x/${target_noncanonical}/sys-include"
- fi
-fi
-
-# Handle --with-libs=XXX. If the value is not "yes", the contents of
-# the name directories are copied to $(tooldir)/lib. Multiple directories
-# are permitted.
-if test x"${with_libs}" != x && test x"${with_libs}" != xno ; then
- if test x${is_cross_compiler} = xno ; then
- echo 1>&2 '***' --with-libs is only supported when cross compiling
- exit 1
- fi
- if test x"${with_libs}" != xyes ; then
- # Copy the libraries in reverse order, so that files in the first named
- # library override files in subsequent libraries.
- x=${gcc_cv_tool_prefix}
- for l in ${with_libs}; do
- copy_dirs="$l $x/${target_noncanonical}/lib ${copy_dirs}"
- done
- fi
-fi
-
-# Set with_gnu_as, with_gnu_ld, and with_system_zlib as appropriate.
-#
-# This is done by determining whether or not the appropriate directory
-# is available, and by checking whether or not specific configurations
-# have requested that this magic not happen.
-#
-# The command line options always override the explicit settings in
-# configure.ac, and the settings in configure.ac override this magic.
-#
-# If the default for a toolchain is to use GNU as and ld, and you don't
-# want to do that, then you should use the --without-gnu-as and
-# --without-gnu-ld options for the configure script. Similarly, if
-# the default is to use the included zlib and you don't want to do that,
-# you should use the --with-system-zlib option for the configure script.
-
-if test x${use_gnu_as} = x &&
- echo " ${configdirs} " | grep " gas " > /dev/null 2>&1 ; then
- with_gnu_as=yes
- extra_host_args="$extra_host_args --with-gnu-as"
-fi
-
-if test x${use_gnu_ld} = x &&
- echo " ${configdirs} " | egrep " (go)?ld " > /dev/null 2>&1 ; then
- with_gnu_ld=yes
- extra_host_args="$extra_host_args --with-gnu-ld"
-fi
-
-if test x${use_included_zlib} = x &&
- echo " ${configdirs} " | grep " zlib " > /dev/null 2>&1 ; then
- :
-else
- with_system_zlib=yes
- extra_host_args="$extra_host_args --with-system-zlib"
-fi
-
-# If using newlib, add --with-newlib to the extra_host_args so that gcc/configure
-# can detect this case.
-
-if test x${with_newlib} != xno && echo " ${target_configdirs} " | grep " target-newlib " > /dev/null 2>&1 ; then
- with_newlib=yes
- extra_host_args="$extra_host_args --with-newlib"
-fi
-
-# Handle ${copy_dirs}
-set fnord ${copy_dirs}
-shift
-while test $# != 0 ; do
- if test -f $2/COPIED && test x"`cat $2/COPIED`" = x"$1" ; then
- :
- else
- echo Copying $1 to $2
-
- # Use the install script to create the directory and all required
- # parent directories.
- if test -d $2 ; then
- :
- else
- echo >config.temp
- ${srcdir}/install-sh -c -m 644 config.temp $2/COPIED
- fi
-
- # Copy the directory, assuming we have tar.
- # FIXME: Should we use B in the second tar? Not all systems support it.
- (cd $1; tar -cf - .) | (cd $2; tar -xpf -)
-
- # It is the responsibility of the user to correctly adjust all
- # symlinks. If somebody can figure out how to handle them correctly
- # here, feel free to add the code.
-
- echo $1 > $2/COPIED
- fi
- shift; shift
-done
-
-# Determine a target-dependent exec_prefix that the installed
-# gcc will search in. Keep this list sorted by triplet, with
-# the *-*-osname triplets last.
-md_exec_prefix=
-case "${target}" in
- i[[34567]]86-pc-msdosdjgpp*)
- md_exec_prefix=/dev/env/DJDIR/bin
- ;;
- *-*-hpux* | \
- *-*-nto-qnx* | \
- *-*-solaris2*)
- md_exec_prefix=/usr/ccs/bin
- ;;
-esac
-
-extra_arflags_for_target=
-extra_nmflags_for_target=
-extra_ranlibflags_for_target=
-target_makefile_frag=/dev/null
-case "${target}" in
- spu-*-*)
- target_makefile_frag="config/mt-spu"
- ;;
- loongarch*-*linux* | loongarch*-*gnu*)
- target_makefile_frag="config/mt-loongarch-gnu"
- ;;
- loongarch*-*elf*)
- target_makefile_frag="config/mt-loongarch-elf"
- ;;
- mips*-sde-elf* | mips*-mti-elf* | mips*-img-elf*)
- target_makefile_frag="config/mt-sde"
- ;;
- mipsisa*-*-elfoabi*)
- target_makefile_frag="config/mt-mips-elfoabi"
- ;;
- mips*-*-*linux* | mips*-*-gnu*)
- target_makefile_frag="config/mt-mips-gnu"
- ;;
- nios2-*-elf*)
- target_makefile_frag="config/mt-nios2-elf"
- ;;
- *-*-linux-android*)
- target_makefile_frag="config/mt-android"
- ;;
- *-*-linux* | *-*-gnu* | *-*-k*bsd*-gnu | *-*-kopensolaris*-gnu)
- target_makefile_frag="config/mt-gnu"
- ;;
- *-*-aix4.[[3456789]]* | *-*-aix[[56789]].*)
- # nm and ar from AIX 4.3 and above require -X32_64 flag to all ar and nm
- # commands to handle both 32-bit and 64-bit objects. These flags are
- # harmless if we're using GNU nm or ar.
- extra_arflags_for_target=" -X32_64"
- extra_nmflags_for_target=" -B -X32_64"
- ;;
-esac
-
-alphaieee_frag=/dev/null
-case $target in
- alpha*-*-*)
- # This just makes sure to use the -mieee option to build target libs.
- # This should probably be set individually by each library.
- alphaieee_frag="config/mt-alphaieee"
- ;;
-esac
-
-# If --enable-target-optspace always use -Os instead of -O2 to build
-# the target libraries, similarly if it is not specified, use -Os
-# on selected platforms.
-ospace_frag=/dev/null
-case "${enable_target_optspace}:${target}" in
- yes:*)
- ospace_frag="config/mt-ospace"
- ;;
- :d30v-*)
- ospace_frag="config/mt-d30v"
- ;;
- :m32r-* | :d10v-* | :fr30-* | :i?86*-*-elfiamcu)
- ospace_frag="config/mt-ospace"
- ;;
- no:* | :*)
- ;;
- *)
- echo "*** bad value \"${enable_target_optspace}\" for --enable-target-optspace flag; ignored" 1>&2
- ;;
-esac
-
-# Some systems (e.g., one of the i386-aix systems the gas testers are
-# using) don't handle "\$" correctly, so don't use it here.
-tooldir='${exec_prefix}'/${target_noncanonical}
-build_tooldir=${tooldir}
-
-# Create a .gdbinit file which runs the one in srcdir
-# and tells GDB to look there for source files.
-
-if test -r ${srcdir}/.gdbinit ; then
- case ${srcdir} in
- .) ;;
- *) cat > ./.gdbinit <<EOF
-# ${NO_EDIT}
-dir ${srcdir}
-dir .
-source ${srcdir}/.gdbinit
-EOF
- ;;
- esac
-fi
-
-# Make sure that the compiler is able to generate an executable. If it
-# can't, we are probably in trouble. We don't care whether we can run the
-# executable--we might be using a cross compiler--we only care whether it
-# can be created. At this point the main configure script has set CC.
-we_are_ok=no
-echo "int main () { return 0; }" > conftest.c
-${CC} -o conftest ${CFLAGS} ${CPPFLAGS} ${LDFLAGS} conftest.c
-if test $? = 0 ; then
- if test -s conftest || test -s conftest.exe ; then
- we_are_ok=yes
- fi
-fi
-case $we_are_ok in
- no)
- echo 1>&2 "*** The command '${CC} -o conftest ${CFLAGS} ${CPPFLAGS} ${LDFLAGS} conftest.c' failed."
- echo 1>&2 "*** You must set the environment variable CC to a working compiler."
- rm -f conftest*
- exit 1
- ;;
-esac
-rm -f conftest*
-
-# Decide which environment variable is used to find dynamic libraries.
-case "${host}" in
- *-*-hpux*) RPATH_ENVVAR=SHLIB_PATH ;;
- *-*-darwin*) RPATH_ENVVAR=DYLD_LIBRARY_PATH ;;
- *-*-mingw* | *-*-cygwin ) RPATH_ENVVAR=PATH ;;
- *) RPATH_ENVVAR=LD_LIBRARY_PATH ;;
-esac
-
-# On systems where the dynamic library environment variable is PATH,
-# gcc/ will put dynamic libraries into a subdirectory to avoid adding
-# built executables to PATH.
-if test "$RPATH_ENVVAR" = PATH; then
- GCC_SHLIB_SUBDIR=/shlib
-else
- GCC_SHLIB_SUBDIR=
-fi
-
-# Adjust the toplevel makefile according to whether bootstrap was selected.
-case $enable_bootstrap in
- yes)
- bootstrap_suffix=bootstrap
- BUILD_CONFIG=bootstrap-debug
- ;;
- no)
- bootstrap_suffix=no-bootstrap
- BUILD_CONFIG=
- ;;
-esac
-
-AC_MSG_CHECKING(for default BUILD_CONFIG)
-
-AC_ARG_WITH([build-config],
- [AS_HELP_STRING([--with-build-config='NAME NAME2...'],
- [use config/NAME.mk build configuration])],
- [case $with_build_config in
- yes) with_build_config= ;;
- no) with_build_config= BUILD_CONFIG= ;;
- esac])
-
-if test "x${with_build_config}" != x; then
- BUILD_CONFIG=$with_build_config
-else
- case $BUILD_CONFIG in
- bootstrap-debug)
- if echo "int f (void) { return 0; }" > conftest.c &&
- ${CC} -c conftest.c &&
- mv conftest.o conftest.o.g0 &&
- ${CC} -c -g conftest.c &&
- mv conftest.o conftest.o.g &&
- ${srcdir}/contrib/compare-debug conftest.o.g0 conftest.o.g > /dev/null 2>&1; then
- :
- else
- BUILD_CONFIG=
- fi
- rm -f conftest.c conftest.o conftest.o.g0 conftest.o.g
- ;;
- esac
-fi
-AC_MSG_RESULT($BUILD_CONFIG)
-AC_SUBST(BUILD_CONFIG)
-
-# Use same top-level configure hooks in libgcc/libstdc++/libvtv.
-AC_MSG_CHECKING([for --enable-vtable-verify])
-AC_ARG_ENABLE(vtable-verify,
-[AS_HELP_STRING([--enable-vtable-verify],
- [Enable vtable verification feature])],
-[case "$enableval" in
- yes) enable_vtable_verify=yes ;;
- no) enable_vtable_verify=no ;;
- *) enable_vtable_verify=no;;
- esac],
-[enable_vtable_verify=no])
-AC_MSG_RESULT($enable_vtable_verify)
-
-# Record target_configdirs and the configure arguments for target and
-# build configuration in Makefile.
-target_configdirs=`echo "${target_configdirs}" | sed -e 's/target-//g'`
-build_configdirs=`echo "${build_configdirs}" | sed -e 's/build-//g'`
-bootstrap_fixincludes=no
-
-# If we are building libgomp, bootstrap it.
-if echo " ${target_configdirs} " | grep " libgomp " > /dev/null 2>&1 ; then
- bootstrap_target_libs=${bootstrap_target_libs}target-libgomp,
-fi
-
-# If we are building libsanitizer and $BUILD_CONFIG contains bootstrap-asan
-# or bootstrap-ubsan, bootstrap it.
-if echo " ${target_configdirs} " | grep " libsanitizer " > /dev/null 2>&1; then
- case "$BUILD_CONFIG" in
- *bootstrap-hwasan* | *bootstrap-asan* | *bootstrap-ubsan* )
- bootstrap_target_libs=${bootstrap_target_libs}target-libsanitizer,
- bootstrap_fixincludes=yes
- ;;
- esac
-fi
-
-# If we are building libvtv and --enable-vtable-verify, bootstrap it.
-if echo " ${target_configdirs} " | grep " libvtv " > /dev/null 2>&1 &&
- test "$enable_vtable_verify" != no; then
- bootstrap_target_libs=${bootstrap_target_libs}target-libvtv,
-fi
-
-# If we are building libatomic and the list of enabled languages includes the
-# D frontend, bootstrap it.
-if echo " ${target_configdirs} " | grep " libatomic " > /dev/null 2>&1; then
- case ,${enable_languages}, in
- *,d,*)
- bootstrap_target_libs=${bootstrap_target_libs}target-libatomic,
- ;;
- esac
-fi
-
-# Determine whether gdb needs tk/tcl or not.
-# Use 'maybe' since enable_gdbtk might be true even if tk isn't available
-# and in that case we want gdb to be built without tk. Ugh!
-# In fact I believe gdb is the *only* package directly dependent on tk,
-# so we should be able to put the 'maybe's in unconditionally and
-# leave out the maybe dependencies when enable_gdbtk is false. I'm not
-# 100% sure that that's safe though.
-
-gdb_tk="maybe-all-tcl maybe-all-tk maybe-all-itcl maybe-all-libgui"
-case "$enable_gdbtk" in
- no)
- GDB_TK="" ;;
- yes)
- GDB_TK="${gdb_tk}" ;;
- *)
- # Only add the dependency on gdbtk when GDBtk is part of the gdb
- # distro. Eventually someone will fix this and move Insight, nee
- # gdbtk to a separate directory.
- if test -d ${srcdir}/gdb/gdbtk ; then
- GDB_TK="${gdb_tk}"
- else
- GDB_TK=""
- fi
- ;;
-esac
-CONFIGURE_GDB_TK=`echo ${GDB_TK} | sed s/-all-/-configure-/g`
-INSTALL_GDB_TK=`echo ${GDB_TK} | sed s/-all-/-install-/g`
-
-# gdb and gdbserver depend on gnulib and gdbsupport, but as nothing
-# else does, only include them if one of these is built. The Makefile
-# provides the ordering, so it's enough here to add to the list.
-case " ${configdirs} " in
- *\ gdb\ *)
- configdirs="${configdirs} gnulib gdbsupport"
- ;;
- *\ gdbserver\ *)
- configdirs="${configdirs} gnulib gdbsupport"
- ;;
- *\ sim\ *)
- configdirs="${configdirs} gnulib"
- ;;
-esac
-
-# Strip out unwanted targets.
-
-# While at that, we remove Makefiles if we were started for recursive
-# configuration, so that the top-level Makefile reconfigures them,
-# like we used to do when configure itself was recursive.
-
-# Loop over modules. We used to use the "$extrasub" feature from Autoconf
-# but now we're fixing up the Makefile ourselves with the additional
-# commands passed to AC_CONFIG_FILES. Use separate variables
-# extrasub-{build,host,target} not because there is any reason to split
-# the substitutions up that way, but only to remain below the limit of
-# 99 commands in a script, for HP-UX sed.
-
-# Do not nest @if/@endif or @unless/@endunless pairs, because
-# configure will not warn you at all.
-
-case "$enable_bootstrap:$ENABLE_GOLD: $configdirs :,$stage1_languages," in
- yes:yes:*\ gold\ *:*,c++,*) ;;
- yes:yes:*\ gold\ *:*)
- AC_MSG_ERROR([in a combined tree, bootstrapping with --enable-gold requires c++ in stage1_languages])
- ;;
-esac
-
-extrasub_build=
-for module in ${build_configdirs} ; do
- if test -z "${no_recursion}" \
- && test -f ${build_subdir}/${module}/Makefile; then
- echo 1>&2 "*** removing ${build_subdir}/${module}/Makefile to force reconfigure"
- rm -f ${build_subdir}/${module}/Makefile
- fi
- extrasub_build="$extrasub_build
-/^@if build-$module\$/d
-/^@endif build-$module\$/d
-/^@unless build-$module\$/,/^@endunless build-$module\$/d
-/^@if build-$module-$bootstrap_suffix\$/d
-/^@endif build-$module-$bootstrap_suffix\$/d
-/^@unless build-$module-$bootstrap_suffix\$/,/^@endunless build-$module-$bootstrap_suffix\$/d"
-done
-extrasub_host=
-for module in ${configdirs} ; do
- if test -z "${no_recursion}"; then
- for file in stage*-${module}/Makefile prev-${module}/Makefile ${module}/Makefile; do
- if test -f ${file}; then
- echo 1>&2 "*** removing ${file} to force reconfigure"
- rm -f ${file}
- fi
- done
- fi
- case ${module},${bootstrap_fixincludes} in
- fixincludes,no) host_bootstrap_suffix=no-bootstrap ;;
- *) host_bootstrap_suffix=$bootstrap_suffix ;;
- esac
- extrasub_host="$extrasub_host
-/^@if $module\$/d
-/^@endif $module\$/d
-/^@unless $module\$/,/^@endunless $module\$/d
-/^@if $module-$host_bootstrap_suffix\$/d
-/^@endif $module-$host_bootstrap_suffix\$/d
-/^@unless $module-$host_bootstrap_suffix\$/,/^@endunless $module-$host_bootstrap_suffix\$/d"
-done
-extrasub_target=
-for module in ${target_configdirs} ; do
- if test -z "${no_recursion}" \
- && test -f ${target_subdir}/${module}/Makefile; then
- echo 1>&2 "*** removing ${target_subdir}/${module}/Makefile to force reconfigure"
- rm -f ${target_subdir}/${module}/Makefile
- fi
-
- # We only bootstrap target libraries listed in bootstrap_target_libs.
- case $bootstrap_target_libs in
- *,target-$module,*) target_bootstrap_suffix=$bootstrap_suffix ;;
- *) target_bootstrap_suffix=no-bootstrap ;;
- esac
-
- extrasub_target="$extrasub_target
-/^@if target-$module\$/d
-/^@endif target-$module\$/d
-/^@unless target-$module\$/,/^@endunless target-$module\$/d
-/^@if target-$module-$target_bootstrap_suffix\$/d
-/^@endif target-$module-$target_bootstrap_suffix\$/d
-/^@unless target-$module-$target_bootstrap_suffix\$/,/^@endunless target-$module-$target_bootstrap_suffix\$/d"
-done
-
-# Do the final fixup along with target modules.
-extrasub_target="$extrasub_target
-/^@if /,/^@endif /d
-/^@unless /d
-/^@endunless /d"
-
-if test "$enable_pgo_build" != "no"; then
- extrasub_build="$extrasub_build
-/^@if pgo-build\$/d
-/^@endif pgo-build\$/d"
-fi
-
-# Create the serialization dependencies. This uses a temporary file.
-
-AC_ARG_ENABLE([serial-configure],
-[AS_HELP_STRING([[--enable-serial-[{host,target,build}-]configure]],
- [force sequential configuration of
- sub-packages for the host, target or build
- machine, or all sub-packages])])
-
-case ${enable_serial_configure} in
- yes)
- enable_serial_build_configure=yes
- enable_serial_host_configure=yes
- enable_serial_target_configure=yes
- ;;
-esac
-
-# These force 'configure's to be done one at a time, to avoid problems
-# with contention over a shared config.cache.
-rm -f serdep.tmp
-if test "x${enable_serial_build_configure}" = xyes || test "x${enable_serial_host_configure}" = xyes || test "x${enable_serial_target_configure}" = xyes; then
-echo '# serdep.tmp' > serdep.tmp
-fi
-olditem=
-test "x${enable_serial_build_configure}" = xyes &&
-for item in ${build_configdirs} ; do
- case ${olditem} in
- "") ;;
- *) echo "configure-build-${item}: configure-build-${olditem}" >> serdep.tmp ;;
- esac
- olditem=${item}
-done
-olditem=
-test "x${enable_serial_host_configure}" = xyes &&
-for item in ${configdirs} ; do
- case ${olditem} in
- "") ;;
- *) echo "configure-${item}: configure-${olditem}" >> serdep.tmp ;;
- esac
- olditem=${item}
-done
-olditem=
-test "x${enable_serial_target_configure}" = xyes &&
-for item in ${target_configdirs} ; do
- case ${olditem} in
- "") ;;
- *) echo "configure-target-${item}: configure-target-${olditem}" >> serdep.tmp ;;
- esac
- olditem=${item}
-done
-serialization_dependencies=serdep.tmp
-AC_SUBST_FILE(serialization_dependencies)
-
-# Base args. Strip norecursion, cache-file, srcdir, host, build,
-# target, nonopt, and variable assignments. These are the ones we
-# might not want to pass down to subconfigures. The exception being
-# --cache-file=/dev/null, which is used to turn off the use of cache
-# files altogether, and which should be passed on to subconfigures.
-# Also strip program-prefix, program-suffix, and program-transform-name,
-# so that we can pass down a consistent program-transform-name.
-hbaseargs=
-bbaseargs=
-tbaseargs=
-keep_next=no
-skip_next=no
-eval "set -- $ac_configure_args"
-for ac_arg
-do
- if test X"$skip_next" = X"yes"; then
- skip_next=no
- continue
- fi
- if test X"$keep_next" = X"yes"; then
- case $ac_arg in
- *\'*)
- ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
- esac
- hbaseargs="$hbaseargs '$ac_arg'"
- bbaseargs="$bbaseargs '$ac_arg'"
- tbaseargs="$tbaseargs '$ac_arg'"
- keep_next=no
- continue
- fi
-
- # Handle separated arguments. Based on the logic generated by
- # autoconf 2.59.
- case $ac_arg in
- *=* | --config-cache | -C | -disable-* | --disable-* \
- | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
- | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
- | -with-* | --with-* | -without-* | --without-* | --x)
- separate_arg=no
- ;;
- -*)
- separate_arg=yes
- ;;
- *)
- separate_arg=no
- ;;
- esac
-
- skip_targ=no
- skip_barg=no
- case $ac_arg in
-changequote(,)
- --with-* | --without-*)
- libopt=`echo "$ac_arg" | sed -e 's,^--[^-_]*[-_],,' -e 's,=.*$,,'`
-
- case $libopt in
- *[-_]include)
- lib=`echo "$libopt" | sed 's,[-_]include$,,'`
- ;;
- *[-_]lib)
- lib=`echo "$libopt" | sed 's,[-_]lib$,,'`
- ;;
- *[-_]prefix)
- lib=`echo "$libopt" | sed 's,[-_]prefix$,,'`
- ;;
- *[-_]type)
- lib=`echo "$libopt" | sed 's,[-_]type$,,'`
- ;;
- *)
- lib=$libopt
- ;;
- esac
-changequote([,])
-
- case $lib in
- mpc | mpfr | gmp | isl)
- # If we're processing --with-$lib, --with-$lib-include or
- # --with-$lib-lib, for one of the libs above, and target is
- # different from host, don't pass the current argument to any
- # target library's configure.
- if test x$is_cross_compiler = xyes; then
- skip_targ=yes
- fi
- ;;
- libintl | libiconv)
- # We don't want libintl (and co.) in anything but the host arguments.
- skip_targ=yes
- skip_barg=yes
- ;;
- esac
- ;;
- esac
-
- case "$ac_arg" in
- --cache-file=/dev/null | \
- -cache-file=/dev/null )
- # Handled here to avoid the test to skip args below.
- hbaseargs="$hbaseargs '$ac_arg'"
- bbaseargs="$bbaseargs '$ac_arg'"
- tbaseargs="$tbaseargs '$ac_arg'"
- # Assert: $separate_arg should always be no.
- keep_next=$separate_arg
- ;;
- --no*)
- continue
- ;;
- --c* | \
- --sr* | \
- --ho* | \
- --bu* | \
- --t* | \
- --program-* | \
- -cache_file* | \
- -srcdir* | \
- -host* | \
- -build* | \
- -target* | \
- -program-prefix* | \
- -program-suffix* | \
- -program-transform-name* )
- skip_next=$separate_arg
- continue
- ;;
- -*)
- # An option. Add it.
- case $ac_arg in
- *\'*)
- ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
- esac
- hbaseargs="$hbaseargs '$ac_arg'"
- if test X"$skip_barg" = Xno; then
- bbaseargs="$bbaseargs '$ac_arg'"
- fi
- if test X"$skip_targ" = Xno; then
- tbaseargs="$tbaseargs '$ac_arg'"
- fi
- keep_next=$separate_arg
- ;;
- *)
- # Either a variable assignment, or a nonopt (triplet). Don't
- # pass it down; let the Makefile handle this.
- continue
- ;;
- esac
-done
-# Remove the initial space we just introduced and, as these will be
-# expanded by make, quote '$'.
-hbaseargs=`echo "x$hbaseargs" | sed -e 's/^x *//' -e 's,\\$,$$,g'`
-bbaseargs=`echo "x$bbaseargs" | sed -e 's/^x *//' -e 's,\\$,$$,g'`
-
-# Add in --program-transform-name, after --program-prefix and
-# --program-suffix have been applied to it. Autoconf has already
-# doubled dollar signs and backslashes in program_transform_name; we want
-# the backslashes un-doubled, and then the entire thing wrapped in single
-# quotes, because this will be expanded first by make and then by the shell.
-# Also, because we want to override the logic in subdir configure scripts to
-# choose program_transform_name, replace any s,x,x, with s,y,y,.
-sed -e "s,\\\\\\\\,\\\\,g; s,','\\\\'',g; s/s,x,x,/s,y,y,/" <<EOF_SED > conftestsed.out
-${program_transform_name}
-EOF_SED
-gcc_transform_name=`cat conftestsed.out`
-rm -f conftestsed.out
-hbaseargs="$hbaseargs --program-transform-name='${gcc_transform_name}'"
-bbaseargs="$bbaseargs --program-transform-name='${gcc_transform_name}'"
-tbaseargs="$tbaseargs --program-transform-name='${gcc_transform_name}'"
-if test "$silent" = yes; then
- bbaseargs="$bbaseargs --silent"
- hbaseargs="$hbaseargs --silent"
- tbaseargs="$tbaseargs --silent"
-fi
-
-bbaseargs="$bbaseargs --disable-option-checking"
-hbaseargs="$hbaseargs --disable-option-checking"
-tbaseargs="$tbaseargs --disable-option-checking"
-
-if test "$enable_year2038" = no; then
- bbaseargs="$bbaseargs --disable-year2038"
- hbaseargs="$hbaseargs --disable-year2038"
- tbaseargs="$tbaseargs --disable-year2038"
-fi
-
-# Record and document user additions to sub configure arguments.
-AC_ARG_VAR([build_configargs],
- [additional configure arguments for build directories])
-AC_ARG_VAR([host_configargs],
- [additional configure arguments for host directories])
-AC_ARG_VAR([target_configargs],
- [additional configure arguments for target directories])
-
-# For the build-side libraries, we just need to pretend we're native,
-# and not use the same cache file. Multilibs are neither needed nor
-# desired. We can't even use the same cache file for all build-side
-# libraries, as they're compiled differently; some with C, some with
-# C++ or with different feature-enabling options.
-build_configargs="$build_configargs --cache-file=./config.cache ${bbaseargs}"
-
-# For host modules, accept cache file option, or specification as blank.
-case "${cache_file}" in
-"") # empty
- cache_file_option="" ;;
-/* | [[A-Za-z]]:[[\\/]]* ) # absolute path
- cache_file_option="--cache-file=${cache_file}" ;;
-*) # relative path
- cache_file_option="--cache-file=../${cache_file}" ;;
-esac
-
-# Host dirs don't like to share a cache file either, horribly enough.
-# This seems to be due to autoconf 2.5x stupidity.
-host_configargs="$host_configargs --cache-file=./config.cache ${extra_host_args} ${hbaseargs}"
-
-target_configargs="$target_configargs ${tbaseargs}"
-
-# Passing a --with-cross-host argument lets the target libraries know
-# whether they are being built with a cross-compiler or being built
-# native. However, it would be better to use other mechanisms to make the
-# sorts of decisions they want to make on this basis. Please consider
-# this option to be deprecated. FIXME.
-if test x${is_cross_compiler} = xyes ; then
- target_configargs="--with-cross-host=${host_noncanonical} ${target_configargs}"
-fi
-
-# Special user-friendly check for native x86_64-linux build, if
-# multilib is not explicitly enabled.
-case "$target:$have_compiler:$host:$target:$enable_multilib" in
- x86_64-*linux*:yes:$build:$build:)
- # Make sure we have a development environment that handles 32-bit
- dev64=no
- echo "int main () { return 0; }" > conftest.c
- ${CC} -m32 -o conftest ${CFLAGS} ${CPPFLAGS} ${LDFLAGS} conftest.c
- if test $? = 0 ; then
- if test -s conftest || test -s conftest.exe ; then
- dev64=yes
- fi
- fi
- rm -f conftest*
- if test x${dev64} != xyes ; then
- AC_MSG_ERROR([I suspect your system does not have 32-bit development libraries (libc and headers). If you have them, rerun configure with --enable-multilib. If you do not have them, and want to build a 64-bit-only compiler, rerun configure with --disable-multilib.])
- fi
- ;;
-esac
-
-# Default to --enable-multilib.
-if test x${enable_multilib} = x ; then
- target_configargs="--enable-multilib ${target_configargs}"
-fi
-
-# Pass --with-newlib if appropriate. Note that target_configdirs has
-# changed from the earlier setting of with_newlib.
-if test x${with_newlib} != xno && echo " ${target_configdirs} " | grep " newlib " > /dev/null 2>&1 && test -d ${srcdir}/newlib ; then
- target_configargs="--with-newlib ${target_configargs}"
-fi
-
-# Different target subdirs use different values of certain variables
-# (notably CXX). Worse, multilibs use *lots* of different values.
-# Worse yet, autoconf 2.5x makes some of these 'precious', meaning that
-# it doesn't automatically accept command-line overrides of them.
-# This means it's not safe for target subdirs to share a cache file,
-# which is disgusting, but there you have it. Hopefully this can be
-# fixed in future. It's still worthwhile to use a cache file for each
-# directory. I think.
-
-# Pass the appropriate --build, --host, --target and --cache-file arguments.
-# We need to pass --target, as newer autoconf's requires consistency
-# for target_alias and gcc doesn't manage it consistently.
-target_configargs="--cache-file=./config.cache ${target_configargs}"
-
-FLAGS_FOR_TARGET=
-case " $target_configdirs " in
- *" newlib "*)
- case " $target_configargs " in
- *" --with-newlib "*)
- case "$target" in
- *-cygwin*)
- FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -L$$r/$(TARGET_SUBDIR)/winsup/cygwin -isystem $$s/winsup/cygwin/include'
- ;;
- esac
-
- # If we're not building GCC, don't discard standard headers.
- if test -d ${srcdir}/gcc; then
- FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -nostdinc'
-
- if test "${build}" != "${host}"; then
- # On Canadian crosses, CC_FOR_TARGET will have already been set
- # by `configure', so we won't have an opportunity to add -Bgcc/
- # to it. This is right: we don't want to search that directory
- # for binaries, but we want the header files in there, so add
- # them explicitly.
- FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -isystem $$r/$(HOST_SUBDIR)/gcc/include -isystem $$r/$(HOST_SUBDIR)/gcc/include-fixed'
-
- # Someone might think of using the pre-installed headers on
- # Canadian crosses, in case the installed compiler is not fully
- # compatible with the compiler being built. In this case, it
- # would be better to flag an error than risking having
- # incompatible object files being constructed. We can't
- # guarantee that an error will be flagged, but let's hope the
- # compiler will do it, when presented with incompatible header
- # files.
- fi
- fi
-
- case "${target}-${is_cross_compiler}" in
- i[[3456789]]86-*-linux*-no)
- # Here host == target, so we don't need to build gcc,
- # so we don't want to discard standard headers.
- FLAGS_FOR_TARGET=`echo " $FLAGS_FOR_TARGET " | sed -e 's/ -nostdinc / /'`
- ;;
- *)
- # If we're building newlib, use its generic headers last, but search
- # for any libc-related directories first (so make it the last -B
- # switch).
- FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -B$$r/$(TARGET_SUBDIR)/newlib/ -isystem $$r/$(TARGET_SUBDIR)/newlib/targ-include -isystem $$s/newlib/libc/include'
-
- # If we're building libgloss, find the startup file, simulator library
- # and linker script.
- case " $target_configdirs " in
- *" libgloss "*)
- # Look for startup file, simulator library and maybe linker script.
- FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -B$$r/$(TARGET_SUBDIR)/libgloss/'"$libgloss_dir"
- # Look for libnosys.a in case the target needs it.
- FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -L$$r/$(TARGET_SUBDIR)/libgloss/libnosys'
- # Most targets have the linker script in the source directory.
- FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -L$$s/libgloss/'"$libgloss_dir"
- ;;
- esac
- ;;
- esac
- ;;
- esac
- ;;
-esac
-
-case "$target" in
- x86_64-*mingw* | *-w64-mingw*)
- # MinGW-w64 does not use newlib, nor does it use winsup. It may,
- # however, use a symlink named 'mingw' in ${prefix} .
- FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -L${prefix}/${target}/lib -L${prefix}/mingw/lib -isystem ${prefix}/${target}/include -isystem ${prefix}/mingw/include'
- ;;
- *-mingw*)
- # MinGW can't be handled as Cygwin above since it does not use newlib.
- FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -L$$r/$(TARGET_SUBDIR)/winsup/mingw -L$$r/$(TARGET_SUBDIR)/winsup/w32api/lib -isystem $$s/winsup/mingw/include -isystem $$s/winsup/w32api/include'
- ;;
-esac
-
-# Allow the user to override the flags for
-# our build compiler if desired.
-if test x"${build}" = x"${host}" ; then
- CFLAGS_FOR_BUILD=${CFLAGS_FOR_BUILD-${CFLAGS}}
- CPPFLAGS_FOR_BUILD=${CPPFLAGS_FOR_BUILD-${CPPFLAGS}}
- CXXFLAGS_FOR_BUILD=${CXXFLAGS_FOR_BUILD-${CXXFLAGS}}
- LDFLAGS_FOR_BUILD=${LDFLAGS_FOR_BUILD-${LDFLAGS}}
-fi
-
-# On Canadian crosses, we'll be searching the right directories for
-# the previously-installed cross compiler, so don't bother to add
-# flags for directories within the install tree of the compiler
-# being built; programs in there won't even run.
-if test "${build}" = "${host}" && test -d ${srcdir}/gcc; then
- # Search for pre-installed headers if nothing else fits.
- FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -B$(build_tooldir)/bin/ -B$(build_tooldir)/lib/ -isystem $(build_tooldir)/include -isystem $(build_tooldir)/sys-include'
-fi
-
-if test "x${use_gnu_ld}" = x &&
- echo " ${configdirs} " | grep " ld " > /dev/null ; then
- # Arrange for us to find uninstalled linker scripts.
- FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -L$$r/$(HOST_SUBDIR)/ld'
-fi
-
-# Search for other target-specific linker scripts and such.
-case "${target}" in
- mep*)
- FLAGS_FOR_TARGET="$FLAGS_FOR_TARGET -mlibrary"
- ;;
- # The VxWorks support for shared libraries is getting in
- # incrementally. Make sure it doesn't get activated implicitly:
- *vxworks*)
- if test "${enable_shared-unset}" = unset ; then
- enable_shared=no
- # So the build of libraries knows ...
- target_configargs="${target_configargs} --disable-shared"
- # So gcc knows ...
- host_configargs="${host_configargs} --disable-shared"
- fi
- ;;
-esac
-
-# Makefile fragments.
-for frag in host_makefile_frag target_makefile_frag alphaieee_frag ospace_frag;
-do
- eval fragval=\$$frag
- if test $fragval != /dev/null; then
- eval $frag=${srcdir}/$fragval
- fi
-done
-AC_SUBST_FILE(host_makefile_frag)
-AC_SUBST_FILE(target_makefile_frag)
-AC_SUBST_FILE(alphaieee_frag)
-AC_SUBST_FILE(ospace_frag)
-
-# Miscellanea: directories, flags, etc.
-AC_SUBST(RPATH_ENVVAR)
-AC_SUBST(GCC_SHLIB_SUBDIR)
-AC_SUBST(tooldir)
-AC_SUBST(build_tooldir)
-AC_SUBST(CONFIGURE_GDB_TK)
-AC_SUBST(GDB_TK)
-AC_SUBST(INSTALL_GDB_TK)
-
-# Build module lists & subconfigure args.
-AC_SUBST(build_configargs)
-AC_SUBST(build_configdirs)
-
-# Host module lists & subconfigure args.
-AC_SUBST(host_configargs)
-AC_SUBST(configdirs)
-AC_SUBST(target_configdirs)
-
-# Target module lists & subconfigure args.
-AC_SUBST(target_configargs)
-
-
-# Build tools.
-AC_SUBST(AR_FOR_BUILD)
-AC_SUBST(AS_FOR_BUILD)
-AC_SUBST(CC_FOR_BUILD)
-AC_SUBST(CFLAGS_FOR_BUILD)
-AC_SUBST(CPP_FOR_BUILD)
-AC_SUBST(CPPFLAGS_FOR_BUILD)
-AC_SUBST(CXXFLAGS_FOR_BUILD)
-AC_SUBST(CXX_FOR_BUILD)
-AC_SUBST(DLLTOOL_FOR_BUILD)
-AC_SUBST(DSYMUTIL_FOR_BUILD)
-AC_SUBST(GFORTRAN_FOR_BUILD)
-AC_SUBST(GOC_FOR_BUILD)
-AC_SUBST(GDC_FOR_BUILD)
-AC_SUBST(LDFLAGS_FOR_BUILD)
-AC_SUBST(LD_FOR_BUILD)
-AC_SUBST(NM_FOR_BUILD)
-AC_SUBST(RANLIB_FOR_BUILD)
-AC_SUBST(WINDMC_FOR_BUILD)
-AC_SUBST(WINDRES_FOR_BUILD)
-
-# Generate default definitions for YACC, M4, LEX and other programs that run
-# on the build machine. These are used if the Makefile can't locate these
-# programs in objdir.
-MISSING=`cd $ac_aux_dir && ${PWDCMD-pwd}`/missing
-
-AC_CHECK_PROGS([YACC], ['bison -y' byacc yacc], [$MISSING bison -y])
-case " $build_configdirs " in
- *" bison "*) YACC='$$r/$(BUILD_SUBDIR)/bison/tests/bison -y' ;;
-esac
-
-AC_CHECK_PROGS([BISON], [bison], [$MISSING bison])
-case " $build_configdirs " in
- *" bison "*) BISON='$$r/$(BUILD_SUBDIR)/bison/tests/bison' ;;
-esac
-
-AC_CHECK_PROGS([M4], [gm4 gnum4 m4], [$MISSING m4])
-case " $build_configdirs " in
- *" m4 "*) M4='$$r/$(BUILD_SUBDIR)/m4/m4' ;;
-esac
-
-AC_CHECK_PROGS([LEX], [flex lex], [$MISSING flex])
-case " $build_configdirs " in
- *" flex "*) LEX='$$r/$(BUILD_SUBDIR)/flex/flex' ;;
- *" lex "*) LEX='$$r/$(BUILD_SUBDIR)/lex/lex' ;;
-esac
-
-AC_CHECK_PROGS([FLEX], [flex], [$MISSING flex])
-case " $build_configdirs " in
- *" flex "*) FLEX='$$r/$(BUILD_SUBDIR)/flex/flex' ;;
-esac
-
-AC_CHECK_PROGS([MAKEINFO], makeinfo, [$MISSING makeinfo])
-case " $build_configdirs " in
- *" texinfo "*) MAKEINFO='$$r/$(BUILD_SUBDIR)/texinfo/makeinfo/makeinfo' ;;
- *)
-changequote(,)
- # For an installed makeinfo, we require it to be from texinfo 4.7 or
- # higher, else we use the "missing" dummy.
- if ${MAKEINFO} --version \
- | egrep 'texinfo[^0-9]*(4\.([7-9]|[1-9][0-9])|[5-9]|[1-9][0-9])' >/dev/null 2>&1; then
- :
- else
- MAKEINFO="$MISSING makeinfo"
- fi
- ;;
-changequote([,])
-esac
-
-# FIXME: expect and dejagnu may become build tools?
-
-AC_CHECK_PROGS(EXPECT, expect, expect)
-case " $configdirs " in
- *" expect "*)
- test $host = $build && EXPECT='$$r/$(HOST_SUBDIR)/expect/expect'
- ;;
-esac
-
-AC_CHECK_PROGS(RUNTEST, runtest, runtest)
-case " $configdirs " in
- *" dejagnu "*)
- test $host = $build && RUNTEST='$$s/$(HOST_SUBDIR)/dejagnu/runtest'
- ;;
-esac
-
-
-# Host tools.
-NCN_STRICT_CHECK_TOOLS(AR, ar)
-NCN_STRICT_CHECK_TOOLS(AS, as)
-NCN_STRICT_CHECK_TOOLS(DLLTOOL, dlltool)
-NCN_STRICT_CHECK_TOOLS(DSYMUTIL, dsymutil)
-NCN_STRICT_CHECK_TOOLS(LD, ld)
-NCN_STRICT_CHECK_TOOLS(LIPO, lipo)
-NCN_STRICT_CHECK_TOOLS(NM, nm)
-NCN_STRICT_CHECK_TOOLS(RANLIB, ranlib, true)
-NCN_STRICT_CHECK_TOOLS(STRIP, strip, true)
-NCN_STRICT_CHECK_TOOLS(WINDRES, windres)
-NCN_STRICT_CHECK_TOOLS(WINDMC, windmc)
-NCN_STRICT_CHECK_TOOLS(OBJCOPY, objcopy)
-NCN_STRICT_CHECK_TOOLS(OBJDUMP, objdump)
-NCN_STRICT_CHECK_TOOLS(OTOOL, otool)
-NCN_STRICT_CHECK_TOOLS(READELF, readelf)
-AC_SUBST(CC)
-AC_SUBST(CXX)
-AC_SUBST(CFLAGS)
-AC_SUBST(CXXFLAGS)
-AC_SUBST(GDC)
-AC_SUBST(GDCFLAGS)
-GDCFLAGS=${GDCFLAGS-${CFLAGS}}
-AC_SUBST(PKG_CONFIG_PATH)
-
-GCC_PLUGIN_OPTION(PLUGIN_OPTION)
-AR_PLUGIN_OPTION=
-RANLIB_PLUGIN_OPTION=
-if test -n "$PLUGIN_OPTION"; then
- if $AR --help 2>&1 | grep -q "\--plugin"; then
- AR_PLUGIN_OPTION="$PLUGIN_OPTION"
- fi
- if $RANLIB --help 2>&1 | grep -q "\--plugin"; then
- RANLIB_PLUGIN_OPTION="$PLUGIN_OPTION"
- fi
-fi
-AC_SUBST(AR_PLUGIN_OPTION)
-AC_SUBST(RANLIB_PLUGIN_OPTION)
-
-# Target tools.
-AC_ARG_WITH([build-time-tools],
- [AS_HELP_STRING([--with-build-time-tools=PATH],
- [use given path to find target tools during the build])],
- [case x"$withval" in
- x/*) ;;
- *)
- with_build_time_tools=
- AC_MSG_WARN([argument to --with-build-time-tools must be an absolute path])
- ;;
- esac],
- [with_build_time_tools=])
-
-NCN_STRICT_CHECK_TARGET_TOOLS(CC_FOR_TARGET, cc gcc)
-NCN_STRICT_CHECK_TARGET_TOOLS(CXX_FOR_TARGET, c++ g++ cxx gxx)
-NCN_STRICT_CHECK_TARGET_TOOLS(GCC_FOR_TARGET, gcc, ${CC_FOR_TARGET})
-NCN_STRICT_CHECK_TARGET_TOOLS(GFORTRAN_FOR_TARGET, gfortran)
-NCN_STRICT_CHECK_TARGET_TOOLS(GOC_FOR_TARGET, gccgo)
-NCN_STRICT_CHECK_TARGET_TOOLS(GDC_FOR_TARGET, gdc)
-NCN_STRICT_CHECK_TARGET_TOOLS(GM2_FOR_TARGET, gm2)
-
-ACX_CHECK_INSTALLED_TARGET_TOOL(AR_FOR_TARGET, ar)
-ACX_CHECK_INSTALLED_TARGET_TOOL(AS_FOR_TARGET, as)
-ACX_CHECK_INSTALLED_TARGET_TOOL(DLLTOOL_FOR_TARGET, dlltool)
-ACX_CHECK_INSTALLED_TARGET_TOOL(DSYMUTIL_FOR_TARGET, dsymutil)
-ACX_CHECK_INSTALLED_TARGET_TOOL(LD_FOR_TARGET, ld)
-ACX_CHECK_INSTALLED_TARGET_TOOL(LIPO_FOR_TARGET, lipo)
-ACX_CHECK_INSTALLED_TARGET_TOOL(NM_FOR_TARGET, nm)
-ACX_CHECK_INSTALLED_TARGET_TOOL(OBJCOPY_FOR_TARGET, objcopy)
-ACX_CHECK_INSTALLED_TARGET_TOOL(OBJDUMP_FOR_TARGET, objdump)
-ACX_CHECK_INSTALLED_TARGET_TOOL(OTOOL_FOR_TARGET, otool)
-ACX_CHECK_INSTALLED_TARGET_TOOL(RANLIB_FOR_TARGET, ranlib)
-ACX_CHECK_INSTALLED_TARGET_TOOL(READELF_FOR_TARGET, readelf)
-ACX_CHECK_INSTALLED_TARGET_TOOL(STRIP_FOR_TARGET, strip)
-ACX_CHECK_INSTALLED_TARGET_TOOL(WINDRES_FOR_TARGET, windres)
-ACX_CHECK_INSTALLED_TARGET_TOOL(WINDMC_FOR_TARGET, windmc)
-
-RAW_CXX_FOR_TARGET="$CXX_FOR_TARGET"
-
-GCC_TARGET_TOOL(ar, AR_FOR_TARGET, AR, [binutils/ar])
-GCC_TARGET_TOOL(as, AS_FOR_TARGET, AS, [gas/as-new])
-GCC_TARGET_TOOL(cc, CC_FOR_TARGET, CC, [gcc/xgcc -B$$r/$(HOST_SUBDIR)/gcc/])
-dnl see comments for CXX_FOR_TARGET_FLAG_TO_PASS
-GCC_TARGET_TOOL(c++, CXX_FOR_TARGET, CXX,
- [gcc/xg++ -B$$r/$(HOST_SUBDIR)/gcc/ -nostdinc++ `if test -f $$r/$(TARGET_SUBDIR)/libstdc++-v3/scripts/testsuite_flags; then $(SHELL) $$r/$(TARGET_SUBDIR)/libstdc++-v3/scripts/testsuite_flags --build-includes; else echo -funconfigured-libstdc++-v3 ; fi` -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src/.libs -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/libsupc++/.libs],
- c++)
-GCC_TARGET_TOOL(c++ for libstdc++, RAW_CXX_FOR_TARGET, CXX,
- [gcc/xgcc -shared-libgcc -B$$r/$(HOST_SUBDIR)/gcc -nostdinc++ -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src/.libs -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/libsupc++/.libs],
- c++)
-GCC_TARGET_TOOL(dlltool, DLLTOOL_FOR_TARGET, DLLTOOL, [binutils/dlltool])
-GCC_TARGET_TOOL(dsymutil, DSYMUTIL_FOR_TARGET, DSYMUTIL)
-GCC_TARGET_TOOL(gcc, GCC_FOR_TARGET, , [gcc/xgcc -B$$r/$(HOST_SUBDIR)/gcc/])
-GCC_TARGET_TOOL(gfortran, GFORTRAN_FOR_TARGET, GFORTRAN,
- [gcc/gfortran -B$$r/$(HOST_SUBDIR)/gcc/], fortran)
-GCC_TARGET_TOOL(gccgo, GOC_FOR_TARGET, GOC,
- [gcc/gccgo -B$$r/$(HOST_SUBDIR)/gcc/], go)
-GCC_TARGET_TOOL(gdc, GDC_FOR_TARGET, GDC,
- [gcc/gdc -B$$r/$(HOST_SUBDIR)/gcc/], d)
-GCC_TARGET_TOOL(gm2, GM2_FOR_TARGET, GM2,
- [gcc/gm2 -B$$r/$(HOST_SUBDIR)/gcc/], m2)
-GCC_TARGET_TOOL(ld, LD_FOR_TARGET, LD, [ld/ld-new])
-GCC_TARGET_TOOL(lipo, LIPO_FOR_TARGET, LIPO)
-GCC_TARGET_TOOL(nm, NM_FOR_TARGET, NM, [binutils/nm-new])
-GCC_TARGET_TOOL(objcopy, OBJCOPY_FOR_TARGET, OBJCOPY, [binutils/objcopy])
-GCC_TARGET_TOOL(objdump, OBJDUMP_FOR_TARGET, OBJDUMP, [binutils/objdump])
-GCC_TARGET_TOOL(otool, OTOOL_FOR_TARGET, OTOOL)
-GCC_TARGET_TOOL(ranlib, RANLIB_FOR_TARGET, RANLIB, [binutils/ranlib])
-GCC_TARGET_TOOL(readelf, READELF_FOR_TARGET, READELF, [binutils/readelf])
-GCC_TARGET_TOOL(strip, STRIP_FOR_TARGET, STRIP, [binutils/strip-new])
-GCC_TARGET_TOOL(windres, WINDRES_FOR_TARGET, WINDRES, [binutils/windres])
-GCC_TARGET_TOOL(windmc, WINDMC_FOR_TARGET, WINDMC, [binutils/windmc])
-
-AC_SUBST(FLAGS_FOR_TARGET)
-AC_SUBST(RAW_CXX_FOR_TARGET)
-
-# Certain tools may need extra flags.
-AR_FOR_TARGET=${AR_FOR_TARGET}${extra_arflags_for_target}
-RANLIB_FOR_TARGET=${RANLIB_FOR_TARGET}${extra_ranlibflags_for_target}
-NM_FOR_TARGET=${NM_FOR_TARGET}${extra_nmflags_for_target}
-
-# When building target libraries, except in a Canadian cross, we use
-# the same toolchain as the compiler we just built.
-COMPILER_AS_FOR_TARGET='$(AS_FOR_TARGET)'
-COMPILER_LD_FOR_TARGET='$(LD_FOR_TARGET)'
-COMPILER_NM_FOR_TARGET='$(NM_FOR_TARGET)'
-if test $host = $build; then
- case " $configdirs " in
- *" gcc "*)
- COMPILER_AS_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/as'
- COMPILER_LD_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/collect-ld'
- COMPILER_NM_FOR_TARGET='$$r/$(HOST_SUBDIR)/gcc/nm'${extra_nmflags_for_target}
- ;;
- esac
-fi
-
-AC_SUBST(COMPILER_AS_FOR_TARGET)
-AC_SUBST(COMPILER_LD_FOR_TARGET)
-AC_SUBST(COMPILER_NM_FOR_TARGET)
-
-AC_MSG_CHECKING([whether to enable maintainer-specific portions of Makefiles])
-AC_ARG_ENABLE(maintainer-mode,
-[AS_HELP_STRING([--enable-maintainer-mode],
- [enable make rules and dependencies not useful
- (and sometimes confusing) to the casual installer])],
- USE_MAINTAINER_MODE=$enableval,
- USE_MAINTAINER_MODE=no)
-AC_MSG_RESULT($USE_MAINTAINER_MODE)
-AC_SUBST(MAINTAINER_MODE_TRUE)
-AC_SUBST(MAINTAINER_MODE_FALSE)
-if test "$USE_MAINTAINER_MODE" = yes; then
- MAINTAINER_MODE_TRUE=
- MAINTAINER_MODE_FALSE='#'
-else
- MAINTAINER_MODE_TRUE='#'
- MAINTAINER_MODE_FALSE=
-fi
-MAINT=$MAINTAINER_MODE_TRUE
-AC_SUBST(MAINT)dnl
-
-# ---------------------
-# GCC bootstrap support
-# ---------------------
-
-# Stage specific cflags for build.
-stage1_cflags="-g"
-case $build in
- vax-*-*)
- case ${GCC} in
- yes) stage1_cflags="-g -Wa,-J" ;;
- *) stage1_cflags="-g -J" ;;
- esac ;;
-esac
-
-AC_SUBST(stage1_cflags)
-
-# Enable --enable-checking in stage1 of the compiler.
-AC_ARG_ENABLE(stage1-checking,
-[AS_HELP_STRING([[--enable-stage1-checking[=all]]],
- [choose additional checking for stage1 of the compiler])],
-[stage1_checking=--enable-checking=${enable_stage1_checking}],
-[if test "x$enable_checking" = xno || test "x$enable_checking" = x; then
- # For --disable-checking or implicit --enable-checking=release, avoid
- # setting --enable-checking=gc in the default stage1 checking for LTO
- # bootstraps. See PR62077.
- case $BUILD_CONFIG in
- *lto*)
- stage1_checking=--enable-checking=release,misc,gimple,rtlflag,tree,types;;
- *)
- stage1_checking=--enable-checking=yes,types;;
- esac
- if test "x$enable_checking" = x && \
- test -d ${srcdir}/gcc && \
- test x"`cat ${srcdir}/gcc/DEV-PHASE`" = xexperimental; then
- stage1_checking=--enable-checking=yes,types,extra
- fi
-else
- stage1_checking=--enable-checking=$enable_checking,types
-fi])
-AC_SUBST(stage1_checking)
-
-# Enable -Werror in bootstrap stage2 and later.
-AC_ARG_ENABLE(werror,
-[AS_HELP_STRING([--enable-werror],
- [enable -Werror in bootstrap stage2 and later])],
-[
-case ${enable_werror} in
- yes) stage2_werror_flag="--enable-werror-always" ;;
- *) stage2_werror_flag="" ;;
-esac
-],
-[
-if test -d ${srcdir}/gcc && test x"`cat $srcdir/gcc/DEV-PHASE`" = xexperimental; then
- case $BUILD_CONFIG in
- bootstrap-debug)
- stage2_werror_flag="--enable-werror-always" ;;
- "")
- stage2_werror_flag="--enable-werror-always" ;;
- esac
-fi
-])
-
-AC_SUBST(stage2_werror_flag)
-
-# Specify what files to not compare during bootstrap.
-
-compare_exclusions="gcc/cc*-checksum\$(objext) | gcc/ada/*tools/*"
-compare_exclusions="$compare_exclusions | gcc/m2/gm2-compiler-boot/M2Version*"
-compare_exclusions="$compare_exclusions | gcc/m2/gm2-compiler-boot/SYSTEM*"
-compare_exclusions="$compare_exclusions | gcc/m2/gm2version*"
-case "$target" in
- hppa*64*-*-hpux*) ;;
- powerpc*-ibm-aix*) compare_exclusions="$compare_exclusions | *libgomp*\$(objext)" ;;
-esac
-AC_SUBST(compare_exclusions)
-
-AC_CONFIG_FILES([Makefile],
- [sed "$extrasub_build" Makefile |
- sed "$extrasub_host" |
- sed "$extrasub_target" > mf$$
- mv -f mf$$ Makefile],
- [extrasub_build="$extrasub_build"
- extrasub_host="$extrasub_host"
- extrasub_target="$extrasub_target"])
-AC_OUTPUT
Index: sources/GNU/binutils/create-2.43.1-aarch64-ifunc-patch/file.list
===================================================================
--- sources/GNU/binutils/create-2.43.1-aarch64-ifunc-patch/file.list (revision 75)
+++ sources/GNU/binutils/create-2.43.1-aarch64-ifunc-patch/file.list (nonexistent)
@@ -1 +0,0 @@
-binutils-2.43.1/bfd/elfnn-aarch64.c
Index: sources/GNU/binutils/create-2.43.1-aarch64-ifunc-patch/create.patch.sh
===================================================================
--- sources/GNU/binutils/create-2.43.1-aarch64-ifunc-patch/create.patch.sh (revision 75)
+++ sources/GNU/binutils/create-2.43.1-aarch64-ifunc-patch/create.patch.sh (nonexistent)
@@ -1,15 +0,0 @@
-#!/bin/bash
-
-VERSION=2.43.1
-
-tar --files-from=file.list -xJvf ../binutils-$VERSION.tar.xz
-mv binutils-$VERSION binutils-$VERSION-orig
-
-cp -rf ./binutils-$VERSION-new ./binutils-$VERSION
-
-diff --unified -Nr binutils-$VERSION-orig binutils-$VERSION > binutils-$VERSION-aarch64-ifunc.patch
-
-mv binutils-$VERSION-aarch64-ifunc.patch ../patches
-
-rm -rf ./binutils-$VERSION
-rm -rf ./binutils-$VERSION-orig
Property changes on: sources/GNU/binutils/create-2.43.1-aarch64-ifunc-patch/create.patch.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: sources/GNU/binutils/create-2.43.1-aarch64-ifunc-patch/binutils-2.43.1-new/bfd/elfnn-aarch64.c
===================================================================
--- sources/GNU/binutils/create-2.43.1-aarch64-ifunc-patch/binutils-2.43.1-new/bfd/elfnn-aarch64.c (revision 75)
+++ sources/GNU/binutils/create-2.43.1-aarch64-ifunc-patch/binutils-2.43.1-new/bfd/elfnn-aarch64.c (nonexistent)
@@ -1,10868 +0,0 @@
-/* AArch64-specific support for NN-bit ELF.
- Copyright (C) 2009-2024 Free Software Foundation, Inc.
- Contributed by ARM Ltd.
-
- This file is part of BFD, the Binary File Descriptor library.
-
- This program is free software; you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation; either version 3 of the License, or
- (at your option) any later version.
-
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program; see the file COPYING3. If not,
- see <http://www.gnu.org/licenses/>. */
-
-/* Notes on implementation:
-
- Thread Local Store (TLS)
-
- Overview:
-
- The implementation currently supports both traditional TLS and TLS
- descriptors, but only general dynamic (GD).
-
- For traditional TLS the assembler will present us with code
- fragments of the form:
-
- adrp x0, :tlsgd:foo
- R_AARCH64_TLSGD_ADR_PAGE21(foo)
- add x0, :tlsgd_lo12:foo
- R_AARCH64_TLSGD_ADD_LO12_NC(foo)
- bl __tls_get_addr
- nop
-
- For TLS descriptors the assembler will present us with code
- fragments of the form:
-
- adrp x0, :tlsdesc:foo R_AARCH64_TLSDESC_ADR_PAGE21(foo)
- ldr x1, [x0, #:tlsdesc_lo12:foo] R_AARCH64_TLSDESC_LD64_LO12(foo)
- add x0, x0, #:tlsdesc_lo12:foo R_AARCH64_TLSDESC_ADD_LO12(foo)
- .tlsdesccall foo
- blr x1 R_AARCH64_TLSDESC_CALL(foo)
-
- The relocations R_AARCH64_TLSGD_{ADR_PREL21,ADD_LO12_NC} against foo
- indicate that foo is thread local and should be accessed via the
- traditional TLS mechanims.
-
- The relocations R_AARCH64_TLSDESC_{ADR_PAGE21,LD64_LO12_NC,ADD_LO12_NC}
- against foo indicate that 'foo' is thread local and should be accessed
- via a TLS descriptor mechanism.
-
- The precise instruction sequence is only relevant from the
- perspective of linker relaxation which is currently not implemented.
-
- The static linker must detect that 'foo' is a TLS object and
- allocate a double GOT entry. The GOT entry must be created for both
- global and local TLS symbols. Note that this is different to none
- TLS local objects which do not need a GOT entry.
-
- In the traditional TLS mechanism, the double GOT entry is used to
- provide the tls_index structure, containing module and offset
- entries. The static linker places the relocation R_AARCH64_TLS_DTPMOD
- on the module entry. The loader will subsequently fixup this
- relocation with the module identity.
-
- For global traditional TLS symbols the static linker places an
- R_AARCH64_TLS_DTPREL relocation on the offset entry. The loader
- will subsequently fixup the offset. For local TLS symbols the static
- linker fixes up offset.
-
- In the TLS descriptor mechanism the double GOT entry is used to
- provide the descriptor. The static linker places the relocation
- R_AARCH64_TLSDESC on the first GOT slot. The loader will
- subsequently fix this up.
-
- Implementation:
-
- The handling of TLS symbols is implemented across a number of
- different backend functions. The following is a top level view of
- what processing is performed where.
-
- The TLS implementation maintains state information for each TLS
- symbol. The state information for local and global symbols is kept
- in different places. Global symbols use generic BFD structures while
- local symbols use backend specific structures that are allocated and
- maintained entirely by the backend.
-
- The flow:
-
- elfNN_aarch64_check_relocs()
-
- This function is invoked for each relocation.
-
- The TLS relocations R_AARCH64_TLSGD_{ADR_PREL21,ADD_LO12_NC} and
- R_AARCH64_TLSDESC_{ADR_PAGE21,LD64_LO12_NC,ADD_LO12_NC} are
- spotted. One time creation of local symbol data structures are
- created when the first local symbol is seen.
-
- The reference count for a symbol is incremented. The GOT type for
- each symbol is marked as general dynamic.
-
- elfNN_aarch64_allocate_dynrelocs ()
-
- For each global with positive reference count we allocate a double
- GOT slot. For a traditional TLS symbol we allocate space for two
- relocation entries on the GOT, for a TLS descriptor symbol we
- allocate space for one relocation on the slot. Record the GOT offset
- for this symbol.
-
- elfNN_aarch64_late_size_sections ()
-
- Iterate all input BFDS, look for in the local symbol data structure
- constructed earlier for local TLS symbols and allocate them double
- GOT slots along with space for a single GOT relocation. Update the
- local symbol structure to record the GOT offset allocated.
-
- elfNN_aarch64_relocate_section ()
-
- Calls elfNN_aarch64_final_link_relocate ()
-
- Emit the relevant TLS relocations against the GOT for each TLS
- symbol. For local TLS symbols emit the GOT offset directly. The GOT
- relocations are emitted once the first time a TLS symbol is
- encountered. The implementation uses the LSB of the GOT offset to
- flag that the relevant GOT relocations for a symbol have been
- emitted. All of the TLS code that uses the GOT offset needs to take
- care to mask out this flag bit before using the offset.
-
- elfNN_aarch64_final_link_relocate ()
-
- Fixup the R_AARCH64_TLSGD_{ADR_PREL21, ADD_LO12_NC} relocations. */
-
-#include "sysdep.h"
-#include "bfd.h"
-#include "libiberty.h"
-#include "libbfd.h"
-#include "elf-bfd.h"
-#include "bfdlink.h"
-#include "objalloc.h"
-#include "elf/aarch64.h"
-#include "elfxx-aarch64.h"
-#include "cpu-aarch64.h"
-
-#define ARCH_SIZE NN
-
-#if ARCH_SIZE == 64
-#define AARCH64_R(NAME) R_AARCH64_ ## NAME
-#define AARCH64_R_STR(NAME) "R_AARCH64_" #NAME
-#define HOWTO64(...) HOWTO (__VA_ARGS__)
-#define HOWTO32(...) EMPTY_HOWTO (0)
-#define LOG_FILE_ALIGN 3
-#define BFD_RELOC_AARCH64_TLSDESC_LD64_LO12_NC BFD_RELOC_AARCH64_TLSDESC_LD64_LO12
-#endif
-
-#if ARCH_SIZE == 32
-#define AARCH64_R(NAME) R_AARCH64_P32_ ## NAME
-#define AARCH64_R_STR(NAME) "R_AARCH64_P32_" #NAME
-#define HOWTO64(...) EMPTY_HOWTO (0)
-#define HOWTO32(...) HOWTO (__VA_ARGS__)
-#define LOG_FILE_ALIGN 2
-#define BFD_RELOC_AARCH64_TLSDESC_LD32_LO12 BFD_RELOC_AARCH64_TLSDESC_LD32_LO12_NC
-#define R_AARCH64_P32_TLSDESC_ADD_LO12 R_AARCH64_P32_TLSDESC_ADD_LO12_NC
-#endif
-
-#define IS_AARCH64_TLS_RELOC(R_TYPE) \
- ((R_TYPE) == BFD_RELOC_AARCH64_TLSGD_ADD_LO12_NC \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSGD_ADR_PAGE21 \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSGD_ADR_PREL21 \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSGD_MOVW_G0_NC \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSGD_MOVW_G1 \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSIE_ADR_GOTTPREL_PAGE21 \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSIE_LD32_GOTTPREL_LO12_NC \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSIE_LD64_GOTTPREL_LO12_NC \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSIE_LD_GOTTPREL_PREL19 \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSIE_MOVW_GOTTPREL_G0_NC \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSIE_MOVW_GOTTPREL_G1 \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSLD_ADD_DTPREL_HI12 \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSLD_ADD_DTPREL_LO12 \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSLD_ADD_DTPREL_LO12_NC \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSLD_ADD_LO12_NC \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSLD_ADR_PAGE21 \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSLD_ADR_PREL21 \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSLD_LDST16_DTPREL_LO12 \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSLD_LDST16_DTPREL_LO12_NC \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSLD_LDST32_DTPREL_LO12 \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSLD_LDST32_DTPREL_LO12_NC \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSLD_LDST64_DTPREL_LO12 \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSLD_LDST64_DTPREL_LO12_NC \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSLD_LDST8_DTPREL_LO12 \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSLD_LDST8_DTPREL_LO12_NC \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSLD_MOVW_DTPREL_G0 \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSLD_MOVW_DTPREL_G0_NC \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSLD_MOVW_DTPREL_G1 \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSLD_MOVW_DTPREL_G1_NC \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSLD_MOVW_DTPREL_G2 \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSLE_ADD_TPREL_HI12 \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSLE_ADD_TPREL_LO12 \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSLE_ADD_TPREL_LO12_NC \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSLE_LDST16_TPREL_LO12 \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSLE_LDST16_TPREL_LO12_NC \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSLE_LDST32_TPREL_LO12 \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSLE_LDST32_TPREL_LO12_NC \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSLE_LDST64_TPREL_LO12 \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSLE_LDST64_TPREL_LO12_NC \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSLE_LDST8_TPREL_LO12 \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSLE_LDST8_TPREL_LO12_NC \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G0 \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G0_NC \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G1 \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G1_NC \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G2 \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLS_DTPMOD \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLS_DTPREL \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLS_TPREL \
- || IS_AARCH64_TLSDESC_RELOC ((R_TYPE)))
-
-#define IS_AARCH64_TLS_RELAX_RELOC(R_TYPE) \
- ((R_TYPE) == BFD_RELOC_AARCH64_TLSDESC_ADD \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSDESC_ADD_LO12 \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSDESC_ADR_PAGE21 \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSDESC_ADR_PREL21 \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSDESC_CALL \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSDESC_LD_PREL19 \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSDESC_LDNN_LO12_NC \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSDESC_LDR \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSDESC_OFF_G0_NC \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSDESC_OFF_G1 \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSDESC_LDR \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSGD_ADR_PAGE21 \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSGD_ADR_PREL21 \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSGD_ADD_LO12_NC \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSGD_MOVW_G0_NC \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSGD_MOVW_G1 \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSIE_ADR_GOTTPREL_PAGE21 \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSIE_LD_GOTTPREL_PREL19 \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSIE_LDNN_GOTTPREL_LO12_NC \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSLD_ADD_LO12_NC \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSLD_ADR_PAGE21 \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSLD_ADR_PREL21)
-
-#define IS_AARCH64_TLSDESC_RELOC(R_TYPE) \
- ((R_TYPE) == BFD_RELOC_AARCH64_TLSDESC \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSDESC_ADD \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSDESC_ADD_LO12 \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSDESC_ADR_PAGE21 \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSDESC_ADR_PREL21 \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSDESC_CALL \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSDESC_LD32_LO12_NC \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSDESC_LD64_LO12 \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSDESC_LDR \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSDESC_LD_PREL19 \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSDESC_OFF_G0_NC \
- || (R_TYPE) == BFD_RELOC_AARCH64_TLSDESC_OFF_G1)
-
-#define ELIMINATE_COPY_RELOCS 1
-
-/* Return size of a relocation entry. HTAB is the bfd's
- elf_aarch64_link_hash_entry. */
-#define RELOC_SIZE(HTAB) (sizeof (ElfNN_External_Rela))
-
-/* GOT Entry size - 8 bytes in ELF64 and 4 bytes in ELF32. */
-#define GOT_ENTRY_SIZE (ARCH_SIZE / 8)
-#define PLT_ENTRY_SIZE (32)
-#define PLT_SMALL_ENTRY_SIZE (16)
-#define PLT_TLSDESC_ENTRY_SIZE (32)
-/* PLT sizes with BTI insn. */
-#define PLT_BTI_SMALL_ENTRY_SIZE (24)
-/* PLT sizes with PAC insn. */
-#define PLT_PAC_SMALL_ENTRY_SIZE (24)
-/* PLT sizes with BTI and PAC insn. */
-#define PLT_BTI_PAC_SMALL_ENTRY_SIZE (24)
-
-/* Encoding of the nop instruction. */
-#define INSN_NOP 0xd503201f
-
-#define aarch64_compute_jump_table_size(htab) \
- (((htab)->root.srelplt == NULL) ? 0 \
- : (htab)->root.srelplt->reloc_count * GOT_ENTRY_SIZE)
-
-/* The first entry in a procedure linkage table looks like this
- if the distance between the PLTGOT and the PLT is < 4GB use
- these PLT entries. Note that the dynamic linker gets &PLTGOT[2]
- in x16 and needs to work out PLTGOT[1] by using an address of
- [x16,#-GOT_ENTRY_SIZE]. */
-static const bfd_byte elfNN_aarch64_small_plt0_entry[PLT_ENTRY_SIZE] =
-{
- 0xf0, 0x7b, 0xbf, 0xa9, /* stp x16, x30, [sp, #-16]! */
- 0x10, 0x00, 0x00, 0x90, /* adrp x16, (GOT+16) */
-#if ARCH_SIZE == 64
- 0x11, 0x0A, 0x40, 0xf9, /* ldr x17, [x16, #PLT_GOT+0x10] */
- 0x10, 0x42, 0x00, 0x91, /* add x16, x16,#PLT_GOT+0x10 */
-#else
- 0x11, 0x0A, 0x40, 0xb9, /* ldr w17, [x16, #PLT_GOT+0x8] */
- 0x10, 0x22, 0x00, 0x11, /* add w16, w16,#PLT_GOT+0x8 */
-#endif
- 0x20, 0x02, 0x1f, 0xd6, /* br x17 */
- 0x1f, 0x20, 0x03, 0xd5, /* nop */
- 0x1f, 0x20, 0x03, 0xd5, /* nop */
- 0x1f, 0x20, 0x03, 0xd5, /* nop */
-};
-
-static const bfd_byte elfNN_aarch64_small_plt0_bti_entry[PLT_ENTRY_SIZE] =
-{
- 0x5f, 0x24, 0x03, 0xd5, /* bti c. */
- 0xf0, 0x7b, 0xbf, 0xa9, /* stp x16, x30, [sp, #-16]! */
- 0x10, 0x00, 0x00, 0x90, /* adrp x16, (GOT+16) */
-#if ARCH_SIZE == 64
- 0x11, 0x0A, 0x40, 0xf9, /* ldr x17, [x16, #PLT_GOT+0x10] */
- 0x10, 0x42, 0x00, 0x91, /* add x16, x16,#PLT_GOT+0x10 */
-#else
- 0x11, 0x0A, 0x40, 0xb9, /* ldr w17, [x16, #PLT_GOT+0x8] */
- 0x10, 0x22, 0x00, 0x11, /* add w16, w16,#PLT_GOT+0x8 */
-#endif
- 0x20, 0x02, 0x1f, 0xd6, /* br x17 */
- 0x1f, 0x20, 0x03, 0xd5, /* nop */
- 0x1f, 0x20, 0x03, 0xd5, /* nop */
-};
-
-/* Per function entry in a procedure linkage table looks like this
- if the distance between the PLTGOT and the PLT is < 4GB use
- these PLT entries. Use BTI versions of the PLTs when enabled. */
-static const bfd_byte elfNN_aarch64_small_plt_entry[PLT_SMALL_ENTRY_SIZE] =
-{
- 0x10, 0x00, 0x00, 0x90, /* adrp x16, PLTGOT + n * 8 */
-#if ARCH_SIZE == 64
- 0x11, 0x02, 0x40, 0xf9, /* ldr x17, [x16, PLTGOT + n * 8] */
- 0x10, 0x02, 0x00, 0x91, /* add x16, x16, :lo12:PLTGOT + n * 8 */
-#else
- 0x11, 0x02, 0x40, 0xb9, /* ldr w17, [x16, PLTGOT + n * 4] */
- 0x10, 0x02, 0x00, 0x11, /* add w16, w16, :lo12:PLTGOT + n * 4 */
-#endif
- 0x20, 0x02, 0x1f, 0xd6, /* br x17. */
-};
-
-static const bfd_byte
-elfNN_aarch64_small_plt_bti_entry[PLT_BTI_SMALL_ENTRY_SIZE] =
-{
- 0x5f, 0x24, 0x03, 0xd5, /* bti c. */
- 0x10, 0x00, 0x00, 0x90, /* adrp x16, PLTGOT + n * 8 */
-#if ARCH_SIZE == 64
- 0x11, 0x02, 0x40, 0xf9, /* ldr x17, [x16, PLTGOT + n * 8] */
- 0x10, 0x02, 0x00, 0x91, /* add x16, x16, :lo12:PLTGOT + n * 8 */
-#else
- 0x11, 0x02, 0x40, 0xb9, /* ldr w17, [x16, PLTGOT + n * 4] */
- 0x10, 0x02, 0x00, 0x11, /* add w16, w16, :lo12:PLTGOT + n * 4 */
-#endif
- 0x20, 0x02, 0x1f, 0xd6, /* br x17. */
- 0x1f, 0x20, 0x03, 0xd5, /* nop */
-};
-
-static const bfd_byte
-elfNN_aarch64_small_plt_pac_entry[PLT_PAC_SMALL_ENTRY_SIZE] =
-{
- 0x10, 0x00, 0x00, 0x90, /* adrp x16, PLTGOT + n * 8 */
-#if ARCH_SIZE == 64
- 0x11, 0x02, 0x40, 0xf9, /* ldr x17, [x16, PLTGOT + n * 8] */
- 0x10, 0x02, 0x00, 0x91, /* add x16, x16, :lo12:PLTGOT + n * 8 */
-#else
- 0x11, 0x02, 0x40, 0xb9, /* ldr w17, [x16, PLTGOT + n * 4] */
- 0x10, 0x02, 0x00, 0x11, /* add w16, w16, :lo12:PLTGOT + n * 4 */
-#endif
- 0x9f, 0x21, 0x03, 0xd5, /* autia1716 */
- 0x20, 0x02, 0x1f, 0xd6, /* br x17. */
- 0x1f, 0x20, 0x03, 0xd5, /* nop */
-};
-
-static const bfd_byte
-elfNN_aarch64_small_plt_bti_pac_entry[PLT_BTI_PAC_SMALL_ENTRY_SIZE] =
-{
- 0x5f, 0x24, 0x03, 0xd5, /* bti c. */
- 0x10, 0x00, 0x00, 0x90, /* adrp x16, PLTGOT + n * 8 */
-#if ARCH_SIZE == 64
- 0x11, 0x02, 0x40, 0xf9, /* ldr x17, [x16, PLTGOT + n * 8] */
- 0x10, 0x02, 0x00, 0x91, /* add x16, x16, :lo12:PLTGOT + n * 8 */
-#else
- 0x11, 0x02, 0x40, 0xb9, /* ldr w17, [x16, PLTGOT + n * 4] */
- 0x10, 0x02, 0x00, 0x11, /* add w16, w16, :lo12:PLTGOT + n * 4 */
-#endif
- 0x9f, 0x21, 0x03, 0xd5, /* autia1716 */
- 0x20, 0x02, 0x1f, 0xd6, /* br x17. */
-};
-
-static const bfd_byte
-elfNN_aarch64_tlsdesc_small_plt_entry[PLT_TLSDESC_ENTRY_SIZE] =
-{
- 0xe2, 0x0f, 0xbf, 0xa9, /* stp x2, x3, [sp, #-16]! */
- 0x02, 0x00, 0x00, 0x90, /* adrp x2, 0 */
- 0x03, 0x00, 0x00, 0x90, /* adrp x3, 0 */
-#if ARCH_SIZE == 64
- 0x42, 0x00, 0x40, 0xf9, /* ldr x2, [x2, #0] */
- 0x63, 0x00, 0x00, 0x91, /* add x3, x3, 0 */
-#else
- 0x42, 0x00, 0x40, 0xb9, /* ldr w2, [x2, #0] */
- 0x63, 0x00, 0x00, 0x11, /* add w3, w3, 0 */
-#endif
- 0x40, 0x00, 0x1f, 0xd6, /* br x2 */
- 0x1f, 0x20, 0x03, 0xd5, /* nop */
- 0x1f, 0x20, 0x03, 0xd5, /* nop */
-};
-
-static const bfd_byte
-elfNN_aarch64_tlsdesc_small_plt_bti_entry[PLT_TLSDESC_ENTRY_SIZE] =
-{
- 0x5f, 0x24, 0x03, 0xd5, /* bti c. */
- 0xe2, 0x0f, 0xbf, 0xa9, /* stp x2, x3, [sp, #-16]! */
- 0x02, 0x00, 0x00, 0x90, /* adrp x2, 0 */
- 0x03, 0x00, 0x00, 0x90, /* adrp x3, 0 */
-#if ARCH_SIZE == 64
- 0x42, 0x00, 0x40, 0xf9, /* ldr x2, [x2, #0] */
- 0x63, 0x00, 0x00, 0x91, /* add x3, x3, 0 */
-#else
- 0x42, 0x00, 0x40, 0xb9, /* ldr w2, [x2, #0] */
- 0x63, 0x00, 0x00, 0x11, /* add w3, w3, 0 */
-#endif
- 0x40, 0x00, 0x1f, 0xd6, /* br x2 */
- 0x1f, 0x20, 0x03, 0xd5, /* nop */
-};
-
-#define elf_info_to_howto elfNN_aarch64_info_to_howto
-#define elf_info_to_howto_rel elfNN_aarch64_info_to_howto
-
-#define AARCH64_ELF_ABI_VERSION 0
-
-/* In case we're on a 32-bit machine, construct a 64-bit "-1" value. */
-#define ALL_ONES (~ (bfd_vma) 0)
-
-/* Indexed by the bfd interal reloc enumerators.
- Therefore, the table needs to be synced with BFD_RELOC_AARCH64_*
- in reloc.c. */
-
-static reloc_howto_type elfNN_aarch64_howto_table[] =
-{
- EMPTY_HOWTO (0),
-
- /* Basic data relocations. */
-
- /* Deprecated, but retained for backwards compatibility. */
- HOWTO64 (R_AARCH64_NULL, /* type */
- 0, /* rightshift */
- 0, /* size */
- 0, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- "R_AARCH64_NULL", /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0, /* dst_mask */
- false), /* pcrel_offset */
- HOWTO (R_AARCH64_NONE, /* type */
- 0, /* rightshift */
- 0, /* size */
- 0, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- "R_AARCH64_NONE", /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0, /* dst_mask */
- false), /* pcrel_offset */
-
- /* .xword: (S+A) */
- HOWTO64 (AARCH64_R (ABS64), /* type */
- 0, /* rightshift */
- 8, /* size */
- 64, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_unsigned, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (ABS64), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- ALL_ONES, /* dst_mask */
- false), /* pcrel_offset */
-
- /* .word: (S+A) */
- HOWTO (AARCH64_R (ABS32), /* type */
- 0, /* rightshift */
- 4, /* size */
- 32, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_unsigned, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (ABS32), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xffffffff, /* dst_mask */
- false), /* pcrel_offset */
-
- /* .half: (S+A) */
- HOWTO (AARCH64_R (ABS16), /* type */
- 0, /* rightshift */
- 2, /* size */
- 16, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_unsigned, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (ABS16), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xffff, /* dst_mask */
- false), /* pcrel_offset */
-
- /* .xword: (S+A-P) */
- HOWTO64 (AARCH64_R (PREL64), /* type */
- 0, /* rightshift */
- 8, /* size */
- 64, /* bitsize */
- true, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_signed, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (PREL64), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- ALL_ONES, /* dst_mask */
- true), /* pcrel_offset */
-
- /* .word: (S+A-P) */
- HOWTO (AARCH64_R (PREL32), /* type */
- 0, /* rightshift */
- 4, /* size */
- 32, /* bitsize */
- true, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_signed, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (PREL32), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xffffffff, /* dst_mask */
- true), /* pcrel_offset */
-
- /* .half: (S+A-P) */
- HOWTO (AARCH64_R (PREL16), /* type */
- 0, /* rightshift */
- 2, /* size */
- 16, /* bitsize */
- true, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_signed, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (PREL16), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xffff, /* dst_mask */
- true), /* pcrel_offset */
-
- /* Group relocations to create a 16, 32, 48 or 64 bit
- unsigned data or abs address inline. */
-
- /* MOVZ: ((S+A) >> 0) & 0xffff */
- HOWTO (AARCH64_R (MOVW_UABS_G0), /* type */
- 0, /* rightshift */
- 4, /* size */
- 16, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_unsigned, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (MOVW_UABS_G0), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xffff, /* dst_mask */
- false), /* pcrel_offset */
-
- /* MOVK: ((S+A) >> 0) & 0xffff [no overflow check] */
- HOWTO (AARCH64_R (MOVW_UABS_G0_NC), /* type */
- 0, /* rightshift */
- 4, /* size */
- 16, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (MOVW_UABS_G0_NC), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xffff, /* dst_mask */
- false), /* pcrel_offset */
-
- /* MOVZ: ((S+A) >> 16) & 0xffff */
- HOWTO (AARCH64_R (MOVW_UABS_G1), /* type */
- 16, /* rightshift */
- 4, /* size */
- 16, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_unsigned, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (MOVW_UABS_G1), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xffff, /* dst_mask */
- false), /* pcrel_offset */
-
- /* MOVK: ((S+A) >> 16) & 0xffff [no overflow check] */
- HOWTO64 (AARCH64_R (MOVW_UABS_G1_NC), /* type */
- 16, /* rightshift */
- 4, /* size */
- 16, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (MOVW_UABS_G1_NC), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xffff, /* dst_mask */
- false), /* pcrel_offset */
-
- /* MOVZ: ((S+A) >> 32) & 0xffff */
- HOWTO64 (AARCH64_R (MOVW_UABS_G2), /* type */
- 32, /* rightshift */
- 4, /* size */
- 16, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_unsigned, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (MOVW_UABS_G2), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xffff, /* dst_mask */
- false), /* pcrel_offset */
-
- /* MOVK: ((S+A) >> 32) & 0xffff [no overflow check] */
- HOWTO64 (AARCH64_R (MOVW_UABS_G2_NC), /* type */
- 32, /* rightshift */
- 4, /* size */
- 16, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (MOVW_UABS_G2_NC), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xffff, /* dst_mask */
- false), /* pcrel_offset */
-
- /* MOVZ: ((S+A) >> 48) & 0xffff */
- HOWTO64 (AARCH64_R (MOVW_UABS_G3), /* type */
- 48, /* rightshift */
- 4, /* size */
- 16, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_unsigned, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (MOVW_UABS_G3), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xffff, /* dst_mask */
- false), /* pcrel_offset */
-
- /* Group relocations to create high part of a 16, 32, 48 or 64 bit
- signed data or abs address inline. Will change instruction
- to MOVN or MOVZ depending on sign of calculated value. */
-
- /* MOV[ZN]: ((S+A) >> 0) & 0xffff */
- HOWTO (AARCH64_R (MOVW_SABS_G0), /* type */
- 0, /* rightshift */
- 4, /* size */
- 17, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_signed, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (MOVW_SABS_G0), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xffff, /* dst_mask */
- false), /* pcrel_offset */
-
- /* MOV[ZN]: ((S+A) >> 16) & 0xffff */
- HOWTO64 (AARCH64_R (MOVW_SABS_G1), /* type */
- 16, /* rightshift */
- 4, /* size */
- 17, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_signed, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (MOVW_SABS_G1), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xffff, /* dst_mask */
- false), /* pcrel_offset */
-
- /* MOV[ZN]: ((S+A) >> 32) & 0xffff */
- HOWTO64 (AARCH64_R (MOVW_SABS_G2), /* type */
- 32, /* rightshift */
- 4, /* size */
- 17, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_signed, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (MOVW_SABS_G2), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xffff, /* dst_mask */
- false), /* pcrel_offset */
-
- /* Group relocations to create a 16, 32, 48 or 64 bit
- PC relative address inline. */
-
- /* MOV[NZ]: ((S+A-P) >> 0) & 0xffff */
- HOWTO (AARCH64_R (MOVW_PREL_G0), /* type */
- 0, /* rightshift */
- 4, /* size */
- 17, /* bitsize */
- true, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_signed, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (MOVW_PREL_G0), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xffff, /* dst_mask */
- true), /* pcrel_offset */
-
- /* MOVK: ((S+A-P) >> 0) & 0xffff [no overflow check] */
- HOWTO (AARCH64_R (MOVW_PREL_G0_NC), /* type */
- 0, /* rightshift */
- 4, /* size */
- 16, /* bitsize */
- true, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (MOVW_PREL_G0_NC), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xffff, /* dst_mask */
- true), /* pcrel_offset */
-
- /* MOV[NZ]: ((S+A-P) >> 16) & 0xffff */
- HOWTO (AARCH64_R (MOVW_PREL_G1), /* type */
- 16, /* rightshift */
- 4, /* size */
- 17, /* bitsize */
- true, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_signed, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (MOVW_PREL_G1), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xffff, /* dst_mask */
- true), /* pcrel_offset */
-
- /* MOVK: ((S+A-P) >> 16) & 0xffff [no overflow check] */
- HOWTO64 (AARCH64_R (MOVW_PREL_G1_NC), /* type */
- 16, /* rightshift */
- 4, /* size */
- 16, /* bitsize */
- true, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (MOVW_PREL_G1_NC), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xffff, /* dst_mask */
- true), /* pcrel_offset */
-
- /* MOV[NZ]: ((S+A-P) >> 32) & 0xffff */
- HOWTO64 (AARCH64_R (MOVW_PREL_G2), /* type */
- 32, /* rightshift */
- 4, /* size */
- 17, /* bitsize */
- true, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_signed, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (MOVW_PREL_G2), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xffff, /* dst_mask */
- true), /* pcrel_offset */
-
- /* MOVK: ((S+A-P) >> 32) & 0xffff [no overflow check] */
- HOWTO64 (AARCH64_R (MOVW_PREL_G2_NC), /* type */
- 32, /* rightshift */
- 4, /* size */
- 16, /* bitsize */
- true, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (MOVW_PREL_G2_NC), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xffff, /* dst_mask */
- true), /* pcrel_offset */
-
- /* MOV[NZ]: ((S+A-P) >> 48) & 0xffff */
- HOWTO64 (AARCH64_R (MOVW_PREL_G3), /* type */
- 48, /* rightshift */
- 4, /* size */
- 16, /* bitsize */
- true, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (MOVW_PREL_G3), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xffff, /* dst_mask */
- true), /* pcrel_offset */
-
-/* Relocations to generate 19, 21 and 33 bit PC-relative load/store
- addresses: PG(x) is (x & ~0xfff). */
-
- /* LD-lit: ((S+A-P) >> 2) & 0x7ffff */
- HOWTO (AARCH64_R (LD_PREL_LO19), /* type */
- 2, /* rightshift */
- 4, /* size */
- 19, /* bitsize */
- true, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_signed, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (LD_PREL_LO19), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0x7ffff, /* dst_mask */
- true), /* pcrel_offset */
-
- /* ADR: (S+A-P) & 0x1fffff */
- HOWTO (AARCH64_R (ADR_PREL_LO21), /* type */
- 0, /* rightshift */
- 4, /* size */
- 21, /* bitsize */
- true, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_signed, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (ADR_PREL_LO21), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0x1fffff, /* dst_mask */
- true), /* pcrel_offset */
-
- /* ADRP: ((PG(S+A)-PG(P)) >> 12) & 0x1fffff */
- HOWTO (AARCH64_R (ADR_PREL_PG_HI21), /* type */
- 12, /* rightshift */
- 4, /* size */
- 21, /* bitsize */
- true, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_signed, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (ADR_PREL_PG_HI21), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0x1fffff, /* dst_mask */
- true), /* pcrel_offset */
-
- /* ADRP: ((PG(S+A)-PG(P)) >> 12) & 0x1fffff [no overflow check] */
- HOWTO64 (AARCH64_R (ADR_PREL_PG_HI21_NC), /* type */
- 12, /* rightshift */
- 4, /* size */
- 21, /* bitsize */
- true, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (ADR_PREL_PG_HI21_NC), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0x1fffff, /* dst_mask */
- true), /* pcrel_offset */
-
- /* ADD: (S+A) & 0xfff [no overflow check] */
- HOWTO (AARCH64_R (ADD_ABS_LO12_NC), /* type */
- 0, /* rightshift */
- 4, /* size */
- 12, /* bitsize */
- false, /* pc_relative */
- 10, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (ADD_ABS_LO12_NC), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0x3ffc00, /* dst_mask */
- false), /* pcrel_offset */
-
- /* LD/ST8: (S+A) & 0xfff */
- HOWTO (AARCH64_R (LDST8_ABS_LO12_NC), /* type */
- 0, /* rightshift */
- 4, /* size */
- 12, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (LDST8_ABS_LO12_NC), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xfff, /* dst_mask */
- false), /* pcrel_offset */
-
- /* Relocations for control-flow instructions. */
-
- /* TBZ/NZ: ((S+A-P) >> 2) & 0x3fff */
- HOWTO (AARCH64_R (TSTBR14), /* type */
- 2, /* rightshift */
- 4, /* size */
- 14, /* bitsize */
- true, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_signed, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TSTBR14), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0x3fff, /* dst_mask */
- true), /* pcrel_offset */
-
- /* B.cond: ((S+A-P) >> 2) & 0x7ffff */
- HOWTO (AARCH64_R (CONDBR19), /* type */
- 2, /* rightshift */
- 4, /* size */
- 19, /* bitsize */
- true, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_signed, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (CONDBR19), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0x7ffff, /* dst_mask */
- true), /* pcrel_offset */
-
- /* B: ((S+A-P) >> 2) & 0x3ffffff */
- HOWTO (AARCH64_R (JUMP26), /* type */
- 2, /* rightshift */
- 4, /* size */
- 26, /* bitsize */
- true, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_signed, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (JUMP26), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0x3ffffff, /* dst_mask */
- true), /* pcrel_offset */
-
- /* BL: ((S+A-P) >> 2) & 0x3ffffff */
- HOWTO (AARCH64_R (CALL26), /* type */
- 2, /* rightshift */
- 4, /* size */
- 26, /* bitsize */
- true, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_signed, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (CALL26), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0x3ffffff, /* dst_mask */
- true), /* pcrel_offset */
-
- /* LD/ST16: (S+A) & 0xffe */
- HOWTO (AARCH64_R (LDST16_ABS_LO12_NC), /* type */
- 1, /* rightshift */
- 4, /* size */
- 12, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (LDST16_ABS_LO12_NC), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xffe, /* dst_mask */
- false), /* pcrel_offset */
-
- /* LD/ST32: (S+A) & 0xffc */
- HOWTO (AARCH64_R (LDST32_ABS_LO12_NC), /* type */
- 2, /* rightshift */
- 4, /* size */
- 12, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (LDST32_ABS_LO12_NC), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xffc, /* dst_mask */
- false), /* pcrel_offset */
-
- /* LD/ST64: (S+A) & 0xff8 */
- HOWTO (AARCH64_R (LDST64_ABS_LO12_NC), /* type */
- 3, /* rightshift */
- 4, /* size */
- 12, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (LDST64_ABS_LO12_NC), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xff8, /* dst_mask */
- false), /* pcrel_offset */
-
- /* LD/ST128: (S+A) & 0xff0 */
- HOWTO (AARCH64_R (LDST128_ABS_LO12_NC), /* type */
- 4, /* rightshift */
- 4, /* size */
- 12, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (LDST128_ABS_LO12_NC), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xff0, /* dst_mask */
- false), /* pcrel_offset */
-
- /* Set a load-literal immediate field to bits
- 0x1FFFFC of G(S)-P */
- HOWTO (AARCH64_R (GOT_LD_PREL19), /* type */
- 2, /* rightshift */
- 4, /* size */
- 19, /* bitsize */
- true, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_signed, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (GOT_LD_PREL19), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xffffe0, /* dst_mask */
- true), /* pcrel_offset */
-
- /* Get to the page for the GOT entry for the symbol
- (G(S) - P) using an ADRP instruction. */
- HOWTO (AARCH64_R (ADR_GOT_PAGE), /* type */
- 12, /* rightshift */
- 4, /* size */
- 21, /* bitsize */
- true, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (ADR_GOT_PAGE), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0x1fffff, /* dst_mask */
- true), /* pcrel_offset */
-
- /* LD64: GOT offset G(S) & 0xff8 */
- HOWTO64 (AARCH64_R (LD64_GOT_LO12_NC), /* type */
- 3, /* rightshift */
- 4, /* size */
- 12, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (LD64_GOT_LO12_NC), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xff8, /* dst_mask */
- false), /* pcrel_offset */
-
- /* LD32: GOT offset G(S) & 0xffc */
- HOWTO32 (AARCH64_R (LD32_GOT_LO12_NC), /* type */
- 2, /* rightshift */
- 4, /* size */
- 12, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (LD32_GOT_LO12_NC), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xffc, /* dst_mask */
- false), /* pcrel_offset */
-
- /* Lower 16 bits of GOT offset for the symbol. */
- HOWTO64 (AARCH64_R (MOVW_GOTOFF_G0_NC), /* type */
- 0, /* rightshift */
- 4, /* size */
- 16, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (MOVW_GOTOFF_G0_NC), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xffff, /* dst_mask */
- false), /* pcrel_offset */
-
- /* Higher 16 bits of GOT offset for the symbol. */
- HOWTO64 (AARCH64_R (MOVW_GOTOFF_G1), /* type */
- 16, /* rightshift */
- 4, /* size */
- 16, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_unsigned, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (MOVW_GOTOFF_G1), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xffff, /* dst_mask */
- false), /* pcrel_offset */
-
- /* LD64: GOT offset for the symbol. */
- HOWTO64 (AARCH64_R (LD64_GOTOFF_LO15), /* type */
- 3, /* rightshift */
- 4, /* size */
- 12, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_unsigned, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (LD64_GOTOFF_LO15), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0x7ff8, /* dst_mask */
- false), /* pcrel_offset */
-
- /* LD32: GOT offset to the page address of GOT table.
- (G(S) - PAGE (_GLOBAL_OFFSET_TABLE_)) & 0x5ffc. */
- HOWTO32 (AARCH64_R (LD32_GOTPAGE_LO14), /* type */
- 2, /* rightshift */
- 4, /* size */
- 12, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_unsigned, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (LD32_GOTPAGE_LO14), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0x5ffc, /* dst_mask */
- false), /* pcrel_offset */
-
- /* LD64: GOT offset to the page address of GOT table.
- (G(S) - PAGE (_GLOBAL_OFFSET_TABLE_)) & 0x7ff8. */
- HOWTO64 (AARCH64_R (LD64_GOTPAGE_LO15), /* type */
- 3, /* rightshift */
- 4, /* size */
- 12, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_unsigned, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (LD64_GOTPAGE_LO15), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0x7ff8, /* dst_mask */
- false), /* pcrel_offset */
-
- /* Get to the page for the GOT entry for the symbol
- (G(S) - P) using an ADRP instruction. */
- HOWTO (AARCH64_R (TLSGD_ADR_PAGE21), /* type */
- 12, /* rightshift */
- 4, /* size */
- 21, /* bitsize */
- true, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSGD_ADR_PAGE21), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0x1fffff, /* dst_mask */
- true), /* pcrel_offset */
-
- HOWTO (AARCH64_R (TLSGD_ADR_PREL21), /* type */
- 0, /* rightshift */
- 4, /* size */
- 21, /* bitsize */
- true, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSGD_ADR_PREL21), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0x1fffff, /* dst_mask */
- true), /* pcrel_offset */
-
- /* ADD: GOT offset G(S) & 0xff8 [no overflow check] */
- HOWTO (AARCH64_R (TLSGD_ADD_LO12_NC), /* type */
- 0, /* rightshift */
- 4, /* size */
- 12, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSGD_ADD_LO12_NC), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xfff, /* dst_mask */
- false), /* pcrel_offset */
-
- /* Lower 16 bits of GOT offset to tls_index. */
- HOWTO64 (AARCH64_R (TLSGD_MOVW_G0_NC), /* type */
- 0, /* rightshift */
- 4, /* size */
- 16, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSGD_MOVW_G0_NC), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xffff, /* dst_mask */
- false), /* pcrel_offset */
-
- /* Higher 16 bits of GOT offset to tls_index. */
- HOWTO64 (AARCH64_R (TLSGD_MOVW_G1), /* type */
- 16, /* rightshift */
- 4, /* size */
- 16, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_unsigned, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSGD_MOVW_G1), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xffff, /* dst_mask */
- false), /* pcrel_offset */
-
- HOWTO (AARCH64_R (TLSIE_ADR_GOTTPREL_PAGE21), /* type */
- 12, /* rightshift */
- 4, /* size */
- 21, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSIE_ADR_GOTTPREL_PAGE21), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0x1fffff, /* dst_mask */
- false), /* pcrel_offset */
-
- HOWTO64 (AARCH64_R (TLSIE_LD64_GOTTPREL_LO12_NC), /* type */
- 3, /* rightshift */
- 4, /* size */
- 12, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSIE_LD64_GOTTPREL_LO12_NC), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xff8, /* dst_mask */
- false), /* pcrel_offset */
-
- HOWTO32 (AARCH64_R (TLSIE_LD32_GOTTPREL_LO12_NC), /* type */
- 2, /* rightshift */
- 4, /* size */
- 12, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSIE_LD32_GOTTPREL_LO12_NC), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xffc, /* dst_mask */
- false), /* pcrel_offset */
-
- HOWTO (AARCH64_R (TLSIE_LD_GOTTPREL_PREL19), /* type */
- 2, /* rightshift */
- 4, /* size */
- 19, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSIE_LD_GOTTPREL_PREL19), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0x1ffffc, /* dst_mask */
- false), /* pcrel_offset */
-
- HOWTO64 (AARCH64_R (TLSIE_MOVW_GOTTPREL_G0_NC), /* type */
- 0, /* rightshift */
- 4, /* size */
- 16, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSIE_MOVW_GOTTPREL_G0_NC), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xffff, /* dst_mask */
- false), /* pcrel_offset */
-
- HOWTO64 (AARCH64_R (TLSIE_MOVW_GOTTPREL_G1), /* type */
- 16, /* rightshift */
- 4, /* size */
- 16, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_unsigned, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSIE_MOVW_GOTTPREL_G1), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xffff, /* dst_mask */
- false), /* pcrel_offset */
-
- /* ADD: bit[23:12] of byte offset to module TLS base address. */
- HOWTO (AARCH64_R (TLSLD_ADD_DTPREL_HI12), /* type */
- 12, /* rightshift */
- 4, /* size */
- 12, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_unsigned, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSLD_ADD_DTPREL_HI12), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xfff, /* dst_mask */
- false), /* pcrel_offset */
-
- /* Unsigned 12 bit byte offset to module TLS base address. */
- HOWTO (AARCH64_R (TLSLD_ADD_DTPREL_LO12), /* type */
- 0, /* rightshift */
- 4, /* size */
- 12, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_unsigned, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSLD_ADD_DTPREL_LO12), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xfff, /* dst_mask */
- false), /* pcrel_offset */
-
- /* No overflow check version of BFD_RELOC_AARCH64_TLSLD_ADD_DTPREL_LO12. */
- HOWTO (AARCH64_R (TLSLD_ADD_DTPREL_LO12_NC), /* type */
- 0, /* rightshift */
- 4, /* size */
- 12, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSLD_ADD_DTPREL_LO12_NC), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xfff, /* dst_mask */
- false), /* pcrel_offset */
-
- /* ADD: GOT offset G(S) & 0xff8 [no overflow check] */
- HOWTO (AARCH64_R (TLSLD_ADD_LO12_NC), /* type */
- 0, /* rightshift */
- 4, /* size */
- 12, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSLD_ADD_LO12_NC), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xfff, /* dst_mask */
- false), /* pcrel_offset */
-
- /* Get to the page for the GOT entry for the symbol
- (G(S) - P) using an ADRP instruction. */
- HOWTO (AARCH64_R (TLSLD_ADR_PAGE21), /* type */
- 12, /* rightshift */
- 4, /* size */
- 21, /* bitsize */
- true, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_signed, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSLD_ADR_PAGE21), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0x1fffff, /* dst_mask */
- true), /* pcrel_offset */
-
- HOWTO (AARCH64_R (TLSLD_ADR_PREL21), /* type */
- 0, /* rightshift */
- 4, /* size */
- 21, /* bitsize */
- true, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_signed, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSLD_ADR_PREL21), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0x1fffff, /* dst_mask */
- true), /* pcrel_offset */
-
- /* LD/ST16: bit[11:1] of byte offset to module TLS base address. */
- HOWTO64 (AARCH64_R (TLSLD_LDST16_DTPREL_LO12), /* type */
- 1, /* rightshift */
- 4, /* size */
- 11, /* bitsize */
- false, /* pc_relative */
- 10, /* bitpos */
- complain_overflow_unsigned, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSLD_LDST16_DTPREL_LO12), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0x1ffc00, /* dst_mask */
- false), /* pcrel_offset */
-
- /* Same as BFD_RELOC_AARCH64_TLSLD_LDST16_DTPREL_LO12, but no overflow check. */
- HOWTO64 (AARCH64_R (TLSLD_LDST16_DTPREL_LO12_NC), /* type */
- 1, /* rightshift */
- 4, /* size */
- 11, /* bitsize */
- false, /* pc_relative */
- 10, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSLD_LDST16_DTPREL_LO12_NC), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0x1ffc00, /* dst_mask */
- false), /* pcrel_offset */
-
- /* LD/ST32: bit[11:2] of byte offset to module TLS base address. */
- HOWTO64 (AARCH64_R (TLSLD_LDST32_DTPREL_LO12), /* type */
- 2, /* rightshift */
- 4, /* size */
- 10, /* bitsize */
- false, /* pc_relative */
- 10, /* bitpos */
- complain_overflow_unsigned, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSLD_LDST32_DTPREL_LO12), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0x3ffc00, /* dst_mask */
- false), /* pcrel_offset */
-
- /* Same as BFD_RELOC_AARCH64_TLSLD_LDST32_DTPREL_LO12, but no overflow check. */
- HOWTO64 (AARCH64_R (TLSLD_LDST32_DTPREL_LO12_NC), /* type */
- 2, /* rightshift */
- 4, /* size */
- 10, /* bitsize */
- false, /* pc_relative */
- 10, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSLD_LDST32_DTPREL_LO12_NC), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xffc00, /* dst_mask */
- false), /* pcrel_offset */
-
- /* LD/ST64: bit[11:3] of byte offset to module TLS base address. */
- HOWTO64 (AARCH64_R (TLSLD_LDST64_DTPREL_LO12), /* type */
- 3, /* rightshift */
- 4, /* size */
- 9, /* bitsize */
- false, /* pc_relative */
- 10, /* bitpos */
- complain_overflow_unsigned, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSLD_LDST64_DTPREL_LO12), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0x3ffc00, /* dst_mask */
- false), /* pcrel_offset */
-
- /* Same as BFD_RELOC_AARCH64_TLSLD_LDST64_DTPREL_LO12, but no overflow check. */
- HOWTO64 (AARCH64_R (TLSLD_LDST64_DTPREL_LO12_NC), /* type */
- 3, /* rightshift */
- 4, /* size */
- 9, /* bitsize */
- false, /* pc_relative */
- 10, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSLD_LDST64_DTPREL_LO12_NC), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0x7fc00, /* dst_mask */
- false), /* pcrel_offset */
-
- /* LD/ST8: bit[11:0] of byte offset to module TLS base address. */
- HOWTO64 (AARCH64_R (TLSLD_LDST8_DTPREL_LO12), /* type */
- 0, /* rightshift */
- 4, /* size */
- 12, /* bitsize */
- false, /* pc_relative */
- 10, /* bitpos */
- complain_overflow_unsigned, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSLD_LDST8_DTPREL_LO12), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0x3ffc00, /* dst_mask */
- false), /* pcrel_offset */
-
- /* Same as BFD_RELOC_AARCH64_TLSLD_LDST8_DTPREL_LO12, but no overflow check. */
- HOWTO64 (AARCH64_R (TLSLD_LDST8_DTPREL_LO12_NC), /* type */
- 0, /* rightshift */
- 4, /* size */
- 12, /* bitsize */
- false, /* pc_relative */
- 10, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSLD_LDST8_DTPREL_LO12_NC), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0x3ffc00, /* dst_mask */
- false), /* pcrel_offset */
-
- /* MOVZ: bit[15:0] of byte offset to module TLS base address. */
- HOWTO (AARCH64_R (TLSLD_MOVW_DTPREL_G0), /* type */
- 0, /* rightshift */
- 4, /* size */
- 16, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_unsigned, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSLD_MOVW_DTPREL_G0), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xffff, /* dst_mask */
- false), /* pcrel_offset */
-
- /* No overflow check version of BFD_RELOC_AARCH64_TLSLD_MOVW_DTPREL_G0. */
- HOWTO (AARCH64_R (TLSLD_MOVW_DTPREL_G0_NC), /* type */
- 0, /* rightshift */
- 4, /* size */
- 16, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSLD_MOVW_DTPREL_G0_NC), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xffff, /* dst_mask */
- false), /* pcrel_offset */
-
- /* MOVZ: bit[31:16] of byte offset to module TLS base address. */
- HOWTO (AARCH64_R (TLSLD_MOVW_DTPREL_G1), /* type */
- 16, /* rightshift */
- 4, /* size */
- 16, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_unsigned, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSLD_MOVW_DTPREL_G1), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xffff, /* dst_mask */
- false), /* pcrel_offset */
-
- /* No overflow check version of BFD_RELOC_AARCH64_TLSLD_MOVW_DTPREL_G1. */
- HOWTO64 (AARCH64_R (TLSLD_MOVW_DTPREL_G1_NC), /* type */
- 16, /* rightshift */
- 4, /* size */
- 16, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSLD_MOVW_DTPREL_G1_NC), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xffff, /* dst_mask */
- false), /* pcrel_offset */
-
- /* MOVZ: bit[47:32] of byte offset to module TLS base address. */
- HOWTO64 (AARCH64_R (TLSLD_MOVW_DTPREL_G2), /* type */
- 32, /* rightshift */
- 4, /* size */
- 16, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_unsigned, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSLD_MOVW_DTPREL_G2), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xffff, /* dst_mask */
- false), /* pcrel_offset */
-
- HOWTO64 (AARCH64_R (TLSLE_MOVW_TPREL_G2), /* type */
- 32, /* rightshift */
- 4, /* size */
- 16, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_unsigned, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSLE_MOVW_TPREL_G2), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xffff, /* dst_mask */
- false), /* pcrel_offset */
-
- HOWTO (AARCH64_R (TLSLE_MOVW_TPREL_G1), /* type */
- 16, /* rightshift */
- 4, /* size */
- 16, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSLE_MOVW_TPREL_G1), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xffff, /* dst_mask */
- false), /* pcrel_offset */
-
- HOWTO64 (AARCH64_R (TLSLE_MOVW_TPREL_G1_NC), /* type */
- 16, /* rightshift */
- 4, /* size */
- 16, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSLE_MOVW_TPREL_G1_NC), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xffff, /* dst_mask */
- false), /* pcrel_offset */
-
- HOWTO (AARCH64_R (TLSLE_MOVW_TPREL_G0), /* type */
- 0, /* rightshift */
- 4, /* size */
- 16, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSLE_MOVW_TPREL_G0), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xffff, /* dst_mask */
- false), /* pcrel_offset */
-
- HOWTO (AARCH64_R (TLSLE_MOVW_TPREL_G0_NC), /* type */
- 0, /* rightshift */
- 4, /* size */
- 16, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSLE_MOVW_TPREL_G0_NC), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xffff, /* dst_mask */
- false), /* pcrel_offset */
-
- HOWTO (AARCH64_R (TLSLE_ADD_TPREL_HI12), /* type */
- 12, /* rightshift */
- 4, /* size */
- 12, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_unsigned, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSLE_ADD_TPREL_HI12), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xfff, /* dst_mask */
- false), /* pcrel_offset */
-
- HOWTO (AARCH64_R (TLSLE_ADD_TPREL_LO12), /* type */
- 0, /* rightshift */
- 4, /* size */
- 12, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_unsigned, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSLE_ADD_TPREL_LO12), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xfff, /* dst_mask */
- false), /* pcrel_offset */
-
- HOWTO (AARCH64_R (TLSLE_ADD_TPREL_LO12_NC), /* type */
- 0, /* rightshift */
- 4, /* size */
- 12, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSLE_ADD_TPREL_LO12_NC), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xfff, /* dst_mask */
- false), /* pcrel_offset */
-
- /* LD/ST16: bit[11:1] of byte offset to module TLS base address. */
- HOWTO (AARCH64_R (TLSLE_LDST16_TPREL_LO12), /* type */
- 1, /* rightshift */
- 4, /* size */
- 11, /* bitsize */
- false, /* pc_relative */
- 10, /* bitpos */
- complain_overflow_unsigned, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSLE_LDST16_TPREL_LO12), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0x1ffc00, /* dst_mask */
- false), /* pcrel_offset */
-
- /* Same as BFD_RELOC_AARCH64_TLSLE_LDST16_TPREL_LO12, but no overflow check. */
- HOWTO (AARCH64_R (TLSLE_LDST16_TPREL_LO12_NC), /* type */
- 1, /* rightshift */
- 4, /* size */
- 11, /* bitsize */
- false, /* pc_relative */
- 10, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSLE_LDST16_TPREL_LO12_NC), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0x1ffc00, /* dst_mask */
- false), /* pcrel_offset */
-
- /* LD/ST32: bit[11:2] of byte offset to module TLS base address. */
- HOWTO (AARCH64_R (TLSLE_LDST32_TPREL_LO12), /* type */
- 2, /* rightshift */
- 4, /* size */
- 10, /* bitsize */
- false, /* pc_relative */
- 10, /* bitpos */
- complain_overflow_unsigned, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSLE_LDST32_TPREL_LO12), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xffc00, /* dst_mask */
- false), /* pcrel_offset */
-
- /* Same as BFD_RELOC_AARCH64_TLSLE_LDST32_TPREL_LO12, but no overflow check. */
- HOWTO (AARCH64_R (TLSLE_LDST32_TPREL_LO12_NC), /* type */
- 2, /* rightshift */
- 4, /* size */
- 10, /* bitsize */
- false, /* pc_relative */
- 10, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSLE_LDST32_TPREL_LO12_NC), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xffc00, /* dst_mask */
- false), /* pcrel_offset */
-
- /* LD/ST64: bit[11:3] of byte offset to module TLS base address. */
- HOWTO (AARCH64_R (TLSLE_LDST64_TPREL_LO12), /* type */
- 3, /* rightshift */
- 4, /* size */
- 9, /* bitsize */
- false, /* pc_relative */
- 10, /* bitpos */
- complain_overflow_unsigned, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSLE_LDST64_TPREL_LO12), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0x7fc00, /* dst_mask */
- false), /* pcrel_offset */
-
- /* Same as BFD_RELOC_AARCH64_TLSLE_LDST64_TPREL_LO12, but no overflow check. */
- HOWTO (AARCH64_R (TLSLE_LDST64_TPREL_LO12_NC), /* type */
- 3, /* rightshift */
- 4, /* size */
- 9, /* bitsize */
- false, /* pc_relative */
- 10, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSLE_LDST64_TPREL_LO12_NC), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0x7fc00, /* dst_mask */
- false), /* pcrel_offset */
-
- /* LD/ST8: bit[11:0] of byte offset to module TLS base address. */
- HOWTO (AARCH64_R (TLSLE_LDST8_TPREL_LO12), /* type */
- 0, /* rightshift */
- 4, /* size */
- 12, /* bitsize */
- false, /* pc_relative */
- 10, /* bitpos */
- complain_overflow_unsigned, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSLE_LDST8_TPREL_LO12), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0x3ffc00, /* dst_mask */
- false), /* pcrel_offset */
-
- /* Same as BFD_RELOC_AARCH64_TLSLE_LDST8_TPREL_LO12, but no overflow check. */
- HOWTO (AARCH64_R (TLSLE_LDST8_TPREL_LO12_NC), /* type */
- 0, /* rightshift */
- 4, /* size */
- 12, /* bitsize */
- false, /* pc_relative */
- 10, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSLE_LDST8_TPREL_LO12_NC), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0x3ffc00, /* dst_mask */
- false), /* pcrel_offset */
-
- HOWTO (AARCH64_R (TLSDESC_LD_PREL19), /* type */
- 2, /* rightshift */
- 4, /* size */
- 19, /* bitsize */
- true, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSDESC_LD_PREL19), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0x0ffffe0, /* dst_mask */
- true), /* pcrel_offset */
-
- HOWTO (AARCH64_R (TLSDESC_ADR_PREL21), /* type */
- 0, /* rightshift */
- 4, /* size */
- 21, /* bitsize */
- true, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSDESC_ADR_PREL21), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0x1fffff, /* dst_mask */
- true), /* pcrel_offset */
-
- /* Get to the page for the GOT entry for the symbol
- (G(S) - P) using an ADRP instruction. */
- HOWTO (AARCH64_R (TLSDESC_ADR_PAGE21), /* type */
- 12, /* rightshift */
- 4, /* size */
- 21, /* bitsize */
- true, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSDESC_ADR_PAGE21), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0x1fffff, /* dst_mask */
- true), /* pcrel_offset */
-
- /* LD64: GOT offset G(S) & 0xff8. */
- HOWTO64 (AARCH64_R (TLSDESC_LD64_LO12), /* type */
- 3, /* rightshift */
- 4, /* size */
- 12, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSDESC_LD64_LO12), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xff8, /* dst_mask */
- false), /* pcrel_offset */
-
- /* LD32: GOT offset G(S) & 0xffc. */
- HOWTO32 (AARCH64_R (TLSDESC_LD32_LO12_NC), /* type */
- 2, /* rightshift */
- 4, /* size */
- 12, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSDESC_LD32_LO12_NC), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xffc, /* dst_mask */
- false), /* pcrel_offset */
-
- /* ADD: GOT offset G(S) & 0xfff. */
- HOWTO (AARCH64_R (TLSDESC_ADD_LO12), /* type */
- 0, /* rightshift */
- 4, /* size */
- 12, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont,/* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSDESC_ADD_LO12), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xfff, /* dst_mask */
- false), /* pcrel_offset */
-
- HOWTO64 (AARCH64_R (TLSDESC_OFF_G1), /* type */
- 16, /* rightshift */
- 4, /* size */
- 12, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_unsigned, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSDESC_OFF_G1), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xffff, /* dst_mask */
- false), /* pcrel_offset */
-
- HOWTO64 (AARCH64_R (TLSDESC_OFF_G0_NC), /* type */
- 0, /* rightshift */
- 4, /* size */
- 12, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSDESC_OFF_G0_NC), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0xffff, /* dst_mask */
- false), /* pcrel_offset */
-
- HOWTO64 (AARCH64_R (TLSDESC_LDR), /* type */
- 0, /* rightshift */
- 4, /* size */
- 12, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSDESC_LDR), /* name */
- false, /* partial_inplace */
- 0x0, /* src_mask */
- 0x0, /* dst_mask */
- false), /* pcrel_offset */
-
- HOWTO64 (AARCH64_R (TLSDESC_ADD), /* type */
- 0, /* rightshift */
- 4, /* size */
- 12, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSDESC_ADD), /* name */
- false, /* partial_inplace */
- 0x0, /* src_mask */
- 0x0, /* dst_mask */
- false), /* pcrel_offset */
-
- HOWTO (AARCH64_R (TLSDESC_CALL), /* type */
- 0, /* rightshift */
- 4, /* size */
- 0, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSDESC_CALL), /* name */
- false, /* partial_inplace */
- 0x0, /* src_mask */
- 0x0, /* dst_mask */
- false), /* pcrel_offset */
-
- HOWTO (AARCH64_R (COPY), /* type */
- 0, /* rightshift */
- 4, /* size */
- 64, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_bitfield, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (COPY), /* name */
- true, /* partial_inplace */
- 0, /* src_mask */
- 0xffffffff, /* dst_mask */
- false), /* pcrel_offset */
-
- HOWTO (AARCH64_R (GLOB_DAT), /* type */
- 0, /* rightshift */
- 4, /* size */
- 64, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_bitfield, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (GLOB_DAT), /* name */
- true, /* partial_inplace */
- 0, /* src_mask */
- 0xffffffff, /* dst_mask */
- false), /* pcrel_offset */
-
- HOWTO (AARCH64_R (JUMP_SLOT), /* type */
- 0, /* rightshift */
- 4, /* size */
- 64, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_bitfield, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (JUMP_SLOT), /* name */
- true, /* partial_inplace */
- 0, /* src_mask */
- 0xffffffff, /* dst_mask */
- false), /* pcrel_offset */
-
- HOWTO (AARCH64_R (RELATIVE), /* type */
- 0, /* rightshift */
- 4, /* size */
- 64, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_bitfield, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (RELATIVE), /* name */
- true, /* partial_inplace */
- 0, /* src_mask */
- ALL_ONES, /* dst_mask */
- false), /* pcrel_offset */
-
- HOWTO (AARCH64_R (TLS_DTPMOD), /* type */
- 0, /* rightshift */
- 4, /* size */
- 64, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
-#if ARCH_SIZE == 64
- AARCH64_R_STR (TLS_DTPMOD64), /* name */
-#else
- AARCH64_R_STR (TLS_DTPMOD), /* name */
-#endif
- false, /* partial_inplace */
- 0, /* src_mask */
- ALL_ONES, /* dst_mask */
- false), /* pc_reloffset */
-
- HOWTO (AARCH64_R (TLS_DTPREL), /* type */
- 0, /* rightshift */
- 4, /* size */
- 64, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
-#if ARCH_SIZE == 64
- AARCH64_R_STR (TLS_DTPREL64), /* name */
-#else
- AARCH64_R_STR (TLS_DTPREL), /* name */
-#endif
- false, /* partial_inplace */
- 0, /* src_mask */
- ALL_ONES, /* dst_mask */
- false), /* pcrel_offset */
-
- HOWTO (AARCH64_R (TLS_TPREL), /* type */
- 0, /* rightshift */
- 4, /* size */
- 64, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
-#if ARCH_SIZE == 64
- AARCH64_R_STR (TLS_TPREL64), /* name */
-#else
- AARCH64_R_STR (TLS_TPREL), /* name */
-#endif
- false, /* partial_inplace */
- 0, /* src_mask */
- ALL_ONES, /* dst_mask */
- false), /* pcrel_offset */
-
- HOWTO (AARCH64_R (TLSDESC), /* type */
- 0, /* rightshift */
- 4, /* size */
- 64, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (TLSDESC), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- ALL_ONES, /* dst_mask */
- false), /* pcrel_offset */
-
- HOWTO (AARCH64_R (IRELATIVE), /* type */
- 0, /* rightshift */
- 4, /* size */
- 64, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_bitfield, /* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- AARCH64_R_STR (IRELATIVE), /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- ALL_ONES, /* dst_mask */
- false), /* pcrel_offset */
-
- EMPTY_HOWTO (0),
-};
-
-static reloc_howto_type elfNN_aarch64_howto_none =
- HOWTO (R_AARCH64_NONE, /* type */
- 0, /* rightshift */
- 0, /* size */
- 0, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
- complain_overflow_dont,/* complain_on_overflow */
- bfd_elf_generic_reloc, /* special_function */
- "R_AARCH64_NONE", /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0, /* dst_mask */
- false); /* pcrel_offset */
-
-/* Given HOWTO, return the bfd internal relocation enumerator. */
-
-static bfd_reloc_code_real_type
-elfNN_aarch64_bfd_reloc_from_howto (reloc_howto_type *howto)
-{
- const int size
- = (int) ARRAY_SIZE (elfNN_aarch64_howto_table);
- const ptrdiff_t offset
- = howto - elfNN_aarch64_howto_table;
-
- if (offset > 0 && offset < size - 1)
- return BFD_RELOC_AARCH64_RELOC_START + offset;
-
- if (howto == &elfNN_aarch64_howto_none)
- return BFD_RELOC_AARCH64_NONE;
-
- return BFD_RELOC_AARCH64_RELOC_START;
-}
-
-/* Given R_TYPE, return the bfd internal relocation enumerator. */
-
-static bfd_reloc_code_real_type
-elfNN_aarch64_bfd_reloc_from_type (bfd *abfd, unsigned int r_type)
-{
- static bool initialized_p = false;
- /* Indexed by R_TYPE, values are offsets in the howto_table. */
- static unsigned int offsets[R_AARCH64_end];
-
- if (!initialized_p)
- {
- unsigned int i;
-
- for (i = 1; i < ARRAY_SIZE (elfNN_aarch64_howto_table) - 1; ++i)
- if (elfNN_aarch64_howto_table[i].type != 0)
- offsets[elfNN_aarch64_howto_table[i].type] = i;
-
- initialized_p = true;
- }
-
- if (r_type == R_AARCH64_NONE || r_type == R_AARCH64_NULL)
- return BFD_RELOC_AARCH64_NONE;
-
- /* PR 17512: file: b371e70a. */
- if (r_type >= R_AARCH64_end)
- {
- _bfd_error_handler (_("%pB: unsupported relocation type %#x"),
- abfd, r_type);
- bfd_set_error (bfd_error_bad_value);
- return BFD_RELOC_AARCH64_NONE;
- }
-
- return BFD_RELOC_AARCH64_RELOC_START + offsets[r_type];
-}
-
-struct elf_aarch64_reloc_map
-{
- bfd_reloc_code_real_type from;
- bfd_reloc_code_real_type to;
-};
-
-/* Map bfd generic reloc to AArch64-specific reloc. */
-static const struct elf_aarch64_reloc_map elf_aarch64_reloc_map[] =
-{
- {BFD_RELOC_NONE, BFD_RELOC_AARCH64_NONE},
-
- /* Basic data relocations. */
- {BFD_RELOC_CTOR, BFD_RELOC_AARCH64_NN},
- {BFD_RELOC_64, BFD_RELOC_AARCH64_64},
- {BFD_RELOC_32, BFD_RELOC_AARCH64_32},
- {BFD_RELOC_16, BFD_RELOC_AARCH64_16},
- {BFD_RELOC_64_PCREL, BFD_RELOC_AARCH64_64_PCREL},
- {BFD_RELOC_32_PCREL, BFD_RELOC_AARCH64_32_PCREL},
- {BFD_RELOC_16_PCREL, BFD_RELOC_AARCH64_16_PCREL},
-};
-
-/* Given the bfd internal relocation enumerator in CODE, return the
- corresponding howto entry. */
-
-static reloc_howto_type *
-elfNN_aarch64_howto_from_bfd_reloc (bfd_reloc_code_real_type code)
-{
- unsigned int i;
-
- /* Convert bfd generic reloc to AArch64-specific reloc. */
- if (code < BFD_RELOC_AARCH64_RELOC_START
- || code > BFD_RELOC_AARCH64_RELOC_END)
- for (i = 0; i < ARRAY_SIZE (elf_aarch64_reloc_map); i++)
- if (elf_aarch64_reloc_map[i].from == code)
- {
- code = elf_aarch64_reloc_map[i].to;
- break;
- }
-
- if (code > BFD_RELOC_AARCH64_RELOC_START
- && code < BFD_RELOC_AARCH64_RELOC_END)
- if (elfNN_aarch64_howto_table[code - BFD_RELOC_AARCH64_RELOC_START].type)
- return &elfNN_aarch64_howto_table[code - BFD_RELOC_AARCH64_RELOC_START];
-
- if (code == BFD_RELOC_AARCH64_NONE)
- return &elfNN_aarch64_howto_none;
-
- return NULL;
-}
-
-static reloc_howto_type *
-elfNN_aarch64_howto_from_type (bfd *abfd, unsigned int r_type)
-{
- bfd_reloc_code_real_type val;
- reloc_howto_type *howto;
-
-#if ARCH_SIZE == 32
- if (r_type > 256)
- {
- bfd_set_error (bfd_error_bad_value);
- return NULL;
- }
-#endif
-
- if (r_type == R_AARCH64_NONE)
- return &elfNN_aarch64_howto_none;
-
- val = elfNN_aarch64_bfd_reloc_from_type (abfd, r_type);
- howto = elfNN_aarch64_howto_from_bfd_reloc (val);
-
- if (howto != NULL)
- return howto;
-
- bfd_set_error (bfd_error_bad_value);
- return NULL;
-}
-
-static bool
-elfNN_aarch64_info_to_howto (bfd *abfd, arelent *bfd_reloc,
- Elf_Internal_Rela *elf_reloc)
-{
- unsigned int r_type;
-
- r_type = ELFNN_R_TYPE (elf_reloc->r_info);
- bfd_reloc->howto = elfNN_aarch64_howto_from_type (abfd, r_type);
-
- if (bfd_reloc->howto == NULL)
- {
- /* xgettext:c-format */
- _bfd_error_handler (_("%pB: unsupported relocation type %#x"), abfd, r_type);
- return false;
- }
- return true;
-}
-
-static reloc_howto_type *
-elfNN_aarch64_reloc_type_lookup (bfd *abfd ATTRIBUTE_UNUSED,
- bfd_reloc_code_real_type code)
-{
- reloc_howto_type *howto = elfNN_aarch64_howto_from_bfd_reloc (code);
-
- if (howto != NULL)
- return howto;
-
- bfd_set_error (bfd_error_bad_value);
- return NULL;
-}
-
-static reloc_howto_type *
-elfNN_aarch64_reloc_name_lookup (bfd *abfd ATTRIBUTE_UNUSED,
- const char *r_name)
-{
- unsigned int i;
-
- for (i = 1; i < ARRAY_SIZE (elfNN_aarch64_howto_table) - 1; ++i)
- if (elfNN_aarch64_howto_table[i].name != NULL
- && strcasecmp (elfNN_aarch64_howto_table[i].name, r_name) == 0)
- return &elfNN_aarch64_howto_table[i];
-
- return NULL;
-}
-
-#define TARGET_LITTLE_SYM aarch64_elfNN_le_vec
-#define TARGET_LITTLE_NAME "elfNN-littleaarch64"
-#define TARGET_BIG_SYM aarch64_elfNN_be_vec
-#define TARGET_BIG_NAME "elfNN-bigaarch64"
-
-/* The linker script knows the section names for placement.
- The entry_names are used to do simple name mangling on the stubs.
- Given a function name, and its type, the stub can be found. The
- name can be changed. The only requirement is the %s be present. */
-#define STUB_ENTRY_NAME "__%s_veneer"
-
-/* Stub name for a BTI landing stub. */
-#define BTI_STUB_ENTRY_NAME "__%s_bti_veneer"
-
-/* The name of the dynamic interpreter. This is put in the .interp
- section. */
-#define ELF_DYNAMIC_INTERPRETER "/lib/ld.so.1"
-
-#define AARCH64_MAX_FWD_BRANCH_OFFSET \
- (((1 << 25) - 1) << 2)
-#define AARCH64_MAX_BWD_BRANCH_OFFSET \
- (-((1 << 25) << 2))
-
-#define AARCH64_MAX_ADRP_IMM ((1 << 20) - 1)
-#define AARCH64_MIN_ADRP_IMM (-(1 << 20))
-
-static int
-aarch64_valid_for_adrp_p (bfd_vma value, bfd_vma place)
-{
- bfd_signed_vma offset = (bfd_signed_vma) (PG (value) - PG (place)) >> 12;
- return offset <= AARCH64_MAX_ADRP_IMM && offset >= AARCH64_MIN_ADRP_IMM;
-}
-
-static int
-aarch64_valid_branch_p (bfd_vma value, bfd_vma place)
-{
- bfd_signed_vma offset = (bfd_signed_vma) (value - place);
- return (offset <= AARCH64_MAX_FWD_BRANCH_OFFSET
- && offset >= AARCH64_MAX_BWD_BRANCH_OFFSET);
-}
-
-static const uint32_t aarch64_adrp_branch_stub [] =
-{
- 0x90000010, /* adrp ip0, X */
- /* R_AARCH64_ADR_HI21_PCREL(X) */
- 0x91000210, /* add ip0, ip0, :lo12:X */
- /* R_AARCH64_ADD_ABS_LO12_NC(X) */
- 0xd61f0200, /* br ip0 */
-};
-
-static const uint32_t aarch64_long_branch_stub[] =
-{
-#if ARCH_SIZE == 64
- 0x58000090, /* ldr ip0, 1f */
-#else
- 0x18000090, /* ldr wip0, 1f */
-#endif
- 0x10000011, /* adr ip1, #0 */
- 0x8b110210, /* add ip0, ip0, ip1 */
- 0xd61f0200, /* br ip0 */
- 0x00000000, /* 1: .xword or .word
- R_AARCH64_PRELNN(X) + 12
- */
- 0x00000000,
-};
-
-static const uint32_t aarch64_bti_direct_branch_stub[] =
-{
- 0xd503245f, /* bti c */
- 0x14000000, /* b <label> */
-};
-
-static const uint32_t aarch64_erratum_835769_stub[] =
-{
- 0x00000000, /* Placeholder for multiply accumulate. */
- 0x14000000, /* b <label> */
-};
-
-static const uint32_t aarch64_erratum_843419_stub[] =
-{
- 0x00000000, /* Placeholder for LDR instruction. */
- 0x14000000, /* b <label> */
-};
-
-/* Section name for stubs is the associated section name plus this
- string. */
-#define STUB_SUFFIX ".stub"
-
-enum elf_aarch64_stub_type
-{
- aarch64_stub_none,
- aarch64_stub_adrp_branch,
- aarch64_stub_long_branch,
- aarch64_stub_bti_direct_branch,
- aarch64_stub_erratum_835769_veneer,
- aarch64_stub_erratum_843419_veneer,
-};
-
-struct elf_aarch64_stub_hash_entry
-{
- /* Base hash table entry structure. */
- struct bfd_hash_entry root;
-
- /* The stub section. */
- asection *stub_sec;
-
- /* Offset within stub_sec of the beginning of this stub. */
- bfd_vma stub_offset;
-
- /* Given the symbol's value and its section we can determine its final
- value when building the stubs (so the stub knows where to jump). */
- bfd_vma target_value;
- asection *target_section;
-
- enum elf_aarch64_stub_type stub_type;
-
- /* The symbol table entry, if any, that this was derived from. */
- struct elf_aarch64_link_hash_entry *h;
-
- /* Destination symbol type */
- unsigned char st_type;
-
- /* The target is also a stub. */
- bool double_stub;
-
- /* Where this stub is being called from, or, in the case of combined
- stub sections, the first input section in the group. */
- asection *id_sec;
-
- /* The name for the local symbol at the start of this stub. The
- stub name in the hash table has to be unique; this does not, so
- it can be friendlier. */
- char *output_name;
-
- /* The instruction which caused this stub to be generated (only valid for
- erratum 835769 workaround stubs at present). */
- uint32_t veneered_insn;
-
- /* In an erratum 843419 workaround stub, the ADRP instruction offset. */
- bfd_vma adrp_offset;
-};
-
-/* Used to build a map of a section. This is required for mixed-endian
- code/data. */
-
-typedef struct elf_elf_section_map
-{
- bfd_vma vma;
- char type;
-}
-elf_aarch64_section_map;
-
-
-typedef struct _aarch64_elf_section_data
-{
- struct bfd_elf_section_data elf;
- unsigned int mapcount;
- unsigned int mapsize;
- elf_aarch64_section_map *map;
-}
-_aarch64_elf_section_data;
-
-#define elf_aarch64_section_data(sec) \
- ((_aarch64_elf_section_data *) elf_section_data (sec))
-
-/* The size of the thread control block which is defined to be two pointers. */
-#define TCB_SIZE (ARCH_SIZE/8)*2
-
-struct elf_aarch64_local_symbol
-{
- unsigned int got_type;
- bfd_signed_vma got_refcount;
- bfd_vma got_offset;
-
- /* Offset of the GOTPLT entry reserved for the TLS descriptor. The
- offset is from the end of the jump table and reserved entries
- within the PLTGOT.
-
- The magic value (bfd_vma) -1 indicates that an offset has not be
- allocated. */
- bfd_vma tlsdesc_got_jump_table_offset;
-};
-
-struct elf_aarch64_obj_tdata
-{
- struct elf_obj_tdata root;
-
- /* local symbol descriptors */
- struct elf_aarch64_local_symbol *locals;
-
- /* Zero to warn when linking objects with incompatible enum sizes. */
- int no_enum_size_warning;
-
- /* Zero to warn when linking objects with incompatible wchar_t sizes. */
- int no_wchar_size_warning;
-
- /* All GNU_PROPERTY_AARCH64_FEATURE_1_AND properties. */
- uint32_t gnu_and_prop;
-
- /* Zero to warn when linking objects with incompatible
- GNU_PROPERTY_AARCH64_FEATURE_1_BTI. */
- int no_bti_warn;
-
- /* PLT type based on security. */
- aarch64_plt_type plt_type;
-};
-
-#define elf_aarch64_tdata(bfd) \
- ((struct elf_aarch64_obj_tdata *) (bfd)->tdata.any)
-
-#define elf_aarch64_locals(bfd) (elf_aarch64_tdata (bfd)->locals)
-
-#define is_aarch64_elf(bfd) \
- (bfd_get_flavour (bfd) == bfd_target_elf_flavour \
- && elf_tdata (bfd) != NULL \
- && elf_object_id (bfd) == AARCH64_ELF_DATA)
-
-static bool
-elfNN_aarch64_mkobject (bfd *abfd)
-{
- return bfd_elf_allocate_object (abfd, sizeof (struct elf_aarch64_obj_tdata),
- AARCH64_ELF_DATA);
-}
-
-#define elf_aarch64_hash_entry(ent) \
- ((struct elf_aarch64_link_hash_entry *)(ent))
-
-#define GOT_UNKNOWN 0
-#define GOT_NORMAL 1
-#define GOT_TLS_GD 2
-#define GOT_TLS_IE 4
-#define GOT_TLSDESC_GD 8
-
-#define GOT_TLS_GD_ANY_P(type) ((type & GOT_TLS_GD) || (type & GOT_TLSDESC_GD))
-
-/* AArch64 ELF linker hash entry. */
-struct elf_aarch64_link_hash_entry
-{
- struct elf_link_hash_entry root;
-
- /* Since PLT entries have variable size, we need to record the
- index into .got.plt instead of recomputing it from the PLT
- offset. */
- bfd_signed_vma plt_got_offset;
-
- /* Bit mask representing the type of GOT entry(s) if any required by
- this symbol. */
- unsigned int got_type;
-
- /* TRUE if symbol is defined as a protected symbol. */
- unsigned int def_protected : 1;
-
- /* A pointer to the most recently used stub hash entry against this
- symbol. */
- struct elf_aarch64_stub_hash_entry *stub_cache;
-
- /* Offset of the GOTPLT entry reserved for the TLS descriptor. The offset
- is from the end of the jump table and reserved entries within the PLTGOT.
-
- The magic value (bfd_vma) -1 indicates that an offset has not
- be allocated. */
- bfd_vma tlsdesc_got_jump_table_offset;
-};
-
-static unsigned int
-elfNN_aarch64_symbol_got_type (struct elf_link_hash_entry *h,
- bfd *abfd,
- unsigned long r_symndx)
-{
- if (h)
- return elf_aarch64_hash_entry (h)->got_type;
-
- if (! elf_aarch64_locals (abfd))
- return GOT_UNKNOWN;
-
- return elf_aarch64_locals (abfd)[r_symndx].got_type;
-}
-
-/* Get the AArch64 elf linker hash table from a link_info structure. */
-#define elf_aarch64_hash_table(info) \
- ((struct elf_aarch64_link_hash_table *) ((info)->hash))
-
-#define aarch64_stub_hash_lookup(table, string, create, copy) \
- ((struct elf_aarch64_stub_hash_entry *) \
- bfd_hash_lookup ((table), (string), (create), (copy)))
-
-/* AArch64 ELF linker hash table. */
-struct elf_aarch64_link_hash_table
-{
- /* The main hash table. */
- struct elf_link_hash_table root;
-
- /* Nonzero to force PIC branch veneers. */
- int pic_veneer;
-
- /* Fix erratum 835769. */
- int fix_erratum_835769;
-
- /* Fix erratum 843419. */
- erratum_84319_opts fix_erratum_843419;
-
- /* Don't apply link-time values for dynamic relocations. */
- int no_apply_dynamic_relocs;
-
- /* The number of bytes in the initial entry in the PLT. */
- bfd_size_type plt_header_size;
-
- /* The bytes of the initial PLT entry. */
- const bfd_byte *plt0_entry;
-
- /* The number of bytes in the subsequent PLT entries. */
- bfd_size_type plt_entry_size;
-
- /* The bytes of the subsequent PLT entry. */
- const bfd_byte *plt_entry;
-
- /* For convenience in allocate_dynrelocs. */
- bfd *obfd;
-
- /* The amount of space used by the reserved portion of the sgotplt
- section, plus whatever space is used by the jump slots. */
- bfd_vma sgotplt_jump_table_size;
-
- /* The stub hash table. */
- struct bfd_hash_table stub_hash_table;
-
- /* Linker stub bfd. */
- bfd *stub_bfd;
-
- /* Linker call-backs. */
- asection *(*add_stub_section) (const char *, asection *);
- void (*layout_sections_again) (void);
-
- /* Array to keep track of which stub sections have been created, and
- information on stub grouping. */
- struct map_stub
- {
- /* This is the section to which stubs in the group will be
- attached. */
- asection *link_sec;
- /* The stub section. */
- asection *stub_sec;
- } *stub_group;
-
- /* Assorted information used by elfNN_aarch64_size_stubs. */
- unsigned int bfd_count;
- unsigned int top_index;
- asection **input_list;
-
- /* True when two stubs are added where one targets the other, happens
- when BTI stubs are inserted and then the stub layout must not change
- during elfNN_aarch64_build_stubs. */
- bool has_double_stub;
-
- /* JUMP_SLOT relocs for variant PCS symbols may be present. */
- int variant_pcs;
-
- /* The number of bytes in the PLT enty for the TLS descriptor. */
- bfd_size_type tlsdesc_plt_entry_size;
-
- /* Used by local STT_GNU_IFUNC symbols. */
- htab_t loc_hash_table;
- void * loc_hash_memory;
-
- /* Array of relative relocs to be emitted in DT_RELR format. */
- bfd_size_type relr_alloc;
- bfd_size_type relr_count;
- struct relr_entry
- {
- asection *sec;
- bfd_vma off;
- } *relr;
- /* Sorted output addresses of above relative relocs. */
- bfd_vma *relr_sorted;
- /* Layout recomputation count. */
- bfd_size_type relr_layout_iter;
-};
-
-/* Create an entry in an AArch64 ELF linker hash table. */
-
-static struct bfd_hash_entry *
-elfNN_aarch64_link_hash_newfunc (struct bfd_hash_entry *entry,
- struct bfd_hash_table *table,
- const char *string)
-{
- struct elf_aarch64_link_hash_entry *ret =
- (struct elf_aarch64_link_hash_entry *) entry;
-
- /* Allocate the structure if it has not already been allocated by a
- subclass. */
- if (ret == NULL)
- ret = bfd_hash_allocate (table,
- sizeof (struct elf_aarch64_link_hash_entry));
- if (ret == NULL)
- return (struct bfd_hash_entry *) ret;
-
- /* Call the allocation method of the superclass. */
- ret = ((struct elf_aarch64_link_hash_entry *)
- _bfd_elf_link_hash_newfunc ((struct bfd_hash_entry *) ret,
- table, string));
- if (ret != NULL)
- {
- ret->got_type = GOT_UNKNOWN;
- ret->def_protected = 0;
- ret->plt_got_offset = (bfd_vma) - 1;
- ret->stub_cache = NULL;
- ret->tlsdesc_got_jump_table_offset = (bfd_vma) - 1;
- }
-
- return (struct bfd_hash_entry *) ret;
-}
-
-/* Initialize an entry in the stub hash table. */
-
-static struct bfd_hash_entry *
-stub_hash_newfunc (struct bfd_hash_entry *entry,
- struct bfd_hash_table *table, const char *string)
-{
- /* Allocate the structure if it has not already been allocated by a
- subclass. */
- if (entry == NULL)
- {
- entry = bfd_hash_allocate (table,
- sizeof (struct
- elf_aarch64_stub_hash_entry));
- if (entry == NULL)
- return entry;
- }
-
- /* Call the allocation method of the superclass. */
- entry = bfd_hash_newfunc (entry, table, string);
- if (entry != NULL)
- {
- struct elf_aarch64_stub_hash_entry *eh;
-
- /* Initialize the local fields. */
- eh = (struct elf_aarch64_stub_hash_entry *) entry;
- memset (&eh->stub_sec, 0,
- (sizeof (struct elf_aarch64_stub_hash_entry)
- - offsetof (struct elf_aarch64_stub_hash_entry, stub_sec)));
- }
-
- return entry;
-}
-
-/* Compute a hash of a local hash entry. We use elf_link_hash_entry
- for local symbol so that we can handle local STT_GNU_IFUNC symbols
- as global symbol. We reuse indx and dynstr_index for local symbol
- hash since they aren't used by global symbols in this backend. */
-
-static hashval_t
-elfNN_aarch64_local_htab_hash (const void *ptr)
-{
- struct elf_link_hash_entry *h
- = (struct elf_link_hash_entry *) ptr;
- return ELF_LOCAL_SYMBOL_HASH (h->indx, h->dynstr_index);
-}
-
-/* Compare local hash entries. */
-
-static int
-elfNN_aarch64_local_htab_eq (const void *ptr1, const void *ptr2)
-{
- struct elf_link_hash_entry *h1
- = (struct elf_link_hash_entry *) ptr1;
- struct elf_link_hash_entry *h2
- = (struct elf_link_hash_entry *) ptr2;
-
- return h1->indx == h2->indx && h1->dynstr_index == h2->dynstr_index;
-}
-
-/* Find and/or create a hash entry for local symbol. */
-
-static struct elf_link_hash_entry *
-elfNN_aarch64_get_local_sym_hash (struct elf_aarch64_link_hash_table *htab,
- bfd *abfd, const Elf_Internal_Rela *rel,
- bool create)
-{
- struct elf_aarch64_link_hash_entry e, *ret;
- asection *sec = abfd->sections;
- hashval_t h = ELF_LOCAL_SYMBOL_HASH (sec->id,
- ELFNN_R_SYM (rel->r_info));
- void **slot;
-
- e.root.indx = sec->id;
- e.root.dynstr_index = ELFNN_R_SYM (rel->r_info);
- slot = htab_find_slot_with_hash (htab->loc_hash_table, &e, h,
- create ? INSERT : NO_INSERT);
-
- if (!slot)
- return NULL;
-
- if (*slot)
- {
- ret = (struct elf_aarch64_link_hash_entry *) *slot;
- return &ret->root;
- }
-
- ret = (struct elf_aarch64_link_hash_entry *)
- objalloc_alloc ((struct objalloc *) htab->loc_hash_memory,
- sizeof (struct elf_aarch64_link_hash_entry));
- if (ret)
- {
- memset (ret, 0, sizeof (*ret));
- ret->root.indx = sec->id;
- ret->root.dynstr_index = ELFNN_R_SYM (rel->r_info);
- ret->root.dynindx = -1;
- *slot = ret;
- }
- return &ret->root;
-}
-
-/* Copy the extra info we tack onto an elf_link_hash_entry. */
-
-static void
-elfNN_aarch64_copy_indirect_symbol (struct bfd_link_info *info,
- struct elf_link_hash_entry *dir,
- struct elf_link_hash_entry *ind)
-{
- struct elf_aarch64_link_hash_entry *edir, *eind;
-
- edir = (struct elf_aarch64_link_hash_entry *) dir;
- eind = (struct elf_aarch64_link_hash_entry *) ind;
-
- if (ind->root.type == bfd_link_hash_indirect)
- {
- /* Copy over PLT info. */
- if (dir->got.refcount <= 0)
- {
- edir->got_type = eind->got_type;
- eind->got_type = GOT_UNKNOWN;
- }
- }
-
- _bfd_elf_link_hash_copy_indirect (info, dir, ind);
-}
-
-/* Merge non-visibility st_other attributes. */
-
-static void
-elfNN_aarch64_merge_symbol_attribute (struct elf_link_hash_entry *h,
- unsigned int st_other,
- bool definition,
- bool dynamic ATTRIBUTE_UNUSED)
-{
- if (definition)
- {
- struct elf_aarch64_link_hash_entry *eh
- = (struct elf_aarch64_link_hash_entry *)h;
- eh->def_protected = ELF_ST_VISIBILITY (st_other) == STV_PROTECTED;
- }
-
- unsigned int isym_sto = st_other & ~ELF_ST_VISIBILITY (-1);
- unsigned int h_sto = h->other & ~ELF_ST_VISIBILITY (-1);
-
- if (isym_sto == h_sto)
- return;
-
- if (isym_sto & ~STO_AARCH64_VARIANT_PCS)
- /* Not fatal, this callback cannot fail. */
- _bfd_error_handler (_("unknown attribute for symbol `%s': 0x%02x"),
- h->root.root.string, isym_sto);
-
- /* Note: Ideally we would warn about any attribute mismatch, but
- this api does not allow that without substantial changes. */
- if (isym_sto & STO_AARCH64_VARIANT_PCS)
- h->other |= STO_AARCH64_VARIANT_PCS;
-}
-
-/* Destroy an AArch64 elf linker hash table. */
-
-static void
-elfNN_aarch64_link_hash_table_free (bfd *obfd)
-{
- struct elf_aarch64_link_hash_table *ret
- = (struct elf_aarch64_link_hash_table *) obfd->link.hash;
-
- if (ret->loc_hash_table)
- htab_delete (ret->loc_hash_table);
- if (ret->loc_hash_memory)
- objalloc_free ((struct objalloc *) ret->loc_hash_memory);
-
- bfd_hash_table_free (&ret->stub_hash_table);
- _bfd_elf_link_hash_table_free (obfd);
-}
-
-/* Create an AArch64 elf linker hash table. */
-
-static struct bfd_link_hash_table *
-elfNN_aarch64_link_hash_table_create (bfd *abfd)
-{
- struct elf_aarch64_link_hash_table *ret;
- size_t amt = sizeof (struct elf_aarch64_link_hash_table);
-
- ret = bfd_zmalloc (amt);
- if (ret == NULL)
- return NULL;
-
- if (!_bfd_elf_link_hash_table_init
- (&ret->root, abfd, elfNN_aarch64_link_hash_newfunc,
- sizeof (struct elf_aarch64_link_hash_entry), AARCH64_ELF_DATA))
- {
- free (ret);
- return NULL;
- }
-
- ret->plt_header_size = PLT_ENTRY_SIZE;
- ret->plt0_entry = elfNN_aarch64_small_plt0_entry;
- ret->plt_entry_size = PLT_SMALL_ENTRY_SIZE;
- ret->plt_entry = elfNN_aarch64_small_plt_entry;
- ret->tlsdesc_plt_entry_size = PLT_TLSDESC_ENTRY_SIZE;
- ret->obfd = abfd;
- ret->root.tlsdesc_got = (bfd_vma) - 1;
-
- if (!bfd_hash_table_init (&ret->stub_hash_table, stub_hash_newfunc,
- sizeof (struct elf_aarch64_stub_hash_entry)))
- {
- _bfd_elf_link_hash_table_free (abfd);
- return NULL;
- }
-
- ret->loc_hash_table = htab_try_create (1024,
- elfNN_aarch64_local_htab_hash,
- elfNN_aarch64_local_htab_eq,
- NULL);
- ret->loc_hash_memory = objalloc_create ();
- if (!ret->loc_hash_table || !ret->loc_hash_memory)
- {
- elfNN_aarch64_link_hash_table_free (abfd);
- return NULL;
- }
- ret->root.root.hash_table_free = elfNN_aarch64_link_hash_table_free;
-
- return &ret->root.root;
-}
-
-/* Perform relocation R_TYPE. Returns TRUE upon success, FALSE otherwise. */
-
-static bool
-aarch64_relocate (unsigned int r_type, bfd *input_bfd, asection *input_section,
- bfd_vma offset, bfd_vma value)
-{
- reloc_howto_type *howto;
- bfd_vma place;
-
- howto = elfNN_aarch64_howto_from_type (input_bfd, r_type);
- place = (input_section->output_section->vma + input_section->output_offset
- + offset);
-
- r_type = elfNN_aarch64_bfd_reloc_from_type (input_bfd, r_type);
- value = _bfd_aarch64_elf_resolve_relocation (input_bfd, r_type, place,
- value, 0, false);
- return _bfd_aarch64_elf_put_addend (input_bfd,
- input_section->contents + offset, r_type,
- howto, value) == bfd_reloc_ok;
-}
-
-/* Determine the type of stub needed, if any, for a call. */
-
-static enum elf_aarch64_stub_type
-aarch64_type_of_stub (asection *input_sec,
- const Elf_Internal_Rela *rel,
- asection *sym_sec,
- unsigned char st_type,
- bfd_vma destination)
-{
- bfd_vma location;
- bfd_signed_vma branch_offset;
- unsigned int r_type;
- enum elf_aarch64_stub_type stub_type = aarch64_stub_none;
-
- if (st_type != STT_FUNC
- && (sym_sec == input_sec))
- return stub_type;
-
- /* Determine where the call point is. */
- location = (input_sec->output_offset
- + input_sec->output_section->vma + rel->r_offset);
-
- branch_offset = (bfd_signed_vma) (destination - location);
-
- r_type = ELFNN_R_TYPE (rel->r_info);
-
- /* We don't want to redirect any old unconditional jump in this way,
- only one which is being used for a sibcall, where it is
- acceptable for the IP0 and IP1 registers to be clobbered. */
- if ((r_type == AARCH64_R (CALL26) || r_type == AARCH64_R (JUMP26))
- && (branch_offset > AARCH64_MAX_FWD_BRANCH_OFFSET
- || branch_offset < AARCH64_MAX_BWD_BRANCH_OFFSET))
- {
- stub_type = aarch64_stub_long_branch;
- }
-
- return stub_type;
-}
-
-/* Build a name for an entry in the stub hash table. */
-
-static char *
-elfNN_aarch64_stub_name (const asection *input_section,
- const asection *sym_sec,
- const struct elf_aarch64_link_hash_entry *hash,
- const Elf_Internal_Rela *rel)
-{
- char *stub_name;
- bfd_size_type len;
-
- if (hash)
- {
- len = 8 + 1 + strlen (hash->root.root.root.string) + 1 + 16 + 1;
- stub_name = bfd_malloc (len);
- if (stub_name != NULL)
- snprintf (stub_name, len, "%08x_%s+%" PRIx64,
- (unsigned int) input_section->id,
- hash->root.root.root.string,
- (uint64_t) rel->r_addend);
- }
- else
- {
- len = 8 + 1 + 8 + 1 + 8 + 1 + 16 + 1;
- stub_name = bfd_malloc (len);
- if (stub_name != NULL)
- snprintf (stub_name, len, "%08x_%x:%x+%" PRIx64,
- (unsigned int) input_section->id,
- (unsigned int) sym_sec->id,
- (unsigned int) ELFNN_R_SYM (rel->r_info),
- (uint64_t) rel->r_addend);
- }
-
- return stub_name;
-}
-
-/* Return TRUE if symbol H should be hashed in the `.gnu.hash' section. For
- executable PLT slots where the executable never takes the address of those
- functions, the function symbols are not added to the hash table. */
-
-static bool
-elf_aarch64_hash_symbol (struct elf_link_hash_entry *h)
-{
- if (h->plt.offset != (bfd_vma) -1
- && !h->def_regular
- && !h->pointer_equality_needed)
- return false;
-
- return _bfd_elf_hash_symbol (h);
-}
-
-
-/* Look up an entry in the stub hash. Stub entries are cached because
- creating the stub name takes a bit of time. */
-
-static struct elf_aarch64_stub_hash_entry *
-elfNN_aarch64_get_stub_entry (const asection *input_section,
- const asection *sym_sec,
- struct elf_link_hash_entry *hash,
- const Elf_Internal_Rela *rel,
- struct elf_aarch64_link_hash_table *htab)
-{
- struct elf_aarch64_stub_hash_entry *stub_entry;
- struct elf_aarch64_link_hash_entry *h =
- (struct elf_aarch64_link_hash_entry *) hash;
- const asection *id_sec;
-
- if ((input_section->flags & SEC_CODE) == 0)
- return NULL;
-
- /* If this input section is part of a group of sections sharing one
- stub section, then use the id of the first section in the group.
- Stub names need to include a section id, as there may well be
- more than one stub used to reach say, printf, and we need to
- distinguish between them. */
- id_sec = htab->stub_group[input_section->id].link_sec;
-
- if (h != NULL && h->stub_cache != NULL
- && h->stub_cache->h == h && h->stub_cache->id_sec == id_sec)
- {
- stub_entry = h->stub_cache;
- }
- else
- {
- char *stub_name;
-
- stub_name = elfNN_aarch64_stub_name (id_sec, sym_sec, h, rel);
- if (stub_name == NULL)
- return NULL;
-
- stub_entry = aarch64_stub_hash_lookup (&htab->stub_hash_table,
- stub_name, false, false);
- if (h != NULL)
- h->stub_cache = stub_entry;
-
- free (stub_name);
- }
-
- return stub_entry;
-}
-
-
-/* Create a stub section. */
-
-static asection *
-_bfd_aarch64_create_stub_section (asection *section,
- struct elf_aarch64_link_hash_table *htab)
-{
- size_t namelen;
- bfd_size_type len;
- char *s_name;
-
- namelen = strlen (section->name);
- len = namelen + sizeof (STUB_SUFFIX);
- s_name = bfd_alloc (htab->stub_bfd, len);
- if (s_name == NULL)
- return NULL;
-
- memcpy (s_name, section->name, namelen);
- memcpy (s_name + namelen, STUB_SUFFIX, sizeof (STUB_SUFFIX));
- return (*htab->add_stub_section) (s_name, section);
-}
-
-
-/* Find or create a stub section for a link section.
-
- Fix or create the stub section used to collect stubs attached to
- the specified link section. */
-
-static asection *
-_bfd_aarch64_get_stub_for_link_section (asection *link_section,
- struct elf_aarch64_link_hash_table *htab)
-{
- if (htab->stub_group[link_section->id].stub_sec == NULL)
- htab->stub_group[link_section->id].stub_sec
- = _bfd_aarch64_create_stub_section (link_section, htab);
- return htab->stub_group[link_section->id].stub_sec;
-}
-
-
-/* Find or create a stub section in the stub group for an input
- section. */
-
-static asection *
-_bfd_aarch64_create_or_find_stub_sec (asection *section,
- struct elf_aarch64_link_hash_table *htab)
-{
- asection *link_sec = htab->stub_group[section->id].link_sec;
- return _bfd_aarch64_get_stub_for_link_section (link_sec, htab);
-}
-
-
-/* Add a new stub entry in the stub group associated with an input
- section to the stub hash. Not all fields of the new stub entry are
- initialised. */
-
-static struct elf_aarch64_stub_hash_entry *
-_bfd_aarch64_add_stub_entry_in_group (const char *stub_name,
- asection *section,
- struct elf_aarch64_link_hash_table *htab)
-{
- asection *link_sec;
- asection *stub_sec;
- struct elf_aarch64_stub_hash_entry *stub_entry;
-
- link_sec = htab->stub_group[section->id].link_sec;
- stub_sec = _bfd_aarch64_create_or_find_stub_sec (section, htab);
-
- /* Enter this entry into the linker stub hash table. */
- stub_entry = aarch64_stub_hash_lookup (&htab->stub_hash_table, stub_name,
- true, false);
- if (stub_entry == NULL)
- {
- /* xgettext:c-format */
- _bfd_error_handler (_("%pB: cannot create stub entry %s"),
- section->owner, stub_name);
- return NULL;
- }
-
- stub_entry->stub_sec = stub_sec;
- stub_entry->stub_offset = 0;
- stub_entry->id_sec = link_sec;
-
- return stub_entry;
-}
-
-/* Add a new stub entry in the final stub section to the stub hash.
- Not all fields of the new stub entry are initialised. */
-
-static struct elf_aarch64_stub_hash_entry *
-_bfd_aarch64_add_stub_entry_after (const char *stub_name,
- asection *link_section,
- struct elf_aarch64_link_hash_table *htab)
-{
- asection *stub_sec;
- struct elf_aarch64_stub_hash_entry *stub_entry;
-
- stub_sec = NULL;
- /* Only create the actual stub if we will end up needing it. */
- if (htab->fix_erratum_843419 & ERRAT_ADRP)
- stub_sec = _bfd_aarch64_get_stub_for_link_section (link_section, htab);
- stub_entry = aarch64_stub_hash_lookup (&htab->stub_hash_table, stub_name,
- true, false);
- if (stub_entry == NULL)
- {
- _bfd_error_handler (_("cannot create stub entry %s"), stub_name);
- return NULL;
- }
-
- stub_entry->stub_sec = stub_sec;
- stub_entry->stub_offset = 0;
- stub_entry->id_sec = link_section;
-
- return stub_entry;
-}
-
-
-static bool
-aarch64_build_one_stub (struct bfd_hash_entry *gen_entry,
- void *in_arg)
-{
- struct elf_aarch64_stub_hash_entry *stub_entry;
- asection *stub_sec;
- bfd *stub_bfd;
- bfd_byte *loc;
- bfd_vma sym_value;
- bfd_vma veneered_insn_loc;
- bfd_vma veneer_entry_loc;
- bfd_signed_vma branch_offset = 0;
- unsigned int template_size;
- unsigned int pad_size = 0;
- const uint32_t *template;
- unsigned int i;
- struct bfd_link_info *info;
- struct elf_aarch64_link_hash_table *htab;
-
- /* Massage our args to the form they really have. */
- stub_entry = (struct elf_aarch64_stub_hash_entry *) gen_entry;
-
- info = (struct bfd_link_info *) in_arg;
- htab = elf_aarch64_hash_table (info);
-
- /* Fail if the target section could not be assigned to an output
- section. The user should fix his linker script. */
- if (stub_entry->target_section->output_section == NULL
- && info->non_contiguous_regions)
- info->callbacks->einfo (_("%F%P: Could not assign `%pA' to an output section. "
- "Retry without "
- "--enable-non-contiguous-regions.\n"),
- stub_entry->target_section);
-
- stub_sec = stub_entry->stub_sec;
-
- /* The layout must not change when a stub may be the target of another. */
- if (htab->has_double_stub)
- BFD_ASSERT (stub_entry->stub_offset == stub_sec->size);
-
- /* Make a note of the offset within the stubs for this entry. */
- stub_entry->stub_offset = stub_sec->size;
- loc = stub_sec->contents + stub_entry->stub_offset;
-
- stub_bfd = stub_sec->owner;
-
- /* This is the address of the stub destination. */
- sym_value = (stub_entry->target_value
- + stub_entry->target_section->output_offset
- + stub_entry->target_section->output_section->vma);
-
- if (stub_entry->stub_type == aarch64_stub_long_branch)
- {
- bfd_vma place = (stub_entry->stub_offset + stub_sec->output_section->vma
- + stub_sec->output_offset);
-
- /* See if we can relax the stub. */
- if (aarch64_valid_for_adrp_p (sym_value, place))
- {
- stub_entry->stub_type = aarch64_stub_adrp_branch;
-
- /* Avoid the relaxation changing the layout. */
- if (htab->has_double_stub)
- pad_size = sizeof (aarch64_long_branch_stub)
- - sizeof (aarch64_adrp_branch_stub);
- }
- }
-
- switch (stub_entry->stub_type)
- {
- case aarch64_stub_adrp_branch:
- template = aarch64_adrp_branch_stub;
- template_size = sizeof (aarch64_adrp_branch_stub);
- break;
- case aarch64_stub_long_branch:
- template = aarch64_long_branch_stub;
- template_size = sizeof (aarch64_long_branch_stub);
- break;
- case aarch64_stub_bti_direct_branch:
- template = aarch64_bti_direct_branch_stub;
- template_size = sizeof (aarch64_bti_direct_branch_stub);
- break;
- case aarch64_stub_erratum_835769_veneer:
- template = aarch64_erratum_835769_stub;
- template_size = sizeof (aarch64_erratum_835769_stub);
- break;
- case aarch64_stub_erratum_843419_veneer:
- template = aarch64_erratum_843419_stub;
- template_size = sizeof (aarch64_erratum_843419_stub);
- break;
- default:
- abort ();
- }
-
- for (i = 0; i < (template_size / sizeof template[0]); i++)
- {
- bfd_putl32 (template[i], loc);
- loc += 4;
- }
-
- template_size += pad_size;
- template_size = (template_size + 7) & ~7;
- stub_sec->size += template_size;
-
- switch (stub_entry->stub_type)
- {
- case aarch64_stub_adrp_branch:
- if (!aarch64_relocate (AARCH64_R (ADR_PREL_PG_HI21), stub_bfd, stub_sec,
- stub_entry->stub_offset, sym_value))
- /* The stub would not have been relaxed if the offset was out
- of range. */
- BFD_FAIL ();
-
- if (!aarch64_relocate (AARCH64_R (ADD_ABS_LO12_NC), stub_bfd, stub_sec,
- stub_entry->stub_offset + 4, sym_value))
- BFD_FAIL ();
- break;
-
- case aarch64_stub_long_branch:
- /* We want the value relative to the address 12 bytes back from the
- value itself. */
- if (!aarch64_relocate (AARCH64_R (PRELNN), stub_bfd, stub_sec,
- stub_entry->stub_offset + 16, sym_value + 12))
- BFD_FAIL ();
- break;
-
- case aarch64_stub_bti_direct_branch:
- if (!aarch64_relocate (AARCH64_R (JUMP26), stub_bfd, stub_sec,
- stub_entry->stub_offset + 4, sym_value))
- BFD_FAIL ();
- break;
-
- case aarch64_stub_erratum_835769_veneer:
- veneered_insn_loc = stub_entry->target_section->output_section->vma
- + stub_entry->target_section->output_offset
- + stub_entry->target_value;
- veneer_entry_loc = stub_entry->stub_sec->output_section->vma
- + stub_entry->stub_sec->output_offset
- + stub_entry->stub_offset;
- branch_offset = veneered_insn_loc - veneer_entry_loc;
- branch_offset >>= 2;
- branch_offset &= 0x3ffffff;
- bfd_putl32 (stub_entry->veneered_insn,
- stub_sec->contents + stub_entry->stub_offset);
- bfd_putl32 (template[1] | branch_offset,
- stub_sec->contents + stub_entry->stub_offset + 4);
- break;
-
- case aarch64_stub_erratum_843419_veneer:
- if (!aarch64_relocate (AARCH64_R (JUMP26), stub_bfd, stub_sec,
- stub_entry->stub_offset + 4, sym_value + 4))
- BFD_FAIL ();
- break;
-
- default:
- abort ();
- }
-
- return true;
-}
-
-/* As above, but don't actually build the stub. Just bump offset so
- we know stub section sizes and record the offset for each stub so
- a stub can target another stub (needed for BTI direct branch stub). */
-
-static bool
-aarch64_size_one_stub (struct bfd_hash_entry *gen_entry, void *in_arg)
-{
- struct elf_aarch64_stub_hash_entry *stub_entry;
- struct elf_aarch64_link_hash_table *htab;
- int size;
-
- /* Massage our args to the form they really have. */
- stub_entry = (struct elf_aarch64_stub_hash_entry *) gen_entry;
- htab = (struct elf_aarch64_link_hash_table *) in_arg;
-
- switch (stub_entry->stub_type)
- {
- case aarch64_stub_adrp_branch:
- size = sizeof (aarch64_adrp_branch_stub);
- break;
- case aarch64_stub_long_branch:
- size = sizeof (aarch64_long_branch_stub);
- break;
- case aarch64_stub_bti_direct_branch:
- size = sizeof (aarch64_bti_direct_branch_stub);
- break;
- case aarch64_stub_erratum_835769_veneer:
- size = sizeof (aarch64_erratum_835769_stub);
- break;
- case aarch64_stub_erratum_843419_veneer:
- {
- if (htab->fix_erratum_843419 == ERRAT_ADR)
- return true;
- size = sizeof (aarch64_erratum_843419_stub);
- }
- break;
- default:
- abort ();
- }
-
- size = (size + 7) & ~7;
- stub_entry->stub_offset = stub_entry->stub_sec->size;
- stub_entry->stub_sec->size += size;
- return true;
-}
-
-/* Output is BTI compatible. */
-
-static bool
-elf_aarch64_bti_p (bfd *output_bfd)
-{
- uint32_t prop = elf_aarch64_tdata (output_bfd)->gnu_and_prop;
- return prop & GNU_PROPERTY_AARCH64_FEATURE_1_BTI;
-}
-
-/* External entry points for sizing and building linker stubs. */
-
-/* Set up various things so that we can make a list of input sections
- for each output section included in the link. Returns -1 on error,
- 0 when no stubs will be needed, and 1 on success. */
-
-int
-elfNN_aarch64_setup_section_lists (bfd *output_bfd,
- struct bfd_link_info *info)
-{
- bfd *input_bfd;
- unsigned int bfd_count;
- unsigned int top_id, top_index;
- asection *section;
- asection **input_list, **list;
- size_t amt;
- struct elf_aarch64_link_hash_table *htab =
- elf_aarch64_hash_table (info);
-
- if (!is_elf_hash_table (&htab->root.root))
- return 0;
-
- /* Count the number of input BFDs and find the top input section id. */
- for (input_bfd = info->input_bfds, bfd_count = 0, top_id = 0;
- input_bfd != NULL; input_bfd = input_bfd->link.next)
- {
- bfd_count += 1;
- for (section = input_bfd->sections;
- section != NULL; section = section->next)
- {
- if (top_id < section->id)
- top_id = section->id;
- }
- }
- htab->bfd_count = bfd_count;
-
- amt = sizeof (struct map_stub) * (top_id + 1);
- htab->stub_group = bfd_zmalloc (amt);
- if (htab->stub_group == NULL)
- return -1;
-
- /* We can't use output_bfd->section_count here to find the top output
- section index as some sections may have been removed, and
- _bfd_strip_section_from_output doesn't renumber the indices. */
- for (section = output_bfd->sections, top_index = 0;
- section != NULL; section = section->next)
- {
- if (top_index < section->index)
- top_index = section->index;
- }
-
- htab->top_index = top_index;
- amt = sizeof (asection *) * (top_index + 1);
- input_list = bfd_malloc (amt);
- htab->input_list = input_list;
- if (input_list == NULL)
- return -1;
-
- /* For sections we aren't interested in, mark their entries with a
- value we can check later. */
- list = input_list + top_index;
- do
- *list = bfd_abs_section_ptr;
- while (list-- != input_list);
-
- for (section = output_bfd->sections;
- section != NULL; section = section->next)
- {
- if ((section->flags & SEC_CODE) != 0)
- input_list[section->index] = NULL;
- }
-
- return 1;
-}
-
-/* Used by elfNN_aarch64_next_input_section and group_sections. */
-#define PREV_SEC(sec) (htab->stub_group[(sec)->id].link_sec)
-
-/* The linker repeatedly calls this function for each input section,
- in the order that input sections are linked into output sections.
- Build lists of input sections to determine groupings between which
- we may insert linker stubs. */
-
-void
-elfNN_aarch64_next_input_section (struct bfd_link_info *info, asection *isec)
-{
- struct elf_aarch64_link_hash_table *htab =
- elf_aarch64_hash_table (info);
-
- if (isec->output_section->index <= htab->top_index)
- {
- asection **list = htab->input_list + isec->output_section->index;
-
- if (*list != bfd_abs_section_ptr && (isec->flags & SEC_CODE) != 0)
- {
- /* Steal the link_sec pointer for our list. */
- /* This happens to make the list in reverse order,
- which is what we want. */
- PREV_SEC (isec) = *list;
- *list = isec;
- }
- }
-}
-
-/* See whether we can group stub sections together. Grouping stub
- sections may result in fewer stubs. More importantly, we need to
- put all .init* and .fini* stubs at the beginning of the .init or
- .fini output sections respectively, because glibc splits the
- _init and _fini functions into multiple parts. Putting a stub in
- the middle of a function is not a good idea. */
-
-static void
-group_sections (struct elf_aarch64_link_hash_table *htab,
- bfd_size_type stub_group_size,
- bool stubs_always_after_branch)
-{
- asection **list = htab->input_list;
-
- do
- {
- asection *tail = *list;
- asection *head;
-
- if (tail == bfd_abs_section_ptr)
- continue;
-
- /* Reverse the list: we must avoid placing stubs at the
- beginning of the section because the beginning of the text
- section may be required for an interrupt vector in bare metal
- code. */
-#define NEXT_SEC PREV_SEC
- head = NULL;
- while (tail != NULL)
- {
- /* Pop from tail. */
- asection *item = tail;
- tail = PREV_SEC (item);
-
- /* Push on head. */
- NEXT_SEC (item) = head;
- head = item;
- }
-
- while (head != NULL)
- {
- asection *curr;
- asection *next;
- bfd_vma stub_group_start = head->output_offset;
- bfd_vma end_of_next;
-
- curr = head;
- while (NEXT_SEC (curr) != NULL)
- {
- next = NEXT_SEC (curr);
- end_of_next = next->output_offset + next->size;
- if (end_of_next - stub_group_start >= stub_group_size)
- /* End of NEXT is too far from start, so stop. */
- break;
- /* Add NEXT to the group. */
- curr = next;
- }
-
- /* OK, the size from the start to the start of CURR is less
- than stub_group_size and thus can be handled by one stub
- section. (Or the head section is itself larger than
- stub_group_size, in which case we may be toast.)
- We should really be keeping track of the total size of
- stubs added here, as stubs contribute to the final output
- section size. */
- do
- {
- next = NEXT_SEC (head);
- /* Set up this stub group. */
- htab->stub_group[head->id].link_sec = curr;
- }
- while (head != curr && (head = next) != NULL);
-
- /* But wait, there's more! Input sections up to stub_group_size
- bytes after the stub section can be handled by it too. */
- if (!stubs_always_after_branch)
- {
- stub_group_start = curr->output_offset + curr->size;
-
- while (next != NULL)
- {
- end_of_next = next->output_offset + next->size;
- if (end_of_next - stub_group_start >= stub_group_size)
- /* End of NEXT is too far from stubs, so stop. */
- break;
- /* Add NEXT to the stub group. */
- head = next;
- next = NEXT_SEC (head);
- htab->stub_group[head->id].link_sec = curr;
- }
- }
- head = next;
- }
- }
- while (list++ != htab->input_list + htab->top_index);
-
- free (htab->input_list);
-}
-
-#undef PREV_SEC
-#undef PREV_SEC
-
-#define AARCH64_HINT(insn) (((insn) & 0xfffff01f) == 0xd503201f)
-#define AARCH64_PACIASP 0xd503233f
-#define AARCH64_PACIBSP 0xd503237f
-#define AARCH64_BTI_C 0xd503245f
-#define AARCH64_BTI_J 0xd503249f
-#define AARCH64_BTI_JC 0xd50324df
-
-/* True if the inserted stub does not break BTI compatibility. */
-
-static bool
-aarch64_bti_stub_p (struct bfd_link_info *info,
- struct elf_aarch64_stub_hash_entry *stub_entry)
-{
- /* Stubs without indirect branch are BTI compatible. */
- if (stub_entry->stub_type != aarch64_stub_adrp_branch
- && stub_entry->stub_type != aarch64_stub_long_branch)
- return true;
-
- /* Return true if the target instruction is compatible with BR x16. */
-
- struct elf_aarch64_link_hash_table *globals = elf_aarch64_hash_table (info);
- asection *section = stub_entry->target_section;
- bfd_byte loc[4];
- file_ptr off = stub_entry->target_value;
- bfd_size_type count = sizeof (loc);
-
- /* PLT code is not generated yet, so treat it specially.
- Note: Checking elf_aarch64_obj_tdata.plt_type & PLT_BTI is not
- enough because it only implies BTI in the PLT0 and tlsdesc PLT
- entries. Normal PLT entries don't have BTI in a shared library
- (because such PLT is normally not called indirectly and adding
- the BTI when a stub targets a PLT would change the PLT layout
- and it's too late for that here). */
- if (section == globals->root.splt)
- memcpy (loc, globals->plt_entry, count);
- else if (!bfd_get_section_contents (section->owner, section, loc, off, count))
- return false;
-
- uint32_t insn = bfd_getl32 (loc);
- if (!AARCH64_HINT (insn))
- return false;
- return insn == AARCH64_BTI_C
- || insn == AARCH64_PACIASP
- || insn == AARCH64_BTI_JC
- || insn == AARCH64_BTI_J
- || insn == AARCH64_PACIBSP;
-}
-
-#define AARCH64_BITS(x, pos, n) (((x) >> (pos)) & ((1 << (n)) - 1))
-
-#define AARCH64_RT(insn) AARCH64_BITS (insn, 0, 5)
-#define AARCH64_RT2(insn) AARCH64_BITS (insn, 10, 5)
-#define AARCH64_RA(insn) AARCH64_BITS (insn, 10, 5)
-#define AARCH64_RD(insn) AARCH64_BITS (insn, 0, 5)
-#define AARCH64_RN(insn) AARCH64_BITS (insn, 5, 5)
-#define AARCH64_RM(insn) AARCH64_BITS (insn, 16, 5)
-
-#define AARCH64_MAC(insn) (((insn) & 0xff000000) == 0x9b000000)
-#define AARCH64_BIT(insn, n) AARCH64_BITS (insn, n, 1)
-#define AARCH64_OP31(insn) AARCH64_BITS (insn, 21, 3)
-#define AARCH64_ZR 0x1f
-
-/* All ld/st ops. See C4-182 of the ARM ARM. The encoding space for
- LD_PCREL, LDST_RO, LDST_UI and LDST_UIMM cover prefetch ops. */
-
-#define AARCH64_LD(insn) (AARCH64_BIT (insn, 22) == 1)
-#define AARCH64_LDST(insn) (((insn) & 0x0a000000) == 0x08000000)
-#define AARCH64_LDST_EX(insn) (((insn) & 0x3f000000) == 0x08000000)
-#define AARCH64_LDST_PCREL(insn) (((insn) & 0x3b000000) == 0x18000000)
-#define AARCH64_LDST_NAP(insn) (((insn) & 0x3b800000) == 0x28000000)
-#define AARCH64_LDSTP_PI(insn) (((insn) & 0x3b800000) == 0x28800000)
-#define AARCH64_LDSTP_O(insn) (((insn) & 0x3b800000) == 0x29000000)
-#define AARCH64_LDSTP_PRE(insn) (((insn) & 0x3b800000) == 0x29800000)
-#define AARCH64_LDST_UI(insn) (((insn) & 0x3b200c00) == 0x38000000)
-#define AARCH64_LDST_PIIMM(insn) (((insn) & 0x3b200c00) == 0x38000400)
-#define AARCH64_LDST_U(insn) (((insn) & 0x3b200c00) == 0x38000800)
-#define AARCH64_LDST_PREIMM(insn) (((insn) & 0x3b200c00) == 0x38000c00)
-#define AARCH64_LDST_RO(insn) (((insn) & 0x3b200c00) == 0x38200800)
-#define AARCH64_LDST_UIMM(insn) (((insn) & 0x3b000000) == 0x39000000)
-#define AARCH64_LDST_SIMD_M(insn) (((insn) & 0xbfbf0000) == 0x0c000000)
-#define AARCH64_LDST_SIMD_M_PI(insn) (((insn) & 0xbfa00000) == 0x0c800000)
-#define AARCH64_LDST_SIMD_S(insn) (((insn) & 0xbf9f0000) == 0x0d000000)
-#define AARCH64_LDST_SIMD_S_PI(insn) (((insn) & 0xbf800000) == 0x0d800000)
-
-/* Classify an INSN if it is indeed a load/store.
-
- Return TRUE if INSN is a LD/ST instruction otherwise return FALSE.
-
- For scalar LD/ST instructions PAIR is FALSE, RT is returned and RT2
- is set equal to RT.
-
- For LD/ST pair instructions PAIR is TRUE, RT and RT2 are returned. */
-
-static bool
-aarch64_mem_op_p (uint32_t insn, unsigned int *rt, unsigned int *rt2,
- bool *pair, bool *load)
-{
- uint32_t opcode;
- unsigned int r;
- uint32_t opc = 0;
- uint32_t v = 0;
- uint32_t opc_v = 0;
-
- /* Bail out quickly if INSN doesn't fall into the load-store
- encoding space. */
- if (!AARCH64_LDST (insn))
- return false;
-
- *pair = false;
- *load = false;
- if (AARCH64_LDST_EX (insn))
- {
- *rt = AARCH64_RT (insn);
- *rt2 = *rt;
- if (AARCH64_BIT (insn, 21) == 1)
- {
- *pair = true;
- *rt2 = AARCH64_RT2 (insn);
- }
- *load = AARCH64_LD (insn);
- return true;
- }
- else if (AARCH64_LDST_NAP (insn)
- || AARCH64_LDSTP_PI (insn)
- || AARCH64_LDSTP_O (insn)
- || AARCH64_LDSTP_PRE (insn))
- {
- *pair = true;
- *rt = AARCH64_RT (insn);
- *rt2 = AARCH64_RT2 (insn);
- *load = AARCH64_LD (insn);
- return true;
- }
- else if (AARCH64_LDST_PCREL (insn)
- || AARCH64_LDST_UI (insn)
- || AARCH64_LDST_PIIMM (insn)
- || AARCH64_LDST_U (insn)
- || AARCH64_LDST_PREIMM (insn)
- || AARCH64_LDST_RO (insn)
- || AARCH64_LDST_UIMM (insn))
- {
- *rt = AARCH64_RT (insn);
- *rt2 = *rt;
- if (AARCH64_LDST_PCREL (insn))
- *load = true;
- opc = AARCH64_BITS (insn, 22, 2);
- v = AARCH64_BIT (insn, 26);
- opc_v = opc | (v << 2);
- *load = (opc_v == 1 || opc_v == 2 || opc_v == 3
- || opc_v == 5 || opc_v == 7);
- return true;
- }
- else if (AARCH64_LDST_SIMD_M (insn)
- || AARCH64_LDST_SIMD_M_PI (insn))
- {
- *rt = AARCH64_RT (insn);
- *load = AARCH64_BIT (insn, 22);
- opcode = (insn >> 12) & 0xf;
- switch (opcode)
- {
- case 0:
- case 2:
- *rt2 = *rt + 3;
- break;
-
- case 4:
- case 6:
- *rt2 = *rt + 2;
- break;
-
- case 7:
- *rt2 = *rt;
- break;
-
- case 8:
- case 10:
- *rt2 = *rt + 1;
- break;
-
- default:
- return false;
- }
- return true;
- }
- else if (AARCH64_LDST_SIMD_S (insn)
- || AARCH64_LDST_SIMD_S_PI (insn))
- {
- *rt = AARCH64_RT (insn);
- r = (insn >> 21) & 1;
- *load = AARCH64_BIT (insn, 22);
- opcode = (insn >> 13) & 0x7;
- switch (opcode)
- {
- case 0:
- case 2:
- case 4:
- *rt2 = *rt + r;
- break;
-
- case 1:
- case 3:
- case 5:
- *rt2 = *rt + (r == 0 ? 2 : 3);
- break;
-
- case 6:
- *rt2 = *rt + r;
- break;
-
- case 7:
- *rt2 = *rt + (r == 0 ? 2 : 3);
- break;
-
- default:
- return false;
- }
- return true;
- }
-
- return false;
-}
-
-/* Return TRUE if INSN is multiply-accumulate. */
-
-static bool
-aarch64_mlxl_p (uint32_t insn)
-{
- uint32_t op31 = AARCH64_OP31 (insn);
-
- if (AARCH64_MAC (insn)
- && (op31 == 0 || op31 == 1 || op31 == 5)
- /* Exclude MUL instructions which are encoded as a multiple accumulate
- with RA = XZR. */
- && AARCH64_RA (insn) != AARCH64_ZR)
- return true;
-
- return false;
-}
-
-/* Some early revisions of the Cortex-A53 have an erratum (835769) whereby
- it is possible for a 64-bit multiply-accumulate instruction to generate an
- incorrect result. The details are quite complex and hard to
- determine statically, since branches in the code may exist in some
- circumstances, but all cases end with a memory (load, store, or
- prefetch) instruction followed immediately by the multiply-accumulate
- operation. We employ a linker patching technique, by moving the potentially
- affected multiply-accumulate instruction into a patch region and replacing
- the original instruction with a branch to the patch. This function checks
- if INSN_1 is the memory operation followed by a multiply-accumulate
- operation (INSN_2). Return TRUE if an erratum sequence is found, FALSE
- if INSN_1 and INSN_2 are safe. */
-
-static bool
-aarch64_erratum_sequence (uint32_t insn_1, uint32_t insn_2)
-{
- uint32_t rt;
- uint32_t rt2;
- uint32_t rn;
- uint32_t rm;
- uint32_t ra;
- bool pair;
- bool load;
-
- if (aarch64_mlxl_p (insn_2)
- && aarch64_mem_op_p (insn_1, &rt, &rt2, &pair, &load))
- {
- /* Any SIMD memory op is independent of the subsequent MLA
- by definition of the erratum. */
- if (AARCH64_BIT (insn_1, 26))
- return true;
-
- /* If not SIMD, check for integer memory ops and MLA relationship. */
- rn = AARCH64_RN (insn_2);
- ra = AARCH64_RA (insn_2);
- rm = AARCH64_RM (insn_2);
-
- /* If this is a load and there's a true(RAW) dependency, we are safe
- and this is not an erratum sequence. */
- if (load &&
- (rt == rn || rt == rm || rt == ra
- || (pair && (rt2 == rn || rt2 == rm || rt2 == ra))))
- return false;
-
- /* We conservatively put out stubs for all other cases (including
- writebacks). */
- return true;
- }
-
- return false;
-}
-
-/* Used to order a list of mapping symbols by address. */
-
-static int
-elf_aarch64_compare_mapping (const void *a, const void *b)
-{
- const elf_aarch64_section_map *amap = (const elf_aarch64_section_map *) a;
- const elf_aarch64_section_map *bmap = (const elf_aarch64_section_map *) b;
-
- if (amap->vma > bmap->vma)
- return 1;
- else if (amap->vma < bmap->vma)
- return -1;
- else if (amap->type > bmap->type)
- /* Ensure results do not depend on the host qsort for objects with
- multiple mapping symbols at the same address by sorting on type
- after vma. */
- return 1;
- else if (amap->type < bmap->type)
- return -1;
- else
- return 0;
-}
-
-
-static char *
-_bfd_aarch64_erratum_835769_stub_name (unsigned num_fixes)
-{
- char *stub_name = (char *) bfd_malloc
- (strlen ("__erratum_835769_veneer_") + 16);
- if (stub_name != NULL)
- sprintf (stub_name,"__erratum_835769_veneer_%d", num_fixes);
- return stub_name;
-}
-
-/* Scan for Cortex-A53 erratum 835769 sequence.
-
- Return TRUE else FALSE on abnormal termination. */
-
-static bool
-_bfd_aarch64_erratum_835769_scan (bfd *input_bfd,
- struct bfd_link_info *info,
- unsigned int *num_fixes_p)
-{
- asection *section;
- struct elf_aarch64_link_hash_table *htab = elf_aarch64_hash_table (info);
- unsigned int num_fixes = *num_fixes_p;
-
- if (htab == NULL)
- return true;
-
- for (section = input_bfd->sections;
- section != NULL;
- section = section->next)
- {
- bfd_byte *contents = NULL;
- struct _aarch64_elf_section_data *sec_data;
- unsigned int span;
-
- if (elf_section_type (section) != SHT_PROGBITS
- || (elf_section_flags (section) & SHF_EXECINSTR) == 0
- || (section->flags & SEC_EXCLUDE) != 0
- || (section->sec_info_type == SEC_INFO_TYPE_JUST_SYMS)
- || (section->output_section == bfd_abs_section_ptr))
- continue;
-
- if (elf_section_data (section)->this_hdr.contents != NULL)
- contents = elf_section_data (section)->this_hdr.contents;
- else if (! bfd_malloc_and_get_section (input_bfd, section, &contents))
- return false;
-
- sec_data = elf_aarch64_section_data (section);
-
- if (sec_data->mapcount)
- qsort (sec_data->map, sec_data->mapcount,
- sizeof (elf_aarch64_section_map), elf_aarch64_compare_mapping);
-
- for (span = 0; span < sec_data->mapcount; span++)
- {
- unsigned int span_start = sec_data->map[span].vma;
- unsigned int span_end = ((span == sec_data->mapcount - 1)
- ? sec_data->map[0].vma + section->size
- : sec_data->map[span + 1].vma);
- unsigned int i;
- char span_type = sec_data->map[span].type;
-
- if (span_type == 'd')
- continue;
-
- for (i = span_start; i + 4 < span_end; i += 4)
- {
- uint32_t insn_1 = bfd_getl32 (contents + i);
- uint32_t insn_2 = bfd_getl32 (contents + i + 4);
-
- if (aarch64_erratum_sequence (insn_1, insn_2))
- {
- struct elf_aarch64_stub_hash_entry *stub_entry;
- char *stub_name = _bfd_aarch64_erratum_835769_stub_name (num_fixes);
- if (! stub_name)
- return false;
-
- stub_entry = _bfd_aarch64_add_stub_entry_in_group (stub_name,
- section,
- htab);
- if (! stub_entry)
- return false;
-
- stub_entry->stub_type = aarch64_stub_erratum_835769_veneer;
- stub_entry->target_section = section;
- stub_entry->target_value = i + 4;
- stub_entry->veneered_insn = insn_2;
- stub_entry->output_name = stub_name;
- num_fixes++;
- }
- }
- }
- if (elf_section_data (section)->this_hdr.contents == NULL)
- free (contents);
- }
-
- *num_fixes_p = num_fixes;
-
- return true;
-}
-
-
-/* Test if instruction INSN is ADRP. */
-
-static bool
-_bfd_aarch64_adrp_p (uint32_t insn)
-{
- return ((insn & AARCH64_ADRP_OP_MASK) == AARCH64_ADRP_OP);
-}
-
-
-/* Helper predicate to look for cortex-a53 erratum 843419 sequence 1. */
-
-static bool
-_bfd_aarch64_erratum_843419_sequence_p (uint32_t insn_1, uint32_t insn_2,
- uint32_t insn_3)
-{
- uint32_t rt;
- uint32_t rt2;
- bool pair;
- bool load;
-
- return (aarch64_mem_op_p (insn_2, &rt, &rt2, &pair, &load)
- && (!pair
- || (pair && !load))
- && AARCH64_LDST_UIMM (insn_3)
- && AARCH64_RN (insn_3) == AARCH64_RD (insn_1));
-}
-
-
-/* Test for the presence of Cortex-A53 erratum 843419 instruction sequence.
-
- Return TRUE if section CONTENTS at offset I contains one of the
- erratum 843419 sequences, otherwise return FALSE. If a sequence is
- seen set P_VENEER_I to the offset of the final LOAD/STORE
- instruction in the sequence.
- */
-
-static bool
-_bfd_aarch64_erratum_843419_p (bfd_byte *contents, bfd_vma vma,
- bfd_vma i, bfd_vma span_end,
- bfd_vma *p_veneer_i)
-{
- uint32_t insn_1 = bfd_getl32 (contents + i);
-
- if (!_bfd_aarch64_adrp_p (insn_1))
- return false;
-
- if (span_end < i + 12)
- return false;
-
- uint32_t insn_2 = bfd_getl32 (contents + i + 4);
- uint32_t insn_3 = bfd_getl32 (contents + i + 8);
-
- if ((vma & 0xfff) != 0xff8 && (vma & 0xfff) != 0xffc)
- return false;
-
- if (_bfd_aarch64_erratum_843419_sequence_p (insn_1, insn_2, insn_3))
- {
- *p_veneer_i = i + 8;
- return true;
- }
-
- if (span_end < i + 16)
- return false;
-
- uint32_t insn_4 = bfd_getl32 (contents + i + 12);
-
- if (_bfd_aarch64_erratum_843419_sequence_p (insn_1, insn_2, insn_4))
- {
- *p_veneer_i = i + 12;
- return true;
- }
-
- return false;
-}
-
-
-/* Resize all stub sections. */
-
-static void
-_bfd_aarch64_resize_stubs (struct elf_aarch64_link_hash_table *htab)
-{
- asection *section;
-
- /* OK, we've added some stubs. Find out the new size of the
- stub sections. */
- for (section = htab->stub_bfd->sections;
- section != NULL; section = section->next)
- {
- /* Ignore non-stub sections. */
- if (!strstr (section->name, STUB_SUFFIX))
- continue;
-
- /* Add space for a branch. Add 8 bytes to keep section 8 byte aligned,
- as long branch stubs contain a 64-bit address. */
- section->size = 8;
- }
-
- bfd_hash_traverse (&htab->stub_hash_table, aarch64_size_one_stub, htab);
-
- for (section = htab->stub_bfd->sections;
- section != NULL; section = section->next)
- {
- if (!strstr (section->name, STUB_SUFFIX))
- continue;
-
- /* Empty stub section. */
- if (section->size == 8)
- section->size = 0;
-
- /* Ensure all stub sections have a size which is a multiple of
- 4096. This is important in order to ensure that the insertion
- of stub sections does not in itself move existing code around
- in such a way that new errata sequences are created. We only do this
- when the ADRP workaround is enabled. If only the ADR workaround is
- enabled then the stubs workaround won't ever be used. */
- if (htab->fix_erratum_843419 & ERRAT_ADRP)
- if (section->size)
- section->size = BFD_ALIGN (section->size, 0x1000);
- }
-}
-
-/* Construct an erratum 843419 workaround stub name. */
-
-static char *
-_bfd_aarch64_erratum_843419_stub_name (asection *input_section,
- bfd_vma offset)
-{
- const bfd_size_type len = 8 + 4 + 1 + 8 + 1 + 16 + 1;
- char *stub_name = bfd_malloc (len);
-
- if (stub_name != NULL)
- snprintf (stub_name, len, "e843419@%04x_%08x_%" PRIx64,
- input_section->owner->id,
- input_section->id,
- (uint64_t) offset);
- return stub_name;
-}
-
-/* Build a stub_entry structure describing an 843419 fixup.
-
- The stub_entry constructed is populated with the bit pattern INSN
- of the instruction located at OFFSET within input SECTION.
-
- Returns TRUE on success. */
-
-static bool
-_bfd_aarch64_erratum_843419_fixup (uint32_t insn,
- bfd_vma adrp_offset,
- bfd_vma ldst_offset,
- asection *section,
- struct bfd_link_info *info)
-{
- struct elf_aarch64_link_hash_table *htab = elf_aarch64_hash_table (info);
- char *stub_name;
- struct elf_aarch64_stub_hash_entry *stub_entry;
-
- stub_name = _bfd_aarch64_erratum_843419_stub_name (section, ldst_offset);
- if (stub_name == NULL)
- return false;
- stub_entry = aarch64_stub_hash_lookup (&htab->stub_hash_table, stub_name,
- false, false);
- if (stub_entry)
- {
- free (stub_name);
- return true;
- }
-
- /* We always place an 843419 workaround veneer in the stub section
- attached to the input section in which an erratum sequence has
- been found. This ensures that later in the link process (in
- elfNN_aarch64_write_section) when we copy the veneered
- instruction from the input section into the stub section the
- copied instruction will have had any relocations applied to it.
- If we placed workaround veneers in any other stub section then we
- could not assume that all relocations have been processed on the
- corresponding input section at the point we output the stub
- section. */
-
- stub_entry = _bfd_aarch64_add_stub_entry_after (stub_name, section, htab);
- if (stub_entry == NULL)
- {
- free (stub_name);
- return false;
- }
-
- stub_entry->adrp_offset = adrp_offset;
- stub_entry->target_value = ldst_offset;
- stub_entry->target_section = section;
- stub_entry->stub_type = aarch64_stub_erratum_843419_veneer;
- stub_entry->veneered_insn = insn;
- stub_entry->output_name = stub_name;
-
- return true;
-}
-
-
-/* Scan an input section looking for the signature of erratum 843419.
-
- Scans input SECTION in INPUT_BFD looking for erratum 843419
- signatures, for each signature found a stub_entry is created
- describing the location of the erratum for subsequent fixup.
-
- Return TRUE on successful scan, FALSE on failure to scan.
- */
-
-static bool
-_bfd_aarch64_erratum_843419_scan (bfd *input_bfd, asection *section,
- struct bfd_link_info *info)
-{
- struct elf_aarch64_link_hash_table *htab = elf_aarch64_hash_table (info);
-
- if (htab == NULL)
- return true;
-
- if (elf_section_type (section) != SHT_PROGBITS
- || (elf_section_flags (section) & SHF_EXECINSTR) == 0
- || (section->flags & SEC_EXCLUDE) != 0
- || (section->sec_info_type == SEC_INFO_TYPE_JUST_SYMS)
- || (section->output_section == bfd_abs_section_ptr))
- return true;
-
- do
- {
- bfd_byte *contents = NULL;
- struct _aarch64_elf_section_data *sec_data;
- unsigned int span;
-
- if (elf_section_data (section)->this_hdr.contents != NULL)
- contents = elf_section_data (section)->this_hdr.contents;
- else if (! bfd_malloc_and_get_section (input_bfd, section, &contents))
- return false;
-
- sec_data = elf_aarch64_section_data (section);
-
- if (sec_data->mapcount)
- qsort (sec_data->map, sec_data->mapcount,
- sizeof (elf_aarch64_section_map), elf_aarch64_compare_mapping);
-
- for (span = 0; span < sec_data->mapcount; span++)
- {
- unsigned int span_start = sec_data->map[span].vma;
- unsigned int span_end = ((span == sec_data->mapcount - 1)
- ? sec_data->map[0].vma + section->size
- : sec_data->map[span + 1].vma);
- unsigned int i;
- char span_type = sec_data->map[span].type;
-
- if (span_type == 'd')
- continue;
-
- for (i = span_start; i + 8 < span_end; i += 4)
- {
- bfd_vma vma = (section->output_section->vma
- + section->output_offset
- + i);
- bfd_vma veneer_i;
-
- if (_bfd_aarch64_erratum_843419_p
- (contents, vma, i, span_end, &veneer_i))
- {
- uint32_t insn = bfd_getl32 (contents + veneer_i);
-
- if (!_bfd_aarch64_erratum_843419_fixup (insn, i, veneer_i,
- section, info))
- return false;
- }
- }
- }
-
- if (elf_section_data (section)->this_hdr.contents == NULL)
- free (contents);
- }
- while (0);
-
- return true;
-}
-
-
-/* Add stub entries for calls.
-
- The basic idea here is to examine all the relocations looking for
- PC-relative calls to a target that is unreachable with a "bl"
- instruction. */
-
-static bool
-_bfd_aarch64_add_call_stub_entries (bool *stub_changed, bfd *output_bfd,
- struct bfd_link_info *info)
-{
- struct elf_aarch64_link_hash_table *htab = elf_aarch64_hash_table (info);
- bool need_bti = elf_aarch64_bti_p (output_bfd);
- bfd *input_bfd;
-
- for (input_bfd = info->input_bfds; input_bfd != NULL;
- input_bfd = input_bfd->link.next)
- {
- Elf_Internal_Shdr *symtab_hdr;
- asection *section;
- Elf_Internal_Sym *local_syms = NULL;
-
- if (!is_aarch64_elf (input_bfd)
- || (input_bfd->flags & BFD_LINKER_CREATED) != 0)
- continue;
-
- /* We'll need the symbol table in a second. */
- symtab_hdr = &elf_tdata (input_bfd)->symtab_hdr;
- if (symtab_hdr->sh_info == 0)
- continue;
-
- /* Walk over each section attached to the input bfd. */
- for (section = input_bfd->sections;
- section != NULL; section = section->next)
- {
- Elf_Internal_Rela *internal_relocs, *irelaend, *irela;
-
- /* If there aren't any relocs, then there's nothing more to do. */
- if ((section->flags & SEC_RELOC) == 0
- || section->reloc_count == 0
- || (section->flags & SEC_CODE) == 0)
- continue;
-
- /* If this section is a link-once section that will be
- discarded, then don't create any stubs. */
- if (section->output_section == NULL
- || section->output_section->owner != output_bfd)
- continue;
-
- /* Get the relocs. */
- internal_relocs
- = _bfd_elf_link_read_relocs (input_bfd, section, NULL,
- NULL, info->keep_memory);
- if (internal_relocs == NULL)
- goto error_ret_free_local;
-
- /* Now examine each relocation. */
- irela = internal_relocs;
- irelaend = irela + section->reloc_count;
- for (; irela < irelaend; irela++)
- {
- unsigned int r_type, r_indx;
- enum elf_aarch64_stub_type stub_type;
- struct elf_aarch64_stub_hash_entry *stub_entry;
- struct elf_aarch64_stub_hash_entry *stub_entry_bti;
- asection *sym_sec;
- bfd_vma sym_value;
- bfd_vma destination;
- struct elf_aarch64_link_hash_entry *hash;
- const char *sym_name;
- char *stub_name;
- char *stub_name_bti;
- const asection *id_sec;
- const asection *id_sec_bti;
- unsigned char st_type;
- bfd_size_type len;
-
- r_type = ELFNN_R_TYPE (irela->r_info);
- r_indx = ELFNN_R_SYM (irela->r_info);
-
- if (r_type >= (unsigned int) R_AARCH64_end)
- {
- bfd_set_error (bfd_error_bad_value);
- error_ret_free_internal:
- if (elf_section_data (section)->relocs == NULL)
- free (internal_relocs);
- goto error_ret_free_local;
- }
-
- /* Only look for stubs on unconditional branch and
- branch and link instructions. */
- if (r_type != (unsigned int) AARCH64_R (CALL26)
- && r_type != (unsigned int) AARCH64_R (JUMP26))
- continue;
-
- /* Now determine the call target, its name, value,
- section. */
- sym_sec = NULL;
- sym_value = 0;
- destination = 0;
- hash = NULL;
- sym_name = NULL;
- if (r_indx < symtab_hdr->sh_info)
- {
- /* It's a local symbol. */
- Elf_Internal_Sym *sym;
- Elf_Internal_Shdr *hdr;
-
- if (local_syms == NULL)
- {
- local_syms
- = (Elf_Internal_Sym *) symtab_hdr->contents;
- if (local_syms == NULL)
- local_syms
- = bfd_elf_get_elf_syms (input_bfd, symtab_hdr,
- symtab_hdr->sh_info, 0,
- NULL, NULL, NULL);
- if (local_syms == NULL)
- goto error_ret_free_internal;
- }
-
- sym = local_syms + r_indx;
- hdr = elf_elfsections (input_bfd)[sym->st_shndx];
- sym_sec = hdr->bfd_section;
- if (!sym_sec)
- /* This is an undefined symbol. It can never
- be resolved. */
- continue;
-
- if (ELF_ST_TYPE (sym->st_info) != STT_SECTION)
- sym_value = sym->st_value;
- destination = (sym_value + irela->r_addend
- + sym_sec->output_offset
- + sym_sec->output_section->vma);
- st_type = ELF_ST_TYPE (sym->st_info);
- sym_name
- = bfd_elf_string_from_elf_section (input_bfd,
- symtab_hdr->sh_link,
- sym->st_name);
- }
- else
- {
- int e_indx;
-
- e_indx = r_indx - symtab_hdr->sh_info;
- hash = ((struct elf_aarch64_link_hash_entry *)
- elf_sym_hashes (input_bfd)[e_indx]);
-
- while (hash->root.root.type == bfd_link_hash_indirect
- || hash->root.root.type == bfd_link_hash_warning)
- hash = ((struct elf_aarch64_link_hash_entry *)
- hash->root.root.u.i.link);
-
- if (hash->root.root.type == bfd_link_hash_defined
- || hash->root.root.type == bfd_link_hash_defweak)
- {
- struct elf_aarch64_link_hash_table *globals =
- elf_aarch64_hash_table (info);
- sym_sec = hash->root.root.u.def.section;
- sym_value = hash->root.root.u.def.value;
- /* For a destination in a shared library,
- use the PLT stub as target address to
- decide whether a branch stub is
- needed. */
- if (globals->root.splt != NULL && hash != NULL
- && hash->root.plt.offset != (bfd_vma) - 1)
- {
- sym_sec = globals->root.splt;
- sym_value = hash->root.plt.offset;
- if (sym_sec->output_section != NULL)
- destination = (sym_value
- + sym_sec->output_offset
- + sym_sec->output_section->vma);
- }
- else if (sym_sec->output_section != NULL)
- destination = (sym_value + irela->r_addend
- + sym_sec->output_offset
- + sym_sec->output_section->vma);
- }
- else if (hash->root.root.type == bfd_link_hash_undefined
- || (hash->root.root.type
- == bfd_link_hash_undefweak))
- {
- /* For a shared library, use the PLT stub as
- target address to decide whether a long
- branch stub is needed.
- For absolute code, they cannot be handled. */
- struct elf_aarch64_link_hash_table *globals =
- elf_aarch64_hash_table (info);
-
- if (globals->root.splt != NULL && hash != NULL
- && hash->root.plt.offset != (bfd_vma) - 1)
- {
- sym_sec = globals->root.splt;
- sym_value = hash->root.plt.offset;
- if (sym_sec->output_section != NULL)
- destination = (sym_value
- + sym_sec->output_offset
- + sym_sec->output_section->vma);
- }
- else
- continue;
- }
- else
- {
- bfd_set_error (bfd_error_bad_value);
- goto error_ret_free_internal;
- }
- st_type = ELF_ST_TYPE (hash->root.type);
- sym_name = hash->root.root.root.string;
- }
-
- /* Determine what (if any) linker stub is needed. */
- stub_type = aarch64_type_of_stub (section, irela, sym_sec,
- st_type, destination);
- if (stub_type == aarch64_stub_none)
- continue;
-
- /* Support for grouping stub sections. */
- id_sec = htab->stub_group[section->id].link_sec;
-
- /* Get the name of this stub. */
- stub_name = elfNN_aarch64_stub_name (id_sec, sym_sec, hash,
- irela);
- if (!stub_name)
- goto error_ret_free_internal;
-
- stub_entry =
- aarch64_stub_hash_lookup (&htab->stub_hash_table,
- stub_name, false, false);
- if (stub_entry != NULL)
- {
- /* The proper stub has already been created. */
- free (stub_name);
-
- /* Always update this stub's target since it may have
- changed after layout. */
- stub_entry->target_value = sym_value + irela->r_addend;
-
- if (stub_entry->double_stub)
- {
- /* Update the target of both stubs. */
-
- id_sec_bti = htab->stub_group[sym_sec->id].link_sec;
- stub_name_bti =
- elfNN_aarch64_stub_name (id_sec_bti, sym_sec, hash,
- irela);
- if (!stub_name_bti)
- goto error_ret_free_internal;
- stub_entry_bti =
- aarch64_stub_hash_lookup (&htab->stub_hash_table,
- stub_name_bti, false, false);
- BFD_ASSERT (stub_entry_bti != NULL);
- free (stub_name_bti);
- stub_entry_bti->target_value = stub_entry->target_value;
- stub_entry->target_value = stub_entry_bti->stub_offset;
- }
- continue;
- }
-
- stub_entry = _bfd_aarch64_add_stub_entry_in_group
- (stub_name, section, htab);
- if (stub_entry == NULL)
- {
- free (stub_name);
- goto error_ret_free_internal;
- }
-
- stub_entry->target_value = sym_value + irela->r_addend;
- stub_entry->target_section = sym_sec;
- stub_entry->stub_type = stub_type;
- stub_entry->h = hash;
- stub_entry->st_type = st_type;
-
- if (sym_name == NULL)
- sym_name = "unnamed";
- len = sizeof (STUB_ENTRY_NAME) + strlen (sym_name);
- stub_entry->output_name = bfd_alloc (htab->stub_bfd, len);
- if (stub_entry->output_name == NULL)
- {
- free (stub_name);
- goto error_ret_free_internal;
- }
-
- snprintf (stub_entry->output_name, len, STUB_ENTRY_NAME,
- sym_name);
-
- /* A stub with indirect jump may break BTI compatibility, so
- insert another stub with direct jump near the target then. */
- if (need_bti && !aarch64_bti_stub_p (info, stub_entry))
- {
- id_sec_bti = htab->stub_group[sym_sec->id].link_sec;
-
- /* If the stub with indirect jump and the BTI stub are in
- the same stub group: change the indirect jump stub into
- a BTI stub since a direct branch can reach the target.
- The BTI landing pad is still needed in case another
- stub indirectly jumps to it. */
- if (id_sec_bti == id_sec)
- {
- stub_entry->stub_type = aarch64_stub_bti_direct_branch;
- goto skip_double_stub;
- }
-
- stub_entry->double_stub = true;
- htab->has_double_stub = true;
-
- stub_name_bti =
- elfNN_aarch64_stub_name (id_sec_bti, sym_sec, hash, irela);
- if (!stub_name_bti)
- {
- free (stub_name);
- goto error_ret_free_internal;
- }
-
- stub_entry_bti =
- aarch64_stub_hash_lookup (&htab->stub_hash_table,
- stub_name_bti, false, false);
- if (stub_entry_bti != NULL)
- BFD_ASSERT (stub_entry_bti->stub_type
- == aarch64_stub_bti_direct_branch);
- else
- {
- stub_entry_bti =
- _bfd_aarch64_add_stub_entry_in_group (stub_name_bti,
- sym_sec, htab);
- if (stub_entry_bti == NULL)
- {
- free (stub_name);
- free (stub_name_bti);
- goto error_ret_free_internal;
- }
-
- stub_entry_bti->target_value =
- sym_value + irela->r_addend;
- stub_entry_bti->target_section = sym_sec;
- stub_entry_bti->stub_type =
- aarch64_stub_bti_direct_branch;
- stub_entry_bti->h = hash;
- stub_entry_bti->st_type = st_type;
-
- len = sizeof (BTI_STUB_ENTRY_NAME) + strlen (sym_name);
- stub_entry_bti->output_name = bfd_alloc (htab->stub_bfd,
- len);
- if (stub_entry_bti->output_name == NULL)
- {
- free (stub_name);
- free (stub_name_bti);
- goto error_ret_free_internal;
- }
- snprintf (stub_entry_bti->output_name, len,
- BTI_STUB_ENTRY_NAME, sym_name);
- }
-
- /* Update the indirect call stub to target the BTI stub. */
- stub_entry->target_value = 0;
- stub_entry->target_section = stub_entry_bti->stub_sec;
- stub_entry->stub_type = stub_type;
- stub_entry->h = NULL;
- stub_entry->st_type = STT_FUNC;
- }
-skip_double_stub:
- *stub_changed = true;
- }
-
- /* We're done with the internal relocs, free them. */
- if (elf_section_data (section)->relocs == NULL)
- free (internal_relocs);
- }
- }
- return true;
- error_ret_free_local:
- return false;
-}
-
-
-/* Determine and set the size of the stub section for a final link. */
-
-bool
-elfNN_aarch64_size_stubs (bfd *output_bfd,
- bfd *stub_bfd,
- struct bfd_link_info *info,
- bfd_signed_vma group_size,
- asection * (*add_stub_section) (const char *,
- asection *),
- void (*layout_sections_again) (void))
-{
- bfd_size_type stub_group_size;
- bool stubs_always_before_branch;
- struct elf_aarch64_link_hash_table *htab = elf_aarch64_hash_table (info);
- unsigned int num_erratum_835769_fixes = 0;
-
- /* Propagate mach to stub bfd, because it may not have been
- finalized when we created stub_bfd. */
- bfd_set_arch_mach (stub_bfd, bfd_get_arch (output_bfd),
- bfd_get_mach (output_bfd));
-
- /* Stash our params away. */
- htab->stub_bfd = stub_bfd;
- htab->add_stub_section = add_stub_section;
- htab->layout_sections_again = layout_sections_again;
- stubs_always_before_branch = group_size < 0;
- if (group_size < 0)
- stub_group_size = -group_size;
- else
- stub_group_size = group_size;
-
- if (stub_group_size == 1)
- {
- /* Default values. */
- /* AArch64 branch range is +-128MB. The value used is 1MB less. */
- stub_group_size = 127 * 1024 * 1024;
- }
-
- group_sections (htab, stub_group_size, stubs_always_before_branch);
-
- (*htab->layout_sections_again) ();
-
- if (htab->fix_erratum_835769)
- {
- bfd *input_bfd;
-
- for (input_bfd = info->input_bfds;
- input_bfd != NULL; input_bfd = input_bfd->link.next)
- {
- if (!is_aarch64_elf (input_bfd)
- || (input_bfd->flags & BFD_LINKER_CREATED) != 0)
- continue;
-
- if (!_bfd_aarch64_erratum_835769_scan (input_bfd, info,
- &num_erratum_835769_fixes))
- return false;
- }
-
- _bfd_aarch64_resize_stubs (htab);
- (*htab->layout_sections_again) ();
- }
-
- if (htab->fix_erratum_843419 != ERRAT_NONE)
- {
- bfd *input_bfd;
-
- for (input_bfd = info->input_bfds;
- input_bfd != NULL;
- input_bfd = input_bfd->link.next)
- {
- asection *section;
-
- if (!is_aarch64_elf (input_bfd)
- || (input_bfd->flags & BFD_LINKER_CREATED) != 0)
- continue;
-
- for (section = input_bfd->sections;
- section != NULL;
- section = section->next)
- if (!_bfd_aarch64_erratum_843419_scan (input_bfd, section, info))
- return false;
- }
-
- _bfd_aarch64_resize_stubs (htab);
- (*htab->layout_sections_again) ();
- }
-
- for (;;)
- {
- bool stub_changed = false;
-
- if (!_bfd_aarch64_add_call_stub_entries (&stub_changed, output_bfd, info))
- return false;
-
- if (!stub_changed)
- return true;
-
- _bfd_aarch64_resize_stubs (htab);
- (*htab->layout_sections_again) ();
- }
-}
-
-/* Build all the stubs associated with the current output file. The
- stubs are kept in a hash table attached to the main linker hash
- table. We also set up the .plt entries for statically linked PIC
- functions here. This function is called via aarch64_elf_finish in the
- linker. */
-
-bool
-elfNN_aarch64_build_stubs (struct bfd_link_info *info)
-{
- asection *stub_sec;
- struct bfd_hash_table *table;
- struct elf_aarch64_link_hash_table *htab;
-
- htab = elf_aarch64_hash_table (info);
-
- for (stub_sec = htab->stub_bfd->sections;
- stub_sec != NULL; stub_sec = stub_sec->next)
- {
- bfd_size_type size;
-
- /* Ignore non-stub sections. */
- if (!strstr (stub_sec->name, STUB_SUFFIX))
- continue;
-
- /* Allocate memory to hold the linker stubs. */
- size = stub_sec->size;
- stub_sec->contents = bfd_zalloc (htab->stub_bfd, size);
- if (stub_sec->contents == NULL && size != 0)
- return false;
- stub_sec->size = 0;
-
- /* Add a branch around the stub section, and a nop, to keep it 8 byte
- aligned, as long branch stubs contain a 64-bit address. */
- bfd_putl32 (0x14000000 | (size >> 2), stub_sec->contents);
- bfd_putl32 (INSN_NOP, stub_sec->contents + 4);
- stub_sec->size += 8;
- }
-
- /* Build the stubs as directed by the stub hash table. */
- table = &htab->stub_hash_table;
- bfd_hash_traverse (table, aarch64_build_one_stub, info);
-
- return true;
-}
-
-
-/* Add an entry to the code/data map for section SEC. */
-
-static void
-elfNN_aarch64_section_map_add (asection *sec, char type, bfd_vma vma)
-{
- struct _aarch64_elf_section_data *sec_data =
- elf_aarch64_section_data (sec);
- unsigned int newidx;
-
- if (sec_data->map == NULL)
- {
- sec_data->map = bfd_malloc (sizeof (elf_aarch64_section_map));
- sec_data->mapcount = 0;
- sec_data->mapsize = 1;
- }
-
- newidx = sec_data->mapcount++;
-
- if (sec_data->mapcount > sec_data->mapsize)
- {
- sec_data->mapsize *= 2;
- sec_data->map = bfd_realloc_or_free
- (sec_data->map, sec_data->mapsize * sizeof (elf_aarch64_section_map));
- }
-
- if (sec_data->map)
- {
- sec_data->map[newidx].vma = vma;
- sec_data->map[newidx].type = type;
- }
-}
-
-
-/* Initialise maps of insn/data for input BFDs. */
-void
-bfd_elfNN_aarch64_init_maps (bfd *abfd)
-{
- Elf_Internal_Sym *isymbuf;
- Elf_Internal_Shdr *hdr;
- unsigned int i, localsyms;
-
- /* Make sure that we are dealing with an AArch64 elf binary. */
- if (!is_aarch64_elf (abfd))
- return;
-
- if ((abfd->flags & DYNAMIC) != 0)
- return;
-
- hdr = &elf_symtab_hdr (abfd);
- localsyms = hdr->sh_info;
-
- /* Obtain a buffer full of symbols for this BFD. The hdr->sh_info field
- should contain the number of local symbols, which should come before any
- global symbols. Mapping symbols are always local. */
- isymbuf = bfd_elf_get_elf_syms (abfd, hdr, localsyms, 0, NULL, NULL, NULL);
-
- /* No internal symbols read? Skip this BFD. */
- if (isymbuf == NULL)
- return;
-
- for (i = 0; i < localsyms; i++)
- {
- Elf_Internal_Sym *isym = &isymbuf[i];
- asection *sec = bfd_section_from_elf_index (abfd, isym->st_shndx);
- const char *name;
-
- if (sec != NULL && ELF_ST_BIND (isym->st_info) == STB_LOCAL)
- {
- name = bfd_elf_string_from_elf_section (abfd,
- hdr->sh_link,
- isym->st_name);
-
- if (bfd_is_aarch64_special_symbol_name
- (name, BFD_AARCH64_SPECIAL_SYM_TYPE_MAP))
- elfNN_aarch64_section_map_add (sec, name[1], isym->st_value);
- }
- }
-}
-
-static void
-setup_plt_values (struct bfd_link_info *link_info,
- aarch64_plt_type plt_type)
-{
- struct elf_aarch64_link_hash_table *globals;
- globals = elf_aarch64_hash_table (link_info);
-
- if (plt_type == PLT_BTI_PAC)
- {
- globals->plt0_entry = elfNN_aarch64_small_plt0_bti_entry;
-
- /* Only in ET_EXEC we need PLTn with BTI. */
- if (bfd_link_pde (link_info))
- {
- globals->plt_entry_size = PLT_BTI_PAC_SMALL_ENTRY_SIZE;
- globals->plt_entry = elfNN_aarch64_small_plt_bti_pac_entry;
- }
- else
- {
- globals->plt_entry_size = PLT_PAC_SMALL_ENTRY_SIZE;
- globals->plt_entry = elfNN_aarch64_small_plt_pac_entry;
- }
- }
- else if (plt_type == PLT_BTI)
- {
- globals->plt0_entry = elfNN_aarch64_small_plt0_bti_entry;
-
- /* Only in ET_EXEC we need PLTn with BTI. */
- if (bfd_link_pde (link_info))
- {
- globals->plt_entry_size = PLT_BTI_SMALL_ENTRY_SIZE;
- globals->plt_entry = elfNN_aarch64_small_plt_bti_entry;
- }
- }
- else if (plt_type == PLT_PAC)
- {
- globals->plt_entry_size = PLT_PAC_SMALL_ENTRY_SIZE;
- globals->plt_entry = elfNN_aarch64_small_plt_pac_entry;
- }
-}
-
-/* Set option values needed during linking. */
-void
-bfd_elfNN_aarch64_set_options (struct bfd *output_bfd,
- struct bfd_link_info *link_info,
- int no_enum_warn,
- int no_wchar_warn, int pic_veneer,
- int fix_erratum_835769,
- erratum_84319_opts fix_erratum_843419,
- int no_apply_dynamic_relocs,
- aarch64_bti_pac_info bp_info)
-{
- struct elf_aarch64_link_hash_table *globals;
-
- globals = elf_aarch64_hash_table (link_info);
- globals->pic_veneer = pic_veneer;
- globals->fix_erratum_835769 = fix_erratum_835769;
- /* If the default options are used, then ERRAT_ADR will be set by default
- which will enable the ADRP->ADR workaround for the erratum 843419
- workaround. */
- globals->fix_erratum_843419 = fix_erratum_843419;
- globals->no_apply_dynamic_relocs = no_apply_dynamic_relocs;
-
- BFD_ASSERT (is_aarch64_elf (output_bfd));
- elf_aarch64_tdata (output_bfd)->no_enum_size_warning = no_enum_warn;
- elf_aarch64_tdata (output_bfd)->no_wchar_size_warning = no_wchar_warn;
-
- switch (bp_info.bti_type)
- {
- case BTI_WARN:
- elf_aarch64_tdata (output_bfd)->no_bti_warn = 0;
- elf_aarch64_tdata (output_bfd)->gnu_and_prop
- |= GNU_PROPERTY_AARCH64_FEATURE_1_BTI;
- break;
-
- default:
- break;
- }
- elf_aarch64_tdata (output_bfd)->plt_type = bp_info.plt_type;
- setup_plt_values (link_info, bp_info.plt_type);
-}
-
-static bfd_vma
-aarch64_calculate_got_entry_vma (struct elf_link_hash_entry *h,
- struct elf_aarch64_link_hash_table
- *globals, struct bfd_link_info *info,
- bfd_vma value, bfd *output_bfd,
- bool *unresolved_reloc_p)
-{
- bfd_vma off = (bfd_vma) - 1;
- asection *basegot = globals->root.sgot;
- bool dyn = globals->root.dynamic_sections_created;
-
- if (h != NULL)
- {
- BFD_ASSERT (basegot != NULL);
- off = h->got.offset;
- BFD_ASSERT (off != (bfd_vma) - 1);
- if (!WILL_CALL_FINISH_DYNAMIC_SYMBOL (dyn, bfd_link_pic (info), h)
- || (bfd_link_pic (info)
- && SYMBOL_REFERENCES_LOCAL (info, h))
- || (ELF_ST_VISIBILITY (h->other)
- && h->root.type == bfd_link_hash_undefweak))
- {
- /* This is actually a static link, or it is a -Bsymbolic link
- and the symbol is defined locally. We must initialize this
- entry in the global offset table. Since the offset must
- always be a multiple of 8 (4 in the case of ILP32), we use
- the least significant bit to record whether we have
- initialized it already.
- When doing a dynamic link, we create a .rel(a).got relocation
- entry to initialize the value. This is done in the
- finish_dynamic_symbol routine. */
- if ((off & 1) != 0)
- off &= ~1;
- else
- {
- bfd_put_NN (output_bfd, value, basegot->contents + off);
- h->got.offset |= 1;
- }
- }
- else
- *unresolved_reloc_p = false;
-
- off = off + basegot->output_section->vma + basegot->output_offset;
- }
-
- return off;
-}
-
-/* Change R_TYPE to a more efficient access model where possible,
- return the new reloc type. */
-
-static bfd_reloc_code_real_type
-aarch64_tls_transition_without_check (bfd_reloc_code_real_type r_type,
- struct elf_link_hash_entry *h,
- struct bfd_link_info *info)
-{
- bool local_exec = bfd_link_executable (info)
- && SYMBOL_REFERENCES_LOCAL (info, h);
-
- switch (r_type)
- {
- case BFD_RELOC_AARCH64_TLSDESC_ADR_PAGE21:
- case BFD_RELOC_AARCH64_TLSGD_ADR_PAGE21:
- return (local_exec
- ? BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G1
- : BFD_RELOC_AARCH64_TLSIE_ADR_GOTTPREL_PAGE21);
-
- case BFD_RELOC_AARCH64_TLSDESC_ADR_PREL21:
- return (local_exec
- ? BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G0_NC
- : r_type);
-
- case BFD_RELOC_AARCH64_TLSDESC_LD_PREL19:
- return (local_exec
- ? BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G1
- : BFD_RELOC_AARCH64_TLSIE_LD_GOTTPREL_PREL19);
-
- case BFD_RELOC_AARCH64_TLSDESC_LDR:
- return (local_exec
- ? BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G0_NC
- : BFD_RELOC_AARCH64_NONE);
-
- case BFD_RELOC_AARCH64_TLSDESC_OFF_G0_NC:
- return (local_exec
- ? BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G1_NC
- : BFD_RELOC_AARCH64_TLSIE_MOVW_GOTTPREL_G0_NC);
-
- case BFD_RELOC_AARCH64_TLSDESC_OFF_G1:
- return (local_exec
- ? BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G2
- : BFD_RELOC_AARCH64_TLSIE_MOVW_GOTTPREL_G1);
-
- case BFD_RELOC_AARCH64_TLSDESC_LDNN_LO12_NC:
- case BFD_RELOC_AARCH64_TLSGD_ADD_LO12_NC:
- return (local_exec
- ? BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G0_NC
- : BFD_RELOC_AARCH64_TLSIE_LDNN_GOTTPREL_LO12_NC);
-
- case BFD_RELOC_AARCH64_TLSIE_ADR_GOTTPREL_PAGE21:
- return local_exec ? BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G1 : r_type;
-
- case BFD_RELOC_AARCH64_TLSIE_LDNN_GOTTPREL_LO12_NC:
- return local_exec ? BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G0_NC : r_type;
-
- case BFD_RELOC_AARCH64_TLSIE_LD_GOTTPREL_PREL19:
- return r_type;
-
- case BFD_RELOC_AARCH64_TLSGD_ADR_PREL21:
- return (local_exec
- ? BFD_RELOC_AARCH64_TLSLE_ADD_TPREL_HI12
- : BFD_RELOC_AARCH64_TLSIE_LD_GOTTPREL_PREL19);
-
- case BFD_RELOC_AARCH64_TLSDESC_ADD:
- case BFD_RELOC_AARCH64_TLSDESC_ADD_LO12:
- case BFD_RELOC_AARCH64_TLSDESC_CALL:
- /* Instructions with these relocations will become NOPs. */
- return BFD_RELOC_AARCH64_NONE;
-
- case BFD_RELOC_AARCH64_TLSLD_ADD_LO12_NC:
- case BFD_RELOC_AARCH64_TLSLD_ADR_PAGE21:
- case BFD_RELOC_AARCH64_TLSLD_ADR_PREL21:
- return local_exec ? BFD_RELOC_AARCH64_NONE : r_type;
-
-#if ARCH_SIZE == 64
- case BFD_RELOC_AARCH64_TLSGD_MOVW_G0_NC:
- return local_exec
- ? BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G1_NC
- : BFD_RELOC_AARCH64_TLSIE_MOVW_GOTTPREL_G0_NC;
-
- case BFD_RELOC_AARCH64_TLSGD_MOVW_G1:
- return local_exec
- ? BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G2
- : BFD_RELOC_AARCH64_TLSIE_MOVW_GOTTPREL_G1;
-#endif
-
- default:
- break;
- }
-
- return r_type;
-}
-
-static unsigned int
-aarch64_reloc_got_type (bfd_reloc_code_real_type r_type)
-{
- switch (r_type)
- {
- case BFD_RELOC_AARCH64_ADR_GOT_PAGE:
- case BFD_RELOC_AARCH64_GOT_LD_PREL19:
- case BFD_RELOC_AARCH64_LD32_GOTPAGE_LO14:
- case BFD_RELOC_AARCH64_LD32_GOT_LO12_NC:
- case BFD_RELOC_AARCH64_LD64_GOTOFF_LO15:
- case BFD_RELOC_AARCH64_LD64_GOTPAGE_LO15:
- case BFD_RELOC_AARCH64_LD64_GOT_LO12_NC:
- case BFD_RELOC_AARCH64_MOVW_GOTOFF_G0_NC:
- case BFD_RELOC_AARCH64_MOVW_GOTOFF_G1:
- return GOT_NORMAL;
-
- case BFD_RELOC_AARCH64_TLSGD_ADD_LO12_NC:
- case BFD_RELOC_AARCH64_TLSGD_ADR_PAGE21:
- case BFD_RELOC_AARCH64_TLSGD_ADR_PREL21:
- case BFD_RELOC_AARCH64_TLSGD_MOVW_G0_NC:
- case BFD_RELOC_AARCH64_TLSGD_MOVW_G1:
- case BFD_RELOC_AARCH64_TLSLD_ADD_LO12_NC:
- case BFD_RELOC_AARCH64_TLSLD_ADR_PAGE21:
- case BFD_RELOC_AARCH64_TLSLD_ADR_PREL21:
- return GOT_TLS_GD;
-
- case BFD_RELOC_AARCH64_TLSDESC_ADD:
- case BFD_RELOC_AARCH64_TLSDESC_ADD_LO12:
- case BFD_RELOC_AARCH64_TLSDESC_ADR_PAGE21:
- case BFD_RELOC_AARCH64_TLSDESC_ADR_PREL21:
- case BFD_RELOC_AARCH64_TLSDESC_CALL:
- case BFD_RELOC_AARCH64_TLSDESC_LD32_LO12_NC:
- case BFD_RELOC_AARCH64_TLSDESC_LD64_LO12:
- case BFD_RELOC_AARCH64_TLSDESC_LD_PREL19:
- case BFD_RELOC_AARCH64_TLSDESC_LDR:
- case BFD_RELOC_AARCH64_TLSDESC_OFF_G0_NC:
- case BFD_RELOC_AARCH64_TLSDESC_OFF_G1:
- return GOT_TLSDESC_GD;
-
- case BFD_RELOC_AARCH64_TLSIE_ADR_GOTTPREL_PAGE21:
- case BFD_RELOC_AARCH64_TLSIE_LD32_GOTTPREL_LO12_NC:
- case BFD_RELOC_AARCH64_TLSIE_LD64_GOTTPREL_LO12_NC:
- case BFD_RELOC_AARCH64_TLSIE_LD_GOTTPREL_PREL19:
- case BFD_RELOC_AARCH64_TLSIE_MOVW_GOTTPREL_G0_NC:
- case BFD_RELOC_AARCH64_TLSIE_MOVW_GOTTPREL_G1:
- return GOT_TLS_IE;
-
- default:
- break;
- }
- return GOT_UNKNOWN;
-}
-
-static bool
-aarch64_can_relax_tls (bfd *input_bfd,
- struct bfd_link_info *info,
- bfd_reloc_code_real_type r_type,
- struct elf_link_hash_entry *h,
- unsigned long r_symndx)
-{
- unsigned int symbol_got_type;
- unsigned int reloc_got_type;
-
- if (! IS_AARCH64_TLS_RELAX_RELOC (r_type))
- return false;
-
- symbol_got_type = elfNN_aarch64_symbol_got_type (h, input_bfd, r_symndx);
- reloc_got_type = aarch64_reloc_got_type (r_type);
-
- if (symbol_got_type == GOT_TLS_IE && GOT_TLS_GD_ANY_P (reloc_got_type))
- return true;
-
- if (!bfd_link_executable (info))
- return false;
-
- if (h && h->root.type == bfd_link_hash_undefweak)
- return false;
-
- return true;
-}
-
-/* Given the relocation code R_TYPE, return the relaxed bfd reloc
- enumerator. */
-
-static bfd_reloc_code_real_type
-aarch64_tls_transition (bfd *input_bfd,
- struct bfd_link_info *info,
- unsigned int r_type,
- struct elf_link_hash_entry *h,
- unsigned long r_symndx)
-{
- bfd_reloc_code_real_type bfd_r_type
- = elfNN_aarch64_bfd_reloc_from_type (input_bfd, r_type);
-
- if (! aarch64_can_relax_tls (input_bfd, info, bfd_r_type, h, r_symndx))
- return bfd_r_type;
-
- return aarch64_tls_transition_without_check (bfd_r_type, h, info);
-}
-
-/* Return the base VMA address which should be subtracted from real addresses
- when resolving R_AARCH64_TLS_DTPREL relocation. */
-
-static bfd_vma
-dtpoff_base (struct bfd_link_info *info)
-{
- /* If tls_sec is NULL, we should have signalled an error already. */
- BFD_ASSERT (elf_hash_table (info)->tls_sec != NULL);
- return elf_hash_table (info)->tls_sec->vma;
-}
-
-/* Return the base VMA address which should be subtracted from real addresses
- when resolving R_AARCH64_TLS_GOTTPREL64 relocations. */
-
-static bfd_vma
-tpoff_base (struct bfd_link_info *info)
-{
- struct elf_link_hash_table *htab = elf_hash_table (info);
-
- /* If tls_sec is NULL, we should have signalled an error already. */
- BFD_ASSERT (htab->tls_sec != NULL);
-
- bfd_vma base = align_power ((bfd_vma) TCB_SIZE,
- htab->tls_sec->alignment_power);
- return htab->tls_sec->vma - base;
-}
-
-static bfd_vma *
-symbol_got_offset_ref (bfd *input_bfd, struct elf_link_hash_entry *h,
- unsigned long r_symndx)
-{
- /* Calculate the address of the GOT entry for symbol
- referred to in h. */
- if (h != NULL)
- return &h->got.offset;
- else
- {
- /* local symbol */
- struct elf_aarch64_local_symbol *l;
-
- l = elf_aarch64_locals (input_bfd);
- return &l[r_symndx].got_offset;
- }
-}
-
-static void
-symbol_got_offset_mark (bfd *input_bfd, struct elf_link_hash_entry *h,
- unsigned long r_symndx)
-{
- bfd_vma *p;
- p = symbol_got_offset_ref (input_bfd, h, r_symndx);
- *p |= 1;
-}
-
-static int
-symbol_got_offset_mark_p (bfd *input_bfd, struct elf_link_hash_entry *h,
- unsigned long r_symndx)
-{
- bfd_vma value;
- value = * symbol_got_offset_ref (input_bfd, h, r_symndx);
- return value & 1;
-}
-
-static bfd_vma
-symbol_got_offset (bfd *input_bfd, struct elf_link_hash_entry *h,
- unsigned long r_symndx)
-{
- bfd_vma value;
- value = * symbol_got_offset_ref (input_bfd, h, r_symndx);
- value &= ~1;
- return value;
-}
-
-static bfd_vma *
-symbol_tlsdesc_got_offset_ref (bfd *input_bfd, struct elf_link_hash_entry *h,
- unsigned long r_symndx)
-{
- /* Calculate the address of the GOT entry for symbol
- referred to in h. */
- if (h != NULL)
- {
- struct elf_aarch64_link_hash_entry *eh;
- eh = (struct elf_aarch64_link_hash_entry *) h;
- return &eh->tlsdesc_got_jump_table_offset;
- }
- else
- {
- /* local symbol */
- struct elf_aarch64_local_symbol *l;
-
- l = elf_aarch64_locals (input_bfd);
- return &l[r_symndx].tlsdesc_got_jump_table_offset;
- }
-}
-
-static void
-symbol_tlsdesc_got_offset_mark (bfd *input_bfd, struct elf_link_hash_entry *h,
- unsigned long r_symndx)
-{
- bfd_vma *p;
- p = symbol_tlsdesc_got_offset_ref (input_bfd, h, r_symndx);
- *p |= 1;
-}
-
-static int
-symbol_tlsdesc_got_offset_mark_p (bfd *input_bfd,
- struct elf_link_hash_entry *h,
- unsigned long r_symndx)
-{
- bfd_vma value;
- value = * symbol_tlsdesc_got_offset_ref (input_bfd, h, r_symndx);
- return value & 1;
-}
-
-static bfd_vma
-symbol_tlsdesc_got_offset (bfd *input_bfd, struct elf_link_hash_entry *h,
- unsigned long r_symndx)
-{
- bfd_vma value;
- value = * symbol_tlsdesc_got_offset_ref (input_bfd, h, r_symndx);
- value &= ~1;
- return value;
-}
-
-/* Data for make_branch_to_erratum_835769_stub(). */
-
-struct erratum_835769_branch_to_stub_data
-{
- struct bfd_link_info *info;
- asection *output_section;
- bfd_byte *contents;
-};
-
-/* Helper to insert branches to erratum 835769 stubs in the right
- places for a particular section. */
-
-static bool
-make_branch_to_erratum_835769_stub (struct bfd_hash_entry *gen_entry,
- void *in_arg)
-{
- struct elf_aarch64_stub_hash_entry *stub_entry;
- struct erratum_835769_branch_to_stub_data *data;
- bfd_byte *contents;
- unsigned long branch_insn = 0;
- bfd_vma veneered_insn_loc, veneer_entry_loc;
- bfd_signed_vma branch_offset;
- unsigned int target;
- bfd *abfd;
-
- stub_entry = (struct elf_aarch64_stub_hash_entry *) gen_entry;
- data = (struct erratum_835769_branch_to_stub_data *) in_arg;
-
- if (stub_entry->target_section != data->output_section
- || stub_entry->stub_type != aarch64_stub_erratum_835769_veneer)
- return true;
-
- contents = data->contents;
- veneered_insn_loc = stub_entry->target_section->output_section->vma
- + stub_entry->target_section->output_offset
- + stub_entry->target_value;
- veneer_entry_loc = stub_entry->stub_sec->output_section->vma
- + stub_entry->stub_sec->output_offset
- + stub_entry->stub_offset;
- branch_offset = veneer_entry_loc - veneered_insn_loc;
-
- abfd = stub_entry->target_section->owner;
- if (!aarch64_valid_branch_p (veneer_entry_loc, veneered_insn_loc))
- _bfd_error_handler
- (_("%pB: error: erratum 835769 stub out "
- "of range (input file too large)"), abfd);
-
- target = stub_entry->target_value;
- branch_insn = 0x14000000;
- branch_offset >>= 2;
- branch_offset &= 0x3ffffff;
- branch_insn |= branch_offset;
- bfd_putl32 (branch_insn, &contents[target]);
-
- return true;
-}
-
-
-static bool
-_bfd_aarch64_erratum_843419_branch_to_stub (struct bfd_hash_entry *gen_entry,
- void *in_arg)
-{
- struct elf_aarch64_stub_hash_entry *stub_entry
- = (struct elf_aarch64_stub_hash_entry *) gen_entry;
- struct erratum_835769_branch_to_stub_data *data
- = (struct erratum_835769_branch_to_stub_data *) in_arg;
- struct bfd_link_info *info;
- struct elf_aarch64_link_hash_table *htab;
- bfd_byte *contents;
- asection *section;
- bfd *abfd;
- bfd_vma place;
- uint32_t insn;
-
- info = data->info;
- contents = data->contents;
- section = data->output_section;
-
- htab = elf_aarch64_hash_table (info);
-
- if (stub_entry->target_section != section
- || stub_entry->stub_type != aarch64_stub_erratum_843419_veneer)
- return true;
-
- BFD_ASSERT (((htab->fix_erratum_843419 & ERRAT_ADRP) && stub_entry->stub_sec)
- || (htab->fix_erratum_843419 & ERRAT_ADR));
-
- /* Only update the stub section if we have one. We should always have one if
- we're allowed to use the ADRP errata workaround, otherwise it is not
- required. */
- if (stub_entry->stub_sec)
- {
- insn = bfd_getl32 (contents + stub_entry->target_value);
- bfd_putl32 (insn,
- stub_entry->stub_sec->contents + stub_entry->stub_offset);
- }
-
- place = (section->output_section->vma + section->output_offset
- + stub_entry->adrp_offset);
- insn = bfd_getl32 (contents + stub_entry->adrp_offset);
-
- if (!_bfd_aarch64_adrp_p (insn))
- abort ();
-
- bfd_signed_vma imm =
- (_bfd_aarch64_sign_extend
- ((bfd_vma) _bfd_aarch64_decode_adrp_imm (insn) << 12, 33)
- - (place & 0xfff));
-
- if ((htab->fix_erratum_843419 & ERRAT_ADR)
- && (imm >= AARCH64_MIN_ADRP_IMM && imm <= AARCH64_MAX_ADRP_IMM))
- {
- insn = (_bfd_aarch64_reencode_adr_imm (AARCH64_ADR_OP, imm)
- | AARCH64_RT (insn));
- bfd_putl32 (insn, contents + stub_entry->adrp_offset);
- /* Stub is not needed, don't map it out. */
- stub_entry->stub_type = aarch64_stub_none;
- }
- else if (htab->fix_erratum_843419 & ERRAT_ADRP)
- {
- bfd_vma veneered_insn_loc;
- bfd_vma veneer_entry_loc;
- bfd_signed_vma branch_offset;
- uint32_t branch_insn;
-
- veneered_insn_loc = stub_entry->target_section->output_section->vma
- + stub_entry->target_section->output_offset
- + stub_entry->target_value;
- veneer_entry_loc = stub_entry->stub_sec->output_section->vma
- + stub_entry->stub_sec->output_offset
- + stub_entry->stub_offset;
- branch_offset = veneer_entry_loc - veneered_insn_loc;
-
- abfd = stub_entry->target_section->owner;
- if (!aarch64_valid_branch_p (veneer_entry_loc, veneered_insn_loc))
- _bfd_error_handler
- (_("%pB: error: erratum 843419 stub out "
- "of range (input file too large)"), abfd);
-
- branch_insn = 0x14000000;
- branch_offset >>= 2;
- branch_offset &= 0x3ffffff;
- branch_insn |= branch_offset;
- bfd_putl32 (branch_insn, contents + stub_entry->target_value);
- }
- else
- {
- abfd = stub_entry->target_section->owner;
- _bfd_error_handler
- (_("%pB: error: erratum 843419 immediate 0x%" PRIx64
- " out of range for ADR (input file too large) and "
- "--fix-cortex-a53-843419=adr used. Run the linker with "
- "--fix-cortex-a53-843419=full instead"),
- abfd, (uint64_t) (bfd_vma) imm);
- bfd_set_error (bfd_error_bad_value);
- /* This function is called inside a hashtable traversal and the error
- handlers called above turn into non-fatal errors. Which means this
- case ld returns an exit code 0 and also produces a broken object file.
- To prevent this, issue a hard abort. */
- BFD_FAIL ();
- }
- return true;
-}
-
-
-static bool
-elfNN_aarch64_write_section (bfd *output_bfd ATTRIBUTE_UNUSED,
- struct bfd_link_info *link_info,
- asection *sec,
- bfd_byte *contents)
-
-{
- struct elf_aarch64_link_hash_table *globals =
- elf_aarch64_hash_table (link_info);
-
- if (globals == NULL)
- return false;
-
- /* Fix code to point to erratum 835769 stubs. */
- if (globals->fix_erratum_835769)
- {
- struct erratum_835769_branch_to_stub_data data;
-
- data.info = link_info;
- data.output_section = sec;
- data.contents = contents;
- bfd_hash_traverse (&globals->stub_hash_table,
- make_branch_to_erratum_835769_stub, &data);
- }
-
- if (globals->fix_erratum_843419)
- {
- struct erratum_835769_branch_to_stub_data data;
-
- data.info = link_info;
- data.output_section = sec;
- data.contents = contents;
- bfd_hash_traverse (&globals->stub_hash_table,
- _bfd_aarch64_erratum_843419_branch_to_stub, &data);
- }
-
- return false;
-}
-
-/* Return TRUE if RELOC is a relocation against the base of GOT table. */
-
-static bool
-aarch64_relocation_aginst_gp_p (bfd_reloc_code_real_type reloc)
-{
- return (reloc == BFD_RELOC_AARCH64_LD32_GOTPAGE_LO14
- || reloc == BFD_RELOC_AARCH64_LD64_GOTPAGE_LO15
- || reloc == BFD_RELOC_AARCH64_LD64_GOTOFF_LO15
- || reloc == BFD_RELOC_AARCH64_MOVW_GOTOFF_G0_NC
- || reloc == BFD_RELOC_AARCH64_MOVW_GOTOFF_G1);
-}
-
-/* Perform a relocation as part of a final link. The input relocation type
- should be TLS relaxed. */
-
-static bfd_reloc_status_type
-elfNN_aarch64_final_link_relocate (reloc_howto_type *howto,
- bfd *input_bfd,
- bfd *output_bfd,
- asection *input_section,
- bfd_byte *contents,
- Elf_Internal_Rela *rel,
- bfd_vma value,
- struct bfd_link_info *info,
- asection *sym_sec,
- struct elf_link_hash_entry *h,
- bool *unresolved_reloc_p,
- bool save_addend,
- bfd_vma *saved_addend,
- Elf_Internal_Sym *sym)
-{
- Elf_Internal_Shdr *symtab_hdr;
- unsigned int r_type = howto->type;
- bfd_reloc_code_real_type bfd_r_type
- = elfNN_aarch64_bfd_reloc_from_howto (howto);
- unsigned long r_symndx;
- bfd_byte *hit_data = contents + rel->r_offset;
- bfd_vma place, off, got_entry_addr = 0;
- bfd_signed_vma signed_addend;
- struct elf_aarch64_link_hash_table *globals;
- bool weak_undef_p;
- bool relative_reloc;
- asection *base_got;
- bfd_vma orig_value = value;
- bool resolved_to_zero;
- bool abs_symbol_p;
-
- globals = elf_aarch64_hash_table (info);
-
- symtab_hdr = &elf_symtab_hdr (input_bfd);
-
- BFD_ASSERT (is_aarch64_elf (input_bfd));
-
- r_symndx = ELFNN_R_SYM (rel->r_info);
-
- place = input_section->output_section->vma
- + input_section->output_offset + rel->r_offset;
-
- /* Get addend, accumulating the addend for consecutive relocs
- which refer to the same offset. */
- signed_addend = saved_addend ? *saved_addend : 0;
- signed_addend += rel->r_addend;
-
- weak_undef_p = (h ? h->root.type == bfd_link_hash_undefweak
- : bfd_is_und_section (sym_sec));
- abs_symbol_p = h != NULL && bfd_is_abs_symbol (&h->root);
-
-
- /* Since STT_GNU_IFUNC symbol must go through PLT, we handle
- it here if it is defined in a non-shared object. */
- if (h != NULL
- && h->type == STT_GNU_IFUNC
- && (input_section->flags & SEC_ALLOC)
- && h->def_regular)
- {
- asection *plt;
- const char *name;
- bfd_vma addend = 0;
-
- if ((input_section->flags & SEC_ALLOC) == 0)
- {
- /* If this is a SHT_NOTE section without SHF_ALLOC, treat
- STT_GNU_IFUNC symbol as STT_FUNC. */
- if (elf_section_type (input_section) == SHT_NOTE)
- goto skip_ifunc;
-
- /* Dynamic relocs are not propagated for SEC_DEBUGGING
- sections because such sections are not SEC_ALLOC and
- thus ld.so will not process them. */
- if ((input_section->flags & SEC_DEBUGGING) != 0)
- return bfd_reloc_ok;
-
- if (h->root.root.string)
- name = h->root.root.string;
- else
- name = bfd_elf_sym_name (input_bfd, symtab_hdr, sym, NULL);
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB(%pA+%#" PRIx64 "): "
- "unresolvable %s relocation against symbol `%s'"),
- input_bfd, input_section, (uint64_t) rel->r_offset,
- howto->name, name);
- bfd_set_error (bfd_error_bad_value);
- return bfd_reloc_notsupported;
- }
- else if (h->plt.offset == (bfd_vma) -1)
- goto bad_ifunc_reloc;
-
- /* STT_GNU_IFUNC symbol must go through PLT. */
- plt = globals->root.splt ? globals->root.splt : globals->root.iplt;
- value = (plt->output_section->vma + plt->output_offset + h->plt.offset);
-
- switch (bfd_r_type)
- {
- default:
- bad_ifunc_reloc:
- if (h->root.root.string)
- name = h->root.root.string;
- else
- name = bfd_elf_sym_name (input_bfd, symtab_hdr, sym,
- NULL);
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB: relocation %s against STT_GNU_IFUNC "
- "symbol `%s' isn't handled by %s"), input_bfd,
- howto->name, name, __func__);
- bfd_set_error (bfd_error_bad_value);
- return bfd_reloc_notsupported;
-
- case BFD_RELOC_AARCH64_NN:
- if (rel->r_addend != 0)
- {
- if (h->root.root.string)
- name = h->root.root.string;
- else
- name = bfd_elf_sym_name (input_bfd, symtab_hdr,
- sym, NULL);
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB: relocation %s against STT_GNU_IFUNC "
- "symbol `%s' has non-zero addend: %" PRId64),
- input_bfd, howto->name, name, (int64_t) rel->r_addend);
- bfd_set_error (bfd_error_bad_value);
- return bfd_reloc_notsupported;
- }
-
- /* Generate dynamic relocation only when there is a
- non-GOT reference in a shared object. */
- if (bfd_link_pic (info) && h->non_got_ref)
- {
- Elf_Internal_Rela outrel;
- asection *sreloc;
-
- /* Need a dynamic relocation to get the real function
- address. */
- outrel.r_offset = _bfd_elf_section_offset (output_bfd,
- info,
- input_section,
- rel->r_offset);
- if (outrel.r_offset == (bfd_vma) -1
- || outrel.r_offset == (bfd_vma) -2)
- abort ();
-
- outrel.r_offset += (input_section->output_section->vma
- + input_section->output_offset);
-
- if (h->dynindx == -1
- || h->forced_local
- || bfd_link_executable (info))
- {
- /* This symbol is resolved locally. */
- outrel.r_info = ELFNN_R_INFO (0, AARCH64_R (IRELATIVE));
- outrel.r_addend = (h->root.u.def.value
- + h->root.u.def.section->output_section->vma
- + h->root.u.def.section->output_offset);
- }
- else
- {
- outrel.r_info = ELFNN_R_INFO (h->dynindx, r_type);
- outrel.r_addend = 0;
- }
-
- sreloc = globals->root.irelifunc;
- elf_append_rela (output_bfd, sreloc, &outrel);
-
- /* If this reloc is against an external symbol, we
- do not want to fiddle with the addend. Otherwise,
- we need to include the symbol value so that it
- becomes an addend for the dynamic reloc. For an
- internal symbol, we have updated addend. */
- return bfd_reloc_ok;
- }
- /* FALLTHROUGH */
- case BFD_RELOC_AARCH64_CALL26:
- case BFD_RELOC_AARCH64_JUMP26:
- value = _bfd_aarch64_elf_resolve_relocation (input_bfd, bfd_r_type,
- place, value,
- signed_addend,
- weak_undef_p);
- return _bfd_aarch64_elf_put_addend (input_bfd, hit_data, bfd_r_type,
- howto, value);
- case BFD_RELOC_AARCH64_ADR_GOT_PAGE:
- case BFD_RELOC_AARCH64_GOT_LD_PREL19:
- case BFD_RELOC_AARCH64_LD32_GOTPAGE_LO14:
- case BFD_RELOC_AARCH64_LD32_GOT_LO12_NC:
- case BFD_RELOC_AARCH64_LD64_GOTPAGE_LO15:
- case BFD_RELOC_AARCH64_MOVW_GOTOFF_G0_NC:
- case BFD_RELOC_AARCH64_MOVW_GOTOFF_G1:
- case BFD_RELOC_AARCH64_LD64_GOTOFF_LO15:
- case BFD_RELOC_AARCH64_LD64_GOT_LO12_NC:
- base_got = globals->root.sgot;
- off = h->got.offset;
-
- if (base_got == NULL)
- abort ();
-
- if (off == (bfd_vma) -1)
- {
- bfd_vma plt_index;
-
- /* We can't use h->got.offset here to save state, or
- even just remember the offset, as finish_dynamic_symbol
- would use that as offset into .got. */
-
- if (globals->root.splt != NULL)
- {
- plt_index = ((h->plt.offset - globals->plt_header_size) /
- globals->plt_entry_size);
- off = (plt_index + 3) * GOT_ENTRY_SIZE;
- base_got = globals->root.sgotplt;
- }
- else
- {
- plt_index = h->plt.offset / globals->plt_entry_size;
- off = plt_index * GOT_ENTRY_SIZE;
- base_got = globals->root.igotplt;
- }
-
- if (h->dynindx == -1
- || h->forced_local
- || info->symbolic)
- {
- /* This references the local definition. We must
- initialize this entry in the global offset table.
- Since the offset must always be a multiple of 8,
- we use the least significant bit to record
- whether we have initialized it already.
-
- When doing a dynamic link, we create a .rela.got
- relocation entry to initialize the value. This
- is done in the finish_dynamic_symbol routine. */
- if ((off & 1) != 0)
- off &= ~1;
- else
- {
- bfd_put_NN (output_bfd, value,
- base_got->contents + off);
- /* Note that this is harmless as -1 | 1 still is -1. */
- h->got.offset |= 1;
- }
- }
- value = (base_got->output_section->vma
- + base_got->output_offset + off);
- }
- else
- value = aarch64_calculate_got_entry_vma (h, globals, info,
- value, output_bfd,
- unresolved_reloc_p);
-
- if (aarch64_relocation_aginst_gp_p (bfd_r_type))
- addend = (globals->root.sgot->output_section->vma
- + globals->root.sgot->output_offset);
-
- value = _bfd_aarch64_elf_resolve_relocation (input_bfd, bfd_r_type,
- place, value,
- addend, weak_undef_p);
- return _bfd_aarch64_elf_put_addend (input_bfd, hit_data, bfd_r_type, howto, value);
- case BFD_RELOC_AARCH64_ADD_LO12:
- case BFD_RELOC_AARCH64_ADR_HI21_PCREL:
- break;
- }
- }
-
- skip_ifunc:
- resolved_to_zero = (h != NULL
- && UNDEFWEAK_NO_DYNAMIC_RELOC (info, h));
-
- switch (bfd_r_type)
- {
- case BFD_RELOC_AARCH64_NONE:
- case BFD_RELOC_AARCH64_TLSDESC_ADD:
- case BFD_RELOC_AARCH64_TLSDESC_CALL:
- case BFD_RELOC_AARCH64_TLSDESC_LDR:
- *unresolved_reloc_p = false;
- return bfd_reloc_ok;
-
- case BFD_RELOC_AARCH64_NN:
-
- /* When generating a shared library or PIE, these relocations
- are copied into the output file to be resolved at run time. */
- if ((bfd_link_pic (info)
- && (input_section->flags & SEC_ALLOC)
- && (h == NULL
- || (ELF_ST_VISIBILITY (h->other) == STV_DEFAULT
- && !resolved_to_zero)
- || h->root.type != bfd_link_hash_undefweak))
- /* Or we are creating an executable, we may need to keep relocations
- for symbols satisfied by a dynamic library if we manage to avoid
- copy relocs for the symbol. */
- || (ELIMINATE_COPY_RELOCS
- && !bfd_link_pic (info)
- && h != NULL
- && (input_section->flags & SEC_ALLOC)
- && h->dynindx != -1
- && !h->non_got_ref
- && ((h->def_dynamic
- && !h->def_regular)
- || h->root.type == bfd_link_hash_undefweak
- || h->root.type == bfd_link_hash_undefined)))
- {
- Elf_Internal_Rela outrel;
- bfd_byte *loc;
- bool skip, relocate;
- asection *sreloc;
-
- *unresolved_reloc_p = false;
-
- skip = false;
- relocate = false;
-
- outrel.r_addend = signed_addend;
- outrel.r_offset =
- _bfd_elf_section_offset (output_bfd, info, input_section,
- rel->r_offset);
- if (outrel.r_offset == (bfd_vma) - 1)
- skip = true;
- else if (outrel.r_offset == (bfd_vma) - 2)
- {
- skip = true;
- relocate = true;
- }
- else if (abs_symbol_p)
- {
- /* Local absolute symbol. */
- skip = (h->forced_local || (h->dynindx == -1));
- relocate = skip;
- }
-
- outrel.r_offset += (input_section->output_section->vma
- + input_section->output_offset);
-
- if (skip)
- memset (&outrel, 0, sizeof outrel);
- else if (h != NULL
- && h->dynindx != -1
- && (!bfd_link_pic (info)
- || !(bfd_link_pie (info) || SYMBOLIC_BIND (info, h))
- || !h->def_regular))
- outrel.r_info = ELFNN_R_INFO (h->dynindx, r_type);
- else if (info->enable_dt_relr
- && input_section->alignment_power != 0
- && rel->r_offset % 2 == 0)
- {
- /* Don't emit a relative relocation that is packed, only
- apply the addend. */
- return _bfd_final_link_relocate (howto, input_bfd, input_section,
- contents, rel->r_offset, value,
- signed_addend);
- }
- else
- {
- int symbol;
-
- /* On SVR4-ish systems, the dynamic loader cannot
- relocate the text and data segments independently,
- so the symbol does not matter. */
- symbol = 0;
- relocate = !globals->no_apply_dynamic_relocs;
- outrel.r_info = ELFNN_R_INFO (symbol, AARCH64_R (RELATIVE));
- outrel.r_addend += value;
- }
-
- sreloc = elf_section_data (input_section)->sreloc;
- if (sreloc == NULL || sreloc->contents == NULL)
- return bfd_reloc_notsupported;
-
- loc = sreloc->contents + sreloc->reloc_count++ * RELOC_SIZE (globals);
- bfd_elfNN_swap_reloca_out (output_bfd, &outrel, loc);
-
- if (sreloc->reloc_count * RELOC_SIZE (globals) > sreloc->size)
- {
- /* Sanity to check that we have previously allocated
- sufficient space in the relocation section for the
- number of relocations we actually want to emit. */
- abort ();
- }
-
- /* If this reloc is against an external symbol, we do not want to
- fiddle with the addend. Otherwise, we need to include the symbol
- value so that it becomes an addend for the dynamic reloc. */
- if (!relocate)
- return bfd_reloc_ok;
-
- return _bfd_final_link_relocate (howto, input_bfd, input_section,
- contents, rel->r_offset, value,
- signed_addend);
- }
- else
- value += signed_addend;
- break;
-
- case BFD_RELOC_AARCH64_CALL26:
- case BFD_RELOC_AARCH64_JUMP26:
- {
- asection *splt = globals->root.splt;
- bool via_plt_p =
- splt != NULL && h != NULL && h->plt.offset != (bfd_vma) - 1;
-
- /* A call to an undefined weak symbol is converted to a jump to
- the next instruction unless a PLT entry will be created.
- The jump to the next instruction is optimized as a NOP.
- Do the same for local undefined symbols. */
- if (weak_undef_p && ! via_plt_p)
- {
- bfd_putl32 (INSN_NOP, hit_data);
- return bfd_reloc_ok;
- }
-
- /* If the call goes through a PLT entry, make sure to
- check distance to the right destination address. */
- if (via_plt_p)
- value = (splt->output_section->vma
- + splt->output_offset + h->plt.offset);
-
- /* Check if a stub has to be inserted because the destination
- is too far away. */
- struct elf_aarch64_stub_hash_entry *stub_entry = NULL;
-
- /* If the branch destination is directed to plt stub, "value" will be
- the final destination, otherwise we should plus signed_addend, it may
- contain non-zero value, for example call to local function symbol
- which are turned into "sec_sym + sec_off", and sec_off is kept in
- signed_addend. */
- if (! aarch64_valid_branch_p (via_plt_p ? value : value + signed_addend,
- place))
- /* The target is out of reach, so redirect the branch to
- the local stub for this function. */
- stub_entry = elfNN_aarch64_get_stub_entry (input_section, sym_sec, h,
- rel, globals);
- if (stub_entry != NULL)
- {
- value = (stub_entry->stub_offset
- + stub_entry->stub_sec->output_offset
- + stub_entry->stub_sec->output_section->vma);
-
- /* We have redirected the destination to stub entry address,
- so ignore any addend record in the original rela entry. */
- signed_addend = 0;
- }
- }
- value = _bfd_aarch64_elf_resolve_relocation (input_bfd, bfd_r_type,
- place, value,
- signed_addend, weak_undef_p);
- *unresolved_reloc_p = false;
- break;
-
- case BFD_RELOC_AARCH64_16_PCREL:
- case BFD_RELOC_AARCH64_32_PCREL:
- case BFD_RELOC_AARCH64_64_PCREL:
- case BFD_RELOC_AARCH64_ADR_HI21_NC_PCREL:
- case BFD_RELOC_AARCH64_ADR_HI21_PCREL:
- case BFD_RELOC_AARCH64_ADR_LO21_PCREL:
- case BFD_RELOC_AARCH64_LD_LO19_PCREL:
- case BFD_RELOC_AARCH64_MOVW_PREL_G0:
- case BFD_RELOC_AARCH64_MOVW_PREL_G0_NC:
- case BFD_RELOC_AARCH64_MOVW_PREL_G1:
- case BFD_RELOC_AARCH64_MOVW_PREL_G1_NC:
- case BFD_RELOC_AARCH64_MOVW_PREL_G2:
- case BFD_RELOC_AARCH64_MOVW_PREL_G2_NC:
- case BFD_RELOC_AARCH64_MOVW_PREL_G3:
- if (bfd_link_pic (info)
- && (input_section->flags & SEC_ALLOC) != 0
- && (input_section->flags & SEC_READONLY) != 0
- && !_bfd_elf_symbol_refs_local_p (h, info, 1))
- {
- int howto_index = bfd_r_type - BFD_RELOC_AARCH64_RELOC_START;
-
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB: relocation %s against symbol `%s' which may bind "
- "externally can not be used when making a shared object; "
- "recompile with -fPIC"),
- input_bfd, elfNN_aarch64_howto_table[howto_index].name,
- h->root.root.string);
- bfd_set_error (bfd_error_bad_value);
- return bfd_reloc_notsupported;
- }
- value = _bfd_aarch64_elf_resolve_relocation (input_bfd, bfd_r_type,
- place, value,
- signed_addend,
- weak_undef_p);
- break;
-
- case BFD_RELOC_AARCH64_BRANCH19:
- case BFD_RELOC_AARCH64_TSTBR14:
- if (h && h->root.type == bfd_link_hash_undefined)
- {
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB: conditional branch to undefined symbol `%s' "
- "not allowed"), input_bfd, h->root.root.string);
- bfd_set_error (bfd_error_bad_value);
- return bfd_reloc_notsupported;
- }
- /* Fall through. */
-
- case BFD_RELOC_AARCH64_16:
-#if ARCH_SIZE == 64
- case BFD_RELOC_AARCH64_32:
-#endif
- case BFD_RELOC_AARCH64_ADD_LO12:
- case BFD_RELOC_AARCH64_LDST128_LO12:
- case BFD_RELOC_AARCH64_LDST16_LO12:
- case BFD_RELOC_AARCH64_LDST32_LO12:
- case BFD_RELOC_AARCH64_LDST64_LO12:
- case BFD_RELOC_AARCH64_LDST8_LO12:
- case BFD_RELOC_AARCH64_MOVW_G0:
- case BFD_RELOC_AARCH64_MOVW_G0_NC:
- case BFD_RELOC_AARCH64_MOVW_G0_S:
- case BFD_RELOC_AARCH64_MOVW_G1:
- case BFD_RELOC_AARCH64_MOVW_G1_NC:
- case BFD_RELOC_AARCH64_MOVW_G1_S:
- case BFD_RELOC_AARCH64_MOVW_G2:
- case BFD_RELOC_AARCH64_MOVW_G2_NC:
- case BFD_RELOC_AARCH64_MOVW_G2_S:
- case BFD_RELOC_AARCH64_MOVW_G3:
- value = _bfd_aarch64_elf_resolve_relocation (input_bfd, bfd_r_type,
- place, value,
- signed_addend, weak_undef_p);
- break;
-
- case BFD_RELOC_AARCH64_ADR_GOT_PAGE:
- case BFD_RELOC_AARCH64_GOT_LD_PREL19:
- case BFD_RELOC_AARCH64_LD32_GOTPAGE_LO14:
- case BFD_RELOC_AARCH64_LD32_GOT_LO12_NC:
- case BFD_RELOC_AARCH64_LD64_GOTPAGE_LO15:
- case BFD_RELOC_AARCH64_LD64_GOT_LO12_NC:
- case BFD_RELOC_AARCH64_LD64_GOTOFF_LO15:
- case BFD_RELOC_AARCH64_MOVW_GOTOFF_G0_NC:
- case BFD_RELOC_AARCH64_MOVW_GOTOFF_G1:
- if (globals->root.sgot == NULL)
- BFD_ASSERT (h != NULL);
-
- relative_reloc = false;
- if (h != NULL)
- {
- bfd_vma addend = 0;
-
- /* If a symbol is not dynamic and is not undefined weak, bind it
- locally and generate a RELATIVE relocation under PIC mode.
-
- NOTE: one symbol may be referenced by several relocations, we
- should only generate one RELATIVE relocation for that symbol.
- Therefore, check GOT offset mark first. */
- if (h->dynindx == -1
- && !h->forced_local
- && h->root.type != bfd_link_hash_undefweak
- && bfd_link_pic (info)
- && !symbol_got_offset_mark_p (input_bfd, h, r_symndx))
- relative_reloc = true;
-
- value = aarch64_calculate_got_entry_vma (h, globals, info, value,
- output_bfd,
- unresolved_reloc_p);
- /* Record the GOT entry address which will be used when generating
- RELATIVE relocation. */
- if (relative_reloc)
- got_entry_addr = value;
-
- if (aarch64_relocation_aginst_gp_p (bfd_r_type))
- addend = (globals->root.sgot->output_section->vma
- + globals->root.sgot->output_offset);
- value = _bfd_aarch64_elf_resolve_relocation (input_bfd, bfd_r_type,
- place, value,
- addend, weak_undef_p);
- }
- else
- {
- bfd_vma addend = 0;
- struct elf_aarch64_local_symbol *locals
- = elf_aarch64_locals (input_bfd);
-
- if (locals == NULL)
- {
- int howto_index = bfd_r_type - BFD_RELOC_AARCH64_RELOC_START;
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB: local symbol descriptor table be NULL when applying "
- "relocation %s against local symbol"),
- input_bfd, elfNN_aarch64_howto_table[howto_index].name);
- abort ();
- }
-
- off = symbol_got_offset (input_bfd, h, r_symndx);
- base_got = globals->root.sgot;
- got_entry_addr = (base_got->output_section->vma
- + base_got->output_offset + off);
-
- if (!symbol_got_offset_mark_p (input_bfd, h, r_symndx))
- {
- bfd_put_64 (output_bfd, value, base_got->contents + off);
-
- /* For local symbol, we have done absolute relocation in static
- linking stage. While for shared library, we need to update the
- content of GOT entry according to the shared object's runtime
- base address. So, we need to generate a R_AARCH64_RELATIVE reloc
- for dynamic linker. */
- if (bfd_link_pic (info))
- relative_reloc = true;
-
- symbol_got_offset_mark (input_bfd, h, r_symndx);
- }
-
- /* Update the relocation value to GOT entry addr as we have transformed
- the direct data access into indirect data access through GOT. */
- value = got_entry_addr;
-
- if (aarch64_relocation_aginst_gp_p (bfd_r_type))
- addend = base_got->output_section->vma + base_got->output_offset;
-
- value = _bfd_aarch64_elf_resolve_relocation (input_bfd, bfd_r_type,
- place, value,
- addend, weak_undef_p);
- }
-
- /* Emit relative relocations, but not if they are packed (DT_RELR). */
- if (relative_reloc && !info->enable_dt_relr)
- {
- asection *s;
- Elf_Internal_Rela outrel;
-
- s = globals->root.srelgot;
- if (s == NULL)
- abort ();
-
- outrel.r_offset = got_entry_addr;
- outrel.r_info = ELFNN_R_INFO (0, AARCH64_R (RELATIVE));
- outrel.r_addend = orig_value;
- elf_append_rela (output_bfd, s, &outrel);
- }
- break;
-
- case BFD_RELOC_AARCH64_TLSGD_ADD_LO12_NC:
- case BFD_RELOC_AARCH64_TLSGD_ADR_PAGE21:
- case BFD_RELOC_AARCH64_TLSGD_ADR_PREL21:
- case BFD_RELOC_AARCH64_TLSIE_ADR_GOTTPREL_PAGE21:
- case BFD_RELOC_AARCH64_TLSIE_LD32_GOTTPREL_LO12_NC:
- case BFD_RELOC_AARCH64_TLSIE_LD64_GOTTPREL_LO12_NC:
- case BFD_RELOC_AARCH64_TLSIE_LD_GOTTPREL_PREL19:
- case BFD_RELOC_AARCH64_TLSLD_ADD_LO12_NC:
- case BFD_RELOC_AARCH64_TLSLD_ADR_PAGE21:
- case BFD_RELOC_AARCH64_TLSLD_ADR_PREL21:
- if (globals->root.sgot == NULL)
- return bfd_reloc_notsupported;
-
- value = (symbol_got_offset (input_bfd, h, r_symndx)
- + globals->root.sgot->output_section->vma
- + globals->root.sgot->output_offset);
-
- value = _bfd_aarch64_elf_resolve_relocation (input_bfd, bfd_r_type,
- place, value,
- 0, weak_undef_p);
- *unresolved_reloc_p = false;
- break;
-
- case BFD_RELOC_AARCH64_TLSGD_MOVW_G0_NC:
- case BFD_RELOC_AARCH64_TLSGD_MOVW_G1:
- case BFD_RELOC_AARCH64_TLSIE_MOVW_GOTTPREL_G0_NC:
- case BFD_RELOC_AARCH64_TLSIE_MOVW_GOTTPREL_G1:
- if (globals->root.sgot == NULL)
- return bfd_reloc_notsupported;
-
- value = symbol_got_offset (input_bfd, h, r_symndx);
- value = _bfd_aarch64_elf_resolve_relocation (input_bfd, bfd_r_type,
- place, value,
- 0, weak_undef_p);
- *unresolved_reloc_p = false;
- break;
-
- case BFD_RELOC_AARCH64_TLSLD_ADD_DTPREL_HI12:
- case BFD_RELOC_AARCH64_TLSLD_ADD_DTPREL_LO12:
- case BFD_RELOC_AARCH64_TLSLD_ADD_DTPREL_LO12_NC:
- case BFD_RELOC_AARCH64_TLSLD_LDST16_DTPREL_LO12:
- case BFD_RELOC_AARCH64_TLSLD_LDST16_DTPREL_LO12_NC:
- case BFD_RELOC_AARCH64_TLSLD_LDST32_DTPREL_LO12:
- case BFD_RELOC_AARCH64_TLSLD_LDST32_DTPREL_LO12_NC:
- case BFD_RELOC_AARCH64_TLSLD_LDST64_DTPREL_LO12:
- case BFD_RELOC_AARCH64_TLSLD_LDST64_DTPREL_LO12_NC:
- case BFD_RELOC_AARCH64_TLSLD_LDST8_DTPREL_LO12:
- case BFD_RELOC_AARCH64_TLSLD_LDST8_DTPREL_LO12_NC:
- case BFD_RELOC_AARCH64_TLSLD_MOVW_DTPREL_G0:
- case BFD_RELOC_AARCH64_TLSLD_MOVW_DTPREL_G0_NC:
- case BFD_RELOC_AARCH64_TLSLD_MOVW_DTPREL_G1:
- case BFD_RELOC_AARCH64_TLSLD_MOVW_DTPREL_G1_NC:
- case BFD_RELOC_AARCH64_TLSLD_MOVW_DTPREL_G2:
- {
- if (!(weak_undef_p || elf_hash_table (info)->tls_sec))
- {
- int howto_index = bfd_r_type - BFD_RELOC_AARCH64_RELOC_START;
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB: TLS relocation %s against undefined symbol `%s'"),
- input_bfd, elfNN_aarch64_howto_table[howto_index].name,
- h->root.root.string);
- bfd_set_error (bfd_error_bad_value);
- return bfd_reloc_notsupported;
- }
-
- bfd_vma def_value
- = weak_undef_p ? 0 : signed_addend - dtpoff_base (info);
- value = _bfd_aarch64_elf_resolve_relocation (input_bfd, bfd_r_type,
- place, value,
- def_value, weak_undef_p);
- break;
- }
-
- case BFD_RELOC_AARCH64_TLSLE_ADD_TPREL_HI12:
- case BFD_RELOC_AARCH64_TLSLE_ADD_TPREL_LO12:
- case BFD_RELOC_AARCH64_TLSLE_ADD_TPREL_LO12_NC:
- case BFD_RELOC_AARCH64_TLSLE_LDST16_TPREL_LO12:
- case BFD_RELOC_AARCH64_TLSLE_LDST16_TPREL_LO12_NC:
- case BFD_RELOC_AARCH64_TLSLE_LDST32_TPREL_LO12:
- case BFD_RELOC_AARCH64_TLSLE_LDST32_TPREL_LO12_NC:
- case BFD_RELOC_AARCH64_TLSLE_LDST64_TPREL_LO12:
- case BFD_RELOC_AARCH64_TLSLE_LDST64_TPREL_LO12_NC:
- case BFD_RELOC_AARCH64_TLSLE_LDST8_TPREL_LO12:
- case BFD_RELOC_AARCH64_TLSLE_LDST8_TPREL_LO12_NC:
- case BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G0:
- case BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G0_NC:
- case BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G1:
- case BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G1_NC:
- case BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G2:
- {
- if (!(weak_undef_p || elf_hash_table (info)->tls_sec))
- {
- int howto_index = bfd_r_type - BFD_RELOC_AARCH64_RELOC_START;
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB: TLS relocation %s against undefined symbol `%s'"),
- input_bfd, elfNN_aarch64_howto_table[howto_index].name,
- h->root.root.string);
- bfd_set_error (bfd_error_bad_value);
- return bfd_reloc_notsupported;
- }
-
- bfd_vma def_value
- = weak_undef_p ? 0 : signed_addend - tpoff_base (info);
- value = _bfd_aarch64_elf_resolve_relocation (input_bfd, bfd_r_type,
- place, value,
- def_value, weak_undef_p);
- *unresolved_reloc_p = false;
- break;
- }
-
- case BFD_RELOC_AARCH64_TLSDESC_ADD_LO12:
- case BFD_RELOC_AARCH64_TLSDESC_ADR_PAGE21:
- case BFD_RELOC_AARCH64_TLSDESC_ADR_PREL21:
- case BFD_RELOC_AARCH64_TLSDESC_LD32_LO12_NC:
- case BFD_RELOC_AARCH64_TLSDESC_LD64_LO12:
- case BFD_RELOC_AARCH64_TLSDESC_LD_PREL19:
- if (globals->root.sgot == NULL)
- return bfd_reloc_notsupported;
- value = (symbol_tlsdesc_got_offset (input_bfd, h, r_symndx)
- + globals->root.sgotplt->output_section->vma
- + globals->root.sgotplt->output_offset
- + globals->sgotplt_jump_table_size);
-
- value = _bfd_aarch64_elf_resolve_relocation (input_bfd, bfd_r_type,
- place, value,
- 0, weak_undef_p);
- *unresolved_reloc_p = false;
- break;
-
- case BFD_RELOC_AARCH64_TLSDESC_OFF_G0_NC:
- case BFD_RELOC_AARCH64_TLSDESC_OFF_G1:
- if (globals->root.sgot == NULL)
- return bfd_reloc_notsupported;
-
- value = (symbol_tlsdesc_got_offset (input_bfd, h, r_symndx)
- + globals->root.sgotplt->output_section->vma
- + globals->root.sgotplt->output_offset
- + globals->sgotplt_jump_table_size);
-
- value -= (globals->root.sgot->output_section->vma
- + globals->root.sgot->output_offset);
-
- value = _bfd_aarch64_elf_resolve_relocation (input_bfd, bfd_r_type,
- place, value,
- 0, weak_undef_p);
- *unresolved_reloc_p = false;
- break;
-
- default:
- return bfd_reloc_notsupported;
- }
-
- if (saved_addend)
- *saved_addend = value;
-
- /* Only apply the final relocation in a sequence. */
- if (save_addend)
- return bfd_reloc_continue;
-
- return _bfd_aarch64_elf_put_addend (input_bfd, hit_data, bfd_r_type,
- howto, value);
-}
-
-/* LP64 and ILP32 operates on x- and w-registers respectively.
- Next definitions take into account the difference between
- corresponding machine codes. R means x-register if the target
- arch is LP64, and w-register if the target is ILP32. */
-
-#if ARCH_SIZE == 64
-# define add_R0_R0 (0x91000000)
-# define add_R0_R0_R1 (0x8b000020)
-# define add_R0_R1 (0x91400020)
-# define ldr_R0 (0x58000000)
-# define ldr_R0_mask(i) (i & 0xffffffe0)
-# define ldr_R0_x0 (0xf9400000)
-# define ldr_hw_R0 (0xf2a00000)
-# define movk_R0 (0xf2800000)
-# define movz_R0 (0xd2a00000)
-# define movz_hw_R0 (0xd2c00000)
-#else /*ARCH_SIZE == 32 */
-# define add_R0_R0 (0x11000000)
-# define add_R0_R0_R1 (0x0b000020)
-# define add_R0_R1 (0x11400020)
-# define ldr_R0 (0x18000000)
-# define ldr_R0_mask(i) (i & 0xbfffffe0)
-# define ldr_R0_x0 (0xb9400000)
-# define ldr_hw_R0 (0x72a00000)
-# define movk_R0 (0x72800000)
-# define movz_R0 (0x52a00000)
-# define movz_hw_R0 (0x52c00000)
-#endif
-
-/* Structure to hold payload for _bfd_aarch64_erratum_843419_clear_stub,
- it is used to identify the stub information to reset. */
-
-struct erratum_843419_branch_to_stub_clear_data
-{
- bfd_vma adrp_offset;
- asection *output_section;
-};
-
-/* Clear the erratum information for GEN_ENTRY if the ADRP_OFFSET and
- section inside IN_ARG matches. The clearing is done by setting the
- stub_type to none. */
-
-static bool
-_bfd_aarch64_erratum_843419_clear_stub (struct bfd_hash_entry *gen_entry,
- void *in_arg)
-{
- struct elf_aarch64_stub_hash_entry *stub_entry
- = (struct elf_aarch64_stub_hash_entry *) gen_entry;
- struct erratum_843419_branch_to_stub_clear_data *data
- = (struct erratum_843419_branch_to_stub_clear_data *) in_arg;
-
- if (stub_entry->target_section != data->output_section
- || stub_entry->stub_type != aarch64_stub_erratum_843419_veneer
- || stub_entry->adrp_offset != data->adrp_offset)
- return true;
-
- /* Change the stub type instead of removing the entry, removing from the hash
- table would be slower and we have already reserved the memory for the entry
- so there wouldn't be much gain. Changing the stub also keeps around a
- record of what was there before. */
- stub_entry->stub_type = aarch64_stub_none;
-
- /* We're done and there could have been only one matching stub at that
- particular offset, so abort further traversal. */
- return false;
-}
-
-/* TLS Relaxations may relax an adrp sequence that matches the erratum 843419
- sequence. In this case the erratum no longer applies and we need to remove
- the entry from the pending stub generation. This clears matching adrp insn
- at ADRP_OFFSET in INPUT_SECTION in the stub table defined in GLOBALS. */
-
-static void
-clear_erratum_843419_entry (struct elf_aarch64_link_hash_table *globals,
- bfd_vma adrp_offset, asection *input_section)
-{
- if (globals->fix_erratum_843419 & ERRAT_ADRP)
- {
- struct erratum_843419_branch_to_stub_clear_data data;
- data.adrp_offset = adrp_offset;
- data.output_section = input_section;
-
- bfd_hash_traverse (&globals->stub_hash_table,
- _bfd_aarch64_erratum_843419_clear_stub, &data);
- }
-}
-
-/* Handle TLS relaxations. Relaxing is possible for symbols that use
- R_AARCH64_TLSDESC_ADR_{PAGE, LD64_LO12_NC, ADD_LO12_NC} during a static
- link.
-
- Return bfd_reloc_ok if we're done, bfd_reloc_continue if the caller
- is to then call final_link_relocate. Return other values in the
- case of error. */
-
-static bfd_reloc_status_type
-elfNN_aarch64_tls_relax (struct elf_aarch64_link_hash_table *globals,
- bfd *input_bfd, asection *input_section,
- bfd_byte *contents, Elf_Internal_Rela *rel,
- struct elf_link_hash_entry *h,
- struct bfd_link_info *info)
-{
- bool local_exec = bfd_link_executable (info)
- && SYMBOL_REFERENCES_LOCAL (info, h);
- unsigned int r_type = ELFNN_R_TYPE (rel->r_info);
- unsigned long insn;
-
- BFD_ASSERT (globals && input_bfd && contents && rel);
-
- switch (elfNN_aarch64_bfd_reloc_from_type (input_bfd, r_type))
- {
- case BFD_RELOC_AARCH64_TLSDESC_ADR_PAGE21:
- case BFD_RELOC_AARCH64_TLSGD_ADR_PAGE21:
- if (local_exec)
- {
- /* GD->LE relaxation:
- adrp x0, :tlsgd:var => movz R0, :tprel_g1:var
- or
- adrp x0, :tlsdesc:var => movz R0, :tprel_g1:var
-
- Where R is x for LP64, and w for ILP32. */
- bfd_putl32 (movz_R0, contents + rel->r_offset);
- /* We have relaxed the adrp into a mov, we may have to clear any
- pending erratum fixes. */
- clear_erratum_843419_entry (globals, rel->r_offset, input_section);
- return bfd_reloc_continue;
- }
- else
- {
- /* GD->IE relaxation:
- adrp x0, :tlsgd:var => adrp x0, :gottprel:var
- or
- adrp x0, :tlsdesc:var => adrp x0, :gottprel:var
- */
- return bfd_reloc_continue;
- }
-
- case BFD_RELOC_AARCH64_TLSDESC_ADR_PREL21:
- BFD_ASSERT (0);
- break;
-
- case BFD_RELOC_AARCH64_TLSDESC_LD_PREL19:
- if (local_exec)
- {
- /* Tiny TLSDESC->LE relaxation:
- ldr x1, :tlsdesc:var => movz R0, #:tprel_g1:var
- adr x0, :tlsdesc:var => movk R0, #:tprel_g0_nc:var
- .tlsdesccall var
- blr x1 => nop
-
- Where R is x for LP64, and w for ILP32. */
- BFD_ASSERT (ELFNN_R_TYPE (rel[1].r_info) == AARCH64_R (TLSDESC_ADR_PREL21));
- BFD_ASSERT (ELFNN_R_TYPE (rel[2].r_info) == AARCH64_R (TLSDESC_CALL));
-
- rel[1].r_info = ELFNN_R_INFO (ELFNN_R_SYM (rel->r_info),
- AARCH64_R (TLSLE_MOVW_TPREL_G0_NC));
- rel[2].r_info = ELFNN_R_INFO (STN_UNDEF, R_AARCH64_NONE);
-
- bfd_putl32 (movz_R0, contents + rel->r_offset);
- bfd_putl32 (movk_R0, contents + rel->r_offset + 4);
- bfd_putl32 (INSN_NOP, contents + rel->r_offset + 8);
- return bfd_reloc_continue;
- }
- else
- {
- /* Tiny TLSDESC->IE relaxation:
- ldr x1, :tlsdesc:var => ldr x0, :gottprel:var
- adr x0, :tlsdesc:var => nop
- .tlsdesccall var
- blr x1 => nop
- */
- BFD_ASSERT (ELFNN_R_TYPE (rel[1].r_info) == AARCH64_R (TLSDESC_ADR_PREL21));
- BFD_ASSERT (ELFNN_R_TYPE (rel[2].r_info) == AARCH64_R (TLSDESC_CALL));
-
- rel[1].r_info = ELFNN_R_INFO (STN_UNDEF, R_AARCH64_NONE);
- rel[2].r_info = ELFNN_R_INFO (STN_UNDEF, R_AARCH64_NONE);
-
- bfd_putl32 (ldr_R0, contents + rel->r_offset);
- bfd_putl32 (INSN_NOP, contents + rel->r_offset + 4);
- bfd_putl32 (INSN_NOP, contents + rel->r_offset + 8);
- return bfd_reloc_continue;
- }
-
- case BFD_RELOC_AARCH64_TLSGD_ADR_PREL21:
- if (local_exec)
- {
- /* Tiny GD->LE relaxation:
- adr x0, :tlsgd:var => mrs x1, tpidr_el0
- bl __tls_get_addr => add R0, R1, #:tprel_hi12:x, lsl #12
- nop => add R0, R0, #:tprel_lo12_nc:x
-
- Where R is x for LP64, and x for Ilp32. */
-
- /* First kill the tls_get_addr reloc on the bl instruction. */
- BFD_ASSERT (rel->r_offset + 4 == rel[1].r_offset);
-
- bfd_putl32 (0xd53bd041, contents + rel->r_offset + 0);
- bfd_putl32 (add_R0_R1, contents + rel->r_offset + 4);
- bfd_putl32 (add_R0_R0, contents + rel->r_offset + 8);
-
- rel[1].r_info = ELFNN_R_INFO (ELFNN_R_SYM (rel->r_info),
- AARCH64_R (TLSLE_ADD_TPREL_LO12_NC));
- rel[1].r_offset = rel->r_offset + 8;
-
- /* Move the current relocation to the second instruction in
- the sequence. */
- rel->r_offset += 4;
- rel->r_info = ELFNN_R_INFO (ELFNN_R_SYM (rel->r_info),
- AARCH64_R (TLSLE_ADD_TPREL_HI12));
- return bfd_reloc_continue;
- }
- else
- {
- /* Tiny GD->IE relaxation:
- adr x0, :tlsgd:var => ldr R0, :gottprel:var
- bl __tls_get_addr => mrs x1, tpidr_el0
- nop => add R0, R0, R1
-
- Where R is x for LP64, and w for Ilp32. */
-
- /* First kill the tls_get_addr reloc on the bl instruction. */
- BFD_ASSERT (rel->r_offset + 4 == rel[1].r_offset);
- rel[1].r_info = ELFNN_R_INFO (STN_UNDEF, R_AARCH64_NONE);
-
- bfd_putl32 (ldr_R0, contents + rel->r_offset);
- bfd_putl32 (0xd53bd041, contents + rel->r_offset + 4);
- bfd_putl32 (add_R0_R0_R1, contents + rel->r_offset + 8);
- return bfd_reloc_continue;
- }
-
-#if ARCH_SIZE == 64
- case BFD_RELOC_AARCH64_TLSGD_MOVW_G1:
- BFD_ASSERT (ELFNN_R_TYPE (rel[1].r_info) == AARCH64_R (TLSGD_MOVW_G0_NC));
- BFD_ASSERT (rel->r_offset + 12 == rel[2].r_offset);
- BFD_ASSERT (ELFNN_R_TYPE (rel[2].r_info) == AARCH64_R (CALL26));
-
- if (local_exec)
- {
- /* Large GD->LE relaxation:
- movz x0, #:tlsgd_g1:var => movz x0, #:tprel_g2:var, lsl #32
- movk x0, #:tlsgd_g0_nc:var => movk x0, #:tprel_g1_nc:var, lsl #16
- add x0, gp, x0 => movk x0, #:tprel_g0_nc:var
- bl __tls_get_addr => mrs x1, tpidr_el0
- nop => add x0, x0, x1
- */
- rel[2].r_info = ELFNN_R_INFO (ELFNN_R_SYM (rel->r_info),
- AARCH64_R (TLSLE_MOVW_TPREL_G0_NC));
- rel[2].r_offset = rel->r_offset + 8;
-
- bfd_putl32 (movz_hw_R0, contents + rel->r_offset + 0);
- bfd_putl32 (ldr_hw_R0, contents + rel->r_offset + 4);
- bfd_putl32 (movk_R0, contents + rel->r_offset + 8);
- bfd_putl32 (0xd53bd041, contents + rel->r_offset + 12);
- bfd_putl32 (add_R0_R0_R1, contents + rel->r_offset + 16);
- }
- else
- {
- /* Large GD->IE relaxation:
- movz x0, #:tlsgd_g1:var => movz x0, #:gottprel_g1:var, lsl #16
- movk x0, #:tlsgd_g0_nc:var => movk x0, #:gottprel_g0_nc:var
- add x0, gp, x0 => ldr x0, [gp, x0]
- bl __tls_get_addr => mrs x1, tpidr_el0
- nop => add x0, x0, x1
- */
- rel[2].r_info = ELFNN_R_INFO (STN_UNDEF, R_AARCH64_NONE);
- bfd_putl32 (0xd2a80000, contents + rel->r_offset + 0);
- bfd_putl32 (ldr_R0, contents + rel->r_offset + 8);
- bfd_putl32 (0xd53bd041, contents + rel->r_offset + 12);
- bfd_putl32 (add_R0_R0_R1, contents + rel->r_offset + 16);
- }
- return bfd_reloc_continue;
-
- case BFD_RELOC_AARCH64_TLSGD_MOVW_G0_NC:
- return bfd_reloc_continue;
-#endif
-
- case BFD_RELOC_AARCH64_TLSIE_LD_GOTTPREL_PREL19:
- return bfd_reloc_continue;
-
- case BFD_RELOC_AARCH64_TLSDESC_LDNN_LO12_NC:
- if (local_exec)
- {
- /* GD->LE relaxation:
- ldr xd, [x0, #:tlsdesc_lo12:var] => movk x0, :tprel_g0_nc:var
-
- Where R is x for lp64 mode, and w for ILP32 mode. */
- bfd_putl32 (movk_R0, contents + rel->r_offset);
- return bfd_reloc_continue;
- }
- else
- {
- /* GD->IE relaxation:
- ldr xd, [x0, #:tlsdesc_lo12:var] => ldr R0, [x0, #:gottprel_lo12:var]
-
- Where R is x for lp64 mode, and w for ILP32 mode. */
- insn = bfd_getl32 (contents + rel->r_offset);
- bfd_putl32 (ldr_R0_mask (insn), contents + rel->r_offset);
- return bfd_reloc_continue;
- }
-
- case BFD_RELOC_AARCH64_TLSGD_ADD_LO12_NC:
- if (local_exec)
- {
- /* GD->LE relaxation
- add x0, #:tlsgd_lo12:var => movk R0, :tprel_g0_nc:var
- bl __tls_get_addr => mrs x1, tpidr_el0
- nop => add R0, R1, R0
-
- Where R is x for lp64 mode, and w for ILP32 mode. */
-
- /* First kill the tls_get_addr reloc on the bl instruction. */
- BFD_ASSERT (rel->r_offset + 4 == rel[1].r_offset);
- rel[1].r_info = ELFNN_R_INFO (STN_UNDEF, R_AARCH64_NONE);
-
- bfd_putl32 (movk_R0, contents + rel->r_offset);
- bfd_putl32 (0xd53bd041, contents + rel->r_offset + 4);
- bfd_putl32 (add_R0_R0_R1, contents + rel->r_offset + 8);
- return bfd_reloc_continue;
- }
- else
- {
- /* GD->IE relaxation
- ADD x0, #:tlsgd_lo12:var => ldr R0, [x0, #:gottprel_lo12:var]
- BL __tls_get_addr => mrs x1, tpidr_el0
- R_AARCH64_CALL26
- NOP => add R0, R1, R0
-
- Where R is x for lp64 mode, and w for ilp32 mode. */
-
- BFD_ASSERT (ELFNN_R_TYPE (rel[1].r_info) == AARCH64_R (CALL26));
-
- /* Remove the relocation on the BL instruction. */
- rel[1].r_info = ELFNN_R_INFO (STN_UNDEF, R_AARCH64_NONE);
-
- /* We choose to fixup the BL and NOP instructions using the
- offset from the second relocation to allow flexibility in
- scheduling instructions between the ADD and BL. */
- bfd_putl32 (ldr_R0_x0, contents + rel->r_offset);
- bfd_putl32 (0xd53bd041, contents + rel[1].r_offset);
- bfd_putl32 (add_R0_R0_R1, contents + rel[1].r_offset + 4);
- return bfd_reloc_continue;
- }
-
- case BFD_RELOC_AARCH64_TLSDESC_ADD:
- case BFD_RELOC_AARCH64_TLSDESC_ADD_LO12:
- case BFD_RELOC_AARCH64_TLSDESC_CALL:
- /* GD->IE/LE relaxation:
- add x0, x0, #:tlsdesc_lo12:var => nop
- blr xd => nop
- */
- bfd_putl32 (INSN_NOP, contents + rel->r_offset);
- return bfd_reloc_ok;
-
- case BFD_RELOC_AARCH64_TLSDESC_LDR:
- if (local_exec)
- {
- /* GD->LE relaxation:
- ldr xd, [gp, xn] => movk R0, #:tprel_g0_nc:var
-
- Where R is x for lp64 mode, and w for ILP32 mode. */
- bfd_putl32 (movk_R0, contents + rel->r_offset);
- return bfd_reloc_continue;
- }
- else
- {
- /* GD->IE relaxation:
- ldr xd, [gp, xn] => ldr R0, [gp, xn]
-
- Where R is x for lp64 mode, and w for ILP32 mode. */
- insn = bfd_getl32 (contents + rel->r_offset);
- bfd_putl32 (ldr_R0_mask (insn), contents + rel->r_offset);
- return bfd_reloc_ok;
- }
-
- case BFD_RELOC_AARCH64_TLSDESC_OFF_G0_NC:
- /* GD->LE relaxation:
- movk xd, #:tlsdesc_off_g0_nc:var => movk R0, #:tprel_g1_nc:var, lsl #16
- GD->IE relaxation:
- movk xd, #:tlsdesc_off_g0_nc:var => movk Rd, #:gottprel_g0_nc:var
-
- Where R is x for lp64 mode, and w for ILP32 mode. */
- if (local_exec)
- bfd_putl32 (ldr_hw_R0, contents + rel->r_offset);
- return bfd_reloc_continue;
-
- case BFD_RELOC_AARCH64_TLSDESC_OFF_G1:
- if (local_exec)
- {
- /* GD->LE relaxation:
- movz xd, #:tlsdesc_off_g1:var => movz R0, #:tprel_g2:var, lsl #32
-
- Where R is x for lp64 mode, and w for ILP32 mode. */
- bfd_putl32 (movz_hw_R0, contents + rel->r_offset);
- return bfd_reloc_continue;
- }
- else
- {
- /* GD->IE relaxation:
- movz xd, #:tlsdesc_off_g1:var => movz Rd, #:gottprel_g1:var, lsl #16
-
- Where R is x for lp64 mode, and w for ILP32 mode. */
- insn = bfd_getl32 (contents + rel->r_offset);
- bfd_putl32 (movz_R0 | (insn & 0x1f), contents + rel->r_offset);
- return bfd_reloc_continue;
- }
-
- case BFD_RELOC_AARCH64_TLSIE_ADR_GOTTPREL_PAGE21:
- /* IE->LE relaxation:
- adrp xd, :gottprel:var => movz Rd, :tprel_g1:var
-
- Where R is x for lp64 mode, and w for ILP32 mode. */
- if (local_exec)
- {
- insn = bfd_getl32 (contents + rel->r_offset);
- bfd_putl32 (movz_R0 | (insn & 0x1f), contents + rel->r_offset);
- /* We have relaxed the adrp into a mov, we may have to clear any
- pending erratum fixes. */
- clear_erratum_843419_entry (globals, rel->r_offset, input_section);
- }
- return bfd_reloc_continue;
-
- case BFD_RELOC_AARCH64_TLSIE_LDNN_GOTTPREL_LO12_NC:
- /* IE->LE relaxation:
- ldr xd, [xm, #:gottprel_lo12:var] => movk Rd, :tprel_g0_nc:var
-
- Where R is x for lp64 mode, and w for ILP32 mode. */
- if (local_exec)
- {
- insn = bfd_getl32 (contents + rel->r_offset);
- bfd_putl32 (movk_R0 | (insn & 0x1f), contents + rel->r_offset);
- }
- return bfd_reloc_continue;
-
- case BFD_RELOC_AARCH64_TLSLD_ADR_PREL21:
- /* LD->LE relaxation (tiny):
- adr x0, :tlsldm:x => mrs x0, tpidr_el0
- bl __tls_get_addr => add R0, R0, TCB_SIZE
-
- Where R is x for lp64 mode, and w for ilp32 mode. */
- if (local_exec)
- {
- BFD_ASSERT (rel->r_offset + 4 == rel[1].r_offset);
- BFD_ASSERT (ELFNN_R_TYPE (rel[1].r_info) == AARCH64_R (CALL26));
- /* No need of CALL26 relocation for tls_get_addr. */
- rel[1].r_info = ELFNN_R_INFO (STN_UNDEF, R_AARCH64_NONE);
- bfd_putl32 (0xd53bd040, contents + rel->r_offset + 0);
- bfd_putl32 (add_R0_R0 | (TCB_SIZE << 10),
- contents + rel->r_offset + 4);
- return bfd_reloc_ok;
- }
- return bfd_reloc_continue;
-
- case BFD_RELOC_AARCH64_TLSLD_ADR_PAGE21:
- /* LD->LE relaxation (small):
- adrp x0, :tlsldm:x => mrs x0, tpidr_el0
- */
- if (local_exec)
- {
- bfd_putl32 (0xd53bd040, contents + rel->r_offset);
- return bfd_reloc_ok;
- }
- return bfd_reloc_continue;
-
- case BFD_RELOC_AARCH64_TLSLD_ADD_LO12_NC:
- /* LD->LE relaxation (small):
- add x0, #:tlsldm_lo12:x => add R0, R0, TCB_SIZE
- bl __tls_get_addr => nop
-
- Where R is x for lp64 mode, and w for ilp32 mode. */
- if (local_exec)
- {
- BFD_ASSERT (rel->r_offset + 4 == rel[1].r_offset);
- BFD_ASSERT (ELFNN_R_TYPE (rel[1].r_info) == AARCH64_R (CALL26));
- /* No need of CALL26 relocation for tls_get_addr. */
- rel[1].r_info = ELFNN_R_INFO (STN_UNDEF, R_AARCH64_NONE);
- bfd_putl32 (add_R0_R0 | (TCB_SIZE << 10),
- contents + rel->r_offset + 0);
- bfd_putl32 (INSN_NOP, contents + rel->r_offset + 4);
- return bfd_reloc_ok;
- }
- return bfd_reloc_continue;
-
- default:
- return bfd_reloc_continue;
- }
-
- return bfd_reloc_ok;
-}
-
-/* Relocate an AArch64 ELF section. */
-
-static int
-elfNN_aarch64_relocate_section (bfd *output_bfd,
- struct bfd_link_info *info,
- bfd *input_bfd,
- asection *input_section,
- bfd_byte *contents,
- Elf_Internal_Rela *relocs,
- Elf_Internal_Sym *local_syms,
- asection **local_sections)
-{
- Elf_Internal_Shdr *symtab_hdr;
- struct elf_link_hash_entry **sym_hashes;
- Elf_Internal_Rela *rel;
- Elf_Internal_Rela *relend;
- const char *name;
- struct elf_aarch64_link_hash_table *globals;
- bool save_addend = false;
- bfd_vma addend = 0;
-
- globals = elf_aarch64_hash_table (info);
-
- symtab_hdr = &elf_symtab_hdr (input_bfd);
- sym_hashes = elf_sym_hashes (input_bfd);
-
- rel = relocs;
- relend = relocs + input_section->reloc_count;
- for (; rel < relend; rel++)
- {
- unsigned int r_type;
- bfd_reloc_code_real_type bfd_r_type;
- bfd_reloc_code_real_type relaxed_bfd_r_type;
- reloc_howto_type *howto;
- unsigned long r_symndx;
- Elf_Internal_Sym *sym;
- asection *sec;
- struct elf_link_hash_entry *h;
- bfd_vma relocation;
- bfd_reloc_status_type r;
- arelent bfd_reloc;
- char sym_type;
- bool unresolved_reloc = false;
- char *error_message = NULL;
-
- r_symndx = ELFNN_R_SYM (rel->r_info);
- r_type = ELFNN_R_TYPE (rel->r_info);
-
- bfd_reloc.howto = elfNN_aarch64_howto_from_type (input_bfd, r_type);
- howto = bfd_reloc.howto;
-
- if (howto == NULL)
- return _bfd_unrecognized_reloc (input_bfd, input_section, r_type);
-
- bfd_r_type = elfNN_aarch64_bfd_reloc_from_howto (howto);
-
- h = NULL;
- sym = NULL;
- sec = NULL;
-
- if (r_symndx < symtab_hdr->sh_info)
- {
- sym = local_syms + r_symndx;
- sym_type = ELFNN_ST_TYPE (sym->st_info);
- sec = local_sections[r_symndx];
-
- /* An object file might have a reference to a local
- undefined symbol. This is a daft object file, but we
- should at least do something about it. NONE and NULL
- relocations do not use the symbol and are explicitly
- allowed to use an undefined one, so allow those.
- Likewise for relocations against STN_UNDEF. */
- if (r_type != R_AARCH64_NONE && r_type != R_AARCH64_NULL
- && r_symndx != STN_UNDEF
- && bfd_is_und_section (sec)
- && ELF_ST_BIND (sym->st_info) != STB_WEAK)
- (*info->callbacks->undefined_symbol)
- (info, bfd_elf_string_from_elf_section
- (input_bfd, symtab_hdr->sh_link, sym->st_name),
- input_bfd, input_section, rel->r_offset, true);
-
- relocation = _bfd_elf_rela_local_sym (output_bfd, sym, &sec, rel);
-
- /* Relocate against local STT_GNU_IFUNC symbol. */
- if (!bfd_link_relocatable (info)
- && ELF_ST_TYPE (sym->st_info) == STT_GNU_IFUNC)
- {
- h = elfNN_aarch64_get_local_sym_hash (globals, input_bfd,
- rel, false);
- if (h == NULL)
- abort ();
-
- /* Set STT_GNU_IFUNC symbol value. */
- h->root.u.def.value = sym->st_value;
- h->root.u.def.section = sec;
- }
- }
- else
- {
- bool warned, ignored;
-
- RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
- r_symndx, symtab_hdr, sym_hashes,
- h, sec, relocation,
- unresolved_reloc, warned, ignored);
-
- sym_type = h->type;
- }
-
- if (sec != NULL && discarded_section (sec))
- RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
- rel, 1, relend, howto, 0, contents);
-
- if (bfd_link_relocatable (info))
- continue;
-
- if (h != NULL)
- name = h->root.root.string;
- else
- {
- name = (bfd_elf_string_from_elf_section
- (input_bfd, symtab_hdr->sh_link, sym->st_name));
- if (name == NULL || *name == '\0')
- name = bfd_section_name (sec);
- }
-
- if (r_symndx != 0
- && r_type != R_AARCH64_NONE
- && r_type != R_AARCH64_NULL
- && (h == NULL
- || h->root.type == bfd_link_hash_defined
- || h->root.type == bfd_link_hash_defweak)
- && IS_AARCH64_TLS_RELOC (bfd_r_type) != (sym_type == STT_TLS))
- {
- _bfd_error_handler
- ((sym_type == STT_TLS
- /* xgettext:c-format */
- ? _("%pB(%pA+%#" PRIx64 "): %s used with TLS symbol %s")
- /* xgettext:c-format */
- : _("%pB(%pA+%#" PRIx64 "): %s used with non-TLS symbol %s")),
- input_bfd,
- input_section, (uint64_t) rel->r_offset, howto->name, name);
- }
-
- /* We relax only if we can see that there can be a valid transition
- from a reloc type to another.
- We call elfNN_aarch64_final_link_relocate unless we're completely
- done, i.e., the relaxation produced the final output we want. */
-
- relaxed_bfd_r_type = aarch64_tls_transition (input_bfd, info, r_type,
- h, r_symndx);
- if (relaxed_bfd_r_type != bfd_r_type)
- {
- bfd_r_type = relaxed_bfd_r_type;
- howto = elfNN_aarch64_howto_from_bfd_reloc (bfd_r_type);
- BFD_ASSERT (howto != NULL);
- r_type = howto->type;
- r = elfNN_aarch64_tls_relax (globals, input_bfd, input_section,
- contents, rel, h, info);
- unresolved_reloc = 0;
- }
- else
- r = bfd_reloc_continue;
-
- /* There may be multiple consecutive relocations for the
- same offset. In that case we are supposed to treat the
- output of each relocation as the addend for the next. */
- if (rel + 1 < relend
- && rel->r_offset == rel[1].r_offset
- && ELFNN_R_TYPE (rel[1].r_info) != R_AARCH64_NONE
- && ELFNN_R_TYPE (rel[1].r_info) != R_AARCH64_NULL)
- save_addend = true;
- else
- save_addend = false;
-
- if (r == bfd_reloc_continue)
- r = elfNN_aarch64_final_link_relocate (howto, input_bfd, output_bfd,
- input_section, contents, rel,
- relocation, info, sec,
- h, &unresolved_reloc,
- save_addend, &addend, sym);
-
- switch (elfNN_aarch64_bfd_reloc_from_type (input_bfd, r_type))
- {
- case BFD_RELOC_AARCH64_TLSGD_ADD_LO12_NC:
- case BFD_RELOC_AARCH64_TLSGD_ADR_PAGE21:
- case BFD_RELOC_AARCH64_TLSGD_ADR_PREL21:
- case BFD_RELOC_AARCH64_TLSGD_MOVW_G0_NC:
- case BFD_RELOC_AARCH64_TLSGD_MOVW_G1:
- case BFD_RELOC_AARCH64_TLSLD_ADD_LO12_NC:
- case BFD_RELOC_AARCH64_TLSLD_ADR_PAGE21:
- case BFD_RELOC_AARCH64_TLSLD_ADR_PREL21:
- if (! symbol_got_offset_mark_p (input_bfd, h, r_symndx))
- {
- bool need_relocs = false;
- bfd_byte *loc;
- int indx;
- bfd_vma off;
-
- off = symbol_got_offset (input_bfd, h, r_symndx);
- indx = h && h->dynindx != -1 ? h->dynindx : 0;
-
- need_relocs =
- (!bfd_link_executable (info) || indx != 0) &&
- (h == NULL
- || ELF_ST_VISIBILITY (h->other) == STV_DEFAULT
- || h->root.type != bfd_link_hash_undefweak);
-
- BFD_ASSERT (globals->root.srelgot != NULL);
-
- if (need_relocs)
- {
- Elf_Internal_Rela rela;
- rela.r_info = ELFNN_R_INFO (indx, AARCH64_R (TLS_DTPMOD));
- rela.r_addend = 0;
- rela.r_offset = globals->root.sgot->output_section->vma +
- globals->root.sgot->output_offset + off;
-
-
- loc = globals->root.srelgot->contents;
- loc += globals->root.srelgot->reloc_count++
- * RELOC_SIZE (htab);
- bfd_elfNN_swap_reloca_out (output_bfd, &rela, loc);
-
- bfd_reloc_code_real_type real_type =
- elfNN_aarch64_bfd_reloc_from_type (input_bfd, r_type);
-
- if (real_type == BFD_RELOC_AARCH64_TLSLD_ADR_PREL21
- || real_type == BFD_RELOC_AARCH64_TLSLD_ADR_PAGE21
- || real_type == BFD_RELOC_AARCH64_TLSLD_ADD_LO12_NC)
- {
- /* For local dynamic, don't generate DTPREL in any case.
- Initialize the DTPREL slot into zero, so we get module
- base address when invoke runtime TLS resolver. */
- bfd_put_NN (output_bfd, 0,
- globals->root.sgot->contents + off
- + GOT_ENTRY_SIZE);
- }
- else if (indx == 0)
- {
- bfd_put_NN (output_bfd,
- relocation - dtpoff_base (info),
- globals->root.sgot->contents + off
- + GOT_ENTRY_SIZE);
- }
- else
- {
- /* This TLS symbol is global. We emit a
- relocation to fixup the tls offset at load
- time. */
- rela.r_info =
- ELFNN_R_INFO (indx, AARCH64_R (TLS_DTPREL));
- rela.r_addend = 0;
- rela.r_offset =
- (globals->root.sgot->output_section->vma
- + globals->root.sgot->output_offset + off
- + GOT_ENTRY_SIZE);
-
- loc = globals->root.srelgot->contents;
- loc += globals->root.srelgot->reloc_count++
- * RELOC_SIZE (globals);
- bfd_elfNN_swap_reloca_out (output_bfd, &rela, loc);
- bfd_put_NN (output_bfd, (bfd_vma) 0,
- globals->root.sgot->contents + off
- + GOT_ENTRY_SIZE);
- }
- }
- else
- {
- bfd_put_NN (output_bfd, (bfd_vma) 1,
- globals->root.sgot->contents + off);
- bfd_put_NN (output_bfd,
- relocation - dtpoff_base (info),
- globals->root.sgot->contents + off
- + GOT_ENTRY_SIZE);
- }
-
- symbol_got_offset_mark (input_bfd, h, r_symndx);
- }
- break;
-
- case BFD_RELOC_AARCH64_TLSIE_ADR_GOTTPREL_PAGE21:
- case BFD_RELOC_AARCH64_TLSIE_LDNN_GOTTPREL_LO12_NC:
- case BFD_RELOC_AARCH64_TLSIE_LD_GOTTPREL_PREL19:
- case BFD_RELOC_AARCH64_TLSIE_MOVW_GOTTPREL_G0_NC:
- case BFD_RELOC_AARCH64_TLSIE_MOVW_GOTTPREL_G1:
- if (! symbol_got_offset_mark_p (input_bfd, h, r_symndx))
- {
- bool need_relocs = false;
- bfd_byte *loc;
- int indx;
- bfd_vma off;
-
- off = symbol_got_offset (input_bfd, h, r_symndx);
-
- indx = h && h->dynindx != -1 ? h->dynindx : 0;
-
- need_relocs =
- (!bfd_link_executable (info) || indx != 0) &&
- (h == NULL
- || ELF_ST_VISIBILITY (h->other) == STV_DEFAULT
- || h->root.type != bfd_link_hash_undefweak);
-
- BFD_ASSERT (globals->root.srelgot != NULL);
-
- if (need_relocs)
- {
- Elf_Internal_Rela rela;
-
- if (indx == 0)
- rela.r_addend = relocation - dtpoff_base (info);
- else
- rela.r_addend = 0;
-
- rela.r_info = ELFNN_R_INFO (indx, AARCH64_R (TLS_TPREL));
- rela.r_offset = globals->root.sgot->output_section->vma +
- globals->root.sgot->output_offset + off;
-
- loc = globals->root.srelgot->contents;
- loc += globals->root.srelgot->reloc_count++
- * RELOC_SIZE (htab);
-
- bfd_elfNN_swap_reloca_out (output_bfd, &rela, loc);
-
- bfd_put_NN (output_bfd, rela.r_addend,
- globals->root.sgot->contents + off);
- }
- else
- bfd_put_NN (output_bfd, relocation - tpoff_base (info),
- globals->root.sgot->contents + off);
-
- symbol_got_offset_mark (input_bfd, h, r_symndx);
- }
- break;
-
- case BFD_RELOC_AARCH64_TLSDESC_ADD_LO12:
- case BFD_RELOC_AARCH64_TLSDESC_ADR_PAGE21:
- case BFD_RELOC_AARCH64_TLSDESC_ADR_PREL21:
- case BFD_RELOC_AARCH64_TLSDESC_LDNN_LO12_NC:
- case BFD_RELOC_AARCH64_TLSDESC_LD_PREL19:
- case BFD_RELOC_AARCH64_TLSDESC_OFF_G0_NC:
- case BFD_RELOC_AARCH64_TLSDESC_OFF_G1:
- if (! symbol_tlsdesc_got_offset_mark_p (input_bfd, h, r_symndx))
- {
- bool need_relocs = false;
- int indx = h && h->dynindx != -1 ? h->dynindx : 0;
- bfd_vma off = symbol_tlsdesc_got_offset (input_bfd, h, r_symndx);
-
- need_relocs = (h == NULL
- || ELF_ST_VISIBILITY (h->other) == STV_DEFAULT
- || h->root.type != bfd_link_hash_undefweak);
-
- BFD_ASSERT (globals->root.srelgot != NULL);
- BFD_ASSERT (globals->root.sgot != NULL);
-
- if (need_relocs)
- {
- bfd_byte *loc;
- Elf_Internal_Rela rela;
- rela.r_info = ELFNN_R_INFO (indx, AARCH64_R (TLSDESC));
-
- rela.r_addend = 0;
- rela.r_offset = (globals->root.sgotplt->output_section->vma
- + globals->root.sgotplt->output_offset
- + off + globals->sgotplt_jump_table_size);
-
- if (indx == 0)
- rela.r_addend = relocation - dtpoff_base (info);
-
- /* Allocate the next available slot in the PLT reloc
- section to hold our R_AARCH64_TLSDESC, the next
- available slot is determined from reloc_count,
- which we step. But note, reloc_count was
- artifically moved down while allocating slots for
- real PLT relocs such that all of the PLT relocs
- will fit above the initial reloc_count and the
- extra stuff will fit below. */
- loc = globals->root.srelplt->contents;
- loc += globals->root.srelplt->reloc_count++
- * RELOC_SIZE (globals);
-
- bfd_elfNN_swap_reloca_out (output_bfd, &rela, loc);
-
- bfd_put_NN (output_bfd, (bfd_vma) 0,
- globals->root.sgotplt->contents + off +
- globals->sgotplt_jump_table_size);
- bfd_put_NN (output_bfd, (bfd_vma) 0,
- globals->root.sgotplt->contents + off +
- globals->sgotplt_jump_table_size +
- GOT_ENTRY_SIZE);
- }
-
- symbol_tlsdesc_got_offset_mark (input_bfd, h, r_symndx);
- }
- break;
- default:
- break;
- }
-
- /* Dynamic relocs are not propagated for SEC_DEBUGGING sections
- because such sections are not SEC_ALLOC and thus ld.so will
- not process them. */
- if (unresolved_reloc
- && !((input_section->flags & SEC_DEBUGGING) != 0
- && h->def_dynamic)
- && _bfd_elf_section_offset (output_bfd, info, input_section,
- +rel->r_offset) != (bfd_vma) - 1)
- {
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB(%pA+%#" PRIx64 "): "
- "unresolvable %s relocation against symbol `%s'"),
- input_bfd, input_section, (uint64_t) rel->r_offset, howto->name,
- h->root.root.string);
- return false;
- }
-
- if (r != bfd_reloc_ok && r != bfd_reloc_continue)
- {
- bfd_reloc_code_real_type real_r_type
- = elfNN_aarch64_bfd_reloc_from_type (input_bfd, r_type);
-
- switch (r)
- {
- case bfd_reloc_overflow:
- (*info->callbacks->reloc_overflow)
- (info, (h ? &h->root : NULL), name, howto->name, (bfd_vma) 0,
- input_bfd, input_section, rel->r_offset);
- if (real_r_type == BFD_RELOC_AARCH64_LD64_GOTPAGE_LO15
- || real_r_type == BFD_RELOC_AARCH64_LD32_GOTPAGE_LO14)
- {
- (*info->callbacks->warning)
- (info,
- _("too many GOT entries for -fpic, "
- "please recompile with -fPIC"),
- name, input_bfd, input_section, rel->r_offset);
- return false;
- }
- /* Overflow can occur when a variable is referenced with a type
- that has a larger alignment than the type with which it was
- declared. eg:
- file1.c: extern int foo; int a (void) { return foo; }
- file2.c: char bar, foo, baz;
- If the variable is placed into a data section at an offset
- that is incompatible with the larger alignment requirement
- overflow will occur. (Strictly speaking this is not overflow
- but rather an alignment problem, but the bfd_reloc_ error
- enum does not have a value to cover that situation).
-
- Try to catch this situation here and provide a more helpful
- error message to the user. */
- if (addend & (((bfd_vma) 1 << howto->rightshift) - 1)
- /* FIXME: Are we testing all of the appropriate reloc
- types here ? */
- && (real_r_type == BFD_RELOC_AARCH64_LD_LO19_PCREL
- || real_r_type == BFD_RELOC_AARCH64_LDST16_LO12
- || real_r_type == BFD_RELOC_AARCH64_LDST32_LO12
- || real_r_type == BFD_RELOC_AARCH64_LDST64_LO12
- || real_r_type == BFD_RELOC_AARCH64_LDST128_LO12))
- {
- info->callbacks->warning
- (info, _("one possible cause of this error is that the \
-symbol is being referenced in the indicated code as if it had a larger \
-alignment than was declared where it was defined"),
- name, input_bfd, input_section, rel->r_offset);
- }
- break;
-
- case bfd_reloc_undefined:
- (*info->callbacks->undefined_symbol)
- (info, name, input_bfd, input_section, rel->r_offset, true);
- break;
-
- case bfd_reloc_outofrange:
- error_message = _("out of range");
- goto common_error;
-
- case bfd_reloc_notsupported:
- error_message = _("unsupported relocation");
- goto common_error;
-
- case bfd_reloc_dangerous:
- /* error_message should already be set. */
- goto common_error;
-
- default:
- error_message = _("unknown error");
- /* Fall through. */
-
- common_error:
- BFD_ASSERT (error_message != NULL);
- (*info->callbacks->reloc_dangerous)
- (info, error_message, input_bfd, input_section, rel->r_offset);
- break;
- }
- }
-
- if (!save_addend)
- addend = 0;
- }
-
- return true;
-}
-
-/* Set the right machine number. */
-
-static bool
-elfNN_aarch64_object_p (bfd *abfd)
-{
-#if ARCH_SIZE == 32
- bfd_default_set_arch_mach (abfd, bfd_arch_aarch64, bfd_mach_aarch64_ilp32);
-#else
- bfd_default_set_arch_mach (abfd, bfd_arch_aarch64, bfd_mach_aarch64);
-#endif
- return true;
-}
-
-/* Function to keep AArch64 specific flags in the ELF header. */
-
-static bool
-elfNN_aarch64_set_private_flags (bfd *abfd, flagword flags)
-{
- if (elf_flags_init (abfd) && elf_elfheader (abfd)->e_flags != flags)
- {
- }
- else
- {
- elf_elfheader (abfd)->e_flags = flags;
- elf_flags_init (abfd) = true;
- }
-
- return true;
-}
-
-/* Merge backend specific data from an object file to the output
- object file when linking. */
-
-static bool
-elfNN_aarch64_merge_private_bfd_data (bfd *ibfd, struct bfd_link_info *info)
-{
- bfd *obfd = info->output_bfd;
- flagword out_flags;
- flagword in_flags;
- bool flags_compatible = true;
- asection *sec;
-
- /* Check if we have the same endianess. */
- if (!_bfd_generic_verify_endian_match (ibfd, info))
- return false;
-
- if (!is_aarch64_elf (ibfd) || !is_aarch64_elf (obfd))
- return true;
-
- /* The input BFD must have had its flags initialised. */
- /* The following seems bogus to me -- The flags are initialized in
- the assembler but I don't think an elf_flags_init field is
- written into the object. */
- /* BFD_ASSERT (elf_flags_init (ibfd)); */
-
- in_flags = elf_elfheader (ibfd)->e_flags;
- out_flags = elf_elfheader (obfd)->e_flags;
-
- if (!elf_flags_init (obfd))
- {
- /* If the input is the default architecture and had the default
- flags then do not bother setting the flags for the output
- architecture, instead allow future merges to do this. If no
- future merges ever set these flags then they will retain their
- uninitialised values, which surprise surprise, correspond
- to the default values. */
- if (bfd_get_arch_info (ibfd)->the_default
- && elf_elfheader (ibfd)->e_flags == 0)
- return true;
-
- elf_flags_init (obfd) = true;
- elf_elfheader (obfd)->e_flags = in_flags;
-
- if (bfd_get_arch (obfd) == bfd_get_arch (ibfd)
- && bfd_get_arch_info (obfd)->the_default)
- return bfd_set_arch_mach (obfd, bfd_get_arch (ibfd),
- bfd_get_mach (ibfd));
-
- return true;
- }
-
- /* Identical flags must be compatible. */
- if (in_flags == out_flags)
- return true;
-
- /* Check to see if the input BFD actually contains any sections. If
- not, its flags may not have been initialised either, but it
- cannot actually cause any incompatiblity. Do not short-circuit
- dynamic objects; their section list may be emptied by
- elf_link_add_object_symbols.
-
- Also check to see if there are no code sections in the input.
- In this case there is no need to check for code specific flags.
- XXX - do we need to worry about floating-point format compatability
- in data sections ? */
- if (!(ibfd->flags & DYNAMIC))
- {
- bool null_input_bfd = true;
- bool only_data_sections = true;
-
- for (sec = ibfd->sections; sec != NULL; sec = sec->next)
- {
- if ((bfd_section_flags (sec)
- & (SEC_LOAD | SEC_CODE | SEC_HAS_CONTENTS))
- == (SEC_LOAD | SEC_CODE | SEC_HAS_CONTENTS))
- only_data_sections = false;
-
- null_input_bfd = false;
- break;
- }
-
- if (null_input_bfd || only_data_sections)
- return true;
- }
-
- return flags_compatible;
-}
-
-/* Display the flags field. */
-
-static bool
-elfNN_aarch64_print_private_bfd_data (bfd *abfd, void *ptr)
-{
- FILE *file = (FILE *) ptr;
- unsigned long flags;
-
- BFD_ASSERT (abfd != NULL && ptr != NULL);
-
- /* Print normal ELF private data. */
- _bfd_elf_print_private_bfd_data (abfd, ptr);
-
- flags = elf_elfheader (abfd)->e_flags;
- /* Ignore init flag - it may not be set, despite the flags field
- containing valid data. */
-
- /* xgettext:c-format */
- fprintf (file, _("private flags = 0x%lx:"), elf_elfheader (abfd)->e_flags);
-
- if (flags)
- fprintf (file, _(" <Unrecognised flag bits set>"));
-
- fputc ('\n', file);
-
- return true;
-}
-
-/* Return true if we need copy relocation against EH. */
-
-static bool
-need_copy_relocation_p (struct elf_aarch64_link_hash_entry *eh)
-{
- struct elf_dyn_relocs *p;
- asection *s;
-
- for (p = eh->root.dyn_relocs; p != NULL; p = p->next)
- {
- /* If there is any pc-relative reference, we need to keep copy relocation
- to avoid propagating the relocation into runtime that current glibc
- does not support. */
- if (p->pc_count)
- return true;
-
- s = p->sec->output_section;
- /* Need copy relocation if it's against read-only section. */
- if (s != NULL && (s->flags & SEC_READONLY) != 0)
- return true;
- }
-
- return false;
-}
-
-/* Adjust a symbol defined by a dynamic object and referenced by a
- regular object. The current definition is in some section of the
- dynamic object, but we're not including those sections. We have to
- change the definition to something the rest of the link can
- understand. */
-
-static bool
-elfNN_aarch64_adjust_dynamic_symbol (struct bfd_link_info *info,
- struct elf_link_hash_entry *h)
-{
- struct elf_aarch64_link_hash_table *htab;
- asection *s, *srel;
-
- /* If this is a function, put it in the procedure linkage table. We
- will fill in the contents of the procedure linkage table later,
- when we know the address of the .got section. */
- if (h->type == STT_FUNC || h->type == STT_GNU_IFUNC || h->needs_plt)
- {
- if (h->plt.refcount <= 0
- || (h->type != STT_GNU_IFUNC
- && (SYMBOL_CALLS_LOCAL (info, h)
- || (ELF_ST_VISIBILITY (h->other) != STV_DEFAULT
- && h->root.type == bfd_link_hash_undefweak))))
- {
- /* This case can occur if we saw a CALL26 reloc in
- an input file, but the symbol wasn't referred to
- by a dynamic object or all references were
- garbage collected. In which case we can end up
- resolving. */
- h->plt.offset = (bfd_vma) - 1;
- h->needs_plt = 0;
- }
-
- return true;
- }
- else
- /* Otherwise, reset to -1. */
- h->plt.offset = (bfd_vma) - 1;
-
-
- /* If this is a weak symbol, and there is a real definition, the
- processor independent code will have arranged for us to see the
- real definition first, and we can just use the same value. */
- if (h->is_weakalias)
- {
- struct elf_link_hash_entry *def = weakdef (h);
- BFD_ASSERT (def->root.type == bfd_link_hash_defined);
- h->root.u.def.section = def->root.u.def.section;
- h->root.u.def.value = def->root.u.def.value;
- if (ELIMINATE_COPY_RELOCS || info->nocopyreloc)
- h->non_got_ref = def->non_got_ref;
- return true;
- }
-
- /* If we are creating a shared library, we must presume that the
- only references to the symbol are via the global offset table.
- For such cases we need not do anything here; the relocations will
- be handled correctly by relocate_section. */
- if (bfd_link_pic (info))
- return true;
-
- /* If there are no references to this symbol that do not use the
- GOT, we don't need to generate a copy reloc. */
- if (!h->non_got_ref)
- return true;
-
- /* If -z nocopyreloc was given, we won't generate them either. */
- if (info->nocopyreloc)
- {
- h->non_got_ref = 0;
- return true;
- }
-
- if (ELIMINATE_COPY_RELOCS)
- {
- struct elf_aarch64_link_hash_entry *eh;
- /* If we don't find any dynamic relocs in read-only sections, then
- we'll be keeping the dynamic relocs and avoiding the copy reloc. */
- eh = (struct elf_aarch64_link_hash_entry *) h;
- if (!need_copy_relocation_p (eh))
- {
- h->non_got_ref = 0;
- return true;
- }
- }
-
- /* We must allocate the symbol in our .dynbss section, which will
- become part of the .bss section of the executable. There will be
- an entry for this symbol in the .dynsym section. The dynamic
- object will contain position independent code, so all references
- from the dynamic object to this symbol will go through the global
- offset table. The dynamic linker will use the .dynsym entry to
- determine the address it must put in the global offset table, so
- both the dynamic object and the regular object will refer to the
- same memory location for the variable. */
-
- htab = elf_aarch64_hash_table (info);
-
- /* We must generate a R_AARCH64_COPY reloc to tell the dynamic linker
- to copy the initial value out of the dynamic object and into the
- runtime process image. */
- if ((h->root.u.def.section->flags & SEC_READONLY) != 0)
- {
- s = htab->root.sdynrelro;
- srel = htab->root.sreldynrelro;
- }
- else
- {
- s = htab->root.sdynbss;
- srel = htab->root.srelbss;
- }
- if ((h->root.u.def.section->flags & SEC_ALLOC) != 0 && h->size != 0)
- {
- srel->size += RELOC_SIZE (htab);
- h->needs_copy = 1;
- }
-
- return _bfd_elf_adjust_dynamic_copy (info, h, s);
-
-}
-
-static bool
-elfNN_aarch64_allocate_local_symbols (bfd *abfd, unsigned number)
-{
- struct elf_aarch64_local_symbol *locals;
- locals = elf_aarch64_locals (abfd);
- if (locals == NULL)
- {
- locals = (struct elf_aarch64_local_symbol *)
- bfd_zalloc (abfd, number * sizeof (struct elf_aarch64_local_symbol));
- if (locals == NULL)
- return false;
- elf_aarch64_locals (abfd) = locals;
- }
- return true;
-}
-
-/* Create the .got section to hold the global offset table. */
-
-static bool
-aarch64_elf_create_got_section (bfd *abfd, struct bfd_link_info *info)
-{
- const struct elf_backend_data *bed = get_elf_backend_data (abfd);
- flagword flags;
- asection *s;
- struct elf_link_hash_entry *h;
- struct elf_link_hash_table *htab = elf_hash_table (info);
-
- /* This function may be called more than once. */
- if (htab->sgot != NULL)
- return true;
-
- flags = bed->dynamic_sec_flags;
-
- s = bfd_make_section_anyway_with_flags (abfd,
- (bed->rela_plts_and_copies_p
- ? ".rela.got" : ".rel.got"),
- (bed->dynamic_sec_flags
- | SEC_READONLY));
- if (s == NULL
- || !bfd_set_section_alignment (s, bed->s->log_file_align))
- return false;
- htab->srelgot = s;
-
- s = bfd_make_section_anyway_with_flags (abfd, ".got", flags);
- if (s == NULL
- || !bfd_set_section_alignment (s, bed->s->log_file_align))
- return false;
- htab->sgot = s;
- htab->sgot->size += GOT_ENTRY_SIZE;
-
- if (bed->want_got_sym)
- {
- /* Define the symbol _GLOBAL_OFFSET_TABLE_ at the start of the .got
- (or .got.plt) section. We don't do this in the linker script
- because we don't want to define the symbol if we are not creating
- a global offset table. */
- h = _bfd_elf_define_linkage_sym (abfd, info, s,
- "_GLOBAL_OFFSET_TABLE_");
- elf_hash_table (info)->hgot = h;
- if (h == NULL)
- return false;
- }
-
- if (bed->want_got_plt)
- {
- s = bfd_make_section_anyway_with_flags (abfd, ".got.plt", flags);
- if (s == NULL
- || !bfd_set_section_alignment (s, bed->s->log_file_align))
- return false;
- htab->sgotplt = s;
- }
-
- /* The first bit of the global offset table is the header. */
- s->size += bed->got_header_size;
-
- return true;
-}
-
-/* Look through the relocs for a section during the first phase. */
-
-static bool
-elfNN_aarch64_check_relocs (bfd *abfd, struct bfd_link_info *info,
- asection *sec, const Elf_Internal_Rela *relocs)
-{
- Elf_Internal_Shdr *symtab_hdr;
- struct elf_link_hash_entry **sym_hashes;
- const Elf_Internal_Rela *rel;
- const Elf_Internal_Rela *rel_end;
- asection *sreloc;
-
- struct elf_aarch64_link_hash_table *htab;
-
- if (bfd_link_relocatable (info))
- return true;
-
- BFD_ASSERT (is_aarch64_elf (abfd));
-
- htab = elf_aarch64_hash_table (info);
- sreloc = NULL;
-
- symtab_hdr = &elf_symtab_hdr (abfd);
- sym_hashes = elf_sym_hashes (abfd);
-
- rel_end = relocs + sec->reloc_count;
- for (rel = relocs; rel < rel_end; rel++)
- {
- struct elf_link_hash_entry *h;
- unsigned int r_symndx;
- unsigned int r_type;
- bfd_reloc_code_real_type bfd_r_type;
- Elf_Internal_Sym *isym;
-
- r_symndx = ELFNN_R_SYM (rel->r_info);
- r_type = ELFNN_R_TYPE (rel->r_info);
-
- if (r_symndx >= NUM_SHDR_ENTRIES (symtab_hdr))
- {
- /* xgettext:c-format */
- _bfd_error_handler (_("%pB: bad symbol index: %d"), abfd, r_symndx);
- return false;
- }
-
- if (r_symndx < symtab_hdr->sh_info)
- {
- /* A local symbol. */
- isym = bfd_sym_from_r_symndx (&htab->root.sym_cache,
- abfd, r_symndx);
- if (isym == NULL)
- return false;
-
- /* Check relocation against local STT_GNU_IFUNC symbol. */
- if (ELF_ST_TYPE (isym->st_info) == STT_GNU_IFUNC)
- {
- h = elfNN_aarch64_get_local_sym_hash (htab, abfd, rel,
- true);
- if (h == NULL)
- return false;
-
- /* Fake a STT_GNU_IFUNC symbol. */
- h->type = STT_GNU_IFUNC;
- h->def_regular = 1;
- h->ref_regular = 1;
- h->forced_local = 1;
- h->root.type = bfd_link_hash_defined;
- }
- else
- h = NULL;
- }
- else
- {
- h = sym_hashes[r_symndx - symtab_hdr->sh_info];
- while (h->root.type == bfd_link_hash_indirect
- || h->root.type == bfd_link_hash_warning)
- h = (struct elf_link_hash_entry *) h->root.u.i.link;
- }
-
- /* Could be done earlier, if h were already available. */
- bfd_r_type = aarch64_tls_transition (abfd, info, r_type, h, r_symndx);
-
- if (h != NULL)
- {
- /* If a relocation refers to _GLOBAL_OFFSET_TABLE_, create the .got.
- This shows up in particular in an R_AARCH64_PREL64 in large model
- when calculating the pc-relative address to .got section which is
- used to initialize the gp register. */
- if (h->root.root.string
- && strcmp (h->root.root.string, "_GLOBAL_OFFSET_TABLE_") == 0)
- {
- if (htab->root.dynobj == NULL)
- htab->root.dynobj = abfd;
-
- if (! aarch64_elf_create_got_section (htab->root.dynobj, info))
- return false;
-
- BFD_ASSERT (h == htab->root.hgot);
- }
-
- /* Create the ifunc sections for static executables. If we
- never see an indirect function symbol nor we are building
- a static executable, those sections will be empty and
- won't appear in output. */
- switch (bfd_r_type)
- {
- default:
- break;
-
- case BFD_RELOC_AARCH64_ADD_LO12:
- case BFD_RELOC_AARCH64_ADR_GOT_PAGE:
- case BFD_RELOC_AARCH64_ADR_HI21_PCREL:
- case BFD_RELOC_AARCH64_CALL26:
- case BFD_RELOC_AARCH64_GOT_LD_PREL19:
- case BFD_RELOC_AARCH64_JUMP26:
- case BFD_RELOC_AARCH64_LD32_GOTPAGE_LO14:
- case BFD_RELOC_AARCH64_LD32_GOT_LO12_NC:
- case BFD_RELOC_AARCH64_LD64_GOTOFF_LO15:
- case BFD_RELOC_AARCH64_LD64_GOTPAGE_LO15:
- case BFD_RELOC_AARCH64_LD64_GOT_LO12_NC:
- case BFD_RELOC_AARCH64_MOVW_GOTOFF_G0_NC:
- case BFD_RELOC_AARCH64_MOVW_GOTOFF_G1:
- case BFD_RELOC_AARCH64_NN:
- if (htab->root.dynobj == NULL)
- htab->root.dynobj = abfd;
- if (!_bfd_elf_create_ifunc_sections (htab->root.dynobj, info))
- return false;
- break;
- }
-
- /* It is referenced by a non-shared object. */
- h->ref_regular = 1;
- }
-
- switch (bfd_r_type)
- {
- case BFD_RELOC_AARCH64_16:
-#if ARCH_SIZE == 64
- case BFD_RELOC_AARCH64_32:
-#endif
- if (bfd_link_pic (info) && (sec->flags & SEC_ALLOC) != 0)
- {
- if (h != NULL
- /* This is an absolute symbol. It represents a value instead
- of an address. */
- && (bfd_is_abs_symbol (&h->root)
- /* This is an undefined symbol. */
- || h->root.type == bfd_link_hash_undefined))
- break;
-
- /* For local symbols, defined global symbols in a non-ABS section,
- it is assumed that the value is an address. */
- int howto_index = bfd_r_type - BFD_RELOC_AARCH64_RELOC_START;
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB: relocation %s against `%s' can not be used when making "
- "a shared object"),
- abfd, elfNN_aarch64_howto_table[howto_index].name,
- (h) ? h->root.root.string : "a local symbol");
- bfd_set_error (bfd_error_bad_value);
- return false;
- }
- else
- break;
-
- case BFD_RELOC_AARCH64_MOVW_G0_NC:
- case BFD_RELOC_AARCH64_MOVW_G1_NC:
- case BFD_RELOC_AARCH64_MOVW_G2_NC:
- case BFD_RELOC_AARCH64_MOVW_G3:
- if (bfd_link_pic (info))
- {
- int howto_index = bfd_r_type - BFD_RELOC_AARCH64_RELOC_START;
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB: relocation %s against `%s' can not be used when making "
- "a shared object; recompile with -fPIC"),
- abfd, elfNN_aarch64_howto_table[howto_index].name,
- (h) ? h->root.root.string : "a local symbol");
- bfd_set_error (bfd_error_bad_value);
- return false;
- }
- /* Fall through. */
-
- case BFD_RELOC_AARCH64_16_PCREL:
- case BFD_RELOC_AARCH64_32_PCREL:
- case BFD_RELOC_AARCH64_64_PCREL:
- case BFD_RELOC_AARCH64_ADD_LO12:
- case BFD_RELOC_AARCH64_ADR_HI21_NC_PCREL:
- case BFD_RELOC_AARCH64_ADR_HI21_PCREL:
- case BFD_RELOC_AARCH64_ADR_LO21_PCREL:
- case BFD_RELOC_AARCH64_LDST128_LO12:
- case BFD_RELOC_AARCH64_LDST16_LO12:
- case BFD_RELOC_AARCH64_LDST32_LO12:
- case BFD_RELOC_AARCH64_LDST64_LO12:
- case BFD_RELOC_AARCH64_LDST8_LO12:
- case BFD_RELOC_AARCH64_LD_LO19_PCREL:
- if (h == NULL || bfd_link_pic (info))
- break;
- /* Fall through. */
-
- case BFD_RELOC_AARCH64_NN:
-
- /* We don't need to handle relocs into sections not going into
- the "real" output. */
- if ((sec->flags & SEC_ALLOC) == 0)
- break;
-
- if (h != NULL)
- {
- if (!bfd_link_pic (info))
- h->non_got_ref = 1;
-
- h->plt.refcount += 1;
- h->pointer_equality_needed = 1;
- }
-
- /* No need to do anything if we're not creating a shared
- object. */
- if (!(bfd_link_pic (info)
- /* If on the other hand, we are creating an executable, we
- may need to keep relocations for symbols satisfied by a
- dynamic library if we manage to avoid copy relocs for the
- symbol.
-
- NOTE: Currently, there is no support of copy relocs
- elimination on pc-relative relocation types, because there is
- no dynamic relocation support for them in glibc. We still
- record the dynamic symbol reference for them. This is
- because one symbol may be referenced by both absolute
- relocation (for example, BFD_RELOC_AARCH64_NN) and
- pc-relative relocation. We need full symbol reference
- information to make correct decision later in
- elfNN_aarch64_adjust_dynamic_symbol. */
- || (ELIMINATE_COPY_RELOCS
- && !bfd_link_pic (info)
- && h != NULL
- && (h->root.type == bfd_link_hash_defweak
- || !h->def_regular))))
- break;
-
- {
- struct elf_dyn_relocs *p;
- struct elf_dyn_relocs **head;
- int howto_index = bfd_r_type - BFD_RELOC_AARCH64_RELOC_START;
-
- /* We must copy these reloc types into the output file.
- Create a reloc section in dynobj and make room for
- this reloc. */
- if (sreloc == NULL)
- {
- if (htab->root.dynobj == NULL)
- htab->root.dynobj = abfd;
-
- sreloc = _bfd_elf_make_dynamic_reloc_section
- (sec, htab->root.dynobj, LOG_FILE_ALIGN, abfd, /*rela? */ true);
-
- if (sreloc == NULL)
- return false;
- }
-
- /* If this is a global symbol, we count the number of
- relocations we need for this symbol. */
- if (h != NULL)
- {
- head = &h->dyn_relocs;
- }
- else
- {
- /* Track dynamic relocs needed for local syms too.
- We really need local syms available to do this
- easily. Oh well. */
-
- asection *s;
- void **vpp;
-
- isym = bfd_sym_from_r_symndx (&htab->root.sym_cache,
- abfd, r_symndx);
- if (isym == NULL)
- return false;
-
- s = bfd_section_from_elf_index (abfd, isym->st_shndx);
- if (s == NULL)
- s = sec;
-
- /* Beware of type punned pointers vs strict aliasing
- rules. */
- vpp = &(elf_section_data (s)->local_dynrel);
- head = (struct elf_dyn_relocs **) vpp;
- }
-
- p = *head;
- if (p == NULL || p->sec != sec)
- {
- size_t amt = sizeof *p;
- p = ((struct elf_dyn_relocs *)
- bfd_zalloc (htab->root.dynobj, amt));
- if (p == NULL)
- return false;
- p->next = *head;
- *head = p;
- p->sec = sec;
- }
-
- p->count += 1;
-
- if (elfNN_aarch64_howto_table[howto_index].pc_relative)
- p->pc_count += 1;
- }
- break;
-
- /* RR: We probably want to keep a consistency check that
- there are no dangling GOT_PAGE relocs. */
- case BFD_RELOC_AARCH64_ADR_GOT_PAGE:
- case BFD_RELOC_AARCH64_GOT_LD_PREL19:
- case BFD_RELOC_AARCH64_LD32_GOTPAGE_LO14:
- case BFD_RELOC_AARCH64_LD32_GOT_LO12_NC:
- case BFD_RELOC_AARCH64_LD64_GOTOFF_LO15:
- case BFD_RELOC_AARCH64_LD64_GOTPAGE_LO15:
- case BFD_RELOC_AARCH64_LD64_GOT_LO12_NC:
- case BFD_RELOC_AARCH64_MOVW_GOTOFF_G0_NC:
- case BFD_RELOC_AARCH64_MOVW_GOTOFF_G1:
- case BFD_RELOC_AARCH64_TLSDESC_ADD_LO12:
- case BFD_RELOC_AARCH64_TLSDESC_ADR_PAGE21:
- case BFD_RELOC_AARCH64_TLSDESC_ADR_PREL21:
- case BFD_RELOC_AARCH64_TLSDESC_LD32_LO12_NC:
- case BFD_RELOC_AARCH64_TLSDESC_LD64_LO12:
- case BFD_RELOC_AARCH64_TLSDESC_LD_PREL19:
- case BFD_RELOC_AARCH64_TLSDESC_OFF_G0_NC:
- case BFD_RELOC_AARCH64_TLSDESC_OFF_G1:
- case BFD_RELOC_AARCH64_TLSGD_ADD_LO12_NC:
- case BFD_RELOC_AARCH64_TLSGD_ADR_PAGE21:
- case BFD_RELOC_AARCH64_TLSGD_ADR_PREL21:
- case BFD_RELOC_AARCH64_TLSGD_MOVW_G0_NC:
- case BFD_RELOC_AARCH64_TLSGD_MOVW_G1:
- case BFD_RELOC_AARCH64_TLSIE_ADR_GOTTPREL_PAGE21:
- case BFD_RELOC_AARCH64_TLSIE_LD32_GOTTPREL_LO12_NC:
- case BFD_RELOC_AARCH64_TLSIE_LD64_GOTTPREL_LO12_NC:
- case BFD_RELOC_AARCH64_TLSIE_LD_GOTTPREL_PREL19:
- case BFD_RELOC_AARCH64_TLSIE_MOVW_GOTTPREL_G0_NC:
- case BFD_RELOC_AARCH64_TLSIE_MOVW_GOTTPREL_G1:
- case BFD_RELOC_AARCH64_TLSLD_ADD_LO12_NC:
- case BFD_RELOC_AARCH64_TLSLD_ADR_PAGE21:
- case BFD_RELOC_AARCH64_TLSLD_ADR_PREL21:
- {
- unsigned got_type;
- unsigned old_got_type;
-
- got_type = aarch64_reloc_got_type (bfd_r_type);
-
- if (h)
- {
- h->got.refcount += 1;
- old_got_type = elf_aarch64_hash_entry (h)->got_type;
- }
- else
- {
- struct elf_aarch64_local_symbol *locals;
-
- if (!elfNN_aarch64_allocate_local_symbols
- (abfd, symtab_hdr->sh_info))
- return false;
-
- locals = elf_aarch64_locals (abfd);
- BFD_ASSERT (r_symndx < symtab_hdr->sh_info);
- locals[r_symndx].got_refcount += 1;
- old_got_type = locals[r_symndx].got_type;
- }
-
- /* If a variable is accessed with both general dynamic TLS
- methods, two slots may be created. */
- if (GOT_TLS_GD_ANY_P (old_got_type) && GOT_TLS_GD_ANY_P (got_type))
- got_type |= old_got_type;
-
- /* We will already have issued an error message if there
- is a TLS/non-TLS mismatch, based on the symbol type.
- So just combine any TLS types needed. */
- if (old_got_type != GOT_UNKNOWN && old_got_type != GOT_NORMAL
- && got_type != GOT_NORMAL)
- got_type |= old_got_type;
-
- /* If the symbol is accessed by both IE and GD methods, we
- are able to relax. Turn off the GD flag, without
- messing up with any other kind of TLS types that may be
- involved. */
- if ((got_type & GOT_TLS_IE) && GOT_TLS_GD_ANY_P (got_type))
- got_type &= ~ (GOT_TLSDESC_GD | GOT_TLS_GD);
-
- if (old_got_type != got_type)
- {
- if (h != NULL)
- elf_aarch64_hash_entry (h)->got_type = got_type;
- else
- {
- struct elf_aarch64_local_symbol *locals;
- locals = elf_aarch64_locals (abfd);
- BFD_ASSERT (r_symndx < symtab_hdr->sh_info);
- locals[r_symndx].got_type = got_type;
- }
- }
-
- if (htab->root.dynobj == NULL)
- htab->root.dynobj = abfd;
- if (! aarch64_elf_create_got_section (htab->root.dynobj, info))
- return false;
- break;
- }
-
- case BFD_RELOC_AARCH64_CALL26:
- case BFD_RELOC_AARCH64_JUMP26:
- /* If this is a local symbol then we resolve it
- directly without creating a PLT entry. */
- if (h == NULL)
- continue;
-
- h->needs_plt = 1;
- if (h->plt.refcount <= 0)
- h->plt.refcount = 1;
- else
- h->plt.refcount += 1;
- break;
-
- default:
- break;
- }
- }
-
- return true;
-}
-
-/* Treat mapping symbols as special target symbols. */
-
-static bool
-elfNN_aarch64_is_target_special_symbol (bfd *abfd ATTRIBUTE_UNUSED,
- asymbol *sym)
-{
- return bfd_is_aarch64_special_symbol_name (sym->name,
- BFD_AARCH64_SPECIAL_SYM_TYPE_ANY);
-}
-
-/* If the ELF symbol SYM might be a function in SEC, return the
- function size and set *CODE_OFF to the function's entry point,
- otherwise return zero. */
-
-static bfd_size_type
-elfNN_aarch64_maybe_function_sym (const asymbol *sym, asection *sec,
- bfd_vma *code_off)
-{
- bfd_size_type size;
- elf_symbol_type * elf_sym = (elf_symbol_type *) sym;
-
- if ((sym->flags & (BSF_SECTION_SYM | BSF_FILE | BSF_OBJECT
- | BSF_THREAD_LOCAL | BSF_RELC | BSF_SRELC)) != 0
- || sym->section != sec)
- return 0;
-
- size = (sym->flags & BSF_SYNTHETIC) ? 0 : elf_sym->internal_elf_sym.st_size;
-
- if (!(sym->flags & BSF_SYNTHETIC))
- switch (ELF_ST_TYPE (elf_sym->internal_elf_sym.st_info))
- {
- case STT_NOTYPE:
- /* Ignore symbols created by the annobin plugin for gcc and clang.
- These symbols are hidden, local, notype and have a size of 0. */
- if (size == 0
- && sym->flags & BSF_LOCAL
- && ELF_ST_VISIBILITY (elf_sym->internal_elf_sym.st_other) == STV_HIDDEN)
- return 0;
- /* Fall through. */
- case STT_FUNC:
- /* FIXME: Allow STT_GNU_IFUNC as well ? */
- break;
- default:
- return 0;
- }
-
- if ((sym->flags & BSF_LOCAL)
- && bfd_is_aarch64_special_symbol_name (sym->name,
- BFD_AARCH64_SPECIAL_SYM_TYPE_ANY))
- return 0;
-
- *code_off = sym->value;
-
- /* Do not return 0 for the function's size. */
- return size ? size : 1;
-}
-
-static bool
-elfNN_aarch64_find_inliner_info (bfd *abfd,
- const char **filename_ptr,
- const char **functionname_ptr,
- unsigned int *line_ptr)
-{
- bool found;
- found = _bfd_dwarf2_find_inliner_info
- (abfd, filename_ptr,
- functionname_ptr, line_ptr, &elf_tdata (abfd)->dwarf2_find_line_info);
- return found;
-}
-
-
-static bool
-elfNN_aarch64_init_file_header (bfd *abfd, struct bfd_link_info *link_info)
-{
- Elf_Internal_Ehdr *i_ehdrp; /* ELF file header, internal form. */
-
- if (!_bfd_elf_init_file_header (abfd, link_info))
- return false;
-
- i_ehdrp = elf_elfheader (abfd);
- i_ehdrp->e_ident[EI_ABIVERSION] = AARCH64_ELF_ABI_VERSION;
- return true;
-}
-
-static enum elf_reloc_type_class
-elfNN_aarch64_reloc_type_class (const struct bfd_link_info *info ATTRIBUTE_UNUSED,
- const asection *rel_sec ATTRIBUTE_UNUSED,
- const Elf_Internal_Rela *rela)
-{
- struct elf_aarch64_link_hash_table *htab = elf_aarch64_hash_table (info);
-
- if (htab->root.dynsym != NULL
- && htab->root.dynsym->contents != NULL)
- {
- /* Check relocation against STT_GNU_IFUNC symbol if there are
- dynamic symbols. */
- bfd *abfd = info->output_bfd;
- const struct elf_backend_data *bed = get_elf_backend_data (abfd);
- unsigned long r_symndx = ELFNN_R_SYM (rela->r_info);
- if (r_symndx != STN_UNDEF)
- {
- Elf_Internal_Sym sym;
- if (!bed->s->swap_symbol_in (abfd,
- (htab->root.dynsym->contents
- + r_symndx * bed->s->sizeof_sym),
- 0, &sym))
- {
- /* xgettext:c-format */
- _bfd_error_handler (_("%pB symbol number %lu references"
- " nonexistent SHT_SYMTAB_SHNDX section"),
- abfd, r_symndx);
- /* Ideally an error class should be returned here. */
- }
- else if (ELF_ST_TYPE (sym.st_info) == STT_GNU_IFUNC)
- return reloc_class_ifunc;
- }
- }
-
- switch ((int) ELFNN_R_TYPE (rela->r_info))
- {
- case AARCH64_R (IRELATIVE):
- return reloc_class_ifunc;
- case AARCH64_R (RELATIVE):
- return reloc_class_relative;
- case AARCH64_R (JUMP_SLOT):
- return reloc_class_plt;
- case AARCH64_R (COPY):
- return reloc_class_copy;
- default:
- return reloc_class_normal;
- }
-}
-
-/* Handle an AArch64 specific section when reading an object file. This is
- called when bfd_section_from_shdr finds a section with an unknown
- type. */
-
-static bool
-elfNN_aarch64_section_from_shdr (bfd *abfd,
- Elf_Internal_Shdr *hdr,
- const char *name, int shindex)
-{
- /* There ought to be a place to keep ELF backend specific flags, but
- at the moment there isn't one. We just keep track of the
- sections by their name, instead. Fortunately, the ABI gives
- names for all the AArch64 specific sections, so we will probably get
- away with this. */
- switch (hdr->sh_type)
- {
- case SHT_AARCH64_ATTRIBUTES:
- break;
-
- default:
- return false;
- }
-
- if (!_bfd_elf_make_section_from_shdr (abfd, hdr, name, shindex))
- return false;
-
- return true;
-}
-
-/* Process any AArch64-specific program segment types. */
-
-static bool
-elfNN_aarch64_section_from_phdr (bfd *abfd ATTRIBUTE_UNUSED,
- Elf_Internal_Phdr *hdr,
- int hdr_index ATTRIBUTE_UNUSED,
- const char *name ATTRIBUTE_UNUSED)
-{
- /* Right now we only handle the PT_AARCH64_MEMTAG_MTE segment type. */
- if (hdr == NULL || hdr->p_type != PT_AARCH64_MEMTAG_MTE)
- return false;
-
- if (hdr->p_filesz > 0)
- {
- /* Sections created from memory tag p_type's are always named
- "memtag". This makes it easier for tools (for example, GDB)
- to find them. */
- asection *newsect = bfd_make_section_anyway (abfd, "memtag");
-
- if (newsect == NULL)
- return false;
-
- unsigned int opb = bfd_octets_per_byte (abfd, NULL);
-
- /* p_vaddr holds the original start address of the tagged memory
- range. */
- newsect->vma = hdr->p_vaddr / opb;
-
- /* p_filesz holds the storage size of the packed tags. */
- newsect->size = hdr->p_filesz;
- newsect->filepos = hdr->p_offset;
-
- /* p_memsz holds the size of the memory range that contains tags. The
- section's rawsize field is reused for this purpose. */
- newsect->rawsize = hdr->p_memsz;
-
- /* Make sure the section's flags has SEC_HAS_CONTENTS set, otherwise
- BFD will return all zeroes when attempting to get contents from this
- section. */
- newsect->flags |= SEC_HAS_CONTENTS;
- }
-
- return true;
-}
-
-/* Implements the bfd_elf_modify_headers hook for aarch64. */
-
-static bool
-elfNN_aarch64_modify_headers (bfd *abfd,
- struct bfd_link_info *info)
-{
- struct elf_segment_map *m;
- unsigned int segment_count = 0;
- Elf_Internal_Phdr *p;
-
- for (m = elf_seg_map (abfd); m != NULL; m = m->next, segment_count++)
- {
- /* We are only interested in the memory tag segment that will be dumped
- to a core file. If we have no memory tags or this isn't a core file we
- are dealing with, just skip this segment. */
- if (m->p_type != PT_AARCH64_MEMTAG_MTE
- || bfd_get_format (abfd) != bfd_core)
- continue;
-
- /* For memory tag segments in core files, the size of the file contents
- is smaller than the size of the memory range. Adjust the memory size
- accordingly. The real memory size is held in the section's rawsize
- field. */
- if (m->count > 0)
- {
- p = elf_tdata (abfd)->phdr;
- p += m->idx;
- p->p_memsz = m->sections[0]->rawsize;
- p->p_flags = 0;
- p->p_paddr = 0;
- p->p_align = 0;
- }
- }
-
- /* Give the generic code a chance to handle the headers. */
- return _bfd_elf_modify_headers (abfd, info);
-}
-
-/* A structure used to record a list of sections, independently
- of the next and prev fields in the asection structure. */
-typedef struct section_list
-{
- asection *sec;
- struct section_list *next;
- struct section_list *prev;
-}
-section_list;
-
-/* Unfortunately we need to keep a list of sections for which
- an _aarch64_elf_section_data structure has been allocated. This
- is because it is possible for functions like elfNN_aarch64_write_section
- to be called on a section which has had an elf_data_structure
- allocated for it (and so the used_by_bfd field is valid) but
- for which the AArch64 extended version of this structure - the
- _aarch64_elf_section_data structure - has not been allocated. */
-static section_list *sections_with_aarch64_elf_section_data = NULL;
-
-static void
-record_section_with_aarch64_elf_section_data (asection *sec)
-{
- struct section_list *entry;
-
- entry = bfd_malloc (sizeof (*entry));
- if (entry == NULL)
- return;
- entry->sec = sec;
- entry->next = sections_with_aarch64_elf_section_data;
- entry->prev = NULL;
- if (entry->next != NULL)
- entry->next->prev = entry;
- sections_with_aarch64_elf_section_data = entry;
-}
-
-static struct section_list *
-find_aarch64_elf_section_entry (asection *sec)
-{
- struct section_list *entry;
- static struct section_list *last_entry = NULL;
-
- /* This is a short cut for the typical case where the sections are added
- to the sections_with_aarch64_elf_section_data list in forward order and
- then looked up here in backwards order. This makes a real difference
- to the ld-srec/sec64k.exp linker test. */
- entry = sections_with_aarch64_elf_section_data;
- if (last_entry != NULL)
- {
- if (last_entry->sec == sec)
- entry = last_entry;
- else if (last_entry->next != NULL && last_entry->next->sec == sec)
- entry = last_entry->next;
- }
-
- for (; entry; entry = entry->next)
- if (entry->sec == sec)
- break;
-
- if (entry)
- /* Record the entry prior to this one - it is the entry we are
- most likely to want to locate next time. Also this way if we
- have been called from
- unrecord_section_with_aarch64_elf_section_data () we will not
- be caching a pointer that is about to be freed. */
- last_entry = entry->prev;
-
- return entry;
-}
-
-static void
-unrecord_section_with_aarch64_elf_section_data (asection *sec)
-{
- struct section_list *entry;
-
- entry = find_aarch64_elf_section_entry (sec);
-
- if (entry)
- {
- if (entry->prev != NULL)
- entry->prev->next = entry->next;
- if (entry->next != NULL)
- entry->next->prev = entry->prev;
- if (entry == sections_with_aarch64_elf_section_data)
- sections_with_aarch64_elf_section_data = entry->next;
- free (entry);
- }
-}
-
-
-typedef struct
-{
- void *finfo;
- struct bfd_link_info *info;
- asection *sec;
- int sec_shndx;
- int (*func) (void *, const char *, Elf_Internal_Sym *,
- asection *, struct elf_link_hash_entry *);
-} output_arch_syminfo;
-
-enum map_symbol_type
-{
- AARCH64_MAP_INSN,
- AARCH64_MAP_DATA
-};
-
-
-/* Output a single mapping symbol. */
-
-static bool
-elfNN_aarch64_output_map_sym (output_arch_syminfo *osi,
- enum map_symbol_type type, bfd_vma offset)
-{
- static const char *names[2] = { "$x", "$d" };
- Elf_Internal_Sym sym;
-
- sym.st_value = (osi->sec->output_section->vma
- + osi->sec->output_offset + offset);
- sym.st_size = 0;
- sym.st_other = 0;
- sym.st_info = ELF_ST_INFO (STB_LOCAL, STT_NOTYPE);
- sym.st_shndx = osi->sec_shndx;
- return osi->func (osi->finfo, names[type], &sym, osi->sec, NULL) == 1;
-}
-
-/* Output a single local symbol for a generated stub. */
-
-static bool
-elfNN_aarch64_output_stub_sym (output_arch_syminfo *osi, const char *name,
- bfd_vma offset, bfd_vma size)
-{
- Elf_Internal_Sym sym;
-
- sym.st_value = (osi->sec->output_section->vma
- + osi->sec->output_offset + offset);
- sym.st_size = size;
- sym.st_other = 0;
- sym.st_info = ELF_ST_INFO (STB_LOCAL, STT_FUNC);
- sym.st_shndx = osi->sec_shndx;
- return osi->func (osi->finfo, name, &sym, osi->sec, NULL) == 1;
-}
-
-static bool
-aarch64_map_one_stub (struct bfd_hash_entry *gen_entry, void *in_arg)
-{
- struct elf_aarch64_stub_hash_entry *stub_entry;
- asection *stub_sec;
- bfd_vma addr;
- char *stub_name;
- output_arch_syminfo *osi;
-
- /* Massage our args to the form they really have. */
- stub_entry = (struct elf_aarch64_stub_hash_entry *) gen_entry;
- osi = (output_arch_syminfo *) in_arg;
-
- stub_sec = stub_entry->stub_sec;
-
- /* Ensure this stub is attached to the current section being
- processed. */
- if (stub_sec != osi->sec)
- return true;
-
- addr = (bfd_vma) stub_entry->stub_offset;
-
- stub_name = stub_entry->output_name;
-
- switch (stub_entry->stub_type)
- {
- case aarch64_stub_adrp_branch:
- if (!elfNN_aarch64_output_stub_sym (osi, stub_name, addr,
- sizeof (aarch64_adrp_branch_stub)))
- return false;
- if (!elfNN_aarch64_output_map_sym (osi, AARCH64_MAP_INSN, addr))
- return false;
- break;
- case aarch64_stub_long_branch:
- if (!elfNN_aarch64_output_stub_sym
- (osi, stub_name, addr, sizeof (aarch64_long_branch_stub)))
- return false;
- if (!elfNN_aarch64_output_map_sym (osi, AARCH64_MAP_INSN, addr))
- return false;
- if (!elfNN_aarch64_output_map_sym (osi, AARCH64_MAP_DATA, addr + 16))
- return false;
- break;
- case aarch64_stub_bti_direct_branch:
- if (!elfNN_aarch64_output_stub_sym (osi, stub_name, addr,
- sizeof (aarch64_bti_direct_branch_stub)))
- return false;
- if (!elfNN_aarch64_output_map_sym (osi, AARCH64_MAP_INSN, addr))
- return false;
- break;
- case aarch64_stub_erratum_835769_veneer:
- if (!elfNN_aarch64_output_stub_sym (osi, stub_name, addr,
- sizeof (aarch64_erratum_835769_stub)))
- return false;
- if (!elfNN_aarch64_output_map_sym (osi, AARCH64_MAP_INSN, addr))
- return false;
- break;
- case aarch64_stub_erratum_843419_veneer:
- if (!elfNN_aarch64_output_stub_sym (osi, stub_name, addr,
- sizeof (aarch64_erratum_843419_stub)))
- return false;
- if (!elfNN_aarch64_output_map_sym (osi, AARCH64_MAP_INSN, addr))
- return false;
- break;
- case aarch64_stub_none:
- break;
-
- default:
- abort ();
- }
-
- return true;
-}
-
-/* Output mapping symbols for linker generated sections. */
-
-static bool
-elfNN_aarch64_output_arch_local_syms (bfd *output_bfd,
- struct bfd_link_info *info,
- void *finfo,
- int (*func) (void *, const char *,
- Elf_Internal_Sym *,
- asection *,
- struct elf_link_hash_entry
- *))
-{
- output_arch_syminfo osi;
- struct elf_aarch64_link_hash_table *htab;
-
- if (info->strip == strip_all
- && !info->emitrelocations
- && !bfd_link_relocatable (info))
- return true;
-
- htab = elf_aarch64_hash_table (info);
-
- osi.finfo = finfo;
- osi.info = info;
- osi.func = func;
-
- /* Long calls stubs. */
- if (htab->stub_bfd && htab->stub_bfd->sections)
- {
- asection *stub_sec;
-
- for (stub_sec = htab->stub_bfd->sections;
- stub_sec != NULL; stub_sec = stub_sec->next)
- {
- /* Ignore non-stub sections. */
- if (!strstr (stub_sec->name, STUB_SUFFIX))
- continue;
-
- osi.sec = stub_sec;
-
- osi.sec_shndx = _bfd_elf_section_from_bfd_section
- (output_bfd, osi.sec->output_section);
-
- /* The first instruction in a stub is always a branch. */
- if (!elfNN_aarch64_output_map_sym (&osi, AARCH64_MAP_INSN, 0))
- return false;
-
- bfd_hash_traverse (&htab->stub_hash_table, aarch64_map_one_stub,
- &osi);
- }
- }
-
- /* Finally, output mapping symbols for the PLT. */
- if (!htab->root.splt || htab->root.splt->size == 0)
- return true;
-
- osi.sec_shndx = _bfd_elf_section_from_bfd_section
- (output_bfd, htab->root.splt->output_section);
- osi.sec = htab->root.splt;
-
- elfNN_aarch64_output_map_sym (&osi, AARCH64_MAP_INSN, 0);
-
- return true;
-
-}
-
-/* Allocate target specific section data. */
-
-static bool
-elfNN_aarch64_new_section_hook (bfd *abfd, asection *sec)
-{
- if (!sec->used_by_bfd)
- {
- _aarch64_elf_section_data *sdata;
- size_t amt = sizeof (*sdata);
-
- sdata = bfd_zalloc (abfd, amt);
- if (sdata == NULL)
- return false;
- sec->used_by_bfd = sdata;
- }
-
- record_section_with_aarch64_elf_section_data (sec);
-
- return _bfd_elf_new_section_hook (abfd, sec);
-}
-
-
-static void
-unrecord_section_via_map_over_sections (bfd *abfd ATTRIBUTE_UNUSED,
- asection *sec,
- void *ignore ATTRIBUTE_UNUSED)
-{
- unrecord_section_with_aarch64_elf_section_data (sec);
-}
-
-static bool
-elfNN_aarch64_bfd_free_cached_info (bfd *abfd)
-{
- if (abfd->sections)
- bfd_map_over_sections (abfd,
- unrecord_section_via_map_over_sections, NULL);
-
- return _bfd_elf_free_cached_info (abfd);
-}
-
-/* Create dynamic sections. This is different from the ARM backend in that
- the got, plt, gotplt and their relocation sections are all created in the
- standard part of the bfd elf backend. */
-
-static bool
-elfNN_aarch64_create_dynamic_sections (bfd *dynobj,
- struct bfd_link_info *info)
-{
- /* We need to create .got section. */
- if (!aarch64_elf_create_got_section (dynobj, info))
- return false;
-
- return _bfd_elf_create_dynamic_sections (dynobj, info);
-}
-
-
-/* Allocate space in .plt, .got and associated reloc sections for
- dynamic relocs. */
-
-static bool
-elfNN_aarch64_allocate_dynrelocs (struct elf_link_hash_entry *h, void *inf)
-{
- struct bfd_link_info *info;
- struct elf_aarch64_link_hash_table *htab;
- struct elf_aarch64_link_hash_entry *eh;
- struct elf_dyn_relocs *p;
-
- /* An example of a bfd_link_hash_indirect symbol is versioned
- symbol. For example: __gxx_personality_v0(bfd_link_hash_indirect)
- -> __gxx_personality_v0(bfd_link_hash_defined)
-
- There is no need to process bfd_link_hash_indirect symbols here
- because we will also be presented with the concrete instance of
- the symbol and elfNN_aarch64_copy_indirect_symbol () will have been
- called to copy all relevant data from the generic to the concrete
- symbol instance. */
- if (h->root.type == bfd_link_hash_indirect)
- return true;
-
- if (h->root.type == bfd_link_hash_warning)
- h = (struct elf_link_hash_entry *) h->root.u.i.link;
-
- info = (struct bfd_link_info *) inf;
- htab = elf_aarch64_hash_table (info);
-
- /* Since STT_GNU_IFUNC symbol must go through PLT, we handle it
- here if it is defined and referenced in a non-shared object. */
- if (h->type == STT_GNU_IFUNC
- && h->def_regular)
- return true;
- else if (htab->root.dynamic_sections_created && h->plt.refcount > 0)
- {
- /* Make sure this symbol is output as a dynamic symbol.
- Undefined weak syms won't yet be marked as dynamic. */
- if (h->dynindx == -1 && !h->forced_local
- && h->root.type == bfd_link_hash_undefweak)
- {
- if (!bfd_elf_link_record_dynamic_symbol (info, h))
- return false;
- }
-
- if (bfd_link_pic (info) || WILL_CALL_FINISH_DYNAMIC_SYMBOL (1, 0, h))
- {
- asection *s = htab->root.splt;
-
- /* If this is the first .plt entry, make room for the special
- first entry. */
- if (s->size == 0)
- s->size += htab->plt_header_size;
-
- h->plt.offset = s->size;
-
- /* If this symbol is not defined in a regular file, and we are
- not generating a shared library, then set the symbol to this
- location in the .plt. This is required to make function
- pointers compare as equal between the normal executable and
- the shared library. */
- if (!bfd_link_pic (info) && !h->def_regular)
- {
- h->root.u.def.section = s;
- h->root.u.def.value = h->plt.offset;
- }
-
- /* Make room for this entry. For now we only create the
- small model PLT entries. We later need to find a way
- of relaxing into these from the large model PLT entries. */
- s->size += htab->plt_entry_size;
-
- /* We also need to make an entry in the .got.plt section, which
- will be placed in the .got section by the linker script. */
- htab->root.sgotplt->size += GOT_ENTRY_SIZE;
-
- /* We also need to make an entry in the .rela.plt section. */
- htab->root.srelplt->size += RELOC_SIZE (htab);
-
- /* We need to ensure that all GOT entries that serve the PLT
- are consecutive with the special GOT slots [0] [1] and
- [2]. Any addtional relocations, such as
- R_AARCH64_TLSDESC, must be placed after the PLT related
- entries. We abuse the reloc_count such that during
- sizing we adjust reloc_count to indicate the number of
- PLT related reserved entries. In subsequent phases when
- filling in the contents of the reloc entries, PLT related
- entries are placed by computing their PLT index (0
- .. reloc_count). While other none PLT relocs are placed
- at the slot indicated by reloc_count and reloc_count is
- updated. */
-
- htab->root.srelplt->reloc_count++;
-
- /* Mark the DSO in case R_<CLS>_JUMP_SLOT relocs against
- variant PCS symbols are present. */
- if (h->other & STO_AARCH64_VARIANT_PCS)
- htab->variant_pcs = 1;
-
- }
- else
- {
- h->plt.offset = (bfd_vma) - 1;
- h->needs_plt = 0;
- }
- }
- else
- {
- h->plt.offset = (bfd_vma) - 1;
- h->needs_plt = 0;
- }
-
- eh = (struct elf_aarch64_link_hash_entry *) h;
- eh->tlsdesc_got_jump_table_offset = (bfd_vma) - 1;
-
- if (h->got.refcount > 0)
- {
- bool dyn;
- unsigned got_type = elf_aarch64_hash_entry (h)->got_type;
-
- h->got.offset = (bfd_vma) - 1;
-
- dyn = htab->root.dynamic_sections_created;
-
- /* Make sure this symbol is output as a dynamic symbol.
- Undefined weak syms won't yet be marked as dynamic. */
- if (dyn && h->dynindx == -1 && !h->forced_local
- && h->root.type == bfd_link_hash_undefweak)
- {
- if (!bfd_elf_link_record_dynamic_symbol (info, h))
- return false;
- }
-
- if (got_type == GOT_UNKNOWN)
- {
- }
- else if (got_type == GOT_NORMAL)
- {
- h->got.offset = htab->root.sgot->size;
- htab->root.sgot->size += GOT_ENTRY_SIZE;
- if ((ELF_ST_VISIBILITY (h->other) == STV_DEFAULT
- || h->root.type != bfd_link_hash_undefweak)
- && (bfd_link_pic (info)
- || WILL_CALL_FINISH_DYNAMIC_SYMBOL (dyn, 0, h))
- /* Undefined weak symbol in static PIE resolves to 0 without
- any dynamic relocations. */
- && !UNDEFWEAK_NO_DYNAMIC_RELOC (info, h))
- {
- htab->root.srelgot->size += RELOC_SIZE (htab);
- }
- }
- else
- {
- int indx;
- if (got_type & GOT_TLSDESC_GD)
- {
- eh->tlsdesc_got_jump_table_offset =
- (htab->root.sgotplt->size
- - aarch64_compute_jump_table_size (htab));
- htab->root.sgotplt->size += GOT_ENTRY_SIZE * 2;
- h->got.offset = (bfd_vma) - 2;
- }
-
- if (got_type & GOT_TLS_GD)
- {
- h->got.offset = htab->root.sgot->size;
- htab->root.sgot->size += GOT_ENTRY_SIZE * 2;
- }
-
- if (got_type & GOT_TLS_IE)
- {
- h->got.offset = htab->root.sgot->size;
- htab->root.sgot->size += GOT_ENTRY_SIZE;
- }
-
- indx = h && h->dynindx != -1 ? h->dynindx : 0;
- if ((ELF_ST_VISIBILITY (h->other) == STV_DEFAULT
- || h->root.type != bfd_link_hash_undefweak)
- && (!bfd_link_executable (info)
- || indx != 0
- || WILL_CALL_FINISH_DYNAMIC_SYMBOL (dyn, 0, h)))
- {
- if (got_type & GOT_TLSDESC_GD)
- {
- htab->root.srelplt->size += RELOC_SIZE (htab);
- /* Note reloc_count not incremented here! We have
- already adjusted reloc_count for this relocation
- type. */
-
- /* TLSDESC PLT is now needed, but not yet determined. */
- htab->root.tlsdesc_plt = (bfd_vma) - 1;
- }
-
- if (got_type & GOT_TLS_GD)
- htab->root.srelgot->size += RELOC_SIZE (htab) * 2;
-
- if (got_type & GOT_TLS_IE)
- htab->root.srelgot->size += RELOC_SIZE (htab);
- }
- }
- }
- else
- {
- h->got.offset = (bfd_vma) - 1;
- }
-
- if (h->dyn_relocs == NULL)
- return true;
-
- for (p = h->dyn_relocs; p != NULL; p = p->next)
- if (eh->def_protected)
- {
- /* Disallow copy relocations against protected symbol. */
- asection *s = p->sec->output_section;
- if (s != NULL && (s->flags & SEC_READONLY) != 0)
- {
- info->callbacks->einfo
- /* xgettext:c-format */
- (_ ("%F%P: %pB: copy relocation against non-copyable "
- "protected symbol `%s'\n"),
- p->sec->owner, h->root.root.string);
- return false;
- }
- }
-
- /* In the shared -Bsymbolic case, discard space allocated for
- dynamic pc-relative relocs against symbols which turn out to be
- defined in regular objects. For the normal shared case, discard
- space for pc-relative relocs that have become local due to symbol
- visibility changes. */
-
- if (bfd_link_pic (info))
- {
- /* Relocs that use pc_count are those that appear on a call
- insn, or certain REL relocs that can generated via assembly.
- We want calls to protected symbols to resolve directly to the
- function rather than going via the plt. If people want
- function pointer comparisons to work as expected then they
- should avoid writing weird assembly. */
- if (SYMBOL_CALLS_LOCAL (info, h))
- {
- struct elf_dyn_relocs **pp;
-
- for (pp = &h->dyn_relocs; (p = *pp) != NULL;)
- {
- p->count -= p->pc_count;
- p->pc_count = 0;
- if (p->count == 0)
- *pp = p->next;
- else
- pp = &p->next;
- }
- }
-
- /* Also discard relocs on undefined weak syms with non-default
- visibility. */
- if (h->dyn_relocs != NULL && h->root.type == bfd_link_hash_undefweak)
- {
- if (ELF_ST_VISIBILITY (h->other) != STV_DEFAULT
- || UNDEFWEAK_NO_DYNAMIC_RELOC (info, h))
- h->dyn_relocs = NULL;
-
- /* Make sure undefined weak symbols are output as a dynamic
- symbol in PIEs. */
- else if (h->dynindx == -1
- && !h->forced_local
- && h->root.type == bfd_link_hash_undefweak
- && !bfd_elf_link_record_dynamic_symbol (info, h))
- return false;
- }
-
- }
- else if (ELIMINATE_COPY_RELOCS)
- {
- /* For the non-shared case, discard space for relocs against
- symbols which turn out to need copy relocs or are not
- dynamic. */
-
- if (!h->non_got_ref
- && ((h->def_dynamic
- && !h->def_regular)
- || (htab->root.dynamic_sections_created
- && (h->root.type == bfd_link_hash_undefweak
- || h->root.type == bfd_link_hash_undefined))))
- {
- /* Make sure this symbol is output as a dynamic symbol.
- Undefined weak syms won't yet be marked as dynamic. */
- if (h->dynindx == -1
- && !h->forced_local
- && h->root.type == bfd_link_hash_undefweak
- && !bfd_elf_link_record_dynamic_symbol (info, h))
- return false;
-
- /* If that succeeded, we know we'll be keeping all the
- relocs. */
- if (h->dynindx != -1)
- goto keep;
- }
-
- h->dyn_relocs = NULL;
-
- keep:;
- }
-
- /* Finally, allocate space. */
- for (p = h->dyn_relocs; p != NULL; p = p->next)
- {
- asection *sreloc;
-
- sreloc = elf_section_data (p->sec)->sreloc;
-
- BFD_ASSERT (sreloc != NULL);
-
- sreloc->size += p->count * RELOC_SIZE (htab);
- }
-
- return true;
-}
-
-/* Allocate space in .plt, .got and associated reloc sections for
- ifunc dynamic relocs. */
-
-static bool
-elfNN_aarch64_allocate_ifunc_dynrelocs (struct elf_link_hash_entry *h,
- void *inf)
-{
- struct bfd_link_info *info;
- struct elf_aarch64_link_hash_table *htab;
-
- /* An example of a bfd_link_hash_indirect symbol is versioned
- symbol. For example: __gxx_personality_v0(bfd_link_hash_indirect)
- -> __gxx_personality_v0(bfd_link_hash_defined)
-
- There is no need to process bfd_link_hash_indirect symbols here
- because we will also be presented with the concrete instance of
- the symbol and elfNN_aarch64_copy_indirect_symbol () will have been
- called to copy all relevant data from the generic to the concrete
- symbol instance. */
- if (h->root.type == bfd_link_hash_indirect)
- return true;
-
- if (h->root.type == bfd_link_hash_warning)
- h = (struct elf_link_hash_entry *) h->root.u.i.link;
-
- info = (struct bfd_link_info *) inf;
- htab = elf_aarch64_hash_table (info);
-
- /* Since STT_GNU_IFUNC symbol must go through PLT, we handle it
- here if it is defined and referenced in a non-shared object. */
- if (h->type == STT_GNU_IFUNC
- && h->def_regular)
- return _bfd_elf_allocate_ifunc_dyn_relocs (info, h,
- &h->dyn_relocs,
- htab->plt_entry_size,
- htab->plt_header_size,
- GOT_ENTRY_SIZE,
- false);
- return true;
-}
-
-/* Allocate space in .plt, .got and associated reloc sections for
- local ifunc dynamic relocs. */
-
-static int
-elfNN_aarch64_allocate_local_ifunc_dynrelocs (void **slot, void *inf)
-{
- struct elf_link_hash_entry *h
- = (struct elf_link_hash_entry *) *slot;
-
- if (h->type != STT_GNU_IFUNC
- || !h->def_regular
- || !h->ref_regular
- || !h->forced_local
- || h->root.type != bfd_link_hash_defined)
- abort ();
-
- return elfNN_aarch64_allocate_ifunc_dynrelocs (h, inf);
-}
-
-/* Record a relative relocation that will be emitted packed (DT_RELR).
- Called after relocation sections are sized, so undo the size accounting
- for this relocation. */
-
-static bool
-record_relr (struct elf_aarch64_link_hash_table *htab, asection *sec,
- bfd_vma off, asection *sreloc)
-{
- /* Undo the relocation section size accounting. */
- BFD_ASSERT (sreloc->size >= RELOC_SIZE (htab));
- sreloc->size -= RELOC_SIZE (htab);
- /* The packing format uses the last bit of the address so that
- must be aligned. We don't pack relocations that may not be
- aligned even though the final output address could end up
- aligned, to avoid complex sizing logic for a rare case. */
- BFD_ASSERT (off % 2 == 0 && sec->alignment_power > 0);
- if (htab->relr_count >= htab->relr_alloc)
- {
- if (htab->relr_alloc == 0)
- htab->relr_alloc = 4096;
- else
- htab->relr_alloc *= 2;
- htab->relr = bfd_realloc (htab->relr,
- htab->relr_alloc * sizeof (*htab->relr));
- if (htab->relr == NULL)
- return false;
- }
- htab->relr[htab->relr_count].sec = sec;
- htab->relr[htab->relr_count].off = off;
- htab->relr_count++;
- return true;
-}
-
-/* Follow elfNN_aarch64_allocate_dynrelocs, but only record relative
- relocations against the GOT and undo their previous size accounting. */
-
-static bool
-record_relr_dyn_got_relocs (struct elf_link_hash_entry *h, void *inf)
-{
-
- if (h->root.type == bfd_link_hash_indirect)
- return true;
- if (h->root.type == bfd_link_hash_warning)
- h = (struct elf_link_hash_entry *) h->root.u.i.link;
- if (h->type == STT_GNU_IFUNC && h->def_regular)
- return true;
- if (h->got.refcount <= 0)
- return true;
- if (elf_aarch64_hash_entry (h)->got_type != GOT_NORMAL)
- return true;
-
- struct bfd_link_info *info = (struct bfd_link_info *) inf;
- struct elf_aarch64_link_hash_table *htab = elf_aarch64_hash_table (info);
-
- if ((ELF_ST_VISIBILITY (h->other) == STV_DEFAULT
- || h->root.type != bfd_link_hash_undefweak)
- && bfd_link_pic (info)
- /* Undefined weak symbol in static PIE resolves to 0 without
- any dynamic relocations. */
- && !UNDEFWEAK_NO_DYNAMIC_RELOC (info, h))
- {
- bool relative_reloc = SYMBOL_REFERENCES_LOCAL (info, h)
- && !bfd_is_abs_symbol (&h->root);
- if (relative_reloc)
- if (!record_relr (htab, htab->root.sgot, h->got.offset,
- htab->root.srelgot))
- return false;
- }
- return true;
-}
-
-/* Record packed relative relocs against the GOT for local symbols.
- Undo the size accounting of elfNN_aarch64_late_size_sections. */
-
-static bool
-record_relr_local_got_relocs (bfd *input_bfd, struct bfd_link_info *info)
-{
- struct elf_aarch64_local_symbol *locals;
- Elf_Internal_Shdr *symtab_hdr;
- struct elf_aarch64_link_hash_table *htab;
-
- if (!bfd_link_pic (info))
- return true;
-
- locals = elf_aarch64_locals (input_bfd);
- if (locals == NULL)
- return true;
-
- symtab_hdr = &elf_symtab_hdr (input_bfd);
- htab = elf_aarch64_hash_table (info);
- for (unsigned int i = 0; i < symtab_hdr->sh_info; i++)
- {
- bfd_vma off = locals[i].got_offset;
- if (locals[i].got_refcount <= 0)
- continue;
- if ((locals[i].got_type & GOT_NORMAL) == 0)
- continue;
-
- /* FIXME: If the local symbol is in SHN_ABS then emitting
- a relative relocation is not correct, but it seems to
- be wrong in elfNN_aarch64_final_link_relocate too. */
- if (!record_relr (htab, htab->root.sgot, off, htab->root.srelgot))
- return false;
- }
- return true;
-}
-
-/* Follows the logic of elfNN_aarch64_relocate_section to decide which
- relocations will become relative and possible to pack. Ignore
- relocations against the GOT, those are handled separately per-symbol.
- Undo the size accounting of the packed relocations and record them
- so the relr section can be sized later. */
-
-static bool
-record_relr_non_got_relocs (bfd *input_bfd, struct bfd_link_info *info,
- asection *sec)
-{
- const Elf_Internal_Rela *relocs;
- const Elf_Internal_Rela *rel;
- const Elf_Internal_Rela *rel_end;
- asection *sreloc;
- struct elf_aarch64_link_hash_table *htab;
- Elf_Internal_Shdr *symtab_hdr;
- struct elf_link_hash_entry **sym_hashes;
-
- if (sec->reloc_count == 0)
- return true;
- if ((sec->flags & (SEC_RELOC | SEC_ALLOC | SEC_DEBUGGING))
- != (SEC_RELOC | SEC_ALLOC))
- return true;
- if (sec->alignment_power == 0)
- return true;
- if (discarded_section (sec))
- return true;
- sreloc = elf_section_data (sec)->sreloc;
- if (sreloc == NULL)
- return true;
- htab = elf_aarch64_hash_table (info);
- symtab_hdr = &elf_symtab_hdr (input_bfd);
- sym_hashes = elf_sym_hashes (input_bfd);
- relocs = _bfd_elf_link_info_read_relocs (input_bfd, info, sec, NULL, NULL,
- info->keep_memory);
- BFD_ASSERT (relocs != NULL);
- rel_end = relocs + sec->reloc_count;
- for (rel = relocs; rel < rel_end; rel++)
- {
- unsigned int r_symndx = ELFNN_R_SYM (rel->r_info);
- unsigned int r_type = ELFNN_R_TYPE (rel->r_info);
-
- bfd_reloc_code_real_type bfd_r_type
- = elfNN_aarch64_bfd_reloc_from_type (input_bfd, r_type);
- /* Handle relocs that can become R_AARCH64_RELATIVE,
- but not ones against the GOT as those are handled
- separately per-symbol. */
- if (bfd_r_type != BFD_RELOC_AARCH64_NN)
- continue;
- /* Can only pack relocation against an aligned address. */
- if (rel->r_offset % 2 != 0)
- continue;
-
- struct elf_link_hash_entry *h = NULL;
- asection *def_sec = NULL;
- bool resolved_to_zero = false;
- if (r_symndx < symtab_hdr->sh_info)
- {
- /* A local symbol. */
- Elf_Internal_Sym *isym;
- isym = bfd_sym_from_r_symndx (&htab->root.sym_cache,
- input_bfd, r_symndx);
- BFD_ASSERT (isym != NULL);
- if (ELF_ST_TYPE (isym->st_info) == STT_GNU_IFUNC)
- continue;
- def_sec = bfd_section_from_elf_index (input_bfd, isym->st_shndx);
- }
- else
- {
- h = sym_hashes[r_symndx - symtab_hdr->sh_info];
- while (h->root.type == bfd_link_hash_indirect
- || h->root.type == bfd_link_hash_warning)
- h = (struct elf_link_hash_entry *) h->root.u.i.link;
-
- /* Filter out symbols that cannot have a relative reloc. */
- if (h->dyn_relocs == NULL)
- continue;
- if (bfd_is_abs_symbol (&h->root))
- continue;
- if (h->type == STT_GNU_IFUNC)
- continue;
-
- if (h->root.type == bfd_link_hash_defined
- || h->root.type == bfd_link_hash_defweak)
- def_sec = h->root.u.def.section;
- resolved_to_zero = UNDEFWEAK_NO_DYNAMIC_RELOC (info, h);
- }
- if (def_sec != NULL && discarded_section (def_sec))
- continue;
- /* Same logic as in elfNN_aarch64_final_link_relocate.
- Except conditionals trimmed that cannot result a reltive reloc. */
- if (bfd_link_pic (info)
- && (h == NULL
- || (ELF_ST_VISIBILITY (h->other) == STV_DEFAULT
- && !resolved_to_zero)
- || h->root.type != bfd_link_hash_undefweak))
- {
- if (h != NULL
- && h->dynindx != -1
- && (!(bfd_link_pie (info) || SYMBOLIC_BIND (info, h))
- || !h->def_regular))
- continue;
- if (!record_relr (htab, sec, rel->r_offset, sreloc))
- return false;
- }
- }
- return true;
-}
-
-static int
-cmp_relr_addr (const void *p, const void *q)
-{
- const bfd_vma *a = p;
- const bfd_vma *b = q;
- return *a < *b ? -1 : *a > *b ? 1 : 0;
-}
-
-/* Produce a malloc'd sorted array of reloc addresses in htab->relr_sorted.
- Returns false on allocation failure. */
-
-static bool
-sort_relr (struct bfd_link_info *info,
- struct elf_aarch64_link_hash_table *htab)
-{
- if (htab->relr_count == 0)
- return true;
-
- bfd_vma *addr = htab->relr_sorted;
- if (addr == NULL)
- {
- addr = bfd_malloc (htab->relr_count * sizeof (*addr));
- if (addr == NULL)
- return false;
- htab->relr_sorted = addr;
- }
-
- for (bfd_size_type i = 0; i < htab->relr_count; i++)
- {
- bfd_vma off = _bfd_elf_section_offset (info->output_bfd, info,
- htab->relr[i].sec,
- htab->relr[i].off);
- addr[i] = htab->relr[i].sec->output_section->vma
- + htab->relr[i].sec->output_offset
- + off;
- }
- qsort (addr, htab->relr_count, sizeof (*addr), cmp_relr_addr);
- return true;
-}
-
-/* Size of a relr entry and a relocated location. */
-#define RELR_SZ (ARCH_SIZE / 8)
-/* Number of consecutive locations a relr bitmap entry references. */
-#define RELR_N (ARCH_SIZE - 1)
-
-/* Size .relr.dyn whenever the layout changes, the number of packed
- relocs are unchanged but the packed representation can. */
-
-bool
-elfNN_aarch64_size_relative_relocs (struct bfd_link_info *info,
- bool *need_layout)
-{
- struct elf_aarch64_link_hash_table *htab = elf_aarch64_hash_table (info);
- asection *srelrdyn = htab->root.srelrdyn;
- *need_layout = false;
-
- if (!sort_relr (info, htab))
- return false;
- bfd_vma *addr = htab->relr_sorted;
-
- BFD_ASSERT (srelrdyn != NULL);
- bfd_size_type oldsize = srelrdyn->size;
- srelrdyn->size = 0;
- for (bfd_size_type i = 0; i < htab->relr_count; )
- {
- bfd_vma base = addr[i];
- i++;
- srelrdyn->size += RELR_SZ;
- base += RELR_SZ;
- for (;;)
- {
- bfd_size_type start_i = i;
- while (i < htab->relr_count
- && addr[i] - base < RELR_N * RELR_SZ
- && (addr[i] - base) % RELR_SZ == 0)
- i++;
- if (i == start_i)
- break;
- srelrdyn->size += RELR_SZ;
- base += RELR_N * RELR_SZ;
- }
- }
- if (srelrdyn->size != oldsize)
- {
- *need_layout = true;
- /* Stop after a few iterations in case the layout does not converge,
- we can do this when the size would shrink. */
- if (htab->relr_layout_iter++ > 5 && srelrdyn->size < oldsize)
- {
- srelrdyn->size = oldsize;
- *need_layout = false;
- }
- }
- return true;
-}
-
-/* Emit the .relr.dyn section after it is sized and the layout is fixed. */
-
-bool
-elfNN_aarch64_finish_relative_relocs (struct bfd_link_info *info)
-{
- struct elf_aarch64_link_hash_table *htab = elf_aarch64_hash_table (info);
- asection *srelrdyn = htab->root.srelrdyn;
- bfd *dynobj = htab->root.dynobj;
-
- if (srelrdyn == NULL || srelrdyn->size == 0)
- return true;
- srelrdyn->contents = bfd_alloc (dynobj, srelrdyn->size);
- if (srelrdyn->contents == NULL)
- return false;
- bfd_vma *addr = htab->relr_sorted;
- bfd_byte *loc = srelrdyn->contents;
- for (bfd_size_type i = 0; i < htab->relr_count; )
- {
- bfd_vma base = addr[i];
- i++;
- bfd_put_NN (dynobj, base, loc);
- loc += RELR_SZ;
- base += RELR_SZ;
- for (;;)
- {
- bfd_vma bits = 0;
- while (i < htab->relr_count)
- {
- bfd_vma delta = addr[i] - base;
- if (delta >= RELR_N * RELR_SZ || delta % RELR_SZ != 0)
- break;
- bits |= (bfd_vma) 1 << (delta / RELR_SZ);
- i++;
- }
- if (bits == 0)
- break;
- bfd_put_NN (dynobj, (bits << 1) | 1, loc);
- loc += RELR_SZ;
- base += RELR_N * RELR_SZ;
- }
- }
- free (addr);
- htab->relr_sorted = NULL;
- /* Pad any excess with 1's, a do-nothing encoding. */
- while (loc < srelrdyn->contents + srelrdyn->size)
- {
- bfd_put_NN (dynobj, 1, loc);
- loc += RELR_SZ;
- }
- return true;
-}
-
-/* This is the most important function of all . Innocuosly named
- though ! */
-
-static bool
-elfNN_aarch64_late_size_sections (bfd *output_bfd ATTRIBUTE_UNUSED,
- struct bfd_link_info *info)
-{
- struct elf_aarch64_link_hash_table *htab;
- bfd *dynobj;
- asection *s;
- bool relocs;
- bfd *ibfd;
-
- htab = elf_aarch64_hash_table ((info));
- dynobj = htab->root.dynobj;
-
- if (dynobj == NULL)
- return true;
-
- if (htab->root.dynamic_sections_created)
- {
- if (bfd_link_executable (info) && !info->nointerp)
- {
- s = bfd_get_linker_section (dynobj, ".interp");
- if (s == NULL)
- abort ();
- s->size = sizeof ELF_DYNAMIC_INTERPRETER;
- s->contents = (unsigned char *) ELF_DYNAMIC_INTERPRETER;
- }
- }
-
- /* Set up .got offsets for local syms, and space for local dynamic
- relocs. */
- for (ibfd = info->input_bfds; ibfd != NULL; ibfd = ibfd->link.next)
- {
- struct elf_aarch64_local_symbol *locals = NULL;
- Elf_Internal_Shdr *symtab_hdr;
- asection *srel;
- unsigned int i;
-
- if (!is_aarch64_elf (ibfd))
- continue;
-
- for (s = ibfd->sections; s != NULL; s = s->next)
- {
- struct elf_dyn_relocs *p;
-
- for (p = (struct elf_dyn_relocs *)
- (elf_section_data (s)->local_dynrel); p != NULL; p = p->next)
- {
- if (discarded_section (p->sec))
- {
- /* Input section has been discarded, either because
- it is a copy of a linkonce section or due to
- linker script /DISCARD/, so we'll be discarding
- the relocs too. */
- }
- else if (p->count != 0)
- {
- srel = elf_section_data (p->sec)->sreloc;
- srel->size += p->count * RELOC_SIZE (htab);
- if ((p->sec->output_section->flags & SEC_READONLY) != 0)
- info->flags |= DF_TEXTREL;
- }
- }
- }
-
- locals = elf_aarch64_locals (ibfd);
- if (!locals)
- continue;
-
- symtab_hdr = &elf_symtab_hdr (ibfd);
- srel = htab->root.srelgot;
- for (i = 0; i < symtab_hdr->sh_info; i++)
- {
- locals[i].got_offset = (bfd_vma) - 1;
- locals[i].tlsdesc_got_jump_table_offset = (bfd_vma) - 1;
- if (locals[i].got_refcount > 0)
- {
- unsigned got_type = locals[i].got_type;
- if (got_type & GOT_TLSDESC_GD)
- {
- locals[i].tlsdesc_got_jump_table_offset =
- (htab->root.sgotplt->size
- - aarch64_compute_jump_table_size (htab));
- htab->root.sgotplt->size += GOT_ENTRY_SIZE * 2;
- locals[i].got_offset = (bfd_vma) - 2;
- }
-
- if (got_type & GOT_TLS_GD)
- {
- locals[i].got_offset = htab->root.sgot->size;
- htab->root.sgot->size += GOT_ENTRY_SIZE * 2;
- }
-
- if (got_type & GOT_TLS_IE
- || got_type & GOT_NORMAL)
- {
- locals[i].got_offset = htab->root.sgot->size;
- htab->root.sgot->size += GOT_ENTRY_SIZE;
- }
-
- if (got_type == GOT_UNKNOWN)
- {
- }
-
- if (bfd_link_pic (info))
- {
- if (got_type & GOT_TLSDESC_GD)
- {
- htab->root.srelplt->size += RELOC_SIZE (htab);
- /* Note RELOC_COUNT not incremented here! */
- htab->root.tlsdesc_plt = (bfd_vma) - 1;
- }
-
- if (got_type & GOT_TLS_GD)
- htab->root.srelgot->size += RELOC_SIZE (htab) * 2;
-
- if (got_type & GOT_TLS_IE
- || got_type & GOT_NORMAL)
- htab->root.srelgot->size += RELOC_SIZE (htab);
- }
- }
- else
- {
- locals[i].got_refcount = (bfd_vma) - 1;
- }
- }
- }
-
-
- /* Allocate global sym .plt and .got entries, and space for global
- sym dynamic relocs. */
- elf_link_hash_traverse (&htab->root, elfNN_aarch64_allocate_dynrelocs,
- info);
-
- /* Allocate global ifunc sym .plt and .got entries, and space for global
- ifunc sym dynamic relocs. */
- elf_link_hash_traverse (&htab->root, elfNN_aarch64_allocate_ifunc_dynrelocs,
- info);
-
- /* Allocate .plt and .got entries, and space for local ifunc symbols. */
- htab_traverse (htab->loc_hash_table,
- elfNN_aarch64_allocate_local_ifunc_dynrelocs,
- info);
-
- /* For every jump slot reserved in the sgotplt, reloc_count is
- incremented. However, when we reserve space for TLS descriptors,
- it's not incremented, so in order to compute the space reserved
- for them, it suffices to multiply the reloc count by the jump
- slot size. */
-
- if (htab->root.srelplt)
- htab->sgotplt_jump_table_size = aarch64_compute_jump_table_size (htab);
-
- if (htab->root.tlsdesc_plt)
- {
- if (htab->root.splt->size == 0)
- htab->root.splt->size += htab->plt_header_size;
-
- /* If we're not using lazy TLS relocations, don't generate the
- GOT and PLT entry required. */
- if ((info->flags & DF_BIND_NOW))
- htab->root.tlsdesc_plt = 0;
- else
- {
- htab->root.tlsdesc_plt = htab->root.splt->size;
- htab->root.splt->size += htab->tlsdesc_plt_entry_size;
-
- htab->root.tlsdesc_got = htab->root.sgot->size;
- htab->root.sgot->size += GOT_ENTRY_SIZE;
- }
- }
-
- /* Record the relative relocations that will be packed and undo the
- size allocation for them in .rela.*. The size of .relr.dyn will be
- computed later iteratively since it depends on the final layout. */
- if (info->enable_dt_relr && !bfd_link_relocatable (info))
- {
- elf_link_hash_traverse (&htab->root, record_relr_dyn_got_relocs, info);
-
- for (ibfd = info->input_bfds; ibfd != NULL; ibfd = ibfd->link.next)
- {
- if (!is_aarch64_elf (ibfd))
- continue;
-
- for (s = ibfd->sections; s != NULL; s = s->next)
- if (!record_relr_non_got_relocs (ibfd, info, s))
- return false;
-
- if (!record_relr_local_got_relocs (ibfd, info))
- return false;
- }
- }
-
- /* Init mapping symbols information to use later to distingush between
- code and data while scanning for errata. */
- if (htab->fix_erratum_835769 || htab->fix_erratum_843419)
- for (ibfd = info->input_bfds; ibfd != NULL; ibfd = ibfd->link.next)
- {
- if (!is_aarch64_elf (ibfd))
- continue;
- bfd_elfNN_aarch64_init_maps (ibfd);
- }
-
- /* We now have determined the sizes of the various dynamic sections.
- Allocate memory for them. */
- relocs = false;
- for (s = dynobj->sections; s != NULL; s = s->next)
- {
- if ((s->flags & SEC_LINKER_CREATED) == 0)
- continue;
-
- if (s == htab->root.splt
- || s == htab->root.sgot
- || s == htab->root.sgotplt
- || s == htab->root.iplt
- || s == htab->root.igotplt
- || s == htab->root.sdynbss
- || s == htab->root.sdynrelro)
- {
- /* Strip this section if we don't need it; see the
- comment below. */
- }
- else if (startswith (bfd_section_name (s), ".rela"))
- {
- if (s->size != 0 && s != htab->root.srelplt)
- relocs = true;
-
- /* We use the reloc_count field as a counter if we need
- to copy relocs into the output file. */
- if (s != htab->root.srelplt)
- s->reloc_count = 0;
- }
- else if (s == htab->root.srelrdyn)
- {
- /* Remove .relr.dyn based on relr_count, not size, since
- it is not sized yet. */
- if (htab->relr_count == 0)
- s->flags |= SEC_EXCLUDE;
- else
- /* Force dynamic tags for relocs even if there are no
- .rela* relocs, required for setting DT_TEXTREL. */
- relocs = true;
- /* Allocate contents later. */
- continue;
- }
- else
- {
- /* It's not one of our sections, so don't allocate space. */
- continue;
- }
-
- if (s->size == 0)
- {
- /* If we don't need this section, strip it from the
- output file. This is mostly to handle .rela.bss and
- .rela.plt. We must create both sections in
- create_dynamic_sections, because they must be created
- before the linker maps input sections to output
- sections. The linker does that before
- adjust_dynamic_symbol is called, and it is that
- function which decides whether anything needs to go
- into these sections. */
- s->flags |= SEC_EXCLUDE;
- continue;
- }
-
- if ((s->flags & SEC_HAS_CONTENTS) == 0)
- continue;
-
- /* Allocate memory for the section contents. We use bfd_zalloc
- here in case unused entries are not reclaimed before the
- section's contents are written out. This should not happen,
- but this way if it does, we get a R_AARCH64_NONE reloc instead
- of garbage. */
- s->contents = (bfd_byte *) bfd_zalloc (dynobj, s->size);
- if (s->contents == NULL)
- return false;
- }
-
- if (htab->root.dynamic_sections_created)
- {
- /* Add some entries to the .dynamic section. We fill in the
- values later, in elfNN_aarch64_finish_dynamic_sections, but we
- must add the entries now so that we get the correct size for
- the .dynamic section. The DT_DEBUG entry is filled in by the
- dynamic linker and used by the debugger. */
-#define add_dynamic_entry(TAG, VAL) \
- _bfd_elf_add_dynamic_entry (info, TAG, VAL)
-
- if (!_bfd_elf_add_dynamic_tags (output_bfd, info, relocs))
- return false;
-
- if (htab->root.splt->size != 0)
- {
- if (htab->variant_pcs
- && !add_dynamic_entry (DT_AARCH64_VARIANT_PCS, 0))
- return false;
-
- if ((elf_aarch64_tdata (output_bfd)->plt_type == PLT_BTI_PAC)
- && (!add_dynamic_entry (DT_AARCH64_BTI_PLT, 0)
- || !add_dynamic_entry (DT_AARCH64_PAC_PLT, 0)))
- return false;
-
- else if ((elf_aarch64_tdata (output_bfd)->plt_type == PLT_BTI)
- && !add_dynamic_entry (DT_AARCH64_BTI_PLT, 0))
- return false;
-
- else if ((elf_aarch64_tdata (output_bfd)->plt_type == PLT_PAC)
- && !add_dynamic_entry (DT_AARCH64_PAC_PLT, 0))
- return false;
- }
- }
-#undef add_dynamic_entry
-
- return true;
-}
-
-static inline void
-elf_aarch64_update_plt_entry (bfd *output_bfd,
- bfd_reloc_code_real_type r_type,
- bfd_byte *plt_entry, bfd_vma value)
-{
- reloc_howto_type *howto = elfNN_aarch64_howto_from_bfd_reloc (r_type);
-
- /* FIXME: We should check the return value from this function call. */
- (void) _bfd_aarch64_elf_put_addend (output_bfd, plt_entry, r_type, howto, value);
-}
-
-static void
-elfNN_aarch64_create_small_pltn_entry (struct elf_link_hash_entry *h,
- struct elf_aarch64_link_hash_table
- *htab, bfd *output_bfd,
- struct bfd_link_info *info)
-{
- bfd_byte *plt_entry;
- bfd_vma plt_index;
- bfd_vma got_offset;
- bfd_vma gotplt_entry_address;
- bfd_vma plt_entry_address;
- Elf_Internal_Rela rela;
- bfd_byte *loc;
- asection *plt, *gotplt, *relplt;
-
- /* When building a static executable, use .iplt, .igot.plt and
- .rela.iplt sections for STT_GNU_IFUNC symbols. */
- if (htab->root.splt != NULL)
- {
- plt = htab->root.splt;
- gotplt = htab->root.sgotplt;
- relplt = htab->root.srelplt;
- }
- else
- {
- plt = htab->root.iplt;
- gotplt = htab->root.igotplt;
- relplt = htab->root.irelplt;
- }
-
- /* Get the index in the procedure linkage table which
- corresponds to this symbol. This is the index of this symbol
- in all the symbols for which we are making plt entries. The
- first entry in the procedure linkage table is reserved.
-
- Get the offset into the .got table of the entry that
- corresponds to this function. Each .got entry is GOT_ENTRY_SIZE
- bytes. The first three are reserved for the dynamic linker.
-
- For static executables, we don't reserve anything. */
-
- if (plt == htab->root.splt)
- {
- plt_index = (h->plt.offset - htab->plt_header_size) / htab->plt_entry_size;
- got_offset = (plt_index + 3) * GOT_ENTRY_SIZE;
- }
- else
- {
- plt_index = h->plt.offset / htab->plt_entry_size;
- got_offset = plt_index * GOT_ENTRY_SIZE;
- }
-
- plt_entry = plt->contents + h->plt.offset;
- plt_entry_address = plt->output_section->vma
- + plt->output_offset + h->plt.offset;
- gotplt_entry_address = gotplt->output_section->vma +
- gotplt->output_offset + got_offset;
-
- /* Copy in the boiler-plate for the PLTn entry. */
- memcpy (plt_entry, htab->plt_entry, htab->plt_entry_size);
-
- /* First instruction in BTI enabled PLT stub is a BTI
- instruction so skip it. */
- if (elf_aarch64_tdata (output_bfd)->plt_type & PLT_BTI
- && elf_elfheader (output_bfd)->e_type == ET_EXEC)
- plt_entry = plt_entry + 4;
-
- /* Fill in the top 21 bits for this: ADRP x16, PLT_GOT + n * 8.
- ADRP: ((PG(S+A)-PG(P)) >> 12) & 0x1fffff */
- elf_aarch64_update_plt_entry (output_bfd, BFD_RELOC_AARCH64_ADR_HI21_PCREL,
- plt_entry,
- PG (gotplt_entry_address) -
- PG (plt_entry_address));
-
- /* Fill in the lo12 bits for the load from the pltgot. */
- elf_aarch64_update_plt_entry (output_bfd, BFD_RELOC_AARCH64_LDSTNN_LO12,
- plt_entry + 4,
- PG_OFFSET (gotplt_entry_address));
-
- /* Fill in the lo12 bits for the add from the pltgot entry. */
- elf_aarch64_update_plt_entry (output_bfd, BFD_RELOC_AARCH64_ADD_LO12,
- plt_entry + 8,
- PG_OFFSET (gotplt_entry_address));
-
- /* All the GOTPLT Entries are essentially initialized to PLT0. */
- bfd_put_NN (output_bfd,
- plt->output_section->vma + plt->output_offset,
- gotplt->contents + got_offset);
-
- rela.r_offset = gotplt_entry_address;
-
- if (h->dynindx == -1
- || ((bfd_link_executable (info)
- || ELF_ST_VISIBILITY (h->other) != STV_DEFAULT)
- && h->def_regular
- && h->type == STT_GNU_IFUNC))
- {
- /* If an STT_GNU_IFUNC symbol is locally defined, generate
- R_AARCH64_IRELATIVE instead of R_AARCH64_JUMP_SLOT. */
- rela.r_info = ELFNN_R_INFO (0, AARCH64_R (IRELATIVE));
- rela.r_addend = (h->root.u.def.value
- + h->root.u.def.section->output_section->vma
- + h->root.u.def.section->output_offset);
- }
- else
- {
- /* Fill in the entry in the .rela.plt section. */
- rela.r_info = ELFNN_R_INFO (h->dynindx, AARCH64_R (JUMP_SLOT));
- rela.r_addend = 0;
- }
-
- /* Compute the relocation entry to used based on PLT index and do
- not adjust reloc_count. The reloc_count has already been adjusted
- to account for this entry. */
- loc = relplt->contents + plt_index * RELOC_SIZE (htab);
- bfd_elfNN_swap_reloca_out (output_bfd, &rela, loc);
-}
-
-/* Size sections even though they're not dynamic. We use it to setup
- _TLS_MODULE_BASE_, if needed. */
-
-static bool
-elfNN_aarch64_early_size_sections (bfd *output_bfd,
- struct bfd_link_info *info)
-{
- asection *tls_sec;
-
- if (bfd_link_relocatable (info))
- return true;
-
- tls_sec = elf_hash_table (info)->tls_sec;
-
- if (tls_sec)
- {
- struct elf_link_hash_entry *tlsbase;
-
- tlsbase = elf_link_hash_lookup (elf_hash_table (info),
- "_TLS_MODULE_BASE_", true, true, false);
-
- if (tlsbase)
- {
- struct bfd_link_hash_entry *h = NULL;
- const struct elf_backend_data *bed =
- get_elf_backend_data (output_bfd);
-
- if (!(_bfd_generic_link_add_one_symbol
- (info, output_bfd, "_TLS_MODULE_BASE_", BSF_LOCAL,
- tls_sec, 0, NULL, false, bed->collect, &h)))
- return false;
-
- tlsbase->type = STT_TLS;
- tlsbase = (struct elf_link_hash_entry *) h;
- tlsbase->def_regular = 1;
- tlsbase->other = STV_HIDDEN;
- (*bed->elf_backend_hide_symbol) (info, tlsbase, true);
- }
- }
-
- return true;
-}
-
-/* Finish up dynamic symbol handling. We set the contents of various
- dynamic sections here. */
-
-static bool
-elfNN_aarch64_finish_dynamic_symbol (bfd *output_bfd,
- struct bfd_link_info *info,
- struct elf_link_hash_entry *h,
- Elf_Internal_Sym *sym)
-{
- struct elf_aarch64_link_hash_table *htab;
- htab = elf_aarch64_hash_table (info);
-
- if (h->plt.offset != (bfd_vma) - 1)
- {
- asection *plt, *gotplt, *relplt;
-
- /* This symbol has an entry in the procedure linkage table. Set
- it up. */
-
- /* When building a static executable, use .iplt, .igot.plt and
- .rela.iplt sections for STT_GNU_IFUNC symbols. */
- if (htab->root.splt != NULL)
- {
- plt = htab->root.splt;
- gotplt = htab->root.sgotplt;
- relplt = htab->root.srelplt;
- }
- else
- {
- plt = htab->root.iplt;
- gotplt = htab->root.igotplt;
- relplt = htab->root.irelplt;
- }
-
- /* This symbol has an entry in the procedure linkage table. Set
- it up. */
- if ((h->dynindx == -1
- && !((h->forced_local || bfd_link_executable (info))
- && h->def_regular
- && h->type == STT_GNU_IFUNC))
- || plt == NULL
- || gotplt == NULL
- || relplt == NULL)
- abort ();
-
- elfNN_aarch64_create_small_pltn_entry (h, htab, output_bfd, info);
- if (!h->def_regular)
- {
- /* Mark the symbol as undefined, rather than as defined in
- the .plt section. */
- sym->st_shndx = SHN_UNDEF;
- /* If the symbol is weak we need to clear the value.
- Otherwise, the PLT entry would provide a definition for
- the symbol even if the symbol wasn't defined anywhere,
- and so the symbol would never be NULL. Leave the value if
- there were any relocations where pointer equality matters
- (this is a clue for the dynamic linker, to make function
- pointer comparisons work between an application and shared
- library). */
- if (!h->ref_regular_nonweak || !h->pointer_equality_needed)
- sym->st_value = 0;
- }
- }
-
- if (h->got.offset != (bfd_vma) - 1
- && elf_aarch64_hash_entry (h)->got_type == GOT_NORMAL
- /* Undefined weak symbol in static PIE resolves to 0 without
- any dynamic relocations. */
- && !UNDEFWEAK_NO_DYNAMIC_RELOC (info, h))
- {
- Elf_Internal_Rela rela;
- bfd_byte *loc;
-
- /* This symbol has an entry in the global offset table. Set it
- up. */
- if (htab->root.sgot == NULL || htab->root.srelgot == NULL)
- abort ();
-
- rela.r_offset = (htab->root.sgot->output_section->vma
- + htab->root.sgot->output_offset
- + (h->got.offset & ~(bfd_vma) 1));
-
- if (h->def_regular
- && h->type == STT_GNU_IFUNC)
- {
- if (bfd_link_pic (info))
- {
- /* Generate R_AARCH64_GLOB_DAT. */
- goto do_glob_dat;
- }
- else
- {
- asection *plt;
-
- if (!h->pointer_equality_needed)
- abort ();
-
- /* For non-shared object, we can't use .got.plt, which
- contains the real function address if we need pointer
- equality. We load the GOT entry with the PLT entry. */
- plt = htab->root.splt ? htab->root.splt : htab->root.iplt;
- bfd_put_NN (output_bfd, (plt->output_section->vma
- + plt->output_offset
- + h->plt.offset),
- htab->root.sgot->contents
- + (h->got.offset & ~(bfd_vma) 1));
- return true;
- }
- }
- else if (bfd_link_pic (info) && SYMBOL_REFERENCES_LOCAL (info, h))
- {
- if (!(h->def_regular || ELF_COMMON_DEF_P (h)))
- return false;
- BFD_ASSERT ((h->got.offset & 1) != 0);
- /* Don't emit relative relocs if they are packed. */
- if (info->enable_dt_relr)
- goto skip_got_reloc;
- rela.r_info = ELFNN_R_INFO (0, AARCH64_R (RELATIVE));
- rela.r_addend = (h->root.u.def.value
- + h->root.u.def.section->output_section->vma
- + h->root.u.def.section->output_offset);
- }
- else
- {
- do_glob_dat:
- BFD_ASSERT ((h->got.offset & 1) == 0);
- bfd_put_NN (output_bfd, (bfd_vma) 0,
- htab->root.sgot->contents + h->got.offset);
- rela.r_info = ELFNN_R_INFO (h->dynindx, AARCH64_R (GLOB_DAT));
- rela.r_addend = 0;
- }
-
- loc = htab->root.srelgot->contents;
- loc += htab->root.srelgot->reloc_count++ * RELOC_SIZE (htab);
- bfd_elfNN_swap_reloca_out (output_bfd, &rela, loc);
- }
-skip_got_reloc:
-
- if (h->needs_copy)
- {
- Elf_Internal_Rela rela;
- asection *s;
- bfd_byte *loc;
-
- /* This symbol needs a copy reloc. Set it up. */
- if (h->dynindx == -1
- || (h->root.type != bfd_link_hash_defined
- && h->root.type != bfd_link_hash_defweak)
- || htab->root.srelbss == NULL)
- abort ();
-
- rela.r_offset = (h->root.u.def.value
- + h->root.u.def.section->output_section->vma
- + h->root.u.def.section->output_offset);
- rela.r_info = ELFNN_R_INFO (h->dynindx, AARCH64_R (COPY));
- rela.r_addend = 0;
- if (h->root.u.def.section == htab->root.sdynrelro)
- s = htab->root.sreldynrelro;
- else
- s = htab->root.srelbss;
- loc = s->contents + s->reloc_count++ * RELOC_SIZE (htab);
- bfd_elfNN_swap_reloca_out (output_bfd, &rela, loc);
- }
-
- /* Mark _DYNAMIC and _GLOBAL_OFFSET_TABLE_ as absolute. SYM may
- be NULL for local symbols. */
- if (sym != NULL
- && (h == elf_hash_table (info)->hdynamic
- || h == elf_hash_table (info)->hgot))
- sym->st_shndx = SHN_ABS;
-
- return true;
-}
-
-/* Finish up local dynamic symbol handling. We set the contents of
- various dynamic sections here. */
-
-static int
-elfNN_aarch64_finish_local_dynamic_symbol (void **slot, void *inf)
-{
- struct elf_link_hash_entry *h
- = (struct elf_link_hash_entry *) *slot;
- struct bfd_link_info *info
- = (struct bfd_link_info *) inf;
-
- return elfNN_aarch64_finish_dynamic_symbol (info->output_bfd,
- info, h, NULL);
-}
-
-static void
-elfNN_aarch64_init_small_plt0_entry (bfd *output_bfd ATTRIBUTE_UNUSED,
- struct elf_aarch64_link_hash_table
- *htab)
-{
- /* Fill in PLT0. Fixme:RR Note this doesn't distinguish between
- small and large plts and at the minute just generates
- the small PLT. */
-
- /* PLT0 of the small PLT looks like this in ELF64 -
- stp x16, x30, [sp, #-16]! // Save the reloc and lr on stack.
- adrp x16, PLT_GOT + 16 // Get the page base of the GOTPLT
- ldr x17, [x16, #:lo12:PLT_GOT+16] // Load the address of the
- // symbol resolver
- add x16, x16, #:lo12:PLT_GOT+16 // Load the lo12 bits of the
- // GOTPLT entry for this.
- br x17
- PLT0 will be slightly different in ELF32 due to different got entry
- size. */
- bfd_vma plt_got_2nd_ent; /* Address of GOT[2]. */
- bfd_vma plt_base;
-
-
- memcpy (htab->root.splt->contents, htab->plt0_entry,
- htab->plt_header_size);
-
- /* PR 26312: Explicitly set the sh_entsize to 0 so that
- consumers do not think that the section contains fixed
- sized objects. */
- elf_section_data (htab->root.splt->output_section)->this_hdr.sh_entsize = 0;
-
- plt_got_2nd_ent = (htab->root.sgotplt->output_section->vma
- + htab->root.sgotplt->output_offset
- + GOT_ENTRY_SIZE * 2);
-
- plt_base = htab->root.splt->output_section->vma +
- htab->root.splt->output_offset;
-
- /* First instruction in BTI enabled PLT stub is a BTI
- instruction so skip it. */
- bfd_byte *plt0_entry = htab->root.splt->contents;
- if (elf_aarch64_tdata (output_bfd)->plt_type & PLT_BTI)
- plt0_entry = plt0_entry + 4;
-
- /* Fill in the top 21 bits for this: ADRP x16, PLT_GOT + n * 8.
- ADRP: ((PG(S+A)-PG(P)) >> 12) & 0x1fffff */
- elf_aarch64_update_plt_entry (output_bfd, BFD_RELOC_AARCH64_ADR_HI21_PCREL,
- plt0_entry + 4,
- PG (plt_got_2nd_ent) - PG (plt_base + 4));
-
- elf_aarch64_update_plt_entry (output_bfd, BFD_RELOC_AARCH64_LDSTNN_LO12,
- plt0_entry + 8,
- PG_OFFSET (plt_got_2nd_ent));
-
- elf_aarch64_update_plt_entry (output_bfd, BFD_RELOC_AARCH64_ADD_LO12,
- plt0_entry + 12,
- PG_OFFSET (plt_got_2nd_ent));
-}
-
-static bool
-elfNN_aarch64_finish_dynamic_sections (bfd *output_bfd,
- struct bfd_link_info *info)
-{
- struct elf_aarch64_link_hash_table *htab;
- bfd *dynobj;
- asection *sdyn;
-
- htab = elf_aarch64_hash_table (info);
- dynobj = htab->root.dynobj;
- sdyn = bfd_get_linker_section (dynobj, ".dynamic");
-
- if (htab->root.dynamic_sections_created)
- {
- ElfNN_External_Dyn *dyncon, *dynconend;
-
- if (sdyn == NULL || htab->root.sgot == NULL)
- abort ();
-
- dyncon = (ElfNN_External_Dyn *) sdyn->contents;
- dynconend = (ElfNN_External_Dyn *) (sdyn->contents + sdyn->size);
- for (; dyncon < dynconend; dyncon++)
- {
- Elf_Internal_Dyn dyn;
- asection *s;
-
- bfd_elfNN_swap_dyn_in (dynobj, dyncon, &dyn);
-
- switch (dyn.d_tag)
- {
- default:
- continue;
-
- case DT_PLTGOT:
- s = htab->root.sgotplt;
- dyn.d_un.d_ptr = s->output_section->vma + s->output_offset;
- break;
-
- case DT_JMPREL:
- s = htab->root.srelplt;
- dyn.d_un.d_ptr = s->output_section->vma + s->output_offset;
- break;
-
- case DT_PLTRELSZ:
- s = htab->root.srelplt;
- dyn.d_un.d_val = s->size;
- break;
-
- case DT_TLSDESC_PLT:
- s = htab->root.splt;
- dyn.d_un.d_ptr = s->output_section->vma + s->output_offset
- + htab->root.tlsdesc_plt;
- break;
-
- case DT_TLSDESC_GOT:
- s = htab->root.sgot;
- BFD_ASSERT (htab->root.tlsdesc_got != (bfd_vma)-1);
- dyn.d_un.d_ptr = s->output_section->vma + s->output_offset
- + htab->root.tlsdesc_got;
- break;
- }
-
- bfd_elfNN_swap_dyn_out (output_bfd, &dyn, dyncon);
- }
-
- }
-
- /* Fill in the special first entry in the procedure linkage table. */
- if (htab->root.splt && htab->root.splt->size > 0)
- {
- elfNN_aarch64_init_small_plt0_entry (output_bfd, htab);
-
- if (htab->root.tlsdesc_plt && !(info->flags & DF_BIND_NOW))
- {
- BFD_ASSERT (htab->root.tlsdesc_got != (bfd_vma)-1);
- bfd_put_NN (output_bfd, (bfd_vma) 0,
- htab->root.sgot->contents + htab->root.tlsdesc_got);
-
- const bfd_byte *entry = elfNN_aarch64_tlsdesc_small_plt_entry;
- htab->tlsdesc_plt_entry_size = PLT_TLSDESC_ENTRY_SIZE;
-
- aarch64_plt_type type = elf_aarch64_tdata (output_bfd)->plt_type;
- if (type == PLT_BTI || type == PLT_BTI_PAC)
- {
- entry = elfNN_aarch64_tlsdesc_small_plt_bti_entry;
- }
-
- memcpy (htab->root.splt->contents + htab->root.tlsdesc_plt,
- entry, htab->tlsdesc_plt_entry_size);
-
- {
- bfd_vma adrp1_addr =
- htab->root.splt->output_section->vma
- + htab->root.splt->output_offset
- + htab->root.tlsdesc_plt + 4;
-
- bfd_vma adrp2_addr = adrp1_addr + 4;
-
- bfd_vma got_addr =
- htab->root.sgot->output_section->vma
- + htab->root.sgot->output_offset;
-
- bfd_vma pltgot_addr =
- htab->root.sgotplt->output_section->vma
- + htab->root.sgotplt->output_offset;
-
- bfd_vma dt_tlsdesc_got = got_addr + htab->root.tlsdesc_got;
-
- bfd_byte *plt_entry =
- htab->root.splt->contents + htab->root.tlsdesc_plt;
-
- /* First instruction in BTI enabled PLT stub is a BTI
- instruction so skip it. */
- if (type & PLT_BTI)
- {
- plt_entry = plt_entry + 4;
- adrp1_addr = adrp1_addr + 4;
- adrp2_addr = adrp2_addr + 4;
- }
-
- /* adrp x2, DT_TLSDESC_GOT */
- elf_aarch64_update_plt_entry (output_bfd,
- BFD_RELOC_AARCH64_ADR_HI21_PCREL,
- plt_entry + 4,
- (PG (dt_tlsdesc_got)
- - PG (adrp1_addr)));
-
- /* adrp x3, 0 */
- elf_aarch64_update_plt_entry (output_bfd,
- BFD_RELOC_AARCH64_ADR_HI21_PCREL,
- plt_entry + 8,
- (PG (pltgot_addr)
- - PG (adrp2_addr)));
-
- /* ldr x2, [x2, #0] */
- elf_aarch64_update_plt_entry (output_bfd,
- BFD_RELOC_AARCH64_LDSTNN_LO12,
- plt_entry + 12,
- PG_OFFSET (dt_tlsdesc_got));
-
- /* add x3, x3, 0 */
- elf_aarch64_update_plt_entry (output_bfd,
- BFD_RELOC_AARCH64_ADD_LO12,
- plt_entry + 16,
- PG_OFFSET (pltgot_addr));
- }
- }
- }
-
- if (htab->root.sgotplt)
- {
- if (bfd_is_abs_section (htab->root.sgotplt->output_section))
- {
- _bfd_error_handler
- (_("discarded output section: `%pA'"), htab->root.sgotplt);
- return false;
- }
-
- /* Fill in the first three entries in the global offset table. */
- if (htab->root.sgotplt->size > 0)
- {
- bfd_put_NN (output_bfd, (bfd_vma) 0, htab->root.sgotplt->contents);
-
- /* Write GOT[1] and GOT[2], needed for the dynamic linker. */
- bfd_put_NN (output_bfd,
- (bfd_vma) 0,
- htab->root.sgotplt->contents + GOT_ENTRY_SIZE);
- bfd_put_NN (output_bfd,
- (bfd_vma) 0,
- htab->root.sgotplt->contents + GOT_ENTRY_SIZE * 2);
- }
-
- if (htab->root.sgot)
- {
- if (htab->root.sgot->size > 0)
- {
- bfd_vma addr =
- sdyn ? sdyn->output_section->vma + sdyn->output_offset : 0;
- bfd_put_NN (output_bfd, addr, htab->root.sgot->contents);
- }
- }
-
- elf_section_data (htab->root.sgotplt->output_section)->
- this_hdr.sh_entsize = GOT_ENTRY_SIZE;
- }
-
- if (htab->root.sgot && htab->root.sgot->size > 0)
- elf_section_data (htab->root.sgot->output_section)->this_hdr.sh_entsize
- = GOT_ENTRY_SIZE;
-
- /* Fill PLT and GOT entries for local STT_GNU_IFUNC symbols. */
- htab_traverse (htab->loc_hash_table,
- elfNN_aarch64_finish_local_dynamic_symbol,
- info);
-
- return true;
-}
-
-/* Check if BTI enabled PLTs are needed. Returns the type needed. */
-static aarch64_plt_type
-get_plt_type (bfd *abfd)
-{
- aarch64_plt_type ret = PLT_NORMAL;
- bfd_byte *contents, *extdyn, *extdynend;
- asection *sec = bfd_get_section_by_name (abfd, ".dynamic");
- if (!sec
- || (sec->flags & SEC_HAS_CONTENTS) == 0
- || sec->size < sizeof (ElfNN_External_Dyn)
- || !bfd_malloc_and_get_section (abfd, sec, &contents))
- return ret;
- extdyn = contents;
- extdynend = contents + sec->size - sizeof (ElfNN_External_Dyn);
- for (; extdyn <= extdynend; extdyn += sizeof (ElfNN_External_Dyn))
- {
- Elf_Internal_Dyn dyn;
- bfd_elfNN_swap_dyn_in (abfd, extdyn, &dyn);
-
- /* Let's check the processor specific dynamic array tags. */
- bfd_vma tag = dyn.d_tag;
- if (tag < DT_LOPROC || tag > DT_HIPROC)
- continue;
-
- switch (tag)
- {
- case DT_AARCH64_BTI_PLT:
- ret |= PLT_BTI;
- break;
-
- case DT_AARCH64_PAC_PLT:
- ret |= PLT_PAC;
- break;
-
- default: break;
- }
- }
- free (contents);
- return ret;
-}
-
-static long
-elfNN_aarch64_get_synthetic_symtab (bfd *abfd,
- long symcount,
- asymbol **syms,
- long dynsymcount,
- asymbol **dynsyms,
- asymbol **ret)
-{
- elf_aarch64_tdata (abfd)->plt_type = get_plt_type (abfd);
- return _bfd_elf_get_synthetic_symtab (abfd, symcount, syms,
- dynsymcount, dynsyms, ret);
-}
-
-/* Return address for Ith PLT stub in section PLT, for relocation REL
- or (bfd_vma) -1 if it should not be included. */
-
-static bfd_vma
-elfNN_aarch64_plt_sym_val (bfd_vma i, const asection *plt,
- const arelent *rel ATTRIBUTE_UNUSED)
-{
- size_t plt0_size = PLT_ENTRY_SIZE;
- size_t pltn_size = PLT_SMALL_ENTRY_SIZE;
-
- if (elf_aarch64_tdata (plt->owner)->plt_type == PLT_BTI_PAC)
- {
- if (elf_elfheader (plt->owner)->e_type == ET_EXEC)
- pltn_size = PLT_BTI_PAC_SMALL_ENTRY_SIZE;
- else
- pltn_size = PLT_PAC_SMALL_ENTRY_SIZE;
- }
- else if (elf_aarch64_tdata (plt->owner)->plt_type == PLT_BTI)
- {
- if (elf_elfheader (plt->owner)->e_type == ET_EXEC)
- pltn_size = PLT_BTI_SMALL_ENTRY_SIZE;
- }
- else if (elf_aarch64_tdata (plt->owner)->plt_type == PLT_PAC)
- {
- pltn_size = PLT_PAC_SMALL_ENTRY_SIZE;
- }
-
- return plt->vma + plt0_size + i * pltn_size;
-}
-
-/* Returns TRUE if NAME is an AArch64 mapping symbol.
- The ARM ELF standard defines $x (for A64 code) and $d (for data).
- It also allows a period initiated suffix to be added to the symbol, ie:
- "$[adtx]\.[:sym_char]+". */
-
-static bool
-is_aarch64_mapping_symbol (const char * name)
-{
- return name != NULL /* Paranoia. */
- && name[0] == '$' /* Note: if objcopy --prefix-symbols has been used then
- the mapping symbols could have acquired a prefix.
- We do not support this here, since such symbols no
- longer conform to the ARM ELF ABI. */
- && (name[1] == 'd' || name[1] == 'x')
- && (name[2] == 0 || name[2] == '.');
- /* FIXME: Strictly speaking the symbol is only a valid mapping symbol if
- any characters that follow the period are legal characters for the body
- of a symbol's name. For now we just assume that this is the case. */
-}
-
-/* Make sure that mapping symbols in object files are not removed via the
- "strip --strip-unneeded" tool. These symbols might needed in order to
- correctly generate linked files. Once an object file has been linked,
- it should be safe to remove them. */
-
-static void
-elfNN_aarch64_backend_symbol_processing (bfd *abfd, asymbol *sym)
-{
- if (((abfd->flags & (EXEC_P | DYNAMIC)) == 0)
- && sym->section != bfd_abs_section_ptr
- && is_aarch64_mapping_symbol (sym->name))
- sym->flags |= BSF_KEEP;
-}
-
-/* Implement elf_backend_setup_gnu_properties for AArch64. It serves as a
- wrapper function for _bfd_aarch64_elf_link_setup_gnu_properties to account
- for the effect of GNU properties of the output_bfd. */
-static bfd *
-elfNN_aarch64_link_setup_gnu_properties (struct bfd_link_info *info)
-{
- uint32_t prop = elf_aarch64_tdata (info->output_bfd)->gnu_and_prop;
- bfd *pbfd = _bfd_aarch64_elf_link_setup_gnu_properties (info, &prop);
- elf_aarch64_tdata (info->output_bfd)->gnu_and_prop = prop;
- elf_aarch64_tdata (info->output_bfd)->plt_type
- |= (prop & GNU_PROPERTY_AARCH64_FEATURE_1_BTI) ? PLT_BTI : 0;
- setup_plt_values (info, elf_aarch64_tdata (info->output_bfd)->plt_type);
- return pbfd;
-}
-
-/* Implement elf_backend_merge_gnu_properties for AArch64. It serves as a
- wrapper function for _bfd_aarch64_elf_merge_gnu_properties to account
- for the effect of GNU properties of the output_bfd. */
-static bool
-elfNN_aarch64_merge_gnu_properties (struct bfd_link_info *info,
- bfd *abfd, bfd *bbfd,
- elf_property *aprop,
- elf_property *bprop)
-{
- uint32_t prop
- = elf_aarch64_tdata (info->output_bfd)->gnu_and_prop;
-
- /* If output has been marked with BTI using command line argument, give out
- warning if necessary. */
- /* Properties are merged per type, hence only check for warnings when merging
- GNU_PROPERTY_AARCH64_FEATURE_1_AND. */
- if (((aprop && aprop->pr_type == GNU_PROPERTY_AARCH64_FEATURE_1_AND)
- || (bprop && bprop->pr_type == GNU_PROPERTY_AARCH64_FEATURE_1_AND))
- && (prop & GNU_PROPERTY_AARCH64_FEATURE_1_BTI)
- && (!elf_aarch64_tdata (info->output_bfd)->no_bti_warn))
- {
- if ((aprop && !(aprop->u.number & GNU_PROPERTY_AARCH64_FEATURE_1_BTI))
- || !aprop)
- {
- _bfd_error_handler (_("%pB: warning: BTI turned on by -z force-bti when "
- "all inputs do not have BTI in NOTE section."),
- abfd);
- }
- if ((bprop && !(bprop->u.number & GNU_PROPERTY_AARCH64_FEATURE_1_BTI))
- || !bprop)
- {
- _bfd_error_handler (_("%pB: warning: BTI turned on by -z force-bti when "
- "all inputs do not have BTI in NOTE section."),
- bbfd);
- }
- }
-
- return _bfd_aarch64_elf_merge_gnu_properties (info, abfd, aprop,
- bprop, prop);
-}
-
-/* We use this so we can override certain functions
- (though currently we don't). */
-
-const struct elf_size_info elfNN_aarch64_size_info =
-{
- sizeof (ElfNN_External_Ehdr),
- sizeof (ElfNN_External_Phdr),
- sizeof (ElfNN_External_Shdr),
- sizeof (ElfNN_External_Rel),
- sizeof (ElfNN_External_Rela),
- sizeof (ElfNN_External_Sym),
- sizeof (ElfNN_External_Dyn),
- sizeof (Elf_External_Note),
- 4, /* Hash table entry size. */
- 1, /* Internal relocs per external relocs. */
- ARCH_SIZE, /* Arch size. */
- LOG_FILE_ALIGN, /* Log_file_align. */
- ELFCLASSNN, EV_CURRENT,
- bfd_elfNN_write_out_phdrs,
- bfd_elfNN_write_shdrs_and_ehdr,
- bfd_elfNN_checksum_contents,
- bfd_elfNN_write_relocs,
- bfd_elfNN_swap_symbol_in,
- bfd_elfNN_swap_symbol_out,
- bfd_elfNN_slurp_reloc_table,
- bfd_elfNN_slurp_symbol_table,
- bfd_elfNN_swap_dyn_in,
- bfd_elfNN_swap_dyn_out,
- bfd_elfNN_swap_reloc_in,
- bfd_elfNN_swap_reloc_out,
- bfd_elfNN_swap_reloca_in,
- bfd_elfNN_swap_reloca_out
-};
-
-#define ELF_ARCH bfd_arch_aarch64
-#define ELF_MACHINE_CODE EM_AARCH64
-#define ELF_MAXPAGESIZE 0x10000
-#define ELF_COMMONPAGESIZE 0x1000
-
-#define bfd_elfNN_bfd_free_cached_info \
- elfNN_aarch64_bfd_free_cached_info
-
-#define bfd_elfNN_bfd_is_target_special_symbol \
- elfNN_aarch64_is_target_special_symbol
-
-#define bfd_elfNN_bfd_link_hash_table_create \
- elfNN_aarch64_link_hash_table_create
-
-#define bfd_elfNN_bfd_merge_private_bfd_data \
- elfNN_aarch64_merge_private_bfd_data
-
-#define bfd_elfNN_bfd_print_private_bfd_data \
- elfNN_aarch64_print_private_bfd_data
-
-#define bfd_elfNN_bfd_reloc_type_lookup \
- elfNN_aarch64_reloc_type_lookup
-
-#define bfd_elfNN_bfd_reloc_name_lookup \
- elfNN_aarch64_reloc_name_lookup
-
-#define bfd_elfNN_bfd_set_private_flags \
- elfNN_aarch64_set_private_flags
-
-#define bfd_elfNN_find_inliner_info \
- elfNN_aarch64_find_inliner_info
-
-#define bfd_elfNN_get_synthetic_symtab \
- elfNN_aarch64_get_synthetic_symtab
-
-#define bfd_elfNN_mkobject \
- elfNN_aarch64_mkobject
-
-#define bfd_elfNN_new_section_hook \
- elfNN_aarch64_new_section_hook
-
-#define elf_backend_adjust_dynamic_symbol \
- elfNN_aarch64_adjust_dynamic_symbol
-
-#define elf_backend_early_size_sections \
- elfNN_aarch64_early_size_sections
-
-#define elf_backend_check_relocs \
- elfNN_aarch64_check_relocs
-
-#define elf_backend_copy_indirect_symbol \
- elfNN_aarch64_copy_indirect_symbol
-
-#define elf_backend_merge_symbol_attribute \
- elfNN_aarch64_merge_symbol_attribute
-
-/* Create .dynbss, and .rela.bss sections in DYNOBJ, and set up shortcuts
- to them in our hash. */
-#define elf_backend_create_dynamic_sections \
- elfNN_aarch64_create_dynamic_sections
-
-#define elf_backend_init_index_section \
- _bfd_elf_init_2_index_sections
-
-#define elf_backend_finish_dynamic_sections \
- elfNN_aarch64_finish_dynamic_sections
-
-#define elf_backend_finish_dynamic_symbol \
- elfNN_aarch64_finish_dynamic_symbol
-
-#define elf_backend_object_p \
- elfNN_aarch64_object_p
-
-#define elf_backend_output_arch_local_syms \
- elfNN_aarch64_output_arch_local_syms
-
-#define elf_backend_maybe_function_sym \
- elfNN_aarch64_maybe_function_sym
-
-#define elf_backend_plt_sym_val \
- elfNN_aarch64_plt_sym_val
-
-#define elf_backend_init_file_header \
- elfNN_aarch64_init_file_header
-
-#define elf_backend_relocate_section \
- elfNN_aarch64_relocate_section
-
-#define elf_backend_reloc_type_class \
- elfNN_aarch64_reloc_type_class
-
-#define elf_backend_section_from_shdr \
- elfNN_aarch64_section_from_shdr
-
-#define elf_backend_section_from_phdr \
- elfNN_aarch64_section_from_phdr
-
-#define elf_backend_modify_headers \
- elfNN_aarch64_modify_headers
-
-#define elf_backend_late_size_sections \
- elfNN_aarch64_late_size_sections
-
-#define elf_backend_size_info \
- elfNN_aarch64_size_info
-
-#define elf_backend_write_section \
- elfNN_aarch64_write_section
-
-#define elf_backend_symbol_processing \
- elfNN_aarch64_backend_symbol_processing
-
-#define elf_backend_setup_gnu_properties \
- elfNN_aarch64_link_setup_gnu_properties
-
-#define elf_backend_merge_gnu_properties \
- elfNN_aarch64_merge_gnu_properties
-
-#define elf_backend_size_relative_relocs \
- elfNN_aarch64_size_relative_relocs
-
-#define elf_backend_finish_relative_relocs \
- elfNN_aarch64_finish_relative_relocs
-
-#define elf_backend_can_refcount 1
-#define elf_backend_can_gc_sections 1
-#define elf_backend_plt_readonly 1
-#define elf_backend_want_got_plt 1
-#define elf_backend_want_plt_sym 0
-#define elf_backend_want_dynrelro 1
-#define elf_backend_may_use_rel_p 0
-#define elf_backend_may_use_rela_p 1
-#define elf_backend_default_use_rela_p 1
-#define elf_backend_rela_normal 1
-#define elf_backend_dtrel_excludes_plt 1
-#define elf_backend_got_header_size (GOT_ENTRY_SIZE * 3)
-#define elf_backend_default_execstack 0
-#define elf_backend_extern_protected_data 0
-#define elf_backend_hash_symbol elf_aarch64_hash_symbol
-
-#undef elf_backend_obj_attrs_section
-#define elf_backend_obj_attrs_section ".ARM.attributes"
-
-#include "elfNN-target.h"
-
-/* CloudABI support. */
-
-#undef TARGET_LITTLE_SYM
-#define TARGET_LITTLE_SYM aarch64_elfNN_le_cloudabi_vec
-#undef TARGET_LITTLE_NAME
-#define TARGET_LITTLE_NAME "elfNN-littleaarch64-cloudabi"
-#undef TARGET_BIG_SYM
-#define TARGET_BIG_SYM aarch64_elfNN_be_cloudabi_vec
-#undef TARGET_BIG_NAME
-#define TARGET_BIG_NAME "elfNN-bigaarch64-cloudabi"
-
-#undef ELF_OSABI
-#define ELF_OSABI ELFOSABI_CLOUDABI
-
-#undef elfNN_bed
-#define elfNN_bed elfNN_aarch64_cloudabi_bed
-
-#include "elfNN-target.h"
Index: sources/GNU/binutils/create-2.43.1-readelf-other-sym-info-patch/file.list
===================================================================
--- sources/GNU/binutils/create-2.43.1-readelf-other-sym-info-patch/file.list (revision 75)
+++ sources/GNU/binutils/create-2.43.1-readelf-other-sym-info-patch/file.list (nonexistent)
@@ -1 +0,0 @@
-binutils-2.43.1/binutils/readelf.c
Index: sources/GNU/binutils/create-2.43.1-readelf-other-sym-info-patch/create.patch.sh
===================================================================
--- sources/GNU/binutils/create-2.43.1-readelf-other-sym-info-patch/create.patch.sh (revision 75)
+++ sources/GNU/binutils/create-2.43.1-readelf-other-sym-info-patch/create.patch.sh (nonexistent)
@@ -1,15 +0,0 @@
-#!/bin/bash
-
-VERSION=2.43.1
-
-tar --files-from=file.list -xJvf ../binutils-$VERSION.tar.xz
-mv binutils-$VERSION binutils-$VERSION-orig
-
-cp -rf ./binutils-$VERSION-new ./binutils-$VERSION
-
-diff --unified -Nr binutils-$VERSION-orig binutils-$VERSION > binutils-$VERSION-readelf-other-sym-info.patch
-
-mv binutils-$VERSION-readelf-other-sym-info.patch ../patches
-
-rm -rf ./binutils-$VERSION
-rm -rf ./binutils-$VERSION-orig
Property changes on: sources/GNU/binutils/create-2.43.1-readelf-other-sym-info-patch/create.patch.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: sources/GNU/binutils/create-2.43.1-readelf-other-sym-info-patch/binutils-2.43.1-new/binutils/readelf.c
===================================================================
--- sources/GNU/binutils/create-2.43.1-readelf-other-sym-info-patch/binutils-2.43.1-new/binutils/readelf.c (revision 75)
+++ sources/GNU/binutils/create-2.43.1-readelf-other-sym-info-patch/binutils-2.43.1-new/binutils/readelf.c (nonexistent)
@@ -1,24286 +0,0 @@
-/* readelf.c -- display contents of an ELF format file
- Copyright (C) 1998-2024 Free Software Foundation, Inc.
-
- Originally developed by Eric Youngdale <eric@andante.jic.com>
- Modifications by Nick Clifton <nickc@redhat.com>
-
- This file is part of GNU Binutils.
-
- This program is free software; you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation; either version 3 of the License, or
- (at your option) any later version.
-
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program; if not, write to the Free Software
- Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA
- 02110-1301, USA. */
-
-/* The difference between readelf and objdump:
-
- Both programs are capable of displaying the contents of ELF format files,
- so why does the binutils project have two file dumpers ?
-
- The reason is that objdump sees an ELF file through a BFD filter of the
- world; if BFD has a bug where, say, it disagrees about a machine constant
- in e_flags, then the odds are good that it will remain internally
- consistent. The linker sees it the BFD way, objdump sees it the BFD way,
- GAS sees it the BFD way. There was need for a tool to go find out what
- the file actually says.
-
- This is why the readelf program does not link against the BFD library - it
- exists as an independent program to help verify the correct working of BFD.
-
- There is also the case that readelf can provide more information about an
- ELF file than is provided by objdump. In particular it can display DWARF
- debugging information which (at the moment) objdump cannot. */
-
-#include "sysdep.h"
-#include <assert.h>
-#include <time.h>
-#include <zlib.h>
-#ifdef HAVE_ZSTD
-#include <zstd.h>
-#endif
-#include <wchar.h>
-
-#if defined HAVE_MSGPACK
-#include <msgpack.h>
-#endif
-
-/* Define BFD64 here, even if our default architecture is 32 bit ELF
- as this will allow us to read in and parse 64bit and 32bit ELF files. */
-#define BFD64
-
-#include "bfd.h"
-#include "bucomm.h"
-#include "elfcomm.h"
-#include "demanguse.h"
-#include "dwarf.h"
-#include "ctf-api.h"
-#include "sframe-api.h"
-#include "demangle.h"
-
-#include "elf/common.h"
-#include "elf/external.h"
-#include "elf/internal.h"
-
-
-/* Included here, before RELOC_MACROS_GEN_FUNC is defined, so that
- we can obtain the H8 reloc numbers. We need these for the
- get_reloc_size() function. We include h8.h again after defining
- RELOC_MACROS_GEN_FUNC so that we get the naming function as well. */
-
-#include "elf/h8.h"
-#undef _ELF_H8_H
-
-/* Undo the effects of #including reloc-macros.h. */
-
-#undef START_RELOC_NUMBERS
-#undef RELOC_NUMBER
-#undef FAKE_RELOC
-#undef EMPTY_RELOC
-#undef END_RELOC_NUMBERS
-#undef _RELOC_MACROS_H
-
-/* The following headers use the elf/reloc-macros.h file to
- automatically generate relocation recognition functions
- such as elf_mips_reloc_type() */
-
-#define RELOC_MACROS_GEN_FUNC
-
-#include "elf/aarch64.h"
-#include "elf/alpha.h"
-#include "elf/amdgpu.h"
-#include "elf/arc.h"
-#include "elf/arm.h"
-#include "elf/avr.h"
-#include "elf/bfin.h"
-#include "elf/cr16.h"
-#include "elf/cris.h"
-#include "elf/crx.h"
-#include "elf/csky.h"
-#include "elf/d10v.h"
-#include "elf/d30v.h"
-#include "elf/dlx.h"
-#include "elf/bpf.h"
-#include "elf/epiphany.h"
-#include "elf/fr30.h"
-#include "elf/frv.h"
-#include "elf/ft32.h"
-#include "elf/h8.h"
-#include "elf/hppa.h"
-#include "elf/i386.h"
-#include "elf/i370.h"
-#include "elf/i860.h"
-#include "elf/i960.h"
-#include "elf/ia64.h"
-#include "elf/ip2k.h"
-#include "elf/kvx.h"
-#include "elf/lm32.h"
-#include "elf/iq2000.h"
-#include "elf/m32c.h"
-#include "elf/m32r.h"
-#include "elf/m68k.h"
-#include "elf/m68hc11.h"
-#include "elf/s12z.h"
-#include "elf/mcore.h"
-#include "elf/mep.h"
-#include "elf/metag.h"
-#include "elf/microblaze.h"
-#include "elf/mips.h"
-#include "elf/mmix.h"
-#include "elf/mn10200.h"
-#include "elf/mn10300.h"
-#include "elf/moxie.h"
-#include "elf/mt.h"
-#include "elf/msp430.h"
-#include "elf/nds32.h"
-#include "elf/nfp.h"
-#include "elf/nios2.h"
-#include "elf/or1k.h"
-#include "elf/pj.h"
-#include "elf/ppc.h"
-#include "elf/ppc64.h"
-#include "elf/pru.h"
-#include "elf/riscv.h"
-#include "elf/rl78.h"
-#include "elf/rx.h"
-#include "elf/s390.h"
-#include "elf/score.h"
-#include "elf/sh.h"
-#include "elf/sparc.h"
-#include "elf/spu.h"
-#include "elf/tic6x.h"
-#include "elf/tilegx.h"
-#include "elf/tilepro.h"
-#include "elf/v850.h"
-#include "elf/vax.h"
-#include "elf/visium.h"
-#include "elf/wasm32.h"
-#include "elf/x86-64.h"
-#include "elf/xgate.h"
-#include "elf/xstormy16.h"
-#include "elf/xtensa.h"
-#include "elf/z80.h"
-#include "elf/loongarch.h"
-#include "elf/bpf.h"
-
-#include "getopt.h"
-#include "libiberty.h"
-#include "safe-ctype.h"
-#include "filenames.h"
-
-#ifndef offsetof
-#define offsetof(TYPE, MEMBER) ((size_t) &(((TYPE *) 0)->MEMBER))
-#endif
-
-typedef struct elf_section_list
-{
- Elf_Internal_Shdr * hdr;
- struct elf_section_list * next;
-} elf_section_list;
-
-/* Flag bits indicating particular types of dump. */
-#define HEX_DUMP (1 << 0) /* The -x command line switch. */
-#ifdef SUPPORT_DISASSEMBLY
-#define DISASS_DUMP (1 << 1) /* The -i command line switch. */
-#endif
-#define DEBUG_DUMP (1 << 2) /* The -w command line switch. */
-#define STRING_DUMP (1 << 3) /* The -p command line switch. */
-#define RELOC_DUMP (1 << 4) /* The -R command line switch. */
-#define CTF_DUMP (1 << 5) /* The --ctf command line switch. */
-#define SFRAME_DUMP (1 << 6) /* The --sframe command line switch. */
-#define AUTO_DUMP (1 << 7) /* The -j command line switch. */
-
-typedef unsigned char dump_type;
-
-/* A linked list of the section names for which dumps were requested. */
-struct dump_list_entry
-{
- char * name;
- dump_type type;
- struct dump_list_entry * next;
-};
-
-/* A dynamic array of flags indicating for which sections a dump
- has been requested via command line switches. */
-struct dump_data
-{
- dump_type * dump_sects;
- unsigned int num_dump_sects;
-};
-
-static struct dump_data cmdline;
-
-static struct dump_list_entry * dump_sects_byname;
-
-char * program_name = "readelf";
-
-static bool show_name = false;
-static bool do_dynamic = false;
-static bool do_syms = false;
-static bool do_dyn_syms = false;
-static bool do_lto_syms = false;
-static bool do_reloc = false;
-static bool do_sections = false;
-static bool do_section_groups = false;
-static bool do_section_details = false;
-static bool do_segments = false;
-static bool do_unwind = false;
-static bool do_using_dynamic = false;
-static bool do_header = false;
-static bool do_dump = false;
-static bool do_version = false;
-static bool do_histogram = false;
-static bool do_debugging = false;
-static bool do_ctf = false;
-static bool do_sframe = false;
-static bool do_arch = false;
-static bool do_notes = false;
-static bool do_archive_index = false;
-static bool check_all = false;
-static bool is_32bit_elf = false;
-static bool decompress_dumps = false;
-static bool do_not_show_symbol_truncation = false;
-static bool do_demangle = false; /* Pretty print C++ symbol names. */
-static bool process_links = false;
-static bool dump_any_debugging = false;
-static bool extra_sym_info = false;
-static int demangle_flags = DMGL_ANSI | DMGL_PARAMS;
-static int sym_base = 0;
-
-static char *dump_ctf_parent_name;
-static char *dump_ctf_symtab_name;
-static char *dump_ctf_strtab_name;
-
-struct group_list
-{
- struct group_list * next;
- unsigned int section_index;
-};
-
-struct group
-{
- struct group_list * root;
- unsigned int group_index;
-};
-
-typedef struct filedata
-{
- const char * file_name;
- bool is_separate;
- FILE * handle;
- uint64_t file_size;
- Elf_Internal_Ehdr file_header;
- uint64_t archive_file_offset;
- uint64_t archive_file_size;
- /* Everything below this point is cleared out by free_filedata. */
- Elf_Internal_Shdr * section_headers;
- Elf_Internal_Phdr * program_headers;
- char * string_table;
- uint64_t string_table_length;
- uint64_t dynamic_addr;
- uint64_t dynamic_size;
- uint64_t dynamic_nent;
- Elf_Internal_Dyn * dynamic_section;
- Elf_Internal_Shdr * dynamic_strtab_section;
- char * dynamic_strings;
- uint64_t dynamic_strings_length;
- Elf_Internal_Shdr * dynamic_symtab_section;
- uint64_t num_dynamic_syms;
- Elf_Internal_Sym * dynamic_symbols;
- uint64_t version_info[16];
- unsigned int dynamic_syminfo_nent;
- Elf_Internal_Syminfo * dynamic_syminfo;
- uint64_t dynamic_syminfo_offset;
- uint64_t nbuckets;
- uint64_t nchains;
- uint64_t * buckets;
- uint64_t * chains;
- uint64_t ngnubuckets;
- uint64_t ngnuchains;
- uint64_t * gnubuckets;
- uint64_t * gnuchains;
- uint64_t * mipsxlat;
- uint64_t gnusymidx;
- char * program_interpreter;
- uint64_t dynamic_info[DT_RELRENT + 1];
- uint64_t dynamic_info_DT_GNU_HASH;
- uint64_t dynamic_info_DT_MIPS_XHASH;
- elf_section_list * symtab_shndx_list;
- size_t group_count;
- struct group * section_groups;
- struct group ** section_headers_groups;
- /* A dynamic array of flags indicating for which sections a dump of
- some kind has been requested. It is reset on a per-object file
- basis and then initialised from the cmdline_dump_sects array,
- the results of interpreting the -w switch, and the
- dump_sects_byname list. */
- struct dump_data dump;
-} Filedata;
-
-/* How to print a vma value. */
-typedef enum print_mode
-{
- HEX,
- HEX_5,
- DEC,
- DEC_5,
- UNSIGNED,
- UNSIGNED_5,
- PREFIX_HEX,
- PREFIX_HEX_5,
- FULL_HEX,
- LONG_HEX,
- ZERO_HEX,
- OCTAL,
- OCTAL_5
-}
-print_mode;
-
-typedef enum unicode_display_type
-{
- unicode_default = 0,
- unicode_locale,
- unicode_escape,
- unicode_hex,
- unicode_highlight,
- unicode_invalid
-} unicode_display_type;
-
-static unicode_display_type unicode_display = unicode_default;
-
-typedef enum
-{
- reltype_unknown,
- reltype_rel,
- reltype_rela,
- reltype_relr
-} relocation_type;
-
-/* Versioned symbol info. */
-enum versioned_symbol_info
-{
- symbol_undefined,
- symbol_hidden,
- symbol_public
-};
-
-static int
-fseek64 (FILE *stream, int64_t offset, int whence)
-{
-#if defined (HAVE_FSEEKO64)
- off64_t o = offset;
- if (o != offset)
- {
- errno = EINVAL;
- return -1;
- }
- return fseeko64 (stream, o, whence);
-#elif defined (HAVE_FSEEKO)
- off_t o = offset;
- if (o != offset)
- {
- errno = EINVAL;
- return -1;
- }
- return fseeko (stream, o, whence);
-#else
- long o = offset;
- if (o != offset)
- {
- errno = EINVAL;
- return -1;
- }
- return fseek (stream, o, whence);
-#endif
-}
-
-static const char * get_symbol_version_string
- (Filedata *, bool, const char *, size_t, unsigned,
- Elf_Internal_Sym *, enum versioned_symbol_info *, unsigned short *);
-
-static bool process_notes_at
- (Filedata *, Elf_Internal_Shdr *, uint64_t, uint64_t, uint64_t);
-
-#define UNKNOWN -1
-
-static inline const char *
-section_name (const Filedata *filedata, const Elf_Internal_Shdr *hdr)
-{
- return filedata->string_table + hdr->sh_name;
-}
-
-static inline bool
-section_name_valid (const Filedata *filedata, const Elf_Internal_Shdr *hdr)
-{
- return (filedata != NULL
- && hdr != NULL
- && filedata->string_table != NULL
- && hdr->sh_name < filedata->string_table_length);
-}
-
-/* Returns true if the given index is real/valid. Note: "real" here
- means "references a real section in the section header" and not
- "is a valid section index as per the ELF standard". */
-
-static inline bool
-section_index_real (const Filedata *filedata, unsigned int ndx)
-{
- return (filedata != NULL
- && filedata->section_headers != NULL
- && ndx < filedata->file_header.e_shnum
- && ndx > 0);
-}
-
-#define DT_VERSIONTAGIDX(tag) (DT_VERNEEDNUM - (tag)) /* Reverse order! */
-
-static inline bool
-valid_symbol_name (const char *strtab, size_t strtab_size, uint64_t offset)
-{
- return strtab != NULL && offset < strtab_size;
-}
-
-static inline bool
-valid_dynamic_name (const Filedata *filedata, uint64_t offset)
-{
- return valid_symbol_name (filedata->dynamic_strings,
- filedata->dynamic_strings_length, offset);
-}
-
-/* GET_DYNAMIC_NAME asssumes that VALID_DYNAMIC_NAME has
- already been called and verified that the string exists. */
-static inline const char *
-get_dynamic_name (const Filedata *filedata, size_t offset)
-{
- return filedata->dynamic_strings + offset;
-}
-
-#define REMOVE_ARCH_BITS(ADDR) \
- do \
- { \
- if (filedata->file_header.e_machine == EM_ARM) \
- (ADDR) &= ~1; \
- } \
- while (0)
-
-/* Get the correct GNU hash section name. */
-#define GNU_HASH_SECTION_NAME(filedata) \
- filedata->dynamic_info_DT_MIPS_XHASH ? ".MIPS.xhash" : ".gnu.hash"
-
-/* Retrieve NMEMB structures, each SIZE bytes long from FILEDATA starting at
- OFFSET + the offset of the current archive member, if we are examining an
- archive. Put the retrieved data into VAR, if it is not NULL. Otherwise
- allocate a buffer using malloc and fill that. In either case return the
- pointer to the start of the retrieved data or NULL if something went wrong.
- If something does go wrong and REASON is not NULL then emit an error
- message using REASON as part of the context. */
-
-static void *
-get_data (void *var,
- Filedata *filedata,
- uint64_t offset,
- uint64_t size,
- uint64_t nmemb,
- const char *reason)
-{
- void * mvar;
- uint64_t amt = size * nmemb;
-
- if (size == 0 || nmemb == 0)
- return NULL;
-
- /* If size_t is smaller than uint64_t, eg because you are building
- on a 32-bit host, then make sure that when the sizes are cast to
- size_t no information is lost. */
- if ((size_t) size != size
- || (size_t) nmemb != nmemb
- || (size_t) amt != amt
- || amt / size != nmemb
- || (size_t) amt + 1 == 0)
- {
- if (reason)
- error (_("Size overflow prevents reading %" PRIu64
- " elements of size %" PRIu64 " for %s\n"),
- nmemb, size, reason);
- return NULL;
- }
-
- /* Be kind to memory checkers (eg valgrind, address sanitizer) by not
- attempting to allocate memory when the read is bound to fail. */
- if (filedata->archive_file_offset > filedata->file_size
- || offset > filedata->file_size - filedata->archive_file_offset
- || amt > filedata->file_size - filedata->archive_file_offset - offset)
- {
- if (reason)
- error (_("Reading %" PRIu64 " bytes extends past end of file for %s\n"),
- amt, reason);
- return NULL;
- }
-
- if (fseek64 (filedata->handle, filedata->archive_file_offset + offset,
- SEEK_SET))
- {
- if (reason)
- error (_("Unable to seek to %#" PRIx64 " for %s\n"),
- filedata->archive_file_offset + offset, reason);
- return NULL;
- }
-
- mvar = var;
- if (mvar == NULL)
- {
- /* + 1 so that we can '\0' terminate invalid string table sections. */
- mvar = malloc ((size_t) amt + 1);
-
- if (mvar == NULL)
- {
- if (reason)
- error (_("Out of memory allocating %" PRIu64 " bytes for %s\n"),
- amt, reason);
- return NULL;
- }
-
- ((char *) mvar)[amt] = '\0';
- }
-
- if (fread (mvar, (size_t) size, (size_t) nmemb, filedata->handle) != nmemb)
- {
- if (reason)
- error (_("Unable to read in %" PRIu64 " bytes of %s\n"),
- amt, reason);
- if (mvar != var)
- free (mvar);
- return NULL;
- }
-
- return mvar;
-}
-
-/* Print a VMA value in the MODE specified.
- Returns the number of characters displayed. */
-
-static unsigned int
-print_vma (uint64_t vma, print_mode mode)
-{
- unsigned int nc = 0;
-
- switch (mode)
- {
- case FULL_HEX:
- nc = printf ("0x");
- /* Fall through. */
- case LONG_HEX:
- if (!is_32bit_elf)
- return nc + printf ("%16.16" PRIx64, vma);
- return nc + printf ("%8.8" PRIx64, vma);
-
- case ZERO_HEX:
- if (is_32bit_elf)
- return printf ("%08" PRIx64, vma);
- return printf ("%016" PRIx64, vma);
-
- case DEC_5:
- if (vma <= 99999)
- return printf ("%5" PRId64, vma);
- /* Fall through. */
- case PREFIX_HEX:
- nc = printf ("0x");
- /* Fall through. */
- case HEX:
- return nc + printf ("%" PRIx64, vma);
-
- case PREFIX_HEX_5:
- nc = printf ("0x");
- /* Fall through. */
- case HEX_5:
- return nc + printf ("%05" PRIx64, vma);
-
- case DEC:
- return printf ("%" PRId64, vma);
-
- case UNSIGNED:
- return printf ("%" PRIu64, vma);
-
- case UNSIGNED_5:
- return printf ("%5" PRIu64, vma);
-
- case OCTAL:
- return printf ("%" PRIo64, vma);
-
- case OCTAL_5:
- return printf ("%5" PRIo64, vma);
-
- default:
- /* FIXME: Report unrecognised mode ? */
- return 0;
- }
-}
-
-
-/* Display a symbol on stdout. Handles the display of control characters and
- multibye characters (assuming the host environment supports them).
-
- Display at most abs(WIDTH) characters, truncating as necessary,
- unless do_wide or extra_sym_info is true.
-
- If truncation will happen and do_not_show_symbol_truncation is FALSE then display
- abs(WIDTH) - 5 characters followed by "[...]".
-
- If WIDTH is negative then ensure that the output is at least (- WIDTH) characters,
- padding as necessary.
-
- Returns the number of emitted characters. */
-
-static unsigned int
-print_symbol_name (signed int width, const char * symbol)
-{
- bool extra_padding = false;
- bool do_dots = false;
- signed int num_printed = 0;
-#ifdef HAVE_MBSTATE_T
- mbstate_t state;
-#endif
- unsigned int width_remaining;
- const void * alloced_symbol = NULL;
-
- if (width < 0)
- {
- /* Keep the width positive. This helps the code below. */
- width = - width;
- extra_padding = true;
- }
- else if (width == 0)
- return 0;
-
- if (do_wide || extra_sym_info)
- /* Set the remaining width to a very large value.
- This simplifies the code below. */
- width_remaining = INT_MAX;
- else
- {
- width_remaining = width;
-
- if (! do_not_show_symbol_truncation
- && (int) strlen (symbol) > width)
- {
- width_remaining -= 5;
- if ((int) width_remaining < 0)
- width_remaining = 0;
- do_dots = true;
- }
- }
-
-#ifdef HAVE_MBSTATE_T
- /* Initialise the multibyte conversion state. */
- memset (& state, 0, sizeof (state));
-#endif
-
- if (do_demangle && *symbol)
- {
- const char * res = cplus_demangle (symbol, demangle_flags);
-
- if (res != NULL)
- alloced_symbol = symbol = res;
- }
-
- while (width_remaining)
- {
- size_t n;
- const char c = *symbol++;
-
- if (c == 0)
- break;
-
- if (ISPRINT (c))
- {
- putchar (c);
- width_remaining --;
- num_printed ++;
- }
- else if (ISCNTRL (c))
- {
- /* Do not print control characters directly as they can affect terminal
- settings. Such characters usually appear in the names generated
- by the assembler for local labels. */
-
- if (width_remaining < 2)
- break;
-
- printf ("^%c", c + 0x40);
- width_remaining -= 2;
- num_printed += 2;
- }
- else if (c == 0x7f)
- {
- if (width_remaining < 5)
- break;
- printf ("<DEL>");
- width_remaining -= 5;
- num_printed += 5;
- }
- else if (unicode_display != unicode_locale
- && unicode_display != unicode_default)
- {
- /* Display unicode characters as something else. */
- unsigned char bytes[4];
- bool is_utf8;
- unsigned int nbytes;
-
- bytes[0] = c;
-
- if (bytes[0] < 0xc0)
- {
- nbytes = 1;
- is_utf8 = false;
- }
- else
- {
- bytes[1] = *symbol++;
-
- if ((bytes[1] & 0xc0) != 0x80)
- {
- is_utf8 = false;
- /* Do not consume this character. It may only
- be the first byte in the sequence that was
- corrupt. */
- --symbol;
- nbytes = 1;
- }
- else if ((bytes[0] & 0x20) == 0)
- {
- is_utf8 = true;
- nbytes = 2;
- }
- else
- {
- bytes[2] = *symbol++;
-
- if ((bytes[2] & 0xc0) != 0x80)
- {
- is_utf8 = false;
- symbol -= 2;
- nbytes = 1;
- }
- else if ((bytes[0] & 0x10) == 0)
- {
- is_utf8 = true;
- nbytes = 3;
- }
- else
- {
- bytes[3] = *symbol++;
-
- nbytes = 4;
-
- if ((bytes[3] & 0xc0) != 0x80)
- {
- is_utf8 = false;
- symbol -= 3;
- nbytes = 1;
- }
- else
- is_utf8 = true;
- }
- }
- }
-
- if (unicode_display == unicode_invalid)
- is_utf8 = false;
-
- if (unicode_display == unicode_hex || ! is_utf8)
- {
- unsigned int i;
-
- if (width_remaining < (nbytes * 2) + 2)
- break;
-
- putchar (is_utf8 ? '<' : '{');
- printf ("0x");
- for (i = 0; i < nbytes; i++)
- printf ("%02x", bytes[i]);
- putchar (is_utf8 ? '>' : '}');
- }
- else
- {
- if (unicode_display == unicode_highlight && isatty (1))
- printf ("\x1B[31;47m"); /* Red. */
-
- switch (nbytes)
- {
- case 2:
- if (width_remaining < 6)
- break;
- printf ("\\u%02x%02x",
- (bytes[0] & 0x1c) >> 2,
- ((bytes[0] & 0x03) << 6) | (bytes[1] & 0x3f));
- break;
- case 3:
- if (width_remaining < 6)
- break;
- printf ("\\u%02x%02x",
- ((bytes[0] & 0x0f) << 4) | ((bytes[1] & 0x3c) >> 2),
- ((bytes[1] & 0x03) << 6) | (bytes[2] & 0x3f));
- break;
- case 4:
- if (width_remaining < 8)
- break;
- printf ("\\u%02x%02x%02x",
- ((bytes[0] & 0x07) << 6) | ((bytes[1] & 0x3c) >> 2),
- ((bytes[1] & 0x03) << 6) | ((bytes[2] & 0x3c) >> 2),
- ((bytes[2] & 0x03) << 6) | (bytes[3] & 0x3f));
-
- break;
- default:
- /* URG. */
- break;
- }
-
- if (unicode_display == unicode_highlight && isatty (1))
- printf ("\033[0m"); /* Default colour. */
- }
-
- if (bytes[nbytes - 1] == 0)
- break;
- }
- else
- {
-#ifdef HAVE_MBSTATE_T
- wchar_t w;
-#endif
- /* Let printf do the hard work of displaying multibyte characters. */
- printf ("%.1s", symbol - 1);
- width_remaining --;
- num_printed ++;
-
-#ifdef HAVE_MBSTATE_T
- /* Try to find out how many bytes made up the character that was
- just printed. Advance the symbol pointer past the bytes that
- were displayed. */
- n = mbrtowc (& w, symbol - 1, MB_CUR_MAX, & state);
-#else
- n = 1;
-#endif
- if (n != (size_t) -1 && n != (size_t) -2 && n > 0)
- symbol += (n - 1);
- }
- }
-
- if (do_dots)
- num_printed += printf ("[...]");
-
- if (extra_padding && num_printed < width)
- {
- /* Fill in the remaining spaces. */
- printf ("%-*s", width - num_printed, " ");
- num_printed = width;
- }
-
- free ((void *) alloced_symbol);
- return num_printed;
-}
-
-/* Returns a pointer to a static buffer containing a printable version of
- the given section's name. Like print_symbol, except that it does not try
- to print multibyte characters, it just interprets them as hex values. */
-
-static const char *
-printable_section_name (Filedata * filedata, const Elf_Internal_Shdr * sec)
-{
-#define NUM_SEC_NAME_BUFS 5
-#define MAX_PRINT_SEC_NAME_LEN 256
-
- static int sec_name_buf_index = 0;
- /* We use a rotating array of static buffers, so that multiple successive calls
- to printable_section_name() will still work. eg when used in a printf. */
- static char sec_name_buf [NUM_SEC_NAME_BUFS][MAX_PRINT_SEC_NAME_LEN + 1];
-
- const char * name;
- char * buf;
- char * buf_start;
- char c;
- unsigned int remaining = MAX_PRINT_SEC_NAME_LEN;
-
- /* Validate the input parameters. */
- if (filedata == NULL)
- return _("<internal error>");
- if (sec == NULL)
- return _("<none>");
- if (filedata->string_table == NULL)
- return _("<no-strings>");
- if (sec->sh_name >= filedata->string_table_length)
- return _("<corrupt>");
-
- /* Select a buffer to use. */
- buf_start = buf = sec_name_buf[sec_name_buf_index];
- if (++sec_name_buf_index >= NUM_SEC_NAME_BUFS)
- sec_name_buf_index = 0;
-
- name = section_name (filedata, sec);
-
- while ((c = * name ++) != 0)
- {
- if (ISCNTRL (c))
- {
- if (remaining < 2)
- break;
-
- * buf ++ = '^';
- * buf ++ = c + 0x40;
- remaining -= 2;
- }
- else if (ISPRINT (c))
- {
- * buf ++ = c;
- remaining -= 1;
- }
- else
- {
- static char hex[17] = "0123456789ABCDEF";
-
- if (remaining < 4)
- break;
- * buf ++ = '<';
- * buf ++ = hex[(c & 0xf0) >> 4];
- * buf ++ = hex[c & 0x0f];
- * buf ++ = '>';
- remaining -= 4;
- }
-
- if (remaining == 0)
- break;
- }
-
- * buf = 0;
- return buf_start;
-}
-
-/* Return TRUE if the current file is for IA-64 machine and OpenVMS ABI.
- This OS has so many departures from the ELF standard that we test it at
- many places. */
-
-static inline bool
-is_ia64_vms (Filedata * filedata)
-{
- return filedata->file_header.e_machine == EM_IA_64
- && filedata->file_header.e_ident[EI_OSABI] == ELFOSABI_OPENVMS;
-}
-
-static const char *
-printable_section_name_from_index (Filedata * filedata,
- size_t ndx,
- bool * is_special)
-{
- if (is_special != NULL)
- * is_special = true;
-
- switch (ndx)
- {
- case SHN_UNDEF: return "UND";
- case SHN_ABS: return "ABS";
- case SHN_COMMON: return "COM";
- break;
- }
-
- if (filedata != NULL)
- {
- switch (filedata->file_header.e_machine)
- {
- case EM_MIPS:
- if (ndx == SHN_MIPS_SCOMMON)
- return "SCOMMON";
- if (ndx == SHN_MIPS_SUNDEFINED)
- return "SUNDEF";
- break;
-
- case EM_TI_C6000:
- if (ndx == SHN_TIC6X_SCOMMON)
- return "SCOM";
- break;
-
- case EM_X86_64:
- case EM_L1OM:
- case EM_K1OM:
- if (ndx == SHN_X86_64_LCOMMON)
- return "LARGE_COM";
- break;
-
- case EM_IA_64:
- if (filedata->file_header.e_ident[EI_OSABI] == ELFOSABI_HPUX
- && ndx == SHN_IA_64_ANSI_COMMON)
- return "ANSI_COM";
-
- if (is_ia64_vms (filedata) && ndx == SHN_IA_64_VMS_SYMVEC)
- return "VMS_SYMVEC";
- break;
-
- default:
- break;
- }
-
- if (filedata->section_headers != NULL
- && ndx < filedata->file_header.e_shnum)
- {
- const char * res;
-
- res = printable_section_name (filedata, filedata->section_headers + ndx);
- if (is_special != NULL)
- * is_special = (res[0] == '<');
-
- return res;
- }
- }
-
- static char name_buf[40];
- unsigned int short_ndx = (unsigned int) (ndx & 0xffff);
-
- if (ndx >= SHN_LOPROC && ndx <= SHN_HIPROC)
- sprintf (name_buf, "PRC[0x%04x]", short_ndx);
- else if (ndx >= SHN_LOOS && ndx <= SHN_HIOS)
- sprintf (name_buf, "OS [0x%04x]", short_ndx);
- else if (ndx >= SHN_LORESERVE)
- sprintf (name_buf, "RSV[0x%04x]", short_ndx);
- else if (filedata->file_header.e_shnum != 0
- && ndx >= filedata->file_header.e_shnum)
- sprintf (name_buf, _("BAD[0x%lx]"), (long) ndx);
- else
- sprintf (name_buf, "<section 0x%lx>", (long) ndx);
-
- return name_buf;
-}
-
-/* Return a pointer to section NAME, or NULL if no such section exists. */
-
-static Elf_Internal_Shdr *
-find_section (Filedata * filedata, const char * name)
-{
- unsigned int i;
-
- if (filedata->section_headers == NULL)
- return NULL;
-
- for (i = 0; i < filedata->file_header.e_shnum; i++)
- if (section_name_valid (filedata, filedata->section_headers + i)
- && streq (section_name (filedata, filedata->section_headers + i),
- name))
- return filedata->section_headers + i;
-
- return NULL;
-}
-
-/* Return a pointer to a section containing ADDR, or NULL if no such
- section exists. */
-
-static Elf_Internal_Shdr *
-find_section_by_address (Filedata * filedata, uint64_t addr)
-{
- unsigned int i;
-
- if (filedata->section_headers == NULL)
- return NULL;
-
- for (i = 0; i < filedata->file_header.e_shnum; i++)
- {
- Elf_Internal_Shdr *sec = filedata->section_headers + i;
-
- if (addr >= sec->sh_addr && addr < sec->sh_addr + sec->sh_size)
- return sec;
- }
-
- return NULL;
-}
-
-static Elf_Internal_Shdr *
-find_section_by_type (Filedata * filedata, unsigned int type)
-{
- unsigned int i;
-
- if (filedata->section_headers == NULL)
- return NULL;
-
- for (i = 0; i < filedata->file_header.e_shnum; i++)
- {
- Elf_Internal_Shdr *sec = filedata->section_headers + i;
-
- if (sec->sh_type == type)
- return sec;
- }
-
- return NULL;
-}
-
-static Elf_Internal_Shdr *
-find_section_by_name (Filedata * filedata, const char * name)
-{
- unsigned int i;
-
- if (filedata->section_headers == NULL || filedata->string_table_length == 0)
- return NULL;
-
- for (i = 0; i < filedata->file_header.e_shnum; i++)
- {
- Elf_Internal_Shdr *sec = filedata->section_headers + i;
-
- if (sec->sh_name < filedata->string_table_length
- && streq (name, filedata->string_table + sec->sh_name))
- return sec;
- }
-
- return NULL;
-}
-
-/* Return a pointer to section NAME, or NULL if no such section exists,
- restricted to the list of sections given in SET. */
-
-static Elf_Internal_Shdr *
-find_section_in_set (Filedata * filedata, const char * name, unsigned int * set)
-{
- unsigned int i;
-
- if (filedata->section_headers == NULL)
- return NULL;
-
- if (set != NULL)
- {
- while ((i = *set++) > 0)
- {
- /* See PR 21156 for a reproducer. */
- if (i >= filedata->file_header.e_shnum)
- continue; /* FIXME: Should we issue an error message ? */
-
- if (section_name_valid (filedata, filedata->section_headers + i)
- && streq (section_name (filedata, filedata->section_headers + i),
- name))
- return filedata->section_headers + i;
- }
- }
-
- return find_section (filedata, name);
-}
-
-/* Guess the relocation size commonly used by the specific machines. */
-
-static bool
-guess_is_rela (unsigned int e_machine)
-{
- switch (e_machine)
- {
- /* Targets that use REL relocations. */
- case EM_386:
- case EM_IAMCU:
- case EM_960:
- case EM_ARM:
- case EM_D10V:
- case EM_CYGNUS_D10V:
- case EM_DLX:
- case EM_MIPS:
- case EM_MIPS_RS3_LE:
- case EM_CYGNUS_M32R:
- case EM_SCORE:
- case EM_XGATE:
- case EM_NFP:
- case EM_BPF:
- return false;
-
- /* Targets that use RELA relocations. */
- case EM_68K:
- case EM_860:
- case EM_AARCH64:
- case EM_ADAPTEVA_EPIPHANY:
- case EM_ALPHA:
- case EM_ALTERA_NIOS2:
- case EM_ARC:
- case EM_ARC_COMPACT:
- case EM_ARC_COMPACT2:
- case EM_ARC_COMPACT3:
- case EM_ARC_COMPACT3_64:
- case EM_AVR:
- case EM_AVR_OLD:
- case EM_BLACKFIN:
- case EM_CR16:
- case EM_CRIS:
- case EM_CRX:
- case EM_CSKY:
- case EM_D30V:
- case EM_CYGNUS_D30V:
- case EM_FR30:
- case EM_FT32:
- case EM_CYGNUS_FR30:
- case EM_CYGNUS_FRV:
- case EM_H8S:
- case EM_H8_300:
- case EM_H8_300H:
- case EM_IA_64:
- case EM_IP2K:
- case EM_IP2K_OLD:
- case EM_IQ2000:
- case EM_KVX:
- case EM_LATTICEMICO32:
- case EM_M32C_OLD:
- case EM_M32C:
- case EM_M32R:
- case EM_MCORE:
- case EM_CYGNUS_MEP:
- case EM_METAG:
- case EM_MMIX:
- case EM_MN10200:
- case EM_CYGNUS_MN10200:
- case EM_MN10300:
- case EM_CYGNUS_MN10300:
- case EM_MOXIE:
- case EM_MSP430:
- case EM_MSP430_OLD:
- case EM_MT:
- case EM_NDS32:
- case EM_NIOS32:
- case EM_OR1K:
- case EM_PPC64:
- case EM_PPC:
- case EM_TI_PRU:
- case EM_RISCV:
- case EM_RL78:
- case EM_RX:
- case EM_S390:
- case EM_S390_OLD:
- case EM_SH:
- case EM_SPARC:
- case EM_SPARC32PLUS:
- case EM_SPARCV9:
- case EM_SPU:
- case EM_TI_C6000:
- case EM_TILEGX:
- case EM_TILEPRO:
- case EM_V800:
- case EM_V850:
- case EM_CYGNUS_V850:
- case EM_VAX:
- case EM_VISIUM:
- case EM_X86_64:
- case EM_L1OM:
- case EM_K1OM:
- case EM_XSTORMY16:
- case EM_XTENSA:
- case EM_XTENSA_OLD:
- case EM_MICROBLAZE:
- case EM_MICROBLAZE_OLD:
- case EM_WEBASSEMBLY:
- return true;
-
- case EM_68HC05:
- case EM_68HC08:
- case EM_68HC11:
- case EM_68HC16:
- case EM_FX66:
- case EM_ME16:
- case EM_MMA:
- case EM_NCPU:
- case EM_NDR1:
- case EM_PCP:
- case EM_ST100:
- case EM_ST19:
- case EM_ST7:
- case EM_ST9PLUS:
- case EM_STARCORE:
- case EM_SVX:
- case EM_TINYJ:
- default:
- warn (_("Don't know about relocations on this machine architecture\n"));
- return false;
- }
-}
-
-/* Load RELA type relocations from FILEDATA at REL_OFFSET extending for REL_SIZE bytes.
- Returns TRUE upon success, FALSE otherwise. If successful then a
- pointer to a malloc'ed buffer containing the relocs is placed in *RELASP,
- and the number of relocs loaded is placed in *NRELASP. It is the caller's
- responsibility to free the allocated buffer. */
-
-static bool
-slurp_rela_relocs (Filedata *filedata,
- uint64_t rel_offset,
- uint64_t rel_size,
- Elf_Internal_Rela **relasp,
- uint64_t *nrelasp)
-{
- Elf_Internal_Rela * relas;
- uint64_t nrelas;
- unsigned int i;
-
- if (is_32bit_elf)
- {
- Elf32_External_Rela * erelas;
-
- erelas = (Elf32_External_Rela *) get_data (NULL, filedata, rel_offset, 1,
- rel_size, _("32-bit relocation data"));
- if (!erelas)
- return false;
-
- nrelas = rel_size / sizeof (Elf32_External_Rela);
-
- relas = (Elf_Internal_Rela *) cmalloc (nrelas,
- sizeof (Elf_Internal_Rela));
-
- if (relas == NULL)
- {
- free (erelas);
- error (_("out of memory parsing relocs\n"));
- return false;
- }
-
- for (i = 0; i < nrelas; i++)
- {
- relas[i].r_offset = BYTE_GET (erelas[i].r_offset);
- relas[i].r_info = BYTE_GET (erelas[i].r_info);
- relas[i].r_addend = BYTE_GET_SIGNED (erelas[i].r_addend);
- }
-
- free (erelas);
- }
- else
- {
- Elf64_External_Rela * erelas;
-
- erelas = (Elf64_External_Rela *) get_data (NULL, filedata, rel_offset, 1,
- rel_size, _("64-bit relocation data"));
- if (!erelas)
- return false;
-
- nrelas = rel_size / sizeof (Elf64_External_Rela);
-
- relas = (Elf_Internal_Rela *) cmalloc (nrelas,
- sizeof (Elf_Internal_Rela));
-
- if (relas == NULL)
- {
- free (erelas);
- error (_("out of memory parsing relocs\n"));
- return false;
- }
-
- for (i = 0; i < nrelas; i++)
- {
- relas[i].r_offset = BYTE_GET (erelas[i].r_offset);
- relas[i].r_info = BYTE_GET (erelas[i].r_info);
- relas[i].r_addend = BYTE_GET_SIGNED (erelas[i].r_addend);
-
- if (filedata->file_header.e_machine == EM_MIPS
- && filedata->file_header.e_ident[EI_DATA] != ELFDATA2MSB)
- {
- /* In little-endian objects, r_info isn't really a
- 64-bit little-endian value: it has a 32-bit
- little-endian symbol index followed by four
- individual byte fields. Reorder INFO
- accordingly. */
- uint64_t inf = relas[i].r_info;
- inf = (((inf & 0xffffffff) << 32)
- | ((inf >> 56) & 0xff)
- | ((inf >> 40) & 0xff00)
- | ((inf >> 24) & 0xff0000)
- | ((inf >> 8) & 0xff000000));
- relas[i].r_info = inf;
- }
- }
-
- free (erelas);
- }
-
- *relasp = relas;
- *nrelasp = nrelas;
- return true;
-}
-
-/* Load REL type relocations from FILEDATA at REL_OFFSET extending for REL_SIZE bytes.
- Returns TRUE upon success, FALSE otherwise. If successful then a
- pointer to a malloc'ed buffer containing the relocs is placed in *RELSP,
- and the number of relocs loaded is placed in *NRELSP. It is the caller's
- responsibility to free the allocated buffer. */
-
-static bool
-slurp_rel_relocs (Filedata *filedata,
- uint64_t rel_offset,
- uint64_t rel_size,
- Elf_Internal_Rela **relsp,
- uint64_t *nrelsp)
-{
- Elf_Internal_Rela * rels;
- uint64_t nrels;
- unsigned int i;
-
- if (is_32bit_elf)
- {
- Elf32_External_Rel * erels;
-
- erels = (Elf32_External_Rel *) get_data (NULL, filedata, rel_offset, 1,
- rel_size, _("32-bit relocation data"));
- if (!erels)
- return false;
-
- nrels = rel_size / sizeof (Elf32_External_Rel);
-
- rels = (Elf_Internal_Rela *) cmalloc (nrels, sizeof (Elf_Internal_Rela));
-
- if (rels == NULL)
- {
- free (erels);
- error (_("out of memory parsing relocs\n"));
- return false;
- }
-
- for (i = 0; i < nrels; i++)
- {
- rels[i].r_offset = BYTE_GET (erels[i].r_offset);
- rels[i].r_info = BYTE_GET (erels[i].r_info);
- rels[i].r_addend = 0;
- }
-
- free (erels);
- }
- else
- {
- Elf64_External_Rel * erels;
-
- erels = (Elf64_External_Rel *) get_data (NULL, filedata, rel_offset, 1,
- rel_size, _("64-bit relocation data"));
- if (!erels)
- return false;
-
- nrels = rel_size / sizeof (Elf64_External_Rel);
-
- rels = (Elf_Internal_Rela *) cmalloc (nrels, sizeof (Elf_Internal_Rela));
-
- if (rels == NULL)
- {
- free (erels);
- error (_("out of memory parsing relocs\n"));
- return false;
- }
-
- for (i = 0; i < nrels; i++)
- {
- rels[i].r_offset = BYTE_GET (erels[i].r_offset);
- rels[i].r_info = BYTE_GET (erels[i].r_info);
- rels[i].r_addend = 0;
-
- if (filedata->file_header.e_machine == EM_MIPS
- && filedata->file_header.e_ident[EI_DATA] != ELFDATA2MSB)
- {
- /* In little-endian objects, r_info isn't really a
- 64-bit little-endian value: it has a 32-bit
- little-endian symbol index followed by four
- individual byte fields. Reorder INFO
- accordingly. */
- uint64_t inf = rels[i].r_info;
- inf = (((inf & 0xffffffff) << 32)
- | ((inf >> 56) & 0xff)
- | ((inf >> 40) & 0xff00)
- | ((inf >> 24) & 0xff0000)
- | ((inf >> 8) & 0xff000000));
- rels[i].r_info = inf;
- }
- }
-
- free (erels);
- }
-
- *relsp = rels;
- *nrelsp = nrels;
- return true;
-}
-
-/* Returns the reloc type extracted from the reloc info field. */
-
-static unsigned int
-get_reloc_type (Filedata * filedata, uint64_t reloc_info)
-{
- if (is_32bit_elf)
- return ELF32_R_TYPE (reloc_info);
-
- switch (filedata->file_header.e_machine)
- {
- case EM_MIPS:
- /* Note: We assume that reloc_info has already been adjusted for us. */
- return ELF64_MIPS_R_TYPE (reloc_info);
-
- case EM_SPARCV9:
- return ELF64_R_TYPE_ID (reloc_info);
-
- default:
- return ELF64_R_TYPE (reloc_info);
- }
-}
-
-/* Return the symbol index extracted from the reloc info field. */
-
-static uint64_t
-get_reloc_symindex (uint64_t reloc_info)
-{
- return is_32bit_elf ? ELF32_R_SYM (reloc_info) : ELF64_R_SYM (reloc_info);
-}
-
-static inline bool
-uses_msp430x_relocs (Filedata * filedata)
-{
- return
- filedata->file_header.e_machine == EM_MSP430 /* Paranoia. */
- /* GCC uses osabi == ELFOSBI_STANDALONE. */
- && (((filedata->file_header.e_flags & EF_MSP430_MACH) == E_MSP430_MACH_MSP430X)
- /* TI compiler uses ELFOSABI_NONE. */
- || (filedata->file_header.e_ident[EI_OSABI] == ELFOSABI_NONE));
-}
-
-
-static const char *
-get_symbol_at (Filedata * filedata,
- Elf_Internal_Sym * symtab,
- uint64_t nsyms,
- char * strtab,
- uint64_t where,
- uint64_t * offset_return)
-{
- Elf_Internal_Sym * beg = symtab;
- Elf_Internal_Sym * end = symtab + nsyms;
- Elf_Internal_Sym * best = NULL;
- uint64_t dist = 0x100000;
-
- /* FIXME: Since this function is likely to be called repeatedly with
- slightly increasing addresses each time, we could speed things up by
- caching the last returned value and starting our search from there. */
- while (beg < end)
- {
- Elf_Internal_Sym * sym;
- uint64_t value;
-
- sym = beg + (end - beg) / 2;
-
- value = sym->st_value;
-
- if (where >= value
- && where - value < dist)
- {
- best = sym;
- dist = where - value;
- if (dist == 0)
- break;
- }
-
- if (where < value)
- end = sym;
- else
- beg = sym + 1;
- }
-
- const char *name;
-
- /* If there is a section start closer than the found symbol then
- use that for symbolizing the address. */
- Elf_Internal_Shdr *sec = find_section_by_address (filedata, where);
- if (sec != NULL
- && where - sec->sh_addr < dist
- && section_name_valid (filedata, sec))
- {
- name = section_name (filedata, sec);
- dist = where - sec->sh_addr;
- }
- else if (best != NULL)
- name = strtab + best->st_name;
- else
- return NULL;
-
- if (offset_return != NULL)
- * offset_return = dist;
-
- return name;
-}
-
-static void
-print_relr_addr_and_sym (Filedata * filedata,
- Elf_Internal_Sym * symtab,
- uint64_t nsyms,
- char * strtab,
- uint64_t where)
-{
- const char * symname = NULL;
- uint64_t offset = 0;
-
- print_vma (where, ZERO_HEX);
- printf (" ");
-
- symname = get_symbol_at (filedata, symtab, nsyms, strtab, where, & offset);
-
- if (symname == NULL)
- printf ("<no sym>");
- else if (offset == 0)
- print_symbol_name (38, symname);
- else
- {
- print_symbol_name (28, symname);
- printf (" + ");
- print_vma (offset, PREFIX_HEX);
- }
-}
-
-/* See bfd_is_aarch64_special_symbol_name. */
-
-static bool
-is_aarch64_special_symbol_name (const char *name)
-{
- if (!name || name[0] != '$')
- return false;
- if (name[1] == 'x' || name[1] == 'd')
- /* Map. */;
- else if (name[1] == 'm' || name[1] == 'f' || name[1] == 'p')
- /* Tag. */;
- else
- return false;
- return name[2] == 0 || name[2] == '.';
-}
-
-static bool
-is_special_symbol_name (Filedata * filedata, const char * s)
-{
- switch (filedata->file_header.e_machine)
- {
- case EM_AARCH64:
- return is_aarch64_special_symbol_name (s);
-
- default:
- return false;
- }
-}
-
-/* Allows selecting the best symbol from a set for displaying addresses.
- BEST is the current best or NULL if there are no good symbols yet.
- SYM is the next symbol to consider, if it is better than BEST then
- return SYM else return BEST. */
-
-static Elf_Internal_Sym *
-select_display_sym (Filedata * filedata,
- char * strtab,
- uint64_t strtablen,
- Elf_Internal_Sym * best,
- Elf_Internal_Sym * sym)
-{
- /* Ignore empty or invalid syms. */
- if (sym->st_name == 0)
- return best;
- if (sym->st_name >= strtablen)
- return best;
- /* Ignore undefined or TLS syms. */
- if (sym->st_shndx == SHN_UNDEF)
- return best;
- if (ELF_ST_TYPE (sym->st_info) == STT_TLS)
- return best;
-
- char *s = strtab + sym->st_name;
-
- /* Don't display special symbols. */
- if (is_special_symbol_name (filedata, s))
- return best;
-
- /* Here SYM is good for display. */
-
- if (best == NULL)
- return sym;
-
- char *sbest = strtab + best->st_name;
-
- /* Prefer non-local symbols. */
- if (ELF_ST_BIND (sym->st_info) == STB_LOCAL
- && ELF_ST_BIND (best->st_info) != STB_LOCAL)
- return best;
- if (ELF_ST_BIND (sym->st_info) != STB_LOCAL
- && ELF_ST_BIND (best->st_info) == STB_LOCAL)
- return sym;
-
- /* Select based on lexicographic order. */
- return strcmp (s, sbest) < 0 ? sym : best;
-}
-
-/* Filter the sorted SYMTAB symbol array in-place to select at most one
- symbol for an address and drop symbols that are not good to display.
- Returns the new array length. */
-
-static uint64_t
-filter_display_syms (Filedata * filedata,
- Elf_Internal_Sym * symtab,
- uint64_t nsyms,
- char * strtab,
- uint64_t strtablen)
-{
- Elf_Internal_Sym *r = symtab;
- Elf_Internal_Sym *w = symtab;
- Elf_Internal_Sym *best = NULL;
- Elf_Internal_Sym *end = symtab + nsyms;
- while (r < end)
- {
- /* Select the best symbol for an address. */
- while (r < end
- && (best == NULL || best->st_value == r->st_value))
- {
- best = select_display_sym (filedata, strtab, strtablen, best, r);
- r++;
- }
- if (best != NULL)
- {
- *w = *best;
- w++;
- best = NULL;
- }
- }
- return w - symtab;
-}
-
-static /* signed */ int
-symcmp (const void *p, const void *q)
-{
- Elf_Internal_Sym *sp = (Elf_Internal_Sym *) p;
- Elf_Internal_Sym *sq = (Elf_Internal_Sym *) q;
-
- return sp->st_value > sq->st_value ? 1 : (sp->st_value < sq->st_value ? -1 : 0);
-}
-
-static uint64_t
-count_relr_relocations (Filedata * filedata,
- Elf_Internal_Shdr * section)
-{
- uint64_t * relrs;
- uint64_t nentries;
- uint64_t i;
- uint64_t count;
- int entsize;
-
- if (section == NULL
- || section->sh_type != SHT_RELR
- || section->sh_size == 0)
- return 0;
-
- entsize = section->sh_entsize;
- if (entsize == 0)
- entsize = is_32bit_elf
- ? sizeof (Elf32_External_Relr) : sizeof (Elf64_External_Relr);
- else if (entsize != sizeof (Elf32_External_Relr)
- && entsize != sizeof (Elf64_External_Relr))
- return 0;
-
- nentries = section->sh_size / entsize;
- if (nentries == 0)
- return 0;
-
- /* FIXME: This call to get_data duplicates one that follows in
- dump_relr_relocations(). They could be combined into just
- one call. */
- relrs = get_data (NULL, filedata, section->sh_offset, 1,
- section->sh_size, _("RELR relocation data"));
- if (relrs == NULL)
- return 0;
-
- for (count = i = 0; i < nentries; i++)
- {
- uint64_t entry;
-
- if (entsize == sizeof (Elf32_External_Relr))
- entry = BYTE_GET (((Elf32_External_Relr *)relrs)[i].r_data);
- else
- entry = BYTE_GET (((Elf64_External_Relr *)relrs)[i].r_data);
-
- if ((entry & 1) == 0)
- {
- ++ count;
- }
- else
- {
- if (entry == 1)
- continue;
-
- for (; entry >>= 1;)
- if ((entry & 1) == 1)
- ++ count;
- }
- }
-
- free (relrs);
- return count;
-}
-
-static bool
-dump_relr_relocations (Filedata * filedata,
- Elf_Internal_Shdr * section,
- Elf_Internal_Sym * symtab,
- uint64_t nsyms,
- char * strtab,
- uint64_t strtablen)
-{
- uint64_t * relrs;
- uint64_t nentries, i;
- uint64_t relr_size = section->sh_size;
- int relr_entsize = section->sh_entsize;
- uint64_t relr_offset = section->sh_offset;
- uint64_t where = 0;
- int num_bits_in_entry;
-
- if (relr_entsize == 0)
- relr_entsize = is_32bit_elf
- ? sizeof (Elf32_External_Relr) : sizeof (Elf64_External_Relr);
-
- nentries = relr_size / relr_entsize;
-
- if (nentries == 0)
- return true;
-
- if (relr_entsize == sizeof (Elf32_External_Relr))
- num_bits_in_entry = 31;
- else if (relr_entsize == sizeof (Elf64_External_Relr))
- num_bits_in_entry = 63;
- else
- {
- warn (_("Unexpected entsize for RELR section\n"));
- return false;
- }
-
- relrs = get_data (NULL, filedata, relr_offset, 1, relr_size, _("RELR relocation data"));
- if (relrs == NULL)
- return false;
-
- /* Paranoia. */
- if (strtab == NULL)
- strtablen = 0;
- if (symtab == NULL)
- nsyms = 0;
-
- if (symtab != NULL)
- {
- /* Symbol tables are not sorted on address, but we want a quick lookup
- for the symbol associated with each address computed below, so sort
- the table then filter out unwanted entries. FIXME: This assumes that
- the symbol table will not be used later on for some other purpose. */
- qsort (symtab, nsyms, sizeof (Elf_Internal_Sym), symcmp);
- nsyms = filter_display_syms (filedata, symtab, nsyms, strtab, strtablen);
- }
-
- if (relr_entsize == sizeof (Elf32_External_Relr))
- printf (_ ("Index: Entry Address Symbolic Address\n"));
- else
- printf (_ ("Index: Entry Address Symbolic Address\n"));
-
- for (i = 0; i < nentries; i++)
- {
- uint64_t entry;
-
- if (relr_entsize == sizeof (Elf32_External_Relr))
- entry = BYTE_GET (((Elf32_External_Relr *)relrs)[i].r_data);
- else
- entry = BYTE_GET (((Elf64_External_Relr *)relrs)[i].r_data);
-
- /* We assume that there will never be more than 9999 entries. */
- printf (_("%04u: "), (unsigned int) i);
- print_vma (entry, ZERO_HEX);
- printf (" ");
-
- if ((entry & 1) == 0)
- {
- where = entry;
- print_relr_addr_and_sym (filedata, symtab, nsyms, strtab, where);
- printf ("\n");
- where += relr_entsize;
- }
- else
- {
- bool first = true;
- int j;
-
- /* The least significant bit is ignored. */
- if (entry == 1)
- /* This can actually happen when the linker is allowed to shrink
- RELR sections. For more details see: https://reviews.llvm.org/D67164. */
- continue;
- else if (i == 0)
- warn (_("Unusual RELR bitmap - no previous entry to set the base address\n"));
-
- for (j = 0; entry >>= 1; j++)
- if ((entry & 1) == 1)
- {
- uint64_t addr = where + (j * relr_entsize);
-
- if (first)
- {
- print_relr_addr_and_sym (filedata, symtab, nsyms, strtab, addr);
- first = false;
- }
- else
- {
- printf (_("\n%*s "), relr_entsize == 4 ? 15 : 23, " ");
- print_relr_addr_and_sym (filedata, symtab, nsyms, strtab, addr);
- }
- }
-
- printf ("\n");
- where += num_bits_in_entry * relr_entsize;
- }
- }
-
- free (relrs);
- return true;
-}
-
-/* Display the contents of the relocation data found at the specified
- offset. */
-
-static bool
-dump_relocations (Filedata * filedata,
- uint64_t rel_offset,
- uint64_t rel_size,
- Elf_Internal_Sym * symtab,
- uint64_t nsyms,
- char * strtab,
- uint64_t strtablen,
- relocation_type rel_type,
- bool is_dynsym)
-{
- size_t i;
- Elf_Internal_Rela * rels;
- bool res = true;
-
- if (rel_type == reltype_unknown)
- rel_type = guess_is_rela (filedata->file_header.e_machine) ? reltype_rela : reltype_rel;
-
- if (rel_type == reltype_rela)
- {
- if (!slurp_rela_relocs (filedata, rel_offset, rel_size, &rels, &rel_size))
- return false;
- }
- else if (rel_type == reltype_rel)
- {
- if (!slurp_rel_relocs (filedata, rel_offset, rel_size, &rels, &rel_size))
- return false;
- }
- else if (rel_type == reltype_relr)
- {
- /* This should have been handled by display_relocations(). */
- return false;
- }
-
- if (is_32bit_elf)
- {
- if (rel_type == reltype_rela)
- {
- if (do_wide)
- printf (_(" Offset Info Type Sym. Value Symbol's Name + Addend\n"));
- else
- printf (_(" Offset Info Type Sym.Value Sym. Name + Addend\n"));
- }
- else
- {
- if (do_wide)
- printf (_(" Offset Info Type Sym. Value Symbol's Name\n"));
- else
- printf (_(" Offset Info Type Sym.Value Sym. Name\n"));
- }
- }
- else
- {
- if (rel_type == reltype_rela)
- {
- if (do_wide)
- printf (_(" Offset Info Type Symbol's Value Symbol's Name + Addend\n"));
- else
- printf (_(" Offset Info Type Sym. Value Sym. Name + Addend\n"));
- }
- else
- {
- if (do_wide)
- printf (_(" Offset Info Type Symbol's Value Symbol's Name\n"));
- else
- printf (_(" Offset Info Type Sym. Value Sym. Name\n"));
- }
- }
-
- for (i = 0; i < rel_size; i++)
- {
- const char * rtype;
- uint64_t offset;
- uint64_t inf;
- uint64_t symtab_index;
- uint64_t type;
-
- offset = rels[i].r_offset;
- inf = rels[i].r_info;
-
- type = get_reloc_type (filedata, inf);
- symtab_index = get_reloc_symindex (inf);
-
- if (is_32bit_elf)
- {
- printf ("%8.8lx %8.8lx ",
- (unsigned long) offset & 0xffffffff,
- (unsigned long) inf & 0xffffffff);
- }
- else
- {
- printf (do_wide
- ? "%16.16" PRIx64 " %16.16" PRIx64 " "
- : "%12.12" PRIx64 " %12.12" PRIx64 " ",
- offset, inf);
- }
-
- switch (filedata->file_header.e_machine)
- {
- default:
- rtype = NULL;
- break;
-
- case EM_AARCH64:
- rtype = elf_aarch64_reloc_type (type);
- break;
-
- case EM_M32R:
- case EM_CYGNUS_M32R:
- rtype = elf_m32r_reloc_type (type);
- break;
-
- case EM_386:
- case EM_IAMCU:
- rtype = elf_i386_reloc_type (type);
- break;
-
- case EM_68HC11:
- case EM_68HC12:
- rtype = elf_m68hc11_reloc_type (type);
- break;
-
- case EM_S12Z:
- rtype = elf_s12z_reloc_type (type);
- break;
-
- case EM_68K:
- rtype = elf_m68k_reloc_type (type);
- break;
-
- case EM_960:
- rtype = elf_i960_reloc_type (type);
- break;
-
- case EM_AVR:
- case EM_AVR_OLD:
- rtype = elf_avr_reloc_type (type);
- break;
-
- case EM_OLD_SPARCV9:
- case EM_SPARC32PLUS:
- case EM_SPARCV9:
- case EM_SPARC:
- rtype = elf_sparc_reloc_type (type);
- break;
-
- case EM_SPU:
- rtype = elf_spu_reloc_type (type);
- break;
-
- case EM_V800:
- rtype = v800_reloc_type (type);
- break;
- case EM_V850:
- case EM_CYGNUS_V850:
- rtype = v850_reloc_type (type);
- break;
-
- case EM_D10V:
- case EM_CYGNUS_D10V:
- rtype = elf_d10v_reloc_type (type);
- break;
-
- case EM_D30V:
- case EM_CYGNUS_D30V:
- rtype = elf_d30v_reloc_type (type);
- break;
-
- case EM_DLX:
- rtype = elf_dlx_reloc_type (type);
- break;
-
- case EM_SH:
- rtype = elf_sh_reloc_type (type);
- break;
-
- case EM_MN10300:
- case EM_CYGNUS_MN10300:
- rtype = elf_mn10300_reloc_type (type);
- break;
-
- case EM_MN10200:
- case EM_CYGNUS_MN10200:
- rtype = elf_mn10200_reloc_type (type);
- break;
-
- case EM_FR30:
- case EM_CYGNUS_FR30:
- rtype = elf_fr30_reloc_type (type);
- break;
-
- case EM_CYGNUS_FRV:
- rtype = elf_frv_reloc_type (type);
- break;
-
- case EM_CSKY:
- rtype = elf_csky_reloc_type (type);
- break;
-
- case EM_FT32:
- rtype = elf_ft32_reloc_type (type);
- break;
-
- case EM_MCORE:
- rtype = elf_mcore_reloc_type (type);
- break;
-
- case EM_MMIX:
- rtype = elf_mmix_reloc_type (type);
- break;
-
- case EM_MOXIE:
- rtype = elf_moxie_reloc_type (type);
- break;
-
- case EM_MSP430:
- if (uses_msp430x_relocs (filedata))
- {
- rtype = elf_msp430x_reloc_type (type);
- break;
- }
- /* Fall through. */
- case EM_MSP430_OLD:
- rtype = elf_msp430_reloc_type (type);
- break;
-
- case EM_NDS32:
- rtype = elf_nds32_reloc_type (type);
- break;
-
- case EM_PPC:
- rtype = elf_ppc_reloc_type (type);
- break;
-
- case EM_PPC64:
- rtype = elf_ppc64_reloc_type (type);
- break;
-
- case EM_MIPS:
- case EM_MIPS_RS3_LE:
- rtype = elf_mips_reloc_type (type);
- break;
-
- case EM_RISCV:
- rtype = elf_riscv_reloc_type (type);
- break;
-
- case EM_ALPHA:
- rtype = elf_alpha_reloc_type (type);
- break;
-
- case EM_ARM:
- rtype = elf_arm_reloc_type (type);
- break;
-
- case EM_ARC:
- case EM_ARC_COMPACT:
- case EM_ARC_COMPACT2:
- case EM_ARC_COMPACT3:
- case EM_ARC_COMPACT3_64:
- rtype = elf_arc_reloc_type (type);
- break;
-
- case EM_PARISC:
- rtype = elf_hppa_reloc_type (type);
- break;
-
- case EM_H8_300:
- case EM_H8_300H:
- case EM_H8S:
- rtype = elf_h8_reloc_type (type);
- break;
-
- case EM_OR1K:
- rtype = elf_or1k_reloc_type (type);
- break;
-
- case EM_PJ:
- case EM_PJ_OLD:
- rtype = elf_pj_reloc_type (type);
- break;
- case EM_IA_64:
- rtype = elf_ia64_reloc_type (type);
- break;
-
- case EM_KVX:
- rtype = elf_kvx_reloc_type (type);
- break;
-
- case EM_CRIS:
- rtype = elf_cris_reloc_type (type);
- break;
-
- case EM_860:
- rtype = elf_i860_reloc_type (type);
- break;
-
- case EM_X86_64:
- case EM_L1OM:
- case EM_K1OM:
- rtype = elf_x86_64_reloc_type (type);
- break;
-
- case EM_S370:
- rtype = i370_reloc_type (type);
- break;
-
- case EM_S390_OLD:
- case EM_S390:
- rtype = elf_s390_reloc_type (type);
- break;
-
- case EM_SCORE:
- rtype = elf_score_reloc_type (type);
- break;
-
- case EM_XSTORMY16:
- rtype = elf_xstormy16_reloc_type (type);
- break;
-
- case EM_CRX:
- rtype = elf_crx_reloc_type (type);
- break;
-
- case EM_VAX:
- rtype = elf_vax_reloc_type (type);
- break;
-
- case EM_VISIUM:
- rtype = elf_visium_reloc_type (type);
- break;
-
- case EM_BPF:
- rtype = elf_bpf_reloc_type (type);
- break;
-
- case EM_ADAPTEVA_EPIPHANY:
- rtype = elf_epiphany_reloc_type (type);
- break;
-
- case EM_IP2K:
- case EM_IP2K_OLD:
- rtype = elf_ip2k_reloc_type (type);
- break;
-
- case EM_IQ2000:
- rtype = elf_iq2000_reloc_type (type);
- break;
-
- case EM_XTENSA_OLD:
- case EM_XTENSA:
- rtype = elf_xtensa_reloc_type (type);
- break;
-
- case EM_LATTICEMICO32:
- rtype = elf_lm32_reloc_type (type);
- break;
-
- case EM_M32C_OLD:
- case EM_M32C:
- rtype = elf_m32c_reloc_type (type);
- break;
-
- case EM_MT:
- rtype = elf_mt_reloc_type (type);
- break;
-
- case EM_BLACKFIN:
- rtype = elf_bfin_reloc_type (type);
- break;
-
- case EM_CYGNUS_MEP:
- rtype = elf_mep_reloc_type (type);
- break;
-
- case EM_CR16:
- rtype = elf_cr16_reloc_type (type);
- break;
-
- case EM_MICROBLAZE:
- case EM_MICROBLAZE_OLD:
- rtype = elf_microblaze_reloc_type (type);
- break;
-
- case EM_RL78:
- rtype = elf_rl78_reloc_type (type);
- break;
-
- case EM_RX:
- rtype = elf_rx_reloc_type (type);
- break;
-
- case EM_METAG:
- rtype = elf_metag_reloc_type (type);
- break;
-
- case EM_TI_C6000:
- rtype = elf_tic6x_reloc_type (type);
- break;
-
- case EM_TILEGX:
- rtype = elf_tilegx_reloc_type (type);
- break;
-
- case EM_TILEPRO:
- rtype = elf_tilepro_reloc_type (type);
- break;
-
- case EM_WEBASSEMBLY:
- rtype = elf_wasm32_reloc_type (type);
- break;
-
- case EM_XGATE:
- rtype = elf_xgate_reloc_type (type);
- break;
-
- case EM_ALTERA_NIOS2:
- rtype = elf_nios2_reloc_type (type);
- break;
-
- case EM_TI_PRU:
- rtype = elf_pru_reloc_type (type);
- break;
-
- case EM_NFP:
- if (EF_NFP_MACH (filedata->file_header.e_flags) == E_NFP_MACH_3200)
- rtype = elf_nfp3200_reloc_type (type);
- else
- rtype = elf_nfp_reloc_type (type);
- break;
-
- case EM_Z80:
- rtype = elf_z80_reloc_type (type);
- break;
-
- case EM_LOONGARCH:
- rtype = elf_loongarch_reloc_type (type);
- break;
-
- case EM_AMDGPU:
- rtype = elf_amdgpu_reloc_type (type);
- break;
- }
-
- if (rtype == NULL)
- printf (_("unrecognized: %-7lx"), (unsigned long) type & 0xffffffff);
- else
- printf (do_wide ? "%-22s" : "%-17.17s", rtype);
-
- if (filedata->file_header.e_machine == EM_ALPHA
- && rtype != NULL
- && streq (rtype, "R_ALPHA_LITUSE")
- && rel_type == reltype_rela)
- {
- switch (rels[i].r_addend)
- {
- case LITUSE_ALPHA_ADDR: rtype = "ADDR"; break;
- case LITUSE_ALPHA_BASE: rtype = "BASE"; break;
- case LITUSE_ALPHA_BYTOFF: rtype = "BYTOFF"; break;
- case LITUSE_ALPHA_JSR: rtype = "JSR"; break;
- case LITUSE_ALPHA_TLSGD: rtype = "TLSGD"; break;
- case LITUSE_ALPHA_TLSLDM: rtype = "TLSLDM"; break;
- case LITUSE_ALPHA_JSRDIRECT: rtype = "JSRDIRECT"; break;
- default: rtype = NULL;
- }
-
- if (rtype)
- printf (" (%s)", rtype);
- else
- {
- putchar (' ');
- printf (_("<unknown addend: %" PRIx64 ">"),
- rels[i].r_addend);
- res = false;
- }
- }
- else if (symtab_index)
- {
- if (symtab == NULL || symtab_index >= nsyms)
- {
- error (_(" bad symbol index: %08lx in reloc\n"),
- (unsigned long) symtab_index);
- res = false;
- }
- else
- {
- Elf_Internal_Sym * psym;
- const char * version_string;
- enum versioned_symbol_info sym_info;
- unsigned short vna_other;
-
- psym = symtab + symtab_index;
-
- version_string
- = get_symbol_version_string (filedata, is_dynsym,
- strtab, strtablen,
- symtab_index,
- psym,
- &sym_info,
- &vna_other);
-
- printf (" ");
-
- if (ELF_ST_TYPE (psym->st_info) == STT_GNU_IFUNC)
- {
- const char * name;
- unsigned int len;
- unsigned int width = is_32bit_elf ? 8 : 14;
-
- /* Relocations against GNU_IFUNC symbols do not use the value
- of the symbol as the address to relocate against. Instead
- they invoke the function named by the symbol and use its
- result as the address for relocation.
-
- To indicate this to the user, do not display the value of
- the symbol in the "Symbols's Value" field. Instead show
- its name followed by () as a hint that the symbol is
- invoked. */
-
- if (strtab == NULL
- || psym->st_name == 0
- || psym->st_name >= strtablen)
- name = "??";
- else
- name = strtab + psym->st_name;
-
- len = print_symbol_name (width, name);
- if (version_string)
- printf (sym_info == symbol_public ? "@@%s" : "@%s",
- version_string);
- printf ("()%-*s", len <= width ? (width + 1) - len : 1, " ");
- }
- else
- {
- print_vma (psym->st_value, LONG_HEX);
-
- printf (is_32bit_elf ? " " : " ");
- }
-
- if (psym->st_name == 0)
- {
- const char * sec_name = "<null>";
-
- if (ELF_ST_TYPE (psym->st_info) == STT_SECTION)
- sec_name = printable_section_name_from_index
- (filedata, psym->st_shndx, NULL);
-
- print_symbol_name (22, sec_name);
- }
- else if (strtab == NULL)
- printf (_("<string table index: %3ld>"), psym->st_name);
- else if (psym->st_name >= strtablen)
- {
- error (_("<corrupt string table index: %3ld>\n"),
- psym->st_name);
- res = false;
- }
- else
- {
- print_symbol_name (22, strtab + psym->st_name);
- if (version_string)
- printf (sym_info == symbol_public ? "@@%s" : "@%s",
- version_string);
- }
-
- if (rel_type == reltype_rela)
- {
- uint64_t off = rels[i].r_addend;
-
- if ((int64_t) off < 0)
- printf (" - %" PRIx64, -off);
- else
- printf (" + %" PRIx64, off);
- }
- }
- }
- else if (rel_type == reltype_rela)
- {
- uint64_t off = rels[i].r_addend;
-
- printf ("%*c", is_32bit_elf ? 12 : 20, ' ');
- if ((int64_t) off < 0)
- printf ("-%" PRIx64, -off);
- else
- printf ("%" PRIx64, off);
- }
-
- if (filedata->file_header.e_machine == EM_SPARCV9
- && rtype != NULL
- && streq (rtype, "R_SPARC_OLO10"))
- printf (" + %" PRIx64, ELF64_R_TYPE_DATA (inf));
-
- putchar ('\n');
-
- if (! is_32bit_elf && filedata->file_header.e_machine == EM_MIPS)
- {
- uint64_t type2 = ELF64_MIPS_R_TYPE2 (inf);
- uint64_t type3 = ELF64_MIPS_R_TYPE3 (inf);
- const char * rtype2 = elf_mips_reloc_type (type2);
- const char * rtype3 = elf_mips_reloc_type (type3);
-
- printf (" Type2: ");
-
- if (rtype2 == NULL)
- printf (_("unrecognized: %-7lx"),
- (unsigned long) type2 & 0xffffffff);
- else
- printf ("%-17.17s", rtype2);
-
- printf ("\n Type3: ");
-
- if (rtype3 == NULL)
- printf (_("unrecognized: %-7lx"),
- (unsigned long) type3 & 0xffffffff);
- else
- printf ("%-17.17s", rtype3);
-
- putchar ('\n');
- }
- }
-
- free (rels);
-
- return res;
-}
-
-static const char *
-get_aarch64_dynamic_type (unsigned long type)
-{
- switch (type)
- {
- case DT_AARCH64_BTI_PLT: return "AARCH64_BTI_PLT";
- case DT_AARCH64_PAC_PLT: return "AARCH64_PAC_PLT";
- case DT_AARCH64_VARIANT_PCS: return "AARCH64_VARIANT_PCS";
- default:
- return NULL;
- }
-}
-
-static const char *
-get_mips_dynamic_type (unsigned long type)
-{
- switch (type)
- {
- case DT_MIPS_RLD_VERSION: return "MIPS_RLD_VERSION";
- case DT_MIPS_TIME_STAMP: return "MIPS_TIME_STAMP";
- case DT_MIPS_ICHECKSUM: return "MIPS_ICHECKSUM";
- case DT_MIPS_IVERSION: return "MIPS_IVERSION";
- case DT_MIPS_FLAGS: return "MIPS_FLAGS";
- case DT_MIPS_BASE_ADDRESS: return "MIPS_BASE_ADDRESS";
- case DT_MIPS_MSYM: return "MIPS_MSYM";
- case DT_MIPS_CONFLICT: return "MIPS_CONFLICT";
- case DT_MIPS_LIBLIST: return "MIPS_LIBLIST";
- case DT_MIPS_LOCAL_GOTNO: return "MIPS_LOCAL_GOTNO";
- case DT_MIPS_CONFLICTNO: return "MIPS_CONFLICTNO";
- case DT_MIPS_LIBLISTNO: return "MIPS_LIBLISTNO";
- case DT_MIPS_SYMTABNO: return "MIPS_SYMTABNO";
- case DT_MIPS_UNREFEXTNO: return "MIPS_UNREFEXTNO";
- case DT_MIPS_GOTSYM: return "MIPS_GOTSYM";
- case DT_MIPS_HIPAGENO: return "MIPS_HIPAGENO";
- case DT_MIPS_RLD_MAP: return "MIPS_RLD_MAP";
- case DT_MIPS_RLD_MAP_REL: return "MIPS_RLD_MAP_REL";
- case DT_MIPS_DELTA_CLASS: return "MIPS_DELTA_CLASS";
- case DT_MIPS_DELTA_CLASS_NO: return "MIPS_DELTA_CLASS_NO";
- case DT_MIPS_DELTA_INSTANCE: return "MIPS_DELTA_INSTANCE";
- case DT_MIPS_DELTA_INSTANCE_NO: return "MIPS_DELTA_INSTANCE_NO";
- case DT_MIPS_DELTA_RELOC: return "MIPS_DELTA_RELOC";
- case DT_MIPS_DELTA_RELOC_NO: return "MIPS_DELTA_RELOC_NO";
- case DT_MIPS_DELTA_SYM: return "MIPS_DELTA_SYM";
- case DT_MIPS_DELTA_SYM_NO: return "MIPS_DELTA_SYM_NO";
- case DT_MIPS_DELTA_CLASSSYM: return "MIPS_DELTA_CLASSSYM";
- case DT_MIPS_DELTA_CLASSSYM_NO: return "MIPS_DELTA_CLASSSYM_NO";
- case DT_MIPS_CXX_FLAGS: return "MIPS_CXX_FLAGS";
- case DT_MIPS_PIXIE_INIT: return "MIPS_PIXIE_INIT";
- case DT_MIPS_SYMBOL_LIB: return "MIPS_SYMBOL_LIB";
- case DT_MIPS_LOCALPAGE_GOTIDX: return "MIPS_LOCALPAGE_GOTIDX";
- case DT_MIPS_LOCAL_GOTIDX: return "MIPS_LOCAL_GOTIDX";
- case DT_MIPS_HIDDEN_GOTIDX: return "MIPS_HIDDEN_GOTIDX";
- case DT_MIPS_PROTECTED_GOTIDX: return "MIPS_PROTECTED_GOTIDX";
- case DT_MIPS_OPTIONS: return "MIPS_OPTIONS";
- case DT_MIPS_INTERFACE: return "MIPS_INTERFACE";
- case DT_MIPS_DYNSTR_ALIGN: return "MIPS_DYNSTR_ALIGN";
- case DT_MIPS_INTERFACE_SIZE: return "MIPS_INTERFACE_SIZE";
- case DT_MIPS_RLD_TEXT_RESOLVE_ADDR: return "MIPS_RLD_TEXT_RESOLVE_ADDR";
- case DT_MIPS_PERF_SUFFIX: return "MIPS_PERF_SUFFIX";
- case DT_MIPS_COMPACT_SIZE: return "MIPS_COMPACT_SIZE";
- case DT_MIPS_GP_VALUE: return "MIPS_GP_VALUE";
- case DT_MIPS_AUX_DYNAMIC: return "MIPS_AUX_DYNAMIC";
- case DT_MIPS_PLTGOT: return "MIPS_PLTGOT";
- case DT_MIPS_RWPLT: return "MIPS_RWPLT";
- case DT_MIPS_XHASH: return "MIPS_XHASH";
- default:
- return NULL;
- }
-}
-
-static const char *
-get_sparc64_dynamic_type (unsigned long type)
-{
- switch (type)
- {
- case DT_SPARC_REGISTER: return "SPARC_REGISTER";
- default:
- return NULL;
- }
-}
-
-static const char *
-get_ppc_dynamic_type (unsigned long type)
-{
- switch (type)
- {
- case DT_PPC_GOT: return "PPC_GOT";
- case DT_PPC_OPT: return "PPC_OPT";
- default:
- return NULL;
- }
-}
-
-static const char *
-get_ppc64_dynamic_type (unsigned long type)
-{
- switch (type)
- {
- case DT_PPC64_GLINK: return "PPC64_GLINK";
- case DT_PPC64_OPD: return "PPC64_OPD";
- case DT_PPC64_OPDSZ: return "PPC64_OPDSZ";
- case DT_PPC64_OPT: return "PPC64_OPT";
- default:
- return NULL;
- }
-}
-
-static const char *
-get_parisc_dynamic_type (unsigned long type)
-{
- switch (type)
- {
- case DT_HP_LOAD_MAP: return "HP_LOAD_MAP";
- case DT_HP_DLD_FLAGS: return "HP_DLD_FLAGS";
- case DT_HP_DLD_HOOK: return "HP_DLD_HOOK";
- case DT_HP_UX10_INIT: return "HP_UX10_INIT";
- case DT_HP_UX10_INITSZ: return "HP_UX10_INITSZ";
- case DT_HP_PREINIT: return "HP_PREINIT";
- case DT_HP_PREINITSZ: return "HP_PREINITSZ";
- case DT_HP_NEEDED: return "HP_NEEDED";
- case DT_HP_TIME_STAMP: return "HP_TIME_STAMP";
- case DT_HP_CHECKSUM: return "HP_CHECKSUM";
- case DT_HP_GST_SIZE: return "HP_GST_SIZE";
- case DT_HP_GST_VERSION: return "HP_GST_VERSION";
- case DT_HP_GST_HASHVAL: return "HP_GST_HASHVAL";
- case DT_HP_EPLTREL: return "HP_GST_EPLTREL";
- case DT_HP_EPLTRELSZ: return "HP_GST_EPLTRELSZ";
- case DT_HP_FILTERED: return "HP_FILTERED";
- case DT_HP_FILTER_TLS: return "HP_FILTER_TLS";
- case DT_HP_COMPAT_FILTERED: return "HP_COMPAT_FILTERED";
- case DT_HP_LAZYLOAD: return "HP_LAZYLOAD";
- case DT_HP_BIND_NOW_COUNT: return "HP_BIND_NOW_COUNT";
- case DT_PLT: return "PLT";
- case DT_PLT_SIZE: return "PLT_SIZE";
- case DT_DLT: return "DLT";
- case DT_DLT_SIZE: return "DLT_SIZE";
- default:
- return NULL;
- }
-}
-
-static const char *
-get_ia64_dynamic_type (unsigned long type)
-{
- switch (type)
- {
- case DT_IA_64_PLT_RESERVE: return "IA_64_PLT_RESERVE";
- case DT_IA_64_VMS_SUBTYPE: return "VMS_SUBTYPE";
- case DT_IA_64_VMS_IMGIOCNT: return "VMS_IMGIOCNT";
- case DT_IA_64_VMS_LNKFLAGS: return "VMS_LNKFLAGS";
- case DT_IA_64_VMS_VIR_MEM_BLK_SIZ: return "VMS_VIR_MEM_BLK_SIZ";
- case DT_IA_64_VMS_IDENT: return "VMS_IDENT";
- case DT_IA_64_VMS_NEEDED_IDENT: return "VMS_NEEDED_IDENT";
- case DT_IA_64_VMS_IMG_RELA_CNT: return "VMS_IMG_RELA_CNT";
- case DT_IA_64_VMS_SEG_RELA_CNT: return "VMS_SEG_RELA_CNT";
- case DT_IA_64_VMS_FIXUP_RELA_CNT: return "VMS_FIXUP_RELA_CNT";
- case DT_IA_64_VMS_FIXUP_NEEDED: return "VMS_FIXUP_NEEDED";
- case DT_IA_64_VMS_SYMVEC_CNT: return "VMS_SYMVEC_CNT";
- case DT_IA_64_VMS_XLATED: return "VMS_XLATED";
- case DT_IA_64_VMS_STACKSIZE: return "VMS_STACKSIZE";
- case DT_IA_64_VMS_UNWINDSZ: return "VMS_UNWINDSZ";
- case DT_IA_64_VMS_UNWIND_CODSEG: return "VMS_UNWIND_CODSEG";
- case DT_IA_64_VMS_UNWIND_INFOSEG: return "VMS_UNWIND_INFOSEG";
- case DT_IA_64_VMS_LINKTIME: return "VMS_LINKTIME";
- case DT_IA_64_VMS_SEG_NO: return "VMS_SEG_NO";
- case DT_IA_64_VMS_SYMVEC_OFFSET: return "VMS_SYMVEC_OFFSET";
- case DT_IA_64_VMS_SYMVEC_SEG: return "VMS_SYMVEC_SEG";
- case DT_IA_64_VMS_UNWIND_OFFSET: return "VMS_UNWIND_OFFSET";
- case DT_IA_64_VMS_UNWIND_SEG: return "VMS_UNWIND_SEG";
- case DT_IA_64_VMS_STRTAB_OFFSET: return "VMS_STRTAB_OFFSET";
- case DT_IA_64_VMS_SYSVER_OFFSET: return "VMS_SYSVER_OFFSET";
- case DT_IA_64_VMS_IMG_RELA_OFF: return "VMS_IMG_RELA_OFF";
- case DT_IA_64_VMS_SEG_RELA_OFF: return "VMS_SEG_RELA_OFF";
- case DT_IA_64_VMS_FIXUP_RELA_OFF: return "VMS_FIXUP_RELA_OFF";
- case DT_IA_64_VMS_PLTGOT_OFFSET: return "VMS_PLTGOT_OFFSET";
- case DT_IA_64_VMS_PLTGOT_SEG: return "VMS_PLTGOT_SEG";
- case DT_IA_64_VMS_FPMODE: return "VMS_FPMODE";
- default:
- return NULL;
- }
-}
-
-static const char *
-get_solaris_section_type (unsigned long type)
-{
- switch (type)
- {
- case 0x6fffffee: return "SUNW_ancillary";
- case 0x6fffffef: return "SUNW_capchain";
- case 0x6ffffff0: return "SUNW_capinfo";
- case 0x6ffffff1: return "SUNW_symsort";
- case 0x6ffffff2: return "SUNW_tlssort";
- case 0x6ffffff3: return "SUNW_LDYNSYM";
- case 0x6ffffff4: return "SUNW_dof";
- case 0x6ffffff5: return "SUNW_cap";
- case 0x6ffffff6: return "SUNW_SIGNATURE";
- case 0x6ffffff7: return "SUNW_ANNOTATE";
- case 0x6ffffff8: return "SUNW_DEBUGSTR";
- case 0x6ffffff9: return "SUNW_DEBUG";
- case 0x6ffffffa: return "SUNW_move";
- case 0x6ffffffb: return "SUNW_COMDAT";
- case 0x6ffffffc: return "SUNW_syminfo";
- case 0x6ffffffd: return "SUNW_verdef";
- case 0x6ffffffe: return "SUNW_verneed";
- case 0x6fffffff: return "SUNW_versym";
- case 0x70000000: return "SPARC_GOTDATA";
- default: return NULL;
- }
-}
-
-static const char *
-get_alpha_dynamic_type (unsigned long type)
-{
- switch (type)
- {
- case DT_ALPHA_PLTRO: return "ALPHA_PLTRO";
- default: return NULL;
- }
-}
-
-static const char *
-get_score_dynamic_type (unsigned long type)
-{
- switch (type)
- {
- case DT_SCORE_BASE_ADDRESS: return "SCORE_BASE_ADDRESS";
- case DT_SCORE_LOCAL_GOTNO: return "SCORE_LOCAL_GOTNO";
- case DT_SCORE_SYMTABNO: return "SCORE_SYMTABNO";
- case DT_SCORE_GOTSYM: return "SCORE_GOTSYM";
- case DT_SCORE_UNREFEXTNO: return "SCORE_UNREFEXTNO";
- case DT_SCORE_HIPAGENO: return "SCORE_HIPAGENO";
- default: return NULL;
- }
-}
-
-static const char *
-get_tic6x_dynamic_type (unsigned long type)
-{
- switch (type)
- {
- case DT_C6000_GSYM_OFFSET: return "C6000_GSYM_OFFSET";
- case DT_C6000_GSTR_OFFSET: return "C6000_GSTR_OFFSET";
- case DT_C6000_DSBT_BASE: return "C6000_DSBT_BASE";
- case DT_C6000_DSBT_SIZE: return "C6000_DSBT_SIZE";
- case DT_C6000_PREEMPTMAP: return "C6000_PREEMPTMAP";
- case DT_C6000_DSBT_INDEX: return "C6000_DSBT_INDEX";
- default: return NULL;
- }
-}
-
-static const char *
-get_nios2_dynamic_type (unsigned long type)
-{
- switch (type)
- {
- case DT_NIOS2_GP: return "NIOS2_GP";
- default: return NULL;
- }
-}
-
-static const char *
-get_solaris_dynamic_type (unsigned long type)
-{
- switch (type)
- {
- case 0x6000000d: return "SUNW_AUXILIARY";
- case 0x6000000e: return "SUNW_RTLDINF";
- case 0x6000000f: return "SUNW_FILTER";
- case 0x60000010: return "SUNW_CAP";
- case 0x60000011: return "SUNW_SYMTAB";
- case 0x60000012: return "SUNW_SYMSZ";
- case 0x60000013: return "SUNW_SORTENT";
- case 0x60000014: return "SUNW_SYMSORT";
- case 0x60000015: return "SUNW_SYMSORTSZ";
- case 0x60000016: return "SUNW_TLSSORT";
- case 0x60000017: return "SUNW_TLSSORTSZ";
- case 0x60000018: return "SUNW_CAPINFO";
- case 0x60000019: return "SUNW_STRPAD";
- case 0x6000001a: return "SUNW_CAPCHAIN";
- case 0x6000001b: return "SUNW_LDMACH";
- case 0x6000001d: return "SUNW_CAPCHAINENT";
- case 0x6000001f: return "SUNW_CAPCHAINSZ";
- case 0x60000021: return "SUNW_PARENT";
- case 0x60000023: return "SUNW_ASLR";
- case 0x60000025: return "SUNW_RELAX";
- case 0x60000029: return "SUNW_NXHEAP";
- case 0x6000002b: return "SUNW_NXSTACK";
-
- case 0x70000001: return "SPARC_REGISTER";
- case 0x7ffffffd: return "AUXILIARY";
- case 0x7ffffffe: return "USED";
- case 0x7fffffff: return "FILTER";
-
- default: return NULL;
- }
-}
-
-static const char *
-get_riscv_dynamic_type (unsigned long type)
-{
- switch (type)
- {
- case DT_RISCV_VARIANT_CC: return "RISCV_VARIANT_CC";
- default:
- return NULL;
- }
-}
-
-static const char *
-get_x86_64_dynamic_type (unsigned long type)
-{
- switch (type)
- {
- case DT_X86_64_PLT:
- return "DT_X86_64_PLT";
- case DT_X86_64_PLTSZ:
- return "DT_X86_64_PLTSZ";
- case DT_X86_64_PLTENT:
- return "DT_X86_64_PLTENT";
- default:
- return NULL;
- }
-}
-
-static const char *
-get_dynamic_type (Filedata * filedata, unsigned long type)
-{
- static char buff[64];
-
- switch (type)
- {
- case DT_NULL: return "NULL";
- case DT_NEEDED: return "NEEDED";
- case DT_PLTRELSZ: return "PLTRELSZ";
- case DT_PLTGOT: return "PLTGOT";
- case DT_HASH: return "HASH";
- case DT_STRTAB: return "STRTAB";
- case DT_SYMTAB: return "SYMTAB";
- case DT_RELA: return "RELA";
- case DT_RELASZ: return "RELASZ";
- case DT_RELAENT: return "RELAENT";
- case DT_STRSZ: return "STRSZ";
- case DT_SYMENT: return "SYMENT";
- case DT_INIT: return "INIT";
- case DT_FINI: return "FINI";
- case DT_SONAME: return "SONAME";
- case DT_RPATH: return "RPATH";
- case DT_SYMBOLIC: return "SYMBOLIC";
- case DT_REL: return "REL";
- case DT_RELSZ: return "RELSZ";
- case DT_RELENT: return "RELENT";
- case DT_RELR: return "RELR";
- case DT_RELRSZ: return "RELRSZ";
- case DT_RELRENT: return "RELRENT";
- case DT_PLTREL: return "PLTREL";
- case DT_DEBUG: return "DEBUG";
- case DT_TEXTREL: return "TEXTREL";
- case DT_JMPREL: return "JMPREL";
- case DT_BIND_NOW: return "BIND_NOW";
- case DT_INIT_ARRAY: return "INIT_ARRAY";
- case DT_FINI_ARRAY: return "FINI_ARRAY";
- case DT_INIT_ARRAYSZ: return "INIT_ARRAYSZ";
- case DT_FINI_ARRAYSZ: return "FINI_ARRAYSZ";
- case DT_RUNPATH: return "RUNPATH";
- case DT_FLAGS: return "FLAGS";
-
- case DT_PREINIT_ARRAY: return "PREINIT_ARRAY";
- case DT_PREINIT_ARRAYSZ: return "PREINIT_ARRAYSZ";
- case DT_SYMTAB_SHNDX: return "SYMTAB_SHNDX";
-
- case DT_CHECKSUM: return "CHECKSUM";
- case DT_PLTPADSZ: return "PLTPADSZ";
- case DT_MOVEENT: return "MOVEENT";
- case DT_MOVESZ: return "MOVESZ";
- case DT_FEATURE: return "FEATURE";
- case DT_POSFLAG_1: return "POSFLAG_1";
- case DT_SYMINSZ: return "SYMINSZ";
- case DT_SYMINENT: return "SYMINENT"; /* aka VALRNGHI */
-
- case DT_ADDRRNGLO: return "ADDRRNGLO";
- case DT_CONFIG: return "CONFIG";
- case DT_DEPAUDIT: return "DEPAUDIT";
- case DT_AUDIT: return "AUDIT";
- case DT_PLTPAD: return "PLTPAD";
- case DT_MOVETAB: return "MOVETAB";
- case DT_SYMINFO: return "SYMINFO"; /* aka ADDRRNGHI */
-
- case DT_VERSYM: return "VERSYM";
-
- case DT_TLSDESC_GOT: return "TLSDESC_GOT";
- case DT_TLSDESC_PLT: return "TLSDESC_PLT";
- case DT_RELACOUNT: return "RELACOUNT";
- case DT_RELCOUNT: return "RELCOUNT";
- case DT_FLAGS_1: return "FLAGS_1";
- case DT_VERDEF: return "VERDEF";
- case DT_VERDEFNUM: return "VERDEFNUM";
- case DT_VERNEED: return "VERNEED";
- case DT_VERNEEDNUM: return "VERNEEDNUM";
-
- case DT_AUXILIARY: return "AUXILIARY";
- case DT_USED: return "USED";
- case DT_FILTER: return "FILTER";
-
- case DT_GNU_PRELINKED: return "GNU_PRELINKED";
- case DT_GNU_CONFLICT: return "GNU_CONFLICT";
- case DT_GNU_CONFLICTSZ: return "GNU_CONFLICTSZ";
- case DT_GNU_LIBLIST: return "GNU_LIBLIST";
- case DT_GNU_LIBLISTSZ: return "GNU_LIBLISTSZ";
- case DT_GNU_HASH: return "GNU_HASH";
- case DT_GNU_FLAGS_1: return "GNU_FLAGS_1";
-
- default:
- if ((type >= DT_LOPROC) && (type <= DT_HIPROC))
- {
- const char * result;
-
- switch (filedata->file_header.e_machine)
- {
- case EM_AARCH64:
- result = get_aarch64_dynamic_type (type);
- break;
- case EM_MIPS:
- case EM_MIPS_RS3_LE:
- result = get_mips_dynamic_type (type);
- break;
- case EM_SPARCV9:
- result = get_sparc64_dynamic_type (type);
- break;
- case EM_PPC:
- result = get_ppc_dynamic_type (type);
- break;
- case EM_PPC64:
- result = get_ppc64_dynamic_type (type);
- break;
- case EM_IA_64:
- result = get_ia64_dynamic_type (type);
- break;
- case EM_ALPHA:
- result = get_alpha_dynamic_type (type);
- break;
- case EM_SCORE:
- result = get_score_dynamic_type (type);
- break;
- case EM_TI_C6000:
- result = get_tic6x_dynamic_type (type);
- break;
- case EM_ALTERA_NIOS2:
- result = get_nios2_dynamic_type (type);
- break;
- case EM_RISCV:
- result = get_riscv_dynamic_type (type);
- break;
- case EM_X86_64:
- result = get_x86_64_dynamic_type (type);
- break;
- default:
- if (filedata->file_header.e_ident[EI_OSABI] == ELFOSABI_SOLARIS)
- result = get_solaris_dynamic_type (type);
- else
- result = NULL;
- break;
- }
-
- if (result != NULL)
- return result;
-
- snprintf (buff, sizeof (buff), _("Processor Specific: %lx"), type);
- }
- else if (((type >= DT_LOOS) && (type <= DT_HIOS))
- || (filedata->file_header.e_machine == EM_PARISC
- && (type >= OLD_DT_LOOS) && (type <= OLD_DT_HIOS)))
- {
- const char * result;
-
- switch (filedata->file_header.e_machine)
- {
- case EM_PARISC:
- result = get_parisc_dynamic_type (type);
- break;
- case EM_IA_64:
- result = get_ia64_dynamic_type (type);
- break;
- default:
- if (filedata->file_header.e_ident[EI_OSABI] == ELFOSABI_SOLARIS)
- result = get_solaris_dynamic_type (type);
- else
- result = NULL;
- break;
- }
-
- if (result != NULL)
- return result;
-
- snprintf (buff, sizeof (buff), _("Operating System specific: %lx"),
- type);
- }
- else
- snprintf (buff, sizeof (buff), _("<unknown>: %lx"), type);
-
- return buff;
- }
-}
-
-static bool get_program_headers (Filedata *);
-static bool get_dynamic_section (Filedata *);
-
-static void
-locate_dynamic_section (Filedata *filedata)
-{
- uint64_t dynamic_addr = 0;
- uint64_t dynamic_size = 0;
-
- if (filedata->file_header.e_phnum != 0
- && get_program_headers (filedata))
- {
- Elf_Internal_Phdr *segment;
- unsigned int i;
-
- for (i = 0, segment = filedata->program_headers;
- i < filedata->file_header.e_phnum;
- i++, segment++)
- {
- if (segment->p_type == PT_DYNAMIC)
- {
- dynamic_addr = segment->p_offset;
- dynamic_size = segment->p_filesz;
-
- if (filedata->section_headers != NULL)
- {
- Elf_Internal_Shdr *sec;
-
- sec = find_section (filedata, ".dynamic");
- if (sec != NULL)
- {
- if (sec->sh_size == 0
- || sec->sh_type == SHT_NOBITS)
- {
- dynamic_addr = 0;
- dynamic_size = 0;
- }
- else
- {
- dynamic_addr = sec->sh_offset;
- dynamic_size = sec->sh_size;
- }
- }
- }
-
- if (dynamic_addr > filedata->file_size
- || (dynamic_size > filedata->file_size - dynamic_addr))
- {
- dynamic_addr = 0;
- dynamic_size = 0;
- }
- break;
- }
- }
- }
- filedata->dynamic_addr = dynamic_addr;
- filedata->dynamic_size = dynamic_size ? dynamic_size : 1;
-}
-
-static bool
-is_pie (Filedata *filedata)
-{
- Elf_Internal_Dyn *entry;
-
- if (filedata->dynamic_size == 0)
- locate_dynamic_section (filedata);
- if (filedata->dynamic_size <= 1)
- return false;
-
- if (!get_dynamic_section (filedata))
- return false;
-
- for (entry = filedata->dynamic_section;
- entry < filedata->dynamic_section + filedata->dynamic_nent;
- entry++)
- {
- if (entry->d_tag == DT_FLAGS_1)
- {
- if ((entry->d_un.d_val & DF_1_PIE) != 0)
- return true;
- break;
- }
- }
- return false;
-}
-
-static char *
-get_file_type (Filedata *filedata)
-{
- unsigned e_type = filedata->file_header.e_type;
- static char buff[64];
-
- switch (e_type)
- {
- case ET_NONE: return _("NONE (None)");
- case ET_REL: return _("REL (Relocatable file)");
- case ET_EXEC: return _("EXEC (Executable file)");
- case ET_DYN:
- if (is_pie (filedata))
- return _("DYN (Position-Independent Executable file)");
- else
- return _("DYN (Shared object file)");
- case ET_CORE: return _("CORE (Core file)");
-
- default:
- if ((e_type >= ET_LOPROC) && (e_type <= ET_HIPROC))
- snprintf (buff, sizeof (buff), _("Processor Specific: (%x)"), e_type);
- else if ((e_type >= ET_LOOS) && (e_type <= ET_HIOS))
- snprintf (buff, sizeof (buff), _("OS Specific: (%x)"), e_type);
- else
- snprintf (buff, sizeof (buff), _("<unknown>: %x"), e_type);
- return buff;
- }
-}
-
-static char *
-get_machine_name (unsigned e_machine)
-{
- static char buff[64]; /* XXX */
-
- switch (e_machine)
- {
- /* Please keep this switch table sorted by increasing EM_ value. */
- /* 0 */
- case EM_NONE: return _("None");
- case EM_M32: return "WE32100";
- case EM_SPARC: return "Sparc";
- case EM_386: return "Intel 80386";
- case EM_68K: return "MC68000";
- case EM_88K: return "MC88000";
- case EM_IAMCU: return "Intel MCU";
- case EM_860: return "Intel 80860";
- case EM_MIPS: return "MIPS R3000";
- case EM_S370: return "IBM System/370";
- /* 10 */
- case EM_MIPS_RS3_LE: return "MIPS R4000 big-endian";
- case EM_OLD_SPARCV9: return "Sparc v9 (old)";
- case EM_PARISC: return "HPPA";
- case EM_VPP550: return "Fujitsu VPP500";
- case EM_SPARC32PLUS: return "Sparc v8+" ;
- case EM_960: return "Intel 80960";
- case EM_PPC: return "PowerPC";
- /* 20 */
- case EM_PPC64: return "PowerPC64";
- case EM_S390_OLD:
- case EM_S390: return "IBM S/390";
- case EM_SPU: return "SPU";
- /* 30 */
- case EM_V800: return "Renesas V850 (using RH850 ABI)";
- case EM_FR20: return "Fujitsu FR20";
- case EM_RH32: return "TRW RH32";
- case EM_MCORE: return "MCORE";
- /* 40 */
- case EM_ARM: return "ARM";
- case EM_OLD_ALPHA: return "Digital Alpha (old)";
- case EM_SH: return "Renesas / SuperH SH";
- case EM_SPARCV9: return "Sparc v9";
- case EM_TRICORE: return "Siemens Tricore";
- case EM_ARC: return "ARC";
- case EM_H8_300: return "Renesas H8/300";
- case EM_H8_300H: return "Renesas H8/300H";
- case EM_H8S: return "Renesas H8S";
- case EM_H8_500: return "Renesas H8/500";
- /* 50 */
- case EM_IA_64: return "Intel IA-64";
- case EM_MIPS_X: return "Stanford MIPS-X";
- case EM_COLDFIRE: return "Motorola Coldfire";
- case EM_68HC12: return "Motorola MC68HC12 Microcontroller";
- case EM_MMA: return "Fujitsu Multimedia Accelerator";
- case EM_PCP: return "Siemens PCP";
- case EM_NCPU: return "Sony nCPU embedded RISC processor";
- case EM_NDR1: return "Denso NDR1 microprocessor";
- case EM_STARCORE: return "Motorola Star*Core processor";
- case EM_ME16: return "Toyota ME16 processor";
- /* 60 */
- case EM_ST100: return "STMicroelectronics ST100 processor";
- case EM_TINYJ: return "Advanced Logic Corp. TinyJ embedded processor";
- case EM_X86_64: return "Advanced Micro Devices X86-64";
- case EM_PDSP: return "Sony DSP processor";
- case EM_PDP10: return "Digital Equipment Corp. PDP-10";
- case EM_PDP11: return "Digital Equipment Corp. PDP-11";
- case EM_FX66: return "Siemens FX66 microcontroller";
- case EM_ST9PLUS: return "STMicroelectronics ST9+ 8/16 bit microcontroller";
- case EM_ST7: return "STMicroelectronics ST7 8-bit microcontroller";
- case EM_68HC16: return "Motorola MC68HC16 Microcontroller";
- /* 70 */
- case EM_68HC11: return "Motorola MC68HC11 Microcontroller";
- case EM_68HC08: return "Motorola MC68HC08 Microcontroller";
- case EM_68HC05: return "Motorola MC68HC05 Microcontroller";
- case EM_SVX: return "Silicon Graphics SVx";
- case EM_ST19: return "STMicroelectronics ST19 8-bit microcontroller";
- case EM_VAX: return "Digital VAX";
- case EM_CRIS: return "Axis Communications 32-bit embedded processor";
- case EM_JAVELIN: return "Infineon Technologies 32-bit embedded cpu";
- case EM_FIREPATH: return "Element 14 64-bit DSP processor";
- case EM_ZSP: return "LSI Logic's 16-bit DSP processor";
- /* 80 */
- case EM_MMIX: return "Donald Knuth's educational 64-bit processor";
- case EM_HUANY: return "Harvard Universitys's machine-independent object format";
- case EM_PRISM: return "Vitesse Prism";
- case EM_AVR_OLD:
- case EM_AVR: return "Atmel AVR 8-bit microcontroller";
- case EM_CYGNUS_FR30:
- case EM_FR30: return "Fujitsu FR30";
- case EM_CYGNUS_D10V:
- case EM_D10V: return "d10v";
- case EM_CYGNUS_D30V:
- case EM_D30V: return "d30v";
- case EM_CYGNUS_V850:
- case EM_V850: return "Renesas V850";
- case EM_CYGNUS_M32R:
- case EM_M32R: return "Renesas M32R (formerly Mitsubishi M32r)";
- case EM_CYGNUS_MN10300:
- case EM_MN10300: return "mn10300";
- /* 90 */
- case EM_CYGNUS_MN10200:
- case EM_MN10200: return "mn10200";
- case EM_PJ: return "picoJava";
- case EM_OR1K: return "OpenRISC 1000";
- case EM_ARC_COMPACT: return "ARCompact";
- case EM_XTENSA_OLD:
- case EM_XTENSA: return "Tensilica Xtensa Processor";
- case EM_VIDEOCORE: return "Alphamosaic VideoCore processor";
- case EM_TMM_GPP: return "Thompson Multimedia General Purpose Processor";
- case EM_NS32K: return "National Semiconductor 32000 series";
- case EM_TPC: return "Tenor Network TPC processor";
- case EM_SNP1K: return "Trebia SNP 1000 processor";
- /* 100 */
- case EM_ST200: return "STMicroelectronics ST200 microcontroller";
- case EM_IP2K_OLD:
- case EM_IP2K: return "Ubicom IP2xxx 8-bit microcontrollers";
- case EM_MAX: return "MAX Processor";
- case EM_CR: return "National Semiconductor CompactRISC";
- case EM_F2MC16: return "Fujitsu F2MC16";
- case EM_MSP430: return "Texas Instruments msp430 microcontroller";
- case EM_BLACKFIN: return "Analog Devices Blackfin";
- case EM_SE_C33: return "S1C33 Family of Seiko Epson processors";
- case EM_SEP: return "Sharp embedded microprocessor";
- case EM_ARCA: return "Arca RISC microprocessor";
- /* 110 */
- case EM_UNICORE: return "Unicore";
- case EM_EXCESS: return "eXcess 16/32/64-bit configurable embedded CPU";
- case EM_DXP: return "Icera Semiconductor Inc. Deep Execution Processor";
- case EM_ALTERA_NIOS2: return "Altera Nios II";
- case EM_CRX: return "National Semiconductor CRX microprocessor";
- case EM_XGATE: return "Motorola XGATE embedded processor";
- case EM_C166:
- case EM_XC16X: return "Infineon Technologies xc16x";
- case EM_M16C: return "Renesas M16C series microprocessors";
- case EM_DSPIC30F: return "Microchip Technology dsPIC30F Digital Signal Controller";
- case EM_CE: return "Freescale Communication Engine RISC core";
- /* 120 */
- case EM_M32C: return "Renesas M32c";
- /* 130 */
- case EM_TSK3000: return "Altium TSK3000 core";
- case EM_RS08: return "Freescale RS08 embedded processor";
- case EM_ECOG2: return "Cyan Technology eCOG2 microprocessor";
- case EM_SCORE: return "SUNPLUS S+Core";
- case EM_DSP24: return "New Japan Radio (NJR) 24-bit DSP Processor";
- case EM_VIDEOCORE3: return "Broadcom VideoCore III processor";
- case EM_LATTICEMICO32: return "Lattice Mico32";
- case EM_SE_C17: return "Seiko Epson C17 family";
- /* 140 */
- case EM_TI_C6000: return "Texas Instruments TMS320C6000 DSP family";
- case EM_TI_C2000: return "Texas Instruments TMS320C2000 DSP family";
- case EM_TI_C5500: return "Texas Instruments TMS320C55x DSP family";
- case EM_TI_PRU: return "TI PRU I/O processor";
- /* 160 */
- case EM_MMDSP_PLUS: return "STMicroelectronics 64bit VLIW Data Signal Processor";
- case EM_CYPRESS_M8C: return "Cypress M8C microprocessor";
- case EM_R32C: return "Renesas R32C series microprocessors";
- case EM_TRIMEDIA: return "NXP Semiconductors TriMedia architecture family";
- case EM_QDSP6: return "QUALCOMM DSP6 Processor";
- case EM_8051: return "Intel 8051 and variants";
- case EM_STXP7X: return "STMicroelectronics STxP7x family";
- case EM_NDS32: return "Andes Technology compact code size embedded RISC processor family";
- case EM_ECOG1X: return "Cyan Technology eCOG1X family";
- case EM_MAXQ30: return "Dallas Semiconductor MAXQ30 Core microcontrollers";
- /* 170 */
- case EM_XIMO16: return "New Japan Radio (NJR) 16-bit DSP Processor";
- case EM_MANIK: return "M2000 Reconfigurable RISC Microprocessor";
- case EM_CRAYNV2: return "Cray Inc. NV2 vector architecture";
- case EM_RX: return "Renesas RX";
- case EM_METAG: return "Imagination Technologies Meta processor architecture";
- case EM_MCST_ELBRUS: return "MCST Elbrus general purpose hardware architecture";
- case EM_ECOG16: return "Cyan Technology eCOG16 family";
- case EM_CR16:
- case EM_MICROBLAZE:
- case EM_MICROBLAZE_OLD: return "Xilinx MicroBlaze";
- case EM_ETPU: return "Freescale Extended Time Processing Unit";
- case EM_SLE9X: return "Infineon Technologies SLE9X core";
- /* 180 */
- case EM_L1OM: return "Intel L1OM";
- case EM_K1OM: return "Intel K1OM";
- case EM_INTEL182: return "Intel (reserved)";
- case EM_AARCH64: return "AArch64";
- case EM_ARM184: return "ARM (reserved)";
- case EM_AVR32: return "Atmel Corporation 32-bit microprocessor";
- case EM_STM8: return "STMicroeletronics STM8 8-bit microcontroller";
- case EM_TILE64: return "Tilera TILE64 multicore architecture family";
- case EM_TILEPRO: return "Tilera TILEPro multicore architecture family";
- /* 190 */
- case EM_CUDA: return "NVIDIA CUDA architecture";
- case EM_TILEGX: return "Tilera TILE-Gx multicore architecture family";
- case EM_CLOUDSHIELD: return "CloudShield architecture family";
- case EM_COREA_1ST: return "KIPO-KAIST Core-A 1st generation processor family";
- case EM_COREA_2ND: return "KIPO-KAIST Core-A 2nd generation processor family";
- case EM_ARC_COMPACT2: return "ARCv2";
- case EM_OPEN8: return "Open8 8-bit RISC soft processor core";
- case EM_RL78: return "Renesas RL78";
- case EM_VIDEOCORE5: return "Broadcom VideoCore V processor";
- case EM_78K0R: return "Renesas 78K0R";
- /* 200 */
- case EM_56800EX: return "Freescale 56800EX Digital Signal Controller (DSC)";
- case EM_BA1: return "Beyond BA1 CPU architecture";
- case EM_BA2: return "Beyond BA2 CPU architecture";
- case EM_XCORE: return "XMOS xCORE processor family";
- case EM_MCHP_PIC: return "Microchip 8-bit PIC(r) family";
- case EM_INTELGT: return "Intel Graphics Technology";
- /* 210 */
- case EM_KM32: return "KM211 KM32 32-bit processor";
- case EM_KMX32: return "KM211 KMX32 32-bit processor";
- case EM_KMX16: return "KM211 KMX16 16-bit processor";
- case EM_KMX8: return "KM211 KMX8 8-bit processor";
- case EM_KVARC: return "KM211 KVARC processor";
- case EM_CDP: return "Paneve CDP architecture family";
- case EM_COGE: return "Cognitive Smart Memory Processor";
- case EM_COOL: return "Bluechip Systems CoolEngine";
- case EM_NORC: return "Nanoradio Optimized RISC";
- case EM_CSR_KALIMBA: return "CSR Kalimba architecture family";
- /* 220 */
- case EM_Z80: return "Zilog Z80";
- case EM_VISIUM: return "CDS VISIUMcore processor";
- case EM_FT32: return "FTDI Chip FT32";
- case EM_MOXIE: return "Moxie";
- case EM_AMDGPU: return "AMD GPU";
- /* 230 (all reserved) */
- /* 240 */
- case EM_RISCV: return "RISC-V";
- case EM_LANAI: return "Lanai 32-bit processor";
- case EM_CEVA: return "CEVA Processor Architecture Family";
- case EM_CEVA_X2: return "CEVA X2 Processor Family";
- case EM_BPF: return "Linux BPF";
- case EM_GRAPHCORE_IPU: return "Graphcore Intelligent Processing Unit";
- case EM_IMG1: return "Imagination Technologies";
- /* 250 */
- case EM_NFP: return "Netronome Flow Processor";
- case EM_VE: return "NEC Vector Engine";
- case EM_CSKY: return "C-SKY";
- case EM_ARC_COMPACT3_64: return "Synopsys ARCv3 64-bit processor";
- case EM_MCS6502: return "MOS Technology MCS 6502 processor";
- case EM_ARC_COMPACT3: return "Synopsys ARCv3 32-bit processor";
- case EM_KVX: return "Kalray VLIW core of the MPPA processor family";
- case EM_65816: return "WDC 65816/65C816";
- case EM_LOONGARCH: return "LoongArch";
- case EM_KF32: return "ChipON KungFu32";
-
- /* Large numbers... */
- case EM_MT: return "Morpho Techologies MT processor";
- case EM_ALPHA: return "Alpha";
- case EM_WEBASSEMBLY: return "Web Assembly";
- case EM_DLX: return "OpenDLX";
- case EM_XSTORMY16: return "Sanyo XStormy16 CPU core";
- case EM_IQ2000: return "Vitesse IQ2000";
- case EM_M32C_OLD:
- case EM_NIOS32: return "Altera Nios";
- case EM_CYGNUS_MEP: return "Toshiba MeP Media Engine";
- case EM_ADAPTEVA_EPIPHANY: return "Adapteva EPIPHANY";
- case EM_CYGNUS_FRV: return "Fujitsu FR-V";
- case EM_S12Z: return "Freescale S12Z";
-
- default:
- snprintf (buff, sizeof (buff), _("<unknown>: 0x%x"), e_machine);
- return buff;
- }
-}
-
-static char *
-decode_ARC_machine_flags (char *out, unsigned e_flags, unsigned e_machine)
-{
- /* ARC has two machine types EM_ARC_COMPACT and EM_ARC_COMPACT2. Some
- other compilers don't specify an architecture type in the e_flags, and
- instead use EM_ARC_COMPACT for old ARC600, ARC601, and ARC700
- architectures, and switch to EM_ARC_COMPACT2 for newer ARCEM and ARCHS
- architectures.
-
- Th GNU tools follows this use of EM_ARC_COMPACT and EM_ARC_COMPACT2,
- but also sets a specific architecture type in the e_flags field.
-
- However, when decoding the flags we don't worry if we see an
- unexpected pairing, for example EM_ARC_COMPACT machine type, with
- ARCEM architecture type. */
-
- switch (e_flags & EF_ARC_MACH_MSK)
- {
- /* We only expect these to occur for EM_ARC_COMPACT2. */
- case EF_ARC_CPU_ARCV2EM:
- out = stpcpy (out, ", ARC EM");
- break;
- case EF_ARC_CPU_ARCV2HS:
- out = stpcpy (out, ", ARC HS");
- break;
-
- /* We only expect these to occur for EM_ARC_COMPACT. */
- case E_ARC_MACH_ARC600:
- out = stpcpy (out, ", ARC600");
- break;
- case E_ARC_MACH_ARC601:
- out = stpcpy (out, ", ARC601");
- break;
- case E_ARC_MACH_ARC700:
- out = stpcpy (out, ", ARC700");
- break;
-
- /* The only times we should end up here are (a) A corrupt ELF, (b) A
- new ELF with new architecture being read by an old version of
- readelf, or (c) An ELF built with non-GNU compiler that does not
- set the architecture in the e_flags. */
- default:
- if (e_machine == EM_ARC_COMPACT)
- out = stpcpy (out, ", Unknown ARCompact");
- else
- out = stpcpy (out, ", Unknown ARC");
- break;
- }
-
- switch (e_flags & EF_ARC_OSABI_MSK)
- {
- case E_ARC_OSABI_ORIG:
- out = stpcpy (out, ", (ABI:legacy)");
- break;
- case E_ARC_OSABI_V2:
- out = stpcpy (out, ", (ABI:v2)");
- break;
- /* Only upstream 3.9+ kernels will support ARCv2 ISA. */
- case E_ARC_OSABI_V3:
- out = stpcpy (out, ", v3 no-legacy-syscalls ABI");
- break;
- case E_ARC_OSABI_V4:
- out = stpcpy (out, ", v4 ABI");
- break;
- default:
- out = stpcpy (out, ", unrecognised ARC OSABI flag");
- break;
- }
- return out;
-}
-
-static char *
-decode_ARM_machine_flags (char *out, unsigned e_flags)
-{
- unsigned eabi;
- bool unknown = false;
-
- eabi = EF_ARM_EABI_VERSION (e_flags);
- e_flags &= ~ EF_ARM_EABIMASK;
-
- /* Handle "generic" ARM flags. */
- if (e_flags & EF_ARM_RELEXEC)
- {
- out = stpcpy (out, ", relocatable executable");
- e_flags &= ~ EF_ARM_RELEXEC;
- }
-
- if (e_flags & EF_ARM_PIC)
- {
- out = stpcpy (out, ", position independent");
- e_flags &= ~ EF_ARM_PIC;
- }
-
- /* Now handle EABI specific flags. */
- switch (eabi)
- {
- default:
- out = stpcpy (out, ", <unrecognized EABI>");
- if (e_flags)
- unknown = true;
- break;
-
- case EF_ARM_EABI_VER1:
- out = stpcpy (out, ", Version1 EABI");
- while (e_flags)
- {
- unsigned flag;
-
- /* Process flags one bit at a time. */
- flag = e_flags & - e_flags;
- e_flags &= ~ flag;
-
- switch (flag)
- {
- case EF_ARM_SYMSARESORTED: /* Conflicts with EF_ARM_INTERWORK. */
- out = stpcpy (out, ", sorted symbol tables");
- break;
-
- default:
- unknown = true;
- break;
- }
- }
- break;
-
- case EF_ARM_EABI_VER2:
- out = stpcpy (out, ", Version2 EABI");
- while (e_flags)
- {
- unsigned flag;
-
- /* Process flags one bit at a time. */
- flag = e_flags & - e_flags;
- e_flags &= ~ flag;
-
- switch (flag)
- {
- case EF_ARM_SYMSARESORTED: /* Conflicts with EF_ARM_INTERWORK. */
- out = stpcpy (out, ", sorted symbol tables");
- break;
-
- case EF_ARM_DYNSYMSUSESEGIDX:
- out = stpcpy (out, ", dynamic symbols use segment index");
- break;
-
- case EF_ARM_MAPSYMSFIRST:
- out = stpcpy (out, ", mapping symbols precede others");
- break;
-
- default:
- unknown = true;
- break;
- }
- }
- break;
-
- case EF_ARM_EABI_VER3:
- out = stpcpy (out, ", Version3 EABI");
- break;
-
- case EF_ARM_EABI_VER4:
- out = stpcpy (out, ", Version4 EABI");
- while (e_flags)
- {
- unsigned flag;
-
- /* Process flags one bit at a time. */
- flag = e_flags & - e_flags;
- e_flags &= ~ flag;
-
- switch (flag)
- {
- case EF_ARM_BE8:
- out = stpcpy (out, ", BE8");
- break;
-
- case EF_ARM_LE8:
- out = stpcpy (out, ", LE8");
- break;
-
- default:
- unknown = true;
- break;
- }
- }
- break;
-
- case EF_ARM_EABI_VER5:
- out = stpcpy (out, ", Version5 EABI");
- while (e_flags)
- {
- unsigned flag;
-
- /* Process flags one bit at a time. */
- flag = e_flags & - e_flags;
- e_flags &= ~ flag;
-
- switch (flag)
- {
- case EF_ARM_BE8:
- out = stpcpy (out, ", BE8");
- break;
-
- case EF_ARM_LE8:
- out = stpcpy (out, ", LE8");
- break;
-
- case EF_ARM_ABI_FLOAT_SOFT: /* Conflicts with EF_ARM_SOFT_FLOAT. */
- out = stpcpy (out, ", soft-float ABI");
- break;
-
- case EF_ARM_ABI_FLOAT_HARD: /* Conflicts with EF_ARM_VFP_FLOAT. */
- out = stpcpy (out, ", hard-float ABI");
- break;
-
- default:
- unknown = true;
- break;
- }
- }
- break;
-
- case EF_ARM_EABI_UNKNOWN:
- out = stpcpy (out, ", GNU EABI");
- while (e_flags)
- {
- unsigned flag;
-
- /* Process flags one bit at a time. */
- flag = e_flags & - e_flags;
- e_flags &= ~ flag;
-
- switch (flag)
- {
- case EF_ARM_INTERWORK:
- out = stpcpy (out, ", interworking enabled");
- break;
-
- case EF_ARM_APCS_26:
- out = stpcpy (out, ", uses APCS/26");
- break;
-
- case EF_ARM_APCS_FLOAT:
- out = stpcpy (out, ", uses APCS/float");
- break;
-
- case EF_ARM_PIC:
- out = stpcpy (out, ", position independent");
- break;
-
- case EF_ARM_ALIGN8:
- out = stpcpy (out, ", 8 bit structure alignment");
- break;
-
- case EF_ARM_NEW_ABI:
- out = stpcpy (out, ", uses new ABI");
- break;
-
- case EF_ARM_OLD_ABI:
- out = stpcpy (out, ", uses old ABI");
- break;
-
- case EF_ARM_SOFT_FLOAT:
- out = stpcpy (out, ", software FP");
- break;
-
- case EF_ARM_VFP_FLOAT:
- out = stpcpy (out, ", VFP");
- break;
-
- default:
- unknown = true;
- break;
- }
- }
- }
-
- if (unknown)
- out = stpcpy (out,_(", <unknown>"));
- return out;
-}
-
-static char *
-decode_AVR_machine_flags (char *out, unsigned e_flags)
-{
- switch (e_flags & EF_AVR_MACH)
- {
- case E_AVR_MACH_AVR1:
- out = stpcpy (out, ", avr:1");
- break;
- case E_AVR_MACH_AVR2:
- out = stpcpy (out, ", avr:2");
- break;
- case E_AVR_MACH_AVR25:
- out = stpcpy (out, ", avr:25");
- break;
- case E_AVR_MACH_AVR3:
- out = stpcpy (out, ", avr:3");
- break;
- case E_AVR_MACH_AVR31:
- out = stpcpy (out, ", avr:31");
- break;
- case E_AVR_MACH_AVR35:
- out = stpcpy (out, ", avr:35");
- break;
- case E_AVR_MACH_AVR4:
- out = stpcpy (out, ", avr:4");
- break;
- case E_AVR_MACH_AVR5:
- out = stpcpy (out, ", avr:5");
- break;
- case E_AVR_MACH_AVR51:
- out = stpcpy (out, ", avr:51");
- break;
- case E_AVR_MACH_AVR6:
- out = stpcpy (out, ", avr:6");
- break;
- case E_AVR_MACH_AVRTINY:
- out = stpcpy (out, ", avr:100");
- break;
- case E_AVR_MACH_XMEGA1:
- out = stpcpy (out, ", avr:101");
- break;
- case E_AVR_MACH_XMEGA2:
- out = stpcpy (out, ", avr:102");
- break;
- case E_AVR_MACH_XMEGA3:
- out = stpcpy (out, ", avr:103");
- break;
- case E_AVR_MACH_XMEGA4:
- out = stpcpy (out, ", avr:104");
- break;
- case E_AVR_MACH_XMEGA5:
- out = stpcpy (out, ", avr:105");
- break;
- case E_AVR_MACH_XMEGA6:
- out = stpcpy (out, ", avr:106");
- break;
- case E_AVR_MACH_XMEGA7:
- out = stpcpy (out, ", avr:107");
- break;
- default:
- out = stpcpy (out, ", avr:<unknown>");
- break;
- }
-
- if (e_flags & EF_AVR_LINKRELAX_PREPARED)
- out = stpcpy (out, ", link-relax");
- return out;
-}
-
-static char *
-decode_BLACKFIN_machine_flags (char *out, unsigned e_flags)
-{
- if (e_flags & EF_BFIN_PIC)
- out = stpcpy (out, ", PIC");
-
- if (e_flags & EF_BFIN_FDPIC)
- out = stpcpy (out, ", FDPIC");
-
- if (e_flags & EF_BFIN_CODE_IN_L1)
- out = stpcpy (out, ", code in L1");
-
- if (e_flags & EF_BFIN_DATA_IN_L1)
- out = stpcpy (out, ", data in L1");
- return out;
-}
-
-static char *
-decode_FRV_machine_flags (char *out, unsigned e_flags)
-{
- switch (e_flags & EF_FRV_CPU_MASK)
- {
- case EF_FRV_CPU_GENERIC:
- break;
-
- default:
- out = stpcpy (out, ", fr???");
- break;
-
- case EF_FRV_CPU_FR300:
- out = stpcpy (out, ", fr300");
- break;
-
- case EF_FRV_CPU_FR400:
- out = stpcpy (out, ", fr400");
- break;
- case EF_FRV_CPU_FR405:
- out = stpcpy (out, ", fr405");
- break;
-
- case EF_FRV_CPU_FR450:
- out = stpcpy (out, ", fr450");
- break;
-
- case EF_FRV_CPU_FR500:
- out = stpcpy (out, ", fr500");
- break;
- case EF_FRV_CPU_FR550:
- out = stpcpy (out, ", fr550");
- break;
-
- case EF_FRV_CPU_SIMPLE:
- out = stpcpy (out, ", simple");
- break;
- case EF_FRV_CPU_TOMCAT:
- out = stpcpy (out, ", tomcat");
- break;
- }
- return out;
-}
-
-static char *
-decode_IA64_machine_flags (char *out, unsigned e_flags, Filedata *filedata)
-{
- if ((e_flags & EF_IA_64_ABI64))
- out = stpcpy (out, ", 64-bit");
- else
- out = stpcpy (out, ", 32-bit");
- if ((e_flags & EF_IA_64_REDUCEDFP))
- out = stpcpy (out, ", reduced fp model");
- if ((e_flags & EF_IA_64_NOFUNCDESC_CONS_GP))
- out = stpcpy (out, ", no function descriptors, constant gp");
- else if ((e_flags & EF_IA_64_CONS_GP))
- out = stpcpy (out, ", constant gp");
- if ((e_flags & EF_IA_64_ABSOLUTE))
- out = stpcpy (out, ", absolute");
- if (filedata->file_header.e_ident[EI_OSABI] == ELFOSABI_OPENVMS)
- {
- if ((e_flags & EF_IA_64_VMS_LINKAGES))
- out = stpcpy (out, ", vms_linkages");
- switch ((e_flags & EF_IA_64_VMS_COMCOD))
- {
- case EF_IA_64_VMS_COMCOD_SUCCESS:
- break;
- case EF_IA_64_VMS_COMCOD_WARNING:
- out = stpcpy (out, ", warning");
- break;
- case EF_IA_64_VMS_COMCOD_ERROR:
- out = stpcpy (out, ", error");
- break;
- case EF_IA_64_VMS_COMCOD_ABORT:
- out = stpcpy (out, ", abort");
- break;
- default:
- warn (_("Unrecognised IA64 VMS Command Code: %x\n"),
- e_flags & EF_IA_64_VMS_COMCOD);
- out = stpcpy (out, ", <unknown>");
- }
- }
- return out;
-}
-
-static char *
-decode_LOONGARCH_machine_flags (char *out, unsigned int e_flags)
-{
- if (EF_LOONGARCH_IS_SOFT_FLOAT (e_flags))
- out = stpcpy (out, ", SOFT-FLOAT");
- else if (EF_LOONGARCH_IS_SINGLE_FLOAT (e_flags))
- out = stpcpy (out, ", SINGLE-FLOAT");
- else if (EF_LOONGARCH_IS_DOUBLE_FLOAT (e_flags))
- out = stpcpy (out, ", DOUBLE-FLOAT");
-
- if (EF_LOONGARCH_IS_OBJ_V0 (e_flags))
- out = stpcpy (out, ", OBJ-v0");
- else if (EF_LOONGARCH_IS_OBJ_V1 (e_flags))
- out = stpcpy (out, ", OBJ-v1");
- return out;
-}
-
-static char *
-decode_M68K_machine_flags (char *out, unsigned int e_flags)
-{
- if ((e_flags & EF_M68K_ARCH_MASK) == EF_M68K_M68000)
- out = stpcpy (out, ", m68000");
- else if ((e_flags & EF_M68K_ARCH_MASK) == EF_M68K_CPU32)
- out = stpcpy (out, ", cpu32");
- else if ((e_flags & EF_M68K_ARCH_MASK) == EF_M68K_FIDO)
- out = stpcpy (out, ", fido_a");
- else
- {
- char const *isa = _("unknown");
- char const *mac = _("unknown mac");
- char const *additional = NULL;
-
- switch (e_flags & EF_M68K_CF_ISA_MASK)
- {
- case EF_M68K_CF_ISA_A_NODIV:
- isa = "A";
- additional = ", nodiv";
- break;
- case EF_M68K_CF_ISA_A:
- isa = "A";
- break;
- case EF_M68K_CF_ISA_A_PLUS:
- isa = "A+";
- break;
- case EF_M68K_CF_ISA_B_NOUSP:
- isa = "B";
- additional = ", nousp";
- break;
- case EF_M68K_CF_ISA_B:
- isa = "B";
- break;
- case EF_M68K_CF_ISA_C:
- isa = "C";
- break;
- case EF_M68K_CF_ISA_C_NODIV:
- isa = "C";
- additional = ", nodiv";
- break;
- }
- out = stpcpy (out, ", cf, isa ");
- out = stpcpy (out, isa);
- if (additional)
- out = stpcpy (out, additional);
- if (e_flags & EF_M68K_CF_FLOAT)
- out = stpcpy (out, ", float");
- switch (e_flags & EF_M68K_CF_MAC_MASK)
- {
- case 0:
- mac = NULL;
- break;
- case EF_M68K_CF_MAC:
- mac = "mac";
- break;
- case EF_M68K_CF_EMAC:
- mac = "emac";
- break;
- case EF_M68K_CF_EMAC_B:
- mac = "emac_b";
- break;
- }
- if (mac)
- {
- out = stpcpy (out, ", ");
- out = stpcpy (out, mac);
- }
- }
- return out;
-}
-
-static char *
-decode_MeP_machine_flags (char *out, unsigned int e_flags)
-{
- switch (e_flags & EF_MEP_CPU_MASK)
- {
- case EF_MEP_CPU_MEP:
- out = stpcpy (out, ", generic MeP");
- break;
- case EF_MEP_CPU_C2:
- out = stpcpy (out, ", MeP C2");
- break;
- case EF_MEP_CPU_C3:
- out = stpcpy (out, ", MeP C3");
- break;
- case EF_MEP_CPU_C4:
- out = stpcpy (out, ", MeP C4");
- break;
- case EF_MEP_CPU_C5:
- out = stpcpy (out, ", MeP C5");
- break;
- case EF_MEP_CPU_H1:
- out = stpcpy (out, ", MeP H1");
- break;
- default:
- out = stpcpy (out, _(", <unknown MeP cpu type>"));
- break;
- }
-
- switch (e_flags & EF_MEP_COP_MASK)
- {
- case EF_MEP_COP_NONE:
- break;
- case EF_MEP_COP_AVC:
- out = stpcpy (out, ", AVC coprocessor");
- break;
- case EF_MEP_COP_AVC2:
- out = stpcpy (out, ", AVC2 coprocessor");
- break;
- case EF_MEP_COP_FMAX:
- out = stpcpy (out, ", FMAX coprocessor");
- break;
- case EF_MEP_COP_IVC2:
- out = stpcpy (out, ", IVC2 coprocessor");
- break;
- default:
- out = stpcpy (out, _("<unknown MeP copro type>"));
- break;
- }
-
- if (e_flags & EF_MEP_LIBRARY)
- out = stpcpy (out, ", Built for Library");
-
- if (e_flags & EF_MEP_INDEX_MASK)
- out += sprintf (out, ", Configuration Index: %#x",
- e_flags & EF_MEP_INDEX_MASK);
-
- if (e_flags & ~ EF_MEP_ALL_FLAGS)
- out += sprintf (out, _(", unknown flags bits: %#x"),
- e_flags & ~ EF_MEP_ALL_FLAGS);
- return out;
-}
-
-static char *
-decode_MIPS_machine_flags (char *out, unsigned int e_flags)
-{
- if (e_flags & EF_MIPS_NOREORDER)
- out = stpcpy (out, ", noreorder");
-
- if (e_flags & EF_MIPS_PIC)
- out = stpcpy (out, ", pic");
-
- if (e_flags & EF_MIPS_CPIC)
- out = stpcpy (out, ", cpic");
-
- if (e_flags & EF_MIPS_UCODE)
- out = stpcpy (out, ", ugen_reserved");
-
- if (e_flags & EF_MIPS_ABI2)
- out = stpcpy (out, ", abi2");
-
- if (e_flags & EF_MIPS_OPTIONS_FIRST)
- out = stpcpy (out, ", odk first");
-
- if (e_flags & EF_MIPS_32BITMODE)
- out = stpcpy (out, ", 32bitmode");
-
- if (e_flags & EF_MIPS_NAN2008)
- out = stpcpy (out, ", nan2008");
-
- if (e_flags & EF_MIPS_FP64)
- out = stpcpy (out, ", fp64");
-
- switch ((e_flags & EF_MIPS_MACH))
- {
- case EF_MIPS_MACH_3900:
- out = stpcpy (out, ", 3900");
- break;
- case EF_MIPS_MACH_4010:
- out = stpcpy (out, ", 4010");
- break;
- case EF_MIPS_MACH_4100:
- out = stpcpy (out, ", 4100");
- break;
- case EF_MIPS_MACH_4111:
- out = stpcpy (out, ", 4111");
- break;
- case EF_MIPS_MACH_4120:
- out = stpcpy (out, ", 4120");
- break;
- case EF_MIPS_MACH_4650:
- out = stpcpy (out, ", 4650");
- break;
- case EF_MIPS_MACH_5400:
- out = stpcpy (out, ", 5400");
- break;
- case EF_MIPS_MACH_5500:
- out = stpcpy (out, ", 5500");
- break;
- case EF_MIPS_MACH_5900:
- out = stpcpy (out, ", 5900");
- break;
- case EF_MIPS_MACH_SB1:
- out = stpcpy (out, ", sb1");
- break;
- case EF_MIPS_MACH_9000:
- out = stpcpy (out, ", 9000");
- break;
- case EF_MIPS_MACH_LS2E:
- out = stpcpy (out, ", loongson-2e");
- break;
- case EF_MIPS_MACH_LS2F:
- out = stpcpy (out, ", loongson-2f");
- break;
- case EF_MIPS_MACH_GS464:
- out = stpcpy (out, ", gs464");
- break;
- case EF_MIPS_MACH_GS464E:
- out = stpcpy (out, ", gs464e");
- break;
- case EF_MIPS_MACH_GS264E:
- out = stpcpy (out, ", gs264e");
- break;
- case EF_MIPS_MACH_OCTEON:
- out = stpcpy (out, ", octeon");
- break;
- case EF_MIPS_MACH_OCTEON2:
- out = stpcpy (out, ", octeon2");
- break;
- case EF_MIPS_MACH_OCTEON3:
- out = stpcpy (out, ", octeon3");
- break;
- case EF_MIPS_MACH_XLR:
- out = stpcpy (out, ", xlr");
- break;
- case EF_MIPS_MACH_IAMR2:
- out = stpcpy (out, ", interaptiv-mr2");
- break;
- case EF_MIPS_MACH_ALLEGREX:
- out = stpcpy (out, ", allegrex");
- break;
- case 0:
- /* We simply ignore the field in this case to avoid confusion:
- MIPS ELF does not specify EF_MIPS_MACH, it is a GNU
- extension. */
- break;
- default:
- out = stpcpy (out, _(", unknown CPU"));
- break;
- }
-
- switch ((e_flags & EF_MIPS_ABI))
- {
- case EF_MIPS_ABI_O32:
- out = stpcpy (out, ", o32");
- break;
- case EF_MIPS_ABI_O64:
- out = stpcpy (out, ", o64");
- break;
- case EF_MIPS_ABI_EABI32:
- out = stpcpy (out, ", eabi32");
- break;
- case EF_MIPS_ABI_EABI64:
- out = stpcpy (out, ", eabi64");
- break;
- case 0:
- /* We simply ignore the field in this case to avoid confusion:
- MIPS ELF does not specify EF_MIPS_ABI, it is a GNU extension.
- This means it is likely to be an o32 file, but not for
- sure. */
- break;
- default:
- out = stpcpy (out, _(", unknown ABI"));
- break;
- }
-
- if (e_flags & EF_MIPS_ARCH_ASE_MDMX)
- out = stpcpy (out, ", mdmx");
-
- if (e_flags & EF_MIPS_ARCH_ASE_M16)
- out = stpcpy (out, ", mips16");
-
- if (e_flags & EF_MIPS_ARCH_ASE_MICROMIPS)
- out = stpcpy (out, ", micromips");
-
- switch ((e_flags & EF_MIPS_ARCH))
- {
- case EF_MIPS_ARCH_1:
- out = stpcpy (out, ", mips1");
- break;
- case EF_MIPS_ARCH_2:
- out = stpcpy (out, ", mips2");
- break;
- case EF_MIPS_ARCH_3:
- out = stpcpy (out, ", mips3");
- break;
- case EF_MIPS_ARCH_4:
- out = stpcpy (out, ", mips4");
- break;
- case EF_MIPS_ARCH_5:
- out = stpcpy (out, ", mips5");
- break;
- case EF_MIPS_ARCH_32:
- out = stpcpy (out, ", mips32");
- break;
- case EF_MIPS_ARCH_32R2:
- out = stpcpy (out, ", mips32r2");
- break;
- case EF_MIPS_ARCH_32R6:
- out = stpcpy (out, ", mips32r6");
- break;
- case EF_MIPS_ARCH_64:
- out = stpcpy (out, ", mips64");
- break;
- case EF_MIPS_ARCH_64R2:
- out = stpcpy (out, ", mips64r2");
- break;
- case EF_MIPS_ARCH_64R6:
- out = stpcpy (out, ", mips64r6");
- break;
- default:
- out = stpcpy (out, _(", unknown ISA"));
- break;
- }
- return out;
-}
-
-static char *
-decode_MSP430_machine_flags (char *out, unsigned e_flags)
-{
- out = stpcpy (out, _(": architecture variant: "));
- switch (e_flags & EF_MSP430_MACH)
- {
- case E_MSP430_MACH_MSP430x11:
- out = stpcpy (out, "MSP430x11");
- break;
- case E_MSP430_MACH_MSP430x11x1:
- out = stpcpy (out, "MSP430x11x1 ");
- break;
- case E_MSP430_MACH_MSP430x12:
- out = stpcpy (out, "MSP430x12");
- break;
- case E_MSP430_MACH_MSP430x13:
- out = stpcpy (out, "MSP430x13");
- break;
- case E_MSP430_MACH_MSP430x14:
- out = stpcpy (out, "MSP430x14");
- break;
- case E_MSP430_MACH_MSP430x15:
- out = stpcpy (out, "MSP430x15");
- break;
- case E_MSP430_MACH_MSP430x16:
- out = stpcpy (out, "MSP430x16");
- break;
- case E_MSP430_MACH_MSP430x31:
- out = stpcpy (out, "MSP430x31");
- break;
- case E_MSP430_MACH_MSP430x32:
- out = stpcpy (out, "MSP430x32");
- break;
- case E_MSP430_MACH_MSP430x33:
- out = stpcpy (out, "MSP430x33");
- break;
- case E_MSP430_MACH_MSP430x41:
- out = stpcpy (out, "MSP430x41");
- break;
- case E_MSP430_MACH_MSP430x42:
- out = stpcpy (out, "MSP430x42");
- break;
- case E_MSP430_MACH_MSP430x43:
- out = stpcpy (out, "MSP430x43");
- break;
- case E_MSP430_MACH_MSP430x44:
- out = stpcpy (out, "MSP430x44");
- break;
- case E_MSP430_MACH_MSP430X :
- out = stpcpy (out, "MSP430X");
- break;
- default:
- out = stpcpy (out, _(": unknown"));
- break;
- }
-
- if (e_flags & ~ EF_MSP430_MACH)
- out = stpcpy (out, _(": unknown extra flag bits also present"));
- return out;
-}
-
-static char *
-decode_NDS32_machine_flags (char *out, unsigned e_flags)
-{
- unsigned abi;
- unsigned arch;
- unsigned config;
- unsigned version;
- bool has_fpu = false;
-
- static const char *ABI_STRINGS[] =
- {
- "ABI v0", /* use r5 as return register; only used in N1213HC */
- "ABI v1", /* use r0 as return register */
- "ABI v2", /* use r0 as return register and don't reserve 24 bytes for arguments */
- "ABI v2fp", /* for FPU */
- "AABI",
- "ABI2 FP+"
- };
- static const char *VER_STRINGS[] =
- {
- "Andes ELF V1.3 or older",
- "Andes ELF V1.3.1",
- "Andes ELF V1.4"
- };
- static const char *ARCH_STRINGS[] =
- {
- "",
- "Andes Star v1.0",
- "Andes Star v2.0",
- "Andes Star v3.0",
- "Andes Star v3.0m"
- };
-
- abi = EF_NDS_ABI & e_flags;
- arch = EF_NDS_ARCH & e_flags;
- config = EF_NDS_INST & e_flags;
- version = EF_NDS32_ELF_VERSION & e_flags;
-
- switch (abi)
- {
- case E_NDS_ABI_V0:
- case E_NDS_ABI_V1:
- case E_NDS_ABI_V2:
- case E_NDS_ABI_V2FP:
- case E_NDS_ABI_AABI:
- case E_NDS_ABI_V2FP_PLUS:
- /* In case there are holes in the array. */
- out += sprintf (out, ", %s", ABI_STRINGS[abi >> EF_NDS_ABI_SHIFT]);
- break;
-
- default:
- out = stpcpy (out, ", <unrecognized ABI>");
- break;
- }
-
- switch (version)
- {
- case E_NDS32_ELF_VER_1_2:
- case E_NDS32_ELF_VER_1_3:
- case E_NDS32_ELF_VER_1_4:
- out += sprintf (out, ", %s", VER_STRINGS[version >> EF_NDS32_ELF_VERSION_SHIFT]);
- break;
-
- default:
- out = stpcpy (out, ", <unrecognized ELF version number>");
- break;
- }
-
- if (E_NDS_ABI_V0 == abi)
- {
- /* OLD ABI; only used in N1213HC, has performance extension 1. */
- out = stpcpy (out, ", Andes Star v1.0, N1213HC, MAC, PERF1");
- if (arch == E_NDS_ARCH_STAR_V1_0)
- out = stpcpy (out, ", 16b"); /* has 16-bit instructions */
- return out;
- }
-
- switch (arch)
- {
- case E_NDS_ARCH_STAR_V1_0:
- case E_NDS_ARCH_STAR_V2_0:
- case E_NDS_ARCH_STAR_V3_0:
- case E_NDS_ARCH_STAR_V3_M:
- out += sprintf (out, ", %s", ARCH_STRINGS[arch >> EF_NDS_ARCH_SHIFT]);
- break;
-
- default:
- out = stpcpy (out, ", <unrecognized architecture>");
- /* ARCH version determines how the e_flags are interpreted.
- If it is unknown, we cannot proceed. */
- return out;
- }
-
- /* Newer ABI; Now handle architecture specific flags. */
- if (arch == E_NDS_ARCH_STAR_V1_0)
- {
- if (config & E_NDS32_HAS_MFUSR_PC_INST)
- out = stpcpy (out, ", MFUSR_PC");
-
- if (!(config & E_NDS32_HAS_NO_MAC_INST))
- out = stpcpy (out, ", MAC");
-
- if (config & E_NDS32_HAS_DIV_INST)
- out = stpcpy (out, ", DIV");
-
- if (config & E_NDS32_HAS_16BIT_INST)
- out = stpcpy (out, ", 16b");
- }
- else
- {
- if (config & E_NDS32_HAS_MFUSR_PC_INST)
- {
- if (version <= E_NDS32_ELF_VER_1_3)
- out = stpcpy (out, ", [B8]");
- else
- out = stpcpy (out, ", EX9");
- }
-
- if (config & E_NDS32_HAS_MAC_DX_INST)
- out = stpcpy (out, ", MAC_DX");
-
- if (config & E_NDS32_HAS_DIV_DX_INST)
- out = stpcpy (out, ", DIV_DX");
-
- if (config & E_NDS32_HAS_16BIT_INST)
- {
- if (version <= E_NDS32_ELF_VER_1_3)
- out = stpcpy (out, ", 16b");
- else
- out = stpcpy (out, ", IFC");
- }
- }
-
- if (config & E_NDS32_HAS_EXT_INST)
- out = stpcpy (out, ", PERF1");
-
- if (config & E_NDS32_HAS_EXT2_INST)
- out = stpcpy (out, ", PERF2");
-
- if (config & E_NDS32_HAS_FPU_INST)
- {
- has_fpu = true;
- out = stpcpy (out, ", FPU_SP");
- }
-
- if (config & E_NDS32_HAS_FPU_DP_INST)
- {
- has_fpu = true;
- out = stpcpy (out, ", FPU_DP");
- }
-
- if (config & E_NDS32_HAS_FPU_MAC_INST)
- {
- has_fpu = true;
- out = stpcpy (out, ", FPU_MAC");
- }
-
- if (has_fpu)
- {
- switch ((config & E_NDS32_FPU_REG_CONF) >> E_NDS32_FPU_REG_CONF_SHIFT)
- {
- case E_NDS32_FPU_REG_8SP_4DP:
- out = stpcpy (out, ", FPU_REG:8/4");
- break;
- case E_NDS32_FPU_REG_16SP_8DP:
- out = stpcpy (out, ", FPU_REG:16/8");
- break;
- case E_NDS32_FPU_REG_32SP_16DP:
- out = stpcpy (out, ", FPU_REG:32/16");
- break;
- case E_NDS32_FPU_REG_32SP_32DP:
- out = stpcpy (out, ", FPU_REG:32/32");
- break;
- }
- }
-
- if (config & E_NDS32_HAS_AUDIO_INST)
- out = stpcpy (out, ", AUDIO");
-
- if (config & E_NDS32_HAS_STRING_INST)
- out = stpcpy (out, ", STR");
-
- if (config & E_NDS32_HAS_REDUCED_REGS)
- out = stpcpy (out, ", 16REG");
-
- if (config & E_NDS32_HAS_VIDEO_INST)
- {
- if (version <= E_NDS32_ELF_VER_1_3)
- out = stpcpy (out, ", VIDEO");
- else
- out = stpcpy (out, ", SATURATION");
- }
-
- if (config & E_NDS32_HAS_ENCRIPT_INST)
- out = stpcpy (out, ", ENCRP");
-
- if (config & E_NDS32_HAS_L2C_INST)
- out = stpcpy (out, ", L2C");
-
- return out;
-}
-
-static char *
-decode_PARISC_machine_flags (char *out, unsigned e_flags)
-{
- switch (e_flags & EF_PARISC_ARCH)
- {
- case EFA_PARISC_1_0:
- out = stpcpy (out, ", PA-RISC 1.0");
- break;
- case EFA_PARISC_1_1:
- out = stpcpy (out, ", PA-RISC 1.1");
- break;
- case EFA_PARISC_2_0:
- out = stpcpy (out, ", PA-RISC 2.0");
- break;
- default:
- break;
- }
- if (e_flags & EF_PARISC_TRAPNIL)
- out = stpcpy (out, ", trapnil");
- if (e_flags & EF_PARISC_EXT)
- out = stpcpy (out, ", ext");
- if (e_flags & EF_PARISC_LSB)
- out = stpcpy (out, ", lsb");
- if (e_flags & EF_PARISC_WIDE)
- out = stpcpy (out, ", wide");
- if (e_flags & EF_PARISC_NO_KABP)
- out = stpcpy (out, ", no kabp");
- if (e_flags & EF_PARISC_LAZYSWAP)
- out = stpcpy (out, ", lazyswap");
- return out;
-}
-
-static char *
-decode_RISCV_machine_flags (char *out, unsigned e_flags)
-{
- if (e_flags & EF_RISCV_RVC)
- out = stpcpy (out, ", RVC");
-
- if (e_flags & EF_RISCV_RVE)
- out = stpcpy (out, ", RVE");
-
- if (e_flags & EF_RISCV_TSO)
- out = stpcpy (out, ", TSO");
-
- switch (e_flags & EF_RISCV_FLOAT_ABI)
- {
- case EF_RISCV_FLOAT_ABI_SOFT:
- out = stpcpy (out, ", soft-float ABI");
- break;
-
- case EF_RISCV_FLOAT_ABI_SINGLE:
- out = stpcpy (out, ", single-float ABI");
- break;
-
- case EF_RISCV_FLOAT_ABI_DOUBLE:
- out = stpcpy (out, ", double-float ABI");
- break;
-
- case EF_RISCV_FLOAT_ABI_QUAD:
- out = stpcpy (out, ", quad-float ABI");
- break;
- }
- return out;
-}
-
-static char *
-decode_RL78_machine_flags (char *out, unsigned e_flags)
-{
- switch (e_flags & E_FLAG_RL78_CPU_MASK)
- {
- case E_FLAG_RL78_ANY_CPU:
- break;
- case E_FLAG_RL78_G10:
- out = stpcpy (out, ", G10");
- break;
- case E_FLAG_RL78_G13:
- out = stpcpy (out, ", G13");
- break;
- case E_FLAG_RL78_G14:
- out = stpcpy (out, ", G14");
- break;
- }
- if (e_flags & E_FLAG_RL78_64BIT_DOUBLES)
- out = stpcpy (out, ", 64-bit doubles");
- return out;
-}
-
-static char *
-decode_RX_machine_flags (char *out, unsigned e_flags)
-{
- if (e_flags & E_FLAG_RX_64BIT_DOUBLES)
- out = stpcpy (out, ", 64-bit doubles");
- if (e_flags & E_FLAG_RX_DSP)
- out = stpcpy (out, ", dsp");
- if (e_flags & E_FLAG_RX_PID)
- out = stpcpy (out, ", pid");
- if (e_flags & E_FLAG_RX_ABI)
- out = stpcpy (out, ", RX ABI");
- if (e_flags & E_FLAG_RX_SINSNS_SET)
- out = stpcpy (out, (e_flags & E_FLAG_RX_SINSNS_YES
- ? ", uses String instructions"
- : ", bans String instructions"));
- if (e_flags & E_FLAG_RX_V2)
- out = stpcpy (out, ", V2");
- if (e_flags & E_FLAG_RX_V3)
- out = stpcpy (out, ", V3");
- return out;
-}
-
-static char *
-decode_SH_machine_flags (char *out, unsigned e_flags)
-{
- switch ((e_flags & EF_SH_MACH_MASK))
- {
- case EF_SH1:
- out = stpcpy (out, ", sh1");
- break;
- case EF_SH2:
- out = stpcpy (out, ", sh2");
- break;
- case EF_SH3:
- out = stpcpy (out, ", sh3");
- break;
- case EF_SH_DSP:
- out = stpcpy (out, ", sh-dsp");
- break;
- case EF_SH3_DSP:
- out = stpcpy (out, ", sh3-dsp");
- break;
- case EF_SH4AL_DSP:
- out = stpcpy (out, ", sh4al-dsp");
- break;
- case EF_SH3E:
- out = stpcpy (out, ", sh3e");
- break;
- case EF_SH4:
- out = stpcpy (out, ", sh4");
- break;
- case EF_SH5:
- out = stpcpy (out, ", sh5");
- break;
- case EF_SH2E:
- out = stpcpy (out, ", sh2e");
- break;
- case EF_SH4A:
- out = stpcpy (out, ", sh4a");
- break;
- case EF_SH2A:
- out = stpcpy (out, ", sh2a");
- break;
- case EF_SH4_NOFPU:
- out = stpcpy (out, ", sh4-nofpu");
- break;
- case EF_SH4A_NOFPU:
- out = stpcpy (out, ", sh4a-nofpu");
- break;
- case EF_SH2A_NOFPU:
- out = stpcpy (out, ", sh2a-nofpu");
- break;
- case EF_SH3_NOMMU:
- out = stpcpy (out, ", sh3-nommu");
- break;
- case EF_SH4_NOMMU_NOFPU:
- out = stpcpy (out, ", sh4-nommu-nofpu");
- break;
- case EF_SH2A_SH4_NOFPU:
- out = stpcpy (out, ", sh2a-nofpu-or-sh4-nommu-nofpu");
- break;
- case EF_SH2A_SH3_NOFPU:
- out = stpcpy (out, ", sh2a-nofpu-or-sh3-nommu");
- break;
- case EF_SH2A_SH4:
- out = stpcpy (out, ", sh2a-or-sh4");
- break;
- case EF_SH2A_SH3E:
- out = stpcpy (out, ", sh2a-or-sh3e");
- break;
- default:
- out = stpcpy (out, _(", unknown ISA"));
- break;
- }
-
- if (e_flags & EF_SH_PIC)
- out = stpcpy (out, ", pic");
-
- if (e_flags & EF_SH_FDPIC)
- out = stpcpy (out, ", fdpic");
- return out;
-}
-
-static char *
-decode_SPARC_machine_flags (char *out, unsigned e_flags)
-{
- if (e_flags & EF_SPARC_32PLUS)
- out = stpcpy (out, ", v8+");
-
- if (e_flags & EF_SPARC_SUN_US1)
- out = stpcpy (out, ", ultrasparcI");
-
- if (e_flags & EF_SPARC_SUN_US3)
- out = stpcpy (out, ", ultrasparcIII");
-
- if (e_flags & EF_SPARC_HAL_R1)
- out = stpcpy (out, ", halr1");
-
- if (e_flags & EF_SPARC_LEDATA)
- out = stpcpy (out, ", ledata");
-
- if ((e_flags & EF_SPARCV9_MM) == EF_SPARCV9_TSO)
- out = stpcpy (out, ", tso");
-
- if ((e_flags & EF_SPARCV9_MM) == EF_SPARCV9_PSO)
- out = stpcpy (out, ", pso");
-
- if ((e_flags & EF_SPARCV9_MM) == EF_SPARCV9_RMO)
- out = stpcpy (out, ", rmo");
- return out;
-}
-
-static char *
-decode_V800_machine_flags (char *out, unsigned int e_flags)
-{
- if ((e_flags & EF_RH850_ABI) == EF_RH850_ABI)
- out = stpcpy (out, ", RH850 ABI");
-
- if (e_flags & EF_V800_850E3)
- out = stpcpy (out, ", V3 architecture");
-
- if ((e_flags & (EF_RH850_FPU_DOUBLE | EF_RH850_FPU_SINGLE)) == 0)
- out = stpcpy (out, ", FPU not used");
-
- if ((e_flags & (EF_RH850_REGMODE22 | EF_RH850_REGMODE32)) == 0)
- out = stpcpy (out, ", regmode: COMMON");
-
- if ((e_flags & (EF_RH850_GP_FIX | EF_RH850_GP_NOFIX)) == 0)
- out = stpcpy (out, ", r4 not used");
-
- if ((e_flags & (EF_RH850_EP_FIX | EF_RH850_EP_NOFIX)) == 0)
- out = stpcpy (out, ", r30 not used");
-
- if ((e_flags & (EF_RH850_TP_FIX | EF_RH850_TP_NOFIX)) == 0)
- out = stpcpy (out, ", r5 not used");
-
- if ((e_flags & (EF_RH850_REG2_RESERVE | EF_RH850_REG2_NORESERVE)) == 0)
- out = stpcpy (out, ", r2 not used");
-
- for (e_flags &= 0xFFFF; e_flags; e_flags &= ~ (e_flags & - e_flags))
- {
- switch (e_flags & - e_flags)
- {
- case EF_RH850_FPU_DOUBLE:
- out = stpcpy (out, ", double precision FPU");
- break;
- case EF_RH850_FPU_SINGLE:
- out = stpcpy (out, ", single precision FPU");
- break;
- case EF_RH850_REGMODE22:
- out = stpcpy (out, ", regmode:22");
- break;
- case EF_RH850_REGMODE32:
- out = stpcpy (out, ", regmode:23");
- break;
- case EF_RH850_GP_FIX:
- out = stpcpy (out, ", r4 fixed");
- break;
- case EF_RH850_GP_NOFIX:
- out = stpcpy (out, ", r4 free");
- break;
- case EF_RH850_EP_FIX:
- out = stpcpy (out, ", r30 fixed");
- break;
- case EF_RH850_EP_NOFIX:
- out = stpcpy (out, ", r30 free");
- break;
- case EF_RH850_TP_FIX:
- out = stpcpy (out, ", r5 fixed");
- break;
- case EF_RH850_TP_NOFIX:
- out = stpcpy (out, ", r5 free");
- break;
- case EF_RH850_REG2_RESERVE:
- out = stpcpy (out, ", r2 fixed");
- break;
- case EF_RH850_REG2_NORESERVE:
- out = stpcpy (out, ", r2 free");
- break;
- default:
- break;
- }
- }
- return out;
-}
-
-static char *
-decode_V850_machine_flags (char *out, unsigned int e_flags)
-{
- switch (e_flags & EF_V850_ARCH)
- {
- case E_V850E3V5_ARCH:
- out = stpcpy (out, ", v850e3v5");
- break;
- case E_V850E2V3_ARCH:
- out = stpcpy (out, ", v850e2v3");
- break;
- case E_V850E2_ARCH:
- out = stpcpy (out, ", v850e2");
- break;
- case E_V850E1_ARCH:
- out = stpcpy (out, ", v850e1");
- break;
- case E_V850E_ARCH:
- out = stpcpy (out, ", v850e");
- break;
- case E_V850_ARCH:
- out = stpcpy (out, ", v850");
- break;
- default:
- out = stpcpy (out, _(", unknown v850 architecture variant"));
- break;
- }
- return out;
-}
-
-static char *
-decode_Z80_machine_flags (char *out, unsigned int e_flags)
-{
- switch (e_flags & EF_Z80_MACH_MSK)
- {
- case EF_Z80_MACH_Z80:
- out = stpcpy (out, ", Z80");
- break;
- case EF_Z80_MACH_Z180:
- out = stpcpy (out, ", Z180");
- break;
- case EF_Z80_MACH_R800:
- out = stpcpy (out, ", R800");
- break;
- case EF_Z80_MACH_EZ80_Z80:
- out = stpcpy (out, ", EZ80");
- break;
- case EF_Z80_MACH_EZ80_ADL:
- out = stpcpy (out, ", EZ80, ADL");
- break;
- case EF_Z80_MACH_GBZ80:
- out = stpcpy (out, ", GBZ80");
- break;
- case EF_Z80_MACH_Z80N:
- out = stpcpy (out, ", Z80N");
- break;
- default:
- out = stpcpy (out, _(", unknown"));
- break;
- }
- return out;
-}
-
-static char *
-decode_AMDGPU_machine_flags (char *out, unsigned int e_flags, Filedata *filedata)
-{
- unsigned char *e_ident = filedata->file_header.e_ident;
- unsigned char osabi = e_ident[EI_OSABI];
- unsigned char abiversion = e_ident[EI_ABIVERSION];
- unsigned int mach;
-
- /* HSA OS ABI v2 used a different encoding, but we don't need to support it,
- it has been deprecated for a while.
-
- The PAL, MESA3D and NONE OS ABIs are not properly versioned, at the time
- of writing, they use the same flags as HSA v3, so the code below uses that
- assumption. */
- if (osabi == ELFOSABI_AMDGPU_HSA && abiversion < ELFABIVERSION_AMDGPU_HSA_V3)
- return out;
-
- mach = e_flags & EF_AMDGPU_MACH;
- switch (mach)
- {
-#define AMDGPU_CASE(code, string) \
- case code: out = stpcpy (out, ", " string); break;
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX600, "gfx600")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX601, "gfx601")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX700, "gfx700")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX701, "gfx701")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX702, "gfx702")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX703, "gfx703")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX704, "gfx704")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX801, "gfx801")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX802, "gfx802")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX803, "gfx803")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX810, "gfx810")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX900, "gfx900")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX902, "gfx902")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX904, "gfx904")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX906, "gfx906")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX908, "gfx908")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX909, "gfx909")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX90C, "gfx90c")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX1010, "gfx1010")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX1011, "gfx1011")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX1012, "gfx1012")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX1030, "gfx1030")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX1031, "gfx1031")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX1032, "gfx1032")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX1033, "gfx1033")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX1100, "gfx1100")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX1101, "gfx1101")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX1102, "gfx1102")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX602, "gfx602")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX705, "gfx705")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX805, "gfx805")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX1035, "gfx1035")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX1034, "gfx1034")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX90A, "gfx90a")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX940, "gfx940")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX1013, "gfx1013")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX1036, "gfx1036")
- default:
- out += sprintf (out, _(", <unknown AMDGPU GPU type: %#x>"), mach);
- break;
-#undef AMDGPU_CASE
- }
-
- e_flags &= ~EF_AMDGPU_MACH;
-
- if ((osabi == ELFOSABI_AMDGPU_HSA
- && abiversion == ELFABIVERSION_AMDGPU_HSA_V3)
- || osabi != ELFOSABI_AMDGPU_HSA)
- {
- /* For HSA v3 and other OS ABIs. */
- if (e_flags & EF_AMDGPU_FEATURE_XNACK_V3)
- {
- out = stpcpy (out, ", xnack on");
- e_flags &= ~EF_AMDGPU_FEATURE_XNACK_V3;
- }
-
- if (e_flags & EF_AMDGPU_FEATURE_SRAMECC_V3)
- {
- out = stpcpy (out, ", sramecc on");
- e_flags &= ~EF_AMDGPU_FEATURE_SRAMECC_V3;
- }
- }
- else
- {
- /* For HSA v4+. */
- int xnack, sramecc;
-
- xnack = e_flags & EF_AMDGPU_FEATURE_XNACK_V4;
- switch (xnack)
- {
- case EF_AMDGPU_FEATURE_XNACK_UNSUPPORTED_V4:
- break;
-
- case EF_AMDGPU_FEATURE_XNACK_ANY_V4:
- out = stpcpy (out, ", xnack any");
- break;
-
- case EF_AMDGPU_FEATURE_XNACK_OFF_V4:
- out = stpcpy (out, ", xnack off");
- break;
-
- case EF_AMDGPU_FEATURE_XNACK_ON_V4:
- out = stpcpy (out, ", xnack on");
- break;
-
- default:
- out += sprintf (out, _(", <unknown xnack value: %#x>"), xnack);
- break;
- }
-
- e_flags &= ~EF_AMDGPU_FEATURE_XNACK_V4;
-
- sramecc = e_flags & EF_AMDGPU_FEATURE_SRAMECC_V4;
- switch (sramecc)
- {
- case EF_AMDGPU_FEATURE_SRAMECC_UNSUPPORTED_V4:
- break;
-
- case EF_AMDGPU_FEATURE_SRAMECC_ANY_V4:
- out = stpcpy (out, ", sramecc any");
- break;
-
- case EF_AMDGPU_FEATURE_SRAMECC_OFF_V4:
- out = stpcpy (out, ", sramecc off");
- break;
-
- case EF_AMDGPU_FEATURE_SRAMECC_ON_V4:
- out = stpcpy (out, ", sramecc on");
- break;
-
- default:
- out += sprintf (out, _(", <unknown sramecc value: %#x>"), sramecc);
- break;
- }
-
- e_flags &= ~EF_AMDGPU_FEATURE_SRAMECC_V4;
- }
-
- if (e_flags != 0)
- out += sprintf (out, _(", unknown flags bits: %#x"), e_flags);
- return out;
-}
-
-static char *
-get_machine_flags (Filedata * filedata, unsigned e_flags, unsigned e_machine)
-{
- static char buf[1024];
- char *out = buf;
-
- buf[0] = '\0';
-
- if (e_flags)
- {
- switch (e_machine)
- {
- default:
- break;
-
- case EM_ARC_COMPACT3:
- out = stpcpy (out, ", HS5x");
- break;
-
- case EM_ARC_COMPACT3_64:
- out = stpcpy (out, ", HS6x");
- break;
-
- case EM_ARC_COMPACT2:
- case EM_ARC_COMPACT:
- out = decode_ARC_machine_flags (out, e_flags, e_machine);
- break;
-
- case EM_ARM:
- out = decode_ARM_machine_flags (out, e_flags);
- break;
-
- case EM_AVR:
- out = decode_AVR_machine_flags (out, e_flags);
- break;
-
- case EM_BLACKFIN:
- out = decode_BLACKFIN_machine_flags (out, e_flags);
- break;
-
- case EM_CYGNUS_FRV:
- out = decode_FRV_machine_flags (out, e_flags);
- break;
-
- case EM_68K:
- out = decode_M68K_machine_flags (out, e_flags);
- break;
-
- case EM_AMDGPU:
- out = decode_AMDGPU_machine_flags (out, e_flags, filedata);
- break;
-
- case EM_CYGNUS_MEP:
- out = decode_MeP_machine_flags (out, e_flags);
- break;
-
- case EM_PPC:
- if (e_flags & EF_PPC_EMB)
- out = stpcpy (out, ", emb");
-
- if (e_flags & EF_PPC_RELOCATABLE)
- out = stpcpy (out, _(", relocatable"));
-
- if (e_flags & EF_PPC_RELOCATABLE_LIB)
- out = stpcpy (out, _(", relocatable-lib"));
- break;
-
- case EM_PPC64:
- if (e_flags & EF_PPC64_ABI)
- out += sprintf (out, ", abiv%d", e_flags & EF_PPC64_ABI);
- break;
-
- case EM_V800:
- out = decode_V800_machine_flags (out, e_flags);
- break;
-
- case EM_V850:
- case EM_CYGNUS_V850:
- out = decode_V850_machine_flags (out, e_flags);
- break;
-
- case EM_M32R:
- case EM_CYGNUS_M32R:
- if ((e_flags & EF_M32R_ARCH) == E_M32R_ARCH)
- out = stpcpy (out, ", m32r");
- break;
-
- case EM_MIPS:
- case EM_MIPS_RS3_LE:
- out = decode_MIPS_machine_flags (out, e_flags);
- break;
-
- case EM_NDS32:
- out = decode_NDS32_machine_flags (out, e_flags);
- break;
-
- case EM_NFP:
- switch (EF_NFP_MACH (e_flags))
- {
- case E_NFP_MACH_3200:
- out = stpcpy (out, ", NFP-32xx");
- break;
- case E_NFP_MACH_6000:
- out = stpcpy (out, ", NFP-6xxx");
- break;
- }
- break;
-
- case EM_RISCV:
- out = decode_RISCV_machine_flags (out, e_flags);
- break;
-
- case EM_SH:
- out = decode_SH_machine_flags (out, e_flags);
- break;
-
- case EM_OR1K:
- if (e_flags & EF_OR1K_NODELAY)
- out = stpcpy (out, ", no delay");
- break;
-
- case EM_BPF:
- out += sprintf (out, ", CPU Version: %u", e_flags & EF_BPF_CPUVER);
- break;
-
- case EM_SPARCV9:
- out = decode_SPARC_machine_flags (out, e_flags);
- break;
-
- case EM_PARISC:
- out = decode_PARISC_machine_flags (out, e_flags);
- break;
-
- case EM_PJ:
- case EM_PJ_OLD:
- if ((e_flags & EF_PICOJAVA_NEWCALLS) == EF_PICOJAVA_NEWCALLS)
- out = stpcpy (out, ", new calling convention");
-
- if ((e_flags & EF_PICOJAVA_GNUCALLS) == EF_PICOJAVA_GNUCALLS)
- out = stpcpy (out, ", gnu calling convention");
- break;
-
- case EM_IA_64:
- out = decode_IA64_machine_flags (out, e_flags, filedata);
- break;
-
- case EM_VAX:
- if ((e_flags & EF_VAX_NONPIC))
- out = stpcpy (out, ", non-PIC");
- if ((e_flags & EF_VAX_DFLOAT))
- out = stpcpy (out, ", D-Float");
- if ((e_flags & EF_VAX_GFLOAT))
- out = stpcpy (out, ", G-Float");
- break;
-
- case EM_VISIUM:
- if (e_flags & EF_VISIUM_ARCH_MCM)
- out = stpcpy (out, ", mcm");
- else if (e_flags & EF_VISIUM_ARCH_MCM24)
- out = stpcpy (out, ", mcm24");
- if (e_flags & EF_VISIUM_ARCH_GR6)
- out = stpcpy (out, ", gr6");
- break;
-
- case EM_RL78:
- out = decode_RL78_machine_flags (out, e_flags);
- break;
-
- case EM_RX:
- out = decode_RX_machine_flags (out, e_flags);
- break;
-
- case EM_S390:
- if (e_flags & EF_S390_HIGH_GPRS)
- out = stpcpy (out, ", highgprs");
- break;
-
- case EM_TI_C6000:
- if ((e_flags & EF_C6000_REL))
- out = stpcpy (out, ", relocatable module");
- break;
-
- case EM_KVX:
- if ((e_flags & (ELF_KVX_CORE_MAJOR_MASK | ELF_KVX_CORE_MINOR_MASK)) == ELF_KVX_CORE_KV3_1)
- strcat (buf, ", Kalray VLIW kv3-1");
- else if ((e_flags & (ELF_KVX_CORE_MAJOR_MASK | ELF_KVX_CORE_MINOR_MASK)) == ELF_KVX_CORE_KV3_2)
- strcat (buf, ", Kalray VLIW kv3-2");
- else if ((e_flags & (ELF_KVX_CORE_MAJOR_MASK | ELF_KVX_CORE_MINOR_MASK)) == ELF_KVX_CORE_KV4_1)
- strcat (buf, ", Kalray VLIW kv4-1");
- else
- strcat (buf, ", unknown KVX MPPA");
- break;
-
- case EM_MSP430:
- out = decode_MSP430_machine_flags (out, e_flags);
- break;
-
- case EM_Z80:
- out = decode_Z80_machine_flags (out, e_flags);
- break;
-
- case EM_LOONGARCH:
- out = decode_LOONGARCH_machine_flags (out, e_flags);
- break;
- }
- }
-
- return buf;
-}
-
-static const char *
-get_osabi_name (Filedata * filedata, unsigned int osabi)
-{
- static char buff[32];
-
- switch (osabi)
- {
- case ELFOSABI_NONE: return "UNIX - System V";
- case ELFOSABI_HPUX: return "UNIX - HP-UX";
- case ELFOSABI_NETBSD: return "UNIX - NetBSD";
- case ELFOSABI_GNU: return "UNIX - GNU";
- case ELFOSABI_SOLARIS: return "UNIX - Solaris";
- case ELFOSABI_AIX: return "UNIX - AIX";
- case ELFOSABI_IRIX: return "UNIX - IRIX";
- case ELFOSABI_FREEBSD: return "UNIX - FreeBSD";
- case ELFOSABI_TRU64: return "UNIX - TRU64";
- case ELFOSABI_MODESTO: return "Novell - Modesto";
- case ELFOSABI_OPENBSD: return "UNIX - OpenBSD";
- case ELFOSABI_OPENVMS: return "VMS - OpenVMS";
- case ELFOSABI_NSK: return "HP - Non-Stop Kernel";
- case ELFOSABI_AROS: return "AROS";
- case ELFOSABI_FENIXOS: return "FenixOS";
- case ELFOSABI_CLOUDABI: return "Nuxi CloudABI";
- case ELFOSABI_OPENVOS: return "Stratus Technologies OpenVOS";
- case ELFOSABI_CUDA: return "CUDA";
- default:
- if (osabi >= 64)
- switch (filedata->file_header.e_machine)
- {
- case EM_AMDGPU:
- switch (osabi)
- {
- case ELFOSABI_AMDGPU_HSA: return "AMD HSA";
- case ELFOSABI_AMDGPU_PAL: return "AMD PAL";
- case ELFOSABI_AMDGPU_MESA3D: return "AMD Mesa3D";
- default:
- break;
- }
- break;
-
- case EM_ARM:
- switch (osabi)
- {
- case ELFOSABI_ARM: return "ARM";
- case ELFOSABI_ARM_FDPIC: return "ARM FDPIC";
- default:
- break;
- }
- break;
-
- case EM_MSP430:
- case EM_MSP430_OLD:
- case EM_VISIUM:
- switch (osabi)
- {
- case ELFOSABI_STANDALONE: return _("Standalone App");
- default:
- break;
- }
- break;
-
- case EM_TI_C6000:
- switch (osabi)
- {
- case ELFOSABI_C6000_ELFABI: return _("Bare-metal C6000");
- case ELFOSABI_C6000_LINUX: return "Linux C6000";
- default:
- break;
- }
- break;
-
- default:
- break;
- }
- snprintf (buff, sizeof (buff), _("<unknown: %x>"), osabi);
- return buff;
- }
-}
-
-static const char *
-get_aarch64_segment_type (unsigned long type)
-{
- switch (type)
- {
- case PT_AARCH64_ARCHEXT: return "AARCH64_ARCHEXT";
- case PT_AARCH64_MEMTAG_MTE: return "AARCH64_MEMTAG_MTE";
- default: return NULL;
- }
-}
-
-static const char *
-get_arm_segment_type (unsigned long type)
-{
- switch (type)
- {
- case PT_ARM_ARCHEXT: return "ARM_ARCHEXT";
- case PT_ARM_EXIDX: return "ARM_EXIDX";
- default: return NULL;
- }
-}
-
-static const char *
-get_s390_segment_type (unsigned long type)
-{
- switch (type)
- {
- case PT_S390_PGSTE: return "S390_PGSTE";
- default: return NULL;
- }
-}
-
-static const char *
-get_mips_segment_type (unsigned long type)
-{
- switch (type)
- {
- case PT_MIPS_REGINFO: return "REGINFO";
- case PT_MIPS_RTPROC: return "RTPROC";
- case PT_MIPS_OPTIONS: return "OPTIONS";
- case PT_MIPS_ABIFLAGS: return "ABIFLAGS";
- default: return NULL;
- }
-}
-
-static const char *
-get_parisc_segment_type (unsigned long type)
-{
- switch (type)
- {
- case PT_PARISC_ARCHEXT: return "PARISC_ARCHEXT";
- case PT_PARISC_UNWIND: return "PARISC_UNWIND";
- case PT_PARISC_WEAKORDER: return "PARISC_WEAKORDER";
- default: return NULL;
- }
-}
-
-static const char *
-get_ia64_segment_type (unsigned long type)
-{
- switch (type)
- {
- case PT_IA_64_ARCHEXT: return "IA_64_ARCHEXT";
- case PT_IA_64_UNWIND: return "IA_64_UNWIND";
- default: return NULL;
- }
-}
-
-static const char *
-get_tic6x_segment_type (unsigned long type)
-{
- switch (type)
- {
- case PT_C6000_PHATTR: return "C6000_PHATTR";
- default: return NULL;
- }
-}
-
-static const char *
-get_riscv_segment_type (unsigned long type)
-{
- switch (type)
- {
- case PT_RISCV_ATTRIBUTES: return "RISCV_ATTRIBUTES";
- default: return NULL;
- }
-}
-
-static const char *
-get_hpux_segment_type (unsigned long type, unsigned e_machine)
-{
- if (e_machine == EM_PARISC)
- switch (type)
- {
- case PT_HP_TLS: return "HP_TLS";
- case PT_HP_CORE_NONE: return "HP_CORE_NONE";
- case PT_HP_CORE_VERSION: return "HP_CORE_VERSION";
- case PT_HP_CORE_KERNEL: return "HP_CORE_KERNEL";
- case PT_HP_CORE_COMM: return "HP_CORE_COMM";
- case PT_HP_CORE_PROC: return "HP_CORE_PROC";
- case PT_HP_CORE_LOADABLE: return "HP_CORE_LOADABLE";
- case PT_HP_CORE_STACK: return "HP_CORE_STACK";
- case PT_HP_CORE_SHM: return "HP_CORE_SHM";
- case PT_HP_CORE_MMF: return "HP_CORE_MMF";
- case PT_HP_PARALLEL: return "HP_PARALLEL";
- case PT_HP_FASTBIND: return "HP_FASTBIND";
- case PT_HP_OPT_ANNOT: return "HP_OPT_ANNOT";
- case PT_HP_HSL_ANNOT: return "HP_HSL_ANNOT";
- case PT_HP_STACK: return "HP_STACK";
- case PT_HP_CORE_UTSNAME: return "HP_CORE_UTSNAME";
- default:
- break;
- }
-
- if (e_machine == EM_IA_64)
- switch (type)
- {
- case PT_HP_TLS: return "HP_TLS";
- case PT_IA_64_HP_OPT_ANOT: return "HP_OPT_ANNOT";
- case PT_IA_64_HP_HSL_ANOT: return "HP_HSL_ANNOT";
- case PT_IA_64_HP_STACK: return "HP_STACK";
- default:
- break;
- }
-
- return NULL;
-}
-
-static const char *
-get_solaris_segment_type (unsigned long type)
-{
- switch (type)
- {
- case PT_SUNW_UNWIND: return "SUNW_UNWIND";
- case PT_SUNW_EH_FRAME: return "SUNW_EH_FRAME";
- case PT_SUNWBSS: return "SUNW_BSS";
- case PT_SUNWSTACK: return "SUNW_STACK";
- case PT_SUNWDTRACE: return "SUNW_DTRACE";
- case PT_SUNWCAP: return "SUNW_CAP";
- default: return NULL;
- }
-}
-
-static const char *
-get_os_specific_segment_type (Filedata * filedata, unsigned long p_type)
-{
- static char buff[32];
- const char * result = NULL;
-
- switch (filedata->file_header.e_ident[EI_OSABI])
- {
- case ELFOSABI_GNU:
- case ELFOSABI_FREEBSD:
- if (p_type >= PT_GNU_MBIND_LO && p_type <= PT_GNU_MBIND_HI)
- {
- sprintf (buff, "GNU_MBIND+%#lx", p_type - PT_GNU_MBIND_LO);
- result = buff;
- }
- break;
-
- case ELFOSABI_HPUX:
- result = get_hpux_segment_type (p_type,
- filedata->file_header.e_machine);
- break;
-
- case ELFOSABI_SOLARIS:
- result = get_solaris_segment_type (p_type);
- break;
-
- default:
- break;
- }
-
- if (result != NULL)
- return result;
-
- switch (p_type)
- {
- case PT_GNU_EH_FRAME: return "GNU_EH_FRAME";
- case PT_GNU_STACK: return "GNU_STACK";
- case PT_GNU_RELRO: return "GNU_RELRO";
- case PT_GNU_PROPERTY: return "GNU_PROPERTY";
- case PT_GNU_SFRAME: return "GNU_SFRAME";
-
- case PT_OPENBSD_MUTABLE: return "OPENBSD_MUTABLE";
- case PT_OPENBSD_RANDOMIZE: return "OPENBSD_RANDOMIZE";
- case PT_OPENBSD_WXNEEDED: return "OPENBSD_WXNEEDED";
- case PT_OPENBSD_NOBTCFI: return "OPENBSD_NOBTCFI";
- case PT_OPENBSD_SYSCALLS: return "OPENBSD_SYSCALLS";
- case PT_OPENBSD_BOOTDATA: return "OPENBSD_BOOTDATA";
-
- default:
- break;
- }
-
- sprintf (buff, "LOOS+%#lx", p_type - PT_LOOS);
- return buff;
-}
-
-static const char *
-get_processor_specific_segment_type (Filedata * filedata, unsigned long p_type)
-{
- static char buff[32];
- const char * result = NULL;
-
- switch (filedata->file_header.e_machine)
- {
- case EM_AARCH64:
- result = get_aarch64_segment_type (p_type);
- break;
-
- case EM_ARM:
- result = get_arm_segment_type (p_type);
- break;
-
- case EM_MIPS:
- case EM_MIPS_RS3_LE:
- result = get_mips_segment_type (p_type);
- break;
-
- case EM_PARISC:
- result = get_parisc_segment_type (p_type);
- break;
-
- case EM_IA_64:
- result = get_ia64_segment_type (p_type);
- break;
-
- case EM_TI_C6000:
- result = get_tic6x_segment_type (p_type);
- break;
-
- case EM_S390:
- case EM_S390_OLD:
- result = get_s390_segment_type (p_type);
- break;
-
- case EM_RISCV:
- result = get_riscv_segment_type (p_type);
- break;
-
- default:
- result = NULL;
- break;
- }
-
- if (result != NULL)
- return result;
-
- sprintf (buff, "LOPROC+%#lx", p_type - PT_LOPROC);
- return buff;
-}
-
-static const char *
-get_segment_type (Filedata * filedata, unsigned long p_type)
-{
- static char buff[32];
-
- switch (p_type)
- {
- case PT_NULL: return "NULL";
- case PT_LOAD: return "LOAD";
- case PT_DYNAMIC: return "DYNAMIC";
- case PT_INTERP: return "INTERP";
- case PT_NOTE: return "NOTE";
- case PT_SHLIB: return "SHLIB";
- case PT_PHDR: return "PHDR";
- case PT_TLS: return "TLS";
- case PT_NUM: return "NUM";
- }
-
- if ((p_type >= PT_LOOS) && (p_type <= PT_HIOS))
- return get_os_specific_segment_type (filedata, p_type);
-
- if ((p_type >= PT_LOPROC) && (p_type <= PT_HIPROC))
- return get_processor_specific_segment_type (filedata, p_type);
-
- snprintf (buff, sizeof (buff), _("<unknown>: %lx"), p_type);
- return buff;
-}
-
-static const char *
-get_arc_section_type_name (unsigned int sh_type)
-{
- switch (sh_type)
- {
- case SHT_ARC_ATTRIBUTES: return "ARC_ATTRIBUTES";
- default:
- break;
- }
- return NULL;
-}
-
-static const char *
-get_mips_section_type_name (unsigned int sh_type)
-{
- switch (sh_type)
- {
- case SHT_MIPS_LIBLIST: return "MIPS_LIBLIST";
- case SHT_MIPS_MSYM: return "MIPS_MSYM";
- case SHT_MIPS_CONFLICT: return "MIPS_CONFLICT";
- case SHT_MIPS_GPTAB: return "MIPS_GPTAB";
- case SHT_MIPS_UCODE: return "MIPS_UCODE";
- case SHT_MIPS_DEBUG: return "MIPS_DEBUG";
- case SHT_MIPS_REGINFO: return "MIPS_REGINFO";
- case SHT_MIPS_PACKAGE: return "MIPS_PACKAGE";
- case SHT_MIPS_PACKSYM: return "MIPS_PACKSYM";
- case SHT_MIPS_RELD: return "MIPS_RELD";
- case SHT_MIPS_IFACE: return "MIPS_IFACE";
- case SHT_MIPS_CONTENT: return "MIPS_CONTENT";
- case SHT_MIPS_OPTIONS: return "MIPS_OPTIONS";
- case SHT_MIPS_SHDR: return "MIPS_SHDR";
- case SHT_MIPS_FDESC: return "MIPS_FDESC";
- case SHT_MIPS_EXTSYM: return "MIPS_EXTSYM";
- case SHT_MIPS_DENSE: return "MIPS_DENSE";
- case SHT_MIPS_PDESC: return "MIPS_PDESC";
- case SHT_MIPS_LOCSYM: return "MIPS_LOCSYM";
- case SHT_MIPS_AUXSYM: return "MIPS_AUXSYM";
- case SHT_MIPS_OPTSYM: return "MIPS_OPTSYM";
- case SHT_MIPS_LOCSTR: return "MIPS_LOCSTR";
- case SHT_MIPS_LINE: return "MIPS_LINE";
- case SHT_MIPS_RFDESC: return "MIPS_RFDESC";
- case SHT_MIPS_DELTASYM: return "MIPS_DELTASYM";
- case SHT_MIPS_DELTAINST: return "MIPS_DELTAINST";
- case SHT_MIPS_DELTACLASS: return "MIPS_DELTACLASS";
- case SHT_MIPS_DWARF: return "MIPS_DWARF";
- case SHT_MIPS_DELTADECL: return "MIPS_DELTADECL";
- case SHT_MIPS_SYMBOL_LIB: return "MIPS_SYMBOL_LIB";
- case SHT_MIPS_EVENTS: return "MIPS_EVENTS";
- case SHT_MIPS_TRANSLATE: return "MIPS_TRANSLATE";
- case SHT_MIPS_PIXIE: return "MIPS_PIXIE";
- case SHT_MIPS_XLATE: return "MIPS_XLATE";
- case SHT_MIPS_XLATE_DEBUG: return "MIPS_XLATE_DEBUG";
- case SHT_MIPS_WHIRL: return "MIPS_WHIRL";
- case SHT_MIPS_EH_REGION: return "MIPS_EH_REGION";
- case SHT_MIPS_XLATE_OLD: return "MIPS_XLATE_OLD";
- case SHT_MIPS_PDR_EXCEPTION: return "MIPS_PDR_EXCEPTION";
- case SHT_MIPS_ABIFLAGS: return "MIPS_ABIFLAGS";
- case SHT_MIPS_XHASH: return "MIPS_XHASH";
- default:
- break;
- }
- return NULL;
-}
-
-static const char *
-get_parisc_section_type_name (unsigned int sh_type)
-{
- switch (sh_type)
- {
- case SHT_PARISC_EXT: return "PARISC_EXT";
- case SHT_PARISC_UNWIND: return "PARISC_UNWIND";
- case SHT_PARISC_DOC: return "PARISC_DOC";
- case SHT_PARISC_ANNOT: return "PARISC_ANNOT";
- case SHT_PARISC_DLKM: return "PARISC_DLKM";
- case SHT_PARISC_SYMEXTN: return "PARISC_SYMEXTN";
- case SHT_PARISC_STUBS: return "PARISC_STUBS";
- default: return NULL;
- }
-}
-
-static const char *
-get_ia64_section_type_name (Filedata * filedata, unsigned int sh_type)
-{
- /* If the top 8 bits are 0x78 the next 8 are the os/abi ID. */
- if ((sh_type & 0xFF000000) == SHT_IA_64_LOPSREG)
- return get_osabi_name (filedata, (sh_type & 0x00FF0000) >> 16);
-
- switch (sh_type)
- {
- case SHT_IA_64_EXT: return "IA_64_EXT";
- case SHT_IA_64_UNWIND: return "IA_64_UNWIND";
- case SHT_IA_64_PRIORITY_INIT: return "IA_64_PRIORITY_INIT";
- default:
- break;
- }
- return NULL;
-}
-
-static const char *
-get_vms_section_type_name (unsigned int sh_type)
-{
- switch (sh_type)
- {
- case SHT_IA_64_VMS_TRACE: return "VMS_TRACE";
- case SHT_IA_64_VMS_TIE_SIGNATURES: return "VMS_TIE_SIGNATURES";
- case SHT_IA_64_VMS_DEBUG: return "VMS_DEBUG";
- case SHT_IA_64_VMS_DEBUG_STR: return "VMS_DEBUG_STR";
- case SHT_IA_64_VMS_LINKAGES: return "VMS_LINKAGES";
- case SHT_IA_64_VMS_SYMBOL_VECTOR: return "VMS_SYMBOL_VECTOR";
- case SHT_IA_64_VMS_FIXUP: return "VMS_FIXUP";
- default:
- break;
- }
- return NULL;
-}
-
-static const char *
-get_x86_64_section_type_name (unsigned int sh_type)
-{
- switch (sh_type)
- {
- case SHT_X86_64_UNWIND: return "X86_64_UNWIND";
- default: return NULL;
- }
-}
-
-static const char *
-get_aarch64_section_type_name (unsigned int sh_type)
-{
- switch (sh_type)
- {
- case SHT_AARCH64_ATTRIBUTES:
- return "AARCH64_ATTRIBUTES";
- case SHT_AARCH64_AUTH_RELR:
- return "AARCH64_AUTH_RELR";
- case SHT_AARCH64_MEMTAG_GLOBALS_STATIC:
- return "AARCH64_MEMTAG_GLOBALS_STATIC";
- case SHT_AARCH64_MEMTAG_GLOBALS_DYNAMIC:
- return "AARCH64_MEMTAG_GLOBALS_DYNAMIC";
- default:
- return NULL;
- }
-}
-
-static const char *
-get_arm_section_type_name (unsigned int sh_type)
-{
- switch (sh_type)
- {
- case SHT_ARM_EXIDX: return "ARM_EXIDX";
- case SHT_ARM_PREEMPTMAP: return "ARM_PREEMPTMAP";
- case SHT_ARM_ATTRIBUTES: return "ARM_ATTRIBUTES";
- case SHT_ARM_DEBUGOVERLAY: return "ARM_DEBUGOVERLAY";
- case SHT_ARM_OVERLAYSECTION: return "ARM_OVERLAYSECTION";
- default: return NULL;
- }
-}
-
-static const char *
-get_tic6x_section_type_name (unsigned int sh_type)
-{
- switch (sh_type)
- {
- case SHT_C6000_UNWIND: return "C6000_UNWIND";
- case SHT_C6000_PREEMPTMAP: return "C6000_PREEMPTMAP";
- case SHT_C6000_ATTRIBUTES: return "C6000_ATTRIBUTES";
- case SHT_TI_ICODE: return "TI_ICODE";
- case SHT_TI_XREF: return "TI_XREF";
- case SHT_TI_HANDLER: return "TI_HANDLER";
- case SHT_TI_INITINFO: return "TI_INITINFO";
- case SHT_TI_PHATTRS: return "TI_PHATTRS";
- default: return NULL;
- }
-}
-
-static const char *
-get_msp430_section_type_name (unsigned int sh_type)
-{
- switch (sh_type)
- {
- case SHT_MSP430_SEC_FLAGS: return "MSP430_SEC_FLAGS";
- case SHT_MSP430_SYM_ALIASES: return "MSP430_SYM_ALIASES";
- case SHT_MSP430_ATTRIBUTES: return "MSP430_ATTRIBUTES";
- default: return NULL;
- }
-}
-
-static const char *
-get_nfp_section_type_name (unsigned int sh_type)
-{
- switch (sh_type)
- {
- case SHT_NFP_MECONFIG: return "NFP_MECONFIG";
- case SHT_NFP_INITREG: return "NFP_INITREG";
- case SHT_NFP_UDEBUG: return "NFP_UDEBUG";
- default: return NULL;
- }
-}
-
-static const char *
-get_v850_section_type_name (unsigned int sh_type)
-{
- switch (sh_type)
- {
- case SHT_V850_SCOMMON: return "V850 Small Common";
- case SHT_V850_TCOMMON: return "V850 Tiny Common";
- case SHT_V850_ZCOMMON: return "V850 Zero Common";
- case SHT_RENESAS_IOP: return "RENESAS IOP";
- case SHT_RENESAS_INFO: return "RENESAS INFO";
- default: return NULL;
- }
-}
-
-static const char *
-get_riscv_section_type_name (unsigned int sh_type)
-{
- switch (sh_type)
- {
- case SHT_RISCV_ATTRIBUTES: return "RISCV_ATTRIBUTES";
- default: return NULL;
- }
-}
-
-static const char *
-get_csky_section_type_name (unsigned int sh_type)
-{
- switch (sh_type)
- {
- case SHT_CSKY_ATTRIBUTES: return "CSKY_ATTRIBUTES";
- default: return NULL;
- }
-}
-
-static const char *
-get_powerpc_section_type_name (unsigned int sh_type)
-{
- switch (sh_type)
- {
- case SHT_ORDERED: return "ORDERED";
- default: return NULL;
- }
-}
-
-static const char *
-get_alpha_section_type_name (unsigned int sh_type)
-{
- switch (sh_type)
- {
- case SHT_ALPHA_DEBUG: return "DEBUG";
- case SHT_ALPHA_REGINFO: return "REGINFO";
- default: return NULL;
- }
-}
-
-static const char *
-get_processor_specific_section_type_name (Filedata * filedata, unsigned int sh_type)
-{
- static char buff[32];
- const char * result = NULL;
-
- switch (filedata->file_header.e_machine)
- {
- case EM_AARCH64:
- result = get_aarch64_section_type_name (sh_type);
- break;
-
- case EM_ALPHA:
- result = get_alpha_section_type_name (sh_type);
- break;
-
- case EM_ARC:
- case EM_ARC_COMPACT:
- case EM_ARC_COMPACT2:
- case EM_ARC_COMPACT3:
- case EM_ARC_COMPACT3_64:
- result = get_arc_section_type_name (sh_type);
- break;
-
- case EM_ARM:
- result = get_arm_section_type_name (sh_type);
- break;
-
- case EM_CSKY:
- result = get_csky_section_type_name (sh_type);
- break;
-
- case EM_IA_64:
- result = get_ia64_section_type_name (filedata, sh_type);
- break;
-
- case EM_MIPS:
- case EM_MIPS_RS3_LE:
- result = get_mips_section_type_name (sh_type);
- break;
-
- case EM_MSP430:
- result = get_msp430_section_type_name (sh_type);
- break;
-
- case EM_NFP:
- result = get_nfp_section_type_name (sh_type);
- break;
-
- case EM_PARISC:
- result = get_parisc_section_type_name (sh_type);
- break;
-
- case EM_PPC64:
- case EM_PPC:
- return get_powerpc_section_type_name (sh_type);
- break;
-
- case EM_RISCV:
- result = get_riscv_section_type_name (sh_type);
- break;
-
- case EM_TI_C6000:
- result = get_tic6x_section_type_name (sh_type);
- break;
-
- case EM_V800:
- case EM_V850:
- case EM_CYGNUS_V850:
- result = get_v850_section_type_name (sh_type);
- break;
-
- case EM_X86_64:
- case EM_L1OM:
- case EM_K1OM:
- result = get_x86_64_section_type_name (sh_type);
- break;
-
- default:
- break;
- }
-
- if (result != NULL)
- return result;
-
- switch (sh_type)
- {
- /* FIXME: Are these correct ? If so, why do they not have #define's ? */
- case 0x7ffffffd: return "AUXILIARY";
- case 0x7fffffff: return "FILTER";
- default:
- break;
- }
-
- sprintf (buff, "LOPROC+%#x", sh_type - SHT_LOPROC);
- return buff;
-}
-
-static const char *
-get_os_specific_section_type_name (Filedata * filedata, unsigned int sh_type)
-{
- static char buff[32];
- const char * result = NULL;
-
- switch (filedata->file_header.e_machine)
- {
- case EM_IA_64:
- result = get_vms_section_type_name (sh_type);
- break;
- default:
- break;
- }
-
- if (result != NULL)
- return result;
-
- if (filedata->file_header.e_ident[EI_OSABI] == ELFOSABI_SOLARIS)
- result = get_solaris_section_type (sh_type);
-
- if (result != NULL)
- return result;
-
- switch (sh_type)
- {
- case SHT_GNU_INCREMENTAL_INPUTS: return "GNU_INCREMENTAL_INPUTS";
- case SHT_GNU_ATTRIBUTES: return "GNU_ATTRIBUTES";
- case SHT_GNU_HASH: return "GNU_HASH";
- case SHT_GNU_LIBLIST: return "GNU_LIBLIST";
-
- case SHT_SUNW_move: return "SUNW_MOVE";
- case SHT_SUNW_COMDAT: return "SUNW_COMDAT";
- case SHT_SUNW_syminfo: return "SUNW_SYMINFO";
- case SHT_GNU_verdef: return "VERDEF";
- case SHT_GNU_verneed: return "VERNEED";
- case SHT_GNU_versym: return "VERSYM";
-
- case SHT_LLVM_ODRTAB: return "LLVM_ODRTAB";
- case SHT_LLVM_LINKER_OPTIONS: return "LLVM_LINKER_OPTIONS";
- case SHT_LLVM_ADDRSIG: return "LLVM_ADDRSIG";
- case SHT_LLVM_DEPENDENT_LIBRARIES: return "LLVM_DEPENDENT_LIBRARIES";
- case SHT_LLVM_SYMPART: return "LLVM_SYMPART";
- case SHT_LLVM_PART_EHDR: return "LLVM_PART_EHDR";
- case SHT_LLVM_PART_PHDR: return "LLVM_PART_PHDR";
- case SHT_LLVM_BB_ADDR_MAP_V0: return "LLVM_BB_ADDR_MAP_V0";
- case SHT_LLVM_CALL_GRAPH_PROFILE: return "LLVM_CALL_GRAPH_PROFILE";
- case SHT_LLVM_BB_ADDR_MAP: return "LLVM_BB_ADDR_MAP";
- case SHT_LLVM_OFFLOADING: return "LLVM_OFFLOADING";
- case SHT_LLVM_LTO: return "LLVM_LTO";
-
- case SHT_ANDROID_REL: return "ANDROID_REL";
- case SHT_ANDROID_RELA: return "ANDROID_RELA";
- case SHT_ANDROID_RELR: return "ANDROID_RELR";
-
- case SHT_CHECKSUM: return "CHECKSUM";
-
- /* FIXME: Are these correct ? If so, why do they not have #define's ? */
- case 0x6ffffff0: return "VERSYM";
-
- default:
- break;
- }
-
- sprintf (buff, "LOOS+%#x", sh_type - SHT_LOOS);
- return buff;
-}
-
-static const char *
-get_user_specific_section_type_name (Filedata * filedata, unsigned int sh_type)
-{
- static char buff[32];
- const char * result;
-
- switch (filedata->file_header.e_machine)
- {
- case EM_V800:
- case EM_V850:
- case EM_CYGNUS_V850:
- result = get_v850_section_type_name (sh_type);
- break;
-
- default:
- result = NULL;
- break;
- }
-
- if (result != NULL)
- return result;
-
- sprintf (buff, "LOUSER+%#x", sh_type - SHT_LOUSER);
- return buff;
-}
-
-static const char *
-get_section_type_name (Filedata * filedata,
- unsigned int sh_type)
-{
- switch (sh_type)
- {
- case SHT_NULL: return "NULL";
- case SHT_PROGBITS: return "PROGBITS";
- case SHT_SYMTAB: return "SYMTAB";
- case SHT_STRTAB: return "STRTAB";
- case SHT_RELA: return "RELA";
- case SHT_HASH: return "HASH";
- case SHT_DYNAMIC: return "DYNAMIC";
- case SHT_NOTE: return "NOTE";
- case SHT_NOBITS: return "NOBITS";
- case SHT_REL: return "REL";
- case SHT_SHLIB: return "SHLIB";
- case SHT_DYNSYM: return "DYNSYM";
- /* 12 and 13 are not defined. */
- case SHT_INIT_ARRAY: return "INIT_ARRAY";
- case SHT_FINI_ARRAY: return "FINI_ARRAY";
- case SHT_PREINIT_ARRAY: return "PREINIT_ARRAY";
- case SHT_GROUP: return "GROUP";
- case SHT_SYMTAB_SHNDX: return "SYMTAB SECTION INDICES";
- case SHT_RELR: return "RELR";
- /* End of generic section types. */
-
- default:
- break;
- }
-
- if ((sh_type >= SHT_LOPROC) && (sh_type <= SHT_HIPROC))
- return get_processor_specific_section_type_name (filedata, sh_type);
-
- if ((sh_type >= SHT_LOOS) && (sh_type <= SHT_HIOS))
- return get_os_specific_section_type_name (filedata, sh_type);
-
- if ((sh_type >= SHT_LOUSER) && (sh_type <= SHT_HIUSER))
- return get_user_specific_section_type_name (filedata, sh_type);
-
- static char buff[32];
-
- /* This message is probably going to be displayed in a 15
- character wide field, so put the hex value first. */
- snprintf (buff, sizeof (buff), _("%08x: <unknown>"), sh_type);
- return buff;
-}
-
-enum long_option_values
-{
- OPTION_DEBUG_DUMP = 512,
- OPTION_DYN_SYMS,
- OPTION_LTO_SYMS,
- OPTION_DWARF_DEPTH,
- OPTION_DWARF_START,
- OPTION_DWARF_CHECK,
- OPTION_CTF_DUMP,
- OPTION_CTF_PARENT,
- OPTION_CTF_SYMBOLS,
- OPTION_CTF_STRINGS,
- OPTION_SFRAME_DUMP,
- OPTION_WITH_SYMBOL_VERSIONS,
- OPTION_RECURSE_LIMIT,
- OPTION_NO_RECURSE_LIMIT,
- OPTION_NO_DEMANGLING,
- OPTION_NO_EXTRA_SYM_INFO,
- OPTION_SYM_BASE
-};
-
-static struct option options[] =
-{
- /* Note - This table is alpha-sorted on the 'val'
- field in order to make adding new options easier. */
- {"arch-specific", no_argument, 0, 'A'},
- {"all", no_argument, 0, 'a'},
- {"demangle", optional_argument, 0, 'C'},
- {"archive-index", no_argument, 0, 'c'},
- {"use-dynamic", no_argument, 0, 'D'},
- {"dynamic", no_argument, 0, 'd'},
- {"headers", no_argument, 0, 'e'},
- {"section-groups", no_argument, 0, 'g'},
- {"help", no_argument, 0, 'H'},
- {"file-header", no_argument, 0, 'h'},
- {"histogram", no_argument, 0, 'I'},
- {"display-section", required_argument, 0, 'j'},
- {"lint", no_argument, 0, 'L'},
- {"enable-checks", no_argument, 0, 'L'},
- {"program-headers", no_argument, 0, 'l'},
- {"segments", no_argument, 0, 'l'},
- {"full-section-name",no_argument, 0, 'N'},
- {"notes", no_argument, 0, 'n'},
- {"process-links", no_argument, 0, 'P'},
- {"string-dump", required_argument, 0, 'p'},
- {"relocated-dump", required_argument, 0, 'R'},
- {"relocs", no_argument, 0, 'r'},
- {"section-headers", no_argument, 0, 'S'},
- {"sections", no_argument, 0, 'S'},
- {"symbols", no_argument, 0, 's'},
- {"syms", no_argument, 0, 's'},
- {"silent-truncation",no_argument, 0, 'T'},
- {"section-details", no_argument, 0, 't'},
- {"unicode", required_argument, NULL, 'U'},
- {"unwind", no_argument, 0, 'u'},
- {"version-info", no_argument, 0, 'V'},
- {"version", no_argument, 0, 'v'},
- {"wide", no_argument, 0, 'W'},
- {"extra-sym-info", no_argument, 0, 'X'},
- {"hex-dump", required_argument, 0, 'x'},
- {"decompress", no_argument, 0, 'z'},
-
- {"no-demangle", no_argument, 0, OPTION_NO_DEMANGLING},
- {"no-extra-sym-info",no_argument, 0, OPTION_NO_EXTRA_SYM_INFO},
- {"recurse-limit", no_argument, NULL, OPTION_RECURSE_LIMIT},
- {"no-recurse-limit", no_argument, NULL, OPTION_NO_RECURSE_LIMIT},
- {"no-recursion-limit", no_argument, NULL, OPTION_NO_RECURSE_LIMIT},
- {"dyn-syms", no_argument, 0, OPTION_DYN_SYMS},
- {"lto-syms", no_argument, 0, OPTION_LTO_SYMS},
- {"debug-dump", optional_argument, 0, OPTION_DEBUG_DUMP},
- {"dwarf-depth", required_argument, 0, OPTION_DWARF_DEPTH},
- {"dwarf-start", required_argument, 0, OPTION_DWARF_START},
- {"dwarf-check", no_argument, 0, OPTION_DWARF_CHECK},
-#ifdef ENABLE_LIBCTF
- {"ctf", required_argument, 0, OPTION_CTF_DUMP},
- {"ctf-symbols", required_argument, 0, OPTION_CTF_SYMBOLS},
- {"ctf-strings", required_argument, 0, OPTION_CTF_STRINGS},
- {"ctf-parent", required_argument, 0, OPTION_CTF_PARENT},
-#endif
- {"sframe", optional_argument, 0, OPTION_SFRAME_DUMP},
- {"sym-base", optional_argument, 0, OPTION_SYM_BASE},
-
- {0, no_argument, 0, 0}
-};
-
-static void
-usage (FILE * stream)
-{
- fprintf (stream, _("Usage: readelf <option(s)> elf-file(s)\n"));
- fprintf (stream, _(" Display information about the contents of ELF format files\n"));
- fprintf (stream, _(" Options are:\n"));
- fprintf (stream, _("\
- -a --all Equivalent to: -h -l -S -s -r -d -V -A -I\n"));
- fprintf (stream, _("\
- -h --file-header Display the ELF file header\n"));
- fprintf (stream, _("\
- -l --program-headers Display the program headers\n"));
- fprintf (stream, _("\
- --segments An alias for --program-headers\n"));
- fprintf (stream, _("\
- -S --section-headers Display the sections' header\n"));
- fprintf (stream, _("\
- --sections An alias for --section-headers\n"));
- fprintf (stream, _("\
- -g --section-groups Display the section groups\n"));
- fprintf (stream, _("\
- -t --section-details Display the section details\n"));
- fprintf (stream, _("\
- -e --headers Equivalent to: -h -l -S\n"));
- fprintf (stream, _("\
- -s --syms Display the symbol table\n"));
- fprintf (stream, _("\
- --symbols An alias for --syms\n"));
- fprintf (stream, _("\
- --dyn-syms Display the dynamic symbol table\n"));
- fprintf (stream, _("\
- --lto-syms Display LTO symbol tables\n"));
- fprintf (stream, _("\
- --sym-base=[0|8|10|16] \n\
- Force base for symbol sizes. The options are \n\
- mixed (the default), octal, decimal, hexadecimal.\n"));
- fprintf (stream, _("\
- -C --demangle[=STYLE] Decode mangled/processed symbol names\n"));
- display_demangler_styles (stream, _("\
- STYLE can be "));
- fprintf (stream, _("\
- --no-demangle Do not demangle low-level symbol names. (default)\n"));
- fprintf (stream, _("\
- --recurse-limit Enable a demangling recursion limit. (default)\n"));
- fprintf (stream, _("\
- --no-recurse-limit Disable a demangling recursion limit\n"));
- fprintf (stream, _("\
- -U[dlexhi] --unicode=[default|locale|escape|hex|highlight|invalid]\n\
- Display unicode characters as determined by the current locale\n\
- (default), escape sequences, \"<hex sequences>\", highlighted\n\
- escape sequences, or treat them as invalid and display as\n\
- \"{hex sequences}\"\n"));
- fprintf (stream, _("\
- -X --extra-sym-info Display extra information when showing symbols\n"));
- fprintf (stream, _("\
- --no-extra-sym-info Do not display extra information when showing symbols (default)\n"));
- fprintf (stream, _("\
- -n --notes Display the contents of note sections (if present)\n"));
- fprintf (stream, _("\
- -r --relocs Display the relocations (if present)\n"));
- fprintf (stream, _("\
- -u --unwind Display the unwind info (if present)\n"));
- fprintf (stream, _("\
- -d --dynamic Display the dynamic section (if present)\n"));
- fprintf (stream, _("\
- -V --version-info Display the version sections (if present)\n"));
- fprintf (stream, _("\
- -A --arch-specific Display architecture specific information (if any)\n"));
- fprintf (stream, _("\
- -c --archive-index Display the symbol/file index in an archive\n"));
- fprintf (stream, _("\
- -D --use-dynamic Use the dynamic section info when displaying symbols\n"));
- fprintf (stream, _("\
- -L --lint|--enable-checks\n\
- Display warning messages for possible problems\n"));
- fprintf (stream, _("\
- -x --hex-dump=<number|name>\n\
- Dump the contents of section <number|name> as bytes\n"));
- fprintf (stream, _("\
- -p --string-dump=<number|name>\n\
- Dump the contents of section <number|name> as strings\n"));
- fprintf (stream, _("\
- -R --relocated-dump=<number|name>\n\
- Dump the relocated contents of section <number|name>\n"));
- fprintf (stream, _("\
- -z --decompress Decompress section before dumping it\n"));
- fprintf (stream, _("\n\
- -j --display-section=<name|number>\n\
- Display the contents of the indicated section. Can be repeated\n"));
- fprintf (stream, _("\
- -w --debug-dump[a/=abbrev, A/=addr, r/=aranges, c/=cu_index, L/=decodedline,\n\
- f/=frames, F/=frames-interp, g/=gdb_index, i/=info, o/=loc,\n\
- m/=macro, p/=pubnames, t/=pubtypes, R/=Ranges, l/=rawline,\n\
- s/=str, O/=str-offsets, u/=trace_abbrev, T/=trace_aranges,\n\
- U/=trace_info]\n\
- Display the contents of DWARF debug sections\n"));
- fprintf (stream, _("\
- -wk --debug-dump=links Display the contents of sections that link to separate\n\
- debuginfo files\n"));
- fprintf (stream, _("\
- -P --process-links Display the contents of non-debug sections in separate\n\
- debuginfo files. (Implies -wK)\n"));
-#if DEFAULT_FOR_FOLLOW_LINKS
- fprintf (stream, _("\
- -wK --debug-dump=follow-links\n\
- Follow links to separate debug info files (default)\n"));
- fprintf (stream, _("\
- -wN --debug-dump=no-follow-links\n\
- Do not follow links to separate debug info files\n"));
-#else
- fprintf (stream, _("\
- -wK --debug-dump=follow-links\n\
- Follow links to separate debug info files\n"));
- fprintf (stream, _("\
- -wN --debug-dump=no-follow-links\n\
- Do not follow links to separate debug info files\n\
- (default)\n"));
-#endif
-#if HAVE_LIBDEBUGINFOD
- fprintf (stream, _("\
- -wD --debug-dump=use-debuginfod\n\
- When following links, also query debuginfod servers (default)\n"));
- fprintf (stream, _("\
- -wE --debug-dump=do-not-use-debuginfod\n\
- When following links, do not query debuginfod servers\n"));
-#endif
- fprintf (stream, _("\
- --dwarf-depth=N Do not display DIEs at depth N or greater\n"));
- fprintf (stream, _("\
- --dwarf-start=N Display DIEs starting at offset N\n"));
-#ifdef ENABLE_LIBCTF
- fprintf (stream, _("\
- --ctf=<number|name> Display CTF info from section <number|name>\n"));
- fprintf (stream, _("\
- --ctf-parent=<name> Use CTF archive member <name> as the CTF parent\n"));
- fprintf (stream, _("\
- --ctf-symbols=<number|name>\n\
- Use section <number|name> as the CTF external symtab\n"));
- fprintf (stream, _("\
- --ctf-strings=<number|name>\n\
- Use section <number|name> as the CTF external strtab\n"));
-#endif
- fprintf (stream, _("\
- --sframe[=NAME] Display SFrame info from section NAME, (default '.sframe')\n"));
-
-#ifdef SUPPORT_DISASSEMBLY
- fprintf (stream, _("\
- -i --instruction-dump=<number|name>\n\
- Disassemble the contents of section <number|name>\n"));
-#endif
- fprintf (stream, _("\
- -I --histogram Display histogram of bucket list lengths\n"));
- fprintf (stream, _("\
- -W --wide Allow output width to exceed 80 characters\n"));
- fprintf (stream, _("\
- -T --silent-truncation If a symbol name is truncated, do not add [...] suffix\n"));
- fprintf (stream, _("\
- @<file> Read options from <file>\n"));
- fprintf (stream, _("\
- -H --help Display this information\n"));
- fprintf (stream, _("\
- -v --version Display the version number of readelf\n"));
-
- if (REPORT_BUGS_TO[0] && stream == stdout)
- fprintf (stdout, _("Report bugs to %s\n"), REPORT_BUGS_TO);
-
- exit (stream == stdout ? 0 : 1);
-}
-
-/* Record the fact that the user wants the contents of section number
- SECTION to be displayed using the method(s) encoded as flags bits
- in TYPE. Note, TYPE can be zero if we are creating the array for
- the first time. */
-
-static void
-request_dump_bynumber (struct dump_data *dumpdata,
- unsigned int section, dump_type type)
-{
- if (section >= dumpdata->num_dump_sects)
- {
- dump_type * new_dump_sects;
-
- new_dump_sects = (dump_type *) calloc (section + 1,
- sizeof (* new_dump_sects));
-
- if (new_dump_sects == NULL)
- error (_("Out of memory allocating dump request table.\n"));
- else
- {
- if (dumpdata->dump_sects)
- {
- /* Copy current flag settings. */
- memcpy (new_dump_sects, dumpdata->dump_sects,
- dumpdata->num_dump_sects * sizeof (* new_dump_sects));
-
- free (dumpdata->dump_sects);
- }
-
- dumpdata->dump_sects = new_dump_sects;
- dumpdata->num_dump_sects = section + 1;
- }
- }
-
- if (dumpdata->dump_sects)
- dumpdata->dump_sects[section] |= type;
-}
-
-/* Request a dump by section name. */
-
-static void
-request_dump_byname (const char * section, dump_type type)
-{
- struct dump_list_entry * new_request;
-
- new_request = (struct dump_list_entry *)
- malloc (sizeof (struct dump_list_entry));
- if (!new_request)
- error (_("Out of memory allocating dump request table.\n"));
-
- new_request->name = strdup (section);
- if (!new_request->name)
- error (_("Out of memory allocating dump request table.\n"));
-
- new_request->type = type;
-
- new_request->next = dump_sects_byname;
- dump_sects_byname = new_request;
-}
-
-static inline void
-request_dump (struct dump_data *dumpdata, dump_type type)
-{
- int section;
- char * cp;
-
- do_dump = true;
- section = strtoul (optarg, & cp, 0);
-
- if (! *cp && section >= 0)
- request_dump_bynumber (dumpdata, section, type);
- else
- request_dump_byname (optarg, type);
-}
-
-static void
-parse_args (struct dump_data *dumpdata, int argc, char ** argv)
-{
- int c;
-
- if (argc < 2)
- usage (stderr);
-
- while ((c = getopt_long
- (argc, argv, "ACDHILNPR:STU:VWXacdeghi:j:lnp:rstuvw::x:z", options, NULL)) != EOF)
- {
- switch (c)
- {
- case 0:
- /* Long options. */
- break;
- case 'H':
- usage (stdout);
- break;
-
- case 'a':
- do_syms = true;
- do_reloc = true;
- do_unwind = true;
- do_dynamic = true;
- do_header = true;
- do_sections = true;
- do_section_groups = true;
- do_segments = true;
- do_version = true;
- do_histogram = true;
- do_arch = true;
- do_notes = true;
- break;
-
- case 'g':
- do_section_groups = true;
- break;
- case 't':
- case 'N':
- do_sections = true;
- do_section_details = true;
- break;
- case 'e':
- do_header = true;
- do_sections = true;
- do_segments = true;
- break;
- case 'A':
- do_arch = true;
- break;
- case 'D':
- do_using_dynamic = true;
- break;
- case 'r':
- do_reloc = true;
- break;
- case 'u':
- do_unwind = true;
- break;
- case 'h':
- do_header = true;
- break;
- case 'l':
- do_segments = true;
- break;
- case 's':
- do_syms = true;
- break;
- case 'S':
- do_sections = true;
- break;
- case 'd':
- do_dynamic = true;
- break;
- case 'I':
- do_histogram = true;
- break;
- case 'n':
- do_notes = true;
- break;
- case 'c':
- do_archive_index = true;
- break;
- case 'L':
- do_checks = true;
- break;
- case 'P':
- process_links = true;
- do_follow_links = true;
- dump_any_debugging = true;
- break;
- case 'j':
- request_dump (dumpdata, AUTO_DUMP);
- break;
- case 'x':
- request_dump (dumpdata, HEX_DUMP);
- break;
- case 'p':
- request_dump (dumpdata, STRING_DUMP);
- break;
- case 'R':
- request_dump (dumpdata, RELOC_DUMP);
- break;
- case 'z':
- decompress_dumps = true;
- break;
- case 'w':
- if (optarg == NULL)
- {
- do_debugging = true;
- do_dump = true;
- dump_any_debugging = true;
- dwarf_select_sections_all ();
- }
- else
- {
- do_debugging = false;
- if (dwarf_select_sections_by_letters (optarg))
- {
- do_dump = true;
- dump_any_debugging = true;
- }
- }
- break;
- case OPTION_DEBUG_DUMP:
- if (optarg == NULL)
- {
- do_dump = true;
- do_debugging = true;
- dump_any_debugging = true;
- dwarf_select_sections_all ();
- }
- else
- {
- do_debugging = false;
- if (dwarf_select_sections_by_names (optarg))
- {
- do_dump = true;
- dump_any_debugging = true;
- }
- }
- break;
- case OPTION_DWARF_DEPTH:
- {
- char *cp;
-
- dwarf_cutoff_level = strtoul (optarg, & cp, 0);
- }
- break;
- case OPTION_DWARF_START:
- {
- char *cp;
-
- dwarf_start_die = strtoul (optarg, & cp, 0);
- }
- break;
- case OPTION_DWARF_CHECK:
- dwarf_check = true;
- break;
- case OPTION_CTF_DUMP:
- do_ctf = true;
- request_dump (dumpdata, CTF_DUMP);
- break;
- case OPTION_CTF_SYMBOLS:
- free (dump_ctf_symtab_name);
- dump_ctf_symtab_name = strdup (optarg);
- break;
- case OPTION_CTF_STRINGS:
- free (dump_ctf_strtab_name);
- dump_ctf_strtab_name = strdup (optarg);
- break;
- case OPTION_CTF_PARENT:
- free (dump_ctf_parent_name);
- dump_ctf_parent_name = strdup (optarg);
- break;
- case OPTION_SFRAME_DUMP:
- do_sframe = true;
- /* Providing section name is optional. request_dump (), however,
- thrives on non NULL optarg. Handle it explicitly here. */
- if (optarg != NULL)
- request_dump (dumpdata, SFRAME_DUMP);
- else
- {
- do_dump = true;
- const char *sframe_sec_name = strdup (".sframe");
- request_dump_byname (sframe_sec_name, SFRAME_DUMP);
- }
- break;
- case OPTION_DYN_SYMS:
- do_dyn_syms = true;
- break;
- case OPTION_LTO_SYMS:
- do_lto_syms = true;
- break;
- case 'X':
- extra_sym_info = true;
- break;
- case OPTION_NO_EXTRA_SYM_INFO:
- extra_sym_info = false;
- break;
-
-#ifdef SUPPORT_DISASSEMBLY
- case 'i':
- request_dump (dumpdata, DISASS_DUMP);
- break;
-#endif
- case 'v':
- print_version (program_name);
- break;
- case 'V':
- do_version = true;
- break;
- case 'W':
- do_wide = true;
- break;
- case 'T':
- do_not_show_symbol_truncation = true;
- break;
- case 'C':
- do_demangle = true;
- if (optarg != NULL)
- {
- enum demangling_styles style;
-
- style = cplus_demangle_name_to_style (optarg);
- if (style == unknown_demangling)
- error (_("unknown demangling style `%s'"), optarg);
-
- cplus_demangle_set_style (style);
- }
- break;
- case OPTION_NO_DEMANGLING:
- do_demangle = false;
- break;
- case OPTION_RECURSE_LIMIT:
- demangle_flags &= ~ DMGL_NO_RECURSE_LIMIT;
- break;
- case OPTION_NO_RECURSE_LIMIT:
- demangle_flags |= DMGL_NO_RECURSE_LIMIT;
- break;
- case OPTION_WITH_SYMBOL_VERSIONS:
- /* Ignored for backward compatibility. */
- break;
-
- case 'U':
- if (optarg == NULL)
- error (_("Missing arg to -U/--unicode")); /* Can this happen ? */
- else if (streq (optarg, "default") || streq (optarg, "d"))
- unicode_display = unicode_default;
- else if (streq (optarg, "locale") || streq (optarg, "l"))
- unicode_display = unicode_locale;
- else if (streq (optarg, "escape") || streq (optarg, "e"))
- unicode_display = unicode_escape;
- else if (streq (optarg, "invalid") || streq (optarg, "i"))
- unicode_display = unicode_invalid;
- else if (streq (optarg, "hex") || streq (optarg, "x"))
- unicode_display = unicode_hex;
- else if (streq (optarg, "highlight") || streq (optarg, "h"))
- unicode_display = unicode_highlight;
- else
- error (_("invalid argument to -U/--unicode: %s"), optarg);
- break;
-
- case OPTION_SYM_BASE:
- sym_base = 0;
- if (optarg != NULL)
- {
- sym_base = strtoul (optarg, NULL, 0);
- switch (sym_base)
- {
- case 0:
- case 8:
- case 10:
- case 16:
- break;
-
- default:
- sym_base = 0;
- break;
- }
- }
- break;
-
- default:
- /* xgettext:c-format */
- error (_("Invalid option '-%c'\n"), c);
- /* Fall through. */
- case '?':
- usage (stderr);
- }
- }
-
- if (!do_dynamic && !do_syms && !do_reloc && !do_unwind && !do_sections
- && !do_segments && !do_header && !do_dump && !do_version
- && !do_histogram && !do_debugging && !do_arch && !do_notes
- && !do_section_groups && !do_archive_index
- && !do_dyn_syms && !do_lto_syms)
- {
- if (do_checks)
- {
- check_all = true;
- do_dynamic = do_syms = do_reloc = do_unwind = do_sections = true;
- do_segments = do_header = do_dump = do_version = true;
- do_histogram = do_debugging = do_arch = do_notes = true;
- do_section_groups = do_archive_index = do_dyn_syms = true;
- do_lto_syms = true;
- }
- else
- usage (stderr);
- }
-}
-
-static const char *
-get_elf_class (unsigned int elf_class)
-{
- static char buff[32];
-
- switch (elf_class)
- {
- case ELFCLASSNONE: return _("none");
- case ELFCLASS32: return "ELF32";
- case ELFCLASS64: return "ELF64";
- default:
- snprintf (buff, sizeof (buff), _("<unknown: %x>"), elf_class);
- return buff;
- }
-}
-
-static const char *
-get_data_encoding (unsigned int encoding)
-{
- static char buff[32];
-
- switch (encoding)
- {
- case ELFDATANONE: return _("none");
- case ELFDATA2LSB: return _("2's complement, little endian");
- case ELFDATA2MSB: return _("2's complement, big endian");
- default:
- snprintf (buff, sizeof (buff), _("<unknown: %x>"), encoding);
- return buff;
- }
-}
-
-static bool
-check_magic_number (Filedata * filedata, Elf_Internal_Ehdr * header)
-{
- if (header->e_ident[EI_MAG0] == ELFMAG0
- && header->e_ident[EI_MAG1] == ELFMAG1
- && header->e_ident[EI_MAG2] == ELFMAG2
- && header->e_ident[EI_MAG3] == ELFMAG3)
- return true;
-
- /* Some compilers produce object files that are not in the ELF file format.
- As an aid to users of readelf, try to identify these cases and suggest
- alternative tools.
-
- FIXME: It is not clear if all four bytes are used as constant magic
- valus by all compilers. It may be necessary to recode this function if
- different tools use different length sequences. */
-
- static struct
- {
- unsigned char magic[4];
- const char * obj_message;
- const char * ar_message;
- }
- known_magic[] =
- {
- { { 'B', 'C', 0xc0, 0xde },
- N_("This is a LLVM bitcode file - try using llvm-bcanalyzer\n"),
- N_("This is a LLVM bitcode file - try extracting and then using llvm-bcanalyzer\n")
- },
- { { 'g', 'o', ' ', 'o' },
- N_("This is a GO binary file - try using 'go tool objdump' or 'go tool nm'\n"),
- NULL
- }
- };
- int i;
-
- for (i = ARRAY_SIZE (known_magic); i--;)
- {
- if (header->e_ident[EI_MAG0] == known_magic[i].magic[0]
- && header->e_ident[EI_MAG1] == known_magic[i].magic[1]
- && header->e_ident[EI_MAG2] == known_magic[i].magic[2]
- && header->e_ident[EI_MAG3] == known_magic[i].magic[3])
- {
- /* Some compiler's analyzer tools do not handle archives,
- so we provide two different kinds of error message. */
- if (filedata->archive_file_size > 0
- && known_magic[i].ar_message != NULL)
- error ("%s", known_magic[i].ar_message);
- else
- error ("%s", known_magic[i].obj_message);
- return false;
- }
- }
-
- error (_("Not an ELF file - it has the wrong magic bytes at the start\n"));
- return false;
-}
-
-/* Decode the data held in 'filedata->file_header'. */
-
-static bool
-process_file_header (Filedata * filedata)
-{
- Elf_Internal_Ehdr * header = & filedata->file_header;
-
- if (! check_magic_number (filedata, header))
- return false;
-
- if (! filedata->is_separate)
- init_dwarf_regnames_by_elf_machine_code (header->e_machine);
-
- if (do_header)
- {
- unsigned i;
-
- if (filedata->is_separate)
- printf (_("ELF Header in linked file '%s':\n"), filedata->file_name);
- else
- printf (_("ELF Header:\n"));
- printf (_(" Magic: "));
- for (i = 0; i < EI_NIDENT; i++)
- printf ("%2.2x ", header->e_ident[i]);
- printf ("\n");
- printf (_(" Class: %s\n"),
- get_elf_class (header->e_ident[EI_CLASS]));
- printf (_(" Data: %s\n"),
- get_data_encoding (header->e_ident[EI_DATA]));
- printf (_(" Version: %d%s\n"),
- header->e_ident[EI_VERSION],
- (header->e_ident[EI_VERSION] == EV_CURRENT
- ? _(" (current)")
- : (header->e_ident[EI_VERSION] != EV_NONE
- ? _(" <unknown>")
- : "")));
- printf (_(" OS/ABI: %s\n"),
- get_osabi_name (filedata, header->e_ident[EI_OSABI]));
- printf (_(" ABI Version: %d\n"),
- header->e_ident[EI_ABIVERSION]);
- printf (_(" Type: %s\n"),
- get_file_type (filedata));
- printf (_(" Machine: %s\n"),
- get_machine_name (header->e_machine));
- printf (_(" Version: 0x%lx\n"),
- header->e_version);
-
- printf (_(" Entry point address: "));
- print_vma (header->e_entry, PREFIX_HEX);
- printf (_("\n Start of program headers: "));
- print_vma (header->e_phoff, DEC);
- printf (_(" (bytes into file)\n Start of section headers: "));
- print_vma (header->e_shoff, DEC);
- printf (_(" (bytes into file)\n"));
-
- printf (_(" Flags: 0x%lx%s\n"),
- header->e_flags,
- get_machine_flags (filedata, header->e_flags, header->e_machine));
- printf (_(" Size of this header: %u (bytes)\n"),
- header->e_ehsize);
- printf (_(" Size of program headers: %u (bytes)\n"),
- header->e_phentsize);
- printf (_(" Number of program headers: %u"),
- header->e_phnum);
- if (filedata->section_headers != NULL
- && header->e_phnum == PN_XNUM
- && filedata->section_headers[0].sh_info != 0)
- printf (" (%u)", filedata->section_headers[0].sh_info);
- putc ('\n', stdout);
- printf (_(" Size of section headers: %u (bytes)\n"),
- header->e_shentsize);
- printf (_(" Number of section headers: %u"),
- header->e_shnum);
- if (filedata->section_headers != NULL && header->e_shnum == SHN_UNDEF)
- {
- header->e_shnum = filedata->section_headers[0].sh_size;
- printf (" (%u)", header->e_shnum);
- }
- putc ('\n', stdout);
- printf (_(" Section header string table index: %u"),
- header->e_shstrndx);
- if (filedata->section_headers != NULL
- && header->e_shstrndx == (SHN_XINDEX & 0xffff))
- {
- header->e_shstrndx = filedata->section_headers[0].sh_link;
- printf (" (%u)", header->e_shstrndx);
- }
- if (header->e_shstrndx != SHN_UNDEF
- && header->e_shstrndx >= header->e_shnum)
- {
- header->e_shstrndx = SHN_UNDEF;
- printf (_(" <corrupt: out of range>"));
- }
- putc ('\n', stdout);
- }
-
- if (filedata->section_headers != NULL)
- {
- if (header->e_phnum == PN_XNUM
- && filedata->section_headers[0].sh_info != 0)
- {
- /* Throw away any cached read of PN_XNUM headers. */
- free (filedata->program_headers);
- filedata->program_headers = NULL;
- header->e_phnum = filedata->section_headers[0].sh_info;
- }
- if (header->e_shnum == SHN_UNDEF)
- header->e_shnum = filedata->section_headers[0].sh_size;
- if (header->e_shstrndx == (SHN_XINDEX & 0xffff))
- header->e_shstrndx = filedata->section_headers[0].sh_link;
- if (header->e_shstrndx >= header->e_shnum)
- header->e_shstrndx = SHN_UNDEF;
- }
-
- return true;
-}
-
-/* Read in the program headers from FILEDATA and store them in PHEADERS.
- Returns TRUE upon success, FALSE otherwise. Loads 32-bit headers. */
-
-static bool
-get_32bit_program_headers (Filedata * filedata, Elf_Internal_Phdr * pheaders)
-{
- Elf32_External_Phdr * phdrs;
- Elf32_External_Phdr * external;
- Elf_Internal_Phdr * internal;
- unsigned int i;
- unsigned int size = filedata->file_header.e_phentsize;
- unsigned int num = filedata->file_header.e_phnum;
-
- /* PR binutils/17531: Cope with unexpected section header sizes. */
- if (size == 0 || num == 0)
- return false;
- if (size < sizeof * phdrs)
- {
- error (_("The e_phentsize field in the ELF header is less than the size of an ELF program header\n"));
- return false;
- }
- if (size > sizeof * phdrs)
- warn (_("The e_phentsize field in the ELF header is larger than the size of an ELF program header\n"));
-
- phdrs = (Elf32_External_Phdr *) get_data (NULL, filedata, filedata->file_header.e_phoff,
- size, num, _("program headers"));
- if (phdrs == NULL)
- return false;
-
- for (i = 0, internal = pheaders, external = phdrs;
- i < filedata->file_header.e_phnum;
- i++, internal++, external++)
- {
- internal->p_type = BYTE_GET (external->p_type);
- internal->p_offset = BYTE_GET (external->p_offset);
- internal->p_vaddr = BYTE_GET (external->p_vaddr);
- internal->p_paddr = BYTE_GET (external->p_paddr);
- internal->p_filesz = BYTE_GET (external->p_filesz);
- internal->p_memsz = BYTE_GET (external->p_memsz);
- internal->p_flags = BYTE_GET (external->p_flags);
- internal->p_align = BYTE_GET (external->p_align);
- }
-
- free (phdrs);
- return true;
-}
-
-/* Read in the program headers from FILEDATA and store them in PHEADERS.
- Returns TRUE upon success, FALSE otherwise. Loads 64-bit headers. */
-
-static bool
-get_64bit_program_headers (Filedata * filedata, Elf_Internal_Phdr * pheaders)
-{
- Elf64_External_Phdr * phdrs;
- Elf64_External_Phdr * external;
- Elf_Internal_Phdr * internal;
- unsigned int i;
- unsigned int size = filedata->file_header.e_phentsize;
- unsigned int num = filedata->file_header.e_phnum;
-
- /* PR binutils/17531: Cope with unexpected section header sizes. */
- if (size == 0 || num == 0)
- return false;
- if (size < sizeof * phdrs)
- {
- error (_("The e_phentsize field in the ELF header is less than the size of an ELF program header\n"));
- return false;
- }
- if (size > sizeof * phdrs)
- warn (_("The e_phentsize field in the ELF header is larger than the size of an ELF program header\n"));
-
- phdrs = (Elf64_External_Phdr *) get_data (NULL, filedata, filedata->file_header.e_phoff,
- size, num, _("program headers"));
- if (!phdrs)
- return false;
-
- for (i = 0, internal = pheaders, external = phdrs;
- i < filedata->file_header.e_phnum;
- i++, internal++, external++)
- {
- internal->p_type = BYTE_GET (external->p_type);
- internal->p_flags = BYTE_GET (external->p_flags);
- internal->p_offset = BYTE_GET (external->p_offset);
- internal->p_vaddr = BYTE_GET (external->p_vaddr);
- internal->p_paddr = BYTE_GET (external->p_paddr);
- internal->p_filesz = BYTE_GET (external->p_filesz);
- internal->p_memsz = BYTE_GET (external->p_memsz);
- internal->p_align = BYTE_GET (external->p_align);
- }
-
- free (phdrs);
- return true;
-}
-
-/* Returns TRUE if the program headers were read into `program_headers'. */
-
-static bool
-get_program_headers (Filedata * filedata)
-{
- Elf_Internal_Phdr * phdrs;
-
- /* Check cache of prior read. */
- if (filedata->program_headers != NULL)
- return true;
-
- /* Be kind to memory checkers by looking for
- e_phnum values which we know must be invalid. */
- if (filedata->file_header.e_phnum
- * (is_32bit_elf ? sizeof (Elf32_External_Phdr) : sizeof (Elf64_External_Phdr))
- >= filedata->file_size)
- {
- error (_("Too many program headers - %#x - the file is not that big\n"),
- filedata->file_header.e_phnum);
- return false;
- }
-
- phdrs = (Elf_Internal_Phdr *) cmalloc (filedata->file_header.e_phnum,
- sizeof (Elf_Internal_Phdr));
- if (phdrs == NULL)
- {
- error (_("Out of memory reading %u program headers\n"),
- filedata->file_header.e_phnum);
- return false;
- }
-
- if (is_32bit_elf
- ? get_32bit_program_headers (filedata, phdrs)
- : get_64bit_program_headers (filedata, phdrs))
- {
- filedata->program_headers = phdrs;
- return true;
- }
-
- free (phdrs);
- return false;
-}
-
-/* Print program header info and locate dynamic section. */
-
-static void
-process_program_headers (Filedata * filedata)
-{
- Elf_Internal_Phdr * segment;
- unsigned int i;
- Elf_Internal_Phdr * previous_load = NULL;
-
- if (filedata->file_header.e_phnum == 0)
- {
- /* PR binutils/12467. */
- if (filedata->file_header.e_phoff != 0)
- warn (_("possibly corrupt ELF header - it has a non-zero program"
- " header offset, but no program headers\n"));
- else if (do_segments)
- {
- if (filedata->is_separate)
- printf (_("\nThere are no program headers in linked file '%s'.\n"),
- filedata->file_name);
- else
- printf (_("\nThere are no program headers in this file.\n"));
- }
- goto no_headers;
- }
-
- if (do_segments && !do_header)
- {
- if (filedata->is_separate)
- printf ("\nIn linked file '%s' the ELF file type is %s\n",
- filedata->file_name, get_file_type (filedata));
- else
- printf (_("\nElf file type is %s\n"), get_file_type (filedata));
- printf (_("Entry point 0x%" PRIx64 "\n"),
- filedata->file_header.e_entry);
- printf (ngettext ("There is %d program header,"
- " starting at offset %" PRIu64 "\n",
- "There are %d program headers,"
- " starting at offset %" PRIu64 "\n",
- filedata->file_header.e_phnum),
- filedata->file_header.e_phnum,
- filedata->file_header.e_phoff);
- }
-
- if (! get_program_headers (filedata))
- goto no_headers;
-
- if (do_segments)
- {
- if (filedata->file_header.e_phnum > 1)
- printf (_("\nProgram Headers:\n"));
- else
- printf (_("\nProgram Headers:\n"));
-
- if (is_32bit_elf)
- printf
- (_(" Type Offset VirtAddr PhysAddr FileSiz MemSiz Flg Align\n"));
- else if (do_wide)
- printf
- (_(" Type Offset VirtAddr PhysAddr FileSiz MemSiz Flg Align\n"));
- else
- {
- printf
- (_(" Type Offset VirtAddr PhysAddr\n"));
- printf
- (_(" FileSiz MemSiz Flags Align\n"));
- }
- }
-
- uint64_t dynamic_addr = 0;
- uint64_t dynamic_size = 0;
- for (i = 0, segment = filedata->program_headers;
- i < filedata->file_header.e_phnum;
- i++, segment++)
- {
- if (do_segments)
- {
- printf (" %-14.14s ", get_segment_type (filedata, segment->p_type));
-
- if (is_32bit_elf)
- {
- printf ("0x%6.6lx ", (unsigned long) segment->p_offset);
- printf ("0x%8.8lx ", (unsigned long) segment->p_vaddr);
- printf ("0x%8.8lx ", (unsigned long) segment->p_paddr);
- printf ("0x%5.5lx ", (unsigned long) segment->p_filesz);
- printf ("0x%5.5lx ", (unsigned long) segment->p_memsz);
- printf ("%c%c%c ",
- (segment->p_flags & PF_R ? 'R' : ' '),
- (segment->p_flags & PF_W ? 'W' : ' '),
- (segment->p_flags & PF_X ? 'E' : ' '));
- printf ("%#lx", (unsigned long) segment->p_align);
- }
- else if (do_wide)
- {
- if ((unsigned long) segment->p_offset == segment->p_offset)
- printf ("0x%6.6lx ", (unsigned long) segment->p_offset);
- else
- {
- print_vma (segment->p_offset, FULL_HEX);
- putchar (' ');
- }
-
- print_vma (segment->p_vaddr, FULL_HEX);
- putchar (' ');
- print_vma (segment->p_paddr, FULL_HEX);
- putchar (' ');
-
- if ((unsigned long) segment->p_filesz == segment->p_filesz)
- printf ("0x%6.6lx ", (unsigned long) segment->p_filesz);
- else
- {
- print_vma (segment->p_filesz, FULL_HEX);
- putchar (' ');
- }
-
- if ((unsigned long) segment->p_memsz == segment->p_memsz)
- printf ("0x%6.6lx", (unsigned long) segment->p_memsz);
- else
- {
- print_vma (segment->p_memsz, FULL_HEX);
- }
-
- printf (" %c%c%c ",
- (segment->p_flags & PF_R ? 'R' : ' '),
- (segment->p_flags & PF_W ? 'W' : ' '),
- (segment->p_flags & PF_X ? 'E' : ' '));
-
- if ((unsigned long) segment->p_align == segment->p_align)
- printf ("%#lx", (unsigned long) segment->p_align);
- else
- {
- print_vma (segment->p_align, PREFIX_HEX);
- }
- }
- else
- {
- print_vma (segment->p_offset, FULL_HEX);
- putchar (' ');
- print_vma (segment->p_vaddr, FULL_HEX);
- putchar (' ');
- print_vma (segment->p_paddr, FULL_HEX);
- printf ("\n ");
- print_vma (segment->p_filesz, FULL_HEX);
- putchar (' ');
- print_vma (segment->p_memsz, FULL_HEX);
- printf (" %c%c%c ",
- (segment->p_flags & PF_R ? 'R' : ' '),
- (segment->p_flags & PF_W ? 'W' : ' '),
- (segment->p_flags & PF_X ? 'E' : ' '));
- print_vma (segment->p_align, PREFIX_HEX);
- }
-
- putc ('\n', stdout);
- }
-
- switch (segment->p_type)
- {
- case PT_LOAD:
-#if 0 /* Do not warn about out of order PT_LOAD segments. Although officially
- required by the ELF standard, several programs, including the Linux
- kernel, make use of non-ordered segments. */
- if (previous_load
- && previous_load->p_vaddr > segment->p_vaddr)
- error (_("LOAD segments must be sorted in order of increasing VirtAddr\n"));
-#endif
- if (segment->p_memsz < segment->p_filesz)
- error (_("the segment's file size is larger than its memory size\n"));
- previous_load = segment;
- break;
-
- case PT_PHDR:
- /* PR 20815 - Verify that the program header is loaded into memory. */
- if (i > 0 && previous_load != NULL)
- error (_("the PHDR segment must occur before any LOAD segment\n"));
- if (filedata->file_header.e_machine != EM_PARISC)
- {
- unsigned int j;
-
- for (j = 1; j < filedata->file_header.e_phnum; j++)
- {
- Elf_Internal_Phdr *load = filedata->program_headers + j;
- if (load->p_type == PT_LOAD
- && load->p_offset <= segment->p_offset
- && (load->p_offset + load->p_filesz
- >= segment->p_offset + segment->p_filesz)
- && load->p_vaddr <= segment->p_vaddr
- && (load->p_vaddr + load->p_filesz
- >= segment->p_vaddr + segment->p_filesz))
- break;
- }
- if (j == filedata->file_header.e_phnum)
- error (_("the PHDR segment is not covered by a LOAD segment\n"));
- }
- break;
-
- case PT_DYNAMIC:
- if (dynamic_addr)
- error (_("more than one dynamic segment\n"));
-
- /* By default, assume that the .dynamic section is the first
- section in the DYNAMIC segment. */
- dynamic_addr = segment->p_offset;
- dynamic_size = segment->p_filesz;
-
- /* Try to locate the .dynamic section. If there is
- a section header table, we can easily locate it. */
- if (filedata->section_headers != NULL)
- {
- Elf_Internal_Shdr * sec;
-
- sec = find_section (filedata, ".dynamic");
- if (sec == NULL || sec->sh_size == 0)
- {
- /* A corresponding .dynamic section is expected, but on
- IA-64/OpenVMS it is OK for it to be missing. */
- if (!is_ia64_vms (filedata))
- error (_("no .dynamic section in the dynamic segment\n"));
- break;
- }
-
- if (sec->sh_type == SHT_NOBITS)
- {
- dynamic_addr = 0;
- dynamic_size = 0;
- break;
- }
-
- dynamic_addr = sec->sh_offset;
- dynamic_size = sec->sh_size;
-
- /* The PT_DYNAMIC segment, which is used by the run-time
- loader, should exactly match the .dynamic section. */
- if (do_checks
- && (dynamic_addr != segment->p_offset
- || dynamic_size != segment->p_filesz))
- warn (_("\
-the .dynamic section is not the same as the dynamic segment\n"));
- }
-
- /* PR binutils/17512: Avoid corrupt dynamic section info in the
- segment. Check this after matching against the section headers
- so we don't warn on debuginfo file (which have NOBITS .dynamic
- sections). */
- if (dynamic_addr > filedata->file_size
- || (dynamic_size > filedata->file_size - dynamic_addr))
- {
- error (_("the dynamic segment offset + size exceeds the size of the file\n"));
- dynamic_addr = 0;
- dynamic_size = 0;
- }
- break;
-
- case PT_INTERP:
- if (segment->p_offset >= filedata->file_size
- || segment->p_filesz > filedata->file_size - segment->p_offset
- || segment->p_filesz - 1 >= (size_t) -2
- || fseek64 (filedata->handle,
- filedata->archive_file_offset + segment->p_offset,
- SEEK_SET))
- error (_("Unable to find program interpreter name\n"));
- else
- {
- size_t len = segment->p_filesz;
- free (filedata->program_interpreter);
- filedata->program_interpreter = xmalloc (len + 1);
- len = fread (filedata->program_interpreter, 1, len,
- filedata->handle);
- filedata->program_interpreter[len] = 0;
-
- if (do_segments)
- printf (_(" [Requesting program interpreter: %s]\n"),
- filedata->program_interpreter);
- }
- break;
- }
- }
-
- if (do_segments
- && filedata->section_headers != NULL
- && filedata->string_table != NULL)
- {
- printf (_("\n Section to Segment mapping:\n"));
- printf (_(" Segment Sections...\n"));
-
- for (i = 0; i < filedata->file_header.e_phnum; i++)
- {
- unsigned int j;
- Elf_Internal_Shdr * section;
-
- segment = filedata->program_headers + i;
- section = filedata->section_headers + 1;
-
- printf (" %2.2d ", i);
-
- for (j = 1; j < filedata->file_header.e_shnum; j++, section++)
- {
- if (!ELF_TBSS_SPECIAL (section, segment)
- && ELF_SECTION_IN_SEGMENT_STRICT (section, segment))
- printf ("%s ", printable_section_name (filedata, section));
- }
-
- putc ('\n',stdout);
- }
- }
-
- filedata->dynamic_addr = dynamic_addr;
- filedata->dynamic_size = dynamic_size ? dynamic_size : 1;
- return;
-
- no_headers:
- filedata->dynamic_addr = 0;
- filedata->dynamic_size = 1;
-}
-
-
-/* Find the file offset corresponding to VMA by using the program headers. */
-
-static int64_t
-offset_from_vma (Filedata * filedata, uint64_t vma, uint64_t size)
-{
- Elf_Internal_Phdr * seg;
-
- if (! get_program_headers (filedata))
- {
- warn (_("Cannot interpret virtual addresses without program headers.\n"));
- return (long) vma;
- }
-
- for (seg = filedata->program_headers;
- seg < filedata->program_headers + filedata->file_header.e_phnum;
- ++seg)
- {
- if (seg->p_type != PT_LOAD)
- continue;
-
- if (vma >= (seg->p_vaddr & -seg->p_align)
- && vma + size <= seg->p_vaddr + seg->p_filesz)
- return vma - seg->p_vaddr + seg->p_offset;
- }
-
- warn (_("Virtual address %#" PRIx64
- " not located in any PT_LOAD segment.\n"), vma);
- return vma;
-}
-
-
-/* Allocate memory and load the sections headers into FILEDATA->filedata->section_headers.
- If PROBE is true, this is just a probe and we do not generate any error
- messages if the load fails. */
-
-static bool
-get_32bit_section_headers (Filedata * filedata, bool probe)
-{
- Elf32_External_Shdr * shdrs;
- Elf_Internal_Shdr * internal;
- unsigned int i;
- unsigned int size = filedata->file_header.e_shentsize;
- unsigned int num = probe ? 1 : filedata->file_header.e_shnum;
-
- /* PR binutils/17531: Cope with unexpected section header sizes. */
- if (size == 0 || num == 0)
- return false;
-
- /* The section header cannot be at the start of the file - that is
- where the ELF file header is located. A file with absolutely no
- sections in it will use a shoff of 0. */
- if (filedata->file_header.e_shoff == 0)
- return false;
-
- if (size < sizeof * shdrs)
- {
- if (! probe)
- error (_("The e_shentsize field in the ELF header is less than the size of an ELF section header\n"));
- return false;
- }
- if (!probe && size > sizeof * shdrs)
- warn (_("The e_shentsize field in the ELF header is larger than the size of an ELF section header\n"));
-
- shdrs = (Elf32_External_Shdr *) get_data (NULL, filedata, filedata->file_header.e_shoff,
- size, num,
- probe ? NULL : _("section headers"));
- if (shdrs == NULL)
- return false;
-
- filedata->section_headers = (Elf_Internal_Shdr *)
- cmalloc (num, sizeof (Elf_Internal_Shdr));
- if (filedata->section_headers == NULL)
- {
- if (!probe)
- error (_("Out of memory reading %u section headers\n"), num);
- free (shdrs);
- return false;
- }
-
- for (i = 0, internal = filedata->section_headers;
- i < num;
- i++, internal++)
- {
- internal->sh_name = BYTE_GET (shdrs[i].sh_name);
- internal->sh_type = BYTE_GET (shdrs[i].sh_type);
- internal->sh_flags = BYTE_GET (shdrs[i].sh_flags);
- internal->sh_addr = BYTE_GET (shdrs[i].sh_addr);
- internal->sh_offset = BYTE_GET (shdrs[i].sh_offset);
- internal->sh_size = BYTE_GET (shdrs[i].sh_size);
- internal->sh_link = BYTE_GET (shdrs[i].sh_link);
- internal->sh_info = BYTE_GET (shdrs[i].sh_info);
- internal->sh_addralign = BYTE_GET (shdrs[i].sh_addralign);
- internal->sh_entsize = BYTE_GET (shdrs[i].sh_entsize);
- if (!probe && internal->sh_link > num)
- warn (_("Section %u has an out of range sh_link value of %u\n"), i, internal->sh_link);
- if (!probe && internal->sh_flags & SHF_INFO_LINK && internal->sh_info > num)
- warn (_("Section %u has an out of range sh_info value of %u\n"), i, internal->sh_info);
- }
-
- free (shdrs);
- return true;
-}
-
-/* Like get_32bit_section_headers, except that it fetches 64-bit headers. */
-
-static bool
-get_64bit_section_headers (Filedata * filedata, bool probe)
-{
- Elf64_External_Shdr * shdrs;
- Elf_Internal_Shdr * internal;
- unsigned int i;
- unsigned int size = filedata->file_header.e_shentsize;
- unsigned int num = probe ? 1 : filedata->file_header.e_shnum;
-
- /* PR binutils/17531: Cope with unexpected section header sizes. */
- if (size == 0 || num == 0)
- return false;
-
- /* The section header cannot be at the start of the file - that is
- where the ELF file header is located. A file with absolutely no
- sections in it will use a shoff of 0. */
- if (filedata->file_header.e_shoff == 0)
- return false;
-
- if (size < sizeof * shdrs)
- {
- if (! probe)
- error (_("The e_shentsize field in the ELF header is less than the size of an ELF section header\n"));
- return false;
- }
-
- if (! probe && size > sizeof * shdrs)
- warn (_("The e_shentsize field in the ELF header is larger than the size of an ELF section header\n"));
-
- shdrs = (Elf64_External_Shdr *) get_data (NULL, filedata,
- filedata->file_header.e_shoff,
- size, num,
- probe ? NULL : _("section headers"));
- if (shdrs == NULL)
- return false;
-
- filedata->section_headers = (Elf_Internal_Shdr *)
- cmalloc (num, sizeof (Elf_Internal_Shdr));
- if (filedata->section_headers == NULL)
- {
- if (! probe)
- error (_("Out of memory reading %u section headers\n"), num);
- free (shdrs);
- return false;
- }
-
- for (i = 0, internal = filedata->section_headers;
- i < num;
- i++, internal++)
- {
- internal->sh_name = BYTE_GET (shdrs[i].sh_name);
- internal->sh_type = BYTE_GET (shdrs[i].sh_type);
- internal->sh_flags = BYTE_GET (shdrs[i].sh_flags);
- internal->sh_addr = BYTE_GET (shdrs[i].sh_addr);
- internal->sh_size = BYTE_GET (shdrs[i].sh_size);
- internal->sh_entsize = BYTE_GET (shdrs[i].sh_entsize);
- internal->sh_link = BYTE_GET (shdrs[i].sh_link);
- internal->sh_info = BYTE_GET (shdrs[i].sh_info);
- internal->sh_offset = BYTE_GET (shdrs[i].sh_offset);
- internal->sh_addralign = BYTE_GET (shdrs[i].sh_addralign);
- if (!probe && internal->sh_link > num)
- warn (_("Section %u has an out of range sh_link value of %u\n"), i, internal->sh_link);
- if (!probe && internal->sh_flags & SHF_INFO_LINK && internal->sh_info > num)
- warn (_("Section %u has an out of range sh_info value of %u\n"), i, internal->sh_info);
- }
-
- free (shdrs);
- return true;
-}
-
-static bool
-get_section_headers (Filedata *filedata, bool probe)
-{
- if (filedata->section_headers != NULL)
- return true;
-
- if (is_32bit_elf)
- return get_32bit_section_headers (filedata, probe);
- else
- return get_64bit_section_headers (filedata, probe);
-}
-
-static Elf_Internal_Sym *
-get_32bit_elf_symbols (Filedata *filedata,
- Elf_Internal_Shdr *section,
- uint64_t *num_syms_return)
-{
- uint64_t number = 0;
- Elf32_External_Sym * esyms = NULL;
- Elf_External_Sym_Shndx * shndx = NULL;
- Elf_Internal_Sym * isyms = NULL;
- Elf_Internal_Sym * psym;
- unsigned int j;
- elf_section_list * entry;
-
- if (section->sh_size == 0)
- {
- if (num_syms_return != NULL)
- * num_syms_return = 0;
- return NULL;
- }
-
- /* Run some sanity checks first. */
- if (section->sh_entsize == 0 || section->sh_entsize > section->sh_size)
- {
- error (_("Section %s has an invalid sh_entsize of %#" PRIx64 "\n"),
- printable_section_name (filedata, section),
- section->sh_entsize);
- goto exit_point;
- }
-
- if (section->sh_size > filedata->file_size)
- {
- error (_("Section %s has an invalid sh_size of %#" PRIx64 "\n"),
- printable_section_name (filedata, section),
- section->sh_size);
- goto exit_point;
- }
-
- number = section->sh_size / section->sh_entsize;
-
- if (number * sizeof (Elf32_External_Sym) > section->sh_size + 1)
- {
- error (_("Size (%#" PRIx64 ") of section %s "
- "is not a multiple of its sh_entsize (%#" PRIx64 ")\n"),
- section->sh_size,
- printable_section_name (filedata, section),
- section->sh_entsize);
- goto exit_point;
- }
-
- esyms = (Elf32_External_Sym *) get_data (NULL, filedata, section->sh_offset, 1,
- section->sh_size, _("symbols"));
- if (esyms == NULL)
- goto exit_point;
-
- shndx = NULL;
- for (entry = filedata->symtab_shndx_list; entry != NULL; entry = entry->next)
- {
- if (entry->hdr->sh_link != (size_t) (section - filedata->section_headers))
- continue;
-
- if (shndx != NULL)
- {
- error (_("Multiple symbol table index sections associated with the same symbol section\n"));
- free (shndx);
- }
-
- shndx = (Elf_External_Sym_Shndx *) get_data (NULL, filedata,
- entry->hdr->sh_offset,
- 1, entry->hdr->sh_size,
- _("symbol table section indices"));
- if (shndx == NULL)
- goto exit_point;
-
- /* PR17531: file: heap-buffer-overflow */
- if (entry->hdr->sh_size / sizeof (Elf_External_Sym_Shndx) < number)
- {
- error (_("Index section %s has an sh_size of %#" PRIx64 " - expected %#" PRIx64 "\n"),
- printable_section_name (filedata, entry->hdr),
- entry->hdr->sh_size,
- section->sh_size);
- goto exit_point;
- }
- }
-
- isyms = (Elf_Internal_Sym *) cmalloc (number, sizeof (Elf_Internal_Sym));
-
- if (isyms == NULL)
- {
- error (_("Out of memory reading %" PRIu64 " symbols\n"), number);
- goto exit_point;
- }
-
- for (j = 0, psym = isyms; j < number; j++, psym++)
- {
- psym->st_name = BYTE_GET (esyms[j].st_name);
- psym->st_value = BYTE_GET (esyms[j].st_value);
- psym->st_size = BYTE_GET (esyms[j].st_size);
- psym->st_shndx = BYTE_GET (esyms[j].st_shndx);
- if (psym->st_shndx == (SHN_XINDEX & 0xffff) && shndx != NULL)
- psym->st_shndx
- = byte_get ((unsigned char *) &shndx[j], sizeof (shndx[j]));
- else if (psym->st_shndx >= (SHN_LORESERVE & 0xffff))
- psym->st_shndx += SHN_LORESERVE - (SHN_LORESERVE & 0xffff);
- psym->st_info = BYTE_GET (esyms[j].st_info);
- psym->st_other = BYTE_GET (esyms[j].st_other);
- }
-
- exit_point:
- free (shndx);
- free (esyms);
-
- if (num_syms_return != NULL)
- * num_syms_return = isyms == NULL ? 0 : number;
-
- return isyms;
-}
-
-static Elf_Internal_Sym *
-get_64bit_elf_symbols (Filedata *filedata,
- Elf_Internal_Shdr *section,
- uint64_t *num_syms_return)
-{
- uint64_t number = 0;
- Elf64_External_Sym * esyms = NULL;
- Elf_External_Sym_Shndx * shndx = NULL;
- Elf_Internal_Sym * isyms = NULL;
- Elf_Internal_Sym * psym;
- unsigned int j;
- elf_section_list * entry;
-
- if (section->sh_size == 0)
- {
- if (num_syms_return != NULL)
- * num_syms_return = 0;
- return NULL;
- }
-
- /* Run some sanity checks first. */
- if (section->sh_entsize == 0 || section->sh_entsize > section->sh_size)
- {
- error (_("Section %s has an invalid sh_entsize of %#" PRIx64 "\n"),
- printable_section_name (filedata, section),
- section->sh_entsize);
- goto exit_point;
- }
-
- if (section->sh_size > filedata->file_size)
- {
- error (_("Section %s has an invalid sh_size of %#" PRIx64 "\n"),
- printable_section_name (filedata, section),
- section->sh_size);
- goto exit_point;
- }
-
- number = section->sh_size / section->sh_entsize;
-
- if (number * sizeof (Elf64_External_Sym) > section->sh_size + 1)
- {
- error (_("Size (%#" PRIx64 ") of section %s "
- "is not a multiple of its sh_entsize (%#" PRIx64 ")\n"),
- section->sh_size,
- printable_section_name (filedata, section),
- section->sh_entsize);
- goto exit_point;
- }
-
- esyms = (Elf64_External_Sym *) get_data (NULL, filedata, section->sh_offset, 1,
- section->sh_size, _("symbols"));
- if (!esyms)
- goto exit_point;
-
- shndx = NULL;
- for (entry = filedata->symtab_shndx_list; entry != NULL; entry = entry->next)
- {
- if (entry->hdr->sh_link != (size_t) (section - filedata->section_headers))
- continue;
-
- if (shndx != NULL)
- {
- error (_("Multiple symbol table index sections associated with the same symbol section\n"));
- free (shndx);
- }
-
- shndx = (Elf_External_Sym_Shndx *) get_data (NULL, filedata,
- entry->hdr->sh_offset,
- 1, entry->hdr->sh_size,
- _("symbol table section indices"));
- if (shndx == NULL)
- goto exit_point;
-
- /* PR17531: file: heap-buffer-overflow */
- if (entry->hdr->sh_size / sizeof (Elf_External_Sym_Shndx) < number)
- {
- error (_("Index section %s has an sh_size of %#" PRIx64 " - expected %#" PRIx64 "\n"),
- printable_section_name (filedata, entry->hdr),
- entry->hdr->sh_size,
- section->sh_size);
- goto exit_point;
- }
- }
-
- isyms = (Elf_Internal_Sym *) cmalloc (number, sizeof (Elf_Internal_Sym));
-
- if (isyms == NULL)
- {
- error (_("Out of memory reading %" PRIu64 " symbols\n"), number);
- goto exit_point;
- }
-
- for (j = 0, psym = isyms; j < number; j++, psym++)
- {
- psym->st_name = BYTE_GET (esyms[j].st_name);
- psym->st_info = BYTE_GET (esyms[j].st_info);
- psym->st_other = BYTE_GET (esyms[j].st_other);
- psym->st_shndx = BYTE_GET (esyms[j].st_shndx);
-
- if (psym->st_shndx == (SHN_XINDEX & 0xffff) && shndx != NULL)
- psym->st_shndx
- = byte_get ((unsigned char *) &shndx[j], sizeof (shndx[j]));
- else if (psym->st_shndx >= (SHN_LORESERVE & 0xffff))
- psym->st_shndx += SHN_LORESERVE - (SHN_LORESERVE & 0xffff);
-
- psym->st_value = BYTE_GET (esyms[j].st_value);
- psym->st_size = BYTE_GET (esyms[j].st_size);
- }
-
- exit_point:
- free (shndx);
- free (esyms);
-
- if (num_syms_return != NULL)
- * num_syms_return = isyms == NULL ? 0 : number;
-
- return isyms;
-}
-
-static Elf_Internal_Sym *
-get_elf_symbols (Filedata *filedata,
- Elf_Internal_Shdr *section,
- uint64_t *num_syms_return)
-{
- if (is_32bit_elf)
- return get_32bit_elf_symbols (filedata, section, num_syms_return);
- else
- return get_64bit_elf_symbols (filedata, section, num_syms_return);
-}
-
-static const char *
-get_elf_section_flags (Filedata * filedata, uint64_t sh_flags)
-{
- static char buff[1024];
- char * p = buff;
- unsigned int field_size = is_32bit_elf ? 8 : 16;
- signed int sindex;
- unsigned int size = sizeof (buff) - (field_size + 4 + 1);
- uint64_t os_flags = 0;
- uint64_t proc_flags = 0;
- uint64_t unknown_flags = 0;
- static const struct
- {
- const char * str;
- unsigned int len;
- }
- flags [] =
- {
- /* 0 */ { STRING_COMMA_LEN ("WRITE") },
- /* 1 */ { STRING_COMMA_LEN ("ALLOC") },
- /* 2 */ { STRING_COMMA_LEN ("EXEC") },
- /* 3 */ { STRING_COMMA_LEN ("MERGE") },
- /* 4 */ { STRING_COMMA_LEN ("STRINGS") },
- /* 5 */ { STRING_COMMA_LEN ("INFO LINK") },
- /* 6 */ { STRING_COMMA_LEN ("LINK ORDER") },
- /* 7 */ { STRING_COMMA_LEN ("OS NONCONF") },
- /* 8 */ { STRING_COMMA_LEN ("GROUP") },
- /* 9 */ { STRING_COMMA_LEN ("TLS") },
- /* IA-64 specific. */
- /* 10 */ { STRING_COMMA_LEN ("SHORT") },
- /* 11 */ { STRING_COMMA_LEN ("NORECOV") },
- /* IA-64 OpenVMS specific. */
- /* 12 */ { STRING_COMMA_LEN ("VMS_GLOBAL") },
- /* 13 */ { STRING_COMMA_LEN ("VMS_OVERLAID") },
- /* 14 */ { STRING_COMMA_LEN ("VMS_SHARED") },
- /* 15 */ { STRING_COMMA_LEN ("VMS_VECTOR") },
- /* 16 */ { STRING_COMMA_LEN ("VMS_ALLOC_64BIT") },
- /* 17 */ { STRING_COMMA_LEN ("VMS_PROTECTED") },
- /* Generic. */
- /* 18 */ { STRING_COMMA_LEN ("EXCLUDE") },
- /* SPARC specific. */
- /* 19 */ { STRING_COMMA_LEN ("ORDERED") },
- /* 20 */ { STRING_COMMA_LEN ("COMPRESSED") },
- /* ARM specific. */
- /* 21 */ { STRING_COMMA_LEN ("ENTRYSECT") },
- /* 22 */ { STRING_COMMA_LEN ("ARM_PURECODE") },
- /* 23 */ { STRING_COMMA_LEN ("COMDEF") },
- /* GNU specific. */
- /* 24 */ { STRING_COMMA_LEN ("GNU_MBIND") },
- /* VLE specific. */
- /* 25 */ { STRING_COMMA_LEN ("VLE") },
- /* GNU specific. */
- /* 26 */ { STRING_COMMA_LEN ("GNU_RETAIN") },
- };
-
- if (do_section_details)
- p += sprintf (p, "[%*.*lx]: ",
- field_size, field_size, (unsigned long) sh_flags);
-
- while (sh_flags)
- {
- uint64_t flag;
-
- flag = sh_flags & - sh_flags;
- sh_flags &= ~ flag;
-
- if (do_section_details)
- {
- switch (flag)
- {
- case SHF_WRITE: sindex = 0; break;
- case SHF_ALLOC: sindex = 1; break;
- case SHF_EXECINSTR: sindex = 2; break;
- case SHF_MERGE: sindex = 3; break;
- case SHF_STRINGS: sindex = 4; break;
- case SHF_INFO_LINK: sindex = 5; break;
- case SHF_LINK_ORDER: sindex = 6; break;
- case SHF_OS_NONCONFORMING: sindex = 7; break;
- case SHF_GROUP: sindex = 8; break;
- case SHF_TLS: sindex = 9; break;
- case SHF_EXCLUDE: sindex = 18; break;
- case SHF_COMPRESSED: sindex = 20; break;
-
- default:
- sindex = -1;
- switch (filedata->file_header.e_machine)
- {
- case EM_IA_64:
- if (flag == SHF_IA_64_SHORT)
- sindex = 10;
- else if (flag == SHF_IA_64_NORECOV)
- sindex = 11;
- else if (filedata->file_header.e_ident[EI_OSABI] == ELFOSABI_OPENVMS)
- switch (flag)
- {
- case SHF_IA_64_VMS_GLOBAL: sindex = 12; break;
- case SHF_IA_64_VMS_OVERLAID: sindex = 13; break;
- case SHF_IA_64_VMS_SHARED: sindex = 14; break;
- case SHF_IA_64_VMS_VECTOR: sindex = 15; break;
- case SHF_IA_64_VMS_ALLOC_64BIT: sindex = 16; break;
- case SHF_IA_64_VMS_PROTECTED: sindex = 17; break;
- default: break;
- }
- break;
-
- case EM_386:
- case EM_IAMCU:
- case EM_X86_64:
- case EM_L1OM:
- case EM_K1OM:
- case EM_OLD_SPARCV9:
- case EM_SPARC32PLUS:
- case EM_SPARCV9:
- case EM_SPARC:
- if (flag == SHF_ORDERED)
- sindex = 19;
- break;
-
- case EM_ARM:
- switch (flag)
- {
- case SHF_ENTRYSECT: sindex = 21; break;
- case SHF_ARM_PURECODE: sindex = 22; break;
- case SHF_COMDEF: sindex = 23; break;
- default: break;
- }
- break;
- case EM_PPC:
- if (flag == SHF_PPC_VLE)
- sindex = 25;
- break;
- default:
- break;
- }
-
- switch (filedata->file_header.e_ident[EI_OSABI])
- {
- case ELFOSABI_GNU:
- case ELFOSABI_FREEBSD:
- if (flag == SHF_GNU_RETAIN)
- sindex = 26;
- /* Fall through */
- case ELFOSABI_NONE:
- if (flag == SHF_GNU_MBIND)
- /* We should not recognize SHF_GNU_MBIND for
- ELFOSABI_NONE, but binutils as of 2019-07-23 did
- not set the EI_OSABI header byte. */
- sindex = 24;
- break;
- default:
- break;
- }
- break;
- }
-
- if (sindex != -1)
- {
- if (p != buff + field_size + 4)
- {
- if (size < (10 + 2))
- {
- warn (_("Internal error: not enough buffer room for section flag info"));
- return _("<unknown>");
- }
- size -= 2;
- *p++ = ',';
- *p++ = ' ';
- }
-
- size -= flags [sindex].len;
- p = stpcpy (p, flags [sindex].str);
- }
- else if (flag & SHF_MASKOS)
- os_flags |= flag;
- else if (flag & SHF_MASKPROC)
- proc_flags |= flag;
- else
- unknown_flags |= flag;
- }
- else
- {
- switch (flag)
- {
- case SHF_WRITE: *p = 'W'; break;
- case SHF_ALLOC: *p = 'A'; break;
- case SHF_EXECINSTR: *p = 'X'; break;
- case SHF_MERGE: *p = 'M'; break;
- case SHF_STRINGS: *p = 'S'; break;
- case SHF_INFO_LINK: *p = 'I'; break;
- case SHF_LINK_ORDER: *p = 'L'; break;
- case SHF_OS_NONCONFORMING: *p = 'O'; break;
- case SHF_GROUP: *p = 'G'; break;
- case SHF_TLS: *p = 'T'; break;
- case SHF_EXCLUDE: *p = 'E'; break;
- case SHF_COMPRESSED: *p = 'C'; break;
-
- default:
- if ((filedata->file_header.e_machine == EM_X86_64
- || filedata->file_header.e_machine == EM_L1OM
- || filedata->file_header.e_machine == EM_K1OM)
- && flag == SHF_X86_64_LARGE)
- *p = 'l';
- else if (filedata->file_header.e_machine == EM_ARM
- && flag == SHF_ARM_PURECODE)
- *p = 'y';
- else if (filedata->file_header.e_machine == EM_PPC
- && flag == SHF_PPC_VLE)
- *p = 'v';
- else if (flag & SHF_MASKOS)
- {
- switch (filedata->file_header.e_ident[EI_OSABI])
- {
- case ELFOSABI_GNU:
- case ELFOSABI_FREEBSD:
- if (flag == SHF_GNU_RETAIN)
- {
- *p = 'R';
- break;
- }
- /* Fall through */
- case ELFOSABI_NONE:
- if (flag == SHF_GNU_MBIND)
- {
- /* We should not recognize SHF_GNU_MBIND for
- ELFOSABI_NONE, but binutils as of 2019-07-23 did
- not set the EI_OSABI header byte. */
- *p = 'D';
- break;
- }
- /* Fall through */
- default:
- *p = 'o';
- sh_flags &= ~SHF_MASKOS;
- break;
- }
- }
- else if (flag & SHF_MASKPROC)
- {
- *p = 'p';
- sh_flags &= ~ SHF_MASKPROC;
- }
- else
- *p = 'x';
- break;
- }
- p++;
- }
- }
-
- if (do_section_details)
- {
- if (os_flags)
- {
- if (p != buff + field_size + 4)
- {
- if (size < 2 + 5 + field_size + 1)
- {
- warn (_("Internal error: not enough buffer room for section flag info"));
- return _("<unknown>");
- }
- size -= 2;
- *p++ = ',';
- *p++ = ' ';
- }
- size -= 5 + field_size;
- p += sprintf (p, "OS (%*.*lx)", field_size, field_size,
- (unsigned long) os_flags);
- }
- if (proc_flags)
- {
- if (p != buff + field_size + 4)
- {
- if (size < 2 + 7 + field_size + 1)
- {
- warn (_("Internal error: not enough buffer room for section flag info"));
- return _("<unknown>");
- }
- size -= 2;
- *p++ = ',';
- *p++ = ' ';
- }
- size -= 7 + field_size;
- p += sprintf (p, "PROC (%*.*lx)", field_size, field_size,
- (unsigned long) proc_flags);
- }
- if (unknown_flags)
- {
- if (p != buff + field_size + 4)
- {
- if (size < 2 + 10 + field_size + 1)
- {
- warn (_("Internal error: not enough buffer room for section flag info"));
- return _("<unknown>");
- }
- size -= 2;
- *p++ = ',';
- *p++ = ' ';
- }
- size -= 10 + field_size;
- p += sprintf (p, _("UNKNOWN (%*.*lx)"), field_size, field_size,
- (unsigned long) unknown_flags);
- }
- }
-
- *p = '\0';
- return buff;
-}
-
-static unsigned int ATTRIBUTE_WARN_UNUSED_RESULT
-get_compression_header (Elf_Internal_Chdr *chdr, unsigned char *buf,
- uint64_t size)
-{
- if (is_32bit_elf)
- {
- Elf32_External_Chdr *echdr = (Elf32_External_Chdr *) buf;
-
- if (size < sizeof (* echdr))
- {
- error (_("Compressed section is too small even for a compression header\n"));
- return 0;
- }
-
- chdr->ch_type = BYTE_GET (echdr->ch_type);
- chdr->ch_size = BYTE_GET (echdr->ch_size);
- chdr->ch_addralign = BYTE_GET (echdr->ch_addralign);
- return sizeof (*echdr);
- }
- else
- {
- Elf64_External_Chdr *echdr = (Elf64_External_Chdr *) buf;
-
- if (size < sizeof (* echdr))
- {
- error (_("Compressed section is too small even for a compression header\n"));
- return 0;
- }
-
- chdr->ch_type = BYTE_GET (echdr->ch_type);
- chdr->ch_size = BYTE_GET (echdr->ch_size);
- chdr->ch_addralign = BYTE_GET (echdr->ch_addralign);
- return sizeof (*echdr);
- }
-}
-
-static bool
-process_section_headers (Filedata * filedata)
-{
- Elf_Internal_Shdr * section;
- unsigned int i;
-
- if (filedata->file_header.e_shnum == 0)
- {
- /* PR binutils/12467. */
- if (filedata->file_header.e_shoff != 0)
- {
- warn (_("possibly corrupt ELF file header - it has a non-zero"
- " section header offset, but no section headers\n"));
- return false;
- }
- else if (do_sections)
- printf (_("\nThere are no sections in this file.\n"));
-
- return true;
- }
-
- if (do_sections && !do_header)
- {
- if (filedata->is_separate && process_links)
- printf (_("In linked file '%s': "), filedata->file_name);
- if (! filedata->is_separate || process_links)
- printf (ngettext ("There is %d section header, "
- "starting at offset %#" PRIx64 ":\n",
- "There are %d section headers, "
- "starting at offset %#" PRIx64 ":\n",
- filedata->file_header.e_shnum),
- filedata->file_header.e_shnum,
- filedata->file_header.e_shoff);
- }
-
- if (!get_section_headers (filedata, false))
- return false;
-
- /* Read in the string table, so that we have names to display. */
- if (filedata->file_header.e_shstrndx != SHN_UNDEF
- && filedata->file_header.e_shstrndx < filedata->file_header.e_shnum)
- {
- section = filedata->section_headers + filedata->file_header.e_shstrndx;
-
- if (section->sh_size != 0)
- {
- filedata->string_table = (char *) get_data (NULL, filedata, section->sh_offset,
- 1, section->sh_size,
- _("string table"));
-
- filedata->string_table_length = filedata->string_table != NULL ? section->sh_size : 0;
- }
- }
-
- /* Scan the sections for the dynamic symbol table
- and dynamic string table and debug sections. */
- eh_addr_size = is_32bit_elf ? 4 : 8;
- switch (filedata->file_header.e_machine)
- {
- case EM_MIPS:
- case EM_MIPS_RS3_LE:
- /* The 64-bit MIPS EABI uses a combination of 32-bit ELF and 64-bit
- FDE addresses. However, the ABI also has a semi-official ILP32
- variant for which the normal FDE address size rules apply.
-
- GCC 4.0 marks EABI64 objects with a dummy .gcc_compiled_longXX
- section, where XX is the size of longs in bits. Unfortunately,
- earlier compilers provided no way of distinguishing ILP32 objects
- from LP64 objects, so if there's any doubt, we should assume that
- the official LP64 form is being used. */
- if ((filedata->file_header.e_flags & EF_MIPS_ABI) == EF_MIPS_ABI_EABI64
- && find_section (filedata, ".gcc_compiled_long32") == NULL)
- eh_addr_size = 8;
- break;
-
- case EM_H8_300:
- case EM_H8_300H:
- switch (filedata->file_header.e_flags & EF_H8_MACH)
- {
- case E_H8_MACH_H8300:
- case E_H8_MACH_H8300HN:
- case E_H8_MACH_H8300SN:
- case E_H8_MACH_H8300SXN:
- eh_addr_size = 2;
- break;
- case E_H8_MACH_H8300H:
- case E_H8_MACH_H8300S:
- case E_H8_MACH_H8300SX:
- eh_addr_size = 4;
- break;
- }
- break;
-
- case EM_M32C_OLD:
- case EM_M32C:
- switch (filedata->file_header.e_flags & EF_M32C_CPU_MASK)
- {
- case EF_M32C_CPU_M16C:
- eh_addr_size = 2;
- break;
- }
- break;
- }
-
-#define CHECK_ENTSIZE_VALUES(section, i, size32, size64) \
- do \
- { \
- uint64_t expected_entsize = is_32bit_elf ? size32 : size64; \
- if (section->sh_entsize != expected_entsize) \
- { \
- error (_("Section %d has invalid sh_entsize of %" PRIx64 "\n"), \
- i, section->sh_entsize); \
- error (_("(Using the expected size of %" PRIx64 " for the rest of this dump)\n"), \
- expected_entsize); \
- section->sh_entsize = expected_entsize; \
- } \
- } \
- while (0)
-
-#define CHECK_ENTSIZE(section, i, type) \
- CHECK_ENTSIZE_VALUES (section, i, sizeof (Elf32_External_##type), \
- sizeof (Elf64_External_##type))
-
- for (i = 0, section = filedata->section_headers;
- i < filedata->file_header.e_shnum;
- i++, section++)
- {
- const char *name = printable_section_name (filedata, section);
-
- /* Run some sanity checks on the headers and
- possibly fill in some file data as well. */
- switch (section->sh_type)
- {
- case SHT_DYNSYM:
- if (filedata->dynamic_symbols != NULL)
- {
- error (_("File contains multiple dynamic symbol tables\n"));
- continue;
- }
-
- CHECK_ENTSIZE (section, i, Sym);
- filedata->dynamic_symbols
- = get_elf_symbols (filedata, section, &filedata->num_dynamic_syms);
- filedata->dynamic_symtab_section = section;
- break;
-
- case SHT_STRTAB:
- if (streq (name, ".dynstr"))
- {
- if (filedata->dynamic_strings != NULL)
- {
- error (_("File contains multiple dynamic string tables\n"));
- continue;
- }
-
- filedata->dynamic_strings
- = (char *) get_data (NULL, filedata, section->sh_offset,
- 1, section->sh_size, _("dynamic strings"));
- filedata->dynamic_strings_length
- = filedata->dynamic_strings == NULL ? 0 : section->sh_size;
- filedata->dynamic_strtab_section = section;
- }
- break;
-
- case SHT_SYMTAB_SHNDX:
- {
- elf_section_list * entry = xmalloc (sizeof * entry);
-
- entry->hdr = section;
- entry->next = filedata->symtab_shndx_list;
- filedata->symtab_shndx_list = entry;
- }
- break;
-
- case SHT_SYMTAB:
- CHECK_ENTSIZE (section, i, Sym);
- break;
-
- case SHT_GROUP:
- CHECK_ENTSIZE_VALUES (section, i, GRP_ENTRY_SIZE, GRP_ENTRY_SIZE);
- break;
-
- case SHT_REL:
- CHECK_ENTSIZE (section, i, Rel);
- if (do_checks && section->sh_size == 0)
- warn (_("Section '%s': zero-sized relocation section\n"), name);
- break;
-
- case SHT_RELA:
- CHECK_ENTSIZE (section, i, Rela);
- if (do_checks && section->sh_size == 0)
- warn (_("Section '%s': zero-sized relocation section\n"), name);
- break;
-
- case SHT_RELR:
- CHECK_ENTSIZE (section, i, Relr);
- break;
-
- case SHT_NOTE:
- case SHT_PROGBITS:
- /* Having a zero sized section is not illegal according to the
- ELF standard, but it might be an indication that something
- is wrong. So issue a warning if we are running in lint mode. */
- if (do_checks && section->sh_size == 0)
- warn (_("Section '%s': has a size of zero - is this intended ?\n"), name);
- break;
-
- default:
- break;
- }
-
- if ((do_debugging || do_debug_info || do_debug_abbrevs
- || do_debug_lines || do_debug_pubnames || do_debug_pubtypes
- || do_debug_aranges || do_debug_frames || do_debug_macinfo
- || do_debug_str || do_debug_str_offsets || do_debug_loc
- || do_debug_ranges
- || do_debug_addr || do_debug_cu_index || do_debug_links)
- && (startswith (name, ".debug_")
- || startswith (name, ".zdebug_")))
- {
- if (name[1] == 'z')
- name += sizeof (".zdebug_") - 1;
- else
- name += sizeof (".debug_") - 1;
-
- if (do_debugging
- || (do_debug_info && startswith (name, "info"))
- || (do_debug_info && startswith (name, "types"))
- || (do_debug_abbrevs && startswith (name, "abbrev"))
- || (do_debug_lines && strcmp (name, "line") == 0)
- || (do_debug_lines && startswith (name, "line."))
- || (do_debug_pubnames && startswith (name, "pubnames"))
- || (do_debug_pubtypes && startswith (name, "pubtypes"))
- || (do_debug_pubnames && startswith (name, "gnu_pubnames"))
- || (do_debug_pubtypes && startswith (name, "gnu_pubtypes"))
- || (do_debug_aranges && startswith (name, "aranges"))
- || (do_debug_ranges && startswith (name, "ranges"))
- || (do_debug_ranges && startswith (name, "rnglists"))
- || (do_debug_frames && startswith (name, "frame"))
- || (do_debug_macinfo && startswith (name, "macinfo"))
- || (do_debug_macinfo && startswith (name, "macro"))
- || (do_debug_str && startswith (name, "str"))
- || (do_debug_links && startswith (name, "sup"))
- || (do_debug_str_offsets && startswith (name, "str_offsets"))
- || (do_debug_loc && startswith (name, "loc"))
- || (do_debug_loc && startswith (name, "loclists"))
- || (do_debug_addr && startswith (name, "addr"))
- || (do_debug_cu_index && startswith (name, "cu_index"))
- || (do_debug_cu_index && startswith (name, "tu_index"))
- )
- request_dump_bynumber (&filedata->dump, i, DEBUG_DUMP);
- }
- /* Linkonce section to be combined with .debug_info at link time. */
- else if ((do_debugging || do_debug_info)
- && startswith (name, ".gnu.linkonce.wi."))
- request_dump_bynumber (&filedata->dump, i, DEBUG_DUMP);
- else if (do_debug_frames && streq (name, ".eh_frame"))
- request_dump_bynumber (&filedata->dump, i, DEBUG_DUMP);
- else if (do_debug_frames && streq (name, ".eh_frame_hdr"))
- request_dump_bynumber (&filedata->dump, i, DEBUG_DUMP);
- else if (do_gdb_index && (streq (name, ".gdb_index")
- || streq (name, ".debug_names")))
- request_dump_bynumber (&filedata->dump, i, DEBUG_DUMP);
- /* Trace sections for Itanium VMS. */
- else if ((do_debugging || do_trace_info || do_trace_abbrevs
- || do_trace_aranges)
- && startswith (name, ".trace_"))
- {
- name += sizeof (".trace_") - 1;
-
- if (do_debugging
- || (do_trace_info && streq (name, "info"))
- || (do_trace_abbrevs && streq (name, "abbrev"))
- || (do_trace_aranges && streq (name, "aranges"))
- )
- request_dump_bynumber (&filedata->dump, i, DEBUG_DUMP);
- }
- else if ((do_debugging || do_debug_links)
- && (startswith (name, ".gnu_debuglink")
- || startswith (name, ".gnu_debugaltlink")))
- request_dump_bynumber (&filedata->dump, i, DEBUG_DUMP);
- }
-
- if (! do_sections)
- return true;
-
- if (filedata->is_separate && ! process_links)
- return true;
-
- if (filedata->is_separate)
- printf (_("\nSection Headers in linked file '%s':\n"), filedata->file_name);
- else if (filedata->file_header.e_shnum > 1)
- printf (_("\nSection Headers:\n"));
- else
- printf (_("\nSection Header:\n"));
-
- if (is_32bit_elf)
- {
- if (do_section_details)
- {
- printf (_(" [Nr] Name\n"));
- printf (_(" Type Addr Off Size ES Lk Inf Al\n"));
- }
- else
- printf
- (_(" [Nr] Name Type Addr Off Size ES Flg Lk Inf Al\n"));
- }
- else if (do_wide)
- {
- if (do_section_details)
- {
- printf (_(" [Nr] Name\n"));
- printf (_(" Type Address Off Size ES Lk Inf Al\n"));
- }
- else
- printf
- (_(" [Nr] Name Type Address Off Size ES Flg Lk Inf Al\n"));
- }
- else
- {
- if (do_section_details)
- {
- printf (_(" [Nr] Name\n"));
- printf (_(" Type Address Offset Link\n"));
- printf (_(" Size EntSize Info Align\n"));
- }
- else
- {
- printf (_(" [Nr] Name Type Address Offset\n"));
- printf (_(" Size EntSize Flags Link Info Align\n"));
- }
- }
-
- if (do_section_details)
- printf (_(" Flags\n"));
-
- for (i = 0, section = filedata->section_headers;
- i < filedata->file_header.e_shnum;
- i++, section++)
- {
- /* Run some sanity checks on the section header. */
-
- /* Check the sh_link field. */
- switch (section->sh_type)
- {
- case SHT_REL:
- case SHT_RELR:
- case SHT_RELA:
- if (section->sh_link == 0
- && (filedata->file_header.e_type == ET_EXEC
- || filedata->file_header.e_type == ET_DYN))
- /* A dynamic relocation section where all entries use a
- zero symbol index need not specify a symtab section. */
- break;
- /* Fall through. */
- case SHT_SYMTAB_SHNDX:
- case SHT_GROUP:
- case SHT_HASH:
- case SHT_GNU_HASH:
- case SHT_GNU_versym:
- if (section->sh_link == 0
- || section->sh_link >= filedata->file_header.e_shnum
- || (filedata->section_headers[section->sh_link].sh_type != SHT_SYMTAB
- && filedata->section_headers[section->sh_link].sh_type != SHT_DYNSYM))
- warn (_("[%2u]: Link field (%u) should index a symtab section.\n"),
- i, section->sh_link);
- break;
-
- case SHT_DYNAMIC:
- case SHT_SYMTAB:
- case SHT_DYNSYM:
- case SHT_GNU_verneed:
- case SHT_GNU_verdef:
- case SHT_GNU_LIBLIST:
- if (section->sh_link == 0
- || section->sh_link >= filedata->file_header.e_shnum
- || filedata->section_headers[section->sh_link].sh_type != SHT_STRTAB)
- warn (_("[%2u]: Link field (%u) should index a string section.\n"),
- i, section->sh_link);
- break;
-
- case SHT_INIT_ARRAY:
- case SHT_FINI_ARRAY:
- case SHT_PREINIT_ARRAY:
- if (section->sh_type < SHT_LOOS && section->sh_link != 0)
- warn (_("[%2u]: Unexpected value (%u) in link field.\n"),
- i, section->sh_link);
- break;
-
- default:
- /* FIXME: Add support for target specific section types. */
-#if 0 /* Currently we do not check other section types as there are too
- many special cases. Stab sections for example have a type
- of SHT_PROGBITS but an sh_link field that links to the .stabstr
- section. */
- if (section->sh_type < SHT_LOOS && section->sh_link != 0)
- warn (_("[%2u]: Unexpected value (%u) in link field.\n"),
- i, section->sh_link);
-#endif
- break;
- }
-
- /* Check the sh_info field. */
- switch (section->sh_type)
- {
- case SHT_REL:
- case SHT_RELA:
- if (section->sh_info == 0
- && (filedata->file_header.e_type == ET_EXEC
- || filedata->file_header.e_type == ET_DYN))
- /* Dynamic relocations apply to segments, so they do not
- need to specify the section they relocate. */
- break;
- if (section->sh_info == 0
- || section->sh_info >= filedata->file_header.e_shnum
- || (filedata->section_headers[section->sh_info].sh_type != SHT_PROGBITS
- && filedata->section_headers[section->sh_info].sh_type != SHT_NOBITS
- && filedata->section_headers[section->sh_info].sh_type != SHT_NOTE
- && filedata->section_headers[section->sh_info].sh_type != SHT_INIT_ARRAY
- && filedata->section_headers[section->sh_info].sh_type != SHT_FINI_ARRAY
- && filedata->section_headers[section->sh_info].sh_type != SHT_PREINIT_ARRAY
- /* FIXME: Are other section types valid ? */
- && filedata->section_headers[section->sh_info].sh_type < SHT_LOOS))
- warn (_("[%2u]: Info field (%u) should index a relocatable section.\n"),
- i, section->sh_info);
- break;
-
- case SHT_DYNAMIC:
- case SHT_HASH:
- case SHT_SYMTAB_SHNDX:
- case SHT_INIT_ARRAY:
- case SHT_FINI_ARRAY:
- case SHT_PREINIT_ARRAY:
- if (section->sh_info != 0)
- warn (_("[%2u]: Unexpected value (%u) in info field.\n"),
- i, section->sh_info);
- break;
-
- case SHT_GROUP:
- case SHT_SYMTAB:
- case SHT_DYNSYM:
- /* A symbol index - we assume that it is valid. */
- break;
-
- default:
- /* FIXME: Add support for target specific section types. */
- if (section->sh_type == SHT_NOBITS)
- /* NOBITS section headers with non-zero sh_info fields can be
- created when a binary is stripped of everything but its debug
- information. The stripped sections have their headers
- preserved but their types set to SHT_NOBITS. So do not check
- this type of section. */
- ;
- else if (section->sh_flags & SHF_INFO_LINK)
- {
- if (section->sh_info < 1 || section->sh_info >= filedata->file_header.e_shnum)
- warn (_("[%2u]: Expected link to another section in info field"), i);
- }
- else if (section->sh_type < SHT_LOOS
- && (section->sh_flags & SHF_GNU_MBIND) == 0
- && section->sh_info != 0)
- warn (_("[%2u]: Unexpected value (%u) in info field.\n"),
- i, section->sh_info);
- break;
- }
-
- /* Check the sh_size field. */
- if (section->sh_size > filedata->file_size
- && section->sh_type != SHT_NOBITS
- && section->sh_type != SHT_NULL
- && section->sh_type < SHT_LOOS)
- warn (_("Size of section %u is larger than the entire file!\n"), i);
-
- printf (" [%2u] ", i);
- if (do_section_details)
- printf ("%s\n ", printable_section_name (filedata, section));
- else
- print_symbol_name (-17, printable_section_name (filedata, section));
-
- printf (do_wide ? " %-15s " : " %-15.15s ",
- get_section_type_name (filedata, section->sh_type));
-
- if (is_32bit_elf)
- {
- const char * link_too_big = NULL;
-
- print_vma (section->sh_addr, LONG_HEX);
-
- printf ( " %6.6lx %6.6lx %2.2lx",
- (unsigned long) section->sh_offset,
- (unsigned long) section->sh_size,
- (unsigned long) section->sh_entsize);
-
- if (do_section_details)
- fputs (" ", stdout);
- else
- printf (" %3s ", get_elf_section_flags (filedata, section->sh_flags));
-
- if (section->sh_link >= filedata->file_header.e_shnum)
- {
- link_too_big = "";
- /* The sh_link value is out of range. Normally this indicates
- an error but it can have special values in Solaris binaries. */
- switch (filedata->file_header.e_machine)
- {
- case EM_386:
- case EM_IAMCU:
- case EM_X86_64:
- case EM_L1OM:
- case EM_K1OM:
- case EM_OLD_SPARCV9:
- case EM_SPARC32PLUS:
- case EM_SPARCV9:
- case EM_SPARC:
- if (section->sh_link == (SHN_BEFORE & 0xffff))
- link_too_big = "BEFORE";
- else if (section->sh_link == (SHN_AFTER & 0xffff))
- link_too_big = "AFTER";
- break;
- default:
- break;
- }
- }
-
- if (do_section_details)
- {
- if (link_too_big != NULL && * link_too_big)
- printf ("<%s> ", link_too_big);
- else
- printf ("%2u ", section->sh_link);
- printf ("%3u %2lu\n", section->sh_info,
- (unsigned long) section->sh_addralign);
- }
- else
- printf ("%2u %3u %2lu\n",
- section->sh_link,
- section->sh_info,
- (unsigned long) section->sh_addralign);
-
- if (link_too_big && ! * link_too_big)
- warn (_("section %u: sh_link value of %u is larger than the number of sections\n"),
- i, section->sh_link);
- }
- else if (do_wide)
- {
- print_vma (section->sh_addr, LONG_HEX);
-
- if ((long) section->sh_offset == section->sh_offset)
- printf (" %6.6lx", (unsigned long) section->sh_offset);
- else
- {
- putchar (' ');
- print_vma (section->sh_offset, LONG_HEX);
- }
-
- if ((unsigned long) section->sh_size == section->sh_size)
- printf (" %6.6lx", (unsigned long) section->sh_size);
- else
- {
- putchar (' ');
- print_vma (section->sh_size, LONG_HEX);
- }
-
- if ((unsigned long) section->sh_entsize == section->sh_entsize)
- printf (" %2.2lx", (unsigned long) section->sh_entsize);
- else
- {
- putchar (' ');
- print_vma (section->sh_entsize, LONG_HEX);
- }
-
- if (do_section_details)
- fputs (" ", stdout);
- else
- printf (" %3s ", get_elf_section_flags (filedata, section->sh_flags));
-
- printf ("%2u %3u ", section->sh_link, section->sh_info);
-
- if ((unsigned long) section->sh_addralign == section->sh_addralign)
- printf ("%2lu\n", (unsigned long) section->sh_addralign);
- else
- {
- print_vma (section->sh_addralign, DEC);
- putchar ('\n');
- }
- }
- else if (do_section_details)
- {
- putchar (' ');
- print_vma (section->sh_addr, LONG_HEX);
- if ((long) section->sh_offset == section->sh_offset)
- printf (" %16.16lx", (unsigned long) section->sh_offset);
- else
- {
- printf (" ");
- print_vma (section->sh_offset, LONG_HEX);
- }
- printf (" %u\n ", section->sh_link);
- print_vma (section->sh_size, LONG_HEX);
- putchar (' ');
- print_vma (section->sh_entsize, LONG_HEX);
-
- printf (" %-16u %lu\n",
- section->sh_info,
- (unsigned long) section->sh_addralign);
- }
- else
- {
- putchar (' ');
- print_vma (section->sh_addr, LONG_HEX);
- if ((long) section->sh_offset == section->sh_offset)
- printf (" %8.8lx", (unsigned long) section->sh_offset);
- else
- {
- printf (" ");
- print_vma (section->sh_offset, LONG_HEX);
- }
- printf ("\n ");
- print_vma (section->sh_size, LONG_HEX);
- printf (" ");
- print_vma (section->sh_entsize, LONG_HEX);
-
- printf (" %3s ", get_elf_section_flags (filedata, section->sh_flags));
-
- printf (" %2u %3u %lu\n",
- section->sh_link,
- section->sh_info,
- (unsigned long) section->sh_addralign);
- }
-
- if (do_section_details)
- {
- printf (" %s\n", get_elf_section_flags (filedata, section->sh_flags));
- if ((section->sh_flags & SHF_COMPRESSED) != 0)
- {
- /* Minimum section size is 12 bytes for 32-bit compression
- header + 12 bytes for compressed data header. */
- unsigned char buf[24];
-
- assert (sizeof (buf) >= sizeof (Elf64_External_Chdr));
- if (get_data (&buf, filedata, section->sh_offset, 1,
- sizeof (buf), _("compression header")))
- {
- Elf_Internal_Chdr chdr;
-
- if (get_compression_header (&chdr, buf, sizeof (buf)) == 0)
- printf (_(" [<corrupt>]\n"));
- else
- {
- if (chdr.ch_type == ch_compress_zlib)
- printf (" ZLIB, ");
- else if (chdr.ch_type == ch_compress_zstd)
- printf (" ZSTD, ");
- else
- printf (_(" [<unknown>: 0x%x], "),
- chdr.ch_type);
- print_vma (chdr.ch_size, LONG_HEX);
- printf (", %lu\n", (unsigned long) chdr.ch_addralign);
- }
- }
- }
- }
- }
-
- if (!do_section_details)
- {
- /* The ordering of the letters shown here matches the ordering of the
- corresponding SHF_xxx values, and hence the order in which these
- letters will be displayed to the user. */
- printf (_("Key to Flags:\n\
- W (write), A (alloc), X (execute), M (merge), S (strings), I (info),\n\
- L (link order), O (extra OS processing required), G (group), T (TLS),\n\
- C (compressed), x (unknown), o (OS specific), E (exclude),\n "));
- switch (filedata->file_header.e_ident[EI_OSABI])
- {
- case ELFOSABI_GNU:
- case ELFOSABI_FREEBSD:
- printf (_("R (retain), "));
- /* Fall through */
- case ELFOSABI_NONE:
- printf (_("D (mbind), "));
- break;
- default:
- break;
- }
- if (filedata->file_header.e_machine == EM_X86_64
- || filedata->file_header.e_machine == EM_L1OM
- || filedata->file_header.e_machine == EM_K1OM)
- printf (_("l (large), "));
- else if (filedata->file_header.e_machine == EM_ARM)
- printf (_("y (purecode), "));
- else if (filedata->file_header.e_machine == EM_PPC)
- printf (_("v (VLE), "));
- printf ("p (processor specific)\n");
- }
-
- return true;
-}
-
-static bool
-get_symtab (Filedata * filedata,
- Elf_Internal_Shdr * symsec,
- Elf_Internal_Sym ** symtab,
- uint64_t * nsyms,
- char ** strtab,
- uint64_t * strtablen)
-{
- *strtab = NULL;
- *strtablen = 0;
- *symtab = get_elf_symbols (filedata, symsec, nsyms);
-
- if (*symtab == NULL)
- return false;
-
- if (symsec->sh_link != 0)
- {
- Elf_Internal_Shdr *strsec;
-
- if (symsec->sh_link >= filedata->file_header.e_shnum)
- {
- error (_("Bad sh_link in symbol table section\n"));
- free (*symtab);
- *symtab = NULL;
- *nsyms = 0;
- return false;
- }
-
- strsec = filedata->section_headers + symsec->sh_link;
-
- *strtab = (char *) get_data (NULL, filedata, strsec->sh_offset,
- 1, strsec->sh_size, _("string table"));
- if (*strtab == NULL)
- {
- free (*symtab);
- *symtab = NULL;
- *nsyms = 0;
- return false;
- }
- *strtablen = strsec->sh_size;
- }
- return true;
-}
-
-static const char *
-get_group_flags (unsigned int flags)
-{
- static char buff[128];
-
- if (flags == 0)
- return "";
- else if (flags == GRP_COMDAT)
- return "COMDAT ";
-
- snprintf (buff, sizeof buff, "[0x%x: %s%s%s]",
- flags,
- flags & GRP_MASKOS ? _("<OS specific>") : "",
- flags & GRP_MASKPROC ? _("<PROC specific>") : "",
- (flags & ~(GRP_COMDAT | GRP_MASKOS | GRP_MASKPROC)
- ? _("<unknown>") : ""));
-
- return buff;
-}
-
-static bool
-process_section_groups (Filedata * filedata)
-{
- Elf_Internal_Shdr * section;
- unsigned int i;
- struct group * group;
- Elf_Internal_Shdr * symtab_sec;
- Elf_Internal_Shdr * strtab_sec;
- Elf_Internal_Sym * symtab;
- uint64_t num_syms;
- char * strtab;
- size_t strtab_size;
-
- /* Don't process section groups unless needed. */
- if (!do_unwind && !do_section_groups)
- return true;
-
- if (filedata->file_header.e_shnum == 0)
- {
- if (do_section_groups)
- {
- if (filedata->is_separate)
- printf (_("\nThere are no sections group in linked file '%s'.\n"),
- filedata->file_name);
- else
- printf (_("\nThere are no section groups in this file.\n"));
- }
- return true;
- }
-
- if (filedata->section_headers == NULL)
- {
- error (_("Section headers are not available!\n"));
- /* PR 13622: This can happen with a corrupt ELF header. */
- return false;
- }
-
- filedata->section_headers_groups
- = (struct group **) calloc (filedata->file_header.e_shnum,
- sizeof (struct group *));
-
- if (filedata->section_headers_groups == NULL)
- {
- error (_("Out of memory reading %u section group headers\n"),
- filedata->file_header.e_shnum);
- return false;
- }
-
- /* Scan the sections for the group section. */
- filedata->group_count = 0;
- for (i = 0, section = filedata->section_headers;
- i < filedata->file_header.e_shnum;
- i++, section++)
- if (section->sh_type == SHT_GROUP)
- filedata->group_count++;
-
- if (filedata->group_count == 0)
- {
- if (do_section_groups)
- {
- if (filedata->is_separate)
- printf (_("\nThere are no section groups in linked file '%s'.\n"),
- filedata->file_name);
- else
- printf (_("\nThere are no section groups in this file.\n"));
- }
-
- return true;
- }
-
- filedata->section_groups = (struct group *) calloc (filedata->group_count,
- sizeof (struct group));
-
- if (filedata->section_groups == NULL)
- {
- error (_("Out of memory reading %zu groups\n"), filedata->group_count);
- return false;
- }
-
- symtab_sec = NULL;
- strtab_sec = NULL;
- symtab = NULL;
- num_syms = 0;
- strtab = NULL;
- strtab_size = 0;
-
- if (filedata->is_separate)
- printf (_("Section groups in linked file '%s'\n"), filedata->file_name);
-
- for (i = 0, section = filedata->section_headers, group = filedata->section_groups;
- i < filedata->file_header.e_shnum;
- i++, section++)
- {
- if (section->sh_type == SHT_GROUP)
- {
- const char * name = printable_section_name (filedata, section);
- const char * group_name;
- unsigned char * start;
- unsigned char * indices;
- unsigned int entry, j, size;
- Elf_Internal_Shdr * sec;
- Elf_Internal_Sym * sym;
-
- /* Get the symbol table. */
- if (section->sh_link >= filedata->file_header.e_shnum
- || ((sec = filedata->section_headers + section->sh_link)->sh_type
- != SHT_SYMTAB))
- {
- error (_("Bad sh_link in group section `%s'\n"), name);
- continue;
- }
-
- if (symtab_sec != sec)
- {
- symtab_sec = sec;
- free (symtab);
- symtab = get_elf_symbols (filedata, symtab_sec, & num_syms);
- }
-
- if (symtab == NULL)
- {
- error (_("Corrupt header in group section `%s'\n"), name);
- continue;
- }
-
- if (section->sh_info >= num_syms)
- {
- error (_("Bad sh_info in group section `%s'\n"), name);
- continue;
- }
-
- sym = symtab + section->sh_info;
-
- if (ELF_ST_TYPE (sym->st_info) == STT_SECTION)
- {
- if (sym->st_shndx == 0
- || sym->st_shndx >= filedata->file_header.e_shnum)
- {
- error (_("Bad sh_info in group section `%s'\n"), name);
- continue;
- }
-
- group_name = printable_section_name (filedata,
- filedata->section_headers
- + sym->st_shndx);
- strtab_sec = NULL;
- free (strtab);
- strtab = NULL;
- strtab_size = 0;
- }
- else
- {
- /* Get the string table. */
- if (symtab_sec->sh_link >= filedata->file_header.e_shnum)
- {
- strtab_sec = NULL;
- free (strtab);
- strtab = NULL;
- strtab_size = 0;
- }
- else if (strtab_sec
- != (sec = filedata->section_headers + symtab_sec->sh_link))
- {
- strtab_sec = sec;
- free (strtab);
-
- strtab = (char *) get_data (NULL, filedata, strtab_sec->sh_offset,
- 1, strtab_sec->sh_size,
- _("string table"));
- strtab_size = strtab != NULL ? strtab_sec->sh_size : 0;
- }
- group_name = sym->st_name < strtab_size
- ? strtab + sym->st_name : _("<corrupt>");
- }
-
- /* PR 17531: file: loop. */
- if (section->sh_entsize > section->sh_size)
- {
- error (_("Section %s has sh_entsize (%#" PRIx64 ")"
- " which is larger than its size (%#" PRIx64 ")\n"),
- printable_section_name (filedata, section),
- section->sh_entsize,
- section->sh_size);
- continue;
- }
-
- start = (unsigned char *) get_data (NULL, filedata, section->sh_offset,
- 1, section->sh_size,
- _("section data"));
- if (start == NULL)
- continue;
-
- indices = start;
- size = (section->sh_size / section->sh_entsize) - 1;
- entry = byte_get (indices, 4);
- indices += 4;
-
- if (do_section_groups)
- {
- printf (_("\n%sgroup section [%5u] `%s' [%s] contains %u sections:\n"),
- get_group_flags (entry), i, name, group_name, size);
-
- printf (_(" [Index] Name\n"));
- }
-
- group->group_index = i;
-
- for (j = 0; j < size; j++)
- {
- struct group_list * g;
-
- entry = byte_get (indices, 4);
- indices += 4;
-
- if (entry >= filedata->file_header.e_shnum)
- {
- static unsigned num_group_errors = 0;
-
- if (num_group_errors ++ < 10)
- {
- error (_("section [%5u] in group section [%5u] > maximum section [%5u]\n"),
- entry, i, filedata->file_header.e_shnum - 1);
- if (num_group_errors == 10)
- warn (_("Further error messages about overlarge group section indices suppressed\n"));
- }
- continue;
- }
-
- if (filedata->section_headers_groups [entry] != NULL)
- {
- if (entry)
- {
- static unsigned num_errs = 0;
-
- if (num_errs ++ < 10)
- {
- error (_("section [%5u] in group section [%5u] already in group section [%5u]\n"),
- entry, i,
- filedata->section_headers_groups [entry]->group_index);
- if (num_errs == 10)
- warn (_("Further error messages about already contained group sections suppressed\n"));
- }
- continue;
- }
- else
- {
- /* Intel C/C++ compiler may put section 0 in a
- section group. We just warn it the first time
- and ignore it afterwards. */
- static bool warned = false;
- if (!warned)
- {
- error (_("section 0 in group section [%5u]\n"),
- filedata->section_headers_groups [entry]->group_index);
- warned = true;
- }
- }
- }
-
- filedata->section_headers_groups [entry] = group;
-
- if (do_section_groups)
- {
- sec = filedata->section_headers + entry;
- printf (" [%5u] %s\n", entry, printable_section_name (filedata, sec));
- }
-
- g = (struct group_list *) xmalloc (sizeof (struct group_list));
- g->section_index = entry;
- g->next = group->root;
- group->root = g;
- }
-
- free (start);
-
- group++;
- }
- }
-
- free (symtab);
- free (strtab);
- return true;
-}
-
-/* Data used to display dynamic fixups. */
-
-struct ia64_vms_dynfixup
-{
- uint64_t needed_ident; /* Library ident number. */
- uint64_t needed; /* Index in the dstrtab of the library name. */
- uint64_t fixup_needed; /* Index of the library. */
- uint64_t fixup_rela_cnt; /* Number of fixups. */
- uint64_t fixup_rela_off; /* Fixups offset in the dynamic segment. */
-};
-
-/* Data used to display dynamic relocations. */
-
-struct ia64_vms_dynimgrela
-{
- uint64_t img_rela_cnt; /* Number of relocations. */
- uint64_t img_rela_off; /* Reloc offset in the dynamic segment. */
-};
-
-/* Display IA-64 OpenVMS dynamic fixups (used to dynamically link a shared
- library). */
-
-static bool
-dump_ia64_vms_dynamic_fixups (Filedata * filedata,
- struct ia64_vms_dynfixup * fixup,
- const char * strtab,
- unsigned int strtab_sz)
-{
- Elf64_External_VMS_IMAGE_FIXUP * imfs;
- size_t i;
- const char * lib_name;
-
- imfs = get_data (NULL, filedata,
- filedata->dynamic_addr + fixup->fixup_rela_off,
- sizeof (*imfs), fixup->fixup_rela_cnt,
- _("dynamic section image fixups"));
- if (!imfs)
- return false;
-
- if (fixup->needed < strtab_sz)
- lib_name = strtab + fixup->needed;
- else
- {
- warn (_("corrupt library name index of %#" PRIx64
- " found in dynamic entry"), fixup->needed);
- lib_name = "???";
- }
-
- printf (_("\nImage fixups for needed library #%" PRId64
- ": %s - ident: %" PRIx64 "\n"),
- fixup->fixup_needed, lib_name, fixup->needed_ident);
- printf
- (_("Seg Offset Type SymVec DataType\n"));
-
- for (i = 0; i < (size_t) fixup->fixup_rela_cnt; i++)
- {
- unsigned int type;
- const char *rtype;
-
- printf ("%3u ", (unsigned) BYTE_GET (imfs [i].fixup_seg));
- printf ("%016" PRIx64 " ", BYTE_GET (imfs [i].fixup_offset));
- type = BYTE_GET (imfs [i].type);
- rtype = elf_ia64_reloc_type (type);
- if (rtype == NULL)
- printf ("0x%08x ", type);
- else
- printf ("%-32s ", rtype);
- printf ("%6u ", (unsigned) BYTE_GET (imfs [i].symvec_index));
- printf ("0x%08x\n", (unsigned) BYTE_GET (imfs [i].data_type));
- }
-
- free (imfs);
- return true;
-}
-
-/* Display IA-64 OpenVMS dynamic relocations (used to relocate an image). */
-
-static bool
-dump_ia64_vms_dynamic_relocs (Filedata * filedata, struct ia64_vms_dynimgrela *imgrela)
-{
- Elf64_External_VMS_IMAGE_RELA *imrs;
- size_t i;
-
- imrs = get_data (NULL, filedata,
- filedata->dynamic_addr + imgrela->img_rela_off,
- sizeof (*imrs), imgrela->img_rela_cnt,
- _("dynamic section image relocations"));
- if (!imrs)
- return false;
-
- printf (_("\nImage relocs\n"));
- printf
- (_("Seg Offset Type Addend Seg Sym Off\n"));
-
- for (i = 0; i < (size_t) imgrela->img_rela_cnt; i++)
- {
- unsigned int type;
- const char *rtype;
-
- printf ("%3u ", (unsigned) BYTE_GET (imrs [i].rela_seg));
- printf ("%08" PRIx64 " ", BYTE_GET (imrs [i].rela_offset));
- type = BYTE_GET (imrs [i].type);
- rtype = elf_ia64_reloc_type (type);
- if (rtype == NULL)
- printf ("0x%08x ", type);
- else
- printf ("%-31s ", rtype);
- print_vma (BYTE_GET (imrs [i].addend), FULL_HEX);
- printf ("%3u ", (unsigned) BYTE_GET (imrs [i].sym_seg));
- printf ("%08" PRIx64 "\n", BYTE_GET (imrs [i].sym_offset));
- }
-
- free (imrs);
- return true;
-}
-
-/* Display IA-64 OpenVMS dynamic relocations and fixups. */
-
-static bool
-process_ia64_vms_dynamic_relocs (Filedata * filedata)
-{
- struct ia64_vms_dynfixup fixup;
- struct ia64_vms_dynimgrela imgrela;
- Elf_Internal_Dyn *entry;
- uint64_t strtab_off = 0;
- uint64_t strtab_sz = 0;
- char *strtab = NULL;
- bool res = true;
-
- memset (&fixup, 0, sizeof (fixup));
- memset (&imgrela, 0, sizeof (imgrela));
-
- /* Note: the order of the entries is specified by the OpenVMS specs. */
- for (entry = filedata->dynamic_section;
- entry < filedata->dynamic_section + filedata->dynamic_nent;
- entry++)
- {
- switch (entry->d_tag)
- {
- case DT_IA_64_VMS_STRTAB_OFFSET:
- strtab_off = entry->d_un.d_val;
- break;
- case DT_STRSZ:
- strtab_sz = entry->d_un.d_val;
- if (strtab == NULL)
- strtab = get_data (NULL, filedata,
- filedata->dynamic_addr + strtab_off,
- 1, strtab_sz, _("dynamic string section"));
- if (strtab == NULL)
- strtab_sz = 0;
- break;
-
- case DT_IA_64_VMS_NEEDED_IDENT:
- fixup.needed_ident = entry->d_un.d_val;
- break;
- case DT_NEEDED:
- fixup.needed = entry->d_un.d_val;
- break;
- case DT_IA_64_VMS_FIXUP_NEEDED:
- fixup.fixup_needed = entry->d_un.d_val;
- break;
- case DT_IA_64_VMS_FIXUP_RELA_CNT:
- fixup.fixup_rela_cnt = entry->d_un.d_val;
- break;
- case DT_IA_64_VMS_FIXUP_RELA_OFF:
- fixup.fixup_rela_off = entry->d_un.d_val;
- if (! dump_ia64_vms_dynamic_fixups (filedata, &fixup, strtab, strtab_sz))
- res = false;
- break;
- case DT_IA_64_VMS_IMG_RELA_CNT:
- imgrela.img_rela_cnt = entry->d_un.d_val;
- break;
- case DT_IA_64_VMS_IMG_RELA_OFF:
- imgrela.img_rela_off = entry->d_un.d_val;
- if (! dump_ia64_vms_dynamic_relocs (filedata, &imgrela))
- res = false;
- break;
-
- default:
- break;
- }
- }
-
- free (strtab);
-
- return res;
-}
-
-static struct
-{
- const char * name;
- int reloc;
- int size;
- relocation_type rel_type;
-}
- dynamic_relocations [] =
-{
- { "REL", DT_REL, DT_RELSZ, reltype_rel },
- { "RELA", DT_RELA, DT_RELASZ, reltype_rela },
- { "RELR", DT_RELR, DT_RELRSZ, reltype_relr },
- { "PLT", DT_JMPREL, DT_PLTRELSZ, reltype_unknown }
-};
-
-static relocation_type
-rel_type_from_sh_type (unsigned int sh_type)
-{
- switch (sh_type)
- {
- case SHT_RELA: return reltype_rela;
- case SHT_REL: return reltype_rel;
- case SHT_RELR: return reltype_relr;
- default: return reltype_unknown;
- }
-}
-
-static bool
-display_relocations (Elf_Internal_Shdr * section,
- Filedata * filedata)
-{
- relocation_type rel_type = rel_type_from_sh_type (section->sh_type);
-
- if (rel_type == reltype_unknown)
- return false;
-
- uint64_t rel_size = section->sh_size;
-
- if (rel_size == 0)
- return false;
-
- if (filedata->is_separate)
- printf (_("\nIn linked file '%s' relocation section "),
- filedata->file_name);
- else
- printf (_("\nRelocation section "));
-
- if (filedata->string_table == NULL)
- printf ("%d", section->sh_name);
- else
- printf ("'%s'", printable_section_name (filedata, section));
-
- uint64_t num_rela = rel_size / section->sh_entsize;
- uint64_t rel_offset = section->sh_offset;
-
- if (rel_type == reltype_relr)
- {
- /* Just stating the 'number of entries' in a RELR section can be
- misleading, since this is not the number of locations relocated, but
- the number of words in the compressed RELR format. So also provide
- the number of locations affected. */
- if (num_rela == 1)
- /* This is unlikely, but possible. */
- printf (_(" at offset %#" PRIx64
- " contains 1 entry which relocates 1 location:\n"),
- rel_offset);
- else
- printf (_(" at offset %#" PRIx64 " contains %" PRIu64
- " entries which relocate %" PRIu64 " locations:\n"),
- rel_offset, num_rela, count_relr_relocations (filedata, section));
- }
- else
- {
- printf (ngettext (" at offset %#" PRIx64
- " contains %" PRIu64 " entry:\n",
- " at offset %#" PRIx64
- " contains %" PRIu64 " entries:\n",
- num_rela),
- rel_offset, num_rela);
- }
-
- Elf_Internal_Shdr * symsec;
- Elf_Internal_Sym * symtab = NULL;
- uint64_t nsyms = 0;
- uint64_t strtablen = 0;
- char * strtab = NULL;
-
- if (section->sh_link == 0
- || section->sh_link >= filedata->file_header.e_shnum)
- {
- /* Symbol data not available.
- This can happen, especially with RELR relocs.
- See if there is a .symtab section present.
- If so then use it. */
- symsec = find_section_by_name (filedata, ".symtab");
- }
- else
- {
- symsec = filedata->section_headers + section->sh_link;
-
- if (symsec->sh_type != SHT_SYMTAB
- && symsec->sh_type != SHT_DYNSYM)
- return false;
- }
-
- if (symsec != NULL
- && !get_symtab (filedata, symsec, &symtab, &nsyms, &strtab, &strtablen))
- return false;
-
- bool res;
-
- if (rel_type == reltype_relr)
- res = dump_relr_relocations (filedata, section, symtab, nsyms, strtab, strtablen);
- else
- res = dump_relocations (filedata, rel_offset, rel_size,
- symtab, nsyms, strtab, strtablen,
- rel_type,
- symsec == NULL ? false : symsec->sh_type == SHT_DYNSYM);
- free (strtab);
- free (symtab);
-
- return res;
-}
-
-/* Process the reloc section. */
-
-static bool
-process_relocs (Filedata * filedata)
-{
- uint64_t rel_size;
- uint64_t rel_offset;
-
- if (!do_reloc)
- return true;
-
- if (do_using_dynamic)
- {
- relocation_type rel_type;
- const char * name;
- bool has_dynamic_reloc;
- unsigned int i;
-
- has_dynamic_reloc = false;
-
- for (i = 0; i < ARRAY_SIZE (dynamic_relocations); i++)
- {
- rel_type = dynamic_relocations [i].rel_type;
- name = dynamic_relocations [i].name;
- rel_size = filedata->dynamic_info[dynamic_relocations [i].size];
- rel_offset = filedata->dynamic_info[dynamic_relocations [i].reloc];
-
- if (rel_size)
- has_dynamic_reloc = true;
-
- if (rel_type == reltype_unknown)
- {
- if (dynamic_relocations [i].reloc == DT_JMPREL)
- switch (filedata->dynamic_info[DT_PLTREL])
- {
- case DT_REL:
- rel_type = reltype_rel;
- break;
- case DT_RELA:
- rel_type = reltype_rela;
- break;
- }
- }
-
- if (rel_size)
- {
- if (filedata->is_separate)
- printf
- (_("\nIn linked file '%s' section '%s' at offset %#" PRIx64
- " contains %" PRId64 " bytes:\n"),
- filedata->file_name, name, rel_offset, rel_size);
- else
- printf
- (_("\n'%s' relocation section at offset %#" PRIx64
- " contains %" PRId64 " bytes:\n"),
- name, rel_offset, rel_size);
-
- dump_relocations (filedata,
- offset_from_vma (filedata, rel_offset, rel_size),
- rel_size,
- filedata->dynamic_symbols,
- filedata->num_dynamic_syms,
- filedata->dynamic_strings,
- filedata->dynamic_strings_length,
- rel_type, true /* is_dynamic */);
- }
- }
-
- if (is_ia64_vms (filedata))
- if (process_ia64_vms_dynamic_relocs (filedata))
- has_dynamic_reloc = true;
-
- if (! has_dynamic_reloc)
- {
- if (filedata->is_separate)
- printf (_("\nThere are no dynamic relocations in linked file '%s'.\n"),
- filedata->file_name);
- else
- printf (_("\nThere are no dynamic relocations in this file.\n"));
- }
- }
- else
- {
- Elf_Internal_Shdr * section;
- size_t i;
- bool found = false;
-
- for (i = 0, section = filedata->section_headers;
- i < filedata->file_header.e_shnum;
- i++, section++)
- {
- if (display_relocations (section, filedata))
- found = true;
- }
-
- if (! found)
- {
- /* Users sometimes forget the -D option, so try to be helpful. */
- for (i = 0; i < ARRAY_SIZE (dynamic_relocations); i++)
- {
- if (filedata->dynamic_info[dynamic_relocations [i].size])
- {
- if (filedata->is_separate)
- printf (_("\nThere are no static relocations in linked file '%s'."),
- filedata->file_name);
- else
- printf (_("\nThere are no static relocations in this file."));
- printf (_("\nTo see the dynamic relocations add --use-dynamic to the command line.\n"));
-
- break;
- }
- }
- if (i == ARRAY_SIZE (dynamic_relocations))
- {
- if (filedata->is_separate)
- printf (_("\nThere are no relocations in linked file '%s'.\n"),
- filedata->file_name);
- else
- printf (_("\nThere are no relocations in this file.\n"));
- }
- }
- }
-
- return true;
-}
-
-/* An absolute address consists of a section and an offset. If the
- section is NULL, the offset itself is the address, otherwise, the
- address equals to LOAD_ADDRESS(section) + offset. */
-
-struct absaddr
-{
- unsigned short section;
- uint64_t offset;
-};
-
-/* Find the nearest symbol at or below ADDR. Returns the symbol
- name, if found, and the offset from the symbol to ADDR. */
-
-static void
-find_symbol_for_address (Filedata *filedata,
- Elf_Internal_Sym *symtab,
- uint64_t nsyms,
- const char *strtab,
- uint64_t strtab_size,
- struct absaddr addr,
- const char **symname,
- uint64_t *offset)
-{
- uint64_t dist = 0x100000;
- Elf_Internal_Sym * sym;
- Elf_Internal_Sym * beg;
- Elf_Internal_Sym * end;
- Elf_Internal_Sym * best = NULL;
-
- REMOVE_ARCH_BITS (addr.offset);
- beg = symtab;
- end = symtab + nsyms;
-
- while (beg < end)
- {
- uint64_t value;
-
- sym = beg + (end - beg) / 2;
-
- value = sym->st_value;
- REMOVE_ARCH_BITS (value);
-
- if (sym->st_name != 0
- && (addr.section == SHN_UNDEF || addr.section == sym->st_shndx)
- && addr.offset >= value
- && addr.offset - value < dist)
- {
- best = sym;
- dist = addr.offset - value;
- if (!dist)
- break;
- }
-
- if (addr.offset < value)
- end = sym;
- else
- beg = sym + 1;
- }
-
- if (best)
- {
- *symname = (best->st_name >= strtab_size
- ? _("<corrupt>") : strtab + best->st_name);
- *offset = dist;
- return;
- }
-
- *symname = NULL;
- *offset = addr.offset;
-}
-
-/* Process the unwind section. */
-
-#include "unwind-ia64.h"
-
-struct ia64_unw_table_entry
-{
- struct absaddr start;
- struct absaddr end;
- struct absaddr info;
-};
-
-struct ia64_unw_aux_info
-{
- struct ia64_unw_table_entry * table; /* Unwind table. */
- uint64_t table_len; /* Length of unwind table. */
- unsigned char * info; /* Unwind info. */
- uint64_t info_size; /* Size of unwind info. */
- uint64_t info_addr; /* Starting address of unwind info. */
- uint64_t seg_base; /* Starting address of segment. */
- Elf_Internal_Sym * symtab; /* The symbol table. */
- uint64_t nsyms; /* Number of symbols. */
- Elf_Internal_Sym * funtab; /* Sorted table of STT_FUNC symbols. */
- uint64_t nfuns; /* Number of entries in funtab. */
- char * strtab; /* The string table. */
- uint64_t strtab_size; /* Size of string table. */
-};
-
-static bool
-dump_ia64_unwind (Filedata * filedata, struct ia64_unw_aux_info * aux)
-{
- struct ia64_unw_table_entry * tp;
- size_t j, nfuns;
- int in_body;
- bool res = true;
-
- aux->funtab = xmalloc (aux->nsyms * sizeof (Elf_Internal_Sym));
- for (nfuns = 0, j = 0; j < aux->nsyms; j++)
- if (aux->symtab[j].st_value && ELF_ST_TYPE (aux->symtab[j].st_info) == STT_FUNC)
- aux->funtab[nfuns++] = aux->symtab[j];
- aux->nfuns = nfuns;
- qsort (aux->funtab, aux->nfuns, sizeof (Elf_Internal_Sym), symcmp);
-
- for (tp = aux->table; tp < aux->table + aux->table_len; ++tp)
- {
- uint64_t stamp;
- uint64_t offset;
- const unsigned char * dp;
- const unsigned char * head;
- const unsigned char * end;
- const char * procname;
-
- find_symbol_for_address (filedata, aux->funtab, aux->nfuns, aux->strtab,
- aux->strtab_size, tp->start, &procname, &offset);
-
- fputs ("\n<", stdout);
-
- if (procname)
- {
- fputs (procname, stdout);
-
- if (offset)
- printf ("+%" PRIx64, offset);
- }
-
- fputs (">: [", stdout);
- print_vma (tp->start.offset, PREFIX_HEX);
- fputc ('-', stdout);
- print_vma (tp->end.offset, PREFIX_HEX);
- printf ("], info at +0x%" PRIx64 "\n",
- tp->info.offset - aux->seg_base);
-
- /* PR 17531: file: 86232b32. */
- if (aux->info == NULL)
- continue;
-
- offset = tp->info.offset;
- if (tp->info.section)
- {
- if (tp->info.section >= filedata->file_header.e_shnum)
- {
- warn (_("Invalid section %u in table entry %td\n"),
- tp->info.section, tp - aux->table);
- res = false;
- continue;
- }
- offset += filedata->section_headers[tp->info.section].sh_addr;
- }
- offset -= aux->info_addr;
- /* PR 17531: file: 0997b4d1. */
- if (offset >= aux->info_size
- || aux->info_size - offset < 8)
- {
- warn (_("Invalid offset %" PRIx64 " in table entry %td\n"),
- tp->info.offset, tp - aux->table);
- res = false;
- continue;
- }
-
- head = aux->info + offset;
- stamp = byte_get ((unsigned char *) head, sizeof (stamp));
-
- printf (" v%u, flags=0x%lx (%s%s), len=%lu bytes\n",
- (unsigned) UNW_VER (stamp),
- (unsigned long) ((stamp & UNW_FLAG_MASK) >> 32),
- UNW_FLAG_EHANDLER (stamp) ? " ehandler" : "",
- UNW_FLAG_UHANDLER (stamp) ? " uhandler" : "",
- (unsigned long) (eh_addr_size * UNW_LENGTH (stamp)));
-
- if (UNW_VER (stamp) != 1)
- {
- printf (_("\tUnknown version.\n"));
- continue;
- }
-
- in_body = 0;
- end = head + 8 + eh_addr_size * UNW_LENGTH (stamp);
- /* PR 17531: file: 16ceda89. */
- if (end > aux->info + aux->info_size)
- end = aux->info + aux->info_size;
- for (dp = head + 8; dp < end;)
- dp = unw_decode (dp, in_body, & in_body, end);
- }
-
- free (aux->funtab);
-
- return res;
-}
-
-static bool
-slurp_ia64_unwind_table (Filedata * filedata,
- struct ia64_unw_aux_info * aux,
- Elf_Internal_Shdr * sec)
-{
- uint64_t size, nrelas, i;
- Elf_Internal_Phdr * seg;
- struct ia64_unw_table_entry * tep;
- Elf_Internal_Shdr * relsec;
- Elf_Internal_Rela * rela;
- Elf_Internal_Rela * rp;
- unsigned char * table;
- unsigned char * tp;
- Elf_Internal_Sym * sym;
- const char * relname;
-
- aux->table_len = 0;
-
- /* First, find the starting address of the segment that includes
- this section: */
-
- if (filedata->file_header.e_phnum)
- {
- if (! get_program_headers (filedata))
- return false;
-
- for (seg = filedata->program_headers;
- seg < filedata->program_headers + filedata->file_header.e_phnum;
- ++seg)
- {
- if (seg->p_type != PT_LOAD)
- continue;
-
- if (sec->sh_addr >= seg->p_vaddr
- && (sec->sh_addr + sec->sh_size <= seg->p_vaddr + seg->p_memsz))
- {
- aux->seg_base = seg->p_vaddr;
- break;
- }
- }
- }
-
- /* Second, build the unwind table from the contents of the unwind section: */
- size = sec->sh_size;
- table = (unsigned char *) get_data (NULL, filedata, sec->sh_offset, 1, size,
- _("unwind table"));
- if (!table)
- return false;
-
- aux->table_len = size / (3 * eh_addr_size);
- aux->table = (struct ia64_unw_table_entry *)
- xcmalloc (aux->table_len, sizeof (aux->table[0]));
- tep = aux->table;
-
- for (tp = table; tp <= table + size - (3 * eh_addr_size); ++tep)
- {
- tep->start.section = SHN_UNDEF;
- tep->end.section = SHN_UNDEF;
- tep->info.section = SHN_UNDEF;
- tep->start.offset = byte_get (tp, eh_addr_size); tp += eh_addr_size;
- tep->end.offset = byte_get (tp, eh_addr_size); tp += eh_addr_size;
- tep->info.offset = byte_get (tp, eh_addr_size); tp += eh_addr_size;
- tep->start.offset += aux->seg_base;
- tep->end.offset += aux->seg_base;
- tep->info.offset += aux->seg_base;
- }
- free (table);
-
- /* Third, apply any relocations to the unwind table: */
- for (relsec = filedata->section_headers;
- relsec < filedata->section_headers + filedata->file_header.e_shnum;
- ++relsec)
- {
- if (relsec->sh_type != SHT_RELA
- || relsec->sh_info >= filedata->file_header.e_shnum
- || filedata->section_headers + relsec->sh_info != sec)
- continue;
-
- if (!slurp_rela_relocs (filedata, relsec->sh_offset, relsec->sh_size,
- & rela, & nrelas))
- {
- free (aux->table);
- aux->table = NULL;
- aux->table_len = 0;
- return false;
- }
-
- for (rp = rela; rp < rela + nrelas; ++rp)
- {
- unsigned int sym_ndx;
- unsigned int r_type = get_reloc_type (filedata, rp->r_info);
- relname = elf_ia64_reloc_type (r_type);
-
- /* PR 17531: file: 9fa67536. */
- if (relname == NULL)
- {
- warn (_("Skipping unknown relocation type: %u\n"), r_type);
- continue;
- }
-
- if (! startswith (relname, "R_IA64_SEGREL"))
- {
- warn (_("Skipping unexpected relocation type: %s\n"), relname);
- continue;
- }
-
- i = rp->r_offset / (3 * eh_addr_size);
-
- /* PR 17531: file: 5bc8d9bf. */
- if (i >= aux->table_len)
- {
- warn (_("Skipping reloc with overlarge offset: %#" PRIx64 "\n"),
- i);
- continue;
- }
-
- sym_ndx = get_reloc_symindex (rp->r_info);
- if (sym_ndx >= aux->nsyms)
- {
- warn (_("Skipping reloc with invalid symbol index: %u\n"),
- sym_ndx);
- continue;
- }
- sym = aux->symtab + sym_ndx;
-
- switch (rp->r_offset / eh_addr_size % 3)
- {
- case 0:
- aux->table[i].start.section = sym->st_shndx;
- aux->table[i].start.offset = rp->r_addend + sym->st_value;
- break;
- case 1:
- aux->table[i].end.section = sym->st_shndx;
- aux->table[i].end.offset = rp->r_addend + sym->st_value;
- break;
- case 2:
- aux->table[i].info.section = sym->st_shndx;
- aux->table[i].info.offset = rp->r_addend + sym->st_value;
- break;
- default:
- break;
- }
- }
-
- free (rela);
- }
-
- return true;
-}
-
-static bool
-ia64_process_unwind (Filedata * filedata)
-{
- Elf_Internal_Shdr * sec;
- Elf_Internal_Shdr * unwsec = NULL;
- uint64_t i, unwcount = 0, unwstart = 0;
- struct ia64_unw_aux_info aux;
- bool res = true;
-
- memset (& aux, 0, sizeof (aux));
-
- for (i = 0, sec = filedata->section_headers; i < filedata->file_header.e_shnum; ++i, ++sec)
- {
- if (sec->sh_type == SHT_SYMTAB)
- {
- if (aux.symtab)
- {
- error (_("Multiple symbol tables encountered\n"));
- free (aux.symtab);
- aux.symtab = NULL;
- free (aux.strtab);
- aux.strtab = NULL;
- }
- if (!get_symtab (filedata, sec, &aux.symtab, &aux.nsyms,
- &aux.strtab, &aux.strtab_size))
- return false;
- }
- else if (sec->sh_type == SHT_IA_64_UNWIND)
- unwcount++;
- }
-
- if (!unwcount)
- printf (_("\nThere are no unwind sections in this file.\n"));
-
- while (unwcount-- > 0)
- {
- const char *suffix;
- size_t len, len2;
-
- for (i = unwstart, sec = filedata->section_headers + unwstart, unwsec = NULL;
- i < filedata->file_header.e_shnum; ++i, ++sec)
- if (sec->sh_type == SHT_IA_64_UNWIND)
- {
- unwsec = sec;
- break;
- }
- /* We have already counted the number of SHT_IA64_UNWIND
- sections so the loop above should never fail. */
- assert (unwsec != NULL);
-
- unwstart = i + 1;
- len = sizeof (ELF_STRING_ia64_unwind_once) - 1;
-
- if ((unwsec->sh_flags & SHF_GROUP) != 0)
- {
- /* We need to find which section group it is in. */
- struct group_list * g;
-
- if (filedata->section_headers_groups == NULL
- || filedata->section_headers_groups[i] == NULL)
- i = filedata->file_header.e_shnum;
- else
- {
- g = filedata->section_headers_groups[i]->root;
-
- for (; g != NULL; g = g->next)
- {
- sec = filedata->section_headers + g->section_index;
-
- if (section_name_valid (filedata, sec)
- && streq (section_name (filedata, sec),
- ELF_STRING_ia64_unwind_info))
- break;
- }
-
- if (g == NULL)
- i = filedata->file_header.e_shnum;
- }
- }
- else if (section_name_valid (filedata, unwsec)
- && startswith (section_name (filedata, unwsec),
- ELF_STRING_ia64_unwind_once))
- {
- /* .gnu.linkonce.ia64unw.FOO -> .gnu.linkonce.ia64unwi.FOO. */
- len2 = sizeof (ELF_STRING_ia64_unwind_info_once) - 1;
- suffix = section_name (filedata, unwsec) + len;
- for (i = 0, sec = filedata->section_headers;
- i < filedata->file_header.e_shnum;
- ++i, ++sec)
- if (section_name_valid (filedata, sec)
- && startswith (section_name (filedata, sec),
- ELF_STRING_ia64_unwind_info_once)
- && streq (section_name (filedata, sec) + len2, suffix))
- break;
- }
- else
- {
- /* .IA_64.unwindFOO -> .IA_64.unwind_infoFOO
- .IA_64.unwind or BAR -> .IA_64.unwind_info. */
- len = sizeof (ELF_STRING_ia64_unwind) - 1;
- len2 = sizeof (ELF_STRING_ia64_unwind_info) - 1;
- suffix = "";
- if (section_name_valid (filedata, unwsec)
- && startswith (section_name (filedata, unwsec),
- ELF_STRING_ia64_unwind))
- suffix = section_name (filedata, unwsec) + len;
- for (i = 0, sec = filedata->section_headers;
- i < filedata->file_header.e_shnum;
- ++i, ++sec)
- if (section_name_valid (filedata, sec)
- && startswith (section_name (filedata, sec),
- ELF_STRING_ia64_unwind_info)
- && streq (section_name (filedata, sec) + len2, suffix))
- break;
- }
-
- if (i == filedata->file_header.e_shnum)
- {
- printf (_("\nCould not find unwind info section for "));
-
- if (filedata->string_table == NULL)
- printf ("%d", unwsec->sh_name);
- else
- printf ("'%s'", printable_section_name (filedata, unwsec));
- }
- else
- {
- aux.info_addr = sec->sh_addr;
- aux.info = (unsigned char *) get_data (NULL, filedata, sec->sh_offset, 1,
- sec->sh_size,
- _("unwind info"));
- aux.info_size = aux.info == NULL ? 0 : sec->sh_size;
-
- printf (_("\nUnwind section "));
-
- if (filedata->string_table == NULL)
- printf ("%d", unwsec->sh_name);
- else
- printf ("'%s'", printable_section_name (filedata, unwsec));
-
- printf (_(" at offset %#" PRIx64 " contains %" PRIu64 " entries:\n"),
- unwsec->sh_offset,
- unwsec->sh_size / (3 * eh_addr_size));
-
- if (slurp_ia64_unwind_table (filedata, & aux, unwsec)
- && aux.table_len > 0)
- dump_ia64_unwind (filedata, & aux);
-
- free ((char *) aux.table);
- free ((char *) aux.info);
- aux.table = NULL;
- aux.info = NULL;
- }
- }
-
- free (aux.symtab);
- free ((char *) aux.strtab);
-
- return res;
-}
-
-struct hppa_unw_table_entry
-{
- struct absaddr start;
- struct absaddr end;
- unsigned int Cannot_unwind:1; /* 0 */
- unsigned int Millicode:1; /* 1 */
- unsigned int Millicode_save_sr0:1; /* 2 */
- unsigned int Region_description:2; /* 3..4 */
- unsigned int reserved1:1; /* 5 */
- unsigned int Entry_SR:1; /* 6 */
- unsigned int Entry_FR:4; /* Number saved 7..10 */
- unsigned int Entry_GR:5; /* Number saved 11..15 */
- unsigned int Args_stored:1; /* 16 */
- unsigned int Variable_Frame:1; /* 17 */
- unsigned int Separate_Package_Body:1; /* 18 */
- unsigned int Frame_Extension_Millicode:1; /* 19 */
- unsigned int Stack_Overflow_Check:1; /* 20 */
- unsigned int Two_Instruction_SP_Increment:1; /* 21 */
- unsigned int Ada_Region:1; /* 22 */
- unsigned int cxx_info:1; /* 23 */
- unsigned int cxx_try_catch:1; /* 24 */
- unsigned int sched_entry_seq:1; /* 25 */
- unsigned int reserved2:1; /* 26 */
- unsigned int Save_SP:1; /* 27 */
- unsigned int Save_RP:1; /* 28 */
- unsigned int Save_MRP_in_frame:1; /* 29 */
- unsigned int extn_ptr_defined:1; /* 30 */
- unsigned int Cleanup_defined:1; /* 31 */
-
- unsigned int MPE_XL_interrupt_marker:1; /* 0 */
- unsigned int HP_UX_interrupt_marker:1; /* 1 */
- unsigned int Large_frame:1; /* 2 */
- unsigned int Pseudo_SP_Set:1; /* 3 */
- unsigned int reserved4:1; /* 4 */
- unsigned int Total_frame_size:27; /* 5..31 */
-};
-
-struct hppa_unw_aux_info
-{
- struct hppa_unw_table_entry * table; /* Unwind table. */
- uint64_t table_len; /* Length of unwind table. */
- uint64_t seg_base; /* Starting address of segment. */
- Elf_Internal_Sym * symtab; /* The symbol table. */
- uint64_t nsyms; /* Number of symbols. */
- Elf_Internal_Sym * funtab; /* Sorted table of STT_FUNC symbols. */
- uint64_t nfuns; /* Number of entries in funtab. */
- char * strtab; /* The string table. */
- uint64_t strtab_size; /* Size of string table. */
-};
-
-static bool
-dump_hppa_unwind (Filedata * filedata, struct hppa_unw_aux_info * aux)
-{
- struct hppa_unw_table_entry * tp;
- uint64_t j, nfuns;
- bool res = true;
-
- aux->funtab = xmalloc (aux->nsyms * sizeof (Elf_Internal_Sym));
- for (nfuns = 0, j = 0; j < aux->nsyms; j++)
- if (aux->symtab[j].st_value && ELF_ST_TYPE (aux->symtab[j].st_info) == STT_FUNC)
- aux->funtab[nfuns++] = aux->symtab[j];
- aux->nfuns = nfuns;
- qsort (aux->funtab, aux->nfuns, sizeof (Elf_Internal_Sym), symcmp);
-
- for (tp = aux->table; tp < aux->table + aux->table_len; ++tp)
- {
- uint64_t offset;
- const char * procname;
-
- find_symbol_for_address (filedata, aux->funtab, aux->nfuns, aux->strtab,
- aux->strtab_size, tp->start, &procname,
- &offset);
-
- fputs ("\n<", stdout);
-
- if (procname)
- {
- fputs (procname, stdout);
-
- if (offset)
- printf ("+%" PRIx64, offset);
- }
-
- fputs (">: [", stdout);
- print_vma (tp->start.offset, PREFIX_HEX);
- fputc ('-', stdout);
- print_vma (tp->end.offset, PREFIX_HEX);
- printf ("]\n\t");
-
-#define PF(_m) if (tp->_m) printf (#_m " ");
-#define PV(_m) if (tp->_m) printf (#_m "=%d ", tp->_m);
- PF(Cannot_unwind);
- PF(Millicode);
- PF(Millicode_save_sr0);
- /* PV(Region_description); */
- PF(Entry_SR);
- PV(Entry_FR);
- PV(Entry_GR);
- PF(Args_stored);
- PF(Variable_Frame);
- PF(Separate_Package_Body);
- PF(Frame_Extension_Millicode);
- PF(Stack_Overflow_Check);
- PF(Two_Instruction_SP_Increment);
- PF(Ada_Region);
- PF(cxx_info);
- PF(cxx_try_catch);
- PF(sched_entry_seq);
- PF(Save_SP);
- PF(Save_RP);
- PF(Save_MRP_in_frame);
- PF(extn_ptr_defined);
- PF(Cleanup_defined);
- PF(MPE_XL_interrupt_marker);
- PF(HP_UX_interrupt_marker);
- PF(Large_frame);
- PF(Pseudo_SP_Set);
- PV(Total_frame_size);
-#undef PF
-#undef PV
- }
-
- printf ("\n");
-
- free (aux->funtab);
-
- return res;
-}
-
-static bool
-slurp_hppa_unwind_table (Filedata * filedata,
- struct hppa_unw_aux_info * aux,
- Elf_Internal_Shdr * sec)
-{
- uint64_t size, unw_ent_size, nentries, nrelas, i;
- Elf_Internal_Phdr * seg;
- struct hppa_unw_table_entry * tep;
- Elf_Internal_Shdr * relsec;
- Elf_Internal_Rela * rela;
- Elf_Internal_Rela * rp;
- unsigned char * table;
- unsigned char * tp;
- Elf_Internal_Sym * sym;
- const char * relname;
-
- /* First, find the starting address of the segment that includes
- this section. */
- if (filedata->file_header.e_phnum)
- {
- if (! get_program_headers (filedata))
- return false;
-
- for (seg = filedata->program_headers;
- seg < filedata->program_headers + filedata->file_header.e_phnum;
- ++seg)
- {
- if (seg->p_type != PT_LOAD)
- continue;
-
- if (sec->sh_addr >= seg->p_vaddr
- && (sec->sh_addr + sec->sh_size <= seg->p_vaddr + seg->p_memsz))
- {
- aux->seg_base = seg->p_vaddr;
- break;
- }
- }
- }
-
- /* Second, build the unwind table from the contents of the unwind
- section. */
- size = sec->sh_size;
- table = (unsigned char *) get_data (NULL, filedata, sec->sh_offset, 1, size,
- _("unwind table"));
- if (!table)
- return false;
-
- unw_ent_size = 16;
- nentries = size / unw_ent_size;
- size = unw_ent_size * nentries;
-
- aux->table_len = nentries;
- tep = aux->table = (struct hppa_unw_table_entry *)
- xcmalloc (nentries, sizeof (aux->table[0]));
-
- for (tp = table; tp < table + size; tp += unw_ent_size, ++tep)
- {
- unsigned int tmp1, tmp2;
-
- tep->start.section = SHN_UNDEF;
- tep->end.section = SHN_UNDEF;
-
- tep->start.offset = byte_get ((unsigned char *) tp + 0, 4);
- tep->end.offset = byte_get ((unsigned char *) tp + 4, 4);
- tmp1 = byte_get ((unsigned char *) tp + 8, 4);
- tmp2 = byte_get ((unsigned char *) tp + 12, 4);
-
- tep->start.offset += aux->seg_base;
- tep->end.offset += aux->seg_base;
-
- tep->Cannot_unwind = (tmp1 >> 31) & 0x1;
- tep->Millicode = (tmp1 >> 30) & 0x1;
- tep->Millicode_save_sr0 = (tmp1 >> 29) & 0x1;
- tep->Region_description = (tmp1 >> 27) & 0x3;
- tep->reserved1 = (tmp1 >> 26) & 0x1;
- tep->Entry_SR = (tmp1 >> 25) & 0x1;
- tep->Entry_FR = (tmp1 >> 21) & 0xf;
- tep->Entry_GR = (tmp1 >> 16) & 0x1f;
- tep->Args_stored = (tmp1 >> 15) & 0x1;
- tep->Variable_Frame = (tmp1 >> 14) & 0x1;
- tep->Separate_Package_Body = (tmp1 >> 13) & 0x1;
- tep->Frame_Extension_Millicode = (tmp1 >> 12) & 0x1;
- tep->Stack_Overflow_Check = (tmp1 >> 11) & 0x1;
- tep->Two_Instruction_SP_Increment = (tmp1 >> 10) & 0x1;
- tep->Ada_Region = (tmp1 >> 9) & 0x1;
- tep->cxx_info = (tmp1 >> 8) & 0x1;
- tep->cxx_try_catch = (tmp1 >> 7) & 0x1;
- tep->sched_entry_seq = (tmp1 >> 6) & 0x1;
- tep->reserved2 = (tmp1 >> 5) & 0x1;
- tep->Save_SP = (tmp1 >> 4) & 0x1;
- tep->Save_RP = (tmp1 >> 3) & 0x1;
- tep->Save_MRP_in_frame = (tmp1 >> 2) & 0x1;
- tep->extn_ptr_defined = (tmp1 >> 1) & 0x1;
- tep->Cleanup_defined = tmp1 & 0x1;
-
- tep->MPE_XL_interrupt_marker = (tmp2 >> 31) & 0x1;
- tep->HP_UX_interrupt_marker = (tmp2 >> 30) & 0x1;
- tep->Large_frame = (tmp2 >> 29) & 0x1;
- tep->Pseudo_SP_Set = (tmp2 >> 28) & 0x1;
- tep->reserved4 = (tmp2 >> 27) & 0x1;
- tep->Total_frame_size = tmp2 & 0x7ffffff;
- }
- free (table);
-
- /* Third, apply any relocations to the unwind table. */
- for (relsec = filedata->section_headers;
- relsec < filedata->section_headers + filedata->file_header.e_shnum;
- ++relsec)
- {
- if (relsec->sh_type != SHT_RELA
- || relsec->sh_info >= filedata->file_header.e_shnum
- || filedata->section_headers + relsec->sh_info != sec)
- continue;
-
- if (!slurp_rela_relocs (filedata, relsec->sh_offset, relsec->sh_size,
- & rela, & nrelas))
- return false;
-
- for (rp = rela; rp < rela + nrelas; ++rp)
- {
- unsigned int sym_ndx;
- unsigned int r_type = get_reloc_type (filedata, rp->r_info);
- relname = elf_hppa_reloc_type (r_type);
-
- if (relname == NULL)
- {
- warn (_("Skipping unknown relocation type: %u\n"), r_type);
- continue;
- }
-
- /* R_PARISC_SEGREL32 or R_PARISC_SEGREL64. */
- if (! startswith (relname, "R_PARISC_SEGREL"))
- {
- warn (_("Skipping unexpected relocation type: %s\n"), relname);
- continue;
- }
-
- i = rp->r_offset / unw_ent_size;
- if (i >= aux->table_len)
- {
- warn (_("Skipping reloc with overlarge offset: %#" PRIx64 "\n"),
- i);
- continue;
- }
-
- sym_ndx = get_reloc_symindex (rp->r_info);
- if (sym_ndx >= aux->nsyms)
- {
- warn (_("Skipping reloc with invalid symbol index: %u\n"),
- sym_ndx);
- continue;
- }
- sym = aux->symtab + sym_ndx;
-
- switch ((rp->r_offset % unw_ent_size) / 4)
- {
- case 0:
- aux->table[i].start.section = sym->st_shndx;
- aux->table[i].start.offset = sym->st_value + rp->r_addend;
- break;
- case 1:
- aux->table[i].end.section = sym->st_shndx;
- aux->table[i].end.offset = sym->st_value + rp->r_addend;
- break;
- default:
- break;
- }
- }
-
- free (rela);
- }
-
- return true;
-}
-
-static bool
-hppa_process_unwind (Filedata * filedata)
-{
- struct hppa_unw_aux_info aux;
- Elf_Internal_Shdr * unwsec = NULL;
- Elf_Internal_Shdr * sec;
- size_t i;
- bool res = true;
-
- if (filedata->string_table == NULL)
- return false;
-
- memset (& aux, 0, sizeof (aux));
-
- for (i = 0, sec = filedata->section_headers; i < filedata->file_header.e_shnum; ++i, ++sec)
- {
- if (sec->sh_type == SHT_SYMTAB)
- {
- if (aux.symtab)
- {
- error (_("Multiple symbol tables encountered\n"));
- free (aux.symtab);
- aux.symtab = NULL;
- free (aux.strtab);
- aux.strtab = NULL;
- }
- if (!get_symtab (filedata, sec, &aux.symtab, &aux.nsyms,
- &aux.strtab, &aux.strtab_size))
- return false;
- }
- else if (section_name_valid (filedata, sec)
- && streq (section_name (filedata, sec), ".PARISC.unwind"))
- unwsec = sec;
- }
-
- if (!unwsec)
- printf (_("\nThere are no unwind sections in this file.\n"));
-
- for (i = 0, sec = filedata->section_headers; i < filedata->file_header.e_shnum; ++i, ++sec)
- {
- if (section_name_valid (filedata, sec)
- && streq (section_name (filedata, sec), ".PARISC.unwind"))
- {
- uint64_t num_unwind = sec->sh_size / 16;
-
- printf (ngettext ("\nUnwind section '%s' at offset %#" PRIx64 " "
- "contains %" PRIu64 " entry:\n",
- "\nUnwind section '%s' at offset %#" PRIx64 " "
- "contains %" PRIu64 " entries:\n",
- num_unwind),
- printable_section_name (filedata, sec),
- sec->sh_offset,
- num_unwind);
-
- if (! slurp_hppa_unwind_table (filedata, &aux, sec))
- res = false;
-
- if (res && aux.table_len > 0)
- {
- if (! dump_hppa_unwind (filedata, &aux))
- res = false;
- }
-
- free ((char *) aux.table);
- aux.table = NULL;
- }
- }
-
- free (aux.symtab);
- free ((char *) aux.strtab);
-
- return res;
-}
-
-struct arm_section
-{
- unsigned char * data; /* The unwind data. */
- Elf_Internal_Shdr * sec; /* The cached unwind section header. */
- Elf_Internal_Rela * rela; /* The cached relocations for this section. */
- uint64_t nrelas; /* The number of relocations. */
- unsigned int rel_type; /* REL or RELA ? */
- Elf_Internal_Rela * next_rela; /* Cyclic pointer to the next reloc to process. */
-};
-
-struct arm_unw_aux_info
-{
- Filedata * filedata; /* The file containing the unwind sections. */
- Elf_Internal_Sym * symtab; /* The file's symbol table. */
- uint64_t nsyms; /* Number of symbols. */
- Elf_Internal_Sym * funtab; /* Sorted table of STT_FUNC symbols. */
- uint64_t nfuns; /* Number of these symbols. */
- char * strtab; /* The file's string table. */
- uint64_t strtab_size; /* Size of string table. */
-};
-
-static const char *
-arm_print_vma_and_name (Filedata * filedata,
- struct arm_unw_aux_info * aux,
- uint64_t fn,
- struct absaddr addr)
-{
- const char *procname;
- uint64_t sym_offset;
-
- if (addr.section == SHN_UNDEF)
- addr.offset = fn;
-
- find_symbol_for_address (filedata, aux->funtab, aux->nfuns, aux->strtab,
- aux->strtab_size, addr, &procname,
- &sym_offset);
-
- print_vma (fn, PREFIX_HEX);
-
- if (procname)
- {
- fputs (" <", stdout);
- fputs (procname, stdout);
-
- if (sym_offset)
- printf ("+0x%" PRIx64, sym_offset);
- fputc ('>', stdout);
- }
-
- return procname;
-}
-
-static void
-arm_free_section (struct arm_section *arm_sec)
-{
- free (arm_sec->data);
- free (arm_sec->rela);
-}
-
-/* 1) If SEC does not match the one cached in ARM_SEC, then free the current
- cached section and install SEC instead.
- 2) Locate the 32-bit word at WORD_OFFSET in unwind section SEC
- and return its valued in * WORDP, relocating if necessary.
- 3) Update the NEXT_RELA field in ARM_SEC and store the section index and
- relocation's offset in ADDR.
- 4) If SYM_NAME is non-NULL and a relocation was applied, record the offset
- into the string table of the symbol associated with the reloc. If no
- reloc was applied store -1 there.
- 5) Return TRUE upon success, FALSE otherwise. */
-
-static bool
-get_unwind_section_word (Filedata * filedata,
- struct arm_unw_aux_info * aux,
- struct arm_section * arm_sec,
- Elf_Internal_Shdr * sec,
- uint64_t word_offset,
- unsigned int * wordp,
- struct absaddr * addr,
- uint64_t * sym_name)
-{
- Elf_Internal_Rela *rp;
- Elf_Internal_Sym *sym;
- const char * relname;
- unsigned int word;
- bool wrapped;
-
- if (sec == NULL || arm_sec == NULL)
- return false;
-
- addr->section = SHN_UNDEF;
- addr->offset = 0;
-
- if (sym_name != NULL)
- *sym_name = (uint64_t) -1;
-
- /* If necessary, update the section cache. */
- if (sec != arm_sec->sec)
- {
- Elf_Internal_Shdr *relsec;
-
- arm_free_section (arm_sec);
-
- arm_sec->sec = sec;
- arm_sec->data = get_data (NULL, aux->filedata, sec->sh_offset, 1,
- sec->sh_size, _("unwind data"));
- arm_sec->rela = NULL;
- arm_sec->nrelas = 0;
-
- for (relsec = filedata->section_headers;
- relsec < filedata->section_headers + filedata->file_header.e_shnum;
- ++relsec)
- {
- if (relsec->sh_info >= filedata->file_header.e_shnum
- || filedata->section_headers + relsec->sh_info != sec
- /* PR 15745: Check the section type as well. */
- || (relsec->sh_type != SHT_REL
- && relsec->sh_type != SHT_RELA))
- continue;
-
- arm_sec->rel_type = relsec->sh_type;
- if (relsec->sh_type == SHT_REL)
- {
- if (!slurp_rel_relocs (aux->filedata, relsec->sh_offset,
- relsec->sh_size,
- & arm_sec->rela, & arm_sec->nrelas))
- return false;
- }
- else /* relsec->sh_type == SHT_RELA */
- {
- if (!slurp_rela_relocs (aux->filedata, relsec->sh_offset,
- relsec->sh_size,
- & arm_sec->rela, & arm_sec->nrelas))
- return false;
- }
- break;
- }
-
- arm_sec->next_rela = arm_sec->rela;
- }
-
- /* If there is no unwind data we can do nothing. */
- if (arm_sec->data == NULL)
- return false;
-
- /* If the offset is invalid then fail. */
- if (/* PR 21343 *//* PR 18879 */
- sec->sh_size < 4
- || word_offset > sec->sh_size - 4)
- return false;
-
- /* Get the word at the required offset. */
- word = byte_get (arm_sec->data + word_offset, 4);
-
- /* PR 17531: file: id:000001,src:001266+003044,op:splice,rep:128. */
- if (arm_sec->rela == NULL)
- {
- * wordp = word;
- return true;
- }
-
- /* Look through the relocs to find the one that applies to the provided offset. */
- wrapped = false;
- for (rp = arm_sec->next_rela; rp != arm_sec->rela + arm_sec->nrelas; rp++)
- {
- uint64_t prelval, offset;
-
- if (rp->r_offset > word_offset && !wrapped)
- {
- rp = arm_sec->rela;
- wrapped = true;
- }
- if (rp->r_offset > word_offset)
- break;
-
- if (rp->r_offset & 3)
- {
- warn (_("Skipping unexpected relocation at offset %#" PRIx64 "\n"),
- rp->r_offset);
- continue;
- }
-
- if (rp->r_offset < word_offset)
- continue;
-
- /* PR 17531: file: 027-161405-0.004 */
- if (aux->symtab == NULL)
- continue;
-
- if (arm_sec->rel_type == SHT_REL)
- {
- offset = word & 0x7fffffff;
- if (offset & 0x40000000)
- offset |= ~ (uint64_t) 0x7fffffff;
- }
- else if (arm_sec->rel_type == SHT_RELA)
- offset = rp->r_addend;
- else
- {
- error (_("Unknown section relocation type %d encountered\n"),
- arm_sec->rel_type);
- break;
- }
-
- /* PR 17531 file: 027-1241568-0.004. */
- if (ELF32_R_SYM (rp->r_info) >= aux->nsyms)
- {
- error (_("Bad symbol index in unwind relocation "
- "(%" PRIu64 " > %" PRIu64 ")\n"),
- ELF32_R_SYM (rp->r_info), aux->nsyms);
- break;
- }
-
- sym = aux->symtab + ELF32_R_SYM (rp->r_info);
- offset += sym->st_value;
- prelval = offset - (arm_sec->sec->sh_addr + rp->r_offset);
-
- /* Check that we are processing the expected reloc type. */
- if (filedata->file_header.e_machine == EM_ARM)
- {
- relname = elf_arm_reloc_type (ELF32_R_TYPE (rp->r_info));
- if (relname == NULL)
- {
- warn (_("Skipping unknown ARM relocation type: %d\n"),
- (int) ELF32_R_TYPE (rp->r_info));
- continue;
- }
-
- if (streq (relname, "R_ARM_NONE"))
- continue;
-
- if (! streq (relname, "R_ARM_PREL31"))
- {
- warn (_("Skipping unexpected ARM relocation type %s\n"), relname);
- continue;
- }
- }
- else if (filedata->file_header.e_machine == EM_TI_C6000)
- {
- relname = elf_tic6x_reloc_type (ELF32_R_TYPE (rp->r_info));
- if (relname == NULL)
- {
- warn (_("Skipping unknown C6000 relocation type: %d\n"),
- (int) ELF32_R_TYPE (rp->r_info));
- continue;
- }
-
- if (streq (relname, "R_C6000_NONE"))
- continue;
-
- if (! streq (relname, "R_C6000_PREL31"))
- {
- warn (_("Skipping unexpected C6000 relocation type %s\n"), relname);
- continue;
- }
-
- prelval >>= 1;
- }
- else
- {
- /* This function currently only supports ARM and TI unwinders. */
- warn (_("Only TI and ARM unwinders are currently supported\n"));
- break;
- }
-
- word = (word & ~ (uint64_t) 0x7fffffff) | (prelval & 0x7fffffff);
- addr->section = sym->st_shndx;
- addr->offset = offset;
-
- if (sym_name)
- * sym_name = sym->st_name;
- break;
- }
-
- *wordp = word;
- arm_sec->next_rela = rp;
-
- return true;
-}
-
-static const char *tic6x_unwind_regnames[16] =
-{
- "A15", "B15", "B14", "B13", "B12", "B11", "B10", "B3",
- "A14", "A13", "A12", "A11", "A10",
- "[invalid reg 13]", "[invalid reg 14]", "[invalid reg 15]"
-};
-
-static void
-decode_tic6x_unwind_regmask (unsigned int mask)
-{
- int i;
-
- for (i = 12; mask; mask >>= 1, i--)
- {
- if (mask & 1)
- {
- fputs (tic6x_unwind_regnames[i], stdout);
- if (mask > 1)
- fputs (", ", stdout);
- }
- }
-}
-
-#define ADVANCE \
- if (remaining == 0 && more_words) \
- { \
- data_offset += 4; \
- if (! get_unwind_section_word (filedata, aux, data_arm_sec, data_sec, \
- data_offset, & word, & addr, NULL)) \
- return false; \
- remaining = 4; \
- more_words--; \
- } \
-
-#define GET_OP(OP) \
- ADVANCE; \
- if (remaining) \
- { \
- remaining--; \
- (OP) = word >> 24; \
- word <<= 8; \
- } \
- else \
- { \
- printf (_("[Truncated opcode]\n")); \
- return false; \
- } \
- printf ("0x%02x ", OP)
-
-static bool
-decode_arm_unwind_bytecode (Filedata * filedata,
- struct arm_unw_aux_info * aux,
- unsigned int word,
- unsigned int remaining,
- unsigned int more_words,
- uint64_t data_offset,
- Elf_Internal_Shdr * data_sec,
- struct arm_section * data_arm_sec)
-{
- struct absaddr addr;
- bool res = true;
-
- /* Decode the unwinding instructions. */
- while (1)
- {
- unsigned int op, op2;
-
- ADVANCE;
- if (remaining == 0)
- break;
- remaining--;
- op = word >> 24;
- word <<= 8;
-
- printf (" 0x%02x ", op);
-
- if ((op & 0xc0) == 0x00)
- {
- int offset = ((op & 0x3f) << 2) + 4;
-
- printf (" vsp = vsp + %d", offset);
- }
- else if ((op & 0xc0) == 0x40)
- {
- int offset = ((op & 0x3f) << 2) + 4;
-
- printf (" vsp = vsp - %d", offset);
- }
- else if ((op & 0xf0) == 0x80)
- {
- GET_OP (op2);
- if (op == 0x80 && op2 == 0)
- printf (_("Refuse to unwind"));
- else
- {
- unsigned int mask = ((op & 0x0f) << 8) | op2;
- bool first = true;
- int i;
-
- printf ("pop {");
- for (i = 0; i < 12; i++)
- if (mask & (1 << i))
- {
- if (first)
- first = false;
- else
- printf (", ");
- printf ("r%d", 4 + i);
- }
- printf ("}");
- }
- }
- else if ((op & 0xf0) == 0x90)
- {
- if (op == 0x9d || op == 0x9f)
- printf (_(" [Reserved]"));
- else
- printf (" vsp = r%d", op & 0x0f);
- }
- else if ((op & 0xf0) == 0xa0)
- {
- int end = 4 + (op & 0x07);
- bool first = true;
- int i;
-
- printf (" pop {");
- for (i = 4; i <= end; i++)
- {
- if (first)
- first = false;
- else
- printf (", ");
- printf ("r%d", i);
- }
- if (op & 0x08)
- {
- if (!first)
- printf (", ");
- printf ("r14");
- }
- printf ("}");
- }
- else if (op == 0xb0)
- printf (_(" finish"));
- else if (op == 0xb1)
- {
- GET_OP (op2);
- if (op2 == 0 || (op2 & 0xf0) != 0)
- printf (_("[Spare]"));
- else
- {
- unsigned int mask = op2 & 0x0f;
- bool first = true;
- int i;
-
- printf ("pop {");
- for (i = 0; i < 12; i++)
- if (mask & (1 << i))
- {
- if (first)
- first = false;
- else
- printf (", ");
- printf ("r%d", i);
- }
- printf ("}");
- }
- }
- else if (op == 0xb2)
- {
- unsigned char buf[9];
- unsigned int i, len;
- uint64_t offset;
-
- for (i = 0; i < sizeof (buf); i++)
- {
- GET_OP (buf[i]);
- if ((buf[i] & 0x80) == 0)
- break;
- }
- if (i == sizeof (buf))
- {
- error (_("corrupt change to vsp\n"));
- res = false;
- }
- else
- {
- offset = read_leb128 (buf, buf + i + 1, false, &len, NULL);
- assert (len == i + 1);
- offset = offset * 4 + 0x204;
- printf ("vsp = vsp + %" PRId64, offset);
- }
- }
- else if (op == 0xb3 || op == 0xc8 || op == 0xc9)
- {
- unsigned int first, last;
-
- GET_OP (op2);
- first = op2 >> 4;
- last = op2 & 0x0f;
- if (op == 0xc8)
- first = first + 16;
- printf ("pop {D%d", first);
- if (last)
- printf ("-D%d", first + last);
- printf ("}");
- }
- else if (op == 0xb4)
- printf (_(" pop {ra_auth_code}"));
- else if (op == 0xb5)
- printf (_(" vsp as modifier for PAC validation"));
- else if ((op & 0xf8) == 0xb8 || (op & 0xf8) == 0xd0)
- {
- unsigned int count = op & 0x07;
-
- printf ("pop {D8");
- if (count)
- printf ("-D%d", 8 + count);
- printf ("}");
- }
- else if (op >= 0xc0 && op <= 0xc5)
- {
- unsigned int count = op & 0x07;
-
- printf (" pop {wR10");
- if (count)
- printf ("-wR%d", 10 + count);
- printf ("}");
- }
- else if (op == 0xc6)
- {
- unsigned int first, last;
-
- GET_OP (op2);
- first = op2 >> 4;
- last = op2 & 0x0f;
- printf ("pop {wR%d", first);
- if (last)
- printf ("-wR%d", first + last);
- printf ("}");
- }
- else if (op == 0xc7)
- {
- GET_OP (op2);
- if (op2 == 0 || (op2 & 0xf0) != 0)
- printf (_("[Spare]"));
- else
- {
- unsigned int mask = op2 & 0x0f;
- bool first = true;
- int i;
-
- printf ("pop {");
- for (i = 0; i < 4; i++)
- if (mask & (1 << i))
- {
- if (first)
- first = false;
- else
- printf (", ");
- printf ("wCGR%d", i);
- }
- printf ("}");
- }
- }
- else
- {
- printf (_(" [unsupported opcode]"));
- res = false;
- }
-
- printf ("\n");
- }
-
- return res;
-}
-
-static bool
-decode_tic6x_unwind_bytecode (Filedata * filedata,
- struct arm_unw_aux_info * aux,
- unsigned int word,
- unsigned int remaining,
- unsigned int more_words,
- uint64_t data_offset,
- Elf_Internal_Shdr * data_sec,
- struct arm_section * data_arm_sec)
-{
- struct absaddr addr;
-
- /* Decode the unwinding instructions. */
- while (1)
- {
- unsigned int op, op2;
-
- ADVANCE;
- if (remaining == 0)
- break;
- remaining--;
- op = word >> 24;
- word <<= 8;
-
- printf (" 0x%02x ", op);
-
- if ((op & 0xc0) == 0x00)
- {
- int offset = ((op & 0x3f) << 3) + 8;
- printf (" sp = sp + %d", offset);
- }
- else if ((op & 0xc0) == 0x80)
- {
- GET_OP (op2);
- if (op == 0x80 && op2 == 0)
- printf (_("Refuse to unwind"));
- else
- {
- unsigned int mask = ((op & 0x1f) << 8) | op2;
- if (op & 0x20)
- printf ("pop compact {");
- else
- printf ("pop {");
-
- decode_tic6x_unwind_regmask (mask);
- printf("}");
- }
- }
- else if ((op & 0xf0) == 0xc0)
- {
- unsigned int reg;
- unsigned int nregs;
- unsigned int i;
- const char *name;
- struct
- {
- unsigned int offset;
- unsigned int reg;
- } regpos[16];
-
- /* Scan entire instruction first so that GET_OP output is not
- interleaved with disassembly. */
- nregs = 0;
- for (i = 0; nregs < (op & 0xf); i++)
- {
- GET_OP (op2);
- reg = op2 >> 4;
- if (reg != 0xf)
- {
- regpos[nregs].offset = i * 2;
- regpos[nregs].reg = reg;
- nregs++;
- }
-
- reg = op2 & 0xf;
- if (reg != 0xf)
- {
- regpos[nregs].offset = i * 2 + 1;
- regpos[nregs].reg = reg;
- nregs++;
- }
- }
-
- printf (_("pop frame {"));
- if (nregs == 0)
- {
- printf (_("*corrupt* - no registers specified"));
- }
- else
- {
- reg = nregs - 1;
- for (i = i * 2; i > 0; i--)
- {
- if (regpos[reg].offset == i - 1)
- {
- name = tic6x_unwind_regnames[regpos[reg].reg];
- if (reg > 0)
- reg--;
- }
- else
- name = _("[pad]");
-
- fputs (name, stdout);
- if (i > 1)
- printf (", ");
- }
- }
-
- printf ("}");
- }
- else if (op == 0xd0)
- printf (" MOV FP, SP");
- else if (op == 0xd1)
- printf (" __c6xabi_pop_rts");
- else if (op == 0xd2)
- {
- unsigned char buf[9];
- unsigned int i, len;
- uint64_t offset;
-
- for (i = 0; i < sizeof (buf); i++)
- {
- GET_OP (buf[i]);
- if ((buf[i] & 0x80) == 0)
- break;
- }
- /* PR 17531: file: id:000001,src:001906+004739,op:splice,rep:2. */
- if (i == sizeof (buf))
- {
- warn (_("Corrupt stack pointer adjustment detected\n"));
- return false;
- }
-
- offset = read_leb128 (buf, buf + i + 1, false, &len, NULL);
- assert (len == i + 1);
- offset = offset * 8 + 0x408;
- printf (_("sp = sp + %" PRId64), offset);
- }
- else if ((op & 0xf0) == 0xe0)
- {
- if ((op & 0x0f) == 7)
- printf (" RETURN");
- else
- printf (" MV %s, B3", tic6x_unwind_regnames[op & 0x0f]);
- }
- else
- {
- printf (_(" [unsupported opcode]"));
- }
- putchar ('\n');
- }
-
- return true;
-}
-
-static uint64_t
-arm_expand_prel31 (Filedata * filedata, uint64_t word, uint64_t where)
-{
- uint64_t offset;
-
- offset = word & 0x7fffffff;
- if (offset & 0x40000000)
- offset |= ~ (uint64_t) 0x7fffffff;
-
- if (filedata->file_header.e_machine == EM_TI_C6000)
- offset <<= 1;
-
- return offset + where;
-}
-
-static bool
-decode_arm_unwind (Filedata * filedata,
- struct arm_unw_aux_info * aux,
- unsigned int word,
- unsigned int remaining,
- uint64_t data_offset,
- Elf_Internal_Shdr * data_sec,
- struct arm_section * data_arm_sec)
-{
- int per_index;
- unsigned int more_words = 0;
- struct absaddr addr;
- uint64_t sym_name = (uint64_t) -1;
- bool res = true;
-
- if (remaining == 0)
- {
- /* Fetch the first word.
- Note - when decoding an object file the address extracted
- here will always be 0. So we also pass in the sym_name
- parameter so that we can find the symbol associated with
- the personality routine. */
- if (! get_unwind_section_word (filedata, aux, data_arm_sec, data_sec, data_offset,
- & word, & addr, & sym_name))
- return false;
-
- remaining = 4;
- }
- else
- {
- addr.section = SHN_UNDEF;
- addr.offset = 0;
- }
-
- if ((word & 0x80000000) == 0)
- {
- /* Expand prel31 for personality routine. */
- uint64_t fn;
- const char *procname;
-
- fn = arm_expand_prel31 (filedata, word, data_sec->sh_addr + data_offset);
- printf (_(" Personality routine: "));
- if (fn == 0
- && addr.section == SHN_UNDEF && addr.offset == 0
- && sym_name != (uint64_t) -1 && sym_name < aux->strtab_size)
- {
- procname = aux->strtab + sym_name;
- print_vma (fn, PREFIX_HEX);
- if (procname)
- {
- fputs (" <", stdout);
- fputs (procname, stdout);
- fputc ('>', stdout);
- }
- }
- else
- procname = arm_print_vma_and_name (filedata, aux, fn, addr);
- fputc ('\n', stdout);
-
- /* The GCC personality routines use the standard compact
- encoding, starting with one byte giving the number of
- words. */
- if (procname != NULL
- && (startswith (procname, "__gcc_personality_v0")
- || startswith (procname, "__gxx_personality_v0")
- || startswith (procname, "__gcj_personality_v0")
- || startswith (procname, "__gnu_objc_personality_v0")))
- {
- remaining = 0;
- more_words = 1;
- ADVANCE;
- if (!remaining)
- {
- printf (_(" [Truncated data]\n"));
- return false;
- }
- more_words = word >> 24;
- word <<= 8;
- remaining--;
- per_index = -1;
- }
- else
- return true;
- }
- else
- {
- /* ARM EHABI Section 6.3:
-
- An exception-handling table entry for the compact model looks like:
-
- 31 30-28 27-24 23-0
- -- ----- ----- ----
- 1 0 index Data for personalityRoutine[index] */
-
- if (filedata->file_header.e_machine == EM_ARM
- && (word & 0x70000000))
- {
- warn (_("Corrupt ARM compact model table entry: %x \n"), word);
- res = false;
- }
-
- per_index = (word >> 24) & 0x7f;
- printf (_(" Compact model index: %d\n"), per_index);
- if (per_index == 0)
- {
- more_words = 0;
- word <<= 8;
- remaining--;
- }
- else if (per_index < 3)
- {
- more_words = (word >> 16) & 0xff;
- word <<= 16;
- remaining -= 2;
- }
- }
-
- switch (filedata->file_header.e_machine)
- {
- case EM_ARM:
- if (per_index < 3)
- {
- if (! decode_arm_unwind_bytecode (filedata, aux, word, remaining, more_words,
- data_offset, data_sec, data_arm_sec))
- res = false;
- }
- else
- {
- warn (_("Unknown ARM compact model index encountered\n"));
- printf (_(" [reserved]\n"));
- res = false;
- }
- break;
-
- case EM_TI_C6000:
- if (per_index < 3)
- {
- if (! decode_tic6x_unwind_bytecode (filedata, aux, word, remaining, more_words,
- data_offset, data_sec, data_arm_sec))
- res = false;
- }
- else if (per_index < 5)
- {
- if (((word >> 17) & 0x7f) == 0x7f)
- printf (_(" Restore stack from frame pointer\n"));
- else
- printf (_(" Stack increment %d\n"), (word >> 14) & 0x1fc);
- printf (_(" Registers restored: "));
- if (per_index == 4)
- printf (" (compact) ");
- decode_tic6x_unwind_regmask ((word >> 4) & 0x1fff);
- putchar ('\n');
- printf (_(" Return register: %s\n"),
- tic6x_unwind_regnames[word & 0xf]);
- }
- else
- printf (_(" [reserved (%d)]\n"), per_index);
- break;
-
- default:
- error (_("Unsupported architecture type %d encountered when decoding unwind table\n"),
- filedata->file_header.e_machine);
- res = false;
- }
-
- /* Decode the descriptors. Not implemented. */
-
- return res;
-}
-
-static bool
-dump_arm_unwind (Filedata * filedata,
- struct arm_unw_aux_info * aux,
- Elf_Internal_Shdr * exidx_sec)
-{
- struct arm_section exidx_arm_sec, extab_arm_sec;
- unsigned int i, exidx_len;
- uint64_t j, nfuns;
- bool res = true;
-
- memset (&exidx_arm_sec, 0, sizeof (exidx_arm_sec));
- memset (&extab_arm_sec, 0, sizeof (extab_arm_sec));
- exidx_len = exidx_sec->sh_size / 8;
-
- aux->funtab = xmalloc (aux->nsyms * sizeof (Elf_Internal_Sym));
- for (nfuns = 0, j = 0; j < aux->nsyms; j++)
- if (aux->symtab[j].st_value && ELF_ST_TYPE (aux->symtab[j].st_info) == STT_FUNC)
- aux->funtab[nfuns++] = aux->symtab[j];
- aux->nfuns = nfuns;
- qsort (aux->funtab, aux->nfuns, sizeof (Elf_Internal_Sym), symcmp);
-
- for (i = 0; i < exidx_len; i++)
- {
- unsigned int exidx_fn, exidx_entry;
- struct absaddr fn_addr, entry_addr;
- uint64_t fn;
-
- fputc ('\n', stdout);
-
- if (! get_unwind_section_word (filedata, aux, & exidx_arm_sec, exidx_sec,
- 8 * i, & exidx_fn, & fn_addr, NULL)
- || ! get_unwind_section_word (filedata, aux, & exidx_arm_sec, exidx_sec,
- 8 * i + 4, & exidx_entry, & entry_addr, NULL))
- {
- free (aux->funtab);
- arm_free_section (& exidx_arm_sec);
- arm_free_section (& extab_arm_sec);
- return false;
- }
-
- /* ARM EHABI, Section 5:
- An index table entry consists of 2 words.
- The first word contains a prel31 offset to the start of a function, with bit 31 clear. */
- if (exidx_fn & 0x80000000)
- {
- warn (_("corrupt index table entry: %x\n"), exidx_fn);
- res = false;
- }
-
- fn = arm_expand_prel31 (filedata, exidx_fn, exidx_sec->sh_addr + 8 * i);
-
- arm_print_vma_and_name (filedata, aux, fn, fn_addr);
- fputs (": ", stdout);
-
- if (exidx_entry == 1)
- {
- print_vma (exidx_entry, PREFIX_HEX);
- fputs (" [cantunwind]\n", stdout);
- }
- else if (exidx_entry & 0x80000000)
- {
- print_vma (exidx_entry, PREFIX_HEX);
- fputc ('\n', stdout);
- decode_arm_unwind (filedata, aux, exidx_entry, 4, 0, NULL, NULL);
- }
- else
- {
- uint64_t table, table_offset = 0;
- Elf_Internal_Shdr *table_sec;
-
- fputs ("@", stdout);
- table = arm_expand_prel31 (filedata, exidx_entry, exidx_sec->sh_addr + 8 * i + 4);
- print_vma (table, PREFIX_HEX);
- printf ("\n");
-
- /* Locate the matching .ARM.extab. */
- if (entry_addr.section != SHN_UNDEF
- && entry_addr.section < filedata->file_header.e_shnum)
- {
- table_sec = filedata->section_headers + entry_addr.section;
- table_offset = entry_addr.offset;
- /* PR 18879 */
- if (table_offset > table_sec->sh_size)
- {
- warn (_("Unwind entry contains corrupt offset (%#" PRIx64 ") into section %s\n"),
- table_offset,
- printable_section_name (filedata, table_sec));
- res = false;
- continue;
- }
- }
- else
- {
- table_sec = find_section_by_address (filedata, table);
- if (table_sec != NULL)
- table_offset = table - table_sec->sh_addr;
- }
-
- if (table_sec == NULL)
- {
- warn (_("Could not locate .ARM.extab section containing %#" PRIx64 ".\n"),
- table);
- res = false;
- continue;
- }
-
- if (! decode_arm_unwind (filedata, aux, 0, 0, table_offset, table_sec,
- &extab_arm_sec))
- res = false;
- }
- }
-
- printf ("\n");
-
- free (aux->funtab);
- arm_free_section (&exidx_arm_sec);
- arm_free_section (&extab_arm_sec);
-
- return res;
-}
-
-/* Used for both ARM and C6X unwinding tables. */
-
-static bool
-arm_process_unwind (Filedata * filedata)
-{
- struct arm_unw_aux_info aux;
- Elf_Internal_Shdr *unwsec = NULL;
- Elf_Internal_Shdr *sec;
- size_t i;
- unsigned int sec_type;
- bool res = true;
-
- switch (filedata->file_header.e_machine)
- {
- case EM_ARM:
- sec_type = SHT_ARM_EXIDX;
- break;
-
- case EM_TI_C6000:
- sec_type = SHT_C6000_UNWIND;
- break;
-
- default:
- error (_("Unsupported architecture type %d encountered when processing unwind table\n"),
- filedata->file_header.e_machine);
- return false;
- }
-
- if (filedata->string_table == NULL)
- return false;
-
- memset (& aux, 0, sizeof (aux));
- aux.filedata = filedata;
-
- for (i = 0, sec = filedata->section_headers; i < filedata->file_header.e_shnum; ++i, ++sec)
- {
- if (sec->sh_type == SHT_SYMTAB)
- {
- if (aux.symtab)
- {
- error (_("Multiple symbol tables encountered\n"));
- free (aux.symtab);
- aux.symtab = NULL;
- free (aux.strtab);
- aux.strtab = NULL;
- }
- if (!get_symtab (filedata, sec, &aux.symtab, &aux.nsyms,
- &aux.strtab, &aux.strtab_size))
- return false;
- }
- else if (sec->sh_type == sec_type)
- unwsec = sec;
- }
-
- if (unwsec == NULL)
- printf (_("\nThere are no unwind sections in this file.\n"));
- else
- for (i = 0, sec = filedata->section_headers; i < filedata->file_header.e_shnum; ++i, ++sec)
- {
- if (sec->sh_type == sec_type)
- {
- uint64_t num_unwind = sec->sh_size / (2 * eh_addr_size);
- printf (ngettext ("\nUnwind section '%s' at offset %#" PRIx64 " "
- "contains %" PRIu64 " entry:\n",
- "\nUnwind section '%s' at offset %#" PRIx64 " "
- "contains %" PRIu64 " entries:\n",
- num_unwind),
- printable_section_name (filedata, sec),
- sec->sh_offset,
- num_unwind);
-
- if (! dump_arm_unwind (filedata, &aux, sec))
- res = false;
- }
- }
-
- free (aux.symtab);
- free ((char *) aux.strtab);
-
- return res;
-}
-
-static bool
-no_processor_specific_unwind (Filedata * filedata ATTRIBUTE_UNUSED)
-{
- printf (_("No processor specific unwind information to decode\n"));
- return true;
-}
-
-static bool
-process_unwind (Filedata * filedata)
-{
- struct unwind_handler
- {
- unsigned int machtype;
- bool (* handler)(Filedata *);
- } handlers[] =
- {
- { EM_ARM, arm_process_unwind },
- { EM_IA_64, ia64_process_unwind },
- { EM_PARISC, hppa_process_unwind },
- { EM_TI_C6000, arm_process_unwind },
- { EM_386, no_processor_specific_unwind },
- { EM_X86_64, no_processor_specific_unwind },
- { 0, NULL }
- };
- int i;
-
- if (!do_unwind)
- return true;
-
- for (i = 0; handlers[i].handler != NULL; i++)
- if (filedata->file_header.e_machine == handlers[i].machtype)
- return handlers[i].handler (filedata);
-
- printf (_("\nThe decoding of unwind sections for machine type %s is not currently supported.\n"),
- get_machine_name (filedata->file_header.e_machine));
- return true;
-}
-
-static void
-dynamic_section_aarch64_val (Elf_Internal_Dyn * entry)
-{
- switch (entry->d_tag)
- {
- case DT_AARCH64_BTI_PLT:
- case DT_AARCH64_PAC_PLT:
- break;
- default:
- print_vma (entry->d_un.d_ptr, PREFIX_HEX);
- break;
- }
- putchar ('\n');
-}
-
-static void
-dynamic_section_mips_val (Filedata * filedata, Elf_Internal_Dyn * entry)
-{
- switch (entry->d_tag)
- {
- case DT_MIPS_FLAGS:
- if (entry->d_un.d_val == 0)
- printf (_("NONE"));
- else
- {
- static const char * opts[] =
- {
- "QUICKSTART", "NOTPOT", "NO_LIBRARY_REPLACEMENT",
- "NO_MOVE", "SGI_ONLY", "GUARANTEE_INIT", "DELTA_C_PLUS_PLUS",
- "GUARANTEE_START_INIT", "PIXIE", "DEFAULT_DELAY_LOAD",
- "REQUICKSTART", "REQUICKSTARTED", "CORD", "NO_UNRES_UNDEF",
- "RLD_ORDER_SAFE"
- };
- unsigned int cnt;
- bool first = true;
-
- for (cnt = 0; cnt < ARRAY_SIZE (opts); ++cnt)
- if (entry->d_un.d_val & (1 << cnt))
- {
- printf ("%s%s", first ? "" : " ", opts[cnt]);
- first = false;
- }
- }
- break;
-
- case DT_MIPS_IVERSION:
- if (valid_dynamic_name (filedata, entry->d_un.d_val))
- printf (_("Interface Version: %s"),
- get_dynamic_name (filedata, entry->d_un.d_val));
- else
- printf (_("Interface Version: <corrupt: %" PRIx64 ">"),
- entry->d_un.d_ptr);
- break;
-
- case DT_MIPS_TIME_STAMP:
- {
- char timebuf[128];
- struct tm * tmp;
- time_t atime = entry->d_un.d_val;
-
- tmp = gmtime (&atime);
- /* PR 17531: file: 6accc532. */
- if (tmp == NULL)
- snprintf (timebuf, sizeof (timebuf), _("<corrupt>"));
- else
- snprintf (timebuf, sizeof (timebuf), "%04u-%02u-%02uT%02u:%02u:%02u",
- tmp->tm_year + 1900, tmp->tm_mon + 1, tmp->tm_mday,
- tmp->tm_hour, tmp->tm_min, tmp->tm_sec);
- printf (_("Time Stamp: %s"), timebuf);
- }
- break;
-
- case DT_MIPS_RLD_VERSION:
- case DT_MIPS_LOCAL_GOTNO:
- case DT_MIPS_CONFLICTNO:
- case DT_MIPS_LIBLISTNO:
- case DT_MIPS_SYMTABNO:
- case DT_MIPS_UNREFEXTNO:
- case DT_MIPS_HIPAGENO:
- case DT_MIPS_DELTA_CLASS_NO:
- case DT_MIPS_DELTA_INSTANCE_NO:
- case DT_MIPS_DELTA_RELOC_NO:
- case DT_MIPS_DELTA_SYM_NO:
- case DT_MIPS_DELTA_CLASSSYM_NO:
- case DT_MIPS_COMPACT_SIZE:
- print_vma (entry->d_un.d_val, DEC);
- break;
-
- case DT_MIPS_XHASH:
- filedata->dynamic_info_DT_MIPS_XHASH = entry->d_un.d_val;
- filedata->dynamic_info_DT_GNU_HASH = entry->d_un.d_val;
- /* Falls through. */
-
- default:
- print_vma (entry->d_un.d_ptr, PREFIX_HEX);
- }
- putchar ('\n');
-}
-
-static void
-dynamic_section_parisc_val (Elf_Internal_Dyn * entry)
-{
- switch (entry->d_tag)
- {
- case DT_HP_DLD_FLAGS:
- {
- static struct
- {
- unsigned int bit;
- const char * str;
- }
- flags[] =
- {
- { DT_HP_DEBUG_PRIVATE, "HP_DEBUG_PRIVATE" },
- { DT_HP_DEBUG_CALLBACK, "HP_DEBUG_CALLBACK" },
- { DT_HP_DEBUG_CALLBACK_BOR, "HP_DEBUG_CALLBACK_BOR" },
- { DT_HP_NO_ENVVAR, "HP_NO_ENVVAR" },
- { DT_HP_BIND_NOW, "HP_BIND_NOW" },
- { DT_HP_BIND_NONFATAL, "HP_BIND_NONFATAL" },
- { DT_HP_BIND_VERBOSE, "HP_BIND_VERBOSE" },
- { DT_HP_BIND_RESTRICTED, "HP_BIND_RESTRICTED" },
- { DT_HP_BIND_SYMBOLIC, "HP_BIND_SYMBOLIC" },
- { DT_HP_RPATH_FIRST, "HP_RPATH_FIRST" },
- { DT_HP_BIND_DEPTH_FIRST, "HP_BIND_DEPTH_FIRST" },
- { DT_HP_GST, "HP_GST" },
- { DT_HP_SHLIB_FIXED, "HP_SHLIB_FIXED" },
- { DT_HP_MERGE_SHLIB_SEG, "HP_MERGE_SHLIB_SEG" },
- { DT_HP_NODELETE, "HP_NODELETE" },
- { DT_HP_GROUP, "HP_GROUP" },
- { DT_HP_PROTECT_LINKAGE_TABLE, "HP_PROTECT_LINKAGE_TABLE" }
- };
- bool first = true;
- size_t cnt;
- uint64_t val = entry->d_un.d_val;
-
- for (cnt = 0; cnt < ARRAY_SIZE (flags); ++cnt)
- if (val & flags[cnt].bit)
- {
- if (! first)
- putchar (' ');
- fputs (flags[cnt].str, stdout);
- first = false;
- val ^= flags[cnt].bit;
- }
-
- if (val != 0 || first)
- {
- if (! first)
- putchar (' ');
- print_vma (val, HEX);
- }
- }
- break;
-
- default:
- print_vma (entry->d_un.d_ptr, PREFIX_HEX);
- break;
- }
- putchar ('\n');
-}
-
-/* VMS vs Unix time offset and factor. */
-
-#define VMS_EPOCH_OFFSET 35067168000000000LL
-#define VMS_GRANULARITY_FACTOR 10000000
-#ifndef INT64_MIN
-#define INT64_MIN (-9223372036854775807LL - 1)
-#endif
-
-/* Display a VMS time in a human readable format. */
-
-static void
-print_vms_time (int64_t vmstime)
-{
- struct tm *tm = NULL;
- time_t unxtime;
-
- if (vmstime >= INT64_MIN + VMS_EPOCH_OFFSET)
- {
- vmstime = (vmstime - VMS_EPOCH_OFFSET) / VMS_GRANULARITY_FACTOR;
- unxtime = vmstime;
- if (unxtime == vmstime)
- tm = gmtime (&unxtime);
- }
- if (tm != NULL)
- printf ("%04u-%02u-%02uT%02u:%02u:%02u",
- tm->tm_year + 1900, tm->tm_mon + 1, tm->tm_mday,
- tm->tm_hour, tm->tm_min, tm->tm_sec);
-}
-
-static void
-dynamic_section_ia64_val (Elf_Internal_Dyn * entry)
-{
- switch (entry->d_tag)
- {
- case DT_IA_64_PLT_RESERVE:
- /* First 3 slots reserved. */
- print_vma (entry->d_un.d_ptr, PREFIX_HEX);
- printf (" -- ");
- print_vma (entry->d_un.d_ptr + (3 * 8), PREFIX_HEX);
- break;
-
- case DT_IA_64_VMS_LINKTIME:
- print_vms_time (entry->d_un.d_val);
- break;
-
- case DT_IA_64_VMS_LNKFLAGS:
- print_vma (entry->d_un.d_ptr, PREFIX_HEX);
- if (entry->d_un.d_val & VMS_LF_CALL_DEBUG)
- printf (" CALL_DEBUG");
- if (entry->d_un.d_val & VMS_LF_NOP0BUFS)
- printf (" NOP0BUFS");
- if (entry->d_un.d_val & VMS_LF_P0IMAGE)
- printf (" P0IMAGE");
- if (entry->d_un.d_val & VMS_LF_MKTHREADS)
- printf (" MKTHREADS");
- if (entry->d_un.d_val & VMS_LF_UPCALLS)
- printf (" UPCALLS");
- if (entry->d_un.d_val & VMS_LF_IMGSTA)
- printf (" IMGSTA");
- if (entry->d_un.d_val & VMS_LF_INITIALIZE)
- printf (" INITIALIZE");
- if (entry->d_un.d_val & VMS_LF_MAIN)
- printf (" MAIN");
- if (entry->d_un.d_val & VMS_LF_EXE_INIT)
- printf (" EXE_INIT");
- if (entry->d_un.d_val & VMS_LF_TBK_IN_IMG)
- printf (" TBK_IN_IMG");
- if (entry->d_un.d_val & VMS_LF_DBG_IN_IMG)
- printf (" DBG_IN_IMG");
- if (entry->d_un.d_val & VMS_LF_TBK_IN_DSF)
- printf (" TBK_IN_DSF");
- if (entry->d_un.d_val & VMS_LF_DBG_IN_DSF)
- printf (" DBG_IN_DSF");
- if (entry->d_un.d_val & VMS_LF_SIGNATURES)
- printf (" SIGNATURES");
- if (entry->d_un.d_val & VMS_LF_REL_SEG_OFF)
- printf (" REL_SEG_OFF");
- break;
-
- default:
- print_vma (entry->d_un.d_ptr, PREFIX_HEX);
- break;
- }
- putchar ('\n');
-}
-
-static bool
-get_32bit_dynamic_section (Filedata * filedata)
-{
- Elf32_External_Dyn * edyn;
- Elf32_External_Dyn * ext;
- Elf_Internal_Dyn * entry;
-
- edyn = (Elf32_External_Dyn *) get_data (NULL, filedata,
- filedata->dynamic_addr, 1,
- filedata->dynamic_size,
- _("dynamic section"));
- if (!edyn)
- return false;
-
- /* SGI's ELF has more than one section in the DYNAMIC segment, and we
- might not have the luxury of section headers. Look for the DT_NULL
- terminator to determine the number of entries. */
- for (ext = edyn, filedata->dynamic_nent = 0;
- (char *) (ext + 1) <= (char *) edyn + filedata->dynamic_size;
- ext++)
- {
- filedata->dynamic_nent++;
- if (BYTE_GET (ext->d_tag) == DT_NULL)
- break;
- }
-
- filedata->dynamic_section
- = (Elf_Internal_Dyn *) cmalloc (filedata->dynamic_nent, sizeof (* entry));
- if (filedata->dynamic_section == NULL)
- {
- error (_("Out of memory allocating space for %" PRIu64 " dynamic entries\n"),
- filedata->dynamic_nent);
- free (edyn);
- return false;
- }
-
- for (ext = edyn, entry = filedata->dynamic_section;
- entry < filedata->dynamic_section + filedata->dynamic_nent;
- ext++, entry++)
- {
- entry->d_tag = BYTE_GET (ext->d_tag);
- entry->d_un.d_val = BYTE_GET (ext->d_un.d_val);
- }
-
- free (edyn);
-
- return true;
-}
-
-static bool
-get_64bit_dynamic_section (Filedata * filedata)
-{
- Elf64_External_Dyn * edyn;
- Elf64_External_Dyn * ext;
- Elf_Internal_Dyn * entry;
-
- /* Read in the data. */
- edyn = (Elf64_External_Dyn *) get_data (NULL, filedata,
- filedata->dynamic_addr, 1,
- filedata->dynamic_size,
- _("dynamic section"));
- if (!edyn)
- return false;
-
- /* SGI's ELF has more than one section in the DYNAMIC segment, and we
- might not have the luxury of section headers. Look for the DT_NULL
- terminator to determine the number of entries. */
- for (ext = edyn, filedata->dynamic_nent = 0;
- /* PR 17533 file: 033-67080-0.004 - do not read past end of buffer. */
- (char *) (ext + 1) <= (char *) edyn + filedata->dynamic_size;
- ext++)
- {
- filedata->dynamic_nent++;
- if (BYTE_GET (ext->d_tag) == DT_NULL)
- break;
- }
-
- filedata->dynamic_section
- = (Elf_Internal_Dyn *) cmalloc (filedata->dynamic_nent, sizeof (* entry));
- if (filedata->dynamic_section == NULL)
- {
- error (_("Out of memory allocating space for %" PRIu64 " dynamic entries\n"),
- filedata->dynamic_nent);
- free (edyn);
- return false;
- }
-
- /* Convert from external to internal formats. */
- for (ext = edyn, entry = filedata->dynamic_section;
- entry < filedata->dynamic_section + filedata->dynamic_nent;
- ext++, entry++)
- {
- entry->d_tag = BYTE_GET (ext->d_tag);
- entry->d_un.d_val = BYTE_GET (ext->d_un.d_val);
- }
-
- free (edyn);
-
- return true;
-}
-
-static bool
-get_dynamic_section (Filedata *filedata)
-{
- if (filedata->dynamic_section)
- return true;
-
- if (is_32bit_elf)
- return get_32bit_dynamic_section (filedata);
- else
- return get_64bit_dynamic_section (filedata);
-}
-
-static void
-print_dynamic_flags (uint64_t flags)
-{
- bool first = true;
-
- while (flags)
- {
- uint64_t flag;
-
- flag = flags & - flags;
- flags &= ~ flag;
-
- if (first)
- first = false;
- else
- putc (' ', stdout);
-
- switch (flag)
- {
- case DF_ORIGIN: fputs ("ORIGIN", stdout); break;
- case DF_SYMBOLIC: fputs ("SYMBOLIC", stdout); break;
- case DF_TEXTREL: fputs ("TEXTREL", stdout); break;
- case DF_BIND_NOW: fputs ("BIND_NOW", stdout); break;
- case DF_STATIC_TLS: fputs ("STATIC_TLS", stdout); break;
- default: fputs (_("unknown"), stdout); break;
- }
- }
- puts ("");
-}
-
-static uint64_t *
-get_dynamic_data (Filedata * filedata, uint64_t number, unsigned int ent_size)
-{
- unsigned char * e_data;
- uint64_t * i_data;
-
- /* If size_t is smaller than uint64_t, eg because you are building
- on a 32-bit host, then make sure that when number is cast to
- size_t no information is lost. */
- if ((size_t) number != number
- || ent_size * number / ent_size != number)
- {
- error (_("Size overflow prevents reading %" PRIu64
- " elements of size %u\n"),
- number, ent_size);
- return NULL;
- }
-
- /* Be kind to memory checkers (eg valgrind, address sanitizer) by not
- attempting to allocate memory when the read is bound to fail. */
- if (ent_size * number > filedata->file_size)
- {
- error (_("Invalid number of dynamic entries: %" PRIu64 "\n"),
- number);
- return NULL;
- }
-
- e_data = (unsigned char *) cmalloc ((size_t) number, ent_size);
- if (e_data == NULL)
- {
- error (_("Out of memory reading %" PRIu64 " dynamic entries\n"),
- number);
- return NULL;
- }
-
- if (fread (e_data, ent_size, (size_t) number, filedata->handle) != number)
- {
- error (_("Unable to read in %" PRIu64 " bytes of dynamic data\n"),
- number * ent_size);
- free (e_data);
- return NULL;
- }
-
- i_data = (uint64_t *) cmalloc ((size_t) number, sizeof (*i_data));
- if (i_data == NULL)
- {
- error (_("Out of memory allocating space for %" PRIu64 " dynamic entries\n"),
- number);
- free (e_data);
- return NULL;
- }
-
- while (number--)
- i_data[number] = byte_get (e_data + number * ent_size, ent_size);
-
- free (e_data);
-
- return i_data;
-}
-
-static uint64_t
-get_num_dynamic_syms (Filedata * filedata)
-{
- uint64_t num_of_syms = 0;
-
- if (!do_histogram && (!do_using_dynamic || do_dyn_syms))
- return num_of_syms;
-
- if (filedata->dynamic_info[DT_HASH])
- {
- unsigned char nb[8];
- unsigned char nc[8];
- unsigned int hash_ent_size = 4;
-
- if ((filedata->file_header.e_machine == EM_ALPHA
- || filedata->file_header.e_machine == EM_S390
- || filedata->file_header.e_machine == EM_S390_OLD)
- && filedata->file_header.e_ident[EI_CLASS] == ELFCLASS64)
- hash_ent_size = 8;
-
- if (fseek64 (filedata->handle,
- (filedata->archive_file_offset
- + offset_from_vma (filedata,
- filedata->dynamic_info[DT_HASH],
- sizeof nb + sizeof nc)),
- SEEK_SET))
- {
- error (_("Unable to seek to start of dynamic information\n"));
- goto no_hash;
- }
-
- if (fread (nb, hash_ent_size, 1, filedata->handle) != 1)
- {
- error (_("Failed to read in number of buckets\n"));
- goto no_hash;
- }
-
- if (fread (nc, hash_ent_size, 1, filedata->handle) != 1)
- {
- error (_("Failed to read in number of chains\n"));
- goto no_hash;
- }
-
- filedata->nbuckets = byte_get (nb, hash_ent_size);
- filedata->nchains = byte_get (nc, hash_ent_size);
-
- if (filedata->nbuckets != 0 && filedata->nchains != 0)
- {
- filedata->buckets = get_dynamic_data (filedata, filedata->nbuckets,
- hash_ent_size);
- filedata->chains = get_dynamic_data (filedata, filedata->nchains,
- hash_ent_size);
-
- if (filedata->buckets != NULL && filedata->chains != NULL)
- num_of_syms = filedata->nchains;
- }
- no_hash:
- if (num_of_syms == 0)
- {
- free (filedata->buckets);
- filedata->buckets = NULL;
- free (filedata->chains);
- filedata->chains = NULL;
- filedata->nbuckets = 0;
- }
- }
-
- if (filedata->dynamic_info_DT_GNU_HASH)
- {
- unsigned char nb[16];
- uint64_t i, maxchain = 0xffffffff, bitmaskwords;
- uint64_t buckets_vma;
- uint64_t hn;
-
- if (fseek64 (filedata->handle,
- (filedata->archive_file_offset
- + offset_from_vma (filedata,
- filedata->dynamic_info_DT_GNU_HASH,
- sizeof nb)),
- SEEK_SET))
- {
- error (_("Unable to seek to start of dynamic information\n"));
- goto no_gnu_hash;
- }
-
- if (fread (nb, 16, 1, filedata->handle) != 1)
- {
- error (_("Failed to read in number of buckets\n"));
- goto no_gnu_hash;
- }
-
- filedata->ngnubuckets = byte_get (nb, 4);
- filedata->gnusymidx = byte_get (nb + 4, 4);
- bitmaskwords = byte_get (nb + 8, 4);
- buckets_vma = filedata->dynamic_info_DT_GNU_HASH + 16;
- if (is_32bit_elf)
- buckets_vma += bitmaskwords * 4;
- else
- buckets_vma += bitmaskwords * 8;
-
- if (fseek64 (filedata->handle,
- (filedata->archive_file_offset
- + offset_from_vma (filedata, buckets_vma, 4)),
- SEEK_SET))
- {
- error (_("Unable to seek to start of dynamic information\n"));
- goto no_gnu_hash;
- }
-
- filedata->gnubuckets
- = get_dynamic_data (filedata, filedata->ngnubuckets, 4);
-
- if (filedata->gnubuckets == NULL)
- goto no_gnu_hash;
-
- for (i = 0; i < filedata->ngnubuckets; i++)
- if (filedata->gnubuckets[i] != 0)
- {
- if (filedata->gnubuckets[i] < filedata->gnusymidx)
- goto no_gnu_hash;
-
- if (maxchain == 0xffffffff || filedata->gnubuckets[i] > maxchain)
- maxchain = filedata->gnubuckets[i];
- }
-
- if (maxchain == 0xffffffff)
- goto no_gnu_hash;
-
- maxchain -= filedata->gnusymidx;
-
- if (fseek64 (filedata->handle,
- (filedata->archive_file_offset
- + offset_from_vma (filedata,
- buckets_vma + 4 * (filedata->ngnubuckets
- + maxchain),
- 4)),
- SEEK_SET))
- {
- error (_("Unable to seek to start of dynamic information\n"));
- goto no_gnu_hash;
- }
-
- do
- {
- if (fread (nb, 4, 1, filedata->handle) != 1)
- {
- error (_("Failed to determine last chain length\n"));
- goto no_gnu_hash;
- }
-
- if (maxchain + 1 == 0)
- goto no_gnu_hash;
-
- ++maxchain;
- }
- while ((byte_get (nb, 4) & 1) == 0);
-
- if (fseek64 (filedata->handle,
- (filedata->archive_file_offset
- + offset_from_vma (filedata, (buckets_vma
- + 4 * filedata->ngnubuckets),
- 4)),
- SEEK_SET))
- {
- error (_("Unable to seek to start of dynamic information\n"));
- goto no_gnu_hash;
- }
-
- filedata->gnuchains = get_dynamic_data (filedata, maxchain, 4);
- filedata->ngnuchains = maxchain;
-
- if (filedata->gnuchains == NULL)
- goto no_gnu_hash;
-
- if (filedata->dynamic_info_DT_MIPS_XHASH)
- {
- if (fseek64 (filedata->handle,
- (filedata->archive_file_offset
- + offset_from_vma (filedata, (buckets_vma
- + 4 * (filedata->ngnubuckets
- + maxchain)), 4)),
- SEEK_SET))
- {
- error (_("Unable to seek to start of dynamic information\n"));
- goto no_gnu_hash;
- }
-
- filedata->mipsxlat = get_dynamic_data (filedata, maxchain, 4);
- if (filedata->mipsxlat == NULL)
- goto no_gnu_hash;
- }
-
- for (hn = 0; hn < filedata->ngnubuckets; ++hn)
- if (filedata->gnubuckets[hn] != 0)
- {
- uint64_t si = filedata->gnubuckets[hn];
- uint64_t off = si - filedata->gnusymidx;
-
- do
- {
- if (filedata->dynamic_info_DT_MIPS_XHASH)
- {
- if (off < filedata->ngnuchains
- && filedata->mipsxlat[off] >= num_of_syms)
- num_of_syms = filedata->mipsxlat[off] + 1;
- }
- else
- {
- if (si >= num_of_syms)
- num_of_syms = si + 1;
- }
- si++;
- }
- while (off < filedata->ngnuchains
- && (filedata->gnuchains[off++] & 1) == 0);
- }
-
- if (num_of_syms == 0)
- {
- no_gnu_hash:
- free (filedata->mipsxlat);
- filedata->mipsxlat = NULL;
- free (filedata->gnuchains);
- filedata->gnuchains = NULL;
- free (filedata->gnubuckets);
- filedata->gnubuckets = NULL;
- filedata->ngnubuckets = 0;
- filedata->ngnuchains = 0;
- }
- }
-
- return num_of_syms;
-}
-
-/* Parse and display the contents of the dynamic section. */
-
-static bool
-process_dynamic_section (Filedata * filedata)
-{
- Elf_Internal_Dyn * entry;
-
- if (filedata->dynamic_size <= 1)
- {
- if (do_dynamic)
- {
- if (filedata->is_separate)
- printf (_("\nThere is no dynamic section in linked file '%s'.\n"),
- filedata->file_name);
- else
- printf (_("\nThere is no dynamic section in this file.\n"));
- }
-
- return true;
- }
-
- if (!get_dynamic_section (filedata))
- return false;
-
- /* Find the appropriate symbol table. */
- if (filedata->dynamic_symbols == NULL || do_histogram)
- {
- uint64_t num_of_syms;
-
- for (entry = filedata->dynamic_section;
- entry < filedata->dynamic_section + filedata->dynamic_nent;
- ++entry)
- if (entry->d_tag == DT_SYMTAB)
- filedata->dynamic_info[DT_SYMTAB] = entry->d_un.d_val;
- else if (entry->d_tag == DT_SYMENT)
- filedata->dynamic_info[DT_SYMENT] = entry->d_un.d_val;
- else if (entry->d_tag == DT_HASH)
- filedata->dynamic_info[DT_HASH] = entry->d_un.d_val;
- else if (entry->d_tag == DT_GNU_HASH)
- filedata->dynamic_info_DT_GNU_HASH = entry->d_un.d_val;
- else if ((filedata->file_header.e_machine == EM_MIPS
- || filedata->file_header.e_machine == EM_MIPS_RS3_LE)
- && entry->d_tag == DT_MIPS_XHASH)
- {
- filedata->dynamic_info_DT_MIPS_XHASH = entry->d_un.d_val;
- filedata->dynamic_info_DT_GNU_HASH = entry->d_un.d_val;
- }
-
- num_of_syms = get_num_dynamic_syms (filedata);
-
- if (num_of_syms != 0
- && filedata->dynamic_symbols == NULL
- && filedata->dynamic_info[DT_SYMTAB]
- && filedata->dynamic_info[DT_SYMENT])
- {
- Elf_Internal_Phdr *seg;
- uint64_t vma = filedata->dynamic_info[DT_SYMTAB];
-
- if (! get_program_headers (filedata))
- {
- error (_("Cannot interpret virtual addresses "
- "without program headers.\n"));
- return false;
- }
-
- for (seg = filedata->program_headers;
- seg < filedata->program_headers + filedata->file_header.e_phnum;
- ++seg)
- {
- if (seg->p_type != PT_LOAD)
- continue;
-
- if (seg->p_offset + seg->p_filesz > filedata->file_size)
- {
- /* See PR 21379 for a reproducer. */
- error (_("Invalid PT_LOAD entry\n"));
- return false;
- }
-
- if (vma >= (seg->p_vaddr & -seg->p_align)
- && vma < seg->p_vaddr + seg->p_filesz)
- {
- /* Since we do not know how big the symbol table is,
- we default to reading in up to the end of PT_LOAD
- segment and processing that. This is overkill, I
- know, but it should work. */
- Elf_Internal_Shdr section;
- section.sh_offset = (vma - seg->p_vaddr
- + seg->p_offset);
- section.sh_size = (num_of_syms
- * filedata->dynamic_info[DT_SYMENT]);
- section.sh_entsize = filedata->dynamic_info[DT_SYMENT];
-
- if (do_checks
- && filedata->dynamic_symtab_section != NULL
- && ((filedata->dynamic_symtab_section->sh_offset
- != section.sh_offset)
- || (filedata->dynamic_symtab_section->sh_size
- != section.sh_size)
- || (filedata->dynamic_symtab_section->sh_entsize
- != section.sh_entsize)))
- warn (_("\
-the .dynsym section doesn't match the DT_SYMTAB and DT_SYMENT tags\n"));
-
- section.sh_name = filedata->string_table_length;
- filedata->dynamic_symbols
- = get_elf_symbols (filedata, §ion,
- &filedata->num_dynamic_syms);
- if (filedata->dynamic_symbols == NULL
- || filedata->num_dynamic_syms != num_of_syms)
- {
- error (_("Corrupt DT_SYMTAB dynamic entry\n"));
- return false;
- }
- break;
- }
- }
- }
- }
-
- /* Similarly find a string table. */
- if (filedata->dynamic_strings == NULL)
- for (entry = filedata->dynamic_section;
- entry < filedata->dynamic_section + filedata->dynamic_nent;
- ++entry)
- {
- if (entry->d_tag == DT_STRTAB)
- filedata->dynamic_info[DT_STRTAB] = entry->d_un.d_val;
-
- if (entry->d_tag == DT_STRSZ)
- filedata->dynamic_info[DT_STRSZ] = entry->d_un.d_val;
-
- if (filedata->dynamic_info[DT_STRTAB]
- && filedata->dynamic_info[DT_STRSZ])
- {
- uint64_t offset;
- uint64_t str_tab_len = filedata->dynamic_info[DT_STRSZ];
-
- offset = offset_from_vma (filedata,
- filedata->dynamic_info[DT_STRTAB],
- str_tab_len);
- if (do_checks
- && filedata->dynamic_strtab_section
- && ((filedata->dynamic_strtab_section->sh_offset
- != (file_ptr) offset)
- || (filedata->dynamic_strtab_section->sh_size
- != str_tab_len)))
- warn (_("\
-the .dynstr section doesn't match the DT_STRTAB and DT_STRSZ tags\n"));
-
- filedata->dynamic_strings
- = (char *) get_data (NULL, filedata, offset, 1, str_tab_len,
- _("dynamic string table"));
- if (filedata->dynamic_strings == NULL)
- {
- error (_("Corrupt DT_STRTAB dynamic entry\n"));
- break;
- }
-
- filedata->dynamic_strings_length = str_tab_len;
- break;
- }
- }
-
- /* And find the syminfo section if available. */
- if (filedata->dynamic_syminfo == NULL)
- {
- uint64_t syminsz = 0;
-
- for (entry = filedata->dynamic_section;
- entry < filedata->dynamic_section + filedata->dynamic_nent;
- ++entry)
- {
- if (entry->d_tag == DT_SYMINENT)
- {
- /* Note: these braces are necessary to avoid a syntax
- error from the SunOS4 C compiler. */
- /* PR binutils/17531: A corrupt file can trigger this test.
- So do not use an assert, instead generate an error message. */
- if (sizeof (Elf_External_Syminfo) != entry->d_un.d_val)
- error (_("Bad value (%d) for SYMINENT entry\n"),
- (int) entry->d_un.d_val);
- }
- else if (entry->d_tag == DT_SYMINSZ)
- syminsz = entry->d_un.d_val;
- else if (entry->d_tag == DT_SYMINFO)
- filedata->dynamic_syminfo_offset
- = offset_from_vma (filedata, entry->d_un.d_val, syminsz);
- }
-
- if (filedata->dynamic_syminfo_offset != 0 && syminsz != 0)
- {
- Elf_External_Syminfo * extsyminfo;
- Elf_External_Syminfo * extsym;
- Elf_Internal_Syminfo * syminfo;
-
- /* There is a syminfo section. Read the data. */
- extsyminfo = (Elf_External_Syminfo *)
- get_data (NULL, filedata, filedata->dynamic_syminfo_offset,
- 1, syminsz, _("symbol information"));
- if (!extsyminfo)
- return false;
-
- if (filedata->dynamic_syminfo != NULL)
- {
- error (_("Multiple dynamic symbol information sections found\n"));
- free (filedata->dynamic_syminfo);
- }
- filedata->dynamic_syminfo = (Elf_Internal_Syminfo *) malloc (syminsz);
- if (filedata->dynamic_syminfo == NULL)
- {
- error (_("Out of memory allocating %" PRIu64
- " bytes for dynamic symbol info\n"),
- syminsz);
- return false;
- }
-
- filedata->dynamic_syminfo_nent
- = syminsz / sizeof (Elf_External_Syminfo);
- for (syminfo = filedata->dynamic_syminfo, extsym = extsyminfo;
- syminfo < (filedata->dynamic_syminfo
- + filedata->dynamic_syminfo_nent);
- ++syminfo, ++extsym)
- {
- syminfo->si_boundto = BYTE_GET (extsym->si_boundto);
- syminfo->si_flags = BYTE_GET (extsym->si_flags);
- }
-
- free (extsyminfo);
- }
- }
-
- if (do_dynamic && filedata->dynamic_addr)
- {
- if (filedata->is_separate)
- printf (ngettext ("\nIn linked file '%s' the dynamic section at offset %#" PRIx64 " contains %" PRIu64 " entry:\n",
- "\nIn linked file '%s' the dynamic section at offset %#" PRIx64 " contains %" PRIu64 " entries:\n",
- filedata->dynamic_nent),
- filedata->file_name,
- filedata->dynamic_addr,
- filedata->dynamic_nent);
- else
- printf (ngettext ("\nDynamic section at offset %#" PRIx64 " contains %" PRIu64 " entry:\n",
- "\nDynamic section at offset %#" PRIx64 " contains %" PRIu64 " entries:\n",
- filedata->dynamic_nent),
- filedata->dynamic_addr,
- filedata->dynamic_nent);
- }
- if (do_dynamic)
- printf (_(" Tag Type Name/Value\n"));
-
- for (entry = filedata->dynamic_section;
- entry < filedata->dynamic_section + filedata->dynamic_nent;
- entry++)
- {
- if (do_dynamic)
- {
- const char * dtype;
-
- putchar (' ');
- print_vma (entry->d_tag, FULL_HEX);
- dtype = get_dynamic_type (filedata, entry->d_tag);
- printf (" (%s)%*s", dtype,
- ((is_32bit_elf ? 27 : 19) - (int) strlen (dtype)), " ");
- }
-
- switch (entry->d_tag)
- {
- case DT_FLAGS:
- if (do_dynamic)
- print_dynamic_flags (entry->d_un.d_val);
- break;
-
- case DT_AUXILIARY:
- case DT_FILTER:
- case DT_CONFIG:
- case DT_DEPAUDIT:
- case DT_AUDIT:
- if (do_dynamic)
- {
- switch (entry->d_tag)
- {
- case DT_AUXILIARY:
- printf (_("Auxiliary library"));
- break;
-
- case DT_FILTER:
- printf (_("Filter library"));
- break;
-
- case DT_CONFIG:
- printf (_("Configuration file"));
- break;
-
- case DT_DEPAUDIT:
- printf (_("Dependency audit library"));
- break;
-
- case DT_AUDIT:
- printf (_("Audit library"));
- break;
- }
-
- if (valid_dynamic_name (filedata, entry->d_un.d_val))
- printf (": [%s]\n",
- get_dynamic_name (filedata, entry->d_un.d_val));
- else
- {
- printf (": ");
- print_vma (entry->d_un.d_val, PREFIX_HEX);
- putchar ('\n');
- }
- }
- break;
-
- case DT_FEATURE:
- if (do_dynamic)
- {
- printf (_("Flags:"));
-
- if (entry->d_un.d_val == 0)
- printf (_(" None\n"));
- else
- {
- uint64_t val = entry->d_un.d_val;
-
- if (val & DTF_1_PARINIT)
- {
- printf (" PARINIT");
- val ^= DTF_1_PARINIT;
- }
- if (val & DTF_1_CONFEXP)
- {
- printf (" CONFEXP");
- val ^= DTF_1_CONFEXP;
- }
- if (val != 0)
- printf (" %" PRIx64, val);
- puts ("");
- }
- }
- break;
-
- case DT_POSFLAG_1:
- if (do_dynamic)
- {
- printf (_("Flags:"));
-
- if (entry->d_un.d_val == 0)
- printf (_(" None\n"));
- else
- {
- uint64_t val = entry->d_un.d_val;
-
- if (val & DF_P1_LAZYLOAD)
- {
- printf (" LAZYLOAD");
- val ^= DF_P1_LAZYLOAD;
- }
- if (val & DF_P1_GROUPPERM)
- {
- printf (" GROUPPERM");
- val ^= DF_P1_GROUPPERM;
- }
- if (val != 0)
- printf (" %" PRIx64, val);
- puts ("");
- }
- }
- break;
-
- case DT_FLAGS_1:
- if (do_dynamic)
- {
- printf (_("Flags:"));
- if (entry->d_un.d_val == 0)
- printf (_(" None\n"));
- else
- {
- uint64_t val = entry->d_un.d_val;
-
- if (val & DF_1_NOW)
- {
- printf (" NOW");
- val ^= DF_1_NOW;
- }
- if (val & DF_1_GLOBAL)
- {
- printf (" GLOBAL");
- val ^= DF_1_GLOBAL;
- }
- if (val & DF_1_GROUP)
- {
- printf (" GROUP");
- val ^= DF_1_GROUP;
- }
- if (val & DF_1_NODELETE)
- {
- printf (" NODELETE");
- val ^= DF_1_NODELETE;
- }
- if (val & DF_1_LOADFLTR)
- {
- printf (" LOADFLTR");
- val ^= DF_1_LOADFLTR;
- }
- if (val & DF_1_INITFIRST)
- {
- printf (" INITFIRST");
- val ^= DF_1_INITFIRST;
- }
- if (val & DF_1_NOOPEN)
- {
- printf (" NOOPEN");
- val ^= DF_1_NOOPEN;
- }
- if (val & DF_1_ORIGIN)
- {
- printf (" ORIGIN");
- val ^= DF_1_ORIGIN;
- }
- if (val & DF_1_DIRECT)
- {
- printf (" DIRECT");
- val ^= DF_1_DIRECT;
- }
- if (val & DF_1_TRANS)
- {
- printf (" TRANS");
- val ^= DF_1_TRANS;
- }
- if (val & DF_1_INTERPOSE)
- {
- printf (" INTERPOSE");
- val ^= DF_1_INTERPOSE;
- }
- if (val & DF_1_NODEFLIB)
- {
- printf (" NODEFLIB");
- val ^= DF_1_NODEFLIB;
- }
- if (val & DF_1_NODUMP)
- {
- printf (" NODUMP");
- val ^= DF_1_NODUMP;
- }
- if (val & DF_1_CONFALT)
- {
- printf (" CONFALT");
- val ^= DF_1_CONFALT;
- }
- if (val & DF_1_ENDFILTEE)
- {
- printf (" ENDFILTEE");
- val ^= DF_1_ENDFILTEE;
- }
- if (val & DF_1_DISPRELDNE)
- {
- printf (" DISPRELDNE");
- val ^= DF_1_DISPRELDNE;
- }
- if (val & DF_1_DISPRELPND)
- {
- printf (" DISPRELPND");
- val ^= DF_1_DISPRELPND;
- }
- if (val & DF_1_NODIRECT)
- {
- printf (" NODIRECT");
- val ^= DF_1_NODIRECT;
- }
- if (val & DF_1_IGNMULDEF)
- {
- printf (" IGNMULDEF");
- val ^= DF_1_IGNMULDEF;
- }
- if (val & DF_1_NOKSYMS)
- {
- printf (" NOKSYMS");
- val ^= DF_1_NOKSYMS;
- }
- if (val & DF_1_NOHDR)
- {
- printf (" NOHDR");
- val ^= DF_1_NOHDR;
- }
- if (val & DF_1_EDITED)
- {
- printf (" EDITED");
- val ^= DF_1_EDITED;
- }
- if (val & DF_1_NORELOC)
- {
- printf (" NORELOC");
- val ^= DF_1_NORELOC;
- }
- if (val & DF_1_SYMINTPOSE)
- {
- printf (" SYMINTPOSE");
- val ^= DF_1_SYMINTPOSE;
- }
- if (val & DF_1_GLOBAUDIT)
- {
- printf (" GLOBAUDIT");
- val ^= DF_1_GLOBAUDIT;
- }
- if (val & DF_1_SINGLETON)
- {
- printf (" SINGLETON");
- val ^= DF_1_SINGLETON;
- }
- if (val & DF_1_STUB)
- {
- printf (" STUB");
- val ^= DF_1_STUB;
- }
- if (val & DF_1_PIE)
- {
- printf (" PIE");
- val ^= DF_1_PIE;
- }
- if (val & DF_1_KMOD)
- {
- printf (" KMOD");
- val ^= DF_1_KMOD;
- }
- if (val & DF_1_WEAKFILTER)
- {
- printf (" WEAKFILTER");
- val ^= DF_1_WEAKFILTER;
- }
- if (val & DF_1_NOCOMMON)
- {
- printf (" NOCOMMON");
- val ^= DF_1_NOCOMMON;
- }
- if (val != 0)
- printf (" %" PRIx64, val);
- puts ("");
- }
- }
- break;
-
- case DT_PLTREL:
- filedata->dynamic_info[entry->d_tag] = entry->d_un.d_val;
- if (do_dynamic)
- puts (get_dynamic_type (filedata, entry->d_un.d_val));
- break;
-
- case DT_NULL :
- case DT_NEEDED :
- case DT_PLTGOT :
- case DT_HASH :
- case DT_STRTAB :
- case DT_SYMTAB :
- case DT_RELA :
- case DT_INIT :
- case DT_FINI :
- case DT_SONAME :
- case DT_RPATH :
- case DT_SYMBOLIC:
- case DT_REL :
- case DT_RELR :
- case DT_DEBUG :
- case DT_TEXTREL :
- case DT_JMPREL :
- case DT_RUNPATH :
- filedata->dynamic_info[entry->d_tag] = entry->d_un.d_val;
-
- if (do_dynamic)
- {
- const char *name;
-
- if (valid_dynamic_name (filedata, entry->d_un.d_val))
- name = get_dynamic_name (filedata, entry->d_un.d_val);
- else
- name = NULL;
-
- if (name)
- {
- switch (entry->d_tag)
- {
- case DT_NEEDED:
- printf (_("Shared library: [%s]"), name);
-
- if (filedata->program_interpreter
- && streq (name, filedata->program_interpreter))
- printf (_(" program interpreter"));
- break;
-
- case DT_SONAME:
- printf (_("Library soname: [%s]"), name);
- break;
-
- case DT_RPATH:
- printf (_("Library rpath: [%s]"), name);
- break;
-
- case DT_RUNPATH:
- printf (_("Library runpath: [%s]"), name);
- break;
-
- default:
- print_vma (entry->d_un.d_val, PREFIX_HEX);
- break;
- }
- }
- else
- print_vma (entry->d_un.d_val, PREFIX_HEX);
-
- putchar ('\n');
- }
- break;
-
- case DT_PLTRELSZ:
- case DT_RELASZ :
- case DT_STRSZ :
- case DT_RELSZ :
- case DT_RELAENT :
- case DT_RELRENT :
- case DT_RELRSZ :
- case DT_SYMENT :
- case DT_RELENT :
- filedata->dynamic_info[entry->d_tag] = entry->d_un.d_val;
- /* Fall through. */
- case DT_PLTPADSZ:
- case DT_MOVEENT :
- case DT_MOVESZ :
- case DT_PREINIT_ARRAYSZ:
- case DT_INIT_ARRAYSZ:
- case DT_FINI_ARRAYSZ:
- case DT_GNU_CONFLICTSZ:
- case DT_GNU_LIBLISTSZ:
- if (do_dynamic)
- {
- print_vma (entry->d_un.d_val, UNSIGNED);
- printf (_(" (bytes)\n"));
- }
- break;
-
- case DT_VERDEFNUM:
- case DT_VERNEEDNUM:
- case DT_RELACOUNT:
- case DT_RELCOUNT:
- if (do_dynamic)
- {
- print_vma (entry->d_un.d_val, UNSIGNED);
- putchar ('\n');
- }
- break;
-
- case DT_SYMINSZ:
- case DT_SYMINENT:
- case DT_SYMINFO:
- case DT_USED:
- case DT_INIT_ARRAY:
- case DT_FINI_ARRAY:
- if (do_dynamic)
- {
- if (entry->d_tag == DT_USED
- && valid_dynamic_name (filedata, entry->d_un.d_val))
- {
- const char *name
- = get_dynamic_name (filedata, entry->d_un.d_val);
-
- if (*name)
- {
- printf (_("Not needed object: [%s]\n"), name);
- break;
- }
- }
-
- print_vma (entry->d_un.d_val, PREFIX_HEX);
- putchar ('\n');
- }
- break;
-
- case DT_BIND_NOW:
- /* The value of this entry is ignored. */
- if (do_dynamic)
- putchar ('\n');
- break;
-
- case DT_GNU_PRELINKED:
- if (do_dynamic)
- {
- struct tm * tmp;
- time_t atime = entry->d_un.d_val;
-
- tmp = gmtime (&atime);
- /* PR 17533 file: 041-1244816-0.004. */
- if (tmp == NULL)
- printf (_("<corrupt time val: %" PRIx64),
- (uint64_t) atime);
- else
- printf ("%04u-%02u-%02uT%02u:%02u:%02u\n",
- tmp->tm_year + 1900, tmp->tm_mon + 1, tmp->tm_mday,
- tmp->tm_hour, tmp->tm_min, tmp->tm_sec);
-
- }
- break;
-
- case DT_GNU_HASH:
- filedata->dynamic_info_DT_GNU_HASH = entry->d_un.d_val;
- if (do_dynamic)
- {
- print_vma (entry->d_un.d_val, PREFIX_HEX);
- putchar ('\n');
- }
- break;
-
- case DT_GNU_FLAGS_1:
- if (do_dynamic)
- {
- printf (_("Flags:"));
- if (entry->d_un.d_val == 0)
- printf (_(" None\n"));
- else
- {
- uint64_t val = entry->d_un.d_val;
-
- if (val & DF_GNU_1_UNIQUE)
- {
- printf (" UNIQUE");
- val ^= DF_GNU_1_UNIQUE;
- }
- if (val != 0)
- printf (" %" PRIx64, val);
- puts ("");
- }
- }
- break;
-
- default:
- if ((entry->d_tag >= DT_VERSYM) && (entry->d_tag <= DT_VERNEEDNUM))
- filedata->version_info[DT_VERSIONTAGIDX (entry->d_tag)]
- = entry->d_un.d_val;
-
- if (do_dynamic)
- {
- switch (filedata->file_header.e_machine)
- {
- case EM_AARCH64:
- dynamic_section_aarch64_val (entry);
- break;
- case EM_MIPS:
- case EM_MIPS_RS3_LE:
- dynamic_section_mips_val (filedata, entry);
- break;
- case EM_PARISC:
- dynamic_section_parisc_val (entry);
- break;
- case EM_IA_64:
- dynamic_section_ia64_val (entry);
- break;
- default:
- print_vma (entry->d_un.d_val, PREFIX_HEX);
- putchar ('\n');
- }
- }
- break;
- }
- }
-
- return true;
-}
-
-static char *
-get_ver_flags (unsigned int flags)
-{
- static char buff[128];
-
- buff[0] = 0;
-
- if (flags == 0)
- return _("none");
-
- if (flags & VER_FLG_BASE)
- strcat (buff, "BASE");
-
- if (flags & VER_FLG_WEAK)
- {
- if (flags & VER_FLG_BASE)
- strcat (buff, " | ");
-
- strcat (buff, "WEAK");
- }
-
- if (flags & VER_FLG_INFO)
- {
- if (flags & (VER_FLG_BASE|VER_FLG_WEAK))
- strcat (buff, " | ");
-
- strcat (buff, "INFO");
- }
-
- if (flags & ~(VER_FLG_BASE | VER_FLG_WEAK | VER_FLG_INFO))
- {
- if (flags & (VER_FLG_BASE | VER_FLG_WEAK | VER_FLG_INFO))
- strcat (buff, " | ");
-
- strcat (buff, _("<unknown>"));
- }
-
- return buff;
-}
-
-/* Display the contents of the version sections. */
-
-static bool
-process_version_sections (Filedata * filedata)
-{
- Elf_Internal_Shdr * section;
- unsigned i;
- bool found = false;
-
- if (! do_version)
- return true;
-
- for (i = 0, section = filedata->section_headers;
- i < filedata->file_header.e_shnum;
- i++, section++)
- {
- switch (section->sh_type)
- {
- case SHT_GNU_verdef:
- {
- Elf_External_Verdef * edefs;
- size_t idx;
- size_t cnt;
- char * endbuf;
-
- found = true;
-
- if (filedata->is_separate)
- printf (ngettext ("\nIn linked file '%s' the version definition section '%s' contains %u entry:\n",
- "\nIn linked file '%s' the version definition section '%s' contains %u entries:\n",
- section->sh_info),
- filedata->file_name,
- printable_section_name (filedata, section),
- section->sh_info);
- else
- printf (ngettext ("\nVersion definition section '%s' "
- "contains %u entry:\n",
- "\nVersion definition section '%s' "
- "contains %u entries:\n",
- section->sh_info),
- printable_section_name (filedata, section),
- section->sh_info);
-
- printf (_(" Addr: 0x%016" PRIx64), section->sh_addr);
- printf (_(" Offset: 0x%08" PRIx64 " Link: %u (%s)\n"),
- section->sh_offset, section->sh_link,
- printable_section_name_from_index (filedata, section->sh_link, NULL));
-
- edefs = (Elf_External_Verdef *)
- get_data (NULL, filedata, section->sh_offset, 1,section->sh_size,
- _("version definition section"));
- if (!edefs)
- break;
- endbuf = (char *) edefs + section->sh_size;
-
- for (idx = cnt = 0; cnt < section->sh_info; ++cnt)
- {
- char * vstart;
- Elf_External_Verdef * edef;
- Elf_Internal_Verdef ent;
- Elf_External_Verdaux * eaux;
- Elf_Internal_Verdaux aux;
- size_t isum;
- int j;
-
- vstart = ((char *) edefs) + idx;
- if (vstart + sizeof (*edef) > endbuf)
- break;
-
- edef = (Elf_External_Verdef *) vstart;
-
- ent.vd_version = BYTE_GET (edef->vd_version);
- ent.vd_flags = BYTE_GET (edef->vd_flags);
- ent.vd_ndx = BYTE_GET (edef->vd_ndx);
- ent.vd_cnt = BYTE_GET (edef->vd_cnt);
- ent.vd_hash = BYTE_GET (edef->vd_hash);
- ent.vd_aux = BYTE_GET (edef->vd_aux);
- ent.vd_next = BYTE_GET (edef->vd_next);
-
- printf (_(" %#06zx: Rev: %d Flags: %s"),
- idx, ent.vd_version, get_ver_flags (ent.vd_flags));
-
- printf (_(" Index: %d Cnt: %d "),
- ent.vd_ndx, ent.vd_cnt);
-
- /* Check for overflow. */
- if (ent.vd_aux > (size_t) (endbuf - vstart))
- break;
-
- vstart += ent.vd_aux;
-
- if (vstart + sizeof (*eaux) > endbuf)
- break;
- eaux = (Elf_External_Verdaux *) vstart;
-
- aux.vda_name = BYTE_GET (eaux->vda_name);
- aux.vda_next = BYTE_GET (eaux->vda_next);
-
- if (valid_dynamic_name (filedata, aux.vda_name))
- printf (_("Name: %s\n"),
- get_dynamic_name (filedata, aux.vda_name));
- else
- printf (_("Name index: %ld\n"), aux.vda_name);
-
- isum = idx + ent.vd_aux;
-
- for (j = 1; j < ent.vd_cnt; j++)
- {
- if (aux.vda_next < sizeof (*eaux)
- && !(j == ent.vd_cnt - 1 && aux.vda_next == 0))
- {
- warn (_("Invalid vda_next field of %lx\n"),
- aux.vda_next);
- j = ent.vd_cnt;
- break;
- }
- /* Check for overflow. */
- if (aux.vda_next > (size_t) (endbuf - vstart))
- break;
-
- isum += aux.vda_next;
- vstart += aux.vda_next;
-
- if (vstart + sizeof (*eaux) > endbuf)
- break;
- eaux = (Elf_External_Verdaux *) vstart;
-
- aux.vda_name = BYTE_GET (eaux->vda_name);
- aux.vda_next = BYTE_GET (eaux->vda_next);
-
- if (valid_dynamic_name (filedata, aux.vda_name))
- printf (_(" %#06zx: Parent %d: %s\n"),
- isum, j,
- get_dynamic_name (filedata, aux.vda_name));
- else
- printf (_(" %#06zx: Parent %d, name index: %ld\n"),
- isum, j, aux.vda_name);
- }
-
- if (j < ent.vd_cnt)
- printf (_(" Version def aux past end of section\n"));
-
- /* PR 17531:
- file: id:000001,src:000172+005151,op:splice,rep:2. */
- if (ent.vd_next < sizeof (*edef)
- && !(cnt == section->sh_info - 1 && ent.vd_next == 0))
- {
- warn (_("Invalid vd_next field of %lx\n"), ent.vd_next);
- cnt = section->sh_info;
- break;
- }
- if (ent.vd_next > (size_t) (endbuf - ((char *) edefs + idx)))
- break;
-
- idx += ent.vd_next;
- }
-
- if (cnt < section->sh_info)
- printf (_(" Version definition past end of section\n"));
-
- free (edefs);
- }
- break;
-
- case SHT_GNU_verneed:
- {
- Elf_External_Verneed * eneed;
- size_t idx;
- size_t cnt;
- char * endbuf;
-
- found = true;
-
- if (filedata->is_separate)
- printf (ngettext ("\nIn linked file '%s' the version needs section '%s' contains %u entry:\n",
- "\nIn linked file '%s' the version needs section '%s' contains %u entries:\n",
- section->sh_info),
- filedata->file_name,
- printable_section_name (filedata, section),
- section->sh_info);
- else
- printf (ngettext ("\nVersion needs section '%s' "
- "contains %u entry:\n",
- "\nVersion needs section '%s' "
- "contains %u entries:\n",
- section->sh_info),
- printable_section_name (filedata, section),
- section->sh_info);
-
- printf (_(" Addr: 0x%016" PRIx64), section->sh_addr);
- printf (_(" Offset: 0x%08" PRIx64 " Link: %u (%s)\n"),
- section->sh_offset, section->sh_link,
- printable_section_name_from_index (filedata, section->sh_link, NULL));
-
- eneed = (Elf_External_Verneed *) get_data (NULL, filedata,
- section->sh_offset, 1,
- section->sh_size,
- _("Version Needs section"));
- if (!eneed)
- break;
- endbuf = (char *) eneed + section->sh_size;
-
- for (idx = cnt = 0; cnt < section->sh_info; ++cnt)
- {
- Elf_External_Verneed * entry;
- Elf_Internal_Verneed ent;
- size_t isum;
- int j;
- char * vstart;
-
- vstart = ((char *) eneed) + idx;
- if (vstart + sizeof (*entry) > endbuf)
- break;
-
- entry = (Elf_External_Verneed *) vstart;
-
- ent.vn_version = BYTE_GET (entry->vn_version);
- ent.vn_cnt = BYTE_GET (entry->vn_cnt);
- ent.vn_file = BYTE_GET (entry->vn_file);
- ent.vn_aux = BYTE_GET (entry->vn_aux);
- ent.vn_next = BYTE_GET (entry->vn_next);
-
- printf (_(" %#06zx: Version: %d"), idx, ent.vn_version);
-
- if (valid_dynamic_name (filedata, ent.vn_file))
- printf (_(" File: %s"),
- get_dynamic_name (filedata, ent.vn_file));
- else
- printf (_(" File: %lx"), ent.vn_file);
-
- printf (_(" Cnt: %d\n"), ent.vn_cnt);
-
- /* Check for overflow. */
- if (ent.vn_aux > (size_t) (endbuf - vstart))
- break;
- vstart += ent.vn_aux;
-
- for (j = 0, isum = idx + ent.vn_aux; j < ent.vn_cnt; ++j)
- {
- Elf_External_Vernaux * eaux;
- Elf_Internal_Vernaux aux;
-
- if (vstart + sizeof (*eaux) > endbuf)
- break;
- eaux = (Elf_External_Vernaux *) vstart;
-
- aux.vna_hash = BYTE_GET (eaux->vna_hash);
- aux.vna_flags = BYTE_GET (eaux->vna_flags);
- aux.vna_other = BYTE_GET (eaux->vna_other);
- aux.vna_name = BYTE_GET (eaux->vna_name);
- aux.vna_next = BYTE_GET (eaux->vna_next);
-
- if (valid_dynamic_name (filedata, aux.vna_name))
- printf (_(" %#06zx: Name: %s"),
- isum, get_dynamic_name (filedata, aux.vna_name));
- else
- printf (_(" %#06zx: Name index: %lx"),
- isum, aux.vna_name);
-
- printf (_(" Flags: %s Version: %d\n"),
- get_ver_flags (aux.vna_flags), aux.vna_other);
-
- if (aux.vna_next < sizeof (*eaux)
- && !(j == ent.vn_cnt - 1 && aux.vna_next == 0))
- {
- warn (_("Invalid vna_next field of %lx\n"),
- aux.vna_next);
- j = ent.vn_cnt;
- break;
- }
- /* Check for overflow. */
- if (aux.vna_next > (size_t) (endbuf - vstart))
- break;
- isum += aux.vna_next;
- vstart += aux.vna_next;
- }
-
- if (j < ent.vn_cnt)
- warn (_("Missing Version Needs auxiliary information\n"));
-
- if (ent.vn_next < sizeof (*entry)
- && !(cnt == section->sh_info - 1 && ent.vn_next == 0))
- {
- warn (_("Invalid vn_next field of %lx\n"), ent.vn_next);
- cnt = section->sh_info;
- break;
- }
- if (ent.vn_next > (size_t) (endbuf - ((char *) eneed + idx)))
- break;
- idx += ent.vn_next;
- }
-
- if (cnt < section->sh_info)
- warn (_("Missing Version Needs information\n"));
-
- free (eneed);
- }
- break;
-
- case SHT_GNU_versym:
- {
- Elf_Internal_Shdr * link_section;
- uint64_t total;
- unsigned int cnt;
- unsigned char * edata;
- unsigned short * data;
- char * strtab;
- Elf_Internal_Sym * symbols;
- Elf_Internal_Shdr * string_sec;
- uint64_t num_syms;
- uint64_t off;
-
- if (section->sh_link >= filedata->file_header.e_shnum)
- break;
-
- link_section = filedata->section_headers + section->sh_link;
- total = section->sh_size / sizeof (Elf_External_Versym);
-
- if (link_section->sh_link >= filedata->file_header.e_shnum)
- break;
-
- found = true;
-
- symbols = get_elf_symbols (filedata, link_section, & num_syms);
- if (symbols == NULL)
- break;
-
- string_sec = filedata->section_headers + link_section->sh_link;
-
- strtab = (char *) get_data (NULL, filedata, string_sec->sh_offset, 1,
- string_sec->sh_size,
- _("version string table"));
- if (!strtab)
- {
- free (symbols);
- break;
- }
-
- if (filedata->is_separate)
- printf (ngettext ("\nIn linked file '%s' the version symbols section '%s' contains %" PRIu64 " entry:\n",
- "\nIn linked file '%s' the version symbols section '%s' contains %" PRIu64 " entries:\n",
- total),
- filedata->file_name,
- printable_section_name (filedata, section),
- total);
- else
- printf (ngettext ("\nVersion symbols section '%s' "
- "contains %" PRIu64 " entry:\n",
- "\nVersion symbols section '%s' "
- "contains %" PRIu64 " entries:\n",
- total),
- printable_section_name (filedata, section),
- total);
-
- printf (_(" Addr: 0x%016" PRIx64), section->sh_addr);
- printf (_(" Offset: 0x%08" PRIx64 " Link: %u (%s)\n"),
- section->sh_offset, section->sh_link,
- printable_section_name (filedata, link_section));
-
- off = offset_from_vma (filedata,
- filedata->version_info[DT_VERSIONTAGIDX (DT_VERSYM)],
- total * sizeof (short));
- edata = (unsigned char *) get_data (NULL, filedata, off,
- sizeof (short), total,
- _("version symbol data"));
- if (!edata)
- {
- free (strtab);
- free (symbols);
- break;
- }
-
- data = (short unsigned int *) cmalloc (total, sizeof (short));
-
- for (cnt = total; cnt --;)
- data[cnt] = byte_get (edata + cnt * sizeof (short),
- sizeof (short));
-
- free (edata);
-
- for (cnt = 0; cnt < total; cnt += 4)
- {
- int j, nn;
- char *name;
- char *invalid = _("*invalid*");
-
- printf (" %03x:", cnt);
-
- for (j = 0; (j < 4) && (cnt + j) < total; ++j)
- switch (data[cnt + j])
- {
- case 0:
- fputs (_(" 0 (*local*) "), stdout);
- break;
-
- case 1:
- fputs (_(" 1 (*global*) "), stdout);
- break;
-
- default:
- nn = printf ("%4x%c", data[cnt + j] & VERSYM_VERSION,
- data[cnt + j] & VERSYM_HIDDEN ? 'h' : ' ');
-
- /* If this index value is greater than the size of the symbols
- array, break to avoid an out-of-bounds read. */
- if (cnt + j >= num_syms)
- {
- warn (_("invalid index into symbol array\n"));
- break;
- }
-
- name = NULL;
- if (filedata->version_info[DT_VERSIONTAGIDX (DT_VERNEED)])
- {
- Elf_Internal_Verneed ivn;
- uint64_t offset;
-
- offset = offset_from_vma
- (filedata,
- filedata->version_info[DT_VERSIONTAGIDX (DT_VERNEED)],
- sizeof (Elf_External_Verneed));
-
- do
- {
- Elf_Internal_Vernaux ivna;
- Elf_External_Verneed evn;
- Elf_External_Vernaux evna;
- uint64_t a_off;
-
- if (get_data (&evn, filedata, offset, sizeof (evn), 1,
- _("version need")) == NULL)
- break;
-
- ivn.vn_aux = BYTE_GET (evn.vn_aux);
- ivn.vn_next = BYTE_GET (evn.vn_next);
-
- a_off = offset + ivn.vn_aux;
-
- do
- {
- if (get_data (&evna, filedata, a_off, sizeof (evna),
- 1, _("version need aux (2)")) == NULL)
- {
- ivna.vna_next = 0;
- ivna.vna_other = 0;
- }
- else
- {
- ivna.vna_next = BYTE_GET (evna.vna_next);
- ivna.vna_other = BYTE_GET (evna.vna_other);
- }
-
- a_off += ivna.vna_next;
- }
- while (ivna.vna_other != data[cnt + j]
- && ivna.vna_next != 0);
-
- if (ivna.vna_other == data[cnt + j])
- {
- ivna.vna_name = BYTE_GET (evna.vna_name);
-
- if (ivna.vna_name >= string_sec->sh_size)
- name = invalid;
- else
- name = strtab + ivna.vna_name;
- break;
- }
-
- offset += ivn.vn_next;
- }
- while (ivn.vn_next);
- }
-
- if (data[cnt + j] != 0x8001
- && filedata->version_info[DT_VERSIONTAGIDX (DT_VERDEF)])
- {
- Elf_Internal_Verdef ivd;
- Elf_External_Verdef evd;
- uint64_t offset;
-
- offset = offset_from_vma
- (filedata,
- filedata->version_info[DT_VERSIONTAGIDX (DT_VERDEF)],
- sizeof evd);
-
- do
- {
- if (get_data (&evd, filedata, offset, sizeof (evd), 1,
- _("version def")) == NULL)
- {
- ivd.vd_next = 0;
- /* PR 17531: file: 046-1082287-0.004. */
- ivd.vd_ndx = (data[cnt + j] & VERSYM_VERSION) + 1;
- break;
- }
- else
- {
- ivd.vd_next = BYTE_GET (evd.vd_next);
- ivd.vd_ndx = BYTE_GET (evd.vd_ndx);
- }
-
- offset += ivd.vd_next;
- }
- while (ivd.vd_ndx != (data[cnt + j] & VERSYM_VERSION)
- && ivd.vd_next != 0);
-
- if (ivd.vd_ndx == (data[cnt + j] & VERSYM_VERSION))
- {
- Elf_External_Verdaux evda;
- Elf_Internal_Verdaux ivda;
-
- ivd.vd_aux = BYTE_GET (evd.vd_aux);
-
- if (get_data (&evda, filedata,
- offset - ivd.vd_next + ivd.vd_aux,
- sizeof (evda), 1,
- _("version def aux")) == NULL)
- break;
-
- ivda.vda_name = BYTE_GET (evda.vda_name);
-
- if (ivda.vda_name >= string_sec->sh_size)
- name = invalid;
- else if (name != NULL && name != invalid)
- name = _("*both*");
- else
- name = strtab + ivda.vda_name;
- }
- }
- if (name != NULL)
- nn += printf ("(%s%-*s",
- name,
- 12 - (int) strlen (name),
- ")");
-
- if (nn < 18)
- printf ("%*c", 18 - nn, ' ');
- }
-
- putchar ('\n');
- }
-
- free (data);
- free (strtab);
- free (symbols);
- }
- break;
-
- default:
- break;
- }
- }
-
- if (! found)
- {
- if (filedata->is_separate)
- printf (_("\nNo version information found in linked file '%s'.\n"),
- filedata->file_name);
- else
- printf (_("\nNo version information found in this file.\n"));
- }
-
- return true;
-}
-
-static const char *
-get_symbol_binding (Filedata * filedata, unsigned int binding)
-{
- static char buff[64];
-
- switch (binding)
- {
- case STB_LOCAL: return "LOCAL";
- case STB_GLOBAL: return "GLOBAL";
- case STB_WEAK: return "WEAK";
- default:
- if (binding >= STB_LOPROC && binding <= STB_HIPROC)
- snprintf (buff, sizeof (buff), _("<processor specific>: %d"),
- binding);
- else if (binding >= STB_LOOS && binding <= STB_HIOS)
- {
- if (binding == STB_GNU_UNIQUE
- && filedata->file_header.e_ident[EI_OSABI] == ELFOSABI_GNU)
- return "UNIQUE";
- snprintf (buff, sizeof (buff), _("<OS specific>: %d"), binding);
- }
- else
- snprintf (buff, sizeof (buff), _("<unknown>: %d"), binding);
- return buff;
- }
-}
-
-static const char *
-get_symbol_type (Filedata * filedata, unsigned int type)
-{
- static char buff[64];
-
- switch (type)
- {
- case STT_NOTYPE: return "NOTYPE";
- case STT_OBJECT: return "OBJECT";
- case STT_FUNC: return "FUNC";
- case STT_SECTION: return "SECTION";
- case STT_FILE: return "FILE";
- case STT_COMMON: return "COMMON";
- case STT_TLS: return "TLS";
- case STT_RELC: return "RELC";
- case STT_SRELC: return "SRELC";
- default:
- if (type >= STT_LOPROC && type <= STT_HIPROC)
- {
- if (filedata->file_header.e_machine == EM_ARM && type == STT_ARM_TFUNC)
- return "THUMB_FUNC";
-
- if (filedata->file_header.e_machine == EM_SPARCV9 && type == STT_REGISTER)
- return "REGISTER";
-
- if (filedata->file_header.e_machine == EM_PARISC && type == STT_PARISC_MILLI)
- return "PARISC_MILLI";
-
- snprintf (buff, sizeof (buff), _("<processor specific>: %d"), type);
- }
- else if (type >= STT_LOOS && type <= STT_HIOS)
- {
- if (filedata->file_header.e_machine == EM_PARISC)
- {
- if (type == STT_HP_OPAQUE)
- return "HP_OPAQUE";
- if (type == STT_HP_STUB)
- return "HP_STUB";
- }
-
- if (type == STT_GNU_IFUNC
- && (filedata->file_header.e_ident[EI_OSABI] == ELFOSABI_GNU
- || filedata->file_header.e_ident[EI_OSABI] == ELFOSABI_FREEBSD))
- return "IFUNC";
-
- snprintf (buff, sizeof (buff), _("<OS specific>: %d"), type);
- }
- else
- snprintf (buff, sizeof (buff), _("<unknown>: %d"), type);
- return buff;
- }
-}
-
-static const char *
-get_symbol_visibility (unsigned int visibility)
-{
- switch (visibility)
- {
- case STV_DEFAULT: return "DEFAULT";
- case STV_INTERNAL: return "INTERNAL";
- case STV_HIDDEN: return "HIDDEN";
- case STV_PROTECTED: return "PROTECTED";
- default:
- error (_("Unrecognized visibility value: %u\n"), visibility);
- return _("<unknown>");
- }
-}
-
-static const char *
-get_alpha_symbol_other (unsigned int other)
-{
- switch (other)
- {
- case STO_ALPHA_NOPV: return "NOPV";
- case STO_ALPHA_STD_GPLOAD: return "STD GPLOAD";
- default:
- error (_("Unrecognized alpha specific other value: %u\n"), other);
- return _("<unknown>");
- }
-}
-
-static const char *
-get_solaris_symbol_visibility (unsigned int visibility)
-{
- switch (visibility)
- {
- case 4: return "EXPORTED";
- case 5: return "SINGLETON";
- case 6: return "ELIMINATE";
- default: return get_symbol_visibility (visibility);
- }
-}
-
-static const char *
-get_aarch64_symbol_other (unsigned int other)
-{
- static char buf[32];
-
- if (other & STO_AARCH64_VARIANT_PCS)
- {
- other &= ~STO_AARCH64_VARIANT_PCS;
- if (other == 0)
- return "VARIANT_PCS";
- snprintf (buf, sizeof buf, "VARIANT_PCS | %x", other);
- return buf;
- }
- return NULL;
-}
-
-static const char *
-get_mips_symbol_other (unsigned int other)
-{
- switch (other)
- {
- case STO_OPTIONAL: return "OPTIONAL";
- case STO_MIPS_PLT: return "MIPS PLT";
- case STO_MIPS_PIC: return "MIPS PIC";
- case STO_MICROMIPS: return "MICROMIPS";
- case STO_MICROMIPS | STO_MIPS_PIC: return "MICROMIPS, MIPS PIC";
- case STO_MIPS16: return "MIPS16";
- default: return NULL;
- }
-}
-
-static const char *
-get_ia64_symbol_other (Filedata * filedata, unsigned int other)
-{
- if (is_ia64_vms (filedata))
- {
- static char res[32];
-
- res[0] = 0;
-
- /* Function types is for images and .STB files only. */
- switch (filedata->file_header.e_type)
- {
- case ET_DYN:
- case ET_EXEC:
- switch (VMS_ST_FUNC_TYPE (other))
- {
- case VMS_SFT_CODE_ADDR:
- strcat (res, " CA");
- break;
- case VMS_SFT_SYMV_IDX:
- strcat (res, " VEC");
- break;
- case VMS_SFT_FD:
- strcat (res, " FD");
- break;
- case VMS_SFT_RESERVE:
- strcat (res, " RSV");
- break;
- default:
- warn (_("Unrecognized IA64 VMS ST Function type: %d\n"),
- VMS_ST_FUNC_TYPE (other));
- strcat (res, " <unknown>");
- break;
- }
- break;
- default:
- break;
- }
- switch (VMS_ST_LINKAGE (other))
- {
- case VMS_STL_IGNORE:
- strcat (res, " IGN");
- break;
- case VMS_STL_RESERVE:
- strcat (res, " RSV");
- break;
- case VMS_STL_STD:
- strcat (res, " STD");
- break;
- case VMS_STL_LNK:
- strcat (res, " LNK");
- break;
- default:
- warn (_("Unrecognized IA64 VMS ST Linkage: %d\n"),
- VMS_ST_LINKAGE (other));
- strcat (res, " <unknown>");
- break;
- }
-
- if (res[0] != 0)
- return res + 1;
- else
- return res;
- }
- return NULL;
-}
-
-static const char *
-get_ppc64_symbol_other (unsigned int other)
-{
- if ((other & ~STO_PPC64_LOCAL_MASK) != 0)
- return NULL;
-
- other >>= STO_PPC64_LOCAL_BIT;
- if (other <= 6)
- {
- static char buf[64];
- if (other >= 2)
- other = ppc64_decode_local_entry (other);
- snprintf (buf, sizeof buf, _("<localentry>: %d"), other);
- return buf;
- }
- return NULL;
-}
-
-static const char *
-get_riscv_symbol_other (unsigned int other)
-{
- static char buf[32];
- buf[0] = 0;
-
- if (other & STO_RISCV_VARIANT_CC)
- {
- strcat (buf, _(" VARIANT_CC"));
- other &= ~STO_RISCV_VARIANT_CC;
- }
-
- if (other != 0)
- snprintf (buf, sizeof buf, " %x", other);
-
-
- if (buf[0] != 0)
- return buf + 1;
- else
- return buf;
-}
-
-static const char *
-get_symbol_other (Filedata * filedata, unsigned int other)
-{
- const char * result = NULL;
- static char buff [64];
-
- if (other == 0)
- return "";
-
- switch (filedata->file_header.e_machine)
- {
- case EM_ALPHA:
- result = get_alpha_symbol_other (other);
- break;
- case EM_AARCH64:
- result = get_aarch64_symbol_other (other);
- break;
- case EM_MIPS:
- result = get_mips_symbol_other (other);
- break;
- case EM_IA_64:
- result = get_ia64_symbol_other (filedata, other);
- break;
- case EM_PPC64:
- result = get_ppc64_symbol_other (other);
- break;
- case EM_RISCV:
- result = get_riscv_symbol_other (other);
- break;
- default:
- result = NULL;
- break;
- }
-
- if (result)
- return result;
-
- snprintf (buff, sizeof buff, _("<other>: %x"), other);
- return buff;
-}
-
-static const char *
-get_symbol_version_string (Filedata *filedata,
- bool is_dynsym,
- const char *strtab,
- size_t strtab_size,
- unsigned int si,
- Elf_Internal_Sym *psym,
- enum versioned_symbol_info *sym_info,
- unsigned short *vna_other)
-{
- unsigned char data[2];
- unsigned short vers_data;
- uint64_t offset;
- unsigned short max_vd_ndx;
-
- if (!is_dynsym
- || filedata->version_info[DT_VERSIONTAGIDX (DT_VERSYM)] == 0)
- return NULL;
-
- offset = offset_from_vma (filedata,
- filedata->version_info[DT_VERSIONTAGIDX (DT_VERSYM)],
- sizeof data + si * sizeof (vers_data));
-
- if (get_data (&data, filedata, offset + si * sizeof (vers_data),
- sizeof (data), 1, _("version data")) == NULL)
- return NULL;
-
- vers_data = byte_get (data, 2);
-
- if ((vers_data & VERSYM_HIDDEN) == 0 && vers_data == 0)
- return NULL;
-
- *sym_info = (vers_data & VERSYM_HIDDEN) != 0 ? symbol_hidden : symbol_public;
- max_vd_ndx = 0;
-
- /* Usually we'd only see verdef for defined symbols, and verneed for
- undefined symbols. However, symbols defined by the linker in
- .dynbss for variables copied from a shared library in order to
- avoid text relocations are defined yet have verneed. We could
- use a heuristic to detect the special case, for example, check
- for verneed first on symbols defined in SHT_NOBITS sections, but
- it is simpler and more reliable to just look for both verdef and
- verneed. .dynbss might not be mapped to a SHT_NOBITS section. */
-
- if (psym->st_shndx != SHN_UNDEF
- && vers_data != 0x8001
- && filedata->version_info[DT_VERSIONTAGIDX (DT_VERDEF)])
- {
- Elf_Internal_Verdef ivd;
- Elf_Internal_Verdaux ivda;
- Elf_External_Verdaux evda;
- uint64_t off;
-
- off = offset_from_vma (filedata,
- filedata->version_info[DT_VERSIONTAGIDX (DT_VERDEF)],
- sizeof (Elf_External_Verdef));
-
- do
- {
- Elf_External_Verdef evd;
-
- if (get_data (&evd, filedata, off, sizeof (evd), 1,
- _("version def")) == NULL)
- {
- ivd.vd_ndx = 0;
- ivd.vd_aux = 0;
- ivd.vd_next = 0;
- ivd.vd_flags = 0;
- }
- else
- {
- ivd.vd_ndx = BYTE_GET (evd.vd_ndx);
- ivd.vd_aux = BYTE_GET (evd.vd_aux);
- ivd.vd_next = BYTE_GET (evd.vd_next);
- ivd.vd_flags = BYTE_GET (evd.vd_flags);
- }
-
- if ((ivd.vd_ndx & VERSYM_VERSION) > max_vd_ndx)
- max_vd_ndx = ivd.vd_ndx & VERSYM_VERSION;
-
- off += ivd.vd_next;
- }
- while (ivd.vd_ndx != (vers_data & VERSYM_VERSION) && ivd.vd_next != 0);
-
- if (ivd.vd_ndx == (vers_data & VERSYM_VERSION))
- {
- if (ivd.vd_ndx == 1 && ivd.vd_flags == VER_FLG_BASE)
- return NULL;
-
- off -= ivd.vd_next;
- off += ivd.vd_aux;
-
- if (get_data (&evda, filedata, off, sizeof (evda), 1,
- _("version def aux")) != NULL)
- {
- ivda.vda_name = BYTE_GET (evda.vda_name);
-
- if (psym->st_name != ivda.vda_name)
- return (ivda.vda_name < strtab_size
- ? strtab + ivda.vda_name : _("<corrupt>"));
- }
- }
- }
-
- if (filedata->version_info[DT_VERSIONTAGIDX (DT_VERNEED)])
- {
- Elf_External_Verneed evn;
- Elf_Internal_Verneed ivn;
- Elf_Internal_Vernaux ivna;
-
- offset = offset_from_vma (filedata,
- filedata->version_info[DT_VERSIONTAGIDX (DT_VERNEED)],
- sizeof evn);
- do
- {
- uint64_t vna_off;
-
- if (get_data (&evn, filedata, offset, sizeof (evn), 1,
- _("version need")) == NULL)
- {
- ivna.vna_next = 0;
- ivna.vna_other = 0;
- ivna.vna_name = 0;
- break;
- }
-
- ivn.vn_aux = BYTE_GET (evn.vn_aux);
- ivn.vn_next = BYTE_GET (evn.vn_next);
-
- vna_off = offset + ivn.vn_aux;
-
- do
- {
- Elf_External_Vernaux evna;
-
- if (get_data (&evna, filedata, vna_off, sizeof (evna), 1,
- _("version need aux (3)")) == NULL)
- {
- ivna.vna_next = 0;
- ivna.vna_other = 0;
- ivna.vna_name = 0;
- }
- else
- {
- ivna.vna_other = BYTE_GET (evna.vna_other);
- ivna.vna_next = BYTE_GET (evna.vna_next);
- ivna.vna_name = BYTE_GET (evna.vna_name);
- }
-
- vna_off += ivna.vna_next;
- }
- while (ivna.vna_other != vers_data && ivna.vna_next != 0);
-
- if (ivna.vna_other == vers_data)
- break;
-
- offset += ivn.vn_next;
- }
- while (ivn.vn_next != 0);
-
- if (ivna.vna_other == vers_data)
- {
- *sym_info = symbol_undefined;
- *vna_other = ivna.vna_other;
- return (ivna.vna_name < strtab_size
- ? strtab + ivna.vna_name : _("<corrupt>"));
- }
- else if ((max_vd_ndx || (vers_data & VERSYM_VERSION) != 1)
- && (vers_data & VERSYM_VERSION) > max_vd_ndx)
- return _("<corrupt>");
- }
- return NULL;
-}
-
-/* Display a symbol size on stdout. Format is based on --sym-base setting. */
-
-static unsigned int
-print_symbol_size (uint64_t vma, int base)
-{
- switch (base)
- {
- case 8:
- return print_vma (vma, OCTAL_5);
-
- case 10:
- return print_vma (vma, UNSIGNED_5);
-
- case 16:
- return print_vma (vma, PREFIX_HEX_5);
-
- case 0:
- default:
- return print_vma (vma, DEC_5);
- }
-}
-
-/* Print information on a single symbol. */
-
-static void
-print_symbol (Filedata * filedata,
- uint64_t symbol_index,
- Elf_Internal_Sym * symtab,
- Elf_Internal_Shdr * section,
- char * strtab,
- size_t strtab_size)
-{
- const char *version_string;
- enum versioned_symbol_info sym_info;
- unsigned short vna_other;
- const char * sstr;
- Elf_Internal_Sym *psym = symtab + symbol_index;
-
- /* FIXME: We should have a table of field widths,
- rather than using hard coded constants. */
- printf ("%6" PRId64 ": ", symbol_index);
- print_vma (psym->st_value, LONG_HEX);
- putchar (' ');
- print_symbol_size (psym->st_size, sym_base);
- printf (" %-7s", get_symbol_type (filedata, ELF_ST_TYPE (psym->st_info)));
- printf (" %-6s", get_symbol_binding (filedata, ELF_ST_BIND (psym->st_info)));
- if (filedata->file_header.e_ident[EI_OSABI] == ELFOSABI_SOLARIS)
- printf (" %-7s", get_solaris_symbol_visibility (psym->st_other));
- else
- {
- unsigned int vis = ELF_ST_VISIBILITY (psym->st_other);
-
- printf (" %-7s", get_symbol_visibility (vis));
-#if 0
- /* Check to see if any other bits in the st_other field are set.
- FIXME: Displaying this information here disrupts the layout
- of the table being generated. */
- if (psym->st_other ^ vis)
- printf (" [%s] ", get_symbol_other (filedata, psym->st_other ^ vis));
-#endif
- }
-
- bool is_special;
-
- sstr = printable_section_name_from_index (filedata, psym->st_shndx, & is_special);
-
- /* Print the symbol's section index. If the index is special
- then print the index's name rather than its number. */
- if (is_special)
- {
- int printed;
-
- /* Special case: If there are no section headers, and the printable
- name is "<section 0x...." then just display the section number
- as a decimal. This happens when objcopy --strip -section-headers
- is used. */
- if (filedata->file_header.e_shnum == 0 && startswith (sstr, "<section"))
- printed = printf (" %4d ", psym->st_shndx);
- else
- printed = printf (" %4s ", sstr);
-
- if (extra_sym_info && printed < 16)
- printf ("%*s", 16 - printed, "");
- }
- else
- {
- printf (" %4u ", psym->st_shndx);
-
- if (extra_sym_info)
- {
- /* Display the section name referenced by the section index. */
- int printed = printf ("(%s) ", sstr);
- if (printed < 10)
- printf ("%*s", 10 - printed, "");
- }
- }
-
- /* Get the symbol's name. For section symbols without a
- specific name use the (already computed) section name. */
- if (ELF_ST_TYPE (psym->st_info) == STT_SECTION
- && section_index_real (filedata, psym->st_shndx)
- && psym->st_name == 0)
- {
- ;
- }
- else
- {
- bool is_valid;
-
- is_valid = valid_symbol_name (strtab, strtab_size, psym->st_name);
- sstr = is_valid ? strtab + psym->st_name : _("<corrupt>");
- }
-
- version_string
- = get_symbol_version_string (filedata,
- (section == NULL
- || section->sh_type == SHT_DYNSYM),
- strtab, strtab_size, symbol_index,
- psym, &sym_info, &vna_other);
-
- int len_avail = 21;
- if (! do_wide && version_string != NULL)
- {
- char buffer[16];
-
- len_avail -= 1 + strlen (version_string);
-
- if (sym_info == symbol_undefined)
- len_avail -= sprintf (buffer," (%d)", vna_other);
- else if (sym_info != symbol_hidden)
- len_avail -= 1;
- }
-
- print_symbol_name (len_avail, sstr);
-
- if (version_string)
- {
- if (sym_info == symbol_undefined)
- printf ("@%s (%d)", version_string, vna_other);
- else
- printf (sym_info == symbol_hidden ? "@%s" : "@@%s",
- version_string);
- }
-
-#if 1
- {
- unsigned int vis = ELF_ST_VISIBILITY (psym->st_other);
-
- /* Check to see if any other bits in the st_other field are set. */
- if (psym->st_other ^ vis)
- printf (" \t[%s]", get_symbol_other (filedata, psym->st_other ^ vis));
- }
-#endif
-
- putchar ('\n');
-
- if (ELF_ST_BIND (psym->st_info) == STB_LOCAL
- && section != NULL
- && symbol_index >= section->sh_info
- /* Irix 5 and 6 MIPS binaries are known to ignore this requirement. */
- && filedata->file_header.e_machine != EM_MIPS
- /* Solaris binaries have been found to violate this requirement as
- well. Not sure if this is a bug or an ABI requirement. */
- && filedata->file_header.e_ident[EI_OSABI] != ELFOSABI_SOLARIS)
- warn (_("local symbol %" PRIu64 " found at index >= %s's sh_info value of %u\n"),
- symbol_index, printable_section_name (filedata, section), section->sh_info);
-}
-
-static const char *
-get_lto_kind (unsigned int kind)
-{
- switch (kind)
- {
- case 0: return "DEF";
- case 1: return "WEAKDEF";
- case 2: return "UNDEF";
- case 3: return "WEAKUNDEF";
- case 4: return "COMMON";
- default:
- break;
- }
-
- static char buffer[30];
- error (_("Unknown LTO symbol definition encountered: %u\n"), kind);
- sprintf (buffer, "<unknown: %u>", kind);
- return buffer;
-}
-
-static const char *
-get_lto_visibility (unsigned int visibility)
-{
- switch (visibility)
- {
- case 0: return "DEFAULT";
- case 1: return "PROTECTED";
- case 2: return "INTERNAL";
- case 3: return "HIDDEN";
- default:
- break;
- }
-
- static char buffer[30];
- error (_("Unknown LTO symbol visibility encountered: %u\n"), visibility);
- sprintf (buffer, "<unknown: %u>", visibility);
- return buffer;
-}
-
-static const char *
-get_lto_sym_type (unsigned int sym_type)
-{
- switch (sym_type)
- {
- case 0: return "UNKNOWN";
- case 1: return "FUNCTION";
- case 2: return "VARIABLE";
- default:
- break;
- }
-
- static char buffer[30];
- error (_("Unknown LTO symbol type encountered: %u\n"), sym_type);
- sprintf (buffer, "<unknown: %u>", sym_type);
- return buffer;
-}
-
-/* Display an LTO format symbol table.
- FIXME: The format of LTO symbol tables is not formalized.
- So this code could need changing in the future. */
-
-static bool
-display_lto_symtab (Filedata * filedata,
- Elf_Internal_Shdr * section)
-{
- if (section->sh_size == 0)
- {
- if (filedata->is_separate)
- printf (_("\nThe LTO Symbol table section '%s' in linked file '%s' is empty!\n"),
- printable_section_name (filedata, section),
- filedata->file_name);
- else
- printf (_("\nLTO Symbol table '%s' is empty!\n"),
- printable_section_name (filedata, section));
-
- return true;
- }
-
- if (section->sh_size > filedata->file_size)
- {
- error (_("Section %s has an invalid sh_size of %#" PRIx64 "\n"),
- printable_section_name (filedata, section),
- section->sh_size);
- return false;
- }
-
- void * alloced_data = get_data (NULL, filedata, section->sh_offset,
- section->sh_size, 1, _("LTO symbols"));
- if (alloced_data == NULL)
- return false;
-
- /* Look for extended data for the symbol table. */
- Elf_Internal_Shdr * ext = NULL;
- void * ext_data_orig = NULL;
- char * ext_data = NULL;
- char * ext_data_end = NULL;
- char * ext_name = NULL;
-
- if (asprintf (& ext_name, ".gnu.lto_.ext_symtab.%s",
- (section_name (filedata, section)
- + sizeof (".gnu.lto_.symtab.") - 1)) > 0
- && ext_name != NULL /* Paranoia. */
- && (ext = find_section (filedata, ext_name)) != NULL)
- {
- if (ext->sh_size < 3)
- error (_("LTO Symbol extension table '%s' is empty!\n"),
- printable_section_name (filedata, ext));
- else
- {
- ext_data_orig = ext_data = get_data (NULL, filedata, ext->sh_offset,
- ext->sh_size, 1,
- _("LTO ext symbol data"));
- if (ext_data != NULL)
- {
- ext_data_end = ext_data + ext->sh_size;
- if (* ext_data++ != 1)
- error (_("Unexpected version number in symbol extension table\n"));
- }
- }
- }
-
- const unsigned char * data = (const unsigned char *) alloced_data;
- const unsigned char * end = data + section->sh_size;
-
- if (filedata->is_separate)
- printf (_("\nIn linked file '%s': "), filedata->file_name);
- else
- printf ("\n");
-
- if (ext_data_orig != NULL)
- {
- if (do_wide)
- printf (_("LTO Symbol table '%s' and extension table '%s' contain:\n"),
- printable_section_name (filedata, section),
- printable_section_name (filedata, ext));
- else
- {
- printf (_("LTO Symbol table '%s'\n"),
- printable_section_name (filedata, section));
- printf (_(" and extension table '%s' contain:\n"),
- printable_section_name (filedata, ext));
- }
- }
- else
- printf (_("LTO Symbol table '%s' contains:\n"),
- printable_section_name (filedata, section));
-
- /* FIXME: Add a wide version. */
- if (ext_data_orig != NULL)
- printf (_(" Comdat_Key Kind Visibility Size Slot Type Section Name\n"));
- else
- printf (_(" Comdat_Key Kind Visibility Size Slot Name\n"));
-
- /* FIXME: We do not handle style prefixes. */
-
- while (data < end)
- {
- const unsigned char * sym_name = data;
- data += strnlen ((const char *) sym_name, end - data) + 1;
- if (data >= end)
- goto fail;
-
- const unsigned char * comdat_key = data;
- data += strnlen ((const char *) comdat_key, end - data) + 1;
- if (data >= end)
- goto fail;
-
- if (data + 2 + 8 + 4 > end)
- goto fail;
-
- unsigned int kind = *data++;
- unsigned int visibility = *data++;
-
- uint64_t size = byte_get (data, 8);
- data += 8;
-
- uint64_t slot = byte_get (data, 4);
- data += 4;
-
- if (ext_data != NULL)
- {
- if (ext_data < (ext_data_end - 1))
- {
- unsigned int sym_type = * ext_data ++;
- unsigned int sec_kind = * ext_data ++;
-
- printf (" %10s %10s %11s %08" PRIx64 " %08" PRIx64 " %9s %08x _",
- * comdat_key == 0 ? "-" : (char *) comdat_key,
- get_lto_kind (kind),
- get_lto_visibility (visibility),
- size,
- slot,
- get_lto_sym_type (sym_type),
- sec_kind);
- print_symbol_name (6, (const char *) sym_name);
- }
- else
- {
- error (_("Ran out of LTO symbol extension data\n"));
- ext_data = NULL;
- /* FIXME: return FAIL result ? */
- }
- }
- else
- {
- printf (" %10s %10s %11s %08" PRIx64 " %08" PRIx64 " _",
- * comdat_key == 0 ? "-" : (char *) comdat_key,
- get_lto_kind (kind),
- get_lto_visibility (visibility),
- size,
- slot);
- print_symbol_name (21, (const char *) sym_name);
- }
- putchar ('\n');
- }
-
- if (ext_data != NULL && ext_data < ext_data_end)
- {
- error (_("Data remains in the LTO symbol extension table\n"));
- goto fail;
- }
-
- free (alloced_data);
- free (ext_data_orig);
- free (ext_name);
- return true;
-
- fail:
- error (_("Buffer overrun encountered whilst decoding LTO symbol table\n"));
- free (alloced_data);
- free (ext_data_orig);
- free (ext_name);
- return false;
-}
-
-/* Display LTO symbol tables. */
-
-static bool
-process_lto_symbol_tables (Filedata * filedata)
-{
- Elf_Internal_Shdr * section;
- unsigned int i;
- bool res = true;
-
- if (!do_lto_syms)
- return true;
-
- if (filedata->section_headers == NULL)
- return true;
-
- for (i = 0, section = filedata->section_headers;
- i < filedata->file_header.e_shnum;
- i++, section++)
- if (section_name_valid (filedata, section)
- && startswith (section_name (filedata, section), ".gnu.lto_.symtab."))
- res &= display_lto_symtab (filedata, section);
-
- return res;
-}
-
-static void
-print_symbol_table_heading (void)
-{
- /* FIXME: We should store the size of each field in the display in a table and
- then use the values inside print_symbol(), instead of that function using
- hard coded constants. */
- if (is_32bit_elf)
- {
- if (extra_sym_info)
- {
- printf (_(" Num: Value Size Type Bind Vis+Other Ndx(SecName) Name [+ Version Info]\n"));
- /* |--6-|: |--8---| |-5-| |--7--| |-6--| |--7--| |---8--| |----13.....| |........... */
- /* eg: 5: 00000000 14 FUNC LOCAL DEFAULT 1 (.text) get_sections */
- }
- else if (do_wide)
- {
- printf (_(" Num: Value Size Type Bind Vis Ndx Name\n"));
- /* |--6-|: |--8---| |-5-| |--7--| |-6--| |--7--| |-4| |........... */
- /* eg: 5: 00000000 14 FUNC LOCAL DEFAULT 1 get_sections */
- }
- else
- {
- printf (_(" Num: Value Size Type Bind Vis Ndx Name\n"));
- /* |--6-|: |--8---| |-5-| |--7--| |-6--| |--7--| |-4| |------------29-------------| */
- /* eg: 5: 00000000 14 FUNC LOCAL DEFAULT 1 get_sections */
- }
- }
- else
- {
- if (extra_sym_info)
- {
- printf (_(" Num: Value Size Type Bind Vis+Other Ndx(SecName) Name [+ Version Info]\n"));
- /* |--6-|: |------16------| |-5-| |--7--| |-6--| |--7--| |-------14---| |..... */
- /* eg: 2: 0000000000000000 0 FUNC LOCAL DEFAULT 1 (.text) .very_long_function_name */
-
- }
- else if (do_wide)
- {
- printf (_(" Num: Value Size Type Bind Vis Ndx Name\n"));
- /* |--6-|: |------16------| |-5-| |--7--| |-6--| |--7--| |-4| |........... */
- /* eg: 5: 0000000000000000 14 FUNC LOCAL DEFAULT 1 very_long_function_name */
- }
- else
- {
- printf (_(" Num: Value Size Type Bind Vis Ndx Name\n"));
- /* |--6-|: |------16------| |-5-| |--7--| |-6--| |--7--| |-4| |--------21---------| */
- /* eg: 5: 0000000000000000 14 FUNC LOCAL DEFAULT 1 very_long_functi[...] */
- }
- }
-}
-
-static bool
-dump_symbol_section (Elf_Internal_Shdr * section,
- Filedata * filedata)
-{
- if (section->sh_entsize == 0)
- {
- printf (_("\nSymbol table '%s' has a sh_entsize of zero!\n"),
- printable_section_name (filedata, section));
- return false;
- }
-
- uint64_t num_syms = section->sh_size / section->sh_entsize;
-
- if (filedata->is_separate)
- printf (ngettext ("\nIn linked file '%s' symbol section '%s'"
- " contains %" PRIu64 " entry:\n",
- "\nIn linked file '%s' symbol section '%s'"
- " contains %" PRIu64 " entries:\n",
- num_syms),
- filedata->file_name,
- printable_section_name (filedata, section),
- num_syms);
- else
- printf (ngettext ("\nSymbol table '%s' contains %" PRIu64
- " entry:\n",
- "\nSymbol table '%s' contains %" PRIu64
- " entries:\n",
- num_syms),
- printable_section_name (filedata, section),
- num_syms);
-
- print_symbol_table_heading ();
-
- Elf_Internal_Sym * symtab = get_elf_symbols (filedata, section, & num_syms);
- if (symtab == NULL)
- /* An error message will have already been displayed. */
- return false;
-
- char * strtab = NULL;
- uint64_t strtab_size = 0;
-
- if (section->sh_link == filedata->file_header.e_shstrndx)
- {
- strtab = filedata->string_table;
- strtab_size = filedata->string_table_length;
- }
- else if (section->sh_link < filedata->file_header.e_shnum)
- {
- Elf_Internal_Shdr * string_sec;
-
- string_sec = filedata->section_headers + section->sh_link;
-
- strtab = (char *) get_data (NULL, filedata, string_sec->sh_offset,
- 1, string_sec->sh_size,
- _("string table"));
- strtab_size = strtab != NULL ? string_sec->sh_size : 0;
- }
-
- uint64_t si;
-
- for (si = 0; si < num_syms; si++)
- print_symbol (filedata, si, symtab, section, strtab, strtab_size);
-
- free (symtab);
-
- if (strtab != filedata->string_table)
- free (strtab);
-
- return true;
-}
-
-/* Dump the symbol table. */
-
-static bool
-process_symbol_table (Filedata * filedata)
-{
- Elf_Internal_Shdr * section;
-
- if (!do_syms && !do_dyn_syms && !do_histogram)
- return true;
-
- if ((filedata->dynamic_info[DT_HASH] || filedata->dynamic_info_DT_GNU_HASH)
- && do_syms
- && do_using_dynamic
- && filedata->dynamic_strings != NULL
- && filedata->dynamic_symbols != NULL)
- {
- uint64_t si;
-
- if (filedata->is_separate)
- {
- printf (ngettext ("\nIn linked file '%s' the dynamic symbol table"
- " contains %" PRIu64 " entry:\n",
- "\nIn linked file '%s' the dynamic symbol table"
- " contains %" PRIu64 " entries:\n",
- filedata->num_dynamic_syms),
- filedata->file_name,
- filedata->num_dynamic_syms);
- }
- else
- {
- printf (ngettext ("\nSymbol table for image contains %" PRIu64
- " entry:\n",
- "\nSymbol table for image contains %" PRIu64
- " entries:\n",
- filedata->num_dynamic_syms),
- filedata->num_dynamic_syms);
- }
-
- print_symbol_table_heading ();
-
- for (si = 0; si < filedata->num_dynamic_syms; si++)
- print_symbol (filedata, si, filedata->dynamic_symbols, NULL,
- filedata->dynamic_strings,
- filedata->dynamic_strings_length);
- }
- else if ((do_dyn_syms || (do_syms && !do_using_dynamic))
- && filedata->section_headers != NULL)
- {
- unsigned int i;
-
- for (i = 0, section = filedata->section_headers;
- i < filedata->file_header.e_shnum;
- i++, section++)
- {
- if ((section->sh_type != SHT_SYMTAB
- && section->sh_type != SHT_DYNSYM)
- || (!do_syms
- && section->sh_type == SHT_SYMTAB))
- continue;
-
- dump_symbol_section (section, filedata);
- }
- }
- else if (do_syms)
- printf
- (_("\nDynamic symbol information is not available for displaying symbols.\n"));
-
- if (do_histogram && filedata->buckets != NULL)
- {
- uint64_t *lengths;
- uint64_t *counts;
- uint64_t hn;
- uint64_t si;
- uint64_t maxlength = 0;
- uint64_t nzero_counts = 0;
- uint64_t nsyms = 0;
- char *visited;
-
- printf (ngettext ("\nHistogram for bucket list length "
- "(total of %" PRIu64 " bucket):\n",
- "\nHistogram for bucket list length "
- "(total of %" PRIu64 " buckets):\n",
- filedata->nbuckets),
- filedata->nbuckets);
-
- lengths = calloc (filedata->nbuckets, sizeof (*lengths));
- if (lengths == NULL)
- {
- error (_("Out of memory allocating space for histogram buckets\n"));
- goto err_out;
- }
- visited = xcmalloc (filedata->nchains, 1);
- memset (visited, 0, filedata->nchains);
-
- printf (_(" Length Number %% of total Coverage\n"));
- for (hn = 0; hn < filedata->nbuckets; ++hn)
- {
- for (si = filedata->buckets[hn]; si > 0; si = filedata->chains[si])
- {
- ++nsyms;
- if (maxlength < ++lengths[hn])
- ++maxlength;
- if (si >= filedata->nchains || visited[si])
- {
- error (_("histogram chain is corrupt\n"));
- break;
- }
- visited[si] = 1;
- }
- }
- free (visited);
-
- counts = calloc (maxlength + 1, sizeof (*counts));
- if (counts == NULL)
- {
- free (lengths);
- error (_("Out of memory allocating space for histogram counts\n"));
- goto err_out;
- }
-
- for (hn = 0; hn < filedata->nbuckets; ++hn)
- ++counts[lengths[hn]];
-
- if (filedata->nbuckets > 0)
- {
- uint64_t i;
- printf (" 0 %-10" PRIu64 " (%5.1f%%)\n",
- counts[0], (counts[0] * 100.0) / filedata->nbuckets);
- for (i = 1; i <= maxlength; ++i)
- {
- nzero_counts += counts[i] * i;
- printf ("%7" PRIu64 " %-10" PRIu64 " (%5.1f%%) %5.1f%%\n",
- i, counts[i], (counts[i] * 100.0) / filedata->nbuckets,
- (nzero_counts * 100.0) / nsyms);
- }
- }
-
- free (counts);
- free (lengths);
- }
-
- free (filedata->buckets);
- filedata->buckets = NULL;
- filedata->nbuckets = 0;
- free (filedata->chains);
- filedata->chains = NULL;
-
- if (do_histogram && filedata->gnubuckets != NULL)
- {
- uint64_t *lengths;
- uint64_t *counts;
- uint64_t hn;
- uint64_t maxlength = 0;
- uint64_t nzero_counts = 0;
- uint64_t nsyms = 0;
-
- printf (ngettext ("\nHistogram for `%s' bucket list length "
- "(total of %" PRIu64 " bucket):\n",
- "\nHistogram for `%s' bucket list length "
- "(total of %" PRIu64 " buckets):\n",
- filedata->ngnubuckets),
- GNU_HASH_SECTION_NAME (filedata),
- filedata->ngnubuckets);
-
- lengths = calloc (filedata->ngnubuckets, sizeof (*lengths));
- if (lengths == NULL)
- {
- error (_("Out of memory allocating space for gnu histogram buckets\n"));
- goto err_out;
- }
-
- printf (_(" Length Number %% of total Coverage\n"));
-
- for (hn = 0; hn < filedata->ngnubuckets; ++hn)
- if (filedata->gnubuckets[hn] != 0)
- {
- uint64_t off, length = 1;
-
- for (off = filedata->gnubuckets[hn] - filedata->gnusymidx;
- /* PR 17531 file: 010-77222-0.004. */
- off < filedata->ngnuchains
- && (filedata->gnuchains[off] & 1) == 0;
- ++off)
- ++length;
- lengths[hn] = length;
- if (length > maxlength)
- maxlength = length;
- nsyms += length;
- }
-
- counts = calloc (maxlength + 1, sizeof (*counts));
- if (counts == NULL)
- {
- free (lengths);
- error (_("Out of memory allocating space for gnu histogram counts\n"));
- goto err_out;
- }
-
- for (hn = 0; hn < filedata->ngnubuckets; ++hn)
- ++counts[lengths[hn]];
-
- if (filedata->ngnubuckets > 0)
- {
- uint64_t j;
- printf (" 0 %-10" PRIu64 " (%5.1f%%)\n",
- counts[0], (counts[0] * 100.0) / filedata->ngnubuckets);
- for (j = 1; j <= maxlength; ++j)
- {
- nzero_counts += counts[j] * j;
- printf ("%7" PRIu64 " %-10" PRIu64 " (%5.1f%%) %5.1f%%\n",
- j, counts[j], (counts[j] * 100.0) / filedata->ngnubuckets,
- (nzero_counts * 100.0) / nsyms);
- }
- }
-
- free (counts);
- free (lengths);
- }
- free (filedata->gnubuckets);
- filedata->gnubuckets = NULL;
- filedata->ngnubuckets = 0;
- free (filedata->gnuchains);
- filedata->gnuchains = NULL;
- filedata->ngnuchains = 0;
- free (filedata->mipsxlat);
- filedata->mipsxlat = NULL;
- return true;
-
- err_out:
- free (filedata->gnubuckets);
- filedata->gnubuckets = NULL;
- filedata->ngnubuckets = 0;
- free (filedata->gnuchains);
- filedata->gnuchains = NULL;
- filedata->ngnuchains = 0;
- free (filedata->mipsxlat);
- filedata->mipsxlat = NULL;
- free (filedata->buckets);
- filedata->buckets = NULL;
- filedata->nbuckets = 0;
- free (filedata->chains);
- filedata->chains = NULL;
- return false;
-}
-
-static bool
-process_syminfo (Filedata * filedata)
-{
- unsigned int i;
-
- if (filedata->dynamic_syminfo == NULL
- || !do_dynamic)
- /* No syminfo, this is ok. */
- return true;
-
- /* There better should be a dynamic symbol section. */
- if (filedata->dynamic_symbols == NULL || filedata->dynamic_strings == NULL)
- return false;
-
- if (filedata->is_separate)
- printf (ngettext ("\nIn linked file '%s: the dynamic info segment at offset %#" PRIx64 " contains %d entry:\n",
- "\nIn linked file '%s: the dynamic info segment at offset %#" PRIx64 " contains %d entries:\n",
- filedata->dynamic_syminfo_nent),
- filedata->file_name,
- filedata->dynamic_syminfo_offset,
- filedata->dynamic_syminfo_nent);
- else
- printf (ngettext ("\nDynamic info segment at offset %#" PRIx64
- " contains %d entry:\n",
- "\nDynamic info segment at offset %#" PRIx64
- " contains %d entries:\n",
- filedata->dynamic_syminfo_nent),
- filedata->dynamic_syminfo_offset,
- filedata->dynamic_syminfo_nent);
-
- printf (_(" Num: Name BoundTo Flags\n"));
- for (i = 0; i < filedata->dynamic_syminfo_nent; ++i)
- {
- unsigned short int flags = filedata->dynamic_syminfo[i].si_flags;
-
- printf ("%4d: ", i);
- if (i >= filedata->num_dynamic_syms)
- printf (_("<corrupt index>"));
- else if (valid_dynamic_name (filedata, filedata->dynamic_symbols[i].st_name))
- print_symbol_name (30, get_dynamic_name (filedata,
- filedata->dynamic_symbols[i].st_name));
- else
- printf (_("<corrupt: %19ld>"), filedata->dynamic_symbols[i].st_name);
- putchar (' ');
-
- switch (filedata->dynamic_syminfo[i].si_boundto)
- {
- case SYMINFO_BT_SELF:
- fputs ("SELF ", stdout);
- break;
- case SYMINFO_BT_PARENT:
- fputs ("PARENT ", stdout);
- break;
- default:
- if (filedata->dynamic_syminfo[i].si_boundto > 0
- && filedata->dynamic_syminfo[i].si_boundto < filedata->dynamic_nent
- && valid_dynamic_name (filedata,
- filedata->dynamic_section[filedata->dynamic_syminfo[i].si_boundto].d_un.d_val))
- {
- print_symbol_name (10, get_dynamic_name (filedata,
- filedata->dynamic_section[filedata->dynamic_syminfo[i].si_boundto].d_un.d_val));
- putchar (' ' );
- }
- else
- printf ("%-10d ", filedata->dynamic_syminfo[i].si_boundto);
- break;
- }
-
- if (flags & SYMINFO_FLG_DIRECT)
- printf (" DIRECT");
- if (flags & SYMINFO_FLG_PASSTHRU)
- printf (" PASSTHRU");
- if (flags & SYMINFO_FLG_COPY)
- printf (" COPY");
- if (flags & SYMINFO_FLG_LAZYLOAD)
- printf (" LAZYLOAD");
-
- puts ("");
- }
-
- return true;
-}
-
-/* A macro which evaluates to TRUE if the region ADDR .. ADDR + NELEM
- is contained by the region START .. END. The types of ADDR, START
- and END should all be the same. Note both ADDR + NELEM and END
- point to just beyond the end of the regions that are being tested. */
-#define IN_RANGE(START,END,ADDR,NELEM) \
- (((ADDR) >= (START)) && ((ADDR) < (END)) && ((ADDR) + (NELEM) <= (END)))
-
-/* Check to see if the given reloc needs to be handled in a target specific
- manner. If so then process the reloc and return TRUE otherwise return
- FALSE.
-
- If called with reloc == NULL, then this is a signal that reloc processing
- for the current section has finished, and any saved state should be
- discarded. */
-
-static bool
-target_specific_reloc_handling (Filedata *filedata,
- Elf_Internal_Rela *reloc,
- unsigned char *start,
- unsigned char *end,
- Elf_Internal_Sym *symtab,
- uint64_t num_syms)
-{
- unsigned int reloc_type = 0;
- uint64_t sym_index = 0;
-
- if (reloc)
- {
- reloc_type = get_reloc_type (filedata, reloc->r_info);
- sym_index = get_reloc_symindex (reloc->r_info);
- }
-
- switch (filedata->file_header.e_machine)
- {
- case EM_LOONGARCH:
- {
- switch (reloc_type)
- {
- /* For .uleb128 .LFE1-.LFB1, loongarch write 0 to object file
- at assembly time. */
- case 107: /* R_LARCH_ADD_ULEB128. */
- case 108: /* R_LARCH_SUB_ULEB128. */
- {
- uint64_t value = 0;
- unsigned int reloc_size = 0;
- int leb_ret = 0;
-
- if (reloc->r_offset < (size_t) (end - start))
- value = read_leb128 (start + reloc->r_offset, end, false,
- &reloc_size, &leb_ret);
- if (leb_ret != 0 || reloc_size == 0 || reloc_size > 8)
- error (_("LoongArch ULEB128 field at 0x%lx contains invalid "
- "ULEB128 value\n"),
- (long) reloc->r_offset);
-
- else if (sym_index >= num_syms)
- error (_("%s reloc contains invalid symbol index "
- "%" PRIu64 "\n"),
- (reloc_type == 107
- ? "R_LARCH_ADD_ULEB128"
- : "R_LARCH_SUB_ULEB128"),
- sym_index);
- else
- {
- if (reloc_type == 107)
- value += reloc->r_addend + symtab[sym_index].st_value;
- else
- value -= reloc->r_addend + symtab[sym_index].st_value;
-
- /* Write uleb128 value to p. */
- bfd_byte *p = start + reloc->r_offset;
- do
- {
- bfd_byte c = value & 0x7f;
- value >>= 7;
- if (--reloc_size != 0)
- c |= 0x80;
- *p++ = c;
- }
- while (reloc_size);
- }
-
- return true;
- }
- }
- break;
- }
-
- case EM_MSP430:
- case EM_MSP430_OLD:
- {
- static Elf_Internal_Sym * saved_sym = NULL;
-
- if (reloc == NULL)
- {
- saved_sym = NULL;
- return true;
- }
-
- switch (reloc_type)
- {
- case 10: /* R_MSP430_SYM_DIFF */
- case 12: /* R_MSP430_GNU_SUB_ULEB128 */
- if (uses_msp430x_relocs (filedata))
- break;
- /* Fall through. */
- case 21: /* R_MSP430X_SYM_DIFF */
- case 23: /* R_MSP430X_GNU_SUB_ULEB128 */
- /* PR 21139. */
- if (sym_index >= num_syms)
- error (_("%s reloc contains invalid symbol index "
- "%" PRIu64 "\n"), "MSP430 SYM_DIFF", sym_index);
- else
- saved_sym = symtab + sym_index;
- return true;
-
- case 1: /* R_MSP430_32 or R_MSP430_ABS32 */
- case 3: /* R_MSP430_16 or R_MSP430_ABS8 */
- goto handle_sym_diff;
-
- case 5: /* R_MSP430_16_BYTE */
- case 9: /* R_MSP430_8 */
- case 11: /* R_MSP430_GNU_SET_ULEB128 */
- if (uses_msp430x_relocs (filedata))
- break;
- goto handle_sym_diff;
-
- case 2: /* R_MSP430_ABS16 */
- case 15: /* R_MSP430X_ABS16 */
- case 22: /* R_MSP430X_GNU_SET_ULEB128 */
- if (! uses_msp430x_relocs (filedata))
- break;
- goto handle_sym_diff;
-
- handle_sym_diff:
- if (saved_sym != NULL)
- {
- uint64_t value;
- unsigned int reloc_size = 0;
- int leb_ret = 0;
- switch (reloc_type)
- {
- case 1: /* R_MSP430_32 or R_MSP430_ABS32 */
- reloc_size = 4;
- break;
- case 11: /* R_MSP430_GNU_SET_ULEB128 */
- case 22: /* R_MSP430X_GNU_SET_ULEB128 */
- if (reloc->r_offset < (size_t) (end - start))
- read_leb128 (start + reloc->r_offset, end, false,
- &reloc_size, &leb_ret);
- break;
- default:
- reloc_size = 2;
- break;
- }
-
- if (leb_ret != 0 || reloc_size == 0 || reloc_size > 8)
- error (_("MSP430 ULEB128 field at %#" PRIx64
- " contains invalid ULEB128 value\n"),
- reloc->r_offset);
- else if (sym_index >= num_syms)
- error (_("%s reloc contains invalid symbol index "
- "%" PRIu64 "\n"), "MSP430", sym_index);
- else
- {
- value = reloc->r_addend + (symtab[sym_index].st_value
- - saved_sym->st_value);
-
- if (IN_RANGE (start, end, start + reloc->r_offset, reloc_size))
- byte_put (start + reloc->r_offset, value, reloc_size);
- else
- /* PR 21137 */
- error (_("MSP430 sym diff reloc contains invalid offset: "
- "%#" PRIx64 "\n"),
- reloc->r_offset);
- }
-
- saved_sym = NULL;
- return true;
- }
- break;
-
- default:
- if (saved_sym != NULL)
- error (_("Unhandled MSP430 reloc type found after SYM_DIFF reloc\n"));
- break;
- }
- break;
- }
-
- case EM_MN10300:
- case EM_CYGNUS_MN10300:
- {
- static Elf_Internal_Sym * saved_sym = NULL;
-
- if (reloc == NULL)
- {
- saved_sym = NULL;
- return true;
- }
-
- switch (reloc_type)
- {
- case 34: /* R_MN10300_ALIGN */
- return true;
- case 33: /* R_MN10300_SYM_DIFF */
- if (sym_index >= num_syms)
- error (_("%s reloc contains invalid symbol index "
- "%" PRIu64 "\n"), "MN10300_SYM_DIFF", sym_index);
- else
- saved_sym = symtab + sym_index;
- return true;
-
- case 1: /* R_MN10300_32 */
- case 2: /* R_MN10300_16 */
- if (saved_sym != NULL)
- {
- int reloc_size = reloc_type == 1 ? 4 : 2;
- uint64_t value;
-
- if (sym_index >= num_syms)
- error (_("%s reloc contains invalid symbol index "
- "%" PRIu64 "\n"), "MN10300", sym_index);
- else
- {
- value = reloc->r_addend + (symtab[sym_index].st_value
- - saved_sym->st_value);
-
- if (IN_RANGE (start, end, start + reloc->r_offset, reloc_size))
- byte_put (start + reloc->r_offset, value, reloc_size);
- else
- error (_("MN10300 sym diff reloc contains invalid offset:"
- " %#" PRIx64 "\n"),
- reloc->r_offset);
- }
-
- saved_sym = NULL;
- return true;
- }
- break;
- default:
- if (saved_sym != NULL)
- error (_("Unhandled MN10300 reloc type found after SYM_DIFF reloc\n"));
- break;
- }
- break;
- }
-
- case EM_RL78:
- {
- static uint64_t saved_sym1 = 0;
- static uint64_t saved_sym2 = 0;
- static uint64_t value;
-
- if (reloc == NULL)
- {
- saved_sym1 = saved_sym2 = 0;
- return true;
- }
-
- switch (reloc_type)
- {
- case 0x80: /* R_RL78_SYM. */
- saved_sym1 = saved_sym2;
- if (sym_index >= num_syms)
- error (_("%s reloc contains invalid symbol index "
- "%" PRIu64 "\n"), "RL78_SYM", sym_index);
- else
- {
- saved_sym2 = symtab[sym_index].st_value;
- saved_sym2 += reloc->r_addend;
- }
- return true;
-
- case 0x83: /* R_RL78_OPsub. */
- value = saved_sym1 - saved_sym2;
- saved_sym2 = saved_sym1 = 0;
- return true;
- break;
-
- case 0x41: /* R_RL78_ABS32. */
- if (IN_RANGE (start, end, start + reloc->r_offset, 4))
- byte_put (start + reloc->r_offset, value, 4);
- else
- error (_("RL78 sym diff reloc contains invalid offset: "
- "%#" PRIx64 "\n"),
- reloc->r_offset);
- value = 0;
- return true;
-
- case 0x43: /* R_RL78_ABS16. */
- if (IN_RANGE (start, end, start + reloc->r_offset, 2))
- byte_put (start + reloc->r_offset, value, 2);
- else
- error (_("RL78 sym diff reloc contains invalid offset: "
- "%#" PRIx64 "\n"),
- reloc->r_offset);
- value = 0;
- return true;
-
- default:
- break;
- }
- break;
- }
- }
-
- return false;
-}
-
-/* Returns TRUE iff RELOC_TYPE is a 32-bit absolute RELA relocation used in
- DWARF debug sections. This is a target specific test. Note - we do not
- go through the whole including-target-headers-multiple-times route, (as
- we have already done with <elf/h8.h>) because this would become very
- messy and even then this function would have to contain target specific
- information (the names of the relocs instead of their numeric values).
- FIXME: This is not the correct way to solve this problem. The proper way
- is to have target specific reloc sizing and typing functions created by
- the reloc-macros.h header, in the same way that it already creates the
- reloc naming functions. */
-
-static bool
-is_32bit_abs_reloc (Filedata * filedata, unsigned int reloc_type)
-{
- /* Please keep this table alpha-sorted for ease of visual lookup. */
- switch (filedata->file_header.e_machine)
- {
- case EM_386:
- case EM_IAMCU:
- return reloc_type == 1; /* R_386_32. */
- case EM_68K:
- return reloc_type == 1; /* R_68K_32. */
- case EM_860:
- return reloc_type == 1; /* R_860_32. */
- case EM_960:
- return reloc_type == 2; /* R_960_32. */
- case EM_AARCH64:
- return (reloc_type == 258
- || reloc_type == 1); /* R_AARCH64_ABS32 || R_AARCH64_P32_ABS32 */
- case EM_BPF:
- return reloc_type == 11; /* R_BPF_DATA_32 */
- case EM_ADAPTEVA_EPIPHANY:
- return reloc_type == 3;
- case EM_ALPHA:
- return reloc_type == 1; /* R_ALPHA_REFLONG. */
- case EM_ARC:
- return reloc_type == 1; /* R_ARC_32. */
- case EM_ARC_COMPACT:
- case EM_ARC_COMPACT2:
- case EM_ARC_COMPACT3:
- case EM_ARC_COMPACT3_64:
- return reloc_type == 4; /* R_ARC_32. */
- case EM_ARM:
- return reloc_type == 2; /* R_ARM_ABS32 */
- case EM_AVR_OLD:
- case EM_AVR:
- return reloc_type == 1;
- case EM_BLACKFIN:
- return reloc_type == 0x12; /* R_byte4_data. */
- case EM_CRIS:
- return reloc_type == 3; /* R_CRIS_32. */
- case EM_CR16:
- return reloc_type == 3; /* R_CR16_NUM32. */
- case EM_CRX:
- return reloc_type == 15; /* R_CRX_NUM32. */
- case EM_CSKY:
- return reloc_type == 1; /* R_CKCORE_ADDR32. */
- case EM_CYGNUS_FRV:
- return reloc_type == 1;
- case EM_CYGNUS_D10V:
- case EM_D10V:
- return reloc_type == 6; /* R_D10V_32. */
- case EM_CYGNUS_D30V:
- case EM_D30V:
- return reloc_type == 12; /* R_D30V_32_NORMAL. */
- case EM_DLX:
- return reloc_type == 3; /* R_DLX_RELOC_32. */
- case EM_CYGNUS_FR30:
- case EM_FR30:
- return reloc_type == 3; /* R_FR30_32. */
- case EM_FT32:
- return reloc_type == 1; /* R_FT32_32. */
- case EM_H8S:
- case EM_H8_300:
- case EM_H8_300H:
- return reloc_type == 1; /* R_H8_DIR32. */
- case EM_IA_64:
- return (reloc_type == 0x64 /* R_IA64_SECREL32MSB. */
- || reloc_type == 0x65 /* R_IA64_SECREL32LSB. */
- || reloc_type == 0x24 /* R_IA64_DIR32MSB. */
- || reloc_type == 0x25 /* R_IA64_DIR32LSB. */);
- case EM_IP2K_OLD:
- case EM_IP2K:
- return reloc_type == 2; /* R_IP2K_32. */
- case EM_IQ2000:
- return reloc_type == 2; /* R_IQ2000_32. */
- case EM_KVX:
- return reloc_type == 2; /* R_KVX_32. */
- case EM_LATTICEMICO32:
- return reloc_type == 3; /* R_LM32_32. */
- case EM_LOONGARCH:
- return reloc_type == 1; /* R_LARCH_32. */
- case EM_M32C_OLD:
- case EM_M32C:
- return reloc_type == 3; /* R_M32C_32. */
- case EM_M32R:
- return reloc_type == 34; /* R_M32R_32_RELA. */
- case EM_68HC11:
- case EM_68HC12:
- return reloc_type == 6; /* R_M68HC11_32. */
- case EM_S12Z:
- return reloc_type == 7 || /* R_S12Z_EXT32 */
- reloc_type == 6; /* R_S12Z_CW32. */
- case EM_MCORE:
- return reloc_type == 1; /* R_MCORE_ADDR32. */
- case EM_CYGNUS_MEP:
- return reloc_type == 4; /* R_MEP_32. */
- case EM_METAG:
- return reloc_type == 2; /* R_METAG_ADDR32. */
- case EM_MICROBLAZE:
- return reloc_type == 1; /* R_MICROBLAZE_32. */
- case EM_MIPS:
- return reloc_type == 2; /* R_MIPS_32. */
- case EM_MMIX:
- return reloc_type == 4; /* R_MMIX_32. */
- case EM_CYGNUS_MN10200:
- case EM_MN10200:
- return reloc_type == 1; /* R_MN10200_32. */
- case EM_CYGNUS_MN10300:
- case EM_MN10300:
- return reloc_type == 1; /* R_MN10300_32. */
- case EM_MOXIE:
- return reloc_type == 1; /* R_MOXIE_32. */
- case EM_MSP430_OLD:
- case EM_MSP430:
- return reloc_type == 1; /* R_MSP430_32 or R_MSP320_ABS32. */
- case EM_MT:
- return reloc_type == 2; /* R_MT_32. */
- case EM_NDS32:
- return reloc_type == 20; /* R_NDS32_32_RELA. */
- case EM_ALTERA_NIOS2:
- return reloc_type == 12; /* R_NIOS2_BFD_RELOC_32. */
- case EM_NIOS32:
- return reloc_type == 1; /* R_NIOS_32. */
- case EM_OR1K:
- return reloc_type == 1; /* R_OR1K_32. */
- case EM_PARISC:
- return (reloc_type == 1 /* R_PARISC_DIR32. */
- || reloc_type == 2 /* R_PARISC_DIR21L. */
- || reloc_type == 41); /* R_PARISC_SECREL32. */
- case EM_PJ:
- case EM_PJ_OLD:
- return reloc_type == 1; /* R_PJ_DATA_DIR32. */
- case EM_PPC64:
- return reloc_type == 1; /* R_PPC64_ADDR32. */
- case EM_PPC:
- return reloc_type == 1; /* R_PPC_ADDR32. */
- case EM_TI_PRU:
- return reloc_type == 11; /* R_PRU_BFD_RELOC_32. */
- case EM_RISCV:
- return reloc_type == 1; /* R_RISCV_32. */
- case EM_RL78:
- return reloc_type == 1; /* R_RL78_DIR32. */
- case EM_RX:
- return reloc_type == 1; /* R_RX_DIR32. */
- case EM_S370:
- return reloc_type == 1; /* R_I370_ADDR31. */
- case EM_S390_OLD:
- case EM_S390:
- return reloc_type == 4; /* R_S390_32. */
- case EM_SCORE:
- return reloc_type == 8; /* R_SCORE_ABS32. */
- case EM_SH:
- return reloc_type == 1; /* R_SH_DIR32. */
- case EM_SPARC32PLUS:
- case EM_SPARCV9:
- case EM_SPARC:
- return reloc_type == 3 /* R_SPARC_32. */
- || reloc_type == 23; /* R_SPARC_UA32. */
- case EM_SPU:
- return reloc_type == 6; /* R_SPU_ADDR32 */
- case EM_TI_C6000:
- return reloc_type == 1; /* R_C6000_ABS32. */
- case EM_TILEGX:
- return reloc_type == 2; /* R_TILEGX_32. */
- case EM_TILEPRO:
- return reloc_type == 1; /* R_TILEPRO_32. */
- case EM_CYGNUS_V850:
- case EM_V850:
- return reloc_type == 6; /* R_V850_ABS32. */
- case EM_V800:
- return reloc_type == 0x33; /* R_V810_WORD. */
- case EM_VAX:
- return reloc_type == 1; /* R_VAX_32. */
- case EM_VISIUM:
- return reloc_type == 3; /* R_VISIUM_32. */
- case EM_WEBASSEMBLY:
- return reloc_type == 1; /* R_WASM32_32. */
- case EM_X86_64:
- case EM_L1OM:
- case EM_K1OM:
- return reloc_type == 10; /* R_X86_64_32. */
- case EM_XGATE:
- return reloc_type == 4; /* R_XGATE_32. */
- case EM_XSTORMY16:
- return reloc_type == 1; /* R_XSTROMY16_32. */
- case EM_XTENSA_OLD:
- case EM_XTENSA:
- return reloc_type == 1; /* R_XTENSA_32. */
- case EM_Z80:
- return reloc_type == 6; /* R_Z80_32. */
- default:
- {
- static unsigned int prev_warn = 0;
-
- /* Avoid repeating the same warning multiple times. */
- if (prev_warn != filedata->file_header.e_machine)
- error (_("Missing knowledge of 32-bit reloc types used in DWARF sections of machine number %d\n"),
- filedata->file_header.e_machine);
- prev_warn = filedata->file_header.e_machine;
- return false;
- }
- }
-}
-
-/* Like is_32bit_abs_reloc except that it returns TRUE iff RELOC_TYPE is
- a 32-bit pc-relative RELA relocation used in DWARF debug sections. */
-
-static bool
-is_32bit_pcrel_reloc (Filedata * filedata, unsigned int reloc_type)
-{
- switch (filedata->file_header.e_machine)
- /* Please keep this table alpha-sorted for ease of visual lookup. */
- {
- case EM_386:
- case EM_IAMCU:
- return reloc_type == 2; /* R_386_PC32. */
- case EM_68K:
- return reloc_type == 4; /* R_68K_PC32. */
- case EM_AARCH64:
- return reloc_type == 261; /* R_AARCH64_PREL32 */
- case EM_ADAPTEVA_EPIPHANY:
- return reloc_type == 6;
- case EM_ALPHA:
- return reloc_type == 10; /* R_ALPHA_SREL32. */
- case EM_ARC_COMPACT:
- case EM_ARC_COMPACT2:
- case EM_ARC_COMPACT3:
- case EM_ARC_COMPACT3_64:
- return reloc_type == 49; /* R_ARC_32_PCREL. */
- case EM_ARM:
- return reloc_type == 3; /* R_ARM_REL32 */
- case EM_AVR_OLD:
- case EM_AVR:
- return reloc_type == 36; /* R_AVR_32_PCREL. */
- case EM_LOONGARCH:
- return reloc_type == 99; /* R_LARCH_32_PCREL. */
- case EM_MICROBLAZE:
- return reloc_type == 2; /* R_MICROBLAZE_32_PCREL. */
- case EM_OR1K:
- return reloc_type == 9; /* R_OR1K_32_PCREL. */
- case EM_PARISC:
- return reloc_type == 9; /* R_PARISC_PCREL32. */
- case EM_PPC:
- return reloc_type == 26; /* R_PPC_REL32. */
- case EM_PPC64:
- return reloc_type == 26; /* R_PPC64_REL32. */
- case EM_RISCV:
- return reloc_type == 57; /* R_RISCV_32_PCREL. */
- case EM_S390_OLD:
- case EM_S390:
- return reloc_type == 5; /* R_390_PC32. */
- case EM_SH:
- return reloc_type == 2; /* R_SH_REL32. */
- case EM_SPARC32PLUS:
- case EM_SPARCV9:
- case EM_SPARC:
- return reloc_type == 6; /* R_SPARC_DISP32. */
- case EM_SPU:
- return reloc_type == 13; /* R_SPU_REL32. */
- case EM_TILEGX:
- return reloc_type == 6; /* R_TILEGX_32_PCREL. */
- case EM_TILEPRO:
- return reloc_type == 4; /* R_TILEPRO_32_PCREL. */
- case EM_VISIUM:
- return reloc_type == 6; /* R_VISIUM_32_PCREL */
- case EM_X86_64:
- case EM_L1OM:
- case EM_K1OM:
- return reloc_type == 2; /* R_X86_64_PC32. */
- case EM_VAX:
- return reloc_type == 4; /* R_VAX_PCREL32. */
- case EM_XTENSA_OLD:
- case EM_XTENSA:
- return reloc_type == 14; /* R_XTENSA_32_PCREL. */
- case EM_KVX:
- return reloc_type == 7; /* R_KVX_32_PCREL */
- default:
- /* Do not abort or issue an error message here. Not all targets use
- pc-relative 32-bit relocs in their DWARF debug information and we
- have already tested for target coverage in is_32bit_abs_reloc. A
- more helpful warning message will be generated by apply_relocations
- anyway, so just return. */
- return false;
- }
-}
-
-/* Like is_32bit_abs_reloc except that it returns TRUE iff RELOC_TYPE is
- a 64-bit absolute RELA relocation used in DWARF debug sections. */
-
-static bool
-is_64bit_abs_reloc (Filedata * filedata, unsigned int reloc_type)
-{
- switch (filedata->file_header.e_machine)
- {
- case EM_AARCH64:
- return reloc_type == 257; /* R_AARCH64_ABS64. */
- case EM_ARC_COMPACT3_64:
- return reloc_type == 5; /* R_ARC_64. */
- case EM_ALPHA:
- return reloc_type == 2; /* R_ALPHA_REFQUAD. */
- case EM_IA_64:
- return (reloc_type == 0x26 /* R_IA64_DIR64MSB. */
- || reloc_type == 0x27 /* R_IA64_DIR64LSB. */);
- case EM_LOONGARCH:
- return reloc_type == 2; /* R_LARCH_64 */
- case EM_PARISC:
- return reloc_type == 80; /* R_PARISC_DIR64. */
- case EM_PPC64:
- return reloc_type == 38; /* R_PPC64_ADDR64. */
- case EM_RISCV:
- return reloc_type == 2; /* R_RISCV_64. */
- case EM_SPARC32PLUS:
- case EM_SPARCV9:
- case EM_SPARC:
- return reloc_type == 32 /* R_SPARC_64. */
- || reloc_type == 54; /* R_SPARC_UA64. */
- case EM_X86_64:
- case EM_L1OM:
- case EM_K1OM:
- return reloc_type == 1; /* R_X86_64_64. */
- case EM_S390_OLD:
- case EM_S390:
- return reloc_type == 22; /* R_S390_64. */
- case EM_TILEGX:
- return reloc_type == 1; /* R_TILEGX_64. */
- case EM_MIPS:
- return reloc_type == 18; /* R_MIPS_64. */
- case EM_KVX:
- return reloc_type == 3; /* R_KVX_64 */
- default:
- return false;
- }
-}
-
-/* Like is_32bit_pcrel_reloc except that it returns TRUE iff RELOC_TYPE is
- a 64-bit pc-relative RELA relocation used in DWARF debug sections. */
-
-static bool
-is_64bit_pcrel_reloc (Filedata * filedata, unsigned int reloc_type)
-{
- switch (filedata->file_header.e_machine)
- {
- case EM_AARCH64:
- return reloc_type == 260; /* R_AARCH64_PREL64. */
- case EM_ALPHA:
- return reloc_type == 11; /* R_ALPHA_SREL64. */
- case EM_IA_64:
- return (reloc_type == 0x4e /* R_IA64_PCREL64MSB. */
- || reloc_type == 0x4f /* R_IA64_PCREL64LSB. */);
- case EM_PARISC:
- return reloc_type == 72; /* R_PARISC_PCREL64. */
- case EM_PPC64:
- return reloc_type == 44; /* R_PPC64_REL64. */
- case EM_SPARC32PLUS:
- case EM_SPARCV9:
- case EM_SPARC:
- return reloc_type == 46; /* R_SPARC_DISP64. */
- case EM_X86_64:
- case EM_L1OM:
- case EM_K1OM:
- return reloc_type == 24; /* R_X86_64_PC64. */
- case EM_S390_OLD:
- case EM_S390:
- return reloc_type == 23; /* R_S390_PC64. */
- case EM_TILEGX:
- return reloc_type == 5; /* R_TILEGX_64_PCREL. */
- default:
- return false;
- }
-}
-
-/* Like is_32bit_abs_reloc except that it returns TRUE iff RELOC_TYPE is
- a 24-bit absolute RELA relocation used in DWARF debug sections. */
-
-static bool
-is_24bit_abs_reloc (Filedata * filedata, unsigned int reloc_type)
-{
- switch (filedata->file_header.e_machine)
- {
- case EM_CYGNUS_MN10200:
- case EM_MN10200:
- return reloc_type == 4; /* R_MN10200_24. */
- case EM_FT32:
- return reloc_type == 5; /* R_FT32_20. */
- case EM_Z80:
- return reloc_type == 5; /* R_Z80_24. */
- default:
- return false;
- }
-}
-
-/* Like is_32bit_abs_reloc except that it returns TRUE iff RELOC_TYPE is
- a 16-bit absolute RELA relocation used in DWARF debug sections. */
-
-static bool
-is_16bit_abs_reloc (Filedata * filedata, unsigned int reloc_type)
-{
- /* Please keep this table alpha-sorted for ease of visual lookup. */
- switch (filedata->file_header.e_machine)
- {
- case EM_ARC:
- case EM_ARC_COMPACT:
- case EM_ARC_COMPACT2:
- case EM_ARC_COMPACT3:
- case EM_ARC_COMPACT3_64:
- return reloc_type == 2; /* R_ARC_16. */
- case EM_ADAPTEVA_EPIPHANY:
- return reloc_type == 5;
- case EM_AVR_OLD:
- case EM_AVR:
- return reloc_type == 4; /* R_AVR_16. */
- case EM_CYGNUS_D10V:
- case EM_D10V:
- return reloc_type == 3; /* R_D10V_16. */
- case EM_FT32:
- return reloc_type == 2; /* R_FT32_16. */
- case EM_H8S:
- case EM_H8_300:
- case EM_H8_300H:
- return reloc_type == R_H8_DIR16;
- case EM_IP2K_OLD:
- case EM_IP2K:
- return reloc_type == 1; /* R_IP2K_16. */
- case EM_M32C_OLD:
- case EM_M32C:
- return reloc_type == 1; /* R_M32C_16 */
- case EM_CYGNUS_MN10200:
- case EM_MN10200:
- return reloc_type == 2; /* R_MN10200_16. */
- case EM_CYGNUS_MN10300:
- case EM_MN10300:
- return reloc_type == 2; /* R_MN10300_16. */
- case EM_KVX:
- return reloc_type == 1; /* R_KVX_16 */
- case EM_MSP430:
- if (uses_msp430x_relocs (filedata))
- return reloc_type == 2; /* R_MSP430_ABS16. */
- /* Fall through. */
- case EM_MSP430_OLD:
- return reloc_type == 5; /* R_MSP430_16_BYTE. */
- case EM_NDS32:
- return reloc_type == 19; /* R_NDS32_16_RELA. */
- case EM_ALTERA_NIOS2:
- return reloc_type == 13; /* R_NIOS2_BFD_RELOC_16. */
- case EM_NIOS32:
- return reloc_type == 9; /* R_NIOS_16. */
- case EM_OR1K:
- return reloc_type == 2; /* R_OR1K_16. */
- case EM_RISCV:
- return reloc_type == 55; /* R_RISCV_SET16. */
- case EM_TI_PRU:
- return reloc_type == 8; /* R_PRU_BFD_RELOC_16. */
- case EM_TI_C6000:
- return reloc_type == 2; /* R_C6000_ABS16. */
- case EM_VISIUM:
- return reloc_type == 2; /* R_VISIUM_16. */
- case EM_XGATE:
- return reloc_type == 3; /* R_XGATE_16. */
- case EM_Z80:
- return reloc_type == 4; /* R_Z80_16. */
- default:
- return false;
- }
-}
-
-/* Like is_32bit_abs_reloc except that it returns TRUE iff RELOC_TYPE is
- a 8-bit absolute RELA relocation used in DWARF debug sections. */
-
-static bool
-is_8bit_abs_reloc (Filedata * filedata, unsigned int reloc_type)
-{
- switch (filedata->file_header.e_machine)
- {
- case EM_RISCV:
- return reloc_type == 54; /* R_RISCV_SET8. */
- case EM_Z80:
- return reloc_type == 1; /* R_Z80_8. */
- case EM_MICROBLAZE:
- return (reloc_type == 33 /* R_MICROBLAZE_32_NONE. */
- || reloc_type == 0 /* R_MICROBLAZE_NONE. */
- || reloc_type == 9 /* R_MICROBLAZE_64_NONE. */);
- default:
- return false;
- }
-}
-
-/* Like is_32bit_abs_reloc except that it returns TRUE iff RELOC_TYPE is
- a 6-bit absolute RELA relocation used in DWARF debug sections. */
-
-static bool
-is_6bit_abs_reloc (Filedata * filedata, unsigned int reloc_type)
-{
- switch (filedata->file_header.e_machine)
- {
- case EM_RISCV:
- return reloc_type == 53; /* R_RISCV_SET6. */
- default:
- return false;
- }
-}
-
-/* Like is_32bit_abs_reloc except that it returns TRUE iff RELOC_TYPE is
- a 32-bit inplace add RELA relocation used in DWARF debug sections. */
-
-static bool
-is_32bit_inplace_add_reloc (Filedata * filedata, unsigned int reloc_type)
-{
- /* Please keep this table alpha-sorted for ease of visual lookup. */
- switch (filedata->file_header.e_machine)
- {
- case EM_LOONGARCH:
- return reloc_type == 50; /* R_LARCH_ADD32. */
- case EM_RISCV:
- return reloc_type == 35; /* R_RISCV_ADD32. */
- default:
- return false;
- }
-}
-
-/* Like is_32bit_abs_reloc except that it returns TRUE iff RELOC_TYPE is
- a 32-bit inplace sub RELA relocation used in DWARF debug sections. */
-
-static bool
-is_32bit_inplace_sub_reloc (Filedata * filedata, unsigned int reloc_type)
-{
- /* Please keep this table alpha-sorted for ease of visual lookup. */
- switch (filedata->file_header.e_machine)
- {
- case EM_LOONGARCH:
- return reloc_type == 55; /* R_LARCH_SUB32. */
- case EM_RISCV:
- return reloc_type == 39; /* R_RISCV_SUB32. */
- default:
- return false;
- }
-}
-
-/* Like is_32bit_abs_reloc except that it returns TRUE iff RELOC_TYPE is
- a 64-bit inplace add RELA relocation used in DWARF debug sections. */
-
-static bool
-is_64bit_inplace_add_reloc (Filedata * filedata, unsigned int reloc_type)
-{
- /* Please keep this table alpha-sorted for ease of visual lookup. */
- switch (filedata->file_header.e_machine)
- {
- case EM_LOONGARCH:
- return reloc_type == 51; /* R_LARCH_ADD64. */
- case EM_RISCV:
- return reloc_type == 36; /* R_RISCV_ADD64. */
- default:
- return false;
- }
-}
-
-/* Like is_32bit_abs_reloc except that it returns TRUE iff RELOC_TYPE is
- a 64-bit inplace sub RELA relocation used in DWARF debug sections. */
-
-static bool
-is_64bit_inplace_sub_reloc (Filedata * filedata, unsigned int reloc_type)
-{
- /* Please keep this table alpha-sorted for ease of visual lookup. */
- switch (filedata->file_header.e_machine)
- {
- case EM_LOONGARCH:
- return reloc_type == 56; /* R_LARCH_SUB64. */
- case EM_RISCV:
- return reloc_type == 40; /* R_RISCV_SUB64. */
- default:
- return false;
- }
-}
-
-/* Like is_32bit_abs_reloc except that it returns TRUE iff RELOC_TYPE is
- a 16-bit inplace add RELA relocation used in DWARF debug sections. */
-
-static bool
-is_16bit_inplace_add_reloc (Filedata * filedata, unsigned int reloc_type)
-{
- /* Please keep this table alpha-sorted for ease of visual lookup. */
- switch (filedata->file_header.e_machine)
- {
- case EM_LOONGARCH:
- return reloc_type == 48; /* R_LARCH_ADD16. */
- case EM_RISCV:
- return reloc_type == 34; /* R_RISCV_ADD16. */
- default:
- return false;
- }
-}
-
-/* Like is_32bit_abs_reloc except that it returns TRUE iff RELOC_TYPE is
- a 16-bit inplace sub RELA relocation used in DWARF debug sections. */
-
-static bool
-is_16bit_inplace_sub_reloc (Filedata * filedata, unsigned int reloc_type)
-{
- /* Please keep this table alpha-sorted for ease of visual lookup. */
- switch (filedata->file_header.e_machine)
- {
- case EM_LOONGARCH:
- return reloc_type == 53; /* R_LARCH_SUB16. */
- case EM_RISCV:
- return reloc_type == 38; /* R_RISCV_SUB16. */
- default:
- return false;
- }
-}
-
-/* Like is_32bit_abs_reloc except that it returns TRUE iff RELOC_TYPE is
- a 8-bit inplace add RELA relocation used in DWARF debug sections. */
-
-static bool
-is_8bit_inplace_add_reloc (Filedata * filedata, unsigned int reloc_type)
-{
- /* Please keep this table alpha-sorted for ease of visual lookup. */
- switch (filedata->file_header.e_machine)
- {
- case EM_LOONGARCH:
- return reloc_type == 47; /* R_LARCH_ADD8. */
- case EM_RISCV:
- return reloc_type == 33; /* R_RISCV_ADD8. */
- default:
- return false;
- }
-}
-
-/* Like is_32bit_abs_reloc except that it returns TRUE iff RELOC_TYPE is
- a 8-bit inplace sub RELA relocation used in DWARF debug sections. */
-
-static bool
-is_8bit_inplace_sub_reloc (Filedata * filedata, unsigned int reloc_type)
-{
- /* Please keep this table alpha-sorted for ease of visual lookup. */
- switch (filedata->file_header.e_machine)
- {
- case EM_LOONGARCH:
- return reloc_type == 52; /* R_LARCH_SUB8. */
- case EM_RISCV:
- return reloc_type == 37; /* R_RISCV_SUB8. */
- default:
- return false;
- }
-}
-
-/* Like is_32bit_abs_reloc except that it returns TRUE iff RELOC_TYPE is
- a 6-bit inplace add RELA relocation used in DWARF debug sections. */
-
-static bool
-is_6bit_inplace_add_reloc (Filedata * filedata, unsigned int reloc_type)
-{
- switch (filedata->file_header.e_machine)
- {
- case EM_LOONGARCH:
- return reloc_type == 105; /* R_LARCH_ADD6. */
- default:
- return false;
- }
-}
-
-/* Like is_32bit_abs_reloc except that it returns TRUE iff RELOC_TYPE is
- a 6-bit inplace sub RELA relocation used in DWARF debug sections. */
-
-static bool
-is_6bit_inplace_sub_reloc (Filedata * filedata, unsigned int reloc_type)
-{
- switch (filedata->file_header.e_machine)
- {
- case EM_LOONGARCH:
- return reloc_type == 106; /* R_LARCH_SUB6. */
- case EM_RISCV:
- return reloc_type == 52; /* R_RISCV_SUB6. */
- default:
- return false;
- }
-}
-
-/* Returns TRUE iff RELOC_TYPE is a NONE relocation used for discarded
- relocation entries (possibly formerly used for SHT_GROUP sections). */
-
-static bool
-is_none_reloc (Filedata * filedata, unsigned int reloc_type)
-{
- switch (filedata->file_header.e_machine)
- {
- case EM_386: /* R_386_NONE. */
- case EM_68K: /* R_68K_NONE. */
- case EM_ADAPTEVA_EPIPHANY:
- case EM_ALPHA: /* R_ALPHA_NONE. */
- case EM_ALTERA_NIOS2: /* R_NIOS2_NONE. */
- case EM_ARC: /* R_ARC_NONE. */
- case EM_ARC_COMPACT2: /* R_ARC_NONE. */
- case EM_ARC_COMPACT: /* R_ARC_NONE. */
- case EM_ARC_COMPACT3: /* R_ARC_NONE. */
- case EM_ARC_COMPACT3_64: /* R_ARC_NONE. */
- case EM_ARM: /* R_ARM_NONE. */
- case EM_CRIS: /* R_CRIS_NONE. */
- case EM_FT32: /* R_FT32_NONE. */
- case EM_IA_64: /* R_IA64_NONE. */
- case EM_K1OM: /* R_X86_64_NONE. */
- case EM_KVX: /* R_KVX_NONE. */
- case EM_L1OM: /* R_X86_64_NONE. */
- case EM_M32R: /* R_M32R_NONE. */
- case EM_MIPS: /* R_MIPS_NONE. */
- case EM_MN10300: /* R_MN10300_NONE. */
- case EM_MOXIE: /* R_MOXIE_NONE. */
- case EM_NIOS32: /* R_NIOS_NONE. */
- case EM_OR1K: /* R_OR1K_NONE. */
- case EM_PARISC: /* R_PARISC_NONE. */
- case EM_PPC64: /* R_PPC64_NONE. */
- case EM_PPC: /* R_PPC_NONE. */
- case EM_RISCV: /* R_RISCV_NONE. */
- case EM_S390: /* R_390_NONE. */
- case EM_S390_OLD:
- case EM_SH: /* R_SH_NONE. */
- case EM_SPARC32PLUS:
- case EM_SPARC: /* R_SPARC_NONE. */
- case EM_SPARCV9:
- case EM_TILEGX: /* R_TILEGX_NONE. */
- case EM_TILEPRO: /* R_TILEPRO_NONE. */
- case EM_TI_C6000:/* R_C6000_NONE. */
- case EM_X86_64: /* R_X86_64_NONE. */
- case EM_Z80: /* R_Z80_NONE. */
- case EM_WEBASSEMBLY: /* R_WASM32_NONE. */
- return reloc_type == 0;
-
- case EM_AARCH64:
- return reloc_type == 0 || reloc_type == 256;
- case EM_AVR_OLD:
- case EM_AVR:
- return (reloc_type == 0 /* R_AVR_NONE. */
- || reloc_type == 30 /* R_AVR_DIFF8. */
- || reloc_type == 31 /* R_AVR_DIFF16. */
- || reloc_type == 32 /* R_AVR_DIFF32. */);
- case EM_METAG:
- return reloc_type == 3; /* R_METAG_NONE. */
- case EM_NDS32:
- return (reloc_type == 0 /* R_NDS32_NONE. */
- || reloc_type == 205 /* R_NDS32_DIFF8. */
- || reloc_type == 206 /* R_NDS32_DIFF16. */
- || reloc_type == 207 /* R_NDS32_DIFF32. */
- || reloc_type == 208 /* R_NDS32_DIFF_ULEB128. */);
- case EM_TI_PRU:
- return (reloc_type == 0 /* R_PRU_NONE. */
- || reloc_type == 65 /* R_PRU_DIFF8. */
- || reloc_type == 66 /* R_PRU_DIFF16. */
- || reloc_type == 67 /* R_PRU_DIFF32. */);
- case EM_XTENSA_OLD:
- case EM_XTENSA:
- return (reloc_type == 0 /* R_XTENSA_NONE. */
- || reloc_type == 17 /* R_XTENSA_DIFF8. */
- || reloc_type == 18 /* R_XTENSA_DIFF16. */
- || reloc_type == 19 /* R_XTENSA_DIFF32. */
- || reloc_type == 57 /* R_XTENSA_PDIFF8. */
- || reloc_type == 58 /* R_XTENSA_PDIFF16. */
- || reloc_type == 59 /* R_XTENSA_PDIFF32. */
- || reloc_type == 60 /* R_XTENSA_NDIFF8. */
- || reloc_type == 61 /* R_XTENSA_NDIFF16. */
- || reloc_type == 62 /* R_XTENSA_NDIFF32. */);
- }
- return false;
-}
-
-/* Returns TRUE if there is a relocation against
- section NAME at OFFSET bytes. */
-
-bool
-reloc_at (struct dwarf_section * dsec, uint64_t offset)
-{
- Elf_Internal_Rela * relocs;
- Elf_Internal_Rela * rp;
-
- if (dsec == NULL || dsec->reloc_info == NULL)
- return false;
-
- relocs = (Elf_Internal_Rela *) dsec->reloc_info;
-
- for (rp = relocs; rp < relocs + dsec->num_relocs; ++rp)
- if (rp->r_offset == offset)
- return true;
-
- return false;
-}
-
-/* Apply relocations to a section.
- Returns TRUE upon success, FALSE otherwise.
- If RELOCS_RETURN is non-NULL then it is set to point to the loaded relocs.
- It is then the caller's responsibility to free them. NUM_RELOCS_RETURN
- will be set to the number of relocs loaded.
-
- Note: So far support has been added only for those relocations
- which can be found in debug sections. FIXME: Add support for
- more relocations ? */
-
-static bool
-apply_relocations (Filedata *filedata,
- const Elf_Internal_Shdr *section,
- unsigned char *start,
- size_t size,
- void **relocs_return,
- uint64_t *num_relocs_return)
-{
- Elf_Internal_Shdr * relsec;
- unsigned char * end = start + size;
-
- if (relocs_return != NULL)
- {
- * (Elf_Internal_Rela **) relocs_return = NULL;
- * num_relocs_return = 0;
- }
-
- if (filedata->file_header.e_type != ET_REL)
- /* No relocs to apply. */
- return true;
-
- /* Find the reloc section associated with the section. */
- for (relsec = filedata->section_headers;
- relsec < filedata->section_headers + filedata->file_header.e_shnum;
- ++relsec)
- {
- bool is_rela;
- uint64_t num_relocs;
- Elf_Internal_Rela * relocs;
- Elf_Internal_Rela * rp;
- Elf_Internal_Shdr * symsec;
- Elf_Internal_Sym * symtab;
- uint64_t num_syms;
- Elf_Internal_Sym * sym;
-
- if ((relsec->sh_type != SHT_RELA && relsec->sh_type != SHT_REL)
- || relsec->sh_info >= filedata->file_header.e_shnum
- || filedata->section_headers + relsec->sh_info != section
- || relsec->sh_size == 0
- || relsec->sh_link >= filedata->file_header.e_shnum)
- continue;
-
- symsec = filedata->section_headers + relsec->sh_link;
- if (symsec->sh_type != SHT_SYMTAB
- && symsec->sh_type != SHT_DYNSYM)
- return false;
-
- is_rela = relsec->sh_type == SHT_RELA;
-
- if (is_rela)
- {
- if (!slurp_rela_relocs (filedata, relsec->sh_offset,
- relsec->sh_size, & relocs, & num_relocs))
- return false;
- }
- else
- {
- if (!slurp_rel_relocs (filedata, relsec->sh_offset,
- relsec->sh_size, & relocs, & num_relocs))
- return false;
- }
-
- /* SH uses RELA but uses in place value instead of the addend field. */
- if (filedata->file_header.e_machine == EM_SH)
- is_rela = false;
-
- symtab = get_elf_symbols (filedata, symsec, & num_syms);
-
- for (rp = relocs; rp < relocs + num_relocs; ++rp)
- {
- uint64_t addend;
- unsigned int reloc_type;
- unsigned int reloc_size;
- bool reloc_inplace = false;
- bool reloc_subtract = false;
- unsigned char *rloc;
- uint64_t sym_index;
-
- reloc_type = get_reloc_type (filedata, rp->r_info);
-
- if (target_specific_reloc_handling (filedata, rp, start, end, symtab, num_syms))
- continue;
- else if (is_none_reloc (filedata, reloc_type))
- continue;
- else if (is_32bit_abs_reloc (filedata, reloc_type)
- || is_32bit_pcrel_reloc (filedata, reloc_type))
- reloc_size = 4;
- else if (is_64bit_abs_reloc (filedata, reloc_type)
- || is_64bit_pcrel_reloc (filedata, reloc_type))
- reloc_size = 8;
- else if (is_24bit_abs_reloc (filedata, reloc_type))
- reloc_size = 3;
- else if (is_16bit_abs_reloc (filedata, reloc_type))
- reloc_size = 2;
- else if (is_8bit_abs_reloc (filedata, reloc_type)
- || is_6bit_abs_reloc (filedata, reloc_type))
- reloc_size = 1;
- else if ((reloc_subtract = is_32bit_inplace_sub_reloc (filedata,
- reloc_type))
- || is_32bit_inplace_add_reloc (filedata, reloc_type))
- {
- reloc_size = 4;
- reloc_inplace = true;
- }
- else if ((reloc_subtract = is_64bit_inplace_sub_reloc (filedata,
- reloc_type))
- || is_64bit_inplace_add_reloc (filedata, reloc_type))
- {
- reloc_size = 8;
- reloc_inplace = true;
- }
- else if ((reloc_subtract = is_16bit_inplace_sub_reloc (filedata,
- reloc_type))
- || is_16bit_inplace_add_reloc (filedata, reloc_type))
- {
- reloc_size = 2;
- reloc_inplace = true;
- }
- else if ((reloc_subtract = is_8bit_inplace_sub_reloc (filedata,
- reloc_type))
- || is_8bit_inplace_add_reloc (filedata, reloc_type))
- {
- reloc_size = 1;
- reloc_inplace = true;
- }
- else if ((reloc_subtract = is_6bit_inplace_sub_reloc (filedata,
- reloc_type))
- || is_6bit_inplace_add_reloc (filedata, reloc_type))
- {
- reloc_size = 1;
- reloc_inplace = true;
- }
- else
- {
- static unsigned int prev_reloc = 0;
-
- if (reloc_type != prev_reloc)
- warn (_("unable to apply unsupported reloc type %d to section %s\n"),
- reloc_type, printable_section_name (filedata, section));
- prev_reloc = reloc_type;
- continue;
- }
-
- rloc = start + rp->r_offset;
- if (!IN_RANGE (start, end, rloc, reloc_size))
- {
- warn (_("skipping invalid relocation offset %#" PRIx64
- " in section %s\n"),
- rp->r_offset,
- printable_section_name (filedata, section));
- continue;
- }
-
- sym_index = get_reloc_symindex (rp->r_info);
- if (sym_index >= num_syms)
- {
- warn (_("skipping invalid relocation symbol index %#" PRIx64
- " in section %s\n"),
- sym_index, printable_section_name (filedata, section));
- continue;
- }
- sym = symtab + sym_index;
-
- /* If the reloc has a symbol associated with it,
- make sure that it is of an appropriate type.
-
- Relocations against symbols without type can happen.
- Gcc -feliminate-dwarf2-dups may generate symbols
- without type for debug info.
-
- Icc generates relocations against function symbols
- instead of local labels.
-
- Relocations against object symbols can happen, eg when
- referencing a global array. For an example of this see
- the _clz.o binary in libgcc.a. */
- if (sym != symtab
- && ELF_ST_TYPE (sym->st_info) != STT_COMMON
- && ELF_ST_TYPE (sym->st_info) > STT_SECTION)
- {
- warn (_("skipping unexpected symbol type %s in section %s relocation %tu\n"),
- get_symbol_type (filedata, ELF_ST_TYPE (sym->st_info)),
- printable_section_name (filedata, relsec),
- rp - relocs);
- continue;
- }
-
- addend = 0;
- if (is_rela)
- addend += rp->r_addend;
- /* R_XTENSA_32, R_PJ_DATA_DIR32 and R_D30V_32_NORMAL are
- partial_inplace. */
- if (!is_rela
- || (filedata->file_header.e_machine == EM_XTENSA
- && reloc_type == 1)
- || ((filedata->file_header.e_machine == EM_PJ
- || filedata->file_header.e_machine == EM_PJ_OLD)
- && reloc_type == 1)
- || ((filedata->file_header.e_machine == EM_D30V
- || filedata->file_header.e_machine == EM_CYGNUS_D30V)
- && reloc_type == 12)
- || reloc_inplace)
- {
- if (is_6bit_inplace_sub_reloc (filedata, reloc_type))
- addend += byte_get (rloc, reloc_size) & 0x3f;
- else
- addend += byte_get (rloc, reloc_size);
- }
-
- if (is_32bit_pcrel_reloc (filedata, reloc_type)
- || is_64bit_pcrel_reloc (filedata, reloc_type))
- {
- /* On HPPA, all pc-relative relocations are biased by 8. */
- if (filedata->file_header.e_machine == EM_PARISC)
- addend -= 8;
- byte_put (rloc, (addend + sym->st_value) - rp->r_offset,
- reloc_size);
- }
- else if (is_6bit_abs_reloc (filedata, reloc_type)
- || is_6bit_inplace_sub_reloc (filedata, reloc_type)
- || is_6bit_inplace_add_reloc (filedata, reloc_type))
- {
- if (reloc_subtract)
- addend -= sym->st_value;
- else
- addend += sym->st_value;
- addend = (addend & 0x3f) | (byte_get (rloc, reloc_size) & 0xc0);
- byte_put (rloc, addend, reloc_size);
- }
- else if (reloc_subtract)
- byte_put (rloc, addend - sym->st_value, reloc_size);
- else
- byte_put (rloc, addend + sym->st_value, reloc_size);
- }
-
- free (symtab);
- /* Let the target specific reloc processing code know that
- we have finished with these relocs. */
- target_specific_reloc_handling (filedata, NULL, NULL, NULL, NULL, 0);
-
- if (relocs_return)
- {
- * (Elf_Internal_Rela **) relocs_return = relocs;
- * num_relocs_return = num_relocs;
- }
- else
- free (relocs);
-
- break;
- }
-
- return true;
-}
-
-#ifdef SUPPORT_DISASSEMBLY
-static bool
-disassemble_section (Elf_Internal_Shdr * section, Filedata * filedata)
-{
- printf (_("\nAssembly dump of section %s\n"), printable_section_name (filedata, section));
-
- /* FIXME: XXX -- to be done --- XXX */
-
- return true;
-}
-#endif
-
-/* Reads in the contents of SECTION from FILE, returning a pointer
- to a malloc'ed buffer or NULL if something went wrong. */
-
-static char *
-get_section_contents (Elf_Internal_Shdr * section, Filedata * filedata)
-{
- uint64_t num_bytes = section->sh_size;
-
- if (num_bytes == 0 || section->sh_type == SHT_NOBITS)
- {
- printf (_("Section '%s' has no data to dump.\n"),
- printable_section_name (filedata, section));
- return NULL;
- }
-
- return (char *) get_data (NULL, filedata, section->sh_offset, 1, num_bytes,
- _("section contents"));
-}
-
-/* Uncompresses a section that was compressed using zlib/zstd, in place. */
-
-static bool
-uncompress_section_contents (bool is_zstd,
- unsigned char ** buffer,
- uint64_t uncompressed_size,
- uint64_t * size,
- uint64_t file_size)
-{
- uint64_t compressed_size = *size;
- unsigned char *compressed_buffer = *buffer;
- unsigned char *uncompressed_buffer = NULL;
- z_stream strm;
- int rc;
-
- /* Similar to bfd_section_size_insane() in the BFD library we expect an
- upper limit of ~10x compression. Any compression larger than that is
- thought to be due to fuzzing of the compression header. */
- if (uncompressed_size > file_size * 10)
- {
- error (_("Uncompressed section size is suspiciously large: 0x%" PRIu64 "\n"),
- uncompressed_size);
- goto fail;
- }
-
- uncompressed_buffer = xmalloc (uncompressed_size);
-
- if (is_zstd)
- {
-#ifdef HAVE_ZSTD
- size_t ret = ZSTD_decompress (uncompressed_buffer, uncompressed_size,
- compressed_buffer, compressed_size);
- if (ZSTD_isError (ret))
- goto fail;
-#endif
- }
- else
- {
- /* It is possible the section consists of several compressed
- buffers concatenated together, so we uncompress in a loop. */
- /* PR 18313: The state field in the z_stream structure is supposed
- to be invisible to the user (ie us), but some compilers will
- still complain about it being used without initialisation. So
- we first zero the entire z_stream structure and then set the fields
- that we need. */
- memset (&strm, 0, sizeof strm);
- strm.avail_in = compressed_size;
- strm.next_in = (Bytef *)compressed_buffer;
- strm.avail_out = uncompressed_size;
-
- rc = inflateInit (&strm);
- while (strm.avail_in > 0)
- {
- if (rc != Z_OK)
- break;
- strm.next_out = ((Bytef *)uncompressed_buffer
- + (uncompressed_size - strm.avail_out));
- rc = inflate (&strm, Z_FINISH);
- if (rc != Z_STREAM_END)
- break;
- rc = inflateReset (&strm);
- }
- if (inflateEnd (&strm) != Z_OK || rc != Z_OK || strm.avail_out != 0)
- goto fail;
- }
-
- *buffer = uncompressed_buffer;
- *size = uncompressed_size;
- return true;
-
- fail:
- free (uncompressed_buffer);
- /* Indicate decompression failure. */
- *buffer = NULL;
- return false;
-}
-
-static uint64_t
-maybe_expand_or_relocate_section (Elf_Internal_Shdr * section,
- Filedata * filedata,
- unsigned char ** start_ptr,
- bool relocate)
-{
- uint64_t section_size = section->sh_size;
- unsigned char * start = * start_ptr;
-
- if (decompress_dumps)
- {
- uint64_t new_size = section_size;
- uint64_t uncompressed_size = 0;
- bool is_zstd = false;
-
- if ((section->sh_flags & SHF_COMPRESSED) != 0)
- {
- Elf_Internal_Chdr chdr;
- unsigned int compression_header_size
- = get_compression_header (& chdr, start, section_size);
-
- if (compression_header_size == 0)
- /* An error message will have already been generated
- by get_compression_header. */
- return (uint64_t) -1;
-
- if (chdr.ch_type == ch_compress_zlib)
- ;
-#ifdef HAVE_ZSTD
- else if (chdr.ch_type == ch_compress_zstd)
- is_zstd = true;
-#endif
- else
- {
- warn (_("section '%s' has unsupported compress type: %d\n"),
- printable_section_name (filedata, section), chdr.ch_type);
- return (uint64_t) -1;
- }
-
- uncompressed_size = chdr.ch_size;
- start += compression_header_size;
- new_size -= compression_header_size;
- }
- else if (new_size > 12 && streq ((char *) start, "ZLIB"))
- {
- /* Read the zlib header. In this case, it should be "ZLIB"
- followed by the uncompressed section size, 8 bytes in
- big-endian order. */
- uncompressed_size = start[4]; uncompressed_size <<= 8;
- uncompressed_size += start[5]; uncompressed_size <<= 8;
- uncompressed_size += start[6]; uncompressed_size <<= 8;
- uncompressed_size += start[7]; uncompressed_size <<= 8;
- uncompressed_size += start[8]; uncompressed_size <<= 8;
- uncompressed_size += start[9]; uncompressed_size <<= 8;
- uncompressed_size += start[10]; uncompressed_size <<= 8;
- uncompressed_size += start[11];
- start += 12;
- new_size -= 12;
- }
-
- if (uncompressed_size)
- {
- if (uncompress_section_contents (is_zstd, &start, uncompressed_size,
- &new_size, filedata->file_size))
- section_size = new_size;
- else
- {
- error (_("Unable to decompress section %s\n"),
- printable_section_name (filedata, section));
- return (uint64_t) -1;
- }
- }
- else
- start = * start_ptr;
- }
- else if (((section->sh_flags & SHF_COMPRESSED) != 0)
- || (section_size > 12 && streq ((char *) start, "ZLIB")))
- {
- printf (_(" NOTE: This section is compressed, but its contents have NOT been expanded for this dump.\n"));
- }
-
- if (relocate)
- {
- if (! apply_relocations (filedata, section, start, section_size, NULL, NULL))
- return (uint64_t) -1;
- }
- else
- {
- Elf_Internal_Shdr *relsec;
-
- /* If the section being dumped has relocations against it the user might
- be expecting these relocations to have been applied. Check for this
- case and issue a warning message in order to avoid confusion.
- FIXME: Maybe we ought to have an option that dumps a section with
- relocs applied ? */
- for (relsec = filedata->section_headers;
- relsec < filedata->section_headers + filedata->file_header.e_shnum;
- ++relsec)
- {
- if ((relsec->sh_type != SHT_RELA && relsec->sh_type != SHT_REL)
- || relsec->sh_info >= filedata->file_header.e_shnum
- || filedata->section_headers + relsec->sh_info != section
- || relsec->sh_size == 0
- || relsec->sh_link >= filedata->file_header.e_shnum)
- continue;
-
- printf (_(" NOTE: This section has relocations against it, but these have NOT been applied to this dump.\n"));
- break;
- }
- }
-
- * start_ptr = start;
- return section_size;
-}
-
-static bool
-dump_section_as_strings (Elf_Internal_Shdr * section, Filedata * filedata)
-{
- uint64_t num_bytes;
- unsigned char *data;
- unsigned char *end;
- unsigned char *real_start;
- unsigned char *start;
- bool some_strings_shown;
-
- real_start = start = (unsigned char *) get_section_contents (section, filedata);
- if (start == NULL)
- /* PR 21820: Do not fail if the section was empty. */
- return section->sh_size == 0 || section->sh_type == SHT_NOBITS;
-
- num_bytes = section->sh_size;
-
- if (filedata->is_separate)
- printf (_("\nString dump of section '%s' in linked file %s:\n"),
- printable_section_name (filedata, section),
- filedata->file_name);
- else
- printf (_("\nString dump of section '%s':\n"),
- printable_section_name (filedata, section));
-
- num_bytes = maybe_expand_or_relocate_section (section, filedata, & start, false);
- if (num_bytes == (uint64_t) -1)
- goto error_out;
-
- data = start;
- end = start + num_bytes;
- some_strings_shown = false;
-
-#ifdef HAVE_MBSTATE_T
- mbstate_t state;
- /* Initialise the multibyte conversion state. */
- memset (& state, 0, sizeof (state));
-#endif
-
- bool continuing = false;
-
- while (data < end)
- {
- while (!ISPRINT (* data))
- if (++ data >= end)
- break;
-
- if (data < end)
- {
- size_t maxlen = end - data;
-
- if (continuing)
- {
- printf (" ");
- continuing = false;
- }
- else
- {
- printf (" [%6tx] ", data - start);
- }
-
- if (maxlen > 0)
- {
- char c = 0;
-
- while (maxlen)
- {
- c = *data++;
-
- if (c == 0)
- break;
-
- /* PR 25543: Treat new-lines as string-ending characters. */
- if (c == '\n')
- {
- printf ("\\n\n");
- if (*data != 0)
- continuing = true;
- break;
- }
-
- /* Do not print control characters directly as they can affect terminal
- settings. Such characters usually appear in the names generated
- by the assembler for local labels. */
- if (ISCNTRL (c))
- {
- printf ("^%c", c + 0x40);
- }
- else if (ISPRINT (c))
- {
- putchar (c);
- }
- else
- {
- size_t n;
-#ifdef HAVE_MBSTATE_T
- wchar_t w;
-#endif
- /* Let printf do the hard work of displaying multibyte characters. */
- printf ("%.1s", data - 1);
-#ifdef HAVE_MBSTATE_T
- /* Try to find out how many bytes made up the character that was
- just printed. Advance the symbol pointer past the bytes that
- were displayed. */
- n = mbrtowc (& w, (char *)(data - 1), MB_CUR_MAX, & state);
-#else
- n = 1;
-#endif
- if (n != (size_t) -1 && n != (size_t) -2 && n > 0)
- data += (n - 1);
- }
- }
-
- if (c != '\n')
- putchar ('\n');
- }
- else
- {
- printf (_("<corrupt>\n"));
- data = end;
- }
- some_strings_shown = true;
- }
- }
-
- if (! some_strings_shown)
- printf (_(" No strings found in this section."));
-
- free (real_start);
-
- putchar ('\n');
- return true;
-
-error_out:
- free (real_start);
- return false;
-}
-
-static bool
-dump_section_as_bytes (Elf_Internal_Shdr *section,
- Filedata *filedata,
- bool relocate)
-{
- size_t bytes;
- uint64_t section_size;
- uint64_t addr;
- unsigned char *data;
- unsigned char *real_start;
- unsigned char *start;
-
- real_start = start = (unsigned char *) get_section_contents (section, filedata);
- if (start == NULL)
- /* PR 21820: Do not fail if the section was empty. */
- return section->sh_size == 0 || section->sh_type == SHT_NOBITS;
-
- section_size = section->sh_size;
-
- if (filedata->is_separate)
- printf (_("\nHex dump of section '%s' in linked file %s:\n"),
- printable_section_name (filedata, section),
- filedata->file_name);
- else
- printf (_("\nHex dump of section '%s':\n"),
- printable_section_name (filedata, section));
-
- section_size = maybe_expand_or_relocate_section (section, filedata, & start, relocate);
- if (section_size == (uint64_t) -1)
- goto error_out;
-
- addr = section->sh_addr;
- bytes = section_size;
- data = start;
-
- while (bytes)
- {
- int j;
- int k;
- int lbytes;
-
- lbytes = (bytes > 16 ? 16 : bytes);
-
- printf (" 0x%8.8" PRIx64 " ", addr);
-
- for (j = 0; j < 16; j++)
- {
- if (j < lbytes)
- printf ("%2.2x", data[j]);
- else
- printf (" ");
-
- if ((j & 3) == 3)
- printf (" ");
- }
-
- for (j = 0; j < lbytes; j++)
- {
- k = data[j];
- if (k >= ' ' && k < 0x7f)
- printf ("%c", k);
- else
- printf (".");
- }
-
- putchar ('\n');
-
- data += lbytes;
- addr += lbytes;
- bytes -= lbytes;
- }
-
- free (real_start);
-
- putchar ('\n');
- return true;
-
- error_out:
- free (real_start);
- return false;
-}
-
-#ifdef ENABLE_LIBCTF
-static ctf_sect_t *
-shdr_to_ctf_sect (ctf_sect_t *buf, Elf_Internal_Shdr *shdr, Filedata *filedata)
-{
- buf->cts_name = printable_section_name (filedata, shdr);
- buf->cts_size = shdr->sh_size;
- buf->cts_entsize = shdr->sh_entsize;
-
- return buf;
-}
-
-/* Formatting callback function passed to ctf_dump. Returns either the pointer
- it is passed, or a pointer to newly-allocated storage, in which case
- dump_ctf() will free it when it no longer needs it. */
-
-static char *
-dump_ctf_indent_lines (ctf_sect_names_t sect ATTRIBUTE_UNUSED,
- char *s, void *arg)
-{
- const char *blanks = arg;
- char *new_s;
-
- if (asprintf (&new_s, "%s%s", blanks, s) < 0)
- return s;
- return new_s;
-}
-
-/* Dump CTF errors/warnings. */
-static void
-dump_ctf_errs (ctf_dict_t *fp)
-{
- ctf_next_t *it = NULL;
- char *errtext;
- int is_warning;
- int err;
-
- /* Dump accumulated errors and warnings. */
- while ((errtext = ctf_errwarning_next (fp, &it, &is_warning, &err)) != NULL)
- {
- error (_("%s: %s"), is_warning ? _("warning"): _("error"),
- errtext);
- free (errtext);
- }
- if (err != ECTF_NEXT_END)
- error (_("CTF error: cannot get CTF errors: `%s'"), ctf_errmsg (err));
-}
-
-/* Dump one CTF archive member. */
-
-static void
-dump_ctf_archive_member (ctf_dict_t *ctf, const char *name, ctf_dict_t *parent,
- size_t member)
-{
- const char *things[] = {"Header", "Labels", "Data objects",
- "Function objects", "Variables", "Types", "Strings",
- ""};
- const char **thing;
- size_t i;
-
- /* Don't print out the name of the default-named archive member if it appears
- first in the list. The name .ctf appears everywhere, even for things that
- aren't really archives, so printing it out is liable to be confusing; also,
- the common case by far is for only one archive member to exist, and hiding
- it in that case seems worthwhile. */
-
- if (strcmp (name, ".ctf") != 0 || member != 0)
- printf (_("\nCTF archive member: %s:\n"), name);
-
- if (ctf_parent_name (ctf) != NULL)
- ctf_import (ctf, parent);
-
- for (i = 0, thing = things; *thing[0]; thing++, i++)
- {
- ctf_dump_state_t *s = NULL;
- char *item;
-
- printf ("\n %s:\n", *thing);
- while ((item = ctf_dump (ctf, &s, i, dump_ctf_indent_lines,
- (void *) " ")) != NULL)
- {
- printf ("%s\n", item);
- free (item);
- }
-
- if (ctf_errno (ctf))
- {
- error (_("Iteration failed: %s, %s\n"), *thing,
- ctf_errmsg (ctf_errno (ctf)));
- break;
- }
- }
-
- dump_ctf_errs (ctf);
-}
-
-static bool
-dump_section_as_ctf (Elf_Internal_Shdr * section, Filedata * filedata)
-{
- Elf_Internal_Shdr * symtab_sec = NULL;
- Elf_Internal_Shdr * strtab_sec = NULL;
- void * data = NULL;
- void * symdata = NULL;
- void * strdata = NULL;
- ctf_sect_t ctfsect, symsect, strsect;
- ctf_sect_t * symsectp = NULL;
- ctf_sect_t * strsectp = NULL;
- ctf_archive_t * ctfa = NULL;
- ctf_dict_t * parent = NULL;
- ctf_dict_t * fp;
-
- ctf_next_t *i = NULL;
- const char *name;
- size_t member = 0;
- int err;
- bool ret = false;
-
- shdr_to_ctf_sect (&ctfsect, section, filedata);
- data = get_section_contents (section, filedata);
- ctfsect.cts_data = data;
-
- if (!dump_ctf_symtab_name)
- dump_ctf_symtab_name = strdup (".dynsym");
-
- if (!dump_ctf_strtab_name)
- dump_ctf_strtab_name = strdup (".dynstr");
-
- if (dump_ctf_symtab_name && dump_ctf_symtab_name[0] != 0)
- {
- if ((symtab_sec = find_section (filedata, dump_ctf_symtab_name)) == NULL)
- {
- error (_("No symbol section named %s\n"), dump_ctf_symtab_name);
- goto fail;
- }
- if ((symdata = (void *) get_data (NULL, filedata,
- symtab_sec->sh_offset, 1,
- symtab_sec->sh_size,
- _("symbols"))) == NULL)
- goto fail;
- symsectp = shdr_to_ctf_sect (&symsect, symtab_sec, filedata);
- symsect.cts_data = symdata;
- }
-
- if (dump_ctf_strtab_name && dump_ctf_strtab_name[0] != 0)
- {
- if ((strtab_sec = find_section (filedata, dump_ctf_strtab_name)) == NULL)
- {
- error (_("No string table section named %s\n"),
- dump_ctf_strtab_name);
- goto fail;
- }
- if ((strdata = (void *) get_data (NULL, filedata,
- strtab_sec->sh_offset, 1,
- strtab_sec->sh_size,
- _("strings"))) == NULL)
- goto fail;
- strsectp = shdr_to_ctf_sect (&strsect, strtab_sec, filedata);
- strsect.cts_data = strdata;
- }
-
- /* Load the CTF file and dump it. It may be a raw CTF section, or an archive:
- libctf papers over the difference, so we can pretend it is always an
- archive. */
-
- if ((ctfa = ctf_arc_bufopen (&ctfsect, symsectp, strsectp, &err)) == NULL)
- {
- dump_ctf_errs (NULL);
- error (_("CTF open failure: %s\n"), ctf_errmsg (err));
- goto fail;
- }
-
- ctf_arc_symsect_endianness (ctfa, filedata->file_header.e_ident[EI_DATA]
- != ELFDATA2MSB);
-
- /* Preload the parent dict, since it will need to be imported into every
- child in turn. */
- if ((parent = ctf_dict_open (ctfa, dump_ctf_parent_name, &err)) == NULL)
- {
- dump_ctf_errs (NULL);
- error (_("CTF open failure: %s\n"), ctf_errmsg (err));
- goto fail;
- }
-
- ret = true;
-
- if (filedata->is_separate)
- printf (_("\nDump of CTF section '%s' in linked file %s:\n"),
- printable_section_name (filedata, section),
- filedata->file_name);
- else
- printf (_("\nDump of CTF section '%s':\n"),
- printable_section_name (filedata, section));
-
- while ((fp = ctf_archive_next (ctfa, &i, &name, 0, &err)) != NULL)
- dump_ctf_archive_member (fp, name, parent, member++);
- if (err != ECTF_NEXT_END)
- {
- dump_ctf_errs (NULL);
- error (_("CTF member open failure: %s\n"), ctf_errmsg (err));
- ret = false;
- }
-
- fail:
- ctf_dict_close (parent);
- ctf_close (ctfa);
- free (data);
- free (symdata);
- free (strdata);
- return ret;
-}
-#endif
-
-static bool
-dump_section_as_sframe (Elf_Internal_Shdr * section, Filedata * filedata)
-{
- void * data = NULL;
- sframe_decoder_ctx *sfd_ctx = NULL;
- const char *print_name = printable_section_name (filedata, section);
-
- bool ret = true;
- size_t sf_size;
- int err = 0;
-
- if (strcmp (print_name, "") == 0)
- {
- error (_("Section name must be provided \n"));
- ret = false;
- return ret;
- }
-
- data = get_section_contents (section, filedata);
- sf_size = section->sh_size;
- /* Decode the contents of the section. */
- sfd_ctx = sframe_decode ((const char*)data, sf_size, &err);
- if (!sfd_ctx)
- {
- ret = false;
- error (_("SFrame decode failure: %s\n"), sframe_errmsg (err));
- goto fail;
- }
-
- printf (_("Contents of the SFrame section %s:"), print_name);
- /* Dump the contents as text. */
- dump_sframe (sfd_ctx, section->sh_addr);
-
- fail:
- free (data);
- return ret;
-}
-
-static bool
-load_specific_debug_section (enum dwarf_section_display_enum debug,
- const Elf_Internal_Shdr * sec,
- void * data)
-{
- struct dwarf_section * section = &debug_displays [debug].section;
- char buf [64];
- Filedata * filedata = (Filedata *) data;
-
- if (section->start != NULL)
- {
- /* If it is already loaded, do nothing. */
- if (streq (section->filename, filedata->file_name))
- return true;
- free (section->start);
- }
-
- snprintf (buf, sizeof (buf), _("%s section data"), section->name);
- section->address = sec->sh_addr;
- section->filename = filedata->file_name;
- section->start = (unsigned char *) get_data (NULL, filedata,
- sec->sh_offset, 1,
- sec->sh_size, buf);
- if (section->start == NULL)
- section->size = 0;
- else
- {
- unsigned char *start = section->start;
- uint64_t size = sec->sh_size;
- uint64_t uncompressed_size = 0;
- bool is_zstd = false;
-
- if ((sec->sh_flags & SHF_COMPRESSED) != 0)
- {
- Elf_Internal_Chdr chdr;
- unsigned int compression_header_size;
-
- if (size < (is_32bit_elf
- ? sizeof (Elf32_External_Chdr)
- : sizeof (Elf64_External_Chdr)))
- {
- warn (_("compressed section %s is too small to contain a compression header\n"),
- section->name);
- return false;
- }
-
- compression_header_size = get_compression_header (&chdr, start, size);
- if (compression_header_size == 0)
- /* An error message will have already been generated
- by get_compression_header. */
- return false;
-
- if (chdr.ch_type == ch_compress_zlib)
- ;
-#ifdef HAVE_ZSTD
- else if (chdr.ch_type == ch_compress_zstd)
- is_zstd = true;
-#endif
- else
- {
- warn (_("section '%s' has unsupported compress type: %d\n"),
- section->name, chdr.ch_type);
- return false;
- }
- uncompressed_size = chdr.ch_size;
- start += compression_header_size;
- size -= compression_header_size;
- }
- else if (size > 12 && streq ((char *) start, "ZLIB"))
- {
- /* Read the zlib header. In this case, it should be "ZLIB"
- followed by the uncompressed section size, 8 bytes in
- big-endian order. */
- uncompressed_size = start[4]; uncompressed_size <<= 8;
- uncompressed_size += start[5]; uncompressed_size <<= 8;
- uncompressed_size += start[6]; uncompressed_size <<= 8;
- uncompressed_size += start[7]; uncompressed_size <<= 8;
- uncompressed_size += start[8]; uncompressed_size <<= 8;
- uncompressed_size += start[9]; uncompressed_size <<= 8;
- uncompressed_size += start[10]; uncompressed_size <<= 8;
- uncompressed_size += start[11];
- start += 12;
- size -= 12;
- }
-
- if (uncompressed_size)
- {
- if (uncompress_section_contents (is_zstd, &start, uncompressed_size,
- &size, filedata->file_size))
- {
- /* Free the compressed buffer, update the section buffer
- and the section size if uncompress is successful. */
- free (section->start);
- section->start = start;
- }
- else
- {
- error (_("Unable to decompress section %s\n"),
- printable_section_name (filedata, sec));
- return false;
- }
- }
-
- section->size = size;
- }
-
- if (section->start == NULL)
- return false;
-
- if (debug_displays [debug].relocate)
- {
- if (! apply_relocations (filedata, sec, section->start, section->size,
- & section->reloc_info, & section->num_relocs))
- return false;
- }
- else
- {
- section->reloc_info = NULL;
- section->num_relocs = 0;
- }
-
- return true;
-}
-
-#if HAVE_LIBDEBUGINFOD
-/* Return a hex string representation of the build-id. */
-unsigned char *
-get_build_id (void * data)
-{
- Filedata * filedata = (Filedata *) data;
- Elf_Internal_Shdr * shdr;
- size_t i;
-
- /* Iterate through notes to find note.gnu.build-id.
- FIXME: Only the first note in any note section is examined. */
- for (i = 0, shdr = filedata->section_headers;
- i < filedata->file_header.e_shnum && shdr != NULL;
- i++, shdr++)
- {
- if (shdr->sh_type != SHT_NOTE)
- continue;
-
- char * next;
- char * end;
- size_t data_remaining;
- size_t min_notesz;
- Elf_External_Note * enote;
- Elf_Internal_Note inote;
-
- uint64_t offset = shdr->sh_offset;
- uint64_t align = shdr->sh_addralign;
- uint64_t length = shdr->sh_size;
-
- enote = (Elf_External_Note *) get_section_contents (shdr, filedata);
- if (enote == NULL)
- continue;
-
- if (align < 4)
- align = 4;
- else if (align != 4 && align != 8)
- {
- free (enote);
- continue;
- }
-
- end = (char *) enote + length;
- data_remaining = end - (char *) enote;
-
- if (!is_ia64_vms (filedata))
- {
- min_notesz = offsetof (Elf_External_Note, name);
- if (data_remaining < min_notesz)
- {
- warn (_("\
-malformed note encountered in section %s whilst scanning for build-id note\n"),
- printable_section_name (filedata, shdr));
- free (enote);
- continue;
- }
- data_remaining -= min_notesz;
-
- inote.type = BYTE_GET (enote->type);
- inote.namesz = BYTE_GET (enote->namesz);
- inote.namedata = enote->name;
- inote.descsz = BYTE_GET (enote->descsz);
- inote.descdata = ((char *) enote
- + ELF_NOTE_DESC_OFFSET (inote.namesz, align));
- inote.descpos = offset + (inote.descdata - (char *) enote);
- next = ((char *) enote
- + ELF_NOTE_NEXT_OFFSET (inote.namesz, inote.descsz, align));
- }
- else
- {
- Elf64_External_VMS_Note *vms_enote;
-
- /* PR binutils/15191
- Make sure that there is enough data to read. */
- min_notesz = offsetof (Elf64_External_VMS_Note, name);
- if (data_remaining < min_notesz)
- {
- warn (_("\
-malformed note encountered in section %s whilst scanning for build-id note\n"),
- printable_section_name (filedata, shdr));
- free (enote);
- continue;
- }
- data_remaining -= min_notesz;
-
- vms_enote = (Elf64_External_VMS_Note *) enote;
- inote.type = BYTE_GET (vms_enote->type);
- inote.namesz = BYTE_GET (vms_enote->namesz);
- inote.namedata = vms_enote->name;
- inote.descsz = BYTE_GET (vms_enote->descsz);
- inote.descdata = inote.namedata + align_power (inote.namesz, 3);
- inote.descpos = offset + (inote.descdata - (char *) enote);
- next = inote.descdata + align_power (inote.descsz, 3);
- }
-
- /* Skip malformed notes. */
- if ((size_t) (inote.descdata - inote.namedata) < inote.namesz
- || (size_t) (inote.descdata - inote.namedata) > data_remaining
- || (size_t) (next - inote.descdata) < inote.descsz
- || ((size_t) (next - inote.descdata)
- > data_remaining - (size_t) (inote.descdata - inote.namedata)))
- {
- warn (_("\
-malformed note encountered in section %s whilst scanning for build-id note\n"),
- printable_section_name (filedata, shdr));
- free (enote);
- continue;
- }
-
- /* Check if this is the build-id note. If so then convert the build-id
- bytes to a hex string. */
- if (inote.namesz > 0
- && startswith (inote.namedata, "GNU")
- && inote.type == NT_GNU_BUILD_ID)
- {
- size_t j;
- char * build_id;
-
- build_id = malloc (inote.descsz * 2 + 1);
- if (build_id == NULL)
- {
- free (enote);
- return NULL;
- }
-
- for (j = 0; j < inote.descsz; ++j)
- sprintf (build_id + (j * 2), "%02x", inote.descdata[j] & 0xff);
- build_id[inote.descsz * 2] = '\0';
- free (enote);
-
- return (unsigned char *) build_id;
- }
- free (enote);
- }
-
- return NULL;
-}
-#endif /* HAVE_LIBDEBUGINFOD */
-
-/* If this is not NULL, load_debug_section will only look for sections
- within the list of sections given here. */
-static unsigned int * section_subset = NULL;
-
-bool
-load_debug_section (enum dwarf_section_display_enum debug, void * data)
-{
- struct dwarf_section * section = &debug_displays [debug].section;
- Elf_Internal_Shdr * sec;
- Filedata * filedata = (Filedata *) data;
-
- if (!dump_any_debugging)
- return false;
-
- /* Without section headers we cannot find any sections. */
- if (filedata->section_headers == NULL)
- return false;
-
- if (filedata->string_table == NULL
- && filedata->file_header.e_shstrndx != SHN_UNDEF
- && filedata->file_header.e_shstrndx < filedata->file_header.e_shnum)
- {
- Elf_Internal_Shdr * strs;
-
- /* Read in the string table, so that we have section names to scan. */
- strs = filedata->section_headers + filedata->file_header.e_shstrndx;
-
- if (strs != NULL && strs->sh_size != 0)
- {
- filedata->string_table
- = (char *) get_data (NULL, filedata, strs->sh_offset,
- 1, strs->sh_size, _("string table"));
-
- filedata->string_table_length
- = filedata->string_table != NULL ? strs->sh_size : 0;
- }
- }
-
- /* Locate the debug section. */
- sec = find_section_in_set (filedata, section->uncompressed_name, section_subset);
- if (sec != NULL)
- section->name = section->uncompressed_name;
- else
- {
- sec = find_section_in_set (filedata, section->compressed_name, section_subset);
- if (sec != NULL)
- section->name = section->compressed_name;
- }
- if (sec == NULL)
- return false;
-
- /* If we're loading from a subset of sections, and we've loaded
- a section matching this name before, it's likely that it's a
- different one. */
- if (section_subset != NULL)
- free_debug_section (debug);
-
- return load_specific_debug_section (debug, sec, data);
-}
-
-void
-free_debug_section (enum dwarf_section_display_enum debug)
-{
- struct dwarf_section * section = &debug_displays [debug].section;
-
- if (section->start == NULL)
- return;
-
- free ((char *) section->start);
- section->start = NULL;
- section->address = 0;
- section->size = 0;
-
- free (section->reloc_info);
- section->reloc_info = NULL;
- section->num_relocs = 0;
-}
-
-static bool
-display_debug_section (int shndx, Elf_Internal_Shdr * section, Filedata * filedata)
-{
- const char *name = (section_name_valid (filedata, section)
- ? section_name (filedata, section) : "");
- const char *print_name = printable_section_name (filedata, section);
- uint64_t length;
- bool result = true;
- int i;
-
- length = section->sh_size;
- if (length == 0)
- {
- printf (_("\nSection '%s' has no debugging data.\n"), print_name);
- return true;
- }
- if (section->sh_type == SHT_NOBITS)
- {
- /* There is no point in dumping the contents of a debugging section
- which has the NOBITS type - the bits in the file will be random.
- This can happen when a file containing a .eh_frame section is
- stripped with the --only-keep-debug command line option. */
- printf (_("section '%s' has the NOBITS type - its contents are unreliable.\n"),
- print_name);
- return false;
- }
-
- if (startswith (name, ".gnu.linkonce.wi."))
- name = ".debug_info";
-
- /* See if we know how to display the contents of this section. */
- for (i = 0; i < max; i++)
- {
- enum dwarf_section_display_enum id = (enum dwarf_section_display_enum) i;
- struct dwarf_section_display * display = debug_displays + i;
- struct dwarf_section * sec = & display->section;
-
- if (streq (sec->uncompressed_name, name)
- || (id == line && startswith (name, ".debug_line."))
- || streq (sec->compressed_name, name))
- {
- bool secondary = (section != find_section (filedata, name));
-
- if (secondary)
- free_debug_section (id);
-
- if (i == line && startswith (name, ".debug_line."))
- sec->name = name;
- else if (streq (sec->uncompressed_name, name))
- sec->name = sec->uncompressed_name;
- else
- sec->name = sec->compressed_name;
-
- if (load_specific_debug_section (id, section, filedata))
- {
- /* If this debug section is part of a CU/TU set in a .dwp file,
- restrict load_debug_section to the sections in that set. */
- section_subset = find_cu_tu_set (filedata, shndx);
-
- result &= display->display (sec, filedata);
-
- section_subset = NULL;
-
- if (secondary || (id != info && id != abbrev && id != debug_addr))
- free_debug_section (id);
- }
- break;
- }
- }
-
- if (i == max)
- {
- printf (_("Unrecognized debug section: %s\n"), print_name);
- result = false;
- }
-
- return result;
-}
-
-/* Set DUMP_SECTS for all sections where dumps were requested
- based on section name. */
-
-static void
-initialise_dumps_byname (Filedata * filedata)
-{
- struct dump_list_entry * cur;
-
- for (cur = dump_sects_byname; cur; cur = cur->next)
- {
- unsigned int i;
- bool any = false;
-
- for (i = 0; i < filedata->file_header.e_shnum; i++)
- if (section_name_valid (filedata, filedata->section_headers + i)
- && streq (section_name (filedata, filedata->section_headers + i),
- cur->name))
- {
- request_dump_bynumber (&filedata->dump, i, cur->type);
- any = true;
- }
-
- if (!any && !filedata->is_separate)
- warn (_("Section '%s' was not dumped because it does not exist\n"),
- cur->name);
- }
-}
-
-static bool
-process_section_contents (Filedata * filedata)
-{
- Elf_Internal_Shdr * section;
- unsigned int i;
- bool res = true;
-
- if (! do_dump)
- return true;
-
- initialise_dumps_byname (filedata);
-
- for (i = 0, section = filedata->section_headers;
- i < filedata->file_header.e_shnum && i < filedata->dump.num_dump_sects;
- i++, section++)
- {
- dump_type dump = filedata->dump.dump_sects[i];
-
- if (filedata->is_separate && ! process_links)
- dump &= DEBUG_DUMP;
-
- if (dump & AUTO_DUMP)
- {
- switch (section->sh_type)
- {
- case SHT_PROGBITS:
- /* FIXME: There are lots of different type of section that have
- SHT_PROGBITS set in their header - code, debug info, etc. So
- we should check the section's name and interpret its contents
- that way, rather than just defaulting to a byte dump. */
-#ifdef SUPPORT_DISASSEMBLY
- res &= disassemble_section (section, filedata);
-#else
- res &= dump_section_as_bytes (section, filedata, false);
-#endif
- break;
-
- case SHT_DYNSYM:
- case SHT_SYMTAB:
- res &= dump_symbol_section (section, filedata);
- break;
-
- case SHT_STRTAB:
- res &= dump_section_as_strings (section, filedata);
- break;
-
- case SHT_RELA:
- case SHT_REL:
- case SHT_RELR:
- res &= display_relocations (section, filedata);
- break;
-
- case SHT_NOTE:
- res &= process_notes_at (filedata, section, section->sh_offset,
- section->sh_size, section->sh_addralign);
- break;
-
- case SHT_NULL:
- inform (_("Unable to display section %d - it has a NULL type\n"), i);
- break;
-
- case SHT_NOBITS:
- inform (_("Unable to display section %d - it has no contents\n"), i);
- break;
-
- case SHT_HASH:
- case SHT_DYNAMIC:
- case SHT_GROUP:
- case SHT_GNU_ATTRIBUTES:
- /* FIXME: Implement these. */
- /* Fall through. */
- default:
- /* FIXME: Add Proc and OS specific section types ? */
- warn (_("Unable to determine how to dump section %d (type %#x)\n"),
- i, section->sh_type);
- res = false;
- break;
- }
- }
-
-#ifdef SUPPORT_DISASSEMBLY
- if (dump & DISASS_DUMP)
- {
- if (! disassemble_section (section, filedata))
- res = false;
- }
-#endif
- if (dump & HEX_DUMP)
- {
- if (! dump_section_as_bytes (section, filedata, false))
- res = false;
- }
-
- if (dump & RELOC_DUMP)
- {
- if (! dump_section_as_bytes (section, filedata, true))
- res = false;
- }
-
- if (dump & STRING_DUMP)
- {
- if (! dump_section_as_strings (section, filedata))
- res = false;
- }
-
- if (dump & DEBUG_DUMP)
- {
- if (! display_debug_section (i, section, filedata))
- res = false;
- }
-
-#ifdef ENABLE_LIBCTF
- if (dump & CTF_DUMP)
- {
- if (! dump_section_as_ctf (section, filedata))
- res = false;
- }
-#endif
- if (dump & SFRAME_DUMP)
- {
- if (! dump_section_as_sframe (section, filedata))
- res = false;
- }
- }
-
- if (! filedata->is_separate)
- {
- /* Check to see if the user requested a
- dump of a section that does not exist. */
- for (; i < filedata->dump.num_dump_sects; i++)
- if (filedata->dump.dump_sects[i])
- {
- warn (_("Section %d was not dumped because it does not exist!\n"), i);
- res = false;
- }
- }
-
- return res;
-}
-
-static void
-process_mips_fpe_exception (int mask)
-{
- if (mask)
- {
- bool first = true;
-
- if (mask & OEX_FPU_INEX)
- fputs ("INEX", stdout), first = false;
- if (mask & OEX_FPU_UFLO)
- printf ("%sUFLO", first ? "" : "|"), first = false;
- if (mask & OEX_FPU_OFLO)
- printf ("%sOFLO", first ? "" : "|"), first = false;
- if (mask & OEX_FPU_DIV0)
- printf ("%sDIV0", first ? "" : "|"), first = false;
- if (mask & OEX_FPU_INVAL)
- printf ("%sINVAL", first ? "" : "|");
- }
- else
- fputs ("0", stdout);
-}
-
-/* Display's the value of TAG at location P. If TAG is
- greater than 0 it is assumed to be an unknown tag, and
- a message is printed to this effect. Otherwise it is
- assumed that a message has already been printed.
-
- If the bottom bit of TAG is set it assumed to have a
- string value, otherwise it is assumed to have an integer
- value.
-
- Returns an updated P pointing to the first unread byte
- beyond the end of TAG's value.
-
- Reads at or beyond END will not be made. */
-
-static unsigned char *
-display_tag_value (signed int tag,
- unsigned char * p,
- const unsigned char * const end)
-{
- uint64_t val;
-
- if (tag > 0)
- printf (" Tag_unknown_%d: ", tag);
-
- if (p >= end)
- {
- warn (_("<corrupt tag>\n"));
- }
- else if (tag & 1)
- {
- /* PR 17531 file: 027-19978-0.004. */
- size_t maxlen = (end - p) - 1;
-
- putchar ('"');
- if (maxlen > 0)
- {
- print_symbol_name ((int) maxlen, (const char *) p);
- p += strnlen ((char *) p, maxlen) + 1;
- }
- else
- {
- printf (_("<corrupt string tag>"));
- p = (unsigned char *) end;
- }
- printf ("\"\n");
- }
- else
- {
- READ_ULEB (val, p, end);
- printf ("%" PRId64 " (0x%" PRIx64 ")\n", val, val);
- }
-
- assert (p <= end);
- return p;
-}
-
-/* ARC ABI attributes section. */
-
-static unsigned char *
-display_arc_attribute (unsigned char * p,
- const unsigned char * const end)
-{
- unsigned int tag;
- unsigned int val;
-
- READ_ULEB (tag, p, end);
-
- switch (tag)
- {
- case Tag_ARC_PCS_config:
- READ_ULEB (val, p, end);
- printf (" Tag_ARC_PCS_config: ");
- switch (val)
- {
- case 0:
- printf (_("Absent/Non standard\n"));
- break;
- case 1:
- printf (_("Bare metal/mwdt\n"));
- break;
- case 2:
- printf (_("Bare metal/newlib\n"));
- break;
- case 3:
- printf (_("Linux/uclibc\n"));
- break;
- case 4:
- printf (_("Linux/glibc\n"));
- break;
- default:
- printf (_("Unknown\n"));
- break;
- }
- break;
-
- case Tag_ARC_CPU_base:
- READ_ULEB (val, p, end);
- printf (" Tag_ARC_CPU_base: ");
- switch (val)
- {
- default:
- case TAG_CPU_NONE:
- printf (_("Absent\n"));
- break;
- case TAG_CPU_ARC6xx:
- printf ("ARC6xx\n");
- break;
- case TAG_CPU_ARC7xx:
- printf ("ARC7xx\n");
- break;
- case TAG_CPU_ARCEM:
- printf ("ARCEM\n");
- break;
- case TAG_CPU_ARCHS:
- printf ("ARCHS\n");
- break;
- }
- break;
-
- case Tag_ARC_CPU_variation:
- READ_ULEB (val, p, end);
- printf (" Tag_ARC_CPU_variation: ");
- switch (val)
- {
- default:
- if (val > 0 && val < 16)
- printf ("Core%d\n", val);
- else
- printf ("Unknown\n");
- break;
-
- case 0:
- printf (_("Absent\n"));
- break;
- }
- break;
-
- case Tag_ARC_CPU_name:
- printf (" Tag_ARC_CPU_name: ");
- p = display_tag_value (-1, p, end);
- break;
-
- case Tag_ARC_ABI_rf16:
- READ_ULEB (val, p, end);
- printf (" Tag_ARC_ABI_rf16: %s\n", val ? _("yes") : _("no"));
- break;
-
- case Tag_ARC_ABI_osver:
- READ_ULEB (val, p, end);
- printf (" Tag_ARC_ABI_osver: v%d\n", val);
- break;
-
- case Tag_ARC_ABI_pic:
- case Tag_ARC_ABI_sda:
- READ_ULEB (val, p, end);
- printf (tag == Tag_ARC_ABI_sda ? " Tag_ARC_ABI_sda: "
- : " Tag_ARC_ABI_pic: ");
- switch (val)
- {
- case 0:
- printf (_("Absent\n"));
- break;
- case 1:
- printf ("MWDT\n");
- break;
- case 2:
- printf ("GNU\n");
- break;
- default:
- printf (_("Unknown\n"));
- break;
- }
- break;
-
- case Tag_ARC_ABI_tls:
- READ_ULEB (val, p, end);
- printf (" Tag_ARC_ABI_tls: %s\n", val ? "r25": "none");
- break;
-
- case Tag_ARC_ABI_enumsize:
- READ_ULEB (val, p, end);
- printf (" Tag_ARC_ABI_enumsize: %s\n", val ? _("default") :
- _("smallest"));
- break;
-
- case Tag_ARC_ABI_exceptions:
- READ_ULEB (val, p, end);
- printf (" Tag_ARC_ABI_exceptions: %s\n", val ? _("OPTFP")
- : _("default"));
- break;
-
- case Tag_ARC_ABI_double_size:
- READ_ULEB (val, p, end);
- printf (" Tag_ARC_ABI_double_size: %d\n", val);
- break;
-
- case Tag_ARC_ISA_config:
- printf (" Tag_ARC_ISA_config: ");
- p = display_tag_value (-1, p, end);
- break;
-
- case Tag_ARC_ISA_apex:
- printf (" Tag_ARC_ISA_apex: ");
- p = display_tag_value (-1, p, end);
- break;
-
- case Tag_ARC_ISA_mpy_option:
- READ_ULEB (val, p, end);
- printf (" Tag_ARC_ISA_mpy_option: %d\n", val);
- break;
-
- case Tag_ARC_ATR_version:
- READ_ULEB (val, p, end);
- printf (" Tag_ARC_ATR_version: %d\n", val);
- break;
-
- default:
- return display_tag_value (tag & 1, p, end);
- }
-
- return p;
-}
-
-/* ARM EABI attributes section. */
-typedef struct
-{
- unsigned int tag;
- const char * name;
- /* 0 = special, 1 = string, 2 = uleb123, > 0x80 == table lookup. */
- unsigned int type;
- const char *const *table;
-} arm_attr_public_tag;
-
-static const char *const arm_attr_tag_CPU_arch[] =
- {"Pre-v4", "v4", "v4T", "v5T", "v5TE", "v5TEJ", "v6", "v6KZ", "v6T2",
- "v6K", "v7", "v6-M", "v6S-M", "v7E-M", "v8", "v8-R", "v8-M.baseline",
- "v8-M.mainline", "v8.1-A", "v8.2-A", "v8.3-A",
- "v8.1-M.mainline", "v9"};
-static const char *const arm_attr_tag_ARM_ISA_use[] = {"No", "Yes"};
-static const char *const arm_attr_tag_THUMB_ISA_use[] =
- {"No", "Thumb-1", "Thumb-2", "Yes"};
-static const char *const arm_attr_tag_FP_arch[] =
- {"No", "VFPv1", "VFPv2", "VFPv3", "VFPv3-D16", "VFPv4", "VFPv4-D16",
- "FP for ARMv8", "FPv5/FP-D16 for ARMv8"};
-static const char *const arm_attr_tag_WMMX_arch[] = {"No", "WMMXv1", "WMMXv2"};
-static const char *const arm_attr_tag_Advanced_SIMD_arch[] =
- {"No", "NEONv1", "NEONv1 with Fused-MAC", "NEON for ARMv8",
- "NEON for ARMv8.1"};
-static const char *const arm_attr_tag_PCS_config[] =
- {"None", "Bare platform", "Linux application", "Linux DSO", "PalmOS 2004",
- "PalmOS (reserved)", "SymbianOS 2004", "SymbianOS (reserved)"};
-static const char *const arm_attr_tag_ABI_PCS_R9_use[] =
- {"V6", "SB", "TLS", "Unused"};
-static const char *const arm_attr_tag_ABI_PCS_RW_data[] =
- {"Absolute", "PC-relative", "SB-relative", "None"};
-static const char *const arm_attr_tag_ABI_PCS_RO_data[] =
- {"Absolute", "PC-relative", "None"};
-static const char *const arm_attr_tag_ABI_PCS_GOT_use[] =
- {"None", "direct", "GOT-indirect"};
-static const char *const arm_attr_tag_ABI_PCS_wchar_t[] =
- {"None", "??? 1", "2", "??? 3", "4"};
-static const char *const arm_attr_tag_ABI_FP_rounding[] = {"Unused", "Needed"};
-static const char *const arm_attr_tag_ABI_FP_denormal[] =
- {"Unused", "Needed", "Sign only"};
-static const char *const arm_attr_tag_ABI_FP_exceptions[] = {"Unused", "Needed"};
-static const char *const arm_attr_tag_ABI_FP_user_exceptions[] = {"Unused", "Needed"};
-static const char *const arm_attr_tag_ABI_FP_number_model[] =
- {"Unused", "Finite", "RTABI", "IEEE 754"};
-static const char *const arm_attr_tag_ABI_enum_size[] =
- {"Unused", "small", "int", "forced to int"};
-static const char *const arm_attr_tag_ABI_HardFP_use[] =
- {"As Tag_FP_arch", "SP only", "Reserved", "Deprecated"};
-static const char *const arm_attr_tag_ABI_VFP_args[] =
- {"AAPCS", "VFP registers", "custom", "compatible"};
-static const char *const arm_attr_tag_ABI_WMMX_args[] =
- {"AAPCS", "WMMX registers", "custom"};
-static const char *const arm_attr_tag_ABI_optimization_goals[] =
- {"None", "Prefer Speed", "Aggressive Speed", "Prefer Size",
- "Aggressive Size", "Prefer Debug", "Aggressive Debug"};
-static const char *const arm_attr_tag_ABI_FP_optimization_goals[] =
- {"None", "Prefer Speed", "Aggressive Speed", "Prefer Size",
- "Aggressive Size", "Prefer Accuracy", "Aggressive Accuracy"};
-static const char *const arm_attr_tag_CPU_unaligned_access[] = {"None", "v6"};
-static const char *const arm_attr_tag_FP_HP_extension[] =
- {"Not Allowed", "Allowed"};
-static const char *const arm_attr_tag_ABI_FP_16bit_format[] =
- {"None", "IEEE 754", "Alternative Format"};
-static const char *const arm_attr_tag_DSP_extension[] =
- {"Follow architecture", "Allowed"};
-static const char *const arm_attr_tag_MPextension_use[] =
- {"Not Allowed", "Allowed"};
-static const char *const arm_attr_tag_DIV_use[] =
- {"Allowed in Thumb-ISA, v7-R or v7-M", "Not allowed",
- "Allowed in v7-A with integer division extension"};
-static const char *const arm_attr_tag_T2EE_use[] = {"Not Allowed", "Allowed"};
-static const char *const arm_attr_tag_Virtualization_use[] =
- {"Not Allowed", "TrustZone", "Virtualization Extensions",
- "TrustZone and Virtualization Extensions"};
-static const char *const arm_attr_tag_MPextension_use_legacy[] =
- {"Not Allowed", "Allowed"};
-
-static const char *const arm_attr_tag_MVE_arch[] =
- {"No MVE", "MVE Integer only", "MVE Integer and FP"};
-
-static const char * arm_attr_tag_PAC_extension[] =
- {"No PAC/AUT instructions",
- "PAC/AUT instructions permitted in the NOP space",
- "PAC/AUT instructions permitted in the NOP and in the non-NOP space"};
-
-static const char * arm_attr_tag_BTI_extension[] =
- {"BTI instructions not permitted",
- "BTI instructions permitted in the NOP space",
- "BTI instructions permitted in the NOP and in the non-NOP space"};
-
-static const char * arm_attr_tag_BTI_use[] =
- {"Compiled without branch target enforcement",
- "Compiled with branch target enforcement"};
-
-static const char * arm_attr_tag_PACRET_use[] =
- {"Compiled without return address signing and authentication",
- "Compiled with return address signing and authentication"};
-
-#define LOOKUP(id, name) \
- {id, #name, 0x80 | ARRAY_SIZE(arm_attr_tag_##name), arm_attr_tag_##name}
-static arm_attr_public_tag arm_attr_public_tags[] =
-{
- {4, "CPU_raw_name", 1, NULL},
- {5, "CPU_name", 1, NULL},
- LOOKUP(6, CPU_arch),
- {7, "CPU_arch_profile", 0, NULL},
- LOOKUP(8, ARM_ISA_use),
- LOOKUP(9, THUMB_ISA_use),
- LOOKUP(10, FP_arch),
- LOOKUP(11, WMMX_arch),
- LOOKUP(12, Advanced_SIMD_arch),
- LOOKUP(13, PCS_config),
- LOOKUP(14, ABI_PCS_R9_use),
- LOOKUP(15, ABI_PCS_RW_data),
- LOOKUP(16, ABI_PCS_RO_data),
- LOOKUP(17, ABI_PCS_GOT_use),
- LOOKUP(18, ABI_PCS_wchar_t),
- LOOKUP(19, ABI_FP_rounding),
- LOOKUP(20, ABI_FP_denormal),
- LOOKUP(21, ABI_FP_exceptions),
- LOOKUP(22, ABI_FP_user_exceptions),
- LOOKUP(23, ABI_FP_number_model),
- {24, "ABI_align_needed", 0, NULL},
- {25, "ABI_align_preserved", 0, NULL},
- LOOKUP(26, ABI_enum_size),
- LOOKUP(27, ABI_HardFP_use),
- LOOKUP(28, ABI_VFP_args),
- LOOKUP(29, ABI_WMMX_args),
- LOOKUP(30, ABI_optimization_goals),
- LOOKUP(31, ABI_FP_optimization_goals),
- {32, "compatibility", 0, NULL},
- LOOKUP(34, CPU_unaligned_access),
- LOOKUP(36, FP_HP_extension),
- LOOKUP(38, ABI_FP_16bit_format),
- LOOKUP(42, MPextension_use),
- LOOKUP(44, DIV_use),
- LOOKUP(46, DSP_extension),
- LOOKUP(48, MVE_arch),
- LOOKUP(50, PAC_extension),
- LOOKUP(52, BTI_extension),
- LOOKUP(74, BTI_use),
- LOOKUP(76, PACRET_use),
- {64, "nodefaults", 0, NULL},
- {65, "also_compatible_with", 0, NULL},
- LOOKUP(66, T2EE_use),
- {67, "conformance", 1, NULL},
- LOOKUP(68, Virtualization_use),
- LOOKUP(70, MPextension_use_legacy)
-};
-#undef LOOKUP
-
-static unsigned char *
-display_arm_attribute (unsigned char * p,
- const unsigned char * const end)
-{
- unsigned int tag;
- unsigned int val;
- arm_attr_public_tag * attr;
- unsigned i;
- unsigned int type;
-
- READ_ULEB (tag, p, end);
- attr = NULL;
- for (i = 0; i < ARRAY_SIZE (arm_attr_public_tags); i++)
- {
- if (arm_attr_public_tags[i].tag == tag)
- {
- attr = &arm_attr_public_tags[i];
- break;
- }
- }
-
- if (attr)
- {
- printf (" Tag_%s: ", attr->name);
- switch (attr->type)
- {
- case 0:
- switch (tag)
- {
- case 7: /* Tag_CPU_arch_profile. */
- READ_ULEB (val, p, end);
- switch (val)
- {
- case 0: printf (_("None\n")); break;
- case 'A': printf (_("Application\n")); break;
- case 'R': printf (_("Realtime\n")); break;
- case 'M': printf (_("Microcontroller\n")); break;
- case 'S': printf (_("Application or Realtime\n")); break;
- default: printf ("??? (%d)\n", val); break;
- }
- break;
-
- case 24: /* Tag_align_needed. */
- READ_ULEB (val, p, end);
- switch (val)
- {
- case 0: printf (_("None\n")); break;
- case 1: printf (_("8-byte\n")); break;
- case 2: printf (_("4-byte\n")); break;
- case 3: printf ("??? 3\n"); break;
- default:
- if (val <= 12)
- printf (_("8-byte and up to %d-byte extended\n"),
- 1 << val);
- else
- printf ("??? (%d)\n", val);
- break;
- }
- break;
-
- case 25: /* Tag_align_preserved. */
- READ_ULEB (val, p, end);
- switch (val)
- {
- case 0: printf (_("None\n")); break;
- case 1: printf (_("8-byte, except leaf SP\n")); break;
- case 2: printf (_("8-byte\n")); break;
- case 3: printf ("??? 3\n"); break;
- default:
- if (val <= 12)
- printf (_("8-byte and up to %d-byte extended\n"),
- 1 << val);
- else
- printf ("??? (%d)\n", val);
- break;
- }
- break;
-
- case 32: /* Tag_compatibility. */
- {
- READ_ULEB (val, p, end);
- printf (_("flag = %d, vendor = "), val);
- if (p < end - 1)
- {
- size_t maxlen = (end - p) - 1;
-
- print_symbol_name ((int) maxlen, (const char *) p);
- p += strnlen ((char *) p, maxlen) + 1;
- }
- else
- {
- printf (_("<corrupt>"));
- p = (unsigned char *) end;
- }
- putchar ('\n');
- }
- break;
-
- case 64: /* Tag_nodefaults. */
- /* PR 17531: file: 001-505008-0.01. */
- if (p < end)
- p++;
- printf (_("True\n"));
- break;
-
- case 65: /* Tag_also_compatible_with. */
- READ_ULEB (val, p, end);
- if (val == 6 /* Tag_CPU_arch. */)
- {
- READ_ULEB (val, p, end);
- if ((unsigned int) val >= ARRAY_SIZE (arm_attr_tag_CPU_arch))
- printf ("??? (%d)\n", val);
- else
- printf ("%s\n", arm_attr_tag_CPU_arch[val]);
- }
- else
- printf ("???\n");
- while (p < end && *(p++) != '\0' /* NUL terminator. */)
- ;
- break;
-
- default:
- printf (_("<unknown: %d>\n"), tag);
- break;
- }
- return p;
-
- case 1:
- return display_tag_value (-1, p, end);
- case 2:
- return display_tag_value (0, p, end);
-
- default:
- assert (attr->type & 0x80);
- READ_ULEB (val, p, end);
- type = attr->type & 0x7f;
- if (val >= type)
- printf ("??? (%d)\n", val);
- else
- printf ("%s\n", attr->table[val]);
- return p;
- }
- }
-
- return display_tag_value (tag, p, end);
-}
-
-static unsigned char *
-display_gnu_attribute (unsigned char * p,
- unsigned char * (* display_proc_gnu_attribute)
- (unsigned char *, unsigned int, const unsigned char * const),
- const unsigned char * const end)
-{
- unsigned int tag;
- unsigned int val;
-
- READ_ULEB (tag, p, end);
-
- /* Tag_compatibility is the only generic GNU attribute defined at
- present. */
- if (tag == 32)
- {
- READ_ULEB (val, p, end);
-
- printf (_("flag = %d, vendor = "), val);
- if (p == end)
- {
- printf (_("<corrupt>\n"));
- warn (_("corrupt vendor attribute\n"));
- }
- else
- {
- if (p < end - 1)
- {
- size_t maxlen = (end - p) - 1;
-
- print_symbol_name ((int) maxlen, (const char *) p);
- p += strnlen ((char *) p, maxlen) + 1;
- }
- else
- {
- printf (_("<corrupt>"));
- p = (unsigned char *) end;
- }
- putchar ('\n');
- }
- return p;
- }
-
- if ((tag & 2) == 0 && display_proc_gnu_attribute)
- return display_proc_gnu_attribute (p, tag, end);
-
- return display_tag_value (tag, p, end);
-}
-
-static unsigned char *
-display_m68k_gnu_attribute (unsigned char * p,
- unsigned int tag,
- const unsigned char * const end)
-{
- unsigned int val;
-
- if (tag == Tag_GNU_M68K_ABI_FP)
- {
- printf (" Tag_GNU_M68K_ABI_FP: ");
- if (p == end)
- {
- printf (_("<corrupt>\n"));
- return p;
- }
- READ_ULEB (val, p, end);
-
- if (val > 3)
- printf ("(%#x), ", val);
-
- switch (val & 3)
- {
- case 0:
- printf (_("unspecified hard/soft float\n"));
- break;
- case 1:
- printf (_("hard float\n"));
- break;
- case 2:
- printf (_("soft float\n"));
- break;
- }
- return p;
- }
-
- return display_tag_value (tag & 1, p, end);
-}
-
-static unsigned char *
-display_power_gnu_attribute (unsigned char * p,
- unsigned int tag,
- const unsigned char * const end)
-{
- unsigned int val;
-
- if (tag == Tag_GNU_Power_ABI_FP)
- {
- printf (" Tag_GNU_Power_ABI_FP: ");
- if (p == end)
- {
- printf (_("<corrupt>\n"));
- return p;
- }
- READ_ULEB (val, p, end);
-
- if (val > 15)
- printf ("(%#x), ", val);
-
- switch (val & 3)
- {
- case 0:
- printf (_("unspecified hard/soft float, "));
- break;
- case 1:
- printf (_("hard float, "));
- break;
- case 2:
- printf (_("soft float, "));
- break;
- case 3:
- printf (_("single-precision hard float, "));
- break;
- }
-
- switch (val & 0xC)
- {
- case 0:
- printf (_("unspecified long double\n"));
- break;
- case 4:
- printf (_("128-bit IBM long double\n"));
- break;
- case 8:
- printf (_("64-bit long double\n"));
- break;
- case 12:
- printf (_("128-bit IEEE long double\n"));
- break;
- }
- return p;
- }
-
- if (tag == Tag_GNU_Power_ABI_Vector)
- {
- printf (" Tag_GNU_Power_ABI_Vector: ");
- if (p == end)
- {
- printf (_("<corrupt>\n"));
- return p;
- }
- READ_ULEB (val, p, end);
-
- if (val > 3)
- printf ("(%#x), ", val);
-
- switch (val & 3)
- {
- case 0:
- printf (_("unspecified\n"));
- break;
- case 1:
- printf (_("generic\n"));
- break;
- case 2:
- printf ("AltiVec\n");
- break;
- case 3:
- printf ("SPE\n");
- break;
- }
- return p;
- }
-
- if (tag == Tag_GNU_Power_ABI_Struct_Return)
- {
- printf (" Tag_GNU_Power_ABI_Struct_Return: ");
- if (p == end)
- {
- printf (_("<corrupt>\n"));
- return p;
- }
- READ_ULEB (val, p, end);
-
- if (val > 2)
- printf ("(%#x), ", val);
-
- switch (val & 3)
- {
- case 0:
- printf (_("unspecified\n"));
- break;
- case 1:
- printf ("r3/r4\n");
- break;
- case 2:
- printf (_("memory\n"));
- break;
- case 3:
- printf ("???\n");
- break;
- }
- return p;
- }
-
- return display_tag_value (tag & 1, p, end);
-}
-
-static unsigned char *
-display_s390_gnu_attribute (unsigned char * p,
- unsigned int tag,
- const unsigned char * const end)
-{
- unsigned int val;
-
- if (tag == Tag_GNU_S390_ABI_Vector)
- {
- printf (" Tag_GNU_S390_ABI_Vector: ");
- READ_ULEB (val, p, end);
-
- switch (val)
- {
- case 0:
- printf (_("any\n"));
- break;
- case 1:
- printf (_("software\n"));
- break;
- case 2:
- printf (_("hardware\n"));
- break;
- default:
- printf ("??? (%d)\n", val);
- break;
- }
- return p;
- }
-
- return display_tag_value (tag & 1, p, end);
-}
-
-static void
-display_sparc_hwcaps (unsigned int mask)
-{
- if (mask)
- {
- bool first = true;
-
- if (mask & ELF_SPARC_HWCAP_MUL32)
- fputs ("mul32", stdout), first = false;
- if (mask & ELF_SPARC_HWCAP_DIV32)
- printf ("%sdiv32", first ? "" : "|"), first = false;
- if (mask & ELF_SPARC_HWCAP_FSMULD)
- printf ("%sfsmuld", first ? "" : "|"), first = false;
- if (mask & ELF_SPARC_HWCAP_V8PLUS)
- printf ("%sv8plus", first ? "" : "|"), first = false;
- if (mask & ELF_SPARC_HWCAP_POPC)
- printf ("%spopc", first ? "" : "|"), first = false;
- if (mask & ELF_SPARC_HWCAP_VIS)
- printf ("%svis", first ? "" : "|"), first = false;
- if (mask & ELF_SPARC_HWCAP_VIS2)
- printf ("%svis2", first ? "" : "|"), first = false;
- if (mask & ELF_SPARC_HWCAP_ASI_BLK_INIT)
- printf ("%sASIBlkInit", first ? "" : "|"), first = false;
- if (mask & ELF_SPARC_HWCAP_FMAF)
- printf ("%sfmaf", first ? "" : "|"), first = false;
- if (mask & ELF_SPARC_HWCAP_VIS3)
- printf ("%svis3", first ? "" : "|"), first = false;
- if (mask & ELF_SPARC_HWCAP_HPC)
- printf ("%shpc", first ? "" : "|"), first = false;
- if (mask & ELF_SPARC_HWCAP_RANDOM)
- printf ("%srandom", first ? "" : "|"), first = false;
- if (mask & ELF_SPARC_HWCAP_TRANS)
- printf ("%strans", first ? "" : "|"), first = false;
- if (mask & ELF_SPARC_HWCAP_FJFMAU)
- printf ("%sfjfmau", first ? "" : "|"), first = false;
- if (mask & ELF_SPARC_HWCAP_IMA)
- printf ("%sima", first ? "" : "|"), first = false;
- if (mask & ELF_SPARC_HWCAP_ASI_CACHE_SPARING)
- printf ("%scspare", first ? "" : "|"), first = false;
- }
- else
- fputc ('0', stdout);
- fputc ('\n', stdout);
-}
-
-static void
-display_sparc_hwcaps2 (unsigned int mask)
-{
- if (mask)
- {
- bool first = true;
-
- if (mask & ELF_SPARC_HWCAP2_FJATHPLUS)
- fputs ("fjathplus", stdout), first = false;
- if (mask & ELF_SPARC_HWCAP2_VIS3B)
- printf ("%svis3b", first ? "" : "|"), first = false;
- if (mask & ELF_SPARC_HWCAP2_ADP)
- printf ("%sadp", first ? "" : "|"), first = false;
- if (mask & ELF_SPARC_HWCAP2_SPARC5)
- printf ("%ssparc5", first ? "" : "|"), first = false;
- if (mask & ELF_SPARC_HWCAP2_MWAIT)
- printf ("%smwait", first ? "" : "|"), first = false;
- if (mask & ELF_SPARC_HWCAP2_XMPMUL)
- printf ("%sxmpmul", first ? "" : "|"), first = false;
- if (mask & ELF_SPARC_HWCAP2_XMONT)
- printf ("%sxmont2", first ? "" : "|"), first = false;
- if (mask & ELF_SPARC_HWCAP2_NSEC)
- printf ("%snsec", first ? "" : "|"), first = false;
- if (mask & ELF_SPARC_HWCAP2_FJATHHPC)
- printf ("%sfjathhpc", first ? "" : "|"), first = false;
- if (mask & ELF_SPARC_HWCAP2_FJDES)
- printf ("%sfjdes", first ? "" : "|"), first = false;
- if (mask & ELF_SPARC_HWCAP2_FJAES)
- printf ("%sfjaes", first ? "" : "|"), first = false;
- }
- else
- fputc ('0', stdout);
- fputc ('\n', stdout);
-}
-
-static unsigned char *
-display_sparc_gnu_attribute (unsigned char * p,
- unsigned int tag,
- const unsigned char * const end)
-{
- unsigned int val;
-
- if (tag == Tag_GNU_Sparc_HWCAPS)
- {
- READ_ULEB (val, p, end);
- printf (" Tag_GNU_Sparc_HWCAPS: ");
- display_sparc_hwcaps (val);
- return p;
- }
- if (tag == Tag_GNU_Sparc_HWCAPS2)
- {
- READ_ULEB (val, p, end);
- printf (" Tag_GNU_Sparc_HWCAPS2: ");
- display_sparc_hwcaps2 (val);
- return p;
- }
-
- return display_tag_value (tag, p, end);
-}
-
-static void
-print_mips_fp_abi_value (unsigned int val)
-{
- switch (val)
- {
- case Val_GNU_MIPS_ABI_FP_ANY:
- printf (_("Hard or soft float\n"));
- break;
- case Val_GNU_MIPS_ABI_FP_DOUBLE:
- printf (_("Hard float (double precision)\n"));
- break;
- case Val_GNU_MIPS_ABI_FP_SINGLE:
- printf (_("Hard float (single precision)\n"));
- break;
- case Val_GNU_MIPS_ABI_FP_SOFT:
- printf (_("Soft float\n"));
- break;
- case Val_GNU_MIPS_ABI_FP_OLD_64:
- printf (_("Hard float (MIPS32r2 64-bit FPU 12 callee-saved)\n"));
- break;
- case Val_GNU_MIPS_ABI_FP_XX:
- printf (_("Hard float (32-bit CPU, Any FPU)\n"));
- break;
- case Val_GNU_MIPS_ABI_FP_64:
- printf (_("Hard float (32-bit CPU, 64-bit FPU)\n"));
- break;
- case Val_GNU_MIPS_ABI_FP_64A:
- printf (_("Hard float compat (32-bit CPU, 64-bit FPU)\n"));
- break;
- case Val_GNU_MIPS_ABI_FP_NAN2008:
- printf (_("NaN 2008 compatibility\n"));
- break;
- default:
- printf ("??? (%d)\n", val);
- break;
- }
-}
-
-static unsigned char *
-display_mips_gnu_attribute (unsigned char * p,
- unsigned int tag,
- const unsigned char * const end)
-{
- if (tag == Tag_GNU_MIPS_ABI_FP)
- {
- unsigned int val;
-
- printf (" Tag_GNU_MIPS_ABI_FP: ");
- READ_ULEB (val, p, end);
- print_mips_fp_abi_value (val);
- return p;
- }
-
- if (tag == Tag_GNU_MIPS_ABI_MSA)
- {
- unsigned int val;
-
- printf (" Tag_GNU_MIPS_ABI_MSA: ");
- READ_ULEB (val, p, end);
-
- switch (val)
- {
- case Val_GNU_MIPS_ABI_MSA_ANY:
- printf (_("Any MSA or not\n"));
- break;
- case Val_GNU_MIPS_ABI_MSA_128:
- printf (_("128-bit MSA\n"));
- break;
- default:
- printf ("??? (%d)\n", val);
- break;
- }
- return p;
- }
-
- return display_tag_value (tag & 1, p, end);
-}
-
-static unsigned char *
-display_tic6x_attribute (unsigned char * p,
- const unsigned char * const end)
-{
- unsigned int tag;
- unsigned int val;
-
- READ_ULEB (tag, p, end);
-
- switch (tag)
- {
- case Tag_ISA:
- printf (" Tag_ISA: ");
- READ_ULEB (val, p, end);
-
- switch (val)
- {
- case C6XABI_Tag_ISA_none:
- printf (_("None\n"));
- break;
- case C6XABI_Tag_ISA_C62X:
- printf ("C62x\n");
- break;
- case C6XABI_Tag_ISA_C67X:
- printf ("C67x\n");
- break;
- case C6XABI_Tag_ISA_C67XP:
- printf ("C67x+\n");
- break;
- case C6XABI_Tag_ISA_C64X:
- printf ("C64x\n");
- break;
- case C6XABI_Tag_ISA_C64XP:
- printf ("C64x+\n");
- break;
- case C6XABI_Tag_ISA_C674X:
- printf ("C674x\n");
- break;
- default:
- printf ("??? (%d)\n", val);
- break;
- }
- return p;
-
- case Tag_ABI_wchar_t:
- printf (" Tag_ABI_wchar_t: ");
- READ_ULEB (val, p, end);
- switch (val)
- {
- case 0:
- printf (_("Not used\n"));
- break;
- case 1:
- printf (_("2 bytes\n"));
- break;
- case 2:
- printf (_("4 bytes\n"));
- break;
- default:
- printf ("??? (%d)\n", val);
- break;
- }
- return p;
-
- case Tag_ABI_stack_align_needed:
- printf (" Tag_ABI_stack_align_needed: ");
- READ_ULEB (val, p, end);
- switch (val)
- {
- case 0:
- printf (_("8-byte\n"));
- break;
- case 1:
- printf (_("16-byte\n"));
- break;
- default:
- printf ("??? (%d)\n", val);
- break;
- }
- return p;
-
- case Tag_ABI_stack_align_preserved:
- READ_ULEB (val, p, end);
- printf (" Tag_ABI_stack_align_preserved: ");
- switch (val)
- {
- case 0:
- printf (_("8-byte\n"));
- break;
- case 1:
- printf (_("16-byte\n"));
- break;
- default:
- printf ("??? (%d)\n", val);
- break;
- }
- return p;
-
- case Tag_ABI_DSBT:
- READ_ULEB (val, p, end);
- printf (" Tag_ABI_DSBT: ");
- switch (val)
- {
- case 0:
- printf (_("DSBT addressing not used\n"));
- break;
- case 1:
- printf (_("DSBT addressing used\n"));
- break;
- default:
- printf ("??? (%d)\n", val);
- break;
- }
- return p;
-
- case Tag_ABI_PID:
- READ_ULEB (val, p, end);
- printf (" Tag_ABI_PID: ");
- switch (val)
- {
- case 0:
- printf (_("Data addressing position-dependent\n"));
- break;
- case 1:
- printf (_("Data addressing position-independent, GOT near DP\n"));
- break;
- case 2:
- printf (_("Data addressing position-independent, GOT far from DP\n"));
- break;
- default:
- printf ("??? (%d)\n", val);
- break;
- }
- return p;
-
- case Tag_ABI_PIC:
- READ_ULEB (val, p, end);
- printf (" Tag_ABI_PIC: ");
- switch (val)
- {
- case 0:
- printf (_("Code addressing position-dependent\n"));
- break;
- case 1:
- printf (_("Code addressing position-independent\n"));
- break;
- default:
- printf ("??? (%d)\n", val);
- break;
- }
- return p;
-
- case Tag_ABI_array_object_alignment:
- READ_ULEB (val, p, end);
- printf (" Tag_ABI_array_object_alignment: ");
- switch (val)
- {
- case 0:
- printf (_("8-byte\n"));
- break;
- case 1:
- printf (_("4-byte\n"));
- break;
- case 2:
- printf (_("16-byte\n"));
- break;
- default:
- printf ("??? (%d)\n", val);
- break;
- }
- return p;
-
- case Tag_ABI_array_object_align_expected:
- READ_ULEB (val, p, end);
- printf (" Tag_ABI_array_object_align_expected: ");
- switch (val)
- {
- case 0:
- printf (_("8-byte\n"));
- break;
- case 1:
- printf (_("4-byte\n"));
- break;
- case 2:
- printf (_("16-byte\n"));
- break;
- default:
- printf ("??? (%d)\n", val);
- break;
- }
- return p;
-
- case Tag_ABI_compatibility:
- {
- READ_ULEB (val, p, end);
- printf (" Tag_ABI_compatibility: ");
- printf (_("flag = %d, vendor = "), val);
- if (p < end - 1)
- {
- size_t maxlen = (end - p) - 1;
-
- print_symbol_name ((int) maxlen, (const char *) p);
- p += strnlen ((char *) p, maxlen) + 1;
- }
- else
- {
- printf (_("<corrupt>"));
- p = (unsigned char *) end;
- }
- putchar ('\n');
- return p;
- }
-
- case Tag_ABI_conformance:
- {
- printf (" Tag_ABI_conformance: \"");
- if (p < end - 1)
- {
- size_t maxlen = (end - p) - 1;
-
- print_symbol_name ((int) maxlen, (const char *) p);
- p += strnlen ((char *) p, maxlen) + 1;
- }
- else
- {
- printf (_("<corrupt>"));
- p = (unsigned char *) end;
- }
- printf ("\"\n");
- return p;
- }
- }
-
- return display_tag_value (tag, p, end);
-}
-
-static void
-display_raw_attribute (unsigned char * p, unsigned char const * const end)
-{
- uint64_t addr = 0;
- size_t bytes = end - p;
-
- assert (end >= p);
- while (bytes)
- {
- int j;
- int k;
- int lbytes = (bytes > 16 ? 16 : bytes);
-
- printf (" 0x%8.8" PRIx64 " ", addr);
-
- for (j = 0; j < 16; j++)
- {
- if (j < lbytes)
- printf ("%2.2x", p[j]);
- else
- printf (" ");
-
- if ((j & 3) == 3)
- printf (" ");
- }
-
- for (j = 0; j < lbytes; j++)
- {
- k = p[j];
- if (k >= ' ' && k < 0x7f)
- printf ("%c", k);
- else
- printf (".");
- }
-
- putchar ('\n');
-
- p += lbytes;
- bytes -= lbytes;
- addr += lbytes;
- }
-
- putchar ('\n');
-}
-
-static unsigned char *
-display_msp430_attribute (unsigned char * p,
- const unsigned char * const end)
-{
- uint64_t val;
- uint64_t tag;
-
- READ_ULEB (tag, p, end);
-
- switch (tag)
- {
- case OFBA_MSPABI_Tag_ISA:
- printf (" Tag_ISA: ");
- READ_ULEB (val, p, end);
- switch (val)
- {
- case 0: printf (_("None\n")); break;
- case 1: printf (_("MSP430\n")); break;
- case 2: printf (_("MSP430X\n")); break;
- default: printf ("??? (%" PRId64 ")\n", val); break;
- }
- break;
-
- case OFBA_MSPABI_Tag_Code_Model:
- printf (" Tag_Code_Model: ");
- READ_ULEB (val, p, end);
- switch (val)
- {
- case 0: printf (_("None\n")); break;
- case 1: printf (_("Small\n")); break;
- case 2: printf (_("Large\n")); break;
- default: printf ("??? (%" PRId64 ")\n", val); break;
- }
- break;
-
- case OFBA_MSPABI_Tag_Data_Model:
- printf (" Tag_Data_Model: ");
- READ_ULEB (val, p, end);
- switch (val)
- {
- case 0: printf (_("None\n")); break;
- case 1: printf (_("Small\n")); break;
- case 2: printf (_("Large\n")); break;
- case 3: printf (_("Restricted Large\n")); break;
- default: printf ("??? (%" PRId64 ")\n", val); break;
- }
- break;
-
- default:
- printf (_(" <unknown tag %" PRId64 ">: "), tag);
-
- if (tag & 1)
- {
- putchar ('"');
- if (p < end - 1)
- {
- size_t maxlen = (end - p) - 1;
-
- print_symbol_name ((int) maxlen, (const char *) p);
- p += strnlen ((char *) p, maxlen) + 1;
- }
- else
- {
- printf (_("<corrupt>"));
- p = (unsigned char *) end;
- }
- printf ("\"\n");
- }
- else
- {
- READ_ULEB (val, p, end);
- printf ("%" PRId64 " (0x%" PRIx64 ")\n", val, val);
- }
- break;
- }
-
- assert (p <= end);
- return p;
-}
-
-static unsigned char *
-display_msp430_gnu_attribute (unsigned char * p,
- unsigned int tag,
- const unsigned char * const end)
-{
- if (tag == Tag_GNU_MSP430_Data_Region)
- {
- uint64_t val;
-
- printf (" Tag_GNU_MSP430_Data_Region: ");
- READ_ULEB (val, p, end);
-
- switch (val)
- {
- case Val_GNU_MSP430_Data_Region_Any:
- printf (_("Any Region\n"));
- break;
- case Val_GNU_MSP430_Data_Region_Lower:
- printf (_("Lower Region Only\n"));
- break;
- default:
- printf ("??? (%" PRIu64 ")\n", val);
- }
- return p;
- }
- return display_tag_value (tag & 1, p, end);
-}
-
-struct riscv_attr_tag_t {
- const char *name;
- unsigned int tag;
-};
-
-static struct riscv_attr_tag_t riscv_attr_tag[] =
-{
-#define T(tag) {"Tag_RISCV_" #tag, Tag_RISCV_##tag}
- T(arch),
- T(priv_spec),
- T(priv_spec_minor),
- T(priv_spec_revision),
- T(unaligned_access),
- T(stack_align),
-#undef T
-};
-
-static unsigned char *
-display_riscv_attribute (unsigned char *p,
- const unsigned char * const end)
-{
- uint64_t val;
- uint64_t tag;
- struct riscv_attr_tag_t *attr = NULL;
- unsigned i;
-
- READ_ULEB (tag, p, end);
-
- /* Find the name of attribute. */
- for (i = 0; i < ARRAY_SIZE (riscv_attr_tag); i++)
- {
- if (riscv_attr_tag[i].tag == tag)
- {
- attr = &riscv_attr_tag[i];
- break;
- }
- }
-
- if (attr)
- printf (" %s: ", attr->name);
- else
- return display_tag_value (tag, p, end);
-
- switch (tag)
- {
- case Tag_RISCV_priv_spec:
- case Tag_RISCV_priv_spec_minor:
- case Tag_RISCV_priv_spec_revision:
- READ_ULEB (val, p, end);
- printf ("%" PRIu64 "\n", val);
- break;
- case Tag_RISCV_unaligned_access:
- READ_ULEB (val, p, end);
- switch (val)
- {
- case 0:
- printf (_("No unaligned access\n"));
- break;
- case 1:
- printf (_("Unaligned access\n"));
- break;
- }
- break;
- case Tag_RISCV_stack_align:
- READ_ULEB (val, p, end);
- printf (_("%" PRIu64 "-bytes\n"), val);
- break;
- case Tag_RISCV_arch:
- p = display_tag_value (-1, p, end);
- break;
- default:
- return display_tag_value (tag, p, end);
- }
-
- return p;
-}
-
-static unsigned char *
-display_csky_attribute (unsigned char * p,
- const unsigned char * const end)
-{
- uint64_t tag;
- uint64_t val;
- READ_ULEB (tag, p, end);
-
- if (tag >= Tag_CSKY_MAX)
- {
- return display_tag_value (-1, p, end);
- }
-
- switch (tag)
- {
- case Tag_CSKY_ARCH_NAME:
- printf (" Tag_CSKY_ARCH_NAME:\t\t");
- return display_tag_value (-1, p, end);
- case Tag_CSKY_CPU_NAME:
- printf (" Tag_CSKY_CPU_NAME:\t\t");
- return display_tag_value (-1, p, end);
-
- case Tag_CSKY_ISA_FLAGS:
- printf (" Tag_CSKY_ISA_FLAGS:\t\t");
- return display_tag_value (0, p, end);
- case Tag_CSKY_ISA_EXT_FLAGS:
- printf (" Tag_CSKY_ISA_EXT_FLAGS:\t");
- return display_tag_value (0, p, end);
-
- case Tag_CSKY_DSP_VERSION:
- printf (" Tag_CSKY_DSP_VERSION:\t\t");
- READ_ULEB (val, p, end);
- if (val == VAL_CSKY_DSP_VERSION_EXTENSION)
- printf ("DSP Extension\n");
- else if (val == VAL_CSKY_DSP_VERSION_2)
- printf ("DSP 2.0\n");
- break;
-
- case Tag_CSKY_VDSP_VERSION:
- printf (" Tag_CSKY_VDSP_VERSION:\t");
- READ_ULEB (val, p, end);
- printf ("VDSP Version %" PRId64 "\n", val);
- break;
-
- case Tag_CSKY_FPU_VERSION:
- printf (" Tag_CSKY_FPU_VERSION:\t\t");
- READ_ULEB (val, p, end);
- if (val == VAL_CSKY_FPU_VERSION_1)
- printf ("ABIV1 FPU Version 1\n");
- else if (val == VAL_CSKY_FPU_VERSION_2)
- printf ("FPU Version 2\n");
- break;
-
- case Tag_CSKY_FPU_ABI:
- printf (" Tag_CSKY_FPU_ABI:\t\t");
- READ_ULEB (val, p, end);
- if (val == VAL_CSKY_FPU_ABI_HARD)
- printf ("Hard\n");
- else if (val == VAL_CSKY_FPU_ABI_SOFTFP)
- printf ("SoftFP\n");
- else if (val == VAL_CSKY_FPU_ABI_SOFT)
- printf ("Soft\n");
- break;
- case Tag_CSKY_FPU_ROUNDING:
- READ_ULEB (val, p, end);
- if (val == 1)
- {
- printf (" Tag_CSKY_FPU_ROUNDING:\t");
- printf ("Needed\n");
- }
- break;
- case Tag_CSKY_FPU_DENORMAL:
- READ_ULEB (val, p, end);
- if (val == 1)
- {
- printf (" Tag_CSKY_FPU_DENORMAL:\t");
- printf ("Needed\n");
- }
- break;
- case Tag_CSKY_FPU_Exception:
- READ_ULEB (val, p, end);
- if (val == 1)
- {
- printf (" Tag_CSKY_FPU_Exception:\t");
- printf ("Needed\n");
- }
- break;
- case Tag_CSKY_FPU_NUMBER_MODULE:
- printf (" Tag_CSKY_FPU_NUMBER_MODULE:\t");
- return display_tag_value (-1, p, end);
- case Tag_CSKY_FPU_HARDFP:
- printf (" Tag_CSKY_FPU_HARDFP:\t\t");
- READ_ULEB (val, p, end);
- if (val & VAL_CSKY_FPU_HARDFP_HALF)
- printf (" Half");
- if (val & VAL_CSKY_FPU_HARDFP_SINGLE)
- printf (" Single");
- if (val & VAL_CSKY_FPU_HARDFP_DOUBLE)
- printf (" Double");
- printf ("\n");
- break;
- default:
- return display_tag_value (tag, p, end);
- }
- return p;
-}
-
-static bool
-process_attributes (Filedata * filedata,
- const char * public_name,
- unsigned int proc_type,
- unsigned char * (* display_pub_attribute) (unsigned char *, const unsigned char * const),
- unsigned char * (* display_proc_gnu_attribute) (unsigned char *, unsigned int, const unsigned char * const))
-{
- Elf_Internal_Shdr * sect;
- unsigned i;
- bool res = true;
-
- /* Find the section header so that we get the size. */
- for (i = 0, sect = filedata->section_headers;
- i < filedata->file_header.e_shnum;
- i++, sect++)
- {
- unsigned char * contents;
- unsigned char * p;
-
- if (sect->sh_type != proc_type && sect->sh_type != SHT_GNU_ATTRIBUTES)
- continue;
-
- contents = (unsigned char *) get_data (NULL, filedata, sect->sh_offset, 1,
- sect->sh_size, _("attributes"));
- if (contents == NULL)
- {
- res = false;
- continue;
- }
-
- p = contents;
- /* The first character is the version of the attributes.
- Currently only version 1, (aka 'A') is recognised here. */
- if (*p != 'A')
- {
- printf (_("Unknown attributes version '%c'(%d) - expecting 'A'\n"), *p, *p);
- res = false;
- }
- else
- {
- uint64_t section_len;
-
- section_len = sect->sh_size - 1;
- p++;
-
- while (section_len > 0)
- {
- uint64_t attr_len;
- unsigned int namelen;
- bool public_section;
- bool gnu_section;
-
- if (section_len <= 4)
- {
- error (_("Tag section ends prematurely\n"));
- res = false;
- break;
- }
- attr_len = byte_get (p, 4);
- p += 4;
-
- if (attr_len > section_len)
- {
- error (_("Bad attribute length (%u > %u)\n"),
- (unsigned) attr_len, (unsigned) section_len);
- attr_len = section_len;
- res = false;
- }
- /* PR 17531: file: 001-101425-0.004 */
- else if (attr_len < 5)
- {
- error (_("Attribute length of %u is too small\n"), (unsigned) attr_len);
- res = false;
- break;
- }
-
- section_len -= attr_len;
- attr_len -= 4;
-
- namelen = strnlen ((char *) p, attr_len) + 1;
- if (namelen == 0 || namelen >= attr_len)
- {
- error (_("Corrupt attribute section name\n"));
- res = false;
- break;
- }
-
- printf (_("Attribute Section: "));
- print_symbol_name (INT_MAX, (const char *) p);
- putchar ('\n');
-
- if (public_name && streq ((char *) p, public_name))
- public_section = true;
- else
- public_section = false;
-
- if (streq ((char *) p, "gnu"))
- gnu_section = true;
- else
- gnu_section = false;
-
- p += namelen;
- attr_len -= namelen;
-
- while (attr_len > 0 && p < contents + sect->sh_size)
- {
- int tag;
- unsigned int val;
- uint64_t size;
- unsigned char * end;
-
- /* PR binutils/17531: Safe handling of corrupt files. */
- if (attr_len < 6)
- {
- error (_("Unused bytes at end of section\n"));
- res = false;
- section_len = 0;
- break;
- }
-
- tag = *(p++);
- size = byte_get (p, 4);
- if (size > attr_len)
- {
- error (_("Bad subsection length (%u > %u)\n"),
- (unsigned) size, (unsigned) attr_len);
- res = false;
- size = attr_len;
- }
- /* PR binutils/17531: Safe handling of corrupt files. */
- if (size < 6)
- {
- error (_("Bad subsection length (%u < 6)\n"),
- (unsigned) size);
- res = false;
- section_len = 0;
- break;
- }
-
- attr_len -= size;
- end = p + size - 1;
- assert (end <= contents + sect->sh_size);
- p += 4;
-
- switch (tag)
- {
- case 1:
- printf (_("File Attributes\n"));
- break;
- case 2:
- printf (_("Section Attributes:"));
- goto do_numlist;
- case 3:
- printf (_("Symbol Attributes:"));
- /* Fall through. */
- do_numlist:
- for (;;)
- {
- READ_ULEB (val, p, end);
- if (val == 0)
- break;
- printf (" %d", val);
- }
- printf ("\n");
- break;
- default:
- printf (_("Unknown tag: %d\n"), tag);
- public_section = false;
- break;
- }
-
- if (public_section && display_pub_attribute != NULL)
- {
- while (p < end)
- p = display_pub_attribute (p, end);
- assert (p == end);
- }
- else if (gnu_section && display_proc_gnu_attribute != NULL)
- {
- while (p < end)
- p = display_gnu_attribute (p,
- display_proc_gnu_attribute,
- end);
- assert (p == end);
- }
- else if (p < end)
- {
- printf (_(" Unknown attribute:\n"));
- display_raw_attribute (p, end);
- p = end;
- }
- else
- attr_len = 0;
- }
- }
- }
-
- free (contents);
- }
-
- return res;
-}
-
-/* DATA points to the contents of a MIPS GOT that starts at VMA PLTGOT.
- Print the Address, Access and Initial fields of an entry at VMA ADDR
- and return the VMA of the next entry, or -1 if there was a problem.
- Does not read from DATA_END or beyond. */
-
-static uint64_t
-print_mips_got_entry (unsigned char * data, uint64_t pltgot, uint64_t addr,
- unsigned char * data_end)
-{
- printf (" ");
- print_vma (addr, LONG_HEX);
- printf (" ");
- if (addr < pltgot + 0xfff0)
- printf ("%6d(gp)", (int) (addr - pltgot - 0x7ff0));
- else
- printf ("%10s", "");
- printf (" ");
- if (data == NULL)
- printf ("%*s", is_32bit_elf ? 8 : 16, _("<unknown>"));
- else
- {
- uint64_t entry;
- unsigned char * from = data + addr - pltgot;
-
- if (from + (is_32bit_elf ? 4 : 8) > data_end)
- {
- warn (_("MIPS GOT entry extends beyond the end of available data\n"));
- printf ("%*s", is_32bit_elf ? 8 : 16, _("<corrupt>"));
- return (uint64_t) -1;
- }
- else
- {
- entry = byte_get (data + addr - pltgot, is_32bit_elf ? 4 : 8);
- print_vma (entry, LONG_HEX);
- }
- }
- return addr + (is_32bit_elf ? 4 : 8);
-}
-
-/* DATA points to the contents of a MIPS PLT GOT that starts at VMA
- PLTGOT. Print the Address and Initial fields of an entry at VMA
- ADDR and return the VMA of the next entry. */
-
-static uint64_t
-print_mips_pltgot_entry (unsigned char * data, uint64_t pltgot, uint64_t addr)
-{
- printf (" ");
- print_vma (addr, LONG_HEX);
- printf (" ");
- if (data == NULL)
- printf ("%*s", is_32bit_elf ? 8 : 16, _("<unknown>"));
- else
- {
- uint64_t entry;
-
- entry = byte_get (data + addr - pltgot, is_32bit_elf ? 4 : 8);
- print_vma (entry, LONG_HEX);
- }
- return addr + (is_32bit_elf ? 4 : 8);
-}
-
-static void
-print_mips_ases (unsigned int mask)
-{
- if (mask & AFL_ASE_DSP)
- fputs ("\n\tDSP ASE", stdout);
- if (mask & AFL_ASE_DSPR2)
- fputs ("\n\tDSP R2 ASE", stdout);
- if (mask & AFL_ASE_DSPR3)
- fputs ("\n\tDSP R3 ASE", stdout);
- if (mask & AFL_ASE_EVA)
- fputs ("\n\tEnhanced VA Scheme", stdout);
- if (mask & AFL_ASE_MCU)
- fputs ("\n\tMCU (MicroController) ASE", stdout);
- if (mask & AFL_ASE_MDMX)
- fputs ("\n\tMDMX ASE", stdout);
- if (mask & AFL_ASE_MIPS3D)
- fputs ("\n\tMIPS-3D ASE", stdout);
- if (mask & AFL_ASE_MT)
- fputs ("\n\tMT ASE", stdout);
- if (mask & AFL_ASE_SMARTMIPS)
- fputs ("\n\tSmartMIPS ASE", stdout);
- if (mask & AFL_ASE_VIRT)
- fputs ("\n\tVZ ASE", stdout);
- if (mask & AFL_ASE_MSA)
- fputs ("\n\tMSA ASE", stdout);
- if (mask & AFL_ASE_MIPS16)
- fputs ("\n\tMIPS16 ASE", stdout);
- if (mask & AFL_ASE_MICROMIPS)
- fputs ("\n\tMICROMIPS ASE", stdout);
- if (mask & AFL_ASE_XPA)
- fputs ("\n\tXPA ASE", stdout);
- if (mask & AFL_ASE_MIPS16E2)
- fputs ("\n\tMIPS16e2 ASE", stdout);
- if (mask & AFL_ASE_CRC)
- fputs ("\n\tCRC ASE", stdout);
- if (mask & AFL_ASE_GINV)
- fputs ("\n\tGINV ASE", stdout);
- if (mask & AFL_ASE_LOONGSON_MMI)
- fputs ("\n\tLoongson MMI ASE", stdout);
- if (mask & AFL_ASE_LOONGSON_CAM)
- fputs ("\n\tLoongson CAM ASE", stdout);
- if (mask & AFL_ASE_LOONGSON_EXT)
- fputs ("\n\tLoongson EXT ASE", stdout);
- if (mask & AFL_ASE_LOONGSON_EXT2)
- fputs ("\n\tLoongson EXT2 ASE", stdout);
- if (mask == 0)
- fprintf (stdout, "\n\t%s", _("None"));
- else if ((mask & ~AFL_ASE_MASK) != 0)
- fprintf (stdout, "\n\t%s (%x)", _("Unknown"), mask & ~AFL_ASE_MASK);
-}
-
-static void
-print_mips_isa_ext (unsigned int isa_ext)
-{
- switch (isa_ext)
- {
- case 0:
- fputs (_("None"), stdout);
- break;
- case AFL_EXT_XLR:
- fputs ("RMI XLR", stdout);
- break;
- case AFL_EXT_OCTEON3:
- fputs ("Cavium Networks Octeon3", stdout);
- break;
- case AFL_EXT_OCTEON2:
- fputs ("Cavium Networks Octeon2", stdout);
- break;
- case AFL_EXT_OCTEONP:
- fputs ("Cavium Networks OcteonP", stdout);
- break;
- case AFL_EXT_OCTEON:
- fputs ("Cavium Networks Octeon", stdout);
- break;
- case AFL_EXT_5900:
- fputs ("Toshiba R5900", stdout);
- break;
- case AFL_EXT_4650:
- fputs ("MIPS R4650", stdout);
- break;
- case AFL_EXT_4010:
- fputs ("LSI R4010", stdout);
- break;
- case AFL_EXT_4100:
- fputs ("NEC VR4100", stdout);
- break;
- case AFL_EXT_3900:
- fputs ("Toshiba R3900", stdout);
- break;
- case AFL_EXT_10000:
- fputs ("MIPS R10000", stdout);
- break;
- case AFL_EXT_SB1:
- fputs ("Broadcom SB-1", stdout);
- break;
- case AFL_EXT_4111:
- fputs ("NEC VR4111/VR4181", stdout);
- break;
- case AFL_EXT_4120:
- fputs ("NEC VR4120", stdout);
- break;
- case AFL_EXT_5400:
- fputs ("NEC VR5400", stdout);
- break;
- case AFL_EXT_5500:
- fputs ("NEC VR5500", stdout);
- break;
- case AFL_EXT_LOONGSON_2E:
- fputs ("ST Microelectronics Loongson 2E", stdout);
- break;
- case AFL_EXT_LOONGSON_2F:
- fputs ("ST Microelectronics Loongson 2F", stdout);
- break;
- case AFL_EXT_INTERAPTIV_MR2:
- fputs ("Imagination interAptiv MR2", stdout);
- break;
- default:
- fprintf (stdout, "%s (%d)", _("Unknown"), isa_ext);
- }
-}
-
-static signed int
-get_mips_reg_size (int reg_size)
-{
- return (reg_size == AFL_REG_NONE) ? 0
- : (reg_size == AFL_REG_32) ? 32
- : (reg_size == AFL_REG_64) ? 64
- : (reg_size == AFL_REG_128) ? 128
- : -1;
-}
-
-static bool
-process_mips_specific (Filedata * filedata)
-{
- Elf_Internal_Dyn * entry;
- Elf_Internal_Shdr *sect = NULL;
- size_t liblist_offset = 0;
- size_t liblistno = 0;
- size_t conflictsno = 0;
- size_t options_offset = 0;
- size_t conflicts_offset = 0;
- size_t pltrelsz = 0;
- size_t pltrel = 0;
- uint64_t pltgot = 0;
- uint64_t mips_pltgot = 0;
- uint64_t jmprel = 0;
- uint64_t local_gotno = 0;
- uint64_t gotsym = 0;
- uint64_t symtabno = 0;
- bool res = true;
-
- if (! process_attributes (filedata, NULL, SHT_GNU_ATTRIBUTES, NULL,
- display_mips_gnu_attribute))
- res = false;
-
- sect = find_section (filedata, ".MIPS.abiflags");
-
- if (sect != NULL)
- {
- Elf_External_ABIFlags_v0 *abiflags_ext;
- Elf_Internal_ABIFlags_v0 abiflags_in;
-
- if (sizeof (Elf_External_ABIFlags_v0) != sect->sh_size)
- {
- error (_("Corrupt MIPS ABI Flags section.\n"));
- res = false;
- }
- else
- {
- abiflags_ext = get_data (NULL, filedata, sect->sh_offset, 1,
- sect->sh_size, _("MIPS ABI Flags section"));
- if (abiflags_ext)
- {
- abiflags_in.version = BYTE_GET (abiflags_ext->version);
- abiflags_in.isa_level = BYTE_GET (abiflags_ext->isa_level);
- abiflags_in.isa_rev = BYTE_GET (abiflags_ext->isa_rev);
- abiflags_in.gpr_size = BYTE_GET (abiflags_ext->gpr_size);
- abiflags_in.cpr1_size = BYTE_GET (abiflags_ext->cpr1_size);
- abiflags_in.cpr2_size = BYTE_GET (abiflags_ext->cpr2_size);
- abiflags_in.fp_abi = BYTE_GET (abiflags_ext->fp_abi);
- abiflags_in.isa_ext = BYTE_GET (abiflags_ext->isa_ext);
- abiflags_in.ases = BYTE_GET (abiflags_ext->ases);
- abiflags_in.flags1 = BYTE_GET (abiflags_ext->flags1);
- abiflags_in.flags2 = BYTE_GET (abiflags_ext->flags2);
-
- printf ("\nMIPS ABI Flags Version: %d\n", abiflags_in.version);
- printf ("\nISA: MIPS%d", abiflags_in.isa_level);
- if (abiflags_in.isa_rev > 1)
- printf ("r%d", abiflags_in.isa_rev);
- printf ("\nGPR size: %d",
- get_mips_reg_size (abiflags_in.gpr_size));
- printf ("\nCPR1 size: %d",
- get_mips_reg_size (abiflags_in.cpr1_size));
- printf ("\nCPR2 size: %d",
- get_mips_reg_size (abiflags_in.cpr2_size));
- fputs ("\nFP ABI: ", stdout);
- print_mips_fp_abi_value (abiflags_in.fp_abi);
- fputs ("ISA Extension: ", stdout);
- print_mips_isa_ext (abiflags_in.isa_ext);
- fputs ("\nASEs:", stdout);
- print_mips_ases (abiflags_in.ases);
- printf ("\nFLAGS 1: %8.8lx", abiflags_in.flags1);
- printf ("\nFLAGS 2: %8.8lx", abiflags_in.flags2);
- fputc ('\n', stdout);
- free (abiflags_ext);
- }
- }
- }
-
- /* We have a lot of special sections. Thanks SGI! */
- if (filedata->dynamic_section == NULL)
- {
- /* No dynamic information available. See if there is static GOT. */
- sect = find_section (filedata, ".got");
- if (sect != NULL)
- {
- unsigned char *data_end;
- unsigned char *data;
- uint64_t ent, end;
- int addr_size;
-
- pltgot = sect->sh_addr;
-
- ent = pltgot;
- addr_size = (is_32bit_elf ? 4 : 8);
- end = pltgot + sect->sh_size;
-
- data = (unsigned char *) get_data (NULL, filedata, sect->sh_offset,
- end - pltgot, 1,
- _("Global Offset Table data"));
- /* PR 12855: Null data is handled gracefully throughout. */
- data_end = data + (end - pltgot);
-
- printf (_("\nStatic GOT:\n"));
- printf (_(" Canonical gp value: "));
- print_vma (ent + 0x7ff0, LONG_HEX);
- printf ("\n\n");
-
- /* In a dynamic binary GOT[0] is reserved for the dynamic
- loader to store the lazy resolver pointer, however in
- a static binary it may well have been omitted and GOT
- reduced to a table of addresses.
- PR 21344: Check for the entry being fully available
- before fetching it. */
- if (data
- && data + ent - pltgot + addr_size <= data_end
- && byte_get (data + ent - pltgot, addr_size) == 0)
- {
- printf (_(" Reserved entries:\n"));
- printf (_(" %*s %10s %*s\n"),
- addr_size * 2, _("Address"), _("Access"),
- addr_size * 2, _("Value"));
- ent = print_mips_got_entry (data, pltgot, ent, data_end);
- printf ("\n");
- if (ent == (uint64_t) -1)
- goto sgot_print_fail;
-
- /* Check for the MSB of GOT[1] being set, identifying a
- GNU object. This entry will be used by some runtime
- loaders, to store the module pointer. Otherwise this
- is an ordinary local entry.
- PR 21344: Check for the entry being fully available
- before fetching it. */
- if (data
- && data + ent - pltgot + addr_size <= data_end
- && (byte_get (data + ent - pltgot, addr_size)
- >> (addr_size * 8 - 1)) != 0)
- {
- ent = print_mips_got_entry (data, pltgot, ent, data_end);
- printf ("\n");
- if (ent == (uint64_t) -1)
- goto sgot_print_fail;
- }
- printf ("\n");
- }
-
- if (data != NULL && ent < end)
- {
- printf (_(" Local entries:\n"));
- printf (" %*s %10s %*s\n",
- addr_size * 2, _("Address"), _("Access"),
- addr_size * 2, _("Value"));
- while (ent < end)
- {
- ent = print_mips_got_entry (data, pltgot, ent, data_end);
- printf ("\n");
- if (ent == (uint64_t) -1)
- goto sgot_print_fail;
- }
- printf ("\n");
- }
-
- sgot_print_fail:
- free (data);
- }
- return res;
- }
-
- for (entry = filedata->dynamic_section;
- /* PR 17531 file: 012-50589-0.004. */
- (entry < filedata->dynamic_section + filedata->dynamic_nent
- && entry->d_tag != DT_NULL);
- ++entry)
- switch (entry->d_tag)
- {
- case DT_MIPS_LIBLIST:
- liblist_offset
- = offset_from_vma (filedata, entry->d_un.d_val,
- liblistno * sizeof (Elf32_External_Lib));
- break;
- case DT_MIPS_LIBLISTNO:
- liblistno = entry->d_un.d_val;
- break;
- case DT_MIPS_OPTIONS:
- options_offset = offset_from_vma (filedata, entry->d_un.d_val, 0);
- break;
- case DT_MIPS_CONFLICT:
- conflicts_offset
- = offset_from_vma (filedata, entry->d_un.d_val,
- conflictsno * sizeof (Elf32_External_Conflict));
- break;
- case DT_MIPS_CONFLICTNO:
- conflictsno = entry->d_un.d_val;
- break;
- case DT_PLTGOT:
- pltgot = entry->d_un.d_ptr;
- break;
- case DT_MIPS_LOCAL_GOTNO:
- local_gotno = entry->d_un.d_val;
- break;
- case DT_MIPS_GOTSYM:
- gotsym = entry->d_un.d_val;
- break;
- case DT_MIPS_SYMTABNO:
- symtabno = entry->d_un.d_val;
- break;
- case DT_MIPS_PLTGOT:
- mips_pltgot = entry->d_un.d_ptr;
- break;
- case DT_PLTREL:
- pltrel = entry->d_un.d_val;
- break;
- case DT_PLTRELSZ:
- pltrelsz = entry->d_un.d_val;
- break;
- case DT_JMPREL:
- jmprel = entry->d_un.d_ptr;
- break;
- default:
- break;
- }
-
- if (liblist_offset != 0 && liblistno != 0 && do_dynamic)
- {
- Elf32_External_Lib * elib;
- size_t cnt;
-
- elib = (Elf32_External_Lib *) get_data (NULL, filedata, liblist_offset,
- sizeof (Elf32_External_Lib),
- liblistno,
- _("liblist section data"));
- if (elib)
- {
- printf (ngettext ("\nSection '.liblist' contains %zu entry:\n",
- "\nSection '.liblist' contains %zu entries:\n",
- liblistno),
- liblistno);
- fputs (_(" Library Time Stamp Checksum Version Flags\n"),
- stdout);
-
- for (cnt = 0; cnt < liblistno; ++cnt)
- {
- Elf32_Lib liblist;
- time_t atime;
- char timebuf[128];
- struct tm * tmp;
-
- liblist.l_name = BYTE_GET (elib[cnt].l_name);
- atime = BYTE_GET (elib[cnt].l_time_stamp);
- liblist.l_checksum = BYTE_GET (elib[cnt].l_checksum);
- liblist.l_version = BYTE_GET (elib[cnt].l_version);
- liblist.l_flags = BYTE_GET (elib[cnt].l_flags);
-
- tmp = gmtime (&atime);
- snprintf (timebuf, sizeof (timebuf),
- "%04u-%02u-%02uT%02u:%02u:%02u",
- tmp->tm_year + 1900, tmp->tm_mon + 1, tmp->tm_mday,
- tmp->tm_hour, tmp->tm_min, tmp->tm_sec);
-
- printf ("%3zu: ", cnt);
- if (valid_dynamic_name (filedata, liblist.l_name))
- print_symbol_name (20, get_dynamic_name (filedata, liblist.l_name));
- else
- printf (_("<corrupt: %9ld>"), liblist.l_name);
- printf (" %s %#10lx %-7ld", timebuf, liblist.l_checksum,
- liblist.l_version);
-
- if (liblist.l_flags == 0)
- puts (_(" NONE"));
- else
- {
- static const struct
- {
- const char * name;
- int bit;
- }
- l_flags_vals[] =
- {
- { " EXACT_MATCH", LL_EXACT_MATCH },
- { " IGNORE_INT_VER", LL_IGNORE_INT_VER },
- { " REQUIRE_MINOR", LL_REQUIRE_MINOR },
- { " EXPORTS", LL_EXPORTS },
- { " DELAY_LOAD", LL_DELAY_LOAD },
- { " DELTA", LL_DELTA }
- };
- int flags = liblist.l_flags;
- size_t fcnt;
-
- for (fcnt = 0; fcnt < ARRAY_SIZE (l_flags_vals); ++fcnt)
- if ((flags & l_flags_vals[fcnt].bit) != 0)
- {
- fputs (l_flags_vals[fcnt].name, stdout);
- flags ^= l_flags_vals[fcnt].bit;
- }
- if (flags != 0)
- printf (" %#x", (unsigned int) flags);
-
- puts ("");
- }
- }
-
- free (elib);
- }
- else
- res = false;
- }
-
- if (options_offset != 0)
- {
- Elf_External_Options * eopt;
- size_t offset;
- int cnt;
-
- /* Find the section header so that we get the size. */
- sect = find_section_by_type (filedata, SHT_MIPS_OPTIONS);
- /* PR 17533 file: 012-277276-0.004. */
- if (sect == NULL)
- {
- error (_("No MIPS_OPTIONS header found\n"));
- return false;
- }
- /* PR 24243 */
- if (sect->sh_size < sizeof (* eopt))
- {
- error (_("The MIPS options section is too small.\n"));
- return false;
- }
-
- eopt = (Elf_External_Options *) get_data (NULL, filedata, options_offset, 1,
- sect->sh_size, _("options"));
- if (eopt)
- {
- Elf_Internal_Options option;
-
- offset = cnt = 0;
- while (offset <= sect->sh_size - sizeof (* eopt))
- {
- Elf_External_Options * eoption;
- unsigned int optsize;
-
- eoption = (Elf_External_Options *) ((char *) eopt + offset);
-
- optsize = BYTE_GET (eoption->size);
-
- /* PR 17531: file: ffa0fa3b. */
- if (optsize < sizeof (* eopt)
- || optsize > sect->sh_size - offset)
- {
- error (_("Invalid size (%u) for MIPS option\n"),
- optsize);
- free (eopt);
- return false;
- }
- offset += optsize;
- ++cnt;
- }
-
- printf (ngettext ("\nSection '%s' contains %d entry:\n",
- "\nSection '%s' contains %d entries:\n",
- cnt),
- printable_section_name (filedata, sect), cnt);
-
- offset = 0;
- while (cnt-- > 0)
- {
- size_t len;
- Elf_External_Options * eoption;
-
- eoption = (Elf_External_Options *) ((char *) eopt + offset);
-
- option.kind = BYTE_GET (eoption->kind);
- option.size = BYTE_GET (eoption->size);
- option.section = BYTE_GET (eoption->section);
- option.info = BYTE_GET (eoption->info);
-
- switch (option.kind)
- {
- case ODK_NULL:
- /* This shouldn't happen. */
- printf (" NULL %" PRId16 " %" PRIx32,
- option.section, option.info);
- break;
-
- case ODK_REGINFO:
- printf (" REGINFO ");
- if (filedata->file_header.e_machine == EM_MIPS)
- {
- Elf32_External_RegInfo * ereg;
- Elf32_RegInfo reginfo;
-
- /* 32bit form. */
- if (option.size < (sizeof (Elf_External_Options)
- + sizeof (Elf32_External_RegInfo)))
- {
- printf (_("<corrupt>\n"));
- error (_("Truncated MIPS REGINFO option\n"));
- cnt = 0;
- break;
- }
-
- ereg = (Elf32_External_RegInfo *) (eoption + 1);
-
- reginfo.ri_gprmask = BYTE_GET (ereg->ri_gprmask);
- reginfo.ri_cprmask[0] = BYTE_GET (ereg->ri_cprmask[0]);
- reginfo.ri_cprmask[1] = BYTE_GET (ereg->ri_cprmask[1]);
- reginfo.ri_cprmask[2] = BYTE_GET (ereg->ri_cprmask[2]);
- reginfo.ri_cprmask[3] = BYTE_GET (ereg->ri_cprmask[3]);
- reginfo.ri_gp_value = BYTE_GET (ereg->ri_gp_value);
-
- printf ("GPR %08" PRIx32 " GP 0x%" PRIx32 "\n",
- reginfo.ri_gprmask, reginfo.ri_gp_value);
- printf (" "
- " CPR0 %08" PRIx32 " CPR1 %08" PRIx32
- " CPR2 %08" PRIx32 " CPR3 %08" PRIx32 "\n",
- reginfo.ri_cprmask[0], reginfo.ri_cprmask[1],
- reginfo.ri_cprmask[2], reginfo.ri_cprmask[3]);
- }
- else
- {
- /* 64 bit form. */
- Elf64_External_RegInfo * ereg;
- Elf64_Internal_RegInfo reginfo;
-
- if (option.size < (sizeof (Elf_External_Options)
- + sizeof (Elf64_External_RegInfo)))
- {
- printf (_("<corrupt>\n"));
- error (_("Truncated MIPS REGINFO option\n"));
- cnt = 0;
- break;
- }
-
- ereg = (Elf64_External_RegInfo *) (eoption + 1);
- reginfo.ri_gprmask = BYTE_GET (ereg->ri_gprmask);
- reginfo.ri_cprmask[0] = BYTE_GET (ereg->ri_cprmask[0]);
- reginfo.ri_cprmask[1] = BYTE_GET (ereg->ri_cprmask[1]);
- reginfo.ri_cprmask[2] = BYTE_GET (ereg->ri_cprmask[2]);
- reginfo.ri_cprmask[3] = BYTE_GET (ereg->ri_cprmask[3]);
- reginfo.ri_gp_value = BYTE_GET (ereg->ri_gp_value);
-
- printf ("GPR %08" PRIx32 " GP 0x%" PRIx64 "\n",
- reginfo.ri_gprmask, reginfo.ri_gp_value);
- printf (" "
- " CPR0 %08" PRIx32 " CPR1 %08" PRIx32
- " CPR2 %08" PRIx32 " CPR3 %08" PRIx32 "\n",
- reginfo.ri_cprmask[0], reginfo.ri_cprmask[1],
- reginfo.ri_cprmask[2], reginfo.ri_cprmask[3]);
- }
- offset += option.size;
- continue;
-
- case ODK_EXCEPTIONS:
- fputs (" EXCEPTIONS fpe_min(", stdout);
- process_mips_fpe_exception (option.info & OEX_FPU_MIN);
- fputs (") fpe_max(", stdout);
- process_mips_fpe_exception ((option.info & OEX_FPU_MAX) >> 8);
- fputs (")", stdout);
-
- if (option.info & OEX_PAGE0)
- fputs (" PAGE0", stdout);
- if (option.info & OEX_SMM)
- fputs (" SMM", stdout);
- if (option.info & OEX_FPDBUG)
- fputs (" FPDBUG", stdout);
- if (option.info & OEX_DISMISS)
- fputs (" DISMISS", stdout);
- break;
-
- case ODK_PAD:
- fputs (" PAD ", stdout);
- if (option.info & OPAD_PREFIX)
- fputs (" PREFIX", stdout);
- if (option.info & OPAD_POSTFIX)
- fputs (" POSTFIX", stdout);
- if (option.info & OPAD_SYMBOL)
- fputs (" SYMBOL", stdout);
- break;
-
- case ODK_HWPATCH:
- fputs (" HWPATCH ", stdout);
- if (option.info & OHW_R4KEOP)
- fputs (" R4KEOP", stdout);
- if (option.info & OHW_R8KPFETCH)
- fputs (" R8KPFETCH", stdout);
- if (option.info & OHW_R5KEOP)
- fputs (" R5KEOP", stdout);
- if (option.info & OHW_R5KCVTL)
- fputs (" R5KCVTL", stdout);
- break;
-
- case ODK_FILL:
- fputs (" FILL ", stdout);
- /* XXX Print content of info word? */
- break;
-
- case ODK_TAGS:
- fputs (" TAGS ", stdout);
- /* XXX Print content of info word? */
- break;
-
- case ODK_HWAND:
- fputs (" HWAND ", stdout);
- if (option.info & OHWA0_R4KEOP_CHECKED)
- fputs (" R4KEOP_CHECKED", stdout);
- if (option.info & OHWA0_R4KEOP_CLEAN)
- fputs (" R4KEOP_CLEAN", stdout);
- break;
-
- case ODK_HWOR:
- fputs (" HWOR ", stdout);
- if (option.info & OHWA0_R4KEOP_CHECKED)
- fputs (" R4KEOP_CHECKED", stdout);
- if (option.info & OHWA0_R4KEOP_CLEAN)
- fputs (" R4KEOP_CLEAN", stdout);
- break;
-
- case ODK_GP_GROUP:
- printf (" GP_GROUP %#06x self-contained %#06x",
- option.info & OGP_GROUP,
- (option.info & OGP_SELF) >> 16);
- break;
-
- case ODK_IDENT:
- printf (" IDENT %#06x self-contained %#06x",
- option.info & OGP_GROUP,
- (option.info & OGP_SELF) >> 16);
- break;
-
- default:
- /* This shouldn't happen. */
- printf (" %3d ??? %" PRId16 " %" PRIx32,
- option.kind, option.section, option.info);
- break;
- }
-
- len = sizeof (* eopt);
- while (len < option.size)
- {
- unsigned char datum = *((unsigned char *) eoption + len);
-
- if (ISPRINT (datum))
- printf ("%c", datum);
- else
- printf ("\\%03o", datum);
- len ++;
- }
- fputs ("\n", stdout);
-
- offset += option.size;
- }
- free (eopt);
- }
- else
- res = false;
- }
-
- if (conflicts_offset != 0 && conflictsno != 0)
- {
- Elf32_Conflict * iconf;
- size_t cnt;
-
- if (filedata->dynamic_symbols == NULL)
- {
- error (_("conflict list found without a dynamic symbol table\n"));
- return false;
- }
-
- /* PR 21345 - print a slightly more helpful error message
- if we are sure that the cmalloc will fail. */
- if (conflictsno > filedata->file_size / sizeof (* iconf))
- {
- error (_("Overlarge number of conflicts detected: %zx\n"),
- conflictsno);
- return false;
- }
-
- iconf = (Elf32_Conflict *) cmalloc (conflictsno, sizeof (* iconf));
- if (iconf == NULL)
- {
- error (_("Out of memory allocating space for dynamic conflicts\n"));
- return false;
- }
-
- if (is_32bit_elf)
- {
- Elf32_External_Conflict * econf32;
-
- econf32 = (Elf32_External_Conflict *)
- get_data (NULL, filedata, conflicts_offset,
- sizeof (*econf32), conflictsno, _("conflict"));
- if (!econf32)
- {
- free (iconf);
- return false;
- }
-
- for (cnt = 0; cnt < conflictsno; ++cnt)
- iconf[cnt] = BYTE_GET (econf32[cnt]);
-
- free (econf32);
- }
- else
- {
- Elf64_External_Conflict * econf64;
-
- econf64 = (Elf64_External_Conflict *)
- get_data (NULL, filedata, conflicts_offset,
- sizeof (*econf64), conflictsno, _("conflict"));
- if (!econf64)
- {
- free (iconf);
- return false;
- }
-
- for (cnt = 0; cnt < conflictsno; ++cnt)
- iconf[cnt] = BYTE_GET (econf64[cnt]);
-
- free (econf64);
- }
-
- printf (ngettext ("\nSection '.conflict' contains %zu entry:\n",
- "\nSection '.conflict' contains %zu entries:\n",
- conflictsno),
- conflictsno);
- puts (_(" Num: Index Value Name"));
-
- for (cnt = 0; cnt < conflictsno; ++cnt)
- {
- printf ("%5zu: %8lu ", cnt, iconf[cnt]);
-
- if (iconf[cnt] >= filedata->num_dynamic_syms)
- printf (_("<corrupt symbol index>"));
- else
- {
- Elf_Internal_Sym * psym;
-
- psym = & filedata->dynamic_symbols[iconf[cnt]];
- print_vma (psym->st_value, FULL_HEX);
- putchar (' ');
- if (valid_dynamic_name (filedata, psym->st_name))
- print_symbol_name (25, get_dynamic_name (filedata, psym->st_name));
- else
- printf (_("<corrupt: %14ld>"), psym->st_name);
- }
- putchar ('\n');
- }
-
- free (iconf);
- }
-
- if (pltgot != 0 && local_gotno != 0)
- {
- uint64_t ent, local_end, global_end;
- size_t i, offset;
- unsigned char * data;
- unsigned char * data_end;
- int addr_size;
-
- ent = pltgot;
- addr_size = (is_32bit_elf ? 4 : 8);
- local_end = pltgot + local_gotno * addr_size;
-
- /* PR binutils/17533 file: 012-111227-0.004 */
- if (symtabno < gotsym)
- {
- error (_("The GOT symbol offset (%" PRIu64
- ") is greater than the symbol table size (%" PRIu64 ")\n"),
- gotsym, symtabno);
- return false;
- }
-
- global_end = local_end + (symtabno - gotsym) * addr_size;
- /* PR 17531: file: 54c91a34. */
- if (global_end < local_end)
- {
- error (_("Too many GOT symbols: %" PRIu64 "\n"), symtabno);
- return false;
- }
-
- offset = offset_from_vma (filedata, pltgot, global_end - pltgot);
- data = (unsigned char *) get_data (NULL, filedata, offset,
- global_end - pltgot, 1,
- _("Global Offset Table data"));
- /* PR 12855: Null data is handled gracefully throughout. */
- data_end = data + (global_end - pltgot);
-
- printf (_("\nPrimary GOT:\n"));
- printf (_(" Canonical gp value: "));
- print_vma (pltgot + 0x7ff0, LONG_HEX);
- printf ("\n\n");
-
- printf (_(" Reserved entries:\n"));
- printf (_(" %*s %10s %*s Purpose\n"),
- addr_size * 2, _("Address"), _("Access"),
- addr_size * 2, _("Initial"));
- ent = print_mips_got_entry (data, pltgot, ent, data_end);
- printf (_(" Lazy resolver\n"));
- if (ent == (uint64_t) -1)
- goto got_print_fail;
-
- /* Check for the MSB of GOT[1] being set, denoting a GNU object.
- This entry will be used by some runtime loaders, to store the
- module pointer. Otherwise this is an ordinary local entry.
- PR 21344: Check for the entry being fully available before
- fetching it. */
- if (data
- && data + ent - pltgot + addr_size <= data_end
- && (byte_get (data + ent - pltgot, addr_size)
- >> (addr_size * 8 - 1)) != 0)
- {
- ent = print_mips_got_entry (data, pltgot, ent, data_end);
- printf (_(" Module pointer (GNU extension)\n"));
- if (ent == (uint64_t) -1)
- goto got_print_fail;
- }
- printf ("\n");
-
- if (data != NULL && ent < local_end)
- {
- printf (_(" Local entries:\n"));
- printf (" %*s %10s %*s\n",
- addr_size * 2, _("Address"), _("Access"),
- addr_size * 2, _("Initial"));
- while (ent < local_end)
- {
- ent = print_mips_got_entry (data, pltgot, ent, data_end);
- printf ("\n");
- if (ent == (uint64_t) -1)
- goto got_print_fail;
- }
- printf ("\n");
- }
-
- if (data != NULL && gotsym < symtabno)
- {
- int sym_width;
-
- printf (_(" Global entries:\n"));
- printf (" %*s %10s %*s %*s %-7s %3s %s\n",
- addr_size * 2, _("Address"),
- _("Access"),
- addr_size * 2, _("Initial"),
- addr_size * 2, _("Sym.Val."),
- _("Type"),
- /* Note for translators: "Ndx" = abbreviated form of "Index". */
- _("Ndx"), _("Name"));
-
- sym_width = (is_32bit_elf ? 80 : 160) - 28 - addr_size * 6 - 1;
-
- for (i = gotsym; i < symtabno; i++)
- {
- ent = print_mips_got_entry (data, pltgot, ent, data_end);
- printf (" ");
-
- if (filedata->dynamic_symbols == NULL)
- printf (_("<no dynamic symbols>"));
- else if (i < filedata->num_dynamic_syms)
- {
- Elf_Internal_Sym * psym = filedata->dynamic_symbols + i;
-
- print_vma (psym->st_value, LONG_HEX);
- printf (" %-7s ", get_symbol_type (filedata, ELF_ST_TYPE (psym->st_info)));
-
- bool is_special;
- const char * s = printable_section_name_from_index (filedata, psym->st_shndx, & is_special);
- if (is_special)
- printf ("%3s ", s);
- else
- printf ("%3u ", psym->st_shndx);
-
- if (valid_dynamic_name (filedata, psym->st_name))
- print_symbol_name (sym_width,
- get_dynamic_name (filedata, psym->st_name));
- else
- printf (_("<corrupt: %14ld>"), psym->st_name);
- }
- else
- printf (_("<symbol index %zu exceeds number of dynamic symbols>"),
- i);
-
- printf ("\n");
- if (ent == (uint64_t) -1)
- break;
- }
- printf ("\n");
- }
-
- got_print_fail:
- free (data);
- }
-
- if (mips_pltgot != 0 && jmprel != 0 && pltrel != 0 && pltrelsz != 0)
- {
- uint64_t ent, end;
- uint64_t offset, rel_offset;
- uint64_t count, i;
- unsigned char * data;
- int addr_size, sym_width;
- Elf_Internal_Rela * rels;
-
- rel_offset = offset_from_vma (filedata, jmprel, pltrelsz);
- if (pltrel == DT_RELA)
- {
- if (!slurp_rela_relocs (filedata, rel_offset, pltrelsz, &rels, &count))
- return false;
- }
- else
- {
- if (!slurp_rel_relocs (filedata, rel_offset, pltrelsz, &rels, &count))
- return false;
- }
-
- ent = mips_pltgot;
- addr_size = (is_32bit_elf ? 4 : 8);
- end = mips_pltgot + (2 + count) * addr_size;
-
- offset = offset_from_vma (filedata, mips_pltgot, end - mips_pltgot);
- data = (unsigned char *) get_data (NULL, filedata, offset, end - mips_pltgot,
- 1, _("Procedure Linkage Table data"));
- if (data == NULL)
- {
- free (rels);
- return false;
- }
-
- printf ("\nPLT GOT:\n\n");
- printf (_(" Reserved entries:\n"));
- printf (_(" %*s %*s Purpose\n"),
- addr_size * 2, _("Address"), addr_size * 2, _("Initial"));
- ent = print_mips_pltgot_entry (data, mips_pltgot, ent);
- printf (_(" PLT lazy resolver\n"));
- ent = print_mips_pltgot_entry (data, mips_pltgot, ent);
- printf (_(" Module pointer\n"));
- printf ("\n");
-
- printf (_(" Entries:\n"));
- printf (" %*s %*s %*s %-7s %3s %s\n",
- addr_size * 2, _("Address"),
- addr_size * 2, _("Initial"),
- addr_size * 2, _("Sym.Val."), _("Type"), _("Ndx"), _("Name"));
- sym_width = (is_32bit_elf ? 80 : 160) - 17 - addr_size * 6 - 1;
- for (i = 0; i < count; i++)
- {
- uint64_t idx = get_reloc_symindex (rels[i].r_info);
-
- ent = print_mips_pltgot_entry (data, mips_pltgot, ent);
- printf (" ");
-
- if (idx >= filedata->num_dynamic_syms)
- printf (_("<corrupt symbol index: %" PRIu64 ">"), idx);
- else
- {
- Elf_Internal_Sym * psym = filedata->dynamic_symbols + idx;
-
- print_vma (psym->st_value, LONG_HEX);
- printf (" %-7s %3s ",
- get_symbol_type (filedata, ELF_ST_TYPE (psym->st_info)),
- printable_section_name_from_index (filedata, psym->st_shndx, NULL));
- if (valid_dynamic_name (filedata, psym->st_name))
- print_symbol_name (sym_width,
- get_dynamic_name (filedata, psym->st_name));
- else
- printf (_("<corrupt: %14ld>"), psym->st_name);
- }
- printf ("\n");
- }
- printf ("\n");
-
- free (data);
- free (rels);
- }
-
- return res;
-}
-
-static bool
-process_nds32_specific (Filedata * filedata)
-{
- Elf_Internal_Shdr *sect = NULL;
-
- sect = find_section (filedata, ".nds32_e_flags");
- if (sect != NULL && sect->sh_size >= 4)
- {
- unsigned char *buf;
- unsigned int flag;
-
- printf ("\nNDS32 elf flags section:\n");
- buf = get_data (NULL, filedata, sect->sh_offset, 1, 4,
- _("NDS32 elf flags section"));
-
- if (buf == NULL)
- return false;
-
- flag = byte_get (buf, 4);
- free (buf);
- switch (flag & 0x3)
- {
- case 0:
- printf ("(VEC_SIZE):\tNo entry.\n");
- break;
- case 1:
- printf ("(VEC_SIZE):\t4 bytes\n");
- break;
- case 2:
- printf ("(VEC_SIZE):\t16 bytes\n");
- break;
- case 3:
- printf ("(VEC_SIZE):\treserved\n");
- break;
- }
- }
-
- return true;
-}
-
-static bool
-process_gnu_liblist (Filedata * filedata)
-{
- Elf_Internal_Shdr * section;
- Elf_Internal_Shdr * string_sec;
- Elf32_External_Lib * elib;
- char * strtab;
- size_t strtab_size;
- size_t cnt;
- uint64_t num_liblist;
- unsigned i;
- bool res = true;
-
- if (! do_arch)
- return true;
-
- for (i = 0, section = filedata->section_headers;
- i < filedata->file_header.e_shnum;
- i++, section++)
- {
- switch (section->sh_type)
- {
- case SHT_GNU_LIBLIST:
- if (section->sh_link >= filedata->file_header.e_shnum)
- break;
-
- elib = (Elf32_External_Lib *)
- get_data (NULL, filedata, section->sh_offset, 1, section->sh_size,
- _("liblist section data"));
-
- if (elib == NULL)
- {
- res = false;
- break;
- }
-
- string_sec = filedata->section_headers + section->sh_link;
- strtab = (char *) get_data (NULL, filedata, string_sec->sh_offset, 1,
- string_sec->sh_size,
- _("liblist string table"));
- if (strtab == NULL
- || section->sh_entsize != sizeof (Elf32_External_Lib))
- {
- free (elib);
- free (strtab);
- res = false;
- break;
- }
- strtab_size = string_sec->sh_size;
-
- num_liblist = section->sh_size / sizeof (Elf32_External_Lib);
- printf (ngettext ("\nLibrary list section '%s' contains %" PRIu64
- " entries:\n",
- "\nLibrary list section '%s' contains %" PRIu64
- " entries:\n",
- num_liblist),
- printable_section_name (filedata, section),
- num_liblist);
-
- puts (_(" Library Time Stamp Checksum Version Flags"));
-
- for (cnt = 0; cnt < section->sh_size / sizeof (Elf32_External_Lib);
- ++cnt)
- {
- Elf32_Lib liblist;
- time_t atime;
- char timebuf[128];
- struct tm * tmp;
-
- liblist.l_name = BYTE_GET (elib[cnt].l_name);
- atime = BYTE_GET (elib[cnt].l_time_stamp);
- liblist.l_checksum = BYTE_GET (elib[cnt].l_checksum);
- liblist.l_version = BYTE_GET (elib[cnt].l_version);
- liblist.l_flags = BYTE_GET (elib[cnt].l_flags);
-
- tmp = gmtime (&atime);
- snprintf (timebuf, sizeof (timebuf),
- "%04u-%02u-%02uT%02u:%02u:%02u",
- tmp->tm_year + 1900, tmp->tm_mon + 1, tmp->tm_mday,
- tmp->tm_hour, tmp->tm_min, tmp->tm_sec);
-
- printf ("%3zu: ", cnt);
- if (do_wide)
- printf ("%-20s", liblist.l_name < strtab_size
- ? strtab + liblist.l_name : _("<corrupt>"));
- else
- printf ("%-20.20s", liblist.l_name < strtab_size
- ? strtab + liblist.l_name : _("<corrupt>"));
- printf (" %s %#010lx %-7ld %-7ld\n", timebuf, liblist.l_checksum,
- liblist.l_version, liblist.l_flags);
- }
-
- free (elib);
- free (strtab);
- }
- }
-
- return res;
-}
-
-static const char *
-get_note_type (Filedata * filedata, unsigned e_type)
-{
- static char buff[64];
-
- if (filedata->file_header.e_type == ET_CORE)
- switch (e_type)
- {
- case NT_AUXV:
- return _("NT_AUXV (auxiliary vector)");
- case NT_PRSTATUS:
- return _("NT_PRSTATUS (prstatus structure)");
- case NT_FPREGSET:
- return _("NT_FPREGSET (floating point registers)");
- case NT_PRPSINFO:
- return _("NT_PRPSINFO (prpsinfo structure)");
- case NT_TASKSTRUCT:
- return _("NT_TASKSTRUCT (task structure)");
- case NT_GDB_TDESC:
- return _("NT_GDB_TDESC (GDB XML target description)");
- case NT_PRXFPREG:
- return _("NT_PRXFPREG (user_xfpregs structure)");
- case NT_PPC_VMX:
- return _("NT_PPC_VMX (ppc Altivec registers)");
- case NT_PPC_VSX:
- return _("NT_PPC_VSX (ppc VSX registers)");
- case NT_PPC_TAR:
- return _("NT_PPC_TAR (ppc TAR register)");
- case NT_PPC_PPR:
- return _("NT_PPC_PPR (ppc PPR register)");
- case NT_PPC_DSCR:
- return _("NT_PPC_DSCR (ppc DSCR register)");
- case NT_PPC_EBB:
- return _("NT_PPC_EBB (ppc EBB registers)");
- case NT_PPC_PMU:
- return _("NT_PPC_PMU (ppc PMU registers)");
- case NT_PPC_TM_CGPR:
- return _("NT_PPC_TM_CGPR (ppc checkpointed GPR registers)");
- case NT_PPC_TM_CFPR:
- return _("NT_PPC_TM_CFPR (ppc checkpointed floating point registers)");
- case NT_PPC_TM_CVMX:
- return _("NT_PPC_TM_CVMX (ppc checkpointed Altivec registers)");
- case NT_PPC_TM_CVSX:
- return _("NT_PPC_TM_CVSX (ppc checkpointed VSX registers)");
- case NT_PPC_TM_SPR:
- return _("NT_PPC_TM_SPR (ppc TM special purpose registers)");
- case NT_PPC_TM_CTAR:
- return _("NT_PPC_TM_CTAR (ppc checkpointed TAR register)");
- case NT_PPC_TM_CPPR:
- return _("NT_PPC_TM_CPPR (ppc checkpointed PPR register)");
- case NT_PPC_TM_CDSCR:
- return _("NT_PPC_TM_CDSCR (ppc checkpointed DSCR register)");
- case NT_386_TLS:
- return _("NT_386_TLS (x86 TLS information)");
- case NT_386_IOPERM:
- return _("NT_386_IOPERM (x86 I/O permissions)");
- case NT_X86_XSTATE:
- return _("NT_X86_XSTATE (x86 XSAVE extended state)");
- case NT_X86_CET:
- return _("NT_X86_CET (x86 CET state)");
- case NT_X86_SHSTK:
- return _("NT_X86_SHSTK (x86 SHSTK state)");
- case NT_S390_HIGH_GPRS:
- return _("NT_S390_HIGH_GPRS (s390 upper register halves)");
- case NT_S390_TIMER:
- return _("NT_S390_TIMER (s390 timer register)");
- case NT_S390_TODCMP:
- return _("NT_S390_TODCMP (s390 TOD comparator register)");
- case NT_S390_TODPREG:
- return _("NT_S390_TODPREG (s390 TOD programmable register)");
- case NT_S390_CTRS:
- return _("NT_S390_CTRS (s390 control registers)");
- case NT_S390_PREFIX:
- return _("NT_S390_PREFIX (s390 prefix register)");
- case NT_S390_LAST_BREAK:
- return _("NT_S390_LAST_BREAK (s390 last breaking event address)");
- case NT_S390_SYSTEM_CALL:
- return _("NT_S390_SYSTEM_CALL (s390 system call restart data)");
- case NT_S390_TDB:
- return _("NT_S390_TDB (s390 transaction diagnostic block)");
- case NT_S390_VXRS_LOW:
- return _("NT_S390_VXRS_LOW (s390 vector registers 0-15 upper half)");
- case NT_S390_VXRS_HIGH:
- return _("NT_S390_VXRS_HIGH (s390 vector registers 16-31)");
- case NT_S390_GS_CB:
- return _("NT_S390_GS_CB (s390 guarded-storage registers)");
- case NT_S390_GS_BC:
- return _("NT_S390_GS_BC (s390 guarded-storage broadcast control)");
- case NT_ARM_VFP:
- return _("NT_ARM_VFP (arm VFP registers)");
- case NT_ARM_TLS:
- return _("NT_ARM_TLS (AArch TLS registers)");
- case NT_ARM_HW_BREAK:
- return _("NT_ARM_HW_BREAK (AArch hardware breakpoint registers)");
- case NT_ARM_HW_WATCH:
- return _("NT_ARM_HW_WATCH (AArch hardware watchpoint registers)");
- case NT_ARM_SYSTEM_CALL:
- return _("NT_ARM_SYSTEM_CALL (AArch system call number)");
- case NT_ARM_SVE:
- return _("NT_ARM_SVE (AArch SVE registers)");
- case NT_ARM_PAC_MASK:
- return _("NT_ARM_PAC_MASK (AArch pointer authentication code masks)");
- case NT_ARM_PACA_KEYS:
- return _("NT_ARM_PACA_KEYS (ARM pointer authentication address keys)");
- case NT_ARM_PACG_KEYS:
- return _("NT_ARM_PACG_KEYS (ARM pointer authentication generic keys)");
- case NT_ARM_TAGGED_ADDR_CTRL:
- return _("NT_ARM_TAGGED_ADDR_CTRL (AArch tagged address control)");
- case NT_ARM_SSVE:
- return _("NT_ARM_SSVE (AArch64 streaming SVE registers)");
- case NT_ARM_ZA:
- return _("NT_ARM_ZA (AArch64 SME ZA register)");
- case NT_ARM_ZT:
- return _("NT_ARM_ZT (AArch64 SME2 ZT registers)");
- case NT_ARM_PAC_ENABLED_KEYS:
- return _("NT_ARM_PAC_ENABLED_KEYS (AArch64 pointer authentication enabled keys)");
- case NT_ARC_V2:
- return _("NT_ARC_V2 (ARC HS accumulator/extra registers)");
- case NT_RISCV_CSR:
- return _("NT_RISCV_CSR (RISC-V control and status registers)");
- case NT_PSTATUS:
- return _("NT_PSTATUS (pstatus structure)");
- case NT_FPREGS:
- return _("NT_FPREGS (floating point registers)");
- case NT_PSINFO:
- return _("NT_PSINFO (psinfo structure)");
- case NT_LWPSTATUS:
- return _("NT_LWPSTATUS (lwpstatus_t structure)");
- case NT_LWPSINFO:
- return _("NT_LWPSINFO (lwpsinfo_t structure)");
- case NT_WIN32PSTATUS:
- return _("NT_WIN32PSTATUS (win32_pstatus structure)");
- case NT_SIGINFO:
- return _("NT_SIGINFO (siginfo_t data)");
- case NT_FILE:
- return _("NT_FILE (mapped files)");
- default:
- break;
- }
- else
- switch (e_type)
- {
- case NT_VERSION:
- return _("NT_VERSION (version)");
- case NT_ARCH:
- return _("NT_ARCH (architecture)");
- case NT_GNU_BUILD_ATTRIBUTE_OPEN:
- return _("OPEN");
- case NT_GNU_BUILD_ATTRIBUTE_FUNC:
- return _("func");
- case NT_GO_BUILDID:
- return _("GO BUILDID");
- case FDO_PACKAGING_METADATA:
- return _("FDO_PACKAGING_METADATA");
- case FDO_DLOPEN_METADATA:
- return _("FDO_DLOPEN_METADATA");
- default:
- break;
- }
-
- snprintf (buff, sizeof (buff), _("Unknown note type: (0x%08x)"), e_type);
- return buff;
-}
-
-static bool
-print_core_note (Elf_Internal_Note *pnote)
-{
- unsigned int addr_size = is_32bit_elf ? 4 : 8;
- uint64_t count, page_size;
- unsigned char *descdata, *filenames, *descend;
-
- if (pnote->type != NT_FILE)
- {
- if (do_wide)
- printf ("\n");
- return true;
- }
-
- if (pnote->descsz < 2 * addr_size)
- {
- error (_(" Malformed note - too short for header\n"));
- return false;
- }
-
- descdata = (unsigned char *) pnote->descdata;
- descend = descdata + pnote->descsz;
-
- if (descdata[pnote->descsz - 1] != '\0')
- {
- error (_(" Malformed note - does not end with \\0\n"));
- return false;
- }
-
- count = byte_get (descdata, addr_size);
- descdata += addr_size;
-
- page_size = byte_get (descdata, addr_size);
- descdata += addr_size;
-
- if (count > ((uint64_t) -1 - 2 * addr_size) / (3 * addr_size)
- || pnote->descsz < 2 * addr_size + count * 3 * addr_size)
- {
- error (_(" Malformed note - too short for supplied file count\n"));
- return false;
- }
-
- printf (_(" Page size: "));
- print_vma (page_size, DEC);
- printf ("\n");
-
- printf (_(" %*s%*s%*s\n"),
- (int) (2 + 2 * addr_size), _("Start"),
- (int) (4 + 2 * addr_size), _("End"),
- (int) (4 + 2 * addr_size), _("Page Offset"));
- filenames = descdata + count * 3 * addr_size;
- while (count-- > 0)
- {
- uint64_t start, end, file_ofs;
-
- if (filenames == descend)
- {
- error (_(" Malformed note - filenames end too early\n"));
- return false;
- }
-
- start = byte_get (descdata, addr_size);
- descdata += addr_size;
- end = byte_get (descdata, addr_size);
- descdata += addr_size;
- file_ofs = byte_get (descdata, addr_size);
- descdata += addr_size;
-
- printf (" ");
- print_vma (start, FULL_HEX);
- printf (" ");
- print_vma (end, FULL_HEX);
- printf (" ");
- print_vma (file_ofs, FULL_HEX);
- printf ("\n %s\n", filenames);
-
- filenames += 1 + strlen ((char *) filenames);
- }
-
- return true;
-}
-
-static const char *
-get_gnu_elf_note_type (unsigned e_type)
-{
- /* NB/ Keep this switch statement in sync with print_gnu_note (). */
- switch (e_type)
- {
- case NT_GNU_ABI_TAG:
- return _("NT_GNU_ABI_TAG (ABI version tag)");
- case NT_GNU_HWCAP:
- return _("NT_GNU_HWCAP (DSO-supplied software HWCAP info)");
- case NT_GNU_BUILD_ID:
- return _("NT_GNU_BUILD_ID (unique build ID bitstring)");
- case NT_GNU_GOLD_VERSION:
- return _("NT_GNU_GOLD_VERSION (gold version)");
- case NT_GNU_PROPERTY_TYPE_0:
- return _("NT_GNU_PROPERTY_TYPE_0");
- case NT_GNU_BUILD_ATTRIBUTE_OPEN:
- return _("NT_GNU_BUILD_ATTRIBUTE_OPEN");
- case NT_GNU_BUILD_ATTRIBUTE_FUNC:
- return _("NT_GNU_BUILD_ATTRIBUTE_FUNC");
- default:
- {
- static char buff[64];
-
- snprintf (buff, sizeof (buff), _("Unknown note type: (0x%08x)"), e_type);
- return buff;
- }
- }
-}
-
-static void
-decode_x86_compat_isa (unsigned int bitmask)
-{
- while (bitmask)
- {
- unsigned int bit = bitmask & (- bitmask);
-
- bitmask &= ~ bit;
- switch (bit)
- {
- case GNU_PROPERTY_X86_COMPAT_ISA_1_486:
- printf ("i486");
- break;
- case GNU_PROPERTY_X86_COMPAT_ISA_1_586:
- printf ("586");
- break;
- case GNU_PROPERTY_X86_COMPAT_ISA_1_686:
- printf ("686");
- break;
- case GNU_PROPERTY_X86_COMPAT_ISA_1_SSE:
- printf ("SSE");
- break;
- case GNU_PROPERTY_X86_COMPAT_ISA_1_SSE2:
- printf ("SSE2");
- break;
- case GNU_PROPERTY_X86_COMPAT_ISA_1_SSE3:
- printf ("SSE3");
- break;
- case GNU_PROPERTY_X86_COMPAT_ISA_1_SSSE3:
- printf ("SSSE3");
- break;
- case GNU_PROPERTY_X86_COMPAT_ISA_1_SSE4_1:
- printf ("SSE4_1");
- break;
- case GNU_PROPERTY_X86_COMPAT_ISA_1_SSE4_2:
- printf ("SSE4_2");
- break;
- case GNU_PROPERTY_X86_COMPAT_ISA_1_AVX:
- printf ("AVX");
- break;
- case GNU_PROPERTY_X86_COMPAT_ISA_1_AVX2:
- printf ("AVX2");
- break;
- case GNU_PROPERTY_X86_COMPAT_ISA_1_AVX512F:
- printf ("AVX512F");
- break;
- case GNU_PROPERTY_X86_COMPAT_ISA_1_AVX512CD:
- printf ("AVX512CD");
- break;
- case GNU_PROPERTY_X86_COMPAT_ISA_1_AVX512ER:
- printf ("AVX512ER");
- break;
- case GNU_PROPERTY_X86_COMPAT_ISA_1_AVX512PF:
- printf ("AVX512PF");
- break;
- case GNU_PROPERTY_X86_COMPAT_ISA_1_AVX512VL:
- printf ("AVX512VL");
- break;
- case GNU_PROPERTY_X86_COMPAT_ISA_1_AVX512DQ:
- printf ("AVX512DQ");
- break;
- case GNU_PROPERTY_X86_COMPAT_ISA_1_AVX512BW:
- printf ("AVX512BW");
- break;
- default:
- printf (_("<unknown: %x>"), bit);
- break;
- }
- if (bitmask)
- printf (", ");
- }
-}
-
-static void
-decode_x86_compat_2_isa (unsigned int bitmask)
-{
- if (!bitmask)
- {
- printf (_("<None>"));
- return;
- }
-
- while (bitmask)
- {
- unsigned int bit = bitmask & (- bitmask);
-
- bitmask &= ~ bit;
- switch (bit)
- {
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_CMOV:
- printf ("CMOV");
- break;
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_SSE:
- printf ("SSE");
- break;
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_SSE2:
- printf ("SSE2");
- break;
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_SSE3:
- printf ("SSE3");
- break;
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_SSSE3:
- printf ("SSSE3");
- break;
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_SSE4_1:
- printf ("SSE4_1");
- break;
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_SSE4_2:
- printf ("SSE4_2");
- break;
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_AVX:
- printf ("AVX");
- break;
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_AVX2:
- printf ("AVX2");
- break;
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_FMA:
- printf ("FMA");
- break;
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_AVX512F:
- printf ("AVX512F");
- break;
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_AVX512CD:
- printf ("AVX512CD");
- break;
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_AVX512ER:
- printf ("AVX512ER");
- break;
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_AVX512PF:
- printf ("AVX512PF");
- break;
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_AVX512VL:
- printf ("AVX512VL");
- break;
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_AVX512DQ:
- printf ("AVX512DQ");
- break;
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_AVX512BW:
- printf ("AVX512BW");
- break;
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_AVX512_4FMAPS:
- printf ("AVX512_4FMAPS");
- break;
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_AVX512_4VNNIW:
- printf ("AVX512_4VNNIW");
- break;
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_AVX512_BITALG:
- printf ("AVX512_BITALG");
- break;
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_AVX512_IFMA:
- printf ("AVX512_IFMA");
- break;
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_AVX512_VBMI:
- printf ("AVX512_VBMI");
- break;
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_AVX512_VBMI2:
- printf ("AVX512_VBMI2");
- break;
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_AVX512_VNNI:
- printf ("AVX512_VNNI");
- break;
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_AVX512_BF16:
- printf ("AVX512_BF16");
- break;
- default:
- printf (_("<unknown: %x>"), bit);
- break;
- }
- if (bitmask)
- printf (", ");
- }
-}
-
-static const char *
-get_amdgpu_elf_note_type (unsigned int e_type)
-{
- switch (e_type)
- {
- case NT_AMDGPU_METADATA:
- return _("NT_AMDGPU_METADATA (code object metadata)");
- default:
- {
- static char buf[64];
- snprintf (buf, sizeof (buf), _("Unknown note type: (0x%08x)"), e_type);
- return buf;
- }
- }
-}
-
-static void
-decode_x86_isa (unsigned int bitmask)
-{
- while (bitmask)
- {
- unsigned int bit = bitmask & (- bitmask);
-
- bitmask &= ~ bit;
- switch (bit)
- {
- case GNU_PROPERTY_X86_ISA_1_BASELINE:
- printf ("x86-64-baseline");
- break;
- case GNU_PROPERTY_X86_ISA_1_V2:
- printf ("x86-64-v2");
- break;
- case GNU_PROPERTY_X86_ISA_1_V3:
- printf ("x86-64-v3");
- break;
- case GNU_PROPERTY_X86_ISA_1_V4:
- printf ("x86-64-v4");
- break;
- default:
- printf (_("<unknown: %x>"), bit);
- break;
- }
- if (bitmask)
- printf (", ");
- }
-}
-
-static void
-decode_x86_feature_1 (unsigned int bitmask)
-{
- if (!bitmask)
- {
- printf (_("<None>"));
- return;
- }
-
- while (bitmask)
- {
- unsigned int bit = bitmask & (- bitmask);
-
- bitmask &= ~ bit;
- switch (bit)
- {
- case GNU_PROPERTY_X86_FEATURE_1_IBT:
- printf ("IBT");
- break;
- case GNU_PROPERTY_X86_FEATURE_1_SHSTK:
- printf ("SHSTK");
- break;
- case GNU_PROPERTY_X86_FEATURE_1_LAM_U48:
- printf ("LAM_U48");
- break;
- case GNU_PROPERTY_X86_FEATURE_1_LAM_U57:
- printf ("LAM_U57");
- break;
- default:
- printf (_("<unknown: %x>"), bit);
- break;
- }
- if (bitmask)
- printf (", ");
- }
-}
-
-static void
-decode_x86_feature_2 (unsigned int bitmask)
-{
- if (!bitmask)
- {
- printf (_("<None>"));
- return;
- }
-
- while (bitmask)
- {
- unsigned int bit = bitmask & (- bitmask);
-
- bitmask &= ~ bit;
- switch (bit)
- {
- case GNU_PROPERTY_X86_FEATURE_2_X86:
- printf ("x86");
- break;
- case GNU_PROPERTY_X86_FEATURE_2_X87:
- printf ("x87");
- break;
- case GNU_PROPERTY_X86_FEATURE_2_MMX:
- printf ("MMX");
- break;
- case GNU_PROPERTY_X86_FEATURE_2_XMM:
- printf ("XMM");
- break;
- case GNU_PROPERTY_X86_FEATURE_2_YMM:
- printf ("YMM");
- break;
- case GNU_PROPERTY_X86_FEATURE_2_ZMM:
- printf ("ZMM");
- break;
- case GNU_PROPERTY_X86_FEATURE_2_TMM:
- printf ("TMM");
- break;
- case GNU_PROPERTY_X86_FEATURE_2_MASK:
- printf ("MASK");
- break;
- case GNU_PROPERTY_X86_FEATURE_2_FXSR:
- printf ("FXSR");
- break;
- case GNU_PROPERTY_X86_FEATURE_2_XSAVE:
- printf ("XSAVE");
- break;
- case GNU_PROPERTY_X86_FEATURE_2_XSAVEOPT:
- printf ("XSAVEOPT");
- break;
- case GNU_PROPERTY_X86_FEATURE_2_XSAVEC:
- printf ("XSAVEC");
- break;
- default:
- printf (_("<unknown: %x>"), bit);
- break;
- }
- if (bitmask)
- printf (", ");
- }
-}
-
-static void
-decode_aarch64_feature_1_and (unsigned int bitmask)
-{
- while (bitmask)
- {
- unsigned int bit = bitmask & (- bitmask);
-
- bitmask &= ~ bit;
- switch (bit)
- {
- case GNU_PROPERTY_AARCH64_FEATURE_1_BTI:
- printf ("BTI");
- break;
-
- case GNU_PROPERTY_AARCH64_FEATURE_1_PAC:
- printf ("PAC");
- break;
-
- default:
- printf (_("<unknown: %x>"), bit);
- break;
- }
- if (bitmask)
- printf (", ");
- }
-}
-
-static void
-decode_1_needed (unsigned int bitmask)
-{
- while (bitmask)
- {
- unsigned int bit = bitmask & (- bitmask);
-
- bitmask &= ~ bit;
- switch (bit)
- {
- case GNU_PROPERTY_1_NEEDED_INDIRECT_EXTERN_ACCESS:
- printf ("indirect external access");
- break;
- default:
- printf (_("<unknown: %x>"), bit);
- break;
- }
- if (bitmask)
- printf (", ");
- }
-}
-
-static void
-print_gnu_property_note (Filedata * filedata, Elf_Internal_Note * pnote)
-{
- unsigned char * ptr = (unsigned char *) pnote->descdata;
- unsigned char * ptr_end = ptr + pnote->descsz;
- unsigned int size = is_32bit_elf ? 4 : 8;
-
- printf (_(" Properties: "));
-
- if (pnote->descsz < 8 || (pnote->descsz % size) != 0)
- {
- printf (_("<corrupt GNU_PROPERTY_TYPE, size = %#lx>\n"), pnote->descsz);
- return;
- }
-
- while (ptr < ptr_end)
- {
- unsigned int j;
- unsigned int type;
- unsigned int datasz;
-
- if ((size_t) (ptr_end - ptr) < 8)
- {
- printf (_("<corrupt descsz: %#lx>\n"), pnote->descsz);
- break;
- }
-
- type = byte_get (ptr, 4);
- datasz = byte_get (ptr + 4, 4);
-
- ptr += 8;
-
- if (datasz > (size_t) (ptr_end - ptr))
- {
- printf (_("<corrupt type (%#x) datasz: %#x>\n"),
- type, datasz);
- break;
- }
-
- if (type >= GNU_PROPERTY_LOPROC && type <= GNU_PROPERTY_HIPROC)
- {
- if (filedata->file_header.e_machine == EM_X86_64
- || filedata->file_header.e_machine == EM_IAMCU
- || filedata->file_header.e_machine == EM_386)
- {
- unsigned int bitmask;
-
- if (datasz == 4)
- bitmask = byte_get (ptr, 4);
- else
- bitmask = 0;
-
- switch (type)
- {
- case GNU_PROPERTY_X86_ISA_1_USED:
- if (datasz != 4)
- printf (_("x86 ISA used: <corrupt length: %#x> "),
- datasz);
- else
- {
- printf ("x86 ISA used: ");
- decode_x86_isa (bitmask);
- }
- goto next;
-
- case GNU_PROPERTY_X86_ISA_1_NEEDED:
- if (datasz != 4)
- printf (_("x86 ISA needed: <corrupt length: %#x> "),
- datasz);
- else
- {
- printf ("x86 ISA needed: ");
- decode_x86_isa (bitmask);
- }
- goto next;
-
- case GNU_PROPERTY_X86_FEATURE_1_AND:
- if (datasz != 4)
- printf (_("x86 feature: <corrupt length: %#x> "),
- datasz);
- else
- {
- printf ("x86 feature: ");
- decode_x86_feature_1 (bitmask);
- }
- goto next;
-
- case GNU_PROPERTY_X86_FEATURE_2_USED:
- if (datasz != 4)
- printf (_("x86 feature used: <corrupt length: %#x> "),
- datasz);
- else
- {
- printf ("x86 feature used: ");
- decode_x86_feature_2 (bitmask);
- }
- goto next;
-
- case GNU_PROPERTY_X86_FEATURE_2_NEEDED:
- if (datasz != 4)
- printf (_("x86 feature needed: <corrupt length: %#x> "), datasz);
- else
- {
- printf ("x86 feature needed: ");
- decode_x86_feature_2 (bitmask);
- }
- goto next;
-
- case GNU_PROPERTY_X86_COMPAT_ISA_1_USED:
- if (datasz != 4)
- printf (_("x86 ISA used: <corrupt length: %#x> "),
- datasz);
- else
- {
- printf ("x86 ISA used: ");
- decode_x86_compat_isa (bitmask);
- }
- goto next;
-
- case GNU_PROPERTY_X86_COMPAT_ISA_1_NEEDED:
- if (datasz != 4)
- printf (_("x86 ISA needed: <corrupt length: %#x> "),
- datasz);
- else
- {
- printf ("x86 ISA needed: ");
- decode_x86_compat_isa (bitmask);
- }
- goto next;
-
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_USED:
- if (datasz != 4)
- printf (_("x86 ISA used: <corrupt length: %#x> "),
- datasz);
- else
- {
- printf ("x86 ISA used: ");
- decode_x86_compat_2_isa (bitmask);
- }
- goto next;
-
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_NEEDED:
- if (datasz != 4)
- printf (_("x86 ISA needed: <corrupt length: %#x> "),
- datasz);
- else
- {
- printf ("x86 ISA needed: ");
- decode_x86_compat_2_isa (bitmask);
- }
- goto next;
-
- default:
- break;
- }
- }
- else if (filedata->file_header.e_machine == EM_AARCH64)
- {
- if (type == GNU_PROPERTY_AARCH64_FEATURE_1_AND)
- {
- printf ("AArch64 feature: ");
- if (datasz != 4)
- printf (_("<corrupt length: %#x> "), datasz);
- else
- decode_aarch64_feature_1_and (byte_get (ptr, 4));
- goto next;
- }
- }
- }
- else
- {
- switch (type)
- {
- case GNU_PROPERTY_STACK_SIZE:
- printf (_("stack size: "));
- if (datasz != size)
- printf (_("<corrupt length: %#x> "), datasz);
- else
- printf ("%#" PRIx64, byte_get (ptr, size));
- goto next;
-
- case GNU_PROPERTY_NO_COPY_ON_PROTECTED:
- printf ("no copy on protected ");
- if (datasz)
- printf (_("<corrupt length: %#x> "), datasz);
- goto next;
-
- default:
- if ((type >= GNU_PROPERTY_UINT32_AND_LO
- && type <= GNU_PROPERTY_UINT32_AND_HI)
- || (type >= GNU_PROPERTY_UINT32_OR_LO
- && type <= GNU_PROPERTY_UINT32_OR_HI))
- {
- switch (type)
- {
- case GNU_PROPERTY_1_NEEDED:
- if (datasz != 4)
- printf (_("1_needed: <corrupt length: %#x> "),
- datasz);
- else
- {
- unsigned int bitmask = byte_get (ptr, 4);
- printf ("1_needed: ");
- decode_1_needed (bitmask);
- }
- goto next;
-
- default:
- break;
- }
- if (type <= GNU_PROPERTY_UINT32_AND_HI)
- printf (_("UINT32_AND (%#x): "), type);
- else
- printf (_("UINT32_OR (%#x): "), type);
- if (datasz != 4)
- printf (_("<corrupt length: %#x> "), datasz);
- else
- printf ("%#x", (unsigned int) byte_get (ptr, 4));
- goto next;
- }
- break;
- }
- }
-
- if (type < GNU_PROPERTY_LOPROC)
- printf (_("<unknown type %#x data: "), type);
- else if (type < GNU_PROPERTY_LOUSER)
- printf (_("<processor-specific type %#x data: "), type);
- else
- printf (_("<application-specific type %#x data: "), type);
- for (j = 0; j < datasz; ++j)
- printf ("%02x ", ptr[j] & 0xff);
- printf (">");
-
- next:
- ptr += ((datasz + (size - 1)) & ~ (size - 1));
- if (ptr == ptr_end)
- break;
-
- if (do_wide)
- printf (", ");
- else
- printf ("\n\t");
- }
-
- printf ("\n");
-}
-
-static bool
-print_gnu_note (Filedata * filedata, Elf_Internal_Note *pnote)
-{
- /* NB/ Keep this switch statement in sync with get_gnu_elf_note_type (). */
- switch (pnote->type)
- {
- case NT_GNU_BUILD_ID:
- {
- size_t i;
-
- printf (_(" Build ID: "));
- for (i = 0; i < pnote->descsz; ++i)
- printf ("%02x", pnote->descdata[i] & 0xff);
- printf ("\n");
- }
- break;
-
- case NT_GNU_ABI_TAG:
- {
- unsigned int os, major, minor, subminor;
- const char *osname;
-
- /* PR 17531: file: 030-599401-0.004. */
- if (pnote->descsz < 16)
- {
- printf (_(" <corrupt GNU_ABI_TAG>\n"));
- break;
- }
-
- os = byte_get ((unsigned char *) pnote->descdata, 4);
- major = byte_get ((unsigned char *) pnote->descdata + 4, 4);
- minor = byte_get ((unsigned char *) pnote->descdata + 8, 4);
- subminor = byte_get ((unsigned char *) pnote->descdata + 12, 4);
-
- switch (os)
- {
- case GNU_ABI_TAG_LINUX:
- osname = "Linux";
- break;
- case GNU_ABI_TAG_HURD:
- osname = "Hurd";
- break;
- case GNU_ABI_TAG_SOLARIS:
- osname = "Solaris";
- break;
- case GNU_ABI_TAG_FREEBSD:
- osname = "FreeBSD";
- break;
- case GNU_ABI_TAG_NETBSD:
- osname = "NetBSD";
- break;
- case GNU_ABI_TAG_SYLLABLE:
- osname = "Syllable";
- break;
- case GNU_ABI_TAG_NACL:
- osname = "NaCl";
- break;
- default:
- osname = "Unknown";
- break;
- }
-
- printf (_(" OS: %s, ABI: %d.%d.%d\n"), osname,
- major, minor, subminor);
- }
- break;
-
- case NT_GNU_GOLD_VERSION:
- {
- size_t i;
-
- printf (_(" Version: "));
- for (i = 0; i < pnote->descsz && pnote->descdata[i] != '\0'; ++i)
- printf ("%c", pnote->descdata[i]);
- printf ("\n");
- }
- break;
-
- case NT_GNU_HWCAP:
- {
- unsigned int num_entries, mask;
-
- /* Hardware capabilities information. Word 0 is the number of entries.
- Word 1 is a bitmask of enabled entries. The rest of the descriptor
- is a series of entries, where each entry is a single byte followed
- by a nul terminated string. The byte gives the bit number to test
- if enabled in the bitmask. */
- printf (_(" Hardware Capabilities: "));
- if (pnote->descsz < 8)
- {
- error (_("<corrupt GNU_HWCAP>\n"));
- return false;
- }
- num_entries = byte_get ((unsigned char *) pnote->descdata, 4);
- mask = byte_get ((unsigned char *) pnote->descdata + 4, 4);
- printf (_("num entries: %d, enabled mask: %x\n"), num_entries, mask);
- /* FIXME: Add code to display the entries... */
- }
- break;
-
- case NT_GNU_PROPERTY_TYPE_0:
- print_gnu_property_note (filedata, pnote);
- break;
-
- default:
- /* Handle unrecognised types. An error message should have already been
- created by get_gnu_elf_note_type(), so all that we need to do is to
- display the data. */
- {
- size_t i;
-
- printf (_(" Description data: "));
- for (i = 0; i < pnote->descsz; ++i)
- printf ("%02x ", pnote->descdata[i] & 0xff);
- printf ("\n");
- }
- break;
- }
-
- return true;
-}
-
-static const char *
-get_v850_elf_note_type (enum v850_notes n_type)
-{
- static char buff[64];
-
- switch (n_type)
- {
- case V850_NOTE_ALIGNMENT: return _("Alignment of 8-byte objects");
- case V850_NOTE_DATA_SIZE: return _("Sizeof double and long double");
- case V850_NOTE_FPU_INFO: return _("Type of FPU support needed");
- case V850_NOTE_SIMD_INFO: return _("Use of SIMD instructions");
- case V850_NOTE_CACHE_INFO: return _("Use of cache");
- case V850_NOTE_MMU_INFO: return _("Use of MMU");
- default:
- snprintf (buff, sizeof (buff), _("Unknown note type: (0x%08x)"), n_type);
- return buff;
- }
-}
-
-static bool
-print_v850_note (Elf_Internal_Note * pnote)
-{
- unsigned int val;
-
- if (pnote->descsz != 4)
- return false;
-
- val = byte_get ((unsigned char *) pnote->descdata, pnote->descsz);
-
- if (val == 0)
- {
- printf (_("not set\n"));
- return true;
- }
-
- switch (pnote->type)
- {
- case V850_NOTE_ALIGNMENT:
- switch (val)
- {
- case EF_RH850_DATA_ALIGN4: printf (_("4-byte\n")); return true;
- case EF_RH850_DATA_ALIGN8: printf (_("8-byte\n")); return true;
- }
- break;
-
- case V850_NOTE_DATA_SIZE:
- switch (val)
- {
- case EF_RH850_DOUBLE32: printf (_("4-bytes\n")); return true;
- case EF_RH850_DOUBLE64: printf (_("8-bytes\n")); return true;
- }
- break;
-
- case V850_NOTE_FPU_INFO:
- switch (val)
- {
- case EF_RH850_FPU20: printf (_("FPU-2.0\n")); return true;
- case EF_RH850_FPU30: printf (_("FPU-3.0\n")); return true;
- }
- break;
-
- case V850_NOTE_MMU_INFO:
- case V850_NOTE_CACHE_INFO:
- case V850_NOTE_SIMD_INFO:
- if (val == EF_RH850_SIMD)
- {
- printf (_("yes\n"));
- return true;
- }
- break;
-
- default:
- /* An 'unknown note type' message will already have been displayed. */
- break;
- }
-
- printf (_("unknown value: %x\n"), val);
- return false;
-}
-
-static bool
-process_netbsd_elf_note (Elf_Internal_Note * pnote)
-{
- unsigned int version;
-
- switch (pnote->type)
- {
- case NT_NETBSD_IDENT:
- if (pnote->descsz < 1)
- break;
- version = byte_get ((unsigned char *) pnote->descdata, sizeof (version));
- if ((version / 10000) % 100)
- printf (" NetBSD\t\t0x%08lx\tIDENT %u (%u.%u%s%c)\n", pnote->descsz,
- version, version / 100000000, (version / 1000000) % 100,
- (version / 10000) % 100 > 26 ? "Z" : "",
- 'A' + (version / 10000) % 26);
- else
- printf (" NetBSD\t\t0x%08lx\tIDENT %u (%u.%u.%u)\n", pnote->descsz,
- version, version / 100000000, (version / 1000000) % 100,
- (version / 100) % 100);
- return true;
-
- case NT_NETBSD_MARCH:
- printf (" NetBSD\t\t0x%08lx\tMARCH <%s>\n", pnote->descsz,
- pnote->descdata);
- return true;
-
- case NT_NETBSD_PAX:
- if (pnote->descsz < 1)
- break;
- version = byte_get ((unsigned char *) pnote->descdata, sizeof (version));
- printf (" NetBSD\t\t0x%08lx\tPaX <%s%s%s%s%s%s>\n", pnote->descsz,
- ((version & NT_NETBSD_PAX_MPROTECT) ? "+mprotect" : ""),
- ((version & NT_NETBSD_PAX_NOMPROTECT) ? "-mprotect" : ""),
- ((version & NT_NETBSD_PAX_GUARD) ? "+guard" : ""),
- ((version & NT_NETBSD_PAX_NOGUARD) ? "-guard" : ""),
- ((version & NT_NETBSD_PAX_ASLR) ? "+ASLR" : ""),
- ((version & NT_NETBSD_PAX_NOASLR) ? "-ASLR" : ""));
- return true;
- }
-
- printf (" NetBSD\t0x%08lx\tUnknown note type: (0x%08lx)\n",
- pnote->descsz, pnote->type);
- return false;
-}
-
-static const char *
-get_freebsd_elfcore_note_type (Filedata * filedata, unsigned e_type)
-{
- switch (e_type)
- {
- case NT_FREEBSD_THRMISC:
- return _("NT_THRMISC (thrmisc structure)");
- case NT_FREEBSD_PROCSTAT_PROC:
- return _("NT_PROCSTAT_PROC (proc data)");
- case NT_FREEBSD_PROCSTAT_FILES:
- return _("NT_PROCSTAT_FILES (files data)");
- case NT_FREEBSD_PROCSTAT_VMMAP:
- return _("NT_PROCSTAT_VMMAP (vmmap data)");
- case NT_FREEBSD_PROCSTAT_GROUPS:
- return _("NT_PROCSTAT_GROUPS (groups data)");
- case NT_FREEBSD_PROCSTAT_UMASK:
- return _("NT_PROCSTAT_UMASK (umask data)");
- case NT_FREEBSD_PROCSTAT_RLIMIT:
- return _("NT_PROCSTAT_RLIMIT (rlimit data)");
- case NT_FREEBSD_PROCSTAT_OSREL:
- return _("NT_PROCSTAT_OSREL (osreldate data)");
- case NT_FREEBSD_PROCSTAT_PSSTRINGS:
- return _("NT_PROCSTAT_PSSTRINGS (ps_strings data)");
- case NT_FREEBSD_PROCSTAT_AUXV:
- return _("NT_PROCSTAT_AUXV (auxv data)");
- case NT_FREEBSD_PTLWPINFO:
- return _("NT_PTLWPINFO (ptrace_lwpinfo structure)");
- case NT_FREEBSD_X86_SEGBASES:
- return _("NT_X86_SEGBASES (x86 segment base registers)");
- }
- return get_note_type (filedata, e_type);
-}
-
-static const char *
-get_netbsd_elfcore_note_type (Filedata * filedata, unsigned e_type)
-{
- static char buff[64];
-
- switch (e_type)
- {
- case NT_NETBSDCORE_PROCINFO:
- /* NetBSD core "procinfo" structure. */
- return _("NetBSD procinfo structure");
-
- case NT_NETBSDCORE_AUXV:
- return _("NetBSD ELF auxiliary vector data");
-
- case NT_NETBSDCORE_LWPSTATUS:
- return _("PT_LWPSTATUS (ptrace_lwpstatus structure)");
-
- default:
- /* As of Jan 2020 there are no other machine-independent notes
- defined for NetBSD core files. If the note type is less
- than the start of the machine-dependent note types, we don't
- understand it. */
-
- if (e_type < NT_NETBSDCORE_FIRSTMACH)
- {
- snprintf (buff, sizeof (buff), _("Unknown note type: (0x%08x)"), e_type);
- return buff;
- }
- break;
- }
-
- switch (filedata->file_header.e_machine)
- {
- /* On the Alpha, SPARC (32-bit and 64-bit), PT_GETREGS == mach+0
- and PT_GETFPREGS == mach+2. */
-
- case EM_OLD_ALPHA:
- case EM_ALPHA:
- case EM_SPARC:
- case EM_SPARC32PLUS:
- case EM_SPARCV9:
- switch (e_type)
- {
- case NT_NETBSDCORE_FIRSTMACH + 0:
- return _("PT_GETREGS (reg structure)");
- case NT_NETBSDCORE_FIRSTMACH + 2:
- return _("PT_GETFPREGS (fpreg structure)");
- default:
- break;
- }
- break;
-
- /* On SuperH, PT_GETREGS == mach+3 and PT_GETFPREGS == mach+5.
- There's also old PT___GETREGS40 == mach + 1 for old reg
- structure which lacks GBR. */
- case EM_SH:
- switch (e_type)
- {
- case NT_NETBSDCORE_FIRSTMACH + 1:
- return _("PT___GETREGS40 (old reg structure)");
- case NT_NETBSDCORE_FIRSTMACH + 3:
- return _("PT_GETREGS (reg structure)");
- case NT_NETBSDCORE_FIRSTMACH + 5:
- return _("PT_GETFPREGS (fpreg structure)");
- default:
- break;
- }
- break;
-
- /* On all other arch's, PT_GETREGS == mach+1 and
- PT_GETFPREGS == mach+3. */
- default:
- switch (e_type)
- {
- case NT_NETBSDCORE_FIRSTMACH + 1:
- return _("PT_GETREGS (reg structure)");
- case NT_NETBSDCORE_FIRSTMACH + 3:
- return _("PT_GETFPREGS (fpreg structure)");
- default:
- break;
- }
- }
-
- snprintf (buff, sizeof (buff), "PT_FIRSTMACH+%d",
- e_type - NT_NETBSDCORE_FIRSTMACH);
- return buff;
-}
-
-static const char *
-get_openbsd_elfcore_note_type (Filedata * filedata, unsigned e_type)
-{
- switch (e_type)
- {
- case NT_OPENBSD_PROCINFO:
- return _("OpenBSD procinfo structure");
- case NT_OPENBSD_AUXV:
- return _("OpenBSD ELF auxiliary vector data");
- case NT_OPENBSD_REGS:
- return _("OpenBSD regular registers");
- case NT_OPENBSD_FPREGS:
- return _("OpenBSD floating point registers");
- case NT_OPENBSD_WCOOKIE:
- return _("OpenBSD window cookie");
- }
-
- return get_note_type (filedata, e_type);
-}
-
-static const char *
-get_qnx_elfcore_note_type (Filedata * filedata, unsigned e_type)
-{
- switch (e_type)
- {
- case QNT_DEBUG_FULLPATH:
- return _("QNX debug fullpath");
- case QNT_DEBUG_RELOC:
- return _("QNX debug relocation");
- case QNT_STACK:
- return _("QNX stack");
- case QNT_GENERATOR:
- return _("QNX generator");
- case QNT_DEFAULT_LIB:
- return _("QNX default library");
- case QNT_CORE_SYSINFO:
- return _("QNX core sysinfo");
- case QNT_CORE_INFO:
- return _("QNX core info");
- case QNT_CORE_STATUS:
- return _("QNX core status");
- case QNT_CORE_GREG:
- return _("QNX general registers");
- case QNT_CORE_FPREG:
- return _("QNX floating point registers");
- case QNT_LINK_MAP:
- return _("QNX link map");
- }
-
- return get_note_type (filedata, e_type);
-}
-
-static const char *
-get_stapsdt_note_type (unsigned e_type)
-{
- static char buff[64];
-
- switch (e_type)
- {
- case NT_STAPSDT:
- return _("NT_STAPSDT (SystemTap probe descriptors)");
-
- default:
- break;
- }
-
- snprintf (buff, sizeof (buff), _("Unknown note type: (0x%08x)"), e_type);
- return buff;
-}
-
-static bool
-print_stapsdt_note (Elf_Internal_Note *pnote)
-{
- size_t len, maxlen;
- size_t addr_size = is_32bit_elf ? 4 : 8;
- char *data = pnote->descdata;
- char *data_end = pnote->descdata + pnote->descsz;
- uint64_t pc, base_addr, semaphore;
- char *provider, *probe, *arg_fmt;
-
- if (pnote->descsz < (addr_size * 3))
- goto stapdt_note_too_small;
-
- pc = byte_get ((unsigned char *) data, addr_size);
- data += addr_size;
-
- base_addr = byte_get ((unsigned char *) data, addr_size);
- data += addr_size;
-
- semaphore = byte_get ((unsigned char *) data, addr_size);
- data += addr_size;
-
- if (data >= data_end)
- goto stapdt_note_too_small;
- maxlen = data_end - data;
- len = strnlen (data, maxlen);
- if (len < maxlen)
- {
- provider = data;
- data += len + 1;
- }
- else
- goto stapdt_note_too_small;
-
- if (data >= data_end)
- goto stapdt_note_too_small;
- maxlen = data_end - data;
- len = strnlen (data, maxlen);
- if (len < maxlen)
- {
- probe = data;
- data += len + 1;
- }
- else
- goto stapdt_note_too_small;
-
- if (data >= data_end)
- goto stapdt_note_too_small;
- maxlen = data_end - data;
- len = strnlen (data, maxlen);
- if (len < maxlen)
- {
- arg_fmt = data;
- data += len + 1;
- }
- else
- goto stapdt_note_too_small;
-
- printf (_(" Provider: %s\n"), provider);
- printf (_(" Name: %s\n"), probe);
- printf (_(" Location: "));
- print_vma (pc, FULL_HEX);
- printf (_(", Base: "));
- print_vma (base_addr, FULL_HEX);
- printf (_(", Semaphore: "));
- print_vma (semaphore, FULL_HEX);
- printf ("\n");
- printf (_(" Arguments: %s\n"), arg_fmt);
-
- return data == data_end;
-
- stapdt_note_too_small:
- printf (_(" <corrupt - note is too small>\n"));
- error (_("corrupt stapdt note - the data size is too small\n"));
- return false;
-}
-
-static bool
-print_fdo_note (Elf_Internal_Note * pnote)
-{
- if (pnote->descsz > 0 && pnote->type == FDO_PACKAGING_METADATA)
- {
- printf (_(" Packaging Metadata: %.*s\n"), (int) pnote->descsz, pnote->descdata);
- return true;
- }
- if (pnote->descsz > 0 && pnote->type == FDO_DLOPEN_METADATA)
- {
- printf (_(" Dlopen Metadata: %.*s\n"), (int) pnote->descsz, pnote->descdata);
- return true;
- }
- return false;
-}
-
-static const char *
-get_ia64_vms_note_type (unsigned e_type)
-{
- static char buff[64];
-
- switch (e_type)
- {
- case NT_VMS_MHD:
- return _("NT_VMS_MHD (module header)");
- case NT_VMS_LNM:
- return _("NT_VMS_LNM (language name)");
- case NT_VMS_SRC:
- return _("NT_VMS_SRC (source files)");
- case NT_VMS_TITLE:
- return "NT_VMS_TITLE";
- case NT_VMS_EIDC:
- return _("NT_VMS_EIDC (consistency check)");
- case NT_VMS_FPMODE:
- return _("NT_VMS_FPMODE (FP mode)");
- case NT_VMS_LINKTIME:
- return "NT_VMS_LINKTIME";
- case NT_VMS_IMGNAM:
- return _("NT_VMS_IMGNAM (image name)");
- case NT_VMS_IMGID:
- return _("NT_VMS_IMGID (image id)");
- case NT_VMS_LINKID:
- return _("NT_VMS_LINKID (link id)");
- case NT_VMS_IMGBID:
- return _("NT_VMS_IMGBID (build id)");
- case NT_VMS_GSTNAM:
- return _("NT_VMS_GSTNAM (sym table name)");
- case NT_VMS_ORIG_DYN:
- return "NT_VMS_ORIG_DYN";
- case NT_VMS_PATCHTIME:
- return "NT_VMS_PATCHTIME";
- default:
- snprintf (buff, sizeof (buff), _("Unknown note type: (0x%08x)"), e_type);
- return buff;
- }
-}
-
-static bool
-print_ia64_vms_note (Elf_Internal_Note * pnote)
-{
- unsigned int maxlen = pnote->descsz;
-
- if (maxlen < 2 || maxlen != pnote->descsz)
- goto desc_size_fail;
-
- switch (pnote->type)
- {
- case NT_VMS_MHD:
- if (maxlen <= 36)
- goto desc_size_fail;
-
- size_t l = strnlen (pnote->descdata + 34, maxlen - 34);
-
- printf (_(" Creation date : %.17s\n"), pnote->descdata);
- printf (_(" Last patch date: %.17s\n"), pnote->descdata + 17);
- if (l + 34 < maxlen)
- {
- printf (_(" Module name : %s\n"), pnote->descdata + 34);
- if (l + 35 < maxlen)
- printf (_(" Module version : %s\n"), pnote->descdata + 34 + l + 1);
- else
- printf (_(" Module version : <missing>\n"));
- }
- else
- {
- printf (_(" Module name : <missing>\n"));
- printf (_(" Module version : <missing>\n"));
- }
- break;
-
- case NT_VMS_LNM:
- printf (_(" Language: %.*s\n"), maxlen, pnote->descdata);
- break;
-
- case NT_VMS_FPMODE:
- printf (_(" Floating Point mode: "));
- if (maxlen < 8)
- goto desc_size_fail;
- /* FIXME: Generate an error if descsz > 8 ? */
-
- printf ("0x%016" PRIx64 "\n",
- byte_get ((unsigned char *) pnote->descdata, 8));
- break;
-
- case NT_VMS_LINKTIME:
- printf (_(" Link time: "));
- if (maxlen < 8)
- goto desc_size_fail;
- /* FIXME: Generate an error if descsz > 8 ? */
-
- print_vms_time (byte_get ((unsigned char *) pnote->descdata, 8));
- printf ("\n");
- break;
-
- case NT_VMS_PATCHTIME:
- printf (_(" Patch time: "));
- if (maxlen < 8)
- goto desc_size_fail;
- /* FIXME: Generate an error if descsz > 8 ? */
-
- print_vms_time (byte_get ((unsigned char *) pnote->descdata, 8));
- printf ("\n");
- break;
-
- case NT_VMS_ORIG_DYN:
- if (maxlen < 34)
- goto desc_size_fail;
-
- printf (_(" Major id: %u, minor id: %u\n"),
- (unsigned) byte_get ((unsigned char *) pnote->descdata, 4),
- (unsigned) byte_get ((unsigned char *) pnote->descdata + 4, 4));
- printf (_(" Last modified : "));
- print_vms_time (byte_get ((unsigned char *) pnote->descdata + 8, 8));
- printf (_("\n Link flags : "));
- printf ("0x%016" PRIx64 "\n",
- byte_get ((unsigned char *) pnote->descdata + 16, 8));
- printf (_(" Header flags: 0x%08x\n"),
- (unsigned) byte_get ((unsigned char *) pnote->descdata + 24, 4));
- printf (_(" Image id : %.*s\n"), maxlen - 32, pnote->descdata + 32);
- break;
-
- case NT_VMS_IMGNAM:
- printf (_(" Image name: %.*s\n"), maxlen, pnote->descdata);
- break;
-
- case NT_VMS_GSTNAM:
- printf (_(" Global symbol table name: %.*s\n"), maxlen, pnote->descdata);
- break;
-
- case NT_VMS_IMGID:
- printf (_(" Image id: %.*s\n"), maxlen, pnote->descdata);
- break;
-
- case NT_VMS_LINKID:
- printf (_(" Linker id: %.*s\n"), maxlen, pnote->descdata);
- break;
-
- default:
- return false;
- }
-
- return true;
-
- desc_size_fail:
- printf (_(" <corrupt - data size is too small>\n"));
- error (_("corrupt IA64 note: data size is too small\n"));
- return false;
-}
-
-struct build_attr_cache {
- Filedata *filedata;
- char *strtab;
- uint64_t strtablen;
- Elf_Internal_Sym *symtab;
- uint64_t nsyms;
-} ba_cache;
-
-/* Find the symbol associated with a build attribute that is attached
- to address OFFSET. If PNAME is non-NULL then store the name of
- the symbol (if found) in the provided pointer, Returns NULL if a
- symbol could not be found. */
-
-static Elf_Internal_Sym *
-get_symbol_for_build_attribute (Filedata *filedata,
- uint64_t offset,
- bool is_open_attr,
- const char **pname)
-{
- Elf_Internal_Sym *saved_sym = NULL;
- Elf_Internal_Sym *sym;
-
- if (filedata->section_headers != NULL
- && (ba_cache.filedata == NULL || filedata != ba_cache.filedata))
- {
- Elf_Internal_Shdr * symsec;
-
- free (ba_cache.strtab);
- ba_cache.strtab = NULL;
- free (ba_cache.symtab);
- ba_cache.symtab = NULL;
-
- /* Load the symbol and string sections. */
- for (symsec = filedata->section_headers;
- symsec < filedata->section_headers + filedata->file_header.e_shnum;
- symsec ++)
- {
- if (symsec->sh_type == SHT_SYMTAB
- && get_symtab (filedata, symsec,
- &ba_cache.symtab, &ba_cache.nsyms,
- &ba_cache.strtab, &ba_cache.strtablen))
- break;
- }
- ba_cache.filedata = filedata;
- }
-
- if (ba_cache.symtab == NULL)
- return NULL;
-
- /* Find a symbol whose value matches offset. */
- for (sym = ba_cache.symtab; sym < ba_cache.symtab + ba_cache.nsyms; sym ++)
- if (sym->st_value == offset)
- {
- if (sym->st_name >= ba_cache.strtablen)
- /* Huh ? This should not happen. */
- continue;
-
- if (ba_cache.strtab[sym->st_name] == 0)
- continue;
-
- /* The AArch64, ARM and RISC-V architectures define mapping symbols
- (eg $d, $x, $t) which we want to ignore. */
- if (ba_cache.strtab[sym->st_name] == '$'
- && ba_cache.strtab[sym->st_name + 1] != 0
- && ba_cache.strtab[sym->st_name + 2] == 0)
- continue;
-
- if (is_open_attr)
- {
- /* For OPEN attributes we prefer GLOBAL over LOCAL symbols
- and FILE or OBJECT symbols over NOTYPE symbols. We skip
- FUNC symbols entirely. */
- switch (ELF_ST_TYPE (sym->st_info))
- {
- case STT_OBJECT:
- case STT_FILE:
- saved_sym = sym;
- if (sym->st_size)
- {
- /* If the symbol has a size associated
- with it then we can stop searching. */
- sym = ba_cache.symtab + ba_cache.nsyms;
- }
- continue;
-
- case STT_FUNC:
- /* Ignore function symbols. */
- continue;
-
- default:
- break;
- }
-
- switch (ELF_ST_BIND (sym->st_info))
- {
- case STB_GLOBAL:
- if (saved_sym == NULL
- || ELF_ST_TYPE (saved_sym->st_info) != STT_OBJECT)
- saved_sym = sym;
- break;
-
- case STB_LOCAL:
- if (saved_sym == NULL)
- saved_sym = sym;
- break;
-
- default:
- break;
- }
- }
- else
- {
- if (ELF_ST_TYPE (sym->st_info) != STT_FUNC)
- continue;
-
- saved_sym = sym;
- break;
- }
- }
-
- if (saved_sym && pname)
- * pname = ba_cache.strtab + saved_sym->st_name;
-
- return saved_sym;
-}
-
-/* Returns true iff addr1 and addr2 are in the same section. */
-
-static bool
-same_section (Filedata * filedata, uint64_t addr1, uint64_t addr2)
-{
- Elf_Internal_Shdr * a1;
- Elf_Internal_Shdr * a2;
-
- a1 = find_section_by_address (filedata, addr1);
- a2 = find_section_by_address (filedata, addr2);
-
- return a1 == a2 && a1 != NULL;
-}
-
-static bool
-print_gnu_build_attribute_description (Elf_Internal_Note * pnote,
- Filedata * filedata)
-{
- static uint64_t global_offset = 0;
- static uint64_t global_end = 0;
- static uint64_t func_offset = 0;
- static uint64_t func_end = 0;
-
- Elf_Internal_Sym *sym;
- const char *name;
- uint64_t start;
- uint64_t end;
- bool is_open_attr = pnote->type == NT_GNU_BUILD_ATTRIBUTE_OPEN;
-
- switch (pnote->descsz)
- {
- case 0:
- /* A zero-length description means that the range of
- the previous note of the same type should be used. */
- if (is_open_attr)
- {
- if (global_end > global_offset)
- printf (_(" Applies to region from %#" PRIx64
- " to %#" PRIx64 "\n"), global_offset, global_end);
- else
- printf (_(" Applies to region from %#" PRIx64
- "\n"), global_offset);
- }
- else
- {
- if (func_end > func_offset)
- printf (_(" Applies to region from %#" PRIx64
- " to %#" PRIx64 "\n"), func_offset, func_end);
- else
- printf (_(" Applies to region from %#" PRIx64
- "\n"), func_offset);
- }
- return true;
-
- case 4:
- start = byte_get ((unsigned char *) pnote->descdata, 4);
- end = 0;
- break;
-
- case 8:
- start = byte_get ((unsigned char *) pnote->descdata, 4);
- end = byte_get ((unsigned char *) pnote->descdata + 4, 4);
- break;
-
- case 16:
- start = byte_get ((unsigned char *) pnote->descdata, 8);
- end = byte_get ((unsigned char *) pnote->descdata + 8, 8);
- break;
-
- default:
- error (_(" <invalid description size: %lx>\n"), pnote->descsz);
- printf (_(" <invalid descsz>"));
- return false;
- }
-
- name = NULL;
- sym = get_symbol_for_build_attribute (filedata, start, is_open_attr, & name);
- /* As of version 5 of the annobin plugin, filename symbols are biased by 2
- in order to avoid them being confused with the start address of the
- first function in the file... */
- if (sym == NULL && is_open_attr)
- sym = get_symbol_for_build_attribute (filedata, start + 2, is_open_attr,
- & name);
-
- if (end == 0 && sym != NULL && sym->st_size > 0)
- end = start + sym->st_size;
-
- if (is_open_attr)
- {
- /* FIXME: Need to properly allow for section alignment.
- 16 is just the alignment used on x86_64. */
- if (global_end > 0
- && start > BFD_ALIGN (global_end, 16)
- /* Build notes are not guaranteed to be organised in order of
- increasing address, but we should find the all of the notes
- for one section in the same place. */
- && same_section (filedata, start, global_end))
- warn (_("Gap in build notes detected from %#" PRIx64
- " to %#" PRIx64 "\n"),
- global_end + 1, start - 1);
-
- printf (_(" Applies to region from %#" PRIx64), start);
- global_offset = start;
-
- if (end)
- {
- printf (_(" to %#" PRIx64), end);
- global_end = end;
- }
- }
- else
- {
- printf (_(" Applies to region from %#" PRIx64), start);
- func_offset = start;
-
- if (end)
- {
- printf (_(" to %#" PRIx64), end);
- func_end = end;
- }
- }
-
- if (sym && name)
- printf (_(" (%s)"), name);
-
- printf ("\n");
- return true;
-}
-
-static bool
-print_gnu_build_attribute_name (Elf_Internal_Note * pnote)
-{
- static const char string_expected [2] = { GNU_BUILD_ATTRIBUTE_TYPE_STRING, 0 };
- static const char number_expected [2] = { GNU_BUILD_ATTRIBUTE_TYPE_NUMERIC, 0 };
- static const char bool_expected [3] = { GNU_BUILD_ATTRIBUTE_TYPE_BOOL_TRUE, GNU_BUILD_ATTRIBUTE_TYPE_BOOL_FALSE, 0 };
- char name_type;
- char name_attribute;
- const char * expected_types;
- const char * name = pnote->namedata;
- const char * text;
- signed int left;
-
- if (name == NULL || pnote->namesz < 2)
- {
- error (_("corrupt name field in GNU build attribute note: size = %ld\n"), pnote->namesz);
- print_symbol_name (-20, _(" <corrupt name>"));
- return false;
- }
-
- if (do_wide)
- left = 28;
- else
- left = 20;
-
- /* Version 2 of the spec adds a "GA" prefix to the name field. */
- if (name[0] == 'G' && name[1] == 'A')
- {
- if (pnote->namesz < 4)
- {
- error (_("corrupt name field in GNU build attribute note: size = %ld\n"), pnote->namesz);
- print_symbol_name (-20, _(" <corrupt name>"));
- return false;
- }
-
- printf ("GA");
- name += 2;
- left -= 2;
- }
-
- switch ((name_type = * name))
- {
- case GNU_BUILD_ATTRIBUTE_TYPE_NUMERIC:
- case GNU_BUILD_ATTRIBUTE_TYPE_STRING:
- case GNU_BUILD_ATTRIBUTE_TYPE_BOOL_TRUE:
- case GNU_BUILD_ATTRIBUTE_TYPE_BOOL_FALSE:
- printf ("%c", * name);
- left --;
- break;
- default:
- error (_("unrecognised attribute type in name field: %d\n"), name_type);
- print_symbol_name (-20, _("<unknown name type>"));
- return false;
- }
-
- ++ name;
- text = NULL;
-
- switch ((name_attribute = * name))
- {
- case GNU_BUILD_ATTRIBUTE_VERSION:
- text = _("<version>");
- expected_types = string_expected;
- ++ name;
- break;
- case GNU_BUILD_ATTRIBUTE_STACK_PROT:
- text = _("<stack prot>");
- expected_types = "!+*";
- ++ name;
- break;
- case GNU_BUILD_ATTRIBUTE_RELRO:
- text = _("<relro>");
- expected_types = bool_expected;
- ++ name;
- break;
- case GNU_BUILD_ATTRIBUTE_STACK_SIZE:
- text = _("<stack size>");
- expected_types = number_expected;
- ++ name;
- break;
- case GNU_BUILD_ATTRIBUTE_TOOL:
- text = _("<tool>");
- expected_types = string_expected;
- ++ name;
- break;
- case GNU_BUILD_ATTRIBUTE_ABI:
- text = _("<ABI>");
- expected_types = "$*";
- ++ name;
- break;
- case GNU_BUILD_ATTRIBUTE_PIC:
- text = _("<PIC>");
- expected_types = number_expected;
- ++ name;
- break;
- case GNU_BUILD_ATTRIBUTE_SHORT_ENUM:
- text = _("<short enum>");
- expected_types = bool_expected;
- ++ name;
- break;
- default:
- if (ISPRINT (* name))
- {
- int len = strnlen (name, pnote->namesz - (name - pnote->namedata)) + 1;
-
- if (len > left && ! do_wide)
- len = left;
- printf ("%.*s:", len, name);
- left -= len;
- name += len;
- }
- else
- {
- static char tmpbuf [128];
-
- error (_("unrecognised byte in name field: %d\n"), * name);
- sprintf (tmpbuf, _("<unknown:_%d>"), * name);
- text = tmpbuf;
- name ++;
- }
- expected_types = "*$!+";
- break;
- }
-
- if (text)
- left -= printf ("%s", text);
-
- if (strchr (expected_types, name_type) == NULL)
- warn (_("attribute does not have an expected type (%c)\n"), name_type);
-
- if ((size_t) (name - pnote->namedata) > pnote->namesz)
- {
- error (_("corrupt name field: namesz: %lu but parsing gets to %td\n"),
- pnote->namesz,
- name - pnote->namedata);
- return false;
- }
-
- if (left < 1 && ! do_wide)
- return true;
-
- switch (name_type)
- {
- case GNU_BUILD_ATTRIBUTE_TYPE_NUMERIC:
- {
- unsigned int bytes;
- uint64_t val = 0;
- unsigned int shift = 0;
- char *decoded = NULL;
-
- bytes = pnote->namesz - (name - pnote->namedata);
- if (bytes > 0)
- /* The -1 is because the name field is always 0 terminated, and we
- want to be able to ensure that the shift in the while loop below
- will not overflow. */
- -- bytes;
-
- if (bytes > sizeof (val))
- {
- error (_("corrupt numeric name field: too many bytes in the value: %x\n"),
- bytes);
- bytes = sizeof (val);
- }
- /* We do not bother to warn if bytes == 0 as this can
- happen with some early versions of the gcc plugin. */
-
- while (bytes --)
- {
- uint64_t byte = *name++ & 0xff;
-
- val |= byte << shift;
- shift += 8;
- }
-
- switch (name_attribute)
- {
- case GNU_BUILD_ATTRIBUTE_PIC:
- switch (val)
- {
- case 0: decoded = "static"; break;
- case 1: decoded = "pic"; break;
- case 2: decoded = "PIC"; break;
- case 3: decoded = "pie"; break;
- case 4: decoded = "PIE"; break;
- default: break;
- }
- break;
- case GNU_BUILD_ATTRIBUTE_STACK_PROT:
- switch (val)
- {
- /* Based upon the SPCT_FLAG_xxx enum values in gcc/cfgexpand.c. */
- case 0: decoded = "off"; break;
- case 1: decoded = "on"; break;
- case 2: decoded = "all"; break;
- case 3: decoded = "strong"; break;
- case 4: decoded = "explicit"; break;
- default: break;
- }
- break;
- default:
- break;
- }
-
- if (decoded != NULL)
- {
- print_symbol_name (-left, decoded);
- left = 0;
- }
- else if (val == 0)
- {
- printf ("0x0");
- left -= 3;
- }
- else
- {
- if (do_wide)
- left -= printf ("0x%" PRIx64, val);
- else
- left -= printf ("0x%-.*" PRIx64, left, val);
- }
- }
- break;
- case GNU_BUILD_ATTRIBUTE_TYPE_STRING:
- left -= print_symbol_name (- left, name);
- break;
- case GNU_BUILD_ATTRIBUTE_TYPE_BOOL_TRUE:
- left -= print_symbol_name (- left, "true");
- break;
- case GNU_BUILD_ATTRIBUTE_TYPE_BOOL_FALSE:
- left -= print_symbol_name (- left, "false");
- break;
- }
-
- if (do_wide && left > 0)
- printf ("%-*s", left, " ");
-
- return true;
-}
-
-/* Print the contents of PNOTE as hex. */
-
-static void
-print_note_contents_hex (Elf_Internal_Note *pnote)
-{
- if (pnote->descsz)
- {
- size_t i;
-
- printf (_(" description data: "));
- for (i = 0; i < pnote->descsz; i++)
- printf ("%02x ", pnote->descdata[i] & 0xff);
- if (!do_wide)
- printf ("\n");
- }
-
- if (do_wide)
- printf ("\n");
-}
-
-#if defined HAVE_MSGPACK
-
-static void
-print_indents (int n)
-{
- printf (" ");
-
- for (int i = 0; i < n; i++)
- printf (" ");
-}
-
-/* Print OBJ in human-readable form. */
-
-static void
-dump_msgpack_obj (const msgpack_object *obj, int indent)
-{
- switch (obj->type)
- {
- case MSGPACK_OBJECT_NIL:
- printf ("(nil)");
- break;
-
- case MSGPACK_OBJECT_BOOLEAN:
- printf ("%s", obj->via.boolean ? "true" : "false");
- break;
-
- case MSGPACK_OBJECT_POSITIVE_INTEGER:
- printf ("%" PRIu64, obj->via.u64);
- break;
-
- case MSGPACK_OBJECT_NEGATIVE_INTEGER:
- printf ("%" PRIi64, obj->via.i64);
- break;
-
- case MSGPACK_OBJECT_FLOAT32:
- case MSGPACK_OBJECT_FLOAT64:
- printf ("%f", obj->via.f64);
- break;
-
- case MSGPACK_OBJECT_STR:
- printf ("\"%.*s\"", obj->via.str.size, obj->via.str.ptr);
- break;
-
- case MSGPACK_OBJECT_ARRAY:
- {
- const msgpack_object_array *array = &obj->via.array;
-
- printf ("[\n");
- ++indent;
-
- for (uint32_t i = 0; i < array->size; ++i)
- {
- const msgpack_object *item = &array->ptr[i];
-
- print_indents (indent);
- dump_msgpack_obj (item, indent);
- printf (",\n");
- }
-
- --indent;
- print_indents (indent);
- printf ("]");
- break;
- }
- break;
-
- case MSGPACK_OBJECT_MAP:
- {
- const msgpack_object_map *map = &obj->via.map;
-
- printf ("{\n");
- ++indent;
-
- for (uint32_t i = 0; i < map->size; ++i)
- {
- const msgpack_object_kv *kv = &map->ptr[i];
- const msgpack_object *key = &kv->key;
- const msgpack_object *val = &kv->val;
-
- print_indents (indent);
- dump_msgpack_obj (key, indent);
- printf (": ");
- dump_msgpack_obj (val, indent);
-
- printf (",\n");
- }
-
- --indent;
- print_indents (indent);
- printf ("}");
-
- break;
- }
-
- case MSGPACK_OBJECT_BIN:
- printf ("(bin)");
- break;
-
- case MSGPACK_OBJECT_EXT:
- printf ("(ext)");
- break;
- }
-}
-
-static void
-dump_msgpack (const msgpack_unpacked *msg)
-{
- print_indents (0);
- dump_msgpack_obj (&msg->data, 0);
- printf ("\n");
-}
-
-#endif /* defined HAVE_MSGPACK */
-
-static bool
-print_amdgpu_note (Elf_Internal_Note *pnote)
-{
-#if defined HAVE_MSGPACK
- /* If msgpack is available, decode and dump the note's content. */
- bool ret;
- msgpack_unpacked msg;
- msgpack_unpack_return msgpack_ret;
-
- assert (pnote->type == NT_AMDGPU_METADATA);
-
- msgpack_unpacked_init (&msg);
- msgpack_ret = msgpack_unpack_next (&msg, pnote->descdata, pnote->descsz,
- NULL);
-
- switch (msgpack_ret)
- {
- case MSGPACK_UNPACK_SUCCESS:
- dump_msgpack (&msg);
- ret = true;
- break;
-
- default:
- error (_("failed to unpack msgpack contents in NT_AMDGPU_METADATA note"));
- ret = false;
- break;
- }
-
- msgpack_unpacked_destroy (&msg);
- return ret;
-#else
- /* msgpack is not available, dump contents as hex. */
- print_note_contents_hex (pnote);
- return true;
-#endif
-}
-
-static bool
-print_qnx_note (Elf_Internal_Note *pnote)
-{
- switch (pnote->type)
- {
- case QNT_STACK:
- if (pnote->descsz != 12)
- goto desc_size_fail;
-
- printf (_(" Stack Size: 0x%" PRIx32 "\n"),
- (unsigned) byte_get ((unsigned char *) pnote->descdata, 4));
- printf (_(" Stack allocated: %" PRIx32 "\n"),
- (unsigned) byte_get ((unsigned char *) pnote->descdata + 4, 4));
- printf (_(" Executable: %s\n"),
- ((unsigned) byte_get ((unsigned char *) pnote->descdata + 8, 1)) ? "no": "yes");
- break;
-
- default:
- print_note_contents_hex(pnote);
- }
- return true;
-
-desc_size_fail:
- printf (_(" <corrupt - data size is too small>\n"));
- error (_("corrupt QNX note: data size is too small\n"));
- return false;
-}
-
-
-/* Note that by the ELF standard, the name field is already null byte
- terminated, and namesz includes the terminating null byte.
- I.E. the value of namesz for the name "FSF" is 4.
-
- If the value of namesz is zero, there is no name present. */
-
-static bool
-process_note (Elf_Internal_Note * pnote,
- Filedata * filedata)
-{
- const char * name = pnote->namesz ? pnote->namedata : "(NONE)";
- const char * nt;
-
- if (pnote->namesz == 0)
- /* If there is no note name, then use the default set of
- note type strings. */
- nt = get_note_type (filedata, pnote->type);
-
- else if (startswith (pnote->namedata, "GNU"))
- /* GNU-specific object file notes. */
- nt = get_gnu_elf_note_type (pnote->type);
-
- else if (startswith (pnote->namedata, "AMDGPU"))
- /* AMDGPU-specific object file notes. */
- nt = get_amdgpu_elf_note_type (pnote->type);
-
- else if (startswith (pnote->namedata, "FreeBSD"))
- /* FreeBSD-specific core file notes. */
- nt = get_freebsd_elfcore_note_type (filedata, pnote->type);
-
- else if (startswith (pnote->namedata, "NetBSD-CORE"))
- /* NetBSD-specific core file notes. */
- nt = get_netbsd_elfcore_note_type (filedata, pnote->type);
-
- else if (startswith (pnote->namedata, "NetBSD"))
- /* NetBSD-specific core file notes. */
- return process_netbsd_elf_note (pnote);
-
- else if (startswith (pnote->namedata, "PaX"))
- /* NetBSD-specific core file notes. */
- return process_netbsd_elf_note (pnote);
-
- else if (startswith (pnote->namedata, "OpenBSD"))
- /* OpenBSD-specific core file notes. */
- nt = get_openbsd_elfcore_note_type (filedata, pnote->type);
-
- else if (startswith (pnote->namedata, "QNX"))
- /* QNX-specific core file notes. */
- nt = get_qnx_elfcore_note_type (filedata, pnote->type);
-
- else if (startswith (pnote->namedata, "SPU/"))
- {
- /* SPU-specific core file notes. */
- nt = pnote->namedata + 4;
- name = "SPU";
- }
-
- else if (startswith (pnote->namedata, "IPF/VMS"))
- /* VMS/ia64-specific file notes. */
- nt = get_ia64_vms_note_type (pnote->type);
-
- else if (startswith (pnote->namedata, "stapsdt"))
- nt = get_stapsdt_note_type (pnote->type);
-
- else
- /* Don't recognize this note name; just use the default set of
- note type strings. */
- nt = get_note_type (filedata, pnote->type);
-
- printf (" ");
-
- if (((startswith (pnote->namedata, "GA")
- && strchr ("*$!+", pnote->namedata[2]) != NULL)
- || strchr ("*$!+", pnote->namedata[0]) != NULL)
- && (pnote->type == NT_GNU_BUILD_ATTRIBUTE_OPEN
- || pnote->type == NT_GNU_BUILD_ATTRIBUTE_FUNC))
- print_gnu_build_attribute_name (pnote);
- else
- print_symbol_name (-20, name);
-
- if (do_wide)
- printf (" 0x%08lx\t%s\t", pnote->descsz, nt);
- else
- printf (" 0x%08lx\t%s\n", pnote->descsz, nt);
-
- if (startswith (pnote->namedata, "IPF/VMS"))
- return print_ia64_vms_note (pnote);
- else if (startswith (pnote->namedata, "GNU"))
- return print_gnu_note (filedata, pnote);
- else if (startswith (pnote->namedata, "stapsdt"))
- return print_stapsdt_note (pnote);
- else if (startswith (pnote->namedata, "CORE"))
- return print_core_note (pnote);
- else if (startswith (pnote->namedata, "FDO"))
- return print_fdo_note (pnote);
- else if (((startswith (pnote->namedata, "GA")
- && strchr ("*$!+", pnote->namedata[2]) != NULL)
- || strchr ("*$!+", pnote->namedata[0]) != NULL)
- && (pnote->type == NT_GNU_BUILD_ATTRIBUTE_OPEN
- || pnote->type == NT_GNU_BUILD_ATTRIBUTE_FUNC))
- return print_gnu_build_attribute_description (pnote, filedata);
- else if (startswith (pnote->namedata, "AMDGPU")
- && pnote->type == NT_AMDGPU_METADATA)
- return print_amdgpu_note (pnote);
- else if (startswith (pnote->namedata, "QNX"))
- return print_qnx_note (pnote);
-
- print_note_contents_hex (pnote);
- return true;
-}
-
-static bool
-process_notes_at (Filedata * filedata,
- Elf_Internal_Shdr * section,
- uint64_t offset,
- uint64_t length,
- uint64_t align)
-{
- Elf_External_Note *pnotes;
- Elf_External_Note *external;
- char *end;
- bool res = true;
-
- if (length <= 0)
- return false;
-
- if (section)
- {
- pnotes = (Elf_External_Note *) get_section_contents (section, filedata);
- if (pnotes)
- {
- if (! apply_relocations (filedata, section, (unsigned char *) pnotes, length, NULL, NULL))
- {
- free (pnotes);
- return false;
- }
- }
- }
- else
- pnotes = (Elf_External_Note *) get_data (NULL, filedata, offset, 1, length,
- _("notes"));
-
- if (pnotes == NULL)
- return false;
-
- external = pnotes;
-
- if (filedata->is_separate)
- printf (_("In linked file '%s': "), filedata->file_name);
- else
- printf ("\n");
- if (section)
- printf (_("Displaying notes found in: %s\n"), printable_section_name (filedata, section));
- else
- printf (_("Displaying notes found at file offset 0x%08" PRIx64
- " with length 0x%08" PRIx64 ":\n"),
- offset, length);
-
- /* NB: Some note sections may have alignment value of 0 or 1. gABI
- specifies that notes should be aligned to 4 bytes in 32-bit
- objects and to 8 bytes in 64-bit objects. As a Linux extension,
- we also support 4 byte alignment in 64-bit objects. If section
- alignment is less than 4, we treate alignment as 4 bytes. */
- if (align < 4)
- align = 4;
- else if (align != 4 && align != 8)
- {
- warn (_("Corrupt note: alignment %" PRId64 ", expecting 4 or 8\n"),
- align);
- free (pnotes);
- return false;
- }
-
- printf (_(" %-20s %-10s\tDescription\n"), _("Owner"), _("Data size"));
-
- end = (char *) pnotes + length;
- while ((char *) external < end)
- {
- Elf_Internal_Note inote;
- size_t min_notesz;
- char * next;
- char * temp = NULL;
- size_t data_remaining = end - (char *) external;
-
- if (!is_ia64_vms (filedata))
- {
- /* PR binutils/15191
- Make sure that there is enough data to read. */
- min_notesz = offsetof (Elf_External_Note, name);
- if (data_remaining < min_notesz)
- {
- warn (ngettext ("Corrupt note: only %zd byte remains, "
- "not enough for a full note\n",
- "Corrupt note: only %zd bytes remain, "
- "not enough for a full note\n",
- data_remaining),
- data_remaining);
- break;
- }
- data_remaining -= min_notesz;
-
- inote.type = BYTE_GET (external->type);
- inote.namesz = BYTE_GET (external->namesz);
- inote.namedata = external->name;
- inote.descsz = BYTE_GET (external->descsz);
- inote.descdata = ((char *) external
- + ELF_NOTE_DESC_OFFSET (inote.namesz, align));
- inote.descpos = offset + (inote.descdata - (char *) pnotes);
- next = ((char *) external
- + ELF_NOTE_NEXT_OFFSET (inote.namesz, inote.descsz, align));
- }
- else
- {
- Elf64_External_VMS_Note *vms_external;
-
- /* PR binutils/15191
- Make sure that there is enough data to read. */
- min_notesz = offsetof (Elf64_External_VMS_Note, name);
- if (data_remaining < min_notesz)
- {
- warn (ngettext ("Corrupt note: only %zd byte remains, "
- "not enough for a full note\n",
- "Corrupt note: only %zd bytes remain, "
- "not enough for a full note\n",
- data_remaining),
- data_remaining);
- break;
- }
- data_remaining -= min_notesz;
-
- vms_external = (Elf64_External_VMS_Note *) external;
- inote.type = BYTE_GET (vms_external->type);
- inote.namesz = BYTE_GET (vms_external->namesz);
- inote.namedata = vms_external->name;
- inote.descsz = BYTE_GET (vms_external->descsz);
- inote.descdata = inote.namedata + align_power (inote.namesz, 3);
- inote.descpos = offset + (inote.descdata - (char *) pnotes);
- next = inote.descdata + align_power (inote.descsz, 3);
- }
-
- /* PR 17531: file: 3443835e. */
- /* PR 17531: file: id:000000,sig:11,src:006986,op:havoc,rep:4. */
- if ((size_t) (inote.descdata - inote.namedata) < inote.namesz
- || (size_t) (inote.descdata - inote.namedata) > data_remaining
- || (size_t) (next - inote.descdata) < inote.descsz
- || ((size_t) (next - inote.descdata)
- > data_remaining - (size_t) (inote.descdata - inote.namedata)))
- {
- warn (_("note with invalid namesz and/or descsz found at offset %#tx\n"),
- (char *) external - (char *) pnotes);
- warn (_(" type: %#lx, namesize: %#lx, descsize: %#lx, alignment: %u\n"),
- inote.type, inote.namesz, inote.descsz, (int) align);
- break;
- }
-
- external = (Elf_External_Note *) next;
-
- /* Verify that name is null terminated. It appears that at least
- one version of Linux (RedHat 6.0) generates corefiles that don't
- comply with the ELF spec by failing to include the null byte in
- namesz. */
- if (inote.namesz > 0 && inote.namedata[inote.namesz - 1] != '\0')
- {
- if ((size_t) (inote.descdata - inote.namedata) == inote.namesz)
- {
- temp = (char *) malloc (inote.namesz + 1);
- if (temp == NULL)
- {
- error (_("Out of memory allocating space for inote name\n"));
- res = false;
- break;
- }
-
- memcpy (temp, inote.namedata, inote.namesz);
- inote.namedata = temp;
- }
- inote.namedata[inote.namesz] = 0;
- }
-
- if (! process_note (& inote, filedata))
- res = false;
-
- free (temp);
- temp = NULL;
- }
-
- free (pnotes);
-
- return res;
-}
-
-static bool
-process_corefile_note_segments (Filedata * filedata)
-{
- Elf_Internal_Phdr *segment;
- unsigned int i;
- bool res = true;
-
- if (! get_program_headers (filedata))
- return true;
-
- for (i = 0, segment = filedata->program_headers;
- i < filedata->file_header.e_phnum;
- i++, segment++)
- {
- if (segment->p_type == PT_NOTE)
- if (! process_notes_at (filedata, NULL, segment->p_offset,
- segment->p_filesz, segment->p_align))
- res = false;
- }
-
- return res;
-}
-
-static bool
-process_v850_notes (Filedata * filedata, uint64_t offset, uint64_t length)
-{
- Elf_External_Note * pnotes;
- Elf_External_Note * external;
- char * end;
- bool res = true;
-
- if (length <= 0)
- return false;
-
- pnotes = (Elf_External_Note *) get_data (NULL, filedata, offset, 1, length,
- _("v850 notes"));
- if (pnotes == NULL)
- return false;
-
- external = pnotes;
- end = (char*) pnotes + length;
-
- printf (_("\nDisplaying contents of Renesas V850 notes section at offset"
- " %#" PRIx64 " with length %#" PRIx64 ":\n"),
- offset, length);
-
- while ((char *) external + sizeof (Elf_External_Note) < end)
- {
- Elf_External_Note * next;
- Elf_Internal_Note inote;
-
- inote.type = BYTE_GET (external->type);
- inote.namesz = BYTE_GET (external->namesz);
- inote.namedata = external->name;
- inote.descsz = BYTE_GET (external->descsz);
- inote.descdata = inote.namedata + align_power (inote.namesz, 2);
- inote.descpos = offset + (inote.descdata - (char *) pnotes);
-
- if (inote.descdata < (char *) pnotes || inote.descdata >= end)
- {
- warn (_("Corrupt note: name size is too big: %lx\n"), inote.namesz);
- inote.descdata = inote.namedata;
- inote.namesz = 0;
- }
-
- next = (Elf_External_Note *) (inote.descdata + align_power (inote.descsz, 2));
-
- if ( ((char *) next > end)
- || ((char *) next < (char *) pnotes))
- {
- warn (_("corrupt descsz found in note at offset %#tx\n"),
- (char *) external - (char *) pnotes);
- warn (_(" type: %#lx, namesize: %#lx, descsize: %#lx\n"),
- inote.type, inote.namesz, inote.descsz);
- break;
- }
-
- external = next;
-
- /* Prevent out-of-bounds indexing. */
- if ( inote.namedata + inote.namesz > end
- || inote.namedata + inote.namesz < inote.namedata)
- {
- warn (_("corrupt namesz found in note at offset %#zx\n"),
- (char *) external - (char *) pnotes);
- warn (_(" type: %#lx, namesize: %#lx, descsize: %#lx\n"),
- inote.type, inote.namesz, inote.descsz);
- break;
- }
-
- printf (" %s: ", get_v850_elf_note_type (inote.type));
-
- if (! print_v850_note (& inote))
- {
- res = false;
- printf ("<corrupt sizes: namesz: %#lx, descsz: %#lx>\n",
- inote.namesz, inote.descsz);
- }
- }
-
- free (pnotes);
-
- return res;
-}
-
-static bool
-process_note_sections (Filedata * filedata)
-{
- Elf_Internal_Shdr *section;
- size_t i;
- unsigned int n = 0;
- bool res = true;
-
- for (i = 0, section = filedata->section_headers;
- i < filedata->file_header.e_shnum && section != NULL;
- i++, section++)
- {
- if (section->sh_type == SHT_NOTE)
- {
- if (! process_notes_at (filedata, section, section->sh_offset,
- section->sh_size, section->sh_addralign))
- res = false;
- n++;
- }
-
- if (( filedata->file_header.e_machine == EM_V800
- || filedata->file_header.e_machine == EM_V850
- || filedata->file_header.e_machine == EM_CYGNUS_V850)
- && section->sh_type == SHT_RENESAS_INFO)
- {
- if (! process_v850_notes (filedata, section->sh_offset,
- section->sh_size))
- res = false;
- n++;
- }
- }
-
- if (n == 0)
- /* Try processing NOTE segments instead. */
- return process_corefile_note_segments (filedata);
-
- return res;
-}
-
-static bool
-process_notes (Filedata * filedata)
-{
- /* If we have not been asked to display the notes then do nothing. */
- if (! do_notes)
- return true;
-
- if (filedata->file_header.e_type != ET_CORE)
- return process_note_sections (filedata);
-
- /* No program headers means no NOTE segment. */
- if (filedata->file_header.e_phnum > 0)
- return process_corefile_note_segments (filedata);
-
- if (filedata->is_separate)
- printf (_("No notes found in linked file '%s'.\n"),
- filedata->file_name);
- else
- printf (_("No notes found file.\n"));
-
- return true;
-}
-
-static unsigned char *
-display_public_gnu_attributes (unsigned char * start,
- const unsigned char * const end)
-{
- printf (_(" Unknown GNU attribute: %s\n"), start);
-
- start += strnlen ((char *) start, end - start);
- display_raw_attribute (start, end);
-
- return (unsigned char *) end;
-}
-
-static unsigned char *
-display_generic_attribute (unsigned char * start,
- unsigned int tag,
- const unsigned char * const end)
-{
- if (tag == 0)
- return (unsigned char *) end;
-
- return display_tag_value (tag, start, end);
-}
-
-static bool
-process_arch_specific (Filedata * filedata)
-{
- if (! do_arch)
- return true;
-
- switch (filedata->file_header.e_machine)
- {
- case EM_ARC:
- case EM_ARC_COMPACT:
- case EM_ARC_COMPACT2:
- case EM_ARC_COMPACT3:
- case EM_ARC_COMPACT3_64:
- return process_attributes (filedata, "ARC", SHT_ARC_ATTRIBUTES,
- display_arc_attribute,
- display_generic_attribute);
- case EM_ARM:
- return process_attributes (filedata, "aeabi", SHT_ARM_ATTRIBUTES,
- display_arm_attribute,
- display_generic_attribute);
-
- case EM_MIPS:
- case EM_MIPS_RS3_LE:
- return process_mips_specific (filedata);
-
- case EM_MSP430:
- return process_attributes (filedata, "mspabi", SHT_MSP430_ATTRIBUTES,
- display_msp430_attribute,
- display_msp430_gnu_attribute);
-
- case EM_RISCV:
- return process_attributes (filedata, "riscv", SHT_RISCV_ATTRIBUTES,
- display_riscv_attribute,
- display_generic_attribute);
-
- case EM_NDS32:
- return process_nds32_specific (filedata);
-
- case EM_68K:
- return process_attributes (filedata, NULL, SHT_GNU_ATTRIBUTES, NULL,
- display_m68k_gnu_attribute);
-
- case EM_PPC:
- case EM_PPC64:
- return process_attributes (filedata, NULL, SHT_GNU_ATTRIBUTES, NULL,
- display_power_gnu_attribute);
-
- case EM_S390:
- case EM_S390_OLD:
- return process_attributes (filedata, NULL, SHT_GNU_ATTRIBUTES, NULL,
- display_s390_gnu_attribute);
-
- case EM_SPARC:
- case EM_SPARC32PLUS:
- case EM_SPARCV9:
- return process_attributes (filedata, NULL, SHT_GNU_ATTRIBUTES, NULL,
- display_sparc_gnu_attribute);
-
- case EM_TI_C6000:
- return process_attributes (filedata, "c6xabi", SHT_C6000_ATTRIBUTES,
- display_tic6x_attribute,
- display_generic_attribute);
-
- case EM_CSKY:
- return process_attributes (filedata, "csky", SHT_CSKY_ATTRIBUTES,
- display_csky_attribute, NULL);
-
- default:
- return process_attributes (filedata, "gnu", SHT_GNU_ATTRIBUTES,
- display_public_gnu_attributes,
- display_generic_attribute);
- }
-}
-
-static bool
-get_file_header (Filedata * filedata)
-{
- /* Read in the identity array. */
- if (fread (filedata->file_header.e_ident, EI_NIDENT, 1, filedata->handle) != 1)
- return false;
-
- /* Determine how to read the rest of the header. */
- switch (filedata->file_header.e_ident[EI_DATA])
- {
- default:
- case ELFDATANONE:
- case ELFDATA2LSB:
- byte_get = byte_get_little_endian;
- byte_put = byte_put_little_endian;
- break;
- case ELFDATA2MSB:
- byte_get = byte_get_big_endian;
- byte_put = byte_put_big_endian;
- break;
- }
-
- /* For now we only support 32 bit and 64 bit ELF files. */
- is_32bit_elf = (filedata->file_header.e_ident[EI_CLASS] != ELFCLASS64);
-
- /* Read in the rest of the header. */
- if (is_32bit_elf)
- {
- Elf32_External_Ehdr ehdr32;
-
- if (fread (ehdr32.e_type, sizeof (ehdr32) - EI_NIDENT, 1, filedata->handle) != 1)
- return false;
-
- filedata->file_header.e_type = BYTE_GET (ehdr32.e_type);
- filedata->file_header.e_machine = BYTE_GET (ehdr32.e_machine);
- filedata->file_header.e_version = BYTE_GET (ehdr32.e_version);
- filedata->file_header.e_entry = BYTE_GET (ehdr32.e_entry);
- filedata->file_header.e_phoff = BYTE_GET (ehdr32.e_phoff);
- filedata->file_header.e_shoff = BYTE_GET (ehdr32.e_shoff);
- filedata->file_header.e_flags = BYTE_GET (ehdr32.e_flags);
- filedata->file_header.e_ehsize = BYTE_GET (ehdr32.e_ehsize);
- filedata->file_header.e_phentsize = BYTE_GET (ehdr32.e_phentsize);
- filedata->file_header.e_phnum = BYTE_GET (ehdr32.e_phnum);
- filedata->file_header.e_shentsize = BYTE_GET (ehdr32.e_shentsize);
- filedata->file_header.e_shnum = BYTE_GET (ehdr32.e_shnum);
- filedata->file_header.e_shstrndx = BYTE_GET (ehdr32.e_shstrndx);
- }
- else
- {
- Elf64_External_Ehdr ehdr64;
-
- if (fread (ehdr64.e_type, sizeof (ehdr64) - EI_NIDENT, 1, filedata->handle) != 1)
- return false;
-
- filedata->file_header.e_type = BYTE_GET (ehdr64.e_type);
- filedata->file_header.e_machine = BYTE_GET (ehdr64.e_machine);
- filedata->file_header.e_version = BYTE_GET (ehdr64.e_version);
- filedata->file_header.e_entry = BYTE_GET (ehdr64.e_entry);
- filedata->file_header.e_phoff = BYTE_GET (ehdr64.e_phoff);
- filedata->file_header.e_shoff = BYTE_GET (ehdr64.e_shoff);
- filedata->file_header.e_flags = BYTE_GET (ehdr64.e_flags);
- filedata->file_header.e_ehsize = BYTE_GET (ehdr64.e_ehsize);
- filedata->file_header.e_phentsize = BYTE_GET (ehdr64.e_phentsize);
- filedata->file_header.e_phnum = BYTE_GET (ehdr64.e_phnum);
- filedata->file_header.e_shentsize = BYTE_GET (ehdr64.e_shentsize);
- filedata->file_header.e_shnum = BYTE_GET (ehdr64.e_shnum);
- filedata->file_header.e_shstrndx = BYTE_GET (ehdr64.e_shstrndx);
- }
-
- return true;
-}
-
-static void
-free_filedata (Filedata *filedata)
-{
- free (filedata->program_interpreter);
- free (filedata->program_headers);
- free (filedata->section_headers);
- free (filedata->string_table);
- free (filedata->dump.dump_sects);
- free (filedata->dynamic_strings);
- free (filedata->dynamic_symbols);
- free (filedata->dynamic_syminfo);
- free (filedata->dynamic_section);
-
- while (filedata->symtab_shndx_list != NULL)
- {
- elf_section_list *next = filedata->symtab_shndx_list->next;
- free (filedata->symtab_shndx_list);
- filedata->symtab_shndx_list = next;
- }
-
- free (filedata->section_headers_groups);
-
- if (filedata->section_groups)
- {
- size_t i;
- struct group_list * g;
- struct group_list * next;
-
- for (i = 0; i < filedata->group_count; i++)
- {
- for (g = filedata->section_groups [i].root; g != NULL; g = next)
- {
- next = g->next;
- free (g);
- }
- }
-
- free (filedata->section_groups);
- }
- memset (&filedata->section_headers, 0,
- sizeof (Filedata) - offsetof (Filedata, section_headers));
-}
-
-static void
-close_file (Filedata * filedata)
-{
- if (filedata)
- {
- if (filedata->handle)
- fclose (filedata->handle);
- free (filedata);
- }
-}
-
-void
-close_debug_file (void * data)
-{
- free_filedata ((Filedata *) data);
- close_file ((Filedata *) data);
-}
-
-static Filedata *
-open_file (const char * pathname, bool is_separate)
-{
- struct stat statbuf;
- Filedata * filedata = NULL;
-
- if (stat (pathname, & statbuf) < 0
- || ! S_ISREG (statbuf.st_mode))
- goto fail;
-
- filedata = calloc (1, sizeof * filedata);
- if (filedata == NULL)
- goto fail;
-
- filedata->handle = fopen (pathname, "rb");
- if (filedata->handle == NULL)
- goto fail;
-
- filedata->file_size = statbuf.st_size;
- filedata->file_name = pathname;
- filedata->is_separate = is_separate;
-
- if (! get_file_header (filedata))
- goto fail;
-
- if (!get_section_headers (filedata, false))
- goto fail;
-
- return filedata;
-
- fail:
- if (filedata)
- {
- if (filedata->handle)
- fclose (filedata->handle);
- free (filedata);
- }
- return NULL;
-}
-
-void *
-open_debug_file (const char * pathname)
-{
- return open_file (pathname, true);
-}
-
-static void
-initialise_dump_sects (Filedata * filedata)
-{
- /* Initialise the dump_sects array from the cmdline_dump_sects array.
- Note we do this even if cmdline_dump_sects is empty because we
- must make sure that the dump_sets array is zeroed out before each
- object file is processed. */
- if (filedata->dump.num_dump_sects > cmdline.num_dump_sects)
- memset (filedata->dump.dump_sects, 0,
- filedata->dump.num_dump_sects * sizeof (*filedata->dump.dump_sects));
-
- if (cmdline.num_dump_sects > 0)
- {
- if (filedata->dump.num_dump_sects == 0)
- /* A sneaky way of allocating the dump_sects array. */
- request_dump_bynumber (&filedata->dump, cmdline.num_dump_sects, 0);
-
- assert (filedata->dump.num_dump_sects >= cmdline.num_dump_sects);
- memcpy (filedata->dump.dump_sects, cmdline.dump_sects,
- cmdline.num_dump_sects * sizeof (*filedata->dump.dump_sects));
- }
-}
-
-static bool
-might_need_separate_debug_info (Filedata * filedata)
-{
- /* Debuginfo files do not need further separate file loading. */
- if (filedata->file_header.e_shstrndx == SHN_UNDEF)
- return false;
-
- /* Since do_follow_links might be enabled by default, only treat it as an
- indication that separate files should be loaded if setting it was a
- deliberate user action. */
- if (DEFAULT_FOR_FOLLOW_LINKS == 0 && do_follow_links)
- return true;
-
- if (process_links || do_syms || do_unwind
- || dump_any_debugging || do_dump || do_debugging)
- return true;
-
- return false;
-}
-
-/* Process one ELF object file according to the command line options.
- This file may actually be stored in an archive. The file is
- positioned at the start of the ELF object. Returns TRUE if no
- problems were encountered, FALSE otherwise. */
-
-static bool
-process_object (Filedata * filedata)
-{
- bool have_separate_files;
- unsigned int i;
- bool res;
-
- if (! get_file_header (filedata))
- {
- error (_("%s: Failed to read file header\n"), filedata->file_name);
- return false;
- }
-
- /* Initialise per file variables. */
- for (i = ARRAY_SIZE (filedata->version_info); i--;)
- filedata->version_info[i] = 0;
-
- for (i = ARRAY_SIZE (filedata->dynamic_info); i--;)
- filedata->dynamic_info[i] = 0;
- filedata->dynamic_info_DT_GNU_HASH = 0;
- filedata->dynamic_info_DT_MIPS_XHASH = 0;
-
- /* Process the file. */
- if (show_name)
- printf (_("\nFile: %s\n"), filedata->file_name);
-
- initialise_dump_sects (filedata);
-
- /* There may be some extensions in the first section header. Don't
- bomb if we can't read it. */
- get_section_headers (filedata, true);
-
- if (! process_file_header (filedata))
- {
- res = false;
- goto out;
- }
-
- /* Throw away the single section header read above, so that we
- re-read the entire set. */
- free (filedata->section_headers);
- filedata->section_headers = NULL;
-
- if (! process_section_headers (filedata))
- {
- /* Without loaded section headers we cannot process lots of things. */
- do_unwind = do_version = do_dump = do_arch = false;
-
- if (! do_using_dynamic)
- do_syms = do_dyn_syms = do_reloc = false;
- }
-
- if (! process_section_groups (filedata))
- /* Without loaded section groups we cannot process unwind. */
- do_unwind = false;
-
- process_program_headers (filedata);
-
- res = process_dynamic_section (filedata);
-
- if (! process_relocs (filedata))
- res = false;
-
- if (! process_unwind (filedata))
- res = false;
-
- if (! process_symbol_table (filedata))
- res = false;
-
- if (! process_lto_symbol_tables (filedata))
- res = false;
-
- if (! process_syminfo (filedata))
- res = false;
-
- if (! process_version_sections (filedata))
- res = false;
-
- if (might_need_separate_debug_info (filedata))
- have_separate_files = load_separate_debug_files (filedata, filedata->file_name);
- else
- have_separate_files = false;
-
- if (! process_section_contents (filedata))
- res = false;
-
- if (have_separate_files)
- {
- separate_info * d;
-
- for (d = first_separate_info; d != NULL; d = d->next)
- {
- initialise_dump_sects (d->handle);
-
- if (process_links && ! process_file_header (d->handle))
- res = false;
- else if (! process_section_headers (d->handle))
- res = false;
- else if (! process_section_contents (d->handle))
- res = false;
- else if (process_links)
- {
- if (! process_section_groups (d->handle))
- res = false;
- process_program_headers (d->handle);
- if (! process_dynamic_section (d->handle))
- res = false;
- if (! process_relocs (d->handle))
- res = false;
- if (! process_unwind (d->handle))
- res = false;
- if (! process_symbol_table (d->handle))
- res = false;
- if (! process_lto_symbol_tables (d->handle))
- res = false;
- if (! process_syminfo (d->handle))
- res = false;
- if (! process_version_sections (d->handle))
- res = false;
- if (! process_notes (d->handle))
- res = false;
- }
- }
-
- /* The file handles are closed by the call to free_debug_memory() below. */
- }
-
- if (! process_notes (filedata))
- res = false;
-
- if (! process_gnu_liblist (filedata))
- res = false;
-
- if (! process_arch_specific (filedata))
- res = false;
-
- out:
- free_filedata (filedata);
-
- free_debug_memory ();
-
- return res;
-}
-
-/* Process an ELF archive.
- On entry the file is positioned just after the ARMAG string.
- Returns TRUE upon success, FALSE otherwise. */
-
-static bool
-process_archive (Filedata * filedata, bool is_thin_archive)
-{
- struct archive_info arch;
- struct archive_info nested_arch;
- size_t got;
- bool ret = true;
-
- show_name = true;
-
- /* The ARCH structure is used to hold information about this archive. */
- arch.file_name = NULL;
- arch.file = NULL;
- arch.index_array = NULL;
- arch.sym_table = NULL;
- arch.longnames = NULL;
-
- /* The NESTED_ARCH structure is used as a single-item cache of information
- about a nested archive (when members of a thin archive reside within
- another regular archive file). */
- nested_arch.file_name = NULL;
- nested_arch.file = NULL;
- nested_arch.index_array = NULL;
- nested_arch.sym_table = NULL;
- nested_arch.longnames = NULL;
-
- if (setup_archive (&arch, filedata->file_name, filedata->handle,
- filedata->file_size, is_thin_archive,
- do_archive_index) != 0)
- {
- ret = false;
- goto out;
- }
-
- if (do_archive_index)
- {
- if (arch.sym_table == NULL)
- error (_("%s: unable to dump the index as none was found\n"),
- filedata->file_name);
- else
- {
- uint64_t i, l;
- uint64_t current_pos;
-
- printf (_("Index of archive %s: (%" PRIu64 " entries,"
- " %#" PRIx64 " bytes in the symbol table)\n"),
- filedata->file_name, arch.index_num,
- arch.sym_size);
-
- current_pos = ftell (filedata->handle);
-
- for (i = l = 0; i < arch.index_num; i++)
- {
- if (i == 0
- || (i > 0 && arch.index_array[i] != arch.index_array[i - 1]))
- {
- char * member_name
- = get_archive_member_name_at (&arch, arch.index_array[i],
- &nested_arch);
-
- if (member_name != NULL)
- {
- char * qualified_name
- = make_qualified_name (&arch, &nested_arch,
- member_name);
-
- if (qualified_name != NULL)
- {
- printf (_("Contents of binary %s at offset "),
- qualified_name);
- (void) print_vma (arch.index_array[i], PREFIX_HEX);
- putchar ('\n');
- free (qualified_name);
- }
- free (member_name);
- }
- }
-
- if (l >= arch.sym_size)
- {
- error (_("%s: end of the symbol table reached "
- "before the end of the index\n"),
- filedata->file_name);
- ret = false;
- break;
- }
- /* PR 17531: file: 0b6630b2. */
- printf ("\t%.*s\n",
- (int) (arch.sym_size - l), arch.sym_table + l);
- l += strnlen (arch.sym_table + l, arch.sym_size - l) + 1;
- }
-
- if (arch.uses_64bit_indices)
- l = (l + 7) & ~ 7;
- else
- l += l & 1;
-
- if (l < arch.sym_size)
- {
- error (ngettext ("%s: %" PRId64 " byte remains in the symbol table, "
- "but without corresponding entries in "
- "the index table\n",
- "%s: %" PRId64 " bytes remain in the symbol table, "
- "but without corresponding entries in "
- "the index table\n",
- arch.sym_size - l),
- filedata->file_name, arch.sym_size - l);
- ret = false;
- }
-
- if (fseek64 (filedata->handle, current_pos, SEEK_SET) != 0)
- {
- error (_("%s: failed to seek back to start of object files "
- "in the archive\n"),
- filedata->file_name);
- ret = false;
- goto out;
- }
- }
-
- if (!do_dynamic && !do_syms && !do_reloc && !do_unwind && !do_sections
- && !do_segments && !do_header && !do_dump && !do_version
- && !do_histogram && !do_debugging && !do_arch && !do_notes
- && !do_section_groups && !do_dyn_syms)
- {
- ret = true; /* Archive index only. */
- goto out;
- }
- }
-
- while (1)
- {
- char * name;
- size_t namelen;
- char * qualified_name;
-
- /* Read the next archive header. */
- if (fseek64 (filedata->handle, arch.next_arhdr_offset, SEEK_SET) != 0)
- {
- error (_("%s: failed to seek to next archive header\n"),
- arch.file_name);
- ret = false;
- break;
- }
- got = fread (&arch.arhdr, 1, sizeof arch.arhdr, filedata->handle);
- if (got != sizeof arch.arhdr)
- {
- if (got == 0)
- break;
- /* PR 24049 - we cannot use filedata->file_name as this will
- have already been freed. */
- error (_("%s: failed to read archive header\n"), arch.file_name);
-
- ret = false;
- break;
- }
- if (memcmp (arch.arhdr.ar_fmag, ARFMAG, 2) != 0)
- {
- error (_("%s: did not find a valid archive header\n"),
- arch.file_name);
- ret = false;
- break;
- }
-
- arch.next_arhdr_offset += sizeof arch.arhdr;
-
- filedata->archive_file_size = strtoul (arch.arhdr.ar_size, NULL, 10);
-
- name = get_archive_member_name (&arch, &nested_arch);
- if (name == NULL)
- {
- error (_("%s: bad archive file name\n"), arch.file_name);
- ret = false;
- break;
- }
- namelen = strlen (name);
-
- qualified_name = make_qualified_name (&arch, &nested_arch, name);
- if (qualified_name == NULL)
- {
- error (_("%s: bad archive file name\n"), arch.file_name);
- free (name);
- ret = false;
- break;
- }
-
- if (is_thin_archive && arch.nested_member_origin == 0)
- {
- /* This is a proxy for an external member of a thin archive. */
- Filedata * member_filedata;
- char * member_file_name = adjust_relative_path
- (filedata->file_name, name, namelen);
-
- free (name);
- if (member_file_name == NULL)
- {
- free (qualified_name);
- ret = false;
- break;
- }
-
- member_filedata = open_file (member_file_name, false);
- if (member_filedata == NULL)
- {
- error (_("Input file '%s' is not readable.\n"), member_file_name);
- free (member_file_name);
- free (qualified_name);
- ret = false;
- break;
- }
-
- filedata->archive_file_offset = arch.nested_member_origin;
- member_filedata->file_name = qualified_name;
-
- /* The call to process_object() expects the file to be at the beginning. */
- rewind (member_filedata->handle);
-
- if (! process_object (member_filedata))
- ret = false;
-
- close_file (member_filedata);
- free (member_file_name);
- }
- else if (is_thin_archive)
- {
- Filedata thin_filedata;
-
- memset (&thin_filedata, 0, sizeof (thin_filedata));
-
- /* PR 15140: Allow for corrupt thin archives. */
- if (nested_arch.file == NULL)
- {
- error (_("%s: contains corrupt thin archive: %s\n"),
- qualified_name, name);
- free (qualified_name);
- free (name);
- ret = false;
- break;
- }
- free (name);
-
- /* This is a proxy for a member of a nested archive. */
- filedata->archive_file_offset
- = arch.nested_member_origin + sizeof arch.arhdr;
-
- /* The nested archive file will have been opened and setup by
- get_archive_member_name. */
- if (fseek64 (nested_arch.file, filedata->archive_file_offset,
- SEEK_SET) != 0)
- {
- error (_("%s: failed to seek to archive member.\n"),
- nested_arch.file_name);
- free (qualified_name);
- ret = false;
- break;
- }
-
- thin_filedata.handle = nested_arch.file;
- thin_filedata.file_name = qualified_name;
-
- if (! process_object (& thin_filedata))
- ret = false;
- }
- else
- {
- free (name);
- filedata->archive_file_offset = arch.next_arhdr_offset;
- filedata->file_name = qualified_name;
- if (! process_object (filedata))
- ret = false;
- arch.next_arhdr_offset += (filedata->archive_file_size + 1) & -2;
- /* Stop looping with "negative" archive_file_size. */
- if (arch.next_arhdr_offset < filedata->archive_file_size)
- arch.next_arhdr_offset = -1ul;
- }
-
- free (qualified_name);
- }
-
- out:
- if (nested_arch.file != NULL)
- fclose (nested_arch.file);
- release_archive (&nested_arch);
- release_archive (&arch);
-
- return ret;
-}
-
-static bool
-process_file (char * file_name)
-{
- Filedata * filedata = NULL;
- struct stat statbuf;
- char armag[SARMAG];
- bool ret = true;
-
- if (stat (file_name, &statbuf) < 0)
- {
- if (errno == ENOENT)
- error (_("'%s': No such file\n"), file_name);
- else
- error (_("Could not locate '%s'. System error message: %s\n"),
- file_name, strerror (errno));
- return false;
- }
-
- if (! S_ISREG (statbuf.st_mode))
- {
- error (_("'%s' is not an ordinary file\n"), file_name);
- return false;
- }
-
- filedata = calloc (1, sizeof * filedata);
- if (filedata == NULL)
- {
- error (_("Out of memory allocating file data structure\n"));
- return false;
- }
-
- filedata->file_name = file_name;
- filedata->handle = fopen (file_name, "rb");
- if (filedata->handle == NULL)
- {
- error (_("Input file '%s' is not readable.\n"), file_name);
- free (filedata);
- return false;
- }
-
- if (fread (armag, SARMAG, 1, filedata->handle) != 1)
- {
- error (_("%s: Failed to read file's magic number\n"), file_name);
- fclose (filedata->handle);
- free (filedata);
- return false;
- }
-
- filedata->file_size = statbuf.st_size;
- filedata->is_separate = false;
-
- if (memcmp (armag, ARMAG, SARMAG) == 0)
- {
- if (! process_archive (filedata, false))
- ret = false;
- }
- else if (memcmp (armag, ARMAGT, SARMAG) == 0)
- {
- if ( ! process_archive (filedata, true))
- ret = false;
- }
- else
- {
- if (do_archive_index && !check_all)
- error (_("File %s is not an archive so its index cannot be displayed.\n"),
- file_name);
-
- rewind (filedata->handle);
- filedata->archive_file_size = filedata->archive_file_offset = 0;
-
- if (! process_object (filedata))
- ret = false;
- }
-
- fclose (filedata->handle);
- free (filedata->section_headers);
- free (filedata->program_headers);
- free (filedata->string_table);
- free (filedata->dump.dump_sects);
- free (filedata);
-
- free (ba_cache.strtab);
- ba_cache.strtab = NULL;
- free (ba_cache.symtab);
- ba_cache.symtab = NULL;
- ba_cache.filedata = NULL;
-
- return ret;
-}
-
-#ifdef SUPPORT_DISASSEMBLY
-/* Needed by the i386 disassembler. For extra credit, someone could
- fix this so that we insert symbolic addresses here, esp for GOT/PLT
- symbols. */
-
-void
-print_address (unsigned int addr, FILE * outfile)
-{
- fprintf (outfile,"0x%8.8x", addr);
-}
-
-/* Needed by the i386 disassembler. */
-
-void
-db_task_printsym (unsigned int addr)
-{
- print_address (addr, stderr);
-}
-#endif
-
-int
-main (int argc, char ** argv)
-{
- int err;
-
-#ifdef HAVE_LC_MESSAGES
- setlocale (LC_MESSAGES, "");
-#endif
- setlocale (LC_CTYPE, "");
- bindtextdomain (PACKAGE, LOCALEDIR);
- textdomain (PACKAGE);
-
- expandargv (&argc, &argv);
-
- parse_args (& cmdline, argc, argv);
-
- if (optind < (argc - 1))
- /* When displaying information for more than one file,
- prefix the information with the file name. */
- show_name = true;
- else if (optind >= argc)
- {
- /* Ensure that the warning is always displayed. */
- do_checks = true;
-
- warn (_("Nothing to do.\n"));
- usage (stderr);
- }
-
- err = false;
- while (optind < argc)
- if (! process_file (argv[optind++]))
- err = true;
-
- free (cmdline.dump_sects);
-
- free (dump_ctf_symtab_name);
- free (dump_ctf_strtab_name);
- free (dump_ctf_parent_name);
-
- return err ? EXIT_FAILURE : EXIT_SUCCESS;
-}
Index: sources/GNU/binutils/create-2.43.1-gold-warn-unsupported-patch/file.list
===================================================================
--- sources/GNU/binutils/create-2.43.1-gold-warn-unsupported-patch/file.list (revision 75)
+++ sources/GNU/binutils/create-2.43.1-gold-warn-unsupported-patch/file.list (nonexistent)
@@ -1,4 +0,0 @@
-binutils-2.43.1/bfd/config.bfd
-binutils-2.43.1/gold/configure
-binutils-2.43.1/gold/configure.ac
-binutils-2.43.1/ld/configure.tgt
Index: sources/GNU/binutils/create-2.43.1-gold-warn-unsupported-patch/create.patch.sh
===================================================================
--- sources/GNU/binutils/create-2.43.1-gold-warn-unsupported-patch/create.patch.sh (revision 75)
+++ sources/GNU/binutils/create-2.43.1-gold-warn-unsupported-patch/create.patch.sh (nonexistent)
@@ -1,15 +0,0 @@
-#!/bin/bash
-
-VERSION=2.43.1
-
-tar --files-from=file.list -xJvf ../binutils-$VERSION.tar.xz
-mv binutils-$VERSION binutils-$VERSION-orig
-
-cp -rf ./binutils-$VERSION-new ./binutils-$VERSION
-
-diff --unified -Nr binutils-$VERSION-orig binutils-$VERSION > binutils-$VERSION-gold-warn-unsupported.patch
-
-mv binutils-$VERSION-gold-warn-unsupported.patch ../patches
-
-rm -rf ./binutils-$VERSION
-rm -rf ./binutils-$VERSION-orig
Property changes on: sources/GNU/binutils/create-2.43.1-gold-warn-unsupported-patch/create.patch.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: sources/GNU/binutils/create-2.43.1-gold-warn-unsupported-patch/binutils-2.43.1-new/ld/configure.tgt
===================================================================
--- sources/GNU/binutils/create-2.43.1-gold-warn-unsupported-patch/binutils-2.43.1-new/ld/configure.tgt (revision 75)
+++ sources/GNU/binutils/create-2.43.1-gold-warn-unsupported-patch/binutils-2.43.1-new/ld/configure.tgt (nonexistent)
@@ -1,1199 +0,0 @@
-# configure.tgt
-#
-# Copyright (C) 2013-2024 Free Software Foundation, Inc.
-#
-# This file is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 3 of the License, or
-# (at your option) any later version.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this program; see the file COPYING3. If not see
-# <http://www.gnu.org/licenses/>.
-
-# This is the linker target specific file. This is invoked by the
-# autoconf generated configure script. Putting it in a separate shell
-# file lets us skip running autoconf when modifying target specific
-# information.
-
-# This file switches on the shell variable ${targ}, and sets the
-# following shell variables:
-# targ_emul name of linker emulation to use
-# targ_extra_emuls additional linker emulations to provide
-# targ_extra_libpath additional linker emulations using LIB_PATH
-# targ_extra_ofiles additional host-compiled objects needed by the emulation
-# targ64_extra_emuls additional linker emulations to provide if
-# --enable-64-bit-bfd is given or if host is 64 bit.
-# targ64_extra_libpath additional linker emulations using LIB_PATH if
-# --enable-64-bit-bfd is given or if host is 64 bit.
-# NATIVE_LIB_DIRS library directories to search on this host
-# (if we are a native or sysrooted linker)
-
-targ_extra_emuls=
-targ_extra_libpath=
-targ_extra_ofiles="ldelf.o ldelfgen.o"
-targ64_extra_emuls=
-targ64_extra_libpath=
-
-# By default the linker will generate warnings if it is creating an
-# executable stack or a segment with all three of read, write and
-# execute permissions. These settings are not appropriate for all
-# targets however, so we can change them here:
-
-if test "${ac_default_ld_warn_rwx_segments}" = unset; then
- case "${targ}" in
- # The CRIS and V850 default linker scripts yields just one segment
- # as intended, so a rwx segment warning is not helpful.
- # The HPPA's and SPARC's PLT sections use a constructed trampoline
- # hence it needs to have a RWX segment.
- # Many MIPS targets use executable segments.
- cris-*-* | crisv32-*-* | \
- hppa*-*-* | \
- mips*-*-* | \
- microblaze*-*-* | \
- sparc*-*-* | \
- v850*-*-*)
- ac_default_ld_warn_rwx_segments=0
- ;;
- *)
- ;;
- esac
-fi
-
-if test "${ac_default_ld_warn_execstack}" = 2; then
- case "${targ}" in
- # The HPPA port needs to support older kernels that
- # use executable stacks for signals and syscalls.
- # Many MIPS targets use executable stacks.
- hppa*-*-* | \
- mips*-*-*)
- ac_default_ld_warn_execstack=0
- ;;
- *)
- ;;
- esac
-fi
-
-# Please try to keep this table more or less in alphabetic order - it
-# makes it much easier to lookup a specific archictecture.
-case "${targ}" in
-aarch64_be-*-elf) targ_emul=aarch64elfb
- targ_extra_emuls="aarch64elf aarch64elf32 aarch64elf32b armelfb armelf"
- ;;
-aarch64-*-elf | aarch64-*-rtems* | aarch64-*-genode*)
- targ_emul=aarch64elf
- targ_extra_emuls="aarch64elf32 aarch64elf32b aarch64elfb armelf armelfb"
- ;;
-aarch64-*-cloudabi*) targ_emul=aarch64cloudabi
- targ_extra_emuls=aarch64cloudabib
- ;;
-aarch64-*-freebsd*) targ_emul=aarch64fbsd
- targ_extra_emuls="aarch64fbsdb aarch64elf"
- ;;
-aarch64-*-fuchsia*) targ_emul=aarch64elf
- targ_extra_emuls="aarch64elfb armelf armelfb"
- ;;
-aarch64_be-*-linux-gnu_ilp32)
- targ_emul=aarch64linux32b
- targ_extra_libpath="aarch64linuxb aarch64linux aarch64linux32 armelfb_linux_eabi armelf_linux_eabi"
- targ_extra_emuls="aarch64elfb aarch64elf aarch64elf32 aarch64elf32b armelfb armelf $targ_extra_libpath"
- ;;
-aarch64-*-linux-gnu_ilp32)
- targ_emul=aarch64linux32
- targ_extra_libpath="aarch64linux aarch64linuxb aarch64linux32b armelfb_linux_eabi armelf_linux_eabi"
- targ_extra_emuls="aarch64elf aarch64elf32 aarch64elf32b aarch64elfb armelf armelfb $targ_extra_libpath"
- ;;
-aarch64_be-*-linux*) targ_emul=aarch64linuxb
- targ_extra_libpath="aarch64linux aarch64linux32 aarch64linux32b armelfb_linux_eabi armelf_linux_eabi"
- targ_extra_emuls="aarch64elfb aarch64elf aarch64elf32 aarch64elf32b armelfb armelf $targ_extra_libpath"
- ;;
-aarch64-*-linux*) targ_emul=aarch64linux
- targ_extra_libpath="aarch64linuxb aarch64linux32 aarch64linux32b armelfb_linux_eabi armelf_linux_eabi"
- targ_extra_emuls="aarch64elf aarch64elf32 aarch64elf32b aarch64elfb armelf armelfb $targ_extra_libpath"
- ;;
-# This has to come after aarch64-*-linux* for aarch64-*-linux-gnu to hit the Linux branch.
-aarch64-*-gnu*)
- targ_emul=aarch64gnu
- targ_extra_emuls="aarch64elf aarch64elfb armelf armelfb"
- ;;
-aarch64-*-haiku*) targ_emul=aarch64haiku
- targ_extra_emuls="aarch64elf aarch64elf32 aarch64elf32b aarch64elfb armelf armelfb armelf_haiku $targ_extra_libpath"
- ;;
-aarch64-*-nto*) targ_emul=aarch64nto
- targ_extra_emuls="aarch64elf aarch64elf32 aarch64elf32b aarch64elfb armelf armelfb"
- ;;
-aarch64-*-pe* | aarch64-*-mingw*)
- targ_emul=aarch64pe
- targ_extra_emuls="arm64pe"
- targ_extra_ofiles="deffilep.o pep-dll-aarch64.o pe-dll.o pdb.o"
- ;;
-alpha*-*-freebsd* | alpha*-*-kfreebsd*-gnu)
- targ_emul=elf64alpha_fbsd
- targ_extra_emuls="elf64alpha alpha"
- tdir_alpha=`echo ${targ_alias} | sed -e 's/freebsd/freebsdecoff/'`
- ;;
-alpha*-*-linux*ecoff*) targ_emul=alpha
- targ_extra_emuls=elf64alpha
- tdir_elf64alpha=`echo ${targ_alias} | sed -e 's/ecoff//'`
- ;;
-alpha*-*-linux-*) targ_emul=elf64alpha
- targ_extra_emuls=alpha
- tdir_alpha=`echo ${targ_alias} | sed -e 's/linux\(-gnu\)*/linux\1ecoff/'`
- ;;
-alpha*-*-osf*) targ_emul=alpha
- targ_extra_ofiles=
- ;;
-alpha*-*-gnu*) targ_emul=elf64alpha
- ;;
-alpha*-*-netbsd*) targ_emul=elf64alpha_nbsd
- ;;
-alpha*-*-openbsd*) targ_emul=elf64alpha
- ;;
-alpha*-*-*vms*) targ_emul=alphavms
- targ_extra_ofiles=
- ;;
-am33_2.0-*-linux*) targ_emul=elf32am33lin # mn10300 variant
- ;;
-arc*-*-elf*) targ_emul=arcelf
- targ_extra_emuls="arclinux arclinux_nps arcv2elf arcv2elfx"
- ;;
-arc*-*-linux*) case "${with_cpu}" in
- nps400) targ_emul=arclinux_nps
- targ_extra_emuls=arclinux
- ;;
- *) targ_emul=arclinux
- targ_extra_emuls=arclinux_nps
- ;;
- esac
- targ_extra_emuls="${targ_extra_emuls} arcelf arcv2elf arcv2elfx"
- ;;
-arm*-*-cegcc*) targ_emul=arm_wince_pe
- targ_extra_ofiles="deffilep.o pe-dll.o"
- LIB_PATH='${tooldir}/lib/w32api'
- ;;
-arm-wince-pe | arm-*-wince | arm*-*-mingw32ce*)
- targ_emul=arm_wince_pe
- targ_extra_ofiles="deffilep.o pe-dll.o"
- ;;
-arm-*-pe) targ_emul=armpe
- targ_extra_ofiles="deffilep.o pe-dll.o"
- ;;
-arm*b-*-freebsd*) targ_emul=armelfb_fbsd
- targ_extra_emuls="armelf_fbsd armelf"
- ;;
-arm*-*-freebsd* | arm-*-kfreebsd*-gnu)
- targ_emul=armelf_fbsd
- targ_extra_emuls="armelfb_fbsd armelf"
- ;;
-armeb-*-netbsd*) targ_emul=armelfb_nbsd;
- targ_extra_emuls="armelf_nbsd armelf"
- ;;
-arm-*-netbsd*) targ_emul=armelf_nbsd;
- targ_extra_emuls="armelfb_nbsd armelf"
- ;;
-arm-*-nto*) targ_emul=armnto
- ;;
-arm-*-phoenix*) targ_emul=armelf
- ;;
-armeb-*-elf | armeb-*-eabi*)
- targ_emul=armelfb
- ;;
-arm-*-elf | arm*-*-eabi* | arm-*-rtems* | arm-*-genode*)
- targ_emul=armelf
- ;;
-arm-*-kaos*) targ_emul=armelf
- ;;
-arm9e-*-elf) targ_emul=armelf
- ;;
-arm*b-*-linux-*eabi*) targ_emul=armelfb_linux_eabi
- targ_extra_emuls=armelf_linux_eabi
- targ_extra_libpath=$targ_extra_emuls
- ;;
-arm*b-*-linux-*) targ_emul=armelfb_linux
- targ_extra_emuls="armelfb armelf armelf_linux"
- targ_extra_libpath="armelf_linux"
- ;;
-arm*-*-linux-*eabi*) targ_emul=armelf_linux_eabi
- targ_extra_emuls="armelfb_linux_eabi"
- targ_extra_libpath=$targ_extra_emuls
- ;;
-arm*-*-uclinuxfdpiceabi)
- targ_emul=armelf_linux_eabi
- targ_extra_emuls="armelfb_linux_eabi armelf_linux_fdpiceabi armelfb_linux_fdpiceabi"
- targ_extra_libpath=$targ_extra_emuls
- ;;
-arm*-*-linux-*) targ_emul=armelf_linux
- targ_extra_emuls="armelf armelfb armelfb_linux"
- targ_extra_libpath="armelfb_linux"
- ;;
-arm*b-*-nacl*) targ_emul=armelfb_nacl
- targ_extra_emuls="armelf_nacl"
- targ_extra_libpath=$targ_extra_emuls
- ;;
-arm*-*-nacl*) targ_emul=armelf_nacl
- targ_extra_emuls="armelfb_nacl"
- targ_extra_libpath=$targ_extra_emuls
- ;;
-arm*-*-uclinux*eabi*) targ_emul=armelf_linux_eabi
- targ_extra_emuls=armelfb_linux_eabi
- targ_extra_libpath=$targ_extra_emuls
- ;;
-arm*-*-uclinux*) targ_emul=armelf_linux
- targ_extra_emuls="armelf armelfb armelfb_linux"
- targ_extra_libpath="armelfb_linux"
- ;;
-arm-*-vxworks) targ_emul=armelf_vxworks
- ;;
-arm*-*-conix*) targ_emul=armelf
- ;;
-arm*-*-fuchsia*) targ_emul=armelf_fuchsia
- targ_extra_emuls="armelfb_fuchsia armelf armelfb"
- ;;
-arm*-*-haiku*) targ_emul=armelf_haiku
- targ_extra_emuls=armelf
- ;;
-avr-*-*) targ_emul=avr2
- targ_extra_emuls="avr1 avr25 avr3 avr31 avr35 avr4 avr5 avr51 avr6 avrxmega1 avrxmega2 avrxmega2_flmap avrxmega3 avrxmega4 avrxmega4_flmap avrxmega5 avrxmega6 avrxmega7 avrtiny"
- ;;
-bfin-*-elf | bfin-*-rtems*)
- targ_emul=elf32bfin
- targ_extra_emuls="elf32bfinfd"
- targ_extra_libpath=$targ_extra_emuls
- ;;
-bfin-*-uclinux*) targ_emul=elf32bfin;
- targ_extra_emuls="elf32bfinfd"
- targ_extra_libpath=$targ_extra_emuls
- ;;
-bfin-*-linux-uclibc*) targ_emul=elf32bfinfd;
- targ_extra_emuls="elf32bfin"
- targ_extra_libpath=$targ_extra_emuls
- ;;
-bpf-* | bpf-*-*) targ_emul=elf64bpf
- ;;
-cr16-*-elf*) targ_emul=elf32cr16
- ;;
-cris-*-*aout*) targ_emul=crisaout
- targ_extra_emuls="criself crislinux"
- targ_extra_libpath=$targ_extra_emuls
- ;;
-cris-*-linux-* | crisv32-*-linux-*)
- targ_emul=crislinux
- ;;
-cris-*-* | crisv32-*-*) targ_emul=criself
- targ_extra_emuls="crisaout crislinux"
- targ_extra_libpath=$targ_extra_emuls
- ;;
-crx-*-elf*) targ_emul=elf32crx
- ;;
-
-csky-*-elf*) targ_emul=cskyelf
- ;;
-csky-*-linux*) targ_emul=cskyelf_linux
- ;;
-
-d10v-*-*) targ_emul=d10velf
- ;;
-d30v-*-*ext*) targ_emul=d30v_e
- targ_extra_emuls="d30velf d30v_o"
- targ_extra_ofiles=ldelfgen.o
- ;;
-d30v-*-*onchip*) targ_emul=d30v_o
- targ_extra_emuls="d30velf d30v_e"
- targ_extra_ofiles=ldelfgen.o
- ;;
-d30v-*-*) targ_emul=d30velf
- targ_extra_emuls="d30v_e d30v_o"
- targ_extra_ofiles=ldelfgen.o
- ;;
-dlx-*-elf*) targ_emul=elf32_dlx
- targ_extra_ofiles=ldelfgen.o
- ;;
-epiphany-*-*) targ_emul=elf32epiphany
- targ_extra_emuls="elf32epiphany_4x4"
- ;;
-fido*-*-elf*) targ_emul=m68kelf
- ;;
-fr30-*-*) targ_emul=elf32fr30
- targ_extra_ofiles=ldelfgen.o
- ;;
-frv-*-*linux*) targ_emul=elf32frvfd
- ;;
-frv-*-*) targ_emul=elf32frv
- targ_extra_emuls="elf32frvfd"
- ;;
-ft32-*-*) targ_emul=elf32ft32
- targ_extra_ofiles=ldelfgen.o
- ;;
-h8300-*-elf* | h8300-*-rtems*)
- targ_emul=h8300elf;
- targ_extra_emuls="h8300helf h8300self h8300hnelf h8300snelf h8300sxelf h8300sxnelf"
- ;;
-h8300-*-linux*)
- targ_emul=h8300elf_linux;
- targ_extra_emuls="h8300helf_linux h8300self_linux h8300sxelf_linux"
- ;;
-hppa*64*-*-linux-*) targ_emul=hppa64linux
- ;;
-hppa*64*-hpux*) targ_emul=elf64hppa
- ;;
-hppa*-*-linux-*) targ_emul=hppalinux
- ;;
-hppa*-*-*elf*) targ_emul=hppaelf
- ;;
-hppa*-*-lites*) targ_emul=hppaelf
- ;;
-hppa*-*-netbsd*) targ_emul=hppanbsd
- ;;
-hppa*-*-openbsd*) targ_emul=hppaobsd
- ;;
-i[3-7]86-*-nto-qnx*) targ_emul=i386nto
- ;;
-i[3-7]86-*-go32) targ_emul=i386go32
- targ_extra_ofiles=
- ;;
-i[3-7]86-*-msdosdjgpp*) targ_emul=i386go32
- targ_extra_ofiles=
- ;;
-i[3-7]86-*-lynxos*) targ_emul=i386lynx
- ;;
-i[3-7]86-*-aros*) targ_emul=elf_i386
- targ_extra_emuls=elf_iamcu
- ;;
-i[3-7]86-*-rdos*) targ_emul=elf_i386
- targ_extra_emuls=elf_iamcu
- ;;
-i[3-7]86-*-bsd) targ_emul=i386bsd
- targ_extra_ofiles=
- ;;
-i[3-7]86-*-bsd386) targ_emul=i386bsd
- targ_extra_ofiles=
- ;;
-i[3-7]86-*-bsdi*) targ_emul=i386bsd
- targ_extra_ofiles=
- ;;
-i[3-7]86-*-linux-*) targ_emul=elf_i386
- targ_extra_emuls="elf_iamcu"
- targ64_extra_emuls="elf_x86_64 elf32_x86_64"
- targ64_extra_libpath="elf_x86_64 elf32_x86_64"
- ;;
-i[3-7]86-*-redox*) targ_emul=elf_i386
- targ_extra_emuls=elf_x86_64
- ;;
-i[3-7]86-*-solaris2*) targ_emul=elf_i386_sol2
- targ_extra_emuls="elf_i386_ldso elf_i386 elf_iamcu elf_x86_64_sol2 elf_x86_64"
- targ_extra_libpath=$targ_extra_emuls
- ;;
-i[3-7]86-*-solaris*) targ_emul=elf_i386_ldso
- targ_extra_emuls="elf_i386"
- targ_extra_libpath=$targ_extra_emuls
- ;;
-i[3-7]86-*-netbsd* | \
-i[3-7]86-*-netbsd*-gnu* | \
-i[3-7]86-*-knetbsd*-gnu | \
-i[3-7]86-*-openbsd*)
- targ_emul=elf_i386
- targ_extra_emuls="elf_iamcu"
- ;;
-i[3-7]86-*-elfiamcu) targ_emul=elf_iamcu
- targ_extra_emuls=elf_i386
- ;;
-i[3-7]86-*-elf* | i[3-7]86-*-rtems* | i[3-7]86-*-genode*)
- targ_emul=elf_i386
- targ_extra_emuls=elf_iamcu
- ;;
-i[3-7]86-*-dragonfly*) targ_emul=elf_i386
- targ_extra_emuls="elf_iamcu i386bsd"
- ;;
-i[3-7]86-*-freebsd* | i[3-7]86-*-kfreebsd*-gnu)
- targ_emul=elf_i386_fbsd
- targ_extra_emuls="elf_i386 elf_iamcu i386bsd"
- ;;
-i[3-7]86-*-gnu*) targ_emul=elf_i386
- targ_extra_emuls=elf_iamcu
- ;;
-i[3-7]86-*-msdos*) targ_emul=i386msdos
- targ_extra_emuls=i386aout
- targ_extra_ofiles=
- ;;
-i[3-7]86-*-moss*) targ_emul=i386moss
- targ_extra_emuls=i386msdos
- ;;
-i[3-7]86-*-winnt*) targ_emul=i386pe ;
- targ_extra_ofiles="deffilep.o pdb.o pe-dll.o"
- ;;
-i[3-7]86-*-pe) targ_emul=i386pe ;
- targ_extra_ofiles="deffilep.o pdb.o pe-dll.o"
- ;;
-i[3-7]86-*-cygwin*) targ_emul=i386pe ;
- targ_extra_ofiles="deffilep.o pdb.o pe-dll.o" ;
- test "$targ" != "$host" && LIB_PATH='${tooldir}/lib/w32api'
- ;;
-i[3-7]86-*-mingw32*) targ_emul=i386pe ;
- targ_extra_ofiles="deffilep.o pdb.o pe-dll.o"
- ;;
-i[3-7]86-*-interix*) targ_emul=i386pe_posix;
- targ_extra_ofiles="deffilep.o pe-dll.o"
- ;;
-i[3-7]86-*-beospe*) targ_emul=i386beos
- targ_extra_ofiles=
- ;;
-i[3-7]86-*-beos*) targ_emul=elf_i386_be
- ;;
-i[3-7]86-*-haiku*) targ_emul=elf_i386_haiku
- ;;
-i[3-7]86-*-vxworks*) targ_emul=elf_i386_vxworks
- ;;
-i[3-7]86-*-chaos) targ_emul=elf_i386_chaos
- ;;
-ia16-*-elf*) targ_emul=elf_i386
- targ_extra_emuls=i386msdos
- ;;
-ia64-*-elf*) targ_emul=elf64_ia64
- ;;
-ia64-*-freebsd* | ia64-*-kfreebsd*-gnu)
- targ_emul=elf64_ia64_fbsd
- targ_extra_emuls="elf64_ia64"
- ;;
-ia64-*-netbsd*) targ_emul=elf64_ia64
- ;;
-ia64-*-linux*) targ_emul=elf64_ia64
- ;;
-ia64-*-*vms*) targ_emul=elf64_ia64_vms
- targ_extra_ofiles=ldelfgen.o
- ;;
-ia64-*-aix*) targ_emul=elf64_aix
- ;;
-ip2k-*-elf) targ_emul=elf32ip2k
- ;;
-iq2000-*-elf) targ_emul=elf32iq2000
- targ_extra_emuls="elf32iq10"
- targ_extra_ofiles=ldelfgen.o
- ;;
-lm32-*-*linux*) targ_emul=elf32lm32fd
- ;;
-lm32-*-*) targ_emul=elf32lm32
- targ_extra_emuls="elf32lm32fd"
- ;;
-kvx-*-linux*) targ_emul=elf64kvx_linux
- targ_extra_emuls="elf64kvx"
- ;;
-kvx-*-*) targ_emul=elf64kvx;
- targ_extra_emuls="elf64kvx_linux elf32kvx"
- ;;
-m32c-*-elf)
- targ_emul=elf32m32c
- ;;
-m32r*le-*-elf*) targ_emul=m32rlelf
- ;;
-m32r*-*-elf*)
- targ_emul=m32relf
- ;;
-m32r*le-*-linux-*) targ_emul=m32rlelf_linux
- ;;
-m32r*-*-linux-*) targ_emul=m32relf_linux
- ;;
-m68hc11-*-*|m6811-*-*) targ_emul=m68hc11elf
- targ_extra_emuls="m68hc11elfb m68hc12elf m68hc12elfb"
- ;;
-m68hc12-*-*|m6812-*-*) targ_emul=m68hc12elf
- targ_extra_emuls="m68hc12elfb m68hc11elf m68hc11elfb"
- ;;
-m68*-*-netbsd*) targ_emul=m68kelfnbsd
- ;;
-m68*-*-haiku*) targ_emul=m68kelf
- ;;
-m68*-*-*) targ_emul=m68kelf
- ;;
-mcore-*-pe) targ_emul=mcorepe ;
- targ_extra_ofiles="deffilep.o pe-dll.o"
- ;;
-mcore-*-elf) targ_emul=elf32mcore
- ;;
-mep-*-elf) targ_emul=elf32mep
- ;;
-metag-*-*) targ_emul=elf32metag
- ;;
-microblazeel*-linux*) targ_emul="elf32mbel_linux"
- targ_extra_emuls="elf32mb_linux"
- ;;
-microblaze*-linux*) targ_emul="elf32mb_linux"
- targ_extra_emuls="elf32mbel_linux"
- ;;
-microblazeel*) targ_emul=elf32microblazeel
- targ_extra_emuls=elf32microblaze
- ;;
-microblaze*) targ_emul=elf32microblaze
- targ_extra_emuls=elf32microblazeel
- ;;
-mips*-sgi-irix5*) targ_emul=elf32bsmip
- ;;
-mips*-sgi-irix6*) targ_emul=elf32bmipn32
- targ_extra_emuls="elf32bsmip elf64bmip"
- targ_extra_libpath=$targ_extra_emuls
- ;;
-mips*el-*-haiku*) targ_emul=elf_mipsel_haiku
- targ_extra_emuls="elf32ltsmip elf32btsmip elf32ltsmipn32 elf64ltsmip elf32btsmipn32 elf64btsmip"
- ;;
-mips*el-*-netbsd*) targ_emul=elf32ltsmip
- targ_extra_emuls="elf32btsmip elf64ltsmip elf64btsmip"
- ;;
-mips*-*-netbsd*) targ_emul=elf32btsmip
- targ_extra_emuls="elf32ltsmip elf64btsmip elf64ltsmip"
- ;;
-mips64el-*-openbsd*) targ_emul=elf64ltsmip
- targ_extra_emuls=elf64btsmip
- ;;
-mips64-*-openbsd*) targ_emul=elf64btsmip
- targ_extra_emuls=elf64ltsmip
- ;;
-mips*vr4300el-*-elf*) targ_emul=elf32l4300
- ;;
-mips*vr4300-*-elf*) targ_emul=elf32b4300
- ;;
-mips*vr4100el-*-elf*) targ_emul=elf32l4300
- ;;
-mips*vr4100-*-elf*) targ_emul=elf32b4300
- ;;
-mips*vr5000el-*-elf*) targ_emul=elf32l4300
- ;;
-mips*vr5000-*-elf*) targ_emul=elf32b4300
- ;;
-mips*el-sde-elf* | mips*el-mti-elf* | mips*el-img-elf*)
- targ_emul=elf32ltsmip
- targ_extra_emuls="elf32btsmip elf32ltsmipn32 elf64ltsmip elf32btsmipn32 elf64btsmip"
- ;;
-mips*-sde-elf* | mips*-mti-elf* | mips*-img-elf*)
- targ_emul=elf32btsmip
- targ_extra_emuls="elf32ltsmip elf32btsmipn32 elf64btsmip elf32ltsmipn32 elf64ltsmip"
- ;;
-mips64*el-ps2-elf*) targ_emul=elf32lr5900n32
- targ_extra_emuls="elf32lr5900"
- targ_extra_libpath=$targ_extra_emuls
- ;;
-mips*el-ps2-elf*) targ_emul=elf32lr5900
- targ_extra_emuls="elf32lr5900n32"
- targ_extra_libpath=$targ_extra_emuls
- ;;
-mips*el-*-elf*) targ_emul=elf32elmip
- ;;
-mips*-*-elf* | mips*-*-rtems*)
- targ_emul=elf32ebmip
- ;;
-mips*el-*-vxworks*) targ_emul=elf32elmipvxworks
- targ_extra_emuls="elf32ebmipvxworks"
- ;;
-mips*-*-vxworks*) targ_emul=elf32ebmipvxworks
- targ_extra_emuls="elf32elmipvxworks"
- ;;
-mips*-*-windiss) targ_emul=elf32mipswindiss
- ;;
-mips64*el-*-linux-gnuabi64)
- targ_emul=elf64ltsmip
- targ_extra_emuls="elf64btsmip elf32ltsmipn32 elf32btsmipn32 elf32ltsmip elf32btsmip"
- targ_extra_libpath=$targ_extra_emuls
- ;;
-mips64*el-*-linux-*) targ_emul=elf32ltsmipn32
- targ_extra_emuls="elf32btsmipn32 elf32ltsmip elf32btsmip elf64ltsmip elf64btsmip"
- targ_extra_libpath=$targ_extra_emuls
- ;;
-mips64*-*-linux-gnuabi64)
- targ_emul=elf64btsmip
- targ_extra_emuls="elf64ltsmip elf32btsmipn32 elf32ltsmipn32 elf32btsmip elf32ltsmip"
- targ_extra_libpath=$targ_extra_emuls
- ;;
-mips64*-*-linux-*) targ_emul=elf32btsmipn32
- targ_extra_emuls="elf32ltsmipn32 elf32btsmip elf32ltsmip elf64btsmip elf64ltsmip"
- targ_extra_libpath=$targ_extra_emuls
- ;;
-mips*el-*-linux-*) targ_emul=elf32ltsmip
- targ_extra_emuls="elf32btsmip elf32ltsmipn32 elf64ltsmip elf32btsmipn32 elf64btsmip"
- targ_extra_libpath=$targ_extra_emuls
- ;;
-mips*-*-linux-*) targ_emul=elf32btsmip
- targ_extra_emuls="elf32ltsmip elf32btsmipn32 elf64btsmip elf32ltsmipn32 elf64ltsmip"
- targ_extra_libpath=$targ_extra_emuls
- ;;
-mips64*el-*-freebsd* | mips64*el-*-kfreebsd*-gnu)
- targ_emul=elf32ltsmipn32_fbsd
- targ_extra_emuls="elf32ltsmip elf32btsmip elf32ltsmipn32 elf32btsmipn32 elf64ltsmip elf64btsmip elf32ltsmip_fbsd elf32btsmip_fbsd elf32btsmipn32_fbsd elf64ltsmip_fbsd elf64btsmip_fbsd"
- targ_extra_libpath=$targ_extra_emuls
- ;;
-mips64*-*-freebsd* | mips64*-*-kfreebsd*-gnu)
- targ_emul=elf32btsmipn32_fbsd
- targ_extra_emuls="elf32ltsmip elf32btsmip elf32ltsmipn32 elf32btsmipn32 elf64ltsmip elf64btsmip elf32ltsmip_fbsd elf32btsmip_fbsd elf32ltsmipn32_fbsd elf64ltsmip_fbsd elf64btsmip_fbsd"
- targ_extra_libpath=$targ_extra_emuls
- ;;
-mips*el-*-freebsd* | mips*el-*-kfreebsd*-gnu)
- targ_emul=elf32ltsmip_fbsd
- targ_extra_emuls="elf32ltsmip elf32btsmip elf32ltsmipn32 elf32btsmipn32 elf64ltsmip elf64btsmip elf32ltsmipn32_fbsd elf32btsmip_fbsd elf32btsmipn32_fbsd elf64ltsmip_fbsd elf64btsmip_fbsd"
- targ_extra_libpath=$targ_extra_emuls
- ;;
-mips*-*-freebsd* | mips*-*-kfreebsd*-gnu)
- targ_emul=elf32btsmip_fbsd
- targ_extra_emuls="elf32ltsmip elf32btsmip elf32ltsmipn32 elf32btsmipn32 elf64ltsmip elf64btsmip elf32ltsmip_fbsd elf32btsmipn32_fbsd elf32ltsmipn32_fbsd elf64ltsmip_fbsd elf64btsmip_fbsd"
- targ_extra_libpath=$targ_extra_emuls
- ;;
-mips*-*-sysv4*) targ_emul=elf32btsmip
- ;;
-mmix-*-*) targ_emul=mmo
- targ_extra_emuls=elf64mmix
- ;;
-mn10200-*-*) targ_emul=mn10200
- targ_extra_ofiles=ldelfgen.o
- ;;
-mn10300-*-*) targ_emul=mn10300
- ;;
-moxie-*-moxiebox*) targ_emul=moxiebox
- targ_extra_ofiles=ldelfgen.o
- ;;
-moxie-*-*) targ_emul=elf32moxie
- ;;
-msp430-*-*) targ_emul=msp430elf
- targ_extra_emuls="msp430X"
- targ_extra_ofiles=ldelfgen.o
- ;;
-mt-*elf) targ_emul=elf32mt
- targ_extra_ofiles=ldelfgen.o
- ;;
-nds32*le-*-elf*) targ_emul=nds32elf
- targ_extra_emuls="nds32elf16m nds32belf nds32belf16m"
- ;;
-nds32*be-*-elf*) targ_emul=nds32belf
- targ_extra_emuls="nds32elf nds32elf16m nds32belf16m"
- ;;
-nds32*le-*-linux-gnu*) targ_emul=nds32elf_linux
- ;;
-nds32*be-*-linux-gnu*) targ_emul=nds32belf_linux
- ;;
-nios2*-*-linux*) targ_emul=nios2linux
- ;;
-nios2*-*-*) targ_emul=nios2elf
- ;;
-ns32k-pc532-mach* | ns32k-pc532-ux*) targ_emul=pc532macha
- targ_extra_ofiles=
- ;;
-ns32k-*-*bsd* | ns32k-pc532-lites*) targ_emul=ns32knbsd
- targ_extra_ofiles=
- ;;
-or1k-*-elf | or1knd-*-elf | or1k-*-rtems* | or1knd-*-rtems*)
- targ_emul=elf32or1k
- ;;
-or1k-*-linux* | or1knd-*-linux*) targ_emul=elf32or1k_linux
- ;;
-pdp11-*-*) targ_emul=pdp11
- targ_extra_ofiles=
- ;;
-pjl*-*-*) targ_emul=pjlelf
- targ_extra_emuls="elf_i386 elf_iamcu"
- ;;
-pj*-*-*) targ_emul=pjelf
- targ_extra_ofiles=ldelfgen.o
- ;;
-powerpc-*-freebsd* | powerpc-*-kfreebsd*-gnu)
- targ_emul=elf32ppc_fbsd
- targ_extra_emuls="elf32ppc elf32ppcsim"
- targ_extra_libpath=elf32ppc;
- tdir_elf32ppcsim=`echo ${targ_alias} | sed -e 's/ppc/ppcsim/'`
- ;;
-powerpc64-*-freebsd*)
- targ_emul=elf64ppc_fbsd
- targ_extra_emuls="elf64ppc elf32ppc_fbsd elf32ppc"
- targ_extra_libpath="elf32ppc_fbsd elf32ppc"
- tdir_elf32ppc=`echo "${targ_alias}" | sed -e 's/64//'`
- tdir_elf32ppc_fbsd=$tdir_elf32ppc
- ;;
-powerpc64le-*-freebsd*)
- targ_emul=elf64lppc_fbsd
- targ_extra_emuls="elf64lppc"
- ;;
-powerpc-*-vxworks*)
- targ_emul=elf32ppcvxworks
- targ_extra_emuls="elf32ppc elf32ppclinux elf32ppcsim"
- ;;
-powerpc*-*-elf* | powerpc*-*-eabi* | powerpc*-*-sysv* \
- | powerpc*-*-linux* | powerpc*-*-netbsd* | powerpc*-*-openbsd* \
- | powerpc*-*-rtems* \
- | powerpc*-*-solaris* | powerpc*-*-kaos* | powerpc*-*-vxworks*)
- case "${targ}" in
- powerpc64*)
- targ_emul=elf64ppc
- targ_extra_emuls="elf32ppc elf32ppclinux elf32ppcsim"
- targ_extra_libpath="elf32ppc elf32ppclinux" ;;
- *linux*)
- targ_emul=elf32ppclinux
- targ_extra_emuls="elf32ppc elf32ppcsim"
- targ_extra_libpath=elf32ppc
- targ64_extra_emuls=elf64ppc
- targ64_extra_libpath=elf64ppc ;;
- *)
- targ_emul=elf32ppc
- targ_extra_emuls="elf32ppclinux elf32ppcsim"
- targ_extra_libpath=elf32ppclinux
- targ64_extra_emuls=elf64ppc
- targ64_extra_libpath=elf64ppc ;;
- esac
- td=tdir_elf32ppc
- td64=tdir_elf64ppc
- s=s/ppc/lppc/g
- case "${targ}" in
- powerpcle-* | powerpc64le-*)
- for z in td td64 targ_emul targ_extra_emuls \
- targ_extra_libpath targ64_extra_emuls \
- targ64_extra_libpath
- do
- eval ${z}=\"\`echo \$${z} \| sed -e $s\`\"
- done
- s=s/lppc/ppc/g ;;
- esac
- # Why oh why did we set tooldir based on target_alias
- # rather than on target?
- eval tdir_${targ_emul}="${targ_alias}"
- cpu=`echo "${targ_alias}" | sed -e 's/-.*//'`
- rest=`echo "${targ_alias}" | sed -e 's/^[^-]*//'`
- le=le
- case "${cpu}" in
- *little) le=little
- esac
- ta32=`echo "${cpu}" | sed -e s/64//`"${rest}"
- ta64=`echo "${cpu}" | sed -e 's/64//;s/$/64/;s/'${le}'64$/64'${le}'/;s/be64$/64be/'`"${rest}"
- eval test -n \"\$${td}\" || eval ${td}="${ta32}"
- eval test -n \"\$${td}linux\" || eval ${td}linux="${ta32}"
- eval test -n \"\$${td}sim\" || eval ${td}sim="${ta32}"
- eval test -n \"\$${td64}\" || eval ${td64}="${ta64}"
- # Now provide the other endian
- for z in targ_extra_emuls targ_extra_libpath
- do
- eval ${z}=\"\$${z} \`echo ${targ_emul} \$${z} \| sed -e $s\`\"
- done
- for z in targ64_extra_emuls targ64_extra_libpath
- do
- eval ${z}=\"\$${z} \`echo \$${z} \| sed -e $s\`\"
- done
- td=`echo "${td}" | sed -e $s`
- td64=`echo "${td64}" | sed -e $s`
- case "${targ}" in
- powerpcle-* | powerpc64le-*)
- cpu=`echo "${cpu}" | sed -e s/${le}\$//` ;;
- *)
- cpu=`echo "${cpu}" | sed -e s/be\$//`${le} ;;
- esac
- ta32=`echo "${cpu}" | sed -e s/64//`"${rest}"
- ta64=`echo "${cpu}" | sed -e 's/64//;s/$/64/;s/'${le}'64$/64'${le}/`"${rest}"
- eval test -n \"\$${td}\" || eval ${td}="${ta32}"
- eval test -n \"\$${td}linux\" || eval ${td}linux="${ta32}"
- eval test -n \"\$${td}sim\" || eval ${td}sim="${ta32}"
- eval test -n \"\$${td64}\" || eval ${td64}="${ta64}"
- ;;
-powerpc-*-nto*) targ_emul=elf32ppcnto
- ;;
-powerpcle-*-nto*) targ_emul=elf32lppcnto
- ;;
-powerpc-*-macos*) targ_emul=ppcmacos
- targ_extra_ofiles=
- ;;
-powerpc-*-aix[5-9]*) targ_emul=aix5ppc
- targ_extra_ofiles=
- ;;
-powerpc-*-aix*) targ_emul=aixppc
- targ_extra_ofiles=
- ;;
-powerpc-*-beos*) targ_emul=aixppc
- targ_extra_ofiles=
- ;;
-powerpc-*-haiku*) targ_emul=elf32ppchaiku
- ;;
-powerpc-*-windiss*) targ_emul=elf32ppcwindiss
- ;;
-pru*-*-*) targ_emul=pruelf
- ;;
-riscv32be*-*-linux*) targ_emul=elf32briscv
- targ_extra_emuls="elf32briscv_ilp32f elf32briscv_ilp32 elf64briscv elf64briscv_lp64f elf64briscv_lp64 elf32lriscv elf32lriscv_ilp32f elf32lriscv_ilp32 elf64lriscv elf64lriscv_lp64f elf64lriscv_lp64"
- targ_extra_libpath=$targ_extra_emuls
- ;;
-riscv32*-*-linux*) targ_emul=elf32lriscv
- targ_extra_emuls="elf32lriscv_ilp32f elf32lriscv_ilp32 elf64lriscv elf64lriscv_lp64f elf64lriscv_lp64 elf32briscv elf32briscv_ilp32f elf32briscv_ilp32 elf64briscv elf64briscv_lp64f elf64briscv_lp64"
- targ_extra_libpath=$targ_extra_emuls
- ;;
-riscvbe-*-* | riscv32be*-*-*)
- targ_emul=elf32briscv
- targ_extra_emuls="elf64briscv elf32lriscv elf64lriscv"
- targ_extra_libpath=$targ_extra_emuls
- ;;
-riscv-*-* | riscv32*-*-*)
- targ_emul=elf32lriscv
- targ_extra_emuls="elf64lriscv elf32briscv elf64briscv"
- targ_extra_libpath=$targ_extra_emuls
- ;;
-riscv64be*-*-linux*) targ_emul=elf64briscv
- targ_extra_emuls="elf64briscv_lp64f elf64briscv_lp64 elf32briscv elf32briscv_ilp32f elf32briscv_ilp32 elf64lriscv elf64lriscv_lp64f elf64lriscv_lp64 elf32lriscv elf32lriscv_ilp32f elf32lriscv_ilp32"
- targ_extra_libpath=$targ_extra_emuls
- ;;
-riscv64*-*-linux*) targ_emul=elf64lriscv
- targ_extra_emuls="elf64lriscv_lp64f elf64lriscv_lp64 elf32lriscv elf32lriscv_ilp32f elf32lriscv_ilp32 elf64briscv elf64briscv_lp64f elf64briscv_lp64 elf32briscv elf32briscv_ilp32f elf32briscv_ilp32"
- targ_extra_libpath=$targ_extra_emuls
- ;;
-riscv64be*-*-*) targ_emul=elf64briscv
- targ_extra_emuls="elf32briscv elf64lriscv elf32lriscv"
- targ_extra_libpath=$targ_extra_emuls
- ;;
-riscv64*-*-*) targ_emul=elf64lriscv
- targ_extra_emuls="elf32lriscv elf64briscv elf32briscv"
- targ_extra_libpath=$targ_extra_emuls
- ;;
-rs6000-*-aix[5-9]*) targ_emul=aix5rs6
- targ_extra_ofiles=
- ;;
-rs6000-*-aix*) targ_emul=aixrs6
- targ_extra_ofiles=
- ;;
-rl78-*-*) targ_emul=elf32rl78
- ;;
-rx-*-linux*) targ_emul=elf32rx_linux
- ;;
-rx-*-*) targ_emul=elf32rx
- ;;
-s12z-*-*) targ_emul=m9s12zelf
- targ_extra_ofiles=ldelfgen.o
- ;;
-s390x-*-linux*) targ_emul=elf64_s390
- targ_extra_emuls=elf_s390
- targ_extra_libpath=$targ_extra_emuls
- tdir_elf_s390=`echo ${targ_alias} | sed -e 's/s390x/s390/'`
- ;;
-s390x-*-tpf*) targ_emul=elf64_s390
- tdir_elf_s390=`echo ${targ_alias} | sed -e 's/s390x/s390/'`
- ;;
-s390-*-linux*) targ_emul=elf_s390
- targ64_extra_emuls=elf64_s390
- targ64_extra_libpath=elf64_s390
- tdir_elf64_s390=`echo ${targ_alias} | sed -e 's/s390/s390x/'`
- ;;
-score-*-elf) targ_emul=score7_elf
- targ_extra_emuls=score3_elf
- ;;
-sh-*-linux*) targ_emul=shlelf_linux
- targ_extra_emuls="shelf_linux shlelf_fd shelf_fd"
- targ_extra_libpath=shelf_linux
- ;;
-sh*eb-*-linux*) targ_emul=shelf_linux
- targ_extra_emuls="shelf_fd"
- ;;
-sh*-*-linux*) targ_emul=shlelf_linux
- targ_extra_emuls="shlelf_fd"
- ;;
-sh*l*-*-netbsd*) targ_emul=shlelf_nbsd
- targ_extra_emuls=shelf_nbsd
- ;;
-sh*-*-netbsd*) targ_emul=shelf_nbsd
- targ_extra_emuls=shlelf_nbsd
- ;;
-shle*-*-elf* | sh[1234]*le*-*-elf | shle*-*-kaos*)
- targ_emul=shlelf
- targ_extra_emuls="shelf shl sh"
- ;;
-sh-*-elf* | sh[1234]*-*-elf | sh-*-rtems* | sh-*-kaos*)
- targ_emul=shelf
- targ_extra_emuls="shlelf sh shl"
- ;;
-sh-*-uclinux* | sh[12]-*-uclinux*)
- targ_emul=shelf_uclinux
- targ_extra_emuls="shelf shlelf sh shl shelf_fd shlelf_fd"
- ;;
-sh-*-vxworks) targ_emul=shelf_vxworks
- targ_extra_emuls=shlelf_vxworks
- ;;
-sh-*-nto*) targ_emul=shelf_nto
- targ_extra_emuls=shlelf_nto
- ;;
-sh-*-pe) targ_emul=shpe ;
- targ_extra_ofiles="deffilep.o pe-dll.o"
- ;;
-sh-*-*) targ_emul=sh;
- targ_extra_emuls=shl
- targ_extra_ofiles=
- ;;
-sparc64-*-freebsd* | sparcv9-*-freebsd* | sparc64-*-kfreebsd*-gnu | sparcv9-*-kfreebsd*-gnu)
- targ_emul=elf64_sparc_fbsd
- targ_extra_emuls="elf64_sparc elf32_sparc"
- targ_extra_libpath=$targ_extra_emuls
- tdir_elf32_sparc=`echo ${targ_alias} | sed -e 's/64//'`
- ;;
-sparc64-*-linux-*) targ_emul=elf64_sparc
- targ_extra_emuls="elf32_sparc"
- targ_extra_libpath=elf32_sparc
- tdir_elf32_sparc=`echo ${targ_alias} | sed -e 's/64//'`
- ;;
-sparc64-*-*bsd*) targ_emul=elf64_sparc
- targ_extra_emuls="elf32_sparc"
- ;;
-sparc64-*-solaris2* | sparcv9-*-solaris2*)
- targ_emul=elf64_sparc_sol2
- targ_extra_emuls="elf64_sparc elf32_sparc_sol2 elf32_sparc"
- targ_extra_libpath=$targ_extra_emuls
- tdir_elf32_sparc=`echo ${targ_alias} | sed -e 's/64//'`
- ;;
-sparc64-*-haiku*) targ_emul=elf64_sparc
- ;;
-sparc64-*-*) targ_emul=elf64_sparc
- ;;
-sparc*-*-linux-*) targ_emul=elf32_sparc
- targ_extra_emuls="elf64_sparc"
- targ_extra_libpath=elf64_sparc
- tdir_elf64_sparc=`echo ${targ_alias} | sed -e 's/32//'`
- ;;
-sparc-*-solaris2.[0-6] | sparc-*-solaris2.[0-6].*)
- targ_emul=elf32_sparc_sol2
- targ_extra_emuls=elf32_sparc
- ;;
-sparc-*-solaris2*) targ_emul=elf32_sparc_sol2
- targ_extra_emuls="elf32_sparc elf64_sparc_sol2 elf64_sparc"
- targ_extra_libpath=$targ_extra_emuls
- tdir_elf64_sparc=`echo ${targ_alias} | sed -e 's/32//'`
- ;;
-sparc*-*-vxworks*) targ_emul=elf32_sparc_vxworks
- ;;
-sparc*-*-*) targ_emul=elf32_sparc
- ;;
-spu-*-elf*) targ_emul=elf32_spu
- ;;
-tic30-*-*coff*) targ_emul=tic30coff
- targ_extra_ofiles=
- ;;
-tic4x-*-* | c4x-*-*) targ_emul=tic4xcoff
- targ_extra_emuls="tic3xcoff tic3xcoff_onchip"
- targ_extra_ofiles=
- ;;
-tic54x-*-* | c54x*-*-*) targ_emul=tic54xcoff
- targ_extra_ofiles=
- ;;
-tic6x-*-elf) targ_emul=elf32_tic6x_elf_le
- targ_extra_emuls="elf32_tic6x_elf_be elf32_tic6x_le elf32_tic6x_be"
- targ_extra_libpath=$targ_extra_emuls
- ;;
-tic6x-*-uclinux) targ_emul=elf32_tic6x_linux_le
- targ_extra_emuls="elf32_tic6x_linux_be elf32_tic6x_le elf32_tic6x_be"
- targ_extra_libpath=$targ_extra_emuls
- ;;
-tilegx-*-*) targ_emul=elf64tilegx
- targ_extra_emuls="elf64tilegx_be elf32tilegx elf32tilegx_be"
- targ_extra_libpath=$targ_extra_emuls
- ;;
-tilegxbe-*-*) targ_emul=elf64tilegx_be
- targ_extra_emuls="elf64tilegx elf32tilegx elf32tilegx_be"
- targ_extra_libpath=$targ_extra_emuls
- ;;
-tilepro-*-*) targ_emul=elf32tilepro
- ;;
-v850*-*-*) targ_emul=v850_rh850
- targ_extra_emuls=v850
- ;;
-vax-*-netbsdaout*) targ_emul=vaxnbsd
- targ_extra_emuls=elf32vax
- ;;
-vax-*-netbsd*) targ_emul=elf32vax
- targ_extra_emuls=vaxnbsd
- ;;
-vax-*-linux-*) targ_emul=elf32vax
- ;;
-visium-*-elf) targ_emul=elf32visium
- ;;
-x86_64-*-rdos*) targ_emul=elf64rdos
- ;;
-x86_64-*-cloudabi*) targ_emul=elf_x86_64_cloudabi
- ;;
-x86_64-*-haiku*) targ_emul=elf_x86_64_haiku
- targ_extra_emuls="elf_x86_64 elf_i386_haiku"
- ;;
-x86_64-*-linux-gnux32) targ_emul=elf32_x86_64
- targ_extra_emuls="elf_x86_64 elf_i386 elf_iamcu"
- targ_extra_libpath="elf_i386 elf_iamcu elf_x86_64"
- tdir_elf_iamcu=`echo ${targ_alias} | sed -e 's/x86_64/i386/' -e 's/-linux-gnux32/-linux-gnu/'`
- tdir_elf_i386=`echo ${targ_alias} | sed -e 's/x86_64/i386/' -e 's/-linux-gnux32/-linux-gnu/'`
- ;;
-x86_64-*-linux-*) targ_emul=elf_x86_64
- targ_extra_emuls="elf32_x86_64 elf_i386 elf_iamcu"
- targ_extra_libpath="elf_i386 elf32_x86_64"
- tdir_elf_i386=`echo ${targ_alias} | sed -e 's/x86_64/i386/'`
- ;;
-x86_64-*-redox*) targ_emul=elf_x86_64
- targ_extra_emuls=elf_i386
- ;;
-x86_64-*-solaris2*) targ_emul=elf_x86_64_sol2
- targ_extra_emuls="elf_x86_64 elf_i386_sol2 elf_i386_ldso elf_i386 elf_iamcu"
- targ_extra_libpath=$targ_extra_emuls
- tdir_elf_i386=`echo ${targ_alias} | sed -e 's/x86_64/i386/'`
- ;;
-x86_64-*-netbsd* | x86_64-*-openbsd*)
- targ_emul=elf_x86_64
- targ_extra_emuls="elf_i386 elf_iamcu"
- tdir_elf_iamcu=`echo ${targ_alias} | \
- sed -e 's/x86_64/i386/' -e 's/aout//'`
- tdir_elf_i386=`echo ${targ_alias} | \
- sed -e 's/x86_64/i386/' -e 's/aout//'`
- ;;
-x86_64-*-elf* | x86_64-*-rtems* | x86_64-*-fuchsia* | x86_64-*-genode*)
- targ_emul=elf_x86_64
- targ_extra_emuls="elf_i386 elf_iamcu elf32_x86_64"
- targ_extra_libpath="elf_i386 elf_iamcu elf32_x86_64"
- tdir_elf_i386=`echo ${targ_alias} | sed -e 's/x86_64/i386/'`
- ;;
-x86_64-*-dragonfly*) targ_emul=elf_x86_64
- targ_extra_emuls="elf_i386 elf_iamcu"
- ;;
-x86_64-*-freebsd* | x86_64-*-kfreebsd*-gnu)
- targ_emul=elf_x86_64_fbsd
- targ_extra_emuls="elf_i386_fbsd elf_x86_64 elf_i386 elf_iamcu"
- targ_extra_libpath="elf_i386_fbsd"
- tdir_elf_i386_fbsd=`echo ${targ_alias} \
- | sed -e 's/x86_64/i386/'`
- tdir_elf_iamcu=`echo ${targ_alias} \
- | sed -e 's/x86_64/i386/'`
- tdir_elf_i386=`echo ${targ_alias} \
- | sed -e 's/x86_64/i386/'`
- ;;
-x86_64-*-pe | x86_64-*-pep) targ_emul=i386pep ;
- targ_extra_emuls=i386pe ;
- targ_extra_ofiles="deffilep.o pdb.o pep-dll-x86_64.o pe-dll.o"
- ;;
-x86_64-*-cygwin) targ_emul=i386pep ;
- targ_extra_emuls=i386pe
- targ_extra_ofiles="deffilep.o pdb.o pep-dll.o pe-dll.o"
- test "$targ" != "$host" && LIB_PATH='${tooldir}/lib/w32api'
- ;;
-x86_64-*-mingw*) targ_emul=i386pep ;
- targ_extra_emuls=i386pe
- targ_extra_ofiles="deffilep.o pdb.o pep-dll.o pe-dll.o"
- ;;
-x86_64-*-gnu*) targ_emul=elf_x86_64
- targ_extra_emuls="elf32_x86_64 elf_iamcu elf_i386"
- targ_extra_libpath="elf_i386 elf32_x86_64"
- tdir_elf_i386=`echo ${targ_alias} | sed -e 's/x86_64/i386/'`
- ;;
-xgate-*-*) targ_emul=xgateelf
- targ_extra_ofiles=ldelfgen.o
- ;;
-xstormy16-*-*) targ_emul=elf32xstormy16
- ;;
-xtensa*-*-*) targ_emul=elf32xtensa
- ;;
-z80-*-elf*) targ_emul=elf32z80
- targ_extra_ofiles="ldelf.o ldelfgen.o"
- ;;
-z80-*-coff) targ_emul=z80
- targ_extra_ofiles=
- ;;
-z8k-*-coff) targ_emul=z8002
- targ_extra_emuls=z8001
- targ_extra_ofiles=
- ;;
-loongarch32-*) targ_emul=elf32loongarch
- ;;
-loongarch64-*) targ_emul=elf64loongarch
- ;;
-*-*-ieee*) targ_emul=vanilla
- targ_extra_ofiles=
- ;;
-*)
- echo 2>&1 "*** ld does not support target '${targ}' NO REALLY"
- echo 2>&1 "*** see ld/configure.tgt for supported targets"
- exit 1
-
-esac
-
-NATIVE_LIB_DIRS='/usr/local/lib /lib /usr/lib'
-case "${target}" in
-
-*-*-dragonfly*)
- NATIVE_LIB_DIRS='/lib /usr/lib /usr/pkg/lib /usr/local/lib'
- ;;
-
-*-*-freebsd*)
- NATIVE_LIB_DIRS='/lib /usr/lib /usr/local/lib'
- ;;
-
-hppa*64*-*-hpux11*)
- NATIVE_LIB_DIRS=/usr/lib/pa20_64
- ;;
-
-i[3-7]86-*-sysv4*)
- NATIVE_LIB_DIRS='/usr/local/lib /usr/ccs/lib /lib /usr/lib'
- ;;
-
-i[3-7]86-*-solaris*)
- NATIVE_LIB_DIRS='/usr/local/lib /usr/ccs/lib /lib /usr/lib'
- ;;
-
-i[3-7]86-pc-interix*)
- NATIVE_LIB_DIRS='/usr/local/lib $$INTERIX_ROOT/usr/lib /lib /usr/lib'
- ;;
-
-ia64-*-aix*)
- NATIVE_LIB_DIRS='/usr/local/lib /usr/lib/ia64l64 /lib /usr/lib'
- ;;
-
-sparc*-*-solaris2*)
- NATIVE_LIB_DIRS='/usr/local/lib /usr/ccs/lib /lib /usr/lib'
- ;;
-
-spu-*-elf*)
- # This allows one to build a pair of PPU/SPU toolchains with common sysroot.
- NATIVE_LIB_DIRS='/lib'
- ;;
-
-i[03-9x]86-*-cygwin* | x86_64-*-cygwin*)
- NATIVE_LIB_DIRS='/usr/lib /usr/lib/w32api'
- ;;
-
-*-*-linux*)
- ;;
-
-*-*-netbsd*)
- ;;
-
-alpha*-*-*)
- NATIVE_LIB_DIRS='/usr/local/lib /usr/ccs/lib /lib /usr/lib'
- ;;
-
-esac
-
-case "${target}" in
-frv-*-* | hppa*-*-* | ia64-*-* | mips*-*-*)
- # Don't enable -z relro by default since many relro tests fail on these
- # targets:
- # FAIL: strip -z relro (relro1)
- # FAIL: strip -z relro -shared (relro1)
- # FAIL: objcopy -z relro (relro1)
- # FAIL: objcopy -z relro -shared (relro1)
- # FAIL: objcopy -z relro (tdata1)
- # FAIL: objcopy -shared -z relro (tdata1)
- # FAIL: objcopy -z relro (tdata2)
- # FAIL: objcopy -shared -z relro (tdata2)
- # FAIL: objcopy -z relro (tdata3)
- # FAIL: objcopy -shared -z relro (tdata3)
- # FAIL: objcopy -shared -z relro (tbss1)
- # FAIL: objcopy -shared -z relro (tbss2)
- # FAIL: objcopy -shared -z relro (tbss3)
- ;;
-*-*-linux*)
- if test ${ac_default_ld_z_relro} = unset; then
- ac_default_ld_z_relro=1
- fi
- ;;
-esac
-
-# Enable -z separate-code and --warn-textrel by default for Linux/x86.
-case "${target}" in
-i[3-7]86-*-linux-* | x86_64-*-linux-*)
- if test ${ac_default_ld_z_separate_code} = unset; then
- ac_default_ld_z_separate_code=1
- fi
- if test ${ac_default_ld_textrel_check} = unset; then
- ac_default_ld_textrel_check=yes
- fi
- ;;
-esac
Index: sources/GNU/binutils/create-2.43.1-gold-warn-unsupported-patch/binutils-2.43.1-new/bfd/config.bfd
===================================================================
--- sources/GNU/binutils/create-2.43.1-gold-warn-unsupported-patch/binutils-2.43.1-new/bfd/config.bfd (revision 75)
+++ sources/GNU/binutils/create-2.43.1-gold-warn-unsupported-patch/binutils-2.43.1-new/bfd/config.bfd (nonexistent)
@@ -1,1556 +0,0 @@
-# config.bfd
-#
-# Copyright (C) 2012-2024 Free Software Foundation, Inc.
-#
-# This file is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 3 of the License, or
-# (at your option) any later version.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this program; see the file COPYING3. If not see
-# <http://www.gnu.org/licenses/>.
-#
-# Convert a canonical host type into a BFD host type.
-# Set shell variable targ to canonical target name, and run
-# using ``. config.bfd''.
-# Sets the following shell variables:
-# targ_defvec Default vector for this target
-# targ_selvecs Vectors to build for this target
-# targ64_selvecs Vectors to build if --enable-64-bit-bfd is given
-# or if host is 64 bit.
-# targ_archs Architectures for this target
-# targ_cflags $(CFLAGS) for this target (FIXME: pretty bogus)
-# targ_underscore Whether underscores are used: yes or no
-
-# Part of this file is processed by targmatch.sed to generate the
-# targmatch.h file. The #ifdef and #endif lines that appear below are
-# copied directly into targmatch.h.
-
-# The binutils c++filt program wants to know whether underscores are
-# stripped or not. That is why we set targ_underscore. c++filt uses
-# this information to choose a default. This information is
-# duplicated in the symbol_leading_char field of the BFD target
-# vector, but c++filt does not deal with object files and is not
-# linked against libbfd.a. It is not terribly important that c++filt
-# get this right; it is just convenient.
-
-targ_defvec=
-targ_selvecs=
-targ64_selvecs=
-targ_cflags=
-targ_underscore=no
-
-# Catch obsolete configurations.
-case $targ in
- null)
- if test "x$enable_obsolete" != xyes; then
- echo "*** Configuration $targ is obsolete." >&2
- echo "*** Specify --enable-obsolete to build it anyway." >&2
- echo "*** Support will be REMOVED in the next major release of BINUTILS," >&2
- echo "*** unless a maintainer comes forward." >&2
- exit 1
- fi;;
-esac
-
-# Warn on changed defaulting
-case $targ in
- *-*-netbsdelf* | *-*-netbsdaout* | *-*-netbsdpe*)
- # Explicit, no defaulting
- ;;
- ns32k-*-netbsd*)
- # The obsolete warning below is enough, and ns32k does not have ELF support
- ;;
- *-*-netbsd* )
- targ_migrated=`echo "$targ" | sed 's/netbsd/netbsdaout/'`
- echo "*** WARNING: $targ is now defaults to meaning ELF not a.out." >&2
- echo "*** Use $targ_migrated instead to explicitly specify a.out." >&2
- ;;
-esac
-
-case $targ in
- mips*-*-irix5* | mips*-*-irix6*)
- # Not obsolete
- ;;
- *-adobe-* | \
- *-*-beos* | \
- *-go32-rtems* | \
- *-sony-* | \
- *-tandem-* | \
- *-*-ieee* | \
- *-*-netbsdpe* | \
- *-*-netware* | \
- *-*-rtemsaout* | \
- *-*-rtemscoff* | \
- a29k-* | \
- arm*-*-aout | \
- arm-*-coff | \
- arm*-*-netbsdaout* | \
- arm-*-oabi | \
- arm-*-riscix* | \
- arm*-*-symbianelf* | \
- arm-epoc-pe* | \
- c30-*-*aout* | tic30-*-*aout* | \
- cr16c-*-* | \
- h8300*-*-coff | \
- h8500*-*-coff | \
- hppa*-*-rtems* | \
- i[3-7]86-*-unixware* | \
- i[3-7]86-*-dgux* | \
- i[3-7]86-*-chorus* | \
- i[3-7]86-*-sysv* | \
- i[3-7]86-*-isc* | \
- i[3-7]86-*-sco* | \
- i[3-7]86-*-coff | \
- i[3-7]86-*-aix* | \
- i[3-7]86-sequent-bsd* | \
- i[3-7]86-*-freebsdaout* | i[3-7]86-*-freebsd[12].* | i[3-7]86-*-freebsd[12] | \
- i[3-7]86-*-netbsdaout* | \
- i[3-7]86-*-openbsd[0-2].* | i[3-7]86-*-openbsd3.[0-3] | \
- i[3-7]86-*-linux*aout* | \
- i[3-7]86-*-mach* | i[3-7]86-*-osf1mk* | \
- i[3-7]86-*-os9k | \
- i[3-7]86-none-* | \
- i[3-7]86-*-aout* | i[3-7]86*-*-vsta* | \
- i370-* | \
- i860-*-* | \
- i960-*-* | \
- m68*-*-bsd* | \
- m68*-*-aout* | \
- m68*-*-coff* | \
- m68*-*-hpux* | \
- m68*-*-linux*aout* | \
- m68*-*-lynxos* | \
- m68*-*-openbsd* | \
- m68*-*-os68k* | \
- m68*-*-psos* | \
- m68*-*-sunos* | \
- m68*-*-sysv* | \
- m68*-*-vsta* | \
- m68*-*-vxworks* | \
- m68*-apollo-* | \
- m68*-apple-aux* | \
- m68*-ericsson-* | \
- m68*-netx-* | \
- m88*-*-* | \
- maxq-*-coff | \
- mips*-*-bsd* | \
- mips*-*-ecoff* | \
- mips*-*-lnews* | \
- mips*-*-mach3* | \
- mips*-*-pe* | \
- mips*-*-riscos* | \
- mips*-*-sysv* | \
- mips*-big-* | \
- mips*-dec-* | \
- mips*-sgi-* | \
- mips*el-*-rtems* | \
- m32c-*-rtems* | \
- ns32k-*-netbsd* | \
- openrisc-*-* | \
- or32-*-* | \
- powerpc-*-lynxos* | powerpc-*-windiss* | \
- powerpcle-*-pe | powerpcle-*-winnt* | powerpcle-*-cygwin* | \
- sh*-*-netbsdaout* | \
- sh*-*-symbianelf* | sh5*-*-* | sh64*-*-* | \
- sparc*-*-*aout* | \
- sparc*-*-chorus* | \
- sparc*-*-coff* | \
- sparc-*-lynxos* | \
- sparc-*-openbsd[0-2].* | sparc-*-openbsd3.[0-1] | \
- tahoe-*-* | \
- vax-*-bsd* | vax-*-ultrix* | vax-*-vms* | \
- w65-*-* | \
- we32k-*-* | \
- xc16x-*-* | \
- null)
- echo "*** Configuration $targ is now obsolete" >&2
- echo "*** and so support for it has been REMOVED." >&2
- exit 1
- ;;
-esac
-
-targ_cpu=`echo $targ | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
-case "${targ_cpu}" in
-aarch64*) targ_archs="bfd_aarch64_arch bfd_arm_arch";;
-alpha*) targ_archs=bfd_alpha_arch ;;
-am33_2.0*) targ_archs=bfd_mn10300_arch ;;
-arc*) targ_archs=bfd_arc_arch ;;
-arm*) targ_archs=bfd_arm_arch ;;
-amdgcn*) targ_archs=bfd_amdgcn_arch ;;
-bfin*) targ_archs=bfd_bfin_arch ;;
-c30*) targ_archs=bfd_tic30_arch ;;
-c4x*) targ_archs=bfd_tic4x_arch ;;
-c54x*) targ_archs=bfd_tic54x_arch ;;
-cr16*) targ_archs=bfd_cr16_arch ;;
-crisv32) targ_archs=bfd_cris_arch ;;
-crx*) targ_archs=bfd_crx_arch ;;
-csky*) targ_archs=bfd_csky_arch ;;
-dlx*) targ_archs=bfd_dlx_arch ;;
-fido*) targ_archs=bfd_m68k_arch ;;
-hppa*) targ_archs=bfd_hppa_arch ;;
-i[3-7]86) targ_archs=bfd_i386_arch ;;
-ia16) targ_archs=bfd_i386_arch ;;
-kvx) targ_archs=bfd_kvx_arch ;;
-loongarch*) targ_archs=bfd_loongarch_arch ;;
-m6811*|m68hc11*) targ_archs="bfd_m68hc11_arch bfd_m68hc12_arch bfd_m9s12x_arch bfd_m9s12xg_arch" ;;
-m6812*|m68hc12*) targ_archs="bfd_m68hc12_arch bfd_m68hc11_arch bfd_m9s12x_arch bfd_m9s12xg_arch" ;;
-m68*) targ_archs=bfd_m68k_arch ;;
-microblaze*) targ_archs=bfd_microblaze_arch ;;
-mips*) targ_archs=bfd_mips_arch ;;
-nds32*) targ_archs=bfd_nds32_arch ;;
-nios2*) targ_archs=bfd_nios2_arch ;;
-or1k*|or1knd*) targ_archs=bfd_or1k_arch ;;
-pdp11*) targ_archs=bfd_pdp11_arch ;;
-pj*) targ_archs="bfd_pj_arch bfd_i386_arch";;
-powerpc*) targ_archs="bfd_rs6000_arch bfd_powerpc_arch" ;;
-pru*) targ_archs=bfd_pru_arch ;;
-riscv*) targ_archs=bfd_riscv_arch ;;
-rs6000) targ_archs="bfd_rs6000_arch bfd_powerpc_arch" ;;
-s12z*) targ_archs=bfd_s12z_arch ;;
-s390*) targ_archs=bfd_s390_arch ;;
-sh*) targ_archs=bfd_sh_arch ;;
-sparc*) targ_archs=bfd_sparc_arch ;;
-spu*) targ_archs=bfd_spu_arch ;;
-tilegx*) targ_archs=bfd_tilegx_arch ;;
-tilepro*) targ_archs=bfd_tilepro_arch ;;
-v850*) targ_archs="bfd_v850_arch bfd_v850_rh850_arch" ;;
-visium*) targ_archs=bfd_visium_arch ;;
-x86_64*) targ_archs=bfd_i386_arch ;;
-xtensa*) targ_archs=bfd_xtensa_arch ;;
-z80*|r800|z180|gbz80|ez80*) targ_archs=bfd_z80_arch ;;
-z8k*) targ_archs=bfd_z8k_arch ;;
-*) targ_archs=bfd_${targ_cpu}_arch ;;
-esac
-
-
-# WHEN ADDING ENTRIES TO THIS MATRIX:
-# Make sure that the left side always has two dashes. Otherwise you
-# can get spurious matches. Even for unambiguous cases, do this as a
-# convention, else the table becomes a real mess to understand and maintain.
-
-case "${targ}" in
-# START OF targmatch.h
-#ifdef BFD64
- aarch64-*-darwin*)
- targ_defvec=aarch64_mach_o_vec
- targ_selvecs="arm_mach_o_vec mach_o_le_vec mach_o_be_vec mach_o_fat_vec"
- targ_archs="$targ_archs bfd_i386_arch bfd_powerpc_arch bfd_rs6000_arch"
- want64=true
- ;;
- aarch64-*-elf | aarch64-*-rtems* | aarch64-*-genode*)
- targ_defvec=aarch64_elf64_le_vec
- targ_selvecs="aarch64_elf64_be_vec aarch64_elf32_le_vec aarch64_elf32_be_vec arm_elf32_le_vec arm_elf32_be_vec aarch64_pei_le_vec aarch64_pe_le_vec"
- want64=true
- ;;
- aarch64-*-pe* | aarch64-*-mingw*)
- targ_defvec=aarch64_pe_le_vec
- targ_selvecs="aarch64_pe_le_vec aarch64_pei_le_vec aarch64_elf64_le_vec aarch64_elf64_be_vec aarch64_elf32_le_vec aarch64_elf32_be_vec arm_elf32_le_vec arm_elf32_be_vec pdb_vec"
- want64=true
- targ_underscore=no
- ;;
- aarch64_be-*-elf)
- targ_defvec=aarch64_elf64_be_vec
- targ_selvecs="aarch64_elf64_le_vec aarch64_elf32_le_vec aarch64_elf32_be_vec arm_elf32_be_vec arm_elf32_le_vec"
- want64=true
- ;;
- aarch64-*-freebsd*)
- targ_defvec=aarch64_elf64_le_vec
- targ_selvecs="aarch64_elf64_be_vec arm_elf32_le_vec arm_elf32_be_vec"
- want64=true
- ;;
- aarch64-*-openbsd*)
- targ_defvec=aarch64_elf64_le_vec
- targ_selvecs="aarch64_elf64_be_vec arm_elf32_le_vec arm_elf32_be_vec"
- want64=true
- ;;
- aarch64-*-fuchsia*)
- targ_defvec=aarch64_elf64_le_vec
- targ_selvecs="aarch64_elf64_be_vec arm_elf32_le_vec arm_elf32_be_vec"
- want64=true
- ;;
- aarch64-*-cloudabi*)
- targ_defvec=aarch64_elf64_le_cloudabi_vec
- targ_selvecs=aarch64_elf64_be_cloudabi_vec
- want64=true
- ;;
- aarch64-*-haiku*)
- targ_defvec=aarch64_elf64_le_vec
- targ_selvecs="aarch64_elf64_be_vec aarch64_elf32_le_vec aarch64_elf32_be_vec arm_elf32_le_vec arm_elf32_be_vec"
- want64=true
- ;;
- aarch64-*-linux* | aarch64-*-netbsd* | aarch64-*-nto* | aarch64-*-gnu*)
- targ_defvec=aarch64_elf64_le_vec
- targ_selvecs="aarch64_elf64_be_vec aarch64_elf32_le_vec aarch64_elf32_be_vec arm_elf32_le_vec arm_elf32_be_vec aarch64_pei_le_vec aarch64_pe_le_vec"
- want64=true
- ;;
- aarch64_be-*-linux* | aarch64_be-*-netbsd*)
- targ_defvec=aarch64_elf64_be_vec
- targ_selvecs="aarch64_elf64_le_vec aarch64_elf32_le_vec aarch64_elf32_be_vec arm_elf32_be_vec arm_elf32_le_vec"
- want64=true
- ;;
- alpha*-*-freebsd* | alpha*-*-kfreebsd*-gnu)
- targ_defvec=alpha_elf64_fbsd_vec
- targ_selvecs="alpha_elf64_vec alpha_ecoff_le_vec"
- want64=true
- # FreeBSD <= 4.0 supports only the old nonstandard way of ABI labelling.
- case "${targ}" in
- alpha*-*-freebsd3* | alpha*-*-freebsd4 | alpha*-*-freebsd4.0*)
- targ_cflags=-DOLD_FREEBSD_ABI_LABEL ;;
- esac
- ;;
- alpha*-*-netbsd* | alpha*-*-openbsd*)
- targ_defvec=alpha_elf64_vec
- targ_selvecs=alpha_ecoff_le_vec
- want64=true
- ;;
- alpha*-*-linux*ecoff*)
- targ_defvec=alpha_ecoff_le_vec
- targ_selvecs=alpha_elf64_vec
- want64=true
- ;;
- alpha*-*-linux-* | alpha*-*-elf*)
- targ_defvec=alpha_elf64_vec
- targ_selvecs=alpha_ecoff_le_vec
- want64=true
- ;;
- alpha*-*-*vms*)
- targ_defvec=alpha_vms_vec
- targ_selvecs=alpha_vms_lib_txt_vec
- want64=true
- ;;
- alpha*-*-*)
- targ_defvec=alpha_ecoff_le_vec
- want64=true
- ;;
- amdgcn-*-*)
- targ_defvec=amdgcn_elf64_le_vec
- want64=true
- ;;
- ia64*-*-freebsd* | ia64*-*-netbsd* | ia64*-*-linux-* | ia64*-*-elf* | ia64*-*-kfreebsd*-gnu)
- targ_defvec=ia64_elf64_le_vec
- targ_selvecs="ia64_elf64_be_vec ia64_pei_vec"
- want64=true
- ;;
- ia64*-*-hpux*)
- targ_defvec=ia64_elf32_hpux_be_vec
- targ_selvecs="ia64_elf64_hpux_be_vec"
- want64=true
- ;;
- ia64*-*-*vms*)
- targ_defvec=ia64_elf64_vms_vec
- targ_selvecs=alpha_vms_lib_txt_vec
- want64=true
- ;;
-#endif /* BFD64 */
-
- am33_2.0-*-linux*)
- targ_defvec=am33_elf32_linux_vec
- ;;
-
- arc*eb-*-elf* | arc*eb-*-linux*)
- targ_defvec=arc_elf32_be_vec
- targ_selvecs=arc_elf32_le_vec
- ;;
-
- arc*-*-elf* | arc*-*-linux*)
- targ_defvec=arc_elf32_le_vec
- targ_selvecs=arc_elf32_be_vec
- ;;
-
- arm-*-darwin*)
- targ_defvec=arm_mach_o_vec
- targ_selvecs="mach_o_le_vec mach_o_be_vec mach_o_fat_vec"
- targ_archs="$targ_archs bfd_i386_arch bfd_powerpc_arch bfd_rs6000_arch"
- ;;
- arm-*-fuchsia*)
- targ_defvec=arm_elf32_le_vec
- targ_selvecs="arm_elf32_be_vec"
- ;;
- arm*-*-haiku*)
- targ_defvec=arm_elf32_le_vec
- targ_selvecs="arm_elf32_fdpic_le_vec arm_elf32_be_vec arm_elf32_fdpic_be_vec arm_pe_le_vec arm_pe_be_vec arm_pei_le_vec arm_pei_be_vec"
- ;;
- arm-*-nacl*)
- targ_defvec=arm_elf32_nacl_le_vec
- targ_selvecs="arm_elf32_nacl_be_vec"
- ;;
- armeb-*-nacl*)
- targ_defvec=arm_elf32_nacl_be_vec
- targ_selvecs="arm_elf32_nacl_le_vec"
- ;;
- armeb-*-netbsd*)
- targ_defvec=arm_elf32_be_vec
- targ_selvecs="arm_elf32_le_vec"
- ;;
- arm-*-netbsd* | arm-*-openbsd*)
- targ_defvec=arm_elf32_le_vec
- targ_selvecs="arm_elf32_be_vec"
- ;;
- arm-*-nto* | nto*arm*)
- targ_defvec=arm_elf32_le_vec
- targ_selvecs=arm_elf32_be_vec
- targ_cflags=-D__QNXTARGET__
- ;;
- arm-wince-pe | arm-*-wince | arm*-*-mingw32ce* | arm*-*-cegcc*)
- targ_defvec=arm_pe_wince_le_vec
- targ_selvecs="arm_pe_wince_le_vec arm_pe_wince_be_vec arm_pei_wince_le_vec arm_pei_wince_be_vec"
- targ_underscore=no
- targ_cflags="-DARM_WINCE -DARM_COFF_BUGFIX"
- ;;
- arm-*-pe*)
- targ_defvec=arm_pe_le_vec
- targ_selvecs="arm_pe_le_vec arm_pe_be_vec arm_pei_le_vec arm_pei_be_vec"
- targ_underscore=yes
- ;;
- arm-*-phoenix*)
- targ_defvec=arm_elf32_le_vec
- targ_selvecs=arm_elf32_be_vec
- ;;
- armeb-*-elf | arm*b-*-freebsd* | arm*b-*-linux-* | armeb-*-eabi*)
- targ_defvec=arm_elf32_be_vec
- targ_selvecs=arm_elf32_le_vec
- ;;
- arm-*-kaos*)
- targ_defvec=arm_elf32_le_vec
- targ_selvecs=arm_elf32_be_vec
- ;;
- arm-*-elf | arm*-*-freebsd* | arm*-*-linux-* | arm*-*-conix* | \
- arm*-*-uclinux* | arm-*-kfreebsd*-gnu | \
- arm*-*-eabi* | arm-*-rtems* | arm*-*-uclinuxfdpiceabi)
- targ_defvec=arm_elf32_le_vec
- targ_selvecs="arm_elf32_fdpic_le_vec arm_elf32_be_vec arm_elf32_fdpic_be_vec"
- ;;
- arm*-*-vxworks | arm*-*-windiss)
- targ_defvec=arm_elf32_vxworks_le_vec
- targ_selvecs=arm_elf32_vxworks_be_vec
- ;;
- arm9e-*-elf)
- targ_defvec=arm_elf32_le_vec
- targ_selvecs=arm_elf32_be_vec
- ;;
-
- avr-*-*)
- targ_defvec=avr_elf32_vec
- ;;
-
- bfin-*-*)
- targ_defvec=bfin_elf32_vec
- targ_selvecs=bfin_elf32_fdpic_vec
- targ_underscore=yes
- ;;
-
- c30-*-*coff* | tic30-*-*coff*)
- targ_defvec=tic30_coff_vec
- ;;
-
- c4x-*-*coff* | tic4x-*-*coff*)
- targ_defvec=tic4x_coff1_vec
- targ_selvecs="tic4x_coff1_beh_vec tic4x_coff2_vec tic4x_coff2_beh_vec tic4x_coff0_vec tic4x_coff0_beh_vec"
- targ_underscore=yes
- ;;
-
- c54x*-*-*coff* | tic54x-*-*coff*)
- targ_defvec=tic54x_coff1_vec
- targ_selvecs="tic54x_coff1_beh_vec tic54x_coff2_vec tic54x_coff2_beh_vec tic54x_coff0_vec tic54x_coff0_beh_vec"
- targ_underscore=yes
- ;;
-
- cr16-*-elf* | cr16*-*-uclinux*)
- targ_defvec=cr16_elf32_vec
- targ_underscore=yes
- ;;
-
- cris-*-* | crisv32-*-*)
- targ_defvec=cris_aout_vec
- targ_selvecs="cris_elf32_us_vec cris_elf32_vec"
- case "${targ}" in
- *-*-linux*) ;;
- *) targ_underscore=yes ;;
- esac
- want64=true
- ;;
-
- crx-*-elf*)
- targ_defvec=crx_elf32_vec
- targ_underscore=yes
- ;;
-
- csky-*-elf* | csky-*-linux* )
- targ_defvec=csky_elf32_le_vec
- targ_selvecs="csky_elf32_be_vec csky_elf32_le_vec"
- ;;
-
- d10v-*-*)
- targ_defvec=d10v_elf32_vec
- ;;
-
- dlx-*-elf*)
- targ_defvec=dlx_elf32_be_vec
- targ_selvecs="dlx_elf32_be_vec"
- ;;
-
- d30v-*-*)
- targ_defvec=d30v_elf32_vec
- ;;
-
-#ifdef BFD64
- bpf-*-none | bpf-*)
- targ_defvec=bpf_elf64_le_vec
- targ_selvecs=bpf_elf64_be_vec
- targ_underscore=yes
- ;;
-#endif
-
- epiphany-*-*)
- targ_defvec=epiphany_elf32_vec
- targ_underscore=yes
- ;;
-
- fido-*-elf* )
- targ_defvec=m68k_elf32_vec
- ;;
-
- fr30-*-elf)
- targ_defvec=fr30_elf32_vec
- ;;
-
- frv-*-elf)
- targ_defvec=frv_elf32_vec
- targ_selvecs=frv_elf32_fdpic_vec
- ;;
-
- frv-*-*linux*)
- targ_defvec=frv_elf32_fdpic_vec
- targ_selvecs=frv_elf32_vec
- ;;
-
- moxie-*-elf | moxie-*-rtems* | moxie-*-uclinux)
- targ_defvec=moxie_elf32_be_vec
- targ_selvecs=moxie_elf32_le_vec
- ;;
-
- moxie-*-moxiebox*)
- targ_defvec=moxie_elf32_le_vec
- ;;
-
- h8300*-*-elf | h8300*-*-rtems*)
- targ_defvec=h8300_elf32_vec
- targ_underscore=yes
- ;;
-
- h8300*-*-linux*)
- targ_defvec=h8300_elf32_linux_vec
- ;;
-
-#ifdef BFD64
- hppa*64*-*-linux-*)
- targ_defvec=hppa_elf64_linux_vec
- targ_selvecs=hppa_elf64_vec
- want64=true
- ;;
- hppa*64*-*-hpux11*)
- targ_defvec=hppa_elf64_vec
- targ_selvecs=hppa_elf64_linux_vec
- targ_cflags=-DHPUX_LARGE_AR_IDS
- want64=true
- ;;
-#endif
-
- hppa*-*-linux-*)
- targ_defvec=hppa_elf32_linux_vec
- targ_selvecs=hppa_elf32_vec
- ;;
- hppa*-*-netbsd*)
- targ_defvec=hppa_elf32_nbsd_vec
- targ_selvecs="hppa_elf32_vec hppa_elf32_linux_vec"
- ;;
- hppa*-*-*elf* | hppa*-*-lites* | hppa*-*-sysv4* | hppa*-*-openbsd*)
- targ_defvec=hppa_elf32_vec
- targ_selvecs=hppa_elf32_linux_vec
- ;;
-
- hppa*-*-bsd*)
- targ_defvec=hppa_som_vec
- targ_selvecs=hppa_elf32_vec
- ;;
- hppa*-*-hpux* | hppa*-*-hiux* | hppa*-*-mpeix*)
- targ_defvec=hppa_som_vec
- ;;
- hppa*-*-osf*)
- targ_defvec=hppa_som_vec
- targ_selvecs=hppa_elf32_vec
- ;;
-
- i[3-7]86-*-elf* | i[3-7]86-*-rtems* | i[3-7]86-*-genode*)
- targ_defvec=i386_elf32_vec
- targ_selvecs="iamcu_elf32_vec i386_coff_vec"
- ;;
- i[3-7]86-*-solaris2*)
- targ_defvec=i386_elf32_sol2_vec
- targ_selvecs="iamcu_elf32_vec i386_coff_vec i386_pei_vec"
- targ64_selvecs="x86_64_elf64_sol2_vec x86_64_pe_vec x86_64_pei_vec"
- want64=true
- ;;
-#ifdef BFD64
- x86_64-*-solaris2*)
- targ_defvec=i386_elf32_sol2_vec
- targ_selvecs="x86_64_elf64_sol2_vec iamcu_elf32_vec i386_coff_vec i386_pei_vec x86_64_pe_vec x86_64_pei_vec"
- want64=true
- ;;
-#endif
- i[3-7]86-*-nto*)
- targ_defvec=i386_elf32_vec
- targ_selvecs="iamcu_elf32_vec i386_coff_vec"
- ;;
- i[3-7]86-*-aros*)
- targ_defvec=i386_elf32_vec
- targ_selvecs=iamcu_elf32_vec
- ;;
- i[3-7]86-*-dicos*)
- targ_defvec=i386_elf32_vec
- targ_selvecs=iamcu_elf32_vec
- targ64_selvecs="x86_64_elf64_vec"
- ;;
- *-*-msdosdjgpp* | *-*-go32* )
- targ_defvec=i386_coff_go32_vec
- targ_selvecs="i386_coff_go32stubbed_vec i386_aout_vec"
- ;;
- i[3-7]86-*-darwin* | i[3-7]86-*-macos10* | i[3-7]86-*-rhapsody*)
- targ_defvec=i386_mach_o_vec
- targ_selvecs="mach_o_le_vec mach_o_be_vec mach_o_fat_vec pef_vec pef_xlib_vec sym_vec"
- targ64_selvecs=x86_64_mach_o_vec
- targ_archs="$targ_archs bfd_powerpc_arch bfd_rs6000_arch"
- ;;
- i[3-7]86-*-bsd*)
- targ_defvec=i386_aout_bsd_vec
- targ_underscore=yes
- ;;
- i[3-7]86-*-dragonfly*)
- targ_defvec=i386_elf32_vec
- targ_selvecs=iamcu_elf32_vec
- targ64_selvecs="x86_64_elf64_vec"
- ;;
- i[3-7]86-*-freebsd* | i[3-7]86-*-kfreebsd*-gnu)
- targ_defvec=i386_elf32_fbsd_vec
- targ_selvecs="i386_elf32_vec iamcu_elf32_vec i386_pei_vec i386_coff_vec"
- targ64_selvecs="x86_64_elf64_fbsd_vec x86_64_elf64_vec x86_64_pe_vec x86_64_pei_vec"
- # FreeBSD <= 4.0 supports only the old nonstandard way of ABI labelling.
- case "${targ}" in
- i[3-7]86-*-freebsd3* | i[3-7]86-*-freebsd4 | i[3-7]86-*-freebsd4.0*)
- targ_cflags=-DOLD_FREEBSD_ABI_LABEL ;;
- esac
- ;;
- i[3-7]86-*-netbsd* | i[3-7]86-*-knetbsd*-gnu)
- targ_defvec=i386_elf32_vec
- targ_selvecs="iamcu_elf32_vec"
- targ64_selvecs="x86_64_elf64_vec"
- ;;
- i[3-7]86-*-openbsd*)
- targ_defvec=i386_elf32_vec
- targ_selvecs="iamcu_elf32_vec"
- ;;
- i[3-7]86-*-linux-*)
- targ_defvec=i386_elf32_vec
- targ_selvecs="iamcu_elf32_vec i386_pei_vec"
- targ64_selvecs="x86_64_elf64_vec x86_64_elf32_vec x86_64_pe_vec x86_64_pei_vec"
- ;;
- i[3-7]86-*-redox*)
- targ_defvec=i386_elf32_vec
- targ_selvecs=
- targ64_selvecs=x86_64_elf64_vec
- ;;
-#ifdef BFD64
- x86_64-*-cloudabi*)
- targ_defvec=x86_64_elf64_cloudabi_vec
- want64=true
- ;;
- x86_64-*-darwin*)
- targ_defvec=x86_64_mach_o_vec
- targ_selvecs="i386_mach_o_vec mach_o_le_vec mach_o_be_vec mach_o_fat_vec pef_vec pef_xlib_vec sym_vec"
- targ_archs="$targ_archs bfd_powerpc_arch bfd_rs6000_arch"
- want64=true
- ;;
- x86_64-*-dicos*)
- targ_defvec=x86_64_elf64_vec
- targ_selvecs="i386_elf32_vec iamcu_elf32_vec"
- want64=true
- ;;
- x86_64-*-elf* | x86_64-*-rtems* | x86_64-*-fuchsia | x86_64-*-genode*)
- targ_defvec=x86_64_elf64_vec
- targ_selvecs="i386_elf32_vec iamcu_elf32_vec x86_64_elf32_vec"
- case "${targ}" in
- x86_64-*-rtems*)
- targ_selvecs="${targ_selvecs} x86_64_pe_vec x86_64_pei_vec"
- esac
- want64=true
- ;;
- x86_64-*-dragonfly*)
- targ_defvec=x86_64_elf64_vec
- targ_selvecs="i386_elf32_vec iamcu_elf32_vec"
- want64=true
- ;;
- x86_64-*-freebsd* | x86_64-*-kfreebsd*-gnu)
- targ_defvec=x86_64_elf64_fbsd_vec
- targ_selvecs="i386_elf32_fbsd_vec iamcu_elf32_vec i386_coff_vec i386_pei_vec x86_64_pe_vec x86_64_pei_vec i386_elf32_vec x86_64_elf64_vec"
- want64=true
- ;;
- x86_64-*-haiku*)
- targ_defvec=x86_64_elf64_vec
- targ_selvecs="i386_elf32_vec"
- want64=true
- ;;
- x86_64-*-netbsd* | x86_64-*-openbsd*)
- targ_defvec=x86_64_elf64_vec
- targ_selvecs="i386_elf32_vec iamcu_elf32_vec i386_coff_vec i386_pei_vec x86_64_pe_vec x86_64_pei_vec"
- want64=true
- ;;
- x86_64-*-linux-*)
- targ_defvec=x86_64_elf64_vec
- targ_selvecs="i386_elf32_vec iamcu_elf32_vec x86_64_elf32_vec i386_pei_vec x86_64_pe_vec x86_64_pei_vec"
- want64=true
- ;;
- x86_64-*-mingw* | x86_64-*-pe | x86_64-*-pep | x86_64-*-cygwin)
- targ_defvec=x86_64_pe_vec
- targ_selvecs="x86_64_pe_vec x86_64_pei_vec x86_64_pe_big_vec x86_64_elf64_vec i386_pe_vec i386_pei_vec i386_elf32_vec iamcu_elf32_vec pdb_vec"
- want64=true
- targ_underscore=no
- ;;
- x86_64-*-rdos*)
- targ_defvec=x86_64_elf64_vec
- want64=true
- ;;
- x86_64-*-redox*)
- targ_defvec=x86_64_elf64_vec
- targ_selvecs=i386_elf32_vec
- want64=true
- ;;
- x86_64-*-gnu*)
- targ_defvec=x86_64_elf64_vec
- targ_selvecs="i386_elf32_vec iamcu_elf32_vec x86_64_elf32_vec"
- want64=true
- ;;
-#endif
- i[3-7]86-*-lynxos*)
- targ_defvec=i386_elf32_vec
- targ_selvecs="iamcu_elf32_vec i386_coff_lynx_vec i386_aout_lynx_vec"
- ;;
- i[3-7]86-*-gnu*)
- targ_defvec=i386_elf32_vec
- targ_selvecs=iamcu_elf32_vec
- ;;
- i[3-7]86-*-msdos*)
- targ_defvec=i386_aout_vec
- targ_selvecs=i386_msdos_vec
- ;;
- i[3-7]86-*-moss*)
- targ_defvec=i386_elf32_vec
- targ_selvecs="iamcu_elf32_vec i386_msdos_vec i386_aout_vec"
- ;;
- i[3-7]86-*-beospe*)
- targ_defvec=i386_pe_vec
- targ_selvecs="i386_pe_vec i386_pei_vec"
- ;;
- i[3-7]86-*-beos*)
- targ_defvec=i386_elf32_vec
- targ_selvecs="iamcu_elf32_vec i386_pe_vec i386_pei_vec"
- ;;
- i[3-7]86-*-haiku*)
- targ_defvec=i386_elf32_vec
- targ_selvecs="i386_pei_vec"
- ;;
- i[3-7]86-*-interix*)
- targ_defvec=i386_pei_vec
- targ_selvecs="i386_pe_vec"
- # FIXME: This should eventually be checked at runtime.
- targ_cflags=-DSTRICT_PE_FORMAT
- ;;
- i[3-7]86-*-rdos*)
- targ_defvec=i386_elf32_vec
- targ_selvecs="iamcu_elf32_vec i386_coff_vec"
- ;;
- i[3-7]86-*-mingw32* | i[3-7]86-*-cygwin* | i[3-7]86-*-winnt | i[3-7]86-*-pe)
- targ_defvec=i386_pe_vec
- targ_selvecs="i386_pe_vec i386_pe_big_vec i386_pei_vec i386_elf32_vec iamcu_elf32_vec pdb_vec"
- targ_underscore=yes
- ;;
- i[3-7]86-*-vxworks*)
- targ_defvec=i386_elf32_vxworks_vec
- targ_underscore=yes
- ;;
-
- ia16-*-elf)
- targ_defvec=i386_elf32_vec
- targ_selvecs="i386_msdos_vec i386_aout_vec"
- ;;
-
- ip2k-*-elf)
- targ_defvec=ip2k_elf32_vec
- targ_underscore=yes
- ;;
-
- iq2000-*-elf)
- targ_defvec=iq2000_elf32_vec
- ;;
-
-#ifdef BFD64
- kvx-*-linux*)
- targ_defvec=kvx_elf64_vec
- targ_selvecs=kvx_elf32_vec
- want64=true
- ;;
-
- kvx-*-*)
- targ_defvec=kvx_elf64_vec
- targ_selvecs=kvx_elf32_vec
- want64=true
- ;;
-#endif
-
- lm32-*-elf | lm32-*-rtems*)
- targ_defvec=lm32_elf32_vec
- targ_selvecs=lm32_elf32_fdpic_vec
- ;;
-
- lm32-*-*linux*)
- targ_defvec=lm32_elf32_fdpic_vec
- targ_selvecs=lm32_elf32_vec
- ;;
-
- m32c-*-elf)
- targ_defvec=m32c_elf32_vec
- targ_underscore=yes
- ;;
-
- m32r*le-*-linux*)
- targ_defvec=m32r_elf32_linux_le_vec
- targ_selvecs="m32r_elf32_linux_vec m32r_elf32_linux_le_vec"
- ;;
- m32r*-*-linux*)
- targ_defvec=m32r_elf32_linux_vec
- targ_selvecs="m32r_elf32_linux_vec m32r_elf32_linux_le_vec"
- ;;
- m32r*le-*-*)
- targ_defvec=m32r_elf32_le_vec
- targ_selvecs="m32r_elf32_vec m32r_elf32_le_vec"
- ;;
- m32r-*-*)
- targ_defvec=m32r_elf32_vec
- ;;
-
- m68*-*-haiku*)
- targ_defvec=m68k_elf32_vec
- ;;
- m68hc11-*-* | m6811-*-*)
- targ_defvec=m68hc11_elf32_vec
- targ_selvecs="m68hc11_elf32_vec m68hc12_elf32_vec"
- ;;
- m68hc12-*-* | m6812-*-*)
- targ_defvec=m68hc12_elf32_vec
- targ_selvecs="m68hc11_elf32_vec m68hc12_elf32_vec"
- ;;
-
- m68*-*-*)
- targ_defvec=m68k_elf32_vec
- ;;
-
- s12z-*-*)
- targ_defvec=s12z_elf32_vec
- ;;
- mcore-*-elf)
- targ_defvec=mcore_elf32_be_vec
- targ_selvecs="mcore_elf32_be_vec mcore_elf32_le_vec"
- ;;
- mcore-*-pe)
- targ_defvec=mcore_pe_be_vec
- targ_selvecs="mcore_pe_be_vec mcore_pe_le_vec mcore_pei_be_vec mcore_pei_le_vec"
- ;;
-
- mep-*-elf)
- targ_defvec=mep_elf32_vec
- targ_selvecs=mep_elf32_le_vec
- ;;
-
- metag-*-*)
- targ_defvec=metag_elf32_vec
- targ_underscore=yes
- ;;
-
- microblazeel*-*)
- targ_defvec=microblaze_elf32_le_vec
- targ_selvecs=microblaze_elf32_vec
- ;;
-
- microblaze*-*)
- targ_defvec=microblaze_elf32_vec
- targ_selvecs=microblaze_elf32_le_vec
- ;;
-
-#ifdef BFD64
- mips*el-*-netbsd*)
- targ_defvec=mips_elf32_trad_le_vec
- targ_selvecs="mips_elf32_trad_be_vec mips_elf64_trad_be_vec mips_elf64_trad_le_vec mips_ecoff_le_vec mips_ecoff_be_vec"
- ;;
- mips*-*-netbsd*)
- targ_defvec=mips_elf32_trad_be_vec
- targ_selvecs="mips_elf32_trad_le_vec mips_elf64_trad_be_vec mips_elf64_trad_le_vec mips_ecoff_be_vec mips_ecoff_le_vec"
- ;;
- mips*el-*-haiku*)
- targ_defvec=mips_elf32_le_vec
- targ_selvecs="mips_elf32_be_vec mips_elf64_be_vec mips_elf64_le_vec mips_ecoff_le_vec mips_ecoff_be_vec"
- ;;
- mips*-*-irix6*)
- targ_defvec=mips_elf32_n_be_vec
- targ_selvecs="mips_elf32_n_le_vec mips_elf32_be_vec mips_elf32_le_vec mips_elf64_be_vec mips_elf64_le_vec"
- ;;
- mips64*-ps2-elf*)
- targ_defvec=mips_elf32_n_le_vec
- targ_selvecs="mips_elf32_n_le_vec mips_elf32_n_be_vec mips_elf32_be_vec mips_elf32_le_vec mips_elf64_be_vec mips_elf64_le_vec"
- ;;
- mips*-ps2-elf*)
- targ_defvec=mips_elf32_le_vec
- targ_selvecs="mips_elf32_be_vec mips_elf32_le_vec mips_elf64_be_vec mips_elf64_le_vec"
- ;;
- mips*-*-irix5*)
- targ_defvec=mips_elf32_be_vec
- targ_selvecs="mips_elf32_le_vec mips_ecoff_be_vec mips_ecoff_le_vec"
- ;;
- mips*el-*-vxworks*)
- targ_defvec=mips_elf32_vxworks_le_vec
- targ_selvecs="mips_elf32_le_vec mips_elf32_vxworks_be_vec mips_elf32_be_vec mips_elf64_be_vec mips_elf64_le_vec"
- ;;
- mips*-*-vxworks*)
- targ_defvec=mips_elf32_vxworks_be_vec
- targ_selvecs="mips_elf32_be_vec mips_elf32_vxworks_le_vec mips_elf32_be_vec mips_elf64_be_vec mips_elf64_le_vec"
- ;;
- mips*el-sde-elf*)
- targ_defvec=mips_elf32_trad_le_vec
- targ_selvecs="mips_elf32_trad_be_vec mips_elf32_ntrad_be_vec mips_elf32_ntrad_le_vec mips_elf64_trad_be_vec mips_elf64_trad_le_vec"
- ;;
- mips*-sde-elf* | mips*-mti-elf* | mips*-img-elf*)
- targ_defvec=mips_elf32_trad_be_vec
- targ_selvecs="mips_elf32_trad_le_vec mips_elf32_ntrad_be_vec mips_elf32_ntrad_le_vec mips_elf64_trad_be_vec mips_elf64_trad_le_vec"
- ;;
- mips*el-*-elf* | mips*-*-chorus*)
- targ_defvec=mips_elf32_le_vec
- targ_selvecs="mips_elf32_be_vec mips_elf64_be_vec mips_elf64_le_vec"
- ;;
- mips*-*-elf* | mips*-*-rtems* | mips*-*-windiss | mips*-*-none)
- targ_defvec=mips_elf32_be_vec
- targ_selvecs="mips_elf32_le_vec mips_elf64_be_vec mips_elf64_le_vec"
- ;;
- mips64*-*-openbsd*)
- targ_defvec=mips_elf64_trad_be_vec
- targ_selvecs="mips_elf32_ntrad_le_vec mips_elf32_ntrad_be_vec mips_elf32_trad_le_vec mips_elf32_trad_be_vec mips_elf64_trad_le_vec"
- ;;
- mips*el-*-openbsd*)
- targ_defvec=mips_elf32_le_vec
- targ_selvecs="mips_elf32_be_vec mips_elf64_be_vec mips_elf64_le_vec mips_ecoff_le_vec mips_ecoff_be_vec"
- ;;
- mips*-*-openbsd*)
- targ_defvec=mips_elf32_be_vec
- targ_selvecs="mips_elf32_le_vec mips_elf64_be_vec mips_elf64_le_vec mips_ecoff_be_vec mips_ecoff_le_vec"
- ;;
- mips64*el-*-linux*-gnuabi64)
- targ_defvec=mips_elf64_trad_le_vec
- targ_selvecs="mips_elf64_trad_be_vec mips_elf32_ntrad_le_vec mips_elf32_ntrad_be_vec mips_elf32_trad_le_vec mips_elf32_trad_be_vec"
- want64=true
- ;;
- mips64*el-*-linux*)
- targ_defvec=mips_elf32_ntrad_le_vec
- targ_selvecs="mips_elf32_ntrad_be_vec mips_elf32_trad_le_vec mips_elf32_trad_be_vec mips_elf64_trad_le_vec mips_elf64_trad_be_vec"
- ;;
- mips64*-*-linux*-gnuabi64)
- targ_defvec=mips_elf64_trad_be_vec
- targ_selvecs="mips_elf64_trad_le_vec mips_elf32_ntrad_be_vec mips_elf32_ntrad_le_vec mips_elf32_trad_be_vec mips_elf32_trad_le_vec"
- want64=true
- ;;
- mips64*-*-linux*)
- targ_defvec=mips_elf32_ntrad_be_vec
- targ_selvecs="mips_elf32_ntrad_le_vec mips_elf32_trad_be_vec mips_elf32_trad_le_vec mips_elf64_trad_be_vec mips_elf64_trad_le_vec"
- ;;
- mips*el-*-linux*)
- targ_defvec=mips_elf32_trad_le_vec
- targ_selvecs="mips_elf32_trad_be_vec mips_ecoff_le_vec mips_ecoff_be_vec mips_elf32_ntrad_le_vec mips_elf64_trad_le_vec mips_elf32_ntrad_be_vec mips_elf64_trad_be_vec"
- ;;
- mips*-*-linux*)
- targ_defvec=mips_elf32_trad_be_vec
- targ_selvecs="mips_elf32_trad_le_vec mips_ecoff_be_vec mips_ecoff_le_vec mips_elf32_ntrad_be_vec mips_elf64_trad_be_vec mips_elf32_ntrad_le_vec mips_elf64_trad_le_vec"
- ;;
- mips64*el-*-freebsd* | mips64*el-*-kfreebsd*-gnu)
- # FreeBSD vectors
- targ_defvec=mips_elf32_ntradfbsd_le_vec
- targ_selvecs="mips_elf32_ntradfbsd_be_vec mips_elf32_tradfbsd_le_vec mips_elf32_tradfbsd_be_vec mips_elf64_tradfbsd_le_vec mips_elf64_tradfbsd_be_vec"
- # Generic vectors
- targ_selvecs="${targ_selvecs} mips_elf32_ntrad_le_vec mips_elf32_ntrad_be_vec mips_elf32_trad_le_vec mips_elf32_trad_be_vec mips_elf64_trad_le_vec mips_elf64_trad_be_vec"
- ;;
- mips64*-*-freebsd* | mips64*-*-kfreebsd*-gnu)
- # FreeBSD vectors
- targ_defvec=mips_elf32_ntradfbsd_be_vec
- targ_selvecs="mips_elf32_ntradfbsd_le_vec mips_elf32_tradfbsd_be_vec mips_elf32_tradfbsd_le_vec mips_elf64_tradfbsd_be_vec mips_elf64_tradfbsd_le_vec"
- # Generic vectors
- targ_selvecs="${targ_selvecs} mips_elf32_ntrad_be_vec mips_elf32_ntrad_le_vec mips_elf32_trad_be_vec mips_elf32_trad_le_vec mips_elf64_trad_be_vec mips_elf64_trad_le_vec"
- ;;
- mips*el-*-freebsd* | mips*el-*-kfreebsd*-gnu)
- # FreeBSD vectors
- targ_defvec=mips_elf32_tradfbsd_le_vec
- targ_selvecs="mips_elf32_tradfbsd_be_vec mips_elf32_ntradfbsd_le_vec mips_elf64_tradfbsd_le_vec mips_elf32_ntradfbsd_be_vec mips_elf64_tradfbsd_be_vec"
- # Generic vectors
- targ_selvecs="${targ_selvecs} mips_elf32_trad_le_vec mips_elf32_trad_be_vec mips_elf32_ntrad_le_vec mips_elf64_trad_le_vec mips_elf32_ntrad_be_vec mips_elf64_trad_be_vec"
- ;;
- mips*-*-freebsd* | mips*-*-kfreebsd*-gnu)
- # FreeBSD vectors
- targ_defvec=mips_elf32_tradfbsd_be_vec
- targ_selvecs="mips_elf32_tradfbsd_le_vec mips_elf32_ntradfbsd_be_vec mips_elf64_tradfbsd_be_vec mips_elf32_ntradfbsd_le_vec mips_elf64_tradfbsd_le_vec"
- # Generic vectors
- targ_selvecs="${targ_selvecs} mips_elf32_trad_be_vec mips_elf32_trad_le_vec mips_elf32_ntrad_be_vec mips_elf64_trad_be_vec mips_elf32_ntrad_le_vec mips_elf64_trad_le_vec"
- ;;
- mmix-*-*)
- targ_defvec=mmix_elf64_vec
- targ_selvecs=mmix_mmo_vec
- want64=true
- ;;
-#endif
- mn10200-*-*)
- targ_defvec=mn10200_elf32_vec
- targ_underscore=yes
- ;;
-
- mn10300-*-*)
- targ_defvec=mn10300_elf32_vec
- targ_underscore=yes
- ;;
-
- mt-*-elf)
- targ_defvec=mt_elf32_vec
- ;;
-
- msp430-*-*)
- targ_defvec=msp430_elf32_vec
- targ_selvecs=msp430_elf32_ti_vec
- ;;
-
- nds32*le-*-linux*)
- targ_defvec=nds32_elf32_linux_le_vec
- targ_selvecs=nds32_elf32_linux_be_vec
- ;;
-
- nds32*be-*-linux*)
- targ_defvec=nds32_elf32_linux_be_vec
- targ_selvecs=nds32_elf32_linux_le_vec
- ;;
-
- nds32*le-*-*)
- targ_defvec=nds32_elf32_le_vec
- targ_selvecs=nds32_elf32_be_vec
- ;;
-
- nds32*be-*-*)
- targ_defvec=nds32_elf32_be_vec
- targ_selvecs=nds32_elf32_le_vec
- ;;
-
-#ifdef BFD64
- nfp-*-*)
- targ_defvec=nfp_elf64_vec
- ;;
-#endif
-
- ns32k-pc532-mach* | ns32k-pc532-ux*)
- targ_defvec=ns32k_aout_pc532mach_vec
- targ_underscore=yes
- ;;
- ns32k-*-lites* | ns32k-*-*bsd*)
- targ_defvec=ns32k_aout_pc532nbsd_vec
- targ_underscore=yes
- ;;
-
- nios2eb-*-*)
- targ_defvec=nios2_elf32_be_vec
- targ_selvecs=nios2_elf32_le_vec
- ;;
-
- nios2el-*-*)
- targ_defvec=nios2_elf32_le_vec
- targ_selvecs=nios2_elf32_be_vec
- ;;
-
- nios2-*-*)
- targ_defvec=nios2_elf32_le_vec
- targ_selvecs=nios2_elf32_be_vec
- ;;
-
- or1k-*-elf | or1k-*-linux* | or1k-*-rtems*)
- targ_defvec=or1k_elf32_vec
- ;;
-
- or1knd-*-elf | or1knd-*-linux* | or1knd-*-rtems*)
- targ_defvec=or1k_elf32_vec
- ;;
-
- pdp11-*-*)
- targ_defvec=pdp11_aout_vec
- targ_underscore=yes
- ;;
-
- pj-*-*)
- targ_defvec=pj_elf32_vec
- targ_selvecs="pj_elf32_vec pj_elf32_le_vec"
- ;;
-
- pjl-*-*)
- targ_defvec=pj_elf32_le_vec
- targ_selvecs="pj_elf32_le_vec pj_elf32_vec i386_elf32_vec iamcu_elf32_vec"
- ;;
-
- powerpc-*-aix5.[01] | rs6000-*-aix5.[01])
- targ_defvec=rs6000_xcoff_vec
- targ_selvecs="rs6000_xcoff64_aix_vec"
- want64=true
- ;;
- powerpc-*-aix[5-9]* | rs6000-*-aix[5-9]*)
- targ_cflags=-DAIX_WEAK_SUPPORT
- targ_defvec=rs6000_xcoff_vec
- targ_selvecs="rs6000_xcoff64_aix_vec"
- want64=true
- ;;
-#ifdef BFD64
- powerpc64-*-aix5.[01])
- targ_defvec=rs6000_xcoff64_aix_vec
- targ_selvecs="rs6000_xcoff_vec"
- want64=true
- ;;
- powerpc64-*-aix[5-9]*)
- targ_cflags=-DAIX_WEAK_SUPPORT
- targ_defvec=rs6000_xcoff64_aix_vec
- targ_selvecs="rs6000_xcoff_vec"
- want64=true
- ;;
-#endif
-
- powerpc-*-aix* | powerpc-*-beos* | rs6000-*-*)
- targ_defvec=rs6000_xcoff_vec
- targ64_selvecs=rs6000_xcoff64_vec
- case "${targ}" in
- *-*-aix4.[3456789]* | *-*-aix[56789]*)
- want64=true;;
- *)
- targ_cflags=-DSMALL_ARCHIVE;;
- esac
- ;;
-#ifdef BFD64
- powerpc64-*-aix*)
- targ_defvec=rs6000_xcoff64_vec
- targ_selvecs=rs6000_xcoff_vec
- want64=true
- ;;
- powerpc64-*-freebsd*)
- targ_defvec=powerpc_elf64_fbsd_vec
- targ_selvecs="powerpc_elf64_vec powerpc_elf32_vec powerpc_elf32_fbsd_vec powerpc_elf32_le_vec rs6000_xcoff_vec rs6000_xcoff64_vec rs6000_xcoff64_aix_vec"
- want64=true
- ;;
- powerpc64le-*-freebsd*)
- targ_defvec=powerpc_elf64_fbsd_le_vec
- targ_selvecs="powerpc_elf64_vec powerpc_elf32_vec powerpc_elf32_fbsd_vec powerpc_elf32_le_vec rs6000_xcoff_vec rs6000_xcoff64_vec rs6000_xcoff64_aix_vec"
- want64=true
- ;;
- powerpc64-*-elf* | powerpc-*-elf64* | powerpc64-*-linux* | \
- powerpc64-*-*bsd*)
- targ_defvec=powerpc_elf64_vec
- targ_selvecs="powerpc_elf64_le_vec powerpc_elf32_vec powerpc_elf32_le_vec rs6000_xcoff_vec rs6000_xcoff64_vec rs6000_xcoff64_aix_vec"
- want64=true
- ;;
- powerpc64le-*-elf* | powerpcle-*-elf64* | powerpc64le-*-linux* | \
- powerpc64le-*-*bsd*)
- targ_defvec=powerpc_elf64_le_vec
- targ_selvecs="powerpc_elf64_vec powerpc_elf32_le_vec powerpc_elf32_vec rs6000_xcoff_vec rs6000_xcoff64_vec rs6000_xcoff64_aix_vec"
- want64=true
- ;;
-#endif
- powerpc-*-*freebsd*)
- targ_defvec=powerpc_elf32_fbsd_vec
- targ_selvecs="rs6000_xcoff_vec powerpc_elf32_vec powerpc_elf32_le_vec powerpc_boot_vec"
- targ64_selvecs="powerpc_elf64_vec powerpc_elf64_le_vec powerpc_elf64_fbsd_vec"
- ;;
- powerpc-*-*bsd* | powerpc-*-elf* | powerpc-*-sysv4* | powerpc-*-eabi* | \
- powerpc-*-solaris2* | powerpc-*-linux-* | powerpc-*-rtems* | \
- powerpc-*-chorus*)
- targ_defvec=powerpc_elf32_vec
- targ_selvecs="rs6000_xcoff_vec powerpc_elf32_le_vec powerpc_boot_vec"
- targ64_selvecs="powerpc_elf64_vec powerpc_elf64_le_vec"
- ;;
- powerpc-*-haiku*)
- targ_defvec=powerpc_elf32_vec
- targ_selvecs="rs6000_xcoff_vec powerpc_elf32_le_vec pef_vec pef_xlib_vec powerpc_xcoff_vec powerpc_boot_vec"
- targ_cflags=-D__HAIKU_TARGET__
- ;;
- powerpc-*-kaos*)
- targ_defvec=powerpc_elf32_vec
- targ_selvecs="powerpc_elf32_le_vec powerpc_boot_vec"
- targ64_selvecs="powerpc_elf64_vec powerpc_elf64_le_vec"
- ;;
- powerpc-*-darwin* | powerpc-*-macos10* | powerpc-*-rhapsody*)
- targ_defvec=mach_o_be_vec
- targ_selvecs="mach_o_be_vec mach_o_le_vec mach_o_fat_vec pef_vec pef_xlib_vec sym_vec"
- targ_archs="$targ_archs bfd_i386_arch"
- ;;
- powerpc-*-macos*)
- targ_defvec=powerpc_xcoff_vec
- ;;
- powerpc-*-nto*)
- targ_defvec=powerpc_elf32_vec
- targ_selvecs="rs6000_xcoff_vec powerpc_elf32_le_vec powerpc_boot_vec"
- ;;
- powerpc-*-vxworks*)
- targ_defvec=powerpc_elf32_vxworks_vec
- targ_selvecs="rs6000_xcoff_vec powerpc_elf32_vec powerpc_elf32_le_vec powerpc_boot_vec"
- targ64_selvecs="powerpc_elf64_vec powerpc_elf64_le_vec"
- ;;
- powerpcle-*-nto*)
- targ_defvec=powerpc_elf32_le_vec
- targ_selvecs="rs6000_xcoff_vec powerpc_elf32_vec powerpc_boot_vec"
- ;;
- powerpcle-*-elf* | powerpcle-*-sysv4* | powerpcle-*-eabi* | \
- powerpcle-*-solaris2* | powerpcle-*-linux-* | powerpcle-*-vxworks*)
- targ_defvec=powerpc_elf32_le_vec
- targ_selvecs="rs6000_xcoff_vec powerpc_elf32_vec powerpc_boot_vec"
- targ64_selvecs="powerpc_elf64_vec powerpc_elf64_le_vec"
- ;;
-
- pru-*-*)
- targ_defvec=pru_elf32_vec
- ;;
-
-#ifdef BFD64
- riscvbe-*-* | riscv32be*-*-*)
- targ_defvec=riscv_elf32_be_vec
- targ_selvecs="riscv_elf32_vec riscv_elf64_vec riscv_elf32_be_vec riscv_elf64_be_vec riscv64_pei_vec"
- want64=true
- ;;
- riscv-*-* | riscv32*-*-*)
- targ_defvec=riscv_elf32_vec
- targ_selvecs="riscv_elf32_vec riscv_elf64_vec riscv_elf32_be_vec riscv_elf64_be_vec riscv64_pei_vec"
- want64=true
- ;;
- riscv64be*-*-*)
- targ_defvec=riscv_elf64_be_vec
- targ_selvecs="riscv_elf32_vec riscv_elf64_vec riscv_elf32_be_vec riscv_elf64_be_vec riscv64_pei_vec"
- want64=true
- ;;
- riscv64*-*-*)
- targ_defvec=riscv_elf64_vec
- targ_selvecs="riscv_elf32_vec riscv_elf64_vec riscv_elf32_be_vec riscv_elf64_be_vec riscv64_pei_vec"
- want64=true
- ;;
-#endif
-
- rl78-*-elf)
- targ_defvec=rl78_elf32_vec
- targ_underscore=yes
- ;;
-
- rx-*-elf)
- targ_defvec=rx_elf32_le_vec
- targ_selvecs="rx_elf32_be_vec rx_elf32_le_vec rx_elf32_be_ns_vec"
- targ_underscore=yes
- ;;
- rx-*-linux*)
- targ_defvec=rx_elf32_linux_le_vec
- targ_selvecs="rx_elf32_linux_le_vec"
- ;;
-
- s390-*-linux*)
- targ_defvec=s390_elf32_vec
- targ64_selvecs=s390_elf64_vec
- want64=true
- ;;
-#ifdef BFD64
- s390x-*-linux*)
- targ_defvec=s390_elf64_vec
- targ_selvecs=s390_elf32_vec
- want64=true
- ;;
- s390x-*-tpf*)
- targ_defvec=s390_elf64_vec
- want64=true
- ;;
-
- score*-*-elf*)
- targ_defvec=score_elf32_be_vec
- targ_selvecs=score_elf32_le_vec
- ;;
-#endif /* BFD64 */
-
- sh*eb-*-linux*)
- targ_defvec=sh_elf32_linux_be_vec
- targ_selvecs=sh_elf32_linux_vec
- targ_selvecs="${targ_selvecs} sh_elf32_fdpic_le_vec sh_elf32_fdpic_be_vec"
- ;;
- sh*-*-linux*)
- targ_defvec=sh_elf32_linux_vec
- targ_selvecs=sh_elf32_linux_be_vec
- targ_selvecs="${targ_selvecs} sh_elf32_fdpic_le_vec sh_elf32_fdpic_be_vec"
- ;;
-
- sh-*-uclinux* | sh[12]-*-uclinux*)
- targ_defvec=sh_elf32_vec
- targ_selvecs="sh_elf32_le_vec sh_elf32_linux_be_vec sh_elf32_linux_vec sh_elf32_fdpic_le_vec sh_elf32_fdpic_be_vec"
- ;;
-
- sh*l*-*-netbsd*)
- targ_defvec=sh_elf32_nbsd_le_vec
- targ_selvecs="sh_elf32_nbsd_vec sh_coff_vec sh_coff_le_vec"
- ;;
- sh*-*-netbsd*)
- targ_defvec=sh_elf32_nbsd_vec
- targ_selvecs="sh_elf32_nbsd_le_vec sh_coff_vec sh_coff_le_vec"
- ;;
-
- shl*-*-elf* | sh[1234]l*-*-elf* | sh3el*-*-elf* | shl*-*-kaos*)
- targ_defvec=sh_elf32_le_vec
- targ_selvecs="sh_elf32_vec sh_coff_le_vec sh_coff_vec sh_coff_small_le_vec sh_coff_small_vec"
- targ_underscore=yes
- ;;
-
- sh-*-elf* | sh[1234]*-elf* | sh-*-rtems* | sh-*-kaos*)
- targ_defvec=sh_elf32_vec
- targ_selvecs="sh_elf32_le_vec sh_coff_vec sh_coff_le_vec sh_coff_small_vec sh_coff_small_le_vec"
- targ_underscore=yes
- ;;
-
- sh-*-nto*)
- targ_defvec=sh_elf32_vec
- targ_selvecs="sh_elf32_le_vec sh_coff_vec sh_coff_le_vec sh_coff_small_vec sh_coff_small_le_vec"
- targ_underscore=yes
- ;;
- sh*-*-openbsd*)
- targ_defvec=sh_elf32_nbsd_le_vec
- targ_selvecs="sh_elf32_nbsd_vec sh_coff_vec sh_coff_le_vec"
- ;;
- sh-*-pe)
- targ_defvec=sh_pe_le_vec
- targ_selvecs="sh_pe_le_vec sh_pei_le_vec"
- targ_underscore=yes
- ;;
- sh-*-vxworks)
- targ_defvec=sh_elf32_vxworks_vec
- targ_selvecs="sh_elf32_vxworks_le_vec"
- # FIXME None of the following are actually used on this target, but
- # they're necessary for coff-sh.c (which is unconditionally used) to be
- # compiled correctly.
- targ_selvecs="$targ_selvecs sh_coff_vec sh_coff_le_vec sh_coff_small_vec sh_coff_small_le_vec"
- targ_underscore=yes
- ;;
- sh-*-*)
- targ_defvec=sh_coff_vec
- targ_selvecs="sh_coff_vec sh_coff_le_vec sh_coff_small_vec sh_coff_small_le_vec"
- targ_underscore=yes
- ;;
-
- sparc-*-solaris2.[0-6] | sparc-*-solaris2.[0-6].*)
- # PR 27666: Do not include sparc_elf32_vec here.
- targ_defvec=sparc_elf32_sol2_vec
- ;;
-#ifdef BFD64
- sparc-*-solaris2* | sparcv9-*-solaris2* | sparc64-*-solaris2*)
- # PR 27666: Do not include sparc_elf32_vec or sparc_elf64_vec here.
- targ_defvec=sparc_elf32_sol2_vec
- targ_selvecs="sparc_elf64_sol2_vec"
- want64=true
- ;;
- sparc64-*-haiku*)
- targ_defvec=sparc_elf64_vec
- targ_selvecs="sparc_elf64_vec sparc_elf32_vec"
- want64=true
- ;;
- sparc64-*-freebsd* | sparc64-*-kfreebsd*-gnu)
- targ_defvec=sparc_elf64_fbsd_vec
- targ_selvecs="sparc_elf64_vec sparc_elf32_vec"
- ;;
- sparc64*-*-*)
- targ_defvec=sparc_elf64_vec
- targ_selvecs="sparc_elf32_vec"
- want64=true
- ;;
-#endif
- sparc-*-linux-* | sparcv*-*-linux-*)
- targ_defvec=sparc_elf32_vec
- targ_selvecs="sparc_elf64_vec"
- ;;
- sparc-*-vxworks*)
- targ_defvec=sparc_elf32_vxworks_vec
- targ_selvecs="sparc_elf32_vec"
- ;;
- sparc*-*-*)
- targ_defvec=sparc_elf32_vec
- ;;
-
- spu-*-elf)
- targ_defvec=spu_elf32_vec
- want64=true
- ;;
-
- tic6x-*-elf)
- targ_defvec=tic6x_elf32_c6000_le_vec
- targ_selvecs="tic6x_elf32_c6000_be_vec tic6x_elf32_le_vec tic6x_elf32_be_vec"
- ;;
-
- tic6x-*-uclinux)
- targ_defvec=tic6x_elf32_linux_le_vec
- targ_selvecs="tic6x_elf32_linux_be_vec tic6x_elf32_le_vec tic6x_elf32_be_vec"
- ;;
-
-#ifdef BFD64
- tilegx-*-*)
- targ_defvec=tilegx_elf64_le_vec
- targ_selvecs="tilegx_elf64_be_vec tilegx_elf32_be_vec tilegx_elf32_le_vec"
- ;;
- tilegxbe-*-*)
- targ_defvec=tilegx_elf64_be_vec
- targ_selvecs="tilegx_elf64_le_vec tilegx_elf32_be_vec tilegx_elf32_le_vec"
- ;;
-#endif
-
- tilepro-*-*)
- targ_defvec=tilepro_elf32_vec
- ;;
-
- ft32*-*-*)
- targ_defvec=ft32_elf32_vec
- ;;
-
- v850*-*-*)
- targ_defvec=v850_elf32_vec
- targ_selvecs="v800_elf32_vec"
- targ_underscore=yes
- ;;
-
- vax-*-netbsdaout*)
- targ_defvec=vax_aout_nbsd_vec
- targ_selvecs="vax_elf32_vec vax_aout_1knbsd_vec"
- targ_underscore=yes
- ;;
-
- vax-*-netbsd*)
- targ_defvec=vax_elf32_vec
- targ_selvecs="vax_aout_nbsd_vec vax_aout_1knbsd_vec"
- ;;
-
- vax-*-openbsd*)
- targ_defvec=vax_aout_nbsd_vec
- targ_underscore=yes
- ;;
-
- vax-*-linux-*)
- targ_defvec=vax_elf32_vec
- ;;
-
- visium-*-elf)
- targ_defvec=visium_elf32_vec
- ;;
-
- wasm32-*-*)
- targ_defvec=wasm32_elf32_vec
- targ_selvecs="wasm_vec"
- ;;
-
- xgate-*-*)
- targ_defvec=xgate_elf32_vec
- targ_selvecs="xgate_elf32_vec"
- ;;
-
- xstormy16-*-elf)
- targ_defvec=xstormy16_elf32_vec
- ;;
-
- xtensa*-*-*)
- targ_defvec=xtensa_elf32_le_vec
- targ_selvecs=xtensa_elf32_be_vec
- ;;
-
- z80-*-coff)
- targ_defvec=z80_coff_vec
- targ_underscore=no
- ;;
-
- z80-*-elf)
- targ_defvec=z80_elf32_vec
- targ_underscore=no
- ;;
-
- z8k*-*-*)
- targ_defvec=z8k_coff_vec
- targ_underscore=yes
- ;;
-
-#ifdef BFD64
- loongarch32-*)
- targ_defvec=loongarch_elf32_vec
- targ_selvecs="loongarch_elf32_vec"
- want64=true
- ;;
-
- loongarch64-*)
- targ_defvec=loongarch_elf64_vec
- targ_selvecs="loongarch_elf32_vec loongarch_elf64_vec loongarch64_pei_vec"
- want64=true
- ;;
-#endif
-
-# END OF targmatch.h
- bpf-*-*)
- echo "*** Configuration $targ is not fully supported." >&2
- echo "*** Use bpf or bpf-*-none as the target instead." >&2
- exit 1
- ;;
-
- *)
- echo 1>&2 "*** BFD does not support target '${targ}'. Honest."
- echo 1>&2 "*** Look in bfd/config.bfd for supported targets."
- exit 1
- ;;
-esac
-
-# All MIPS ELF targets need a 64-bit bfd_vma.
-case "${targ_defvec} ${targ_selvecs}" in
- *mips_elf*)
- want64=true
- ;;
-esac
-
-case "${host64}${want64}" in
- *true*)
- targ_selvecs="${targ_selvecs} ${targ64_selvecs}"
- ;;
-esac
-
-# If we support any ELF target, then automatically add support for the
-# generic ELF targets. This permits an objdump with some ELF support
-# to be used on an arbitrary ELF file for anything other than
-# relocation information.
-case "${targ_defvec} ${targ_selvecs}" in
- *elf64* | *mips_elf32_n*)
- targ_selvecs="${targ_selvecs} elf64_le_vec elf64_be_vec elf32_le_vec elf32_be_vec"
- ;;
- *elf32*)
- targ_selvecs="${targ_selvecs} elf32_le_vec elf32_be_vec"
- ;;
-esac
-
-# If we support Intel MCU target, then add support for bfd_iamcu_arch.
-case "${targ_defvec} ${targ_selvecs}" in
- *iamcu_elf32*)
- targ_archs="$targ_archs bfd_iamcu_arch"
- ;;
-esac
-
-case "${targ}" in
- mipsisa32r6* | mipsisa64r6* | mips*-img-*)
- targ_cflags="$targ_cflags -DMIPS_DEFAULT_R6=1"
- ;;
-esac
Index: sources/GNU/binutils/create-2.43.1-gold-warn-unsupported-patch/binutils-2.43.1-new/gold/configure
===================================================================
--- sources/GNU/binutils/create-2.43.1-gold-warn-unsupported-patch/binutils-2.43.1-new/gold/configure (revision 75)
+++ sources/GNU/binutils/create-2.43.1-gold-warn-unsupported-patch/binutils-2.43.1-new/gold/configure (nonexistent)
@@ -1,15590 +0,0 @@
-#! /bin/sh
-# Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.69 for gold 0.1.
-#
-#
-# Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc.
-#
-#
-# This configure script is free software; the Free Software Foundation
-# gives unlimited permission to copy, distribute and modify it.
-## -------------------- ##
-## M4sh Initialization. ##
-## -------------------- ##
-
-# Be more Bourne compatible
-DUALCASE=1; export DUALCASE # for MKS sh
-if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
- emulate sh
- NULLCMD=:
- # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
- # is contrary to our usage. Disable this feature.
- alias -g '${1+"$@"}'='"$@"'
- setopt NO_GLOB_SUBST
-else
- case `(set -o) 2>/dev/null` in #(
- *posix*) :
- set -o posix ;; #(
- *) :
- ;;
-esac
-fi
-
-
-as_nl='
-'
-export as_nl
-# Printing a long string crashes Solaris 7 /usr/bin/printf.
-as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
-as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
-as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
-# Prefer a ksh shell builtin over an external printf program on Solaris,
-# but without wasting forks for bash or zsh.
-if test -z "$BASH_VERSION$ZSH_VERSION" \
- && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
- as_echo='print -r --'
- as_echo_n='print -rn --'
-elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
- as_echo='printf %s\n'
- as_echo_n='printf %s'
-else
- if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
- as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
- as_echo_n='/usr/ucb/echo -n'
- else
- as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
- as_echo_n_body='eval
- arg=$1;
- case $arg in #(
- *"$as_nl"*)
- expr "X$arg" : "X\\(.*\\)$as_nl";
- arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
- esac;
- expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
- '
- export as_echo_n_body
- as_echo_n='sh -c $as_echo_n_body as_echo'
- fi
- export as_echo_body
- as_echo='sh -c $as_echo_body as_echo'
-fi
-
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- PATH_SEPARATOR=:
- (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
- (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
- PATH_SEPARATOR=';'
- }
-fi
-
-
-# IFS
-# We need space, tab and new line, in precisely that order. Quoting is
-# there to prevent editors from complaining about space-tab.
-# (If _AS_PATH_WALK were called with IFS unset, it would disable word
-# splitting by setting IFS to empty value.)
-IFS=" "" $as_nl"
-
-# Find who we are. Look in the path if we contain no directory separator.
-as_myself=
-case $0 in #((
- *[\\/]* ) as_myself=$0 ;;
- *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
- done
-IFS=$as_save_IFS
-
- ;;
-esac
-# We did not find ourselves, most probably we were run as `sh COMMAND'
-# in which case we are not to be found in the path.
-if test "x$as_myself" = x; then
- as_myself=$0
-fi
-if test ! -f "$as_myself"; then
- $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
- exit 1
-fi
-
-# Unset variables that we do not need and which cause bugs (e.g. in
-# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
-# suppresses any "Segmentation fault" message there. '((' could
-# trigger a bug in pdksh 5.2.14.
-for as_var in BASH_ENV ENV MAIL MAILPATH
-do eval test x\${$as_var+set} = xset \
- && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
-done
-PS1='$ '
-PS2='> '
-PS4='+ '
-
-# NLS nuisances.
-LC_ALL=C
-export LC_ALL
-LANGUAGE=C
-export LANGUAGE
-
-# CDPATH.
-(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
-
-# Use a proper internal environment variable to ensure we don't fall
- # into an infinite loop, continuously re-executing ourselves.
- if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then
- _as_can_reexec=no; export _as_can_reexec;
- # We cannot yet assume a decent shell, so we have to provide a
-# neutralization value for shells without unset; and this also
-# works around shells that cannot unset nonexistent variables.
-# Preserve -v and -x to the replacement shell.
-BASH_ENV=/dev/null
-ENV=/dev/null
-(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
-case $- in # ((((
- *v*x* | *x*v* ) as_opts=-vx ;;
- *v* ) as_opts=-v ;;
- *x* ) as_opts=-x ;;
- * ) as_opts= ;;
-esac
-exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
-# Admittedly, this is quite paranoid, since all the known shells bail
-# out after a failed `exec'.
-$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
-as_fn_exit 255
- fi
- # We don't want this to propagate to other subprocesses.
- { _as_can_reexec=; unset _as_can_reexec;}
-if test "x$CONFIG_SHELL" = x; then
- as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
- emulate sh
- NULLCMD=:
- # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
- # is contrary to our usage. Disable this feature.
- alias -g '\${1+\"\$@\"}'='\"\$@\"'
- setopt NO_GLOB_SUBST
-else
- case \`(set -o) 2>/dev/null\` in #(
- *posix*) :
- set -o posix ;; #(
- *) :
- ;;
-esac
-fi
-"
- as_required="as_fn_return () { (exit \$1); }
-as_fn_success () { as_fn_return 0; }
-as_fn_failure () { as_fn_return 1; }
-as_fn_ret_success () { return 0; }
-as_fn_ret_failure () { return 1; }
-
-exitcode=0
-as_fn_success || { exitcode=1; echo as_fn_success failed.; }
-as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
-as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
-as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
-if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
-
-else
- exitcode=1; echo positional parameters were not saved.
-fi
-test x\$exitcode = x0 || exit 1
-test -x / || exit 1"
- as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
- as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
- eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
- test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
-test \$(( 1 + 1 )) = 2 || exit 1"
- if (eval "$as_required") 2>/dev/null; then :
- as_have_required=yes
-else
- as_have_required=no
-fi
- if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
-
-else
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-as_found=false
-for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- as_found=:
- case $as_dir in #(
- /*)
- for as_base in sh bash ksh sh5; do
- # Try only shells that exist, to save several forks.
- as_shell=$as_dir/$as_base
- if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
- { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
- CONFIG_SHELL=$as_shell as_have_required=yes
- if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
- break 2
-fi
-fi
- done;;
- esac
- as_found=false
-done
-$as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
- { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
- CONFIG_SHELL=$SHELL as_have_required=yes
-fi; }
-IFS=$as_save_IFS
-
-
- if test "x$CONFIG_SHELL" != x; then :
- export CONFIG_SHELL
- # We cannot yet assume a decent shell, so we have to provide a
-# neutralization value for shells without unset; and this also
-# works around shells that cannot unset nonexistent variables.
-# Preserve -v and -x to the replacement shell.
-BASH_ENV=/dev/null
-ENV=/dev/null
-(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
-case $- in # ((((
- *v*x* | *x*v* ) as_opts=-vx ;;
- *v* ) as_opts=-v ;;
- *x* ) as_opts=-x ;;
- * ) as_opts= ;;
-esac
-exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
-# Admittedly, this is quite paranoid, since all the known shells bail
-# out after a failed `exec'.
-$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
-exit 255
-fi
-
- if test x$as_have_required = xno; then :
- $as_echo "$0: This script requires a shell more modern than all"
- $as_echo "$0: the shells that I found on your system."
- if test x${ZSH_VERSION+set} = xset ; then
- $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
- $as_echo "$0: be upgraded to zsh 4.3.4 or later."
- else
- $as_echo "$0: Please tell bug-autoconf@gnu.org about your system,
-$0: including any error possibly output before this
-$0: message. Then install a modern shell, or manually run
-$0: the script under such a shell if you do have one."
- fi
- exit 1
-fi
-fi
-fi
-SHELL=${CONFIG_SHELL-/bin/sh}
-export SHELL
-# Unset more variables known to interfere with behavior of common tools.
-CLICOLOR_FORCE= GREP_OPTIONS=
-unset CLICOLOR_FORCE GREP_OPTIONS
-
-## --------------------- ##
-## M4sh Shell Functions. ##
-## --------------------- ##
-# as_fn_unset VAR
-# ---------------
-# Portably unset VAR.
-as_fn_unset ()
-{
- { eval $1=; unset $1;}
-}
-as_unset=as_fn_unset
-
-# as_fn_set_status STATUS
-# -----------------------
-# Set $? to STATUS, without forking.
-as_fn_set_status ()
-{
- return $1
-} # as_fn_set_status
-
-# as_fn_exit STATUS
-# -----------------
-# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
-as_fn_exit ()
-{
- set +e
- as_fn_set_status $1
- exit $1
-} # as_fn_exit
-
-# as_fn_mkdir_p
-# -------------
-# Create "$as_dir" as a directory, including parents if necessary.
-as_fn_mkdir_p ()
-{
-
- case $as_dir in #(
- -*) as_dir=./$as_dir;;
- esac
- test -d "$as_dir" || eval $as_mkdir_p || {
- as_dirs=
- while :; do
- case $as_dir in #(
- *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
- *) as_qdir=$as_dir;;
- esac
- as_dirs="'$as_qdir' $as_dirs"
- as_dir=`$as_dirname -- "$as_dir" ||
-$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$as_dir" : 'X\(//\)[^/]' \| \
- X"$as_dir" : 'X\(//\)$' \| \
- X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$as_dir" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
- test -d "$as_dir" && break
- done
- test -z "$as_dirs" || eval "mkdir $as_dirs"
- } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
-
-
-} # as_fn_mkdir_p
-
-# as_fn_executable_p FILE
-# -----------------------
-# Test if FILE is an executable regular file.
-as_fn_executable_p ()
-{
- test -f "$1" && test -x "$1"
-} # as_fn_executable_p
-# as_fn_append VAR VALUE
-# ----------------------
-# Append the text in VALUE to the end of the definition contained in VAR. Take
-# advantage of any shell optimizations that allow amortized linear growth over
-# repeated appends, instead of the typical quadratic growth present in naive
-# implementations.
-if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
- eval 'as_fn_append ()
- {
- eval $1+=\$2
- }'
-else
- as_fn_append ()
- {
- eval $1=\$$1\$2
- }
-fi # as_fn_append
-
-# as_fn_arith ARG...
-# ------------------
-# Perform arithmetic evaluation on the ARGs, and store the result in the
-# global $as_val. Take advantage of shells that can avoid forks. The arguments
-# must be portable across $(()) and expr.
-if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
- eval 'as_fn_arith ()
- {
- as_val=$(( $* ))
- }'
-else
- as_fn_arith ()
- {
- as_val=`expr "$@" || test $? -eq 1`
- }
-fi # as_fn_arith
-
-
-# as_fn_error STATUS ERROR [LINENO LOG_FD]
-# ----------------------------------------
-# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
-# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
-# script with STATUS, using 1 if that was 0.
-as_fn_error ()
-{
- as_status=$1; test $as_status -eq 0 && as_status=1
- if test "$4"; then
- as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
- fi
- $as_echo "$as_me: error: $2" >&2
- as_fn_exit $as_status
-} # as_fn_error
-
-if expr a : '\(a\)' >/dev/null 2>&1 &&
- test "X`expr 00001 : '.*\(...\)'`" = X001; then
- as_expr=expr
-else
- as_expr=false
-fi
-
-if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
- as_basename=basename
-else
- as_basename=false
-fi
-
-if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
- as_dirname=dirname
-else
- as_dirname=false
-fi
-
-as_me=`$as_basename -- "$0" ||
-$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
- X"$0" : 'X\(//\)$' \| \
- X"$0" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X/"$0" |
- sed '/^.*\/\([^/][^/]*\)\/*$/{
- s//\1/
- q
- }
- /^X\/\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\/\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
-
-# Avoid depending upon Character Ranges.
-as_cr_letters='abcdefghijklmnopqrstuvwxyz'
-as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
-as_cr_Letters=$as_cr_letters$as_cr_LETTERS
-as_cr_digits='0123456789'
-as_cr_alnum=$as_cr_Letters$as_cr_digits
-
-
- as_lineno_1=$LINENO as_lineno_1a=$LINENO
- as_lineno_2=$LINENO as_lineno_2a=$LINENO
- eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
- test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
- # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-)
- sed -n '
- p
- /[$]LINENO/=
- ' <$as_myself |
- sed '
- s/[$]LINENO.*/&-/
- t lineno
- b
- :lineno
- N
- :loop
- s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
- t loop
- s/-\n.*//
- ' >$as_me.lineno &&
- chmod +x "$as_me.lineno" ||
- { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
-
- # If we had to re-execute with $CONFIG_SHELL, we're ensured to have
- # already done that, so ensure we don't try to do so again and fall
- # in an infinite loop. This has already happened in practice.
- _as_can_reexec=no; export _as_can_reexec
- # Don't try to exec as it changes $[0], causing all sort of problems
- # (the dirname of $[0] is not the place where we might find the
- # original and so on. Autoconf is especially sensitive to this).
- . "./$as_me.lineno"
- # Exit status is that of the last command.
- exit
-}
-
-ECHO_C= ECHO_N= ECHO_T=
-case `echo -n x` in #(((((
--n*)
- case `echo 'xy\c'` in
- *c*) ECHO_T=' ';; # ECHO_T is single tab character.
- xy) ECHO_C='\c';;
- *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
- ECHO_T=' ';;
- esac;;
-*)
- ECHO_N='-n';;
-esac
-
-rm -f conf$$ conf$$.exe conf$$.file
-if test -d conf$$.dir; then
- rm -f conf$$.dir/conf$$.file
-else
- rm -f conf$$.dir
- mkdir conf$$.dir 2>/dev/null
-fi
-if (echo >conf$$.file) 2>/dev/null; then
- if ln -s conf$$.file conf$$ 2>/dev/null; then
- as_ln_s='ln -s'
- # ... but there are two gotchas:
- # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
- # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
- # In both cases, we have to default to `cp -pR'.
- ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
- as_ln_s='cp -pR'
- elif ln conf$$.file conf$$ 2>/dev/null; then
- as_ln_s=ln
- else
- as_ln_s='cp -pR'
- fi
-else
- as_ln_s='cp -pR'
-fi
-rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
-rmdir conf$$.dir 2>/dev/null
-
-if mkdir -p . 2>/dev/null; then
- as_mkdir_p='mkdir -p "$as_dir"'
-else
- test -d ./-p && rmdir ./-p
- as_mkdir_p=false
-fi
-
-as_test_x='test -x'
-as_executable_p=as_fn_executable_p
-
-# Sed expression to map a string onto a valid CPP name.
-as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
-
-# Sed expression to map a string onto a valid variable name.
-as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
-
-
-test -n "$DJDIR" || exec 7<&0 </dev/null
-exec 6>&1
-
-# Name of the host.
-# hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status,
-# so uname gets run too.
-ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
-
-#
-# Initializations.
-#
-ac_default_prefix=/usr/local
-ac_clean_files=
-ac_config_libobj_dir=.
-LIBOBJS=
-cross_compiling=no
-subdirs=
-MFLAGS=
-MAKEFLAGS=
-
-# Identity of this package.
-PACKAGE_NAME='gold'
-PACKAGE_TARNAME='gold'
-PACKAGE_VERSION='0.1'
-PACKAGE_STRING='gold 0.1'
-PACKAGE_BUGREPORT=''
-PACKAGE_URL=''
-
-ac_unique_file="gold.cc"
-# Factoring default headers for most tests.
-ac_includes_default="\
-#include <stdio.h>
-#ifdef HAVE_SYS_TYPES_H
-# include <sys/types.h>
-#endif
-#ifdef HAVE_SYS_STAT_H
-# include <sys/stat.h>
-#endif
-#ifdef STDC_HEADERS
-# include <stdlib.h>
-# include <stddef.h>
-#else
-# ifdef HAVE_STDLIB_H
-# include <stdlib.h>
-# endif
-#endif
-#ifdef HAVE_STRING_H
-# if !defined STDC_HEADERS && defined HAVE_MEMORY_H
-# include <memory.h>
-# endif
-# include <string.h>
-#endif
-#ifdef HAVE_STRINGS_H
-# include <strings.h>
-#endif
-#ifdef HAVE_INTTYPES_H
-# include <inttypes.h>
-#endif
-#ifdef HAVE_STDINT_H
-# include <stdint.h>
-#endif
-#ifdef HAVE_UNISTD_H
-# include <unistd.h>
-#endif"
-
-gt_needs=
-ac_subst_vars='am__EXEEXT_FALSE
-am__EXEEXT_TRUE
-LTLIBOBJS
-MAINT
-MAINTAINER_MODE_FALSE
-MAINTAINER_MODE_TRUE
-HAVE_CXX11
-DLOPEN_LIBS
-CXXCPP
-HAVE_NO_USE_LINKER_PLUGIN_FALSE
-HAVE_NO_USE_LINKER_PLUGIN_TRUE
-HAVE_PUBNAMES_FALSE
-HAVE_PUBNAMES_TRUE
-JANSSON_LIBS
-JANSSON_CFLAGS
-THREADS_FALSE
-THREADS_TRUE
-PTHREAD_CFLAGS
-PTHREAD_LIBS
-PTHREAD_CC
-ax_pthread_config
-SED
-HAVE_ZSTD_FALSE
-HAVE_ZSTD_TRUE
-ZSTD_LIBS
-ZSTD_CFLAGS
-PKG_CONFIG_LIBDIR
-PKG_CONFIG_PATH
-PKG_CONFIG
-zlibinc
-zlibdir
-LIBOBJS
-LFS_CFLAGS
-GOLD_LDADD
-GOLD_LDFLAGS
-WARN_CXXFLAGS
-WARN_WRITE_STRINGS
-NO_WERROR
-WARN_CFLAGS_FOR_BUILD
-WARN_CFLAGS
-IFUNC_STATIC_FALSE
-IFUNC_STATIC_TRUE
-IFUNC_FALSE
-IFUNC_TRUE
-RANDOM_SEED_CFLAGS
-TLS_DESCRIPTORS_FALSE
-TLS_DESCRIPTORS_TRUE
-TLS_GNU2_DIALECT_FALSE
-TLS_GNU2_DIALECT_TRUE
-OMP_SUPPORT_FALSE
-OMP_SUPPORT_TRUE
-STATIC_TLS_FALSE
-STATIC_TLS_TRUE
-TLS_FALSE
-TLS_TRUE
-MERGE_CONSTANTS_FLAG
-CFLAGS_CF_PROTECTION_FALSE
-CFLAGS_CF_PROTECTION_TRUE
-GCC9_FALSE
-GCC9_TRUE
-MCMODEL_MEDIUM_FALSE
-MCMODEL_MEDIUM_TRUE
-FN_PTRS_IN_SO_WITHOUT_PIC_FALSE
-FN_PTRS_IN_SO_WITHOUT_PIC_TRUE
-HAVE_STATIC_FALSE
-HAVE_STATIC_TRUE
-NATIVE_OR_CROSS_LINKER_FALSE
-NATIVE_OR_CROSS_LINKER_TRUE
-GCC_FALSE
-GCC_TRUE
-NATIVE_LINKER_FALSE
-NATIVE_LINKER_TRUE
-CATOBJEXT
-GENCAT
-INSTOBJEXT
-DATADIRNAME
-CATALOGS
-INCINTL
-LIBINTL_DEP
-POSUB
-LTLIBINTL
-LIBINTL
-INTLLIBS
-LTLIBICONV
-LIBICONV
-INTL_MACOSX_LIBS
-MSGMERGE
-XGETTEXT
-GMSGFMT
-MSGFMT
-USE_NLS
-MKINSTALLDIRS
-LN_S
-RANLIB
-YFLAGS
-YACC
-am__fastdepCXX_FALSE
-am__fastdepCXX_TRUE
-CXXDEPMODE
-ac_ct_CXX
-CXXFLAGS
-CXX
-NM
-TARGETOBJS
-DEFAULT_TARGET
-DEFAULT_TARGET_MIPS_FALSE
-DEFAULT_TARGET_MIPS_TRUE
-DEFAULT_TARGET_TILEGX_FALSE
-DEFAULT_TARGET_TILEGX_TRUE
-DEFAULT_TARGET_X86_64_OR_X32_FALSE
-DEFAULT_TARGET_X86_64_OR_X32_TRUE
-DEFAULT_TARGET_X32_FALSE
-DEFAULT_TARGET_X32_TRUE
-DEFAULT_TARGET_X86_64_FALSE
-DEFAULT_TARGET_X86_64_TRUE
-DEFAULT_TARGET_S390_FALSE
-DEFAULT_TARGET_S390_TRUE
-DEFAULT_TARGET_SPARC_FALSE
-DEFAULT_TARGET_SPARC_TRUE
-DEFAULT_TARGET_POWERPC_FALSE
-DEFAULT_TARGET_POWERPC_TRUE
-DEFAULT_TARGET_I386_FALSE
-DEFAULT_TARGET_I386_TRUE
-DEFAULT_TARGET_ARM_FALSE
-DEFAULT_TARGET_ARM_TRUE
-DEFAULT_TARGET_AARCH64_FALSE
-DEFAULT_TARGET_AARCH64_TRUE
-PLUGINS_FALSE
-PLUGINS_TRUE
-installed_linker
-install_as_default
-EGREP
-GREP
-CPP
-am__fastdepCC_FALSE
-am__fastdepCC_TRUE
-CCDEPMODE
-am__nodep
-AMDEPBACKSLASH
-AMDEP_FALSE
-AMDEP_TRUE
-am__quote
-am__include
-DEPDIR
-OBJEXT
-EXEEXT
-ac_ct_CC
-CPPFLAGS
-LDFLAGS
-CFLAGS
-CC
-AM_BACKSLASH
-AM_DEFAULT_VERBOSITY
-AM_DEFAULT_V
-AM_V
-am__untar
-am__tar
-AMTAR
-am__leading_dot
-SET_MAKE
-AWK
-mkdir_p
-MKDIR_P
-INSTALL_STRIP_PROGRAM
-STRIP
-install_sh
-MAKEINFO
-AUTOHEADER
-AUTOMAKE
-AUTOCONF
-ACLOCAL
-VERSION
-PACKAGE
-CYGPATH_W
-am__isrc
-INSTALL_DATA
-INSTALL_SCRIPT
-INSTALL_PROGRAM
-target_os
-target_vendor
-target_cpu
-target
-host_os
-host_vendor
-host_cpu
-host
-build_os
-build_vendor
-build_cpu
-build
-target_alias
-host_alias
-build_alias
-LIBS
-ECHO_T
-ECHO_N
-ECHO_C
-DEFS
-mandir
-localedir
-libdir
-psdir
-pdfdir
-dvidir
-htmldir
-infodir
-docdir
-oldincludedir
-includedir
-localstatedir
-sharedstatedir
-sysconfdir
-datadir
-datarootdir
-libexecdir
-sbindir
-bindir
-program_transform_name
-prefix
-exec_prefix
-PACKAGE_URL
-PACKAGE_BUGREPORT
-PACKAGE_STRING
-PACKAGE_VERSION
-PACKAGE_TARNAME
-PACKAGE_NAME
-PATH_SEPARATOR
-SHELL'
-ac_subst_files=''
-ac_user_opts='
-enable_option_checking
-enable_silent_rules
-enable_dependency_tracking
-with_sysroot
-enable_gold
-enable_plugins
-enable_relro
-enable_targets
-enable_default_hash_style
-with_lib_path
-enable_nls
-with_gnu_ld
-enable_rpath
-with_libiconv_prefix
-with_libiconv_type
-with_libintl_prefix
-with_libintl_type
-enable_werror
-enable_build_warnings
-with_gold_ldflags
-with_gold_ldadd
-with_system_zlib
-with_zstd
-enable_threads
-enable_jansson
-enable_maintainer_mode
-'
- ac_precious_vars='build_alias
-host_alias
-target_alias
-CC
-CFLAGS
-LDFLAGS
-LIBS
-CPPFLAGS
-CPP
-CXX
-CXXFLAGS
-CCC
-YACC
-YFLAGS
-PKG_CONFIG
-PKG_CONFIG_PATH
-PKG_CONFIG_LIBDIR
-ZSTD_CFLAGS
-ZSTD_LIBS
-JANSSON_CFLAGS
-JANSSON_LIBS
-CXXCPP'
-
-
-# Initialize some variables set by options.
-ac_init_help=
-ac_init_version=false
-ac_unrecognized_opts=
-ac_unrecognized_sep=
-# The variables have the same names as the options, with
-# dashes changed to underlines.
-cache_file=/dev/null
-exec_prefix=NONE
-no_create=
-no_recursion=
-prefix=NONE
-program_prefix=NONE
-program_suffix=NONE
-program_transform_name=s,x,x,
-silent=
-site=
-srcdir=
-verbose=
-x_includes=NONE
-x_libraries=NONE
-
-# Installation directory options.
-# These are left unexpanded so users can "make install exec_prefix=/foo"
-# and all the variables that are supposed to be based on exec_prefix
-# by default will actually change.
-# Use braces instead of parens because sh, perl, etc. also accept them.
-# (The list follows the same order as the GNU Coding Standards.)
-bindir='${exec_prefix}/bin'
-sbindir='${exec_prefix}/sbin'
-libexecdir='${exec_prefix}/libexec'
-datarootdir='${prefix}/share'
-datadir='${datarootdir}'
-sysconfdir='${prefix}/etc'
-sharedstatedir='${prefix}/com'
-localstatedir='${prefix}/var'
-includedir='${prefix}/include'
-oldincludedir='/usr/include'
-docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
-infodir='${datarootdir}/info'
-htmldir='${docdir}'
-dvidir='${docdir}'
-pdfdir='${docdir}'
-psdir='${docdir}'
-libdir='${exec_prefix}/lib'
-localedir='${datarootdir}/locale'
-mandir='${datarootdir}/man'
-
-ac_prev=
-ac_dashdash=
-for ac_option
-do
- # If the previous option needs an argument, assign it.
- if test -n "$ac_prev"; then
- eval $ac_prev=\$ac_option
- ac_prev=
- continue
- fi
-
- case $ac_option in
- *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
- *=) ac_optarg= ;;
- *) ac_optarg=yes ;;
- esac
-
- # Accept the important Cygnus configure options, so we can diagnose typos.
-
- case $ac_dashdash$ac_option in
- --)
- ac_dashdash=yes ;;
-
- -bindir | --bindir | --bindi | --bind | --bin | --bi)
- ac_prev=bindir ;;
- -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
- bindir=$ac_optarg ;;
-
- -build | --build | --buil | --bui | --bu)
- ac_prev=build_alias ;;
- -build=* | --build=* | --buil=* | --bui=* | --bu=*)
- build_alias=$ac_optarg ;;
-
- -cache-file | --cache-file | --cache-fil | --cache-fi \
- | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
- ac_prev=cache_file ;;
- -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
- | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
- cache_file=$ac_optarg ;;
-
- --config-cache | -C)
- cache_file=config.cache ;;
-
- -datadir | --datadir | --datadi | --datad)
- ac_prev=datadir ;;
- -datadir=* | --datadir=* | --datadi=* | --datad=*)
- datadir=$ac_optarg ;;
-
- -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
- | --dataroo | --dataro | --datar)
- ac_prev=datarootdir ;;
- -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
- | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
- datarootdir=$ac_optarg ;;
-
- -disable-* | --disable-*)
- ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
- # Reject names that are not valid shell variable names.
- expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
- as_fn_error $? "invalid feature name: $ac_useropt"
- ac_useropt_orig=$ac_useropt
- ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
- case $ac_user_opts in
- *"
-"enable_$ac_useropt"
-"*) ;;
- *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
- ac_unrecognized_sep=', ';;
- esac
- eval enable_$ac_useropt=no ;;
-
- -docdir | --docdir | --docdi | --doc | --do)
- ac_prev=docdir ;;
- -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
- docdir=$ac_optarg ;;
-
- -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
- ac_prev=dvidir ;;
- -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
- dvidir=$ac_optarg ;;
-
- -enable-* | --enable-*)
- ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
- # Reject names that are not valid shell variable names.
- expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
- as_fn_error $? "invalid feature name: $ac_useropt"
- ac_useropt_orig=$ac_useropt
- ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
- case $ac_user_opts in
- *"
-"enable_$ac_useropt"
-"*) ;;
- *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
- ac_unrecognized_sep=', ';;
- esac
- eval enable_$ac_useropt=\$ac_optarg ;;
-
- -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
- | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
- | --exec | --exe | --ex)
- ac_prev=exec_prefix ;;
- -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
- | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
- | --exec=* | --exe=* | --ex=*)
- exec_prefix=$ac_optarg ;;
-
- -gas | --gas | --ga | --g)
- # Obsolete; use --with-gas.
- with_gas=yes ;;
-
- -help | --help | --hel | --he | -h)
- ac_init_help=long ;;
- -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
- ac_init_help=recursive ;;
- -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
- ac_init_help=short ;;
-
- -host | --host | --hos | --ho)
- ac_prev=host_alias ;;
- -host=* | --host=* | --hos=* | --ho=*)
- host_alias=$ac_optarg ;;
-
- -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
- ac_prev=htmldir ;;
- -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
- | --ht=*)
- htmldir=$ac_optarg ;;
-
- -includedir | --includedir | --includedi | --included | --include \
- | --includ | --inclu | --incl | --inc)
- ac_prev=includedir ;;
- -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
- | --includ=* | --inclu=* | --incl=* | --inc=*)
- includedir=$ac_optarg ;;
-
- -infodir | --infodir | --infodi | --infod | --info | --inf)
- ac_prev=infodir ;;
- -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
- infodir=$ac_optarg ;;
-
- -libdir | --libdir | --libdi | --libd)
- ac_prev=libdir ;;
- -libdir=* | --libdir=* | --libdi=* | --libd=*)
- libdir=$ac_optarg ;;
-
- -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
- | --libexe | --libex | --libe)
- ac_prev=libexecdir ;;
- -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
- | --libexe=* | --libex=* | --libe=*)
- libexecdir=$ac_optarg ;;
-
- -localedir | --localedir | --localedi | --localed | --locale)
- ac_prev=localedir ;;
- -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
- localedir=$ac_optarg ;;
-
- -localstatedir | --localstatedir | --localstatedi | --localstated \
- | --localstate | --localstat | --localsta | --localst | --locals)
- ac_prev=localstatedir ;;
- -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
- | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
- localstatedir=$ac_optarg ;;
-
- -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
- ac_prev=mandir ;;
- -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
- mandir=$ac_optarg ;;
-
- -nfp | --nfp | --nf)
- # Obsolete; use --without-fp.
- with_fp=no ;;
-
- -no-create | --no-create | --no-creat | --no-crea | --no-cre \
- | --no-cr | --no-c | -n)
- no_create=yes ;;
-
- -no-recursion | --no-recursion | --no-recursio | --no-recursi \
- | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
- no_recursion=yes ;;
-
- -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
- | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
- | --oldin | --oldi | --old | --ol | --o)
- ac_prev=oldincludedir ;;
- -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
- | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
- | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
- oldincludedir=$ac_optarg ;;
-
- -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
- ac_prev=prefix ;;
- -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
- prefix=$ac_optarg ;;
-
- -program-prefix | --program-prefix | --program-prefi | --program-pref \
- | --program-pre | --program-pr | --program-p)
- ac_prev=program_prefix ;;
- -program-prefix=* | --program-prefix=* | --program-prefi=* \
- | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
- program_prefix=$ac_optarg ;;
-
- -program-suffix | --program-suffix | --program-suffi | --program-suff \
- | --program-suf | --program-su | --program-s)
- ac_prev=program_suffix ;;
- -program-suffix=* | --program-suffix=* | --program-suffi=* \
- | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
- program_suffix=$ac_optarg ;;
-
- -program-transform-name | --program-transform-name \
- | --program-transform-nam | --program-transform-na \
- | --program-transform-n | --program-transform- \
- | --program-transform | --program-transfor \
- | --program-transfo | --program-transf \
- | --program-trans | --program-tran \
- | --progr-tra | --program-tr | --program-t)
- ac_prev=program_transform_name ;;
- -program-transform-name=* | --program-transform-name=* \
- | --program-transform-nam=* | --program-transform-na=* \
- | --program-transform-n=* | --program-transform-=* \
- | --program-transform=* | --program-transfor=* \
- | --program-transfo=* | --program-transf=* \
- | --program-trans=* | --program-tran=* \
- | --progr-tra=* | --program-tr=* | --program-t=*)
- program_transform_name=$ac_optarg ;;
-
- -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
- ac_prev=pdfdir ;;
- -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
- pdfdir=$ac_optarg ;;
-
- -psdir | --psdir | --psdi | --psd | --ps)
- ac_prev=psdir ;;
- -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
- psdir=$ac_optarg ;;
-
- -q | -quiet | --quiet | --quie | --qui | --qu | --q \
- | -silent | --silent | --silen | --sile | --sil)
- silent=yes ;;
-
- -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
- ac_prev=sbindir ;;
- -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
- | --sbi=* | --sb=*)
- sbindir=$ac_optarg ;;
-
- -sharedstatedir | --sharedstatedir | --sharedstatedi \
- | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
- | --sharedst | --shareds | --shared | --share | --shar \
- | --sha | --sh)
- ac_prev=sharedstatedir ;;
- -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
- | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
- | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
- | --sha=* | --sh=*)
- sharedstatedir=$ac_optarg ;;
-
- -site | --site | --sit)
- ac_prev=site ;;
- -site=* | --site=* | --sit=*)
- site=$ac_optarg ;;
-
- -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
- ac_prev=srcdir ;;
- -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
- srcdir=$ac_optarg ;;
-
- -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
- | --syscon | --sysco | --sysc | --sys | --sy)
- ac_prev=sysconfdir ;;
- -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
- | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
- sysconfdir=$ac_optarg ;;
-
- -target | --target | --targe | --targ | --tar | --ta | --t)
- ac_prev=target_alias ;;
- -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
- target_alias=$ac_optarg ;;
-
- -v | -verbose | --verbose | --verbos | --verbo | --verb)
- verbose=yes ;;
-
- -version | --version | --versio | --versi | --vers | -V)
- ac_init_version=: ;;
-
- -with-* | --with-*)
- ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
- # Reject names that are not valid shell variable names.
- expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
- as_fn_error $? "invalid package name: $ac_useropt"
- ac_useropt_orig=$ac_useropt
- ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
- case $ac_user_opts in
- *"
-"with_$ac_useropt"
-"*) ;;
- *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
- ac_unrecognized_sep=', ';;
- esac
- eval with_$ac_useropt=\$ac_optarg ;;
-
- -without-* | --without-*)
- ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
- # Reject names that are not valid shell variable names.
- expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
- as_fn_error $? "invalid package name: $ac_useropt"
- ac_useropt_orig=$ac_useropt
- ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
- case $ac_user_opts in
- *"
-"with_$ac_useropt"
-"*) ;;
- *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
- ac_unrecognized_sep=', ';;
- esac
- eval with_$ac_useropt=no ;;
-
- --x)
- # Obsolete; use --with-x.
- with_x=yes ;;
-
- -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
- | --x-incl | --x-inc | --x-in | --x-i)
- ac_prev=x_includes ;;
- -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
- | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
- x_includes=$ac_optarg ;;
-
- -x-libraries | --x-libraries | --x-librarie | --x-librari \
- | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
- ac_prev=x_libraries ;;
- -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
- | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
- x_libraries=$ac_optarg ;;
-
- -*) as_fn_error $? "unrecognized option: \`$ac_option'
-Try \`$0 --help' for more information"
- ;;
-
- *=*)
- ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
- # Reject names that are not valid shell variable names.
- case $ac_envvar in #(
- '' | [0-9]* | *[!_$as_cr_alnum]* )
- as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
- esac
- eval $ac_envvar=\$ac_optarg
- export $ac_envvar ;;
-
- *)
- # FIXME: should be removed in autoconf 3.0.
- $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
- expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
- $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
- : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
- ;;
-
- esac
-done
-
-if test -n "$ac_prev"; then
- ac_option=--`echo $ac_prev | sed 's/_/-/g'`
- as_fn_error $? "missing argument to $ac_option"
-fi
-
-if test -n "$ac_unrecognized_opts"; then
- case $enable_option_checking in
- no) ;;
- fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
- *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
- esac
-fi
-
-# Check all directory arguments for consistency.
-for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
- datadir sysconfdir sharedstatedir localstatedir includedir \
- oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
- libdir localedir mandir
-do
- eval ac_val=\$$ac_var
- # Remove trailing slashes.
- case $ac_val in
- */ )
- ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
- eval $ac_var=\$ac_val;;
- esac
- # Be sure to have absolute directory names.
- case $ac_val in
- [\\/$]* | ?:[\\/]* ) continue;;
- NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
- esac
- as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
-done
-
-# There might be people who depend on the old broken behavior: `$host'
-# used to hold the argument of --host etc.
-# FIXME: To remove some day.
-build=$build_alias
-host=$host_alias
-target=$target_alias
-
-# FIXME: To remove some day.
-if test "x$host_alias" != x; then
- if test "x$build_alias" = x; then
- cross_compiling=maybe
- elif test "x$build_alias" != "x$host_alias"; then
- cross_compiling=yes
- fi
-fi
-
-ac_tool_prefix=
-test -n "$host_alias" && ac_tool_prefix=$host_alias-
-
-test "$silent" = yes && exec 6>/dev/null
-
-
-ac_pwd=`pwd` && test -n "$ac_pwd" &&
-ac_ls_di=`ls -di .` &&
-ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
- as_fn_error $? "working directory cannot be determined"
-test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
- as_fn_error $? "pwd does not report name of working directory"
-
-
-# Find the source files, if location was not specified.
-if test -z "$srcdir"; then
- ac_srcdir_defaulted=yes
- # Try the directory containing this script, then the parent directory.
- ac_confdir=`$as_dirname -- "$as_myself" ||
-$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$as_myself" : 'X\(//\)[^/]' \| \
- X"$as_myself" : 'X\(//\)$' \| \
- X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$as_myself" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
- srcdir=$ac_confdir
- if test ! -r "$srcdir/$ac_unique_file"; then
- srcdir=..
- fi
-else
- ac_srcdir_defaulted=no
-fi
-if test ! -r "$srcdir/$ac_unique_file"; then
- test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
- as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
-fi
-ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
-ac_abs_confdir=`(
- cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
- pwd)`
-# When building in place, set srcdir=.
-if test "$ac_abs_confdir" = "$ac_pwd"; then
- srcdir=.
-fi
-# Remove unnecessary trailing slashes from srcdir.
-# Double slashes in file names in object file debugging info
-# mess up M-x gdb in Emacs.
-case $srcdir in
-*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
-esac
-for ac_var in $ac_precious_vars; do
- eval ac_env_${ac_var}_set=\${${ac_var}+set}
- eval ac_env_${ac_var}_value=\$${ac_var}
- eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
- eval ac_cv_env_${ac_var}_value=\$${ac_var}
-done
-
-#
-# Report the --help message.
-#
-if test "$ac_init_help" = "long"; then
- # Omit some internal or obsolete options to make the list less imposing.
- # This message is too long to be a string in the A/UX 3.1 sh.
- cat <<_ACEOF
-\`configure' configures gold 0.1 to adapt to many kinds of systems.
-
-Usage: $0 [OPTION]... [VAR=VALUE]...
-
-To assign environment variables (e.g., CC, CFLAGS...), specify them as
-VAR=VALUE. See below for descriptions of some of the useful variables.
-
-Defaults for the options are specified in brackets.
-
-Configuration:
- -h, --help display this help and exit
- --help=short display options specific to this package
- --help=recursive display the short help of all the included packages
- -V, --version display version information and exit
- -q, --quiet, --silent do not print \`checking ...' messages
- --cache-file=FILE cache test results in FILE [disabled]
- -C, --config-cache alias for \`--cache-file=config.cache'
- -n, --no-create do not create output files
- --srcdir=DIR find the sources in DIR [configure dir or \`..']
-
-Installation directories:
- --prefix=PREFIX install architecture-independent files in PREFIX
- [$ac_default_prefix]
- --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
- [PREFIX]
-
-By default, \`make install' will install all the files in
-\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
-an installation prefix other than \`$ac_default_prefix' using \`--prefix',
-for instance \`--prefix=\$HOME'.
-
-For better control, use the options below.
-
-Fine tuning of the installation directories:
- --bindir=DIR user executables [EPREFIX/bin]
- --sbindir=DIR system admin executables [EPREFIX/sbin]
- --libexecdir=DIR program executables [EPREFIX/libexec]
- --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
- --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
- --localstatedir=DIR modifiable single-machine data [PREFIX/var]
- --libdir=DIR object code libraries [EPREFIX/lib]
- --includedir=DIR C header files [PREFIX/include]
- --oldincludedir=DIR C header files for non-gcc [/usr/include]
- --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
- --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
- --infodir=DIR info documentation [DATAROOTDIR/info]
- --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
- --mandir=DIR man documentation [DATAROOTDIR/man]
- --docdir=DIR documentation root [DATAROOTDIR/doc/gold]
- --htmldir=DIR html documentation [DOCDIR]
- --dvidir=DIR dvi documentation [DOCDIR]
- --pdfdir=DIR pdf documentation [DOCDIR]
- --psdir=DIR ps documentation [DOCDIR]
-_ACEOF
-
- cat <<\_ACEOF
-
-Program names:
- --program-prefix=PREFIX prepend PREFIX to installed program names
- --program-suffix=SUFFIX append SUFFIX to installed program names
- --program-transform-name=PROGRAM run sed PROGRAM on installed program names
-
-System types:
- --build=BUILD configure for building on BUILD [guessed]
- --host=HOST cross-compile to build programs to run on HOST [BUILD]
- --target=TARGET configure for building compilers for TARGET [HOST]
-_ACEOF
-fi
-
-if test -n "$ac_init_help"; then
- case $ac_init_help in
- short | recursive ) echo "Configuration of gold 0.1:";;
- esac
- cat <<\_ACEOF
-
-Optional Features:
- --disable-option-checking ignore unrecognized --enable/--with options
- --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
- --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
- --enable-silent-rules less verbose build output (undo: "make V=1")
- --disable-silent-rules verbose build output (undo: "make V=0")
- --enable-dependency-tracking
- do not reject slow dependency extractors
- --disable-dependency-tracking
- speeds up one-time build
- --enable-gold[=ARG] build gold [ARG={default,yes,no}]
- --enable-plugins Enable support for plugins
- --enable-relro enable -z relro in ELF linker by default
- --enable-targets alternative target configurations
- --enable-default-hash-style={sysv,gnu,both}
- use this default hash style
- --disable-nls do not use Native Language Support
- --disable-rpath do not hardcode runtime library paths
- --enable-werror treat compile warnings as errors
- --enable-build-warnings enable build-time compiler warnings
- --enable-threads[=ARG] multi-threaded linking [ARG={auto,yes,no}]
- --enable-jansson enable jansson [default=no]
- --enable-maintainer-mode
- enable make rules and dependencies not useful (and
- sometimes confusing) to the casual installer
-
-Optional Packages:
- --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
- --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
- --with-sysroot=DIR search for usr/lib et al within DIR
- --with-lib-path=dir1:dir2... set default LIB_PATH
- --with-gnu-ld assume the C compiler uses GNU ld default=no
- --with-libiconv-prefix[=DIR] search for libiconv in DIR/include and DIR/lib
- --without-libiconv-prefix don't search for libiconv in includedir and libdir
- --with-libiconv-type=TYPE type of library to search for (auto/static/shared)
- --with-libintl-prefix[=DIR] search for libintl in DIR/include and DIR/lib
- --without-libintl-prefix don't search for libintl in includedir and libdir
- --with-libintl-type=TYPE type of library to search for (auto/static/shared)
- --with-gold-ldflags=FLAGS additional link flags for gold
- --with-gold-ldadd=LIBS additional libraries for gold
- --with-system-zlib use installed libz
- --with-zstd support zstd compressed debug sections
- (default=auto)
-
-Some influential environment variables:
- CC C compiler command
- CFLAGS C compiler flags
- LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
- nonstandard directory <lib dir>
- LIBS libraries to pass to the linker, e.g. -l<library>
- CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
- you have headers in a nonstandard directory <include dir>
- CPP C preprocessor
- CXX C++ compiler command
- CXXFLAGS C++ compiler flags
- YACC The `Yet Another Compiler Compiler' implementation to use.
- Defaults to the first program found out of: `bison -y', `byacc',
- `yacc'.
- YFLAGS The list of arguments that will be passed by default to $YACC.
- This script will default YFLAGS to the empty string to avoid a
- default value of `-d' given by some make applications.
- PKG_CONFIG path to pkg-config utility
- PKG_CONFIG_PATH
- directories to add to pkg-config's search path
- PKG_CONFIG_LIBDIR
- path overriding pkg-config's built-in search path
- ZSTD_CFLAGS C compiler flags for ZSTD, overriding pkg-config
- ZSTD_LIBS linker flags for ZSTD, overriding pkg-config
- JANSSON_CFLAGS
- C compiler flags for JANSSON, overriding pkg-config
- JANSSON_LIBS
- linker flags for JANSSON, overriding pkg-config
- CXXCPP C++ preprocessor
-
-Use these variables to override the choices made by `configure' or to help
-it to find libraries and programs with nonstandard names/locations.
-
-Report bugs to the package provider.
-_ACEOF
-ac_status=$?
-fi
-
-if test "$ac_init_help" = "recursive"; then
- # If there are subdirs, report their specific --help.
- for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
- test -d "$ac_dir" ||
- { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
- continue
- ac_builddir=.
-
-case "$ac_dir" in
-.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
-*)
- ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
- # A ".." for each directory in $ac_dir_suffix.
- ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
- case $ac_top_builddir_sub in
- "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
- *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
- esac ;;
-esac
-ac_abs_top_builddir=$ac_pwd
-ac_abs_builddir=$ac_pwd$ac_dir_suffix
-# for backward compatibility:
-ac_top_builddir=$ac_top_build_prefix
-
-case $srcdir in
- .) # We are building in place.
- ac_srcdir=.
- ac_top_srcdir=$ac_top_builddir_sub
- ac_abs_top_srcdir=$ac_pwd ;;
- [\\/]* | ?:[\\/]* ) # Absolute name.
- ac_srcdir=$srcdir$ac_dir_suffix;
- ac_top_srcdir=$srcdir
- ac_abs_top_srcdir=$srcdir ;;
- *) # Relative name.
- ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
- ac_top_srcdir=$ac_top_build_prefix$srcdir
- ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
-esac
-ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
-
- cd "$ac_dir" || { ac_status=$?; continue; }
- # Check for guested configure.
- if test -f "$ac_srcdir/configure.gnu"; then
- echo &&
- $SHELL "$ac_srcdir/configure.gnu" --help=recursive
- elif test -f "$ac_srcdir/configure"; then
- echo &&
- $SHELL "$ac_srcdir/configure" --help=recursive
- else
- $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
- fi || ac_status=$?
- cd "$ac_pwd" || { ac_status=$?; break; }
- done
-fi
-
-test -n "$ac_init_help" && exit $ac_status
-if $ac_init_version; then
- cat <<\_ACEOF
-gold configure 0.1
-generated by GNU Autoconf 2.69
-
-Copyright (C) 2012 Free Software Foundation, Inc.
-This configure script is free software; the Free Software Foundation
-gives unlimited permission to copy, distribute and modify it.
-_ACEOF
- exit
-fi
-
-## ------------------------ ##
-## Autoconf initialization. ##
-## ------------------------ ##
-
-# ac_fn_c_try_compile LINENO
-# --------------------------
-# Try to compile conftest.$ac_ext, and return whether this succeeded.
-ac_fn_c_try_compile ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- rm -f conftest.$ac_objext
- if { { ac_try="$ac_compile"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_compile") 2>conftest.err
- ac_status=$?
- if test -s conftest.err; then
- grep -v '^ *+' conftest.err >conftest.er1
- cat conftest.er1 >&5
- mv -f conftest.er1 conftest.err
- fi
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && {
- test -z "$ac_c_werror_flag" ||
- test ! -s conftest.err
- } && test -s conftest.$ac_objext; then :
- ac_retval=0
-else
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
- ac_retval=1
-fi
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
- as_fn_set_status $ac_retval
-
-} # ac_fn_c_try_compile
-
-# ac_fn_c_try_cpp LINENO
-# ----------------------
-# Try to preprocess conftest.$ac_ext, and return whether this succeeded.
-ac_fn_c_try_cpp ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- if { { ac_try="$ac_cpp conftest.$ac_ext"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
- ac_status=$?
- if test -s conftest.err; then
- grep -v '^ *+' conftest.err >conftest.er1
- cat conftest.er1 >&5
- mv -f conftest.er1 conftest.err
- fi
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } > conftest.i && {
- test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
- test ! -s conftest.err
- }; then :
- ac_retval=0
-else
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
- ac_retval=1
-fi
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
- as_fn_set_status $ac_retval
-
-} # ac_fn_c_try_cpp
-
-# ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
-# -------------------------------------------------------
-# Tests whether HEADER exists, giving a warning if it cannot be compiled using
-# the include files in INCLUDES and setting the cache variable VAR
-# accordingly.
-ac_fn_c_check_header_mongrel ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- if eval \${$3+:} false; then :
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
-$as_echo_n "checking for $2... " >&6; }
-if eval \${$3+:} false; then :
- $as_echo_n "(cached) " >&6
-fi
-eval ac_res=\$$3
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
-else
- # Is the header compilable?
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
-$as_echo_n "checking $2 usability... " >&6; }
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$4
-#include <$2>
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_header_compiler=yes
-else
- ac_header_compiler=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
-$as_echo "$ac_header_compiler" >&6; }
-
-# Is the header present?
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
-$as_echo_n "checking $2 presence... " >&6; }
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <$2>
-_ACEOF
-if ac_fn_c_try_cpp "$LINENO"; then :
- ac_header_preproc=yes
-else
- ac_header_preproc=no
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
-$as_echo "$ac_header_preproc" >&6; }
-
-# So? What about this header?
-case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
- yes:no: )
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
-$as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
-$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
- ;;
- no:yes:* )
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
-$as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
-$as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
-$as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
-$as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
-$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
- ;;
-esac
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
-$as_echo_n "checking for $2... " >&6; }
-if eval \${$3+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- eval "$3=\$ac_header_compiler"
-fi
-eval ac_res=\$$3
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
-fi
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
-
-} # ac_fn_c_check_header_mongrel
-
-# ac_fn_c_try_run LINENO
-# ----------------------
-# Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
-# that executables *can* be run.
-ac_fn_c_try_run ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- if { { ac_try="$ac_link"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_link") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
- { { case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_try") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; }; then :
- ac_retval=0
-else
- $as_echo "$as_me: program exited with status $ac_status" >&5
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
- ac_retval=$ac_status
-fi
- rm -rf conftest.dSYM conftest_ipa8_conftest.oo
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
- as_fn_set_status $ac_retval
-
-} # ac_fn_c_try_run
-
-# ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
-# -------------------------------------------------------
-# Tests whether HEADER exists and can be compiled using the include files in
-# INCLUDES, setting the cache variable VAR accordingly.
-ac_fn_c_check_header_compile ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
-$as_echo_n "checking for $2... " >&6; }
-if eval \${$3+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$4
-#include <$2>
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- eval "$3=yes"
-else
- eval "$3=no"
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-eval ac_res=\$$3
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
-
-} # ac_fn_c_check_header_compile
-
-# ac_fn_c_try_link LINENO
-# -----------------------
-# Try to link conftest.$ac_ext, and return whether this succeeded.
-ac_fn_c_try_link ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- rm -f conftest.$ac_objext conftest$ac_exeext
- if { { ac_try="$ac_link"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_link") 2>conftest.err
- ac_status=$?
- if test -s conftest.err; then
- grep -v '^ *+' conftest.err >conftest.er1
- cat conftest.er1 >&5
- mv -f conftest.er1 conftest.err
- fi
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && {
- test -z "$ac_c_werror_flag" ||
- test ! -s conftest.err
- } && test -s conftest$ac_exeext && {
- test "$cross_compiling" = yes ||
- test -x conftest$ac_exeext
- }; then :
- ac_retval=0
-else
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
- ac_retval=1
-fi
- # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
- # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
- # interfere with the next link command; also delete a directory that is
- # left behind by Apple's compiler. We do this before executing the actions.
- rm -rf conftest.dSYM conftest_ipa8_conftest.oo
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
- as_fn_set_status $ac_retval
-
-} # ac_fn_c_try_link
-
-# ac_fn_cxx_try_compile LINENO
-# ----------------------------
-# Try to compile conftest.$ac_ext, and return whether this succeeded.
-ac_fn_cxx_try_compile ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- rm -f conftest.$ac_objext
- if { { ac_try="$ac_compile"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_compile") 2>conftest.err
- ac_status=$?
- if test -s conftest.err; then
- grep -v '^ *+' conftest.err >conftest.er1
- cat conftest.er1 >&5
- mv -f conftest.er1 conftest.err
- fi
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && {
- test -z "$ac_cxx_werror_flag" ||
- test ! -s conftest.err
- } && test -s conftest.$ac_objext; then :
- ac_retval=0
-else
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
- ac_retval=1
-fi
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
- as_fn_set_status $ac_retval
-
-} # ac_fn_cxx_try_compile
-
-# ac_fn_c_check_func LINENO FUNC VAR
-# ----------------------------------
-# Tests whether FUNC exists, setting the cache variable VAR accordingly
-ac_fn_c_check_func ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
-$as_echo_n "checking for $2... " >&6; }
-if eval \${$3+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-/* Define $2 to an innocuous variant, in case <limits.h> declares $2.
- For example, HP-UX 11i <limits.h> declares gettimeofday. */
-#define $2 innocuous_$2
-
-/* System header to define __stub macros and hopefully few prototypes,
- which can conflict with char $2 (); below.
- Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
- <limits.h> exists even on freestanding compilers. */
-
-#ifdef __STDC__
-# include <limits.h>
-#else
-# include <assert.h>
-#endif
-
-#undef $2
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char $2 ();
-/* The GNU C library defines this for functions which it implements
- to always fail with ENOSYS. Some functions are actually named
- something starting with __ and the normal name is an alias. */
-#if defined __stub_$2 || defined __stub___$2
-choke me
-#endif
-
-int
-main ()
-{
-return $2 ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- eval "$3=yes"
-else
- eval "$3=no"
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-fi
-eval ac_res=\$$3
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
-
-} # ac_fn_c_check_func
-
-# ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES
-# ---------------------------------------------
-# Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR
-# accordingly.
-ac_fn_c_check_decl ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- as_decl_name=`echo $2|sed 's/ *(.*//'`
- as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'`
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5
-$as_echo_n "checking whether $as_decl_name is declared... " >&6; }
-if eval \${$3+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$4
-int
-main ()
-{
-#ifndef $as_decl_name
-#ifdef __cplusplus
- (void) $as_decl_use;
-#else
- (void) $as_decl_name;
-#endif
-#endif
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- eval "$3=yes"
-else
- eval "$3=no"
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-eval ac_res=\$$3
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
-
-} # ac_fn_c_check_decl
-
-# ac_fn_cxx_try_cpp LINENO
-# ------------------------
-# Try to preprocess conftest.$ac_ext, and return whether this succeeded.
-ac_fn_cxx_try_cpp ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- if { { ac_try="$ac_cpp conftest.$ac_ext"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
- ac_status=$?
- if test -s conftest.err; then
- grep -v '^ *+' conftest.err >conftest.er1
- cat conftest.er1 >&5
- mv -f conftest.er1 conftest.err
- fi
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } > conftest.i && {
- test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" ||
- test ! -s conftest.err
- }; then :
- ac_retval=0
-else
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
- ac_retval=1
-fi
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
- as_fn_set_status $ac_retval
-
-} # ac_fn_cxx_try_cpp
-
-# ac_fn_cxx_check_header_mongrel LINENO HEADER VAR INCLUDES
-# ---------------------------------------------------------
-# Tests whether HEADER exists, giving a warning if it cannot be compiled using
-# the include files in INCLUDES and setting the cache variable VAR
-# accordingly.
-ac_fn_cxx_check_header_mongrel ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- if eval \${$3+:} false; then :
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
-$as_echo_n "checking for $2... " >&6; }
-if eval \${$3+:} false; then :
- $as_echo_n "(cached) " >&6
-fi
-eval ac_res=\$$3
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
-else
- # Is the header compilable?
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
-$as_echo_n "checking $2 usability... " >&6; }
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$4
-#include <$2>
-_ACEOF
-if ac_fn_cxx_try_compile "$LINENO"; then :
- ac_header_compiler=yes
-else
- ac_header_compiler=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
-$as_echo "$ac_header_compiler" >&6; }
-
-# Is the header present?
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
-$as_echo_n "checking $2 presence... " >&6; }
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <$2>
-_ACEOF
-if ac_fn_cxx_try_cpp "$LINENO"; then :
- ac_header_preproc=yes
-else
- ac_header_preproc=no
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
-$as_echo "$ac_header_preproc" >&6; }
-
-# So? What about this header?
-case $ac_header_compiler:$ac_header_preproc:$ac_cxx_preproc_warn_flag in #((
- yes:no: )
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
-$as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
-$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
- ;;
- no:yes:* )
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
-$as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
-$as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
-$as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
-$as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
-$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
- ;;
-esac
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
-$as_echo_n "checking for $2... " >&6; }
-if eval \${$3+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- eval "$3=\$ac_header_compiler"
-fi
-eval ac_res=\$$3
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
-fi
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
-
-} # ac_fn_cxx_check_header_mongrel
-
-# ac_fn_cxx_check_decl LINENO SYMBOL VAR INCLUDES
-# -----------------------------------------------
-# Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR
-# accordingly.
-ac_fn_cxx_check_decl ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- as_decl_name=`echo $2|sed 's/ *(.*//'`
- as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'`
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5
-$as_echo_n "checking whether $as_decl_name is declared... " >&6; }
-if eval \${$3+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$4
-int
-main ()
-{
-#ifndef $as_decl_name
-#ifdef __cplusplus
- (void) $as_decl_use;
-#else
- (void) $as_decl_name;
-#endif
-#endif
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_cxx_try_compile "$LINENO"; then :
- eval "$3=yes"
-else
- eval "$3=no"
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-eval ac_res=\$$3
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
-
-} # ac_fn_cxx_check_decl
-
-# ac_fn_cxx_try_link LINENO
-# -------------------------
-# Try to link conftest.$ac_ext, and return whether this succeeded.
-ac_fn_cxx_try_link ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- rm -f conftest.$ac_objext conftest$ac_exeext
- if { { ac_try="$ac_link"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_link") 2>conftest.err
- ac_status=$?
- if test -s conftest.err; then
- grep -v '^ *+' conftest.err >conftest.er1
- cat conftest.er1 >&5
- mv -f conftest.er1 conftest.err
- fi
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && {
- test -z "$ac_cxx_werror_flag" ||
- test ! -s conftest.err
- } && test -s conftest$ac_exeext && {
- test "$cross_compiling" = yes ||
- test -x conftest$ac_exeext
- }; then :
- ac_retval=0
-else
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
- ac_retval=1
-fi
- # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
- # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
- # interfere with the next link command; also delete a directory that is
- # left behind by Apple's compiler. We do this before executing the actions.
- rm -rf conftest.dSYM conftest_ipa8_conftest.oo
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
- as_fn_set_status $ac_retval
-
-} # ac_fn_cxx_try_link
-
-# ac_fn_cxx_check_func LINENO FUNC VAR
-# ------------------------------------
-# Tests whether FUNC exists, setting the cache variable VAR accordingly
-ac_fn_cxx_check_func ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
-$as_echo_n "checking for $2... " >&6; }
-if eval \${$3+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-/* Define $2 to an innocuous variant, in case <limits.h> declares $2.
- For example, HP-UX 11i <limits.h> declares gettimeofday. */
-#define $2 innocuous_$2
-
-/* System header to define __stub macros and hopefully few prototypes,
- which can conflict with char $2 (); below.
- Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
- <limits.h> exists even on freestanding compilers. */
-
-#ifdef __STDC__
-# include <limits.h>
-#else
-# include <assert.h>
-#endif
-
-#undef $2
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char $2 ();
-/* The GNU C library defines this for functions which it implements
- to always fail with ENOSYS. Some functions are actually named
- something starting with __ and the normal name is an alias. */
-#if defined __stub_$2 || defined __stub___$2
-choke me
-#endif
-
-int
-main ()
-{
-return $2 ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_cxx_try_link "$LINENO"; then :
- eval "$3=yes"
-else
- eval "$3=no"
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-fi
-eval ac_res=\$$3
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
-
-} # ac_fn_cxx_check_func
-cat >config.log <<_ACEOF
-This file contains any messages produced by compilers while
-running configure, to aid debugging if configure makes a mistake.
-
-It was created by gold $as_me 0.1, which was
-generated by GNU Autoconf 2.69. Invocation command line was
-
- $ $0 $@
-
-_ACEOF
-exec 5>>config.log
-{
-cat <<_ASUNAME
-## --------- ##
-## Platform. ##
-## --------- ##
-
-hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
-uname -m = `(uname -m) 2>/dev/null || echo unknown`
-uname -r = `(uname -r) 2>/dev/null || echo unknown`
-uname -s = `(uname -s) 2>/dev/null || echo unknown`
-uname -v = `(uname -v) 2>/dev/null || echo unknown`
-
-/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
-/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
-
-/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
-/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
-/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
-/usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
-/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
-/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
-/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
-
-_ASUNAME
-
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- $as_echo "PATH: $as_dir"
- done
-IFS=$as_save_IFS
-
-} >&5
-
-cat >&5 <<_ACEOF
-
-
-## ----------- ##
-## Core tests. ##
-## ----------- ##
-
-_ACEOF
-
-
-# Keep a trace of the command line.
-# Strip out --no-create and --no-recursion so they do not pile up.
-# Strip out --silent because we don't want to record it for future runs.
-# Also quote any args containing shell meta-characters.
-# Make two passes to allow for proper duplicate-argument suppression.
-ac_configure_args=
-ac_configure_args0=
-ac_configure_args1=
-ac_must_keep_next=false
-for ac_pass in 1 2
-do
- for ac_arg
- do
- case $ac_arg in
- -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
- -q | -quiet | --quiet | --quie | --qui | --qu | --q \
- | -silent | --silent | --silen | --sile | --sil)
- continue ;;
- *\'*)
- ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
- esac
- case $ac_pass in
- 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
- 2)
- as_fn_append ac_configure_args1 " '$ac_arg'"
- if test $ac_must_keep_next = true; then
- ac_must_keep_next=false # Got value, back to normal.
- else
- case $ac_arg in
- *=* | --config-cache | -C | -disable-* | --disable-* \
- | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
- | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
- | -with-* | --with-* | -without-* | --without-* | --x)
- case "$ac_configure_args0 " in
- "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
- esac
- ;;
- -* ) ac_must_keep_next=true ;;
- esac
- fi
- as_fn_append ac_configure_args " '$ac_arg'"
- ;;
- esac
- done
-done
-{ ac_configure_args0=; unset ac_configure_args0;}
-{ ac_configure_args1=; unset ac_configure_args1;}
-
-# When interrupted or exit'd, cleanup temporary files, and complete
-# config.log. We remove comments because anyway the quotes in there
-# would cause problems or look ugly.
-# WARNING: Use '\'' to represent an apostrophe within the trap.
-# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
-trap 'exit_status=$?
- # Save into config.log some information that might help in debugging.
- {
- echo
-
- $as_echo "## ---------------- ##
-## Cache variables. ##
-## ---------------- ##"
- echo
- # The following way of writing the cache mishandles newlines in values,
-(
- for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
- eval ac_val=\$$ac_var
- case $ac_val in #(
- *${as_nl}*)
- case $ac_var in #(
- *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
-$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
- esac
- case $ac_var in #(
- _ | IFS | as_nl) ;; #(
- BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
- *) { eval $ac_var=; unset $ac_var;} ;;
- esac ;;
- esac
- done
- (set) 2>&1 |
- case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
- *${as_nl}ac_space=\ *)
- sed -n \
- "s/'\''/'\''\\\\'\'''\''/g;
- s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
- ;; #(
- *)
- sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
- ;;
- esac |
- sort
-)
- echo
-
- $as_echo "## ----------------- ##
-## Output variables. ##
-## ----------------- ##"
- echo
- for ac_var in $ac_subst_vars
- do
- eval ac_val=\$$ac_var
- case $ac_val in
- *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
- esac
- $as_echo "$ac_var='\''$ac_val'\''"
- done | sort
- echo
-
- if test -n "$ac_subst_files"; then
- $as_echo "## ------------------- ##
-## File substitutions. ##
-## ------------------- ##"
- echo
- for ac_var in $ac_subst_files
- do
- eval ac_val=\$$ac_var
- case $ac_val in
- *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
- esac
- $as_echo "$ac_var='\''$ac_val'\''"
- done | sort
- echo
- fi
-
- if test -s confdefs.h; then
- $as_echo "## ----------- ##
-## confdefs.h. ##
-## ----------- ##"
- echo
- cat confdefs.h
- echo
- fi
- test "$ac_signal" != 0 &&
- $as_echo "$as_me: caught signal $ac_signal"
- $as_echo "$as_me: exit $exit_status"
- } >&5
- rm -f core *.core core.conftest.* &&
- rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
- exit $exit_status
-' 0
-for ac_signal in 1 2 13 15; do
- trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
-done
-ac_signal=0
-
-# confdefs.h avoids OS command line length limits that DEFS can exceed.
-rm -f -r conftest* confdefs.h
-
-$as_echo "/* confdefs.h */" > confdefs.h
-
-# Predefined preprocessor variables.
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_NAME "$PACKAGE_NAME"
-_ACEOF
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
-_ACEOF
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_VERSION "$PACKAGE_VERSION"
-_ACEOF
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_STRING "$PACKAGE_STRING"
-_ACEOF
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
-_ACEOF
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_URL "$PACKAGE_URL"
-_ACEOF
-
-
-# Let the site file select an alternate cache file if it wants to.
-# Prefer an explicitly selected file to automatically selected ones.
-ac_site_file1=NONE
-ac_site_file2=NONE
-if test -n "$CONFIG_SITE"; then
- # We do not want a PATH search for config.site.
- case $CONFIG_SITE in #((
- -*) ac_site_file1=./$CONFIG_SITE;;
- */*) ac_site_file1=$CONFIG_SITE;;
- *) ac_site_file1=./$CONFIG_SITE;;
- esac
-elif test "x$prefix" != xNONE; then
- ac_site_file1=$prefix/share/config.site
- ac_site_file2=$prefix/etc/config.site
-else
- ac_site_file1=$ac_default_prefix/share/config.site
- ac_site_file2=$ac_default_prefix/etc/config.site
-fi
-for ac_site_file in "$ac_site_file1" "$ac_site_file2"
-do
- test "x$ac_site_file" = xNONE && continue
- if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
-$as_echo "$as_me: loading site script $ac_site_file" >&6;}
- sed 's/^/| /' "$ac_site_file" >&5
- . "$ac_site_file" \
- || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "failed to load site script $ac_site_file
-See \`config.log' for more details" "$LINENO" 5; }
- fi
-done
-
-if test -r "$cache_file"; then
- # Some versions of bash will fail to source /dev/null (special files
- # actually), so we avoid doing that. DJGPP emulates it as a regular file.
- if test /dev/null != "$cache_file" && test -f "$cache_file"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
-$as_echo "$as_me: loading cache $cache_file" >&6;}
- case $cache_file in
- [\\/]* | ?:[\\/]* ) . "$cache_file";;
- *) . "./$cache_file";;
- esac
- fi
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
-$as_echo "$as_me: creating cache $cache_file" >&6;}
- >$cache_file
-fi
-
-gt_needs="$gt_needs "
-# Check that the precious variables saved in the cache have kept the same
-# value.
-ac_cache_corrupted=false
-for ac_var in $ac_precious_vars; do
- eval ac_old_set=\$ac_cv_env_${ac_var}_set
- eval ac_new_set=\$ac_env_${ac_var}_set
- eval ac_old_val=\$ac_cv_env_${ac_var}_value
- eval ac_new_val=\$ac_env_${ac_var}_value
- case $ac_old_set,$ac_new_set in
- set,)
- { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
-$as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
- ac_cache_corrupted=: ;;
- ,set)
- { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
-$as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
- ac_cache_corrupted=: ;;
- ,);;
- *)
- if test "x$ac_old_val" != "x$ac_new_val"; then
- # differences in whitespace do not lead to failure.
- ac_old_val_w=`echo x $ac_old_val`
- ac_new_val_w=`echo x $ac_new_val`
- if test "$ac_old_val_w" != "$ac_new_val_w"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
-$as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
- ac_cache_corrupted=:
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
-$as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
- eval $ac_var=\$ac_old_val
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
-$as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
-$as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
- fi;;
- esac
- # Pass precious variables to config.status.
- if test "$ac_new_set" = set; then
- case $ac_new_val in
- *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
- *) ac_arg=$ac_var=$ac_new_val ;;
- esac
- case " $ac_configure_args " in
- *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
- *) as_fn_append ac_configure_args " '$ac_arg'" ;;
- esac
- fi
-done
-if $ac_cache_corrupted; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
-$as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
- as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
-fi
-## -------------------- ##
-## Main body of script. ##
-## -------------------- ##
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-
-
-
-
-
-
-ac_aux_dir=
-for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
- if test -f "$ac_dir/install-sh"; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install-sh -c"
- break
- elif test -f "$ac_dir/install.sh"; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install.sh -c"
- break
- elif test -f "$ac_dir/shtool"; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/shtool install -c"
- break
- fi
-done
-if test -z "$ac_aux_dir"; then
- as_fn_error $? "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5
-fi
-
-# These three variables are undocumented and unsupported,
-# and are intended to be withdrawn in a future Autoconf release.
-# They can cause serious problems if a builder's source tree is in a directory
-# whose full name contains unusual characters.
-ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
-ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
-ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
-
-
-# Make sure we can run config.sub.
-$SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
- as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
-$as_echo_n "checking build system type... " >&6; }
-if ${ac_cv_build+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_build_alias=$build_alias
-test "x$ac_build_alias" = x &&
- ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
-test "x$ac_build_alias" = x &&
- as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
-ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
- as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
-$as_echo "$ac_cv_build" >&6; }
-case $ac_cv_build in
-*-*-*) ;;
-*) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
-esac
-build=$ac_cv_build
-ac_save_IFS=$IFS; IFS='-'
-set x $ac_cv_build
-shift
-build_cpu=$1
-build_vendor=$2
-shift; shift
-# Remember, the first character of IFS is used to create $*,
-# except with old shells:
-build_os=$*
-IFS=$ac_save_IFS
-case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
-$as_echo_n "checking host system type... " >&6; }
-if ${ac_cv_host+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test "x$host_alias" = x; then
- ac_cv_host=$ac_cv_build
-else
- ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
- as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
-$as_echo "$ac_cv_host" >&6; }
-case $ac_cv_host in
-*-*-*) ;;
-*) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
-esac
-host=$ac_cv_host
-ac_save_IFS=$IFS; IFS='-'
-set x $ac_cv_host
-shift
-host_cpu=$1
-host_vendor=$2
-shift; shift
-# Remember, the first character of IFS is used to create $*,
-# except with old shells:
-host_os=$*
-IFS=$ac_save_IFS
-case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking target system type" >&5
-$as_echo_n "checking target system type... " >&6; }
-if ${ac_cv_target+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test "x$target_alias" = x; then
- ac_cv_target=$ac_cv_host
-else
- ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` ||
- as_fn_error $? "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5
-$as_echo "$ac_cv_target" >&6; }
-case $ac_cv_target in
-*-*-*) ;;
-*) as_fn_error $? "invalid value of canonical target" "$LINENO" 5;;
-esac
-target=$ac_cv_target
-ac_save_IFS=$IFS; IFS='-'
-set x $ac_cv_target
-shift
-target_cpu=$1
-target_vendor=$2
-shift; shift
-# Remember, the first character of IFS is used to create $*,
-# except with old shells:
-target_os=$*
-IFS=$ac_save_IFS
-case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac
-
-
-# The aliases save the names the user supplied, while $host etc.
-# will get canonicalized.
-test -n "$target_alias" &&
- test "$program_prefix$program_suffix$program_transform_name" = \
- NONENONEs,x,x, &&
- program_prefix=${target_alias}-
-
-am__api_version='1.15'
-
-# Find a good install program. We prefer a C program (faster),
-# so one script is as good as another. But avoid the broken or
-# incompatible versions:
-# SysV /etc/install, /usr/sbin/install
-# SunOS /usr/etc/install
-# IRIX /sbin/install
-# AIX /bin/install
-# AmigaOS /C/install, which installs bootblocks on floppy discs
-# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
-# AFS /usr/afsws/bin/install, which mishandles nonexistent args
-# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
-# OS/2's system install, which has a completely different semantic
-# ./install, which can be erroneously created by make from ./install.sh.
-# Reject install programs that cannot install multiple files.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
-$as_echo_n "checking for a BSD-compatible install... " >&6; }
-if test -z "$INSTALL"; then
-if ${ac_cv_path_install+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- # Account for people who put trailing slashes in PATH elements.
-case $as_dir/ in #((
- ./ | .// | /[cC]/* | \
- /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
- ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
- /usr/ucb/* ) ;;
- *)
- # OSF1 and SCO ODT 3.0 have their own names for install.
- # Don't use installbsd from OSF since it installs stuff as root
- # by default.
- for ac_prog in ginstall scoinst install; do
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
- if test $ac_prog = install &&
- grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
- # AIX install. It has an incompatible calling convention.
- :
- elif test $ac_prog = install &&
- grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
- # program-specific install script used by HP pwplus--don't use.
- :
- else
- rm -rf conftest.one conftest.two conftest.dir
- echo one > conftest.one
- echo two > conftest.two
- mkdir conftest.dir
- if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
- test -s conftest.one && test -s conftest.two &&
- test -s conftest.dir/conftest.one &&
- test -s conftest.dir/conftest.two
- then
- ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
- break 3
- fi
- fi
- fi
- done
- done
- ;;
-esac
-
- done
-IFS=$as_save_IFS
-
-rm -rf conftest.one conftest.two conftest.dir
-
-fi
- if test "${ac_cv_path_install+set}" = set; then
- INSTALL=$ac_cv_path_install
- else
- # As a last resort, use the slow shell script. Don't cache a
- # value for INSTALL within a source directory, because that will
- # break other packages using the cache if that directory is
- # removed, or if the value is a relative name.
- INSTALL=$ac_install_sh
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
-$as_echo "$INSTALL" >&6; }
-
-# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
-# It thinks the first close brace ends the variable substitution.
-test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
-
-test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
-
-test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5
-$as_echo_n "checking whether build environment is sane... " >&6; }
-# Reject unsafe characters in $srcdir or the absolute working directory
-# name. Accept space and tab only in the latter.
-am_lf='
-'
-case `pwd` in
- *[\\\"\#\$\&\'\`$am_lf]*)
- as_fn_error $? "unsafe absolute working directory name" "$LINENO" 5;;
-esac
-case $srcdir in
- *[\\\"\#\$\&\'\`$am_lf\ \ ]*)
- as_fn_error $? "unsafe srcdir value: '$srcdir'" "$LINENO" 5;;
-esac
-
-# Do 'set' in a subshell so we don't clobber the current shell's
-# arguments. Must try -L first in case configure is actually a
-# symlink; some systems play weird games with the mod time of symlinks
-# (eg FreeBSD returns the mod time of the symlink's containing
-# directory).
-if (
- am_has_slept=no
- for am_try in 1 2; do
- echo "timestamp, slept: $am_has_slept" > conftest.file
- set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
- if test "$*" = "X"; then
- # -L didn't work.
- set X `ls -t "$srcdir/configure" conftest.file`
- fi
- if test "$*" != "X $srcdir/configure conftest.file" \
- && test "$*" != "X conftest.file $srcdir/configure"; then
-
- # If neither matched, then we have a broken ls. This can happen
- # if, for instance, CONFIG_SHELL is bash and it inherits a
- # broken ls alias from the environment. This has actually
- # happened. Such a system could not be considered "sane".
- as_fn_error $? "ls -t appears to fail. Make sure there is not a broken
- alias in your environment" "$LINENO" 5
- fi
- if test "$2" = conftest.file || test $am_try -eq 2; then
- break
- fi
- # Just in case.
- sleep 1
- am_has_slept=yes
- done
- test "$2" = conftest.file
- )
-then
- # Ok.
- :
-else
- as_fn_error $? "newly created file is older than distributed files!
-Check your system clock" "$LINENO" 5
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-# If we didn't sleep, we still need to ensure time stamps of config.status and
-# generated files are strictly newer.
-am_sleep_pid=
-if grep 'slept: no' conftest.file >/dev/null 2>&1; then
- ( sleep 1 ) &
- am_sleep_pid=$!
-fi
-
-rm -f conftest.file
-
-test "$program_prefix" != NONE &&
- program_transform_name="s&^&$program_prefix&;$program_transform_name"
-# Use a double $ so make ignores it.
-test "$program_suffix" != NONE &&
- program_transform_name="s&\$&$program_suffix&;$program_transform_name"
-# Double any \ or $.
-# By default was `s,x,x', remove it if useless.
-ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
-program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
-
-# Expand $ac_aux_dir to an absolute path.
-am_aux_dir=`cd "$ac_aux_dir" && pwd`
-
-if test x"${MISSING+set}" != xset; then
- case $am_aux_dir in
- *\ * | *\ *)
- MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
- *)
- MISSING="\${SHELL} $am_aux_dir/missing" ;;
- esac
-fi
-# Use eval to expand $SHELL
-if eval "$MISSING --is-lightweight"; then
- am_missing_run="$MISSING "
-else
- am_missing_run=
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: 'missing' script is too old or missing" >&5
-$as_echo "$as_me: WARNING: 'missing' script is too old or missing" >&2;}
-fi
-
-if test x"${install_sh+set}" != xset; then
- case $am_aux_dir in
- *\ * | *\ *)
- install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
- *)
- install_sh="\${SHELL} $am_aux_dir/install-sh"
- esac
-fi
-
-# Installed binaries are usually stripped using 'strip' when the user
-# run "make install-strip". However 'strip' might not be the right
-# tool to use in cross-compilation environments, therefore Automake
-# will honor the 'STRIP' environment variable to overrule this program.
-if test "$cross_compiling" != no; then
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
-set dummy ${ac_tool_prefix}strip; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_STRIP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$STRIP"; then
- ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_STRIP="${ac_tool_prefix}strip"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-STRIP=$ac_cv_prog_STRIP
-if test -n "$STRIP"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
-$as_echo "$STRIP" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_STRIP"; then
- ac_ct_STRIP=$STRIP
- # Extract the first word of "strip", so it can be a program name with args.
-set dummy strip; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_STRIP"; then
- ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_STRIP="strip"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
-if test -n "$ac_ct_STRIP"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
-$as_echo "$ac_ct_STRIP" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_STRIP" = x; then
- STRIP=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- STRIP=$ac_ct_STRIP
- fi
-else
- STRIP="$ac_cv_prog_STRIP"
-fi
-
-fi
-INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5
-$as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
-if test -z "$MKDIR_P"; then
- if ${ac_cv_path_mkdir+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_prog in mkdir gmkdir; do
- for ac_exec_ext in '' $ac_executable_extensions; do
- as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext" || continue
- case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
- 'mkdir (GNU coreutils) '* | \
- 'mkdir (coreutils) '* | \
- 'mkdir (fileutils) '4.1*)
- ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
- break 3;;
- esac
- done
- done
- done
-IFS=$as_save_IFS
-
-fi
-
- test -d ./--version && rmdir ./--version
- if test "${ac_cv_path_mkdir+set}" = set; then
- MKDIR_P="$ac_cv_path_mkdir -p"
- else
- # As a last resort, use the slow shell script. Don't cache a
- # value for MKDIR_P within a source directory, because that will
- # break other packages using the cache if that directory is
- # removed, or if the value is a relative name.
- MKDIR_P="$ac_install_sh -d"
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
-$as_echo "$MKDIR_P" >&6; }
-
-for ac_prog in gawk mawk nawk awk
-do
- # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_AWK+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$AWK"; then
- ac_cv_prog_AWK="$AWK" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_AWK="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-AWK=$ac_cv_prog_AWK
-if test -n "$AWK"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
-$as_echo "$AWK" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$AWK" && break
-done
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
-$as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
-set x ${MAKE-make}
-ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
-if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat >conftest.make <<\_ACEOF
-SHELL = /bin/sh
-all:
- @echo '@@@%%%=$(MAKE)=@@@%%%'
-_ACEOF
-# GNU make sometimes prints "make[1]: Entering ...", which would confuse us.
-case `${MAKE-make} -f conftest.make 2>/dev/null` in
- *@@@%%%=?*=@@@%%%*)
- eval ac_cv_prog_make_${ac_make}_set=yes;;
- *)
- eval ac_cv_prog_make_${ac_make}_set=no;;
-esac
-rm -f conftest.make
-fi
-if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- SET_MAKE=
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- SET_MAKE="MAKE=${MAKE-make}"
-fi
-
-rm -rf .tst 2>/dev/null
-mkdir .tst 2>/dev/null
-if test -d .tst; then
- am__leading_dot=.
-else
- am__leading_dot=_
-fi
-rmdir .tst 2>/dev/null
-
-# Check whether --enable-silent-rules was given.
-if test "${enable_silent_rules+set}" = set; then :
- enableval=$enable_silent_rules;
-fi
-
-case $enable_silent_rules in # (((
- yes) AM_DEFAULT_VERBOSITY=0;;
- no) AM_DEFAULT_VERBOSITY=1;;
- *) AM_DEFAULT_VERBOSITY=1;;
-esac
-am_make=${MAKE-make}
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5
-$as_echo_n "checking whether $am_make supports nested variables... " >&6; }
-if ${am_cv_make_support_nested_variables+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if $as_echo 'TRUE=$(BAR$(V))
-BAR0=false
-BAR1=true
-V=1
-am__doit:
- @$(TRUE)
-.PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then
- am_cv_make_support_nested_variables=yes
-else
- am_cv_make_support_nested_variables=no
-fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5
-$as_echo "$am_cv_make_support_nested_variables" >&6; }
-if test $am_cv_make_support_nested_variables = yes; then
- AM_V='$(V)'
- AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
-else
- AM_V=$AM_DEFAULT_VERBOSITY
- AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY
-fi
-AM_BACKSLASH='\'
-
-if test "`cd $srcdir && pwd`" != "`pwd`"; then
- # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
- # is not polluted with repeated "-I."
- am__isrc=' -I$(srcdir)'
- # test to see if srcdir already configured
- if test -f $srcdir/config.status; then
- as_fn_error $? "source directory already configured; run \"make distclean\" there first" "$LINENO" 5
- fi
-fi
-
-# test whether we have cygpath
-if test -z "$CYGPATH_W"; then
- if (cygpath --version) >/dev/null 2>/dev/null; then
- CYGPATH_W='cygpath -w'
- else
- CYGPATH_W=echo
- fi
-fi
-
-
-# Define the identity of the package.
- PACKAGE='gold'
- VERSION='0.1'
-
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE "$PACKAGE"
-_ACEOF
-
-
-cat >>confdefs.h <<_ACEOF
-#define VERSION "$VERSION"
-_ACEOF
-
-# Some tools Automake needs.
-
-ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"}
-
-
-AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
-
-
-AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"}
-
-
-AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
-
-
-MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
-
-# For better backward compatibility. To be removed once Automake 1.9.x
-# dies out for good. For more background, see:
-# <http://lists.gnu.org/archive/html/automake/2012-07/msg00001.html>
-# <http://lists.gnu.org/archive/html/automake/2012-07/msg00014.html>
-mkdir_p='$(MKDIR_P)'
-
-# We need awk for the "check" target (and possibly the TAP driver). The
-# system "awk" is bad on some platforms.
-# Always define AMTAR for backward compatibility. Yes, it's still used
-# in the wild :-( We should find a proper way to deprecate it ...
-AMTAR='$${TAR-tar}'
-
-
-# We'll loop over all known methods to create a tar archive until one works.
-_am_tools='gnutar pax cpio none'
-
-am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -'
-
-
-
-
-
-
-# POSIX will say in a future version that running "rm -f" with no argument
-# is OK; and we want to be able to make that assumption in our Makefile
-# recipes. So use an aggressive probe to check that the usage we want is
-# actually supported "in the wild" to an acceptable degree.
-# See automake bug#10828.
-# To make any issue more visible, cause the running configure to be aborted
-# by default if the 'rm' program in use doesn't match our expectations; the
-# user can still override this though.
-if rm -f && rm -fr && rm -rf; then : OK; else
- cat >&2 <<'END'
-Oops!
-
-Your 'rm' program seems unable to run without file operands specified
-on the command line, even when the '-f' option is present. This is contrary
-to the behaviour of most rm programs out there, and not conforming with
-the upcoming POSIX standard: <http://austingroupbugs.net/view.php?id=542>
-
-Please tell bug-automake@gnu.org about your system, including the value
-of your $PATH and any error possibly output before this message. This
-can help us improve future automake versions.
-
-END
- if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then
- echo 'Configuration will proceed anyway, since you have set the' >&2
- echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2
- echo >&2
- else
- cat >&2 <<'END'
-Aborting the configuration process, to ensure you take notice of the issue.
-
-You can download and install GNU coreutils to get an 'rm' implementation
-that behaves properly: <http://www.gnu.org/software/coreutils/>.
-
-If you want to complete the configuration process using your problematic
-'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM
-to "yes", and re-run configure.
-
-END
- as_fn_error $? "Your 'rm' program is bad, sorry." "$LINENO" 5
- fi
-fi
-
-# Check whether --enable-silent-rules was given.
-if test "${enable_silent_rules+set}" = set; then :
- enableval=$enable_silent_rules;
-fi
-
-case $enable_silent_rules in # (((
- yes) AM_DEFAULT_VERBOSITY=0;;
- no) AM_DEFAULT_VERBOSITY=1;;
- *) AM_DEFAULT_VERBOSITY=0;;
-esac
-am_make=${MAKE-make}
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5
-$as_echo_n "checking whether $am_make supports nested variables... " >&6; }
-if ${am_cv_make_support_nested_variables+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if $as_echo 'TRUE=$(BAR$(V))
-BAR0=false
-BAR1=true
-V=1
-am__doit:
- @$(TRUE)
-.PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then
- am_cv_make_support_nested_variables=yes
-else
- am_cv_make_support_nested_variables=no
-fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5
-$as_echo "$am_cv_make_support_nested_variables" >&6; }
-if test $am_cv_make_support_nested_variables = yes; then
- AM_V='$(V)'
- AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
-else
- AM_V=$AM_DEFAULT_VERBOSITY
- AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY
-fi
-AM_BACKSLASH='\'
-
-
-ac_config_headers="$ac_config_headers config.h:config.in"
-
-
-DEPDIR="${am__leading_dot}deps"
-
-ac_config_commands="$ac_config_commands depfiles"
-
-
-am_make=${MAKE-make}
-cat > confinc << 'END'
-am__doit:
- @echo this is the am__doit target
-.PHONY: am__doit
-END
-# If we don't find an include directive, just comment out the code.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5
-$as_echo_n "checking for style of include used by $am_make... " >&6; }
-am__include="#"
-am__quote=
-_am_result=none
-# First try GNU make style include.
-echo "include confinc" > confmf
-# Ignore all kinds of additional output from 'make'.
-case `$am_make -s -f confmf 2> /dev/null` in #(
-*the\ am__doit\ target*)
- am__include=include
- am__quote=
- _am_result=GNU
- ;;
-esac
-# Now try BSD make style include.
-if test "$am__include" = "#"; then
- echo '.include "confinc"' > confmf
- case `$am_make -s -f confmf 2> /dev/null` in #(
- *the\ am__doit\ target*)
- am__include=.include
- am__quote="\""
- _am_result=BSD
- ;;
- esac
-fi
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5
-$as_echo "$_am_result" >&6; }
-rm -f confinc confmf
-
-# Check whether --enable-dependency-tracking was given.
-if test "${enable_dependency_tracking+set}" = set; then :
- enableval=$enable_dependency_tracking;
-fi
-
-if test "x$enable_dependency_tracking" != xno; then
- am_depcomp="$ac_aux_dir/depcomp"
- AMDEPBACKSLASH='\'
- am__nodep='_no'
-fi
- if test "x$enable_dependency_tracking" != xno; then
- AMDEP_TRUE=
- AMDEP_FALSE='#'
-else
- AMDEP_TRUE='#'
- AMDEP_FALSE=
-fi
-
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
-set dummy ${ac_tool_prefix}gcc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_CC="${ac_tool_prefix}gcc"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
-$as_echo "$CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_CC"; then
- ac_ct_CC=$CC
- # Extract the first word of "gcc", so it can be a program name with args.
-set dummy gcc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_CC"; then
- ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_CC="gcc"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_CC=$ac_cv_prog_ac_ct_CC
-if test -n "$ac_ct_CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
-$as_echo "$ac_ct_CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_CC" = x; then
- CC=""
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- CC=$ac_ct_CC
- fi
-else
- CC="$ac_cv_prog_CC"
-fi
-
-if test -z "$CC"; then
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
-set dummy ${ac_tool_prefix}cc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_CC="${ac_tool_prefix}cc"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
-$as_echo "$CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
-fi
-if test -z "$CC"; then
- # Extract the first word of "cc", so it can be a program name with args.
-set dummy cc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
- ac_prog_rejected=no
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
- ac_prog_rejected=yes
- continue
- fi
- ac_cv_prog_CC="cc"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-if test $ac_prog_rejected = yes; then
- # We found a bogon in the path, so make sure we never use it.
- set dummy $ac_cv_prog_CC
- shift
- if test $# != 0; then
- # We chose a different compiler from the bogus one.
- # However, it has the same basename, so the bogon will be chosen
- # first if we set CC to just the basename; use the full file name.
- shift
- ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
- fi
-fi
-fi
-fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
-$as_echo "$CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$CC"; then
- if test -n "$ac_tool_prefix"; then
- for ac_prog in cl.exe
- do
- # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
-set dummy $ac_tool_prefix$ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
-$as_echo "$CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$CC" && break
- done
-fi
-if test -z "$CC"; then
- ac_ct_CC=$CC
- for ac_prog in cl.exe
-do
- # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_CC"; then
- ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_CC="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_CC=$ac_cv_prog_ac_ct_CC
-if test -n "$ac_ct_CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
-$as_echo "$ac_ct_CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$ac_ct_CC" && break
-done
-
- if test "x$ac_ct_CC" = x; then
- CC=""
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- CC=$ac_ct_CC
- fi
-fi
-
-fi
-
-
-test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "no acceptable C compiler found in \$PATH
-See \`config.log' for more details" "$LINENO" 5; }
-
-# Provide some information about the compiler.
-$as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
-set X $ac_compile
-ac_compiler=$2
-for ac_option in --version -v -V -qversion; do
- { { ac_try="$ac_compiler $ac_option >&5"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_compiler $ac_option >&5") 2>conftest.err
- ac_status=$?
- if test -s conftest.err; then
- sed '10a\
-... rest of stderr output deleted ...
- 10q' conftest.err >conftest.er1
- cat conftest.er1 >&5
- fi
- rm -f conftest.er1 conftest.err
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }
-done
-
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-ac_clean_files_save=$ac_clean_files
-ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
-# Try to create an executable without -o first, disregard a.out.
-# It will help us diagnose broken compilers, and finding out an intuition
-# of exeext.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
-$as_echo_n "checking whether the C compiler works... " >&6; }
-ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
-
-# The possible output files:
-ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
-
-ac_rmfiles=
-for ac_file in $ac_files
-do
- case $ac_file in
- *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
- * ) ac_rmfiles="$ac_rmfiles $ac_file";;
- esac
-done
-rm -f $ac_rmfiles
-
-if { { ac_try="$ac_link_default"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_link_default") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then :
- # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
-# So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
-# in a Makefile. We should not override ac_cv_exeext if it was cached,
-# so that the user can short-circuit this test for compilers unknown to
-# Autoconf.
-for ac_file in $ac_files ''
-do
- test -f "$ac_file" || continue
- case $ac_file in
- *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
- ;;
- [ab].out )
- # We found the default executable, but exeext='' is most
- # certainly right.
- break;;
- *.* )
- if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
- then :; else
- ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
- fi
- # We set ac_cv_exeext here because the later test for it is not
- # safe: cross compilers may not add the suffix if given an `-o'
- # argument, so we may need to know it at that point already.
- # Even if this section looks crufty: it has the advantage of
- # actually working.
- break;;
- * )
- break;;
- esac
-done
-test "$ac_cv_exeext" = no && ac_cv_exeext=
-
-else
- ac_file=''
-fi
-if test -z "$ac_file"; then :
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-$as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error 77 "C compiler cannot create executables
-See \`config.log' for more details" "$LINENO" 5; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
-$as_echo_n "checking for C compiler default output file name... " >&6; }
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
-$as_echo "$ac_file" >&6; }
-ac_exeext=$ac_cv_exeext
-
-rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
-ac_clean_files=$ac_clean_files_save
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
-$as_echo_n "checking for suffix of executables... " >&6; }
-if { { ac_try="$ac_link"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_link") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then :
- # If both `conftest.exe' and `conftest' are `present' (well, observable)
-# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
-# work properly (i.e., refer to `conftest.exe'), while it won't with
-# `rm'.
-for ac_file in conftest.exe conftest conftest.*; do
- test -f "$ac_file" || continue
- case $ac_file in
- *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
- *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
- break;;
- * ) break;;
- esac
-done
-else
- { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "cannot compute suffix of executables: cannot compile and link
-See \`config.log' for more details" "$LINENO" 5; }
-fi
-rm -f conftest conftest$ac_cv_exeext
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
-$as_echo "$ac_cv_exeext" >&6; }
-
-rm -f conftest.$ac_ext
-EXEEXT=$ac_cv_exeext
-ac_exeext=$EXEEXT
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <stdio.h>
-int
-main ()
-{
-FILE *f = fopen ("conftest.out", "w");
- return ferror (f) || fclose (f) != 0;
-
- ;
- return 0;
-}
-_ACEOF
-ac_clean_files="$ac_clean_files conftest.out"
-# Check that the compiler produces executables we can run. If not, either
-# the compiler is broken, or we cross compile.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
-$as_echo_n "checking whether we are cross compiling... " >&6; }
-if test "$cross_compiling" != yes; then
- { { ac_try="$ac_link"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_link") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }
- if { ac_try='./conftest$ac_cv_exeext'
- { { case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_try") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; }; then
- cross_compiling=no
- else
- if test "$cross_compiling" = maybe; then
- cross_compiling=yes
- else
- { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "cannot run C compiled programs.
-If you meant to cross compile, use \`--host'.
-See \`config.log' for more details" "$LINENO" 5; }
- fi
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
-$as_echo "$cross_compiling" >&6; }
-
-rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
-ac_clean_files=$ac_clean_files_save
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
-$as_echo_n "checking for suffix of object files... " >&6; }
-if ${ac_cv_objext+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-rm -f conftest.o conftest.obj
-if { { ac_try="$ac_compile"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_compile") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then :
- for ac_file in conftest.o conftest.obj conftest.*; do
- test -f "$ac_file" || continue;
- case $ac_file in
- *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
- *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
- break;;
- esac
-done
-else
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "cannot compute suffix of object files: cannot compile
-See \`config.log' for more details" "$LINENO" 5; }
-fi
-rm -f conftest.$ac_cv_objext conftest.$ac_ext
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
-$as_echo "$ac_cv_objext" >&6; }
-OBJEXT=$ac_cv_objext
-ac_objext=$OBJEXT
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
-$as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
-if ${ac_cv_c_compiler_gnu+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-#ifndef __GNUC__
- choke me
-#endif
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_compiler_gnu=yes
-else
- ac_compiler_gnu=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-ac_cv_c_compiler_gnu=$ac_compiler_gnu
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
-$as_echo "$ac_cv_c_compiler_gnu" >&6; }
-if test $ac_compiler_gnu = yes; then
- GCC=yes
-else
- GCC=
-fi
-ac_test_CFLAGS=${CFLAGS+set}
-ac_save_CFLAGS=$CFLAGS
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
-$as_echo_n "checking whether $CC accepts -g... " >&6; }
-if ${ac_cv_prog_cc_g+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_save_c_werror_flag=$ac_c_werror_flag
- ac_c_werror_flag=yes
- ac_cv_prog_cc_g=no
- CFLAGS="-g"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_prog_cc_g=yes
-else
- CFLAGS=""
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
-
-else
- ac_c_werror_flag=$ac_save_c_werror_flag
- CFLAGS="-g"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_prog_cc_g=yes
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- ac_c_werror_flag=$ac_save_c_werror_flag
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
-$as_echo "$ac_cv_prog_cc_g" >&6; }
-if test "$ac_test_CFLAGS" = set; then
- CFLAGS=$ac_save_CFLAGS
-elif test $ac_cv_prog_cc_g = yes; then
- if test "$GCC" = yes; then
- CFLAGS="-g -O2"
- else
- CFLAGS="-g"
- fi
-else
- if test "$GCC" = yes; then
- CFLAGS="-O2"
- else
- CFLAGS=
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
-$as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
-if ${ac_cv_prog_cc_c89+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_cv_prog_cc_c89=no
-ac_save_CC=$CC
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <stdarg.h>
-#include <stdio.h>
-struct stat;
-/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
-struct buf { int x; };
-FILE * (*rcsopen) (struct buf *, struct stat *, int);
-static char *e (p, i)
- char **p;
- int i;
-{
- return p[i];
-}
-static char *f (char * (*g) (char **, int), char **p, ...)
-{
- char *s;
- va_list v;
- va_start (v,p);
- s = g (p, va_arg (v,int));
- va_end (v);
- return s;
-}
-
-/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
- function prototypes and stuff, but not '\xHH' hex character constants.
- These don't provoke an error unfortunately, instead are silently treated
- as 'x'. The following induces an error, until -std is added to get
- proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
- array size at least. It's necessary to write '\x00'==0 to get something
- that's true only with -std. */
-int osf4_cc_array ['\x00' == 0 ? 1 : -1];
-
-/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
- inside strings and character constants. */
-#define FOO(x) 'x'
-int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
-
-int test (int i, double x);
-struct s1 {int (*f) (int a);};
-struct s2 {int (*f) (double a);};
-int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
-int argc;
-char **argv;
-int
-main ()
-{
-return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
- ;
- return 0;
-}
-_ACEOF
-for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
- -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
-do
- CC="$ac_save_CC $ac_arg"
- if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_prog_cc_c89=$ac_arg
-fi
-rm -f core conftest.err conftest.$ac_objext
- test "x$ac_cv_prog_cc_c89" != "xno" && break
-done
-rm -f conftest.$ac_ext
-CC=$ac_save_CC
-
-fi
-# AC_CACHE_VAL
-case "x$ac_cv_prog_cc_c89" in
- x)
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
-$as_echo "none needed" >&6; } ;;
- xno)
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
-$as_echo "unsupported" >&6; } ;;
- *)
- CC="$CC $ac_cv_prog_cc_c89"
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
-$as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
-esac
-if test "x$ac_cv_prog_cc_c89" != xno; then :
-
-fi
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC understands -c and -o together" >&5
-$as_echo_n "checking whether $CC understands -c and -o together... " >&6; }
-if ${am_cv_prog_cc_c_o+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
- # Make sure it works both with $CC and with simple cc.
- # Following AC_PROG_CC_C_O, we do the test twice because some
- # compilers refuse to overwrite an existing .o file with -o,
- # though they will create one.
- am_cv_prog_cc_c_o=yes
- for am_i in 1 2; do
- if { echo "$as_me:$LINENO: $CC -c conftest.$ac_ext -o conftest2.$ac_objext" >&5
- ($CC -c conftest.$ac_ext -o conftest2.$ac_objext) >&5 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } \
- && test -f conftest2.$ac_objext; then
- : OK
- else
- am_cv_prog_cc_c_o=no
- break
- fi
- done
- rm -f core conftest*
- unset am_i
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_cc_c_o" >&5
-$as_echo "$am_cv_prog_cc_c_o" >&6; }
-if test "$am_cv_prog_cc_c_o" != yes; then
- # Losing compiler, so override with the script.
- # FIXME: It is wrong to rewrite CC.
- # But if we don't then we get into trouble of one sort or another.
- # A longer-term fix would be to have automake use am__CC in this case,
- # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
- CC="$am_aux_dir/compile $CC"
-fi
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-
-depcc="$CC" am_compiler_list=
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
-$as_echo_n "checking dependency style of $depcc... " >&6; }
-if ${am_cv_CC_dependencies_compiler_type+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
- # We make a subdir and do the tests there. Otherwise we can end up
- # making bogus files that we don't know about and never remove. For
- # instance it was reported that on HP-UX the gcc test will end up
- # making a dummy file named 'D' -- because '-MD' means "put the output
- # in D".
- rm -rf conftest.dir
- mkdir conftest.dir
- # Copy depcomp to subdir because otherwise we won't find it if we're
- # using a relative directory.
- cp "$am_depcomp" conftest.dir
- cd conftest.dir
- # We will build objects and dependencies in a subdirectory because
- # it helps to detect inapplicable dependency modes. For instance
- # both Tru64's cc and ICC support -MD to output dependencies as a
- # side effect of compilation, but ICC will put the dependencies in
- # the current directory while Tru64 will put them in the object
- # directory.
- mkdir sub
-
- am_cv_CC_dependencies_compiler_type=none
- if test "$am_compiler_list" = ""; then
- am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
- fi
- am__universal=false
- case " $depcc " in #(
- *\ -arch\ *\ -arch\ *) am__universal=true ;;
- esac
-
- for depmode in $am_compiler_list; do
- # Setup a source with many dependencies, because some compilers
- # like to wrap large dependency lists on column 80 (with \), and
- # we should not choose a depcomp mode which is confused by this.
- #
- # We need to recreate these files for each test, as the compiler may
- # overwrite some of them when testing with obscure command lines.
- # This happens at least with the AIX C compiler.
- : > sub/conftest.c
- for i in 1 2 3 4 5 6; do
- echo '#include "conftst'$i'.h"' >> sub/conftest.c
- # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with
- # Solaris 10 /bin/sh.
- echo '/* dummy */' > sub/conftst$i.h
- done
- echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
-
- # We check with '-c' and '-o' for the sake of the "dashmstdout"
- # mode. It turns out that the SunPro C++ compiler does not properly
- # handle '-M -o', and we need to detect this. Also, some Intel
- # versions had trouble with output in subdirs.
- am__obj=sub/conftest.${OBJEXT-o}
- am__minus_obj="-o $am__obj"
- case $depmode in
- gcc)
- # This depmode causes a compiler race in universal mode.
- test "$am__universal" = false || continue
- ;;
- nosideeffect)
- # After this tag, mechanisms are not by side-effect, so they'll
- # only be used when explicitly requested.
- if test "x$enable_dependency_tracking" = xyes; then
- continue
- else
- break
- fi
- ;;
- msvc7 | msvc7msys | msvisualcpp | msvcmsys)
- # This compiler won't grok '-c -o', but also, the minuso test has
- # not run yet. These depmodes are late enough in the game, and
- # so weak that their functioning should not be impacted.
- am__obj=conftest.${OBJEXT-o}
- am__minus_obj=
- ;;
- none) break ;;
- esac
- if depmode=$depmode \
- source=sub/conftest.c object=$am__obj \
- depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
- $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
- >/dev/null 2>conftest.err &&
- grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
- grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
- grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
- ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
- # icc doesn't choke on unknown options, it will just issue warnings
- # or remarks (even with -Werror). So we grep stderr for any message
- # that says an option was ignored or not supported.
- # When given -MP, icc 7.0 and 7.1 complain thusly:
- # icc: Command line warning: ignoring option '-M'; no argument required
- # The diagnosis changed in icc 8.0:
- # icc: Command line remark: option '-MP' not supported
- if (grep 'ignoring option' conftest.err ||
- grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
- am_cv_CC_dependencies_compiler_type=$depmode
- break
- fi
- fi
- done
-
- cd ..
- rm -rf conftest.dir
-else
- am_cv_CC_dependencies_compiler_type=none
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
-$as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
-CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
-
- if
- test "x$enable_dependency_tracking" != xno \
- && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
- am__fastdepCC_TRUE=
- am__fastdepCC_FALSE='#'
-else
- am__fastdepCC_TRUE='#'
- am__fastdepCC_FALSE=
-fi
-
-
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
-$as_echo_n "checking how to run the C preprocessor... " >&6; }
-# On Suns, sometimes $CPP names a directory.
-if test -n "$CPP" && test -d "$CPP"; then
- CPP=
-fi
-if test -z "$CPP"; then
- if ${ac_cv_prog_CPP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- # Double quotes because CPP needs to be expanded
- for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
- do
- ac_preproc_ok=false
-for ac_c_preproc_warn_flag in '' yes
-do
- # Use a header file that comes with gcc, so configuring glibc
- # with a fresh cross-compiler works.
- # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
- # <limits.h> exists even on freestanding compilers.
- # On the NeXT, cc -E runs the code through the compiler's parser,
- # not just through cpp. "Syntax error" is here to catch this case.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#ifdef __STDC__
-# include <limits.h>
-#else
-# include <assert.h>
-#endif
- Syntax error
-_ACEOF
-if ac_fn_c_try_cpp "$LINENO"; then :
-
-else
- # Broken: fails on valid input.
-continue
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-
- # OK, works on sane cases. Now check whether nonexistent headers
- # can be detected and how.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <ac_nonexistent.h>
-_ACEOF
-if ac_fn_c_try_cpp "$LINENO"; then :
- # Broken: success on invalid input.
-continue
-else
- # Passes both tests.
-ac_preproc_ok=:
-break
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-
-done
-# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
-rm -f conftest.i conftest.err conftest.$ac_ext
-if $ac_preproc_ok; then :
- break
-fi
-
- done
- ac_cv_prog_CPP=$CPP
-
-fi
- CPP=$ac_cv_prog_CPP
-else
- ac_cv_prog_CPP=$CPP
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
-$as_echo "$CPP" >&6; }
-ac_preproc_ok=false
-for ac_c_preproc_warn_flag in '' yes
-do
- # Use a header file that comes with gcc, so configuring glibc
- # with a fresh cross-compiler works.
- # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
- # <limits.h> exists even on freestanding compilers.
- # On the NeXT, cc -E runs the code through the compiler's parser,
- # not just through cpp. "Syntax error" is here to catch this case.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#ifdef __STDC__
-# include <limits.h>
-#else
-# include <assert.h>
-#endif
- Syntax error
-_ACEOF
-if ac_fn_c_try_cpp "$LINENO"; then :
-
-else
- # Broken: fails on valid input.
-continue
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-
- # OK, works on sane cases. Now check whether nonexistent headers
- # can be detected and how.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <ac_nonexistent.h>
-_ACEOF
-if ac_fn_c_try_cpp "$LINENO"; then :
- # Broken: success on invalid input.
-continue
-else
- # Passes both tests.
-ac_preproc_ok=:
-break
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-
-done
-# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
-rm -f conftest.i conftest.err conftest.$ac_ext
-if $ac_preproc_ok; then :
-
-else
- { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
-See \`config.log' for more details" "$LINENO" 5; }
-fi
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
-$as_echo_n "checking for grep that handles long lines and -e... " >&6; }
-if ${ac_cv_path_GREP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -z "$GREP"; then
- ac_path_GREP_found=false
- # Loop through the user's path and test for each of PROGNAME-LIST
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_prog in grep ggrep; do
- for ac_exec_ext in '' $ac_executable_extensions; do
- ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
- as_fn_executable_p "$ac_path_GREP" || continue
-# Check for GNU ac_path_GREP and select it if it is found.
- # Check for GNU $ac_path_GREP
-case `"$ac_path_GREP" --version 2>&1` in
-*GNU*)
- ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
-*)
- ac_count=0
- $as_echo_n 0123456789 >"conftest.in"
- while :
- do
- cat "conftest.in" "conftest.in" >"conftest.tmp"
- mv "conftest.tmp" "conftest.in"
- cp "conftest.in" "conftest.nl"
- $as_echo 'GREP' >> "conftest.nl"
- "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
- diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
- as_fn_arith $ac_count + 1 && ac_count=$as_val
- if test $ac_count -gt ${ac_path_GREP_max-0}; then
- # Best one so far, save it but keep looking for a better one
- ac_cv_path_GREP="$ac_path_GREP"
- ac_path_GREP_max=$ac_count
- fi
- # 10*(2^10) chars as input seems more than enough
- test $ac_count -gt 10 && break
- done
- rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
-esac
-
- $ac_path_GREP_found && break 3
- done
- done
- done
-IFS=$as_save_IFS
- if test -z "$ac_cv_path_GREP"; then
- as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
- fi
-else
- ac_cv_path_GREP=$GREP
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
-$as_echo "$ac_cv_path_GREP" >&6; }
- GREP="$ac_cv_path_GREP"
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
-$as_echo_n "checking for egrep... " >&6; }
-if ${ac_cv_path_EGREP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
- then ac_cv_path_EGREP="$GREP -E"
- else
- if test -z "$EGREP"; then
- ac_path_EGREP_found=false
- # Loop through the user's path and test for each of PROGNAME-LIST
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_prog in egrep; do
- for ac_exec_ext in '' $ac_executable_extensions; do
- ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
- as_fn_executable_p "$ac_path_EGREP" || continue
-# Check for GNU ac_path_EGREP and select it if it is found.
- # Check for GNU $ac_path_EGREP
-case `"$ac_path_EGREP" --version 2>&1` in
-*GNU*)
- ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
-*)
- ac_count=0
- $as_echo_n 0123456789 >"conftest.in"
- while :
- do
- cat "conftest.in" "conftest.in" >"conftest.tmp"
- mv "conftest.tmp" "conftest.in"
- cp "conftest.in" "conftest.nl"
- $as_echo 'EGREP' >> "conftest.nl"
- "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
- diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
- as_fn_arith $ac_count + 1 && ac_count=$as_val
- if test $ac_count -gt ${ac_path_EGREP_max-0}; then
- # Best one so far, save it but keep looking for a better one
- ac_cv_path_EGREP="$ac_path_EGREP"
- ac_path_EGREP_max=$ac_count
- fi
- # 10*(2^10) chars as input seems more than enough
- test $ac_count -gt 10 && break
- done
- rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
-esac
-
- $ac_path_EGREP_found && break 3
- done
- done
- done
-IFS=$as_save_IFS
- if test -z "$ac_cv_path_EGREP"; then
- as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
- fi
-else
- ac_cv_path_EGREP=$EGREP
-fi
-
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
-$as_echo "$ac_cv_path_EGREP" >&6; }
- EGREP="$ac_cv_path_EGREP"
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
-$as_echo_n "checking for ANSI C header files... " >&6; }
-if ${ac_cv_header_stdc+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <stdlib.h>
-#include <stdarg.h>
-#include <string.h>
-#include <float.h>
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_header_stdc=yes
-else
- ac_cv_header_stdc=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-
-if test $ac_cv_header_stdc = yes; then
- # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <string.h>
-
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "memchr" >/dev/null 2>&1; then :
-
-else
- ac_cv_header_stdc=no
-fi
-rm -f conftest*
-
-fi
-
-if test $ac_cv_header_stdc = yes; then
- # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <stdlib.h>
-
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "free" >/dev/null 2>&1; then :
-
-else
- ac_cv_header_stdc=no
-fi
-rm -f conftest*
-
-fi
-
-if test $ac_cv_header_stdc = yes; then
- # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
- if test "$cross_compiling" = yes; then :
- :
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <ctype.h>
-#include <stdlib.h>
-#if ((' ' & 0x0FF) == 0x020)
-# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
-# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
-#else
-# define ISLOWER(c) \
- (('a' <= (c) && (c) <= 'i') \
- || ('j' <= (c) && (c) <= 'r') \
- || ('s' <= (c) && (c) <= 'z'))
-# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
-#endif
-
-#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
-int
-main ()
-{
- int i;
- for (i = 0; i < 256; i++)
- if (XOR (islower (i), ISLOWER (i))
- || toupper (i) != TOUPPER (i))
- return 2;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_run "$LINENO"; then :
-
-else
- ac_cv_header_stdc=no
-fi
-rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
- conftest.$ac_objext conftest.beam conftest.$ac_ext
-fi
-
-fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
-$as_echo "$ac_cv_header_stdc" >&6; }
-if test $ac_cv_header_stdc = yes; then
-
-$as_echo "#define STDC_HEADERS 1" >>confdefs.h
-
-fi
-
-# On IRIX 5.3, sys/types and inttypes.h are conflicting.
-for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
- inttypes.h stdint.h unistd.h
-do :
- as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
-ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
-"
-if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
- cat >>confdefs.h <<_ACEOF
-#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
-_ACEOF
-
-fi
-
-done
-
-
-
- ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
-if test "x$ac_cv_header_minix_config_h" = xyes; then :
- MINIX=yes
-else
- MINIX=
-fi
-
-
- if test "$MINIX" = yes; then
-
-$as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
-
-
-$as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
-
-
-$as_echo "#define _MINIX 1" >>confdefs.h
-
- fi
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
-$as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
-if ${ac_cv_safe_to_define___extensions__+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-# define __EXTENSIONS__ 1
- $ac_includes_default
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_safe_to_define___extensions__=yes
-else
- ac_cv_safe_to_define___extensions__=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
-$as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
- test $ac_cv_safe_to_define___extensions__ = yes &&
- $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
-
- $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
-
- $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
-
- $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
-
- $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
-
-
-
-# PR 14072
-
-
-
-# Check whether --with-sysroot was given.
-if test "${with_sysroot+set}" = set; then :
- withval=$with_sysroot; sysroot=$withval
-else
- sysroot=no
-fi
-
-
-if test "$sysroot" = "yes"; then
- sysroot='${exec_prefix}/${target_alias}/sys-root'
-elif test "$sysroot" = "no"; then
- sysroot=
-fi
-
-sysroot_relocatable=0
-if test -n "$sysroot"; then
- case "$sysroot" in
- "${prefix}" | "${prefix}/"* | \
- "${exec_prefix}" | "${exec_prefix}/"* | \
- '${prefix}' | '${prefix}/'*| \
- '${exec_prefix}' | '${exec_prefix}/'*)
- sysroot_relocatable=1
- ;;
- esac
-fi
-
-
-cat >>confdefs.h <<_ACEOF
-#define TARGET_SYSTEM_ROOT "$sysroot"
-_ACEOF
-
-
-cat >>confdefs.h <<_ACEOF
-#define TARGET_SYSTEM_ROOT_RELOCATABLE $sysroot_relocatable
-_ACEOF
-
-
-
-installed_linker=ld.gold
-# Check whether --enable-gold was given.
-if test "${enable_gold+set}" = set; then :
- enableval=$enable_gold; case "${enableval}" in
- default)
- install_as_default=yes
- ;;
- yes)
- if test x${enable_ld} = xno; then
- install_as_default=yes
- fi
- ;;
- esac
-else
- install_as_default=no
-fi
-
-
-
-
-
- maybe_plugins=no
- for ac_header in dlfcn.h
-do :
- ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default
-"
-if test "x$ac_cv_header_dlfcn_h" = xyes; then :
- cat >>confdefs.h <<_ACEOF
-#define HAVE_DLFCN_H 1
-_ACEOF
- maybe_plugins=yes
-fi
-
-done
-
- for ac_header in windows.h
-do :
- ac_fn_c_check_header_compile "$LINENO" "windows.h" "ac_cv_header_windows_h" "$ac_includes_default
-"
-if test "x$ac_cv_header_windows_h" = xyes; then :
- cat >>confdefs.h <<_ACEOF
-#define HAVE_WINDOWS_H 1
-_ACEOF
- maybe_plugins=yes
-fi
-
-done
-
-
- # Check whether --enable-plugins was given.
-if test "${enable_plugins+set}" = set; then :
- enableval=$enable_plugins; case "${enableval}" in
- no) plugins=no ;;
- *) plugins=yes
- if test "$maybe_plugins" != "yes" ; then
- as_fn_error $? "Building with plugin support requires a host that supports dlopen." "$LINENO" 5
- fi ;;
- esac
-else
- plugins=$maybe_plugins
-
-fi
-
- if test "$plugins" = "yes"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing dlsym" >&5
-$as_echo_n "checking for library containing dlsym... " >&6; }
-if ${ac_cv_search_dlsym+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_func_search_save_LIBS=$LIBS
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char dlsym ();
-int
-main ()
-{
-return dlsym ();
- ;
- return 0;
-}
-_ACEOF
-for ac_lib in '' dl; do
- if test -z "$ac_lib"; then
- ac_res="none required"
- else
- ac_res=-l$ac_lib
- LIBS="-l$ac_lib $ac_func_search_save_LIBS"
- fi
- if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_search_dlsym=$ac_res
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext
- if ${ac_cv_search_dlsym+:} false; then :
- break
-fi
-done
-if ${ac_cv_search_dlsym+:} false; then :
-
-else
- ac_cv_search_dlsym=no
-fi
-rm conftest.$ac_ext
-LIBS=$ac_func_search_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_dlsym" >&5
-$as_echo "$ac_cv_search_dlsym" >&6; }
-ac_res=$ac_cv_search_dlsym
-if test "$ac_res" != no; then :
- test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
-
-fi
-
- fi
-
-if test "$plugins" = "yes"; then
-
-$as_echo "#define ENABLE_PLUGINS 1" >>confdefs.h
-
-fi
- if test "$plugins" = "yes"; then
- PLUGINS_TRUE=
- PLUGINS_FALSE='#'
-else
- PLUGINS_TRUE='#'
- PLUGINS_FALSE=
-fi
-
-
-# Decide if -z relro should be enabled in ELF linker by default.
-ac_default_ld_z_relro=unset
-# Provide a configure time option to override our default.
-# Check whether --enable-relro was given.
-if test "${enable_relro+set}" = set; then :
- enableval=$enable_relro; case "${enableval}" in
- yes) ac_default_ld_z_relro=1 ;;
- no) ac_default_ld_z_relro=0 ;;
-esac
-fi
-if test "${ac_default_ld_z_relro}" = unset; then
- ac_default_ld_z_relro=1
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define DEFAULT_LD_Z_RELRO $ac_default_ld_z_relro
-_ACEOF
-
-
-# Check whether --enable-targets was given.
-if test "${enable_targets+set}" = set; then :
- enableval=$enable_targets; case "${enableval}" in
- yes | "")
- as_fn_error $? "--enable-targets option must specify target names or 'all'" "$LINENO" 5
- ;;
- no)
- enable_targets=
- ;;
- *)
- enable_targets=$enableval
- ;;
-esac
-else
- # For now, enable all targets by default
- enable_targets=all
-
-fi
-
-
-# Canonicalize the enabled targets.
-if test -n "$enable_targets"; then
- for targ in `echo $enable_targets | sed -e 's/,/ /g'`; do
- result=`$ac_config_sub $targ 2>/dev/null`
- if test -n "$result"; then
- canon_targets="$canon_targets $result"
- else
- # Permit unrecognized target names, like "all".
- canon_targets="$canon_targets $targ"
- fi
- done
-fi
-
-# Decide which "--hash-style" to use by default
-# Provide a configure time option to override our default.
-# Check whether --enable-default-hash-style was given.
-if test "${enable_default_hash_style+set}" = set; then :
- enableval=$enable_default_hash_style; case "${enable_default_hash_style}" in
- sysv | gnu | both) ;;
- *) as_fn_error $? "bad value ${enable_default_hash_style} for enable-default-hash-style option" "$LINENO" 5 ;;
-esac
-else
- case "${target}" in
- # Enable gnu hash only on GNU targets, but not mips
- mips*-*-*) enable_default_hash_style=sysv ;;
- *-*-gnu* | *-*-linux* | *-*-nacl*) enable_default_hash_style=both ;;
- *) enable_default_hash_style=sysv ;;
-esac
-fi
-
-
-
-cat >>confdefs.h <<_ACEOF
-#define DEFAULT_HASH_STYLE "${enable_default_hash_style}"
-_ACEOF
-
-
-# See which specific instantiations we need.
-targetobjs=
-all_targets=
-default_machine=
-default_size=
-default_big_endian=
-default_osabi=ELFOSABI_NONE
-targ_32_little=
-targ_32_big=
-targ_64_little=
-targ_64_big=
-for targ in $target $canon_targets; do
- if test "$targ" = "all"; then
- targ_32_little=yes
- targ_32_big=yes
- targ_64_little=yes
- targ_64_big=yes
- all_targets=yes
- else
- . ${srcdir}/configure.tgt
-
- if test "$targ_obj" = "UNKNOWN"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \"unsupported target $targ\"" >&5
-$as_echo "$as_me: WARNING: \"unsupported target $targ\"" >&2;}
- else
- targetobjs="$targetobjs ${targ_obj}.\$(OBJEXT)"
- if test "$targ_extra_obj" != ""; then
- targetobjs="$targetobjs ${targ_extra_obj}.\$(OBJEXT)"
- fi
- if test "$targ_size" = "32" -o "$targ_extra_size" = "32"; then
- if test "$targ_big_endian" = "true" \
- -o "$targ_extra_big_endian" = "true"; then
- targ_32_big=yes
- fi
- if test "$targ_big_endian" = "false" \
- -o "$targ_extra_big_endian" = "false"; then
- targ_32_little=yes
- fi
- fi
- if test "$targ_size" = "64" -o "$targ_extra_size" = "64"; then
- if test "$targ_big_endian" = "true" \
- -o "$targ_extra_big_endian" = "true"; then
- targ_64_big=yes
- fi
- if test "$targ_big_endian" = "false" \
- -o "$targ_extra_big_endian" = "false"; then
- targ_64_little=yes
- fi
- fi
-
- if test "$target" = "$targ"; then
- default_machine=$targ_machine
- default_size=$targ_size
- default_big_endian=$targ_big_endian
- default_osabi=$targ_osabi
-
- if test "$targ_obj" = "aarch64"; then
- DEFAULT_TARGET_AARCH64_TRUE=
- DEFAULT_TARGET_AARCH64_FALSE='#'
-else
- DEFAULT_TARGET_AARCH64_TRUE='#'
- DEFAULT_TARGET_AARCH64_FALSE=
-fi
-
- if test "$targ_obj" = "arm"; then
- DEFAULT_TARGET_ARM_TRUE=
- DEFAULT_TARGET_ARM_FALSE='#'
-else
- DEFAULT_TARGET_ARM_TRUE='#'
- DEFAULT_TARGET_ARM_FALSE=
-fi
-
- if test "$targ_obj" = "i386"; then
- DEFAULT_TARGET_I386_TRUE=
- DEFAULT_TARGET_I386_FALSE='#'
-else
- DEFAULT_TARGET_I386_TRUE='#'
- DEFAULT_TARGET_I386_FALSE=
-fi
-
- if test "$targ_obj" = "powerpc"; then
- DEFAULT_TARGET_POWERPC_TRUE=
- DEFAULT_TARGET_POWERPC_FALSE='#'
-else
- DEFAULT_TARGET_POWERPC_TRUE='#'
- DEFAULT_TARGET_POWERPC_FALSE=
-fi
-
- if test "$targ_obj" = "sparc"; then
- DEFAULT_TARGET_SPARC_TRUE=
- DEFAULT_TARGET_SPARC_FALSE='#'
-else
- DEFAULT_TARGET_SPARC_TRUE='#'
- DEFAULT_TARGET_SPARC_FALSE=
-fi
-
- if test "$targ_obj" = "s390"; then
- DEFAULT_TARGET_S390_TRUE=
- DEFAULT_TARGET_S390_FALSE='#'
-else
- DEFAULT_TARGET_S390_TRUE='#'
- DEFAULT_TARGET_S390_FALSE=
-fi
-
- target_x86_64=no
- target_x32=no
- if test "$targ_obj" = "x86_64"; then
- case "$target" in
- x86_64*-linux-gnux32)
- target_x32=yes
- default_size=32
- ;;
- *)
- target_x86_64=yes
- ;;
- esac
- fi
- if test "$target_x86_64" = "yes"; then
- DEFAULT_TARGET_X86_64_TRUE=
- DEFAULT_TARGET_X86_64_FALSE='#'
-else
- DEFAULT_TARGET_X86_64_TRUE='#'
- DEFAULT_TARGET_X86_64_FALSE=
-fi
-
- if test "$target_x32" = "yes"; then
- DEFAULT_TARGET_X32_TRUE=
- DEFAULT_TARGET_X32_FALSE='#'
-else
- DEFAULT_TARGET_X32_TRUE='#'
- DEFAULT_TARGET_X32_FALSE=
-fi
-
- if test "$target_x86_64" = "yes" -o "$target_x32" = "yes"; then
- DEFAULT_TARGET_X86_64_OR_X32_TRUE=
- DEFAULT_TARGET_X86_64_OR_X32_FALSE='#'
-else
- DEFAULT_TARGET_X86_64_OR_X32_TRUE='#'
- DEFAULT_TARGET_X86_64_OR_X32_FALSE=
-fi
-
- if test "$targ_obj" = "tilegx"; then
- DEFAULT_TARGET_TILEGX_TRUE=
- DEFAULT_TARGET_TILEGX_FALSE='#'
-else
- DEFAULT_TARGET_TILEGX_TRUE='#'
- DEFAULT_TARGET_TILEGX_FALSE=
-fi
-
- if test "$targ_obj" = "mips"; then
- DEFAULT_TARGET_MIPS_TRUE=
- DEFAULT_TARGET_MIPS_FALSE='#'
-else
- DEFAULT_TARGET_MIPS_TRUE='#'
- DEFAULT_TARGET_MIPS_FALSE=
-fi
-
- DEFAULT_TARGET=${targ_obj}
-
- fi
- fi
- fi
-done
-
-# Remove any duplicates.
-to=""
-for t in $targetobjs; do
- case " $to " in
- *" $t "*) ;;
- *) to="$to $t" ;;
- esac
-done
-targetobjs=$to
-
-if test -n "$targ_32_little"; then
-
-$as_echo "#define HAVE_TARGET_32_LITTLE 1" >>confdefs.h
-
-fi
-if test -n "$targ_32_big"; then
-
-$as_echo "#define HAVE_TARGET_32_BIG 1" >>confdefs.h
-
-fi
-if test -n "$targ_64_little"; then
-
-$as_echo "#define HAVE_TARGET_64_LITTLE 1" >>confdefs.h
-
-fi
-if test -n "$targ_64_big"; then
-
-$as_echo "#define HAVE_TARGET_64_BIG 1" >>confdefs.h
-
-fi
-
-if test -n "$all_targets"; then
- TARGETOBJS='$(ALL_TARGETOBJS)'
-else
- TARGETOBJS="$targetobjs"
-fi
-
-
-
-cat >>confdefs.h <<_ACEOF
-#define GOLD_DEFAULT_MACHINE $default_machine
-_ACEOF
-
-
-cat >>confdefs.h <<_ACEOF
-#define GOLD_DEFAULT_SIZE $default_size
-_ACEOF
-
-
-cat >>confdefs.h <<_ACEOF
-#define GOLD_DEFAULT_BIG_ENDIAN $default_big_endian
-_ACEOF
-
-
-cat >>confdefs.h <<_ACEOF
-#define GOLD_DEFAULT_OSABI $default_osabi
-_ACEOF
-
-
-
-# Check whether --with-lib-path was given.
-if test "${with_lib_path+set}" = set; then :
- withval=$with_lib_path; case "$withval" in
- yes) LIB_PATH='"/lib:/usr/lib"' ;;
- no) LIB_PATH='""' ;;
- *) LIB_PATH='"'"$withval"'"' ;;
- esac
-else
- LIB_PATH='"::DEFAULT::"'
-fi
-
-
-cat >>confdefs.h <<_ACEOF
-#define LIB_PATH $LIB_PATH
-_ACEOF
-
-if test "x$target_alias" = "x" -o "x$host_alias" = "x$target_alias"; then
-
-$as_echo "#define NATIVE_LINKER 1" >>confdefs.h
-
-fi
-
-if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}nm", so it can be a program name with args.
-set dummy ${ac_tool_prefix}nm; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_NM+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$NM"; then
- ac_cv_prog_NM="$NM" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_NM="${ac_tool_prefix}nm"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-NM=$ac_cv_prog_NM
-if test -n "$NM"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5
-$as_echo "$NM" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_NM"; then
- ac_ct_NM=$NM
- # Extract the first word of "nm", so it can be a program name with args.
-set dummy nm; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_NM+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_NM"; then
- ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_NM="nm"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_NM=$ac_cv_prog_ac_ct_NM
-if test -n "$ac_ct_NM"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NM" >&5
-$as_echo "$ac_ct_NM" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_NM" = x; then
- NM=""
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- NM=$ac_ct_NM
- fi
-else
- NM="$ac_cv_prog_NM"
-fi
-
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
-set dummy ${ac_tool_prefix}gcc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_CC="${ac_tool_prefix}gcc"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
-$as_echo "$CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_CC"; then
- ac_ct_CC=$CC
- # Extract the first word of "gcc", so it can be a program name with args.
-set dummy gcc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_CC"; then
- ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_CC="gcc"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_CC=$ac_cv_prog_ac_ct_CC
-if test -n "$ac_ct_CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
-$as_echo "$ac_ct_CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_CC" = x; then
- CC=""
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- CC=$ac_ct_CC
- fi
-else
- CC="$ac_cv_prog_CC"
-fi
-
-if test -z "$CC"; then
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
-set dummy ${ac_tool_prefix}cc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_CC="${ac_tool_prefix}cc"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
-$as_echo "$CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
-fi
-if test -z "$CC"; then
- # Extract the first word of "cc", so it can be a program name with args.
-set dummy cc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
- ac_prog_rejected=no
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
- ac_prog_rejected=yes
- continue
- fi
- ac_cv_prog_CC="cc"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-if test $ac_prog_rejected = yes; then
- # We found a bogon in the path, so make sure we never use it.
- set dummy $ac_cv_prog_CC
- shift
- if test $# != 0; then
- # We chose a different compiler from the bogus one.
- # However, it has the same basename, so the bogon will be chosen
- # first if we set CC to just the basename; use the full file name.
- shift
- ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
- fi
-fi
-fi
-fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
-$as_echo "$CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$CC"; then
- if test -n "$ac_tool_prefix"; then
- for ac_prog in cl.exe
- do
- # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
-set dummy $ac_tool_prefix$ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
-$as_echo "$CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$CC" && break
- done
-fi
-if test -z "$CC"; then
- ac_ct_CC=$CC
- for ac_prog in cl.exe
-do
- # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_CC"; then
- ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_CC="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_CC=$ac_cv_prog_ac_ct_CC
-if test -n "$ac_ct_CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
-$as_echo "$ac_ct_CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$ac_ct_CC" && break
-done
-
- if test "x$ac_ct_CC" = x; then
- CC=""
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- CC=$ac_ct_CC
- fi
-fi
-
-fi
-
-
-test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "no acceptable C compiler found in \$PATH
-See \`config.log' for more details" "$LINENO" 5; }
-
-# Provide some information about the compiler.
-$as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
-set X $ac_compile
-ac_compiler=$2
-for ac_option in --version -v -V -qversion; do
- { { ac_try="$ac_compiler $ac_option >&5"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_compiler $ac_option >&5") 2>conftest.err
- ac_status=$?
- if test -s conftest.err; then
- sed '10a\
-... rest of stderr output deleted ...
- 10q' conftest.err >conftest.er1
- cat conftest.er1 >&5
- fi
- rm -f conftest.er1 conftest.err
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }
-done
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
-$as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
-if ${ac_cv_c_compiler_gnu+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-#ifndef __GNUC__
- choke me
-#endif
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_compiler_gnu=yes
-else
- ac_compiler_gnu=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-ac_cv_c_compiler_gnu=$ac_compiler_gnu
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
-$as_echo "$ac_cv_c_compiler_gnu" >&6; }
-if test $ac_compiler_gnu = yes; then
- GCC=yes
-else
- GCC=
-fi
-ac_test_CFLAGS=${CFLAGS+set}
-ac_save_CFLAGS=$CFLAGS
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
-$as_echo_n "checking whether $CC accepts -g... " >&6; }
-if ${ac_cv_prog_cc_g+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_save_c_werror_flag=$ac_c_werror_flag
- ac_c_werror_flag=yes
- ac_cv_prog_cc_g=no
- CFLAGS="-g"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_prog_cc_g=yes
-else
- CFLAGS=""
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
-
-else
- ac_c_werror_flag=$ac_save_c_werror_flag
- CFLAGS="-g"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_prog_cc_g=yes
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- ac_c_werror_flag=$ac_save_c_werror_flag
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
-$as_echo "$ac_cv_prog_cc_g" >&6; }
-if test "$ac_test_CFLAGS" = set; then
- CFLAGS=$ac_save_CFLAGS
-elif test $ac_cv_prog_cc_g = yes; then
- if test "$GCC" = yes; then
- CFLAGS="-g -O2"
- else
- CFLAGS="-g"
- fi
-else
- if test "$GCC" = yes; then
- CFLAGS="-O2"
- else
- CFLAGS=
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
-$as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
-if ${ac_cv_prog_cc_c89+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_cv_prog_cc_c89=no
-ac_save_CC=$CC
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <stdarg.h>
-#include <stdio.h>
-struct stat;
-/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
-struct buf { int x; };
-FILE * (*rcsopen) (struct buf *, struct stat *, int);
-static char *e (p, i)
- char **p;
- int i;
-{
- return p[i];
-}
-static char *f (char * (*g) (char **, int), char **p, ...)
-{
- char *s;
- va_list v;
- va_start (v,p);
- s = g (p, va_arg (v,int));
- va_end (v);
- return s;
-}
-
-/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
- function prototypes and stuff, but not '\xHH' hex character constants.
- These don't provoke an error unfortunately, instead are silently treated
- as 'x'. The following induces an error, until -std is added to get
- proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
- array size at least. It's necessary to write '\x00'==0 to get something
- that's true only with -std. */
-int osf4_cc_array ['\x00' == 0 ? 1 : -1];
-
-/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
- inside strings and character constants. */
-#define FOO(x) 'x'
-int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
-
-int test (int i, double x);
-struct s1 {int (*f) (int a);};
-struct s2 {int (*f) (double a);};
-int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
-int argc;
-char **argv;
-int
-main ()
-{
-return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
- ;
- return 0;
-}
-_ACEOF
-for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
- -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
-do
- CC="$ac_save_CC $ac_arg"
- if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_prog_cc_c89=$ac_arg
-fi
-rm -f core conftest.err conftest.$ac_objext
- test "x$ac_cv_prog_cc_c89" != "xno" && break
-done
-rm -f conftest.$ac_ext
-CC=$ac_save_CC
-
-fi
-# AC_CACHE_VAL
-case "x$ac_cv_prog_cc_c89" in
- x)
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
-$as_echo "none needed" >&6; } ;;
- xno)
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
-$as_echo "unsupported" >&6; } ;;
- *)
- CC="$CC $ac_cv_prog_cc_c89"
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
-$as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
-esac
-if test "x$ac_cv_prog_cc_c89" != xno; then :
-
-fi
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC understands -c and -o together" >&5
-$as_echo_n "checking whether $CC understands -c and -o together... " >&6; }
-if ${am_cv_prog_cc_c_o+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
- # Make sure it works both with $CC and with simple cc.
- # Following AC_PROG_CC_C_O, we do the test twice because some
- # compilers refuse to overwrite an existing .o file with -o,
- # though they will create one.
- am_cv_prog_cc_c_o=yes
- for am_i in 1 2; do
- if { echo "$as_me:$LINENO: $CC -c conftest.$ac_ext -o conftest2.$ac_objext" >&5
- ($CC -c conftest.$ac_ext -o conftest2.$ac_objext) >&5 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } \
- && test -f conftest2.$ac_objext; then
- : OK
- else
- am_cv_prog_cc_c_o=no
- break
- fi
- done
- rm -f core conftest*
- unset am_i
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_cc_c_o" >&5
-$as_echo "$am_cv_prog_cc_c_o" >&6; }
-if test "$am_cv_prog_cc_c_o" != yes; then
- # Losing compiler, so override with the script.
- # FIXME: It is wrong to rewrite CC.
- # But if we don't then we get into trouble of one sort or another.
- # A longer-term fix would be to have automake use am__CC in this case,
- # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
- CC="$am_aux_dir/compile $CC"
-fi
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-
-depcc="$CC" am_compiler_list=
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
-$as_echo_n "checking dependency style of $depcc... " >&6; }
-if ${am_cv_CC_dependencies_compiler_type+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
- # We make a subdir and do the tests there. Otherwise we can end up
- # making bogus files that we don't know about and never remove. For
- # instance it was reported that on HP-UX the gcc test will end up
- # making a dummy file named 'D' -- because '-MD' means "put the output
- # in D".
- rm -rf conftest.dir
- mkdir conftest.dir
- # Copy depcomp to subdir because otherwise we won't find it if we're
- # using a relative directory.
- cp "$am_depcomp" conftest.dir
- cd conftest.dir
- # We will build objects and dependencies in a subdirectory because
- # it helps to detect inapplicable dependency modes. For instance
- # both Tru64's cc and ICC support -MD to output dependencies as a
- # side effect of compilation, but ICC will put the dependencies in
- # the current directory while Tru64 will put them in the object
- # directory.
- mkdir sub
-
- am_cv_CC_dependencies_compiler_type=none
- if test "$am_compiler_list" = ""; then
- am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
- fi
- am__universal=false
- case " $depcc " in #(
- *\ -arch\ *\ -arch\ *) am__universal=true ;;
- esac
-
- for depmode in $am_compiler_list; do
- # Setup a source with many dependencies, because some compilers
- # like to wrap large dependency lists on column 80 (with \), and
- # we should not choose a depcomp mode which is confused by this.
- #
- # We need to recreate these files for each test, as the compiler may
- # overwrite some of them when testing with obscure command lines.
- # This happens at least with the AIX C compiler.
- : > sub/conftest.c
- for i in 1 2 3 4 5 6; do
- echo '#include "conftst'$i'.h"' >> sub/conftest.c
- # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with
- # Solaris 10 /bin/sh.
- echo '/* dummy */' > sub/conftst$i.h
- done
- echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
-
- # We check with '-c' and '-o' for the sake of the "dashmstdout"
- # mode. It turns out that the SunPro C++ compiler does not properly
- # handle '-M -o', and we need to detect this. Also, some Intel
- # versions had trouble with output in subdirs.
- am__obj=sub/conftest.${OBJEXT-o}
- am__minus_obj="-o $am__obj"
- case $depmode in
- gcc)
- # This depmode causes a compiler race in universal mode.
- test "$am__universal" = false || continue
- ;;
- nosideeffect)
- # After this tag, mechanisms are not by side-effect, so they'll
- # only be used when explicitly requested.
- if test "x$enable_dependency_tracking" = xyes; then
- continue
- else
- break
- fi
- ;;
- msvc7 | msvc7msys | msvisualcpp | msvcmsys)
- # This compiler won't grok '-c -o', but also, the minuso test has
- # not run yet. These depmodes are late enough in the game, and
- # so weak that their functioning should not be impacted.
- am__obj=conftest.${OBJEXT-o}
- am__minus_obj=
- ;;
- none) break ;;
- esac
- if depmode=$depmode \
- source=sub/conftest.c object=$am__obj \
- depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
- $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
- >/dev/null 2>conftest.err &&
- grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
- grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
- grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
- ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
- # icc doesn't choke on unknown options, it will just issue warnings
- # or remarks (even with -Werror). So we grep stderr for any message
- # that says an option was ignored or not supported.
- # When given -MP, icc 7.0 and 7.1 complain thusly:
- # icc: Command line warning: ignoring option '-M'; no argument required
- # The diagnosis changed in icc 8.0:
- # icc: Command line remark: option '-MP' not supported
- if (grep 'ignoring option' conftest.err ||
- grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
- am_cv_CC_dependencies_compiler_type=$depmode
- break
- fi
- fi
- done
-
- cd ..
- rm -rf conftest.dir
-else
- am_cv_CC_dependencies_compiler_type=none
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
-$as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
-CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
-
- if
- test "x$enable_dependency_tracking" != xno \
- && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
- am__fastdepCC_TRUE=
- am__fastdepCC_FALSE='#'
-else
- am__fastdepCC_TRUE='#'
- am__fastdepCC_FALSE=
-fi
-
-
-ac_ext=cpp
-ac_cpp='$CXXCPP $CPPFLAGS'
-ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
-if test -z "$CXX"; then
- if test -n "$CCC"; then
- CXX=$CCC
- else
- if test -n "$ac_tool_prefix"; then
- for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC
- do
- # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
-set dummy $ac_tool_prefix$ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CXX+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$CXX"; then
- ac_cv_prog_CXX="$CXX" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_CXX="$ac_tool_prefix$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-CXX=$ac_cv_prog_CXX
-if test -n "$CXX"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5
-$as_echo "$CXX" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$CXX" && break
- done
-fi
-if test -z "$CXX"; then
- ac_ct_CXX=$CXX
- for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC
-do
- # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_CXX+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_CXX"; then
- ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_CXX="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_CXX=$ac_cv_prog_ac_ct_CXX
-if test -n "$ac_ct_CXX"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5
-$as_echo "$ac_ct_CXX" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$ac_ct_CXX" && break
-done
-
- if test "x$ac_ct_CXX" = x; then
- CXX="g++"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- CXX=$ac_ct_CXX
- fi
-fi
-
- fi
-fi
-# Provide some information about the compiler.
-$as_echo "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5
-set X $ac_compile
-ac_compiler=$2
-for ac_option in --version -v -V -qversion; do
- { { ac_try="$ac_compiler $ac_option >&5"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_compiler $ac_option >&5") 2>conftest.err
- ac_status=$?
- if test -s conftest.err; then
- sed '10a\
-... rest of stderr output deleted ...
- 10q' conftest.err >conftest.er1
- cat conftest.er1 >&5
- fi
- rm -f conftest.er1 conftest.err
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }
-done
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C++ compiler" >&5
-$as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; }
-if ${ac_cv_cxx_compiler_gnu+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-#ifndef __GNUC__
- choke me
-#endif
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_cxx_try_compile "$LINENO"; then :
- ac_compiler_gnu=yes
-else
- ac_compiler_gnu=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-ac_cv_cxx_compiler_gnu=$ac_compiler_gnu
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5
-$as_echo "$ac_cv_cxx_compiler_gnu" >&6; }
-if test $ac_compiler_gnu = yes; then
- GXX=yes
-else
- GXX=
-fi
-ac_test_CXXFLAGS=${CXXFLAGS+set}
-ac_save_CXXFLAGS=$CXXFLAGS
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5
-$as_echo_n "checking whether $CXX accepts -g... " >&6; }
-if ${ac_cv_prog_cxx_g+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_save_cxx_werror_flag=$ac_cxx_werror_flag
- ac_cxx_werror_flag=yes
- ac_cv_prog_cxx_g=no
- CXXFLAGS="-g"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_cxx_try_compile "$LINENO"; then :
- ac_cv_prog_cxx_g=yes
-else
- CXXFLAGS=""
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_cxx_try_compile "$LINENO"; then :
-
-else
- ac_cxx_werror_flag=$ac_save_cxx_werror_flag
- CXXFLAGS="-g"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_cxx_try_compile "$LINENO"; then :
- ac_cv_prog_cxx_g=yes
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- ac_cxx_werror_flag=$ac_save_cxx_werror_flag
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5
-$as_echo "$ac_cv_prog_cxx_g" >&6; }
-if test "$ac_test_CXXFLAGS" = set; then
- CXXFLAGS=$ac_save_CXXFLAGS
-elif test $ac_cv_prog_cxx_g = yes; then
- if test "$GXX" = yes; then
- CXXFLAGS="-g -O2"
- else
- CXXFLAGS="-g"
- fi
-else
- if test "$GXX" = yes; then
- CXXFLAGS="-O2"
- else
- CXXFLAGS=
- fi
-fi
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-depcc="$CXX" am_compiler_list=
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
-$as_echo_n "checking dependency style of $depcc... " >&6; }
-if ${am_cv_CXX_dependencies_compiler_type+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
- # We make a subdir and do the tests there. Otherwise we can end up
- # making bogus files that we don't know about and never remove. For
- # instance it was reported that on HP-UX the gcc test will end up
- # making a dummy file named 'D' -- because '-MD' means "put the output
- # in D".
- rm -rf conftest.dir
- mkdir conftest.dir
- # Copy depcomp to subdir because otherwise we won't find it if we're
- # using a relative directory.
- cp "$am_depcomp" conftest.dir
- cd conftest.dir
- # We will build objects and dependencies in a subdirectory because
- # it helps to detect inapplicable dependency modes. For instance
- # both Tru64's cc and ICC support -MD to output dependencies as a
- # side effect of compilation, but ICC will put the dependencies in
- # the current directory while Tru64 will put them in the object
- # directory.
- mkdir sub
-
- am_cv_CXX_dependencies_compiler_type=none
- if test "$am_compiler_list" = ""; then
- am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
- fi
- am__universal=false
- case " $depcc " in #(
- *\ -arch\ *\ -arch\ *) am__universal=true ;;
- esac
-
- for depmode in $am_compiler_list; do
- # Setup a source with many dependencies, because some compilers
- # like to wrap large dependency lists on column 80 (with \), and
- # we should not choose a depcomp mode which is confused by this.
- #
- # We need to recreate these files for each test, as the compiler may
- # overwrite some of them when testing with obscure command lines.
- # This happens at least with the AIX C compiler.
- : > sub/conftest.c
- for i in 1 2 3 4 5 6; do
- echo '#include "conftst'$i'.h"' >> sub/conftest.c
- # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with
- # Solaris 10 /bin/sh.
- echo '/* dummy */' > sub/conftst$i.h
- done
- echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
-
- # We check with '-c' and '-o' for the sake of the "dashmstdout"
- # mode. It turns out that the SunPro C++ compiler does not properly
- # handle '-M -o', and we need to detect this. Also, some Intel
- # versions had trouble with output in subdirs.
- am__obj=sub/conftest.${OBJEXT-o}
- am__minus_obj="-o $am__obj"
- case $depmode in
- gcc)
- # This depmode causes a compiler race in universal mode.
- test "$am__universal" = false || continue
- ;;
- nosideeffect)
- # After this tag, mechanisms are not by side-effect, so they'll
- # only be used when explicitly requested.
- if test "x$enable_dependency_tracking" = xyes; then
- continue
- else
- break
- fi
- ;;
- msvc7 | msvc7msys | msvisualcpp | msvcmsys)
- # This compiler won't grok '-c -o', but also, the minuso test has
- # not run yet. These depmodes are late enough in the game, and
- # so weak that their functioning should not be impacted.
- am__obj=conftest.${OBJEXT-o}
- am__minus_obj=
- ;;
- none) break ;;
- esac
- if depmode=$depmode \
- source=sub/conftest.c object=$am__obj \
- depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
- $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
- >/dev/null 2>conftest.err &&
- grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
- grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
- grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
- ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
- # icc doesn't choke on unknown options, it will just issue warnings
- # or remarks (even with -Werror). So we grep stderr for any message
- # that says an option was ignored or not supported.
- # When given -MP, icc 7.0 and 7.1 complain thusly:
- # icc: Command line warning: ignoring option '-M'; no argument required
- # The diagnosis changed in icc 8.0:
- # icc: Command line remark: option '-MP' not supported
- if (grep 'ignoring option' conftest.err ||
- grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
- am_cv_CXX_dependencies_compiler_type=$depmode
- break
- fi
- fi
- done
-
- cd ..
- rm -rf conftest.dir
-else
- am_cv_CXX_dependencies_compiler_type=none
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CXX_dependencies_compiler_type" >&5
-$as_echo "$am_cv_CXX_dependencies_compiler_type" >&6; }
-CXXDEPMODE=depmode=$am_cv_CXX_dependencies_compiler_type
-
- if
- test "x$enable_dependency_tracking" != xno \
- && test "$am_cv_CXX_dependencies_compiler_type" = gcc3; then
- am__fastdepCXX_TRUE=
- am__fastdepCXX_FALSE='#'
-else
- am__fastdepCXX_TRUE='#'
- am__fastdepCXX_FALSE=
-fi
-
-
-for ac_prog in 'bison -y' byacc
-do
- # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_YACC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$YACC"; then
- ac_cv_prog_YACC="$YACC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_YACC="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-YACC=$ac_cv_prog_YACC
-if test -n "$YACC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $YACC" >&5
-$as_echo "$YACC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$YACC" && break
-done
-test -n "$YACC" || YACC="yacc"
-
-if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
-set dummy ${ac_tool_prefix}ranlib; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_RANLIB+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$RANLIB"; then
- ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-RANLIB=$ac_cv_prog_RANLIB
-if test -n "$RANLIB"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
-$as_echo "$RANLIB" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_RANLIB"; then
- ac_ct_RANLIB=$RANLIB
- # Extract the first word of "ranlib", so it can be a program name with args.
-set dummy ranlib; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_RANLIB"; then
- ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_RANLIB="ranlib"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
-if test -n "$ac_ct_RANLIB"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
-$as_echo "$ac_ct_RANLIB" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_RANLIB" = x; then
- RANLIB=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- RANLIB=$ac_ct_RANLIB
- fi
-else
- RANLIB="$ac_cv_prog_RANLIB"
-fi
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
-$as_echo_n "checking whether ln -s works... " >&6; }
-LN_S=$as_ln_s
-if test "$LN_S" = "ln -s"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
-$as_echo "no, using $LN_S" >&6; }
-fi
-
-
-
- MKINSTALLDIRS=
- if test -n "$ac_aux_dir"; then
- case "$ac_aux_dir" in
- /*) MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs" ;;
- *) MKINSTALLDIRS="\$(top_builddir)/$ac_aux_dir/mkinstalldirs" ;;
- esac
- fi
- if test -z "$MKINSTALLDIRS"; then
- MKINSTALLDIRS="\$(top_srcdir)/mkinstalldirs"
- fi
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NLS is requested" >&5
-$as_echo_n "checking whether NLS is requested... " >&6; }
- # Check whether --enable-nls was given.
-if test "${enable_nls+set}" = set; then :
- enableval=$enable_nls; USE_NLS=$enableval
-else
- USE_NLS=yes
-fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_NLS" >&5
-$as_echo "$USE_NLS" >&6; }
-
-
-
-
-
-
-# Prepare PATH_SEPARATOR.
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-
-# Find out how to test for executable files. Don't use a zero-byte file,
-# as systems may use methods other than mode bits to determine executability.
-cat >conf$$.file <<_ASEOF
-#! /bin/sh
-exit 0
-_ASEOF
-chmod +x conf$$.file
-if test -x conf$$.file >/dev/null 2>&1; then
- ac_executable_p="test -x"
-else
- ac_executable_p="test -f"
-fi
-rm -f conf$$.file
-
-# Extract the first word of "msgfmt", so it can be a program name with args.
-set dummy msgfmt; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_MSGFMT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case "$MSGFMT" in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
- ;;
- *)
- ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH; do
- IFS="$ac_save_IFS"
- test -z "$ac_dir" && ac_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
- if $ac_dir/$ac_word --statistics /dev/null >/dev/null 2>&1 &&
- (if $ac_dir/$ac_word --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- ac_cv_path_MSGFMT="$ac_dir/$ac_word$ac_exec_ext"
- break 2
- fi
- fi
- done
- done
- IFS="$ac_save_IFS"
- test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT=":"
- ;;
-esac
-fi
-MSGFMT="$ac_cv_path_MSGFMT"
-if test "$MSGFMT" != ":"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGFMT" >&5
-$as_echo "$MSGFMT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- # Extract the first word of "gmsgfmt", so it can be a program name with args.
-set dummy gmsgfmt; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_GMSGFMT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $GMSGFMT in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
- ;;
- *)
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_path_GMSGFMT="$as_dir/$ac_word$ac_exec_ext"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
- test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT"
- ;;
-esac
-fi
-GMSGFMT=$ac_cv_path_GMSGFMT
-if test -n "$GMSGFMT"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GMSGFMT" >&5
-$as_echo "$GMSGFMT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-
-
-# Prepare PATH_SEPARATOR.
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-
-# Find out how to test for executable files. Don't use a zero-byte file,
-# as systems may use methods other than mode bits to determine executability.
-cat >conf$$.file <<_ASEOF
-#! /bin/sh
-exit 0
-_ASEOF
-chmod +x conf$$.file
-if test -x conf$$.file >/dev/null 2>&1; then
- ac_executable_p="test -x"
-else
- ac_executable_p="test -f"
-fi
-rm -f conf$$.file
-
-# Extract the first word of "xgettext", so it can be a program name with args.
-set dummy xgettext; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_XGETTEXT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case "$XGETTEXT" in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
- ;;
- *)
- ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH; do
- IFS="$ac_save_IFS"
- test -z "$ac_dir" && ac_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
- if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >/dev/null 2>&1 &&
- (if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- ac_cv_path_XGETTEXT="$ac_dir/$ac_word$ac_exec_ext"
- break 2
- fi
- fi
- done
- done
- IFS="$ac_save_IFS"
- test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":"
- ;;
-esac
-fi
-XGETTEXT="$ac_cv_path_XGETTEXT"
-if test "$XGETTEXT" != ":"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XGETTEXT" >&5
-$as_echo "$XGETTEXT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- rm -f messages.po
-
-
-# Prepare PATH_SEPARATOR.
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-
-# Find out how to test for executable files. Don't use a zero-byte file,
-# as systems may use methods other than mode bits to determine executability.
-cat >conf$$.file <<_ASEOF
-#! /bin/sh
-exit 0
-_ASEOF
-chmod +x conf$$.file
-if test -x conf$$.file >/dev/null 2>&1; then
- ac_executable_p="test -x"
-else
- ac_executable_p="test -f"
-fi
-rm -f conf$$.file
-
-# Extract the first word of "msgmerge", so it can be a program name with args.
-set dummy msgmerge; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_MSGMERGE+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case "$MSGMERGE" in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_MSGMERGE="$MSGMERGE" # Let the user override the test with a path.
- ;;
- *)
- ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH; do
- IFS="$ac_save_IFS"
- test -z "$ac_dir" && ac_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
- if $ac_dir/$ac_word --update -q /dev/null /dev/null >/dev/null 2>&1; then
- ac_cv_path_MSGMERGE="$ac_dir/$ac_word$ac_exec_ext"
- break 2
- fi
- fi
- done
- done
- IFS="$ac_save_IFS"
- test -z "$ac_cv_path_MSGMERGE" && ac_cv_path_MSGMERGE=":"
- ;;
-esac
-fi
-MSGMERGE="$ac_cv_path_MSGMERGE"
-if test "$MSGMERGE" != ":"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGMERGE" >&5
-$as_echo "$MSGMERGE" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- if test "$GMSGFMT" != ":"; then
- if $GMSGFMT --statistics /dev/null >/dev/null 2>&1 &&
- (if $GMSGFMT --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- : ;
- else
- GMSGFMT=`echo "$GMSGFMT" | sed -e 's,^.*/,,'`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: found $GMSGFMT program is not GNU msgfmt; ignore it" >&5
-$as_echo "found $GMSGFMT program is not GNU msgfmt; ignore it" >&6; }
- GMSGFMT=":"
- fi
- fi
-
- if test "$XGETTEXT" != ":"; then
- if $XGETTEXT --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >/dev/null 2>&1 &&
- (if $XGETTEXT --omit-header --copyright-holder= --msgid-bugs-address= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- : ;
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: found xgettext program is not GNU xgettext; ignore it" >&5
-$as_echo "found xgettext program is not GNU xgettext; ignore it" >&6; }
- XGETTEXT=":"
- fi
- rm -f messages.po
- fi
-
- ac_config_commands="$ac_config_commands default-1"
-
-
-
- if test "X$prefix" = "XNONE"; then
- acl_final_prefix="$ac_default_prefix"
- else
- acl_final_prefix="$prefix"
- fi
- if test "X$exec_prefix" = "XNONE"; then
- acl_final_exec_prefix='${prefix}'
- else
- acl_final_exec_prefix="$exec_prefix"
- fi
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- eval acl_final_exec_prefix=\"$acl_final_exec_prefix\"
- prefix="$acl_save_prefix"
-
-
-# Check whether --with-gnu-ld was given.
-if test "${with_gnu_ld+set}" = set; then :
- withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
-else
- with_gnu_ld=no
-fi
-
-# Prepare PATH_SEPARATOR.
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-ac_prog=ld
-if test "$GCC" = yes; then
- # Check if gcc -print-prog-name=ld gives a path.
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by GCC" >&5
-$as_echo_n "checking for ld used by GCC... " >&6; }
- case $host in
- *-*-mingw*)
- # gcc leaves a trailing carriage return which upsets mingw
- ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
- *)
- ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
- esac
- case $ac_prog in
- # Accept absolute paths.
- [\\/]* | [A-Za-z]:[\\/]*)
- re_direlt='/[^/][^/]*/\.\./'
- # Canonicalize the path of ld
- ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
- while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
- ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
- done
- test -z "$LD" && LD="$ac_prog"
- ;;
- "")
- # If it fails, then pretend we aren't using GCC.
- ac_prog=ld
- ;;
- *)
- # If it is relative, then search for the first ld in PATH.
- with_gnu_ld=unknown
- ;;
- esac
-elif test "$with_gnu_ld" = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
-$as_echo_n "checking for GNU ld... " >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
-$as_echo_n "checking for non-GNU ld... " >&6; }
-fi
-if ${acl_cv_path_LD+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -z "$LD"; then
- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
- for ac_dir in $PATH; do
- test -z "$ac_dir" && ac_dir=.
- if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
- acl_cv_path_LD="$ac_dir/$ac_prog"
- # Check to see if the program is GNU ld. I'd rather use --version,
- # but apparently some GNU ld's only accept -v.
- # Break only if it was the GNU/non-GNU ld that we prefer.
- if "$acl_cv_path_LD" -v 2>&1 < /dev/null | $EGREP '(GNU|with BFD)' > /dev/null; then
- test "$with_gnu_ld" != no && break
- else
- test "$with_gnu_ld" != yes && break
- fi
- fi
- done
- IFS="$ac_save_ifs"
-else
- acl_cv_path_LD="$LD" # Let the user override the test with a path.
-fi
-fi
-
-LD="$acl_cv_path_LD"
-if test -n "$LD"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
-$as_echo "$LD" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
-$as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
-if ${acl_cv_prog_gnu_ld+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- # I'd rather use --version here, but apparently some GNU ld's only accept -v.
-if $LD -v 2>&1 </dev/null | $EGREP '(GNU|with BFD)' 1>&5; then
- acl_cv_prog_gnu_ld=yes
-else
- acl_cv_prog_gnu_ld=no
-fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $acl_cv_prog_gnu_ld" >&5
-$as_echo "$acl_cv_prog_gnu_ld" >&6; }
-with_gnu_ld=$acl_cv_prog_gnu_ld
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shared library run path origin" >&5
-$as_echo_n "checking for shared library run path origin... " >&6; }
-if ${acl_cv_rpath+:} false; then :
- $as_echo_n "(cached) " >&6
-else
-
- CC="$CC" GCC="$GCC" LDFLAGS="$LDFLAGS" LD="$LD" with_gnu_ld="$with_gnu_ld" \
- ${CONFIG_SHELL-/bin/sh} "$ac_aux_dir/config.rpath" "$host" > conftest.sh
- . ./conftest.sh
- rm -f ./conftest.sh
- acl_cv_rpath=done
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $acl_cv_rpath" >&5
-$as_echo "$acl_cv_rpath" >&6; }
- wl="$acl_cv_wl"
- libext="$acl_cv_libext"
- shlibext="$acl_cv_shlibext"
- hardcode_libdir_flag_spec="$acl_cv_hardcode_libdir_flag_spec"
- hardcode_libdir_separator="$acl_cv_hardcode_libdir_separator"
- hardcode_direct="$acl_cv_hardcode_direct"
- hardcode_minus_L="$acl_cv_hardcode_minus_L"
- # Check whether --enable-rpath was given.
-if test "${enable_rpath+set}" = set; then :
- enableval=$enable_rpath; :
-else
- enable_rpath=yes
-fi
-
-
-
-
-
-
-
-
- use_additional=yes
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
-
- eval additional_includedir=\"$includedir\"
- eval additional_libdir=\"$libdir\"
-
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
-
-# Check whether --with-libiconv-prefix was given.
-if test "${with_libiconv_prefix+set}" = set; then :
- withval=$with_libiconv_prefix;
- if test "X$withval" = "Xno"; then
- use_additional=no
- else
- if test "X$withval" = "X"; then
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
-
- eval additional_includedir=\"$includedir\"
- eval additional_libdir=\"$libdir\"
-
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- else
- additional_includedir="$withval/include"
- additional_libdir="$withval/lib"
- fi
- fi
-
-fi
-
-
-# Check whether --with-libiconv-type was given.
-if test "${with_libiconv_type+set}" = set; then :
- withval=$with_libiconv_type; with_libiconv_type=$withval
-else
- with_libiconv_type=auto
-fi
-
- lib_type=`eval echo \$with_libiconv_type`
-
- LIBICONV=
- LTLIBICONV=
- INCICONV=
- rpathdirs=
- ltrpathdirs=
- names_already_handled=
- names_next_round='iconv '
- while test -n "$names_next_round"; do
- names_this_round="$names_next_round"
- names_next_round=
- for name in $names_this_round; do
- already_handled=
- for n in $names_already_handled; do
- if test "$n" = "$name"; then
- already_handled=yes
- break
- fi
- done
- if test -z "$already_handled"; then
- names_already_handled="$names_already_handled $name"
- uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
- eval value=\"\$HAVE_LIB$uppername\"
- if test -n "$value"; then
- if test "$value" = yes; then
- eval value=\"\$LIB$uppername\"
- test -z "$value" || LIBICONV="${LIBICONV}${LIBICONV:+ }$value"
- eval value=\"\$LTLIB$uppername\"
- test -z "$value" || LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$value"
- else
- :
- fi
- else
- found_dir=
- found_la=
- found_so=
- found_a=
- if test $use_additional = yes; then
- if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext" && test x$lib_type != xstatic; then
- found_dir="$additional_libdir"
- found_so="$additional_libdir/lib$name.$shlibext"
- if test -f "$additional_libdir/lib$name.la"; then
- found_la="$additional_libdir/lib$name.la"
- fi
- elif test x$lib_type != xshared; then
- if test -f "$additional_libdir/lib$name.$libext"; then
- found_dir="$additional_libdir"
- found_a="$additional_libdir/lib$name.$libext"
- if test -f "$additional_libdir/lib$name.la"; then
- found_la="$additional_libdir/lib$name.la"
- fi
- fi
- fi
- fi
- if test "X$found_dir" = "X"; then
- for x in $LDFLAGS $LTLIBICONV; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- case "$x" in
- -L*)
- dir=`echo "X$x" | sed -e 's/^X-L//'`
- if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext" && test x$lib_type != xstatic; then
- found_dir="$dir"
- found_so="$dir/lib$name.$shlibext"
- if test -f "$dir/lib$name.la"; then
- found_la="$dir/lib$name.la"
- fi
- elif test x$lib_type != xshared; then
- if test -f "$dir/lib$name.$libext"; then
- found_dir="$dir"
- found_a="$dir/lib$name.$libext"
- if test -f "$dir/lib$name.la"; then
- found_la="$dir/lib$name.la"
- fi
- fi
- fi
- ;;
- esac
- if test "X$found_dir" != "X"; then
- break
- fi
- done
- fi
- if test "X$found_dir" != "X"; then
- LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$found_dir -l$name"
- if test "X$found_so" != "X"; then
- if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
- else
- haveit=
- for x in $ltrpathdirs; do
- if test "X$x" = "X$found_dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- ltrpathdirs="$ltrpathdirs $found_dir"
- fi
- if test "$hardcode_direct" = yes; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
- else
- if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
- haveit=
- for x in $rpathdirs; do
- if test "X$x" = "X$found_dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- rpathdirs="$rpathdirs $found_dir"
- fi
- else
- haveit=
- for x in $LDFLAGS $LIBICONV; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-L$found_dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir"
- fi
- if test "$hardcode_minus_L" != no; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
- else
- LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name"
- fi
- fi
- fi
- fi
- else
- if test "X$found_a" != "X"; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }$found_a"
- else
- LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir -l$name"
- fi
- fi
- additional_includedir=
- case "$found_dir" in
- */lib | */lib/)
- basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
- additional_includedir="$basedir/include"
- ;;
- esac
- if test "X$additional_includedir" != "X"; then
- if test "X$additional_includedir" != "X/usr/include"; then
- haveit=
- if test "X$additional_includedir" = "X/usr/local/include"; then
- if test -n "$GCC"; then
- case $host_os in
- linux*) haveit=yes;;
- esac
- fi
- fi
- if test -z "$haveit"; then
- for x in $CPPFLAGS $INCICONV; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-I$additional_includedir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- if test -d "$additional_includedir"; then
- INCICONV="${INCICONV}${INCICONV:+ }-I$additional_includedir"
- fi
- fi
- fi
- fi
- fi
- if test -n "$found_la"; then
- save_libdir="$libdir"
- case "$found_la" in
- */* | *\\*) . "$found_la" ;;
- *) . "./$found_la" ;;
- esac
- libdir="$save_libdir"
- for dep in $dependency_libs; do
- case "$dep" in
- -L*)
- additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
- if test "X$additional_libdir" != "X/usr/lib"; then
- haveit=
- if test "X$additional_libdir" = "X/usr/local/lib"; then
- if test -n "$GCC"; then
- case $host_os in
- linux*) haveit=yes;;
- esac
- fi
- fi
- if test -z "$haveit"; then
- haveit=
- for x in $LDFLAGS $LIBICONV; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-L$additional_libdir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- if test -d "$additional_libdir"; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }-L$additional_libdir"
- fi
- fi
- haveit=
- for x in $LDFLAGS $LTLIBICONV; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-L$additional_libdir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- if test -d "$additional_libdir"; then
- LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$additional_libdir"
- fi
- fi
- fi
- fi
- ;;
- -R*)
- dir=`echo "X$dep" | sed -e 's/^X-R//'`
- if test "$enable_rpath" != no; then
- haveit=
- for x in $rpathdirs; do
- if test "X$x" = "X$dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- rpathdirs="$rpathdirs $dir"
- fi
- haveit=
- for x in $ltrpathdirs; do
- if test "X$x" = "X$dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- ltrpathdirs="$ltrpathdirs $dir"
- fi
- fi
- ;;
- -l*)
- names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
- ;;
- *.la)
- names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
- ;;
- *)
- LIBICONV="${LIBICONV}${LIBICONV:+ }$dep"
- LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$dep"
- ;;
- esac
- done
- fi
- else
- if test "x$lib_type" = "xauto" || test "x$lib_type" = "xshared"; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name"
- LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-l$name"
- else
- LIBICONV="${LIBICONV}${LIBICONV:+ }-l:lib$name.$libext"
- LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-l:lib$name.$libext"
- fi
- fi
- fi
- fi
- done
- done
- if test "X$rpathdirs" != "X"; then
- if test -n "$hardcode_libdir_separator"; then
- alldirs=
- for found_dir in $rpathdirs; do
- alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
- done
- acl_save_libdir="$libdir"
- libdir="$alldirs"
- eval flag=\"$hardcode_libdir_flag_spec\"
- libdir="$acl_save_libdir"
- LIBICONV="${LIBICONV}${LIBICONV:+ }$flag"
- else
- for found_dir in $rpathdirs; do
- acl_save_libdir="$libdir"
- libdir="$found_dir"
- eval flag=\"$hardcode_libdir_flag_spec\"
- libdir="$acl_save_libdir"
- LIBICONV="${LIBICONV}${LIBICONV:+ }$flag"
- done
- fi
- fi
- if test "X$ltrpathdirs" != "X"; then
- for found_dir in $ltrpathdirs; do
- LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-R$found_dir"
- done
- fi
-
-
-
-
-
-if test -f ../gettext/uninstalled-config.sh; then
- relative_builddir='$(top_builddir)/../gettext'
- . ../gettext/uninstalled-config.sh
-else
- # The sister gettext directory doesn't exist and won't collect information on
- # using gettext for us. Call a bundled AM_GNU_GETTEXT.
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CFPreferencesCopyAppValue" >&5
-$as_echo_n "checking for CFPreferencesCopyAppValue... " >&6; }
-if ${gt_cv_func_CFPreferencesCopyAppValue+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- gt_save_LIBS="$LIBS"
- LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <CoreFoundation/CFPreferences.h>
-int
-main ()
-{
-CFPreferencesCopyAppValue(NULL, NULL)
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- gt_cv_func_CFPreferencesCopyAppValue=yes
-else
- gt_cv_func_CFPreferencesCopyAppValue=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LIBS="$gt_save_LIBS"
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_CFPreferencesCopyAppValue" >&5
-$as_echo "$gt_cv_func_CFPreferencesCopyAppValue" >&6; }
- if test $gt_cv_func_CFPreferencesCopyAppValue = yes; then
-
-$as_echo "#define HAVE_CFPREFERENCESCOPYAPPVALUE 1" >>confdefs.h
-
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CFLocaleCopyPreferredLanguages" >&5
-$as_echo_n "checking for CFLocaleCopyPreferredLanguages... " >&6; }
-if ${gt_cv_func_CFLocaleCopyPreferredLanguages+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- gt_save_LIBS="$LIBS"
- LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <CoreFoundation/CFLocale.h>
-int
-main ()
-{
-CFLocaleCopyPreferredLanguages();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- gt_cv_func_CFLocaleCopyPreferredLanguages=yes
-else
- gt_cv_func_CFLocaleCopyPreferredLanguages=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LIBS="$gt_save_LIBS"
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_CFLocaleCopyPreferredLanguages" >&5
-$as_echo "$gt_cv_func_CFLocaleCopyPreferredLanguages" >&6; }
- if test $gt_cv_func_CFLocaleCopyPreferredLanguages = yes; then
-
-$as_echo "#define HAVE_CFLOCALECOPYPREFERREDLANGUAGES 1" >>confdefs.h
-
- fi
- INTL_MACOSX_LIBS=
- if test $gt_cv_func_CFPreferencesCopyAppValue = yes \
- || test $gt_cv_func_CFLocaleCopyPreferredLanguages = yes; then
- INTL_MACOSX_LIBS="-Wl,-framework -Wl,CoreFoundation -Wl,-framework -Wl,CoreServices"
- fi
-
-
-
-
-
-
- LIBINTL=
- LTLIBINTL=
- POSUB=
-
- case " $gt_needs " in
- *" need-formatstring-macros "*) gt_api_version=3 ;;
- *" need-ngettext "*) gt_api_version=2 ;;
- *) gt_api_version=1 ;;
- esac
- gt_func_gnugettext_libc="gt_cv_func_gnugettext${gt_api_version}_libc"
- gt_func_gnugettext_libintl="gt_cv_func_gnugettext${gt_api_version}_libintl"
-
- if test "$USE_NLS" = "yes"; then
- gt_use_preinstalled_gnugettext=no
-
-
- if test $gt_api_version -ge 3; then
- gt_revision_test_code='
-#ifndef __GNU_GETTEXT_SUPPORTED_REVISION
-#define __GNU_GETTEXT_SUPPORTED_REVISION(major) ((major) == 0 ? 0 : -1)
-#endif
-typedef int array [2 * (__GNU_GETTEXT_SUPPORTED_REVISION(0) >= 1) - 1];
-'
- else
- gt_revision_test_code=
- fi
- if test $gt_api_version -ge 2; then
- gt_expression_test_code=' + * ngettext ("", "", 0)'
- else
- gt_expression_test_code=
- fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU gettext in libc" >&5
-$as_echo_n "checking for GNU gettext in libc... " >&6; }
-if eval \${$gt_func_gnugettext_libc+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <libintl.h>
-#ifndef __GNU_GETTEXT_SUPPORTED_REVISION
-extern int _nl_msg_cat_cntr;
-extern int *_nl_domain_bindings;
-#define __GNU_GETTEXT_SYMBOL_EXPRESSION (_nl_msg_cat_cntr + *_nl_domain_bindings)
-#else
-#define __GNU_GETTEXT_SYMBOL_EXPRESSION 0
-#endif
-$gt_revision_test_code
-
-int
-main ()
-{
-
-bindtextdomain ("", "");
-return * gettext ("")$gt_expression_test_code + __GNU_GETTEXT_SYMBOL_EXPRESSION
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- eval "$gt_func_gnugettext_libc=yes"
-else
- eval "$gt_func_gnugettext_libc=no"
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-fi
-eval ac_res=\$$gt_func_gnugettext_libc
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
-
- if { eval "gt_val=\$$gt_func_gnugettext_libc"; test "$gt_val" != "yes"; }; then
-
-
-
-
-
- am_save_CPPFLAGS="$CPPFLAGS"
-
- for element in $INCICONV; do
- haveit=
- for x in $CPPFLAGS; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X$element"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
- fi
- done
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for iconv" >&5
-$as_echo_n "checking for iconv... " >&6; }
-if ${am_cv_func_iconv+:} false; then :
- $as_echo_n "(cached) " >&6
-else
-
- am_cv_func_iconv="no, consider installing GNU libiconv"
- am_cv_lib_iconv=no
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <stdlib.h>
-#include <iconv.h>
-
-int
-main ()
-{
-iconv_t cd = iconv_open("","");
- iconv(cd,NULL,NULL,NULL,NULL);
- iconv_close(cd);
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- am_cv_func_iconv=yes
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- if test "$am_cv_func_iconv" != yes; then
- am_save_LIBS="$LIBS"
- LIBS="$LIBS $LIBICONV"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <stdlib.h>
-#include <iconv.h>
-
-int
-main ()
-{
-iconv_t cd = iconv_open("","");
- iconv(cd,NULL,NULL,NULL,NULL);
- iconv_close(cd);
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- am_cv_lib_iconv=yes
- am_cv_func_iconv=yes
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LIBS="$am_save_LIBS"
- fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv" >&5
-$as_echo "$am_cv_func_iconv" >&6; }
- if test "$am_cv_func_iconv" = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working iconv" >&5
-$as_echo_n "checking for working iconv... " >&6; }
-if ${am_cv_func_iconv_works+:} false; then :
- $as_echo_n "(cached) " >&6
-else
-
- am_save_LIBS="$LIBS"
- if test $am_cv_lib_iconv = yes; then
- LIBS="$LIBS $LIBICONV"
- fi
- am_cv_func_iconv_works=no
- for ac_iconv_const in '' 'const'; do
- if test "$cross_compiling" = yes; then :
- case "$host_os" in
- aix* | hpux*) am_cv_func_iconv_works="guessing no" ;;
- *) am_cv_func_iconv_works="guessing yes" ;;
- esac
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <iconv.h>
-#include <string.h>
-
-#ifndef ICONV_CONST
-# define ICONV_CONST $ac_iconv_const
-#endif
-
-int
-main ()
-{
-int result = 0;
- /* Test against AIX 5.1...7.2 bug: Failures are not distinguishable from
- successful returns. This is even documented in
- <https://www.ibm.com/support/knowledgecenter/ssw_aix_72/i_bostechref/iconv.html> */
- {
- iconv_t cd_utf8_to_88591 = iconv_open ("ISO8859-1", "UTF-8");
- if (cd_utf8_to_88591 != (iconv_t)(-1))
- {
- static ICONV_CONST char input[] = "\342\202\254"; /* EURO SIGN */
- char buf[10];
- ICONV_CONST char *inptr = input;
- size_t inbytesleft = strlen (input);
- char *outptr = buf;
- size_t outbytesleft = sizeof (buf);
- size_t res = iconv (cd_utf8_to_88591,
- &inptr, &inbytesleft,
- &outptr, &outbytesleft);
- if (res == 0)
- result |= 1;
- iconv_close (cd_utf8_to_88591);
- }
- }
- /* Test against Solaris 10 bug: Failures are not distinguishable from
- successful returns. */
- {
- iconv_t cd_ascii_to_88591 = iconv_open ("ISO8859-1", "646");
- if (cd_ascii_to_88591 != (iconv_t)(-1))
- {
- static ICONV_CONST char input[] = "\263";
- char buf[10];
- ICONV_CONST char *inptr = input;
- size_t inbytesleft = strlen (input);
- char *outptr = buf;
- size_t outbytesleft = sizeof (buf);
- size_t res = iconv (cd_ascii_to_88591,
- &inptr, &inbytesleft,
- &outptr, &outbytesleft);
- if (res == 0)
- result |= 2;
- iconv_close (cd_ascii_to_88591);
- }
- }
- /* Test against AIX 6.1..7.1 bug: Buffer overrun. */
- {
- iconv_t cd_88591_to_utf8 = iconv_open ("UTF-8", "ISO-8859-1");
- if (cd_88591_to_utf8 != (iconv_t)(-1))
- {
- static ICONV_CONST char input[] = "\304";
- static char buf[2] = { (char)0xDE, (char)0xAD };
- ICONV_CONST char *inptr = input;
- size_t inbytesleft = 1;
- char *outptr = buf;
- size_t outbytesleft = 1;
- size_t res = iconv (cd_88591_to_utf8,
- &inptr, &inbytesleft,
- &outptr, &outbytesleft);
- if (res != (size_t)(-1) || outptr - buf > 1 || buf[1] != (char)0xAD)
- result |= 4;
- iconv_close (cd_88591_to_utf8);
- }
- }
-#if 0 /* This bug could be worked around by the caller. */
- /* Test against HP-UX 11.11 bug: Positive return value instead of 0. */
- {
- iconv_t cd_88591_to_utf8 = iconv_open ("utf8", "iso88591");
- if (cd_88591_to_utf8 != (iconv_t)(-1))
- {
- static ICONV_CONST char input[] = "\304rger mit b\366sen B\374bchen ohne Augenma\337";
- char buf[50];
- ICONV_CONST char *inptr = input;
- size_t inbytesleft = strlen (input);
- char *outptr = buf;
- size_t outbytesleft = sizeof (buf);
- size_t res = iconv (cd_88591_to_utf8,
- &inptr, &inbytesleft,
- &outptr, &outbytesleft);
- if ((int)res > 0)
- result |= 8;
- iconv_close (cd_88591_to_utf8);
- }
- }
-#endif
- /* Test against HP-UX 11.11 bug: No converter from EUC-JP to UTF-8 is
- provided. */
- {
- /* Try standardized names. */
- iconv_t cd1 = iconv_open ("UTF-8", "EUC-JP");
- /* Try IRIX, OSF/1 names. */
- iconv_t cd2 = iconv_open ("UTF-8", "eucJP");
- /* Try AIX names. */
- iconv_t cd3 = iconv_open ("UTF-8", "IBM-eucJP");
- /* Try HP-UX names. */
- iconv_t cd4 = iconv_open ("utf8", "eucJP");
- if (cd1 == (iconv_t)(-1) && cd2 == (iconv_t)(-1)
- && cd3 == (iconv_t)(-1) && cd4 == (iconv_t)(-1))
- result |= 16;
- if (cd1 != (iconv_t)(-1))
- iconv_close (cd1);
- if (cd2 != (iconv_t)(-1))
- iconv_close (cd2);
- if (cd3 != (iconv_t)(-1))
- iconv_close (cd3);
- if (cd4 != (iconv_t)(-1))
- iconv_close (cd4);
- }
- return result;
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_run "$LINENO"; then :
- am_cv_func_iconv_works=yes
-fi
-rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
- conftest.$ac_objext conftest.beam conftest.$ac_ext
-fi
-
- test "$am_cv_func_iconv_works" = no || break
- done
- LIBS="$am_save_LIBS"
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv_works" >&5
-$as_echo "$am_cv_func_iconv_works" >&6; }
- case "$am_cv_func_iconv_works" in
- *no) am_func_iconv=no am_cv_lib_iconv=no ;;
- *) am_func_iconv=yes ;;
- esac
- else
- am_func_iconv=no am_cv_lib_iconv=no
- fi
- if test "$am_func_iconv" = yes; then
-
-$as_echo "#define HAVE_ICONV 1" >>confdefs.h
-
- fi
- if test "$am_cv_lib_iconv" = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libiconv" >&5
-$as_echo_n "checking how to link with libiconv... " >&6; }
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBICONV" >&5
-$as_echo "$LIBICONV" >&6; }
- else
- CPPFLAGS="$am_save_CPPFLAGS"
- LIBICONV=
- LTLIBICONV=
- fi
-
-
-
-
-
-
- use_additional=yes
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
-
- eval additional_includedir=\"$includedir\"
- eval additional_libdir=\"$libdir\"
-
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
-
-# Check whether --with-libintl-prefix was given.
-if test "${with_libintl_prefix+set}" = set; then :
- withval=$with_libintl_prefix;
- if test "X$withval" = "Xno"; then
- use_additional=no
- else
- if test "X$withval" = "X"; then
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
-
- eval additional_includedir=\"$includedir\"
- eval additional_libdir=\"$libdir\"
-
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- else
- additional_includedir="$withval/include"
- additional_libdir="$withval/lib"
- fi
- fi
-
-fi
-
-
-# Check whether --with-libintl-type was given.
-if test "${with_libintl_type+set}" = set; then :
- withval=$with_libintl_type; with_libintl_type=$withval
-else
- with_libintl_type=auto
-fi
-
- lib_type=`eval echo \$with_libintl_type`
-
- LIBINTL=
- LTLIBINTL=
- INCINTL=
- rpathdirs=
- ltrpathdirs=
- names_already_handled=
- names_next_round='intl '
- while test -n "$names_next_round"; do
- names_this_round="$names_next_round"
- names_next_round=
- for name in $names_this_round; do
- already_handled=
- for n in $names_already_handled; do
- if test "$n" = "$name"; then
- already_handled=yes
- break
- fi
- done
- if test -z "$already_handled"; then
- names_already_handled="$names_already_handled $name"
- uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
- eval value=\"\$HAVE_LIB$uppername\"
- if test -n "$value"; then
- if test "$value" = yes; then
- eval value=\"\$LIB$uppername\"
- test -z "$value" || LIBINTL="${LIBINTL}${LIBINTL:+ }$value"
- eval value=\"\$LTLIB$uppername\"
- test -z "$value" || LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }$value"
- else
- :
- fi
- else
- found_dir=
- found_la=
- found_so=
- found_a=
- if test $use_additional = yes; then
- if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext" && test x$lib_type != xstatic; then
- found_dir="$additional_libdir"
- found_so="$additional_libdir/lib$name.$shlibext"
- if test -f "$additional_libdir/lib$name.la"; then
- found_la="$additional_libdir/lib$name.la"
- fi
- elif test x$lib_type != xshared; then
- if test -f "$additional_libdir/lib$name.$libext"; then
- found_dir="$additional_libdir"
- found_a="$additional_libdir/lib$name.$libext"
- if test -f "$additional_libdir/lib$name.la"; then
- found_la="$additional_libdir/lib$name.la"
- fi
- fi
- fi
- fi
- if test "X$found_dir" = "X"; then
- for x in $LDFLAGS $LTLIBINTL; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- case "$x" in
- -L*)
- dir=`echo "X$x" | sed -e 's/^X-L//'`
- if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext" && test x$lib_type != xstatic; then
- found_dir="$dir"
- found_so="$dir/lib$name.$shlibext"
- if test -f "$dir/lib$name.la"; then
- found_la="$dir/lib$name.la"
- fi
- elif test x$lib_type != xshared; then
- if test -f "$dir/lib$name.$libext"; then
- found_dir="$dir"
- found_a="$dir/lib$name.$libext"
- if test -f "$dir/lib$name.la"; then
- found_la="$dir/lib$name.la"
- fi
- fi
- fi
- ;;
- esac
- if test "X$found_dir" != "X"; then
- break
- fi
- done
- fi
- if test "X$found_dir" != "X"; then
- LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-L$found_dir -l$name"
- if test "X$found_so" != "X"; then
- if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
- else
- haveit=
- for x in $ltrpathdirs; do
- if test "X$x" = "X$found_dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- ltrpathdirs="$ltrpathdirs $found_dir"
- fi
- if test "$hardcode_direct" = yes; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
- else
- if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
- haveit=
- for x in $rpathdirs; do
- if test "X$x" = "X$found_dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- rpathdirs="$rpathdirs $found_dir"
- fi
- else
- haveit=
- for x in $LDFLAGS $LIBINTL; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-L$found_dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }-L$found_dir"
- fi
- if test "$hardcode_minus_L" != no; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
- else
- LIBINTL="${LIBINTL}${LIBINTL:+ }-l$name"
- fi
- fi
- fi
- fi
- else
- if test "X$found_a" != "X"; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }$found_a"
- else
- LIBINTL="${LIBINTL}${LIBINTL:+ }-L$found_dir -l$name"
- fi
- fi
- additional_includedir=
- case "$found_dir" in
- */lib | */lib/)
- basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
- additional_includedir="$basedir/include"
- ;;
- esac
- if test "X$additional_includedir" != "X"; then
- if test "X$additional_includedir" != "X/usr/include"; then
- haveit=
- if test "X$additional_includedir" = "X/usr/local/include"; then
- if test -n "$GCC"; then
- case $host_os in
- linux*) haveit=yes;;
- esac
- fi
- fi
- if test -z "$haveit"; then
- for x in $CPPFLAGS $INCINTL; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-I$additional_includedir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- if test -d "$additional_includedir"; then
- INCINTL="${INCINTL}${INCINTL:+ }-I$additional_includedir"
- fi
- fi
- fi
- fi
- fi
- if test -n "$found_la"; then
- save_libdir="$libdir"
- case "$found_la" in
- */* | *\\*) . "$found_la" ;;
- *) . "./$found_la" ;;
- esac
- libdir="$save_libdir"
- for dep in $dependency_libs; do
- case "$dep" in
- -L*)
- additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
- if test "X$additional_libdir" != "X/usr/lib"; then
- haveit=
- if test "X$additional_libdir" = "X/usr/local/lib"; then
- if test -n "$GCC"; then
- case $host_os in
- linux*) haveit=yes;;
- esac
- fi
- fi
- if test -z "$haveit"; then
- haveit=
- for x in $LDFLAGS $LIBINTL; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-L$additional_libdir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- if test -d "$additional_libdir"; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }-L$additional_libdir"
- fi
- fi
- haveit=
- for x in $LDFLAGS $LTLIBINTL; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-L$additional_libdir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- if test -d "$additional_libdir"; then
- LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-L$additional_libdir"
- fi
- fi
- fi
- fi
- ;;
- -R*)
- dir=`echo "X$dep" | sed -e 's/^X-R//'`
- if test "$enable_rpath" != no; then
- haveit=
- for x in $rpathdirs; do
- if test "X$x" = "X$dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- rpathdirs="$rpathdirs $dir"
- fi
- haveit=
- for x in $ltrpathdirs; do
- if test "X$x" = "X$dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- ltrpathdirs="$ltrpathdirs $dir"
- fi
- fi
- ;;
- -l*)
- names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
- ;;
- *.la)
- names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
- ;;
- *)
- LIBINTL="${LIBINTL}${LIBINTL:+ }$dep"
- LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }$dep"
- ;;
- esac
- done
- fi
- else
- if test "x$lib_type" = "xauto" || test "x$lib_type" = "xshared"; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }-l$name"
- LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-l$name"
- else
- LIBINTL="${LIBINTL}${LIBINTL:+ }-l:lib$name.$libext"
- LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-l:lib$name.$libext"
- fi
- fi
- fi
- fi
- done
- done
- if test "X$rpathdirs" != "X"; then
- if test -n "$hardcode_libdir_separator"; then
- alldirs=
- for found_dir in $rpathdirs; do
- alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
- done
- acl_save_libdir="$libdir"
- libdir="$alldirs"
- eval flag=\"$hardcode_libdir_flag_spec\"
- libdir="$acl_save_libdir"
- LIBINTL="${LIBINTL}${LIBINTL:+ }$flag"
- else
- for found_dir in $rpathdirs; do
- acl_save_libdir="$libdir"
- libdir="$found_dir"
- eval flag=\"$hardcode_libdir_flag_spec\"
- libdir="$acl_save_libdir"
- LIBINTL="${LIBINTL}${LIBINTL:+ }$flag"
- done
- fi
- fi
- if test "X$ltrpathdirs" != "X"; then
- for found_dir in $ltrpathdirs; do
- LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-R$found_dir"
- done
- fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU gettext in libintl" >&5
-$as_echo_n "checking for GNU gettext in libintl... " >&6; }
-if eval \${$gt_func_gnugettext_libintl+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- gt_save_CPPFLAGS="$CPPFLAGS"
- CPPFLAGS="$CPPFLAGS $INCINTL"
- gt_save_LIBS="$LIBS"
- LIBS="$LIBS $LIBINTL"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <libintl.h>
-#ifndef __GNU_GETTEXT_SUPPORTED_REVISION
-extern int _nl_msg_cat_cntr;
-extern
-#ifdef __cplusplus
-"C"
-#endif
-const char *_nl_expand_alias (const char *);
-#define __GNU_GETTEXT_SYMBOL_EXPRESSION (_nl_msg_cat_cntr + *_nl_expand_alias (""))
-#else
-#define __GNU_GETTEXT_SYMBOL_EXPRESSION 0
-#endif
-$gt_revision_test_code
-
-int
-main ()
-{
-
-bindtextdomain ("", "");
-return * gettext ("")$gt_expression_test_code + __GNU_GETTEXT_SYMBOL_EXPRESSION
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- eval "$gt_func_gnugettext_libintl=yes"
-else
- eval "$gt_func_gnugettext_libintl=no"
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" != yes; } && test -n "$LIBICONV"; then
- LIBS="$LIBS $LIBICONV"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <libintl.h>
-#ifndef __GNU_GETTEXT_SUPPORTED_REVISION
-extern int _nl_msg_cat_cntr;
-extern
-#ifdef __cplusplus
-"C"
-#endif
-const char *_nl_expand_alias (const char *);
-#define __GNU_GETTEXT_SYMBOL_EXPRESSION (_nl_msg_cat_cntr + *_nl_expand_alias (""))
-#else
-#define __GNU_GETTEXT_SYMBOL_EXPRESSION 0
-#endif
-$gt_revision_test_code
-
-int
-main ()
-{
-
-bindtextdomain ("", "");
-return * gettext ("")$gt_expression_test_code + __GNU_GETTEXT_SYMBOL_EXPRESSION
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- LIBINTL="$LIBINTL $LIBICONV"
- LTLIBINTL="$LTLIBINTL $LTLIBICONV"
- eval "$gt_func_gnugettext_libintl=yes"
-
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- fi
- CPPFLAGS="$gt_save_CPPFLAGS"
- LIBS="$gt_save_LIBS"
-fi
-eval ac_res=\$$gt_func_gnugettext_libintl
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
- fi
-
- if { eval "gt_val=\$$gt_func_gnugettext_libc"; test "$gt_val" = "yes"; } \
- || { { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; } \
- && test "$PACKAGE" != gettext-runtime \
- && test "$PACKAGE" != gettext-tools; }; then
- gt_use_preinstalled_gnugettext=yes
- else
- LIBINTL=
- LTLIBINTL=
- INCINTL=
- fi
-
-
-
- if test -n "$INTL_MACOSX_LIBS"; then
- if test "$gt_use_preinstalled_gnugettext" = "yes" \
- || test "$nls_cv_use_gnu_gettext" = "yes"; then
- LIBINTL="$LIBINTL $INTL_MACOSX_LIBS"
- LTLIBINTL="$LTLIBINTL $INTL_MACOSX_LIBS"
- fi
- fi
-
- if test "$gt_use_preinstalled_gnugettext" = "yes" \
- || test "$nls_cv_use_gnu_gettext" = "yes"; then
-
-$as_echo "#define ENABLE_NLS 1" >>confdefs.h
-
- else
- USE_NLS=no
- fi
- fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use NLS" >&5
-$as_echo_n "checking whether to use NLS... " >&6; }
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_NLS" >&5
-$as_echo "$USE_NLS" >&6; }
- if test "$USE_NLS" = "yes"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking where the gettext function comes from" >&5
-$as_echo_n "checking where the gettext function comes from... " >&6; }
- if test "$gt_use_preinstalled_gnugettext" = "yes"; then
- if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; }; then
- gt_source="external libintl"
- else
- gt_source="libc"
- fi
- else
- gt_source="included intl directory"
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_source" >&5
-$as_echo "$gt_source" >&6; }
- fi
-
- if test "$USE_NLS" = "yes"; then
-
- if test "$gt_use_preinstalled_gnugettext" = "yes"; then
- if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; }; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libintl" >&5
-$as_echo_n "checking how to link with libintl... " >&6; }
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBINTL" >&5
-$as_echo "$LIBINTL" >&6; }
-
- for element in $INCINTL; do
- haveit=
- for x in $CPPFLAGS; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X$element"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
- fi
- done
-
- fi
-
-
-$as_echo "#define HAVE_GETTEXT 1" >>confdefs.h
-
-
-$as_echo "#define HAVE_DCGETTEXT 1" >>confdefs.h
-
- fi
-
- POSUB=po
- fi
-
-
-
- INTLLIBS="$LIBINTL"
-
-
-
-
-
-
-fi
-
-
-
-
-
-
-
-
-
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NLS is requested" >&5
-$as_echo_n "checking whether NLS is requested... " >&6; }
-if test x"$USE_NLS" != xyes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-
-$as_echo "#define ENABLE_NLS 1" >>confdefs.h
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for catalogs to be installed" >&5
-$as_echo_n "checking for catalogs to be installed... " >&6; }
- # Look for .po and .gmo files in the source directory.
- CATALOGS=
- XLINGUAS=
- for cat in $srcdir/po/*.gmo $srcdir/po/*.po; do
- # If there aren't any .gmo files the shell will give us the
- # literal string "../path/to/srcdir/po/*.gmo" which has to be
- # weeded out.
- case "$cat" in *\**)
- continue;;
- esac
- # The quadruple backslash is collapsed to a double backslash
- # by the backticks, then collapsed again by the double quotes,
- # leaving us with one backslash in the sed expression (right
- # before the dot that mustn't act as a wildcard).
- cat=`echo $cat | sed -e "s!$srcdir/po/!!" -e "s!\\\\.po!.gmo!"`
- lang=`echo $cat | sed -e "s!\\\\.gmo!!"`
- # The user is allowed to set LINGUAS to a list of languages to
- # install catalogs for. If it's empty that means "all of them."
- if test "x$LINGUAS" = x; then
- CATALOGS="$CATALOGS $cat"
- XLINGUAS="$XLINGUAS $lang"
- else
- case "$LINGUAS" in *$lang*)
- CATALOGS="$CATALOGS $cat"
- XLINGUAS="$XLINGUAS $lang"
- ;;
- esac
- fi
- done
- LINGUAS="$XLINGUAS"
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LINGUAS" >&5
-$as_echo "$LINGUAS" >&6; }
-
-
- DATADIRNAME=share
-
- INSTOBJEXT=.mo
-
- GENCAT=gencat
-
- CATOBJEXT=.gmo
-
-fi
-
-
-
-
-# Prepare PATH_SEPARATOR.
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-
-# Find out how to test for executable files. Don't use a zero-byte file,
-# as systems may use methods other than mode bits to determine executability.
-cat >conf$$.file <<_ASEOF
-#! /bin/sh
-exit 0
-_ASEOF
-chmod +x conf$$.file
-if test -x conf$$.file >/dev/null 2>&1; then
- ac_executable_p="test -x"
-else
- ac_executable_p="test -f"
-fi
-rm -f conf$$.file
-
-# Extract the first word of "msgfmt", so it can be a program name with args.
-set dummy msgfmt; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_MSGFMT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case "$MSGFMT" in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
- ;;
- *)
- ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH; do
- IFS="$ac_save_IFS"
- test -z "$ac_dir" && ac_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
- if $ac_dir/$ac_word --statistics /dev/null >/dev/null 2>&1 &&
- (if $ac_dir/$ac_word --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- ac_cv_path_MSGFMT="$ac_dir/$ac_word$ac_exec_ext"
- break 2
- fi
- fi
- done
- done
- IFS="$ac_save_IFS"
- test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT=":"
- ;;
-esac
-fi
-MSGFMT="$ac_cv_path_MSGFMT"
-if test "$MSGFMT" != ":"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGFMT" >&5
-$as_echo "$MSGFMT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- # Extract the first word of "gmsgfmt", so it can be a program name with args.
-set dummy gmsgfmt; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_GMSGFMT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $GMSGFMT in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
- ;;
- *)
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_path_GMSGFMT="$as_dir/$ac_word$ac_exec_ext"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
- test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT"
- ;;
-esac
-fi
-GMSGFMT=$ac_cv_path_GMSGFMT
-if test -n "$GMSGFMT"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GMSGFMT" >&5
-$as_echo "$GMSGFMT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-
-
-# Prepare PATH_SEPARATOR.
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-
-# Find out how to test for executable files. Don't use a zero-byte file,
-# as systems may use methods other than mode bits to determine executability.
-cat >conf$$.file <<_ASEOF
-#! /bin/sh
-exit 0
-_ASEOF
-chmod +x conf$$.file
-if test -x conf$$.file >/dev/null 2>&1; then
- ac_executable_p="test -x"
-else
- ac_executable_p="test -f"
-fi
-rm -f conf$$.file
-
-# Extract the first word of "xgettext", so it can be a program name with args.
-set dummy xgettext; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_XGETTEXT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case "$XGETTEXT" in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
- ;;
- *)
- ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH; do
- IFS="$ac_save_IFS"
- test -z "$ac_dir" && ac_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
- if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >/dev/null 2>&1 &&
- (if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- ac_cv_path_XGETTEXT="$ac_dir/$ac_word$ac_exec_ext"
- break 2
- fi
- fi
- done
- done
- IFS="$ac_save_IFS"
- test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":"
- ;;
-esac
-fi
-XGETTEXT="$ac_cv_path_XGETTEXT"
-if test "$XGETTEXT" != ":"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XGETTEXT" >&5
-$as_echo "$XGETTEXT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- rm -f messages.po
-
-
-# Prepare PATH_SEPARATOR.
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-
-# Find out how to test for executable files. Don't use a zero-byte file,
-# as systems may use methods other than mode bits to determine executability.
-cat >conf$$.file <<_ASEOF
-#! /bin/sh
-exit 0
-_ASEOF
-chmod +x conf$$.file
-if test -x conf$$.file >/dev/null 2>&1; then
- ac_executable_p="test -x"
-else
- ac_executable_p="test -f"
-fi
-rm -f conf$$.file
-
-# Extract the first word of "msgmerge", so it can be a program name with args.
-set dummy msgmerge; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_MSGMERGE+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case "$MSGMERGE" in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_MSGMERGE="$MSGMERGE" # Let the user override the test with a path.
- ;;
- *)
- ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH; do
- IFS="$ac_save_IFS"
- test -z "$ac_dir" && ac_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
- if $ac_dir/$ac_word --update -q /dev/null /dev/null >/dev/null 2>&1; then
- ac_cv_path_MSGMERGE="$ac_dir/$ac_word$ac_exec_ext"
- break 2
- fi
- fi
- done
- done
- IFS="$ac_save_IFS"
- test -z "$ac_cv_path_MSGMERGE" && ac_cv_path_MSGMERGE=":"
- ;;
-esac
-fi
-MSGMERGE="$ac_cv_path_MSGMERGE"
-if test "$MSGMERGE" != ":"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGMERGE" >&5
-$as_echo "$MSGMERGE" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- if test "$GMSGFMT" != ":"; then
- if $GMSGFMT --statistics /dev/null >/dev/null 2>&1 &&
- (if $GMSGFMT --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- : ;
- else
- GMSGFMT=`echo "$GMSGFMT" | sed -e 's,^.*/,,'`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: found $GMSGFMT program is not GNU msgfmt; ignore it" >&5
-$as_echo "found $GMSGFMT program is not GNU msgfmt; ignore it" >&6; }
- GMSGFMT=":"
- fi
- fi
-
- if test "$XGETTEXT" != ":"; then
- if $XGETTEXT --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >/dev/null 2>&1 &&
- (if $XGETTEXT --omit-header --copyright-holder= --msgid-bugs-address= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- : ;
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: found xgettext program is not GNU xgettext; ignore it" >&5
-$as_echo "found xgettext program is not GNU xgettext; ignore it" >&6; }
- XGETTEXT=":"
- fi
- rm -f messages.po
- fi
-
- ac_config_commands="$ac_config_commands default-2"
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
-$as_echo_n "checking whether byte ordering is bigendian... " >&6; }
-if ${ac_cv_c_bigendian+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_cv_c_bigendian=unknown
- # See if we're dealing with a universal compiler.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#ifndef __APPLE_CC__
- not a universal capable compiler
- #endif
- typedef int dummy;
-
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
-
- # Check for potential -arch flags. It is not universal unless
- # there are at least two -arch flags with different values.
- ac_arch=
- ac_prev=
- for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
- if test -n "$ac_prev"; then
- case $ac_word in
- i?86 | x86_64 | ppc | ppc64)
- if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
- ac_arch=$ac_word
- else
- ac_cv_c_bigendian=universal
- break
- fi
- ;;
- esac
- ac_prev=
- elif test "x$ac_word" = "x-arch"; then
- ac_prev=arch
- fi
- done
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- if test $ac_cv_c_bigendian = unknown; then
- # See if sys/param.h defines the BYTE_ORDER macro.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <sys/types.h>
- #include <sys/param.h>
-
-int
-main ()
-{
-#if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
- && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
- && LITTLE_ENDIAN)
- bogus endian macros
- #endif
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- # It does; now see whether it defined to BIG_ENDIAN or not.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <sys/types.h>
- #include <sys/param.h>
-
-int
-main ()
-{
-#if BYTE_ORDER != BIG_ENDIAN
- not big endian
- #endif
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_c_bigendian=yes
-else
- ac_cv_c_bigendian=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- fi
- if test $ac_cv_c_bigendian = unknown; then
- # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <limits.h>
-
-int
-main ()
-{
-#if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
- bogus endian macros
- #endif
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- # It does; now see whether it defined to _BIG_ENDIAN or not.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <limits.h>
-
-int
-main ()
-{
-#ifndef _BIG_ENDIAN
- not big endian
- #endif
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_c_bigendian=yes
-else
- ac_cv_c_bigendian=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- fi
- if test $ac_cv_c_bigendian = unknown; then
- # Compile a test program.
- if test "$cross_compiling" = yes; then :
- # Try to guess by grepping values from an object file.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-short int ascii_mm[] =
- { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
- short int ascii_ii[] =
- { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
- int use_ascii (int i) {
- return ascii_mm[i] + ascii_ii[i];
- }
- short int ebcdic_ii[] =
- { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
- short int ebcdic_mm[] =
- { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
- int use_ebcdic (int i) {
- return ebcdic_mm[i] + ebcdic_ii[i];
- }
- extern int foo;
-
-int
-main ()
-{
-return use_ascii (foo) == use_ebcdic (foo);
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
- ac_cv_c_bigendian=yes
- fi
- if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
- if test "$ac_cv_c_bigendian" = unknown; then
- ac_cv_c_bigendian=no
- else
- # finding both strings is unlikely to happen, but who knows?
- ac_cv_c_bigendian=unknown
- fi
- fi
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$ac_includes_default
-int
-main ()
-{
-
- /* Are we little or big endian? From Harbison&Steele. */
- union
- {
- long int l;
- char c[sizeof (long int)];
- } u;
- u.l = 1;
- return u.c[sizeof (long int) - 1] == 1;
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_run "$LINENO"; then :
- ac_cv_c_bigendian=no
-else
- ac_cv_c_bigendian=yes
-fi
-rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
- conftest.$ac_objext conftest.beam conftest.$ac_ext
-fi
-
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
-$as_echo "$ac_cv_c_bigendian" >&6; }
- case $ac_cv_c_bigendian in #(
- yes)
- $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
-;; #(
- no)
- ;; #(
- universal)
-
-$as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
-
- ;; #(
- *)
- as_fn_error $? "unknown endianness
- presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
- esac
-
-
-
-
- if test "x$target_alias" = "x" -o "x$host_alias" = "x$target_alias"; then
- NATIVE_LINKER_TRUE=
- NATIVE_LINKER_FALSE='#'
-else
- NATIVE_LINKER_TRUE='#'
- NATIVE_LINKER_FALSE=
-fi
-
- if test "$GCC" = yes; then
- GCC_TRUE=
- GCC_FALSE='#'
-else
- GCC_TRUE='#'
- GCC_FALSE=
-fi
-
-
- if test "x$target_alias" = "x" -o "x$host_alias" = "x$target_alias" -o "x$host_alias" = "x$build_alias"; then
- NATIVE_OR_CROSS_LINKER_TRUE=
- NATIVE_OR_CROSS_LINKER_FALSE='#'
-else
- NATIVE_OR_CROSS_LINKER_TRUE='#'
- NATIVE_OR_CROSS_LINKER_FALSE=
-fi
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether static linking works" >&5
-$as_echo_n "checking whether static linking works... " >&6; }
-if ${gold_cv_lib_static+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- LDFLAGS_hold=$LDFLAGS
-LDFLAGS="$LDFLAGS -static"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-void f() { }
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- gold_cv_lib_static=yes
-else
- gold_cv_lib_static=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LDFLAGS=$LDFLAGS_hold
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gold_cv_lib_static" >&5
-$as_echo "$gold_cv_lib_static" >&6; }
- if test "$gold_cv_lib_static" = "yes"; then
- HAVE_STATIC_TRUE=
- HAVE_STATIC_FALSE='#'
-else
- HAVE_STATIC_TRUE='#'
- HAVE_STATIC_FALSE=
-fi
-
-
- if
- case $target_cpu in
- powerpc*) false;;
- x86_64) false;;
- sparc64) false;;
- s390x) false;;
- *) true;;
- esac; then
- FN_PTRS_IN_SO_WITHOUT_PIC_TRUE=
- FN_PTRS_IN_SO_WITHOUT_PIC_FALSE='#'
-else
- FN_PTRS_IN_SO_WITHOUT_PIC_TRUE='#'
- FN_PTRS_IN_SO_WITHOUT_PIC_FALSE=
-fi
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for gcc >= 4.1" >&5
-$as_echo_n "checking for gcc >= 4.1... " >&6; }
-if ${gold_cv_prog_gcc41+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#if !defined __GNUC__
-error
-#elif __GNUC__ < 4 || (__GNUC__ == 4 && __GNUC_MINOR__ < 1)
-error
-#endif
-
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- gold_cv_prog_gcc41=yes
-else
- gold_cv_prog_gcc41=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gold_cv_prog_gcc41" >&5
-$as_echo "$gold_cv_prog_gcc41" >&6; }
-
-save_CFLAGS="$CFLAGS"
-CFLAGS="$CFLAGS -mcmodel=medium"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-int i;
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- have_mcmodel_medium=yes
-else
- have_mcmodel_medium=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-CFLAGS="$save_CFLAGS"
- if test "$target_cpu" = "x86_64" -a "$have_mcmodel_medium" = "yes" -a "$gold_cv_prog_gcc41" = "yes"; then
- MCMODEL_MEDIUM_TRUE=
- MCMODEL_MEDIUM_FALSE='#'
-else
- MCMODEL_MEDIUM_TRUE='#'
- MCMODEL_MEDIUM_FALSE=
-fi
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for gcc >= 9" >&5
-$as_echo_n "checking for gcc >= 9... " >&6; }
-if ${gold_cv_prog_gcc9+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#if !defined __GNUC__ || __GNUC__ < 9
-error
-#endif
-
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- gold_cv_prog_gcc9=yes
-else
- gold_cv_prog_gcc9=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gold_cv_prog_gcc9" >&5
-$as_echo "$gold_cv_prog_gcc9" >&6; }
- if test "$gold_cv_prog_gcc9" = "yes"; then
- GCC9_TRUE=
- GCC9_FALSE='#'
-else
- GCC9_TRUE='#'
- GCC9_FALSE=
-fi
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for -fcf-protection" >&5
-$as_echo_n "checking for -fcf-protection... " >&6; }
-if ${gold_cv_cflags_cf_protection+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#if !defined __x86_64__ || !defined __CET__
-error
-#endif
-
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- gold_cv_cflags_cf_protection=yes
-else
- gold_cv_cflags_cf_protection=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gold_cv_cflags_cf_protection" >&5
-$as_echo "$gold_cv_cflags_cf_protection" >&6; }
- if test "$gold_cv_cflags_cf_protection" = "yes"; then
- CFLAGS_CF_PROTECTION_TRUE=
- CFLAGS_CF_PROTECTION_FALSE='#'
-else
- CFLAGS_CF_PROTECTION_TRUE='#'
- CFLAGS_CF_PROTECTION_FALSE=
-fi
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -fmerge-constants" >&5
-$as_echo_n "checking whether $CC supports -fmerge-constants... " >&6; }
-if ${gold_cv_merge_constants+:} false; then :
- $as_echo_n "(cached) " >&6
-else
-
-save_CFLAGS="$CFLAGS"
-CFLAGS="$CFLAGS -fmerge-constants"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-const char *s = "foo";
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- gold_cv_merge_constants=yes
-else
- gold_cv_merge_constants=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-CFLAGS="$save_CFLAGS"
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gold_cv_merge_constants" >&5
-$as_echo "$gold_cv_merge_constants" >&6; }
-
-if test "$gold_cv_merge_constants" = yes; then :
- MERGE_CONSTANTS_FLAG=-fmerge-constants
-else
- MERGE_CONSTANTS_FLAG=
-fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for thread support" >&5
-$as_echo_n "checking for thread support... " >&6; }
-if ${gold_cv_c_thread+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-__thread int i = 1;
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- gold_cv_c_thread=yes
-else
- gold_cv_c_thread=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gold_cv_c_thread" >&5
-$as_echo "$gold_cv_c_thread" >&6; }
-
- if test "$gold_cv_c_thread" = "yes"; then
- TLS_TRUE=
- TLS_FALSE='#'
-else
- TLS_TRUE='#'
- TLS_FALSE=
-fi
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for glibc >= 2.4" >&5
-$as_echo_n "checking for glibc >= 2.4... " >&6; }
-if ${gold_cv_lib_glibc24+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <features.h>
-#if !defined __GLIBC__
-error
-#elif __GLIBC__ < 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ < 4)
-error
-#endif
-
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- gold_cv_lib_glibc24=yes
-else
- gold_cv_lib_glibc24=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gold_cv_lib_glibc24" >&5
-$as_echo "$gold_cv_lib_glibc24" >&6; }
-
- if test "$gold_cv_lib_glibc24" = "yes"; then
- STATIC_TLS_TRUE=
- STATIC_TLS_FALSE='#'
-else
- STATIC_TLS_TRUE='#'
- STATIC_TLS_FALSE=
-fi
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for omp support" >&5
-$as_echo_n "checking for omp support... " >&6; }
-if ${gold_cv_c_threadprivate+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- save_CFLAGS="$CFLAGS"
-CFLAGS="$CFLAGS -fopenmp"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <omp.h>
-int i;
-#pragma omp threadprivate (i)
-
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- gold_cv_c_threadprivate=yes
-else
- gold_cv_c_threadprivate=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-CFLAGS="$save_CFLAGS"
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gold_cv_c_threadprivate" >&5
-$as_echo "$gold_cv_c_threadprivate" >&6; }
-if test "$gold_cv_c_threadprivate" = "yes"; then
-
-$as_echo "#define HAVE_OMP_SUPPORT 1" >>confdefs.h
-
-fi
- if test "$gold_cv_c_threadprivate" = "yes"; then
- OMP_SUPPORT_TRUE=
- OMP_SUPPORT_FALSE='#'
-else
- OMP_SUPPORT_TRUE='#'
- OMP_SUPPORT_FALSE=
-fi
-
-
-save_CFLAGS="$CFLAGS"
-CFLAGS="$CFLAGS -Werror -fpic -mtls-dialect=gnu2"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-__thread int i;
-void foo (void)
-{
- i = 10;
-}
-
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- have_tls_gnu2=yes
-else
- have_tls_gnu2=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-CFLAGS="$save_CFLAGS"
- if test "$have_tls_gnu2" = "yes"; then
- TLS_GNU2_DIALECT_TRUE=
- TLS_GNU2_DIALECT_FALSE='#'
-else
- TLS_GNU2_DIALECT_TRUE='#'
- TLS_GNU2_DIALECT_FALSE=
-fi
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for glibc >= 2.9" >&5
-$as_echo_n "checking for glibc >= 2.9... " >&6; }
-if ${gold_cv_lib_glibc29+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <features.h>
-#if !defined __GLIBC__
-error
-#elif __GLIBC__ < 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ < 9)
-error
-#endif
-
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- gold_cv_lib_glibc29=yes
-else
- gold_cv_lib_glibc29=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gold_cv_lib_glibc29" >&5
-$as_echo "$gold_cv_lib_glibc29" >&6; }
-
- if test "$gold_cv_lib_glibc29" = "yes"; then
- TLS_DESCRIPTORS_TRUE=
- TLS_DESCRIPTORS_FALSE='#'
-else
- TLS_DESCRIPTORS_TRUE='#'
- TLS_DESCRIPTORS_FALSE=
-fi
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for -frandom-seed support" >&5
-$as_echo_n "checking for -frandom-seed support... " >&6; }
-if ${gold_cv_c_random_seed+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- save_CFLAGS="$CFLAGS"
-CFLAGS="$CFLAGS -frandom-seed=foo"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-int i;
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- gold_cv_c_random_seed=yes
-else
- gold_cv_c_random_seed=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-CFLAGS="$save_CFLAGS"
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gold_cv_c_random_seed" >&5
-$as_echo "$gold_cv_c_random_seed" >&6; }
-if test "$gold_cv_c_random_seed" = "yes"; then
- # In Makefile, '$@' will be expanded to be the name of the file
- # being built, providing a unique seed for each file.
- RANDOM_SEED_CFLAGS=-frandom-seed=\$@
-fi
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for glibc ifunc support" >&5
-$as_echo_n "checking for glibc ifunc support... " >&6; }
-if ${gold_cv_lib_glibc_ifunc+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- save_LDFLAGS="$LDFLAGS"
-LDFLAGS="$LDFLAGS -static"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <features.h>
-#if !defined __GLIBC__
-error
-#elif __GLIBC__ < 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ < 11)
-error
-#endif
-void func (void) { }
-void invoke (void);
-__asm__(".type invoke, %gnu_indirect_function");
-typedef void (*funcptr) (void);
-funcptr dispatch (void) __asm__ ("invoke");
-funcptr dispatch (void) { return &func; }
-int
-main ()
-{
-invoke();
- ;
- return 0;
-}
-
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
-
-if ${NM} conftest$EXEEXT | grep "__rela\?_iplt_start" >/dev/null 2>&1; then
- gold_cv_lib_glibc_ifunc=both
-else
- gold_cv_lib_glibc_ifunc=dyn
-fi
-else
- gold_cv_lib_glibc_ifunc=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LDFLAGS="$save_LDFLAGS"
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gold_cv_lib_glibc_ifunc" >&5
-$as_echo "$gold_cv_lib_glibc_ifunc" >&6; }
-
- if test "$gold_cv_lib_glibc_ifunc" != "no"; then
- IFUNC_TRUE=
- IFUNC_FALSE='#'
-else
- IFUNC_TRUE='#'
- IFUNC_FALSE=
-fi
-
- if test "$gold_cv_lib_glibc_ifunc" = "both"; then
- IFUNC_STATIC_TRUE=
- IFUNC_STATIC_FALSE='#'
-else
- IFUNC_STATIC_TRUE='#'
- IFUNC_STATIC_FALSE=
-fi
-
-
-
-# Set the 'development' global.
-. $srcdir/../bfd/development.sh
-
-# Set acp_cpp_for_build variable
-ac_cpp_for_build="$CC_FOR_BUILD -E $CPPFLAGS_FOR_BUILD"
-
-# Default set of GCC warnings to enable.
-GCC_WARN_CFLAGS="-W -Wall -Wstrict-prototypes -Wmissing-prototypes"
-GCC_WARN_CFLAGS_FOR_BUILD="-W -Wall -Wstrict-prototypes -Wmissing-prototypes"
-
-# Add -Wshadow if the compiler is a sufficiently recent version of GCC.
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-__GNUC__
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "(^[0-3]$|^__GNUC__$)" >/dev/null 2>&1; then :
-
-else
- GCC_WARN_CFLAGS="$GCC_WARN_CFLAGS -Wshadow"
-fi
-rm -f conftest*
-
-
-# Add -Wstack-usage if the compiler is a sufficiently recent version of GCC.
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-__GNUC__
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "(^[0-4]$|^__GNUC__$)" >/dev/null 2>&1; then :
-
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-__clang__
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "^__clang__$" >/dev/null 2>&1; then :
- GCC_WARN_CFLAGS="$GCC_WARN_CFLAGS -Wstack-usage=262144"
-fi
-rm -f conftest*
-
-fi
-rm -f conftest*
-
-
-# Set WARN_WRITE_STRINGS if the compiler supports -Wwrite-strings.
-WARN_WRITE_STRINGS=""
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-__GNUC__
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "(^[0-3]$|^__GNUC__$)" >/dev/null 2>&1; then :
-
-else
- WARN_WRITE_STRINGS="-Wwrite-strings"
-fi
-rm -f conftest*
-
-
-# Verify CC_FOR_BUILD to be compatible with warning flags
-
-# Add -Wshadow if the compiler is a sufficiently recent version of GCC.
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-__GNUC__
-_ACEOF
-if (eval "$ac_cpp_for_build conftest.$ac_ext") 2>&5 |
- $EGREP "(^[0-3]$|^__GNUC__$)" >/dev/null 2>&1; then :
-
-else
- GCC_WARN_CFLAGS_FOR_BUILD="$GCC_WARN_CFLAGS_FOR_BUILD -Wshadow"
-fi
-rm -f conftest*
-
-
-# Add -Wstack-usage if the compiler is a sufficiently recent version of GCC.
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-__GNUC__
-_ACEOF
-if (eval "$ac_cpp_for_build conftest.$ac_ext") 2>&5 |
- $EGREP "(^[0-4]$|^__GNUC__$)" >/dev/null 2>&1; then :
-
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-__clang__
-_ACEOF
-if (eval "$ac_cpp_for_build conftest.$ac_ext") 2>&5 |
- $EGREP "^__clang__$" >/dev/null 2>&1; then :
- GCC_WARN_CFLAGS_FOR_BUILD="$GCC_WARN_CFLAGS_FOR_BUILD -Wstack-usage=262144"
-fi
-rm -f conftest*
-
-fi
-rm -f conftest*
-
-
-# Check whether --enable-werror was given.
-if test "${enable_werror+set}" = set; then :
- enableval=$enable_werror; case "${enableval}" in
- yes | y) ERROR_ON_WARNING="yes" ;;
- no | n) ERROR_ON_WARNING="no" ;;
- *) as_fn_error $? "bad value ${enableval} for --enable-werror" "$LINENO" 5 ;;
- esac
-fi
-
-
-# Disable -Wformat by default when using gcc on mingw
-case "${host}" in
- *-*-mingw32*)
- if test "${GCC}" = yes -a -z "${ERROR_ON_WARNING}" ; then
- GCC_WARN_CFLAGS="$GCC_WARN_CFLAGS -Wno-format"
- GCC_WARN_CFLAGS_FOR_BUILD="$GCC_WARN_CFLAGS_FOR_BUILD -Wno-format"
- fi
- ;;
- *) ;;
-esac
-
-# Enable -Werror by default when using gcc. Turn it off for releases.
-if test "${GCC}" = yes -a -z "${ERROR_ON_WARNING}" -a "$development" = true ; then
- ERROR_ON_WARNING=yes
-fi
-
-NO_WERROR=
-if test "${ERROR_ON_WARNING}" = yes ; then
- GCC_WARN_CFLAGS="$GCC_WARN_CFLAGS -Werror"
- GCC_WARN_CFLAGS_FOR_BUILD="$GCC_WARN_CFLAGS_FOR_BUILD -Werror"
- NO_WERROR="-Wno-error"
-fi
-
-if test "${GCC}" = yes ; then
- WARN_CFLAGS="${GCC_WARN_CFLAGS}"
- WARN_CFLAGS_FOR_BUILD="${GCC_WARN_CFLAGS_FOR_BUILD}"
-fi
-
-# Check whether --enable-build-warnings was given.
-if test "${enable_build_warnings+set}" = set; then :
- enableval=$enable_build_warnings; case "${enableval}" in
- yes) WARN_CFLAGS="${GCC_WARN_CFLAGS}"
- WARN_CFLAGS_FOR_BUILD="${GCC_WARN_CFLAGS_FOR_BUILD}";;
- no) if test "${GCC}" = yes ; then
- WARN_CFLAGS="-w"
- WARN_CFLAGS_FOR_BUILD="-w"
- fi;;
- ,*) t=`echo "${enableval}" | sed -e "s/,/ /g"`
- WARN_CFLAGS="${GCC_WARN_CFLAGS} ${t}"
- WARN_CFLAGS_FOR_BUILD="${GCC_WARN_CFLAGS_FOR_BUILD} ${t}";;
- *,) t=`echo "${enableval}" | sed -e "s/,/ /g"`
- WARN_CFLAGS="${t} ${GCC_WARN_CFLAGS}"
- WARN_CFLAGS_FOR_BUILD="${t} ${GCC_WARN_CFLAGS_FOR_BUILD}";;
- *) WARN_CFLAGS=`echo "${enableval}" | sed -e "s/,/ /g"`
- WARN_CFLAGS_FOR_BUILD=`echo "${enableval}" | sed -e "s/,/ /g"`;;
-esac
-fi
-
-
-if test x"$silent" != x"yes" && test x"$WARN_CFLAGS" != x""; then
- echo "Setting warning flags = $WARN_CFLAGS" 6>&1
-fi
-
-
-
-
-
-
-
-WARN_CXXFLAGS=`echo ${WARN_CFLAGS} | sed -e 's/-Wstrict-prototypes//' -e 's/-Wmissing-prototypes//' -e 's/-Wshadow//'`
-
-
-
-# Check whether --with-gold-ldflags was given.
-if test "${with_gold_ldflags+set}" = set; then :
- withval=$with_gold_ldflags; if test "$withval" = "no" -o "$withval" = "yes"; then
- GOLD_LDFLAGS=
- else
- GOLD_LDFLAGS=$withval
- fi
-else
- GOLD_LDFLAGS=
-fi
-
-
-
-
-# Check whether --with-gold-ldadd was given.
-if test "${with_gold_ldadd+set}" = set; then :
- withval=$with_gold_ldadd; if test "$withval" = "no" -o "$withval" = "yes"; then
- GOLD_LDADD=
- else
- GOLD_LDADD=$withval
- fi
-else
- GOLD_LDADD=
-fi
-
-
-
-LFS_CFLAGS="-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64"
-
-
-for ac_header in sys/mman.h
-do :
- ac_fn_c_check_header_mongrel "$LINENO" "sys/mman.h" "ac_cv_header_sys_mman_h" "$ac_includes_default"
-if test "x$ac_cv_header_sys_mman_h" = xyes; then :
- cat >>confdefs.h <<_ACEOF
-#define HAVE_SYS_MMAN_H 1
-_ACEOF
-
-fi
-
-done
-
-for ac_func in chsize mmap link
-do :
- as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
-ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
-if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
- cat >>confdefs.h <<_ACEOF
-#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
-_ACEOF
-
-fi
-done
-
-ac_fn_c_check_func "$LINENO" "pread" "ac_cv_func_pread"
-if test "x$ac_cv_func_pread" = xyes; then :
- $as_echo "#define HAVE_PREAD 1" >>confdefs.h
-
-else
- case " $LIBOBJS " in
- *" pread.$ac_objext "* ) ;;
- *) LIBOBJS="$LIBOBJS pread.$ac_objext"
- ;;
-esac
-
-fi
-
-ac_fn_c_check_func "$LINENO" "ftruncate" "ac_cv_func_ftruncate"
-if test "x$ac_cv_func_ftruncate" = xyes; then :
- $as_echo "#define HAVE_FTRUNCATE 1" >>confdefs.h
-
-else
- case " $LIBOBJS " in
- *" ftruncate.$ac_objext "* ) ;;
- *) LIBOBJS="$LIBOBJS ftruncate.$ac_objext"
- ;;
-esac
-
-fi
-
-ac_fn_c_check_func "$LINENO" "ffsll" "ac_cv_func_ffsll"
-if test "x$ac_cv_func_ffsll" = xyes; then :
- $as_echo "#define HAVE_FFSLL 1" >>confdefs.h
-
-else
- case " $LIBOBJS " in
- *" ffsll.$ac_objext "* ) ;;
- *) LIBOBJS="$LIBOBJS ffsll.$ac_objext"
- ;;
-esac
-
-fi
-
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking mremap with MREMAP_MAYMOVE" >&5
-$as_echo_n "checking mremap with MREMAP_MAYMOVE... " >&6; }
-if ${gold_cv_lib_mremap_maymove+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-
-#include <sys/mman.h>
-void f() { mremap (0, 0, 0, MREMAP_MAYMOVE); }
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- gold_cv_lib_mremap_maymove=yes
-else
- gold_cv_lib_mremap_maymove=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gold_cv_lib_mremap_maymove" >&5
-$as_echo "$gold_cv_lib_mremap_maymove" >&6; }
-if test "$gold_cv_lib_mremap_maymove" = "yes"; then
-
-$as_echo "#define HAVE_MREMAP 1" >>confdefs.h
-
-else
- case " $LIBOBJS " in
- *" mremap.$ac_objext "* ) ;;
- *) LIBOBJS="$LIBOBJS mremap.$ac_objext"
- ;;
-esac
-
-fi
-
-# Link in zlib/zstd if we can. This allows us to write compressed sections.
-
- # Use the system's zlib library.
- zlibdir="-L\$(top_builddir)/../zlib"
- zlibinc="-I\$(top_srcdir)/../zlib"
-
-# Check whether --with-system-zlib was given.
-if test "${with_system_zlib+set}" = set; then :
- withval=$with_system_zlib; if test x$with_system_zlib = xyes ; then
- zlibdir=
- zlibinc=
- fi
-
-fi
-
-
-
-
-
-
-
-
-
-
-
-if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
-set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_PKG_CONFIG+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $PKG_CONFIG in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
- ;;
- *)
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
- ;;
-esac
-fi
-PKG_CONFIG=$ac_cv_path_PKG_CONFIG
-if test -n "$PKG_CONFIG"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
-$as_echo "$PKG_CONFIG" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_path_PKG_CONFIG"; then
- ac_pt_PKG_CONFIG=$PKG_CONFIG
- # Extract the first word of "pkg-config", so it can be a program name with args.
-set dummy pkg-config; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $ac_pt_PKG_CONFIG in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
- ;;
- *)
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
- ;;
-esac
-fi
-ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
-if test -n "$ac_pt_PKG_CONFIG"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5
-$as_echo "$ac_pt_PKG_CONFIG" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_pt_PKG_CONFIG" = x; then
- PKG_CONFIG=""
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- PKG_CONFIG=$ac_pt_PKG_CONFIG
- fi
-else
- PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
-fi
-
-fi
-if test -n "$PKG_CONFIG"; then
- _pkg_min_version=0.9.0
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5
-$as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; }
- if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- PKG_CONFIG=""
- fi
-fi
-
-
-# Check whether --with-zstd was given.
-if test "${with_zstd+set}" = set; then :
- withval=$with_zstd;
-else
- with_zstd=auto
-fi
-
-
-if test "$with_zstd" != no; then :
-
-pkg_failed=no
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for libzstd >= 1.4.0" >&5
-$as_echo_n "checking for libzstd >= 1.4.0... " >&6; }
-
-if test -n "$ZSTD_CFLAGS"; then
- pkg_cv_ZSTD_CFLAGS="$ZSTD_CFLAGS"
- elif test -n "$PKG_CONFIG"; then
- if test -n "$PKG_CONFIG" && \
- { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libzstd >= 1.4.0\""; } >&5
- ($PKG_CONFIG --exists --print-errors "libzstd >= 1.4.0") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- pkg_cv_ZSTD_CFLAGS=`$PKG_CONFIG --cflags "libzstd >= 1.4.0" 2>/dev/null`
- test "x$?" != "x0" && pkg_failed=yes
-else
- pkg_failed=yes
-fi
- else
- pkg_failed=untried
-fi
-if test -n "$ZSTD_LIBS"; then
- pkg_cv_ZSTD_LIBS="$ZSTD_LIBS"
- elif test -n "$PKG_CONFIG"; then
- if test -n "$PKG_CONFIG" && \
- { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libzstd >= 1.4.0\""; } >&5
- ($PKG_CONFIG --exists --print-errors "libzstd >= 1.4.0") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- pkg_cv_ZSTD_LIBS=`$PKG_CONFIG --libs "libzstd >= 1.4.0" 2>/dev/null`
- test "x$?" != "x0" && pkg_failed=yes
-else
- pkg_failed=yes
-fi
- else
- pkg_failed=untried
-fi
-
-if test $pkg_failed = no; then
- pkg_save_LDFLAGS="$LDFLAGS"
- LDFLAGS="$LDFLAGS $pkg_cv_ZSTD_LIBS"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
-
-else
- pkg_failed=yes
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LDFLAGS=$pkg_save_LDFLAGS
-fi
-
-
-
-if test $pkg_failed = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-
-if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
- _pkg_short_errors_supported=yes
-else
- _pkg_short_errors_supported=no
-fi
- if test $_pkg_short_errors_supported = yes; then
- ZSTD_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libzstd >= 1.4.0" 2>&1`
- else
- ZSTD_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libzstd >= 1.4.0" 2>&1`
- fi
- # Put the nasty error message in config.log where it belongs
- echo "$ZSTD_PKG_ERRORS" >&5
-
-
- if test "$with_zstd" = yes; then
- as_fn_error $? "--with-zstd was given, but pkgconfig/libzstd.pc is not found" "$LINENO" 5
- fi
-
-elif test $pkg_failed = untried; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-
- if test "$with_zstd" = yes; then
- as_fn_error $? "--with-zstd was given, but pkgconfig/libzstd.pc is not found" "$LINENO" 5
- fi
-
-else
- ZSTD_CFLAGS=$pkg_cv_ZSTD_CFLAGS
- ZSTD_LIBS=$pkg_cv_ZSTD_LIBS
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-
-
-$as_echo "#define HAVE_ZSTD 1" >>confdefs.h
-
-
-fi
-
-fi
-
- if test "$pkg_cv_ZSTD_LIBS" != ""; then
- HAVE_ZSTD_TRUE=
- HAVE_ZSTD_FALSE='#'
-else
- HAVE_ZSTD_TRUE='#'
- HAVE_ZSTD_FALSE=
-fi
-
-
-# Check whether --enable-threads was given.
-if test "${enable_threads+set}" = set; then :
- enableval=$enable_threads; case "${enableval}" in
- yes | "") threads=yes ;;
- no) threads=no ;;
- auto) threads=auto ;;
- *) threads=yes ;;
- esac
-else
- threads=auto
-fi
-
-
-if test "$threads" = "yes"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
-$as_echo_n "checking for a sed that does not truncate output... " >&6; }
-if ${ac_cv_path_SED+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
- for ac_i in 1 2 3 4 5 6 7; do
- ac_script="$ac_script$as_nl$ac_script"
- done
- echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
- { ac_script=; unset ac_script;}
- if test -z "$SED"; then
- ac_path_SED_found=false
- # Loop through the user's path and test for each of PROGNAME-LIST
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_prog in sed gsed; do
- for ac_exec_ext in '' $ac_executable_extensions; do
- ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
- as_fn_executable_p "$ac_path_SED" || continue
-# Check for GNU ac_path_SED and select it if it is found.
- # Check for GNU $ac_path_SED
-case `"$ac_path_SED" --version 2>&1` in
-*GNU*)
- ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
-*)
- ac_count=0
- $as_echo_n 0123456789 >"conftest.in"
- while :
- do
- cat "conftest.in" "conftest.in" >"conftest.tmp"
- mv "conftest.tmp" "conftest.in"
- cp "conftest.in" "conftest.nl"
- $as_echo '' >> "conftest.nl"
- "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
- diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
- as_fn_arith $ac_count + 1 && ac_count=$as_val
- if test $ac_count -gt ${ac_path_SED_max-0}; then
- # Best one so far, save it but keep looking for a better one
- ac_cv_path_SED="$ac_path_SED"
- ac_path_SED_max=$ac_count
- fi
- # 10*(2^10) chars as input seems more than enough
- test $ac_count -gt 10 && break
- done
- rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
-esac
-
- $ac_path_SED_found && break 3
- done
- done
- done
-IFS=$as_save_IFS
- if test -z "$ac_cv_path_SED"; then
- as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
- fi
-else
- ac_cv_path_SED=$SED
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
-$as_echo "$ac_cv_path_SED" >&6; }
- SED="$ac_cv_path_SED"
- rm -f conftest.sed
-
-
-
-
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-ax_pthread_ok=no
-
-# We used to check for pthread.h first, but this fails if pthread.h
-# requires special compiler flags (e.g. on Tru64 or Sequent).
-# It gets checked for in the link test anyway.
-
-# First of all, check if the user has set any of the PTHREAD_LIBS,
-# etcetera environment variables, and if threads linking works using
-# them:
-if test "x$PTHREAD_CFLAGS$PTHREAD_LIBS" != "x"; then
- ax_pthread_save_CC="$CC"
- ax_pthread_save_CFLAGS="$CFLAGS"
- ax_pthread_save_LIBS="$LIBS"
- if test "x$PTHREAD_CC" != "x"; then :
- CC="$PTHREAD_CC"
-fi
- CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
- LIBS="$PTHREAD_LIBS $LIBS"
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_join using $CC $PTHREAD_CFLAGS $PTHREAD_LIBS" >&5
-$as_echo_n "checking for pthread_join using $CC $PTHREAD_CFLAGS $PTHREAD_LIBS... " >&6; }
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char pthread_join ();
-int
-main ()
-{
-return pthread_join ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ax_pthread_ok=yes
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_ok" >&5
-$as_echo "$ax_pthread_ok" >&6; }
- if test "x$ax_pthread_ok" = "xno"; then
- PTHREAD_LIBS=""
- PTHREAD_CFLAGS=""
- fi
- CC="$ax_pthread_save_CC"
- CFLAGS="$ax_pthread_save_CFLAGS"
- LIBS="$ax_pthread_save_LIBS"
-fi
-
-# We must check for the threads library under a number of different
-# names; the ordering is very important because some systems
-# (e.g. DEC) have both -lpthread and -lpthreads, where one of the
-# libraries is broken (non-POSIX).
-
-# Create a list of thread flags to try. Items starting with a "-" are
-# C compiler flags, and other items are library names, except for "none"
-# which indicates that we try without any flags at all, and "pthread-config"
-# which is a program returning the flags for the Pth emulation library.
-
-ax_pthread_flags="pthreads none -Kthread -pthread -pthreads -mthreads pthread --thread-safe -mt pthread-config"
-
-# The ordering *is* (sometimes) important. Some notes on the
-# individual items follow:
-
-# pthreads: AIX (must check this before -lpthread)
-# none: in case threads are in libc; should be tried before -Kthread and
-# other compiler flags to prevent continual compiler warnings
-# -Kthread: Sequent (threads in libc, but -Kthread needed for pthread.h)
-# -pthread: Linux/gcc (kernel threads), BSD/gcc (userland threads), Tru64
-# (Note: HP C rejects this with "bad form for `-t' option")
-# -pthreads: Solaris/gcc (Note: HP C also rejects)
-# -mt: Sun Workshop C (may only link SunOS threads [-lthread], but it
-# doesn't hurt to check since this sometimes defines pthreads and
-# -D_REENTRANT too), HP C (must be checked before -lpthread, which
-# is present but should not be used directly; and before -mthreads,
-# because the compiler interprets this as "-mt" + "-hreads")
-# -mthreads: Mingw32/gcc, Lynx/gcc
-# pthread: Linux, etcetera
-# --thread-safe: KAI C++
-# pthread-config: use pthread-config program (for GNU Pth library)
-
-case $host_os in
-
- freebsd*)
-
- # -kthread: FreeBSD kernel threads (preferred to -pthread since SMP-able)
- # lthread: LinuxThreads port on FreeBSD (also preferred to -pthread)
-
- ax_pthread_flags="-kthread lthread $ax_pthread_flags"
- ;;
-
- hpux*)
-
- # From the cc(1) man page: "[-mt] Sets various -D flags to enable
- # multi-threading and also sets -lpthread."
-
- ax_pthread_flags="-mt -pthread pthread $ax_pthread_flags"
- ;;
-
- openedition*)
-
- # IBM z/OS requires a feature-test macro to be defined in order to
- # enable POSIX threads at all, so give the user a hint if this is
- # not set. (We don't define these ourselves, as they can affect
- # other portions of the system API in unpredictable ways.)
-
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-# if !defined(_OPEN_THREADS) && !defined(_UNIX03_THREADS)
- AX_PTHREAD_ZOS_MISSING
-# endif
-
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "AX_PTHREAD_ZOS_MISSING" >/dev/null 2>&1; then :
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: IBM z/OS requires -D_OPEN_THREADS or -D_UNIX03_THREADS to enable pthreads support." >&5
-$as_echo "$as_me: WARNING: IBM z/OS requires -D_OPEN_THREADS or -D_UNIX03_THREADS to enable pthreads support." >&2;}
-fi
-rm -f conftest*
-
- ;;
-
- solaris*)
-
- # On Solaris (at least, for some versions), libc contains stubbed
- # (non-functional) versions of the pthreads routines, so link-based
- # tests will erroneously succeed. (N.B.: The stubs are missing
- # pthread_cleanup_push, or rather a function called by this macro,
- # so we could check for that, but who knows whether they'll stub
- # that too in a future libc.) So we'll check first for the
- # standard Solaris way of linking pthreads (-mt -lpthread).
-
- ax_pthread_flags="-mt,pthread pthread $ax_pthread_flags"
- ;;
-esac
-
-# GCC generally uses -pthread, or -pthreads on some platforms (e.g. SPARC)
-
-if test "x$GCC" = "xyes"; then :
- ax_pthread_flags="-pthread -pthreads $ax_pthread_flags"
-fi
-
-# The presence of a feature test macro requesting re-entrant function
-# definitions is, on some systems, a strong hint that pthreads support is
-# correctly enabled
-
-case $host_os in
- darwin* | hpux* | linux* | osf* | solaris*)
- ax_pthread_check_macro="_REENTRANT"
- ;;
-
- aix*)
- ax_pthread_check_macro="_THREAD_SAFE"
- ;;
-
- *)
- ax_pthread_check_macro="--"
- ;;
-esac
-if test "x$ax_pthread_check_macro" = "x--"; then :
- ax_pthread_check_cond=0
-else
- ax_pthread_check_cond="!defined($ax_pthread_check_macro)"
-fi
-
-# Are we compiling with Clang?
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC is Clang" >&5
-$as_echo_n "checking whether $CC is Clang... " >&6; }
-if ${ax_cv_PTHREAD_CLANG+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ax_cv_PTHREAD_CLANG=no
- # Note that Autoconf sets GCC=yes for Clang as well as GCC
- if test "x$GCC" = "xyes"; then
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-/* Note: Clang 2.7 lacks __clang_[a-z]+__ */
-# if defined(__clang__) && defined(__llvm__)
- AX_PTHREAD_CC_IS_CLANG
-# endif
-
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "AX_PTHREAD_CC_IS_CLANG" >/dev/null 2>&1; then :
- ax_cv_PTHREAD_CLANG=yes
-fi
-rm -f conftest*
-
- fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_CLANG" >&5
-$as_echo "$ax_cv_PTHREAD_CLANG" >&6; }
-ax_pthread_clang="$ax_cv_PTHREAD_CLANG"
-
-ax_pthread_clang_warning=no
-
-# Clang needs special handling, because older versions handle the -pthread
-# option in a rather... idiosyncratic way
-
-if test "x$ax_pthread_clang" = "xyes"; then
-
- # Clang takes -pthread; it has never supported any other flag
-
- # (Note 1: This will need to be revisited if a system that Clang
- # supports has POSIX threads in a separate library. This tends not
- # to be the way of modern systems, but it's conceivable.)
-
- # (Note 2: On some systems, notably Darwin, -pthread is not needed
- # to get POSIX threads support; the API is always present and
- # active. We could reasonably leave PTHREAD_CFLAGS empty. But
- # -pthread does define _REENTRANT, and while the Darwin headers
- # ignore this macro, third-party headers might not.)
-
- PTHREAD_CFLAGS="-pthread"
- PTHREAD_LIBS=
-
- ax_pthread_ok=yes
-
- # However, older versions of Clang make a point of warning the user
- # that, in an invocation where only linking and no compilation is
- # taking place, the -pthread option has no effect ("argument unused
- # during compilation"). They expect -pthread to be passed in only
- # when source code is being compiled.
- #
- # Problem is, this is at odds with the way Automake and most other
- # C build frameworks function, which is that the same flags used in
- # compilation (CFLAGS) are also used in linking. Many systems
- # supported by AX_PTHREAD require exactly this for POSIX threads
- # support, and in fact it is often not straightforward to specify a
- # flag that is used only in the compilation phase and not in
- # linking. Such a scenario is extremely rare in practice.
- #
- # Even though use of the -pthread flag in linking would only print
- # a warning, this can be a nuisance for well-run software projects
- # that build with -Werror. So if the active version of Clang has
- # this misfeature, we search for an option to squash it.
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether Clang needs flag to prevent \"argument unused\" warning when linking with -pthread" >&5
-$as_echo_n "checking whether Clang needs flag to prevent \"argument unused\" warning when linking with -pthread... " >&6; }
-if ${ax_cv_PTHREAD_CLANG_NO_WARN_FLAG+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ax_cv_PTHREAD_CLANG_NO_WARN_FLAG=unknown
- # Create an alternate version of $ac_link that compiles and
- # links in two steps (.c -> .o, .o -> exe) instead of one
- # (.c -> exe), because the warning occurs only in the second
- # step
- ax_pthread_save_ac_link="$ac_link"
- ax_pthread_sed='s/conftest\.\$ac_ext/conftest.$ac_objext/g'
- ax_pthread_link_step=`$as_echo "$ac_link" | sed "$ax_pthread_sed"`
- ax_pthread_2step_ac_link="($ac_compile) && (echo ==== >&5) && ($ax_pthread_link_step)"
- ax_pthread_save_CFLAGS="$CFLAGS"
- for ax_pthread_try in '' -Qunused-arguments -Wno-unused-command-line-argument unknown; do
- if test "x$ax_pthread_try" = "xunknown"; then :
- break
-fi
- CFLAGS="-Werror -Wunknown-warning-option $ax_pthread_try -pthread $ax_pthread_save_CFLAGS"
- ac_link="$ax_pthread_save_ac_link"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-int main(void){return 0;}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_link="$ax_pthread_2step_ac_link"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-int main(void){return 0;}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- break
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- done
- ac_link="$ax_pthread_save_ac_link"
- CFLAGS="$ax_pthread_save_CFLAGS"
- if test "x$ax_pthread_try" = "x"; then :
- ax_pthread_try=no
-fi
- ax_cv_PTHREAD_CLANG_NO_WARN_FLAG="$ax_pthread_try"
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_CLANG_NO_WARN_FLAG" >&5
-$as_echo "$ax_cv_PTHREAD_CLANG_NO_WARN_FLAG" >&6; }
-
- case "$ax_cv_PTHREAD_CLANG_NO_WARN_FLAG" in
- no | unknown) ;;
- *) PTHREAD_CFLAGS="$ax_cv_PTHREAD_CLANG_NO_WARN_FLAG $PTHREAD_CFLAGS" ;;
- esac
-
-fi # $ax_pthread_clang = yes
-
-if test "x$ax_pthread_ok" = "xno"; then
-for ax_pthread_try_flag in $ax_pthread_flags; do
-
- case $ax_pthread_try_flag in
- none)
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads work without any flags" >&5
-$as_echo_n "checking whether pthreads work without any flags... " >&6; }
- ;;
-
- -mt,pthread)
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads work with -mt -lpthread" >&5
-$as_echo_n "checking whether pthreads work with -mt -lpthread... " >&6; }
- PTHREAD_CFLAGS="-mt"
- PTHREAD_LIBS="-lpthread"
- ;;
-
- -*)
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads work with $ax_pthread_try_flag" >&5
-$as_echo_n "checking whether pthreads work with $ax_pthread_try_flag... " >&6; }
- PTHREAD_CFLAGS="$ax_pthread_try_flag"
- ;;
-
- pthread-config)
- # Extract the first word of "pthread-config", so it can be a program name with args.
-set dummy pthread-config; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ax_pthread_config+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ax_pthread_config"; then
- ac_cv_prog_ax_pthread_config="$ax_pthread_config" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ax_pthread_config="yes"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
- test -z "$ac_cv_prog_ax_pthread_config" && ac_cv_prog_ax_pthread_config="no"
-fi
-fi
-ax_pthread_config=$ac_cv_prog_ax_pthread_config
-if test -n "$ax_pthread_config"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_config" >&5
-$as_echo "$ax_pthread_config" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- if test "x$ax_pthread_config" = "xno"; then :
- continue
-fi
- PTHREAD_CFLAGS="`pthread-config --cflags`"
- PTHREAD_LIBS="`pthread-config --ldflags` `pthread-config --libs`"
- ;;
-
- *)
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the pthreads library -l$ax_pthread_try_flag" >&5
-$as_echo_n "checking for the pthreads library -l$ax_pthread_try_flag... " >&6; }
- PTHREAD_LIBS="-l$ax_pthread_try_flag"
- ;;
- esac
-
- ax_pthread_save_CFLAGS="$CFLAGS"
- ax_pthread_save_LIBS="$LIBS"
- CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
- LIBS="$PTHREAD_LIBS $LIBS"
-
- # Check for various functions. We must include pthread.h,
- # since some functions may be macros. (On the Sequent, we
- # need a special flag -Kthread to make this header compile.)
- # We check for pthread_join because it is in -lpthread on IRIX
- # while pthread_create is in libc. We check for pthread_attr_init
- # due to DEC craziness with -lpthreads. We check for
- # pthread_cleanup_push because it is one of the few pthread
- # functions on Solaris that doesn't have a non-functional libc stub.
- # We try pthread_create on general principles.
-
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <pthread.h>
-# if $ax_pthread_check_cond
-# error "$ax_pthread_check_macro must be defined"
-# endif
- static void routine(void *a) { a = 0; }
- static void *start_routine(void *a) { return a; }
-int
-main ()
-{
-pthread_t th; pthread_attr_t attr;
- pthread_create(&th, 0, start_routine, 0);
- pthread_join(th, 0);
- pthread_attr_init(&attr);
- pthread_cleanup_push(routine, 0);
- pthread_cleanup_pop(0) /* ; */
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ax_pthread_ok=yes
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-
- CFLAGS="$ax_pthread_save_CFLAGS"
- LIBS="$ax_pthread_save_LIBS"
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_ok" >&5
-$as_echo "$ax_pthread_ok" >&6; }
- if test "x$ax_pthread_ok" = "xyes"; then :
- break
-fi
-
- PTHREAD_LIBS=""
- PTHREAD_CFLAGS=""
-done
-fi
-
-# Various other checks:
-if test "x$ax_pthread_ok" = "xyes"; then
- ax_pthread_save_CFLAGS="$CFLAGS"
- ax_pthread_save_LIBS="$LIBS"
- CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
- LIBS="$PTHREAD_LIBS $LIBS"
-
- # Detect AIX lossage: JOINABLE attribute is called UNDETACHED.
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for joinable pthread attribute" >&5
-$as_echo_n "checking for joinable pthread attribute... " >&6; }
-if ${ax_cv_PTHREAD_JOINABLE_ATTR+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ax_cv_PTHREAD_JOINABLE_ATTR=unknown
- for ax_pthread_attr in PTHREAD_CREATE_JOINABLE PTHREAD_CREATE_UNDETACHED; do
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <pthread.h>
-int
-main ()
-{
-int attr = $ax_pthread_attr; return attr /* ; */
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ax_cv_PTHREAD_JOINABLE_ATTR=$ax_pthread_attr; break
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- done
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_JOINABLE_ATTR" >&5
-$as_echo "$ax_cv_PTHREAD_JOINABLE_ATTR" >&6; }
- if test "x$ax_cv_PTHREAD_JOINABLE_ATTR" != "xunknown" && \
- test "x$ax_cv_PTHREAD_JOINABLE_ATTR" != "xPTHREAD_CREATE_JOINABLE" && \
- test "x$ax_pthread_joinable_attr_defined" != "xyes"; then :
-
-cat >>confdefs.h <<_ACEOF
-#define PTHREAD_CREATE_JOINABLE $ax_cv_PTHREAD_JOINABLE_ATTR
-_ACEOF
-
- ax_pthread_joinable_attr_defined=yes
-
-fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether more special flags are required for pthreads" >&5
-$as_echo_n "checking whether more special flags are required for pthreads... " >&6; }
-if ${ax_cv_PTHREAD_SPECIAL_FLAGS+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ax_cv_PTHREAD_SPECIAL_FLAGS=no
- case $host_os in
- solaris*)
- ax_cv_PTHREAD_SPECIAL_FLAGS="-D_POSIX_PTHREAD_SEMANTICS"
- ;;
- esac
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_SPECIAL_FLAGS" >&5
-$as_echo "$ax_cv_PTHREAD_SPECIAL_FLAGS" >&6; }
- if test "x$ax_cv_PTHREAD_SPECIAL_FLAGS" != "xno" && \
- test "x$ax_pthread_special_flags_added" != "xyes"; then :
- PTHREAD_CFLAGS="$ax_cv_PTHREAD_SPECIAL_FLAGS $PTHREAD_CFLAGS"
- ax_pthread_special_flags_added=yes
-fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PTHREAD_PRIO_INHERIT" >&5
-$as_echo_n "checking for PTHREAD_PRIO_INHERIT... " >&6; }
-if ${ax_cv_PTHREAD_PRIO_INHERIT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <pthread.h>
-int
-main ()
-{
-int i = PTHREAD_PRIO_INHERIT;
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ax_cv_PTHREAD_PRIO_INHERIT=yes
-else
- ax_cv_PTHREAD_PRIO_INHERIT=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_PRIO_INHERIT" >&5
-$as_echo "$ax_cv_PTHREAD_PRIO_INHERIT" >&6; }
- if test "x$ax_cv_PTHREAD_PRIO_INHERIT" = "xyes" && \
- test "x$ax_pthread_prio_inherit_defined" != "xyes"; then :
-
-$as_echo "#define HAVE_PTHREAD_PRIO_INHERIT 1" >>confdefs.h
-
- ax_pthread_prio_inherit_defined=yes
-
-fi
-
- CFLAGS="$ax_pthread_save_CFLAGS"
- LIBS="$ax_pthread_save_LIBS"
-
- # More AIX lossage: compile with *_r variant
- if test "x$GCC" != "xyes"; then
- case $host_os in
- aix*)
- case "x/$CC" in #(
- x*/c89|x*/c89_128|x*/c99|x*/c99_128|x*/cc|x*/cc128|x*/xlc|x*/xlc_v6|x*/xlc128|x*/xlc128_v6) :
- #handle absolute path differently from PATH based program lookup
- case "x$CC" in #(
- x/*) :
- if as_fn_executable_p ${CC}_r; then :
- PTHREAD_CC="${CC}_r"
-fi ;; #(
- *) :
- for ac_prog in ${CC}_r
-do
- # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_PTHREAD_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$PTHREAD_CC"; then
- ac_cv_prog_PTHREAD_CC="$PTHREAD_CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_PTHREAD_CC="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-PTHREAD_CC=$ac_cv_prog_PTHREAD_CC
-if test -n "$PTHREAD_CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PTHREAD_CC" >&5
-$as_echo "$PTHREAD_CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$PTHREAD_CC" && break
-done
-test -n "$PTHREAD_CC" || PTHREAD_CC="$CC"
- ;;
-esac ;; #(
- *) :
- ;;
-esac
- ;;
- esac
- fi
-fi
-
-test -n "$PTHREAD_CC" || PTHREAD_CC="$CC"
-
-
-
-
-
-# Finally, execute ACTION-IF-FOUND/ACTION-IF-NOT-FOUND:
-if test "x$ax_pthread_ok" = "xyes"; then
- threads=yes
- :
-else
- ax_pthread_ok=no
- as_fn_error $? "pthread not found" "$LINENO" 5
-fi
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-
-elif test "$threads" = "auto"; then
-
-
-
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-ax_pthread_ok=no
-
-# We used to check for pthread.h first, but this fails if pthread.h
-# requires special compiler flags (e.g. on Tru64 or Sequent).
-# It gets checked for in the link test anyway.
-
-# First of all, check if the user has set any of the PTHREAD_LIBS,
-# etcetera environment variables, and if threads linking works using
-# them:
-if test "x$PTHREAD_CFLAGS$PTHREAD_LIBS" != "x"; then
- ax_pthread_save_CC="$CC"
- ax_pthread_save_CFLAGS="$CFLAGS"
- ax_pthread_save_LIBS="$LIBS"
- if test "x$PTHREAD_CC" != "x"; then :
- CC="$PTHREAD_CC"
-fi
- CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
- LIBS="$PTHREAD_LIBS $LIBS"
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_join using $CC $PTHREAD_CFLAGS $PTHREAD_LIBS" >&5
-$as_echo_n "checking for pthread_join using $CC $PTHREAD_CFLAGS $PTHREAD_LIBS... " >&6; }
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char pthread_join ();
-int
-main ()
-{
-return pthread_join ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ax_pthread_ok=yes
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_ok" >&5
-$as_echo "$ax_pthread_ok" >&6; }
- if test "x$ax_pthread_ok" = "xno"; then
- PTHREAD_LIBS=""
- PTHREAD_CFLAGS=""
- fi
- CC="$ax_pthread_save_CC"
- CFLAGS="$ax_pthread_save_CFLAGS"
- LIBS="$ax_pthread_save_LIBS"
-fi
-
-# We must check for the threads library under a number of different
-# names; the ordering is very important because some systems
-# (e.g. DEC) have both -lpthread and -lpthreads, where one of the
-# libraries is broken (non-POSIX).
-
-# Create a list of thread flags to try. Items starting with a "-" are
-# C compiler flags, and other items are library names, except for "none"
-# which indicates that we try without any flags at all, and "pthread-config"
-# which is a program returning the flags for the Pth emulation library.
-
-ax_pthread_flags="pthreads none -Kthread -pthread -pthreads -mthreads pthread --thread-safe -mt pthread-config"
-
-# The ordering *is* (sometimes) important. Some notes on the
-# individual items follow:
-
-# pthreads: AIX (must check this before -lpthread)
-# none: in case threads are in libc; should be tried before -Kthread and
-# other compiler flags to prevent continual compiler warnings
-# -Kthread: Sequent (threads in libc, but -Kthread needed for pthread.h)
-# -pthread: Linux/gcc (kernel threads), BSD/gcc (userland threads), Tru64
-# (Note: HP C rejects this with "bad form for `-t' option")
-# -pthreads: Solaris/gcc (Note: HP C also rejects)
-# -mt: Sun Workshop C (may only link SunOS threads [-lthread], but it
-# doesn't hurt to check since this sometimes defines pthreads and
-# -D_REENTRANT too), HP C (must be checked before -lpthread, which
-# is present but should not be used directly; and before -mthreads,
-# because the compiler interprets this as "-mt" + "-hreads")
-# -mthreads: Mingw32/gcc, Lynx/gcc
-# pthread: Linux, etcetera
-# --thread-safe: KAI C++
-# pthread-config: use pthread-config program (for GNU Pth library)
-
-case $host_os in
-
- freebsd*)
-
- # -kthread: FreeBSD kernel threads (preferred to -pthread since SMP-able)
- # lthread: LinuxThreads port on FreeBSD (also preferred to -pthread)
-
- ax_pthread_flags="-kthread lthread $ax_pthread_flags"
- ;;
-
- hpux*)
-
- # From the cc(1) man page: "[-mt] Sets various -D flags to enable
- # multi-threading and also sets -lpthread."
-
- ax_pthread_flags="-mt -pthread pthread $ax_pthread_flags"
- ;;
-
- openedition*)
-
- # IBM z/OS requires a feature-test macro to be defined in order to
- # enable POSIX threads at all, so give the user a hint if this is
- # not set. (We don't define these ourselves, as they can affect
- # other portions of the system API in unpredictable ways.)
-
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-# if !defined(_OPEN_THREADS) && !defined(_UNIX03_THREADS)
- AX_PTHREAD_ZOS_MISSING
-# endif
-
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "AX_PTHREAD_ZOS_MISSING" >/dev/null 2>&1; then :
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: IBM z/OS requires -D_OPEN_THREADS or -D_UNIX03_THREADS to enable pthreads support." >&5
-$as_echo "$as_me: WARNING: IBM z/OS requires -D_OPEN_THREADS or -D_UNIX03_THREADS to enable pthreads support." >&2;}
-fi
-rm -f conftest*
-
- ;;
-
- solaris*)
-
- # On Solaris (at least, for some versions), libc contains stubbed
- # (non-functional) versions of the pthreads routines, so link-based
- # tests will erroneously succeed. (N.B.: The stubs are missing
- # pthread_cleanup_push, or rather a function called by this macro,
- # so we could check for that, but who knows whether they'll stub
- # that too in a future libc.) So we'll check first for the
- # standard Solaris way of linking pthreads (-mt -lpthread).
-
- ax_pthread_flags="-mt,pthread pthread $ax_pthread_flags"
- ;;
-esac
-
-# GCC generally uses -pthread, or -pthreads on some platforms (e.g. SPARC)
-
-if test "x$GCC" = "xyes"; then :
- ax_pthread_flags="-pthread -pthreads $ax_pthread_flags"
-fi
-
-# The presence of a feature test macro requesting re-entrant function
-# definitions is, on some systems, a strong hint that pthreads support is
-# correctly enabled
-
-case $host_os in
- darwin* | hpux* | linux* | osf* | solaris*)
- ax_pthread_check_macro="_REENTRANT"
- ;;
-
- aix*)
- ax_pthread_check_macro="_THREAD_SAFE"
- ;;
-
- *)
- ax_pthread_check_macro="--"
- ;;
-esac
-if test "x$ax_pthread_check_macro" = "x--"; then :
- ax_pthread_check_cond=0
-else
- ax_pthread_check_cond="!defined($ax_pthread_check_macro)"
-fi
-
-# Are we compiling with Clang?
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC is Clang" >&5
-$as_echo_n "checking whether $CC is Clang... " >&6; }
-if ${ax_cv_PTHREAD_CLANG+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ax_cv_PTHREAD_CLANG=no
- # Note that Autoconf sets GCC=yes for Clang as well as GCC
- if test "x$GCC" = "xyes"; then
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-/* Note: Clang 2.7 lacks __clang_[a-z]+__ */
-# if defined(__clang__) && defined(__llvm__)
- AX_PTHREAD_CC_IS_CLANG
-# endif
-
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "AX_PTHREAD_CC_IS_CLANG" >/dev/null 2>&1; then :
- ax_cv_PTHREAD_CLANG=yes
-fi
-rm -f conftest*
-
- fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_CLANG" >&5
-$as_echo "$ax_cv_PTHREAD_CLANG" >&6; }
-ax_pthread_clang="$ax_cv_PTHREAD_CLANG"
-
-ax_pthread_clang_warning=no
-
-# Clang needs special handling, because older versions handle the -pthread
-# option in a rather... idiosyncratic way
-
-if test "x$ax_pthread_clang" = "xyes"; then
-
- # Clang takes -pthread; it has never supported any other flag
-
- # (Note 1: This will need to be revisited if a system that Clang
- # supports has POSIX threads in a separate library. This tends not
- # to be the way of modern systems, but it's conceivable.)
-
- # (Note 2: On some systems, notably Darwin, -pthread is not needed
- # to get POSIX threads support; the API is always present and
- # active. We could reasonably leave PTHREAD_CFLAGS empty. But
- # -pthread does define _REENTRANT, and while the Darwin headers
- # ignore this macro, third-party headers might not.)
-
- PTHREAD_CFLAGS="-pthread"
- PTHREAD_LIBS=
-
- ax_pthread_ok=yes
-
- # However, older versions of Clang make a point of warning the user
- # that, in an invocation where only linking and no compilation is
- # taking place, the -pthread option has no effect ("argument unused
- # during compilation"). They expect -pthread to be passed in only
- # when source code is being compiled.
- #
- # Problem is, this is at odds with the way Automake and most other
- # C build frameworks function, which is that the same flags used in
- # compilation (CFLAGS) are also used in linking. Many systems
- # supported by AX_PTHREAD require exactly this for POSIX threads
- # support, and in fact it is often not straightforward to specify a
- # flag that is used only in the compilation phase and not in
- # linking. Such a scenario is extremely rare in practice.
- #
- # Even though use of the -pthread flag in linking would only print
- # a warning, this can be a nuisance for well-run software projects
- # that build with -Werror. So if the active version of Clang has
- # this misfeature, we search for an option to squash it.
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether Clang needs flag to prevent \"argument unused\" warning when linking with -pthread" >&5
-$as_echo_n "checking whether Clang needs flag to prevent \"argument unused\" warning when linking with -pthread... " >&6; }
-if ${ax_cv_PTHREAD_CLANG_NO_WARN_FLAG+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ax_cv_PTHREAD_CLANG_NO_WARN_FLAG=unknown
- # Create an alternate version of $ac_link that compiles and
- # links in two steps (.c -> .o, .o -> exe) instead of one
- # (.c -> exe), because the warning occurs only in the second
- # step
- ax_pthread_save_ac_link="$ac_link"
- ax_pthread_sed='s/conftest\.\$ac_ext/conftest.$ac_objext/g'
- ax_pthread_link_step=`$as_echo "$ac_link" | sed "$ax_pthread_sed"`
- ax_pthread_2step_ac_link="($ac_compile) && (echo ==== >&5) && ($ax_pthread_link_step)"
- ax_pthread_save_CFLAGS="$CFLAGS"
- for ax_pthread_try in '' -Qunused-arguments -Wno-unused-command-line-argument unknown; do
- if test "x$ax_pthread_try" = "xunknown"; then :
- break
-fi
- CFLAGS="-Werror -Wunknown-warning-option $ax_pthread_try -pthread $ax_pthread_save_CFLAGS"
- ac_link="$ax_pthread_save_ac_link"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-int main(void){return 0;}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_link="$ax_pthread_2step_ac_link"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-int main(void){return 0;}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- break
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- done
- ac_link="$ax_pthread_save_ac_link"
- CFLAGS="$ax_pthread_save_CFLAGS"
- if test "x$ax_pthread_try" = "x"; then :
- ax_pthread_try=no
-fi
- ax_cv_PTHREAD_CLANG_NO_WARN_FLAG="$ax_pthread_try"
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_CLANG_NO_WARN_FLAG" >&5
-$as_echo "$ax_cv_PTHREAD_CLANG_NO_WARN_FLAG" >&6; }
-
- case "$ax_cv_PTHREAD_CLANG_NO_WARN_FLAG" in
- no | unknown) ;;
- *) PTHREAD_CFLAGS="$ax_cv_PTHREAD_CLANG_NO_WARN_FLAG $PTHREAD_CFLAGS" ;;
- esac
-
-fi # $ax_pthread_clang = yes
-
-if test "x$ax_pthread_ok" = "xno"; then
-for ax_pthread_try_flag in $ax_pthread_flags; do
-
- case $ax_pthread_try_flag in
- none)
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads work without any flags" >&5
-$as_echo_n "checking whether pthreads work without any flags... " >&6; }
- ;;
-
- -mt,pthread)
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads work with -mt -lpthread" >&5
-$as_echo_n "checking whether pthreads work with -mt -lpthread... " >&6; }
- PTHREAD_CFLAGS="-mt"
- PTHREAD_LIBS="-lpthread"
- ;;
-
- -*)
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthreads work with $ax_pthread_try_flag" >&5
-$as_echo_n "checking whether pthreads work with $ax_pthread_try_flag... " >&6; }
- PTHREAD_CFLAGS="$ax_pthread_try_flag"
- ;;
-
- pthread-config)
- # Extract the first word of "pthread-config", so it can be a program name with args.
-set dummy pthread-config; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ax_pthread_config+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ax_pthread_config"; then
- ac_cv_prog_ax_pthread_config="$ax_pthread_config" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ax_pthread_config="yes"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
- test -z "$ac_cv_prog_ax_pthread_config" && ac_cv_prog_ax_pthread_config="no"
-fi
-fi
-ax_pthread_config=$ac_cv_prog_ax_pthread_config
-if test -n "$ax_pthread_config"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_config" >&5
-$as_echo "$ax_pthread_config" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- if test "x$ax_pthread_config" = "xno"; then :
- continue
-fi
- PTHREAD_CFLAGS="`pthread-config --cflags`"
- PTHREAD_LIBS="`pthread-config --ldflags` `pthread-config --libs`"
- ;;
-
- *)
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the pthreads library -l$ax_pthread_try_flag" >&5
-$as_echo_n "checking for the pthreads library -l$ax_pthread_try_flag... " >&6; }
- PTHREAD_LIBS="-l$ax_pthread_try_flag"
- ;;
- esac
-
- ax_pthread_save_CFLAGS="$CFLAGS"
- ax_pthread_save_LIBS="$LIBS"
- CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
- LIBS="$PTHREAD_LIBS $LIBS"
-
- # Check for various functions. We must include pthread.h,
- # since some functions may be macros. (On the Sequent, we
- # need a special flag -Kthread to make this header compile.)
- # We check for pthread_join because it is in -lpthread on IRIX
- # while pthread_create is in libc. We check for pthread_attr_init
- # due to DEC craziness with -lpthreads. We check for
- # pthread_cleanup_push because it is one of the few pthread
- # functions on Solaris that doesn't have a non-functional libc stub.
- # We try pthread_create on general principles.
-
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <pthread.h>
-# if $ax_pthread_check_cond
-# error "$ax_pthread_check_macro must be defined"
-# endif
- static void routine(void *a) { a = 0; }
- static void *start_routine(void *a) { return a; }
-int
-main ()
-{
-pthread_t th; pthread_attr_t attr;
- pthread_create(&th, 0, start_routine, 0);
- pthread_join(th, 0);
- pthread_attr_init(&attr);
- pthread_cleanup_push(routine, 0);
- pthread_cleanup_pop(0) /* ; */
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ax_pthread_ok=yes
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-
- CFLAGS="$ax_pthread_save_CFLAGS"
- LIBS="$ax_pthread_save_LIBS"
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_pthread_ok" >&5
-$as_echo "$ax_pthread_ok" >&6; }
- if test "x$ax_pthread_ok" = "xyes"; then :
- break
-fi
-
- PTHREAD_LIBS=""
- PTHREAD_CFLAGS=""
-done
-fi
-
-# Various other checks:
-if test "x$ax_pthread_ok" = "xyes"; then
- ax_pthread_save_CFLAGS="$CFLAGS"
- ax_pthread_save_LIBS="$LIBS"
- CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
- LIBS="$PTHREAD_LIBS $LIBS"
-
- # Detect AIX lossage: JOINABLE attribute is called UNDETACHED.
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for joinable pthread attribute" >&5
-$as_echo_n "checking for joinable pthread attribute... " >&6; }
-if ${ax_cv_PTHREAD_JOINABLE_ATTR+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ax_cv_PTHREAD_JOINABLE_ATTR=unknown
- for ax_pthread_attr in PTHREAD_CREATE_JOINABLE PTHREAD_CREATE_UNDETACHED; do
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <pthread.h>
-int
-main ()
-{
-int attr = $ax_pthread_attr; return attr /* ; */
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ax_cv_PTHREAD_JOINABLE_ATTR=$ax_pthread_attr; break
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- done
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_JOINABLE_ATTR" >&5
-$as_echo "$ax_cv_PTHREAD_JOINABLE_ATTR" >&6; }
- if test "x$ax_cv_PTHREAD_JOINABLE_ATTR" != "xunknown" && \
- test "x$ax_cv_PTHREAD_JOINABLE_ATTR" != "xPTHREAD_CREATE_JOINABLE" && \
- test "x$ax_pthread_joinable_attr_defined" != "xyes"; then :
-
-cat >>confdefs.h <<_ACEOF
-#define PTHREAD_CREATE_JOINABLE $ax_cv_PTHREAD_JOINABLE_ATTR
-_ACEOF
-
- ax_pthread_joinable_attr_defined=yes
-
-fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether more special flags are required for pthreads" >&5
-$as_echo_n "checking whether more special flags are required for pthreads... " >&6; }
-if ${ax_cv_PTHREAD_SPECIAL_FLAGS+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ax_cv_PTHREAD_SPECIAL_FLAGS=no
- case $host_os in
- solaris*)
- ax_cv_PTHREAD_SPECIAL_FLAGS="-D_POSIX_PTHREAD_SEMANTICS"
- ;;
- esac
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_SPECIAL_FLAGS" >&5
-$as_echo "$ax_cv_PTHREAD_SPECIAL_FLAGS" >&6; }
- if test "x$ax_cv_PTHREAD_SPECIAL_FLAGS" != "xno" && \
- test "x$ax_pthread_special_flags_added" != "xyes"; then :
- PTHREAD_CFLAGS="$ax_cv_PTHREAD_SPECIAL_FLAGS $PTHREAD_CFLAGS"
- ax_pthread_special_flags_added=yes
-fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PTHREAD_PRIO_INHERIT" >&5
-$as_echo_n "checking for PTHREAD_PRIO_INHERIT... " >&6; }
-if ${ax_cv_PTHREAD_PRIO_INHERIT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <pthread.h>
-int
-main ()
-{
-int i = PTHREAD_PRIO_INHERIT;
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ax_cv_PTHREAD_PRIO_INHERIT=yes
-else
- ax_cv_PTHREAD_PRIO_INHERIT=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_PTHREAD_PRIO_INHERIT" >&5
-$as_echo "$ax_cv_PTHREAD_PRIO_INHERIT" >&6; }
- if test "x$ax_cv_PTHREAD_PRIO_INHERIT" = "xyes" && \
- test "x$ax_pthread_prio_inherit_defined" != "xyes"; then :
-
-$as_echo "#define HAVE_PTHREAD_PRIO_INHERIT 1" >>confdefs.h
-
- ax_pthread_prio_inherit_defined=yes
-
-fi
-
- CFLAGS="$ax_pthread_save_CFLAGS"
- LIBS="$ax_pthread_save_LIBS"
-
- # More AIX lossage: compile with *_r variant
- if test "x$GCC" != "xyes"; then
- case $host_os in
- aix*)
- case "x/$CC" in #(
- x*/c89|x*/c89_128|x*/c99|x*/c99_128|x*/cc|x*/cc128|x*/xlc|x*/xlc_v6|x*/xlc128|x*/xlc128_v6) :
- #handle absolute path differently from PATH based program lookup
- case "x$CC" in #(
- x/*) :
- if as_fn_executable_p ${CC}_r; then :
- PTHREAD_CC="${CC}_r"
-fi ;; #(
- *) :
- for ac_prog in ${CC}_r
-do
- # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_PTHREAD_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$PTHREAD_CC"; then
- ac_cv_prog_PTHREAD_CC="$PTHREAD_CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_PTHREAD_CC="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-PTHREAD_CC=$ac_cv_prog_PTHREAD_CC
-if test -n "$PTHREAD_CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PTHREAD_CC" >&5
-$as_echo "$PTHREAD_CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$PTHREAD_CC" && break
-done
-test -n "$PTHREAD_CC" || PTHREAD_CC="$CC"
- ;;
-esac ;; #(
- *) :
- ;;
-esac
- ;;
- esac
- fi
-fi
-
-test -n "$PTHREAD_CC" || PTHREAD_CC="$CC"
-
-
-
-
-
-# Finally, execute ACTION-IF-FOUND/ACTION-IF-NOT-FOUND:
-if test "x$ax_pthread_ok" = "xyes"; then
- threads=yes
- :
-else
- ax_pthread_ok=no
- threads=no
-fi
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-
-fi
-
-if test "$threads" = "yes"; then
-
-$as_echo "#define ENABLE_THREADS 1" >>confdefs.h
-
-fi
- if test "$threads" = "yes"; then
- THREADS_TRUE=
- THREADS_FALSE='#'
-else
- THREADS_TRUE='#'
- THREADS_FALSE=
-fi
-
-
-# Used to validate --package-metadata= input. Disabled by default.
-# Check whether --enable-jansson was given.
-if test "${enable_jansson+set}" = set; then :
- enableval=$enable_jansson; enable_jansson=$enableval
-else
- enable_jansson="no"
-fi
-
-
-if test "x$enable_jansson" != "xno"; then
-
-
-
-
-
-
-
-if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
-set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_PKG_CONFIG+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $PKG_CONFIG in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
- ;;
- *)
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
- ;;
-esac
-fi
-PKG_CONFIG=$ac_cv_path_PKG_CONFIG
-if test -n "$PKG_CONFIG"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
-$as_echo "$PKG_CONFIG" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_path_PKG_CONFIG"; then
- ac_pt_PKG_CONFIG=$PKG_CONFIG
- # Extract the first word of "pkg-config", so it can be a program name with args.
-set dummy pkg-config; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $ac_pt_PKG_CONFIG in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
- ;;
- *)
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
- ;;
-esac
-fi
-ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
-if test -n "$ac_pt_PKG_CONFIG"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5
-$as_echo "$ac_pt_PKG_CONFIG" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_pt_PKG_CONFIG" = x; then
- PKG_CONFIG=""
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- PKG_CONFIG=$ac_pt_PKG_CONFIG
- fi
-else
- PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
-fi
-
-fi
-if test -n "$PKG_CONFIG"; then
- _pkg_min_version=0.9.0
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5
-$as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; }
- if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- PKG_CONFIG=""
- fi
-fi
- if test -n "$PKG_CONFIG"; then :
-
-
-pkg_failed=no
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for jansson" >&5
-$as_echo_n "checking for jansson... " >&6; }
-
-if test -n "$JANSSON_CFLAGS"; then
- pkg_cv_JANSSON_CFLAGS="$JANSSON_CFLAGS"
- elif test -n "$PKG_CONFIG"; then
- if test -n "$PKG_CONFIG" && \
- { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"jansson\""; } >&5
- ($PKG_CONFIG --exists --print-errors "jansson") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- pkg_cv_JANSSON_CFLAGS=`$PKG_CONFIG --cflags "jansson" 2>/dev/null`
- test "x$?" != "x0" && pkg_failed=yes
-else
- pkg_failed=yes
-fi
- else
- pkg_failed=untried
-fi
-if test -n "$JANSSON_LIBS"; then
- pkg_cv_JANSSON_LIBS="$JANSSON_LIBS"
- elif test -n "$PKG_CONFIG"; then
- if test -n "$PKG_CONFIG" && \
- { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"jansson\""; } >&5
- ($PKG_CONFIG --exists --print-errors "jansson") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- pkg_cv_JANSSON_LIBS=`$PKG_CONFIG --libs "jansson" 2>/dev/null`
- test "x$?" != "x0" && pkg_failed=yes
-else
- pkg_failed=yes
-fi
- else
- pkg_failed=untried
-fi
-
-if test $pkg_failed = no; then
- pkg_save_LDFLAGS="$LDFLAGS"
- LDFLAGS="$LDFLAGS $pkg_cv_JANSSON_LIBS"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
-
-else
- pkg_failed=yes
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LDFLAGS=$pkg_save_LDFLAGS
-fi
-
-
-
-if test $pkg_failed = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-
-if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
- _pkg_short_errors_supported=yes
-else
- _pkg_short_errors_supported=no
-fi
- if test $_pkg_short_errors_supported = yes; then
- JANSSON_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "jansson" 2>&1`
- else
- JANSSON_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "jansson" 2>&1`
- fi
- # Put the nasty error message in config.log where it belongs
- echo "$JANSSON_PKG_ERRORS" >&5
-
-
- as_fn_error $? "Cannot find jansson library" "$LINENO" 5
-
-elif test $pkg_failed = untried; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-
- as_fn_error $? "Cannot find jansson library" "$LINENO" 5
-
-else
- JANSSON_CFLAGS=$pkg_cv_JANSSON_CFLAGS
- JANSSON_LIBS=$pkg_cv_JANSSON_LIBS
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-
-
-$as_echo "#define HAVE_JANSSON 1" >>confdefs.h
-
-
-
-
-fi
-
-else
-
- as_fn_error $? "Cannot find pkg-config" "$LINENO" 5
-
-fi
-fi
-
-ac_fn_c_check_decl "$LINENO" "basename" "ac_cv_have_decl_basename" "$ac_includes_default"
-if test "x$ac_cv_have_decl_basename" = xyes; then :
- ac_have_decl=1
-else
- ac_have_decl=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define HAVE_DECL_BASENAME $ac_have_decl
-_ACEOF
-ac_fn_c_check_decl "$LINENO" "ffs" "ac_cv_have_decl_ffs" "$ac_includes_default"
-if test "x$ac_cv_have_decl_ffs" = xyes; then :
- ac_have_decl=1
-else
- ac_have_decl=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define HAVE_DECL_FFS $ac_have_decl
-_ACEOF
-ac_fn_c_check_decl "$LINENO" "asprintf" "ac_cv_have_decl_asprintf" "$ac_includes_default"
-if test "x$ac_cv_have_decl_asprintf" = xyes; then :
- ac_have_decl=1
-else
- ac_have_decl=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define HAVE_DECL_ASPRINTF $ac_have_decl
-_ACEOF
-ac_fn_c_check_decl "$LINENO" "vasprintf" "ac_cv_have_decl_vasprintf" "$ac_includes_default"
-if test "x$ac_cv_have_decl_vasprintf" = xyes; then :
- ac_have_decl=1
-else
- ac_have_decl=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define HAVE_DECL_VASPRINTF $ac_have_decl
-_ACEOF
-ac_fn_c_check_decl "$LINENO" "snprintf" "ac_cv_have_decl_snprintf" "$ac_includes_default"
-if test "x$ac_cv_have_decl_snprintf" = xyes; then :
- ac_have_decl=1
-else
- ac_have_decl=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define HAVE_DECL_SNPRINTF $ac_have_decl
-_ACEOF
-ac_fn_c_check_decl "$LINENO" "vsnprintf" "ac_cv_have_decl_vsnprintf" "$ac_includes_default"
-if test "x$ac_cv_have_decl_vsnprintf" = xyes; then :
- ac_have_decl=1
-else
- ac_have_decl=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define HAVE_DECL_VSNPRINTF $ac_have_decl
-_ACEOF
-ac_fn_c_check_decl "$LINENO" "strverscmp" "ac_cv_have_decl_strverscmp" "$ac_includes_default"
-if test "x$ac_cv_have_decl_strverscmp" = xyes; then :
- ac_have_decl=1
-else
- ac_have_decl=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define HAVE_DECL_STRVERSCMP $ac_have_decl
-_ACEOF
-
-
-save_CFLAGS="$CFLAGS"
-CFLAGS="$CFLAGS -Werror -gpubnames"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-int i;
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- have_pubnames=yes
-else
- have_pubnames=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-CFLAGS="$save_CFLAGS"
- if test "$have_pubnames" = "yes"; then
- HAVE_PUBNAMES_TRUE=
- HAVE_PUBNAMES_FALSE='#'
-else
- HAVE_PUBNAMES_TRUE='#'
- HAVE_PUBNAMES_FALSE=
-fi
-
-
-save_CFLAGS="$CFLAGS"
-CFLAGS="$CFLAGS -Werror -fno-use-linker-plugin"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-int i;
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- have_no_use_linker_plugin=yes
-else
- have_no_use_linker_plugin=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-CFLAGS="$save_CFLAGS"
- if test "$have_no_use_linker_plugin" = "yes"; then
- HAVE_NO_USE_LINKER_PLUGIN_TRUE=
- HAVE_NO_USE_LINKER_PLUGIN_FALSE='#'
-else
- HAVE_NO_USE_LINKER_PLUGIN_TRUE='#'
- HAVE_NO_USE_LINKER_PLUGIN_FALSE=
-fi
-
-
-ac_ext=cpp
-ac_cpp='$CXXCPP $CPPFLAGS'
-ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
-
-
-
-ac_ext=cpp
-ac_cpp='$CXXCPP $CPPFLAGS'
-ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C++ preprocessor" >&5
-$as_echo_n "checking how to run the C++ preprocessor... " >&6; }
-if test -z "$CXXCPP"; then
- if ${ac_cv_prog_CXXCPP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- # Double quotes because CXXCPP needs to be expanded
- for CXXCPP in "$CXX -E" "/lib/cpp"
- do
- ac_preproc_ok=false
-for ac_cxx_preproc_warn_flag in '' yes
-do
- # Use a header file that comes with gcc, so configuring glibc
- # with a fresh cross-compiler works.
- # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
- # <limits.h> exists even on freestanding compilers.
- # On the NeXT, cc -E runs the code through the compiler's parser,
- # not just through cpp. "Syntax error" is here to catch this case.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#ifdef __STDC__
-# include <limits.h>
-#else
-# include <assert.h>
-#endif
- Syntax error
-_ACEOF
-if ac_fn_cxx_try_cpp "$LINENO"; then :
-
-else
- # Broken: fails on valid input.
-continue
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-
- # OK, works on sane cases. Now check whether nonexistent headers
- # can be detected and how.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <ac_nonexistent.h>
-_ACEOF
-if ac_fn_cxx_try_cpp "$LINENO"; then :
- # Broken: success on invalid input.
-continue
-else
- # Passes both tests.
-ac_preproc_ok=:
-break
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-
-done
-# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
-rm -f conftest.i conftest.err conftest.$ac_ext
-if $ac_preproc_ok; then :
- break
-fi
-
- done
- ac_cv_prog_CXXCPP=$CXXCPP
-
-fi
- CXXCPP=$ac_cv_prog_CXXCPP
-else
- ac_cv_prog_CXXCPP=$CXXCPP
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXXCPP" >&5
-$as_echo "$CXXCPP" >&6; }
-ac_preproc_ok=false
-for ac_cxx_preproc_warn_flag in '' yes
-do
- # Use a header file that comes with gcc, so configuring glibc
- # with a fresh cross-compiler works.
- # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
- # <limits.h> exists even on freestanding compilers.
- # On the NeXT, cc -E runs the code through the compiler's parser,
- # not just through cpp. "Syntax error" is here to catch this case.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#ifdef __STDC__
-# include <limits.h>
-#else
-# include <assert.h>
-#endif
- Syntax error
-_ACEOF
-if ac_fn_cxx_try_cpp "$LINENO"; then :
-
-else
- # Broken: fails on valid input.
-continue
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-
- # OK, works on sane cases. Now check whether nonexistent headers
- # can be detected and how.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <ac_nonexistent.h>
-_ACEOF
-if ac_fn_cxx_try_cpp "$LINENO"; then :
- # Broken: success on invalid input.
-continue
-else
- # Passes both tests.
-ac_preproc_ok=:
-break
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-
-done
-# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
-rm -f conftest.i conftest.err conftest.$ac_ext
-if $ac_preproc_ok; then :
-
-else
- { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "C++ preprocessor \"$CXXCPP\" fails sanity check
-See \`config.log' for more details" "$LINENO" 5; }
-fi
-
-ac_ext=cpp
-ac_cpp='$CXXCPP $CPPFLAGS'
-ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
-
-
-for ac_header in unordered_set unordered_map
-do :
- as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
-ac_fn_cxx_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
-if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
- cat >>confdefs.h <<_ACEOF
-#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
-_ACEOF
-
-fi
-
-done
-
-for ac_header in tr1/unordered_set tr1/unordered_map
-do :
- as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
-ac_fn_cxx_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
-if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
- cat >>confdefs.h <<_ACEOF
-#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
-_ACEOF
-
-fi
-
-done
-
-for ac_header in ext/hash_map ext/hash_set
-do :
- as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
-ac_fn_cxx_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
-if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
- cat >>confdefs.h <<_ACEOF
-#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
-_ACEOF
-
-fi
-
-done
-
-for ac_header in byteswap.h
-do :
- ac_fn_cxx_check_header_mongrel "$LINENO" "byteswap.h" "ac_cv_header_byteswap_h" "$ac_includes_default"
-if test "x$ac_cv_header_byteswap_h" = xyes; then :
- cat >>confdefs.h <<_ACEOF
-#define HAVE_BYTESWAP_H 1
-_ACEOF
-
-fi
-
-done
-
-
-ac_fn_cxx_check_decl "$LINENO" "bswap_16" "ac_cv_have_decl_bswap_16" "#include <byteswap.h>
-"
-if test "x$ac_cv_have_decl_bswap_16" = xyes; then :
- ac_have_decl=1
-else
- ac_have_decl=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define HAVE_DECL_BSWAP_16 $ac_have_decl
-_ACEOF
-ac_fn_cxx_check_decl "$LINENO" "bswap_32" "ac_cv_have_decl_bswap_32" "#include <byteswap.h>
-"
-if test "x$ac_cv_have_decl_bswap_32" = xyes; then :
- ac_have_decl=1
-else
- ac_have_decl=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define HAVE_DECL_BSWAP_32 $ac_have_decl
-_ACEOF
-ac_fn_cxx_check_decl "$LINENO" "bswap_64" "ac_cv_have_decl_bswap_64" "#include <byteswap.h>
-"
-if test "x$ac_cv_have_decl_bswap_64" = xyes; then :
- ac_have_decl=1
-else
- ac_have_decl=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define HAVE_DECL_BSWAP_64 $ac_have_decl
-_ACEOF
-
-
-for ac_header in windows.h
-do :
- ac_fn_cxx_check_header_mongrel "$LINENO" "windows.h" "ac_cv_header_windows_h" "$ac_includes_default"
-if test "x$ac_cv_header_windows_h" = xyes; then :
- cat >>confdefs.h <<_ACEOF
-#define HAVE_WINDOWS_H 1
-_ACEOF
-
-fi
-
-done
-
-for ac_header in dlfcn.h
-do :
- ac_fn_cxx_check_header_mongrel "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default"
-if test "x$ac_cv_header_dlfcn_h" = xyes; then :
- cat >>confdefs.h <<_ACEOF
-#define HAVE_DLFCN_H 1
-_ACEOF
-
-fi
-
-done
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing dlopen" >&5
-$as_echo_n "checking for library containing dlopen... " >&6; }
-if ${ac_cv_search_dlopen+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_func_search_save_LIBS=$LIBS
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char dlopen ();
-int
-main ()
-{
-return dlopen ();
- ;
- return 0;
-}
-_ACEOF
-for ac_lib in '' dl dld; do
- if test -z "$ac_lib"; then
- ac_res="none required"
- else
- ac_res=-l$ac_lib
- LIBS="-l$ac_lib $ac_func_search_save_LIBS"
- fi
- if ac_fn_cxx_try_link "$LINENO"; then :
- ac_cv_search_dlopen=$ac_res
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext
- if ${ac_cv_search_dlopen+:} false; then :
- break
-fi
-done
-if ${ac_cv_search_dlopen+:} false; then :
-
-else
- ac_cv_search_dlopen=no
-fi
-rm conftest.$ac_ext
-LIBS=$ac_func_search_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_dlopen" >&5
-$as_echo "$ac_cv_search_dlopen" >&6; }
-ac_res=$ac_cv_search_dlopen
-if test "$ac_res" != no; then :
- test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
-
-fi
-
-case "$ac_cv_search_dlopen" in
- no*) DLOPEN_LIBS="";;
- *) DLOPEN_LIBS="$ac_cv_search_dlopen";;
-esac
-
-
-for ac_func in mallinfo mallinfo2 posix_fallocate fallocate readv sysconf times mkdtemp
-do :
- as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
-ac_fn_cxx_check_func "$LINENO" "$ac_func" "$as_ac_var"
-if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
- cat >>confdefs.h <<_ACEOF
-#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
-_ACEOF
-
-fi
-done
-
-ac_fn_cxx_check_decl "$LINENO" "basename" "ac_cv_have_decl_basename" "$ac_includes_default"
-if test "x$ac_cv_have_decl_basename" = xyes; then :
- ac_have_decl=1
-else
- ac_have_decl=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define HAVE_DECL_BASENAME $ac_have_decl
-_ACEOF
-ac_fn_cxx_check_decl "$LINENO" "ffs" "ac_cv_have_decl_ffs" "$ac_includes_default"
-if test "x$ac_cv_have_decl_ffs" = xyes; then :
- ac_have_decl=1
-else
- ac_have_decl=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define HAVE_DECL_FFS $ac_have_decl
-_ACEOF
-ac_fn_cxx_check_decl "$LINENO" "asprintf" "ac_cv_have_decl_asprintf" "$ac_includes_default"
-if test "x$ac_cv_have_decl_asprintf" = xyes; then :
- ac_have_decl=1
-else
- ac_have_decl=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define HAVE_DECL_ASPRINTF $ac_have_decl
-_ACEOF
-ac_fn_cxx_check_decl "$LINENO" "vasprintf" "ac_cv_have_decl_vasprintf" "$ac_includes_default"
-if test "x$ac_cv_have_decl_vasprintf" = xyes; then :
- ac_have_decl=1
-else
- ac_have_decl=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define HAVE_DECL_VASPRINTF $ac_have_decl
-_ACEOF
-ac_fn_cxx_check_decl "$LINENO" "snprintf" "ac_cv_have_decl_snprintf" "$ac_includes_default"
-if test "x$ac_cv_have_decl_snprintf" = xyes; then :
- ac_have_decl=1
-else
- ac_have_decl=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define HAVE_DECL_SNPRINTF $ac_have_decl
-_ACEOF
-ac_fn_cxx_check_decl "$LINENO" "vsnprintf" "ac_cv_have_decl_vsnprintf" "$ac_includes_default"
-if test "x$ac_cv_have_decl_vsnprintf" = xyes; then :
- ac_have_decl=1
-else
- ac_have_decl=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define HAVE_DECL_VSNPRINTF $ac_have_decl
-_ACEOF
-ac_fn_cxx_check_decl "$LINENO" "strverscmp" "ac_cv_have_decl_strverscmp" "$ac_includes_default"
-if test "x$ac_cv_have_decl_strverscmp" = xyes; then :
- ac_have_decl=1
-else
- ac_have_decl=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define HAVE_DECL_STRVERSCMP $ac_have_decl
-_ACEOF
-ac_fn_cxx_check_decl "$LINENO" "strndup" "ac_cv_have_decl_strndup" "$ac_includes_default"
-if test "x$ac_cv_have_decl_strndup" = xyes; then :
- ac_have_decl=1
-else
- ac_have_decl=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define HAVE_DECL_STRNDUP $ac_have_decl
-_ACEOF
-ac_fn_cxx_check_decl "$LINENO" "memmem" "ac_cv_have_decl_memmem" "$ac_includes_default"
-if test "x$ac_cv_have_decl_memmem" = xyes; then :
- ac_have_decl=1
-else
- ac_have_decl=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define HAVE_DECL_MEMMEM $ac_have_decl
-_ACEOF
-
-
-# Use of ::std::tr1::unordered_map::rehash causes undefined symbols
-# at link time with some versions of GCC.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ::std::tr1::unordered_map::rehash is usable." >&5
-$as_echo_n "checking whether ::std::tr1::unordered_map::rehash is usable.... " >&6; }
-if ${gold_cv_unordered_map_rehash+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <tr1/unordered_map>
-void bar() { ::std::tr1::unordered_map<int, int> x; x.rehash(10); }
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_cxx_try_link "$LINENO"; then :
- gold_cv_unordered_map_rehash=yes
-else
- gold_cv_unordered_map_rehash=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gold_cv_unordered_map_rehash" >&5
-$as_echo "$gold_cv_unordered_map_rehash" >&6; }
-if test "$gold_cv_unordered_map_rehash" = "yes"; then
-
-$as_echo "#define HAVE_TR1_UNORDERED_MAP_REHASH 1" >>confdefs.h
-
-fi
-
-# Since 5e9091dab8858b25210a91d22fbbbfdee9c969ad gold now requires C++11
-# So we need to check for it.
- ax_cxx_compile_alternatives="11 0x" ax_cxx_compile_cxx11_required=true
- ac_ext=cpp
-ac_cpp='$CXXCPP $CPPFLAGS'
-ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
- ac_success=no
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX supports C++11 features by default" >&5
-$as_echo_n "checking whether $CXX supports C++11 features by default... " >&6; }
-if ${ax_cv_cxx_compile_cxx11+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-
-// If the compiler admits that it is not ready for C++11, why torture it?
-// Hopefully, this will speed up the test.
-
-#ifndef __cplusplus
-
-#error "This is not a C++ compiler"
-
-#elif __cplusplus < 201103L
-
-#error "This is not a C++11 compiler"
-
-#else
-
-namespace cxx11
-{
-
- namespace test_static_assert
- {
-
- template <typename T>
- struct check
- {
- static_assert(sizeof(int) <= sizeof(T), "not big enough");
- };
-
- }
-
- namespace test_final_override
- {
-
- struct Base
- {
- virtual ~Base() {}
- virtual void f() {}
- };
-
- struct Derived : public Base
- {
- virtual ~Derived() override {}
- virtual void f() override {}
- };
-
- }
-
- namespace test_double_right_angle_brackets
- {
-
- template < typename T >
- struct check {};
-
- typedef check<void> single_type;
- typedef check<check<void>> double_type;
- typedef check<check<check<void>>> triple_type;
- typedef check<check<check<check<void>>>> quadruple_type;
-
- }
-
- namespace test_decltype
- {
-
- int
- f()
- {
- int a = 1;
- decltype(a) b = 2;
- return a + b;
- }
-
- }
-
- namespace test_type_deduction
- {
-
- template < typename T1, typename T2 >
- struct is_same
- {
- static const bool value = false;
- };
-
- template < typename T >
- struct is_same<T, T>
- {
- static const bool value = true;
- };
-
- template < typename T1, typename T2 >
- auto
- add(T1 a1, T2 a2) -> decltype(a1 + a2)
- {
- return a1 + a2;
- }
-
- int
- test(const int c, volatile int v)
- {
- static_assert(is_same<int, decltype(0)>::value == true, "");
- static_assert(is_same<int, decltype(c)>::value == false, "");
- static_assert(is_same<int, decltype(v)>::value == false, "");
- auto ac = c;
- auto av = v;
- auto sumi = ac + av + 'x';
- auto sumf = ac + av + 1.0;
- static_assert(is_same<int, decltype(ac)>::value == true, "");
- static_assert(is_same<int, decltype(av)>::value == true, "");
- static_assert(is_same<int, decltype(sumi)>::value == true, "");
- static_assert(is_same<int, decltype(sumf)>::value == false, "");
- static_assert(is_same<int, decltype(add(c, v))>::value == true, "");
- return (sumf > 0.0) ? sumi : add(c, v);
- }
-
- }
-
- namespace test_noexcept
- {
-
- int f() { return 0; }
- int g() noexcept { return 0; }
-
- static_assert(noexcept(f()) == false, "");
- static_assert(noexcept(g()) == true, "");
-
- }
-
- namespace test_constexpr
- {
-
- template < typename CharT >
- unsigned long constexpr
- strlen_c_r(const CharT *const s, const unsigned long acc) noexcept
- {
- return *s ? strlen_c_r(s + 1, acc + 1) : acc;
- }
-
- template < typename CharT >
- unsigned long constexpr
- strlen_c(const CharT *const s) noexcept
- {
- return strlen_c_r(s, 0UL);
- }
-
- static_assert(strlen_c("") == 0UL, "");
- static_assert(strlen_c("1") == 1UL, "");
- static_assert(strlen_c("example") == 7UL, "");
- static_assert(strlen_c("another\0example") == 7UL, "");
-
- }
-
- namespace test_rvalue_references
- {
-
- template < int N >
- struct answer
- {
- static constexpr int value = N;
- };
-
- answer<1> f(int&) { return answer<1>(); }
- answer<2> f(const int&) { return answer<2>(); }
- answer<3> f(int&&) { return answer<3>(); }
-
- void
- test()
- {
- int i = 0;
- const int c = 0;
- static_assert(decltype(f(i))::value == 1, "");
- static_assert(decltype(f(c))::value == 2, "");
- static_assert(decltype(f(0))::value == 3, "");
- }
-
- }
-
- namespace test_uniform_initialization
- {
-
- struct test
- {
- static const int zero {};
- static const int one {1};
- };
-
- static_assert(test::zero == 0, "");
- static_assert(test::one == 1, "");
-
- }
-
- namespace test_lambdas
- {
-
- void
- test1()
- {
- auto lambda1 = [](){};
- auto lambda2 = lambda1;
- lambda1();
- lambda2();
- }
-
- int
- test2()
- {
- auto a = [](int i, int j){ return i + j; }(1, 2);
- auto b = []() -> int { return '0'; }();
- auto c = [=](){ return a + b; }();
- auto d = [&](){ return c; }();
- auto e = [a, &b](int x) mutable {
- const auto identity = [](int y){ return y; };
- for (auto i = 0; i < a; ++i)
- a += b--;
- return x + identity(a + b);
- }(0);
- return a + b + c + d + e;
- }
-
- int
- test3()
- {
- const auto nullary = [](){ return 0; };
- const auto unary = [](int x){ return x; };
- using nullary_t = decltype(nullary);
- using unary_t = decltype(unary);
- const auto higher1st = [](nullary_t f){ return f(); };
- const auto higher2nd = [unary](nullary_t f1){
- return [unary, f1](unary_t f2){ return f2(unary(f1())); };
- };
- return higher1st(nullary) + higher2nd(nullary)(unary);
- }
-
- }
-
- namespace test_variadic_templates
- {
-
- template <int...>
- struct sum;
-
- template <int N0, int... N1toN>
- struct sum<N0, N1toN...>
- {
- static constexpr auto value = N0 + sum<N1toN...>::value;
- };
-
- template <>
- struct sum<>
- {
- static constexpr auto value = 0;
- };
-
- static_assert(sum<>::value == 0, "");
- static_assert(sum<1>::value == 1, "");
- static_assert(sum<23>::value == 23, "");
- static_assert(sum<1, 2>::value == 3, "");
- static_assert(sum<5, 5, 11>::value == 21, "");
- static_assert(sum<2, 3, 5, 7, 11, 13>::value == 41, "");
-
- }
-
- // http://stackoverflow.com/questions/13728184/template-aliases-and-sfinae
- // Clang 3.1 fails with headers of libstd++ 4.8.3 when using std::function
- // because of this.
- namespace test_template_alias_sfinae
- {
-
- struct foo {};
-
- template<typename T>
- using member = typename T::member_type;
-
- template<typename T>
- void func(...) {}
-
- template<typename T>
- void func(member<T>*) {}
-
- void test();
-
- void test() { func<foo>(0); }
-
- }
-
-} // namespace cxx11
-
-#endif // __cplusplus >= 201103L
-
-
-
-_ACEOF
-if ac_fn_cxx_try_compile "$LINENO"; then :
- ax_cv_cxx_compile_cxx11=yes
-else
- ax_cv_cxx_compile_cxx11=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ax_cv_cxx_compile_cxx11" >&5
-$as_echo "$ax_cv_cxx_compile_cxx11" >&6; }
- if test x$ax_cv_cxx_compile_cxx11 = xyes; then
- ac_success=yes
- fi
-
- if test x$ac_success = xno; then
- for alternative in ${ax_cxx_compile_alternatives}; do
- switch="-std=gnu++${alternative}"
- cachevar=`$as_echo "ax_cv_cxx_compile_cxx11_$switch" | $as_tr_sh`
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX supports C++11 features with $switch" >&5
-$as_echo_n "checking whether $CXX supports C++11 features with $switch... " >&6; }
-if eval \${$cachevar+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_save_CXX="$CXX"
- CXX="$CXX $switch"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-
-// If the compiler admits that it is not ready for C++11, why torture it?
-// Hopefully, this will speed up the test.
-
-#ifndef __cplusplus
-
-#error "This is not a C++ compiler"
-
-#elif __cplusplus < 201103L
-
-#error "This is not a C++11 compiler"
-
-#else
-
-namespace cxx11
-{
-
- namespace test_static_assert
- {
-
- template <typename T>
- struct check
- {
- static_assert(sizeof(int) <= sizeof(T), "not big enough");
- };
-
- }
-
- namespace test_final_override
- {
-
- struct Base
- {
- virtual ~Base() {}
- virtual void f() {}
- };
-
- struct Derived : public Base
- {
- virtual ~Derived() override {}
- virtual void f() override {}
- };
-
- }
-
- namespace test_double_right_angle_brackets
- {
-
- template < typename T >
- struct check {};
-
- typedef check<void> single_type;
- typedef check<check<void>> double_type;
- typedef check<check<check<void>>> triple_type;
- typedef check<check<check<check<void>>>> quadruple_type;
-
- }
-
- namespace test_decltype
- {
-
- int
- f()
- {
- int a = 1;
- decltype(a) b = 2;
- return a + b;
- }
-
- }
-
- namespace test_type_deduction
- {
-
- template < typename T1, typename T2 >
- struct is_same
- {
- static const bool value = false;
- };
-
- template < typename T >
- struct is_same<T, T>
- {
- static const bool value = true;
- };
-
- template < typename T1, typename T2 >
- auto
- add(T1 a1, T2 a2) -> decltype(a1 + a2)
- {
- return a1 + a2;
- }
-
- int
- test(const int c, volatile int v)
- {
- static_assert(is_same<int, decltype(0)>::value == true, "");
- static_assert(is_same<int, decltype(c)>::value == false, "");
- static_assert(is_same<int, decltype(v)>::value == false, "");
- auto ac = c;
- auto av = v;
- auto sumi = ac + av + 'x';
- auto sumf = ac + av + 1.0;
- static_assert(is_same<int, decltype(ac)>::value == true, "");
- static_assert(is_same<int, decltype(av)>::value == true, "");
- static_assert(is_same<int, decltype(sumi)>::value == true, "");
- static_assert(is_same<int, decltype(sumf)>::value == false, "");
- static_assert(is_same<int, decltype(add(c, v))>::value == true, "");
- return (sumf > 0.0) ? sumi : add(c, v);
- }
-
- }
-
- namespace test_noexcept
- {
-
- int f() { return 0; }
- int g() noexcept { return 0; }
-
- static_assert(noexcept(f()) == false, "");
- static_assert(noexcept(g()) == true, "");
-
- }
-
- namespace test_constexpr
- {
-
- template < typename CharT >
- unsigned long constexpr
- strlen_c_r(const CharT *const s, const unsigned long acc) noexcept
- {
- return *s ? strlen_c_r(s + 1, acc + 1) : acc;
- }
-
- template < typename CharT >
- unsigned long constexpr
- strlen_c(const CharT *const s) noexcept
- {
- return strlen_c_r(s, 0UL);
- }
-
- static_assert(strlen_c("") == 0UL, "");
- static_assert(strlen_c("1") == 1UL, "");
- static_assert(strlen_c("example") == 7UL, "");
- static_assert(strlen_c("another\0example") == 7UL, "");
-
- }
-
- namespace test_rvalue_references
- {
-
- template < int N >
- struct answer
- {
- static constexpr int value = N;
- };
-
- answer<1> f(int&) { return answer<1>(); }
- answer<2> f(const int&) { return answer<2>(); }
- answer<3> f(int&&) { return answer<3>(); }
-
- void
- test()
- {
- int i = 0;
- const int c = 0;
- static_assert(decltype(f(i))::value == 1, "");
- static_assert(decltype(f(c))::value == 2, "");
- static_assert(decltype(f(0))::value == 3, "");
- }
-
- }
-
- namespace test_uniform_initialization
- {
-
- struct test
- {
- static const int zero {};
- static const int one {1};
- };
-
- static_assert(test::zero == 0, "");
- static_assert(test::one == 1, "");
-
- }
-
- namespace test_lambdas
- {
-
- void
- test1()
- {
- auto lambda1 = [](){};
- auto lambda2 = lambda1;
- lambda1();
- lambda2();
- }
-
- int
- test2()
- {
- auto a = [](int i, int j){ return i + j; }(1, 2);
- auto b = []() -> int { return '0'; }();
- auto c = [=](){ return a + b; }();
- auto d = [&](){ return c; }();
- auto e = [a, &b](int x) mutable {
- const auto identity = [](int y){ return y; };
- for (auto i = 0; i < a; ++i)
- a += b--;
- return x + identity(a + b);
- }(0);
- return a + b + c + d + e;
- }
-
- int
- test3()
- {
- const auto nullary = [](){ return 0; };
- const auto unary = [](int x){ return x; };
- using nullary_t = decltype(nullary);
- using unary_t = decltype(unary);
- const auto higher1st = [](nullary_t f){ return f(); };
- const auto higher2nd = [unary](nullary_t f1){
- return [unary, f1](unary_t f2){ return f2(unary(f1())); };
- };
- return higher1st(nullary) + higher2nd(nullary)(unary);
- }
-
- }
-
- namespace test_variadic_templates
- {
-
- template <int...>
- struct sum;
-
- template <int N0, int... N1toN>
- struct sum<N0, N1toN...>
- {
- static constexpr auto value = N0 + sum<N1toN...>::value;
- };
-
- template <>
- struct sum<>
- {
- static constexpr auto value = 0;
- };
-
- static_assert(sum<>::value == 0, "");
- static_assert(sum<1>::value == 1, "");
- static_assert(sum<23>::value == 23, "");
- static_assert(sum<1, 2>::value == 3, "");
- static_assert(sum<5, 5, 11>::value == 21, "");
- static_assert(sum<2, 3, 5, 7, 11, 13>::value == 41, "");
-
- }
-
- // http://stackoverflow.com/questions/13728184/template-aliases-and-sfinae
- // Clang 3.1 fails with headers of libstd++ 4.8.3 when using std::function
- // because of this.
- namespace test_template_alias_sfinae
- {
-
- struct foo {};
-
- template<typename T>
- using member = typename T::member_type;
-
- template<typename T>
- void func(...) {}
-
- template<typename T>
- void func(member<T>*) {}
-
- void test();
-
- void test() { func<foo>(0); }
-
- }
-
-} // namespace cxx11
-
-#endif // __cplusplus >= 201103L
-
-
-
-_ACEOF
-if ac_fn_cxx_try_compile "$LINENO"; then :
- eval $cachevar=yes
-else
- eval $cachevar=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- CXX="$ac_save_CXX"
-fi
-eval ac_res=\$$cachevar
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
- if eval test x\$$cachevar = xyes; then
- CXX="$CXX $switch"
- if test -n "$CXXCPP" ; then
- CXXCPP="$CXXCPP $switch"
- fi
- ac_success=yes
- break
- fi
- done
- fi
-
- if test x$ac_success = xno; then
- for alternative in ${ax_cxx_compile_alternatives}; do
- for switch in -std=c++${alternative} +std=c++${alternative} "-h std=c++${alternative}"; do
- cachevar=`$as_echo "ax_cv_cxx_compile_cxx11_$switch" | $as_tr_sh`
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX supports C++11 features with $switch" >&5
-$as_echo_n "checking whether $CXX supports C++11 features with $switch... " >&6; }
-if eval \${$cachevar+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_save_CXX="$CXX"
- CXX="$CXX $switch"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-
-// If the compiler admits that it is not ready for C++11, why torture it?
-// Hopefully, this will speed up the test.
-
-#ifndef __cplusplus
-
-#error "This is not a C++ compiler"
-
-#elif __cplusplus < 201103L
-
-#error "This is not a C++11 compiler"
-
-#else
-
-namespace cxx11
-{
-
- namespace test_static_assert
- {
-
- template <typename T>
- struct check
- {
- static_assert(sizeof(int) <= sizeof(T), "not big enough");
- };
-
- }
-
- namespace test_final_override
- {
-
- struct Base
- {
- virtual ~Base() {}
- virtual void f() {}
- };
-
- struct Derived : public Base
- {
- virtual ~Derived() override {}
- virtual void f() override {}
- };
-
- }
-
- namespace test_double_right_angle_brackets
- {
-
- template < typename T >
- struct check {};
-
- typedef check<void> single_type;
- typedef check<check<void>> double_type;
- typedef check<check<check<void>>> triple_type;
- typedef check<check<check<check<void>>>> quadruple_type;
-
- }
-
- namespace test_decltype
- {
-
- int
- f()
- {
- int a = 1;
- decltype(a) b = 2;
- return a + b;
- }
-
- }
-
- namespace test_type_deduction
- {
-
- template < typename T1, typename T2 >
- struct is_same
- {
- static const bool value = false;
- };
-
- template < typename T >
- struct is_same<T, T>
- {
- static const bool value = true;
- };
-
- template < typename T1, typename T2 >
- auto
- add(T1 a1, T2 a2) -> decltype(a1 + a2)
- {
- return a1 + a2;
- }
-
- int
- test(const int c, volatile int v)
- {
- static_assert(is_same<int, decltype(0)>::value == true, "");
- static_assert(is_same<int, decltype(c)>::value == false, "");
- static_assert(is_same<int, decltype(v)>::value == false, "");
- auto ac = c;
- auto av = v;
- auto sumi = ac + av + 'x';
- auto sumf = ac + av + 1.0;
- static_assert(is_same<int, decltype(ac)>::value == true, "");
- static_assert(is_same<int, decltype(av)>::value == true, "");
- static_assert(is_same<int, decltype(sumi)>::value == true, "");
- static_assert(is_same<int, decltype(sumf)>::value == false, "");
- static_assert(is_same<int, decltype(add(c, v))>::value == true, "");
- return (sumf > 0.0) ? sumi : add(c, v);
- }
-
- }
-
- namespace test_noexcept
- {
-
- int f() { return 0; }
- int g() noexcept { return 0; }
-
- static_assert(noexcept(f()) == false, "");
- static_assert(noexcept(g()) == true, "");
-
- }
-
- namespace test_constexpr
- {
-
- template < typename CharT >
- unsigned long constexpr
- strlen_c_r(const CharT *const s, const unsigned long acc) noexcept
- {
- return *s ? strlen_c_r(s + 1, acc + 1) : acc;
- }
-
- template < typename CharT >
- unsigned long constexpr
- strlen_c(const CharT *const s) noexcept
- {
- return strlen_c_r(s, 0UL);
- }
-
- static_assert(strlen_c("") == 0UL, "");
- static_assert(strlen_c("1") == 1UL, "");
- static_assert(strlen_c("example") == 7UL, "");
- static_assert(strlen_c("another\0example") == 7UL, "");
-
- }
-
- namespace test_rvalue_references
- {
-
- template < int N >
- struct answer
- {
- static constexpr int value = N;
- };
-
- answer<1> f(int&) { return answer<1>(); }
- answer<2> f(const int&) { return answer<2>(); }
- answer<3> f(int&&) { return answer<3>(); }
-
- void
- test()
- {
- int i = 0;
- const int c = 0;
- static_assert(decltype(f(i))::value == 1, "");
- static_assert(decltype(f(c))::value == 2, "");
- static_assert(decltype(f(0))::value == 3, "");
- }
-
- }
-
- namespace test_uniform_initialization
- {
-
- struct test
- {
- static const int zero {};
- static const int one {1};
- };
-
- static_assert(test::zero == 0, "");
- static_assert(test::one == 1, "");
-
- }
-
- namespace test_lambdas
- {
-
- void
- test1()
- {
- auto lambda1 = [](){};
- auto lambda2 = lambda1;
- lambda1();
- lambda2();
- }
-
- int
- test2()
- {
- auto a = [](int i, int j){ return i + j; }(1, 2);
- auto b = []() -> int { return '0'; }();
- auto c = [=](){ return a + b; }();
- auto d = [&](){ return c; }();
- auto e = [a, &b](int x) mutable {
- const auto identity = [](int y){ return y; };
- for (auto i = 0; i < a; ++i)
- a += b--;
- return x + identity(a + b);
- }(0);
- return a + b + c + d + e;
- }
-
- int
- test3()
- {
- const auto nullary = [](){ return 0; };
- const auto unary = [](int x){ return x; };
- using nullary_t = decltype(nullary);
- using unary_t = decltype(unary);
- const auto higher1st = [](nullary_t f){ return f(); };
- const auto higher2nd = [unary](nullary_t f1){
- return [unary, f1](unary_t f2){ return f2(unary(f1())); };
- };
- return higher1st(nullary) + higher2nd(nullary)(unary);
- }
-
- }
-
- namespace test_variadic_templates
- {
-
- template <int...>
- struct sum;
-
- template <int N0, int... N1toN>
- struct sum<N0, N1toN...>
- {
- static constexpr auto value = N0 + sum<N1toN...>::value;
- };
-
- template <>
- struct sum<>
- {
- static constexpr auto value = 0;
- };
-
- static_assert(sum<>::value == 0, "");
- static_assert(sum<1>::value == 1, "");
- static_assert(sum<23>::value == 23, "");
- static_assert(sum<1, 2>::value == 3, "");
- static_assert(sum<5, 5, 11>::value == 21, "");
- static_assert(sum<2, 3, 5, 7, 11, 13>::value == 41, "");
-
- }
-
- // http://stackoverflow.com/questions/13728184/template-aliases-and-sfinae
- // Clang 3.1 fails with headers of libstd++ 4.8.3 when using std::function
- // because of this.
- namespace test_template_alias_sfinae
- {
-
- struct foo {};
-
- template<typename T>
- using member = typename T::member_type;
-
- template<typename T>
- void func(...) {}
-
- template<typename T>
- void func(member<T>*) {}
-
- void test();
-
- void test() { func<foo>(0); }
-
- }
-
-} // namespace cxx11
-
-#endif // __cplusplus >= 201103L
-
-
-
-_ACEOF
-if ac_fn_cxx_try_compile "$LINENO"; then :
- eval $cachevar=yes
-else
- eval $cachevar=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- CXX="$ac_save_CXX"
-fi
-eval ac_res=\$$cachevar
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
- if eval test x\$$cachevar = xyes; then
- CXX="$CXX $switch"
- if test -n "$CXXCPP" ; then
- CXXCPP="$CXXCPP $switch"
- fi
- ac_success=yes
- break
- fi
- done
- if test x$ac_success = xyes; then
- break
- fi
- done
- fi
-
- ac_ext=cpp
-ac_cpp='$CXXCPP $CPPFLAGS'
-ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
-
- if test x$ax_cxx_compile_cxx11_required = xtrue; then
- if test x$ac_success = xno; then
- as_fn_error $? "*** A compiler with support for C++11 language features is required." "$LINENO" 5
- fi
- fi
- if test x$ac_success = xno; then
- HAVE_CXX11=0
- { $as_echo "$as_me:${as_lineno-$LINENO}: No compiler with C++11 support was found" >&5
-$as_echo "$as_me: No compiler with C++11 support was found" >&6;}
- else
- HAVE_CXX11=1
-
-$as_echo "#define HAVE_CXX11 1" >>confdefs.h
-
- fi
-
-
-
-# Use of tr1/unordered_map with off_t as a key is not supported on GCC
-# 4.1.xx when compiling in 32-bit mode with a 64-bit off_t type.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether std::tr1::hash<off_t> is defined" >&5
-$as_echo_n "checking whether std::tr1::hash<off_t> is defined... " >&6; }
-if ${gold_cv_hash_off_t+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- CXXFLAGS_hold=$CXXFLAGS
-CXXFLAGS="$CXXFLAGS $LFS_CFLAGS"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <sys/types.h>
-#include <tr1/unordered_map>
-std::tr1::hash<off_t> h;
-
-_ACEOF
-if ac_fn_cxx_try_compile "$LINENO"; then :
- gold_cv_hash_off_t=yes
-else
- gold_cv_hash_off_t=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-CXXFLAGS=$CXXFLAGS_hold
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gold_cv_hash_off_t" >&5
-$as_echo "$gold_cv_hash_off_t" >&6; }
-if test "$gold_cv_hash_off_t" = "yes"; then
-
-$as_echo "#define HAVE_TR1_HASH_OFF_T 1" >>confdefs.h
-
-fi
-
-# gcc 4.3.0 doesn't recognize the printf attribute on a template
-# function. Check for that. This is gcc bug 35546. This test can
-# probably be removed after the bug has been fixed for a while.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we can use attributes with template functions" >&5
-$as_echo_n "checking whether we can use attributes with template functions... " >&6; }
-if ${gold_cv_template_attribute+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-template<typename T> extern void foo(const char*, ...)
- __attribute__ ((__format__ (__printf__, 1, 2)));
-template<typename T> void foo(const char* format, ...) {}
-void bar() { foo<int>("%s\n", "foo"); }
-
-_ACEOF
-if ac_fn_cxx_try_compile "$LINENO"; then :
- gold_cv_template_attribute=yes
-else
- gold_cv_template_attribute=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gold_cv_template_attribute" >&5
-$as_echo "$gold_cv_template_attribute" >&6; }
-if test "$gold_cv_template_attribute" = "yes"; then
-
-$as_echo "#define HAVE_TEMPLATE_ATTRIBUTES 1" >>confdefs.h
-
-fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct stat::st_mtim." >&5
-$as_echo_n "checking for struct stat::st_mtim.... " >&6; }
-if ${gold_cv_stat_st_mtim+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <sys/stat.h>
-long bar() { struct stat s; return (long)(s.st_mtim.tv_sec + s.st_mtim.tv_sec);}
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_cxx_try_compile "$LINENO"; then :
- gold_cv_stat_st_mtim=yes
-else
- gold_cv_stat_st_mtim=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gold_cv_stat_st_mtim" >&5
-$as_echo "$gold_cv_stat_st_mtim" >&6; }
-if test "$gold_cv_stat_st_mtim" = "yes"; then
-
-$as_echo "#define HAVE_STAT_ST_MTIM 1" >>confdefs.h
-
-fi
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-
-for ac_header in locale.h
-do :
- ac_fn_c_check_header_mongrel "$LINENO" "locale.h" "ac_cv_header_locale_h" "$ac_includes_default"
-if test "x$ac_cv_header_locale_h" = xyes; then :
- cat >>confdefs.h <<_ACEOF
-#define HAVE_LOCALE_H 1
-_ACEOF
-
-fi
-
-done
-
-for ac_func in setlocale
-do :
- ac_fn_c_check_func "$LINENO" "setlocale" "ac_cv_func_setlocale"
-if test "x$ac_cv_func_setlocale" = xyes; then :
- cat >>confdefs.h <<_ACEOF
-#define HAVE_SETLOCALE 1
-_ACEOF
-
-fi
-done
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LC_MESSAGES" >&5
-$as_echo_n "checking for LC_MESSAGES... " >&6; }
-if ${am_cv_val_LC_MESSAGES+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <locale.h>
-int
-main ()
-{
-return LC_MESSAGES
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- am_cv_val_LC_MESSAGES=yes
-else
- am_cv_val_LC_MESSAGES=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_val_LC_MESSAGES" >&5
-$as_echo "$am_cv_val_LC_MESSAGES" >&6; }
- if test $am_cv_val_LC_MESSAGES = yes; then
-
-$as_echo "#define HAVE_LC_MESSAGES 1" >>confdefs.h
-
- fi
-
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable maintainer-specific portions of Makefiles" >&5
-$as_echo_n "checking whether to enable maintainer-specific portions of Makefiles... " >&6; }
- # Check whether --enable-maintainer-mode was given.
-if test "${enable_maintainer_mode+set}" = set; then :
- enableval=$enable_maintainer_mode; USE_MAINTAINER_MODE=$enableval
-else
- USE_MAINTAINER_MODE=no
-fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_MAINTAINER_MODE" >&5
-$as_echo "$USE_MAINTAINER_MODE" >&6; }
- if test $USE_MAINTAINER_MODE = yes; then
- MAINTAINER_MODE_TRUE=
- MAINTAINER_MODE_FALSE='#'
-else
- MAINTAINER_MODE_TRUE='#'
- MAINTAINER_MODE_FALSE=
-fi
-
- MAINT=$MAINTAINER_MODE_TRUE
-
-
-
-ac_config_files="$ac_config_files Makefile testsuite/Makefile po/Makefile.in:po/Make-in"
-
-cat >confcache <<\_ACEOF
-# This file is a shell script that caches the results of configure
-# tests run on this system so they can be shared between configure
-# scripts and configure runs, see configure's option --config-cache.
-# It is not useful on other systems. If it contains results you don't
-# want to keep, you may remove or edit it.
-#
-# config.status only pays attention to the cache file if you give it
-# the --recheck option to rerun configure.
-#
-# `ac_cv_env_foo' variables (set or unset) will be overridden when
-# loading this file, other *unset* `ac_cv_foo' will be assigned the
-# following values.
-
-_ACEOF
-
-# The following way of writing the cache mishandles newlines in values,
-# but we know of no workaround that is simple, portable, and efficient.
-# So, we kill variables containing newlines.
-# Ultrix sh set writes to stderr and can't be redirected directly,
-# and sets the high bit in the cache file unless we assign to the vars.
-(
- for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
- eval ac_val=\$$ac_var
- case $ac_val in #(
- *${as_nl}*)
- case $ac_var in #(
- *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
-$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
- esac
- case $ac_var in #(
- _ | IFS | as_nl) ;; #(
- BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
- *) { eval $ac_var=; unset $ac_var;} ;;
- esac ;;
- esac
- done
-
- (set) 2>&1 |
- case $as_nl`(ac_space=' '; set) 2>&1` in #(
- *${as_nl}ac_space=\ *)
- # `set' does not quote correctly, so add quotes: double-quote
- # substitution turns \\\\ into \\, and sed turns \\ into \.
- sed -n \
- "s/'/'\\\\''/g;
- s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
- ;; #(
- *)
- # `set' quotes correctly as required by POSIX, so do not add quotes.
- sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
- ;;
- esac |
- sort
-) |
- sed '
- /^ac_cv_env_/b end
- t clear
- :clear
- s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
- t end
- s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
- :end' >>confcache
-if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
- if test -w "$cache_file"; then
- if test "x$cache_file" != "x/dev/null"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
-$as_echo "$as_me: updating cache $cache_file" >&6;}
- if test ! -f "$cache_file" || test -h "$cache_file"; then
- cat confcache >"$cache_file"
- else
- case $cache_file in #(
- */* | ?:*)
- mv -f confcache "$cache_file"$$ &&
- mv -f "$cache_file"$$ "$cache_file" ;; #(
- *)
- mv -f confcache "$cache_file" ;;
- esac
- fi
- fi
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
-$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
- fi
-fi
-rm -f confcache
-
-test "x$prefix" = xNONE && prefix=$ac_default_prefix
-# Let make expand exec_prefix.
-test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
-
-DEFS=-DHAVE_CONFIG_H
-
-ac_libobjs=
-ac_ltlibobjs=
-for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
- # 1. Remove the extension, and $U if already installed.
- ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
- ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
- # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
- # will be set to the directory where LIBOBJS objects are built.
- as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
- as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
-done
-LIBOBJS=$ac_libobjs
-
-LTLIBOBJS=$ac_ltlibobjs
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking that generated files are newer than configure" >&5
-$as_echo_n "checking that generated files are newer than configure... " >&6; }
- if test -n "$am_sleep_pid"; then
- # Hide warnings about reused PIDs.
- wait $am_sleep_pid 2>/dev/null
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: done" >&5
-$as_echo "done" >&6; }
- if test -n "$EXEEXT"; then
- am__EXEEXT_TRUE=
- am__EXEEXT_FALSE='#'
-else
- am__EXEEXT_TRUE='#'
- am__EXEEXT_FALSE=
-fi
-
-if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
- as_fn_error $? "conditional \"AMDEP\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
- as_fn_error $? "conditional \"am__fastdepCC\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${PLUGINS_TRUE}" && test -z "${PLUGINS_FALSE}"; then
- as_fn_error $? "conditional \"PLUGINS\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${DEFAULT_TARGET_AARCH64_TRUE}" && test -z "${DEFAULT_TARGET_AARCH64_FALSE}"; then
- as_fn_error $? "conditional \"DEFAULT_TARGET_AARCH64\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${DEFAULT_TARGET_ARM_TRUE}" && test -z "${DEFAULT_TARGET_ARM_FALSE}"; then
- as_fn_error $? "conditional \"DEFAULT_TARGET_ARM\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${DEFAULT_TARGET_I386_TRUE}" && test -z "${DEFAULT_TARGET_I386_FALSE}"; then
- as_fn_error $? "conditional \"DEFAULT_TARGET_I386\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${DEFAULT_TARGET_POWERPC_TRUE}" && test -z "${DEFAULT_TARGET_POWERPC_FALSE}"; then
- as_fn_error $? "conditional \"DEFAULT_TARGET_POWERPC\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${DEFAULT_TARGET_SPARC_TRUE}" && test -z "${DEFAULT_TARGET_SPARC_FALSE}"; then
- as_fn_error $? "conditional \"DEFAULT_TARGET_SPARC\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${DEFAULT_TARGET_S390_TRUE}" && test -z "${DEFAULT_TARGET_S390_FALSE}"; then
- as_fn_error $? "conditional \"DEFAULT_TARGET_S390\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${DEFAULT_TARGET_X86_64_TRUE}" && test -z "${DEFAULT_TARGET_X86_64_FALSE}"; then
- as_fn_error $? "conditional \"DEFAULT_TARGET_X86_64\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${DEFAULT_TARGET_X32_TRUE}" && test -z "${DEFAULT_TARGET_X32_FALSE}"; then
- as_fn_error $? "conditional \"DEFAULT_TARGET_X32\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${DEFAULT_TARGET_X86_64_OR_X32_TRUE}" && test -z "${DEFAULT_TARGET_X86_64_OR_X32_FALSE}"; then
- as_fn_error $? "conditional \"DEFAULT_TARGET_X86_64_OR_X32\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${DEFAULT_TARGET_TILEGX_TRUE}" && test -z "${DEFAULT_TARGET_TILEGX_FALSE}"; then
- as_fn_error $? "conditional \"DEFAULT_TARGET_TILEGX\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${DEFAULT_TARGET_MIPS_TRUE}" && test -z "${DEFAULT_TARGET_MIPS_FALSE}"; then
- as_fn_error $? "conditional \"DEFAULT_TARGET_MIPS\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
- as_fn_error $? "conditional \"am__fastdepCC\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${am__fastdepCXX_TRUE}" && test -z "${am__fastdepCXX_FALSE}"; then
- as_fn_error $? "conditional \"am__fastdepCXX\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-
-if test -z "${NATIVE_LINKER_TRUE}" && test -z "${NATIVE_LINKER_FALSE}"; then
- as_fn_error $? "conditional \"NATIVE_LINKER\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${GCC_TRUE}" && test -z "${GCC_FALSE}"; then
- as_fn_error $? "conditional \"GCC\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${NATIVE_OR_CROSS_LINKER_TRUE}" && test -z "${NATIVE_OR_CROSS_LINKER_FALSE}"; then
- as_fn_error $? "conditional \"NATIVE_OR_CROSS_LINKER\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${HAVE_STATIC_TRUE}" && test -z "${HAVE_STATIC_FALSE}"; then
- as_fn_error $? "conditional \"HAVE_STATIC\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${FN_PTRS_IN_SO_WITHOUT_PIC_TRUE}" && test -z "${FN_PTRS_IN_SO_WITHOUT_PIC_FALSE}"; then
- as_fn_error $? "conditional \"FN_PTRS_IN_SO_WITHOUT_PIC\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${MCMODEL_MEDIUM_TRUE}" && test -z "${MCMODEL_MEDIUM_FALSE}"; then
- as_fn_error $? "conditional \"MCMODEL_MEDIUM\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${GCC9_TRUE}" && test -z "${GCC9_FALSE}"; then
- as_fn_error $? "conditional \"GCC9\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${CFLAGS_CF_PROTECTION_TRUE}" && test -z "${CFLAGS_CF_PROTECTION_FALSE}"; then
- as_fn_error $? "conditional \"CFLAGS_CF_PROTECTION\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${TLS_TRUE}" && test -z "${TLS_FALSE}"; then
- as_fn_error $? "conditional \"TLS\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${STATIC_TLS_TRUE}" && test -z "${STATIC_TLS_FALSE}"; then
- as_fn_error $? "conditional \"STATIC_TLS\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${OMP_SUPPORT_TRUE}" && test -z "${OMP_SUPPORT_FALSE}"; then
- as_fn_error $? "conditional \"OMP_SUPPORT\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${TLS_GNU2_DIALECT_TRUE}" && test -z "${TLS_GNU2_DIALECT_FALSE}"; then
- as_fn_error $? "conditional \"TLS_GNU2_DIALECT\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${TLS_DESCRIPTORS_TRUE}" && test -z "${TLS_DESCRIPTORS_FALSE}"; then
- as_fn_error $? "conditional \"TLS_DESCRIPTORS\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${IFUNC_TRUE}" && test -z "${IFUNC_FALSE}"; then
- as_fn_error $? "conditional \"IFUNC\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${IFUNC_STATIC_TRUE}" && test -z "${IFUNC_STATIC_FALSE}"; then
- as_fn_error $? "conditional \"IFUNC_STATIC\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${HAVE_ZSTD_TRUE}" && test -z "${HAVE_ZSTD_FALSE}"; then
- as_fn_error $? "conditional \"HAVE_ZSTD\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${THREADS_TRUE}" && test -z "${THREADS_FALSE}"; then
- as_fn_error $? "conditional \"THREADS\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${HAVE_PUBNAMES_TRUE}" && test -z "${HAVE_PUBNAMES_FALSE}"; then
- as_fn_error $? "conditional \"HAVE_PUBNAMES\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${HAVE_NO_USE_LINKER_PLUGIN_TRUE}" && test -z "${HAVE_NO_USE_LINKER_PLUGIN_FALSE}"; then
- as_fn_error $? "conditional \"HAVE_NO_USE_LINKER_PLUGIN\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${MAINTAINER_MODE_TRUE}" && test -z "${MAINTAINER_MODE_FALSE}"; then
- as_fn_error $? "conditional \"MAINTAINER_MODE\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-
-: "${CONFIG_STATUS=./config.status}"
-ac_write_fail=0
-ac_clean_files_save=$ac_clean_files
-ac_clean_files="$ac_clean_files $CONFIG_STATUS"
-{ $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
-$as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
-as_write_fail=0
-cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
-#! $SHELL
-# Generated by $as_me.
-# Run this file to recreate the current configuration.
-# Compiler output produced by configure, useful for debugging
-# configure, is in config.log if it exists.
-
-debug=false
-ac_cs_recheck=false
-ac_cs_silent=false
-
-SHELL=\${CONFIG_SHELL-$SHELL}
-export SHELL
-_ASEOF
-cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
-## -------------------- ##
-## M4sh Initialization. ##
-## -------------------- ##
-
-# Be more Bourne compatible
-DUALCASE=1; export DUALCASE # for MKS sh
-if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
- emulate sh
- NULLCMD=:
- # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
- # is contrary to our usage. Disable this feature.
- alias -g '${1+"$@"}'='"$@"'
- setopt NO_GLOB_SUBST
-else
- case `(set -o) 2>/dev/null` in #(
- *posix*) :
- set -o posix ;; #(
- *) :
- ;;
-esac
-fi
-
-
-as_nl='
-'
-export as_nl
-# Printing a long string crashes Solaris 7 /usr/bin/printf.
-as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
-as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
-as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
-# Prefer a ksh shell builtin over an external printf program on Solaris,
-# but without wasting forks for bash or zsh.
-if test -z "$BASH_VERSION$ZSH_VERSION" \
- && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
- as_echo='print -r --'
- as_echo_n='print -rn --'
-elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
- as_echo='printf %s\n'
- as_echo_n='printf %s'
-else
- if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
- as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
- as_echo_n='/usr/ucb/echo -n'
- else
- as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
- as_echo_n_body='eval
- arg=$1;
- case $arg in #(
- *"$as_nl"*)
- expr "X$arg" : "X\\(.*\\)$as_nl";
- arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
- esac;
- expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
- '
- export as_echo_n_body
- as_echo_n='sh -c $as_echo_n_body as_echo'
- fi
- export as_echo_body
- as_echo='sh -c $as_echo_body as_echo'
-fi
-
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- PATH_SEPARATOR=:
- (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
- (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
- PATH_SEPARATOR=';'
- }
-fi
-
-
-# IFS
-# We need space, tab and new line, in precisely that order. Quoting is
-# there to prevent editors from complaining about space-tab.
-# (If _AS_PATH_WALK were called with IFS unset, it would disable word
-# splitting by setting IFS to empty value.)
-IFS=" "" $as_nl"
-
-# Find who we are. Look in the path if we contain no directory separator.
-as_myself=
-case $0 in #((
- *[\\/]* ) as_myself=$0 ;;
- *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
- done
-IFS=$as_save_IFS
-
- ;;
-esac
-# We did not find ourselves, most probably we were run as `sh COMMAND'
-# in which case we are not to be found in the path.
-if test "x$as_myself" = x; then
- as_myself=$0
-fi
-if test ! -f "$as_myself"; then
- $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
- exit 1
-fi
-
-# Unset variables that we do not need and which cause bugs (e.g. in
-# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
-# suppresses any "Segmentation fault" message there. '((' could
-# trigger a bug in pdksh 5.2.14.
-for as_var in BASH_ENV ENV MAIL MAILPATH
-do eval test x\${$as_var+set} = xset \
- && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
-done
-PS1='$ '
-PS2='> '
-PS4='+ '
-
-# NLS nuisances.
-LC_ALL=C
-export LC_ALL
-LANGUAGE=C
-export LANGUAGE
-
-# CDPATH.
-(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
-
-
-# as_fn_error STATUS ERROR [LINENO LOG_FD]
-# ----------------------------------------
-# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
-# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
-# script with STATUS, using 1 if that was 0.
-as_fn_error ()
-{
- as_status=$1; test $as_status -eq 0 && as_status=1
- if test "$4"; then
- as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
- fi
- $as_echo "$as_me: error: $2" >&2
- as_fn_exit $as_status
-} # as_fn_error
-
-
-# as_fn_set_status STATUS
-# -----------------------
-# Set $? to STATUS, without forking.
-as_fn_set_status ()
-{
- return $1
-} # as_fn_set_status
-
-# as_fn_exit STATUS
-# -----------------
-# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
-as_fn_exit ()
-{
- set +e
- as_fn_set_status $1
- exit $1
-} # as_fn_exit
-
-# as_fn_unset VAR
-# ---------------
-# Portably unset VAR.
-as_fn_unset ()
-{
- { eval $1=; unset $1;}
-}
-as_unset=as_fn_unset
-# as_fn_append VAR VALUE
-# ----------------------
-# Append the text in VALUE to the end of the definition contained in VAR. Take
-# advantage of any shell optimizations that allow amortized linear growth over
-# repeated appends, instead of the typical quadratic growth present in naive
-# implementations.
-if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
- eval 'as_fn_append ()
- {
- eval $1+=\$2
- }'
-else
- as_fn_append ()
- {
- eval $1=\$$1\$2
- }
-fi # as_fn_append
-
-# as_fn_arith ARG...
-# ------------------
-# Perform arithmetic evaluation on the ARGs, and store the result in the
-# global $as_val. Take advantage of shells that can avoid forks. The arguments
-# must be portable across $(()) and expr.
-if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
- eval 'as_fn_arith ()
- {
- as_val=$(( $* ))
- }'
-else
- as_fn_arith ()
- {
- as_val=`expr "$@" || test $? -eq 1`
- }
-fi # as_fn_arith
-
-
-if expr a : '\(a\)' >/dev/null 2>&1 &&
- test "X`expr 00001 : '.*\(...\)'`" = X001; then
- as_expr=expr
-else
- as_expr=false
-fi
-
-if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
- as_basename=basename
-else
- as_basename=false
-fi
-
-if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
- as_dirname=dirname
-else
- as_dirname=false
-fi
-
-as_me=`$as_basename -- "$0" ||
-$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
- X"$0" : 'X\(//\)$' \| \
- X"$0" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X/"$0" |
- sed '/^.*\/\([^/][^/]*\)\/*$/{
- s//\1/
- q
- }
- /^X\/\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\/\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
-
-# Avoid depending upon Character Ranges.
-as_cr_letters='abcdefghijklmnopqrstuvwxyz'
-as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
-as_cr_Letters=$as_cr_letters$as_cr_LETTERS
-as_cr_digits='0123456789'
-as_cr_alnum=$as_cr_Letters$as_cr_digits
-
-ECHO_C= ECHO_N= ECHO_T=
-case `echo -n x` in #(((((
--n*)
- case `echo 'xy\c'` in
- *c*) ECHO_T=' ';; # ECHO_T is single tab character.
- xy) ECHO_C='\c';;
- *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
- ECHO_T=' ';;
- esac;;
-*)
- ECHO_N='-n';;
-esac
-
-rm -f conf$$ conf$$.exe conf$$.file
-if test -d conf$$.dir; then
- rm -f conf$$.dir/conf$$.file
-else
- rm -f conf$$.dir
- mkdir conf$$.dir 2>/dev/null
-fi
-if (echo >conf$$.file) 2>/dev/null; then
- if ln -s conf$$.file conf$$ 2>/dev/null; then
- as_ln_s='ln -s'
- # ... but there are two gotchas:
- # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
- # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
- # In both cases, we have to default to `cp -pR'.
- ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
- as_ln_s='cp -pR'
- elif ln conf$$.file conf$$ 2>/dev/null; then
- as_ln_s=ln
- else
- as_ln_s='cp -pR'
- fi
-else
- as_ln_s='cp -pR'
-fi
-rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
-rmdir conf$$.dir 2>/dev/null
-
-
-# as_fn_mkdir_p
-# -------------
-# Create "$as_dir" as a directory, including parents if necessary.
-as_fn_mkdir_p ()
-{
-
- case $as_dir in #(
- -*) as_dir=./$as_dir;;
- esac
- test -d "$as_dir" || eval $as_mkdir_p || {
- as_dirs=
- while :; do
- case $as_dir in #(
- *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
- *) as_qdir=$as_dir;;
- esac
- as_dirs="'$as_qdir' $as_dirs"
- as_dir=`$as_dirname -- "$as_dir" ||
-$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$as_dir" : 'X\(//\)[^/]' \| \
- X"$as_dir" : 'X\(//\)$' \| \
- X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$as_dir" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
- test -d "$as_dir" && break
- done
- test -z "$as_dirs" || eval "mkdir $as_dirs"
- } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
-
-
-} # as_fn_mkdir_p
-if mkdir -p . 2>/dev/null; then
- as_mkdir_p='mkdir -p "$as_dir"'
-else
- test -d ./-p && rmdir ./-p
- as_mkdir_p=false
-fi
-
-
-# as_fn_executable_p FILE
-# -----------------------
-# Test if FILE is an executable regular file.
-as_fn_executable_p ()
-{
- test -f "$1" && test -x "$1"
-} # as_fn_executable_p
-as_test_x='test -x'
-as_executable_p=as_fn_executable_p
-
-# Sed expression to map a string onto a valid CPP name.
-as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
-
-# Sed expression to map a string onto a valid variable name.
-as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
-
-
-exec 6>&1
-## ----------------------------------- ##
-## Main body of $CONFIG_STATUS script. ##
-## ----------------------------------- ##
-_ASEOF
-test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
-
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-# Save the log message, to keep $0 and so on meaningful, and to
-# report actual input values of CONFIG_FILES etc. instead of their
-# values after options handling.
-ac_log="
-This file was extended by gold $as_me 0.1, which was
-generated by GNU Autoconf 2.69. Invocation command line was
-
- CONFIG_FILES = $CONFIG_FILES
- CONFIG_HEADERS = $CONFIG_HEADERS
- CONFIG_LINKS = $CONFIG_LINKS
- CONFIG_COMMANDS = $CONFIG_COMMANDS
- $ $0 $@
-
-on `(hostname || uname -n) 2>/dev/null | sed 1q`
-"
-
-_ACEOF
-
-case $ac_config_files in *"
-"*) set x $ac_config_files; shift; ac_config_files=$*;;
-esac
-
-case $ac_config_headers in *"
-"*) set x $ac_config_headers; shift; ac_config_headers=$*;;
-esac
-
-
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-# Files that config.status was made for.
-config_files="$ac_config_files"
-config_headers="$ac_config_headers"
-config_commands="$ac_config_commands"
-
-_ACEOF
-
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-ac_cs_usage="\
-\`$as_me' instantiates files and other configuration actions
-from templates according to the current configuration. Unless the files
-and actions are specified as TAGs, all are instantiated by default.
-
-Usage: $0 [OPTION]... [TAG]...
-
- -h, --help print this help, then exit
- -V, --version print version number and configuration settings, then exit
- --config print configuration, then exit
- -q, --quiet, --silent
- do not print progress messages
- -d, --debug don't remove temporary files
- --recheck update $as_me by reconfiguring in the same conditions
- --file=FILE[:TEMPLATE]
- instantiate the configuration file FILE
- --header=FILE[:TEMPLATE]
- instantiate the configuration header FILE
-
-Configuration files:
-$config_files
-
-Configuration headers:
-$config_headers
-
-Configuration commands:
-$config_commands
-
-Report bugs to the package provider."
-
-_ACEOF
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
-ac_cs_version="\\
-gold config.status 0.1
-configured by $0, generated by GNU Autoconf 2.69,
- with options \\"\$ac_cs_config\\"
-
-Copyright (C) 2012 Free Software Foundation, Inc.
-This config.status script is free software; the Free Software Foundation
-gives unlimited permission to copy, distribute and modify it."
-
-ac_pwd='$ac_pwd'
-srcdir='$srcdir'
-INSTALL='$INSTALL'
-MKDIR_P='$MKDIR_P'
-AWK='$AWK'
-test -n "\$AWK" || AWK=awk
-_ACEOF
-
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-# The default lists apply if the user does not specify any file.
-ac_need_defaults=:
-while test $# != 0
-do
- case $1 in
- --*=?*)
- ac_option=`expr "X$1" : 'X\([^=]*\)='`
- ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
- ac_shift=:
- ;;
- --*=)
- ac_option=`expr "X$1" : 'X\([^=]*\)='`
- ac_optarg=
- ac_shift=:
- ;;
- *)
- ac_option=$1
- ac_optarg=$2
- ac_shift=shift
- ;;
- esac
-
- case $ac_option in
- # Handling of the options.
- -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
- ac_cs_recheck=: ;;
- --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
- $as_echo "$ac_cs_version"; exit ;;
- --config | --confi | --conf | --con | --co | --c )
- $as_echo "$ac_cs_config"; exit ;;
- --debug | --debu | --deb | --de | --d | -d )
- debug=: ;;
- --file | --fil | --fi | --f )
- $ac_shift
- case $ac_optarg in
- *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
- '') as_fn_error $? "missing file argument" ;;
- esac
- as_fn_append CONFIG_FILES " '$ac_optarg'"
- ac_need_defaults=false;;
- --header | --heade | --head | --hea )
- $ac_shift
- case $ac_optarg in
- *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
- esac
- as_fn_append CONFIG_HEADERS " '$ac_optarg'"
- ac_need_defaults=false;;
- --he | --h)
- # Conflict between --help and --header
- as_fn_error $? "ambiguous option: \`$1'
-Try \`$0 --help' for more information.";;
- --help | --hel | -h )
- $as_echo "$ac_cs_usage"; exit ;;
- -q | -quiet | --quiet | --quie | --qui | --qu | --q \
- | -silent | --silent | --silen | --sile | --sil | --si | --s)
- ac_cs_silent=: ;;
-
- # This is an error.
- -*) as_fn_error $? "unrecognized option: \`$1'
-Try \`$0 --help' for more information." ;;
-
- *) as_fn_append ac_config_targets " $1"
- ac_need_defaults=false ;;
-
- esac
- shift
-done
-
-ac_configure_extra_args=
-
-if $ac_cs_silent; then
- exec 6>/dev/null
- ac_configure_extra_args="$ac_configure_extra_args --silent"
-fi
-
-_ACEOF
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-if \$ac_cs_recheck; then
- set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
- shift
- \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
- CONFIG_SHELL='$SHELL'
- export CONFIG_SHELL
- exec "\$@"
-fi
-
-_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-exec 5>>config.log
-{
- echo
- sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
-## Running $as_me. ##
-_ASBOX
- $as_echo "$ac_log"
-} >&5
-
-_ACEOF
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-#
-# INIT-COMMANDS
-#
-AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"
-# Capture the value of obsolete ALL_LINGUAS because we need it to compute
- # POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES, CATALOGS. But hide it
- # from automake.
- eval 'OBSOLETE_ALL_LINGUAS''="$ALL_LINGUAS"'
- # Capture the value of LINGUAS because we need it to compute CATALOGS.
- LINGUAS="${LINGUAS-%UNSET%}"
-
-# Capture the value of obsolete ALL_LINGUAS because we need it to compute
- # POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES, CATALOGS. But hide it
- # from automake.
- eval 'OBSOLETE_ALL_LINGUAS''="$ALL_LINGUAS"'
- # Capture the value of LINGUAS because we need it to compute CATALOGS.
- LINGUAS="${LINGUAS-%UNSET%}"
-
-
-_ACEOF
-
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-
-# Handling of arguments.
-for ac_config_target in $ac_config_targets
-do
- case $ac_config_target in
- "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h:config.in" ;;
- "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
- "default-1") CONFIG_COMMANDS="$CONFIG_COMMANDS default-1" ;;
- "default-2") CONFIG_COMMANDS="$CONFIG_COMMANDS default-2" ;;
- "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
- "testsuite/Makefile") CONFIG_FILES="$CONFIG_FILES testsuite/Makefile" ;;
- "po/Makefile.in") CONFIG_FILES="$CONFIG_FILES po/Makefile.in:po/Make-in" ;;
-
- *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
- esac
-done
-
-
-# If the user did not use the arguments to specify the items to instantiate,
-# then the envvar interface is used. Set only those that are not.
-# We use the long form for the default assignment because of an extremely
-# bizarre bug on SunOS 4.1.3.
-if $ac_need_defaults; then
- test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
- test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
- test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
-fi
-
-# Have a temporary directory for convenience. Make it in the build tree
-# simply because there is no reason against having it here, and in addition,
-# creating and moving files from /tmp can sometimes cause problems.
-# Hook for its removal unless debugging.
-# Note that there is a small window in which the directory will not be cleaned:
-# after its creation but before its name has been assigned to `$tmp'.
-$debug ||
-{
- tmp= ac_tmp=
- trap 'exit_status=$?
- : "${ac_tmp:=$tmp}"
- { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
-' 0
- trap 'as_fn_exit 1' 1 2 13 15
-}
-# Create a (secure) tmp directory for tmp files.
-
-{
- tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
- test -d "$tmp"
-} ||
-{
- tmp=./conf$$-$RANDOM
- (umask 077 && mkdir "$tmp")
-} || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
-ac_tmp=$tmp
-
-# Set up the scripts for CONFIG_FILES section.
-# No need to generate them if there are no CONFIG_FILES.
-# This happens for instance with `./config.status config.h'.
-if test -n "$CONFIG_FILES"; then
-
-
-ac_cr=`echo X | tr X '\015'`
-# On cygwin, bash can eat \r inside `` if the user requested igncr.
-# But we know of no other shell where ac_cr would be empty at this
-# point, so we can use a bashism as a fallback.
-if test "x$ac_cr" = x; then
- eval ac_cr=\$\'\\r\'
-fi
-ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
-if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
- ac_cs_awk_cr='\\r'
-else
- ac_cs_awk_cr=$ac_cr
-fi
-
-echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
-_ACEOF
-
-
-{
- echo "cat >conf$$subs.awk <<_ACEOF" &&
- echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
- echo "_ACEOF"
-} >conf$$subs.sh ||
- as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
-ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
-ac_delim='%!_!# '
-for ac_last_try in false false false false false :; do
- . ./conf$$subs.sh ||
- as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
-
- ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
- if test $ac_delim_n = $ac_delim_num; then
- break
- elif $ac_last_try; then
- as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
- else
- ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
- fi
-done
-rm -f conf$$subs.sh
-
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
-_ACEOF
-sed -n '
-h
-s/^/S["/; s/!.*/"]=/
-p
-g
-s/^[^!]*!//
-:repl
-t repl
-s/'"$ac_delim"'$//
-t delim
-:nl
-h
-s/\(.\{148\}\)..*/\1/
-t more1
-s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
-p
-n
-b repl
-:more1
-s/["\\]/\\&/g; s/^/"/; s/$/"\\/
-p
-g
-s/.\{148\}//
-t nl
-:delim
-h
-s/\(.\{148\}\)..*/\1/
-t more2
-s/["\\]/\\&/g; s/^/"/; s/$/"/
-p
-b
-:more2
-s/["\\]/\\&/g; s/^/"/; s/$/"\\/
-p
-g
-s/.\{148\}//
-t delim
-' <conf$$subs.awk | sed '
-/^[^""]/{
- N
- s/\n//
-}
-' >>$CONFIG_STATUS || ac_write_fail=1
-rm -f conf$$subs.awk
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-_ACAWK
-cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
- for (key in S) S_is_set[key] = 1
- FS = ""
-
-}
-{
- line = $ 0
- nfields = split(line, field, "@")
- substed = 0
- len = length(field[1])
- for (i = 2; i < nfields; i++) {
- key = field[i]
- keylen = length(key)
- if (S_is_set[key]) {
- value = S[key]
- line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
- len += length(value) + length(field[++i])
- substed = 1
- } else
- len += 1 + keylen
- }
-
- print line
-}
-
-_ACAWK
-_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
- sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
-else
- cat
-fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
- || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
-_ACEOF
-
-# VPATH may cause trouble with some makes, so we remove sole $(srcdir),
-# ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
-# trailing colons and then remove the whole line if VPATH becomes empty
-# (actually we leave an empty line to preserve line numbers).
-if test "x$srcdir" = x.; then
- ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{
-h
-s///
-s/^/:/
-s/[ ]*$/:/
-s/:\$(srcdir):/:/g
-s/:\${srcdir}:/:/g
-s/:@srcdir@:/:/g
-s/^:*//
-s/:*$//
-x
-s/\(=[ ]*\).*/\1/
-G
-s/\n//
-s/^[^=]*=[ ]*$//
-}'
-fi
-
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-fi # test -n "$CONFIG_FILES"
-
-# Set up the scripts for CONFIG_HEADERS section.
-# No need to generate them if there are no CONFIG_HEADERS.
-# This happens for instance with `./config.status Makefile'.
-if test -n "$CONFIG_HEADERS"; then
-cat >"$ac_tmp/defines.awk" <<\_ACAWK ||
-BEGIN {
-_ACEOF
-
-# Transform confdefs.h into an awk script `defines.awk', embedded as
-# here-document in config.status, that substitutes the proper values into
-# config.h.in to produce config.h.
-
-# Create a delimiter string that does not exist in confdefs.h, to ease
-# handling of long lines.
-ac_delim='%!_!# '
-for ac_last_try in false false :; do
- ac_tt=`sed -n "/$ac_delim/p" confdefs.h`
- if test -z "$ac_tt"; then
- break
- elif $ac_last_try; then
- as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
- else
- ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
- fi
-done
-
-# For the awk script, D is an array of macro values keyed by name,
-# likewise P contains macro parameters if any. Preserve backslash
-# newline sequences.
-
-ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
-sed -n '
-s/.\{148\}/&'"$ac_delim"'/g
-t rset
-:rset
-s/^[ ]*#[ ]*define[ ][ ]*/ /
-t def
-d
-:def
-s/\\$//
-t bsnl
-s/["\\]/\\&/g
-s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
-D["\1"]=" \3"/p
-s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
-d
-:bsnl
-s/["\\]/\\&/g
-s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
-D["\1"]=" \3\\\\\\n"\\/p
-t cont
-s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
-t cont
-d
-:cont
-n
-s/.\{148\}/&'"$ac_delim"'/g
-t clear
-:clear
-s/\\$//
-t bsnlc
-s/["\\]/\\&/g; s/^/"/; s/$/"/p
-d
-:bsnlc
-s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
-b cont
-' <confdefs.h | sed '
-s/'"$ac_delim"'/"\\\
-"/g' >>$CONFIG_STATUS || ac_write_fail=1
-
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
- for (key in D) D_is_set[key] = 1
- FS = ""
-}
-/^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
- line = \$ 0
- split(line, arg, " ")
- if (arg[1] == "#") {
- defundef = arg[2]
- mac1 = arg[3]
- } else {
- defundef = substr(arg[1], 2)
- mac1 = arg[2]
- }
- split(mac1, mac2, "(") #)
- macro = mac2[1]
- prefix = substr(line, 1, index(line, defundef) - 1)
- if (D_is_set[macro]) {
- # Preserve the white space surrounding the "#".
- print prefix "define", macro P[macro] D[macro]
- next
- } else {
- # Replace #undef with comments. This is necessary, for example,
- # in the case of _POSIX_SOURCE, which is predefined and required
- # on some systems where configure will not decide to define it.
- if (defundef == "undef") {
- print "/*", prefix defundef, macro, "*/"
- next
- }
- }
-}
-{ print }
-_ACAWK
-_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
- as_fn_error $? "could not setup config headers machinery" "$LINENO" 5
-fi # test -n "$CONFIG_HEADERS"
-
-
-eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS"
-shift
-for ac_tag
-do
- case $ac_tag in
- :[FHLC]) ac_mode=$ac_tag; continue;;
- esac
- case $ac_mode$ac_tag in
- :[FHL]*:*);;
- :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
- :[FH]-) ac_tag=-:-;;
- :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
- esac
- ac_save_IFS=$IFS
- IFS=:
- set x $ac_tag
- IFS=$ac_save_IFS
- shift
- ac_file=$1
- shift
-
- case $ac_mode in
- :L) ac_source=$1;;
- :[FH])
- ac_file_inputs=
- for ac_f
- do
- case $ac_f in
- -) ac_f="$ac_tmp/stdin";;
- *) # Look for the file first in the build tree, then in the source tree
- # (if the path is not absolute). The absolute path cannot be DOS-style,
- # because $ac_f cannot contain `:'.
- test -f "$ac_f" ||
- case $ac_f in
- [\\/$]*) false;;
- *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
- esac ||
- as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
- esac
- case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
- as_fn_append ac_file_inputs " '$ac_f'"
- done
-
- # Let's still pretend it is `configure' which instantiates (i.e., don't
- # use $as_me), people would be surprised to read:
- # /* config.h. Generated by config.status. */
- configure_input='Generated from '`
- $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
- `' by configure.'
- if test x"$ac_file" != x-; then
- configure_input="$ac_file. $configure_input"
- { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
-$as_echo "$as_me: creating $ac_file" >&6;}
- fi
- # Neutralize special characters interpreted by sed in replacement strings.
- case $configure_input in #(
- *\&* | *\|* | *\\* )
- ac_sed_conf_input=`$as_echo "$configure_input" |
- sed 's/[\\\\&|]/\\\\&/g'`;; #(
- *) ac_sed_conf_input=$configure_input;;
- esac
-
- case $ac_tag in
- *:-:* | *:-) cat >"$ac_tmp/stdin" \
- || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
- esac
- ;;
- esac
-
- ac_dir=`$as_dirname -- "$ac_file" ||
-$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$ac_file" : 'X\(//\)[^/]' \| \
- X"$ac_file" : 'X\(//\)$' \| \
- X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$ac_file" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
- as_dir="$ac_dir"; as_fn_mkdir_p
- ac_builddir=.
-
-case "$ac_dir" in
-.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
-*)
- ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
- # A ".." for each directory in $ac_dir_suffix.
- ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
- case $ac_top_builddir_sub in
- "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
- *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
- esac ;;
-esac
-ac_abs_top_builddir=$ac_pwd
-ac_abs_builddir=$ac_pwd$ac_dir_suffix
-# for backward compatibility:
-ac_top_builddir=$ac_top_build_prefix
-
-case $srcdir in
- .) # We are building in place.
- ac_srcdir=.
- ac_top_srcdir=$ac_top_builddir_sub
- ac_abs_top_srcdir=$ac_pwd ;;
- [\\/]* | ?:[\\/]* ) # Absolute name.
- ac_srcdir=$srcdir$ac_dir_suffix;
- ac_top_srcdir=$srcdir
- ac_abs_top_srcdir=$srcdir ;;
- *) # Relative name.
- ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
- ac_top_srcdir=$ac_top_build_prefix$srcdir
- ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
-esac
-ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
-
-
- case $ac_mode in
- :F)
- #
- # CONFIG_FILE
- #
-
- case $INSTALL in
- [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
- *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
- esac
- ac_MKDIR_P=$MKDIR_P
- case $MKDIR_P in
- [\\/$]* | ?:[\\/]* ) ;;
- */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
- esac
-_ACEOF
-
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-# If the template does not know about datarootdir, expand it.
-# FIXME: This hack should be removed a few years after 2.60.
-ac_datarootdir_hack=; ac_datarootdir_seen=
-ac_sed_dataroot='
-/datarootdir/ {
- p
- q
-}
-/@datadir@/p
-/@docdir@/p
-/@infodir@/p
-/@localedir@/p
-/@mandir@/p'
-case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
-*datarootdir*) ac_datarootdir_seen=yes;;
-*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
-$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
-_ACEOF
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
- ac_datarootdir_hack='
- s&@datadir@&$datadir&g
- s&@docdir@&$docdir&g
- s&@infodir@&$infodir&g
- s&@localedir@&$localedir&g
- s&@mandir@&$mandir&g
- s&\\\${datarootdir}&$datarootdir&g' ;;
-esac
-_ACEOF
-
-# Neutralize VPATH when `$srcdir' = `.'.
-# Shell code in configure.ac might set extrasub.
-# FIXME: do we really want to maintain this feature?
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-ac_sed_extra="$ac_vpsub
-$extrasub
-_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-:t
-/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
-s|@configure_input@|$ac_sed_conf_input|;t t
-s&@top_builddir@&$ac_top_builddir_sub&;t t
-s&@top_build_prefix@&$ac_top_build_prefix&;t t
-s&@srcdir@&$ac_srcdir&;t t
-s&@abs_srcdir@&$ac_abs_srcdir&;t t
-s&@top_srcdir@&$ac_top_srcdir&;t t
-s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
-s&@builddir@&$ac_builddir&;t t
-s&@abs_builddir@&$ac_abs_builddir&;t t
-s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
-s&@INSTALL@&$ac_INSTALL&;t t
-s&@MKDIR_P@&$ac_MKDIR_P&;t t
-$ac_datarootdir_hack
-"
-eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \
- >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
-
-test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
- { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
- { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \
- "$ac_tmp/out"`; test -z "$ac_out"; } &&
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
-which seems to be undefined. Please make sure it is defined" >&5
-$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
-which seems to be undefined. Please make sure it is defined" >&2;}
-
- rm -f "$ac_tmp/stdin"
- case $ac_file in
- -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
- *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
- esac \
- || as_fn_error $? "could not create $ac_file" "$LINENO" 5
- ;;
- :H)
- #
- # CONFIG_HEADER
- #
- if test x"$ac_file" != x-; then
- {
- $as_echo "/* $configure_input */" \
- && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs"
- } >"$ac_tmp/config.h" \
- || as_fn_error $? "could not create $ac_file" "$LINENO" 5
- if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
-$as_echo "$as_me: $ac_file is unchanged" >&6;}
- else
- rm -f "$ac_file"
- mv "$ac_tmp/config.h" "$ac_file" \
- || as_fn_error $? "could not create $ac_file" "$LINENO" 5
- fi
- else
- $as_echo "/* $configure_input */" \
- && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \
- || as_fn_error $? "could not create -" "$LINENO" 5
- fi
-# Compute "$ac_file"'s index in $config_headers.
-_am_arg="$ac_file"
-_am_stamp_count=1
-for _am_header in $config_headers :; do
- case $_am_header in
- $_am_arg | $_am_arg:* )
- break ;;
- * )
- _am_stamp_count=`expr $_am_stamp_count + 1` ;;
- esac
-done
-echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" ||
-$as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$_am_arg" : 'X\(//\)[^/]' \| \
- X"$_am_arg" : 'X\(//\)$' \| \
- X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$_am_arg" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`/stamp-h$_am_stamp_count
- ;;
-
- :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
-$as_echo "$as_me: executing $ac_file commands" >&6;}
- ;;
- esac
-
-
- case $ac_file$ac_mode in
- "depfiles":C) test x"$AMDEP_TRUE" != x"" || {
- # Older Autoconf quotes --file arguments for eval, but not when files
- # are listed without --file. Let's play safe and only enable the eval
- # if we detect the quoting.
- case $CONFIG_FILES in
- *\'*) eval set x "$CONFIG_FILES" ;;
- *) set x $CONFIG_FILES ;;
- esac
- shift
- for mf
- do
- # Strip MF so we end up with the name of the file.
- mf=`echo "$mf" | sed -e 's/:.*$//'`
- # Check whether this is an Automake generated Makefile or not.
- # We used to match only the files named 'Makefile.in', but
- # some people rename them; so instead we look at the file content.
- # Grep'ing the first line is not enough: some people post-process
- # each Makefile.in and add a new line on top of each file to say so.
- # Grep'ing the whole file is not good either: AIX grep has a line
- # limit of 2048, but all sed's we know have understand at least 4000.
- if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
- dirpart=`$as_dirname -- "$mf" ||
-$as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$mf" : 'X\(//\)[^/]' \| \
- X"$mf" : 'X\(//\)$' \| \
- X"$mf" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$mf" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
- else
- continue
- fi
- # Extract the definition of DEPDIR, am__include, and am__quote
- # from the Makefile without running 'make'.
- DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
- test -z "$DEPDIR" && continue
- am__include=`sed -n 's/^am__include = //p' < "$mf"`
- test -z "$am__include" && continue
- am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
- # Find all dependency output files, they are included files with
- # $(DEPDIR) in their names. We invoke sed twice because it is the
- # simplest approach to changing $(DEPDIR) to its actual value in the
- # expansion.
- for file in `sed -n "
- s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
- sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g'`; do
- # Make sure the directory exists.
- test -f "$dirpart/$file" && continue
- fdir=`$as_dirname -- "$file" ||
-$as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$file" : 'X\(//\)[^/]' \| \
- X"$file" : 'X\(//\)$' \| \
- X"$file" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$file" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
- as_dir=$dirpart/$fdir; as_fn_mkdir_p
- # echo "creating $dirpart/$file"
- echo '# dummy' > "$dirpart/$file"
- done
- done
-}
- ;;
- "default-1":C)
- for ac_file in $CONFIG_FILES; do
- # Support "outfile[:infile[:infile...]]"
- case "$ac_file" in
- *:*) ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
- esac
- # PO directories have a Makefile.in generated from Makefile.in.in.
- case "$ac_file" in */Makefile.in)
- # Adjust a relative srcdir.
- ac_dir=`echo "$ac_file"|sed 's%/[^/][^/]*$%%'`
- ac_dir_suffix=/`echo "$ac_dir"|sed 's%^\./%%'`
- ac_dots=`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'`
- # In autoconf-2.13 it is called $ac_given_srcdir.
- # In autoconf-2.50 it is called $srcdir.
- test -n "$ac_given_srcdir" || ac_given_srcdir="$srcdir"
- case "$ac_given_srcdir" in
- .) top_srcdir=`echo $ac_dots|sed 's%/$%%'` ;;
- /*) top_srcdir="$ac_given_srcdir" ;;
- *) top_srcdir="$ac_dots$ac_given_srcdir" ;;
- esac
- if test -f "$ac_given_srcdir/$ac_dir/POTFILES.in"; then
- rm -f "$ac_dir/POTFILES"
- test -n "$as_me" && echo "$as_me: creating $ac_dir/POTFILES" || echo "creating $ac_dir/POTFILES"
- cat "$ac_given_srcdir/$ac_dir/POTFILES.in" | sed -e "/^#/d" -e "/^[ ]*\$/d" -e "s,.*, $top_srcdir/& \\\\," | sed -e "\$s/\(.*\) \\\\/\1/" > "$ac_dir/POTFILES"
- POMAKEFILEDEPS="POTFILES.in"
- # ALL_LINGUAS, POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES depend
- # on $ac_dir but don't depend on user-specified configuration
- # parameters.
- if test -f "$ac_given_srcdir/$ac_dir/LINGUAS"; then
- # The LINGUAS file contains the set of available languages.
- if test -n "$OBSOLETE_ALL_LINGUAS"; then
- test -n "$as_me" && echo "$as_me: setting ALL_LINGUAS in configure.ac is obsolete" || echo "setting ALL_LINGUAS in configure.ac is obsolete"
- fi
- ALL_LINGUAS_=`sed -e "/^#/d" "$ac_given_srcdir/$ac_dir/LINGUAS"`
- # Hide the ALL_LINGUAS assigment from automake.
- eval 'ALL_LINGUAS''=$ALL_LINGUAS_'
- POMAKEFILEDEPS="$POMAKEFILEDEPS LINGUAS"
- else
- # The set of available languages was given in configure.ac.
- eval 'ALL_LINGUAS''=$OBSOLETE_ALL_LINGUAS'
- fi
- case "$ac_given_srcdir" in
- .) srcdirpre= ;;
- *) srcdirpre='$(srcdir)/' ;;
- esac
- POFILES=
- GMOFILES=
- UPDATEPOFILES=
- DUMMYPOFILES=
- for lang in $ALL_LINGUAS; do
- POFILES="$POFILES $srcdirpre$lang.po"
- GMOFILES="$GMOFILES $srcdirpre$lang.gmo"
- UPDATEPOFILES="$UPDATEPOFILES $lang.po-update"
- DUMMYPOFILES="$DUMMYPOFILES $lang.nop"
- done
- # CATALOGS depends on both $ac_dir and the user's LINGUAS
- # environment variable.
- INST_LINGUAS=
- if test -n "$ALL_LINGUAS"; then
- for presentlang in $ALL_LINGUAS; do
- useit=no
- if test "%UNSET%" != "$LINGUAS"; then
- desiredlanguages="$LINGUAS"
- else
- desiredlanguages="$ALL_LINGUAS"
- fi
- for desiredlang in $desiredlanguages; do
- # Use the presentlang catalog if desiredlang is
- # a. equal to presentlang, or
- # b. a variant of presentlang (because in this case,
- # presentlang can be used as a fallback for messages
- # which are not translated in the desiredlang catalog).
- case "$desiredlang" in
- "$presentlang"*) useit=yes;;
- esac
- done
- if test $useit = yes; then
- INST_LINGUAS="$INST_LINGUAS $presentlang"
- fi
- done
- fi
- CATALOGS=
- if test -n "$INST_LINGUAS"; then
- for lang in $INST_LINGUAS; do
- CATALOGS="$CATALOGS $lang.gmo"
- done
- fi
- test -n "$as_me" && echo "$as_me: creating $ac_dir/Makefile" || echo "creating $ac_dir/Makefile"
- sed -e "/^POTFILES =/r $ac_dir/POTFILES" -e "/^# Makevars/r $ac_given_srcdir/$ac_dir/Makevars" -e "s|@POFILES@|$POFILES|g" -e "s|@GMOFILES@|$GMOFILES|g" -e "s|@UPDATEPOFILES@|$UPDATEPOFILES|g" -e "s|@DUMMYPOFILES@|$DUMMYPOFILES|g" -e "s|@CATALOGS@|$CATALOGS|g" -e "s|@POMAKEFILEDEPS@|$POMAKEFILEDEPS|g" "$ac_dir/Makefile.in" > "$ac_dir/Makefile"
- for f in "$ac_given_srcdir/$ac_dir"/Rules-*; do
- if test -f "$f"; then
- case "$f" in
- *.orig | *.bak | *~) ;;
- *) cat "$f" >> "$ac_dir/Makefile" ;;
- esac
- fi
- done
- fi
- ;;
- esac
- done ;;
- "default-2":C)
- for ac_file in $CONFIG_FILES; do
- # Support "outfile[:infile[:infile...]]"
- case "$ac_file" in
- *:*) ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
- esac
- # PO directories have a Makefile.in generated from Makefile.in.in.
- case "$ac_file" in */Makefile.in)
- # Adjust a relative srcdir.
- ac_dir=`echo "$ac_file"|sed 's%/[^/][^/]*$%%'`
- ac_dir_suffix=/`echo "$ac_dir"|sed 's%^\./%%'`
- ac_dots=`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'`
- # In autoconf-2.13 it is called $ac_given_srcdir.
- # In autoconf-2.50 it is called $srcdir.
- test -n "$ac_given_srcdir" || ac_given_srcdir="$srcdir"
- case "$ac_given_srcdir" in
- .) top_srcdir=`echo $ac_dots|sed 's%/$%%'` ;;
- /*) top_srcdir="$ac_given_srcdir" ;;
- *) top_srcdir="$ac_dots$ac_given_srcdir" ;;
- esac
- if test -f "$ac_given_srcdir/$ac_dir/POTFILES.in"; then
- rm -f "$ac_dir/POTFILES"
- test -n "$as_me" && echo "$as_me: creating $ac_dir/POTFILES" || echo "creating $ac_dir/POTFILES"
- cat "$ac_given_srcdir/$ac_dir/POTFILES.in" | sed -e "/^#/d" -e "/^[ ]*\$/d" -e "s,.*, $top_srcdir/& \\\\," | sed -e "\$s/\(.*\) \\\\/\1/" > "$ac_dir/POTFILES"
- POMAKEFILEDEPS="POTFILES.in"
- # ALL_LINGUAS, POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES depend
- # on $ac_dir but don't depend on user-specified configuration
- # parameters.
- if test -f "$ac_given_srcdir/$ac_dir/LINGUAS"; then
- # The LINGUAS file contains the set of available languages.
- if test -n "$OBSOLETE_ALL_LINGUAS"; then
- test -n "$as_me" && echo "$as_me: setting ALL_LINGUAS in configure.ac is obsolete" || echo "setting ALL_LINGUAS in configure.ac is obsolete"
- fi
- ALL_LINGUAS_=`sed -e "/^#/d" "$ac_given_srcdir/$ac_dir/LINGUAS"`
- # Hide the ALL_LINGUAS assigment from automake.
- eval 'ALL_LINGUAS''=$ALL_LINGUAS_'
- POMAKEFILEDEPS="$POMAKEFILEDEPS LINGUAS"
- else
- # The set of available languages was given in configure.ac.
- eval 'ALL_LINGUAS''=$OBSOLETE_ALL_LINGUAS'
- fi
- case "$ac_given_srcdir" in
- .) srcdirpre= ;;
- *) srcdirpre='$(srcdir)/' ;;
- esac
- POFILES=
- GMOFILES=
- UPDATEPOFILES=
- DUMMYPOFILES=
- for lang in $ALL_LINGUAS; do
- POFILES="$POFILES $srcdirpre$lang.po"
- GMOFILES="$GMOFILES $srcdirpre$lang.gmo"
- UPDATEPOFILES="$UPDATEPOFILES $lang.po-update"
- DUMMYPOFILES="$DUMMYPOFILES $lang.nop"
- done
- # CATALOGS depends on both $ac_dir and the user's LINGUAS
- # environment variable.
- INST_LINGUAS=
- if test -n "$ALL_LINGUAS"; then
- for presentlang in $ALL_LINGUAS; do
- useit=no
- if test "%UNSET%" != "$LINGUAS"; then
- desiredlanguages="$LINGUAS"
- else
- desiredlanguages="$ALL_LINGUAS"
- fi
- for desiredlang in $desiredlanguages; do
- # Use the presentlang catalog if desiredlang is
- # a. equal to presentlang, or
- # b. a variant of presentlang (because in this case,
- # presentlang can be used as a fallback for messages
- # which are not translated in the desiredlang catalog).
- case "$desiredlang" in
- "$presentlang"*) useit=yes;;
- esac
- done
- if test $useit = yes; then
- INST_LINGUAS="$INST_LINGUAS $presentlang"
- fi
- done
- fi
- CATALOGS=
- if test -n "$INST_LINGUAS"; then
- for lang in $INST_LINGUAS; do
- CATALOGS="$CATALOGS $lang.gmo"
- done
- fi
- test -n "$as_me" && echo "$as_me: creating $ac_dir/Makefile" || echo "creating $ac_dir/Makefile"
- sed -e "/^POTFILES =/r $ac_dir/POTFILES" -e "/^# Makevars/r $ac_given_srcdir/$ac_dir/Makevars" -e "s|@POFILES@|$POFILES|g" -e "s|@GMOFILES@|$GMOFILES|g" -e "s|@UPDATEPOFILES@|$UPDATEPOFILES|g" -e "s|@DUMMYPOFILES@|$DUMMYPOFILES|g" -e "s|@CATALOGS@|$CATALOGS|g" -e "s|@POMAKEFILEDEPS@|$POMAKEFILEDEPS|g" "$ac_dir/Makefile.in" > "$ac_dir/Makefile"
- for f in "$ac_given_srcdir/$ac_dir"/Rules-*; do
- if test -f "$f"; then
- case "$f" in
- *.orig | *.bak | *~) ;;
- *) cat "$f" >> "$ac_dir/Makefile" ;;
- esac
- fi
- done
- fi
- ;;
- esac
- done ;;
-
- esac
-done # for ac_tag
-
-
-as_fn_exit 0
-_ACEOF
-ac_clean_files=$ac_clean_files_save
-
-test $ac_write_fail = 0 ||
- as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
-
-
-# configure is writing to config.log, and then calls config.status.
-# config.status does its own redirection, appending to config.log.
-# Unfortunately, on DOS this fails, as config.log is still kept open
-# by configure, so config.status won't be able to write to it; its
-# output is simply discarded. So we exec the FD to /dev/null,
-# effectively closing config.log, so it can be properly (re)opened and
-# appended to by config.status. When coming back to configure, we
-# need to make the FD available again.
-if test "$no_create" != yes; then
- ac_cs_success=:
- ac_config_status_args=
- test "$silent" = yes &&
- ac_config_status_args="$ac_config_status_args --quiet"
- exec 5>/dev/null
- $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
- exec 5>>config.log
- # Use ||, not &&, to avoid exiting from the if with $? = 1, which
- # would make configure fail if this is the last instruction.
- $ac_cs_success || as_fn_exit 1
-fi
-if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
-$as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
-fi
-
Property changes on: sources/GNU/binutils/create-2.43.1-gold-warn-unsupported-patch/binutils-2.43.1-new/gold/configure
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: sources/GNU/binutils/create-2.43.1-gold-warn-unsupported-patch/binutils-2.43.1-new/gold/configure.ac
===================================================================
--- sources/GNU/binutils/create-2.43.1-gold-warn-unsupported-patch/binutils-2.43.1-new/gold/configure.ac (revision 75)
+++ sources/GNU/binutils/create-2.43.1-gold-warn-unsupported-patch/binutils-2.43.1-new/gold/configure.ac (nonexistent)
@@ -1,741 +0,0 @@
-dnl Process this file with autoconf to produce a configure script.
-dnl
-dnl Copyright (C) 2006-2024 Free Software Foundation, Inc.
-dnl
-dnl This file is free software; you can redistribute it and/or modify
-dnl it under the terms of the GNU General Public License as published by
-dnl the Free Software Foundation; either version 3 of the License, or
-dnl (at your option) any later version.
-dnl
-dnl This program is distributed in the hope that it will be useful,
-dnl but WITHOUT ANY WARRANTY; without even the implied warranty of
-dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-dnl GNU General Public License for more details.
-dnl
-dnl You should have received a copy of the GNU General Public License
-dnl along with this program; see the file COPYING3. If not see
-dnl <http://www.gnu.org/licenses/>.
-dnl
-
-AC_INIT([gold], [0.1])
-AC_CONFIG_SRCDIR(gold.cc)
-
-AC_CANONICAL_TARGET
-
-AM_INIT_AUTOMAKE([no-dist parallel-tests])
-AM_SILENT_RULES([yes])
-
-AM_CONFIG_HEADER(config.h:config.in)
-
-AC_USE_SYSTEM_EXTENSIONS
-
-# PR 14072
-AH_VERBATIM([00_CONFIG_H_CHECK],
-[/* Check that config.h is #included before system headers
- (this works only for glibc, but that should be enough). */
-#if defined(__GLIBC__) && !defined(__FreeBSD_kernel__) && !defined(__CONFIG_H__)
-# error config.h must be #included before system headers
-#endif
-#define __CONFIG_H__ 1])
-
-AC_ARG_WITH(sysroot,
-[ --with-sysroot[=DIR] search for usr/lib et al within DIR],
-[sysroot=$withval], [sysroot=no])
-
-if test "$sysroot" = "yes"; then
- sysroot='${exec_prefix}/${target_alias}/sys-root'
-elif test "$sysroot" = "no"; then
- sysroot=
-fi
-
-sysroot_relocatable=0
-if test -n "$sysroot"; then
- case "$sysroot" in
- "${prefix}" | "${prefix}/"* | \
- "${exec_prefix}" | "${exec_prefix}/"* | \
- '${prefix}' | '${prefix}/'*| \
- '${exec_prefix}' | '${exec_prefix}/'*)
- sysroot_relocatable=1
- ;;
- esac
-fi
-
-AC_DEFINE_UNQUOTED(TARGET_SYSTEM_ROOT, "$sysroot",
- [System root for target files])
-AC_DEFINE_UNQUOTED(TARGET_SYSTEM_ROOT_RELOCATABLE, $sysroot_relocatable,
- [Whether the system root can be relocated])
-
-dnl "install_as_default" is true if the linker to be installed as the
-dnl default linker, ld.
-dnl "installed_linker" is the installed gold linker name.
-
-installed_linker=ld.gold
-AC_ARG_ENABLE(gold,
-[[ --enable-gold[=ARG] build gold [ARG={default,yes,no}]]],
-[case "${enableval}" in
- default)
- install_as_default=yes
- ;;
- yes)
- if test x${enable_ld} = xno; then
- install_as_default=yes
- fi
- ;;
- esac],
-[install_as_default=no])
-AC_SUBST(install_as_default)
-AC_SUBST(installed_linker)
-
-AC_PLUGINS
-if test "$plugins" = "yes"; then
- AC_DEFINE(ENABLE_PLUGINS, 1,
- [Define to enable linker plugins])
-fi
-AM_CONDITIONAL(PLUGINS, test "$plugins" = "yes")
-
-# Decide if -z relro should be enabled in ELF linker by default.
-ac_default_ld_z_relro=unset
-# Provide a configure time option to override our default.
-AC_ARG_ENABLE(relro,
- AS_HELP_STRING([--enable-relro],
- [enable -z relro in ELF linker by default]),
-[case "${enableval}" in
- yes) ac_default_ld_z_relro=1 ;;
- no) ac_default_ld_z_relro=0 ;;
-esac])dnl
-if test "${ac_default_ld_z_relro}" = unset; then
- ac_default_ld_z_relro=1
-fi
-AC_DEFINE_UNQUOTED(DEFAULT_LD_Z_RELRO,
- $ac_default_ld_z_relro,
- [Define to 1 if you want to enable -z relro in ELF linker by default.])
-
-AC_ARG_ENABLE([targets],
-[ --enable-targets alternative target configurations],
-[case "${enableval}" in
- yes | "")
- AC_MSG_ERROR([--enable-targets option must specify target names or 'all'])
- ;;
- no)
- enable_targets=
- ;;
- *)
- enable_targets=$enableval
- ;;
-esac],
-[# For now, enable all targets by default
- enable_targets=all
-])
-
-# Canonicalize the enabled targets.
-if test -n "$enable_targets"; then
- for targ in `echo $enable_targets | sed -e 's/,/ /g'`; do
- result=`$ac_config_sub $targ 2>/dev/null`
- if test -n "$result"; then
- canon_targets="$canon_targets $result"
- else
- # Permit unrecognized target names, like "all".
- canon_targets="$canon_targets $targ"
- fi
- done
-fi
-
-# Decide which "--hash-style" to use by default
-# Provide a configure time option to override our default.
-AC_ARG_ENABLE([default-hash-style],
-AS_HELP_STRING([--enable-default-hash-style={sysv,gnu,both}],
- [use this default hash style]),
-[case "${enable_default_hash_style}" in
- sysv | gnu | both) ;;
- *) AC_MSG_ERROR([bad value ${enable_default_hash_style} for enable-default-hash-style option]) ;;
-esac],
-[case "${target}" in
- # Enable gnu hash only on GNU targets, but not mips
- mips*-*-*) enable_default_hash_style=sysv ;;
- *-*-gnu* | *-*-linux* | *-*-nacl*) enable_default_hash_style=both ;;
- *) enable_default_hash_style=sysv ;;
-esac])
-
-AC_DEFINE_UNQUOTED([DEFAULT_HASH_STYLE],
- ["${enable_default_hash_style}"],
- [Set the default --hash-style value])
-
-# See which specific instantiations we need.
-targetobjs=
-all_targets=
-default_machine=
-default_size=
-default_big_endian=
-default_osabi=ELFOSABI_NONE
-targ_32_little=
-targ_32_big=
-targ_64_little=
-targ_64_big=
-for targ in $target $canon_targets; do
- if test "$targ" = "all"; then
- targ_32_little=yes
- targ_32_big=yes
- targ_64_little=yes
- targ_64_big=yes
- all_targets=yes
- else
- . ${srcdir}/configure.tgt
-
- if test "$targ_obj" = "UNKNOWN"; then
- AC_MSG_WARN("unsupported target $targ")
- else
- targetobjs="$targetobjs ${targ_obj}.\$(OBJEXT)"
- if test "$targ_extra_obj" != ""; then
- targetobjs="$targetobjs ${targ_extra_obj}.\$(OBJEXT)"
- fi
- if test "$targ_size" = "32" -o "$targ_extra_size" = "32"; then
- if test "$targ_big_endian" = "true" \
- -o "$targ_extra_big_endian" = "true"; then
- targ_32_big=yes
- fi
- if test "$targ_big_endian" = "false" \
- -o "$targ_extra_big_endian" = "false"; then
- targ_32_little=yes
- fi
- fi
- if test "$targ_size" = "64" -o "$targ_extra_size" = "64"; then
- if test "$targ_big_endian" = "true" \
- -o "$targ_extra_big_endian" = "true"; then
- targ_64_big=yes
- fi
- if test "$targ_big_endian" = "false" \
- -o "$targ_extra_big_endian" = "false"; then
- targ_64_little=yes
- fi
- fi
-
- if test "$target" = "$targ"; then
- default_machine=$targ_machine
- default_size=$targ_size
- default_big_endian=$targ_big_endian
- default_osabi=$targ_osabi
-
- AM_CONDITIONAL(DEFAULT_TARGET_AARCH64, test "$targ_obj" = "aarch64")
- AM_CONDITIONAL(DEFAULT_TARGET_ARM, test "$targ_obj" = "arm")
- AM_CONDITIONAL(DEFAULT_TARGET_I386, test "$targ_obj" = "i386")
- AM_CONDITIONAL(DEFAULT_TARGET_POWERPC, test "$targ_obj" = "powerpc")
- AM_CONDITIONAL(DEFAULT_TARGET_SPARC, test "$targ_obj" = "sparc")
- AM_CONDITIONAL(DEFAULT_TARGET_S390, test "$targ_obj" = "s390")
- target_x86_64=no
- target_x32=no
- if test "$targ_obj" = "x86_64"; then
- case "$target" in
- x86_64*-linux-gnux32)
- target_x32=yes
- default_size=32
- ;;
- *)
- target_x86_64=yes
- ;;
- esac
- fi
- AM_CONDITIONAL(DEFAULT_TARGET_X86_64, test "$target_x86_64" = "yes")
- AM_CONDITIONAL(DEFAULT_TARGET_X32, test "$target_x32" = "yes")
- AM_CONDITIONAL(DEFAULT_TARGET_X86_64_OR_X32,
- test "$target_x86_64" = "yes" -o "$target_x32" = "yes")
- AM_CONDITIONAL(DEFAULT_TARGET_TILEGX, test "$targ_obj" = "tilegx")
- AM_CONDITIONAL(DEFAULT_TARGET_MIPS, test "$targ_obj" = "mips")
- DEFAULT_TARGET=${targ_obj}
- AC_SUBST(DEFAULT_TARGET)
- fi
- fi
- fi
-done
-
-# Remove any duplicates.
-to=""
-for t in $targetobjs; do
- case " $to " in
- *" $t "*) ;;
- *) to="$to $t" ;;
- esac
-done
-targetobjs=$to
-
-if test -n "$targ_32_little"; then
- AC_DEFINE(HAVE_TARGET_32_LITTLE, 1,
- [Define to support 32-bit little-endian targets])
-fi
-if test -n "$targ_32_big"; then
- AC_DEFINE(HAVE_TARGET_32_BIG, 1,
- [Define to support 32-bit big-endian targets])
-fi
-if test -n "$targ_64_little"; then
- AC_DEFINE(HAVE_TARGET_64_LITTLE, 1,
- [Define to support 64-bit little-endian targets])
-fi
-if test -n "$targ_64_big"; then
- AC_DEFINE(HAVE_TARGET_64_BIG, 1,
- [Define to support 64-bit big-endian targets])
-fi
-
-if test -n "$all_targets"; then
- TARGETOBJS='$(ALL_TARGETOBJS)'
-else
- TARGETOBJS="$targetobjs"
-fi
-AC_SUBST(TARGETOBJS)
-
-AC_DEFINE_UNQUOTED(GOLD_DEFAULT_MACHINE, $default_machine,
- [Default machine code])
-AC_DEFINE_UNQUOTED(GOLD_DEFAULT_SIZE, $default_size,
- [Default size (32 or 64)])
-AC_DEFINE_UNQUOTED(GOLD_DEFAULT_BIG_ENDIAN, $default_big_endian,
- [Default big endian (true or false)])
-AC_DEFINE_UNQUOTED(GOLD_DEFAULT_OSABI, $default_osabi,
- [Default OSABI code])
-
-AC_ARG_WITH(lib-path,
-[ --with-lib-path=dir1:dir2... set default LIB_PATH],
-[case "$withval" in
- yes) LIB_PATH='"/lib:/usr/lib"' ;;
- no) LIB_PATH='""' ;;
- *) LIB_PATH='"'"$withval"'"' ;;
- esac],
-[LIB_PATH='"::DEFAULT::"'])
-AC_DEFINE_UNQUOTED(LIB_PATH, $LIB_PATH,
- [Default library search path])
-if test "x$target_alias" = "x" -o "x$host_alias" = "x$target_alias"; then
- AC_DEFINE(NATIVE_LINKER, 1, [Whether configured as a native linker])
-fi
-
-AC_CHECK_TOOL(NM, nm)
-
-AC_PROG_CC
-AC_PROG_CXX
-AC_PROG_YACC
-AC_PROG_RANLIB
-AC_PROG_INSTALL
-AC_PROG_LN_S
-
-ZW_GNU_GETTEXT_SISTER_DIR
-AM_PO_SUBDIRS
-
-AC_C_BIGENDIAN
-
-AC_EXEEXT
-
-AM_CONDITIONAL(NATIVE_LINKER,
- test "x$target_alias" = "x" -o "x$host_alias" = "x$target_alias")
-AM_CONDITIONAL(GCC, test "$GCC" = yes)
-
-AM_CONDITIONAL(NATIVE_OR_CROSS_LINKER,
- test "x$target_alias" = "x" -o "x$host_alias" = "x$target_alias" -o "x$host_alias" = "x$build_alias")
-
-dnl Test for whether static linking is supported. Some systems do not
-dnl install static libraries. This only affects the set of tests that
-dnl we run.
-AC_CACHE_CHECK([whether static linking works], [gold_cv_lib_static],
-[LDFLAGS_hold=$LDFLAGS
-LDFLAGS="$LDFLAGS -static"
-AC_LINK_IFELSE([
-AC_LANG_PROGRAM([[void f() { }]])],
-[gold_cv_lib_static=yes], [gold_cv_lib_static=no])
-LDFLAGS=$LDFLAGS_hold])
-AM_CONDITIONAL(HAVE_STATIC, test "$gold_cv_lib_static" = "yes")
-
-dnl Some architectures do not support taking pointers of functions
-dnl defined in shared libraries except in -fPIC mode. We need to
-dnl tell the unittest framework if we're compiling for one of those
-dnl targets, so it doesn't try to run the tests that do that.
-AM_CONDITIONAL(FN_PTRS_IN_SO_WITHOUT_PIC, [
- case $target_cpu in
- powerpc*) false;;
- x86_64) false;;
- sparc64) false;;
- s390x) false;;
- *) true;;
- esac])
-
-dnl Test for gcc 4.1 or later. Full support for -mcmodel=medium is
-dnl only available in gcc 4.1.
-AC_CACHE_CHECK([for gcc >= 4.1], [gold_cv_prog_gcc41],
-[AC_COMPILE_IFELSE([AC_LANG_SOURCE([
-#if !defined __GNUC__
-error
-#elif __GNUC__ < 4 || (__GNUC__ == 4 && __GNUC_MINOR__ < 1)
-error
-#endif
-])], [gold_cv_prog_gcc41=yes], [gold_cv_prog_gcc41=no])])
-
-save_CFLAGS="$CFLAGS"
-CFLAGS="$CFLAGS -mcmodel=medium"
-AC_COMPILE_IFELSE([AC_LANG_SOURCE([int i;])], [have_mcmodel_medium=yes], [have_mcmodel_medium=no])
-CFLAGS="$save_CFLAGS"
-dnl Whether we can test -mcmodel=medium.
-AM_CONDITIONAL(MCMODEL_MEDIUM,
-[test "$target_cpu" = "x86_64" -a "$have_mcmodel_medium" = "yes" -a "$gold_cv_prog_gcc41" = "yes"])
-
-dnl Test for gcc 9 or later. Some incremental tests fail with GCC 9 or
-dnl later.
-AC_CACHE_CHECK([for gcc >= 9], [gold_cv_prog_gcc9],
-[AC_COMPILE_IFELSE([AC_LANG_SOURCE([
-#if !defined __GNUC__ || __GNUC__ < 9
-error
-#endif
-])], [gold_cv_prog_gcc9=yes], [gold_cv_prog_gcc9=no])])
-AM_CONDITIONAL(GCC9, [test "$gold_cv_prog_gcc9" = "yes"])
-
-dnl Test for -fcf-protection on x86-64. Some incremental tests fail with
-dnl -fcf-protection.
-AC_CACHE_CHECK([for -fcf-protection], [gold_cv_cflags_cf_protection],
-[AC_COMPILE_IFELSE([AC_LANG_SOURCE([
-#if !defined __x86_64__ || !defined __CET__
-error
-#endif
-])], [gold_cv_cflags_cf_protection=yes], [gold_cv_cflags_cf_protection=no])])
-AM_CONDITIONAL(CFLAGS_CF_PROTECTION, [test "$gold_cv_cflags_cf_protection" = "yes"])
-
-AC_CACHE_CHECK([whether $CC supports -fmerge-constants],
- [gold_cv_merge_constants], [
-save_CFLAGS="$CFLAGS"
-CFLAGS="$CFLAGS -fmerge-constants"
-AC_COMPILE_IFELSE([AC_LANG_SOURCE([const char *s = "foo";])],
- [gold_cv_merge_constants=yes],
- [gold_cv_merge_constants=no])
-CFLAGS="$save_CFLAGS"])
-AC_SUBST([MERGE_CONSTANTS_FLAG])
-AS_IF([test "$gold_cv_merge_constants" = yes],
- [MERGE_CONSTANTS_FLAG=-fmerge-constants],
- [MERGE_CONSTANTS_FLAG=])
-
-dnl Test for __thread support.
-AC_CACHE_CHECK([for thread support], [gold_cv_c_thread],
-[AC_COMPILE_IFELSE([AC_LANG_SOURCE([__thread int i = 1;])],
-[gold_cv_c_thread=yes], [gold_cv_c_thread=no])])
-
-AM_CONDITIONAL(TLS, test "$gold_cv_c_thread" = "yes")
-
-dnl On GNU/Linux TLS in static programs only works when using glibc
-dnl 2.4 or later.
-AC_CACHE_CHECK([for glibc >= 2.4], [gold_cv_lib_glibc24],
-[AC_COMPILE_IFELSE([AC_LANG_SOURCE([
-#include <features.h>
-#if !defined __GLIBC__
-error
-#elif __GLIBC__ < 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ < 4)
-error
-#endif
-])], [gold_cv_lib_glibc24=yes], [gold_cv_lib_glibc24=no])])
-
-AM_CONDITIONAL(STATIC_TLS, test "$gold_cv_lib_glibc24" = "yes")
-
-dnl Test for #pragma omp threadprivate
-AC_CACHE_CHECK([for omp support], [gold_cv_c_threadprivate],
-[save_CFLAGS="$CFLAGS"
-CFLAGS="$CFLAGS -fopenmp"
-AC_COMPILE_IFELSE([AC_LANG_SOURCE([
-#include <omp.h>
-int i;
-#pragma omp threadprivate (i)
-])], [gold_cv_c_threadprivate=yes], [gold_cv_c_threadprivate=no])
-CFLAGS="$save_CFLAGS"])
-if test "$gold_cv_c_threadprivate" = "yes"; then
- AC_DEFINE(HAVE_OMP_SUPPORT, 1,
- [Define if compiler supports #pragma omp threadprivate])
-fi
-AM_CONDITIONAL(OMP_SUPPORT, test "$gold_cv_c_threadprivate" = "yes")
-
-dnl Test for the -ftls-dialect=gnu2 option.
-dnl Use -Werror in case of compilers that make unknown -m options warnings.
-dnl They would pass the test here, but fail in actual use when $WARN_CFLAGS
-dnl gets set later by default Autoconf magic to include -Werror. (We are
-dnl assuming here that there is no compiler that groks -mtls-dialect=gnu2
-dnl but does not grok -Werror.)
-save_CFLAGS="$CFLAGS"
-CFLAGS="$CFLAGS -Werror -fpic -mtls-dialect=gnu2"
-AC_COMPILE_IFELSE([AC_LANG_SOURCE([
-__thread int i;
-void foo (void)
-{
- i = 10;
-}
-])], [have_tls_gnu2=yes], [have_tls_gnu2=no])
-CFLAGS="$save_CFLAGS"
-AM_CONDITIONAL(TLS_GNU2_DIALECT, test "$have_tls_gnu2" = "yes")
-
-dnl On GNU/Linux TLS descriptors are supported by the dynamic loader
-dnl only with glibc 2.9 or later.
-AC_CACHE_CHECK([for glibc >= 2.9], [gold_cv_lib_glibc29],
-[AC_COMPILE_IFELSE([AC_LANG_SOURCE([
-#include <features.h>
-#if !defined __GLIBC__
-error
-#elif __GLIBC__ < 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ < 9)
-error
-#endif
-])], [gold_cv_lib_glibc29=yes], [gold_cv_lib_glibc29=no])])
-
-AM_CONDITIONAL(TLS_DESCRIPTORS, test "$gold_cv_lib_glibc29" = "yes")
-
-dnl Test for the -frandom-seed option.
-AC_CACHE_CHECK([for -frandom-seed support], [gold_cv_c_random_seed],
-[save_CFLAGS="$CFLAGS"
-CFLAGS="$CFLAGS -frandom-seed=foo"
-AC_COMPILE_IFELSE([AC_LANG_SOURCE([int i;])], [gold_cv_c_random_seed=yes],
-[gold_cv_c_random_seed=no])
-CFLAGS="$save_CFLAGS"])
-if test "$gold_cv_c_random_seed" = "yes"; then
- # In Makefile, '$@' will be expanded to be the name of the file
- # being built, providing a unique seed for each file.
- RANDOM_SEED_CFLAGS=-frandom-seed=\$@
-fi
-AC_SUBST(RANDOM_SEED_CFLAGS)
-
-dnl On GNU/Linux ifunc is supported by the dynamic linker in glibc
-dnl 2.11 or later, and by binutils 2.20.1 or later.
-AC_CACHE_CHECK([for glibc ifunc support], [gold_cv_lib_glibc_ifunc],
-[save_LDFLAGS="$LDFLAGS"
-LDFLAGS="$LDFLAGS -static"
-AC_LINK_IFELSE([AC_LANG_PROGRAM([[
-#include <features.h>
-#if !defined __GLIBC__
-error
-#elif __GLIBC__ < 2 || (__GLIBC__ == 2 && __GLIBC_MINOR__ < 11)
-error
-#endif
-void func (void) { }
-void invoke (void);
-__asm__(".type invoke, %gnu_indirect_function");
-typedef void (*funcptr) (void);
-funcptr dispatch (void) __asm__ ("invoke");
-funcptr dispatch (void) { return &func; }]],
-[[invoke();]])
-], [
-if ${NM} conftest$EXEEXT | grep "__rela\?_iplt_start" >/dev/null 2>&1; then
- gold_cv_lib_glibc_ifunc=both
-else
- gold_cv_lib_glibc_ifunc=dyn
-fi], [gold_cv_lib_glibc_ifunc=no])
-LDFLAGS="$save_LDFLAGS"])
-
-AM_CONDITIONAL(IFUNC, test "$gold_cv_lib_glibc_ifunc" != "no")
-AM_CONDITIONAL(IFUNC_STATIC, test "$gold_cv_lib_glibc_ifunc" = "both")
-
-AM_BINUTILS_WARNINGS
-
-WARN_CXXFLAGS=`echo ${WARN_CFLAGS} | sed -e 's/-Wstrict-prototypes//' -e 's/-Wmissing-prototypes//' -e 's/-Wshadow//'`
-AC_SUBST(WARN_CXXFLAGS)
-
-AC_ARG_WITH(gold-ldflags,
-[ --with-gold-ldflags=FLAGS additional link flags for gold],
-[if test "$withval" = "no" -o "$withval" = "yes"; then
- GOLD_LDFLAGS=
- else
- GOLD_LDFLAGS=$withval
- fi],
-[GOLD_LDFLAGS=])
-AC_SUBST(GOLD_LDFLAGS)
-
-AC_ARG_WITH(gold-ldadd,
-[ --with-gold-ldadd=LIBS additional libraries for gold],
-[if test "$withval" = "no" -o "$withval" = "yes"; then
- GOLD_LDADD=
- else
- GOLD_LDADD=$withval
- fi],
-[GOLD_LDADD=])
-AC_SUBST(GOLD_LDADD)
-
-dnl Force support for large files by default. This may need to be
-dnl host dependent. If build == host, we can check getconf LFS_CFLAGS.
-LFS_CFLAGS="-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64"
-AC_SUBST(LFS_CFLAGS)
-
-AC_CHECK_HEADERS(sys/mman.h)
-AC_CHECK_FUNCS(chsize mmap link)
-AC_REPLACE_FUNCS(pread ftruncate ffsll)
-
-AC_CACHE_CHECK([mremap with MREMAP_MAYMOVE], [gold_cv_lib_mremap_maymove],
-[AC_LINK_IFELSE([
-AC_LANG_PROGRAM([[
-#include <sys/mman.h>
-void f() { mremap (0, 0, 0, MREMAP_MAYMOVE); }
-]])], [gold_cv_lib_mremap_maymove=yes], [gold_cv_lib_mremap_maymove=no])])
-if test "$gold_cv_lib_mremap_maymove" = "yes"; then
- AC_DEFINE(HAVE_MREMAP, 1,
- [Define to 1 if you have the mremap function with MREMAP_MAYMOVE support])
-else
- AC_LIBOBJ(mremap)
-fi
-
-# Link in zlib/zstd if we can. This allows us to write compressed sections.
-AM_ZLIB
-AC_ZSTD
-AM_CONDITIONAL(HAVE_ZSTD, test "$pkg_cv_ZSTD_LIBS" != "")
-
-AC_ARG_ENABLE([threads],
-[[ --enable-threads[=ARG] multi-threaded linking [ARG={auto,yes,no}]]],
-[case "${enableval}" in
- yes | "") threads=yes ;;
- no) threads=no ;;
- auto) threads=auto ;;
- *) threads=yes ;;
- esac],
-[threads=auto])
-
-if test "$threads" = "yes"; then
- AX_PTHREAD([threads=yes], AC_MSG_ERROR([pthread not found]))
-elif test "$threads" = "auto"; then
- AX_PTHREAD([threads=yes], [threads=no])
-fi
-
-if test "$threads" = "yes"; then
- AC_DEFINE(ENABLE_THREADS, 1,
- [Define to do multi-threaded linking])
-fi
-AM_CONDITIONAL(THREADS, test "$threads" = "yes")
-
-# Used to validate --package-metadata= input. Disabled by default.
-AC_ARG_ENABLE([jansson],
- [AS_HELP_STRING([--enable-jansson],
- [enable jansson [default=no]])],
- [enable_jansson=$enableval],
- [enable_jansson="no"])
-
-if test "x$enable_jansson" != "xno"; then
- PKG_PROG_PKG_CONFIG
- AS_IF([test -n "$PKG_CONFIG"],
- [
- PKG_CHECK_MODULES(JANSSON, [jansson],
- [
- AC_DEFINE(HAVE_JANSSON, 1, [The jansson library is to be used])
- AC_SUBST([JANSSON_CFLAGS])
- AC_SUBST([JANSSON_LIBS])
- ],
- [
- AC_MSG_ERROR([Cannot find jansson library])
- ])
- ],
- [
- AC_MSG_ERROR([Cannot find pkg-config])
- ])
-fi
-
-dnl We have to check these in C, not C++, because autoconf generates
-dnl tests which have no type information, and current glibc provides
-dnl multiple declarations of functions like basename when compiling
-dnl with C++.
-AC_CHECK_DECLS([basename, ffs, asprintf, vasprintf, snprintf, vsnprintf, strverscmp])
-
-dnl Check if gcc supports the -gpubnames option.
-dnl Use -Werror in case of compilers that make unknown -g options warnings.
-dnl They would pass the test here, but fail in actual use when $WARN_CFLAGS
-dnl gets set later by default Autoconf magic to include -Werror. (We are
-dnl assuming here that there is no compiler that groks -gpubnames
-dnl but does not grok -Werror.)
-save_CFLAGS="$CFLAGS"
-CFLAGS="$CFLAGS -Werror -gpubnames"
-AC_COMPILE_IFELSE([AC_LANG_SOURCE([int i;])], [have_pubnames=yes], [have_pubnames=no])
-CFLAGS="$save_CFLAGS"
-AM_CONDITIONAL(HAVE_PUBNAMES, test "$have_pubnames" = "yes")
-
-dnl Check if gcc supports the -fno-use-linker-plugin option.
-save_CFLAGS="$CFLAGS"
-CFLAGS="$CFLAGS -Werror -fno-use-linker-plugin"
-AC_COMPILE_IFELSE([AC_LANG_SOURCE([int i;])], [have_no_use_linker_plugin=yes], [have_no_use_linker_plugin=no])
-CFLAGS="$save_CFLAGS"
-AM_CONDITIONAL(HAVE_NO_USE_LINKER_PLUGIN, test "$have_no_use_linker_plugin" = "yes")
-
-AC_LANG_PUSH(C++)
-
-AC_CHECK_HEADERS(unordered_set unordered_map)
-AC_CHECK_HEADERS(tr1/unordered_set tr1/unordered_map)
-AC_CHECK_HEADERS(ext/hash_map ext/hash_set)
-AC_CHECK_HEADERS(byteswap.h)
-
-dnl Check for bswap_{16,32,64}
-AC_CHECK_DECLS([bswap_16, bswap_32, bswap_64], [], [], [[#include <byteswap.h>]])
-
-dnl When plugins enabled dynamic loader interface is required. Check headers
-dnl which may provide this interface. Add the necessary library to link.
-AC_CHECK_HEADERS(windows.h)
-AC_CHECK_HEADERS(dlfcn.h)
-AC_SEARCH_LIBS(dlopen, [dl dld])
-case "$ac_cv_search_dlopen" in
- no*) DLOPEN_LIBS="";;
- *) DLOPEN_LIBS="$ac_cv_search_dlopen";;
-esac
-AC_SUBST(DLOPEN_LIBS)
-
-AC_CHECK_FUNCS(mallinfo mallinfo2 posix_fallocate fallocate readv sysconf times mkdtemp)
-AC_CHECK_DECLS([basename, ffs, asprintf, vasprintf, snprintf, vsnprintf, strverscmp, strndup, memmem])
-
-# Use of ::std::tr1::unordered_map::rehash causes undefined symbols
-# at link time with some versions of GCC.
-AC_CACHE_CHECK([whether ::std::tr1::unordered_map::rehash is usable.],
-[gold_cv_unordered_map_rehash],
-[AC_LINK_IFELSE([AC_LANG_PROGRAM([[
-#include <tr1/unordered_map>
-void bar() { ::std::tr1::unordered_map<int, int> x; x.rehash(10); }
-]])], [gold_cv_unordered_map_rehash=yes], [gold_cv_unordered_map_rehash=no])])
-if test "$gold_cv_unordered_map_rehash" = "yes"; then
- AC_DEFINE(HAVE_TR1_UNORDERED_MAP_REHASH, 1,
- [Define if ::std::tr1::unordered_map::rehash is usable])
-fi
-
-# Since 5e9091dab8858b25210a91d22fbbbfdee9c969ad gold now requires C++11
-# So we need to check for it.
-AX_CXX_COMPILE_STDCXX([11], [], [mandatory])
-
-# Use of tr1/unordered_map with off_t as a key is not supported on GCC
-# 4.1.xx when compiling in 32-bit mode with a 64-bit off_t type.
-AC_CACHE_CHECK([whether std::tr1::hash<off_t> is defined],
-[gold_cv_hash_off_t],
-[CXXFLAGS_hold=$CXXFLAGS
-CXXFLAGS="$CXXFLAGS $LFS_CFLAGS"
-AC_COMPILE_IFELSE([AC_LANG_SOURCE([
-#include <sys/types.h>
-#include <tr1/unordered_map>
-std::tr1::hash<off_t> h;
-])],
-[gold_cv_hash_off_t=yes],
-[gold_cv_hash_off_t=no])
-CXXFLAGS=$CXXFLAGS_hold])
-if test "$gold_cv_hash_off_t" = "yes"; then
- AC_DEFINE(HAVE_TR1_HASH_OFF_T, 1,
- [Define if std::tr1::hash<off_t> is usable])
-fi
-
-# gcc 4.3.0 doesn't recognize the printf attribute on a template
-# function. Check for that. This is gcc bug 35546. This test can
-# probably be removed after the bug has been fixed for a while.
-AC_CACHE_CHECK([whether we can use attributes with template functions],
-[gold_cv_template_attribute],
-[AC_COMPILE_IFELSE([AC_LANG_SOURCE([
-template<typename T> extern void foo(const char*, ...)
- __attribute__ ((__format__ (__printf__, 1, 2)));
-template<typename T> void foo(const char* format, ...) {}
-void bar() { foo<int>("%s\n", "foo"); }
-])], [gold_cv_template_attribute=yes], [gold_cv_template_attribute=no])])
-if test "$gold_cv_template_attribute" = "yes"; then
- AC_DEFINE(HAVE_TEMPLATE_ATTRIBUTES, 1,
- [Define if attributes work on C++ templates])
-fi
-
-dnl Check if the system has struct stat::st_mtim.
-AC_CACHE_CHECK([for struct stat::st_mtim.],
-[gold_cv_stat_st_mtim],
-[AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
-#include <sys/stat.h>
-long bar() { struct stat s; return (long)(s.st_mtim.tv_sec + s.st_mtim.tv_sec);}
-]])], [gold_cv_stat_st_mtim=yes], [gold_cv_stat_st_mtim=no])])
-if test "$gold_cv_stat_st_mtim" = "yes"; then
- AC_DEFINE(HAVE_STAT_ST_MTIM, 1,
- [Define if struct stat has a field st_mtim with timespec for mtime])
-fi
-
-AC_LANG_POP(C++)
-
-AC_CHECK_HEADERS(locale.h)
-AC_CHECK_FUNCS(setlocale)
-AM_LC_MESSAGES
-
-AM_MAINTAINER_MODE
-
-AC_OUTPUT(Makefile testsuite/Makefile po/Makefile.in:po/Make-in)
Index: sources/GNU/binutils/create-2.43.1-gold-i386-gnu-property-notes-patch/file.list
===================================================================
--- sources/GNU/binutils/create-2.43.1-gold-i386-gnu-property-notes-patch/file.list (revision 75)
+++ sources/GNU/binutils/create-2.43.1-gold-i386-gnu-property-notes-patch/file.list (nonexistent)
@@ -1 +0,0 @@
-binutils-2.43.1/gold/i386.cc
Index: sources/GNU/binutils/create-2.43.1-gold-i386-gnu-property-notes-patch/create.patch.sh
===================================================================
--- sources/GNU/binutils/create-2.43.1-gold-i386-gnu-property-notes-patch/create.patch.sh (revision 75)
+++ sources/GNU/binutils/create-2.43.1-gold-i386-gnu-property-notes-patch/create.patch.sh (nonexistent)
@@ -1,15 +0,0 @@
-#!/bin/bash
-
-VERSION=2.43.1
-
-tar --files-from=file.list -xJvf ../binutils-$VERSION.tar.xz
-mv binutils-$VERSION binutils-$VERSION-orig
-
-cp -rf ./binutils-$VERSION-new ./binutils-$VERSION
-
-diff --unified -Nr binutils-$VERSION-orig binutils-$VERSION > binutils-$VERSION-gold-i386-gnu-property-notes.patch
-
-mv binutils-$VERSION-gold-i386-gnu-property-notes.patch ../patches
-
-rm -rf ./binutils-$VERSION
-rm -rf ./binutils-$VERSION-orig
Property changes on: sources/GNU/binutils/create-2.43.1-gold-i386-gnu-property-notes-patch/create.patch.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: sources/GNU/binutils/create-2.43.1-gold-i386-gnu-property-notes-patch/binutils-2.43.1-new/gold/i386.cc
===================================================================
--- sources/GNU/binutils/create-2.43.1-gold-i386-gnu-property-notes-patch/binutils-2.43.1-new/gold/i386.cc (revision 75)
+++ sources/GNU/binutils/create-2.43.1-gold-i386-gnu-property-notes-patch/binutils-2.43.1-new/gold/i386.cc (nonexistent)
@@ -1,4621 +0,0 @@
-// i386.cc -- i386 target support for gold.
-
-// Copyright (C) 2006-2024 Free Software Foundation, Inc.
-// Written by Ian Lance Taylor <iant@google.com>.
-
-// This file is part of gold.
-
-// This program is free software; you can redistribute it and/or modify
-// it under the terms of the GNU General Public License as published by
-// the Free Software Foundation; either version 3 of the License, or
-// (at your option) any later version.
-
-// This program is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-
-// You should have received a copy of the GNU General Public License
-// along with this program; if not, write to the Free Software
-// Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston,
-// MA 02110-1301, USA.
-
-#include "gold.h"
-
-#include <cstring>
-
-#include "elfcpp.h"
-#include "dwarf.h"
-#include "parameters.h"
-#include "reloc.h"
-#include "i386.h"
-#include "object.h"
-#include "symtab.h"
-#include "layout.h"
-#include "output.h"
-#include "copy-relocs.h"
-#include "target.h"
-#include "target-reloc.h"
-#include "target-select.h"
-#include "tls.h"
-#include "freebsd.h"
-#include "nacl.h"
-#include "gc.h"
-
-namespace
-{
-
-using namespace gold;
-
-// A class to handle the .got.plt section.
-
-class Output_data_got_plt_i386 : public Output_section_data_build
-{
- public:
- Output_data_got_plt_i386(Layout* layout)
- : Output_section_data_build(4),
- layout_(layout)
- { }
-
- protected:
- // Write out the PLT data.
- void
- do_write(Output_file*);
-
- // Write to a map file.
- void
- do_print_to_mapfile(Mapfile* mapfile) const
- { mapfile->print_output_data(this, "** GOT PLT"); }
-
- private:
- // A pointer to the Layout class, so that we can find the .dynamic
- // section when we write out the GOT PLT section.
- Layout* layout_;
-};
-
-// A class to handle the PLT data.
-// This is an abstract base class that handles most of the linker details
-// but does not know the actual contents of PLT entries. The derived
-// classes below fill in those details.
-
-class Output_data_plt_i386 : public Output_section_data
-{
- public:
- typedef Output_data_reloc<elfcpp::SHT_REL, true, 32, false> Reloc_section;
-
- Output_data_plt_i386(Layout*, uint64_t addralign,
- Output_data_got_plt_i386*, Output_data_space*);
-
- // Add an entry to the PLT.
- void
- add_entry(Symbol_table*, Layout*, Symbol* gsym);
-
- // Add an entry to the PLT for a local STT_GNU_IFUNC symbol.
- unsigned int
- add_local_ifunc_entry(Symbol_table*, Layout*,
- Sized_relobj_file<32, false>* relobj,
- unsigned int local_sym_index);
-
- // Return the .rel.plt section data.
- Reloc_section*
- rel_plt() const
- { return this->rel_; }
-
- // Return where the TLS_DESC relocations should go.
- Reloc_section*
- rel_tls_desc(Layout*);
-
- // Return where the IRELATIVE relocations should go.
- Reloc_section*
- rel_irelative(Symbol_table*, Layout*);
-
- // Return whether we created a section for IRELATIVE relocations.
- bool
- has_irelative_section() const
- { return this->irelative_rel_ != NULL; }
-
- // Return the number of PLT entries.
- unsigned int
- entry_count() const
- { return this->count_ + this->irelative_count_; }
-
- // Return the offset of the first non-reserved PLT entry.
- unsigned int
- first_plt_entry_offset()
- { return this->get_plt_entry_size(); }
-
- // Return the size of a PLT entry.
- unsigned int
- get_plt_entry_size() const
- { return this->do_get_plt_entry_size(); }
-
- // Return the PLT address to use for a global symbol.
- uint64_t
- address_for_global(const Symbol*);
-
- // Return the PLT address to use for a local symbol.
- uint64_t
- address_for_local(const Relobj*, unsigned int symndx);
-
- // Add .eh_frame information for the PLT.
- void
- add_eh_frame(Layout* layout)
- { this->do_add_eh_frame(layout); }
-
- protected:
- // Fill the first PLT entry, given the pointer to the PLT section data
- // and the runtime address of the GOT.
- void
- fill_first_plt_entry(unsigned char* pov,
- elfcpp::Elf_types<32>::Elf_Addr got_address)
- { this->do_fill_first_plt_entry(pov, got_address); }
-
- // Fill a normal PLT entry, given the pointer to the entry's data in the
- // section, the runtime address of the GOT, the offset into the GOT of
- // the corresponding slot, the offset into the relocation section of the
- // corresponding reloc, and the offset of this entry within the whole
- // PLT. Return the offset from this PLT entry's runtime address that
- // should be used to compute the initial value of the GOT slot.
- unsigned int
- fill_plt_entry(unsigned char* pov,
- elfcpp::Elf_types<32>::Elf_Addr got_address,
- unsigned int got_offset,
- unsigned int plt_offset,
- unsigned int plt_rel_offset)
- {
- return this->do_fill_plt_entry(pov, got_address, got_offset,
- plt_offset, plt_rel_offset);
- }
-
- virtual unsigned int
- do_get_plt_entry_size() const = 0;
-
- virtual void
- do_fill_first_plt_entry(unsigned char* pov,
- elfcpp::Elf_types<32>::Elf_Addr got_address) = 0;
-
- virtual unsigned int
- do_fill_plt_entry(unsigned char* pov,
- elfcpp::Elf_types<32>::Elf_Addr got_address,
- unsigned int got_offset,
- unsigned int plt_offset,
- unsigned int plt_rel_offset) = 0;
-
- virtual void
- do_add_eh_frame(Layout*) = 0;
-
- void
- do_adjust_output_section(Output_section* os);
-
- // Write to a map file.
- void
- do_print_to_mapfile(Mapfile* mapfile) const
- { mapfile->print_output_data(this, _("** PLT")); }
-
- // The .eh_frame unwind information for the PLT.
- // The CIE is common across variants of the PLT format.
- static const int plt_eh_frame_cie_size = 16;
- static const unsigned char plt_eh_frame_cie[plt_eh_frame_cie_size];
-
- private:
- // Set the final size.
- void
- set_final_data_size()
- {
- this->set_data_size((this->count_ + this->irelative_count_ + 1)
- * this->get_plt_entry_size());
- }
-
- // Write out the PLT data.
- void
- do_write(Output_file*);
-
- // We keep a list of global STT_GNU_IFUNC symbols, each with its
- // offset in the GOT.
- struct Global_ifunc
- {
- Symbol* sym;
- unsigned int got_offset;
- };
-
- // We keep a list of local STT_GNU_IFUNC symbols, each with its
- // offset in the GOT.
- struct Local_ifunc
- {
- Sized_relobj_file<32, false>* object;
- unsigned int local_sym_index;
- unsigned int got_offset;
- };
-
- // The reloc section.
- Reloc_section* rel_;
- // The TLS_DESC relocations, if necessary. These must follow the
- // regular PLT relocs.
- Reloc_section* tls_desc_rel_;
- // The IRELATIVE relocations, if necessary. These must follow the
- // regular relocatoins and the TLS_DESC relocations.
- Reloc_section* irelative_rel_;
- // The .got.plt section.
- Output_data_got_plt_i386* got_plt_;
- // The part of the .got.plt section used for IRELATIVE relocs.
- Output_data_space* got_irelative_;
- // The number of PLT entries.
- unsigned int count_;
- // Number of PLT entries with R_386_IRELATIVE relocs. These follow
- // the regular PLT entries.
- unsigned int irelative_count_;
- // Global STT_GNU_IFUNC symbols.
- std::vector<Global_ifunc> global_ifuncs_;
- // Local STT_GNU_IFUNC symbols.
- std::vector<Local_ifunc> local_ifuncs_;
-};
-
-// This is an abstract class for the standard PLT layout.
-// The derived classes below handle the actual PLT contents
-// for the executable (non-PIC) and shared-library (PIC) cases.
-// The unwind information is uniform across those two, so it's here.
-
-class Output_data_plt_i386_standard : public Output_data_plt_i386
-{
- public:
- Output_data_plt_i386_standard(Layout* layout,
- Output_data_got_plt_i386* got_plt,
- Output_data_space* got_irelative)
- : Output_data_plt_i386(layout, plt_entry_size, got_plt, got_irelative)
- { }
-
- protected:
- virtual unsigned int
- do_get_plt_entry_size() const
- { return plt_entry_size; }
-
- virtual void
- do_add_eh_frame(Layout* layout)
- {
- layout->add_eh_frame_for_plt(this, plt_eh_frame_cie, plt_eh_frame_cie_size,
- plt_eh_frame_fde, plt_eh_frame_fde_size);
- }
-
- // The size of an entry in the PLT.
- static const int plt_entry_size = 16;
-
- // The .eh_frame unwind information for the PLT.
- static const int plt_eh_frame_fde_size = 32;
- static const unsigned char plt_eh_frame_fde[plt_eh_frame_fde_size];
-};
-
-// Actually fill the PLT contents for an executable (non-PIC).
-
-class Output_data_plt_i386_exec : public Output_data_plt_i386_standard
-{
-public:
- Output_data_plt_i386_exec(Layout* layout,
- Output_data_got_plt_i386* got_plt,
- Output_data_space* got_irelative)
- : Output_data_plt_i386_standard(layout, got_plt, got_irelative)
- { }
-
- protected:
- virtual void
- do_fill_first_plt_entry(unsigned char* pov,
- elfcpp::Elf_types<32>::Elf_Addr got_address);
-
- virtual unsigned int
- do_fill_plt_entry(unsigned char* pov,
- elfcpp::Elf_types<32>::Elf_Addr got_address,
- unsigned int got_offset,
- unsigned int plt_offset,
- unsigned int plt_rel_offset);
-
- private:
- // The first entry in the PLT for an executable.
- static const unsigned char first_plt_entry[plt_entry_size];
-
- // Other entries in the PLT for an executable.
- static const unsigned char plt_entry[plt_entry_size];
-};
-
-// Actually fill the PLT contents for a shared library (PIC).
-
-class Output_data_plt_i386_dyn : public Output_data_plt_i386_standard
-{
- public:
- Output_data_plt_i386_dyn(Layout* layout,
- Output_data_got_plt_i386* got_plt,
- Output_data_space* got_irelative)
- : Output_data_plt_i386_standard(layout, got_plt, got_irelative)
- { }
-
- protected:
- virtual void
- do_fill_first_plt_entry(unsigned char* pov, elfcpp::Elf_types<32>::Elf_Addr);
-
- virtual unsigned int
- do_fill_plt_entry(unsigned char* pov,
- elfcpp::Elf_types<32>::Elf_Addr,
- unsigned int got_offset,
- unsigned int plt_offset,
- unsigned int plt_rel_offset);
-
- private:
- // The first entry in the PLT for a shared object.
- static const unsigned char first_plt_entry[plt_entry_size];
-
- // Other entries in the PLT for a shared object.
- static const unsigned char plt_entry[plt_entry_size];
-};
-
-// The i386 target class.
-// TLS info comes from
-// http://people.redhat.com/drepper/tls.pdf
-// http://www.lsd.ic.unicamp.br/~oliva/writeups/TLS/RFC-TLSDESC-x86.txt
-
-class Target_i386 : public Sized_target<32, false>
-{
- public:
- typedef Output_data_reloc<elfcpp::SHT_REL, true, 32, false> Reloc_section;
-
- Target_i386(const Target::Target_info* info = &i386_info)
- : Sized_target<32, false>(info),
- got_(NULL), plt_(NULL), got_plt_(NULL), got_irelative_(NULL),
- got_tlsdesc_(NULL), global_offset_table_(NULL), rel_dyn_(NULL),
- rel_irelative_(NULL), copy_relocs_(elfcpp::R_386_COPY),
- got_mod_index_offset_(-1U), tls_base_symbol_defined_(false),
- isa_1_used_(0), isa_1_needed_(0),
- feature_1_(0), feature_2_used_(0), feature_2_needed_(0),
- object_isa_1_used_(0), object_feature_1_(0),
- object_feature_2_used_(0), seen_first_object_(false)
- { }
-
- // Process the relocations to determine unreferenced sections for
- // garbage collection.
- void
- gc_process_relocs(Symbol_table* symtab,
- Layout* layout,
- Sized_relobj_file<32, false>* object,
- unsigned int data_shndx,
- unsigned int sh_type,
- const unsigned char* prelocs,
- size_t reloc_count,
- Output_section* output_section,
- bool needs_special_offset_handling,
- size_t local_symbol_count,
- const unsigned char* plocal_symbols);
-
- // Scan the relocations to look for symbol adjustments.
- void
- scan_relocs(Symbol_table* symtab,
- Layout* layout,
- Sized_relobj_file<32, false>* object,
- unsigned int data_shndx,
- unsigned int sh_type,
- const unsigned char* prelocs,
- size_t reloc_count,
- Output_section* output_section,
- bool needs_special_offset_handling,
- size_t local_symbol_count,
- const unsigned char* plocal_symbols);
-
- // Finalize the sections.
- void
- do_finalize_sections(Layout*, const Input_objects*, Symbol_table*);
-
- // Return the value to use for a dynamic which requires special
- // treatment.
- uint64_t
- do_dynsym_value(const Symbol*) const;
-
- // Relocate a section.
- void
- relocate_section(const Relocate_info<32, false>*,
- unsigned int sh_type,
- const unsigned char* prelocs,
- size_t reloc_count,
- Output_section* output_section,
- bool needs_special_offset_handling,
- unsigned char* view,
- elfcpp::Elf_types<32>::Elf_Addr view_address,
- section_size_type view_size,
- const Reloc_symbol_changes*);
-
- // Scan the relocs during a relocatable link.
- void
- scan_relocatable_relocs(Symbol_table* symtab,
- Layout* layout,
- Sized_relobj_file<32, false>* object,
- unsigned int data_shndx,
- unsigned int sh_type,
- const unsigned char* prelocs,
- size_t reloc_count,
- Output_section* output_section,
- bool needs_special_offset_handling,
- size_t local_symbol_count,
- const unsigned char* plocal_symbols,
- Relocatable_relocs*);
-
- // Scan the relocs for --emit-relocs.
- void
- emit_relocs_scan(Symbol_table* symtab,
- Layout* layout,
- Sized_relobj_file<32, false>* object,
- unsigned int data_shndx,
- unsigned int sh_type,
- const unsigned char* prelocs,
- size_t reloc_count,
- Output_section* output_section,
- bool needs_special_offset_handling,
- size_t local_symbol_count,
- const unsigned char* plocal_syms,
- Relocatable_relocs* rr);
-
- // Emit relocations for a section.
- void
- relocate_relocs(const Relocate_info<32, false>*,
- unsigned int sh_type,
- const unsigned char* prelocs,
- size_t reloc_count,
- Output_section* output_section,
- elfcpp::Elf_types<32>::Elf_Off offset_in_output_section,
- unsigned char* view,
- elfcpp::Elf_types<32>::Elf_Addr view_address,
- section_size_type view_size,
- unsigned char* reloc_view,
- section_size_type reloc_view_size);
-
- // Return a string used to fill a code section with nops.
- std::string
- do_code_fill(section_size_type length) const;
-
- // Return whether SYM is defined by the ABI.
- bool
- do_is_defined_by_abi(const Symbol* sym) const
- { return strcmp(sym->name(), "___tls_get_addr") == 0; }
-
- // Return whether a symbol name implies a local label. The UnixWare
- // 2.1 cc generates temporary symbols that start with .X, so we
- // recognize them here. FIXME: do other SVR4 compilers also use .X?.
- // If so, we should move the .X recognition into
- // Target::do_is_local_label_name.
- bool
- do_is_local_label_name(const char* name) const
- {
- if (name[0] == '.' && name[1] == 'X')
- return true;
- return Target::do_is_local_label_name(name);
- }
-
- // Return the PLT address to use for a global symbol.
- uint64_t
- do_plt_address_for_global(const Symbol* gsym) const
- { return this->plt_section()->address_for_global(gsym); }
-
- uint64_t
- do_plt_address_for_local(const Relobj* relobj, unsigned int symndx) const
- { return this->plt_section()->address_for_local(relobj, symndx); }
-
- // We can tell whether we take the address of a function.
- inline bool
- do_can_check_for_function_pointers() const
- { return true; }
-
- // Return the base for a DW_EH_PE_datarel encoding.
- uint64_t
- do_ehframe_datarel_base() const;
-
- // Return whether SYM is call to a non-split function.
- bool
- do_is_call_to_non_split(const Symbol* sym, const unsigned char*,
- const unsigned char*, section_size_type) const;
-
- // Adjust -fsplit-stack code which calls non-split-stack code.
- void
- do_calls_non_split(Relobj* object, unsigned int shndx,
- section_offset_type fnoffset, section_size_type fnsize,
- const unsigned char* prelocs, size_t reloc_count,
- unsigned char* view, section_size_type view_size,
- std::string* from, std::string* to) const;
-
- // Return the size of the GOT section.
- section_size_type
- got_size() const
- {
- gold_assert(this->got_ != NULL);
- return this->got_->data_size();
- }
-
- // Return the number of entries in the GOT.
- unsigned int
- got_entry_count() const
- {
- if (this->got_ == NULL)
- return 0;
- return this->got_size() / 4;
- }
-
- // Return the number of entries in the PLT.
- unsigned int
- plt_entry_count() const;
-
- // Return the offset of the first non-reserved PLT entry.
- unsigned int
- first_plt_entry_offset() const;
-
- // Return the size of each PLT entry.
- unsigned int
- plt_entry_size() const;
-
- protected:
- // Instantiate the plt_ member.
- // This chooses the right PLT flavor for an executable or a shared object.
- Output_data_plt_i386*
- make_data_plt(Layout* layout,
- Output_data_got_plt_i386* got_plt,
- Output_data_space* got_irelative,
- bool dyn)
- { return this->do_make_data_plt(layout, got_plt, got_irelative, dyn); }
-
- virtual Output_data_plt_i386*
- do_make_data_plt(Layout* layout,
- Output_data_got_plt_i386* got_plt,
- Output_data_space* got_irelative,
- bool dyn)
- {
- if (dyn)
- return new Output_data_plt_i386_dyn(layout, got_plt, got_irelative);
- else
- return new Output_data_plt_i386_exec(layout, got_plt, got_irelative);
- }
-
- private:
- // The class which scans relocations.
- struct Scan
- {
- static inline int
-
- get_reference_flags(unsigned int r_type);
-
- inline void
- local(Symbol_table* symtab, Layout* layout, Target_i386* target,
- Sized_relobj_file<32, false>* object,
- unsigned int data_shndx,
- Output_section* output_section,
- const elfcpp::Rel<32, false>& reloc, unsigned int r_type,
- const elfcpp::Sym<32, false>& lsym,
- bool is_discarded);
-
- inline void
- global(Symbol_table* symtab, Layout* layout, Target_i386* target,
- Sized_relobj_file<32, false>* object,
- unsigned int data_shndx,
- Output_section* output_section,
- const elfcpp::Rel<32, false>& reloc, unsigned int r_type,
- Symbol* gsym);
-
- inline bool
- local_reloc_may_be_function_pointer(Symbol_table* symtab, Layout* layout,
- Target_i386* target,
- Sized_relobj_file<32, false>* object,
- unsigned int data_shndx,
- Output_section* output_section,
- const elfcpp::Rel<32, false>& reloc,
- unsigned int r_type,
- const elfcpp::Sym<32, false>& lsym);
-
- inline bool
- global_reloc_may_be_function_pointer(Symbol_table* symtab, Layout* layout,
- Target_i386* target,
- Sized_relobj_file<32, false>* object,
- unsigned int data_shndx,
- Output_section* output_section,
- const elfcpp::Rel<32, false>& reloc,
- unsigned int r_type,
- Symbol* gsym);
-
- inline bool
- possible_function_pointer_reloc(unsigned int r_type);
-
- bool
- reloc_needs_plt_for_ifunc(Sized_relobj_file<32, false>*,
- unsigned int r_type);
-
- static void
- unsupported_reloc_local(Sized_relobj_file<32, false>*, unsigned int r_type);
-
- static void
- unsupported_reloc_global(Sized_relobj_file<32, false>*, unsigned int r_type,
- Symbol*);
- };
-
- // The class which implements relocation.
- class Relocate
- {
- public:
- Relocate()
- : skip_call_tls_get_addr_(false),
- local_dynamic_type_(LOCAL_DYNAMIC_NONE)
- { }
-
- ~Relocate()
- {
- if (this->skip_call_tls_get_addr_)
- {
- // FIXME: This needs to specify the location somehow.
- gold_error(_("missing expected TLS relocation"));
- }
- }
-
- // Return whether the static relocation needs to be applied.
- inline bool
- should_apply_static_reloc(const Sized_symbol<32>* gsym,
- unsigned int r_type,
- bool is_32bit,
- Output_section* output_section);
-
- // Do a relocation. Return false if the caller should not issue
- // any warnings about this relocation.
- inline bool
- relocate(const Relocate_info<32, false>*, unsigned int,
- Target_i386*, Output_section*, size_t, const unsigned char*,
- const Sized_symbol<32>*, const Symbol_value<32>*,
- unsigned char*, elfcpp::Elf_types<32>::Elf_Addr,
- section_size_type);
-
- private:
- // Do a TLS relocation.
- inline void
- relocate_tls(const Relocate_info<32, false>*, Target_i386* target,
- size_t relnum, const elfcpp::Rel<32, false>&,
- unsigned int r_type, const Sized_symbol<32>*,
- const Symbol_value<32>*,
- unsigned char*, elfcpp::Elf_types<32>::Elf_Addr,
- section_size_type);
-
- // Do a TLS General-Dynamic to Initial-Exec transition.
- inline void
- tls_gd_to_ie(const Relocate_info<32, false>*, size_t relnum,
- const elfcpp::Rel<32, false>&, unsigned int r_type,
- elfcpp::Elf_types<32>::Elf_Addr value,
- unsigned char* view,
- section_size_type view_size);
-
- // Do a TLS General-Dynamic to Local-Exec transition.
- inline void
- tls_gd_to_le(const Relocate_info<32, false>*, size_t relnum,
- Output_segment* tls_segment,
- const elfcpp::Rel<32, false>&, unsigned int r_type,
- elfcpp::Elf_types<32>::Elf_Addr value,
- unsigned char* view,
- section_size_type view_size);
-
- // Do a TLS_GOTDESC or TLS_DESC_CALL General-Dynamic to Initial-Exec
- // transition.
- inline void
- tls_desc_gd_to_ie(const Relocate_info<32, false>*, size_t relnum,
- const elfcpp::Rel<32, false>&, unsigned int r_type,
- elfcpp::Elf_types<32>::Elf_Addr value,
- unsigned char* view,
- section_size_type view_size);
-
- // Do a TLS_GOTDESC or TLS_DESC_CALL General-Dynamic to Local-Exec
- // transition.
- inline void
- tls_desc_gd_to_le(const Relocate_info<32, false>*, size_t relnum,
- Output_segment* tls_segment,
- const elfcpp::Rel<32, false>&, unsigned int r_type,
- elfcpp::Elf_types<32>::Elf_Addr value,
- unsigned char* view,
- section_size_type view_size);
-
- // Do a TLS Local-Dynamic to Local-Exec transition.
- inline void
- tls_ld_to_le(const Relocate_info<32, false>*, size_t relnum,
- Output_segment* tls_segment,
- const elfcpp::Rel<32, false>&, unsigned int r_type,
- elfcpp::Elf_types<32>::Elf_Addr value,
- unsigned char* view,
- section_size_type view_size);
-
- // Do a TLS Initial-Exec to Local-Exec transition.
- static inline void
- tls_ie_to_le(const Relocate_info<32, false>*, size_t relnum,
- Output_segment* tls_segment,
- const elfcpp::Rel<32, false>&, unsigned int r_type,
- elfcpp::Elf_types<32>::Elf_Addr value,
- unsigned char* view,
- section_size_type view_size);
-
- // We need to keep track of which type of local dynamic relocation
- // we have seen, so that we can optimize R_386_TLS_LDO_32 correctly.
- enum Local_dynamic_type
- {
- LOCAL_DYNAMIC_NONE,
- LOCAL_DYNAMIC_SUN,
- LOCAL_DYNAMIC_GNU
- };
-
- // This is set if we should skip the next reloc, which should be a
- // PLT32 reloc against ___tls_get_addr.
- bool skip_call_tls_get_addr_;
- // The type of local dynamic relocation we have seen in the section
- // being relocated, if any.
- Local_dynamic_type local_dynamic_type_;
- };
-
- // A class for inquiring about properties of a relocation,
- // used while scanning relocs during a relocatable link and
- // garbage collection.
- class Classify_reloc :
- public gold::Default_classify_reloc<elfcpp::SHT_REL, 32, false>
- {
- public:
- typedef Reloc_types<elfcpp::SHT_REL, 32, false>::Reloc Reltype;
-
- // Return the explicit addend of the relocation (return 0 for SHT_REL).
- static elfcpp::Elf_types<32>::Elf_Swxword
- get_r_addend(const Reltype*)
- { return 0; }
-
- // Return the size of the addend of the relocation (only used for SHT_REL).
- static unsigned int
- get_size_for_reloc(unsigned int, Relobj*);
- };
-
- // Adjust TLS relocation type based on the options and whether this
- // is a local symbol.
- static tls::Tls_optimization
- optimize_tls_reloc(bool is_final, int r_type);
-
- // Check if relocation against this symbol is a candidate for
- // conversion from
- // mov foo@GOT(%reg), %reg
- // to
- // lea foo@GOTOFF(%reg), %reg.
- static bool
- can_convert_mov_to_lea(const Symbol* gsym)
- {
- gold_assert(gsym != NULL);
- return (gsym->type() != elfcpp::STT_GNU_IFUNC
- && !gsym->is_undefined ()
- && !gsym->is_from_dynobj()
- && !gsym->is_preemptible()
- && (!parameters->options().shared()
- || (gsym->visibility() != elfcpp::STV_DEFAULT
- && gsym->visibility() != elfcpp::STV_PROTECTED)
- || parameters->options().Bsymbolic())
- && strcmp(gsym->name(), "_DYNAMIC") != 0);
- }
-
- // Get the GOT section, creating it if necessary.
- Output_data_got<32, false>*
- got_section(Symbol_table*, Layout*);
-
- // Get the GOT PLT section.
- Output_data_got_plt_i386*
- got_plt_section() const
- {
- gold_assert(this->got_plt_ != NULL);
- return this->got_plt_;
- }
-
- // Get the GOT section for TLSDESC entries.
- Output_data_got<32, false>*
- got_tlsdesc_section() const
- {
- gold_assert(this->got_tlsdesc_ != NULL);
- return this->got_tlsdesc_;
- }
-
- // Create the PLT section.
- void
- make_plt_section(Symbol_table* symtab, Layout* layout);
-
- // Create a PLT entry for a global symbol.
- void
- make_plt_entry(Symbol_table*, Layout*, Symbol*);
-
- // Create a PLT entry for a local STT_GNU_IFUNC symbol.
- void
- make_local_ifunc_plt_entry(Symbol_table*, Layout*,
- Sized_relobj_file<32, false>* relobj,
- unsigned int local_sym_index);
-
- // Define the _TLS_MODULE_BASE_ symbol in the TLS segment.
- void
- define_tls_base_symbol(Symbol_table*, Layout*);
-
- // Create a GOT entry for the TLS module index.
- unsigned int
- got_mod_index_entry(Symbol_table* symtab, Layout* layout,
- Sized_relobj_file<32, false>* object);
-
- // Get the PLT section.
- Output_data_plt_i386*
- plt_section() const
- {
- gold_assert(this->plt_ != NULL);
- return this->plt_;
- }
-
- // Get the dynamic reloc section, creating it if necessary.
- Reloc_section*
- rel_dyn_section(Layout*);
-
- // Get the section to use for TLS_DESC relocations.
- Reloc_section*
- rel_tls_desc_section(Layout*) const;
-
- // Get the section to use for IRELATIVE relocations.
- Reloc_section*
- rel_irelative_section(Layout*);
-
- // Add a potential copy relocation.
- void
- copy_reloc(Symbol_table* symtab, Layout* layout,
- Sized_relobj_file<32, false>* object,
- unsigned int shndx, Output_section* output_section,
- Symbol* sym, const elfcpp::Rel<32, false>& reloc)
- {
- unsigned int r_type = elfcpp::elf_r_type<32>(reloc.get_r_info());
- this->copy_relocs_.copy_reloc(symtab, layout,
- symtab->get_sized_symbol<32>(sym),
- object, shndx, output_section,
- r_type, reloc.get_r_offset(), 0,
- this->rel_dyn_section(layout));
- }
-
- // Record a target-specific program property in the .note.gnu.property
- // section.
- void
- record_gnu_property(unsigned int, unsigned int, size_t,
- const unsigned char*, const Object*);
-
- // Merge the target-specific program properties from the current object.
- void
- merge_gnu_properties(const Object*);
-
- // Finalize the target-specific program properties and add them back to
- // the layout.
- void
- do_finalize_gnu_properties(Layout*) const;
-
- // Information about this specific target which we pass to the
- // general Target structure.
- static const Target::Target_info i386_info;
-
- // The types of GOT entries needed for this platform.
- // These values are exposed to the ABI in an incremental link.
- // Do not renumber existing values without changing the version
- // number of the .gnu_incremental_inputs section.
- enum Got_type
- {
- GOT_TYPE_STANDARD = 0, // GOT entry for a regular symbol
- GOT_TYPE_TLS_NOFFSET = 1, // GOT entry for negative TLS offset
- GOT_TYPE_TLS_OFFSET = 2, // GOT entry for positive TLS offset
- GOT_TYPE_TLS_PAIR = 3, // GOT entry for TLS module/offset pair
- GOT_TYPE_TLS_DESC = 4 // GOT entry for TLS_DESC pair
- };
-
- // The GOT section.
- Output_data_got<32, false>* got_;
- // The PLT section.
- Output_data_plt_i386* plt_;
- // The GOT PLT section.
- Output_data_got_plt_i386* got_plt_;
- // The GOT section for IRELATIVE relocations.
- Output_data_space* got_irelative_;
- // The GOT section for TLSDESC relocations.
- Output_data_got<32, false>* got_tlsdesc_;
- // The _GLOBAL_OFFSET_TABLE_ symbol.
- Symbol* global_offset_table_;
- // The dynamic reloc section.
- Reloc_section* rel_dyn_;
- // The section to use for IRELATIVE relocs.
- Reloc_section* rel_irelative_;
- // Relocs saved to avoid a COPY reloc.
- Copy_relocs<elfcpp::SHT_REL, 32, false> copy_relocs_;
- // Offset of the GOT entry for the TLS module index.
- unsigned int got_mod_index_offset_;
- // True if the _TLS_MODULE_BASE_ symbol has been defined.
- bool tls_base_symbol_defined_;
-
- // Target-specific program properties, from .note.gnu.property section.
- // Each bit represents a specific feature.
- uint32_t isa_1_used_;
- uint32_t isa_1_needed_;
- uint32_t feature_1_;
- uint32_t feature_2_used_;
- uint32_t feature_2_needed_;
- // Target-specific properties from the current object.
- // These bits get ORed into ISA_1_USED_ after all properties for the object
- // have been processed. But if either is all zeroes (as when the property
- // is absent from an object), the result should be all zeroes.
- // (See PR ld/23486.)
- uint32_t object_isa_1_used_;
- // These bits get ANDed into FEATURE_1_ after all properties for the object
- // have been processed.
- uint32_t object_feature_1_;
- uint32_t object_feature_2_used_;
- // Whether we have seen our first object, for use in initializing FEATURE_1_.
- bool seen_first_object_;
-};
-
-const Target::Target_info Target_i386::i386_info =
-{
- 32, // size
- false, // is_big_endian
- elfcpp::EM_386, // machine_code
- false, // has_make_symbol
- false, // has_resolve
- true, // has_code_fill
- true, // is_default_stack_executable
- true, // can_icf_inline_merge_sections
- '\0', // wrap_char
- "/usr/lib/libc.so.1", // dynamic_linker
- 0x08048000, // default_text_segment_address
- 0x1000, // abi_pagesize (overridable by -z max-page-size)
- 0x1000, // common_pagesize (overridable by -z common-page-size)
- false, // isolate_execinstr
- 0, // rosegment_gap
- elfcpp::SHN_UNDEF, // small_common_shndx
- elfcpp::SHN_UNDEF, // large_common_shndx
- 0, // small_common_section_flags
- 0, // large_common_section_flags
- NULL, // attributes_section
- NULL, // attributes_vendor
- "_start", // entry_symbol_name
- 32, // hash_entry_size
- elfcpp::SHT_PROGBITS, // unwind_section_type
-};
-
-// Get the GOT section, creating it if necessary.
-
-Output_data_got<32, false>*
-Target_i386::got_section(Symbol_table* symtab, Layout* layout)
-{
- if (this->got_ == NULL)
- {
- gold_assert(symtab != NULL && layout != NULL);
-
- this->got_ = new Output_data_got<32, false>();
-
- // When using -z now, we can treat .got.plt as a relro section.
- // Without -z now, it is modified after program startup by lazy
- // PLT relocations.
- bool is_got_plt_relro = parameters->options().now();
- Output_section_order got_order = (is_got_plt_relro
- ? ORDER_RELRO
- : ORDER_RELRO_LAST);
- Output_section_order got_plt_order = (is_got_plt_relro
- ? ORDER_RELRO
- : ORDER_NON_RELRO_FIRST);
-
- layout->add_output_section_data(".got", elfcpp::SHT_PROGBITS,
- (elfcpp::SHF_ALLOC
- | elfcpp::SHF_WRITE),
- this->got_, got_order, true);
-
- this->got_plt_ = new Output_data_got_plt_i386(layout);
- layout->add_output_section_data(".got.plt", elfcpp::SHT_PROGBITS,
- (elfcpp::SHF_ALLOC
- | elfcpp::SHF_WRITE),
- this->got_plt_, got_plt_order,
- is_got_plt_relro);
-
- // The first three entries are reserved.
- this->got_plt_->set_current_data_size(3 * 4);
-
- if (!is_got_plt_relro)
- {
- // Those bytes can go into the relro segment.
- layout->increase_relro(3 * 4);
- }
-
- // Define _GLOBAL_OFFSET_TABLE_ at the start of the PLT.
- this->global_offset_table_ =
- symtab->define_in_output_data("_GLOBAL_OFFSET_TABLE_", NULL,
- Symbol_table::PREDEFINED,
- this->got_plt_,
- 0, 0, elfcpp::STT_OBJECT,
- elfcpp::STB_LOCAL,
- elfcpp::STV_HIDDEN, 0,
- false, false);
-
- // If there are any IRELATIVE relocations, they get GOT entries
- // in .got.plt after the jump slot relocations.
- this->got_irelative_ = new Output_data_space(4, "** GOT IRELATIVE PLT");
- layout->add_output_section_data(".got.plt", elfcpp::SHT_PROGBITS,
- (elfcpp::SHF_ALLOC
- | elfcpp::SHF_WRITE),
- this->got_irelative_,
- got_plt_order, is_got_plt_relro);
-
- // If there are any TLSDESC relocations, they get GOT entries in
- // .got.plt after the jump slot entries.
- this->got_tlsdesc_ = new Output_data_got<32, false>();
- layout->add_output_section_data(".got.plt", elfcpp::SHT_PROGBITS,
- (elfcpp::SHF_ALLOC
- | elfcpp::SHF_WRITE),
- this->got_tlsdesc_,
- got_plt_order, is_got_plt_relro);
- }
-
- return this->got_;
-}
-
-// Get the dynamic reloc section, creating it if necessary.
-
-Target_i386::Reloc_section*
-Target_i386::rel_dyn_section(Layout* layout)
-{
- if (this->rel_dyn_ == NULL)
- {
- gold_assert(layout != NULL);
- this->rel_dyn_ = new Reloc_section(parameters->options().combreloc());
- layout->add_output_section_data(".rel.dyn", elfcpp::SHT_REL,
- elfcpp::SHF_ALLOC, this->rel_dyn_,
- ORDER_DYNAMIC_RELOCS, false);
- }
- return this->rel_dyn_;
-}
-
-// Get the section to use for IRELATIVE relocs, creating it if
-// necessary. These go in .rel.dyn, but only after all other dynamic
-// relocations. They need to follow the other dynamic relocations so
-// that they can refer to global variables initialized by those
-// relocs.
-
-Target_i386::Reloc_section*
-Target_i386::rel_irelative_section(Layout* layout)
-{
- if (this->rel_irelative_ == NULL)
- {
- // Make sure we have already create the dynamic reloc section.
- this->rel_dyn_section(layout);
- this->rel_irelative_ = new Reloc_section(false);
- layout->add_output_section_data(".rel.dyn", elfcpp::SHT_REL,
- elfcpp::SHF_ALLOC, this->rel_irelative_,
- ORDER_DYNAMIC_RELOCS, false);
- gold_assert(this->rel_dyn_->output_section()
- == this->rel_irelative_->output_section());
- }
- return this->rel_irelative_;
-}
-
-// Record a target-specific program property from the .note.gnu.property
-// section.
-void
-Target_i386::record_gnu_property(
- unsigned int, unsigned int pr_type,
- size_t pr_datasz, const unsigned char* pr_data,
- const Object* object)
-{
- uint32_t val = 0;
-
- switch (pr_type)
- {
- case elfcpp::GNU_PROPERTY_X86_COMPAT_ISA_1_USED:
- case elfcpp::GNU_PROPERTY_X86_COMPAT_ISA_1_NEEDED:
- case elfcpp::GNU_PROPERTY_X86_COMPAT_2_ISA_1_USED:
- case elfcpp::GNU_PROPERTY_X86_COMPAT_2_ISA_1_NEEDED:
- case elfcpp::GNU_PROPERTY_X86_ISA_1_USED:
- case elfcpp::GNU_PROPERTY_X86_ISA_1_NEEDED:
- case elfcpp::GNU_PROPERTY_X86_FEATURE_1_AND:
- case elfcpp::GNU_PROPERTY_X86_FEATURE_2_USED:
- case elfcpp::GNU_PROPERTY_X86_FEATURE_2_NEEDED:
- if (pr_datasz != 4)
- {
- gold_warning(_("%s: corrupt .note.gnu.property section "
- "(pr_datasz for property %d is not 4)"),
- object->name().c_str(), pr_type);
- return;
- }
- val = elfcpp::Swap<32, false>::readval(pr_data);
- break;
- default:
- gold_warning(_("%s: unknown program property type 0x%x "
- "in .note.gnu.property section"),
- object->name().c_str(), pr_type);
- break;
- }
-
- switch (pr_type)
- {
- case elfcpp::GNU_PROPERTY_X86_ISA_1_USED:
- this->object_isa_1_used_ |= val;
- break;
- case elfcpp::GNU_PROPERTY_X86_ISA_1_NEEDED:
- this->isa_1_needed_ |= val;
- break;
- case elfcpp::GNU_PROPERTY_X86_FEATURE_1_AND:
- // If we see multiple feature props in one object, OR them together.
- this->object_feature_1_ |= val;
- break;
- case elfcpp::GNU_PROPERTY_X86_FEATURE_2_USED:
- this->object_feature_2_used_ |= val;
- break;
- case elfcpp::GNU_PROPERTY_X86_FEATURE_2_NEEDED:
- this->feature_2_needed_ |= val;
- break;
- }
-}
-
-// Merge the target-specific program properties from the current object.
-void
-Target_i386::merge_gnu_properties(const Object*)
-{
- if (this->seen_first_object_)
- {
- // If any object is missing the ISA_1_USED property, we must omit
- // it from the output file.
- if (this->object_isa_1_used_ == 0)
- this->isa_1_used_ = 0;
- else if (this->isa_1_used_ != 0)
- this->isa_1_used_ |= this->object_isa_1_used_;
- this->feature_1_ &= this->object_feature_1_;
- // If any object is missing the FEATURE_2_USED property, we must
- // omit it from the output file.
- if (this->object_feature_2_used_ == 0)
- this->feature_2_used_ = 0;
- else if (this->feature_2_used_ != 0)
- this->feature_2_used_ |= this->object_feature_2_used_;
- }
- else
- {
- this->isa_1_used_ = this->object_isa_1_used_;
- this->feature_1_ = this->object_feature_1_;
- this->feature_2_used_ = this->object_feature_2_used_;
- this->seen_first_object_ = true;
- }
- this->object_isa_1_used_ = 0;
- this->object_feature_1_ = 0;
- this->object_feature_2_used_ = 0;
-}
-
-static inline void
-add_property(Layout* layout, unsigned int pr_type, uint32_t val)
-{
- unsigned char buf[4];
- elfcpp::Swap<32, false>::writeval(buf, val);
- layout->add_gnu_property(elfcpp::NT_GNU_PROPERTY_TYPE_0, pr_type, 4, buf);
-}
-
-// Finalize the target-specific program properties and add them back to
-// the layout.
-void
-Target_i386::do_finalize_gnu_properties(Layout* layout) const
-{
- if (this->isa_1_used_ != 0)
- add_property(layout, elfcpp::GNU_PROPERTY_X86_ISA_1_USED,
- this->isa_1_used_);
- if (this->isa_1_needed_ != 0)
- add_property(layout, elfcpp::GNU_PROPERTY_X86_ISA_1_NEEDED,
- this->isa_1_needed_);
- if (this->feature_1_ != 0)
- add_property(layout, elfcpp::GNU_PROPERTY_X86_FEATURE_1_AND,
- this->feature_1_);
- if (this->feature_2_used_ != 0)
- add_property(layout, elfcpp::GNU_PROPERTY_X86_FEATURE_2_USED,
- this->feature_2_used_);
- if (this->feature_2_needed_ != 0)
- add_property(layout, elfcpp::GNU_PROPERTY_X86_FEATURE_2_NEEDED,
- this->feature_2_needed_);
-}
-
-// Write the first three reserved words of the .got.plt section.
-// The remainder of the section is written while writing the PLT
-// in Output_data_plt_i386::do_write.
-
-void
-Output_data_got_plt_i386::do_write(Output_file* of)
-{
- // The first entry in the GOT is the address of the .dynamic section
- // aka the PT_DYNAMIC segment. The next two entries are reserved.
- // We saved space for them when we created the section in
- // Target_i386::got_section.
- const off_t got_file_offset = this->offset();
- gold_assert(this->data_size() >= 12);
- unsigned char* const got_view = of->get_output_view(got_file_offset, 12);
- Output_section* dynamic = this->layout_->dynamic_section();
- uint32_t dynamic_addr = dynamic == NULL ? 0 : dynamic->address();
- elfcpp::Swap<32, false>::writeval(got_view, dynamic_addr);
- memset(got_view + 4, 0, 8);
- of->write_output_view(got_file_offset, 12, got_view);
-}
-
-// Create the PLT section. The ordinary .got section is an argument,
-// since we need to refer to the start. We also create our own .got
-// section just for PLT entries.
-
-Output_data_plt_i386::Output_data_plt_i386(Layout* layout,
- uint64_t addralign,
- Output_data_got_plt_i386* got_plt,
- Output_data_space* got_irelative)
- : Output_section_data(addralign),
- tls_desc_rel_(NULL), irelative_rel_(NULL), got_plt_(got_plt),
- got_irelative_(got_irelative), count_(0), irelative_count_(0),
- global_ifuncs_(), local_ifuncs_()
-{
- this->rel_ = new Reloc_section(false);
- layout->add_output_section_data(".rel.plt", elfcpp::SHT_REL,
- elfcpp::SHF_ALLOC, this->rel_,
- ORDER_DYNAMIC_PLT_RELOCS, false);
-}
-
-void
-Output_data_plt_i386::do_adjust_output_section(Output_section* os)
-{
- // UnixWare sets the entsize of .plt to 4, and so does the old GNU
- // linker, and so do we.
- os->set_entsize(4);
-}
-
-// Add an entry to the PLT.
-
-void
-Output_data_plt_i386::add_entry(Symbol_table* symtab, Layout* layout,
- Symbol* gsym)
-{
- gold_assert(!gsym->has_plt_offset());
-
- // Every PLT entry needs a reloc.
- if (gsym->type() == elfcpp::STT_GNU_IFUNC
- && gsym->can_use_relative_reloc(false))
- {
- gsym->set_plt_offset(this->irelative_count_ * this->get_plt_entry_size());
- ++this->irelative_count_;
- section_offset_type got_offset =
- this->got_irelative_->current_data_size();
- this->got_irelative_->set_current_data_size(got_offset + 4);
- Reloc_section* rel = this->rel_irelative(symtab, layout);
- rel->add_symbolless_global_addend(gsym, elfcpp::R_386_IRELATIVE,
- this->got_irelative_, got_offset);
- struct Global_ifunc gi;
- gi.sym = gsym;
- gi.got_offset = got_offset;
- this->global_ifuncs_.push_back(gi);
- }
- else
- {
- // When setting the PLT offset we skip the initial reserved PLT
- // entry.
- gsym->set_plt_offset((this->count_ + 1) * this->get_plt_entry_size());
-
- ++this->count_;
-
- section_offset_type got_offset = this->got_plt_->current_data_size();
-
- // Every PLT entry needs a GOT entry which points back to the
- // PLT entry (this will be changed by the dynamic linker,
- // normally lazily when the function is called).
- this->got_plt_->set_current_data_size(got_offset + 4);
-
- gsym->set_needs_dynsym_entry();
- this->rel_->add_global(gsym, elfcpp::R_386_JUMP_SLOT, this->got_plt_,
- got_offset);
- }
-
- // Note that we don't need to save the symbol. The contents of the
- // PLT are independent of which symbols are used. The symbols only
- // appear in the relocations.
-}
-
-// Add an entry to the PLT for a local STT_GNU_IFUNC symbol. Return
-// the PLT offset.
-
-unsigned int
-Output_data_plt_i386::add_local_ifunc_entry(
- Symbol_table* symtab,
- Layout* layout,
- Sized_relobj_file<32, false>* relobj,
- unsigned int local_sym_index)
-{
- unsigned int plt_offset = this->irelative_count_ * this->get_plt_entry_size();
- ++this->irelative_count_;
-
- section_offset_type got_offset = this->got_irelative_->current_data_size();
-
- // Every PLT entry needs a GOT entry which points back to the PLT
- // entry.
- this->got_irelative_->set_current_data_size(got_offset + 4);
-
- // Every PLT entry needs a reloc.
- Reloc_section* rel = this->rel_irelative(symtab, layout);
- rel->add_symbolless_local_addend(relobj, local_sym_index,
- elfcpp::R_386_IRELATIVE,
- this->got_irelative_, got_offset);
-
- struct Local_ifunc li;
- li.object = relobj;
- li.local_sym_index = local_sym_index;
- li.got_offset = got_offset;
- this->local_ifuncs_.push_back(li);
-
- return plt_offset;
-}
-
-// Return where the TLS_DESC relocations should go, creating it if
-// necessary. These follow the JUMP_SLOT relocations.
-
-Output_data_plt_i386::Reloc_section*
-Output_data_plt_i386::rel_tls_desc(Layout* layout)
-{
- if (this->tls_desc_rel_ == NULL)
- {
- this->tls_desc_rel_ = new Reloc_section(false);
- layout->add_output_section_data(".rel.plt", elfcpp::SHT_REL,
- elfcpp::SHF_ALLOC, this->tls_desc_rel_,
- ORDER_DYNAMIC_PLT_RELOCS, false);
- gold_assert(this->tls_desc_rel_->output_section()
- == this->rel_->output_section());
- }
- return this->tls_desc_rel_;
-}
-
-// Return where the IRELATIVE relocations should go in the PLT. These
-// follow the JUMP_SLOT and TLS_DESC relocations.
-
-Output_data_plt_i386::Reloc_section*
-Output_data_plt_i386::rel_irelative(Symbol_table* symtab, Layout* layout)
-{
- if (this->irelative_rel_ == NULL)
- {
- // Make sure we have a place for the TLS_DESC relocations, in
- // case we see any later on.
- this->rel_tls_desc(layout);
- this->irelative_rel_ = new Reloc_section(false);
- layout->add_output_section_data(".rel.plt", elfcpp::SHT_REL,
- elfcpp::SHF_ALLOC, this->irelative_rel_,
- ORDER_DYNAMIC_PLT_RELOCS, false);
- gold_assert(this->irelative_rel_->output_section()
- == this->rel_->output_section());
-
- if (parameters->doing_static_link())
- {
- // A statically linked executable will only have a .rel.plt
- // section to hold R_386_IRELATIVE relocs for STT_GNU_IFUNC
- // symbols. The library will use these symbols to locate
- // the IRELATIVE relocs at program startup time.
- symtab->define_in_output_data("__rel_iplt_start", NULL,
- Symbol_table::PREDEFINED,
- this->irelative_rel_, 0, 0,
- elfcpp::STT_NOTYPE, elfcpp::STB_GLOBAL,
- elfcpp::STV_HIDDEN, 0, false, true);
- symtab->define_in_output_data("__rel_iplt_end", NULL,
- Symbol_table::PREDEFINED,
- this->irelative_rel_, 0, 0,
- elfcpp::STT_NOTYPE, elfcpp::STB_GLOBAL,
- elfcpp::STV_HIDDEN, 0, true, true);
- }
- }
- return this->irelative_rel_;
-}
-
-// Return the PLT address to use for a global symbol.
-
-uint64_t
-Output_data_plt_i386::address_for_global(const Symbol* gsym)
-{
- uint64_t offset = 0;
- if (gsym->type() == elfcpp::STT_GNU_IFUNC
- && gsym->can_use_relative_reloc(false))
- offset = (this->count_ + 1) * this->get_plt_entry_size();
- return this->address() + offset + gsym->plt_offset();
-}
-
-// Return the PLT address to use for a local symbol. These are always
-// IRELATIVE relocs.
-
-uint64_t
-Output_data_plt_i386::address_for_local(const Relobj* object,
- unsigned int r_sym)
-{
- return (this->address()
- + (this->count_ + 1) * this->get_plt_entry_size()
- + object->local_plt_offset(r_sym));
-}
-
-// The first entry in the PLT for an executable.
-
-const unsigned char Output_data_plt_i386_exec::first_plt_entry[plt_entry_size] =
-{
- 0xff, 0x35, // pushl contents of memory address
- 0, 0, 0, 0, // replaced with address of .got + 4
- 0xff, 0x25, // jmp indirect
- 0, 0, 0, 0, // replaced with address of .got + 8
- 0, 0, 0, 0 // unused
-};
-
-void
-Output_data_plt_i386_exec::do_fill_first_plt_entry(
- unsigned char* pov,
- elfcpp::Elf_types<32>::Elf_Addr got_address)
-{
- memcpy(pov, first_plt_entry, plt_entry_size);
- elfcpp::Swap_unaligned<32, false>::writeval(pov + 2, got_address + 4);
- elfcpp::Swap<32, false>::writeval(pov + 8, got_address + 8);
-}
-
-// The first entry in the PLT for a shared object.
-
-const unsigned char Output_data_plt_i386_dyn::first_plt_entry[plt_entry_size] =
-{
- 0xff, 0xb3, 4, 0, 0, 0, // pushl 4(%ebx)
- 0xff, 0xa3, 8, 0, 0, 0, // jmp *8(%ebx)
- 0, 0, 0, 0 // unused
-};
-
-void
-Output_data_plt_i386_dyn::do_fill_first_plt_entry(
- unsigned char* pov,
- elfcpp::Elf_types<32>::Elf_Addr)
-{
- memcpy(pov, first_plt_entry, plt_entry_size);
-}
-
-// Subsequent entries in the PLT for an executable.
-
-const unsigned char Output_data_plt_i386_exec::plt_entry[plt_entry_size] =
-{
- 0xff, 0x25, // jmp indirect
- 0, 0, 0, 0, // replaced with address of symbol in .got
- 0x68, // pushl immediate
- 0, 0, 0, 0, // replaced with offset into relocation table
- 0xe9, // jmp relative
- 0, 0, 0, 0 // replaced with offset to start of .plt
-};
-
-unsigned int
-Output_data_plt_i386_exec::do_fill_plt_entry(
- unsigned char* pov,
- elfcpp::Elf_types<32>::Elf_Addr got_address,
- unsigned int got_offset,
- unsigned int plt_offset,
- unsigned int plt_rel_offset)
-{
- memcpy(pov, plt_entry, plt_entry_size);
- elfcpp::Swap_unaligned<32, false>::writeval(pov + 2,
- got_address + got_offset);
- elfcpp::Swap_unaligned<32, false>::writeval(pov + 7, plt_rel_offset);
- elfcpp::Swap<32, false>::writeval(pov + 12, - (plt_offset + 12 + 4));
- return 6;
-}
-
-// Subsequent entries in the PLT for a shared object.
-
-const unsigned char Output_data_plt_i386_dyn::plt_entry[plt_entry_size] =
-{
- 0xff, 0xa3, // jmp *offset(%ebx)
- 0, 0, 0, 0, // replaced with offset of symbol in .got
- 0x68, // pushl immediate
- 0, 0, 0, 0, // replaced with offset into relocation table
- 0xe9, // jmp relative
- 0, 0, 0, 0 // replaced with offset to start of .plt
-};
-
-unsigned int
-Output_data_plt_i386_dyn::do_fill_plt_entry(unsigned char* pov,
- elfcpp::Elf_types<32>::Elf_Addr,
- unsigned int got_offset,
- unsigned int plt_offset,
- unsigned int plt_rel_offset)
-{
- memcpy(pov, plt_entry, plt_entry_size);
- elfcpp::Swap_unaligned<32, false>::writeval(pov + 2, got_offset);
- elfcpp::Swap_unaligned<32, false>::writeval(pov + 7, plt_rel_offset);
- elfcpp::Swap<32, false>::writeval(pov + 12, - (plt_offset + 12 + 4));
- return 6;
-}
-
-// The .eh_frame unwind information for the PLT.
-
-const unsigned char
-Output_data_plt_i386::plt_eh_frame_cie[plt_eh_frame_cie_size] =
-{
- 1, // CIE version.
- 'z', // Augmentation: augmentation size included.
- 'R', // Augmentation: FDE encoding included.
- '\0', // End of augmentation string.
- 1, // Code alignment factor.
- 0x7c, // Data alignment factor.
- 8, // Return address column.
- 1, // Augmentation size.
- (elfcpp::DW_EH_PE_pcrel // FDE encoding.
- | elfcpp::DW_EH_PE_sdata4),
- elfcpp::DW_CFA_def_cfa, 4, 4, // DW_CFA_def_cfa: r4 (esp) ofs 4.
- elfcpp::DW_CFA_offset + 8, 1, // DW_CFA_offset: r8 (eip) at cfa-4.
- elfcpp::DW_CFA_nop, // Align to 16 bytes.
- elfcpp::DW_CFA_nop
-};
-
-const unsigned char
-Output_data_plt_i386_standard::plt_eh_frame_fde[plt_eh_frame_fde_size] =
-{
- 0, 0, 0, 0, // Replaced with offset to .plt.
- 0, 0, 0, 0, // Replaced with size of .plt.
- 0, // Augmentation size.
- elfcpp::DW_CFA_def_cfa_offset, 8, // DW_CFA_def_cfa_offset: 8.
- elfcpp::DW_CFA_advance_loc + 6, // Advance 6 to __PLT__ + 6.
- elfcpp::DW_CFA_def_cfa_offset, 12, // DW_CFA_def_cfa_offset: 12.
- elfcpp::DW_CFA_advance_loc + 10, // Advance 10 to __PLT__ + 16.
- elfcpp::DW_CFA_def_cfa_expression, // DW_CFA_def_cfa_expression.
- 11, // Block length.
- elfcpp::DW_OP_breg4, 4, // Push %esp + 4.
- elfcpp::DW_OP_breg8, 0, // Push %eip.
- elfcpp::DW_OP_lit15, // Push 0xf.
- elfcpp::DW_OP_and, // & (%eip & 0xf).
- elfcpp::DW_OP_lit11, // Push 0xb.
- elfcpp::DW_OP_ge, // >= ((%eip & 0xf) >= 0xb)
- elfcpp::DW_OP_lit2, // Push 2.
- elfcpp::DW_OP_shl, // << (((%eip & 0xf) >= 0xb) << 2)
- elfcpp::DW_OP_plus, // + ((((%eip&0xf)>=0xb)<<2)+%esp+4
- elfcpp::DW_CFA_nop, // Align to 32 bytes.
- elfcpp::DW_CFA_nop,
- elfcpp::DW_CFA_nop,
- elfcpp::DW_CFA_nop
-};
-
-// Write out the PLT. This uses the hand-coded instructions above,
-// and adjusts them as needed. This is all specified by the i386 ELF
-// Processor Supplement.
-
-void
-Output_data_plt_i386::do_write(Output_file* of)
-{
- const off_t offset = this->offset();
- const section_size_type oview_size =
- convert_to_section_size_type(this->data_size());
- unsigned char* const oview = of->get_output_view(offset, oview_size);
-
- const off_t got_file_offset = this->got_plt_->offset();
- gold_assert(parameters->incremental_update()
- || (got_file_offset + this->got_plt_->data_size()
- == this->got_irelative_->offset()));
- const section_size_type got_size =
- convert_to_section_size_type(this->got_plt_->data_size()
- + this->got_irelative_->data_size());
-
- unsigned char* const got_view = of->get_output_view(got_file_offset,
- got_size);
-
- unsigned char* pov = oview;
-
- elfcpp::Elf_types<32>::Elf_Addr plt_address = this->address();
- elfcpp::Elf_types<32>::Elf_Addr got_address = this->got_plt_->address();
-
- this->fill_first_plt_entry(pov, got_address);
- pov += this->get_plt_entry_size();
-
- // The first three entries in the GOT are reserved, and are written
- // by Output_data_got_plt_i386::do_write.
- unsigned char* got_pov = got_view + 12;
-
- const int rel_size = elfcpp::Elf_sizes<32>::rel_size;
-
- unsigned int plt_offset = this->get_plt_entry_size();
- unsigned int plt_rel_offset = 0;
- unsigned int got_offset = 12;
- const unsigned int count = this->count_ + this->irelative_count_;
- for (unsigned int i = 0;
- i < count;
- ++i,
- pov += this->get_plt_entry_size(),
- got_pov += 4,
- plt_offset += this->get_plt_entry_size(),
- plt_rel_offset += rel_size,
- got_offset += 4)
- {
- // Set and adjust the PLT entry itself.
- unsigned int lazy_offset = this->fill_plt_entry(pov,
- got_address,
- got_offset,
- plt_offset,
- plt_rel_offset);
-
- // Set the entry in the GOT.
- elfcpp::Swap<32, false>::writeval(got_pov,
- plt_address + plt_offset + lazy_offset);
- }
-
- // If any STT_GNU_IFUNC symbols have PLT entries, we need to change
- // the GOT to point to the actual symbol value, rather than point to
- // the PLT entry. That will let the dynamic linker call the right
- // function when resolving IRELATIVE relocations.
- unsigned char* got_irelative_view = got_view + this->got_plt_->data_size();
- for (std::vector<Global_ifunc>::const_iterator p =
- this->global_ifuncs_.begin();
- p != this->global_ifuncs_.end();
- ++p)
- {
- const Sized_symbol<32>* ssym =
- static_cast<const Sized_symbol<32>*>(p->sym);
- elfcpp::Swap<32, false>::writeval(got_irelative_view + p->got_offset,
- ssym->value());
- }
-
- for (std::vector<Local_ifunc>::const_iterator p =
- this->local_ifuncs_.begin();
- p != this->local_ifuncs_.end();
- ++p)
- {
- const Symbol_value<32>* psymval =
- p->object->local_symbol(p->local_sym_index);
- elfcpp::Swap<32, false>::writeval(got_irelative_view + p->got_offset,
- psymval->value(p->object, 0));
- }
-
- gold_assert(static_cast<section_size_type>(pov - oview) == oview_size);
- gold_assert(static_cast<section_size_type>(got_pov - got_view) == got_size);
-
- of->write_output_view(offset, oview_size, oview);
- of->write_output_view(got_file_offset, got_size, got_view);
-}
-
-// Create the PLT section.
-
-void
-Target_i386::make_plt_section(Symbol_table* symtab, Layout* layout)
-{
- if (this->plt_ == NULL)
- {
- // Create the GOT sections first.
- this->got_section(symtab, layout);
-
- const bool dyn = parameters->options().output_is_position_independent();
- this->plt_ = this->make_data_plt(layout,
- this->got_plt_,
- this->got_irelative_,
- dyn);
-
- // Add unwind information if requested.
- if (parameters->options().ld_generated_unwind_info())
- this->plt_->add_eh_frame(layout);
-
- layout->add_output_section_data(".plt", elfcpp::SHT_PROGBITS,
- (elfcpp::SHF_ALLOC
- | elfcpp::SHF_EXECINSTR),
- this->plt_, ORDER_PLT, false);
-
- // Make the sh_info field of .rel.plt point to .plt.
- Output_section* rel_plt_os = this->plt_->rel_plt()->output_section();
- rel_plt_os->set_info_section(this->plt_->output_section());
- }
-}
-
-// Create a PLT entry for a global symbol.
-
-void
-Target_i386::make_plt_entry(Symbol_table* symtab, Layout* layout, Symbol* gsym)
-{
- if (gsym->has_plt_offset())
- return;
- if (this->plt_ == NULL)
- this->make_plt_section(symtab, layout);
- this->plt_->add_entry(symtab, layout, gsym);
-}
-
-// Make a PLT entry for a local STT_GNU_IFUNC symbol.
-
-void
-Target_i386::make_local_ifunc_plt_entry(Symbol_table* symtab, Layout* layout,
- Sized_relobj_file<32, false>* relobj,
- unsigned int local_sym_index)
-{
- if (relobj->local_has_plt_offset(local_sym_index))
- return;
- if (this->plt_ == NULL)
- this->make_plt_section(symtab, layout);
- unsigned int plt_offset = this->plt_->add_local_ifunc_entry(symtab, layout,
- relobj,
- local_sym_index);
- relobj->set_local_plt_offset(local_sym_index, plt_offset);
-}
-
-// Return the number of entries in the PLT.
-
-unsigned int
-Target_i386::plt_entry_count() const
-{
- if (this->plt_ == NULL)
- return 0;
- return this->plt_->entry_count();
-}
-
-// Return the offset of the first non-reserved PLT entry.
-
-unsigned int
-Target_i386::first_plt_entry_offset() const
-{
- if (this->plt_ == NULL)
- return 0;
- return this->plt_->first_plt_entry_offset();
-}
-
-// Return the size of each PLT entry.
-
-unsigned int
-Target_i386::plt_entry_size() const
-{
- if (this->plt_ == NULL)
- return 0;
- return this->plt_->get_plt_entry_size();
-}
-
-// Get the section to use for TLS_DESC relocations.
-
-Target_i386::Reloc_section*
-Target_i386::rel_tls_desc_section(Layout* layout) const
-{
- return this->plt_section()->rel_tls_desc(layout);
-}
-
-// Define the _TLS_MODULE_BASE_ symbol in the TLS segment.
-
-void
-Target_i386::define_tls_base_symbol(Symbol_table* symtab, Layout* layout)
-{
- if (this->tls_base_symbol_defined_)
- return;
-
- Output_segment* tls_segment = layout->tls_segment();
- if (tls_segment != NULL)
- {
- bool is_exec = parameters->options().output_is_executable();
- symtab->define_in_output_segment("_TLS_MODULE_BASE_", NULL,
- Symbol_table::PREDEFINED,
- tls_segment, 0, 0,
- elfcpp::STT_TLS,
- elfcpp::STB_LOCAL,
- elfcpp::STV_HIDDEN, 0,
- (is_exec
- ? Symbol::SEGMENT_END
- : Symbol::SEGMENT_START),
- true);
- }
- this->tls_base_symbol_defined_ = true;
-}
-
-// Create a GOT entry for the TLS module index.
-
-unsigned int
-Target_i386::got_mod_index_entry(Symbol_table* symtab, Layout* layout,
- Sized_relobj_file<32, false>* object)
-{
- if (this->got_mod_index_offset_ == -1U)
- {
- gold_assert(symtab != NULL && layout != NULL && object != NULL);
- Reloc_section* rel_dyn = this->rel_dyn_section(layout);
- Output_data_got<32, false>* got = this->got_section(symtab, layout);
- unsigned int got_offset = got->add_constant(0);
- rel_dyn->add_local(object, 0, elfcpp::R_386_TLS_DTPMOD32, got,
- got_offset);
- got->add_constant(0);
- this->got_mod_index_offset_ = got_offset;
- }
- return this->got_mod_index_offset_;
-}
-
-// Optimize the TLS relocation type based on what we know about the
-// symbol. IS_FINAL is true if the final address of this symbol is
-// known at link time.
-
-tls::Tls_optimization
-Target_i386::optimize_tls_reloc(bool is_final, int r_type)
-{
- // If we are generating a shared library, then we can't do anything
- // in the linker.
- if (parameters->options().shared())
- return tls::TLSOPT_NONE;
-
- switch (r_type)
- {
- case elfcpp::R_386_TLS_GD:
- case elfcpp::R_386_TLS_GOTDESC:
- case elfcpp::R_386_TLS_DESC_CALL:
- // These are General-Dynamic which permits fully general TLS
- // access. Since we know that we are generating an executable,
- // we can convert this to Initial-Exec. If we also know that
- // this is a local symbol, we can further switch to Local-Exec.
- if (is_final)
- return tls::TLSOPT_TO_LE;
- return tls::TLSOPT_TO_IE;
-
- case elfcpp::R_386_TLS_LDM:
- // This is Local-Dynamic, which refers to a local symbol in the
- // dynamic TLS block. Since we know that we generating an
- // executable, we can switch to Local-Exec.
- return tls::TLSOPT_TO_LE;
-
- case elfcpp::R_386_TLS_LDO_32:
- // Another type of Local-Dynamic relocation.
- return tls::TLSOPT_TO_LE;
-
- case elfcpp::R_386_TLS_IE:
- case elfcpp::R_386_TLS_GOTIE:
- case elfcpp::R_386_TLS_IE_32:
- // These are Initial-Exec relocs which get the thread offset
- // from the GOT. If we know that we are linking against the
- // local symbol, we can switch to Local-Exec, which links the
- // thread offset into the instruction.
- if (is_final)
- return tls::TLSOPT_TO_LE;
- return tls::TLSOPT_NONE;
-
- case elfcpp::R_386_TLS_LE:
- case elfcpp::R_386_TLS_LE_32:
- // When we already have Local-Exec, there is nothing further we
- // can do.
- return tls::TLSOPT_NONE;
-
- default:
- gold_unreachable();
- }
-}
-
-// Get the Reference_flags for a particular relocation.
-
-int
-Target_i386::Scan::get_reference_flags(unsigned int r_type)
-{
- switch (r_type)
- {
- case elfcpp::R_386_NONE:
- case elfcpp::R_386_GNU_VTINHERIT:
- case elfcpp::R_386_GNU_VTENTRY:
- case elfcpp::R_386_GOTPC:
- // No symbol reference.
- return 0;
-
- case elfcpp::R_386_32:
- case elfcpp::R_386_16:
- case elfcpp::R_386_8:
- return Symbol::ABSOLUTE_REF;
-
- case elfcpp::R_386_PC32:
- case elfcpp::R_386_PC16:
- case elfcpp::R_386_PC8:
- case elfcpp::R_386_GOTOFF:
- return Symbol::RELATIVE_REF;
-
- case elfcpp::R_386_PLT32:
- return Symbol::FUNCTION_CALL | Symbol::RELATIVE_REF;
-
- case elfcpp::R_386_GOT32:
- case elfcpp::R_386_GOT32X:
- // Absolute in GOT.
- return Symbol::ABSOLUTE_REF;
-
- case elfcpp::R_386_TLS_GD: // Global-dynamic
- case elfcpp::R_386_TLS_GOTDESC: // Global-dynamic (from ~oliva url)
- case elfcpp::R_386_TLS_DESC_CALL:
- case elfcpp::R_386_TLS_LDM: // Local-dynamic
- case elfcpp::R_386_TLS_LDO_32: // Alternate local-dynamic
- case elfcpp::R_386_TLS_IE: // Initial-exec
- case elfcpp::R_386_TLS_IE_32:
- case elfcpp::R_386_TLS_GOTIE:
- case elfcpp::R_386_TLS_LE: // Local-exec
- case elfcpp::R_386_TLS_LE_32:
- return Symbol::TLS_REF;
-
- case elfcpp::R_386_COPY:
- case elfcpp::R_386_GLOB_DAT:
- case elfcpp::R_386_JUMP_SLOT:
- case elfcpp::R_386_RELATIVE:
- case elfcpp::R_386_IRELATIVE:
- case elfcpp::R_386_TLS_TPOFF:
- case elfcpp::R_386_TLS_DTPMOD32:
- case elfcpp::R_386_TLS_DTPOFF32:
- case elfcpp::R_386_TLS_TPOFF32:
- case elfcpp::R_386_TLS_DESC:
- case elfcpp::R_386_32PLT:
- case elfcpp::R_386_TLS_GD_32:
- case elfcpp::R_386_TLS_GD_PUSH:
- case elfcpp::R_386_TLS_GD_CALL:
- case elfcpp::R_386_TLS_GD_POP:
- case elfcpp::R_386_TLS_LDM_32:
- case elfcpp::R_386_TLS_LDM_PUSH:
- case elfcpp::R_386_TLS_LDM_CALL:
- case elfcpp::R_386_TLS_LDM_POP:
- case elfcpp::R_386_USED_BY_INTEL_200:
- default:
- // Not expected. We will give an error later.
- return 0;
- }
-}
-
-// Report an unsupported relocation against a local symbol.
-
-void
-Target_i386::Scan::unsupported_reloc_local(Sized_relobj_file<32, false>* object,
- unsigned int r_type)
-{
- gold_error(_("%s: unsupported reloc %u against local symbol"),
- object->name().c_str(), r_type);
-}
-
-// Return whether we need to make a PLT entry for a relocation of a
-// given type against a STT_GNU_IFUNC symbol.
-
-bool
-Target_i386::Scan::reloc_needs_plt_for_ifunc(
- Sized_relobj_file<32, false>* object,
- unsigned int r_type)
-{
- int flags = Scan::get_reference_flags(r_type);
- if (flags & Symbol::TLS_REF)
- gold_error(_("%s: unsupported TLS reloc %u for IFUNC symbol"),
- object->name().c_str(), r_type);
- return flags != 0;
-}
-
-// Scan a relocation for a local symbol.
-
-inline void
-Target_i386::Scan::local(Symbol_table* symtab,
- Layout* layout,
- Target_i386* target,
- Sized_relobj_file<32, false>* object,
- unsigned int data_shndx,
- Output_section* output_section,
- const elfcpp::Rel<32, false>& reloc,
- unsigned int r_type,
- const elfcpp::Sym<32, false>& lsym,
- bool is_discarded)
-{
- if (is_discarded)
- return;
-
- // A local STT_GNU_IFUNC symbol may require a PLT entry.
- if (lsym.get_st_type() == elfcpp::STT_GNU_IFUNC
- && this->reloc_needs_plt_for_ifunc(object, r_type))
- {
- unsigned int r_sym = elfcpp::elf_r_sym<32>(reloc.get_r_info());
- target->make_local_ifunc_plt_entry(symtab, layout, object, r_sym);
- }
-
- switch (r_type)
- {
- case elfcpp::R_386_NONE:
- case elfcpp::R_386_GNU_VTINHERIT:
- case elfcpp::R_386_GNU_VTENTRY:
- break;
-
- case elfcpp::R_386_32:
- // If building a shared library (or a position-independent
- // executable), we need to create a dynamic relocation for
- // this location. The relocation applied at link time will
- // apply the link-time value, so we flag the location with
- // an R_386_RELATIVE relocation so the dynamic loader can
- // relocate it easily.
- if (parameters->options().output_is_position_independent())
- {
- Reloc_section* rel_dyn = target->rel_dyn_section(layout);
- unsigned int r_sym = elfcpp::elf_r_sym<32>(reloc.get_r_info());
- rel_dyn->add_local_relative(object, r_sym, elfcpp::R_386_RELATIVE,
- output_section, data_shndx,
- reloc.get_r_offset());
- }
- break;
-
- case elfcpp::R_386_16:
- case elfcpp::R_386_8:
- // If building a shared library (or a position-independent
- // executable), we need to create a dynamic relocation for
- // this location. Because the addend needs to remain in the
- // data section, we need to be careful not to apply this
- // relocation statically.
- if (parameters->options().output_is_position_independent())
- {
- Reloc_section* rel_dyn = target->rel_dyn_section(layout);
- unsigned int r_sym = elfcpp::elf_r_sym<32>(reloc.get_r_info());
- if (lsym.get_st_type() != elfcpp::STT_SECTION)
- rel_dyn->add_local(object, r_sym, r_type, output_section,
- data_shndx, reloc.get_r_offset());
- else
- {
- gold_assert(lsym.get_st_value() == 0);
- unsigned int shndx = lsym.get_st_shndx();
- bool is_ordinary;
- shndx = object->adjust_sym_shndx(r_sym, shndx,
- &is_ordinary);
- if (!is_ordinary)
- object->error(_("section symbol %u has bad shndx %u"),
- r_sym, shndx);
- else
- rel_dyn->add_local_section(object, shndx,
- r_type, output_section,
- data_shndx, reloc.get_r_offset());
- }
- }
- break;
-
- case elfcpp::R_386_PC32:
- case elfcpp::R_386_PC16:
- case elfcpp::R_386_PC8:
- break;
-
- case elfcpp::R_386_PLT32:
- // Since we know this is a local symbol, we can handle this as a
- // PC32 reloc.
- break;
-
- case elfcpp::R_386_GOTOFF:
- case elfcpp::R_386_GOTPC:
- // We need a GOT section.
- target->got_section(symtab, layout);
- break;
-
- case elfcpp::R_386_GOT32:
- case elfcpp::R_386_GOT32X:
- {
- // We need GOT section.
- Output_data_got<32, false>* got = target->got_section(symtab, layout);
-
- // If the relocation symbol isn't IFUNC,
- // and is local, then we will convert
- // mov foo@GOT(%reg), %reg
- // to
- // lea foo@GOTOFF(%reg), %reg
- // in Relocate::relocate.
- if (reloc.get_r_offset() >= 2
- && lsym.get_st_type() != elfcpp::STT_GNU_IFUNC)
- {
- section_size_type stype;
- const unsigned char* view = object->section_contents(data_shndx,
- &stype, true);
- if (view[reloc.get_r_offset() - 2] == 0x8b)
- break;
- }
-
- // Otherwise, the symbol requires a GOT entry.
- unsigned int r_sym = elfcpp::elf_r_sym<32>(reloc.get_r_info());
-
- // For a STT_GNU_IFUNC symbol we want the PLT offset. That
- // lets function pointers compare correctly with shared
- // libraries. Otherwise we would need an IRELATIVE reloc.
- bool is_new;
- if (lsym.get_st_type() == elfcpp::STT_GNU_IFUNC)
- is_new = got->add_local_plt(object, r_sym, GOT_TYPE_STANDARD);
- else
- is_new = got->add_local(object, r_sym, GOT_TYPE_STANDARD);
- if (is_new)
- {
- // If we are generating a shared object, we need to add a
- // dynamic RELATIVE relocation for this symbol's GOT entry.
- if (parameters->options().output_is_position_independent())
- {
- Reloc_section* rel_dyn = target->rel_dyn_section(layout);
- unsigned int got_offset =
- object->local_got_offset(r_sym, GOT_TYPE_STANDARD);
- rel_dyn->add_local_relative(object, r_sym,
- elfcpp::R_386_RELATIVE,
- got, got_offset);
- }
- }
- }
- break;
-
- // These are relocations which should only be seen by the
- // dynamic linker, and should never be seen here.
- case elfcpp::R_386_COPY:
- case elfcpp::R_386_GLOB_DAT:
- case elfcpp::R_386_JUMP_SLOT:
- case elfcpp::R_386_RELATIVE:
- case elfcpp::R_386_IRELATIVE:
- case elfcpp::R_386_TLS_TPOFF:
- case elfcpp::R_386_TLS_DTPMOD32:
- case elfcpp::R_386_TLS_DTPOFF32:
- case elfcpp::R_386_TLS_TPOFF32:
- case elfcpp::R_386_TLS_DESC:
- gold_error(_("%s: unexpected reloc %u in object file"),
- object->name().c_str(), r_type);
- break;
-
- // These are initial TLS relocs, which are expected when
- // linking.
- case elfcpp::R_386_TLS_GD: // Global-dynamic
- case elfcpp::R_386_TLS_GOTDESC: // Global-dynamic (from ~oliva url)
- case elfcpp::R_386_TLS_DESC_CALL:
- case elfcpp::R_386_TLS_LDM: // Local-dynamic
- case elfcpp::R_386_TLS_LDO_32: // Alternate local-dynamic
- case elfcpp::R_386_TLS_IE: // Initial-exec
- case elfcpp::R_386_TLS_IE_32:
- case elfcpp::R_386_TLS_GOTIE:
- case elfcpp::R_386_TLS_LE: // Local-exec
- case elfcpp::R_386_TLS_LE_32:
- {
- bool output_is_shared = parameters->options().shared();
- const tls::Tls_optimization optimized_type
- = Target_i386::optimize_tls_reloc(!output_is_shared, r_type);
- switch (r_type)
- {
- case elfcpp::R_386_TLS_GD: // Global-dynamic
- if (optimized_type == tls::TLSOPT_NONE)
- {
- // Create a pair of GOT entries for the module index and
- // dtv-relative offset.
- Output_data_got<32, false>* got
- = target->got_section(symtab, layout);
- unsigned int r_sym = elfcpp::elf_r_sym<32>(reloc.get_r_info());
- unsigned int shndx = lsym.get_st_shndx();
- bool is_ordinary;
- shndx = object->adjust_sym_shndx(r_sym, shndx, &is_ordinary);
- if (!is_ordinary)
- object->error(_("local symbol %u has bad shndx %u"),
- r_sym, shndx);
- else
- got->add_local_pair_with_rel(object, r_sym, shndx,
- GOT_TYPE_TLS_PAIR,
- target->rel_dyn_section(layout),
- elfcpp::R_386_TLS_DTPMOD32);
- }
- else if (optimized_type != tls::TLSOPT_TO_LE)
- unsupported_reloc_local(object, r_type);
- break;
-
- case elfcpp::R_386_TLS_GOTDESC: // Global-dynamic (from ~oliva)
- target->define_tls_base_symbol(symtab, layout);
- if (optimized_type == tls::TLSOPT_NONE)
- {
- // Create a double GOT entry with an R_386_TLS_DESC
- // reloc. The R_386_TLS_DESC reloc is resolved
- // lazily, so the GOT entry needs to be in an area in
- // .got.plt, not .got. Call got_section to make sure
- // the section has been created.
- target->got_section(symtab, layout);
- Output_data_got<32, false>* got = target->got_tlsdesc_section();
- unsigned int r_sym = elfcpp::elf_r_sym<32>(reloc.get_r_info());
- if (!object->local_has_got_offset(r_sym, GOT_TYPE_TLS_DESC))
- {
- unsigned int got_offset = got->add_constant(0);
- // The local symbol value is stored in the second
- // GOT entry.
- got->add_local(object, r_sym, GOT_TYPE_TLS_DESC);
- // That set the GOT offset of the local symbol to
- // point to the second entry, but we want it to
- // point to the first.
- object->set_local_got_offset(r_sym, GOT_TYPE_TLS_DESC,
- got_offset);
- Reloc_section* rt = target->rel_tls_desc_section(layout);
- rt->add_absolute(elfcpp::R_386_TLS_DESC, got, got_offset);
- }
- }
- else if (optimized_type != tls::TLSOPT_TO_LE)
- unsupported_reloc_local(object, r_type);
- break;
-
- case elfcpp::R_386_TLS_DESC_CALL:
- break;
-
- case elfcpp::R_386_TLS_LDM: // Local-dynamic
- if (optimized_type == tls::TLSOPT_NONE)
- {
- // Create a GOT entry for the module index.
- target->got_mod_index_entry(symtab, layout, object);
- }
- else if (optimized_type != tls::TLSOPT_TO_LE)
- unsupported_reloc_local(object, r_type);
- break;
-
- case elfcpp::R_386_TLS_LDO_32: // Alternate local-dynamic
- break;
-
- case elfcpp::R_386_TLS_IE: // Initial-exec
- case elfcpp::R_386_TLS_IE_32:
- case elfcpp::R_386_TLS_GOTIE:
- layout->set_has_static_tls();
- if (optimized_type == tls::TLSOPT_NONE)
- {
- // For the R_386_TLS_IE relocation, we need to create a
- // dynamic relocation when building a shared library.
- if (r_type == elfcpp::R_386_TLS_IE
- && parameters->options().shared())
- {
- Reloc_section* rel_dyn = target->rel_dyn_section(layout);
- unsigned int r_sym
- = elfcpp::elf_r_sym<32>(reloc.get_r_info());
- rel_dyn->add_local_relative(object, r_sym,
- elfcpp::R_386_RELATIVE,
- output_section, data_shndx,
- reloc.get_r_offset());
- }
- // Create a GOT entry for the tp-relative offset.
- Output_data_got<32, false>* got
- = target->got_section(symtab, layout);
- unsigned int r_sym = elfcpp::elf_r_sym<32>(reloc.get_r_info());
- unsigned int dyn_r_type = (r_type == elfcpp::R_386_TLS_IE_32
- ? elfcpp::R_386_TLS_TPOFF32
- : elfcpp::R_386_TLS_TPOFF);
- unsigned int got_type = (r_type == elfcpp::R_386_TLS_IE_32
- ? GOT_TYPE_TLS_OFFSET
- : GOT_TYPE_TLS_NOFFSET);
- got->add_local_with_rel(object, r_sym, got_type,
- target->rel_dyn_section(layout),
- dyn_r_type);
- }
- else if (optimized_type != tls::TLSOPT_TO_LE)
- unsupported_reloc_local(object, r_type);
- break;
-
- case elfcpp::R_386_TLS_LE: // Local-exec
- case elfcpp::R_386_TLS_LE_32:
- layout->set_has_static_tls();
- if (output_is_shared)
- {
- // We need to create a dynamic relocation.
- gold_assert(lsym.get_st_type() != elfcpp::STT_SECTION);
- unsigned int r_sym = elfcpp::elf_r_sym<32>(reloc.get_r_info());
- unsigned int dyn_r_type = (r_type == elfcpp::R_386_TLS_LE_32
- ? elfcpp::R_386_TLS_TPOFF32
- : elfcpp::R_386_TLS_TPOFF);
- Reloc_section* rel_dyn = target->rel_dyn_section(layout);
- rel_dyn->add_local(object, r_sym, dyn_r_type, output_section,
- data_shndx, reloc.get_r_offset());
- }
- break;
-
- default:
- gold_unreachable();
- }
- }
- break;
-
- case elfcpp::R_386_32PLT:
- case elfcpp::R_386_TLS_GD_32:
- case elfcpp::R_386_TLS_GD_PUSH:
- case elfcpp::R_386_TLS_GD_CALL:
- case elfcpp::R_386_TLS_GD_POP:
- case elfcpp::R_386_TLS_LDM_32:
- case elfcpp::R_386_TLS_LDM_PUSH:
- case elfcpp::R_386_TLS_LDM_CALL:
- case elfcpp::R_386_TLS_LDM_POP:
- case elfcpp::R_386_USED_BY_INTEL_200:
- default:
- unsupported_reloc_local(object, r_type);
- break;
- }
-}
-
-// Report an unsupported relocation against a global symbol.
-
-void
-Target_i386::Scan::unsupported_reloc_global(
- Sized_relobj_file<32, false>* object,
- unsigned int r_type,
- Symbol* gsym)
-{
- gold_error(_("%s: unsupported reloc %u against global symbol %s"),
- object->name().c_str(), r_type, gsym->demangled_name().c_str());
-}
-
-inline bool
-Target_i386::Scan::possible_function_pointer_reloc(unsigned int r_type)
-{
- switch (r_type)
- {
- case elfcpp::R_386_32:
- case elfcpp::R_386_16:
- case elfcpp::R_386_8:
- case elfcpp::R_386_GOTOFF:
- case elfcpp::R_386_GOT32:
- case elfcpp::R_386_GOT32X:
- {
- return true;
- }
- default:
- return false;
- }
- return false;
-}
-
-inline bool
-Target_i386::Scan::local_reloc_may_be_function_pointer(
- Symbol_table* ,
- Layout* ,
- Target_i386* ,
- Sized_relobj_file<32, false>* ,
- unsigned int ,
- Output_section* ,
- const elfcpp::Rel<32, false>& ,
- unsigned int r_type,
- const elfcpp::Sym<32, false>&)
-{
- return possible_function_pointer_reloc(r_type);
-}
-
-inline bool
-Target_i386::Scan::global_reloc_may_be_function_pointer(
- Symbol_table* ,
- Layout* ,
- Target_i386* ,
- Sized_relobj_file<32, false>* ,
- unsigned int ,
- Output_section* ,
- const elfcpp::Rel<32, false>& ,
- unsigned int r_type,
- Symbol*)
-{
- return possible_function_pointer_reloc(r_type);
-}
-
-// Scan a relocation for a global symbol.
-
-inline void
-Target_i386::Scan::global(Symbol_table* symtab,
- Layout* layout,
- Target_i386* target,
- Sized_relobj_file<32, false>* object,
- unsigned int data_shndx,
- Output_section* output_section,
- const elfcpp::Rel<32, false>& reloc,
- unsigned int r_type,
- Symbol* gsym)
-{
- // A STT_GNU_IFUNC symbol may require a PLT entry.
- if (gsym->type() == elfcpp::STT_GNU_IFUNC
- && this->reloc_needs_plt_for_ifunc(object, r_type))
- target->make_plt_entry(symtab, layout, gsym);
-
- switch (r_type)
- {
- case elfcpp::R_386_NONE:
- case elfcpp::R_386_GNU_VTINHERIT:
- case elfcpp::R_386_GNU_VTENTRY:
- break;
-
- case elfcpp::R_386_32:
- case elfcpp::R_386_16:
- case elfcpp::R_386_8:
- {
- // Make a PLT entry if necessary.
- if (gsym->needs_plt_entry())
- {
- target->make_plt_entry(symtab, layout, gsym);
- // Since this is not a PC-relative relocation, we may be
- // taking the address of a function. In that case we need to
- // set the entry in the dynamic symbol table to the address of
- // the PLT entry.
- if (gsym->is_from_dynobj() && !parameters->options().shared())
- gsym->set_needs_dynsym_value();
- }
- // Make a dynamic relocation if necessary.
- if (gsym->needs_dynamic_reloc(Scan::get_reference_flags(r_type)))
- {
- if (!parameters->options().output_is_position_independent()
- && gsym->may_need_copy_reloc())
- {
- target->copy_reloc(symtab, layout, object,
- data_shndx, output_section, gsym, reloc);
- }
- else if (r_type == elfcpp::R_386_32
- && gsym->type() == elfcpp::STT_GNU_IFUNC
- && gsym->can_use_relative_reloc(false)
- && !gsym->is_from_dynobj()
- && !gsym->is_undefined()
- && !gsym->is_preemptible())
- {
- // Use an IRELATIVE reloc for a locally defined
- // STT_GNU_IFUNC symbol. This makes a function
- // address in a PIE executable match the address in a
- // shared library that it links against.
- Reloc_section* rel_dyn = target->rel_irelative_section(layout);
- rel_dyn->add_symbolless_global_addend(gsym,
- elfcpp::R_386_IRELATIVE,
- output_section,
- object, data_shndx,
- reloc.get_r_offset());
- }
- else if (r_type == elfcpp::R_386_32
- && gsym->can_use_relative_reloc(false))
- {
- Reloc_section* rel_dyn = target->rel_dyn_section(layout);
- rel_dyn->add_global_relative(gsym, elfcpp::R_386_RELATIVE,
- output_section, object,
- data_shndx, reloc.get_r_offset());
- }
- else
- {
- Reloc_section* rel_dyn = target->rel_dyn_section(layout);
- rel_dyn->add_global(gsym, r_type, output_section, object,
- data_shndx, reloc.get_r_offset());
- }
- }
- }
- break;
-
- case elfcpp::R_386_PC32:
- case elfcpp::R_386_PC16:
- case elfcpp::R_386_PC8:
- {
- // Make a PLT entry if necessary.
- if (gsym->needs_plt_entry())
- {
- // These relocations are used for function calls only in
- // non-PIC code. For a 32-bit relocation in a shared library,
- // we'll need a text relocation anyway, so we can skip the
- // PLT entry and let the dynamic linker bind the call directly
- // to the target. For smaller relocations, we should use a
- // PLT entry to ensure that the call can reach.
- if (!parameters->options().shared()
- || r_type != elfcpp::R_386_PC32)
- target->make_plt_entry(symtab, layout, gsym);
- }
- // Make a dynamic relocation if necessary.
- if (gsym->needs_dynamic_reloc(Scan::get_reference_flags(r_type)))
- {
- if (parameters->options().output_is_executable()
- && gsym->may_need_copy_reloc())
- {
- target->copy_reloc(symtab, layout, object,
- data_shndx, output_section, gsym, reloc);
- }
- else
- {
- Reloc_section* rel_dyn = target->rel_dyn_section(layout);
- rel_dyn->add_global(gsym, r_type, output_section, object,
- data_shndx, reloc.get_r_offset());
- }
- }
- }
- break;
-
- case elfcpp::R_386_GOT32:
- case elfcpp::R_386_GOT32X:
- {
- // The symbol requires a GOT section.
- Output_data_got<32, false>* got = target->got_section(symtab, layout);
-
- // If we convert this from
- // mov foo@GOT(%reg), %reg
- // to
- // lea foo@GOTOFF(%reg), %reg
- // in Relocate::relocate, then there is nothing to do here.
- if (reloc.get_r_offset() >= 2
- && Target_i386::can_convert_mov_to_lea(gsym))
- {
- section_size_type stype;
- const unsigned char* view = object->section_contents(data_shndx,
- &stype, true);
- if (view[reloc.get_r_offset() - 2] == 0x8b)
- break;
- }
-
- if (gsym->final_value_is_known())
- {
- // For a STT_GNU_IFUNC symbol we want the PLT address.
- if (gsym->type() == elfcpp::STT_GNU_IFUNC)
- got->add_global_plt(gsym, GOT_TYPE_STANDARD);
- else
- got->add_global(gsym, GOT_TYPE_STANDARD);
- }
- else
- {
- // If this symbol is not fully resolved, we need to add a
- // GOT entry with a dynamic relocation.
- Reloc_section* rel_dyn = target->rel_dyn_section(layout);
-
- // Use a GLOB_DAT rather than a RELATIVE reloc if:
- //
- // 1) The symbol may be defined in some other module.
- //
- // 2) We are building a shared library and this is a
- // protected symbol; using GLOB_DAT means that the dynamic
- // linker can use the address of the PLT in the main
- // executable when appropriate so that function address
- // comparisons work.
- //
- // 3) This is a STT_GNU_IFUNC symbol in position dependent
- // code, again so that function address comparisons work.
- if (gsym->is_from_dynobj()
- || gsym->is_undefined()
- || gsym->is_preemptible()
- || (gsym->visibility() == elfcpp::STV_PROTECTED
- && parameters->options().shared())
- || (gsym->type() == elfcpp::STT_GNU_IFUNC
- && parameters->options().output_is_position_independent()))
- got->add_global_with_rel(gsym, GOT_TYPE_STANDARD,
- rel_dyn, elfcpp::R_386_GLOB_DAT);
- else
- {
- // For a STT_GNU_IFUNC symbol we want to write the PLT
- // offset into the GOT, so that function pointer
- // comparisons work correctly.
- bool is_new;
- if (gsym->type() != elfcpp::STT_GNU_IFUNC)
- is_new = got->add_global(gsym, GOT_TYPE_STANDARD);
- else
- {
- is_new = got->add_global_plt(gsym, GOT_TYPE_STANDARD);
- // Tell the dynamic linker to use the PLT address
- // when resolving relocations.
- if (gsym->is_from_dynobj()
- && !parameters->options().shared())
- gsym->set_needs_dynsym_value();
- }
- if (is_new)
- {
- unsigned int got_off = gsym->got_offset(GOT_TYPE_STANDARD);
- rel_dyn->add_global_relative(gsym, elfcpp::R_386_RELATIVE,
- got, got_off);
- }
- }
- }
- }
- break;
-
- case elfcpp::R_386_PLT32:
- // If the symbol is fully resolved, this is just a PC32 reloc.
- // Otherwise we need a PLT entry.
- if (gsym->final_value_is_known())
- break;
- // If building a shared library, we can also skip the PLT entry
- // if the symbol is defined in the output file and is protected
- // or hidden.
- if (gsym->is_defined()
- && !gsym->is_from_dynobj()
- && !gsym->is_preemptible())
- break;
- target->make_plt_entry(symtab, layout, gsym);
- break;
-
- case elfcpp::R_386_GOTOFF:
- // A GOT-relative reference must resolve locally.
- if (!gsym->is_defined())
- gold_error(_("%s: relocation R_386_GOTOFF against undefined symbol %s"
- " cannot be used when making a shared object"),
- object->name().c_str(), gsym->name());
- else if (gsym->is_from_dynobj())
- gold_error(_("%s: relocation R_386_GOTOFF against external symbol %s"
- " cannot be used when making a shared object"),
- object->name().c_str(), gsym->name());
- else if (gsym->is_preemptible())
- gold_error(_("%s: relocation R_386_GOTOFF against preemptible symbol %s"
- " cannot be used when making a shared object"),
- object->name().c_str(), gsym->name());
- // We need a GOT section.
- target->got_section(symtab, layout);
- break;
-
- case elfcpp::R_386_GOTPC:
- // We need a GOT section.
- target->got_section(symtab, layout);
- break;
-
- // These are relocations which should only be seen by the
- // dynamic linker, and should never be seen here.
- case elfcpp::R_386_COPY:
- case elfcpp::R_386_GLOB_DAT:
- case elfcpp::R_386_JUMP_SLOT:
- case elfcpp::R_386_RELATIVE:
- case elfcpp::R_386_IRELATIVE:
- case elfcpp::R_386_TLS_TPOFF:
- case elfcpp::R_386_TLS_DTPMOD32:
- case elfcpp::R_386_TLS_DTPOFF32:
- case elfcpp::R_386_TLS_TPOFF32:
- case elfcpp::R_386_TLS_DESC:
- gold_error(_("%s: unexpected reloc %u in object file"),
- object->name().c_str(), r_type);
- break;
-
- // These are initial tls relocs, which are expected when
- // linking.
- case elfcpp::R_386_TLS_GD: // Global-dynamic
- case elfcpp::R_386_TLS_GOTDESC: // Global-dynamic (from ~oliva url)
- case elfcpp::R_386_TLS_DESC_CALL:
- case elfcpp::R_386_TLS_LDM: // Local-dynamic
- case elfcpp::R_386_TLS_LDO_32: // Alternate local-dynamic
- case elfcpp::R_386_TLS_IE: // Initial-exec
- case elfcpp::R_386_TLS_IE_32:
- case elfcpp::R_386_TLS_GOTIE:
- case elfcpp::R_386_TLS_LE: // Local-exec
- case elfcpp::R_386_TLS_LE_32:
- {
- const bool is_final = gsym->final_value_is_known();
- const tls::Tls_optimization optimized_type
- = Target_i386::optimize_tls_reloc(is_final, r_type);
- switch (r_type)
- {
- case elfcpp::R_386_TLS_GD: // Global-dynamic
- if (optimized_type == tls::TLSOPT_NONE)
- {
- // Create a pair of GOT entries for the module index and
- // dtv-relative offset.
- Output_data_got<32, false>* got
- = target->got_section(symtab, layout);
- got->add_global_pair_with_rel(gsym, GOT_TYPE_TLS_PAIR,
- target->rel_dyn_section(layout),
- elfcpp::R_386_TLS_DTPMOD32,
- elfcpp::R_386_TLS_DTPOFF32);
- }
- else if (optimized_type == tls::TLSOPT_TO_IE)
- {
- // Create a GOT entry for the tp-relative offset.
- Output_data_got<32, false>* got
- = target->got_section(symtab, layout);
- got->add_global_with_rel(gsym, GOT_TYPE_TLS_NOFFSET,
- target->rel_dyn_section(layout),
- elfcpp::R_386_TLS_TPOFF);
- }
- else if (optimized_type != tls::TLSOPT_TO_LE)
- unsupported_reloc_global(object, r_type, gsym);
- break;
-
- case elfcpp::R_386_TLS_GOTDESC: // Global-dynamic (~oliva url)
- target->define_tls_base_symbol(symtab, layout);
- if (optimized_type == tls::TLSOPT_NONE)
- {
- // Create a double GOT entry with an R_386_TLS_DESC
- // reloc. The R_386_TLS_DESC reloc is resolved
- // lazily, so the GOT entry needs to be in an area in
- // .got.plt, not .got. Call got_section to make sure
- // the section has been created.
- target->got_section(symtab, layout);
- Output_data_got<32, false>* got = target->got_tlsdesc_section();
- Reloc_section* rt = target->rel_tls_desc_section(layout);
- got->add_global_pair_with_rel(gsym, GOT_TYPE_TLS_DESC, rt,
- elfcpp::R_386_TLS_DESC, 0);
- }
- else if (optimized_type == tls::TLSOPT_TO_IE)
- {
- // Create a GOT entry for the tp-relative offset.
- Output_data_got<32, false>* got
- = target->got_section(symtab, layout);
- got->add_global_with_rel(gsym, GOT_TYPE_TLS_NOFFSET,
- target->rel_dyn_section(layout),
- elfcpp::R_386_TLS_TPOFF);
- }
- else if (optimized_type != tls::TLSOPT_TO_LE)
- unsupported_reloc_global(object, r_type, gsym);
- break;
-
- case elfcpp::R_386_TLS_DESC_CALL:
- break;
-
- case elfcpp::R_386_TLS_LDM: // Local-dynamic
- if (optimized_type == tls::TLSOPT_NONE)
- {
- // Create a GOT entry for the module index.
- target->got_mod_index_entry(symtab, layout, object);
- }
- else if (optimized_type != tls::TLSOPT_TO_LE)
- unsupported_reloc_global(object, r_type, gsym);
- break;
-
- case elfcpp::R_386_TLS_LDO_32: // Alternate local-dynamic
- break;
-
- case elfcpp::R_386_TLS_IE: // Initial-exec
- case elfcpp::R_386_TLS_IE_32:
- case elfcpp::R_386_TLS_GOTIE:
- layout->set_has_static_tls();
- if (optimized_type == tls::TLSOPT_NONE)
- {
- // For the R_386_TLS_IE relocation, we need to create a
- // dynamic relocation when building a shared library.
- if (r_type == elfcpp::R_386_TLS_IE
- && parameters->options().shared())
- {
- Reloc_section* rel_dyn = target->rel_dyn_section(layout);
- rel_dyn->add_global_relative(gsym, elfcpp::R_386_RELATIVE,
- output_section, object,
- data_shndx,
- reloc.get_r_offset());
- }
- // Create a GOT entry for the tp-relative offset.
- Output_data_got<32, false>* got
- = target->got_section(symtab, layout);
- unsigned int dyn_r_type = (r_type == elfcpp::R_386_TLS_IE_32
- ? elfcpp::R_386_TLS_TPOFF32
- : elfcpp::R_386_TLS_TPOFF);
- unsigned int got_type = (r_type == elfcpp::R_386_TLS_IE_32
- ? GOT_TYPE_TLS_OFFSET
- : GOT_TYPE_TLS_NOFFSET);
- got->add_global_with_rel(gsym, got_type,
- target->rel_dyn_section(layout),
- dyn_r_type);
- }
- else if (optimized_type != tls::TLSOPT_TO_LE)
- unsupported_reloc_global(object, r_type, gsym);
- break;
-
- case elfcpp::R_386_TLS_LE: // Local-exec
- case elfcpp::R_386_TLS_LE_32:
- layout->set_has_static_tls();
- if (parameters->options().shared())
- {
- // We need to create a dynamic relocation.
- unsigned int dyn_r_type = (r_type == elfcpp::R_386_TLS_LE_32
- ? elfcpp::R_386_TLS_TPOFF32
- : elfcpp::R_386_TLS_TPOFF);
- Reloc_section* rel_dyn = target->rel_dyn_section(layout);
- rel_dyn->add_global(gsym, dyn_r_type, output_section, object,
- data_shndx, reloc.get_r_offset());
- }
- break;
-
- default:
- gold_unreachable();
- }
- }
- break;
-
- case elfcpp::R_386_32PLT:
- case elfcpp::R_386_TLS_GD_32:
- case elfcpp::R_386_TLS_GD_PUSH:
- case elfcpp::R_386_TLS_GD_CALL:
- case elfcpp::R_386_TLS_GD_POP:
- case elfcpp::R_386_TLS_LDM_32:
- case elfcpp::R_386_TLS_LDM_PUSH:
- case elfcpp::R_386_TLS_LDM_CALL:
- case elfcpp::R_386_TLS_LDM_POP:
- case elfcpp::R_386_USED_BY_INTEL_200:
- default:
- unsupported_reloc_global(object, r_type, gsym);
- break;
- }
-}
-
-// Process relocations for gc.
-
-void
-Target_i386::gc_process_relocs(Symbol_table* symtab,
- Layout* layout,
- Sized_relobj_file<32, false>* object,
- unsigned int data_shndx,
- unsigned int,
- const unsigned char* prelocs,
- size_t reloc_count,
- Output_section* output_section,
- bool needs_special_offset_handling,
- size_t local_symbol_count,
- const unsigned char* plocal_symbols)
-{
- gold::gc_process_relocs<32, false, Target_i386, Scan, Classify_reloc>(
- symtab,
- layout,
- this,
- object,
- data_shndx,
- prelocs,
- reloc_count,
- output_section,
- needs_special_offset_handling,
- local_symbol_count,
- plocal_symbols);
-}
-
-// Scan relocations for a section.
-
-void
-Target_i386::scan_relocs(Symbol_table* symtab,
- Layout* layout,
- Sized_relobj_file<32, false>* object,
- unsigned int data_shndx,
- unsigned int sh_type,
- const unsigned char* prelocs,
- size_t reloc_count,
- Output_section* output_section,
- bool needs_special_offset_handling,
- size_t local_symbol_count,
- const unsigned char* plocal_symbols)
-{
- if (sh_type == elfcpp::SHT_RELA)
- {
- gold_error(_("%s: unsupported RELA reloc section"),
- object->name().c_str());
- return;
- }
-
- gold::scan_relocs<32, false, Target_i386, Scan, Classify_reloc>(
- symtab,
- layout,
- this,
- object,
- data_shndx,
- prelocs,
- reloc_count,
- output_section,
- needs_special_offset_handling,
- local_symbol_count,
- plocal_symbols);
-}
-
-// Finalize the sections.
-
-void
-Target_i386::do_finalize_sections(
- Layout* layout,
- const Input_objects*,
- Symbol_table* symtab)
-{
- const Reloc_section* rel_plt = (this->plt_ == NULL
- ? NULL
- : this->plt_->rel_plt());
- layout->add_target_dynamic_tags(true, this->got_plt_, rel_plt,
- this->rel_dyn_, true, false, false);
-
- // Emit any relocs we saved in an attempt to avoid generating COPY
- // relocs.
- if (this->copy_relocs_.any_saved_relocs())
- this->copy_relocs_.emit(this->rel_dyn_section(layout));
-
- // Set the size of the _GLOBAL_OFFSET_TABLE_ symbol to the size of
- // the .got.plt section.
- Symbol* sym = this->global_offset_table_;
- if (sym != NULL)
- {
- uint32_t data_size = this->got_plt_->current_data_size();
- symtab->get_sized_symbol<32>(sym)->set_symsize(data_size);
- }
-
- if (parameters->doing_static_link()
- && (this->plt_ == NULL || !this->plt_->has_irelative_section()))
- {
- // If linking statically, make sure that the __rel_iplt symbols
- // were defined if necessary, even if we didn't create a PLT.
- static const Define_symbol_in_segment syms[] =
- {
- {
- "__rel_iplt_start", // name
- elfcpp::PT_LOAD, // segment_type
- elfcpp::PF_W, // segment_flags_set
- elfcpp::PF(0), // segment_flags_clear
- 0, // value
- 0, // size
- elfcpp::STT_NOTYPE, // type
- elfcpp::STB_GLOBAL, // binding
- elfcpp::STV_HIDDEN, // visibility
- 0, // nonvis
- Symbol::SEGMENT_START, // offset_from_base
- true // only_if_ref
- },
- {
- "__rel_iplt_end", // name
- elfcpp::PT_LOAD, // segment_type
- elfcpp::PF_W, // segment_flags_set
- elfcpp::PF(0), // segment_flags_clear
- 0, // value
- 0, // size
- elfcpp::STT_NOTYPE, // type
- elfcpp::STB_GLOBAL, // binding
- elfcpp::STV_HIDDEN, // visibility
- 0, // nonvis
- Symbol::SEGMENT_START, // offset_from_base
- true // only_if_ref
- }
- };
-
- symtab->define_symbols(layout, 2, syms,
- layout->script_options()->saw_sections_clause());
- }
-}
-
-// Return whether a direct absolute static relocation needs to be applied.
-// In cases where Scan::local() or Scan::global() has created
-// a dynamic relocation other than R_386_RELATIVE, the addend
-// of the relocation is carried in the data, and we must not
-// apply the static relocation.
-
-inline bool
-Target_i386::Relocate::should_apply_static_reloc(const Sized_symbol<32>* gsym,
- unsigned int r_type,
- bool is_32bit,
- Output_section* output_section)
-{
- // If the output section is not allocated, then we didn't call
- // scan_relocs, we didn't create a dynamic reloc, and we must apply
- // the reloc here.
- if ((output_section->flags() & elfcpp::SHF_ALLOC) == 0)
- return true;
-
- int ref_flags = Scan::get_reference_flags(r_type);
-
- // For local symbols, we will have created a non-RELATIVE dynamic
- // relocation only if (a) the output is position independent,
- // (b) the relocation is absolute (not pc- or segment-relative), and
- // (c) the relocation is not 32 bits wide.
- if (gsym == NULL)
- return !(parameters->options().output_is_position_independent()
- && (ref_flags & Symbol::ABSOLUTE_REF)
- && !is_32bit);
-
- // For global symbols, we use the same helper routines used in the
- // scan pass. If we did not create a dynamic relocation, or if we
- // created a RELATIVE dynamic relocation, we should apply the static
- // relocation.
- bool has_dyn = gsym->needs_dynamic_reloc(ref_flags);
- bool is_rel = (ref_flags & Symbol::ABSOLUTE_REF)
- && gsym->can_use_relative_reloc(ref_flags
- & Symbol::FUNCTION_CALL);
- return !has_dyn || is_rel;
-}
-
-// Perform a relocation.
-
-inline bool
-Target_i386::Relocate::relocate(const Relocate_info<32, false>* relinfo,
- unsigned int,
- Target_i386* target,
- Output_section* output_section,
- size_t relnum,
- const unsigned char* preloc,
- const Sized_symbol<32>* gsym,
- const Symbol_value<32>* psymval,
- unsigned char* view,
- elfcpp::Elf_types<32>::Elf_Addr address,
- section_size_type view_size)
-{
- const elfcpp::Rel<32, false> rel(preloc);
- unsigned int r_type = elfcpp::elf_r_type<32>(rel.get_r_info());
-
- if (this->skip_call_tls_get_addr_)
- {
- if ((r_type != elfcpp::R_386_PLT32
- && r_type != elfcpp::R_386_GOT32X
- && r_type != elfcpp::R_386_PC32)
- || gsym == NULL
- || strcmp(gsym->name(), "___tls_get_addr") != 0)
- {
- gold_error_at_location(relinfo, relnum, rel.get_r_offset(),
- _("missing expected TLS relocation"));
- this->skip_call_tls_get_addr_ = false;
- }
- else
- {
- this->skip_call_tls_get_addr_ = false;
- return false;
- }
- }
-
- if (view == NULL)
- return true;
-
- const Sized_relobj_file<32, false>* object = relinfo->object;
-
- // Pick the value to use for symbols defined in shared objects.
- Symbol_value<32> symval;
- if (gsym != NULL
- && gsym->type() == elfcpp::STT_GNU_IFUNC
- && r_type == elfcpp::R_386_32
- && gsym->needs_dynamic_reloc(Scan::get_reference_flags(r_type))
- && gsym->can_use_relative_reloc(false)
- && !gsym->is_from_dynobj()
- && !gsym->is_undefined()
- && !gsym->is_preemptible())
- {
- // In this case we are generating a R_386_IRELATIVE reloc. We
- // want to use the real value of the symbol, not the PLT offset.
- }
- else if (gsym != NULL
- && gsym->use_plt_offset(Scan::get_reference_flags(r_type)))
- {
- symval.set_output_value(target->plt_address_for_global(gsym));
- psymval = &symval;
- }
- else if (gsym == NULL && psymval->is_ifunc_symbol())
- {
- unsigned int r_sym = elfcpp::elf_r_sym<32>(rel.get_r_info());
- if (object->local_has_plt_offset(r_sym))
- {
- symval.set_output_value(target->plt_address_for_local(object, r_sym));
- psymval = &symval;
- }
- }
-
- bool baseless;
-
- switch (r_type)
- {
- case elfcpp::R_386_NONE:
- case elfcpp::R_386_GNU_VTINHERIT:
- case elfcpp::R_386_GNU_VTENTRY:
- break;
-
- case elfcpp::R_386_32:
- if (should_apply_static_reloc(gsym, r_type, true, output_section))
- Relocate_functions<32, false>::rel32(view, object, psymval);
- break;
-
- case elfcpp::R_386_PC32:
- if (should_apply_static_reloc(gsym, r_type, true, output_section))
- Relocate_functions<32, false>::pcrel32(view, object, psymval, address);
- break;
-
- case elfcpp::R_386_16:
- if (should_apply_static_reloc(gsym, r_type, false, output_section))
- Relocate_functions<32, false>::rel16(view, object, psymval);
- break;
-
- case elfcpp::R_386_PC16:
- if (should_apply_static_reloc(gsym, r_type, false, output_section))
- Relocate_functions<32, false>::pcrel16(view, object, psymval, address);
- break;
-
- case elfcpp::R_386_8:
- if (should_apply_static_reloc(gsym, r_type, false, output_section))
- Relocate_functions<32, false>::rel8(view, object, psymval);
- break;
-
- case elfcpp::R_386_PC8:
- if (should_apply_static_reloc(gsym, r_type, false, output_section))
- Relocate_functions<32, false>::pcrel8(view, object, psymval, address);
- break;
-
- case elfcpp::R_386_PLT32:
- gold_assert(gsym == NULL
- || gsym->has_plt_offset()
- || gsym->final_value_is_known()
- || (gsym->is_defined()
- && !gsym->is_from_dynobj()
- && !gsym->is_preemptible()));
- Relocate_functions<32, false>::pcrel32(view, object, psymval, address);
- break;
-
- case elfcpp::R_386_GOT32:
- case elfcpp::R_386_GOT32X:
- baseless = (view[-1] & 0xc7) == 0x5;
- // R_386_GOT32 and R_386_GOT32X don't work without base register
- // when generating a position-independent output file.
- if (baseless
- && parameters->options().output_is_position_independent())
- {
- if(gsym)
- gold_error_at_location(relinfo, relnum, rel.get_r_offset(),
- _("unexpected reloc %u against global symbol %s without base register in object file when generating a position-independent output file"),
- r_type, gsym->demangled_name().c_str());
- else
- gold_error_at_location(relinfo, relnum, rel.get_r_offset(),
- _("unexpected reloc %u against local symbol without base register in object file when generating a position-independent output file"),
- r_type);
- }
-
- // Convert
- // mov foo@GOT(%reg), %reg
- // to
- // lea foo@GOTOFF(%reg), %reg
- // if possible.
- if (rel.get_r_offset() >= 2
- && view[-2] == 0x8b
- && ((gsym == NULL && !psymval->is_ifunc_symbol())
- || (gsym != NULL
- && Target_i386::can_convert_mov_to_lea(gsym))))
- {
- view[-2] = 0x8d;
- elfcpp::Elf_types<32>::Elf_Addr value;
- value = psymval->value(object, 0);
- // Don't subtract the .got.plt section address for baseless
- // addressing.
- if (!baseless)
- value -= target->got_plt_section()->address();
- Relocate_functions<32, false>::rel32(view, value);
- }
- else
- {
- // The GOT pointer points to the end of the GOT section.
- // We need to subtract the size of the GOT section to get
- // the actual offset to use in the relocation.
- unsigned int got_offset = 0;
- if (gsym != NULL)
- {
- gold_assert(gsym->has_got_offset(GOT_TYPE_STANDARD));
- got_offset = (gsym->got_offset(GOT_TYPE_STANDARD)
- - target->got_size());
- }
- else
- {
- unsigned int r_sym = elfcpp::elf_r_sym<32>(rel.get_r_info());
- gold_assert(object->local_has_got_offset(r_sym, GOT_TYPE_STANDARD));
- got_offset = (object->local_got_offset(r_sym, GOT_TYPE_STANDARD)
- - target->got_size());
- }
- // Add the .got.plt section address for baseless addressing.
- if (baseless)
- got_offset += target->got_plt_section()->address();
- Relocate_functions<32, false>::rel32(view, got_offset);
- }
- break;
-
- case elfcpp::R_386_GOTOFF:
- {
- elfcpp::Elf_types<32>::Elf_Addr reladdr;
- reladdr = target->got_plt_section()->address();
- Relocate_functions<32, false>::pcrel32(view, object, psymval, reladdr);
- }
- break;
-
- case elfcpp::R_386_GOTPC:
- {
- elfcpp::Elf_types<32>::Elf_Addr value;
- value = target->got_plt_section()->address();
- Relocate_functions<32, false>::pcrel32(view, value, address);
- }
- break;
-
- case elfcpp::R_386_COPY:
- case elfcpp::R_386_GLOB_DAT:
- case elfcpp::R_386_JUMP_SLOT:
- case elfcpp::R_386_RELATIVE:
- case elfcpp::R_386_IRELATIVE:
- // These are outstanding tls relocs, which are unexpected when
- // linking.
- case elfcpp::R_386_TLS_TPOFF:
- case elfcpp::R_386_TLS_DTPMOD32:
- case elfcpp::R_386_TLS_DTPOFF32:
- case elfcpp::R_386_TLS_TPOFF32:
- case elfcpp::R_386_TLS_DESC:
- gold_error_at_location(relinfo, relnum, rel.get_r_offset(),
- _("unexpected reloc %u in object file"),
- r_type);
- break;
-
- // These are initial tls relocs, which are expected when
- // linking.
- case elfcpp::R_386_TLS_GD: // Global-dynamic
- case elfcpp::R_386_TLS_GOTDESC: // Global-dynamic (from ~oliva url)
- case elfcpp::R_386_TLS_DESC_CALL:
- case elfcpp::R_386_TLS_LDM: // Local-dynamic
- case elfcpp::R_386_TLS_LDO_32: // Alternate local-dynamic
- case elfcpp::R_386_TLS_IE: // Initial-exec
- case elfcpp::R_386_TLS_IE_32:
- case elfcpp::R_386_TLS_GOTIE:
- case elfcpp::R_386_TLS_LE: // Local-exec
- case elfcpp::R_386_TLS_LE_32:
- this->relocate_tls(relinfo, target, relnum, rel, r_type, gsym, psymval,
- view, address, view_size);
- break;
-
- case elfcpp::R_386_32PLT:
- case elfcpp::R_386_TLS_GD_32:
- case elfcpp::R_386_TLS_GD_PUSH:
- case elfcpp::R_386_TLS_GD_CALL:
- case elfcpp::R_386_TLS_GD_POP:
- case elfcpp::R_386_TLS_LDM_32:
- case elfcpp::R_386_TLS_LDM_PUSH:
- case elfcpp::R_386_TLS_LDM_CALL:
- case elfcpp::R_386_TLS_LDM_POP:
- case elfcpp::R_386_USED_BY_INTEL_200:
- default:
- gold_error_at_location(relinfo, relnum, rel.get_r_offset(),
- _("unsupported reloc %u"),
- r_type);
- break;
- }
-
- return true;
-}
-
-// Perform a TLS relocation.
-
-inline void
-Target_i386::Relocate::relocate_tls(const Relocate_info<32, false>* relinfo,
- Target_i386* target,
- size_t relnum,
- const elfcpp::Rel<32, false>& rel,
- unsigned int r_type,
- const Sized_symbol<32>* gsym,
- const Symbol_value<32>* psymval,
- unsigned char* view,
- elfcpp::Elf_types<32>::Elf_Addr,
- section_size_type view_size)
-{
- Output_segment* tls_segment = relinfo->layout->tls_segment();
-
- const Sized_relobj_file<32, false>* object = relinfo->object;
-
- elfcpp::Elf_types<32>::Elf_Addr value = psymval->value(object, 0);
-
- const bool is_final = (gsym == NULL
- ? !parameters->options().shared()
- : gsym->final_value_is_known());
- const tls::Tls_optimization optimized_type
- = Target_i386::optimize_tls_reloc(is_final, r_type);
- switch (r_type)
- {
- case elfcpp::R_386_TLS_GD: // Global-dynamic
- if (optimized_type == tls::TLSOPT_TO_LE)
- {
- if (tls_segment == NULL)
- {
- gold_assert(parameters->errors()->error_count() > 0
- || issue_undefined_symbol_error(gsym));
- return;
- }
- this->tls_gd_to_le(relinfo, relnum, tls_segment,
- rel, r_type, value, view,
- view_size);
- break;
- }
- else
- {
- unsigned int got_type = (optimized_type == tls::TLSOPT_TO_IE
- ? GOT_TYPE_TLS_NOFFSET
- : GOT_TYPE_TLS_PAIR);
- unsigned int got_offset;
- if (gsym != NULL)
- {
- gold_assert(gsym->has_got_offset(got_type));
- got_offset = gsym->got_offset(got_type) - target->got_size();
- }
- else
- {
- unsigned int r_sym = elfcpp::elf_r_sym<32>(rel.get_r_info());
- gold_assert(object->local_has_got_offset(r_sym, got_type));
- got_offset = (object->local_got_offset(r_sym, got_type)
- - target->got_size());
- }
- if (optimized_type == tls::TLSOPT_TO_IE)
- {
- this->tls_gd_to_ie(relinfo, relnum, rel, r_type,
- got_offset, view, view_size);
- break;
- }
- else if (optimized_type == tls::TLSOPT_NONE)
- {
- // Relocate the field with the offset of the pair of GOT
- // entries.
- Relocate_functions<32, false>::rel32(view, got_offset);
- break;
- }
- }
- gold_error_at_location(relinfo, relnum, rel.get_r_offset(),
- _("unsupported reloc %u"),
- r_type);
- break;
-
- case elfcpp::R_386_TLS_GOTDESC: // Global-dynamic (from ~oliva url)
- case elfcpp::R_386_TLS_DESC_CALL:
- this->local_dynamic_type_ = LOCAL_DYNAMIC_GNU;
- if (optimized_type == tls::TLSOPT_TO_LE)
- {
- if (tls_segment == NULL)
- {
- gold_assert(parameters->errors()->error_count() > 0
- || issue_undefined_symbol_error(gsym));
- return;
- }
- this->tls_desc_gd_to_le(relinfo, relnum, tls_segment,
- rel, r_type, value, view,
- view_size);
- break;
- }
- else
- {
- unsigned int got_type = (optimized_type == tls::TLSOPT_TO_IE
- ? GOT_TYPE_TLS_NOFFSET
- : GOT_TYPE_TLS_DESC);
- unsigned int got_offset = 0;
- if (r_type == elfcpp::R_386_TLS_GOTDESC
- && optimized_type == tls::TLSOPT_NONE)
- {
- // We created GOT entries in the .got.tlsdesc portion of
- // the .got.plt section, but the offset stored in the
- // symbol is the offset within .got.tlsdesc.
- got_offset = (target->got_size()
- + target->got_plt_section()->data_size());
- }
- if (gsym != NULL)
- {
- gold_assert(gsym->has_got_offset(got_type));
- got_offset += gsym->got_offset(got_type) - target->got_size();
- }
- else
- {
- unsigned int r_sym = elfcpp::elf_r_sym<32>(rel.get_r_info());
- gold_assert(object->local_has_got_offset(r_sym, got_type));
- got_offset += (object->local_got_offset(r_sym, got_type)
- - target->got_size());
- }
- if (optimized_type == tls::TLSOPT_TO_IE)
- {
- this->tls_desc_gd_to_ie(relinfo, relnum, rel, r_type,
- got_offset, view, view_size);
- break;
- }
- else if (optimized_type == tls::TLSOPT_NONE)
- {
- if (r_type == elfcpp::R_386_TLS_GOTDESC)
- {
- // Relocate the field with the offset of the pair of GOT
- // entries.
- Relocate_functions<32, false>::rel32(view, got_offset);
- }
- break;
- }
- }
- gold_error_at_location(relinfo, relnum, rel.get_r_offset(),
- _("unsupported reloc %u"),
- r_type);
- break;
-
- case elfcpp::R_386_TLS_LDM: // Local-dynamic
- if (this->local_dynamic_type_ == LOCAL_DYNAMIC_SUN)
- {
- gold_error_at_location(relinfo, relnum, rel.get_r_offset(),
- _("both SUN and GNU model "
- "TLS relocations"));
- break;
- }
- this->local_dynamic_type_ = LOCAL_DYNAMIC_GNU;
- if (optimized_type == tls::TLSOPT_TO_LE)
- {
- if (tls_segment == NULL)
- {
- gold_assert(parameters->errors()->error_count() > 0
- || issue_undefined_symbol_error(gsym));
- return;
- }
- this->tls_ld_to_le(relinfo, relnum, tls_segment, rel, r_type,
- value, view, view_size);
- break;
- }
- else if (optimized_type == tls::TLSOPT_NONE)
- {
- // Relocate the field with the offset of the GOT entry for
- // the module index.
- unsigned int got_offset;
- got_offset = (target->got_mod_index_entry(NULL, NULL, NULL)
- - target->got_size());
- Relocate_functions<32, false>::rel32(view, got_offset);
- break;
- }
- gold_error_at_location(relinfo, relnum, rel.get_r_offset(),
- _("unsupported reloc %u"),
- r_type);
- break;
-
- case elfcpp::R_386_TLS_LDO_32: // Alternate local-dynamic
- if (optimized_type == tls::TLSOPT_TO_LE)
- {
- // This reloc can appear in debugging sections, in which
- // case we must not convert to local-exec. We decide what
- // to do based on whether the section is marked as
- // containing executable code. That is what the GNU linker
- // does as well.
- elfcpp::Shdr<32, false> shdr(relinfo->data_shdr);
- if ((shdr.get_sh_flags() & elfcpp::SHF_EXECINSTR) != 0)
- {
- if (tls_segment == NULL)
- {
- gold_assert(parameters->errors()->error_count() > 0
- || issue_undefined_symbol_error(gsym));
- return;
- }
- value -= tls_segment->memsz();
- }
- }
- Relocate_functions<32, false>::rel32(view, value);
- break;
-
- case elfcpp::R_386_TLS_IE: // Initial-exec
- case elfcpp::R_386_TLS_GOTIE:
- case elfcpp::R_386_TLS_IE_32:
- if (optimized_type == tls::TLSOPT_TO_LE)
- {
- if (tls_segment == NULL)
- {
- gold_assert(parameters->errors()->error_count() > 0
- || issue_undefined_symbol_error(gsym));
- return;
- }
- Target_i386::Relocate::tls_ie_to_le(relinfo, relnum, tls_segment,
- rel, r_type, value, view,
- view_size);
- break;
- }
- else if (optimized_type == tls::TLSOPT_NONE)
- {
- // Relocate the field with the offset of the GOT entry for
- // the tp-relative offset of the symbol.
- unsigned int got_type = (r_type == elfcpp::R_386_TLS_IE_32
- ? GOT_TYPE_TLS_OFFSET
- : GOT_TYPE_TLS_NOFFSET);
- unsigned int got_offset;
- if (gsym != NULL)
- {
- gold_assert(gsym->has_got_offset(got_type));
- got_offset = gsym->got_offset(got_type);
- }
- else
- {
- unsigned int r_sym = elfcpp::elf_r_sym<32>(rel.get_r_info());
- gold_assert(object->local_has_got_offset(r_sym, got_type));
- got_offset = object->local_got_offset(r_sym, got_type);
- }
- // For the R_386_TLS_IE relocation, we need to apply the
- // absolute address of the GOT entry.
- if (r_type == elfcpp::R_386_TLS_IE)
- got_offset += target->got_plt_section()->address();
- // All GOT offsets are relative to the end of the GOT.
- got_offset -= target->got_size();
- Relocate_functions<32, false>::rel32(view, got_offset);
- break;
- }
- gold_error_at_location(relinfo, relnum, rel.get_r_offset(),
- _("unsupported reloc %u"),
- r_type);
- break;
-
- case elfcpp::R_386_TLS_LE: // Local-exec
- // If we're creating a shared library, a dynamic relocation will
- // have been created for this location, so do not apply it now.
- if (!parameters->options().shared())
- {
- if (tls_segment == NULL)
- {
- gold_assert(parameters->errors()->error_count() > 0
- || issue_undefined_symbol_error(gsym));
- return;
- }
- value -= tls_segment->memsz();
- Relocate_functions<32, false>::rel32(view, value);
- }
- break;
-
- case elfcpp::R_386_TLS_LE_32:
- // If we're creating a shared library, a dynamic relocation will
- // have been created for this location, so do not apply it now.
- if (!parameters->options().shared())
- {
- if (tls_segment == NULL)
- {
- gold_assert(parameters->errors()->error_count() > 0
- || issue_undefined_symbol_error(gsym));
- return;
- }
- value = tls_segment->memsz() - value;
- Relocate_functions<32, false>::rel32(view, value);
- }
- break;
- }
-}
-
-// Do a relocation in which we convert a TLS General-Dynamic to a
-// Local-Exec.
-
-inline void
-Target_i386::Relocate::tls_gd_to_le(const Relocate_info<32, false>* relinfo,
- size_t relnum,
- Output_segment* tls_segment,
- const elfcpp::Rel<32, false>& rel,
- unsigned int,
- elfcpp::Elf_types<32>::Elf_Addr value,
- unsigned char* view,
- section_size_type view_size)
-{
- // leal foo(,%ebx,1),%eax; call ___tls_get_addr@PLT
- // ==> movl %gs:0,%eax; subl $foo@tpoff,%eax
- // leal foo(%ebx),%eax; call ___tls_get_addr@PLT
- // ==> movl %gs:0,%eax; subl $foo@tpoff,%eax
- // leal foo(%reg),%eax; call *___tls_get_addr@GOT(%reg)
- // ==> movl %gs:0,%eax; subl $foo@tpoff,%eax
-
- tls::check_range(relinfo, relnum, rel.get_r_offset(), view_size, -2);
- tls::check_range(relinfo, relnum, rel.get_r_offset(), view_size, 9);
-
- unsigned char op1 = view[-1];
- unsigned char op2 = view[-2];
- unsigned char op3 = view[4];
-
- tls::check_tls(relinfo, relnum, rel.get_r_offset(),
- op2 == 0x8d || op2 == 0x04);
- tls::check_tls(relinfo, relnum, rel.get_r_offset(),
- op3 == 0xe8 || op3 == 0xff);
-
- int roff = 5;
-
- if (op2 == 0x04)
- {
- tls::check_range(relinfo, relnum, rel.get_r_offset(), view_size, -3);
- tls::check_tls(relinfo, relnum, rel.get_r_offset(), view[-3] == 0x8d);
- tls::check_tls(relinfo, relnum, rel.get_r_offset(),
- ((op1 & 0xc7) == 0x05 && op1 != (4 << 3)));
- memcpy(view - 3, "\x65\xa1\0\0\0\0\x81\xe8\0\0\0", 12);
- }
- else
- {
- unsigned char reg = op1 & 7;
- tls::check_tls(relinfo, relnum, rel.get_r_offset(),
- ((op1 & 0xf8) == 0x80
- && reg != 4
- && reg != 0
- && (op3 == 0xe8 || (view[5] & 0x7) == reg)));
- if (op3 == 0xff
- || (rel.get_r_offset() + 9 < view_size
- && view[9] == 0x90))
- {
- // There is an indirect call or a trailing nop. Use the size
- // byte subl.
- memcpy(view - 2, "\x65\xa1\0\0\0\0\x81\xe8\0\0\0", 12);
- roff = 6;
- }
- else
- {
- // Use the five byte subl.
- memcpy(view - 2, "\x65\xa1\0\0\0\0\x2d\0\0\0", 11);
- }
- }
-
- value = tls_segment->memsz() - value;
- Relocate_functions<32, false>::rel32(view + roff, value);
-
- // The next reloc should be a PLT32 reloc against __tls_get_addr.
- // We can skip it.
- this->skip_call_tls_get_addr_ = true;
-}
-
-// Do a relocation in which we convert a TLS General-Dynamic to an
-// Initial-Exec.
-
-inline void
-Target_i386::Relocate::tls_gd_to_ie(const Relocate_info<32, false>* relinfo,
- size_t relnum,
- const elfcpp::Rel<32, false>& rel,
- unsigned int,
- elfcpp::Elf_types<32>::Elf_Addr value,
- unsigned char* view,
- section_size_type view_size)
-{
- // leal foo(,%ebx,1),%eax; call ___tls_get_addr@PLT
- // ==> movl %gs:0,%eax; addl foo@gotntpoff(%ebx),%eax
- // leal foo(%ebx),%eax; call ___tls_get_addr@PLT; nop
- // ==> movl %gs:0,%eax; addl foo@gotntpoff(%ebx),%eax
- // leal foo(%reg),%eax; call *___tls_get_addr@GOT(%reg)
- // ==> movl %gs:0,%eax; addl foo@gotntpoff(%reg),%eax
-
- tls::check_range(relinfo, relnum, rel.get_r_offset(), view_size, -2);
- tls::check_range(relinfo, relnum, rel.get_r_offset(), view_size, 9);
-
- unsigned char op1 = view[-1];
- unsigned char op2 = view[-2];
- unsigned char op3 = view[4];
-
- tls::check_tls(relinfo, relnum, rel.get_r_offset(),
- op2 == 0x8d || op2 == 0x04);
- tls::check_tls(relinfo, relnum, rel.get_r_offset(),
- op3 == 0xe8 || op3 == 0xff);
-
- int roff;
-
- if (op2 == 0x04)
- {
- tls::check_range(relinfo, relnum, rel.get_r_offset(), view_size, -3);
- tls::check_tls(relinfo, relnum, rel.get_r_offset(), view[-3] == 0x8d);
- tls::check_tls(relinfo, relnum, rel.get_r_offset(),
- ((op1 & 0xc7) == 0x05 && op1 != (4 << 3)));
- roff = 5;
- }
- else
- {
- unsigned char reg = op1 & 7;
- tls::check_range(relinfo, relnum, rel.get_r_offset(), view_size, 10);
- tls::check_tls(relinfo, relnum, rel.get_r_offset(),
- ((op1 & 0xf8) == 0x80
- && reg != 4
- && reg != 0
- && ((op3 == 0xe8 && view[9] == 0x90)
- || (view[5] & 0x7) == reg)));
- roff = 6;
- }
-
- memcpy(view + roff - 8, "\x65\xa1\0\0\0\0\x03\x83\0\0\0", 12);
- Relocate_functions<32, false>::rel32(view + roff, value);
-
- // The next reloc should be a PLT32 reloc against __tls_get_addr.
- // We can skip it.
- this->skip_call_tls_get_addr_ = true;
-}
-
-// Do a relocation in which we convert a TLS_GOTDESC or TLS_DESC_CALL
-// General-Dynamic to a Local-Exec.
-
-inline void
-Target_i386::Relocate::tls_desc_gd_to_le(
- const Relocate_info<32, false>* relinfo,
- size_t relnum,
- Output_segment* tls_segment,
- const elfcpp::Rel<32, false>& rel,
- unsigned int r_type,
- elfcpp::Elf_types<32>::Elf_Addr value,
- unsigned char* view,
- section_size_type view_size)
-{
- if (r_type == elfcpp::R_386_TLS_GOTDESC)
- {
- // leal foo@TLSDESC(%ebx), %eax
- // ==> leal foo@NTPOFF, %eax
- tls::check_range(relinfo, relnum, rel.get_r_offset(), view_size, -2);
- tls::check_range(relinfo, relnum, rel.get_r_offset(), view_size, 4);
- tls::check_tls(relinfo, relnum, rel.get_r_offset(),
- view[-2] == 0x8d && view[-1] == 0x83);
- view[-1] = 0x05;
- value -= tls_segment->memsz();
- Relocate_functions<32, false>::rel32(view, value);
- }
- else
- {
- // call *foo@TLSCALL(%eax)
- // ==> nop; nop
- gold_assert(r_type == elfcpp::R_386_TLS_DESC_CALL);
- tls::check_range(relinfo, relnum, rel.get_r_offset(), view_size, 2);
- tls::check_tls(relinfo, relnum, rel.get_r_offset(),
- view[0] == 0xff && view[1] == 0x10);
- view[0] = 0x66;
- view[1] = 0x90;
- }
-}
-
-// Do a relocation in which we convert a TLS_GOTDESC or TLS_DESC_CALL
-// General-Dynamic to an Initial-Exec.
-
-inline void
-Target_i386::Relocate::tls_desc_gd_to_ie(
- const Relocate_info<32, false>* relinfo,
- size_t relnum,
- const elfcpp::Rel<32, false>& rel,
- unsigned int r_type,
- elfcpp::Elf_types<32>::Elf_Addr value,
- unsigned char* view,
- section_size_type view_size)
-{
- if (r_type == elfcpp::R_386_TLS_GOTDESC)
- {
- // leal foo@TLSDESC(%ebx), %eax
- // ==> movl foo@GOTNTPOFF(%ebx), %eax
- tls::check_range(relinfo, relnum, rel.get_r_offset(), view_size, -2);
- tls::check_range(relinfo, relnum, rel.get_r_offset(), view_size, 4);
- tls::check_tls(relinfo, relnum, rel.get_r_offset(),
- view[-2] == 0x8d && view[-1] == 0x83);
- view[-2] = 0x8b;
- Relocate_functions<32, false>::rel32(view, value);
- }
- else
- {
- // call *foo@TLSCALL(%eax)
- // ==> nop; nop
- gold_assert(r_type == elfcpp::R_386_TLS_DESC_CALL);
- tls::check_range(relinfo, relnum, rel.get_r_offset(), view_size, 2);
- tls::check_tls(relinfo, relnum, rel.get_r_offset(),
- view[0] == 0xff && view[1] == 0x10);
- view[0] = 0x66;
- view[1] = 0x90;
- }
-}
-
-// Do a relocation in which we convert a TLS Local-Dynamic to a
-// Local-Exec.
-
-inline void
-Target_i386::Relocate::tls_ld_to_le(const Relocate_info<32, false>* relinfo,
- size_t relnum,
- Output_segment*,
- const elfcpp::Rel<32, false>& rel,
- unsigned int,
- elfcpp::Elf_types<32>::Elf_Addr,
- unsigned char* view,
- section_size_type view_size)
-{
- // leal foo(%ebx), %eax; call ___tls_get_addr@PLT
- // ==> movl %gs:0,%eax; nop; leal 0(%esi,1),%esi
- // leal foo(%reg), %eax; call call *___tls_get_addr@GOT(%reg)
- // ==> movl %gs:0,%eax; leal (%esi),%esi
-
- tls::check_range(relinfo, relnum, rel.get_r_offset(), view_size, -2);
-
- unsigned char op1 = view[-1];
- unsigned char op2 = view[-2];
- unsigned char op3 = view[4];
-
- tls::check_tls(relinfo, relnum, rel.get_r_offset(),
- op3 == 0xe8 || op3 == 0xff);
- tls::check_range(relinfo, relnum, rel.get_r_offset(), view_size,
- op3 == 0xe8 ? 9 : 10);
-
- // FIXME: Does this test really always pass?
- tls::check_tls(relinfo, relnum, rel.get_r_offset(), op2 == 0x8d);
-
- unsigned char reg = op1 & 7;
- tls::check_tls(relinfo, relnum, rel.get_r_offset(),
- ((op1 & 0xf8) == 0x80
- && reg != 4
- && reg != 0
- && (op3 == 0xe8 || (view[5] & 0x7) == reg)));
-
- if (op3 == 0xe8)
- memcpy(view - 2, "\x65\xa1\0\0\0\0\x90\x8d\x74\x26\0", 11);
- else
- memcpy(view - 2, "\x65\xa1\0\0\0\0\x8d\xb6\0\0\0\0", 12);
-
- // The next reloc should be a PLT32 reloc against __tls_get_addr.
- // We can skip it.
- this->skip_call_tls_get_addr_ = true;
-}
-
-// Do a relocation in which we convert a TLS Initial-Exec to a
-// Local-Exec.
-
-inline void
-Target_i386::Relocate::tls_ie_to_le(const Relocate_info<32, false>* relinfo,
- size_t relnum,
- Output_segment* tls_segment,
- const elfcpp::Rel<32, false>& rel,
- unsigned int r_type,
- elfcpp::Elf_types<32>::Elf_Addr value,
- unsigned char* view,
- section_size_type view_size)
-{
- // We have to actually change the instructions, which means that we
- // need to examine the opcodes to figure out which instruction we
- // are looking at.
- if (r_type == elfcpp::R_386_TLS_IE)
- {
- // movl %gs:XX,%eax ==> movl $YY,%eax
- // movl %gs:XX,%reg ==> movl $YY,%reg
- // addl %gs:XX,%reg ==> addl $YY,%reg
- tls::check_range(relinfo, relnum, rel.get_r_offset(), view_size, -1);
- tls::check_range(relinfo, relnum, rel.get_r_offset(), view_size, 4);
-
- unsigned char op1 = view[-1];
- if (op1 == 0xa1)
- {
- // movl XX,%eax ==> movl $YY,%eax
- view[-1] = 0xb8;
- }
- else
- {
- tls::check_range(relinfo, relnum, rel.get_r_offset(), view_size, -2);
-
- unsigned char op2 = view[-2];
- if (op2 == 0x8b)
- {
- // movl XX,%reg ==> movl $YY,%reg
- tls::check_tls(relinfo, relnum, rel.get_r_offset(),
- (op1 & 0xc7) == 0x05);
- view[-2] = 0xc7;
- view[-1] = 0xc0 | ((op1 >> 3) & 7);
- }
- else if (op2 == 0x03)
- {
- // addl XX,%reg ==> addl $YY,%reg
- tls::check_tls(relinfo, relnum, rel.get_r_offset(),
- (op1 & 0xc7) == 0x05);
- view[-2] = 0x81;
- view[-1] = 0xc0 | ((op1 >> 3) & 7);
- }
- else
- tls::check_tls(relinfo, relnum, rel.get_r_offset(), 0);
- }
- }
- else
- {
- // subl %gs:XX(%reg1),%reg2 ==> subl $YY,%reg2
- // movl %gs:XX(%reg1),%reg2 ==> movl $YY,%reg2
- // addl %gs:XX(%reg1),%reg2 ==> addl $YY,$reg2
- tls::check_range(relinfo, relnum, rel.get_r_offset(), view_size, -2);
- tls::check_range(relinfo, relnum, rel.get_r_offset(), view_size, 4);
-
- unsigned char op1 = view[-1];
- unsigned char op2 = view[-2];
- tls::check_tls(relinfo, relnum, rel.get_r_offset(),
- (op1 & 0xc0) == 0x80 && (op1 & 7) != 4);
- if (op2 == 0x8b)
- {
- // movl %gs:XX(%reg1),%reg2 ==> movl $YY,%reg2
- view[-2] = 0xc7;
- view[-1] = 0xc0 | ((op1 >> 3) & 7);
- }
- else if (op2 == 0x2b)
- {
- // subl %gs:XX(%reg1),%reg2 ==> subl $YY,%reg2
- view[-2] = 0x81;
- view[-1] = 0xe8 | ((op1 >> 3) & 7);
- }
- else if (op2 == 0x03)
- {
- // addl %gs:XX(%reg1),%reg2 ==> addl $YY,$reg2
- view[-2] = 0x81;
- view[-1] = 0xc0 | ((op1 >> 3) & 7);
- }
- else
- tls::check_tls(relinfo, relnum, rel.get_r_offset(), 0);
- }
-
- value = tls_segment->memsz() - value;
- if (r_type == elfcpp::R_386_TLS_IE || r_type == elfcpp::R_386_TLS_GOTIE)
- value = - value;
-
- Relocate_functions<32, false>::rel32(view, value);
-}
-
-// Relocate section data.
-
-void
-Target_i386::relocate_section(const Relocate_info<32, false>* relinfo,
- unsigned int sh_type,
- const unsigned char* prelocs,
- size_t reloc_count,
- Output_section* output_section,
- bool needs_special_offset_handling,
- unsigned char* view,
- elfcpp::Elf_types<32>::Elf_Addr address,
- section_size_type view_size,
- const Reloc_symbol_changes* reloc_symbol_changes)
-{
- gold_assert(sh_type == elfcpp::SHT_REL);
-
- gold::relocate_section<32, false, Target_i386, Relocate,
- gold::Default_comdat_behavior, Classify_reloc>(
- relinfo,
- this,
- prelocs,
- reloc_count,
- output_section,
- needs_special_offset_handling,
- view,
- address,
- view_size,
- reloc_symbol_changes);
-}
-
-// Return the size of a relocation while scanning during a relocatable
-// link.
-
-unsigned int
-Target_i386::Classify_reloc::get_size_for_reloc(
- unsigned int r_type,
- Relobj* object)
-{
- switch (r_type)
- {
- case elfcpp::R_386_NONE:
- case elfcpp::R_386_GNU_VTINHERIT:
- case elfcpp::R_386_GNU_VTENTRY:
- case elfcpp::R_386_TLS_GD: // Global-dynamic
- case elfcpp::R_386_TLS_GOTDESC: // Global-dynamic (from ~oliva url)
- case elfcpp::R_386_TLS_DESC_CALL:
- case elfcpp::R_386_TLS_LDM: // Local-dynamic
- case elfcpp::R_386_TLS_LDO_32: // Alternate local-dynamic
- case elfcpp::R_386_TLS_IE: // Initial-exec
- case elfcpp::R_386_TLS_IE_32:
- case elfcpp::R_386_TLS_GOTIE:
- case elfcpp::R_386_TLS_LE: // Local-exec
- case elfcpp::R_386_TLS_LE_32:
- return 0;
-
- case elfcpp::R_386_32:
- case elfcpp::R_386_PC32:
- case elfcpp::R_386_GOT32:
- case elfcpp::R_386_GOT32X:
- case elfcpp::R_386_PLT32:
- case elfcpp::R_386_GOTOFF:
- case elfcpp::R_386_GOTPC:
- return 4;
-
- case elfcpp::R_386_16:
- case elfcpp::R_386_PC16:
- return 2;
-
- case elfcpp::R_386_8:
- case elfcpp::R_386_PC8:
- return 1;
-
- // These are relocations which should only be seen by the
- // dynamic linker, and should never be seen here.
- case elfcpp::R_386_COPY:
- case elfcpp::R_386_GLOB_DAT:
- case elfcpp::R_386_JUMP_SLOT:
- case elfcpp::R_386_RELATIVE:
- case elfcpp::R_386_IRELATIVE:
- case elfcpp::R_386_TLS_TPOFF:
- case elfcpp::R_386_TLS_DTPMOD32:
- case elfcpp::R_386_TLS_DTPOFF32:
- case elfcpp::R_386_TLS_TPOFF32:
- case elfcpp::R_386_TLS_DESC:
- object->error(_("unexpected reloc %u in object file"), r_type);
- return 0;
-
- case elfcpp::R_386_32PLT:
- case elfcpp::R_386_TLS_GD_32:
- case elfcpp::R_386_TLS_GD_PUSH:
- case elfcpp::R_386_TLS_GD_CALL:
- case elfcpp::R_386_TLS_GD_POP:
- case elfcpp::R_386_TLS_LDM_32:
- case elfcpp::R_386_TLS_LDM_PUSH:
- case elfcpp::R_386_TLS_LDM_CALL:
- case elfcpp::R_386_TLS_LDM_POP:
- case elfcpp::R_386_USED_BY_INTEL_200:
- default:
- object->error(_("unsupported reloc %u in object file"), r_type);
- return 0;
- }
-}
-
-// Scan the relocs during a relocatable link.
-
-void
-Target_i386::scan_relocatable_relocs(Symbol_table* symtab,
- Layout* layout,
- Sized_relobj_file<32, false>* object,
- unsigned int data_shndx,
- unsigned int sh_type,
- const unsigned char* prelocs,
- size_t reloc_count,
- Output_section* output_section,
- bool needs_special_offset_handling,
- size_t local_symbol_count,
- const unsigned char* plocal_symbols,
- Relocatable_relocs* rr)
-{
- typedef gold::Default_scan_relocatable_relocs<Classify_reloc>
- Scan_relocatable_relocs;
-
- gold_assert(sh_type == elfcpp::SHT_REL);
-
- gold::scan_relocatable_relocs<32, false, Scan_relocatable_relocs>(
- symtab,
- layout,
- object,
- data_shndx,
- prelocs,
- reloc_count,
- output_section,
- needs_special_offset_handling,
- local_symbol_count,
- plocal_symbols,
- rr);
-}
-
-// Scan the relocs for --emit-relocs.
-
-void
-Target_i386::emit_relocs_scan(Symbol_table* symtab,
- Layout* layout,
- Sized_relobj_file<32, false>* object,
- unsigned int data_shndx,
- unsigned int sh_type,
- const unsigned char* prelocs,
- size_t reloc_count,
- Output_section* output_section,
- bool needs_special_offset_handling,
- size_t local_symbol_count,
- const unsigned char* plocal_syms,
- Relocatable_relocs* rr)
-{
- typedef gold::Default_classify_reloc<elfcpp::SHT_REL, 32, false>
- Classify_reloc;
- typedef gold::Default_emit_relocs_strategy<Classify_reloc>
- Emit_relocs_strategy;
-
- gold_assert(sh_type == elfcpp::SHT_REL);
-
- gold::scan_relocatable_relocs<32, false, Emit_relocs_strategy>(
- symtab,
- layout,
- object,
- data_shndx,
- prelocs,
- reloc_count,
- output_section,
- needs_special_offset_handling,
- local_symbol_count,
- plocal_syms,
- rr);
-}
-
-// Emit relocations for a section.
-
-void
-Target_i386::relocate_relocs(
- const Relocate_info<32, false>* relinfo,
- unsigned int sh_type,
- const unsigned char* prelocs,
- size_t reloc_count,
- Output_section* output_section,
- elfcpp::Elf_types<32>::Elf_Off offset_in_output_section,
- unsigned char* view,
- elfcpp::Elf_types<32>::Elf_Addr view_address,
- section_size_type view_size,
- unsigned char* reloc_view,
- section_size_type reloc_view_size)
-{
- gold_assert(sh_type == elfcpp::SHT_REL);
-
- gold::relocate_relocs<32, false, Classify_reloc>(
- relinfo,
- prelocs,
- reloc_count,
- output_section,
- offset_in_output_section,
- view,
- view_address,
- view_size,
- reloc_view,
- reloc_view_size);
-}
-
-// Return the value to use for a dynamic which requires special
-// treatment. This is how we support equality comparisons of function
-// pointers across shared library boundaries, as described in the
-// processor specific ABI supplement.
-
-uint64_t
-Target_i386::do_dynsym_value(const Symbol* gsym) const
-{
- gold_assert(gsym->is_from_dynobj() && gsym->has_plt_offset());
- return this->plt_address_for_global(gsym);
-}
-
-// Return a string used to fill a code section with nops to take up
-// the specified length.
-
-std::string
-Target_i386::do_code_fill(section_size_type length) const
-{
- if (length >= 16)
- {
- // Build a jmp instruction to skip over the bytes.
- unsigned char jmp[5];
- jmp[0] = 0xe9;
- elfcpp::Swap_unaligned<32, false>::writeval(jmp + 1, length - 5);
- return (std::string(reinterpret_cast<char*>(&jmp[0]), 5)
- + std::string(length - 5, static_cast<char>(0x90)));
- }
-
- // Nop sequences of various lengths.
- const char nop1[1] = { '\x90' }; // nop
- const char nop2[2] = { '\x66', '\x90' }; // xchg %ax %ax
- const char nop3[3] = { '\x8d', '\x76', '\x00' }; // leal 0(%esi),%esi
- const char nop4[4] = { '\x8d', '\x74', '\x26', // leal 0(%esi,1),%esi
- '\x00'};
- const char nop5[5] = { '\x90', '\x8d', '\x74', // nop
- '\x26', '\x00' }; // leal 0(%esi,1),%esi
- const char nop6[6] = { '\x8d', '\xb6', '\x00', // leal 0L(%esi),%esi
- '\x00', '\x00', '\x00' };
- const char nop7[7] = { '\x8d', '\xb4', '\x26', // leal 0L(%esi,1),%esi
- '\x00', '\x00', '\x00',
- '\x00' };
- const char nop8[8] = { '\x90', '\x8d', '\xb4', // nop
- '\x26', '\x00', '\x00', // leal 0L(%esi,1),%esi
- '\x00', '\x00' };
- const char nop9[9] = { '\x89', '\xf6', '\x8d', // movl %esi,%esi
- '\xbc', '\x27', '\x00', // leal 0L(%edi,1),%edi
- '\x00', '\x00', '\x00' };
- const char nop10[10] = { '\x8d', '\x76', '\x00', // leal 0(%esi),%esi
- '\x8d', '\xbc', '\x27', // leal 0L(%edi,1),%edi
- '\x00', '\x00', '\x00',
- '\x00' };
- const char nop11[11] = { '\x8d', '\x74', '\x26', // leal 0(%esi,1),%esi
- '\x00', '\x8d', '\xbc', // leal 0L(%edi,1),%edi
- '\x27', '\x00', '\x00',
- '\x00', '\x00' };
- const char nop12[12] = { '\x8d', '\xb6', '\x00', // leal 0L(%esi),%esi
- '\x00', '\x00', '\x00', // leal 0L(%edi),%edi
- '\x8d', '\xbf', '\x00',
- '\x00', '\x00', '\x00' };
- const char nop13[13] = { '\x8d', '\xb6', '\x00', // leal 0L(%esi),%esi
- '\x00', '\x00', '\x00', // leal 0L(%edi,1),%edi
- '\x8d', '\xbc', '\x27',
- '\x00', '\x00', '\x00',
- '\x00' };
- const char nop14[14] = { '\x8d', '\xb4', '\x26', // leal 0L(%esi,1),%esi
- '\x00', '\x00', '\x00', // leal 0L(%edi,1),%edi
- '\x00', '\x8d', '\xbc',
- '\x27', '\x00', '\x00',
- '\x00', '\x00' };
- const char nop15[15] = { '\xeb', '\x0d', '\x90', // jmp .+15
- '\x90', '\x90', '\x90', // nop,nop,nop,...
- '\x90', '\x90', '\x90',
- '\x90', '\x90', '\x90',
- '\x90', '\x90', '\x90' };
-
- const char* nops[16] = {
- NULL,
- nop1, nop2, nop3, nop4, nop5, nop6, nop7,
- nop8, nop9, nop10, nop11, nop12, nop13, nop14, nop15
- };
-
- return std::string(nops[length], length);
-}
-
-// Return the value to use for the base of a DW_EH_PE_datarel offset
-// in an FDE. Solaris and SVR4 use DW_EH_PE_datarel because their
-// assembler can not write out the difference between two labels in
-// different sections, so instead of using a pc-relative value they
-// use an offset from the GOT.
-
-uint64_t
-Target_i386::do_ehframe_datarel_base() const
-{
- gold_assert(this->global_offset_table_ != NULL);
- Symbol* sym = this->global_offset_table_;
- Sized_symbol<32>* ssym = static_cast<Sized_symbol<32>*>(sym);
- return ssym->value();
-}
-
-// Return whether SYM should be treated as a call to a non-split
-// function. We don't want that to be true of a call to a
-// get_pc_thunk function.
-
-bool
-Target_i386::do_is_call_to_non_split(const Symbol* sym,
- const unsigned char*,
- const unsigned char*,
- section_size_type) const
-{
- return (sym->type() == elfcpp::STT_FUNC
- && !is_prefix_of("__i686.get_pc_thunk.", sym->name()));
-}
-
-// FNOFFSET in section SHNDX in OBJECT is the start of a function
-// compiled with -fsplit-stack. The function calls non-split-stack
-// code. We have to change the function so that it always ensures
-// that it has enough stack space to run some random function.
-
-void
-Target_i386::do_calls_non_split(Relobj* object, unsigned int shndx,
- section_offset_type fnoffset,
- section_size_type fnsize,
- const unsigned char*,
- size_t,
- unsigned char* view,
- section_size_type view_size,
- std::string* from,
- std::string* to) const
-{
- // The function starts with a comparison of the stack pointer and a
- // field in the TCB. This is followed by a jump.
-
- // cmp %gs:NN,%esp
- if (this->match_view(view, view_size, fnoffset, "\x65\x3b\x25", 3)
- && fnsize > 7)
- {
- // We will call __morestack if the carry flag is set after this
- // comparison. We turn the comparison into an stc instruction
- // and some nops.
- view[fnoffset] = '\xf9';
- this->set_view_to_nop(view, view_size, fnoffset + 1, 6);
- }
- // lea NN(%esp),%ecx
- // lea NN(%esp),%edx
- else if ((this->match_view(view, view_size, fnoffset, "\x8d\x8c\x24", 3)
- || this->match_view(view, view_size, fnoffset, "\x8d\x94\x24", 3))
- && fnsize > 7)
- {
- // This is loading an offset from the stack pointer for a
- // comparison. The offset is negative, so we decrease the
- // offset by the amount of space we need for the stack. This
- // means we will avoid calling __morestack if there happens to
- // be plenty of space on the stack already.
- unsigned char* pval = view + fnoffset + 3;
- uint32_t val = elfcpp::Swap_unaligned<32, false>::readval(pval);
- val -= parameters->options().split_stack_adjust_size();
- elfcpp::Swap_unaligned<32, false>::writeval(pval, val);
- }
- else
- {
- if (!object->has_no_split_stack())
- object->error(_("failed to match split-stack sequence at "
- "section %u offset %0zx"),
- shndx, static_cast<size_t>(fnoffset));
- return;
- }
-
- // We have to change the function so that it calls
- // __morestack_non_split instead of __morestack. The former will
- // allocate additional stack space.
- *from = "__morestack";
- *to = "__morestack_non_split";
-}
-
-// The selector for i386 object files. Note this is never instantiated
-// directly. It's only used in Target_selector_i386_nacl, below.
-
-class Target_selector_i386 : public Target_selector_freebsd
-{
-public:
- Target_selector_i386()
- : Target_selector_freebsd(elfcpp::EM_386, 32, false,
- "elf32-i386", "elf32-i386-freebsd",
- "elf_i386")
- { }
-
- Target*
- do_instantiate_target()
- { return new Target_i386(); }
-};
-
-// NaCl variant. It uses different PLT contents.
-
-class Output_data_plt_i386_nacl : public Output_data_plt_i386
-{
- public:
- Output_data_plt_i386_nacl(Layout* layout,
- Output_data_got_plt_i386* got_plt,
- Output_data_space* got_irelative)
- : Output_data_plt_i386(layout, plt_entry_size, got_plt, got_irelative)
- { }
-
- protected:
- virtual unsigned int
- do_get_plt_entry_size() const
- { return plt_entry_size; }
-
- virtual void
- do_add_eh_frame(Layout* layout)
- {
- layout->add_eh_frame_for_plt(this, plt_eh_frame_cie, plt_eh_frame_cie_size,
- plt_eh_frame_fde, plt_eh_frame_fde_size);
- }
-
- // The size of an entry in the PLT.
- static const int plt_entry_size = 64;
-
- // The .eh_frame unwind information for the PLT.
- static const int plt_eh_frame_fde_size = 32;
- static const unsigned char plt_eh_frame_fde[plt_eh_frame_fde_size];
-};
-
-class Output_data_plt_i386_nacl_exec : public Output_data_plt_i386_nacl
-{
-public:
- Output_data_plt_i386_nacl_exec(Layout* layout,
- Output_data_got_plt_i386* got_plt,
- Output_data_space* got_irelative)
- : Output_data_plt_i386_nacl(layout, got_plt, got_irelative)
- { }
-
- protected:
- virtual void
- do_fill_first_plt_entry(unsigned char* pov,
- elfcpp::Elf_types<32>::Elf_Addr got_address);
-
- virtual unsigned int
- do_fill_plt_entry(unsigned char* pov,
- elfcpp::Elf_types<32>::Elf_Addr got_address,
- unsigned int got_offset,
- unsigned int plt_offset,
- unsigned int plt_rel_offset);
-
- private:
- // The first entry in the PLT for an executable.
- static const unsigned char first_plt_entry[plt_entry_size];
-
- // Other entries in the PLT for an executable.
- static const unsigned char plt_entry[plt_entry_size];
-};
-
-class Output_data_plt_i386_nacl_dyn : public Output_data_plt_i386_nacl
-{
- public:
- Output_data_plt_i386_nacl_dyn(Layout* layout,
- Output_data_got_plt_i386* got_plt,
- Output_data_space* got_irelative)
- : Output_data_plt_i386_nacl(layout, got_plt, got_irelative)
- { }
-
- protected:
- virtual void
- do_fill_first_plt_entry(unsigned char* pov, elfcpp::Elf_types<32>::Elf_Addr);
-
- virtual unsigned int
- do_fill_plt_entry(unsigned char* pov,
- elfcpp::Elf_types<32>::Elf_Addr,
- unsigned int got_offset,
- unsigned int plt_offset,
- unsigned int plt_rel_offset);
-
- private:
- // The first entry in the PLT for a shared object.
- static const unsigned char first_plt_entry[plt_entry_size];
-
- // Other entries in the PLT for a shared object.
- static const unsigned char plt_entry[plt_entry_size];
-};
-
-class Target_i386_nacl : public Target_i386
-{
- public:
- Target_i386_nacl()
- : Target_i386(&i386_nacl_info)
- { }
-
- protected:
- virtual Output_data_plt_i386*
- do_make_data_plt(Layout* layout,
- Output_data_got_plt_i386* got_plt,
- Output_data_space* got_irelative,
- bool dyn)
- {
- if (dyn)
- return new Output_data_plt_i386_nacl_dyn(layout, got_plt, got_irelative);
- else
- return new Output_data_plt_i386_nacl_exec(layout, got_plt, got_irelative);
- }
-
- virtual std::string
- do_code_fill(section_size_type length) const;
-
- private:
- static const Target::Target_info i386_nacl_info;
-};
-
-const Target::Target_info Target_i386_nacl::i386_nacl_info =
-{
- 32, // size
- false, // is_big_endian
- elfcpp::EM_386, // machine_code
- false, // has_make_symbol
- false, // has_resolve
- true, // has_code_fill
- true, // is_default_stack_executable
- true, // can_icf_inline_merge_sections
- '\0', // wrap_char
- "/lib/ld-nacl-x86-32.so.1", // dynamic_linker
- 0x20000, // default_text_segment_address
- 0x10000, // abi_pagesize (overridable by -z max-page-size)
- 0x10000, // common_pagesize (overridable by -z common-page-size)
- true, // isolate_execinstr
- 0x10000000, // rosegment_gap
- elfcpp::SHN_UNDEF, // small_common_shndx
- elfcpp::SHN_UNDEF, // large_common_shndx
- 0, // small_common_section_flags
- 0, // large_common_section_flags
- NULL, // attributes_section
- NULL, // attributes_vendor
- "_start", // entry_symbol_name
- 32, // hash_entry_size
- elfcpp::SHT_PROGBITS, // unwind_section_type
-};
-
-#define NACLMASK 0xe0 // 32-byte alignment mask
-
-const unsigned char
-Output_data_plt_i386_nacl_exec::first_plt_entry[plt_entry_size] =
-{
- 0xff, 0x35, // pushl contents of memory address
- 0, 0, 0, 0, // replaced with address of .got + 4
- 0x8b, 0x0d, // movl contents of address, %ecx
- 0, 0, 0, 0, // replaced with address of .got + 8
- 0x83, 0xe1, NACLMASK, // andl $NACLMASK, %ecx
- 0xff, 0xe1, // jmp *%ecx
- 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, // nops
- 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, // nops
- 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, // nops
- 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, // nops
- 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, // nops
- 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, // nops
- 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, // nops
- 0x90, 0x90, 0x90, 0x90, 0x90
-};
-
-void
-Output_data_plt_i386_nacl_exec::do_fill_first_plt_entry(
- unsigned char* pov,
- elfcpp::Elf_types<32>::Elf_Addr got_address)
-{
- memcpy(pov, first_plt_entry, plt_entry_size);
- elfcpp::Swap_unaligned<32, false>::writeval(pov + 2, got_address + 4);
- elfcpp::Swap<32, false>::writeval(pov + 8, got_address + 8);
-}
-
-// The first entry in the PLT for a shared object.
-
-const unsigned char
-Output_data_plt_i386_nacl_dyn::first_plt_entry[plt_entry_size] =
-{
- 0xff, 0xb3, 4, 0, 0, 0, // pushl 4(%ebx)
- 0x8b, 0x4b, 0x08, // mov 0x8(%ebx), %ecx
- 0x83, 0xe1, NACLMASK, // andl $NACLMASK, %ecx
- 0xff, 0xe1, // jmp *%ecx
- 0x90, 0x90, 0x90, 0x90, 0x90, // nops
- 0x90, 0x90, 0x90, 0x90, 0x90, // nops
- 0x90, 0x90, 0x90, 0x90, 0x90, // nops
- 0x90, 0x90, 0x90, 0x90, 0x90, // nops
- 0x90, 0x90, 0x90, 0x90, 0x90, // nops
- 0x90, 0x90, 0x90, 0x90, 0x90, // nops
- 0x90, 0x90, 0x90, 0x90, 0x90, // nops
- 0x90, 0x90, 0x90, 0x90, 0x90, // nops
- 0x90, 0x90, 0x90, 0x90, 0x90, // nops
- 0x90, 0x90, 0x90, 0x90, 0x90 // nops
-};
-
-void
-Output_data_plt_i386_nacl_dyn::do_fill_first_plt_entry(
- unsigned char* pov,
- elfcpp::Elf_types<32>::Elf_Addr)
-{
- memcpy(pov, first_plt_entry, plt_entry_size);
-}
-
-// Subsequent entries in the PLT for an executable.
-
-const unsigned char
-Output_data_plt_i386_nacl_exec::plt_entry[plt_entry_size] =
-{
- 0x8b, 0x0d, // movl contents of address, %ecx */
- 0, 0, 0, 0, // replaced with address of symbol in .got
- 0x83, 0xe1, NACLMASK, // andl $NACLMASK, %ecx
- 0xff, 0xe1, // jmp *%ecx
-
- // Pad to the next 32-byte boundary with nop instructions.
- 0x90,
- 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90,
- 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90,
-
- // Lazy GOT entries point here (32-byte aligned).
- 0x68, // pushl immediate
- 0, 0, 0, 0, // replaced with offset into relocation table
- 0xe9, // jmp relative
- 0, 0, 0, 0, // replaced with offset to start of .plt
-
- // Pad to the next 32-byte boundary with nop instructions.
- 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90,
- 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90,
- 0x90, 0x90
-};
-
-unsigned int
-Output_data_plt_i386_nacl_exec::do_fill_plt_entry(
- unsigned char* pov,
- elfcpp::Elf_types<32>::Elf_Addr got_address,
- unsigned int got_offset,
- unsigned int plt_offset,
- unsigned int plt_rel_offset)
-{
- memcpy(pov, plt_entry, plt_entry_size);
- elfcpp::Swap_unaligned<32, false>::writeval(pov + 2,
- got_address + got_offset);
- elfcpp::Swap_unaligned<32, false>::writeval(pov + 33, plt_rel_offset);
- elfcpp::Swap<32, false>::writeval(pov + 38, - (plt_offset + 38 + 4));
- return 32;
-}
-
-// Subsequent entries in the PLT for a shared object.
-
-const unsigned char
-Output_data_plt_i386_nacl_dyn::plt_entry[plt_entry_size] =
-{
- 0x8b, 0x8b, // movl offset(%ebx), %ecx
- 0, 0, 0, 0, // replaced with offset of symbol in .got
- 0x83, 0xe1, 0xe0, // andl $NACLMASK, %ecx
- 0xff, 0xe1, // jmp *%ecx
-
- // Pad to the next 32-byte boundary with nop instructions.
- 0x90,
- 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90,
- 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90,
-
- // Lazy GOT entries point here (32-byte aligned).
- 0x68, // pushl immediate
- 0, 0, 0, 0, // replaced with offset into relocation table.
- 0xe9, // jmp relative
- 0, 0, 0, 0, // replaced with offset to start of .plt.
-
- // Pad to the next 32-byte boundary with nop instructions.
- 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90,
- 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90, 0x90,
- 0x90, 0x90
-};
-
-unsigned int
-Output_data_plt_i386_nacl_dyn::do_fill_plt_entry(
- unsigned char* pov,
- elfcpp::Elf_types<32>::Elf_Addr,
- unsigned int got_offset,
- unsigned int plt_offset,
- unsigned int plt_rel_offset)
-{
- memcpy(pov, plt_entry, plt_entry_size);
- elfcpp::Swap_unaligned<32, false>::writeval(pov + 2, got_offset);
- elfcpp::Swap_unaligned<32, false>::writeval(pov + 33, plt_rel_offset);
- elfcpp::Swap<32, false>::writeval(pov + 38, - (plt_offset + 38 + 4));
- return 32;
-}
-
-const unsigned char
-Output_data_plt_i386_nacl::plt_eh_frame_fde[plt_eh_frame_fde_size] =
-{
- 0, 0, 0, 0, // Replaced with offset to .plt.
- 0, 0, 0, 0, // Replaced with size of .plt.
- 0, // Augmentation size.
- elfcpp::DW_CFA_def_cfa_offset, 8, // DW_CFA_def_cfa_offset: 8.
- elfcpp::DW_CFA_advance_loc + 6, // Advance 6 to __PLT__ + 6.
- elfcpp::DW_CFA_def_cfa_offset, 12, // DW_CFA_def_cfa_offset: 12.
- elfcpp::DW_CFA_advance_loc + 58, // Advance 58 to __PLT__ + 64.
- elfcpp::DW_CFA_def_cfa_expression, // DW_CFA_def_cfa_expression.
- 13, // Block length.
- elfcpp::DW_OP_breg4, 4, // Push %esp + 4.
- elfcpp::DW_OP_breg8, 0, // Push %eip.
- elfcpp::DW_OP_const1u, 63, // Push 0x3f.
- elfcpp::DW_OP_and, // & (%eip & 0x3f).
- elfcpp::DW_OP_const1u, 37, // Push 0x25.
- elfcpp::DW_OP_ge, // >= ((%eip & 0x3f) >= 0x25)
- elfcpp::DW_OP_lit2, // Push 2.
- elfcpp::DW_OP_shl, // << (((%eip & 0x3f) >= 0x25) << 2)
- elfcpp::DW_OP_plus, // + ((((%eip&0x3f)>=0x25)<<2)+%esp+4
- elfcpp::DW_CFA_nop, // Align to 32 bytes.
- elfcpp::DW_CFA_nop
-};
-
-// Return a string used to fill a code section with nops.
-// For NaCl, long NOPs are only valid if they do not cross
-// bundle alignment boundaries, so keep it simple with one-byte NOPs.
-std::string
-Target_i386_nacl::do_code_fill(section_size_type length) const
-{
- return std::string(length, static_cast<char>(0x90));
-}
-
-// The selector for i386-nacl object files.
-
-class Target_selector_i386_nacl
- : public Target_selector_nacl<Target_selector_i386, Target_i386_nacl>
-{
- public:
- Target_selector_i386_nacl()
- : Target_selector_nacl<Target_selector_i386,
- Target_i386_nacl>("x86-32",
- "elf32-i386-nacl",
- "elf_i386_nacl")
- { }
-};
-
-Target_selector_i386_nacl target_selector_i386;
-
-// IAMCU variant. It uses EM_IAMCU, not EM_386.
-
-class Target_iamcu : public Target_i386
-{
- public:
- Target_iamcu()
- : Target_i386(&iamcu_info)
- { }
-
- private:
- // Information about this specific target which we pass to the
- // general Target structure.
- static const Target::Target_info iamcu_info;
-};
-
-const Target::Target_info Target_iamcu::iamcu_info =
-{
- 32, // size
- false, // is_big_endian
- elfcpp::EM_IAMCU, // machine_code
- false, // has_make_symbol
- false, // has_resolve
- true, // has_code_fill
- true, // is_default_stack_executable
- true, // can_icf_inline_merge_sections
- '\0', // wrap_char
- "/usr/lib/libc.so.1", // dynamic_linker
- 0x08048000, // default_text_segment_address
- 0x1000, // abi_pagesize (overridable by -z max-page-size)
- 0x1000, // common_pagesize (overridable by -z common-page-size)
- false, // isolate_execinstr
- 0, // rosegment_gap
- elfcpp::SHN_UNDEF, // small_common_shndx
- elfcpp::SHN_UNDEF, // large_common_shndx
- 0, // small_common_section_flags
- 0, // large_common_section_flags
- NULL, // attributes_section
- NULL, // attributes_vendor
- "_start", // entry_symbol_name
- 32, // hash_entry_size
- elfcpp::SHT_PROGBITS, // unwind_section_type
-};
-
-class Target_selector_iamcu : public Target_selector
-{
-public:
- Target_selector_iamcu()
- : Target_selector(elfcpp::EM_IAMCU, 32, false, "elf32-iamcu",
- "elf_iamcu")
- { }
-
- Target*
- do_instantiate_target()
- { return new Target_iamcu(); }
-};
-
-Target_selector_iamcu target_selector_iamcu;
-
-} // End anonymous namespace.
Index: sources/GNU/binutils/create-2.43.1-gold-mismatched-section-flags-patch/file.list
===================================================================
--- sources/GNU/binutils/create-2.43.1-gold-mismatched-section-flags-patch/file.list (revision 75)
+++ sources/GNU/binutils/create-2.43.1-gold-mismatched-section-flags-patch/file.list (nonexistent)
@@ -1 +0,0 @@
-binutils-2.43.1/gold/layout.cc
Index: sources/GNU/binutils/create-2.43.1-gold-mismatched-section-flags-patch/create.patch.sh
===================================================================
--- sources/GNU/binutils/create-2.43.1-gold-mismatched-section-flags-patch/create.patch.sh (revision 75)
+++ sources/GNU/binutils/create-2.43.1-gold-mismatched-section-flags-patch/create.patch.sh (nonexistent)
@@ -1,15 +0,0 @@
-#!/bin/bash
-
-VERSION=2.43.1
-
-tar --files-from=file.list -xJvf ../binutils-$VERSION.tar.xz
-mv binutils-$VERSION binutils-$VERSION-orig
-
-cp -rf ./binutils-$VERSION-new ./binutils-$VERSION
-
-diff --unified -Nr binutils-$VERSION-orig binutils-$VERSION > binutils-$VERSION-gold-mismatched-section-flags.patch
-
-mv binutils-$VERSION-gold-mismatched-section-flags.patch ../patches
-
-rm -rf ./binutils-$VERSION
-rm -rf ./binutils-$VERSION-orig
Property changes on: sources/GNU/binutils/create-2.43.1-gold-mismatched-section-flags-patch/create.patch.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: sources/GNU/binutils/create-2.43.1-gold-mismatched-section-flags-patch/binutils-2.43.1-new/gold/layout.cc
===================================================================
--- sources/GNU/binutils/create-2.43.1-gold-mismatched-section-flags-patch/binutils-2.43.1-new/gold/layout.cc (revision 75)
+++ sources/GNU/binutils/create-2.43.1-gold-mismatched-section-flags-patch/binutils-2.43.1-new/gold/layout.cc (nonexistent)
@@ -1,6539 +0,0 @@
-// layout.cc -- lay out output file sections for gold
-
-// Copyright (C) 2006-2024 Free Software Foundation, Inc.
-// Written by Ian Lance Taylor <iant@google.com>.
-
-// This file is part of gold.
-
-// This program is free software; you can redistribute it and/or modify
-// it under the terms of the GNU General Public License as published by
-// the Free Software Foundation; either version 3 of the License, or
-// (at your option) any later version.
-
-// This program is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-// GNU General Public License for more details.
-
-// You should have received a copy of the GNU General Public License
-// along with this program; if not, write to the Free Software
-// Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston,
-// MA 02110-1301, USA.
-
-#include "gold.h"
-
-#include <cerrno>
-#include <cstring>
-#include <algorithm>
-#include <iostream>
-#include <fstream>
-#include <utility>
-#include <fcntl.h>
-#include <fnmatch.h>
-#include <unistd.h>
-#include "libiberty.h"
-#include "md5.h"
-#include "sha1.h"
-#ifdef __MINGW32__
-#include <windows.h>
-#include <rpcdce.h>
-#endif
-#ifdef HAVE_JANSSON
-#include <jansson.h>
-#endif
-
-#include "parameters.h"
-#include "options.h"
-#include "mapfile.h"
-#include "script.h"
-#include "script-sections.h"
-#include "output.h"
-#include "symtab.h"
-#include "dynobj.h"
-#include "ehframe.h"
-#include "gdb-index.h"
-#include "compressed_output.h"
-#include "reduced_debug_output.h"
-#include "object.h"
-#include "reloc.h"
-#include "descriptors.h"
-#include "plugin.h"
-#include "incremental.h"
-#include "layout.h"
-
-namespace gold
-{
-
-// Class Free_list.
-
-// The total number of free lists used.
-unsigned int Free_list::num_lists = 0;
-// The total number of free list nodes used.
-unsigned int Free_list::num_nodes = 0;
-// The total number of calls to Free_list::remove.
-unsigned int Free_list::num_removes = 0;
-// The total number of nodes visited during calls to Free_list::remove.
-unsigned int Free_list::num_remove_visits = 0;
-// The total number of calls to Free_list::allocate.
-unsigned int Free_list::num_allocates = 0;
-// The total number of nodes visited during calls to Free_list::allocate.
-unsigned int Free_list::num_allocate_visits = 0;
-
-// Initialize the free list. Creates a single free list node that
-// describes the entire region of length LEN. If EXTEND is true,
-// allocate() is allowed to extend the region beyond its initial
-// length.
-
-void
-Free_list::init(off_t len, bool extend)
-{
- this->list_.push_front(Free_list_node(0, len));
- this->last_remove_ = this->list_.begin();
- this->extend_ = extend;
- this->length_ = len;
- ++Free_list::num_lists;
- ++Free_list::num_nodes;
-}
-
-// Remove a chunk from the free list. Because we start with a single
-// node that covers the entire section, and remove chunks from it one
-// at a time, we do not need to coalesce chunks or handle cases that
-// span more than one free node. We expect to remove chunks from the
-// free list in order, and we expect to have only a few chunks of free
-// space left (corresponding to files that have changed since the last
-// incremental link), so a simple linear list should provide sufficient
-// performance.
-
-void
-Free_list::remove(off_t start, off_t end)
-{
- if (start == end)
- return;
- gold_assert(start < end);
-
- ++Free_list::num_removes;
-
- Iterator p = this->last_remove_;
- if (p->start_ > start)
- p = this->list_.begin();
-
- for (; p != this->list_.end(); ++p)
- {
- ++Free_list::num_remove_visits;
- // Find a node that wholly contains the indicated region.
- if (p->start_ <= start && p->end_ >= end)
- {
- // Case 1: the indicated region spans the whole node.
- // Add some fuzz to avoid creating tiny free chunks.
- if (p->start_ + 3 >= start && p->end_ <= end + 3)
- p = this->list_.erase(p);
- // Case 2: remove a chunk from the start of the node.
- else if (p->start_ + 3 >= start)
- p->start_ = end;
- // Case 3: remove a chunk from the end of the node.
- else if (p->end_ <= end + 3)
- p->end_ = start;
- // Case 4: remove a chunk from the middle, and split
- // the node into two.
- else
- {
- Free_list_node newnode(p->start_, start);
- p->start_ = end;
- this->list_.insert(p, newnode);
- ++Free_list::num_nodes;
- }
- this->last_remove_ = p;
- return;
- }
- }
-
- // Did not find a node containing the given chunk. This could happen
- // because a small chunk was already removed due to the fuzz.
- gold_debug(DEBUG_INCREMENTAL,
- "Free_list::remove(%d,%d) not found",
- static_cast<int>(start), static_cast<int>(end));
-}
-
-// Allocate a chunk of size LEN from the free list. Returns -1ULL
-// if a sufficiently large chunk of free space is not found.
-// We use a simple first-fit algorithm.
-
-off_t
-Free_list::allocate(off_t len, uint64_t align, off_t minoff)
-{
- gold_debug(DEBUG_INCREMENTAL,
- "Free_list::allocate(%08lx, %d, %08lx)",
- static_cast<long>(len), static_cast<int>(align),
- static_cast<long>(minoff));
- if (len == 0)
- return align_address(minoff, align);
-
- ++Free_list::num_allocates;
-
- // We usually want to drop free chunks smaller than 4 bytes.
- // If we need to guarantee a minimum hole size, though, we need
- // to keep track of all free chunks.
- const int fuzz = this->min_hole_ > 0 ? 0 : 3;
-
- for (Iterator p = this->list_.begin(); p != this->list_.end(); ++p)
- {
- ++Free_list::num_allocate_visits;
- off_t start = p->start_ > minoff ? p->start_ : minoff;
- start = align_address(start, align);
- off_t end = start + len;
- if (end > p->end_ && p->end_ == this->length_ && this->extend_)
- {
- this->length_ = end;
- p->end_ = end;
- }
- if (end == p->end_ || (end <= p->end_ - this->min_hole_))
- {
- if (p->start_ + fuzz >= start && p->end_ <= end + fuzz)
- this->list_.erase(p);
- else if (p->start_ + fuzz >= start)
- p->start_ = end;
- else if (p->end_ <= end + fuzz)
- p->end_ = start;
- else
- {
- Free_list_node newnode(p->start_, start);
- p->start_ = end;
- this->list_.insert(p, newnode);
- ++Free_list::num_nodes;
- }
- return start;
- }
- }
- if (this->extend_)
- {
- off_t start = align_address(this->length_, align);
- this->length_ = start + len;
- return start;
- }
- return -1;
-}
-
-// Dump the free list (for debugging).
-void
-Free_list::dump()
-{
- gold_info("Free list:\n start end length\n");
- for (Iterator p = this->list_.begin(); p != this->list_.end(); ++p)
- gold_info(" %08lx %08lx %08lx", static_cast<long>(p->start_),
- static_cast<long>(p->end_),
- static_cast<long>(p->end_ - p->start_));
-}
-
-// Print the statistics for the free lists.
-void
-Free_list::print_stats()
-{
- fprintf(stderr, _("%s: total free lists: %u\n"),
- program_name, Free_list::num_lists);
- fprintf(stderr, _("%s: total free list nodes: %u\n"),
- program_name, Free_list::num_nodes);
- fprintf(stderr, _("%s: calls to Free_list::remove: %u\n"),
- program_name, Free_list::num_removes);
- fprintf(stderr, _("%s: nodes visited: %u\n"),
- program_name, Free_list::num_remove_visits);
- fprintf(stderr, _("%s: calls to Free_list::allocate: %u\n"),
- program_name, Free_list::num_allocates);
- fprintf(stderr, _("%s: nodes visited: %u\n"),
- program_name, Free_list::num_allocate_visits);
-}
-
-// A Hash_task computes the MD5 checksum of an array of char.
-
-class Hash_task : public Task
-{
- public:
- Hash_task(Output_file* of,
- size_t offset,
- size_t size,
- unsigned char* dst,
- Task_token* final_blocker)
- : of_(of), offset_(offset), size_(size), dst_(dst),
- final_blocker_(final_blocker)
- { }
-
- void
- run(Workqueue*)
- {
- const unsigned char* iv =
- this->of_->get_input_view(this->offset_, this->size_);
- md5_buffer(reinterpret_cast<const char*>(iv), this->size_, this->dst_);
- this->of_->free_input_view(this->offset_, this->size_, iv);
- }
-
- Task_token*
- is_runnable()
- { return NULL; }
-
- // Unblock FINAL_BLOCKER_ when done.
- void
- locks(Task_locker* tl)
- { tl->add(this, this->final_blocker_); }
-
- std::string
- get_name() const
- { return "Hash_task"; }
-
- private:
- Output_file* of_;
- const size_t offset_;
- const size_t size_;
- unsigned char* const dst_;
- Task_token* const final_blocker_;
-};
-
-// Layout::Relaxation_debug_check methods.
-
-// Check that sections and special data are in reset states.
-// We do not save states for Output_sections and special Output_data.
-// So we check that they have not assigned any addresses or offsets.
-// clean_up_after_relaxation simply resets their addresses and offsets.
-void
-Layout::Relaxation_debug_check::check_output_data_for_reset_values(
- const Layout::Section_list& sections,
- const Layout::Data_list& special_outputs,
- const Layout::Data_list& relax_outputs)
-{
- for(Layout::Section_list::const_iterator p = sections.begin();
- p != sections.end();
- ++p)
- gold_assert((*p)->address_and_file_offset_have_reset_values());
-
- for(Layout::Data_list::const_iterator p = special_outputs.begin();
- p != special_outputs.end();
- ++p)
- gold_assert((*p)->address_and_file_offset_have_reset_values());
-
- gold_assert(relax_outputs.empty());
-}
-
-// Save information of SECTIONS for checking later.
-
-void
-Layout::Relaxation_debug_check::read_sections(
- const Layout::Section_list& sections)
-{
- for(Layout::Section_list::const_iterator p = sections.begin();
- p != sections.end();
- ++p)
- {
- Output_section* os = *p;
- Section_info info;
- info.output_section = os;
- info.address = os->is_address_valid() ? os->address() : 0;
- info.data_size = os->is_data_size_valid() ? os->data_size() : -1;
- info.offset = os->is_offset_valid()? os->offset() : -1 ;
- this->section_infos_.push_back(info);
- }
-}
-
-// Verify SECTIONS using previously recorded information.
-
-void
-Layout::Relaxation_debug_check::verify_sections(
- const Layout::Section_list& sections)
-{
- size_t i = 0;
- for(Layout::Section_list::const_iterator p = sections.begin();
- p != sections.end();
- ++p, ++i)
- {
- Output_section* os = *p;
- uint64_t address = os->is_address_valid() ? os->address() : 0;
- off_t data_size = os->is_data_size_valid() ? os->data_size() : -1;
- off_t offset = os->is_offset_valid()? os->offset() : -1 ;
-
- if (i >= this->section_infos_.size())
- {
- gold_fatal("Section_info of %s missing.\n", os->name());
- }
- const Section_info& info = this->section_infos_[i];
- if (os != info.output_section)
- gold_fatal("Section order changed. Expecting %s but see %s\n",
- info.output_section->name(), os->name());
- if (address != info.address
- || data_size != info.data_size
- || offset != info.offset)
- gold_fatal("Section %s changed.\n", os->name());
- }
-}
-
-// Layout_task_runner methods.
-
-// Lay out the sections. This is called after all the input objects
-// have been read.
-
-void
-Layout_task_runner::run(Workqueue* workqueue, const Task* task)
-{
- // See if any of the input definitions violate the One Definition Rule.
- // TODO: if this is too slow, do this as a task, rather than inline.
- this->symtab_->detect_odr_violations(task, this->options_.output_file_name());
-
- Layout* layout = this->layout_;
- off_t file_size = layout->finalize(this->input_objects_,
- this->symtab_,
- this->target_,
- task);
-
- // Now we know the final size of the output file and we know where
- // each piece of information goes.
-
- if (this->mapfile_ != NULL)
- {
- this->mapfile_->print_discarded_sections(this->input_objects_);
- layout->print_to_mapfile(this->mapfile_);
- }
-
- Output_file* of;
- if (layout->incremental_base() == NULL)
- {
- of = new Output_file(parameters->options().output_file_name());
- if (this->options_.oformat_enum() != General_options::OBJECT_FORMAT_ELF)
- of->set_is_temporary();
- of->open(file_size);
- }
- else
- {
- of = layout->incremental_base()->output_file();
-
- // Apply the incremental relocations for symbols whose values
- // have changed. We do this before we resize the file and start
- // writing anything else to it, so that we can read the old
- // incremental information from the file before (possibly)
- // overwriting it.
- if (parameters->incremental_update())
- layout->incremental_base()->apply_incremental_relocs(this->symtab_,
- this->layout_,
- of);
-
- of->resize(file_size);
- }
-
- // Queue up the final set of tasks.
- gold::queue_final_tasks(this->options_, this->input_objects_,
- this->symtab_, layout, workqueue, of);
-}
-
-// Layout methods.
-
-Layout::Layout(int number_of_input_files, Script_options* script_options)
- : number_of_input_files_(number_of_input_files),
- script_options_(script_options),
- namepool_(),
- sympool_(),
- dynpool_(),
- signatures_(),
- section_name_map_(),
- segment_list_(),
- section_list_(),
- unattached_section_list_(),
- special_output_list_(),
- relax_output_list_(),
- section_headers_(NULL),
- tls_segment_(NULL),
- relro_segment_(NULL),
- interp_segment_(NULL),
- increase_relro_(0),
- symtab_section_(NULL),
- symtab_xindex_(NULL),
- dynsym_section_(NULL),
- dynsym_xindex_(NULL),
- dynamic_section_(NULL),
- dynamic_symbol_(NULL),
- dynamic_data_(NULL),
- eh_frame_section_(NULL),
- eh_frame_data_(NULL),
- added_eh_frame_data_(false),
- eh_frame_hdr_section_(NULL),
- gdb_index_data_(NULL),
- build_id_note_(NULL),
- debug_abbrev_(NULL),
- debug_info_(NULL),
- group_signatures_(),
- output_file_size_(-1),
- have_added_input_section_(false),
- sections_are_attached_(false),
- input_requires_executable_stack_(false),
- input_with_gnu_stack_note_(false),
- input_without_gnu_stack_note_(false),
- has_static_tls_(false),
- any_postprocessing_sections_(false),
- resized_signatures_(false),
- have_stabstr_section_(false),
- section_ordering_specified_(false),
- unique_segment_for_sections_specified_(false),
- incremental_inputs_(NULL),
- record_output_section_data_from_script_(false),
- lto_slim_object_(false),
- script_output_section_data_list_(),
- segment_states_(NULL),
- relaxation_debug_check_(NULL),
- section_order_map_(),
- section_segment_map_(),
- input_section_position_(),
- input_section_glob_(),
- incremental_base_(NULL),
- free_list_(),
- gnu_properties_()
-{
- // Make space for more than enough segments for a typical file.
- // This is just for efficiency--it's OK if we wind up needing more.
- this->segment_list_.reserve(12);
-
- // We expect two unattached Output_data objects: the file header and
- // the segment headers.
- this->special_output_list_.reserve(2);
-
- // Initialize structure needed for an incremental build.
- if (parameters->incremental())
- this->incremental_inputs_ = new Incremental_inputs;
-
- // The section name pool is worth optimizing in all cases, because
- // it is small, but there are often overlaps due to .rel sections.
- this->namepool_.set_optimize();
-}
-
-// For incremental links, record the base file to be modified.
-
-void
-Layout::set_incremental_base(Incremental_binary* base)
-{
- this->incremental_base_ = base;
- this->free_list_.init(base->output_file()->filesize(), true);
-}
-
-// Hash a key we use to look up an output section mapping.
-
-size_t
-Layout::Hash_key::operator()(const Layout::Key& k) const
-{
- return k.first + k.second.first + k.second.second;
-}
-
-// These are the debug sections that are actually used by gdb.
-// Currently, we've checked versions of gdb up to and including 7.4.
-// We only check the part of the name that follows ".debug_" or
-// ".zdebug_".
-
-static const char* gdb_sections[] =
-{
- "abbrev",
- "addr", // Fission extension
- // "aranges", // not used by gdb as of 7.4
- "frame",
- "gdb_scripts",
- "info",
- "types",
- "line",
- "loc",
- "macinfo",
- "macro",
- // "pubnames", // not used by gdb as of 7.4
- // "pubtypes", // not used by gdb as of 7.4
- // "gnu_pubnames", // Fission extension
- // "gnu_pubtypes", // Fission extension
- "ranges",
- "str",
- "str_offsets",
-};
-
-// This is the minimum set of sections needed for line numbers.
-
-static const char* lines_only_debug_sections[] =
-{
- "abbrev",
- // "addr", // Fission extension
- // "aranges", // not used by gdb as of 7.4
- // "frame",
- // "gdb_scripts",
- "info",
- // "types",
- "line",
- // "loc",
- // "macinfo",
- // "macro",
- // "pubnames", // not used by gdb as of 7.4
- // "pubtypes", // not used by gdb as of 7.4
- // "gnu_pubnames", // Fission extension
- // "gnu_pubtypes", // Fission extension
- // "ranges",
- "str",
- "str_offsets", // Fission extension
-};
-
-// These sections are the DWARF fast-lookup tables, and are not needed
-// when building a .gdb_index section.
-
-static const char* gdb_fast_lookup_sections[] =
-{
- "aranges",
- "pubnames",
- "gnu_pubnames",
- "pubtypes",
- "gnu_pubtypes",
-};
-
-// Returns whether the given debug section is in the list of
-// debug-sections-used-by-some-version-of-gdb. SUFFIX is the
-// portion of the name following ".debug_" or ".zdebug_".
-
-static inline bool
-is_gdb_debug_section(const char* suffix)
-{
- // We can do this faster: binary search or a hashtable. But why bother?
- for (size_t i = 0; i < sizeof(gdb_sections)/sizeof(*gdb_sections); ++i)
- if (strcmp(suffix, gdb_sections[i]) == 0)
- return true;
- return false;
-}
-
-// Returns whether the given section is needed for lines-only debugging.
-
-static inline bool
-is_lines_only_debug_section(const char* suffix)
-{
- // We can do this faster: binary search or a hashtable. But why bother?
- for (size_t i = 0;
- i < sizeof(lines_only_debug_sections)/sizeof(*lines_only_debug_sections);
- ++i)
- if (strcmp(suffix, lines_only_debug_sections[i]) == 0)
- return true;
- return false;
-}
-
-// Returns whether the given section is a fast-lookup section that
-// will not be needed when building a .gdb_index section.
-
-static inline bool
-is_gdb_fast_lookup_section(const char* suffix)
-{
- // We can do this faster: binary search or a hashtable. But why bother?
- for (size_t i = 0;
- i < sizeof(gdb_fast_lookup_sections)/sizeof(*gdb_fast_lookup_sections);
- ++i)
- if (strcmp(suffix, gdb_fast_lookup_sections[i]) == 0)
- return true;
- return false;
-}
-
-// Sometimes we compress sections. This is typically done for
-// sections that are not part of normal program execution (such as
-// .debug_* sections), and where the readers of these sections know
-// how to deal with compressed sections. This routine doesn't say for
-// certain whether we'll compress -- it depends on commandline options
-// as well -- just whether this section is a candidate for compression.
-// (The Output_compressed_section class decides whether to compress
-// a given section, and picks the name of the compressed section.)
-
-static bool
-is_compressible_debug_section(const char* secname)
-{
- return (is_prefix_of(".debug", secname));
-}
-
-// We may see compressed debug sections in input files. Return TRUE
-// if this is the name of a compressed debug section.
-
-bool
-is_compressed_debug_section(const char* secname)
-{
- return (is_prefix_of(".zdebug", secname));
-}
-
-std::string
-corresponding_uncompressed_section_name(std::string secname)
-{
- gold_assert(secname[0] == '.' && secname[1] == 'z');
- std::string ret(".");
- ret.append(secname, 2, std::string::npos);
- return ret;
-}
-
-// Whether to include this section in the link.
-
-template<int size, bool big_endian>
-bool
-Layout::include_section(Sized_relobj_file<size, big_endian>*, const char* name,
- const elfcpp::Shdr<size, big_endian>& shdr)
-{
- if (!parameters->options().relocatable()
- && (shdr.get_sh_flags() & elfcpp::SHF_EXCLUDE))
- return false;
-
- elfcpp::Elf_Word sh_type = shdr.get_sh_type();
-
- if ((sh_type >= elfcpp::SHT_LOOS && sh_type <= elfcpp::SHT_HIOS)
- || (sh_type >= elfcpp::SHT_LOPROC && sh_type <= elfcpp::SHT_HIPROC))
- return parameters->target().should_include_section(sh_type);
-
- switch (sh_type)
- {
- case elfcpp::SHT_NULL:
- case elfcpp::SHT_SYMTAB:
- case elfcpp::SHT_DYNSYM:
- case elfcpp::SHT_HASH:
- case elfcpp::SHT_DYNAMIC:
- case elfcpp::SHT_SYMTAB_SHNDX:
- return false;
-
- case elfcpp::SHT_STRTAB:
- // Discard the sections which have special meanings in the ELF
- // ABI. Keep others (e.g., .stabstr). We could also do this by
- // checking the sh_link fields of the appropriate sections.
- return (strcmp(name, ".dynstr") != 0
- && strcmp(name, ".strtab") != 0
- && strcmp(name, ".shstrtab") != 0);
-
- case elfcpp::SHT_RELA:
- case elfcpp::SHT_REL:
- case elfcpp::SHT_GROUP:
- // If we are emitting relocations these should be handled
- // elsewhere.
- gold_assert(!parameters->options().relocatable());
- return false;
-
- case elfcpp::SHT_PROGBITS:
- if (parameters->options().strip_debug()
- && (shdr.get_sh_flags() & elfcpp::SHF_ALLOC) == 0)
- {
- if (is_debug_info_section(name))
- return false;
- }
- if (parameters->options().strip_debug_non_line()
- && (shdr.get_sh_flags() & elfcpp::SHF_ALLOC) == 0)
- {
- // Debugging sections can only be recognized by name.
- if (is_prefix_of(".debug_", name)
- && !is_lines_only_debug_section(name + 7))
- return false;
- if (is_prefix_of(".zdebug_", name)
- && !is_lines_only_debug_section(name + 8))
- return false;
- }
- if (parameters->options().strip_debug_gdb()
- && (shdr.get_sh_flags() & elfcpp::SHF_ALLOC) == 0)
- {
- // Debugging sections can only be recognized by name.
- if (is_prefix_of(".debug_", name)
- && !is_gdb_debug_section(name + 7))
- return false;
- if (is_prefix_of(".zdebug_", name)
- && !is_gdb_debug_section(name + 8))
- return false;
- }
- if (parameters->options().gdb_index()
- && (shdr.get_sh_flags() & elfcpp::SHF_ALLOC) == 0)
- {
- // When building .gdb_index, we can strip .debug_pubnames,
- // .debug_pubtypes, and .debug_aranges sections.
- if (is_prefix_of(".debug_", name)
- && is_gdb_fast_lookup_section(name + 7))
- return false;
- if (is_prefix_of(".zdebug_", name)
- && is_gdb_fast_lookup_section(name + 8))
- return false;
- }
- if (parameters->options().strip_lto_sections()
- && !parameters->options().relocatable()
- && (shdr.get_sh_flags() & elfcpp::SHF_ALLOC) == 0)
- {
- // Ignore LTO sections containing intermediate code.
- if (is_prefix_of(".gnu.lto_", name))
- return false;
- }
- // The GNU linker strips .gnu_debuglink sections, so we do too.
- // This is a feature used to keep debugging information in
- // separate files.
- if (strcmp(name, ".gnu_debuglink") == 0)
- return false;
- return true;
-
- default:
- return true;
- }
-}
-
-// Return an output section named NAME, or NULL if there is none.
-
-Output_section*
-Layout::find_output_section(const char* name) const
-{
- for (Section_list::const_iterator p = this->section_list_.begin();
- p != this->section_list_.end();
- ++p)
- if (strcmp((*p)->name(), name) == 0)
- return *p;
- return NULL;
-}
-
-// Return an output segment of type TYPE, with segment flags SET set
-// and segment flags CLEAR clear. Return NULL if there is none.
-
-Output_segment*
-Layout::find_output_segment(elfcpp::PT type, elfcpp::Elf_Word set,
- elfcpp::Elf_Word clear) const
-{
- for (Segment_list::const_iterator p = this->segment_list_.begin();
- p != this->segment_list_.end();
- ++p)
- if (static_cast<elfcpp::PT>((*p)->type()) == type
- && ((*p)->flags() & set) == set
- && ((*p)->flags() & clear) == 0)
- return *p;
- return NULL;
-}
-
-// When we put a .ctors or .dtors section with more than one word into
-// a .init_array or .fini_array section, we need to reverse the words
-// in the .ctors/.dtors section. This is because .init_array executes
-// constructors front to back, where .ctors executes them back to
-// front, and vice-versa for .fini_array/.dtors. Although we do want
-// to remap .ctors/.dtors into .init_array/.fini_array because it can
-// be more efficient, we don't want to change the order in which
-// constructors/destructors are run. This set just keeps track of
-// these sections which need to be reversed. It is only changed by
-// Layout::layout. It should be a private member of Layout, but that
-// would require layout.h to #include object.h to get the definition
-// of Section_id.
-static Unordered_set<Section_id, Section_id_hash> ctors_sections_in_init_array;
-
-// Return whether OBJECT/SHNDX is a .ctors/.dtors section mapped to a
-// .init_array/.fini_array section.
-
-bool
-Layout::is_ctors_in_init_array(Relobj* relobj, unsigned int shndx) const
-{
- return (ctors_sections_in_init_array.find(Section_id(relobj, shndx))
- != ctors_sections_in_init_array.end());
-}
-
-// Return the output section to use for section NAME with type TYPE
-// and section flags FLAGS. NAME must be canonicalized in the string
-// pool, and NAME_KEY is the key. ORDER is where this should appear
-// in the output sections. IS_RELRO is true for a relro section.
-
-Output_section*
-Layout::get_output_section(const char* name, Stringpool::Key name_key,
- elfcpp::Elf_Word type, elfcpp::Elf_Xword flags,
- Output_section_order order, bool is_relro)
-{
- elfcpp::Elf_Word lookup_type = type;
-
- // For lookup purposes, treat INIT_ARRAY, FINI_ARRAY, and
- // PREINIT_ARRAY like PROGBITS. This ensures that we combine
- // .init_array, .fini_array, and .preinit_array sections by name
- // whatever their type in the input file. We do this because the
- // types are not always right in the input files.
- if (lookup_type == elfcpp::SHT_INIT_ARRAY
- || lookup_type == elfcpp::SHT_FINI_ARRAY
- || lookup_type == elfcpp::SHT_PREINIT_ARRAY)
- lookup_type = elfcpp::SHT_PROGBITS;
-
- elfcpp::Elf_Xword lookup_flags = flags;
-
- // Ignoring SHF_WRITE and SHF_EXECINSTR here means that we combine
- // read-write with read-only sections. Some other ELF linkers do
- // not do this. FIXME: Perhaps there should be an option
- // controlling this.
- lookup_flags &= ~(elfcpp::SHF_WRITE | elfcpp::SHF_EXECINSTR);
-
- const Key key(name_key, std::make_pair(lookup_type, lookup_flags));
- const std::pair<Key, Output_section*> v(key, NULL);
- std::pair<Section_name_map::iterator, bool> ins(
- this->section_name_map_.insert(v));
-
- if (!ins.second)
- return ins.first->second;
- else
- {
- // This is the first time we've seen this name/type/flags
- // combination. For compatibility with the GNU linker, we
- // combine sections with contents and zero flags with sections
- // with non-zero flags. This is a workaround for cases where
- // assembler code forgets to set section flags. FIXME: Perhaps
- // there should be an option to control this.
- Output_section* os = NULL;
-
- if (lookup_type == elfcpp::SHT_PROGBITS)
- {
- if (flags == 0)
- {
- Output_section* same_name = this->find_output_section(name);
- if (same_name != NULL
- && (same_name->type() == elfcpp::SHT_PROGBITS
- || same_name->type() == elfcpp::SHT_INIT_ARRAY
- || same_name->type() == elfcpp::SHT_FINI_ARRAY
- || same_name->type() == elfcpp::SHT_PREINIT_ARRAY)
- && (same_name->flags() & elfcpp::SHF_TLS) == 0)
- os = same_name;
- }
-#if 0 /* BZ 1722715, PR 17556. */
- else if ((flags & elfcpp::SHF_TLS) == 0)
- {
- elfcpp::Elf_Xword zero_flags = 0;
- const Key zero_key(name_key, std::make_pair(lookup_type,
- zero_flags));
- Section_name_map::iterator p =
- this->section_name_map_.find(zero_key);
- if (p != this->section_name_map_.end())
- os = p->second;
- }
-#endif
- }
-
- if (os == NULL)
- os = this->make_output_section(name, type, flags, order, is_relro);
-
- ins.first->second = os;
- return os;
- }
-}
-
-// Returns TRUE iff NAME (an input section from RELOBJ) will
-// be mapped to an output section that should be KEPT.
-
-bool
-Layout::keep_input_section(const Relobj* relobj, const char* name)
-{
- if (! this->script_options_->saw_sections_clause())
- return false;
-
- Script_sections* ss = this->script_options_->script_sections();
- const char* file_name = relobj == NULL ? NULL : relobj->name().c_str();
- Output_section** output_section_slot;
- Script_sections::Section_type script_section_type;
- bool keep;
-
- name = ss->output_section_name(file_name, name, &output_section_slot,
- &script_section_type, &keep, true);
- return name != NULL && keep;
-}
-
-// Clear the input section flags that should not be copied to the
-// output section.
-
-elfcpp::Elf_Xword
-Layout::get_output_section_flags(elfcpp::Elf_Xword input_section_flags)
-{
- // Some flags in the input section should not be automatically
- // copied to the output section.
- input_section_flags &= ~ (elfcpp::SHF_INFO_LINK
- | elfcpp::SHF_GROUP
- | elfcpp::SHF_COMPRESSED
- | elfcpp::SHF_MERGE
- | elfcpp::SHF_STRINGS);
-
- // We only clear the SHF_LINK_ORDER flag in for
- // a non-relocatable link.
- if (!parameters->options().relocatable())
- input_section_flags &= ~elfcpp::SHF_LINK_ORDER;
-
- return input_section_flags;
-}
-
-// Pick the output section to use for section NAME, in input file
-// RELOBJ, with type TYPE and flags FLAGS. RELOBJ may be NULL for a
-// linker created section. IS_INPUT_SECTION is true if we are
-// choosing an output section for an input section found in a input
-// file. ORDER is where this section should appear in the output
-// sections. IS_RELRO is true for a relro section. This will return
-// NULL if the input section should be discarded. MATCH_INPUT_SPEC
-// is true if the section name should be matched against input specs
-// in a linker script.
-
-Output_section*
-Layout::choose_output_section(const Relobj* relobj, const char* name,
- elfcpp::Elf_Word type, elfcpp::Elf_Xword flags,
- bool is_input_section, Output_section_order order,
- bool is_relro, bool is_reloc,
- bool match_input_spec)
-{
- // We should not see any input sections after we have attached
- // sections to segments.
- gold_assert(!is_input_section || !this->sections_are_attached_);
-
- flags = this->get_output_section_flags(flags);
-
- if (this->script_options_->saw_sections_clause() && !is_reloc)
- {
- // We are using a SECTIONS clause, so the output section is
- // chosen based only on the name.
-
- Script_sections* ss = this->script_options_->script_sections();
- const char* file_name = relobj == NULL ? NULL : relobj->name().c_str();
- Output_section** output_section_slot;
- Script_sections::Section_type script_section_type;
- const char* orig_name = name;
- bool keep;
- name = ss->output_section_name(file_name, name, &output_section_slot,
- &script_section_type, &keep,
- match_input_spec);
-
- if (name == NULL)
- {
- gold_debug(DEBUG_SCRIPT, _("Unable to create output section '%s' "
- "because it is not allowed by the "
- "SECTIONS clause of the linker script"),
- orig_name);
- // The SECTIONS clause says to discard this input section.
- return NULL;
- }
-
- // We can only handle script section types ST_NONE and ST_NOLOAD.
- switch (script_section_type)
- {
- case Script_sections::ST_NONE:
- break;
- case Script_sections::ST_NOLOAD:
- flags &= elfcpp::SHF_ALLOC;
- break;
- default:
- gold_unreachable();
- }
-
- // If this is an orphan section--one not mentioned in the linker
- // script--then OUTPUT_SECTION_SLOT will be NULL, and we do the
- // default processing below.
-
- if (output_section_slot != NULL)
- {
- if (*output_section_slot != NULL)
- {
- (*output_section_slot)->update_flags_for_input_section(flags);
- return *output_section_slot;
- }
-
- // We don't put sections found in the linker script into
- // SECTION_NAME_MAP_. That keeps us from getting confused
- // if an orphan section is mapped to a section with the same
- // name as one in the linker script.
-
- name = this->namepool_.add(name, false, NULL);
-
- Output_section* os = this->make_output_section(name, type, flags,
- order, is_relro);
-
- os->set_found_in_sections_clause();
-
- // Special handling for NOLOAD sections.
- if (script_section_type == Script_sections::ST_NOLOAD)
- {
- os->set_is_noload();
-
- // The constructor of Output_section sets addresses of non-ALLOC
- // sections to 0 by default. We don't want that for NOLOAD
- // sections even if they have no SHF_ALLOC flag.
- if ((os->flags() & elfcpp::SHF_ALLOC) == 0
- && os->is_address_valid())
- {
- gold_assert(os->address() == 0
- && !os->is_offset_valid()
- && !os->is_data_size_valid());
- os->reset_address_and_file_offset();
- }
- }
-
- *output_section_slot = os;
- return os;
- }
- }
-
- // FIXME: Handle SHF_OS_NONCONFORMING somewhere.
-
- size_t len = strlen(name);
- std::string uncompressed_name;
-
- // Compressed debug sections should be mapped to the corresponding
- // uncompressed section.
- if (is_compressed_debug_section(name))
- {
- uncompressed_name =
- corresponding_uncompressed_section_name(std::string(name, len));
- name = uncompressed_name.c_str();
- len = uncompressed_name.length();
- }
-
- // Turn NAME from the name of the input section into the name of the
- // output section.
- if (is_input_section
- && !this->script_options_->saw_sections_clause()
- && !parameters->options().relocatable())
- {
- const char *orig_name = name;
- name = parameters->target().output_section_name(relobj, name, &len);
- if (name == NULL)
- name = Layout::output_section_name(relobj, orig_name, &len);
- }
-
- Stringpool::Key name_key;
- name = this->namepool_.add_with_length(name, len, true, &name_key);
-
- // Find or make the output section. The output section is selected
- // based on the section name, type, and flags.
- return this->get_output_section(name, name_key, type, flags, order, is_relro);
-}
-
-// For incremental links, record the initial fixed layout of a section
-// from the base file, and return a pointer to the Output_section.
-
-template<int size, bool big_endian>
-Output_section*
-Layout::init_fixed_output_section(const char* name,
- elfcpp::Shdr<size, big_endian>& shdr)
-{
- unsigned int sh_type = shdr.get_sh_type();
-
- // We preserve the layout of PROGBITS, NOBITS, INIT_ARRAY, FINI_ARRAY,
- // PRE_INIT_ARRAY, and NOTE sections.
- // All others will be created from scratch and reallocated.
- if (!can_incremental_update(sh_type))
- return NULL;
-
- // If we're generating a .gdb_index section, we need to regenerate
- // it from scratch.
- if (parameters->options().gdb_index()
- && sh_type == elfcpp::SHT_PROGBITS
- && strcmp(name, ".gdb_index") == 0)
- return NULL;
-
- typename elfcpp::Elf_types<size>::Elf_Addr sh_addr = shdr.get_sh_addr();
- typename elfcpp::Elf_types<size>::Elf_Off sh_offset = shdr.get_sh_offset();
- typename elfcpp::Elf_types<size>::Elf_WXword sh_size = shdr.get_sh_size();
- typename elfcpp::Elf_types<size>::Elf_WXword sh_flags =
- this->get_output_section_flags(shdr.get_sh_flags());
- typename elfcpp::Elf_types<size>::Elf_WXword sh_addralign =
- shdr.get_sh_addralign();
-
- // Make the output section.
- Stringpool::Key name_key;
- name = this->namepool_.add(name, true, &name_key);
- Output_section* os = this->get_output_section(name, name_key, sh_type,
- sh_flags, ORDER_INVALID, false);
- os->set_fixed_layout(sh_addr, sh_offset, sh_size, sh_addralign);
- if (sh_type != elfcpp::SHT_NOBITS)
- this->free_list_.remove(sh_offset, sh_offset + sh_size);
- return os;
-}
-
-// Return the index by which an input section should be ordered. This
-// is used to sort some .text sections, for compatibility with GNU ld.
-
-int
-Layout::special_ordering_of_input_section(const char* name)
-{
- // The GNU linker has some special handling for some sections that
- // wind up in the .text section. Sections that start with these
- // prefixes must appear first, and must appear in the order listed
- // here.
- static const char* const text_section_sort[] =
- {
- ".text.unlikely",
- ".text.exit",
- ".text.startup",
- ".text.hot",
- ".text.sorted"
- };
-
- for (size_t i = 0;
- i < sizeof(text_section_sort) / sizeof(text_section_sort[0]);
- i++)
- if (is_prefix_of(text_section_sort[i], name))
- return i;
-
- return -1;
-}
-
-// Return the output section to use for input section SHNDX, with name
-// NAME, with header HEADER, from object OBJECT. RELOC_SHNDX is the
-// index of a relocation section which applies to this section, or 0
-// if none, or -1U if more than one. RELOC_TYPE is the type of the
-// relocation section if there is one. Set *OFF to the offset of this
-// input section without the output section. Return NULL if the
-// section should be discarded. Set *OFF to -1 if the section
-// contents should not be written directly to the output file, but
-// will instead receive special handling.
-
-template<int size, bool big_endian>
-Output_section*
-Layout::layout(Sized_relobj_file<size, big_endian>* object, unsigned int shndx,
- const char* name, const elfcpp::Shdr<size, big_endian>& shdr,
- unsigned int sh_type, unsigned int reloc_shndx,
- unsigned int, off_t* off)
-{
- *off = 0;
-
- if (!this->include_section(object, name, shdr))
- return NULL;
-
- // In a relocatable link a grouped section must not be combined with
- // any other sections.
- Output_section* os;
- if (parameters->options().relocatable()
- && (shdr.get_sh_flags() & elfcpp::SHF_GROUP) != 0)
- {
- // Some flags in the input section should not be automatically
- // copied to the output section.
- elfcpp::Elf_Xword sh_flags = (shdr.get_sh_flags()
- & ~ elfcpp::SHF_COMPRESSED);
- name = this->namepool_.add(name, true, NULL);
- os = this->make_output_section(name, sh_type, sh_flags, ORDER_INVALID,
- false);
- }
- else
- {
- // Get the section flags and mask out any flags that do not
- // take part in section matching.
- elfcpp::Elf_Xword sh_flags
- = (this->get_output_section_flags(shdr.get_sh_flags())
- & ~object->osabi().ignored_sh_flags());
-
- // All ".text.unlikely.*" sections can be moved to a unique
- // segment with --text-unlikely-segment option.
- bool text_unlikely_segment
- = (parameters->options().text_unlikely_segment()
- && is_prefix_of(".text.unlikely",
- object->section_name(shndx).c_str()));
- if (text_unlikely_segment)
- {
- Stringpool::Key name_key;
- const char* os_name = this->namepool_.add(".text.unlikely", true,
- &name_key);
- os = this->get_output_section(os_name, name_key, sh_type, sh_flags,
- ORDER_INVALID, false);
- // Map this output section to a unique segment. This is done to
- // separate "text" that is not likely to be executed from "text"
- // that is likely executed.
- os->set_is_unique_segment();
- }
- else
- {
- // Plugins can choose to place one or more subsets of sections in
- // unique segments and this is done by mapping these section subsets
- // to unique output sections. Check if this section needs to be
- // remapped to a unique output section.
- Section_segment_map::iterator it
- = this->section_segment_map_.find(Const_section_id(object, shndx));
- if (it == this->section_segment_map_.end())
- {
- os = this->choose_output_section(object, name, sh_type,
- sh_flags, true, ORDER_INVALID,
- false, false, true);
- }
- else
- {
- // We know the name of the output section, directly call
- // get_output_section here by-passing choose_output_section.
- const char* os_name = it->second->name;
- Stringpool::Key name_key;
- os_name = this->namepool_.add(os_name, true, &name_key);
- os = this->get_output_section(os_name, name_key, sh_type,
- sh_flags, ORDER_INVALID, false);
- if (!os->is_unique_segment())
- {
- os->set_is_unique_segment();
- os->set_extra_segment_flags(it->second->flags);
- os->set_segment_alignment(it->second->align);
- }
- }
- }
- if (os == NULL)
- return NULL;
- }
-
- // By default the GNU linker sorts input sections whose names match
- // .ctors.*, .dtors.*, .init_array.*, or .fini_array.*. The
- // sections are sorted by name. This is used to implement
- // constructor priority ordering. We are compatible. When we put
- // .ctor sections in .init_array and .dtor sections in .fini_array,
- // we must also sort plain .ctor and .dtor sections.
- if (!this->script_options_->saw_sections_clause()
- && !parameters->options().relocatable()
- && (is_prefix_of(".ctors.", name)
- || is_prefix_of(".dtors.", name)
- || is_prefix_of(".init_array.", name)
- || is_prefix_of(".fini_array.", name)
- || (parameters->options().ctors_in_init_array()
- && (strcmp(name, ".ctors") == 0
- || strcmp(name, ".dtors") == 0))))
- os->set_must_sort_attached_input_sections();
-
- // By default the GNU linker sorts some special text sections ahead
- // of others. We are compatible.
- if (parameters->options().text_reorder()
- && !this->script_options_->saw_sections_clause()
- && !this->is_section_ordering_specified()
- && !parameters->options().relocatable()
- && Layout::special_ordering_of_input_section(name) >= 0)
- os->set_must_sort_attached_input_sections();
-
- // If this is a .ctors or .ctors.* section being mapped to a
- // .init_array section, or a .dtors or .dtors.* section being mapped
- // to a .fini_array section, we will need to reverse the words if
- // there is more than one. Record this section for later. See
- // ctors_sections_in_init_array above.
- if (!this->script_options_->saw_sections_clause()
- && !parameters->options().relocatable()
- && shdr.get_sh_size() > size / 8
- && (((strcmp(name, ".ctors") == 0
- || is_prefix_of(".ctors.", name))
- && strcmp(os->name(), ".init_array") == 0)
- || ((strcmp(name, ".dtors") == 0
- || is_prefix_of(".dtors.", name))
- && strcmp(os->name(), ".fini_array") == 0)))
- ctors_sections_in_init_array.insert(Section_id(object, shndx));
-
- // FIXME: Handle SHF_LINK_ORDER somewhere.
-
- elfcpp::Elf_Xword orig_flags = os->flags();
-
- *off = os->add_input_section(this, object, shndx, name, shdr, reloc_shndx,
- this->script_options_->saw_sections_clause());
-
- // If the flags changed, we may have to change the order.
- if ((orig_flags & elfcpp::SHF_ALLOC) != 0)
- {
- orig_flags &= (elfcpp::SHF_WRITE | elfcpp::SHF_EXECINSTR);
- elfcpp::Elf_Xword new_flags =
- os->flags() & (elfcpp::SHF_WRITE | elfcpp::SHF_EXECINSTR);
- if (orig_flags != new_flags)
- os->set_order(this->default_section_order(os, false));
- }
-
- this->have_added_input_section_ = true;
-
- return os;
-}
-
-// Maps section SECN to SEGMENT s.
-void
-Layout::insert_section_segment_map(Const_section_id secn,
- Unique_segment_info *s)
-{
- gold_assert(this->unique_segment_for_sections_specified_);
- this->section_segment_map_[secn] = s;
-}
-
-// Handle a relocation section when doing a relocatable link.
-
-template<int size, bool big_endian>
-Output_section*
-Layout::layout_reloc(Sized_relobj_file<size, big_endian>*,
- unsigned int,
- const elfcpp::Shdr<size, big_endian>& shdr,
- Output_section* data_section,
- Relocatable_relocs* rr)
-{
- gold_assert(parameters->options().relocatable()
- || parameters->options().emit_relocs());
-
- int sh_type = shdr.get_sh_type();
-
- std::string name;
- if (sh_type == elfcpp::SHT_REL)
- name = ".rel";
- else if (sh_type == elfcpp::SHT_RELA)
- name = ".rela";
- else
- gold_unreachable();
- name += data_section->name();
-
- // If the output data section already has a reloc section, use that;
- // otherwise, make a new one.
- Output_section* os = data_section->reloc_section();
- if (os == NULL)
- {
- const char* n = this->namepool_.add(name.c_str(), true, NULL);
- os = this->make_output_section(n, sh_type, shdr.get_sh_flags(),
- ORDER_INVALID, false);
- os->set_should_link_to_symtab();
- os->set_info_section(data_section);
- data_section->set_reloc_section(os);
- }
-
- Output_section_data* posd;
- if (sh_type == elfcpp::SHT_REL)
- {
- os->set_entsize(elfcpp::Elf_sizes<size>::rel_size);
- posd = new Output_relocatable_relocs<elfcpp::SHT_REL,
- size,
- big_endian>(rr);
- }
- else if (sh_type == elfcpp::SHT_RELA)
- {
- os->set_entsize(elfcpp::Elf_sizes<size>::rela_size);
- posd = new Output_relocatable_relocs<elfcpp::SHT_RELA,
- size,
- big_endian>(rr);
- }
- else
- gold_unreachable();
-
- os->add_output_section_data(posd);
- rr->set_output_data(posd);
-
- return os;
-}
-
-// Handle a group section when doing a relocatable link.
-
-template<int size, bool big_endian>
-void
-Layout::layout_group(Symbol_table* symtab,
- Sized_relobj_file<size, big_endian>* object,
- unsigned int,
- const char* group_section_name,
- const char* signature,
- const elfcpp::Shdr<size, big_endian>& shdr,
- elfcpp::Elf_Word flags,
- std::vector<unsigned int>* shndxes)
-{
- gold_assert(parameters->options().relocatable());
- gold_assert(shdr.get_sh_type() == elfcpp::SHT_GROUP);
- group_section_name = this->namepool_.add(group_section_name, true, NULL);
- Output_section* os = this->make_output_section(group_section_name,
- elfcpp::SHT_GROUP,
- shdr.get_sh_flags(),
- ORDER_INVALID, false);
-
- // We need to find a symbol with the signature in the symbol table.
- // If we don't find one now, we need to look again later.
- Symbol* sym = symtab->lookup(signature, NULL);
- if (sym != NULL)
- os->set_info_symndx(sym);
- else
- {
- // Reserve some space to minimize reallocations.
- if (this->group_signatures_.empty())
- this->group_signatures_.reserve(this->number_of_input_files_ * 16);
-
- // We will wind up using a symbol whose name is the signature.
- // So just put the signature in the symbol name pool to save it.
- signature = symtab->canonicalize_name(signature);
- this->group_signatures_.push_back(Group_signature(os, signature));
- }
-
- os->set_should_link_to_symtab();
- os->set_entsize(4);
-
- section_size_type entry_count =
- convert_to_section_size_type(shdr.get_sh_size() / 4);
- Output_section_data* posd =
- new Output_data_group<size, big_endian>(object, entry_count, flags,
- shndxes);
- os->add_output_section_data(posd);
-}
-
-// Special GNU handling of sections name .eh_frame. They will
-// normally hold exception frame data as defined by the C++ ABI
-// (http://codesourcery.com/cxx-abi/).
-
-template<int size, bool big_endian>
-Output_section*
-Layout::layout_eh_frame(Sized_relobj_file<size, big_endian>* object,
- const unsigned char* symbols,
- off_t symbols_size,
- const unsigned char* symbol_names,
- off_t symbol_names_size,
- unsigned int shndx,
- const elfcpp::Shdr<size, big_endian>& shdr,
- unsigned int reloc_shndx, unsigned int reloc_type,
- off_t* off)
-{
- const unsigned int unwind_section_type =
- parameters->target().unwind_section_type();
-
- gold_assert(shdr.get_sh_type() == elfcpp::SHT_PROGBITS
- || shdr.get_sh_type() == unwind_section_type);
- gold_assert((shdr.get_sh_flags() & elfcpp::SHF_ALLOC) != 0);
-
- Output_section* os = this->make_eh_frame_section(object);
- if (os == NULL)
- return NULL;
-
- gold_assert(this->eh_frame_section_ == os);
-
- elfcpp::Elf_Xword orig_flags = os->flags();
-
- Eh_frame::Eh_frame_section_disposition disp =
- Eh_frame::EH_UNRECOGNIZED_SECTION;
- if (!parameters->incremental())
- {
- disp = this->eh_frame_data_->add_ehframe_input_section(object,
- symbols,
- symbols_size,
- symbol_names,
- symbol_names_size,
- shndx,
- reloc_shndx,
- reloc_type);
- }
-
- if (disp == Eh_frame::EH_OPTIMIZABLE_SECTION)
- {
- os->update_flags_for_input_section(shdr.get_sh_flags());
-
- // A writable .eh_frame section is a RELRO section.
- if ((orig_flags & (elfcpp::SHF_WRITE | elfcpp::SHF_EXECINSTR))
- != (os->flags() & (elfcpp::SHF_WRITE | elfcpp::SHF_EXECINSTR)))
- {
- os->set_is_relro();
- os->set_order(ORDER_RELRO);
- }
-
- *off = -1;
- return os;
- }
-
- if (disp == Eh_frame::EH_END_MARKER_SECTION && !this->added_eh_frame_data_)
- {
- // We found the end marker section, so now we can add the set of
- // optimized sections to the output section. We need to postpone
- // adding this until we've found a section we can optimize so that
- // the .eh_frame section in crtbeginT.o winds up at the start of
- // the output section.
- os->add_output_section_data(this->eh_frame_data_);
- this->added_eh_frame_data_ = true;
- }
-
- // We couldn't handle this .eh_frame section for some reason.
- // Add it as a normal section.
- bool saw_sections_clause = this->script_options_->saw_sections_clause();
- *off = os->add_input_section(this, object, shndx, ".eh_frame", shdr,
- reloc_shndx, saw_sections_clause);
- this->have_added_input_section_ = true;
-
- if ((orig_flags & (elfcpp::SHF_WRITE | elfcpp::SHF_EXECINSTR))
- != (os->flags() & (elfcpp::SHF_WRITE | elfcpp::SHF_EXECINSTR)))
- os->set_order(this->default_section_order(os, false));
-
- return os;
-}
-
-void
-Layout::finalize_eh_frame_section()
-{
- // If we never found an end marker section, we need to add the
- // optimized eh sections to the output section now.
- if (!parameters->incremental()
- && this->eh_frame_section_ != NULL
- && !this->added_eh_frame_data_)
- {
- this->eh_frame_section_->add_output_section_data(this->eh_frame_data_);
- this->added_eh_frame_data_ = true;
- }
-}
-
-// Create and return the magic .eh_frame section. Create
-// .eh_frame_hdr also if appropriate. OBJECT is the object with the
-// input .eh_frame section; it may be NULL.
-
-Output_section*
-Layout::make_eh_frame_section(const Relobj* object)
-{
- const unsigned int unwind_section_type =
- parameters->target().unwind_section_type();
-
- Output_section* os = this->choose_output_section(object, ".eh_frame",
- unwind_section_type,
- elfcpp::SHF_ALLOC, false,
- ORDER_EHFRAME, false, false,
- false);
- if (os == NULL)
- return NULL;
-
- if (this->eh_frame_section_ == NULL)
- {
- this->eh_frame_section_ = os;
- this->eh_frame_data_ = new Eh_frame();
-
- // For incremental linking, we do not optimize .eh_frame sections
- // or create a .eh_frame_hdr section.
- if (parameters->options().eh_frame_hdr() && !parameters->incremental())
- {
- Output_section* hdr_os =
- this->choose_output_section(NULL, ".eh_frame_hdr",
- unwind_section_type,
- elfcpp::SHF_ALLOC, false,
- ORDER_EHFRAME, false, false,
- false);
-
- if (hdr_os != NULL)
- {
- Eh_frame_hdr* hdr_posd = new Eh_frame_hdr(os,
- this->eh_frame_data_);
- hdr_os->add_output_section_data(hdr_posd);
-
- hdr_os->set_after_input_sections();
-
- if (!this->script_options_->saw_phdrs_clause())
- {
- Output_segment* hdr_oseg;
- hdr_oseg = this->make_output_segment(elfcpp::PT_GNU_EH_FRAME,
- elfcpp::PF_R);
- hdr_oseg->add_output_section_to_nonload(hdr_os,
- elfcpp::PF_R);
- }
-
- this->eh_frame_data_->set_eh_frame_hdr(hdr_posd);
- }
- }
- }
-
- return os;
-}
-
-// Add an exception frame for a PLT. This is called from target code.
-
-void
-Layout::add_eh_frame_for_plt(Output_data* plt, const unsigned char* cie_data,
- size_t cie_length, const unsigned char* fde_data,
- size_t fde_length)
-{
- if (parameters->incremental())
- {
- // FIXME: Maybe this could work some day....
- return;
- }
- Output_section* os = this->make_eh_frame_section(NULL);
- if (os == NULL)
- return;
- this->eh_frame_data_->add_ehframe_for_plt(plt, cie_data, cie_length,
- fde_data, fde_length);
- if (!this->added_eh_frame_data_)
- {
- os->add_output_section_data(this->eh_frame_data_);
- this->added_eh_frame_data_ = true;
- }
-}
-
-// Remove all post-map .eh_frame information for a PLT.
-
-void
-Layout::remove_eh_frame_for_plt(Output_data* plt, const unsigned char* cie_data,
- size_t cie_length)
-{
- if (parameters->incremental())
- {
- // FIXME: Maybe this could work some day....
- return;
- }
- this->eh_frame_data_->remove_ehframe_for_plt(plt, cie_data, cie_length);
-}
-
-// Scan a .debug_info or .debug_types section, and add summary
-// information to the .gdb_index section.
-
-template<int size, bool big_endian>
-void
-Layout::add_to_gdb_index(bool is_type_unit,
- Sized_relobj<size, big_endian>* object,
- const unsigned char* symbols,
- off_t symbols_size,
- unsigned int shndx,
- unsigned int reloc_shndx,
- unsigned int reloc_type)
-{
- if (this->gdb_index_data_ == NULL)
- {
- Output_section* os = this->choose_output_section(NULL, ".gdb_index",
- elfcpp::SHT_PROGBITS, 0,
- false, ORDER_INVALID,
- false, false, false);
- if (os == NULL)
- return;
-
- this->gdb_index_data_ = new Gdb_index(os);
- os->add_output_section_data(this->gdb_index_data_);
- os->set_after_input_sections();
- }
-
- this->gdb_index_data_->scan_debug_info(is_type_unit, object, symbols,
- symbols_size, shndx, reloc_shndx,
- reloc_type);
-}
-
-// Add POSD to an output section using NAME, TYPE, and FLAGS. Return
-// the output section.
-
-Output_section*
-Layout::add_output_section_data(const char* name, elfcpp::Elf_Word type,
- elfcpp::Elf_Xword flags,
- Output_section_data* posd,
- Output_section_order order, bool is_relro)
-{
- Output_section* os = this->choose_output_section(NULL, name, type, flags,
- false, order, is_relro,
- false, false);
- if (os != NULL)
- os->add_output_section_data(posd);
- return os;
-}
-
-// Map section flags to segment flags.
-
-elfcpp::Elf_Word
-Layout::section_flags_to_segment(elfcpp::Elf_Xword flags)
-{
- elfcpp::Elf_Word ret = elfcpp::PF_R;
- if ((flags & elfcpp::SHF_WRITE) != 0)
- ret |= elfcpp::PF_W;
- if ((flags & elfcpp::SHF_EXECINSTR) != 0)
- ret |= elfcpp::PF_X;
- return ret;
-}
-
-// Make a new Output_section, and attach it to segments as
-// appropriate. ORDER is the order in which this section should
-// appear in the output segment. IS_RELRO is true if this is a relro
-// (read-only after relocations) section.
-
-Output_section*
-Layout::make_output_section(const char* name, elfcpp::Elf_Word type,
- elfcpp::Elf_Xword flags,
- Output_section_order order, bool is_relro)
-{
- Output_section* os;
- if ((flags & elfcpp::SHF_ALLOC) == 0
- && strcmp(parameters->options().compress_debug_sections(), "none") != 0
- && is_compressible_debug_section(name))
- os = new Output_compressed_section(¶meters->options(), name, type,
- flags);
- else if ((flags & elfcpp::SHF_ALLOC) == 0
- && parameters->options().strip_debug_non_line()
- && strcmp(".debug_abbrev", name) == 0)
- {
- os = this->debug_abbrev_ = new Output_reduced_debug_abbrev_section(
- name, type, flags);
- if (this->debug_info_)
- this->debug_info_->set_abbreviations(this->debug_abbrev_);
- }
- else if ((flags & elfcpp::SHF_ALLOC) == 0
- && parameters->options().strip_debug_non_line()
- && strcmp(".debug_info", name) == 0)
- {
- os = this->debug_info_ = new Output_reduced_debug_info_section(
- name, type, flags);
- if (this->debug_abbrev_)
- this->debug_info_->set_abbreviations(this->debug_abbrev_);
- }
- else
- {
- // Sometimes .init_array*, .preinit_array* and .fini_array* do
- // not have correct section types. Force them here.
- if (type == elfcpp::SHT_PROGBITS)
- {
- if (is_prefix_of(".init_array", name))
- type = elfcpp::SHT_INIT_ARRAY;
- else if (is_prefix_of(".preinit_array", name))
- type = elfcpp::SHT_PREINIT_ARRAY;
- else if (is_prefix_of(".fini_array", name))
- type = elfcpp::SHT_FINI_ARRAY;
- }
-
- // FIXME: const_cast is ugly.
- Target* target = const_cast<Target*>(¶meters->target());
- os = target->make_output_section(name, type, flags);
- }
-
- // With -z relro, we have to recognize the special sections by name.
- // There is no other way.
- bool is_relro_local = false;
- if (!this->script_options_->saw_sections_clause()
- && parameters->options().relro()
- && (flags & elfcpp::SHF_ALLOC) != 0
- && (flags & elfcpp::SHF_WRITE) != 0)
- {
- if (type == elfcpp::SHT_PROGBITS)
- {
- if ((flags & elfcpp::SHF_TLS) != 0)
- is_relro = true;
- else if (strcmp(name, ".data.rel.ro") == 0)
- is_relro = true;
- else if (strcmp(name, ".data.rel.ro.local") == 0)
- {
- is_relro = true;
- is_relro_local = true;
- }
- else if (strcmp(name, ".ctors") == 0
- || strcmp(name, ".dtors") == 0
- || strcmp(name, ".jcr") == 0)
- is_relro = true;
- }
- else if (type == elfcpp::SHT_INIT_ARRAY
- || type == elfcpp::SHT_FINI_ARRAY
- || type == elfcpp::SHT_PREINIT_ARRAY)
- is_relro = true;
- }
-
- if (is_relro)
- os->set_is_relro();
-
- if (order == ORDER_INVALID && (flags & elfcpp::SHF_ALLOC) != 0)
- order = this->default_section_order(os, is_relro_local);
-
- os->set_order(order);
-
- parameters->target().new_output_section(os);
-
- this->section_list_.push_back(os);
-
- // The GNU linker by default sorts some sections by priority, so we
- // do the same. We need to know that this might happen before we
- // attach any input sections.
- if (!this->script_options_->saw_sections_clause()
- && !parameters->options().relocatable()
- && (strcmp(name, ".init_array") == 0
- || strcmp(name, ".fini_array") == 0
- || (!parameters->options().ctors_in_init_array()
- && (strcmp(name, ".ctors") == 0
- || strcmp(name, ".dtors") == 0))))
- os->set_may_sort_attached_input_sections();
-
- // The GNU linker by default sorts .text.{unlikely,exit,startup,hot}
- // sections before other .text sections. We are compatible. We
- // need to know that this might happen before we attach any input
- // sections.
- if (parameters->options().text_reorder()
- && !this->script_options_->saw_sections_clause()
- && !this->is_section_ordering_specified()
- && !parameters->options().relocatable()
- && strcmp(name, ".text") == 0)
- os->set_may_sort_attached_input_sections();
-
- // GNU linker sorts section by name with --sort-section=name.
- if (strcmp(parameters->options().sort_section(), "name") == 0)
- os->set_must_sort_attached_input_sections();
-
- // Check for .stab*str sections, as .stab* sections need to link to
- // them.
- if (type == elfcpp::SHT_STRTAB
- && !this->have_stabstr_section_
- && strncmp(name, ".stab", 5) == 0
- && strcmp(name + strlen(name) - 3, "str") == 0)
- this->have_stabstr_section_ = true;
-
- // During a full incremental link, we add patch space to most
- // PROGBITS and NOBITS sections. Flag those that may be
- // arbitrarily padded.
- if ((type == elfcpp::SHT_PROGBITS || type == elfcpp::SHT_NOBITS)
- && order != ORDER_INTERP
- && order != ORDER_INIT
- && order != ORDER_PLT
- && order != ORDER_FINI
- && order != ORDER_RELRO_LAST
- && order != ORDER_NON_RELRO_FIRST
- && strcmp(name, ".eh_frame") != 0
- && strcmp(name, ".ctors") != 0
- && strcmp(name, ".dtors") != 0
- && strcmp(name, ".jcr") != 0)
- {
- os->set_is_patch_space_allowed();
-
- // Certain sections require "holes" to be filled with
- // specific fill patterns. These fill patterns may have
- // a minimum size, so we must prevent allocations from the
- // free list that leave a hole smaller than the minimum.
- if (strcmp(name, ".debug_info") == 0)
- os->set_free_space_fill(new Output_fill_debug_info(false));
- else if (strcmp(name, ".debug_types") == 0)
- os->set_free_space_fill(new Output_fill_debug_info(true));
- else if (strcmp(name, ".debug_line") == 0)
- os->set_free_space_fill(new Output_fill_debug_line());
- }
-
- // If we have already attached the sections to segments, then we
- // need to attach this one now. This happens for sections created
- // directly by the linker.
- if (this->sections_are_attached_)
- this->attach_section_to_segment(¶meters->target(), os);
-
- return os;
-}
-
-// Return the default order in which a section should be placed in an
-// output segment. This function captures a lot of the ideas in
-// ld/scripttempl/elf.sc in the GNU linker. Note that the order of a
-// linker created section is normally set when the section is created;
-// this function is used for input sections.
-
-Output_section_order
-Layout::default_section_order(Output_section* os, bool is_relro_local)
-{
- gold_assert((os->flags() & elfcpp::SHF_ALLOC) != 0);
- bool is_write = (os->flags() & elfcpp::SHF_WRITE) != 0;
- bool is_execinstr = (os->flags() & elfcpp::SHF_EXECINSTR) != 0;
- bool is_bss = false;
-
- switch (os->type())
- {
- default:
- case elfcpp::SHT_PROGBITS:
- break;
- case elfcpp::SHT_NOBITS:
- is_bss = true;
- break;
- case elfcpp::SHT_RELA:
- case elfcpp::SHT_REL:
- if (!is_write)
- return ORDER_DYNAMIC_RELOCS;
- break;
- case elfcpp::SHT_HASH:
- case elfcpp::SHT_DYNAMIC:
- case elfcpp::SHT_SHLIB:
- case elfcpp::SHT_DYNSYM:
- case elfcpp::SHT_GNU_HASH:
- case elfcpp::SHT_GNU_verdef:
- case elfcpp::SHT_GNU_verneed:
- case elfcpp::SHT_GNU_versym:
- if (!is_write)
- return ORDER_DYNAMIC_LINKER;
- break;
- case elfcpp::SHT_NOTE:
- return is_write ? ORDER_RW_NOTE : ORDER_RO_NOTE;
- }
-
- if ((os->flags() & elfcpp::SHF_TLS) != 0)
- return is_bss ? ORDER_TLS_BSS : ORDER_TLS_DATA;
-
- if (!is_bss && !is_write)
- {
- if (is_execinstr)
- {
- if (strcmp(os->name(), ".init") == 0)
- return ORDER_INIT;
- else if (strcmp(os->name(), ".fini") == 0)
- return ORDER_FINI;
- else if (parameters->options().keep_text_section_prefix())
- {
- // -z,keep-text-section-prefix introduces additional
- // output sections.
- if (strcmp(os->name(), ".text.hot") == 0)
- return ORDER_TEXT_HOT;
- else if (strcmp(os->name(), ".text.startup") == 0)
- return ORDER_TEXT_STARTUP;
- else if (strcmp(os->name(), ".text.exit") == 0)
- return ORDER_TEXT_EXIT;
- else if (strcmp(os->name(), ".text.unlikely") == 0)
- return ORDER_TEXT_UNLIKELY;
- }
- }
- return is_execinstr ? ORDER_TEXT : ORDER_READONLY;
- }
-
- if (os->is_relro())
- return is_relro_local ? ORDER_RELRO_LOCAL : ORDER_RELRO;
-
- if (os->is_small_section())
- return is_bss ? ORDER_SMALL_BSS : ORDER_SMALL_DATA;
- if (os->is_large_section())
- return is_bss ? ORDER_LARGE_BSS : ORDER_LARGE_DATA;
-
- return is_bss ? ORDER_BSS : ORDER_DATA;
-}
-
-// Attach output sections to segments. This is called after we have
-// seen all the input sections.
-
-void
-Layout::attach_sections_to_segments(const Target* target)
-{
- for (Section_list::iterator p = this->section_list_.begin();
- p != this->section_list_.end();
- ++p)
- this->attach_section_to_segment(target, *p);
-
- this->sections_are_attached_ = true;
-}
-
-// Attach an output section to a segment.
-
-void
-Layout::attach_section_to_segment(const Target* target, Output_section* os)
-{
- if ((os->flags() & elfcpp::SHF_ALLOC) == 0)
- this->unattached_section_list_.push_back(os);
- else
- this->attach_allocated_section_to_segment(target, os);
-}
-
-// Attach an allocated output section to a segment.
-
-void
-Layout::attach_allocated_section_to_segment(const Target* target,
- Output_section* os)
-{
- elfcpp::Elf_Xword flags = os->flags();
- gold_assert((flags & elfcpp::SHF_ALLOC) != 0);
-
- if (parameters->options().relocatable())
- return;
-
- // If we have a SECTIONS clause, we can't handle the attachment to
- // segments until after we've seen all the sections.
- if (this->script_options_->saw_sections_clause())
- return;
-
- gold_assert(!this->script_options_->saw_phdrs_clause());
-
- // This output section goes into a PT_LOAD segment.
-
- elfcpp::Elf_Word seg_flags = Layout::section_flags_to_segment(flags);
-
- // If this output section's segment has extra flags that need to be set,
- // coming from a linker plugin, do that.
- seg_flags |= os->extra_segment_flags();
-
- // Check for --section-start.
- uint64_t addr;
- bool is_address_set = parameters->options().section_start(os->name(), &addr);
-
- // In general the only thing we really care about for PT_LOAD
- // segments is whether or not they are writable or executable,
- // so that is how we search for them.
- // Large data sections also go into their own PT_LOAD segment.
- // People who need segments sorted on some other basis will
- // have to use a linker script.
-
- Segment_list::const_iterator p;
- if (!os->is_unique_segment())
- {
- for (p = this->segment_list_.begin();
- p != this->segment_list_.end();
- ++p)
- {
- if ((*p)->type() != elfcpp::PT_LOAD)
- continue;
- if ((*p)->is_unique_segment())
- continue;
- if (!parameters->options().omagic()
- && ((*p)->flags() & elfcpp::PF_W) != (seg_flags & elfcpp::PF_W))
- continue;
- if ((target->isolate_execinstr() || parameters->options().rosegment())
- && ((*p)->flags() & elfcpp::PF_X) != (seg_flags & elfcpp::PF_X))
- continue;
- // If -Tbss was specified, we need to separate the data and BSS
- // segments.
- if (parameters->options().user_set_Tbss())
- {
- if ((os->type() == elfcpp::SHT_NOBITS)
- == (*p)->has_any_data_sections())
- continue;
- }
- if (os->is_large_data_section() && !(*p)->is_large_data_segment())
- continue;
-
- if (is_address_set)
- {
- if ((*p)->are_addresses_set())
- continue;
-
- (*p)->add_initial_output_data(os);
- (*p)->update_flags_for_output_section(seg_flags);
- (*p)->set_addresses(addr, addr);
- break;
- }
-
- (*p)->add_output_section_to_load(this, os, seg_flags);
- break;
- }
- }
-
- if (p == this->segment_list_.end()
- || os->is_unique_segment())
- {
- Output_segment* oseg = this->make_output_segment(elfcpp::PT_LOAD,
- seg_flags);
- if (os->is_large_data_section())
- oseg->set_is_large_data_segment();
- oseg->add_output_section_to_load(this, os, seg_flags);
- if (is_address_set)
- oseg->set_addresses(addr, addr);
- // Check if segment should be marked unique. For segments marked
- // unique by linker plugins, set the new alignment if specified.
- if (os->is_unique_segment())
- {
- oseg->set_is_unique_segment();
- if (os->segment_alignment() != 0)
- oseg->set_minimum_p_align(os->segment_alignment());
- }
- }
-
- // If we see a loadable SHT_NOTE section, we create a PT_NOTE
- // segment.
- if (os->type() == elfcpp::SHT_NOTE)
- {
- uint64_t os_align = os->addralign();
-
- // See if we already have an equivalent PT_NOTE segment.
- for (p = this->segment_list_.begin();
- p != segment_list_.end();
- ++p)
- {
- if ((*p)->type() == elfcpp::PT_NOTE
- && (*p)->align() == os_align
- && (((*p)->flags() & elfcpp::PF_W)
- == (seg_flags & elfcpp::PF_W)))
- {
- (*p)->add_output_section_to_nonload(os, seg_flags);
- break;
- }
- }
-
- if (p == this->segment_list_.end())
- {
- Output_segment* oseg = this->make_output_segment(elfcpp::PT_NOTE,
- seg_flags);
- oseg->add_output_section_to_nonload(os, seg_flags);
- oseg->set_align(os_align);
- }
- }
-
- // If we see a loadable SHF_TLS section, we create a PT_TLS
- // segment. There can only be one such segment.
- if ((flags & elfcpp::SHF_TLS) != 0)
- {
- if (this->tls_segment_ == NULL)
- this->make_output_segment(elfcpp::PT_TLS, seg_flags);
- this->tls_segment_->add_output_section_to_nonload(os, seg_flags);
- }
-
- // If -z relro is in effect, and we see a relro section, we create a
- // PT_GNU_RELRO segment. There can only be one such segment.
- if (os->is_relro() && parameters->options().relro())
- {
- gold_assert(seg_flags == (elfcpp::PF_R | elfcpp::PF_W));
- if (this->relro_segment_ == NULL)
- this->make_output_segment(elfcpp::PT_GNU_RELRO, seg_flags);
- this->relro_segment_->add_output_section_to_nonload(os, seg_flags);
- }
-
- // If we see a section named .interp, put it into a PT_INTERP
- // segment. This seems broken to me, but this is what GNU ld does,
- // and glibc expects it.
- if (strcmp(os->name(), ".interp") == 0
- && !this->script_options_->saw_phdrs_clause())
- {
- if (this->interp_segment_ == NULL)
- this->make_output_segment(elfcpp::PT_INTERP, seg_flags);
- else
- gold_warning(_("multiple '.interp' sections in input files "
- "may cause confusing PT_INTERP segment"));
- this->interp_segment_->add_output_section_to_nonload(os, seg_flags);
- }
-}
-
-// Make an output section for a script.
-
-Output_section*
-Layout::make_output_section_for_script(
- const char* name,
- Script_sections::Section_type section_type)
-{
- name = this->namepool_.add(name, false, NULL);
- elfcpp::Elf_Xword sh_flags = elfcpp::SHF_ALLOC;
- if (section_type == Script_sections::ST_NOLOAD)
- sh_flags = 0;
- Output_section* os = this->make_output_section(name, elfcpp::SHT_PROGBITS,
- sh_flags, ORDER_INVALID,
- false);
- os->set_found_in_sections_clause();
- if (section_type == Script_sections::ST_NOLOAD)
- os->set_is_noload();
- return os;
-}
-
-// Return the number of segments we expect to see.
-
-size_t
-Layout::expected_segment_count() const
-{
- size_t ret = this->segment_list_.size();
-
- // If we didn't see a SECTIONS clause in a linker script, we should
- // already have the complete list of segments. Otherwise we ask the
- // SECTIONS clause how many segments it expects, and add in the ones
- // we already have (PT_GNU_STACK, PT_GNU_EH_FRAME, etc.)
-
- if (!this->script_options_->saw_sections_clause())
- return ret;
- else
- {
- const Script_sections* ss = this->script_options_->script_sections();
- return ret + ss->expected_segment_count(this);
- }
-}
-
-// Handle the .note.GNU-stack section at layout time. SEEN_GNU_STACK
-// is whether we saw a .note.GNU-stack section in the object file.
-// GNU_STACK_FLAGS is the section flags. The flags give the
-// protection required for stack memory. We record this in an
-// executable as a PT_GNU_STACK segment. If an object file does not
-// have a .note.GNU-stack segment, we must assume that it is an old
-// object. On some targets that will force an executable stack.
-
-void
-Layout::layout_gnu_stack(bool seen_gnu_stack, uint64_t gnu_stack_flags,
- const Object* obj)
-{
- if (!seen_gnu_stack)
- {
- this->input_without_gnu_stack_note_ = true;
- if (parameters->options().warn_execstack()
- && parameters->target().is_default_stack_executable())
- gold_warning(_("%s: missing .note.GNU-stack section"
- " implies executable stack"),
- obj->name().c_str());
- }
- else
- {
- this->input_with_gnu_stack_note_ = true;
- if ((gnu_stack_flags & elfcpp::SHF_EXECINSTR) != 0)
- {
- this->input_requires_executable_stack_ = true;
- if (parameters->options().warn_execstack())
- gold_warning(_("%s: requires executable stack"),
- obj->name().c_str());
- }
- }
-}
-
-// Read a value with given size and endianness.
-
-static inline uint64_t
-read_sized_value(size_t size, const unsigned char* buf, bool is_big_endian,
- const Object* object)
-{
- uint64_t val = 0;
- if (size == 4)
- {
- if (is_big_endian)
- val = elfcpp::Swap<32, true>::readval(buf);
- else
- val = elfcpp::Swap<32, false>::readval(buf);
- }
- else if (size == 8)
- {
- if (is_big_endian)
- val = elfcpp::Swap<64, true>::readval(buf);
- else
- val = elfcpp::Swap<64, false>::readval(buf);
- }
- else
- {
- gold_warning(_("%s: in .note.gnu.property section, "
- "pr_datasz must be 4 or 8"),
- object->name().c_str());
- }
- return val;
-}
-
-// Write a value with given size and endianness.
-
-static inline void
-write_sized_value(uint64_t value, size_t size, unsigned char* buf,
- bool is_big_endian)
-{
- if (size == 4)
- {
- if (is_big_endian)
- elfcpp::Swap<32, true>::writeval(buf, static_cast<uint32_t>(value));
- else
- elfcpp::Swap<32, false>::writeval(buf, static_cast<uint32_t>(value));
- }
- else if (size == 8)
- {
- if (is_big_endian)
- elfcpp::Swap<64, true>::writeval(buf, value);
- else
- elfcpp::Swap<64, false>::writeval(buf, value);
- }
- else
- {
- // We will have already complained about this.
- }
-}
-
-// Handle the .note.gnu.property section at layout time.
-
-void
-Layout::layout_gnu_property(unsigned int note_type,
- unsigned int pr_type,
- size_t pr_datasz,
- const unsigned char* pr_data,
- const Object* object)
-{
- // We currently support only the one note type.
- gold_assert(note_type == elfcpp::NT_GNU_PROPERTY_TYPE_0);
-
- if (pr_type >= elfcpp::GNU_PROPERTY_LOPROC
- && pr_type < elfcpp::GNU_PROPERTY_HIPROC)
- {
- // Target-dependent property value; call the target to record.
- const int size = parameters->target().get_size();
- const bool is_big_endian = parameters->target().is_big_endian();
- if (size == 32)
- {
- if (is_big_endian)
- {
-#ifdef HAVE_TARGET_32_BIG
- parameters->sized_target<32, true>()->
- record_gnu_property(note_type, pr_type, pr_datasz, pr_data,
- object);
-#else
- gold_unreachable();
-#endif
- }
- else
- {
-#ifdef HAVE_TARGET_32_LITTLE
- parameters->sized_target<32, false>()->
- record_gnu_property(note_type, pr_type, pr_datasz, pr_data,
- object);
-#else
- gold_unreachable();
-#endif
- }
- }
- else if (size == 64)
- {
- if (is_big_endian)
- {
-#ifdef HAVE_TARGET_64_BIG
- parameters->sized_target<64, true>()->
- record_gnu_property(note_type, pr_type, pr_datasz, pr_data,
- object);
-#else
- gold_unreachable();
-#endif
- }
- else
- {
-#ifdef HAVE_TARGET_64_LITTLE
- parameters->sized_target<64, false>()->
- record_gnu_property(note_type, pr_type, pr_datasz, pr_data,
- object);
-#else
- gold_unreachable();
-#endif
- }
- }
- else
- gold_unreachable();
- return;
- }
-
- Gnu_properties::iterator pprop = this->gnu_properties_.find(pr_type);
- if (pprop == this->gnu_properties_.end())
- {
- Gnu_property prop;
- prop.pr_datasz = pr_datasz;
- prop.pr_data = new unsigned char[pr_datasz];
- memcpy(prop.pr_data, pr_data, pr_datasz);
- this->gnu_properties_[pr_type] = prop;
- }
- else
- {
- const bool is_big_endian = parameters->target().is_big_endian();
- switch (pr_type)
- {
- case elfcpp::GNU_PROPERTY_STACK_SIZE:
- // Record the maximum value seen.
- {
- uint64_t val1 = read_sized_value(pprop->second.pr_datasz,
- pprop->second.pr_data,
- is_big_endian, object);
- uint64_t val2 = read_sized_value(pr_datasz, pr_data,
- is_big_endian, object);
- if (val2 > val1)
- write_sized_value(val2, pprop->second.pr_datasz,
- pprop->second.pr_data, is_big_endian);
- }
- break;
- case elfcpp::GNU_PROPERTY_NO_COPY_ON_PROTECTED:
- // No data to merge.
- break;
- default:
- gold_warning(_("%s: unknown program property type %d "
- "in .note.gnu.property section"),
- object->name().c_str(), pr_type);
- }
- }
-}
-
-// Merge per-object properties with program properties.
-// This lets the target identify objects that are missing certain
-// properties, in cases where properties must be ANDed together.
-
-void
-Layout::merge_gnu_properties(const Object* object)
-{
- const int size = parameters->target().get_size();
- const bool is_big_endian = parameters->target().is_big_endian();
- if (size == 32)
- {
- if (is_big_endian)
- {
-#ifdef HAVE_TARGET_32_BIG
- parameters->sized_target<32, true>()->merge_gnu_properties(object);
-#else
- gold_unreachable();
-#endif
- }
- else
- {
-#ifdef HAVE_TARGET_32_LITTLE
- parameters->sized_target<32, false>()->merge_gnu_properties(object);
-#else
- gold_unreachable();
-#endif
- }
- }
- else if (size == 64)
- {
- if (is_big_endian)
- {
-#ifdef HAVE_TARGET_64_BIG
- parameters->sized_target<64, true>()->merge_gnu_properties(object);
-#else
- gold_unreachable();
-#endif
- }
- else
- {
-#ifdef HAVE_TARGET_64_LITTLE
- parameters->sized_target<64, false>()->merge_gnu_properties(object);
-#else
- gold_unreachable();
-#endif
- }
- }
- else
- gold_unreachable();
-}
-
-// Add a target-specific property for the output .note.gnu.property section.
-
-void
-Layout::add_gnu_property(unsigned int note_type,
- unsigned int pr_type,
- size_t pr_datasz,
- const unsigned char* pr_data)
-{
- gold_assert(note_type == elfcpp::NT_GNU_PROPERTY_TYPE_0);
-
- Gnu_property prop;
- prop.pr_datasz = pr_datasz;
- prop.pr_data = new unsigned char[pr_datasz];
- memcpy(prop.pr_data, pr_data, pr_datasz);
- this->gnu_properties_[pr_type] = prop;
-}
-
-// Create automatic note sections.
-
-void
-Layout::create_notes()
-{
- this->create_gnu_properties_note();
- this->create_gold_note();
- this->create_stack_segment();
- this->create_build_id();
- this->create_package_metadata();
-}
-
-// Create the dynamic sections which are needed before we read the
-// relocs.
-
-void
-Layout::create_initial_dynamic_sections(Symbol_table* symtab)
-{
- if (parameters->doing_static_link())
- return;
-
- this->dynamic_section_ = this->choose_output_section(NULL, ".dynamic",
- elfcpp::SHT_DYNAMIC,
- (elfcpp::SHF_ALLOC
- | elfcpp::SHF_WRITE),
- false, ORDER_RELRO,
- true, false, false);
-
- // A linker script may discard .dynamic, so check for NULL.
- if (this->dynamic_section_ != NULL)
- {
- this->dynamic_symbol_ =
- symtab->define_in_output_data("_DYNAMIC", NULL,
- Symbol_table::PREDEFINED,
- this->dynamic_section_, 0, 0,
- elfcpp::STT_OBJECT, elfcpp::STB_LOCAL,
- elfcpp::STV_HIDDEN, 0, false, false);
-
- this->dynamic_data_ = new Output_data_dynamic(&this->dynpool_);
-
- this->dynamic_section_->add_output_section_data(this->dynamic_data_);
- }
-}
-
-// For each output section whose name can be represented as C symbol,
-// define __start and __stop symbols for the section. This is a GNU
-// extension.
-
-void
-Layout::define_section_symbols(Symbol_table* symtab)
-{
- const elfcpp::STV visibility = parameters->options().start_stop_visibility_enum();
- for (Section_list::const_iterator p = this->section_list_.begin();
- p != this->section_list_.end();
- ++p)
- {
- const char* const name = (*p)->name();
- if (is_cident(name))
- {
- const std::string name_string(name);
- const std::string start_name(cident_section_start_prefix
- + name_string);
- const std::string stop_name(cident_section_stop_prefix
- + name_string);
-
- symtab->define_in_output_data(start_name.c_str(),
- NULL, // version
- Symbol_table::PREDEFINED,
- *p,
- 0, // value
- 0, // symsize
- elfcpp::STT_NOTYPE,
- elfcpp::STB_GLOBAL,
- visibility,
- 0, // nonvis
- false, // offset_is_from_end
- true); // only_if_ref
-
- symtab->define_in_output_data(stop_name.c_str(),
- NULL, // version
- Symbol_table::PREDEFINED,
- *p,
- 0, // value
- 0, // symsize
- elfcpp::STT_NOTYPE,
- elfcpp::STB_GLOBAL,
- visibility,
- 0, // nonvis
- true, // offset_is_from_end
- true); // only_if_ref
- }
- }
-}
-
-// Define symbols for group signatures.
-
-void
-Layout::define_group_signatures(Symbol_table* symtab)
-{
- for (Group_signatures::iterator p = this->group_signatures_.begin();
- p != this->group_signatures_.end();
- ++p)
- {
- Symbol* sym = symtab->lookup(p->signature, NULL);
- if (sym != NULL)
- p->section->set_info_symndx(sym);
- else
- {
- // Force the name of the group section to the group
- // signature, and use the group's section symbol as the
- // signature symbol.
- if (strcmp(p->section->name(), p->signature) != 0)
- {
- const char* name = this->namepool_.add(p->signature,
- true, NULL);
- p->section->set_name(name);
- }
- p->section->set_needs_symtab_index();
- p->section->set_info_section_symndx(p->section);
- }
- }
-
- this->group_signatures_.clear();
-}
-
-// Find the first read-only PT_LOAD segment, creating one if
-// necessary.
-
-Output_segment*
-Layout::find_first_load_seg(const Target* target)
-{
- Output_segment* best = NULL;
- for (Segment_list::const_iterator p = this->segment_list_.begin();
- p != this->segment_list_.end();
- ++p)
- {
- if ((*p)->type() == elfcpp::PT_LOAD
- && ((*p)->flags() & elfcpp::PF_R) != 0
- && (parameters->options().omagic()
- || ((*p)->flags() & elfcpp::PF_W) == 0)
- && (!target->isolate_execinstr()
- || ((*p)->flags() & elfcpp::PF_X) == 0))
- {
- if (best == NULL || this->segment_precedes(*p, best))
- best = *p;
- }
- }
- if (best != NULL)
- return best;
-
- gold_assert(!this->script_options_->saw_phdrs_clause());
-
- Output_segment* load_seg = this->make_output_segment(elfcpp::PT_LOAD,
- elfcpp::PF_R);
- return load_seg;
-}
-
-// Save states of all current output segments. Store saved states
-// in SEGMENT_STATES.
-
-void
-Layout::save_segments(Segment_states* segment_states)
-{
- for (Segment_list::const_iterator p = this->segment_list_.begin();
- p != this->segment_list_.end();
- ++p)
- {
- Output_segment* segment = *p;
- // Shallow copy.
- Output_segment* copy = new Output_segment(*segment);
- (*segment_states)[segment] = copy;
- }
-}
-
-// Restore states of output segments and delete any segment not found in
-// SEGMENT_STATES.
-
-void
-Layout::restore_segments(const Segment_states* segment_states)
-{
- // Go through the segment list and remove any segment added in the
- // relaxation loop.
- this->tls_segment_ = NULL;
- this->relro_segment_ = NULL;
- Segment_list::iterator list_iter = this->segment_list_.begin();
- while (list_iter != this->segment_list_.end())
- {
- Output_segment* segment = *list_iter;
- Segment_states::const_iterator states_iter =
- segment_states->find(segment);
- if (states_iter != segment_states->end())
- {
- const Output_segment* copy = states_iter->second;
- // Shallow copy to restore states.
- *segment = *copy;
-
- // Also fix up TLS and RELRO segment pointers as appropriate.
- if (segment->type() == elfcpp::PT_TLS)
- this->tls_segment_ = segment;
- else if (segment->type() == elfcpp::PT_GNU_RELRO)
- this->relro_segment_ = segment;
-
- ++list_iter;
- }
- else
- {
- list_iter = this->segment_list_.erase(list_iter);
- // This is a segment created during section layout. It should be
- // safe to remove it since we should have removed all pointers to it.
- delete segment;
- }
- }
-}
-
-// Clean up after relaxation so that sections can be laid out again.
-
-void
-Layout::clean_up_after_relaxation()
-{
- // Restore the segments to point state just prior to the relaxation loop.
- Script_sections* script_section = this->script_options_->script_sections();
- script_section->release_segments();
- this->restore_segments(this->segment_states_);
-
- // Reset section addresses and file offsets
- for (Section_list::iterator p = this->section_list_.begin();
- p != this->section_list_.end();
- ++p)
- {
- (*p)->restore_states();
-
- // If an input section changes size because of relaxation,
- // we need to adjust the section offsets of all input sections.
- // after such a section.
- if ((*p)->section_offsets_need_adjustment())
- (*p)->adjust_section_offsets();
-
- (*p)->reset_address_and_file_offset();
- }
-
- // Reset special output object address and file offsets.
- for (Data_list::iterator p = this->special_output_list_.begin();
- p != this->special_output_list_.end();
- ++p)
- (*p)->reset_address_and_file_offset();
-
- // A linker script may have created some output section data objects.
- // They are useless now.
- for (Output_section_data_list::const_iterator p =
- this->script_output_section_data_list_.begin();
- p != this->script_output_section_data_list_.end();
- ++p)
- delete *p;
- this->script_output_section_data_list_.clear();
-
- // Special-case fill output objects are recreated each time through
- // the relaxation loop.
- this->reset_relax_output();
-}
-
-void
-Layout::reset_relax_output()
-{
- for (Data_list::const_iterator p = this->relax_output_list_.begin();
- p != this->relax_output_list_.end();
- ++p)
- delete *p;
- this->relax_output_list_.clear();
-}
-
-// Prepare for relaxation.
-
-void
-Layout::prepare_for_relaxation()
-{
- // Create an relaxation debug check if in debugging mode.
- if (is_debugging_enabled(DEBUG_RELAXATION))
- this->relaxation_debug_check_ = new Relaxation_debug_check();
-
- // Save segment states.
- this->segment_states_ = new Segment_states();
- this->save_segments(this->segment_states_);
-
- for(Section_list::const_iterator p = this->section_list_.begin();
- p != this->section_list_.end();
- ++p)
- (*p)->save_states();
-
- if (is_debugging_enabled(DEBUG_RELAXATION))
- this->relaxation_debug_check_->check_output_data_for_reset_values(
- this->section_list_, this->special_output_list_,
- this->relax_output_list_);
-
- // Also enable recording of output section data from scripts.
- this->record_output_section_data_from_script_ = true;
-}
-
-// If the user set the address of the text segment, that may not be
-// compatible with putting the segment headers and file headers into
-// that segment. For isolate_execinstr() targets, it's the rodata
-// segment rather than text where we might put the headers.
-static inline bool
-load_seg_unusable_for_headers(const Target* target)
-{
- const General_options& options = parameters->options();
- if (target->isolate_execinstr())
- return (options.user_set_Trodata_segment()
- && options.Trodata_segment() % target->abi_pagesize() != 0);
- else
- return (options.user_set_Ttext()
- && options.Ttext() % target->abi_pagesize() != 0);
-}
-
-// Relaxation loop body: If target has no relaxation, this runs only once
-// Otherwise, the target relaxation hook is called at the end of
-// each iteration. If the hook returns true, it means re-layout of
-// section is required.
-//
-// The number of segments created by a linking script without a PHDRS
-// clause may be affected by section sizes and alignments. There is
-// a remote chance that relaxation causes different number of PT_LOAD
-// segments are created and sections are attached to different segments.
-// Therefore, we always throw away all segments created during section
-// layout. In order to be able to restart the section layout, we keep
-// a copy of the segment list right before the relaxation loop and use
-// that to restore the segments.
-//
-// PASS is the current relaxation pass number.
-// SYMTAB is a symbol table.
-// PLOAD_SEG is the address of a pointer for the load segment.
-// PHDR_SEG is a pointer to the PHDR segment.
-// SEGMENT_HEADERS points to the output segment header.
-// FILE_HEADER points to the output file header.
-// PSHNDX is the address to store the output section index.
-
-off_t inline
-Layout::relaxation_loop_body(
- int pass,
- Target* target,
- Symbol_table* symtab,
- Output_segment** pload_seg,
- Output_segment* phdr_seg,
- Output_segment_headers* segment_headers,
- Output_file_header* file_header,
- unsigned int* pshndx)
-{
- // If this is not the first iteration, we need to clean up after
- // relaxation so that we can lay out the sections again.
- if (pass != 0)
- this->clean_up_after_relaxation();
-
- // If there is a SECTIONS clause, put all the input sections into
- // the required order.
- Output_segment* load_seg;
- if (this->script_options_->saw_sections_clause())
- load_seg = this->set_section_addresses_from_script(symtab);
- else if (parameters->options().relocatable())
- load_seg = NULL;
- else
- load_seg = this->find_first_load_seg(target);
-
- if (parameters->options().oformat_enum()
- != General_options::OBJECT_FORMAT_ELF)
- load_seg = NULL;
-
- if (load_seg_unusable_for_headers(target))
- {
- load_seg = NULL;
- phdr_seg = NULL;
- }
-
- gold_assert(phdr_seg == NULL
- || load_seg != NULL
- || this->script_options_->saw_sections_clause());
-
- // If the address of the load segment we found has been set by
- // --section-start rather than by a script, then adjust the VMA and
- // LMA downward if possible to include the file and section headers.
- uint64_t header_gap = 0;
- if (load_seg != NULL
- && load_seg->are_addresses_set()
- && !this->script_options_->saw_sections_clause()
- && !parameters->options().relocatable())
- {
- file_header->finalize_data_size();
- segment_headers->finalize_data_size();
- size_t sizeof_headers = (file_header->data_size()
- + segment_headers->data_size());
- const uint64_t abi_pagesize = target->abi_pagesize();
- uint64_t hdr_paddr = load_seg->paddr() - sizeof_headers;
- hdr_paddr &= ~(abi_pagesize - 1);
- uint64_t subtract = load_seg->paddr() - hdr_paddr;
- if (load_seg->paddr() < subtract || load_seg->vaddr() < subtract)
- load_seg = NULL;
- else
- {
- load_seg->set_addresses(load_seg->vaddr() - subtract,
- load_seg->paddr() - subtract);
- header_gap = subtract - sizeof_headers;
- }
- }
-
- // Lay out the segment headers.
- if (!parameters->options().relocatable())
- {
- gold_assert(segment_headers != NULL);
- if (header_gap != 0 && load_seg != NULL)
- {
- Output_data_zero_fill* z = new Output_data_zero_fill(header_gap, 1);
- load_seg->add_initial_output_data(z);
- }
- if (load_seg != NULL)
- load_seg->add_initial_output_data(segment_headers);
- if (phdr_seg != NULL)
- phdr_seg->add_initial_output_data(segment_headers);
- }
-
- // Lay out the file header.
- if (load_seg != NULL)
- load_seg->add_initial_output_data(file_header);
-
- if (this->script_options_->saw_phdrs_clause()
- && !parameters->options().relocatable())
- {
- // Support use of FILEHDRS and PHDRS attachments in a PHDRS
- // clause in a linker script.
- Script_sections* ss = this->script_options_->script_sections();
- ss->put_headers_in_phdrs(file_header, segment_headers);
- }
-
- // We set the output section indexes in set_segment_offsets and
- // set_section_indexes.
- *pshndx = 1;
-
- // Set the file offsets of all the segments, and all the sections
- // they contain.
- off_t off;
- if (!parameters->options().relocatable())
- off = this->set_segment_offsets(target, load_seg, pshndx);
- else
- off = this->set_relocatable_section_offsets(file_header, pshndx);
-
- // Verify that the dummy relaxation does not change anything.
- if (is_debugging_enabled(DEBUG_RELAXATION))
- {
- if (pass == 0)
- this->relaxation_debug_check_->read_sections(this->section_list_);
- else
- this->relaxation_debug_check_->verify_sections(this->section_list_);
- }
-
- *pload_seg = load_seg;
- return off;
-}
-
-// Search the list of patterns and find the position of the given section
-// name in the output section. If the section name matches a glob
-// pattern and a non-glob name, then the non-glob position takes
-// precedence. Return 0 if no match is found.
-
-unsigned int
-Layout::find_section_order_index(const std::string& section_name)
-{
- Unordered_map<std::string, unsigned int>::iterator map_it;
- map_it = this->input_section_position_.find(section_name);
- if (map_it != this->input_section_position_.end())
- return map_it->second;
-
- // Absolute match failed. Linear search the glob patterns.
- std::vector<std::string>::iterator it;
- for (it = this->input_section_glob_.begin();
- it != this->input_section_glob_.end();
- ++it)
- {
- if (fnmatch((*it).c_str(), section_name.c_str(), FNM_NOESCAPE) == 0)
- {
- map_it = this->input_section_position_.find(*it);
- gold_assert(map_it != this->input_section_position_.end());
- return map_it->second;
- }
- }
- return 0;
-}
-
-// Read the sequence of input sections from the file specified with
-// option --section-ordering-file.
-
-void
-Layout::read_layout_from_file()
-{
- const char* filename = parameters->options().section_ordering_file();
- std::ifstream in;
- std::string line;
-
- in.open(filename);
- if (!in)
- gold_fatal(_("unable to open --section-ordering-file file %s: %s"),
- filename, strerror(errno));
-
- File_read::record_file_read(filename);
-
- std::getline(in, line); // this chops off the trailing \n, if any
- unsigned int position = 1;
- this->set_section_ordering_specified();
-
- while (in)
- {
- if (!line.empty() && line[line.length() - 1] == '\r') // Windows
- line.resize(line.length() - 1);
- // Ignore comments, beginning with '#'
- if (line[0] == '#')
- {
- std::getline(in, line);
- continue;
- }
- this->input_section_position_[line] = position;
- // Store all glob patterns in a vector.
- if (is_wildcard_string(line.c_str()))
- this->input_section_glob_.push_back(line);
- position++;
- std::getline(in, line);
- }
-}
-
-// Finalize the layout. When this is called, we have created all the
-// output sections and all the output segments which are based on
-// input sections. We have several things to do, and we have to do
-// them in the right order, so that we get the right results correctly
-// and efficiently.
-
-// 1) Finalize the list of output segments and create the segment
-// table header.
-
-// 2) Finalize the dynamic symbol table and associated sections.
-
-// 3) Determine the final file offset of all the output segments.
-
-// 4) Determine the final file offset of all the SHF_ALLOC output
-// sections.
-
-// 5) Create the symbol table sections and the section name table
-// section.
-
-// 6) Finalize the symbol table: set symbol values to their final
-// value and make a final determination of which symbols are going
-// into the output symbol table.
-
-// 7) Create the section table header.
-
-// 8) Determine the final file offset of all the output sections which
-// are not SHF_ALLOC, including the section table header.
-
-// 9) Finalize the ELF file header.
-
-// This function returns the size of the output file.
-
-off_t
-Layout::finalize(const Input_objects* input_objects, Symbol_table* symtab,
- Target* target, const Task* task)
-{
- unsigned int local_dynamic_count = 0;
- unsigned int forced_local_dynamic_count = 0;
-
- target->finalize_sections(this, input_objects, symtab);
-
- this->count_local_symbols(task, input_objects);
-
- this->link_stabs_sections();
-
- Output_segment* phdr_seg = NULL;
- if (!parameters->options().relocatable() && !parameters->doing_static_link())
- {
- // There was a dynamic object in the link. We need to create
- // some information for the dynamic linker.
-
- // Create the PT_PHDR segment which will hold the program
- // headers.
- if (!this->script_options_->saw_phdrs_clause())
- phdr_seg = this->make_output_segment(elfcpp::PT_PHDR, elfcpp::PF_R);
-
- // Create the dynamic symbol table, including the hash table.
- Output_section* dynstr;
- std::vector<Symbol*> dynamic_symbols;
- Versions versions(*this->script_options()->version_script_info(),
- &this->dynpool_);
- this->create_dynamic_symtab(input_objects, symtab, &dynstr,
- &local_dynamic_count,
- &forced_local_dynamic_count,
- &dynamic_symbols,
- &versions);
-
- // Create the .interp section to hold the name of the
- // interpreter, and put it in a PT_INTERP segment. Don't do it
- // if we saw a .interp section in an input file.
- if ((!parameters->options().shared()
- || parameters->options().dynamic_linker() != NULL)
- && this->interp_segment_ == NULL)
- this->create_interp(target);
-
- // Finish the .dynamic section to hold the dynamic data, and put
- // it in a PT_DYNAMIC segment.
- this->finish_dynamic_section(input_objects, symtab);
-
- // We should have added everything we need to the dynamic string
- // table.
- this->dynpool_.set_string_offsets();
-
- // Create the version sections. We can't do this until the
- // dynamic string table is complete.
- this->create_version_sections(&versions, symtab,
- (local_dynamic_count
- + forced_local_dynamic_count),
- dynamic_symbols, dynstr);
-
- // Set the size of the _DYNAMIC symbol. We can't do this until
- // after we call create_version_sections.
- this->set_dynamic_symbol_size(symtab);
- }
-
- // Create segment headers.
- Output_segment_headers* segment_headers =
- (parameters->options().relocatable()
- ? NULL
- : new Output_segment_headers(this->segment_list_));
-
- // Lay out the file header.
- Output_file_header* file_header = new Output_file_header(target, symtab,
- segment_headers);
-
- this->special_output_list_.push_back(file_header);
- if (segment_headers != NULL)
- this->special_output_list_.push_back(segment_headers);
-
- // Find approriate places for orphan output sections if we are using
- // a linker script.
- if (this->script_options_->saw_sections_clause())
- this->place_orphan_sections_in_script();
-
- Output_segment* load_seg;
- off_t off;
- unsigned int shndx;
- int pass = 0;
-
- // Take a snapshot of the section layout as needed.
- if (target->may_relax())
- this->prepare_for_relaxation();
-
- // Run the relaxation loop to lay out sections.
- do
- {
- off = this->relaxation_loop_body(pass, target, symtab, &load_seg,
- phdr_seg, segment_headers, file_header,
- &shndx);
- pass++;
- }
- while (target->may_relax()
- && target->relax(pass, input_objects, symtab, this, task));
-
- // If there is a load segment that contains the file and program headers,
- // provide a symbol __ehdr_start pointing there.
- // A program can use this to examine itself robustly.
- Symbol *ehdr_start = symtab->lookup("__ehdr_start");
- if (ehdr_start != NULL && ehdr_start->is_predefined())
- {
- if (load_seg != NULL)
- ehdr_start->set_output_segment(load_seg, Symbol::SEGMENT_START);
- else
- ehdr_start->set_undefined();
- }
-
- // Set the file offsets of all the non-data sections we've seen so
- // far which don't have to wait for the input sections. We need
- // this in order to finalize local symbols in non-allocated
- // sections.
- off = this->set_section_offsets(off, BEFORE_INPUT_SECTIONS_PASS);
-
- // Set the section indexes of all unallocated sections seen so far,
- // in case any of them are somehow referenced by a symbol.
- shndx = this->set_section_indexes(shndx);
-
- // Create the symbol table sections.
- this->create_symtab_sections(input_objects, symtab, shndx, &off,
- local_dynamic_count);
- if (!parameters->doing_static_link())
- this->assign_local_dynsym_offsets(input_objects);
-
- // Process any symbol assignments from a linker script. This must
- // be called after the symbol table has been finalized.
- this->script_options_->finalize_symbols(symtab, this);
-
- // Create the incremental inputs sections.
- if (this->incremental_inputs_)
- {
- this->incremental_inputs_->finalize();
- this->create_incremental_info_sections(symtab);
- }
-
- // Create the .shstrtab section.
- Output_section* shstrtab_section = this->create_shstrtab();
-
- // Set the file offsets of the rest of the non-data sections which
- // don't have to wait for the input sections.
- off = this->set_section_offsets(off, BEFORE_INPUT_SECTIONS_PASS);
-
- // Now that all sections have been created, set the section indexes
- // for any sections which haven't been done yet.
- shndx = this->set_section_indexes(shndx);
-
- // Create the section table header.
- this->create_shdrs(shstrtab_section, &off);
-
- // If there are no sections which require postprocessing, we can
- // handle the section names now, and avoid a resize later.
- if (!this->any_postprocessing_sections_)
- {
- off = this->set_section_offsets(off,
- POSTPROCESSING_SECTIONS_PASS);
- off =
- this->set_section_offsets(off,
- STRTAB_AFTER_POSTPROCESSING_SECTIONS_PASS);
- }
-
- file_header->set_section_info(this->section_headers_, shstrtab_section);
-
- // Now we know exactly where everything goes in the output file
- // (except for non-allocated sections which require postprocessing).
- Output_data::layout_complete();
-
- this->output_file_size_ = off;
-
- return off;
-}
-
-// Create a note header following the format defined in the ELF ABI.
-// NAME is the name, NOTE_TYPE is the type, SECTION_NAME is the name
-// of the section to create, DESCSZ is the size of the descriptor.
-// ALLOCATE is true if the section should be allocated in memory.
-// This returns the new note section. It sets *TRAILING_PADDING to
-// the number of trailing zero bytes required.
-
-Output_section*
-Layout::create_note(const char* name, int note_type,
- const char* section_name, size_t descsz,
- bool allocate, size_t* trailing_padding)
-{
- // Authorities all agree that the values in a .note field should
- // be aligned on 4-byte boundaries for 32-bit binaries. However,
- // they differ on what the alignment is for 64-bit binaries.
- // The GABI says unambiguously they take 8-byte alignment:
- // http://sco.com/developers/gabi/latest/ch5.pheader.html#note_section
- // Other documentation says alignment should always be 4 bytes:
- // http://www.netbsd.org/docs/kernel/elf-notes.html#note-format
- // GNU ld and GNU readelf both support the latter (at least as of
- // version 2.16.91), and glibc always generates the latter for
- // .note.ABI-tag (as of version 1.6), so that's the one we go with
- // here.
-#ifdef GABI_FORMAT_FOR_DOTNOTE_SECTION // This is not defined by default.
- const int size = parameters->target().get_size();
-#else
- const int size = 32;
-#endif
- // The NT_GNU_PROPERTY_TYPE_0 note is aligned to the pointer size.
- const int addralign = ((note_type == elfcpp::NT_GNU_PROPERTY_TYPE_0
- ? parameters->target().get_size()
- : size) / 8);
-
- // The contents of the .note section.
- size_t namesz = strlen(name) + 1;
- size_t aligned_namesz = align_address(namesz, size / 8);
- size_t aligned_descsz = align_address(descsz, size / 8);
-
- size_t notehdrsz = 3 * (size / 8) + aligned_namesz;
-
- unsigned char* buffer = new unsigned char[notehdrsz];
- memset(buffer, 0, notehdrsz);
-
- bool is_big_endian = parameters->target().is_big_endian();
-
- if (size == 32)
- {
- if (!is_big_endian)
- {
- elfcpp::Swap<32, false>::writeval(buffer, namesz);
- elfcpp::Swap<32, false>::writeval(buffer + 4, descsz);
- elfcpp::Swap<32, false>::writeval(buffer + 8, note_type);
- }
- else
- {
- elfcpp::Swap<32, true>::writeval(buffer, namesz);
- elfcpp::Swap<32, true>::writeval(buffer + 4, descsz);
- elfcpp::Swap<32, true>::writeval(buffer + 8, note_type);
- }
- }
- else if (size == 64)
- {
- if (!is_big_endian)
- {
- elfcpp::Swap<64, false>::writeval(buffer, namesz);
- elfcpp::Swap<64, false>::writeval(buffer + 8, descsz);
- elfcpp::Swap<64, false>::writeval(buffer + 16, note_type);
- }
- else
- {
- elfcpp::Swap<64, true>::writeval(buffer, namesz);
- elfcpp::Swap<64, true>::writeval(buffer + 8, descsz);
- elfcpp::Swap<64, true>::writeval(buffer + 16, note_type);
- }
- }
- else
- gold_unreachable();
-
- memcpy(buffer + 3 * (size / 8), name, namesz);
-
- elfcpp::Elf_Xword flags = 0;
- Output_section_order order = ORDER_INVALID;
- if (allocate)
- {
- flags = elfcpp::SHF_ALLOC;
- order = (note_type == elfcpp::NT_GNU_PROPERTY_TYPE_0
- ? ORDER_PROPERTY_NOTE : ORDER_RO_NOTE);
- }
- Output_section* os = this->choose_output_section(NULL, section_name,
- elfcpp::SHT_NOTE,
- flags, false, order, false,
- false, true);
- if (os == NULL)
- return NULL;
-
- Output_section_data* posd = new Output_data_const_buffer(buffer, notehdrsz,
- addralign,
- "** note header");
- os->add_output_section_data(posd);
-
- *trailing_padding = aligned_descsz - descsz;
-
- return os;
-}
-
-// Create a .note.gnu.property section to record program properties
-// accumulated from the input files.
-
-void
-Layout::create_gnu_properties_note()
-{
- parameters->target().finalize_gnu_properties(this);
-
- if (this->gnu_properties_.empty())
- return;
-
- const unsigned int size = parameters->target().get_size();
- const bool is_big_endian = parameters->target().is_big_endian();
-
- // Compute the total size of the properties array.
- size_t descsz = 0;
- for (Gnu_properties::const_iterator prop = this->gnu_properties_.begin();
- prop != this->gnu_properties_.end();
- ++prop)
- {
- descsz = align_address(descsz + 8 + prop->second.pr_datasz, size / 8);
- }
-
- // Create the note section.
- size_t trailing_padding;
- Output_section* os = this->create_note("GNU", elfcpp::NT_GNU_PROPERTY_TYPE_0,
- ".note.gnu.property", descsz,
- true, &trailing_padding);
- if (os == NULL)
- return;
- gold_assert(trailing_padding == 0);
-
- // Allocate and fill the properties array.
- unsigned char* desc = new unsigned char[descsz];
- unsigned char* p = desc;
- for (Gnu_properties::const_iterator prop = this->gnu_properties_.begin();
- prop != this->gnu_properties_.end();
- ++prop)
- {
- size_t datasz = prop->second.pr_datasz;
- size_t aligned_datasz = align_address(prop->second.pr_datasz, size / 8);
- write_sized_value(prop->first, 4, p, is_big_endian);
- write_sized_value(datasz, 4, p + 4, is_big_endian);
- memcpy(p + 8, prop->second.pr_data, datasz);
- if (aligned_datasz > datasz)
- memset(p + 8 + datasz, 0, aligned_datasz - datasz);
- p += 8 + aligned_datasz;
- }
- Output_section_data* posd = new Output_data_const(desc, descsz, 4);
- os->add_output_section_data(posd);
-}
-
-// For an executable or shared library, create a note to record the
-// version of gold used to create the binary.
-
-void
-Layout::create_gold_note()
-{
- if (parameters->options().relocatable()
- || parameters->incremental_update())
- return;
-
- std::string desc = std::string("gold ") + gold::get_version_string();
-
- Output_section* os;
- Output_section_data* posd;
-
- if (!parameters->options().enable_linker_version())
- {
- size_t trailing_padding;
-
- os = this->create_note("GNU", elfcpp::NT_GNU_GOLD_VERSION,
- ".note.gnu.gold-version", desc.size(),
- false, &trailing_padding);
- if (os == NULL)
- return;
-
- posd = new Output_data_const(desc, 4);
- os->add_output_section_data(posd);
-
- if (trailing_padding > 0)
- {
- posd = new Output_data_zero_fill(trailing_padding, 0);
- os->add_output_section_data(posd);
- }
- }
- else
- {
- os = this->choose_output_section(NULL, ".comment",
- elfcpp::SHT_PROGBITS, 0,
- false, ORDER_INVALID,
- false, false, false);
- if (os == NULL)
- return;
-
- posd = new Output_data_const(desc, 1);
- os->add_output_section_data(posd);
- }
-}
-
-// Record whether the stack should be executable. This can be set
-// from the command line using the -z execstack or -z noexecstack
-// options. Otherwise, if any input file has a .note.GNU-stack
-// section with the SHF_EXECINSTR flag set, the stack should be
-// executable. Otherwise, if at least one input file a
-// .note.GNU-stack section, and some input file has no .note.GNU-stack
-// section, we use the target default for whether the stack should be
-// executable. If -z stack-size was used to set a p_memsz value for
-// PT_GNU_STACK, we generate the segment regardless. Otherwise, we
-// don't generate a stack note. When generating a object file, we
-// create a .note.GNU-stack section with the appropriate marking.
-// When generating an executable or shared library, we create a
-// PT_GNU_STACK segment.
-
-void
-Layout::create_stack_segment()
-{
- bool is_stack_executable;
- if (parameters->options().is_execstack_set())
- {
- is_stack_executable = parameters->options().is_stack_executable();
- if (!is_stack_executable
- && this->input_requires_executable_stack_
- && parameters->options().warn_execstack())
- gold_warning(_("one or more inputs require executable stack, "
- "but -z noexecstack was given"));
- }
- else if (!this->input_with_gnu_stack_note_
- && (!parameters->options().user_set_stack_size()
- || parameters->options().relocatable()))
- return;
- else
- {
- if (this->input_requires_executable_stack_)
- is_stack_executable = true;
- else if (this->input_without_gnu_stack_note_)
- is_stack_executable =
- parameters->target().is_default_stack_executable();
- else
- is_stack_executable = false;
- }
-
- if (parameters->options().relocatable())
- {
- const char* name = this->namepool_.add(".note.GNU-stack", false, NULL);
- elfcpp::Elf_Xword flags = 0;
- if (is_stack_executable)
- flags |= elfcpp::SHF_EXECINSTR;
- this->make_output_section(name, elfcpp::SHT_PROGBITS, flags,
- ORDER_INVALID, false);
- }
- else
- {
- if (this->script_options_->saw_phdrs_clause())
- return;
- int flags = elfcpp::PF_R | elfcpp::PF_W;
- if (is_stack_executable)
- flags |= elfcpp::PF_X;
- Output_segment* seg =
- this->make_output_segment(elfcpp::PT_GNU_STACK, flags);
- seg->set_size(parameters->options().stack_size());
- // BFD lets targets override this default alignment, but the only
- // targets that do so are ones that Gold does not support so far.
- seg->set_minimum_p_align(16);
- }
-}
-
-// If --build-id was used, set up the build ID note.
-
-void
-Layout::create_build_id()
-{
- if (!parameters->options().user_set_build_id())
- return;
-
- const char* style = parameters->options().build_id();
- if (strcmp(style, "none") == 0)
- return;
-
- // Set DESCSZ to the size of the note descriptor. When possible,
- // set DESC to the note descriptor contents.
- size_t descsz;
- std::string desc;
- if (strcmp(style, "md5") == 0)
- descsz = 128 / 8;
- else if ((strcmp(style, "sha1") == 0) || (strcmp(style, "tree") == 0))
- descsz = 160 / 8;
- else if (strcmp(style, "uuid") == 0)
- {
-#ifndef __MINGW32__
- const size_t uuidsz = 128 / 8;
-
- char buffer[uuidsz];
- memset(buffer, 0, uuidsz);
-
- int descriptor = open_descriptor(-1, "/dev/urandom", O_RDONLY);
- if (descriptor < 0)
- gold_error(_("--build-id=uuid failed: could not open /dev/urandom: %s"),
- strerror(errno));
- else
- {
- ssize_t got = ::read(descriptor, buffer, uuidsz);
- release_descriptor(descriptor, true);
- if (got < 0)
- gold_error(_("/dev/urandom: read failed: %s"), strerror(errno));
- else if (static_cast<size_t>(got) != uuidsz)
- gold_error(_("/dev/urandom: expected %zu bytes, got %zd bytes"),
- uuidsz, got);
- }
-
- desc.assign(buffer, uuidsz);
- descsz = uuidsz;
-#else // __MINGW32__
- UUID uuid;
- typedef RPC_STATUS (RPC_ENTRY *UuidCreateFn)(UUID *Uuid);
-
- HMODULE rpc_library = LoadLibrary("rpcrt4.dll");
- if (!rpc_library)
- gold_error(_("--build-id=uuid failed: could not load rpcrt4.dll"));
- else
- {
- UuidCreateFn uuid_create = reinterpret_cast<UuidCreateFn>(
- GetProcAddress(rpc_library, "UuidCreate"));
- if (!uuid_create)
- gold_error(_("--build-id=uuid failed: could not find UuidCreate"));
- else if (uuid_create(&uuid) != RPC_S_OK)
- gold_error(_("__build_id=uuid failed: call UuidCreate() failed"));
- FreeLibrary(rpc_library);
- }
- desc.assign(reinterpret_cast<const char *>(&uuid), sizeof(UUID));
- descsz = sizeof(UUID);
-#endif // __MINGW32__
- }
- else if (strncmp(style, "0x", 2) == 0)
- {
- hex_init();
- const char* p = style + 2;
- while (*p != '\0')
- {
- if (hex_p(p[0]) && hex_p(p[1]))
- {
- char c = (hex_value(p[0]) << 4) | hex_value(p[1]);
- desc += c;
- p += 2;
- }
- else if (*p == '-' || *p == ':')
- ++p;
- else
- gold_fatal(_("--build-id argument '%s' not a valid hex number"),
- style);
- }
- descsz = desc.size();
- }
- else
- gold_fatal(_("unrecognized --build-id argument '%s'"), style);
-
- // Create the note.
- size_t trailing_padding;
- Output_section* os = this->create_note("GNU", elfcpp::NT_GNU_BUILD_ID,
- ".note.gnu.build-id", descsz, true,
- &trailing_padding);
- if (os == NULL)
- return;
-
- if (!desc.empty())
- {
- // We know the value already, so we fill it in now.
- gold_assert(desc.size() == descsz);
-
- Output_section_data* posd = new Output_data_const(desc, 4);
- os->add_output_section_data(posd);
-
- if (trailing_padding != 0)
- {
- posd = new Output_data_zero_fill(trailing_padding, 0);
- os->add_output_section_data(posd);
- }
- }
- else
- {
- // We need to compute a checksum after we have completed the
- // link.
- gold_assert(trailing_padding == 0);
- this->build_id_note_ = new Output_data_zero_fill(descsz, 4);
- os->add_output_section_data(this->build_id_note_);
- }
-}
-
-// If --package-metadata was used, set up the package metadata note.
-// https://systemd.io/ELF_PACKAGE_METADATA/
-
-void
-Layout::create_package_metadata()
-{
- if (!parameters->options().user_set_package_metadata())
- return;
-
- const char* desc = parameters->options().package_metadata();
- if (strcmp(desc, "") == 0)
- return;
-
-#ifdef HAVE_JANSSON
- json_error_t json_error;
- json_t *json = json_loads(desc, 0, &json_error);
- if (json)
- json_decref(json);
- else
- {
- gold_fatal(_("error: --package-metadata=%s does not contain valid "
- "JSON: %s\n"),
- desc, json_error.text);
- }
-#endif
-
- // Create the note.
- size_t trailing_padding;
- // Ensure the trailing NULL byte is always included, as per specification.
- size_t descsz = strlen(desc) + 1;
- Output_section* os = this->create_note("FDO", elfcpp::FDO_PACKAGING_METADATA,
- ".note.package", descsz, true,
- &trailing_padding);
- if (os == NULL)
- return;
-
- Output_section_data* posd = new Output_data_const(desc, descsz, 4);
- os->add_output_section_data(posd);
-
- if (trailing_padding != 0)
- {
- posd = new Output_data_zero_fill(trailing_padding, 0);
- os->add_output_section_data(posd);
- }
-}
-
-// If we have both .stabXX and .stabXXstr sections, then the sh_link
-// field of the former should point to the latter. I'm not sure who
-// started this, but the GNU linker does it, and some tools depend
-// upon it.
-
-void
-Layout::link_stabs_sections()
-{
- if (!this->have_stabstr_section_)
- return;
-
- for (Section_list::iterator p = this->section_list_.begin();
- p != this->section_list_.end();
- ++p)
- {
- if ((*p)->type() != elfcpp::SHT_STRTAB)
- continue;
-
- const char* name = (*p)->name();
- if (strncmp(name, ".stab", 5) != 0)
- continue;
-
- size_t len = strlen(name);
- if (strcmp(name + len - 3, "str") != 0)
- continue;
-
- std::string stab_name(name, len - 3);
- Output_section* stab_sec;
- stab_sec = this->find_output_section(stab_name.c_str());
- if (stab_sec != NULL)
- stab_sec->set_link_section(*p);
- }
-}
-
-// Create .gnu_incremental_inputs and related sections needed
-// for the next run of incremental linking to check what has changed.
-
-void
-Layout::create_incremental_info_sections(Symbol_table* symtab)
-{
- Incremental_inputs* incr = this->incremental_inputs_;
-
- gold_assert(incr != NULL);
-
- // Create the .gnu_incremental_inputs, _symtab, and _relocs input sections.
- incr->create_data_sections(symtab);
-
- // Add the .gnu_incremental_inputs section.
- const char* incremental_inputs_name =
- this->namepool_.add(".gnu_incremental_inputs", false, NULL);
- Output_section* incremental_inputs_os =
- this->make_output_section(incremental_inputs_name,
- elfcpp::SHT_GNU_INCREMENTAL_INPUTS, 0,
- ORDER_INVALID, false);
- incremental_inputs_os->add_output_section_data(incr->inputs_section());
-
- // Add the .gnu_incremental_symtab section.
- const char* incremental_symtab_name =
- this->namepool_.add(".gnu_incremental_symtab", false, NULL);
- Output_section* incremental_symtab_os =
- this->make_output_section(incremental_symtab_name,
- elfcpp::SHT_GNU_INCREMENTAL_SYMTAB, 0,
- ORDER_INVALID, false);
- incremental_symtab_os->add_output_section_data(incr->symtab_section());
- incremental_symtab_os->set_entsize(4);
-
- // Add the .gnu_incremental_relocs section.
- const char* incremental_relocs_name =
- this->namepool_.add(".gnu_incremental_relocs", false, NULL);
- Output_section* incremental_relocs_os =
- this->make_output_section(incremental_relocs_name,
- elfcpp::SHT_GNU_INCREMENTAL_RELOCS, 0,
- ORDER_INVALID, false);
- incremental_relocs_os->add_output_section_data(incr->relocs_section());
- incremental_relocs_os->set_entsize(incr->relocs_entsize());
-
- // Add the .gnu_incremental_got_plt section.
- const char* incremental_got_plt_name =
- this->namepool_.add(".gnu_incremental_got_plt", false, NULL);
- Output_section* incremental_got_plt_os =
- this->make_output_section(incremental_got_plt_name,
- elfcpp::SHT_GNU_INCREMENTAL_GOT_PLT, 0,
- ORDER_INVALID, false);
- incremental_got_plt_os->add_output_section_data(incr->got_plt_section());
-
- // Add the .gnu_incremental_strtab section.
- const char* incremental_strtab_name =
- this->namepool_.add(".gnu_incremental_strtab", false, NULL);
- Output_section* incremental_strtab_os = this->make_output_section(incremental_strtab_name,
- elfcpp::SHT_STRTAB, 0,
- ORDER_INVALID, false);
- Output_data_strtab* strtab_data =
- new Output_data_strtab(incr->get_stringpool());
- incremental_strtab_os->add_output_section_data(strtab_data);
-
- incremental_inputs_os->set_after_input_sections();
- incremental_symtab_os->set_after_input_sections();
- incremental_relocs_os->set_after_input_sections();
- incremental_got_plt_os->set_after_input_sections();
-
- incremental_inputs_os->set_link_section(incremental_strtab_os);
- incremental_symtab_os->set_link_section(incremental_inputs_os);
- incremental_relocs_os->set_link_section(incremental_inputs_os);
- incremental_got_plt_os->set_link_section(incremental_inputs_os);
-}
-
-// Return whether SEG1 should be before SEG2 in the output file. This
-// is based entirely on the segment type and flags. When this is
-// called the segment addresses have normally not yet been set.
-
-bool
-Layout::segment_precedes(const Output_segment* seg1,
- const Output_segment* seg2)
-{
- // In order to produce a stable ordering if we're called with the same pointer
- // return false.
- if (seg1 == seg2)
- return false;
-
- elfcpp::Elf_Word type1 = seg1->type();
- elfcpp::Elf_Word type2 = seg2->type();
-
- // The single PT_PHDR segment is required to precede any loadable
- // segment. We simply make it always first.
- if (type1 == elfcpp::PT_PHDR)
- {
- gold_assert(type2 != elfcpp::PT_PHDR);
- return true;
- }
- if (type2 == elfcpp::PT_PHDR)
- return false;
-
- // The single PT_INTERP segment is required to precede any loadable
- // segment. We simply make it always second.
- if (type1 == elfcpp::PT_INTERP)
- {
- gold_assert(type2 != elfcpp::PT_INTERP);
- return true;
- }
- if (type2 == elfcpp::PT_INTERP)
- return false;
-
- // We then put PT_LOAD segments before any other segments.
- if (type1 == elfcpp::PT_LOAD && type2 != elfcpp::PT_LOAD)
- return true;
- if (type2 == elfcpp::PT_LOAD && type1 != elfcpp::PT_LOAD)
- return false;
-
- // We put the PT_TLS segment last except for the PT_GNU_RELRO
- // segment, because that is where the dynamic linker expects to find
- // it (this is just for efficiency; other positions would also work
- // correctly).
- if (type1 == elfcpp::PT_TLS
- && type2 != elfcpp::PT_TLS
- && type2 != elfcpp::PT_GNU_RELRO)
- return false;
- if (type2 == elfcpp::PT_TLS
- && type1 != elfcpp::PT_TLS
- && type1 != elfcpp::PT_GNU_RELRO)
- return true;
-
- // We put the PT_GNU_RELRO segment last, because that is where the
- // dynamic linker expects to find it (as with PT_TLS, this is just
- // for efficiency).
- if (type1 == elfcpp::PT_GNU_RELRO && type2 != elfcpp::PT_GNU_RELRO)
- return false;
- if (type2 == elfcpp::PT_GNU_RELRO && type1 != elfcpp::PT_GNU_RELRO)
- return true;
-
- const elfcpp::Elf_Word flags1 = seg1->flags();
- const elfcpp::Elf_Word flags2 = seg2->flags();
-
- // The order of non-PT_LOAD segments is unimportant. We simply sort
- // by the numeric segment type and flags values. There should not
- // be more than one segment with the same type and flags, except
- // when a linker script specifies such.
- if (type1 != elfcpp::PT_LOAD)
- {
- if (type1 != type2)
- return type1 < type2;
- uint64_t align1 = seg1->align();
- uint64_t align2 = seg2->align();
- // Place segments with larger alignments first.
- if (align1 != align2)
- return align1 > align2;
- gold_assert(flags1 != flags2
- || this->script_options_->saw_phdrs_clause());
- return flags1 < flags2;
- }
-
- // If the addresses are set already, sort by load address.
- if (seg1->are_addresses_set())
- {
- if (!seg2->are_addresses_set())
- return true;
-
- unsigned int section_count1 = seg1->output_section_count();
- unsigned int section_count2 = seg2->output_section_count();
- if (section_count1 == 0 && section_count2 > 0)
- return true;
- if (section_count1 > 0 && section_count2 == 0)
- return false;
-
- uint64_t paddr1 = (seg1->are_addresses_set()
- ? seg1->paddr()
- : seg1->first_section_load_address());
- uint64_t paddr2 = (seg2->are_addresses_set()
- ? seg2->paddr()
- : seg2->first_section_load_address());
-
- if (paddr1 != paddr2)
- return paddr1 < paddr2;
- }
- else if (seg2->are_addresses_set())
- return false;
-
- // A segment which holds large data comes after a segment which does
- // not hold large data.
- if (seg1->is_large_data_segment())
- {
- if (!seg2->is_large_data_segment())
- return false;
- }
- else if (seg2->is_large_data_segment())
- return true;
-
- // Otherwise, we sort PT_LOAD segments based on the flags. Readonly
- // segments come before writable segments. Then writable segments
- // with data come before writable segments without data. Then
- // executable segments come before non-executable segments. Then
- // the unlikely case of a non-readable segment comes before the
- // normal case of a readable segment. If there are multiple
- // segments with the same type and flags, we require that the
- // address be set, and we sort by virtual address and then physical
- // address.
- if ((flags1 & elfcpp::PF_W) != (flags2 & elfcpp::PF_W))
- return (flags1 & elfcpp::PF_W) == 0;
- if ((flags1 & elfcpp::PF_W) != 0
- && seg1->has_any_data_sections() != seg2->has_any_data_sections())
- return seg1->has_any_data_sections();
- if ((flags1 & elfcpp::PF_X) != (flags2 & elfcpp::PF_X))
- return (flags1 & elfcpp::PF_X) != 0;
- if ((flags1 & elfcpp::PF_R) != (flags2 & elfcpp::PF_R))
- return (flags1 & elfcpp::PF_R) == 0;
-
- // We shouldn't get here--we shouldn't create segments which we
- // can't distinguish. Unless of course we are using a weird linker
- // script or overlapping --section-start options. We could also get
- // here if plugins want unique segments for subsets of sections.
- gold_assert(this->script_options_->saw_phdrs_clause()
- || parameters->options().any_section_start()
- || this->is_unique_segment_for_sections_specified()
- || parameters->options().text_unlikely_segment());
- return false;
-}
-
-// Increase OFF so that it is congruent to ADDR modulo ABI_PAGESIZE.
-
-static off_t
-align_file_offset(off_t off, uint64_t addr, uint64_t abi_pagesize)
-{
- uint64_t unsigned_off = off;
- uint64_t aligned_off = ((unsigned_off & ~(abi_pagesize - 1))
- | (addr & (abi_pagesize - 1)));
- if (aligned_off < unsigned_off)
- aligned_off += abi_pagesize;
- return aligned_off;
-}
-
-// On targets where the text segment contains only executable code,
-// a non-executable segment is never the text segment.
-
-static inline bool
-is_text_segment(const Target* target, const Output_segment* seg)
-{
- elfcpp::Elf_Xword flags = seg->flags();
- if ((flags & elfcpp::PF_W) != 0)
- return false;
- if ((flags & elfcpp::PF_X) == 0)
- return !target->isolate_execinstr();
- return true;
-}
-
-// Set the file offsets of all the segments, and all the sections they
-// contain. They have all been created. LOAD_SEG must be laid out
-// first. Return the offset of the data to follow.
-
-off_t
-Layout::set_segment_offsets(const Target* target, Output_segment* load_seg,
- unsigned int* pshndx)
-{
- // Sort them into the final order. We use a stable sort so that we
- // don't randomize the order of indistinguishable segments created
- // by linker scripts.
- std::stable_sort(this->segment_list_.begin(), this->segment_list_.end(),
- Layout::Compare_segments(this));
-
- // Find the PT_LOAD segments, and set their addresses and offsets
- // and their section's addresses and offsets.
- uint64_t start_addr;
- if (parameters->options().user_set_Ttext())
- start_addr = parameters->options().Ttext();
- else if (parameters->options().output_is_position_independent())
- start_addr = 0;
- else
- start_addr = target->default_text_segment_address();
-
- uint64_t addr = start_addr;
- off_t off = 0;
-
- // If LOAD_SEG is NULL, then the file header and segment headers
- // will not be loadable. But they still need to be at offset 0 in
- // the file. Set their offsets now.
- if (load_seg == NULL)
- {
- for (Data_list::iterator p = this->special_output_list_.begin();
- p != this->special_output_list_.end();
- ++p)
- {
- off = align_address(off, (*p)->addralign());
- (*p)->set_address_and_file_offset(0, off);
- off += (*p)->data_size();
- }
- }
-
- unsigned int increase_relro = this->increase_relro_;
- if (this->script_options_->saw_sections_clause())
- increase_relro = 0;
-
- const bool check_sections = parameters->options().check_sections();
- Output_segment* last_load_segment = NULL;
-
- unsigned int shndx_begin = *pshndx;
- unsigned int shndx_load_seg = *pshndx;
-
- for (Segment_list::iterator p = this->segment_list_.begin();
- p != this->segment_list_.end();
- ++p)
- {
- if ((*p)->type() == elfcpp::PT_LOAD)
- {
- if (target->isolate_execinstr())
- {
- // When we hit the segment that should contain the
- // file headers, reset the file offset so we place
- // it and subsequent segments appropriately.
- // We'll fix up the preceding segments below.
- if (load_seg == *p)
- {
- if (off == 0)
- load_seg = NULL;
- else
- {
- off = 0;
- shndx_load_seg = *pshndx;
- }
- }
- }
- else
- {
- // Verify that the file headers fall into the first segment.
- if (load_seg != NULL && load_seg != *p)
- gold_unreachable();
- load_seg = NULL;
- }
-
- bool are_addresses_set = (*p)->are_addresses_set();
- if (are_addresses_set)
- {
- // When it comes to setting file offsets, we care about
- // the physical address.
- addr = (*p)->paddr();
- }
- else if (parameters->options().user_set_Ttext()
- && (parameters->options().omagic()
- || is_text_segment(target, *p)))
- {
- are_addresses_set = true;
- }
- else if (parameters->options().user_set_Trodata_segment()
- && ((*p)->flags() & (elfcpp::PF_W | elfcpp::PF_X)) == 0)
- {
- addr = parameters->options().Trodata_segment();
- are_addresses_set = true;
- }
- else if (parameters->options().user_set_Tdata()
- && ((*p)->flags() & elfcpp::PF_W) != 0
- && (!parameters->options().user_set_Tbss()
- || (*p)->has_any_data_sections()))
- {
- addr = parameters->options().Tdata();
- are_addresses_set = true;
- }
- else if (parameters->options().user_set_Tbss()
- && ((*p)->flags() & elfcpp::PF_W) != 0
- && !(*p)->has_any_data_sections())
- {
- addr = parameters->options().Tbss();
- are_addresses_set = true;
- }
-
- uint64_t orig_addr = addr;
- uint64_t orig_off = off;
-
- uint64_t aligned_addr = 0;
- uint64_t abi_pagesize = target->abi_pagesize();
- uint64_t common_pagesize = target->common_pagesize();
-
- if (!parameters->options().nmagic()
- && !parameters->options().omagic())
- (*p)->set_minimum_p_align(abi_pagesize);
-
- if (!are_addresses_set)
- {
- // Skip the address forward one page, maintaining the same
- // position within the page. This lets us store both segments
- // overlapping on a single page in the file, but the loader will
- // put them on different pages in memory. We will revisit this
- // decision once we know the size of the segment.
-
- uint64_t max_align = (*p)->maximum_alignment();
- if (max_align > abi_pagesize)
- addr = align_address(addr, max_align);
- aligned_addr = addr;
-
- if (load_seg == *p)
- {
- // This is the segment that will contain the file
- // headers, so its offset will have to be exactly zero.
- gold_assert(orig_off == 0);
-
- // If the target wants a fixed minimum distance from the
- // text segment to the read-only segment, move up now.
- uint64_t min_addr =
- start_addr + (parameters->options().user_set_rosegment_gap()
- ? parameters->options().rosegment_gap()
- : target->rosegment_gap());
- if (addr < min_addr)
- addr = min_addr;
-
- // But this is not the first segment! To make its
- // address congruent with its offset, that address better
- // be aligned to the ABI-mandated page size.
- addr = align_address(addr, abi_pagesize);
- aligned_addr = addr;
- }
- else
- {
- if ((addr & (abi_pagesize - 1)) != 0)
- addr = addr + abi_pagesize;
-
- off = orig_off + ((addr - orig_addr) & (abi_pagesize - 1));
- }
- }
-
- if (!parameters->options().nmagic()
- && !parameters->options().omagic())
- {
- // Here we are also taking care of the case when
- // the maximum segment alignment is larger than the page size.
- off = align_file_offset(off, addr,
- std::max(abi_pagesize,
- (*p)->maximum_alignment()));
- }
- else
- {
- // This is -N or -n with a section script which prevents
- // us from using a load segment. We need to ensure that
- // the file offset is aligned to the alignment of the
- // segment. This is because the linker script
- // implicitly assumed a zero offset. If we don't align
- // here, then the alignment of the sections in the
- // linker script may not match the alignment of the
- // sections in the set_section_addresses call below,
- // causing an error about dot moving backward.
- off = align_address(off, (*p)->maximum_alignment());
- }
-
- unsigned int shndx_hold = *pshndx;
- bool has_relro = false;
- uint64_t new_addr = (*p)->set_section_addresses(target, this,
- false, addr,
- &increase_relro,
- &has_relro,
- &off, pshndx);
-
- // Now that we know the size of this segment, we may be able
- // to save a page in memory, at the cost of wasting some
- // file space, by instead aligning to the start of a new
- // page. Here we use the real machine page size rather than
- // the ABI mandated page size. If the segment has been
- // aligned so that the relro data ends at a page boundary,
- // we do not try to realign it.
-
- if (!are_addresses_set
- && !has_relro
- && aligned_addr != addr
- && !parameters->incremental())
- {
- uint64_t first_off = (common_pagesize
- - (aligned_addr
- & (common_pagesize - 1)));
- uint64_t last_off = new_addr & (common_pagesize - 1);
- if (first_off > 0
- && last_off > 0
- && ((aligned_addr & ~ (common_pagesize - 1))
- != (new_addr & ~ (common_pagesize - 1)))
- && first_off + last_off <= common_pagesize)
- {
- *pshndx = shndx_hold;
- addr = align_address(aligned_addr, common_pagesize);
- addr = align_address(addr, (*p)->maximum_alignment());
- if ((addr & (abi_pagesize - 1)) != 0)
- addr = addr + abi_pagesize;
- off = orig_off + ((addr - orig_addr) & (abi_pagesize - 1));
- off = align_file_offset(off, addr, abi_pagesize);
-
- increase_relro = this->increase_relro_;
- if (this->script_options_->saw_sections_clause())
- increase_relro = 0;
- has_relro = false;
-
- new_addr = (*p)->set_section_addresses(target, this,
- true, addr,
- &increase_relro,
- &has_relro,
- &off, pshndx);
- }
- }
-
- addr = new_addr;
-
- // Implement --check-sections. We know that the segments
- // are sorted by LMA.
- if (check_sections && last_load_segment != NULL)
- {
- gold_assert(last_load_segment->paddr() <= (*p)->paddr());
- if (last_load_segment->paddr() + last_load_segment->memsz()
- > (*p)->paddr())
- {
- unsigned long long lb1 = last_load_segment->paddr();
- unsigned long long le1 = lb1 + last_load_segment->memsz();
- unsigned long long lb2 = (*p)->paddr();
- unsigned long long le2 = lb2 + (*p)->memsz();
- gold_error(_("load segment overlap [0x%llx -> 0x%llx] and "
- "[0x%llx -> 0x%llx]"),
- lb1, le1, lb2, le2);
- }
- }
- last_load_segment = *p;
- }
- }
-
- if (load_seg != NULL && target->isolate_execinstr())
- {
- // Process the early segments again, setting their file offsets
- // so they land after the segments starting at LOAD_SEG.
- off = align_file_offset(off, 0, target->abi_pagesize());
-
- this->reset_relax_output();
-
- for (Segment_list::iterator p = this->segment_list_.begin();
- *p != load_seg;
- ++p)
- {
- if ((*p)->type() == elfcpp::PT_LOAD)
- {
- // We repeat the whole job of assigning addresses and
- // offsets, but we really only want to change the offsets and
- // must ensure that the addresses all come out the same as
- // they did the first time through.
- bool has_relro = false;
- const uint64_t old_addr = (*p)->vaddr();
- const uint64_t old_end = old_addr + (*p)->memsz();
- uint64_t new_addr = (*p)->set_section_addresses(target, this,
- true, old_addr,
- &increase_relro,
- &has_relro,
- &off,
- &shndx_begin);
- gold_assert(new_addr == old_end);
- }
- }
-
- gold_assert(shndx_begin == shndx_load_seg);
- }
-
- // Handle the non-PT_LOAD segments, setting their offsets from their
- // section's offsets.
- for (Segment_list::iterator p = this->segment_list_.begin();
- p != this->segment_list_.end();
- ++p)
- {
- // PT_GNU_STACK was set up correctly when it was created.
- if ((*p)->type() != elfcpp::PT_LOAD
- && (*p)->type() != elfcpp::PT_GNU_STACK)
- (*p)->set_offset((*p)->type() == elfcpp::PT_GNU_RELRO
- ? increase_relro
- : 0);
- }
-
- // Set the TLS offsets for each section in the PT_TLS segment.
- if (this->tls_segment_ != NULL)
- this->tls_segment_->set_tls_offsets();
-
- return off;
-}
-
-// Set the offsets of all the allocated sections when doing a
-// relocatable link. This does the same jobs as set_segment_offsets,
-// only for a relocatable link.
-
-off_t
-Layout::set_relocatable_section_offsets(Output_data* file_header,
- unsigned int* pshndx)
-{
- off_t off = 0;
-
- file_header->set_address_and_file_offset(0, 0);
- off += file_header->data_size();
-
- for (Section_list::iterator p = this->section_list_.begin();
- p != this->section_list_.end();
- ++p)
- {
- // We skip unallocated sections here, except that group sections
- // have to come first.
- if (((*p)->flags() & elfcpp::SHF_ALLOC) == 0
- && (*p)->type() != elfcpp::SHT_GROUP)
- continue;
-
- off = align_address(off, (*p)->addralign());
-
- // The linker script might have set the address.
- if (!(*p)->is_address_valid())
- (*p)->set_address(0);
- (*p)->set_file_offset(off);
- (*p)->finalize_data_size();
- if ((*p)->type() != elfcpp::SHT_NOBITS)
- off += (*p)->data_size();
-
- (*p)->set_out_shndx(*pshndx);
- ++*pshndx;
- }
-
- return off;
-}
-
-// Set the file offset of all the sections not associated with a
-// segment.
-
-off_t
-Layout::set_section_offsets(off_t off, Layout::Section_offset_pass pass)
-{
- off_t startoff = off;
- off_t maxoff = off;
-
- for (Section_list::iterator p = this->unattached_section_list_.begin();
- p != this->unattached_section_list_.end();
- ++p)
- {
- // The symtab section is handled in create_symtab_sections.
- if (*p == this->symtab_section_)
- continue;
-
- // If we've already set the data size, don't set it again.
- if ((*p)->is_offset_valid() && (*p)->is_data_size_valid())
- continue;
-
- if (pass == BEFORE_INPUT_SECTIONS_PASS
- && (*p)->requires_postprocessing())
- {
- (*p)->create_postprocessing_buffer();
- this->any_postprocessing_sections_ = true;
- }
-
- if (pass == BEFORE_INPUT_SECTIONS_PASS
- && (*p)->after_input_sections())
- continue;
- else if (pass == POSTPROCESSING_SECTIONS_PASS
- && (!(*p)->after_input_sections()
- || (*p)->type() == elfcpp::SHT_STRTAB))
- continue;
- else if (pass == STRTAB_AFTER_POSTPROCESSING_SECTIONS_PASS
- && (!(*p)->after_input_sections()
- || (*p)->type() != elfcpp::SHT_STRTAB))
- continue;
-
- if (!parameters->incremental_update())
- {
- off = align_address(off, (*p)->addralign());
- (*p)->set_file_offset(off);
- (*p)->finalize_data_size();
- }
- else
- {
- // Incremental update: allocate file space from free list.
- (*p)->pre_finalize_data_size();
- off_t current_size = (*p)->current_data_size();
- off = this->allocate(current_size, (*p)->addralign(), startoff);
- if (off == -1)
- {
- if (is_debugging_enabled(DEBUG_INCREMENTAL))
- this->free_list_.dump();
- gold_assert((*p)->output_section() != NULL);
- gold_fallback(_("out of patch space for section %s; "
- "relink with --incremental-full"),
- (*p)->output_section()->name());
- }
- (*p)->set_file_offset(off);
- (*p)->finalize_data_size();
- if ((*p)->data_size() > current_size)
- {
- gold_assert((*p)->output_section() != NULL);
- gold_fallback(_("%s: section changed size; "
- "relink with --incremental-full"),
- (*p)->output_section()->name());
- }
- gold_debug(DEBUG_INCREMENTAL,
- "set_section_offsets: %08lx %08lx %s",
- static_cast<long>(off),
- static_cast<long>((*p)->data_size()),
- ((*p)->output_section() != NULL
- ? (*p)->output_section()->name() : "(special)"));
- }
-
- off += (*p)->data_size();
- if (off > maxoff)
- maxoff = off;
-
- // At this point the name must be set.
- if (pass != STRTAB_AFTER_POSTPROCESSING_SECTIONS_PASS)
- this->namepool_.add((*p)->name(), false, NULL);
- }
- return maxoff;
-}
-
-// Set the section indexes of all the sections not associated with a
-// segment.
-
-unsigned int
-Layout::set_section_indexes(unsigned int shndx)
-{
- for (Section_list::iterator p = this->unattached_section_list_.begin();
- p != this->unattached_section_list_.end();
- ++p)
- {
- if (!(*p)->has_out_shndx())
- {
- (*p)->set_out_shndx(shndx);
- ++shndx;
- }
- }
- return shndx;
-}
-
-// Set the section addresses according to the linker script. This is
-// only called when we see a SECTIONS clause. This returns the
-// program segment which should hold the file header and segment
-// headers, if any. It will return NULL if they should not be in a
-// segment.
-
-Output_segment*
-Layout::set_section_addresses_from_script(Symbol_table* symtab)
-{
- Script_sections* ss = this->script_options_->script_sections();
- gold_assert(ss->saw_sections_clause());
- return this->script_options_->set_section_addresses(symtab, this);
-}
-
-// Place the orphan sections in the linker script.
-
-void
-Layout::place_orphan_sections_in_script()
-{
- Script_sections* ss = this->script_options_->script_sections();
- gold_assert(ss->saw_sections_clause());
-
- // Place each orphaned output section in the script.
- for (Section_list::iterator p = this->section_list_.begin();
- p != this->section_list_.end();
- ++p)
- {
- if (!(*p)->found_in_sections_clause())
- ss->place_orphan(*p);
- }
-}
-
-// Count the local symbols in the regular symbol table and the dynamic
-// symbol table, and build the respective string pools.
-
-void
-Layout::count_local_symbols(const Task* task,
- const Input_objects* input_objects)
-{
- // First, figure out an upper bound on the number of symbols we'll
- // be inserting into each pool. This helps us create the pools with
- // the right size, to avoid unnecessary hashtable resizing.
- unsigned int symbol_count = 0;
- for (Input_objects::Relobj_iterator p = input_objects->relobj_begin();
- p != input_objects->relobj_end();
- ++p)
- symbol_count += (*p)->local_symbol_count();
-
- // Go from "upper bound" to "estimate." We overcount for two
- // reasons: we double-count symbols that occur in more than one
- // object file, and we count symbols that are dropped from the
- // output. Add it all together and assume we overcount by 100%.
- symbol_count /= 2;
-
- // We assume all symbols will go into both the sympool and dynpool.
- this->sympool_.reserve(symbol_count);
- this->dynpool_.reserve(symbol_count);
-
- for (Input_objects::Relobj_iterator p = input_objects->relobj_begin();
- p != input_objects->relobj_end();
- ++p)
- {
- Task_lock_obj<Object> tlo(task, *p);
- (*p)->count_local_symbols(&this->sympool_, &this->dynpool_);
- }
-}
-
-// Create the symbol table sections. Here we also set the final
-// values of the symbols. At this point all the loadable sections are
-// fully laid out. SHNUM is the number of sections so far.
-
-void
-Layout::create_symtab_sections(const Input_objects* input_objects,
- Symbol_table* symtab,
- unsigned int shnum,
- off_t* poff,
- unsigned int local_dynamic_count)
-{
- int symsize;
- unsigned int align;
- if (parameters->target().get_size() == 32)
- {
- symsize = elfcpp::Elf_sizes<32>::sym_size;
- align = 4;
- }
- else if (parameters->target().get_size() == 64)
- {
- symsize = elfcpp::Elf_sizes<64>::sym_size;
- align = 8;
- }
- else
- gold_unreachable();
-
- // Compute file offsets relative to the start of the symtab section.
- off_t off = 0;
-
- // Save space for the dummy symbol at the start of the section. We
- // never bother to write this out--it will just be left as zero.
- off += symsize;
- unsigned int local_symbol_index = 1;
-
- // Add STT_SECTION symbols for each Output section which needs one.
- for (Section_list::iterator p = this->section_list_.begin();
- p != this->section_list_.end();
- ++p)
- {
- if (!(*p)->needs_symtab_index())
- (*p)->set_symtab_index(-1U);
- else
- {
- (*p)->set_symtab_index(local_symbol_index);
- ++local_symbol_index;
- off += symsize;
- }
- }
-
- for (Input_objects::Relobj_iterator p = input_objects->relobj_begin();
- p != input_objects->relobj_end();
- ++p)
- {
- unsigned int index = (*p)->finalize_local_symbols(local_symbol_index,
- off, symtab);
- off += (index - local_symbol_index) * symsize;
- local_symbol_index = index;
- }
-
- unsigned int local_symcount = local_symbol_index;
- gold_assert(static_cast<off_t>(local_symcount * symsize) == off);
-
- off_t dynoff;
- size_t dyncount;
- if (this->dynsym_section_ == NULL)
- {
- dynoff = 0;
- dyncount = 0;
- }
- else
- {
- off_t locsize = local_dynamic_count * this->dynsym_section_->entsize();
- dynoff = this->dynsym_section_->offset() + locsize;
- dyncount = (this->dynsym_section_->data_size() - locsize) / symsize;
- gold_assert(static_cast<off_t>(dyncount * symsize)
- == this->dynsym_section_->data_size() - locsize);
- }
-
- off_t global_off = off;
- off = symtab->finalize(off, dynoff, local_dynamic_count, dyncount,
- &this->sympool_, &local_symcount);
-
- if (!parameters->options().strip_all())
- {
- this->sympool_.set_string_offsets();
-
- const char* symtab_name = this->namepool_.add(".symtab", false, NULL);
- Output_section* osymtab = this->make_output_section(symtab_name,
- elfcpp::SHT_SYMTAB,
- 0, ORDER_INVALID,
- false);
- this->symtab_section_ = osymtab;
-
- Output_section_data* pos = new Output_data_fixed_space(off, align,
- "** symtab");
- osymtab->add_output_section_data(pos);
-
- // We generate a .symtab_shndx section if we have more than
- // SHN_LORESERVE sections. Technically it is possible that we
- // don't need one, because it is possible that there are no
- // symbols in any of sections with indexes larger than
- // SHN_LORESERVE. That is probably unusual, though, and it is
- // easier to always create one than to compute section indexes
- // twice (once here, once when writing out the symbols).
- if (shnum >= elfcpp::SHN_LORESERVE)
- {
- const char* symtab_xindex_name = this->namepool_.add(".symtab_shndx",
- false, NULL);
- Output_section* osymtab_xindex =
- this->make_output_section(symtab_xindex_name,
- elfcpp::SHT_SYMTAB_SHNDX, 0,
- ORDER_INVALID, false);
-
- size_t symcount = off / symsize;
- this->symtab_xindex_ = new Output_symtab_xindex(symcount);
-
- osymtab_xindex->add_output_section_data(this->symtab_xindex_);
-
- osymtab_xindex->set_link_section(osymtab);
- osymtab_xindex->set_addralign(4);
- osymtab_xindex->set_entsize(4);
-
- osymtab_xindex->set_after_input_sections();
-
- // This tells the driver code to wait until the symbol table
- // has written out before writing out the postprocessing
- // sections, including the .symtab_shndx section.
- this->any_postprocessing_sections_ = true;
- }
-
- const char* strtab_name = this->namepool_.add(".strtab", false, NULL);
- Output_section* ostrtab = this->make_output_section(strtab_name,
- elfcpp::SHT_STRTAB,
- 0, ORDER_INVALID,
- false);
-
- Output_section_data* pstr = new Output_data_strtab(&this->sympool_);
- ostrtab->add_output_section_data(pstr);
-
- off_t symtab_off;
- if (!parameters->incremental_update())
- symtab_off = align_address(*poff, align);
- else
- {
- symtab_off = this->allocate(off, align, *poff);
- if (off == -1)
- gold_fallback(_("out of patch space for symbol table; "
- "relink with --incremental-full"));
- gold_debug(DEBUG_INCREMENTAL,
- "create_symtab_sections: %08lx %08lx .symtab",
- static_cast<long>(symtab_off),
- static_cast<long>(off));
- }
-
- symtab->set_file_offset(symtab_off + global_off);
- osymtab->set_file_offset(symtab_off);
- osymtab->finalize_data_size();
- osymtab->set_link_section(ostrtab);
- osymtab->set_info(local_symcount);
- osymtab->set_entsize(symsize);
-
- if (symtab_off + off > *poff)
- *poff = symtab_off + off;
- }
-}
-
-// Create the .shstrtab section, which holds the names of the
-// sections. At the time this is called, we have created all the
-// output sections except .shstrtab itself.
-
-Output_section*
-Layout::create_shstrtab()
-{
- // FIXME: We don't need to create a .shstrtab section if we are
- // stripping everything.
-
- const char* name = this->namepool_.add(".shstrtab", false, NULL);
-
- Output_section* os = this->make_output_section(name, elfcpp::SHT_STRTAB, 0,
- ORDER_INVALID, false);
-
- if (strcmp(parameters->options().compress_debug_sections(), "none") != 0)
- {
- // We can't write out this section until we've set all the
- // section names, and we don't set the names of compressed
- // output sections until relocations are complete. FIXME: With
- // the current names we use, this is unnecessary.
- os->set_after_input_sections();
- }
-
- Output_section_data* posd = new Output_data_strtab(&this->namepool_);
- os->add_output_section_data(posd);
-
- return os;
-}
-
-// Create the section headers. SIZE is 32 or 64. OFF is the file
-// offset.
-
-void
-Layout::create_shdrs(const Output_section* shstrtab_section, off_t* poff)
-{
- Output_section_headers* oshdrs;
- oshdrs = new Output_section_headers(this,
- &this->segment_list_,
- &this->section_list_,
- &this->unattached_section_list_,
- &this->namepool_,
- shstrtab_section);
- off_t off;
- if (!parameters->incremental_update())
- off = align_address(*poff, oshdrs->addralign());
- else
- {
- oshdrs->pre_finalize_data_size();
- off = this->allocate(oshdrs->data_size(), oshdrs->addralign(), *poff);
- if (off == -1)
- gold_fallback(_("out of patch space for section header table; "
- "relink with --incremental-full"));
- gold_debug(DEBUG_INCREMENTAL,
- "create_shdrs: %08lx %08lx (section header table)",
- static_cast<long>(off),
- static_cast<long>(off + oshdrs->data_size()));
- }
- oshdrs->set_address_and_file_offset(0, off);
- off += oshdrs->data_size();
- if (off > *poff)
- *poff = off;
- this->section_headers_ = oshdrs;
-}
-
-// Count the allocated sections.
-
-size_t
-Layout::allocated_output_section_count() const
-{
- size_t section_count = 0;
- for (Segment_list::const_iterator p = this->segment_list_.begin();
- p != this->segment_list_.end();
- ++p)
- section_count += (*p)->output_section_count();
- return section_count;
-}
-
-// Create the dynamic symbol table.
-// *PLOCAL_DYNAMIC_COUNT will be set to the number of local symbols
-// from input objects, and *PFORCED_LOCAL_DYNAMIC_COUNT will be set
-// to the number of global symbols that have been forced local.
-// We need to remember the former because the forced-local symbols are
-// written along with the global symbols in Symtab::write_globals().
-
-void
-Layout::create_dynamic_symtab(const Input_objects* input_objects,
- Symbol_table* symtab,
- Output_section** pdynstr,
- unsigned int* plocal_dynamic_count,
- unsigned int* pforced_local_dynamic_count,
- std::vector<Symbol*>* pdynamic_symbols,
- Versions* pversions)
-{
- // Count all the symbols in the dynamic symbol table, and set the
- // dynamic symbol indexes.
-
- // Skip symbol 0, which is always all zeroes.
- unsigned int index = 1;
-
- // Add STT_SECTION symbols for each Output section which needs one.
- for (Section_list::iterator p = this->section_list_.begin();
- p != this->section_list_.end();
- ++p)
- {
- if (!(*p)->needs_dynsym_index())
- (*p)->set_dynsym_index(-1U);
- else
- {
- (*p)->set_dynsym_index(index);
- ++index;
- }
- }
-
- // Count the local symbols that need to go in the dynamic symbol table,
- // and set the dynamic symbol indexes.
- for (Input_objects::Relobj_iterator p = input_objects->relobj_begin();
- p != input_objects->relobj_end();
- ++p)
- {
- unsigned int new_index = (*p)->set_local_dynsym_indexes(index);
- index = new_index;
- }
-
- unsigned int local_symcount = index;
- unsigned int forced_local_count = 0;
-
- index = symtab->set_dynsym_indexes(index, &forced_local_count,
- pdynamic_symbols, &this->dynpool_,
- pversions);
-
- *plocal_dynamic_count = local_symcount;
- *pforced_local_dynamic_count = forced_local_count;
-
- int symsize;
- unsigned int align;
- const int size = parameters->target().get_size();
- if (size == 32)
- {
- symsize = elfcpp::Elf_sizes<32>::sym_size;
- align = 4;
- }
- else if (size == 64)
- {
- symsize = elfcpp::Elf_sizes<64>::sym_size;
- align = 8;
- }
- else
- gold_unreachable();
-
- // Create the dynamic symbol table section.
-
- Output_section* dynsym = this->choose_output_section(NULL, ".dynsym",
- elfcpp::SHT_DYNSYM,
- elfcpp::SHF_ALLOC,
- false,
- ORDER_DYNAMIC_LINKER,
- false, false, false);
-
- // Check for NULL as a linker script may discard .dynsym.
- if (dynsym != NULL)
- {
- Output_section_data* odata = new Output_data_fixed_space(index * symsize,
- align,
- "** dynsym");
- dynsym->add_output_section_data(odata);
-
- dynsym->set_info(local_symcount + forced_local_count);
- dynsym->set_entsize(symsize);
- dynsym->set_addralign(align);
-
- this->dynsym_section_ = dynsym;
- }
-
- Output_data_dynamic* const odyn = this->dynamic_data_;
- if (odyn != NULL)
- {
- odyn->add_section_address(elfcpp::DT_SYMTAB, dynsym);
- odyn->add_constant(elfcpp::DT_SYMENT, symsize);
- }
-
- // If there are more than SHN_LORESERVE allocated sections, we
- // create a .dynsym_shndx section. It is possible that we don't
- // need one, because it is possible that there are no dynamic
- // symbols in any of the sections with indexes larger than
- // SHN_LORESERVE. This is probably unusual, though, and at this
- // time we don't know the actual section indexes so it is
- // inconvenient to check.
- if (this->allocated_output_section_count() >= elfcpp::SHN_LORESERVE)
- {
- Output_section* dynsym_xindex =
- this->choose_output_section(NULL, ".dynsym_shndx",
- elfcpp::SHT_SYMTAB_SHNDX,
- elfcpp::SHF_ALLOC,
- false, ORDER_DYNAMIC_LINKER, false, false,
- false);
-
- if (dynsym_xindex != NULL)
- {
- this->dynsym_xindex_ = new Output_symtab_xindex(index);
-
- dynsym_xindex->add_output_section_data(this->dynsym_xindex_);
-
- dynsym_xindex->set_link_section(dynsym);
- dynsym_xindex->set_addralign(4);
- dynsym_xindex->set_entsize(4);
-
- dynsym_xindex->set_after_input_sections();
-
- // This tells the driver code to wait until the symbol table
- // has written out before writing out the postprocessing
- // sections, including the .dynsym_shndx section.
- this->any_postprocessing_sections_ = true;
- }
- }
-
- // Create the dynamic string table section.
-
- Output_section* dynstr = this->choose_output_section(NULL, ".dynstr",
- elfcpp::SHT_STRTAB,
- elfcpp::SHF_ALLOC,
- false,
- ORDER_DYNAMIC_LINKER,
- false, false, false);
- *pdynstr = dynstr;
- if (dynstr != NULL)
- {
- Output_section_data* strdata = new Output_data_strtab(&this->dynpool_);
- dynstr->add_output_section_data(strdata);
-
- if (dynsym != NULL)
- dynsym->set_link_section(dynstr);
- if (this->dynamic_section_ != NULL)
- this->dynamic_section_->set_link_section(dynstr);
-
- if (odyn != NULL)
- {
- odyn->add_section_address(elfcpp::DT_STRTAB, dynstr);
- odyn->add_section_size(elfcpp::DT_STRSZ, dynstr);
- }
- }
-
- // Create the hash tables. The Gnu-style hash table must be
- // built first, because it changes the order of the symbols
- // in the dynamic symbol table.
-
- if (strcmp(parameters->options().hash_style(), "gnu") == 0
- || strcmp(parameters->options().hash_style(), "both") == 0)
- {
- unsigned char* phash;
- unsigned int hashlen;
- Dynobj::create_gnu_hash_table(*pdynamic_symbols,
- local_symcount + forced_local_count,
- &phash, &hashlen);
-
- Output_section* hashsec =
- this->choose_output_section(NULL, ".gnu.hash", elfcpp::SHT_GNU_HASH,
- elfcpp::SHF_ALLOC, false,
- ORDER_DYNAMIC_LINKER, false, false,
- false);
-
- Output_section_data* hashdata = new Output_data_const_buffer(phash,
- hashlen,
- align,
- "** hash");
- if (hashsec != NULL && hashdata != NULL)
- hashsec->add_output_section_data(hashdata);
-
- if (hashsec != NULL)
- {
- if (dynsym != NULL)
- hashsec->set_link_section(dynsym);
-
- // For a 64-bit target, the entries in .gnu.hash do not have
- // a uniform size, so we only set the entry size for a
- // 32-bit target.
- if (parameters->target().get_size() == 32)
- hashsec->set_entsize(4);
-
- if (odyn != NULL)
- odyn->add_section_address(elfcpp::DT_GNU_HASH, hashsec);
- }
- }
-
- if (strcmp(parameters->options().hash_style(), "sysv") == 0
- || strcmp(parameters->options().hash_style(), "both") == 0)
- {
- unsigned char* phash;
- unsigned int hashlen;
- Dynobj::create_elf_hash_table(*pdynamic_symbols,
- local_symcount + forced_local_count,
- &phash, &hashlen);
-
- Output_section* hashsec =
- this->choose_output_section(NULL, ".hash", elfcpp::SHT_HASH,
- elfcpp::SHF_ALLOC, false,
- ORDER_DYNAMIC_LINKER, false, false,
- false);
-
- Output_section_data* hashdata = new Output_data_const_buffer(phash,
- hashlen,
- align,
- "** hash");
- if (hashsec != NULL && hashdata != NULL)
- hashsec->add_output_section_data(hashdata);
-
- if (hashsec != NULL)
- {
- if (dynsym != NULL)
- hashsec->set_link_section(dynsym);
- hashsec->set_entsize(parameters->target().hash_entry_size() / 8);
- }
-
- if (odyn != NULL)
- odyn->add_section_address(elfcpp::DT_HASH, hashsec);
- }
-}
-
-// Assign offsets to each local portion of the dynamic symbol table.
-
-void
-Layout::assign_local_dynsym_offsets(const Input_objects* input_objects)
-{
- Output_section* dynsym = this->dynsym_section_;
- if (dynsym == NULL)
- return;
-
- off_t off = dynsym->offset();
-
- // Skip the dummy symbol at the start of the section.
- off += dynsym->entsize();
-
- for (Input_objects::Relobj_iterator p = input_objects->relobj_begin();
- p != input_objects->relobj_end();
- ++p)
- {
- unsigned int count = (*p)->set_local_dynsym_offset(off);
- off += count * dynsym->entsize();
- }
-}
-
-// Create the version sections.
-
-void
-Layout::create_version_sections(const Versions* versions,
- const Symbol_table* symtab,
- unsigned int local_symcount,
- const std::vector<Symbol*>& dynamic_symbols,
- const Output_section* dynstr)
-{
- if (!versions->any_defs() && !versions->any_needs())
- return;
-
- switch (parameters->size_and_endianness())
- {
-#ifdef HAVE_TARGET_32_LITTLE
- case Parameters::TARGET_32_LITTLE:
- this->sized_create_version_sections<32, false>(versions, symtab,
- local_symcount,
- dynamic_symbols, dynstr);
- break;
-#endif
-#ifdef HAVE_TARGET_32_BIG
- case Parameters::TARGET_32_BIG:
- this->sized_create_version_sections<32, true>(versions, symtab,
- local_symcount,
- dynamic_symbols, dynstr);
- break;
-#endif
-#ifdef HAVE_TARGET_64_LITTLE
- case Parameters::TARGET_64_LITTLE:
- this->sized_create_version_sections<64, false>(versions, symtab,
- local_symcount,
- dynamic_symbols, dynstr);
- break;
-#endif
-#ifdef HAVE_TARGET_64_BIG
- case Parameters::TARGET_64_BIG:
- this->sized_create_version_sections<64, true>(versions, symtab,
- local_symcount,
- dynamic_symbols, dynstr);
- break;
-#endif
- default:
- gold_unreachable();
- }
-}
-
-// Create the version sections, sized version.
-
-template<int size, bool big_endian>
-void
-Layout::sized_create_version_sections(
- const Versions* versions,
- const Symbol_table* symtab,
- unsigned int local_symcount,
- const std::vector<Symbol*>& dynamic_symbols,
- const Output_section* dynstr)
-{
- Output_section* vsec = this->choose_output_section(NULL, ".gnu.version",
- elfcpp::SHT_GNU_versym,
- elfcpp::SHF_ALLOC,
- false,
- ORDER_DYNAMIC_LINKER,
- false, false, false);
-
- // Check for NULL since a linker script may discard this section.
- if (vsec != NULL)
- {
- unsigned char* vbuf;
- unsigned int vsize;
- versions->symbol_section_contents<size, big_endian>(symtab,
- &this->dynpool_,
- local_symcount,
- dynamic_symbols,
- &vbuf, &vsize);
-
- Output_section_data* vdata = new Output_data_const_buffer(vbuf, vsize, 2,
- "** versions");
-
- vsec->add_output_section_data(vdata);
- vsec->set_entsize(2);
- vsec->set_link_section(this->dynsym_section_);
- }
-
- Output_data_dynamic* const odyn = this->dynamic_data_;
- if (odyn != NULL && vsec != NULL)
- odyn->add_section_address(elfcpp::DT_VERSYM, vsec);
-
- if (versions->any_defs())
- {
- Output_section* vdsec;
- vdsec = this->choose_output_section(NULL, ".gnu.version_d",
- elfcpp::SHT_GNU_verdef,
- elfcpp::SHF_ALLOC,
- false, ORDER_DYNAMIC_LINKER, false,
- false, false);
-
- if (vdsec != NULL)
- {
- unsigned char* vdbuf;
- unsigned int vdsize;
- unsigned int vdentries;
- versions->def_section_contents<size, big_endian>(&this->dynpool_,
- &vdbuf, &vdsize,
- &vdentries);
-
- Output_section_data* vddata =
- new Output_data_const_buffer(vdbuf, vdsize, 4, "** version defs");
-
- vdsec->add_output_section_data(vddata);
- vdsec->set_link_section(dynstr);
- vdsec->set_info(vdentries);
-
- if (odyn != NULL)
- {
- odyn->add_section_address(elfcpp::DT_VERDEF, vdsec);
- odyn->add_constant(elfcpp::DT_VERDEFNUM, vdentries);
- }
- }
- }
-
- if (versions->any_needs())
- {
- Output_section* vnsec;
- vnsec = this->choose_output_section(NULL, ".gnu.version_r",
- elfcpp::SHT_GNU_verneed,
- elfcpp::SHF_ALLOC,
- false, ORDER_DYNAMIC_LINKER, false,
- false, false);
-
- if (vnsec != NULL)
- {
- unsigned char* vnbuf;
- unsigned int vnsize;
- unsigned int vnentries;
- versions->need_section_contents<size, big_endian>(&this->dynpool_,
- &vnbuf, &vnsize,
- &vnentries);
-
- Output_section_data* vndata =
- new Output_data_const_buffer(vnbuf, vnsize, 4, "** version refs");
-
- vnsec->add_output_section_data(vndata);
- vnsec->set_link_section(dynstr);
- vnsec->set_info(vnentries);
-
- if (odyn != NULL)
- {
- odyn->add_section_address(elfcpp::DT_VERNEED, vnsec);
- odyn->add_constant(elfcpp::DT_VERNEEDNUM, vnentries);
- }
- }
- }
-}
-
-// Create the .interp section and PT_INTERP segment.
-
-void
-Layout::create_interp(const Target* target)
-{
- gold_assert(this->interp_segment_ == NULL);
-
- const char* interp = parameters->options().dynamic_linker();
- if (interp == NULL)
- {
- interp = target->dynamic_linker();
- gold_assert(interp != NULL);
- }
-
- size_t len = strlen(interp) + 1;
-
- Output_section_data* odata = new Output_data_const(interp, len, 1);
-
- Output_section* osec = this->choose_output_section(NULL, ".interp",
- elfcpp::SHT_PROGBITS,
- elfcpp::SHF_ALLOC,
- false, ORDER_INTERP,
- false, false, false);
- if (osec != NULL)
- osec->add_output_section_data(odata);
-}
-
-// Add dynamic tags for the PLT and the dynamic relocs. This is
-// called by the target-specific code. This does nothing if not doing
-// a dynamic link.
-
-// USE_REL is true for REL relocs rather than RELA relocs.
-
-// If PLT_GOT is not NULL, then DT_PLTGOT points to it.
-
-// If PLT_REL is not NULL, it is used for DT_PLTRELSZ, and DT_JMPREL,
-// and we also set DT_PLTREL. We use PLT_REL's output section, since
-// some targets have multiple reloc sections in PLT_REL.
-
-// If DYN_REL is not NULL, it is used for DT_REL/DT_RELA,
-// DT_RELSZ/DT_RELASZ, DT_RELENT/DT_RELAENT. Again we use the output
-// section.
-
-// If ADD_DEBUG is true, we add a DT_DEBUG entry when generating an
-// executable.
-
-void
-Layout::add_target_dynamic_tags(bool use_rel, const Output_data* plt_got,
- const Output_data* plt_rel,
- const Output_data_reloc_generic* dyn_rel,
- bool add_debug, bool dynrel_includes_plt,
- bool custom_relcount)
-{
- Output_data_dynamic* odyn = this->dynamic_data_;
- if (odyn == NULL)
- return;
-
- if (plt_got != NULL && plt_got->output_section() != NULL)
- odyn->add_section_address(elfcpp::DT_PLTGOT, plt_got);
-
- if (plt_rel != NULL && plt_rel->output_section() != NULL)
- {
- odyn->add_section_size(elfcpp::DT_PLTRELSZ, plt_rel->output_section());
- odyn->add_section_address(elfcpp::DT_JMPREL, plt_rel->output_section());
- odyn->add_constant(elfcpp::DT_PLTREL,
- use_rel ? elfcpp::DT_REL : elfcpp::DT_RELA);
- }
-
- if ((dyn_rel != NULL && dyn_rel->output_section() != NULL)
- || (dynrel_includes_plt
- && plt_rel != NULL
- && plt_rel->output_section() != NULL))
- {
- bool have_dyn_rel = dyn_rel != NULL && dyn_rel->output_section() != NULL;
- bool have_plt_rel = plt_rel != NULL && plt_rel->output_section() != NULL;
- odyn->add_section_address(use_rel ? elfcpp::DT_REL : elfcpp::DT_RELA,
- (have_dyn_rel
- ? dyn_rel->output_section()
- : plt_rel->output_section()));
- elfcpp::DT size_tag = use_rel ? elfcpp::DT_RELSZ : elfcpp::DT_RELASZ;
- if (have_dyn_rel && have_plt_rel && dynrel_includes_plt)
- odyn->add_section_size(size_tag,
- dyn_rel->output_section(),
- plt_rel->output_section());
- else if (have_dyn_rel)
- odyn->add_section_size(size_tag, dyn_rel->output_section());
- else
- odyn->add_section_size(size_tag, plt_rel->output_section());
- const int size = parameters->target().get_size();
- elfcpp::DT rel_tag;
- int rel_size;
- if (use_rel)
- {
- rel_tag = elfcpp::DT_RELENT;
- if (size == 32)
- rel_size = Reloc_types<elfcpp::SHT_REL, 32, false>::reloc_size;
- else if (size == 64)
- rel_size = Reloc_types<elfcpp::SHT_REL, 64, false>::reloc_size;
- else
- gold_unreachable();
- }
- else
- {
- rel_tag = elfcpp::DT_RELAENT;
- if (size == 32)
- rel_size = Reloc_types<elfcpp::SHT_RELA, 32, false>::reloc_size;
- else if (size == 64)
- rel_size = Reloc_types<elfcpp::SHT_RELA, 64, false>::reloc_size;
- else
- gold_unreachable();
- }
- odyn->add_constant(rel_tag, rel_size);
-
- if (parameters->options().combreloc() && have_dyn_rel)
- {
- size_t c = dyn_rel->relative_reloc_count();
- if (c != 0)
- {
- elfcpp::DT tag
- = use_rel ? elfcpp::DT_RELCOUNT : elfcpp::DT_RELACOUNT;
- if (custom_relcount)
- odyn->add_custom(tag);
- else
- odyn->add_constant(tag, c);
- }
- }
- }
-
- if (add_debug && !parameters->options().shared())
- {
- // The value of the DT_DEBUG tag is filled in by the dynamic
- // linker at run time, and used by the debugger.
- odyn->add_constant(elfcpp::DT_DEBUG, 0);
- }
-}
-
-void
-Layout::add_target_specific_dynamic_tag(elfcpp::DT tag, unsigned int val)
-{
- Output_data_dynamic* odyn = this->dynamic_data_;
- if (odyn == NULL)
- return;
- odyn->add_constant(tag, val);
-}
-
-// Finish the .dynamic section and PT_DYNAMIC segment.
-
-void
-Layout::finish_dynamic_section(const Input_objects* input_objects,
- const Symbol_table* symtab)
-{
- if (!this->script_options_->saw_phdrs_clause()
- && this->dynamic_section_ != NULL)
- {
- Output_segment* oseg = this->make_output_segment(elfcpp::PT_DYNAMIC,
- (elfcpp::PF_R
- | elfcpp::PF_W));
- oseg->add_output_section_to_nonload(this->dynamic_section_,
- elfcpp::PF_R | elfcpp::PF_W);
- }
-
- Output_data_dynamic* const odyn = this->dynamic_data_;
- if (odyn == NULL)
- return;
-
- for (Input_objects::Dynobj_iterator p = input_objects->dynobj_begin();
- p != input_objects->dynobj_end();
- ++p)
- {
- if (!(*p)->is_needed() && (*p)->as_needed())
- {
- // This dynamic object was linked with --as-needed, but it
- // is not needed.
- continue;
- }
-
- odyn->add_string(elfcpp::DT_NEEDED, (*p)->soname());
- }
-
- if (parameters->options().shared())
- {
- const char* soname = parameters->options().soname();
- if (soname != NULL)
- odyn->add_string(elfcpp::DT_SONAME, soname);
- }
-
- Symbol* sym = symtab->lookup(parameters->options().init());
- if (sym != NULL && sym->is_defined() && !sym->is_from_dynobj())
- odyn->add_symbol(elfcpp::DT_INIT, sym);
-
- sym = symtab->lookup(parameters->options().fini());
- if (sym != NULL && sym->is_defined() && !sym->is_from_dynobj())
- odyn->add_symbol(elfcpp::DT_FINI, sym);
-
- // Look for .init_array, .preinit_array and .fini_array by checking
- // section types.
- for(Layout::Section_list::const_iterator p = this->section_list_.begin();
- p != this->section_list_.end();
- ++p)
- switch((*p)->type())
- {
- case elfcpp::SHT_FINI_ARRAY:
- odyn->add_section_address(elfcpp::DT_FINI_ARRAY, *p);
- odyn->add_section_size(elfcpp::DT_FINI_ARRAYSZ, *p);
- break;
- case elfcpp::SHT_INIT_ARRAY:
- odyn->add_section_address(elfcpp::DT_INIT_ARRAY, *p);
- odyn->add_section_size(elfcpp::DT_INIT_ARRAYSZ, *p);
- break;
- case elfcpp::SHT_PREINIT_ARRAY:
- odyn->add_section_address(elfcpp::DT_PREINIT_ARRAY, *p);
- odyn->add_section_size(elfcpp::DT_PREINIT_ARRAYSZ, *p);
- break;
- default:
- break;
- }
-
- // Add a DT_RPATH entry if needed.
- const General_options::Dir_list& rpath(parameters->options().rpath());
- if (!rpath.empty())
- {
- std::string rpath_val;
- for (General_options::Dir_list::const_iterator p = rpath.begin();
- p != rpath.end();
- ++p)
- {
- if (rpath_val.empty())
- rpath_val = p->name();
- else
- {
- // Eliminate duplicates.
- General_options::Dir_list::const_iterator q;
- for (q = rpath.begin(); q != p; ++q)
- if (q->name() == p->name())
- break;
- if (q == p)
- {
- rpath_val += ':';
- rpath_val += p->name();
- }
- }
- }
-
- if (!parameters->options().enable_new_dtags())
- odyn->add_string(elfcpp::DT_RPATH, rpath_val);
- else
- odyn->add_string(elfcpp::DT_RUNPATH, rpath_val);
- }
-
- // Look for text segments that have dynamic relocations.
- bool have_textrel = false;
- if (!this->script_options_->saw_sections_clause())
- {
- for (Segment_list::const_iterator p = this->segment_list_.begin();
- p != this->segment_list_.end();
- ++p)
- {
- if ((*p)->type() == elfcpp::PT_LOAD
- && ((*p)->flags() & elfcpp::PF_W) == 0
- && (*p)->has_dynamic_reloc())
- {
- have_textrel = true;
- break;
- }
- }
- }
- else
- {
- // We don't know the section -> segment mapping, so we are
- // conservative and just look for readonly sections with
- // relocations. If those sections wind up in writable segments,
- // then we have created an unnecessary DT_TEXTREL entry.
- for (Section_list::const_iterator p = this->section_list_.begin();
- p != this->section_list_.end();
- ++p)
- {
- if (((*p)->flags() & elfcpp::SHF_ALLOC) != 0
- && ((*p)->flags() & elfcpp::SHF_WRITE) == 0
- && (*p)->has_dynamic_reloc())
- {
- have_textrel = true;
- break;
- }
- }
- }
-
- if (parameters->options().filter() != NULL)
- odyn->add_string(elfcpp::DT_FILTER, parameters->options().filter());
- if (parameters->options().any_auxiliary())
- {
- for (options::String_set::const_iterator p =
- parameters->options().auxiliary_begin();
- p != parameters->options().auxiliary_end();
- ++p)
- odyn->add_string(elfcpp::DT_AUXILIARY, *p);
- }
-
- // Add a DT_FLAGS entry if necessary.
- unsigned int flags = 0;
- if (have_textrel)
- {
- // Add a DT_TEXTREL for compatibility with older loaders.
- odyn->add_constant(elfcpp::DT_TEXTREL, 0);
- flags |= elfcpp::DF_TEXTREL;
-
- if (parameters->options().text())
- gold_error(_("read-only segment has dynamic relocations"));
- else if (parameters->options().warn_shared_textrel()
- && parameters->options().shared())
- gold_warning(_("shared library text segment is not shareable"));
- }
- if (parameters->options().shared() && this->has_static_tls())
- flags |= elfcpp::DF_STATIC_TLS;
- if (parameters->options().origin())
- flags |= elfcpp::DF_ORIGIN;
- if (parameters->options().Bsymbolic()
- && !parameters->options().have_dynamic_list())
- {
- flags |= elfcpp::DF_SYMBOLIC;
- // Add DT_SYMBOLIC for compatibility with older loaders.
- odyn->add_constant(elfcpp::DT_SYMBOLIC, 0);
- }
- if (parameters->options().now())
- flags |= elfcpp::DF_BIND_NOW;
- if (flags != 0)
- odyn->add_constant(elfcpp::DT_FLAGS, flags);
-
- flags = 0;
- if (parameters->options().global())
- flags |= elfcpp::DF_1_GLOBAL;
- if (parameters->options().initfirst())
- flags |= elfcpp::DF_1_INITFIRST;
- if (parameters->options().interpose())
- flags |= elfcpp::DF_1_INTERPOSE;
- if (parameters->options().loadfltr())
- flags |= elfcpp::DF_1_LOADFLTR;
- if (parameters->options().nodefaultlib())
- flags |= elfcpp::DF_1_NODEFLIB;
- if (parameters->options().nodelete())
- flags |= elfcpp::DF_1_NODELETE;
- if (parameters->options().nodlopen())
- flags |= elfcpp::DF_1_NOOPEN;
- if (parameters->options().nodump())
- flags |= elfcpp::DF_1_NODUMP;
- if (!parameters->options().shared())
- flags &= ~(elfcpp::DF_1_INITFIRST
- | elfcpp::DF_1_NODELETE
- | elfcpp::DF_1_NOOPEN);
- if (parameters->options().origin())
- flags |= elfcpp::DF_1_ORIGIN;
- if (parameters->options().now())
- flags |= elfcpp::DF_1_NOW;
- if (parameters->options().Bgroup())
- flags |= elfcpp::DF_1_GROUP;
- if (parameters->options().pie())
- flags |= elfcpp::DF_1_PIE;
- if (flags != 0)
- odyn->add_constant(elfcpp::DT_FLAGS_1, flags);
-
- flags = 0;
- if (parameters->options().unique())
- flags |= elfcpp::DF_GNU_1_UNIQUE;
- if (flags != 0)
- odyn->add_constant(elfcpp::DT_GNU_FLAGS_1, flags);
-}
-
-// Set the size of the _DYNAMIC symbol table to be the size of the
-// dynamic data.
-
-void
-Layout::set_dynamic_symbol_size(const Symbol_table* symtab)
-{
- Output_data_dynamic* const odyn = this->dynamic_data_;
- if (odyn == NULL)
- return;
- odyn->finalize_data_size();
- if (this->dynamic_symbol_ == NULL)
- return;
- off_t data_size = odyn->data_size();
- const int size = parameters->target().get_size();
- if (size == 32)
- symtab->get_sized_symbol<32>(this->dynamic_symbol_)->set_symsize(data_size);
- else if (size == 64)
- symtab->get_sized_symbol<64>(this->dynamic_symbol_)->set_symsize(data_size);
- else
- gold_unreachable();
-}
-
-// The mapping of input section name prefixes to output section names.
-// In some cases one prefix is itself a prefix of another prefix; in
-// such a case the longer prefix must come first. These prefixes are
-// based on the GNU linker default ELF linker script.
-
-#define MAPPING_INIT(f, t) { f, sizeof(f) - 1, t, sizeof(t) - 1 }
-#define MAPPING_INIT_EXACT(f, t) { f, 0, t, sizeof(t) - 1 }
-const Layout::Section_name_mapping Layout::section_name_mapping[] =
-{
- MAPPING_INIT(".text.", ".text"),
- MAPPING_INIT(".rodata.", ".rodata"),
- MAPPING_INIT(".data.rel.ro.local.", ".data.rel.ro.local"),
- MAPPING_INIT_EXACT(".data.rel.ro.local", ".data.rel.ro.local"),
- MAPPING_INIT(".data.rel.ro.", ".data.rel.ro"),
- MAPPING_INIT_EXACT(".data.rel.ro", ".data.rel.ro"),
- MAPPING_INIT(".data.", ".data"),
- MAPPING_INIT(".bss.", ".bss"),
- MAPPING_INIT(".tdata.", ".tdata"),
- MAPPING_INIT(".tbss.", ".tbss"),
- MAPPING_INIT(".init_array.", ".init_array"),
- MAPPING_INIT(".fini_array.", ".fini_array"),
- MAPPING_INIT(".sdata.", ".sdata"),
- MAPPING_INIT(".sbss.", ".sbss"),
- // FIXME: In the GNU linker, .sbss2 and .sdata2 are handled
- // differently depending on whether it is creating a shared library.
- MAPPING_INIT(".sdata2.", ".sdata"),
- MAPPING_INIT(".sbss2.", ".sbss"),
- MAPPING_INIT(".lrodata.", ".lrodata"),
- MAPPING_INIT(".ldata.", ".ldata"),
- MAPPING_INIT(".lbss.", ".lbss"),
- MAPPING_INIT(".gcc_except_table.", ".gcc_except_table"),
- MAPPING_INIT(".gnu.linkonce.d.rel.ro.local.", ".data.rel.ro.local"),
- MAPPING_INIT(".gnu.linkonce.d.rel.ro.", ".data.rel.ro"),
- MAPPING_INIT(".gnu.linkonce.t.", ".text"),
- MAPPING_INIT(".gnu.linkonce.r.", ".rodata"),
- MAPPING_INIT(".gnu.linkonce.d.", ".data"),
- MAPPING_INIT(".gnu.linkonce.b.", ".bss"),
- MAPPING_INIT(".gnu.linkonce.s.", ".sdata"),
- MAPPING_INIT(".gnu.linkonce.sb.", ".sbss"),
- MAPPING_INIT(".gnu.linkonce.s2.", ".sdata"),
- MAPPING_INIT(".gnu.linkonce.sb2.", ".sbss"),
- MAPPING_INIT(".gnu.linkonce.wi.", ".debug_info"),
- MAPPING_INIT(".gnu.linkonce.td.", ".tdata"),
- MAPPING_INIT(".gnu.linkonce.tb.", ".tbss"),
- MAPPING_INIT(".gnu.linkonce.lr.", ".lrodata"),
- MAPPING_INIT(".gnu.linkonce.l.", ".ldata"),
- MAPPING_INIT(".gnu.linkonce.lb.", ".lbss"),
- MAPPING_INIT(".ARM.extab", ".ARM.extab"),
- MAPPING_INIT(".gnu.linkonce.armextab.", ".ARM.extab"),
- MAPPING_INIT(".ARM.exidx", ".ARM.exidx"),
- MAPPING_INIT(".gnu.linkonce.armexidx.", ".ARM.exidx"),
- MAPPING_INIT(".gnu.build.attributes.", ".gnu.build.attributes"),
-};
-
-// Mapping for ".text" section prefixes with -z,keep-text-section-prefix.
-const Layout::Section_name_mapping Layout::text_section_name_mapping[] =
-{
- MAPPING_INIT(".text.hot.", ".text.hot"),
- MAPPING_INIT_EXACT(".text.hot", ".text.hot"),
- MAPPING_INIT(".text.unlikely.", ".text.unlikely"),
- MAPPING_INIT_EXACT(".text.unlikely", ".text.unlikely"),
- MAPPING_INIT(".text.startup.", ".text.startup"),
- MAPPING_INIT_EXACT(".text.startup", ".text.startup"),
- MAPPING_INIT(".text.exit.", ".text.exit"),
- MAPPING_INIT_EXACT(".text.exit", ".text.exit"),
- MAPPING_INIT(".text.", ".text"),
-};
-#undef MAPPING_INIT
-#undef MAPPING_INIT_EXACT
-
-const int Layout::section_name_mapping_count =
- (sizeof(Layout::section_name_mapping)
- / sizeof(Layout::section_name_mapping[0]));
-
-const int Layout::text_section_name_mapping_count =
- (sizeof(Layout::text_section_name_mapping)
- / sizeof(Layout::text_section_name_mapping[0]));
-
-// Find section name NAME in PSNM and return the mapped name if found
-// with the length set in PLEN.
-const char *
-Layout::match_section_name(const Layout::Section_name_mapping* psnm,
- const int count,
- const char* name, size_t* plen)
-{
- for (int i = 0; i < count; ++i, ++psnm)
- {
- if (psnm->fromlen > 0)
- {
- if (strncmp(name, psnm->from, psnm->fromlen) == 0)
- {
- *plen = psnm->tolen;
- return psnm->to;
- }
- }
- else
- {
- if (strcmp(name, psnm->from) == 0)
- {
- *plen = psnm->tolen;
- return psnm->to;
- }
- }
- }
- return NULL;
-}
-
-// Choose the output section name to use given an input section name.
-// Set *PLEN to the length of the name. *PLEN is initialized to the
-// length of NAME.
-
-const char*
-Layout::output_section_name(const Relobj* relobj, const char* name,
- size_t* plen)
-{
- // gcc 4.3 generates the following sorts of section names when it
- // needs a section name specific to a function:
- // .text.FN
- // .rodata.FN
- // .sdata2.FN
- // .data.FN
- // .data.rel.FN
- // .data.rel.local.FN
- // .data.rel.ro.FN
- // .data.rel.ro.local.FN
- // .sdata.FN
- // .bss.FN
- // .sbss.FN
- // .tdata.FN
- // .tbss.FN
-
- // The GNU linker maps all of those to the part before the .FN,
- // except that .data.rel.local.FN is mapped to .data, and
- // .data.rel.ro.local.FN is mapped to .data.rel.ro. The sections
- // beginning with .data.rel.ro.local are grouped together.
-
- // For an anonymous namespace, the string FN can contain a '.'.
-
- // Also of interest: .rodata.strN.N, .rodata.cstN, both of which the
- // GNU linker maps to .rodata.
-
- // The .data.rel.ro sections are used with -z relro. The sections
- // are recognized by name. We use the same names that the GNU
- // linker does for these sections.
-
- // It is hard to handle this in a principled way, so we don't even
- // try. We use a table of mappings. If the input section name is
- // not found in the table, we simply use it as the output section
- // name.
-
- if (parameters->options().keep_text_section_prefix()
- && is_prefix_of(".text", name))
- {
- const char* match = match_section_name(text_section_name_mapping,
- text_section_name_mapping_count,
- name, plen);
- if (match != NULL)
- return match;
- }
-
- const char* match = match_section_name(section_name_mapping,
- section_name_mapping_count, name, plen);
- if (match != NULL)
- return match;
-
- // As an additional complication, .ctors sections are output in
- // either .ctors or .init_array sections, and .dtors sections are
- // output in either .dtors or .fini_array sections.
- if (is_prefix_of(".ctors.", name) || is_prefix_of(".dtors.", name))
- {
- if (parameters->options().ctors_in_init_array())
- {
- *plen = 11;
- return name[1] == 'c' ? ".init_array" : ".fini_array";
- }
- else
- {
- *plen = 6;
- return name[1] == 'c' ? ".ctors" : ".dtors";
- }
- }
- if (parameters->options().ctors_in_init_array()
- && (strcmp(name, ".ctors") == 0 || strcmp(name, ".dtors") == 0))
- {
- // To make .init_array/.fini_array work with gcc we must exclude
- // .ctors and .dtors sections from the crtbegin and crtend
- // files.
- if (relobj == NULL
- || (!Layout::match_file_name(relobj, "crtbegin")
- && !Layout::match_file_name(relobj, "crtend")))
- {
- *plen = 11;
- return name[1] == 'c' ? ".init_array" : ".fini_array";
- }
- }
-
- return name;
-}
-
-// Return true if RELOBJ is an input file whose base name matches
-// FILE_NAME. The base name must have an extension of ".o", and must
-// be exactly FILE_NAME.o or FILE_NAME, one character, ".o". This is
-// to match crtbegin.o as well as crtbeginS.o without getting confused
-// by other possibilities. Overall matching the file name this way is
-// a dreadful hack, but the GNU linker does it in order to better
-// support gcc, and we need to be compatible.
-
-bool
-Layout::match_file_name(const Relobj* relobj, const char* match)
-{
- const std::string& file_name(relobj->name());
- const char* base_name = lbasename(file_name.c_str());
- size_t match_len = strlen(match);
- if (strncmp(base_name, match, match_len) != 0)
- return false;
- size_t base_len = strlen(base_name);
- if (base_len != match_len + 2 && base_len != match_len + 3)
- return false;
- return memcmp(base_name + base_len - 2, ".o", 2) == 0;
-}
-
-// Check if a comdat group or .gnu.linkonce section with the given
-// NAME is selected for the link. If there is already a section,
-// *KEPT_SECTION is set to point to the existing section and the
-// function returns false. Otherwise, OBJECT, SHNDX, IS_COMDAT, and
-// IS_GROUP_NAME are recorded for this NAME in the layout object,
-// *KEPT_SECTION is set to the internal copy and the function returns
-// true.
-
-bool
-Layout::find_or_add_kept_section(const std::string& name,
- Relobj* object,
- unsigned int shndx,
- bool is_comdat,
- bool is_group_name,
- Kept_section** kept_section)
-{
- // It's normal to see a couple of entries here, for the x86 thunk
- // sections. If we see more than a few, we're linking a C++
- // program, and we resize to get more space to minimize rehashing.
- if (this->signatures_.size() > 4
- && !this->resized_signatures_)
- {
- reserve_unordered_map(&this->signatures_,
- this->number_of_input_files_ * 64);
- this->resized_signatures_ = true;
- }
-
- Kept_section candidate;
- std::pair<Signatures::iterator, bool> ins =
- this->signatures_.insert(std::make_pair(name, candidate));
-
- if (kept_section != NULL)
- *kept_section = &ins.first->second;
- if (ins.second)
- {
- // This is the first time we've seen this signature.
- ins.first->second.set_object(object);
- ins.first->second.set_shndx(shndx);
- if (is_comdat)
- ins.first->second.set_is_comdat();
- if (is_group_name)
- ins.first->second.set_is_group_name();
- return true;
- }
-
- // We have already seen this signature.
-
- if (ins.first->second.is_group_name())
- {
- // We've already seen a real section group with this signature.
- // If the kept group is from a plugin object, and we're in the
- // replacement phase, accept the new one as a replacement.
- if (ins.first->second.object() == NULL
- && parameters->options().plugins()->in_replacement_phase())
- {
- ins.first->second.set_object(object);
- ins.first->second.set_shndx(shndx);
- return true;
- }
- return false;
- }
- else if (is_group_name)
- {
- // This is a real section group, and we've already seen a
- // linkonce section with this signature. Record that we've seen
- // a section group, and don't include this section group.
- ins.first->second.set_is_group_name();
- return false;
- }
- else
- {
- // We've already seen a linkonce section and this is a linkonce
- // section. These don't block each other--this may be the same
- // symbol name with different section types.
- return true;
- }
-}
-
-// Store the allocated sections into the section list.
-
-void
-Layout::get_allocated_sections(Section_list* section_list) const
-{
- for (Section_list::const_iterator p = this->section_list_.begin();
- p != this->section_list_.end();
- ++p)
- if (((*p)->flags() & elfcpp::SHF_ALLOC) != 0)
- section_list->push_back(*p);
-}
-
-// Store the executable sections into the section list.
-
-void
-Layout::get_executable_sections(Section_list* section_list) const
-{
- for (Section_list::const_iterator p = this->section_list_.begin();
- p != this->section_list_.end();
- ++p)
- if (((*p)->flags() & (elfcpp::SHF_ALLOC | elfcpp::SHF_EXECINSTR))
- == (elfcpp::SHF_ALLOC | elfcpp::SHF_EXECINSTR))
- section_list->push_back(*p);
-}
-
-// Create an output segment.
-
-Output_segment*
-Layout::make_output_segment(elfcpp::Elf_Word type, elfcpp::Elf_Word flags)
-{
- gold_assert(!parameters->options().relocatable());
- Output_segment* oseg = new Output_segment(type, flags);
- this->segment_list_.push_back(oseg);
-
- if (type == elfcpp::PT_TLS)
- this->tls_segment_ = oseg;
- else if (type == elfcpp::PT_GNU_RELRO)
- this->relro_segment_ = oseg;
- else if (type == elfcpp::PT_INTERP)
- this->interp_segment_ = oseg;
-
- return oseg;
-}
-
-// Return the file offset of the normal symbol table.
-
-off_t
-Layout::symtab_section_offset() const
-{
- if (this->symtab_section_ != NULL)
- return this->symtab_section_->offset();
- return 0;
-}
-
-// Return the section index of the normal symbol table. It may have
-// been stripped by the -s/--strip-all option.
-
-unsigned int
-Layout::symtab_section_shndx() const
-{
- if (this->symtab_section_ != NULL)
- return this->symtab_section_->out_shndx();
- return 0;
-}
-
-// Write out the Output_sections. Most won't have anything to write,
-// since most of the data will come from input sections which are
-// handled elsewhere. But some Output_sections do have Output_data.
-
-void
-Layout::write_output_sections(Output_file* of) const
-{
- for (Section_list::const_iterator p = this->section_list_.begin();
- p != this->section_list_.end();
- ++p)
- {
- if (!(*p)->after_input_sections())
- (*p)->write(of);
- }
-}
-
-// Write out data not associated with a section or the symbol table.
-
-void
-Layout::write_data(const Symbol_table* symtab, Output_file* of) const
-{
- if (!parameters->options().strip_all())
- {
- const Output_section* symtab_section = this->symtab_section_;
- for (Section_list::const_iterator p = this->section_list_.begin();
- p != this->section_list_.end();
- ++p)
- {
- if ((*p)->needs_symtab_index())
- {
- gold_assert(symtab_section != NULL);
- unsigned int index = (*p)->symtab_index();
- gold_assert(index > 0 && index != -1U);
- off_t off = (symtab_section->offset()
- + index * symtab_section->entsize());
- symtab->write_section_symbol(*p, this->symtab_xindex_, of, off);
- }
- }
- }
-
- const Output_section* dynsym_section = this->dynsym_section_;
- for (Section_list::const_iterator p = this->section_list_.begin();
- p != this->section_list_.end();
- ++p)
- {
- if ((*p)->needs_dynsym_index())
- {
- gold_assert(dynsym_section != NULL);
- unsigned int index = (*p)->dynsym_index();
- gold_assert(index > 0 && index != -1U);
- off_t off = (dynsym_section->offset()
- + index * dynsym_section->entsize());
- symtab->write_section_symbol(*p, this->dynsym_xindex_, of, off);
- }
- }
-
- // Write out the Output_data which are not in an Output_section.
- for (Data_list::const_iterator p = this->special_output_list_.begin();
- p != this->special_output_list_.end();
- ++p)
- (*p)->write(of);
-
- // Write out the Output_data which are not in an Output_section
- // and are regenerated in each iteration of relaxation.
- for (Data_list::const_iterator p = this->relax_output_list_.begin();
- p != this->relax_output_list_.end();
- ++p)
- (*p)->write(of);
-}
-
-// Write out the Output_sections which can only be written after the
-// input sections are complete.
-
-void
-Layout::write_sections_after_input_sections(Output_file* of)
-{
- // Determine the final section offsets, and thus the final output
- // file size. Note we finalize the .shstrab last, to allow the
- // after_input_section sections to modify their section-names before
- // writing.
- if (this->any_postprocessing_sections_)
- {
- off_t off = this->output_file_size_;
- off = this->set_section_offsets(off, POSTPROCESSING_SECTIONS_PASS);
-
- // Now that we've finalized the names, we can finalize the shstrab.
- off =
- this->set_section_offsets(off,
- STRTAB_AFTER_POSTPROCESSING_SECTIONS_PASS);
-
- if (off > this->output_file_size_)
- {
- of->resize(off);
- this->output_file_size_ = off;
- }
- }
-
- for (Section_list::const_iterator p = this->section_list_.begin();
- p != this->section_list_.end();
- ++p)
- {
- if ((*p)->after_input_sections())
- (*p)->write(of);
- }
-
- this->section_headers_->write(of);
-}
-
-// If a tree-style build ID was requested, the parallel part of that computation
-// is already done, and the final hash-of-hashes is computed here. For other
-// types of build IDs, all the work is done here.
-
-void
-Layout::write_build_id(Output_file* of, unsigned char* array_of_hashes,
- size_t size_of_hashes) const
-{
- if (this->build_id_note_ == NULL)
- return;
-
- unsigned char* ov = of->get_output_view(this->build_id_note_->offset(),
- this->build_id_note_->data_size());
-
- if (array_of_hashes == NULL)
- {
- const size_t output_file_size = this->output_file_size();
- const unsigned char* iv = of->get_input_view(0, output_file_size);
- const char* style = parameters->options().build_id();
-
- // If we get here with style == "tree" then the output must be
- // too small for chunking, and we use SHA-1 in that case.
- if ((strcmp(style, "sha1") == 0) || (strcmp(style, "tree") == 0))
- sha1_buffer(reinterpret_cast<const char*>(iv), output_file_size, ov);
- else if (strcmp(style, "md5") == 0)
- md5_buffer(reinterpret_cast<const char*>(iv), output_file_size, ov);
- else
- gold_unreachable();
-
- of->free_input_view(0, output_file_size, iv);
- }
- else
- {
- // Non-overlapping substrings of the output file have been hashed.
- // Compute SHA-1 hash of the hashes.
- sha1_buffer(reinterpret_cast<const char*>(array_of_hashes),
- size_of_hashes, ov);
- delete[] array_of_hashes;
- }
-
- of->write_output_view(this->build_id_note_->offset(),
- this->build_id_note_->data_size(),
- ov);
-}
-
-// Write out a binary file. This is called after the link is
-// complete. IN is the temporary output file we used to generate the
-// ELF code. We simply walk through the segments, read them from
-// their file offset in IN, and write them to their load address in
-// the output file. FIXME: with a bit more work, we could support
-// S-records and/or Intel hex format here.
-
-void
-Layout::write_binary(Output_file* in) const
-{
- gold_assert(parameters->options().oformat_enum()
- == General_options::OBJECT_FORMAT_BINARY);
-
- // Get the size of the binary file.
- uint64_t max_load_address = 0;
- for (Segment_list::const_iterator p = this->segment_list_.begin();
- p != this->segment_list_.end();
- ++p)
- {
- if ((*p)->type() == elfcpp::PT_LOAD && (*p)->filesz() > 0)
- {
- uint64_t max_paddr = (*p)->paddr() + (*p)->filesz();
- if (max_paddr > max_load_address)
- max_load_address = max_paddr;
- }
- }
-
- Output_file out(parameters->options().output_file_name());
- out.open(max_load_address);
-
- for (Segment_list::const_iterator p = this->segment_list_.begin();
- p != this->segment_list_.end();
- ++p)
- {
- if ((*p)->type() == elfcpp::PT_LOAD && (*p)->filesz() > 0)
- {
- const unsigned char* vin = in->get_input_view((*p)->offset(),
- (*p)->filesz());
- unsigned char* vout = out.get_output_view((*p)->paddr(),
- (*p)->filesz());
- memcpy(vout, vin, (*p)->filesz());
- out.write_output_view((*p)->paddr(), (*p)->filesz(), vout);
- in->free_input_view((*p)->offset(), (*p)->filesz(), vin);
- }
- }
-
- out.close();
-}
-
-// Print the output sections to the map file.
-
-void
-Layout::print_to_mapfile(Mapfile* mapfile) const
-{
- for (Segment_list::const_iterator p = this->segment_list_.begin();
- p != this->segment_list_.end();
- ++p)
- (*p)->print_sections_to_mapfile(mapfile);
- for (Section_list::const_iterator p = this->unattached_section_list_.begin();
- p != this->unattached_section_list_.end();
- ++p)
- (*p)->print_to_mapfile(mapfile);
-}
-
-// Print statistical information to stderr. This is used for --stats.
-
-void
-Layout::print_stats() const
-{
- this->namepool_.print_stats("section name pool");
- this->sympool_.print_stats("output symbol name pool");
- this->dynpool_.print_stats("dynamic name pool");
-
- for (Section_list::const_iterator p = this->section_list_.begin();
- p != this->section_list_.end();
- ++p)
- (*p)->print_merge_stats();
-}
-
-// Write_sections_task methods.
-
-// We can always run this task.
-
-Task_token*
-Write_sections_task::is_runnable()
-{
- return NULL;
-}
-
-// We need to unlock both OUTPUT_SECTIONS_BLOCKER and FINAL_BLOCKER
-// when finished.
-
-void
-Write_sections_task::locks(Task_locker* tl)
-{
- tl->add(this, this->output_sections_blocker_);
- if (this->input_sections_blocker_ != NULL)
- tl->add(this, this->input_sections_blocker_);
- tl->add(this, this->final_blocker_);
-}
-
-// Run the task--write out the data.
-
-void
-Write_sections_task::run(Workqueue*)
-{
- this->layout_->write_output_sections(this->of_);
-}
-
-// Write_data_task methods.
-
-// We can always run this task.
-
-Task_token*
-Write_data_task::is_runnable()
-{
- return NULL;
-}
-
-// We need to unlock FINAL_BLOCKER when finished.
-
-void
-Write_data_task::locks(Task_locker* tl)
-{
- tl->add(this, this->final_blocker_);
-}
-
-// Run the task--write out the data.
-
-void
-Write_data_task::run(Workqueue*)
-{
- this->layout_->write_data(this->symtab_, this->of_);
-}
-
-// Write_symbols_task methods.
-
-// We can always run this task.
-
-Task_token*
-Write_symbols_task::is_runnable()
-{
- return NULL;
-}
-
-// We need to unlock FINAL_BLOCKER when finished.
-
-void
-Write_symbols_task::locks(Task_locker* tl)
-{
- tl->add(this, this->final_blocker_);
-}
-
-// Run the task--write out the symbols.
-
-void
-Write_symbols_task::run(Workqueue*)
-{
- this->symtab_->write_globals(this->sympool_, this->dynpool_,
- this->layout_->symtab_xindex(),
- this->layout_->dynsym_xindex(), this->of_);
-}
-
-// Write_after_input_sections_task methods.
-
-// We can only run this task after the input sections have completed.
-
-Task_token*
-Write_after_input_sections_task::is_runnable()
-{
- if (this->input_sections_blocker_->is_blocked())
- return this->input_sections_blocker_;
- return NULL;
-}
-
-// We need to unlock FINAL_BLOCKER when finished.
-
-void
-Write_after_input_sections_task::locks(Task_locker* tl)
-{
- tl->add(this, this->final_blocker_);
-}
-
-// Run the task.
-
-void
-Write_after_input_sections_task::run(Workqueue*)
-{
- this->layout_->write_sections_after_input_sections(this->of_);
-}
-
-// Build IDs can be computed as a "flat" sha1 or md5 of a string of bytes,
-// or as a "tree" where each chunk of the string is hashed and then those
-// hashes are put into a (much smaller) string which is hashed with sha1.
-// We compute a checksum over the entire file because that is simplest.
-
-void
-Build_id_task_runner::run(Workqueue* workqueue, const Task*)
-{
- Task_token* post_hash_tasks_blocker = new Task_token(true);
- const Layout* layout = this->layout_;
- Output_file* of = this->of_;
- const size_t filesize = (layout->output_file_size() <= 0 ? 0
- : static_cast<size_t>(layout->output_file_size()));
- unsigned char* array_of_hashes = NULL;
- size_t size_of_hashes = 0;
-
- if (strcmp(this->options_->build_id(), "tree") == 0
- && this->options_->build_id_chunk_size_for_treehash() > 0
- && filesize > 0
- && (filesize >= this->options_->build_id_min_file_size_for_treehash()))
- {
- static const size_t MD5_OUTPUT_SIZE_IN_BYTES = 16;
- const size_t chunk_size =
- this->options_->build_id_chunk_size_for_treehash();
- const size_t num_hashes = ((filesize - 1) / chunk_size) + 1;
- post_hash_tasks_blocker->add_blockers(num_hashes);
- size_of_hashes = num_hashes * MD5_OUTPUT_SIZE_IN_BYTES;
- array_of_hashes = new unsigned char[size_of_hashes];
- unsigned char *dst = array_of_hashes;
- for (size_t i = 0, src_offset = 0; i < num_hashes;
- i++, dst += MD5_OUTPUT_SIZE_IN_BYTES, src_offset += chunk_size)
- {
- size_t size = std::min(chunk_size, filesize - src_offset);
- workqueue->queue(new Hash_task(of,
- src_offset,
- size,
- dst,
- post_hash_tasks_blocker));
- }
- }
-
- // Queue the final task to write the build id and close the output file.
- workqueue->queue(new Task_function(new Close_task_runner(this->options_,
- layout,
- of,
- array_of_hashes,
- size_of_hashes),
- post_hash_tasks_blocker,
- "Task_function Close_task_runner"));
-}
-
-// Close_task_runner methods.
-
-// Finish up the build ID computation, if necessary, and write a binary file,
-// if necessary. Then close the output file.
-
-void
-Close_task_runner::run(Workqueue*, const Task*)
-{
- // At this point the multi-threaded part of the build ID computation,
- // if any, is done. See Build_id_task_runner.
- this->layout_->write_build_id(this->of_, this->array_of_hashes_,
- this->size_of_hashes_);
-
- // If we've been asked to create a binary file, we do so here.
- if (this->options_->oformat_enum() != General_options::OBJECT_FORMAT_ELF)
- this->layout_->write_binary(this->of_);
-
- if (this->options_->dependency_file())
- File_read::write_dependency_file(this->options_->dependency_file(),
- this->options_->output_file_name());
-
- this->of_->close();
-}
-
-// Instantiate the templates we need. We could use the configure
-// script to restrict this to only the ones for implemented targets.
-
-#ifdef HAVE_TARGET_32_LITTLE
-template
-Output_section*
-Layout::init_fixed_output_section<32, false>(
- const char* name,
- elfcpp::Shdr<32, false>& shdr);
-#endif
-
-#ifdef HAVE_TARGET_32_BIG
-template
-Output_section*
-Layout::init_fixed_output_section<32, true>(
- const char* name,
- elfcpp::Shdr<32, true>& shdr);
-#endif
-
-#ifdef HAVE_TARGET_64_LITTLE
-template
-Output_section*
-Layout::init_fixed_output_section<64, false>(
- const char* name,
- elfcpp::Shdr<64, false>& shdr);
-#endif
-
-#ifdef HAVE_TARGET_64_BIG
-template
-Output_section*
-Layout::init_fixed_output_section<64, true>(
- const char* name,
- elfcpp::Shdr<64, true>& shdr);
-#endif
-
-#ifdef HAVE_TARGET_32_LITTLE
-template
-Output_section*
-Layout::layout<32, false>(Sized_relobj_file<32, false>* object,
- unsigned int shndx,
- const char* name,
- const elfcpp::Shdr<32, false>& shdr,
- unsigned int, unsigned int, unsigned int, off_t*);
-#endif
-
-#ifdef HAVE_TARGET_32_BIG
-template
-Output_section*
-Layout::layout<32, true>(Sized_relobj_file<32, true>* object,
- unsigned int shndx,
- const char* name,
- const elfcpp::Shdr<32, true>& shdr,
- unsigned int, unsigned int, unsigned int, off_t*);
-#endif
-
-#ifdef HAVE_TARGET_64_LITTLE
-template
-Output_section*
-Layout::layout<64, false>(Sized_relobj_file<64, false>* object,
- unsigned int shndx,
- const char* name,
- const elfcpp::Shdr<64, false>& shdr,
- unsigned int, unsigned int, unsigned int, off_t*);
-#endif
-
-#ifdef HAVE_TARGET_64_BIG
-template
-Output_section*
-Layout::layout<64, true>(Sized_relobj_file<64, true>* object,
- unsigned int shndx,
- const char* name,
- const elfcpp::Shdr<64, true>& shdr,
- unsigned int, unsigned int, unsigned int, off_t*);
-#endif
-
-#ifdef HAVE_TARGET_32_LITTLE
-template
-Output_section*
-Layout::layout_reloc<32, false>(Sized_relobj_file<32, false>* object,
- unsigned int reloc_shndx,
- const elfcpp::Shdr<32, false>& shdr,
- Output_section* data_section,
- Relocatable_relocs* rr);
-#endif
-
-#ifdef HAVE_TARGET_32_BIG
-template
-Output_section*
-Layout::layout_reloc<32, true>(Sized_relobj_file<32, true>* object,
- unsigned int reloc_shndx,
- const elfcpp::Shdr<32, true>& shdr,
- Output_section* data_section,
- Relocatable_relocs* rr);
-#endif
-
-#ifdef HAVE_TARGET_64_LITTLE
-template
-Output_section*
-Layout::layout_reloc<64, false>(Sized_relobj_file<64, false>* object,
- unsigned int reloc_shndx,
- const elfcpp::Shdr<64, false>& shdr,
- Output_section* data_section,
- Relocatable_relocs* rr);
-#endif
-
-#ifdef HAVE_TARGET_64_BIG
-template
-Output_section*
-Layout::layout_reloc<64, true>(Sized_relobj_file<64, true>* object,
- unsigned int reloc_shndx,
- const elfcpp::Shdr<64, true>& shdr,
- Output_section* data_section,
- Relocatable_relocs* rr);
-#endif
-
-#ifdef HAVE_TARGET_32_LITTLE
-template
-void
-Layout::layout_group<32, false>(Symbol_table* symtab,
- Sized_relobj_file<32, false>* object,
- unsigned int,
- const char* group_section_name,
- const char* signature,
- const elfcpp::Shdr<32, false>& shdr,
- elfcpp::Elf_Word flags,
- std::vector<unsigned int>* shndxes);
-#endif
-
-#ifdef HAVE_TARGET_32_BIG
-template
-void
-Layout::layout_group<32, true>(Symbol_table* symtab,
- Sized_relobj_file<32, true>* object,
- unsigned int,
- const char* group_section_name,
- const char* signature,
- const elfcpp::Shdr<32, true>& shdr,
- elfcpp::Elf_Word flags,
- std::vector<unsigned int>* shndxes);
-#endif
-
-#ifdef HAVE_TARGET_64_LITTLE
-template
-void
-Layout::layout_group<64, false>(Symbol_table* symtab,
- Sized_relobj_file<64, false>* object,
- unsigned int,
- const char* group_section_name,
- const char* signature,
- const elfcpp::Shdr<64, false>& shdr,
- elfcpp::Elf_Word flags,
- std::vector<unsigned int>* shndxes);
-#endif
-
-#ifdef HAVE_TARGET_64_BIG
-template
-void
-Layout::layout_group<64, true>(Symbol_table* symtab,
- Sized_relobj_file<64, true>* object,
- unsigned int,
- const char* group_section_name,
- const char* signature,
- const elfcpp::Shdr<64, true>& shdr,
- elfcpp::Elf_Word flags,
- std::vector<unsigned int>* shndxes);
-#endif
-
-#ifdef HAVE_TARGET_32_LITTLE
-template
-Output_section*
-Layout::layout_eh_frame<32, false>(Sized_relobj_file<32, false>* object,
- const unsigned char* symbols,
- off_t symbols_size,
- const unsigned char* symbol_names,
- off_t symbol_names_size,
- unsigned int shndx,
- const elfcpp::Shdr<32, false>& shdr,
- unsigned int reloc_shndx,
- unsigned int reloc_type,
- off_t* off);
-#endif
-
-#ifdef HAVE_TARGET_32_BIG
-template
-Output_section*
-Layout::layout_eh_frame<32, true>(Sized_relobj_file<32, true>* object,
- const unsigned char* symbols,
- off_t symbols_size,
- const unsigned char* symbol_names,
- off_t symbol_names_size,
- unsigned int shndx,
- const elfcpp::Shdr<32, true>& shdr,
- unsigned int reloc_shndx,
- unsigned int reloc_type,
- off_t* off);
-#endif
-
-#ifdef HAVE_TARGET_64_LITTLE
-template
-Output_section*
-Layout::layout_eh_frame<64, false>(Sized_relobj_file<64, false>* object,
- const unsigned char* symbols,
- off_t symbols_size,
- const unsigned char* symbol_names,
- off_t symbol_names_size,
- unsigned int shndx,
- const elfcpp::Shdr<64, false>& shdr,
- unsigned int reloc_shndx,
- unsigned int reloc_type,
- off_t* off);
-#endif
-
-#ifdef HAVE_TARGET_64_BIG
-template
-Output_section*
-Layout::layout_eh_frame<64, true>(Sized_relobj_file<64, true>* object,
- const unsigned char* symbols,
- off_t symbols_size,
- const unsigned char* symbol_names,
- off_t symbol_names_size,
- unsigned int shndx,
- const elfcpp::Shdr<64, true>& shdr,
- unsigned int reloc_shndx,
- unsigned int reloc_type,
- off_t* off);
-#endif
-
-#ifdef HAVE_TARGET_32_LITTLE
-template
-void
-Layout::add_to_gdb_index(bool is_type_unit,
- Sized_relobj<32, false>* object,
- const unsigned char* symbols,
- off_t symbols_size,
- unsigned int shndx,
- unsigned int reloc_shndx,
- unsigned int reloc_type);
-#endif
-
-#ifdef HAVE_TARGET_32_BIG
-template
-void
-Layout::add_to_gdb_index(bool is_type_unit,
- Sized_relobj<32, true>* object,
- const unsigned char* symbols,
- off_t symbols_size,
- unsigned int shndx,
- unsigned int reloc_shndx,
- unsigned int reloc_type);
-#endif
-
-#ifdef HAVE_TARGET_64_LITTLE
-template
-void
-Layout::add_to_gdb_index(bool is_type_unit,
- Sized_relobj<64, false>* object,
- const unsigned char* symbols,
- off_t symbols_size,
- unsigned int shndx,
- unsigned int reloc_shndx,
- unsigned int reloc_type);
-#endif
-
-#ifdef HAVE_TARGET_64_BIG
-template
-void
-Layout::add_to_gdb_index(bool is_type_unit,
- Sized_relobj<64, true>* object,
- const unsigned char* symbols,
- off_t symbols_size,
- unsigned int shndx,
- unsigned int reloc_shndx,
- unsigned int reloc_type);
-#endif
-
-} // End namespace gold.
Index: sources/GNU/binutils/create-2.43.1-fname-in-error-messages-patch/file.list
===================================================================
--- sources/GNU/binutils/create-2.43.1-fname-in-error-messages-patch/file.list (revision 75)
+++ sources/GNU/binutils/create-2.43.1-fname-in-error-messages-patch/file.list (nonexistent)
@@ -1 +0,0 @@
-binutils-2.43.1/binutils/readelf.c
Index: sources/GNU/binutils/create-2.43.1-fname-in-error-messages-patch/create.patch.sh
===================================================================
--- sources/GNU/binutils/create-2.43.1-fname-in-error-messages-patch/create.patch.sh (revision 75)
+++ sources/GNU/binutils/create-2.43.1-fname-in-error-messages-patch/create.patch.sh (nonexistent)
@@ -1,15 +0,0 @@
-#!/bin/bash
-
-VERSION=2.43.1
-
-tar --files-from=file.list -xJvf ../binutils-$VERSION.tar.xz
-mv binutils-$VERSION binutils-$VERSION-orig
-
-cp -rf ./binutils-$VERSION-new ./binutils-$VERSION
-
-diff --unified -Nr binutils-$VERSION-orig binutils-$VERSION > binutils-$VERSION-fname-in-error-messages.patch
-
-mv binutils-$VERSION-fname-in-error-messages.patch ../patches
-
-rm -rf ./binutils-$VERSION
-rm -rf ./binutils-$VERSION-orig
Property changes on: sources/GNU/binutils/create-2.43.1-fname-in-error-messages-patch/create.patch.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: sources/GNU/binutils/create-2.43.1-fname-in-error-messages-patch/binutils-2.43.1-new/binutils/readelf.c
===================================================================
--- sources/GNU/binutils/create-2.43.1-fname-in-error-messages-patch/binutils-2.43.1-new/binutils/readelf.c (revision 75)
+++ sources/GNU/binutils/create-2.43.1-fname-in-error-messages-patch/binutils-2.43.1-new/binutils/readelf.c (nonexistent)
@@ -1,24288 +0,0 @@
-/* readelf.c -- display contents of an ELF format file
- Copyright (C) 1998-2024 Free Software Foundation, Inc.
-
- Originally developed by Eric Youngdale <eric@andante.jic.com>
- Modifications by Nick Clifton <nickc@redhat.com>
-
- This file is part of GNU Binutils.
-
- This program is free software; you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation; either version 3 of the License, or
- (at your option) any later version.
-
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program; if not, write to the Free Software
- Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA
- 02110-1301, USA. */
-
-/* The difference between readelf and objdump:
-
- Both programs are capable of displaying the contents of ELF format files,
- so why does the binutils project have two file dumpers ?
-
- The reason is that objdump sees an ELF file through a BFD filter of the
- world; if BFD has a bug where, say, it disagrees about a machine constant
- in e_flags, then the odds are good that it will remain internally
- consistent. The linker sees it the BFD way, objdump sees it the BFD way,
- GAS sees it the BFD way. There was need for a tool to go find out what
- the file actually says.
-
- This is why the readelf program does not link against the BFD library - it
- exists as an independent program to help verify the correct working of BFD.
-
- There is also the case that readelf can provide more information about an
- ELF file than is provided by objdump. In particular it can display DWARF
- debugging information which (at the moment) objdump cannot. */
-
-#include "sysdep.h"
-#include <assert.h>
-#include <time.h>
-#include <zlib.h>
-#ifdef HAVE_ZSTD
-#include <zstd.h>
-#endif
-#include <wchar.h>
-
-#if defined HAVE_MSGPACK
-#include <msgpack.h>
-#endif
-
-/* Define BFD64 here, even if our default architecture is 32 bit ELF
- as this will allow us to read in and parse 64bit and 32bit ELF files. */
-#define BFD64
-
-#include "bfd.h"
-#include "bucomm.h"
-#include "elfcomm.h"
-#include "demanguse.h"
-#include "dwarf.h"
-#include "ctf-api.h"
-#include "sframe-api.h"
-#include "demangle.h"
-
-#include "elf/common.h"
-#include "elf/external.h"
-#include "elf/internal.h"
-
-
-/* Included here, before RELOC_MACROS_GEN_FUNC is defined, so that
- we can obtain the H8 reloc numbers. We need these for the
- get_reloc_size() function. We include h8.h again after defining
- RELOC_MACROS_GEN_FUNC so that we get the naming function as well. */
-
-#include "elf/h8.h"
-#undef _ELF_H8_H
-
-/* Undo the effects of #including reloc-macros.h. */
-
-#undef START_RELOC_NUMBERS
-#undef RELOC_NUMBER
-#undef FAKE_RELOC
-#undef EMPTY_RELOC
-#undef END_RELOC_NUMBERS
-#undef _RELOC_MACROS_H
-
-/* The following headers use the elf/reloc-macros.h file to
- automatically generate relocation recognition functions
- such as elf_mips_reloc_type() */
-
-#define RELOC_MACROS_GEN_FUNC
-
-#include "elf/aarch64.h"
-#include "elf/alpha.h"
-#include "elf/amdgpu.h"
-#include "elf/arc.h"
-#include "elf/arm.h"
-#include "elf/avr.h"
-#include "elf/bfin.h"
-#include "elf/cr16.h"
-#include "elf/cris.h"
-#include "elf/crx.h"
-#include "elf/csky.h"
-#include "elf/d10v.h"
-#include "elf/d30v.h"
-#include "elf/dlx.h"
-#include "elf/bpf.h"
-#include "elf/epiphany.h"
-#include "elf/fr30.h"
-#include "elf/frv.h"
-#include "elf/ft32.h"
-#include "elf/h8.h"
-#include "elf/hppa.h"
-#include "elf/i386.h"
-#include "elf/i370.h"
-#include "elf/i860.h"
-#include "elf/i960.h"
-#include "elf/ia64.h"
-#include "elf/ip2k.h"
-#include "elf/kvx.h"
-#include "elf/lm32.h"
-#include "elf/iq2000.h"
-#include "elf/m32c.h"
-#include "elf/m32r.h"
-#include "elf/m68k.h"
-#include "elf/m68hc11.h"
-#include "elf/s12z.h"
-#include "elf/mcore.h"
-#include "elf/mep.h"
-#include "elf/metag.h"
-#include "elf/microblaze.h"
-#include "elf/mips.h"
-#include "elf/mmix.h"
-#include "elf/mn10200.h"
-#include "elf/mn10300.h"
-#include "elf/moxie.h"
-#include "elf/mt.h"
-#include "elf/msp430.h"
-#include "elf/nds32.h"
-#include "elf/nfp.h"
-#include "elf/nios2.h"
-#include "elf/or1k.h"
-#include "elf/pj.h"
-#include "elf/ppc.h"
-#include "elf/ppc64.h"
-#include "elf/pru.h"
-#include "elf/riscv.h"
-#include "elf/rl78.h"
-#include "elf/rx.h"
-#include "elf/s390.h"
-#include "elf/score.h"
-#include "elf/sh.h"
-#include "elf/sparc.h"
-#include "elf/spu.h"
-#include "elf/tic6x.h"
-#include "elf/tilegx.h"
-#include "elf/tilepro.h"
-#include "elf/v850.h"
-#include "elf/vax.h"
-#include "elf/visium.h"
-#include "elf/wasm32.h"
-#include "elf/x86-64.h"
-#include "elf/xgate.h"
-#include "elf/xstormy16.h"
-#include "elf/xtensa.h"
-#include "elf/z80.h"
-#include "elf/loongarch.h"
-#include "elf/bpf.h"
-
-#include "getopt.h"
-#include "libiberty.h"
-#include "safe-ctype.h"
-#include "filenames.h"
-
-#ifndef offsetof
-#define offsetof(TYPE, MEMBER) ((size_t) &(((TYPE *) 0)->MEMBER))
-#endif
-
-typedef struct elf_section_list
-{
- Elf_Internal_Shdr * hdr;
- struct elf_section_list * next;
-} elf_section_list;
-
-/* Flag bits indicating particular types of dump. */
-#define HEX_DUMP (1 << 0) /* The -x command line switch. */
-#ifdef SUPPORT_DISASSEMBLY
-#define DISASS_DUMP (1 << 1) /* The -i command line switch. */
-#endif
-#define DEBUG_DUMP (1 << 2) /* The -w command line switch. */
-#define STRING_DUMP (1 << 3) /* The -p command line switch. */
-#define RELOC_DUMP (1 << 4) /* The -R command line switch. */
-#define CTF_DUMP (1 << 5) /* The --ctf command line switch. */
-#define SFRAME_DUMP (1 << 6) /* The --sframe command line switch. */
-#define AUTO_DUMP (1 << 7) /* The -j command line switch. */
-
-typedef unsigned char dump_type;
-
-/* A linked list of the section names for which dumps were requested. */
-struct dump_list_entry
-{
- char * name;
- dump_type type;
- struct dump_list_entry * next;
-};
-
-/* A dynamic array of flags indicating for which sections a dump
- has been requested via command line switches. */
-struct dump_data
-{
- dump_type * dump_sects;
- unsigned int num_dump_sects;
-};
-
-static struct dump_data cmdline;
-
-static struct dump_list_entry * dump_sects_byname;
-
-char * program_name = "readelf";
-
-static bool show_name = false;
-static bool do_dynamic = false;
-static bool do_syms = false;
-static bool do_dyn_syms = false;
-static bool do_lto_syms = false;
-static bool do_reloc = false;
-static bool do_sections = false;
-static bool do_section_groups = false;
-static bool do_section_details = false;
-static bool do_segments = false;
-static bool do_unwind = false;
-static bool do_using_dynamic = false;
-static bool do_header = false;
-static bool do_dump = false;
-static bool do_version = false;
-static bool do_histogram = false;
-static bool do_debugging = false;
-static bool do_ctf = false;
-static bool do_sframe = false;
-static bool do_arch = false;
-static bool do_notes = false;
-static bool do_archive_index = false;
-static bool check_all = false;
-static bool is_32bit_elf = false;
-static bool decompress_dumps = false;
-static bool do_not_show_symbol_truncation = false;
-static bool do_demangle = false; /* Pretty print C++ symbol names. */
-static bool process_links = false;
-static bool dump_any_debugging = false;
-static bool extra_sym_info = false;
-static int demangle_flags = DMGL_ANSI | DMGL_PARAMS;
-static int sym_base = 0;
-
-static char *dump_ctf_parent_name;
-static char *dump_ctf_symtab_name;
-static char *dump_ctf_strtab_name;
-
-struct group_list
-{
- struct group_list * next;
- unsigned int section_index;
-};
-
-struct group
-{
- struct group_list * root;
- unsigned int group_index;
-};
-
-typedef struct filedata
-{
- const char * file_name;
- bool is_separate;
- FILE * handle;
- uint64_t file_size;
- Elf_Internal_Ehdr file_header;
- uint64_t archive_file_offset;
- uint64_t archive_file_size;
- /* Everything below this point is cleared out by free_filedata. */
- Elf_Internal_Shdr * section_headers;
- Elf_Internal_Phdr * program_headers;
- char * string_table;
- uint64_t string_table_length;
- uint64_t dynamic_addr;
- uint64_t dynamic_size;
- uint64_t dynamic_nent;
- Elf_Internal_Dyn * dynamic_section;
- Elf_Internal_Shdr * dynamic_strtab_section;
- char * dynamic_strings;
- uint64_t dynamic_strings_length;
- Elf_Internal_Shdr * dynamic_symtab_section;
- uint64_t num_dynamic_syms;
- Elf_Internal_Sym * dynamic_symbols;
- uint64_t version_info[16];
- unsigned int dynamic_syminfo_nent;
- Elf_Internal_Syminfo * dynamic_syminfo;
- uint64_t dynamic_syminfo_offset;
- uint64_t nbuckets;
- uint64_t nchains;
- uint64_t * buckets;
- uint64_t * chains;
- uint64_t ngnubuckets;
- uint64_t ngnuchains;
- uint64_t * gnubuckets;
- uint64_t * gnuchains;
- uint64_t * mipsxlat;
- uint64_t gnusymidx;
- char * program_interpreter;
- uint64_t dynamic_info[DT_RELRENT + 1];
- uint64_t dynamic_info_DT_GNU_HASH;
- uint64_t dynamic_info_DT_MIPS_XHASH;
- elf_section_list * symtab_shndx_list;
- size_t group_count;
- struct group * section_groups;
- struct group ** section_headers_groups;
- /* A dynamic array of flags indicating for which sections a dump of
- some kind has been requested. It is reset on a per-object file
- basis and then initialised from the cmdline_dump_sects array,
- the results of interpreting the -w switch, and the
- dump_sects_byname list. */
- struct dump_data dump;
-} Filedata;
-
-/* How to print a vma value. */
-typedef enum print_mode
-{
- HEX,
- HEX_5,
- DEC,
- DEC_5,
- UNSIGNED,
- UNSIGNED_5,
- PREFIX_HEX,
- PREFIX_HEX_5,
- FULL_HEX,
- LONG_HEX,
- ZERO_HEX,
- OCTAL,
- OCTAL_5
-}
-print_mode;
-
-typedef enum unicode_display_type
-{
- unicode_default = 0,
- unicode_locale,
- unicode_escape,
- unicode_hex,
- unicode_highlight,
- unicode_invalid
-} unicode_display_type;
-
-static unicode_display_type unicode_display = unicode_default;
-
-typedef enum
-{
- reltype_unknown,
- reltype_rel,
- reltype_rela,
- reltype_relr
-} relocation_type;
-
-/* Versioned symbol info. */
-enum versioned_symbol_info
-{
- symbol_undefined,
- symbol_hidden,
- symbol_public
-};
-
-static int
-fseek64 (FILE *stream, int64_t offset, int whence)
-{
-#if defined (HAVE_FSEEKO64)
- off64_t o = offset;
- if (o != offset)
- {
- errno = EINVAL;
- return -1;
- }
- return fseeko64 (stream, o, whence);
-#elif defined (HAVE_FSEEKO)
- off_t o = offset;
- if (o != offset)
- {
- errno = EINVAL;
- return -1;
- }
- return fseeko (stream, o, whence);
-#else
- long o = offset;
- if (o != offset)
- {
- errno = EINVAL;
- return -1;
- }
- return fseek (stream, o, whence);
-#endif
-}
-
-static const char * get_symbol_version_string
- (Filedata *, bool, const char *, size_t, unsigned,
- Elf_Internal_Sym *, enum versioned_symbol_info *, unsigned short *);
-
-static bool process_notes_at
- (Filedata *, Elf_Internal_Shdr *, uint64_t, uint64_t, uint64_t);
-
-#define UNKNOWN -1
-
-static inline const char *
-section_name (const Filedata *filedata, const Elf_Internal_Shdr *hdr)
-{
- return filedata->string_table + hdr->sh_name;
-}
-
-static inline bool
-section_name_valid (const Filedata *filedata, const Elf_Internal_Shdr *hdr)
-{
- return (filedata != NULL
- && hdr != NULL
- && filedata->string_table != NULL
- && hdr->sh_name < filedata->string_table_length);
-}
-
-/* Returns true if the given index is real/valid. Note: "real" here
- means "references a real section in the section header" and not
- "is a valid section index as per the ELF standard". */
-
-static inline bool
-section_index_real (const Filedata *filedata, unsigned int ndx)
-{
- return (filedata != NULL
- && filedata->section_headers != NULL
- && ndx < filedata->file_header.e_shnum
- && ndx > 0);
-}
-
-#define DT_VERSIONTAGIDX(tag) (DT_VERNEEDNUM - (tag)) /* Reverse order! */
-
-static inline bool
-valid_symbol_name (const char *strtab, size_t strtab_size, uint64_t offset)
-{
- return strtab != NULL && offset < strtab_size;
-}
-
-static inline bool
-valid_dynamic_name (const Filedata *filedata, uint64_t offset)
-{
- return valid_symbol_name (filedata->dynamic_strings,
- filedata->dynamic_strings_length, offset);
-}
-
-/* GET_DYNAMIC_NAME asssumes that VALID_DYNAMIC_NAME has
- already been called and verified that the string exists. */
-static inline const char *
-get_dynamic_name (const Filedata *filedata, size_t offset)
-{
- return filedata->dynamic_strings + offset;
-}
-
-#define REMOVE_ARCH_BITS(ADDR) \
- do \
- { \
- if (filedata->file_header.e_machine == EM_ARM) \
- (ADDR) &= ~1; \
- } \
- while (0)
-
-/* Get the correct GNU hash section name. */
-#define GNU_HASH_SECTION_NAME(filedata) \
- filedata->dynamic_info_DT_MIPS_XHASH ? ".MIPS.xhash" : ".gnu.hash"
-
-/* Retrieve NMEMB structures, each SIZE bytes long from FILEDATA starting at
- OFFSET + the offset of the current archive member, if we are examining an
- archive. Put the retrieved data into VAR, if it is not NULL. Otherwise
- allocate a buffer using malloc and fill that. In either case return the
- pointer to the start of the retrieved data or NULL if something went wrong.
- If something does go wrong and REASON is not NULL then emit an error
- message using REASON as part of the context. */
-
-static void *
-get_data (void *var,
- Filedata *filedata,
- uint64_t offset,
- uint64_t size,
- uint64_t nmemb,
- const char *reason)
-{
- void * mvar;
- uint64_t amt = size * nmemb;
-
- if (size == 0 || nmemb == 0)
- return NULL;
-
- /* If size_t is smaller than uint64_t, eg because you are building
- on a 32-bit host, then make sure that when the sizes are cast to
- size_t no information is lost. */
- if ((size_t) size != size
- || (size_t) nmemb != nmemb
- || (size_t) amt != amt
- || amt / size != nmemb
- || (size_t) amt + 1 == 0)
- {
- if (reason)
- error (_("Size overflow prevents reading %" PRIu64
- " elements of size %" PRIu64 " for %s\n"),
- nmemb, size, reason);
- return NULL;
- }
-
- /* Be kind to memory checkers (eg valgrind, address sanitizer) by not
- attempting to allocate memory when the read is bound to fail. */
- if (filedata->archive_file_offset > filedata->file_size
- || offset > filedata->file_size - filedata->archive_file_offset
- || amt > filedata->file_size - filedata->archive_file_offset - offset)
- {
- if (reason)
- error (_("Reading %" PRIu64 " bytes extends past end of file for %s\n"),
- amt, reason);
- return NULL;
- }
-
- if (fseek64 (filedata->handle, filedata->archive_file_offset + offset,
- SEEK_SET))
- {
- if (reason)
- error (_("Unable to seek to %#" PRIx64 " for %s\n"),
- filedata->archive_file_offset + offset, reason);
- return NULL;
- }
-
- mvar = var;
- if (mvar == NULL)
- {
- /* + 1 so that we can '\0' terminate invalid string table sections. */
- mvar = malloc ((size_t) amt + 1);
-
- if (mvar == NULL)
- {
- if (reason)
- error (_("Out of memory allocating %" PRIu64 " bytes for %s\n"),
- amt, reason);
- return NULL;
- }
-
- ((char *) mvar)[amt] = '\0';
- }
-
- if (fread (mvar, (size_t) size, (size_t) nmemb, filedata->handle) != nmemb)
- {
- if (reason)
- error (_("Unable to read in %" PRIu64 " bytes of %s\n"),
- amt, reason);
- if (mvar != var)
- free (mvar);
- return NULL;
- }
-
- return mvar;
-}
-
-/* Print a VMA value in the MODE specified.
- Returns the number of characters displayed. */
-
-static unsigned int
-print_vma (uint64_t vma, print_mode mode)
-{
- unsigned int nc = 0;
-
- switch (mode)
- {
- case FULL_HEX:
- nc = printf ("0x");
- /* Fall through. */
- case LONG_HEX:
- if (!is_32bit_elf)
- return nc + printf ("%16.16" PRIx64, vma);
- return nc + printf ("%8.8" PRIx64, vma);
-
- case ZERO_HEX:
- if (is_32bit_elf)
- return printf ("%08" PRIx64, vma);
- return printf ("%016" PRIx64, vma);
-
- case DEC_5:
- if (vma <= 99999)
- return printf ("%5" PRId64, vma);
- /* Fall through. */
- case PREFIX_HEX:
- nc = printf ("0x");
- /* Fall through. */
- case HEX:
- return nc + printf ("%" PRIx64, vma);
-
- case PREFIX_HEX_5:
- nc = printf ("0x");
- /* Fall through. */
- case HEX_5:
- return nc + printf ("%05" PRIx64, vma);
-
- case DEC:
- return printf ("%" PRId64, vma);
-
- case UNSIGNED:
- return printf ("%" PRIu64, vma);
-
- case UNSIGNED_5:
- return printf ("%5" PRIu64, vma);
-
- case OCTAL:
- return printf ("%" PRIo64, vma);
-
- case OCTAL_5:
- return printf ("%5" PRIo64, vma);
-
- default:
- /* FIXME: Report unrecognised mode ? */
- return 0;
- }
-}
-
-
-/* Display a symbol on stdout. Handles the display of control characters and
- multibye characters (assuming the host environment supports them).
-
- Display at most abs(WIDTH) characters, truncating as necessary,
- unless do_wide or extra_sym_info is true.
-
- If truncation will happen and do_not_show_symbol_truncation is FALSE then display
- abs(WIDTH) - 5 characters followed by "[...]".
-
- If WIDTH is negative then ensure that the output is at least (- WIDTH) characters,
- padding as necessary.
-
- Returns the number of emitted characters. */
-
-static unsigned int
-print_symbol_name (signed int width, const char * symbol)
-{
- bool extra_padding = false;
- bool do_dots = false;
- signed int num_printed = 0;
-#ifdef HAVE_MBSTATE_T
- mbstate_t state;
-#endif
- unsigned int width_remaining;
- const void * alloced_symbol = NULL;
-
- if (width < 0)
- {
- /* Keep the width positive. This helps the code below. */
- width = - width;
- extra_padding = true;
- }
- else if (width == 0)
- return 0;
-
- if (do_wide || extra_sym_info)
- /* Set the remaining width to a very large value.
- This simplifies the code below. */
- width_remaining = INT_MAX;
- else
- {
- width_remaining = width;
-
- if (! do_not_show_symbol_truncation
- && (int) strlen (symbol) > width)
- {
- width_remaining -= 5;
- if ((int) width_remaining < 0)
- width_remaining = 0;
- do_dots = true;
- }
- }
-
-#ifdef HAVE_MBSTATE_T
- /* Initialise the multibyte conversion state. */
- memset (& state, 0, sizeof (state));
-#endif
-
- if (do_demangle && *symbol)
- {
- const char * res = cplus_demangle (symbol, demangle_flags);
-
- if (res != NULL)
- alloced_symbol = symbol = res;
- }
-
- while (width_remaining)
- {
- size_t n;
- const char c = *symbol++;
-
- if (c == 0)
- break;
-
- if (ISPRINT (c))
- {
- putchar (c);
- width_remaining --;
- num_printed ++;
- }
- else if (ISCNTRL (c))
- {
- /* Do not print control characters directly as they can affect terminal
- settings. Such characters usually appear in the names generated
- by the assembler for local labels. */
-
- if (width_remaining < 2)
- break;
-
- printf ("^%c", c + 0x40);
- width_remaining -= 2;
- num_printed += 2;
- }
- else if (c == 0x7f)
- {
- if (width_remaining < 5)
- break;
- printf ("<DEL>");
- width_remaining -= 5;
- num_printed += 5;
- }
- else if (unicode_display != unicode_locale
- && unicode_display != unicode_default)
- {
- /* Display unicode characters as something else. */
- unsigned char bytes[4];
- bool is_utf8;
- unsigned int nbytes;
-
- bytes[0] = c;
-
- if (bytes[0] < 0xc0)
- {
- nbytes = 1;
- is_utf8 = false;
- }
- else
- {
- bytes[1] = *symbol++;
-
- if ((bytes[1] & 0xc0) != 0x80)
- {
- is_utf8 = false;
- /* Do not consume this character. It may only
- be the first byte in the sequence that was
- corrupt. */
- --symbol;
- nbytes = 1;
- }
- else if ((bytes[0] & 0x20) == 0)
- {
- is_utf8 = true;
- nbytes = 2;
- }
- else
- {
- bytes[2] = *symbol++;
-
- if ((bytes[2] & 0xc0) != 0x80)
- {
- is_utf8 = false;
- symbol -= 2;
- nbytes = 1;
- }
- else if ((bytes[0] & 0x10) == 0)
- {
- is_utf8 = true;
- nbytes = 3;
- }
- else
- {
- bytes[3] = *symbol++;
-
- nbytes = 4;
-
- if ((bytes[3] & 0xc0) != 0x80)
- {
- is_utf8 = false;
- symbol -= 3;
- nbytes = 1;
- }
- else
- is_utf8 = true;
- }
- }
- }
-
- if (unicode_display == unicode_invalid)
- is_utf8 = false;
-
- if (unicode_display == unicode_hex || ! is_utf8)
- {
- unsigned int i;
-
- if (width_remaining < (nbytes * 2) + 2)
- break;
-
- putchar (is_utf8 ? '<' : '{');
- printf ("0x");
- for (i = 0; i < nbytes; i++)
- printf ("%02x", bytes[i]);
- putchar (is_utf8 ? '>' : '}');
- }
- else
- {
- if (unicode_display == unicode_highlight && isatty (1))
- printf ("\x1B[31;47m"); /* Red. */
-
- switch (nbytes)
- {
- case 2:
- if (width_remaining < 6)
- break;
- printf ("\\u%02x%02x",
- (bytes[0] & 0x1c) >> 2,
- ((bytes[0] & 0x03) << 6) | (bytes[1] & 0x3f));
- break;
- case 3:
- if (width_remaining < 6)
- break;
- printf ("\\u%02x%02x",
- ((bytes[0] & 0x0f) << 4) | ((bytes[1] & 0x3c) >> 2),
- ((bytes[1] & 0x03) << 6) | (bytes[2] & 0x3f));
- break;
- case 4:
- if (width_remaining < 8)
- break;
- printf ("\\u%02x%02x%02x",
- ((bytes[0] & 0x07) << 6) | ((bytes[1] & 0x3c) >> 2),
- ((bytes[1] & 0x03) << 6) | ((bytes[2] & 0x3c) >> 2),
- ((bytes[2] & 0x03) << 6) | (bytes[3] & 0x3f));
-
- break;
- default:
- /* URG. */
- break;
- }
-
- if (unicode_display == unicode_highlight && isatty (1))
- printf ("\033[0m"); /* Default colour. */
- }
-
- if (bytes[nbytes - 1] == 0)
- break;
- }
- else
- {
-#ifdef HAVE_MBSTATE_T
- wchar_t w;
-#endif
- /* Let printf do the hard work of displaying multibyte characters. */
- printf ("%.1s", symbol - 1);
- width_remaining --;
- num_printed ++;
-
-#ifdef HAVE_MBSTATE_T
- /* Try to find out how many bytes made up the character that was
- just printed. Advance the symbol pointer past the bytes that
- were displayed. */
- n = mbrtowc (& w, symbol - 1, MB_CUR_MAX, & state);
-#else
- n = 1;
-#endif
- if (n != (size_t) -1 && n != (size_t) -2 && n > 0)
- symbol += (n - 1);
- }
- }
-
- if (do_dots)
- num_printed += printf ("[...]");
-
- if (extra_padding && num_printed < width)
- {
- /* Fill in the remaining spaces. */
- printf ("%-*s", width - num_printed, " ");
- num_printed = width;
- }
-
- free ((void *) alloced_symbol);
- return num_printed;
-}
-
-/* Returns a pointer to a static buffer containing a printable version of
- the given section's name. Like print_symbol, except that it does not try
- to print multibyte characters, it just interprets them as hex values. */
-
-static const char *
-printable_section_name (Filedata * filedata, const Elf_Internal_Shdr * sec)
-{
-#define NUM_SEC_NAME_BUFS 5
-#define MAX_PRINT_SEC_NAME_LEN 256
-
- static int sec_name_buf_index = 0;
- /* We use a rotating array of static buffers, so that multiple successive calls
- to printable_section_name() will still work. eg when used in a printf. */
- static char sec_name_buf [NUM_SEC_NAME_BUFS][MAX_PRINT_SEC_NAME_LEN + 1];
-
- const char * name;
- char * buf;
- char * buf_start;
- char c;
- unsigned int remaining = MAX_PRINT_SEC_NAME_LEN;
-
- /* Validate the input parameters. */
- if (filedata == NULL)
- return _("<internal error>");
- if (sec == NULL)
- return _("<none>");
- if (filedata->string_table == NULL)
- return _("<no-strings>");
- if (sec->sh_name >= filedata->string_table_length)
- return _("<corrupt>");
-
- /* Select a buffer to use. */
- buf_start = buf = sec_name_buf[sec_name_buf_index];
- if (++sec_name_buf_index >= NUM_SEC_NAME_BUFS)
- sec_name_buf_index = 0;
-
- name = section_name (filedata, sec);
-
- while ((c = * name ++) != 0)
- {
- if (ISCNTRL (c))
- {
- if (remaining < 2)
- break;
-
- * buf ++ = '^';
- * buf ++ = c + 0x40;
- remaining -= 2;
- }
- else if (ISPRINT (c))
- {
- * buf ++ = c;
- remaining -= 1;
- }
- else
- {
- static char hex[17] = "0123456789ABCDEF";
-
- if (remaining < 4)
- break;
- * buf ++ = '<';
- * buf ++ = hex[(c & 0xf0) >> 4];
- * buf ++ = hex[c & 0x0f];
- * buf ++ = '>';
- remaining -= 4;
- }
-
- if (remaining == 0)
- break;
- }
-
- * buf = 0;
- return buf_start;
-}
-
-/* Return TRUE if the current file is for IA-64 machine and OpenVMS ABI.
- This OS has so many departures from the ELF standard that we test it at
- many places. */
-
-static inline bool
-is_ia64_vms (Filedata * filedata)
-{
- return filedata->file_header.e_machine == EM_IA_64
- && filedata->file_header.e_ident[EI_OSABI] == ELFOSABI_OPENVMS;
-}
-
-static const char *
-printable_section_name_from_index (Filedata * filedata,
- size_t ndx,
- bool * is_special)
-{
- if (is_special != NULL)
- * is_special = true;
-
- switch (ndx)
- {
- case SHN_UNDEF: return "UND";
- case SHN_ABS: return "ABS";
- case SHN_COMMON: return "COM";
- break;
- }
-
- if (filedata != NULL)
- {
- switch (filedata->file_header.e_machine)
- {
- case EM_MIPS:
- if (ndx == SHN_MIPS_SCOMMON)
- return "SCOMMON";
- if (ndx == SHN_MIPS_SUNDEFINED)
- return "SUNDEF";
- break;
-
- case EM_TI_C6000:
- if (ndx == SHN_TIC6X_SCOMMON)
- return "SCOM";
- break;
-
- case EM_X86_64:
- case EM_L1OM:
- case EM_K1OM:
- if (ndx == SHN_X86_64_LCOMMON)
- return "LARGE_COM";
- break;
-
- case EM_IA_64:
- if (filedata->file_header.e_ident[EI_OSABI] == ELFOSABI_HPUX
- && ndx == SHN_IA_64_ANSI_COMMON)
- return "ANSI_COM";
-
- if (is_ia64_vms (filedata) && ndx == SHN_IA_64_VMS_SYMVEC)
- return "VMS_SYMVEC";
- break;
-
- default:
- break;
- }
-
- if (filedata->section_headers != NULL
- && ndx < filedata->file_header.e_shnum)
- {
- const char * res;
-
- res = printable_section_name (filedata, filedata->section_headers + ndx);
- if (is_special != NULL)
- * is_special = (res[0] == '<');
-
- return res;
- }
- }
-
- static char name_buf[40];
- unsigned int short_ndx = (unsigned int) (ndx & 0xffff);
-
- if (ndx >= SHN_LOPROC && ndx <= SHN_HIPROC)
- sprintf (name_buf, "PRC[0x%04x]", short_ndx);
- else if (ndx >= SHN_LOOS && ndx <= SHN_HIOS)
- sprintf (name_buf, "OS [0x%04x]", short_ndx);
- else if (ndx >= SHN_LORESERVE)
- sprintf (name_buf, "RSV[0x%04x]", short_ndx);
- else if (filedata->file_header.e_shnum != 0
- && ndx >= filedata->file_header.e_shnum)
- sprintf (name_buf, _("BAD[0x%lx]"), (long) ndx);
- else
- sprintf (name_buf, "<section 0x%lx>", (long) ndx);
-
- return name_buf;
-}
-
-/* Return a pointer to section NAME, or NULL if no such section exists. */
-
-static Elf_Internal_Shdr *
-find_section (Filedata * filedata, const char * name)
-{
- unsigned int i;
-
- if (filedata->section_headers == NULL)
- return NULL;
-
- for (i = 0; i < filedata->file_header.e_shnum; i++)
- if (section_name_valid (filedata, filedata->section_headers + i)
- && streq (section_name (filedata, filedata->section_headers + i),
- name))
- return filedata->section_headers + i;
-
- return NULL;
-}
-
-/* Return a pointer to a section containing ADDR, or NULL if no such
- section exists. */
-
-static Elf_Internal_Shdr *
-find_section_by_address (Filedata * filedata, uint64_t addr)
-{
- unsigned int i;
-
- if (filedata->section_headers == NULL)
- return NULL;
-
- for (i = 0; i < filedata->file_header.e_shnum; i++)
- {
- Elf_Internal_Shdr *sec = filedata->section_headers + i;
-
- if (addr >= sec->sh_addr && addr < sec->sh_addr + sec->sh_size)
- return sec;
- }
-
- return NULL;
-}
-
-static Elf_Internal_Shdr *
-find_section_by_type (Filedata * filedata, unsigned int type)
-{
- unsigned int i;
-
- if (filedata->section_headers == NULL)
- return NULL;
-
- for (i = 0; i < filedata->file_header.e_shnum; i++)
- {
- Elf_Internal_Shdr *sec = filedata->section_headers + i;
-
- if (sec->sh_type == type)
- return sec;
- }
-
- return NULL;
-}
-
-static Elf_Internal_Shdr *
-find_section_by_name (Filedata * filedata, const char * name)
-{
- unsigned int i;
-
- if (filedata->section_headers == NULL || filedata->string_table_length == 0)
- return NULL;
-
- for (i = 0; i < filedata->file_header.e_shnum; i++)
- {
- Elf_Internal_Shdr *sec = filedata->section_headers + i;
-
- if (sec->sh_name < filedata->string_table_length
- && streq (name, filedata->string_table + sec->sh_name))
- return sec;
- }
-
- return NULL;
-}
-
-/* Return a pointer to section NAME, or NULL if no such section exists,
- restricted to the list of sections given in SET. */
-
-static Elf_Internal_Shdr *
-find_section_in_set (Filedata * filedata, const char * name, unsigned int * set)
-{
- unsigned int i;
-
- if (filedata->section_headers == NULL)
- return NULL;
-
- if (set != NULL)
- {
- while ((i = *set++) > 0)
- {
- /* See PR 21156 for a reproducer. */
- if (i >= filedata->file_header.e_shnum)
- continue; /* FIXME: Should we issue an error message ? */
-
- if (section_name_valid (filedata, filedata->section_headers + i)
- && streq (section_name (filedata, filedata->section_headers + i),
- name))
- return filedata->section_headers + i;
- }
- }
-
- return find_section (filedata, name);
-}
-
-/* Guess the relocation size commonly used by the specific machines. */
-
-static bool
-guess_is_rela (unsigned int e_machine)
-{
- switch (e_machine)
- {
- /* Targets that use REL relocations. */
- case EM_386:
- case EM_IAMCU:
- case EM_960:
- case EM_ARM:
- case EM_D10V:
- case EM_CYGNUS_D10V:
- case EM_DLX:
- case EM_MIPS:
- case EM_MIPS_RS3_LE:
- case EM_CYGNUS_M32R:
- case EM_SCORE:
- case EM_XGATE:
- case EM_NFP:
- case EM_BPF:
- return false;
-
- /* Targets that use RELA relocations. */
- case EM_68K:
- case EM_860:
- case EM_AARCH64:
- case EM_ADAPTEVA_EPIPHANY:
- case EM_ALPHA:
- case EM_ALTERA_NIOS2:
- case EM_ARC:
- case EM_ARC_COMPACT:
- case EM_ARC_COMPACT2:
- case EM_ARC_COMPACT3:
- case EM_ARC_COMPACT3_64:
- case EM_AVR:
- case EM_AVR_OLD:
- case EM_BLACKFIN:
- case EM_CR16:
- case EM_CRIS:
- case EM_CRX:
- case EM_CSKY:
- case EM_D30V:
- case EM_CYGNUS_D30V:
- case EM_FR30:
- case EM_FT32:
- case EM_CYGNUS_FR30:
- case EM_CYGNUS_FRV:
- case EM_H8S:
- case EM_H8_300:
- case EM_H8_300H:
- case EM_IA_64:
- case EM_IP2K:
- case EM_IP2K_OLD:
- case EM_IQ2000:
- case EM_KVX:
- case EM_LATTICEMICO32:
- case EM_M32C_OLD:
- case EM_M32C:
- case EM_M32R:
- case EM_MCORE:
- case EM_CYGNUS_MEP:
- case EM_METAG:
- case EM_MMIX:
- case EM_MN10200:
- case EM_CYGNUS_MN10200:
- case EM_MN10300:
- case EM_CYGNUS_MN10300:
- case EM_MOXIE:
- case EM_MSP430:
- case EM_MSP430_OLD:
- case EM_MT:
- case EM_NDS32:
- case EM_NIOS32:
- case EM_OR1K:
- case EM_PPC64:
- case EM_PPC:
- case EM_TI_PRU:
- case EM_RISCV:
- case EM_RL78:
- case EM_RX:
- case EM_S390:
- case EM_S390_OLD:
- case EM_SH:
- case EM_SPARC:
- case EM_SPARC32PLUS:
- case EM_SPARCV9:
- case EM_SPU:
- case EM_TI_C6000:
- case EM_TILEGX:
- case EM_TILEPRO:
- case EM_V800:
- case EM_V850:
- case EM_CYGNUS_V850:
- case EM_VAX:
- case EM_VISIUM:
- case EM_X86_64:
- case EM_L1OM:
- case EM_K1OM:
- case EM_XSTORMY16:
- case EM_XTENSA:
- case EM_XTENSA_OLD:
- case EM_MICROBLAZE:
- case EM_MICROBLAZE_OLD:
- case EM_WEBASSEMBLY:
- return true;
-
- case EM_68HC05:
- case EM_68HC08:
- case EM_68HC11:
- case EM_68HC16:
- case EM_FX66:
- case EM_ME16:
- case EM_MMA:
- case EM_NCPU:
- case EM_NDR1:
- case EM_PCP:
- case EM_ST100:
- case EM_ST19:
- case EM_ST7:
- case EM_ST9PLUS:
- case EM_STARCORE:
- case EM_SVX:
- case EM_TINYJ:
- default:
- warn (_("Don't know about relocations on this machine architecture\n"));
- return false;
- }
-}
-
-/* Load RELA type relocations from FILEDATA at REL_OFFSET extending for REL_SIZE bytes.
- Returns TRUE upon success, FALSE otherwise. If successful then a
- pointer to a malloc'ed buffer containing the relocs is placed in *RELASP,
- and the number of relocs loaded is placed in *NRELASP. It is the caller's
- responsibility to free the allocated buffer. */
-
-static bool
-slurp_rela_relocs (Filedata *filedata,
- uint64_t rel_offset,
- uint64_t rel_size,
- Elf_Internal_Rela **relasp,
- uint64_t *nrelasp)
-{
- Elf_Internal_Rela * relas;
- uint64_t nrelas;
- unsigned int i;
-
- if (is_32bit_elf)
- {
- Elf32_External_Rela * erelas;
-
- erelas = (Elf32_External_Rela *) get_data (NULL, filedata, rel_offset, 1,
- rel_size, _("32-bit relocation data"));
- if (!erelas)
- return false;
-
- nrelas = rel_size / sizeof (Elf32_External_Rela);
-
- relas = (Elf_Internal_Rela *) cmalloc (nrelas,
- sizeof (Elf_Internal_Rela));
-
- if (relas == NULL)
- {
- free (erelas);
- error (_("out of memory parsing relocs\n"));
- return false;
- }
-
- for (i = 0; i < nrelas; i++)
- {
- relas[i].r_offset = BYTE_GET (erelas[i].r_offset);
- relas[i].r_info = BYTE_GET (erelas[i].r_info);
- relas[i].r_addend = BYTE_GET_SIGNED (erelas[i].r_addend);
- }
-
- free (erelas);
- }
- else
- {
- Elf64_External_Rela * erelas;
-
- erelas = (Elf64_External_Rela *) get_data (NULL, filedata, rel_offset, 1,
- rel_size, _("64-bit relocation data"));
- if (!erelas)
- return false;
-
- nrelas = rel_size / sizeof (Elf64_External_Rela);
-
- relas = (Elf_Internal_Rela *) cmalloc (nrelas,
- sizeof (Elf_Internal_Rela));
-
- if (relas == NULL)
- {
- free (erelas);
- error (_("out of memory parsing relocs\n"));
- return false;
- }
-
- for (i = 0; i < nrelas; i++)
- {
- relas[i].r_offset = BYTE_GET (erelas[i].r_offset);
- relas[i].r_info = BYTE_GET (erelas[i].r_info);
- relas[i].r_addend = BYTE_GET_SIGNED (erelas[i].r_addend);
-
- if (filedata->file_header.e_machine == EM_MIPS
- && filedata->file_header.e_ident[EI_DATA] != ELFDATA2MSB)
- {
- /* In little-endian objects, r_info isn't really a
- 64-bit little-endian value: it has a 32-bit
- little-endian symbol index followed by four
- individual byte fields. Reorder INFO
- accordingly. */
- uint64_t inf = relas[i].r_info;
- inf = (((inf & 0xffffffff) << 32)
- | ((inf >> 56) & 0xff)
- | ((inf >> 40) & 0xff00)
- | ((inf >> 24) & 0xff0000)
- | ((inf >> 8) & 0xff000000));
- relas[i].r_info = inf;
- }
- }
-
- free (erelas);
- }
-
- *relasp = relas;
- *nrelasp = nrelas;
- return true;
-}
-
-/* Load REL type relocations from FILEDATA at REL_OFFSET extending for REL_SIZE bytes.
- Returns TRUE upon success, FALSE otherwise. If successful then a
- pointer to a malloc'ed buffer containing the relocs is placed in *RELSP,
- and the number of relocs loaded is placed in *NRELSP. It is the caller's
- responsibility to free the allocated buffer. */
-
-static bool
-slurp_rel_relocs (Filedata *filedata,
- uint64_t rel_offset,
- uint64_t rel_size,
- Elf_Internal_Rela **relsp,
- uint64_t *nrelsp)
-{
- Elf_Internal_Rela * rels;
- uint64_t nrels;
- unsigned int i;
-
- if (is_32bit_elf)
- {
- Elf32_External_Rel * erels;
-
- erels = (Elf32_External_Rel *) get_data (NULL, filedata, rel_offset, 1,
- rel_size, _("32-bit relocation data"));
- if (!erels)
- return false;
-
- nrels = rel_size / sizeof (Elf32_External_Rel);
-
- rels = (Elf_Internal_Rela *) cmalloc (nrels, sizeof (Elf_Internal_Rela));
-
- if (rels == NULL)
- {
- free (erels);
- error (_("out of memory parsing relocs\n"));
- return false;
- }
-
- for (i = 0; i < nrels; i++)
- {
- rels[i].r_offset = BYTE_GET (erels[i].r_offset);
- rels[i].r_info = BYTE_GET (erels[i].r_info);
- rels[i].r_addend = 0;
- }
-
- free (erels);
- }
- else
- {
- Elf64_External_Rel * erels;
-
- erels = (Elf64_External_Rel *) get_data (NULL, filedata, rel_offset, 1,
- rel_size, _("64-bit relocation data"));
- if (!erels)
- return false;
-
- nrels = rel_size / sizeof (Elf64_External_Rel);
-
- rels = (Elf_Internal_Rela *) cmalloc (nrels, sizeof (Elf_Internal_Rela));
-
- if (rels == NULL)
- {
- free (erels);
- error (_("out of memory parsing relocs\n"));
- return false;
- }
-
- for (i = 0; i < nrels; i++)
- {
- rels[i].r_offset = BYTE_GET (erels[i].r_offset);
- rels[i].r_info = BYTE_GET (erels[i].r_info);
- rels[i].r_addend = 0;
-
- if (filedata->file_header.e_machine == EM_MIPS
- && filedata->file_header.e_ident[EI_DATA] != ELFDATA2MSB)
- {
- /* In little-endian objects, r_info isn't really a
- 64-bit little-endian value: it has a 32-bit
- little-endian symbol index followed by four
- individual byte fields. Reorder INFO
- accordingly. */
- uint64_t inf = rels[i].r_info;
- inf = (((inf & 0xffffffff) << 32)
- | ((inf >> 56) & 0xff)
- | ((inf >> 40) & 0xff00)
- | ((inf >> 24) & 0xff0000)
- | ((inf >> 8) & 0xff000000));
- rels[i].r_info = inf;
- }
- }
-
- free (erels);
- }
-
- *relsp = rels;
- *nrelsp = nrels;
- return true;
-}
-
-/* Returns the reloc type extracted from the reloc info field. */
-
-static unsigned int
-get_reloc_type (Filedata * filedata, uint64_t reloc_info)
-{
- if (is_32bit_elf)
- return ELF32_R_TYPE (reloc_info);
-
- switch (filedata->file_header.e_machine)
- {
- case EM_MIPS:
- /* Note: We assume that reloc_info has already been adjusted for us. */
- return ELF64_MIPS_R_TYPE (reloc_info);
-
- case EM_SPARCV9:
- return ELF64_R_TYPE_ID (reloc_info);
-
- default:
- return ELF64_R_TYPE (reloc_info);
- }
-}
-
-/* Return the symbol index extracted from the reloc info field. */
-
-static uint64_t
-get_reloc_symindex (uint64_t reloc_info)
-{
- return is_32bit_elf ? ELF32_R_SYM (reloc_info) : ELF64_R_SYM (reloc_info);
-}
-
-static inline bool
-uses_msp430x_relocs (Filedata * filedata)
-{
- return
- filedata->file_header.e_machine == EM_MSP430 /* Paranoia. */
- /* GCC uses osabi == ELFOSBI_STANDALONE. */
- && (((filedata->file_header.e_flags & EF_MSP430_MACH) == E_MSP430_MACH_MSP430X)
- /* TI compiler uses ELFOSABI_NONE. */
- || (filedata->file_header.e_ident[EI_OSABI] == ELFOSABI_NONE));
-}
-
-
-static const char *
-get_symbol_at (Filedata * filedata,
- Elf_Internal_Sym * symtab,
- uint64_t nsyms,
- char * strtab,
- uint64_t where,
- uint64_t * offset_return)
-{
- Elf_Internal_Sym * beg = symtab;
- Elf_Internal_Sym * end = symtab + nsyms;
- Elf_Internal_Sym * best = NULL;
- uint64_t dist = 0x100000;
-
- /* FIXME: Since this function is likely to be called repeatedly with
- slightly increasing addresses each time, we could speed things up by
- caching the last returned value and starting our search from there. */
- while (beg < end)
- {
- Elf_Internal_Sym * sym;
- uint64_t value;
-
- sym = beg + (end - beg) / 2;
-
- value = sym->st_value;
-
- if (where >= value
- && where - value < dist)
- {
- best = sym;
- dist = where - value;
- if (dist == 0)
- break;
- }
-
- if (where < value)
- end = sym;
- else
- beg = sym + 1;
- }
-
- const char *name;
-
- /* If there is a section start closer than the found symbol then
- use that for symbolizing the address. */
- Elf_Internal_Shdr *sec = find_section_by_address (filedata, where);
- if (sec != NULL
- && where - sec->sh_addr < dist
- && section_name_valid (filedata, sec))
- {
- name = section_name (filedata, sec);
- dist = where - sec->sh_addr;
- }
- else if (best != NULL)
- name = strtab + best->st_name;
- else
- return NULL;
-
- if (offset_return != NULL)
- * offset_return = dist;
-
- return name;
-}
-
-static void
-print_relr_addr_and_sym (Filedata * filedata,
- Elf_Internal_Sym * symtab,
- uint64_t nsyms,
- char * strtab,
- uint64_t where)
-{
- const char * symname = NULL;
- uint64_t offset = 0;
-
- print_vma (where, ZERO_HEX);
- printf (" ");
-
- symname = get_symbol_at (filedata, symtab, nsyms, strtab, where, & offset);
-
- if (symname == NULL)
- printf ("<no sym>");
- else if (offset == 0)
- print_symbol_name (38, symname);
- else
- {
- print_symbol_name (28, symname);
- printf (" + ");
- print_vma (offset, PREFIX_HEX);
- }
-}
-
-/* See bfd_is_aarch64_special_symbol_name. */
-
-static bool
-is_aarch64_special_symbol_name (const char *name)
-{
- if (!name || name[0] != '$')
- return false;
- if (name[1] == 'x' || name[1] == 'd')
- /* Map. */;
- else if (name[1] == 'm' || name[1] == 'f' || name[1] == 'p')
- /* Tag. */;
- else
- return false;
- return name[2] == 0 || name[2] == '.';
-}
-
-static bool
-is_special_symbol_name (Filedata * filedata, const char * s)
-{
- switch (filedata->file_header.e_machine)
- {
- case EM_AARCH64:
- return is_aarch64_special_symbol_name (s);
-
- default:
- return false;
- }
-}
-
-/* Allows selecting the best symbol from a set for displaying addresses.
- BEST is the current best or NULL if there are no good symbols yet.
- SYM is the next symbol to consider, if it is better than BEST then
- return SYM else return BEST. */
-
-static Elf_Internal_Sym *
-select_display_sym (Filedata * filedata,
- char * strtab,
- uint64_t strtablen,
- Elf_Internal_Sym * best,
- Elf_Internal_Sym * sym)
-{
- /* Ignore empty or invalid syms. */
- if (sym->st_name == 0)
- return best;
- if (sym->st_name >= strtablen)
- return best;
- /* Ignore undefined or TLS syms. */
- if (sym->st_shndx == SHN_UNDEF)
- return best;
- if (ELF_ST_TYPE (sym->st_info) == STT_TLS)
- return best;
-
- char *s = strtab + sym->st_name;
-
- /* Don't display special symbols. */
- if (is_special_symbol_name (filedata, s))
- return best;
-
- /* Here SYM is good for display. */
-
- if (best == NULL)
- return sym;
-
- char *sbest = strtab + best->st_name;
-
- /* Prefer non-local symbols. */
- if (ELF_ST_BIND (sym->st_info) == STB_LOCAL
- && ELF_ST_BIND (best->st_info) != STB_LOCAL)
- return best;
- if (ELF_ST_BIND (sym->st_info) != STB_LOCAL
- && ELF_ST_BIND (best->st_info) == STB_LOCAL)
- return sym;
-
- /* Select based on lexicographic order. */
- return strcmp (s, sbest) < 0 ? sym : best;
-}
-
-/* Filter the sorted SYMTAB symbol array in-place to select at most one
- symbol for an address and drop symbols that are not good to display.
- Returns the new array length. */
-
-static uint64_t
-filter_display_syms (Filedata * filedata,
- Elf_Internal_Sym * symtab,
- uint64_t nsyms,
- char * strtab,
- uint64_t strtablen)
-{
- Elf_Internal_Sym *r = symtab;
- Elf_Internal_Sym *w = symtab;
- Elf_Internal_Sym *best = NULL;
- Elf_Internal_Sym *end = symtab + nsyms;
- while (r < end)
- {
- /* Select the best symbol for an address. */
- while (r < end
- && (best == NULL || best->st_value == r->st_value))
- {
- best = select_display_sym (filedata, strtab, strtablen, best, r);
- r++;
- }
- if (best != NULL)
- {
- *w = *best;
- w++;
- best = NULL;
- }
- }
- return w - symtab;
-}
-
-static /* signed */ int
-symcmp (const void *p, const void *q)
-{
- Elf_Internal_Sym *sp = (Elf_Internal_Sym *) p;
- Elf_Internal_Sym *sq = (Elf_Internal_Sym *) q;
-
- return sp->st_value > sq->st_value ? 1 : (sp->st_value < sq->st_value ? -1 : 0);
-}
-
-static uint64_t
-count_relr_relocations (Filedata * filedata,
- Elf_Internal_Shdr * section)
-{
- uint64_t * relrs;
- uint64_t nentries;
- uint64_t i;
- uint64_t count;
- int entsize;
-
- if (section == NULL
- || section->sh_type != SHT_RELR
- || section->sh_size == 0)
- return 0;
-
- entsize = section->sh_entsize;
- if (entsize == 0)
- entsize = is_32bit_elf
- ? sizeof (Elf32_External_Relr) : sizeof (Elf64_External_Relr);
- else if (entsize != sizeof (Elf32_External_Relr)
- && entsize != sizeof (Elf64_External_Relr))
- return 0;
-
- nentries = section->sh_size / entsize;
- if (nentries == 0)
- return 0;
-
- /* FIXME: This call to get_data duplicates one that follows in
- dump_relr_relocations(). They could be combined into just
- one call. */
- relrs = get_data (NULL, filedata, section->sh_offset, 1,
- section->sh_size, _("RELR relocation data"));
- if (relrs == NULL)
- return 0;
-
- for (count = i = 0; i < nentries; i++)
- {
- uint64_t entry;
-
- if (entsize == sizeof (Elf32_External_Relr))
- entry = BYTE_GET (((Elf32_External_Relr *)relrs)[i].r_data);
- else
- entry = BYTE_GET (((Elf64_External_Relr *)relrs)[i].r_data);
-
- if ((entry & 1) == 0)
- {
- ++ count;
- }
- else
- {
- if (entry == 1)
- continue;
-
- for (; entry >>= 1;)
- if ((entry & 1) == 1)
- ++ count;
- }
- }
-
- free (relrs);
- return count;
-}
-
-static bool
-dump_relr_relocations (Filedata * filedata,
- Elf_Internal_Shdr * section,
- Elf_Internal_Sym * symtab,
- uint64_t nsyms,
- char * strtab,
- uint64_t strtablen)
-{
- uint64_t * relrs;
- uint64_t nentries, i;
- uint64_t relr_size = section->sh_size;
- int relr_entsize = section->sh_entsize;
- uint64_t relr_offset = section->sh_offset;
- uint64_t where = 0;
- int num_bits_in_entry;
-
- if (relr_entsize == 0)
- relr_entsize = is_32bit_elf
- ? sizeof (Elf32_External_Relr) : sizeof (Elf64_External_Relr);
-
- nentries = relr_size / relr_entsize;
-
- if (nentries == 0)
- return true;
-
- if (relr_entsize == sizeof (Elf32_External_Relr))
- num_bits_in_entry = 31;
- else if (relr_entsize == sizeof (Elf64_External_Relr))
- num_bits_in_entry = 63;
- else
- {
- warn (_("Unexpected entsize for RELR section\n"));
- return false;
- }
-
- relrs = get_data (NULL, filedata, relr_offset, 1, relr_size, _("RELR relocation data"));
- if (relrs == NULL)
- return false;
-
- /* Paranoia. */
- if (strtab == NULL)
- strtablen = 0;
- if (symtab == NULL)
- nsyms = 0;
-
- if (symtab != NULL)
- {
- /* Symbol tables are not sorted on address, but we want a quick lookup
- for the symbol associated with each address computed below, so sort
- the table then filter out unwanted entries. FIXME: This assumes that
- the symbol table will not be used later on for some other purpose. */
- qsort (symtab, nsyms, sizeof (Elf_Internal_Sym), symcmp);
- nsyms = filter_display_syms (filedata, symtab, nsyms, strtab, strtablen);
- }
-
- if (relr_entsize == sizeof (Elf32_External_Relr))
- printf (_ ("Index: Entry Address Symbolic Address\n"));
- else
- printf (_ ("Index: Entry Address Symbolic Address\n"));
-
- for (i = 0; i < nentries; i++)
- {
- uint64_t entry;
-
- if (relr_entsize == sizeof (Elf32_External_Relr))
- entry = BYTE_GET (((Elf32_External_Relr *)relrs)[i].r_data);
- else
- entry = BYTE_GET (((Elf64_External_Relr *)relrs)[i].r_data);
-
- /* We assume that there will never be more than 9999 entries. */
- printf (_("%04u: "), (unsigned int) i);
- print_vma (entry, ZERO_HEX);
- printf (" ");
-
- if ((entry & 1) == 0)
- {
- where = entry;
- print_relr_addr_and_sym (filedata, symtab, nsyms, strtab, where);
- printf ("\n");
- where += relr_entsize;
- }
- else
- {
- bool first = true;
- int j;
-
- /* The least significant bit is ignored. */
- if (entry == 1)
- /* This can actually happen when the linker is allowed to shrink
- RELR sections. For more details see: https://reviews.llvm.org/D67164. */
- continue;
- else if (i == 0)
- warn (_("Unusual RELR bitmap - no previous entry to set the base address\n"));
-
- for (j = 0; entry >>= 1; j++)
- if ((entry & 1) == 1)
- {
- uint64_t addr = where + (j * relr_entsize);
-
- if (first)
- {
- print_relr_addr_and_sym (filedata, symtab, nsyms, strtab, addr);
- first = false;
- }
- else
- {
- printf (_("\n%*s "), relr_entsize == 4 ? 15 : 23, " ");
- print_relr_addr_and_sym (filedata, symtab, nsyms, strtab, addr);
- }
- }
-
- printf ("\n");
- where += num_bits_in_entry * relr_entsize;
- }
- }
-
- free (relrs);
- return true;
-}
-
-/* Display the contents of the relocation data found at the specified
- offset. */
-
-static bool
-dump_relocations (Filedata * filedata,
- uint64_t rel_offset,
- uint64_t rel_size,
- Elf_Internal_Sym * symtab,
- uint64_t nsyms,
- char * strtab,
- uint64_t strtablen,
- relocation_type rel_type,
- bool is_dynsym)
-{
- size_t i;
- Elf_Internal_Rela * rels;
- bool res = true;
-
- if (rel_type == reltype_unknown)
- rel_type = guess_is_rela (filedata->file_header.e_machine) ? reltype_rela : reltype_rel;
-
- if (rel_type == reltype_rela)
- {
- if (!slurp_rela_relocs (filedata, rel_offset, rel_size, &rels, &rel_size))
- return false;
- }
- else if (rel_type == reltype_rel)
- {
- if (!slurp_rel_relocs (filedata, rel_offset, rel_size, &rels, &rel_size))
- return false;
- }
- else if (rel_type == reltype_relr)
- {
- /* This should have been handled by display_relocations(). */
- return false;
- }
-
- if (is_32bit_elf)
- {
- if (rel_type == reltype_rela)
- {
- if (do_wide)
- printf (_(" Offset Info Type Sym. Value Symbol's Name + Addend\n"));
- else
- printf (_(" Offset Info Type Sym.Value Sym. Name + Addend\n"));
- }
- else
- {
- if (do_wide)
- printf (_(" Offset Info Type Sym. Value Symbol's Name\n"));
- else
- printf (_(" Offset Info Type Sym.Value Sym. Name\n"));
- }
- }
- else
- {
- if (rel_type == reltype_rela)
- {
- if (do_wide)
- printf (_(" Offset Info Type Symbol's Value Symbol's Name + Addend\n"));
- else
- printf (_(" Offset Info Type Sym. Value Sym. Name + Addend\n"));
- }
- else
- {
- if (do_wide)
- printf (_(" Offset Info Type Symbol's Value Symbol's Name\n"));
- else
- printf (_(" Offset Info Type Sym. Value Sym. Name\n"));
- }
- }
-
- for (i = 0; i < rel_size; i++)
- {
- const char * rtype;
- uint64_t offset;
- uint64_t inf;
- uint64_t symtab_index;
- uint64_t type;
-
- offset = rels[i].r_offset;
- inf = rels[i].r_info;
-
- type = get_reloc_type (filedata, inf);
- symtab_index = get_reloc_symindex (inf);
-
- if (is_32bit_elf)
- {
- printf ("%8.8lx %8.8lx ",
- (unsigned long) offset & 0xffffffff,
- (unsigned long) inf & 0xffffffff);
- }
- else
- {
- printf (do_wide
- ? "%16.16" PRIx64 " %16.16" PRIx64 " "
- : "%12.12" PRIx64 " %12.12" PRIx64 " ",
- offset, inf);
- }
-
- switch (filedata->file_header.e_machine)
- {
- default:
- rtype = NULL;
- break;
-
- case EM_AARCH64:
- rtype = elf_aarch64_reloc_type (type);
- break;
-
- case EM_M32R:
- case EM_CYGNUS_M32R:
- rtype = elf_m32r_reloc_type (type);
- break;
-
- case EM_386:
- case EM_IAMCU:
- rtype = elf_i386_reloc_type (type);
- break;
-
- case EM_68HC11:
- case EM_68HC12:
- rtype = elf_m68hc11_reloc_type (type);
- break;
-
- case EM_S12Z:
- rtype = elf_s12z_reloc_type (type);
- break;
-
- case EM_68K:
- rtype = elf_m68k_reloc_type (type);
- break;
-
- case EM_960:
- rtype = elf_i960_reloc_type (type);
- break;
-
- case EM_AVR:
- case EM_AVR_OLD:
- rtype = elf_avr_reloc_type (type);
- break;
-
- case EM_OLD_SPARCV9:
- case EM_SPARC32PLUS:
- case EM_SPARCV9:
- case EM_SPARC:
- rtype = elf_sparc_reloc_type (type);
- break;
-
- case EM_SPU:
- rtype = elf_spu_reloc_type (type);
- break;
-
- case EM_V800:
- rtype = v800_reloc_type (type);
- break;
- case EM_V850:
- case EM_CYGNUS_V850:
- rtype = v850_reloc_type (type);
- break;
-
- case EM_D10V:
- case EM_CYGNUS_D10V:
- rtype = elf_d10v_reloc_type (type);
- break;
-
- case EM_D30V:
- case EM_CYGNUS_D30V:
- rtype = elf_d30v_reloc_type (type);
- break;
-
- case EM_DLX:
- rtype = elf_dlx_reloc_type (type);
- break;
-
- case EM_SH:
- rtype = elf_sh_reloc_type (type);
- break;
-
- case EM_MN10300:
- case EM_CYGNUS_MN10300:
- rtype = elf_mn10300_reloc_type (type);
- break;
-
- case EM_MN10200:
- case EM_CYGNUS_MN10200:
- rtype = elf_mn10200_reloc_type (type);
- break;
-
- case EM_FR30:
- case EM_CYGNUS_FR30:
- rtype = elf_fr30_reloc_type (type);
- break;
-
- case EM_CYGNUS_FRV:
- rtype = elf_frv_reloc_type (type);
- break;
-
- case EM_CSKY:
- rtype = elf_csky_reloc_type (type);
- break;
-
- case EM_FT32:
- rtype = elf_ft32_reloc_type (type);
- break;
-
- case EM_MCORE:
- rtype = elf_mcore_reloc_type (type);
- break;
-
- case EM_MMIX:
- rtype = elf_mmix_reloc_type (type);
- break;
-
- case EM_MOXIE:
- rtype = elf_moxie_reloc_type (type);
- break;
-
- case EM_MSP430:
- if (uses_msp430x_relocs (filedata))
- {
- rtype = elf_msp430x_reloc_type (type);
- break;
- }
- /* Fall through. */
- case EM_MSP430_OLD:
- rtype = elf_msp430_reloc_type (type);
- break;
-
- case EM_NDS32:
- rtype = elf_nds32_reloc_type (type);
- break;
-
- case EM_PPC:
- rtype = elf_ppc_reloc_type (type);
- break;
-
- case EM_PPC64:
- rtype = elf_ppc64_reloc_type (type);
- break;
-
- case EM_MIPS:
- case EM_MIPS_RS3_LE:
- rtype = elf_mips_reloc_type (type);
- break;
-
- case EM_RISCV:
- rtype = elf_riscv_reloc_type (type);
- break;
-
- case EM_ALPHA:
- rtype = elf_alpha_reloc_type (type);
- break;
-
- case EM_ARM:
- rtype = elf_arm_reloc_type (type);
- break;
-
- case EM_ARC:
- case EM_ARC_COMPACT:
- case EM_ARC_COMPACT2:
- case EM_ARC_COMPACT3:
- case EM_ARC_COMPACT3_64:
- rtype = elf_arc_reloc_type (type);
- break;
-
- case EM_PARISC:
- rtype = elf_hppa_reloc_type (type);
- break;
-
- case EM_H8_300:
- case EM_H8_300H:
- case EM_H8S:
- rtype = elf_h8_reloc_type (type);
- break;
-
- case EM_OR1K:
- rtype = elf_or1k_reloc_type (type);
- break;
-
- case EM_PJ:
- case EM_PJ_OLD:
- rtype = elf_pj_reloc_type (type);
- break;
- case EM_IA_64:
- rtype = elf_ia64_reloc_type (type);
- break;
-
- case EM_KVX:
- rtype = elf_kvx_reloc_type (type);
- break;
-
- case EM_CRIS:
- rtype = elf_cris_reloc_type (type);
- break;
-
- case EM_860:
- rtype = elf_i860_reloc_type (type);
- break;
-
- case EM_X86_64:
- case EM_L1OM:
- case EM_K1OM:
- rtype = elf_x86_64_reloc_type (type);
- break;
-
- case EM_S370:
- rtype = i370_reloc_type (type);
- break;
-
- case EM_S390_OLD:
- case EM_S390:
- rtype = elf_s390_reloc_type (type);
- break;
-
- case EM_SCORE:
- rtype = elf_score_reloc_type (type);
- break;
-
- case EM_XSTORMY16:
- rtype = elf_xstormy16_reloc_type (type);
- break;
-
- case EM_CRX:
- rtype = elf_crx_reloc_type (type);
- break;
-
- case EM_VAX:
- rtype = elf_vax_reloc_type (type);
- break;
-
- case EM_VISIUM:
- rtype = elf_visium_reloc_type (type);
- break;
-
- case EM_BPF:
- rtype = elf_bpf_reloc_type (type);
- break;
-
- case EM_ADAPTEVA_EPIPHANY:
- rtype = elf_epiphany_reloc_type (type);
- break;
-
- case EM_IP2K:
- case EM_IP2K_OLD:
- rtype = elf_ip2k_reloc_type (type);
- break;
-
- case EM_IQ2000:
- rtype = elf_iq2000_reloc_type (type);
- break;
-
- case EM_XTENSA_OLD:
- case EM_XTENSA:
- rtype = elf_xtensa_reloc_type (type);
- break;
-
- case EM_LATTICEMICO32:
- rtype = elf_lm32_reloc_type (type);
- break;
-
- case EM_M32C_OLD:
- case EM_M32C:
- rtype = elf_m32c_reloc_type (type);
- break;
-
- case EM_MT:
- rtype = elf_mt_reloc_type (type);
- break;
-
- case EM_BLACKFIN:
- rtype = elf_bfin_reloc_type (type);
- break;
-
- case EM_CYGNUS_MEP:
- rtype = elf_mep_reloc_type (type);
- break;
-
- case EM_CR16:
- rtype = elf_cr16_reloc_type (type);
- break;
-
- case EM_MICROBLAZE:
- case EM_MICROBLAZE_OLD:
- rtype = elf_microblaze_reloc_type (type);
- break;
-
- case EM_RL78:
- rtype = elf_rl78_reloc_type (type);
- break;
-
- case EM_RX:
- rtype = elf_rx_reloc_type (type);
- break;
-
- case EM_METAG:
- rtype = elf_metag_reloc_type (type);
- break;
-
- case EM_TI_C6000:
- rtype = elf_tic6x_reloc_type (type);
- break;
-
- case EM_TILEGX:
- rtype = elf_tilegx_reloc_type (type);
- break;
-
- case EM_TILEPRO:
- rtype = elf_tilepro_reloc_type (type);
- break;
-
- case EM_WEBASSEMBLY:
- rtype = elf_wasm32_reloc_type (type);
- break;
-
- case EM_XGATE:
- rtype = elf_xgate_reloc_type (type);
- break;
-
- case EM_ALTERA_NIOS2:
- rtype = elf_nios2_reloc_type (type);
- break;
-
- case EM_TI_PRU:
- rtype = elf_pru_reloc_type (type);
- break;
-
- case EM_NFP:
- if (EF_NFP_MACH (filedata->file_header.e_flags) == E_NFP_MACH_3200)
- rtype = elf_nfp3200_reloc_type (type);
- else
- rtype = elf_nfp_reloc_type (type);
- break;
-
- case EM_Z80:
- rtype = elf_z80_reloc_type (type);
- break;
-
- case EM_LOONGARCH:
- rtype = elf_loongarch_reloc_type (type);
- break;
-
- case EM_AMDGPU:
- rtype = elf_amdgpu_reloc_type (type);
- break;
- }
-
- if (rtype == NULL)
- printf (_("unrecognized: %-7lx"), (unsigned long) type & 0xffffffff);
- else
- printf (do_wide ? "%-22s" : "%-17.17s", rtype);
-
- if (filedata->file_header.e_machine == EM_ALPHA
- && rtype != NULL
- && streq (rtype, "R_ALPHA_LITUSE")
- && rel_type == reltype_rela)
- {
- switch (rels[i].r_addend)
- {
- case LITUSE_ALPHA_ADDR: rtype = "ADDR"; break;
- case LITUSE_ALPHA_BASE: rtype = "BASE"; break;
- case LITUSE_ALPHA_BYTOFF: rtype = "BYTOFF"; break;
- case LITUSE_ALPHA_JSR: rtype = "JSR"; break;
- case LITUSE_ALPHA_TLSGD: rtype = "TLSGD"; break;
- case LITUSE_ALPHA_TLSLDM: rtype = "TLSLDM"; break;
- case LITUSE_ALPHA_JSRDIRECT: rtype = "JSRDIRECT"; break;
- default: rtype = NULL;
- }
-
- if (rtype)
- printf (" (%s)", rtype);
- else
- {
- putchar (' ');
- printf (_("<unknown addend: %" PRIx64 ">"),
- rels[i].r_addend);
- res = false;
- }
- }
- else if (symtab_index)
- {
- if (symtab == NULL || symtab_index >= nsyms)
- {
- error (_(" bad symbol index: %08lx in reloc\n"),
- (unsigned long) symtab_index);
- res = false;
- }
- else
- {
- Elf_Internal_Sym * psym;
- const char * version_string;
- enum versioned_symbol_info sym_info;
- unsigned short vna_other;
-
- psym = symtab + symtab_index;
-
- version_string
- = get_symbol_version_string (filedata, is_dynsym,
- strtab, strtablen,
- symtab_index,
- psym,
- &sym_info,
- &vna_other);
-
- printf (" ");
-
- if (ELF_ST_TYPE (psym->st_info) == STT_GNU_IFUNC)
- {
- const char * name;
- unsigned int len;
- unsigned int width = is_32bit_elf ? 8 : 14;
-
- /* Relocations against GNU_IFUNC symbols do not use the value
- of the symbol as the address to relocate against. Instead
- they invoke the function named by the symbol and use its
- result as the address for relocation.
-
- To indicate this to the user, do not display the value of
- the symbol in the "Symbols's Value" field. Instead show
- its name followed by () as a hint that the symbol is
- invoked. */
-
- if (strtab == NULL
- || psym->st_name == 0
- || psym->st_name >= strtablen)
- name = "??";
- else
- name = strtab + psym->st_name;
-
- len = print_symbol_name (width, name);
- if (version_string)
- printf (sym_info == symbol_public ? "@@%s" : "@%s",
- version_string);
- printf ("()%-*s", len <= width ? (width + 1) - len : 1, " ");
- }
- else
- {
- print_vma (psym->st_value, LONG_HEX);
-
- printf (is_32bit_elf ? " " : " ");
- }
-
- if (psym->st_name == 0)
- {
- const char * sec_name = "<null>";
-
- if (ELF_ST_TYPE (psym->st_info) == STT_SECTION)
- sec_name = printable_section_name_from_index
- (filedata, psym->st_shndx, NULL);
-
- print_symbol_name (22, sec_name);
- }
- else if (strtab == NULL)
- printf (_("<string table index: %3ld>"), psym->st_name);
- else if (psym->st_name >= strtablen)
- {
- error (_("<corrupt string table index: %3ld>\n"),
- psym->st_name);
- res = false;
- }
- else
- {
- print_symbol_name (22, strtab + psym->st_name);
- if (version_string)
- printf (sym_info == symbol_public ? "@@%s" : "@%s",
- version_string);
- }
-
- if (rel_type == reltype_rela)
- {
- uint64_t off = rels[i].r_addend;
-
- if ((int64_t) off < 0)
- printf (" - %" PRIx64, -off);
- else
- printf (" + %" PRIx64, off);
- }
- }
- }
- else if (rel_type == reltype_rela)
- {
- uint64_t off = rels[i].r_addend;
-
- printf ("%*c", is_32bit_elf ? 12 : 20, ' ');
- if ((int64_t) off < 0)
- printf ("-%" PRIx64, -off);
- else
- printf ("%" PRIx64, off);
- }
-
- if (filedata->file_header.e_machine == EM_SPARCV9
- && rtype != NULL
- && streq (rtype, "R_SPARC_OLO10"))
- printf (" + %" PRIx64, ELF64_R_TYPE_DATA (inf));
-
- putchar ('\n');
-
- if (! is_32bit_elf && filedata->file_header.e_machine == EM_MIPS)
- {
- uint64_t type2 = ELF64_MIPS_R_TYPE2 (inf);
- uint64_t type3 = ELF64_MIPS_R_TYPE3 (inf);
- const char * rtype2 = elf_mips_reloc_type (type2);
- const char * rtype3 = elf_mips_reloc_type (type3);
-
- printf (" Type2: ");
-
- if (rtype2 == NULL)
- printf (_("unrecognized: %-7lx"),
- (unsigned long) type2 & 0xffffffff);
- else
- printf ("%-17.17s", rtype2);
-
- printf ("\n Type3: ");
-
- if (rtype3 == NULL)
- printf (_("unrecognized: %-7lx"),
- (unsigned long) type3 & 0xffffffff);
- else
- printf ("%-17.17s", rtype3);
-
- putchar ('\n');
- }
- }
-
- free (rels);
-
- return res;
-}
-
-static const char *
-get_aarch64_dynamic_type (unsigned long type)
-{
- switch (type)
- {
- case DT_AARCH64_BTI_PLT: return "AARCH64_BTI_PLT";
- case DT_AARCH64_PAC_PLT: return "AARCH64_PAC_PLT";
- case DT_AARCH64_VARIANT_PCS: return "AARCH64_VARIANT_PCS";
- default:
- return NULL;
- }
-}
-
-static const char *
-get_mips_dynamic_type (unsigned long type)
-{
- switch (type)
- {
- case DT_MIPS_RLD_VERSION: return "MIPS_RLD_VERSION";
- case DT_MIPS_TIME_STAMP: return "MIPS_TIME_STAMP";
- case DT_MIPS_ICHECKSUM: return "MIPS_ICHECKSUM";
- case DT_MIPS_IVERSION: return "MIPS_IVERSION";
- case DT_MIPS_FLAGS: return "MIPS_FLAGS";
- case DT_MIPS_BASE_ADDRESS: return "MIPS_BASE_ADDRESS";
- case DT_MIPS_MSYM: return "MIPS_MSYM";
- case DT_MIPS_CONFLICT: return "MIPS_CONFLICT";
- case DT_MIPS_LIBLIST: return "MIPS_LIBLIST";
- case DT_MIPS_LOCAL_GOTNO: return "MIPS_LOCAL_GOTNO";
- case DT_MIPS_CONFLICTNO: return "MIPS_CONFLICTNO";
- case DT_MIPS_LIBLISTNO: return "MIPS_LIBLISTNO";
- case DT_MIPS_SYMTABNO: return "MIPS_SYMTABNO";
- case DT_MIPS_UNREFEXTNO: return "MIPS_UNREFEXTNO";
- case DT_MIPS_GOTSYM: return "MIPS_GOTSYM";
- case DT_MIPS_HIPAGENO: return "MIPS_HIPAGENO";
- case DT_MIPS_RLD_MAP: return "MIPS_RLD_MAP";
- case DT_MIPS_RLD_MAP_REL: return "MIPS_RLD_MAP_REL";
- case DT_MIPS_DELTA_CLASS: return "MIPS_DELTA_CLASS";
- case DT_MIPS_DELTA_CLASS_NO: return "MIPS_DELTA_CLASS_NO";
- case DT_MIPS_DELTA_INSTANCE: return "MIPS_DELTA_INSTANCE";
- case DT_MIPS_DELTA_INSTANCE_NO: return "MIPS_DELTA_INSTANCE_NO";
- case DT_MIPS_DELTA_RELOC: return "MIPS_DELTA_RELOC";
- case DT_MIPS_DELTA_RELOC_NO: return "MIPS_DELTA_RELOC_NO";
- case DT_MIPS_DELTA_SYM: return "MIPS_DELTA_SYM";
- case DT_MIPS_DELTA_SYM_NO: return "MIPS_DELTA_SYM_NO";
- case DT_MIPS_DELTA_CLASSSYM: return "MIPS_DELTA_CLASSSYM";
- case DT_MIPS_DELTA_CLASSSYM_NO: return "MIPS_DELTA_CLASSSYM_NO";
- case DT_MIPS_CXX_FLAGS: return "MIPS_CXX_FLAGS";
- case DT_MIPS_PIXIE_INIT: return "MIPS_PIXIE_INIT";
- case DT_MIPS_SYMBOL_LIB: return "MIPS_SYMBOL_LIB";
- case DT_MIPS_LOCALPAGE_GOTIDX: return "MIPS_LOCALPAGE_GOTIDX";
- case DT_MIPS_LOCAL_GOTIDX: return "MIPS_LOCAL_GOTIDX";
- case DT_MIPS_HIDDEN_GOTIDX: return "MIPS_HIDDEN_GOTIDX";
- case DT_MIPS_PROTECTED_GOTIDX: return "MIPS_PROTECTED_GOTIDX";
- case DT_MIPS_OPTIONS: return "MIPS_OPTIONS";
- case DT_MIPS_INTERFACE: return "MIPS_INTERFACE";
- case DT_MIPS_DYNSTR_ALIGN: return "MIPS_DYNSTR_ALIGN";
- case DT_MIPS_INTERFACE_SIZE: return "MIPS_INTERFACE_SIZE";
- case DT_MIPS_RLD_TEXT_RESOLVE_ADDR: return "MIPS_RLD_TEXT_RESOLVE_ADDR";
- case DT_MIPS_PERF_SUFFIX: return "MIPS_PERF_SUFFIX";
- case DT_MIPS_COMPACT_SIZE: return "MIPS_COMPACT_SIZE";
- case DT_MIPS_GP_VALUE: return "MIPS_GP_VALUE";
- case DT_MIPS_AUX_DYNAMIC: return "MIPS_AUX_DYNAMIC";
- case DT_MIPS_PLTGOT: return "MIPS_PLTGOT";
- case DT_MIPS_RWPLT: return "MIPS_RWPLT";
- case DT_MIPS_XHASH: return "MIPS_XHASH";
- default:
- return NULL;
- }
-}
-
-static const char *
-get_sparc64_dynamic_type (unsigned long type)
-{
- switch (type)
- {
- case DT_SPARC_REGISTER: return "SPARC_REGISTER";
- default:
- return NULL;
- }
-}
-
-static const char *
-get_ppc_dynamic_type (unsigned long type)
-{
- switch (type)
- {
- case DT_PPC_GOT: return "PPC_GOT";
- case DT_PPC_OPT: return "PPC_OPT";
- default:
- return NULL;
- }
-}
-
-static const char *
-get_ppc64_dynamic_type (unsigned long type)
-{
- switch (type)
- {
- case DT_PPC64_GLINK: return "PPC64_GLINK";
- case DT_PPC64_OPD: return "PPC64_OPD";
- case DT_PPC64_OPDSZ: return "PPC64_OPDSZ";
- case DT_PPC64_OPT: return "PPC64_OPT";
- default:
- return NULL;
- }
-}
-
-static const char *
-get_parisc_dynamic_type (unsigned long type)
-{
- switch (type)
- {
- case DT_HP_LOAD_MAP: return "HP_LOAD_MAP";
- case DT_HP_DLD_FLAGS: return "HP_DLD_FLAGS";
- case DT_HP_DLD_HOOK: return "HP_DLD_HOOK";
- case DT_HP_UX10_INIT: return "HP_UX10_INIT";
- case DT_HP_UX10_INITSZ: return "HP_UX10_INITSZ";
- case DT_HP_PREINIT: return "HP_PREINIT";
- case DT_HP_PREINITSZ: return "HP_PREINITSZ";
- case DT_HP_NEEDED: return "HP_NEEDED";
- case DT_HP_TIME_STAMP: return "HP_TIME_STAMP";
- case DT_HP_CHECKSUM: return "HP_CHECKSUM";
- case DT_HP_GST_SIZE: return "HP_GST_SIZE";
- case DT_HP_GST_VERSION: return "HP_GST_VERSION";
- case DT_HP_GST_HASHVAL: return "HP_GST_HASHVAL";
- case DT_HP_EPLTREL: return "HP_GST_EPLTREL";
- case DT_HP_EPLTRELSZ: return "HP_GST_EPLTRELSZ";
- case DT_HP_FILTERED: return "HP_FILTERED";
- case DT_HP_FILTER_TLS: return "HP_FILTER_TLS";
- case DT_HP_COMPAT_FILTERED: return "HP_COMPAT_FILTERED";
- case DT_HP_LAZYLOAD: return "HP_LAZYLOAD";
- case DT_HP_BIND_NOW_COUNT: return "HP_BIND_NOW_COUNT";
- case DT_PLT: return "PLT";
- case DT_PLT_SIZE: return "PLT_SIZE";
- case DT_DLT: return "DLT";
- case DT_DLT_SIZE: return "DLT_SIZE";
- default:
- return NULL;
- }
-}
-
-static const char *
-get_ia64_dynamic_type (unsigned long type)
-{
- switch (type)
- {
- case DT_IA_64_PLT_RESERVE: return "IA_64_PLT_RESERVE";
- case DT_IA_64_VMS_SUBTYPE: return "VMS_SUBTYPE";
- case DT_IA_64_VMS_IMGIOCNT: return "VMS_IMGIOCNT";
- case DT_IA_64_VMS_LNKFLAGS: return "VMS_LNKFLAGS";
- case DT_IA_64_VMS_VIR_MEM_BLK_SIZ: return "VMS_VIR_MEM_BLK_SIZ";
- case DT_IA_64_VMS_IDENT: return "VMS_IDENT";
- case DT_IA_64_VMS_NEEDED_IDENT: return "VMS_NEEDED_IDENT";
- case DT_IA_64_VMS_IMG_RELA_CNT: return "VMS_IMG_RELA_CNT";
- case DT_IA_64_VMS_SEG_RELA_CNT: return "VMS_SEG_RELA_CNT";
- case DT_IA_64_VMS_FIXUP_RELA_CNT: return "VMS_FIXUP_RELA_CNT";
- case DT_IA_64_VMS_FIXUP_NEEDED: return "VMS_FIXUP_NEEDED";
- case DT_IA_64_VMS_SYMVEC_CNT: return "VMS_SYMVEC_CNT";
- case DT_IA_64_VMS_XLATED: return "VMS_XLATED";
- case DT_IA_64_VMS_STACKSIZE: return "VMS_STACKSIZE";
- case DT_IA_64_VMS_UNWINDSZ: return "VMS_UNWINDSZ";
- case DT_IA_64_VMS_UNWIND_CODSEG: return "VMS_UNWIND_CODSEG";
- case DT_IA_64_VMS_UNWIND_INFOSEG: return "VMS_UNWIND_INFOSEG";
- case DT_IA_64_VMS_LINKTIME: return "VMS_LINKTIME";
- case DT_IA_64_VMS_SEG_NO: return "VMS_SEG_NO";
- case DT_IA_64_VMS_SYMVEC_OFFSET: return "VMS_SYMVEC_OFFSET";
- case DT_IA_64_VMS_SYMVEC_SEG: return "VMS_SYMVEC_SEG";
- case DT_IA_64_VMS_UNWIND_OFFSET: return "VMS_UNWIND_OFFSET";
- case DT_IA_64_VMS_UNWIND_SEG: return "VMS_UNWIND_SEG";
- case DT_IA_64_VMS_STRTAB_OFFSET: return "VMS_STRTAB_OFFSET";
- case DT_IA_64_VMS_SYSVER_OFFSET: return "VMS_SYSVER_OFFSET";
- case DT_IA_64_VMS_IMG_RELA_OFF: return "VMS_IMG_RELA_OFF";
- case DT_IA_64_VMS_SEG_RELA_OFF: return "VMS_SEG_RELA_OFF";
- case DT_IA_64_VMS_FIXUP_RELA_OFF: return "VMS_FIXUP_RELA_OFF";
- case DT_IA_64_VMS_PLTGOT_OFFSET: return "VMS_PLTGOT_OFFSET";
- case DT_IA_64_VMS_PLTGOT_SEG: return "VMS_PLTGOT_SEG";
- case DT_IA_64_VMS_FPMODE: return "VMS_FPMODE";
- default:
- return NULL;
- }
-}
-
-static const char *
-get_solaris_section_type (unsigned long type)
-{
- switch (type)
- {
- case 0x6fffffee: return "SUNW_ancillary";
- case 0x6fffffef: return "SUNW_capchain";
- case 0x6ffffff0: return "SUNW_capinfo";
- case 0x6ffffff1: return "SUNW_symsort";
- case 0x6ffffff2: return "SUNW_tlssort";
- case 0x6ffffff3: return "SUNW_LDYNSYM";
- case 0x6ffffff4: return "SUNW_dof";
- case 0x6ffffff5: return "SUNW_cap";
- case 0x6ffffff6: return "SUNW_SIGNATURE";
- case 0x6ffffff7: return "SUNW_ANNOTATE";
- case 0x6ffffff8: return "SUNW_DEBUGSTR";
- case 0x6ffffff9: return "SUNW_DEBUG";
- case 0x6ffffffa: return "SUNW_move";
- case 0x6ffffffb: return "SUNW_COMDAT";
- case 0x6ffffffc: return "SUNW_syminfo";
- case 0x6ffffffd: return "SUNW_verdef";
- case 0x6ffffffe: return "SUNW_verneed";
- case 0x6fffffff: return "SUNW_versym";
- case 0x70000000: return "SPARC_GOTDATA";
- default: return NULL;
- }
-}
-
-static const char *
-get_alpha_dynamic_type (unsigned long type)
-{
- switch (type)
- {
- case DT_ALPHA_PLTRO: return "ALPHA_PLTRO";
- default: return NULL;
- }
-}
-
-static const char *
-get_score_dynamic_type (unsigned long type)
-{
- switch (type)
- {
- case DT_SCORE_BASE_ADDRESS: return "SCORE_BASE_ADDRESS";
- case DT_SCORE_LOCAL_GOTNO: return "SCORE_LOCAL_GOTNO";
- case DT_SCORE_SYMTABNO: return "SCORE_SYMTABNO";
- case DT_SCORE_GOTSYM: return "SCORE_GOTSYM";
- case DT_SCORE_UNREFEXTNO: return "SCORE_UNREFEXTNO";
- case DT_SCORE_HIPAGENO: return "SCORE_HIPAGENO";
- default: return NULL;
- }
-}
-
-static const char *
-get_tic6x_dynamic_type (unsigned long type)
-{
- switch (type)
- {
- case DT_C6000_GSYM_OFFSET: return "C6000_GSYM_OFFSET";
- case DT_C6000_GSTR_OFFSET: return "C6000_GSTR_OFFSET";
- case DT_C6000_DSBT_BASE: return "C6000_DSBT_BASE";
- case DT_C6000_DSBT_SIZE: return "C6000_DSBT_SIZE";
- case DT_C6000_PREEMPTMAP: return "C6000_PREEMPTMAP";
- case DT_C6000_DSBT_INDEX: return "C6000_DSBT_INDEX";
- default: return NULL;
- }
-}
-
-static const char *
-get_nios2_dynamic_type (unsigned long type)
-{
- switch (type)
- {
- case DT_NIOS2_GP: return "NIOS2_GP";
- default: return NULL;
- }
-}
-
-static const char *
-get_solaris_dynamic_type (unsigned long type)
-{
- switch (type)
- {
- case 0x6000000d: return "SUNW_AUXILIARY";
- case 0x6000000e: return "SUNW_RTLDINF";
- case 0x6000000f: return "SUNW_FILTER";
- case 0x60000010: return "SUNW_CAP";
- case 0x60000011: return "SUNW_SYMTAB";
- case 0x60000012: return "SUNW_SYMSZ";
- case 0x60000013: return "SUNW_SORTENT";
- case 0x60000014: return "SUNW_SYMSORT";
- case 0x60000015: return "SUNW_SYMSORTSZ";
- case 0x60000016: return "SUNW_TLSSORT";
- case 0x60000017: return "SUNW_TLSSORTSZ";
- case 0x60000018: return "SUNW_CAPINFO";
- case 0x60000019: return "SUNW_STRPAD";
- case 0x6000001a: return "SUNW_CAPCHAIN";
- case 0x6000001b: return "SUNW_LDMACH";
- case 0x6000001d: return "SUNW_CAPCHAINENT";
- case 0x6000001f: return "SUNW_CAPCHAINSZ";
- case 0x60000021: return "SUNW_PARENT";
- case 0x60000023: return "SUNW_ASLR";
- case 0x60000025: return "SUNW_RELAX";
- case 0x60000029: return "SUNW_NXHEAP";
- case 0x6000002b: return "SUNW_NXSTACK";
-
- case 0x70000001: return "SPARC_REGISTER";
- case 0x7ffffffd: return "AUXILIARY";
- case 0x7ffffffe: return "USED";
- case 0x7fffffff: return "FILTER";
-
- default: return NULL;
- }
-}
-
-static const char *
-get_riscv_dynamic_type (unsigned long type)
-{
- switch (type)
- {
- case DT_RISCV_VARIANT_CC: return "RISCV_VARIANT_CC";
- default:
- return NULL;
- }
-}
-
-static const char *
-get_x86_64_dynamic_type (unsigned long type)
-{
- switch (type)
- {
- case DT_X86_64_PLT:
- return "DT_X86_64_PLT";
- case DT_X86_64_PLTSZ:
- return "DT_X86_64_PLTSZ";
- case DT_X86_64_PLTENT:
- return "DT_X86_64_PLTENT";
- default:
- return NULL;
- }
-}
-
-static const char *
-get_dynamic_type (Filedata * filedata, unsigned long type)
-{
- static char buff[64];
-
- switch (type)
- {
- case DT_NULL: return "NULL";
- case DT_NEEDED: return "NEEDED";
- case DT_PLTRELSZ: return "PLTRELSZ";
- case DT_PLTGOT: return "PLTGOT";
- case DT_HASH: return "HASH";
- case DT_STRTAB: return "STRTAB";
- case DT_SYMTAB: return "SYMTAB";
- case DT_RELA: return "RELA";
- case DT_RELASZ: return "RELASZ";
- case DT_RELAENT: return "RELAENT";
- case DT_STRSZ: return "STRSZ";
- case DT_SYMENT: return "SYMENT";
- case DT_INIT: return "INIT";
- case DT_FINI: return "FINI";
- case DT_SONAME: return "SONAME";
- case DT_RPATH: return "RPATH";
- case DT_SYMBOLIC: return "SYMBOLIC";
- case DT_REL: return "REL";
- case DT_RELSZ: return "RELSZ";
- case DT_RELENT: return "RELENT";
- case DT_RELR: return "RELR";
- case DT_RELRSZ: return "RELRSZ";
- case DT_RELRENT: return "RELRENT";
- case DT_PLTREL: return "PLTREL";
- case DT_DEBUG: return "DEBUG";
- case DT_TEXTREL: return "TEXTREL";
- case DT_JMPREL: return "JMPREL";
- case DT_BIND_NOW: return "BIND_NOW";
- case DT_INIT_ARRAY: return "INIT_ARRAY";
- case DT_FINI_ARRAY: return "FINI_ARRAY";
- case DT_INIT_ARRAYSZ: return "INIT_ARRAYSZ";
- case DT_FINI_ARRAYSZ: return "FINI_ARRAYSZ";
- case DT_RUNPATH: return "RUNPATH";
- case DT_FLAGS: return "FLAGS";
-
- case DT_PREINIT_ARRAY: return "PREINIT_ARRAY";
- case DT_PREINIT_ARRAYSZ: return "PREINIT_ARRAYSZ";
- case DT_SYMTAB_SHNDX: return "SYMTAB_SHNDX";
-
- case DT_CHECKSUM: return "CHECKSUM";
- case DT_PLTPADSZ: return "PLTPADSZ";
- case DT_MOVEENT: return "MOVEENT";
- case DT_MOVESZ: return "MOVESZ";
- case DT_FEATURE: return "FEATURE";
- case DT_POSFLAG_1: return "POSFLAG_1";
- case DT_SYMINSZ: return "SYMINSZ";
- case DT_SYMINENT: return "SYMINENT"; /* aka VALRNGHI */
-
- case DT_ADDRRNGLO: return "ADDRRNGLO";
- case DT_CONFIG: return "CONFIG";
- case DT_DEPAUDIT: return "DEPAUDIT";
- case DT_AUDIT: return "AUDIT";
- case DT_PLTPAD: return "PLTPAD";
- case DT_MOVETAB: return "MOVETAB";
- case DT_SYMINFO: return "SYMINFO"; /* aka ADDRRNGHI */
-
- case DT_VERSYM: return "VERSYM";
-
- case DT_TLSDESC_GOT: return "TLSDESC_GOT";
- case DT_TLSDESC_PLT: return "TLSDESC_PLT";
- case DT_RELACOUNT: return "RELACOUNT";
- case DT_RELCOUNT: return "RELCOUNT";
- case DT_FLAGS_1: return "FLAGS_1";
- case DT_VERDEF: return "VERDEF";
- case DT_VERDEFNUM: return "VERDEFNUM";
- case DT_VERNEED: return "VERNEED";
- case DT_VERNEEDNUM: return "VERNEEDNUM";
-
- case DT_AUXILIARY: return "AUXILIARY";
- case DT_USED: return "USED";
- case DT_FILTER: return "FILTER";
-
- case DT_GNU_PRELINKED: return "GNU_PRELINKED";
- case DT_GNU_CONFLICT: return "GNU_CONFLICT";
- case DT_GNU_CONFLICTSZ: return "GNU_CONFLICTSZ";
- case DT_GNU_LIBLIST: return "GNU_LIBLIST";
- case DT_GNU_LIBLISTSZ: return "GNU_LIBLISTSZ";
- case DT_GNU_HASH: return "GNU_HASH";
- case DT_GNU_FLAGS_1: return "GNU_FLAGS_1";
-
- default:
- if ((type >= DT_LOPROC) && (type <= DT_HIPROC))
- {
- const char * result;
-
- switch (filedata->file_header.e_machine)
- {
- case EM_AARCH64:
- result = get_aarch64_dynamic_type (type);
- break;
- case EM_MIPS:
- case EM_MIPS_RS3_LE:
- result = get_mips_dynamic_type (type);
- break;
- case EM_SPARCV9:
- result = get_sparc64_dynamic_type (type);
- break;
- case EM_PPC:
- result = get_ppc_dynamic_type (type);
- break;
- case EM_PPC64:
- result = get_ppc64_dynamic_type (type);
- break;
- case EM_IA_64:
- result = get_ia64_dynamic_type (type);
- break;
- case EM_ALPHA:
- result = get_alpha_dynamic_type (type);
- break;
- case EM_SCORE:
- result = get_score_dynamic_type (type);
- break;
- case EM_TI_C6000:
- result = get_tic6x_dynamic_type (type);
- break;
- case EM_ALTERA_NIOS2:
- result = get_nios2_dynamic_type (type);
- break;
- case EM_RISCV:
- result = get_riscv_dynamic_type (type);
- break;
- case EM_X86_64:
- result = get_x86_64_dynamic_type (type);
- break;
- default:
- if (filedata->file_header.e_ident[EI_OSABI] == ELFOSABI_SOLARIS)
- result = get_solaris_dynamic_type (type);
- else
- result = NULL;
- break;
- }
-
- if (result != NULL)
- return result;
-
- snprintf (buff, sizeof (buff), _("Processor Specific: %lx"), type);
- }
- else if (((type >= DT_LOOS) && (type <= DT_HIOS))
- || (filedata->file_header.e_machine == EM_PARISC
- && (type >= OLD_DT_LOOS) && (type <= OLD_DT_HIOS)))
- {
- const char * result;
-
- switch (filedata->file_header.e_machine)
- {
- case EM_PARISC:
- result = get_parisc_dynamic_type (type);
- break;
- case EM_IA_64:
- result = get_ia64_dynamic_type (type);
- break;
- default:
- if (filedata->file_header.e_ident[EI_OSABI] == ELFOSABI_SOLARIS)
- result = get_solaris_dynamic_type (type);
- else
- result = NULL;
- break;
- }
-
- if (result != NULL)
- return result;
-
- snprintf (buff, sizeof (buff), _("Operating System specific: %lx"),
- type);
- }
- else
- snprintf (buff, sizeof (buff), _("<unknown>: %lx"), type);
-
- return buff;
- }
-}
-
-static bool get_program_headers (Filedata *);
-static bool get_dynamic_section (Filedata *);
-
-static void
-locate_dynamic_section (Filedata *filedata)
-{
- uint64_t dynamic_addr = 0;
- uint64_t dynamic_size = 0;
-
- if (filedata->file_header.e_phnum != 0
- && get_program_headers (filedata))
- {
- Elf_Internal_Phdr *segment;
- unsigned int i;
-
- for (i = 0, segment = filedata->program_headers;
- i < filedata->file_header.e_phnum;
- i++, segment++)
- {
- if (segment->p_type == PT_DYNAMIC)
- {
- dynamic_addr = segment->p_offset;
- dynamic_size = segment->p_filesz;
-
- if (filedata->section_headers != NULL)
- {
- Elf_Internal_Shdr *sec;
-
- sec = find_section (filedata, ".dynamic");
- if (sec != NULL)
- {
- if (sec->sh_size == 0
- || sec->sh_type == SHT_NOBITS)
- {
- dynamic_addr = 0;
- dynamic_size = 0;
- }
- else
- {
- dynamic_addr = sec->sh_offset;
- dynamic_size = sec->sh_size;
- }
- }
- }
-
- if (dynamic_addr > filedata->file_size
- || (dynamic_size > filedata->file_size - dynamic_addr))
- {
- dynamic_addr = 0;
- dynamic_size = 0;
- }
- break;
- }
- }
- }
- filedata->dynamic_addr = dynamic_addr;
- filedata->dynamic_size = dynamic_size ? dynamic_size : 1;
-}
-
-static bool
-is_pie (Filedata *filedata)
-{
- Elf_Internal_Dyn *entry;
-
- if (filedata->dynamic_size == 0)
- locate_dynamic_section (filedata);
- if (filedata->dynamic_size <= 1)
- return false;
-
- if (!get_dynamic_section (filedata))
- return false;
-
- for (entry = filedata->dynamic_section;
- entry < filedata->dynamic_section + filedata->dynamic_nent;
- entry++)
- {
- if (entry->d_tag == DT_FLAGS_1)
- {
- if ((entry->d_un.d_val & DF_1_PIE) != 0)
- return true;
- break;
- }
- }
- return false;
-}
-
-static char *
-get_file_type (Filedata *filedata)
-{
- unsigned e_type = filedata->file_header.e_type;
- static char buff[64];
-
- switch (e_type)
- {
- case ET_NONE: return _("NONE (None)");
- case ET_REL: return _("REL (Relocatable file)");
- case ET_EXEC: return _("EXEC (Executable file)");
- case ET_DYN:
- if (is_pie (filedata))
- return _("DYN (Position-Independent Executable file)");
- else
- return _("DYN (Shared object file)");
- case ET_CORE: return _("CORE (Core file)");
-
- default:
- if ((e_type >= ET_LOPROC) && (e_type <= ET_HIPROC))
- snprintf (buff, sizeof (buff), _("Processor Specific: (%x)"), e_type);
- else if ((e_type >= ET_LOOS) && (e_type <= ET_HIOS))
- snprintf (buff, sizeof (buff), _("OS Specific: (%x)"), e_type);
- else
- snprintf (buff, sizeof (buff), _("<unknown>: %x"), e_type);
- return buff;
- }
-}
-
-static char *
-get_machine_name (unsigned e_machine)
-{
- static char buff[64]; /* XXX */
-
- switch (e_machine)
- {
- /* Please keep this switch table sorted by increasing EM_ value. */
- /* 0 */
- case EM_NONE: return _("None");
- case EM_M32: return "WE32100";
- case EM_SPARC: return "Sparc";
- case EM_386: return "Intel 80386";
- case EM_68K: return "MC68000";
- case EM_88K: return "MC88000";
- case EM_IAMCU: return "Intel MCU";
- case EM_860: return "Intel 80860";
- case EM_MIPS: return "MIPS R3000";
- case EM_S370: return "IBM System/370";
- /* 10 */
- case EM_MIPS_RS3_LE: return "MIPS R4000 big-endian";
- case EM_OLD_SPARCV9: return "Sparc v9 (old)";
- case EM_PARISC: return "HPPA";
- case EM_VPP550: return "Fujitsu VPP500";
- case EM_SPARC32PLUS: return "Sparc v8+" ;
- case EM_960: return "Intel 80960";
- case EM_PPC: return "PowerPC";
- /* 20 */
- case EM_PPC64: return "PowerPC64";
- case EM_S390_OLD:
- case EM_S390: return "IBM S/390";
- case EM_SPU: return "SPU";
- /* 30 */
- case EM_V800: return "Renesas V850 (using RH850 ABI)";
- case EM_FR20: return "Fujitsu FR20";
- case EM_RH32: return "TRW RH32";
- case EM_MCORE: return "MCORE";
- /* 40 */
- case EM_ARM: return "ARM";
- case EM_OLD_ALPHA: return "Digital Alpha (old)";
- case EM_SH: return "Renesas / SuperH SH";
- case EM_SPARCV9: return "Sparc v9";
- case EM_TRICORE: return "Siemens Tricore";
- case EM_ARC: return "ARC";
- case EM_H8_300: return "Renesas H8/300";
- case EM_H8_300H: return "Renesas H8/300H";
- case EM_H8S: return "Renesas H8S";
- case EM_H8_500: return "Renesas H8/500";
- /* 50 */
- case EM_IA_64: return "Intel IA-64";
- case EM_MIPS_X: return "Stanford MIPS-X";
- case EM_COLDFIRE: return "Motorola Coldfire";
- case EM_68HC12: return "Motorola MC68HC12 Microcontroller";
- case EM_MMA: return "Fujitsu Multimedia Accelerator";
- case EM_PCP: return "Siemens PCP";
- case EM_NCPU: return "Sony nCPU embedded RISC processor";
- case EM_NDR1: return "Denso NDR1 microprocessor";
- case EM_STARCORE: return "Motorola Star*Core processor";
- case EM_ME16: return "Toyota ME16 processor";
- /* 60 */
- case EM_ST100: return "STMicroelectronics ST100 processor";
- case EM_TINYJ: return "Advanced Logic Corp. TinyJ embedded processor";
- case EM_X86_64: return "Advanced Micro Devices X86-64";
- case EM_PDSP: return "Sony DSP processor";
- case EM_PDP10: return "Digital Equipment Corp. PDP-10";
- case EM_PDP11: return "Digital Equipment Corp. PDP-11";
- case EM_FX66: return "Siemens FX66 microcontroller";
- case EM_ST9PLUS: return "STMicroelectronics ST9+ 8/16 bit microcontroller";
- case EM_ST7: return "STMicroelectronics ST7 8-bit microcontroller";
- case EM_68HC16: return "Motorola MC68HC16 Microcontroller";
- /* 70 */
- case EM_68HC11: return "Motorola MC68HC11 Microcontroller";
- case EM_68HC08: return "Motorola MC68HC08 Microcontroller";
- case EM_68HC05: return "Motorola MC68HC05 Microcontroller";
- case EM_SVX: return "Silicon Graphics SVx";
- case EM_ST19: return "STMicroelectronics ST19 8-bit microcontroller";
- case EM_VAX: return "Digital VAX";
- case EM_CRIS: return "Axis Communications 32-bit embedded processor";
- case EM_JAVELIN: return "Infineon Technologies 32-bit embedded cpu";
- case EM_FIREPATH: return "Element 14 64-bit DSP processor";
- case EM_ZSP: return "LSI Logic's 16-bit DSP processor";
- /* 80 */
- case EM_MMIX: return "Donald Knuth's educational 64-bit processor";
- case EM_HUANY: return "Harvard Universitys's machine-independent object format";
- case EM_PRISM: return "Vitesse Prism";
- case EM_AVR_OLD:
- case EM_AVR: return "Atmel AVR 8-bit microcontroller";
- case EM_CYGNUS_FR30:
- case EM_FR30: return "Fujitsu FR30";
- case EM_CYGNUS_D10V:
- case EM_D10V: return "d10v";
- case EM_CYGNUS_D30V:
- case EM_D30V: return "d30v";
- case EM_CYGNUS_V850:
- case EM_V850: return "Renesas V850";
- case EM_CYGNUS_M32R:
- case EM_M32R: return "Renesas M32R (formerly Mitsubishi M32r)";
- case EM_CYGNUS_MN10300:
- case EM_MN10300: return "mn10300";
- /* 90 */
- case EM_CYGNUS_MN10200:
- case EM_MN10200: return "mn10200";
- case EM_PJ: return "picoJava";
- case EM_OR1K: return "OpenRISC 1000";
- case EM_ARC_COMPACT: return "ARCompact";
- case EM_XTENSA_OLD:
- case EM_XTENSA: return "Tensilica Xtensa Processor";
- case EM_VIDEOCORE: return "Alphamosaic VideoCore processor";
- case EM_TMM_GPP: return "Thompson Multimedia General Purpose Processor";
- case EM_NS32K: return "National Semiconductor 32000 series";
- case EM_TPC: return "Tenor Network TPC processor";
- case EM_SNP1K: return "Trebia SNP 1000 processor";
- /* 100 */
- case EM_ST200: return "STMicroelectronics ST200 microcontroller";
- case EM_IP2K_OLD:
- case EM_IP2K: return "Ubicom IP2xxx 8-bit microcontrollers";
- case EM_MAX: return "MAX Processor";
- case EM_CR: return "National Semiconductor CompactRISC";
- case EM_F2MC16: return "Fujitsu F2MC16";
- case EM_MSP430: return "Texas Instruments msp430 microcontroller";
- case EM_BLACKFIN: return "Analog Devices Blackfin";
- case EM_SE_C33: return "S1C33 Family of Seiko Epson processors";
- case EM_SEP: return "Sharp embedded microprocessor";
- case EM_ARCA: return "Arca RISC microprocessor";
- /* 110 */
- case EM_UNICORE: return "Unicore";
- case EM_EXCESS: return "eXcess 16/32/64-bit configurable embedded CPU";
- case EM_DXP: return "Icera Semiconductor Inc. Deep Execution Processor";
- case EM_ALTERA_NIOS2: return "Altera Nios II";
- case EM_CRX: return "National Semiconductor CRX microprocessor";
- case EM_XGATE: return "Motorola XGATE embedded processor";
- case EM_C166:
- case EM_XC16X: return "Infineon Technologies xc16x";
- case EM_M16C: return "Renesas M16C series microprocessors";
- case EM_DSPIC30F: return "Microchip Technology dsPIC30F Digital Signal Controller";
- case EM_CE: return "Freescale Communication Engine RISC core";
- /* 120 */
- case EM_M32C: return "Renesas M32c";
- /* 130 */
- case EM_TSK3000: return "Altium TSK3000 core";
- case EM_RS08: return "Freescale RS08 embedded processor";
- case EM_ECOG2: return "Cyan Technology eCOG2 microprocessor";
- case EM_SCORE: return "SUNPLUS S+Core";
- case EM_DSP24: return "New Japan Radio (NJR) 24-bit DSP Processor";
- case EM_VIDEOCORE3: return "Broadcom VideoCore III processor";
- case EM_LATTICEMICO32: return "Lattice Mico32";
- case EM_SE_C17: return "Seiko Epson C17 family";
- /* 140 */
- case EM_TI_C6000: return "Texas Instruments TMS320C6000 DSP family";
- case EM_TI_C2000: return "Texas Instruments TMS320C2000 DSP family";
- case EM_TI_C5500: return "Texas Instruments TMS320C55x DSP family";
- case EM_TI_PRU: return "TI PRU I/O processor";
- /* 160 */
- case EM_MMDSP_PLUS: return "STMicroelectronics 64bit VLIW Data Signal Processor";
- case EM_CYPRESS_M8C: return "Cypress M8C microprocessor";
- case EM_R32C: return "Renesas R32C series microprocessors";
- case EM_TRIMEDIA: return "NXP Semiconductors TriMedia architecture family";
- case EM_QDSP6: return "QUALCOMM DSP6 Processor";
- case EM_8051: return "Intel 8051 and variants";
- case EM_STXP7X: return "STMicroelectronics STxP7x family";
- case EM_NDS32: return "Andes Technology compact code size embedded RISC processor family";
- case EM_ECOG1X: return "Cyan Technology eCOG1X family";
- case EM_MAXQ30: return "Dallas Semiconductor MAXQ30 Core microcontrollers";
- /* 170 */
- case EM_XIMO16: return "New Japan Radio (NJR) 16-bit DSP Processor";
- case EM_MANIK: return "M2000 Reconfigurable RISC Microprocessor";
- case EM_CRAYNV2: return "Cray Inc. NV2 vector architecture";
- case EM_RX: return "Renesas RX";
- case EM_METAG: return "Imagination Technologies Meta processor architecture";
- case EM_MCST_ELBRUS: return "MCST Elbrus general purpose hardware architecture";
- case EM_ECOG16: return "Cyan Technology eCOG16 family";
- case EM_CR16:
- case EM_MICROBLAZE:
- case EM_MICROBLAZE_OLD: return "Xilinx MicroBlaze";
- case EM_ETPU: return "Freescale Extended Time Processing Unit";
- case EM_SLE9X: return "Infineon Technologies SLE9X core";
- /* 180 */
- case EM_L1OM: return "Intel L1OM";
- case EM_K1OM: return "Intel K1OM";
- case EM_INTEL182: return "Intel (reserved)";
- case EM_AARCH64: return "AArch64";
- case EM_ARM184: return "ARM (reserved)";
- case EM_AVR32: return "Atmel Corporation 32-bit microprocessor";
- case EM_STM8: return "STMicroeletronics STM8 8-bit microcontroller";
- case EM_TILE64: return "Tilera TILE64 multicore architecture family";
- case EM_TILEPRO: return "Tilera TILEPro multicore architecture family";
- /* 190 */
- case EM_CUDA: return "NVIDIA CUDA architecture";
- case EM_TILEGX: return "Tilera TILE-Gx multicore architecture family";
- case EM_CLOUDSHIELD: return "CloudShield architecture family";
- case EM_COREA_1ST: return "KIPO-KAIST Core-A 1st generation processor family";
- case EM_COREA_2ND: return "KIPO-KAIST Core-A 2nd generation processor family";
- case EM_ARC_COMPACT2: return "ARCv2";
- case EM_OPEN8: return "Open8 8-bit RISC soft processor core";
- case EM_RL78: return "Renesas RL78";
- case EM_VIDEOCORE5: return "Broadcom VideoCore V processor";
- case EM_78K0R: return "Renesas 78K0R";
- /* 200 */
- case EM_56800EX: return "Freescale 56800EX Digital Signal Controller (DSC)";
- case EM_BA1: return "Beyond BA1 CPU architecture";
- case EM_BA2: return "Beyond BA2 CPU architecture";
- case EM_XCORE: return "XMOS xCORE processor family";
- case EM_MCHP_PIC: return "Microchip 8-bit PIC(r) family";
- case EM_INTELGT: return "Intel Graphics Technology";
- /* 210 */
- case EM_KM32: return "KM211 KM32 32-bit processor";
- case EM_KMX32: return "KM211 KMX32 32-bit processor";
- case EM_KMX16: return "KM211 KMX16 16-bit processor";
- case EM_KMX8: return "KM211 KMX8 8-bit processor";
- case EM_KVARC: return "KM211 KVARC processor";
- case EM_CDP: return "Paneve CDP architecture family";
- case EM_COGE: return "Cognitive Smart Memory Processor";
- case EM_COOL: return "Bluechip Systems CoolEngine";
- case EM_NORC: return "Nanoradio Optimized RISC";
- case EM_CSR_KALIMBA: return "CSR Kalimba architecture family";
- /* 220 */
- case EM_Z80: return "Zilog Z80";
- case EM_VISIUM: return "CDS VISIUMcore processor";
- case EM_FT32: return "FTDI Chip FT32";
- case EM_MOXIE: return "Moxie";
- case EM_AMDGPU: return "AMD GPU";
- /* 230 (all reserved) */
- /* 240 */
- case EM_RISCV: return "RISC-V";
- case EM_LANAI: return "Lanai 32-bit processor";
- case EM_CEVA: return "CEVA Processor Architecture Family";
- case EM_CEVA_X2: return "CEVA X2 Processor Family";
- case EM_BPF: return "Linux BPF";
- case EM_GRAPHCORE_IPU: return "Graphcore Intelligent Processing Unit";
- case EM_IMG1: return "Imagination Technologies";
- /* 250 */
- case EM_NFP: return "Netronome Flow Processor";
- case EM_VE: return "NEC Vector Engine";
- case EM_CSKY: return "C-SKY";
- case EM_ARC_COMPACT3_64: return "Synopsys ARCv3 64-bit processor";
- case EM_MCS6502: return "MOS Technology MCS 6502 processor";
- case EM_ARC_COMPACT3: return "Synopsys ARCv3 32-bit processor";
- case EM_KVX: return "Kalray VLIW core of the MPPA processor family";
- case EM_65816: return "WDC 65816/65C816";
- case EM_LOONGARCH: return "LoongArch";
- case EM_KF32: return "ChipON KungFu32";
-
- /* Large numbers... */
- case EM_MT: return "Morpho Techologies MT processor";
- case EM_ALPHA: return "Alpha";
- case EM_WEBASSEMBLY: return "Web Assembly";
- case EM_DLX: return "OpenDLX";
- case EM_XSTORMY16: return "Sanyo XStormy16 CPU core";
- case EM_IQ2000: return "Vitesse IQ2000";
- case EM_M32C_OLD:
- case EM_NIOS32: return "Altera Nios";
- case EM_CYGNUS_MEP: return "Toshiba MeP Media Engine";
- case EM_ADAPTEVA_EPIPHANY: return "Adapteva EPIPHANY";
- case EM_CYGNUS_FRV: return "Fujitsu FR-V";
- case EM_S12Z: return "Freescale S12Z";
-
- default:
- snprintf (buff, sizeof (buff), _("<unknown>: 0x%x"), e_machine);
- return buff;
- }
-}
-
-static char *
-decode_ARC_machine_flags (char *out, unsigned e_flags, unsigned e_machine)
-{
- /* ARC has two machine types EM_ARC_COMPACT and EM_ARC_COMPACT2. Some
- other compilers don't specify an architecture type in the e_flags, and
- instead use EM_ARC_COMPACT for old ARC600, ARC601, and ARC700
- architectures, and switch to EM_ARC_COMPACT2 for newer ARCEM and ARCHS
- architectures.
-
- Th GNU tools follows this use of EM_ARC_COMPACT and EM_ARC_COMPACT2,
- but also sets a specific architecture type in the e_flags field.
-
- However, when decoding the flags we don't worry if we see an
- unexpected pairing, for example EM_ARC_COMPACT machine type, with
- ARCEM architecture type. */
-
- switch (e_flags & EF_ARC_MACH_MSK)
- {
- /* We only expect these to occur for EM_ARC_COMPACT2. */
- case EF_ARC_CPU_ARCV2EM:
- out = stpcpy (out, ", ARC EM");
- break;
- case EF_ARC_CPU_ARCV2HS:
- out = stpcpy (out, ", ARC HS");
- break;
-
- /* We only expect these to occur for EM_ARC_COMPACT. */
- case E_ARC_MACH_ARC600:
- out = stpcpy (out, ", ARC600");
- break;
- case E_ARC_MACH_ARC601:
- out = stpcpy (out, ", ARC601");
- break;
- case E_ARC_MACH_ARC700:
- out = stpcpy (out, ", ARC700");
- break;
-
- /* The only times we should end up here are (a) A corrupt ELF, (b) A
- new ELF with new architecture being read by an old version of
- readelf, or (c) An ELF built with non-GNU compiler that does not
- set the architecture in the e_flags. */
- default:
- if (e_machine == EM_ARC_COMPACT)
- out = stpcpy (out, ", Unknown ARCompact");
- else
- out = stpcpy (out, ", Unknown ARC");
- break;
- }
-
- switch (e_flags & EF_ARC_OSABI_MSK)
- {
- case E_ARC_OSABI_ORIG:
- out = stpcpy (out, ", (ABI:legacy)");
- break;
- case E_ARC_OSABI_V2:
- out = stpcpy (out, ", (ABI:v2)");
- break;
- /* Only upstream 3.9+ kernels will support ARCv2 ISA. */
- case E_ARC_OSABI_V3:
- out = stpcpy (out, ", v3 no-legacy-syscalls ABI");
- break;
- case E_ARC_OSABI_V4:
- out = stpcpy (out, ", v4 ABI");
- break;
- default:
- out = stpcpy (out, ", unrecognised ARC OSABI flag");
- break;
- }
- return out;
-}
-
-static char *
-decode_ARM_machine_flags (char *out, unsigned e_flags)
-{
- unsigned eabi;
- bool unknown = false;
-
- eabi = EF_ARM_EABI_VERSION (e_flags);
- e_flags &= ~ EF_ARM_EABIMASK;
-
- /* Handle "generic" ARM flags. */
- if (e_flags & EF_ARM_RELEXEC)
- {
- out = stpcpy (out, ", relocatable executable");
- e_flags &= ~ EF_ARM_RELEXEC;
- }
-
- if (e_flags & EF_ARM_PIC)
- {
- out = stpcpy (out, ", position independent");
- e_flags &= ~ EF_ARM_PIC;
- }
-
- /* Now handle EABI specific flags. */
- switch (eabi)
- {
- default:
- out = stpcpy (out, ", <unrecognized EABI>");
- if (e_flags)
- unknown = true;
- break;
-
- case EF_ARM_EABI_VER1:
- out = stpcpy (out, ", Version1 EABI");
- while (e_flags)
- {
- unsigned flag;
-
- /* Process flags one bit at a time. */
- flag = e_flags & - e_flags;
- e_flags &= ~ flag;
-
- switch (flag)
- {
- case EF_ARM_SYMSARESORTED: /* Conflicts with EF_ARM_INTERWORK. */
- out = stpcpy (out, ", sorted symbol tables");
- break;
-
- default:
- unknown = true;
- break;
- }
- }
- break;
-
- case EF_ARM_EABI_VER2:
- out = stpcpy (out, ", Version2 EABI");
- while (e_flags)
- {
- unsigned flag;
-
- /* Process flags one bit at a time. */
- flag = e_flags & - e_flags;
- e_flags &= ~ flag;
-
- switch (flag)
- {
- case EF_ARM_SYMSARESORTED: /* Conflicts with EF_ARM_INTERWORK. */
- out = stpcpy (out, ", sorted symbol tables");
- break;
-
- case EF_ARM_DYNSYMSUSESEGIDX:
- out = stpcpy (out, ", dynamic symbols use segment index");
- break;
-
- case EF_ARM_MAPSYMSFIRST:
- out = stpcpy (out, ", mapping symbols precede others");
- break;
-
- default:
- unknown = true;
- break;
- }
- }
- break;
-
- case EF_ARM_EABI_VER3:
- out = stpcpy (out, ", Version3 EABI");
- break;
-
- case EF_ARM_EABI_VER4:
- out = stpcpy (out, ", Version4 EABI");
- while (e_flags)
- {
- unsigned flag;
-
- /* Process flags one bit at a time. */
- flag = e_flags & - e_flags;
- e_flags &= ~ flag;
-
- switch (flag)
- {
- case EF_ARM_BE8:
- out = stpcpy (out, ", BE8");
- break;
-
- case EF_ARM_LE8:
- out = stpcpy (out, ", LE8");
- break;
-
- default:
- unknown = true;
- break;
- }
- }
- break;
-
- case EF_ARM_EABI_VER5:
- out = stpcpy (out, ", Version5 EABI");
- while (e_flags)
- {
- unsigned flag;
-
- /* Process flags one bit at a time. */
- flag = e_flags & - e_flags;
- e_flags &= ~ flag;
-
- switch (flag)
- {
- case EF_ARM_BE8:
- out = stpcpy (out, ", BE8");
- break;
-
- case EF_ARM_LE8:
- out = stpcpy (out, ", LE8");
- break;
-
- case EF_ARM_ABI_FLOAT_SOFT: /* Conflicts with EF_ARM_SOFT_FLOAT. */
- out = stpcpy (out, ", soft-float ABI");
- break;
-
- case EF_ARM_ABI_FLOAT_HARD: /* Conflicts with EF_ARM_VFP_FLOAT. */
- out = stpcpy (out, ", hard-float ABI");
- break;
-
- default:
- unknown = true;
- break;
- }
- }
- break;
-
- case EF_ARM_EABI_UNKNOWN:
- out = stpcpy (out, ", GNU EABI");
- while (e_flags)
- {
- unsigned flag;
-
- /* Process flags one bit at a time. */
- flag = e_flags & - e_flags;
- e_flags &= ~ flag;
-
- switch (flag)
- {
- case EF_ARM_INTERWORK:
- out = stpcpy (out, ", interworking enabled");
- break;
-
- case EF_ARM_APCS_26:
- out = stpcpy (out, ", uses APCS/26");
- break;
-
- case EF_ARM_APCS_FLOAT:
- out = stpcpy (out, ", uses APCS/float");
- break;
-
- case EF_ARM_PIC:
- out = stpcpy (out, ", position independent");
- break;
-
- case EF_ARM_ALIGN8:
- out = stpcpy (out, ", 8 bit structure alignment");
- break;
-
- case EF_ARM_NEW_ABI:
- out = stpcpy (out, ", uses new ABI");
- break;
-
- case EF_ARM_OLD_ABI:
- out = stpcpy (out, ", uses old ABI");
- break;
-
- case EF_ARM_SOFT_FLOAT:
- out = stpcpy (out, ", software FP");
- break;
-
- case EF_ARM_VFP_FLOAT:
- out = stpcpy (out, ", VFP");
- break;
-
- default:
- unknown = true;
- break;
- }
- }
- }
-
- if (unknown)
- out = stpcpy (out,_(", <unknown>"));
- return out;
-}
-
-static char *
-decode_AVR_machine_flags (char *out, unsigned e_flags)
-{
- switch (e_flags & EF_AVR_MACH)
- {
- case E_AVR_MACH_AVR1:
- out = stpcpy (out, ", avr:1");
- break;
- case E_AVR_MACH_AVR2:
- out = stpcpy (out, ", avr:2");
- break;
- case E_AVR_MACH_AVR25:
- out = stpcpy (out, ", avr:25");
- break;
- case E_AVR_MACH_AVR3:
- out = stpcpy (out, ", avr:3");
- break;
- case E_AVR_MACH_AVR31:
- out = stpcpy (out, ", avr:31");
- break;
- case E_AVR_MACH_AVR35:
- out = stpcpy (out, ", avr:35");
- break;
- case E_AVR_MACH_AVR4:
- out = stpcpy (out, ", avr:4");
- break;
- case E_AVR_MACH_AVR5:
- out = stpcpy (out, ", avr:5");
- break;
- case E_AVR_MACH_AVR51:
- out = stpcpy (out, ", avr:51");
- break;
- case E_AVR_MACH_AVR6:
- out = stpcpy (out, ", avr:6");
- break;
- case E_AVR_MACH_AVRTINY:
- out = stpcpy (out, ", avr:100");
- break;
- case E_AVR_MACH_XMEGA1:
- out = stpcpy (out, ", avr:101");
- break;
- case E_AVR_MACH_XMEGA2:
- out = stpcpy (out, ", avr:102");
- break;
- case E_AVR_MACH_XMEGA3:
- out = stpcpy (out, ", avr:103");
- break;
- case E_AVR_MACH_XMEGA4:
- out = stpcpy (out, ", avr:104");
- break;
- case E_AVR_MACH_XMEGA5:
- out = stpcpy (out, ", avr:105");
- break;
- case E_AVR_MACH_XMEGA6:
- out = stpcpy (out, ", avr:106");
- break;
- case E_AVR_MACH_XMEGA7:
- out = stpcpy (out, ", avr:107");
- break;
- default:
- out = stpcpy (out, ", avr:<unknown>");
- break;
- }
-
- if (e_flags & EF_AVR_LINKRELAX_PREPARED)
- out = stpcpy (out, ", link-relax");
- return out;
-}
-
-static char *
-decode_BLACKFIN_machine_flags (char *out, unsigned e_flags)
-{
- if (e_flags & EF_BFIN_PIC)
- out = stpcpy (out, ", PIC");
-
- if (e_flags & EF_BFIN_FDPIC)
- out = stpcpy (out, ", FDPIC");
-
- if (e_flags & EF_BFIN_CODE_IN_L1)
- out = stpcpy (out, ", code in L1");
-
- if (e_flags & EF_BFIN_DATA_IN_L1)
- out = stpcpy (out, ", data in L1");
- return out;
-}
-
-static char *
-decode_FRV_machine_flags (char *out, unsigned e_flags)
-{
- switch (e_flags & EF_FRV_CPU_MASK)
- {
- case EF_FRV_CPU_GENERIC:
- break;
-
- default:
- out = stpcpy (out, ", fr???");
- break;
-
- case EF_FRV_CPU_FR300:
- out = stpcpy (out, ", fr300");
- break;
-
- case EF_FRV_CPU_FR400:
- out = stpcpy (out, ", fr400");
- break;
- case EF_FRV_CPU_FR405:
- out = stpcpy (out, ", fr405");
- break;
-
- case EF_FRV_CPU_FR450:
- out = stpcpy (out, ", fr450");
- break;
-
- case EF_FRV_CPU_FR500:
- out = stpcpy (out, ", fr500");
- break;
- case EF_FRV_CPU_FR550:
- out = stpcpy (out, ", fr550");
- break;
-
- case EF_FRV_CPU_SIMPLE:
- out = stpcpy (out, ", simple");
- break;
- case EF_FRV_CPU_TOMCAT:
- out = stpcpy (out, ", tomcat");
- break;
- }
- return out;
-}
-
-static char *
-decode_IA64_machine_flags (char *out, unsigned e_flags, Filedata *filedata)
-{
- if ((e_flags & EF_IA_64_ABI64))
- out = stpcpy (out, ", 64-bit");
- else
- out = stpcpy (out, ", 32-bit");
- if ((e_flags & EF_IA_64_REDUCEDFP))
- out = stpcpy (out, ", reduced fp model");
- if ((e_flags & EF_IA_64_NOFUNCDESC_CONS_GP))
- out = stpcpy (out, ", no function descriptors, constant gp");
- else if ((e_flags & EF_IA_64_CONS_GP))
- out = stpcpy (out, ", constant gp");
- if ((e_flags & EF_IA_64_ABSOLUTE))
- out = stpcpy (out, ", absolute");
- if (filedata->file_header.e_ident[EI_OSABI] == ELFOSABI_OPENVMS)
- {
- if ((e_flags & EF_IA_64_VMS_LINKAGES))
- out = stpcpy (out, ", vms_linkages");
- switch ((e_flags & EF_IA_64_VMS_COMCOD))
- {
- case EF_IA_64_VMS_COMCOD_SUCCESS:
- break;
- case EF_IA_64_VMS_COMCOD_WARNING:
- out = stpcpy (out, ", warning");
- break;
- case EF_IA_64_VMS_COMCOD_ERROR:
- out = stpcpy (out, ", error");
- break;
- case EF_IA_64_VMS_COMCOD_ABORT:
- out = stpcpy (out, ", abort");
- break;
- default:
- warn (_("Unrecognised IA64 VMS Command Code: %x\n"),
- e_flags & EF_IA_64_VMS_COMCOD);
- out = stpcpy (out, ", <unknown>");
- }
- }
- return out;
-}
-
-static char *
-decode_LOONGARCH_machine_flags (char *out, unsigned int e_flags)
-{
- if (EF_LOONGARCH_IS_SOFT_FLOAT (e_flags))
- out = stpcpy (out, ", SOFT-FLOAT");
- else if (EF_LOONGARCH_IS_SINGLE_FLOAT (e_flags))
- out = stpcpy (out, ", SINGLE-FLOAT");
- else if (EF_LOONGARCH_IS_DOUBLE_FLOAT (e_flags))
- out = stpcpy (out, ", DOUBLE-FLOAT");
-
- if (EF_LOONGARCH_IS_OBJ_V0 (e_flags))
- out = stpcpy (out, ", OBJ-v0");
- else if (EF_LOONGARCH_IS_OBJ_V1 (e_flags))
- out = stpcpy (out, ", OBJ-v1");
- return out;
-}
-
-static char *
-decode_M68K_machine_flags (char *out, unsigned int e_flags)
-{
- if ((e_flags & EF_M68K_ARCH_MASK) == EF_M68K_M68000)
- out = stpcpy (out, ", m68000");
- else if ((e_flags & EF_M68K_ARCH_MASK) == EF_M68K_CPU32)
- out = stpcpy (out, ", cpu32");
- else if ((e_flags & EF_M68K_ARCH_MASK) == EF_M68K_FIDO)
- out = stpcpy (out, ", fido_a");
- else
- {
- char const *isa = _("unknown");
- char const *mac = _("unknown mac");
- char const *additional = NULL;
-
- switch (e_flags & EF_M68K_CF_ISA_MASK)
- {
- case EF_M68K_CF_ISA_A_NODIV:
- isa = "A";
- additional = ", nodiv";
- break;
- case EF_M68K_CF_ISA_A:
- isa = "A";
- break;
- case EF_M68K_CF_ISA_A_PLUS:
- isa = "A+";
- break;
- case EF_M68K_CF_ISA_B_NOUSP:
- isa = "B";
- additional = ", nousp";
- break;
- case EF_M68K_CF_ISA_B:
- isa = "B";
- break;
- case EF_M68K_CF_ISA_C:
- isa = "C";
- break;
- case EF_M68K_CF_ISA_C_NODIV:
- isa = "C";
- additional = ", nodiv";
- break;
- }
- out = stpcpy (out, ", cf, isa ");
- out = stpcpy (out, isa);
- if (additional)
- out = stpcpy (out, additional);
- if (e_flags & EF_M68K_CF_FLOAT)
- out = stpcpy (out, ", float");
- switch (e_flags & EF_M68K_CF_MAC_MASK)
- {
- case 0:
- mac = NULL;
- break;
- case EF_M68K_CF_MAC:
- mac = "mac";
- break;
- case EF_M68K_CF_EMAC:
- mac = "emac";
- break;
- case EF_M68K_CF_EMAC_B:
- mac = "emac_b";
- break;
- }
- if (mac)
- {
- out = stpcpy (out, ", ");
- out = stpcpy (out, mac);
- }
- }
- return out;
-}
-
-static char *
-decode_MeP_machine_flags (char *out, unsigned int e_flags)
-{
- switch (e_flags & EF_MEP_CPU_MASK)
- {
- case EF_MEP_CPU_MEP:
- out = stpcpy (out, ", generic MeP");
- break;
- case EF_MEP_CPU_C2:
- out = stpcpy (out, ", MeP C2");
- break;
- case EF_MEP_CPU_C3:
- out = stpcpy (out, ", MeP C3");
- break;
- case EF_MEP_CPU_C4:
- out = stpcpy (out, ", MeP C4");
- break;
- case EF_MEP_CPU_C5:
- out = stpcpy (out, ", MeP C5");
- break;
- case EF_MEP_CPU_H1:
- out = stpcpy (out, ", MeP H1");
- break;
- default:
- out = stpcpy (out, _(", <unknown MeP cpu type>"));
- break;
- }
-
- switch (e_flags & EF_MEP_COP_MASK)
- {
- case EF_MEP_COP_NONE:
- break;
- case EF_MEP_COP_AVC:
- out = stpcpy (out, ", AVC coprocessor");
- break;
- case EF_MEP_COP_AVC2:
- out = stpcpy (out, ", AVC2 coprocessor");
- break;
- case EF_MEP_COP_FMAX:
- out = stpcpy (out, ", FMAX coprocessor");
- break;
- case EF_MEP_COP_IVC2:
- out = stpcpy (out, ", IVC2 coprocessor");
- break;
- default:
- out = stpcpy (out, _("<unknown MeP copro type>"));
- break;
- }
-
- if (e_flags & EF_MEP_LIBRARY)
- out = stpcpy (out, ", Built for Library");
-
- if (e_flags & EF_MEP_INDEX_MASK)
- out += sprintf (out, ", Configuration Index: %#x",
- e_flags & EF_MEP_INDEX_MASK);
-
- if (e_flags & ~ EF_MEP_ALL_FLAGS)
- out += sprintf (out, _(", unknown flags bits: %#x"),
- e_flags & ~ EF_MEP_ALL_FLAGS);
- return out;
-}
-
-static char *
-decode_MIPS_machine_flags (char *out, unsigned int e_flags)
-{
- if (e_flags & EF_MIPS_NOREORDER)
- out = stpcpy (out, ", noreorder");
-
- if (e_flags & EF_MIPS_PIC)
- out = stpcpy (out, ", pic");
-
- if (e_flags & EF_MIPS_CPIC)
- out = stpcpy (out, ", cpic");
-
- if (e_flags & EF_MIPS_UCODE)
- out = stpcpy (out, ", ugen_reserved");
-
- if (e_flags & EF_MIPS_ABI2)
- out = stpcpy (out, ", abi2");
-
- if (e_flags & EF_MIPS_OPTIONS_FIRST)
- out = stpcpy (out, ", odk first");
-
- if (e_flags & EF_MIPS_32BITMODE)
- out = stpcpy (out, ", 32bitmode");
-
- if (e_flags & EF_MIPS_NAN2008)
- out = stpcpy (out, ", nan2008");
-
- if (e_flags & EF_MIPS_FP64)
- out = stpcpy (out, ", fp64");
-
- switch ((e_flags & EF_MIPS_MACH))
- {
- case EF_MIPS_MACH_3900:
- out = stpcpy (out, ", 3900");
- break;
- case EF_MIPS_MACH_4010:
- out = stpcpy (out, ", 4010");
- break;
- case EF_MIPS_MACH_4100:
- out = stpcpy (out, ", 4100");
- break;
- case EF_MIPS_MACH_4111:
- out = stpcpy (out, ", 4111");
- break;
- case EF_MIPS_MACH_4120:
- out = stpcpy (out, ", 4120");
- break;
- case EF_MIPS_MACH_4650:
- out = stpcpy (out, ", 4650");
- break;
- case EF_MIPS_MACH_5400:
- out = stpcpy (out, ", 5400");
- break;
- case EF_MIPS_MACH_5500:
- out = stpcpy (out, ", 5500");
- break;
- case EF_MIPS_MACH_5900:
- out = stpcpy (out, ", 5900");
- break;
- case EF_MIPS_MACH_SB1:
- out = stpcpy (out, ", sb1");
- break;
- case EF_MIPS_MACH_9000:
- out = stpcpy (out, ", 9000");
- break;
- case EF_MIPS_MACH_LS2E:
- out = stpcpy (out, ", loongson-2e");
- break;
- case EF_MIPS_MACH_LS2F:
- out = stpcpy (out, ", loongson-2f");
- break;
- case EF_MIPS_MACH_GS464:
- out = stpcpy (out, ", gs464");
- break;
- case EF_MIPS_MACH_GS464E:
- out = stpcpy (out, ", gs464e");
- break;
- case EF_MIPS_MACH_GS264E:
- out = stpcpy (out, ", gs264e");
- break;
- case EF_MIPS_MACH_OCTEON:
- out = stpcpy (out, ", octeon");
- break;
- case EF_MIPS_MACH_OCTEON2:
- out = stpcpy (out, ", octeon2");
- break;
- case EF_MIPS_MACH_OCTEON3:
- out = stpcpy (out, ", octeon3");
- break;
- case EF_MIPS_MACH_XLR:
- out = stpcpy (out, ", xlr");
- break;
- case EF_MIPS_MACH_IAMR2:
- out = stpcpy (out, ", interaptiv-mr2");
- break;
- case EF_MIPS_MACH_ALLEGREX:
- out = stpcpy (out, ", allegrex");
- break;
- case 0:
- /* We simply ignore the field in this case to avoid confusion:
- MIPS ELF does not specify EF_MIPS_MACH, it is a GNU
- extension. */
- break;
- default:
- out = stpcpy (out, _(", unknown CPU"));
- break;
- }
-
- switch ((e_flags & EF_MIPS_ABI))
- {
- case EF_MIPS_ABI_O32:
- out = stpcpy (out, ", o32");
- break;
- case EF_MIPS_ABI_O64:
- out = stpcpy (out, ", o64");
- break;
- case EF_MIPS_ABI_EABI32:
- out = stpcpy (out, ", eabi32");
- break;
- case EF_MIPS_ABI_EABI64:
- out = stpcpy (out, ", eabi64");
- break;
- case 0:
- /* We simply ignore the field in this case to avoid confusion:
- MIPS ELF does not specify EF_MIPS_ABI, it is a GNU extension.
- This means it is likely to be an o32 file, but not for
- sure. */
- break;
- default:
- out = stpcpy (out, _(", unknown ABI"));
- break;
- }
-
- if (e_flags & EF_MIPS_ARCH_ASE_MDMX)
- out = stpcpy (out, ", mdmx");
-
- if (e_flags & EF_MIPS_ARCH_ASE_M16)
- out = stpcpy (out, ", mips16");
-
- if (e_flags & EF_MIPS_ARCH_ASE_MICROMIPS)
- out = stpcpy (out, ", micromips");
-
- switch ((e_flags & EF_MIPS_ARCH))
- {
- case EF_MIPS_ARCH_1:
- out = stpcpy (out, ", mips1");
- break;
- case EF_MIPS_ARCH_2:
- out = stpcpy (out, ", mips2");
- break;
- case EF_MIPS_ARCH_3:
- out = stpcpy (out, ", mips3");
- break;
- case EF_MIPS_ARCH_4:
- out = stpcpy (out, ", mips4");
- break;
- case EF_MIPS_ARCH_5:
- out = stpcpy (out, ", mips5");
- break;
- case EF_MIPS_ARCH_32:
- out = stpcpy (out, ", mips32");
- break;
- case EF_MIPS_ARCH_32R2:
- out = stpcpy (out, ", mips32r2");
- break;
- case EF_MIPS_ARCH_32R6:
- out = stpcpy (out, ", mips32r6");
- break;
- case EF_MIPS_ARCH_64:
- out = stpcpy (out, ", mips64");
- break;
- case EF_MIPS_ARCH_64R2:
- out = stpcpy (out, ", mips64r2");
- break;
- case EF_MIPS_ARCH_64R6:
- out = stpcpy (out, ", mips64r6");
- break;
- default:
- out = stpcpy (out, _(", unknown ISA"));
- break;
- }
- return out;
-}
-
-static char *
-decode_MSP430_machine_flags (char *out, unsigned e_flags)
-{
- out = stpcpy (out, _(": architecture variant: "));
- switch (e_flags & EF_MSP430_MACH)
- {
- case E_MSP430_MACH_MSP430x11:
- out = stpcpy (out, "MSP430x11");
- break;
- case E_MSP430_MACH_MSP430x11x1:
- out = stpcpy (out, "MSP430x11x1 ");
- break;
- case E_MSP430_MACH_MSP430x12:
- out = stpcpy (out, "MSP430x12");
- break;
- case E_MSP430_MACH_MSP430x13:
- out = stpcpy (out, "MSP430x13");
- break;
- case E_MSP430_MACH_MSP430x14:
- out = stpcpy (out, "MSP430x14");
- break;
- case E_MSP430_MACH_MSP430x15:
- out = stpcpy (out, "MSP430x15");
- break;
- case E_MSP430_MACH_MSP430x16:
- out = stpcpy (out, "MSP430x16");
- break;
- case E_MSP430_MACH_MSP430x31:
- out = stpcpy (out, "MSP430x31");
- break;
- case E_MSP430_MACH_MSP430x32:
- out = stpcpy (out, "MSP430x32");
- break;
- case E_MSP430_MACH_MSP430x33:
- out = stpcpy (out, "MSP430x33");
- break;
- case E_MSP430_MACH_MSP430x41:
- out = stpcpy (out, "MSP430x41");
- break;
- case E_MSP430_MACH_MSP430x42:
- out = stpcpy (out, "MSP430x42");
- break;
- case E_MSP430_MACH_MSP430x43:
- out = stpcpy (out, "MSP430x43");
- break;
- case E_MSP430_MACH_MSP430x44:
- out = stpcpy (out, "MSP430x44");
- break;
- case E_MSP430_MACH_MSP430X :
- out = stpcpy (out, "MSP430X");
- break;
- default:
- out = stpcpy (out, _(": unknown"));
- break;
- }
-
- if (e_flags & ~ EF_MSP430_MACH)
- out = stpcpy (out, _(": unknown extra flag bits also present"));
- return out;
-}
-
-static char *
-decode_NDS32_machine_flags (char *out, unsigned e_flags)
-{
- unsigned abi;
- unsigned arch;
- unsigned config;
- unsigned version;
- bool has_fpu = false;
-
- static const char *ABI_STRINGS[] =
- {
- "ABI v0", /* use r5 as return register; only used in N1213HC */
- "ABI v1", /* use r0 as return register */
- "ABI v2", /* use r0 as return register and don't reserve 24 bytes for arguments */
- "ABI v2fp", /* for FPU */
- "AABI",
- "ABI2 FP+"
- };
- static const char *VER_STRINGS[] =
- {
- "Andes ELF V1.3 or older",
- "Andes ELF V1.3.1",
- "Andes ELF V1.4"
- };
- static const char *ARCH_STRINGS[] =
- {
- "",
- "Andes Star v1.0",
- "Andes Star v2.0",
- "Andes Star v3.0",
- "Andes Star v3.0m"
- };
-
- abi = EF_NDS_ABI & e_flags;
- arch = EF_NDS_ARCH & e_flags;
- config = EF_NDS_INST & e_flags;
- version = EF_NDS32_ELF_VERSION & e_flags;
-
- switch (abi)
- {
- case E_NDS_ABI_V0:
- case E_NDS_ABI_V1:
- case E_NDS_ABI_V2:
- case E_NDS_ABI_V2FP:
- case E_NDS_ABI_AABI:
- case E_NDS_ABI_V2FP_PLUS:
- /* In case there are holes in the array. */
- out += sprintf (out, ", %s", ABI_STRINGS[abi >> EF_NDS_ABI_SHIFT]);
- break;
-
- default:
- out = stpcpy (out, ", <unrecognized ABI>");
- break;
- }
-
- switch (version)
- {
- case E_NDS32_ELF_VER_1_2:
- case E_NDS32_ELF_VER_1_3:
- case E_NDS32_ELF_VER_1_4:
- out += sprintf (out, ", %s", VER_STRINGS[version >> EF_NDS32_ELF_VERSION_SHIFT]);
- break;
-
- default:
- out = stpcpy (out, ", <unrecognized ELF version number>");
- break;
- }
-
- if (E_NDS_ABI_V0 == abi)
- {
- /* OLD ABI; only used in N1213HC, has performance extension 1. */
- out = stpcpy (out, ", Andes Star v1.0, N1213HC, MAC, PERF1");
- if (arch == E_NDS_ARCH_STAR_V1_0)
- out = stpcpy (out, ", 16b"); /* has 16-bit instructions */
- return out;
- }
-
- switch (arch)
- {
- case E_NDS_ARCH_STAR_V1_0:
- case E_NDS_ARCH_STAR_V2_0:
- case E_NDS_ARCH_STAR_V3_0:
- case E_NDS_ARCH_STAR_V3_M:
- out += sprintf (out, ", %s", ARCH_STRINGS[arch >> EF_NDS_ARCH_SHIFT]);
- break;
-
- default:
- out = stpcpy (out, ", <unrecognized architecture>");
- /* ARCH version determines how the e_flags are interpreted.
- If it is unknown, we cannot proceed. */
- return out;
- }
-
- /* Newer ABI; Now handle architecture specific flags. */
- if (arch == E_NDS_ARCH_STAR_V1_0)
- {
- if (config & E_NDS32_HAS_MFUSR_PC_INST)
- out = stpcpy (out, ", MFUSR_PC");
-
- if (!(config & E_NDS32_HAS_NO_MAC_INST))
- out = stpcpy (out, ", MAC");
-
- if (config & E_NDS32_HAS_DIV_INST)
- out = stpcpy (out, ", DIV");
-
- if (config & E_NDS32_HAS_16BIT_INST)
- out = stpcpy (out, ", 16b");
- }
- else
- {
- if (config & E_NDS32_HAS_MFUSR_PC_INST)
- {
- if (version <= E_NDS32_ELF_VER_1_3)
- out = stpcpy (out, ", [B8]");
- else
- out = stpcpy (out, ", EX9");
- }
-
- if (config & E_NDS32_HAS_MAC_DX_INST)
- out = stpcpy (out, ", MAC_DX");
-
- if (config & E_NDS32_HAS_DIV_DX_INST)
- out = stpcpy (out, ", DIV_DX");
-
- if (config & E_NDS32_HAS_16BIT_INST)
- {
- if (version <= E_NDS32_ELF_VER_1_3)
- out = stpcpy (out, ", 16b");
- else
- out = stpcpy (out, ", IFC");
- }
- }
-
- if (config & E_NDS32_HAS_EXT_INST)
- out = stpcpy (out, ", PERF1");
-
- if (config & E_NDS32_HAS_EXT2_INST)
- out = stpcpy (out, ", PERF2");
-
- if (config & E_NDS32_HAS_FPU_INST)
- {
- has_fpu = true;
- out = stpcpy (out, ", FPU_SP");
- }
-
- if (config & E_NDS32_HAS_FPU_DP_INST)
- {
- has_fpu = true;
- out = stpcpy (out, ", FPU_DP");
- }
-
- if (config & E_NDS32_HAS_FPU_MAC_INST)
- {
- has_fpu = true;
- out = stpcpy (out, ", FPU_MAC");
- }
-
- if (has_fpu)
- {
- switch ((config & E_NDS32_FPU_REG_CONF) >> E_NDS32_FPU_REG_CONF_SHIFT)
- {
- case E_NDS32_FPU_REG_8SP_4DP:
- out = stpcpy (out, ", FPU_REG:8/4");
- break;
- case E_NDS32_FPU_REG_16SP_8DP:
- out = stpcpy (out, ", FPU_REG:16/8");
- break;
- case E_NDS32_FPU_REG_32SP_16DP:
- out = stpcpy (out, ", FPU_REG:32/16");
- break;
- case E_NDS32_FPU_REG_32SP_32DP:
- out = stpcpy (out, ", FPU_REG:32/32");
- break;
- }
- }
-
- if (config & E_NDS32_HAS_AUDIO_INST)
- out = stpcpy (out, ", AUDIO");
-
- if (config & E_NDS32_HAS_STRING_INST)
- out = stpcpy (out, ", STR");
-
- if (config & E_NDS32_HAS_REDUCED_REGS)
- out = stpcpy (out, ", 16REG");
-
- if (config & E_NDS32_HAS_VIDEO_INST)
- {
- if (version <= E_NDS32_ELF_VER_1_3)
- out = stpcpy (out, ", VIDEO");
- else
- out = stpcpy (out, ", SATURATION");
- }
-
- if (config & E_NDS32_HAS_ENCRIPT_INST)
- out = stpcpy (out, ", ENCRP");
-
- if (config & E_NDS32_HAS_L2C_INST)
- out = stpcpy (out, ", L2C");
-
- return out;
-}
-
-static char *
-decode_PARISC_machine_flags (char *out, unsigned e_flags)
-{
- switch (e_flags & EF_PARISC_ARCH)
- {
- case EFA_PARISC_1_0:
- out = stpcpy (out, ", PA-RISC 1.0");
- break;
- case EFA_PARISC_1_1:
- out = stpcpy (out, ", PA-RISC 1.1");
- break;
- case EFA_PARISC_2_0:
- out = stpcpy (out, ", PA-RISC 2.0");
- break;
- default:
- break;
- }
- if (e_flags & EF_PARISC_TRAPNIL)
- out = stpcpy (out, ", trapnil");
- if (e_flags & EF_PARISC_EXT)
- out = stpcpy (out, ", ext");
- if (e_flags & EF_PARISC_LSB)
- out = stpcpy (out, ", lsb");
- if (e_flags & EF_PARISC_WIDE)
- out = stpcpy (out, ", wide");
- if (e_flags & EF_PARISC_NO_KABP)
- out = stpcpy (out, ", no kabp");
- if (e_flags & EF_PARISC_LAZYSWAP)
- out = stpcpy (out, ", lazyswap");
- return out;
-}
-
-static char *
-decode_RISCV_machine_flags (char *out, unsigned e_flags)
-{
- if (e_flags & EF_RISCV_RVC)
- out = stpcpy (out, ", RVC");
-
- if (e_flags & EF_RISCV_RVE)
- out = stpcpy (out, ", RVE");
-
- if (e_flags & EF_RISCV_TSO)
- out = stpcpy (out, ", TSO");
-
- switch (e_flags & EF_RISCV_FLOAT_ABI)
- {
- case EF_RISCV_FLOAT_ABI_SOFT:
- out = stpcpy (out, ", soft-float ABI");
- break;
-
- case EF_RISCV_FLOAT_ABI_SINGLE:
- out = stpcpy (out, ", single-float ABI");
- break;
-
- case EF_RISCV_FLOAT_ABI_DOUBLE:
- out = stpcpy (out, ", double-float ABI");
- break;
-
- case EF_RISCV_FLOAT_ABI_QUAD:
- out = stpcpy (out, ", quad-float ABI");
- break;
- }
- return out;
-}
-
-static char *
-decode_RL78_machine_flags (char *out, unsigned e_flags)
-{
- switch (e_flags & E_FLAG_RL78_CPU_MASK)
- {
- case E_FLAG_RL78_ANY_CPU:
- break;
- case E_FLAG_RL78_G10:
- out = stpcpy (out, ", G10");
- break;
- case E_FLAG_RL78_G13:
- out = stpcpy (out, ", G13");
- break;
- case E_FLAG_RL78_G14:
- out = stpcpy (out, ", G14");
- break;
- }
- if (e_flags & E_FLAG_RL78_64BIT_DOUBLES)
- out = stpcpy (out, ", 64-bit doubles");
- return out;
-}
-
-static char *
-decode_RX_machine_flags (char *out, unsigned e_flags)
-{
- if (e_flags & E_FLAG_RX_64BIT_DOUBLES)
- out = stpcpy (out, ", 64-bit doubles");
- if (e_flags & E_FLAG_RX_DSP)
- out = stpcpy (out, ", dsp");
- if (e_flags & E_FLAG_RX_PID)
- out = stpcpy (out, ", pid");
- if (e_flags & E_FLAG_RX_ABI)
- out = stpcpy (out, ", RX ABI");
- if (e_flags & E_FLAG_RX_SINSNS_SET)
- out = stpcpy (out, (e_flags & E_FLAG_RX_SINSNS_YES
- ? ", uses String instructions"
- : ", bans String instructions"));
- if (e_flags & E_FLAG_RX_V2)
- out = stpcpy (out, ", V2");
- if (e_flags & E_FLAG_RX_V3)
- out = stpcpy (out, ", V3");
- return out;
-}
-
-static char *
-decode_SH_machine_flags (char *out, unsigned e_flags)
-{
- switch ((e_flags & EF_SH_MACH_MASK))
- {
- case EF_SH1:
- out = stpcpy (out, ", sh1");
- break;
- case EF_SH2:
- out = stpcpy (out, ", sh2");
- break;
- case EF_SH3:
- out = stpcpy (out, ", sh3");
- break;
- case EF_SH_DSP:
- out = stpcpy (out, ", sh-dsp");
- break;
- case EF_SH3_DSP:
- out = stpcpy (out, ", sh3-dsp");
- break;
- case EF_SH4AL_DSP:
- out = stpcpy (out, ", sh4al-dsp");
- break;
- case EF_SH3E:
- out = stpcpy (out, ", sh3e");
- break;
- case EF_SH4:
- out = stpcpy (out, ", sh4");
- break;
- case EF_SH5:
- out = stpcpy (out, ", sh5");
- break;
- case EF_SH2E:
- out = stpcpy (out, ", sh2e");
- break;
- case EF_SH4A:
- out = stpcpy (out, ", sh4a");
- break;
- case EF_SH2A:
- out = stpcpy (out, ", sh2a");
- break;
- case EF_SH4_NOFPU:
- out = stpcpy (out, ", sh4-nofpu");
- break;
- case EF_SH4A_NOFPU:
- out = stpcpy (out, ", sh4a-nofpu");
- break;
- case EF_SH2A_NOFPU:
- out = stpcpy (out, ", sh2a-nofpu");
- break;
- case EF_SH3_NOMMU:
- out = stpcpy (out, ", sh3-nommu");
- break;
- case EF_SH4_NOMMU_NOFPU:
- out = stpcpy (out, ", sh4-nommu-nofpu");
- break;
- case EF_SH2A_SH4_NOFPU:
- out = stpcpy (out, ", sh2a-nofpu-or-sh4-nommu-nofpu");
- break;
- case EF_SH2A_SH3_NOFPU:
- out = stpcpy (out, ", sh2a-nofpu-or-sh3-nommu");
- break;
- case EF_SH2A_SH4:
- out = stpcpy (out, ", sh2a-or-sh4");
- break;
- case EF_SH2A_SH3E:
- out = stpcpy (out, ", sh2a-or-sh3e");
- break;
- default:
- out = stpcpy (out, _(", unknown ISA"));
- break;
- }
-
- if (e_flags & EF_SH_PIC)
- out = stpcpy (out, ", pic");
-
- if (e_flags & EF_SH_FDPIC)
- out = stpcpy (out, ", fdpic");
- return out;
-}
-
-static char *
-decode_SPARC_machine_flags (char *out, unsigned e_flags)
-{
- if (e_flags & EF_SPARC_32PLUS)
- out = stpcpy (out, ", v8+");
-
- if (e_flags & EF_SPARC_SUN_US1)
- out = stpcpy (out, ", ultrasparcI");
-
- if (e_flags & EF_SPARC_SUN_US3)
- out = stpcpy (out, ", ultrasparcIII");
-
- if (e_flags & EF_SPARC_HAL_R1)
- out = stpcpy (out, ", halr1");
-
- if (e_flags & EF_SPARC_LEDATA)
- out = stpcpy (out, ", ledata");
-
- if ((e_flags & EF_SPARCV9_MM) == EF_SPARCV9_TSO)
- out = stpcpy (out, ", tso");
-
- if ((e_flags & EF_SPARCV9_MM) == EF_SPARCV9_PSO)
- out = stpcpy (out, ", pso");
-
- if ((e_flags & EF_SPARCV9_MM) == EF_SPARCV9_RMO)
- out = stpcpy (out, ", rmo");
- return out;
-}
-
-static char *
-decode_V800_machine_flags (char *out, unsigned int e_flags)
-{
- if ((e_flags & EF_RH850_ABI) == EF_RH850_ABI)
- out = stpcpy (out, ", RH850 ABI");
-
- if (e_flags & EF_V800_850E3)
- out = stpcpy (out, ", V3 architecture");
-
- if ((e_flags & (EF_RH850_FPU_DOUBLE | EF_RH850_FPU_SINGLE)) == 0)
- out = stpcpy (out, ", FPU not used");
-
- if ((e_flags & (EF_RH850_REGMODE22 | EF_RH850_REGMODE32)) == 0)
- out = stpcpy (out, ", regmode: COMMON");
-
- if ((e_flags & (EF_RH850_GP_FIX | EF_RH850_GP_NOFIX)) == 0)
- out = stpcpy (out, ", r4 not used");
-
- if ((e_flags & (EF_RH850_EP_FIX | EF_RH850_EP_NOFIX)) == 0)
- out = stpcpy (out, ", r30 not used");
-
- if ((e_flags & (EF_RH850_TP_FIX | EF_RH850_TP_NOFIX)) == 0)
- out = stpcpy (out, ", r5 not used");
-
- if ((e_flags & (EF_RH850_REG2_RESERVE | EF_RH850_REG2_NORESERVE)) == 0)
- out = stpcpy (out, ", r2 not used");
-
- for (e_flags &= 0xFFFF; e_flags; e_flags &= ~ (e_flags & - e_flags))
- {
- switch (e_flags & - e_flags)
- {
- case EF_RH850_FPU_DOUBLE:
- out = stpcpy (out, ", double precision FPU");
- break;
- case EF_RH850_FPU_SINGLE:
- out = stpcpy (out, ", single precision FPU");
- break;
- case EF_RH850_REGMODE22:
- out = stpcpy (out, ", regmode:22");
- break;
- case EF_RH850_REGMODE32:
- out = stpcpy (out, ", regmode:23");
- break;
- case EF_RH850_GP_FIX:
- out = stpcpy (out, ", r4 fixed");
- break;
- case EF_RH850_GP_NOFIX:
- out = stpcpy (out, ", r4 free");
- break;
- case EF_RH850_EP_FIX:
- out = stpcpy (out, ", r30 fixed");
- break;
- case EF_RH850_EP_NOFIX:
- out = stpcpy (out, ", r30 free");
- break;
- case EF_RH850_TP_FIX:
- out = stpcpy (out, ", r5 fixed");
- break;
- case EF_RH850_TP_NOFIX:
- out = stpcpy (out, ", r5 free");
- break;
- case EF_RH850_REG2_RESERVE:
- out = stpcpy (out, ", r2 fixed");
- break;
- case EF_RH850_REG2_NORESERVE:
- out = stpcpy (out, ", r2 free");
- break;
- default:
- break;
- }
- }
- return out;
-}
-
-static char *
-decode_V850_machine_flags (char *out, unsigned int e_flags)
-{
- switch (e_flags & EF_V850_ARCH)
- {
- case E_V850E3V5_ARCH:
- out = stpcpy (out, ", v850e3v5");
- break;
- case E_V850E2V3_ARCH:
- out = stpcpy (out, ", v850e2v3");
- break;
- case E_V850E2_ARCH:
- out = stpcpy (out, ", v850e2");
- break;
- case E_V850E1_ARCH:
- out = stpcpy (out, ", v850e1");
- break;
- case E_V850E_ARCH:
- out = stpcpy (out, ", v850e");
- break;
- case E_V850_ARCH:
- out = stpcpy (out, ", v850");
- break;
- default:
- out = stpcpy (out, _(", unknown v850 architecture variant"));
- break;
- }
- return out;
-}
-
-static char *
-decode_Z80_machine_flags (char *out, unsigned int e_flags)
-{
- switch (e_flags & EF_Z80_MACH_MSK)
- {
- case EF_Z80_MACH_Z80:
- out = stpcpy (out, ", Z80");
- break;
- case EF_Z80_MACH_Z180:
- out = stpcpy (out, ", Z180");
- break;
- case EF_Z80_MACH_R800:
- out = stpcpy (out, ", R800");
- break;
- case EF_Z80_MACH_EZ80_Z80:
- out = stpcpy (out, ", EZ80");
- break;
- case EF_Z80_MACH_EZ80_ADL:
- out = stpcpy (out, ", EZ80, ADL");
- break;
- case EF_Z80_MACH_GBZ80:
- out = stpcpy (out, ", GBZ80");
- break;
- case EF_Z80_MACH_Z80N:
- out = stpcpy (out, ", Z80N");
- break;
- default:
- out = stpcpy (out, _(", unknown"));
- break;
- }
- return out;
-}
-
-static char *
-decode_AMDGPU_machine_flags (char *out, unsigned int e_flags, Filedata *filedata)
-{
- unsigned char *e_ident = filedata->file_header.e_ident;
- unsigned char osabi = e_ident[EI_OSABI];
- unsigned char abiversion = e_ident[EI_ABIVERSION];
- unsigned int mach;
-
- /* HSA OS ABI v2 used a different encoding, but we don't need to support it,
- it has been deprecated for a while.
-
- The PAL, MESA3D and NONE OS ABIs are not properly versioned, at the time
- of writing, they use the same flags as HSA v3, so the code below uses that
- assumption. */
- if (osabi == ELFOSABI_AMDGPU_HSA && abiversion < ELFABIVERSION_AMDGPU_HSA_V3)
- return out;
-
- mach = e_flags & EF_AMDGPU_MACH;
- switch (mach)
- {
-#define AMDGPU_CASE(code, string) \
- case code: out = stpcpy (out, ", " string); break;
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX600, "gfx600")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX601, "gfx601")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX700, "gfx700")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX701, "gfx701")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX702, "gfx702")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX703, "gfx703")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX704, "gfx704")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX801, "gfx801")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX802, "gfx802")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX803, "gfx803")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX810, "gfx810")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX900, "gfx900")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX902, "gfx902")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX904, "gfx904")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX906, "gfx906")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX908, "gfx908")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX909, "gfx909")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX90C, "gfx90c")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX1010, "gfx1010")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX1011, "gfx1011")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX1012, "gfx1012")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX1030, "gfx1030")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX1031, "gfx1031")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX1032, "gfx1032")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX1033, "gfx1033")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX1100, "gfx1100")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX1101, "gfx1101")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX1102, "gfx1102")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX602, "gfx602")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX705, "gfx705")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX805, "gfx805")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX1035, "gfx1035")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX1034, "gfx1034")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX90A, "gfx90a")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX940, "gfx940")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX1013, "gfx1013")
- AMDGPU_CASE (EF_AMDGPU_MACH_AMDGCN_GFX1036, "gfx1036")
- default:
- out += sprintf (out, _(", <unknown AMDGPU GPU type: %#x>"), mach);
- break;
-#undef AMDGPU_CASE
- }
-
- e_flags &= ~EF_AMDGPU_MACH;
-
- if ((osabi == ELFOSABI_AMDGPU_HSA
- && abiversion == ELFABIVERSION_AMDGPU_HSA_V3)
- || osabi != ELFOSABI_AMDGPU_HSA)
- {
- /* For HSA v3 and other OS ABIs. */
- if (e_flags & EF_AMDGPU_FEATURE_XNACK_V3)
- {
- out = stpcpy (out, ", xnack on");
- e_flags &= ~EF_AMDGPU_FEATURE_XNACK_V3;
- }
-
- if (e_flags & EF_AMDGPU_FEATURE_SRAMECC_V3)
- {
- out = stpcpy (out, ", sramecc on");
- e_flags &= ~EF_AMDGPU_FEATURE_SRAMECC_V3;
- }
- }
- else
- {
- /* For HSA v4+. */
- int xnack, sramecc;
-
- xnack = e_flags & EF_AMDGPU_FEATURE_XNACK_V4;
- switch (xnack)
- {
- case EF_AMDGPU_FEATURE_XNACK_UNSUPPORTED_V4:
- break;
-
- case EF_AMDGPU_FEATURE_XNACK_ANY_V4:
- out = stpcpy (out, ", xnack any");
- break;
-
- case EF_AMDGPU_FEATURE_XNACK_OFF_V4:
- out = stpcpy (out, ", xnack off");
- break;
-
- case EF_AMDGPU_FEATURE_XNACK_ON_V4:
- out = stpcpy (out, ", xnack on");
- break;
-
- default:
- out += sprintf (out, _(", <unknown xnack value: %#x>"), xnack);
- break;
- }
-
- e_flags &= ~EF_AMDGPU_FEATURE_XNACK_V4;
-
- sramecc = e_flags & EF_AMDGPU_FEATURE_SRAMECC_V4;
- switch (sramecc)
- {
- case EF_AMDGPU_FEATURE_SRAMECC_UNSUPPORTED_V4:
- break;
-
- case EF_AMDGPU_FEATURE_SRAMECC_ANY_V4:
- out = stpcpy (out, ", sramecc any");
- break;
-
- case EF_AMDGPU_FEATURE_SRAMECC_OFF_V4:
- out = stpcpy (out, ", sramecc off");
- break;
-
- case EF_AMDGPU_FEATURE_SRAMECC_ON_V4:
- out = stpcpy (out, ", sramecc on");
- break;
-
- default:
- out += sprintf (out, _(", <unknown sramecc value: %#x>"), sramecc);
- break;
- }
-
- e_flags &= ~EF_AMDGPU_FEATURE_SRAMECC_V4;
- }
-
- if (e_flags != 0)
- out += sprintf (out, _(", unknown flags bits: %#x"), e_flags);
- return out;
-}
-
-static char *
-get_machine_flags (Filedata * filedata, unsigned e_flags, unsigned e_machine)
-{
- static char buf[1024];
- char *out = buf;
-
- buf[0] = '\0';
-
- if (e_flags)
- {
- switch (e_machine)
- {
- default:
- break;
-
- case EM_ARC_COMPACT3:
- out = stpcpy (out, ", HS5x");
- break;
-
- case EM_ARC_COMPACT3_64:
- out = stpcpy (out, ", HS6x");
- break;
-
- case EM_ARC_COMPACT2:
- case EM_ARC_COMPACT:
- out = decode_ARC_machine_flags (out, e_flags, e_machine);
- break;
-
- case EM_ARM:
- out = decode_ARM_machine_flags (out, e_flags);
- break;
-
- case EM_AVR:
- out = decode_AVR_machine_flags (out, e_flags);
- break;
-
- case EM_BLACKFIN:
- out = decode_BLACKFIN_machine_flags (out, e_flags);
- break;
-
- case EM_CYGNUS_FRV:
- out = decode_FRV_machine_flags (out, e_flags);
- break;
-
- case EM_68K:
- out = decode_M68K_machine_flags (out, e_flags);
- break;
-
- case EM_AMDGPU:
- out = decode_AMDGPU_machine_flags (out, e_flags, filedata);
- break;
-
- case EM_CYGNUS_MEP:
- out = decode_MeP_machine_flags (out, e_flags);
- break;
-
- case EM_PPC:
- if (e_flags & EF_PPC_EMB)
- out = stpcpy (out, ", emb");
-
- if (e_flags & EF_PPC_RELOCATABLE)
- out = stpcpy (out, _(", relocatable"));
-
- if (e_flags & EF_PPC_RELOCATABLE_LIB)
- out = stpcpy (out, _(", relocatable-lib"));
- break;
-
- case EM_PPC64:
- if (e_flags & EF_PPC64_ABI)
- out += sprintf (out, ", abiv%d", e_flags & EF_PPC64_ABI);
- break;
-
- case EM_V800:
- out = decode_V800_machine_flags (out, e_flags);
- break;
-
- case EM_V850:
- case EM_CYGNUS_V850:
- out = decode_V850_machine_flags (out, e_flags);
- break;
-
- case EM_M32R:
- case EM_CYGNUS_M32R:
- if ((e_flags & EF_M32R_ARCH) == E_M32R_ARCH)
- out = stpcpy (out, ", m32r");
- break;
-
- case EM_MIPS:
- case EM_MIPS_RS3_LE:
- out = decode_MIPS_machine_flags (out, e_flags);
- break;
-
- case EM_NDS32:
- out = decode_NDS32_machine_flags (out, e_flags);
- break;
-
- case EM_NFP:
- switch (EF_NFP_MACH (e_flags))
- {
- case E_NFP_MACH_3200:
- out = stpcpy (out, ", NFP-32xx");
- break;
- case E_NFP_MACH_6000:
- out = stpcpy (out, ", NFP-6xxx");
- break;
- }
- break;
-
- case EM_RISCV:
- out = decode_RISCV_machine_flags (out, e_flags);
- break;
-
- case EM_SH:
- out = decode_SH_machine_flags (out, e_flags);
- break;
-
- case EM_OR1K:
- if (e_flags & EF_OR1K_NODELAY)
- out = stpcpy (out, ", no delay");
- break;
-
- case EM_BPF:
- out += sprintf (out, ", CPU Version: %u", e_flags & EF_BPF_CPUVER);
- break;
-
- case EM_SPARCV9:
- out = decode_SPARC_machine_flags (out, e_flags);
- break;
-
- case EM_PARISC:
- out = decode_PARISC_machine_flags (out, e_flags);
- break;
-
- case EM_PJ:
- case EM_PJ_OLD:
- if ((e_flags & EF_PICOJAVA_NEWCALLS) == EF_PICOJAVA_NEWCALLS)
- out = stpcpy (out, ", new calling convention");
-
- if ((e_flags & EF_PICOJAVA_GNUCALLS) == EF_PICOJAVA_GNUCALLS)
- out = stpcpy (out, ", gnu calling convention");
- break;
-
- case EM_IA_64:
- out = decode_IA64_machine_flags (out, e_flags, filedata);
- break;
-
- case EM_VAX:
- if ((e_flags & EF_VAX_NONPIC))
- out = stpcpy (out, ", non-PIC");
- if ((e_flags & EF_VAX_DFLOAT))
- out = stpcpy (out, ", D-Float");
- if ((e_flags & EF_VAX_GFLOAT))
- out = stpcpy (out, ", G-Float");
- break;
-
- case EM_VISIUM:
- if (e_flags & EF_VISIUM_ARCH_MCM)
- out = stpcpy (out, ", mcm");
- else if (e_flags & EF_VISIUM_ARCH_MCM24)
- out = stpcpy (out, ", mcm24");
- if (e_flags & EF_VISIUM_ARCH_GR6)
- out = stpcpy (out, ", gr6");
- break;
-
- case EM_RL78:
- out = decode_RL78_machine_flags (out, e_flags);
- break;
-
- case EM_RX:
- out = decode_RX_machine_flags (out, e_flags);
- break;
-
- case EM_S390:
- if (e_flags & EF_S390_HIGH_GPRS)
- out = stpcpy (out, ", highgprs");
- break;
-
- case EM_TI_C6000:
- if ((e_flags & EF_C6000_REL))
- out = stpcpy (out, ", relocatable module");
- break;
-
- case EM_KVX:
- if ((e_flags & (ELF_KVX_CORE_MAJOR_MASK | ELF_KVX_CORE_MINOR_MASK)) == ELF_KVX_CORE_KV3_1)
- strcat (buf, ", Kalray VLIW kv3-1");
- else if ((e_flags & (ELF_KVX_CORE_MAJOR_MASK | ELF_KVX_CORE_MINOR_MASK)) == ELF_KVX_CORE_KV3_2)
- strcat (buf, ", Kalray VLIW kv3-2");
- else if ((e_flags & (ELF_KVX_CORE_MAJOR_MASK | ELF_KVX_CORE_MINOR_MASK)) == ELF_KVX_CORE_KV4_1)
- strcat (buf, ", Kalray VLIW kv4-1");
- else
- strcat (buf, ", unknown KVX MPPA");
- break;
-
- case EM_MSP430:
- out = decode_MSP430_machine_flags (out, e_flags);
- break;
-
- case EM_Z80:
- out = decode_Z80_machine_flags (out, e_flags);
- break;
-
- case EM_LOONGARCH:
- out = decode_LOONGARCH_machine_flags (out, e_flags);
- break;
- }
- }
-
- return buf;
-}
-
-static const char *
-get_osabi_name (Filedata * filedata, unsigned int osabi)
-{
- static char buff[32];
-
- switch (osabi)
- {
- case ELFOSABI_NONE: return "UNIX - System V";
- case ELFOSABI_HPUX: return "UNIX - HP-UX";
- case ELFOSABI_NETBSD: return "UNIX - NetBSD";
- case ELFOSABI_GNU: return "UNIX - GNU";
- case ELFOSABI_SOLARIS: return "UNIX - Solaris";
- case ELFOSABI_AIX: return "UNIX - AIX";
- case ELFOSABI_IRIX: return "UNIX - IRIX";
- case ELFOSABI_FREEBSD: return "UNIX - FreeBSD";
- case ELFOSABI_TRU64: return "UNIX - TRU64";
- case ELFOSABI_MODESTO: return "Novell - Modesto";
- case ELFOSABI_OPENBSD: return "UNIX - OpenBSD";
- case ELFOSABI_OPENVMS: return "VMS - OpenVMS";
- case ELFOSABI_NSK: return "HP - Non-Stop Kernel";
- case ELFOSABI_AROS: return "AROS";
- case ELFOSABI_FENIXOS: return "FenixOS";
- case ELFOSABI_CLOUDABI: return "Nuxi CloudABI";
- case ELFOSABI_OPENVOS: return "Stratus Technologies OpenVOS";
- case ELFOSABI_CUDA: return "CUDA";
- default:
- if (osabi >= 64)
- switch (filedata->file_header.e_machine)
- {
- case EM_AMDGPU:
- switch (osabi)
- {
- case ELFOSABI_AMDGPU_HSA: return "AMD HSA";
- case ELFOSABI_AMDGPU_PAL: return "AMD PAL";
- case ELFOSABI_AMDGPU_MESA3D: return "AMD Mesa3D";
- default:
- break;
- }
- break;
-
- case EM_ARM:
- switch (osabi)
- {
- case ELFOSABI_ARM: return "ARM";
- case ELFOSABI_ARM_FDPIC: return "ARM FDPIC";
- default:
- break;
- }
- break;
-
- case EM_MSP430:
- case EM_MSP430_OLD:
- case EM_VISIUM:
- switch (osabi)
- {
- case ELFOSABI_STANDALONE: return _("Standalone App");
- default:
- break;
- }
- break;
-
- case EM_TI_C6000:
- switch (osabi)
- {
- case ELFOSABI_C6000_ELFABI: return _("Bare-metal C6000");
- case ELFOSABI_C6000_LINUX: return "Linux C6000";
- default:
- break;
- }
- break;
-
- default:
- break;
- }
- snprintf (buff, sizeof (buff), _("<unknown: %x>"), osabi);
- return buff;
- }
-}
-
-static const char *
-get_aarch64_segment_type (unsigned long type)
-{
- switch (type)
- {
- case PT_AARCH64_ARCHEXT: return "AARCH64_ARCHEXT";
- case PT_AARCH64_MEMTAG_MTE: return "AARCH64_MEMTAG_MTE";
- default: return NULL;
- }
-}
-
-static const char *
-get_arm_segment_type (unsigned long type)
-{
- switch (type)
- {
- case PT_ARM_ARCHEXT: return "ARM_ARCHEXT";
- case PT_ARM_EXIDX: return "ARM_EXIDX";
- default: return NULL;
- }
-}
-
-static const char *
-get_s390_segment_type (unsigned long type)
-{
- switch (type)
- {
- case PT_S390_PGSTE: return "S390_PGSTE";
- default: return NULL;
- }
-}
-
-static const char *
-get_mips_segment_type (unsigned long type)
-{
- switch (type)
- {
- case PT_MIPS_REGINFO: return "REGINFO";
- case PT_MIPS_RTPROC: return "RTPROC";
- case PT_MIPS_OPTIONS: return "OPTIONS";
- case PT_MIPS_ABIFLAGS: return "ABIFLAGS";
- default: return NULL;
- }
-}
-
-static const char *
-get_parisc_segment_type (unsigned long type)
-{
- switch (type)
- {
- case PT_PARISC_ARCHEXT: return "PARISC_ARCHEXT";
- case PT_PARISC_UNWIND: return "PARISC_UNWIND";
- case PT_PARISC_WEAKORDER: return "PARISC_WEAKORDER";
- default: return NULL;
- }
-}
-
-static const char *
-get_ia64_segment_type (unsigned long type)
-{
- switch (type)
- {
- case PT_IA_64_ARCHEXT: return "IA_64_ARCHEXT";
- case PT_IA_64_UNWIND: return "IA_64_UNWIND";
- default: return NULL;
- }
-}
-
-static const char *
-get_tic6x_segment_type (unsigned long type)
-{
- switch (type)
- {
- case PT_C6000_PHATTR: return "C6000_PHATTR";
- default: return NULL;
- }
-}
-
-static const char *
-get_riscv_segment_type (unsigned long type)
-{
- switch (type)
- {
- case PT_RISCV_ATTRIBUTES: return "RISCV_ATTRIBUTES";
- default: return NULL;
- }
-}
-
-static const char *
-get_hpux_segment_type (unsigned long type, unsigned e_machine)
-{
- if (e_machine == EM_PARISC)
- switch (type)
- {
- case PT_HP_TLS: return "HP_TLS";
- case PT_HP_CORE_NONE: return "HP_CORE_NONE";
- case PT_HP_CORE_VERSION: return "HP_CORE_VERSION";
- case PT_HP_CORE_KERNEL: return "HP_CORE_KERNEL";
- case PT_HP_CORE_COMM: return "HP_CORE_COMM";
- case PT_HP_CORE_PROC: return "HP_CORE_PROC";
- case PT_HP_CORE_LOADABLE: return "HP_CORE_LOADABLE";
- case PT_HP_CORE_STACK: return "HP_CORE_STACK";
- case PT_HP_CORE_SHM: return "HP_CORE_SHM";
- case PT_HP_CORE_MMF: return "HP_CORE_MMF";
- case PT_HP_PARALLEL: return "HP_PARALLEL";
- case PT_HP_FASTBIND: return "HP_FASTBIND";
- case PT_HP_OPT_ANNOT: return "HP_OPT_ANNOT";
- case PT_HP_HSL_ANNOT: return "HP_HSL_ANNOT";
- case PT_HP_STACK: return "HP_STACK";
- case PT_HP_CORE_UTSNAME: return "HP_CORE_UTSNAME";
- default:
- break;
- }
-
- if (e_machine == EM_IA_64)
- switch (type)
- {
- case PT_HP_TLS: return "HP_TLS";
- case PT_IA_64_HP_OPT_ANOT: return "HP_OPT_ANNOT";
- case PT_IA_64_HP_HSL_ANOT: return "HP_HSL_ANNOT";
- case PT_IA_64_HP_STACK: return "HP_STACK";
- default:
- break;
- }
-
- return NULL;
-}
-
-static const char *
-get_solaris_segment_type (unsigned long type)
-{
- switch (type)
- {
- case PT_SUNW_UNWIND: return "SUNW_UNWIND";
- case PT_SUNW_EH_FRAME: return "SUNW_EH_FRAME";
- case PT_SUNWBSS: return "SUNW_BSS";
- case PT_SUNWSTACK: return "SUNW_STACK";
- case PT_SUNWDTRACE: return "SUNW_DTRACE";
- case PT_SUNWCAP: return "SUNW_CAP";
- default: return NULL;
- }
-}
-
-static const char *
-get_os_specific_segment_type (Filedata * filedata, unsigned long p_type)
-{
- static char buff[32];
- const char * result = NULL;
-
- switch (filedata->file_header.e_ident[EI_OSABI])
- {
- case ELFOSABI_GNU:
- case ELFOSABI_FREEBSD:
- if (p_type >= PT_GNU_MBIND_LO && p_type <= PT_GNU_MBIND_HI)
- {
- sprintf (buff, "GNU_MBIND+%#lx", p_type - PT_GNU_MBIND_LO);
- result = buff;
- }
- break;
-
- case ELFOSABI_HPUX:
- result = get_hpux_segment_type (p_type,
- filedata->file_header.e_machine);
- break;
-
- case ELFOSABI_SOLARIS:
- result = get_solaris_segment_type (p_type);
- break;
-
- default:
- break;
- }
-
- if (result != NULL)
- return result;
-
- switch (p_type)
- {
- case PT_GNU_EH_FRAME: return "GNU_EH_FRAME";
- case PT_GNU_STACK: return "GNU_STACK";
- case PT_GNU_RELRO: return "GNU_RELRO";
- case PT_GNU_PROPERTY: return "GNU_PROPERTY";
- case PT_GNU_SFRAME: return "GNU_SFRAME";
-
- case PT_OPENBSD_MUTABLE: return "OPENBSD_MUTABLE";
- case PT_OPENBSD_RANDOMIZE: return "OPENBSD_RANDOMIZE";
- case PT_OPENBSD_WXNEEDED: return "OPENBSD_WXNEEDED";
- case PT_OPENBSD_NOBTCFI: return "OPENBSD_NOBTCFI";
- case PT_OPENBSD_SYSCALLS: return "OPENBSD_SYSCALLS";
- case PT_OPENBSD_BOOTDATA: return "OPENBSD_BOOTDATA";
-
- default:
- break;
- }
-
- sprintf (buff, "LOOS+%#lx", p_type - PT_LOOS);
- return buff;
-}
-
-static const char *
-get_processor_specific_segment_type (Filedata * filedata, unsigned long p_type)
-{
- static char buff[32];
- const char * result = NULL;
-
- switch (filedata->file_header.e_machine)
- {
- case EM_AARCH64:
- result = get_aarch64_segment_type (p_type);
- break;
-
- case EM_ARM:
- result = get_arm_segment_type (p_type);
- break;
-
- case EM_MIPS:
- case EM_MIPS_RS3_LE:
- result = get_mips_segment_type (p_type);
- break;
-
- case EM_PARISC:
- result = get_parisc_segment_type (p_type);
- break;
-
- case EM_IA_64:
- result = get_ia64_segment_type (p_type);
- break;
-
- case EM_TI_C6000:
- result = get_tic6x_segment_type (p_type);
- break;
-
- case EM_S390:
- case EM_S390_OLD:
- result = get_s390_segment_type (p_type);
- break;
-
- case EM_RISCV:
- result = get_riscv_segment_type (p_type);
- break;
-
- default:
- result = NULL;
- break;
- }
-
- if (result != NULL)
- return result;
-
- sprintf (buff, "LOPROC+%#lx", p_type - PT_LOPROC);
- return buff;
-}
-
-static const char *
-get_segment_type (Filedata * filedata, unsigned long p_type)
-{
- static char buff[32];
-
- switch (p_type)
- {
- case PT_NULL: return "NULL";
- case PT_LOAD: return "LOAD";
- case PT_DYNAMIC: return "DYNAMIC";
- case PT_INTERP: return "INTERP";
- case PT_NOTE: return "NOTE";
- case PT_SHLIB: return "SHLIB";
- case PT_PHDR: return "PHDR";
- case PT_TLS: return "TLS";
- case PT_NUM: return "NUM";
- }
-
- if ((p_type >= PT_LOOS) && (p_type <= PT_HIOS))
- return get_os_specific_segment_type (filedata, p_type);
-
- if ((p_type >= PT_LOPROC) && (p_type <= PT_HIPROC))
- return get_processor_specific_segment_type (filedata, p_type);
-
- snprintf (buff, sizeof (buff), _("<unknown>: %lx"), p_type);
- return buff;
-}
-
-static const char *
-get_arc_section_type_name (unsigned int sh_type)
-{
- switch (sh_type)
- {
- case SHT_ARC_ATTRIBUTES: return "ARC_ATTRIBUTES";
- default:
- break;
- }
- return NULL;
-}
-
-static const char *
-get_mips_section_type_name (unsigned int sh_type)
-{
- switch (sh_type)
- {
- case SHT_MIPS_LIBLIST: return "MIPS_LIBLIST";
- case SHT_MIPS_MSYM: return "MIPS_MSYM";
- case SHT_MIPS_CONFLICT: return "MIPS_CONFLICT";
- case SHT_MIPS_GPTAB: return "MIPS_GPTAB";
- case SHT_MIPS_UCODE: return "MIPS_UCODE";
- case SHT_MIPS_DEBUG: return "MIPS_DEBUG";
- case SHT_MIPS_REGINFO: return "MIPS_REGINFO";
- case SHT_MIPS_PACKAGE: return "MIPS_PACKAGE";
- case SHT_MIPS_PACKSYM: return "MIPS_PACKSYM";
- case SHT_MIPS_RELD: return "MIPS_RELD";
- case SHT_MIPS_IFACE: return "MIPS_IFACE";
- case SHT_MIPS_CONTENT: return "MIPS_CONTENT";
- case SHT_MIPS_OPTIONS: return "MIPS_OPTIONS";
- case SHT_MIPS_SHDR: return "MIPS_SHDR";
- case SHT_MIPS_FDESC: return "MIPS_FDESC";
- case SHT_MIPS_EXTSYM: return "MIPS_EXTSYM";
- case SHT_MIPS_DENSE: return "MIPS_DENSE";
- case SHT_MIPS_PDESC: return "MIPS_PDESC";
- case SHT_MIPS_LOCSYM: return "MIPS_LOCSYM";
- case SHT_MIPS_AUXSYM: return "MIPS_AUXSYM";
- case SHT_MIPS_OPTSYM: return "MIPS_OPTSYM";
- case SHT_MIPS_LOCSTR: return "MIPS_LOCSTR";
- case SHT_MIPS_LINE: return "MIPS_LINE";
- case SHT_MIPS_RFDESC: return "MIPS_RFDESC";
- case SHT_MIPS_DELTASYM: return "MIPS_DELTASYM";
- case SHT_MIPS_DELTAINST: return "MIPS_DELTAINST";
- case SHT_MIPS_DELTACLASS: return "MIPS_DELTACLASS";
- case SHT_MIPS_DWARF: return "MIPS_DWARF";
- case SHT_MIPS_DELTADECL: return "MIPS_DELTADECL";
- case SHT_MIPS_SYMBOL_LIB: return "MIPS_SYMBOL_LIB";
- case SHT_MIPS_EVENTS: return "MIPS_EVENTS";
- case SHT_MIPS_TRANSLATE: return "MIPS_TRANSLATE";
- case SHT_MIPS_PIXIE: return "MIPS_PIXIE";
- case SHT_MIPS_XLATE: return "MIPS_XLATE";
- case SHT_MIPS_XLATE_DEBUG: return "MIPS_XLATE_DEBUG";
- case SHT_MIPS_WHIRL: return "MIPS_WHIRL";
- case SHT_MIPS_EH_REGION: return "MIPS_EH_REGION";
- case SHT_MIPS_XLATE_OLD: return "MIPS_XLATE_OLD";
- case SHT_MIPS_PDR_EXCEPTION: return "MIPS_PDR_EXCEPTION";
- case SHT_MIPS_ABIFLAGS: return "MIPS_ABIFLAGS";
- case SHT_MIPS_XHASH: return "MIPS_XHASH";
- default:
- break;
- }
- return NULL;
-}
-
-static const char *
-get_parisc_section_type_name (unsigned int sh_type)
-{
- switch (sh_type)
- {
- case SHT_PARISC_EXT: return "PARISC_EXT";
- case SHT_PARISC_UNWIND: return "PARISC_UNWIND";
- case SHT_PARISC_DOC: return "PARISC_DOC";
- case SHT_PARISC_ANNOT: return "PARISC_ANNOT";
- case SHT_PARISC_DLKM: return "PARISC_DLKM";
- case SHT_PARISC_SYMEXTN: return "PARISC_SYMEXTN";
- case SHT_PARISC_STUBS: return "PARISC_STUBS";
- default: return NULL;
- }
-}
-
-static const char *
-get_ia64_section_type_name (Filedata * filedata, unsigned int sh_type)
-{
- /* If the top 8 bits are 0x78 the next 8 are the os/abi ID. */
- if ((sh_type & 0xFF000000) == SHT_IA_64_LOPSREG)
- return get_osabi_name (filedata, (sh_type & 0x00FF0000) >> 16);
-
- switch (sh_type)
- {
- case SHT_IA_64_EXT: return "IA_64_EXT";
- case SHT_IA_64_UNWIND: return "IA_64_UNWIND";
- case SHT_IA_64_PRIORITY_INIT: return "IA_64_PRIORITY_INIT";
- default:
- break;
- }
- return NULL;
-}
-
-static const char *
-get_vms_section_type_name (unsigned int sh_type)
-{
- switch (sh_type)
- {
- case SHT_IA_64_VMS_TRACE: return "VMS_TRACE";
- case SHT_IA_64_VMS_TIE_SIGNATURES: return "VMS_TIE_SIGNATURES";
- case SHT_IA_64_VMS_DEBUG: return "VMS_DEBUG";
- case SHT_IA_64_VMS_DEBUG_STR: return "VMS_DEBUG_STR";
- case SHT_IA_64_VMS_LINKAGES: return "VMS_LINKAGES";
- case SHT_IA_64_VMS_SYMBOL_VECTOR: return "VMS_SYMBOL_VECTOR";
- case SHT_IA_64_VMS_FIXUP: return "VMS_FIXUP";
- default:
- break;
- }
- return NULL;
-}
-
-static const char *
-get_x86_64_section_type_name (unsigned int sh_type)
-{
- switch (sh_type)
- {
- case SHT_X86_64_UNWIND: return "X86_64_UNWIND";
- default: return NULL;
- }
-}
-
-static const char *
-get_aarch64_section_type_name (unsigned int sh_type)
-{
- switch (sh_type)
- {
- case SHT_AARCH64_ATTRIBUTES:
- return "AARCH64_ATTRIBUTES";
- case SHT_AARCH64_AUTH_RELR:
- return "AARCH64_AUTH_RELR";
- case SHT_AARCH64_MEMTAG_GLOBALS_STATIC:
- return "AARCH64_MEMTAG_GLOBALS_STATIC";
- case SHT_AARCH64_MEMTAG_GLOBALS_DYNAMIC:
- return "AARCH64_MEMTAG_GLOBALS_DYNAMIC";
- default:
- return NULL;
- }
-}
-
-static const char *
-get_arm_section_type_name (unsigned int sh_type)
-{
- switch (sh_type)
- {
- case SHT_ARM_EXIDX: return "ARM_EXIDX";
- case SHT_ARM_PREEMPTMAP: return "ARM_PREEMPTMAP";
- case SHT_ARM_ATTRIBUTES: return "ARM_ATTRIBUTES";
- case SHT_ARM_DEBUGOVERLAY: return "ARM_DEBUGOVERLAY";
- case SHT_ARM_OVERLAYSECTION: return "ARM_OVERLAYSECTION";
- default: return NULL;
- }
-}
-
-static const char *
-get_tic6x_section_type_name (unsigned int sh_type)
-{
- switch (sh_type)
- {
- case SHT_C6000_UNWIND: return "C6000_UNWIND";
- case SHT_C6000_PREEMPTMAP: return "C6000_PREEMPTMAP";
- case SHT_C6000_ATTRIBUTES: return "C6000_ATTRIBUTES";
- case SHT_TI_ICODE: return "TI_ICODE";
- case SHT_TI_XREF: return "TI_XREF";
- case SHT_TI_HANDLER: return "TI_HANDLER";
- case SHT_TI_INITINFO: return "TI_INITINFO";
- case SHT_TI_PHATTRS: return "TI_PHATTRS";
- default: return NULL;
- }
-}
-
-static const char *
-get_msp430_section_type_name (unsigned int sh_type)
-{
- switch (sh_type)
- {
- case SHT_MSP430_SEC_FLAGS: return "MSP430_SEC_FLAGS";
- case SHT_MSP430_SYM_ALIASES: return "MSP430_SYM_ALIASES";
- case SHT_MSP430_ATTRIBUTES: return "MSP430_ATTRIBUTES";
- default: return NULL;
- }
-}
-
-static const char *
-get_nfp_section_type_name (unsigned int sh_type)
-{
- switch (sh_type)
- {
- case SHT_NFP_MECONFIG: return "NFP_MECONFIG";
- case SHT_NFP_INITREG: return "NFP_INITREG";
- case SHT_NFP_UDEBUG: return "NFP_UDEBUG";
- default: return NULL;
- }
-}
-
-static const char *
-get_v850_section_type_name (unsigned int sh_type)
-{
- switch (sh_type)
- {
- case SHT_V850_SCOMMON: return "V850 Small Common";
- case SHT_V850_TCOMMON: return "V850 Tiny Common";
- case SHT_V850_ZCOMMON: return "V850 Zero Common";
- case SHT_RENESAS_IOP: return "RENESAS IOP";
- case SHT_RENESAS_INFO: return "RENESAS INFO";
- default: return NULL;
- }
-}
-
-static const char *
-get_riscv_section_type_name (unsigned int sh_type)
-{
- switch (sh_type)
- {
- case SHT_RISCV_ATTRIBUTES: return "RISCV_ATTRIBUTES";
- default: return NULL;
- }
-}
-
-static const char *
-get_csky_section_type_name (unsigned int sh_type)
-{
- switch (sh_type)
- {
- case SHT_CSKY_ATTRIBUTES: return "CSKY_ATTRIBUTES";
- default: return NULL;
- }
-}
-
-static const char *
-get_powerpc_section_type_name (unsigned int sh_type)
-{
- switch (sh_type)
- {
- case SHT_ORDERED: return "ORDERED";
- default: return NULL;
- }
-}
-
-static const char *
-get_alpha_section_type_name (unsigned int sh_type)
-{
- switch (sh_type)
- {
- case SHT_ALPHA_DEBUG: return "DEBUG";
- case SHT_ALPHA_REGINFO: return "REGINFO";
- default: return NULL;
- }
-}
-
-static const char *
-get_processor_specific_section_type_name (Filedata * filedata, unsigned int sh_type)
-{
- static char buff[32];
- const char * result = NULL;
-
- switch (filedata->file_header.e_machine)
- {
- case EM_AARCH64:
- result = get_aarch64_section_type_name (sh_type);
- break;
-
- case EM_ALPHA:
- result = get_alpha_section_type_name (sh_type);
- break;
-
- case EM_ARC:
- case EM_ARC_COMPACT:
- case EM_ARC_COMPACT2:
- case EM_ARC_COMPACT3:
- case EM_ARC_COMPACT3_64:
- result = get_arc_section_type_name (sh_type);
- break;
-
- case EM_ARM:
- result = get_arm_section_type_name (sh_type);
- break;
-
- case EM_CSKY:
- result = get_csky_section_type_name (sh_type);
- break;
-
- case EM_IA_64:
- result = get_ia64_section_type_name (filedata, sh_type);
- break;
-
- case EM_MIPS:
- case EM_MIPS_RS3_LE:
- result = get_mips_section_type_name (sh_type);
- break;
-
- case EM_MSP430:
- result = get_msp430_section_type_name (sh_type);
- break;
-
- case EM_NFP:
- result = get_nfp_section_type_name (sh_type);
- break;
-
- case EM_PARISC:
- result = get_parisc_section_type_name (sh_type);
- break;
-
- case EM_PPC64:
- case EM_PPC:
- return get_powerpc_section_type_name (sh_type);
- break;
-
- case EM_RISCV:
- result = get_riscv_section_type_name (sh_type);
- break;
-
- case EM_TI_C6000:
- result = get_tic6x_section_type_name (sh_type);
- break;
-
- case EM_V800:
- case EM_V850:
- case EM_CYGNUS_V850:
- result = get_v850_section_type_name (sh_type);
- break;
-
- case EM_X86_64:
- case EM_L1OM:
- case EM_K1OM:
- result = get_x86_64_section_type_name (sh_type);
- break;
-
- default:
- break;
- }
-
- if (result != NULL)
- return result;
-
- switch (sh_type)
- {
- /* FIXME: Are these correct ? If so, why do they not have #define's ? */
- case 0x7ffffffd: return "AUXILIARY";
- case 0x7fffffff: return "FILTER";
- default:
- break;
- }
-
- sprintf (buff, "LOPROC+%#x", sh_type - SHT_LOPROC);
- return buff;
-}
-
-static const char *
-get_os_specific_section_type_name (Filedata * filedata, unsigned int sh_type)
-{
- static char buff[32];
- const char * result = NULL;
-
- switch (filedata->file_header.e_machine)
- {
- case EM_IA_64:
- result = get_vms_section_type_name (sh_type);
- break;
- default:
- break;
- }
-
- if (result != NULL)
- return result;
-
- if (filedata->file_header.e_ident[EI_OSABI] == ELFOSABI_SOLARIS)
- result = get_solaris_section_type (sh_type);
-
- if (result != NULL)
- return result;
-
- switch (sh_type)
- {
- case SHT_GNU_INCREMENTAL_INPUTS: return "GNU_INCREMENTAL_INPUTS";
- case SHT_GNU_ATTRIBUTES: return "GNU_ATTRIBUTES";
- case SHT_GNU_HASH: return "GNU_HASH";
- case SHT_GNU_LIBLIST: return "GNU_LIBLIST";
-
- case SHT_SUNW_move: return "SUNW_MOVE";
- case SHT_SUNW_COMDAT: return "SUNW_COMDAT";
- case SHT_SUNW_syminfo: return "SUNW_SYMINFO";
- case SHT_GNU_verdef: return "VERDEF";
- case SHT_GNU_verneed: return "VERNEED";
- case SHT_GNU_versym: return "VERSYM";
-
- case SHT_LLVM_ODRTAB: return "LLVM_ODRTAB";
- case SHT_LLVM_LINKER_OPTIONS: return "LLVM_LINKER_OPTIONS";
- case SHT_LLVM_ADDRSIG: return "LLVM_ADDRSIG";
- case SHT_LLVM_DEPENDENT_LIBRARIES: return "LLVM_DEPENDENT_LIBRARIES";
- case SHT_LLVM_SYMPART: return "LLVM_SYMPART";
- case SHT_LLVM_PART_EHDR: return "LLVM_PART_EHDR";
- case SHT_LLVM_PART_PHDR: return "LLVM_PART_PHDR";
- case SHT_LLVM_BB_ADDR_MAP_V0: return "LLVM_BB_ADDR_MAP_V0";
- case SHT_LLVM_CALL_GRAPH_PROFILE: return "LLVM_CALL_GRAPH_PROFILE";
- case SHT_LLVM_BB_ADDR_MAP: return "LLVM_BB_ADDR_MAP";
- case SHT_LLVM_OFFLOADING: return "LLVM_OFFLOADING";
- case SHT_LLVM_LTO: return "LLVM_LTO";
-
- case SHT_ANDROID_REL: return "ANDROID_REL";
- case SHT_ANDROID_RELA: return "ANDROID_RELA";
- case SHT_ANDROID_RELR: return "ANDROID_RELR";
-
- case SHT_CHECKSUM: return "CHECKSUM";
-
- /* FIXME: Are these correct ? If so, why do they not have #define's ? */
- case 0x6ffffff0: return "VERSYM";
-
- default:
- break;
- }
-
- sprintf (buff, "LOOS+%#x", sh_type - SHT_LOOS);
- return buff;
-}
-
-static const char *
-get_user_specific_section_type_name (Filedata * filedata, unsigned int sh_type)
-{
- static char buff[32];
- const char * result;
-
- switch (filedata->file_header.e_machine)
- {
- case EM_V800:
- case EM_V850:
- case EM_CYGNUS_V850:
- result = get_v850_section_type_name (sh_type);
- break;
-
- default:
- result = NULL;
- break;
- }
-
- if (result != NULL)
- return result;
-
- sprintf (buff, "LOUSER+%#x", sh_type - SHT_LOUSER);
- return buff;
-}
-
-static const char *
-get_section_type_name (Filedata * filedata,
- unsigned int sh_type)
-{
- switch (sh_type)
- {
- case SHT_NULL: return "NULL";
- case SHT_PROGBITS: return "PROGBITS";
- case SHT_SYMTAB: return "SYMTAB";
- case SHT_STRTAB: return "STRTAB";
- case SHT_RELA: return "RELA";
- case SHT_HASH: return "HASH";
- case SHT_DYNAMIC: return "DYNAMIC";
- case SHT_NOTE: return "NOTE";
- case SHT_NOBITS: return "NOBITS";
- case SHT_REL: return "REL";
- case SHT_SHLIB: return "SHLIB";
- case SHT_DYNSYM: return "DYNSYM";
- /* 12 and 13 are not defined. */
- case SHT_INIT_ARRAY: return "INIT_ARRAY";
- case SHT_FINI_ARRAY: return "FINI_ARRAY";
- case SHT_PREINIT_ARRAY: return "PREINIT_ARRAY";
- case SHT_GROUP: return "GROUP";
- case SHT_SYMTAB_SHNDX: return "SYMTAB SECTION INDICES";
- case SHT_RELR: return "RELR";
- /* End of generic section types. */
-
- default:
- break;
- }
-
- if ((sh_type >= SHT_LOPROC) && (sh_type <= SHT_HIPROC))
- return get_processor_specific_section_type_name (filedata, sh_type);
-
- if ((sh_type >= SHT_LOOS) && (sh_type <= SHT_HIOS))
- return get_os_specific_section_type_name (filedata, sh_type);
-
- if ((sh_type >= SHT_LOUSER) && (sh_type <= SHT_HIUSER))
- return get_user_specific_section_type_name (filedata, sh_type);
-
- static char buff[32];
-
- /* This message is probably going to be displayed in a 15
- character wide field, so put the hex value first. */
- snprintf (buff, sizeof (buff), _("%08x: <unknown>"), sh_type);
- return buff;
-}
-
-enum long_option_values
-{
- OPTION_DEBUG_DUMP = 512,
- OPTION_DYN_SYMS,
- OPTION_LTO_SYMS,
- OPTION_DWARF_DEPTH,
- OPTION_DWARF_START,
- OPTION_DWARF_CHECK,
- OPTION_CTF_DUMP,
- OPTION_CTF_PARENT,
- OPTION_CTF_SYMBOLS,
- OPTION_CTF_STRINGS,
- OPTION_SFRAME_DUMP,
- OPTION_WITH_SYMBOL_VERSIONS,
- OPTION_RECURSE_LIMIT,
- OPTION_NO_RECURSE_LIMIT,
- OPTION_NO_DEMANGLING,
- OPTION_NO_EXTRA_SYM_INFO,
- OPTION_SYM_BASE
-};
-
-static struct option options[] =
-{
- /* Note - This table is alpha-sorted on the 'val'
- field in order to make adding new options easier. */
- {"arch-specific", no_argument, 0, 'A'},
- {"all", no_argument, 0, 'a'},
- {"demangle", optional_argument, 0, 'C'},
- {"archive-index", no_argument, 0, 'c'},
- {"use-dynamic", no_argument, 0, 'D'},
- {"dynamic", no_argument, 0, 'd'},
- {"headers", no_argument, 0, 'e'},
- {"section-groups", no_argument, 0, 'g'},
- {"help", no_argument, 0, 'H'},
- {"file-header", no_argument, 0, 'h'},
- {"histogram", no_argument, 0, 'I'},
- {"display-section", required_argument, 0, 'j'},
- {"lint", no_argument, 0, 'L'},
- {"enable-checks", no_argument, 0, 'L'},
- {"program-headers", no_argument, 0, 'l'},
- {"segments", no_argument, 0, 'l'},
- {"full-section-name",no_argument, 0, 'N'},
- {"notes", no_argument, 0, 'n'},
- {"process-links", no_argument, 0, 'P'},
- {"string-dump", required_argument, 0, 'p'},
- {"relocated-dump", required_argument, 0, 'R'},
- {"relocs", no_argument, 0, 'r'},
- {"section-headers", no_argument, 0, 'S'},
- {"sections", no_argument, 0, 'S'},
- {"symbols", no_argument, 0, 's'},
- {"syms", no_argument, 0, 's'},
- {"silent-truncation",no_argument, 0, 'T'},
- {"section-details", no_argument, 0, 't'},
- {"unicode", required_argument, NULL, 'U'},
- {"unwind", no_argument, 0, 'u'},
- {"version-info", no_argument, 0, 'V'},
- {"version", no_argument, 0, 'v'},
- {"wide", no_argument, 0, 'W'},
- {"extra-sym-info", no_argument, 0, 'X'},
- {"hex-dump", required_argument, 0, 'x'},
- {"decompress", no_argument, 0, 'z'},
-
- {"no-demangle", no_argument, 0, OPTION_NO_DEMANGLING},
- {"no-extra-sym-info",no_argument, 0, OPTION_NO_EXTRA_SYM_INFO},
- {"recurse-limit", no_argument, NULL, OPTION_RECURSE_LIMIT},
- {"no-recurse-limit", no_argument, NULL, OPTION_NO_RECURSE_LIMIT},
- {"no-recursion-limit", no_argument, NULL, OPTION_NO_RECURSE_LIMIT},
- {"dyn-syms", no_argument, 0, OPTION_DYN_SYMS},
- {"lto-syms", no_argument, 0, OPTION_LTO_SYMS},
- {"debug-dump", optional_argument, 0, OPTION_DEBUG_DUMP},
- {"dwarf-depth", required_argument, 0, OPTION_DWARF_DEPTH},
- {"dwarf-start", required_argument, 0, OPTION_DWARF_START},
- {"dwarf-check", no_argument, 0, OPTION_DWARF_CHECK},
-#ifdef ENABLE_LIBCTF
- {"ctf", required_argument, 0, OPTION_CTF_DUMP},
- {"ctf-symbols", required_argument, 0, OPTION_CTF_SYMBOLS},
- {"ctf-strings", required_argument, 0, OPTION_CTF_STRINGS},
- {"ctf-parent", required_argument, 0, OPTION_CTF_PARENT},
-#endif
- {"sframe", optional_argument, 0, OPTION_SFRAME_DUMP},
- {"sym-base", optional_argument, 0, OPTION_SYM_BASE},
-
- {0, no_argument, 0, 0}
-};
-
-static void
-usage (FILE * stream)
-{
- fprintf (stream, _("Usage: readelf <option(s)> elf-file(s)\n"));
- fprintf (stream, _(" Display information about the contents of ELF format files\n"));
- fprintf (stream, _(" Options are:\n"));
- fprintf (stream, _("\
- -a --all Equivalent to: -h -l -S -s -r -d -V -A -I\n"));
- fprintf (stream, _("\
- -h --file-header Display the ELF file header\n"));
- fprintf (stream, _("\
- -l --program-headers Display the program headers\n"));
- fprintf (stream, _("\
- --segments An alias for --program-headers\n"));
- fprintf (stream, _("\
- -S --section-headers Display the sections' header\n"));
- fprintf (stream, _("\
- --sections An alias for --section-headers\n"));
- fprintf (stream, _("\
- -g --section-groups Display the section groups\n"));
- fprintf (stream, _("\
- -t --section-details Display the section details\n"));
- fprintf (stream, _("\
- -e --headers Equivalent to: -h -l -S\n"));
- fprintf (stream, _("\
- -s --syms Display the symbol table\n"));
- fprintf (stream, _("\
- --symbols An alias for --syms\n"));
- fprintf (stream, _("\
- --dyn-syms Display the dynamic symbol table\n"));
- fprintf (stream, _("\
- --lto-syms Display LTO symbol tables\n"));
- fprintf (stream, _("\
- --sym-base=[0|8|10|16] \n\
- Force base for symbol sizes. The options are \n\
- mixed (the default), octal, decimal, hexadecimal.\n"));
- fprintf (stream, _("\
- -C --demangle[=STYLE] Decode mangled/processed symbol names\n"));
- display_demangler_styles (stream, _("\
- STYLE can be "));
- fprintf (stream, _("\
- --no-demangle Do not demangle low-level symbol names. (default)\n"));
- fprintf (stream, _("\
- --recurse-limit Enable a demangling recursion limit. (default)\n"));
- fprintf (stream, _("\
- --no-recurse-limit Disable a demangling recursion limit\n"));
- fprintf (stream, _("\
- -U[dlexhi] --unicode=[default|locale|escape|hex|highlight|invalid]\n\
- Display unicode characters as determined by the current locale\n\
- (default), escape sequences, \"<hex sequences>\", highlighted\n\
- escape sequences, or treat them as invalid and display as\n\
- \"{hex sequences}\"\n"));
- fprintf (stream, _("\
- -X --extra-sym-info Display extra information when showing symbols\n"));
- fprintf (stream, _("\
- --no-extra-sym-info Do not display extra information when showing symbols (default)\n"));
- fprintf (stream, _("\
- -n --notes Display the contents of note sections (if present)\n"));
- fprintf (stream, _("\
- -r --relocs Display the relocations (if present)\n"));
- fprintf (stream, _("\
- -u --unwind Display the unwind info (if present)\n"));
- fprintf (stream, _("\
- -d --dynamic Display the dynamic section (if present)\n"));
- fprintf (stream, _("\
- -V --version-info Display the version sections (if present)\n"));
- fprintf (stream, _("\
- -A --arch-specific Display architecture specific information (if any)\n"));
- fprintf (stream, _("\
- -c --archive-index Display the symbol/file index in an archive\n"));
- fprintf (stream, _("\
- -D --use-dynamic Use the dynamic section info when displaying symbols\n"));
- fprintf (stream, _("\
- -L --lint|--enable-checks\n\
- Display warning messages for possible problems\n"));
- fprintf (stream, _("\
- -x --hex-dump=<number|name>\n\
- Dump the contents of section <number|name> as bytes\n"));
- fprintf (stream, _("\
- -p --string-dump=<number|name>\n\
- Dump the contents of section <number|name> as strings\n"));
- fprintf (stream, _("\
- -R --relocated-dump=<number|name>\n\
- Dump the relocated contents of section <number|name>\n"));
- fprintf (stream, _("\
- -z --decompress Decompress section before dumping it\n"));
- fprintf (stream, _("\n\
- -j --display-section=<name|number>\n\
- Display the contents of the indicated section. Can be repeated\n"));
- fprintf (stream, _("\
- -w --debug-dump[a/=abbrev, A/=addr, r/=aranges, c/=cu_index, L/=decodedline,\n\
- f/=frames, F/=frames-interp, g/=gdb_index, i/=info, o/=loc,\n\
- m/=macro, p/=pubnames, t/=pubtypes, R/=Ranges, l/=rawline,\n\
- s/=str, O/=str-offsets, u/=trace_abbrev, T/=trace_aranges,\n\
- U/=trace_info]\n\
- Display the contents of DWARF debug sections\n"));
- fprintf (stream, _("\
- -wk --debug-dump=links Display the contents of sections that link to separate\n\
- debuginfo files\n"));
- fprintf (stream, _("\
- -P --process-links Display the contents of non-debug sections in separate\n\
- debuginfo files. (Implies -wK)\n"));
-#if DEFAULT_FOR_FOLLOW_LINKS
- fprintf (stream, _("\
- -wK --debug-dump=follow-links\n\
- Follow links to separate debug info files (default)\n"));
- fprintf (stream, _("\
- -wN --debug-dump=no-follow-links\n\
- Do not follow links to separate debug info files\n"));
-#else
- fprintf (stream, _("\
- -wK --debug-dump=follow-links\n\
- Follow links to separate debug info files\n"));
- fprintf (stream, _("\
- -wN --debug-dump=no-follow-links\n\
- Do not follow links to separate debug info files\n\
- (default)\n"));
-#endif
-#if HAVE_LIBDEBUGINFOD
- fprintf (stream, _("\
- -wD --debug-dump=use-debuginfod\n\
- When following links, also query debuginfod servers (default)\n"));
- fprintf (stream, _("\
- -wE --debug-dump=do-not-use-debuginfod\n\
- When following links, do not query debuginfod servers\n"));
-#endif
- fprintf (stream, _("\
- --dwarf-depth=N Do not display DIEs at depth N or greater\n"));
- fprintf (stream, _("\
- --dwarf-start=N Display DIEs starting at offset N\n"));
-#ifdef ENABLE_LIBCTF
- fprintf (stream, _("\
- --ctf=<number|name> Display CTF info from section <number|name>\n"));
- fprintf (stream, _("\
- --ctf-parent=<name> Use CTF archive member <name> as the CTF parent\n"));
- fprintf (stream, _("\
- --ctf-symbols=<number|name>\n\
- Use section <number|name> as the CTF external symtab\n"));
- fprintf (stream, _("\
- --ctf-strings=<number|name>\n\
- Use section <number|name> as the CTF external strtab\n"));
-#endif
- fprintf (stream, _("\
- --sframe[=NAME] Display SFrame info from section NAME, (default '.sframe')\n"));
-
-#ifdef SUPPORT_DISASSEMBLY
- fprintf (stream, _("\
- -i --instruction-dump=<number|name>\n\
- Disassemble the contents of section <number|name>\n"));
-#endif
- fprintf (stream, _("\
- -I --histogram Display histogram of bucket list lengths\n"));
- fprintf (stream, _("\
- -W --wide Allow output width to exceed 80 characters\n"));
- fprintf (stream, _("\
- -T --silent-truncation If a symbol name is truncated, do not add [...] suffix\n"));
- fprintf (stream, _("\
- @<file> Read options from <file>\n"));
- fprintf (stream, _("\
- -H --help Display this information\n"));
- fprintf (stream, _("\
- -v --version Display the version number of readelf\n"));
-
- if (REPORT_BUGS_TO[0] && stream == stdout)
- fprintf (stdout, _("Report bugs to %s\n"), REPORT_BUGS_TO);
-
- exit (stream == stdout ? 0 : 1);
-}
-
-/* Record the fact that the user wants the contents of section number
- SECTION to be displayed using the method(s) encoded as flags bits
- in TYPE. Note, TYPE can be zero if we are creating the array for
- the first time. */
-
-static void
-request_dump_bynumber (struct dump_data *dumpdata,
- unsigned int section, dump_type type)
-{
- if (section >= dumpdata->num_dump_sects)
- {
- dump_type * new_dump_sects;
-
- new_dump_sects = (dump_type *) calloc (section + 1,
- sizeof (* new_dump_sects));
-
- if (new_dump_sects == NULL)
- error (_("Out of memory allocating dump request table.\n"));
- else
- {
- if (dumpdata->dump_sects)
- {
- /* Copy current flag settings. */
- memcpy (new_dump_sects, dumpdata->dump_sects,
- dumpdata->num_dump_sects * sizeof (* new_dump_sects));
-
- free (dumpdata->dump_sects);
- }
-
- dumpdata->dump_sects = new_dump_sects;
- dumpdata->num_dump_sects = section + 1;
- }
- }
-
- if (dumpdata->dump_sects)
- dumpdata->dump_sects[section] |= type;
-}
-
-/* Request a dump by section name. */
-
-static void
-request_dump_byname (const char * section, dump_type type)
-{
- struct dump_list_entry * new_request;
-
- new_request = (struct dump_list_entry *)
- malloc (sizeof (struct dump_list_entry));
- if (!new_request)
- error (_("Out of memory allocating dump request table.\n"));
-
- new_request->name = strdup (section);
- if (!new_request->name)
- error (_("Out of memory allocating dump request table.\n"));
-
- new_request->type = type;
-
- new_request->next = dump_sects_byname;
- dump_sects_byname = new_request;
-}
-
-static inline void
-request_dump (struct dump_data *dumpdata, dump_type type)
-{
- int section;
- char * cp;
-
- do_dump = true;
- section = strtoul (optarg, & cp, 0);
-
- if (! *cp && section >= 0)
- request_dump_bynumber (dumpdata, section, type);
- else
- request_dump_byname (optarg, type);
-}
-
-static void
-parse_args (struct dump_data *dumpdata, int argc, char ** argv)
-{
- int c;
-
- if (argc < 2)
- usage (stderr);
-
- while ((c = getopt_long
- (argc, argv, "ACDHILNPR:STU:VWXacdeghi:j:lnp:rstuvw::x:z", options, NULL)) != EOF)
- {
- switch (c)
- {
- case 0:
- /* Long options. */
- break;
- case 'H':
- usage (stdout);
- break;
-
- case 'a':
- do_syms = true;
- do_reloc = true;
- do_unwind = true;
- do_dynamic = true;
- do_header = true;
- do_sections = true;
- do_section_groups = true;
- do_segments = true;
- do_version = true;
- do_histogram = true;
- do_arch = true;
- do_notes = true;
- break;
-
- case 'g':
- do_section_groups = true;
- break;
- case 't':
- case 'N':
- do_sections = true;
- do_section_details = true;
- break;
- case 'e':
- do_header = true;
- do_sections = true;
- do_segments = true;
- break;
- case 'A':
- do_arch = true;
- break;
- case 'D':
- do_using_dynamic = true;
- break;
- case 'r':
- do_reloc = true;
- break;
- case 'u':
- do_unwind = true;
- break;
- case 'h':
- do_header = true;
- break;
- case 'l':
- do_segments = true;
- break;
- case 's':
- do_syms = true;
- break;
- case 'S':
- do_sections = true;
- break;
- case 'd':
- do_dynamic = true;
- break;
- case 'I':
- do_histogram = true;
- break;
- case 'n':
- do_notes = true;
- break;
- case 'c':
- do_archive_index = true;
- break;
- case 'L':
- do_checks = true;
- break;
- case 'P':
- process_links = true;
- do_follow_links = true;
- dump_any_debugging = true;
- break;
- case 'j':
- request_dump (dumpdata, AUTO_DUMP);
- break;
- case 'x':
- request_dump (dumpdata, HEX_DUMP);
- break;
- case 'p':
- request_dump (dumpdata, STRING_DUMP);
- break;
- case 'R':
- request_dump (dumpdata, RELOC_DUMP);
- break;
- case 'z':
- decompress_dumps = true;
- break;
- case 'w':
- if (optarg == NULL)
- {
- do_debugging = true;
- do_dump = true;
- dump_any_debugging = true;
- dwarf_select_sections_all ();
- }
- else
- {
- do_debugging = false;
- if (dwarf_select_sections_by_letters (optarg))
- {
- do_dump = true;
- dump_any_debugging = true;
- }
- }
- break;
- case OPTION_DEBUG_DUMP:
- if (optarg == NULL)
- {
- do_dump = true;
- do_debugging = true;
- dump_any_debugging = true;
- dwarf_select_sections_all ();
- }
- else
- {
- do_debugging = false;
- if (dwarf_select_sections_by_names (optarg))
- {
- do_dump = true;
- dump_any_debugging = true;
- }
- }
- break;
- case OPTION_DWARF_DEPTH:
- {
- char *cp;
-
- dwarf_cutoff_level = strtoul (optarg, & cp, 0);
- }
- break;
- case OPTION_DWARF_START:
- {
- char *cp;
-
- dwarf_start_die = strtoul (optarg, & cp, 0);
- }
- break;
- case OPTION_DWARF_CHECK:
- dwarf_check = true;
- break;
- case OPTION_CTF_DUMP:
- do_ctf = true;
- request_dump (dumpdata, CTF_DUMP);
- break;
- case OPTION_CTF_SYMBOLS:
- free (dump_ctf_symtab_name);
- dump_ctf_symtab_name = strdup (optarg);
- break;
- case OPTION_CTF_STRINGS:
- free (dump_ctf_strtab_name);
- dump_ctf_strtab_name = strdup (optarg);
- break;
- case OPTION_CTF_PARENT:
- free (dump_ctf_parent_name);
- dump_ctf_parent_name = strdup (optarg);
- break;
- case OPTION_SFRAME_DUMP:
- do_sframe = true;
- /* Providing section name is optional. request_dump (), however,
- thrives on non NULL optarg. Handle it explicitly here. */
- if (optarg != NULL)
- request_dump (dumpdata, SFRAME_DUMP);
- else
- {
- do_dump = true;
- const char *sframe_sec_name = strdup (".sframe");
- request_dump_byname (sframe_sec_name, SFRAME_DUMP);
- }
- break;
- case OPTION_DYN_SYMS:
- do_dyn_syms = true;
- break;
- case OPTION_LTO_SYMS:
- do_lto_syms = true;
- break;
- case 'X':
- extra_sym_info = true;
- break;
- case OPTION_NO_EXTRA_SYM_INFO:
- extra_sym_info = false;
- break;
-
-#ifdef SUPPORT_DISASSEMBLY
- case 'i':
- request_dump (dumpdata, DISASS_DUMP);
- break;
-#endif
- case 'v':
- print_version (program_name);
- break;
- case 'V':
- do_version = true;
- break;
- case 'W':
- do_wide = true;
- break;
- case 'T':
- do_not_show_symbol_truncation = true;
- break;
- case 'C':
- do_demangle = true;
- if (optarg != NULL)
- {
- enum demangling_styles style;
-
- style = cplus_demangle_name_to_style (optarg);
- if (style == unknown_demangling)
- error (_("unknown demangling style `%s'"), optarg);
-
- cplus_demangle_set_style (style);
- }
- break;
- case OPTION_NO_DEMANGLING:
- do_demangle = false;
- break;
- case OPTION_RECURSE_LIMIT:
- demangle_flags &= ~ DMGL_NO_RECURSE_LIMIT;
- break;
- case OPTION_NO_RECURSE_LIMIT:
- demangle_flags |= DMGL_NO_RECURSE_LIMIT;
- break;
- case OPTION_WITH_SYMBOL_VERSIONS:
- /* Ignored for backward compatibility. */
- break;
-
- case 'U':
- if (optarg == NULL)
- error (_("Missing arg to -U/--unicode")); /* Can this happen ? */
- else if (streq (optarg, "default") || streq (optarg, "d"))
- unicode_display = unicode_default;
- else if (streq (optarg, "locale") || streq (optarg, "l"))
- unicode_display = unicode_locale;
- else if (streq (optarg, "escape") || streq (optarg, "e"))
- unicode_display = unicode_escape;
- else if (streq (optarg, "invalid") || streq (optarg, "i"))
- unicode_display = unicode_invalid;
- else if (streq (optarg, "hex") || streq (optarg, "x"))
- unicode_display = unicode_hex;
- else if (streq (optarg, "highlight") || streq (optarg, "h"))
- unicode_display = unicode_highlight;
- else
- error (_("invalid argument to -U/--unicode: %s"), optarg);
- break;
-
- case OPTION_SYM_BASE:
- sym_base = 0;
- if (optarg != NULL)
- {
- sym_base = strtoul (optarg, NULL, 0);
- switch (sym_base)
- {
- case 0:
- case 8:
- case 10:
- case 16:
- break;
-
- default:
- sym_base = 0;
- break;
- }
- }
- break;
-
- default:
- /* xgettext:c-format */
- error (_("Invalid option '-%c'\n"), c);
- /* Fall through. */
- case '?':
- usage (stderr);
- }
- }
-
- if (!do_dynamic && !do_syms && !do_reloc && !do_unwind && !do_sections
- && !do_segments && !do_header && !do_dump && !do_version
- && !do_histogram && !do_debugging && !do_arch && !do_notes
- && !do_section_groups && !do_archive_index
- && !do_dyn_syms && !do_lto_syms)
- {
- if (do_checks)
- {
- check_all = true;
- do_dynamic = do_syms = do_reloc = do_unwind = do_sections = true;
- do_segments = do_header = do_dump = do_version = true;
- do_histogram = do_debugging = do_arch = do_notes = true;
- do_section_groups = do_archive_index = do_dyn_syms = true;
- do_lto_syms = true;
- }
- else
- usage (stderr);
- }
-}
-
-static const char *
-get_elf_class (unsigned int elf_class)
-{
- static char buff[32];
-
- switch (elf_class)
- {
- case ELFCLASSNONE: return _("none");
- case ELFCLASS32: return "ELF32";
- case ELFCLASS64: return "ELF64";
- default:
- snprintf (buff, sizeof (buff), _("<unknown: %x>"), elf_class);
- return buff;
- }
-}
-
-static const char *
-get_data_encoding (unsigned int encoding)
-{
- static char buff[32];
-
- switch (encoding)
- {
- case ELFDATANONE: return _("none");
- case ELFDATA2LSB: return _("2's complement, little endian");
- case ELFDATA2MSB: return _("2's complement, big endian");
- default:
- snprintf (buff, sizeof (buff), _("<unknown: %x>"), encoding);
- return buff;
- }
-}
-
-static bool
-check_magic_number (Filedata * filedata, Elf_Internal_Ehdr * header)
-{
- if (header->e_ident[EI_MAG0] == ELFMAG0
- && header->e_ident[EI_MAG1] == ELFMAG1
- && header->e_ident[EI_MAG2] == ELFMAG2
- && header->e_ident[EI_MAG3] == ELFMAG3)
- return true;
-
- /* Some compilers produce object files that are not in the ELF file format.
- As an aid to users of readelf, try to identify these cases and suggest
- alternative tools.
-
- FIXME: It is not clear if all four bytes are used as constant magic
- valus by all compilers. It may be necessary to recode this function if
- different tools use different length sequences. */
-
- static struct
- {
- unsigned char magic[4];
- const char * obj_message;
- const char * ar_message;
- }
- known_magic[] =
- {
- { { 'B', 'C', 0xc0, 0xde },
- N_("This is a LLVM bitcode file - try using llvm-bcanalyzer\n"),
- N_("This is a LLVM bitcode file - try extracting and then using llvm-bcanalyzer\n")
- },
- { { 'g', 'o', ' ', 'o' },
- N_("This is a GO binary file - try using 'go tool objdump' or 'go tool nm'\n"),
- NULL
- }
- };
- int i;
-
- for (i = ARRAY_SIZE (known_magic); i--;)
- {
- if (header->e_ident[EI_MAG0] == known_magic[i].magic[0]
- && header->e_ident[EI_MAG1] == known_magic[i].magic[1]
- && header->e_ident[EI_MAG2] == known_magic[i].magic[2]
- && header->e_ident[EI_MAG3] == known_magic[i].magic[3])
- {
- /* Some compiler's analyzer tools do not handle archives,
- so we provide two different kinds of error message. */
- if (filedata->archive_file_size > 0
- && known_magic[i].ar_message != NULL)
- error ("%s", known_magic[i].ar_message);
- else
- error ("%s", known_magic[i].obj_message);
- return false;
- }
- }
-
- error (_("Not an ELF file - it has the wrong magic bytes at the start\n"));
- return false;
-}
-
-/* Decode the data held in 'filedata->file_header'. */
-
-static bool
-process_file_header (Filedata * filedata)
-{
- Elf_Internal_Ehdr * header = & filedata->file_header;
-
- if (! check_magic_number (filedata, header))
- return false;
-
- if (! filedata->is_separate)
- init_dwarf_regnames_by_elf_machine_code (header->e_machine);
-
- if (do_header)
- {
- unsigned i;
-
- if (filedata->is_separate)
- printf (_("ELF Header in linked file '%s':\n"), filedata->file_name);
- else
- printf (_("ELF Header:\n"));
- printf (_(" Magic: "));
- for (i = 0; i < EI_NIDENT; i++)
- printf ("%2.2x ", header->e_ident[i]);
- printf ("\n");
- printf (_(" Class: %s\n"),
- get_elf_class (header->e_ident[EI_CLASS]));
- printf (_(" Data: %s\n"),
- get_data_encoding (header->e_ident[EI_DATA]));
- printf (_(" Version: %d%s\n"),
- header->e_ident[EI_VERSION],
- (header->e_ident[EI_VERSION] == EV_CURRENT
- ? _(" (current)")
- : (header->e_ident[EI_VERSION] != EV_NONE
- ? _(" <unknown>")
- : "")));
- printf (_(" OS/ABI: %s\n"),
- get_osabi_name (filedata, header->e_ident[EI_OSABI]));
- printf (_(" ABI Version: %d\n"),
- header->e_ident[EI_ABIVERSION]);
- printf (_(" Type: %s\n"),
- get_file_type (filedata));
- printf (_(" Machine: %s\n"),
- get_machine_name (header->e_machine));
- printf (_(" Version: 0x%lx\n"),
- header->e_version);
-
- printf (_(" Entry point address: "));
- print_vma (header->e_entry, PREFIX_HEX);
- printf (_("\n Start of program headers: "));
- print_vma (header->e_phoff, DEC);
- printf (_(" (bytes into file)\n Start of section headers: "));
- print_vma (header->e_shoff, DEC);
- printf (_(" (bytes into file)\n"));
-
- printf (_(" Flags: 0x%lx%s\n"),
- header->e_flags,
- get_machine_flags (filedata, header->e_flags, header->e_machine));
- printf (_(" Size of this header: %u (bytes)\n"),
- header->e_ehsize);
- printf (_(" Size of program headers: %u (bytes)\n"),
- header->e_phentsize);
- printf (_(" Number of program headers: %u"),
- header->e_phnum);
- if (filedata->section_headers != NULL
- && header->e_phnum == PN_XNUM
- && filedata->section_headers[0].sh_info != 0)
- printf (" (%u)", filedata->section_headers[0].sh_info);
- putc ('\n', stdout);
- printf (_(" Size of section headers: %u (bytes)\n"),
- header->e_shentsize);
- printf (_(" Number of section headers: %u"),
- header->e_shnum);
- if (filedata->section_headers != NULL && header->e_shnum == SHN_UNDEF)
- {
- header->e_shnum = filedata->section_headers[0].sh_size;
- printf (" (%u)", header->e_shnum);
- }
- putc ('\n', stdout);
- printf (_(" Section header string table index: %u"),
- header->e_shstrndx);
- if (filedata->section_headers != NULL
- && header->e_shstrndx == (SHN_XINDEX & 0xffff))
- {
- header->e_shstrndx = filedata->section_headers[0].sh_link;
- printf (" (%u)", header->e_shstrndx);
- }
- if (header->e_shstrndx != SHN_UNDEF
- && header->e_shstrndx >= header->e_shnum)
- {
- header->e_shstrndx = SHN_UNDEF;
- printf (_(" <corrupt: out of range>"));
- }
- putc ('\n', stdout);
- }
-
- if (filedata->section_headers != NULL)
- {
- if (header->e_phnum == PN_XNUM
- && filedata->section_headers[0].sh_info != 0)
- {
- /* Throw away any cached read of PN_XNUM headers. */
- free (filedata->program_headers);
- filedata->program_headers = NULL;
- header->e_phnum = filedata->section_headers[0].sh_info;
- }
- if (header->e_shnum == SHN_UNDEF)
- header->e_shnum = filedata->section_headers[0].sh_size;
- if (header->e_shstrndx == (SHN_XINDEX & 0xffff))
- header->e_shstrndx = filedata->section_headers[0].sh_link;
- if (header->e_shstrndx >= header->e_shnum)
- header->e_shstrndx = SHN_UNDEF;
- }
-
- return true;
-}
-
-/* Read in the program headers from FILEDATA and store them in PHEADERS.
- Returns TRUE upon success, FALSE otherwise. Loads 32-bit headers. */
-
-static bool
-get_32bit_program_headers (Filedata * filedata, Elf_Internal_Phdr * pheaders)
-{
- Elf32_External_Phdr * phdrs;
- Elf32_External_Phdr * external;
- Elf_Internal_Phdr * internal;
- unsigned int i;
- unsigned int size = filedata->file_header.e_phentsize;
- unsigned int num = filedata->file_header.e_phnum;
-
- /* PR binutils/17531: Cope with unexpected section header sizes. */
- if (size == 0 || num == 0)
- return false;
- if (size < sizeof * phdrs)
- {
- error (_("The e_phentsize field in the ELF header is less than the size of an ELF program header\n"));
- return false;
- }
- if (size > sizeof * phdrs)
- warn (_("The e_phentsize field in the ELF header is larger than the size of an ELF program header\n"));
-
- phdrs = (Elf32_External_Phdr *) get_data (NULL, filedata, filedata->file_header.e_phoff,
- size, num, _("program headers"));
- if (phdrs == NULL)
- return false;
-
- for (i = 0, internal = pheaders, external = phdrs;
- i < filedata->file_header.e_phnum;
- i++, internal++, external++)
- {
- internal->p_type = BYTE_GET (external->p_type);
- internal->p_offset = BYTE_GET (external->p_offset);
- internal->p_vaddr = BYTE_GET (external->p_vaddr);
- internal->p_paddr = BYTE_GET (external->p_paddr);
- internal->p_filesz = BYTE_GET (external->p_filesz);
- internal->p_memsz = BYTE_GET (external->p_memsz);
- internal->p_flags = BYTE_GET (external->p_flags);
- internal->p_align = BYTE_GET (external->p_align);
- }
-
- free (phdrs);
- return true;
-}
-
-/* Read in the program headers from FILEDATA and store them in PHEADERS.
- Returns TRUE upon success, FALSE otherwise. Loads 64-bit headers. */
-
-static bool
-get_64bit_program_headers (Filedata * filedata, Elf_Internal_Phdr * pheaders)
-{
- Elf64_External_Phdr * phdrs;
- Elf64_External_Phdr * external;
- Elf_Internal_Phdr * internal;
- unsigned int i;
- unsigned int size = filedata->file_header.e_phentsize;
- unsigned int num = filedata->file_header.e_phnum;
-
- /* PR binutils/17531: Cope with unexpected section header sizes. */
- if (size == 0 || num == 0)
- return false;
- if (size < sizeof * phdrs)
- {
- error (_("The e_phentsize field in the ELF header is less than the size of an ELF program header\n"));
- return false;
- }
- if (size > sizeof * phdrs)
- warn (_("The e_phentsize field in the ELF header is larger than the size of an ELF program header\n"));
-
- phdrs = (Elf64_External_Phdr *) get_data (NULL, filedata, filedata->file_header.e_phoff,
- size, num, _("program headers"));
- if (!phdrs)
- return false;
-
- for (i = 0, internal = pheaders, external = phdrs;
- i < filedata->file_header.e_phnum;
- i++, internal++, external++)
- {
- internal->p_type = BYTE_GET (external->p_type);
- internal->p_flags = BYTE_GET (external->p_flags);
- internal->p_offset = BYTE_GET (external->p_offset);
- internal->p_vaddr = BYTE_GET (external->p_vaddr);
- internal->p_paddr = BYTE_GET (external->p_paddr);
- internal->p_filesz = BYTE_GET (external->p_filesz);
- internal->p_memsz = BYTE_GET (external->p_memsz);
- internal->p_align = BYTE_GET (external->p_align);
- }
-
- free (phdrs);
- return true;
-}
-
-/* Returns TRUE if the program headers were read into `program_headers'. */
-
-static bool
-get_program_headers (Filedata * filedata)
-{
- Elf_Internal_Phdr * phdrs;
-
- /* Check cache of prior read. */
- if (filedata->program_headers != NULL)
- return true;
-
- /* Be kind to memory checkers by looking for
- e_phnum values which we know must be invalid. */
- if (filedata->file_header.e_phnum
- * (is_32bit_elf ? sizeof (Elf32_External_Phdr) : sizeof (Elf64_External_Phdr))
- >= filedata->file_size)
- {
- error (_("Too many program headers - %#x - the file is not that big\n"),
- filedata->file_header.e_phnum);
- return false;
- }
-
- phdrs = (Elf_Internal_Phdr *) cmalloc (filedata->file_header.e_phnum,
- sizeof (Elf_Internal_Phdr));
- if (phdrs == NULL)
- {
- error (_("Out of memory reading %u program headers\n"),
- filedata->file_header.e_phnum);
- return false;
- }
-
- if (is_32bit_elf
- ? get_32bit_program_headers (filedata, phdrs)
- : get_64bit_program_headers (filedata, phdrs))
- {
- filedata->program_headers = phdrs;
- return true;
- }
-
- free (phdrs);
- return false;
-}
-
-/* Print program header info and locate dynamic section. */
-
-static void
-process_program_headers (Filedata * filedata)
-{
- Elf_Internal_Phdr * segment;
- unsigned int i;
- Elf_Internal_Phdr * previous_load = NULL;
-
- if (filedata->file_header.e_phnum == 0)
- {
- /* PR binutils/12467. */
- if (filedata->file_header.e_phoff != 0)
- warn (_("possibly corrupt ELF header - it has a non-zero program"
- " header offset, but no program headers\n"));
- else if (do_segments)
- {
- if (filedata->is_separate)
- printf (_("\nThere are no program headers in linked file '%s'.\n"),
- filedata->file_name);
- else
- printf (_("\nThere are no program headers in this file.\n"));
- }
- goto no_headers;
- }
-
- if (do_segments && !do_header)
- {
- if (filedata->is_separate)
- printf ("\nIn linked file '%s' the ELF file type is %s\n",
- filedata->file_name, get_file_type (filedata));
- else
- printf (_("\nElf file type is %s\n"), get_file_type (filedata));
- printf (_("Entry point 0x%" PRIx64 "\n"),
- filedata->file_header.e_entry);
- printf (ngettext ("There is %d program header,"
- " starting at offset %" PRIu64 "\n",
- "There are %d program headers,"
- " starting at offset %" PRIu64 "\n",
- filedata->file_header.e_phnum),
- filedata->file_header.e_phnum,
- filedata->file_header.e_phoff);
- }
-
- if (! get_program_headers (filedata))
- goto no_headers;
-
- if (do_segments)
- {
- if (filedata->file_header.e_phnum > 1)
- printf (_("\nProgram Headers:\n"));
- else
- printf (_("\nProgram Headers:\n"));
-
- if (is_32bit_elf)
- printf
- (_(" Type Offset VirtAddr PhysAddr FileSiz MemSiz Flg Align\n"));
- else if (do_wide)
- printf
- (_(" Type Offset VirtAddr PhysAddr FileSiz MemSiz Flg Align\n"));
- else
- {
- printf
- (_(" Type Offset VirtAddr PhysAddr\n"));
- printf
- (_(" FileSiz MemSiz Flags Align\n"));
- }
- }
-
- uint64_t dynamic_addr = 0;
- uint64_t dynamic_size = 0;
- for (i = 0, segment = filedata->program_headers;
- i < filedata->file_header.e_phnum;
- i++, segment++)
- {
- if (do_segments)
- {
- printf (" %-14.14s ", get_segment_type (filedata, segment->p_type));
-
- if (is_32bit_elf)
- {
- printf ("0x%6.6lx ", (unsigned long) segment->p_offset);
- printf ("0x%8.8lx ", (unsigned long) segment->p_vaddr);
- printf ("0x%8.8lx ", (unsigned long) segment->p_paddr);
- printf ("0x%5.5lx ", (unsigned long) segment->p_filesz);
- printf ("0x%5.5lx ", (unsigned long) segment->p_memsz);
- printf ("%c%c%c ",
- (segment->p_flags & PF_R ? 'R' : ' '),
- (segment->p_flags & PF_W ? 'W' : ' '),
- (segment->p_flags & PF_X ? 'E' : ' '));
- printf ("%#lx", (unsigned long) segment->p_align);
- }
- else if (do_wide)
- {
- if ((unsigned long) segment->p_offset == segment->p_offset)
- printf ("0x%6.6lx ", (unsigned long) segment->p_offset);
- else
- {
- print_vma (segment->p_offset, FULL_HEX);
- putchar (' ');
- }
-
- print_vma (segment->p_vaddr, FULL_HEX);
- putchar (' ');
- print_vma (segment->p_paddr, FULL_HEX);
- putchar (' ');
-
- if ((unsigned long) segment->p_filesz == segment->p_filesz)
- printf ("0x%6.6lx ", (unsigned long) segment->p_filesz);
- else
- {
- print_vma (segment->p_filesz, FULL_HEX);
- putchar (' ');
- }
-
- if ((unsigned long) segment->p_memsz == segment->p_memsz)
- printf ("0x%6.6lx", (unsigned long) segment->p_memsz);
- else
- {
- print_vma (segment->p_memsz, FULL_HEX);
- }
-
- printf (" %c%c%c ",
- (segment->p_flags & PF_R ? 'R' : ' '),
- (segment->p_flags & PF_W ? 'W' : ' '),
- (segment->p_flags & PF_X ? 'E' : ' '));
-
- if ((unsigned long) segment->p_align == segment->p_align)
- printf ("%#lx", (unsigned long) segment->p_align);
- else
- {
- print_vma (segment->p_align, PREFIX_HEX);
- }
- }
- else
- {
- print_vma (segment->p_offset, FULL_HEX);
- putchar (' ');
- print_vma (segment->p_vaddr, FULL_HEX);
- putchar (' ');
- print_vma (segment->p_paddr, FULL_HEX);
- printf ("\n ");
- print_vma (segment->p_filesz, FULL_HEX);
- putchar (' ');
- print_vma (segment->p_memsz, FULL_HEX);
- printf (" %c%c%c ",
- (segment->p_flags & PF_R ? 'R' : ' '),
- (segment->p_flags & PF_W ? 'W' : ' '),
- (segment->p_flags & PF_X ? 'E' : ' '));
- print_vma (segment->p_align, PREFIX_HEX);
- }
-
- putc ('\n', stdout);
- }
-
- switch (segment->p_type)
- {
- case PT_LOAD:
-#if 0 /* Do not warn about out of order PT_LOAD segments. Although officially
- required by the ELF standard, several programs, including the Linux
- kernel, make use of non-ordered segments. */
- if (previous_load
- && previous_load->p_vaddr > segment->p_vaddr)
- error (_("LOAD segments must be sorted in order of increasing VirtAddr\n"));
-#endif
- if (segment->p_memsz < segment->p_filesz)
- error (_("the segment's file size is larger than its memory size\n"));
- previous_load = segment;
- break;
-
- case PT_PHDR:
- /* PR 20815 - Verify that the program header is loaded into memory. */
- if (i > 0 && previous_load != NULL)
- error (_("the PHDR segment must occur before any LOAD segment\n"));
- if (filedata->file_header.e_machine != EM_PARISC)
- {
- unsigned int j;
-
- for (j = 1; j < filedata->file_header.e_phnum; j++)
- {
- Elf_Internal_Phdr *load = filedata->program_headers + j;
- if (load->p_type == PT_LOAD
- && load->p_offset <= segment->p_offset
- && (load->p_offset + load->p_filesz
- >= segment->p_offset + segment->p_filesz)
- && load->p_vaddr <= segment->p_vaddr
- && (load->p_vaddr + load->p_filesz
- >= segment->p_vaddr + segment->p_filesz))
- break;
- }
- if (j == filedata->file_header.e_phnum)
- error (_("the PHDR segment is not covered by a LOAD segment\n"));
- }
- break;
-
- case PT_DYNAMIC:
- if (dynamic_addr)
- error (_("more than one dynamic segment\n"));
-
- /* By default, assume that the .dynamic section is the first
- section in the DYNAMIC segment. */
- dynamic_addr = segment->p_offset;
- dynamic_size = segment->p_filesz;
-
- /* Try to locate the .dynamic section. If there is
- a section header table, we can easily locate it. */
- if (filedata->section_headers != NULL)
- {
- Elf_Internal_Shdr * sec;
-
- sec = find_section (filedata, ".dynamic");
- if (sec == NULL || sec->sh_size == 0)
- {
- /* A corresponding .dynamic section is expected, but on
- IA-64/OpenVMS it is OK for it to be missing. */
- if (!is_ia64_vms (filedata))
- error (_("no .dynamic section in the dynamic segment\n"));
- break;
- }
-
- if (sec->sh_type == SHT_NOBITS)
- {
- dynamic_addr = 0;
- dynamic_size = 0;
- break;
- }
-
- dynamic_addr = sec->sh_offset;
- dynamic_size = sec->sh_size;
-
- /* The PT_DYNAMIC segment, which is used by the run-time
- loader, should exactly match the .dynamic section. */
- if (do_checks
- && (dynamic_addr != segment->p_offset
- || dynamic_size != segment->p_filesz))
- warn (_("\
-the .dynamic section is not the same as the dynamic segment\n"));
- }
-
- /* PR binutils/17512: Avoid corrupt dynamic section info in the
- segment. Check this after matching against the section headers
- so we don't warn on debuginfo file (which have NOBITS .dynamic
- sections). */
- if (dynamic_addr > filedata->file_size
- || (dynamic_size > filedata->file_size - dynamic_addr))
- {
- error (_("the dynamic segment offset + size exceeds the size of the file\n"));
- dynamic_addr = 0;
- dynamic_size = 0;
- }
- break;
-
- case PT_INTERP:
- if (segment->p_offset >= filedata->file_size
- || segment->p_filesz > filedata->file_size - segment->p_offset
- || segment->p_filesz - 1 >= (size_t) -2
- || fseek64 (filedata->handle,
- filedata->archive_file_offset + segment->p_offset,
- SEEK_SET))
- error (_("Unable to find program interpreter name\n"));
- else
- {
- size_t len = segment->p_filesz;
- free (filedata->program_interpreter);
- filedata->program_interpreter = xmalloc (len + 1);
- len = fread (filedata->program_interpreter, 1, len,
- filedata->handle);
- filedata->program_interpreter[len] = 0;
-
- if (do_segments)
- printf (_(" [Requesting program interpreter: %s]\n"),
- filedata->program_interpreter);
- }
- break;
- }
- }
-
- if (do_segments
- && filedata->section_headers != NULL
- && filedata->string_table != NULL)
- {
- printf (_("\n Section to Segment mapping:\n"));
- printf (_(" Segment Sections...\n"));
-
- for (i = 0; i < filedata->file_header.e_phnum; i++)
- {
- unsigned int j;
- Elf_Internal_Shdr * section;
-
- segment = filedata->program_headers + i;
- section = filedata->section_headers + 1;
-
- printf (" %2.2d ", i);
-
- for (j = 1; j < filedata->file_header.e_shnum; j++, section++)
- {
- if (!ELF_TBSS_SPECIAL (section, segment)
- && ELF_SECTION_IN_SEGMENT_STRICT (section, segment))
- printf ("%s ", printable_section_name (filedata, section));
- }
-
- putc ('\n',stdout);
- }
- }
-
- filedata->dynamic_addr = dynamic_addr;
- filedata->dynamic_size = dynamic_size ? dynamic_size : 1;
- return;
-
- no_headers:
- filedata->dynamic_addr = 0;
- filedata->dynamic_size = 1;
-}
-
-
-/* Find the file offset corresponding to VMA by using the program headers. */
-
-static int64_t
-offset_from_vma (Filedata * filedata, uint64_t vma, uint64_t size)
-{
- Elf_Internal_Phdr * seg;
-
- if (! get_program_headers (filedata))
- {
- warn (_("Cannot interpret virtual addresses without program headers.\n"));
- return (long) vma;
- }
-
- for (seg = filedata->program_headers;
- seg < filedata->program_headers + filedata->file_header.e_phnum;
- ++seg)
- {
- if (seg->p_type != PT_LOAD)
- continue;
-
- if (vma >= (seg->p_vaddr & -seg->p_align)
- && vma + size <= seg->p_vaddr + seg->p_filesz)
- return vma - seg->p_vaddr + seg->p_offset;
- }
-
- warn (_("Virtual address %#" PRIx64
- " not located in any PT_LOAD segment.\n"), vma);
- return vma;
-}
-
-
-/* Allocate memory and load the sections headers into FILEDATA->filedata->section_headers.
- If PROBE is true, this is just a probe and we do not generate any error
- messages if the load fails. */
-
-static bool
-get_32bit_section_headers (Filedata * filedata, bool probe)
-{
- Elf32_External_Shdr * shdrs;
- Elf_Internal_Shdr * internal;
- unsigned int i;
- unsigned int size = filedata->file_header.e_shentsize;
- unsigned int num = probe ? 1 : filedata->file_header.e_shnum;
-
- /* PR binutils/17531: Cope with unexpected section header sizes. */
- if (size == 0 || num == 0)
- return false;
-
- /* The section header cannot be at the start of the file - that is
- where the ELF file header is located. A file with absolutely no
- sections in it will use a shoff of 0. */
- if (filedata->file_header.e_shoff == 0)
- return false;
-
- if (size < sizeof * shdrs)
- {
- if (! probe)
- error (_("The e_shentsize field in the ELF header is less than the size of an ELF section header\n"));
- return false;
- }
- if (!probe && size > sizeof * shdrs)
- warn (_("The e_shentsize field in the ELF header is larger than the size of an ELF section header\n"));
-
- shdrs = (Elf32_External_Shdr *) get_data (NULL, filedata, filedata->file_header.e_shoff,
- size, num,
- probe ? NULL : _("section headers"));
- if (shdrs == NULL)
- return false;
-
- filedata->section_headers = (Elf_Internal_Shdr *)
- cmalloc (num, sizeof (Elf_Internal_Shdr));
- if (filedata->section_headers == NULL)
- {
- if (!probe)
- error (_("Out of memory reading %u section headers\n"), num);
- free (shdrs);
- return false;
- }
-
- for (i = 0, internal = filedata->section_headers;
- i < num;
- i++, internal++)
- {
- internal->sh_name = BYTE_GET (shdrs[i].sh_name);
- internal->sh_type = BYTE_GET (shdrs[i].sh_type);
- internal->sh_flags = BYTE_GET (shdrs[i].sh_flags);
- internal->sh_addr = BYTE_GET (shdrs[i].sh_addr);
- internal->sh_offset = BYTE_GET (shdrs[i].sh_offset);
- internal->sh_size = BYTE_GET (shdrs[i].sh_size);
- internal->sh_link = BYTE_GET (shdrs[i].sh_link);
- internal->sh_info = BYTE_GET (shdrs[i].sh_info);
- internal->sh_addralign = BYTE_GET (shdrs[i].sh_addralign);
- internal->sh_entsize = BYTE_GET (shdrs[i].sh_entsize);
- if (!probe && internal->sh_link > num)
- warn (_("Section %u has an out of range sh_link value of %u\n"), i, internal->sh_link);
- if (!probe && internal->sh_flags & SHF_INFO_LINK && internal->sh_info > num)
- warn (_("Section %u has an out of range sh_info value of %u\n"), i, internal->sh_info);
- }
-
- free (shdrs);
- return true;
-}
-
-/* Like get_32bit_section_headers, except that it fetches 64-bit headers. */
-
-static bool
-get_64bit_section_headers (Filedata * filedata, bool probe)
-{
- Elf64_External_Shdr * shdrs;
- Elf_Internal_Shdr * internal;
- unsigned int i;
- unsigned int size = filedata->file_header.e_shentsize;
- unsigned int num = probe ? 1 : filedata->file_header.e_shnum;
-
- /* PR binutils/17531: Cope with unexpected section header sizes. */
- if (size == 0 || num == 0)
- return false;
-
- /* The section header cannot be at the start of the file - that is
- where the ELF file header is located. A file with absolutely no
- sections in it will use a shoff of 0. */
- if (filedata->file_header.e_shoff == 0)
- return false;
-
- if (size < sizeof * shdrs)
- {
- if (! probe)
- error (_("The e_shentsize field in the ELF header is less than the size of an ELF section header\n"));
- return false;
- }
-
- if (! probe && size > sizeof * shdrs)
- warn (_("The e_shentsize field in the ELF header is larger than the size of an ELF section header\n"));
-
- shdrs = (Elf64_External_Shdr *) get_data (NULL, filedata,
- filedata->file_header.e_shoff,
- size, num,
- probe ? NULL : _("section headers"));
- if (shdrs == NULL)
- return false;
-
- filedata->section_headers = (Elf_Internal_Shdr *)
- cmalloc (num, sizeof (Elf_Internal_Shdr));
- if (filedata->section_headers == NULL)
- {
- if (! probe)
- error (_("Out of memory reading %u section headers\n"), num);
- free (shdrs);
- return false;
- }
-
- for (i = 0, internal = filedata->section_headers;
- i < num;
- i++, internal++)
- {
- internal->sh_name = BYTE_GET (shdrs[i].sh_name);
- internal->sh_type = BYTE_GET (shdrs[i].sh_type);
- internal->sh_flags = BYTE_GET (shdrs[i].sh_flags);
- internal->sh_addr = BYTE_GET (shdrs[i].sh_addr);
- internal->sh_size = BYTE_GET (shdrs[i].sh_size);
- internal->sh_entsize = BYTE_GET (shdrs[i].sh_entsize);
- internal->sh_link = BYTE_GET (shdrs[i].sh_link);
- internal->sh_info = BYTE_GET (shdrs[i].sh_info);
- internal->sh_offset = BYTE_GET (shdrs[i].sh_offset);
- internal->sh_addralign = BYTE_GET (shdrs[i].sh_addralign);
- if (!probe && internal->sh_link > num)
- warn (_("Section %u has an out of range sh_link value of %u\n"), i, internal->sh_link);
- if (!probe && internal->sh_flags & SHF_INFO_LINK && internal->sh_info > num)
- warn (_("Section %u has an out of range sh_info value of %u\n"), i, internal->sh_info);
- }
-
- free (shdrs);
- return true;
-}
-
-static bool
-get_section_headers (Filedata *filedata, bool probe)
-{
- if (filedata->section_headers != NULL)
- return true;
-
- if (is_32bit_elf)
- return get_32bit_section_headers (filedata, probe);
- else
- return get_64bit_section_headers (filedata, probe);
-}
-
-static Elf_Internal_Sym *
-get_32bit_elf_symbols (Filedata *filedata,
- Elf_Internal_Shdr *section,
- uint64_t *num_syms_return)
-{
- uint64_t number = 0;
- Elf32_External_Sym * esyms = NULL;
- Elf_External_Sym_Shndx * shndx = NULL;
- Elf_Internal_Sym * isyms = NULL;
- Elf_Internal_Sym * psym;
- unsigned int j;
- elf_section_list * entry;
-
- if (section->sh_size == 0)
- {
- if (num_syms_return != NULL)
- * num_syms_return = 0;
- return NULL;
- }
-
- /* Run some sanity checks first. */
- if (section->sh_entsize == 0 || section->sh_entsize > section->sh_size)
- {
- error (_("Section %s has an invalid sh_entsize of %#" PRIx64 "\n"),
- printable_section_name (filedata, section),
- section->sh_entsize);
- goto exit_point;
- }
-
- if (section->sh_size > filedata->file_size)
- {
- error (_("Section %s has an invalid sh_size of %#" PRIx64 "\n"),
- printable_section_name (filedata, section),
- section->sh_size);
- goto exit_point;
- }
-
- number = section->sh_size / section->sh_entsize;
-
- if (number * sizeof (Elf32_External_Sym) > section->sh_size + 1)
- {
- error (_("Size (%#" PRIx64 ") of section %s "
- "is not a multiple of its sh_entsize (%#" PRIx64 ")\n"),
- section->sh_size,
- printable_section_name (filedata, section),
- section->sh_entsize);
- goto exit_point;
- }
-
- esyms = (Elf32_External_Sym *) get_data (NULL, filedata, section->sh_offset, 1,
- section->sh_size, _("symbols"));
- if (esyms == NULL)
- goto exit_point;
-
- shndx = NULL;
- for (entry = filedata->symtab_shndx_list; entry != NULL; entry = entry->next)
- {
- if (entry->hdr->sh_link != (size_t) (section - filedata->section_headers))
- continue;
-
- if (shndx != NULL)
- {
- error (_("Multiple symbol table index sections associated with the same symbol section\n"));
- free (shndx);
- }
-
- shndx = (Elf_External_Sym_Shndx *) get_data (NULL, filedata,
- entry->hdr->sh_offset,
- 1, entry->hdr->sh_size,
- _("symbol table section indices"));
- if (shndx == NULL)
- goto exit_point;
-
- /* PR17531: file: heap-buffer-overflow */
- if (entry->hdr->sh_size / sizeof (Elf_External_Sym_Shndx) < number)
- {
- error (_("Index section %s has an sh_size of %#" PRIx64 " - expected %#" PRIx64 "\n"),
- printable_section_name (filedata, entry->hdr),
- entry->hdr->sh_size,
- section->sh_size);
- goto exit_point;
- }
- }
-
- isyms = (Elf_Internal_Sym *) cmalloc (number, sizeof (Elf_Internal_Sym));
-
- if (isyms == NULL)
- {
- error (_("Out of memory reading %" PRIu64 " symbols\n"), number);
- goto exit_point;
- }
-
- for (j = 0, psym = isyms; j < number; j++, psym++)
- {
- psym->st_name = BYTE_GET (esyms[j].st_name);
- psym->st_value = BYTE_GET (esyms[j].st_value);
- psym->st_size = BYTE_GET (esyms[j].st_size);
- psym->st_shndx = BYTE_GET (esyms[j].st_shndx);
- if (psym->st_shndx == (SHN_XINDEX & 0xffff) && shndx != NULL)
- psym->st_shndx
- = byte_get ((unsigned char *) &shndx[j], sizeof (shndx[j]));
- else if (psym->st_shndx >= (SHN_LORESERVE & 0xffff))
- psym->st_shndx += SHN_LORESERVE - (SHN_LORESERVE & 0xffff);
- psym->st_info = BYTE_GET (esyms[j].st_info);
- psym->st_other = BYTE_GET (esyms[j].st_other);
- }
-
- exit_point:
- free (shndx);
- free (esyms);
-
- if (num_syms_return != NULL)
- * num_syms_return = isyms == NULL ? 0 : number;
-
- return isyms;
-}
-
-static Elf_Internal_Sym *
-get_64bit_elf_symbols (Filedata *filedata,
- Elf_Internal_Shdr *section,
- uint64_t *num_syms_return)
-{
- uint64_t number = 0;
- Elf64_External_Sym * esyms = NULL;
- Elf_External_Sym_Shndx * shndx = NULL;
- Elf_Internal_Sym * isyms = NULL;
- Elf_Internal_Sym * psym;
- unsigned int j;
- elf_section_list * entry;
-
- if (section->sh_size == 0)
- {
- if (num_syms_return != NULL)
- * num_syms_return = 0;
- return NULL;
- }
-
- /* Run some sanity checks first. */
- if (section->sh_entsize == 0 || section->sh_entsize > section->sh_size)
- {
- error (_("Section %s has an invalid sh_entsize of %#" PRIx64 "\n"),
- printable_section_name (filedata, section),
- section->sh_entsize);
- goto exit_point;
- }
-
- if (section->sh_size > filedata->file_size)
- {
- error (_("Section %s has an invalid sh_size of %#" PRIx64 "\n"),
- printable_section_name (filedata, section),
- section->sh_size);
- goto exit_point;
- }
-
- number = section->sh_size / section->sh_entsize;
-
- if (number * sizeof (Elf64_External_Sym) > section->sh_size + 1)
- {
- error (_("Size (%#" PRIx64 ") of section %s "
- "is not a multiple of its sh_entsize (%#" PRIx64 ")\n"),
- section->sh_size,
- printable_section_name (filedata, section),
- section->sh_entsize);
- goto exit_point;
- }
-
- esyms = (Elf64_External_Sym *) get_data (NULL, filedata, section->sh_offset, 1,
- section->sh_size, _("symbols"));
- if (!esyms)
- goto exit_point;
-
- shndx = NULL;
- for (entry = filedata->symtab_shndx_list; entry != NULL; entry = entry->next)
- {
- if (entry->hdr->sh_link != (size_t) (section - filedata->section_headers))
- continue;
-
- if (shndx != NULL)
- {
- error (_("Multiple symbol table index sections associated with the same symbol section\n"));
- free (shndx);
- }
-
- shndx = (Elf_External_Sym_Shndx *) get_data (NULL, filedata,
- entry->hdr->sh_offset,
- 1, entry->hdr->sh_size,
- _("symbol table section indices"));
- if (shndx == NULL)
- goto exit_point;
-
- /* PR17531: file: heap-buffer-overflow */
- if (entry->hdr->sh_size / sizeof (Elf_External_Sym_Shndx) < number)
- {
- error (_("Index section %s has an sh_size of %#" PRIx64 " - expected %#" PRIx64 "\n"),
- printable_section_name (filedata, entry->hdr),
- entry->hdr->sh_size,
- section->sh_size);
- goto exit_point;
- }
- }
-
- isyms = (Elf_Internal_Sym *) cmalloc (number, sizeof (Elf_Internal_Sym));
-
- if (isyms == NULL)
- {
- error (_("Out of memory reading %" PRIu64 " symbols\n"), number);
- goto exit_point;
- }
-
- for (j = 0, psym = isyms; j < number; j++, psym++)
- {
- psym->st_name = BYTE_GET (esyms[j].st_name);
- psym->st_info = BYTE_GET (esyms[j].st_info);
- psym->st_other = BYTE_GET (esyms[j].st_other);
- psym->st_shndx = BYTE_GET (esyms[j].st_shndx);
-
- if (psym->st_shndx == (SHN_XINDEX & 0xffff) && shndx != NULL)
- psym->st_shndx
- = byte_get ((unsigned char *) &shndx[j], sizeof (shndx[j]));
- else if (psym->st_shndx >= (SHN_LORESERVE & 0xffff))
- psym->st_shndx += SHN_LORESERVE - (SHN_LORESERVE & 0xffff);
-
- psym->st_value = BYTE_GET (esyms[j].st_value);
- psym->st_size = BYTE_GET (esyms[j].st_size);
- }
-
- exit_point:
- free (shndx);
- free (esyms);
-
- if (num_syms_return != NULL)
- * num_syms_return = isyms == NULL ? 0 : number;
-
- return isyms;
-}
-
-static Elf_Internal_Sym *
-get_elf_symbols (Filedata *filedata,
- Elf_Internal_Shdr *section,
- uint64_t *num_syms_return)
-{
- if (is_32bit_elf)
- return get_32bit_elf_symbols (filedata, section, num_syms_return);
- else
- return get_64bit_elf_symbols (filedata, section, num_syms_return);
-}
-
-static const char *
-get_elf_section_flags (Filedata * filedata, uint64_t sh_flags)
-{
- static char buff[1024];
- char * p = buff;
- unsigned int field_size = is_32bit_elf ? 8 : 16;
- signed int sindex;
- unsigned int size = sizeof (buff) - (field_size + 4 + 1);
- uint64_t os_flags = 0;
- uint64_t proc_flags = 0;
- uint64_t unknown_flags = 0;
- static const struct
- {
- const char * str;
- unsigned int len;
- }
- flags [] =
- {
- /* 0 */ { STRING_COMMA_LEN ("WRITE") },
- /* 1 */ { STRING_COMMA_LEN ("ALLOC") },
- /* 2 */ { STRING_COMMA_LEN ("EXEC") },
- /* 3 */ { STRING_COMMA_LEN ("MERGE") },
- /* 4 */ { STRING_COMMA_LEN ("STRINGS") },
- /* 5 */ { STRING_COMMA_LEN ("INFO LINK") },
- /* 6 */ { STRING_COMMA_LEN ("LINK ORDER") },
- /* 7 */ { STRING_COMMA_LEN ("OS NONCONF") },
- /* 8 */ { STRING_COMMA_LEN ("GROUP") },
- /* 9 */ { STRING_COMMA_LEN ("TLS") },
- /* IA-64 specific. */
- /* 10 */ { STRING_COMMA_LEN ("SHORT") },
- /* 11 */ { STRING_COMMA_LEN ("NORECOV") },
- /* IA-64 OpenVMS specific. */
- /* 12 */ { STRING_COMMA_LEN ("VMS_GLOBAL") },
- /* 13 */ { STRING_COMMA_LEN ("VMS_OVERLAID") },
- /* 14 */ { STRING_COMMA_LEN ("VMS_SHARED") },
- /* 15 */ { STRING_COMMA_LEN ("VMS_VECTOR") },
- /* 16 */ { STRING_COMMA_LEN ("VMS_ALLOC_64BIT") },
- /* 17 */ { STRING_COMMA_LEN ("VMS_PROTECTED") },
- /* Generic. */
- /* 18 */ { STRING_COMMA_LEN ("EXCLUDE") },
- /* SPARC specific. */
- /* 19 */ { STRING_COMMA_LEN ("ORDERED") },
- /* 20 */ { STRING_COMMA_LEN ("COMPRESSED") },
- /* ARM specific. */
- /* 21 */ { STRING_COMMA_LEN ("ENTRYSECT") },
- /* 22 */ { STRING_COMMA_LEN ("ARM_PURECODE") },
- /* 23 */ { STRING_COMMA_LEN ("COMDEF") },
- /* GNU specific. */
- /* 24 */ { STRING_COMMA_LEN ("GNU_MBIND") },
- /* VLE specific. */
- /* 25 */ { STRING_COMMA_LEN ("VLE") },
- /* GNU specific. */
- /* 26 */ { STRING_COMMA_LEN ("GNU_RETAIN") },
- };
-
- if (do_section_details)
- p += sprintf (p, "[%*.*lx]: ",
- field_size, field_size, (unsigned long) sh_flags);
-
- while (sh_flags)
- {
- uint64_t flag;
-
- flag = sh_flags & - sh_flags;
- sh_flags &= ~ flag;
-
- if (do_section_details)
- {
- switch (flag)
- {
- case SHF_WRITE: sindex = 0; break;
- case SHF_ALLOC: sindex = 1; break;
- case SHF_EXECINSTR: sindex = 2; break;
- case SHF_MERGE: sindex = 3; break;
- case SHF_STRINGS: sindex = 4; break;
- case SHF_INFO_LINK: sindex = 5; break;
- case SHF_LINK_ORDER: sindex = 6; break;
- case SHF_OS_NONCONFORMING: sindex = 7; break;
- case SHF_GROUP: sindex = 8; break;
- case SHF_TLS: sindex = 9; break;
- case SHF_EXCLUDE: sindex = 18; break;
- case SHF_COMPRESSED: sindex = 20; break;
-
- default:
- sindex = -1;
- switch (filedata->file_header.e_machine)
- {
- case EM_IA_64:
- if (flag == SHF_IA_64_SHORT)
- sindex = 10;
- else if (flag == SHF_IA_64_NORECOV)
- sindex = 11;
- else if (filedata->file_header.e_ident[EI_OSABI] == ELFOSABI_OPENVMS)
- switch (flag)
- {
- case SHF_IA_64_VMS_GLOBAL: sindex = 12; break;
- case SHF_IA_64_VMS_OVERLAID: sindex = 13; break;
- case SHF_IA_64_VMS_SHARED: sindex = 14; break;
- case SHF_IA_64_VMS_VECTOR: sindex = 15; break;
- case SHF_IA_64_VMS_ALLOC_64BIT: sindex = 16; break;
- case SHF_IA_64_VMS_PROTECTED: sindex = 17; break;
- default: break;
- }
- break;
-
- case EM_386:
- case EM_IAMCU:
- case EM_X86_64:
- case EM_L1OM:
- case EM_K1OM:
- case EM_OLD_SPARCV9:
- case EM_SPARC32PLUS:
- case EM_SPARCV9:
- case EM_SPARC:
- if (flag == SHF_ORDERED)
- sindex = 19;
- break;
-
- case EM_ARM:
- switch (flag)
- {
- case SHF_ENTRYSECT: sindex = 21; break;
- case SHF_ARM_PURECODE: sindex = 22; break;
- case SHF_COMDEF: sindex = 23; break;
- default: break;
- }
- break;
- case EM_PPC:
- if (flag == SHF_PPC_VLE)
- sindex = 25;
- break;
- default:
- break;
- }
-
- switch (filedata->file_header.e_ident[EI_OSABI])
- {
- case ELFOSABI_GNU:
- case ELFOSABI_FREEBSD:
- if (flag == SHF_GNU_RETAIN)
- sindex = 26;
- /* Fall through */
- case ELFOSABI_NONE:
- if (flag == SHF_GNU_MBIND)
- /* We should not recognize SHF_GNU_MBIND for
- ELFOSABI_NONE, but binutils as of 2019-07-23 did
- not set the EI_OSABI header byte. */
- sindex = 24;
- break;
- default:
- break;
- }
- break;
- }
-
- if (sindex != -1)
- {
- if (p != buff + field_size + 4)
- {
- if (size < (10 + 2))
- {
- warn (_("Internal error: not enough buffer room for section flag info"));
- return _("<unknown>");
- }
- size -= 2;
- *p++ = ',';
- *p++ = ' ';
- }
-
- size -= flags [sindex].len;
- p = stpcpy (p, flags [sindex].str);
- }
- else if (flag & SHF_MASKOS)
- os_flags |= flag;
- else if (flag & SHF_MASKPROC)
- proc_flags |= flag;
- else
- unknown_flags |= flag;
- }
- else
- {
- switch (flag)
- {
- case SHF_WRITE: *p = 'W'; break;
- case SHF_ALLOC: *p = 'A'; break;
- case SHF_EXECINSTR: *p = 'X'; break;
- case SHF_MERGE: *p = 'M'; break;
- case SHF_STRINGS: *p = 'S'; break;
- case SHF_INFO_LINK: *p = 'I'; break;
- case SHF_LINK_ORDER: *p = 'L'; break;
- case SHF_OS_NONCONFORMING: *p = 'O'; break;
- case SHF_GROUP: *p = 'G'; break;
- case SHF_TLS: *p = 'T'; break;
- case SHF_EXCLUDE: *p = 'E'; break;
- case SHF_COMPRESSED: *p = 'C'; break;
-
- default:
- if ((filedata->file_header.e_machine == EM_X86_64
- || filedata->file_header.e_machine == EM_L1OM
- || filedata->file_header.e_machine == EM_K1OM)
- && flag == SHF_X86_64_LARGE)
- *p = 'l';
- else if (filedata->file_header.e_machine == EM_ARM
- && flag == SHF_ARM_PURECODE)
- *p = 'y';
- else if (filedata->file_header.e_machine == EM_PPC
- && flag == SHF_PPC_VLE)
- *p = 'v';
- else if (flag & SHF_MASKOS)
- {
- switch (filedata->file_header.e_ident[EI_OSABI])
- {
- case ELFOSABI_GNU:
- case ELFOSABI_FREEBSD:
- if (flag == SHF_GNU_RETAIN)
- {
- *p = 'R';
- break;
- }
- /* Fall through */
- case ELFOSABI_NONE:
- if (flag == SHF_GNU_MBIND)
- {
- /* We should not recognize SHF_GNU_MBIND for
- ELFOSABI_NONE, but binutils as of 2019-07-23 did
- not set the EI_OSABI header byte. */
- *p = 'D';
- break;
- }
- /* Fall through */
- default:
- *p = 'o';
- sh_flags &= ~SHF_MASKOS;
- break;
- }
- }
- else if (flag & SHF_MASKPROC)
- {
- *p = 'p';
- sh_flags &= ~ SHF_MASKPROC;
- }
- else
- *p = 'x';
- break;
- }
- p++;
- }
- }
-
- if (do_section_details)
- {
- if (os_flags)
- {
- if (p != buff + field_size + 4)
- {
- if (size < 2 + 5 + field_size + 1)
- {
- warn (_("Internal error: not enough buffer room for section flag info"));
- return _("<unknown>");
- }
- size -= 2;
- *p++ = ',';
- *p++ = ' ';
- }
- size -= 5 + field_size;
- p += sprintf (p, "OS (%*.*lx)", field_size, field_size,
- (unsigned long) os_flags);
- }
- if (proc_flags)
- {
- if (p != buff + field_size + 4)
- {
- if (size < 2 + 7 + field_size + 1)
- {
- warn (_("Internal error: not enough buffer room for section flag info"));
- return _("<unknown>");
- }
- size -= 2;
- *p++ = ',';
- *p++ = ' ';
- }
- size -= 7 + field_size;
- p += sprintf (p, "PROC (%*.*lx)", field_size, field_size,
- (unsigned long) proc_flags);
- }
- if (unknown_flags)
- {
- if (p != buff + field_size + 4)
- {
- if (size < 2 + 10 + field_size + 1)
- {
- warn (_("Internal error: not enough buffer room for section flag info"));
- return _("<unknown>");
- }
- size -= 2;
- *p++ = ',';
- *p++ = ' ';
- }
- size -= 10 + field_size;
- p += sprintf (p, _("UNKNOWN (%*.*lx)"), field_size, field_size,
- (unsigned long) unknown_flags);
- }
- }
-
- *p = '\0';
- return buff;
-}
-
-static unsigned int ATTRIBUTE_WARN_UNUSED_RESULT
-get_compression_header (Elf_Internal_Chdr *chdr, unsigned char *buf,
- uint64_t size)
-{
- if (is_32bit_elf)
- {
- Elf32_External_Chdr *echdr = (Elf32_External_Chdr *) buf;
-
- if (size < sizeof (* echdr))
- {
- error (_("Compressed section is too small even for a compression header\n"));
- return 0;
- }
-
- chdr->ch_type = BYTE_GET (echdr->ch_type);
- chdr->ch_size = BYTE_GET (echdr->ch_size);
- chdr->ch_addralign = BYTE_GET (echdr->ch_addralign);
- return sizeof (*echdr);
- }
- else
- {
- Elf64_External_Chdr *echdr = (Elf64_External_Chdr *) buf;
-
- if (size < sizeof (* echdr))
- {
- error (_("Compressed section is too small even for a compression header\n"));
- return 0;
- }
-
- chdr->ch_type = BYTE_GET (echdr->ch_type);
- chdr->ch_size = BYTE_GET (echdr->ch_size);
- chdr->ch_addralign = BYTE_GET (echdr->ch_addralign);
- return sizeof (*echdr);
- }
-}
-
-static bool
-process_section_headers (Filedata * filedata)
-{
- Elf_Internal_Shdr * section;
- unsigned int i;
-
- if (filedata->file_header.e_shnum == 0)
- {
- /* PR binutils/12467. */
- if (filedata->file_header.e_shoff != 0)
- {
- warn (_("possibly corrupt ELF file header - it has a non-zero"
- " section header offset, but no section headers\n"));
- return false;
- }
- else if (do_sections)
- printf (_("\nThere are no sections in this file.\n"));
-
- return true;
- }
-
- if (do_sections && !do_header)
- {
- if (filedata->is_separate && process_links)
- printf (_("In linked file '%s': "), filedata->file_name);
- if (! filedata->is_separate || process_links)
- printf (ngettext ("There is %d section header, "
- "starting at offset %#" PRIx64 ":\n",
- "There are %d section headers, "
- "starting at offset %#" PRIx64 ":\n",
- filedata->file_header.e_shnum),
- filedata->file_header.e_shnum,
- filedata->file_header.e_shoff);
- }
-
- if (!get_section_headers (filedata, false))
- return false;
-
- /* Read in the string table, so that we have names to display. */
- if (filedata->file_header.e_shstrndx != SHN_UNDEF
- && filedata->file_header.e_shstrndx < filedata->file_header.e_shnum)
- {
- section = filedata->section_headers + filedata->file_header.e_shstrndx;
-
- if (section->sh_size != 0)
- {
- filedata->string_table = (char *) get_data (NULL, filedata, section->sh_offset,
- 1, section->sh_size,
- _("string table"));
-
- filedata->string_table_length = filedata->string_table != NULL ? section->sh_size : 0;
- }
- }
-
- /* Scan the sections for the dynamic symbol table
- and dynamic string table and debug sections. */
- eh_addr_size = is_32bit_elf ? 4 : 8;
- switch (filedata->file_header.e_machine)
- {
- case EM_MIPS:
- case EM_MIPS_RS3_LE:
- /* The 64-bit MIPS EABI uses a combination of 32-bit ELF and 64-bit
- FDE addresses. However, the ABI also has a semi-official ILP32
- variant for which the normal FDE address size rules apply.
-
- GCC 4.0 marks EABI64 objects with a dummy .gcc_compiled_longXX
- section, where XX is the size of longs in bits. Unfortunately,
- earlier compilers provided no way of distinguishing ILP32 objects
- from LP64 objects, so if there's any doubt, we should assume that
- the official LP64 form is being used. */
- if ((filedata->file_header.e_flags & EF_MIPS_ABI) == EF_MIPS_ABI_EABI64
- && find_section (filedata, ".gcc_compiled_long32") == NULL)
- eh_addr_size = 8;
- break;
-
- case EM_H8_300:
- case EM_H8_300H:
- switch (filedata->file_header.e_flags & EF_H8_MACH)
- {
- case E_H8_MACH_H8300:
- case E_H8_MACH_H8300HN:
- case E_H8_MACH_H8300SN:
- case E_H8_MACH_H8300SXN:
- eh_addr_size = 2;
- break;
- case E_H8_MACH_H8300H:
- case E_H8_MACH_H8300S:
- case E_H8_MACH_H8300SX:
- eh_addr_size = 4;
- break;
- }
- break;
-
- case EM_M32C_OLD:
- case EM_M32C:
- switch (filedata->file_header.e_flags & EF_M32C_CPU_MASK)
- {
- case EF_M32C_CPU_M16C:
- eh_addr_size = 2;
- break;
- }
- break;
- }
-
-#define CHECK_ENTSIZE_VALUES(section, i, size32, size64) \
- do \
- { \
- uint64_t expected_entsize = is_32bit_elf ? size32 : size64; \
- if (section->sh_entsize != expected_entsize) \
- { \
- error (_("Section %d has invalid sh_entsize of %" PRIx64 "\n"), \
- i, section->sh_entsize); \
- error (_("(Using the expected size of %" PRIx64 " for the rest of this dump)\n"), \
- expected_entsize); \
- section->sh_entsize = expected_entsize; \
- } \
- } \
- while (0)
-
-#define CHECK_ENTSIZE(section, i, type) \
- CHECK_ENTSIZE_VALUES (section, i, sizeof (Elf32_External_##type), \
- sizeof (Elf64_External_##type))
-
- for (i = 0, section = filedata->section_headers;
- i < filedata->file_header.e_shnum;
- i++, section++)
- {
- const char *name = printable_section_name (filedata, section);
-
- /* Run some sanity checks on the headers and
- possibly fill in some file data as well. */
- switch (section->sh_type)
- {
- case SHT_DYNSYM:
- if (filedata->dynamic_symbols != NULL)
- {
- error (_("File contains multiple dynamic symbol tables\n"));
- continue;
- }
-
- CHECK_ENTSIZE (section, i, Sym);
- filedata->dynamic_symbols
- = get_elf_symbols (filedata, section, &filedata->num_dynamic_syms);
- filedata->dynamic_symtab_section = section;
- break;
-
- case SHT_STRTAB:
- if (streq (name, ".dynstr"))
- {
- if (filedata->dynamic_strings != NULL)
- {
- error (_("File contains multiple dynamic string tables\n"));
- continue;
- }
-
- filedata->dynamic_strings
- = (char *) get_data (NULL, filedata, section->sh_offset,
- 1, section->sh_size, _("dynamic strings"));
- filedata->dynamic_strings_length
- = filedata->dynamic_strings == NULL ? 0 : section->sh_size;
- filedata->dynamic_strtab_section = section;
- }
- break;
-
- case SHT_SYMTAB_SHNDX:
- {
- elf_section_list * entry = xmalloc (sizeof * entry);
-
- entry->hdr = section;
- entry->next = filedata->symtab_shndx_list;
- filedata->symtab_shndx_list = entry;
- }
- break;
-
- case SHT_SYMTAB:
- CHECK_ENTSIZE (section, i, Sym);
- break;
-
- case SHT_GROUP:
- CHECK_ENTSIZE_VALUES (section, i, GRP_ENTRY_SIZE, GRP_ENTRY_SIZE);
- break;
-
- case SHT_REL:
- CHECK_ENTSIZE (section, i, Rel);
- if (do_checks && section->sh_size == 0)
- warn (_("Section '%s': zero-sized relocation section\n"), name);
- break;
-
- case SHT_RELA:
- CHECK_ENTSIZE (section, i, Rela);
- if (do_checks && section->sh_size == 0)
- warn (_("Section '%s': zero-sized relocation section\n"), name);
- break;
-
- case SHT_RELR:
- CHECK_ENTSIZE (section, i, Relr);
- break;
-
- case SHT_NOTE:
- case SHT_PROGBITS:
- /* Having a zero sized section is not illegal according to the
- ELF standard, but it might be an indication that something
- is wrong. So issue a warning if we are running in lint mode. */
- if (do_checks && section->sh_size == 0)
- warn (_("Section '%s': has a size of zero - is this intended ?\n"), name);
- break;
-
- default:
- break;
- }
-
- if ((do_debugging || do_debug_info || do_debug_abbrevs
- || do_debug_lines || do_debug_pubnames || do_debug_pubtypes
- || do_debug_aranges || do_debug_frames || do_debug_macinfo
- || do_debug_str || do_debug_str_offsets || do_debug_loc
- || do_debug_ranges
- || do_debug_addr || do_debug_cu_index || do_debug_links)
- && (startswith (name, ".debug_")
- || startswith (name, ".zdebug_")))
- {
- if (name[1] == 'z')
- name += sizeof (".zdebug_") - 1;
- else
- name += sizeof (".debug_") - 1;
-
- if (do_debugging
- || (do_debug_info && startswith (name, "info"))
- || (do_debug_info && startswith (name, "types"))
- || (do_debug_abbrevs && startswith (name, "abbrev"))
- || (do_debug_lines && strcmp (name, "line") == 0)
- || (do_debug_lines && startswith (name, "line."))
- || (do_debug_pubnames && startswith (name, "pubnames"))
- || (do_debug_pubtypes && startswith (name, "pubtypes"))
- || (do_debug_pubnames && startswith (name, "gnu_pubnames"))
- || (do_debug_pubtypes && startswith (name, "gnu_pubtypes"))
- || (do_debug_aranges && startswith (name, "aranges"))
- || (do_debug_ranges && startswith (name, "ranges"))
- || (do_debug_ranges && startswith (name, "rnglists"))
- || (do_debug_frames && startswith (name, "frame"))
- || (do_debug_macinfo && startswith (name, "macinfo"))
- || (do_debug_macinfo && startswith (name, "macro"))
- || (do_debug_str && startswith (name, "str"))
- || (do_debug_links && startswith (name, "sup"))
- || (do_debug_str_offsets && startswith (name, "str_offsets"))
- || (do_debug_loc && startswith (name, "loc"))
- || (do_debug_loc && startswith (name, "loclists"))
- || (do_debug_addr && startswith (name, "addr"))
- || (do_debug_cu_index && startswith (name, "cu_index"))
- || (do_debug_cu_index && startswith (name, "tu_index"))
- )
- request_dump_bynumber (&filedata->dump, i, DEBUG_DUMP);
- }
- /* Linkonce section to be combined with .debug_info at link time. */
- else if ((do_debugging || do_debug_info)
- && startswith (name, ".gnu.linkonce.wi."))
- request_dump_bynumber (&filedata->dump, i, DEBUG_DUMP);
- else if (do_debug_frames && streq (name, ".eh_frame"))
- request_dump_bynumber (&filedata->dump, i, DEBUG_DUMP);
- else if (do_debug_frames && streq (name, ".eh_frame_hdr"))
- request_dump_bynumber (&filedata->dump, i, DEBUG_DUMP);
- else if (do_gdb_index && (streq (name, ".gdb_index")
- || streq (name, ".debug_names")))
- request_dump_bynumber (&filedata->dump, i, DEBUG_DUMP);
- /* Trace sections for Itanium VMS. */
- else if ((do_debugging || do_trace_info || do_trace_abbrevs
- || do_trace_aranges)
- && startswith (name, ".trace_"))
- {
- name += sizeof (".trace_") - 1;
-
- if (do_debugging
- || (do_trace_info && streq (name, "info"))
- || (do_trace_abbrevs && streq (name, "abbrev"))
- || (do_trace_aranges && streq (name, "aranges"))
- )
- request_dump_bynumber (&filedata->dump, i, DEBUG_DUMP);
- }
- else if ((do_debugging || do_debug_links)
- && (startswith (name, ".gnu_debuglink")
- || startswith (name, ".gnu_debugaltlink")))
- request_dump_bynumber (&filedata->dump, i, DEBUG_DUMP);
- }
-
- if (! do_sections)
- return true;
-
- if (filedata->is_separate && ! process_links)
- return true;
-
- if (filedata->is_separate)
- printf (_("\nSection Headers in linked file '%s':\n"), filedata->file_name);
- else if (filedata->file_header.e_shnum > 1)
- printf (_("\nSection Headers:\n"));
- else
- printf (_("\nSection Header:\n"));
-
- if (is_32bit_elf)
- {
- if (do_section_details)
- {
- printf (_(" [Nr] Name\n"));
- printf (_(" Type Addr Off Size ES Lk Inf Al\n"));
- }
- else
- printf
- (_(" [Nr] Name Type Addr Off Size ES Flg Lk Inf Al\n"));
- }
- else if (do_wide)
- {
- if (do_section_details)
- {
- printf (_(" [Nr] Name\n"));
- printf (_(" Type Address Off Size ES Lk Inf Al\n"));
- }
- else
- printf
- (_(" [Nr] Name Type Address Off Size ES Flg Lk Inf Al\n"));
- }
- else
- {
- if (do_section_details)
- {
- printf (_(" [Nr] Name\n"));
- printf (_(" Type Address Offset Link\n"));
- printf (_(" Size EntSize Info Align\n"));
- }
- else
- {
- printf (_(" [Nr] Name Type Address Offset\n"));
- printf (_(" Size EntSize Flags Link Info Align\n"));
- }
- }
-
- if (do_section_details)
- printf (_(" Flags\n"));
-
- for (i = 0, section = filedata->section_headers;
- i < filedata->file_header.e_shnum;
- i++, section++)
- {
- /* Run some sanity checks on the section header. */
-
- /* Check the sh_link field. */
- switch (section->sh_type)
- {
- case SHT_REL:
- case SHT_RELR:
- case SHT_RELA:
- if (section->sh_link == 0
- && (filedata->file_header.e_type == ET_EXEC
- || filedata->file_header.e_type == ET_DYN))
- /* A dynamic relocation section where all entries use a
- zero symbol index need not specify a symtab section. */
- break;
- /* Fall through. */
- case SHT_SYMTAB_SHNDX:
- case SHT_GROUP:
- case SHT_HASH:
- case SHT_GNU_HASH:
- case SHT_GNU_versym:
- if (section->sh_link == 0
- || section->sh_link >= filedata->file_header.e_shnum
- || (filedata->section_headers[section->sh_link].sh_type != SHT_SYMTAB
- && filedata->section_headers[section->sh_link].sh_type != SHT_DYNSYM))
- warn (_("[%2u]: Link field (%u) should index a symtab section.\n"),
- i, section->sh_link);
- break;
-
- case SHT_DYNAMIC:
- case SHT_SYMTAB:
- case SHT_DYNSYM:
- case SHT_GNU_verneed:
- case SHT_GNU_verdef:
- case SHT_GNU_LIBLIST:
- if (section->sh_link == 0
- || section->sh_link >= filedata->file_header.e_shnum
- || filedata->section_headers[section->sh_link].sh_type != SHT_STRTAB)
- warn (_("[%2u]: Link field (%u) should index a string section.\n"),
- i, section->sh_link);
- break;
-
- case SHT_INIT_ARRAY:
- case SHT_FINI_ARRAY:
- case SHT_PREINIT_ARRAY:
- if (section->sh_type < SHT_LOOS && section->sh_link != 0)
- warn (_("[%2u]: Unexpected value (%u) in link field.\n"),
- i, section->sh_link);
- break;
-
- default:
- /* FIXME: Add support for target specific section types. */
-#if 0 /* Currently we do not check other section types as there are too
- many special cases. Stab sections for example have a type
- of SHT_PROGBITS but an sh_link field that links to the .stabstr
- section. */
- if (section->sh_type < SHT_LOOS && section->sh_link != 0)
- warn (_("[%2u]: Unexpected value (%u) in link field.\n"),
- i, section->sh_link);
-#endif
- break;
- }
-
- /* Check the sh_info field. */
- switch (section->sh_type)
- {
- case SHT_REL:
- case SHT_RELA:
- if (section->sh_info == 0
- && (filedata->file_header.e_type == ET_EXEC
- || filedata->file_header.e_type == ET_DYN))
- /* Dynamic relocations apply to segments, so they do not
- need to specify the section they relocate. */
- break;
- if (section->sh_info == 0
- || section->sh_info >= filedata->file_header.e_shnum
- || (filedata->section_headers[section->sh_info].sh_type != SHT_PROGBITS
- && filedata->section_headers[section->sh_info].sh_type != SHT_NOBITS
- && filedata->section_headers[section->sh_info].sh_type != SHT_NOTE
- && filedata->section_headers[section->sh_info].sh_type != SHT_INIT_ARRAY
- && filedata->section_headers[section->sh_info].sh_type != SHT_FINI_ARRAY
- && filedata->section_headers[section->sh_info].sh_type != SHT_PREINIT_ARRAY
- /* FIXME: Are other section types valid ? */
- && filedata->section_headers[section->sh_info].sh_type < SHT_LOOS))
- warn (_("[%2u]: Info field (%u) should index a relocatable section.\n"),
- i, section->sh_info);
- break;
-
- case SHT_DYNAMIC:
- case SHT_HASH:
- case SHT_SYMTAB_SHNDX:
- case SHT_INIT_ARRAY:
- case SHT_FINI_ARRAY:
- case SHT_PREINIT_ARRAY:
- if (section->sh_info != 0)
- warn (_("[%2u]: Unexpected value (%u) in info field.\n"),
- i, section->sh_info);
- break;
-
- case SHT_GROUP:
- case SHT_SYMTAB:
- case SHT_DYNSYM:
- /* A symbol index - we assume that it is valid. */
- break;
-
- default:
- /* FIXME: Add support for target specific section types. */
- if (section->sh_type == SHT_NOBITS)
- /* NOBITS section headers with non-zero sh_info fields can be
- created when a binary is stripped of everything but its debug
- information. The stripped sections have their headers
- preserved but their types set to SHT_NOBITS. So do not check
- this type of section. */
- ;
- else if (section->sh_flags & SHF_INFO_LINK)
- {
- if (section->sh_info < 1 || section->sh_info >= filedata->file_header.e_shnum)
- warn (_("[%2u]: Expected link to another section in info field"), i);
- }
- else if (section->sh_type < SHT_LOOS
- && (section->sh_flags & SHF_GNU_MBIND) == 0
- && section->sh_info != 0)
- warn (_("[%2u]: Unexpected value (%u) in info field.\n"),
- i, section->sh_info);
- break;
- }
-
- /* Check the sh_size field. */
- if (section->sh_size > filedata->file_size
- && section->sh_type != SHT_NOBITS
- && section->sh_type != SHT_NULL
- && section->sh_type < SHT_LOOS)
- warn (_("Size of section %u is larger than the entire file!\n"), i);
-
- printf (" [%2u] ", i);
- if (do_section_details)
- printf ("%s\n ", printable_section_name (filedata, section));
- else
- print_symbol_name (-17, printable_section_name (filedata, section));
-
- printf (do_wide ? " %-15s " : " %-15.15s ",
- get_section_type_name (filedata, section->sh_type));
-
- if (is_32bit_elf)
- {
- const char * link_too_big = NULL;
-
- print_vma (section->sh_addr, LONG_HEX);
-
- printf ( " %6.6lx %6.6lx %2.2lx",
- (unsigned long) section->sh_offset,
- (unsigned long) section->sh_size,
- (unsigned long) section->sh_entsize);
-
- if (do_section_details)
- fputs (" ", stdout);
- else
- printf (" %3s ", get_elf_section_flags (filedata, section->sh_flags));
-
- if (section->sh_link >= filedata->file_header.e_shnum)
- {
- link_too_big = "";
- /* The sh_link value is out of range. Normally this indicates
- an error but it can have special values in Solaris binaries. */
- switch (filedata->file_header.e_machine)
- {
- case EM_386:
- case EM_IAMCU:
- case EM_X86_64:
- case EM_L1OM:
- case EM_K1OM:
- case EM_OLD_SPARCV9:
- case EM_SPARC32PLUS:
- case EM_SPARCV9:
- case EM_SPARC:
- if (section->sh_link == (SHN_BEFORE & 0xffff))
- link_too_big = "BEFORE";
- else if (section->sh_link == (SHN_AFTER & 0xffff))
- link_too_big = "AFTER";
- break;
- default:
- break;
- }
- }
-
- if (do_section_details)
- {
- if (link_too_big != NULL && * link_too_big)
- printf ("<%s> ", link_too_big);
- else
- printf ("%2u ", section->sh_link);
- printf ("%3u %2lu\n", section->sh_info,
- (unsigned long) section->sh_addralign);
- }
- else
- printf ("%2u %3u %2lu\n",
- section->sh_link,
- section->sh_info,
- (unsigned long) section->sh_addralign);
-
- if (link_too_big && ! * link_too_big)
- warn (_("section %u: sh_link value of %u is larger than the number of sections\n"),
- i, section->sh_link);
- }
- else if (do_wide)
- {
- print_vma (section->sh_addr, LONG_HEX);
-
- if ((long) section->sh_offset == section->sh_offset)
- printf (" %6.6lx", (unsigned long) section->sh_offset);
- else
- {
- putchar (' ');
- print_vma (section->sh_offset, LONG_HEX);
- }
-
- if ((unsigned long) section->sh_size == section->sh_size)
- printf (" %6.6lx", (unsigned long) section->sh_size);
- else
- {
- putchar (' ');
- print_vma (section->sh_size, LONG_HEX);
- }
-
- if ((unsigned long) section->sh_entsize == section->sh_entsize)
- printf (" %2.2lx", (unsigned long) section->sh_entsize);
- else
- {
- putchar (' ');
- print_vma (section->sh_entsize, LONG_HEX);
- }
-
- if (do_section_details)
- fputs (" ", stdout);
- else
- printf (" %3s ", get_elf_section_flags (filedata, section->sh_flags));
-
- printf ("%2u %3u ", section->sh_link, section->sh_info);
-
- if ((unsigned long) section->sh_addralign == section->sh_addralign)
- printf ("%2lu\n", (unsigned long) section->sh_addralign);
- else
- {
- print_vma (section->sh_addralign, DEC);
- putchar ('\n');
- }
- }
- else if (do_section_details)
- {
- putchar (' ');
- print_vma (section->sh_addr, LONG_HEX);
- if ((long) section->sh_offset == section->sh_offset)
- printf (" %16.16lx", (unsigned long) section->sh_offset);
- else
- {
- printf (" ");
- print_vma (section->sh_offset, LONG_HEX);
- }
- printf (" %u\n ", section->sh_link);
- print_vma (section->sh_size, LONG_HEX);
- putchar (' ');
- print_vma (section->sh_entsize, LONG_HEX);
-
- printf (" %-16u %lu\n",
- section->sh_info,
- (unsigned long) section->sh_addralign);
- }
- else
- {
- putchar (' ');
- print_vma (section->sh_addr, LONG_HEX);
- if ((long) section->sh_offset == section->sh_offset)
- printf (" %8.8lx", (unsigned long) section->sh_offset);
- else
- {
- printf (" ");
- print_vma (section->sh_offset, LONG_HEX);
- }
- printf ("\n ");
- print_vma (section->sh_size, LONG_HEX);
- printf (" ");
- print_vma (section->sh_entsize, LONG_HEX);
-
- printf (" %3s ", get_elf_section_flags (filedata, section->sh_flags));
-
- printf (" %2u %3u %lu\n",
- section->sh_link,
- section->sh_info,
- (unsigned long) section->sh_addralign);
- }
-
- if (do_section_details)
- {
- printf (" %s\n", get_elf_section_flags (filedata, section->sh_flags));
- if ((section->sh_flags & SHF_COMPRESSED) != 0)
- {
- /* Minimum section size is 12 bytes for 32-bit compression
- header + 12 bytes for compressed data header. */
- unsigned char buf[24];
-
- assert (sizeof (buf) >= sizeof (Elf64_External_Chdr));
- if (get_data (&buf, filedata, section->sh_offset, 1,
- sizeof (buf), _("compression header")))
- {
- Elf_Internal_Chdr chdr;
-
- if (get_compression_header (&chdr, buf, sizeof (buf)) == 0)
- printf (_(" [<corrupt>]\n"));
- else
- {
- if (chdr.ch_type == ch_compress_zlib)
- printf (" ZLIB, ");
- else if (chdr.ch_type == ch_compress_zstd)
- printf (" ZSTD, ");
- else
- printf (_(" [<unknown>: 0x%x], "),
- chdr.ch_type);
- print_vma (chdr.ch_size, LONG_HEX);
- printf (", %lu\n", (unsigned long) chdr.ch_addralign);
- }
- }
- }
- }
- }
-
- if (!do_section_details)
- {
- /* The ordering of the letters shown here matches the ordering of the
- corresponding SHF_xxx values, and hence the order in which these
- letters will be displayed to the user. */
- printf (_("Key to Flags:\n\
- W (write), A (alloc), X (execute), M (merge), S (strings), I (info),\n\
- L (link order), O (extra OS processing required), G (group), T (TLS),\n\
- C (compressed), x (unknown), o (OS specific), E (exclude),\n "));
- switch (filedata->file_header.e_ident[EI_OSABI])
- {
- case ELFOSABI_GNU:
- case ELFOSABI_FREEBSD:
- printf (_("R (retain), "));
- /* Fall through */
- case ELFOSABI_NONE:
- printf (_("D (mbind), "));
- break;
- default:
- break;
- }
- if (filedata->file_header.e_machine == EM_X86_64
- || filedata->file_header.e_machine == EM_L1OM
- || filedata->file_header.e_machine == EM_K1OM)
- printf (_("l (large), "));
- else if (filedata->file_header.e_machine == EM_ARM)
- printf (_("y (purecode), "));
- else if (filedata->file_header.e_machine == EM_PPC)
- printf (_("v (VLE), "));
- printf ("p (processor specific)\n");
- }
-
- return true;
-}
-
-static bool
-get_symtab (Filedata * filedata,
- Elf_Internal_Shdr * symsec,
- Elf_Internal_Sym ** symtab,
- uint64_t * nsyms,
- char ** strtab,
- uint64_t * strtablen)
-{
- *strtab = NULL;
- *strtablen = 0;
- *symtab = get_elf_symbols (filedata, symsec, nsyms);
-
- if (*symtab == NULL)
- return false;
-
- if (symsec->sh_link != 0)
- {
- Elf_Internal_Shdr *strsec;
-
- if (symsec->sh_link >= filedata->file_header.e_shnum)
- {
- error (_("Bad sh_link in symbol table section\n"));
- free (*symtab);
- *symtab = NULL;
- *nsyms = 0;
- return false;
- }
-
- strsec = filedata->section_headers + symsec->sh_link;
-
- *strtab = (char *) get_data (NULL, filedata, strsec->sh_offset,
- 1, strsec->sh_size, _("string table"));
- if (*strtab == NULL)
- {
- free (*symtab);
- *symtab = NULL;
- *nsyms = 0;
- return false;
- }
- *strtablen = strsec->sh_size;
- }
- return true;
-}
-
-static const char *
-get_group_flags (unsigned int flags)
-{
- static char buff[128];
-
- if (flags == 0)
- return "";
- else if (flags == GRP_COMDAT)
- return "COMDAT ";
-
- snprintf (buff, sizeof buff, "[0x%x: %s%s%s]",
- flags,
- flags & GRP_MASKOS ? _("<OS specific>") : "",
- flags & GRP_MASKPROC ? _("<PROC specific>") : "",
- (flags & ~(GRP_COMDAT | GRP_MASKOS | GRP_MASKPROC)
- ? _("<unknown>") : ""));
-
- return buff;
-}
-
-static bool
-process_section_groups (Filedata * filedata)
-{
- Elf_Internal_Shdr * section;
- unsigned int i;
- struct group * group;
- Elf_Internal_Shdr * symtab_sec;
- Elf_Internal_Shdr * strtab_sec;
- Elf_Internal_Sym * symtab;
- uint64_t num_syms;
- char * strtab;
- size_t strtab_size;
-
- /* Don't process section groups unless needed. */
- if (!do_unwind && !do_section_groups)
- return true;
-
- if (filedata->file_header.e_shnum == 0)
- {
- if (do_section_groups)
- {
- if (filedata->is_separate)
- printf (_("\nThere are no sections group in linked file '%s'.\n"),
- filedata->file_name);
- else
- printf (_("\nThere are no section groups in this file.\n"));
- }
- return true;
- }
-
- if (filedata->section_headers == NULL)
- {
- error (_("Section headers are not available!\n"));
- /* PR 13622: This can happen with a corrupt ELF header. */
- return false;
- }
-
- filedata->section_headers_groups
- = (struct group **) calloc (filedata->file_header.e_shnum,
- sizeof (struct group *));
-
- if (filedata->section_headers_groups == NULL)
- {
- error (_("Out of memory reading %u section group headers\n"),
- filedata->file_header.e_shnum);
- return false;
- }
-
- /* Scan the sections for the group section. */
- filedata->group_count = 0;
- for (i = 0, section = filedata->section_headers;
- i < filedata->file_header.e_shnum;
- i++, section++)
- if (section->sh_type == SHT_GROUP)
- filedata->group_count++;
-
- if (filedata->group_count == 0)
- {
- if (do_section_groups)
- {
- if (filedata->is_separate)
- printf (_("\nThere are no section groups in linked file '%s'.\n"),
- filedata->file_name);
- else
- printf (_("\nThere are no section groups in this file.\n"));
- }
-
- return true;
- }
-
- filedata->section_groups = (struct group *) calloc (filedata->group_count,
- sizeof (struct group));
-
- if (filedata->section_groups == NULL)
- {
- error (_("Out of memory reading %zu groups\n"), filedata->group_count);
- return false;
- }
-
- symtab_sec = NULL;
- strtab_sec = NULL;
- symtab = NULL;
- num_syms = 0;
- strtab = NULL;
- strtab_size = 0;
-
- if (filedata->is_separate)
- printf (_("Section groups in linked file '%s'\n"), filedata->file_name);
-
- for (i = 0, section = filedata->section_headers, group = filedata->section_groups;
- i < filedata->file_header.e_shnum;
- i++, section++)
- {
- if (section->sh_type == SHT_GROUP)
- {
- const char * name = printable_section_name (filedata, section);
- const char * group_name;
- unsigned char * start;
- unsigned char * indices;
- unsigned int entry, j, size;
- Elf_Internal_Shdr * sec;
- Elf_Internal_Sym * sym;
-
- /* Get the symbol table. */
- if (section->sh_link >= filedata->file_header.e_shnum
- || ((sec = filedata->section_headers + section->sh_link)->sh_type
- != SHT_SYMTAB))
- {
- error (_("Bad sh_link in group section `%s'\n"), name);
- continue;
- }
-
- if (symtab_sec != sec)
- {
- symtab_sec = sec;
- free (symtab);
- symtab = get_elf_symbols (filedata, symtab_sec, & num_syms);
- }
-
- if (symtab == NULL)
- {
- error (_("Corrupt header in group section `%s'\n"), name);
- continue;
- }
-
- if (section->sh_info >= num_syms)
- {
- error (_("Bad sh_info in group section `%s'\n"), name);
- continue;
- }
-
- sym = symtab + section->sh_info;
-
- if (ELF_ST_TYPE (sym->st_info) == STT_SECTION)
- {
- if (sym->st_shndx == 0
- || sym->st_shndx >= filedata->file_header.e_shnum)
- {
- error (_("Bad sh_info in group section `%s'\n"), name);
- continue;
- }
-
- group_name = printable_section_name (filedata,
- filedata->section_headers
- + sym->st_shndx);
- strtab_sec = NULL;
- free (strtab);
- strtab = NULL;
- strtab_size = 0;
- }
- else
- {
- /* Get the string table. */
- if (symtab_sec->sh_link >= filedata->file_header.e_shnum)
- {
- strtab_sec = NULL;
- free (strtab);
- strtab = NULL;
- strtab_size = 0;
- }
- else if (strtab_sec
- != (sec = filedata->section_headers + symtab_sec->sh_link))
- {
- strtab_sec = sec;
- free (strtab);
-
- strtab = (char *) get_data (NULL, filedata, strtab_sec->sh_offset,
- 1, strtab_sec->sh_size,
- _("string table"));
- strtab_size = strtab != NULL ? strtab_sec->sh_size : 0;
- }
- group_name = sym->st_name < strtab_size
- ? strtab + sym->st_name : _("<corrupt>");
- }
-
- /* PR 17531: file: loop. */
- if (section->sh_entsize > section->sh_size)
- {
- error (_("Section %s has sh_entsize (%#" PRIx64 ")"
- " which is larger than its size (%#" PRIx64 ")\n"),
- printable_section_name (filedata, section),
- section->sh_entsize,
- section->sh_size);
- continue;
- }
-
- start = (unsigned char *) get_data (NULL, filedata, section->sh_offset,
- 1, section->sh_size,
- _("section data"));
- if (start == NULL)
- continue;
-
- indices = start;
- size = (section->sh_size / section->sh_entsize) - 1;
- entry = byte_get (indices, 4);
- indices += 4;
-
- if (do_section_groups)
- {
- printf (_("\n%sgroup section [%5u] `%s' [%s] contains %u sections:\n"),
- get_group_flags (entry), i, name, group_name, size);
-
- printf (_(" [Index] Name\n"));
- }
-
- group->group_index = i;
-
- for (j = 0; j < size; j++)
- {
- struct group_list * g;
-
- entry = byte_get (indices, 4);
- indices += 4;
-
- if (entry >= filedata->file_header.e_shnum)
- {
- static unsigned num_group_errors = 0;
-
- if (num_group_errors ++ < 10)
- {
- error (_("section [%5u] in group section [%5u] > maximum section [%5u]\n"),
- entry, i, filedata->file_header.e_shnum - 1);
- if (num_group_errors == 10)
- warn (_("Further error messages about overlarge group section indices suppressed\n"));
- }
- continue;
- }
-
- if (filedata->section_headers_groups [entry] != NULL)
- {
- if (entry)
- {
- static unsigned num_errs = 0;
-
- if (num_errs ++ < 10)
- {
- error (_("section [%5u] in group section [%5u] already in group section [%5u]\n"),
- entry, i,
- filedata->section_headers_groups [entry]->group_index);
- if (num_errs == 10)
- warn (_("Further error messages about already contained group sections suppressed\n"));
- }
- continue;
- }
- else
- {
- /* Intel C/C++ compiler may put section 0 in a
- section group. We just warn it the first time
- and ignore it afterwards. */
- static bool warned = false;
- if (!warned)
- {
- error (_("section 0 in group section [%5u]\n"),
- filedata->section_headers_groups [entry]->group_index);
- warned = true;
- }
- }
- }
-
- filedata->section_headers_groups [entry] = group;
-
- if (do_section_groups)
- {
- sec = filedata->section_headers + entry;
- printf (" [%5u] %s\n", entry, printable_section_name (filedata, sec));
- }
-
- g = (struct group_list *) xmalloc (sizeof (struct group_list));
- g->section_index = entry;
- g->next = group->root;
- group->root = g;
- }
-
- free (start);
-
- group++;
- }
- }
-
- free (symtab);
- free (strtab);
- return true;
-}
-
-/* Data used to display dynamic fixups. */
-
-struct ia64_vms_dynfixup
-{
- uint64_t needed_ident; /* Library ident number. */
- uint64_t needed; /* Index in the dstrtab of the library name. */
- uint64_t fixup_needed; /* Index of the library. */
- uint64_t fixup_rela_cnt; /* Number of fixups. */
- uint64_t fixup_rela_off; /* Fixups offset in the dynamic segment. */
-};
-
-/* Data used to display dynamic relocations. */
-
-struct ia64_vms_dynimgrela
-{
- uint64_t img_rela_cnt; /* Number of relocations. */
- uint64_t img_rela_off; /* Reloc offset in the dynamic segment. */
-};
-
-/* Display IA-64 OpenVMS dynamic fixups (used to dynamically link a shared
- library). */
-
-static bool
-dump_ia64_vms_dynamic_fixups (Filedata * filedata,
- struct ia64_vms_dynfixup * fixup,
- const char * strtab,
- unsigned int strtab_sz)
-{
- Elf64_External_VMS_IMAGE_FIXUP * imfs;
- size_t i;
- const char * lib_name;
-
- imfs = get_data (NULL, filedata,
- filedata->dynamic_addr + fixup->fixup_rela_off,
- sizeof (*imfs), fixup->fixup_rela_cnt,
- _("dynamic section image fixups"));
- if (!imfs)
- return false;
-
- if (fixup->needed < strtab_sz)
- lib_name = strtab + fixup->needed;
- else
- {
- warn (_("corrupt library name index of %#" PRIx64
- " found in dynamic entry"), fixup->needed);
- lib_name = "???";
- }
-
- printf (_("\nImage fixups for needed library #%" PRId64
- ": %s - ident: %" PRIx64 "\n"),
- fixup->fixup_needed, lib_name, fixup->needed_ident);
- printf
- (_("Seg Offset Type SymVec DataType\n"));
-
- for (i = 0; i < (size_t) fixup->fixup_rela_cnt; i++)
- {
- unsigned int type;
- const char *rtype;
-
- printf ("%3u ", (unsigned) BYTE_GET (imfs [i].fixup_seg));
- printf ("%016" PRIx64 " ", BYTE_GET (imfs [i].fixup_offset));
- type = BYTE_GET (imfs [i].type);
- rtype = elf_ia64_reloc_type (type);
- if (rtype == NULL)
- printf ("0x%08x ", type);
- else
- printf ("%-32s ", rtype);
- printf ("%6u ", (unsigned) BYTE_GET (imfs [i].symvec_index));
- printf ("0x%08x\n", (unsigned) BYTE_GET (imfs [i].data_type));
- }
-
- free (imfs);
- return true;
-}
-
-/* Display IA-64 OpenVMS dynamic relocations (used to relocate an image). */
-
-static bool
-dump_ia64_vms_dynamic_relocs (Filedata * filedata, struct ia64_vms_dynimgrela *imgrela)
-{
- Elf64_External_VMS_IMAGE_RELA *imrs;
- size_t i;
-
- imrs = get_data (NULL, filedata,
- filedata->dynamic_addr + imgrela->img_rela_off,
- sizeof (*imrs), imgrela->img_rela_cnt,
- _("dynamic section image relocations"));
- if (!imrs)
- return false;
-
- printf (_("\nImage relocs\n"));
- printf
- (_("Seg Offset Type Addend Seg Sym Off\n"));
-
- for (i = 0; i < (size_t) imgrela->img_rela_cnt; i++)
- {
- unsigned int type;
- const char *rtype;
-
- printf ("%3u ", (unsigned) BYTE_GET (imrs [i].rela_seg));
- printf ("%08" PRIx64 " ", BYTE_GET (imrs [i].rela_offset));
- type = BYTE_GET (imrs [i].type);
- rtype = elf_ia64_reloc_type (type);
- if (rtype == NULL)
- printf ("0x%08x ", type);
- else
- printf ("%-31s ", rtype);
- print_vma (BYTE_GET (imrs [i].addend), FULL_HEX);
- printf ("%3u ", (unsigned) BYTE_GET (imrs [i].sym_seg));
- printf ("%08" PRIx64 "\n", BYTE_GET (imrs [i].sym_offset));
- }
-
- free (imrs);
- return true;
-}
-
-/* Display IA-64 OpenVMS dynamic relocations and fixups. */
-
-static bool
-process_ia64_vms_dynamic_relocs (Filedata * filedata)
-{
- struct ia64_vms_dynfixup fixup;
- struct ia64_vms_dynimgrela imgrela;
- Elf_Internal_Dyn *entry;
- uint64_t strtab_off = 0;
- uint64_t strtab_sz = 0;
- char *strtab = NULL;
- bool res = true;
-
- memset (&fixup, 0, sizeof (fixup));
- memset (&imgrela, 0, sizeof (imgrela));
-
- /* Note: the order of the entries is specified by the OpenVMS specs. */
- for (entry = filedata->dynamic_section;
- entry < filedata->dynamic_section + filedata->dynamic_nent;
- entry++)
- {
- switch (entry->d_tag)
- {
- case DT_IA_64_VMS_STRTAB_OFFSET:
- strtab_off = entry->d_un.d_val;
- break;
- case DT_STRSZ:
- strtab_sz = entry->d_un.d_val;
- if (strtab == NULL)
- strtab = get_data (NULL, filedata,
- filedata->dynamic_addr + strtab_off,
- 1, strtab_sz, _("dynamic string section"));
- if (strtab == NULL)
- strtab_sz = 0;
- break;
-
- case DT_IA_64_VMS_NEEDED_IDENT:
- fixup.needed_ident = entry->d_un.d_val;
- break;
- case DT_NEEDED:
- fixup.needed = entry->d_un.d_val;
- break;
- case DT_IA_64_VMS_FIXUP_NEEDED:
- fixup.fixup_needed = entry->d_un.d_val;
- break;
- case DT_IA_64_VMS_FIXUP_RELA_CNT:
- fixup.fixup_rela_cnt = entry->d_un.d_val;
- break;
- case DT_IA_64_VMS_FIXUP_RELA_OFF:
- fixup.fixup_rela_off = entry->d_un.d_val;
- if (! dump_ia64_vms_dynamic_fixups (filedata, &fixup, strtab, strtab_sz))
- res = false;
- break;
- case DT_IA_64_VMS_IMG_RELA_CNT:
- imgrela.img_rela_cnt = entry->d_un.d_val;
- break;
- case DT_IA_64_VMS_IMG_RELA_OFF:
- imgrela.img_rela_off = entry->d_un.d_val;
- if (! dump_ia64_vms_dynamic_relocs (filedata, &imgrela))
- res = false;
- break;
-
- default:
- break;
- }
- }
-
- free (strtab);
-
- return res;
-}
-
-static struct
-{
- const char * name;
- int reloc;
- int size;
- relocation_type rel_type;
-}
- dynamic_relocations [] =
-{
- { "REL", DT_REL, DT_RELSZ, reltype_rel },
- { "RELA", DT_RELA, DT_RELASZ, reltype_rela },
- { "RELR", DT_RELR, DT_RELRSZ, reltype_relr },
- { "PLT", DT_JMPREL, DT_PLTRELSZ, reltype_unknown }
-};
-
-static relocation_type
-rel_type_from_sh_type (unsigned int sh_type)
-{
- switch (sh_type)
- {
- case SHT_RELA: return reltype_rela;
- case SHT_REL: return reltype_rel;
- case SHT_RELR: return reltype_relr;
- default: return reltype_unknown;
- }
-}
-
-static bool
-display_relocations (Elf_Internal_Shdr * section,
- Filedata * filedata)
-{
- relocation_type rel_type = rel_type_from_sh_type (section->sh_type);
-
- if (rel_type == reltype_unknown)
- return false;
-
- uint64_t rel_size = section->sh_size;
-
- if (rel_size == 0)
- return false;
-
- if (filedata->is_separate)
- printf (_("\nIn linked file '%s' relocation section "),
- filedata->file_name);
- else
- printf (_("\nRelocation section "));
-
- if (filedata->string_table == NULL)
- printf ("%d", section->sh_name);
- else
- printf ("'%s'", printable_section_name (filedata, section));
-
- uint64_t num_rela = rel_size / section->sh_entsize;
- uint64_t rel_offset = section->sh_offset;
-
- if (rel_type == reltype_relr)
- {
- /* Just stating the 'number of entries' in a RELR section can be
- misleading, since this is not the number of locations relocated, but
- the number of words in the compressed RELR format. So also provide
- the number of locations affected. */
- if (num_rela == 1)
- /* This is unlikely, but possible. */
- printf (_(" at offset %#" PRIx64
- " contains 1 entry which relocates 1 location:\n"),
- rel_offset);
- else
- printf (_(" at offset %#" PRIx64 " contains %" PRIu64
- " entries which relocate %" PRIu64 " locations:\n"),
- rel_offset, num_rela, count_relr_relocations (filedata, section));
- }
- else
- {
- printf (ngettext (" at offset %#" PRIx64
- " contains %" PRIu64 " entry:\n",
- " at offset %#" PRIx64
- " contains %" PRIu64 " entries:\n",
- num_rela),
- rel_offset, num_rela);
- }
-
- Elf_Internal_Shdr * symsec;
- Elf_Internal_Sym * symtab = NULL;
- uint64_t nsyms = 0;
- uint64_t strtablen = 0;
- char * strtab = NULL;
-
- if (section->sh_link == 0
- || section->sh_link >= filedata->file_header.e_shnum)
- {
- /* Symbol data not available.
- This can happen, especially with RELR relocs.
- See if there is a .symtab section present.
- If so then use it. */
- symsec = find_section_by_name (filedata, ".symtab");
- }
- else
- {
- symsec = filedata->section_headers + section->sh_link;
-
- if (symsec->sh_type != SHT_SYMTAB
- && symsec->sh_type != SHT_DYNSYM)
- return false;
- }
-
- if (symsec != NULL
- && !get_symtab (filedata, symsec, &symtab, &nsyms, &strtab, &strtablen))
- return false;
-
- bool res;
-
- if (rel_type == reltype_relr)
- res = dump_relr_relocations (filedata, section, symtab, nsyms, strtab, strtablen);
- else
- res = dump_relocations (filedata, rel_offset, rel_size,
- symtab, nsyms, strtab, strtablen,
- rel_type,
- symsec == NULL ? false : symsec->sh_type == SHT_DYNSYM);
- free (strtab);
- free (symtab);
-
- return res;
-}
-
-/* Process the reloc section. */
-
-static bool
-process_relocs (Filedata * filedata)
-{
- uint64_t rel_size;
- uint64_t rel_offset;
-
- if (!do_reloc)
- return true;
-
- if (do_using_dynamic)
- {
- relocation_type rel_type;
- const char * name;
- bool has_dynamic_reloc;
- unsigned int i;
-
- has_dynamic_reloc = false;
-
- for (i = 0; i < ARRAY_SIZE (dynamic_relocations); i++)
- {
- rel_type = dynamic_relocations [i].rel_type;
- name = dynamic_relocations [i].name;
- rel_size = filedata->dynamic_info[dynamic_relocations [i].size];
- rel_offset = filedata->dynamic_info[dynamic_relocations [i].reloc];
-
- if (rel_size)
- has_dynamic_reloc = true;
-
- if (rel_type == reltype_unknown)
- {
- if (dynamic_relocations [i].reloc == DT_JMPREL)
- switch (filedata->dynamic_info[DT_PLTREL])
- {
- case DT_REL:
- rel_type = reltype_rel;
- break;
- case DT_RELA:
- rel_type = reltype_rela;
- break;
- }
- }
-
- if (rel_size)
- {
- if (filedata->is_separate)
- printf
- (_("\nIn linked file '%s' section '%s' at offset %#" PRIx64
- " contains %" PRId64 " bytes:\n"),
- filedata->file_name, name, rel_offset, rel_size);
- else
- printf
- (_("\n'%s' relocation section at offset %#" PRIx64
- " contains %" PRId64 " bytes:\n"),
- name, rel_offset, rel_size);
-
- dump_relocations (filedata,
- offset_from_vma (filedata, rel_offset, rel_size),
- rel_size,
- filedata->dynamic_symbols,
- filedata->num_dynamic_syms,
- filedata->dynamic_strings,
- filedata->dynamic_strings_length,
- rel_type, true /* is_dynamic */);
- }
- }
-
- if (is_ia64_vms (filedata))
- if (process_ia64_vms_dynamic_relocs (filedata))
- has_dynamic_reloc = true;
-
- if (! has_dynamic_reloc)
- {
- if (filedata->is_separate)
- printf (_("\nThere are no dynamic relocations in linked file '%s'.\n"),
- filedata->file_name);
- else
- printf (_("\nThere are no dynamic relocations in this file.\n"));
- }
- }
- else
- {
- Elf_Internal_Shdr * section;
- size_t i;
- bool found = false;
-
- for (i = 0, section = filedata->section_headers;
- i < filedata->file_header.e_shnum;
- i++, section++)
- {
- if (display_relocations (section, filedata))
- found = true;
- }
-
- if (! found)
- {
- /* Users sometimes forget the -D option, so try to be helpful. */
- for (i = 0; i < ARRAY_SIZE (dynamic_relocations); i++)
- {
- if (filedata->dynamic_info[dynamic_relocations [i].size])
- {
- if (filedata->is_separate)
- printf (_("\nThere are no static relocations in linked file '%s'."),
- filedata->file_name);
- else
- printf (_("\nThere are no static relocations in this file."));
- printf (_("\nTo see the dynamic relocations add --use-dynamic to the command line.\n"));
-
- break;
- }
- }
- if (i == ARRAY_SIZE (dynamic_relocations))
- {
- if (filedata->is_separate)
- printf (_("\nThere are no relocations in linked file '%s'.\n"),
- filedata->file_name);
- else
- printf (_("\nThere are no relocations in this file.\n"));
- }
- }
- }
-
- return true;
-}
-
-/* An absolute address consists of a section and an offset. If the
- section is NULL, the offset itself is the address, otherwise, the
- address equals to LOAD_ADDRESS(section) + offset. */
-
-struct absaddr
-{
- unsigned short section;
- uint64_t offset;
-};
-
-/* Find the nearest symbol at or below ADDR. Returns the symbol
- name, if found, and the offset from the symbol to ADDR. */
-
-static void
-find_symbol_for_address (Filedata *filedata,
- Elf_Internal_Sym *symtab,
- uint64_t nsyms,
- const char *strtab,
- uint64_t strtab_size,
- struct absaddr addr,
- const char **symname,
- uint64_t *offset)
-{
- uint64_t dist = 0x100000;
- Elf_Internal_Sym * sym;
- Elf_Internal_Sym * beg;
- Elf_Internal_Sym * end;
- Elf_Internal_Sym * best = NULL;
-
- REMOVE_ARCH_BITS (addr.offset);
- beg = symtab;
- end = symtab + nsyms;
-
- while (beg < end)
- {
- uint64_t value;
-
- sym = beg + (end - beg) / 2;
-
- value = sym->st_value;
- REMOVE_ARCH_BITS (value);
-
- if (sym->st_name != 0
- && (addr.section == SHN_UNDEF || addr.section == sym->st_shndx)
- && addr.offset >= value
- && addr.offset - value < dist)
- {
- best = sym;
- dist = addr.offset - value;
- if (!dist)
- break;
- }
-
- if (addr.offset < value)
- end = sym;
- else
- beg = sym + 1;
- }
-
- if (best)
- {
- *symname = (best->st_name >= strtab_size
- ? _("<corrupt>") : strtab + best->st_name);
- *offset = dist;
- return;
- }
-
- *symname = NULL;
- *offset = addr.offset;
-}
-
-/* Process the unwind section. */
-
-#include "unwind-ia64.h"
-
-struct ia64_unw_table_entry
-{
- struct absaddr start;
- struct absaddr end;
- struct absaddr info;
-};
-
-struct ia64_unw_aux_info
-{
- struct ia64_unw_table_entry * table; /* Unwind table. */
- uint64_t table_len; /* Length of unwind table. */
- unsigned char * info; /* Unwind info. */
- uint64_t info_size; /* Size of unwind info. */
- uint64_t info_addr; /* Starting address of unwind info. */
- uint64_t seg_base; /* Starting address of segment. */
- Elf_Internal_Sym * symtab; /* The symbol table. */
- uint64_t nsyms; /* Number of symbols. */
- Elf_Internal_Sym * funtab; /* Sorted table of STT_FUNC symbols. */
- uint64_t nfuns; /* Number of entries in funtab. */
- char * strtab; /* The string table. */
- uint64_t strtab_size; /* Size of string table. */
-};
-
-static bool
-dump_ia64_unwind (Filedata * filedata, struct ia64_unw_aux_info * aux)
-{
- struct ia64_unw_table_entry * tp;
- size_t j, nfuns;
- int in_body;
- bool res = true;
-
- aux->funtab = xmalloc (aux->nsyms * sizeof (Elf_Internal_Sym));
- for (nfuns = 0, j = 0; j < aux->nsyms; j++)
- if (aux->symtab[j].st_value && ELF_ST_TYPE (aux->symtab[j].st_info) == STT_FUNC)
- aux->funtab[nfuns++] = aux->symtab[j];
- aux->nfuns = nfuns;
- qsort (aux->funtab, aux->nfuns, sizeof (Elf_Internal_Sym), symcmp);
-
- for (tp = aux->table; tp < aux->table + aux->table_len; ++tp)
- {
- uint64_t stamp;
- uint64_t offset;
- const unsigned char * dp;
- const unsigned char * head;
- const unsigned char * end;
- const char * procname;
-
- find_symbol_for_address (filedata, aux->funtab, aux->nfuns, aux->strtab,
- aux->strtab_size, tp->start, &procname, &offset);
-
- fputs ("\n<", stdout);
-
- if (procname)
- {
- fputs (procname, stdout);
-
- if (offset)
- printf ("+%" PRIx64, offset);
- }
-
- fputs (">: [", stdout);
- print_vma (tp->start.offset, PREFIX_HEX);
- fputc ('-', stdout);
- print_vma (tp->end.offset, PREFIX_HEX);
- printf ("], info at +0x%" PRIx64 "\n",
- tp->info.offset - aux->seg_base);
-
- /* PR 17531: file: 86232b32. */
- if (aux->info == NULL)
- continue;
-
- offset = tp->info.offset;
- if (tp->info.section)
- {
- if (tp->info.section >= filedata->file_header.e_shnum)
- {
- warn (_("Invalid section %u in table entry %td\n"),
- tp->info.section, tp - aux->table);
- res = false;
- continue;
- }
- offset += filedata->section_headers[tp->info.section].sh_addr;
- }
- offset -= aux->info_addr;
- /* PR 17531: file: 0997b4d1. */
- if (offset >= aux->info_size
- || aux->info_size - offset < 8)
- {
- warn (_("Invalid offset %" PRIx64 " in table entry %td\n"),
- tp->info.offset, tp - aux->table);
- res = false;
- continue;
- }
-
- head = aux->info + offset;
- stamp = byte_get ((unsigned char *) head, sizeof (stamp));
-
- printf (" v%u, flags=0x%lx (%s%s), len=%lu bytes\n",
- (unsigned) UNW_VER (stamp),
- (unsigned long) ((stamp & UNW_FLAG_MASK) >> 32),
- UNW_FLAG_EHANDLER (stamp) ? " ehandler" : "",
- UNW_FLAG_UHANDLER (stamp) ? " uhandler" : "",
- (unsigned long) (eh_addr_size * UNW_LENGTH (stamp)));
-
- if (UNW_VER (stamp) != 1)
- {
- printf (_("\tUnknown version.\n"));
- continue;
- }
-
- in_body = 0;
- end = head + 8 + eh_addr_size * UNW_LENGTH (stamp);
- /* PR 17531: file: 16ceda89. */
- if (end > aux->info + aux->info_size)
- end = aux->info + aux->info_size;
- for (dp = head + 8; dp < end;)
- dp = unw_decode (dp, in_body, & in_body, end);
- }
-
- free (aux->funtab);
-
- return res;
-}
-
-static bool
-slurp_ia64_unwind_table (Filedata * filedata,
- struct ia64_unw_aux_info * aux,
- Elf_Internal_Shdr * sec)
-{
- uint64_t size, nrelas, i;
- Elf_Internal_Phdr * seg;
- struct ia64_unw_table_entry * tep;
- Elf_Internal_Shdr * relsec;
- Elf_Internal_Rela * rela;
- Elf_Internal_Rela * rp;
- unsigned char * table;
- unsigned char * tp;
- Elf_Internal_Sym * sym;
- const char * relname;
-
- aux->table_len = 0;
-
- /* First, find the starting address of the segment that includes
- this section: */
-
- if (filedata->file_header.e_phnum)
- {
- if (! get_program_headers (filedata))
- return false;
-
- for (seg = filedata->program_headers;
- seg < filedata->program_headers + filedata->file_header.e_phnum;
- ++seg)
- {
- if (seg->p_type != PT_LOAD)
- continue;
-
- if (sec->sh_addr >= seg->p_vaddr
- && (sec->sh_addr + sec->sh_size <= seg->p_vaddr + seg->p_memsz))
- {
- aux->seg_base = seg->p_vaddr;
- break;
- }
- }
- }
-
- /* Second, build the unwind table from the contents of the unwind section: */
- size = sec->sh_size;
- table = (unsigned char *) get_data (NULL, filedata, sec->sh_offset, 1, size,
- _("unwind table"));
- if (!table)
- return false;
-
- aux->table_len = size / (3 * eh_addr_size);
- aux->table = (struct ia64_unw_table_entry *)
- xcmalloc (aux->table_len, sizeof (aux->table[0]));
- tep = aux->table;
-
- for (tp = table; tp <= table + size - (3 * eh_addr_size); ++tep)
- {
- tep->start.section = SHN_UNDEF;
- tep->end.section = SHN_UNDEF;
- tep->info.section = SHN_UNDEF;
- tep->start.offset = byte_get (tp, eh_addr_size); tp += eh_addr_size;
- tep->end.offset = byte_get (tp, eh_addr_size); tp += eh_addr_size;
- tep->info.offset = byte_get (tp, eh_addr_size); tp += eh_addr_size;
- tep->start.offset += aux->seg_base;
- tep->end.offset += aux->seg_base;
- tep->info.offset += aux->seg_base;
- }
- free (table);
-
- /* Third, apply any relocations to the unwind table: */
- for (relsec = filedata->section_headers;
- relsec < filedata->section_headers + filedata->file_header.e_shnum;
- ++relsec)
- {
- if (relsec->sh_type != SHT_RELA
- || relsec->sh_info >= filedata->file_header.e_shnum
- || filedata->section_headers + relsec->sh_info != sec)
- continue;
-
- if (!slurp_rela_relocs (filedata, relsec->sh_offset, relsec->sh_size,
- & rela, & nrelas))
- {
- free (aux->table);
- aux->table = NULL;
- aux->table_len = 0;
- return false;
- }
-
- for (rp = rela; rp < rela + nrelas; ++rp)
- {
- unsigned int sym_ndx;
- unsigned int r_type = get_reloc_type (filedata, rp->r_info);
- relname = elf_ia64_reloc_type (r_type);
-
- /* PR 17531: file: 9fa67536. */
- if (relname == NULL)
- {
- warn (_("Skipping unknown relocation type: %u\n"), r_type);
- continue;
- }
-
- if (! startswith (relname, "R_IA64_SEGREL"))
- {
- warn (_("Skipping unexpected relocation type: %s\n"), relname);
- continue;
- }
-
- i = rp->r_offset / (3 * eh_addr_size);
-
- /* PR 17531: file: 5bc8d9bf. */
- if (i >= aux->table_len)
- {
- warn (_("Skipping reloc with overlarge offset: %#" PRIx64 "\n"),
- i);
- continue;
- }
-
- sym_ndx = get_reloc_symindex (rp->r_info);
- if (sym_ndx >= aux->nsyms)
- {
- warn (_("Skipping reloc with invalid symbol index: %u\n"),
- sym_ndx);
- continue;
- }
- sym = aux->symtab + sym_ndx;
-
- switch (rp->r_offset / eh_addr_size % 3)
- {
- case 0:
- aux->table[i].start.section = sym->st_shndx;
- aux->table[i].start.offset = rp->r_addend + sym->st_value;
- break;
- case 1:
- aux->table[i].end.section = sym->st_shndx;
- aux->table[i].end.offset = rp->r_addend + sym->st_value;
- break;
- case 2:
- aux->table[i].info.section = sym->st_shndx;
- aux->table[i].info.offset = rp->r_addend + sym->st_value;
- break;
- default:
- break;
- }
- }
-
- free (rela);
- }
-
- return true;
-}
-
-static bool
-ia64_process_unwind (Filedata * filedata)
-{
- Elf_Internal_Shdr * sec;
- Elf_Internal_Shdr * unwsec = NULL;
- uint64_t i, unwcount = 0, unwstart = 0;
- struct ia64_unw_aux_info aux;
- bool res = true;
-
- memset (& aux, 0, sizeof (aux));
-
- for (i = 0, sec = filedata->section_headers; i < filedata->file_header.e_shnum; ++i, ++sec)
- {
- if (sec->sh_type == SHT_SYMTAB)
- {
- if (aux.symtab)
- {
- error (_("Multiple symbol tables encountered\n"));
- free (aux.symtab);
- aux.symtab = NULL;
- free (aux.strtab);
- aux.strtab = NULL;
- }
- if (!get_symtab (filedata, sec, &aux.symtab, &aux.nsyms,
- &aux.strtab, &aux.strtab_size))
- return false;
- }
- else if (sec->sh_type == SHT_IA_64_UNWIND)
- unwcount++;
- }
-
- if (!unwcount)
- printf (_("\nThere are no unwind sections in this file.\n"));
-
- while (unwcount-- > 0)
- {
- const char *suffix;
- size_t len, len2;
-
- for (i = unwstart, sec = filedata->section_headers + unwstart, unwsec = NULL;
- i < filedata->file_header.e_shnum; ++i, ++sec)
- if (sec->sh_type == SHT_IA_64_UNWIND)
- {
- unwsec = sec;
- break;
- }
- /* We have already counted the number of SHT_IA64_UNWIND
- sections so the loop above should never fail. */
- assert (unwsec != NULL);
-
- unwstart = i + 1;
- len = sizeof (ELF_STRING_ia64_unwind_once) - 1;
-
- if ((unwsec->sh_flags & SHF_GROUP) != 0)
- {
- /* We need to find which section group it is in. */
- struct group_list * g;
-
- if (filedata->section_headers_groups == NULL
- || filedata->section_headers_groups[i] == NULL)
- i = filedata->file_header.e_shnum;
- else
- {
- g = filedata->section_headers_groups[i]->root;
-
- for (; g != NULL; g = g->next)
- {
- sec = filedata->section_headers + g->section_index;
-
- if (section_name_valid (filedata, sec)
- && streq (section_name (filedata, sec),
- ELF_STRING_ia64_unwind_info))
- break;
- }
-
- if (g == NULL)
- i = filedata->file_header.e_shnum;
- }
- }
- else if (section_name_valid (filedata, unwsec)
- && startswith (section_name (filedata, unwsec),
- ELF_STRING_ia64_unwind_once))
- {
- /* .gnu.linkonce.ia64unw.FOO -> .gnu.linkonce.ia64unwi.FOO. */
- len2 = sizeof (ELF_STRING_ia64_unwind_info_once) - 1;
- suffix = section_name (filedata, unwsec) + len;
- for (i = 0, sec = filedata->section_headers;
- i < filedata->file_header.e_shnum;
- ++i, ++sec)
- if (section_name_valid (filedata, sec)
- && startswith (section_name (filedata, sec),
- ELF_STRING_ia64_unwind_info_once)
- && streq (section_name (filedata, sec) + len2, suffix))
- break;
- }
- else
- {
- /* .IA_64.unwindFOO -> .IA_64.unwind_infoFOO
- .IA_64.unwind or BAR -> .IA_64.unwind_info. */
- len = sizeof (ELF_STRING_ia64_unwind) - 1;
- len2 = sizeof (ELF_STRING_ia64_unwind_info) - 1;
- suffix = "";
- if (section_name_valid (filedata, unwsec)
- && startswith (section_name (filedata, unwsec),
- ELF_STRING_ia64_unwind))
- suffix = section_name (filedata, unwsec) + len;
- for (i = 0, sec = filedata->section_headers;
- i < filedata->file_header.e_shnum;
- ++i, ++sec)
- if (section_name_valid (filedata, sec)
- && startswith (section_name (filedata, sec),
- ELF_STRING_ia64_unwind_info)
- && streq (section_name (filedata, sec) + len2, suffix))
- break;
- }
-
- if (i == filedata->file_header.e_shnum)
- {
- printf (_("\nCould not find unwind info section for "));
-
- if (filedata->string_table == NULL)
- printf ("%d", unwsec->sh_name);
- else
- printf ("'%s'", printable_section_name (filedata, unwsec));
- }
- else
- {
- aux.info_addr = sec->sh_addr;
- aux.info = (unsigned char *) get_data (NULL, filedata, sec->sh_offset, 1,
- sec->sh_size,
- _("unwind info"));
- aux.info_size = aux.info == NULL ? 0 : sec->sh_size;
-
- printf (_("\nUnwind section "));
-
- if (filedata->string_table == NULL)
- printf ("%d", unwsec->sh_name);
- else
- printf ("'%s'", printable_section_name (filedata, unwsec));
-
- printf (_(" at offset %#" PRIx64 " contains %" PRIu64 " entries:\n"),
- unwsec->sh_offset,
- unwsec->sh_size / (3 * eh_addr_size));
-
- if (slurp_ia64_unwind_table (filedata, & aux, unwsec)
- && aux.table_len > 0)
- dump_ia64_unwind (filedata, & aux);
-
- free ((char *) aux.table);
- free ((char *) aux.info);
- aux.table = NULL;
- aux.info = NULL;
- }
- }
-
- free (aux.symtab);
- free ((char *) aux.strtab);
-
- return res;
-}
-
-struct hppa_unw_table_entry
-{
- struct absaddr start;
- struct absaddr end;
- unsigned int Cannot_unwind:1; /* 0 */
- unsigned int Millicode:1; /* 1 */
- unsigned int Millicode_save_sr0:1; /* 2 */
- unsigned int Region_description:2; /* 3..4 */
- unsigned int reserved1:1; /* 5 */
- unsigned int Entry_SR:1; /* 6 */
- unsigned int Entry_FR:4; /* Number saved 7..10 */
- unsigned int Entry_GR:5; /* Number saved 11..15 */
- unsigned int Args_stored:1; /* 16 */
- unsigned int Variable_Frame:1; /* 17 */
- unsigned int Separate_Package_Body:1; /* 18 */
- unsigned int Frame_Extension_Millicode:1; /* 19 */
- unsigned int Stack_Overflow_Check:1; /* 20 */
- unsigned int Two_Instruction_SP_Increment:1; /* 21 */
- unsigned int Ada_Region:1; /* 22 */
- unsigned int cxx_info:1; /* 23 */
- unsigned int cxx_try_catch:1; /* 24 */
- unsigned int sched_entry_seq:1; /* 25 */
- unsigned int reserved2:1; /* 26 */
- unsigned int Save_SP:1; /* 27 */
- unsigned int Save_RP:1; /* 28 */
- unsigned int Save_MRP_in_frame:1; /* 29 */
- unsigned int extn_ptr_defined:1; /* 30 */
- unsigned int Cleanup_defined:1; /* 31 */
-
- unsigned int MPE_XL_interrupt_marker:1; /* 0 */
- unsigned int HP_UX_interrupt_marker:1; /* 1 */
- unsigned int Large_frame:1; /* 2 */
- unsigned int Pseudo_SP_Set:1; /* 3 */
- unsigned int reserved4:1; /* 4 */
- unsigned int Total_frame_size:27; /* 5..31 */
-};
-
-struct hppa_unw_aux_info
-{
- struct hppa_unw_table_entry * table; /* Unwind table. */
- uint64_t table_len; /* Length of unwind table. */
- uint64_t seg_base; /* Starting address of segment. */
- Elf_Internal_Sym * symtab; /* The symbol table. */
- uint64_t nsyms; /* Number of symbols. */
- Elf_Internal_Sym * funtab; /* Sorted table of STT_FUNC symbols. */
- uint64_t nfuns; /* Number of entries in funtab. */
- char * strtab; /* The string table. */
- uint64_t strtab_size; /* Size of string table. */
-};
-
-static bool
-dump_hppa_unwind (Filedata * filedata, struct hppa_unw_aux_info * aux)
-{
- struct hppa_unw_table_entry * tp;
- uint64_t j, nfuns;
- bool res = true;
-
- aux->funtab = xmalloc (aux->nsyms * sizeof (Elf_Internal_Sym));
- for (nfuns = 0, j = 0; j < aux->nsyms; j++)
- if (aux->symtab[j].st_value && ELF_ST_TYPE (aux->symtab[j].st_info) == STT_FUNC)
- aux->funtab[nfuns++] = aux->symtab[j];
- aux->nfuns = nfuns;
- qsort (aux->funtab, aux->nfuns, sizeof (Elf_Internal_Sym), symcmp);
-
- for (tp = aux->table; tp < aux->table + aux->table_len; ++tp)
- {
- uint64_t offset;
- const char * procname;
-
- find_symbol_for_address (filedata, aux->funtab, aux->nfuns, aux->strtab,
- aux->strtab_size, tp->start, &procname,
- &offset);
-
- fputs ("\n<", stdout);
-
- if (procname)
- {
- fputs (procname, stdout);
-
- if (offset)
- printf ("+%" PRIx64, offset);
- }
-
- fputs (">: [", stdout);
- print_vma (tp->start.offset, PREFIX_HEX);
- fputc ('-', stdout);
- print_vma (tp->end.offset, PREFIX_HEX);
- printf ("]\n\t");
-
-#define PF(_m) if (tp->_m) printf (#_m " ");
-#define PV(_m) if (tp->_m) printf (#_m "=%d ", tp->_m);
- PF(Cannot_unwind);
- PF(Millicode);
- PF(Millicode_save_sr0);
- /* PV(Region_description); */
- PF(Entry_SR);
- PV(Entry_FR);
- PV(Entry_GR);
- PF(Args_stored);
- PF(Variable_Frame);
- PF(Separate_Package_Body);
- PF(Frame_Extension_Millicode);
- PF(Stack_Overflow_Check);
- PF(Two_Instruction_SP_Increment);
- PF(Ada_Region);
- PF(cxx_info);
- PF(cxx_try_catch);
- PF(sched_entry_seq);
- PF(Save_SP);
- PF(Save_RP);
- PF(Save_MRP_in_frame);
- PF(extn_ptr_defined);
- PF(Cleanup_defined);
- PF(MPE_XL_interrupt_marker);
- PF(HP_UX_interrupt_marker);
- PF(Large_frame);
- PF(Pseudo_SP_Set);
- PV(Total_frame_size);
-#undef PF
-#undef PV
- }
-
- printf ("\n");
-
- free (aux->funtab);
-
- return res;
-}
-
-static bool
-slurp_hppa_unwind_table (Filedata * filedata,
- struct hppa_unw_aux_info * aux,
- Elf_Internal_Shdr * sec)
-{
- uint64_t size, unw_ent_size, nentries, nrelas, i;
- Elf_Internal_Phdr * seg;
- struct hppa_unw_table_entry * tep;
- Elf_Internal_Shdr * relsec;
- Elf_Internal_Rela * rela;
- Elf_Internal_Rela * rp;
- unsigned char * table;
- unsigned char * tp;
- Elf_Internal_Sym * sym;
- const char * relname;
-
- /* First, find the starting address of the segment that includes
- this section. */
- if (filedata->file_header.e_phnum)
- {
- if (! get_program_headers (filedata))
- return false;
-
- for (seg = filedata->program_headers;
- seg < filedata->program_headers + filedata->file_header.e_phnum;
- ++seg)
- {
- if (seg->p_type != PT_LOAD)
- continue;
-
- if (sec->sh_addr >= seg->p_vaddr
- && (sec->sh_addr + sec->sh_size <= seg->p_vaddr + seg->p_memsz))
- {
- aux->seg_base = seg->p_vaddr;
- break;
- }
- }
- }
-
- /* Second, build the unwind table from the contents of the unwind
- section. */
- size = sec->sh_size;
- table = (unsigned char *) get_data (NULL, filedata, sec->sh_offset, 1, size,
- _("unwind table"));
- if (!table)
- return false;
-
- unw_ent_size = 16;
- nentries = size / unw_ent_size;
- size = unw_ent_size * nentries;
-
- aux->table_len = nentries;
- tep = aux->table = (struct hppa_unw_table_entry *)
- xcmalloc (nentries, sizeof (aux->table[0]));
-
- for (tp = table; tp < table + size; tp += unw_ent_size, ++tep)
- {
- unsigned int tmp1, tmp2;
-
- tep->start.section = SHN_UNDEF;
- tep->end.section = SHN_UNDEF;
-
- tep->start.offset = byte_get ((unsigned char *) tp + 0, 4);
- tep->end.offset = byte_get ((unsigned char *) tp + 4, 4);
- tmp1 = byte_get ((unsigned char *) tp + 8, 4);
- tmp2 = byte_get ((unsigned char *) tp + 12, 4);
-
- tep->start.offset += aux->seg_base;
- tep->end.offset += aux->seg_base;
-
- tep->Cannot_unwind = (tmp1 >> 31) & 0x1;
- tep->Millicode = (tmp1 >> 30) & 0x1;
- tep->Millicode_save_sr0 = (tmp1 >> 29) & 0x1;
- tep->Region_description = (tmp1 >> 27) & 0x3;
- tep->reserved1 = (tmp1 >> 26) & 0x1;
- tep->Entry_SR = (tmp1 >> 25) & 0x1;
- tep->Entry_FR = (tmp1 >> 21) & 0xf;
- tep->Entry_GR = (tmp1 >> 16) & 0x1f;
- tep->Args_stored = (tmp1 >> 15) & 0x1;
- tep->Variable_Frame = (tmp1 >> 14) & 0x1;
- tep->Separate_Package_Body = (tmp1 >> 13) & 0x1;
- tep->Frame_Extension_Millicode = (tmp1 >> 12) & 0x1;
- tep->Stack_Overflow_Check = (tmp1 >> 11) & 0x1;
- tep->Two_Instruction_SP_Increment = (tmp1 >> 10) & 0x1;
- tep->Ada_Region = (tmp1 >> 9) & 0x1;
- tep->cxx_info = (tmp1 >> 8) & 0x1;
- tep->cxx_try_catch = (tmp1 >> 7) & 0x1;
- tep->sched_entry_seq = (tmp1 >> 6) & 0x1;
- tep->reserved2 = (tmp1 >> 5) & 0x1;
- tep->Save_SP = (tmp1 >> 4) & 0x1;
- tep->Save_RP = (tmp1 >> 3) & 0x1;
- tep->Save_MRP_in_frame = (tmp1 >> 2) & 0x1;
- tep->extn_ptr_defined = (tmp1 >> 1) & 0x1;
- tep->Cleanup_defined = tmp1 & 0x1;
-
- tep->MPE_XL_interrupt_marker = (tmp2 >> 31) & 0x1;
- tep->HP_UX_interrupt_marker = (tmp2 >> 30) & 0x1;
- tep->Large_frame = (tmp2 >> 29) & 0x1;
- tep->Pseudo_SP_Set = (tmp2 >> 28) & 0x1;
- tep->reserved4 = (tmp2 >> 27) & 0x1;
- tep->Total_frame_size = tmp2 & 0x7ffffff;
- }
- free (table);
-
- /* Third, apply any relocations to the unwind table. */
- for (relsec = filedata->section_headers;
- relsec < filedata->section_headers + filedata->file_header.e_shnum;
- ++relsec)
- {
- if (relsec->sh_type != SHT_RELA
- || relsec->sh_info >= filedata->file_header.e_shnum
- || filedata->section_headers + relsec->sh_info != sec)
- continue;
-
- if (!slurp_rela_relocs (filedata, relsec->sh_offset, relsec->sh_size,
- & rela, & nrelas))
- return false;
-
- for (rp = rela; rp < rela + nrelas; ++rp)
- {
- unsigned int sym_ndx;
- unsigned int r_type = get_reloc_type (filedata, rp->r_info);
- relname = elf_hppa_reloc_type (r_type);
-
- if (relname == NULL)
- {
- warn (_("Skipping unknown relocation type: %u\n"), r_type);
- continue;
- }
-
- /* R_PARISC_SEGREL32 or R_PARISC_SEGREL64. */
- if (! startswith (relname, "R_PARISC_SEGREL"))
- {
- warn (_("Skipping unexpected relocation type: %s\n"), relname);
- continue;
- }
-
- i = rp->r_offset / unw_ent_size;
- if (i >= aux->table_len)
- {
- warn (_("Skipping reloc with overlarge offset: %#" PRIx64 "\n"),
- i);
- continue;
- }
-
- sym_ndx = get_reloc_symindex (rp->r_info);
- if (sym_ndx >= aux->nsyms)
- {
- warn (_("Skipping reloc with invalid symbol index: %u\n"),
- sym_ndx);
- continue;
- }
- sym = aux->symtab + sym_ndx;
-
- switch ((rp->r_offset % unw_ent_size) / 4)
- {
- case 0:
- aux->table[i].start.section = sym->st_shndx;
- aux->table[i].start.offset = sym->st_value + rp->r_addend;
- break;
- case 1:
- aux->table[i].end.section = sym->st_shndx;
- aux->table[i].end.offset = sym->st_value + rp->r_addend;
- break;
- default:
- break;
- }
- }
-
- free (rela);
- }
-
- return true;
-}
-
-static bool
-hppa_process_unwind (Filedata * filedata)
-{
- struct hppa_unw_aux_info aux;
- Elf_Internal_Shdr * unwsec = NULL;
- Elf_Internal_Shdr * sec;
- size_t i;
- bool res = true;
-
- if (filedata->string_table == NULL)
- return false;
-
- memset (& aux, 0, sizeof (aux));
-
- for (i = 0, sec = filedata->section_headers; i < filedata->file_header.e_shnum; ++i, ++sec)
- {
- if (sec->sh_type == SHT_SYMTAB)
- {
- if (aux.symtab)
- {
- error (_("Multiple symbol tables encountered\n"));
- free (aux.symtab);
- aux.symtab = NULL;
- free (aux.strtab);
- aux.strtab = NULL;
- }
- if (!get_symtab (filedata, sec, &aux.symtab, &aux.nsyms,
- &aux.strtab, &aux.strtab_size))
- return false;
- }
- else if (section_name_valid (filedata, sec)
- && streq (section_name (filedata, sec), ".PARISC.unwind"))
- unwsec = sec;
- }
-
- if (!unwsec)
- printf (_("\nThere are no unwind sections in this file.\n"));
-
- for (i = 0, sec = filedata->section_headers; i < filedata->file_header.e_shnum; ++i, ++sec)
- {
- if (section_name_valid (filedata, sec)
- && streq (section_name (filedata, sec), ".PARISC.unwind"))
- {
- uint64_t num_unwind = sec->sh_size / 16;
-
- printf (ngettext ("\nUnwind section '%s' at offset %#" PRIx64 " "
- "contains %" PRIu64 " entry:\n",
- "\nUnwind section '%s' at offset %#" PRIx64 " "
- "contains %" PRIu64 " entries:\n",
- num_unwind),
- printable_section_name (filedata, sec),
- sec->sh_offset,
- num_unwind);
-
- if (! slurp_hppa_unwind_table (filedata, &aux, sec))
- res = false;
-
- if (res && aux.table_len > 0)
- {
- if (! dump_hppa_unwind (filedata, &aux))
- res = false;
- }
-
- free ((char *) aux.table);
- aux.table = NULL;
- }
- }
-
- free (aux.symtab);
- free ((char *) aux.strtab);
-
- return res;
-}
-
-struct arm_section
-{
- unsigned char * data; /* The unwind data. */
- Elf_Internal_Shdr * sec; /* The cached unwind section header. */
- Elf_Internal_Rela * rela; /* The cached relocations for this section. */
- uint64_t nrelas; /* The number of relocations. */
- unsigned int rel_type; /* REL or RELA ? */
- Elf_Internal_Rela * next_rela; /* Cyclic pointer to the next reloc to process. */
-};
-
-struct arm_unw_aux_info
-{
- Filedata * filedata; /* The file containing the unwind sections. */
- Elf_Internal_Sym * symtab; /* The file's symbol table. */
- uint64_t nsyms; /* Number of symbols. */
- Elf_Internal_Sym * funtab; /* Sorted table of STT_FUNC symbols. */
- uint64_t nfuns; /* Number of these symbols. */
- char * strtab; /* The file's string table. */
- uint64_t strtab_size; /* Size of string table. */
-};
-
-static const char *
-arm_print_vma_and_name (Filedata * filedata,
- struct arm_unw_aux_info * aux,
- uint64_t fn,
- struct absaddr addr)
-{
- const char *procname;
- uint64_t sym_offset;
-
- if (addr.section == SHN_UNDEF)
- addr.offset = fn;
-
- find_symbol_for_address (filedata, aux->funtab, aux->nfuns, aux->strtab,
- aux->strtab_size, addr, &procname,
- &sym_offset);
-
- print_vma (fn, PREFIX_HEX);
-
- if (procname)
- {
- fputs (" <", stdout);
- fputs (procname, stdout);
-
- if (sym_offset)
- printf ("+0x%" PRIx64, sym_offset);
- fputc ('>', stdout);
- }
-
- return procname;
-}
-
-static void
-arm_free_section (struct arm_section *arm_sec)
-{
- free (arm_sec->data);
- free (arm_sec->rela);
-}
-
-/* 1) If SEC does not match the one cached in ARM_SEC, then free the current
- cached section and install SEC instead.
- 2) Locate the 32-bit word at WORD_OFFSET in unwind section SEC
- and return its valued in * WORDP, relocating if necessary.
- 3) Update the NEXT_RELA field in ARM_SEC and store the section index and
- relocation's offset in ADDR.
- 4) If SYM_NAME is non-NULL and a relocation was applied, record the offset
- into the string table of the symbol associated with the reloc. If no
- reloc was applied store -1 there.
- 5) Return TRUE upon success, FALSE otherwise. */
-
-static bool
-get_unwind_section_word (Filedata * filedata,
- struct arm_unw_aux_info * aux,
- struct arm_section * arm_sec,
- Elf_Internal_Shdr * sec,
- uint64_t word_offset,
- unsigned int * wordp,
- struct absaddr * addr,
- uint64_t * sym_name)
-{
- Elf_Internal_Rela *rp;
- Elf_Internal_Sym *sym;
- const char * relname;
- unsigned int word;
- bool wrapped;
-
- if (sec == NULL || arm_sec == NULL)
- return false;
-
- addr->section = SHN_UNDEF;
- addr->offset = 0;
-
- if (sym_name != NULL)
- *sym_name = (uint64_t) -1;
-
- /* If necessary, update the section cache. */
- if (sec != arm_sec->sec)
- {
- Elf_Internal_Shdr *relsec;
-
- arm_free_section (arm_sec);
-
- arm_sec->sec = sec;
- arm_sec->data = get_data (NULL, aux->filedata, sec->sh_offset, 1,
- sec->sh_size, _("unwind data"));
- arm_sec->rela = NULL;
- arm_sec->nrelas = 0;
-
- for (relsec = filedata->section_headers;
- relsec < filedata->section_headers + filedata->file_header.e_shnum;
- ++relsec)
- {
- if (relsec->sh_info >= filedata->file_header.e_shnum
- || filedata->section_headers + relsec->sh_info != sec
- /* PR 15745: Check the section type as well. */
- || (relsec->sh_type != SHT_REL
- && relsec->sh_type != SHT_RELA))
- continue;
-
- arm_sec->rel_type = relsec->sh_type;
- if (relsec->sh_type == SHT_REL)
- {
- if (!slurp_rel_relocs (aux->filedata, relsec->sh_offset,
- relsec->sh_size,
- & arm_sec->rela, & arm_sec->nrelas))
- return false;
- }
- else /* relsec->sh_type == SHT_RELA */
- {
- if (!slurp_rela_relocs (aux->filedata, relsec->sh_offset,
- relsec->sh_size,
- & arm_sec->rela, & arm_sec->nrelas))
- return false;
- }
- break;
- }
-
- arm_sec->next_rela = arm_sec->rela;
- }
-
- /* If there is no unwind data we can do nothing. */
- if (arm_sec->data == NULL)
- return false;
-
- /* If the offset is invalid then fail. */
- if (/* PR 21343 *//* PR 18879 */
- sec->sh_size < 4
- || word_offset > sec->sh_size - 4)
- return false;
-
- /* Get the word at the required offset. */
- word = byte_get (arm_sec->data + word_offset, 4);
-
- /* PR 17531: file: id:000001,src:001266+003044,op:splice,rep:128. */
- if (arm_sec->rela == NULL)
- {
- * wordp = word;
- return true;
- }
-
- /* Look through the relocs to find the one that applies to the provided offset. */
- wrapped = false;
- for (rp = arm_sec->next_rela; rp != arm_sec->rela + arm_sec->nrelas; rp++)
- {
- uint64_t prelval, offset;
-
- if (rp->r_offset > word_offset && !wrapped)
- {
- rp = arm_sec->rela;
- wrapped = true;
- }
- if (rp->r_offset > word_offset)
- break;
-
- if (rp->r_offset & 3)
- {
- warn (_("Skipping unexpected relocation at offset %#" PRIx64 "\n"),
- rp->r_offset);
- continue;
- }
-
- if (rp->r_offset < word_offset)
- continue;
-
- /* PR 17531: file: 027-161405-0.004 */
- if (aux->symtab == NULL)
- continue;
-
- if (arm_sec->rel_type == SHT_REL)
- {
- offset = word & 0x7fffffff;
- if (offset & 0x40000000)
- offset |= ~ (uint64_t) 0x7fffffff;
- }
- else if (arm_sec->rel_type == SHT_RELA)
- offset = rp->r_addend;
- else
- {
- error (_("Unknown section relocation type %d encountered\n"),
- arm_sec->rel_type);
- break;
- }
-
- /* PR 17531 file: 027-1241568-0.004. */
- if (ELF32_R_SYM (rp->r_info) >= aux->nsyms)
- {
- error (_("Bad symbol index in unwind relocation "
- "(%" PRIu64 " > %" PRIu64 ")\n"),
- ELF32_R_SYM (rp->r_info), aux->nsyms);
- break;
- }
-
- sym = aux->symtab + ELF32_R_SYM (rp->r_info);
- offset += sym->st_value;
- prelval = offset - (arm_sec->sec->sh_addr + rp->r_offset);
-
- /* Check that we are processing the expected reloc type. */
- if (filedata->file_header.e_machine == EM_ARM)
- {
- relname = elf_arm_reloc_type (ELF32_R_TYPE (rp->r_info));
- if (relname == NULL)
- {
- warn (_("Skipping unknown ARM relocation type: %d\n"),
- (int) ELF32_R_TYPE (rp->r_info));
- continue;
- }
-
- if (streq (relname, "R_ARM_NONE"))
- continue;
-
- if (! streq (relname, "R_ARM_PREL31"))
- {
- warn (_("Skipping unexpected ARM relocation type %s\n"), relname);
- continue;
- }
- }
- else if (filedata->file_header.e_machine == EM_TI_C6000)
- {
- relname = elf_tic6x_reloc_type (ELF32_R_TYPE (rp->r_info));
- if (relname == NULL)
- {
- warn (_("Skipping unknown C6000 relocation type: %d\n"),
- (int) ELF32_R_TYPE (rp->r_info));
- continue;
- }
-
- if (streq (relname, "R_C6000_NONE"))
- continue;
-
- if (! streq (relname, "R_C6000_PREL31"))
- {
- warn (_("Skipping unexpected C6000 relocation type %s\n"), relname);
- continue;
- }
-
- prelval >>= 1;
- }
- else
- {
- /* This function currently only supports ARM and TI unwinders. */
- warn (_("Only TI and ARM unwinders are currently supported\n"));
- break;
- }
-
- word = (word & ~ (uint64_t) 0x7fffffff) | (prelval & 0x7fffffff);
- addr->section = sym->st_shndx;
- addr->offset = offset;
-
- if (sym_name)
- * sym_name = sym->st_name;
- break;
- }
-
- *wordp = word;
- arm_sec->next_rela = rp;
-
- return true;
-}
-
-static const char *tic6x_unwind_regnames[16] =
-{
- "A15", "B15", "B14", "B13", "B12", "B11", "B10", "B3",
- "A14", "A13", "A12", "A11", "A10",
- "[invalid reg 13]", "[invalid reg 14]", "[invalid reg 15]"
-};
-
-static void
-decode_tic6x_unwind_regmask (unsigned int mask)
-{
- int i;
-
- for (i = 12; mask; mask >>= 1, i--)
- {
- if (mask & 1)
- {
- fputs (tic6x_unwind_regnames[i], stdout);
- if (mask > 1)
- fputs (", ", stdout);
- }
- }
-}
-
-#define ADVANCE \
- if (remaining == 0 && more_words) \
- { \
- data_offset += 4; \
- if (! get_unwind_section_word (filedata, aux, data_arm_sec, data_sec, \
- data_offset, & word, & addr, NULL)) \
- return false; \
- remaining = 4; \
- more_words--; \
- } \
-
-#define GET_OP(OP) \
- ADVANCE; \
- if (remaining) \
- { \
- remaining--; \
- (OP) = word >> 24; \
- word <<= 8; \
- } \
- else \
- { \
- printf (_("[Truncated opcode]\n")); \
- return false; \
- } \
- printf ("0x%02x ", OP)
-
-static bool
-decode_arm_unwind_bytecode (Filedata * filedata,
- struct arm_unw_aux_info * aux,
- unsigned int word,
- unsigned int remaining,
- unsigned int more_words,
- uint64_t data_offset,
- Elf_Internal_Shdr * data_sec,
- struct arm_section * data_arm_sec)
-{
- struct absaddr addr;
- bool res = true;
-
- /* Decode the unwinding instructions. */
- while (1)
- {
- unsigned int op, op2;
-
- ADVANCE;
- if (remaining == 0)
- break;
- remaining--;
- op = word >> 24;
- word <<= 8;
-
- printf (" 0x%02x ", op);
-
- if ((op & 0xc0) == 0x00)
- {
- int offset = ((op & 0x3f) << 2) + 4;
-
- printf (" vsp = vsp + %d", offset);
- }
- else if ((op & 0xc0) == 0x40)
- {
- int offset = ((op & 0x3f) << 2) + 4;
-
- printf (" vsp = vsp - %d", offset);
- }
- else if ((op & 0xf0) == 0x80)
- {
- GET_OP (op2);
- if (op == 0x80 && op2 == 0)
- printf (_("Refuse to unwind"));
- else
- {
- unsigned int mask = ((op & 0x0f) << 8) | op2;
- bool first = true;
- int i;
-
- printf ("pop {");
- for (i = 0; i < 12; i++)
- if (mask & (1 << i))
- {
- if (first)
- first = false;
- else
- printf (", ");
- printf ("r%d", 4 + i);
- }
- printf ("}");
- }
- }
- else if ((op & 0xf0) == 0x90)
- {
- if (op == 0x9d || op == 0x9f)
- printf (_(" [Reserved]"));
- else
- printf (" vsp = r%d", op & 0x0f);
- }
- else if ((op & 0xf0) == 0xa0)
- {
- int end = 4 + (op & 0x07);
- bool first = true;
- int i;
-
- printf (" pop {");
- for (i = 4; i <= end; i++)
- {
- if (first)
- first = false;
- else
- printf (", ");
- printf ("r%d", i);
- }
- if (op & 0x08)
- {
- if (!first)
- printf (", ");
- printf ("r14");
- }
- printf ("}");
- }
- else if (op == 0xb0)
- printf (_(" finish"));
- else if (op == 0xb1)
- {
- GET_OP (op2);
- if (op2 == 0 || (op2 & 0xf0) != 0)
- printf (_("[Spare]"));
- else
- {
- unsigned int mask = op2 & 0x0f;
- bool first = true;
- int i;
-
- printf ("pop {");
- for (i = 0; i < 12; i++)
- if (mask & (1 << i))
- {
- if (first)
- first = false;
- else
- printf (", ");
- printf ("r%d", i);
- }
- printf ("}");
- }
- }
- else if (op == 0xb2)
- {
- unsigned char buf[9];
- unsigned int i, len;
- uint64_t offset;
-
- for (i = 0; i < sizeof (buf); i++)
- {
- GET_OP (buf[i]);
- if ((buf[i] & 0x80) == 0)
- break;
- }
- if (i == sizeof (buf))
- {
- error (_("corrupt change to vsp\n"));
- res = false;
- }
- else
- {
- offset = read_leb128 (buf, buf + i + 1, false, &len, NULL);
- assert (len == i + 1);
- offset = offset * 4 + 0x204;
- printf ("vsp = vsp + %" PRId64, offset);
- }
- }
- else if (op == 0xb3 || op == 0xc8 || op == 0xc9)
- {
- unsigned int first, last;
-
- GET_OP (op2);
- first = op2 >> 4;
- last = op2 & 0x0f;
- if (op == 0xc8)
- first = first + 16;
- printf ("pop {D%d", first);
- if (last)
- printf ("-D%d", first + last);
- printf ("}");
- }
- else if (op == 0xb4)
- printf (_(" pop {ra_auth_code}"));
- else if (op == 0xb5)
- printf (_(" vsp as modifier for PAC validation"));
- else if ((op & 0xf8) == 0xb8 || (op & 0xf8) == 0xd0)
- {
- unsigned int count = op & 0x07;
-
- printf ("pop {D8");
- if (count)
- printf ("-D%d", 8 + count);
- printf ("}");
- }
- else if (op >= 0xc0 && op <= 0xc5)
- {
- unsigned int count = op & 0x07;
-
- printf (" pop {wR10");
- if (count)
- printf ("-wR%d", 10 + count);
- printf ("}");
- }
- else if (op == 0xc6)
- {
- unsigned int first, last;
-
- GET_OP (op2);
- first = op2 >> 4;
- last = op2 & 0x0f;
- printf ("pop {wR%d", first);
- if (last)
- printf ("-wR%d", first + last);
- printf ("}");
- }
- else if (op == 0xc7)
- {
- GET_OP (op2);
- if (op2 == 0 || (op2 & 0xf0) != 0)
- printf (_("[Spare]"));
- else
- {
- unsigned int mask = op2 & 0x0f;
- bool first = true;
- int i;
-
- printf ("pop {");
- for (i = 0; i < 4; i++)
- if (mask & (1 << i))
- {
- if (first)
- first = false;
- else
- printf (", ");
- printf ("wCGR%d", i);
- }
- printf ("}");
- }
- }
- else
- {
- printf (_(" [unsupported opcode]"));
- res = false;
- }
-
- printf ("\n");
- }
-
- return res;
-}
-
-static bool
-decode_tic6x_unwind_bytecode (Filedata * filedata,
- struct arm_unw_aux_info * aux,
- unsigned int word,
- unsigned int remaining,
- unsigned int more_words,
- uint64_t data_offset,
- Elf_Internal_Shdr * data_sec,
- struct arm_section * data_arm_sec)
-{
- struct absaddr addr;
-
- /* Decode the unwinding instructions. */
- while (1)
- {
- unsigned int op, op2;
-
- ADVANCE;
- if (remaining == 0)
- break;
- remaining--;
- op = word >> 24;
- word <<= 8;
-
- printf (" 0x%02x ", op);
-
- if ((op & 0xc0) == 0x00)
- {
- int offset = ((op & 0x3f) << 3) + 8;
- printf (" sp = sp + %d", offset);
- }
- else if ((op & 0xc0) == 0x80)
- {
- GET_OP (op2);
- if (op == 0x80 && op2 == 0)
- printf (_("Refuse to unwind"));
- else
- {
- unsigned int mask = ((op & 0x1f) << 8) | op2;
- if (op & 0x20)
- printf ("pop compact {");
- else
- printf ("pop {");
-
- decode_tic6x_unwind_regmask (mask);
- printf("}");
- }
- }
- else if ((op & 0xf0) == 0xc0)
- {
- unsigned int reg;
- unsigned int nregs;
- unsigned int i;
- const char *name;
- struct
- {
- unsigned int offset;
- unsigned int reg;
- } regpos[16];
-
- /* Scan entire instruction first so that GET_OP output is not
- interleaved with disassembly. */
- nregs = 0;
- for (i = 0; nregs < (op & 0xf); i++)
- {
- GET_OP (op2);
- reg = op2 >> 4;
- if (reg != 0xf)
- {
- regpos[nregs].offset = i * 2;
- regpos[nregs].reg = reg;
- nregs++;
- }
-
- reg = op2 & 0xf;
- if (reg != 0xf)
- {
- regpos[nregs].offset = i * 2 + 1;
- regpos[nregs].reg = reg;
- nregs++;
- }
- }
-
- printf (_("pop frame {"));
- if (nregs == 0)
- {
- printf (_("*corrupt* - no registers specified"));
- }
- else
- {
- reg = nregs - 1;
- for (i = i * 2; i > 0; i--)
- {
- if (regpos[reg].offset == i - 1)
- {
- name = tic6x_unwind_regnames[regpos[reg].reg];
- if (reg > 0)
- reg--;
- }
- else
- name = _("[pad]");
-
- fputs (name, stdout);
- if (i > 1)
- printf (", ");
- }
- }
-
- printf ("}");
- }
- else if (op == 0xd0)
- printf (" MOV FP, SP");
- else if (op == 0xd1)
- printf (" __c6xabi_pop_rts");
- else if (op == 0xd2)
- {
- unsigned char buf[9];
- unsigned int i, len;
- uint64_t offset;
-
- for (i = 0; i < sizeof (buf); i++)
- {
- GET_OP (buf[i]);
- if ((buf[i] & 0x80) == 0)
- break;
- }
- /* PR 17531: file: id:000001,src:001906+004739,op:splice,rep:2. */
- if (i == sizeof (buf))
- {
- warn (_("Corrupt stack pointer adjustment detected\n"));
- return false;
- }
-
- offset = read_leb128 (buf, buf + i + 1, false, &len, NULL);
- assert (len == i + 1);
- offset = offset * 8 + 0x408;
- printf (_("sp = sp + %" PRId64), offset);
- }
- else if ((op & 0xf0) == 0xe0)
- {
- if ((op & 0x0f) == 7)
- printf (" RETURN");
- else
- printf (" MV %s, B3", tic6x_unwind_regnames[op & 0x0f]);
- }
- else
- {
- printf (_(" [unsupported opcode]"));
- }
- putchar ('\n');
- }
-
- return true;
-}
-
-static uint64_t
-arm_expand_prel31 (Filedata * filedata, uint64_t word, uint64_t where)
-{
- uint64_t offset;
-
- offset = word & 0x7fffffff;
- if (offset & 0x40000000)
- offset |= ~ (uint64_t) 0x7fffffff;
-
- if (filedata->file_header.e_machine == EM_TI_C6000)
- offset <<= 1;
-
- return offset + where;
-}
-
-static bool
-decode_arm_unwind (Filedata * filedata,
- struct arm_unw_aux_info * aux,
- unsigned int word,
- unsigned int remaining,
- uint64_t data_offset,
- Elf_Internal_Shdr * data_sec,
- struct arm_section * data_arm_sec)
-{
- int per_index;
- unsigned int more_words = 0;
- struct absaddr addr;
- uint64_t sym_name = (uint64_t) -1;
- bool res = true;
-
- if (remaining == 0)
- {
- /* Fetch the first word.
- Note - when decoding an object file the address extracted
- here will always be 0. So we also pass in the sym_name
- parameter so that we can find the symbol associated with
- the personality routine. */
- if (! get_unwind_section_word (filedata, aux, data_arm_sec, data_sec, data_offset,
- & word, & addr, & sym_name))
- return false;
-
- remaining = 4;
- }
- else
- {
- addr.section = SHN_UNDEF;
- addr.offset = 0;
- }
-
- if ((word & 0x80000000) == 0)
- {
- /* Expand prel31 for personality routine. */
- uint64_t fn;
- const char *procname;
-
- fn = arm_expand_prel31 (filedata, word, data_sec->sh_addr + data_offset);
- printf (_(" Personality routine: "));
- if (fn == 0
- && addr.section == SHN_UNDEF && addr.offset == 0
- && sym_name != (uint64_t) -1 && sym_name < aux->strtab_size)
- {
- procname = aux->strtab + sym_name;
- print_vma (fn, PREFIX_HEX);
- if (procname)
- {
- fputs (" <", stdout);
- fputs (procname, stdout);
- fputc ('>', stdout);
- }
- }
- else
- procname = arm_print_vma_and_name (filedata, aux, fn, addr);
- fputc ('\n', stdout);
-
- /* The GCC personality routines use the standard compact
- encoding, starting with one byte giving the number of
- words. */
- if (procname != NULL
- && (startswith (procname, "__gcc_personality_v0")
- || startswith (procname, "__gxx_personality_v0")
- || startswith (procname, "__gcj_personality_v0")
- || startswith (procname, "__gnu_objc_personality_v0")))
- {
- remaining = 0;
- more_words = 1;
- ADVANCE;
- if (!remaining)
- {
- printf (_(" [Truncated data]\n"));
- return false;
- }
- more_words = word >> 24;
- word <<= 8;
- remaining--;
- per_index = -1;
- }
- else
- return true;
- }
- else
- {
- /* ARM EHABI Section 6.3:
-
- An exception-handling table entry for the compact model looks like:
-
- 31 30-28 27-24 23-0
- -- ----- ----- ----
- 1 0 index Data for personalityRoutine[index] */
-
- if (filedata->file_header.e_machine == EM_ARM
- && (word & 0x70000000))
- {
- warn (_("Corrupt ARM compact model table entry: %x \n"), word);
- res = false;
- }
-
- per_index = (word >> 24) & 0x7f;
- printf (_(" Compact model index: %d\n"), per_index);
- if (per_index == 0)
- {
- more_words = 0;
- word <<= 8;
- remaining--;
- }
- else if (per_index < 3)
- {
- more_words = (word >> 16) & 0xff;
- word <<= 16;
- remaining -= 2;
- }
- }
-
- switch (filedata->file_header.e_machine)
- {
- case EM_ARM:
- if (per_index < 3)
- {
- if (! decode_arm_unwind_bytecode (filedata, aux, word, remaining, more_words,
- data_offset, data_sec, data_arm_sec))
- res = false;
- }
- else
- {
- warn (_("Unknown ARM compact model index encountered\n"));
- printf (_(" [reserved]\n"));
- res = false;
- }
- break;
-
- case EM_TI_C6000:
- if (per_index < 3)
- {
- if (! decode_tic6x_unwind_bytecode (filedata, aux, word, remaining, more_words,
- data_offset, data_sec, data_arm_sec))
- res = false;
- }
- else if (per_index < 5)
- {
- if (((word >> 17) & 0x7f) == 0x7f)
- printf (_(" Restore stack from frame pointer\n"));
- else
- printf (_(" Stack increment %d\n"), (word >> 14) & 0x1fc);
- printf (_(" Registers restored: "));
- if (per_index == 4)
- printf (" (compact) ");
- decode_tic6x_unwind_regmask ((word >> 4) & 0x1fff);
- putchar ('\n');
- printf (_(" Return register: %s\n"),
- tic6x_unwind_regnames[word & 0xf]);
- }
- else
- printf (_(" [reserved (%d)]\n"), per_index);
- break;
-
- default:
- error (_("Unsupported architecture type %d encountered when decoding unwind table\n"),
- filedata->file_header.e_machine);
- res = false;
- }
-
- /* Decode the descriptors. Not implemented. */
-
- return res;
-}
-
-static bool
-dump_arm_unwind (Filedata * filedata,
- struct arm_unw_aux_info * aux,
- Elf_Internal_Shdr * exidx_sec)
-{
- struct arm_section exidx_arm_sec, extab_arm_sec;
- unsigned int i, exidx_len;
- uint64_t j, nfuns;
- bool res = true;
-
- memset (&exidx_arm_sec, 0, sizeof (exidx_arm_sec));
- memset (&extab_arm_sec, 0, sizeof (extab_arm_sec));
- exidx_len = exidx_sec->sh_size / 8;
-
- aux->funtab = xmalloc (aux->nsyms * sizeof (Elf_Internal_Sym));
- for (nfuns = 0, j = 0; j < aux->nsyms; j++)
- if (aux->symtab[j].st_value && ELF_ST_TYPE (aux->symtab[j].st_info) == STT_FUNC)
- aux->funtab[nfuns++] = aux->symtab[j];
- aux->nfuns = nfuns;
- qsort (aux->funtab, aux->nfuns, sizeof (Elf_Internal_Sym), symcmp);
-
- for (i = 0; i < exidx_len; i++)
- {
- unsigned int exidx_fn, exidx_entry;
- struct absaddr fn_addr, entry_addr;
- uint64_t fn;
-
- fputc ('\n', stdout);
-
- if (! get_unwind_section_word (filedata, aux, & exidx_arm_sec, exidx_sec,
- 8 * i, & exidx_fn, & fn_addr, NULL)
- || ! get_unwind_section_word (filedata, aux, & exidx_arm_sec, exidx_sec,
- 8 * i + 4, & exidx_entry, & entry_addr, NULL))
- {
- free (aux->funtab);
- arm_free_section (& exidx_arm_sec);
- arm_free_section (& extab_arm_sec);
- return false;
- }
-
- /* ARM EHABI, Section 5:
- An index table entry consists of 2 words.
- The first word contains a prel31 offset to the start of a function, with bit 31 clear. */
- if (exidx_fn & 0x80000000)
- {
- warn (_("corrupt index table entry: %x\n"), exidx_fn);
- res = false;
- }
-
- fn = arm_expand_prel31 (filedata, exidx_fn, exidx_sec->sh_addr + 8 * i);
-
- arm_print_vma_and_name (filedata, aux, fn, fn_addr);
- fputs (": ", stdout);
-
- if (exidx_entry == 1)
- {
- print_vma (exidx_entry, PREFIX_HEX);
- fputs (" [cantunwind]\n", stdout);
- }
- else if (exidx_entry & 0x80000000)
- {
- print_vma (exidx_entry, PREFIX_HEX);
- fputc ('\n', stdout);
- decode_arm_unwind (filedata, aux, exidx_entry, 4, 0, NULL, NULL);
- }
- else
- {
- uint64_t table, table_offset = 0;
- Elf_Internal_Shdr *table_sec;
-
- fputs ("@", stdout);
- table = arm_expand_prel31 (filedata, exidx_entry, exidx_sec->sh_addr + 8 * i + 4);
- print_vma (table, PREFIX_HEX);
- printf ("\n");
-
- /* Locate the matching .ARM.extab. */
- if (entry_addr.section != SHN_UNDEF
- && entry_addr.section < filedata->file_header.e_shnum)
- {
- table_sec = filedata->section_headers + entry_addr.section;
- table_offset = entry_addr.offset;
- /* PR 18879 */
- if (table_offset > table_sec->sh_size)
- {
- warn (_("Unwind entry contains corrupt offset (%#" PRIx64 ") into section %s\n"),
- table_offset,
- printable_section_name (filedata, table_sec));
- res = false;
- continue;
- }
- }
- else
- {
- table_sec = find_section_by_address (filedata, table);
- if (table_sec != NULL)
- table_offset = table - table_sec->sh_addr;
- }
-
- if (table_sec == NULL)
- {
- warn (_("Could not locate .ARM.extab section containing %#" PRIx64 ".\n"),
- table);
- res = false;
- continue;
- }
-
- if (! decode_arm_unwind (filedata, aux, 0, 0, table_offset, table_sec,
- &extab_arm_sec))
- res = false;
- }
- }
-
- printf ("\n");
-
- free (aux->funtab);
- arm_free_section (&exidx_arm_sec);
- arm_free_section (&extab_arm_sec);
-
- return res;
-}
-
-/* Used for both ARM and C6X unwinding tables. */
-
-static bool
-arm_process_unwind (Filedata * filedata)
-{
- struct arm_unw_aux_info aux;
- Elf_Internal_Shdr *unwsec = NULL;
- Elf_Internal_Shdr *sec;
- size_t i;
- unsigned int sec_type;
- bool res = true;
-
- switch (filedata->file_header.e_machine)
- {
- case EM_ARM:
- sec_type = SHT_ARM_EXIDX;
- break;
-
- case EM_TI_C6000:
- sec_type = SHT_C6000_UNWIND;
- break;
-
- default:
- error (_("Unsupported architecture type %d encountered when processing unwind table\n"),
- filedata->file_header.e_machine);
- return false;
- }
-
- if (filedata->string_table == NULL)
- return false;
-
- memset (& aux, 0, sizeof (aux));
- aux.filedata = filedata;
-
- for (i = 0, sec = filedata->section_headers; i < filedata->file_header.e_shnum; ++i, ++sec)
- {
- if (sec->sh_type == SHT_SYMTAB)
- {
- if (aux.symtab)
- {
- error (_("Multiple symbol tables encountered\n"));
- free (aux.symtab);
- aux.symtab = NULL;
- free (aux.strtab);
- aux.strtab = NULL;
- }
- if (!get_symtab (filedata, sec, &aux.symtab, &aux.nsyms,
- &aux.strtab, &aux.strtab_size))
- return false;
- }
- else if (sec->sh_type == sec_type)
- unwsec = sec;
- }
-
- if (unwsec == NULL)
- printf (_("\nThere are no unwind sections in this file.\n"));
- else
- for (i = 0, sec = filedata->section_headers; i < filedata->file_header.e_shnum; ++i, ++sec)
- {
- if (sec->sh_type == sec_type)
- {
- uint64_t num_unwind = sec->sh_size / (2 * eh_addr_size);
- printf (ngettext ("\nUnwind section '%s' at offset %#" PRIx64 " "
- "contains %" PRIu64 " entry:\n",
- "\nUnwind section '%s' at offset %#" PRIx64 " "
- "contains %" PRIu64 " entries:\n",
- num_unwind),
- printable_section_name (filedata, sec),
- sec->sh_offset,
- num_unwind);
-
- if (! dump_arm_unwind (filedata, &aux, sec))
- res = false;
- }
- }
-
- free (aux.symtab);
- free ((char *) aux.strtab);
-
- return res;
-}
-
-static bool
-no_processor_specific_unwind (Filedata * filedata ATTRIBUTE_UNUSED)
-{
- printf (_("No processor specific unwind information to decode\n"));
- return true;
-}
-
-static bool
-process_unwind (Filedata * filedata)
-{
- struct unwind_handler
- {
- unsigned int machtype;
- bool (* handler)(Filedata *);
- } handlers[] =
- {
- { EM_ARM, arm_process_unwind },
- { EM_IA_64, ia64_process_unwind },
- { EM_PARISC, hppa_process_unwind },
- { EM_TI_C6000, arm_process_unwind },
- { EM_386, no_processor_specific_unwind },
- { EM_X86_64, no_processor_specific_unwind },
- { 0, NULL }
- };
- int i;
-
- if (!do_unwind)
- return true;
-
- for (i = 0; handlers[i].handler != NULL; i++)
- if (filedata->file_header.e_machine == handlers[i].machtype)
- return handlers[i].handler (filedata);
-
- printf (_("\nThe decoding of unwind sections for machine type %s is not currently supported.\n"),
- get_machine_name (filedata->file_header.e_machine));
- return true;
-}
-
-static void
-dynamic_section_aarch64_val (Elf_Internal_Dyn * entry)
-{
- switch (entry->d_tag)
- {
- case DT_AARCH64_BTI_PLT:
- case DT_AARCH64_PAC_PLT:
- break;
- default:
- print_vma (entry->d_un.d_ptr, PREFIX_HEX);
- break;
- }
- putchar ('\n');
-}
-
-static void
-dynamic_section_mips_val (Filedata * filedata, Elf_Internal_Dyn * entry)
-{
- switch (entry->d_tag)
- {
- case DT_MIPS_FLAGS:
- if (entry->d_un.d_val == 0)
- printf (_("NONE"));
- else
- {
- static const char * opts[] =
- {
- "QUICKSTART", "NOTPOT", "NO_LIBRARY_REPLACEMENT",
- "NO_MOVE", "SGI_ONLY", "GUARANTEE_INIT", "DELTA_C_PLUS_PLUS",
- "GUARANTEE_START_INIT", "PIXIE", "DEFAULT_DELAY_LOAD",
- "REQUICKSTART", "REQUICKSTARTED", "CORD", "NO_UNRES_UNDEF",
- "RLD_ORDER_SAFE"
- };
- unsigned int cnt;
- bool first = true;
-
- for (cnt = 0; cnt < ARRAY_SIZE (opts); ++cnt)
- if (entry->d_un.d_val & (1 << cnt))
- {
- printf ("%s%s", first ? "" : " ", opts[cnt]);
- first = false;
- }
- }
- break;
-
- case DT_MIPS_IVERSION:
- if (valid_dynamic_name (filedata, entry->d_un.d_val))
- printf (_("Interface Version: %s"),
- get_dynamic_name (filedata, entry->d_un.d_val));
- else
- printf (_("Interface Version: <corrupt: %" PRIx64 ">"),
- entry->d_un.d_ptr);
- break;
-
- case DT_MIPS_TIME_STAMP:
- {
- char timebuf[128];
- struct tm * tmp;
- time_t atime = entry->d_un.d_val;
-
- tmp = gmtime (&atime);
- /* PR 17531: file: 6accc532. */
- if (tmp == NULL)
- snprintf (timebuf, sizeof (timebuf), _("<corrupt>"));
- else
- snprintf (timebuf, sizeof (timebuf), "%04u-%02u-%02uT%02u:%02u:%02u",
- tmp->tm_year + 1900, tmp->tm_mon + 1, tmp->tm_mday,
- tmp->tm_hour, tmp->tm_min, tmp->tm_sec);
- printf (_("Time Stamp: %s"), timebuf);
- }
- break;
-
- case DT_MIPS_RLD_VERSION:
- case DT_MIPS_LOCAL_GOTNO:
- case DT_MIPS_CONFLICTNO:
- case DT_MIPS_LIBLISTNO:
- case DT_MIPS_SYMTABNO:
- case DT_MIPS_UNREFEXTNO:
- case DT_MIPS_HIPAGENO:
- case DT_MIPS_DELTA_CLASS_NO:
- case DT_MIPS_DELTA_INSTANCE_NO:
- case DT_MIPS_DELTA_RELOC_NO:
- case DT_MIPS_DELTA_SYM_NO:
- case DT_MIPS_DELTA_CLASSSYM_NO:
- case DT_MIPS_COMPACT_SIZE:
- print_vma (entry->d_un.d_val, DEC);
- break;
-
- case DT_MIPS_XHASH:
- filedata->dynamic_info_DT_MIPS_XHASH = entry->d_un.d_val;
- filedata->dynamic_info_DT_GNU_HASH = entry->d_un.d_val;
- /* Falls through. */
-
- default:
- print_vma (entry->d_un.d_ptr, PREFIX_HEX);
- }
- putchar ('\n');
-}
-
-static void
-dynamic_section_parisc_val (Elf_Internal_Dyn * entry)
-{
- switch (entry->d_tag)
- {
- case DT_HP_DLD_FLAGS:
- {
- static struct
- {
- unsigned int bit;
- const char * str;
- }
- flags[] =
- {
- { DT_HP_DEBUG_PRIVATE, "HP_DEBUG_PRIVATE" },
- { DT_HP_DEBUG_CALLBACK, "HP_DEBUG_CALLBACK" },
- { DT_HP_DEBUG_CALLBACK_BOR, "HP_DEBUG_CALLBACK_BOR" },
- { DT_HP_NO_ENVVAR, "HP_NO_ENVVAR" },
- { DT_HP_BIND_NOW, "HP_BIND_NOW" },
- { DT_HP_BIND_NONFATAL, "HP_BIND_NONFATAL" },
- { DT_HP_BIND_VERBOSE, "HP_BIND_VERBOSE" },
- { DT_HP_BIND_RESTRICTED, "HP_BIND_RESTRICTED" },
- { DT_HP_BIND_SYMBOLIC, "HP_BIND_SYMBOLIC" },
- { DT_HP_RPATH_FIRST, "HP_RPATH_FIRST" },
- { DT_HP_BIND_DEPTH_FIRST, "HP_BIND_DEPTH_FIRST" },
- { DT_HP_GST, "HP_GST" },
- { DT_HP_SHLIB_FIXED, "HP_SHLIB_FIXED" },
- { DT_HP_MERGE_SHLIB_SEG, "HP_MERGE_SHLIB_SEG" },
- { DT_HP_NODELETE, "HP_NODELETE" },
- { DT_HP_GROUP, "HP_GROUP" },
- { DT_HP_PROTECT_LINKAGE_TABLE, "HP_PROTECT_LINKAGE_TABLE" }
- };
- bool first = true;
- size_t cnt;
- uint64_t val = entry->d_un.d_val;
-
- for (cnt = 0; cnt < ARRAY_SIZE (flags); ++cnt)
- if (val & flags[cnt].bit)
- {
- if (! first)
- putchar (' ');
- fputs (flags[cnt].str, stdout);
- first = false;
- val ^= flags[cnt].bit;
- }
-
- if (val != 0 || first)
- {
- if (! first)
- putchar (' ');
- print_vma (val, HEX);
- }
- }
- break;
-
- default:
- print_vma (entry->d_un.d_ptr, PREFIX_HEX);
- break;
- }
- putchar ('\n');
-}
-
-/* VMS vs Unix time offset and factor. */
-
-#define VMS_EPOCH_OFFSET 35067168000000000LL
-#define VMS_GRANULARITY_FACTOR 10000000
-#ifndef INT64_MIN
-#define INT64_MIN (-9223372036854775807LL - 1)
-#endif
-
-/* Display a VMS time in a human readable format. */
-
-static void
-print_vms_time (int64_t vmstime)
-{
- struct tm *tm = NULL;
- time_t unxtime;
-
- if (vmstime >= INT64_MIN + VMS_EPOCH_OFFSET)
- {
- vmstime = (vmstime - VMS_EPOCH_OFFSET) / VMS_GRANULARITY_FACTOR;
- unxtime = vmstime;
- if (unxtime == vmstime)
- tm = gmtime (&unxtime);
- }
- if (tm != NULL)
- printf ("%04u-%02u-%02uT%02u:%02u:%02u",
- tm->tm_year + 1900, tm->tm_mon + 1, tm->tm_mday,
- tm->tm_hour, tm->tm_min, tm->tm_sec);
-}
-
-static void
-dynamic_section_ia64_val (Elf_Internal_Dyn * entry)
-{
- switch (entry->d_tag)
- {
- case DT_IA_64_PLT_RESERVE:
- /* First 3 slots reserved. */
- print_vma (entry->d_un.d_ptr, PREFIX_HEX);
- printf (" -- ");
- print_vma (entry->d_un.d_ptr + (3 * 8), PREFIX_HEX);
- break;
-
- case DT_IA_64_VMS_LINKTIME:
- print_vms_time (entry->d_un.d_val);
- break;
-
- case DT_IA_64_VMS_LNKFLAGS:
- print_vma (entry->d_un.d_ptr, PREFIX_HEX);
- if (entry->d_un.d_val & VMS_LF_CALL_DEBUG)
- printf (" CALL_DEBUG");
- if (entry->d_un.d_val & VMS_LF_NOP0BUFS)
- printf (" NOP0BUFS");
- if (entry->d_un.d_val & VMS_LF_P0IMAGE)
- printf (" P0IMAGE");
- if (entry->d_un.d_val & VMS_LF_MKTHREADS)
- printf (" MKTHREADS");
- if (entry->d_un.d_val & VMS_LF_UPCALLS)
- printf (" UPCALLS");
- if (entry->d_un.d_val & VMS_LF_IMGSTA)
- printf (" IMGSTA");
- if (entry->d_un.d_val & VMS_LF_INITIALIZE)
- printf (" INITIALIZE");
- if (entry->d_un.d_val & VMS_LF_MAIN)
- printf (" MAIN");
- if (entry->d_un.d_val & VMS_LF_EXE_INIT)
- printf (" EXE_INIT");
- if (entry->d_un.d_val & VMS_LF_TBK_IN_IMG)
- printf (" TBK_IN_IMG");
- if (entry->d_un.d_val & VMS_LF_DBG_IN_IMG)
- printf (" DBG_IN_IMG");
- if (entry->d_un.d_val & VMS_LF_TBK_IN_DSF)
- printf (" TBK_IN_DSF");
- if (entry->d_un.d_val & VMS_LF_DBG_IN_DSF)
- printf (" DBG_IN_DSF");
- if (entry->d_un.d_val & VMS_LF_SIGNATURES)
- printf (" SIGNATURES");
- if (entry->d_un.d_val & VMS_LF_REL_SEG_OFF)
- printf (" REL_SEG_OFF");
- break;
-
- default:
- print_vma (entry->d_un.d_ptr, PREFIX_HEX);
- break;
- }
- putchar ('\n');
-}
-
-static bool
-get_32bit_dynamic_section (Filedata * filedata)
-{
- Elf32_External_Dyn * edyn;
- Elf32_External_Dyn * ext;
- Elf_Internal_Dyn * entry;
-
- edyn = (Elf32_External_Dyn *) get_data (NULL, filedata,
- filedata->dynamic_addr, 1,
- filedata->dynamic_size,
- _("dynamic section"));
- if (!edyn)
- return false;
-
- /* SGI's ELF has more than one section in the DYNAMIC segment, and we
- might not have the luxury of section headers. Look for the DT_NULL
- terminator to determine the number of entries. */
- for (ext = edyn, filedata->dynamic_nent = 0;
- (char *) (ext + 1) <= (char *) edyn + filedata->dynamic_size;
- ext++)
- {
- filedata->dynamic_nent++;
- if (BYTE_GET (ext->d_tag) == DT_NULL)
- break;
- }
-
- filedata->dynamic_section
- = (Elf_Internal_Dyn *) cmalloc (filedata->dynamic_nent, sizeof (* entry));
- if (filedata->dynamic_section == NULL)
- {
- error (_("Out of memory allocating space for %" PRIu64 " dynamic entries\n"),
- filedata->dynamic_nent);
- free (edyn);
- return false;
- }
-
- for (ext = edyn, entry = filedata->dynamic_section;
- entry < filedata->dynamic_section + filedata->dynamic_nent;
- ext++, entry++)
- {
- entry->d_tag = BYTE_GET (ext->d_tag);
- entry->d_un.d_val = BYTE_GET (ext->d_un.d_val);
- }
-
- free (edyn);
-
- return true;
-}
-
-static bool
-get_64bit_dynamic_section (Filedata * filedata)
-{
- Elf64_External_Dyn * edyn;
- Elf64_External_Dyn * ext;
- Elf_Internal_Dyn * entry;
-
- /* Read in the data. */
- edyn = (Elf64_External_Dyn *) get_data (NULL, filedata,
- filedata->dynamic_addr, 1,
- filedata->dynamic_size,
- _("dynamic section"));
- if (!edyn)
- return false;
-
- /* SGI's ELF has more than one section in the DYNAMIC segment, and we
- might not have the luxury of section headers. Look for the DT_NULL
- terminator to determine the number of entries. */
- for (ext = edyn, filedata->dynamic_nent = 0;
- /* PR 17533 file: 033-67080-0.004 - do not read past end of buffer. */
- (char *) (ext + 1) <= (char *) edyn + filedata->dynamic_size;
- ext++)
- {
- filedata->dynamic_nent++;
- if (BYTE_GET (ext->d_tag) == DT_NULL)
- break;
- }
-
- filedata->dynamic_section
- = (Elf_Internal_Dyn *) cmalloc (filedata->dynamic_nent, sizeof (* entry));
- if (filedata->dynamic_section == NULL)
- {
- error (_("Out of memory allocating space for %" PRIu64 " dynamic entries\n"),
- filedata->dynamic_nent);
- free (edyn);
- return false;
- }
-
- /* Convert from external to internal formats. */
- for (ext = edyn, entry = filedata->dynamic_section;
- entry < filedata->dynamic_section + filedata->dynamic_nent;
- ext++, entry++)
- {
- entry->d_tag = BYTE_GET (ext->d_tag);
- entry->d_un.d_val = BYTE_GET (ext->d_un.d_val);
- }
-
- free (edyn);
-
- return true;
-}
-
-static bool
-get_dynamic_section (Filedata *filedata)
-{
- if (filedata->dynamic_section)
- return true;
-
- if (is_32bit_elf)
- return get_32bit_dynamic_section (filedata);
- else
- return get_64bit_dynamic_section (filedata);
-}
-
-static void
-print_dynamic_flags (uint64_t flags)
-{
- bool first = true;
-
- while (flags)
- {
- uint64_t flag;
-
- flag = flags & - flags;
- flags &= ~ flag;
-
- if (first)
- first = false;
- else
- putc (' ', stdout);
-
- switch (flag)
- {
- case DF_ORIGIN: fputs ("ORIGIN", stdout); break;
- case DF_SYMBOLIC: fputs ("SYMBOLIC", stdout); break;
- case DF_TEXTREL: fputs ("TEXTREL", stdout); break;
- case DF_BIND_NOW: fputs ("BIND_NOW", stdout); break;
- case DF_STATIC_TLS: fputs ("STATIC_TLS", stdout); break;
- default: fputs (_("unknown"), stdout); break;
- }
- }
- puts ("");
-}
-
-static uint64_t *
-get_dynamic_data (Filedata * filedata, uint64_t number, unsigned int ent_size)
-{
- unsigned char * e_data;
- uint64_t * i_data;
-
- /* If size_t is smaller than uint64_t, eg because you are building
- on a 32-bit host, then make sure that when number is cast to
- size_t no information is lost. */
- if ((size_t) number != number
- || ent_size * number / ent_size != number)
- {
- error (_("Size overflow prevents reading %" PRIu64
- " elements of size %u\n"),
- number, ent_size);
- return NULL;
- }
-
- /* Be kind to memory checkers (eg valgrind, address sanitizer) by not
- attempting to allocate memory when the read is bound to fail. */
- if (ent_size * number > filedata->file_size)
- {
- error (_("Invalid number of dynamic entries: %" PRIu64 "\n"),
- number);
- return NULL;
- }
-
- e_data = (unsigned char *) cmalloc ((size_t) number, ent_size);
- if (e_data == NULL)
- {
- error (_("Out of memory reading %" PRIu64 " dynamic entries\n"),
- number);
- return NULL;
- }
-
- if (fread (e_data, ent_size, (size_t) number, filedata->handle) != number)
- {
- error (_("Unable to read in %" PRIu64 " bytes of dynamic data\n"),
- number * ent_size);
- free (e_data);
- return NULL;
- }
-
- i_data = (uint64_t *) cmalloc ((size_t) number, sizeof (*i_data));
- if (i_data == NULL)
- {
- error (_("Out of memory allocating space for %" PRIu64 " dynamic entries\n"),
- number);
- free (e_data);
- return NULL;
- }
-
- while (number--)
- i_data[number] = byte_get (e_data + number * ent_size, ent_size);
-
- free (e_data);
-
- return i_data;
-}
-
-static uint64_t
-get_num_dynamic_syms (Filedata * filedata)
-{
- uint64_t num_of_syms = 0;
-
- if (!do_histogram && (!do_using_dynamic || do_dyn_syms))
- return num_of_syms;
-
- if (filedata->dynamic_info[DT_HASH])
- {
- unsigned char nb[8];
- unsigned char nc[8];
- unsigned int hash_ent_size = 4;
-
- if ((filedata->file_header.e_machine == EM_ALPHA
- || filedata->file_header.e_machine == EM_S390
- || filedata->file_header.e_machine == EM_S390_OLD)
- && filedata->file_header.e_ident[EI_CLASS] == ELFCLASS64)
- hash_ent_size = 8;
-
- if (fseek64 (filedata->handle,
- (filedata->archive_file_offset
- + offset_from_vma (filedata,
- filedata->dynamic_info[DT_HASH],
- sizeof nb + sizeof nc)),
- SEEK_SET))
- {
- error (_("Unable to seek to start of dynamic information\n"));
- goto no_hash;
- }
-
- if (fread (nb, hash_ent_size, 1, filedata->handle) != 1)
- {
- error (_("Failed to read in number of buckets\n"));
- goto no_hash;
- }
-
- if (fread (nc, hash_ent_size, 1, filedata->handle) != 1)
- {
- error (_("Failed to read in number of chains\n"));
- goto no_hash;
- }
-
- filedata->nbuckets = byte_get (nb, hash_ent_size);
- filedata->nchains = byte_get (nc, hash_ent_size);
-
- if (filedata->nbuckets != 0 && filedata->nchains != 0)
- {
- filedata->buckets = get_dynamic_data (filedata, filedata->nbuckets,
- hash_ent_size);
- filedata->chains = get_dynamic_data (filedata, filedata->nchains,
- hash_ent_size);
-
- if (filedata->buckets != NULL && filedata->chains != NULL)
- num_of_syms = filedata->nchains;
- }
- no_hash:
- if (num_of_syms == 0)
- {
- free (filedata->buckets);
- filedata->buckets = NULL;
- free (filedata->chains);
- filedata->chains = NULL;
- filedata->nbuckets = 0;
- }
- }
-
- if (filedata->dynamic_info_DT_GNU_HASH)
- {
- unsigned char nb[16];
- uint64_t i, maxchain = 0xffffffff, bitmaskwords;
- uint64_t buckets_vma;
- uint64_t hn;
-
- if (fseek64 (filedata->handle,
- (filedata->archive_file_offset
- + offset_from_vma (filedata,
- filedata->dynamic_info_DT_GNU_HASH,
- sizeof nb)),
- SEEK_SET))
- {
- error (_("Unable to seek to start of dynamic information\n"));
- goto no_gnu_hash;
- }
-
- if (fread (nb, 16, 1, filedata->handle) != 1)
- {
- error (_("Failed to read in number of buckets\n"));
- goto no_gnu_hash;
- }
-
- filedata->ngnubuckets = byte_get (nb, 4);
- filedata->gnusymidx = byte_get (nb + 4, 4);
- bitmaskwords = byte_get (nb + 8, 4);
- buckets_vma = filedata->dynamic_info_DT_GNU_HASH + 16;
- if (is_32bit_elf)
- buckets_vma += bitmaskwords * 4;
- else
- buckets_vma += bitmaskwords * 8;
-
- if (fseek64 (filedata->handle,
- (filedata->archive_file_offset
- + offset_from_vma (filedata, buckets_vma, 4)),
- SEEK_SET))
- {
- error (_("Unable to seek to start of dynamic information\n"));
- goto no_gnu_hash;
- }
-
- filedata->gnubuckets
- = get_dynamic_data (filedata, filedata->ngnubuckets, 4);
-
- if (filedata->gnubuckets == NULL)
- goto no_gnu_hash;
-
- for (i = 0; i < filedata->ngnubuckets; i++)
- if (filedata->gnubuckets[i] != 0)
- {
- if (filedata->gnubuckets[i] < filedata->gnusymidx)
- goto no_gnu_hash;
-
- if (maxchain == 0xffffffff || filedata->gnubuckets[i] > maxchain)
- maxchain = filedata->gnubuckets[i];
- }
-
- if (maxchain == 0xffffffff)
- goto no_gnu_hash;
-
- maxchain -= filedata->gnusymidx;
-
- if (fseek64 (filedata->handle,
- (filedata->archive_file_offset
- + offset_from_vma (filedata,
- buckets_vma + 4 * (filedata->ngnubuckets
- + maxchain),
- 4)),
- SEEK_SET))
- {
- error (_("Unable to seek to start of dynamic information\n"));
- goto no_gnu_hash;
- }
-
- do
- {
- if (fread (nb, 4, 1, filedata->handle) != 1)
- {
- error (_("Failed to determine last chain length\n"));
- goto no_gnu_hash;
- }
-
- if (maxchain + 1 == 0)
- goto no_gnu_hash;
-
- ++maxchain;
- }
- while ((byte_get (nb, 4) & 1) == 0);
-
- if (fseek64 (filedata->handle,
- (filedata->archive_file_offset
- + offset_from_vma (filedata, (buckets_vma
- + 4 * filedata->ngnubuckets),
- 4)),
- SEEK_SET))
- {
- error (_("Unable to seek to start of dynamic information\n"));
- goto no_gnu_hash;
- }
-
- filedata->gnuchains = get_dynamic_data (filedata, maxchain, 4);
- filedata->ngnuchains = maxchain;
-
- if (filedata->gnuchains == NULL)
- goto no_gnu_hash;
-
- if (filedata->dynamic_info_DT_MIPS_XHASH)
- {
- if (fseek64 (filedata->handle,
- (filedata->archive_file_offset
- + offset_from_vma (filedata, (buckets_vma
- + 4 * (filedata->ngnubuckets
- + maxchain)), 4)),
- SEEK_SET))
- {
- error (_("Unable to seek to start of dynamic information\n"));
- goto no_gnu_hash;
- }
-
- filedata->mipsxlat = get_dynamic_data (filedata, maxchain, 4);
- if (filedata->mipsxlat == NULL)
- goto no_gnu_hash;
- }
-
- for (hn = 0; hn < filedata->ngnubuckets; ++hn)
- if (filedata->gnubuckets[hn] != 0)
- {
- uint64_t si = filedata->gnubuckets[hn];
- uint64_t off = si - filedata->gnusymidx;
-
- do
- {
- if (filedata->dynamic_info_DT_MIPS_XHASH)
- {
- if (off < filedata->ngnuchains
- && filedata->mipsxlat[off] >= num_of_syms)
- num_of_syms = filedata->mipsxlat[off] + 1;
- }
- else
- {
- if (si >= num_of_syms)
- num_of_syms = si + 1;
- }
- si++;
- }
- while (off < filedata->ngnuchains
- && (filedata->gnuchains[off++] & 1) == 0);
- }
-
- if (num_of_syms == 0)
- {
- no_gnu_hash:
- free (filedata->mipsxlat);
- filedata->mipsxlat = NULL;
- free (filedata->gnuchains);
- filedata->gnuchains = NULL;
- free (filedata->gnubuckets);
- filedata->gnubuckets = NULL;
- filedata->ngnubuckets = 0;
- filedata->ngnuchains = 0;
- }
- }
-
- return num_of_syms;
-}
-
-/* Parse and display the contents of the dynamic section. */
-
-static bool
-process_dynamic_section (Filedata * filedata)
-{
- Elf_Internal_Dyn * entry;
-
- if (filedata->dynamic_size <= 1)
- {
- if (do_dynamic)
- {
- if (filedata->is_separate)
- printf (_("\nThere is no dynamic section in linked file '%s'.\n"),
- filedata->file_name);
- else
- printf (_("\nThere is no dynamic section in this file.\n"));
- }
-
- return true;
- }
-
- if (!get_dynamic_section (filedata))
- return false;
-
- /* Find the appropriate symbol table. */
- if (filedata->dynamic_symbols == NULL || do_histogram)
- {
- uint64_t num_of_syms;
-
- for (entry = filedata->dynamic_section;
- entry < filedata->dynamic_section + filedata->dynamic_nent;
- ++entry)
- if (entry->d_tag == DT_SYMTAB)
- filedata->dynamic_info[DT_SYMTAB] = entry->d_un.d_val;
- else if (entry->d_tag == DT_SYMENT)
- filedata->dynamic_info[DT_SYMENT] = entry->d_un.d_val;
- else if (entry->d_tag == DT_HASH)
- filedata->dynamic_info[DT_HASH] = entry->d_un.d_val;
- else if (entry->d_tag == DT_GNU_HASH)
- filedata->dynamic_info_DT_GNU_HASH = entry->d_un.d_val;
- else if ((filedata->file_header.e_machine == EM_MIPS
- || filedata->file_header.e_machine == EM_MIPS_RS3_LE)
- && entry->d_tag == DT_MIPS_XHASH)
- {
- filedata->dynamic_info_DT_MIPS_XHASH = entry->d_un.d_val;
- filedata->dynamic_info_DT_GNU_HASH = entry->d_un.d_val;
- }
-
- num_of_syms = get_num_dynamic_syms (filedata);
-
- if (num_of_syms != 0
- && filedata->dynamic_symbols == NULL
- && filedata->dynamic_info[DT_SYMTAB]
- && filedata->dynamic_info[DT_SYMENT])
- {
- Elf_Internal_Phdr *seg;
- uint64_t vma = filedata->dynamic_info[DT_SYMTAB];
-
- if (! get_program_headers (filedata))
- {
- error (_("Cannot interpret virtual addresses "
- "without program headers.\n"));
- return false;
- }
-
- for (seg = filedata->program_headers;
- seg < filedata->program_headers + filedata->file_header.e_phnum;
- ++seg)
- {
- if (seg->p_type != PT_LOAD)
- continue;
-
- if (seg->p_offset + seg->p_filesz > filedata->file_size)
- {
- /* See PR 21379 for a reproducer. */
- error (_("Invalid PT_LOAD entry\n"));
- return false;
- }
-
- if (vma >= (seg->p_vaddr & -seg->p_align)
- && vma < seg->p_vaddr + seg->p_filesz)
- {
- /* Since we do not know how big the symbol table is,
- we default to reading in up to the end of PT_LOAD
- segment and processing that. This is overkill, I
- know, but it should work. */
- Elf_Internal_Shdr section;
- section.sh_offset = (vma - seg->p_vaddr
- + seg->p_offset);
- section.sh_size = (num_of_syms
- * filedata->dynamic_info[DT_SYMENT]);
- section.sh_entsize = filedata->dynamic_info[DT_SYMENT];
-
- if (do_checks
- && filedata->dynamic_symtab_section != NULL
- && ((filedata->dynamic_symtab_section->sh_offset
- != section.sh_offset)
- || (filedata->dynamic_symtab_section->sh_size
- != section.sh_size)
- || (filedata->dynamic_symtab_section->sh_entsize
- != section.sh_entsize)))
- warn (_("\
-the .dynsym section doesn't match the DT_SYMTAB and DT_SYMENT tags\n"));
-
- section.sh_name = filedata->string_table_length;
- filedata->dynamic_symbols
- = get_elf_symbols (filedata, §ion,
- &filedata->num_dynamic_syms);
- if (filedata->dynamic_symbols == NULL
- || filedata->num_dynamic_syms != num_of_syms)
- {
- error (_("Corrupt DT_SYMTAB dynamic entry\n"));
- return false;
- }
- break;
- }
- }
- }
- }
-
- /* Similarly find a string table. */
- if (filedata->dynamic_strings == NULL)
- for (entry = filedata->dynamic_section;
- entry < filedata->dynamic_section + filedata->dynamic_nent;
- ++entry)
- {
- if (entry->d_tag == DT_STRTAB)
- filedata->dynamic_info[DT_STRTAB] = entry->d_un.d_val;
-
- if (entry->d_tag == DT_STRSZ)
- filedata->dynamic_info[DT_STRSZ] = entry->d_un.d_val;
-
- if (filedata->dynamic_info[DT_STRTAB]
- && filedata->dynamic_info[DT_STRSZ])
- {
- uint64_t offset;
- uint64_t str_tab_len = filedata->dynamic_info[DT_STRSZ];
-
- offset = offset_from_vma (filedata,
- filedata->dynamic_info[DT_STRTAB],
- str_tab_len);
- if (do_checks
- && filedata->dynamic_strtab_section
- && ((filedata->dynamic_strtab_section->sh_offset
- != (file_ptr) offset)
- || (filedata->dynamic_strtab_section->sh_size
- != str_tab_len)))
- warn (_("\
-the .dynstr section doesn't match the DT_STRTAB and DT_STRSZ tags\n"));
-
- filedata->dynamic_strings
- = (char *) get_data (NULL, filedata, offset, 1, str_tab_len,
- _("dynamic string table"));
- if (filedata->dynamic_strings == NULL)
- {
- error (_("Corrupt DT_STRTAB dynamic entry\n"));
- break;
- }
-
- filedata->dynamic_strings_length = str_tab_len;
- break;
- }
- }
-
- /* And find the syminfo section if available. */
- if (filedata->dynamic_syminfo == NULL)
- {
- uint64_t syminsz = 0;
-
- for (entry = filedata->dynamic_section;
- entry < filedata->dynamic_section + filedata->dynamic_nent;
- ++entry)
- {
- if (entry->d_tag == DT_SYMINENT)
- {
- /* Note: these braces are necessary to avoid a syntax
- error from the SunOS4 C compiler. */
- /* PR binutils/17531: A corrupt file can trigger this test.
- So do not use an assert, instead generate an error message. */
- if (sizeof (Elf_External_Syminfo) != entry->d_un.d_val)
- error (_("Bad value (%d) for SYMINENT entry\n"),
- (int) entry->d_un.d_val);
- }
- else if (entry->d_tag == DT_SYMINSZ)
- syminsz = entry->d_un.d_val;
- else if (entry->d_tag == DT_SYMINFO)
- filedata->dynamic_syminfo_offset
- = offset_from_vma (filedata, entry->d_un.d_val, syminsz);
- }
-
- if (filedata->dynamic_syminfo_offset != 0 && syminsz != 0)
- {
- Elf_External_Syminfo * extsyminfo;
- Elf_External_Syminfo * extsym;
- Elf_Internal_Syminfo * syminfo;
-
- /* There is a syminfo section. Read the data. */
- extsyminfo = (Elf_External_Syminfo *)
- get_data (NULL, filedata, filedata->dynamic_syminfo_offset,
- 1, syminsz, _("symbol information"));
- if (!extsyminfo)
- return false;
-
- if (filedata->dynamic_syminfo != NULL)
- {
- error (_("Multiple dynamic symbol information sections found\n"));
- free (filedata->dynamic_syminfo);
- }
- filedata->dynamic_syminfo = (Elf_Internal_Syminfo *) malloc (syminsz);
- if (filedata->dynamic_syminfo == NULL)
- {
- error (_("Out of memory allocating %" PRIu64
- " bytes for dynamic symbol info\n"),
- syminsz);
- return false;
- }
-
- filedata->dynamic_syminfo_nent
- = syminsz / sizeof (Elf_External_Syminfo);
- for (syminfo = filedata->dynamic_syminfo, extsym = extsyminfo;
- syminfo < (filedata->dynamic_syminfo
- + filedata->dynamic_syminfo_nent);
- ++syminfo, ++extsym)
- {
- syminfo->si_boundto = BYTE_GET (extsym->si_boundto);
- syminfo->si_flags = BYTE_GET (extsym->si_flags);
- }
-
- free (extsyminfo);
- }
- }
-
- if (do_dynamic && filedata->dynamic_addr)
- {
- if (filedata->is_separate)
- printf (ngettext ("\nIn linked file '%s' the dynamic section at offset %#" PRIx64 " contains %" PRIu64 " entry:\n",
- "\nIn linked file '%s' the dynamic section at offset %#" PRIx64 " contains %" PRIu64 " entries:\n",
- filedata->dynamic_nent),
- filedata->file_name,
- filedata->dynamic_addr,
- filedata->dynamic_nent);
- else
- printf (ngettext ("\nDynamic section at offset %#" PRIx64 " contains %" PRIu64 " entry:\n",
- "\nDynamic section at offset %#" PRIx64 " contains %" PRIu64 " entries:\n",
- filedata->dynamic_nent),
- filedata->dynamic_addr,
- filedata->dynamic_nent);
- }
- if (do_dynamic)
- printf (_(" Tag Type Name/Value\n"));
-
- for (entry = filedata->dynamic_section;
- entry < filedata->dynamic_section + filedata->dynamic_nent;
- entry++)
- {
- if (do_dynamic)
- {
- const char * dtype;
-
- putchar (' ');
- print_vma (entry->d_tag, FULL_HEX);
- dtype = get_dynamic_type (filedata, entry->d_tag);
- printf (" (%s)%*s", dtype,
- ((is_32bit_elf ? 27 : 19) - (int) strlen (dtype)), " ");
- }
-
- switch (entry->d_tag)
- {
- case DT_FLAGS:
- if (do_dynamic)
- print_dynamic_flags (entry->d_un.d_val);
- break;
-
- case DT_AUXILIARY:
- case DT_FILTER:
- case DT_CONFIG:
- case DT_DEPAUDIT:
- case DT_AUDIT:
- if (do_dynamic)
- {
- switch (entry->d_tag)
- {
- case DT_AUXILIARY:
- printf (_("Auxiliary library"));
- break;
-
- case DT_FILTER:
- printf (_("Filter library"));
- break;
-
- case DT_CONFIG:
- printf (_("Configuration file"));
- break;
-
- case DT_DEPAUDIT:
- printf (_("Dependency audit library"));
- break;
-
- case DT_AUDIT:
- printf (_("Audit library"));
- break;
- }
-
- if (valid_dynamic_name (filedata, entry->d_un.d_val))
- printf (": [%s]\n",
- get_dynamic_name (filedata, entry->d_un.d_val));
- else
- {
- printf (": ");
- print_vma (entry->d_un.d_val, PREFIX_HEX);
- putchar ('\n');
- }
- }
- break;
-
- case DT_FEATURE:
- if (do_dynamic)
- {
- printf (_("Flags:"));
-
- if (entry->d_un.d_val == 0)
- printf (_(" None\n"));
- else
- {
- uint64_t val = entry->d_un.d_val;
-
- if (val & DTF_1_PARINIT)
- {
- printf (" PARINIT");
- val ^= DTF_1_PARINIT;
- }
- if (val & DTF_1_CONFEXP)
- {
- printf (" CONFEXP");
- val ^= DTF_1_CONFEXP;
- }
- if (val != 0)
- printf (" %" PRIx64, val);
- puts ("");
- }
- }
- break;
-
- case DT_POSFLAG_1:
- if (do_dynamic)
- {
- printf (_("Flags:"));
-
- if (entry->d_un.d_val == 0)
- printf (_(" None\n"));
- else
- {
- uint64_t val = entry->d_un.d_val;
-
- if (val & DF_P1_LAZYLOAD)
- {
- printf (" LAZYLOAD");
- val ^= DF_P1_LAZYLOAD;
- }
- if (val & DF_P1_GROUPPERM)
- {
- printf (" GROUPPERM");
- val ^= DF_P1_GROUPPERM;
- }
- if (val != 0)
- printf (" %" PRIx64, val);
- puts ("");
- }
- }
- break;
-
- case DT_FLAGS_1:
- if (do_dynamic)
- {
- printf (_("Flags:"));
- if (entry->d_un.d_val == 0)
- printf (_(" None\n"));
- else
- {
- uint64_t val = entry->d_un.d_val;
-
- if (val & DF_1_NOW)
- {
- printf (" NOW");
- val ^= DF_1_NOW;
- }
- if (val & DF_1_GLOBAL)
- {
- printf (" GLOBAL");
- val ^= DF_1_GLOBAL;
- }
- if (val & DF_1_GROUP)
- {
- printf (" GROUP");
- val ^= DF_1_GROUP;
- }
- if (val & DF_1_NODELETE)
- {
- printf (" NODELETE");
- val ^= DF_1_NODELETE;
- }
- if (val & DF_1_LOADFLTR)
- {
- printf (" LOADFLTR");
- val ^= DF_1_LOADFLTR;
- }
- if (val & DF_1_INITFIRST)
- {
- printf (" INITFIRST");
- val ^= DF_1_INITFIRST;
- }
- if (val & DF_1_NOOPEN)
- {
- printf (" NOOPEN");
- val ^= DF_1_NOOPEN;
- }
- if (val & DF_1_ORIGIN)
- {
- printf (" ORIGIN");
- val ^= DF_1_ORIGIN;
- }
- if (val & DF_1_DIRECT)
- {
- printf (" DIRECT");
- val ^= DF_1_DIRECT;
- }
- if (val & DF_1_TRANS)
- {
- printf (" TRANS");
- val ^= DF_1_TRANS;
- }
- if (val & DF_1_INTERPOSE)
- {
- printf (" INTERPOSE");
- val ^= DF_1_INTERPOSE;
- }
- if (val & DF_1_NODEFLIB)
- {
- printf (" NODEFLIB");
- val ^= DF_1_NODEFLIB;
- }
- if (val & DF_1_NODUMP)
- {
- printf (" NODUMP");
- val ^= DF_1_NODUMP;
- }
- if (val & DF_1_CONFALT)
- {
- printf (" CONFALT");
- val ^= DF_1_CONFALT;
- }
- if (val & DF_1_ENDFILTEE)
- {
- printf (" ENDFILTEE");
- val ^= DF_1_ENDFILTEE;
- }
- if (val & DF_1_DISPRELDNE)
- {
- printf (" DISPRELDNE");
- val ^= DF_1_DISPRELDNE;
- }
- if (val & DF_1_DISPRELPND)
- {
- printf (" DISPRELPND");
- val ^= DF_1_DISPRELPND;
- }
- if (val & DF_1_NODIRECT)
- {
- printf (" NODIRECT");
- val ^= DF_1_NODIRECT;
- }
- if (val & DF_1_IGNMULDEF)
- {
- printf (" IGNMULDEF");
- val ^= DF_1_IGNMULDEF;
- }
- if (val & DF_1_NOKSYMS)
- {
- printf (" NOKSYMS");
- val ^= DF_1_NOKSYMS;
- }
- if (val & DF_1_NOHDR)
- {
- printf (" NOHDR");
- val ^= DF_1_NOHDR;
- }
- if (val & DF_1_EDITED)
- {
- printf (" EDITED");
- val ^= DF_1_EDITED;
- }
- if (val & DF_1_NORELOC)
- {
- printf (" NORELOC");
- val ^= DF_1_NORELOC;
- }
- if (val & DF_1_SYMINTPOSE)
- {
- printf (" SYMINTPOSE");
- val ^= DF_1_SYMINTPOSE;
- }
- if (val & DF_1_GLOBAUDIT)
- {
- printf (" GLOBAUDIT");
- val ^= DF_1_GLOBAUDIT;
- }
- if (val & DF_1_SINGLETON)
- {
- printf (" SINGLETON");
- val ^= DF_1_SINGLETON;
- }
- if (val & DF_1_STUB)
- {
- printf (" STUB");
- val ^= DF_1_STUB;
- }
- if (val & DF_1_PIE)
- {
- printf (" PIE");
- val ^= DF_1_PIE;
- }
- if (val & DF_1_KMOD)
- {
- printf (" KMOD");
- val ^= DF_1_KMOD;
- }
- if (val & DF_1_WEAKFILTER)
- {
- printf (" WEAKFILTER");
- val ^= DF_1_WEAKFILTER;
- }
- if (val & DF_1_NOCOMMON)
- {
- printf (" NOCOMMON");
- val ^= DF_1_NOCOMMON;
- }
- if (val != 0)
- printf (" %" PRIx64, val);
- puts ("");
- }
- }
- break;
-
- case DT_PLTREL:
- filedata->dynamic_info[entry->d_tag] = entry->d_un.d_val;
- if (do_dynamic)
- puts (get_dynamic_type (filedata, entry->d_un.d_val));
- break;
-
- case DT_NULL :
- case DT_NEEDED :
- case DT_PLTGOT :
- case DT_HASH :
- case DT_STRTAB :
- case DT_SYMTAB :
- case DT_RELA :
- case DT_INIT :
- case DT_FINI :
- case DT_SONAME :
- case DT_RPATH :
- case DT_SYMBOLIC:
- case DT_REL :
- case DT_RELR :
- case DT_DEBUG :
- case DT_TEXTREL :
- case DT_JMPREL :
- case DT_RUNPATH :
- filedata->dynamic_info[entry->d_tag] = entry->d_un.d_val;
-
- if (do_dynamic)
- {
- const char *name;
-
- if (valid_dynamic_name (filedata, entry->d_un.d_val))
- name = get_dynamic_name (filedata, entry->d_un.d_val);
- else
- name = NULL;
-
- if (name)
- {
- switch (entry->d_tag)
- {
- case DT_NEEDED:
- printf (_("Shared library: [%s]"), name);
-
- if (filedata->program_interpreter
- && streq (name, filedata->program_interpreter))
- printf (_(" program interpreter"));
- break;
-
- case DT_SONAME:
- printf (_("Library soname: [%s]"), name);
- break;
-
- case DT_RPATH:
- printf (_("Library rpath: [%s]"), name);
- break;
-
- case DT_RUNPATH:
- printf (_("Library runpath: [%s]"), name);
- break;
-
- default:
- print_vma (entry->d_un.d_val, PREFIX_HEX);
- break;
- }
- }
- else
- print_vma (entry->d_un.d_val, PREFIX_HEX);
-
- putchar ('\n');
- }
- break;
-
- case DT_PLTRELSZ:
- case DT_RELASZ :
- case DT_STRSZ :
- case DT_RELSZ :
- case DT_RELAENT :
- case DT_RELRENT :
- case DT_RELRSZ :
- case DT_SYMENT :
- case DT_RELENT :
- filedata->dynamic_info[entry->d_tag] = entry->d_un.d_val;
- /* Fall through. */
- case DT_PLTPADSZ:
- case DT_MOVEENT :
- case DT_MOVESZ :
- case DT_PREINIT_ARRAYSZ:
- case DT_INIT_ARRAYSZ:
- case DT_FINI_ARRAYSZ:
- case DT_GNU_CONFLICTSZ:
- case DT_GNU_LIBLISTSZ:
- if (do_dynamic)
- {
- print_vma (entry->d_un.d_val, UNSIGNED);
- printf (_(" (bytes)\n"));
- }
- break;
-
- case DT_VERDEFNUM:
- case DT_VERNEEDNUM:
- case DT_RELACOUNT:
- case DT_RELCOUNT:
- if (do_dynamic)
- {
- print_vma (entry->d_un.d_val, UNSIGNED);
- putchar ('\n');
- }
- break;
-
- case DT_SYMINSZ:
- case DT_SYMINENT:
- case DT_SYMINFO:
- case DT_USED:
- case DT_INIT_ARRAY:
- case DT_FINI_ARRAY:
- if (do_dynamic)
- {
- if (entry->d_tag == DT_USED
- && valid_dynamic_name (filedata, entry->d_un.d_val))
- {
- const char *name
- = get_dynamic_name (filedata, entry->d_un.d_val);
-
- if (*name)
- {
- printf (_("Not needed object: [%s]\n"), name);
- break;
- }
- }
-
- print_vma (entry->d_un.d_val, PREFIX_HEX);
- putchar ('\n');
- }
- break;
-
- case DT_BIND_NOW:
- /* The value of this entry is ignored. */
- if (do_dynamic)
- putchar ('\n');
- break;
-
- case DT_GNU_PRELINKED:
- if (do_dynamic)
- {
- struct tm * tmp;
- time_t atime = entry->d_un.d_val;
-
- tmp = gmtime (&atime);
- /* PR 17533 file: 041-1244816-0.004. */
- if (tmp == NULL)
- printf (_("<corrupt time val: %" PRIx64),
- (uint64_t) atime);
- else
- printf ("%04u-%02u-%02uT%02u:%02u:%02u\n",
- tmp->tm_year + 1900, tmp->tm_mon + 1, tmp->tm_mday,
- tmp->tm_hour, tmp->tm_min, tmp->tm_sec);
-
- }
- break;
-
- case DT_GNU_HASH:
- filedata->dynamic_info_DT_GNU_HASH = entry->d_un.d_val;
- if (do_dynamic)
- {
- print_vma (entry->d_un.d_val, PREFIX_HEX);
- putchar ('\n');
- }
- break;
-
- case DT_GNU_FLAGS_1:
- if (do_dynamic)
- {
- printf (_("Flags:"));
- if (entry->d_un.d_val == 0)
- printf (_(" None\n"));
- else
- {
- uint64_t val = entry->d_un.d_val;
-
- if (val & DF_GNU_1_UNIQUE)
- {
- printf (" UNIQUE");
- val ^= DF_GNU_1_UNIQUE;
- }
- if (val != 0)
- printf (" %" PRIx64, val);
- puts ("");
- }
- }
- break;
-
- default:
- if ((entry->d_tag >= DT_VERSYM) && (entry->d_tag <= DT_VERNEEDNUM))
- filedata->version_info[DT_VERSIONTAGIDX (entry->d_tag)]
- = entry->d_un.d_val;
-
- if (do_dynamic)
- {
- switch (filedata->file_header.e_machine)
- {
- case EM_AARCH64:
- dynamic_section_aarch64_val (entry);
- break;
- case EM_MIPS:
- case EM_MIPS_RS3_LE:
- dynamic_section_mips_val (filedata, entry);
- break;
- case EM_PARISC:
- dynamic_section_parisc_val (entry);
- break;
- case EM_IA_64:
- dynamic_section_ia64_val (entry);
- break;
- default:
- print_vma (entry->d_un.d_val, PREFIX_HEX);
- putchar ('\n');
- }
- }
- break;
- }
- }
-
- return true;
-}
-
-static char *
-get_ver_flags (unsigned int flags)
-{
- static char buff[128];
-
- buff[0] = 0;
-
- if (flags == 0)
- return _("none");
-
- if (flags & VER_FLG_BASE)
- strcat (buff, "BASE");
-
- if (flags & VER_FLG_WEAK)
- {
- if (flags & VER_FLG_BASE)
- strcat (buff, " | ");
-
- strcat (buff, "WEAK");
- }
-
- if (flags & VER_FLG_INFO)
- {
- if (flags & (VER_FLG_BASE|VER_FLG_WEAK))
- strcat (buff, " | ");
-
- strcat (buff, "INFO");
- }
-
- if (flags & ~(VER_FLG_BASE | VER_FLG_WEAK | VER_FLG_INFO))
- {
- if (flags & (VER_FLG_BASE | VER_FLG_WEAK | VER_FLG_INFO))
- strcat (buff, " | ");
-
- strcat (buff, _("<unknown>"));
- }
-
- return buff;
-}
-
-/* Display the contents of the version sections. */
-
-static bool
-process_version_sections (Filedata * filedata)
-{
- Elf_Internal_Shdr * section;
- unsigned i;
- bool found = false;
-
- if (! do_version)
- return true;
-
- for (i = 0, section = filedata->section_headers;
- i < filedata->file_header.e_shnum;
- i++, section++)
- {
- switch (section->sh_type)
- {
- case SHT_GNU_verdef:
- {
- Elf_External_Verdef * edefs;
- size_t idx;
- size_t cnt;
- char * endbuf;
-
- found = true;
-
- if (filedata->is_separate)
- printf (ngettext ("\nIn linked file '%s' the version definition section '%s' contains %u entry:\n",
- "\nIn linked file '%s' the version definition section '%s' contains %u entries:\n",
- section->sh_info),
- filedata->file_name,
- printable_section_name (filedata, section),
- section->sh_info);
- else
- printf (ngettext ("\nVersion definition section '%s' "
- "contains %u entry:\n",
- "\nVersion definition section '%s' "
- "contains %u entries:\n",
- section->sh_info),
- printable_section_name (filedata, section),
- section->sh_info);
-
- printf (_(" Addr: 0x%016" PRIx64), section->sh_addr);
- printf (_(" Offset: 0x%08" PRIx64 " Link: %u (%s)\n"),
- section->sh_offset, section->sh_link,
- printable_section_name_from_index (filedata, section->sh_link, NULL));
-
- edefs = (Elf_External_Verdef *)
- get_data (NULL, filedata, section->sh_offset, 1,section->sh_size,
- _("version definition section"));
- if (!edefs)
- break;
- endbuf = (char *) edefs + section->sh_size;
-
- for (idx = cnt = 0; cnt < section->sh_info; ++cnt)
- {
- char * vstart;
- Elf_External_Verdef * edef;
- Elf_Internal_Verdef ent;
- Elf_External_Verdaux * eaux;
- Elf_Internal_Verdaux aux;
- size_t isum;
- int j;
-
- vstart = ((char *) edefs) + idx;
- if (vstart + sizeof (*edef) > endbuf)
- break;
-
- edef = (Elf_External_Verdef *) vstart;
-
- ent.vd_version = BYTE_GET (edef->vd_version);
- ent.vd_flags = BYTE_GET (edef->vd_flags);
- ent.vd_ndx = BYTE_GET (edef->vd_ndx);
- ent.vd_cnt = BYTE_GET (edef->vd_cnt);
- ent.vd_hash = BYTE_GET (edef->vd_hash);
- ent.vd_aux = BYTE_GET (edef->vd_aux);
- ent.vd_next = BYTE_GET (edef->vd_next);
-
- printf (_(" %#06zx: Rev: %d Flags: %s"),
- idx, ent.vd_version, get_ver_flags (ent.vd_flags));
-
- printf (_(" Index: %d Cnt: %d "),
- ent.vd_ndx, ent.vd_cnt);
-
- /* Check for overflow. */
- if (ent.vd_aux > (size_t) (endbuf - vstart))
- break;
-
- vstart += ent.vd_aux;
-
- if (vstart + sizeof (*eaux) > endbuf)
- break;
- eaux = (Elf_External_Verdaux *) vstart;
-
- aux.vda_name = BYTE_GET (eaux->vda_name);
- aux.vda_next = BYTE_GET (eaux->vda_next);
-
- if (valid_dynamic_name (filedata, aux.vda_name))
- printf (_("Name: %s\n"),
- get_dynamic_name (filedata, aux.vda_name));
- else
- printf (_("Name index: %ld\n"), aux.vda_name);
-
- isum = idx + ent.vd_aux;
-
- for (j = 1; j < ent.vd_cnt; j++)
- {
- if (aux.vda_next < sizeof (*eaux)
- && !(j == ent.vd_cnt - 1 && aux.vda_next == 0))
- {
- warn (_("Invalid vda_next field of %lx\n"),
- aux.vda_next);
- j = ent.vd_cnt;
- break;
- }
- /* Check for overflow. */
- if (aux.vda_next > (size_t) (endbuf - vstart))
- break;
-
- isum += aux.vda_next;
- vstart += aux.vda_next;
-
- if (vstart + sizeof (*eaux) > endbuf)
- break;
- eaux = (Elf_External_Verdaux *) vstart;
-
- aux.vda_name = BYTE_GET (eaux->vda_name);
- aux.vda_next = BYTE_GET (eaux->vda_next);
-
- if (valid_dynamic_name (filedata, aux.vda_name))
- printf (_(" %#06zx: Parent %d: %s\n"),
- isum, j,
- get_dynamic_name (filedata, aux.vda_name));
- else
- printf (_(" %#06zx: Parent %d, name index: %ld\n"),
- isum, j, aux.vda_name);
- }
-
- if (j < ent.vd_cnt)
- printf (_(" Version def aux past end of section\n"));
-
- /* PR 17531:
- file: id:000001,src:000172+005151,op:splice,rep:2. */
- if (ent.vd_next < sizeof (*edef)
- && !(cnt == section->sh_info - 1 && ent.vd_next == 0))
- {
- warn (_("Invalid vd_next field of %lx\n"), ent.vd_next);
- cnt = section->sh_info;
- break;
- }
- if (ent.vd_next > (size_t) (endbuf - ((char *) edefs + idx)))
- break;
-
- idx += ent.vd_next;
- }
-
- if (cnt < section->sh_info)
- printf (_(" Version definition past end of section\n"));
-
- free (edefs);
- }
- break;
-
- case SHT_GNU_verneed:
- {
- Elf_External_Verneed * eneed;
- size_t idx;
- size_t cnt;
- char * endbuf;
-
- found = true;
-
- if (filedata->is_separate)
- printf (ngettext ("\nIn linked file '%s' the version needs section '%s' contains %u entry:\n",
- "\nIn linked file '%s' the version needs section '%s' contains %u entries:\n",
- section->sh_info),
- filedata->file_name,
- printable_section_name (filedata, section),
- section->sh_info);
- else
- printf (ngettext ("\nVersion needs section '%s' "
- "contains %u entry:\n",
- "\nVersion needs section '%s' "
- "contains %u entries:\n",
- section->sh_info),
- printable_section_name (filedata, section),
- section->sh_info);
-
- printf (_(" Addr: 0x%016" PRIx64), section->sh_addr);
- printf (_(" Offset: 0x%08" PRIx64 " Link: %u (%s)\n"),
- section->sh_offset, section->sh_link,
- printable_section_name_from_index (filedata, section->sh_link, NULL));
-
- eneed = (Elf_External_Verneed *) get_data (NULL, filedata,
- section->sh_offset, 1,
- section->sh_size,
- _("Version Needs section"));
- if (!eneed)
- break;
- endbuf = (char *) eneed + section->sh_size;
-
- for (idx = cnt = 0; cnt < section->sh_info; ++cnt)
- {
- Elf_External_Verneed * entry;
- Elf_Internal_Verneed ent;
- size_t isum;
- int j;
- char * vstart;
-
- vstart = ((char *) eneed) + idx;
- if (vstart + sizeof (*entry) > endbuf)
- break;
-
- entry = (Elf_External_Verneed *) vstart;
-
- ent.vn_version = BYTE_GET (entry->vn_version);
- ent.vn_cnt = BYTE_GET (entry->vn_cnt);
- ent.vn_file = BYTE_GET (entry->vn_file);
- ent.vn_aux = BYTE_GET (entry->vn_aux);
- ent.vn_next = BYTE_GET (entry->vn_next);
-
- printf (_(" %#06zx: Version: %d"), idx, ent.vn_version);
-
- if (valid_dynamic_name (filedata, ent.vn_file))
- printf (_(" File: %s"),
- get_dynamic_name (filedata, ent.vn_file));
- else
- printf (_(" File: %lx"), ent.vn_file);
-
- printf (_(" Cnt: %d\n"), ent.vn_cnt);
-
- /* Check for overflow. */
- if (ent.vn_aux > (size_t) (endbuf - vstart))
- break;
- vstart += ent.vn_aux;
-
- for (j = 0, isum = idx + ent.vn_aux; j < ent.vn_cnt; ++j)
- {
- Elf_External_Vernaux * eaux;
- Elf_Internal_Vernaux aux;
-
- if (vstart + sizeof (*eaux) > endbuf)
- break;
- eaux = (Elf_External_Vernaux *) vstart;
-
- aux.vna_hash = BYTE_GET (eaux->vna_hash);
- aux.vna_flags = BYTE_GET (eaux->vna_flags);
- aux.vna_other = BYTE_GET (eaux->vna_other);
- aux.vna_name = BYTE_GET (eaux->vna_name);
- aux.vna_next = BYTE_GET (eaux->vna_next);
-
- if (valid_dynamic_name (filedata, aux.vna_name))
- printf (_(" %#06zx: Name: %s"),
- isum, get_dynamic_name (filedata, aux.vna_name));
- else
- printf (_(" %#06zx: Name index: %lx"),
- isum, aux.vna_name);
-
- printf (_(" Flags: %s Version: %d\n"),
- get_ver_flags (aux.vna_flags), aux.vna_other);
-
- if (aux.vna_next < sizeof (*eaux)
- && !(j == ent.vn_cnt - 1 && aux.vna_next == 0))
- {
- warn (_("Invalid vna_next field of %lx\n"),
- aux.vna_next);
- j = ent.vn_cnt;
- break;
- }
- /* Check for overflow. */
- if (aux.vna_next > (size_t) (endbuf - vstart))
- break;
- isum += aux.vna_next;
- vstart += aux.vna_next;
- }
-
- if (j < ent.vn_cnt)
- warn (_("Missing Version Needs auxiliary information\n"));
-
- if (ent.vn_next < sizeof (*entry)
- && !(cnt == section->sh_info - 1 && ent.vn_next == 0))
- {
- warn (_("Invalid vn_next field of %lx\n"), ent.vn_next);
- cnt = section->sh_info;
- break;
- }
- if (ent.vn_next > (size_t) (endbuf - ((char *) eneed + idx)))
- break;
- idx += ent.vn_next;
- }
-
- if (cnt < section->sh_info)
- warn (_("Missing Version Needs information\n"));
-
- free (eneed);
- }
- break;
-
- case SHT_GNU_versym:
- {
- Elf_Internal_Shdr * link_section;
- uint64_t total;
- unsigned int cnt;
- unsigned char * edata;
- unsigned short * data;
- char * strtab;
- Elf_Internal_Sym * symbols;
- Elf_Internal_Shdr * string_sec;
- uint64_t num_syms;
- uint64_t off;
-
- if (section->sh_link >= filedata->file_header.e_shnum)
- break;
-
- link_section = filedata->section_headers + section->sh_link;
- total = section->sh_size / sizeof (Elf_External_Versym);
-
- if (link_section->sh_link >= filedata->file_header.e_shnum)
- break;
-
- found = true;
-
- symbols = get_elf_symbols (filedata, link_section, & num_syms);
- if (symbols == NULL)
- break;
-
- string_sec = filedata->section_headers + link_section->sh_link;
-
- strtab = (char *) get_data (NULL, filedata, string_sec->sh_offset, 1,
- string_sec->sh_size,
- _("version string table"));
- if (!strtab)
- {
- free (symbols);
- break;
- }
-
- if (filedata->is_separate)
- printf (ngettext ("\nIn linked file '%s' the version symbols section '%s' contains %" PRIu64 " entry:\n",
- "\nIn linked file '%s' the version symbols section '%s' contains %" PRIu64 " entries:\n",
- total),
- filedata->file_name,
- printable_section_name (filedata, section),
- total);
- else
- printf (ngettext ("\nVersion symbols section '%s' "
- "contains %" PRIu64 " entry:\n",
- "\nVersion symbols section '%s' "
- "contains %" PRIu64 " entries:\n",
- total),
- printable_section_name (filedata, section),
- total);
-
- printf (_(" Addr: 0x%016" PRIx64), section->sh_addr);
- printf (_(" Offset: 0x%08" PRIx64 " Link: %u (%s)\n"),
- section->sh_offset, section->sh_link,
- printable_section_name (filedata, link_section));
-
- off = offset_from_vma (filedata,
- filedata->version_info[DT_VERSIONTAGIDX (DT_VERSYM)],
- total * sizeof (short));
- edata = (unsigned char *) get_data (NULL, filedata, off,
- sizeof (short), total,
- _("version symbol data"));
- if (!edata)
- {
- free (strtab);
- free (symbols);
- break;
- }
-
- data = (short unsigned int *) cmalloc (total, sizeof (short));
-
- for (cnt = total; cnt --;)
- data[cnt] = byte_get (edata + cnt * sizeof (short),
- sizeof (short));
-
- free (edata);
-
- for (cnt = 0; cnt < total; cnt += 4)
- {
- int j, nn;
- char *name;
- char *invalid = _("*invalid*");
-
- printf (" %03x:", cnt);
-
- for (j = 0; (j < 4) && (cnt + j) < total; ++j)
- switch (data[cnt + j])
- {
- case 0:
- fputs (_(" 0 (*local*) "), stdout);
- break;
-
- case 1:
- fputs (_(" 1 (*global*) "), stdout);
- break;
-
- default:
- nn = printf ("%4x%c", data[cnt + j] & VERSYM_VERSION,
- data[cnt + j] & VERSYM_HIDDEN ? 'h' : ' ');
-
- /* If this index value is greater than the size of the symbols
- array, break to avoid an out-of-bounds read. */
- if (cnt + j >= num_syms)
- {
- warn (_("invalid index into symbol array\n"));
- break;
- }
-
- name = NULL;
- if (filedata->version_info[DT_VERSIONTAGIDX (DT_VERNEED)])
- {
- Elf_Internal_Verneed ivn;
- uint64_t offset;
-
- offset = offset_from_vma
- (filedata,
- filedata->version_info[DT_VERSIONTAGIDX (DT_VERNEED)],
- sizeof (Elf_External_Verneed));
-
- do
- {
- Elf_Internal_Vernaux ivna;
- Elf_External_Verneed evn;
- Elf_External_Vernaux evna;
- uint64_t a_off;
-
- if (get_data (&evn, filedata, offset, sizeof (evn), 1,
- _("version need")) == NULL)
- break;
-
- ivn.vn_aux = BYTE_GET (evn.vn_aux);
- ivn.vn_next = BYTE_GET (evn.vn_next);
-
- a_off = offset + ivn.vn_aux;
-
- do
- {
- if (get_data (&evna, filedata, a_off, sizeof (evna),
- 1, _("version need aux (2)")) == NULL)
- {
- ivna.vna_next = 0;
- ivna.vna_other = 0;
- }
- else
- {
- ivna.vna_next = BYTE_GET (evna.vna_next);
- ivna.vna_other = BYTE_GET (evna.vna_other);
- }
-
- a_off += ivna.vna_next;
- }
- while (ivna.vna_other != data[cnt + j]
- && ivna.vna_next != 0);
-
- if (ivna.vna_other == data[cnt + j])
- {
- ivna.vna_name = BYTE_GET (evna.vna_name);
-
- if (ivna.vna_name >= string_sec->sh_size)
- name = invalid;
- else
- name = strtab + ivna.vna_name;
- break;
- }
-
- offset += ivn.vn_next;
- }
- while (ivn.vn_next);
- }
-
- if (data[cnt + j] != 0x8001
- && filedata->version_info[DT_VERSIONTAGIDX (DT_VERDEF)])
- {
- Elf_Internal_Verdef ivd;
- Elf_External_Verdef evd;
- uint64_t offset;
-
- offset = offset_from_vma
- (filedata,
- filedata->version_info[DT_VERSIONTAGIDX (DT_VERDEF)],
- sizeof evd);
-
- do
- {
- if (get_data (&evd, filedata, offset, sizeof (evd), 1,
- _("version def")) == NULL)
- {
- ivd.vd_next = 0;
- /* PR 17531: file: 046-1082287-0.004. */
- ivd.vd_ndx = (data[cnt + j] & VERSYM_VERSION) + 1;
- break;
- }
- else
- {
- ivd.vd_next = BYTE_GET (evd.vd_next);
- ivd.vd_ndx = BYTE_GET (evd.vd_ndx);
- }
-
- offset += ivd.vd_next;
- }
- while (ivd.vd_ndx != (data[cnt + j] & VERSYM_VERSION)
- && ivd.vd_next != 0);
-
- if (ivd.vd_ndx == (data[cnt + j] & VERSYM_VERSION))
- {
- Elf_External_Verdaux evda;
- Elf_Internal_Verdaux ivda;
-
- ivd.vd_aux = BYTE_GET (evd.vd_aux);
-
- if (get_data (&evda, filedata,
- offset - ivd.vd_next + ivd.vd_aux,
- sizeof (evda), 1,
- _("version def aux")) == NULL)
- break;
-
- ivda.vda_name = BYTE_GET (evda.vda_name);
-
- if (ivda.vda_name >= string_sec->sh_size)
- name = invalid;
- else if (name != NULL && name != invalid)
- name = _("*both*");
- else
- name = strtab + ivda.vda_name;
- }
- }
- if (name != NULL)
- nn += printf ("(%s%-*s",
- name,
- 12 - (int) strlen (name),
- ")");
-
- if (nn < 18)
- printf ("%*c", 18 - nn, ' ');
- }
-
- putchar ('\n');
- }
-
- free (data);
- free (strtab);
- free (symbols);
- }
- break;
-
- default:
- break;
- }
- }
-
- if (! found)
- {
- if (filedata->is_separate)
- printf (_("\nNo version information found in linked file '%s'.\n"),
- filedata->file_name);
- else
- printf (_("\nNo version information found in this file.\n"));
- }
-
- return true;
-}
-
-static const char *
-get_symbol_binding (Filedata * filedata, unsigned int binding)
-{
- static char buff[64];
-
- switch (binding)
- {
- case STB_LOCAL: return "LOCAL";
- case STB_GLOBAL: return "GLOBAL";
- case STB_WEAK: return "WEAK";
- default:
- if (binding >= STB_LOPROC && binding <= STB_HIPROC)
- snprintf (buff, sizeof (buff), _("<processor specific>: %d"),
- binding);
- else if (binding >= STB_LOOS && binding <= STB_HIOS)
- {
- if (binding == STB_GNU_UNIQUE
- && filedata->file_header.e_ident[EI_OSABI] == ELFOSABI_GNU)
- return "UNIQUE";
- snprintf (buff, sizeof (buff), _("<OS specific>: %d"), binding);
- }
- else
- snprintf (buff, sizeof (buff), _("<unknown>: %d"), binding);
- return buff;
- }
-}
-
-static const char *
-get_symbol_type (Filedata * filedata, unsigned int type)
-{
- static char buff[64];
-
- switch (type)
- {
- case STT_NOTYPE: return "NOTYPE";
- case STT_OBJECT: return "OBJECT";
- case STT_FUNC: return "FUNC";
- case STT_SECTION: return "SECTION";
- case STT_FILE: return "FILE";
- case STT_COMMON: return "COMMON";
- case STT_TLS: return "TLS";
- case STT_RELC: return "RELC";
- case STT_SRELC: return "SRELC";
- default:
- if (type >= STT_LOPROC && type <= STT_HIPROC)
- {
- if (filedata->file_header.e_machine == EM_ARM && type == STT_ARM_TFUNC)
- return "THUMB_FUNC";
-
- if (filedata->file_header.e_machine == EM_SPARCV9 && type == STT_REGISTER)
- return "REGISTER";
-
- if (filedata->file_header.e_machine == EM_PARISC && type == STT_PARISC_MILLI)
- return "PARISC_MILLI";
-
- snprintf (buff, sizeof (buff), _("<processor specific>: %d"), type);
- }
- else if (type >= STT_LOOS && type <= STT_HIOS)
- {
- if (filedata->file_header.e_machine == EM_PARISC)
- {
- if (type == STT_HP_OPAQUE)
- return "HP_OPAQUE";
- if (type == STT_HP_STUB)
- return "HP_STUB";
- }
-
- if (type == STT_GNU_IFUNC
- && (filedata->file_header.e_ident[EI_OSABI] == ELFOSABI_GNU
- || filedata->file_header.e_ident[EI_OSABI] == ELFOSABI_FREEBSD))
- return "IFUNC";
-
- snprintf (buff, sizeof (buff), _("<OS specific>: %d"), type);
- }
- else
- snprintf (buff, sizeof (buff), _("<unknown>: %d"), type);
- return buff;
- }
-}
-
-static const char *
-get_symbol_visibility (unsigned int visibility)
-{
- switch (visibility)
- {
- case STV_DEFAULT: return "DEFAULT";
- case STV_INTERNAL: return "INTERNAL";
- case STV_HIDDEN: return "HIDDEN";
- case STV_PROTECTED: return "PROTECTED";
- default:
- error (_("Unrecognized visibility value: %u\n"), visibility);
- return _("<unknown>");
- }
-}
-
-static const char *
-get_alpha_symbol_other (unsigned int other)
-{
- switch (other)
- {
- case STO_ALPHA_NOPV: return "NOPV";
- case STO_ALPHA_STD_GPLOAD: return "STD GPLOAD";
- default:
- error (_("Unrecognized alpha specific other value: %u\n"), other);
- return _("<unknown>");
- }
-}
-
-static const char *
-get_solaris_symbol_visibility (unsigned int visibility)
-{
- switch (visibility)
- {
- case 4: return "EXPORTED";
- case 5: return "SINGLETON";
- case 6: return "ELIMINATE";
- default: return get_symbol_visibility (visibility);
- }
-}
-
-static const char *
-get_aarch64_symbol_other (unsigned int other)
-{
- static char buf[32];
-
- if (other & STO_AARCH64_VARIANT_PCS)
- {
- other &= ~STO_AARCH64_VARIANT_PCS;
- if (other == 0)
- return "VARIANT_PCS";
- snprintf (buf, sizeof buf, "VARIANT_PCS | %x", other);
- return buf;
- }
- return NULL;
-}
-
-static const char *
-get_mips_symbol_other (unsigned int other)
-{
- switch (other)
- {
- case STO_OPTIONAL: return "OPTIONAL";
- case STO_MIPS_PLT: return "MIPS PLT";
- case STO_MIPS_PIC: return "MIPS PIC";
- case STO_MICROMIPS: return "MICROMIPS";
- case STO_MICROMIPS | STO_MIPS_PIC: return "MICROMIPS, MIPS PIC";
- case STO_MIPS16: return "MIPS16";
- default: return NULL;
- }
-}
-
-static const char *
-get_ia64_symbol_other (Filedata * filedata, unsigned int other)
-{
- if (is_ia64_vms (filedata))
- {
- static char res[32];
-
- res[0] = 0;
-
- /* Function types is for images and .STB files only. */
- switch (filedata->file_header.e_type)
- {
- case ET_DYN:
- case ET_EXEC:
- switch (VMS_ST_FUNC_TYPE (other))
- {
- case VMS_SFT_CODE_ADDR:
- strcat (res, " CA");
- break;
- case VMS_SFT_SYMV_IDX:
- strcat (res, " VEC");
- break;
- case VMS_SFT_FD:
- strcat (res, " FD");
- break;
- case VMS_SFT_RESERVE:
- strcat (res, " RSV");
- break;
- default:
- warn (_("Unrecognized IA64 VMS ST Function type: %d\n"),
- VMS_ST_FUNC_TYPE (other));
- strcat (res, " <unknown>");
- break;
- }
- break;
- default:
- break;
- }
- switch (VMS_ST_LINKAGE (other))
- {
- case VMS_STL_IGNORE:
- strcat (res, " IGN");
- break;
- case VMS_STL_RESERVE:
- strcat (res, " RSV");
- break;
- case VMS_STL_STD:
- strcat (res, " STD");
- break;
- case VMS_STL_LNK:
- strcat (res, " LNK");
- break;
- default:
- warn (_("Unrecognized IA64 VMS ST Linkage: %d\n"),
- VMS_ST_LINKAGE (other));
- strcat (res, " <unknown>");
- break;
- }
-
- if (res[0] != 0)
- return res + 1;
- else
- return res;
- }
- return NULL;
-}
-
-static const char *
-get_ppc64_symbol_other (unsigned int other)
-{
- if ((other & ~STO_PPC64_LOCAL_MASK) != 0)
- return NULL;
-
- other >>= STO_PPC64_LOCAL_BIT;
- if (other <= 6)
- {
- static char buf[64];
- if (other >= 2)
- other = ppc64_decode_local_entry (other);
- snprintf (buf, sizeof buf, _("<localentry>: %d"), other);
- return buf;
- }
- return NULL;
-}
-
-static const char *
-get_riscv_symbol_other (unsigned int other)
-{
- static char buf[32];
- buf[0] = 0;
-
- if (other & STO_RISCV_VARIANT_CC)
- {
- strcat (buf, _(" VARIANT_CC"));
- other &= ~STO_RISCV_VARIANT_CC;
- }
-
- if (other != 0)
- snprintf (buf, sizeof buf, " %x", other);
-
-
- if (buf[0] != 0)
- return buf + 1;
- else
- return buf;
-}
-
-static const char *
-get_symbol_other (Filedata * filedata, unsigned int other)
-{
- const char * result = NULL;
- static char buff [64];
-
- if (other == 0)
- return "";
-
- switch (filedata->file_header.e_machine)
- {
- case EM_ALPHA:
- result = get_alpha_symbol_other (other);
- break;
- case EM_AARCH64:
- result = get_aarch64_symbol_other (other);
- break;
- case EM_MIPS:
- result = get_mips_symbol_other (other);
- break;
- case EM_IA_64:
- result = get_ia64_symbol_other (filedata, other);
- break;
- case EM_PPC64:
- result = get_ppc64_symbol_other (other);
- break;
- case EM_RISCV:
- result = get_riscv_symbol_other (other);
- break;
- default:
- result = NULL;
- break;
- }
-
- if (result)
- return result;
-
- snprintf (buff, sizeof buff, _("<other>: %x"), other);
- return buff;
-}
-
-static const char *
-get_symbol_version_string (Filedata *filedata,
- bool is_dynsym,
- const char *strtab,
- size_t strtab_size,
- unsigned int si,
- Elf_Internal_Sym *psym,
- enum versioned_symbol_info *sym_info,
- unsigned short *vna_other)
-{
- unsigned char data[2];
- unsigned short vers_data;
- uint64_t offset;
- unsigned short max_vd_ndx;
-
- if (!is_dynsym
- || filedata->version_info[DT_VERSIONTAGIDX (DT_VERSYM)] == 0)
- return NULL;
-
- offset = offset_from_vma (filedata,
- filedata->version_info[DT_VERSIONTAGIDX (DT_VERSYM)],
- sizeof data + si * sizeof (vers_data));
-
- if (get_data (&data, filedata, offset + si * sizeof (vers_data),
- sizeof (data), 1, _("version data")) == NULL)
- return NULL;
-
- vers_data = byte_get (data, 2);
-
- if ((vers_data & VERSYM_HIDDEN) == 0 && vers_data == 0)
- return NULL;
-
- *sym_info = (vers_data & VERSYM_HIDDEN) != 0 ? symbol_hidden : symbol_public;
- max_vd_ndx = 0;
-
- /* Usually we'd only see verdef for defined symbols, and verneed for
- undefined symbols. However, symbols defined by the linker in
- .dynbss for variables copied from a shared library in order to
- avoid text relocations are defined yet have verneed. We could
- use a heuristic to detect the special case, for example, check
- for verneed first on symbols defined in SHT_NOBITS sections, but
- it is simpler and more reliable to just look for both verdef and
- verneed. .dynbss might not be mapped to a SHT_NOBITS section. */
-
- if (psym->st_shndx != SHN_UNDEF
- && vers_data != 0x8001
- && filedata->version_info[DT_VERSIONTAGIDX (DT_VERDEF)])
- {
- Elf_Internal_Verdef ivd;
- Elf_Internal_Verdaux ivda;
- Elf_External_Verdaux evda;
- uint64_t off;
-
- off = offset_from_vma (filedata,
- filedata->version_info[DT_VERSIONTAGIDX (DT_VERDEF)],
- sizeof (Elf_External_Verdef));
-
- do
- {
- Elf_External_Verdef evd;
-
- if (get_data (&evd, filedata, off, sizeof (evd), 1,
- _("version def")) == NULL)
- {
- ivd.vd_ndx = 0;
- ivd.vd_aux = 0;
- ivd.vd_next = 0;
- ivd.vd_flags = 0;
- }
- else
- {
- ivd.vd_ndx = BYTE_GET (evd.vd_ndx);
- ivd.vd_aux = BYTE_GET (evd.vd_aux);
- ivd.vd_next = BYTE_GET (evd.vd_next);
- ivd.vd_flags = BYTE_GET (evd.vd_flags);
- }
-
- if ((ivd.vd_ndx & VERSYM_VERSION) > max_vd_ndx)
- max_vd_ndx = ivd.vd_ndx & VERSYM_VERSION;
-
- off += ivd.vd_next;
- }
- while (ivd.vd_ndx != (vers_data & VERSYM_VERSION) && ivd.vd_next != 0);
-
- if (ivd.vd_ndx == (vers_data & VERSYM_VERSION))
- {
- if (ivd.vd_ndx == 1 && ivd.vd_flags == VER_FLG_BASE)
- return NULL;
-
- off -= ivd.vd_next;
- off += ivd.vd_aux;
-
- if (get_data (&evda, filedata, off, sizeof (evda), 1,
- _("version def aux")) != NULL)
- {
- ivda.vda_name = BYTE_GET (evda.vda_name);
-
- if (psym->st_name != ivda.vda_name)
- return (ivda.vda_name < strtab_size
- ? strtab + ivda.vda_name : _("<corrupt>"));
- }
- }
- }
-
- if (filedata->version_info[DT_VERSIONTAGIDX (DT_VERNEED)])
- {
- Elf_External_Verneed evn;
- Elf_Internal_Verneed ivn;
- Elf_Internal_Vernaux ivna;
-
- offset = offset_from_vma (filedata,
- filedata->version_info[DT_VERSIONTAGIDX (DT_VERNEED)],
- sizeof evn);
- do
- {
- uint64_t vna_off;
-
- if (get_data (&evn, filedata, offset, sizeof (evn), 1,
- _("version need")) == NULL)
- {
- ivna.vna_next = 0;
- ivna.vna_other = 0;
- ivna.vna_name = 0;
- break;
- }
-
- ivn.vn_aux = BYTE_GET (evn.vn_aux);
- ivn.vn_next = BYTE_GET (evn.vn_next);
-
- vna_off = offset + ivn.vn_aux;
-
- do
- {
- Elf_External_Vernaux evna;
-
- if (get_data (&evna, filedata, vna_off, sizeof (evna), 1,
- _("version need aux (3)")) == NULL)
- {
- ivna.vna_next = 0;
- ivna.vna_other = 0;
- ivna.vna_name = 0;
- }
- else
- {
- ivna.vna_other = BYTE_GET (evna.vna_other);
- ivna.vna_next = BYTE_GET (evna.vna_next);
- ivna.vna_name = BYTE_GET (evna.vna_name);
- }
-
- vna_off += ivna.vna_next;
- }
- while (ivna.vna_other != vers_data && ivna.vna_next != 0);
-
- if (ivna.vna_other == vers_data)
- break;
-
- offset += ivn.vn_next;
- }
- while (ivn.vn_next != 0);
-
- if (ivna.vna_other == vers_data)
- {
- *sym_info = symbol_undefined;
- *vna_other = ivna.vna_other;
- return (ivna.vna_name < strtab_size
- ? strtab + ivna.vna_name : _("<corrupt>"));
- }
- else if ((max_vd_ndx || (vers_data & VERSYM_VERSION) != 1)
- && (vers_data & VERSYM_VERSION) > max_vd_ndx)
- return _("<corrupt>");
- }
- return NULL;
-}
-
-/* Display a symbol size on stdout. Format is based on --sym-base setting. */
-
-static unsigned int
-print_symbol_size (uint64_t vma, int base)
-{
- switch (base)
- {
- case 8:
- return print_vma (vma, OCTAL_5);
-
- case 10:
- return print_vma (vma, UNSIGNED_5);
-
- case 16:
- return print_vma (vma, PREFIX_HEX_5);
-
- case 0:
- default:
- return print_vma (vma, DEC_5);
- }
-}
-
-/* Print information on a single symbol. */
-
-static void
-print_symbol (Filedata * filedata,
- uint64_t symbol_index,
- Elf_Internal_Sym * symtab,
- Elf_Internal_Shdr * section,
- char * strtab,
- size_t strtab_size)
-{
- const char *version_string;
- enum versioned_symbol_info sym_info;
- unsigned short vna_other;
- const char * sstr;
- Elf_Internal_Sym *psym = symtab + symbol_index;
-
- /* FIXME: We should have a table of field widths,
- rather than using hard coded constants. */
- printf ("%6" PRId64 ": ", symbol_index);
- print_vma (psym->st_value, LONG_HEX);
- putchar (' ');
- print_symbol_size (psym->st_size, sym_base);
- printf (" %-7s", get_symbol_type (filedata, ELF_ST_TYPE (psym->st_info)));
- printf (" %-6s", get_symbol_binding (filedata, ELF_ST_BIND (psym->st_info)));
- if (filedata->file_header.e_ident[EI_OSABI] == ELFOSABI_SOLARIS)
- printf (" %-7s", get_solaris_symbol_visibility (psym->st_other));
- else
- {
- unsigned int vis = ELF_ST_VISIBILITY (psym->st_other);
-
- printf (" %-7s", get_symbol_visibility (vis));
-
- /* Check to see if any other bits in the st_other field are set.
- FIXME: Displaying this information here disrupts the layout
- of the table being generated. */
- if (psym->st_other ^ vis)
- printf (" [%s] ", get_symbol_other (filedata, psym->st_other ^ vis));
- }
-
- bool is_special;
-
- sstr = printable_section_name_from_index (filedata, psym->st_shndx, & is_special);
-
- /* Print the symbol's section index. If the index is special
- then print the index's name rather than its number. */
- if (is_special)
- {
- int printed;
-
- /* Special case: If there are no section headers, and the printable
- name is "<section 0x...." then just display the section number
- as a decimal. This happens when objcopy --strip -section-headers
- is used. */
- if (filedata->file_header.e_shnum == 0 && startswith (sstr, "<section"))
- printed = printf (" %4d ", psym->st_shndx);
- else
- printed = printf (" %4s ", sstr);
-
- if (extra_sym_info && printed < 16)
- printf ("%*s", 16 - printed, "");
- }
- else
- {
- printf (" %4u ", psym->st_shndx);
-
- if (extra_sym_info)
- {
- /* Display the section name referenced by the section index. */
- int printed = printf ("(%s) ", sstr);
- if (printed < 10)
- printf ("%*s", 10 - printed, "");
- }
- }
-
- /* Get the symbol's name. For section symbols without a
- specific name use the (already computed) section name. */
- if (ELF_ST_TYPE (psym->st_info) == STT_SECTION
- && section_index_real (filedata, psym->st_shndx)
- && psym->st_name == 0)
- {
- ;
- }
- else
- {
- bool is_valid;
-
- is_valid = valid_symbol_name (strtab, strtab_size, psym->st_name);
- sstr = is_valid ? strtab + psym->st_name : _("<corrupt>");
- }
-
- version_string
- = get_symbol_version_string (filedata,
- (section == NULL
- || section->sh_type == SHT_DYNSYM),
- strtab, strtab_size, symbol_index,
- psym, &sym_info, &vna_other);
-
- int len_avail = 21;
- if (! do_wide && version_string != NULL)
- {
- char buffer[16];
-
- len_avail -= 1 + strlen (version_string);
-
- if (sym_info == symbol_undefined)
- len_avail -= sprintf (buffer," (%d)", vna_other);
- else if (sym_info != symbol_hidden)
- len_avail -= 1;
- }
-
- print_symbol_name (len_avail, sstr);
-
- if (version_string)
- {
- if (sym_info == symbol_undefined)
- printf ("@%s (%d)", version_string, vna_other);
- else
- printf (sym_info == symbol_hidden ? "@%s" : "@@%s",
- version_string);
- }
-
- putchar ('\n');
-
- if (ELF_ST_BIND (psym->st_info) == STB_LOCAL
- && section != NULL
- && symbol_index >= section->sh_info
- /* Irix 5 and 6 MIPS binaries are known to ignore this requirement. */
- && filedata->file_header.e_machine != EM_MIPS
- /* Solaris binaries have been found to violate this requirement as
- well. Not sure if this is a bug or an ABI requirement. */
- && filedata->file_header.e_ident[EI_OSABI] != ELFOSABI_SOLARIS)
- warn (_("local symbol %" PRIu64 " found at index >= %s's sh_info value of %u\n"),
- symbol_index, printable_section_name (filedata, section), section->sh_info);
-}
-
-static const char *
-get_lto_kind (unsigned int kind)
-{
- switch (kind)
- {
- case 0: return "DEF";
- case 1: return "WEAKDEF";
- case 2: return "UNDEF";
- case 3: return "WEAKUNDEF";
- case 4: return "COMMON";
- default:
- break;
- }
-
- static char buffer[30];
- error (_("Unknown LTO symbol definition encountered: %u\n"), kind);
- sprintf (buffer, "<unknown: %u>", kind);
- return buffer;
-}
-
-static const char *
-get_lto_visibility (unsigned int visibility)
-{
- switch (visibility)
- {
- case 0: return "DEFAULT";
- case 1: return "PROTECTED";
- case 2: return "INTERNAL";
- case 3: return "HIDDEN";
- default:
- break;
- }
-
- static char buffer[30];
- error (_("Unknown LTO symbol visibility encountered: %u\n"), visibility);
- sprintf (buffer, "<unknown: %u>", visibility);
- return buffer;
-}
-
-static const char *
-get_lto_sym_type (unsigned int sym_type)
-{
- switch (sym_type)
- {
- case 0: return "UNKNOWN";
- case 1: return "FUNCTION";
- case 2: return "VARIABLE";
- default:
- break;
- }
-
- static char buffer[30];
- error (_("Unknown LTO symbol type encountered: %u\n"), sym_type);
- sprintf (buffer, "<unknown: %u>", sym_type);
- return buffer;
-}
-
-/* Display an LTO format symbol table.
- FIXME: The format of LTO symbol tables is not formalized.
- So this code could need changing in the future. */
-
-static bool
-display_lto_symtab (Filedata * filedata,
- Elf_Internal_Shdr * section)
-{
- if (section->sh_size == 0)
- {
- if (filedata->is_separate)
- printf (_("\nThe LTO Symbol table section '%s' in linked file '%s' is empty!\n"),
- printable_section_name (filedata, section),
- filedata->file_name);
- else
- printf (_("\nLTO Symbol table '%s' is empty!\n"),
- printable_section_name (filedata, section));
-
- return true;
- }
-
- if (section->sh_size > filedata->file_size)
- {
- error (_("Section %s has an invalid sh_size of %#" PRIx64 "\n"),
- printable_section_name (filedata, section),
- section->sh_size);
- return false;
- }
-
- void * alloced_data = get_data (NULL, filedata, section->sh_offset,
- section->sh_size, 1, _("LTO symbols"));
- if (alloced_data == NULL)
- return false;
-
- /* Look for extended data for the symbol table. */
- Elf_Internal_Shdr * ext = NULL;
- void * ext_data_orig = NULL;
- char * ext_data = NULL;
- char * ext_data_end = NULL;
- char * ext_name = NULL;
-
- if (asprintf (& ext_name, ".gnu.lto_.ext_symtab.%s",
- (section_name (filedata, section)
- + sizeof (".gnu.lto_.symtab.") - 1)) > 0
- && ext_name != NULL /* Paranoia. */
- && (ext = find_section (filedata, ext_name)) != NULL)
- {
- if (ext->sh_size < 3)
- error (_("LTO Symbol extension table '%s' is empty!\n"),
- printable_section_name (filedata, ext));
- else
- {
- ext_data_orig = ext_data = get_data (NULL, filedata, ext->sh_offset,
- ext->sh_size, 1,
- _("LTO ext symbol data"));
- if (ext_data != NULL)
- {
- ext_data_end = ext_data + ext->sh_size;
- if (* ext_data++ != 1)
- error (_("Unexpected version number in symbol extension table\n"));
- }
- }
- }
-
- const unsigned char * data = (const unsigned char *) alloced_data;
- const unsigned char * end = data + section->sh_size;
-
- if (filedata->is_separate)
- printf (_("\nIn linked file '%s': "), filedata->file_name);
- else
- printf ("\n");
-
- if (ext_data_orig != NULL)
- {
- if (do_wide)
- printf (_("LTO Symbol table '%s' and extension table '%s' contain:\n"),
- printable_section_name (filedata, section),
- printable_section_name (filedata, ext));
- else
- {
- printf (_("LTO Symbol table '%s'\n"),
- printable_section_name (filedata, section));
- printf (_(" and extension table '%s' contain:\n"),
- printable_section_name (filedata, ext));
- }
- }
- else
- printf (_("LTO Symbol table '%s' contains:\n"),
- printable_section_name (filedata, section));
-
- /* FIXME: Add a wide version. */
- if (ext_data_orig != NULL)
- printf (_(" Comdat_Key Kind Visibility Size Slot Type Section Name\n"));
- else
- printf (_(" Comdat_Key Kind Visibility Size Slot Name\n"));
-
- /* FIXME: We do not handle style prefixes. */
-
- while (data < end)
- {
- const unsigned char * sym_name = data;
- data += strnlen ((const char *) sym_name, end - data) + 1;
- if (data >= end)
- goto fail;
-
- const unsigned char * comdat_key = data;
- data += strnlen ((const char *) comdat_key, end - data) + 1;
- if (data >= end)
- goto fail;
-
- if (data + 2 + 8 + 4 > end)
- goto fail;
-
- unsigned int kind = *data++;
- unsigned int visibility = *data++;
-
- uint64_t size = byte_get (data, 8);
- data += 8;
-
- uint64_t slot = byte_get (data, 4);
- data += 4;
-
- if (ext_data != NULL)
- {
- if (ext_data < (ext_data_end - 1))
- {
- unsigned int sym_type = * ext_data ++;
- unsigned int sec_kind = * ext_data ++;
-
- printf (" %10s %10s %11s %08" PRIx64 " %08" PRIx64 " %9s %08x _",
- * comdat_key == 0 ? "-" : (char *) comdat_key,
- get_lto_kind (kind),
- get_lto_visibility (visibility),
- size,
- slot,
- get_lto_sym_type (sym_type),
- sec_kind);
- print_symbol_name (6, (const char *) sym_name);
- }
- else
- {
- error (_("Ran out of LTO symbol extension data\n"));
- ext_data = NULL;
- /* FIXME: return FAIL result ? */
- }
- }
- else
- {
- printf (" %10s %10s %11s %08" PRIx64 " %08" PRIx64 " _",
- * comdat_key == 0 ? "-" : (char *) comdat_key,
- get_lto_kind (kind),
- get_lto_visibility (visibility),
- size,
- slot);
- print_symbol_name (21, (const char *) sym_name);
- }
- putchar ('\n');
- }
-
- if (ext_data != NULL && ext_data < ext_data_end)
- {
- error (_("Data remains in the LTO symbol extension table\n"));
- goto fail;
- }
-
- free (alloced_data);
- free (ext_data_orig);
- free (ext_name);
- return true;
-
- fail:
- error (_("Buffer overrun encountered whilst decoding LTO symbol table\n"));
- free (alloced_data);
- free (ext_data_orig);
- free (ext_name);
- return false;
-}
-
-/* Display LTO symbol tables. */
-
-static bool
-process_lto_symbol_tables (Filedata * filedata)
-{
- Elf_Internal_Shdr * section;
- unsigned int i;
- bool res = true;
-
- if (!do_lto_syms)
- return true;
-
- if (filedata->section_headers == NULL)
- return true;
-
- for (i = 0, section = filedata->section_headers;
- i < filedata->file_header.e_shnum;
- i++, section++)
- if (section_name_valid (filedata, section)
- && startswith (section_name (filedata, section), ".gnu.lto_.symtab."))
- res &= display_lto_symtab (filedata, section);
-
- return res;
-}
-
-static void
-print_symbol_table_heading (void)
-{
- /* FIXME: We should store the size of each field in the display in a table and
- then use the values inside print_symbol(), instead of that function using
- hard coded constants. */
- if (is_32bit_elf)
- {
- if (extra_sym_info)
- {
- printf (_(" Num: Value Size Type Bind Vis+Other Ndx(SecName) Name [+ Version Info]\n"));
- /* |--6-|: |--8---| |-5-| |--7--| |-6--| |--7--| |---8--| |----13.....| |........... */
- /* eg: 5: 00000000 14 FUNC LOCAL DEFAULT 1 (.text) get_sections */
- }
- else if (do_wide)
- {
- printf (_(" Num: Value Size Type Bind Vis Ndx Name\n"));
- /* |--6-|: |--8---| |-5-| |--7--| |-6--| |--7--| |-4| |........... */
- /* eg: 5: 00000000 14 FUNC LOCAL DEFAULT 1 get_sections */
- }
- else
- {
- printf (_(" Num: Value Size Type Bind Vis Ndx Name\n"));
- /* |--6-|: |--8---| |-5-| |--7--| |-6--| |--7--| |-4| |------------29-------------| */
- /* eg: 5: 00000000 14 FUNC LOCAL DEFAULT 1 get_sections */
- }
- }
- else
- {
- if (extra_sym_info)
- {
- printf (_(" Num: Value Size Type Bind Vis+Other Ndx(SecName) Name [+ Version Info]\n"));
- /* |--6-|: |------16------| |-5-| |--7--| |-6--| |--7--| |-------14---| |..... */
- /* eg: 2: 0000000000000000 0 FUNC LOCAL DEFAULT 1 (.text) .very_long_function_name */
-
- }
- else if (do_wide)
- {
- printf (_(" Num: Value Size Type Bind Vis Ndx Name\n"));
- /* |--6-|: |------16------| |-5-| |--7--| |-6--| |--7--| |-4| |........... */
- /* eg: 5: 0000000000000000 14 FUNC LOCAL DEFAULT 1 very_long_function_name */
- }
- else
- {
- printf (_(" Num: Value Size Type Bind Vis Ndx Name\n"));
- /* |--6-|: |------16------| |-5-| |--7--| |-6--| |--7--| |-4| |--------21---------| */
- /* eg: 5: 0000000000000000 14 FUNC LOCAL DEFAULT 1 very_long_functi[...] */
- }
- }
-}
-
-static bool
-dump_symbol_section (Elf_Internal_Shdr * section,
- Filedata * filedata)
-{
- if (section->sh_entsize == 0)
- {
- printf (_("\nSymbol table '%s' has a sh_entsize of zero!\n"),
- printable_section_name (filedata, section));
- return false;
- }
-
- uint64_t num_syms = section->sh_size / section->sh_entsize;
-
- if (filedata->is_separate)
- printf (ngettext ("\nIn linked file '%s' symbol section '%s'"
- " contains %" PRIu64 " entry:\n",
- "\nIn linked file '%s' symbol section '%s'"
- " contains %" PRIu64 " entries:\n",
- num_syms),
- filedata->file_name,
- printable_section_name (filedata, section),
- num_syms);
- else
- printf (ngettext ("\nSymbol table '%s' contains %" PRIu64
- " entry:\n",
- "\nSymbol table '%s' contains %" PRIu64
- " entries:\n",
- num_syms),
- printable_section_name (filedata, section),
- num_syms);
-
- print_symbol_table_heading ();
-
- Elf_Internal_Sym * symtab = get_elf_symbols (filedata, section, & num_syms);
- if (symtab == NULL)
- /* An error message will have already been displayed. */
- return false;
-
- char * strtab = NULL;
- uint64_t strtab_size = 0;
-
- if (section->sh_link == filedata->file_header.e_shstrndx)
- {
- strtab = filedata->string_table;
- strtab_size = filedata->string_table_length;
- }
- else if (section->sh_link < filedata->file_header.e_shnum)
- {
- Elf_Internal_Shdr * string_sec;
-
- string_sec = filedata->section_headers + section->sh_link;
-
- strtab = (char *) get_data (NULL, filedata, string_sec->sh_offset,
- 1, string_sec->sh_size,
- _("string table"));
- strtab_size = strtab != NULL ? string_sec->sh_size : 0;
- }
-
- uint64_t si;
-
- for (si = 0; si < num_syms; si++)
- print_symbol (filedata, si, symtab, section, strtab, strtab_size);
-
- free (symtab);
-
- if (strtab != filedata->string_table)
- free (strtab);
-
- return true;
-}
-
-/* Dump the symbol table. */
-
-static bool
-process_symbol_table (Filedata * filedata)
-{
- Elf_Internal_Shdr * section;
-
- if (!do_syms && !do_dyn_syms && !do_histogram)
- return true;
-
- if ((filedata->dynamic_info[DT_HASH] || filedata->dynamic_info_DT_GNU_HASH)
- && do_syms
- && do_using_dynamic
- && filedata->dynamic_strings != NULL
- && filedata->dynamic_symbols != NULL)
- {
- uint64_t si;
-
- if (filedata->is_separate)
- {
- printf (ngettext ("\nIn linked file '%s' the dynamic symbol table"
- " contains %" PRIu64 " entry:\n",
- "\nIn linked file '%s' the dynamic symbol table"
- " contains %" PRIu64 " entries:\n",
- filedata->num_dynamic_syms),
- filedata->file_name,
- filedata->num_dynamic_syms);
- }
- else
- {
- printf (ngettext ("\nSymbol table for image contains %" PRIu64
- " entry:\n",
- "\nSymbol table for image contains %" PRIu64
- " entries:\n",
- filedata->num_dynamic_syms),
- filedata->num_dynamic_syms);
- }
-
- print_symbol_table_heading ();
-
- for (si = 0; si < filedata->num_dynamic_syms; si++)
- print_symbol (filedata, si, filedata->dynamic_symbols, NULL,
- filedata->dynamic_strings,
- filedata->dynamic_strings_length);
- }
- else if ((do_dyn_syms || (do_syms && !do_using_dynamic))
- && filedata->section_headers != NULL)
- {
- unsigned int i;
-
- for (i = 0, section = filedata->section_headers;
- i < filedata->file_header.e_shnum;
- i++, section++)
- {
- if ((section->sh_type != SHT_SYMTAB
- && section->sh_type != SHT_DYNSYM)
- || (!do_syms
- && section->sh_type == SHT_SYMTAB))
- continue;
-
- dump_symbol_section (section, filedata);
- }
- }
- else if (do_syms)
- printf
- (_("\nDynamic symbol information is not available for displaying symbols.\n"));
-
- if (do_histogram && filedata->buckets != NULL)
- {
- uint64_t *lengths;
- uint64_t *counts;
- uint64_t hn;
- uint64_t si;
- uint64_t maxlength = 0;
- uint64_t nzero_counts = 0;
- uint64_t nsyms = 0;
- char *visited;
-
- printf (ngettext ("\nHistogram for bucket list length "
- "(total of %" PRIu64 " bucket):\n",
- "\nHistogram for bucket list length "
- "(total of %" PRIu64 " buckets):\n",
- filedata->nbuckets),
- filedata->nbuckets);
-
- lengths = calloc (filedata->nbuckets, sizeof (*lengths));
- if (lengths == NULL)
- {
- error (_("Out of memory allocating space for histogram buckets\n"));
- goto err_out;
- }
- visited = xcmalloc (filedata->nchains, 1);
- memset (visited, 0, filedata->nchains);
-
- printf (_(" Length Number %% of total Coverage\n"));
- for (hn = 0; hn < filedata->nbuckets; ++hn)
- {
- for (si = filedata->buckets[hn]; si > 0; si = filedata->chains[si])
- {
- ++nsyms;
- if (maxlength < ++lengths[hn])
- ++maxlength;
- if (si >= filedata->nchains || visited[si])
- {
- error (_("histogram chain is corrupt\n"));
- break;
- }
- visited[si] = 1;
- }
- }
- free (visited);
-
- counts = calloc (maxlength + 1, sizeof (*counts));
- if (counts == NULL)
- {
- free (lengths);
- error (_("Out of memory allocating space for histogram counts\n"));
- goto err_out;
- }
-
- for (hn = 0; hn < filedata->nbuckets; ++hn)
- ++counts[lengths[hn]];
-
- if (filedata->nbuckets > 0)
- {
- uint64_t i;
- printf (" 0 %-10" PRIu64 " (%5.1f%%)\n",
- counts[0], (counts[0] * 100.0) / filedata->nbuckets);
- for (i = 1; i <= maxlength; ++i)
- {
- nzero_counts += counts[i] * i;
- printf ("%7" PRIu64 " %-10" PRIu64 " (%5.1f%%) %5.1f%%\n",
- i, counts[i], (counts[i] * 100.0) / filedata->nbuckets,
- (nzero_counts * 100.0) / nsyms);
- }
- }
-
- free (counts);
- free (lengths);
- }
-
- free (filedata->buckets);
- filedata->buckets = NULL;
- filedata->nbuckets = 0;
- free (filedata->chains);
- filedata->chains = NULL;
-
- if (do_histogram && filedata->gnubuckets != NULL)
- {
- uint64_t *lengths;
- uint64_t *counts;
- uint64_t hn;
- uint64_t maxlength = 0;
- uint64_t nzero_counts = 0;
- uint64_t nsyms = 0;
-
- printf (ngettext ("\nHistogram for `%s' bucket list length "
- "(total of %" PRIu64 " bucket):\n",
- "\nHistogram for `%s' bucket list length "
- "(total of %" PRIu64 " buckets):\n",
- filedata->ngnubuckets),
- GNU_HASH_SECTION_NAME (filedata),
- filedata->ngnubuckets);
-
- lengths = calloc (filedata->ngnubuckets, sizeof (*lengths));
- if (lengths == NULL)
- {
- error (_("Out of memory allocating space for gnu histogram buckets\n"));
- goto err_out;
- }
-
- printf (_(" Length Number %% of total Coverage\n"));
-
- for (hn = 0; hn < filedata->ngnubuckets; ++hn)
- if (filedata->gnubuckets[hn] != 0)
- {
- uint64_t off, length = 1;
-
- for (off = filedata->gnubuckets[hn] - filedata->gnusymidx;
- /* PR 17531 file: 010-77222-0.004. */
- off < filedata->ngnuchains
- && (filedata->gnuchains[off] & 1) == 0;
- ++off)
- ++length;
- lengths[hn] = length;
- if (length > maxlength)
- maxlength = length;
- nsyms += length;
- }
-
- counts = calloc (maxlength + 1, sizeof (*counts));
- if (counts == NULL)
- {
- free (lengths);
- error (_("Out of memory allocating space for gnu histogram counts\n"));
- goto err_out;
- }
-
- for (hn = 0; hn < filedata->ngnubuckets; ++hn)
- ++counts[lengths[hn]];
-
- if (filedata->ngnubuckets > 0)
- {
- uint64_t j;
- printf (" 0 %-10" PRIu64 " (%5.1f%%)\n",
- counts[0], (counts[0] * 100.0) / filedata->ngnubuckets);
- for (j = 1; j <= maxlength; ++j)
- {
- nzero_counts += counts[j] * j;
- printf ("%7" PRIu64 " %-10" PRIu64 " (%5.1f%%) %5.1f%%\n",
- j, counts[j], (counts[j] * 100.0) / filedata->ngnubuckets,
- (nzero_counts * 100.0) / nsyms);
- }
- }
-
- free (counts);
- free (lengths);
- }
- free (filedata->gnubuckets);
- filedata->gnubuckets = NULL;
- filedata->ngnubuckets = 0;
- free (filedata->gnuchains);
- filedata->gnuchains = NULL;
- filedata->ngnuchains = 0;
- free (filedata->mipsxlat);
- filedata->mipsxlat = NULL;
- return true;
-
- err_out:
- free (filedata->gnubuckets);
- filedata->gnubuckets = NULL;
- filedata->ngnubuckets = 0;
- free (filedata->gnuchains);
- filedata->gnuchains = NULL;
- filedata->ngnuchains = 0;
- free (filedata->mipsxlat);
- filedata->mipsxlat = NULL;
- free (filedata->buckets);
- filedata->buckets = NULL;
- filedata->nbuckets = 0;
- free (filedata->chains);
- filedata->chains = NULL;
- return false;
-}
-
-static bool
-process_syminfo (Filedata * filedata)
-{
- unsigned int i;
-
- if (filedata->dynamic_syminfo == NULL
- || !do_dynamic)
- /* No syminfo, this is ok. */
- return true;
-
- /* There better should be a dynamic symbol section. */
- if (filedata->dynamic_symbols == NULL || filedata->dynamic_strings == NULL)
- return false;
-
- if (filedata->is_separate)
- printf (ngettext ("\nIn linked file '%s: the dynamic info segment at offset %#" PRIx64 " contains %d entry:\n",
- "\nIn linked file '%s: the dynamic info segment at offset %#" PRIx64 " contains %d entries:\n",
- filedata->dynamic_syminfo_nent),
- filedata->file_name,
- filedata->dynamic_syminfo_offset,
- filedata->dynamic_syminfo_nent);
- else
- printf (ngettext ("\nDynamic info segment at offset %#" PRIx64
- " contains %d entry:\n",
- "\nDynamic info segment at offset %#" PRIx64
- " contains %d entries:\n",
- filedata->dynamic_syminfo_nent),
- filedata->dynamic_syminfo_offset,
- filedata->dynamic_syminfo_nent);
-
- printf (_(" Num: Name BoundTo Flags\n"));
- for (i = 0; i < filedata->dynamic_syminfo_nent; ++i)
- {
- unsigned short int flags = filedata->dynamic_syminfo[i].si_flags;
-
- printf ("%4d: ", i);
- if (i >= filedata->num_dynamic_syms)
- printf (_("<corrupt index>"));
- else if (valid_dynamic_name (filedata, filedata->dynamic_symbols[i].st_name))
- print_symbol_name (30, get_dynamic_name (filedata,
- filedata->dynamic_symbols[i].st_name));
- else
- printf (_("<corrupt: %19ld>"), filedata->dynamic_symbols[i].st_name);
- putchar (' ');
-
- switch (filedata->dynamic_syminfo[i].si_boundto)
- {
- case SYMINFO_BT_SELF:
- fputs ("SELF ", stdout);
- break;
- case SYMINFO_BT_PARENT:
- fputs ("PARENT ", stdout);
- break;
- default:
- if (filedata->dynamic_syminfo[i].si_boundto > 0
- && filedata->dynamic_syminfo[i].si_boundto < filedata->dynamic_nent
- && valid_dynamic_name (filedata,
- filedata->dynamic_section[filedata->dynamic_syminfo[i].si_boundto].d_un.d_val))
- {
- print_symbol_name (10, get_dynamic_name (filedata,
- filedata->dynamic_section[filedata->dynamic_syminfo[i].si_boundto].d_un.d_val));
- putchar (' ' );
- }
- else
- printf ("%-10d ", filedata->dynamic_syminfo[i].si_boundto);
- break;
- }
-
- if (flags & SYMINFO_FLG_DIRECT)
- printf (" DIRECT");
- if (flags & SYMINFO_FLG_PASSTHRU)
- printf (" PASSTHRU");
- if (flags & SYMINFO_FLG_COPY)
- printf (" COPY");
- if (flags & SYMINFO_FLG_LAZYLOAD)
- printf (" LAZYLOAD");
-
- puts ("");
- }
-
- return true;
-}
-
-/* A macro which evaluates to TRUE if the region ADDR .. ADDR + NELEM
- is contained by the region START .. END. The types of ADDR, START
- and END should all be the same. Note both ADDR + NELEM and END
- point to just beyond the end of the regions that are being tested. */
-#define IN_RANGE(START,END,ADDR,NELEM) \
- (((ADDR) >= (START)) && ((ADDR) < (END)) && ((ADDR) + (NELEM) <= (END)))
-
-/* Check to see if the given reloc needs to be handled in a target specific
- manner. If so then process the reloc and return TRUE otherwise return
- FALSE.
-
- If called with reloc == NULL, then this is a signal that reloc processing
- for the current section has finished, and any saved state should be
- discarded. */
-
-static bool
-target_specific_reloc_handling (Filedata *filedata,
- Elf_Internal_Rela *reloc,
- unsigned char *start,
- unsigned char *end,
- Elf_Internal_Sym *symtab,
- uint64_t num_syms)
-{
- unsigned int reloc_type = 0;
- uint64_t sym_index = 0;
-
- if (reloc)
- {
- reloc_type = get_reloc_type (filedata, reloc->r_info);
- sym_index = get_reloc_symindex (reloc->r_info);
- }
-
- switch (filedata->file_header.e_machine)
- {
- case EM_LOONGARCH:
- {
- switch (reloc_type)
- {
- /* For .uleb128 .LFE1-.LFB1, loongarch write 0 to object file
- at assembly time. */
- case 107: /* R_LARCH_ADD_ULEB128. */
- case 108: /* R_LARCH_SUB_ULEB128. */
- {
- uint64_t value = 0;
- unsigned int reloc_size = 0;
- int leb_ret = 0;
-
- if (reloc->r_offset < (size_t) (end - start))
- value = read_leb128 (start + reloc->r_offset, end, false,
- &reloc_size, &leb_ret);
- if (leb_ret != 0 || reloc_size == 0 || reloc_size > 8)
- error (_("LoongArch ULEB128 field at 0x%lx contains invalid "
- "ULEB128 value\n"),
- (long) reloc->r_offset);
-
- else if (sym_index >= num_syms)
- error (_("%s reloc contains invalid symbol index "
- "%" PRIu64 "\n"),
- (reloc_type == 107
- ? "R_LARCH_ADD_ULEB128"
- : "R_LARCH_SUB_ULEB128"),
- sym_index);
- else
- {
- if (reloc_type == 107)
- value += reloc->r_addend + symtab[sym_index].st_value;
- else
- value -= reloc->r_addend + symtab[sym_index].st_value;
-
- /* Write uleb128 value to p. */
- bfd_byte *p = start + reloc->r_offset;
- do
- {
- bfd_byte c = value & 0x7f;
- value >>= 7;
- if (--reloc_size != 0)
- c |= 0x80;
- *p++ = c;
- }
- while (reloc_size);
- }
-
- return true;
- }
- }
- break;
- }
-
- case EM_MSP430:
- case EM_MSP430_OLD:
- {
- static Elf_Internal_Sym * saved_sym = NULL;
-
- if (reloc == NULL)
- {
- saved_sym = NULL;
- return true;
- }
-
- switch (reloc_type)
- {
- case 10: /* R_MSP430_SYM_DIFF */
- case 12: /* R_MSP430_GNU_SUB_ULEB128 */
- if (uses_msp430x_relocs (filedata))
- break;
- /* Fall through. */
- case 21: /* R_MSP430X_SYM_DIFF */
- case 23: /* R_MSP430X_GNU_SUB_ULEB128 */
- /* PR 21139. */
- if (sym_index >= num_syms)
- error (_("%s reloc contains invalid symbol index "
- "%" PRIu64 "\n"), "MSP430 SYM_DIFF", sym_index);
- else
- saved_sym = symtab + sym_index;
- return true;
-
- case 1: /* R_MSP430_32 or R_MSP430_ABS32 */
- case 3: /* R_MSP430_16 or R_MSP430_ABS8 */
- goto handle_sym_diff;
-
- case 5: /* R_MSP430_16_BYTE */
- case 9: /* R_MSP430_8 */
- case 11: /* R_MSP430_GNU_SET_ULEB128 */
- if (uses_msp430x_relocs (filedata))
- break;
- goto handle_sym_diff;
-
- case 2: /* R_MSP430_ABS16 */
- case 15: /* R_MSP430X_ABS16 */
- case 22: /* R_MSP430X_GNU_SET_ULEB128 */
- if (! uses_msp430x_relocs (filedata))
- break;
- goto handle_sym_diff;
-
- handle_sym_diff:
- if (saved_sym != NULL)
- {
- uint64_t value;
- unsigned int reloc_size = 0;
- int leb_ret = 0;
- switch (reloc_type)
- {
- case 1: /* R_MSP430_32 or R_MSP430_ABS32 */
- reloc_size = 4;
- break;
- case 11: /* R_MSP430_GNU_SET_ULEB128 */
- case 22: /* R_MSP430X_GNU_SET_ULEB128 */
- if (reloc->r_offset < (size_t) (end - start))
- read_leb128 (start + reloc->r_offset, end, false,
- &reloc_size, &leb_ret);
- break;
- default:
- reloc_size = 2;
- break;
- }
-
- if (leb_ret != 0 || reloc_size == 0 || reloc_size > 8)
- error (_("MSP430 ULEB128 field at %#" PRIx64
- " contains invalid ULEB128 value\n"),
- reloc->r_offset);
- else if (sym_index >= num_syms)
- error (_("%s reloc contains invalid symbol index "
- "%" PRIu64 "\n"), "MSP430", sym_index);
- else
- {
- value = reloc->r_addend + (symtab[sym_index].st_value
- - saved_sym->st_value);
-
- if (IN_RANGE (start, end, start + reloc->r_offset, reloc_size))
- byte_put (start + reloc->r_offset, value, reloc_size);
- else
- /* PR 21137 */
- error (_("MSP430 sym diff reloc contains invalid offset: "
- "%#" PRIx64 "\n"),
- reloc->r_offset);
- }
-
- saved_sym = NULL;
- return true;
- }
- break;
-
- default:
- if (saved_sym != NULL)
- error (_("Unhandled MSP430 reloc type found after SYM_DIFF reloc\n"));
- break;
- }
- break;
- }
-
- case EM_MN10300:
- case EM_CYGNUS_MN10300:
- {
- static Elf_Internal_Sym * saved_sym = NULL;
-
- if (reloc == NULL)
- {
- saved_sym = NULL;
- return true;
- }
-
- switch (reloc_type)
- {
- case 34: /* R_MN10300_ALIGN */
- return true;
- case 33: /* R_MN10300_SYM_DIFF */
- if (sym_index >= num_syms)
- error (_("%s reloc contains invalid symbol index "
- "%" PRIu64 "\n"), "MN10300_SYM_DIFF", sym_index);
- else
- saved_sym = symtab + sym_index;
- return true;
-
- case 1: /* R_MN10300_32 */
- case 2: /* R_MN10300_16 */
- if (saved_sym != NULL)
- {
- int reloc_size = reloc_type == 1 ? 4 : 2;
- uint64_t value;
-
- if (sym_index >= num_syms)
- error (_("%s reloc contains invalid symbol index "
- "%" PRIu64 "\n"), "MN10300", sym_index);
- else
- {
- value = reloc->r_addend + (symtab[sym_index].st_value
- - saved_sym->st_value);
-
- if (IN_RANGE (start, end, start + reloc->r_offset, reloc_size))
- byte_put (start + reloc->r_offset, value, reloc_size);
- else
- error (_("MN10300 sym diff reloc contains invalid offset:"
- " %#" PRIx64 "\n"),
- reloc->r_offset);
- }
-
- saved_sym = NULL;
- return true;
- }
- break;
- default:
- if (saved_sym != NULL)
- error (_("Unhandled MN10300 reloc type found after SYM_DIFF reloc\n"));
- break;
- }
- break;
- }
-
- case EM_RL78:
- {
- static uint64_t saved_sym1 = 0;
- static uint64_t saved_sym2 = 0;
- static uint64_t value;
-
- if (reloc == NULL)
- {
- saved_sym1 = saved_sym2 = 0;
- return true;
- }
-
- switch (reloc_type)
- {
- case 0x80: /* R_RL78_SYM. */
- saved_sym1 = saved_sym2;
- if (sym_index >= num_syms)
- error (_("%s reloc contains invalid symbol index "
- "%" PRIu64 "\n"), "RL78_SYM", sym_index);
- else
- {
- saved_sym2 = symtab[sym_index].st_value;
- saved_sym2 += reloc->r_addend;
- }
- return true;
-
- case 0x83: /* R_RL78_OPsub. */
- value = saved_sym1 - saved_sym2;
- saved_sym2 = saved_sym1 = 0;
- return true;
- break;
-
- case 0x41: /* R_RL78_ABS32. */
- if (IN_RANGE (start, end, start + reloc->r_offset, 4))
- byte_put (start + reloc->r_offset, value, 4);
- else
- error (_("RL78 sym diff reloc contains invalid offset: "
- "%#" PRIx64 "\n"),
- reloc->r_offset);
- value = 0;
- return true;
-
- case 0x43: /* R_RL78_ABS16. */
- if (IN_RANGE (start, end, start + reloc->r_offset, 2))
- byte_put (start + reloc->r_offset, value, 2);
- else
- error (_("RL78 sym diff reloc contains invalid offset: "
- "%#" PRIx64 "\n"),
- reloc->r_offset);
- value = 0;
- return true;
-
- default:
- break;
- }
- break;
- }
- }
-
- return false;
-}
-
-/* Returns TRUE iff RELOC_TYPE is a 32-bit absolute RELA relocation used in
- DWARF debug sections. This is a target specific test. Note - we do not
- go through the whole including-target-headers-multiple-times route, (as
- we have already done with <elf/h8.h>) because this would become very
- messy and even then this function would have to contain target specific
- information (the names of the relocs instead of their numeric values).
- FIXME: This is not the correct way to solve this problem. The proper way
- is to have target specific reloc sizing and typing functions created by
- the reloc-macros.h header, in the same way that it already creates the
- reloc naming functions. */
-
-static bool
-is_32bit_abs_reloc (Filedata * filedata, unsigned int reloc_type)
-{
- /* Please keep this table alpha-sorted for ease of visual lookup. */
- switch (filedata->file_header.e_machine)
- {
- case EM_386:
- case EM_IAMCU:
- return reloc_type == 1; /* R_386_32. */
- case EM_68K:
- return reloc_type == 1; /* R_68K_32. */
- case EM_860:
- return reloc_type == 1; /* R_860_32. */
- case EM_960:
- return reloc_type == 2; /* R_960_32. */
- case EM_AARCH64:
- return (reloc_type == 258
- || reloc_type == 1); /* R_AARCH64_ABS32 || R_AARCH64_P32_ABS32 */
- case EM_BPF:
- return reloc_type == 11; /* R_BPF_DATA_32 */
- case EM_ADAPTEVA_EPIPHANY:
- return reloc_type == 3;
- case EM_ALPHA:
- return reloc_type == 1; /* R_ALPHA_REFLONG. */
- case EM_ARC:
- return reloc_type == 1; /* R_ARC_32. */
- case EM_ARC_COMPACT:
- case EM_ARC_COMPACT2:
- case EM_ARC_COMPACT3:
- case EM_ARC_COMPACT3_64:
- return reloc_type == 4; /* R_ARC_32. */
- case EM_ARM:
- return reloc_type == 2; /* R_ARM_ABS32 */
- case EM_AVR_OLD:
- case EM_AVR:
- return reloc_type == 1;
- case EM_BLACKFIN:
- return reloc_type == 0x12; /* R_byte4_data. */
- case EM_CRIS:
- return reloc_type == 3; /* R_CRIS_32. */
- case EM_CR16:
- return reloc_type == 3; /* R_CR16_NUM32. */
- case EM_CRX:
- return reloc_type == 15; /* R_CRX_NUM32. */
- case EM_CSKY:
- return reloc_type == 1; /* R_CKCORE_ADDR32. */
- case EM_CYGNUS_FRV:
- return reloc_type == 1;
- case EM_CYGNUS_D10V:
- case EM_D10V:
- return reloc_type == 6; /* R_D10V_32. */
- case EM_CYGNUS_D30V:
- case EM_D30V:
- return reloc_type == 12; /* R_D30V_32_NORMAL. */
- case EM_DLX:
- return reloc_type == 3; /* R_DLX_RELOC_32. */
- case EM_CYGNUS_FR30:
- case EM_FR30:
- return reloc_type == 3; /* R_FR30_32. */
- case EM_FT32:
- return reloc_type == 1; /* R_FT32_32. */
- case EM_H8S:
- case EM_H8_300:
- case EM_H8_300H:
- return reloc_type == 1; /* R_H8_DIR32. */
- case EM_IA_64:
- return (reloc_type == 0x64 /* R_IA64_SECREL32MSB. */
- || reloc_type == 0x65 /* R_IA64_SECREL32LSB. */
- || reloc_type == 0x24 /* R_IA64_DIR32MSB. */
- || reloc_type == 0x25 /* R_IA64_DIR32LSB. */);
- case EM_IP2K_OLD:
- case EM_IP2K:
- return reloc_type == 2; /* R_IP2K_32. */
- case EM_IQ2000:
- return reloc_type == 2; /* R_IQ2000_32. */
- case EM_KVX:
- return reloc_type == 2; /* R_KVX_32. */
- case EM_LATTICEMICO32:
- return reloc_type == 3; /* R_LM32_32. */
- case EM_LOONGARCH:
- return reloc_type == 1; /* R_LARCH_32. */
- case EM_M32C_OLD:
- case EM_M32C:
- return reloc_type == 3; /* R_M32C_32. */
- case EM_M32R:
- return reloc_type == 34; /* R_M32R_32_RELA. */
- case EM_68HC11:
- case EM_68HC12:
- return reloc_type == 6; /* R_M68HC11_32. */
- case EM_S12Z:
- return reloc_type == 7 || /* R_S12Z_EXT32 */
- reloc_type == 6; /* R_S12Z_CW32. */
- case EM_MCORE:
- return reloc_type == 1; /* R_MCORE_ADDR32. */
- case EM_CYGNUS_MEP:
- return reloc_type == 4; /* R_MEP_32. */
- case EM_METAG:
- return reloc_type == 2; /* R_METAG_ADDR32. */
- case EM_MICROBLAZE:
- return reloc_type == 1; /* R_MICROBLAZE_32. */
- case EM_MIPS:
- return reloc_type == 2; /* R_MIPS_32. */
- case EM_MMIX:
- return reloc_type == 4; /* R_MMIX_32. */
- case EM_CYGNUS_MN10200:
- case EM_MN10200:
- return reloc_type == 1; /* R_MN10200_32. */
- case EM_CYGNUS_MN10300:
- case EM_MN10300:
- return reloc_type == 1; /* R_MN10300_32. */
- case EM_MOXIE:
- return reloc_type == 1; /* R_MOXIE_32. */
- case EM_MSP430_OLD:
- case EM_MSP430:
- return reloc_type == 1; /* R_MSP430_32 or R_MSP320_ABS32. */
- case EM_MT:
- return reloc_type == 2; /* R_MT_32. */
- case EM_NDS32:
- return reloc_type == 20; /* R_NDS32_32_RELA. */
- case EM_ALTERA_NIOS2:
- return reloc_type == 12; /* R_NIOS2_BFD_RELOC_32. */
- case EM_NIOS32:
- return reloc_type == 1; /* R_NIOS_32. */
- case EM_OR1K:
- return reloc_type == 1; /* R_OR1K_32. */
- case EM_PARISC:
- return (reloc_type == 1 /* R_PARISC_DIR32. */
- || reloc_type == 2 /* R_PARISC_DIR21L. */
- || reloc_type == 41); /* R_PARISC_SECREL32. */
- case EM_PJ:
- case EM_PJ_OLD:
- return reloc_type == 1; /* R_PJ_DATA_DIR32. */
- case EM_PPC64:
- return reloc_type == 1; /* R_PPC64_ADDR32. */
- case EM_PPC:
- return reloc_type == 1; /* R_PPC_ADDR32. */
- case EM_TI_PRU:
- return reloc_type == 11; /* R_PRU_BFD_RELOC_32. */
- case EM_RISCV:
- return reloc_type == 1; /* R_RISCV_32. */
- case EM_RL78:
- return reloc_type == 1; /* R_RL78_DIR32. */
- case EM_RX:
- return reloc_type == 1; /* R_RX_DIR32. */
- case EM_S370:
- return reloc_type == 1; /* R_I370_ADDR31. */
- case EM_S390_OLD:
- case EM_S390:
- return reloc_type == 4; /* R_S390_32. */
- case EM_SCORE:
- return reloc_type == 8; /* R_SCORE_ABS32. */
- case EM_SH:
- return reloc_type == 1; /* R_SH_DIR32. */
- case EM_SPARC32PLUS:
- case EM_SPARCV9:
- case EM_SPARC:
- return reloc_type == 3 /* R_SPARC_32. */
- || reloc_type == 23; /* R_SPARC_UA32. */
- case EM_SPU:
- return reloc_type == 6; /* R_SPU_ADDR32 */
- case EM_TI_C6000:
- return reloc_type == 1; /* R_C6000_ABS32. */
- case EM_TILEGX:
- return reloc_type == 2; /* R_TILEGX_32. */
- case EM_TILEPRO:
- return reloc_type == 1; /* R_TILEPRO_32. */
- case EM_CYGNUS_V850:
- case EM_V850:
- return reloc_type == 6; /* R_V850_ABS32. */
- case EM_V800:
- return reloc_type == 0x33; /* R_V810_WORD. */
- case EM_VAX:
- return reloc_type == 1; /* R_VAX_32. */
- case EM_VISIUM:
- return reloc_type == 3; /* R_VISIUM_32. */
- case EM_WEBASSEMBLY:
- return reloc_type == 1; /* R_WASM32_32. */
- case EM_X86_64:
- case EM_L1OM:
- case EM_K1OM:
- return reloc_type == 10; /* R_X86_64_32. */
- case EM_XGATE:
- return reloc_type == 4; /* R_XGATE_32. */
- case EM_XSTORMY16:
- return reloc_type == 1; /* R_XSTROMY16_32. */
- case EM_XTENSA_OLD:
- case EM_XTENSA:
- return reloc_type == 1; /* R_XTENSA_32. */
- case EM_Z80:
- return reloc_type == 6; /* R_Z80_32. */
- default:
- {
- static unsigned int prev_warn = 0;
-
- /* Avoid repeating the same warning multiple times. */
- if (prev_warn != filedata->file_header.e_machine)
- error (_("Missing knowledge of 32-bit reloc types used in DWARF sections of machine number %d\n"),
- filedata->file_header.e_machine);
- prev_warn = filedata->file_header.e_machine;
- return false;
- }
- }
-}
-
-/* Like is_32bit_abs_reloc except that it returns TRUE iff RELOC_TYPE is
- a 32-bit pc-relative RELA relocation used in DWARF debug sections. */
-
-static bool
-is_32bit_pcrel_reloc (Filedata * filedata, unsigned int reloc_type)
-{
- switch (filedata->file_header.e_machine)
- /* Please keep this table alpha-sorted for ease of visual lookup. */
- {
- case EM_386:
- case EM_IAMCU:
- return reloc_type == 2; /* R_386_PC32. */
- case EM_68K:
- return reloc_type == 4; /* R_68K_PC32. */
- case EM_AARCH64:
- return reloc_type == 261; /* R_AARCH64_PREL32 */
- case EM_ADAPTEVA_EPIPHANY:
- return reloc_type == 6;
- case EM_ALPHA:
- return reloc_type == 10; /* R_ALPHA_SREL32. */
- case EM_ARC_COMPACT:
- case EM_ARC_COMPACT2:
- case EM_ARC_COMPACT3:
- case EM_ARC_COMPACT3_64:
- return reloc_type == 49; /* R_ARC_32_PCREL. */
- case EM_ARM:
- return reloc_type == 3; /* R_ARM_REL32 */
- case EM_AVR_OLD:
- case EM_AVR:
- return reloc_type == 36; /* R_AVR_32_PCREL. */
- case EM_LOONGARCH:
- return reloc_type == 99; /* R_LARCH_32_PCREL. */
- case EM_MICROBLAZE:
- return reloc_type == 2; /* R_MICROBLAZE_32_PCREL. */
- case EM_OR1K:
- return reloc_type == 9; /* R_OR1K_32_PCREL. */
- case EM_PARISC:
- return reloc_type == 9; /* R_PARISC_PCREL32. */
- case EM_PPC:
- return reloc_type == 26; /* R_PPC_REL32. */
- case EM_PPC64:
- return reloc_type == 26; /* R_PPC64_REL32. */
- case EM_RISCV:
- return reloc_type == 57; /* R_RISCV_32_PCREL. */
- case EM_S390_OLD:
- case EM_S390:
- return reloc_type == 5; /* R_390_PC32. */
- case EM_SH:
- return reloc_type == 2; /* R_SH_REL32. */
- case EM_SPARC32PLUS:
- case EM_SPARCV9:
- case EM_SPARC:
- return reloc_type == 6; /* R_SPARC_DISP32. */
- case EM_SPU:
- return reloc_type == 13; /* R_SPU_REL32. */
- case EM_TILEGX:
- return reloc_type == 6; /* R_TILEGX_32_PCREL. */
- case EM_TILEPRO:
- return reloc_type == 4; /* R_TILEPRO_32_PCREL. */
- case EM_VISIUM:
- return reloc_type == 6; /* R_VISIUM_32_PCREL */
- case EM_X86_64:
- case EM_L1OM:
- case EM_K1OM:
- return reloc_type == 2; /* R_X86_64_PC32. */
- case EM_VAX:
- return reloc_type == 4; /* R_VAX_PCREL32. */
- case EM_XTENSA_OLD:
- case EM_XTENSA:
- return reloc_type == 14; /* R_XTENSA_32_PCREL. */
- case EM_KVX:
- return reloc_type == 7; /* R_KVX_32_PCREL */
- default:
- /* Do not abort or issue an error message here. Not all targets use
- pc-relative 32-bit relocs in their DWARF debug information and we
- have already tested for target coverage in is_32bit_abs_reloc. A
- more helpful warning message will be generated by apply_relocations
- anyway, so just return. */
- return false;
- }
-}
-
-/* Like is_32bit_abs_reloc except that it returns TRUE iff RELOC_TYPE is
- a 64-bit absolute RELA relocation used in DWARF debug sections. */
-
-static bool
-is_64bit_abs_reloc (Filedata * filedata, unsigned int reloc_type)
-{
- switch (filedata->file_header.e_machine)
- {
- case EM_AARCH64:
- return reloc_type == 257; /* R_AARCH64_ABS64. */
- case EM_ARC_COMPACT3_64:
- return reloc_type == 5; /* R_ARC_64. */
- case EM_ALPHA:
- return reloc_type == 2; /* R_ALPHA_REFQUAD. */
- case EM_IA_64:
- return (reloc_type == 0x26 /* R_IA64_DIR64MSB. */
- || reloc_type == 0x27 /* R_IA64_DIR64LSB. */);
- case EM_LOONGARCH:
- return reloc_type == 2; /* R_LARCH_64 */
- case EM_PARISC:
- return reloc_type == 80; /* R_PARISC_DIR64. */
- case EM_PPC64:
- return reloc_type == 38; /* R_PPC64_ADDR64. */
- case EM_RISCV:
- return reloc_type == 2; /* R_RISCV_64. */
- case EM_SPARC32PLUS:
- case EM_SPARCV9:
- case EM_SPARC:
- return reloc_type == 32 /* R_SPARC_64. */
- || reloc_type == 54; /* R_SPARC_UA64. */
- case EM_X86_64:
- case EM_L1OM:
- case EM_K1OM:
- return reloc_type == 1; /* R_X86_64_64. */
- case EM_S390_OLD:
- case EM_S390:
- return reloc_type == 22; /* R_S390_64. */
- case EM_TILEGX:
- return reloc_type == 1; /* R_TILEGX_64. */
- case EM_MIPS:
- return reloc_type == 18; /* R_MIPS_64. */
- case EM_KVX:
- return reloc_type == 3; /* R_KVX_64 */
- default:
- return false;
- }
-}
-
-/* Like is_32bit_pcrel_reloc except that it returns TRUE iff RELOC_TYPE is
- a 64-bit pc-relative RELA relocation used in DWARF debug sections. */
-
-static bool
-is_64bit_pcrel_reloc (Filedata * filedata, unsigned int reloc_type)
-{
- switch (filedata->file_header.e_machine)
- {
- case EM_AARCH64:
- return reloc_type == 260; /* R_AARCH64_PREL64. */
- case EM_ALPHA:
- return reloc_type == 11; /* R_ALPHA_SREL64. */
- case EM_IA_64:
- return (reloc_type == 0x4e /* R_IA64_PCREL64MSB. */
- || reloc_type == 0x4f /* R_IA64_PCREL64LSB. */);
- case EM_PARISC:
- return reloc_type == 72; /* R_PARISC_PCREL64. */
- case EM_PPC64:
- return reloc_type == 44; /* R_PPC64_REL64. */
- case EM_SPARC32PLUS:
- case EM_SPARCV9:
- case EM_SPARC:
- return reloc_type == 46; /* R_SPARC_DISP64. */
- case EM_X86_64:
- case EM_L1OM:
- case EM_K1OM:
- return reloc_type == 24; /* R_X86_64_PC64. */
- case EM_S390_OLD:
- case EM_S390:
- return reloc_type == 23; /* R_S390_PC64. */
- case EM_TILEGX:
- return reloc_type == 5; /* R_TILEGX_64_PCREL. */
- default:
- return false;
- }
-}
-
-/* Like is_32bit_abs_reloc except that it returns TRUE iff RELOC_TYPE is
- a 24-bit absolute RELA relocation used in DWARF debug sections. */
-
-static bool
-is_24bit_abs_reloc (Filedata * filedata, unsigned int reloc_type)
-{
- switch (filedata->file_header.e_machine)
- {
- case EM_CYGNUS_MN10200:
- case EM_MN10200:
- return reloc_type == 4; /* R_MN10200_24. */
- case EM_FT32:
- return reloc_type == 5; /* R_FT32_20. */
- case EM_Z80:
- return reloc_type == 5; /* R_Z80_24. */
- default:
- return false;
- }
-}
-
-/* Like is_32bit_abs_reloc except that it returns TRUE iff RELOC_TYPE is
- a 16-bit absolute RELA relocation used in DWARF debug sections. */
-
-static bool
-is_16bit_abs_reloc (Filedata * filedata, unsigned int reloc_type)
-{
- /* Please keep this table alpha-sorted for ease of visual lookup. */
- switch (filedata->file_header.e_machine)
- {
- case EM_ARC:
- case EM_ARC_COMPACT:
- case EM_ARC_COMPACT2:
- case EM_ARC_COMPACT3:
- case EM_ARC_COMPACT3_64:
- return reloc_type == 2; /* R_ARC_16. */
- case EM_ADAPTEVA_EPIPHANY:
- return reloc_type == 5;
- case EM_AVR_OLD:
- case EM_AVR:
- return reloc_type == 4; /* R_AVR_16. */
- case EM_CYGNUS_D10V:
- case EM_D10V:
- return reloc_type == 3; /* R_D10V_16. */
- case EM_FT32:
- return reloc_type == 2; /* R_FT32_16. */
- case EM_H8S:
- case EM_H8_300:
- case EM_H8_300H:
- return reloc_type == R_H8_DIR16;
- case EM_IP2K_OLD:
- case EM_IP2K:
- return reloc_type == 1; /* R_IP2K_16. */
- case EM_M32C_OLD:
- case EM_M32C:
- return reloc_type == 1; /* R_M32C_16 */
- case EM_CYGNUS_MN10200:
- case EM_MN10200:
- return reloc_type == 2; /* R_MN10200_16. */
- case EM_CYGNUS_MN10300:
- case EM_MN10300:
- return reloc_type == 2; /* R_MN10300_16. */
- case EM_KVX:
- return reloc_type == 1; /* R_KVX_16 */
- case EM_MSP430:
- if (uses_msp430x_relocs (filedata))
- return reloc_type == 2; /* R_MSP430_ABS16. */
- /* Fall through. */
- case EM_MSP430_OLD:
- return reloc_type == 5; /* R_MSP430_16_BYTE. */
- case EM_NDS32:
- return reloc_type == 19; /* R_NDS32_16_RELA. */
- case EM_ALTERA_NIOS2:
- return reloc_type == 13; /* R_NIOS2_BFD_RELOC_16. */
- case EM_NIOS32:
- return reloc_type == 9; /* R_NIOS_16. */
- case EM_OR1K:
- return reloc_type == 2; /* R_OR1K_16. */
- case EM_RISCV:
- return reloc_type == 55; /* R_RISCV_SET16. */
- case EM_TI_PRU:
- return reloc_type == 8; /* R_PRU_BFD_RELOC_16. */
- case EM_TI_C6000:
- return reloc_type == 2; /* R_C6000_ABS16. */
- case EM_VISIUM:
- return reloc_type == 2; /* R_VISIUM_16. */
- case EM_XGATE:
- return reloc_type == 3; /* R_XGATE_16. */
- case EM_Z80:
- return reloc_type == 4; /* R_Z80_16. */
- default:
- return false;
- }
-}
-
-/* Like is_32bit_abs_reloc except that it returns TRUE iff RELOC_TYPE is
- a 8-bit absolute RELA relocation used in DWARF debug sections. */
-
-static bool
-is_8bit_abs_reloc (Filedata * filedata, unsigned int reloc_type)
-{
- switch (filedata->file_header.e_machine)
- {
- case EM_RISCV:
- return reloc_type == 54; /* R_RISCV_SET8. */
- case EM_Z80:
- return reloc_type == 1; /* R_Z80_8. */
- case EM_MICROBLAZE:
- return (reloc_type == 33 /* R_MICROBLAZE_32_NONE. */
- || reloc_type == 0 /* R_MICROBLAZE_NONE. */
- || reloc_type == 9 /* R_MICROBLAZE_64_NONE. */);
- default:
- return false;
- }
-}
-
-/* Like is_32bit_abs_reloc except that it returns TRUE iff RELOC_TYPE is
- a 6-bit absolute RELA relocation used in DWARF debug sections. */
-
-static bool
-is_6bit_abs_reloc (Filedata * filedata, unsigned int reloc_type)
-{
- switch (filedata->file_header.e_machine)
- {
- case EM_RISCV:
- return reloc_type == 53; /* R_RISCV_SET6. */
- default:
- return false;
- }
-}
-
-/* Like is_32bit_abs_reloc except that it returns TRUE iff RELOC_TYPE is
- a 32-bit inplace add RELA relocation used in DWARF debug sections. */
-
-static bool
-is_32bit_inplace_add_reloc (Filedata * filedata, unsigned int reloc_type)
-{
- /* Please keep this table alpha-sorted for ease of visual lookup. */
- switch (filedata->file_header.e_machine)
- {
- case EM_LOONGARCH:
- return reloc_type == 50; /* R_LARCH_ADD32. */
- case EM_RISCV:
- return reloc_type == 35; /* R_RISCV_ADD32. */
- default:
- return false;
- }
-}
-
-/* Like is_32bit_abs_reloc except that it returns TRUE iff RELOC_TYPE is
- a 32-bit inplace sub RELA relocation used in DWARF debug sections. */
-
-static bool
-is_32bit_inplace_sub_reloc (Filedata * filedata, unsigned int reloc_type)
-{
- /* Please keep this table alpha-sorted for ease of visual lookup. */
- switch (filedata->file_header.e_machine)
- {
- case EM_LOONGARCH:
- return reloc_type == 55; /* R_LARCH_SUB32. */
- case EM_RISCV:
- return reloc_type == 39; /* R_RISCV_SUB32. */
- default:
- return false;
- }
-}
-
-/* Like is_32bit_abs_reloc except that it returns TRUE iff RELOC_TYPE is
- a 64-bit inplace add RELA relocation used in DWARF debug sections. */
-
-static bool
-is_64bit_inplace_add_reloc (Filedata * filedata, unsigned int reloc_type)
-{
- /* Please keep this table alpha-sorted for ease of visual lookup. */
- switch (filedata->file_header.e_machine)
- {
- case EM_LOONGARCH:
- return reloc_type == 51; /* R_LARCH_ADD64. */
- case EM_RISCV:
- return reloc_type == 36; /* R_RISCV_ADD64. */
- default:
- return false;
- }
-}
-
-/* Like is_32bit_abs_reloc except that it returns TRUE iff RELOC_TYPE is
- a 64-bit inplace sub RELA relocation used in DWARF debug sections. */
-
-static bool
-is_64bit_inplace_sub_reloc (Filedata * filedata, unsigned int reloc_type)
-{
- /* Please keep this table alpha-sorted for ease of visual lookup. */
- switch (filedata->file_header.e_machine)
- {
- case EM_LOONGARCH:
- return reloc_type == 56; /* R_LARCH_SUB64. */
- case EM_RISCV:
- return reloc_type == 40; /* R_RISCV_SUB64. */
- default:
- return false;
- }
-}
-
-/* Like is_32bit_abs_reloc except that it returns TRUE iff RELOC_TYPE is
- a 16-bit inplace add RELA relocation used in DWARF debug sections. */
-
-static bool
-is_16bit_inplace_add_reloc (Filedata * filedata, unsigned int reloc_type)
-{
- /* Please keep this table alpha-sorted for ease of visual lookup. */
- switch (filedata->file_header.e_machine)
- {
- case EM_LOONGARCH:
- return reloc_type == 48; /* R_LARCH_ADD16. */
- case EM_RISCV:
- return reloc_type == 34; /* R_RISCV_ADD16. */
- default:
- return false;
- }
-}
-
-/* Like is_32bit_abs_reloc except that it returns TRUE iff RELOC_TYPE is
- a 16-bit inplace sub RELA relocation used in DWARF debug sections. */
-
-static bool
-is_16bit_inplace_sub_reloc (Filedata * filedata, unsigned int reloc_type)
-{
- /* Please keep this table alpha-sorted for ease of visual lookup. */
- switch (filedata->file_header.e_machine)
- {
- case EM_LOONGARCH:
- return reloc_type == 53; /* R_LARCH_SUB16. */
- case EM_RISCV:
- return reloc_type == 38; /* R_RISCV_SUB16. */
- default:
- return false;
- }
-}
-
-/* Like is_32bit_abs_reloc except that it returns TRUE iff RELOC_TYPE is
- a 8-bit inplace add RELA relocation used in DWARF debug sections. */
-
-static bool
-is_8bit_inplace_add_reloc (Filedata * filedata, unsigned int reloc_type)
-{
- /* Please keep this table alpha-sorted for ease of visual lookup. */
- switch (filedata->file_header.e_machine)
- {
- case EM_LOONGARCH:
- return reloc_type == 47; /* R_LARCH_ADD8. */
- case EM_RISCV:
- return reloc_type == 33; /* R_RISCV_ADD8. */
- default:
- return false;
- }
-}
-
-/* Like is_32bit_abs_reloc except that it returns TRUE iff RELOC_TYPE is
- a 8-bit inplace sub RELA relocation used in DWARF debug sections. */
-
-static bool
-is_8bit_inplace_sub_reloc (Filedata * filedata, unsigned int reloc_type)
-{
- /* Please keep this table alpha-sorted for ease of visual lookup. */
- switch (filedata->file_header.e_machine)
- {
- case EM_LOONGARCH:
- return reloc_type == 52; /* R_LARCH_SUB8. */
- case EM_RISCV:
- return reloc_type == 37; /* R_RISCV_SUB8. */
- default:
- return false;
- }
-}
-
-/* Like is_32bit_abs_reloc except that it returns TRUE iff RELOC_TYPE is
- a 6-bit inplace add RELA relocation used in DWARF debug sections. */
-
-static bool
-is_6bit_inplace_add_reloc (Filedata * filedata, unsigned int reloc_type)
-{
- switch (filedata->file_header.e_machine)
- {
- case EM_LOONGARCH:
- return reloc_type == 105; /* R_LARCH_ADD6. */
- default:
- return false;
- }
-}
-
-/* Like is_32bit_abs_reloc except that it returns TRUE iff RELOC_TYPE is
- a 6-bit inplace sub RELA relocation used in DWARF debug sections. */
-
-static bool
-is_6bit_inplace_sub_reloc (Filedata * filedata, unsigned int reloc_type)
-{
- switch (filedata->file_header.e_machine)
- {
- case EM_LOONGARCH:
- return reloc_type == 106; /* R_LARCH_SUB6. */
- case EM_RISCV:
- return reloc_type == 52; /* R_RISCV_SUB6. */
- default:
- return false;
- }
-}
-
-/* Returns TRUE iff RELOC_TYPE is a NONE relocation used for discarded
- relocation entries (possibly formerly used for SHT_GROUP sections). */
-
-static bool
-is_none_reloc (Filedata * filedata, unsigned int reloc_type)
-{
- switch (filedata->file_header.e_machine)
- {
- case EM_386: /* R_386_NONE. */
- case EM_68K: /* R_68K_NONE. */
- case EM_ADAPTEVA_EPIPHANY:
- case EM_ALPHA: /* R_ALPHA_NONE. */
- case EM_ALTERA_NIOS2: /* R_NIOS2_NONE. */
- case EM_ARC: /* R_ARC_NONE. */
- case EM_ARC_COMPACT2: /* R_ARC_NONE. */
- case EM_ARC_COMPACT: /* R_ARC_NONE. */
- case EM_ARC_COMPACT3: /* R_ARC_NONE. */
- case EM_ARC_COMPACT3_64: /* R_ARC_NONE. */
- case EM_ARM: /* R_ARM_NONE. */
- case EM_CRIS: /* R_CRIS_NONE. */
- case EM_FT32: /* R_FT32_NONE. */
- case EM_IA_64: /* R_IA64_NONE. */
- case EM_K1OM: /* R_X86_64_NONE. */
- case EM_KVX: /* R_KVX_NONE. */
- case EM_L1OM: /* R_X86_64_NONE. */
- case EM_M32R: /* R_M32R_NONE. */
- case EM_MIPS: /* R_MIPS_NONE. */
- case EM_MN10300: /* R_MN10300_NONE. */
- case EM_MOXIE: /* R_MOXIE_NONE. */
- case EM_NIOS32: /* R_NIOS_NONE. */
- case EM_OR1K: /* R_OR1K_NONE. */
- case EM_PARISC: /* R_PARISC_NONE. */
- case EM_PPC64: /* R_PPC64_NONE. */
- case EM_PPC: /* R_PPC_NONE. */
- case EM_RISCV: /* R_RISCV_NONE. */
- case EM_S390: /* R_390_NONE. */
- case EM_S390_OLD:
- case EM_SH: /* R_SH_NONE. */
- case EM_SPARC32PLUS:
- case EM_SPARC: /* R_SPARC_NONE. */
- case EM_SPARCV9:
- case EM_TILEGX: /* R_TILEGX_NONE. */
- case EM_TILEPRO: /* R_TILEPRO_NONE. */
- case EM_TI_C6000:/* R_C6000_NONE. */
- case EM_X86_64: /* R_X86_64_NONE. */
- case EM_Z80: /* R_Z80_NONE. */
- case EM_WEBASSEMBLY: /* R_WASM32_NONE. */
- return reloc_type == 0;
-
- case EM_AARCH64:
- return reloc_type == 0 || reloc_type == 256;
- case EM_AVR_OLD:
- case EM_AVR:
- return (reloc_type == 0 /* R_AVR_NONE. */
- || reloc_type == 30 /* R_AVR_DIFF8. */
- || reloc_type == 31 /* R_AVR_DIFF16. */
- || reloc_type == 32 /* R_AVR_DIFF32. */);
- case EM_METAG:
- return reloc_type == 3; /* R_METAG_NONE. */
- case EM_NDS32:
- return (reloc_type == 0 /* R_NDS32_NONE. */
- || reloc_type == 205 /* R_NDS32_DIFF8. */
- || reloc_type == 206 /* R_NDS32_DIFF16. */
- || reloc_type == 207 /* R_NDS32_DIFF32. */
- || reloc_type == 208 /* R_NDS32_DIFF_ULEB128. */);
- case EM_TI_PRU:
- return (reloc_type == 0 /* R_PRU_NONE. */
- || reloc_type == 65 /* R_PRU_DIFF8. */
- || reloc_type == 66 /* R_PRU_DIFF16. */
- || reloc_type == 67 /* R_PRU_DIFF32. */);
- case EM_XTENSA_OLD:
- case EM_XTENSA:
- return (reloc_type == 0 /* R_XTENSA_NONE. */
- || reloc_type == 17 /* R_XTENSA_DIFF8. */
- || reloc_type == 18 /* R_XTENSA_DIFF16. */
- || reloc_type == 19 /* R_XTENSA_DIFF32. */
- || reloc_type == 57 /* R_XTENSA_PDIFF8. */
- || reloc_type == 58 /* R_XTENSA_PDIFF16. */
- || reloc_type == 59 /* R_XTENSA_PDIFF32. */
- || reloc_type == 60 /* R_XTENSA_NDIFF8. */
- || reloc_type == 61 /* R_XTENSA_NDIFF16. */
- || reloc_type == 62 /* R_XTENSA_NDIFF32. */);
- }
- return false;
-}
-
-/* Returns TRUE if there is a relocation against
- section NAME at OFFSET bytes. */
-
-bool
-reloc_at (struct dwarf_section * dsec, uint64_t offset)
-{
- Elf_Internal_Rela * relocs;
- Elf_Internal_Rela * rp;
-
- if (dsec == NULL || dsec->reloc_info == NULL)
- return false;
-
- relocs = (Elf_Internal_Rela *) dsec->reloc_info;
-
- for (rp = relocs; rp < relocs + dsec->num_relocs; ++rp)
- if (rp->r_offset == offset)
- return true;
-
- return false;
-}
-
-/* Apply relocations to a section.
- Returns TRUE upon success, FALSE otherwise.
- If RELOCS_RETURN is non-NULL then it is set to point to the loaded relocs.
- It is then the caller's responsibility to free them. NUM_RELOCS_RETURN
- will be set to the number of relocs loaded.
-
- Note: So far support has been added only for those relocations
- which can be found in debug sections. FIXME: Add support for
- more relocations ? */
-
-static bool
-apply_relocations (Filedata *filedata,
- const Elf_Internal_Shdr *section,
- unsigned char *start,
- size_t size,
- void **relocs_return,
- uint64_t *num_relocs_return)
-{
- Elf_Internal_Shdr * relsec;
- unsigned char * end = start + size;
-
- if (relocs_return != NULL)
- {
- * (Elf_Internal_Rela **) relocs_return = NULL;
- * num_relocs_return = 0;
- }
-
- if (filedata->file_header.e_type != ET_REL)
- /* No relocs to apply. */
- return true;
-
- /* Find the reloc section associated with the section. */
- for (relsec = filedata->section_headers;
- relsec < filedata->section_headers + filedata->file_header.e_shnum;
- ++relsec)
- {
- bool is_rela;
- uint64_t num_relocs;
- Elf_Internal_Rela * relocs;
- Elf_Internal_Rela * rp;
- Elf_Internal_Shdr * symsec;
- Elf_Internal_Sym * symtab;
- uint64_t num_syms;
- Elf_Internal_Sym * sym;
-
- if ((relsec->sh_type != SHT_RELA && relsec->sh_type != SHT_REL)
- || relsec->sh_info >= filedata->file_header.e_shnum
- || filedata->section_headers + relsec->sh_info != section
- || relsec->sh_size == 0
- || relsec->sh_link >= filedata->file_header.e_shnum)
- continue;
-
- symsec = filedata->section_headers + relsec->sh_link;
- if (symsec->sh_type != SHT_SYMTAB
- && symsec->sh_type != SHT_DYNSYM)
- return false;
-
- is_rela = relsec->sh_type == SHT_RELA;
-
- if (is_rela)
- {
- if (!slurp_rela_relocs (filedata, relsec->sh_offset,
- relsec->sh_size, & relocs, & num_relocs))
- return false;
- }
- else
- {
- if (!slurp_rel_relocs (filedata, relsec->sh_offset,
- relsec->sh_size, & relocs, & num_relocs))
- return false;
- }
-
- /* SH uses RELA but uses in place value instead of the addend field. */
- if (filedata->file_header.e_machine == EM_SH)
- is_rela = false;
-
- symtab = get_elf_symbols (filedata, symsec, & num_syms);
-
- for (rp = relocs; rp < relocs + num_relocs; ++rp)
- {
- uint64_t addend;
- unsigned int reloc_type;
- unsigned int reloc_size;
- bool reloc_inplace = false;
- bool reloc_subtract = false;
- unsigned char *rloc;
- uint64_t sym_index;
-
- reloc_type = get_reloc_type (filedata, rp->r_info);
-
- if (target_specific_reloc_handling (filedata, rp, start, end, symtab, num_syms))
- continue;
- else if (is_none_reloc (filedata, reloc_type))
- continue;
- else if (is_32bit_abs_reloc (filedata, reloc_type)
- || is_32bit_pcrel_reloc (filedata, reloc_type))
- reloc_size = 4;
- else if (is_64bit_abs_reloc (filedata, reloc_type)
- || is_64bit_pcrel_reloc (filedata, reloc_type))
- reloc_size = 8;
- else if (is_24bit_abs_reloc (filedata, reloc_type))
- reloc_size = 3;
- else if (is_16bit_abs_reloc (filedata, reloc_type))
- reloc_size = 2;
- else if (is_8bit_abs_reloc (filedata, reloc_type)
- || is_6bit_abs_reloc (filedata, reloc_type))
- reloc_size = 1;
- else if ((reloc_subtract = is_32bit_inplace_sub_reloc (filedata,
- reloc_type))
- || is_32bit_inplace_add_reloc (filedata, reloc_type))
- {
- reloc_size = 4;
- reloc_inplace = true;
- }
- else if ((reloc_subtract = is_64bit_inplace_sub_reloc (filedata,
- reloc_type))
- || is_64bit_inplace_add_reloc (filedata, reloc_type))
- {
- reloc_size = 8;
- reloc_inplace = true;
- }
- else if ((reloc_subtract = is_16bit_inplace_sub_reloc (filedata,
- reloc_type))
- || is_16bit_inplace_add_reloc (filedata, reloc_type))
- {
- reloc_size = 2;
- reloc_inplace = true;
- }
- else if ((reloc_subtract = is_8bit_inplace_sub_reloc (filedata,
- reloc_type))
- || is_8bit_inplace_add_reloc (filedata, reloc_type))
- {
- reloc_size = 1;
- reloc_inplace = true;
- }
- else if ((reloc_subtract = is_6bit_inplace_sub_reloc (filedata,
- reloc_type))
- || is_6bit_inplace_add_reloc (filedata, reloc_type))
- {
- reloc_size = 1;
- reloc_inplace = true;
- }
- else
- {
- static unsigned int prev_reloc = 0;
-
- if (reloc_type != prev_reloc)
- warn (_("unable to apply unsupported reloc type %d to section %s\n"),
- reloc_type, printable_section_name (filedata, section));
- prev_reloc = reloc_type;
- continue;
- }
-
- rloc = start + rp->r_offset;
- if (!IN_RANGE (start, end, rloc, reloc_size))
- {
- warn (_("skipping invalid relocation offset %#" PRIx64
- " in section %s\n"),
- rp->r_offset,
- printable_section_name (filedata, section));
- continue;
- }
-
- sym_index = get_reloc_symindex (rp->r_info);
- if (sym_index >= num_syms)
- {
- warn (_("skipping invalid relocation symbol index %#" PRIx64
- " in section %s\n"),
- sym_index, printable_section_name (filedata, section));
- continue;
- }
- sym = symtab + sym_index;
-
- /* If the reloc has a symbol associated with it,
- make sure that it is of an appropriate type.
-
- Relocations against symbols without type can happen.
- Gcc -feliminate-dwarf2-dups may generate symbols
- without type for debug info.
-
- Icc generates relocations against function symbols
- instead of local labels.
-
- Relocations against object symbols can happen, eg when
- referencing a global array. For an example of this see
- the _clz.o binary in libgcc.a. */
- if (sym != symtab
- && ELF_ST_TYPE (sym->st_info) != STT_COMMON
- && ELF_ST_TYPE (sym->st_info) > STT_SECTION)
- {
- warn (_("skipping unexpected symbol type %s in section %s relocation %tu\n"),
- get_symbol_type (filedata, ELF_ST_TYPE (sym->st_info)),
- printable_section_name (filedata, relsec),
- rp - relocs);
- continue;
- }
-
- addend = 0;
- if (is_rela)
- addend += rp->r_addend;
- /* R_XTENSA_32, R_PJ_DATA_DIR32 and R_D30V_32_NORMAL are
- partial_inplace. */
- if (!is_rela
- || (filedata->file_header.e_machine == EM_XTENSA
- && reloc_type == 1)
- || ((filedata->file_header.e_machine == EM_PJ
- || filedata->file_header.e_machine == EM_PJ_OLD)
- && reloc_type == 1)
- || ((filedata->file_header.e_machine == EM_D30V
- || filedata->file_header.e_machine == EM_CYGNUS_D30V)
- && reloc_type == 12)
- || reloc_inplace)
- {
- if (is_6bit_inplace_sub_reloc (filedata, reloc_type))
- addend += byte_get (rloc, reloc_size) & 0x3f;
- else
- addend += byte_get (rloc, reloc_size);
- }
-
- if (is_32bit_pcrel_reloc (filedata, reloc_type)
- || is_64bit_pcrel_reloc (filedata, reloc_type))
- {
- /* On HPPA, all pc-relative relocations are biased by 8. */
- if (filedata->file_header.e_machine == EM_PARISC)
- addend -= 8;
- byte_put (rloc, (addend + sym->st_value) - rp->r_offset,
- reloc_size);
- }
- else if (is_6bit_abs_reloc (filedata, reloc_type)
- || is_6bit_inplace_sub_reloc (filedata, reloc_type)
- || is_6bit_inplace_add_reloc (filedata, reloc_type))
- {
- if (reloc_subtract)
- addend -= sym->st_value;
- else
- addend += sym->st_value;
- addend = (addend & 0x3f) | (byte_get (rloc, reloc_size) & 0xc0);
- byte_put (rloc, addend, reloc_size);
- }
- else if (reloc_subtract)
- byte_put (rloc, addend - sym->st_value, reloc_size);
- else
- byte_put (rloc, addend + sym->st_value, reloc_size);
- }
-
- free (symtab);
- /* Let the target specific reloc processing code know that
- we have finished with these relocs. */
- target_specific_reloc_handling (filedata, NULL, NULL, NULL, NULL, 0);
-
- if (relocs_return)
- {
- * (Elf_Internal_Rela **) relocs_return = relocs;
- * num_relocs_return = num_relocs;
- }
- else
- free (relocs);
-
- break;
- }
-
- return true;
-}
-
-#ifdef SUPPORT_DISASSEMBLY
-static bool
-disassemble_section (Elf_Internal_Shdr * section, Filedata * filedata)
-{
- printf (_("\nAssembly dump of section %s\n"), printable_section_name (filedata, section));
-
- /* FIXME: XXX -- to be done --- XXX */
-
- return true;
-}
-#endif
-
-/* Reads in the contents of SECTION from FILE, returning a pointer
- to a malloc'ed buffer or NULL if something went wrong. */
-
-static char *
-get_section_contents (Elf_Internal_Shdr * section, Filedata * filedata)
-{
- uint64_t num_bytes = section->sh_size;
-
- if (num_bytes == 0 || section->sh_type == SHT_NOBITS)
- {
- printf (_("Section '%s' has no data to dump.\n"),
- printable_section_name (filedata, section));
- return NULL;
- }
-
- return (char *) get_data (NULL, filedata, section->sh_offset, 1, num_bytes,
- _("section contents"));
-}
-
-/* Uncompresses a section that was compressed using zlib/zstd, in place. */
-
-static bool
-uncompress_section_contents (bool is_zstd,
- unsigned char ** buffer,
- uint64_t uncompressed_size,
- uint64_t * size,
- uint64_t file_size)
-{
- uint64_t compressed_size = *size;
- unsigned char *compressed_buffer = *buffer;
- unsigned char *uncompressed_buffer = NULL;
- z_stream strm;
- int rc;
-
- /* Similar to bfd_section_size_insane() in the BFD library we expect an
- upper limit of ~10x compression. Any compression larger than that is
- thought to be due to fuzzing of the compression header. */
- if (uncompressed_size > file_size * 10)
- {
- error (_("Uncompressed section size is suspiciously large: 0x%" PRIu64 "\n"),
- uncompressed_size);
- goto fail;
- }
-
- uncompressed_buffer = xmalloc (uncompressed_size);
-
- if (is_zstd)
- {
-#ifdef HAVE_ZSTD
- size_t ret = ZSTD_decompress (uncompressed_buffer, uncompressed_size,
- compressed_buffer, compressed_size);
- if (ZSTD_isError (ret))
- goto fail;
-#endif
- }
- else
- {
- /* It is possible the section consists of several compressed
- buffers concatenated together, so we uncompress in a loop. */
- /* PR 18313: The state field in the z_stream structure is supposed
- to be invisible to the user (ie us), but some compilers will
- still complain about it being used without initialisation. So
- we first zero the entire z_stream structure and then set the fields
- that we need. */
- memset (&strm, 0, sizeof strm);
- strm.avail_in = compressed_size;
- strm.next_in = (Bytef *)compressed_buffer;
- strm.avail_out = uncompressed_size;
-
- rc = inflateInit (&strm);
- while (strm.avail_in > 0)
- {
- if (rc != Z_OK)
- break;
- strm.next_out = ((Bytef *)uncompressed_buffer
- + (uncompressed_size - strm.avail_out));
- rc = inflate (&strm, Z_FINISH);
- if (rc != Z_STREAM_END)
- break;
- rc = inflateReset (&strm);
- }
- if (inflateEnd (&strm) != Z_OK || rc != Z_OK || strm.avail_out != 0)
- goto fail;
- }
-
- *buffer = uncompressed_buffer;
- *size = uncompressed_size;
- return true;
-
- fail:
- free (uncompressed_buffer);
- /* Indicate decompression failure. */
- *buffer = NULL;
- return false;
-}
-
-static uint64_t
-maybe_expand_or_relocate_section (Elf_Internal_Shdr * section,
- Filedata * filedata,
- unsigned char ** start_ptr,
- bool relocate)
-{
- uint64_t section_size = section->sh_size;
- unsigned char * start = * start_ptr;
-
- if (decompress_dumps)
- {
- uint64_t new_size = section_size;
- uint64_t uncompressed_size = 0;
- bool is_zstd = false;
-
- if ((section->sh_flags & SHF_COMPRESSED) != 0)
- {
- Elf_Internal_Chdr chdr;
- unsigned int compression_header_size
- = get_compression_header (& chdr, start, section_size);
-
- if (compression_header_size == 0)
- /* An error message will have already been generated
- by get_compression_header. */
- return (uint64_t) -1;
-
- if (chdr.ch_type == ch_compress_zlib)
- ;
-#ifdef HAVE_ZSTD
- else if (chdr.ch_type == ch_compress_zstd)
- is_zstd = true;
-#endif
- else
- {
- warn (_("section '%s' has unsupported compress type: %d\n"),
- printable_section_name (filedata, section), chdr.ch_type);
- return (uint64_t) -1;
- }
-
- uncompressed_size = chdr.ch_size;
- start += compression_header_size;
- new_size -= compression_header_size;
- }
- else if (new_size > 12 && streq ((char *) start, "ZLIB"))
- {
- /* Read the zlib header. In this case, it should be "ZLIB"
- followed by the uncompressed section size, 8 bytes in
- big-endian order. */
- uncompressed_size = start[4]; uncompressed_size <<= 8;
- uncompressed_size += start[5]; uncompressed_size <<= 8;
- uncompressed_size += start[6]; uncompressed_size <<= 8;
- uncompressed_size += start[7]; uncompressed_size <<= 8;
- uncompressed_size += start[8]; uncompressed_size <<= 8;
- uncompressed_size += start[9]; uncompressed_size <<= 8;
- uncompressed_size += start[10]; uncompressed_size <<= 8;
- uncompressed_size += start[11];
- start += 12;
- new_size -= 12;
- }
-
- if (uncompressed_size)
- {
- if (uncompress_section_contents (is_zstd, &start, uncompressed_size,
- &new_size, filedata->file_size))
- section_size = new_size;
- else
- {
- error (_("Unable to decompress section %s\n"),
- printable_section_name (filedata, section));
- return (uint64_t) -1;
- }
- }
- else
- start = * start_ptr;
- }
- else if (((section->sh_flags & SHF_COMPRESSED) != 0)
- || (section_size > 12 && streq ((char *) start, "ZLIB")))
- {
- printf (_(" NOTE: This section is compressed, but its contents have NOT been expanded for this dump.\n"));
- }
-
- if (relocate)
- {
- if (! apply_relocations (filedata, section, start, section_size, NULL, NULL))
- return (uint64_t) -1;
- }
- else
- {
- Elf_Internal_Shdr *relsec;
-
- /* If the section being dumped has relocations against it the user might
- be expecting these relocations to have been applied. Check for this
- case and issue a warning message in order to avoid confusion.
- FIXME: Maybe we ought to have an option that dumps a section with
- relocs applied ? */
- for (relsec = filedata->section_headers;
- relsec < filedata->section_headers + filedata->file_header.e_shnum;
- ++relsec)
- {
- if ((relsec->sh_type != SHT_RELA && relsec->sh_type != SHT_REL)
- || relsec->sh_info >= filedata->file_header.e_shnum
- || filedata->section_headers + relsec->sh_info != section
- || relsec->sh_size == 0
- || relsec->sh_link >= filedata->file_header.e_shnum)
- continue;
-
- printf (_(" NOTE: This section has relocations against it, but these have NOT been applied to this dump.\n"));
- break;
- }
- }
-
- * start_ptr = start;
- return section_size;
-}
-
-static bool
-dump_section_as_strings (Elf_Internal_Shdr * section, Filedata * filedata)
-{
- uint64_t num_bytes;
- unsigned char *data;
- unsigned char *end;
- unsigned char *real_start;
- unsigned char *start;
- bool some_strings_shown;
-
- real_start = start = (unsigned char *) get_section_contents (section, filedata);
- if (start == NULL)
- /* PR 21820: Do not fail if the section was empty. */
- return section->sh_size == 0 || section->sh_type == SHT_NOBITS;
-
- num_bytes = section->sh_size;
-
- if (filedata->is_separate)
- printf (_("\nString dump of section '%s' in linked file %s:\n"),
- printable_section_name (filedata, section),
- filedata->file_name);
- else
- printf (_("\nString dump of section '%s':\n"),
- printable_section_name (filedata, section));
-
- num_bytes = maybe_expand_or_relocate_section (section, filedata, & start, false);
- if (num_bytes == (uint64_t) -1)
- goto error_out;
-
- data = start;
- end = start + num_bytes;
- some_strings_shown = false;
-
-#ifdef HAVE_MBSTATE_T
- mbstate_t state;
- /* Initialise the multibyte conversion state. */
- memset (& state, 0, sizeof (state));
-#endif
-
- bool continuing = false;
-
- while (data < end)
- {
- while (!ISPRINT (* data))
- if (++ data >= end)
- break;
-
- if (data < end)
- {
- size_t maxlen = end - data;
-
- if (continuing)
- {
- printf (" ");
- continuing = false;
- }
- else
- {
- printf (" [%6tx] ", data - start);
- }
-
- if (maxlen > 0)
- {
- char c = 0;
-
- while (maxlen)
- {
- c = *data++;
-
- if (c == 0)
- break;
-
- /* PR 25543: Treat new-lines as string-ending characters. */
- if (c == '\n')
- {
- printf ("\\n\n");
- if (*data != 0)
- continuing = true;
- break;
- }
-
- /* Do not print control characters directly as they can affect terminal
- settings. Such characters usually appear in the names generated
- by the assembler for local labels. */
- if (ISCNTRL (c))
- {
- printf ("^%c", c + 0x40);
- }
- else if (ISPRINT (c))
- {
- putchar (c);
- }
- else
- {
- size_t n;
-#ifdef HAVE_MBSTATE_T
- wchar_t w;
-#endif
- /* Let printf do the hard work of displaying multibyte characters. */
- printf ("%.1s", data - 1);
-#ifdef HAVE_MBSTATE_T
- /* Try to find out how many bytes made up the character that was
- just printed. Advance the symbol pointer past the bytes that
- were displayed. */
- n = mbrtowc (& w, (char *)(data - 1), MB_CUR_MAX, & state);
-#else
- n = 1;
-#endif
- if (n != (size_t) -1 && n != (size_t) -2 && n > 0)
- data += (n - 1);
- }
- }
-
- if (c != '\n')
- putchar ('\n');
- }
- else
- {
- printf (_("<corrupt>\n"));
- data = end;
- }
- some_strings_shown = true;
- }
- }
-
- if (! some_strings_shown)
- printf (_(" No strings found in this section."));
-
- free (real_start);
-
- putchar ('\n');
- return true;
-
-error_out:
- free (real_start);
- return false;
-}
-
-static bool
-dump_section_as_bytes (Elf_Internal_Shdr *section,
- Filedata *filedata,
- bool relocate)
-{
- size_t bytes;
- uint64_t section_size;
- uint64_t addr;
- unsigned char *data;
- unsigned char *real_start;
- unsigned char *start;
-
- real_start = start = (unsigned char *) get_section_contents (section, filedata);
- if (start == NULL)
- /* PR 21820: Do not fail if the section was empty. */
- return section->sh_size == 0 || section->sh_type == SHT_NOBITS;
-
- section_size = section->sh_size;
-
- if (filedata->is_separate)
- printf (_("\nHex dump of section '%s' in linked file %s:\n"),
- printable_section_name (filedata, section),
- filedata->file_name);
- else
- printf (_("\nHex dump of section '%s':\n"),
- printable_section_name (filedata, section));
-
- section_size = maybe_expand_or_relocate_section (section, filedata, & start, relocate);
- if (section_size == (uint64_t) -1)
- goto error_out;
-
- addr = section->sh_addr;
- bytes = section_size;
- data = start;
-
- while (bytes)
- {
- int j;
- int k;
- int lbytes;
-
- lbytes = (bytes > 16 ? 16 : bytes);
-
- printf (" 0x%8.8" PRIx64 " ", addr);
-
- for (j = 0; j < 16; j++)
- {
- if (j < lbytes)
- printf ("%2.2x", data[j]);
- else
- printf (" ");
-
- if ((j & 3) == 3)
- printf (" ");
- }
-
- for (j = 0; j < lbytes; j++)
- {
- k = data[j];
- if (k >= ' ' && k < 0x7f)
- printf ("%c", k);
- else
- printf (".");
- }
-
- putchar ('\n');
-
- data += lbytes;
- addr += lbytes;
- bytes -= lbytes;
- }
-
- free (real_start);
-
- putchar ('\n');
- return true;
-
- error_out:
- free (real_start);
- return false;
-}
-
-#ifdef ENABLE_LIBCTF
-static ctf_sect_t *
-shdr_to_ctf_sect (ctf_sect_t *buf, Elf_Internal_Shdr *shdr, Filedata *filedata)
-{
- buf->cts_name = printable_section_name (filedata, shdr);
- buf->cts_size = shdr->sh_size;
- buf->cts_entsize = shdr->sh_entsize;
-
- return buf;
-}
-
-/* Formatting callback function passed to ctf_dump. Returns either the pointer
- it is passed, or a pointer to newly-allocated storage, in which case
- dump_ctf() will free it when it no longer needs it. */
-
-static char *
-dump_ctf_indent_lines (ctf_sect_names_t sect ATTRIBUTE_UNUSED,
- char *s, void *arg)
-{
- const char *blanks = arg;
- char *new_s;
-
- if (asprintf (&new_s, "%s%s", blanks, s) < 0)
- return s;
- return new_s;
-}
-
-/* Dump CTF errors/warnings. */
-static void
-dump_ctf_errs (ctf_dict_t *fp)
-{
- ctf_next_t *it = NULL;
- char *errtext;
- int is_warning;
- int err;
-
- /* Dump accumulated errors and warnings. */
- while ((errtext = ctf_errwarning_next (fp, &it, &is_warning, &err)) != NULL)
- {
- error (_("%s: %s"), is_warning ? _("warning"): _("error"),
- errtext);
- free (errtext);
- }
- if (err != ECTF_NEXT_END)
- error (_("CTF error: cannot get CTF errors: `%s'"), ctf_errmsg (err));
-}
-
-/* Dump one CTF archive member. */
-
-static void
-dump_ctf_archive_member (ctf_dict_t *ctf, const char *name, ctf_dict_t *parent,
- size_t member)
-{
- const char *things[] = {"Header", "Labels", "Data objects",
- "Function objects", "Variables", "Types", "Strings",
- ""};
- const char **thing;
- size_t i;
-
- /* Don't print out the name of the default-named archive member if it appears
- first in the list. The name .ctf appears everywhere, even for things that
- aren't really archives, so printing it out is liable to be confusing; also,
- the common case by far is for only one archive member to exist, and hiding
- it in that case seems worthwhile. */
-
- if (strcmp (name, ".ctf") != 0 || member != 0)
- printf (_("\nCTF archive member: %s:\n"), name);
-
- if (ctf_parent_name (ctf) != NULL)
- ctf_import (ctf, parent);
-
- for (i = 0, thing = things; *thing[0]; thing++, i++)
- {
- ctf_dump_state_t *s = NULL;
- char *item;
-
- printf ("\n %s:\n", *thing);
- while ((item = ctf_dump (ctf, &s, i, dump_ctf_indent_lines,
- (void *) " ")) != NULL)
- {
- printf ("%s\n", item);
- free (item);
- }
-
- if (ctf_errno (ctf))
- {
- error (_("Iteration failed: %s, %s\n"), *thing,
- ctf_errmsg (ctf_errno (ctf)));
- break;
- }
- }
-
- dump_ctf_errs (ctf);
-}
-
-static bool
-dump_section_as_ctf (Elf_Internal_Shdr * section, Filedata * filedata)
-{
- Elf_Internal_Shdr * symtab_sec = NULL;
- Elf_Internal_Shdr * strtab_sec = NULL;
- void * data = NULL;
- void * symdata = NULL;
- void * strdata = NULL;
- ctf_sect_t ctfsect, symsect, strsect;
- ctf_sect_t * symsectp = NULL;
- ctf_sect_t * strsectp = NULL;
- ctf_archive_t * ctfa = NULL;
- ctf_dict_t * parent = NULL;
- ctf_dict_t * fp;
-
- ctf_next_t *i = NULL;
- const char *name;
- size_t member = 0;
- int err;
- bool ret = false;
-
- shdr_to_ctf_sect (&ctfsect, section, filedata);
- data = get_section_contents (section, filedata);
- ctfsect.cts_data = data;
-
- if (!dump_ctf_symtab_name)
- dump_ctf_symtab_name = strdup (".dynsym");
-
- if (!dump_ctf_strtab_name)
- dump_ctf_strtab_name = strdup (".dynstr");
-
- if (dump_ctf_symtab_name && dump_ctf_symtab_name[0] != 0)
- {
- if ((symtab_sec = find_section (filedata, dump_ctf_symtab_name)) == NULL)
- {
- error (_("No symbol section named %s\n"), dump_ctf_symtab_name);
- goto fail;
- }
- if ((symdata = (void *) get_data (NULL, filedata,
- symtab_sec->sh_offset, 1,
- symtab_sec->sh_size,
- _("symbols"))) == NULL)
- goto fail;
- symsectp = shdr_to_ctf_sect (&symsect, symtab_sec, filedata);
- symsect.cts_data = symdata;
- }
-
- if (dump_ctf_strtab_name && dump_ctf_strtab_name[0] != 0)
- {
- if ((strtab_sec = find_section (filedata, dump_ctf_strtab_name)) == NULL)
- {
- error (_("No string table section named %s\n"),
- dump_ctf_strtab_name);
- goto fail;
- }
- if ((strdata = (void *) get_data (NULL, filedata,
- strtab_sec->sh_offset, 1,
- strtab_sec->sh_size,
- _("strings"))) == NULL)
- goto fail;
- strsectp = shdr_to_ctf_sect (&strsect, strtab_sec, filedata);
- strsect.cts_data = strdata;
- }
-
- /* Load the CTF file and dump it. It may be a raw CTF section, or an archive:
- libctf papers over the difference, so we can pretend it is always an
- archive. */
-
- if ((ctfa = ctf_arc_bufopen (&ctfsect, symsectp, strsectp, &err)) == NULL)
- {
- dump_ctf_errs (NULL);
- error (_("CTF open failure: %s\n"), ctf_errmsg (err));
- goto fail;
- }
-
- ctf_arc_symsect_endianness (ctfa, filedata->file_header.e_ident[EI_DATA]
- != ELFDATA2MSB);
-
- /* Preload the parent dict, since it will need to be imported into every
- child in turn. */
- if ((parent = ctf_dict_open (ctfa, dump_ctf_parent_name, &err)) == NULL)
- {
- dump_ctf_errs (NULL);
- error (_("CTF open failure: %s\n"), ctf_errmsg (err));
- goto fail;
- }
-
- ret = true;
-
- if (filedata->is_separate)
- printf (_("\nDump of CTF section '%s' in linked file %s:\n"),
- printable_section_name (filedata, section),
- filedata->file_name);
- else
- printf (_("\nDump of CTF section '%s':\n"),
- printable_section_name (filedata, section));
-
- while ((fp = ctf_archive_next (ctfa, &i, &name, 0, &err)) != NULL)
- dump_ctf_archive_member (fp, name, parent, member++);
- if (err != ECTF_NEXT_END)
- {
- dump_ctf_errs (NULL);
- error (_("CTF member open failure: %s\n"), ctf_errmsg (err));
- ret = false;
- }
-
- fail:
- ctf_dict_close (parent);
- ctf_close (ctfa);
- free (data);
- free (symdata);
- free (strdata);
- return ret;
-}
-#endif
-
-static bool
-dump_section_as_sframe (Elf_Internal_Shdr * section, Filedata * filedata)
-{
- void * data = NULL;
- sframe_decoder_ctx *sfd_ctx = NULL;
- const char *print_name = printable_section_name (filedata, section);
-
- bool ret = true;
- size_t sf_size;
- int err = 0;
-
- if (strcmp (print_name, "") == 0)
- {
- error (_("Section name must be provided \n"));
- ret = false;
- return ret;
- }
-
- data = get_section_contents (section, filedata);
- sf_size = section->sh_size;
- /* Decode the contents of the section. */
- sfd_ctx = sframe_decode ((const char*)data, sf_size, &err);
- if (!sfd_ctx)
- {
- ret = false;
- error (_("SFrame decode failure: %s\n"), sframe_errmsg (err));
- goto fail;
- }
-
- printf (_("Contents of the SFrame section %s:"), print_name);
- /* Dump the contents as text. */
- dump_sframe (sfd_ctx, section->sh_addr);
-
- fail:
- free (data);
- return ret;
-}
-
-static bool
-load_specific_debug_section (enum dwarf_section_display_enum debug,
- const Elf_Internal_Shdr * sec,
- void * data)
-{
- struct dwarf_section * section = &debug_displays [debug].section;
- char buf [64];
- Filedata * filedata = (Filedata *) data;
-
- if (section->start != NULL)
- {
- /* If it is already loaded, do nothing. */
- if (streq (section->filename, filedata->file_name))
- return true;
- free (section->start);
- }
-
- snprintf (buf, sizeof (buf), _("%s section data"), section->name);
- section->address = sec->sh_addr;
- section->filename = filedata->file_name;
- section->start = (unsigned char *) get_data (NULL, filedata,
- sec->sh_offset, 1,
- sec->sh_size, buf);
- if (section->start == NULL)
- section->size = 0;
- else
- {
- unsigned char *start = section->start;
- uint64_t size = sec->sh_size;
- uint64_t uncompressed_size = 0;
- bool is_zstd = false;
-
- if ((sec->sh_flags & SHF_COMPRESSED) != 0)
- {
- Elf_Internal_Chdr chdr;
- unsigned int compression_header_size;
-
- if (size < (is_32bit_elf
- ? sizeof (Elf32_External_Chdr)
- : sizeof (Elf64_External_Chdr)))
- {
- warn (_("compressed section %s is too small to contain a compression header\n"),
- section->name);
- return false;
- }
-
- compression_header_size = get_compression_header (&chdr, start, size);
- if (compression_header_size == 0)
- /* An error message will have already been generated
- by get_compression_header. */
- return false;
-
- if (chdr.ch_type == ch_compress_zlib)
- ;
-#ifdef HAVE_ZSTD
- else if (chdr.ch_type == ch_compress_zstd)
- is_zstd = true;
-#endif
- else
- {
- warn (_("section '%s' has unsupported compress type: %d\n"),
- section->name, chdr.ch_type);
- return false;
- }
- uncompressed_size = chdr.ch_size;
- start += compression_header_size;
- size -= compression_header_size;
- }
- else if (size > 12 && streq ((char *) start, "ZLIB"))
- {
- /* Read the zlib header. In this case, it should be "ZLIB"
- followed by the uncompressed section size, 8 bytes in
- big-endian order. */
- uncompressed_size = start[4]; uncompressed_size <<= 8;
- uncompressed_size += start[5]; uncompressed_size <<= 8;
- uncompressed_size += start[6]; uncompressed_size <<= 8;
- uncompressed_size += start[7]; uncompressed_size <<= 8;
- uncompressed_size += start[8]; uncompressed_size <<= 8;
- uncompressed_size += start[9]; uncompressed_size <<= 8;
- uncompressed_size += start[10]; uncompressed_size <<= 8;
- uncompressed_size += start[11];
- start += 12;
- size -= 12;
- }
-
- if (uncompressed_size)
- {
- if (uncompress_section_contents (is_zstd, &start, uncompressed_size,
- &size, filedata->file_size))
- {
- /* Free the compressed buffer, update the section buffer
- and the section size if uncompress is successful. */
- free (section->start);
- section->start = start;
- }
- else
- {
- error (_("Unable to decompress section %s\n"),
- printable_section_name (filedata, sec));
- return false;
- }
- }
-
- section->size = size;
- }
-
- if (section->start == NULL)
- return false;
-
- if (debug_displays [debug].relocate)
- {
- if (! apply_relocations (filedata, sec, section->start, section->size,
- & section->reloc_info, & section->num_relocs))
- return false;
- }
- else
- {
- section->reloc_info = NULL;
- section->num_relocs = 0;
- }
-
- return true;
-}
-
-#if HAVE_LIBDEBUGINFOD
-/* Return a hex string representation of the build-id. */
-unsigned char *
-get_build_id (void * data)
-{
- Filedata * filedata = (Filedata *) data;
- Elf_Internal_Shdr * shdr;
- size_t i;
-
- /* Iterate through notes to find note.gnu.build-id.
- FIXME: Only the first note in any note section is examined. */
- for (i = 0, shdr = filedata->section_headers;
- i < filedata->file_header.e_shnum && shdr != NULL;
- i++, shdr++)
- {
- if (shdr->sh_type != SHT_NOTE)
- continue;
-
- char * next;
- char * end;
- size_t data_remaining;
- size_t min_notesz;
- Elf_External_Note * enote;
- Elf_Internal_Note inote;
-
- uint64_t offset = shdr->sh_offset;
- uint64_t align = shdr->sh_addralign;
- uint64_t length = shdr->sh_size;
-
- enote = (Elf_External_Note *) get_section_contents (shdr, filedata);
- if (enote == NULL)
- continue;
-
- if (align < 4)
- align = 4;
- else if (align != 4 && align != 8)
- {
- free (enote);
- continue;
- }
-
- end = (char *) enote + length;
- data_remaining = end - (char *) enote;
-
- if (!is_ia64_vms (filedata))
- {
- min_notesz = offsetof (Elf_External_Note, name);
- if (data_remaining < min_notesz)
- {
- warn (_("\
-malformed note encountered in section %s whilst scanning for build-id note\n"),
- printable_section_name (filedata, shdr));
- free (enote);
- continue;
- }
- data_remaining -= min_notesz;
-
- inote.type = BYTE_GET (enote->type);
- inote.namesz = BYTE_GET (enote->namesz);
- inote.namedata = enote->name;
- inote.descsz = BYTE_GET (enote->descsz);
- inote.descdata = ((char *) enote
- + ELF_NOTE_DESC_OFFSET (inote.namesz, align));
- inote.descpos = offset + (inote.descdata - (char *) enote);
- next = ((char *) enote
- + ELF_NOTE_NEXT_OFFSET (inote.namesz, inote.descsz, align));
- }
- else
- {
- Elf64_External_VMS_Note *vms_enote;
-
- /* PR binutils/15191
- Make sure that there is enough data to read. */
- min_notesz = offsetof (Elf64_External_VMS_Note, name);
- if (data_remaining < min_notesz)
- {
- warn (_("\
-malformed note encountered in section %s whilst scanning for build-id note\n"),
- printable_section_name (filedata, shdr));
- free (enote);
- continue;
- }
- data_remaining -= min_notesz;
-
- vms_enote = (Elf64_External_VMS_Note *) enote;
- inote.type = BYTE_GET (vms_enote->type);
- inote.namesz = BYTE_GET (vms_enote->namesz);
- inote.namedata = vms_enote->name;
- inote.descsz = BYTE_GET (vms_enote->descsz);
- inote.descdata = inote.namedata + align_power (inote.namesz, 3);
- inote.descpos = offset + (inote.descdata - (char *) enote);
- next = inote.descdata + align_power (inote.descsz, 3);
- }
-
- /* Skip malformed notes. */
- if ((size_t) (inote.descdata - inote.namedata) < inote.namesz
- || (size_t) (inote.descdata - inote.namedata) > data_remaining
- || (size_t) (next - inote.descdata) < inote.descsz
- || ((size_t) (next - inote.descdata)
- > data_remaining - (size_t) (inote.descdata - inote.namedata)))
- {
- warn (_("\
-malformed note encountered in section %s whilst scanning for build-id note\n"),
- printable_section_name (filedata, shdr));
- free (enote);
- continue;
- }
-
- /* Check if this is the build-id note. If so then convert the build-id
- bytes to a hex string. */
- if (inote.namesz > 0
- && startswith (inote.namedata, "GNU")
- && inote.type == NT_GNU_BUILD_ID)
- {
- size_t j;
- char * build_id;
-
- build_id = malloc (inote.descsz * 2 + 1);
- if (build_id == NULL)
- {
- free (enote);
- return NULL;
- }
-
- for (j = 0; j < inote.descsz; ++j)
- sprintf (build_id + (j * 2), "%02x", inote.descdata[j] & 0xff);
- build_id[inote.descsz * 2] = '\0';
- free (enote);
-
- return (unsigned char *) build_id;
- }
- free (enote);
- }
-
- return NULL;
-}
-#endif /* HAVE_LIBDEBUGINFOD */
-
-/* If this is not NULL, load_debug_section will only look for sections
- within the list of sections given here. */
-static unsigned int * section_subset = NULL;
-
-bool
-load_debug_section (enum dwarf_section_display_enum debug, void * data)
-{
- struct dwarf_section * section = &debug_displays [debug].section;
- Elf_Internal_Shdr * sec;
- Filedata * filedata = (Filedata *) data;
-
- if (!dump_any_debugging)
- return false;
-
- /* Without section headers we cannot find any sections. */
- if (filedata->section_headers == NULL)
- return false;
-
- if (filedata->string_table == NULL
- && filedata->file_header.e_shstrndx != SHN_UNDEF
- && filedata->file_header.e_shstrndx < filedata->file_header.e_shnum)
- {
- Elf_Internal_Shdr * strs;
-
- /* Read in the string table, so that we have section names to scan. */
- strs = filedata->section_headers + filedata->file_header.e_shstrndx;
-
- if (strs != NULL && strs->sh_size != 0)
- {
- filedata->string_table
- = (char *) get_data (NULL, filedata, strs->sh_offset,
- 1, strs->sh_size, _("string table"));
-
- filedata->string_table_length
- = filedata->string_table != NULL ? strs->sh_size : 0;
- }
- }
-
- /* Locate the debug section. */
- sec = find_section_in_set (filedata, section->uncompressed_name, section_subset);
- if (sec != NULL)
- section->name = section->uncompressed_name;
- else
- {
- sec = find_section_in_set (filedata, section->compressed_name, section_subset);
- if (sec != NULL)
- section->name = section->compressed_name;
- }
- if (sec == NULL)
- return false;
-
- /* If we're loading from a subset of sections, and we've loaded
- a section matching this name before, it's likely that it's a
- different one. */
- if (section_subset != NULL)
- free_debug_section (debug);
-
- return load_specific_debug_section (debug, sec, data);
-}
-
-void
-free_debug_section (enum dwarf_section_display_enum debug)
-{
- struct dwarf_section * section = &debug_displays [debug].section;
-
- if (section->start == NULL)
- return;
-
- free ((char *) section->start);
- section->start = NULL;
- section->address = 0;
- section->size = 0;
-
- free (section->reloc_info);
- section->reloc_info = NULL;
- section->num_relocs = 0;
-}
-
-static bool
-display_debug_section (int shndx, Elf_Internal_Shdr * section, Filedata * filedata)
-{
- const char *name = (section_name_valid (filedata, section)
- ? section_name (filedata, section) : "");
- const char *print_name = printable_section_name (filedata, section);
- uint64_t length;
- bool result = true;
- int i;
-
- length = section->sh_size;
- if (length == 0)
- {
- printf (_("\nSection '%s' has no debugging data.\n"), print_name);
- return true;
- }
- if (section->sh_type == SHT_NOBITS)
- {
- /* There is no point in dumping the contents of a debugging section
- which has the NOBITS type - the bits in the file will be random.
- This can happen when a file containing a .eh_frame section is
- stripped with the --only-keep-debug command line option. */
- printf (_("section '%s' has the NOBITS type - its contents are unreliable.\n"),
- print_name);
- return false;
- }
-
- if (startswith (name, ".gnu.linkonce.wi."))
- name = ".debug_info";
-
- /* See if we know how to display the contents of this section. */
- for (i = 0; i < max; i++)
- {
- enum dwarf_section_display_enum id = (enum dwarf_section_display_enum) i;
- struct dwarf_section_display * display = debug_displays + i;
- struct dwarf_section * sec = & display->section;
-
- if (streq (sec->uncompressed_name, name)
- || (id == line && startswith (name, ".debug_line."))
- || streq (sec->compressed_name, name))
- {
- bool secondary = (section != find_section (filedata, name));
-
- if (secondary)
- free_debug_section (id);
-
- if (i == line && startswith (name, ".debug_line."))
- sec->name = name;
- else if (streq (sec->uncompressed_name, name))
- sec->name = sec->uncompressed_name;
- else
- sec->name = sec->compressed_name;
-
- if (load_specific_debug_section (id, section, filedata))
- {
- /* If this debug section is part of a CU/TU set in a .dwp file,
- restrict load_debug_section to the sections in that set. */
- section_subset = find_cu_tu_set (filedata, shndx);
-
- result &= display->display (sec, filedata);
-
- section_subset = NULL;
-
- if (secondary || (id != info && id != abbrev && id != debug_addr))
- free_debug_section (id);
- }
- break;
- }
- }
-
- if (i == max)
- {
- printf (_("Unrecognized debug section: %s\n"), print_name);
- result = false;
- }
-
- return result;
-}
-
-/* Set DUMP_SECTS for all sections where dumps were requested
- based on section name. */
-
-static void
-initialise_dumps_byname (Filedata * filedata)
-{
- struct dump_list_entry * cur;
-
- for (cur = dump_sects_byname; cur; cur = cur->next)
- {
- unsigned int i;
- bool any = false;
-
- for (i = 0; i < filedata->file_header.e_shnum; i++)
- if (section_name_valid (filedata, filedata->section_headers + i)
- && streq (section_name (filedata, filedata->section_headers + i),
- cur->name))
- {
- request_dump_bynumber (&filedata->dump, i, cur->type);
- any = true;
- }
-
- if (!any && !filedata->is_separate)
- warn (_("Section '%s' was not dumped because it does not exist\n"),
- cur->name);
- }
-}
-
-static bool
-process_section_contents (Filedata * filedata)
-{
- Elf_Internal_Shdr * section;
- unsigned int i;
- bool res = true;
-
- if (! do_dump)
- return true;
-
- initialise_dumps_byname (filedata);
-
- for (i = 0, section = filedata->section_headers;
- i < filedata->file_header.e_shnum && i < filedata->dump.num_dump_sects;
- i++, section++)
- {
- dump_type dump = filedata->dump.dump_sects[i];
-
- if (filedata->is_separate && ! process_links)
- dump &= DEBUG_DUMP;
-
- if (dump & AUTO_DUMP)
- {
- switch (section->sh_type)
- {
- case SHT_PROGBITS:
- /* FIXME: There are lots of different type of section that have
- SHT_PROGBITS set in their header - code, debug info, etc. So
- we should check the section's name and interpret its contents
- that way, rather than just defaulting to a byte dump. */
-#ifdef SUPPORT_DISASSEMBLY
- res &= disassemble_section (section, filedata);
-#else
- res &= dump_section_as_bytes (section, filedata, false);
-#endif
- break;
-
- case SHT_DYNSYM:
- case SHT_SYMTAB:
- res &= dump_symbol_section (section, filedata);
- break;
-
- case SHT_STRTAB:
- res &= dump_section_as_strings (section, filedata);
- break;
-
- case SHT_RELA:
- case SHT_REL:
- case SHT_RELR:
- res &= display_relocations (section, filedata);
- break;
-
- case SHT_NOTE:
- res &= process_notes_at (filedata, section, section->sh_offset,
- section->sh_size, section->sh_addralign);
- break;
-
- case SHT_NULL:
- inform (_("Unable to display section %d - it has a NULL type\n"), i);
- break;
-
- case SHT_NOBITS:
- inform (_("Unable to display section %d - it has no contents\n"), i);
- break;
-
- case SHT_HASH:
- case SHT_DYNAMIC:
- case SHT_GROUP:
- case SHT_GNU_ATTRIBUTES:
- /* FIXME: Implement these. */
- /* Fall through. */
- default:
- /* FIXME: Add Proc and OS specific section types ? */
- warn (_("Unable to determine how to dump section %d (type %#x)\n"),
- i, section->sh_type);
- res = false;
- break;
- }
- }
-
-#ifdef SUPPORT_DISASSEMBLY
- if (dump & DISASS_DUMP)
- {
- if (! disassemble_section (section, filedata))
- res = false;
- }
-#endif
- if (dump & HEX_DUMP)
- {
- if (! dump_section_as_bytes (section, filedata, false))
- res = false;
- }
-
- if (dump & RELOC_DUMP)
- {
- if (! dump_section_as_bytes (section, filedata, true))
- res = false;
- }
-
- if (dump & STRING_DUMP)
- {
- if (! dump_section_as_strings (section, filedata))
- res = false;
- }
-
- if (dump & DEBUG_DUMP)
- {
- if (! display_debug_section (i, section, filedata))
- res = false;
- }
-
-#ifdef ENABLE_LIBCTF
- if (dump & CTF_DUMP)
- {
- if (! dump_section_as_ctf (section, filedata))
- res = false;
- }
-#endif
- if (dump & SFRAME_DUMP)
- {
- if (! dump_section_as_sframe (section, filedata))
- res = false;
- }
- }
-
- if (! filedata->is_separate)
- {
- /* Check to see if the user requested a
- dump of a section that does not exist. */
- for (; i < filedata->dump.num_dump_sects; i++)
- if (filedata->dump.dump_sects[i])
- {
- warn (_("Section %d was not dumped because it does not exist!\n"), i);
- res = false;
- }
- }
-
- return res;
-}
-
-static void
-process_mips_fpe_exception (int mask)
-{
- if (mask)
- {
- bool first = true;
-
- if (mask & OEX_FPU_INEX)
- fputs ("INEX", stdout), first = false;
- if (mask & OEX_FPU_UFLO)
- printf ("%sUFLO", first ? "" : "|"), first = false;
- if (mask & OEX_FPU_OFLO)
- printf ("%sOFLO", first ? "" : "|"), first = false;
- if (mask & OEX_FPU_DIV0)
- printf ("%sDIV0", first ? "" : "|"), first = false;
- if (mask & OEX_FPU_INVAL)
- printf ("%sINVAL", first ? "" : "|");
- }
- else
- fputs ("0", stdout);
-}
-
-/* Display's the value of TAG at location P. If TAG is
- greater than 0 it is assumed to be an unknown tag, and
- a message is printed to this effect. Otherwise it is
- assumed that a message has already been printed.
-
- If the bottom bit of TAG is set it assumed to have a
- string value, otherwise it is assumed to have an integer
- value.
-
- Returns an updated P pointing to the first unread byte
- beyond the end of TAG's value.
-
- Reads at or beyond END will not be made. */
-
-static unsigned char *
-display_tag_value (signed int tag,
- unsigned char * p,
- const unsigned char * const end)
-{
- uint64_t val;
-
- if (tag > 0)
- printf (" Tag_unknown_%d: ", tag);
-
- if (p >= end)
- {
- warn (_("<corrupt tag>\n"));
- }
- else if (tag & 1)
- {
- /* PR 17531 file: 027-19978-0.004. */
- size_t maxlen = (end - p) - 1;
-
- putchar ('"');
- if (maxlen > 0)
- {
- print_symbol_name ((int) maxlen, (const char *) p);
- p += strnlen ((char *) p, maxlen) + 1;
- }
- else
- {
- printf (_("<corrupt string tag>"));
- p = (unsigned char *) end;
- }
- printf ("\"\n");
- }
- else
- {
- READ_ULEB (val, p, end);
- printf ("%" PRId64 " (0x%" PRIx64 ")\n", val, val);
- }
-
- assert (p <= end);
- return p;
-}
-
-/* ARC ABI attributes section. */
-
-static unsigned char *
-display_arc_attribute (unsigned char * p,
- const unsigned char * const end)
-{
- unsigned int tag;
- unsigned int val;
-
- READ_ULEB (tag, p, end);
-
- switch (tag)
- {
- case Tag_ARC_PCS_config:
- READ_ULEB (val, p, end);
- printf (" Tag_ARC_PCS_config: ");
- switch (val)
- {
- case 0:
- printf (_("Absent/Non standard\n"));
- break;
- case 1:
- printf (_("Bare metal/mwdt\n"));
- break;
- case 2:
- printf (_("Bare metal/newlib\n"));
- break;
- case 3:
- printf (_("Linux/uclibc\n"));
- break;
- case 4:
- printf (_("Linux/glibc\n"));
- break;
- default:
- printf (_("Unknown\n"));
- break;
- }
- break;
-
- case Tag_ARC_CPU_base:
- READ_ULEB (val, p, end);
- printf (" Tag_ARC_CPU_base: ");
- switch (val)
- {
- default:
- case TAG_CPU_NONE:
- printf (_("Absent\n"));
- break;
- case TAG_CPU_ARC6xx:
- printf ("ARC6xx\n");
- break;
- case TAG_CPU_ARC7xx:
- printf ("ARC7xx\n");
- break;
- case TAG_CPU_ARCEM:
- printf ("ARCEM\n");
- break;
- case TAG_CPU_ARCHS:
- printf ("ARCHS\n");
- break;
- }
- break;
-
- case Tag_ARC_CPU_variation:
- READ_ULEB (val, p, end);
- printf (" Tag_ARC_CPU_variation: ");
- switch (val)
- {
- default:
- if (val > 0 && val < 16)
- printf ("Core%d\n", val);
- else
- printf ("Unknown\n");
- break;
-
- case 0:
- printf (_("Absent\n"));
- break;
- }
- break;
-
- case Tag_ARC_CPU_name:
- printf (" Tag_ARC_CPU_name: ");
- p = display_tag_value (-1, p, end);
- break;
-
- case Tag_ARC_ABI_rf16:
- READ_ULEB (val, p, end);
- printf (" Tag_ARC_ABI_rf16: %s\n", val ? _("yes") : _("no"));
- break;
-
- case Tag_ARC_ABI_osver:
- READ_ULEB (val, p, end);
- printf (" Tag_ARC_ABI_osver: v%d\n", val);
- break;
-
- case Tag_ARC_ABI_pic:
- case Tag_ARC_ABI_sda:
- READ_ULEB (val, p, end);
- printf (tag == Tag_ARC_ABI_sda ? " Tag_ARC_ABI_sda: "
- : " Tag_ARC_ABI_pic: ");
- switch (val)
- {
- case 0:
- printf (_("Absent\n"));
- break;
- case 1:
- printf ("MWDT\n");
- break;
- case 2:
- printf ("GNU\n");
- break;
- default:
- printf (_("Unknown\n"));
- break;
- }
- break;
-
- case Tag_ARC_ABI_tls:
- READ_ULEB (val, p, end);
- printf (" Tag_ARC_ABI_tls: %s\n", val ? "r25": "none");
- break;
-
- case Tag_ARC_ABI_enumsize:
- READ_ULEB (val, p, end);
- printf (" Tag_ARC_ABI_enumsize: %s\n", val ? _("default") :
- _("smallest"));
- break;
-
- case Tag_ARC_ABI_exceptions:
- READ_ULEB (val, p, end);
- printf (" Tag_ARC_ABI_exceptions: %s\n", val ? _("OPTFP")
- : _("default"));
- break;
-
- case Tag_ARC_ABI_double_size:
- READ_ULEB (val, p, end);
- printf (" Tag_ARC_ABI_double_size: %d\n", val);
- break;
-
- case Tag_ARC_ISA_config:
- printf (" Tag_ARC_ISA_config: ");
- p = display_tag_value (-1, p, end);
- break;
-
- case Tag_ARC_ISA_apex:
- printf (" Tag_ARC_ISA_apex: ");
- p = display_tag_value (-1, p, end);
- break;
-
- case Tag_ARC_ISA_mpy_option:
- READ_ULEB (val, p, end);
- printf (" Tag_ARC_ISA_mpy_option: %d\n", val);
- break;
-
- case Tag_ARC_ATR_version:
- READ_ULEB (val, p, end);
- printf (" Tag_ARC_ATR_version: %d\n", val);
- break;
-
- default:
- return display_tag_value (tag & 1, p, end);
- }
-
- return p;
-}
-
-/* ARM EABI attributes section. */
-typedef struct
-{
- unsigned int tag;
- const char * name;
- /* 0 = special, 1 = string, 2 = uleb123, > 0x80 == table lookup. */
- unsigned int type;
- const char *const *table;
-} arm_attr_public_tag;
-
-static const char *const arm_attr_tag_CPU_arch[] =
- {"Pre-v4", "v4", "v4T", "v5T", "v5TE", "v5TEJ", "v6", "v6KZ", "v6T2",
- "v6K", "v7", "v6-M", "v6S-M", "v7E-M", "v8", "v8-R", "v8-M.baseline",
- "v8-M.mainline", "v8.1-A", "v8.2-A", "v8.3-A",
- "v8.1-M.mainline", "v9"};
-static const char *const arm_attr_tag_ARM_ISA_use[] = {"No", "Yes"};
-static const char *const arm_attr_tag_THUMB_ISA_use[] =
- {"No", "Thumb-1", "Thumb-2", "Yes"};
-static const char *const arm_attr_tag_FP_arch[] =
- {"No", "VFPv1", "VFPv2", "VFPv3", "VFPv3-D16", "VFPv4", "VFPv4-D16",
- "FP for ARMv8", "FPv5/FP-D16 for ARMv8"};
-static const char *const arm_attr_tag_WMMX_arch[] = {"No", "WMMXv1", "WMMXv2"};
-static const char *const arm_attr_tag_Advanced_SIMD_arch[] =
- {"No", "NEONv1", "NEONv1 with Fused-MAC", "NEON for ARMv8",
- "NEON for ARMv8.1"};
-static const char *const arm_attr_tag_PCS_config[] =
- {"None", "Bare platform", "Linux application", "Linux DSO", "PalmOS 2004",
- "PalmOS (reserved)", "SymbianOS 2004", "SymbianOS (reserved)"};
-static const char *const arm_attr_tag_ABI_PCS_R9_use[] =
- {"V6", "SB", "TLS", "Unused"};
-static const char *const arm_attr_tag_ABI_PCS_RW_data[] =
- {"Absolute", "PC-relative", "SB-relative", "None"};
-static const char *const arm_attr_tag_ABI_PCS_RO_data[] =
- {"Absolute", "PC-relative", "None"};
-static const char *const arm_attr_tag_ABI_PCS_GOT_use[] =
- {"None", "direct", "GOT-indirect"};
-static const char *const arm_attr_tag_ABI_PCS_wchar_t[] =
- {"None", "??? 1", "2", "??? 3", "4"};
-static const char *const arm_attr_tag_ABI_FP_rounding[] = {"Unused", "Needed"};
-static const char *const arm_attr_tag_ABI_FP_denormal[] =
- {"Unused", "Needed", "Sign only"};
-static const char *const arm_attr_tag_ABI_FP_exceptions[] = {"Unused", "Needed"};
-static const char *const arm_attr_tag_ABI_FP_user_exceptions[] = {"Unused", "Needed"};
-static const char *const arm_attr_tag_ABI_FP_number_model[] =
- {"Unused", "Finite", "RTABI", "IEEE 754"};
-static const char *const arm_attr_tag_ABI_enum_size[] =
- {"Unused", "small", "int", "forced to int"};
-static const char *const arm_attr_tag_ABI_HardFP_use[] =
- {"As Tag_FP_arch", "SP only", "Reserved", "Deprecated"};
-static const char *const arm_attr_tag_ABI_VFP_args[] =
- {"AAPCS", "VFP registers", "custom", "compatible"};
-static const char *const arm_attr_tag_ABI_WMMX_args[] =
- {"AAPCS", "WMMX registers", "custom"};
-static const char *const arm_attr_tag_ABI_optimization_goals[] =
- {"None", "Prefer Speed", "Aggressive Speed", "Prefer Size",
- "Aggressive Size", "Prefer Debug", "Aggressive Debug"};
-static const char *const arm_attr_tag_ABI_FP_optimization_goals[] =
- {"None", "Prefer Speed", "Aggressive Speed", "Prefer Size",
- "Aggressive Size", "Prefer Accuracy", "Aggressive Accuracy"};
-static const char *const arm_attr_tag_CPU_unaligned_access[] = {"None", "v6"};
-static const char *const arm_attr_tag_FP_HP_extension[] =
- {"Not Allowed", "Allowed"};
-static const char *const arm_attr_tag_ABI_FP_16bit_format[] =
- {"None", "IEEE 754", "Alternative Format"};
-static const char *const arm_attr_tag_DSP_extension[] =
- {"Follow architecture", "Allowed"};
-static const char *const arm_attr_tag_MPextension_use[] =
- {"Not Allowed", "Allowed"};
-static const char *const arm_attr_tag_DIV_use[] =
- {"Allowed in Thumb-ISA, v7-R or v7-M", "Not allowed",
- "Allowed in v7-A with integer division extension"};
-static const char *const arm_attr_tag_T2EE_use[] = {"Not Allowed", "Allowed"};
-static const char *const arm_attr_tag_Virtualization_use[] =
- {"Not Allowed", "TrustZone", "Virtualization Extensions",
- "TrustZone and Virtualization Extensions"};
-static const char *const arm_attr_tag_MPextension_use_legacy[] =
- {"Not Allowed", "Allowed"};
-
-static const char *const arm_attr_tag_MVE_arch[] =
- {"No MVE", "MVE Integer only", "MVE Integer and FP"};
-
-static const char * arm_attr_tag_PAC_extension[] =
- {"No PAC/AUT instructions",
- "PAC/AUT instructions permitted in the NOP space",
- "PAC/AUT instructions permitted in the NOP and in the non-NOP space"};
-
-static const char * arm_attr_tag_BTI_extension[] =
- {"BTI instructions not permitted",
- "BTI instructions permitted in the NOP space",
- "BTI instructions permitted in the NOP and in the non-NOP space"};
-
-static const char * arm_attr_tag_BTI_use[] =
- {"Compiled without branch target enforcement",
- "Compiled with branch target enforcement"};
-
-static const char * arm_attr_tag_PACRET_use[] =
- {"Compiled without return address signing and authentication",
- "Compiled with return address signing and authentication"};
-
-#define LOOKUP(id, name) \
- {id, #name, 0x80 | ARRAY_SIZE(arm_attr_tag_##name), arm_attr_tag_##name}
-static arm_attr_public_tag arm_attr_public_tags[] =
-{
- {4, "CPU_raw_name", 1, NULL},
- {5, "CPU_name", 1, NULL},
- LOOKUP(6, CPU_arch),
- {7, "CPU_arch_profile", 0, NULL},
- LOOKUP(8, ARM_ISA_use),
- LOOKUP(9, THUMB_ISA_use),
- LOOKUP(10, FP_arch),
- LOOKUP(11, WMMX_arch),
- LOOKUP(12, Advanced_SIMD_arch),
- LOOKUP(13, PCS_config),
- LOOKUP(14, ABI_PCS_R9_use),
- LOOKUP(15, ABI_PCS_RW_data),
- LOOKUP(16, ABI_PCS_RO_data),
- LOOKUP(17, ABI_PCS_GOT_use),
- LOOKUP(18, ABI_PCS_wchar_t),
- LOOKUP(19, ABI_FP_rounding),
- LOOKUP(20, ABI_FP_denormal),
- LOOKUP(21, ABI_FP_exceptions),
- LOOKUP(22, ABI_FP_user_exceptions),
- LOOKUP(23, ABI_FP_number_model),
- {24, "ABI_align_needed", 0, NULL},
- {25, "ABI_align_preserved", 0, NULL},
- LOOKUP(26, ABI_enum_size),
- LOOKUP(27, ABI_HardFP_use),
- LOOKUP(28, ABI_VFP_args),
- LOOKUP(29, ABI_WMMX_args),
- LOOKUP(30, ABI_optimization_goals),
- LOOKUP(31, ABI_FP_optimization_goals),
- {32, "compatibility", 0, NULL},
- LOOKUP(34, CPU_unaligned_access),
- LOOKUP(36, FP_HP_extension),
- LOOKUP(38, ABI_FP_16bit_format),
- LOOKUP(42, MPextension_use),
- LOOKUP(44, DIV_use),
- LOOKUP(46, DSP_extension),
- LOOKUP(48, MVE_arch),
- LOOKUP(50, PAC_extension),
- LOOKUP(52, BTI_extension),
- LOOKUP(74, BTI_use),
- LOOKUP(76, PACRET_use),
- {64, "nodefaults", 0, NULL},
- {65, "also_compatible_with", 0, NULL},
- LOOKUP(66, T2EE_use),
- {67, "conformance", 1, NULL},
- LOOKUP(68, Virtualization_use),
- LOOKUP(70, MPextension_use_legacy)
-};
-#undef LOOKUP
-
-static unsigned char *
-display_arm_attribute (unsigned char * p,
- const unsigned char * const end)
-{
- unsigned int tag;
- unsigned int val;
- arm_attr_public_tag * attr;
- unsigned i;
- unsigned int type;
-
- READ_ULEB (tag, p, end);
- attr = NULL;
- for (i = 0; i < ARRAY_SIZE (arm_attr_public_tags); i++)
- {
- if (arm_attr_public_tags[i].tag == tag)
- {
- attr = &arm_attr_public_tags[i];
- break;
- }
- }
-
- if (attr)
- {
- printf (" Tag_%s: ", attr->name);
- switch (attr->type)
- {
- case 0:
- switch (tag)
- {
- case 7: /* Tag_CPU_arch_profile. */
- READ_ULEB (val, p, end);
- switch (val)
- {
- case 0: printf (_("None\n")); break;
- case 'A': printf (_("Application\n")); break;
- case 'R': printf (_("Realtime\n")); break;
- case 'M': printf (_("Microcontroller\n")); break;
- case 'S': printf (_("Application or Realtime\n")); break;
- default: printf ("??? (%d)\n", val); break;
- }
- break;
-
- case 24: /* Tag_align_needed. */
- READ_ULEB (val, p, end);
- switch (val)
- {
- case 0: printf (_("None\n")); break;
- case 1: printf (_("8-byte\n")); break;
- case 2: printf (_("4-byte\n")); break;
- case 3: printf ("??? 3\n"); break;
- default:
- if (val <= 12)
- printf (_("8-byte and up to %d-byte extended\n"),
- 1 << val);
- else
- printf ("??? (%d)\n", val);
- break;
- }
- break;
-
- case 25: /* Tag_align_preserved. */
- READ_ULEB (val, p, end);
- switch (val)
- {
- case 0: printf (_("None\n")); break;
- case 1: printf (_("8-byte, except leaf SP\n")); break;
- case 2: printf (_("8-byte\n")); break;
- case 3: printf ("??? 3\n"); break;
- default:
- if (val <= 12)
- printf (_("8-byte and up to %d-byte extended\n"),
- 1 << val);
- else
- printf ("??? (%d)\n", val);
- break;
- }
- break;
-
- case 32: /* Tag_compatibility. */
- {
- READ_ULEB (val, p, end);
- printf (_("flag = %d, vendor = "), val);
- if (p < end - 1)
- {
- size_t maxlen = (end - p) - 1;
-
- print_symbol_name ((int) maxlen, (const char *) p);
- p += strnlen ((char *) p, maxlen) + 1;
- }
- else
- {
- printf (_("<corrupt>"));
- p = (unsigned char *) end;
- }
- putchar ('\n');
- }
- break;
-
- case 64: /* Tag_nodefaults. */
- /* PR 17531: file: 001-505008-0.01. */
- if (p < end)
- p++;
- printf (_("True\n"));
- break;
-
- case 65: /* Tag_also_compatible_with. */
- READ_ULEB (val, p, end);
- if (val == 6 /* Tag_CPU_arch. */)
- {
- READ_ULEB (val, p, end);
- if ((unsigned int) val >= ARRAY_SIZE (arm_attr_tag_CPU_arch))
- printf ("??? (%d)\n", val);
- else
- printf ("%s\n", arm_attr_tag_CPU_arch[val]);
- }
- else
- printf ("???\n");
- while (p < end && *(p++) != '\0' /* NUL terminator. */)
- ;
- break;
-
- default:
- printf (_("<unknown: %d>\n"), tag);
- break;
- }
- return p;
-
- case 1:
- return display_tag_value (-1, p, end);
- case 2:
- return display_tag_value (0, p, end);
-
- default:
- assert (attr->type & 0x80);
- READ_ULEB (val, p, end);
- type = attr->type & 0x7f;
- if (val >= type)
- printf ("??? (%d)\n", val);
- else
- printf ("%s\n", attr->table[val]);
- return p;
- }
- }
-
- return display_tag_value (tag, p, end);
-}
-
-static unsigned char *
-display_gnu_attribute (unsigned char * p,
- unsigned char * (* display_proc_gnu_attribute)
- (unsigned char *, unsigned int, const unsigned char * const),
- const unsigned char * const end)
-{
- unsigned int tag;
- unsigned int val;
-
- READ_ULEB (tag, p, end);
-
- /* Tag_compatibility is the only generic GNU attribute defined at
- present. */
- if (tag == 32)
- {
- READ_ULEB (val, p, end);
-
- printf (_("flag = %d, vendor = "), val);
- if (p == end)
- {
- printf (_("<corrupt>\n"));
- warn (_("corrupt vendor attribute\n"));
- }
- else
- {
- if (p < end - 1)
- {
- size_t maxlen = (end - p) - 1;
-
- print_symbol_name ((int) maxlen, (const char *) p);
- p += strnlen ((char *) p, maxlen) + 1;
- }
- else
- {
- printf (_("<corrupt>"));
- p = (unsigned char *) end;
- }
- putchar ('\n');
- }
- return p;
- }
-
- if ((tag & 2) == 0 && display_proc_gnu_attribute)
- return display_proc_gnu_attribute (p, tag, end);
-
- return display_tag_value (tag, p, end);
-}
-
-static unsigned char *
-display_m68k_gnu_attribute (unsigned char * p,
- unsigned int tag,
- const unsigned char * const end)
-{
- unsigned int val;
-
- if (tag == Tag_GNU_M68K_ABI_FP)
- {
- printf (" Tag_GNU_M68K_ABI_FP: ");
- if (p == end)
- {
- printf (_("<corrupt>\n"));
- return p;
- }
- READ_ULEB (val, p, end);
-
- if (val > 3)
- printf ("(%#x), ", val);
-
- switch (val & 3)
- {
- case 0:
- printf (_("unspecified hard/soft float\n"));
- break;
- case 1:
- printf (_("hard float\n"));
- break;
- case 2:
- printf (_("soft float\n"));
- break;
- }
- return p;
- }
-
- return display_tag_value (tag & 1, p, end);
-}
-
-static unsigned char *
-display_power_gnu_attribute (unsigned char * p,
- unsigned int tag,
- const unsigned char * const end)
-{
- unsigned int val;
-
- if (tag == Tag_GNU_Power_ABI_FP)
- {
- printf (" Tag_GNU_Power_ABI_FP: ");
- if (p == end)
- {
- printf (_("<corrupt>\n"));
- return p;
- }
- READ_ULEB (val, p, end);
-
- if (val > 15)
- printf ("(%#x), ", val);
-
- switch (val & 3)
- {
- case 0:
- printf (_("unspecified hard/soft float, "));
- break;
- case 1:
- printf (_("hard float, "));
- break;
- case 2:
- printf (_("soft float, "));
- break;
- case 3:
- printf (_("single-precision hard float, "));
- break;
- }
-
- switch (val & 0xC)
- {
- case 0:
- printf (_("unspecified long double\n"));
- break;
- case 4:
- printf (_("128-bit IBM long double\n"));
- break;
- case 8:
- printf (_("64-bit long double\n"));
- break;
- case 12:
- printf (_("128-bit IEEE long double\n"));
- break;
- }
- return p;
- }
-
- if (tag == Tag_GNU_Power_ABI_Vector)
- {
- printf (" Tag_GNU_Power_ABI_Vector: ");
- if (p == end)
- {
- printf (_("<corrupt>\n"));
- return p;
- }
- READ_ULEB (val, p, end);
-
- if (val > 3)
- printf ("(%#x), ", val);
-
- switch (val & 3)
- {
- case 0:
- printf (_("unspecified\n"));
- break;
- case 1:
- printf (_("generic\n"));
- break;
- case 2:
- printf ("AltiVec\n");
- break;
- case 3:
- printf ("SPE\n");
- break;
- }
- return p;
- }
-
- if (tag == Tag_GNU_Power_ABI_Struct_Return)
- {
- printf (" Tag_GNU_Power_ABI_Struct_Return: ");
- if (p == end)
- {
- printf (_("<corrupt>\n"));
- return p;
- }
- READ_ULEB (val, p, end);
-
- if (val > 2)
- printf ("(%#x), ", val);
-
- switch (val & 3)
- {
- case 0:
- printf (_("unspecified\n"));
- break;
- case 1:
- printf ("r3/r4\n");
- break;
- case 2:
- printf (_("memory\n"));
- break;
- case 3:
- printf ("???\n");
- break;
- }
- return p;
- }
-
- return display_tag_value (tag & 1, p, end);
-}
-
-static unsigned char *
-display_s390_gnu_attribute (unsigned char * p,
- unsigned int tag,
- const unsigned char * const end)
-{
- unsigned int val;
-
- if (tag == Tag_GNU_S390_ABI_Vector)
- {
- printf (" Tag_GNU_S390_ABI_Vector: ");
- READ_ULEB (val, p, end);
-
- switch (val)
- {
- case 0:
- printf (_("any\n"));
- break;
- case 1:
- printf (_("software\n"));
- break;
- case 2:
- printf (_("hardware\n"));
- break;
- default:
- printf ("??? (%d)\n", val);
- break;
- }
- return p;
- }
-
- return display_tag_value (tag & 1, p, end);
-}
-
-static void
-display_sparc_hwcaps (unsigned int mask)
-{
- if (mask)
- {
- bool first = true;
-
- if (mask & ELF_SPARC_HWCAP_MUL32)
- fputs ("mul32", stdout), first = false;
- if (mask & ELF_SPARC_HWCAP_DIV32)
- printf ("%sdiv32", first ? "" : "|"), first = false;
- if (mask & ELF_SPARC_HWCAP_FSMULD)
- printf ("%sfsmuld", first ? "" : "|"), first = false;
- if (mask & ELF_SPARC_HWCAP_V8PLUS)
- printf ("%sv8plus", first ? "" : "|"), first = false;
- if (mask & ELF_SPARC_HWCAP_POPC)
- printf ("%spopc", first ? "" : "|"), first = false;
- if (mask & ELF_SPARC_HWCAP_VIS)
- printf ("%svis", first ? "" : "|"), first = false;
- if (mask & ELF_SPARC_HWCAP_VIS2)
- printf ("%svis2", first ? "" : "|"), first = false;
- if (mask & ELF_SPARC_HWCAP_ASI_BLK_INIT)
- printf ("%sASIBlkInit", first ? "" : "|"), first = false;
- if (mask & ELF_SPARC_HWCAP_FMAF)
- printf ("%sfmaf", first ? "" : "|"), first = false;
- if (mask & ELF_SPARC_HWCAP_VIS3)
- printf ("%svis3", first ? "" : "|"), first = false;
- if (mask & ELF_SPARC_HWCAP_HPC)
- printf ("%shpc", first ? "" : "|"), first = false;
- if (mask & ELF_SPARC_HWCAP_RANDOM)
- printf ("%srandom", first ? "" : "|"), first = false;
- if (mask & ELF_SPARC_HWCAP_TRANS)
- printf ("%strans", first ? "" : "|"), first = false;
- if (mask & ELF_SPARC_HWCAP_FJFMAU)
- printf ("%sfjfmau", first ? "" : "|"), first = false;
- if (mask & ELF_SPARC_HWCAP_IMA)
- printf ("%sima", first ? "" : "|"), first = false;
- if (mask & ELF_SPARC_HWCAP_ASI_CACHE_SPARING)
- printf ("%scspare", first ? "" : "|"), first = false;
- }
- else
- fputc ('0', stdout);
- fputc ('\n', stdout);
-}
-
-static void
-display_sparc_hwcaps2 (unsigned int mask)
-{
- if (mask)
- {
- bool first = true;
-
- if (mask & ELF_SPARC_HWCAP2_FJATHPLUS)
- fputs ("fjathplus", stdout), first = false;
- if (mask & ELF_SPARC_HWCAP2_VIS3B)
- printf ("%svis3b", first ? "" : "|"), first = false;
- if (mask & ELF_SPARC_HWCAP2_ADP)
- printf ("%sadp", first ? "" : "|"), first = false;
- if (mask & ELF_SPARC_HWCAP2_SPARC5)
- printf ("%ssparc5", first ? "" : "|"), first = false;
- if (mask & ELF_SPARC_HWCAP2_MWAIT)
- printf ("%smwait", first ? "" : "|"), first = false;
- if (mask & ELF_SPARC_HWCAP2_XMPMUL)
- printf ("%sxmpmul", first ? "" : "|"), first = false;
- if (mask & ELF_SPARC_HWCAP2_XMONT)
- printf ("%sxmont2", first ? "" : "|"), first = false;
- if (mask & ELF_SPARC_HWCAP2_NSEC)
- printf ("%snsec", first ? "" : "|"), first = false;
- if (mask & ELF_SPARC_HWCAP2_FJATHHPC)
- printf ("%sfjathhpc", first ? "" : "|"), first = false;
- if (mask & ELF_SPARC_HWCAP2_FJDES)
- printf ("%sfjdes", first ? "" : "|"), first = false;
- if (mask & ELF_SPARC_HWCAP2_FJAES)
- printf ("%sfjaes", first ? "" : "|"), first = false;
- }
- else
- fputc ('0', stdout);
- fputc ('\n', stdout);
-}
-
-static unsigned char *
-display_sparc_gnu_attribute (unsigned char * p,
- unsigned int tag,
- const unsigned char * const end)
-{
- unsigned int val;
-
- if (tag == Tag_GNU_Sparc_HWCAPS)
- {
- READ_ULEB (val, p, end);
- printf (" Tag_GNU_Sparc_HWCAPS: ");
- display_sparc_hwcaps (val);
- return p;
- }
- if (tag == Tag_GNU_Sparc_HWCAPS2)
- {
- READ_ULEB (val, p, end);
- printf (" Tag_GNU_Sparc_HWCAPS2: ");
- display_sparc_hwcaps2 (val);
- return p;
- }
-
- return display_tag_value (tag, p, end);
-}
-
-static void
-print_mips_fp_abi_value (unsigned int val)
-{
- switch (val)
- {
- case Val_GNU_MIPS_ABI_FP_ANY:
- printf (_("Hard or soft float\n"));
- break;
- case Val_GNU_MIPS_ABI_FP_DOUBLE:
- printf (_("Hard float (double precision)\n"));
- break;
- case Val_GNU_MIPS_ABI_FP_SINGLE:
- printf (_("Hard float (single precision)\n"));
- break;
- case Val_GNU_MIPS_ABI_FP_SOFT:
- printf (_("Soft float\n"));
- break;
- case Val_GNU_MIPS_ABI_FP_OLD_64:
- printf (_("Hard float (MIPS32r2 64-bit FPU 12 callee-saved)\n"));
- break;
- case Val_GNU_MIPS_ABI_FP_XX:
- printf (_("Hard float (32-bit CPU, Any FPU)\n"));
- break;
- case Val_GNU_MIPS_ABI_FP_64:
- printf (_("Hard float (32-bit CPU, 64-bit FPU)\n"));
- break;
- case Val_GNU_MIPS_ABI_FP_64A:
- printf (_("Hard float compat (32-bit CPU, 64-bit FPU)\n"));
- break;
- case Val_GNU_MIPS_ABI_FP_NAN2008:
- printf (_("NaN 2008 compatibility\n"));
- break;
- default:
- printf ("??? (%d)\n", val);
- break;
- }
-}
-
-static unsigned char *
-display_mips_gnu_attribute (unsigned char * p,
- unsigned int tag,
- const unsigned char * const end)
-{
- if (tag == Tag_GNU_MIPS_ABI_FP)
- {
- unsigned int val;
-
- printf (" Tag_GNU_MIPS_ABI_FP: ");
- READ_ULEB (val, p, end);
- print_mips_fp_abi_value (val);
- return p;
- }
-
- if (tag == Tag_GNU_MIPS_ABI_MSA)
- {
- unsigned int val;
-
- printf (" Tag_GNU_MIPS_ABI_MSA: ");
- READ_ULEB (val, p, end);
-
- switch (val)
- {
- case Val_GNU_MIPS_ABI_MSA_ANY:
- printf (_("Any MSA or not\n"));
- break;
- case Val_GNU_MIPS_ABI_MSA_128:
- printf (_("128-bit MSA\n"));
- break;
- default:
- printf ("??? (%d)\n", val);
- break;
- }
- return p;
- }
-
- return display_tag_value (tag & 1, p, end);
-}
-
-static unsigned char *
-display_tic6x_attribute (unsigned char * p,
- const unsigned char * const end)
-{
- unsigned int tag;
- unsigned int val;
-
- READ_ULEB (tag, p, end);
-
- switch (tag)
- {
- case Tag_ISA:
- printf (" Tag_ISA: ");
- READ_ULEB (val, p, end);
-
- switch (val)
- {
- case C6XABI_Tag_ISA_none:
- printf (_("None\n"));
- break;
- case C6XABI_Tag_ISA_C62X:
- printf ("C62x\n");
- break;
- case C6XABI_Tag_ISA_C67X:
- printf ("C67x\n");
- break;
- case C6XABI_Tag_ISA_C67XP:
- printf ("C67x+\n");
- break;
- case C6XABI_Tag_ISA_C64X:
- printf ("C64x\n");
- break;
- case C6XABI_Tag_ISA_C64XP:
- printf ("C64x+\n");
- break;
- case C6XABI_Tag_ISA_C674X:
- printf ("C674x\n");
- break;
- default:
- printf ("??? (%d)\n", val);
- break;
- }
- return p;
-
- case Tag_ABI_wchar_t:
- printf (" Tag_ABI_wchar_t: ");
- READ_ULEB (val, p, end);
- switch (val)
- {
- case 0:
- printf (_("Not used\n"));
- break;
- case 1:
- printf (_("2 bytes\n"));
- break;
- case 2:
- printf (_("4 bytes\n"));
- break;
- default:
- printf ("??? (%d)\n", val);
- break;
- }
- return p;
-
- case Tag_ABI_stack_align_needed:
- printf (" Tag_ABI_stack_align_needed: ");
- READ_ULEB (val, p, end);
- switch (val)
- {
- case 0:
- printf (_("8-byte\n"));
- break;
- case 1:
- printf (_("16-byte\n"));
- break;
- default:
- printf ("??? (%d)\n", val);
- break;
- }
- return p;
-
- case Tag_ABI_stack_align_preserved:
- READ_ULEB (val, p, end);
- printf (" Tag_ABI_stack_align_preserved: ");
- switch (val)
- {
- case 0:
- printf (_("8-byte\n"));
- break;
- case 1:
- printf (_("16-byte\n"));
- break;
- default:
- printf ("??? (%d)\n", val);
- break;
- }
- return p;
-
- case Tag_ABI_DSBT:
- READ_ULEB (val, p, end);
- printf (" Tag_ABI_DSBT: ");
- switch (val)
- {
- case 0:
- printf (_("DSBT addressing not used\n"));
- break;
- case 1:
- printf (_("DSBT addressing used\n"));
- break;
- default:
- printf ("??? (%d)\n", val);
- break;
- }
- return p;
-
- case Tag_ABI_PID:
- READ_ULEB (val, p, end);
- printf (" Tag_ABI_PID: ");
- switch (val)
- {
- case 0:
- printf (_("Data addressing position-dependent\n"));
- break;
- case 1:
- printf (_("Data addressing position-independent, GOT near DP\n"));
- break;
- case 2:
- printf (_("Data addressing position-independent, GOT far from DP\n"));
- break;
- default:
- printf ("??? (%d)\n", val);
- break;
- }
- return p;
-
- case Tag_ABI_PIC:
- READ_ULEB (val, p, end);
- printf (" Tag_ABI_PIC: ");
- switch (val)
- {
- case 0:
- printf (_("Code addressing position-dependent\n"));
- break;
- case 1:
- printf (_("Code addressing position-independent\n"));
- break;
- default:
- printf ("??? (%d)\n", val);
- break;
- }
- return p;
-
- case Tag_ABI_array_object_alignment:
- READ_ULEB (val, p, end);
- printf (" Tag_ABI_array_object_alignment: ");
- switch (val)
- {
- case 0:
- printf (_("8-byte\n"));
- break;
- case 1:
- printf (_("4-byte\n"));
- break;
- case 2:
- printf (_("16-byte\n"));
- break;
- default:
- printf ("??? (%d)\n", val);
- break;
- }
- return p;
-
- case Tag_ABI_array_object_align_expected:
- READ_ULEB (val, p, end);
- printf (" Tag_ABI_array_object_align_expected: ");
- switch (val)
- {
- case 0:
- printf (_("8-byte\n"));
- break;
- case 1:
- printf (_("4-byte\n"));
- break;
- case 2:
- printf (_("16-byte\n"));
- break;
- default:
- printf ("??? (%d)\n", val);
- break;
- }
- return p;
-
- case Tag_ABI_compatibility:
- {
- READ_ULEB (val, p, end);
- printf (" Tag_ABI_compatibility: ");
- printf (_("flag = %d, vendor = "), val);
- if (p < end - 1)
- {
- size_t maxlen = (end - p) - 1;
-
- print_symbol_name ((int) maxlen, (const char *) p);
- p += strnlen ((char *) p, maxlen) + 1;
- }
- else
- {
- printf (_("<corrupt>"));
- p = (unsigned char *) end;
- }
- putchar ('\n');
- return p;
- }
-
- case Tag_ABI_conformance:
- {
- printf (" Tag_ABI_conformance: \"");
- if (p < end - 1)
- {
- size_t maxlen = (end - p) - 1;
-
- print_symbol_name ((int) maxlen, (const char *) p);
- p += strnlen ((char *) p, maxlen) + 1;
- }
- else
- {
- printf (_("<corrupt>"));
- p = (unsigned char *) end;
- }
- printf ("\"\n");
- return p;
- }
- }
-
- return display_tag_value (tag, p, end);
-}
-
-static void
-display_raw_attribute (unsigned char * p, unsigned char const * const end)
-{
- uint64_t addr = 0;
- size_t bytes = end - p;
-
- assert (end >= p);
- while (bytes)
- {
- int j;
- int k;
- int lbytes = (bytes > 16 ? 16 : bytes);
-
- printf (" 0x%8.8" PRIx64 " ", addr);
-
- for (j = 0; j < 16; j++)
- {
- if (j < lbytes)
- printf ("%2.2x", p[j]);
- else
- printf (" ");
-
- if ((j & 3) == 3)
- printf (" ");
- }
-
- for (j = 0; j < lbytes; j++)
- {
- k = p[j];
- if (k >= ' ' && k < 0x7f)
- printf ("%c", k);
- else
- printf (".");
- }
-
- putchar ('\n');
-
- p += lbytes;
- bytes -= lbytes;
- addr += lbytes;
- }
-
- putchar ('\n');
-}
-
-static unsigned char *
-display_msp430_attribute (unsigned char * p,
- const unsigned char * const end)
-{
- uint64_t val;
- uint64_t tag;
-
- READ_ULEB (tag, p, end);
-
- switch (tag)
- {
- case OFBA_MSPABI_Tag_ISA:
- printf (" Tag_ISA: ");
- READ_ULEB (val, p, end);
- switch (val)
- {
- case 0: printf (_("None\n")); break;
- case 1: printf (_("MSP430\n")); break;
- case 2: printf (_("MSP430X\n")); break;
- default: printf ("??? (%" PRId64 ")\n", val); break;
- }
- break;
-
- case OFBA_MSPABI_Tag_Code_Model:
- printf (" Tag_Code_Model: ");
- READ_ULEB (val, p, end);
- switch (val)
- {
- case 0: printf (_("None\n")); break;
- case 1: printf (_("Small\n")); break;
- case 2: printf (_("Large\n")); break;
- default: printf ("??? (%" PRId64 ")\n", val); break;
- }
- break;
-
- case OFBA_MSPABI_Tag_Data_Model:
- printf (" Tag_Data_Model: ");
- READ_ULEB (val, p, end);
- switch (val)
- {
- case 0: printf (_("None\n")); break;
- case 1: printf (_("Small\n")); break;
- case 2: printf (_("Large\n")); break;
- case 3: printf (_("Restricted Large\n")); break;
- default: printf ("??? (%" PRId64 ")\n", val); break;
- }
- break;
-
- default:
- printf (_(" <unknown tag %" PRId64 ">: "), tag);
-
- if (tag & 1)
- {
- putchar ('"');
- if (p < end - 1)
- {
- size_t maxlen = (end - p) - 1;
-
- print_symbol_name ((int) maxlen, (const char *) p);
- p += strnlen ((char *) p, maxlen) + 1;
- }
- else
- {
- printf (_("<corrupt>"));
- p = (unsigned char *) end;
- }
- printf ("\"\n");
- }
- else
- {
- READ_ULEB (val, p, end);
- printf ("%" PRId64 " (0x%" PRIx64 ")\n", val, val);
- }
- break;
- }
-
- assert (p <= end);
- return p;
-}
-
-static unsigned char *
-display_msp430_gnu_attribute (unsigned char * p,
- unsigned int tag,
- const unsigned char * const end)
-{
- if (tag == Tag_GNU_MSP430_Data_Region)
- {
- uint64_t val;
-
- printf (" Tag_GNU_MSP430_Data_Region: ");
- READ_ULEB (val, p, end);
-
- switch (val)
- {
- case Val_GNU_MSP430_Data_Region_Any:
- printf (_("Any Region\n"));
- break;
- case Val_GNU_MSP430_Data_Region_Lower:
- printf (_("Lower Region Only\n"));
- break;
- default:
- printf ("??? (%" PRIu64 ")\n", val);
- }
- return p;
- }
- return display_tag_value (tag & 1, p, end);
-}
-
-struct riscv_attr_tag_t {
- const char *name;
- unsigned int tag;
-};
-
-static struct riscv_attr_tag_t riscv_attr_tag[] =
-{
-#define T(tag) {"Tag_RISCV_" #tag, Tag_RISCV_##tag}
- T(arch),
- T(priv_spec),
- T(priv_spec_minor),
- T(priv_spec_revision),
- T(unaligned_access),
- T(stack_align),
-#undef T
-};
-
-static unsigned char *
-display_riscv_attribute (unsigned char *p,
- const unsigned char * const end)
-{
- uint64_t val;
- uint64_t tag;
- struct riscv_attr_tag_t *attr = NULL;
- unsigned i;
-
- READ_ULEB (tag, p, end);
-
- /* Find the name of attribute. */
- for (i = 0; i < ARRAY_SIZE (riscv_attr_tag); i++)
- {
- if (riscv_attr_tag[i].tag == tag)
- {
- attr = &riscv_attr_tag[i];
- break;
- }
- }
-
- if (attr)
- printf (" %s: ", attr->name);
- else
- return display_tag_value (tag, p, end);
-
- switch (tag)
- {
- case Tag_RISCV_priv_spec:
- case Tag_RISCV_priv_spec_minor:
- case Tag_RISCV_priv_spec_revision:
- READ_ULEB (val, p, end);
- printf ("%" PRIu64 "\n", val);
- break;
- case Tag_RISCV_unaligned_access:
- READ_ULEB (val, p, end);
- switch (val)
- {
- case 0:
- printf (_("No unaligned access\n"));
- break;
- case 1:
- printf (_("Unaligned access\n"));
- break;
- }
- break;
- case Tag_RISCV_stack_align:
- READ_ULEB (val, p, end);
- printf (_("%" PRIu64 "-bytes\n"), val);
- break;
- case Tag_RISCV_arch:
- p = display_tag_value (-1, p, end);
- break;
- default:
- return display_tag_value (tag, p, end);
- }
-
- return p;
-}
-
-static unsigned char *
-display_csky_attribute (unsigned char * p,
- const unsigned char * const end)
-{
- uint64_t tag;
- uint64_t val;
- READ_ULEB (tag, p, end);
-
- if (tag >= Tag_CSKY_MAX)
- {
- return display_tag_value (-1, p, end);
- }
-
- switch (tag)
- {
- case Tag_CSKY_ARCH_NAME:
- printf (" Tag_CSKY_ARCH_NAME:\t\t");
- return display_tag_value (-1, p, end);
- case Tag_CSKY_CPU_NAME:
- printf (" Tag_CSKY_CPU_NAME:\t\t");
- return display_tag_value (-1, p, end);
-
- case Tag_CSKY_ISA_FLAGS:
- printf (" Tag_CSKY_ISA_FLAGS:\t\t");
- return display_tag_value (0, p, end);
- case Tag_CSKY_ISA_EXT_FLAGS:
- printf (" Tag_CSKY_ISA_EXT_FLAGS:\t");
- return display_tag_value (0, p, end);
-
- case Tag_CSKY_DSP_VERSION:
- printf (" Tag_CSKY_DSP_VERSION:\t\t");
- READ_ULEB (val, p, end);
- if (val == VAL_CSKY_DSP_VERSION_EXTENSION)
- printf ("DSP Extension\n");
- else if (val == VAL_CSKY_DSP_VERSION_2)
- printf ("DSP 2.0\n");
- break;
-
- case Tag_CSKY_VDSP_VERSION:
- printf (" Tag_CSKY_VDSP_VERSION:\t");
- READ_ULEB (val, p, end);
- printf ("VDSP Version %" PRId64 "\n", val);
- break;
-
- case Tag_CSKY_FPU_VERSION:
- printf (" Tag_CSKY_FPU_VERSION:\t\t");
- READ_ULEB (val, p, end);
- if (val == VAL_CSKY_FPU_VERSION_1)
- printf ("ABIV1 FPU Version 1\n");
- else if (val == VAL_CSKY_FPU_VERSION_2)
- printf ("FPU Version 2\n");
- break;
-
- case Tag_CSKY_FPU_ABI:
- printf (" Tag_CSKY_FPU_ABI:\t\t");
- READ_ULEB (val, p, end);
- if (val == VAL_CSKY_FPU_ABI_HARD)
- printf ("Hard\n");
- else if (val == VAL_CSKY_FPU_ABI_SOFTFP)
- printf ("SoftFP\n");
- else if (val == VAL_CSKY_FPU_ABI_SOFT)
- printf ("Soft\n");
- break;
- case Tag_CSKY_FPU_ROUNDING:
- READ_ULEB (val, p, end);
- if (val == 1)
- {
- printf (" Tag_CSKY_FPU_ROUNDING:\t");
- printf ("Needed\n");
- }
- break;
- case Tag_CSKY_FPU_DENORMAL:
- READ_ULEB (val, p, end);
- if (val == 1)
- {
- printf (" Tag_CSKY_FPU_DENORMAL:\t");
- printf ("Needed\n");
- }
- break;
- case Tag_CSKY_FPU_Exception:
- READ_ULEB (val, p, end);
- if (val == 1)
- {
- printf (" Tag_CSKY_FPU_Exception:\t");
- printf ("Needed\n");
- }
- break;
- case Tag_CSKY_FPU_NUMBER_MODULE:
- printf (" Tag_CSKY_FPU_NUMBER_MODULE:\t");
- return display_tag_value (-1, p, end);
- case Tag_CSKY_FPU_HARDFP:
- printf (" Tag_CSKY_FPU_HARDFP:\t\t");
- READ_ULEB (val, p, end);
- if (val & VAL_CSKY_FPU_HARDFP_HALF)
- printf (" Half");
- if (val & VAL_CSKY_FPU_HARDFP_SINGLE)
- printf (" Single");
- if (val & VAL_CSKY_FPU_HARDFP_DOUBLE)
- printf (" Double");
- printf ("\n");
- break;
- default:
- return display_tag_value (tag, p, end);
- }
- return p;
-}
-
-static bool
-process_attributes (Filedata * filedata,
- const char * public_name,
- unsigned int proc_type,
- unsigned char * (* display_pub_attribute) (unsigned char *, const unsigned char * const),
- unsigned char * (* display_proc_gnu_attribute) (unsigned char *, unsigned int, const unsigned char * const))
-{
- Elf_Internal_Shdr * sect;
- unsigned i;
- bool res = true;
-
- /* Find the section header so that we get the size. */
- for (i = 0, sect = filedata->section_headers;
- i < filedata->file_header.e_shnum;
- i++, sect++)
- {
- unsigned char * contents;
- unsigned char * p;
-
- if (sect->sh_type != proc_type && sect->sh_type != SHT_GNU_ATTRIBUTES)
- continue;
-
- contents = (unsigned char *) get_data (NULL, filedata, sect->sh_offset, 1,
- sect->sh_size, _("attributes"));
- if (contents == NULL)
- {
- res = false;
- continue;
- }
-
- p = contents;
- /* The first character is the version of the attributes.
- Currently only version 1, (aka 'A') is recognised here. */
- if (*p != 'A')
- {
- printf (_("Unknown attributes version '%c'(%d) - expecting 'A'\n"), *p, *p);
- res = false;
- }
- else
- {
- uint64_t section_len;
-
- section_len = sect->sh_size - 1;
- p++;
-
- while (section_len > 0)
- {
- uint64_t attr_len;
- unsigned int namelen;
- bool public_section;
- bool gnu_section;
-
- if (section_len <= 4)
- {
- error (_("Tag section ends prematurely\n"));
- res = false;
- break;
- }
- attr_len = byte_get (p, 4);
- p += 4;
-
- if (attr_len > section_len)
- {
- error (_("Bad attribute length (%u > %u)\n"),
- (unsigned) attr_len, (unsigned) section_len);
- attr_len = section_len;
- res = false;
- }
- /* PR 17531: file: 001-101425-0.004 */
- else if (attr_len < 5)
- {
- error (_("Attribute length of %u is too small\n"), (unsigned) attr_len);
- res = false;
- break;
- }
-
- section_len -= attr_len;
- attr_len -= 4;
-
- namelen = strnlen ((char *) p, attr_len) + 1;
- if (namelen == 0 || namelen >= attr_len)
- {
- error (_("Corrupt attribute section name\n"));
- res = false;
- break;
- }
-
- printf (_("Attribute Section: "));
- print_symbol_name (INT_MAX, (const char *) p);
- putchar ('\n');
-
- if (public_name && streq ((char *) p, public_name))
- public_section = true;
- else
- public_section = false;
-
- if (streq ((char *) p, "gnu"))
- gnu_section = true;
- else
- gnu_section = false;
-
- p += namelen;
- attr_len -= namelen;
-
- while (attr_len > 0 && p < contents + sect->sh_size)
- {
- int tag;
- unsigned int val;
- uint64_t size;
- unsigned char * end;
-
- /* PR binutils/17531: Safe handling of corrupt files. */
- if (attr_len < 6)
- {
- error (_("Unused bytes at end of section\n"));
- res = false;
- section_len = 0;
- break;
- }
-
- tag = *(p++);
- size = byte_get (p, 4);
- if (size > attr_len)
- {
- error (_("Bad subsection length (%u > %u)\n"),
- (unsigned) size, (unsigned) attr_len);
- res = false;
- size = attr_len;
- }
- /* PR binutils/17531: Safe handling of corrupt files. */
- if (size < 6)
- {
- error (_("Bad subsection length (%u < 6)\n"),
- (unsigned) size);
- res = false;
- section_len = 0;
- break;
- }
-
- attr_len -= size;
- end = p + size - 1;
- assert (end <= contents + sect->sh_size);
- p += 4;
-
- switch (tag)
- {
- case 1:
- printf (_("File Attributes\n"));
- break;
- case 2:
- printf (_("Section Attributes:"));
- goto do_numlist;
- case 3:
- printf (_("Symbol Attributes:"));
- /* Fall through. */
- do_numlist:
- for (;;)
- {
- READ_ULEB (val, p, end);
- if (val == 0)
- break;
- printf (" %d", val);
- }
- printf ("\n");
- break;
- default:
- printf (_("Unknown tag: %d\n"), tag);
- public_section = false;
- break;
- }
-
- if (public_section && display_pub_attribute != NULL)
- {
- while (p < end)
- p = display_pub_attribute (p, end);
- assert (p == end);
- }
- else if (gnu_section && display_proc_gnu_attribute != NULL)
- {
- while (p < end)
- p = display_gnu_attribute (p,
- display_proc_gnu_attribute,
- end);
- assert (p == end);
- }
- else if (p < end)
- {
- printf (_(" Unknown attribute:\n"));
- display_raw_attribute (p, end);
- p = end;
- }
- else
- attr_len = 0;
- }
- }
- }
-
- free (contents);
- }
-
- return res;
-}
-
-/* DATA points to the contents of a MIPS GOT that starts at VMA PLTGOT.
- Print the Address, Access and Initial fields of an entry at VMA ADDR
- and return the VMA of the next entry, or -1 if there was a problem.
- Does not read from DATA_END or beyond. */
-
-static uint64_t
-print_mips_got_entry (unsigned char * data, uint64_t pltgot, uint64_t addr,
- unsigned char * data_end)
-{
- printf (" ");
- print_vma (addr, LONG_HEX);
- printf (" ");
- if (addr < pltgot + 0xfff0)
- printf ("%6d(gp)", (int) (addr - pltgot - 0x7ff0));
- else
- printf ("%10s", "");
- printf (" ");
- if (data == NULL)
- printf ("%*s", is_32bit_elf ? 8 : 16, _("<unknown>"));
- else
- {
- uint64_t entry;
- unsigned char * from = data + addr - pltgot;
-
- if (from + (is_32bit_elf ? 4 : 8) > data_end)
- {
- warn (_("MIPS GOT entry extends beyond the end of available data\n"));
- printf ("%*s", is_32bit_elf ? 8 : 16, _("<corrupt>"));
- return (uint64_t) -1;
- }
- else
- {
- entry = byte_get (data + addr - pltgot, is_32bit_elf ? 4 : 8);
- print_vma (entry, LONG_HEX);
- }
- }
- return addr + (is_32bit_elf ? 4 : 8);
-}
-
-/* DATA points to the contents of a MIPS PLT GOT that starts at VMA
- PLTGOT. Print the Address and Initial fields of an entry at VMA
- ADDR and return the VMA of the next entry. */
-
-static uint64_t
-print_mips_pltgot_entry (unsigned char * data, uint64_t pltgot, uint64_t addr)
-{
- printf (" ");
- print_vma (addr, LONG_HEX);
- printf (" ");
- if (data == NULL)
- printf ("%*s", is_32bit_elf ? 8 : 16, _("<unknown>"));
- else
- {
- uint64_t entry;
-
- entry = byte_get (data + addr - pltgot, is_32bit_elf ? 4 : 8);
- print_vma (entry, LONG_HEX);
- }
- return addr + (is_32bit_elf ? 4 : 8);
-}
-
-static void
-print_mips_ases (unsigned int mask)
-{
- if (mask & AFL_ASE_DSP)
- fputs ("\n\tDSP ASE", stdout);
- if (mask & AFL_ASE_DSPR2)
- fputs ("\n\tDSP R2 ASE", stdout);
- if (mask & AFL_ASE_DSPR3)
- fputs ("\n\tDSP R3 ASE", stdout);
- if (mask & AFL_ASE_EVA)
- fputs ("\n\tEnhanced VA Scheme", stdout);
- if (mask & AFL_ASE_MCU)
- fputs ("\n\tMCU (MicroController) ASE", stdout);
- if (mask & AFL_ASE_MDMX)
- fputs ("\n\tMDMX ASE", stdout);
- if (mask & AFL_ASE_MIPS3D)
- fputs ("\n\tMIPS-3D ASE", stdout);
- if (mask & AFL_ASE_MT)
- fputs ("\n\tMT ASE", stdout);
- if (mask & AFL_ASE_SMARTMIPS)
- fputs ("\n\tSmartMIPS ASE", stdout);
- if (mask & AFL_ASE_VIRT)
- fputs ("\n\tVZ ASE", stdout);
- if (mask & AFL_ASE_MSA)
- fputs ("\n\tMSA ASE", stdout);
- if (mask & AFL_ASE_MIPS16)
- fputs ("\n\tMIPS16 ASE", stdout);
- if (mask & AFL_ASE_MICROMIPS)
- fputs ("\n\tMICROMIPS ASE", stdout);
- if (mask & AFL_ASE_XPA)
- fputs ("\n\tXPA ASE", stdout);
- if (mask & AFL_ASE_MIPS16E2)
- fputs ("\n\tMIPS16e2 ASE", stdout);
- if (mask & AFL_ASE_CRC)
- fputs ("\n\tCRC ASE", stdout);
- if (mask & AFL_ASE_GINV)
- fputs ("\n\tGINV ASE", stdout);
- if (mask & AFL_ASE_LOONGSON_MMI)
- fputs ("\n\tLoongson MMI ASE", stdout);
- if (mask & AFL_ASE_LOONGSON_CAM)
- fputs ("\n\tLoongson CAM ASE", stdout);
- if (mask & AFL_ASE_LOONGSON_EXT)
- fputs ("\n\tLoongson EXT ASE", stdout);
- if (mask & AFL_ASE_LOONGSON_EXT2)
- fputs ("\n\tLoongson EXT2 ASE", stdout);
- if (mask == 0)
- fprintf (stdout, "\n\t%s", _("None"));
- else if ((mask & ~AFL_ASE_MASK) != 0)
- fprintf (stdout, "\n\t%s (%x)", _("Unknown"), mask & ~AFL_ASE_MASK);
-}
-
-static void
-print_mips_isa_ext (unsigned int isa_ext)
-{
- switch (isa_ext)
- {
- case 0:
- fputs (_("None"), stdout);
- break;
- case AFL_EXT_XLR:
- fputs ("RMI XLR", stdout);
- break;
- case AFL_EXT_OCTEON3:
- fputs ("Cavium Networks Octeon3", stdout);
- break;
- case AFL_EXT_OCTEON2:
- fputs ("Cavium Networks Octeon2", stdout);
- break;
- case AFL_EXT_OCTEONP:
- fputs ("Cavium Networks OcteonP", stdout);
- break;
- case AFL_EXT_OCTEON:
- fputs ("Cavium Networks Octeon", stdout);
- break;
- case AFL_EXT_5900:
- fputs ("Toshiba R5900", stdout);
- break;
- case AFL_EXT_4650:
- fputs ("MIPS R4650", stdout);
- break;
- case AFL_EXT_4010:
- fputs ("LSI R4010", stdout);
- break;
- case AFL_EXT_4100:
- fputs ("NEC VR4100", stdout);
- break;
- case AFL_EXT_3900:
- fputs ("Toshiba R3900", stdout);
- break;
- case AFL_EXT_10000:
- fputs ("MIPS R10000", stdout);
- break;
- case AFL_EXT_SB1:
- fputs ("Broadcom SB-1", stdout);
- break;
- case AFL_EXT_4111:
- fputs ("NEC VR4111/VR4181", stdout);
- break;
- case AFL_EXT_4120:
- fputs ("NEC VR4120", stdout);
- break;
- case AFL_EXT_5400:
- fputs ("NEC VR5400", stdout);
- break;
- case AFL_EXT_5500:
- fputs ("NEC VR5500", stdout);
- break;
- case AFL_EXT_LOONGSON_2E:
- fputs ("ST Microelectronics Loongson 2E", stdout);
- break;
- case AFL_EXT_LOONGSON_2F:
- fputs ("ST Microelectronics Loongson 2F", stdout);
- break;
- case AFL_EXT_INTERAPTIV_MR2:
- fputs ("Imagination interAptiv MR2", stdout);
- break;
- default:
- fprintf (stdout, "%s (%d)", _("Unknown"), isa_ext);
- }
-}
-
-static signed int
-get_mips_reg_size (int reg_size)
-{
- return (reg_size == AFL_REG_NONE) ? 0
- : (reg_size == AFL_REG_32) ? 32
- : (reg_size == AFL_REG_64) ? 64
- : (reg_size == AFL_REG_128) ? 128
- : -1;
-}
-
-static bool
-process_mips_specific (Filedata * filedata)
-{
- Elf_Internal_Dyn * entry;
- Elf_Internal_Shdr *sect = NULL;
- size_t liblist_offset = 0;
- size_t liblistno = 0;
- size_t conflictsno = 0;
- size_t options_offset = 0;
- size_t conflicts_offset = 0;
- size_t pltrelsz = 0;
- size_t pltrel = 0;
- uint64_t pltgot = 0;
- uint64_t mips_pltgot = 0;
- uint64_t jmprel = 0;
- uint64_t local_gotno = 0;
- uint64_t gotsym = 0;
- uint64_t symtabno = 0;
- bool res = true;
-
- if (! process_attributes (filedata, NULL, SHT_GNU_ATTRIBUTES, NULL,
- display_mips_gnu_attribute))
- res = false;
-
- sect = find_section (filedata, ".MIPS.abiflags");
-
- if (sect != NULL)
- {
- Elf_External_ABIFlags_v0 *abiflags_ext;
- Elf_Internal_ABIFlags_v0 abiflags_in;
-
- if (sizeof (Elf_External_ABIFlags_v0) != sect->sh_size)
- {
- error (_("Corrupt MIPS ABI Flags section.\n"));
- res = false;
- }
- else
- {
- abiflags_ext = get_data (NULL, filedata, sect->sh_offset, 1,
- sect->sh_size, _("MIPS ABI Flags section"));
- if (abiflags_ext)
- {
- abiflags_in.version = BYTE_GET (abiflags_ext->version);
- abiflags_in.isa_level = BYTE_GET (abiflags_ext->isa_level);
- abiflags_in.isa_rev = BYTE_GET (abiflags_ext->isa_rev);
- abiflags_in.gpr_size = BYTE_GET (abiflags_ext->gpr_size);
- abiflags_in.cpr1_size = BYTE_GET (abiflags_ext->cpr1_size);
- abiflags_in.cpr2_size = BYTE_GET (abiflags_ext->cpr2_size);
- abiflags_in.fp_abi = BYTE_GET (abiflags_ext->fp_abi);
- abiflags_in.isa_ext = BYTE_GET (abiflags_ext->isa_ext);
- abiflags_in.ases = BYTE_GET (abiflags_ext->ases);
- abiflags_in.flags1 = BYTE_GET (abiflags_ext->flags1);
- abiflags_in.flags2 = BYTE_GET (abiflags_ext->flags2);
-
- printf ("\nMIPS ABI Flags Version: %d\n", abiflags_in.version);
- printf ("\nISA: MIPS%d", abiflags_in.isa_level);
- if (abiflags_in.isa_rev > 1)
- printf ("r%d", abiflags_in.isa_rev);
- printf ("\nGPR size: %d",
- get_mips_reg_size (abiflags_in.gpr_size));
- printf ("\nCPR1 size: %d",
- get_mips_reg_size (abiflags_in.cpr1_size));
- printf ("\nCPR2 size: %d",
- get_mips_reg_size (abiflags_in.cpr2_size));
- fputs ("\nFP ABI: ", stdout);
- print_mips_fp_abi_value (abiflags_in.fp_abi);
- fputs ("ISA Extension: ", stdout);
- print_mips_isa_ext (abiflags_in.isa_ext);
- fputs ("\nASEs:", stdout);
- print_mips_ases (abiflags_in.ases);
- printf ("\nFLAGS 1: %8.8lx", abiflags_in.flags1);
- printf ("\nFLAGS 2: %8.8lx", abiflags_in.flags2);
- fputc ('\n', stdout);
- free (abiflags_ext);
- }
- }
- }
-
- /* We have a lot of special sections. Thanks SGI! */
- if (filedata->dynamic_section == NULL)
- {
- /* No dynamic information available. See if there is static GOT. */
- sect = find_section (filedata, ".got");
- if (sect != NULL)
- {
- unsigned char *data_end;
- unsigned char *data;
- uint64_t ent, end;
- int addr_size;
-
- pltgot = sect->sh_addr;
-
- ent = pltgot;
- addr_size = (is_32bit_elf ? 4 : 8);
- end = pltgot + sect->sh_size;
-
- data = (unsigned char *) get_data (NULL, filedata, sect->sh_offset,
- end - pltgot, 1,
- _("Global Offset Table data"));
- /* PR 12855: Null data is handled gracefully throughout. */
- data_end = data + (end - pltgot);
-
- printf (_("\nStatic GOT:\n"));
- printf (_(" Canonical gp value: "));
- print_vma (ent + 0x7ff0, LONG_HEX);
- printf ("\n\n");
-
- /* In a dynamic binary GOT[0] is reserved for the dynamic
- loader to store the lazy resolver pointer, however in
- a static binary it may well have been omitted and GOT
- reduced to a table of addresses.
- PR 21344: Check for the entry being fully available
- before fetching it. */
- if (data
- && data + ent - pltgot + addr_size <= data_end
- && byte_get (data + ent - pltgot, addr_size) == 0)
- {
- printf (_(" Reserved entries:\n"));
- printf (_(" %*s %10s %*s\n"),
- addr_size * 2, _("Address"), _("Access"),
- addr_size * 2, _("Value"));
- ent = print_mips_got_entry (data, pltgot, ent, data_end);
- printf ("\n");
- if (ent == (uint64_t) -1)
- goto sgot_print_fail;
-
- /* Check for the MSB of GOT[1] being set, identifying a
- GNU object. This entry will be used by some runtime
- loaders, to store the module pointer. Otherwise this
- is an ordinary local entry.
- PR 21344: Check for the entry being fully available
- before fetching it. */
- if (data
- && data + ent - pltgot + addr_size <= data_end
- && (byte_get (data + ent - pltgot, addr_size)
- >> (addr_size * 8 - 1)) != 0)
- {
- ent = print_mips_got_entry (data, pltgot, ent, data_end);
- printf ("\n");
- if (ent == (uint64_t) -1)
- goto sgot_print_fail;
- }
- printf ("\n");
- }
-
- if (data != NULL && ent < end)
- {
- printf (_(" Local entries:\n"));
- printf (" %*s %10s %*s\n",
- addr_size * 2, _("Address"), _("Access"),
- addr_size * 2, _("Value"));
- while (ent < end)
- {
- ent = print_mips_got_entry (data, pltgot, ent, data_end);
- printf ("\n");
- if (ent == (uint64_t) -1)
- goto sgot_print_fail;
- }
- printf ("\n");
- }
-
- sgot_print_fail:
- free (data);
- }
- return res;
- }
-
- for (entry = filedata->dynamic_section;
- /* PR 17531 file: 012-50589-0.004. */
- (entry < filedata->dynamic_section + filedata->dynamic_nent
- && entry->d_tag != DT_NULL);
- ++entry)
- switch (entry->d_tag)
- {
- case DT_MIPS_LIBLIST:
- liblist_offset
- = offset_from_vma (filedata, entry->d_un.d_val,
- liblistno * sizeof (Elf32_External_Lib));
- break;
- case DT_MIPS_LIBLISTNO:
- liblistno = entry->d_un.d_val;
- break;
- case DT_MIPS_OPTIONS:
- options_offset = offset_from_vma (filedata, entry->d_un.d_val, 0);
- break;
- case DT_MIPS_CONFLICT:
- conflicts_offset
- = offset_from_vma (filedata, entry->d_un.d_val,
- conflictsno * sizeof (Elf32_External_Conflict));
- break;
- case DT_MIPS_CONFLICTNO:
- conflictsno = entry->d_un.d_val;
- break;
- case DT_PLTGOT:
- pltgot = entry->d_un.d_ptr;
- break;
- case DT_MIPS_LOCAL_GOTNO:
- local_gotno = entry->d_un.d_val;
- break;
- case DT_MIPS_GOTSYM:
- gotsym = entry->d_un.d_val;
- break;
- case DT_MIPS_SYMTABNO:
- symtabno = entry->d_un.d_val;
- break;
- case DT_MIPS_PLTGOT:
- mips_pltgot = entry->d_un.d_ptr;
- break;
- case DT_PLTREL:
- pltrel = entry->d_un.d_val;
- break;
- case DT_PLTRELSZ:
- pltrelsz = entry->d_un.d_val;
- break;
- case DT_JMPREL:
- jmprel = entry->d_un.d_ptr;
- break;
- default:
- break;
- }
-
- if (liblist_offset != 0 && liblistno != 0 && do_dynamic)
- {
- Elf32_External_Lib * elib;
- size_t cnt;
-
- elib = (Elf32_External_Lib *) get_data (NULL, filedata, liblist_offset,
- sizeof (Elf32_External_Lib),
- liblistno,
- _("liblist section data"));
- if (elib)
- {
- printf (ngettext ("\nSection '.liblist' contains %zu entry:\n",
- "\nSection '.liblist' contains %zu entries:\n",
- liblistno),
- liblistno);
- fputs (_(" Library Time Stamp Checksum Version Flags\n"),
- stdout);
-
- for (cnt = 0; cnt < liblistno; ++cnt)
- {
- Elf32_Lib liblist;
- time_t atime;
- char timebuf[128];
- struct tm * tmp;
-
- liblist.l_name = BYTE_GET (elib[cnt].l_name);
- atime = BYTE_GET (elib[cnt].l_time_stamp);
- liblist.l_checksum = BYTE_GET (elib[cnt].l_checksum);
- liblist.l_version = BYTE_GET (elib[cnt].l_version);
- liblist.l_flags = BYTE_GET (elib[cnt].l_flags);
-
- tmp = gmtime (&atime);
- snprintf (timebuf, sizeof (timebuf),
- "%04u-%02u-%02uT%02u:%02u:%02u",
- tmp->tm_year + 1900, tmp->tm_mon + 1, tmp->tm_mday,
- tmp->tm_hour, tmp->tm_min, tmp->tm_sec);
-
- printf ("%3zu: ", cnt);
- if (valid_dynamic_name (filedata, liblist.l_name))
- print_symbol_name (20, get_dynamic_name (filedata, liblist.l_name));
- else
- printf (_("<corrupt: %9ld>"), liblist.l_name);
- printf (" %s %#10lx %-7ld", timebuf, liblist.l_checksum,
- liblist.l_version);
-
- if (liblist.l_flags == 0)
- puts (_(" NONE"));
- else
- {
- static const struct
- {
- const char * name;
- int bit;
- }
- l_flags_vals[] =
- {
- { " EXACT_MATCH", LL_EXACT_MATCH },
- { " IGNORE_INT_VER", LL_IGNORE_INT_VER },
- { " REQUIRE_MINOR", LL_REQUIRE_MINOR },
- { " EXPORTS", LL_EXPORTS },
- { " DELAY_LOAD", LL_DELAY_LOAD },
- { " DELTA", LL_DELTA }
- };
- int flags = liblist.l_flags;
- size_t fcnt;
-
- for (fcnt = 0; fcnt < ARRAY_SIZE (l_flags_vals); ++fcnt)
- if ((flags & l_flags_vals[fcnt].bit) != 0)
- {
- fputs (l_flags_vals[fcnt].name, stdout);
- flags ^= l_flags_vals[fcnt].bit;
- }
- if (flags != 0)
- printf (" %#x", (unsigned int) flags);
-
- puts ("");
- }
- }
-
- free (elib);
- }
- else
- res = false;
- }
-
- if (options_offset != 0)
- {
- Elf_External_Options * eopt;
- size_t offset;
- int cnt;
-
- /* Find the section header so that we get the size. */
- sect = find_section_by_type (filedata, SHT_MIPS_OPTIONS);
- /* PR 17533 file: 012-277276-0.004. */
- if (sect == NULL)
- {
- error (_("No MIPS_OPTIONS header found\n"));
- return false;
- }
- /* PR 24243 */
- if (sect->sh_size < sizeof (* eopt))
- {
- error (_("The MIPS options section is too small.\n"));
- return false;
- }
-
- eopt = (Elf_External_Options *) get_data (NULL, filedata, options_offset, 1,
- sect->sh_size, _("options"));
- if (eopt)
- {
- Elf_Internal_Options option;
-
- offset = cnt = 0;
- while (offset <= sect->sh_size - sizeof (* eopt))
- {
- Elf_External_Options * eoption;
- unsigned int optsize;
-
- eoption = (Elf_External_Options *) ((char *) eopt + offset);
-
- optsize = BYTE_GET (eoption->size);
-
- /* PR 17531: file: ffa0fa3b. */
- if (optsize < sizeof (* eopt)
- || optsize > sect->sh_size - offset)
- {
- error (_("Invalid size (%u) for MIPS option\n"),
- optsize);
- free (eopt);
- return false;
- }
- offset += optsize;
- ++cnt;
- }
-
- printf (ngettext ("\nSection '%s' contains %d entry:\n",
- "\nSection '%s' contains %d entries:\n",
- cnt),
- printable_section_name (filedata, sect), cnt);
-
- offset = 0;
- while (cnt-- > 0)
- {
- size_t len;
- Elf_External_Options * eoption;
-
- eoption = (Elf_External_Options *) ((char *) eopt + offset);
-
- option.kind = BYTE_GET (eoption->kind);
- option.size = BYTE_GET (eoption->size);
- option.section = BYTE_GET (eoption->section);
- option.info = BYTE_GET (eoption->info);
-
- switch (option.kind)
- {
- case ODK_NULL:
- /* This shouldn't happen. */
- printf (" NULL %" PRId16 " %" PRIx32,
- option.section, option.info);
- break;
-
- case ODK_REGINFO:
- printf (" REGINFO ");
- if (filedata->file_header.e_machine == EM_MIPS)
- {
- Elf32_External_RegInfo * ereg;
- Elf32_RegInfo reginfo;
-
- /* 32bit form. */
- if (option.size < (sizeof (Elf_External_Options)
- + sizeof (Elf32_External_RegInfo)))
- {
- printf (_("<corrupt>\n"));
- error (_("Truncated MIPS REGINFO option\n"));
- cnt = 0;
- break;
- }
-
- ereg = (Elf32_External_RegInfo *) (eoption + 1);
-
- reginfo.ri_gprmask = BYTE_GET (ereg->ri_gprmask);
- reginfo.ri_cprmask[0] = BYTE_GET (ereg->ri_cprmask[0]);
- reginfo.ri_cprmask[1] = BYTE_GET (ereg->ri_cprmask[1]);
- reginfo.ri_cprmask[2] = BYTE_GET (ereg->ri_cprmask[2]);
- reginfo.ri_cprmask[3] = BYTE_GET (ereg->ri_cprmask[3]);
- reginfo.ri_gp_value = BYTE_GET (ereg->ri_gp_value);
-
- printf ("GPR %08" PRIx32 " GP 0x%" PRIx32 "\n",
- reginfo.ri_gprmask, reginfo.ri_gp_value);
- printf (" "
- " CPR0 %08" PRIx32 " CPR1 %08" PRIx32
- " CPR2 %08" PRIx32 " CPR3 %08" PRIx32 "\n",
- reginfo.ri_cprmask[0], reginfo.ri_cprmask[1],
- reginfo.ri_cprmask[2], reginfo.ri_cprmask[3]);
- }
- else
- {
- /* 64 bit form. */
- Elf64_External_RegInfo * ereg;
- Elf64_Internal_RegInfo reginfo;
-
- if (option.size < (sizeof (Elf_External_Options)
- + sizeof (Elf64_External_RegInfo)))
- {
- printf (_("<corrupt>\n"));
- error (_("Truncated MIPS REGINFO option\n"));
- cnt = 0;
- break;
- }
-
- ereg = (Elf64_External_RegInfo *) (eoption + 1);
- reginfo.ri_gprmask = BYTE_GET (ereg->ri_gprmask);
- reginfo.ri_cprmask[0] = BYTE_GET (ereg->ri_cprmask[0]);
- reginfo.ri_cprmask[1] = BYTE_GET (ereg->ri_cprmask[1]);
- reginfo.ri_cprmask[2] = BYTE_GET (ereg->ri_cprmask[2]);
- reginfo.ri_cprmask[3] = BYTE_GET (ereg->ri_cprmask[3]);
- reginfo.ri_gp_value = BYTE_GET (ereg->ri_gp_value);
-
- printf ("GPR %08" PRIx32 " GP 0x%" PRIx64 "\n",
- reginfo.ri_gprmask, reginfo.ri_gp_value);
- printf (" "
- " CPR0 %08" PRIx32 " CPR1 %08" PRIx32
- " CPR2 %08" PRIx32 " CPR3 %08" PRIx32 "\n",
- reginfo.ri_cprmask[0], reginfo.ri_cprmask[1],
- reginfo.ri_cprmask[2], reginfo.ri_cprmask[3]);
- }
- offset += option.size;
- continue;
-
- case ODK_EXCEPTIONS:
- fputs (" EXCEPTIONS fpe_min(", stdout);
- process_mips_fpe_exception (option.info & OEX_FPU_MIN);
- fputs (") fpe_max(", stdout);
- process_mips_fpe_exception ((option.info & OEX_FPU_MAX) >> 8);
- fputs (")", stdout);
-
- if (option.info & OEX_PAGE0)
- fputs (" PAGE0", stdout);
- if (option.info & OEX_SMM)
- fputs (" SMM", stdout);
- if (option.info & OEX_FPDBUG)
- fputs (" FPDBUG", stdout);
- if (option.info & OEX_DISMISS)
- fputs (" DISMISS", stdout);
- break;
-
- case ODK_PAD:
- fputs (" PAD ", stdout);
- if (option.info & OPAD_PREFIX)
- fputs (" PREFIX", stdout);
- if (option.info & OPAD_POSTFIX)
- fputs (" POSTFIX", stdout);
- if (option.info & OPAD_SYMBOL)
- fputs (" SYMBOL", stdout);
- break;
-
- case ODK_HWPATCH:
- fputs (" HWPATCH ", stdout);
- if (option.info & OHW_R4KEOP)
- fputs (" R4KEOP", stdout);
- if (option.info & OHW_R8KPFETCH)
- fputs (" R8KPFETCH", stdout);
- if (option.info & OHW_R5KEOP)
- fputs (" R5KEOP", stdout);
- if (option.info & OHW_R5KCVTL)
- fputs (" R5KCVTL", stdout);
- break;
-
- case ODK_FILL:
- fputs (" FILL ", stdout);
- /* XXX Print content of info word? */
- break;
-
- case ODK_TAGS:
- fputs (" TAGS ", stdout);
- /* XXX Print content of info word? */
- break;
-
- case ODK_HWAND:
- fputs (" HWAND ", stdout);
- if (option.info & OHWA0_R4KEOP_CHECKED)
- fputs (" R4KEOP_CHECKED", stdout);
- if (option.info & OHWA0_R4KEOP_CLEAN)
- fputs (" R4KEOP_CLEAN", stdout);
- break;
-
- case ODK_HWOR:
- fputs (" HWOR ", stdout);
- if (option.info & OHWA0_R4KEOP_CHECKED)
- fputs (" R4KEOP_CHECKED", stdout);
- if (option.info & OHWA0_R4KEOP_CLEAN)
- fputs (" R4KEOP_CLEAN", stdout);
- break;
-
- case ODK_GP_GROUP:
- printf (" GP_GROUP %#06x self-contained %#06x",
- option.info & OGP_GROUP,
- (option.info & OGP_SELF) >> 16);
- break;
-
- case ODK_IDENT:
- printf (" IDENT %#06x self-contained %#06x",
- option.info & OGP_GROUP,
- (option.info & OGP_SELF) >> 16);
- break;
-
- default:
- /* This shouldn't happen. */
- printf (" %3d ??? %" PRId16 " %" PRIx32,
- option.kind, option.section, option.info);
- break;
- }
-
- len = sizeof (* eopt);
- while (len < option.size)
- {
- unsigned char datum = *((unsigned char *) eoption + len);
-
- if (ISPRINT (datum))
- printf ("%c", datum);
- else
- printf ("\\%03o", datum);
- len ++;
- }
- fputs ("\n", stdout);
-
- offset += option.size;
- }
- free (eopt);
- }
- else
- res = false;
- }
-
- if (conflicts_offset != 0 && conflictsno != 0)
- {
- Elf32_Conflict * iconf;
- size_t cnt;
-
- if (filedata->dynamic_symbols == NULL)
- {
- error (_("conflict list found without a dynamic symbol table\n"));
- return false;
- }
-
- /* PR 21345 - print a slightly more helpful error message
- if we are sure that the cmalloc will fail. */
- if (conflictsno > filedata->file_size / sizeof (* iconf))
- {
- error (_("Overlarge number of conflicts detected: %zx\n"),
- conflictsno);
- return false;
- }
-
- iconf = (Elf32_Conflict *) cmalloc (conflictsno, sizeof (* iconf));
- if (iconf == NULL)
- {
- error (_("Out of memory allocating space for dynamic conflicts\n"));
- return false;
- }
-
- if (is_32bit_elf)
- {
- Elf32_External_Conflict * econf32;
-
- econf32 = (Elf32_External_Conflict *)
- get_data (NULL, filedata, conflicts_offset,
- sizeof (*econf32), conflictsno, _("conflict"));
- if (!econf32)
- {
- free (iconf);
- return false;
- }
-
- for (cnt = 0; cnt < conflictsno; ++cnt)
- iconf[cnt] = BYTE_GET (econf32[cnt]);
-
- free (econf32);
- }
- else
- {
- Elf64_External_Conflict * econf64;
-
- econf64 = (Elf64_External_Conflict *)
- get_data (NULL, filedata, conflicts_offset,
- sizeof (*econf64), conflictsno, _("conflict"));
- if (!econf64)
- {
- free (iconf);
- return false;
- }
-
- for (cnt = 0; cnt < conflictsno; ++cnt)
- iconf[cnt] = BYTE_GET (econf64[cnt]);
-
- free (econf64);
- }
-
- printf (ngettext ("\nSection '.conflict' contains %zu entry:\n",
- "\nSection '.conflict' contains %zu entries:\n",
- conflictsno),
- conflictsno);
- puts (_(" Num: Index Value Name"));
-
- for (cnt = 0; cnt < conflictsno; ++cnt)
- {
- printf ("%5zu: %8lu ", cnt, iconf[cnt]);
-
- if (iconf[cnt] >= filedata->num_dynamic_syms)
- printf (_("<corrupt symbol index>"));
- else
- {
- Elf_Internal_Sym * psym;
-
- psym = & filedata->dynamic_symbols[iconf[cnt]];
- print_vma (psym->st_value, FULL_HEX);
- putchar (' ');
- if (valid_dynamic_name (filedata, psym->st_name))
- print_symbol_name (25, get_dynamic_name (filedata, psym->st_name));
- else
- printf (_("<corrupt: %14ld>"), psym->st_name);
- }
- putchar ('\n');
- }
-
- free (iconf);
- }
-
- if (pltgot != 0 && local_gotno != 0)
- {
- uint64_t ent, local_end, global_end;
- size_t i, offset;
- unsigned char * data;
- unsigned char * data_end;
- int addr_size;
-
- ent = pltgot;
- addr_size = (is_32bit_elf ? 4 : 8);
- local_end = pltgot + local_gotno * addr_size;
-
- /* PR binutils/17533 file: 012-111227-0.004 */
- if (symtabno < gotsym)
- {
- error (_("The GOT symbol offset (%" PRIu64
- ") is greater than the symbol table size (%" PRIu64 ")\n"),
- gotsym, symtabno);
- return false;
- }
-
- global_end = local_end + (symtabno - gotsym) * addr_size;
- /* PR 17531: file: 54c91a34. */
- if (global_end < local_end)
- {
- error (_("Too many GOT symbols: %" PRIu64 "\n"), symtabno);
- return false;
- }
-
- offset = offset_from_vma (filedata, pltgot, global_end - pltgot);
- data = (unsigned char *) get_data (NULL, filedata, offset,
- global_end - pltgot, 1,
- _("Global Offset Table data"));
- /* PR 12855: Null data is handled gracefully throughout. */
- data_end = data + (global_end - pltgot);
-
- printf (_("\nPrimary GOT:\n"));
- printf (_(" Canonical gp value: "));
- print_vma (pltgot + 0x7ff0, LONG_HEX);
- printf ("\n\n");
-
- printf (_(" Reserved entries:\n"));
- printf (_(" %*s %10s %*s Purpose\n"),
- addr_size * 2, _("Address"), _("Access"),
- addr_size * 2, _("Initial"));
- ent = print_mips_got_entry (data, pltgot, ent, data_end);
- printf (_(" Lazy resolver\n"));
- if (ent == (uint64_t) -1)
- goto got_print_fail;
-
- /* Check for the MSB of GOT[1] being set, denoting a GNU object.
- This entry will be used by some runtime loaders, to store the
- module pointer. Otherwise this is an ordinary local entry.
- PR 21344: Check for the entry being fully available before
- fetching it. */
- if (data
- && data + ent - pltgot + addr_size <= data_end
- && (byte_get (data + ent - pltgot, addr_size)
- >> (addr_size * 8 - 1)) != 0)
- {
- ent = print_mips_got_entry (data, pltgot, ent, data_end);
- printf (_(" Module pointer (GNU extension)\n"));
- if (ent == (uint64_t) -1)
- goto got_print_fail;
- }
- printf ("\n");
-
- if (data != NULL && ent < local_end)
- {
- printf (_(" Local entries:\n"));
- printf (" %*s %10s %*s\n",
- addr_size * 2, _("Address"), _("Access"),
- addr_size * 2, _("Initial"));
- while (ent < local_end)
- {
- ent = print_mips_got_entry (data, pltgot, ent, data_end);
- printf ("\n");
- if (ent == (uint64_t) -1)
- goto got_print_fail;
- }
- printf ("\n");
- }
-
- if (data != NULL && gotsym < symtabno)
- {
- int sym_width;
-
- printf (_(" Global entries:\n"));
- printf (" %*s %10s %*s %*s %-7s %3s %s\n",
- addr_size * 2, _("Address"),
- _("Access"),
- addr_size * 2, _("Initial"),
- addr_size * 2, _("Sym.Val."),
- _("Type"),
- /* Note for translators: "Ndx" = abbreviated form of "Index". */
- _("Ndx"), _("Name"));
-
- sym_width = (is_32bit_elf ? 80 : 160) - 28 - addr_size * 6 - 1;
-
- for (i = gotsym; i < symtabno; i++)
- {
- ent = print_mips_got_entry (data, pltgot, ent, data_end);
- printf (" ");
-
- if (filedata->dynamic_symbols == NULL)
- printf (_("<no dynamic symbols>"));
- else if (i < filedata->num_dynamic_syms)
- {
- Elf_Internal_Sym * psym = filedata->dynamic_symbols + i;
-
- print_vma (psym->st_value, LONG_HEX);
- printf (" %-7s ", get_symbol_type (filedata, ELF_ST_TYPE (psym->st_info)));
-
- bool is_special;
- const char * s = printable_section_name_from_index (filedata, psym->st_shndx, & is_special);
- if (is_special)
- printf ("%3s ", s);
- else
- printf ("%3u ", psym->st_shndx);
-
- if (valid_dynamic_name (filedata, psym->st_name))
- print_symbol_name (sym_width,
- get_dynamic_name (filedata, psym->st_name));
- else
- printf (_("<corrupt: %14ld>"), psym->st_name);
- }
- else
- printf (_("<symbol index %zu exceeds number of dynamic symbols>"),
- i);
-
- printf ("\n");
- if (ent == (uint64_t) -1)
- break;
- }
- printf ("\n");
- }
-
- got_print_fail:
- free (data);
- }
-
- if (mips_pltgot != 0 && jmprel != 0 && pltrel != 0 && pltrelsz != 0)
- {
- uint64_t ent, end;
- uint64_t offset, rel_offset;
- uint64_t count, i;
- unsigned char * data;
- int addr_size, sym_width;
- Elf_Internal_Rela * rels;
-
- rel_offset = offset_from_vma (filedata, jmprel, pltrelsz);
- if (pltrel == DT_RELA)
- {
- if (!slurp_rela_relocs (filedata, rel_offset, pltrelsz, &rels, &count))
- return false;
- }
- else
- {
- if (!slurp_rel_relocs (filedata, rel_offset, pltrelsz, &rels, &count))
- return false;
- }
-
- ent = mips_pltgot;
- addr_size = (is_32bit_elf ? 4 : 8);
- end = mips_pltgot + (2 + count) * addr_size;
-
- offset = offset_from_vma (filedata, mips_pltgot, end - mips_pltgot);
- data = (unsigned char *) get_data (NULL, filedata, offset, end - mips_pltgot,
- 1, _("Procedure Linkage Table data"));
- if (data == NULL)
- {
- free (rels);
- return false;
- }
-
- printf ("\nPLT GOT:\n\n");
- printf (_(" Reserved entries:\n"));
- printf (_(" %*s %*s Purpose\n"),
- addr_size * 2, _("Address"), addr_size * 2, _("Initial"));
- ent = print_mips_pltgot_entry (data, mips_pltgot, ent);
- printf (_(" PLT lazy resolver\n"));
- ent = print_mips_pltgot_entry (data, mips_pltgot, ent);
- printf (_(" Module pointer\n"));
- printf ("\n");
-
- printf (_(" Entries:\n"));
- printf (" %*s %*s %*s %-7s %3s %s\n",
- addr_size * 2, _("Address"),
- addr_size * 2, _("Initial"),
- addr_size * 2, _("Sym.Val."), _("Type"), _("Ndx"), _("Name"));
- sym_width = (is_32bit_elf ? 80 : 160) - 17 - addr_size * 6 - 1;
- for (i = 0; i < count; i++)
- {
- uint64_t idx = get_reloc_symindex (rels[i].r_info);
-
- ent = print_mips_pltgot_entry (data, mips_pltgot, ent);
- printf (" ");
-
- if (idx >= filedata->num_dynamic_syms)
- printf (_("<corrupt symbol index: %" PRIu64 ">"), idx);
- else
- {
- Elf_Internal_Sym * psym = filedata->dynamic_symbols + idx;
-
- print_vma (psym->st_value, LONG_HEX);
- printf (" %-7s %3s ",
- get_symbol_type (filedata, ELF_ST_TYPE (psym->st_info)),
- printable_section_name_from_index (filedata, psym->st_shndx, NULL));
- if (valid_dynamic_name (filedata, psym->st_name))
- print_symbol_name (sym_width,
- get_dynamic_name (filedata, psym->st_name));
- else
- printf (_("<corrupt: %14ld>"), psym->st_name);
- }
- printf ("\n");
- }
- printf ("\n");
-
- free (data);
- free (rels);
- }
-
- return res;
-}
-
-static bool
-process_nds32_specific (Filedata * filedata)
-{
- Elf_Internal_Shdr *sect = NULL;
-
- sect = find_section (filedata, ".nds32_e_flags");
- if (sect != NULL && sect->sh_size >= 4)
- {
- unsigned char *buf;
- unsigned int flag;
-
- printf ("\nNDS32 elf flags section:\n");
- buf = get_data (NULL, filedata, sect->sh_offset, 1, 4,
- _("NDS32 elf flags section"));
-
- if (buf == NULL)
- return false;
-
- flag = byte_get (buf, 4);
- free (buf);
- switch (flag & 0x3)
- {
- case 0:
- printf ("(VEC_SIZE):\tNo entry.\n");
- break;
- case 1:
- printf ("(VEC_SIZE):\t4 bytes\n");
- break;
- case 2:
- printf ("(VEC_SIZE):\t16 bytes\n");
- break;
- case 3:
- printf ("(VEC_SIZE):\treserved\n");
- break;
- }
- }
-
- return true;
-}
-
-static bool
-process_gnu_liblist (Filedata * filedata)
-{
- Elf_Internal_Shdr * section;
- Elf_Internal_Shdr * string_sec;
- Elf32_External_Lib * elib;
- char * strtab;
- size_t strtab_size;
- size_t cnt;
- uint64_t num_liblist;
- unsigned i;
- bool res = true;
-
- if (! do_arch)
- return true;
-
- for (i = 0, section = filedata->section_headers;
- i < filedata->file_header.e_shnum;
- i++, section++)
- {
- switch (section->sh_type)
- {
- case SHT_GNU_LIBLIST:
- if (section->sh_link >= filedata->file_header.e_shnum)
- break;
-
- elib = (Elf32_External_Lib *)
- get_data (NULL, filedata, section->sh_offset, 1, section->sh_size,
- _("liblist section data"));
-
- if (elib == NULL)
- {
- res = false;
- break;
- }
-
- string_sec = filedata->section_headers + section->sh_link;
- strtab = (char *) get_data (NULL, filedata, string_sec->sh_offset, 1,
- string_sec->sh_size,
- _("liblist string table"));
- if (strtab == NULL
- || section->sh_entsize != sizeof (Elf32_External_Lib))
- {
- free (elib);
- free (strtab);
- res = false;
- break;
- }
- strtab_size = string_sec->sh_size;
-
- num_liblist = section->sh_size / sizeof (Elf32_External_Lib);
- printf (ngettext ("\nLibrary list section '%s' contains %" PRIu64
- " entries:\n",
- "\nLibrary list section '%s' contains %" PRIu64
- " entries:\n",
- num_liblist),
- printable_section_name (filedata, section),
- num_liblist);
-
- puts (_(" Library Time Stamp Checksum Version Flags"));
-
- for (cnt = 0; cnt < section->sh_size / sizeof (Elf32_External_Lib);
- ++cnt)
- {
- Elf32_Lib liblist;
- time_t atime;
- char timebuf[128];
- struct tm * tmp;
-
- liblist.l_name = BYTE_GET (elib[cnt].l_name);
- atime = BYTE_GET (elib[cnt].l_time_stamp);
- liblist.l_checksum = BYTE_GET (elib[cnt].l_checksum);
- liblist.l_version = BYTE_GET (elib[cnt].l_version);
- liblist.l_flags = BYTE_GET (elib[cnt].l_flags);
-
- tmp = gmtime (&atime);
- snprintf (timebuf, sizeof (timebuf),
- "%04u-%02u-%02uT%02u:%02u:%02u",
- tmp->tm_year + 1900, tmp->tm_mon + 1, tmp->tm_mday,
- tmp->tm_hour, tmp->tm_min, tmp->tm_sec);
-
- printf ("%3zu: ", cnt);
- if (do_wide)
- printf ("%-20s", liblist.l_name < strtab_size
- ? strtab + liblist.l_name : _("<corrupt>"));
- else
- printf ("%-20.20s", liblist.l_name < strtab_size
- ? strtab + liblist.l_name : _("<corrupt>"));
- printf (" %s %#010lx %-7ld %-7ld\n", timebuf, liblist.l_checksum,
- liblist.l_version, liblist.l_flags);
- }
-
- free (elib);
- free (strtab);
- }
- }
-
- return res;
-}
-
-static const char *
-get_note_type (Filedata * filedata, unsigned e_type)
-{
- static char buff[64];
-
- if (filedata->file_header.e_type == ET_CORE)
- switch (e_type)
- {
- case NT_AUXV:
- return _("NT_AUXV (auxiliary vector)");
- case NT_PRSTATUS:
- return _("NT_PRSTATUS (prstatus structure)");
- case NT_FPREGSET:
- return _("NT_FPREGSET (floating point registers)");
- case NT_PRPSINFO:
- return _("NT_PRPSINFO (prpsinfo structure)");
- case NT_TASKSTRUCT:
- return _("NT_TASKSTRUCT (task structure)");
- case NT_GDB_TDESC:
- return _("NT_GDB_TDESC (GDB XML target description)");
- case NT_PRXFPREG:
- return _("NT_PRXFPREG (user_xfpregs structure)");
- case NT_PPC_VMX:
- return _("NT_PPC_VMX (ppc Altivec registers)");
- case NT_PPC_VSX:
- return _("NT_PPC_VSX (ppc VSX registers)");
- case NT_PPC_TAR:
- return _("NT_PPC_TAR (ppc TAR register)");
- case NT_PPC_PPR:
- return _("NT_PPC_PPR (ppc PPR register)");
- case NT_PPC_DSCR:
- return _("NT_PPC_DSCR (ppc DSCR register)");
- case NT_PPC_EBB:
- return _("NT_PPC_EBB (ppc EBB registers)");
- case NT_PPC_PMU:
- return _("NT_PPC_PMU (ppc PMU registers)");
- case NT_PPC_TM_CGPR:
- return _("NT_PPC_TM_CGPR (ppc checkpointed GPR registers)");
- case NT_PPC_TM_CFPR:
- return _("NT_PPC_TM_CFPR (ppc checkpointed floating point registers)");
- case NT_PPC_TM_CVMX:
- return _("NT_PPC_TM_CVMX (ppc checkpointed Altivec registers)");
- case NT_PPC_TM_CVSX:
- return _("NT_PPC_TM_CVSX (ppc checkpointed VSX registers)");
- case NT_PPC_TM_SPR:
- return _("NT_PPC_TM_SPR (ppc TM special purpose registers)");
- case NT_PPC_TM_CTAR:
- return _("NT_PPC_TM_CTAR (ppc checkpointed TAR register)");
- case NT_PPC_TM_CPPR:
- return _("NT_PPC_TM_CPPR (ppc checkpointed PPR register)");
- case NT_PPC_TM_CDSCR:
- return _("NT_PPC_TM_CDSCR (ppc checkpointed DSCR register)");
- case NT_386_TLS:
- return _("NT_386_TLS (x86 TLS information)");
- case NT_386_IOPERM:
- return _("NT_386_IOPERM (x86 I/O permissions)");
- case NT_X86_XSTATE:
- return _("NT_X86_XSTATE (x86 XSAVE extended state)");
- case NT_X86_CET:
- return _("NT_X86_CET (x86 CET state)");
- case NT_X86_SHSTK:
- return _("NT_X86_SHSTK (x86 SHSTK state)");
- case NT_S390_HIGH_GPRS:
- return _("NT_S390_HIGH_GPRS (s390 upper register halves)");
- case NT_S390_TIMER:
- return _("NT_S390_TIMER (s390 timer register)");
- case NT_S390_TODCMP:
- return _("NT_S390_TODCMP (s390 TOD comparator register)");
- case NT_S390_TODPREG:
- return _("NT_S390_TODPREG (s390 TOD programmable register)");
- case NT_S390_CTRS:
- return _("NT_S390_CTRS (s390 control registers)");
- case NT_S390_PREFIX:
- return _("NT_S390_PREFIX (s390 prefix register)");
- case NT_S390_LAST_BREAK:
- return _("NT_S390_LAST_BREAK (s390 last breaking event address)");
- case NT_S390_SYSTEM_CALL:
- return _("NT_S390_SYSTEM_CALL (s390 system call restart data)");
- case NT_S390_TDB:
- return _("NT_S390_TDB (s390 transaction diagnostic block)");
- case NT_S390_VXRS_LOW:
- return _("NT_S390_VXRS_LOW (s390 vector registers 0-15 upper half)");
- case NT_S390_VXRS_HIGH:
- return _("NT_S390_VXRS_HIGH (s390 vector registers 16-31)");
- case NT_S390_GS_CB:
- return _("NT_S390_GS_CB (s390 guarded-storage registers)");
- case NT_S390_GS_BC:
- return _("NT_S390_GS_BC (s390 guarded-storage broadcast control)");
- case NT_ARM_VFP:
- return _("NT_ARM_VFP (arm VFP registers)");
- case NT_ARM_TLS:
- return _("NT_ARM_TLS (AArch TLS registers)");
- case NT_ARM_HW_BREAK:
- return _("NT_ARM_HW_BREAK (AArch hardware breakpoint registers)");
- case NT_ARM_HW_WATCH:
- return _("NT_ARM_HW_WATCH (AArch hardware watchpoint registers)");
- case NT_ARM_SYSTEM_CALL:
- return _("NT_ARM_SYSTEM_CALL (AArch system call number)");
- case NT_ARM_SVE:
- return _("NT_ARM_SVE (AArch SVE registers)");
- case NT_ARM_PAC_MASK:
- return _("NT_ARM_PAC_MASK (AArch pointer authentication code masks)");
- case NT_ARM_PACA_KEYS:
- return _("NT_ARM_PACA_KEYS (ARM pointer authentication address keys)");
- case NT_ARM_PACG_KEYS:
- return _("NT_ARM_PACG_KEYS (ARM pointer authentication generic keys)");
- case NT_ARM_TAGGED_ADDR_CTRL:
- return _("NT_ARM_TAGGED_ADDR_CTRL (AArch tagged address control)");
- case NT_ARM_SSVE:
- return _("NT_ARM_SSVE (AArch64 streaming SVE registers)");
- case NT_ARM_ZA:
- return _("NT_ARM_ZA (AArch64 SME ZA register)");
- case NT_ARM_ZT:
- return _("NT_ARM_ZT (AArch64 SME2 ZT registers)");
- case NT_ARM_PAC_ENABLED_KEYS:
- return _("NT_ARM_PAC_ENABLED_KEYS (AArch64 pointer authentication enabled keys)");
- case NT_ARC_V2:
- return _("NT_ARC_V2 (ARC HS accumulator/extra registers)");
- case NT_RISCV_CSR:
- return _("NT_RISCV_CSR (RISC-V control and status registers)");
- case NT_PSTATUS:
- return _("NT_PSTATUS (pstatus structure)");
- case NT_FPREGS:
- return _("NT_FPREGS (floating point registers)");
- case NT_PSINFO:
- return _("NT_PSINFO (psinfo structure)");
- case NT_LWPSTATUS:
- return _("NT_LWPSTATUS (lwpstatus_t structure)");
- case NT_LWPSINFO:
- return _("NT_LWPSINFO (lwpsinfo_t structure)");
- case NT_WIN32PSTATUS:
- return _("NT_WIN32PSTATUS (win32_pstatus structure)");
- case NT_SIGINFO:
- return _("NT_SIGINFO (siginfo_t data)");
- case NT_FILE:
- return _("NT_FILE (mapped files)");
- default:
- break;
- }
- else
- switch (e_type)
- {
- case NT_VERSION:
- return _("NT_VERSION (version)");
- case NT_ARCH:
- return _("NT_ARCH (architecture)");
- case NT_GNU_BUILD_ATTRIBUTE_OPEN:
- return _("OPEN");
- case NT_GNU_BUILD_ATTRIBUTE_FUNC:
- return _("func");
- case NT_GO_BUILDID:
- return _("GO BUILDID");
- case FDO_PACKAGING_METADATA:
- return _("FDO_PACKAGING_METADATA");
- case FDO_DLOPEN_METADATA:
- return _("FDO_DLOPEN_METADATA");
- default:
- break;
- }
-
- snprintf (buff, sizeof (buff), _("Unknown note type: (0x%08x)"), e_type);
- return buff;
-}
-
-static bool
-print_core_note (Elf_Internal_Note *pnote)
-{
- unsigned int addr_size = is_32bit_elf ? 4 : 8;
- uint64_t count, page_size;
- unsigned char *descdata, *filenames, *descend;
-
- if (pnote->type != NT_FILE)
- {
- if (do_wide)
- printf ("\n");
- return true;
- }
-
- if (pnote->descsz < 2 * addr_size)
- {
- error (_(" Malformed note - too short for header\n"));
- return false;
- }
-
- descdata = (unsigned char *) pnote->descdata;
- descend = descdata + pnote->descsz;
-
- if (descdata[pnote->descsz - 1] != '\0')
- {
- error (_(" Malformed note - does not end with \\0\n"));
- return false;
- }
-
- count = byte_get (descdata, addr_size);
- descdata += addr_size;
-
- page_size = byte_get (descdata, addr_size);
- descdata += addr_size;
-
- if (count > ((uint64_t) -1 - 2 * addr_size) / (3 * addr_size)
- || pnote->descsz < 2 * addr_size + count * 3 * addr_size)
- {
- error (_(" Malformed note - too short for supplied file count\n"));
- return false;
- }
-
- printf (_(" Page size: "));
- print_vma (page_size, DEC);
- printf ("\n");
-
- printf (_(" %*s%*s%*s\n"),
- (int) (2 + 2 * addr_size), _("Start"),
- (int) (4 + 2 * addr_size), _("End"),
- (int) (4 + 2 * addr_size), _("Page Offset"));
- filenames = descdata + count * 3 * addr_size;
- while (count-- > 0)
- {
- uint64_t start, end, file_ofs;
-
- if (filenames == descend)
- {
- error (_(" Malformed note - filenames end too early\n"));
- return false;
- }
-
- start = byte_get (descdata, addr_size);
- descdata += addr_size;
- end = byte_get (descdata, addr_size);
- descdata += addr_size;
- file_ofs = byte_get (descdata, addr_size);
- descdata += addr_size;
-
- printf (" ");
- print_vma (start, FULL_HEX);
- printf (" ");
- print_vma (end, FULL_HEX);
- printf (" ");
- print_vma (file_ofs, FULL_HEX);
- printf ("\n %s\n", filenames);
-
- filenames += 1 + strlen ((char *) filenames);
- }
-
- return true;
-}
-
-static const char *
-get_gnu_elf_note_type (unsigned e_type)
-{
- /* NB/ Keep this switch statement in sync with print_gnu_note (). */
- switch (e_type)
- {
- case NT_GNU_ABI_TAG:
- return _("NT_GNU_ABI_TAG (ABI version tag)");
- case NT_GNU_HWCAP:
- return _("NT_GNU_HWCAP (DSO-supplied software HWCAP info)");
- case NT_GNU_BUILD_ID:
- return _("NT_GNU_BUILD_ID (unique build ID bitstring)");
- case NT_GNU_GOLD_VERSION:
- return _("NT_GNU_GOLD_VERSION (gold version)");
- case NT_GNU_PROPERTY_TYPE_0:
- return _("NT_GNU_PROPERTY_TYPE_0");
- case NT_GNU_BUILD_ATTRIBUTE_OPEN:
- return _("NT_GNU_BUILD_ATTRIBUTE_OPEN");
- case NT_GNU_BUILD_ATTRIBUTE_FUNC:
- return _("NT_GNU_BUILD_ATTRIBUTE_FUNC");
- default:
- {
- static char buff[64];
-
- snprintf (buff, sizeof (buff), _("Unknown note type: (0x%08x)"), e_type);
- return buff;
- }
- }
-}
-
-static void
-decode_x86_compat_isa (unsigned int bitmask)
-{
- while (bitmask)
- {
- unsigned int bit = bitmask & (- bitmask);
-
- bitmask &= ~ bit;
- switch (bit)
- {
- case GNU_PROPERTY_X86_COMPAT_ISA_1_486:
- printf ("i486");
- break;
- case GNU_PROPERTY_X86_COMPAT_ISA_1_586:
- printf ("586");
- break;
- case GNU_PROPERTY_X86_COMPAT_ISA_1_686:
- printf ("686");
- break;
- case GNU_PROPERTY_X86_COMPAT_ISA_1_SSE:
- printf ("SSE");
- break;
- case GNU_PROPERTY_X86_COMPAT_ISA_1_SSE2:
- printf ("SSE2");
- break;
- case GNU_PROPERTY_X86_COMPAT_ISA_1_SSE3:
- printf ("SSE3");
- break;
- case GNU_PROPERTY_X86_COMPAT_ISA_1_SSSE3:
- printf ("SSSE3");
- break;
- case GNU_PROPERTY_X86_COMPAT_ISA_1_SSE4_1:
- printf ("SSE4_1");
- break;
- case GNU_PROPERTY_X86_COMPAT_ISA_1_SSE4_2:
- printf ("SSE4_2");
- break;
- case GNU_PROPERTY_X86_COMPAT_ISA_1_AVX:
- printf ("AVX");
- break;
- case GNU_PROPERTY_X86_COMPAT_ISA_1_AVX2:
- printf ("AVX2");
- break;
- case GNU_PROPERTY_X86_COMPAT_ISA_1_AVX512F:
- printf ("AVX512F");
- break;
- case GNU_PROPERTY_X86_COMPAT_ISA_1_AVX512CD:
- printf ("AVX512CD");
- break;
- case GNU_PROPERTY_X86_COMPAT_ISA_1_AVX512ER:
- printf ("AVX512ER");
- break;
- case GNU_PROPERTY_X86_COMPAT_ISA_1_AVX512PF:
- printf ("AVX512PF");
- break;
- case GNU_PROPERTY_X86_COMPAT_ISA_1_AVX512VL:
- printf ("AVX512VL");
- break;
- case GNU_PROPERTY_X86_COMPAT_ISA_1_AVX512DQ:
- printf ("AVX512DQ");
- break;
- case GNU_PROPERTY_X86_COMPAT_ISA_1_AVX512BW:
- printf ("AVX512BW");
- break;
- default:
- printf (_("<unknown: %x>"), bit);
- break;
- }
- if (bitmask)
- printf (", ");
- }
-}
-
-static void
-decode_x86_compat_2_isa (unsigned int bitmask)
-{
- if (!bitmask)
- {
- printf (_("<None>"));
- return;
- }
-
- while (bitmask)
- {
- unsigned int bit = bitmask & (- bitmask);
-
- bitmask &= ~ bit;
- switch (bit)
- {
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_CMOV:
- printf ("CMOV");
- break;
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_SSE:
- printf ("SSE");
- break;
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_SSE2:
- printf ("SSE2");
- break;
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_SSE3:
- printf ("SSE3");
- break;
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_SSSE3:
- printf ("SSSE3");
- break;
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_SSE4_1:
- printf ("SSE4_1");
- break;
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_SSE4_2:
- printf ("SSE4_2");
- break;
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_AVX:
- printf ("AVX");
- break;
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_AVX2:
- printf ("AVX2");
- break;
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_FMA:
- printf ("FMA");
- break;
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_AVX512F:
- printf ("AVX512F");
- break;
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_AVX512CD:
- printf ("AVX512CD");
- break;
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_AVX512ER:
- printf ("AVX512ER");
- break;
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_AVX512PF:
- printf ("AVX512PF");
- break;
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_AVX512VL:
- printf ("AVX512VL");
- break;
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_AVX512DQ:
- printf ("AVX512DQ");
- break;
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_AVX512BW:
- printf ("AVX512BW");
- break;
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_AVX512_4FMAPS:
- printf ("AVX512_4FMAPS");
- break;
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_AVX512_4VNNIW:
- printf ("AVX512_4VNNIW");
- break;
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_AVX512_BITALG:
- printf ("AVX512_BITALG");
- break;
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_AVX512_IFMA:
- printf ("AVX512_IFMA");
- break;
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_AVX512_VBMI:
- printf ("AVX512_VBMI");
- break;
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_AVX512_VBMI2:
- printf ("AVX512_VBMI2");
- break;
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_AVX512_VNNI:
- printf ("AVX512_VNNI");
- break;
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_AVX512_BF16:
- printf ("AVX512_BF16");
- break;
- default:
- printf (_("<unknown: %x>"), bit);
- break;
- }
- if (bitmask)
- printf (", ");
- }
-}
-
-static const char *
-get_amdgpu_elf_note_type (unsigned int e_type)
-{
- switch (e_type)
- {
- case NT_AMDGPU_METADATA:
- return _("NT_AMDGPU_METADATA (code object metadata)");
- default:
- {
- static char buf[64];
- snprintf (buf, sizeof (buf), _("Unknown note type: (0x%08x)"), e_type);
- return buf;
- }
- }
-}
-
-static void
-decode_x86_isa (unsigned int bitmask)
-{
- while (bitmask)
- {
- unsigned int bit = bitmask & (- bitmask);
-
- bitmask &= ~ bit;
- switch (bit)
- {
- case GNU_PROPERTY_X86_ISA_1_BASELINE:
- printf ("x86-64-baseline");
- break;
- case GNU_PROPERTY_X86_ISA_1_V2:
- printf ("x86-64-v2");
- break;
- case GNU_PROPERTY_X86_ISA_1_V3:
- printf ("x86-64-v3");
- break;
- case GNU_PROPERTY_X86_ISA_1_V4:
- printf ("x86-64-v4");
- break;
- default:
- printf (_("<unknown: %x>"), bit);
- break;
- }
- if (bitmask)
- printf (", ");
- }
-}
-
-static void
-decode_x86_feature_1 (unsigned int bitmask)
-{
- if (!bitmask)
- {
- printf (_("<None>"));
- return;
- }
-
- while (bitmask)
- {
- unsigned int bit = bitmask & (- bitmask);
-
- bitmask &= ~ bit;
- switch (bit)
- {
- case GNU_PROPERTY_X86_FEATURE_1_IBT:
- printf ("IBT");
- break;
- case GNU_PROPERTY_X86_FEATURE_1_SHSTK:
- printf ("SHSTK");
- break;
- case GNU_PROPERTY_X86_FEATURE_1_LAM_U48:
- printf ("LAM_U48");
- break;
- case GNU_PROPERTY_X86_FEATURE_1_LAM_U57:
- printf ("LAM_U57");
- break;
- default:
- printf (_("<unknown: %x>"), bit);
- break;
- }
- if (bitmask)
- printf (", ");
- }
-}
-
-static void
-decode_x86_feature_2 (unsigned int bitmask)
-{
- if (!bitmask)
- {
- printf (_("<None>"));
- return;
- }
-
- while (bitmask)
- {
- unsigned int bit = bitmask & (- bitmask);
-
- bitmask &= ~ bit;
- switch (bit)
- {
- case GNU_PROPERTY_X86_FEATURE_2_X86:
- printf ("x86");
- break;
- case GNU_PROPERTY_X86_FEATURE_2_X87:
- printf ("x87");
- break;
- case GNU_PROPERTY_X86_FEATURE_2_MMX:
- printf ("MMX");
- break;
- case GNU_PROPERTY_X86_FEATURE_2_XMM:
- printf ("XMM");
- break;
- case GNU_PROPERTY_X86_FEATURE_2_YMM:
- printf ("YMM");
- break;
- case GNU_PROPERTY_X86_FEATURE_2_ZMM:
- printf ("ZMM");
- break;
- case GNU_PROPERTY_X86_FEATURE_2_TMM:
- printf ("TMM");
- break;
- case GNU_PROPERTY_X86_FEATURE_2_MASK:
- printf ("MASK");
- break;
- case GNU_PROPERTY_X86_FEATURE_2_FXSR:
- printf ("FXSR");
- break;
- case GNU_PROPERTY_X86_FEATURE_2_XSAVE:
- printf ("XSAVE");
- break;
- case GNU_PROPERTY_X86_FEATURE_2_XSAVEOPT:
- printf ("XSAVEOPT");
- break;
- case GNU_PROPERTY_X86_FEATURE_2_XSAVEC:
- printf ("XSAVEC");
- break;
- default:
- printf (_("<unknown: %x>"), bit);
- break;
- }
- if (bitmask)
- printf (", ");
- }
-}
-
-static void
-decode_aarch64_feature_1_and (unsigned int bitmask)
-{
- while (bitmask)
- {
- unsigned int bit = bitmask & (- bitmask);
-
- bitmask &= ~ bit;
- switch (bit)
- {
- case GNU_PROPERTY_AARCH64_FEATURE_1_BTI:
- printf ("BTI");
- break;
-
- case GNU_PROPERTY_AARCH64_FEATURE_1_PAC:
- printf ("PAC");
- break;
-
- default:
- printf (_("<unknown: %x>"), bit);
- break;
- }
- if (bitmask)
- printf (", ");
- }
-}
-
-static void
-decode_1_needed (unsigned int bitmask)
-{
- while (bitmask)
- {
- unsigned int bit = bitmask & (- bitmask);
-
- bitmask &= ~ bit;
- switch (bit)
- {
- case GNU_PROPERTY_1_NEEDED_INDIRECT_EXTERN_ACCESS:
- printf ("indirect external access");
- break;
- default:
- printf (_("<unknown: %x>"), bit);
- break;
- }
- if (bitmask)
- printf (", ");
- }
-}
-
-static void
-print_gnu_property_note (Filedata * filedata, Elf_Internal_Note * pnote)
-{
- unsigned char * ptr = (unsigned char *) pnote->descdata;
- unsigned char * ptr_end = ptr + pnote->descsz;
- unsigned int size = is_32bit_elf ? 4 : 8;
-
- printf (_(" Properties: "));
-
- if (pnote->descsz < 8 || (pnote->descsz % size) != 0)
- {
- printf (_("<corrupt GNU_PROPERTY_TYPE, size = %#lx>\n"), pnote->descsz);
- return;
- }
-
- while (ptr < ptr_end)
- {
- unsigned int j;
- unsigned int type;
- unsigned int datasz;
-
- if ((size_t) (ptr_end - ptr) < 8)
- {
- printf (_("<corrupt descsz: %#lx>\n"), pnote->descsz);
- break;
- }
-
- type = byte_get (ptr, 4);
- datasz = byte_get (ptr + 4, 4);
-
- ptr += 8;
-
- if (datasz > (size_t) (ptr_end - ptr))
- {
- printf (_("<corrupt type (%#x) datasz: %#x>\n"),
- type, datasz);
- break;
- }
-
- if (type >= GNU_PROPERTY_LOPROC && type <= GNU_PROPERTY_HIPROC)
- {
- if (filedata->file_header.e_machine == EM_X86_64
- || filedata->file_header.e_machine == EM_IAMCU
- || filedata->file_header.e_machine == EM_386)
- {
- unsigned int bitmask;
-
- if (datasz == 4)
- bitmask = byte_get (ptr, 4);
- else
- bitmask = 0;
-
- switch (type)
- {
- case GNU_PROPERTY_X86_ISA_1_USED:
- if (datasz != 4)
- printf (_("x86 ISA used: <corrupt length: %#x> "),
- datasz);
- else
- {
- printf ("x86 ISA used: ");
- decode_x86_isa (bitmask);
- }
- goto next;
-
- case GNU_PROPERTY_X86_ISA_1_NEEDED:
- if (datasz != 4)
- printf (_("x86 ISA needed: <corrupt length: %#x> "),
- datasz);
- else
- {
- printf ("x86 ISA needed: ");
- decode_x86_isa (bitmask);
- }
- goto next;
-
- case GNU_PROPERTY_X86_FEATURE_1_AND:
- if (datasz != 4)
- printf (_("x86 feature: <corrupt length: %#x> "),
- datasz);
- else
- {
- printf ("x86 feature: ");
- decode_x86_feature_1 (bitmask);
- }
- goto next;
-
- case GNU_PROPERTY_X86_FEATURE_2_USED:
- if (datasz != 4)
- printf (_("x86 feature used: <corrupt length: %#x> "),
- datasz);
- else
- {
- printf ("x86 feature used: ");
- decode_x86_feature_2 (bitmask);
- }
- goto next;
-
- case GNU_PROPERTY_X86_FEATURE_2_NEEDED:
- if (datasz != 4)
- printf (_("x86 feature needed: <corrupt length: %#x> "), datasz);
- else
- {
- printf ("x86 feature needed: ");
- decode_x86_feature_2 (bitmask);
- }
- goto next;
-
- case GNU_PROPERTY_X86_COMPAT_ISA_1_USED:
- if (datasz != 4)
- printf (_("x86 ISA used: <corrupt length: %#x> "),
- datasz);
- else
- {
- printf ("x86 ISA used: ");
- decode_x86_compat_isa (bitmask);
- }
- goto next;
-
- case GNU_PROPERTY_X86_COMPAT_ISA_1_NEEDED:
- if (datasz != 4)
- printf (_("x86 ISA needed: <corrupt length: %#x> "),
- datasz);
- else
- {
- printf ("x86 ISA needed: ");
- decode_x86_compat_isa (bitmask);
- }
- goto next;
-
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_USED:
- if (datasz != 4)
- printf (_("x86 ISA used: <corrupt length: %#x> "),
- datasz);
- else
- {
- printf ("x86 ISA used: ");
- decode_x86_compat_2_isa (bitmask);
- }
- goto next;
-
- case GNU_PROPERTY_X86_COMPAT_2_ISA_1_NEEDED:
- if (datasz != 4)
- printf (_("x86 ISA needed: <corrupt length: %#x> "),
- datasz);
- else
- {
- printf ("x86 ISA needed: ");
- decode_x86_compat_2_isa (bitmask);
- }
- goto next;
-
- default:
- break;
- }
- }
- else if (filedata->file_header.e_machine == EM_AARCH64)
- {
- if (type == GNU_PROPERTY_AARCH64_FEATURE_1_AND)
- {
- printf ("AArch64 feature: ");
- if (datasz != 4)
- printf (_("<corrupt length: %#x> "), datasz);
- else
- decode_aarch64_feature_1_and (byte_get (ptr, 4));
- goto next;
- }
- }
- }
- else
- {
- switch (type)
- {
- case GNU_PROPERTY_STACK_SIZE:
- printf (_("stack size: "));
- if (datasz != size)
- printf (_("<corrupt length: %#x> "), datasz);
- else
- printf ("%#" PRIx64, byte_get (ptr, size));
- goto next;
-
- case GNU_PROPERTY_NO_COPY_ON_PROTECTED:
- printf ("no copy on protected ");
- if (datasz)
- printf (_("<corrupt length: %#x> "), datasz);
- goto next;
-
- default:
- if ((type >= GNU_PROPERTY_UINT32_AND_LO
- && type <= GNU_PROPERTY_UINT32_AND_HI)
- || (type >= GNU_PROPERTY_UINT32_OR_LO
- && type <= GNU_PROPERTY_UINT32_OR_HI))
- {
- switch (type)
- {
- case GNU_PROPERTY_1_NEEDED:
- if (datasz != 4)
- printf (_("1_needed: <corrupt length: %#x> "),
- datasz);
- else
- {
- unsigned int bitmask = byte_get (ptr, 4);
- printf ("1_needed: ");
- decode_1_needed (bitmask);
- }
- goto next;
-
- default:
- break;
- }
- if (type <= GNU_PROPERTY_UINT32_AND_HI)
- printf (_("UINT32_AND (%#x): "), type);
- else
- printf (_("UINT32_OR (%#x): "), type);
- if (datasz != 4)
- printf (_("<corrupt length: %#x> "), datasz);
- else
- printf ("%#x", (unsigned int) byte_get (ptr, 4));
- goto next;
- }
- break;
- }
- }
-
- if (type < GNU_PROPERTY_LOPROC)
- printf (_("<unknown type %#x data: "), type);
- else if (type < GNU_PROPERTY_LOUSER)
- printf (_("<processor-specific type %#x data: "), type);
- else
- printf (_("<application-specific type %#x data: "), type);
- for (j = 0; j < datasz; ++j)
- printf ("%02x ", ptr[j] & 0xff);
- printf (">");
-
- next:
- ptr += ((datasz + (size - 1)) & ~ (size - 1));
- if (ptr == ptr_end)
- break;
-
- if (do_wide)
- printf (", ");
- else
- printf ("\n\t");
- }
-
- printf ("\n");
-}
-
-static bool
-print_gnu_note (Filedata * filedata, Elf_Internal_Note *pnote)
-{
- /* NB/ Keep this switch statement in sync with get_gnu_elf_note_type (). */
- switch (pnote->type)
- {
- case NT_GNU_BUILD_ID:
- {
- size_t i;
-
- printf (_(" Build ID: "));
- for (i = 0; i < pnote->descsz; ++i)
- printf ("%02x", pnote->descdata[i] & 0xff);
- printf ("\n");
- }
- break;
-
- case NT_GNU_ABI_TAG:
- {
- unsigned int os, major, minor, subminor;
- const char *osname;
-
- /* PR 17531: file: 030-599401-0.004. */
- if (pnote->descsz < 16)
- {
- printf (_(" <corrupt GNU_ABI_TAG>\n"));
- break;
- }
-
- os = byte_get ((unsigned char *) pnote->descdata, 4);
- major = byte_get ((unsigned char *) pnote->descdata + 4, 4);
- minor = byte_get ((unsigned char *) pnote->descdata + 8, 4);
- subminor = byte_get ((unsigned char *) pnote->descdata + 12, 4);
-
- switch (os)
- {
- case GNU_ABI_TAG_LINUX:
- osname = "Linux";
- break;
- case GNU_ABI_TAG_HURD:
- osname = "Hurd";
- break;
- case GNU_ABI_TAG_SOLARIS:
- osname = "Solaris";
- break;
- case GNU_ABI_TAG_FREEBSD:
- osname = "FreeBSD";
- break;
- case GNU_ABI_TAG_NETBSD:
- osname = "NetBSD";
- break;
- case GNU_ABI_TAG_SYLLABLE:
- osname = "Syllable";
- break;
- case GNU_ABI_TAG_NACL:
- osname = "NaCl";
- break;
- default:
- osname = "Unknown";
- break;
- }
-
- printf (_(" OS: %s, ABI: %d.%d.%d\n"), osname,
- major, minor, subminor);
- }
- break;
-
- case NT_GNU_GOLD_VERSION:
- {
- size_t i;
-
- printf (_(" Version: "));
- for (i = 0; i < pnote->descsz && pnote->descdata[i] != '\0'; ++i)
- printf ("%c", pnote->descdata[i]);
- printf ("\n");
- }
- break;
-
- case NT_GNU_HWCAP:
- {
- unsigned int num_entries, mask;
-
- /* Hardware capabilities information. Word 0 is the number of entries.
- Word 1 is a bitmask of enabled entries. The rest of the descriptor
- is a series of entries, where each entry is a single byte followed
- by a nul terminated string. The byte gives the bit number to test
- if enabled in the bitmask. */
- printf (_(" Hardware Capabilities: "));
- if (pnote->descsz < 8)
- {
- error (_("<corrupt GNU_HWCAP>\n"));
- return false;
- }
- num_entries = byte_get ((unsigned char *) pnote->descdata, 4);
- mask = byte_get ((unsigned char *) pnote->descdata + 4, 4);
- printf (_("num entries: %d, enabled mask: %x\n"), num_entries, mask);
- /* FIXME: Add code to display the entries... */
- }
- break;
-
- case NT_GNU_PROPERTY_TYPE_0:
- print_gnu_property_note (filedata, pnote);
- break;
-
- default:
- /* Handle unrecognised types. An error message should have already been
- created by get_gnu_elf_note_type(), so all that we need to do is to
- display the data. */
- {
- size_t i;
-
- printf (_(" Description data: "));
- for (i = 0; i < pnote->descsz; ++i)
- printf ("%02x ", pnote->descdata[i] & 0xff);
- printf ("\n");
- }
- break;
- }
-
- return true;
-}
-
-static const char *
-get_v850_elf_note_type (enum v850_notes n_type)
-{
- static char buff[64];
-
- switch (n_type)
- {
- case V850_NOTE_ALIGNMENT: return _("Alignment of 8-byte objects");
- case V850_NOTE_DATA_SIZE: return _("Sizeof double and long double");
- case V850_NOTE_FPU_INFO: return _("Type of FPU support needed");
- case V850_NOTE_SIMD_INFO: return _("Use of SIMD instructions");
- case V850_NOTE_CACHE_INFO: return _("Use of cache");
- case V850_NOTE_MMU_INFO: return _("Use of MMU");
- default:
- snprintf (buff, sizeof (buff), _("Unknown note type: (0x%08x)"), n_type);
- return buff;
- }
-}
-
-static bool
-print_v850_note (Elf_Internal_Note * pnote)
-{
- unsigned int val;
-
- if (pnote->descsz != 4)
- return false;
-
- val = byte_get ((unsigned char *) pnote->descdata, pnote->descsz);
-
- if (val == 0)
- {
- printf (_("not set\n"));
- return true;
- }
-
- switch (pnote->type)
- {
- case V850_NOTE_ALIGNMENT:
- switch (val)
- {
- case EF_RH850_DATA_ALIGN4: printf (_("4-byte\n")); return true;
- case EF_RH850_DATA_ALIGN8: printf (_("8-byte\n")); return true;
- }
- break;
-
- case V850_NOTE_DATA_SIZE:
- switch (val)
- {
- case EF_RH850_DOUBLE32: printf (_("4-bytes\n")); return true;
- case EF_RH850_DOUBLE64: printf (_("8-bytes\n")); return true;
- }
- break;
-
- case V850_NOTE_FPU_INFO:
- switch (val)
- {
- case EF_RH850_FPU20: printf (_("FPU-2.0\n")); return true;
- case EF_RH850_FPU30: printf (_("FPU-3.0\n")); return true;
- }
- break;
-
- case V850_NOTE_MMU_INFO:
- case V850_NOTE_CACHE_INFO:
- case V850_NOTE_SIMD_INFO:
- if (val == EF_RH850_SIMD)
- {
- printf (_("yes\n"));
- return true;
- }
- break;
-
- default:
- /* An 'unknown note type' message will already have been displayed. */
- break;
- }
-
- printf (_("unknown value: %x\n"), val);
- return false;
-}
-
-static bool
-process_netbsd_elf_note (Elf_Internal_Note * pnote)
-{
- unsigned int version;
-
- switch (pnote->type)
- {
- case NT_NETBSD_IDENT:
- if (pnote->descsz < 1)
- break;
- version = byte_get ((unsigned char *) pnote->descdata, sizeof (version));
- if ((version / 10000) % 100)
- printf (" NetBSD\t\t0x%08lx\tIDENT %u (%u.%u%s%c)\n", pnote->descsz,
- version, version / 100000000, (version / 1000000) % 100,
- (version / 10000) % 100 > 26 ? "Z" : "",
- 'A' + (version / 10000) % 26);
- else
- printf (" NetBSD\t\t0x%08lx\tIDENT %u (%u.%u.%u)\n", pnote->descsz,
- version, version / 100000000, (version / 1000000) % 100,
- (version / 100) % 100);
- return true;
-
- case NT_NETBSD_MARCH:
- printf (" NetBSD\t\t0x%08lx\tMARCH <%s>\n", pnote->descsz,
- pnote->descdata);
- return true;
-
- case NT_NETBSD_PAX:
- if (pnote->descsz < 1)
- break;
- version = byte_get ((unsigned char *) pnote->descdata, sizeof (version));
- printf (" NetBSD\t\t0x%08lx\tPaX <%s%s%s%s%s%s>\n", pnote->descsz,
- ((version & NT_NETBSD_PAX_MPROTECT) ? "+mprotect" : ""),
- ((version & NT_NETBSD_PAX_NOMPROTECT) ? "-mprotect" : ""),
- ((version & NT_NETBSD_PAX_GUARD) ? "+guard" : ""),
- ((version & NT_NETBSD_PAX_NOGUARD) ? "-guard" : ""),
- ((version & NT_NETBSD_PAX_ASLR) ? "+ASLR" : ""),
- ((version & NT_NETBSD_PAX_NOASLR) ? "-ASLR" : ""));
- return true;
- }
-
- printf (" NetBSD\t0x%08lx\tUnknown note type: (0x%08lx)\n",
- pnote->descsz, pnote->type);
- return false;
-}
-
-static const char *
-get_freebsd_elfcore_note_type (Filedata * filedata, unsigned e_type)
-{
- switch (e_type)
- {
- case NT_FREEBSD_THRMISC:
- return _("NT_THRMISC (thrmisc structure)");
- case NT_FREEBSD_PROCSTAT_PROC:
- return _("NT_PROCSTAT_PROC (proc data)");
- case NT_FREEBSD_PROCSTAT_FILES:
- return _("NT_PROCSTAT_FILES (files data)");
- case NT_FREEBSD_PROCSTAT_VMMAP:
- return _("NT_PROCSTAT_VMMAP (vmmap data)");
- case NT_FREEBSD_PROCSTAT_GROUPS:
- return _("NT_PROCSTAT_GROUPS (groups data)");
- case NT_FREEBSD_PROCSTAT_UMASK:
- return _("NT_PROCSTAT_UMASK (umask data)");
- case NT_FREEBSD_PROCSTAT_RLIMIT:
- return _("NT_PROCSTAT_RLIMIT (rlimit data)");
- case NT_FREEBSD_PROCSTAT_OSREL:
- return _("NT_PROCSTAT_OSREL (osreldate data)");
- case NT_FREEBSD_PROCSTAT_PSSTRINGS:
- return _("NT_PROCSTAT_PSSTRINGS (ps_strings data)");
- case NT_FREEBSD_PROCSTAT_AUXV:
- return _("NT_PROCSTAT_AUXV (auxv data)");
- case NT_FREEBSD_PTLWPINFO:
- return _("NT_PTLWPINFO (ptrace_lwpinfo structure)");
- case NT_FREEBSD_X86_SEGBASES:
- return _("NT_X86_SEGBASES (x86 segment base registers)");
- }
- return get_note_type (filedata, e_type);
-}
-
-static const char *
-get_netbsd_elfcore_note_type (Filedata * filedata, unsigned e_type)
-{
- static char buff[64];
-
- switch (e_type)
- {
- case NT_NETBSDCORE_PROCINFO:
- /* NetBSD core "procinfo" structure. */
- return _("NetBSD procinfo structure");
-
- case NT_NETBSDCORE_AUXV:
- return _("NetBSD ELF auxiliary vector data");
-
- case NT_NETBSDCORE_LWPSTATUS:
- return _("PT_LWPSTATUS (ptrace_lwpstatus structure)");
-
- default:
- /* As of Jan 2020 there are no other machine-independent notes
- defined for NetBSD core files. If the note type is less
- than the start of the machine-dependent note types, we don't
- understand it. */
-
- if (e_type < NT_NETBSDCORE_FIRSTMACH)
- {
- snprintf (buff, sizeof (buff), _("Unknown note type: (0x%08x)"), e_type);
- return buff;
- }
- break;
- }
-
- switch (filedata->file_header.e_machine)
- {
- /* On the Alpha, SPARC (32-bit and 64-bit), PT_GETREGS == mach+0
- and PT_GETFPREGS == mach+2. */
-
- case EM_OLD_ALPHA:
- case EM_ALPHA:
- case EM_SPARC:
- case EM_SPARC32PLUS:
- case EM_SPARCV9:
- switch (e_type)
- {
- case NT_NETBSDCORE_FIRSTMACH + 0:
- return _("PT_GETREGS (reg structure)");
- case NT_NETBSDCORE_FIRSTMACH + 2:
- return _("PT_GETFPREGS (fpreg structure)");
- default:
- break;
- }
- break;
-
- /* On SuperH, PT_GETREGS == mach+3 and PT_GETFPREGS == mach+5.
- There's also old PT___GETREGS40 == mach + 1 for old reg
- structure which lacks GBR. */
- case EM_SH:
- switch (e_type)
- {
- case NT_NETBSDCORE_FIRSTMACH + 1:
- return _("PT___GETREGS40 (old reg structure)");
- case NT_NETBSDCORE_FIRSTMACH + 3:
- return _("PT_GETREGS (reg structure)");
- case NT_NETBSDCORE_FIRSTMACH + 5:
- return _("PT_GETFPREGS (fpreg structure)");
- default:
- break;
- }
- break;
-
- /* On all other arch's, PT_GETREGS == mach+1 and
- PT_GETFPREGS == mach+3. */
- default:
- switch (e_type)
- {
- case NT_NETBSDCORE_FIRSTMACH + 1:
- return _("PT_GETREGS (reg structure)");
- case NT_NETBSDCORE_FIRSTMACH + 3:
- return _("PT_GETFPREGS (fpreg structure)");
- default:
- break;
- }
- }
-
- snprintf (buff, sizeof (buff), "PT_FIRSTMACH+%d",
- e_type - NT_NETBSDCORE_FIRSTMACH);
- return buff;
-}
-
-static const char *
-get_openbsd_elfcore_note_type (Filedata * filedata, unsigned e_type)
-{
- switch (e_type)
- {
- case NT_OPENBSD_PROCINFO:
- return _("OpenBSD procinfo structure");
- case NT_OPENBSD_AUXV:
- return _("OpenBSD ELF auxiliary vector data");
- case NT_OPENBSD_REGS:
- return _("OpenBSD regular registers");
- case NT_OPENBSD_FPREGS:
- return _("OpenBSD floating point registers");
- case NT_OPENBSD_WCOOKIE:
- return _("OpenBSD window cookie");
- }
-
- return get_note_type (filedata, e_type);
-}
-
-static const char *
-get_qnx_elfcore_note_type (Filedata * filedata, unsigned e_type)
-{
- switch (e_type)
- {
- case QNT_DEBUG_FULLPATH:
- return _("QNX debug fullpath");
- case QNT_DEBUG_RELOC:
- return _("QNX debug relocation");
- case QNT_STACK:
- return _("QNX stack");
- case QNT_GENERATOR:
- return _("QNX generator");
- case QNT_DEFAULT_LIB:
- return _("QNX default library");
- case QNT_CORE_SYSINFO:
- return _("QNX core sysinfo");
- case QNT_CORE_INFO:
- return _("QNX core info");
- case QNT_CORE_STATUS:
- return _("QNX core status");
- case QNT_CORE_GREG:
- return _("QNX general registers");
- case QNT_CORE_FPREG:
- return _("QNX floating point registers");
- case QNT_LINK_MAP:
- return _("QNX link map");
- }
-
- return get_note_type (filedata, e_type);
-}
-
-static const char *
-get_stapsdt_note_type (unsigned e_type)
-{
- static char buff[64];
-
- switch (e_type)
- {
- case NT_STAPSDT:
- return _("NT_STAPSDT (SystemTap probe descriptors)");
-
- default:
- break;
- }
-
- snprintf (buff, sizeof (buff), _("Unknown note type: (0x%08x)"), e_type);
- return buff;
-}
-
-static bool
-print_stapsdt_note (Elf_Internal_Note *pnote)
-{
- size_t len, maxlen;
- size_t addr_size = is_32bit_elf ? 4 : 8;
- char *data = pnote->descdata;
- char *data_end = pnote->descdata + pnote->descsz;
- uint64_t pc, base_addr, semaphore;
- char *provider, *probe, *arg_fmt;
-
- if (pnote->descsz < (addr_size * 3))
- goto stapdt_note_too_small;
-
- pc = byte_get ((unsigned char *) data, addr_size);
- data += addr_size;
-
- base_addr = byte_get ((unsigned char *) data, addr_size);
- data += addr_size;
-
- semaphore = byte_get ((unsigned char *) data, addr_size);
- data += addr_size;
-
- if (data >= data_end)
- goto stapdt_note_too_small;
- maxlen = data_end - data;
- len = strnlen (data, maxlen);
- if (len < maxlen)
- {
- provider = data;
- data += len + 1;
- }
- else
- goto stapdt_note_too_small;
-
- if (data >= data_end)
- goto stapdt_note_too_small;
- maxlen = data_end - data;
- len = strnlen (data, maxlen);
- if (len < maxlen)
- {
- probe = data;
- data += len + 1;
- }
- else
- goto stapdt_note_too_small;
-
- if (data >= data_end)
- goto stapdt_note_too_small;
- maxlen = data_end - data;
- len = strnlen (data, maxlen);
- if (len < maxlen)
- {
- arg_fmt = data;
- data += len + 1;
- }
- else
- goto stapdt_note_too_small;
-
- printf (_(" Provider: %s\n"), provider);
- printf (_(" Name: %s\n"), probe);
- printf (_(" Location: "));
- print_vma (pc, FULL_HEX);
- printf (_(", Base: "));
- print_vma (base_addr, FULL_HEX);
- printf (_(", Semaphore: "));
- print_vma (semaphore, FULL_HEX);
- printf ("\n");
- printf (_(" Arguments: %s\n"), arg_fmt);
-
- return data == data_end;
-
- stapdt_note_too_small:
- printf (_(" <corrupt - note is too small>\n"));
- error (_("corrupt stapdt note - the data size is too small\n"));
- return false;
-}
-
-static bool
-print_fdo_note (Elf_Internal_Note * pnote)
-{
- if (pnote->descsz > 0 && pnote->type == FDO_PACKAGING_METADATA)
- {
- printf (_(" Packaging Metadata: %.*s\n"), (int) pnote->descsz, pnote->descdata);
- return true;
- }
- if (pnote->descsz > 0 && pnote->type == FDO_DLOPEN_METADATA)
- {
- printf (_(" Dlopen Metadata: %.*s\n"), (int) pnote->descsz, pnote->descdata);
- return true;
- }
- return false;
-}
-
-static const char *
-get_ia64_vms_note_type (unsigned e_type)
-{
- static char buff[64];
-
- switch (e_type)
- {
- case NT_VMS_MHD:
- return _("NT_VMS_MHD (module header)");
- case NT_VMS_LNM:
- return _("NT_VMS_LNM (language name)");
- case NT_VMS_SRC:
- return _("NT_VMS_SRC (source files)");
- case NT_VMS_TITLE:
- return "NT_VMS_TITLE";
- case NT_VMS_EIDC:
- return _("NT_VMS_EIDC (consistency check)");
- case NT_VMS_FPMODE:
- return _("NT_VMS_FPMODE (FP mode)");
- case NT_VMS_LINKTIME:
- return "NT_VMS_LINKTIME";
- case NT_VMS_IMGNAM:
- return _("NT_VMS_IMGNAM (image name)");
- case NT_VMS_IMGID:
- return _("NT_VMS_IMGID (image id)");
- case NT_VMS_LINKID:
- return _("NT_VMS_LINKID (link id)");
- case NT_VMS_IMGBID:
- return _("NT_VMS_IMGBID (build id)");
- case NT_VMS_GSTNAM:
- return _("NT_VMS_GSTNAM (sym table name)");
- case NT_VMS_ORIG_DYN:
- return "NT_VMS_ORIG_DYN";
- case NT_VMS_PATCHTIME:
- return "NT_VMS_PATCHTIME";
- default:
- snprintf (buff, sizeof (buff), _("Unknown note type: (0x%08x)"), e_type);
- return buff;
- }
-}
-
-static bool
-print_ia64_vms_note (Elf_Internal_Note * pnote)
-{
- unsigned int maxlen = pnote->descsz;
-
- if (maxlen < 2 || maxlen != pnote->descsz)
- goto desc_size_fail;
-
- switch (pnote->type)
- {
- case NT_VMS_MHD:
- if (maxlen <= 36)
- goto desc_size_fail;
-
- size_t l = strnlen (pnote->descdata + 34, maxlen - 34);
-
- printf (_(" Creation date : %.17s\n"), pnote->descdata);
- printf (_(" Last patch date: %.17s\n"), pnote->descdata + 17);
- if (l + 34 < maxlen)
- {
- printf (_(" Module name : %s\n"), pnote->descdata + 34);
- if (l + 35 < maxlen)
- printf (_(" Module version : %s\n"), pnote->descdata + 34 + l + 1);
- else
- printf (_(" Module version : <missing>\n"));
- }
- else
- {
- printf (_(" Module name : <missing>\n"));
- printf (_(" Module version : <missing>\n"));
- }
- break;
-
- case NT_VMS_LNM:
- printf (_(" Language: %.*s\n"), maxlen, pnote->descdata);
- break;
-
- case NT_VMS_FPMODE:
- printf (_(" Floating Point mode: "));
- if (maxlen < 8)
- goto desc_size_fail;
- /* FIXME: Generate an error if descsz > 8 ? */
-
- printf ("0x%016" PRIx64 "\n",
- byte_get ((unsigned char *) pnote->descdata, 8));
- break;
-
- case NT_VMS_LINKTIME:
- printf (_(" Link time: "));
- if (maxlen < 8)
- goto desc_size_fail;
- /* FIXME: Generate an error if descsz > 8 ? */
-
- print_vms_time (byte_get ((unsigned char *) pnote->descdata, 8));
- printf ("\n");
- break;
-
- case NT_VMS_PATCHTIME:
- printf (_(" Patch time: "));
- if (maxlen < 8)
- goto desc_size_fail;
- /* FIXME: Generate an error if descsz > 8 ? */
-
- print_vms_time (byte_get ((unsigned char *) pnote->descdata, 8));
- printf ("\n");
- break;
-
- case NT_VMS_ORIG_DYN:
- if (maxlen < 34)
- goto desc_size_fail;
-
- printf (_(" Major id: %u, minor id: %u\n"),
- (unsigned) byte_get ((unsigned char *) pnote->descdata, 4),
- (unsigned) byte_get ((unsigned char *) pnote->descdata + 4, 4));
- printf (_(" Last modified : "));
- print_vms_time (byte_get ((unsigned char *) pnote->descdata + 8, 8));
- printf (_("\n Link flags : "));
- printf ("0x%016" PRIx64 "\n",
- byte_get ((unsigned char *) pnote->descdata + 16, 8));
- printf (_(" Header flags: 0x%08x\n"),
- (unsigned) byte_get ((unsigned char *) pnote->descdata + 24, 4));
- printf (_(" Image id : %.*s\n"), maxlen - 32, pnote->descdata + 32);
- break;
-
- case NT_VMS_IMGNAM:
- printf (_(" Image name: %.*s\n"), maxlen, pnote->descdata);
- break;
-
- case NT_VMS_GSTNAM:
- printf (_(" Global symbol table name: %.*s\n"), maxlen, pnote->descdata);
- break;
-
- case NT_VMS_IMGID:
- printf (_(" Image id: %.*s\n"), maxlen, pnote->descdata);
- break;
-
- case NT_VMS_LINKID:
- printf (_(" Linker id: %.*s\n"), maxlen, pnote->descdata);
- break;
-
- default:
- return false;
- }
-
- return true;
-
- desc_size_fail:
- printf (_(" <corrupt - data size is too small>\n"));
- error (_("corrupt IA64 note: data size is too small\n"));
- return false;
-}
-
-struct build_attr_cache {
- Filedata *filedata;
- char *strtab;
- uint64_t strtablen;
- Elf_Internal_Sym *symtab;
- uint64_t nsyms;
-} ba_cache;
-
-/* Find the symbol associated with a build attribute that is attached
- to address OFFSET. If PNAME is non-NULL then store the name of
- the symbol (if found) in the provided pointer, Returns NULL if a
- symbol could not be found. */
-
-static Elf_Internal_Sym *
-get_symbol_for_build_attribute (Filedata *filedata,
- uint64_t offset,
- bool is_open_attr,
- const char **pname)
-{
- Elf_Internal_Sym *saved_sym = NULL;
- Elf_Internal_Sym *sym;
-
- if (filedata->section_headers != NULL
- && (ba_cache.filedata == NULL || filedata != ba_cache.filedata))
- {
- Elf_Internal_Shdr * symsec;
-
- free (ba_cache.strtab);
- ba_cache.strtab = NULL;
- free (ba_cache.symtab);
- ba_cache.symtab = NULL;
-
- /* Load the symbol and string sections. */
- for (symsec = filedata->section_headers;
- symsec < filedata->section_headers + filedata->file_header.e_shnum;
- symsec ++)
- {
- if (symsec->sh_type == SHT_SYMTAB
- && get_symtab (filedata, symsec,
- &ba_cache.symtab, &ba_cache.nsyms,
- &ba_cache.strtab, &ba_cache.strtablen))
- break;
- }
- ba_cache.filedata = filedata;
- }
-
- if (ba_cache.symtab == NULL)
- return NULL;
-
- /* Find a symbol whose value matches offset. */
- for (sym = ba_cache.symtab; sym < ba_cache.symtab + ba_cache.nsyms; sym ++)
- if (sym->st_value == offset)
- {
- if (sym->st_name >= ba_cache.strtablen)
- /* Huh ? This should not happen. */
- continue;
-
- if (ba_cache.strtab[sym->st_name] == 0)
- continue;
-
- /* The AArch64, ARM and RISC-V architectures define mapping symbols
- (eg $d, $x, $t) which we want to ignore. */
- if (ba_cache.strtab[sym->st_name] == '$'
- && ba_cache.strtab[sym->st_name + 1] != 0
- && ba_cache.strtab[sym->st_name + 2] == 0)
- continue;
-
- if (is_open_attr)
- {
- /* For OPEN attributes we prefer GLOBAL over LOCAL symbols
- and FILE or OBJECT symbols over NOTYPE symbols. We skip
- FUNC symbols entirely. */
- switch (ELF_ST_TYPE (sym->st_info))
- {
- case STT_OBJECT:
- case STT_FILE:
- saved_sym = sym;
- if (sym->st_size)
- {
- /* If the symbol has a size associated
- with it then we can stop searching. */
- sym = ba_cache.symtab + ba_cache.nsyms;
- }
- continue;
-
- case STT_FUNC:
- /* Ignore function symbols. */
- continue;
-
- default:
- break;
- }
-
- switch (ELF_ST_BIND (sym->st_info))
- {
- case STB_GLOBAL:
- if (saved_sym == NULL
- || ELF_ST_TYPE (saved_sym->st_info) != STT_OBJECT)
- saved_sym = sym;
- break;
-
- case STB_LOCAL:
- if (saved_sym == NULL)
- saved_sym = sym;
- break;
-
- default:
- break;
- }
- }
- else
- {
- if (ELF_ST_TYPE (sym->st_info) != STT_FUNC)
- continue;
-
- saved_sym = sym;
- break;
- }
- }
-
- if (saved_sym && pname)
- * pname = ba_cache.strtab + saved_sym->st_name;
-
- return saved_sym;
-}
-
-/* Returns true iff addr1 and addr2 are in the same section. */
-
-static bool
-same_section (Filedata * filedata, uint64_t addr1, uint64_t addr2)
-{
- Elf_Internal_Shdr * a1;
- Elf_Internal_Shdr * a2;
-
- a1 = find_section_by_address (filedata, addr1);
- a2 = find_section_by_address (filedata, addr2);
-
- return a1 == a2 && a1 != NULL;
-}
-
-static bool
-print_gnu_build_attribute_description (Elf_Internal_Note * pnote,
- Filedata * filedata)
-{
- static uint64_t global_offset = 0;
- static uint64_t global_end = 0;
- static uint64_t func_offset = 0;
- static uint64_t func_end = 0;
-
- Elf_Internal_Sym *sym;
- const char *name;
- uint64_t start;
- uint64_t end;
- bool is_open_attr = pnote->type == NT_GNU_BUILD_ATTRIBUTE_OPEN;
-
- switch (pnote->descsz)
- {
- case 0:
- /* A zero-length description means that the range of
- the previous note of the same type should be used. */
- if (is_open_attr)
- {
- if (global_end > global_offset)
- printf (_(" Applies to region from %#" PRIx64
- " to %#" PRIx64 "\n"), global_offset, global_end);
- else
- printf (_(" Applies to region from %#" PRIx64
- "\n"), global_offset);
- }
- else
- {
- if (func_end > func_offset)
- printf (_(" Applies to region from %#" PRIx64
- " to %#" PRIx64 "\n"), func_offset, func_end);
- else
- printf (_(" Applies to region from %#" PRIx64
- "\n"), func_offset);
- }
- return true;
-
- case 4:
- start = byte_get ((unsigned char *) pnote->descdata, 4);
- end = 0;
- break;
-
- case 8:
- start = byte_get ((unsigned char *) pnote->descdata, 4);
- end = byte_get ((unsigned char *) pnote->descdata + 4, 4);
- break;
-
- case 16:
- start = byte_get ((unsigned char *) pnote->descdata, 8);
- end = byte_get ((unsigned char *) pnote->descdata + 8, 8);
- break;
-
- default:
- error (_(" <invalid description size: %lx>\n"), pnote->descsz);
- printf (_(" <invalid descsz>"));
- return false;
- }
-
- name = NULL;
- sym = get_symbol_for_build_attribute (filedata, start, is_open_attr, & name);
- /* As of version 5 of the annobin plugin, filename symbols are biased by 2
- in order to avoid them being confused with the start address of the
- first function in the file... */
- if (sym == NULL && is_open_attr)
- sym = get_symbol_for_build_attribute (filedata, start + 2, is_open_attr,
- & name);
-
- if (end == 0 && sym != NULL && sym->st_size > 0)
- end = start + sym->st_size;
-
- if (is_open_attr)
- {
- /* FIXME: Need to properly allow for section alignment.
- 16 is just the alignment used on x86_64. */
- if (global_end > 0
- && start > BFD_ALIGN (global_end, 16)
- /* Build notes are not guaranteed to be organised in order of
- increasing address, but we should find the all of the notes
- for one section in the same place. */
- && same_section (filedata, start, global_end))
- warn (_("Gap in build notes detected from %#" PRIx64
- " to %#" PRIx64 "\n"),
- global_end + 1, start - 1);
-
- printf (_(" Applies to region from %#" PRIx64), start);
- global_offset = start;
-
- if (end)
- {
- printf (_(" to %#" PRIx64), end);
- global_end = end;
- }
- }
- else
- {
- printf (_(" Applies to region from %#" PRIx64), start);
- func_offset = start;
-
- if (end)
- {
- printf (_(" to %#" PRIx64), end);
- func_end = end;
- }
- }
-
- if (sym && name)
- printf (_(" (%s)"), name);
-
- printf ("\n");
- return true;
-}
-
-static bool
-print_gnu_build_attribute_name (Elf_Internal_Note * pnote)
-{
- static const char string_expected [2] = { GNU_BUILD_ATTRIBUTE_TYPE_STRING, 0 };
- static const char number_expected [2] = { GNU_BUILD_ATTRIBUTE_TYPE_NUMERIC, 0 };
- static const char bool_expected [3] = { GNU_BUILD_ATTRIBUTE_TYPE_BOOL_TRUE, GNU_BUILD_ATTRIBUTE_TYPE_BOOL_FALSE, 0 };
- char name_type;
- char name_attribute;
- const char * expected_types;
- const char * name = pnote->namedata;
- const char * text;
- signed int left;
-
- if (name == NULL || pnote->namesz < 2)
- {
- error (_("corrupt name field in GNU build attribute note: size = %ld\n"), pnote->namesz);
- print_symbol_name (-20, _(" <corrupt name>"));
- return false;
- }
-
- if (do_wide)
- left = 28;
- else
- left = 20;
-
- /* Version 2 of the spec adds a "GA" prefix to the name field. */
- if (name[0] == 'G' && name[1] == 'A')
- {
- if (pnote->namesz < 4)
- {
- error (_("corrupt name field in GNU build attribute note: size = %ld\n"), pnote->namesz);
- print_symbol_name (-20, _(" <corrupt name>"));
- return false;
- }
-
- printf ("GA");
- name += 2;
- left -= 2;
- }
-
- switch ((name_type = * name))
- {
- case GNU_BUILD_ATTRIBUTE_TYPE_NUMERIC:
- case GNU_BUILD_ATTRIBUTE_TYPE_STRING:
- case GNU_BUILD_ATTRIBUTE_TYPE_BOOL_TRUE:
- case GNU_BUILD_ATTRIBUTE_TYPE_BOOL_FALSE:
- printf ("%c", * name);
- left --;
- break;
- default:
- error (_("unrecognised attribute type in name field: %d\n"), name_type);
- print_symbol_name (-20, _("<unknown name type>"));
- return false;
- }
-
- ++ name;
- text = NULL;
-
- switch ((name_attribute = * name))
- {
- case GNU_BUILD_ATTRIBUTE_VERSION:
- text = _("<version>");
- expected_types = string_expected;
- ++ name;
- break;
- case GNU_BUILD_ATTRIBUTE_STACK_PROT:
- text = _("<stack prot>");
- expected_types = "!+*";
- ++ name;
- break;
- case GNU_BUILD_ATTRIBUTE_RELRO:
- text = _("<relro>");
- expected_types = bool_expected;
- ++ name;
- break;
- case GNU_BUILD_ATTRIBUTE_STACK_SIZE:
- text = _("<stack size>");
- expected_types = number_expected;
- ++ name;
- break;
- case GNU_BUILD_ATTRIBUTE_TOOL:
- text = _("<tool>");
- expected_types = string_expected;
- ++ name;
- break;
- case GNU_BUILD_ATTRIBUTE_ABI:
- text = _("<ABI>");
- expected_types = "$*";
- ++ name;
- break;
- case GNU_BUILD_ATTRIBUTE_PIC:
- text = _("<PIC>");
- expected_types = number_expected;
- ++ name;
- break;
- case GNU_BUILD_ATTRIBUTE_SHORT_ENUM:
- text = _("<short enum>");
- expected_types = bool_expected;
- ++ name;
- break;
- default:
- if (ISPRINT (* name))
- {
- int len = strnlen (name, pnote->namesz - (name - pnote->namedata)) + 1;
-
- if (len > left && ! do_wide)
- len = left;
- printf ("%.*s:", len, name);
- left -= len;
- name += len;
- }
- else
- {
- static char tmpbuf [128];
-
- error (_("unrecognised byte in name field: %d\n"), * name);
- sprintf (tmpbuf, _("<unknown:_%d>"), * name);
- text = tmpbuf;
- name ++;
- }
- expected_types = "*$!+";
- break;
- }
-
- if (text)
- left -= printf ("%s", text);
-
- if (strchr (expected_types, name_type) == NULL)
- warn (_("attribute does not have an expected type (%c)\n"), name_type);
-
- if ((size_t) (name - pnote->namedata) > pnote->namesz)
- {
- error (_("corrupt name field: namesz: %lu but parsing gets to %td\n"),
- pnote->namesz,
- name - pnote->namedata);
- return false;
- }
-
- if (left < 1 && ! do_wide)
- return true;
-
- switch (name_type)
- {
- case GNU_BUILD_ATTRIBUTE_TYPE_NUMERIC:
- {
- unsigned int bytes;
- uint64_t val = 0;
- unsigned int shift = 0;
- char *decoded = NULL;
-
- bytes = pnote->namesz - (name - pnote->namedata);
- if (bytes > 0)
- /* The -1 is because the name field is always 0 terminated, and we
- want to be able to ensure that the shift in the while loop below
- will not overflow. */
- -- bytes;
-
- if (bytes > sizeof (val))
- {
- error (_("corrupt numeric name field: too many bytes in the value: %x\n"),
- bytes);
- bytes = sizeof (val);
- }
- /* We do not bother to warn if bytes == 0 as this can
- happen with some early versions of the gcc plugin. */
-
- while (bytes --)
- {
- uint64_t byte = *name++ & 0xff;
-
- val |= byte << shift;
- shift += 8;
- }
-
- switch (name_attribute)
- {
- case GNU_BUILD_ATTRIBUTE_PIC:
- switch (val)
- {
- case 0: decoded = "static"; break;
- case 1: decoded = "pic"; break;
- case 2: decoded = "PIC"; break;
- case 3: decoded = "pie"; break;
- case 4: decoded = "PIE"; break;
- default: break;
- }
- break;
- case GNU_BUILD_ATTRIBUTE_STACK_PROT:
- switch (val)
- {
- /* Based upon the SPCT_FLAG_xxx enum values in gcc/cfgexpand.c. */
- case 0: decoded = "off"; break;
- case 1: decoded = "on"; break;
- case 2: decoded = "all"; break;
- case 3: decoded = "strong"; break;
- case 4: decoded = "explicit"; break;
- default: break;
- }
- break;
- default:
- break;
- }
-
- if (decoded != NULL)
- {
- print_symbol_name (-left, decoded);
- left = 0;
- }
- else if (val == 0)
- {
- printf ("0x0");
- left -= 3;
- }
- else
- {
- if (do_wide)
- left -= printf ("0x%" PRIx64, val);
- else
- left -= printf ("0x%-.*" PRIx64, left, val);
- }
- }
- break;
- case GNU_BUILD_ATTRIBUTE_TYPE_STRING:
- left -= print_symbol_name (- left, name);
- break;
- case GNU_BUILD_ATTRIBUTE_TYPE_BOOL_TRUE:
- left -= print_symbol_name (- left, "true");
- break;
- case GNU_BUILD_ATTRIBUTE_TYPE_BOOL_FALSE:
- left -= print_symbol_name (- left, "false");
- break;
- }
-
- if (do_wide && left > 0)
- printf ("%-*s", left, " ");
-
- return true;
-}
-
-/* Print the contents of PNOTE as hex. */
-
-static void
-print_note_contents_hex (Elf_Internal_Note *pnote)
-{
- if (pnote->descsz)
- {
- size_t i;
-
- printf (_(" description data: "));
- for (i = 0; i < pnote->descsz; i++)
- printf ("%02x ", pnote->descdata[i] & 0xff);
- if (!do_wide)
- printf ("\n");
- }
-
- if (do_wide)
- printf ("\n");
-}
-
-#if defined HAVE_MSGPACK
-
-static void
-print_indents (int n)
-{
- printf (" ");
-
- for (int i = 0; i < n; i++)
- printf (" ");
-}
-
-/* Print OBJ in human-readable form. */
-
-static void
-dump_msgpack_obj (const msgpack_object *obj, int indent)
-{
- switch (obj->type)
- {
- case MSGPACK_OBJECT_NIL:
- printf ("(nil)");
- break;
-
- case MSGPACK_OBJECT_BOOLEAN:
- printf ("%s", obj->via.boolean ? "true" : "false");
- break;
-
- case MSGPACK_OBJECT_POSITIVE_INTEGER:
- printf ("%" PRIu64, obj->via.u64);
- break;
-
- case MSGPACK_OBJECT_NEGATIVE_INTEGER:
- printf ("%" PRIi64, obj->via.i64);
- break;
-
- case MSGPACK_OBJECT_FLOAT32:
- case MSGPACK_OBJECT_FLOAT64:
- printf ("%f", obj->via.f64);
- break;
-
- case MSGPACK_OBJECT_STR:
- printf ("\"%.*s\"", obj->via.str.size, obj->via.str.ptr);
- break;
-
- case MSGPACK_OBJECT_ARRAY:
- {
- const msgpack_object_array *array = &obj->via.array;
-
- printf ("[\n");
- ++indent;
-
- for (uint32_t i = 0; i < array->size; ++i)
- {
- const msgpack_object *item = &array->ptr[i];
-
- print_indents (indent);
- dump_msgpack_obj (item, indent);
- printf (",\n");
- }
-
- --indent;
- print_indents (indent);
- printf ("]");
- break;
- }
- break;
-
- case MSGPACK_OBJECT_MAP:
- {
- const msgpack_object_map *map = &obj->via.map;
-
- printf ("{\n");
- ++indent;
-
- for (uint32_t i = 0; i < map->size; ++i)
- {
- const msgpack_object_kv *kv = &map->ptr[i];
- const msgpack_object *key = &kv->key;
- const msgpack_object *val = &kv->val;
-
- print_indents (indent);
- dump_msgpack_obj (key, indent);
- printf (": ");
- dump_msgpack_obj (val, indent);
-
- printf (",\n");
- }
-
- --indent;
- print_indents (indent);
- printf ("}");
-
- break;
- }
-
- case MSGPACK_OBJECT_BIN:
- printf ("(bin)");
- break;
-
- case MSGPACK_OBJECT_EXT:
- printf ("(ext)");
- break;
- }
-}
-
-static void
-dump_msgpack (const msgpack_unpacked *msg)
-{
- print_indents (0);
- dump_msgpack_obj (&msg->data, 0);
- printf ("\n");
-}
-
-#endif /* defined HAVE_MSGPACK */
-
-static bool
-print_amdgpu_note (Elf_Internal_Note *pnote)
-{
-#if defined HAVE_MSGPACK
- /* If msgpack is available, decode and dump the note's content. */
- bool ret;
- msgpack_unpacked msg;
- msgpack_unpack_return msgpack_ret;
-
- assert (pnote->type == NT_AMDGPU_METADATA);
-
- msgpack_unpacked_init (&msg);
- msgpack_ret = msgpack_unpack_next (&msg, pnote->descdata, pnote->descsz,
- NULL);
-
- switch (msgpack_ret)
- {
- case MSGPACK_UNPACK_SUCCESS:
- dump_msgpack (&msg);
- ret = true;
- break;
-
- default:
- error (_("failed to unpack msgpack contents in NT_AMDGPU_METADATA note"));
- ret = false;
- break;
- }
-
- msgpack_unpacked_destroy (&msg);
- return ret;
-#else
- /* msgpack is not available, dump contents as hex. */
- print_note_contents_hex (pnote);
- return true;
-#endif
-}
-
-static bool
-print_qnx_note (Elf_Internal_Note *pnote)
-{
- switch (pnote->type)
- {
- case QNT_STACK:
- if (pnote->descsz != 12)
- goto desc_size_fail;
-
- printf (_(" Stack Size: 0x%" PRIx32 "\n"),
- (unsigned) byte_get ((unsigned char *) pnote->descdata, 4));
- printf (_(" Stack allocated: %" PRIx32 "\n"),
- (unsigned) byte_get ((unsigned char *) pnote->descdata + 4, 4));
- printf (_(" Executable: %s\n"),
- ((unsigned) byte_get ((unsigned char *) pnote->descdata + 8, 1)) ? "no": "yes");
- break;
-
- default:
- print_note_contents_hex(pnote);
- }
- return true;
-
-desc_size_fail:
- printf (_(" <corrupt - data size is too small>\n"));
- error (_("corrupt QNX note: data size is too small\n"));
- return false;
-}
-
-
-/* Note that by the ELF standard, the name field is already null byte
- terminated, and namesz includes the terminating null byte.
- I.E. the value of namesz for the name "FSF" is 4.
-
- If the value of namesz is zero, there is no name present. */
-
-static bool
-process_note (Elf_Internal_Note * pnote,
- Filedata * filedata)
-{
- const char * name = pnote->namesz ? pnote->namedata : "(NONE)";
- const char * nt;
-
- if (pnote->namesz == 0)
- /* If there is no note name, then use the default set of
- note type strings. */
- nt = get_note_type (filedata, pnote->type);
-
- else if (startswith (pnote->namedata, "GNU"))
- /* GNU-specific object file notes. */
- nt = get_gnu_elf_note_type (pnote->type);
-
- else if (startswith (pnote->namedata, "AMDGPU"))
- /* AMDGPU-specific object file notes. */
- nt = get_amdgpu_elf_note_type (pnote->type);
-
- else if (startswith (pnote->namedata, "FreeBSD"))
- /* FreeBSD-specific core file notes. */
- nt = get_freebsd_elfcore_note_type (filedata, pnote->type);
-
- else if (startswith (pnote->namedata, "NetBSD-CORE"))
- /* NetBSD-specific core file notes. */
- nt = get_netbsd_elfcore_note_type (filedata, pnote->type);
-
- else if (startswith (pnote->namedata, "NetBSD"))
- /* NetBSD-specific core file notes. */
- return process_netbsd_elf_note (pnote);
-
- else if (startswith (pnote->namedata, "PaX"))
- /* NetBSD-specific core file notes. */
- return process_netbsd_elf_note (pnote);
-
- else if (startswith (pnote->namedata, "OpenBSD"))
- /* OpenBSD-specific core file notes. */
- nt = get_openbsd_elfcore_note_type (filedata, pnote->type);
-
- else if (startswith (pnote->namedata, "QNX"))
- /* QNX-specific core file notes. */
- nt = get_qnx_elfcore_note_type (filedata, pnote->type);
-
- else if (startswith (pnote->namedata, "SPU/"))
- {
- /* SPU-specific core file notes. */
- nt = pnote->namedata + 4;
- name = "SPU";
- }
-
- else if (startswith (pnote->namedata, "IPF/VMS"))
- /* VMS/ia64-specific file notes. */
- nt = get_ia64_vms_note_type (pnote->type);
-
- else if (startswith (pnote->namedata, "stapsdt"))
- nt = get_stapsdt_note_type (pnote->type);
-
- else
- /* Don't recognize this note name; just use the default set of
- note type strings. */
- nt = get_note_type (filedata, pnote->type);
-
- printf (" ");
-
- if (((startswith (pnote->namedata, "GA")
- && strchr ("*$!+", pnote->namedata[2]) != NULL)
- || strchr ("*$!+", pnote->namedata[0]) != NULL)
- && (pnote->type == NT_GNU_BUILD_ATTRIBUTE_OPEN
- || pnote->type == NT_GNU_BUILD_ATTRIBUTE_FUNC))
- print_gnu_build_attribute_name (pnote);
- else
- print_symbol_name (-20, name);
-
- if (do_wide)
- printf (" 0x%08lx\t%s\t", pnote->descsz, nt);
- else
- printf (" 0x%08lx\t%s\n", pnote->descsz, nt);
-
- if (startswith (pnote->namedata, "IPF/VMS"))
- return print_ia64_vms_note (pnote);
- else if (startswith (pnote->namedata, "GNU"))
- return print_gnu_note (filedata, pnote);
- else if (startswith (pnote->namedata, "stapsdt"))
- return print_stapsdt_note (pnote);
- else if (startswith (pnote->namedata, "CORE"))
- return print_core_note (pnote);
- else if (startswith (pnote->namedata, "FDO"))
- return print_fdo_note (pnote);
- else if (((startswith (pnote->namedata, "GA")
- && strchr ("*$!+", pnote->namedata[2]) != NULL)
- || strchr ("*$!+", pnote->namedata[0]) != NULL)
- && (pnote->type == NT_GNU_BUILD_ATTRIBUTE_OPEN
- || pnote->type == NT_GNU_BUILD_ATTRIBUTE_FUNC))
- return print_gnu_build_attribute_description (pnote, filedata);
- else if (startswith (pnote->namedata, "AMDGPU")
- && pnote->type == NT_AMDGPU_METADATA)
- return print_amdgpu_note (pnote);
- else if (startswith (pnote->namedata, "QNX"))
- return print_qnx_note (pnote);
-
- print_note_contents_hex (pnote);
- return true;
-}
-
-static bool
-process_notes_at (Filedata * filedata,
- Elf_Internal_Shdr * section,
- uint64_t offset,
- uint64_t length,
- uint64_t align)
-{
- Elf_External_Note *pnotes;
- Elf_External_Note *external;
- char *end;
- bool res = true;
-
- if (length <= 0)
- return false;
-
- if (section)
- {
- pnotes = (Elf_External_Note *) get_section_contents (section, filedata);
- if (pnotes)
- {
- if (! apply_relocations (filedata, section, (unsigned char *) pnotes, length, NULL, NULL))
- {
- free (pnotes);
- return false;
- }
- }
- }
- else
- pnotes = (Elf_External_Note *) get_data (NULL, filedata, offset, 1, length,
- _("notes"));
-
- if (pnotes == NULL)
- return false;
-
- external = pnotes;
-
- if (filedata->is_separate)
- printf (_("In linked file '%s': "), filedata->file_name);
- else
- printf ("\n");
- if (section)
- printf (_("Displaying notes found in: %s\n"), printable_section_name (filedata, section));
- else
- printf (_("Displaying notes found at file offset 0x%08" PRIx64
- " with length 0x%08" PRIx64 ":\n"),
- offset, length);
-
- /* NB: Some note sections may have alignment value of 0 or 1. gABI
- specifies that notes should be aligned to 4 bytes in 32-bit
- objects and to 8 bytes in 64-bit objects. As a Linux extension,
- we also support 4 byte alignment in 64-bit objects. If section
- alignment is less than 4, we treate alignment as 4 bytes. */
- if (align < 4)
- align = 4;
- else if (align != 4 && align != 8)
- {
- warn (_("Corrupt note: alignment %" PRId64 ", expecting 4 or 8\n"),
- align);
- free (pnotes);
- return false;
- }
-
- printf (_(" %-20s %-10s\tDescription\n"), _("Owner"), _("Data size"));
-
- end = (char *) pnotes + length;
- while ((char *) external < end)
- {
- Elf_Internal_Note inote;
- size_t min_notesz;
- char * next;
- char * temp = NULL;
- size_t data_remaining = end - (char *) external;
-
- if (!is_ia64_vms (filedata))
- {
- /* PR binutils/15191
- Make sure that there is enough data to read. */
- min_notesz = offsetof (Elf_External_Note, name);
- if (data_remaining < min_notesz)
- {
- warn (ngettext ("Corrupt note: only %zd byte remains, "
- "not enough for a full note\n",
- "Corrupt note: only %zd bytes remain, "
- "not enough for a full note\n",
- data_remaining),
- data_remaining);
- break;
- }
- data_remaining -= min_notesz;
-
- inote.type = BYTE_GET (external->type);
- inote.namesz = BYTE_GET (external->namesz);
- inote.namedata = external->name;
- inote.descsz = BYTE_GET (external->descsz);
- inote.descdata = ((char *) external
- + ELF_NOTE_DESC_OFFSET (inote.namesz, align));
- inote.descpos = offset + (inote.descdata - (char *) pnotes);
- next = ((char *) external
- + ELF_NOTE_NEXT_OFFSET (inote.namesz, inote.descsz, align));
- }
- else
- {
- Elf64_External_VMS_Note *vms_external;
-
- /* PR binutils/15191
- Make sure that there is enough data to read. */
- min_notesz = offsetof (Elf64_External_VMS_Note, name);
- if (data_remaining < min_notesz)
- {
- warn (ngettext ("Corrupt note: only %zd byte remains, "
- "not enough for a full note\n",
- "Corrupt note: only %zd bytes remain, "
- "not enough for a full note\n",
- data_remaining),
- data_remaining);
- break;
- }
- data_remaining -= min_notesz;
-
- vms_external = (Elf64_External_VMS_Note *) external;
- inote.type = BYTE_GET (vms_external->type);
- inote.namesz = BYTE_GET (vms_external->namesz);
- inote.namedata = vms_external->name;
- inote.descsz = BYTE_GET (vms_external->descsz);
- inote.descdata = inote.namedata + align_power (inote.namesz, 3);
- inote.descpos = offset + (inote.descdata - (char *) pnotes);
- next = inote.descdata + align_power (inote.descsz, 3);
- }
-
- /* PR 17531: file: 3443835e. */
- /* PR 17531: file: id:000000,sig:11,src:006986,op:havoc,rep:4. */
- if ((size_t) (inote.descdata - inote.namedata) < inote.namesz
- || (size_t) (inote.descdata - inote.namedata) > data_remaining
- || (size_t) (next - inote.descdata) < inote.descsz
- || ((size_t) (next - inote.descdata)
- > data_remaining - (size_t) (inote.descdata - inote.namedata)))
- {
- warn (_("note with invalid namesz and/or descsz found at offset %#tx\n"),
- (char *) external - (char *) pnotes);
- warn (_(" type: %#lx, namesize: %#lx, descsize: %#lx, alignment: %u\n"),
- inote.type, inote.namesz, inote.descsz, (int) align);
- break;
- }
-
- external = (Elf_External_Note *) next;
-
- /* Verify that name is null terminated. It appears that at least
- one version of Linux (RedHat 6.0) generates corefiles that don't
- comply with the ELF spec by failing to include the null byte in
- namesz. */
- if (inote.namesz > 0 && inote.namedata[inote.namesz - 1] != '\0')
- {
- if ((size_t) (inote.descdata - inote.namedata) == inote.namesz)
- {
- temp = (char *) malloc (inote.namesz + 1);
- if (temp == NULL)
- {
- error (_("Out of memory allocating space for inote name\n"));
- res = false;
- break;
- }
-
- memcpy (temp, inote.namedata, inote.namesz);
- inote.namedata = temp;
- }
- inote.namedata[inote.namesz] = 0;
- }
-
- if (! process_note (& inote, filedata))
- res = false;
-
- free (temp);
- temp = NULL;
- }
-
- free (pnotes);
-
- return res;
-}
-
-static bool
-process_corefile_note_segments (Filedata * filedata)
-{
- Elf_Internal_Phdr *segment;
- unsigned int i;
- bool res = true;
-
- if (! get_program_headers (filedata))
- return true;
-
- for (i = 0, segment = filedata->program_headers;
- i < filedata->file_header.e_phnum;
- i++, segment++)
- {
- if (segment->p_type == PT_NOTE)
- if (! process_notes_at (filedata, NULL, segment->p_offset,
- segment->p_filesz, segment->p_align))
- res = false;
- }
-
- return res;
-}
-
-static bool
-process_v850_notes (Filedata * filedata, uint64_t offset, uint64_t length)
-{
- Elf_External_Note * pnotes;
- Elf_External_Note * external;
- char * end;
- bool res = true;
-
- if (length <= 0)
- return false;
-
- pnotes = (Elf_External_Note *) get_data (NULL, filedata, offset, 1, length,
- _("v850 notes"));
- if (pnotes == NULL)
- return false;
-
- external = pnotes;
- end = (char*) pnotes + length;
-
- printf (_("\nDisplaying contents of Renesas V850 notes section at offset"
- " %#" PRIx64 " with length %#" PRIx64 ":\n"),
- offset, length);
-
- while ((char *) external + sizeof (Elf_External_Note) < end)
- {
- Elf_External_Note * next;
- Elf_Internal_Note inote;
-
- inote.type = BYTE_GET (external->type);
- inote.namesz = BYTE_GET (external->namesz);
- inote.namedata = external->name;
- inote.descsz = BYTE_GET (external->descsz);
- inote.descdata = inote.namedata + align_power (inote.namesz, 2);
- inote.descpos = offset + (inote.descdata - (char *) pnotes);
-
- if (inote.descdata < (char *) pnotes || inote.descdata >= end)
- {
- warn (_("Corrupt note: name size is too big: %lx\n"), inote.namesz);
- inote.descdata = inote.namedata;
- inote.namesz = 0;
- }
-
- next = (Elf_External_Note *) (inote.descdata + align_power (inote.descsz, 2));
-
- if ( ((char *) next > end)
- || ((char *) next < (char *) pnotes))
- {
- warn (_("corrupt descsz found in note at offset %#tx\n"),
- (char *) external - (char *) pnotes);
- warn (_(" type: %#lx, namesize: %#lx, descsize: %#lx\n"),
- inote.type, inote.namesz, inote.descsz);
- break;
- }
-
- external = next;
-
- /* Prevent out-of-bounds indexing. */
- if ( inote.namedata + inote.namesz > end
- || inote.namedata + inote.namesz < inote.namedata)
- {
- warn (_("corrupt namesz found in note at offset %#zx\n"),
- (char *) external - (char *) pnotes);
- warn (_(" type: %#lx, namesize: %#lx, descsize: %#lx\n"),
- inote.type, inote.namesz, inote.descsz);
- break;
- }
-
- printf (" %s: ", get_v850_elf_note_type (inote.type));
-
- if (! print_v850_note (& inote))
- {
- res = false;
- printf ("<corrupt sizes: namesz: %#lx, descsz: %#lx>\n",
- inote.namesz, inote.descsz);
- }
- }
-
- free (pnotes);
-
- return res;
-}
-
-static bool
-process_note_sections (Filedata * filedata)
-{
- Elf_Internal_Shdr *section;
- size_t i;
- unsigned int n = 0;
- bool res = true;
-
- for (i = 0, section = filedata->section_headers;
- i < filedata->file_header.e_shnum && section != NULL;
- i++, section++)
- {
- if (section->sh_type == SHT_NOTE)
- {
- if (! process_notes_at (filedata, section, section->sh_offset,
- section->sh_size, section->sh_addralign))
- res = false;
- n++;
- }
-
- if (( filedata->file_header.e_machine == EM_V800
- || filedata->file_header.e_machine == EM_V850
- || filedata->file_header.e_machine == EM_CYGNUS_V850)
- && section->sh_type == SHT_RENESAS_INFO)
- {
- if (! process_v850_notes (filedata, section->sh_offset,
- section->sh_size))
- res = false;
- n++;
- }
- }
-
- if (n == 0)
- /* Try processing NOTE segments instead. */
- return process_corefile_note_segments (filedata);
-
- return res;
-}
-
-static bool
-process_notes (Filedata * filedata)
-{
- /* If we have not been asked to display the notes then do nothing. */
- if (! do_notes)
- return true;
-
- if (filedata->file_header.e_type != ET_CORE)
- return process_note_sections (filedata);
-
- /* No program headers means no NOTE segment. */
- if (filedata->file_header.e_phnum > 0)
- return process_corefile_note_segments (filedata);
-
- if (filedata->is_separate)
- printf (_("No notes found in linked file '%s'.\n"),
- filedata->file_name);
- else
- printf (_("No notes found file.\n"));
-
- return true;
-}
-
-static unsigned char *
-display_public_gnu_attributes (unsigned char * start,
- const unsigned char * const end)
-{
- printf (_(" Unknown GNU attribute: %s\n"), start);
-
- start += strnlen ((char *) start, end - start);
- display_raw_attribute (start, end);
-
- return (unsigned char *) end;
-}
-
-static unsigned char *
-display_generic_attribute (unsigned char * start,
- unsigned int tag,
- const unsigned char * const end)
-{
- if (tag == 0)
- return (unsigned char *) end;
-
- return display_tag_value (tag, start, end);
-}
-
-static bool
-process_arch_specific (Filedata * filedata)
-{
- if (! do_arch)
- return true;
-
- switch (filedata->file_header.e_machine)
- {
- case EM_ARC:
- case EM_ARC_COMPACT:
- case EM_ARC_COMPACT2:
- case EM_ARC_COMPACT3:
- case EM_ARC_COMPACT3_64:
- return process_attributes (filedata, "ARC", SHT_ARC_ATTRIBUTES,
- display_arc_attribute,
- display_generic_attribute);
- case EM_ARM:
- return process_attributes (filedata, "aeabi", SHT_ARM_ATTRIBUTES,
- display_arm_attribute,
- display_generic_attribute);
-
- case EM_MIPS:
- case EM_MIPS_RS3_LE:
- return process_mips_specific (filedata);
-
- case EM_MSP430:
- return process_attributes (filedata, "mspabi", SHT_MSP430_ATTRIBUTES,
- display_msp430_attribute,
- display_msp430_gnu_attribute);
-
- case EM_RISCV:
- return process_attributes (filedata, "riscv", SHT_RISCV_ATTRIBUTES,
- display_riscv_attribute,
- display_generic_attribute);
-
- case EM_NDS32:
- return process_nds32_specific (filedata);
-
- case EM_68K:
- return process_attributes (filedata, NULL, SHT_GNU_ATTRIBUTES, NULL,
- display_m68k_gnu_attribute);
-
- case EM_PPC:
- case EM_PPC64:
- return process_attributes (filedata, NULL, SHT_GNU_ATTRIBUTES, NULL,
- display_power_gnu_attribute);
-
- case EM_S390:
- case EM_S390_OLD:
- return process_attributes (filedata, NULL, SHT_GNU_ATTRIBUTES, NULL,
- display_s390_gnu_attribute);
-
- case EM_SPARC:
- case EM_SPARC32PLUS:
- case EM_SPARCV9:
- return process_attributes (filedata, NULL, SHT_GNU_ATTRIBUTES, NULL,
- display_sparc_gnu_attribute);
-
- case EM_TI_C6000:
- return process_attributes (filedata, "c6xabi", SHT_C6000_ATTRIBUTES,
- display_tic6x_attribute,
- display_generic_attribute);
-
- case EM_CSKY:
- return process_attributes (filedata, "csky", SHT_CSKY_ATTRIBUTES,
- display_csky_attribute, NULL);
-
- default:
- return process_attributes (filedata, "gnu", SHT_GNU_ATTRIBUTES,
- display_public_gnu_attributes,
- display_generic_attribute);
- }
-}
-
-static bool
-get_file_header (Filedata * filedata)
-{
- /* Read in the identity array. */
- if (fread (filedata->file_header.e_ident, EI_NIDENT, 1, filedata->handle) != 1)
- return false;
-
- /* Determine how to read the rest of the header. */
- switch (filedata->file_header.e_ident[EI_DATA])
- {
- default:
- case ELFDATANONE:
- case ELFDATA2LSB:
- byte_get = byte_get_little_endian;
- byte_put = byte_put_little_endian;
- break;
- case ELFDATA2MSB:
- byte_get = byte_get_big_endian;
- byte_put = byte_put_big_endian;
- break;
- }
-
- /* For now we only support 32 bit and 64 bit ELF files. */
- is_32bit_elf = (filedata->file_header.e_ident[EI_CLASS] != ELFCLASS64);
-
- /* Read in the rest of the header. */
- if (is_32bit_elf)
- {
- Elf32_External_Ehdr ehdr32;
-
- if (fread (ehdr32.e_type, sizeof (ehdr32) - EI_NIDENT, 1, filedata->handle) != 1)
- return false;
-
- filedata->file_header.e_type = BYTE_GET (ehdr32.e_type);
- filedata->file_header.e_machine = BYTE_GET (ehdr32.e_machine);
- filedata->file_header.e_version = BYTE_GET (ehdr32.e_version);
- filedata->file_header.e_entry = BYTE_GET (ehdr32.e_entry);
- filedata->file_header.e_phoff = BYTE_GET (ehdr32.e_phoff);
- filedata->file_header.e_shoff = BYTE_GET (ehdr32.e_shoff);
- filedata->file_header.e_flags = BYTE_GET (ehdr32.e_flags);
- filedata->file_header.e_ehsize = BYTE_GET (ehdr32.e_ehsize);
- filedata->file_header.e_phentsize = BYTE_GET (ehdr32.e_phentsize);
- filedata->file_header.e_phnum = BYTE_GET (ehdr32.e_phnum);
- filedata->file_header.e_shentsize = BYTE_GET (ehdr32.e_shentsize);
- filedata->file_header.e_shnum = BYTE_GET (ehdr32.e_shnum);
- filedata->file_header.e_shstrndx = BYTE_GET (ehdr32.e_shstrndx);
- }
- else
- {
- Elf64_External_Ehdr ehdr64;
-
- if (fread (ehdr64.e_type, sizeof (ehdr64) - EI_NIDENT, 1, filedata->handle) != 1)
- return false;
-
- filedata->file_header.e_type = BYTE_GET (ehdr64.e_type);
- filedata->file_header.e_machine = BYTE_GET (ehdr64.e_machine);
- filedata->file_header.e_version = BYTE_GET (ehdr64.e_version);
- filedata->file_header.e_entry = BYTE_GET (ehdr64.e_entry);
- filedata->file_header.e_phoff = BYTE_GET (ehdr64.e_phoff);
- filedata->file_header.e_shoff = BYTE_GET (ehdr64.e_shoff);
- filedata->file_header.e_flags = BYTE_GET (ehdr64.e_flags);
- filedata->file_header.e_ehsize = BYTE_GET (ehdr64.e_ehsize);
- filedata->file_header.e_phentsize = BYTE_GET (ehdr64.e_phentsize);
- filedata->file_header.e_phnum = BYTE_GET (ehdr64.e_phnum);
- filedata->file_header.e_shentsize = BYTE_GET (ehdr64.e_shentsize);
- filedata->file_header.e_shnum = BYTE_GET (ehdr64.e_shnum);
- filedata->file_header.e_shstrndx = BYTE_GET (ehdr64.e_shstrndx);
- }
-
- return true;
-}
-
-static void
-free_filedata (Filedata *filedata)
-{
- free (filedata->program_interpreter);
- free (filedata->program_headers);
- free (filedata->section_headers);
- free (filedata->string_table);
- free (filedata->dump.dump_sects);
- free (filedata->dynamic_strings);
- free (filedata->dynamic_symbols);
- free (filedata->dynamic_syminfo);
- free (filedata->dynamic_section);
-
- while (filedata->symtab_shndx_list != NULL)
- {
- elf_section_list *next = filedata->symtab_shndx_list->next;
- free (filedata->symtab_shndx_list);
- filedata->symtab_shndx_list = next;
- }
-
- free (filedata->section_headers_groups);
-
- if (filedata->section_groups)
- {
- size_t i;
- struct group_list * g;
- struct group_list * next;
-
- for (i = 0; i < filedata->group_count; i++)
- {
- for (g = filedata->section_groups [i].root; g != NULL; g = next)
- {
- next = g->next;
- free (g);
- }
- }
-
- free (filedata->section_groups);
- }
- memset (&filedata->section_headers, 0,
- sizeof (Filedata) - offsetof (Filedata, section_headers));
-}
-
-static void
-close_file (Filedata * filedata)
-{
- if (filedata)
- {
- if (filedata->handle)
- fclose (filedata->handle);
- free (filedata);
- }
-}
-
-void
-close_debug_file (void * data)
-{
- free_filedata ((Filedata *) data);
- close_file ((Filedata *) data);
-}
-
-static Filedata *
-open_file (const char * pathname, bool is_separate)
-{
- struct stat statbuf;
- Filedata * filedata = NULL;
-
- if (stat (pathname, & statbuf) < 0
- || ! S_ISREG (statbuf.st_mode))
- goto fail;
-
- filedata = calloc (1, sizeof * filedata);
- if (filedata == NULL)
- goto fail;
-
- filedata->handle = fopen (pathname, "rb");
- if (filedata->handle == NULL)
- goto fail;
-
- filedata->file_size = statbuf.st_size;
- filedata->file_name = pathname;
- filedata->is_separate = is_separate;
-
- if (! get_file_header (filedata))
- goto fail;
-
- if (!get_section_headers (filedata, false))
- goto fail;
-
- return filedata;
-
- fail:
- if (filedata)
- {
- if (filedata->handle)
- fclose (filedata->handle);
- free (filedata);
- }
- return NULL;
-}
-
-void *
-open_debug_file (const char * pathname)
-{
- return open_file (pathname, true);
-}
-
-static void
-initialise_dump_sects (Filedata * filedata)
-{
- /* Initialise the dump_sects array from the cmdline_dump_sects array.
- Note we do this even if cmdline_dump_sects is empty because we
- must make sure that the dump_sets array is zeroed out before each
- object file is processed. */
- if (filedata->dump.num_dump_sects > cmdline.num_dump_sects)
- memset (filedata->dump.dump_sects, 0,
- filedata->dump.num_dump_sects * sizeof (*filedata->dump.dump_sects));
-
- if (cmdline.num_dump_sects > 0)
- {
- if (filedata->dump.num_dump_sects == 0)
- /* A sneaky way of allocating the dump_sects array. */
- request_dump_bynumber (&filedata->dump, cmdline.num_dump_sects, 0);
-
- assert (filedata->dump.num_dump_sects >= cmdline.num_dump_sects);
- memcpy (filedata->dump.dump_sects, cmdline.dump_sects,
- cmdline.num_dump_sects * sizeof (*filedata->dump.dump_sects));
- }
-}
-
-static bool
-might_need_separate_debug_info (Filedata * filedata)
-{
- /* Debuginfo files do not need further separate file loading. */
- if (filedata->file_header.e_shstrndx == SHN_UNDEF)
- return false;
-
- /* Since do_follow_links might be enabled by default, only treat it as an
- indication that separate files should be loaded if setting it was a
- deliberate user action. */
- if (DEFAULT_FOR_FOLLOW_LINKS == 0 && do_follow_links)
- return true;
-
- if (process_links || do_syms || do_unwind
- || dump_any_debugging || do_dump || do_debugging)
- return true;
-
- return false;
-}
-
-/* Process one ELF object file according to the command line options.
- This file may actually be stored in an archive. The file is
- positioned at the start of the ELF object. Returns TRUE if no
- problems were encountered, FALSE otherwise. */
-
-static bool
-process_object (Filedata * filedata)
-{
- bool have_separate_files;
- unsigned int i;
- bool res;
-
- if (! get_file_header (filedata))
- {
- error (_("%s: Failed to read file header\n"), filedata->file_name);
- return false;
- }
-
- /* Initialise per file variables. */
- for (i = ARRAY_SIZE (filedata->version_info); i--;)
- filedata->version_info[i] = 0;
-
- for (i = ARRAY_SIZE (filedata->dynamic_info); i--;)
- filedata->dynamic_info[i] = 0;
- filedata->dynamic_info_DT_GNU_HASH = 0;
- filedata->dynamic_info_DT_MIPS_XHASH = 0;
-
- /* Process the file. */
- if (show_name)
- printf (_("\nFile: %s\n"), filedata->file_name);
-
- initialise_dump_sects (filedata);
-
- /* There may be some extensions in the first section header. Don't
- bomb if we can't read it. */
- get_section_headers (filedata, true);
-
- if (! process_file_header (filedata))
- {
- res = false;
- goto out;
- }
-
- /* Throw away the single section header read above, so that we
- re-read the entire set. */
- free (filedata->section_headers);
- filedata->section_headers = NULL;
-
- if (! process_section_headers (filedata))
- {
- /* Without loaded section headers we cannot process lots of things. */
- do_unwind = do_version = do_dump = do_arch = false;
-
- if (! do_using_dynamic)
- do_syms = do_dyn_syms = do_reloc = false;
- }
-
- if (! process_section_groups (filedata))
- /* Without loaded section groups we cannot process unwind. */
- do_unwind = false;
-
- process_program_headers (filedata);
-
- res = process_dynamic_section (filedata);
-
- if (! process_relocs (filedata))
- res = false;
-
- if (! process_unwind (filedata))
- res = false;
-
- if (! process_symbol_table (filedata))
- res = false;
-
- if (! process_lto_symbol_tables (filedata))
- res = false;
-
- if (! process_syminfo (filedata))
- res = false;
-
- if (! process_version_sections (filedata))
- res = false;
-
- if (might_need_separate_debug_info (filedata))
- have_separate_files = load_separate_debug_files (filedata, filedata->file_name);
- else
- have_separate_files = false;
-
- if (! process_section_contents (filedata))
- res = false;
-
- if (have_separate_files)
- {
- separate_info * d;
-
- for (d = first_separate_info; d != NULL; d = d->next)
- {
- initialise_dump_sects (d->handle);
-
- if (process_links && ! process_file_header (d->handle))
- res = false;
- else if (! process_section_headers (d->handle))
- res = false;
- else if (! process_section_contents (d->handle))
- res = false;
- else if (process_links)
- {
- if (! process_section_groups (d->handle))
- res = false;
- process_program_headers (d->handle);
- if (! process_dynamic_section (d->handle))
- res = false;
- if (! process_relocs (d->handle))
- res = false;
- if (! process_unwind (d->handle))
- res = false;
- if (! process_symbol_table (d->handle))
- res = false;
- if (! process_lto_symbol_tables (d->handle))
- res = false;
- if (! process_syminfo (d->handle))
- res = false;
- if (! process_version_sections (d->handle))
- res = false;
- if (! process_notes (d->handle))
- res = false;
- }
- }
-
- /* The file handles are closed by the call to free_debug_memory() below. */
- }
-
- if (! process_notes (filedata))
- res = false;
-
- if (! process_gnu_liblist (filedata))
- res = false;
-
- if (! process_arch_specific (filedata))
- res = false;
-
- out:
- free_filedata (filedata);
-
- free_debug_memory ();
-
- return res;
-}
-
-/* Process an ELF archive.
- On entry the file is positioned just after the ARMAG string.
- Returns TRUE upon success, FALSE otherwise. */
-
-static bool
-process_archive (Filedata * filedata, bool is_thin_archive)
-{
- struct archive_info arch;
- struct archive_info nested_arch;
- size_t got;
- bool ret = true;
-
- show_name = true;
-
- /* The ARCH structure is used to hold information about this archive. */
- arch.file_name = NULL;
- arch.file = NULL;
- arch.index_array = NULL;
- arch.sym_table = NULL;
- arch.longnames = NULL;
-
- /* The NESTED_ARCH structure is used as a single-item cache of information
- about a nested archive (when members of a thin archive reside within
- another regular archive file). */
- nested_arch.file_name = NULL;
- nested_arch.file = NULL;
- nested_arch.index_array = NULL;
- nested_arch.sym_table = NULL;
- nested_arch.longnames = NULL;
-
- if (setup_archive (&arch, filedata->file_name, filedata->handle,
- filedata->file_size, is_thin_archive,
- do_archive_index) != 0)
- {
- ret = false;
- goto out;
- }
-
- if (do_archive_index)
- {
- if (arch.sym_table == NULL)
- error (_("%s: unable to dump the index as none was found\n"),
- filedata->file_name);
- else
- {
- uint64_t i, l;
- uint64_t current_pos;
-
- printf (_("Index of archive %s: (%" PRIu64 " entries,"
- " %#" PRIx64 " bytes in the symbol table)\n"),
- filedata->file_name, arch.index_num,
- arch.sym_size);
-
- current_pos = ftell (filedata->handle);
-
- for (i = l = 0; i < arch.index_num; i++)
- {
- if (i == 0
- || (i > 0 && arch.index_array[i] != arch.index_array[i - 1]))
- {
- char * member_name
- = get_archive_member_name_at (&arch, arch.index_array[i],
- &nested_arch);
-
- if (member_name != NULL)
- {
- char * qualified_name
- = make_qualified_name (&arch, &nested_arch,
- member_name);
-
- if (qualified_name != NULL)
- {
- printf (_("Contents of binary %s at offset "),
- qualified_name);
- (void) print_vma (arch.index_array[i], PREFIX_HEX);
- putchar ('\n');
- free (qualified_name);
- }
- free (member_name);
- }
- }
-
- if (l >= arch.sym_size)
- {
- error (_("%s: end of the symbol table reached "
- "before the end of the index\n"),
- filedata->file_name);
- ret = false;
- break;
- }
- /* PR 17531: file: 0b6630b2. */
- printf ("\t%.*s\n",
- (int) (arch.sym_size - l), arch.sym_table + l);
- l += strnlen (arch.sym_table + l, arch.sym_size - l) + 1;
- }
-
- if (arch.uses_64bit_indices)
- l = (l + 7) & ~ 7;
- else
- l += l & 1;
-
- if (l < arch.sym_size)
- {
- error (ngettext ("%s: %" PRId64 " byte remains in the symbol table, "
- "but without corresponding entries in "
- "the index table\n",
- "%s: %" PRId64 " bytes remain in the symbol table, "
- "but without corresponding entries in "
- "the index table\n",
- arch.sym_size - l),
- filedata->file_name, arch.sym_size - l);
- ret = false;
- }
-
- if (fseek64 (filedata->handle, current_pos, SEEK_SET) != 0)
- {
- error (_("%s: failed to seek back to start of object files "
- "in the archive\n"),
- filedata->file_name);
- ret = false;
- goto out;
- }
- }
-
- if (!do_dynamic && !do_syms && !do_reloc && !do_unwind && !do_sections
- && !do_segments && !do_header && !do_dump && !do_version
- && !do_histogram && !do_debugging && !do_arch && !do_notes
- && !do_section_groups && !do_dyn_syms)
- {
- ret = true; /* Archive index only. */
- goto out;
- }
- }
-
- while (1)
- {
- char * name;
- size_t namelen;
- char * qualified_name;
-
- /* Read the next archive header. */
- if (fseek64 (filedata->handle, arch.next_arhdr_offset, SEEK_SET) != 0)
- {
- error (_("%s: failed to seek to next archive header\n"),
- arch.file_name);
- ret = false;
- break;
- }
- got = fread (&arch.arhdr, 1, sizeof arch.arhdr, filedata->handle);
- if (got != sizeof arch.arhdr)
- {
- if (got == 0)
- break;
- /* PR 24049 - we cannot use filedata->file_name as this will
- have already been freed. */
- error (_("%s: failed to read archive header\n"), arch.file_name);
-
- ret = false;
- break;
- }
- if (memcmp (arch.arhdr.ar_fmag, ARFMAG, 2) != 0)
- {
- error (_("%s: did not find a valid archive header\n"),
- arch.file_name);
- ret = false;
- break;
- }
-
- arch.next_arhdr_offset += sizeof arch.arhdr;
-
- filedata->archive_file_size = strtoul (arch.arhdr.ar_size, NULL, 10);
-
- name = get_archive_member_name (&arch, &nested_arch);
- if (name == NULL)
- {
- error (_("%s: bad archive file name\n"), arch.file_name);
- ret = false;
- break;
- }
- namelen = strlen (name);
-
- qualified_name = make_qualified_name (&arch, &nested_arch, name);
- if (qualified_name == NULL)
- {
- error (_("%s: bad archive file name\n"), arch.file_name);
- free (name);
- ret = false;
- break;
- }
-
- if (is_thin_archive && arch.nested_member_origin == 0)
- {
- /* This is a proxy for an external member of a thin archive. */
- Filedata * member_filedata;
- char * member_file_name = adjust_relative_path
- (filedata->file_name, name, namelen);
-
- free (name);
- if (member_file_name == NULL)
- {
- free (qualified_name);
- ret = false;
- break;
- }
-
- member_filedata = open_file (member_file_name, false);
- if (member_filedata == NULL)
- {
- error (_("Input file '%s' is not readable.\n"), member_file_name);
- free (member_file_name);
- free (qualified_name);
- ret = false;
- break;
- }
-
- filedata->archive_file_offset = arch.nested_member_origin;
- member_filedata->file_name = qualified_name;
-
- /* The call to process_object() expects the file to be at the beginning. */
- rewind (member_filedata->handle);
-
- if (! process_object (member_filedata))
- ret = false;
-
- close_file (member_filedata);
- free (member_file_name);
- }
- else if (is_thin_archive)
- {
- Filedata thin_filedata;
-
- memset (&thin_filedata, 0, sizeof (thin_filedata));
-
- /* PR 15140: Allow for corrupt thin archives. */
- if (nested_arch.file == NULL)
- {
- error (_("%s: contains corrupt thin archive: %s\n"),
- qualified_name, name);
- free (qualified_name);
- free (name);
- ret = false;
- break;
- }
- free (name);
-
- /* This is a proxy for a member of a nested archive. */
- filedata->archive_file_offset
- = arch.nested_member_origin + sizeof arch.arhdr;
-
- /* The nested archive file will have been opened and setup by
- get_archive_member_name. */
- if (fseek64 (nested_arch.file, filedata->archive_file_offset,
- SEEK_SET) != 0)
- {
- error (_("%s: failed to seek to archive member.\n"),
- nested_arch.file_name);
- free (qualified_name);
- ret = false;
- break;
- }
-
- thin_filedata.handle = nested_arch.file;
- thin_filedata.file_name = qualified_name;
-
- if (! process_object (& thin_filedata))
- ret = false;
- }
- else
- {
- free (name);
- filedata->archive_file_offset = arch.next_arhdr_offset;
- filedata->file_name = qualified_name;
- if (! process_object (filedata))
- ret = false;
- arch.next_arhdr_offset += (filedata->archive_file_size + 1) & -2;
- /* Stop looping with "negative" archive_file_size. */
- if (arch.next_arhdr_offset < filedata->archive_file_size)
- arch.next_arhdr_offset = -1ul;
- }
-
- free (qualified_name);
- }
-
- out:
- if (nested_arch.file != NULL)
- fclose (nested_arch.file);
- release_archive (&nested_arch);
- release_archive (&arch);
-
- return ret;
-}
-
-static bool
-process_file (char * file_name)
-{
- Filedata * filedata = NULL;
- struct stat statbuf;
- char armag[SARMAG];
- bool ret = false;
- char * name;
- char * saved_program_name;
-
- /* Overload program_name to include file_name. Doing this means
- that warning/error messages will positively identify the file
- concerned even when multiple instances of readelf are running. */
- name = xmalloc (strlen (program_name) + strlen (file_name) + 3);
- sprintf (name, "%s: %s", program_name, file_name);
- saved_program_name = program_name;
- program_name = name;
-
- if (stat (file_name, &statbuf) < 0)
- {
- if (errno == ENOENT)
- error (_("No such file\n"));
- else
- error (_("Could not locate file. System error message: %s\n"),
- strerror (errno));
- goto done;
- }
-
- if (! S_ISREG (statbuf.st_mode))
- {
- error (_("Not an ordinary file\n"));
- goto done;
- }
-
- filedata = calloc (1, sizeof * filedata);
- if (filedata == NULL)
- {
- error (_("Out of memory allocating file data structure\n"));
- goto done;
- }
-
- filedata->file_name = file_name;
- filedata->handle = fopen (file_name, "rb");
- if (filedata->handle == NULL)
- {
- error (_("Not readable\n"));
- goto done;
- }
-
- if (fread (armag, SARMAG, 1, filedata->handle) != 1)
- {
- error (_("Failed to read file's magic number\n"));
- goto done;
- }
-
- filedata->file_size = statbuf.st_size;
- filedata->is_separate = false;
-
- if (memcmp (armag, ARMAG, SARMAG) == 0)
- {
- if (process_archive (filedata, false))
- ret = true;
- }
- else if (memcmp (armag, ARMAGT, SARMAG) == 0)
- {
- if (process_archive (filedata, true))
- ret = true;
- }
- else
- {
- if (do_archive_index && !check_all)
- error (_("Not an archive so its index cannot be displayed.\n"));
-
- rewind (filedata->handle);
- filedata->archive_file_size = filedata->archive_file_offset = 0;
-
- if (process_object (filedata))
- ret = true;
- }
-
- done:
- if (filedata)
- {
- if (filedata->handle != NULL)
- fclose (filedata->handle);
- free (filedata->section_headers);
- free (filedata->program_headers);
- free (filedata->string_table);
- free (filedata->dump.dump_sects);
- free (filedata);
- }
- free (program_name);
- program_name = saved_program_name;
-
- free (ba_cache.strtab);
- ba_cache.strtab = NULL;
- free (ba_cache.symtab);
- ba_cache.symtab = NULL;
- ba_cache.filedata = NULL;
-
- return ret;
-}
-
-#ifdef SUPPORT_DISASSEMBLY
-/* Needed by the i386 disassembler. For extra credit, someone could
- fix this so that we insert symbolic addresses here, esp for GOT/PLT
- symbols. */
-
-void
-print_address (unsigned int addr, FILE * outfile)
-{
- fprintf (outfile,"0x%8.8x", addr);
-}
-
-/* Needed by the i386 disassembler. */
-
-void
-db_task_printsym (unsigned int addr)
-{
- print_address (addr, stderr);
-}
-#endif
-
-int
-main (int argc, char ** argv)
-{
- int err;
-
-#ifdef HAVE_LC_MESSAGES
- setlocale (LC_MESSAGES, "");
-#endif
- setlocale (LC_CTYPE, "");
- bindtextdomain (PACKAGE, LOCALEDIR);
- textdomain (PACKAGE);
-
- expandargv (&argc, &argv);
-
- parse_args (& cmdline, argc, argv);
-
- if (optind < (argc - 1))
- /* When displaying information for more than one file,
- prefix the information with the file name. */
- show_name = true;
- else if (optind >= argc)
- {
- /* Ensure that the warning is always displayed. */
- do_checks = true;
-
- warn (_("Nothing to do.\n"));
- usage (stderr);
- }
-
- err = false;
- while (optind < argc)
- if (! process_file (argv[optind++]))
- err = true;
-
- free (cmdline.dump_sects);
-
- free (dump_ctf_symtab_name);
- free (dump_ctf_strtab_name);
- free (dump_ctf_parent_name);
-
- return err ? EXIT_FAILURE : EXIT_SUCCESS;
-}
Index: sources/GNU/binutils/create-2.43.1-ldforcele-patch/file.list
===================================================================
--- sources/GNU/binutils/create-2.43.1-ldforcele-patch/file.list (revision 75)
+++ sources/GNU/binutils/create-2.43.1-ldforcele-patch/file.list (nonexistent)
@@ -1,2 +0,0 @@
-binutils-2.43.1/ld/ldlang.c
-binutils-2.43.1/ld/ldmain.c
Index: sources/GNU/binutils/create-2.43.1-ldforcele-patch/create.patch.sh
===================================================================
--- sources/GNU/binutils/create-2.43.1-ldforcele-patch/create.patch.sh (revision 75)
+++ sources/GNU/binutils/create-2.43.1-ldforcele-patch/create.patch.sh (nonexistent)
@@ -1,15 +0,0 @@
-#!/bin/bash
-
-VERSION=2.43.1
-
-tar --files-from=file.list -xJvf ../binutils-$VERSION.tar.xz
-mv binutils-$VERSION binutils-$VERSION-orig
-
-cp -rf ./binutils-$VERSION-new ./binutils-$VERSION
-
-diff --unified -Nr binutils-$VERSION-orig binutils-$VERSION > binutils-$VERSION-ldforcele.patch
-
-mv binutils-$VERSION-ldforcele.patch ../patches
-
-rm -rf ./binutils-$VERSION
-rm -rf ./binutils-$VERSION-orig
Property changes on: sources/GNU/binutils/create-2.43.1-ldforcele-patch/create.patch.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: sources/GNU/binutils/create-2.43.1-ldforcele-patch/binutils-2.43.1-new/ld/ldmain.c
===================================================================
--- sources/GNU/binutils/create-2.43.1-ldforcele-patch/binutils-2.43.1-new/ld/ldmain.c (revision 75)
+++ sources/GNU/binutils/create-2.43.1-ldforcele-patch/binutils-2.43.1-new/ld/ldmain.c (nonexistent)
@@ -1,1707 +0,0 @@
-/* Main program of GNU linker.
- Copyright (C) 1991-2024 Free Software Foundation, Inc.
- Written by Steve Chamberlain steve@cygnus.com
-
- This file is part of the GNU Binutils.
-
- This program is free software; you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation; either version 3 of the License, or
- (at your option) any later version.
-
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program; if not, write to the Free Software
- Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston,
- MA 02110-1301, USA. */
-
-#include "sysdep.h"
-#include "bfd.h"
-#include "safe-ctype.h"
-#include "libiberty.h"
-#include "bfdlink.h"
-#include "ctf-api.h"
-#include "filenames.h"
-#include "elf/common.h"
-
-#include "ld.h"
-#include "ldmain.h"
-#include "ldmisc.h"
-#include "ldwrite.h"
-#include "ldexp.h"
-#include "ldlang.h"
-#include <ldgram.h>
-#include "ldlex.h"
-#include "ldfile.h"
-#include "ldemul.h"
-#include "ldctor.h"
-#if BFD_SUPPORTS_PLUGINS
-#include "plugin.h"
-#include "plugin-api.h"
-#endif /* BFD_SUPPORTS_PLUGINS */
-
-/* Somewhere above, sys/stat.h got included. */
-#if !defined(S_ISDIR) && defined(S_IFDIR)
-#define S_ISDIR(m) (((m) & S_IFMT) == S_IFDIR)
-#endif
-
-#include <string.h>
-
-#ifndef TARGET_SYSTEM_ROOT
-#define TARGET_SYSTEM_ROOT ""
-#endif
-
-/* EXPORTS */
-
-FILE *saved_script_handle = NULL;
-FILE *previous_script_handle = NULL;
-bool force_make_executable = false;
-
-char *default_target;
-const char *output_filename = "a.out";
-
-/* Name this program was invoked by. */
-char *program_name;
-
-/* The prefix for system library directories. */
-const char *ld_sysroot;
-
-/* The canonical representation of ld_sysroot. */
-char *ld_canon_sysroot;
-int ld_canon_sysroot_len;
-
-/* Set by -G argument, for targets like MIPS ELF. */
-int g_switch_value = 8;
-
-/* Nonzero means print names of input files as processed. */
-unsigned int trace_files;
-
-/* Nonzero means report actions taken by the linker, and describe the linker script in use. */
-bool verbose;
-
-/* Nonzero means version number was printed, so exit successfully
- instead of complaining if no input files are given. */
-bool version_printed;
-
-/* TRUE if we should demangle symbol names. */
-bool demangling;
-
-bool in_section_ordering;
-
-args_type command_line;
-
-ld_config_type config;
-
-sort_type sort_section;
-
-static const char *get_sysroot
- (int, char **);
-static char *get_emulation
- (int, char **);
-static bool add_archive_element
- (struct bfd_link_info *, bfd *, const char *, bfd **);
-static void multiple_definition
- (struct bfd_link_info *, struct bfd_link_hash_entry *,
- bfd *, asection *, bfd_vma);
-static void multiple_common
- (struct bfd_link_info *, struct bfd_link_hash_entry *,
- bfd *, enum bfd_link_hash_type, bfd_vma);
-static void add_to_set
- (struct bfd_link_info *, struct bfd_link_hash_entry *,
- bfd_reloc_code_real_type, bfd *, asection *, bfd_vma);
-static void constructor_callback
- (struct bfd_link_info *, bool, const char *, bfd *,
- asection *, bfd_vma);
-static void warning_callback
- (struct bfd_link_info *, const char *, const char *, bfd *,
- asection *, bfd_vma);
-static void warning_find_reloc
- (bfd *, asection *, void *);
-static void undefined_symbol
- (struct bfd_link_info *, const char *, bfd *, asection *, bfd_vma,
- bool);
-static void reloc_overflow
- (struct bfd_link_info *, struct bfd_link_hash_entry *, const char *,
- const char *, bfd_vma, bfd *, asection *, bfd_vma);
-static void reloc_dangerous
- (struct bfd_link_info *, const char *, bfd *, asection *, bfd_vma);
-static void unattached_reloc
- (struct bfd_link_info *, const char *, bfd *, asection *, bfd_vma);
-static bool notice
- (struct bfd_link_info *, struct bfd_link_hash_entry *,
- struct bfd_link_hash_entry *, bfd *, asection *, bfd_vma, flagword);
-
-static struct bfd_link_callbacks link_callbacks =
-{
- add_archive_element,
- multiple_definition,
- multiple_common,
- add_to_set,
- constructor_callback,
- warning_callback,
- undefined_symbol,
- reloc_overflow,
- reloc_dangerous,
- unattached_reloc,
- notice,
- einfo,
- info_msg,
- minfo,
- ldlang_override_segment_assignment,
- ldlang_ctf_acquire_strings,
- NULL,
- ldlang_ctf_new_dynsym,
- ldlang_write_ctf_late
-};
-
-static bfd_assert_handler_type default_bfd_assert_handler;
-static bfd_error_handler_type default_bfd_error_handler;
-
-struct bfd_link_info link_info;
-
-struct dependency_file
-{
- struct dependency_file *next;
- char *name;
-};
-
-static struct dependency_file *dependency_files, *dependency_files_tail;
-
-void
-track_dependency_files (const char *filename)
-{
- struct dependency_file *dep
- = (struct dependency_file *) xmalloc (sizeof (*dep));
- dep->name = xstrdup (filename);
- dep->next = NULL;
- if (dependency_files == NULL)
- dependency_files = dep;
- else
- dependency_files_tail->next = dep;
- dependency_files_tail = dep;
-}
-
-static void
-write_dependency_file (void)
-{
- FILE *out;
- struct dependency_file *dep;
-
- out = fopen (config.dependency_file, FOPEN_WT);
- if (out == NULL)
- {
- einfo (_("%F%P: cannot open dependency file %s: %E\n"),
- config.dependency_file);
- }
-
- fprintf (out, "%s:", output_filename);
-
- for (dep = dependency_files; dep != NULL; dep = dep->next)
- fprintf (out, " \\\n %s", dep->name);
-
- fprintf (out, "\n");
- for (dep = dependency_files; dep != NULL; dep = dep->next)
- fprintf (out, "\n%s:\n", dep->name);
-
- fclose (out);
-}
-
-static void
-ld_cleanup (void)
-{
- bfd *ibfd, *inext;
- if (link_info.output_bfd)
- bfd_close_all_done (link_info.output_bfd);
- for (ibfd = link_info.input_bfds; ibfd; ibfd = inext)
- {
- inext = ibfd->link.next;
- bfd_close_all_done (ibfd);
- }
-#if BFD_SUPPORTS_PLUGINS
- plugin_call_cleanup ();
-#endif
- if (output_filename && delete_output_file_on_failure)
- unlink_if_ordinary (output_filename);
-}
-
-/* Hook to notice BFD assertions. */
-
-static void
-ld_bfd_assert_handler (const char *fmt, const char *bfdver,
- const char *file, int line)
-{
- config.make_executable = false;
- (*default_bfd_assert_handler) (fmt, bfdver, file, line);
-}
-
-/* Hook the bfd error/warning handler for --fatal-warnings. */
-
-static void
-ld_bfd_error_handler (const char *fmt, va_list ap)
-{
- if (config.fatal_warnings)
- config.make_executable = false;
- (*default_bfd_error_handler) (fmt, ap);
-}
-
-static void
-display_external_script (void)
-{
- if (saved_script_handle == NULL)
- return;
-
- static const int ld_bufsz = 8193;
- size_t n;
- char *buf = (char *) xmalloc (ld_bufsz);
-
- rewind (saved_script_handle);
- while ((n = fread (buf, 1, ld_bufsz - 1, saved_script_handle)) > 0)
- {
- buf[n] = 0;
- info_msg ("%s", buf);
- }
- rewind (saved_script_handle);
- free (buf);
-}
-
-int
-main (int argc, char **argv)
-{
- char *emulation;
- long start_time = get_run_time ();
-
-#ifdef HAVE_LC_MESSAGES
- setlocale (LC_MESSAGES, "");
-#endif
- setlocale (LC_CTYPE, "");
- bindtextdomain (PACKAGE, LOCALEDIR);
- textdomain (PACKAGE);
-
- program_name = argv[0];
- xmalloc_set_program_name (program_name);
-
- expandargv (&argc, &argv);
-
- if (bfd_init () != BFD_INIT_MAGIC)
- einfo (_("%F%P: fatal error: libbfd ABI mismatch\n"));
-
- bfd_set_error_program_name (program_name);
-
- /* We want to notice and fail on those nasty BFD assertions which are
- likely to signal incorrect output being generated but otherwise may
- leave no trace. */
- default_bfd_assert_handler = bfd_set_assert_handler (ld_bfd_assert_handler);
-
- /* Also hook the bfd error/warning handler for --fatal-warnings. */
- default_bfd_error_handler = bfd_set_error_handler (ld_bfd_error_handler);
-
- xatexit (ld_cleanup);
-
- /* Set up the sysroot directory. */
- ld_sysroot = get_sysroot (argc, argv);
- if (*ld_sysroot)
- ld_canon_sysroot = lrealpath (ld_sysroot);
- if (ld_canon_sysroot)
- {
- ld_canon_sysroot_len = strlen (ld_canon_sysroot);
-
- /* is_sysrooted_pathname() relies on no trailing dirsep. */
- if (ld_canon_sysroot_len > 0
- && IS_DIR_SEPARATOR (ld_canon_sysroot [ld_canon_sysroot_len - 1]))
- ld_canon_sysroot [--ld_canon_sysroot_len] = '\0';
- }
- else
- ld_canon_sysroot_len = -1;
-
- /* Set the default BFD target based on the configured target. Doing
- this permits the linker to be configured for a particular target,
- and linked against a shared BFD library which was configured for
- a different target. The macro TARGET is defined by Makefile. */
- if (!bfd_set_default_target (TARGET))
- {
- einfo (_("%X%P: can't set BFD default target to `%s': %E\n"), TARGET);
- xexit (1);
- }
-
-#if YYDEBUG
- {
- extern int yydebug;
- yydebug = 1;
- }
-#endif
-
- config.build_constructors = true;
- config.rpath_separator = ':';
- config.split_by_reloc = (unsigned) -1;
- config.split_by_file = (bfd_size_type) -1;
- config.make_executable = true;
- config.magic_demand_paged = true;
- config.text_read_only = true;
- config.print_map_discarded = true;
- link_info.disable_target_specific_optimizations = -1;
-
- command_line.warn_mismatch = true;
- command_line.warn_search_mismatch = true;
- command_line.check_section_addresses = -1;
-
- /* We initialize DEMANGLING based on the environment variable
- COLLECT_NO_DEMANGLE. The gcc collect2 program will demangle the
- output of the linker, unless COLLECT_NO_DEMANGLE is set in the
- environment. Acting the same way here lets us provide the same
- interface by default. */
- demangling = getenv ("COLLECT_NO_DEMANGLE") == NULL;
-
- link_info.allow_undefined_version = true;
- link_info.keep_memory = true;
- link_info.max_cache_size = (bfd_size_type) -1;
- link_info.combreloc = true;
- link_info.strip_discarded = true;
- link_info.prohibit_multiple_definition_absolute = false;
- link_info.textrel_check = DEFAULT_LD_TEXTREL_CHECK;
- link_info.emit_hash = DEFAULT_EMIT_SYSV_HASH;
- link_info.emit_gnu_hash = DEFAULT_EMIT_GNU_HASH;
- link_info.callbacks = &link_callbacks;
- link_info.input_bfds_tail = &link_info.input_bfds;
- /* SVR4 linkers seem to set DT_INIT and DT_FINI based on magic _init
- and _fini symbols. We are compatible. */
- link_info.init_function = "_init";
- link_info.fini_function = "_fini";
- link_info.relax_pass = 1;
- link_info.extern_protected_data = -1;
- link_info.dynamic_undefined_weak = -1;
- link_info.indirect_extern_access = -1;
- link_info.pei386_auto_import = -1;
- link_info.spare_dynamic_tags = 5;
- link_info.path_separator = ':';
-#ifdef DEFAULT_FLAG_COMPRESS_DEBUG
- config.compress_debug = DEFAULT_COMPRESSED_DEBUG_ALGORITHM;
-#endif
-#ifdef DEFAULT_NEW_DTAGS
- link_info.new_dtags = DEFAULT_NEW_DTAGS;
-#endif
- link_info.start_stop_gc = false;
- link_info.start_stop_visibility = STV_PROTECTED;
-
- ldfile_add_arch ("");
- emulation = get_emulation (argc, argv);
- ldemul_choose_mode (emulation);
- default_target = ldemul_choose_target (argc, argv);
- lang_init ();
- ldexp_init ();
- ldemul_before_parse ();
- lang_has_input_file = false;
- parse_args (argc, argv);
-
- if (config.hash_table_size != 0)
- bfd_hash_set_default_size (config.hash_table_size);
-
-#if BFD_SUPPORTS_PLUGINS
- /* Now all the plugin arguments have been gathered, we can load them. */
- plugin_load_plugins ();
-#endif /* BFD_SUPPORTS_PLUGINS */
-
- ldemul_set_symbols ();
-
- /* If we have not already opened and parsed a linker script,
- try the default script from command line first. */
- if (saved_script_handle == NULL
- && command_line.default_script != NULL)
- {
- ldfile_open_script_file (command_line.default_script);
- parser_input = input_script;
- yyparse ();
- }
-
- /* If we have not already opened and parsed a linker script
- read the emulation's appropriate default script. */
- if (saved_script_handle == NULL)
- {
- int isfile;
- char *s = ldemul_get_script (&isfile);
-
- if (isfile)
- ldfile_open_default_command_file (s);
- else
- {
- lex_string = s;
- lex_redirect (s, _("built in linker script"), 1);
- }
- parser_input = input_script;
- yyparse ();
- lex_string = NULL;
- }
-
- if (verbose)
- {
- if (saved_script_handle)
- info_msg (_("using external linker script: %s"), processed_scripts->name);
- else
- info_msg (_("using internal linker script:"));
- info_msg ("\n==================================================\n");
-
- if (saved_script_handle)
- display_external_script ();
- else
- {
- int isfile;
-
- info_msg (ldemul_get_script (&isfile));
- }
-
- info_msg ("\n==================================================\n");
- }
-
- if (command_line.section_ordering_file)
- {
- FILE *hold_script_handle;
-
- hold_script_handle = saved_script_handle;
- ldfile_open_command_file (command_line.section_ordering_file);
- if (verbose)
- display_external_script ();
- saved_script_handle = hold_script_handle;
- in_section_ordering = true;
- parser_input = input_section_ordering_script;
- yyparse ();
- in_section_ordering = false;
-
- }
-
- if (command_line.force_group_allocation
- || !bfd_link_relocatable (&link_info))
- link_info.resolve_section_groups = true;
- else
- link_info.resolve_section_groups = false;
-
- if (command_line.print_output_format)
- info_msg ("%s\n", lang_get_output_target ());
-
- lang_final ();
-
- /* If the only command line argument has been -v or --version or --verbose
- then ignore any input files provided by linker scripts and exit now.
- We do not want to create an output file when the linker is just invoked
- to provide version information. */
- if (argc == 2 && version_printed)
- xexit (0);
-
- if (link_info.inhibit_common_definition && !bfd_link_dll (&link_info))
- einfo (_("%F%P: --no-define-common may not be used without -shared\n"));
-
- if (!lang_has_input_file)
- {
- if (version_printed || command_line.print_output_format)
- xexit (0);
- output_unknown_cmdline_warnings ();
- einfo (_("%F%P: no input files\n"));
- }
-
- if (verbose)
- info_msg (_("%P: mode %s\n"), emulation);
-
- ldemul_after_parse ();
-
- output_unknown_cmdline_warnings ();
-
- if (config.map_filename)
- {
- if (strcmp (config.map_filename, "-") == 0)
- {
- config.map_file = stdout;
- }
- else
- {
- config.map_file = fopen (config.map_filename, FOPEN_WT);
- if (config.map_file == (FILE *) NULL)
- {
- bfd_set_error (bfd_error_system_call);
- einfo (_("%F%P: cannot open map file %s: %E\n"),
- config.map_filename);
- }
- }
- link_info.has_map_file = true;
- }
-
- lang_process ();
-
- /* Print error messages for any missing symbols, for any warning
- symbols, and possibly multiple definitions. */
- if (bfd_link_relocatable (&link_info))
- link_info.output_bfd->flags &= ~EXEC_P;
- else
- link_info.output_bfd->flags |= EXEC_P;
-
- flagword flags = 0;
- switch (config.compress_debug)
- {
- case COMPRESS_DEBUG_GNU_ZLIB:
- flags = BFD_COMPRESS;
- break;
- case COMPRESS_DEBUG_GABI_ZLIB:
- flags = BFD_COMPRESS | BFD_COMPRESS_GABI;
- break;
- case COMPRESS_DEBUG_ZSTD:
- flags = BFD_COMPRESS | BFD_COMPRESS_GABI | BFD_COMPRESS_ZSTD;
- break;
- default:
- break;
- }
- link_info.output_bfd->flags
- |= flags & bfd_applicable_file_flags (link_info.output_bfd);
-
- ldwrite ();
-
- if (config.map_file != NULL)
- lang_map ();
- if (command_line.cref)
- output_cref (config.map_file != NULL ? config.map_file : stdout);
- if (nocrossref_list != NULL)
- check_nocrossrefs ();
- if (command_line.print_memory_usage)
- lang_print_memory_usage ();
-#if 0
- {
- struct bfd_link_hash_entry *h;
-
- h = bfd_link_hash_lookup (link_info.hash, "__image_base__", 0,0,1);
- fprintf (stderr, "lookup = %p val %lx\n", h, h ? h->u.def.value : 1);
- }
-#endif
- ldexp_finish ();
- lang_finish ();
-
- if (config.dependency_file != NULL)
- write_dependency_file ();
-
- /* Even if we're producing relocatable output, some non-fatal errors should
- be reported in the exit status. (What non-fatal errors, if any, do we
- want to ignore for relocatable output?) */
- if (!config.make_executable && !force_make_executable)
- {
- if (verbose)
- einfo (_("%P: link errors found, deleting executable `%s'\n"),
- output_filename);
-
- /* The file will be removed by ld_cleanup. */
- xexit (1);
- }
- else
- {
- bfd *obfd = link_info.output_bfd;
- link_info.output_bfd = NULL;
- if (!bfd_close (obfd))
- einfo (_("%F%P: %s: final close failed: %E\n"), output_filename);
-
- /* If the --force-exe-suffix is enabled, and we're making an
- executable file and it doesn't end in .exe, copy it to one
- which does. */
- if (!bfd_link_relocatable (&link_info)
- && command_line.force_exe_suffix)
- {
- int len = strlen (output_filename);
-
- if (len < 4
- || (strcasecmp (output_filename + len - 4, ".exe") != 0
- && strcasecmp (output_filename + len - 4, ".dll") != 0))
- {
- FILE *src;
- FILE *dst;
- const int bsize = 4096;
- char *buf = (char *) xmalloc (bsize);
- int l;
- char *dst_name = (char *) xmalloc (len + 5);
-
- strcpy (dst_name, output_filename);
- strcat (dst_name, ".exe");
- src = fopen (output_filename, FOPEN_RB);
- dst = fopen (dst_name, FOPEN_WB);
-
- if (!src)
- einfo (_("%F%P: unable to open for source of copy `%s'\n"),
- output_filename);
- if (!dst)
- einfo (_("%F%P: unable to open for destination of copy `%s'\n"),
- dst_name);
- while ((l = fread (buf, 1, bsize, src)) > 0)
- {
- int done = fwrite (buf, 1, l, dst);
-
- if (done != l)
- einfo (_("%P: error writing file `%s'\n"), dst_name);
- }
-
- fclose (src);
- if (fclose (dst) == EOF)
- einfo (_("%P: error closing file `%s'\n"), dst_name);
- free (dst_name);
- free (buf);
- }
- }
- }
-
- if (config.stats)
- {
- long run_time = get_run_time () - start_time;
-
- fflush (stdout);
- fprintf (stderr, _("%s: total time in link: %ld.%06ld\n"),
- program_name, run_time / 1000000, run_time % 1000000);
- fflush (stderr);
- }
-
- /* Prevent ld_cleanup from deleting the output file. */
- output_filename = NULL;
-
- xexit (0);
- return 0;
-}
-
-/* If the configured sysroot is relocatable, try relocating it based on
- default prefix FROM. Return the relocated directory if it exists,
- otherwise return null. */
-
-static char *
-get_relative_sysroot (const char *from ATTRIBUTE_UNUSED)
-{
-#ifdef TARGET_SYSTEM_ROOT_RELOCATABLE
- char *path;
- struct stat s;
-
- path = make_relative_prefix (program_name, from, TARGET_SYSTEM_ROOT);
- if (path)
- {
- if (stat (path, &s) == 0 && S_ISDIR (s.st_mode))
- return path;
- free (path);
- }
-#endif
- return 0;
-}
-
-/* Return the sysroot directory. Return "" if no sysroot is being used. */
-
-static const char *
-get_sysroot (int argc, char **argv)
-{
- int i;
- const char *path = NULL;
-
- for (i = 1; i < argc; i++)
- if (startswith (argv[i], "--sysroot="))
- path = argv[i] + strlen ("--sysroot=");
-
- if (!path)
- path = get_relative_sysroot (BINDIR);
-
- if (!path)
- path = get_relative_sysroot (TOOLBINDIR);
-
- if (!path)
- path = TARGET_SYSTEM_ROOT;
-
- if (IS_DIR_SEPARATOR (*path) && path[1] == 0)
- path = "";
-
- return path;
-}
-
-/* We need to find any explicitly given emulation in order to initialize the
- state that's needed by the lex&yacc argument parser (parse_args). */
-
-static char *
-get_emulation (int argc, char **argv)
-{
- char *emulation;
- int i;
-
- emulation = getenv (EMULATION_ENVIRON);
- if (emulation == NULL)
- emulation = DEFAULT_EMULATION;
-
- for (i = 1; i < argc; i++)
- {
- if (startswith (argv[i], "-m"))
- {
- if (argv[i][2] == '\0')
- {
- /* -m EMUL */
- if (i < argc - 1)
- {
- emulation = argv[i + 1];
- i++;
- }
- else
- einfo (_("%F%P: missing argument to -m\n"));
- }
- else if (strcmp (argv[i], "-mips1") == 0
- || strcmp (argv[i], "-mips2") == 0
- || strcmp (argv[i], "-mips3") == 0
- || strcmp (argv[i], "-mips4") == 0
- || strcmp (argv[i], "-mips5") == 0
- || strcmp (argv[i], "-mips32") == 0
- || strcmp (argv[i], "-mips32r2") == 0
- || strcmp (argv[i], "-mips32r3") == 0
- || strcmp (argv[i], "-mips32r5") == 0
- || strcmp (argv[i], "-mips32r6") == 0
- || strcmp (argv[i], "-mips64") == 0
- || strcmp (argv[i], "-mips64r2") == 0
- || strcmp (argv[i], "-mips64r3") == 0
- || strcmp (argv[i], "-mips64r5") == 0
- || strcmp (argv[i], "-mips64r6") == 0)
- {
- /* FIXME: The arguments -mips1, -mips2, -mips3, etc. are
- passed to the linker by some MIPS compilers. They
- generally tell the linker to use a slightly different
- library path. Perhaps someday these should be
- implemented as emulations; until then, we just ignore
- the arguments and hope that nobody ever creates
- emulations named ips1, ips2 or ips3. */
- }
- else if (strcmp (argv[i], "-m486") == 0)
- {
- /* FIXME: The argument -m486 is passed to the linker on
- some Linux systems. Hope that nobody creates an
- emulation named 486. */
- }
- else
- {
- /* -mEMUL */
- emulation = &argv[i][2];
- }
- }
- }
-
- if ((strncmp (emulation, "elf64ppc", 8) == 0
- || strncmp (emulation, "elf32ppc", 8) == 0)
- && getenv ("LD_FORCE_LE") != NULL)
- {
- size_t len = strlen (emulation);
- char *le = xmalloc (len + 2);
- memcpy (le, emulation, 5);
- le[5] = 'l';
- memcpy (le + 6, emulation + 5, len - 4);
- emulation = le;
- }
-
- return emulation;
-}
-
-void
-add_ysym (const char *name)
-{
- if (link_info.notice_hash == NULL)
- {
- link_info.notice_hash
- = (struct bfd_hash_table *) xmalloc (sizeof (struct bfd_hash_table));
- if (!bfd_hash_table_init_n (link_info.notice_hash,
- bfd_hash_newfunc,
- sizeof (struct bfd_hash_entry),
- 61))
- einfo (_("%F%P: bfd_hash_table_init failed: %E\n"));
- }
-
- if (bfd_hash_lookup (link_info.notice_hash, name, true, true) == NULL)
- einfo (_("%F%P: bfd_hash_lookup failed: %E\n"));
-}
-
-void
-add_ignoresym (struct bfd_link_info *info, const char *name)
-{
- if (info->ignore_hash == NULL)
- {
- info->ignore_hash = xmalloc (sizeof (struct bfd_hash_table));
- if (!bfd_hash_table_init_n (info->ignore_hash,
- bfd_hash_newfunc,
- sizeof (struct bfd_hash_entry),
- 61))
- einfo (_("%F%P: bfd_hash_table_init failed: %E\n"));
- }
-
- if (bfd_hash_lookup (info->ignore_hash, name, true, true) == NULL)
- einfo (_("%F%P: bfd_hash_lookup failed: %E\n"));
-}
-
-/* Record a symbol to be wrapped, from the --wrap option. */
-
-void
-add_wrap (const char *name)
-{
- if (link_info.wrap_hash == NULL)
- {
- link_info.wrap_hash
- = (struct bfd_hash_table *) xmalloc (sizeof (struct bfd_hash_table));
- if (!bfd_hash_table_init_n (link_info.wrap_hash,
- bfd_hash_newfunc,
- sizeof (struct bfd_hash_entry),
- 61))
- einfo (_("%F%P: bfd_hash_table_init failed: %E\n"));
- }
-
- if (bfd_hash_lookup (link_info.wrap_hash, name, true, true) == NULL)
- einfo (_("%F%P: bfd_hash_lookup failed: %E\n"));
-}
-
-/* Handle the -retain-symbols-file option. */
-
-void
-add_keepsyms_file (const char *filename)
-{
- FILE *file;
- char *buf;
- size_t bufsize;
- int c;
-
- if (link_info.strip == strip_some)
- einfo (_("%X%P: error: duplicate retain-symbols-file\n"));
-
- file = fopen (filename, "r");
- if (file == NULL)
- {
- bfd_set_error (bfd_error_system_call);
- einfo ("%X%P: %s: %E\n", filename);
- return;
- }
-
- link_info.keep_hash = (struct bfd_hash_table *)
- xmalloc (sizeof (struct bfd_hash_table));
- if (!bfd_hash_table_init (link_info.keep_hash, bfd_hash_newfunc,
- sizeof (struct bfd_hash_entry)))
- einfo (_("%F%P: bfd_hash_table_init failed: %E\n"));
-
- bufsize = 100;
- buf = (char *) xmalloc (bufsize);
-
- c = getc (file);
- while (c != EOF)
- {
- while (ISSPACE (c))
- c = getc (file);
-
- if (c != EOF)
- {
- size_t len = 0;
-
- while (!ISSPACE (c) && c != EOF)
- {
- buf[len] = c;
- ++len;
- if (len >= bufsize)
- {
- bufsize *= 2;
- buf = (char *) xrealloc (buf, bufsize);
- }
- c = getc (file);
- }
-
- buf[len] = '\0';
-
- if (bfd_hash_lookup (link_info.keep_hash, buf, true, true) == NULL)
- einfo (_("%F%P: bfd_hash_lookup for insertion failed: %E\n"));
- }
- }
-
- if (link_info.strip != strip_none)
- einfo (_("%P: `-retain-symbols-file' overrides `-s' and `-S'\n"));
-
- free (buf);
- link_info.strip = strip_some;
- fclose (file);
-}
-
-/* Callbacks from the BFD linker routines. */
-
-/* This is called when BFD has decided to include an archive member in
- a link. */
-
-static bool
-add_archive_element (struct bfd_link_info *info,
- bfd *abfd,
- const char *name,
- bfd **subsbfd ATTRIBUTE_UNUSED)
-{
- lang_input_statement_type *input;
- lang_input_statement_type *parent;
- lang_input_statement_type orig_input;
-
- input = (lang_input_statement_type *)
- xcalloc (1, sizeof (lang_input_statement_type));
- input->header.type = lang_input_statement_enum;
- input->filename = bfd_get_filename (abfd);
- input->local_sym_name = bfd_get_filename (abfd);
- input->the_bfd = abfd;
-
- /* Save the original data for trace files/tries below, as plugins
- (if enabled) may possibly alter it to point to a replacement
- BFD, but we still want to output the original BFD filename. */
- orig_input = *input;
-#if BFD_SUPPORTS_PLUGINS
- /* Don't claim a fat IR object if no IR object should be claimed. */
- if (link_info.lto_plugin_active
- && (!no_more_claiming
- || bfd_get_lto_type (abfd) != lto_fat_ir_object))
- {
- /* We must offer this archive member to the plugins to claim. */
- plugin_maybe_claim (input);
- if (input->flags.claimed)
- {
- if (no_more_claiming)
- {
- /* Don't claim new IR symbols after all IR symbols have
- been claimed. */
- if (verbose)
- info_msg ("%pI: no new IR symbols to claim\n",
- &orig_input);
- input->flags.claimed = 0;
- return false;
- }
- input->flags.claim_archive = true;
- *subsbfd = input->the_bfd;
- }
- }
-#endif /* BFD_SUPPORTS_PLUGINS */
-
- if (link_info.input_bfds_tail == &input->the_bfd->link.next
- || input->the_bfd->link.next != NULL)
- {
- /* We have already loaded this element, and are attempting to
- load it again. This can happen when the archive map doesn't
- match actual symbols defined by the element. */
- free (input);
- bfd_set_error (bfd_error_malformed_archive);
- return false;
- }
-
- /* Set the file_chain pointer of archives to the last element loaded
- from the archive. See ldlang.c:find_rescan_insertion. */
- parent = bfd_usrdata (abfd->my_archive);
- if (parent != NULL && !parent->flags.reload)
- parent->next = input;
-
- ldlang_add_file (input);
-
- if (config.map_file != NULL)
- {
- static bool header_printed;
- struct bfd_link_hash_entry *h;
- bfd *from;
- int len;
-
- h = bfd_link_hash_lookup (info->hash, name, false, false, true);
- if (h == NULL
- && info->pei386_auto_import
- && startswith (name, "__imp_"))
- h = bfd_link_hash_lookup (info->hash, name + 6, false, false, true);
-
- if (h == NULL)
- from = NULL;
- else
- {
- switch (h->type)
- {
- default:
- from = NULL;
- break;
-
- case bfd_link_hash_defined:
- case bfd_link_hash_defweak:
- from = h->u.def.section->owner;
- break;
-
- case bfd_link_hash_undefined:
- case bfd_link_hash_undefweak:
- from = h->u.undef.abfd;
- break;
-
- case bfd_link_hash_common:
- from = h->u.c.p->section->owner;
- break;
- }
- }
-
- if (!header_printed)
- {
- minfo (_("Archive member included to satisfy reference by file (symbol)\n\n"));
- header_printed = true;
- }
-
- if (abfd->my_archive == NULL
- || bfd_is_thin_archive (abfd->my_archive))
- {
- minfo ("%s", bfd_get_filename (abfd));
- len = strlen (bfd_get_filename (abfd));
- }
- else
- {
- minfo ("%s(%s)", bfd_get_filename (abfd->my_archive),
- bfd_get_filename (abfd));
- len = (strlen (bfd_get_filename (abfd->my_archive))
- + strlen (bfd_get_filename (abfd))
- + 2);
- }
-
- if (len >= 29)
- {
- print_nl ();
- len = 0;
- }
- print_spaces (30 - len);
-
- if (from != NULL)
- minfo ("%pB ", from);
- if (h != NULL)
- minfo ("(%pT)\n", h->root.string);
- else
- minfo ("(%s)\n", name);
- }
-
- if (verbose
- || trace_files > 1
- || (trace_files && bfd_is_thin_archive (orig_input.the_bfd->my_archive)))
- info_msg ("%pI\n", &orig_input);
- return true;
-}
-
-/* This is called when BFD has discovered a symbol which is defined
- multiple times. */
-
-static void
-multiple_definition (struct bfd_link_info *info,
- struct bfd_link_hash_entry *h,
- bfd *nbfd,
- asection *nsec,
- bfd_vma nval)
-{
- const char *name;
- bfd *obfd;
- asection *osec;
- bfd_vma oval;
-
- if (info->allow_multiple_definition)
- return;
-
- switch (h->type)
- {
- case bfd_link_hash_defined:
- osec = h->u.def.section;
- oval = h->u.def.value;
- obfd = h->u.def.section->owner;
- break;
- case bfd_link_hash_indirect:
- osec = bfd_ind_section_ptr;
- oval = 0;
- obfd = NULL;
- break;
- default:
- abort ();
- }
-
- /* Ignore a redefinition of an absolute symbol to the
- same value; it's harmless. */
- if (h->type == bfd_link_hash_defined
- && bfd_is_abs_section (osec)
- && bfd_is_abs_section (nsec)
- && nval == oval)
- return;
-
- /* If either section has the output_section field set to
- bfd_abs_section_ptr, it means that the section is being
- discarded, and this is not really a multiple definition at all.
- FIXME: It would be cleaner to somehow ignore symbols defined in
- sections which are being discarded. */
- if (!info->prohibit_multiple_definition_absolute
- && ((osec->output_section != NULL
- && ! bfd_is_abs_section (osec)
- && bfd_is_abs_section (osec->output_section))
- || (nsec->output_section != NULL
- && !bfd_is_abs_section (nsec)
- && bfd_is_abs_section (nsec->output_section))))
- return;
-
- name = h->root.string;
- if (nbfd == NULL)
- {
- nbfd = obfd;
- nsec = osec;
- nval = oval;
- obfd = NULL;
- }
- if (info->warn_multiple_definition)
- einfo (_("%P: %C: warning: multiple definition of `%pT'"),
- nbfd, nsec, nval, name);
- else
- einfo (_("%X%P: %C: multiple definition of `%pT'"),
- nbfd, nsec, nval, name);
- if (obfd != NULL)
- einfo (_("; %D: first defined here"), obfd, osec, oval);
- einfo ("\n");
-
- if (RELAXATION_ENABLED_BY_USER)
- {
- einfo (_("%P: disabling relaxation; it will not work with multiple definitions\n"));
- DISABLE_RELAXATION;
- }
-}
-
-/* This is called when there is a definition of a common symbol, or
- when a common symbol is found for a symbol that is already defined,
- or when two common symbols are found. We only do something if
- -warn-common was used. */
-
-static void
-multiple_common (struct bfd_link_info *info ATTRIBUTE_UNUSED,
- struct bfd_link_hash_entry *h,
- bfd *nbfd,
- enum bfd_link_hash_type ntype,
- bfd_vma nsize)
-{
- const char *name;
- bfd *obfd;
- enum bfd_link_hash_type otype;
- bfd_vma osize;
-
- if (!config.warn_common)
- return;
-
- name = h->root.string;
- otype = h->type;
- if (otype == bfd_link_hash_common)
- {
- obfd = h->u.c.p->section->owner;
- osize = h->u.c.size;
- }
- else if (otype == bfd_link_hash_defined
- || otype == bfd_link_hash_defweak)
- {
- obfd = h->u.def.section->owner;
- osize = 0;
- }
- else
- {
- /* FIXME: It would nice if we could report the BFD which defined
- an indirect symbol, but we don't have anywhere to store the
- information. */
- obfd = NULL;
- osize = 0;
- }
-
- if (ntype == bfd_link_hash_defined
- || ntype == bfd_link_hash_defweak
- || ntype == bfd_link_hash_indirect)
- {
- ASSERT (otype == bfd_link_hash_common);
- if (obfd != NULL)
- einfo (_("%P: %pB: warning: definition of `%pT' overriding common"
- " from %pB\n"),
- nbfd, name, obfd);
- else
- einfo (_("%P: %pB: warning: definition of `%pT' overriding common\n"),
- nbfd, name);
- }
- else if (otype == bfd_link_hash_defined
- || otype == bfd_link_hash_defweak
- || otype == bfd_link_hash_indirect)
- {
- ASSERT (ntype == bfd_link_hash_common);
- if (obfd != NULL)
- einfo (_("%P: %pB: warning: common of `%pT' overridden by definition"
- " from %pB\n"),
- nbfd, name, obfd);
- else
- einfo (_("%P: %pB: warning: common of `%pT' overridden by definition\n"),
- nbfd, name);
- }
- else
- {
- ASSERT (otype == bfd_link_hash_common && ntype == bfd_link_hash_common);
- if (osize > nsize)
- {
- if (obfd != NULL)
- einfo (_("%P: %pB: warning: common of `%pT' overridden"
- " by larger common from %pB\n"),
- nbfd, name, obfd);
- else
- einfo (_("%P: %pB: warning: common of `%pT' overridden"
- " by larger common\n"),
- nbfd, name);
- }
- else if (nsize > osize)
- {
- if (obfd != NULL)
- einfo (_("%P: %pB: warning: common of `%pT' overriding"
- " smaller common from %pB\n"),
- nbfd, name, obfd);
- else
- einfo (_("%P: %pB: warning: common of `%pT' overriding"
- " smaller common\n"),
- nbfd, name);
- }
- else
- {
- if (obfd != NULL)
- einfo (_("%P: %pB and %pB: warning: multiple common of `%pT'\n"),
- nbfd, obfd, name);
- else
- einfo (_("%P: %pB: warning: multiple common of `%pT'\n"),
- nbfd, name);
- }
- }
-}
-
-/* This is called when BFD has discovered a set element. H is the
- entry in the linker hash table for the set. SECTION and VALUE
- represent a value which should be added to the set. */
-
-static void
-add_to_set (struct bfd_link_info *info ATTRIBUTE_UNUSED,
- struct bfd_link_hash_entry *h,
- bfd_reloc_code_real_type reloc,
- bfd *abfd,
- asection *section,
- bfd_vma value)
-{
- if (config.warn_constructors)
- einfo (_("%P: warning: global constructor %s used\n"),
- h->root.string);
-
- if (!config.build_constructors)
- return;
-
- ldctor_add_set_entry (h, reloc, NULL, section, value);
-
- if (h->type == bfd_link_hash_new)
- {
- h->type = bfd_link_hash_undefined;
- h->u.undef.abfd = abfd;
- /* We don't call bfd_link_add_undef to add this to the list of
- undefined symbols because we are going to define it
- ourselves. */
- }
-}
-
-/* This is called when BFD has discovered a constructor. This is only
- called for some object file formats--those which do not handle
- constructors in some more clever fashion. This is similar to
- adding an element to a set, but less general. */
-
-static void
-constructor_callback (struct bfd_link_info *info,
- bool constructor,
- const char *name,
- bfd *abfd,
- asection *section,
- bfd_vma value)
-{
- char *s;
- struct bfd_link_hash_entry *h;
- char set_name[1 + sizeof "__CTOR_LIST__"];
-
- if (config.warn_constructors)
- einfo (_("%P: warning: global constructor %s used\n"), name);
-
- if (!config.build_constructors)
- return;
-
- /* Ensure that BFD_RELOC_CTOR exists now, so that we can give a
- useful error message. */
- if (bfd_reloc_type_lookup (info->output_bfd, BFD_RELOC_CTOR) == NULL
- && (bfd_link_relocatable (info)
- || bfd_reloc_type_lookup (abfd, BFD_RELOC_CTOR) == NULL))
- einfo (_("%F%P: BFD backend error: BFD_RELOC_CTOR unsupported\n"));
-
- s = set_name;
- if (bfd_get_symbol_leading_char (abfd) != '\0')
- *s++ = bfd_get_symbol_leading_char (abfd);
- if (constructor)
- strcpy (s, "__CTOR_LIST__");
- else
- strcpy (s, "__DTOR_LIST__");
-
- h = bfd_link_hash_lookup (info->hash, set_name, true, true, true);
- if (h == (struct bfd_link_hash_entry *) NULL)
- einfo (_("%F%P: bfd_link_hash_lookup failed: %E\n"));
- if (h->type == bfd_link_hash_new)
- {
- h->type = bfd_link_hash_undefined;
- h->u.undef.abfd = abfd;
- /* We don't call bfd_link_add_undef to add this to the list of
- undefined symbols because we are going to define it
- ourselves. */
- }
-
- ldctor_add_set_entry (h, BFD_RELOC_CTOR, name, section, value);
-}
-
-/* A structure used by warning_callback to pass information through
- bfd_map_over_sections. */
-
-struct warning_callback_info
-{
- bool found;
- const char *warning;
- const char *symbol;
- asymbol **asymbols;
-};
-
-/* Look through the relocs to see if we can find a plausible address
- for SYMBOL in ABFD. Return TRUE if found. Otherwise return FALSE. */
-
-static bool
-symbol_warning (const char *warning, const char *symbol, bfd *abfd)
-{
- struct warning_callback_info cinfo;
-
- if (!bfd_generic_link_read_symbols (abfd))
- einfo (_("%F%P: %pB: could not read symbols: %E\n"), abfd);
-
- cinfo.found = false;
- cinfo.warning = warning;
- cinfo.symbol = symbol;
- cinfo.asymbols = bfd_get_outsymbols (abfd);
- bfd_map_over_sections (abfd, warning_find_reloc, &cinfo);
- return cinfo.found;
-}
-
-/* This is called when there is a reference to a warning symbol. */
-
-static void
-warning_callback (struct bfd_link_info *info ATTRIBUTE_UNUSED,
- const char *warning,
- const char *symbol,
- bfd *abfd,
- asection *section,
- bfd_vma address)
-{
- /* This is a hack to support warn_multiple_gp. FIXME: This should
- have a cleaner interface, but what? */
- if (!config.warn_multiple_gp
- && strcmp (warning, "using multiple gp values") == 0)
- return;
-
- if (section != NULL)
- einfo ("%P: %C: %s%s\n", abfd, section, address, _("warning: "), warning);
- else if (abfd == NULL)
- einfo ("%P: %s%s\n", _("warning: "), warning);
- else if (symbol == NULL)
- einfo ("%P: %pB: %s%s\n", abfd, _("warning: "), warning);
- else if (!symbol_warning (warning, symbol, abfd))
- {
- bfd *b;
- /* Search all input files for a reference to SYMBOL. */
- for (b = info->input_bfds; b; b = b->link.next)
- if (b != abfd && symbol_warning (warning, symbol, b))
- return;
- einfo ("%P: %pB: %s%s\n", abfd, _("warning: "), warning);
- }
-}
-
-/* This is called by warning_callback for each section. It checks the
- relocs of the section to see if it can find a reference to the
- symbol which triggered the warning. If it can, it uses the reloc
- to give an error message with a file and line number. */
-
-static void
-warning_find_reloc (bfd *abfd, asection *sec, void *iarg)
-{
- struct warning_callback_info *info = (struct warning_callback_info *) iarg;
- long relsize;
- arelent **relpp;
- long relcount;
- arelent **p, **pend;
-
- if (info->found)
- return;
-
- relsize = bfd_get_reloc_upper_bound (abfd, sec);
- if (relsize < 0)
- einfo (_("%F%P: %pB: could not read relocs: %E\n"), abfd);
- if (relsize == 0)
- return;
-
- relpp = (arelent **) xmalloc (relsize);
- relcount = bfd_canonicalize_reloc (abfd, sec, relpp, info->asymbols);
- if (relcount < 0)
- einfo (_("%F%P: %pB: could not read relocs: %E\n"), abfd);
-
- p = relpp;
- pend = p + relcount;
- for (; p < pend && *p != NULL; p++)
- {
- arelent *q = *p;
-
- if (q->sym_ptr_ptr != NULL
- && *q->sym_ptr_ptr != NULL
- && strcmp (bfd_asymbol_name (*q->sym_ptr_ptr), info->symbol) == 0)
- {
- /* We found a reloc for the symbol we are looking for. */
- einfo ("%P: %H: %s%s\n", abfd, sec, q->address, _("warning: "),
- info->warning);
- info->found = true;
- break;
- }
- }
-
- free (relpp);
-}
-
-#if SUPPORT_ERROR_HANDLING_SCRIPT
-char * error_handling_script = NULL;
-#endif
-
-/* This is called when an undefined symbol is found. */
-
-static void
-undefined_symbol (struct bfd_link_info *info,
- const char *name,
- bfd *abfd,
- asection *section,
- bfd_vma address,
- bool error)
-{
- static char *error_name;
- static unsigned int error_count;
-
-#define MAX_ERRORS_IN_A_ROW 5
-
- if (info->ignore_hash != NULL
- && bfd_hash_lookup (info->ignore_hash, name, false, false) != NULL)
- return;
-
- if (config.warn_once)
- {
- /* Only warn once about a particular undefined symbol. */
- add_ignoresym (info, name);
- }
-
- /* We never print more than a reasonable number of errors in a row
- for a single symbol. */
- if (error_name != NULL
- && strcmp (name, error_name) == 0)
- ++error_count;
- else
- {
- error_count = 0;
- free (error_name);
- error_name = xstrdup (name);
- }
-
-#if SUPPORT_ERROR_HANDLING_SCRIPT
- if (error_handling_script != NULL
- && error_count < MAX_ERRORS_IN_A_ROW)
- {
- char * argv[4];
- const char * res;
- int status, err;
-
- argv[0] = error_handling_script;
- argv[1] = "undefined-symbol";
- argv[2] = (char *) name;
- argv[3] = NULL;
-
- if (verbose)
- einfo (_("%P: About to run error handling script '%s' with arguments: '%s' '%s'\n"),
- argv[0], argv[1], argv[2]);
-
- res = pex_one (PEX_SEARCH, error_handling_script, argv,
- N_("error handling script"),
- NULL /* Send stdout to random, temp file. */,
- NULL /* Write to stderr. */,
- &status, &err);
- if (res != NULL)
- {
- einfo (_("%P: Failed to run error handling script '%s', reason: "),
- error_handling_script);
- /* FIXME: We assume here that errrno == err. */
- perror (res);
- }
- /* We ignore the return status of the script and
- carry on to issue the normal error message. */
- }
-#endif /* SUPPORT_ERROR_HANDLING_SCRIPT */
-
- if (section != NULL)
- {
- if (error_count < MAX_ERRORS_IN_A_ROW)
- {
- if (error)
- einfo (_("%X%P: %H: undefined reference to `%pT'\n"),
- abfd, section, address, name);
- else
- einfo (_("%P: %H: warning: undefined reference to `%pT'\n"),
- abfd, section, address, name);
- }
- else if (error_count == MAX_ERRORS_IN_A_ROW)
- {
- if (error)
- einfo (_("%X%P: %D: more undefined references to `%pT' follow\n"),
- abfd, section, address, name);
- else
- einfo (_("%P: %D: warning: more undefined references to `%pT' follow\n"),
- abfd, section, address, name);
- }
- else if (error)
- einfo ("%X");
- }
- else
- {
- if (error_count < MAX_ERRORS_IN_A_ROW)
- {
- if (error)
- einfo (_("%X%P: %pB: undefined reference to `%pT'\n"),
- abfd, name);
- else
- einfo (_("%P: %pB: warning: undefined reference to `%pT'\n"),
- abfd, name);
- }
- else if (error_count == MAX_ERRORS_IN_A_ROW)
- {
- if (error)
- einfo (_("%X%P: %pB: more undefined references to `%pT' follow\n"),
- abfd, name);
- else
- einfo (_("%P: %pB: warning: more undefined references to `%pT' follow\n"),
- abfd, name);
- }
- else if (error)
- einfo ("%X");
- }
-}
-
-/* Counter to limit the number of relocation overflow error messages
- to print. Errors are printed as it is decremented. When it's
- called and the counter is zero, a final message is printed
- indicating more relocations were omitted. When it gets to -1, no
- such errors are printed. If it's initially set to a value less
- than -1, all such errors will be printed (--verbose does this). */
-
-int overflow_cutoff_limit = 10;
-
-/* This is called when a reloc overflows. */
-
-static void
-reloc_overflow (struct bfd_link_info *info,
- struct bfd_link_hash_entry *entry,
- const char *name,
- const char *reloc_name,
- bfd_vma addend,
- bfd *abfd,
- asection *section,
- bfd_vma address)
-{
- if (overflow_cutoff_limit == -1)
- return;
-
- einfo ("%X%H:", abfd, section, address);
-
- if (overflow_cutoff_limit >= 0
- && overflow_cutoff_limit-- == 0)
- {
- einfo (_(" additional relocation overflows omitted from the output\n"));
- return;
- }
-
- if (entry)
- {
- while (entry->type == bfd_link_hash_indirect
- || entry->type == bfd_link_hash_warning)
- entry = entry->u.i.link;
- switch (entry->type)
- {
- case bfd_link_hash_undefined:
- case bfd_link_hash_undefweak:
- einfo (_(" relocation truncated to fit: "
- "%s against undefined symbol `%pT'"),
- reloc_name, entry->root.string);
- break;
- case bfd_link_hash_defined:
- case bfd_link_hash_defweak:
- einfo (_(" relocation truncated to fit: "
- "%s against symbol `%pT' defined in %pA section in %pB"),
- reloc_name, entry->root.string,
- entry->u.def.section,
- entry->u.def.section == bfd_abs_section_ptr
- ? info->output_bfd : entry->u.def.section->owner);
- break;
- default:
- abort ();
- break;
- }
- }
- else
- einfo (_(" relocation truncated to fit: %s against `%pT'"),
- reloc_name, name);
- if (addend != 0)
- einfo ("+%v", addend);
- einfo ("\n");
-}
-
-/* This is called when a dangerous relocation is made. */
-
-static void
-reloc_dangerous (struct bfd_link_info *info ATTRIBUTE_UNUSED,
- const char *message,
- bfd *abfd,
- asection *section,
- bfd_vma address)
-{
- einfo (_("%X%H: dangerous relocation: %s\n"),
- abfd, section, address, message);
-}
-
-/* This is called when a reloc is being generated attached to a symbol
- that is not being output. */
-
-static void
-unattached_reloc (struct bfd_link_info *info ATTRIBUTE_UNUSED,
- const char *name,
- bfd *abfd,
- asection *section,
- bfd_vma address)
-{
- einfo (_("%X%H: reloc refers to symbol `%pT' which is not being output\n"),
- abfd, section, address, name);
-}
-
-/* This is called if link_info.notice_all is set, or when a symbol in
- link_info.notice_hash is found. Symbols are put in notice_hash
- using the -y option, while notice_all is set if the --cref option
- has been supplied, or if there are any NOCROSSREFS sections in the
- linker script; and if plugins are active, since they need to monitor
- all references from non-IR files. */
-
-static bool
-notice (struct bfd_link_info *info,
- struct bfd_link_hash_entry *h,
- struct bfd_link_hash_entry *inh ATTRIBUTE_UNUSED,
- bfd *abfd,
- asection *section,
- bfd_vma value,
- flagword flags ATTRIBUTE_UNUSED)
-{
- const char *name;
-
- if (h == NULL)
- {
- if (command_line.cref || nocrossref_list != NULL)
- return handle_asneeded_cref (abfd, (enum notice_asneeded_action) value);
- return true;
- }
-
- name = h->root.string;
- if (info->notice_hash != NULL
- && bfd_hash_lookup (info->notice_hash, name, false, false) != NULL)
- {
- if (bfd_is_und_section (section))
- einfo (_("%P: %pB: reference to %s\n"), abfd, name);
- else
- einfo (_("%P: %pB: definition of %s\n"), abfd, name);
- }
-
- if (command_line.cref || nocrossref_list != NULL)
- add_cref (name, abfd, section, value);
-
- return true;
-}
Index: sources/GNU/binutils/create-2.43.1-ldforcele-patch/binutils-2.43.1-new/ld/ldlang.c
===================================================================
--- sources/GNU/binutils/create-2.43.1-ldforcele-patch/binutils-2.43.1-new/ld/ldlang.c (revision 75)
+++ sources/GNU/binutils/create-2.43.1-ldforcele-patch/binutils-2.43.1-new/ld/ldlang.c (nonexistent)
@@ -1,10009 +0,0 @@
-/* Linker command language support.
- Copyright (C) 1991-2024 Free Software Foundation, Inc.
-
- This file is part of the GNU Binutils.
-
- This program is free software; you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation; either version 3 of the License, or
- (at your option) any later version.
-
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program; if not, write to the Free Software
- Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston,
- MA 02110-1301, USA. */
-
-#include "sysdep.h"
-#include <limits.h>
-#include "bfd.h"
-#include "libiberty.h"
-#include "filenames.h"
-#include "safe-ctype.h"
-#include "obstack.h"
-#include "bfdlink.h"
-#include "ctf-api.h"
-#include "ld.h"
-#include "ldmain.h"
-#include "ldexp.h"
-#include "ldlang.h"
-#include <ldgram.h>
-#include "ldlex.h"
-#include "ldmisc.h"
-#include "ldctor.h"
-#include "ldfile.h"
-#include "ldemul.h"
-#include "fnmatch.h"
-#include "demangle.h"
-#include "hashtab.h"
-#include "elf-bfd.h"
-#include "bfdver.h"
-
-#if BFD_SUPPORTS_PLUGINS
-#include "plugin.h"
-#endif
-
-#ifndef offsetof
-#define offsetof(TYPE, MEMBER) ((size_t) & (((TYPE*) 0)->MEMBER))
-#endif
-
-/* Convert between addresses in bytes and sizes in octets.
- For currently supported targets, octets_per_byte is always a power
- of two, so we can use shifts. */
-#define TO_ADDR(X) ((X) >> opb_shift)
-#define TO_SIZE(X) ((X) << opb_shift)
-
-/* Local variables. */
-static struct obstack stat_obstack;
-static struct obstack map_obstack;
-static struct obstack pt_obstack;
-
-#define obstack_chunk_alloc xmalloc
-#define obstack_chunk_free free
-static const char *entry_symbol_default = "start";
-static bool map_head_is_link_order = false;
-static lang_output_section_statement_type *default_common_section;
-static bool map_option_f;
-static bfd_vma print_dot;
-static lang_input_statement_type *first_file;
-static const char *current_target;
-static lang_statement_list_type *stat_save[10];
-static lang_statement_list_type **stat_save_ptr = &stat_save[0];
-static struct unique_sections *unique_section_list;
-static struct asneeded_minfo *asneeded_list_head;
-static unsigned int opb_shift = 0;
-
-/* Forward declarations. */
-static void exp_init_os (etree_type *);
-static lang_input_statement_type *lookup_name (const char *);
-static bool wont_add_section_p (asection *,
- lang_output_section_statement_type *);
-static void insert_undefined (const char *);
-static bool sort_def_symbol (struct bfd_link_hash_entry *, void *);
-static lang_statement_union_type *new_statement (enum statement_enum type,
- size_t size,
- lang_statement_list_type *list);
-static void print_statement (lang_statement_union_type *,
- lang_output_section_statement_type *);
-static void print_statement_list (lang_statement_union_type *,
- lang_output_section_statement_type *);
-static void print_statements (void);
-static void print_input_section (asection *, bool);
-static bool lang_one_common (struct bfd_link_hash_entry *, void *);
-static void lang_record_phdrs (void);
-static void lang_do_version_exports_section (void);
-static void lang_finalize_version_expr_head
- (struct bfd_elf_version_expr_head *);
-static void lang_do_memory_regions (bool);
-
-/* Exported variables. */
-const char *output_target;
-lang_output_section_statement_type *abs_output_section;
-/* Header for list of statements corresponding to any files involved in the
- link, either specified from the command-line or added implicitely (eg.
- archive member used to resolved undefined symbol, wildcard statement from
- linker script, etc.). Next pointer is in next field of a
- lang_statement_header_type (reached via header field in a
- lang_statement_union). */
-lang_statement_list_type statement_list;
-lang_statement_list_type lang_os_list;
-lang_statement_list_type *stat_ptr = &statement_list;
-/* Header for list of statements corresponding to files used in the final
- executable. This can be either object file specified on the command-line
- or library member resolving an undefined reference. Next pointer is in next
- field of a lang_input_statement_type (reached via input_statement field in a
- lang_statement_union). */
-lang_statement_list_type file_chain = { NULL, NULL };
-/* Header for list of statements corresponding to files specified on the
- command-line for linking. It thus contains real object files and archive
- but not archive members. Next pointer is in next_real_file field of a
- lang_input_statement_type statement (reached via input_statement field in a
- lang_statement_union). */
-lang_statement_list_type input_file_chain;
-static const char *current_input_file;
-struct bfd_elf_dynamic_list **current_dynamic_list_p;
-struct bfd_sym_chain entry_symbol = { NULL, NULL };
-const char *entry_section = ".text";
-struct lang_input_statement_flags input_flags;
-bool entry_from_cmdline;
-bool lang_has_input_file = false;
-bool had_output_filename = false;
-bool lang_float_flag = false;
-bool delete_output_file_on_failure = false;
-bool enable_linker_version = false;
-struct lang_phdr *lang_phdr_list;
-struct lang_nocrossrefs *nocrossref_list;
-struct asneeded_minfo **asneeded_list_tail;
-#ifdef ENABLE_LIBCTF
-static ctf_dict_t *ctf_output;
-#endif
-
-/* Functions that traverse the linker script and might evaluate
- DEFINED() need to increment this at the start of the traversal. */
-int lang_statement_iteration = 0;
-
-/* Count times through one_lang_size_sections_pass after mark phase. */
-static int lang_sizing_iteration = 0;
-
-/* Return TRUE if the PATTERN argument is a wildcard pattern.
- Although backslashes are treated specially if a pattern contains
- wildcards, we do not consider the mere presence of a backslash to
- be enough to cause the pattern to be treated as a wildcard.
- That lets us handle DOS filenames more naturally. */
-#define wildcardp(pattern) (strpbrk ((pattern), "?*[") != NULL)
-
-#define new_stat(x, y) \
- (x##_type *) new_statement (x##_enum, sizeof (x##_type), y)
-
-#define outside_section_address(q) \
- ((q)->output_offset + (q)->output_section->vma)
-
-#define outside_symbol_address(q) \
- ((q)->value + outside_section_address (q->section))
-
-/* CTF sections smaller than this are not compressed: compression of
- dictionaries this small doesn't gain much, and this lets consumers mmap the
- sections directly out of the ELF file and use them with no decompression
- overhead if they want to. */
-#define CTF_COMPRESSION_THRESHOLD 4096
-
-void *
-stat_alloc (size_t size)
-{
- return obstack_alloc (&stat_obstack, size);
-}
-
-/* Code for handling simple wildcards without going through fnmatch,
- which can be expensive because of charset translations etc. */
-
-/* A simple wild is a literal string followed by a single '*',
- where the literal part is at least 4 characters long. */
-
-static bool
-is_simple_wild (const char *name)
-{
- size_t len = strcspn (name, "*?[");
- return len >= 4 && name[len] == '*' && name[len + 1] == '\0';
-}
-
-static bool
-match_simple_wild (const char *pattern, const char *name)
-{
- /* The first four characters of the pattern are guaranteed valid
- non-wildcard characters. So we can go faster. */
- if (pattern[0] != name[0] || pattern[1] != name[1]
- || pattern[2] != name[2] || pattern[3] != name[3])
- return false;
-
- pattern += 4;
- name += 4;
- while (*pattern != '*')
- if (*name++ != *pattern++)
- return false;
-
- return true;
-}
-
-static int
-name_match (const char *pattern, const char *name)
-{
- if (is_simple_wild (pattern))
- return !match_simple_wild (pattern, name);
- if (wildcardp (pattern))
- return fnmatch (pattern, name, 0);
- return strcmp (pattern, name);
-}
-
-/* Given an analyzed wildcard_spec SPEC, match it against NAME,
- returns zero on a match, non-zero if there's no match. */
-
-static int
-spec_match (const struct wildcard_spec *spec, const char *name)
-{
- size_t nl = spec->namelen;
- size_t pl = spec->prefixlen;
- size_t sl = spec->suffixlen;
- size_t inputlen = strlen (name);
- int r;
-
- if (pl)
- {
- if (inputlen < pl)
- return 1;
-
- r = memcmp (spec->name, name, pl);
- if (r)
- return r;
- }
-
- if (sl)
- {
- if (inputlen < sl)
- return 1;
-
- r = memcmp (spec->name + nl - sl, name + inputlen - sl, sl);
- if (r)
- return r;
- }
-
- if (nl == pl + sl + 1 && spec->name[pl] == '*')
- return 0;
-
- if (nl > pl)
- return fnmatch (spec->name + pl, name + pl, 0);
-
- if (inputlen >= nl)
- return name[nl];
-
- return 0;
-}
-
-static char *
-ldirname (const char *name)
-{
- const char *base = lbasename (name);
- char *dirname;
-
- while (base > name && IS_DIR_SEPARATOR (base[-1]))
- --base;
- if (base == name)
- return strdup (".");
- dirname = strdup (name);
- dirname[base - name] = '\0';
- return dirname;
-}
-
-/* If PATTERN is of the form archive:file, return a pointer to the
- separator. If not, return NULL. */
-
-static char *
-archive_path (const char *pattern)
-{
- char *p = NULL;
-
- if (link_info.path_separator == 0)
- return p;
-
- p = strchr (pattern, link_info.path_separator);
-#ifdef HAVE_DOS_BASED_FILE_SYSTEM
- if (p == NULL || link_info.path_separator != ':')
- return p;
-
- /* Assume a match on the second char is part of drive specifier,
- as in "c:\silly.dos". */
- if (p == pattern + 1 && ISALPHA (*pattern))
- p = strchr (p + 1, link_info.path_separator);
-#endif
- return p;
-}
-
-/* Given that FILE_SPEC results in a non-NULL SEP result from archive_path,
- return whether F matches FILE_SPEC. */
-
-static bool
-input_statement_is_archive_path (const char *file_spec, char *sep,
- lang_input_statement_type *f)
-{
- bool match = false;
-
- if ((*(sep + 1) == 0
- || name_match (sep + 1, f->filename) == 0)
- && ((sep != file_spec)
- == (f->the_bfd != NULL && f->the_bfd->my_archive != NULL)))
- {
- match = true;
-
- if (sep != file_spec)
- {
- const char *aname = bfd_get_filename (f->the_bfd->my_archive);
- *sep = 0;
- match = name_match (file_spec, aname) == 0;
- *sep = link_info.path_separator;
- }
- }
- return match;
-}
-
-static bool
-unique_section_p (const asection *sec,
- const lang_output_section_statement_type *os)
-{
- struct unique_sections *unam;
- const char *secnam;
-
- if (!link_info.resolve_section_groups
- && sec->owner != NULL
- && bfd_is_group_section (sec->owner, sec))
- return !(os != NULL
- && strcmp (os->name, DISCARD_SECTION_NAME) == 0);
-
- secnam = sec->name;
- for (unam = unique_section_list; unam; unam = unam->next)
- if (name_match (unam->name, secnam) == 0)
- return true;
-
- return false;
-}
-
-/* Generic traversal routines for finding matching sections. */
-
-/* Return true if FILE matches a pattern in EXCLUDE_LIST, otherwise return
- false. */
-
-static bool
-walk_wild_file_in_exclude_list (struct name_list *exclude_list,
- lang_input_statement_type *file)
-{
- struct name_list *list_tmp;
-
- for (list_tmp = exclude_list;
- list_tmp;
- list_tmp = list_tmp->next)
- {
- char *p = archive_path (list_tmp->name);
-
- if (p != NULL)
- {
- if (input_statement_is_archive_path (list_tmp->name, p, file))
- return true;
- }
-
- else if (name_match (list_tmp->name, file->filename) == 0)
- return true;
-
- /* FIXME: Perhaps remove the following at some stage? Matching
- unadorned archives like this was never documented and has
- been superceded by the archive:path syntax. */
- else if (file->the_bfd != NULL
- && file->the_bfd->my_archive != NULL
- && name_match (list_tmp->name,
- bfd_get_filename (file->the_bfd->my_archive)) == 0)
- return true;
- }
-
- return false;
-}
-
-/* Add SECTION (from input FILE) to the list of matching sections
- within PTR (the matching wildcard is SEC). */
-
-static void
-add_matching_section (lang_wild_statement_type *ptr,
- struct wildcard_list *sec,
- asection *section,
- lang_input_statement_type *file)
-{
- lang_input_matcher_type *new_section;
- /* Add a section reference to the list. */
- new_section = new_stat (lang_input_matcher, &ptr->matching_sections);
- new_section->section = section;
- new_section->pattern = sec;
- new_section->input_stmt = file;
-}
-
-/* Process section S (from input file FILE) in relation to wildcard
- statement PTR. We already know that a prefix of the name of S matches
- some wildcard in PTR's wildcard list. Here we check if the filename
- matches as well (if it's specified) and if any of the wildcards in fact
- does match. */
-
-static void
-walk_wild_section_match (lang_wild_statement_type *ptr,
- lang_input_statement_type *file,
- asection *s)
-{
- struct wildcard_list *sec;
- const char *file_spec = ptr->filename;
- char *p;
-
- /* Check if filenames match. */
- if (file_spec == NULL)
- ;
- else if ((p = archive_path (file_spec)) != NULL)
- {
- if (!input_statement_is_archive_path (file_spec, p, file))
- return;
- }
- else if (wildcardp (file_spec))
- {
- if (fnmatch (file_spec, file->filename, 0) != 0)
- return;
- }
- else
- {
- /* XXX Matching against non-wildcard filename in wild statements
- was done by going through lookup_name, which uses
- ->local_sym_name to compare against, not ->filename. We retain
- this behaviour even though the above code paths use filename.
- It would be more logical to use it here as well, in which
- case the above wildcard() arm could be folded into this by using
- name_match. This would also solve the worry of what to do
- about unset local_sym_name (in which case lookup_name simply adds
- the input file again). */
- const char *filename = file->local_sym_name;
- lang_input_statement_type *arch_is;
- if (filename && filename_cmp (filename, file_spec) == 0)
- ;
- /* FIXME: see also walk_wild_file_in_exclude_list for why we
- also check parents BFD (local_sym_)name to match input statements
- with unadorned archive names. */
- else if (file->the_bfd
- && file->the_bfd->my_archive
- && (arch_is = bfd_usrdata (file->the_bfd->my_archive))
- && arch_is->local_sym_name
- && filename_cmp (arch_is->local_sym_name, file_spec) == 0)
- ;
- else
- return;
- }
-
- /* If filename is excluded we're done. */
- if (walk_wild_file_in_exclude_list (ptr->exclude_name_list, file))
- return;
-
- /* Check section name against each wildcard spec. If there's no
- wildcard all sections match. */
- sec = ptr->section_list;
- if (sec == NULL)
- add_matching_section (ptr, sec, s, file);
- else
- {
- const char *sname = bfd_section_name (s);
- for (; sec != NULL; sec = sec->next)
- {
- if (sec->spec.name != NULL
- && spec_match (&sec->spec, sname) != 0)
- continue;
-
- /* Don't process sections from files which were excluded. */
- if (!walk_wild_file_in_exclude_list (sec->spec.exclude_name_list,
- file))
- add_matching_section (ptr, sec, s, file);
- }
- }
-}
-
-/* Return the numerical value of the init_priority attribute from
- section name NAME. */
-
-static int
-get_init_priority (const asection *sec)
-{
- const char *name = bfd_section_name (sec);
- const char *dot;
-
- /* GCC uses the following section names for the init_priority
- attribute with numerical values 101 to 65535 inclusive. A
- lower value means a higher priority.
-
- 1: .init_array.NNNNN/.fini_array.NNNNN: Where NNNNN is the
- decimal numerical value of the init_priority attribute.
- The order of execution in .init_array is forward and
- .fini_array is backward.
- 2: .ctors.NNNNN/.dtors.NNNNN: Where NNNNN is 65535 minus the
- decimal numerical value of the init_priority attribute.
- The order of execution in .ctors is backward and .dtors
- is forward.
-
- .init_array.NNNNN sections would normally be placed in an output
- .init_array section, .fini_array.NNNNN in .fini_array,
- .ctors.NNNNN in .ctors, and .dtors.NNNNN in .dtors. This means
- we should sort by increasing number (and could just use
- SORT_BY_NAME in scripts). However if .ctors.NNNNN sections are
- being placed in .init_array (which may also contain
- .init_array.NNNNN sections) or .dtors.NNNNN sections are being
- placed in .fini_array then we need to extract the init_priority
- attribute and sort on that. */
- dot = strrchr (name, '.');
- if (dot != NULL && ISDIGIT (dot[1]))
- {
- char *end;
- unsigned long init_priority = strtoul (dot + 1, &end, 10);
- if (*end == 0)
- {
- if (dot == name + 6
- && (strncmp (name, ".ctors", 6) == 0
- || strncmp (name, ".dtors", 6) == 0))
- init_priority = 65535 - init_priority;
- if (init_priority <= INT_MAX)
- return init_priority;
- }
- }
- return -1;
-}
-
-/* Compare sections ASEC and BSEC according to SORT. */
-
-static int
-compare_section (sort_type sort, asection *asec, asection *bsec, bool reversed)
-{
- int ret;
- int a_priority, b_priority;
-
- switch (sort)
- {
- default:
- abort ();
-
- case by_init_priority:
- a_priority = get_init_priority (asec);
- b_priority = get_init_priority (bsec);
- if (a_priority < 0 || b_priority < 0)
- goto sort_by_name;
- if (reversed)
- ret = b_priority - a_priority;
- else
- ret = a_priority - b_priority;
- if (ret)
- break;
- else
- goto sort_by_name;
-
- case by_alignment_name:
- ret = bfd_section_alignment (bsec) - bfd_section_alignment (asec);
- if (ret)
- break;
- /* Fall through. */
-
- case by_name:
- sort_by_name:
- if (reversed)
- ret = strcmp (bfd_section_name (bsec), bfd_section_name (asec));
- else
- ret = strcmp (bfd_section_name (asec), bfd_section_name (bsec));
- break;
-
- case by_name_alignment:
- if (reversed)
- ret = strcmp (bfd_section_name (bsec), bfd_section_name (asec));
- else
- ret = strcmp (bfd_section_name (asec), bfd_section_name (bsec));
- if (ret)
- break;
- /* Fall through. */
-
- case by_alignment:
- ret = bfd_section_alignment (bsec) - bfd_section_alignment (asec);
- break;
- }
-
- return ret;
-}
-
-/* PE puts the sort key in the input statement. */
-
-static const char *
-sort_filename (bfd *abfd)
-{
- lang_input_statement_type *is = bfd_usrdata (abfd);
- if (is->sort_key)
- return is->sort_key;
- return bfd_get_filename (abfd);
-}
-
-/* Handle wildcard sorting. This returns the place in a binary search tree
- where this FILE:SECTION should be inserted for wild statement WILD where
- the spec SEC was the matching one. The tree is later linearized. */
-
-static lang_section_bst_type **
-wild_sort (lang_wild_statement_type *wild,
- struct wildcard_list *sec,
- lang_input_statement_type *file,
- asection *section)
-{
- lang_section_bst_type **tree;
-
- if (!wild->filenames_sorted
- && (sec == NULL || sec->spec.sorted == none
- || sec->spec.sorted == by_none))
- {
- /* We might be called even if _this_ spec doesn't need sorting,
- in which case we simply append at the right end of tree. */
- return wild->rightmost;
- }
-
- tree = &wild->tree;
- while (*tree)
- {
- /* Sorting by filename takes precedence over sorting by section
- name. */
-
- if (wild->filenames_sorted)
- {
- const char *fn, *ln;
- bool fa, la;
- int i;
- asection *lsec = (*tree)->section;
-
- /* The PE support for the .idata section as generated by
- dlltool assumes that files will be sorted by the name of
- the archive and then the name of the file within the
- archive. */
-
- fa = file->the_bfd->my_archive != NULL;
- if (fa)
- fn = sort_filename (file->the_bfd->my_archive);
- else
- fn = sort_filename (file->the_bfd);
-
- la = lsec->owner->my_archive != NULL;
- if (la)
- ln = sort_filename (lsec->owner->my_archive);
- else
- ln = sort_filename (lsec->owner);
-
- if (wild->filenames_reversed)
- i = filename_cmp (ln, fn);
- else
- i = filename_cmp (fn, ln);
-
- if (i > 0)
- { tree = &((*tree)->right); continue; }
- else if (i < 0)
- { tree = &((*tree)->left); continue; }
-
- if (fa || la)
- {
- if (fa)
- fn = sort_filename (file->the_bfd);
- if (la)
- ln = sort_filename (lsec->owner);
-
- if (wild->filenames_reversed)
- i = filename_cmp (ln, fn);
- else
- i = filename_cmp (fn, ln);
-
- if (i > 0)
- { tree = &((*tree)->right); continue; }
- else if (i < 0)
- { tree = &((*tree)->left); continue; }
- }
- }
-
- /* Here either the files are not sorted by name, or we are
- looking at the sections for this file. */
-
- /* Find the correct node to append this section. */
- if (sec && sec->spec.sorted != none && sec->spec.sorted != by_none
- && compare_section (sec->spec.sorted, section, (*tree)->section, sec->spec.reversed) < 0)
- tree = &((*tree)->left);
- else
- tree = &((*tree)->right);
- }
-
- return tree;
-}
-
-/* Use wild_sort to build a BST to sort sections. */
-
-static void
-output_section_callback_sort (lang_wild_statement_type *ptr,
- struct wildcard_list *sec,
- asection *section,
- lang_input_statement_type *file,
- void *output)
-{
- lang_section_bst_type *node;
- lang_section_bst_type **tree;
- lang_output_section_statement_type *os;
-
- os = (lang_output_section_statement_type *) output;
-
- if (unique_section_p (section, os))
- return;
-
- /* Don't add sections to the tree when we already know that
- lang_add_section won't do anything with it. */
- if (wont_add_section_p (section, os))
- return;
-
- node = (lang_section_bst_type *) xmalloc (sizeof (lang_section_bst_type));
- node->left = 0;
- node->right = 0;
- node->section = section;
- node->pattern = ptr->section_list;
-
- tree = wild_sort (ptr, sec, file, section);
- if (tree != NULL)
- {
- *tree = node;
- if (tree == ptr->rightmost)
- ptr->rightmost = &node->right;
- }
-}
-
-/* Convert a sorted sections' BST back to list form. */
-
-static void
-output_section_callback_tree_to_list (lang_wild_statement_type *ptr,
- lang_section_bst_type *tree,
- void *output)
-{
- if (tree->left)
- output_section_callback_tree_to_list (ptr, tree->left, output);
-
- lang_add_section (&ptr->children, tree->section, tree->pattern,
- ptr->section_flag_list,
- (lang_output_section_statement_type *) output);
-
- if (tree->right)
- output_section_callback_tree_to_list (ptr, tree->right, output);
-
- free (tree);
-}
-
-
-/* Sections are matched against wildcard statements via a prefix tree.
- The prefix tree holds prefixes of all matching patterns (up to the first
- wildcard character), and the wild statement from which those patterns
- came. When matching a section name against the tree we're walking through
- the tree character by character. Each statement we hit is one that
- potentially matches. This is checked by actually going through the
- (glob) matching routines.
-
- When the section name turns out to actually match we record that section
- in the wild statements list of matching sections. */
-
-/* A prefix can be matched by multiple statement, so we need a list of them. */
-struct wild_stmt_list
-{
- lang_wild_statement_type *stmt;
- struct wild_stmt_list *next;
-};
-
-/* The prefix tree itself. */
-struct prefixtree
-{
- /* The list of all children (linked via .next). */
- struct prefixtree *child;
- struct prefixtree *next;
- /* This tree node is responsible for the prefix of parent plus 'c'. */
- char c;
- /* The statements that potentially can match this prefix. */
- struct wild_stmt_list *stmt;
-};
-
-/* We always have a root node in the prefix tree. It corresponds to the
- empty prefix. E.g. a glob like "*" would sit in this root. */
-static struct prefixtree the_root, *ptroot = &the_root;
-
-/* Given a prefix tree in *TREE, corresponding to prefix P, find or
- INSERT the tree node corresponding to prefix P+C. */
-
-static struct prefixtree *
-get_prefix_tree (struct prefixtree **tree, char c, bool insert)
-{
- struct prefixtree *t;
- for (t = *tree; t; t = t->next)
- if (t->c == c)
- return t;
- if (!insert)
- return NULL;
- t = (struct prefixtree *) obstack_alloc (&pt_obstack, sizeof *t);
- t->child = NULL;
- t->next = *tree;
- t->c = c;
- t->stmt = NULL;
- *tree = t;
- return t;
-}
-
-/* Add STMT to the set of statements that can be matched by the prefix
- corresponding to prefix tree T. */
-
-static void
-pt_add_stmt (struct prefixtree *t, lang_wild_statement_type *stmt)
-{
- struct wild_stmt_list *sl, **psl;
- sl = (struct wild_stmt_list *) obstack_alloc (&pt_obstack, sizeof *sl);
- sl->stmt = stmt;
- sl->next = NULL;
- psl = &t->stmt;
- while (*psl)
- psl = &(*psl)->next;
- *psl = sl;
-}
-
-/* Insert STMT into the global prefix tree. */
-
-static void
-insert_prefix_tree (lang_wild_statement_type *stmt)
-{
- struct wildcard_list *sec;
- struct prefixtree *t;
-
- if (!stmt->section_list)
- {
- /* If we have no section_list (no wildcards in the wild STMT),
- then every section name will match, so add this to the root. */
- pt_add_stmt (ptroot, stmt);
- return;
- }
-
- for (sec = stmt->section_list; sec; sec = sec->next)
- {
- const char *name = sec->spec.name ? sec->spec.name : "*";
- char c;
- t = ptroot;
- for (; (c = *name); name++)
- {
- if (c == '*' || c == '[' || c == '?')
- break;
- t = get_prefix_tree (&t->child, c, true);
- }
- /* If we hit a glob character, the matching prefix is what we saw
- until now. If we hit the end of pattern (hence it's no glob) then
- we can do better: we only need to record a match when a section name
- completely matches, not merely a prefix, so record the trailing 0
- as well. */
- if (!c)
- t = get_prefix_tree (&t->child, 0, true);
- pt_add_stmt (t, stmt);
- }
-}
-
-/* Dump T indented by INDENT spaces. */
-
-static void
-debug_prefix_tree_rec (struct prefixtree *t, int indent)
-{
- for (; t; t = t->next)
- {
- struct wild_stmt_list *sl;
- printf ("%*s %c", indent, "", t->c);
- for (sl = t->stmt; sl; sl = sl->next)
- {
- struct wildcard_list *curr;
- printf (" %p ", sl->stmt);
- for (curr = sl->stmt->section_list; curr; curr = curr->next)
- printf ("%s ", curr->spec.name ? curr->spec.name : "*");
- }
- printf ("\n");
- debug_prefix_tree_rec (t->child, indent + 2);
- }
-}
-
-/* Dump the global prefix tree. */
-
-static void
-debug_prefix_tree (void)
-{
- debug_prefix_tree_rec (ptroot, 2);
-}
-
-/* Like strcspn() but start to look from the end to beginning of
- S. Returns the length of the suffix of S consisting entirely
- of characters not in REJECT. */
-
-static size_t
-rstrcspn (const char *s, const char *reject)
-{
- size_t len = strlen (s), sufflen = 0;
- while (len--)
- {
- char c = s[len];
- if (strchr (reject, c) != 0)
- break;
- sufflen++;
- }
- return sufflen;
-}
-
-/* Analyze the wildcards in wild statement PTR to setup various
- things for quick matching. */
-
-static void
-analyze_walk_wild_section_handler (lang_wild_statement_type *ptr)
-{
- struct wildcard_list *sec;
-
- ptr->tree = NULL;
- ptr->rightmost = &ptr->tree;
-
- for (sec = ptr->section_list; sec != NULL; sec = sec->next)
- {
- if (sec->spec.name)
- {
- sec->spec.namelen = strlen (sec->spec.name);
- sec->spec.prefixlen = strcspn (sec->spec.name, "?*[");
- sec->spec.suffixlen = rstrcspn (sec->spec.name + sec->spec.prefixlen,
- "?*]");
- }
- else
- sec->spec.namelen = sec->spec.prefixlen = sec->spec.suffixlen = 0;
- }
-
- insert_prefix_tree (ptr);
-}
-
-/* Match all sections from FILE against the global prefix tree,
- and record them into each wild statement that has a match. */
-
-static void
-resolve_wild_sections (lang_input_statement_type *file)
-{
- asection *s;
-
- if (file->flags.just_syms)
- return;
-
- for (s = file->the_bfd->sections; s != NULL; s = s->next)
- {
- const char *sname = bfd_section_name (s);
- char c = 1;
- struct prefixtree *t = ptroot;
- //printf (" YYY consider %s of %s\n", sname, file->the_bfd->filename);
- do
- {
- if (t->stmt)
- {
- struct wild_stmt_list *sl;
- for (sl = t->stmt; sl; sl = sl->next)
- {
- walk_wild_section_match (sl->stmt, file, s);
- //printf (" ZZZ maybe place into %p\n", sl->stmt);
- }
- }
- if (!c)
- break;
- c = *sname++;
- t = get_prefix_tree (&t->child, c, false);
- }
- while (t);
- }
-}
-
-/* Match all sections from all input files against the global prefix tree. */
-
-static void
-resolve_wilds (void)
-{
- LANG_FOR_EACH_INPUT_STATEMENT (f)
- {
- //printf("XXX %s\n", f->filename);
- if (f->the_bfd == NULL
- || !bfd_check_format (f->the_bfd, bfd_archive))
- resolve_wild_sections (f);
- else
- {
- bfd *member;
-
- /* This is an archive file. We must map each member of the
- archive separately. */
- member = bfd_openr_next_archived_file (f->the_bfd, NULL);
- while (member != NULL)
- {
- /* When lookup_name is called, it will call the add_symbols
- entry point for the archive. For each element of the
- archive which is included, BFD will call ldlang_add_file,
- which will set the usrdata field of the member to the
- lang_input_statement. */
- if (bfd_usrdata (member) != NULL)
- resolve_wild_sections (bfd_usrdata (member));
-
- member = bfd_openr_next_archived_file (f->the_bfd, member);
- }
- }
- }
-}
-
-/* For each input section that matches wild statement S calls
- CALLBACK with DATA. */
-
-static void
-walk_wild (lang_wild_statement_type *s, callback_t callback, void *data)
-{
- lang_statement_union_type *l;
-
- for (l = s->matching_sections.head; l; l = l->header.next)
- {
- (*callback) (s, l->input_matcher.pattern, l->input_matcher.section,
- l->input_matcher.input_stmt, data);
- }
-}
-
-/* lang_for_each_statement walks the parse tree and calls the provided
- function for each node, except those inside output section statements
- with constraint set to -1. */
-
-void
-lang_for_each_statement_worker (void (*func) (lang_statement_union_type *),
- lang_statement_union_type *s)
-{
- for (; s != NULL; s = s->header.next)
- {
- func (s);
-
- switch (s->header.type)
- {
- case lang_constructors_statement_enum:
- lang_for_each_statement_worker (func, constructor_list.head);
- break;
- case lang_output_section_statement_enum:
- if (s->output_section_statement.constraint != -1)
- lang_for_each_statement_worker
- (func, s->output_section_statement.children.head);
- break;
- case lang_wild_statement_enum:
- lang_for_each_statement_worker (func,
- s->wild_statement.children.head);
- break;
- case lang_group_statement_enum:
- lang_for_each_statement_worker (func,
- s->group_statement.children.head);
- break;
- case lang_data_statement_enum:
- case lang_reloc_statement_enum:
- case lang_object_symbols_statement_enum:
- case lang_output_statement_enum:
- case lang_target_statement_enum:
- case lang_input_section_enum:
- case lang_input_statement_enum:
- case lang_assignment_statement_enum:
- case lang_padding_statement_enum:
- case lang_address_statement_enum:
- case lang_fill_statement_enum:
- case lang_insert_statement_enum:
- break;
- default:
- FAIL ();
- break;
- }
- }
-}
-
-void
-lang_for_each_statement (void (*func) (lang_statement_union_type *))
-{
- lang_for_each_statement_worker (func, statement_list.head);
-}
-
-/*----------------------------------------------------------------------*/
-
-void
-lang_list_init (lang_statement_list_type *list)
-{
- list->head = NULL;
- list->tail = &list->head;
-}
-
-static void
-lang_statement_append (lang_statement_list_type *list,
- void *element,
- void *field)
-{
- *(list->tail) = element;
- list->tail = field;
-}
-
-void
-push_stat_ptr (lang_statement_list_type *new_ptr)
-{
- if (stat_save_ptr >= stat_save + sizeof (stat_save) / sizeof (stat_save[0]))
- abort ();
- *stat_save_ptr++ = stat_ptr;
- stat_ptr = new_ptr;
-}
-
-void
-pop_stat_ptr (void)
-{
- if (stat_save_ptr <= stat_save)
- abort ();
- stat_ptr = *--stat_save_ptr;
-}
-
-/* Build a new statement node for the parse tree. */
-
-static lang_statement_union_type *
-new_statement (enum statement_enum type,
- size_t size,
- lang_statement_list_type *list)
-{
- lang_statement_union_type *new_stmt;
-
- new_stmt = stat_alloc (size);
- new_stmt->header.type = type;
- new_stmt->header.next = NULL;
- lang_statement_append (list, new_stmt, &new_stmt->header.next);
- return new_stmt;
-}
-
-/* Build a new input file node for the language. There are several
- ways in which we treat an input file, eg, we only look at symbols,
- or prefix it with a -l etc.
-
- We can be supplied with requests for input files more than once;
- they may, for example be split over several lines like foo.o(.text)
- foo.o(.data) etc, so when asked for a file we check that we haven't
- got it already so we don't duplicate the bfd. */
-
-static lang_input_statement_type *
-new_afile (const char *name,
- lang_input_file_enum_type file_type,
- const char *target,
- const char *from_filename)
-{
- lang_input_statement_type *p;
-
- lang_has_input_file = true;
-
- /* PR 30632: It is OK for name to be NULL. For example
- see the initialization of first_file in lang_init(). */
- if (name != NULL)
- {
- name = ldfile_possibly_remap_input (name);
- /* But if a name is remapped to NULL, it should be ignored. */
- if (name == NULL)
- return NULL;
- }
-
- p = new_stat (lang_input_statement, stat_ptr);
- memset (&p->the_bfd, 0,
- sizeof (*p) - offsetof (lang_input_statement_type, the_bfd));
- p->extra_search_path = NULL;
- p->target = target;
- p->flags.dynamic = input_flags.dynamic;
- p->flags.add_DT_NEEDED_for_dynamic = input_flags.add_DT_NEEDED_for_dynamic;
- p->flags.add_DT_NEEDED_for_regular = input_flags.add_DT_NEEDED_for_regular;
- p->flags.whole_archive = input_flags.whole_archive;
- p->flags.sysrooted = input_flags.sysrooted;
- p->sort_key = NULL;
-
- switch (file_type)
- {
- case lang_input_file_is_symbols_only_enum:
- p->filename = name;
- p->local_sym_name = name;
- p->flags.real = true;
- p->flags.just_syms = true;
- break;
- case lang_input_file_is_fake_enum:
- p->filename = name;
- p->local_sym_name = name;
- break;
- case lang_input_file_is_l_enum:
- if (name[0] == ':' && name[1] != '\0')
- {
- p->filename = name + 1;
- p->flags.full_name_provided = true;
- }
- else
- p->filename = name;
- p->local_sym_name = concat ("-l", name, (const char *) NULL);
- p->flags.maybe_archive = true;
- p->flags.real = true;
- p->flags.search_dirs = true;
- break;
- case lang_input_file_is_marker_enum:
- p->filename = name;
- p->local_sym_name = name;
- p->flags.search_dirs = true;
- break;
- case lang_input_file_is_search_file_enum:
- p->filename = name;
- p->local_sym_name = name;
- /* If name is a relative path, search the directory of the current linker
- script first. */
- if (from_filename && !IS_ABSOLUTE_PATH (name))
- p->extra_search_path = ldirname (from_filename);
- p->flags.real = true;
- p->flags.search_dirs = true;
- break;
- case lang_input_file_is_file_enum:
- p->filename = name;
- p->local_sym_name = name;
- p->flags.real = true;
- break;
- default:
- FAIL ();
- }
-
- lang_statement_append (&input_file_chain, p, &p->next_real_file);
- return p;
-}
-
-lang_input_statement_type *
-lang_add_input_file (const char *name,
- lang_input_file_enum_type file_type,
- const char *target)
-{
- if (name != NULL
- && (*name == '=' || startswith (name, "$SYSROOT")))
- {
- lang_input_statement_type *ret;
- char *sysrooted_name
- = concat (ld_sysroot,
- name + (*name == '=' ? 1 : strlen ("$SYSROOT")),
- (const char *) NULL);
-
- /* We've now forcibly prepended the sysroot, making the input
- file independent of the context. Therefore, temporarily
- force a non-sysrooted context for this statement, so it won't
- get the sysroot prepended again when opened. (N.B. if it's a
- script, any child nodes with input files starting with "/"
- will be handled as "sysrooted" as they'll be found to be
- within the sysroot subdirectory.) */
- unsigned int outer_sysrooted = input_flags.sysrooted;
- input_flags.sysrooted = 0;
- ret = new_afile (sysrooted_name, file_type, target, NULL);
- input_flags.sysrooted = outer_sysrooted;
- return ret;
- }
-
- return new_afile (name, file_type, target, current_input_file);
-}
-
-struct out_section_hash_entry
-{
- struct bfd_hash_entry root;
- lang_statement_union_type s;
-};
-
-/* The hash table. */
-
-static struct bfd_hash_table output_section_statement_table;
-
-/* Support routines for the hash table used by lang_output_section_find,
- initialize the table, fill in an entry and remove the table. */
-
-static struct bfd_hash_entry *
-output_section_statement_newfunc (struct bfd_hash_entry *entry,
- struct bfd_hash_table *table,
- const char *string)
-{
- lang_output_section_statement_type **nextp;
- struct out_section_hash_entry *ret;
-
- if (entry == NULL)
- {
- entry = (struct bfd_hash_entry *) bfd_hash_allocate (table,
- sizeof (*ret));
- if (entry == NULL)
- return entry;
- }
-
- entry = bfd_hash_newfunc (entry, table, string);
- if (entry == NULL)
- return entry;
-
- ret = (struct out_section_hash_entry *) entry;
- memset (&ret->s, 0, sizeof (ret->s));
- ret->s.header.type = lang_output_section_statement_enum;
- ret->s.output_section_statement.subsection_alignment = NULL;
- ret->s.output_section_statement.section_alignment = NULL;
- ret->s.output_section_statement.block_value = 1;
- lang_list_init (&ret->s.output_section_statement.children);
- lang_list_init (&ret->s.output_section_statement.sort_children);
- lang_statement_append (stat_ptr, &ret->s, &ret->s.header.next);
-
- /* For every output section statement added to the list, except the
- first one, lang_os_list.tail points to the "next"
- field of the last element of the list. */
- if (lang_os_list.head != NULL)
- ret->s.output_section_statement.prev
- = ((lang_output_section_statement_type *)
- ((char *) lang_os_list.tail
- - offsetof (lang_output_section_statement_type, next)));
-
- /* GCC's strict aliasing rules prevent us from just casting the
- address, so we store the pointer in a variable and cast that
- instead. */
- nextp = &ret->s.output_section_statement.next;
- lang_statement_append (&lang_os_list, &ret->s, nextp);
- return &ret->root;
-}
-
-static void
-output_section_statement_table_init (void)
-{
- if (!bfd_hash_table_init_n (&output_section_statement_table,
- output_section_statement_newfunc,
- sizeof (struct out_section_hash_entry),
- 61))
- einfo (_("%F%P: can not create hash table: %E\n"));
-}
-
-static void
-output_section_statement_table_free (void)
-{
- bfd_hash_table_free (&output_section_statement_table);
-}
-
-/* Build enough state so that the parser can build its tree. */
-
-void
-lang_init (void)
-{
- obstack_begin (&stat_obstack, 1000);
- obstack_init (&pt_obstack);
-
- stat_ptr = &statement_list;
-
- output_section_statement_table_init ();
-
- lang_list_init (stat_ptr);
-
- lang_list_init (&input_file_chain);
- lang_list_init (&lang_os_list);
- lang_list_init (&file_chain);
- first_file = lang_add_input_file (NULL, lang_input_file_is_marker_enum,
- NULL);
- abs_output_section =
- lang_output_section_statement_lookup (BFD_ABS_SECTION_NAME, 0, 1);
-
- abs_output_section->bfd_section = bfd_abs_section_ptr;
-
- asneeded_list_head = NULL;
- asneeded_list_tail = &asneeded_list_head;
-}
-
-void
-lang_finish (void)
-{
- output_section_statement_table_free ();
- ldfile_remap_input_free ();
-}
-
-/*----------------------------------------------------------------------
- A region is an area of memory declared with the
- MEMORY { name:org=exp, len=exp ... }
- syntax.
-
- We maintain a list of all the regions here.
-
- If no regions are specified in the script, then the default is used
- which is created when looked up to be the entire data space.
-
- If create is true we are creating a region inside a MEMORY block.
- In this case it is probably an error to create a region that has
- already been created. If we are not inside a MEMORY block it is
- dubious to use an undeclared region name (except DEFAULT_MEMORY_REGION)
- and so we issue a warning.
-
- Each region has at least one name. The first name is either
- DEFAULT_MEMORY_REGION or the name given in the MEMORY block. You can add
- alias names to an existing region within a script with
- REGION_ALIAS (alias, region_name). Each name corresponds to at most one
- region. */
-
-static lang_memory_region_type *lang_memory_region_list;
-static lang_memory_region_type **lang_memory_region_list_tail
- = &lang_memory_region_list;
-
-lang_memory_region_type *
-lang_memory_region_lookup (const char *const name, bool create)
-{
- lang_memory_region_name *n;
- lang_memory_region_type *r;
- lang_memory_region_type *new_region;
-
- /* NAME is NULL for LMA memspecs if no region was specified. */
- if (name == NULL)
- return NULL;
-
- for (r = lang_memory_region_list; r != NULL; r = r->next)
- for (n = &r->name_list; n != NULL; n = n->next)
- if (strcmp (n->name, name) == 0)
- {
- if (create)
- einfo (_("%P:%pS: warning: redeclaration of memory region `%s'\n"),
- NULL, name);
- return r;
- }
-
- if (!create && strcmp (name, DEFAULT_MEMORY_REGION))
- einfo (_("%P:%pS: warning: memory region `%s' not declared\n"),
- NULL, name);
-
- new_region = stat_alloc (sizeof (lang_memory_region_type));
-
- new_region->name_list.name = xstrdup (name);
- new_region->name_list.next = NULL;
- new_region->next = NULL;
- new_region->origin_exp = NULL;
- new_region->origin = 0;
- new_region->length_exp = NULL;
- new_region->length = ~(bfd_size_type) 0;
- new_region->current = 0;
- new_region->last_os = NULL;
- new_region->flags = 0;
- new_region->not_flags = 0;
- new_region->had_full_message = false;
-
- *lang_memory_region_list_tail = new_region;
- lang_memory_region_list_tail = &new_region->next;
-
- return new_region;
-}
-
-void
-lang_memory_region_alias (const char *alias, const char *region_name)
-{
- lang_memory_region_name *n;
- lang_memory_region_type *r;
- lang_memory_region_type *region;
-
- /* The default region must be unique. This ensures that it is not necessary
- to iterate through the name list if someone wants the check if a region is
- the default memory region. */
- if (strcmp (region_name, DEFAULT_MEMORY_REGION) == 0
- || strcmp (alias, DEFAULT_MEMORY_REGION) == 0)
- einfo (_("%F%P:%pS: error: alias for default memory region\n"), NULL);
-
- /* Look for the target region and check if the alias is not already
- in use. */
- region = NULL;
- for (r = lang_memory_region_list; r != NULL; r = r->next)
- for (n = &r->name_list; n != NULL; n = n->next)
- {
- if (region == NULL && strcmp (n->name, region_name) == 0)
- region = r;
- if (strcmp (n->name, alias) == 0)
- einfo (_("%F%P:%pS: error: redefinition of memory region "
- "alias `%s'\n"),
- NULL, alias);
- }
-
- /* Check if the target region exists. */
- if (region == NULL)
- einfo (_("%F%P:%pS: error: memory region `%s' "
- "for alias `%s' does not exist\n"),
- NULL, region_name, alias);
-
- /* Add alias to region name list. */
- n = stat_alloc (sizeof (lang_memory_region_name));
- n->name = xstrdup (alias);
- n->next = region->name_list.next;
- region->name_list.next = n;
-}
-
-static lang_memory_region_type *
-lang_memory_default (asection *section)
-{
- lang_memory_region_type *p;
-
- flagword sec_flags = section->flags;
-
- /* Override SEC_DATA to mean a writable section. */
- if ((sec_flags & (SEC_ALLOC | SEC_READONLY | SEC_CODE)) == SEC_ALLOC)
- sec_flags |= SEC_DATA;
-
- for (p = lang_memory_region_list; p != NULL; p = p->next)
- {
- if ((p->flags & sec_flags) != 0
- && (p->not_flags & sec_flags) == 0)
- {
- return p;
- }
- }
- return lang_memory_region_lookup (DEFAULT_MEMORY_REGION, false);
-}
-
-/* Get the output section statement directly from the userdata. */
-
-lang_output_section_statement_type *
-lang_output_section_get (const asection *output_section)
-{
- return bfd_section_userdata (output_section);
-}
-
-/* Find or create an output_section_statement with the given NAME.
- If CONSTRAINT is non-zero match one with that constraint, otherwise
- match any non-negative constraint. If CREATE is 0 return NULL when
- no match exists. If CREATE is 1, create an output_section_statement
- when no match exists or if CONSTRAINT is SPECIAL. If CREATE is 2,
- always make a new output_section_statement. */
-
-lang_output_section_statement_type *
-lang_output_section_statement_lookup (const char *name,
- int constraint,
- int create)
-{
- struct out_section_hash_entry *entry;
-
- entry = ((struct out_section_hash_entry *)
- bfd_hash_lookup (&output_section_statement_table, name,
- create != 0, false));
- if (entry == NULL)
- {
- if (create)
- einfo (_("%F%P: failed creating section `%s': %E\n"), name);
- return NULL;
- }
-
- if (entry->s.output_section_statement.name != NULL)
- {
- /* We have a section of this name, but it might not have the correct
- constraint. */
- struct out_section_hash_entry *last_ent;
-
- name = entry->s.output_section_statement.name;
- do
- {
- if (create != 2
- && !(create && constraint == SPECIAL)
- && (constraint == entry->s.output_section_statement.constraint
- || (constraint == 0
- && entry->s.output_section_statement.constraint >= 0)))
- return &entry->s.output_section_statement;
- last_ent = entry;
- entry = (struct out_section_hash_entry *) entry->root.next;
- }
- while (entry != NULL
- && name == entry->s.output_section_statement.name);
-
- if (!create)
- return NULL;
-
- entry
- = ((struct out_section_hash_entry *)
- output_section_statement_newfunc (NULL,
- &output_section_statement_table,
- name));
- if (entry == NULL)
- {
- einfo (_("%F%P: failed creating section `%s': %E\n"), name);
- return NULL;
- }
- entry->root = last_ent->root;
- last_ent->root.next = &entry->root;
- }
-
- entry->s.output_section_statement.name = name;
- entry->s.output_section_statement.constraint = constraint;
- entry->s.output_section_statement.dup_output = (create == 2
- || constraint == SPECIAL);
- return &entry->s.output_section_statement;
-}
-
-/* Find the next output_section_statement with the same name as OS.
- If CONSTRAINT is non-zero, find one with that constraint otherwise
- match any non-negative constraint. */
-
-lang_output_section_statement_type *
-next_matching_output_section_statement (lang_output_section_statement_type *os,
- int constraint)
-{
- /* All output_section_statements are actually part of a
- struct out_section_hash_entry. */
- struct out_section_hash_entry *entry = (struct out_section_hash_entry *)
- ((char *) os
- - offsetof (struct out_section_hash_entry, s.output_section_statement));
- const char *name = os->name;
-
- ASSERT (name == entry->root.string);
- do
- {
- entry = (struct out_section_hash_entry *) entry->root.next;
- if (entry == NULL
- || name != entry->s.output_section_statement.name)
- return NULL;
- }
- while (constraint != entry->s.output_section_statement.constraint
- && (constraint != 0
- || entry->s.output_section_statement.constraint < 0));
-
- return &entry->s.output_section_statement;
-}
-
-/* A variant of lang_output_section_find used by place_orphan.
- Returns the output statement that should precede a new output
- statement for SEC. If an exact match is found on certain flags,
- sets *EXACT too. */
-
-lang_output_section_statement_type *
-lang_output_section_find_by_flags (const asection *sec,
- flagword sec_flags,
- lang_output_section_statement_type **exact,
- lang_match_sec_type_func match_type)
-{
- lang_output_section_statement_type *first, *look, *found;
- flagword look_flags, differ;
-
- /* We know the first statement on this list is *ABS*. May as well
- skip it. */
- first = (void *) lang_os_list.head;
- first = first->next;
-
- /* First try for an exact match. */
- found = NULL;
- for (look = first; look; look = look->next)
- {
- look_flags = look->flags;
- if (look->bfd_section != NULL)
- {
- look_flags = look->bfd_section->flags;
- if (match_type && !match_type (link_info.output_bfd,
- look->bfd_section,
- sec->owner, sec))
- continue;
- }
- differ = look_flags ^ sec_flags;
- if (!(differ & (SEC_HAS_CONTENTS | SEC_ALLOC | SEC_LOAD | SEC_READONLY
- | SEC_CODE | SEC_SMALL_DATA | SEC_THREAD_LOCAL)))
- found = look;
- }
- if (found != NULL)
- {
- if (exact != NULL)
- *exact = found;
- return found;
- }
-
- if ((sec_flags & SEC_CODE) != 0
- && (sec_flags & SEC_ALLOC) != 0)
- {
- /* Try for a rw code section. */
- for (look = first; look; look = look->next)
- {
- look_flags = look->flags;
- if (look->bfd_section != NULL)
- {
- look_flags = look->bfd_section->flags;
- if (match_type && !match_type (link_info.output_bfd,
- look->bfd_section,
- sec->owner, sec))
- continue;
- }
- differ = look_flags ^ sec_flags;
- if (!(differ & (SEC_HAS_CONTENTS | SEC_ALLOC | SEC_LOAD
- | SEC_CODE | SEC_SMALL_DATA | SEC_THREAD_LOCAL)))
- found = look;
- }
- }
- else if ((sec_flags & SEC_READONLY) != 0
- && (sec_flags & SEC_ALLOC) != 0)
- {
- /* .rodata can go after .text, .sdata2 after .rodata. */
- for (look = first; look; look = look->next)
- {
- look_flags = look->flags;
- if (look->bfd_section != NULL)
- {
- look_flags = look->bfd_section->flags;
- if (match_type && !match_type (link_info.output_bfd,
- look->bfd_section,
- sec->owner, sec))
- continue;
- }
- differ = look_flags ^ sec_flags;
- if (!(differ & (SEC_HAS_CONTENTS | SEC_ALLOC | SEC_LOAD
- | SEC_READONLY | SEC_SMALL_DATA))
- || (!(differ & (SEC_HAS_CONTENTS | SEC_ALLOC | SEC_LOAD
- | SEC_READONLY))
- && !(look_flags & SEC_SMALL_DATA)))
- found = look;
- }
- }
- else if ((sec_flags & SEC_THREAD_LOCAL) != 0
- && (sec_flags & SEC_ALLOC) != 0)
- {
- /* .tdata can go after .data, .tbss after .tdata. Treat .tbss
- as if it were a loaded section, and don't use match_type. */
- bool seen_thread_local = false;
-
- match_type = NULL;
- for (look = first; look; look = look->next)
- {
- look_flags = look->flags;
- if (look->bfd_section != NULL)
- look_flags = look->bfd_section->flags;
-
- differ = look_flags ^ (sec_flags | SEC_LOAD | SEC_HAS_CONTENTS);
- if (!(differ & (SEC_THREAD_LOCAL | SEC_ALLOC)))
- {
- /* .tdata and .tbss must be adjacent and in that order. */
- if (!(look_flags & SEC_LOAD)
- && (sec_flags & SEC_LOAD))
- /* ..so if we're at a .tbss section and we're placing
- a .tdata section stop looking and return the
- previous section. */
- break;
- found = look;
- seen_thread_local = true;
- }
- else if (seen_thread_local)
- break;
- else if (!(differ & (SEC_HAS_CONTENTS | SEC_ALLOC | SEC_LOAD)))
- found = look;
- }
- }
- else if ((sec_flags & SEC_SMALL_DATA) != 0
- && (sec_flags & SEC_ALLOC) != 0)
- {
- /* .sdata goes after .data, .sbss after .sdata. */
- for (look = first; look; look = look->next)
- {
- look_flags = look->flags;
- if (look->bfd_section != NULL)
- {
- look_flags = look->bfd_section->flags;
- if (match_type && !match_type (link_info.output_bfd,
- look->bfd_section,
- sec->owner, sec))
- continue;
- }
- differ = look_flags ^ sec_flags;
- if (!(differ & (SEC_HAS_CONTENTS | SEC_ALLOC | SEC_LOAD
- | SEC_THREAD_LOCAL))
- || ((look_flags & SEC_SMALL_DATA)
- && !(sec_flags & SEC_HAS_CONTENTS)))
- found = look;
- }
- }
- else if ((sec_flags & SEC_HAS_CONTENTS) != 0
- && (sec_flags & SEC_ALLOC) != 0)
- {
- /* .data goes after .rodata. */
- for (look = first; look; look = look->next)
- {
- look_flags = look->flags;
- if (look->bfd_section != NULL)
- {
- look_flags = look->bfd_section->flags;
- if (match_type && !match_type (link_info.output_bfd,
- look->bfd_section,
- sec->owner, sec))
- continue;
- }
- differ = look_flags ^ sec_flags;
- if (!(differ & (SEC_HAS_CONTENTS | SEC_ALLOC | SEC_LOAD
- | SEC_SMALL_DATA | SEC_THREAD_LOCAL)))
- found = look;
- }
- }
- else if ((sec_flags & SEC_ALLOC) != 0)
- {
- /* .bss goes after any other alloc section. */
- for (look = first; look; look = look->next)
- {
- look_flags = look->flags;
- if (look->bfd_section != NULL)
- {
- look_flags = look->bfd_section->flags;
- if (match_type && !match_type (link_info.output_bfd,
- look->bfd_section,
- sec->owner, sec))
- continue;
- }
- differ = look_flags ^ sec_flags;
- if (!(differ & SEC_ALLOC))
- found = look;
- }
- }
- else
- {
- /* non-alloc go last. */
- for (look = first; look; look = look->next)
- {
- look_flags = look->flags;
- if (look->bfd_section != NULL)
- look_flags = look->bfd_section->flags;
- differ = look_flags ^ sec_flags;
- if (!(differ & SEC_DEBUGGING))
- found = look;
- }
- return found;
- }
-
- if (found || !match_type)
- return found;
-
- return lang_output_section_find_by_flags (sec, sec_flags, NULL, NULL);
-}
-
-/* Find the last output section before given output statement.
- Used by place_orphan. */
-
-static asection *
-output_prev_sec_find (lang_output_section_statement_type *os)
-{
- lang_output_section_statement_type *lookup;
-
- for (lookup = os->prev; lookup != NULL; lookup = lookup->prev)
- {
- if (lookup->constraint < 0)
- continue;
-
- if (lookup->bfd_section != NULL)
- return lookup->bfd_section;
- }
-
- return NULL;
-}
-
-/* Look for a suitable place for a new output section statement. The
- idea is to skip over anything that might be inside a SECTIONS {}
- statement in a script, before we find another output section
- statement. Assignments to "dot" before an output section statement
- are assumed to belong to it, except in two cases; The first
- assignment to dot, and assignments before non-alloc sections.
- Otherwise we might put an orphan before . = . + SIZEOF_HEADERS or
- similar assignments that set the initial address, or we might
- insert non-alloc note sections among assignments setting end of
- image symbols. */
-
-static lang_statement_union_type **
-insert_os_after (lang_statement_union_type *after)
-{
- lang_statement_union_type **where;
- lang_statement_union_type **assign = NULL;
- bool ignore_first;
-
- ignore_first = after == lang_os_list.head;
-
- for (where = &after->header.next;
- *where != NULL;
- where = &(*where)->header.next)
- {
- switch ((*where)->header.type)
- {
- case lang_assignment_statement_enum:
- if (assign == NULL)
- {
- lang_assignment_statement_type *ass;
-
- ass = &(*where)->assignment_statement;
- if (ass->exp->type.node_class != etree_assert
- && ass->exp->assign.dst[0] == '.'
- && ass->exp->assign.dst[1] == 0)
- {
- if (!ignore_first)
- assign = where;
- ignore_first = false;
- }
- }
- continue;
- case lang_wild_statement_enum:
- case lang_input_section_enum:
- case lang_object_symbols_statement_enum:
- case lang_fill_statement_enum:
- case lang_data_statement_enum:
- case lang_reloc_statement_enum:
- case lang_padding_statement_enum:
- case lang_constructors_statement_enum:
- assign = NULL;
- ignore_first = false;
- continue;
- case lang_output_section_statement_enum:
- if (assign != NULL)
- {
- asection *s = (*where)->output_section_statement.bfd_section;
-
- if (s == NULL
- || s->map_head.s == NULL
- || (s->flags & SEC_ALLOC) != 0)
- where = assign;
- }
- break;
- case lang_input_statement_enum:
- case lang_address_statement_enum:
- case lang_target_statement_enum:
- case lang_output_statement_enum:
- case lang_group_statement_enum:
- case lang_insert_statement_enum:
- continue;
- case lang_input_matcher_enum:
- FAIL ();
- }
- break;
- }
-
- return where;
-}
-
-lang_output_section_statement_type *
-lang_insert_orphan (asection *s,
- const char *secname,
- int constraint,
- lang_output_section_statement_type *after,
- struct orphan_save *place,
- etree_type *address,
- lang_statement_list_type *add_child)
-{
- lang_statement_list_type add;
- lang_output_section_statement_type *os;
- lang_output_section_statement_type **os_tail;
-
- /* If we have found an appropriate place for the output section
- statements for this orphan, add them to our own private list,
- inserting them later into the global statement list. */
- if (after != NULL)
- {
- lang_list_init (&add);
- push_stat_ptr (&add);
- }
-
- if (bfd_link_relocatable (&link_info)
- || (s->flags & (SEC_LOAD | SEC_ALLOC)) == 0)
- address = exp_intop (0);
-
- os_tail = (lang_output_section_statement_type **) lang_os_list.tail;
- os = lang_enter_output_section_statement (
- secname, address, normal_section, 0, NULL, NULL, NULL, constraint, 0);
-
- if (add_child == NULL)
- add_child = &os->children;
- lang_add_section (add_child, s, NULL, NULL, os);
-
- if (after && (s->flags & (SEC_LOAD | SEC_ALLOC)) != 0)
- {
- const char *region = (after->region
- ? after->region->name_list.name
- : DEFAULT_MEMORY_REGION);
- const char *lma_region = (after->lma_region
- ? after->lma_region->name_list.name
- : NULL);
- lang_leave_output_section_statement (NULL, region, after->phdrs,
- lma_region);
- }
- else
- lang_leave_output_section_statement (NULL, DEFAULT_MEMORY_REGION, NULL,
- NULL);
-
- /* Restore the global list pointer. */
- if (after != NULL)
- pop_stat_ptr ();
-
- if (after != NULL && os->bfd_section != NULL)
- {
- asection *snew, *as;
- bool place_after = place->stmt == NULL;
- bool insert_after = true;
-
- snew = os->bfd_section;
-
- /* Shuffle the bfd section list to make the output file look
- neater. This is really only cosmetic. */
- if (place->section == NULL
- && after != (void *) lang_os_list.head)
- {
- asection *bfd_section = after->bfd_section;
-
- /* If the output statement hasn't been used to place any input
- sections (and thus doesn't have an output bfd_section),
- look for the closest prior output statement having an
- output section. */
- if (bfd_section == NULL)
- bfd_section = output_prev_sec_find (after);
-
- if (bfd_section != NULL
- && bfd_section->owner != NULL
- && bfd_section != snew)
- place->section = &bfd_section->next;
- }
-
- if (place->section == NULL)
- place->section = &link_info.output_bfd->sections;
-
- as = *place->section;
-
- if (!as)
- {
- /* Put the section at the end of the list. */
-
- /* Unlink the section. */
- bfd_section_list_remove (link_info.output_bfd, snew);
-
- /* Now tack it back on in the right place. */
- bfd_section_list_append (link_info.output_bfd, snew);
- }
- else if ((bfd_get_flavour (link_info.output_bfd)
- == bfd_target_elf_flavour)
- && (bfd_get_flavour (s->owner)
- == bfd_target_elf_flavour)
- && ((elf_section_type (s) == SHT_NOTE
- && (s->flags & SEC_LOAD) != 0)
- || (elf_section_type (as) == SHT_NOTE
- && (as->flags & SEC_LOAD) != 0)))
- {
- /* Make sure that output note sections are grouped and sorted
- by alignments when inserting a note section or insert a
- section after a note section, */
- asection *sec;
- /* A specific section after which the output note section
- should be placed. */
- asection *after_sec;
- /* True if we need to insert the orphan section after a
- specific section to maintain output note section order. */
- bool after_sec_note = false;
-
- static asection *first_orphan_note = NULL;
-
- /* Group and sort output note section by alignments in
- ascending order. */
- after_sec = NULL;
- if (elf_section_type (s) == SHT_NOTE
- && (s->flags & SEC_LOAD) != 0)
- {
- /* Search from the beginning for the last output note
- section with equal or larger alignments. NB: Don't
- place orphan note section after non-note sections. */
-
- first_orphan_note = NULL;
- for (sec = link_info.output_bfd->sections;
- (sec != NULL
- && !bfd_is_abs_section (sec));
- sec = sec->next)
- if (sec != snew
- && elf_section_type (sec) == SHT_NOTE
- && (sec->flags & SEC_LOAD) != 0)
- {
- if (!first_orphan_note)
- first_orphan_note = sec;
- if (sec->alignment_power >= s->alignment_power)
- after_sec = sec;
- }
- else if (first_orphan_note)
- {
- /* Stop if there is non-note section after the first
- orphan note section. */
- break;
- }
-
- /* If this will be the first orphan note section, it can
- be placed at the default location. */
- after_sec_note = first_orphan_note != NULL;
- if (after_sec == NULL && after_sec_note)
- {
- /* If all output note sections have smaller
- alignments, place the section before all
- output orphan note sections. */
- after_sec = first_orphan_note;
- insert_after = false;
- }
- }
- else if (first_orphan_note)
- {
- /* Don't place non-note sections in the middle of orphan
- note sections. */
- after_sec_note = true;
- after_sec = as;
- for (sec = as->next;
- (sec != NULL
- && !bfd_is_abs_section (sec));
- sec = sec->next)
- if (elf_section_type (sec) == SHT_NOTE
- && (sec->flags & SEC_LOAD) != 0)
- after_sec = sec;
- }
-
- if (after_sec_note)
- {
- if (after_sec)
- {
- /* Search forward to insert OS after AFTER_SEC output
- statement. */
- lang_output_section_statement_type *stmt, *next;
- bool found = false;
- for (stmt = after; stmt != NULL; stmt = next)
- {
- next = stmt->next;
- if (insert_after)
- {
- if (stmt->bfd_section == after_sec)
- {
- place_after = true;
- found = true;
- after = stmt;
- break;
- }
- }
- else
- {
- /* If INSERT_AFTER is FALSE, place OS before
- AFTER_SEC output statement. */
- if (next && next->bfd_section == after_sec)
- {
- place_after = true;
- found = true;
- after = stmt;
- break;
- }
- }
- }
-
- /* Search backward to insert OS after AFTER_SEC output
- statement. */
- if (!found)
- for (stmt = after; stmt != NULL; stmt = stmt->prev)
- {
- if (insert_after)
- {
- if (stmt->bfd_section == after_sec)
- {
- place_after = true;
- after = stmt;
- break;
- }
- }
- else
- {
- /* If INSERT_AFTER is FALSE, place OS before
- AFTER_SEC output statement. */
- if (stmt->next->bfd_section == after_sec)
- {
- place_after = true;
- after = stmt;
- break;
- }
- }
- }
- }
-
- if (after_sec == NULL
- || (insert_after && after_sec->next != snew)
- || (!insert_after && after_sec->prev != snew))
- {
- /* Unlink the section. */
- bfd_section_list_remove (link_info.output_bfd, snew);
-
- /* Place SNEW after AFTER_SEC. If AFTER_SEC is NULL,
- prepend SNEW. */
- if (after_sec)
- {
- if (insert_after)
- bfd_section_list_insert_after (link_info.output_bfd,
- after_sec, snew);
- else
- bfd_section_list_insert_before (link_info.output_bfd,
- after_sec, snew);
- }
- else
- bfd_section_list_prepend (link_info.output_bfd, snew);
- }
- }
- else if (as != snew && as->prev != snew)
- {
- /* Unlink the section. */
- bfd_section_list_remove (link_info.output_bfd, snew);
-
- /* Now tack it back on in the right place. */
- bfd_section_list_insert_before (link_info.output_bfd,
- as, snew);
- }
- }
- else if (as != snew && as->prev != snew)
- {
- /* Unlink the section. */
- bfd_section_list_remove (link_info.output_bfd, snew);
-
- /* Now tack it back on in the right place. */
- bfd_section_list_insert_before (link_info.output_bfd, as, snew);
- }
-
- /* Save the end of this list. Further ophans of this type will
- follow the one we've just added. */
- place->section = &snew->next;
-
- /* The following is non-cosmetic. We try to put the output
- statements in some sort of reasonable order here, because they
- determine the final load addresses of the orphan sections.
- In addition, placing output statements in the wrong order may
- require extra segments. For instance, given a typical
- situation of all read-only sections placed in one segment and
- following that a segment containing all the read-write
- sections, we wouldn't want to place an orphan read/write
- section before or amongst the read-only ones. */
- if (add.head != NULL)
- {
- lang_output_section_statement_type *newly_added_os;
-
- /* Place OS after AFTER if AFTER_NOTE is TRUE. */
- if (place_after)
- {
- lang_statement_union_type **where;
-
- where = insert_os_after ((lang_statement_union_type *) after);
- *add.tail = *where;
- *where = add.head;
-
- place->os_tail = &after->next;
- }
- else
- {
- /* Put it after the last orphan statement we added. */
- *add.tail = *place->stmt;
- *place->stmt = add.head;
- }
-
- /* Fix the global list pointer if we happened to tack our
- new list at the tail. */
- if (*stat_ptr->tail == add.head)
- stat_ptr->tail = add.tail;
-
- /* Save the end of this list. */
- place->stmt = add.tail;
-
- /* Do the same for the list of output section statements. */
- newly_added_os = *os_tail;
- *os_tail = NULL;
- newly_added_os->prev = (lang_output_section_statement_type *)
- ((char *) place->os_tail
- - offsetof (lang_output_section_statement_type, next));
- newly_added_os->next = *place->os_tail;
- if (newly_added_os->next != NULL)
- newly_added_os->next->prev = newly_added_os;
- *place->os_tail = newly_added_os;
- place->os_tail = &newly_added_os->next;
-
- /* Fixing the global list pointer here is a little different.
- We added to the list in lang_enter_output_section_statement,
- trimmed off the new output_section_statment above when
- assigning *os_tail = NULL, but possibly added it back in
- the same place when assigning *place->os_tail. */
- if (*os_tail == NULL)
- lang_os_list.tail = (lang_statement_union_type **) os_tail;
- }
- }
- return os;
-}
-
-static void
-lang_print_asneeded (void)
-{
- struct asneeded_minfo *m;
-
- if (asneeded_list_head == NULL)
- return;
-
- minfo (_("\nAs-needed library included to satisfy reference by file (symbol)\n\n"));
-
- for (m = asneeded_list_head; m != NULL; m = m->next)
- {
- int len;
-
- minfo ("%s", m->soname);
- len = strlen (m->soname);
-
- if (len >= 29)
- {
- print_nl ();
- len = 0;
- }
- print_spaces (30 - len);
-
- if (m->ref != NULL)
- minfo ("%pB ", m->ref);
- minfo ("(%pT)\n", m->name);
- }
-}
-
-static void
-lang_map_flags (flagword flag)
-{
- if (flag & SEC_ALLOC)
- minfo ("a");
-
- if (flag & SEC_CODE)
- minfo ("x");
-
- if (flag & SEC_READONLY)
- minfo ("r");
-
- if (flag & SEC_DATA)
- minfo ("w");
-
- if (flag & SEC_LOAD)
- minfo ("l");
-}
-
-void
-lang_map (void)
-{
- lang_memory_region_type *m;
- bool dis_header_printed = false;
-
- ldfile_print_input_remaps ();
-
- LANG_FOR_EACH_INPUT_STATEMENT (file)
- {
- asection *s;
-
- if ((file->the_bfd->flags & (BFD_LINKER_CREATED | DYNAMIC)) != 0
- || file->flags.just_syms)
- continue;
-
- if (config.print_map_discarded)
- for (s = file->the_bfd->sections; s != NULL; s = s->next)
- if ((s->output_section == NULL
- || s->output_section->owner != link_info.output_bfd)
- && (s->flags & (SEC_LINKER_CREATED | SEC_KEEP)) == 0)
- {
- if (! dis_header_printed)
- {
- minfo (_("\nDiscarded input sections\n\n"));
- dis_header_printed = true;
- }
-
- print_input_section (s, true);
- }
- }
- if (config.print_map_discarded && ! dis_header_printed)
- minfo (_("\nThere are no discarded input sections\n"));
-
- minfo (_("\nMemory Configuration\n\n"));
- fprintf (config.map_file, "%-16s %-18s %-18s %s\n",
- _("Name"), _("Origin"), _("Length"), _("Attributes"));
-
- for (m = lang_memory_region_list; m != NULL; m = m->next)
- {
- fprintf (config.map_file, "%-16s", m->name_list.name);
-
- char buf[32];
- bfd_sprintf_vma (link_info.output_bfd, buf, m->origin);
- fprintf (config.map_file, " 0x%-16s", buf);
- bfd_sprintf_vma (link_info.output_bfd, buf, m->length);
- fprintf (config.map_file,
- " 0x%*s", m->flags || m->not_flags ? -17 : 0, buf);
- if (m->flags)
- lang_map_flags (m->flags);
-
- if (m->not_flags)
- {
- minfo ("!");
- lang_map_flags (m->not_flags);
- }
-
- print_nl ();
- }
-
- minfo (_("\nLinker script and memory map\n\n"));
-
- if (!link_info.reduce_memory_overheads)
- {
- obstack_begin (&map_obstack, 1000);
- bfd_link_hash_traverse (link_info.hash, sort_def_symbol, 0);
- }
- expld.phase = lang_fixed_phase_enum;
- lang_statement_iteration++;
- print_statements ();
-
- ldemul_extra_map_file_text (link_info.output_bfd, &link_info,
- config.map_file);
-}
-
-static bool
-sort_def_symbol (struct bfd_link_hash_entry *hash_entry,
- void *info ATTRIBUTE_UNUSED)
-{
- if ((hash_entry->type == bfd_link_hash_defined
- || hash_entry->type == bfd_link_hash_defweak)
- && hash_entry->u.def.section->owner != link_info.output_bfd
- && hash_entry->u.def.section->owner != NULL)
- {
- input_section_userdata_type *ud;
- struct map_symbol_def *def;
-
- ud = bfd_section_userdata (hash_entry->u.def.section);
- if (!ud)
- {
- ud = stat_alloc (sizeof (*ud));
- bfd_set_section_userdata (hash_entry->u.def.section, ud);
- ud->map_symbol_def_tail = &ud->map_symbol_def_head;
- ud->map_symbol_def_count = 0;
- }
- else if (!ud->map_symbol_def_tail)
- ud->map_symbol_def_tail = &ud->map_symbol_def_head;
-
- def = (struct map_symbol_def *) obstack_alloc (&map_obstack, sizeof *def);
- def->entry = hash_entry;
- *(ud->map_symbol_def_tail) = def;
- ud->map_symbol_def_tail = &def->next;
- ud->map_symbol_def_count++;
- }
- return true;
-}
-
-/* Initialize an output section. */
-
-static void
-init_os (lang_output_section_statement_type *s, flagword flags)
-{
- if (strcmp (s->name, DISCARD_SECTION_NAME) == 0)
- einfo (_("%F%P: illegal use of `%s' section\n"), DISCARD_SECTION_NAME);
-
- if (!s->dup_output)
- s->bfd_section = bfd_get_section_by_name (link_info.output_bfd, s->name);
- if (s->bfd_section == NULL)
- s->bfd_section = bfd_make_section_anyway_with_flags (link_info.output_bfd,
- s->name, flags);
- if (s->bfd_section == NULL)
- {
- einfo (_("%F%P: output format %s cannot represent section"
- " called %s: %E\n"),
- link_info.output_bfd->xvec->name, s->name);
- }
- s->bfd_section->output_section = s->bfd_section;
- s->bfd_section->output_offset = 0;
-
- /* Set the userdata of the output section to the output section
- statement to avoid lookup. */
- bfd_set_section_userdata (s->bfd_section, s);
-
- /* If there is a base address, make sure that any sections it might
- mention are initialized. */
- if (s->addr_tree != NULL)
- exp_init_os (s->addr_tree);
-
- if (s->load_base != NULL)
- exp_init_os (s->load_base);
-
- /* If supplied an alignment, set it. */
- if (s->section_alignment != NULL)
- s->bfd_section->alignment_power = exp_get_power (s->section_alignment, s,
- "section alignment");
-}
-
-static flagword
-get_os_init_flag (lang_output_section_statement_type * os)
-{
- if (os != NULL)
- switch (os->sectype)
- {
- case readonly_section: return SEC_READONLY;
- case noload_section: return SEC_NEVER_LOAD;
- default: break;
- }
-
- return 0;
-}
-
-/* Make sure that all output sections mentioned in an expression are
- initialized. */
-
-static void
-exp_init_os (etree_type *exp)
-{
- switch (exp->type.node_class)
- {
- case etree_assign:
- case etree_provide:
- case etree_provided:
- exp_init_os (exp->assign.src);
- break;
-
- case etree_binary:
- exp_init_os (exp->binary.lhs);
- exp_init_os (exp->binary.rhs);
- break;
-
- case etree_trinary:
- exp_init_os (exp->trinary.cond);
- exp_init_os (exp->trinary.lhs);
- exp_init_os (exp->trinary.rhs);
- break;
-
- case etree_assert:
- exp_init_os (exp->assert_s.child);
- break;
-
- case etree_unary:
- exp_init_os (exp->unary.child);
- break;
-
- case etree_name:
- switch (exp->type.node_code)
- {
- case ADDR:
- case LOADADDR:
- {
- lang_output_section_statement_type *os;
-
- os = lang_output_section_find (exp->name.name);
- if (os != NULL && os->bfd_section == NULL)
- init_os (os, get_os_init_flag (os));
- }
- }
- break;
-
- default:
- break;
- }
-}
-
-static void
-section_already_linked (bfd *abfd, asection *sec, void *data)
-{
- lang_input_statement_type *entry = (lang_input_statement_type *) data;
-
- /* If we are only reading symbols from this object, then we want to
- discard all sections. */
- if (entry->flags.just_syms)
- {
- bfd_link_just_syms (abfd, sec, &link_info);
- return;
- }
-
- /* Deal with SHF_EXCLUDE ELF sections. */
- if (!bfd_link_relocatable (&link_info)
- && (abfd->flags & BFD_PLUGIN) == 0
- && (sec->flags & (SEC_GROUP | SEC_KEEP | SEC_EXCLUDE)) == SEC_EXCLUDE)
- sec->output_section = bfd_abs_section_ptr;
-
- if (!(abfd->flags & DYNAMIC))
- bfd_section_already_linked (abfd, sec, &link_info);
-}
-
-
-/* Returns true if SECTION is one we know will be discarded based on its
- section flags, otherwise returns false. */
-
-static bool
-lang_discard_section_p (asection *section)
-{
- bool discard;
- flagword flags = section->flags;
-
- /* Discard sections marked with SEC_EXCLUDE. */
- discard = (flags & SEC_EXCLUDE) != 0;
-
- /* Discard the group descriptor sections when we're finally placing the
- sections from within the group. */
- if ((flags & SEC_GROUP) != 0
- && link_info.resolve_section_groups)
- discard = true;
-
- /* Discard debugging sections if we are stripping debugging
- information. */
- if ((link_info.strip == strip_debugger || link_info.strip == strip_all)
- && (flags & SEC_DEBUGGING) != 0)
- discard = true;
-
- /* Discard non-alloc sections if we are stripping section headers. */
- else if (config.no_section_header && (flags & SEC_ALLOC) == 0)
- discard = true;
-
- return discard;
-}
-
-/* Return TRUE if SECTION is never going to be added to output statement
- OUTPUT. lang_add_section() definitely won't do anything with SECTION
- if this returns TRUE. It may do something (or not) if this returns FALSE.
-
- Can be used as early-out to filter matches. This may set
- output_section of SECTION, if it was unset, to the abs section in case
- we discover SECTION to be always discarded. This may also give
- warning messages. */
-
-static bool
-wont_add_section_p (asection *section,
- lang_output_section_statement_type *output)
-{
- bool discard;
-
- /* Is this section one we know should be discarded? */
- discard = lang_discard_section_p (section);
-
- /* Discard input sections which are assigned to a section named
- DISCARD_SECTION_NAME. */
- if (strcmp (output->name, DISCARD_SECTION_NAME) == 0)
- discard = true;
-
- if (discard)
- {
- if (section->output_section == NULL)
- {
- /* This prevents future calls from assigning this section or
- warning about it again. */
- section->output_section = bfd_abs_section_ptr;
- }
- else if (bfd_is_abs_section (section->output_section))
- ;
- else if (link_info.non_contiguous_regions_warnings)
- einfo (_("%P:%pS: warning: --enable-non-contiguous-regions makes "
- "section `%pA' from `%pB' match /DISCARD/ clause.\n"),
- NULL, section, section->owner);
-
- return true;
- }
-
- if (section->output_section != NULL)
- {
- if (!link_info.non_contiguous_regions)
- return true;
-
- /* SECTION has already been handled in a special way
- (eg. LINK_ONCE): skip it. */
- if (bfd_is_abs_section (section->output_section))
- return true;
-
- /* Already assigned to the same output section, do not process
- it again, to avoid creating loops between duplicate sections
- later. */
- if (section->output_section == output->bfd_section)
- return true;
-
- if (link_info.non_contiguous_regions_warnings && output->bfd_section)
- einfo (_("%P:%pS: warning: --enable-non-contiguous-regions may "
- "change behaviour for section `%pA' from `%pB' (assigned to "
- "%pA, but additional match: %pA)\n"),
- NULL, section, section->owner, section->output_section,
- output->bfd_section);
-
- /* SECTION has already been assigned to an output section, but
- the user allows it to be mapped to another one in case it
- overflows. We'll later update the actual output section in
- size_input_section as appropriate. */
- }
-
- return false;
-}
-
-/* The wild routines.
-
- These expand statements like *(.text) and foo.o to a list of
- explicit actions, like foo.o(.text), bar.o(.text) and
- foo.o(.text, .data). */
-
-/* Add SECTION to the output section OUTPUT. Do this by creating a
- lang_input_section statement which is placed at PTR. */
-
-void
-lang_add_section (lang_statement_list_type *ptr,
- asection *section,
- struct wildcard_list *pattern,
- struct flag_info *sflag_info,
- lang_output_section_statement_type *output)
-{
- flagword flags = section->flags;
-
- lang_input_section_type *new_section;
- bfd *abfd = link_info.output_bfd;
-
- if (wont_add_section_p (section, output))
- return;
-
- if (sflag_info)
- {
- bool keep;
-
- keep = bfd_lookup_section_flags (&link_info, sflag_info, section);
- if (!keep)
- return;
- }
-
- /* We don't copy the SEC_NEVER_LOAD flag from an input section
- to an output section, because we want to be able to include a
- SEC_NEVER_LOAD section in the middle of an otherwise loaded
- section (I don't know why we want to do this, but we do).
- build_link_order in ldwrite.c handles this case by turning
- the embedded SEC_NEVER_LOAD section into a fill. */
- flags &= ~ SEC_NEVER_LOAD;
-
- /* If final link, don't copy the SEC_LINK_ONCE flags, they've
- already been processed. One reason to do this is that on pe
- format targets, .text$foo sections go into .text and it's odd
- to see .text with SEC_LINK_ONCE set. */
- if ((flags & (SEC_LINK_ONCE | SEC_GROUP)) == (SEC_LINK_ONCE | SEC_GROUP))
- {
- if (link_info.resolve_section_groups)
- flags &= ~(SEC_LINK_ONCE | SEC_LINK_DUPLICATES | SEC_RELOC);
- else
- flags &= ~(SEC_LINK_DUPLICATES | SEC_RELOC);
- }
- else if (!bfd_link_relocatable (&link_info))
- flags &= ~(SEC_LINK_ONCE | SEC_LINK_DUPLICATES | SEC_RELOC);
-
- switch (output->sectype)
- {
- case normal_section:
- case overlay_section:
- case first_overlay_section:
- case type_section:
- break;
- case noalloc_section:
- flags &= ~SEC_ALLOC;
- break;
- case typed_readonly_section:
- case readonly_section:
- flags |= SEC_READONLY;
- break;
- case noload_section:
- flags &= ~SEC_LOAD;
- flags |= SEC_NEVER_LOAD;
- /* Unfortunately GNU ld has managed to evolve two different
- meanings to NOLOAD in scripts. ELF gets a .bss style noload,
- alloc, no contents section. All others get a noload, noalloc
- section. */
- if (bfd_get_flavour (link_info.output_bfd) == bfd_target_elf_flavour)
- flags &= ~SEC_HAS_CONTENTS;
- else
- flags &= ~SEC_ALLOC;
- break;
- }
-
- if (output->bfd_section == NULL)
- init_os (output, flags);
-
- /* If SEC_READONLY is not set in the input section, then clear
- it from the output section. */
- output->bfd_section->flags &= flags | ~SEC_READONLY;
-
- if (output->bfd_section->linker_has_input)
- {
- /* Only set SEC_READONLY flag on the first input section. */
- flags &= ~ SEC_READONLY;
-
- /* Keep SEC_MERGE and SEC_STRINGS only if they are the same. */
- if ((output->bfd_section->flags & (SEC_MERGE | SEC_STRINGS))
- != (flags & (SEC_MERGE | SEC_STRINGS))
- || ((flags & SEC_MERGE) != 0
- && output->bfd_section->entsize != section->entsize))
- {
- output->bfd_section->flags &= ~ (SEC_MERGE | SEC_STRINGS);
- flags &= ~ (SEC_MERGE | SEC_STRINGS);
- }
- }
- output->bfd_section->flags |= flags;
-
- if (!output->bfd_section->linker_has_input)
- {
- output->bfd_section->linker_has_input = 1;
- /* This must happen after flags have been updated. The output
- section may have been created before we saw its first input
- section, eg. for a data statement. */
- bfd_init_private_section_data (section->owner, section,
- link_info.output_bfd,
- output->bfd_section,
- &link_info);
- if ((flags & SEC_MERGE) != 0)
- output->bfd_section->entsize = section->entsize;
- }
-
- if ((flags & SEC_TIC54X_BLOCK) != 0
- && bfd_get_arch (section->owner) == bfd_arch_tic54x)
- {
- /* FIXME: This value should really be obtained from the bfd... */
- output->block_value = 128;
- }
-
- /* When a .ctors section is placed in .init_array it must be copied
- in reverse order. Similarly for .dtors. Set that up. */
- if (bfd_get_flavour (link_info.output_bfd) == bfd_target_elf_flavour
- && ((startswith (section->name, ".ctors")
- && strcmp (output->bfd_section->name, ".init_array") == 0)
- || (startswith (section->name, ".dtors")
- && strcmp (output->bfd_section->name, ".fini_array") == 0))
- && (section->name[6] == 0 || section->name[6] == '.'))
- section->flags |= SEC_ELF_REVERSE_COPY;
-
- if (section->alignment_power > output->bfd_section->alignment_power)
- output->bfd_section->alignment_power = section->alignment_power;
-
- section->output_section = output->bfd_section;
-
- if (!map_head_is_link_order)
- {
- asection *s = output->bfd_section->map_tail.s;
- output->bfd_section->map_tail.s = section;
- section->map_head.s = NULL;
- section->map_tail.s = s;
- if (s != NULL)
- s->map_head.s = section;
- else
- output->bfd_section->map_head.s = section;
- }
-
- /* Add a section reference to the list. */
- new_section = new_stat (lang_input_section, ptr);
- new_section->section = section;
- new_section->pattern = pattern;
-}
-
-/* Expand a wild statement for a particular FILE. SECTION may be
- NULL, in which case it is a wild card. This assumes that the
- wild statement doesn't need any sorting (of filenames or sections). */
-
-static void
-output_section_callback_nosort (lang_wild_statement_type *ptr,
- struct wildcard_list *sec ATTRIBUTE_UNUSED,
- asection *section,
- lang_input_statement_type *file ATTRIBUTE_UNUSED,
- void *output)
-{
- lang_output_section_statement_type *os;
-
- os = (lang_output_section_statement_type *) output;
-
- /* Exclude sections that match UNIQUE_SECTION_LIST. */
- if (unique_section_p (section, os))
- return;
-
- lang_add_section (&ptr->children, section, ptr->section_list,
- ptr->section_flag_list, os);
-}
-
-/* Check if all sections in a wild statement for a particular FILE
- are readonly. */
-
-static void
-check_section_callback (lang_wild_statement_type *ptr ATTRIBUTE_UNUSED,
- struct wildcard_list *sec ATTRIBUTE_UNUSED,
- asection *section,
- lang_input_statement_type *file ATTRIBUTE_UNUSED,
- void *output)
-{
- lang_output_section_statement_type *os;
-
- os = (lang_output_section_statement_type *) output;
-
- /* Exclude sections that match UNIQUE_SECTION_LIST. */
- if (unique_section_p (section, os))
- return;
-
- if (section->output_section == NULL && (section->flags & SEC_READONLY) == 0)
- os->all_input_readonly = false;
-}
-
-/* This is passed a file name which must have been seen already and
- added to the statement tree. We will see if it has been opened
- already and had its symbols read. If not then we'll read it. */
-
-static lang_input_statement_type *
-lookup_name (const char *name)
-{
- lang_input_statement_type *search;
-
- for (search = (void *) input_file_chain.head;
- search != NULL;
- search = search->next_real_file)
- {
- /* Use the local_sym_name as the name of the file that has
- already been loaded as filename might have been transformed
- via the search directory lookup mechanism. */
- const char *filename = search->local_sym_name;
-
- if (filename != NULL
- && filename_cmp (filename, name) == 0)
- break;
- }
-
- if (search == NULL)
- {
- /* Arrange to splice the input statement added by new_afile into
- statement_list after the current input_file_chain tail.
- We know input_file_chain is not an empty list, and that
- lookup_name was called via open_input_bfds. Later calls to
- lookup_name should always match an existing input_statement. */
- lang_statement_union_type **tail = stat_ptr->tail;
- lang_statement_union_type **after
- = (void *) ((char *) input_file_chain.tail
- - offsetof (lang_input_statement_type, next_real_file)
- + offsetof (lang_input_statement_type, header.next));
- lang_statement_union_type *rest = *after;
- stat_ptr->tail = after;
- search = new_afile (name, lang_input_file_is_search_file_enum,
- default_target, NULL);
- *stat_ptr->tail = rest;
- if (*tail == NULL)
- stat_ptr->tail = tail;
- }
-
- /* If we have already added this file, or this file is not real
- don't add this file. */
- if (search->flags.loaded || !search->flags.real)
- return search;
-
- if (!load_symbols (search, NULL))
- return NULL;
-
- return search;
-}
-
-/* Save LIST as a list of libraries whose symbols should not be exported. */
-
-struct excluded_lib
-{
- char *name;
- struct excluded_lib *next;
-};
-static struct excluded_lib *excluded_libs;
-
-void
-add_excluded_libs (const char *list)
-{
- const char *p = list, *end;
-
- while (*p != '\0')
- {
- struct excluded_lib *entry;
- end = strpbrk (p, ",:");
- if (end == NULL)
- end = p + strlen (p);
- entry = (struct excluded_lib *) xmalloc (sizeof (*entry));
- entry->next = excluded_libs;
- entry->name = (char *) xmalloc (end - p + 1);
- memcpy (entry->name, p, end - p);
- entry->name[end - p] = '\0';
- excluded_libs = entry;
- if (*end == '\0')
- break;
- p = end + 1;
- }
-}
-
-static void
-check_excluded_libs (bfd *abfd)
-{
- struct excluded_lib *lib = excluded_libs;
-
- while (lib)
- {
- int len = strlen (lib->name);
- const char *filename = lbasename (bfd_get_filename (abfd));
-
- if (strcmp (lib->name, "ALL") == 0)
- {
- abfd->no_export = true;
- return;
- }
-
- if (filename_ncmp (lib->name, filename, len) == 0
- && (filename[len] == '\0'
- || (filename[len] == '.' && filename[len + 1] == 'a'
- && filename[len + 2] == '\0')))
- {
- abfd->no_export = true;
- return;
- }
-
- lib = lib->next;
- }
-}
-
-/* Get the symbols for an input file. */
-
-bool
-load_symbols (lang_input_statement_type *entry,
- lang_statement_list_type *place)
-{
- char **matching;
-
- if (entry->flags.loaded)
- return true;
-
- ldfile_open_file (entry);
-
- /* Do not process further if the file was missing. */
- if (entry->flags.missing_file)
- return true;
-
- if (trace_files || verbose)
- info_msg ("%pI\n", entry);
-
- if (!bfd_check_format (entry->the_bfd, bfd_archive)
- && !bfd_check_format_matches (entry->the_bfd, bfd_object, &matching))
- {
- bfd_error_type err;
- struct lang_input_statement_flags save_flags;
- extern FILE *yyin;
-
- err = bfd_get_error ();
-
- /* See if the emulation has some special knowledge. */
- if (ldemul_unrecognized_file (entry))
- {
- if (err == bfd_error_file_ambiguously_recognized)
- free (matching);
- return true;
- }
-
- if (err == bfd_error_file_ambiguously_recognized)
- {
- char **p;
-
- einfo (_("%P: %pB: file not recognized: %E;"
- " matching formats:"), entry->the_bfd);
- for (p = matching; *p != NULL; p++)
- einfo (" %s", *p);
- free (matching);
- einfo ("%F\n");
- }
- else if (err != bfd_error_file_not_recognized
- || place == NULL)
- einfo (_("%F%P: %pB: file not recognized: %E\n"), entry->the_bfd);
-
- bfd_close (entry->the_bfd);
- entry->the_bfd = NULL;
-
- /* Try to interpret the file as a linker script. */
- save_flags = input_flags;
- ldfile_open_command_file (entry->filename);
-
- push_stat_ptr (place);
- input_flags.add_DT_NEEDED_for_regular
- = entry->flags.add_DT_NEEDED_for_regular;
- input_flags.add_DT_NEEDED_for_dynamic
- = entry->flags.add_DT_NEEDED_for_dynamic;
- input_flags.whole_archive = entry->flags.whole_archive;
- input_flags.dynamic = entry->flags.dynamic;
-
- ldfile_assumed_script = true;
- parser_input = input_script;
- current_input_file = entry->filename;
- yyparse ();
- current_input_file = NULL;
- ldfile_assumed_script = false;
-
- /* missing_file is sticky. sysrooted will already have been
- restored when seeing EOF in yyparse, but no harm to restore
- again. */
- save_flags.missing_file |= input_flags.missing_file;
- input_flags = save_flags;
- pop_stat_ptr ();
- fclose (yyin);
- yyin = NULL;
- entry->flags.loaded = true;
-
- return true;
- }
-
- if (ldemul_recognized_file (entry))
- return true;
-
- /* We don't call ldlang_add_file for an archive. Instead, the
- add_symbols entry point will call ldlang_add_file, via the
- add_archive_element callback, for each element of the archive
- which is used. */
- switch (bfd_get_format (entry->the_bfd))
- {
- default:
- break;
-
- case bfd_object:
- if (!entry->flags.reload)
- ldlang_add_file (entry);
- break;
-
- case bfd_archive:
- check_excluded_libs (entry->the_bfd);
-
- bfd_set_usrdata (entry->the_bfd, entry);
- if (entry->flags.whole_archive)
- {
- bfd *member = NULL;
- bool loaded = true;
-
- for (;;)
- {
- bfd *subsbfd;
- member = bfd_openr_next_archived_file (entry->the_bfd, member);
-
- if (member == NULL)
- break;
-
- if (!bfd_check_format (member, bfd_object))
- {
- einfo (_("%F%P: %pB: member %pB in archive is not an object\n"),
- entry->the_bfd, member);
- loaded = false;
- }
-
- subsbfd = member;
- if (!(*link_info.callbacks
- ->add_archive_element) (&link_info, member,
- "--whole-archive", &subsbfd))
- abort ();
-
- /* Potentially, the add_archive_element hook may have set a
- substitute BFD for us. */
- if (!bfd_link_add_symbols (subsbfd, &link_info))
- {
- einfo (_("%F%P: %pB: error adding symbols: %E\n"), member);
- loaded = false;
- }
- }
-
- entry->flags.loaded = loaded;
- return loaded;
- }
- break;
- }
-
- if (bfd_link_add_symbols (entry->the_bfd, &link_info))
- entry->flags.loaded = true;
- else
- einfo (_("%F%P: %pB: error adding symbols: %E\n"), entry->the_bfd);
-
- return entry->flags.loaded;
-}
-
-/* Handle a wild statement. S->FILENAME or S->SECTION_LIST or both
- may be NULL, indicating that it is a wildcard. Separate
- lang_input_section statements are created for each part of the
- expansion; they are added after the wild statement S. OUTPUT is
- the output section. */
-
-static void
-wild (lang_wild_statement_type *s,
- const char *target ATTRIBUTE_UNUSED,
- lang_output_section_statement_type *output)
-{
- struct wildcard_list *sec;
-
- if (s->filenames_sorted || s->any_specs_sorted)
- {
- lang_section_bst_type *tree;
-
- walk_wild (s, output_section_callback_sort, output);
-
- tree = s->tree;
- if (tree)
- {
- output_section_callback_tree_to_list (s, tree, output);
- s->tree = NULL;
- s->rightmost = &s->tree;
- }
- }
- else
- walk_wild (s, output_section_callback_nosort, output);
-
- if (default_common_section == NULL)
- for (sec = s->section_list; sec != NULL; sec = sec->next)
- if (sec->spec.name != NULL && strcmp (sec->spec.name, "COMMON") == 0)
- {
- /* Remember the section that common is going to in case we
- later get something which doesn't know where to put it. */
- default_common_section = output;
- break;
- }
-}
-
-/* Return TRUE iff target is the sought target. */
-
-static int
-get_target (const bfd_target *target, void *data)
-{
- const char *sought = (const char *) data;
-
- return strcmp (target->name, sought) == 0;
-}
-
-/* Like strcpy() but convert to lower case as well. */
-
-static void
-stricpy (char *dest, const char *src)
-{
- char c;
-
- while ((c = *src++) != 0)
- *dest++ = TOLOWER (c);
-
- *dest = 0;
-}
-
-/* Remove the first occurrence of needle (if any) in haystack
- from haystack. */
-
-static void
-strcut (char *haystack, const char *needle)
-{
- haystack = strstr (haystack, needle);
-
- if (haystack)
- {
- char *src;
-
- for (src = haystack + strlen (needle); *src;)
- *haystack++ = *src++;
-
- *haystack = 0;
- }
-}
-
-/* Compare two target format name strings.
- Return a value indicating how "similar" they are. */
-
-static int
-name_compare (const char *first, const char *second)
-{
- char *copy1;
- char *copy2;
- int result;
-
- copy1 = (char *) xmalloc (strlen (first) + 1);
- copy2 = (char *) xmalloc (strlen (second) + 1);
-
- /* Convert the names to lower case. */
- stricpy (copy1, first);
- stricpy (copy2, second);
-
- /* Remove size and endian strings from the name. */
- strcut (copy1, "big");
- strcut (copy1, "little");
- strcut (copy2, "big");
- strcut (copy2, "little");
-
- /* Return a value based on how many characters match,
- starting from the beginning. If both strings are
- the same then return 10 * their length. */
- for (result = 0; copy1[result] == copy2[result]; result++)
- if (copy1[result] == 0)
- {
- result *= 10;
- break;
- }
-
- free (copy1);
- free (copy2);
-
- return result;
-}
-
-/* Set by closest_target_match() below. */
-static const bfd_target *winner;
-
-/* Scan all the valid bfd targets looking for one that has the endianness
- requirement that was specified on the command line, and is the nearest
- match to the original output target. */
-
-static int
-closest_target_match (const bfd_target *target, void *data)
-{
- const bfd_target *original = (const bfd_target *) data;
-
- if (command_line.endian == ENDIAN_BIG
- && target->byteorder != BFD_ENDIAN_BIG)
- return 0;
-
- if (command_line.endian == ENDIAN_LITTLE
- && target->byteorder != BFD_ENDIAN_LITTLE)
- return 0;
-
- /* Must be the same flavour. */
- if (target->flavour != original->flavour)
- return 0;
-
- /* Ignore generic big and little endian elf vectors. */
- if (strcmp (target->name, "elf32-big") == 0
- || strcmp (target->name, "elf64-big") == 0
- || strcmp (target->name, "elf32-little") == 0
- || strcmp (target->name, "elf64-little") == 0)
- return 0;
-
- /* If we have not found a potential winner yet, then record this one. */
- if (winner == NULL)
- {
- winner = target;
- return 0;
- }
-
- /* Oh dear, we now have two potential candidates for a successful match.
- Compare their names and choose the better one. */
- if (name_compare (target->name, original->name)
- > name_compare (winner->name, original->name))
- winner = target;
-
- /* Keep on searching until wqe have checked them all. */
- return 0;
-}
-
-/* Return the BFD target format of the first input file. */
-
-static const char *
-get_first_input_target (void)
-{
- const char *target = NULL;
-
- LANG_FOR_EACH_INPUT_STATEMENT (s)
- {
- if (s->header.type == lang_input_statement_enum
- && s->flags.real)
- {
- ldfile_open_file (s);
-
- if (s->the_bfd != NULL
- && bfd_check_format (s->the_bfd, bfd_object))
- {
- target = bfd_get_target (s->the_bfd);
-
- if (target != NULL)
- break;
- }
- }
- }
-
- return target;
-}
-
-const char *
-lang_get_output_target (void)
-{
- const char *target;
-
- /* Has the user told us which output format to use? */
- if (output_target != NULL)
- return output_target;
-
- /* No - has the current target been set to something other than
- the default? */
- if (current_target != default_target && current_target != NULL)
- return current_target;
-
- /* No - can we determine the format of the first input file? */
- target = get_first_input_target ();
- if (target != NULL)
- return target;
-
- /* Failed - use the default output target. */
- return default_target;
-}
-
-/* Open the output file. */
-
-static void
-open_output (const char *name)
-{
- lang_input_statement_type *f;
- char *out = lrealpath (name);
-
- for (f = (void *) input_file_chain.head;
- f != NULL;
- f = f->next_real_file)
- if (f->flags.real)
- {
- char *in = lrealpath (f->local_sym_name);
- if (filename_cmp (in, out) == 0)
- einfo (_("%F%P: input file '%s' is the same as output file\n"),
- f->filename);
- free (in);
- }
- free (out);
-
- output_target = lang_get_output_target ();
-
- /* Has the user requested a particular endianness on the command
- line? */
- if (command_line.endian != ENDIAN_UNSET)
- {
- /* Get the chosen target. */
- const bfd_target *target
- = bfd_iterate_over_targets (get_target, (void *) output_target);
-
- /* If the target is not supported, we cannot do anything. */
- if (target != NULL)
- {
- enum bfd_endian desired_endian;
-
- if (command_line.endian == ENDIAN_BIG)
- desired_endian = BFD_ENDIAN_BIG;
- else
- desired_endian = BFD_ENDIAN_LITTLE;
-
- /* See if the target has the wrong endianness. This should
- not happen if the linker script has provided big and
- little endian alternatives, but some scrips don't do
- this. */
- if (target->byteorder != desired_endian)
- {
- /* If it does, then see if the target provides
- an alternative with the correct endianness. */
- if (target->alternative_target != NULL
- && (target->alternative_target->byteorder == desired_endian))
- output_target = target->alternative_target->name;
- else
- {
- /* Try to find a target as similar as possible to
- the default target, but which has the desired
- endian characteristic. */
- bfd_iterate_over_targets (closest_target_match,
- (void *) target);
-
- /* Oh dear - we could not find any targets that
- satisfy our requirements. */
- if (winner == NULL)
- einfo (_("%P: warning: could not find any targets"
- " that match endianness requirement\n"));
- else
- output_target = winner->name;
- }
- }
- }
- }
-
- link_info.output_bfd = bfd_openw (name, output_target);
-
- if (link_info.output_bfd == NULL)
- {
- if (bfd_get_error () == bfd_error_invalid_target)
- einfo (_("%F%P: target %s not found\n"), output_target);
-
- einfo (_("%F%P: cannot open output file %s: %E\n"), name);
- }
-
- delete_output_file_on_failure = true;
-
- if (!bfd_set_format (link_info.output_bfd, bfd_object))
- einfo (_("%F%P: %s: can not make object file: %E\n"), name);
- if (!bfd_set_arch_mach (link_info.output_bfd,
- ldfile_output_architecture,
- ldfile_output_machine))
- einfo (_("%F%P: %s: can not set architecture: %E\n"), name);
-
- link_info.hash = bfd_link_hash_table_create (link_info.output_bfd);
- if (link_info.hash == NULL)
- einfo (_("%F%P: can not create hash table: %E\n"));
-
- bfd_set_gp_size (link_info.output_bfd, g_switch_value);
-}
-
-static void
-ldlang_open_output (lang_statement_union_type *statement)
-{
- switch (statement->header.type)
- {
- case lang_output_statement_enum:
- ASSERT (link_info.output_bfd == NULL);
- open_output (statement->output_statement.name);
- ldemul_set_output_arch ();
- if (config.magic_demand_paged
- && !bfd_link_relocatable (&link_info))
- link_info.output_bfd->flags |= D_PAGED;
- else
- link_info.output_bfd->flags &= ~D_PAGED;
- if (config.text_read_only)
- link_info.output_bfd->flags |= WP_TEXT;
- else
- link_info.output_bfd->flags &= ~WP_TEXT;
- if (link_info.traditional_format)
- link_info.output_bfd->flags |= BFD_TRADITIONAL_FORMAT;
- else
- link_info.output_bfd->flags &= ~BFD_TRADITIONAL_FORMAT;
- if (config.no_section_header)
- link_info.output_bfd->flags |= BFD_NO_SECTION_HEADER;
- else
- link_info.output_bfd->flags &= ~BFD_NO_SECTION_HEADER;
- break;
-
- case lang_target_statement_enum:
- current_target = statement->target_statement.target;
- break;
- default:
- break;
- }
-}
-
-static void
-init_opb (asection *s)
-{
- unsigned int x;
-
- opb_shift = 0;
- if (bfd_get_flavour (link_info.output_bfd) == bfd_target_elf_flavour
- && s != NULL
- && (s->flags & SEC_ELF_OCTETS) != 0)
- return;
-
- x = bfd_arch_mach_octets_per_byte (ldfile_output_architecture,
- ldfile_output_machine);
- if (x > 1)
- while ((x & 1) == 0)
- {
- x >>= 1;
- ++opb_shift;
- }
- ASSERT (x == 1);
-}
-
-/* Open all the input files. */
-
-enum open_bfd_mode
- {
- OPEN_BFD_NORMAL = 0,
- OPEN_BFD_FORCE = 1,
- OPEN_BFD_RESCAN = 2
- };
-#if BFD_SUPPORTS_PLUGINS
-static lang_input_statement_type *plugin_insert = NULL;
-static struct bfd_link_hash_entry *plugin_undefs = NULL;
-#endif
-
-static void
-open_input_bfds (lang_statement_union_type *s,
- lang_output_section_statement_type *os,
- enum open_bfd_mode mode)
-{
- for (; s != NULL; s = s->header.next)
- {
- switch (s->header.type)
- {
- case lang_constructors_statement_enum:
- open_input_bfds (constructor_list.head, os, mode);
- break;
- case lang_output_section_statement_enum:
- os = &s->output_section_statement;
- open_input_bfds (os->children.head, os, mode);
- break;
- case lang_wild_statement_enum:
- /* Maybe we should load the file's symbols. */
- if ((mode & OPEN_BFD_RESCAN) == 0
- && s->wild_statement.filename
- && !wildcardp (s->wild_statement.filename)
- && !archive_path (s->wild_statement.filename))
- lookup_name (s->wild_statement.filename);
- open_input_bfds (s->wild_statement.children.head, os, mode);
- break;
- case lang_group_statement_enum:
- {
- struct bfd_link_hash_entry *undefs;
-#if BFD_SUPPORTS_PLUGINS
- lang_input_statement_type *plugin_insert_save;
-#endif
-
- /* We must continually search the entries in the group
- until no new symbols are added to the list of undefined
- symbols. */
-
- do
- {
-#if BFD_SUPPORTS_PLUGINS
- plugin_insert_save = plugin_insert;
-#endif
- undefs = link_info.hash->undefs_tail;
- open_input_bfds (s->group_statement.children.head, os,
- mode | OPEN_BFD_FORCE);
- }
- while (undefs != link_info.hash->undefs_tail
-#if BFD_SUPPORTS_PLUGINS
- /* Objects inserted by a plugin, which are loaded
- before we hit this loop, may have added new
- undefs. */
- || (plugin_insert != plugin_insert_save && plugin_undefs)
-#endif
- );
- }
- break;
- case lang_target_statement_enum:
- current_target = s->target_statement.target;
- break;
- case lang_input_statement_enum:
- if (s->input_statement.flags.real)
- {
- lang_statement_union_type **os_tail;
- lang_statement_list_type add;
- bfd *abfd;
-
- s->input_statement.target = current_target;
-
- /* If we are being called from within a group, and this
- is an archive which has already been searched, then
- force it to be researched unless the whole archive
- has been loaded already. Do the same for a rescan.
- Likewise reload --as-needed shared libs. */
- if (mode != OPEN_BFD_NORMAL
-#if BFD_SUPPORTS_PLUGINS
- && ((mode & OPEN_BFD_RESCAN) == 0
- || plugin_insert == NULL)
-#endif
- && s->input_statement.flags.loaded
- && (abfd = s->input_statement.the_bfd) != NULL
- && ((bfd_get_format (abfd) == bfd_archive
- && !s->input_statement.flags.whole_archive)
- || (bfd_get_format (abfd) == bfd_object
- && ((abfd->flags) & DYNAMIC) != 0
- && s->input_statement.flags.add_DT_NEEDED_for_regular
- && bfd_get_flavour (abfd) == bfd_target_elf_flavour
- && (elf_dyn_lib_class (abfd) & DYN_AS_NEEDED) != 0)))
- {
- s->input_statement.flags.loaded = false;
- s->input_statement.flags.reload = true;
- }
-
- os_tail = lang_os_list.tail;
- lang_list_init (&add);
-
- if (!load_symbols (&s->input_statement, &add))
- config.make_executable = false;
-
- if (add.head != NULL)
- {
- /* If this was a script with output sections then
- tack any added statements on to the end of the
- list. This avoids having to reorder the output
- section statement list. Very likely the user
- forgot -T, and whatever we do here will not meet
- naive user expectations. */
- if (os_tail != lang_os_list.tail)
- {
- einfo (_("%P: warning: %s contains output sections;"
- " did you forget -T?\n"),
- s->input_statement.filename);
- *stat_ptr->tail = add.head;
- stat_ptr->tail = add.tail;
- }
- else
- {
- *add.tail = s->header.next;
- s->header.next = add.head;
- }
- }
- }
-#if BFD_SUPPORTS_PLUGINS
- /* If we have found the point at which a plugin added new
- files, clear plugin_insert to enable archive rescan. */
- if (&s->input_statement == plugin_insert)
- plugin_insert = NULL;
-#endif
- break;
- case lang_assignment_statement_enum:
- if (s->assignment_statement.exp->type.node_class != etree_assert)
- exp_fold_tree_no_dot (s->assignment_statement.exp, os);
- break;
- default:
- break;
- }
- }
-
- /* Exit if any of the files were missing. */
- if (input_flags.missing_file)
- einfo ("%F");
-}
-
-#ifdef ENABLE_LIBCTF
-/* Emit CTF errors and warnings. fp can be NULL to report errors/warnings
- that happened specifically at CTF open time. */
-static void
-lang_ctf_errs_warnings (ctf_dict_t *fp)
-{
- ctf_next_t *i = NULL;
- char *text;
- int is_warning;
- int err;
-
- while ((text = ctf_errwarning_next (fp, &i, &is_warning, &err)) != NULL)
- {
- einfo (_("%s: %s\n"), is_warning ? _("CTF warning"): _("CTF error"),
- text);
- free (text);
- }
- if (err != ECTF_NEXT_END)
- {
- einfo (_("CTF error: cannot get CTF errors: `%s'\n"),
- ctf_errmsg (err));
- }
-
- /* `err' returns errors from the error/warning iterator in particular.
- These never assert. But if we have an fp, that could have recorded
- an assertion failure: assert if it has done so. */
- ASSERT (!fp || ctf_errno (fp) != ECTF_INTERNAL);
-}
-
-/* Open the CTF sections in the input files with libctf: if any were opened,
- create a fake input file that we'll write the merged CTF data to later
- on. */
-
-static void
-ldlang_open_ctf (void)
-{
- int any_ctf = 0;
- int err;
-
- LANG_FOR_EACH_INPUT_STATEMENT (file)
- {
- asection *sect;
-
- /* Incoming files from the compiler have a single ctf_dict_t in them
- (which is presented to us by the libctf API in a ctf_archive_t
- wrapper): files derived from a previous relocatable link have a CTF
- archive containing possibly many CTF files. */
-
- if ((file->the_ctf = ctf_bfdopen (file->the_bfd, &err)) == NULL)
- {
- if (err != ECTF_NOCTFDATA)
- {
- lang_ctf_errs_warnings (NULL);
- einfo (_("%P: warning: CTF section in %pB not loaded; "
- "its types will be discarded: %s\n"), file->the_bfd,
- ctf_errmsg (err));
- }
- continue;
- }
-
- /* Prevent the contents of this section from being written, while
- requiring the section itself to be duplicated in the output, but only
- once. */
- /* This section must exist if ctf_bfdopen() succeeded. */
- sect = bfd_get_section_by_name (file->the_bfd, ".ctf");
- sect->size = 0;
- sect->flags |= SEC_NEVER_LOAD | SEC_HAS_CONTENTS | SEC_LINKER_CREATED;
-
- if (any_ctf)
- sect->flags |= SEC_EXCLUDE;
- any_ctf = 1;
- }
-
- if (!any_ctf)
- {
- ctf_output = NULL;
- return;
- }
-
- if ((ctf_output = ctf_create (&err)) != NULL)
- return;
-
- einfo (_("%P: warning: CTF output not created: `%s'\n"),
- ctf_errmsg (err));
-
- LANG_FOR_EACH_INPUT_STATEMENT (errfile)
- ctf_close (errfile->the_ctf);
-}
-
-/* Merge together CTF sections. After this, only the symtab-dependent
- function and data object sections need adjustment. */
-
-static void
-lang_merge_ctf (void)
-{
- asection *output_sect;
- int flags = 0;
-
- if (!ctf_output)
- return;
-
- output_sect = bfd_get_section_by_name (link_info.output_bfd, ".ctf");
-
- /* If the section was discarded, don't waste time merging. */
- if (output_sect == NULL)
- {
- ctf_dict_close (ctf_output);
- ctf_output = NULL;
-
- LANG_FOR_EACH_INPUT_STATEMENT (file)
- {
- ctf_close (file->the_ctf);
- file->the_ctf = NULL;
- }
- return;
- }
-
- LANG_FOR_EACH_INPUT_STATEMENT (file)
- {
- if (!file->the_ctf)
- continue;
-
- /* Takes ownership of file->the_ctf. */
- if (ctf_link_add_ctf (ctf_output, file->the_ctf, file->filename) < 0)
- {
- einfo (_("%P: warning: CTF section in %pB cannot be linked: `%s'\n"),
- file->the_bfd, ctf_errmsg (ctf_errno (ctf_output)));
- ctf_close (file->the_ctf);
- file->the_ctf = NULL;
- continue;
- }
- }
-
- if (!config.ctf_share_duplicated)
- flags = CTF_LINK_SHARE_UNCONFLICTED;
- else
- flags = CTF_LINK_SHARE_DUPLICATED;
- if (!config.ctf_variables)
- flags |= CTF_LINK_OMIT_VARIABLES_SECTION;
- if (bfd_link_relocatable (&link_info))
- flags |= CTF_LINK_NO_FILTER_REPORTED_SYMS;
-
- if (ctf_link (ctf_output, flags) < 0)
- {
- lang_ctf_errs_warnings (ctf_output);
- einfo (_("%P: warning: CTF linking failed; "
- "output will have no CTF section: %s\n"),
- ctf_errmsg (ctf_errno (ctf_output)));
- if (output_sect)
- {
- output_sect->size = 0;
- output_sect->flags |= SEC_EXCLUDE;
- }
- }
- /* Output any lingering errors that didn't come from ctf_link. */
- lang_ctf_errs_warnings (ctf_output);
-}
-
-/* Let the emulation acquire strings from the dynamic strtab to help it optimize
- the CTF, if supported. */
-
-void
-ldlang_ctf_acquire_strings (struct elf_strtab_hash *dynstrtab)
-{
- ldemul_acquire_strings_for_ctf (ctf_output, dynstrtab);
-}
-
-/* Inform the emulation about the addition of a new dynamic symbol, in BFD
- internal format. */
-void ldlang_ctf_new_dynsym (int symidx, struct elf_internal_sym *sym)
-{
- ldemul_new_dynsym_for_ctf (ctf_output, symidx, sym);
-}
-
-/* Write out the CTF section. Called early, if the emulation isn't going to
- need to dedup against the strtab and symtab, then possibly called from the
- target linker code if the dedup has happened. */
-static void
-lang_write_ctf (int late)
-{
- size_t output_size;
- asection *output_sect;
-
- if (!ctf_output)
- return;
-
- if (late)
- {
- /* Emit CTF late if this emulation says it can do so. */
- if (ldemul_emit_ctf_early ())
- return;
- }
- else
- {
- if (!ldemul_emit_ctf_early ())
- return;
- }
-
- /* Inform the emulation that all the symbols that will be received have
- been. */
-
- ldemul_new_dynsym_for_ctf (ctf_output, 0, NULL);
-
- /* Emit CTF. */
-
- output_sect = bfd_get_section_by_name (link_info.output_bfd, ".ctf");
- if (output_sect)
- {
- output_sect->contents = ctf_link_write (ctf_output, &output_size,
- CTF_COMPRESSION_THRESHOLD);
- output_sect->size = output_size;
- output_sect->flags |= SEC_IN_MEMORY | SEC_KEEP;
-
- lang_ctf_errs_warnings (ctf_output);
- if (!output_sect->contents)
- {
- einfo (_("%P: warning: CTF section emission failed; "
- "output will have no CTF section: %s\n"),
- ctf_errmsg (ctf_errno (ctf_output)));
- output_sect->size = 0;
- output_sect->flags |= SEC_EXCLUDE;
- }
- }
-
- /* This also closes every CTF input file used in the link. */
- ctf_dict_close (ctf_output);
- ctf_output = NULL;
-
- LANG_FOR_EACH_INPUT_STATEMENT (file)
- file->the_ctf = NULL;
-}
-
-/* Write out the CTF section late, if the emulation needs that. */
-
-void
-ldlang_write_ctf_late (void)
-{
- /* Trigger a "late call", if the emulation needs one. */
-
- lang_write_ctf (1);
-}
-#else
-static void
-ldlang_open_ctf (void)
-{
- LANG_FOR_EACH_INPUT_STATEMENT (file)
- {
- asection *sect;
-
- /* If built without CTF, warn and delete all CTF sections from the output.
- (The alternative would be to simply concatenate them, which does not
- yield a valid CTF section.) */
-
- if ((sect = bfd_get_section_by_name (file->the_bfd, ".ctf")) != NULL)
- {
- einfo (_("%P: warning: CTF section in %pB not linkable: "
- "%P was built without support for CTF\n"), file->the_bfd);
- sect->size = 0;
- sect->flags |= SEC_EXCLUDE;
- }
- }
-}
-
-static void lang_merge_ctf (void) {}
-void
-ldlang_ctf_acquire_strings (struct elf_strtab_hash *dynstrtab
- ATTRIBUTE_UNUSED) {}
-void
-ldlang_ctf_new_dynsym (int symidx ATTRIBUTE_UNUSED,
- struct elf_internal_sym *sym ATTRIBUTE_UNUSED) {}
-static void lang_write_ctf (int late ATTRIBUTE_UNUSED) {}
-void ldlang_write_ctf_late (void) {}
-#endif
-
-/* Add the supplied name to the symbol table as an undefined reference.
- This is a two step process as the symbol table doesn't even exist at
- the time the ld command line is processed. First we put the name
- on a list, then, once the output file has been opened, transfer the
- name to the symbol table. */
-
-typedef struct bfd_sym_chain ldlang_undef_chain_list_type;
-
-#define ldlang_undef_chain_list_head entry_symbol.next
-
-void
-ldlang_add_undef (const char *const name, bool cmdline ATTRIBUTE_UNUSED)
-{
- ldlang_undef_chain_list_type *new_undef;
-
- new_undef = stat_alloc (sizeof (*new_undef));
- new_undef->next = ldlang_undef_chain_list_head;
- ldlang_undef_chain_list_head = new_undef;
-
- new_undef->name = xstrdup (name);
-
- if (link_info.output_bfd != NULL)
- insert_undefined (new_undef->name);
-}
-
-/* Insert NAME as undefined in the symbol table. */
-
-static void
-insert_undefined (const char *name)
-{
- struct bfd_link_hash_entry *h;
-
- h = bfd_link_hash_lookup (link_info.hash, name, true, false, true);
- if (h == NULL)
- einfo (_("%F%P: bfd_link_hash_lookup failed: %E\n"));
- if (h->type == bfd_link_hash_new)
- {
- h->type = bfd_link_hash_undefined;
- h->u.undef.abfd = NULL;
- h->non_ir_ref_regular = true;
- bfd_link_add_undef (link_info.hash, h);
- }
-}
-
-/* Run through the list of undefineds created above and place them
- into the linker hash table as undefined symbols belonging to the
- script file. */
-
-static void
-lang_place_undefineds (void)
-{
- ldlang_undef_chain_list_type *ptr;
-
- for (ptr = ldlang_undef_chain_list_head; ptr != NULL; ptr = ptr->next)
- insert_undefined (ptr->name);
-}
-
-/* Mark -u symbols against garbage collection. */
-
-static void
-lang_mark_undefineds (void)
-{
- ldlang_undef_chain_list_type *ptr;
-
- if (is_elf_hash_table (link_info.hash))
- for (ptr = ldlang_undef_chain_list_head; ptr != NULL; ptr = ptr->next)
- {
- struct elf_link_hash_entry *h = (struct elf_link_hash_entry *)
- bfd_link_hash_lookup (link_info.hash, ptr->name, false, false, true);
- if (h != NULL)
- h->mark = 1;
- }
-}
-
-/* Structure used to build the list of symbols that the user has required
- be defined. */
-
-struct require_defined_symbol
-{
- const char *name;
- struct require_defined_symbol *next;
-};
-
-/* The list of symbols that the user has required be defined. */
-
-static struct require_defined_symbol *require_defined_symbol_list;
-
-/* Add a new symbol NAME to the list of symbols that are required to be
- defined. */
-
-void
-ldlang_add_require_defined (const char *const name)
-{
- struct require_defined_symbol *ptr;
-
- ldlang_add_undef (name, true);
- ptr = stat_alloc (sizeof (*ptr));
- ptr->next = require_defined_symbol_list;
- ptr->name = strdup (name);
- require_defined_symbol_list = ptr;
-}
-
-/* Check that all symbols the user required to be defined, are defined,
- raise an error if we find a symbol that is not defined. */
-
-static void
-ldlang_check_require_defined_symbols (void)
-{
- struct require_defined_symbol *ptr;
-
- for (ptr = require_defined_symbol_list; ptr != NULL; ptr = ptr->next)
- {
- struct bfd_link_hash_entry *h;
-
- h = bfd_link_hash_lookup (link_info.hash, ptr->name,
- false, false, true);
- if (h == NULL
- || (h->type != bfd_link_hash_defined
- && h->type != bfd_link_hash_defweak))
- einfo(_("%X%P: required symbol `%s' not defined\n"), ptr->name);
- }
-}
-
-/* Check for all readonly or some readwrite sections. */
-
-static void
-check_input_sections
- (lang_statement_union_type *s,
- lang_output_section_statement_type *output_section_statement)
-{
- for (; s != NULL; s = s->header.next)
- {
- switch (s->header.type)
- {
- case lang_wild_statement_enum:
- walk_wild (&s->wild_statement, check_section_callback,
- output_section_statement);
- if (!output_section_statement->all_input_readonly)
- return;
- break;
- case lang_constructors_statement_enum:
- check_input_sections (constructor_list.head,
- output_section_statement);
- if (!output_section_statement->all_input_readonly)
- return;
- break;
- case lang_group_statement_enum:
- check_input_sections (s->group_statement.children.head,
- output_section_statement);
- if (!output_section_statement->all_input_readonly)
- return;
- break;
- default:
- break;
- }
- }
-}
-
-/* Update wildcard statements if needed. */
-
-static void
-update_wild_statements (lang_statement_union_type *s)
-{
- struct wildcard_list *sec;
-
- switch (sort_section)
- {
- default:
- FAIL ();
-
- case none:
- break;
-
- case by_name:
- case by_alignment:
- for (; s != NULL; s = s->header.next)
- {
- switch (s->header.type)
- {
- default:
- break;
-
- case lang_wild_statement_enum:
- for (sec = s->wild_statement.section_list; sec != NULL;
- sec = sec->next)
- /* Don't sort .init/.fini sections. */
- if (strcmp (sec->spec.name, ".init") != 0
- && strcmp (sec->spec.name, ".fini") != 0)
- {
- switch (sec->spec.sorted)
- {
- case none:
- sec->spec.sorted = sort_section;
- break;
- case by_name:
- if (sort_section == by_alignment)
- sec->spec.sorted = by_name_alignment;
- break;
- case by_alignment:
- if (sort_section == by_name)
- sec->spec.sorted = by_alignment_name;
- break;
- default:
- break;
- }
- s->wild_statement.any_specs_sorted = true;
- }
- break;
-
- case lang_constructors_statement_enum:
- update_wild_statements (constructor_list.head);
- break;
-
- case lang_output_section_statement_enum:
- update_wild_statements
- (s->output_section_statement.children.head);
- break;
-
- case lang_group_statement_enum:
- update_wild_statements (s->group_statement.children.head);
- break;
- }
- }
- break;
- }
-}
-
-/* Open input files and attach to output sections. */
-
-static void
-map_input_to_output_sections
- (lang_statement_union_type *s, const char *target,
- lang_output_section_statement_type *os)
-{
- for (; s != NULL; s = s->header.next)
- {
- lang_output_section_statement_type *tos;
- flagword flags;
- unsigned int type = 0;
-
- switch (s->header.type)
- {
- case lang_wild_statement_enum:
- wild (&s->wild_statement, target, os);
- break;
- case lang_constructors_statement_enum:
- map_input_to_output_sections (constructor_list.head,
- target,
- os);
- break;
- case lang_output_section_statement_enum:
- tos = &s->output_section_statement;
- if (tos->constraint == ONLY_IF_RW
- || tos->constraint == ONLY_IF_RO)
- {
- tos->all_input_readonly = true;
- check_input_sections (tos->children.head, tos);
- if (tos->all_input_readonly != (tos->constraint == ONLY_IF_RO))
- tos->constraint = -1;
- }
- if (tos->constraint >= 0)
- map_input_to_output_sections (tos->children.head,
- target,
- tos);
- break;
- case lang_output_statement_enum:
- break;
- case lang_target_statement_enum:
- target = s->target_statement.target;
- break;
- case lang_group_statement_enum:
- map_input_to_output_sections (s->group_statement.children.head,
- target,
- os);
- break;
- case lang_data_statement_enum:
- if (os == NULL)
- /* This should never happen. */
- FAIL ();
- /* Make sure that any sections mentioned in the expression
- are initialized. */
- exp_init_os (s->data_statement.exp);
- /* The output section gets CONTENTS, ALLOC and LOAD, but
- these may be overridden by the script. */
- flags = SEC_HAS_CONTENTS | SEC_ALLOC | SEC_LOAD;
- switch (os->sectype)
- {
- case normal_section:
- case overlay_section:
- case first_overlay_section:
- break;
- case noalloc_section:
- flags = SEC_HAS_CONTENTS;
- break;
- case readonly_section:
- flags |= SEC_READONLY;
- break;
- case typed_readonly_section:
- flags |= SEC_READONLY;
- /* Fall through. */
- case type_section:
- if (os->sectype_value->type.node_class == etree_name
- && os->sectype_value->type.node_code == NAME)
- {
- const char *name = os->sectype_value->name.name;
- if (strcmp (name, "SHT_PROGBITS") == 0)
- type = SHT_PROGBITS;
- else if (strcmp (name, "SHT_STRTAB") == 0)
- type = SHT_STRTAB;
- else if (strcmp (name, "SHT_NOTE") == 0)
- type = SHT_NOTE;
- else if (strcmp (name, "SHT_NOBITS") == 0)
- type = SHT_NOBITS;
- else if (strcmp (name, "SHT_INIT_ARRAY") == 0)
- type = SHT_INIT_ARRAY;
- else if (strcmp (name, "SHT_FINI_ARRAY") == 0)
- type = SHT_FINI_ARRAY;
- else if (strcmp (name, "SHT_PREINIT_ARRAY") == 0)
- type = SHT_PREINIT_ARRAY;
- else
- einfo (_ ("%F%P: invalid type for output section `%s'\n"),
- os->name);
- }
- else
- {
- exp_fold_tree_no_dot (os->sectype_value, os);
- if (expld.result.valid_p)
- type = expld.result.value;
- else
- einfo (_ ("%F%P: invalid type for output section `%s'\n"),
- os->name);
- }
- break;
- case noload_section:
- if (bfd_get_flavour (link_info.output_bfd)
- == bfd_target_elf_flavour)
- flags = SEC_NEVER_LOAD | SEC_ALLOC;
- else
- flags = SEC_NEVER_LOAD | SEC_HAS_CONTENTS;
- break;
- }
- if (os->bfd_section == NULL)
- init_os (os, flags | SEC_READONLY);
- else
- os->bfd_section->flags |= flags;
- os->bfd_section->type = type;
- break;
- case lang_input_section_enum:
- break;
- case lang_fill_statement_enum:
- case lang_object_symbols_statement_enum:
- case lang_reloc_statement_enum:
- case lang_padding_statement_enum:
- case lang_input_statement_enum:
- if (os != NULL && os->bfd_section == NULL)
- init_os (os, 0);
- break;
-
- case lang_assignment_statement_enum:
- if (os != NULL && os->bfd_section == NULL)
- init_os (os, get_os_init_flag (os));
-
- /* Make sure that any sections mentioned in the assignment
- are initialized. */
- exp_init_os (s->assignment_statement.exp);
- break;
-
- case lang_address_statement_enum:
- /* Mark the specified section with the supplied address.
- If this section was actually a segment marker, then the
- directive is ignored if the linker script explicitly
- processed the segment marker. Originally, the linker
- treated segment directives (like -Ttext on the
- command-line) as section directives. We honor the
- section directive semantics for backwards compatibility;
- linker scripts that do not specifically check for
- SEGMENT_START automatically get the old semantics. */
- if (!s->address_statement.segment
- || !s->address_statement.segment->used)
- {
- const char *name = s->address_statement.section_name;
-
- /* Create the output section statement here so that
- orphans with a set address will be placed after other
- script sections. If we let the orphan placement code
- place them in amongst other sections then the address
- will affect following script sections, which is
- likely to surprise naive users. */
- tos = lang_output_section_statement_lookup (name, 0, 1);
- tos->addr_tree = s->address_statement.address;
- if (tos->bfd_section == NULL)
- init_os (tos, 0);
- }
- break;
- case lang_insert_statement_enum:
- break;
- case lang_input_matcher_enum:
- FAIL ();
- }
- }
-}
-
-/* An insert statement snips out all the linker statements from the
- start of the list and places them after the output section
- statement specified by the insert. This operation is complicated
- by the fact that we keep a doubly linked list of output section
- statements as well as the singly linked list of all statements.
- FIXME someday: Twiddling with the list not only moves statements
- from the user's script but also input and group statements that are
- built from command line object files and --start-group. We only
- get away with this because the list pointers used by file_chain
- and input_file_chain are not reordered, and processing via
- statement_list after this point mostly ignores input statements.
- One exception is the map file, where LOAD and START GROUP/END GROUP
- can end up looking odd. */
-
-static void
-process_insert_statements (lang_statement_union_type **start)
-{
- lang_statement_union_type **s;
- lang_output_section_statement_type *first_os = NULL;
- lang_output_section_statement_type *last_os = NULL;
- lang_output_section_statement_type *os;
-
- s = start;
- while (*s != NULL)
- {
- if ((*s)->header.type == lang_output_section_statement_enum)
- {
- /* Keep pointers to the first and last output section
- statement in the sequence we may be about to move. */
- os = &(*s)->output_section_statement;
-
- ASSERT (last_os == NULL || last_os->next == os);
- last_os = os;
-
- /* Set constraint negative so that lang_output_section_find
- won't match this output section statement. At this
- stage in linking constraint has values in the range
- [-1, ONLY_IN_RW]. */
- last_os->constraint = -2 - last_os->constraint;
- if (first_os == NULL)
- first_os = last_os;
- }
- else if ((*s)->header.type == lang_group_statement_enum)
- {
- /* A user might put -T between --start-group and
- --end-group. One way this odd construct might arise is
- from a wrapper around ld to change library search
- behaviour. For example:
- #! /bin/sh
- exec real_ld --start-group "$@" --end-group
- This isn't completely unreasonable so go looking inside a
- group statement for insert statements. */
- process_insert_statements (&(*s)->group_statement.children.head);
- }
- else if ((*s)->header.type == lang_insert_statement_enum)
- {
- lang_insert_statement_type *i = &(*s)->insert_statement;
- lang_output_section_statement_type *where;
- lang_statement_union_type **ptr;
- lang_statement_union_type *first;
-
- if (link_info.non_contiguous_regions)
- {
- einfo (_("warning: INSERT statement in linker script is "
- "incompatible with --enable-non-contiguous-regions.\n"));
- }
-
- where = lang_output_section_find (i->where);
- if (where != NULL && i->is_before)
- {
- do
- where = where->prev;
- while (where != NULL && where->constraint < 0);
- }
- if (where == NULL)
- {
- einfo (_("%F%P: %s not found for insert\n"), i->where);
- return;
- }
-
- /* Deal with reordering the output section statement list. */
- if (last_os != NULL)
- {
- asection *first_sec, *last_sec;
- struct lang_output_section_statement_struct **next;
-
- /* Snip out the output sections we are moving. */
- first_os->prev->next = last_os->next;
- if (last_os->next == NULL)
- {
- next = &first_os->prev->next;
- lang_os_list.tail = (lang_statement_union_type **) next;
- }
- else
- last_os->next->prev = first_os->prev;
- /* Add them in at the new position. */
- last_os->next = where->next;
- if (where->next == NULL)
- {
- next = &last_os->next;
- lang_os_list.tail = (lang_statement_union_type **) next;
- }
- else
- where->next->prev = last_os;
- first_os->prev = where;
- where->next = first_os;
-
- /* Move the bfd sections in the same way. */
- first_sec = NULL;
- last_sec = NULL;
- for (os = first_os; os != NULL; os = os->next)
- {
- os->constraint = -2 - os->constraint;
- if (os->bfd_section != NULL
- && os->bfd_section->owner != NULL)
- {
- last_sec = os->bfd_section;
- if (first_sec == NULL)
- first_sec = last_sec;
- }
- if (os == last_os)
- break;
- }
- if (last_sec != NULL)
- {
- asection *sec = where->bfd_section;
- if (sec == NULL)
- sec = output_prev_sec_find (where);
-
- /* The place we want to insert must come after the
- sections we are moving. So if we find no
- section or if the section is the same as our
- last section, then no move is needed. */
- if (sec != NULL && sec != last_sec)
- {
- /* Trim them off. */
- if (first_sec->prev != NULL)
- first_sec->prev->next = last_sec->next;
- else
- link_info.output_bfd->sections = last_sec->next;
- if (last_sec->next != NULL)
- last_sec->next->prev = first_sec->prev;
- else
- link_info.output_bfd->section_last = first_sec->prev;
- /* Add back. */
- if (sec->owner == NULL)
- /* SEC is the absolute section, from the
- first dummy output section statement. Add
- back the sections we trimmed off to the
- start of the bfd sections. */
- sec = NULL;
- if (sec != NULL)
- last_sec->next = sec->next;
- else
- last_sec->next = link_info.output_bfd->sections;
- if (last_sec->next != NULL)
- last_sec->next->prev = last_sec;
- else
- link_info.output_bfd->section_last = last_sec;
- first_sec->prev = sec;
- if (first_sec->prev != NULL)
- first_sec->prev->next = first_sec;
- else
- link_info.output_bfd->sections = first_sec;
- }
- }
- }
-
- lang_statement_union_type *after = (void *) where;
- if (where == &lang_os_list.head->output_section_statement
- && where->next == first_os)
- {
- /* PR30155. Handle a corner case where the statement
- list is something like the following:
- . LOAD t.o
- . .data 0x0000000000000000 0x0
- . [0x0000000000000000] b = .
- . *(.data)
- . .data 0x0000000000000000 0x0 t.o
- . 0x0000000000000000 0x4 LONG 0x0
- . INSERT BEFORE .text.start
- . [0x0000000000000004] a = .
- . .text.start 0x0000000000000000 0x0
- . [0x0000000000000000] c = .
- . OUTPUT(a.out elf64-x86-64)
- Here we do not want to allow insert_os_after to
- choose a point inside the list we are moving.
- That would lose the list. Instead, let
- insert_os_after work from the INSERT, which in this
- particular example will result in inserting after
- the assignment "a = .". */
- after = *s;
- }
- ptr = insert_os_after (after);
- /* Snip everything from the start of the list, up to and
- including the insert statement we are currently processing. */
- first = *start;
- *start = (*s)->header.next;
- /* Add them back where they belong, minus the insert. */
- *s = *ptr;
- if (*s == NULL)
- statement_list.tail = s;
- *ptr = first;
- s = start;
- first_os = NULL;
- last_os = NULL;
- continue;
- }
- s = &(*s)->header.next;
- }
-
- /* Undo constraint twiddling. */
- for (os = first_os; os != NULL; os = os->next)
- {
- os->constraint = -2 - os->constraint;
- if (os == last_os)
- break;
- }
-}
-
-/* An output section might have been removed after its statement was
- added. For example, ldemul_before_allocation can remove dynamic
- sections if they turn out to be not needed. Clean them up here. */
-
-void
-strip_excluded_output_sections (void)
-{
- lang_output_section_statement_type *os;
-
- /* Run lang_size_sections (if not already done). */
- if (expld.phase != lang_mark_phase_enum)
- {
- expld.phase = lang_mark_phase_enum;
- expld.dataseg.phase = exp_seg_none;
- one_lang_size_sections_pass (NULL, false);
- lang_reset_memory_regions ();
- }
-
- for (os = (void *) lang_os_list.head;
- os != NULL;
- os = os->next)
- {
- asection *output_section;
- bool exclude;
-
- if (os->constraint < 0)
- continue;
-
- output_section = os->bfd_section;
- if (output_section == NULL)
- continue;
-
- exclude = (output_section->rawsize == 0
- && (output_section->flags & SEC_KEEP) == 0
- && !bfd_section_removed_from_list (link_info.output_bfd,
- output_section));
-
- /* Some sections have not yet been sized, notably .gnu.version,
- .dynsym, .dynstr and .hash. These all have SEC_LINKER_CREATED
- input sections, so don't drop output sections that have such
- input sections unless they are also marked SEC_EXCLUDE. */
- if (exclude && output_section->map_head.s != NULL)
- {
- asection *s;
-
- for (s = output_section->map_head.s; s != NULL; s = s->map_head.s)
- if ((s->flags & SEC_EXCLUDE) == 0
- && ((s->flags & SEC_LINKER_CREATED) != 0
- || link_info.emitrelocations))
- {
- exclude = false;
- break;
- }
- }
-
- if (exclude)
- {
- /* We don't set bfd_section to NULL since bfd_section of the
- removed output section statement may still be used. */
- if (!os->update_dot)
- os->ignored = true;
- output_section->flags |= SEC_EXCLUDE;
- bfd_section_list_remove (link_info.output_bfd, output_section);
- link_info.output_bfd->section_count--;
- }
- }
-}
-
-/* Called from ldwrite to clear out asection.map_head and
- asection.map_tail for use as link_orders in ldwrite. */
-
-void
-lang_clear_os_map (void)
-{
- lang_output_section_statement_type *os;
-
- if (map_head_is_link_order)
- return;
-
- for (os = (void *) lang_os_list.head;
- os != NULL;
- os = os->next)
- {
- asection *output_section;
-
- if (os->constraint < 0)
- continue;
-
- output_section = os->bfd_section;
- if (output_section == NULL)
- continue;
-
- /* TODO: Don't just junk map_head.s, turn them into link_orders. */
- output_section->map_head.link_order = NULL;
- output_section->map_tail.link_order = NULL;
- }
-
- /* Stop future calls to lang_add_section from messing with map_head
- and map_tail link_order fields. */
- map_head_is_link_order = true;
-}
-
-static void
-print_output_section_statement
- (lang_output_section_statement_type *output_section_statement)
-{
- asection *section = output_section_statement->bfd_section;
- int len;
-
- if (output_section_statement != abs_output_section)
- {
- minfo ("\n%s", output_section_statement->name);
-
- if (section != NULL)
- {
- print_dot = section->vma;
-
- len = strlen (output_section_statement->name);
- if (len >= SECTION_NAME_MAP_LENGTH - 1)
- {
- print_nl ();
- len = 0;
- }
- print_spaces (SECTION_NAME_MAP_LENGTH - len);
-
- minfo ("0x%V %W", section->vma, TO_ADDR (section->size));
-
- if (section->vma != section->lma)
- minfo (_(" load address 0x%V"), section->lma);
-
- if (output_section_statement->update_dot_tree != NULL)
- exp_fold_tree (output_section_statement->update_dot_tree,
- output_section_statement,
- bfd_abs_section_ptr, &print_dot);
- }
-
- print_nl ();
- }
-
- print_statement_list (output_section_statement->children.head,
- output_section_statement);
-}
-
-static void
-print_assignment (lang_assignment_statement_type *assignment,
- lang_output_section_statement_type *output_section)
-{
- bool is_dot;
- etree_type *tree;
- asection *osec;
-
- print_spaces (SECTION_NAME_MAP_LENGTH);
-
- if (assignment->exp->type.node_class == etree_assert)
- {
- is_dot = false;
- tree = assignment->exp->assert_s.child;
- }
- else
- {
- const char *dst = assignment->exp->assign.dst;
-
- is_dot = (dst[0] == '.' && dst[1] == 0);
- tree = assignment->exp;
- }
-
- osec = output_section->bfd_section;
- if (osec == NULL)
- osec = bfd_abs_section_ptr;
-
- if (assignment->exp->type.node_class != etree_provide)
- exp_fold_tree (tree, output_section, osec, &print_dot);
- else
- expld.result.valid_p = false;
-
- char buf[32];
- const char *str = buf;
- if (expld.result.valid_p)
- {
- bfd_vma value;
-
- if (assignment->exp->type.node_class == etree_assert
- || is_dot
- || expld.assign_name != NULL)
- {
- value = expld.result.value;
-
- if (expld.result.section != NULL)
- value += expld.result.section->vma;
-
- buf[0] = '0';
- buf[1] = 'x';
- bfd_sprintf_vma (link_info.output_bfd, buf + 2, value);
- if (is_dot)
- print_dot = value;
- }
- else
- {
- struct bfd_link_hash_entry *h;
-
- h = bfd_link_hash_lookup (link_info.hash, assignment->exp->assign.dst,
- false, false, true);
- if (h != NULL
- && (h->type == bfd_link_hash_defined
- || h->type == bfd_link_hash_defweak))
- {
- value = h->u.def.value;
- value += h->u.def.section->output_section->vma;
- value += h->u.def.section->output_offset;
-
- buf[0] = '[';
- buf[1] = '0';
- buf[2] = 'x';
- bfd_sprintf_vma (link_info.output_bfd, buf + 3, value);
- strcat (buf, "]");
- }
- else
- str = "[unresolved]";
- }
- }
- else
- {
- if (assignment->exp->type.node_class == etree_provide)
- str = "[!provide]";
- else
- str = "*undef*";
- }
- expld.assign_name = NULL;
-
- fprintf (config.map_file, "%-34s", str);
- exp_print_tree (assignment->exp);
- print_nl ();
-}
-
-static void
-print_input_statement (lang_input_statement_type *statm)
-{
- if (statm->filename != NULL)
- fprintf (config.map_file, "LOAD %s\n", statm->filename);
-}
-
-/* Print all symbols defined in a particular section. This is called
- via bfd_link_hash_traverse, or by print_all_symbols. */
-
-bool
-print_one_symbol (struct bfd_link_hash_entry *hash_entry, void *ptr)
-{
- asection *sec = (asection *) ptr;
-
- if ((hash_entry->type == bfd_link_hash_defined
- || hash_entry->type == bfd_link_hash_defweak)
- && sec == hash_entry->u.def.section)
- {
- print_spaces (SECTION_NAME_MAP_LENGTH);
- minfo ("0x%V ",
- (hash_entry->u.def.value
- + hash_entry->u.def.section->output_offset
- + hash_entry->u.def.section->output_section->vma));
-
- minfo (" %pT\n", hash_entry->root.string);
- }
-
- return true;
-}
-
-static int
-hash_entry_addr_cmp (const void *a, const void *b)
-{
- const struct bfd_link_hash_entry *l = *(const struct bfd_link_hash_entry **)a;
- const struct bfd_link_hash_entry *r = *(const struct bfd_link_hash_entry **)b;
-
- if (l->u.def.value < r->u.def.value)
- return -1;
- else if (l->u.def.value > r->u.def.value)
- return 1;
- else
- return 0;
-}
-
-static void
-print_all_symbols (asection *sec)
-{
- input_section_userdata_type *ud = bfd_section_userdata (sec);
- struct map_symbol_def *def;
- struct bfd_link_hash_entry **entries;
- unsigned int i;
-
- if (!ud)
- return;
-
- *ud->map_symbol_def_tail = 0;
-
- /* Sort the symbols by address. */
- entries = (struct bfd_link_hash_entry **)
- obstack_alloc (&map_obstack,
- ud->map_symbol_def_count * sizeof (*entries));
-
- for (i = 0, def = ud->map_symbol_def_head; def; def = def->next, i++)
- entries[i] = def->entry;
-
- qsort (entries, ud->map_symbol_def_count, sizeof (*entries),
- hash_entry_addr_cmp);
-
- /* Print the symbols. */
- for (i = 0; i < ud->map_symbol_def_count; i++)
- ldemul_print_symbol (entries[i], sec);
-
- obstack_free (&map_obstack, entries);
-}
-
-/* Returns TRUE if SYM is a symbol suitable for printing
- in a linker map as a local symbol. */
-
-static bool
-ld_is_local_symbol (asymbol * sym)
-{
- const char * name = bfd_asymbol_name (sym);
-
- if (name == NULL || *name == 0)
- return false;
-
- if (strcmp (name, "(null)") == 0)
- return false;
-
- /* Skip .Lxxx and such like. */
- if (bfd_is_local_label (link_info.output_bfd, sym))
- return false;
-
- /* FIXME: This is intended to skip ARM mapping symbols,
- which for some reason are not excluded by bfd_is_local_label,
- but maybe it is wrong for other architectures.
- It would be better to fix bfd_is_local_label. */
- if (*name == '$')
- return false;
-
- /* Some local symbols, eg _GLOBAL_OFFSET_TABLE_, are present
- in the hash table, so do not print duplicates here. */
- struct bfd_link_hash_entry * h;
- h = bfd_link_hash_lookup (link_info.hash, name, false /* create */,
- false /* copy */, true /* follow */);
- if (h == NULL)
- return true;
-
- /* Symbols from the plugin owned BFD will not get their own
- iteration of this function, but can be on the link_info
- list. So include them here. */
- if (h->u.def.section->owner != NULL
- && ((bfd_get_file_flags (h->u.def.section->owner) & (BFD_LINKER_CREATED | BFD_PLUGIN))
- == (BFD_LINKER_CREATED | BFD_PLUGIN)))
- return true;
-
- return false;
-}
-
-/* Print information about an input section to the map file. */
-
-static void
-print_input_section (asection *i, bool is_discarded)
-{
- bfd_size_type size = i->size;
- int len;
- bfd_vma addr;
-
- init_opb (i);
-
- minfo (" %s", i->name);
-
- len = 1 + strlen (i->name);
- if (len >= SECTION_NAME_MAP_LENGTH - 1)
- {
- print_nl ();
- len = 0;
- }
- print_spaces (SECTION_NAME_MAP_LENGTH - len);
-
- if (i->output_section != NULL
- && i->output_section->owner == link_info.output_bfd)
- addr = i->output_section->vma + i->output_offset;
- else
- {
- addr = print_dot;
- if (!is_discarded)
- size = 0;
- }
-
- char buf[32];
- bfd_sprintf_vma (link_info.output_bfd, buf, addr);
- minfo ("0x%s %W %pB\n", buf, TO_ADDR (size), i->owner);
-
- if (size != i->rawsize && i->rawsize != 0)
- {
- len = SECTION_NAME_MAP_LENGTH + 3 + strlen (buf);
- print_spaces (len);
- minfo (_("%W (size before relaxing)\n"), TO_ADDR (i->rawsize));
- }
-
- if (i->output_section != NULL
- && i->output_section->owner == link_info.output_bfd)
- {
- if (link_info.reduce_memory_overheads)
- bfd_link_hash_traverse (link_info.hash, ldemul_print_symbol, i);
- else
- print_all_symbols (i);
-
- /* Update print_dot, but make sure that we do not move it
- backwards - this could happen if we have overlays and a
- later overlay is shorter than an earier one. */
- if (addr + TO_ADDR (size) > print_dot)
- print_dot = addr + TO_ADDR (size);
-
- if (config.print_map_locals)
- {
- long storage_needed;
-
- /* FIXME: It would be better to cache this table, rather
- than recreating it for each output section. */
- /* FIXME: This call is not working for non-ELF based targets.
- Find out why. */
- storage_needed = bfd_get_symtab_upper_bound (link_info.output_bfd);
- if (storage_needed > 0)
- {
- asymbol ** symbol_table;
- long number_of_symbols;
- long j;
-
- symbol_table = xmalloc (storage_needed);
- number_of_symbols = bfd_canonicalize_symtab (link_info.output_bfd, symbol_table);
-
- for (j = 0; j < number_of_symbols; j++)
- {
- asymbol * sym = symbol_table[j];
- bfd_vma sym_addr = sym->value + i->output_section->vma;
-
- if (sym->section == i->output_section
- && (sym->flags & BSF_LOCAL) != 0
- && sym_addr >= addr
- && sym_addr < print_dot
- && ld_is_local_symbol (sym))
- {
- print_spaces (SECTION_NAME_MAP_LENGTH);
- minfo ("0x%V (local) %s\n", sym_addr, bfd_asymbol_name (sym));
- }
- }
-
- free (symbol_table);
- }
- }
- }
-}
-
-static void
-print_fill_statement (lang_fill_statement_type *fill)
-{
- size_t size;
- unsigned char *p;
- fputs (" FILL mask 0x", config.map_file);
- for (p = fill->fill->data, size = fill->fill->size; size != 0; p++, size--)
- fprintf (config.map_file, "%02x", *p);
- fputs ("\n", config.map_file);
-}
-
-static void
-print_data_statement (lang_data_statement_type *data)
-{
- bfd_vma addr;
- bfd_size_type size;
- const char *name;
-
- init_opb (data->output_section);
- print_spaces (SECTION_NAME_MAP_LENGTH);
-
- addr = data->output_offset;
- if (data->output_section != NULL)
- addr += data->output_section->vma;
-
- switch (data->type)
- {
- default:
- abort ();
- case BYTE:
- size = BYTE_SIZE;
- name = "BYTE";
- break;
- case SHORT:
- size = SHORT_SIZE;
- name = "SHORT";
- break;
- case LONG:
- size = LONG_SIZE;
- name = "LONG";
- break;
- case QUAD:
- size = QUAD_SIZE;
- name = "QUAD";
- break;
- case SQUAD:
- size = QUAD_SIZE;
- name = "SQUAD";
- break;
- }
-
- if (size < TO_SIZE ((unsigned) 1))
- size = TO_SIZE ((unsigned) 1);
- minfo ("0x%V %W %s 0x%v", addr, TO_ADDR (size), name, data->value);
-
- if (data->exp->type.node_class != etree_value)
- {
- print_space ();
- exp_print_tree (data->exp);
- }
-
- print_nl ();
-
- print_dot = addr + TO_ADDR (size);
-}
-
-/* Print an address statement. These are generated by options like
- -Ttext. */
-
-static void
-print_address_statement (lang_address_statement_type *address)
-{
- minfo (_("Address of section %s set to "), address->section_name);
- exp_print_tree (address->address);
- print_nl ();
-}
-
-/* Print a reloc statement. */
-
-static void
-print_reloc_statement (lang_reloc_statement_type *reloc)
-{
- bfd_vma addr;
- bfd_size_type size;
-
- init_opb (reloc->output_section);
- print_spaces (SECTION_NAME_MAP_LENGTH);
-
- addr = reloc->output_offset;
- if (reloc->output_section != NULL)
- addr += reloc->output_section->vma;
-
- size = bfd_get_reloc_size (reloc->howto);
-
- minfo ("0x%V %W RELOC %s ", addr, TO_ADDR (size), reloc->howto->name);
-
- if (reloc->name != NULL)
- minfo ("%s+", reloc->name);
- else
- minfo ("%s+", reloc->section->name);
-
- exp_print_tree (reloc->addend_exp);
-
- print_nl ();
-
- print_dot = addr + TO_ADDR (size);
-}
-
-static void
-print_padding_statement (lang_padding_statement_type *s)
-{
- int len;
- bfd_vma addr;
-
- init_opb (s->output_section);
- minfo (" *fill*");
-
- len = sizeof " *fill*" - 1;
- print_spaces (SECTION_NAME_MAP_LENGTH - len);
-
- addr = s->output_offset;
- if (s->output_section != NULL)
- addr += s->output_section->vma;
- minfo ("0x%V %W ", addr, TO_ADDR (s->size));
-
- if (s->fill->size != 0)
- {
- size_t size;
- unsigned char *p;
- for (p = s->fill->data, size = s->fill->size; size != 0; p++, size--)
- fprintf (config.map_file, "%02x", *p);
- }
-
- print_nl ();
-
- print_dot = addr + TO_ADDR (s->size);
-}
-
-static void
-print_wild_statement (lang_wild_statement_type *w,
- lang_output_section_statement_type *os)
-{
- struct wildcard_list *sec;
-
- print_space ();
-
- if (w->exclude_name_list)
- {
- name_list *tmp;
- minfo ("EXCLUDE_FILE(%s", w->exclude_name_list->name);
- for (tmp = w->exclude_name_list->next; tmp; tmp = tmp->next)
- minfo (" %s", tmp->name);
- minfo (") ");
- }
-
- if (w->filenames_sorted)
- minfo ("SORT_BY_NAME(");
- if (w->filenames_reversed)
- minfo ("REVERSE(");
- if (w->filename != NULL)
- minfo ("%s", w->filename);
- else
- minfo ("*");
- if (w->filenames_reversed)
- minfo (")");
- if (w->filenames_sorted)
- minfo (")");
-
- minfo ("(");
- for (sec = w->section_list; sec; sec = sec->next)
- {
- int closing_paren = 0;
-
- switch (sec->spec.sorted)
- {
- case none:
- break;
-
- case by_name:
- minfo ("SORT_BY_NAME(");
- closing_paren = 1;
- break;
-
- case by_alignment:
- minfo ("SORT_BY_ALIGNMENT(");
- closing_paren = 1;
- break;
-
- case by_name_alignment:
- minfo ("SORT_BY_NAME(SORT_BY_ALIGNMENT(");
- closing_paren = 2;
- break;
-
- case by_alignment_name:
- minfo ("SORT_BY_ALIGNMENT(SORT_BY_NAME(");
- closing_paren = 2;
- break;
-
- case by_none:
- minfo ("SORT_NONE(");
- closing_paren = 1;
- break;
-
- case by_init_priority:
- minfo ("SORT_BY_INIT_PRIORITY(");
- closing_paren = 1;
- break;
- }
-
- if (sec->spec.reversed)
- {
- minfo ("REVERSE(");
- closing_paren++;
- }
-
- if (sec->spec.exclude_name_list != NULL)
- {
- name_list *tmp;
- minfo ("EXCLUDE_FILE(%s", sec->spec.exclude_name_list->name);
- for (tmp = sec->spec.exclude_name_list->next; tmp; tmp = tmp->next)
- minfo (" %s", tmp->name);
- minfo (") ");
- }
- if (sec->spec.name != NULL)
- minfo ("%s", sec->spec.name);
- else
- minfo ("*");
- for (;closing_paren > 0; closing_paren--)
- minfo (")");
- if (sec->next)
- minfo (" ");
- }
- minfo (")");
-
- print_nl ();
-
- print_statement_list (w->children.head, os);
-}
-
-/* Print a group statement. */
-
-static void
-print_group (lang_group_statement_type *s,
- lang_output_section_statement_type *os)
-{
- fprintf (config.map_file, "START GROUP\n");
- print_statement_list (s->children.head, os);
- fprintf (config.map_file, "END GROUP\n");
-}
-
-/* Print the list of statements in S.
- This can be called for any statement type. */
-
-static void
-print_statement_list (lang_statement_union_type *s,
- lang_output_section_statement_type *os)
-{
- while (s != NULL)
- {
- print_statement (s, os);
- s = s->header.next;
- }
-}
-
-/* Print the first statement in statement list S.
- This can be called for any statement type. */
-
-static void
-print_statement (lang_statement_union_type *s,
- lang_output_section_statement_type *os)
-{
- switch (s->header.type)
- {
- default:
- fprintf (config.map_file, _("Fail with %d\n"), s->header.type);
- FAIL ();
- break;
- case lang_constructors_statement_enum:
- if (constructor_list.head != NULL)
- {
- if (constructors_sorted)
- minfo (" SORT (CONSTRUCTORS)\n");
- else
- minfo (" CONSTRUCTORS\n");
- print_statement_list (constructor_list.head, os);
- }
- break;
- case lang_wild_statement_enum:
- print_wild_statement (&s->wild_statement, os);
- break;
- case lang_address_statement_enum:
- print_address_statement (&s->address_statement);
- break;
- case lang_object_symbols_statement_enum:
- minfo (" CREATE_OBJECT_SYMBOLS\n");
- break;
- case lang_fill_statement_enum:
- print_fill_statement (&s->fill_statement);
- break;
- case lang_data_statement_enum:
- print_data_statement (&s->data_statement);
- break;
- case lang_reloc_statement_enum:
- print_reloc_statement (&s->reloc_statement);
- break;
- case lang_input_section_enum:
- print_input_section (s->input_section.section, false);
- break;
- case lang_padding_statement_enum:
- print_padding_statement (&s->padding_statement);
- break;
- case lang_output_section_statement_enum:
- print_output_section_statement (&s->output_section_statement);
- break;
- case lang_assignment_statement_enum:
- print_assignment (&s->assignment_statement, os);
- break;
- case lang_target_statement_enum:
- fprintf (config.map_file, "TARGET(%s)\n", s->target_statement.target);
- break;
- case lang_output_statement_enum:
- minfo ("OUTPUT(%s", s->output_statement.name);
- if (output_target != NULL)
- minfo (" %s", output_target);
- minfo (")\n");
- break;
- case lang_input_statement_enum:
- print_input_statement (&s->input_statement);
- break;
- case lang_group_statement_enum:
- print_group (&s->group_statement, os);
- break;
- case lang_insert_statement_enum:
- minfo ("INSERT %s %s\n",
- s->insert_statement.is_before ? "BEFORE" : "AFTER",
- s->insert_statement.where);
- break;
- }
-}
-
-static void
-print_statements (void)
-{
- print_statement_list (statement_list.head, abs_output_section);
-}
-
-/* Print the first N statements in statement list S to STDERR.
- If N == 0, nothing is printed.
- If N < 0, the entire list is printed.
- Intended to be called from GDB. */
-
-void
-dprint_statement (lang_statement_union_type *s, int n)
-{
- FILE *map_save = config.map_file;
-
- config.map_file = stderr;
-
- if (n < 0)
- print_statement_list (s, abs_output_section);
- else
- {
- while (s && --n >= 0)
- {
- print_statement (s, abs_output_section);
- s = s->header.next;
- }
- }
-
- config.map_file = map_save;
-}
-
-static void
-insert_pad (lang_statement_union_type **ptr,
- fill_type *fill,
- bfd_size_type alignment_needed,
- asection *output_section,
- bfd_vma dot)
-{
- static fill_type zero_fill;
- lang_statement_union_type *pad = NULL;
-
- if (ptr != &statement_list.head)
- pad = ((lang_statement_union_type *)
- ((char *) ptr - offsetof (lang_statement_union_type, header.next)));
- if (pad != NULL
- && pad->header.type == lang_padding_statement_enum
- && pad->padding_statement.output_section == output_section)
- {
- /* Use the existing pad statement. */
- }
- else if ((pad = *ptr) != NULL
- && pad->header.type == lang_padding_statement_enum
- && pad->padding_statement.output_section == output_section)
- {
- /* Use the existing pad statement. */
- }
- else
- {
- /* Make a new padding statement, linked into existing chain. */
- pad = stat_alloc (sizeof (lang_padding_statement_type));
- pad->header.next = *ptr;
- *ptr = pad;
- pad->header.type = lang_padding_statement_enum;
- pad->padding_statement.output_section = output_section;
- if (fill == NULL)
- fill = &zero_fill;
- pad->padding_statement.fill = fill;
- }
- pad->padding_statement.output_offset = dot - output_section->vma;
- pad->padding_statement.size = alignment_needed;
- if (!(output_section->flags & SEC_FIXED_SIZE))
- output_section->size = TO_SIZE (dot + TO_ADDR (alignment_needed)
- - output_section->vma);
-}
-
-/* Work out how much this section will move the dot point. */
-
-static bfd_vma
-size_input_section
- (lang_statement_union_type **this_ptr,
- lang_output_section_statement_type *output_section_statement,
- fill_type *fill,
- bool *removed,
- bfd_vma dot)
-{
- lang_input_section_type *is = &((*this_ptr)->input_section);
- asection *i = is->section;
- asection *o = output_section_statement->bfd_section;
- *removed = 0;
-
- if (link_info.non_contiguous_regions)
- {
- /* If the input section I has already been successfully assigned
- to an output section other than O, don't bother with it and
- let the caller remove it from the list. Keep processing in
- case we have already handled O, because the repeated passes
- have reinitialized its size. */
- if (i->already_assigned && i->already_assigned != o)
- {
- *removed = 1;
- return dot;
- }
- }
-
- if (i->sec_info_type == SEC_INFO_TYPE_JUST_SYMS)
- i->output_offset = i->vma - o->vma;
- else if (((i->flags & SEC_EXCLUDE) != 0)
- || output_section_statement->ignored)
- i->output_offset = dot - o->vma;
- else
- {
- bfd_size_type alignment_needed;
-
- /* Align this section first to the input sections requirement,
- then to the output section's requirement. If this alignment
- is greater than any seen before, then record it too. Perform
- the alignment by inserting a magic 'padding' statement.
- We can force input section alignment within an output section
- by using SUBALIGN. The value specified overrides any alignment
- given by input sections, whether larger or smaller. */
-
- if (output_section_statement->subsection_alignment != NULL)
- o->alignment_power = i->alignment_power =
- exp_get_power (output_section_statement->subsection_alignment,
- output_section_statement,
- "subsection alignment");
-
- if (o->alignment_power < i->alignment_power)
- o->alignment_power = i->alignment_power;
-
- alignment_needed = align_power (dot, i->alignment_power) - dot;
-
- if (alignment_needed != 0)
- {
- insert_pad (this_ptr, fill, TO_SIZE (alignment_needed), o, dot);
- dot += alignment_needed;
- }
-
- if (link_info.non_contiguous_regions)
- {
- /* If I would overflow O, let the caller remove I from the
- list. */
- if (output_section_statement->region)
- {
- bfd_vma end = output_section_statement->region->origin
- + output_section_statement->region->length;
-
- if (dot + TO_ADDR (i->size) > end)
- {
- if (i->flags & SEC_LINKER_CREATED)
- einfo (_("%F%P: Output section `%pA' not large enough for "
- "the linker-created stubs section `%pA'.\n"),
- i->output_section, i);
-
- if (i->rawsize && i->rawsize != i->size)
- einfo (_("%F%P: Relaxation not supported with "
- "--enable-non-contiguous-regions (section `%pA' "
- "would overflow `%pA' after it changed size).\n"),
- i, i->output_section);
-
- *removed = 1;
- dot = end;
- i->output_section = NULL;
- return dot;
- }
- }
- }
-
- /* Remember where in the output section this input section goes. */
- i->output_offset = dot - o->vma;
-
- /* Mark how big the output section must be to contain this now. */
- dot += TO_ADDR (i->size);
- if (!(o->flags & SEC_FIXED_SIZE))
- o->size = TO_SIZE (dot - o->vma);
-
- if (link_info.non_contiguous_regions)
- {
- /* Record that I was successfully assigned to O, and update
- its actual output section too. */
- i->already_assigned = o;
- i->output_section = o;
- }
- }
-
- return dot;
-}
-
-struct check_sec
-{
- asection *sec;
- bool warned;
-};
-
-static int
-sort_sections_by_lma (const void *arg1, const void *arg2)
-{
- const asection *sec1 = ((const struct check_sec *) arg1)->sec;
- const asection *sec2 = ((const struct check_sec *) arg2)->sec;
-
- if (sec1->lma < sec2->lma)
- return -1;
- else if (sec1->lma > sec2->lma)
- return 1;
- else if (sec1->id < sec2->id)
- return -1;
- else if (sec1->id > sec2->id)
- return 1;
-
- return 0;
-}
-
-static int
-sort_sections_by_vma (const void *arg1, const void *arg2)
-{
- const asection *sec1 = ((const struct check_sec *) arg1)->sec;
- const asection *sec2 = ((const struct check_sec *) arg2)->sec;
-
- if (sec1->vma < sec2->vma)
- return -1;
- else if (sec1->vma > sec2->vma)
- return 1;
- else if (sec1->id < sec2->id)
- return -1;
- else if (sec1->id > sec2->id)
- return 1;
-
- return 0;
-}
-
-#define IS_TBSS(s) \
- ((s->flags & (SEC_LOAD | SEC_THREAD_LOCAL)) == SEC_THREAD_LOCAL)
-
-#define IGNORE_SECTION(s) \
- ((s->flags & SEC_ALLOC) == 0 || IS_TBSS (s))
-
-/* Check to see if any allocated sections overlap with other allocated
- sections. This can happen if a linker script specifies the output
- section addresses of the two sections. Also check whether any memory
- region has overflowed. */
-
-static void
-lang_check_section_addresses (void)
-{
- asection *s, *p;
- struct check_sec *sections;
- size_t i, count;
- bfd_vma addr_mask;
- bfd_vma s_start;
- bfd_vma s_end;
- bfd_vma p_start = 0;
- bfd_vma p_end = 0;
- lang_memory_region_type *m;
- bool overlays;
-
- /* Detect address space overflow on allocated sections. */
- addr_mask = ((bfd_vma) 1 <<
- (bfd_arch_bits_per_address (link_info.output_bfd) - 1)) - 1;
- addr_mask = (addr_mask << 1) + 1;
- for (s = link_info.output_bfd->sections; s != NULL; s = s->next)
- if ((s->flags & SEC_ALLOC) != 0)
- {
- s_end = (s->vma + s->size) & addr_mask;
- if (s_end != 0 && s_end < (s->vma & addr_mask))
- einfo (_("%X%P: section %s VMA wraps around address space\n"),
- s->name);
- else
- {
- s_end = (s->lma + s->size) & addr_mask;
- if (s_end != 0 && s_end < (s->lma & addr_mask))
- einfo (_("%X%P: section %s LMA wraps around address space\n"),
- s->name);
- }
- }
-
- if (bfd_count_sections (link_info.output_bfd) <= 1)
- return;
-
- count = bfd_count_sections (link_info.output_bfd);
- sections = XNEWVEC (struct check_sec, count);
-
- /* Scan all sections in the output list. */
- count = 0;
- for (s = link_info.output_bfd->sections; s != NULL; s = s->next)
- {
- if (IGNORE_SECTION (s)
- || s->size == 0)
- continue;
-
- sections[count].sec = s;
- sections[count].warned = false;
- count++;
- }
-
- if (count <= 1)
- {
- free (sections);
- return;
- }
-
- qsort (sections, count, sizeof (*sections), sort_sections_by_lma);
-
- /* First check section LMAs. There should be no overlap of LMAs on
- loadable sections, even with overlays. */
- for (p = NULL, i = 0; i < count; i++)
- {
- s = sections[i].sec;
- init_opb (s);
- if ((s->flags & SEC_LOAD) != 0)
- {
- s_start = s->lma;
- s_end = s_start + TO_ADDR (s->size) - 1;
-
- /* Look for an overlap. We have sorted sections by lma, so
- we know that s_start >= p_start. Besides the obvious
- case of overlap when the current section starts before
- the previous one ends, we also must have overlap if the
- previous section wraps around the address space. */
- if (p != NULL
- && (s_start <= p_end
- || p_end < p_start))
- {
- einfo (_("%X%P: section %s LMA [%V,%V]"
- " overlaps section %s LMA [%V,%V]\n"),
- s->name, s_start, s_end, p->name, p_start, p_end);
- sections[i].warned = true;
- }
- p = s;
- p_start = s_start;
- p_end = s_end;
- }
- }
-
- /* If any non-zero size allocated section (excluding tbss) starts at
- exactly the same VMA as another such section, then we have
- overlays. Overlays generated by the OVERLAY keyword will have
- this property. It is possible to intentionally generate overlays
- that fail this test, but it would be unusual. */
- qsort (sections, count, sizeof (*sections), sort_sections_by_vma);
- overlays = false;
- p_start = sections[0].sec->vma;
- for (i = 1; i < count; i++)
- {
- s_start = sections[i].sec->vma;
- if (p_start == s_start)
- {
- overlays = true;
- break;
- }
- p_start = s_start;
- }
-
- /* Now check section VMAs if no overlays were detected. */
- if (!overlays)
- {
- for (p = NULL, i = 0; i < count; i++)
- {
- s = sections[i].sec;
- init_opb (s);
- s_start = s->vma;
- s_end = s_start + TO_ADDR (s->size) - 1;
-
- if (p != NULL
- && !sections[i].warned
- && (s_start <= p_end
- || p_end < p_start))
- einfo (_("%X%P: section %s VMA [%V,%V]"
- " overlaps section %s VMA [%V,%V]\n"),
- s->name, s_start, s_end, p->name, p_start, p_end);
- p = s;
- p_start = s_start;
- p_end = s_end;
- }
- }
-
- free (sections);
-
- /* If any memory region has overflowed, report by how much.
- We do not issue this diagnostic for regions that had sections
- explicitly placed outside their bounds; os_region_check's
- diagnostics are adequate for that case.
-
- FIXME: It is conceivable that m->current - (m->origin + m->length)
- might overflow a 32-bit integer. There is, alas, no way to print
- a bfd_vma quantity in decimal. */
- for (m = lang_memory_region_list; m; m = m->next)
- if (m->had_full_message)
- {
- unsigned long over = m->current - (m->origin + m->length);
- einfo (ngettext ("%X%P: region `%s' overflowed by %lu byte\n",
- "%X%P: region `%s' overflowed by %lu bytes\n",
- over),
- m->name_list.name, over);
- }
-}
-
-/* Make sure the new address is within the region. We explicitly permit the
- current address to be at the exact end of the region when the address is
- non-zero, in case the region is at the end of addressable memory and the
- calculation wraps around. */
-
-static void
-os_region_check (lang_output_section_statement_type *os,
- lang_memory_region_type *region,
- etree_type *tree,
- bfd_vma rbase)
-{
- if ((region->current < region->origin
- || (region->current - region->origin > region->length))
- && ((region->current != region->origin + region->length)
- || rbase == 0))
- {
- if (tree != NULL)
- {
- einfo (_("%X%P: address 0x%v of %pB section `%s'"
- " is not within region `%s'\n"),
- region->current,
- os->bfd_section->owner,
- os->bfd_section->name,
- region->name_list.name);
- }
- else if (!region->had_full_message)
- {
- region->had_full_message = true;
-
- einfo (_("%X%P: %pB section `%s' will not fit in region `%s'\n"),
- os->bfd_section->owner,
- os->bfd_section->name,
- region->name_list.name);
- }
- }
-}
-
-static void
-ldlang_check_relro_region (lang_statement_union_type *s)
-{
- seg_align_type *seg = &expld.dataseg;
-
- if (seg->relro == exp_seg_relro_start)
- {
- if (!seg->relro_start_stat)
- seg->relro_start_stat = s;
- else
- {
- ASSERT (seg->relro_start_stat == s);
- }
- }
- else if (seg->relro == exp_seg_relro_end)
- {
- if (!seg->relro_end_stat)
- seg->relro_end_stat = s;
- else
- {
- ASSERT (seg->relro_end_stat == s);
- }
- }
-}
-
-/* Set the sizes for all the output sections. */
-
-static bfd_vma
-lang_size_sections_1
- (lang_statement_union_type **prev,
- lang_output_section_statement_type *current_os,
- fill_type *fill,
- bfd_vma dot,
- bool *relax,
- bool check_regions)
-{
- lang_statement_union_type *s;
- lang_statement_union_type *prev_s = NULL;
- bool removed_prev_s = false;
- lang_output_section_statement_type *os = current_os;
-
- /* Size up the sections from their constituent parts. */
- for (s = *prev; s != NULL; prev_s = s, s = s->header.next)
- {
- bool removed = false;
-
- switch (s->header.type)
- {
- case lang_output_section_statement_enum:
- {
- bfd_vma newdot, after, dotdelta;
- lang_memory_region_type *r;
- int section_alignment = 0;
-
- os = &s->output_section_statement;
- init_opb (os->bfd_section);
- if (os->constraint == -1)
- break;
-
- /* FIXME: We shouldn't need to zero section vmas for ld -r
- here, in lang_insert_orphan, or in the default linker scripts.
- This is covering for coff backend linker bugs. See PR6945. */
- if (os->addr_tree == NULL
- && bfd_link_relocatable (&link_info)
- && (bfd_get_flavour (link_info.output_bfd)
- == bfd_target_coff_flavour))
- os->addr_tree = exp_intop (0);
- if (os->addr_tree != NULL)
- {
- exp_fold_tree (os->addr_tree, os, bfd_abs_section_ptr, &dot);
-
- if (expld.result.valid_p)
- {
- dot = expld.result.value;
- if (expld.result.section != NULL)
- dot += expld.result.section->vma;
- }
- else if (expld.phase != lang_mark_phase_enum)
- einfo (_("%F%P:%pS: non constant or forward reference"
- " address expression for section %s\n"),
- os->addr_tree, os->name);
- }
-
- if (os->bfd_section == NULL)
- /* This section was removed or never actually created. */
- break;
-
- /* If this is a COFF shared library section, use the size and
- address from the input section. FIXME: This is COFF
- specific; it would be cleaner if there were some other way
- to do this, but nothing simple comes to mind. */
- if (((bfd_get_flavour (link_info.output_bfd)
- == bfd_target_ecoff_flavour)
- || (bfd_get_flavour (link_info.output_bfd)
- == bfd_target_coff_flavour))
- && (os->bfd_section->flags & SEC_COFF_SHARED_LIBRARY) != 0)
- {
- asection *input;
-
- if (os->children.head == NULL
- || os->children.head->header.next != NULL
- || (os->children.head->header.type
- != lang_input_section_enum))
- einfo (_("%X%P: internal error on COFF shared library"
- " section %s\n"), os->name);
-
- input = os->children.head->input_section.section;
- bfd_set_section_vma (os->bfd_section,
- bfd_section_vma (input));
- if (!(os->bfd_section->flags & SEC_FIXED_SIZE))
- os->bfd_section->size = input->size;
- break;
- }
-
- newdot = dot;
- dotdelta = 0;
- if (bfd_is_abs_section (os->bfd_section))
- {
- /* No matter what happens, an abs section starts at zero. */
- ASSERT (os->bfd_section->vma == 0);
- }
- else
- {
- if (os->addr_tree == NULL)
- {
- /* No address specified for this section, get one
- from the region specification. */
- if (os->region == NULL
- || ((os->bfd_section->flags & (SEC_ALLOC | SEC_LOAD))
- && os->region->name_list.name[0] == '*'
- && strcmp (os->region->name_list.name,
- DEFAULT_MEMORY_REGION) == 0))
- {
- os->region = lang_memory_default (os->bfd_section);
- }
-
- /* If a loadable section is using the default memory
- region, and some non default memory regions were
- defined, issue an error message. */
- if (!os->ignored
- && !IGNORE_SECTION (os->bfd_section)
- && !bfd_link_relocatable (&link_info)
- && check_regions
- && strcmp (os->region->name_list.name,
- DEFAULT_MEMORY_REGION) == 0
- && lang_memory_region_list != NULL
- && (strcmp (lang_memory_region_list->name_list.name,
- DEFAULT_MEMORY_REGION) != 0
- || lang_memory_region_list->next != NULL)
- && lang_sizing_iteration == 1)
- {
- /* By default this is an error rather than just a
- warning because if we allocate the section to the
- default memory region we can end up creating an
- excessively large binary, or even seg faulting when
- attempting to perform a negative seek. See
- sources.redhat.com/ml/binutils/2003-04/msg00423.html
- for an example of this. This behaviour can be
- overridden by the using the --no-check-sections
- switch. */
- if (command_line.check_section_addresses)
- einfo (_("%F%P: error: no memory region specified"
- " for loadable section `%s'\n"),
- bfd_section_name (os->bfd_section));
- else
- einfo (_("%P: warning: no memory region specified"
- " for loadable section `%s'\n"),
- bfd_section_name (os->bfd_section));
- }
-
- newdot = os->region->current;
- section_alignment = os->bfd_section->alignment_power;
- }
- else
- section_alignment = exp_get_power (os->section_alignment, os,
- "section alignment");
-
- /* Align to what the section needs. */
- if (section_alignment > 0)
- {
- bfd_vma savedot = newdot;
- bfd_vma diff = 0;
-
- newdot = align_power (newdot, section_alignment);
- dotdelta = newdot - savedot;
-
- if (lang_sizing_iteration == 1)
- diff = dotdelta;
- else if (lang_sizing_iteration > 1)
- {
- /* Only report adjustments that would change
- alignment from what we have already reported. */
- diff = newdot - os->bfd_section->vma;
- if (!(diff & (((bfd_vma) 1 << section_alignment) - 1)))
- diff = 0;
- }
- if (diff != 0
- && (config.warn_section_align
- || os->addr_tree != NULL))
- einfo (_("%P: warning: "
- "start of section %s changed by %ld\n"),
- os->name, (long) diff);
- }
-
- bfd_set_section_vma (os->bfd_section, newdot);
-
- os->bfd_section->output_offset = 0;
- }
-
- lang_size_sections_1 (&os->children.head, os,
- os->fill, newdot, relax, check_regions);
-
- os->processed_vma = true;
-
- if (bfd_is_abs_section (os->bfd_section) || os->ignored)
- /* Except for some special linker created sections,
- no output section should change from zero size
- after strip_excluded_output_sections. A non-zero
- size on an ignored section indicates that some
- input section was not sized early enough. */
- ASSERT (os->bfd_section->size == 0);
- else
- {
- dot = os->bfd_section->vma;
-
- /* Put the section within the requested block size, or
- align at the block boundary. */
- after = ((dot
- + TO_ADDR (os->bfd_section->size)
- + os->block_value - 1)
- & - (bfd_vma) os->block_value);
-
- if (!(os->bfd_section->flags & SEC_FIXED_SIZE))
- os->bfd_section->size = TO_SIZE (after
- - os->bfd_section->vma);
- }
-
- /* Set section lma. */
- r = os->region;
- if (r == NULL)
- r = lang_memory_region_lookup (DEFAULT_MEMORY_REGION, false);
-
- if (os->load_base)
- {
- bfd_vma lma = exp_get_abs_int (os->load_base, 0, "load base");
- os->bfd_section->lma = lma;
- }
- else if (os->lma_region != NULL)
- {
- bfd_vma lma = os->lma_region->current;
-
- if (os->align_lma_with_input)
- lma += dotdelta;
- else
- {
- /* When LMA_REGION is the same as REGION, align the LMA
- as we did for the VMA, possibly including alignment
- from the bfd section. If a different region, then
- only align according to the value in the output
- statement. */
- if (os->lma_region != os->region)
- section_alignment = exp_get_power (os->section_alignment,
- os,
- "section alignment");
- if (section_alignment > 0)
- lma = align_power (lma, section_alignment);
- }
- os->bfd_section->lma = lma;
- }
- else if (r->last_os != NULL
- && (os->bfd_section->flags & SEC_ALLOC) != 0)
- {
- bfd_vma lma;
- asection *last;
-
- last = r->last_os->output_section_statement.bfd_section;
-
- /* A backwards move of dot should be accompanied by
- an explicit assignment to the section LMA (ie.
- os->load_base set) because backwards moves can
- create overlapping LMAs. */
- if (dot < last->vma
- && os->bfd_section->size != 0
- && dot + TO_ADDR (os->bfd_section->size) <= last->vma)
- {
- /* If dot moved backwards then leave lma equal to
- vma. This is the old default lma, which might
- just happen to work when the backwards move is
- sufficiently large. Nag if this changes anything,
- so people can fix their linker scripts. */
-
- if (last->vma != last->lma)
- einfo (_("%P: warning: dot moved backwards "
- "before `%s'\n"), os->name);
- }
- else
- {
- /* If this is an overlay, set the current lma to that
- at the end of the previous section. */
- if (os->sectype == overlay_section)
- lma = last->lma + TO_ADDR (last->size);
-
- /* Otherwise, keep the same lma to vma relationship
- as the previous section. */
- else
- lma = os->bfd_section->vma + last->lma - last->vma;
-
- if (section_alignment > 0)
- lma = align_power (lma, section_alignment);
- os->bfd_section->lma = lma;
- }
- }
- os->processed_lma = true;
-
- /* Keep track of normal sections using the default
- lma region. We use this to set the lma for
- following sections. Overlays or other linker
- script assignment to lma might mean that the
- default lma == vma is incorrect.
- To avoid warnings about dot moving backwards when using
- -Ttext, don't start tracking sections until we find one
- of non-zero size or with lma set differently to vma.
- Do this tracking before we short-cut the loop so that we
- track changes for the case where the section size is zero,
- but the lma is set differently to the vma. This is
- important, if an orphan section is placed after an
- otherwise empty output section that has an explicit lma
- set, we want that lma reflected in the orphans lma. */
- if (((!IGNORE_SECTION (os->bfd_section)
- && (os->bfd_section->size != 0
- || (r->last_os == NULL
- && os->bfd_section->vma != os->bfd_section->lma)
- || (r->last_os != NULL
- && dot >= (r->last_os->output_section_statement
- .bfd_section->vma))))
- || os->sectype == first_overlay_section)
- && os->lma_region == NULL
- && !bfd_link_relocatable (&link_info))
- r->last_os = s;
-
- if (bfd_is_abs_section (os->bfd_section) || os->ignored)
- break;
-
- /* .tbss sections effectively have zero size. */
- if (!IS_TBSS (os->bfd_section)
- || bfd_link_relocatable (&link_info))
- dotdelta = TO_ADDR (os->bfd_section->size);
- else
- dotdelta = 0;
- dot += dotdelta;
-
- if (os->update_dot_tree != 0)
- exp_fold_tree (os->update_dot_tree, os, bfd_abs_section_ptr, &dot);
-
- /* Update dot in the region ?
- We only do this if the section is going to be allocated,
- since unallocated sections do not contribute to the region's
- overall size in memory. */
- if (os->region != NULL
- && (os->bfd_section->flags & (SEC_ALLOC | SEC_LOAD)))
- {
- os->region->current = dot;
-
- if (check_regions)
- /* Make sure the new address is within the region. */
- os_region_check (os, os->region, os->addr_tree,
- os->bfd_section->vma);
-
- if (os->lma_region != NULL && os->lma_region != os->region
- && ((os->bfd_section->flags & SEC_LOAD)
- || os->align_lma_with_input))
- {
- os->lma_region->current = os->bfd_section->lma + dotdelta;
-
- if (check_regions)
- os_region_check (os, os->lma_region, NULL,
- os->bfd_section->lma);
- }
- }
- }
- break;
-
- case lang_constructors_statement_enum:
- dot = lang_size_sections_1 (&constructor_list.head, current_os,
- fill, dot, relax, check_regions);
- break;
-
- case lang_data_statement_enum:
- {
- unsigned int size = 0;
-
- s->data_statement.output_offset = dot - current_os->bfd_section->vma;
- s->data_statement.output_section = current_os->bfd_section;
-
- /* We might refer to provided symbols in the expression, and
- need to mark them as needed. */
- exp_fold_tree (s->data_statement.exp, os,
- bfd_abs_section_ptr, &dot);
-
- switch (s->data_statement.type)
- {
- default:
- abort ();
- case QUAD:
- case SQUAD:
- size = QUAD_SIZE;
- break;
- case LONG:
- size = LONG_SIZE;
- break;
- case SHORT:
- size = SHORT_SIZE;
- break;
- case BYTE:
- size = BYTE_SIZE;
- break;
- }
- if (size < TO_SIZE ((unsigned) 1))
- size = TO_SIZE ((unsigned) 1);
- dot += TO_ADDR (size);
- if (!(current_os->bfd_section->flags & SEC_FIXED_SIZE))
- current_os->bfd_section->size
- = TO_SIZE (dot - current_os->bfd_section->vma);
-
- }
- break;
-
- case lang_reloc_statement_enum:
- {
- int size;
-
- s->reloc_statement.output_offset
- = dot - current_os->bfd_section->vma;
- s->reloc_statement.output_section
- = current_os->bfd_section;
- size = bfd_get_reloc_size (s->reloc_statement.howto);
- dot += TO_ADDR (size);
- if (!(current_os->bfd_section->flags & SEC_FIXED_SIZE))
- current_os->bfd_section->size
- = TO_SIZE (dot - current_os->bfd_section->vma);
- }
- break;
-
- case lang_wild_statement_enum:
- dot = lang_size_sections_1 (&s->wild_statement.children.head,
- current_os, fill, dot, relax,
- check_regions);
- break;
-
- case lang_object_symbols_statement_enum:
- link_info.create_object_symbols_section = current_os->bfd_section;
- current_os->bfd_section->flags |= SEC_KEEP;
- break;
-
- case lang_output_statement_enum:
- case lang_target_statement_enum:
- break;
-
- case lang_input_section_enum:
- {
- asection *i;
-
- i = s->input_section.section;
- if (relax)
- {
- bool again;
-
- if (!bfd_relax_section (i->owner, i, &link_info, &again))
- einfo (_("%F%P: can't relax section: %E\n"));
- if (again)
- *relax = true;
- }
- dot = size_input_section (prev, current_os, fill, &removed, dot);
- }
- break;
-
- case lang_input_statement_enum:
- break;
-
- case lang_fill_statement_enum:
- s->fill_statement.output_section = current_os->bfd_section;
-
- fill = s->fill_statement.fill;
- break;
-
- case lang_assignment_statement_enum:
- {
- bfd_vma newdot = dot;
- etree_type *tree = s->assignment_statement.exp;
-
- expld.dataseg.relro = exp_seg_relro_none;
-
- exp_fold_tree (tree, os, current_os->bfd_section, &newdot);
-
- ldlang_check_relro_region (s);
-
- expld.dataseg.relro = exp_seg_relro_none;
-
- /* This symbol may be relative to this section. */
- if ((tree->type.node_class == etree_provided
- || tree->type.node_class == etree_assign)
- && (tree->assign.dst [0] != '.'
- || tree->assign.dst [1] != '\0'))
- current_os->update_dot = 1;
-
- if (!current_os->ignored)
- {
- if (current_os == abs_output_section)
- {
- /* If we don't have an output section, then just adjust
- the default memory address. */
- lang_memory_region_lookup (DEFAULT_MEMORY_REGION,
- false)->current = newdot;
- }
- else if (newdot != dot)
- {
- /* Insert a pad after this statement. We can't
- put the pad before when relaxing, in case the
- assignment references dot. */
- insert_pad (&s->header.next, fill, TO_SIZE (newdot - dot),
- current_os->bfd_section, dot);
-
- /* Don't neuter the pad below when relaxing. */
- s = s->header.next;
-
- /* If dot is advanced, this implies that the section
- should have space allocated to it, unless the
- user has explicitly stated that the section
- should not be allocated. */
- if (current_os->sectype != noalloc_section
- && (current_os->sectype != noload_section
- || (bfd_get_flavour (link_info.output_bfd)
- == bfd_target_elf_flavour)))
- current_os->bfd_section->flags |= SEC_ALLOC;
- }
- dot = newdot;
- }
- }
- break;
-
- case lang_padding_statement_enum:
- /* If this is the first time lang_size_sections is called,
- we won't have any padding statements. If this is the
- second or later passes when relaxing, we should allow
- padding to shrink. If padding is needed on this pass, it
- will be added back in. */
- s->padding_statement.size = 0;
-
- /* Make sure output_offset is valid. If relaxation shrinks
- the section and this pad isn't needed, it's possible to
- have output_offset larger than the final size of the
- section. bfd_set_section_contents will complain even for
- a pad size of zero. */
- s->padding_statement.output_offset
- = dot - current_os->bfd_section->vma;
- break;
-
- case lang_group_statement_enum:
- dot = lang_size_sections_1 (&s->group_statement.children.head,
- current_os, fill, dot, relax,
- check_regions);
- break;
-
- case lang_insert_statement_enum:
- break;
-
- /* We can only get here when relaxing is turned on. */
- case lang_address_statement_enum:
- break;
-
- default:
- FAIL ();
- break;
- }
-
- /* If an input section doesn't fit in the current output
- section, remove it from the list. Handle the case where we
- have to remove an input_section statement here: there is a
- special case to remove the first element of the list. */
- if (link_info.non_contiguous_regions && removed)
- {
- /* If we removed the first element during the previous
- iteration, override the loop assignment of prev_s. */
- if (removed_prev_s)
- prev_s = NULL;
-
- if (prev_s)
- {
- /* If there was a real previous input section, just skip
- the current one. */
- prev_s->header.next=s->header.next;
- s = prev_s;
- removed_prev_s = false;
- }
- else
- {
- /* Remove the first input section of the list. */
- *prev = s->header.next;
- removed_prev_s = true;
- }
-
- /* Move to next element, unless we removed the head of the
- list. */
- if (!removed_prev_s)
- prev = &s->header.next;
- }
- else
- {
- prev = &s->header.next;
- removed_prev_s = false;
- }
- }
- return dot;
-}
-
-/* Callback routine that is used in _bfd_elf_map_sections_to_segments.
- The BFD library has set NEW_SEGMENT to TRUE iff it thinks that
- CURRENT_SECTION and PREVIOUS_SECTION ought to be placed into different
- segments. We are allowed an opportunity to override this decision. */
-
-bool
-ldlang_override_segment_assignment (struct bfd_link_info *info ATTRIBUTE_UNUSED,
- bfd *abfd ATTRIBUTE_UNUSED,
- asection *current_section,
- asection *previous_section,
- bool new_segment)
-{
- lang_output_section_statement_type *cur;
- lang_output_section_statement_type *prev;
-
- /* The checks below are only necessary when the BFD library has decided
- that the two sections ought to be placed into the same segment. */
- if (new_segment)
- return true;
-
- /* Paranoia checks. */
- if (current_section == NULL || previous_section == NULL)
- return new_segment;
-
- /* If this flag is set, the target never wants code and non-code
- sections comingled in the same segment. */
- if (config.separate_code
- && ((current_section->flags ^ previous_section->flags) & SEC_CODE))
- return true;
-
- /* Find the memory regions associated with the two sections.
- We call lang_output_section_find() here rather than scanning the list
- of output sections looking for a matching section pointer because if
- we have a large number of sections then a hash lookup is faster. */
- cur = lang_output_section_find (current_section->name);
- prev = lang_output_section_find (previous_section->name);
-
- /* More paranoia. */
- if (cur == NULL || prev == NULL)
- return new_segment;
-
- /* If the regions are different then force the sections to live in
- different segments. See the email thread starting at the following
- URL for the reasons why this is necessary:
- http://sourceware.org/ml/binutils/2007-02/msg00216.html */
- return cur->region != prev->region;
-}
-
-void
-one_lang_size_sections_pass (bool *relax, bool check_regions)
-{
- lang_statement_iteration++;
- if (expld.phase != lang_mark_phase_enum)
- lang_sizing_iteration++;
- lang_size_sections_1 (&statement_list.head, abs_output_section,
- 0, 0, relax, check_regions);
-}
-
-static bool
-lang_size_segment (void)
-{
- /* If XXX_SEGMENT_ALIGN XXX_SEGMENT_END pair was seen, check whether
- a page could be saved in the data segment. */
- seg_align_type *seg = &expld.dataseg;
- bfd_vma first, last;
-
- first = -seg->base & (seg->commonpagesize - 1);
- last = seg->end & (seg->commonpagesize - 1);
- if (first && last
- && ((seg->base & ~(seg->commonpagesize - 1))
- != (seg->end & ~(seg->commonpagesize - 1)))
- && first + last <= seg->commonpagesize)
- {
- seg->phase = exp_seg_adjust;
- return true;
- }
-
- seg->phase = exp_seg_done;
- return false;
-}
-
-static bfd_vma
-lang_size_relro_segment_1 (void)
-{
- seg_align_type *seg = &expld.dataseg;
- bfd_vma relro_end, desired_end;
- asection *sec;
-
- /* Compute the expected PT_GNU_RELRO/PT_LOAD segment end. */
- relro_end = (seg->relro_end + seg->relropagesize - 1) & -seg->relropagesize;
-
- /* Adjust by the offset arg of XXX_SEGMENT_RELRO_END. */
- desired_end = relro_end - seg->relro_offset;
-
- /* For sections in the relro segment.. */
- for (sec = link_info.output_bfd->section_last; sec; sec = sec->prev)
- if ((sec->flags & SEC_ALLOC) != 0
- && sec->vma >= seg->base
- && sec->vma < seg->relro_end - seg->relro_offset)
- {
- /* Where do we want to put this section so that it ends as
- desired? */
- bfd_vma start, end, bump;
-
- end = start = sec->vma;
- if (!IS_TBSS (sec))
- end += TO_ADDR (sec->size);
- bump = desired_end - end;
- /* We'd like to increase START by BUMP, but we must heed
- alignment so the increase might be less than optimum. */
- start += bump;
- start &= ~(((bfd_vma) 1 << sec->alignment_power) - 1);
- /* This is now the desired end for the previous section. */
- desired_end = start;
- }
-
- seg->phase = exp_seg_relro_adjust;
- ASSERT (desired_end >= seg->base);
- seg->base = desired_end;
- return relro_end;
-}
-
-static bool
-lang_size_relro_segment (bool *relax, bool check_regions)
-{
- bool do_reset = false;
-
- if (link_info.relro && expld.dataseg.relro_end)
- {
- bfd_vma data_initial_base = expld.dataseg.base;
- bfd_vma data_relro_end = lang_size_relro_segment_1 ();
-
- lang_reset_memory_regions ();
- one_lang_size_sections_pass (relax, check_regions);
-
- /* Assignments to dot, or to output section address in a user
- script have increased padding over the original. Revert. */
- if (expld.dataseg.relro_end > data_relro_end)
- {
- expld.dataseg.base = data_initial_base;
- do_reset = true;
- }
- }
- else if (lang_size_segment ())
- do_reset = true;
-
- return do_reset;
-}
-
-void
-lang_size_sections (bool *relax, bool check_regions)
-{
- expld.phase = lang_allocating_phase_enum;
- expld.dataseg.phase = exp_seg_none;
-
- one_lang_size_sections_pass (relax, check_regions);
-
- if (expld.dataseg.phase != exp_seg_end_seen)
- expld.dataseg.phase = exp_seg_done;
-
- if (expld.dataseg.phase == exp_seg_end_seen)
- {
- bool do_reset
- = lang_size_relro_segment (relax, check_regions);
-
- if (do_reset)
- {
- lang_reset_memory_regions ();
- one_lang_size_sections_pass (relax, check_regions);
- }
-
- if (link_info.relro && expld.dataseg.relro_end)
- {
- link_info.relro_start = expld.dataseg.base;
- link_info.relro_end = expld.dataseg.relro_end;
- }
- }
-}
-
-static lang_output_section_statement_type *current_section;
-static lang_assignment_statement_type *current_assign;
-static bool prefer_next_section;
-
-/* Worker function for lang_do_assignments. Recursiveness goes here. */
-
-static bfd_vma
-lang_do_assignments_1 (lang_statement_union_type *s,
- lang_output_section_statement_type *current_os,
- fill_type *fill,
- bfd_vma dot,
- bool *found_end)
-{
- lang_output_section_statement_type *os = current_os;
-
- for (; s != NULL; s = s->header.next)
- {
- switch (s->header.type)
- {
- case lang_constructors_statement_enum:
- dot = lang_do_assignments_1 (constructor_list.head,
- current_os, fill, dot, found_end);
- break;
-
- case lang_output_section_statement_enum:
- {
- bfd_vma newdot;
-
- os = &s->output_section_statement;
- os->after_end = *found_end;
- init_opb (os->bfd_section);
- newdot = dot;
- if (os->bfd_section != NULL)
- {
- if (!os->ignored && (os->bfd_section->flags & SEC_ALLOC) != 0)
- {
- current_section = os;
- prefer_next_section = false;
- }
- newdot = os->bfd_section->vma;
- }
- newdot = lang_do_assignments_1 (os->children.head,
- os, os->fill, newdot, found_end);
- if (!os->ignored)
- {
- if (os->bfd_section != NULL)
- {
- newdot = os->bfd_section->vma;
-
- /* .tbss sections effectively have zero size. */
- if (!IS_TBSS (os->bfd_section)
- || bfd_link_relocatable (&link_info))
- newdot += TO_ADDR (os->bfd_section->size);
-
- if (os->update_dot_tree != NULL)
- exp_fold_tree (os->update_dot_tree, os,
- bfd_abs_section_ptr, &newdot);
- }
- dot = newdot;
- }
- }
- break;
-
- case lang_wild_statement_enum:
-
- dot = lang_do_assignments_1 (s->wild_statement.children.head,
- current_os, fill, dot, found_end);
- break;
-
- case lang_object_symbols_statement_enum:
- case lang_output_statement_enum:
- case lang_target_statement_enum:
- break;
-
- case lang_data_statement_enum:
- exp_fold_tree (s->data_statement.exp, os, bfd_abs_section_ptr, &dot);
- if (expld.result.valid_p)
- {
- s->data_statement.value = expld.result.value;
- if (expld.result.section != NULL)
- s->data_statement.value += expld.result.section->vma;
- }
- else if (expld.phase == lang_final_phase_enum)
- einfo (_("%F%P: invalid data statement\n"));
- {
- unsigned int size;
- switch (s->data_statement.type)
- {
- default:
- abort ();
- case QUAD:
- case SQUAD:
- size = QUAD_SIZE;
- break;
- case LONG:
- size = LONG_SIZE;
- break;
- case SHORT:
- size = SHORT_SIZE;
- break;
- case BYTE:
- size = BYTE_SIZE;
- break;
- }
- if (size < TO_SIZE ((unsigned) 1))
- size = TO_SIZE ((unsigned) 1);
- dot += TO_ADDR (size);
- }
- break;
-
- case lang_reloc_statement_enum:
- exp_fold_tree (s->reloc_statement.addend_exp, os,
- bfd_abs_section_ptr, &dot);
- if (expld.result.valid_p)
- s->reloc_statement.addend_value = expld.result.value;
- else if (expld.phase == lang_final_phase_enum)
- einfo (_("%F%P: invalid reloc statement\n"));
- dot += TO_ADDR (bfd_get_reloc_size (s->reloc_statement.howto));
- break;
-
- case lang_input_section_enum:
- {
- asection *in = s->input_section.section;
-
- if ((in->flags & SEC_EXCLUDE) == 0)
- dot += TO_ADDR (in->size);
- }
- break;
-
- case lang_input_statement_enum:
- break;
-
- case lang_fill_statement_enum:
- fill = s->fill_statement.fill;
- break;
-
- case lang_assignment_statement_enum:
- current_assign = &s->assignment_statement;
- if (current_assign->exp->type.node_class != etree_assert)
- {
- const char *p = current_assign->exp->assign.dst;
-
- if (current_os == abs_output_section && p[0] == '.' && p[1] == 0)
- prefer_next_section = true;
-
- while (*p == '_')
- ++p;
- if (strcmp (p, "end") == 0)
- *found_end = true;
- }
- exp_fold_tree (s->assignment_statement.exp, os,
- (current_os->bfd_section != NULL
- ? current_os->bfd_section : bfd_und_section_ptr),
- &dot);
- break;
-
- case lang_padding_statement_enum:
- dot += TO_ADDR (s->padding_statement.size);
- break;
-
- case lang_group_statement_enum:
- dot = lang_do_assignments_1 (s->group_statement.children.head,
- current_os, fill, dot, found_end);
- break;
-
- case lang_insert_statement_enum:
- break;
-
- case lang_address_statement_enum:
- break;
-
- default:
- FAIL ();
- break;
- }
- }
- return dot;
-}
-
-void
-lang_do_assignments (lang_phase_type phase)
-{
- bool found_end = false;
-
- current_section = NULL;
- prefer_next_section = false;
- expld.phase = phase;
- lang_statement_iteration++;
- lang_do_assignments_1 (statement_list.head,
- abs_output_section, NULL, 0, &found_end);
-}
-
-/* For an assignment statement outside of an output section statement,
- choose the best of neighbouring output sections to use for values
- of "dot". */
-
-asection *
-section_for_dot (void)
-{
- asection *s;
-
- /* Assignments belong to the previous output section, unless there
- has been an assignment to "dot", in which case following
- assignments belong to the next output section. (The assumption
- is that an assignment to "dot" is setting up the address for the
- next output section.) Except that past the assignment to "_end"
- we always associate with the previous section. This exception is
- for targets like SH that define an alloc .stack or other
- weirdness after non-alloc sections. */
- if (current_section == NULL || prefer_next_section)
- {
- lang_statement_union_type *stmt;
- lang_output_section_statement_type *os;
-
- for (stmt = (lang_statement_union_type *) current_assign;
- stmt != NULL;
- stmt = stmt->header.next)
- if (stmt->header.type == lang_output_section_statement_enum)
- break;
-
- os = stmt ? &stmt->output_section_statement : NULL;
- while (os != NULL
- && !os->after_end
- && (os->bfd_section == NULL
- || (os->bfd_section->flags & SEC_EXCLUDE) != 0
- || bfd_section_removed_from_list (link_info.output_bfd,
- os->bfd_section)))
- os = os->next;
-
- if (current_section == NULL || os == NULL || !os->after_end)
- {
- if (os != NULL)
- s = os->bfd_section;
- else
- s = link_info.output_bfd->section_last;
- while (s != NULL
- && ((s->flags & SEC_ALLOC) == 0
- || (s->flags & SEC_THREAD_LOCAL) != 0))
- s = s->prev;
- if (s != NULL)
- return s;
-
- return bfd_abs_section_ptr;
- }
- }
-
- s = current_section->bfd_section;
-
- /* The section may have been stripped. */
- while (s != NULL
- && ((s->flags & SEC_EXCLUDE) != 0
- || (s->flags & SEC_ALLOC) == 0
- || (s->flags & SEC_THREAD_LOCAL) != 0
- || bfd_section_removed_from_list (link_info.output_bfd, s)))
- s = s->prev;
- if (s == NULL)
- s = link_info.output_bfd->sections;
- while (s != NULL
- && ((s->flags & SEC_ALLOC) == 0
- || (s->flags & SEC_THREAD_LOCAL) != 0))
- s = s->next;
- if (s != NULL)
- return s;
-
- return bfd_abs_section_ptr;
-}
-
-/* Array of __start/__stop/.startof./.sizeof/ symbols. */
-
-static struct bfd_link_hash_entry **start_stop_syms;
-static size_t start_stop_count = 0;
-static size_t start_stop_alloc = 0;
-
-/* Give start/stop SYMBOL for SEC a preliminary definition, and add it
- to start_stop_syms. */
-
-static void
-lang_define_start_stop (const char *symbol, asection *sec)
-{
- struct bfd_link_hash_entry *h;
-
- h = bfd_define_start_stop (link_info.output_bfd, &link_info, symbol, sec);
- if (h != NULL)
- {
- if (start_stop_count == start_stop_alloc)
- {
- start_stop_alloc = 2 * start_stop_alloc + 10;
- start_stop_syms
- = xrealloc (start_stop_syms,
- start_stop_alloc * sizeof (*start_stop_syms));
- }
- start_stop_syms[start_stop_count++] = h;
- }
-}
-
-/* Check for input sections whose names match references to
- __start_SECNAME or __stop_SECNAME symbols. Give the symbols
- preliminary definitions. */
-
-static void
-lang_init_start_stop (void)
-{
- bfd *abfd;
- asection *s;
- char leading_char = bfd_get_symbol_leading_char (link_info.output_bfd);
-
- for (abfd = link_info.input_bfds; abfd != NULL; abfd = abfd->link.next)
- for (s = abfd->sections; s != NULL; s = s->next)
- {
- const char *ps;
- const char *secname = s->name;
-
- for (ps = secname; *ps != '\0'; ps++)
- if (!ISALNUM ((unsigned char) *ps) && *ps != '_')
- break;
- if (*ps == '\0')
- {
- char *symbol = (char *) xmalloc (10 + strlen (secname));
-
- symbol[0] = leading_char;
- sprintf (symbol + (leading_char != 0), "__start_%s", secname);
- lang_define_start_stop (symbol, s);
-
- symbol[1] = leading_char;
- memcpy (symbol + 1 + (leading_char != 0), "__stop", 6);
- lang_define_start_stop (symbol + 1, s);
-
- free (symbol);
- }
- }
-}
-
-/* Iterate over start_stop_syms. */
-
-static void
-foreach_start_stop (void (*func) (struct bfd_link_hash_entry *))
-{
- size_t i;
-
- for (i = 0; i < start_stop_count; ++i)
- func (start_stop_syms[i]);
-}
-
-/* __start and __stop symbols are only supposed to be defined by the
- linker for orphan sections, but we now extend that to sections that
- map to an output section of the same name. The symbols were
- defined early for --gc-sections, before we mapped input to output
- sections, so undo those that don't satisfy this rule. */
-
-static void
-undef_start_stop (struct bfd_link_hash_entry *h)
-{
- if (h->ldscript_def)
- return;
-
- if (h->u.def.section->output_section == NULL
- || h->u.def.section->output_section->owner != link_info.output_bfd
- || strcmp (h->u.def.section->name,
- h->u.def.section->output_section->name) != 0)
- {
- asection *sec = bfd_get_section_by_name (link_info.output_bfd,
- h->u.def.section->name);
- if (sec != NULL)
- {
- /* When there are more than one input sections with the same
- section name, SECNAME, linker picks the first one to define
- __start_SECNAME and __stop_SECNAME symbols. When the first
- input section is removed by comdat group, we need to check
- if there is still an output section with section name
- SECNAME. */
- asection *i;
- for (i = sec->map_head.s; i != NULL; i = i->map_head.s)
- if (strcmp (h->u.def.section->name, i->name) == 0)
- {
- h->u.def.section = i;
- return;
- }
- }
- h->type = bfd_link_hash_undefined;
- h->u.undef.abfd = NULL;
- if (is_elf_hash_table (link_info.hash))
- {
- const struct elf_backend_data *bed;
- struct elf_link_hash_entry *eh = (struct elf_link_hash_entry *) h;
- unsigned int was_forced = eh->forced_local;
-
- bed = get_elf_backend_data (link_info.output_bfd);
- (*bed->elf_backend_hide_symbol) (&link_info, eh, true);
- if (!eh->ref_regular_nonweak)
- h->type = bfd_link_hash_undefweak;
- eh->def_regular = 0;
- eh->forced_local = was_forced;
- }
- }
-}
-
-static void
-lang_undef_start_stop (void)
-{
- foreach_start_stop (undef_start_stop);
-}
-
-/* Check for output sections whose names match references to
- .startof.SECNAME or .sizeof.SECNAME symbols. Give the symbols
- preliminary definitions. */
-
-static void
-lang_init_startof_sizeof (void)
-{
- asection *s;
-
- for (s = link_info.output_bfd->sections; s != NULL; s = s->next)
- {
- const char *secname = s->name;
- char *symbol = (char *) xmalloc (10 + strlen (secname));
-
- sprintf (symbol, ".startof.%s", secname);
- lang_define_start_stop (symbol, s);
-
- memcpy (symbol + 1, ".size", 5);
- lang_define_start_stop (symbol + 1, s);
- free (symbol);
- }
-}
-
-/* Set .startof., .sizeof., __start and __stop symbols final values. */
-
-static void
-set_start_stop (struct bfd_link_hash_entry *h)
-{
- if (h->ldscript_def
- || h->type != bfd_link_hash_defined)
- return;
-
- if (h->root.string[0] == '.')
- {
- /* .startof. or .sizeof. symbol.
- .startof. already has final value. */
- if (h->root.string[2] == 'i')
- {
- /* .sizeof. */
- h->u.def.value = TO_ADDR (h->u.def.section->size);
- h->u.def.section = bfd_abs_section_ptr;
- }
- }
- else
- {
- /* __start or __stop symbol. */
- int has_lead = bfd_get_symbol_leading_char (link_info.output_bfd) != 0;
-
- h->u.def.section = h->u.def.section->output_section;
- if (h->root.string[4 + has_lead] == 'o')
- {
- /* __stop_ */
- h->u.def.value = TO_ADDR (h->u.def.section->size);
- }
- }
-}
-
-static void
-lang_finalize_start_stop (void)
-{
- foreach_start_stop (set_start_stop);
-}
-
-static void
-lang_symbol_tweaks (void)
-{
- /* Give initial values for __start and __stop symbols, so that ELF
- gc_sections will keep sections referenced by these symbols. Must
- be done before lang_do_assignments. */
- if (config.build_constructors)
- lang_init_start_stop ();
-
- /* Make __ehdr_start hidden, and set def_regular even though it is
- likely undefined at this stage. For lang_check_relocs. */
- if (is_elf_hash_table (link_info.hash)
- && !bfd_link_relocatable (&link_info))
- {
- struct elf_link_hash_entry *h = (struct elf_link_hash_entry *)
- bfd_link_hash_lookup (link_info.hash, "__ehdr_start",
- false, false, true);
-
- /* Only adjust the export class if the symbol was referenced
- and not defined, otherwise leave it alone. */
- if (h != NULL
- && (h->root.type == bfd_link_hash_new
- || h->root.type == bfd_link_hash_undefined
- || h->root.type == bfd_link_hash_undefweak
- || h->root.type == bfd_link_hash_common))
- {
- const struct elf_backend_data *bed;
- bed = get_elf_backend_data (link_info.output_bfd);
- (*bed->elf_backend_hide_symbol) (&link_info, h, true);
- if (ELF_ST_VISIBILITY (h->other) != STV_INTERNAL)
- h->other = (h->other & ~ELF_ST_VISIBILITY (-1)) | STV_HIDDEN;
- h->def_regular = 1;
- h->root.linker_def = 1;
- h->root.rel_from_abs = 1;
- }
- }
-}
-
-static void
-lang_end (void)
-{
- struct bfd_link_hash_entry *h;
- bool warn;
-
- if ((bfd_link_relocatable (&link_info) && !link_info.gc_sections)
- || bfd_link_dll (&link_info))
- warn = entry_from_cmdline;
- else
- warn = true;
-
- /* Force the user to specify a root when generating a relocatable with
- --gc-sections, unless --gc-keep-exported was also given. */
- if (bfd_link_relocatable (&link_info)
- && link_info.gc_sections
- && !link_info.gc_keep_exported)
- {
- struct bfd_sym_chain *sym;
-
- for (sym = link_info.gc_sym_list; sym != NULL; sym = sym->next)
- {
- h = bfd_link_hash_lookup (link_info.hash, sym->name,
- false, false, false);
- if (h != NULL
- && (h->type == bfd_link_hash_defined
- || h->type == bfd_link_hash_defweak)
- && !bfd_is_const_section (h->u.def.section))
- break;
- }
- if (!sym)
- einfo (_("%F%P: --gc-sections requires a defined symbol root "
- "specified by -e or -u\n"));
- }
-
- if (entry_symbol.name == NULL)
- {
- /* No entry has been specified. Look for the default entry, but
- don't warn if we don't find it. */
- entry_symbol.name = entry_symbol_default;
- warn = false;
- }
-
- h = bfd_link_hash_lookup (link_info.hash, entry_symbol.name,
- false, false, true);
- if (h != NULL
- && (h->type == bfd_link_hash_defined
- || h->type == bfd_link_hash_defweak)
- && h->u.def.section->output_section != NULL)
- {
- bfd_vma val;
-
- val = (h->u.def.value
- + bfd_section_vma (h->u.def.section->output_section)
- + h->u.def.section->output_offset);
- if (!bfd_set_start_address (link_info.output_bfd, val))
- einfo (_("%F%P: %s: can't set start address\n"), entry_symbol.name);
- }
- else
- {
- bfd_vma val;
- const char *send;
-
- /* We couldn't find the entry symbol. Try parsing it as a
- number. */
- val = bfd_scan_vma (entry_symbol.name, &send, 0);
- if (*send == '\0')
- {
- if (!bfd_set_start_address (link_info.output_bfd, val))
- einfo (_("%F%P: can't set start address\n"));
- }
- /* BZ 2004952: Only use the start of the entry section for executables. */
- else if bfd_link_executable (&link_info)
- {
- asection *ts;
-
- /* Can't find the entry symbol, and it's not a number. Use
- the first address in the text section. */
- ts = bfd_get_section_by_name (link_info.output_bfd, entry_section);
- if (ts != NULL)
- {
- if (warn)
- einfo (_("%P: warning: cannot find entry symbol %s;"
- " defaulting to %V\n"),
- entry_symbol.name,
- bfd_section_vma (ts));
- if (!bfd_set_start_address (link_info.output_bfd,
- bfd_section_vma (ts)))
- einfo (_("%F%P: can't set start address\n"));
- }
- else
- {
- if (warn)
- einfo (_("%P: warning: cannot find entry symbol %s;"
- " not setting start address\n"),
- entry_symbol.name);
- }
- }
- else
- {
- if (warn)
- einfo (_("%P: warning: cannot find entry symbol %s;"
- " not setting start address\n"),
- entry_symbol.name);
- }
- }
-}
-
-/* This is a small function used when we want to ignore errors from
- BFD. */
-
-static void
-ignore_bfd_errors (const char *fmt ATTRIBUTE_UNUSED,
- va_list ap ATTRIBUTE_UNUSED)
-{
- /* Don't do anything. */
-}
-
-/* Check that the architecture of all the input files is compatible
- with the output file. Also call the backend to let it do any
- other checking that is needed. */
-
-static void
-lang_check (void)
-{
- lang_input_statement_type *file;
- bfd *input_bfd;
- const bfd_arch_info_type *compatible;
-
- for (file = (void *) file_chain.head;
- file != NULL;
- file = file->next)
- {
-#if BFD_SUPPORTS_PLUGINS
- /* Don't check format of files claimed by plugin. */
- if (file->flags.claimed)
- continue;
-#endif /* BFD_SUPPORTS_PLUGINS */
- input_bfd = file->the_bfd;
- compatible
- = bfd_arch_get_compatible (input_bfd, link_info.output_bfd,
- command_line.accept_unknown_input_arch);
-
- /* In general it is not possible to perform a relocatable
- link between differing object formats when the input
- file has relocations, because the relocations in the
- input format may not have equivalent representations in
- the output format (and besides BFD does not translate
- relocs for other link purposes than a final link). */
- if (!file->flags.just_syms
- && (bfd_link_relocatable (&link_info)
- || link_info.emitrelocations)
- && (compatible == NULL
- || (bfd_get_flavour (input_bfd)
- != bfd_get_flavour (link_info.output_bfd)))
- && (bfd_get_file_flags (input_bfd) & HAS_RELOC) != 0)
- {
- einfo (_("%F%P: relocatable linking with relocations from"
- " format %s (%pB) to format %s (%pB) is not supported\n"),
- bfd_get_target (input_bfd), input_bfd,
- bfd_get_target (link_info.output_bfd), link_info.output_bfd);
- /* einfo with %F exits. */
- }
-
- if (compatible == NULL)
- {
- if (command_line.warn_mismatch)
- einfo (_("%X%P: %s architecture of input file `%pB'"
- " is incompatible with %s output\n"),
- bfd_printable_name (input_bfd), input_bfd,
- bfd_printable_name (link_info.output_bfd));
- }
-
- /* If the input bfd has no contents, it shouldn't set the
- private data of the output bfd. */
- else if (!file->flags.just_syms
- && ((input_bfd->flags & DYNAMIC) != 0
- || bfd_count_sections (input_bfd) != 0))
- {
- bfd_error_handler_type pfn = NULL;
-
- /* If we aren't supposed to warn about mismatched input
- files, temporarily set the BFD error handler to a
- function which will do nothing. We still want to call
- bfd_merge_private_bfd_data, since it may set up
- information which is needed in the output file. */
- if (!command_line.warn_mismatch)
- pfn = bfd_set_error_handler (ignore_bfd_errors);
- if (!bfd_merge_private_bfd_data (input_bfd, &link_info))
- {
- if (command_line.warn_mismatch)
- einfo (_("%X%P: failed to merge target specific data"
- " of file %pB\n"), input_bfd);
- }
- if (!command_line.warn_mismatch)
- bfd_set_error_handler (pfn);
- }
- }
-}
-
-/* Look through all the global common symbols and attach them to the
- correct section. The -sort-common command line switch may be used
- to roughly sort the entries by alignment. */
-
-static void
-lang_common (void)
-{
- if (link_info.inhibit_common_definition)
- return;
- if (bfd_link_relocatable (&link_info)
- && !command_line.force_common_definition)
- return;
-
- if (!config.sort_common)
- bfd_link_hash_traverse (link_info.hash, lang_one_common, NULL);
- else
- {
- unsigned int power;
-
- if (config.sort_common == sort_descending)
- {
- for (power = 4; power > 0; power--)
- bfd_link_hash_traverse (link_info.hash, lang_one_common, &power);
-
- power = 0;
- bfd_link_hash_traverse (link_info.hash, lang_one_common, &power);
- }
- else
- {
- for (power = 0; power <= 4; power++)
- bfd_link_hash_traverse (link_info.hash, lang_one_common, &power);
-
- power = (unsigned int) -1;
- bfd_link_hash_traverse (link_info.hash, lang_one_common, &power);
- }
- }
-}
-
-/* Place one common symbol in the correct section. */
-
-static bool
-lang_one_common (struct bfd_link_hash_entry *h, void *info)
-{
- unsigned int power_of_two;
- bfd_vma size;
- asection *section;
-
- if (h->type != bfd_link_hash_common)
- return true;
-
- size = h->u.c.size;
- power_of_two = h->u.c.p->alignment_power;
-
- if (config.sort_common == sort_descending
- && power_of_two < *(unsigned int *) info)
- return true;
- else if (config.sort_common == sort_ascending
- && power_of_two > *(unsigned int *) info)
- return true;
-
- section = h->u.c.p->section;
- if (!bfd_define_common_symbol (link_info.output_bfd, &link_info, h))
- einfo (_("%F%P: could not define common symbol `%pT': %E\n"),
- h->root.string);
-
- if (config.map_file != NULL)
- {
- static bool header_printed;
- int len;
- char *name;
- char buf[32];
-
- if (!header_printed)
- {
- minfo (_("\nAllocating common symbols\n"));
- minfo (_("Common symbol size file\n\n"));
- header_printed = true;
- }
-
- name = bfd_demangle (link_info.output_bfd, h->root.string,
- DMGL_ANSI | DMGL_PARAMS);
- if (name == NULL)
- {
- minfo ("%s", h->root.string);
- len = strlen (h->root.string);
- }
- else
- {
- minfo ("%s", name);
- len = strlen (name);
- free (name);
- }
-
- if (len >= 19)
- {
- print_nl ();
- len = 0;
- }
-
- sprintf (buf, "%" PRIx64, (uint64_t) size);
- fprintf (config.map_file, "%*s0x%-16s", 20 - len, "", buf);
-
- minfo ("%pB\n", section->owner);
- }
-
- return true;
-}
-
-/* Handle a single orphan section S, placing the orphan into an appropriate
- output section. The effects of the --orphan-handling command line
- option are handled here. */
-
-static void
-ldlang_place_orphan (asection *s)
-{
- if (config.orphan_handling == orphan_handling_discard)
- {
- lang_output_section_statement_type *os;
- os = lang_output_section_statement_lookup (DISCARD_SECTION_NAME, 0, 1);
- if (os->addr_tree == NULL
- && (bfd_link_relocatable (&link_info)
- || (s->flags & (SEC_LOAD | SEC_ALLOC)) == 0))
- os->addr_tree = exp_intop (0);
- lang_add_section (&os->children, s, NULL, NULL, os);
- }
- else
- {
- lang_output_section_statement_type *os;
- const char *name = s->name;
- int constraint = 0;
-
- if (config.orphan_handling == orphan_handling_error)
- einfo (_("%X%P: error: unplaced orphan section `%pA' from `%pB'\n"),
- s, s->owner);
-
- if (config.unique_orphan_sections || unique_section_p (s, NULL))
- constraint = SPECIAL;
-
- os = ldemul_place_orphan (s, name, constraint);
- if (os == NULL)
- {
- os = lang_output_section_statement_lookup (name, constraint, 1);
- if (os->addr_tree == NULL
- && (bfd_link_relocatable (&link_info)
- || (s->flags & (SEC_LOAD | SEC_ALLOC)) == 0))
- os->addr_tree = exp_intop (0);
- lang_add_section (&os->children, s, NULL, NULL, os);
- }
-
- if (config.orphan_handling == orphan_handling_warn)
- einfo (_("%P: warning: orphan section `%pA' from `%pB' being "
- "placed in section `%s'\n"),
- s, s->owner, os->name);
- }
-}
-
-/* Run through the input files and ensure that every input section has
- somewhere to go. If one is found without a destination then create
- an input request and place it into the statement tree. */
-
-static void
-lang_place_orphans (void)
-{
- LANG_FOR_EACH_INPUT_STATEMENT (file)
- {
- asection *s;
-
- for (s = file->the_bfd->sections; s != NULL; s = s->next)
- {
- if (s->output_section == NULL)
- {
- /* This section of the file is not attached, root
- around for a sensible place for it to go. */
-
- if (file->flags.just_syms)
- bfd_link_just_syms (file->the_bfd, s, &link_info);
- else if (lang_discard_section_p (s))
- s->output_section = bfd_abs_section_ptr;
- else if (strcmp (s->name, "COMMON") == 0)
- {
- /* This is a lonely common section which must have
- come from an archive. We attach to the section
- with the wildcard. */
- if (!bfd_link_relocatable (&link_info)
- || command_line.force_common_definition)
- {
- if (default_common_section == NULL)
- default_common_section
- = lang_output_section_statement_lookup (".bss", 0, 1);
- lang_add_section (&default_common_section->children, s,
- NULL, NULL, default_common_section);
- }
- }
- else
- ldlang_place_orphan (s);
- }
- }
- }
-}
-
-void
-lang_set_flags (lang_memory_region_type *ptr, const char *flags, int invert)
-{
- flagword *ptr_flags;
-
- ptr_flags = invert ? &ptr->not_flags : &ptr->flags;
-
- while (*flags)
- {
- switch (*flags)
- {
- /* PR 17900: An exclamation mark in the attributes reverses
- the sense of any of the attributes that follow. */
- case '!':
- invert = !invert;
- ptr_flags = invert ? &ptr->not_flags : &ptr->flags;
- break;
-
- case 'A': case 'a':
- *ptr_flags |= SEC_ALLOC;
- break;
-
- case 'R': case 'r':
- *ptr_flags |= SEC_READONLY;
- break;
-
- case 'W': case 'w':
- *ptr_flags |= SEC_DATA;
- break;
-
- case 'X': case 'x':
- *ptr_flags |= SEC_CODE;
- break;
-
- case 'L': case 'l':
- case 'I': case 'i':
- *ptr_flags |= SEC_LOAD;
- break;
-
- default:
- einfo (_("%F%P: invalid character %c (%d) in flags\n"),
- *flags, *flags);
- break;
- }
- flags++;
- }
-}
-
-/* Call a function on each real input file. This function will be
- called on an archive, but not on the elements. */
-
-void
-lang_for_each_input_file (void (*func) (lang_input_statement_type *))
-{
- lang_input_statement_type *f;
-
- for (f = (void *) input_file_chain.head;
- f != NULL;
- f = f->next_real_file)
- if (f->flags.real)
- func (f);
-}
-
-/* Call a function on each real file. The function will be called on
- all the elements of an archive which are included in the link, but
- will not be called on the archive file itself. */
-
-void
-lang_for_each_file (void (*func) (lang_input_statement_type *))
-{
- LANG_FOR_EACH_INPUT_STATEMENT (f)
- {
- if (f->flags.real)
- func (f);
- }
-}
-
-void
-ldlang_add_file (lang_input_statement_type *entry)
-{
- lang_statement_append (&file_chain, entry, &entry->next);
-
- /* The BFD linker needs to have a list of all input BFDs involved in
- a link. */
- ASSERT (link_info.input_bfds_tail != &entry->the_bfd->link.next
- && entry->the_bfd->link.next == NULL);
- ASSERT (entry->the_bfd != link_info.output_bfd);
-
- *link_info.input_bfds_tail = entry->the_bfd;
- link_info.input_bfds_tail = &entry->the_bfd->link.next;
- bfd_set_usrdata (entry->the_bfd, entry);
- bfd_set_gp_size (entry->the_bfd, g_switch_value);
-
- /* Look through the sections and check for any which should not be
- included in the link. We need to do this now, so that we can
- notice when the backend linker tries to report multiple
- definition errors for symbols which are in sections we aren't
- going to link. FIXME: It might be better to entirely ignore
- symbols which are defined in sections which are going to be
- discarded. This would require modifying the backend linker for
- each backend which might set the SEC_LINK_ONCE flag. If we do
- this, we should probably handle SEC_EXCLUDE in the same way. */
-
- bfd_map_over_sections (entry->the_bfd, section_already_linked, entry);
-}
-
-void
-lang_add_output (const char *name, int from_script)
-{
- /* Make -o on command line override OUTPUT in script. */
- if (!had_output_filename || !from_script)
- {
- output_filename = name;
- had_output_filename = true;
- }
-}
-
-lang_output_section_statement_type *
-lang_enter_output_section_statement (const char *output_section_statement_name,
- etree_type *address_exp,
- enum section_type sectype,
- etree_type *sectype_value,
- etree_type *align,
- etree_type *subalign,
- etree_type *ebase,
- int constraint,
- int align_with_input)
-{
- lang_output_section_statement_type *os;
-
- os = lang_output_section_statement_lookup (output_section_statement_name,
- constraint,
- in_section_ordering ? 0 : 2);
- if (os == NULL) /* && in_section_ordering */
- einfo (_("%F%P:%pS: error: output section '%s' must already exist\n"),
- NULL, output_section_statement_name);
- current_section = os;
-
- /* Make next things chain into subchain of this. */
- push_stat_ptr (in_section_ordering ? &os->sort_children : &os->children);
-
- if (in_section_ordering)
- return os;
-
- if (os->addr_tree == NULL)
- os->addr_tree = address_exp;
-
- os->sectype = sectype;
- if (sectype == type_section || sectype == typed_readonly_section)
- os->sectype_value = sectype_value;
- else if (sectype == noload_section)
- os->flags = SEC_NEVER_LOAD;
- else
- os->flags = SEC_NO_FLAGS;
- os->block_value = 1;
-
- os->align_lma_with_input = align_with_input == ALIGN_WITH_INPUT;
- if (os->align_lma_with_input && align != NULL)
- einfo (_("%F%P:%pS: error: align with input and explicit align specified\n"),
- NULL);
-
- os->subsection_alignment = subalign;
- os->section_alignment = align;
-
- os->load_base = ebase;
- return os;
-}
-
-void
-lang_final (void)
-{
- lang_output_statement_type *new_stmt;
-
- new_stmt = new_stat (lang_output_statement, stat_ptr);
- new_stmt->name = output_filename;
-}
-
-/* Reset the current counters in the regions. */
-
-void
-lang_reset_memory_regions (void)
-{
- lang_memory_region_type *p = lang_memory_region_list;
- asection *o;
- lang_output_section_statement_type *os;
-
- for (p = lang_memory_region_list; p != NULL; p = p->next)
- {
- p->current = p->origin;
- p->last_os = NULL;
- }
-
- for (os = (void *) lang_os_list.head;
- os != NULL;
- os = os->next)
- {
- os->processed_vma = false;
- os->processed_lma = false;
- }
-
- for (o = link_info.output_bfd->sections; o != NULL; o = o->next)
- {
- /* Save the last size for possible use by bfd_relax_section. */
- o->rawsize = o->size;
- if (!(o->flags & SEC_FIXED_SIZE))
- o->size = 0;
- }
-}
-
-/* Worker for lang_gc_sections_1. */
-
-static void
-gc_section_callback (lang_wild_statement_type *ptr,
- struct wildcard_list *sec ATTRIBUTE_UNUSED,
- asection *section,
- lang_input_statement_type *file ATTRIBUTE_UNUSED,
- void *data ATTRIBUTE_UNUSED)
-{
- /* If the wild pattern was marked KEEP, the member sections
- should be as well. */
- if (ptr->keep_sections)
- section->flags |= SEC_KEEP;
-}
-
-/* Iterate over sections marking them against GC. */
-
-static void
-lang_gc_sections_1 (lang_statement_union_type *s)
-{
- for (; s != NULL; s = s->header.next)
- {
- switch (s->header.type)
- {
- case lang_wild_statement_enum:
- walk_wild (&s->wild_statement, gc_section_callback, NULL);
- break;
- case lang_constructors_statement_enum:
- lang_gc_sections_1 (constructor_list.head);
- break;
- case lang_output_section_statement_enum:
- lang_gc_sections_1 (s->output_section_statement.children.head);
- break;
- case lang_group_statement_enum:
- lang_gc_sections_1 (s->group_statement.children.head);
- break;
- default:
- break;
- }
- }
-}
-
-static void
-lang_gc_sections (void)
-{
- /* Keep all sections so marked in the link script. */
- lang_gc_sections_1 (statement_list.head);
-
- /* SEC_EXCLUDE is ignored when doing a relocatable link, except in
- the special case of .stabstr debug info. (See bfd/stabs.c)
- Twiddle the flag here, to simplify later linker code. */
- if (bfd_link_relocatable (&link_info))
- {
- LANG_FOR_EACH_INPUT_STATEMENT (f)
- {
- asection *sec;
-#if BFD_SUPPORTS_PLUGINS
- if (f->flags.claimed)
- continue;
-#endif
- for (sec = f->the_bfd->sections; sec != NULL; sec = sec->next)
- if ((sec->flags & SEC_DEBUGGING) == 0
- || strcmp (sec->name, ".stabstr") != 0)
- sec->flags &= ~SEC_EXCLUDE;
- }
- }
-
- if (link_info.gc_sections)
- bfd_gc_sections (link_info.output_bfd, &link_info);
-}
-
-/* Worker for lang_find_relro_sections_1. */
-
-static void
-find_relro_section_callback (lang_wild_statement_type *ptr ATTRIBUTE_UNUSED,
- struct wildcard_list *sec ATTRIBUTE_UNUSED,
- asection *section,
- lang_input_statement_type *file ATTRIBUTE_UNUSED,
- void *data)
-{
- /* Discarded, excluded and ignored sections effectively have zero
- size. */
- if (section->output_section != NULL
- && section->output_section->owner == link_info.output_bfd
- && (section->output_section->flags & SEC_EXCLUDE) == 0
- && !IGNORE_SECTION (section)
- && section->size != 0)
- {
- bool *has_relro_section = (bool *) data;
- *has_relro_section = true;
- }
-}
-
-/* Iterate over sections for relro sections. */
-
-static void
-lang_find_relro_sections_1 (lang_statement_union_type *s,
- bool *has_relro_section)
-{
- if (*has_relro_section)
- return;
-
- for (; s != NULL; s = s->header.next)
- {
- if (s == expld.dataseg.relro_end_stat)
- break;
-
- switch (s->header.type)
- {
- case lang_wild_statement_enum:
- walk_wild (&s->wild_statement,
- find_relro_section_callback,
- has_relro_section);
- break;
- case lang_constructors_statement_enum:
- lang_find_relro_sections_1 (constructor_list.head,
- has_relro_section);
- break;
- case lang_output_section_statement_enum:
- lang_find_relro_sections_1 (s->output_section_statement.children.head,
- has_relro_section);
- break;
- case lang_group_statement_enum:
- lang_find_relro_sections_1 (s->group_statement.children.head,
- has_relro_section);
- break;
- default:
- break;
- }
- }
-}
-
-static void
-lang_find_relro_sections (void)
-{
- bool has_relro_section = false;
-
- /* Check all sections in the link script. */
-
- lang_find_relro_sections_1 (expld.dataseg.relro_start_stat,
- &has_relro_section);
-
- if (!has_relro_section)
- link_info.relro = false;
-}
-
-/* Relax all sections until bfd_relax_section gives up. */
-
-void
-lang_relax_sections (bool need_layout)
-{
- /* NB: Also enable relaxation to layout sections for DT_RELR. */
- if (RELAXATION_ENABLED || link_info.enable_dt_relr)
- {
- /* We may need more than one relaxation pass. */
- int i = link_info.relax_pass;
-
- /* The backend can use it to determine the current pass. */
- link_info.relax_pass = 0;
-
- while (i--)
- {
- /* Keep relaxing until bfd_relax_section gives up. */
- bool relax_again;
-
- link_info.relax_trip = -1;
- do
- {
- link_info.relax_trip++;
-
- /* Note: pe-dll.c does something like this also. If you find
- you need to change this code, you probably need to change
- pe-dll.c also. DJ */
-
- /* Do all the assignments with our current guesses as to
- section sizes. */
- lang_do_assignments (lang_assigning_phase_enum);
-
- /* We must do this after lang_do_assignments, because it uses
- size. */
- lang_reset_memory_regions ();
-
- /* Perform another relax pass - this time we know where the
- globals are, so can make a better guess. */
- relax_again = false;
- lang_size_sections (&relax_again, false);
- }
- while (relax_again);
-
- link_info.relax_pass++;
- }
- need_layout = true;
- }
-
- if (need_layout)
- {
- /* Final extra sizing to report errors. */
- lang_do_assignments (lang_assigning_phase_enum);
- lang_reset_memory_regions ();
- lang_size_sections (NULL, true);
- }
-}
-
-#if BFD_SUPPORTS_PLUGINS
-/* Find the insert point for the plugin's replacement files. We
- place them after the first claimed real object file, or if the
- first claimed object is an archive member, after the last real
- object file immediately preceding the archive. In the event
- no objects have been claimed at all, we return the first dummy
- object file on the list as the insert point; that works, but
- the callee must be careful when relinking the file_chain as it
- is not actually on that chain, only the statement_list and the
- input_file list; in that case, the replacement files must be
- inserted at the head of the file_chain. */
-
-static lang_input_statement_type *
-find_replacements_insert_point (bool *before)
-{
- lang_input_statement_type *claim1, *lastobject;
- lastobject = (void *) input_file_chain.head;
- for (claim1 = (void *) file_chain.head;
- claim1 != NULL;
- claim1 = claim1->next)
- {
- if (claim1->flags.claimed)
- {
- *before = claim1->flags.claim_archive;
- return claim1->flags.claim_archive ? lastobject : claim1;
- }
- /* Update lastobject if this is a real object file. */
- if (claim1->the_bfd != NULL && claim1->the_bfd->my_archive == NULL)
- lastobject = claim1;
- }
- /* No files were claimed by the plugin. Choose the last object
- file found on the list (maybe the first, dummy entry) as the
- insert point. */
- *before = false;
- return lastobject;
-}
-
-/* Find where to insert ADD, an archive element or shared library
- added during a rescan. */
-
-static lang_input_statement_type **
-find_rescan_insertion (lang_input_statement_type *add)
-{
- bfd *add_bfd = add->the_bfd;
- lang_input_statement_type *f;
- lang_input_statement_type *last_loaded = NULL;
- lang_input_statement_type *before = NULL;
- lang_input_statement_type **iter = NULL;
-
- if (add_bfd->my_archive != NULL)
- add_bfd = add_bfd->my_archive;
-
- /* First look through the input file chain, to find an object file
- before the one we've rescanned. Normal object files always
- appear on both the input file chain and the file chain, so this
- lets us get quickly to somewhere near the correct place on the
- file chain if it is full of archive elements. Archives don't
- appear on the file chain, but if an element has been extracted
- then their input_statement->next points at it. */
- for (f = (void *) input_file_chain.head;
- f != NULL;
- f = f->next_real_file)
- {
- if (f->the_bfd == add_bfd)
- {
- before = last_loaded;
- if (f->next != NULL)
- return &f->next->next;
- }
- if (f->the_bfd != NULL && f->next != NULL)
- last_loaded = f;
- }
-
- for (iter = before ? &before->next : &file_chain.head->input_statement.next;
- *iter != NULL;
- iter = &(*iter)->next)
- if (!(*iter)->flags.claim_archive
- && (*iter)->the_bfd->my_archive == NULL)
- break;
-
- return iter;
-}
-
-/* Detach new nodes added to DESTLIST since the time ORIGLIST
- was taken as a copy of it and leave them in ORIGLIST. */
-
-static void
-lang_list_remove_tail (lang_statement_list_type *destlist,
- lang_statement_list_type *origlist)
-{
- union lang_statement_union **savetail;
- /* Check that ORIGLIST really is an earlier state of DESTLIST. */
- ASSERT (origlist->head == destlist->head);
- savetail = origlist->tail;
- origlist->head = *(savetail);
- origlist->tail = destlist->tail;
- destlist->tail = savetail;
- *savetail = NULL;
-}
-
-static lang_statement_union_type **
-find_next_input_statement (lang_statement_union_type **s)
-{
- for ( ; *s; s = &(*s)->header.next)
- {
- lang_statement_union_type **t;
- switch ((*s)->header.type)
- {
- case lang_input_statement_enum:
- return s;
- case lang_wild_statement_enum:
- t = &(*s)->wild_statement.children.head;
- break;
- case lang_group_statement_enum:
- t = &(*s)->group_statement.children.head;
- break;
- case lang_output_section_statement_enum:
- t = &(*s)->output_section_statement.children.head;
- break;
- default:
- continue;
- }
- t = find_next_input_statement (t);
- if (*t)
- return t;
- }
- return s;
-}
-#endif /* BFD_SUPPORTS_PLUGINS */
-
-/* Insert SRCLIST into DESTLIST after given element by chaining
- on FIELD as the next-pointer. (Counterintuitively does not need
- a pointer to the actual after-node itself, just its chain field.) */
-
-static void
-lang_list_insert_after (lang_statement_list_type *destlist,
- lang_statement_list_type *srclist,
- lang_statement_union_type **field)
-{
- *(srclist->tail) = *field;
- *field = srclist->head;
- if (destlist->tail == field)
- destlist->tail = srclist->tail;
-}
-
-/* Add NAME to the list of garbage collection entry points. */
-
-void
-lang_add_gc_name (const char *name)
-{
- struct bfd_sym_chain *sym;
-
- if (name == NULL)
- return;
-
- sym = stat_alloc (sizeof (*sym));
-
- sym->next = link_info.gc_sym_list;
- sym->name = name;
- link_info.gc_sym_list = sym;
-}
-
-/* Check relocations. */
-
-static void
-lang_check_relocs (void)
-{
- if (link_info.check_relocs_after_open_input)
- {
- bfd *abfd;
-
- for (abfd = link_info.input_bfds;
- abfd != (bfd *) NULL; abfd = abfd->link.next)
- if (!bfd_link_check_relocs (abfd, &link_info))
- {
- /* No object output, fail return. */
- config.make_executable = false;
- /* Note: we do not abort the loop, but rather
- continue the scan in case there are other
- bad relocations to report. */
- }
- }
-}
-
-/* Look through all output sections looking for places where we can
- propagate forward the lma region. */
-
-static void
-lang_propagate_lma_regions (void)
-{
- lang_output_section_statement_type *os;
-
- for (os = (void *) lang_os_list.head;
- os != NULL;
- os = os->next)
- {
- if (os->prev != NULL
- && os->lma_region == NULL
- && os->load_base == NULL
- && os->addr_tree == NULL
- && os->region == os->prev->region)
- os->lma_region = os->prev->lma_region;
- }
-}
-
-static void
-warn_non_contiguous_discards (void)
-{
- LANG_FOR_EACH_INPUT_STATEMENT (file)
- {
- if ((file->the_bfd->flags & (BFD_LINKER_CREATED | DYNAMIC)) != 0
- || file->flags.just_syms)
- continue;
-
- for (asection *s = file->the_bfd->sections; s != NULL; s = s->next)
- if (s->output_section == NULL
- && (s->flags & SEC_LINKER_CREATED) == 0)
- einfo (_("%P: warning: --enable-non-contiguous-regions "
- "discards section `%pA' from `%pB'\n"),
- s, file->the_bfd);
- }
-}
-
-static void
-reset_one_wild (lang_statement_union_type *statement)
-{
- if (statement->header.type == lang_wild_statement_enum)
- {
- lang_wild_statement_type *stmt = &statement->wild_statement;
- lang_list_init (&stmt->matching_sections);
- }
-}
-
-static void
-reset_resolved_wilds (void)
-{
- lang_for_each_statement (reset_one_wild);
-}
-
-/* For each output section statement, splice any entries on the
- sort_children list before the first wild statement on the children
- list. */
-
-static void
-lang_os_merge_sort_children (void)
-{
- lang_output_section_statement_type *os;
- for (os = (void *) lang_os_list.head; os != NULL; os = os->next)
- {
- if (os->sort_children.head != NULL)
- {
- lang_statement_union_type **where;
- for (where = &os->children.head;
- *where != NULL;
- where = &(*where)->header.next)
- if ((*where)->header.type == lang_wild_statement_enum)
- break;
- lang_list_insert_after (&os->children, &os->sort_children, where);
- }
- }
-}
-
-void
-lang_process (void)
-{
- lang_os_merge_sort_children ();
-
- /* Finalize dynamic list. */
- if (link_info.dynamic_list)
- lang_finalize_version_expr_head (&link_info.dynamic_list->head);
-
- current_target = default_target;
-
- /* Open the output file. */
- lang_for_each_statement (ldlang_open_output);
- init_opb (NULL);
-
- ldemul_create_output_section_statements ();
-
- /* Add to the hash table all undefineds on the command line. */
- lang_place_undefineds ();
-
- if (!bfd_section_already_linked_table_init ())
- einfo (_("%F%P: can not create hash table: %E\n"));
-
- /* A first pass through the memory regions ensures that if any region
- references a symbol for its origin or length then this symbol will be
- added to the symbol table. Having these symbols in the symbol table
- means that when we call open_input_bfds PROVIDE statements will
- trigger to provide any needed symbols. The regions origins and
- lengths are not assigned as a result of this call. */
- lang_do_memory_regions (false);
-
- /* Create a bfd for each input file. */
- current_target = default_target;
- lang_statement_iteration++;
- open_input_bfds (statement_list.head, NULL, OPEN_BFD_NORMAL);
-
- /* Now that open_input_bfds has processed assignments and provide
- statements we can give values to symbolic origin/length now. */
- lang_do_memory_regions (true);
-
- ldemul_before_plugin_all_symbols_read ();
-
-#if BFD_SUPPORTS_PLUGINS
- if (link_info.lto_plugin_active)
- {
- lang_statement_list_type added;
- lang_statement_list_type files, inputfiles;
-
- /* Now all files are read, let the plugin(s) decide if there
- are any more to be added to the link before we call the
- emulation's after_open hook. We create a private list of
- input statements for this purpose, which we will eventually
- insert into the global statement list after the first claimed
- file. */
- added = *stat_ptr;
- /* We need to manipulate all three chains in synchrony. */
- files = file_chain;
- inputfiles = input_file_chain;
- if (plugin_call_all_symbols_read ())
- einfo (_("%F%P: %s: plugin reported error after all symbols read\n"),
- plugin_error_plugin ());
- link_info.lto_all_symbols_read = true;
- /* Open any newly added files, updating the file chains. */
- plugin_undefs = link_info.hash->undefs_tail;
- lang_output_section_statement_type *last_os = NULL;
- if (lang_os_list.head != NULL)
- last_os = ((lang_output_section_statement_type *)
- ((char *) lang_os_list.tail
- - offsetof (lang_output_section_statement_type, next)));
- open_input_bfds (*added.tail, last_os, OPEN_BFD_NORMAL);
- if (plugin_undefs == link_info.hash->undefs_tail)
- plugin_undefs = NULL;
- /* Restore the global list pointer now they have all been added. */
- lang_list_remove_tail (stat_ptr, &added);
- /* And detach the fresh ends of the file lists. */
- lang_list_remove_tail (&file_chain, &files);
- lang_list_remove_tail (&input_file_chain, &inputfiles);
- /* Were any new files added? */
- if (added.head != NULL)
- {
- /* If so, we will insert them into the statement list immediately
- after the first input file that was claimed by the plugin,
- unless that file was an archive in which case it is inserted
- immediately before. */
- bool before;
- lang_statement_union_type **prev;
- plugin_insert = find_replacements_insert_point (&before);
- /* If a plugin adds input files without having claimed any, we
- don't really have a good idea where to place them. Just putting
- them at the start or end of the list is liable to leave them
- outside the crtbegin...crtend range. */
- ASSERT (plugin_insert != NULL);
- /* Splice the new statement list into the old one. */
- prev = &plugin_insert->header.next;
- if (before)
- {
- prev = find_next_input_statement (prev);
- if (*prev != (void *) plugin_insert->next_real_file)
- {
- /* We didn't find the expected input statement.
- Fall back to adding after plugin_insert. */
- prev = &plugin_insert->header.next;
- }
- }
- lang_list_insert_after (stat_ptr, &added, prev);
- /* Likewise for the file chains. */
- lang_list_insert_after (&input_file_chain, &inputfiles,
- (void *) &plugin_insert->next_real_file);
- /* We must be careful when relinking file_chain; we may need to
- insert the new files at the head of the list if the insert
- point chosen is the dummy first input file. */
- if (plugin_insert->filename)
- lang_list_insert_after (&file_chain, &files,
- (void *) &plugin_insert->next);
- else
- lang_list_insert_after (&file_chain, &files, &file_chain.head);
-
- /* Rescan archives in case new undefined symbols have appeared. */
- files = file_chain;
- lang_statement_iteration++;
- open_input_bfds (statement_list.head, NULL, OPEN_BFD_RESCAN);
- lang_list_remove_tail (&file_chain, &files);
- while (files.head != NULL)
- {
- lang_input_statement_type **insert;
- lang_input_statement_type **iter, *temp;
- bfd *my_arch;
-
- insert = find_rescan_insertion (&files.head->input_statement);
- /* All elements from an archive can be added at once. */
- iter = &files.head->input_statement.next;
- my_arch = files.head->input_statement.the_bfd->my_archive;
- if (my_arch != NULL)
- for (; *iter != NULL; iter = &(*iter)->next)
- if ((*iter)->the_bfd->my_archive != my_arch)
- break;
- temp = *insert;
- *insert = &files.head->input_statement;
- files.head = (lang_statement_union_type *) *iter;
- *iter = temp;
- if (file_chain.tail == (lang_statement_union_type **) insert)
- file_chain.tail = (lang_statement_union_type **) iter;
- if (my_arch != NULL)
- {
- lang_input_statement_type *parent = bfd_usrdata (my_arch);
- if (parent != NULL)
- parent->next = (lang_input_statement_type *)
- ((char *) iter
- - offsetof (lang_input_statement_type, next));
- }
- }
- }
- }
-#endif /* BFD_SUPPORTS_PLUGINS */
-
- struct bfd_sym_chain **sym = &link_info.gc_sym_list;
- while (*sym)
- sym = &(*sym)->next;
-
- *sym = &entry_symbol;
-
- if (entry_symbol.name == NULL)
- {
- *sym = ldlang_undef_chain_list_head;
-
- /* entry_symbol is normally initialised by an ENTRY definition in the
- linker script or the -e command line option. But if neither of
- these have been used, the target specific backend may still have
- provided an entry symbol via a call to lang_default_entry().
- Unfortunately this value will not be processed until lang_end()
- is called, long after this function has finished. So detect this
- case here and add the target's entry symbol to the list of starting
- points for garbage collection resolution. */
- lang_add_gc_name (entry_symbol_default);
- }
-
- lang_add_gc_name (link_info.init_function);
- lang_add_gc_name (link_info.fini_function);
-
- ldemul_after_open ();
- if (config.map_file != NULL)
- lang_print_asneeded ();
-
- ldlang_open_ctf ();
-
- bfd_section_already_linked_table_free ();
-
- /* Make sure that we're not mixing architectures. We call this
- after all the input files have been opened, but before we do any
- other processing, so that any operations merge_private_bfd_data
- does on the output file will be known during the rest of the
- link. */
- lang_check ();
-
- /* Handle .exports instead of a version script if we're told to do so. */
- if (command_line.version_exports_section)
- lang_do_version_exports_section ();
-
- /* Build all sets based on the information gathered from the input
- files. */
- ldctor_build_sets ();
-
- lang_symbol_tweaks ();
-
- /* PR 13683: We must rerun the assignments prior to running garbage
- collection in order to make sure that all symbol aliases are resolved. */
- lang_do_assignments (lang_mark_phase_enum);
- expld.phase = lang_first_phase_enum;
-
- /* Size up the common data. */
- lang_common ();
-
- if (0)
- debug_prefix_tree ();
-
- resolve_wilds ();
-
- /* Remove unreferenced sections if asked to. */
- lang_gc_sections ();
-
- lang_mark_undefineds ();
-
- /* Check relocations. */
- lang_check_relocs ();
-
- ldemul_after_check_relocs ();
-
- /* There might have been new sections created (e.g. as result of
- checking relocs to need a .got, or suchlike), so to properly order
- them into our lists of matching sections reset them here. */
- reset_resolved_wilds ();
- resolve_wilds ();
-
- /* Update wild statements in case the user gave --sort-section.
- Note how the option might have come after the linker script and
- so couldn't have been set when the wild statements were created. */
- update_wild_statements (statement_list.head);
-
- /* Run through the contours of the script and attach input sections
- to the correct output sections. */
- lang_statement_iteration++;
- map_input_to_output_sections (statement_list.head, NULL, NULL);
-
- /* Start at the statement immediately after the special abs_section
- output statement, so that it isn't reordered. */
- process_insert_statements (&lang_os_list.head->header.next);
-
- ldemul_before_place_orphans ();
-
- /* Find any sections not attached explicitly and handle them. */
- lang_place_orphans ();
-
- if (!bfd_link_relocatable (&link_info))
- {
- asection *found;
-
- /* Merge SEC_MERGE sections. This has to be done after GC of
- sections, so that GCed sections are not merged, but before
- assigning dynamic symbols, since removing whole input sections
- is hard then. */
- bfd_merge_sections (link_info.output_bfd, &link_info);
-
- /* Look for a text section and set the readonly attribute in it. */
- found = bfd_get_section_by_name (link_info.output_bfd, ".text");
-
- if (found != NULL)
- {
- if (config.text_read_only)
- found->flags |= SEC_READONLY;
- else
- found->flags &= ~SEC_READONLY;
- }
- }
-
- /* Merge together CTF sections. After this, only the symtab-dependent
- function and data object sections need adjustment. */
- lang_merge_ctf ();
-
- /* Emit the CTF, iff the emulation doesn't need to do late emission after
- examining things laid out late, like the strtab. */
- lang_write_ctf (0);
-
- /* Copy forward lma regions for output sections in same lma region. */
- lang_propagate_lma_regions ();
-
- /* Defining __start/__stop symbols early for --gc-sections to work
- around a glibc build problem can result in these symbols being
- defined when they should not be. Fix them now. */
- if (config.build_constructors)
- lang_undef_start_stop ();
-
- /* Define .startof./.sizeof. symbols with preliminary values before
- dynamic symbols are created. */
- if (!bfd_link_relocatable (&link_info))
- lang_init_startof_sizeof ();
-
- /* Do anything special before sizing sections. This is where ELF
- and other back-ends size dynamic sections. */
- ldemul_before_allocation ();
-
- /* We must record the program headers before we try to fix the
- section positions, since they will affect SIZEOF_HEADERS. */
- lang_record_phdrs ();
-
- /* Check relro sections. */
- if (link_info.relro && !bfd_link_relocatable (&link_info))
- lang_find_relro_sections ();
-
- /* Size up the sections. */
- lang_size_sections (NULL, !RELAXATION_ENABLED);
-
- /* See if anything special should be done now we know how big
- everything is. This is where relaxation is done. */
- ldemul_after_allocation ();
-
- /* Fix any __start, __stop, .startof. or .sizeof. symbols. */
- lang_finalize_start_stop ();
-
- /* Do all the assignments again, to report errors. Assignment
- statements are processed multiple times, updating symbols; In
- open_input_bfds, lang_do_assignments, and lang_size_sections.
- Since lang_relax_sections calls lang_do_assignments, symbols are
- also updated in ldemul_after_allocation. */
- lang_do_assignments (lang_final_phase_enum);
-
- ldemul_finish ();
-
- /* Convert absolute symbols to section relative. */
- ldexp_finalize_syms ();
-
- /* Make sure that the section addresses make sense. */
- if (command_line.check_section_addresses)
- lang_check_section_addresses ();
-
- if (link_info.non_contiguous_regions
- && link_info.non_contiguous_regions_warnings)
- warn_non_contiguous_discards ();
-
- /* Check any required symbols are known. */
- ldlang_check_require_defined_symbols ();
-
- lang_end ();
-}
-
-void
-lang_add_version_string (void)
-{
- if (! enable_linker_version)
- return;
-
- const char * str = "GNU ld ";
- int len = strlen (str);
- int i;
-
- for (i = 0 ; i < len ; i++)
- lang_add_data (BYTE, exp_intop (str[i]));
-
- str = BFD_VERSION_STRING;
- len = strlen (str);
-
- for (i = 0 ; i < len ; i++)
- lang_add_data (BYTE, exp_intop (str[i]));
-
- lang_add_data (BYTE, exp_intop ('\0'));
-}
-
-/* EXPORTED TO YACC */
-
-void
-lang_add_wild (struct wildcard_spec *filespec,
- struct wildcard_list *section_list,
- bool keep_sections)
-{
- struct wildcard_list *curr, *next;
- lang_wild_statement_type *new_stmt;
- bool any_specs_sorted = false;
-
- /* Reverse the list as the parser puts it back to front. */
- for (curr = section_list, section_list = NULL;
- curr != NULL;
- section_list = curr, curr = next)
- {
- if (curr->spec.sorted != none && curr->spec.sorted != by_none)
- any_specs_sorted = true;
- next = curr->next;
- curr->next = section_list;
- }
-
- if (filespec != NULL && filespec->name != NULL)
- {
- if (strcmp (filespec->name, "*") == 0)
- filespec->name = NULL;
- else if (!wildcardp (filespec->name))
- lang_has_input_file = true;
- }
-
- new_stmt = new_stat (lang_wild_statement, stat_ptr);
- new_stmt->filename = NULL;
- new_stmt->filenames_sorted = false;
- new_stmt->any_specs_sorted = any_specs_sorted;
- new_stmt->section_flag_list = NULL;
- new_stmt->exclude_name_list = NULL;
- if (filespec != NULL)
- {
- new_stmt->filename = filespec->name;
- new_stmt->filenames_sorted = (filespec->sorted == by_name || filespec->reversed);
- new_stmt->section_flag_list = filespec->section_flag_list;
- new_stmt->exclude_name_list = filespec->exclude_name_list;
- new_stmt->filenames_reversed = filespec->reversed;
- }
- new_stmt->section_list = section_list;
- new_stmt->keep_sections = keep_sections;
- lang_list_init (&new_stmt->children);
- lang_list_init (&new_stmt->matching_sections);
- analyze_walk_wild_section_handler (new_stmt);
- if (0)
- {
- printf ("wild %s(", new_stmt->filename ? new_stmt->filename : "*");
- for (curr = new_stmt->section_list; curr; curr = curr->next)
- printf ("%s ", curr->spec.name ? curr->spec.name : "*");
- printf (")\n");
- }
-}
-
-void
-lang_section_start (const char *name, etree_type *address,
- const segment_type *segment)
-{
- lang_address_statement_type *ad;
-
- ad = new_stat (lang_address_statement, stat_ptr);
- ad->section_name = name;
- ad->address = address;
- ad->segment = segment;
-}
-
-/* Set the start symbol to NAME. CMDLINE is nonzero if this is called
- because of a -e argument on the command line, or zero if this is
- called by ENTRY in a linker script. Command line arguments take
- precedence. */
-
-void
-lang_add_entry (const char *name, bool cmdline)
-{
- if (entry_symbol.name == NULL
- || cmdline
- || !entry_from_cmdline)
- {
- entry_symbol.name = name;
- entry_from_cmdline = cmdline;
- }
-}
-
-/* Set the default start symbol to NAME. .em files should use this,
- not lang_add_entry, to override the use of "start" if neither the
- linker script nor the command line specifies an entry point. NAME
- must be permanently allocated. */
-void
-lang_default_entry (const char *name)
-{
- entry_symbol_default = name;
-}
-
-void
-lang_add_target (const char *name)
-{
- lang_target_statement_type *new_stmt;
-
- new_stmt = new_stat (lang_target_statement, stat_ptr);
- new_stmt->target = name;
-}
-
-void
-lang_add_map (const char *name)
-{
- while (*name)
- {
- switch (*name)
- {
- case 'F':
- map_option_f = true;
- break;
- }
- name++;
- }
-}
-
-void
-lang_add_fill (fill_type *fill)
-{
- lang_fill_statement_type *new_stmt;
-
- new_stmt = new_stat (lang_fill_statement, stat_ptr);
- new_stmt->fill = fill;
-}
-
-void
-lang_add_data (int type, union etree_union *exp)
-{
- lang_data_statement_type *new_stmt;
-
- new_stmt = new_stat (lang_data_statement, stat_ptr);
- new_stmt->exp = exp;
- new_stmt->type = type;
-}
-
-void
-lang_add_string (const char *s)
-{
- bfd_vma len = strlen (s);
- bfd_vma i;
- bool escape = false;
-
- /* Add byte expressions until end of string. */
- for (i = 0 ; i < len; i++)
- {
- char c = *s++;
-
- if (escape)
- {
- switch (c)
- {
- default:
- /* Ignore the escape. */
- break;
-
- case 'n': c = '\n'; break;
- case 'r': c = '\r'; break;
- case 't': c = '\t'; break;
-
- case '0':
- case '1':
- case '2':
- case '3':
- case '4':
- case '5':
- case '6':
- case '7':
- /* We have an octal number. */
- {
- unsigned int value = c - '0';
-
- c = *s;
- if ((c >= '0') && (c <= '7'))
- {
- value <<= 3;
- value += (c - '0');
- i++;
- s++;
-
- c = *s;
- if ((c >= '0') && (c <= '7'))
- {
- value <<= 3;
- value += (c - '0');
- i++;
- s++;
- }
- }
-
- if (value > 0xff)
- {
- /* octal: \777 is treated as '\077' + '7' */
- value >>= 3;
- i--;
- s--;
- }
-
- c = value;
- }
- break;
- }
-
- lang_add_data (BYTE, exp_intop (c));
- escape = false;
- }
- else
- {
- if (c == '\\')
- escape = true;
- else
- lang_add_data (BYTE, exp_intop (c));
- }
- }
-
- /* Remeber to terminate the string. */
- lang_add_data (BYTE, exp_intop (0));
-}
-
-/* Create a new reloc statement. RELOC is the BFD relocation type to
- generate. HOWTO is the corresponding howto structure (we could
- look this up, but the caller has already done so). SECTION is the
- section to generate a reloc against, or NAME is the name of the
- symbol to generate a reloc against. Exactly one of SECTION and
- NAME must be NULL. ADDEND is an expression for the addend. */
-
-void
-lang_add_reloc (bfd_reloc_code_real_type reloc,
- reloc_howto_type *howto,
- asection *section,
- const char *name,
- union etree_union *addend)
-{
- lang_reloc_statement_type *p = new_stat (lang_reloc_statement, stat_ptr);
-
- p->reloc = reloc;
- p->howto = howto;
- p->section = section;
- p->name = name;
- p->addend_exp = addend;
-
- p->addend_value = 0;
- p->output_section = NULL;
- p->output_offset = 0;
-}
-
-lang_assignment_statement_type *
-lang_add_assignment (etree_type *exp)
-{
- lang_assignment_statement_type *new_stmt;
-
- new_stmt = new_stat (lang_assignment_statement, stat_ptr);
- new_stmt->exp = exp;
- return new_stmt;
-}
-
-void
-lang_add_attribute (enum statement_enum attribute)
-{
- new_statement (attribute, sizeof (lang_statement_header_type), stat_ptr);
-}
-
-void
-lang_startup (const char *name)
-{
- if (first_file->filename != NULL)
- {
- einfo (_("%F%P: multiple STARTUP files\n"));
- }
- first_file->filename = name;
- first_file->local_sym_name = name;
- first_file->flags.real = true;
-}
-
-void
-lang_float (bool maybe)
-{
- lang_float_flag = maybe;
-}
-
-
-/* Work out the load- and run-time regions from a script statement, and
- store them in *LMA_REGION and *REGION respectively.
-
- MEMSPEC is the name of the run-time region, or the value of
- DEFAULT_MEMORY_REGION if the statement didn't specify one.
- LMA_MEMSPEC is the name of the load-time region, or null if the
- statement didn't specify one.HAVE_LMA_P is TRUE if the statement
- had an explicit load address.
-
- It is an error to specify both a load region and a load address. */
-
-static void
-lang_get_regions (lang_memory_region_type **region,
- lang_memory_region_type **lma_region,
- const char *memspec,
- const char *lma_memspec,
- bool have_lma,
- bool have_vma)
-{
- *lma_region = lang_memory_region_lookup (lma_memspec, false);
-
- /* If no runtime region or VMA has been specified, but the load region
- has been specified, then use the load region for the runtime region
- as well. */
- if (lma_memspec != NULL
- && !have_vma
- && strcmp (memspec, DEFAULT_MEMORY_REGION) == 0)
- *region = *lma_region;
- else
- *region = lang_memory_region_lookup (memspec, false);
-
- if (have_lma && lma_memspec != 0)
- einfo (_("%X%P:%pS: section has both a load address and a load region\n"),
- NULL);
-}
-
-void
-lang_leave_output_section_statement (fill_type *fill, const char *memspec,
- lang_output_section_phdr_list *phdrs,
- const char *lma_memspec)
-{
- pop_stat_ptr ();
- if (in_section_ordering)
- return;
-
- lang_get_regions (¤t_section->region,
- ¤t_section->lma_region,
- memspec, lma_memspec,
- current_section->load_base != NULL,
- current_section->addr_tree != NULL);
-
- current_section->fill = fill;
- current_section->phdrs = phdrs;
-}
-
-/* Set the output format type. -oformat overrides scripts. */
-
-void
-lang_add_output_format (const char *format,
- const char *big,
- const char *little,
- int from_script)
-{
- if (output_target == NULL || !from_script)
- {
- if (command_line.endian == ENDIAN_BIG
- && big != NULL)
- format = big;
- else if (command_line.endian == ENDIAN_LITTLE
- && little != NULL)
- format = little;
-
- if (getenv ("LD_FORCE_LE") != NULL)
- {
- if (strcmp (format, "elf64-powerpc") == 0)
- format = "elf64-powerpcle";
- else if (strcmp (format, "elf32-powerpc") == 0)
- format = "elf32-powerpcle";
- else if (strcmp (format, "elf64-big") == 0)
- format = "elf64-little";
- else if (strcmp (format, "elf32-big") == 0)
- format = "elf32-little";
- }
-
- output_target = format;
- }
-}
-
-void
-lang_add_insert (const char *where, int is_before)
-{
- lang_insert_statement_type *new_stmt;
-
- new_stmt = new_stat (lang_insert_statement, stat_ptr);
- new_stmt->where = where;
- new_stmt->is_before = is_before;
- saved_script_handle = previous_script_handle;
-}
-
-/* Enter a group. This creates a new lang_group_statement, and sets
- stat_ptr to build new statements within the group. */
-
-void
-lang_enter_group (void)
-{
- lang_group_statement_type *g;
-
- g = new_stat (lang_group_statement, stat_ptr);
- lang_list_init (&g->children);
- push_stat_ptr (&g->children);
-}
-
-/* Leave a group. This just resets stat_ptr to start writing to the
- regular list of statements again. Note that this will not work if
- groups can occur inside anything else which can adjust stat_ptr,
- but currently they can't. */
-
-void
-lang_leave_group (void)
-{
- pop_stat_ptr ();
-}
-
-/* Add a new program header. This is called for each entry in a PHDRS
- command in a linker script. */
-
-void
-lang_new_phdr (const char *name,
- etree_type *type,
- bool filehdr,
- bool phdrs,
- etree_type *at,
- etree_type *flags)
-{
- struct lang_phdr *n, **pp;
- bool hdrs;
-
- n = stat_alloc (sizeof (struct lang_phdr));
- n->next = NULL;
- n->name = name;
- n->type = exp_get_vma (type, NULL, 0, "program header type");
- n->filehdr = filehdr;
- n->phdrs = phdrs;
- n->at = at;
- n->flags = flags;
-
- hdrs = n->type == 1 && (phdrs || filehdr);
-
- for (pp = &lang_phdr_list; *pp != NULL; pp = &(*pp)->next)
- if (hdrs
- && (*pp)->type == 1
- && !((*pp)->filehdr || (*pp)->phdrs))
- {
- einfo (_("%X%P:%pS: PHDRS and FILEHDR are not supported"
- " when prior PT_LOAD headers lack them\n"), NULL);
- hdrs = false;
- }
-
- *pp = n;
-}
-
-/* Record the program header information in the output BFD. FIXME: We
- should not be calling an ELF specific function here. */
-
-static void
-lang_record_phdrs (void)
-{
- unsigned int alc;
- asection **secs;
- lang_output_section_phdr_list *last;
- struct lang_phdr *l;
- lang_output_section_statement_type *os;
-
- alc = 10;
- secs = (asection **) xmalloc (alc * sizeof (asection *));
- last = NULL;
-
- for (l = lang_phdr_list; l != NULL; l = l->next)
- {
- unsigned int c;
- flagword flags;
- bfd_vma at;
-
- c = 0;
- for (os = (void *) lang_os_list.head;
- os != NULL;
- os = os->next)
- {
- lang_output_section_phdr_list *pl;
-
- if (os->constraint < 0)
- continue;
-
- pl = os->phdrs;
- if (pl != NULL)
- last = pl;
- else
- {
- if (os->sectype == noload_section
- || os->bfd_section == NULL
- || (os->bfd_section->flags & SEC_ALLOC) == 0)
- continue;
-
- /* Don't add orphans to PT_INTERP header. */
- if (l->type == 3)
- continue;
-
- if (last == NULL)
- {
- lang_output_section_statement_type *tmp_os;
-
- /* If we have not run across a section with a program
- header assigned to it yet, then scan forwards to find
- one. This prevents inconsistencies in the linker's
- behaviour when a script has specified just a single
- header and there are sections in that script which are
- not assigned to it, and which occur before the first
- use of that header. See here for more details:
- http://sourceware.org/ml/binutils/2007-02/msg00291.html */
- for (tmp_os = os; tmp_os; tmp_os = tmp_os->next)
- if (tmp_os->phdrs)
- {
- last = tmp_os->phdrs;
- break;
- }
- if (last == NULL)
- einfo (_("%F%P: no sections assigned to phdrs\n"));
- }
- pl = last;
- }
-
- if (os->bfd_section == NULL)
- continue;
-
- for (; pl != NULL; pl = pl->next)
- {
- if (strcmp (pl->name, l->name) == 0)
- {
- if (c >= alc)
- {
- alc *= 2;
- secs = (asection **) xrealloc (secs,
- alc * sizeof (asection *));
- }
- secs[c] = os->bfd_section;
- ++c;
- pl->used = true;
- }
- }
- }
-
- if (l->flags == NULL)
- flags = 0;
- else
- flags = exp_get_vma (l->flags, NULL, 0, "phdr flags");
-
- if (l->at == NULL)
- at = 0;
- else
- at = exp_get_vma (l->at, NULL, 0, "phdr load address");
-
- if (!bfd_record_phdr (link_info.output_bfd, l->type,
- l->flags != NULL, flags, l->at != NULL,
- at, l->filehdr, l->phdrs, c, secs))
- einfo (_("%F%P: bfd_record_phdr failed: %E\n"));
- }
-
- free (secs);
-
- /* Make sure all the phdr assignments succeeded. */
- for (os = (void *) lang_os_list.head;
- os != NULL;
- os = os->next)
- {
- lang_output_section_phdr_list *pl;
-
- if (os->constraint < 0
- || os->bfd_section == NULL)
- continue;
-
- for (pl = os->phdrs;
- pl != NULL;
- pl = pl->next)
- if (!pl->used && strcmp (pl->name, "NONE") != 0)
- einfo (_("%X%P: section `%s' assigned to non-existent phdr `%s'\n"),
- os->name, pl->name);
- }
-}
-
-/* Record a list of sections which may not be cross referenced. */
-
-void
-lang_add_nocrossref (lang_nocrossref_type *l)
-{
- struct lang_nocrossrefs *n;
-
- n = (struct lang_nocrossrefs *) xmalloc (sizeof *n);
- n->next = nocrossref_list;
- n->list = l;
- n->onlyfirst = false;
- nocrossref_list = n;
-
- /* Set notice_all so that we get informed about all symbols. */
- link_info.notice_all = true;
-}
-
-/* Record a section that cannot be referenced from a list of sections. */
-
-void
-lang_add_nocrossref_to (lang_nocrossref_type *l)
-{
- lang_add_nocrossref (l);
- nocrossref_list->onlyfirst = true;
-}
-
-/* Overlay handling. We handle overlays with some static variables. */
-
-/* The overlay virtual address. */
-static etree_type *overlay_vma;
-/* And subsection alignment. */
-static etree_type *overlay_subalign;
-
-/* An expression for the maximum section size seen so far. */
-static etree_type *overlay_max;
-
-/* A list of all the sections in this overlay. */
-
-struct overlay_list {
- struct overlay_list *next;
- lang_output_section_statement_type *os;
-};
-
-static struct overlay_list *overlay_list;
-
-/* Start handling an overlay. */
-
-void
-lang_enter_overlay (etree_type *vma_expr, etree_type *subalign)
-{
- /* The grammar should prevent nested overlays from occurring. */
- ASSERT (overlay_vma == NULL
- && overlay_subalign == NULL
- && overlay_max == NULL);
-
- overlay_vma = vma_expr;
- overlay_subalign = subalign;
-}
-
-/* Start a section in an overlay. We handle this by calling
- lang_enter_output_section_statement with the correct VMA.
- lang_leave_overlay sets up the LMA and memory regions. */
-
-void
-lang_enter_overlay_section (const char *name)
-{
- struct overlay_list *n;
- etree_type *size;
-
- lang_enter_output_section_statement (name, overlay_vma, overlay_section,
- 0, 0, overlay_subalign, 0, 0, 0);
-
- /* If this is the first section, then base the VMA of future
- sections on this one. This will work correctly even if `.' is
- used in the addresses. */
- if (overlay_list == NULL)
- overlay_vma = exp_nameop (ADDR, name);
-
- /* Remember the section. */
- n = (struct overlay_list *) xmalloc (sizeof *n);
- n->os = current_section;
- n->next = overlay_list;
- overlay_list = n;
-
- size = exp_nameop (SIZEOF, name);
-
- /* Arrange to work out the maximum section end address. */
- if (overlay_max == NULL)
- overlay_max = size;
- else
- overlay_max = exp_binop (MAX_K, overlay_max, size);
-}
-
-/* Finish a section in an overlay. There isn't any special to do
- here. */
-
-void
-lang_leave_overlay_section (fill_type *fill,
- lang_output_section_phdr_list *phdrs)
-{
- const char *name;
- char *clean, *s2;
- const char *s1;
- char *buf;
-
- name = current_section->name;
-
- /* For now, assume that DEFAULT_MEMORY_REGION is the run-time memory
- region and that no load-time region has been specified. It doesn't
- really matter what we say here, since lang_leave_overlay will
- override it. */
- lang_leave_output_section_statement (fill, DEFAULT_MEMORY_REGION, phdrs, 0);
-
- /* Define the magic symbols. */
-
- clean = (char *) xmalloc (strlen (name) + 1);
- s2 = clean;
- for (s1 = name; *s1 != '\0'; s1++)
- if (ISALNUM (*s1) || *s1 == '_')
- *s2++ = *s1;
- *s2 = '\0';
-
- buf = (char *) xmalloc (strlen (clean) + sizeof "__load_start_");
- sprintf (buf, "__load_start_%s", clean);
- lang_add_assignment (exp_provide (buf,
- exp_nameop (LOADADDR, name),
- false));
-
- buf = (char *) xmalloc (strlen (clean) + sizeof "__load_stop_");
- sprintf (buf, "__load_stop_%s", clean);
- lang_add_assignment (exp_provide (buf,
- exp_binop ('+',
- exp_nameop (LOADADDR, name),
- exp_nameop (SIZEOF, name)),
- false));
-
- free (clean);
-}
-
-/* Finish an overlay. If there are any overlay wide settings, this
- looks through all the sections in the overlay and sets them. */
-
-void
-lang_leave_overlay (etree_type *lma_expr,
- int nocrossrefs,
- fill_type *fill,
- const char *memspec,
- lang_output_section_phdr_list *phdrs,
- const char *lma_memspec)
-{
- lang_memory_region_type *region;
- lang_memory_region_type *lma_region;
- struct overlay_list *l;
- lang_nocrossref_type *nocrossref;
-
- lang_get_regions (®ion, &lma_region,
- memspec, lma_memspec,
- lma_expr != NULL, false);
-
- nocrossref = NULL;
-
- /* After setting the size of the last section, set '.' to end of the
- overlay region. */
- if (overlay_list != NULL)
- {
- overlay_list->os->update_dot = 1;
- overlay_list->os->update_dot_tree
- = exp_assign (".", exp_binop ('+', overlay_vma, overlay_max), false);
- }
-
- l = overlay_list;
- while (l != NULL)
- {
- struct overlay_list *next;
-
- if (fill != NULL && l->os->fill == NULL)
- l->os->fill = fill;
-
- l->os->region = region;
- l->os->lma_region = lma_region;
-
- /* The first section has the load address specified in the
- OVERLAY statement. The rest are worked out from that.
- The base address is not needed (and should be null) if
- an LMA region was specified. */
- if (l->next == 0)
- {
- l->os->load_base = lma_expr;
- l->os->sectype = first_overlay_section;
- }
- if (phdrs != NULL && l->os->phdrs == NULL)
- l->os->phdrs = phdrs;
-
- if (nocrossrefs)
- {
- lang_nocrossref_type *nc;
-
- nc = (lang_nocrossref_type *) xmalloc (sizeof *nc);
- nc->name = l->os->name;
- nc->next = nocrossref;
- nocrossref = nc;
- }
-
- next = l->next;
- free (l);
- l = next;
- }
-
- if (nocrossref != NULL)
- lang_add_nocrossref (nocrossref);
-
- overlay_vma = NULL;
- overlay_list = NULL;
- overlay_max = NULL;
- overlay_subalign = NULL;
-}
-
-/* Version handling. This is only useful for ELF. */
-
-/* If PREV is NULL, return first version pattern matching particular symbol.
- If PREV is non-NULL, return first version pattern matching particular
- symbol after PREV (previously returned by lang_vers_match). */
-
-static struct bfd_elf_version_expr *
-lang_vers_match (struct bfd_elf_version_expr_head *head,
- struct bfd_elf_version_expr *prev,
- const char *sym)
-{
- const char *c_sym;
- const char *cxx_sym = sym;
- const char *java_sym = sym;
- struct bfd_elf_version_expr *expr = NULL;
- enum demangling_styles curr_style;
-
- curr_style = CURRENT_DEMANGLING_STYLE;
- cplus_demangle_set_style (no_demangling);
- c_sym = bfd_demangle (link_info.output_bfd, sym, DMGL_NO_OPTS);
- if (!c_sym)
- c_sym = sym;
- cplus_demangle_set_style (curr_style);
-
- if (head->mask & BFD_ELF_VERSION_CXX_TYPE)
- {
- cxx_sym = bfd_demangle (link_info.output_bfd, sym,
- DMGL_PARAMS | DMGL_ANSI);
- if (!cxx_sym)
- cxx_sym = sym;
- }
- if (head->mask & BFD_ELF_VERSION_JAVA_TYPE)
- {
- java_sym = bfd_demangle (link_info.output_bfd, sym, DMGL_JAVA);
- if (!java_sym)
- java_sym = sym;
- }
-
- if (head->htab && (prev == NULL || prev->literal))
- {
- struct bfd_elf_version_expr e;
-
- switch (prev ? prev->mask : 0)
- {
- case 0:
- if (head->mask & BFD_ELF_VERSION_C_TYPE)
- {
- e.pattern = c_sym;
- expr = (struct bfd_elf_version_expr *)
- htab_find ((htab_t) head->htab, &e);
- while (expr && strcmp (expr->pattern, c_sym) == 0)
- if (expr->mask == BFD_ELF_VERSION_C_TYPE)
- goto out_ret;
- else
- expr = expr->next;
- }
- /* Fallthrough */
- case BFD_ELF_VERSION_C_TYPE:
- if (head->mask & BFD_ELF_VERSION_CXX_TYPE)
- {
- e.pattern = cxx_sym;
- expr = (struct bfd_elf_version_expr *)
- htab_find ((htab_t) head->htab, &e);
- while (expr && strcmp (expr->pattern, cxx_sym) == 0)
- if (expr->mask == BFD_ELF_VERSION_CXX_TYPE)
- goto out_ret;
- else
- expr = expr->next;
- }
- /* Fallthrough */
- case BFD_ELF_VERSION_CXX_TYPE:
- if (head->mask & BFD_ELF_VERSION_JAVA_TYPE)
- {
- e.pattern = java_sym;
- expr = (struct bfd_elf_version_expr *)
- htab_find ((htab_t) head->htab, &e);
- while (expr && strcmp (expr->pattern, java_sym) == 0)
- if (expr->mask == BFD_ELF_VERSION_JAVA_TYPE)
- goto out_ret;
- else
- expr = expr->next;
- }
- /* Fallthrough */
- default:
- break;
- }
- }
-
- /* Finally, try the wildcards. */
- if (prev == NULL || prev->literal)
- expr = head->remaining;
- else
- expr = prev->next;
- for (; expr; expr = expr->next)
- {
- const char *s;
-
- if (!expr->pattern)
- continue;
-
- if (expr->pattern[0] == '*' && expr->pattern[1] == '\0')
- break;
-
- if (expr->mask == BFD_ELF_VERSION_JAVA_TYPE)
- s = java_sym;
- else if (expr->mask == BFD_ELF_VERSION_CXX_TYPE)
- s = cxx_sym;
- else
- s = c_sym;
- if (fnmatch (expr->pattern, s, 0) == 0)
- break;
- }
-
- out_ret:
- if (c_sym != sym)
- free ((char *) c_sym);
- if (cxx_sym != sym)
- free ((char *) cxx_sym);
- if (java_sym != sym)
- free ((char *) java_sym);
- return expr;
-}
-
-/* Return NULL if the PATTERN argument is a glob pattern, otherwise,
- return a pointer to the symbol name with any backslash quotes removed. */
-
-static const char *
-realsymbol (const char *pattern)
-{
- const char *p;
- bool changed = false, backslash = false;
- char *s, *symbol = (char *) xmalloc (strlen (pattern) + 1);
-
- for (p = pattern, s = symbol; *p != '\0'; ++p)
- {
- /* It is a glob pattern only if there is no preceding
- backslash. */
- if (backslash)
- {
- /* Remove the preceding backslash. */
- *(s - 1) = *p;
- backslash = false;
- changed = true;
- }
- else
- {
- if (*p == '?' || *p == '*' || *p == '[')
- {
- free (symbol);
- return NULL;
- }
-
- *s++ = *p;
- backslash = *p == '\\';
- }
- }
-
- if (changed)
- {
- *s = '\0';
- return symbol;
- }
- else
- {
- free (symbol);
- return pattern;
- }
-}
-
-/* This is called for each variable name or match expression. NEW_NAME is
- the name of the symbol to match, or, if LITERAL_P is FALSE, a glob
- pattern to be matched against symbol names. */
-
-struct bfd_elf_version_expr *
-lang_new_vers_pattern (struct bfd_elf_version_expr *orig,
- const char *new_name,
- const char *lang,
- bool literal_p)
-{
- struct bfd_elf_version_expr *ret;
-
- ret = (struct bfd_elf_version_expr *) xmalloc (sizeof *ret);
- ret->next = orig;
- ret->symver = 0;
- ret->script = 0;
- ret->literal = true;
- ret->pattern = literal_p ? new_name : realsymbol (new_name);
- if (ret->pattern == NULL)
- {
- ret->pattern = new_name;
- ret->literal = false;
- }
-
- if (lang == NULL || strcasecmp (lang, "C") == 0)
- ret->mask = BFD_ELF_VERSION_C_TYPE;
- else if (strcasecmp (lang, "C++") == 0)
- ret->mask = BFD_ELF_VERSION_CXX_TYPE;
- else if (strcasecmp (lang, "Java") == 0)
- ret->mask = BFD_ELF_VERSION_JAVA_TYPE;
- else
- {
- einfo (_("%X%P: unknown language `%s' in version information\n"),
- lang);
- ret->mask = BFD_ELF_VERSION_C_TYPE;
- }
-
- return ldemul_new_vers_pattern (ret);
-}
-
-/* This is called for each set of variable names and match
- expressions. */
-
-struct bfd_elf_version_tree *
-lang_new_vers_node (struct bfd_elf_version_expr *globals,
- struct bfd_elf_version_expr *locals)
-{
- struct bfd_elf_version_tree *ret;
-
- ret = (struct bfd_elf_version_tree *) xcalloc (1, sizeof *ret);
- ret->globals.list = globals;
- ret->locals.list = locals;
- ret->match = lang_vers_match;
- ret->name_indx = (unsigned int) -1;
- return ret;
-}
-
-/* This static variable keeps track of version indices. */
-
-static int version_index;
-
-static hashval_t
-version_expr_head_hash (const void *p)
-{
- const struct bfd_elf_version_expr *e =
- (const struct bfd_elf_version_expr *) p;
-
- return htab_hash_string (e->pattern);
-}
-
-static int
-version_expr_head_eq (const void *p1, const void *p2)
-{
- const struct bfd_elf_version_expr *e1 =
- (const struct bfd_elf_version_expr *) p1;
- const struct bfd_elf_version_expr *e2 =
- (const struct bfd_elf_version_expr *) p2;
-
- return strcmp (e1->pattern, e2->pattern) == 0;
-}
-
-static void
-lang_finalize_version_expr_head (struct bfd_elf_version_expr_head *head)
-{
- size_t count = 0;
- struct bfd_elf_version_expr *e, *next;
- struct bfd_elf_version_expr **list_loc, **remaining_loc;
-
- for (e = head->list; e; e = e->next)
- {
- if (e->literal)
- count++;
- head->mask |= e->mask;
- }
-
- if (count)
- {
- head->htab = htab_create (count * 2, version_expr_head_hash,
- version_expr_head_eq, NULL);
- list_loc = &head->list;
- remaining_loc = &head->remaining;
- for (e = head->list; e; e = next)
- {
- next = e->next;
- if (!e->literal)
- {
- *remaining_loc = e;
- remaining_loc = &e->next;
- }
- else
- {
- void **loc = htab_find_slot ((htab_t) head->htab, e, INSERT);
-
- if (*loc)
- {
- struct bfd_elf_version_expr *e1, *last;
-
- e1 = (struct bfd_elf_version_expr *) *loc;
- last = NULL;
- do
- {
- if (e1->mask == e->mask)
- {
- last = NULL;
- break;
- }
- last = e1;
- e1 = e1->next;
- }
- while (e1 && strcmp (e1->pattern, e->pattern) == 0);
-
- if (last == NULL)
- {
- /* This is a duplicate. */
- /* FIXME: Memory leak. Sometimes pattern is not
- xmalloced alone, but in larger chunk of memory. */
- /* free (e->pattern); */
- free (e);
- }
- else
- {
- e->next = last->next;
- last->next = e;
- }
- }
- else
- {
- *loc = e;
- *list_loc = e;
- list_loc = &e->next;
- }
- }
- }
- *remaining_loc = NULL;
- *list_loc = head->remaining;
- }
- else
- head->remaining = head->list;
-}
-
-/* This is called when we know the name and dependencies of the
- version. */
-
-void
-lang_register_vers_node (const char *name,
- struct bfd_elf_version_tree *version,
- struct bfd_elf_version_deps *deps)
-{
- struct bfd_elf_version_tree *t, **pp;
- struct bfd_elf_version_expr *e1;
-
- if (name == NULL)
- name = "";
-
- if (link_info.version_info != NULL
- && (name[0] == '\0' || link_info.version_info->name[0] == '\0'))
- {
- einfo (_("%X%P: anonymous version tag cannot be combined"
- " with other version tags\n"));
- free (version);
- return;
- }
-
- /* Make sure this node has a unique name. */
- for (t = link_info.version_info; t != NULL; t = t->next)
- if (strcmp (t->name, name) == 0)
- einfo (_("%X%P: duplicate version tag `%s'\n"), name);
-
- lang_finalize_version_expr_head (&version->globals);
- lang_finalize_version_expr_head (&version->locals);
-
- /* Check the global and local match names, and make sure there
- aren't any duplicates. */
-
- for (e1 = version->globals.list; e1 != NULL; e1 = e1->next)
- {
- for (t = link_info.version_info; t != NULL; t = t->next)
- {
- struct bfd_elf_version_expr *e2;
-
- if (t->locals.htab && e1->literal)
- {
- e2 = (struct bfd_elf_version_expr *)
- htab_find ((htab_t) t->locals.htab, e1);
- while (e2 && strcmp (e1->pattern, e2->pattern) == 0)
- {
- if (e1->mask == e2->mask)
- einfo (_("%X%P: duplicate expression `%s'"
- " in version information\n"), e1->pattern);
- e2 = e2->next;
- }
- }
- else if (!e1->literal)
- for (e2 = t->locals.remaining; e2 != NULL; e2 = e2->next)
- if (strcmp (e1->pattern, e2->pattern) == 0
- && e1->mask == e2->mask)
- einfo (_("%X%P: duplicate expression `%s'"
- " in version information\n"), e1->pattern);
- }
- }
-
- for (e1 = version->locals.list; e1 != NULL; e1 = e1->next)
- {
- for (t = link_info.version_info; t != NULL; t = t->next)
- {
- struct bfd_elf_version_expr *e2;
-
- if (t->globals.htab && e1->literal)
- {
- e2 = (struct bfd_elf_version_expr *)
- htab_find ((htab_t) t->globals.htab, e1);
- while (e2 && strcmp (e1->pattern, e2->pattern) == 0)
- {
- if (e1->mask == e2->mask)
- einfo (_("%X%P: duplicate expression `%s'"
- " in version information\n"),
- e1->pattern);
- e2 = e2->next;
- }
- }
- else if (!e1->literal)
- for (e2 = t->globals.remaining; e2 != NULL; e2 = e2->next)
- if (strcmp (e1->pattern, e2->pattern) == 0
- && e1->mask == e2->mask)
- einfo (_("%X%P: duplicate expression `%s'"
- " in version information\n"), e1->pattern);
- }
- }
-
- version->deps = deps;
- version->name = name;
- if (name[0] != '\0')
- {
- ++version_index;
- version->vernum = version_index;
- }
- else
- version->vernum = 0;
-
- for (pp = &link_info.version_info; *pp != NULL; pp = &(*pp)->next)
- ;
- *pp = version;
-}
-
-/* This is called when we see a version dependency. */
-
-struct bfd_elf_version_deps *
-lang_add_vers_depend (struct bfd_elf_version_deps *list, const char *name)
-{
- struct bfd_elf_version_deps *ret;
- struct bfd_elf_version_tree *t;
-
- ret = (struct bfd_elf_version_deps *) xmalloc (sizeof *ret);
- ret->next = list;
-
- for (t = link_info.version_info; t != NULL; t = t->next)
- {
- if (strcmp (t->name, name) == 0)
- {
- ret->version_needed = t;
- return ret;
- }
- }
-
- einfo (_("%X%P: unable to find version dependency `%s'\n"), name);
-
- ret->version_needed = NULL;
- return ret;
-}
-
-static void
-lang_do_version_exports_section (void)
-{
- struct bfd_elf_version_expr *greg = NULL, *lreg;
-
- LANG_FOR_EACH_INPUT_STATEMENT (is)
- {
- asection *sec = bfd_get_section_by_name (is->the_bfd, ".exports");
- char *contents, *p;
- bfd_size_type len;
-
- if (sec == NULL)
- continue;
-
- len = sec->size;
- contents = (char *) xmalloc (len);
- if (!bfd_get_section_contents (is->the_bfd, sec, contents, 0, len))
- einfo (_("%X%P: unable to read .exports section contents\n"), sec);
-
- p = contents;
- while (p < contents + len)
- {
- greg = lang_new_vers_pattern (greg, p, NULL, false);
- p = strchr (p, '\0') + 1;
- }
-
- /* Do not free the contents, as we used them creating the regex. */
-
- /* Do not include this section in the link. */
- sec->flags |= SEC_EXCLUDE | SEC_KEEP;
- }
-
- lreg = lang_new_vers_pattern (NULL, "*", NULL, false);
- lang_register_vers_node (command_line.version_exports_section,
- lang_new_vers_node (greg, lreg), NULL);
-}
-
-/* Evaluate LENGTH and ORIGIN parts of MEMORY spec. This is initially
- called with UPDATE_REGIONS_P set to FALSE, in this case no errors are
- thrown, however, references to symbols in the origin and length fields
- will be pushed into the symbol table, this allows PROVIDE statements to
- then provide these symbols. This function is called a second time with
- UPDATE_REGIONS_P set to TRUE, this time the we update the actual region
- data structures, and throw errors if missing symbols are encountered. */
-
-static void
-lang_do_memory_regions (bool update_regions_p)
-{
- lang_memory_region_type *r = lang_memory_region_list;
-
- for (; r != NULL; r = r->next)
- {
- if (r->origin_exp)
- {
- exp_fold_tree_no_dot (r->origin_exp, NULL);
- if (update_regions_p)
- {
- if (expld.result.valid_p)
- {
- r->origin = expld.result.value;
- r->current = r->origin;
- }
- else
- einfo (_("%P: invalid origin for memory region %s\n"),
- r->name_list.name);
- }
- }
- if (r->length_exp)
- {
- exp_fold_tree_no_dot (r->length_exp, NULL);
- if (update_regions_p)
- {
- if (expld.result.valid_p)
- r->length = expld.result.value;
- else
- einfo (_("%P: invalid length for memory region %s\n"),
- r->name_list.name);
- }
- }
- }
-}
-
-void
-lang_add_unique (const char *name)
-{
- struct unique_sections *ent;
-
- for (ent = unique_section_list; ent; ent = ent->next)
- if (strcmp (ent->name, name) == 0)
- return;
-
- ent = (struct unique_sections *) xmalloc (sizeof *ent);
- ent->name = xstrdup (name);
- ent->next = unique_section_list;
- unique_section_list = ent;
-}
-
-/* Append the list of dynamic symbols to the existing one. */
-
-void
-lang_append_dynamic_list (struct bfd_elf_dynamic_list **list_p,
- struct bfd_elf_version_expr *dynamic)
-{
- if (*list_p)
- {
- struct bfd_elf_version_expr *tail;
- for (tail = dynamic; tail->next != NULL; tail = tail->next)
- ;
- tail->next = (*list_p)->head.list;
- (*list_p)->head.list = dynamic;
- }
- else
- {
- struct bfd_elf_dynamic_list *d;
-
- d = (struct bfd_elf_dynamic_list *) xcalloc (1, sizeof *d);
- d->head.list = dynamic;
- d->match = lang_vers_match;
- *list_p = d;
- }
-}
-
-/* Append the list of C++ typeinfo dynamic symbols to the existing
- one. */
-
-void
-lang_append_dynamic_list_cpp_typeinfo (void)
-{
- const char *symbols[] =
- {
- "typeinfo name for*",
- "typeinfo for*"
- };
- struct bfd_elf_version_expr *dynamic = NULL;
- unsigned int i;
-
- for (i = 0; i < ARRAY_SIZE (symbols); i++)
- dynamic = lang_new_vers_pattern (dynamic, symbols [i], "C++",
- false);
-
- lang_append_dynamic_list (&link_info.dynamic_list, dynamic);
-}
-
-/* Append the list of C++ operator new and delete dynamic symbols to the
- existing one. */
-
-void
-lang_append_dynamic_list_cpp_new (void)
-{
- const char *symbols[] =
- {
- "operator new*",
- "operator delete*"
- };
- struct bfd_elf_version_expr *dynamic = NULL;
- unsigned int i;
-
- for (i = 0; i < ARRAY_SIZE (symbols); i++)
- dynamic = lang_new_vers_pattern (dynamic, symbols [i], "C++",
- false);
-
- lang_append_dynamic_list (&link_info.dynamic_list, dynamic);
-}
-
-/* Scan a space and/or comma separated string of features. */
-
-void
-lang_ld_feature (char *str)
-{
- char *p, *q;
-
- p = str;
- while (*p)
- {
- char sep;
- while (*p == ',' || ISSPACE (*p))
- ++p;
- if (!*p)
- break;
- q = p + 1;
- while (*q && *q != ',' && !ISSPACE (*q))
- ++q;
- sep = *q;
- *q = 0;
- if (strcasecmp (p, "SANE_EXPR") == 0)
- config.sane_expr = true;
- else
- einfo (_("%X%P: unknown feature `%s'\n"), p);
- *q = sep;
- p = q;
- }
-}
-
-/* Pretty print memory amount. */
-
-static void
-lang_print_memory_size (uint64_t sz)
-{
- if (sz == 0)
- printf (" %10" PRIu64 " B", sz);
- else if ((sz & 0x3fffffff) == 0)
- printf ("%10" PRIu64 " GB", sz >> 30);
- else if ((sz & 0xfffff) == 0)
- printf ("%10" PRIu64 " MB", sz >> 20);
- else if ((sz & 0x3ff) == 0)
- printf ("%10" PRIu64 " KB", sz >> 10);
- else
- printf (" %10" PRIu64 " B", sz);
-}
-
-/* Implement --print-memory-usage: disply per region memory usage. */
-
-void
-lang_print_memory_usage (void)
-{
- lang_memory_region_type *r;
-
- printf ("Memory region Used Size Region Size %%age Used\n");
- for (r = lang_memory_region_list; r->next != NULL; r = r->next)
- {
- bfd_vma used_length = r->current - r->origin;
-
- printf ("%16s: ",r->name_list.name);
- lang_print_memory_size (used_length);
- lang_print_memory_size (r->length);
-
- if (r->length != 0)
- {
- double percent = used_length * 100.0 / r->length;
- printf (" %6.2f%%", percent);
- }
- printf ("\n");
- }
-}
Index: sources/GNU/binutils/create-2.43.1-cleansweep-patch/file.list
===================================================================
--- sources/GNU/binutils/create-2.43.1-cleansweep-patch/file.list (revision 75)
+++ sources/GNU/binutils/create-2.43.1-cleansweep-patch/file.list (nonexistent)
@@ -1,2 +0,0 @@
-binutils-2.43.1/ld/testsuite/ld-plugin/lto.exp
-binutils-2.43.1/ld/testsuite/ld-size/size.exp
Index: sources/GNU/binutils/create-2.43.1-cleansweep-patch/create.patch.sh
===================================================================
--- sources/GNU/binutils/create-2.43.1-cleansweep-patch/create.patch.sh (revision 75)
+++ sources/GNU/binutils/create-2.43.1-cleansweep-patch/create.patch.sh (nonexistent)
@@ -1,15 +0,0 @@
-#!/bin/bash
-
-VERSION=2.43.1
-
-tar --files-from=file.list -xJvf ../binutils-$VERSION.tar.xz
-mv binutils-$VERSION binutils-$VERSION-orig
-
-cp -rf ./binutils-$VERSION-new ./binutils-$VERSION
-
-diff --unified -Nr binutils-$VERSION-orig binutils-$VERSION > binutils-$VERSION-cleansweep.patch
-
-mv binutils-$VERSION-cleansweep.patch ../patches
-
-rm -rf ./binutils-$VERSION
-rm -rf ./binutils-$VERSION-orig
Property changes on: sources/GNU/binutils/create-2.43.1-cleansweep-patch/create.patch.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: sources/GNU/binutils/create-2.43.1-cleansweep-patch/binutils-2.43.1-new/ld/testsuite/ld-size/size.exp
===================================================================
--- sources/GNU/binutils/create-2.43.1-cleansweep-patch/binutils-2.43.1-new/ld/testsuite/ld-size/size.exp (revision 75)
+++ sources/GNU/binutils/create-2.43.1-cleansweep-patch/binutils-2.43.1-new/ld/testsuite/ld-size/size.exp (nonexistent)
@@ -1,279 +0,0 @@
-# Expect script for linker support of size relocations.
-#
-# Copyright (C) 2013-2024 Free Software Foundation, Inc.
-#
-# This file is part of the GNU Binutils.
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 3 of the License, or
-# (at your option) any later version.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this program; if not, write to the Free Software
-# Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston,
-# MA 02110-1301, USA.
-#
-
-
-# Size relocations have only been implemented for the ix86 and x86_64,
-# so far.
-if {!(([istarget "i?86-*-*"]
- || [istarget "x86_64-*-*"])
- && ([istarget "*-*-elf*"]
- || [istarget "*-*-nacl*"]
- || [istarget "*-*-linux*"]
- || [istarget "*-*-gnu*"])) } {
- verbose "Size relocations tests not run - no target support"
- return
-}
-
-# Skip when -shared is not supported
-if { ![check_shared_lib_support] } {
- verbose "Size relocation tests not run - shared support disabled"
- return
-}
-
-# So as to avoid rewriting every last test case here in a nacl variant,
-# we use black magic to massage the generic cases into nacl-variant cases.
-if [istarget "*-*-nacl*"] {
- # Change all the -melf_i386 to -melf_i386_nacl so linking can succeed.
- set options_regsub(ld) {-m(\\S+) -m\\1_nacl}
-}
-
-set test_list [lsort [glob -nocomplain $srcdir/$subdir/*.d]]
-foreach t $test_list {
- # We need to strip the ".d", but can leave the dirname.
- verbose [file rootname $t]
- run_dump_test [file rootname $t]
-}
-
-# We need a working compiler.
-if { ![check_compiler_available] } {
- verbose "Native size relocation tests not run - no compiler available"
- return
-}
-
-run_cc_link_tests [list \
- [list \
- "Build libsize-1.so" \
- "-shared" \
- "-fPIC" \
- {size-1a.c size-1b.c} \
- {} \
- "libsize-1.so" \
- ] \
- [list \
- "Build libsize-2.so" \
- "-shared" \
- "-fPIC" \
- {size-2a.c size-2b.c} \
- {} \
- "libsize-2.so" \
- ] \
- [list \
- "Build libsize-3a.so" \
- "-shared" "-fPIC" \
- {size-3a.c} \
- {} \
- "libsize-3a.so" \
- ] \
- [list \
- "Build libsize-3b.so" \
- "-shared" \
- "-fPIC" \
- {size-3b.c} \
- {} \
- "libsize-3b.so" \
- ] \
- [list \
- "Build libsize-3c.so" \
- "-shared" \
- "-fPIC" \
- {size-3c.c} \
- {} \
- "libsize-3c.so" \
- ] \
- [list \
- "Build libsize-6b.so" \
- "-shared" \
- "-fPIC" \
- {size-6b.c} \
- {} \
- "libsize-6b.so" \
- ] \
- [list \
- "Build libsize-9.so" \
- "-shared $NOSANITIZE_CFLAGS" \
- "-fPIC $NOSANITIZE_CFLAGS" \
- {size-9b.c} \
- {{readelf -rW size-9.rd}} \
- "libsize-9.so" \
- ] \
- [list \
- "Build libsize-10.so" \
- "-shared" \
- "-fPIC" \
- {size-10b.c} \
- {{readelf -rW size-10.rd}} \
- "libsize-10.so" \
- ] \
-]
-
-return
-
-# Check if size relocation works at run-time.
-catch "exec tmpdir/size-7.exe > tmpdir/dump.out" exec_output
-if ![string match "" $exec_output] then {
- send_log "No run-time size relocation support: $exec_output\n"
- verbose "No run-time size relocation support: $exec_output" 1
- return
-}
-
-if { [regexp_diff "tmpdir/dump.out" "$srcdir/$subdir/size-7.out" ] } then {
- verbose "output is [file_contents "tmpdir/dump.out"]" 2
- fail "Run-time size relocation"
- return
-}
-
-# Run-time size relocation tests.
-run_ld_link_exec_tests [list \
- [list \
- "Run size-1" \
- "-Wl,--no-as-needed tmpdir/libsize-1.so" \
- "" \
- {size-1.c} \
- "size-1" \
- "size-1.out" \
- ] \
- [list \
- "Run size-2" \
- "-Wl,--no-as-needed tmpdir/libsize-2.so" \
- "" \
- {size-2.c} \
- "size-2" \
- "size-2.out" \
- ] \
- [list \
- "Run size-3a" \
- "" \
- "" \
- {size-3.c size-3a.c} \
- "size-3a" \
- "size-3.out" \
- ] \
- [list \
- "Run size-3b" \
- "-Wl,--no-as-needed tmpdir/libsize-3a.so" \
- "" \
- {size-3.c} \
- "size-3b" \
- "size-3.out" \
- ] \
- [list \
- "Run size-3c" \
- "" \
- "" \
- {size-3.c size-3b.c} \
- "size-3c" \
- "size-3.out" \
- ] \
- [list \
- "Run size-3d (1)" \
- "-Wl,--no-as-needed tmpdir/libsize-3b.so" \
- "" \
- {size-3.c} \
- "size-3d1" \
- "size-3.out" \
- ] \
- [list \
- "Run size-3d (2)" \
- "" \
- "" \
- {size-3.c size-3c.c} \
- "size-3d2" \
- "size-3.out" \
- ] \
- [list \
- {"Run size-3e" \
- "-Wl,--no-as-needed tmpdir/libsize-3c.so" "" \
- {size-3.c} "size-3e" "size-3.out"} \
- ] \
- [list \
- "Run size-4a" \
- "$NOPIE_LDFLAGS" \
- "" \
- {size-4a.c size-4b.c} \
- "size-4a" \
- "size-4.out" \
- "$NOPIE_CFLAGS" \
- ] \
- [list \
- "Run size-4b" \
- "$NOPIE_LDFLAGS" \
- "" \
- {size-4b.c size-4a.c} \
- "size-4b" \
- "size-4.out" \
- "$NOPIE_CFLAGS" \
- ] \
- [list \
- "Run size-5a" \
- "$NOPIE_LDFLAGS" \
- "" \
- {size-5a.c size-5b.c} \
- "size-5a" \
- "size-5.out" \
- "$NOPIE_CFLAGS" \
- ] \
- [list \
- "Run size-5b" \
- "$NOPIE_LDFLAGS" \
- "" \
- {size-5b.c size-5a.c} \
- "size-5b" \
- "size-5.out" \
- "$NOPIE_CFLAGS" \
- ] \
- [list \
- "Run size-6" \
- "$NOPIE_LDFLAGS -Wl,--no-as-needed tmpdir/libsize-6b.so" \
- "" \
- {size-6a.c} \
- "size-6" \
- "size-6.out" \
- "$NOPIE_CFLAGS" \
- ] \
- [list \
- "Run size-8" \
- "$NOPIE_LDFLAGS -Wl,--no-as-needed,--hash-style=gnu,-z,notext \
- tmpdir/libsize-8.so" \
- "" \
- {size-8a.c} \
- "size-8" \
- "size-8.out" \
- "$NOPIE_CFLAGS" \
- ] \
- [list \
- "Run size-9" \
- "-Wl,--no-as-needed tmpdir/libsize-9.so $NOSANITIZE_CFLAGS" \
- "" \
- {size-9a.c} \
- "size-9" \
- "size-9.out" \
- "$NOSANITIZE_CFLAGS" \
- ] \
- [list \
- "Run size-10" \
- "-Wl,--no-as-needed tmpdir/libsize-10.so" \
- "" \
- {size-10a.c} \
- "size-10" \
- "size-10.out" \
- ] \
-]
Index: sources/GNU/binutils/create-2.43.1-cleansweep-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/lto.exp
===================================================================
--- sources/GNU/binutils/create-2.43.1-cleansweep-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/lto.exp (revision 75)
+++ sources/GNU/binutils/create-2.43.1-cleansweep-patch/binutils-2.43.1-new/ld/testsuite/ld-plugin/lto.exp (nonexistent)
@@ -1,1204 +0,0 @@
-# Expect script for ld-plugin LTO tests
-# Copyright (C) 2011-2024 Free Software Foundation, Inc.
-#
-# This file is part of the GNU Binutils.
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 3 of the License, or
-# (at your option) any later version.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this program; if not, write to the Free Software
-# Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston,
-# MA 02110-1301, USA.
-
-# Check to see if the C and C++ compilers work
-if { ![check_compiler_available] || [which $CXX_FOR_TARGET] == 0 } {
- return
-}
-
-# These tests require plugin and LTO.
-if { ![check_plugin_api_available]
- || ![check_lto_available] } {
- return
-}
-
-set saved_CFLAGS "$CFLAGS_FOR_TARGET"
-set saved_CXXFLAGS "$CXXFLAGS_FOR_TARGET"
-regsub -all "(\\-Wp,)?-D_FORTIFY_SOURCE=\[0-9\]+" $CFLAGS_FOR_TARGET "" CFLAGS_FOR_TARGET
-regsub -all "(\\-Wp,)?-D_FORTIFY_SOURCE=\[0-9\]+" $CXXFLAGS_FOR_TARGET "" CXXFLAGS_FOR_TARGET
-
-proc restore_notify { } {
- global saved_CFLAGS
- global saved_CXXFLAGS
- global CFLAGS_FOR_TARGET
- global CXXFLAGS_FOR_TARGET
- set CFLAGS_FOR_TARGET "$saved_CFLAGS"
- set CXXFLAGS_FOR_TARGET "$saved_CXXFLAGS"
-}
-
-set lto_fat ""
-set lto_no_fat ""
-if { [check_lto_fat_available] } {
- set lto_fat "-ffat-lto-objects"
- set lto_no_fat "-fno-fat-lto-objects"
- set no_lto "-fno-lto"
-}
-
-# Simple LTO tests and generate input files for complex LTO tests.
-set lto_link_tests [list \
- [list "LTO 1" \
- "-O2 -flto -fuse-linker-plugin" "-flto -fuse-linker-plugin" \
- {lto-1a.c lto-1b.c} {} "lto-1.exe"] \
- [list "Compile 2" \
- "" "-O2 -flto -fuse-linker-plugin $NOSANITIZE_CFLAGS" \
- {lto-2.c} {} ""] \
- [list "LTO 2" \
- "-static -O2 -flto -fuse-linker-plugin tmpdir/lto-2.o -lm" \
- "$NOSANITIZE_CFLAGS" \
- {dummy.c} {} "lto-2.exe"] \
- [list "Compile 3a" \
- "" "-flto" \
- {lto-3a.c} {} ""] \
- [list "Compile 3c" \
- "" "-O2" \
- {lto-3c.c} {} ""] \
- [list "Build liblto-3.a" \
- "" "-flto $lto_fat" \
- {lto-3b.c} {} "liblto-3.a"] \
- [list "Compile 5a" \
- "" "-flto $lto_fat" \
- {lto-5a.c} {} ""] \
- [list "Compile 5b" \
- "" "-flto $lto_fat" \
- {lto-5b.c} {} ""] \
- [list "Compile PR ld/12365" \
- "" "-flto -O2 $lto_fat -finline" \
- {pr12365a.c pr12365b.c pr12365c.c} {} ""] \
- [list "Compile 9" \
- "" "-O2 -finline -flto" \
- {lto-9.cc} {} "" "c++"] \
- [list "Compile 11a" \
- "" "-O -flto" \
- {lto-11a.c} {} ""] \
- [list "Compile 11b" \
- "" "-O -flto" \
- {lto-11b.c} {} ""] \
- [list "Compile 11c" \
- "" "-O" \
- {lto-11c.c} {} ""] \
- [list "Build liblto-12.a" \
- "$plug_opt" "-O2 -flto" \
- {lto-12c.c} {} "liblto-12.a"] \
- [list "Compile 12" \
- "" "-O2 -flto" \
- {lto-12a.c lto-12b.c} {} ""] \
- [list "Compile 13" \
- "" "-O2 -flto" \
- {lto-13a.c lto-13b.c} {} ""] \
- [list "Build liblto-13.a" \
- "" "-O2" \
- {lto-13c.c} {} "liblto-13.a"] \
- [list "Compile 14a" \
- "" "-flto" \
- {lto-14a.c lto-14b.c} {} ""] \
- [list "Build liblto-14.a" \
- "$plug_opt" "-flto" \
- {lto-14c.c} {} "liblto-14.a"] \
- [list "Compile 15a" \
- "" "-flto" \
- {lto-15a.c} {} ""] \
- [list "Build liblto-15.a" \
- "$plug_opt" "-flto" \
- {lto-15b.c} {} "liblto-15.a"] \
- [list "PR ld/12696" \
- "-O2 -flto -fuse-linker-plugin -r -nostdlib" "-O2 -flto" \
- {pr12696-1.cc} {} "pr12696-1r.o" "c++"] \
- [list "Compile PR ld/12758" \
- "" "" \
- {pr12758a.s} {} ""] \
- [list "Build libpr12758.a" \
- "" "-flto -O2 $lto_fat $NOSANITIZE_CFLAGS" \
- {pr12758b.c} {} "libpr12758.a"] \
- [list "PR ld/12758" \
- "$NOPIE_LDFLAGS $NOSANITIZE_CFLAGS -O2 -Wl,-e,foo -nostdlib -flto -fuse-linker-plugin tmpdir/pr12758a.o -Wl,--start-group tmpdir/libpr12758.a -Wl,--end-group -Wl,--no-error-execstack" \
- "$NOSANITIZE_CFLAGS" \
- {dummy.c} {} "pr12758.exe"] \
- [list "Build libpr13183.a" \
- "-T" "-flto -O2 $lto_fat -finline" \
- {pr13183a.c} {} "libpr13183.a"] \
- [list "Compile PR ld/13183" \
- "" "-flto -O2 -finline" \
- {pr13183b.c} {} ""] \
- [list "Compile PR ld/13201" \
- "" "-flto -O2" \
- {pr13201.c} {} ""] \
- [list "PR ld/13287" \
- "-flto -fuse-linker-plugin -Wl,--as-needed" "-flto" \
- {pr13287.cc} {} "pr13287.exe" "c++"] \
- [list "PR ld/15323 (1)" \
- "" "-O2" \
- {pr15323a.c} {} "" "c"] \
- [list "PR ld/15323 (2)" \
- "-O2 -flto -r -nostdlib" "-O2 -flto" \
- {pr15323a.c} {} "pr15323a-r.o" "c"] \
- [list "Compile(1) PR ld/pr16846" \
- "" "-flto" \
- {pr16846a.c pr16846b.c} {} ""] \
- [list "Compile(2) PR ld/pr16846" \
- "" "" \
- {pr16846c.c} {} ""] \
- [list "PR ld/pr16846(1)" \
- "-flto -fuse-linker-plugin tmpdir/pr16846a.o tmpdir/pr16846b.o tmpdir/pr16846c.o" "" \
- {dummy.c} {} "pr16846a.exe"] \
- [list "PR ld/pr16846(2)" \
- "-flto -fuse-linker-plugin tmpdir/pr16846a.o tmpdir/pr16846c.o tmpdir/pr16846b.o" "" \
- {dummy.c} {} "pr16846b.exe"] \
- [list "PR ld/19317 (1)" \
- "$plug_opt" "-flto $lto_no_fat" \
- {pr19317.c} {} "libpr19317.a"] \
- [list "Build pr20276a.o" \
- "" "-fno-lto -fcommon" \
- {pr20276a.c}] \
- [list "Build pr20276b.o" \
- "$plug_opt" "-flto $lto_no_fat -fcommon" \
- {pr20276b.c}] \
- [list "Build pr20267a.o" \
- "" "-fcommon" \
- {pr20267a.c}] \
- [list "Build libpr20267a.a" \
- "$plug_opt" "-flto $lto_fat -fcommon" \
- {pr20267b.c} {} "libpr20267a.a"] \
- [list "Build libpr20267b.a" \
- "$plug_opt" "-flto $lto_no_fat -fcommon" \
- {pr20267b.c} {} "libpr20267b.a"] \
- [list "Build pr20321" \
- "-flto -Wl,-plugin,$plug_so" "-flto" \
- {pr20321.c} {{warning ".*: duplicated plugin"}} \
- "pr20321" "c"] \
- [list "Build pr22502a.o" \
- "" "" \
- {pr22502a.c}] \
- [list "Build pr22502b.o" \
- "$plug_opt" "-flto $lto_no_fat" \
- {pr22502b.c}] \
- [list "Build pr22751.a" \
- "$plug_opt" "-flto $lto_no_fat $INT128_CFLAGS" \
- {pr22751.c} {} "pr22751.a"] \
- [list "Build pr24406-2b.o" \
- "" "-O2 -fno-lto" \
- {pr24406-2b.c}] \
- [list "Build pr26163a.o" \
- "" "-O2 -fno-lto" \
- {pr26163a.c}] \
- [list "Build pr26262b.o" \
- "" "-O2" \
- {pr26262b.c} {} "" "c"] \
- [list "Build pr26262c.o" \
- "" "-O2" \
- {pr26262c.c} {} "" "c"] \
- [list "Build pr26267a.o" \
- "" "-O2 -flto $lto_no_fat" \
- {pr26267a.c} {} "" "c"] \
- [list "Build pr26267b.o" \
- "" "-O2" \
- {pr26267b.c} {} "" "c"] \
- [list "Build pr26267c.o" \
- "" "-O2" \
- {pr26267c.c} {} "" "c"] \
- [list "Build pr26267a" \
- "" "-O2" \
- {pr26267a.c} {} "" "c"] \
- [list "Build pr26267a" \
- "-flto tmpdir/pr26267a.o tmpdir/pr26267b.o tmpdir/pr26267c.o" \
- "-flto $lto_no_fat" \
- {dummy.c} \
- {{error_output "pr26267.err"}} \
- "pr26267a"] \
- [list "Build pr26267b" \
- "-flto tmpdir/pr26267b.o tmpdir/pr26267c.o tmpdir/pr26267a.o" \
- "-flto $lto_no_fat" \
- {dummy.c} \
- {{error_output "pr26267.err"}} \
- "pr26267b"] \
- [list "Build pr26389.o" \
- "$plug_opt" "-flto $lto_no_fat -fcommon" \
- {pr26389.c} \
- [list [list "nm" "$plug_opt" "pr26389.d"]]] \
-]
-
-if { [at_least_gcc_version 10 0] && [check_lto_shared_available] } {
- set lto_link_tests [concat $lto_link_tests [list \
- [list "pr25355.o" \
- "" \
- "-flto -fno-common $lto_no_fat" \
- {pr25355.c} \
- [list [list "nm" "$plug_opt" "pr25355.d"]]] \
- [list "pr28264.so" \
- "-shared -Wl,--version-script=pr28264.ver" \
- "-flto $lto_no_fat -fPIC" \
- {pr28264.c} \
- {{readelf {--dyn-syms --wide} pr28264-1.d} \
- {readelf {--dyn-syms --wide} pr28264-2.d} \
- {readelf {--dyn-syms --wide} pr28264-3.d} \
- {readelf {--dyn-syms --wide} pr28264-4.d}} \
- {pr28264.so}] \
- ]]
-}
-
-if { [at_least_gcc_version 4 7] } {
- set lto_link_tests [concat $lto_link_tests [list \
- [list "Compile PR ld/12942 (1)" \
- "" "-flto -O2" \
- {pr12942a.cc pr12942c.cc} {} "" "c++"] \
- [list "Compile PR ld/12942 (2)" \
- "" "-O0" \
- {pr12942b.cc} {} "" "c++"] \
- ]]
-}
-
-set lto_compile_elf_tests [list \
- [list "Compile 7" \
- "" "-flto -O2" \
- {lto-7a.c lto-7b.c lto-7c.c} {} ""] \
- [list "Compile 8a" \
- "" "-O2" \
- {lto-8a.c} {} ""] \
- [list "Compile 8b" \
- "" "-flto -O2" \
- {lto-8b.c} {} ""] \
- [list "PR ld/23309" \
- "-O2 -flto -fuse-linker-plugin -fvisibility=hidden -ffunction-sections -Wl,--gc-sections,-u,KeepMe" \
- "-O2 -flto -fuse-linker-plugin -fvisibility=hidden -ffunction-sections" \
- {pr23309.c} {{"nm" {} "pr23309.d"}} "pr23309.exe" "c"] \
-]
-
-# Generate input files for complex LTO tests for ELF.
-set lto_link_elf_tests [list \
- [list "LTO 6" \
- "-O2 -flto -fuse-linker-plugin" "" \
- {lto-6.c} {} "lto-6.exe" "c"] \
- [list "Build liblto-7.so" \
- "-shared" "-O2 -fpic" \
- {lto-7d.c} {} "liblto-7.so" "c"] \
- [list "Build liblto-17a.so" \
- "-shared -O2 -fpic -flto -fuse-linker-plugin" "-O2 -fpic -flto -finline" \
- {lto-17a.c} {{"nm" {} "lto-17a.d"}} "liblto-17a.so" "c"] \
- [list "Build liblto-17b.so 1" \
- "-shared -O2 -fpic -flto -fuse-linker-plugin tmpdir/lto-17a.o" "-O2 -fpic -flto -finline" \
- {lto-17b.c} {{"nm" {} "lto-17b-1.d"}} "liblto-17b.so"] \
- [list "Build liblto-17b.so 2" \
- "-shared -O2 -fpic -flto -fuse-linker-plugin tmpdir/lto-17a.o" "-O2 -fpic -flto" \
- {lto-17b.c} {{"nm" {} "lto-17b-2.d"}} "liblto-17b.so"] \
- [list "Compile PR ld/12760" \
- "" "-g -O0" \
- {pr12760a.c} {} ""] \
- [list "Build libpr12760.a" \
- "" "-flto -O2 $lto_fat" \
- {pr12760b.c} {} "libpr12760.a"] \
- [list "PR ld/12760" \
- "-O2 -Wl,-e,foo -nostdlib -flto -fuse-linker-plugin tmpdir/pr12760a.o -Wl,--start-group tmpdir/libpr12760.a -Wl,--end-group" "" \
- {dummy.c} {{warning {pr12760a.c:6:\(.*\): warning: Bad \.?bar}}} \
- "pr12760.exe" "c"] \
- [list "PR ld/12975" \
- "-shared -O2 -fPIC -flto -fuse-linker-plugin -nostdlib -Wl,-version-script,pr12975.t" "-O2 -flto" \
- {pr12975.c} {{"readelf" {-s --wide} "pr12975.d"}} "pr12975.so" "c"] \
- [list "PR ld/13229" \
- "-shared -O2 -fPIC -flto -fuse-linker-plugin -nostdlib" "-O2 -finline -fno-early-inlining -flto" \
- {pr13229.cc} {{"readelf" {-s --wide} "pr13229.d"}} "pr13229.so" "c++"] \
- [list "PR ld/13244" \
- "-shared -O2 -fPIC -flto -fuse-linker-plugin -nostdlib" "-O2 -fno-early-inlining -flto" \
- {pr13244.c} {{"readelf" {-s --wide} "pr13244.d"}} "pr13244.so" "c"] \
- [list "Build libpr15146a.a" \
- "$plug_opt" "-flto -O2" \
- {pr15146a.c} {} "lib15146a.a"] \
- [list "Build pr15146b.so" \
- "-shared" "-O2 -fpic" \
- {pr15146b.c} {} "pr15146b.so" "c"] \
- [list "Build pr15146c.so" \
- "-shared -Wl,--no-as-needed tmpdir/pr15146b.so" "-O2 -fpic $no_lto" \
- {pr15146c.c} {} "pr15146c.so" "c"] \
- [list "PR ld/15146 (1)" \
- "-O2 -flto -fuse-linker-plugin -Wl,-rpath-link,. -Wl,--no-copy-dt-needed-entries -Wl,--no-as-needed tmpdir/pr15146a.o tmpdir/pr15146c.so" "" \
- {dummy.c} {{"readelf" {-d} "pr15146.d"}} "pr15146a.exe"] \
- [list "Build libpr15146d.a" \
- "$plug_opt" "-flto -O2" \
- {pr15146d.c} {} "lib15146d.a"] \
- [list "Build libpr16746a.a" \
- "" "" \
- {pr16746a.c pr16746b.c} {} "lib15146a.a"] \
- [list "Build libpr16746b.a" \
- "$plug_opt" "-O2 -flto" \
- {pr16746c.c pr16746d.c} {} "lib15146b.a"] \
- [list "PR ld/16746 (1)" \
- "-O2 -flto -fuse-linker-plugin tmpdir/pr16746a.o tmpdir/pr16746c.o" "-O2 -flto" \
- {dummy.c} {} "pr16746a.exe"] \
- [list "PR ld/16746 (2)" \
- "-O2 -flto -fuse-linker-plugin tmpdir/pr16746c.o tmpdir/pr16746a.o" "-O2 -flto" \
- {dummy.c} {} "pr16746b.exe"] \
- [list "Build pr21382a.o" \
- "" "-O2 -flto" \
- {pr21382a.c} {} "" "c"] \
- [list "Build pr21382.so" \
- "-shared" "-O2 -fpic" \
- {pr21382b.c} {} "pr21382.so" "c"] \
- [list {Build pr22220lib.so} \
- {-shared -Wl,--version-script=pr22220lib.ver} {-fPIC} \
- {pr22220lib.cc} {} {pr22220lib.so} {c++}] \
- [list {Build pr22220main.o} \
- {} {-flto} \
- {pr22220main.cc} {} {} {c++}] \
- [list "Build libpr23818.so" \
- "-shared -flto -g -Wl,-version-script,pr23818.t" \
- "-g -flto $lto_fat" \
- {pr23818a.c pr23818b.c} \
- {{"readelf" {-s --wide} "pr23818.d"}} \
- "libpr23818.so"] \
- [list "Build libpr23958.so" \
- "-shared -flto -Wl,-version-script,pr23958.t" \
- "-g -flto $lto_fat" \
- {pr23958.c} \
- "" \
- "libpr23958.so"] \
- [list "Build pr24486a.o" \
- "$plug_opt" "-flto -O2" \
- {pr24486a.c} {} "" "c"] \
- [list "Build pr24486b.so" \
- "-shared" "-O2 -fpic" \
- {pr24486b.c} {} "pr24486b.so" "c"] \
- [list "Build pr24486c.so" \
- "-shared -Wl,--no-as-needed tmpdir/pr24486b.so" "-O2 -fpic" \
- {pr24486c.c} {} "pr24486c.so" "c"] \
- [list "PR ld/24486" \
- "-O2 -flto tmpdir/pr24486a.o tmpdir/pr24486c.so -Wl,--as-needed tmpdir/pr24486b.so" "" \
- {dummy.c} {} "pr24486.exe"] \
- [list "Build pr25593a-1.o" \
- "$plug_opt" "-flto -O2" \
- {pr25593a-1.c} {} "" "c"] \
- [list "Build pr25593a-2.o" \
- "" "-O2" \
- {pr25593a-2.c} {} "" "c"] \
- [list "Build pr25593b.o" \
- "" "-O2" \
- {pr25593b.c} {} "" "c"] \
- [list "Build pr25593c.so" \
- "-shared" "-O2 -fpic" \
- {pr25593c.c} {} "pr25593c.so" "c"] \
- [list "Build pr25593d.so" \
- "-shared" "-O2 -fpic" \
- {pr25593d.c} {} "pr25593d.so" "c"] \
- [list "Build pr25593e.so" \
- "-shared" "-O2 -fpic" \
- {pr25593e.c} {} "pr25593e.so" "c"] \
- [list "PR ld/r25593 (LTO)" \
- "-O2 -flto -Wl,--as-needed tmpdir/pr25593a-1.o tmpdir/pr25593b.o \
- tmpdir/pr25593c.so tmpdir/pr25593d.so tmpdir/pr25593e.so" "" \
- {dummy.c} {{readelf {-d --wide} pr25593.d}} "pr25593a.exe"] \
- [list "PR ld/r25593" \
- "-O2 -flto -Wl,--as-needed tmpdir/pr25593a-2.o tmpdir/pr25593b.o \
- tmpdir/pr25593c.so tmpdir/pr25593d.so tmpdir/pr25593e.so" "" \
- {dummy.c} {{readelf {-d --wide} pr25593.d}} "pr25593b.exe"] \
- [list "Build pr25618a.o" \
- "$plug_opt" "-O2 -flto -fpic" \
- {pr25618a.cc} {} "" "c++"] \
- [list "Build pr25618.a" \
- "$plug_opt" "-O2 -flto -fpic" \
- {pr25618b.cc} {} "pr25618.a" "c++"] \
- [list "Build pr25618.so" \
- "-shared -Wl,--exclude-libs,ALL tmpdir/pr25618a.o tmpdir/pr25618.a" \
- "-fpic" \
- {dummy.c} {{readelf {--dyn-syms --wide} pr25618.d}} "pr25618.so" "c++"] \
- [list {liblto-18b.so} \
- {-shared} {-O2 -fpic} \
- {lto-18b.c} {} {liblto-18b.so}] \
- [list {liblto-18b.a} \
- "$plug_opt" {-flto -O2} \
- {lto-18b.c} {} {liblto-18b.a}] \
- [list {liblto-18c.so} \
- {-shared} {-O2 -fpic} \
- {lto-18c.c} {} {liblto-18c.so}] \
- [list {liblto-18c.a} \
- "$plug_opt" {-flto -O2} \
- {lto-18c.c} {} {liblto-18c.a}] \
- [list {lto-18d.o} \
- {} {-flto -O2} \
- {lto-18d.c} {} {}] \
- [list {liblto-19.a} \
- "$plug_opt" {-flto -O2 -fPIC} \
- {lto-19a.c} {} {liblto-19.a}] \
- [list {compile lto-19b.c} \
- "$plug_opt" {-flto -O2 -fPIC} \
- {lto-19b.c} {} {} {c}] \
- [list {liblto-19.so} \
- {-shared tmpdir/lto-19b.o tmpdir/liblto-19.a} {-O2 -fPIC} \
- {dummy.c} {} {liblto-19.so}] \
- [list {pr26806.so} \
- {-shared} {-fpic -O2 -flto} \
- {pr26806.c} {{nm {-D} pr26806.d}} {pr26806.so}] \
- [list {pr27311a.so} \
- {-shared -Wl,--version-script=pr27311.ver} {-fPIC} \
- {pr27311a.c} {} {pr27311a.so}] \
- [list {pr27311b.so} \
- {-shared -Wl,--no-as-needed tmpdir/pr27311a.so} {-fPIC} \
- {pr27311b.c} {} {pr27311b.so}] \
- [list {pr27311c.o} \
- {} {-flto} \
- {pr27311c.c} {} {} {c}] \
- [list {pr27311d.o} \
- {} {-flto} \
- {pr27311d.c} {} {} {c}] \
- [list {pr27311-1} \
- {tmpdir/pr27311c.o -Wl,--no-as-needed,--rpath-link=. tmpdir/pr27311b.so} {} \
- {dummy.c} {{readelf {--dyn-syms --wide} pr27311.d}} {pr27311-1}] \
- [list {pr27311-2} \
- {tmpdir/pr27311d.o -Wl,--no-as-needed,--rpath-link=. tmpdir/pr27311b.so} {} \
- {dummy.c} {{readelf {--dyn-syms --wide} pr27311.d}} {pr27311-2}] \
- [list {pr27441a.so} \
- {-shared} {-fPIC} \
- {pr27441a.c} {} {pr27441a.so}] \
- [list {pr27441b.so} \
- {-shared} {-fPIC} \
- {pr27441b.c} {} {pr27441b.so}] \
- [list {pr27441c.o} \
- {} {-fPIC -flto} \
- {pr27441c.c} {} {}] \
- [list {pr27441c.so} \
- {-shared -fPIC -Wl,--as-needed tmpdir/pr27441c.o tmpdir/pr27441b.so tmpdir/pr27441a.so} {-fPIC} \
- {dummy.c} {{readelf {-dW} pr27441c.d}} {pr27441c.so}] \
- [list \
- "Build libpr28879a.so" \
- "-shared" \
- "-O0 -fpic" \
- {pr28879a.cc} \
- {} \
- "libpr28879a.so" \
- "c++" \
- ] \
- [list \
- "Build libpr28879b.so" \
- "-shared -Wl,--no-as-needed tmpdir/libpr28879a.so" \
- "-O2 -fpic" \
- {dummy.c} \
- {} \
- "libpr28879b.so" \
- ] \
- [list \
- "Build pr28879" \
- "-Wl,--no-as-needed tmpdir/libpr28879b.so -Wl,-rpath-link,." \
- "-O0 -flto -D_GLIBCXX_ASSERTIONS" \
- {pr28879b.cc} \
- {} \
- "pr28879" \
- "c++" \
- ] \
- [list \
- "Build libpr28849a.so" \
- "-shared" \
- "-fPIC" \
- {pr28849a.c} \
- "" \
- "libpr28849a.so" \
- ] \
- [list \
- "Build libpr28849b.so" \
- "-shared -Wl,--no-as-needed,tmpdir/libpr28849a.so" \
- "" \
- {dummy.c} \
- "" \
- "libpr28849b.so" \
- ] \
- [list \
- "Build pr28849" \
- "-Wl,--no-as-needed,--copy-dt-needed-entries,-rpath-link,. \
- tmpdir/libpr28849b.so" \
- "-O2 -flto" \
- {pr28849b.c} \
- {{"nm" {-D} "pr28849.d"}} \
- "pr28849" \
- ] \
- [list \
- "PR ld/pr29086" \
- "-Wl,--wrap=foo" \
- "-O0 -flto" \
- {pr29086.c} \
- {} \
- "pr29086" \
- ] \
- [list \
- "PR ld/31956 (a)" \
- "-Wl,--wrap=parse_line" \
- "-O2 -flto" \
- {pr31956a.c pr31956b.c} \
- {} \
- "pr31956a" \
- ] \
- [list \
- "PR ld/31956 (b)" \
- "-Wl,--wrap=parse_line" \
- "-O2 -flto" \
- {pr31956b.c pr31956a.c} \
- {} \
- "pr31956b" \
- ] \
- [list \
- "PR ld/31956 (malloc)" \
- "-Wl,--wrap=malloc" \
- "-O2 -flto" \
- {pr31956c.c} \
- {} \
- "pr31956c" \
- ] \
- [list \
- "PR ld/31956 (unused)" \
- "-Wl,--wrap=parse_line" \
- "-O2 -flto" \
- {pr31956d.c} \
- {{"nm" {} "pr31956d.d"}} \
- "pr31956d" \
- ] \
- [list \
- "Build pr30281.so" \
- "-shared -Wl,--version-script,pr30281.t \
- -O2 -fPIC -flto-partition=max -flto=2" \
- "-O2 -fPIC -flto-partition=max -flto=2" \
- {pr30281.c} \
- "" \
- "pr30281.so" \
- ] \
- [list \
- "Build pr31482b.a" \
- "" \
- "" \
- {pr31482b.c} \
- "" \
- "pr31482b.a" \
- ] \
- [list \
- "Build pr31482c.so" \
- "-shared" \
- "-fPIC" \
- {pr31482c.c} \
- "" \
- "pr31482c.so" \
- ] \
- [list \
- "Build pr31615b.so" \
- "-shared -Wl,--version-script=pr31615.ver" \
- "-fPIC" \
- {pr31615b.c} \
- "" \
- "pr31615b.so" \
- ] \
- [list \
- "Build pr31615c.so" \
- "-shared -Wl,--version-script=pr31615.ver" \
- "-fPIC" \
- {pr31615c.c} \
- "" \
- "pr31615c.so" \
- ] \
- [list \
- "Build pr31615d.so" \
- "-shared -Wl,--version-script=pr31615.ver" \
- "-fPIC" \
- {pr31615d.c} \
- "" \
- "pr31615d.so" \
- ] \
- [list \
- "Build pr31644b.a" \
- "" \
- "" \
- {pr31644b.c} \
- "" \
- "pr31644b.a" \
- ] \
- [list \
- "Build pr31644c.so" \
- "-shared" \
- "-fPIC" \
- {pr31644c.c} \
- "" \
- "pr31644c.so" \
- ] \
-]
-
-# PR 14918 checks that libgcc is not spuriously included in a shared link of
-# an empty program. The ARM crt1.o startup code however calls __libc_csu_init
-# in /usr/lib/libc_nonshared.a(elf-init.oS). This in turn needs
-# __aeabi_unwind_cpp_pr0@@GCC_3.5 which is provided by libgcc_s.so.1, so the
-# test fails. Hence this code to skip the test.
-if { ! [istarget "arm*-*-*"] } {
- lappend lto_link_elf_tests \
- [list "PR ld/14918" \
- "-flto" "-flto" \
- {pr14918.c} {{"readelf" {-d --wide} "pr14918.d"}} "pr14918.exe" "c"]
-}
-
-# PR 12982 checks that an executable stack is not created by default
-# when using the LTO plugin. The HPPA target however requires an
-# executable stack for syscall restarts and signal returns, so we
-# skip this test for that target.
-if { ! [istarget "hppa*-*-*"] } {
- lappend lto_link_elf_tests \
- [list "PR ld/12982" \
- "-O2 -flto -fuse-linker-plugin" "-O2 -flto" \
- {pr12982.c} {{"readelf" {-l --wide} "pr12982.d"}} "pr12982.exe"]
-}
-
-# Check final symbols in executables.
-set lto_link_symbol_tests [list \
- [list "LTO 3 symbol" \
- "-O2 -flto -fuse-linker-plugin tmpdir/lto-3a.o tmpdir/lto-3c.o tmpdir/liblto-3.a" "" \
- {dummy.c} {{"nm" {} "lto-3.d"}} "lto-3.exe" "c"] \
- [list "LTO 5 symbol" \
- "-O2 -flto -fuse-linker-plugin tmpdir/lto-5.o" "" \
- {dummy.c} {{"nm" {} "lto-5.d"}} "lto-5.exe" "c"] \
- [list "LTO 9 symbol" \
- "-O2 -flto -fuse-linker-plugin tmpdir/lto-9.o" "" \
- {dummy.c} {{"nm" {-C} "lto-9.d"}} "lto-9.exe" "c++"] \
- [list "LTO 16a symbol" \
- "-O2 $NOSANITIZE_CFLAGS -Wl,-e,foo -nostdlib -flto -fuse-linker-plugin" \
- "-flto $NOSANITIZE_CFLAGS" \
- {lto-16a.c} {{"nm" {} "lto-16a.d"}} "lto-16.exe" "c"] \
- [list "LTO 16b symbol" \
- "-O2 $NOSANITIZE_CFLAGS -Wl,-e,foo -u bar -nostdlib -flto -fuse-linker-plugin" \
- "-flto $NOSANITIZE_CFLAGS" \
- {lto-16a.c lto-16b.c} {{"nm" {} "lto-16b.d"}} "lto-16b.exe" "c"] \
- [list "PR ld/13183" \
- "-O2 -flto -fuse-linker-plugin tmpdir/pr13183b.o tmpdir/libpr13183.a" "" \
- {dummy.c} {{"nm" {} "pr13183.d"}} "pr13183.exe" "c"] \
-]
-
-# LTO run-time tests.
-set lto_run_tests [list \
- [list "LTO 3a" \
- "-O2 -flto -fuse-linker-plugin tmpdir/lto-3a.o tmpdir/lto-3c.o tmpdir/liblto-3.a" "" \
- {dummy.c} "lto-3b.exe" "lto-3.out" "" "c"] \
- [list "LTO 3b" \
- "-O2 -flto -fuse-linker-plugin tmpdir/lto-3a.o tmpdir/lto-3c.o tmpdir/lto-3.o" "" \
- {dummy.c} "lto-3c.exe" "lto-3.out" "" "c"] \
- [list "LTO 3c" \
- "-O2 -flto -fuse-linker-plugin tmpdir/lto-3a.o tmpdir/lto-3c.o -Wl,--whole-archive tmpdir/liblto-3.a -Wl,--no-whole-archive tmpdir/liblto-3.a" "" \
- {dummy.c} "lto-3d.exe" "lto-3.out" "" "c"] \
- [list "LTO 5" \
- "-O2 -flto -fuse-linker-plugin tmpdir/lto-5.o" "" \
- {dummy.c} "lto-5.exe" "lto-5.out" "" "c"] \
- [list "LTO 11" \
- "-O -flto -fuse-linker-plugin tmpdir/liblto-11.a" "" \
- {dummy.c} "lto-11.exe" "lto-11.out" "" "c"] \
- [list "LTO 12a" \
- "-O -flto -fuse-linker-plugin tmpdir/lto-12a.o tmpdir/liblto-12.a tmpdir/lto-12b.o" "" \
- {dummy.c} "lto-12a.exe" "lto-12.out" "" "c"] \
- [list "LTO 12b" \
- "-O -flto -fuse-linker-plugin tmpdir/lto-12a.o tmpdir/lto-12b.o tmpdir/liblto-12.a" "" \
- {dummy.c} "lto-12b.exe" "lto-12.out" "" "c"] \
- [list "LTO 13" \
- "-O -flto -fuse-linker-plugin tmpdir/lto-13a.o tmpdir/liblto-13.a tmpdir/lto-13b.o" "" \
- {dummy.c} "lto-13.exe" "lto-13.out" "" "c"] \
- [list "LTO 14" \
- "-O2 -flto -fuse-linker-plugin tmpdir/lto-14a.o -Wl,--whole-archive tmpdir/liblto-14.a -Wl,--no-whole-archive tmpdir/lto-14b.o" "" \
- {dummy.c} "lto-14.exe" "lto-14.out" "" "c"] \
- [list "LTO 15" \
- "-O2 -flto -fuse-linker-plugin -Wl,--start-group tmpdir/liblto-15.a tmpdir/lto-15a.o -Wl,--end-group" "" \
- {dummy.c} "lto-15.exe" "lto-15.out" "" "c"] \
- [list "PR ld/13066" \
- "-O2 -flto -fuse-linker-plugin" "" \
- {pr13066.cc} "pr13066.exe" "pr13066.out" "" "c++"] \
- [list "PR ld/13201" \
- "-O2 -flto -fuse-linker-plugin -Wl,--as-needed tmpdir/pr13201.o -lm" "" \
- {dummy.c} "pr13201.exe" "pr13201.out" "" "c"] \
- [list "PR ld/15323 (3)" \
- "-O2 -flto -fuse-linker-plugin tmpdir/pr15323a.o" "" \
- {pr15323b.c} "pr15323.exe" "pr15323.out" "-flto -O2" "c"] \
- [list "PR ld/15323 (4)" \
- "-O2 -flto tmpdir/pr15323a-r.o" "" \
- {dummy.c} "pr15323a.exe" "pr15323.out" "-flto -O2" "c"] \
- [list "PR ld/19317 (3)" \
- "-O2 -flto tmpdir/pr19317-r.o" "" \
- {dummy.c} "pr19317.exe" "pr19317.out" "-flto -O2" "c"] \
- [list "Run pr20276" \
- "-O2 -flto tmpdir/pr20276a.o tmpdir/pr20276b.o" "" \
- {dummy.c} "pr20276" "pass.out" "-flto -O2" "c"] \
- [list "Run pr20267a" \
- "-O2 -flto -fcommon tmpdir/pr20267a.o tmpdir/libpr20267a.a" "" \
- {dummy.c} "pr20267a" "pass.out" "-flto -O2 -fcommon" "c"] \
- [list "Run pr20267b" \
- "-O2 -flto -fcommon tmpdir/pr20267a.o tmpdir/libpr20267b.a" "" \
- {dummy.c} "pr20267b" "pass.out" "-flto -O2 -fcommon" "c"] \
- [list "Run pr22502" \
- "-O2 -flto tmpdir/pr22502a.o tmpdir/pr22502b.o" "" \
- {dummy.c} "pr20267" "pass.out" "-flto -O2 -fcommon" "c"] \
- [list "Run pr22751" \
- "-O2 -flto" "" \
- {dummy.c} "pr22751" "pass.out" "-flto -O2" "c" "" \
- "-Wl,--whole-archive tmpdir/pr22751.a -Wl,--no-whole-archive"] \
- [list "Run pr24406-1" \
- "-O2 -flto" "" \
- {pr24406-1.c} "pr24406-1" "pass.out" "-flto -O2" "c" "" \
- "-Wl,--wrap=read"] \
- [list "Run pr24406-2" \
- "-O2 -flto" "" \
- {pr24406-2a.c} "pr24406-2" "pass.out" \
- "-flto -O2" "c" "" \
- "tmpdir/pr24406-2b.o -Wl,--wrap=cook"] \
- [list "Run pr26163" \
- "-O2 -flto" "" \
- {pr26163b.c} "pr24406-2" "pass.out" \
- "-flto -O2" "c" "" \
- "tmpdir/pr26163a.o -Wl,--defsym,g=real_g"] \
- [list "Run pr26262a" \
- "-O2 -flto" "" \
- {pr26262a.c} "pr26262a" "pass.out" \
- "-flto -O2" "c" "" \
- "tmpdir/pr26262b.o tmpdir/pr26262c.o"] \
- [list "Run pr26262b" \
- "-flto -O2 tmpdir/pr26262b.o tmpdir/pr26262c.o" "" \
- {pr26262a.c} "pr26262b" "pass.out" \
- "-flto -O2" "c" "" \
- ""] \
-]
-
-if { [at_least_gcc_version 4 7] } {
- set lto_run_tests [concat $lto_run_tests [list \
- [list "PR ld/12942 (1)" \
- "-O2 -flto -fuse-linker-plugin tmpdir/pr12942a.o tmpdir/pr12942b.o" "" \
- {dummy.c} "pr12942a.exe" "pr12942.out" "" "c++"] \
- [list "PR ld/12942 (2)" \
- "-O2 -flto -fuse-linker-plugin tmpdir/pr12942a.o tmpdir/pr12942c.o" "" \
- {dummy.c} "pr12942c.exe" "pr12942.out" "" "c++"] \
- ]]
-}
-
-# LTO run-time tests for ELF which require shared library support.
-set lto_run_elf_shared_tests [list \
- [list "LTO 7" \
- "-O2 -flto -fuse-linker-plugin tmpdir/lto-7b.o tmpdir/lto-7c.o tmpdir/lto-7a.o -Wl,--no-as-needed tmpdir/liblto-7.so" "" \
- {dummy.c} "lto-7.exe" "lto-7.out" "" "c"] \
- [list "Run pr21382" \
- "-O2 -flto -fuse-linker-plugin -Wl,--as-needed tmpdir/pr21382a.o tmpdir/pr21382.so" "" \
- {dummy.c} "pr21382.exe" "pass.out" "" "c"] \
- [list {pr22220a} \
- {-flto -fuse-linker-plugin tmpdir/pr22220main.o tmpdir/pr22220lib.so} {} \
- {dummy.c} {pr22220a.exe} {pass.out} {} {c++}] \
- [list {pr22220b} \
- {-flto -fuse-linker-plugin -Wl,--no-as-needed tmpdir/pr22220lib.so tmpdir/pr22220main.o} {} \
- {dummy.c} {pr22220b.exe} {pass.out} {} {c++}] \
- [list {lto-18 (1)} \
- {-flto -fuse-linker-plugin} {} \
- {lto-18a.c} {lto-18-1.exe} {lto-18.out} {-flto -O2} {c} {} \
- {tmpdir/lto-18d.o -Wl,--as-needed,-R,tmpdir -Ltmpdir -llto-18b -llto-18c}] \
- [list {lto-18 (2)} \
- {-flto -fuse-linker-plugin} {} \
- {lto-18a.c} {lto-18-2.exe} {lto-18.out} {-flto -O2} {c} {} \
- {-Wl,--as-needed,-R,tmpdir -Ltmpdir -llto-18b -llto-18c tmpdir/lto-18d.o}] \
- [list {lto-18 (3)} \
- {-static -flto -fuse-linker-plugin} {} \
- {lto-18a.c} {lto-18-3.exe} {lto-18.out} {-flto -O2} {c} {} \
- {tmpdir/lto-18d.o -Ltmpdir -llto-18b -llto-18c}] \
- [list {lto-18 (4)} \
- {-static -flto -fuse-linker-plugin} {} \
- {lto-18a.c} {lto-18-4.exe} {lto-18.out} {-flto -O2} {c} {} \
- { -Ltmpdir -llto-18b -llto-18c tmpdir/lto-18d.o}] \
- [list {lto-19} \
- {-Wl,--as-needed,-R,tmpdir} {} \
- {lto-19c.c} {lto-19.exe} {pass.out} {-flto -O2} {c} {} \
- {tmpdir/liblto-19.so tmpdir/liblto-19.a}] \
- [list {pr31482a} \
- {-Wl,--no-as-needed,-R,tmpdir} {} \
- {pr31482a.c} {pr31482a.exe} {pass.out} {-flto} {c} {} \
- {tmpdir/pr31482b.a tmpdir/pr31482c.so}] \
- [list {pr31482b} \
- {-Wl,--no-as-needed,-R,tmpdir} {} \
- {pr31482a.c} {pr31482b.exe} {pass1.out} {-flto} {c} {} \
- {tmpdir/pr31482c.so tmpdir/pr31482b.a}] \
- [list {pr31489a} \
- {-Wl,--as-needed,-R,tmpdir} {} \
- {pr31482a.c} {pr31489a.exe} {pass.out} {-flto} {c} {} \
- {tmpdir/pr31482b.a tmpdir/pr31482c.so}] \
- [list {pr31489b} \
- {-Wl,--as-needed,-R,tmpdir} {} \
- {pr31482a.c} {pr31489b.exe} {pass1.out} {-flto} {c} {} \
- {tmpdir/pr31482c.so tmpdir/pr31482b.a}] \
- [list {pr31615a} \
- {-Wl,-R,tmpdir} {} \
- {pr31615a.c} {pr31615a.exe} {pass.out} {-O3 -flto} {c} {} \
- {-Wl,--as-needed tmpdir/pr31615b.so -Wl,--no-as-needed \
- tmpdir/pr31615d.so}] \
- [list {pr31615b} \
- {-Wl,-R,tmpdir} {} \
- {pr31615a.c} {pr31615b.exe} {pass.out} {-O3 -flto} {c} {} \
- {-Wl,--as-needed tmpdir/pr31615c.so -Wl,--no-as-needed \
- tmpdir/pr31615d.so}] \
- [list {pr31644a} \
- {-Wl,-R,tmpdir} {} \
- {pr31644a.c} {pr31644a.exe} {pass.out} {-flto} {c} {} \
- {-Wl,--no-as-needed tmpdir/pr31644b.a tmpdir/pr31644c.so}] \
- [list {pr31644b} \
- {-Wl,-R,tmpdir} {} \
- {pr31644a.c} {pr31644b.exe} {pass.out} {-flto} {c} {} \
- {-Wl,--as-needed tmpdir/pr31644b.a tmpdir/pr31644c.so}] \
-]
-
-# LTO run-time tests for ELF
-set lto_run_elf_tests [list \
- [list "LTO 8" \
- "-O2 -flto -fuse-linker-plugin tmpdir/lto-8b.o tmpdir/lto-8a.o" "" \
- {dummy.c} "lto-8.exe" "lto-8.out" "" "c"] \
- [list "LTO TLS IE" \
- "-O2 -flto -fuse-linker-plugin" "" \
- {run-ie.c} "run-ie.exe" "run-ie.out" "" "c"] \
-]
-
-run_cc_link_tests $lto_link_tests
-
-# These compilation tests generate intermediate object files which will be used
-# by some elf tests besides shared libs tests. So, always compile them.
-run_cc_link_tests $lto_compile_elf_tests
-
-# Restrict these to ELF targets that support shared libs and PIC.
-if { [is_elf_format] && [check_lto_shared_available] } {
- run_cc_link_tests $lto_link_elf_tests
- set testname "PR ld/15146 (2)"
- set exec_output [run_host_cmd "$CC_FOR_TARGET" "-O2 -flto -fuse-linker-plugin -Wl,-rpath-link,. -Wl,--no-copy-dt-needed-entries -Wl,--no-as-needed tmpdir/pr15146d.o tmpdir/pr15146c.so"]
- if { [ regexp "undefined reference to symbol '\\.?xxx'" $exec_output ] } {
- pass $testname
- } {
- fail $testname
- }
- set testname "PR ld/16746 (3)"
- set exec_output [run_host_cmd "$CC_FOR_TARGET" "-O2 -flto -fuse-linker-plugin tmpdir/pr16746b.o tmpdir/pr16746d.o"]
- if { [ regexp "warning: \\.?foobar" $exec_output ] && ![ regexp "symbol from plugin" $exec_output ] } {
- pass $testname
- } {
- fail $testname
- }
- set testname "PR ld/16746 (4)"
- set exec_output [run_host_cmd "$CC_FOR_TARGET" "-O2 -flto -fuse-linker-plugin tmpdir/pr16746d.o tmpdir/pr16746b.o"]
- if { [ regexp "warning: \\.?foobar" $exec_output ] && ![ regexp "symbol from plugin" $exec_output ] } {
- pass $testname
- } {
- fail $testname
- }
-}
-
-run_cc_link_tests [list \
- [list \
- "Build pr28138.a" \
- "-T" "" \
- {pr28138-1.c pr28138-2.c pr28138-3.c pr28138-4.c pr28138-5.c \
- pr28138-6.c pr28138-7.c} {} "pr28138.a" \
- ] \
- [list \
- "Build pr28138.o" \
- "" "" \
- {pr28138.c} {} \
- ] \
-]
-
-set exec_output [run_host_cmd "sh" \
- "-c \"ulimit -n 20; \
- $CC_FOR_TARGET $gcc_B_opt $CFLAGS_FOR_TARGET \
- $ld_L_opt -o tmpdir/pr28138 \
- tmpdir/pr28138.o tmpdir/pr28138.a\""]
-set exec_output [prune_warnings $exec_output]
-if [string match "" $exec_output] then {
- if { [isnative] } {
- set exec_output [run_host_cmd "tmpdir/pr28138" ""]
- if [string match "PASS" $exec_output] then {
- pass "PR ld/28138 (build & run)"
- } else {
- fail "PR ld/28138 (built ok, run failed)"
- }
- } else {
- pass "PR ld/28138 (build only)"
- }
-} else {
- fail "PR ld/28138 (build only)"
-}
-
-set testname "Build liblto-11.a"
-remote_file host delete "tmpdir/liblto-11.a"
-set catch_output [run_host_cmd "$ar" "rc $plug_opt tmpdir/liblto-11.a tmpdir/lto-11a.o tmpdir/lto-11b.o tmpdir/lto-11c.o"]
-if {![string match "" $catch_output]} {
- fail $testname
- restore_notify
- return
-}
-
-if { [at_least_gcc_version 4 7] } {
- # Check expected LTO linker errors.
- # Since the asm symbol name hack in pr12365b.c doesn't work on all
- # targets, run PR ld/12365 tests only for known targets.
- if { ([istarget "i?86-*-elf*"]
- || [istarget "i?86-*-linux*"]
- || [istarget "i?86-*-gnu*"]
- || [istarget "x86_64-*-linux*"]
- || [istarget "amd64-*-linux*"]) } {
- set testname "PR ld/12365"
- set exec_output [run_host_cmd "$CC_FOR_TARGET" "-O2 -flto -flto-partition=none -fuse-linker-plugin -o tmpdir/pr12365 tmpdir/pr12365a.o tmpdir/pr12365b.o tmpdir/pr12365c.o"]
- set exec_output [prune_warnings $exec_output]
- if { [ regexp "undefined reference to `my_bcopy'" $exec_output ] } {
- # Linker should catch the reference to undefined `my_bcopy'
- # error caused by a GCC bug.
- pass $testname
- } elseif { [ string match "" $exec_output ] } {
- global READELF
- set exec_output [run_host_cmd "$READELF" "-s -W tmpdir/pr12365"]
- if { [ regexp "my_bcopy" $exec_output ] } {
- # Verify that there is no `my_bcopy' symbol in executable.
- fail $testname
- } {
- pass $testname
- }
- } {
- fail $testname
- }
-
- run_cc_link_tests [list \
- [list \
- "Build pr22721a.so" \
- "-shared $NOSANITIZE_CFLAGS -nostdlib -nostartfiles \
- -Wl,-version-script,pr22721.t" \
- "" \
- {pr22721a.s} \
- {} \
- "pr22721a.so" \
- ] \
- [list \
- "Build pr22721b.o" \
- "$plug_opt $NOSANITIZE_CFLAGS" \
- "-O2 -fPIC -flto $lto_no_fat" \
- {pr22721b.c} \
- ] \
- [list \
- "Build PR ld/pr22721" \
- "-O2 -flto -fuse-linker-plugin -nostdlib -nostartfiles \
- $NOSANITIZE_CFLAGS \
- -Wl,-e,_start tmpdir/pr22721b.o tmpdir/pr22721a.so" \
- "$NOSANITIZE_CFLAGS" \
- {dummy.c} \
- {} \
- "pr22721.exe"
- ] \
- ]
- }
- set testname "PR ld/12942 (3)"
- set exec_output [run_host_cmd "$CXX_FOR_TARGET" "-O2 -flto -fuse-linker-plugin tmpdir/pr12942b.o tmpdir/pr12942a.o"]
- if { [ regexp "undefined reference to `\\.?link_error\\(\\)'" $exec_output ] } {
- pass $testname
- } {
- fail $testname
- }
-
- run_cc_link_tests [list \
- [list \
- "Build pr23460*.o" \
- "$plug_opt" \
- "-O2 -fPIC -flto $lto_no_fat" \
- {pr23460a.c pr23460b.c pr23460c.c \
- pr23460d.c pr23460e.c pr23460f.c} \
- ] \
- ]
- set exec_output [run_host_cmd "sh" \
- "-c \"ulimit -n 20; \
- $ar -rc $plug_opt \
- tmpdir/libpr23460.a \
- tmpdir/pr23460a.o \
- tmpdir/pr23460b.o \
- tmpdir/pr23460c.o \
- tmpdir/pr23460d.o \
- tmpdir/pr23460e.o \
- tmpdir/pr23460f.o\""]
- set exec_output [prune_warnings $exec_output]
- if [string match "" $exec_output] then {
- pass "PR binutils/23460"
- } else {
- fail "PR binutils/23460"
- }
- set exec_output [run_host_cmd "$RANLIB" "$plug_opt tmpdir/libpr23460.a"]
- set exec_output [prune_warnings $exec_output]
- if [string match "" $exec_output] then {
- pass "PR binutils/23460"
- } else {
- fail "PR binutils/23460"
- }
-}
-
-# Fedora specific binutils patches break some of the tests that follow...
-restore_notify
-return
-
-# Run "ld -r" to generate inputs for complex LTO tests.
-run_dump_test "lto-3r"
-remote_exec host "mv" "tmpdir/dump tmpdir/lto-3.o"
-run_dump_test "lto-5r"
-remote_exec host "mv" "tmpdir/dump tmpdir/lto-5.o"
-
-run_cc_link_tests $lto_link_symbol_tests
-
-run_ld_link_tests [list \
- [list "PR ld/19317 (2)" \
- "-r tmpdir/pr19317.o --no-error-execstack" "" "" \
- {dummy.s} {} "pr19317-r.o"] \
-]
-
-run_ld_link_exec_tests $lto_run_tests
-
-if { [is_elf_format] } {
- run_ld_link_exec_tests $lto_run_elf_tests
-
- # Note - it is not guaranteed that the ordering of symbols in the dynamic
- # symbol table will match the ordering of the symbols specified by the
- # --dynamic-list command line option.
- #
- # For PR22983 we want to make sure that all four symbols specified in
- # pr222983.t are present in the output, but a simple sequences of regexps
- # will not work as we do not know the order of the symbols. (Readelf
- # does not have a symbol sorting option and the run_cc_list_tests proc
- # does not allow for the output of the dump program to piped into `sort`).
- #
- # So instead we run readelf four times, each time checking for the
- # presence of a specific symbol from the pr22983.t file.
- run_cc_link_tests [list \
- [list \
- "Build pr22983" \
- "-Wl,--dynamic-list,pr22983.t" \
- "-flto" \
- {pr22983a.c pr22983b.c} \
- {{readelf {--dyn-syms --wide} pr22983.1.d} \
- {readelf {--dyn-syms --wide} pr22983.2.d} \
- {readelf {--dyn-syms --wide} pr22983.3.d} \
- {readelf {--dyn-syms --wide} pr22983.4.d}} \
- "pr22983" \
- ] \
- ]
-}
-
-if { [is_elf_format] && [check_lto_shared_available] } {
- run_ld_link_exec_tests $lto_run_elf_shared_tests
-}
-
-proc pr20103 {cflags libs} {
- global CC_FOR_TARGET
-
- set testname "PR ld/20103 ($cflags $libs)"
- set exec_output [run_host_cmd "$CC_FOR_TARGET" "$cflags $libs"]
- # NB: Starting from GCC 4.9, -flto is optional for final link.
- if { [ regexp "fatpr20103" "$libs" ] \
- && ([regexp " -flto" "$cflags"] \
- || [at_least_gcc_version 4 9]) } {
- set result1good "fail"
- set result1bad "pass"
- } {
- set result1good "pass"
- set result1bad "fail"
- }
- if { [ regexp "undefined reference to `\\.?dead'" $exec_output ] } {
- $result1good "$testname (1)"
- } {
- $result1bad "$testname (1)"
- }
- if { [ regexp "plugin needed to handle lto object" $exec_output ] } {
- fail "$testname (2)"
- } {
- pass "$testname (2)"
- }
-}
-
-if { [check_lto_fat_available] } {
- run_cc_link_tests [list \
- [list \
- "Build fatpr20103a.a" \
- "$plug_opt" "-flto -ffat-lto-objects" \
- {pr20103a.c} {} "fatpr20103a.a"
- ] \
- [list \
- "Build fatpr20103b.a" \
- "$plug_opt" "-flto -ffat-lto-objects" \
- {pr20103b.c} {} "fatpr20103b.a"
- ] \
- [list \
- "Build fatpr20103c.a" \
- "$plug_opt" "-flto -ffat-lto-objects" \
- {pr20103c.c} {} "fatpr20103c.a" \
- ] \
- [list \
- "Build thinpr20103a.a" \
- "$plug_opt" "-flto -fno-fat-lto-objects" \
- {pr20103a.c} {} "thinpr20103a.a"
- ] \
- [list \
- "Build thinpr20103b.a" \
- "$plug_opt" "-flto -fno-fat-lto-objects" \
- {pr20103b.c} {} "thinpr20103b.a"
- ] \
- [list \
- "Build thinpr20103c.a" \
- "$plug_opt" "-flto -fno-fat-lto-objects" \
- {pr20103c.c} {} "thinpr20103c.a" \
- ] \
- [list \
- "Build pr20103a" \
- "-O2 -flto -Wl,--start-group tmpdir/thinpr20103a.a tmpdir/thinpr20103b.a tmpdir/thinpr20103c.a -Wl,--end-group" \
- "-O2 -flto" \
- {dummy.c} {} "pr20103a" \
- ] \
- [list \
- "Build pr20103b" \
- "-O2 -flto -Wl,--start-group tmpdir/fatpr20103a.a tmpdir/fatpr20103b.a tmpdir/fatpr20103c.a -Wl,--end-group" \
- "-O2 -flto" \
- {dummy.c} {} "pr20103b" \
- ] \
- [list \
- "Build pr20103c" \
- "-O2 -Wl,--start-group tmpdir/fatpr20103a.a tmpdir/fatpr20103b.a tmpdir/fatpr20103c.a -Wl,--end-group" \
- "-O2" \
- {dummy.c} {} "pr20103c" \
- ] \
- [list "Build fatpr23935.a" \
- "$plug_opt" \
- "-flto -fno-builtin -ffat-lto-objects" \
- {pr23935a.c} \
- "" \
- "fatpr23935.a" \
- ] \
- [list "Build pr23935b.o" \
- "$plug_opt" \
- "-flto -fno-fat-lto-objects" \
- {pr23935b.c} \
- ] \
- [list \
- "Build pr23935" \
- "-static -flto -Wl,-emain -nostdlib tmpdir/pr23935b.o \
- tmpdir/fatpr23935.a" \
- "-flto -fno-fat-lto-objects" \
- {dummy.c} \
- "" \
- "pr23935" \
- ] \
- ]
- pr20103 "-O2 -flto" "tmpdir/thinpr20103a.a tmpdir/thinpr20103b.a tmpdir/thinpr20103c.a"
- pr20103 "-O2 -flto" "tmpdir/fatpr20103a.a tmpdir/fatpr20103b.a tmpdir/fatpr20103c.a"
- pr20103 "-O2" "tmpdir/fatpr20103a.a tmpdir/fatpr20103b.a tmpdir/fatpr20103c.a"
-
- if { [at_least_gcc_version 4 9] } {
- run_cc_link_tests [list \
- [list \
- "Build pr20103d" \
- "-O2 -Wl,--start-group tmpdir/thinpr20103a.a tmpdir/thinpr20103b.a tmpdir/thinpr20103c.a -Wl,--end-group" \
- "-O2" \
- {dummy.c} {} "pr20103d" \
- ] \
- ]
- pr20103 "-O2" "tmpdir/thinpr20103a.a tmpdir/thinpr20103b.a tmpdir/thinpr20103c.a"
- }
-}
-
-restore_notify
Index: sources/GNU/binutils/create-2.43.1-libtool-lib64-patch/file.list
===================================================================
--- sources/GNU/binutils/create-2.43.1-libtool-lib64-patch/file.list (revision 75)
+++ sources/GNU/binutils/create-2.43.1-libtool-lib64-patch/file.list (nonexistent)
@@ -1,6 +0,0 @@
-binutils-2.43.1/bfd/configure
-binutils-2.43.1/binutils/configure
-binutils-2.43.1/gas/configure
-binutils-2.43.1/gprof/configure
-binutils-2.43.1/ld/configure
-binutils-2.43.1/opcodes/configure
Index: sources/GNU/binutils/create-2.43.1-libtool-lib64-patch/create.patch.sh
===================================================================
--- sources/GNU/binutils/create-2.43.1-libtool-lib64-patch/create.patch.sh (revision 75)
+++ sources/GNU/binutils/create-2.43.1-libtool-lib64-patch/create.patch.sh (nonexistent)
@@ -1,15 +0,0 @@
-#!/bin/bash
-
-VERSION=2.43.1
-
-tar --files-from=file.list -xJvf ../binutils-$VERSION.tar.xz
-mv binutils-$VERSION binutils-$VERSION-orig
-
-cp -rf ./binutils-$VERSION-new ./binutils-$VERSION
-
-diff --unified -Nr binutils-$VERSION-orig binutils-$VERSION > binutils-$VERSION-libtool-lib64.patch
-
-mv binutils-$VERSION-libtool-lib64.patch ../patches
-
-rm -rf ./binutils-$VERSION
-rm -rf ./binutils-$VERSION-orig
Property changes on: sources/GNU/binutils/create-2.43.1-libtool-lib64-patch/create.patch.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: sources/GNU/binutils/create-2.43.1-libtool-lib64-patch/binutils-2.43.1-new/ld/configure
===================================================================
--- sources/GNU/binutils/create-2.43.1-libtool-lib64-patch/binutils-2.43.1-new/ld/configure (revision 75)
+++ sources/GNU/binutils/create-2.43.1-libtool-lib64-patch/binutils-2.43.1-new/ld/configure (nonexistent)
@@ -1,22481 +0,0 @@
-#! /bin/sh
-# Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.69 for ld 2.43.1.
-#
-#
-# Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc.
-#
-#
-# This configure script is free software; the Free Software Foundation
-# gives unlimited permission to copy, distribute and modify it.
-## -------------------- ##
-## M4sh Initialization. ##
-## -------------------- ##
-
-# Be more Bourne compatible
-DUALCASE=1; export DUALCASE # for MKS sh
-if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
- emulate sh
- NULLCMD=:
- # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
- # is contrary to our usage. Disable this feature.
- alias -g '${1+"$@"}'='"$@"'
- setopt NO_GLOB_SUBST
-else
- case `(set -o) 2>/dev/null` in #(
- *posix*) :
- set -o posix ;; #(
- *) :
- ;;
-esac
-fi
-
-
-as_nl='
-'
-export as_nl
-# Printing a long string crashes Solaris 7 /usr/bin/printf.
-as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
-as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
-as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
-# Prefer a ksh shell builtin over an external printf program on Solaris,
-# but without wasting forks for bash or zsh.
-if test -z "$BASH_VERSION$ZSH_VERSION" \
- && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
- as_echo='print -r --'
- as_echo_n='print -rn --'
-elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
- as_echo='printf %s\n'
- as_echo_n='printf %s'
-else
- if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
- as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
- as_echo_n='/usr/ucb/echo -n'
- else
- as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
- as_echo_n_body='eval
- arg=$1;
- case $arg in #(
- *"$as_nl"*)
- expr "X$arg" : "X\\(.*\\)$as_nl";
- arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
- esac;
- expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
- '
- export as_echo_n_body
- as_echo_n='sh -c $as_echo_n_body as_echo'
- fi
- export as_echo_body
- as_echo='sh -c $as_echo_body as_echo'
-fi
-
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- PATH_SEPARATOR=:
- (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
- (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
- PATH_SEPARATOR=';'
- }
-fi
-
-
-# IFS
-# We need space, tab and new line, in precisely that order. Quoting is
-# there to prevent editors from complaining about space-tab.
-# (If _AS_PATH_WALK were called with IFS unset, it would disable word
-# splitting by setting IFS to empty value.)
-IFS=" "" $as_nl"
-
-# Find who we are. Look in the path if we contain no directory separator.
-as_myself=
-case $0 in #((
- *[\\/]* ) as_myself=$0 ;;
- *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
- done
-IFS=$as_save_IFS
-
- ;;
-esac
-# We did not find ourselves, most probably we were run as `sh COMMAND'
-# in which case we are not to be found in the path.
-if test "x$as_myself" = x; then
- as_myself=$0
-fi
-if test ! -f "$as_myself"; then
- $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
- exit 1
-fi
-
-# Unset variables that we do not need and which cause bugs (e.g. in
-# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
-# suppresses any "Segmentation fault" message there. '((' could
-# trigger a bug in pdksh 5.2.14.
-for as_var in BASH_ENV ENV MAIL MAILPATH
-do eval test x\${$as_var+set} = xset \
- && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
-done
-PS1='$ '
-PS2='> '
-PS4='+ '
-
-# NLS nuisances.
-LC_ALL=C
-export LC_ALL
-LANGUAGE=C
-export LANGUAGE
-
-# CDPATH.
-(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
-
-# Use a proper internal environment variable to ensure we don't fall
- # into an infinite loop, continuously re-executing ourselves.
- if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then
- _as_can_reexec=no; export _as_can_reexec;
- # We cannot yet assume a decent shell, so we have to provide a
-# neutralization value for shells without unset; and this also
-# works around shells that cannot unset nonexistent variables.
-# Preserve -v and -x to the replacement shell.
-BASH_ENV=/dev/null
-ENV=/dev/null
-(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
-case $- in # ((((
- *v*x* | *x*v* ) as_opts=-vx ;;
- *v* ) as_opts=-v ;;
- *x* ) as_opts=-x ;;
- * ) as_opts= ;;
-esac
-exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
-# Admittedly, this is quite paranoid, since all the known shells bail
-# out after a failed `exec'.
-$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
-as_fn_exit 255
- fi
- # We don't want this to propagate to other subprocesses.
- { _as_can_reexec=; unset _as_can_reexec;}
-if test "x$CONFIG_SHELL" = x; then
- as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
- emulate sh
- NULLCMD=:
- # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
- # is contrary to our usage. Disable this feature.
- alias -g '\${1+\"\$@\"}'='\"\$@\"'
- setopt NO_GLOB_SUBST
-else
- case \`(set -o) 2>/dev/null\` in #(
- *posix*) :
- set -o posix ;; #(
- *) :
- ;;
-esac
-fi
-"
- as_required="as_fn_return () { (exit \$1); }
-as_fn_success () { as_fn_return 0; }
-as_fn_failure () { as_fn_return 1; }
-as_fn_ret_success () { return 0; }
-as_fn_ret_failure () { return 1; }
-
-exitcode=0
-as_fn_success || { exitcode=1; echo as_fn_success failed.; }
-as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
-as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
-as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
-if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
-
-else
- exitcode=1; echo positional parameters were not saved.
-fi
-test x\$exitcode = x0 || exit 1
-test -x / || exit 1"
- as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
- as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
- eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
- test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
-test \$(( 1 + 1 )) = 2 || exit 1
-
- test -n \"\${ZSH_VERSION+set}\${BASH_VERSION+set}\" || (
- ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
- ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO
- ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO
- PATH=/empty FPATH=/empty; export PATH FPATH
- test \"X\`printf %s \$ECHO\`\" = \"X\$ECHO\" \\
- || test \"X\`print -r -- \$ECHO\`\" = \"X\$ECHO\" ) || exit 1"
- if (eval "$as_required") 2>/dev/null; then :
- as_have_required=yes
-else
- as_have_required=no
-fi
- if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
-
-else
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-as_found=false
-for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- as_found=:
- case $as_dir in #(
- /*)
- for as_base in sh bash ksh sh5; do
- # Try only shells that exist, to save several forks.
- as_shell=$as_dir/$as_base
- if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
- { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
- CONFIG_SHELL=$as_shell as_have_required=yes
- if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
- break 2
-fi
-fi
- done;;
- esac
- as_found=false
-done
-$as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
- { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
- CONFIG_SHELL=$SHELL as_have_required=yes
-fi; }
-IFS=$as_save_IFS
-
-
- if test "x$CONFIG_SHELL" != x; then :
- export CONFIG_SHELL
- # We cannot yet assume a decent shell, so we have to provide a
-# neutralization value for shells without unset; and this also
-# works around shells that cannot unset nonexistent variables.
-# Preserve -v and -x to the replacement shell.
-BASH_ENV=/dev/null
-ENV=/dev/null
-(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
-case $- in # ((((
- *v*x* | *x*v* ) as_opts=-vx ;;
- *v* ) as_opts=-v ;;
- *x* ) as_opts=-x ;;
- * ) as_opts= ;;
-esac
-exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
-# Admittedly, this is quite paranoid, since all the known shells bail
-# out after a failed `exec'.
-$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
-exit 255
-fi
-
- if test x$as_have_required = xno; then :
- $as_echo "$0: This script requires a shell more modern than all"
- $as_echo "$0: the shells that I found on your system."
- if test x${ZSH_VERSION+set} = xset ; then
- $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
- $as_echo "$0: be upgraded to zsh 4.3.4 or later."
- else
- $as_echo "$0: Please tell bug-autoconf@gnu.org about your system,
-$0: including any error possibly output before this
-$0: message. Then install a modern shell, or manually run
-$0: the script under such a shell if you do have one."
- fi
- exit 1
-fi
-fi
-fi
-SHELL=${CONFIG_SHELL-/bin/sh}
-export SHELL
-# Unset more variables known to interfere with behavior of common tools.
-CLICOLOR_FORCE= GREP_OPTIONS=
-unset CLICOLOR_FORCE GREP_OPTIONS
-
-## --------------------- ##
-## M4sh Shell Functions. ##
-## --------------------- ##
-# as_fn_unset VAR
-# ---------------
-# Portably unset VAR.
-as_fn_unset ()
-{
- { eval $1=; unset $1;}
-}
-as_unset=as_fn_unset
-
-# as_fn_set_status STATUS
-# -----------------------
-# Set $? to STATUS, without forking.
-as_fn_set_status ()
-{
- return $1
-} # as_fn_set_status
-
-# as_fn_exit STATUS
-# -----------------
-# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
-as_fn_exit ()
-{
- set +e
- as_fn_set_status $1
- exit $1
-} # as_fn_exit
-
-# as_fn_mkdir_p
-# -------------
-# Create "$as_dir" as a directory, including parents if necessary.
-as_fn_mkdir_p ()
-{
-
- case $as_dir in #(
- -*) as_dir=./$as_dir;;
- esac
- test -d "$as_dir" || eval $as_mkdir_p || {
- as_dirs=
- while :; do
- case $as_dir in #(
- *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
- *) as_qdir=$as_dir;;
- esac
- as_dirs="'$as_qdir' $as_dirs"
- as_dir=`$as_dirname -- "$as_dir" ||
-$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$as_dir" : 'X\(//\)[^/]' \| \
- X"$as_dir" : 'X\(//\)$' \| \
- X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$as_dir" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
- test -d "$as_dir" && break
- done
- test -z "$as_dirs" || eval "mkdir $as_dirs"
- } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
-
-
-} # as_fn_mkdir_p
-
-# as_fn_executable_p FILE
-# -----------------------
-# Test if FILE is an executable regular file.
-as_fn_executable_p ()
-{
- test -f "$1" && test -x "$1"
-} # as_fn_executable_p
-# as_fn_append VAR VALUE
-# ----------------------
-# Append the text in VALUE to the end of the definition contained in VAR. Take
-# advantage of any shell optimizations that allow amortized linear growth over
-# repeated appends, instead of the typical quadratic growth present in naive
-# implementations.
-if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
- eval 'as_fn_append ()
- {
- eval $1+=\$2
- }'
-else
- as_fn_append ()
- {
- eval $1=\$$1\$2
- }
-fi # as_fn_append
-
-# as_fn_arith ARG...
-# ------------------
-# Perform arithmetic evaluation on the ARGs, and store the result in the
-# global $as_val. Take advantage of shells that can avoid forks. The arguments
-# must be portable across $(()) and expr.
-if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
- eval 'as_fn_arith ()
- {
- as_val=$(( $* ))
- }'
-else
- as_fn_arith ()
- {
- as_val=`expr "$@" || test $? -eq 1`
- }
-fi # as_fn_arith
-
-
-# as_fn_error STATUS ERROR [LINENO LOG_FD]
-# ----------------------------------------
-# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
-# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
-# script with STATUS, using 1 if that was 0.
-as_fn_error ()
-{
- as_status=$1; test $as_status -eq 0 && as_status=1
- if test "$4"; then
- as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
- fi
- $as_echo "$as_me: error: $2" >&2
- as_fn_exit $as_status
-} # as_fn_error
-
-if expr a : '\(a\)' >/dev/null 2>&1 &&
- test "X`expr 00001 : '.*\(...\)'`" = X001; then
- as_expr=expr
-else
- as_expr=false
-fi
-
-if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
- as_basename=basename
-else
- as_basename=false
-fi
-
-if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
- as_dirname=dirname
-else
- as_dirname=false
-fi
-
-as_me=`$as_basename -- "$0" ||
-$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
- X"$0" : 'X\(//\)$' \| \
- X"$0" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X/"$0" |
- sed '/^.*\/\([^/][^/]*\)\/*$/{
- s//\1/
- q
- }
- /^X\/\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\/\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
-
-# Avoid depending upon Character Ranges.
-as_cr_letters='abcdefghijklmnopqrstuvwxyz'
-as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
-as_cr_Letters=$as_cr_letters$as_cr_LETTERS
-as_cr_digits='0123456789'
-as_cr_alnum=$as_cr_Letters$as_cr_digits
-
-
- as_lineno_1=$LINENO as_lineno_1a=$LINENO
- as_lineno_2=$LINENO as_lineno_2a=$LINENO
- eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
- test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
- # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-)
- sed -n '
- p
- /[$]LINENO/=
- ' <$as_myself |
- sed '
- s/[$]LINENO.*/&-/
- t lineno
- b
- :lineno
- N
- :loop
- s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
- t loop
- s/-\n.*//
- ' >$as_me.lineno &&
- chmod +x "$as_me.lineno" ||
- { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
-
- # If we had to re-execute with $CONFIG_SHELL, we're ensured to have
- # already done that, so ensure we don't try to do so again and fall
- # in an infinite loop. This has already happened in practice.
- _as_can_reexec=no; export _as_can_reexec
- # Don't try to exec as it changes $[0], causing all sort of problems
- # (the dirname of $[0] is not the place where we might find the
- # original and so on. Autoconf is especially sensitive to this).
- . "./$as_me.lineno"
- # Exit status is that of the last command.
- exit
-}
-
-ECHO_C= ECHO_N= ECHO_T=
-case `echo -n x` in #(((((
--n*)
- case `echo 'xy\c'` in
- *c*) ECHO_T=' ';; # ECHO_T is single tab character.
- xy) ECHO_C='\c';;
- *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
- ECHO_T=' ';;
- esac;;
-*)
- ECHO_N='-n';;
-esac
-
-rm -f conf$$ conf$$.exe conf$$.file
-if test -d conf$$.dir; then
- rm -f conf$$.dir/conf$$.file
-else
- rm -f conf$$.dir
- mkdir conf$$.dir 2>/dev/null
-fi
-if (echo >conf$$.file) 2>/dev/null; then
- if ln -s conf$$.file conf$$ 2>/dev/null; then
- as_ln_s='ln -s'
- # ... but there are two gotchas:
- # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
- # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
- # In both cases, we have to default to `cp -pR'.
- ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
- as_ln_s='cp -pR'
- elif ln conf$$.file conf$$ 2>/dev/null; then
- as_ln_s=ln
- else
- as_ln_s='cp -pR'
- fi
-else
- as_ln_s='cp -pR'
-fi
-rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
-rmdir conf$$.dir 2>/dev/null
-
-if mkdir -p . 2>/dev/null; then
- as_mkdir_p='mkdir -p "$as_dir"'
-else
- test -d ./-p && rmdir ./-p
- as_mkdir_p=false
-fi
-
-as_test_x='test -x'
-as_executable_p=as_fn_executable_p
-
-# Sed expression to map a string onto a valid CPP name.
-as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
-
-# Sed expression to map a string onto a valid variable name.
-as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
-
-SHELL=${CONFIG_SHELL-/bin/sh}
-
-
-test -n "$DJDIR" || exec 7<&0 </dev/null
-exec 6>&1
-
-# Name of the host.
-# hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status,
-# so uname gets run too.
-ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
-
-#
-# Initializations.
-#
-ac_default_prefix=/usr/local
-ac_clean_files=
-ac_config_libobj_dir=.
-LIBOBJS=
-cross_compiling=no
-subdirs=
-MFLAGS=
-MAKEFLAGS=
-
-# Identity of this package.
-PACKAGE_NAME='ld'
-PACKAGE_TARNAME='ld'
-PACKAGE_VERSION='2.43.1'
-PACKAGE_STRING='ld 2.43.1'
-PACKAGE_BUGREPORT=''
-PACKAGE_URL=''
-
-ac_unique_file="ldmain.c"
-# Factoring default headers for most tests.
-ac_includes_default="\
-#include <stdio.h>
-#ifdef HAVE_SYS_TYPES_H
-# include <sys/types.h>
-#endif
-#ifdef HAVE_SYS_STAT_H
-# include <sys/stat.h>
-#endif
-#ifdef STDC_HEADERS
-# include <stdlib.h>
-# include <stddef.h>
-#else
-# ifdef HAVE_STDLIB_H
-# include <stdlib.h>
-# endif
-#endif
-#ifdef HAVE_STRING_H
-# if !defined STDC_HEADERS && defined HAVE_MEMORY_H
-# include <memory.h>
-# endif
-# include <string.h>
-#endif
-#ifdef HAVE_STRINGS_H
-# include <strings.h>
-#endif
-#ifdef HAVE_INTTYPES_H
-# include <inttypes.h>
-#endif
-#ifdef HAVE_STDINT_H
-# include <stdint.h>
-#endif
-#ifdef HAVE_UNISTD_H
-# include <unistd.h>
-#endif"
-
-gt_needs=
-ac_header_list=
-ac_subst_vars='am__EXEEXT_FALSE
-am__EXEEXT_TRUE
-LTLIBOBJS
-LIBOBJS
-TESTSFRAMELIB
-TESTCTFLIB
-TESTBFDLIB
-EMULATION_LIBPATH
-LIB_PATH
-EMUL_EXTRA_OFILES
-EMULATION_OFILES
-TDIRS
-EMUL
-elf_plt_unwind_list_options
-elf_shlib_list_options
-elf_list_options
-ZSTD_LIBS
-ZSTD_CFLAGS
-zlibinc
-zlibdir
-NATIVE_LIB_DIRS
-HDEFINES
-do_compare
-GENINSRC_NEVER_FALSE
-GENINSRC_NEVER_TRUE
-LEXLIB
-LEX_OUTPUT_ROOT
-LEX
-YFLAGS
-YACC
-CATOBJEXT
-GENCAT
-INSTOBJEXT
-DATADIRNAME
-CATALOGS
-INCINTL
-LIBINTL_DEP
-POSUB
-LTLIBINTL
-LIBINTL
-INTLLIBS
-LTLIBICONV
-LIBICONV
-INTL_MACOSX_LIBS
-MSGMERGE
-XGETTEXT
-GMSGFMT
-MSGFMT
-USE_NLS
-MKINSTALLDIRS
-WARN_WRITE_STRINGS
-NO_WERROR
-WARN_CFLAGS_FOR_BUILD
-WARN_CFLAGS
-JANSSON_LIBS
-JANSSON_CFLAGS
-enable_libctf
-ENABLE_LIBCTF_FALSE
-ENABLE_LIBCTF_TRUE
-enable_initfini_array
-installed_linker
-install_as_default
-TARGET_SYSTEM_ROOT_DEFINE
-TARGET_SYSTEM_ROOT
-use_sysroot
-ENABLE_BFD_64_BIT_FALSE
-ENABLE_BFD_64_BIT_TRUE
-LARGEFILE_CPPFLAGS
-CXXCPP
-OTOOL64
-OTOOL
-LIPO
-NMEDIT
-DSYMUTIL
-RANLIB
-AR
-OBJDUMP
-LN_S
-NM
-ac_ct_DUMPBIN
-DUMPBIN
-LD
-FGREP
-SED
-LIBTOOL
-PKG_CONFIG_LIBDIR
-PKG_CONFIG_PATH
-PKG_CONFIG
-EGREP
-CPP
-GREP
-am__fastdepCXX_FALSE
-am__fastdepCXX_TRUE
-CXXDEPMODE
-ac_ct_CXX
-CXXFLAGS
-CXX
-am__fastdepCC_FALSE
-am__fastdepCC_TRUE
-CCDEPMODE
-am__nodep
-AMDEPBACKSLASH
-AMDEP_FALSE
-AMDEP_TRUE
-am__quote
-am__include
-DEPDIR
-OBJEXT
-EXEEXT
-ac_ct_CC
-CPPFLAGS
-LDFLAGS
-CFLAGS
-CC
-MAINT
-MAINTAINER_MODE_FALSE
-MAINTAINER_MODE_TRUE
-AM_BACKSLASH
-AM_DEFAULT_VERBOSITY
-AM_DEFAULT_V
-AM_V
-am__untar
-am__tar
-AMTAR
-am__leading_dot
-SET_MAKE
-AWK
-mkdir_p
-MKDIR_P
-INSTALL_STRIP_PROGRAM
-STRIP
-install_sh
-MAKEINFO
-AUTOHEADER
-AUTOMAKE
-AUTOCONF
-ACLOCAL
-VERSION
-PACKAGE
-CYGPATH_W
-am__isrc
-INSTALL_DATA
-INSTALL_SCRIPT
-INSTALL_PROGRAM
-target_os
-target_vendor
-target_cpu
-target
-host_os
-host_vendor
-host_cpu
-host
-build_os
-build_vendor
-build_cpu
-build
-target_alias
-host_alias
-build_alias
-LIBS
-ECHO_T
-ECHO_N
-ECHO_C
-DEFS
-mandir
-localedir
-libdir
-psdir
-pdfdir
-dvidir
-htmldir
-infodir
-docdir
-oldincludedir
-includedir
-localstatedir
-sharedstatedir
-sysconfdir
-datadir
-datarootdir
-libexecdir
-sbindir
-bindir
-program_transform_name
-prefix
-exec_prefix
-PACKAGE_URL
-PACKAGE_BUGREPORT
-PACKAGE_STRING
-PACKAGE_VERSION
-PACKAGE_TARNAME
-PACKAGE_NAME
-PATH_SEPARATOR
-SHELL'
-ac_subst_files=''
-ac_user_opts='
-enable_option_checking
-enable_silent_rules
-enable_maintainer_mode
-enable_dependency_tracking
-enable_shared
-enable_static
-with_pic
-enable_fast_install
-with_gnu_ld
-enable_libtool_lock
-enable_plugins
-enable_largefile
-enable_checking
-with_lib_path
-enable_targets
-enable_64_bit_bfd
-with_sysroot
-enable_gold
-enable_got
-enable_compressed_debug_sections
-enable_default_compressed_debug_sections_algorithm
-enable_new_dtags
-enable_relro
-enable_textrel_check
-enable_separate_code
-enable_rosegment
-enable_mark_plt
-enable_warn_execstack
-enable_error_execstack
-enable_warn_rwx_segments
-enable_error_rwx_segments
-enable_default_execstack
-enable_error_handling_script
-enable_default_hash_style
-enable_initfini_array
-enable_libctf
-enable_jansson
-enable_werror
-enable_build_warnings
-enable_nls
-enable_rpath
-with_libiconv_prefix
-with_libiconv_type
-with_libintl_prefix
-with_libintl_type
-with_system_zlib
-with_zstd
-'
- ac_precious_vars='build_alias
-host_alias
-target_alias
-CC
-CFLAGS
-LDFLAGS
-LIBS
-CPPFLAGS
-CXX
-CXXFLAGS
-CCC
-CPP
-PKG_CONFIG
-PKG_CONFIG_PATH
-PKG_CONFIG_LIBDIR
-CXXCPP
-JANSSON_CFLAGS
-JANSSON_LIBS
-YACC
-YFLAGS
-ZSTD_CFLAGS
-ZSTD_LIBS'
-
-
-# Initialize some variables set by options.
-ac_init_help=
-ac_init_version=false
-ac_unrecognized_opts=
-ac_unrecognized_sep=
-# The variables have the same names as the options, with
-# dashes changed to underlines.
-cache_file=/dev/null
-exec_prefix=NONE
-no_create=
-no_recursion=
-prefix=NONE
-program_prefix=NONE
-program_suffix=NONE
-program_transform_name=s,x,x,
-silent=
-site=
-srcdir=
-verbose=
-x_includes=NONE
-x_libraries=NONE
-
-# Installation directory options.
-# These are left unexpanded so users can "make install exec_prefix=/foo"
-# and all the variables that are supposed to be based on exec_prefix
-# by default will actually change.
-# Use braces instead of parens because sh, perl, etc. also accept them.
-# (The list follows the same order as the GNU Coding Standards.)
-bindir='${exec_prefix}/bin'
-sbindir='${exec_prefix}/sbin'
-libexecdir='${exec_prefix}/libexec'
-datarootdir='${prefix}/share'
-datadir='${datarootdir}'
-sysconfdir='${prefix}/etc'
-sharedstatedir='${prefix}/com'
-localstatedir='${prefix}/var'
-includedir='${prefix}/include'
-oldincludedir='/usr/include'
-docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
-infodir='${datarootdir}/info'
-htmldir='${docdir}'
-dvidir='${docdir}'
-pdfdir='${docdir}'
-psdir='${docdir}'
-libdir='${exec_prefix}/lib'
-localedir='${datarootdir}/locale'
-mandir='${datarootdir}/man'
-
-ac_prev=
-ac_dashdash=
-for ac_option
-do
- # If the previous option needs an argument, assign it.
- if test -n "$ac_prev"; then
- eval $ac_prev=\$ac_option
- ac_prev=
- continue
- fi
-
- case $ac_option in
- *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
- *=) ac_optarg= ;;
- *) ac_optarg=yes ;;
- esac
-
- # Accept the important Cygnus configure options, so we can diagnose typos.
-
- case $ac_dashdash$ac_option in
- --)
- ac_dashdash=yes ;;
-
- -bindir | --bindir | --bindi | --bind | --bin | --bi)
- ac_prev=bindir ;;
- -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
- bindir=$ac_optarg ;;
-
- -build | --build | --buil | --bui | --bu)
- ac_prev=build_alias ;;
- -build=* | --build=* | --buil=* | --bui=* | --bu=*)
- build_alias=$ac_optarg ;;
-
- -cache-file | --cache-file | --cache-fil | --cache-fi \
- | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
- ac_prev=cache_file ;;
- -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
- | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
- cache_file=$ac_optarg ;;
-
- --config-cache | -C)
- cache_file=config.cache ;;
-
- -datadir | --datadir | --datadi | --datad)
- ac_prev=datadir ;;
- -datadir=* | --datadir=* | --datadi=* | --datad=*)
- datadir=$ac_optarg ;;
-
- -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
- | --dataroo | --dataro | --datar)
- ac_prev=datarootdir ;;
- -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
- | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
- datarootdir=$ac_optarg ;;
-
- -disable-* | --disable-*)
- ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
- # Reject names that are not valid shell variable names.
- expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
- as_fn_error $? "invalid feature name: $ac_useropt"
- ac_useropt_orig=$ac_useropt
- ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
- case $ac_user_opts in
- *"
-"enable_$ac_useropt"
-"*) ;;
- *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
- ac_unrecognized_sep=', ';;
- esac
- eval enable_$ac_useropt=no ;;
-
- -docdir | --docdir | --docdi | --doc | --do)
- ac_prev=docdir ;;
- -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
- docdir=$ac_optarg ;;
-
- -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
- ac_prev=dvidir ;;
- -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
- dvidir=$ac_optarg ;;
-
- -enable-* | --enable-*)
- ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
- # Reject names that are not valid shell variable names.
- expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
- as_fn_error $? "invalid feature name: $ac_useropt"
- ac_useropt_orig=$ac_useropt
- ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
- case $ac_user_opts in
- *"
-"enable_$ac_useropt"
-"*) ;;
- *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
- ac_unrecognized_sep=', ';;
- esac
- eval enable_$ac_useropt=\$ac_optarg ;;
-
- -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
- | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
- | --exec | --exe | --ex)
- ac_prev=exec_prefix ;;
- -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
- | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
- | --exec=* | --exe=* | --ex=*)
- exec_prefix=$ac_optarg ;;
-
- -gas | --gas | --ga | --g)
- # Obsolete; use --with-gas.
- with_gas=yes ;;
-
- -help | --help | --hel | --he | -h)
- ac_init_help=long ;;
- -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
- ac_init_help=recursive ;;
- -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
- ac_init_help=short ;;
-
- -host | --host | --hos | --ho)
- ac_prev=host_alias ;;
- -host=* | --host=* | --hos=* | --ho=*)
- host_alias=$ac_optarg ;;
-
- -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
- ac_prev=htmldir ;;
- -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
- | --ht=*)
- htmldir=$ac_optarg ;;
-
- -includedir | --includedir | --includedi | --included | --include \
- | --includ | --inclu | --incl | --inc)
- ac_prev=includedir ;;
- -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
- | --includ=* | --inclu=* | --incl=* | --inc=*)
- includedir=$ac_optarg ;;
-
- -infodir | --infodir | --infodi | --infod | --info | --inf)
- ac_prev=infodir ;;
- -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
- infodir=$ac_optarg ;;
-
- -libdir | --libdir | --libdi | --libd)
- ac_prev=libdir ;;
- -libdir=* | --libdir=* | --libdi=* | --libd=*)
- libdir=$ac_optarg ;;
-
- -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
- | --libexe | --libex | --libe)
- ac_prev=libexecdir ;;
- -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
- | --libexe=* | --libex=* | --libe=*)
- libexecdir=$ac_optarg ;;
-
- -localedir | --localedir | --localedi | --localed | --locale)
- ac_prev=localedir ;;
- -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
- localedir=$ac_optarg ;;
-
- -localstatedir | --localstatedir | --localstatedi | --localstated \
- | --localstate | --localstat | --localsta | --localst | --locals)
- ac_prev=localstatedir ;;
- -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
- | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
- localstatedir=$ac_optarg ;;
-
- -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
- ac_prev=mandir ;;
- -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
- mandir=$ac_optarg ;;
-
- -nfp | --nfp | --nf)
- # Obsolete; use --without-fp.
- with_fp=no ;;
-
- -no-create | --no-create | --no-creat | --no-crea | --no-cre \
- | --no-cr | --no-c | -n)
- no_create=yes ;;
-
- -no-recursion | --no-recursion | --no-recursio | --no-recursi \
- | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
- no_recursion=yes ;;
-
- -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
- | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
- | --oldin | --oldi | --old | --ol | --o)
- ac_prev=oldincludedir ;;
- -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
- | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
- | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
- oldincludedir=$ac_optarg ;;
-
- -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
- ac_prev=prefix ;;
- -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
- prefix=$ac_optarg ;;
-
- -program-prefix | --program-prefix | --program-prefi | --program-pref \
- | --program-pre | --program-pr | --program-p)
- ac_prev=program_prefix ;;
- -program-prefix=* | --program-prefix=* | --program-prefi=* \
- | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
- program_prefix=$ac_optarg ;;
-
- -program-suffix | --program-suffix | --program-suffi | --program-suff \
- | --program-suf | --program-su | --program-s)
- ac_prev=program_suffix ;;
- -program-suffix=* | --program-suffix=* | --program-suffi=* \
- | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
- program_suffix=$ac_optarg ;;
-
- -program-transform-name | --program-transform-name \
- | --program-transform-nam | --program-transform-na \
- | --program-transform-n | --program-transform- \
- | --program-transform | --program-transfor \
- | --program-transfo | --program-transf \
- | --program-trans | --program-tran \
- | --progr-tra | --program-tr | --program-t)
- ac_prev=program_transform_name ;;
- -program-transform-name=* | --program-transform-name=* \
- | --program-transform-nam=* | --program-transform-na=* \
- | --program-transform-n=* | --program-transform-=* \
- | --program-transform=* | --program-transfor=* \
- | --program-transfo=* | --program-transf=* \
- | --program-trans=* | --program-tran=* \
- | --progr-tra=* | --program-tr=* | --program-t=*)
- program_transform_name=$ac_optarg ;;
-
- -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
- ac_prev=pdfdir ;;
- -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
- pdfdir=$ac_optarg ;;
-
- -psdir | --psdir | --psdi | --psd | --ps)
- ac_prev=psdir ;;
- -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
- psdir=$ac_optarg ;;
-
- -q | -quiet | --quiet | --quie | --qui | --qu | --q \
- | -silent | --silent | --silen | --sile | --sil)
- silent=yes ;;
-
- -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
- ac_prev=sbindir ;;
- -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
- | --sbi=* | --sb=*)
- sbindir=$ac_optarg ;;
-
- -sharedstatedir | --sharedstatedir | --sharedstatedi \
- | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
- | --sharedst | --shareds | --shared | --share | --shar \
- | --sha | --sh)
- ac_prev=sharedstatedir ;;
- -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
- | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
- | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
- | --sha=* | --sh=*)
- sharedstatedir=$ac_optarg ;;
-
- -site | --site | --sit)
- ac_prev=site ;;
- -site=* | --site=* | --sit=*)
- site=$ac_optarg ;;
-
- -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
- ac_prev=srcdir ;;
- -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
- srcdir=$ac_optarg ;;
-
- -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
- | --syscon | --sysco | --sysc | --sys | --sy)
- ac_prev=sysconfdir ;;
- -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
- | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
- sysconfdir=$ac_optarg ;;
-
- -target | --target | --targe | --targ | --tar | --ta | --t)
- ac_prev=target_alias ;;
- -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
- target_alias=$ac_optarg ;;
-
- -v | -verbose | --verbose | --verbos | --verbo | --verb)
- verbose=yes ;;
-
- -version | --version | --versio | --versi | --vers | -V)
- ac_init_version=: ;;
-
- -with-* | --with-*)
- ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
- # Reject names that are not valid shell variable names.
- expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
- as_fn_error $? "invalid package name: $ac_useropt"
- ac_useropt_orig=$ac_useropt
- ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
- case $ac_user_opts in
- *"
-"with_$ac_useropt"
-"*) ;;
- *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
- ac_unrecognized_sep=', ';;
- esac
- eval with_$ac_useropt=\$ac_optarg ;;
-
- -without-* | --without-*)
- ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
- # Reject names that are not valid shell variable names.
- expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
- as_fn_error $? "invalid package name: $ac_useropt"
- ac_useropt_orig=$ac_useropt
- ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
- case $ac_user_opts in
- *"
-"with_$ac_useropt"
-"*) ;;
- *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
- ac_unrecognized_sep=', ';;
- esac
- eval with_$ac_useropt=no ;;
-
- --x)
- # Obsolete; use --with-x.
- with_x=yes ;;
-
- -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
- | --x-incl | --x-inc | --x-in | --x-i)
- ac_prev=x_includes ;;
- -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
- | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
- x_includes=$ac_optarg ;;
-
- -x-libraries | --x-libraries | --x-librarie | --x-librari \
- | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
- ac_prev=x_libraries ;;
- -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
- | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
- x_libraries=$ac_optarg ;;
-
- -*) as_fn_error $? "unrecognized option: \`$ac_option'
-Try \`$0 --help' for more information"
- ;;
-
- *=*)
- ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
- # Reject names that are not valid shell variable names.
- case $ac_envvar in #(
- '' | [0-9]* | *[!_$as_cr_alnum]* )
- as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
- esac
- eval $ac_envvar=\$ac_optarg
- export $ac_envvar ;;
-
- *)
- # FIXME: should be removed in autoconf 3.0.
- $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
- expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
- $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
- : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
- ;;
-
- esac
-done
-
-if test -n "$ac_prev"; then
- ac_option=--`echo $ac_prev | sed 's/_/-/g'`
- as_fn_error $? "missing argument to $ac_option"
-fi
-
-if test -n "$ac_unrecognized_opts"; then
- case $enable_option_checking in
- no) ;;
- fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
- *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
- esac
-fi
-
-# Check all directory arguments for consistency.
-for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
- datadir sysconfdir sharedstatedir localstatedir includedir \
- oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
- libdir localedir mandir
-do
- eval ac_val=\$$ac_var
- # Remove trailing slashes.
- case $ac_val in
- */ )
- ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
- eval $ac_var=\$ac_val;;
- esac
- # Be sure to have absolute directory names.
- case $ac_val in
- [\\/$]* | ?:[\\/]* ) continue;;
- NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
- esac
- as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
-done
-
-# There might be people who depend on the old broken behavior: `$host'
-# used to hold the argument of --host etc.
-# FIXME: To remove some day.
-build=$build_alias
-host=$host_alias
-target=$target_alias
-
-# FIXME: To remove some day.
-if test "x$host_alias" != x; then
- if test "x$build_alias" = x; then
- cross_compiling=maybe
- elif test "x$build_alias" != "x$host_alias"; then
- cross_compiling=yes
- fi
-fi
-
-ac_tool_prefix=
-test -n "$host_alias" && ac_tool_prefix=$host_alias-
-
-test "$silent" = yes && exec 6>/dev/null
-
-
-ac_pwd=`pwd` && test -n "$ac_pwd" &&
-ac_ls_di=`ls -di .` &&
-ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
- as_fn_error $? "working directory cannot be determined"
-test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
- as_fn_error $? "pwd does not report name of working directory"
-
-
-# Find the source files, if location was not specified.
-if test -z "$srcdir"; then
- ac_srcdir_defaulted=yes
- # Try the directory containing this script, then the parent directory.
- ac_confdir=`$as_dirname -- "$as_myself" ||
-$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$as_myself" : 'X\(//\)[^/]' \| \
- X"$as_myself" : 'X\(//\)$' \| \
- X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$as_myself" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
- srcdir=$ac_confdir
- if test ! -r "$srcdir/$ac_unique_file"; then
- srcdir=..
- fi
-else
- ac_srcdir_defaulted=no
-fi
-if test ! -r "$srcdir/$ac_unique_file"; then
- test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
- as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
-fi
-ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
-ac_abs_confdir=`(
- cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
- pwd)`
-# When building in place, set srcdir=.
-if test "$ac_abs_confdir" = "$ac_pwd"; then
- srcdir=.
-fi
-# Remove unnecessary trailing slashes from srcdir.
-# Double slashes in file names in object file debugging info
-# mess up M-x gdb in Emacs.
-case $srcdir in
-*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
-esac
-for ac_var in $ac_precious_vars; do
- eval ac_env_${ac_var}_set=\${${ac_var}+set}
- eval ac_env_${ac_var}_value=\$${ac_var}
- eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
- eval ac_cv_env_${ac_var}_value=\$${ac_var}
-done
-
-#
-# Report the --help message.
-#
-if test "$ac_init_help" = "long"; then
- # Omit some internal or obsolete options to make the list less imposing.
- # This message is too long to be a string in the A/UX 3.1 sh.
- cat <<_ACEOF
-\`configure' configures ld 2.43.1 to adapt to many kinds of systems.
-
-Usage: $0 [OPTION]... [VAR=VALUE]...
-
-To assign environment variables (e.g., CC, CFLAGS...), specify them as
-VAR=VALUE. See below for descriptions of some of the useful variables.
-
-Defaults for the options are specified in brackets.
-
-Configuration:
- -h, --help display this help and exit
- --help=short display options specific to this package
- --help=recursive display the short help of all the included packages
- -V, --version display version information and exit
- -q, --quiet, --silent do not print \`checking ...' messages
- --cache-file=FILE cache test results in FILE [disabled]
- -C, --config-cache alias for \`--cache-file=config.cache'
- -n, --no-create do not create output files
- --srcdir=DIR find the sources in DIR [configure dir or \`..']
-
-Installation directories:
- --prefix=PREFIX install architecture-independent files in PREFIX
- [$ac_default_prefix]
- --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
- [PREFIX]
-
-By default, \`make install' will install all the files in
-\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
-an installation prefix other than \`$ac_default_prefix' using \`--prefix',
-for instance \`--prefix=\$HOME'.
-
-For better control, use the options below.
-
-Fine tuning of the installation directories:
- --bindir=DIR user executables [EPREFIX/bin]
- --sbindir=DIR system admin executables [EPREFIX/sbin]
- --libexecdir=DIR program executables [EPREFIX/libexec]
- --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
- --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
- --localstatedir=DIR modifiable single-machine data [PREFIX/var]
- --libdir=DIR object code libraries [EPREFIX/lib]
- --includedir=DIR C header files [PREFIX/include]
- --oldincludedir=DIR C header files for non-gcc [/usr/include]
- --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
- --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
- --infodir=DIR info documentation [DATAROOTDIR/info]
- --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
- --mandir=DIR man documentation [DATAROOTDIR/man]
- --docdir=DIR documentation root [DATAROOTDIR/doc/ld]
- --htmldir=DIR html documentation [DOCDIR]
- --dvidir=DIR dvi documentation [DOCDIR]
- --pdfdir=DIR pdf documentation [DOCDIR]
- --psdir=DIR ps documentation [DOCDIR]
-_ACEOF
-
- cat <<\_ACEOF
-
-Program names:
- --program-prefix=PREFIX prepend PREFIX to installed program names
- --program-suffix=SUFFIX append SUFFIX to installed program names
- --program-transform-name=PROGRAM run sed PROGRAM on installed program names
-
-System types:
- --build=BUILD configure for building on BUILD [guessed]
- --host=HOST cross-compile to build programs to run on HOST [BUILD]
- --target=TARGET configure for building compilers for TARGET [HOST]
-_ACEOF
-fi
-
-if test -n "$ac_init_help"; then
- case $ac_init_help in
- short | recursive ) echo "Configuration of ld 2.43.1:";;
- esac
- cat <<\_ACEOF
-
-Optional Features:
- --disable-option-checking ignore unrecognized --enable/--with options
- --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
- --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
- --enable-silent-rules less verbose build output (undo: "make V=1")
- --disable-silent-rules verbose build output (undo: "make V=0")
- --enable-maintainer-mode
- enable make rules and dependencies not useful (and
- sometimes confusing) to the casual installer
- --enable-dependency-tracking
- do not reject slow dependency extractors
- --disable-dependency-tracking
- speeds up one-time build
- --enable-shared[=PKGS] build shared libraries [default=yes]
- --enable-static[=PKGS] build static libraries [default=yes]
- --enable-fast-install[=PKGS]
- optimize for fast installation [default=yes]
- --disable-libtool-lock avoid locking (might break parallel builds)
- --enable-plugins Enable support for plugins
- --disable-largefile omit support for large files
- --enable-checking enable run-time checks
- --enable-targets alternative target configurations
- --enable-64-bit-bfd 64-bit support (on hosts with narrower word sizes)
- --enable-gold[=ARG] build gold [ARG={default,yes,no}]
- --enable-got=<type> GOT handling scheme (target, single, negative,
- multigot)
- --enable-compressed-debug-sections={all,ld,none}
- compress debug sections by default]
- --enable-default-compressed-debug-sections-algorithm={zlib,zstd}
- Default compression algorithm for
- --enable-compressed-debug-sections.
- --enable-new-dtags set DT_RUNPATH instead of DT_RPATH by default]
- --enable-relro enable -z relro in ELF linker by default
- --enable-textrel-check=[yes|no|warning|error]
- enable DT_TEXTREL check in ELF linker
- --enable-separate-code enable -z separate-code in ELF linker by default
- --enable-rosegment enable --rosegment in the ELF linker by default
- --enable-mark-plt enable -z mark-plt in ELF x86-64 linker by default
- --enable-warn-execstack enable warnings when creating an executable stack
- --enable-error-execstack
- turn executable stack warnings into errors
- --enable-warn-rwx-segments
- enable warnings when creating segments with RWX
- permissions
- --enable-error-rwx-segments
- turn executable segment warnings into errors
- --enable-default-execstack
- create an executable stack if an input file is
- missing a .note.GNU-stack section
- --enable-error-handling-script
- enable/disable support for the
- --error-handling-script option
- --enable-default-hash-style={sysv,gnu,both}
- use this default hash style
- --disable-initfini-array do not use .init_array/.fini_array sections
- --enable-libctf Handle .ctf type-info sections [default=yes]
- --enable-jansson enable jansson [default=no]
- --enable-werror treat compile warnings as errors
- --enable-build-warnings enable build-time compiler warnings
- --disable-nls do not use Native Language Support
- --disable-rpath do not hardcode runtime library paths
-
-Optional Packages:
- --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
- --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
- --with-pic try to use only PIC/non-PIC objects [default=use
- both]
- --with-gnu-ld assume the C compiler uses GNU ld [default=no]
- --with-lib-path=dir1:dir2... set default LIB_PATH
- --with-sysroot=DIR Search for usr/lib et al within DIR.
- --with-gnu-ld assume the C compiler uses GNU ld default=no
- --with-libiconv-prefix[=DIR] search for libiconv in DIR/include and DIR/lib
- --without-libiconv-prefix don't search for libiconv in includedir and libdir
- --with-libiconv-type=TYPE type of library to search for (auto/static/shared)
- --with-libintl-prefix[=DIR] search for libintl in DIR/include and DIR/lib
- --without-libintl-prefix don't search for libintl in includedir and libdir
- --with-libintl-type=TYPE type of library to search for (auto/static/shared)
- --with-system-zlib use installed libz
- --with-zstd support zstd compressed debug sections
- (default=auto)
-
-Some influential environment variables:
- CC C compiler command
- CFLAGS C compiler flags
- LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
- nonstandard directory <lib dir>
- LIBS libraries to pass to the linker, e.g. -l<library>
- CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
- you have headers in a nonstandard directory <include dir>
- CXX C++ compiler command
- CXXFLAGS C++ compiler flags
- CPP C preprocessor
- PKG_CONFIG path to pkg-config utility
- PKG_CONFIG_PATH
- directories to add to pkg-config's search path
- PKG_CONFIG_LIBDIR
- path overriding pkg-config's built-in search path
- CXXCPP C++ preprocessor
- JANSSON_CFLAGS
- C compiler flags for JANSSON, overriding pkg-config
- JANSSON_LIBS
- linker flags for JANSSON, overriding pkg-config
- YACC The `Yet Another Compiler Compiler' implementation to use.
- Defaults to the first program found out of: `bison -y', `byacc',
- `yacc'.
- YFLAGS The list of arguments that will be passed by default to $YACC.
- This script will default YFLAGS to the empty string to avoid a
- default value of `-d' given by some make applications.
- ZSTD_CFLAGS C compiler flags for ZSTD, overriding pkg-config
- ZSTD_LIBS linker flags for ZSTD, overriding pkg-config
-
-Use these variables to override the choices made by `configure' or to help
-it to find libraries and programs with nonstandard names/locations.
-
-Report bugs to the package provider.
-_ACEOF
-ac_status=$?
-fi
-
-if test "$ac_init_help" = "recursive"; then
- # If there are subdirs, report their specific --help.
- for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
- test -d "$ac_dir" ||
- { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
- continue
- ac_builddir=.
-
-case "$ac_dir" in
-.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
-*)
- ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
- # A ".." for each directory in $ac_dir_suffix.
- ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
- case $ac_top_builddir_sub in
- "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
- *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
- esac ;;
-esac
-ac_abs_top_builddir=$ac_pwd
-ac_abs_builddir=$ac_pwd$ac_dir_suffix
-# for backward compatibility:
-ac_top_builddir=$ac_top_build_prefix
-
-case $srcdir in
- .) # We are building in place.
- ac_srcdir=.
- ac_top_srcdir=$ac_top_builddir_sub
- ac_abs_top_srcdir=$ac_pwd ;;
- [\\/]* | ?:[\\/]* ) # Absolute name.
- ac_srcdir=$srcdir$ac_dir_suffix;
- ac_top_srcdir=$srcdir
- ac_abs_top_srcdir=$srcdir ;;
- *) # Relative name.
- ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
- ac_top_srcdir=$ac_top_build_prefix$srcdir
- ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
-esac
-ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
-
- cd "$ac_dir" || { ac_status=$?; continue; }
- # Check for guested configure.
- if test -f "$ac_srcdir/configure.gnu"; then
- echo &&
- $SHELL "$ac_srcdir/configure.gnu" --help=recursive
- elif test -f "$ac_srcdir/configure"; then
- echo &&
- $SHELL "$ac_srcdir/configure" --help=recursive
- else
- $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
- fi || ac_status=$?
- cd "$ac_pwd" || { ac_status=$?; break; }
- done
-fi
-
-test -n "$ac_init_help" && exit $ac_status
-if $ac_init_version; then
- cat <<\_ACEOF
-ld configure 2.43.1
-generated by GNU Autoconf 2.69
-
-Copyright (C) 2012 Free Software Foundation, Inc.
-This configure script is free software; the Free Software Foundation
-gives unlimited permission to copy, distribute and modify it.
-_ACEOF
- exit
-fi
-
-## ------------------------ ##
-## Autoconf initialization. ##
-## ------------------------ ##
-
-# ac_fn_c_try_compile LINENO
-# --------------------------
-# Try to compile conftest.$ac_ext, and return whether this succeeded.
-ac_fn_c_try_compile ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- rm -f conftest.$ac_objext
- if { { ac_try="$ac_compile"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_compile") 2>conftest.err
- ac_status=$?
- if test -s conftest.err; then
- grep -v '^ *+' conftest.err >conftest.er1
- cat conftest.er1 >&5
- mv -f conftest.er1 conftest.err
- fi
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && {
- test -z "$ac_c_werror_flag" ||
- test ! -s conftest.err
- } && test -s conftest.$ac_objext; then :
- ac_retval=0
-else
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
- ac_retval=1
-fi
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
- as_fn_set_status $ac_retval
-
-} # ac_fn_c_try_compile
-
-# ac_fn_cxx_try_compile LINENO
-# ----------------------------
-# Try to compile conftest.$ac_ext, and return whether this succeeded.
-ac_fn_cxx_try_compile ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- rm -f conftest.$ac_objext
- if { { ac_try="$ac_compile"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_compile") 2>conftest.err
- ac_status=$?
- if test -s conftest.err; then
- grep -v '^ *+' conftest.err >conftest.er1
- cat conftest.er1 >&5
- mv -f conftest.er1 conftest.err
- fi
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && {
- test -z "$ac_cxx_werror_flag" ||
- test ! -s conftest.err
- } && test -s conftest.$ac_objext; then :
- ac_retval=0
-else
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
- ac_retval=1
-fi
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
- as_fn_set_status $ac_retval
-
-} # ac_fn_cxx_try_compile
-
-# ac_fn_c_try_cpp LINENO
-# ----------------------
-# Try to preprocess conftest.$ac_ext, and return whether this succeeded.
-ac_fn_c_try_cpp ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- if { { ac_try="$ac_cpp conftest.$ac_ext"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
- ac_status=$?
- if test -s conftest.err; then
- grep -v '^ *+' conftest.err >conftest.er1
- cat conftest.er1 >&5
- mv -f conftest.er1 conftest.err
- fi
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } > conftest.i && {
- test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
- test ! -s conftest.err
- }; then :
- ac_retval=0
-else
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
- ac_retval=1
-fi
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
- as_fn_set_status $ac_retval
-
-} # ac_fn_c_try_cpp
-
-# ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
-# -------------------------------------------------------
-# Tests whether HEADER exists, giving a warning if it cannot be compiled using
-# the include files in INCLUDES and setting the cache variable VAR
-# accordingly.
-ac_fn_c_check_header_mongrel ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- if eval \${$3+:} false; then :
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
-$as_echo_n "checking for $2... " >&6; }
-if eval \${$3+:} false; then :
- $as_echo_n "(cached) " >&6
-fi
-eval ac_res=\$$3
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
-else
- # Is the header compilable?
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
-$as_echo_n "checking $2 usability... " >&6; }
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$4
-#include <$2>
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_header_compiler=yes
-else
- ac_header_compiler=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
-$as_echo "$ac_header_compiler" >&6; }
-
-# Is the header present?
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
-$as_echo_n "checking $2 presence... " >&6; }
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <$2>
-_ACEOF
-if ac_fn_c_try_cpp "$LINENO"; then :
- ac_header_preproc=yes
-else
- ac_header_preproc=no
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
-$as_echo "$ac_header_preproc" >&6; }
-
-# So? What about this header?
-case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
- yes:no: )
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
-$as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
-$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
- ;;
- no:yes:* )
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
-$as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
-$as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
-$as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
-$as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
-$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
- ;;
-esac
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
-$as_echo_n "checking for $2... " >&6; }
-if eval \${$3+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- eval "$3=\$ac_header_compiler"
-fi
-eval ac_res=\$$3
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
-fi
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
-
-} # ac_fn_c_check_header_mongrel
-
-# ac_fn_c_try_run LINENO
-# ----------------------
-# Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
-# that executables *can* be run.
-ac_fn_c_try_run ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- if { { ac_try="$ac_link"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_link") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
- { { case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_try") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; }; then :
- ac_retval=0
-else
- $as_echo "$as_me: program exited with status $ac_status" >&5
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
- ac_retval=$ac_status
-fi
- rm -rf conftest.dSYM conftest_ipa8_conftest.oo
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
- as_fn_set_status $ac_retval
-
-} # ac_fn_c_try_run
-
-# ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
-# -------------------------------------------------------
-# Tests whether HEADER exists and can be compiled using the include files in
-# INCLUDES, setting the cache variable VAR accordingly.
-ac_fn_c_check_header_compile ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
-$as_echo_n "checking for $2... " >&6; }
-if eval \${$3+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$4
-#include <$2>
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- eval "$3=yes"
-else
- eval "$3=no"
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-eval ac_res=\$$3
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
-
-} # ac_fn_c_check_header_compile
-
-# ac_fn_c_try_link LINENO
-# -----------------------
-# Try to link conftest.$ac_ext, and return whether this succeeded.
-ac_fn_c_try_link ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- rm -f conftest.$ac_objext conftest$ac_exeext
- if { { ac_try="$ac_link"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_link") 2>conftest.err
- ac_status=$?
- if test -s conftest.err; then
- grep -v '^ *+' conftest.err >conftest.er1
- cat conftest.er1 >&5
- mv -f conftest.er1 conftest.err
- fi
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && {
- test -z "$ac_c_werror_flag" ||
- test ! -s conftest.err
- } && test -s conftest$ac_exeext && {
- test "$cross_compiling" = yes ||
- test -x conftest$ac_exeext
- }; then :
- ac_retval=0
-else
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
- ac_retval=1
-fi
- # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
- # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
- # interfere with the next link command; also delete a directory that is
- # left behind by Apple's compiler. We do this before executing the actions.
- rm -rf conftest.dSYM conftest_ipa8_conftest.oo
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
- as_fn_set_status $ac_retval
-
-} # ac_fn_c_try_link
-
-# ac_fn_c_check_func LINENO FUNC VAR
-# ----------------------------------
-# Tests whether FUNC exists, setting the cache variable VAR accordingly
-ac_fn_c_check_func ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
-$as_echo_n "checking for $2... " >&6; }
-if eval \${$3+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-/* Define $2 to an innocuous variant, in case <limits.h> declares $2.
- For example, HP-UX 11i <limits.h> declares gettimeofday. */
-#define $2 innocuous_$2
-
-/* System header to define __stub macros and hopefully few prototypes,
- which can conflict with char $2 (); below.
- Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
- <limits.h> exists even on freestanding compilers. */
-
-#ifdef __STDC__
-# include <limits.h>
-#else
-# include <assert.h>
-#endif
-
-#undef $2
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char $2 ();
-/* The GNU C library defines this for functions which it implements
- to always fail with ENOSYS. Some functions are actually named
- something starting with __ and the normal name is an alias. */
-#if defined __stub_$2 || defined __stub___$2
-choke me
-#endif
-
-int
-main ()
-{
-return $2 ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- eval "$3=yes"
-else
- eval "$3=no"
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-fi
-eval ac_res=\$$3
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
-
-} # ac_fn_c_check_func
-
-# ac_fn_cxx_try_cpp LINENO
-# ------------------------
-# Try to preprocess conftest.$ac_ext, and return whether this succeeded.
-ac_fn_cxx_try_cpp ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- if { { ac_try="$ac_cpp conftest.$ac_ext"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
- ac_status=$?
- if test -s conftest.err; then
- grep -v '^ *+' conftest.err >conftest.er1
- cat conftest.er1 >&5
- mv -f conftest.er1 conftest.err
- fi
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } > conftest.i && {
- test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" ||
- test ! -s conftest.err
- }; then :
- ac_retval=0
-else
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
- ac_retval=1
-fi
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
- as_fn_set_status $ac_retval
-
-} # ac_fn_cxx_try_cpp
-
-# ac_fn_cxx_try_link LINENO
-# -------------------------
-# Try to link conftest.$ac_ext, and return whether this succeeded.
-ac_fn_cxx_try_link ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- rm -f conftest.$ac_objext conftest$ac_exeext
- if { { ac_try="$ac_link"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_link") 2>conftest.err
- ac_status=$?
- if test -s conftest.err; then
- grep -v '^ *+' conftest.err >conftest.er1
- cat conftest.er1 >&5
- mv -f conftest.er1 conftest.err
- fi
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && {
- test -z "$ac_cxx_werror_flag" ||
- test ! -s conftest.err
- } && test -s conftest$ac_exeext && {
- test "$cross_compiling" = yes ||
- test -x conftest$ac_exeext
- }; then :
- ac_retval=0
-else
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
- ac_retval=1
-fi
- # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
- # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
- # interfere with the next link command; also delete a directory that is
- # left behind by Apple's compiler. We do this before executing the actions.
- rm -rf conftest.dSYM conftest_ipa8_conftest.oo
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
- as_fn_set_status $ac_retval
-
-} # ac_fn_cxx_try_link
-
-# ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
-# --------------------------------------------
-# Tries to find the compile-time value of EXPR in a program that includes
-# INCLUDES, setting VAR accordingly. Returns whether the value could be
-# computed
-ac_fn_c_compute_int ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- if test "$cross_compiling" = yes; then
- # Depending upon the size, compute the lo and hi bounds.
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$4
-int
-main ()
-{
-static int test_array [1 - 2 * !(($2) >= 0)];
-test_array [0] = 0;
-return test_array [0];
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_lo=0 ac_mid=0
- while :; do
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$4
-int
-main ()
-{
-static int test_array [1 - 2 * !(($2) <= $ac_mid)];
-test_array [0] = 0;
-return test_array [0];
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_hi=$ac_mid; break
-else
- as_fn_arith $ac_mid + 1 && ac_lo=$as_val
- if test $ac_lo -le $ac_mid; then
- ac_lo= ac_hi=
- break
- fi
- as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- done
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$4
-int
-main ()
-{
-static int test_array [1 - 2 * !(($2) < 0)];
-test_array [0] = 0;
-return test_array [0];
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_hi=-1 ac_mid=-1
- while :; do
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$4
-int
-main ()
-{
-static int test_array [1 - 2 * !(($2) >= $ac_mid)];
-test_array [0] = 0;
-return test_array [0];
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_lo=$ac_mid; break
-else
- as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
- if test $ac_mid -le $ac_hi; then
- ac_lo= ac_hi=
- break
- fi
- as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- done
-else
- ac_lo= ac_hi=
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-# Binary search between lo and hi bounds.
-while test "x$ac_lo" != "x$ac_hi"; do
- as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$4
-int
-main ()
-{
-static int test_array [1 - 2 * !(($2) <= $ac_mid)];
-test_array [0] = 0;
-return test_array [0];
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_hi=$ac_mid
-else
- as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-done
-case $ac_lo in #((
-?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
-'') ac_retval=1 ;;
-esac
- else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$4
-static long int longval () { return $2; }
-static unsigned long int ulongval () { return $2; }
-#include <stdio.h>
-#include <stdlib.h>
-int
-main ()
-{
-
- FILE *f = fopen ("conftest.val", "w");
- if (! f)
- return 1;
- if (($2) < 0)
- {
- long int i = longval ();
- if (i != ($2))
- return 1;
- fprintf (f, "%ld", i);
- }
- else
- {
- unsigned long int i = ulongval ();
- if (i != ($2))
- return 1;
- fprintf (f, "%lu", i);
- }
- /* Do not output a trailing newline, as this causes \r\n confusion
- on some platforms. */
- return ferror (f) || fclose (f) != 0;
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_run "$LINENO"; then :
- echo >>conftest.val; read $3 <conftest.val; ac_retval=0
-else
- ac_retval=1
-fi
-rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
- conftest.$ac_objext conftest.beam conftest.$ac_ext
-rm -f conftest.val
-
- fi
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
- as_fn_set_status $ac_retval
-
-} # ac_fn_c_compute_int
-
-# ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES
-# ---------------------------------------------
-# Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR
-# accordingly.
-ac_fn_c_check_decl ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- as_decl_name=`echo $2|sed 's/ *(.*//'`
- as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'`
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5
-$as_echo_n "checking whether $as_decl_name is declared... " >&6; }
-if eval \${$3+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$4
-int
-main ()
-{
-#ifndef $as_decl_name
-#ifdef __cplusplus
- (void) $as_decl_use;
-#else
- (void) $as_decl_name;
-#endif
-#endif
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- eval "$3=yes"
-else
- eval "$3=no"
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-eval ac_res=\$$3
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
-
-} # ac_fn_c_check_decl
-cat >config.log <<_ACEOF
-This file contains any messages produced by compilers while
-running configure, to aid debugging if configure makes a mistake.
-
-It was created by ld $as_me 2.43.1, which was
-generated by GNU Autoconf 2.69. Invocation command line was
-
- $ $0 $@
-
-_ACEOF
-exec 5>>config.log
-{
-cat <<_ASUNAME
-## --------- ##
-## Platform. ##
-## --------- ##
-
-hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
-uname -m = `(uname -m) 2>/dev/null || echo unknown`
-uname -r = `(uname -r) 2>/dev/null || echo unknown`
-uname -s = `(uname -s) 2>/dev/null || echo unknown`
-uname -v = `(uname -v) 2>/dev/null || echo unknown`
-
-/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
-/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
-
-/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
-/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
-/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
-/usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
-/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
-/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
-/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
-
-_ASUNAME
-
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- $as_echo "PATH: $as_dir"
- done
-IFS=$as_save_IFS
-
-} >&5
-
-cat >&5 <<_ACEOF
-
-
-## ----------- ##
-## Core tests. ##
-## ----------- ##
-
-_ACEOF
-
-
-# Keep a trace of the command line.
-# Strip out --no-create and --no-recursion so they do not pile up.
-# Strip out --silent because we don't want to record it for future runs.
-# Also quote any args containing shell meta-characters.
-# Make two passes to allow for proper duplicate-argument suppression.
-ac_configure_args=
-ac_configure_args0=
-ac_configure_args1=
-ac_must_keep_next=false
-for ac_pass in 1 2
-do
- for ac_arg
- do
- case $ac_arg in
- -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
- -q | -quiet | --quiet | --quie | --qui | --qu | --q \
- | -silent | --silent | --silen | --sile | --sil)
- continue ;;
- *\'*)
- ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
- esac
- case $ac_pass in
- 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
- 2)
- as_fn_append ac_configure_args1 " '$ac_arg'"
- if test $ac_must_keep_next = true; then
- ac_must_keep_next=false # Got value, back to normal.
- else
- case $ac_arg in
- *=* | --config-cache | -C | -disable-* | --disable-* \
- | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
- | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
- | -with-* | --with-* | -without-* | --without-* | --x)
- case "$ac_configure_args0 " in
- "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
- esac
- ;;
- -* ) ac_must_keep_next=true ;;
- esac
- fi
- as_fn_append ac_configure_args " '$ac_arg'"
- ;;
- esac
- done
-done
-{ ac_configure_args0=; unset ac_configure_args0;}
-{ ac_configure_args1=; unset ac_configure_args1;}
-
-# When interrupted or exit'd, cleanup temporary files, and complete
-# config.log. We remove comments because anyway the quotes in there
-# would cause problems or look ugly.
-# WARNING: Use '\'' to represent an apostrophe within the trap.
-# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
-trap 'exit_status=$?
- # Save into config.log some information that might help in debugging.
- {
- echo
-
- $as_echo "## ---------------- ##
-## Cache variables. ##
-## ---------------- ##"
- echo
- # The following way of writing the cache mishandles newlines in values,
-(
- for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
- eval ac_val=\$$ac_var
- case $ac_val in #(
- *${as_nl}*)
- case $ac_var in #(
- *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
-$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
- esac
- case $ac_var in #(
- _ | IFS | as_nl) ;; #(
- BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
- *) { eval $ac_var=; unset $ac_var;} ;;
- esac ;;
- esac
- done
- (set) 2>&1 |
- case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
- *${as_nl}ac_space=\ *)
- sed -n \
- "s/'\''/'\''\\\\'\'''\''/g;
- s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
- ;; #(
- *)
- sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
- ;;
- esac |
- sort
-)
- echo
-
- $as_echo "## ----------------- ##
-## Output variables. ##
-## ----------------- ##"
- echo
- for ac_var in $ac_subst_vars
- do
- eval ac_val=\$$ac_var
- case $ac_val in
- *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
- esac
- $as_echo "$ac_var='\''$ac_val'\''"
- done | sort
- echo
-
- if test -n "$ac_subst_files"; then
- $as_echo "## ------------------- ##
-## File substitutions. ##
-## ------------------- ##"
- echo
- for ac_var in $ac_subst_files
- do
- eval ac_val=\$$ac_var
- case $ac_val in
- *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
- esac
- $as_echo "$ac_var='\''$ac_val'\''"
- done | sort
- echo
- fi
-
- if test -s confdefs.h; then
- $as_echo "## ----------- ##
-## confdefs.h. ##
-## ----------- ##"
- echo
- cat confdefs.h
- echo
- fi
- test "$ac_signal" != 0 &&
- $as_echo "$as_me: caught signal $ac_signal"
- $as_echo "$as_me: exit $exit_status"
- } >&5
- rm -f core *.core core.conftest.* &&
- rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
- exit $exit_status
-' 0
-for ac_signal in 1 2 13 15; do
- trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
-done
-ac_signal=0
-
-# confdefs.h avoids OS command line length limits that DEFS can exceed.
-rm -f -r conftest* confdefs.h
-
-$as_echo "/* confdefs.h */" > confdefs.h
-
-# Predefined preprocessor variables.
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_NAME "$PACKAGE_NAME"
-_ACEOF
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
-_ACEOF
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_VERSION "$PACKAGE_VERSION"
-_ACEOF
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_STRING "$PACKAGE_STRING"
-_ACEOF
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
-_ACEOF
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_URL "$PACKAGE_URL"
-_ACEOF
-
-
-# Let the site file select an alternate cache file if it wants to.
-# Prefer an explicitly selected file to automatically selected ones.
-ac_site_file1=NONE
-ac_site_file2=NONE
-if test -n "$CONFIG_SITE"; then
- # We do not want a PATH search for config.site.
- case $CONFIG_SITE in #((
- -*) ac_site_file1=./$CONFIG_SITE;;
- */*) ac_site_file1=$CONFIG_SITE;;
- *) ac_site_file1=./$CONFIG_SITE;;
- esac
-elif test "x$prefix" != xNONE; then
- ac_site_file1=$prefix/share/config.site
- ac_site_file2=$prefix/etc/config.site
-else
- ac_site_file1=$ac_default_prefix/share/config.site
- ac_site_file2=$ac_default_prefix/etc/config.site
-fi
-for ac_site_file in "$ac_site_file1" "$ac_site_file2"
-do
- test "x$ac_site_file" = xNONE && continue
- if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
-$as_echo "$as_me: loading site script $ac_site_file" >&6;}
- sed 's/^/| /' "$ac_site_file" >&5
- . "$ac_site_file" \
- || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "failed to load site script $ac_site_file
-See \`config.log' for more details" "$LINENO" 5; }
- fi
-done
-
-if test -r "$cache_file"; then
- # Some versions of bash will fail to source /dev/null (special files
- # actually), so we avoid doing that. DJGPP emulates it as a regular file.
- if test /dev/null != "$cache_file" && test -f "$cache_file"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
-$as_echo "$as_me: loading cache $cache_file" >&6;}
- case $cache_file in
- [\\/]* | ?:[\\/]* ) . "$cache_file";;
- *) . "./$cache_file";;
- esac
- fi
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
-$as_echo "$as_me: creating cache $cache_file" >&6;}
- >$cache_file
-fi
-
-gt_needs="$gt_needs "
-as_fn_append ac_header_list " stdlib.h"
-as_fn_append ac_header_list " unistd.h"
-as_fn_append ac_header_list " sys/param.h"
-# Check that the precious variables saved in the cache have kept the same
-# value.
-ac_cache_corrupted=false
-for ac_var in $ac_precious_vars; do
- eval ac_old_set=\$ac_cv_env_${ac_var}_set
- eval ac_new_set=\$ac_env_${ac_var}_set
- eval ac_old_val=\$ac_cv_env_${ac_var}_value
- eval ac_new_val=\$ac_env_${ac_var}_value
- case $ac_old_set,$ac_new_set in
- set,)
- { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
-$as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
- ac_cache_corrupted=: ;;
- ,set)
- { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
-$as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
- ac_cache_corrupted=: ;;
- ,);;
- *)
- if test "x$ac_old_val" != "x$ac_new_val"; then
- # differences in whitespace do not lead to failure.
- ac_old_val_w=`echo x $ac_old_val`
- ac_new_val_w=`echo x $ac_new_val`
- if test "$ac_old_val_w" != "$ac_new_val_w"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
-$as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
- ac_cache_corrupted=:
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
-$as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
- eval $ac_var=\$ac_old_val
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
-$as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
-$as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
- fi;;
- esac
- # Pass precious variables to config.status.
- if test "$ac_new_set" = set; then
- case $ac_new_val in
- *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
- *) ac_arg=$ac_var=$ac_new_val ;;
- esac
- case " $ac_configure_args " in
- *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
- *) as_fn_append ac_configure_args " '$ac_arg'" ;;
- esac
- fi
-done
-if $ac_cache_corrupted; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
-$as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
- as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
-fi
-## -------------------- ##
-## Main body of script. ##
-## -------------------- ##
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-
-
-
-
-
-
-ac_aux_dir=
-for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
- if test -f "$ac_dir/install-sh"; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install-sh -c"
- break
- elif test -f "$ac_dir/install.sh"; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install.sh -c"
- break
- elif test -f "$ac_dir/shtool"; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/shtool install -c"
- break
- fi
-done
-if test -z "$ac_aux_dir"; then
- as_fn_error $? "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5
-fi
-
-# These three variables are undocumented and unsupported,
-# and are intended to be withdrawn in a future Autoconf release.
-# They can cause serious problems if a builder's source tree is in a directory
-# whose full name contains unusual characters.
-ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
-ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
-ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
-
-
-# Make sure we can run config.sub.
-$SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
- as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
-$as_echo_n "checking build system type... " >&6; }
-if ${ac_cv_build+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_build_alias=$build_alias
-test "x$ac_build_alias" = x &&
- ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
-test "x$ac_build_alias" = x &&
- as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
-ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
- as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
-$as_echo "$ac_cv_build" >&6; }
-case $ac_cv_build in
-*-*-*) ;;
-*) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
-esac
-build=$ac_cv_build
-ac_save_IFS=$IFS; IFS='-'
-set x $ac_cv_build
-shift
-build_cpu=$1
-build_vendor=$2
-shift; shift
-# Remember, the first character of IFS is used to create $*,
-# except with old shells:
-build_os=$*
-IFS=$ac_save_IFS
-case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
-$as_echo_n "checking host system type... " >&6; }
-if ${ac_cv_host+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test "x$host_alias" = x; then
- ac_cv_host=$ac_cv_build
-else
- ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
- as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
-$as_echo "$ac_cv_host" >&6; }
-case $ac_cv_host in
-*-*-*) ;;
-*) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
-esac
-host=$ac_cv_host
-ac_save_IFS=$IFS; IFS='-'
-set x $ac_cv_host
-shift
-host_cpu=$1
-host_vendor=$2
-shift; shift
-# Remember, the first character of IFS is used to create $*,
-# except with old shells:
-host_os=$*
-IFS=$ac_save_IFS
-case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking target system type" >&5
-$as_echo_n "checking target system type... " >&6; }
-if ${ac_cv_target+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test "x$target_alias" = x; then
- ac_cv_target=$ac_cv_host
-else
- ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` ||
- as_fn_error $? "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5
-$as_echo "$ac_cv_target" >&6; }
-case $ac_cv_target in
-*-*-*) ;;
-*) as_fn_error $? "invalid value of canonical target" "$LINENO" 5;;
-esac
-target=$ac_cv_target
-ac_save_IFS=$IFS; IFS='-'
-set x $ac_cv_target
-shift
-target_cpu=$1
-target_vendor=$2
-shift; shift
-# Remember, the first character of IFS is used to create $*,
-# except with old shells:
-target_os=$*
-IFS=$ac_save_IFS
-case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac
-
-
-# The aliases save the names the user supplied, while $host etc.
-# will get canonicalized.
-test -n "$target_alias" &&
- test "$program_prefix$program_suffix$program_transform_name" = \
- NONENONEs,x,x, &&
- program_prefix=${target_alias}-
-
-
-am__api_version='1.15'
-
-# Find a good install program. We prefer a C program (faster),
-# so one script is as good as another. But avoid the broken or
-# incompatible versions:
-# SysV /etc/install, /usr/sbin/install
-# SunOS /usr/etc/install
-# IRIX /sbin/install
-# AIX /bin/install
-# AmigaOS /C/install, which installs bootblocks on floppy discs
-# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
-# AFS /usr/afsws/bin/install, which mishandles nonexistent args
-# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
-# OS/2's system install, which has a completely different semantic
-# ./install, which can be erroneously created by make from ./install.sh.
-# Reject install programs that cannot install multiple files.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
-$as_echo_n "checking for a BSD-compatible install... " >&6; }
-if test -z "$INSTALL"; then
-if ${ac_cv_path_install+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- # Account for people who put trailing slashes in PATH elements.
-case $as_dir/ in #((
- ./ | .// | /[cC]/* | \
- /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
- ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
- /usr/ucb/* ) ;;
- *)
- # OSF1 and SCO ODT 3.0 have their own names for install.
- # Don't use installbsd from OSF since it installs stuff as root
- # by default.
- for ac_prog in ginstall scoinst install; do
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
- if test $ac_prog = install &&
- grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
- # AIX install. It has an incompatible calling convention.
- :
- elif test $ac_prog = install &&
- grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
- # program-specific install script used by HP pwplus--don't use.
- :
- else
- rm -rf conftest.one conftest.two conftest.dir
- echo one > conftest.one
- echo two > conftest.two
- mkdir conftest.dir
- if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
- test -s conftest.one && test -s conftest.two &&
- test -s conftest.dir/conftest.one &&
- test -s conftest.dir/conftest.two
- then
- ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
- break 3
- fi
- fi
- fi
- done
- done
- ;;
-esac
-
- done
-IFS=$as_save_IFS
-
-rm -rf conftest.one conftest.two conftest.dir
-
-fi
- if test "${ac_cv_path_install+set}" = set; then
- INSTALL=$ac_cv_path_install
- else
- # As a last resort, use the slow shell script. Don't cache a
- # value for INSTALL within a source directory, because that will
- # break other packages using the cache if that directory is
- # removed, or if the value is a relative name.
- INSTALL=$ac_install_sh
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
-$as_echo "$INSTALL" >&6; }
-
-# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
-# It thinks the first close brace ends the variable substitution.
-test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
-
-test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
-
-test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5
-$as_echo_n "checking whether build environment is sane... " >&6; }
-# Reject unsafe characters in $srcdir or the absolute working directory
-# name. Accept space and tab only in the latter.
-am_lf='
-'
-case `pwd` in
- *[\\\"\#\$\&\'\`$am_lf]*)
- as_fn_error $? "unsafe absolute working directory name" "$LINENO" 5;;
-esac
-case $srcdir in
- *[\\\"\#\$\&\'\`$am_lf\ \ ]*)
- as_fn_error $? "unsafe srcdir value: '$srcdir'" "$LINENO" 5;;
-esac
-
-# Do 'set' in a subshell so we don't clobber the current shell's
-# arguments. Must try -L first in case configure is actually a
-# symlink; some systems play weird games with the mod time of symlinks
-# (eg FreeBSD returns the mod time of the symlink's containing
-# directory).
-if (
- am_has_slept=no
- for am_try in 1 2; do
- echo "timestamp, slept: $am_has_slept" > conftest.file
- set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
- if test "$*" = "X"; then
- # -L didn't work.
- set X `ls -t "$srcdir/configure" conftest.file`
- fi
- if test "$*" != "X $srcdir/configure conftest.file" \
- && test "$*" != "X conftest.file $srcdir/configure"; then
-
- # If neither matched, then we have a broken ls. This can happen
- # if, for instance, CONFIG_SHELL is bash and it inherits a
- # broken ls alias from the environment. This has actually
- # happened. Such a system could not be considered "sane".
- as_fn_error $? "ls -t appears to fail. Make sure there is not a broken
- alias in your environment" "$LINENO" 5
- fi
- if test "$2" = conftest.file || test $am_try -eq 2; then
- break
- fi
- # Just in case.
- sleep 1
- am_has_slept=yes
- done
- test "$2" = conftest.file
- )
-then
- # Ok.
- :
-else
- as_fn_error $? "newly created file is older than distributed files!
-Check your system clock" "$LINENO" 5
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-# If we didn't sleep, we still need to ensure time stamps of config.status and
-# generated files are strictly newer.
-am_sleep_pid=
-if grep 'slept: no' conftest.file >/dev/null 2>&1; then
- ( sleep 1 ) &
- am_sleep_pid=$!
-fi
-
-rm -f conftest.file
-
-test "$program_prefix" != NONE &&
- program_transform_name="s&^&$program_prefix&;$program_transform_name"
-# Use a double $ so make ignores it.
-test "$program_suffix" != NONE &&
- program_transform_name="s&\$&$program_suffix&;$program_transform_name"
-# Double any \ or $.
-# By default was `s,x,x', remove it if useless.
-ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
-program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
-
-# Expand $ac_aux_dir to an absolute path.
-am_aux_dir=`cd "$ac_aux_dir" && pwd`
-
-if test x"${MISSING+set}" != xset; then
- case $am_aux_dir in
- *\ * | *\ *)
- MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
- *)
- MISSING="\${SHELL} $am_aux_dir/missing" ;;
- esac
-fi
-# Use eval to expand $SHELL
-if eval "$MISSING --is-lightweight"; then
- am_missing_run="$MISSING "
-else
- am_missing_run=
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: 'missing' script is too old or missing" >&5
-$as_echo "$as_me: WARNING: 'missing' script is too old or missing" >&2;}
-fi
-
-if test x"${install_sh+set}" != xset; then
- case $am_aux_dir in
- *\ * | *\ *)
- install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
- *)
- install_sh="\${SHELL} $am_aux_dir/install-sh"
- esac
-fi
-
-# Installed binaries are usually stripped using 'strip' when the user
-# run "make install-strip". However 'strip' might not be the right
-# tool to use in cross-compilation environments, therefore Automake
-# will honor the 'STRIP' environment variable to overrule this program.
-if test "$cross_compiling" != no; then
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
-set dummy ${ac_tool_prefix}strip; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_STRIP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$STRIP"; then
- ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_STRIP="${ac_tool_prefix}strip"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-STRIP=$ac_cv_prog_STRIP
-if test -n "$STRIP"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
-$as_echo "$STRIP" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_STRIP"; then
- ac_ct_STRIP=$STRIP
- # Extract the first word of "strip", so it can be a program name with args.
-set dummy strip; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_STRIP"; then
- ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_STRIP="strip"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
-if test -n "$ac_ct_STRIP"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
-$as_echo "$ac_ct_STRIP" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_STRIP" = x; then
- STRIP=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- STRIP=$ac_ct_STRIP
- fi
-else
- STRIP="$ac_cv_prog_STRIP"
-fi
-
-fi
-INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5
-$as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
-if test -z "$MKDIR_P"; then
- if ${ac_cv_path_mkdir+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_prog in mkdir gmkdir; do
- for ac_exec_ext in '' $ac_executable_extensions; do
- as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext" || continue
- case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
- 'mkdir (GNU coreutils) '* | \
- 'mkdir (coreutils) '* | \
- 'mkdir (fileutils) '4.1*)
- ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
- break 3;;
- esac
- done
- done
- done
-IFS=$as_save_IFS
-
-fi
-
- test -d ./--version && rmdir ./--version
- if test "${ac_cv_path_mkdir+set}" = set; then
- MKDIR_P="$ac_cv_path_mkdir -p"
- else
- # As a last resort, use the slow shell script. Don't cache a
- # value for MKDIR_P within a source directory, because that will
- # break other packages using the cache if that directory is
- # removed, or if the value is a relative name.
- MKDIR_P="$ac_install_sh -d"
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
-$as_echo "$MKDIR_P" >&6; }
-
-for ac_prog in gawk mawk nawk awk
-do
- # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_AWK+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$AWK"; then
- ac_cv_prog_AWK="$AWK" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_AWK="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-AWK=$ac_cv_prog_AWK
-if test -n "$AWK"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
-$as_echo "$AWK" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$AWK" && break
-done
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
-$as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
-set x ${MAKE-make}
-ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
-if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat >conftest.make <<\_ACEOF
-SHELL = /bin/sh
-all:
- @echo '@@@%%%=$(MAKE)=@@@%%%'
-_ACEOF
-# GNU make sometimes prints "make[1]: Entering ...", which would confuse us.
-case `${MAKE-make} -f conftest.make 2>/dev/null` in
- *@@@%%%=?*=@@@%%%*)
- eval ac_cv_prog_make_${ac_make}_set=yes;;
- *)
- eval ac_cv_prog_make_${ac_make}_set=no;;
-esac
-rm -f conftest.make
-fi
-if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- SET_MAKE=
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- SET_MAKE="MAKE=${MAKE-make}"
-fi
-
-rm -rf .tst 2>/dev/null
-mkdir .tst 2>/dev/null
-if test -d .tst; then
- am__leading_dot=.
-else
- am__leading_dot=_
-fi
-rmdir .tst 2>/dev/null
-
-# Check whether --enable-silent-rules was given.
-if test "${enable_silent_rules+set}" = set; then :
- enableval=$enable_silent_rules;
-fi
-
-case $enable_silent_rules in # (((
- yes) AM_DEFAULT_VERBOSITY=0;;
- no) AM_DEFAULT_VERBOSITY=1;;
- *) AM_DEFAULT_VERBOSITY=1;;
-esac
-am_make=${MAKE-make}
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5
-$as_echo_n "checking whether $am_make supports nested variables... " >&6; }
-if ${am_cv_make_support_nested_variables+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if $as_echo 'TRUE=$(BAR$(V))
-BAR0=false
-BAR1=true
-V=1
-am__doit:
- @$(TRUE)
-.PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then
- am_cv_make_support_nested_variables=yes
-else
- am_cv_make_support_nested_variables=no
-fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5
-$as_echo "$am_cv_make_support_nested_variables" >&6; }
-if test $am_cv_make_support_nested_variables = yes; then
- AM_V='$(V)'
- AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
-else
- AM_V=$AM_DEFAULT_VERBOSITY
- AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY
-fi
-AM_BACKSLASH='\'
-
-if test "`cd $srcdir && pwd`" != "`pwd`"; then
- # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
- # is not polluted with repeated "-I."
- am__isrc=' -I$(srcdir)'
- # test to see if srcdir already configured
- if test -f $srcdir/config.status; then
- as_fn_error $? "source directory already configured; run \"make distclean\" there first" "$LINENO" 5
- fi
-fi
-
-# test whether we have cygpath
-if test -z "$CYGPATH_W"; then
- if (cygpath --version) >/dev/null 2>/dev/null; then
- CYGPATH_W='cygpath -w'
- else
- CYGPATH_W=echo
- fi
-fi
-
-
-# Define the identity of the package.
- PACKAGE='ld'
- VERSION='2.43.1'
-
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE "$PACKAGE"
-_ACEOF
-
-
-cat >>confdefs.h <<_ACEOF
-#define VERSION "$VERSION"
-_ACEOF
-
-# Some tools Automake needs.
-
-ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"}
-
-
-AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
-
-
-AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"}
-
-
-AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
-
-
-MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
-
-# For better backward compatibility. To be removed once Automake 1.9.x
-# dies out for good. For more background, see:
-# <http://lists.gnu.org/archive/html/automake/2012-07/msg00001.html>
-# <http://lists.gnu.org/archive/html/automake/2012-07/msg00014.html>
-mkdir_p='$(MKDIR_P)'
-
-# We need awk for the "check" target (and possibly the TAP driver). The
-# system "awk" is bad on some platforms.
-# Always define AMTAR for backward compatibility. Yes, it's still used
-# in the wild :-( We should find a proper way to deprecate it ...
-AMTAR='$${TAR-tar}'
-
-
-# We'll loop over all known methods to create a tar archive until one works.
-_am_tools='gnutar pax cpio none'
-
-am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -'
-
-
-
-
-
-
-# POSIX will say in a future version that running "rm -f" with no argument
-# is OK; and we want to be able to make that assumption in our Makefile
-# recipes. So use an aggressive probe to check that the usage we want is
-# actually supported "in the wild" to an acceptable degree.
-# See automake bug#10828.
-# To make any issue more visible, cause the running configure to be aborted
-# by default if the 'rm' program in use doesn't match our expectations; the
-# user can still override this though.
-if rm -f && rm -fr && rm -rf; then : OK; else
- cat >&2 <<'END'
-Oops!
-
-Your 'rm' program seems unable to run without file operands specified
-on the command line, even when the '-f' option is present. This is contrary
-to the behaviour of most rm programs out there, and not conforming with
-the upcoming POSIX standard: <http://austingroupbugs.net/view.php?id=542>
-
-Please tell bug-automake@gnu.org about your system, including the value
-of your $PATH and any error possibly output before this message. This
-can help us improve future automake versions.
-
-END
- if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then
- echo 'Configuration will proceed anyway, since you have set the' >&2
- echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2
- echo >&2
- else
- cat >&2 <<'END'
-Aborting the configuration process, to ensure you take notice of the issue.
-
-You can download and install GNU coreutils to get an 'rm' implementation
-that behaves properly: <http://www.gnu.org/software/coreutils/>.
-
-If you want to complete the configuration process using your problematic
-'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM
-to "yes", and re-run configure.
-
-END
- as_fn_error $? "Your 'rm' program is bad, sorry." "$LINENO" 5
- fi
-fi
-
-# Check whether --enable-silent-rules was given.
-if test "${enable_silent_rules+set}" = set; then :
- enableval=$enable_silent_rules;
-fi
-
-case $enable_silent_rules in # (((
- yes) AM_DEFAULT_VERBOSITY=0;;
- no) AM_DEFAULT_VERBOSITY=1;;
- *) AM_DEFAULT_VERBOSITY=0;;
-esac
-am_make=${MAKE-make}
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5
-$as_echo_n "checking whether $am_make supports nested variables... " >&6; }
-if ${am_cv_make_support_nested_variables+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if $as_echo 'TRUE=$(BAR$(V))
-BAR0=false
-BAR1=true
-V=1
-am__doit:
- @$(TRUE)
-.PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then
- am_cv_make_support_nested_variables=yes
-else
- am_cv_make_support_nested_variables=no
-fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5
-$as_echo "$am_cv_make_support_nested_variables" >&6; }
-if test $am_cv_make_support_nested_variables = yes; then
- AM_V='$(V)'
- AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
-else
- AM_V=$AM_DEFAULT_VERBOSITY
- AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY
-fi
-AM_BACKSLASH='\'
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable maintainer-specific portions of Makefiles" >&5
-$as_echo_n "checking whether to enable maintainer-specific portions of Makefiles... " >&6; }
- # Check whether --enable-maintainer-mode was given.
-if test "${enable_maintainer_mode+set}" = set; then :
- enableval=$enable_maintainer_mode; USE_MAINTAINER_MODE=$enableval
-else
- USE_MAINTAINER_MODE=no
-fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_MAINTAINER_MODE" >&5
-$as_echo "$USE_MAINTAINER_MODE" >&6; }
- if test $USE_MAINTAINER_MODE = yes; then
- MAINTAINER_MODE_TRUE=
- MAINTAINER_MODE_FALSE='#'
-else
- MAINTAINER_MODE_TRUE='#'
- MAINTAINER_MODE_FALSE=
-fi
-
- MAINT=$MAINTAINER_MODE_TRUE
-
-
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
-set dummy ${ac_tool_prefix}gcc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_CC="${ac_tool_prefix}gcc"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
-$as_echo "$CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_CC"; then
- ac_ct_CC=$CC
- # Extract the first word of "gcc", so it can be a program name with args.
-set dummy gcc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_CC"; then
- ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_CC="gcc"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_CC=$ac_cv_prog_ac_ct_CC
-if test -n "$ac_ct_CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
-$as_echo "$ac_ct_CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_CC" = x; then
- CC=""
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- CC=$ac_ct_CC
- fi
-else
- CC="$ac_cv_prog_CC"
-fi
-
-if test -z "$CC"; then
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
-set dummy ${ac_tool_prefix}cc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_CC="${ac_tool_prefix}cc"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
-$as_echo "$CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
-fi
-if test -z "$CC"; then
- # Extract the first word of "cc", so it can be a program name with args.
-set dummy cc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
- ac_prog_rejected=no
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
- ac_prog_rejected=yes
- continue
- fi
- ac_cv_prog_CC="cc"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-if test $ac_prog_rejected = yes; then
- # We found a bogon in the path, so make sure we never use it.
- set dummy $ac_cv_prog_CC
- shift
- if test $# != 0; then
- # We chose a different compiler from the bogus one.
- # However, it has the same basename, so the bogon will be chosen
- # first if we set CC to just the basename; use the full file name.
- shift
- ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
- fi
-fi
-fi
-fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
-$as_echo "$CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$CC"; then
- if test -n "$ac_tool_prefix"; then
- for ac_prog in cl.exe
- do
- # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
-set dummy $ac_tool_prefix$ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
-$as_echo "$CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$CC" && break
- done
-fi
-if test -z "$CC"; then
- ac_ct_CC=$CC
- for ac_prog in cl.exe
-do
- # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_CC"; then
- ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_CC="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_CC=$ac_cv_prog_ac_ct_CC
-if test -n "$ac_ct_CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
-$as_echo "$ac_ct_CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$ac_ct_CC" && break
-done
-
- if test "x$ac_ct_CC" = x; then
- CC=""
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- CC=$ac_ct_CC
- fi
-fi
-
-fi
-
-
-test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "no acceptable C compiler found in \$PATH
-See \`config.log' for more details" "$LINENO" 5; }
-
-# Provide some information about the compiler.
-$as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
-set X $ac_compile
-ac_compiler=$2
-for ac_option in --version -v -V -qversion; do
- { { ac_try="$ac_compiler $ac_option >&5"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_compiler $ac_option >&5") 2>conftest.err
- ac_status=$?
- if test -s conftest.err; then
- sed '10a\
-... rest of stderr output deleted ...
- 10q' conftest.err >conftest.er1
- cat conftest.er1 >&5
- fi
- rm -f conftest.er1 conftest.err
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }
-done
-
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-ac_clean_files_save=$ac_clean_files
-ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
-# Try to create an executable without -o first, disregard a.out.
-# It will help us diagnose broken compilers, and finding out an intuition
-# of exeext.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
-$as_echo_n "checking whether the C compiler works... " >&6; }
-ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
-
-# The possible output files:
-ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
-
-ac_rmfiles=
-for ac_file in $ac_files
-do
- case $ac_file in
- *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
- * ) ac_rmfiles="$ac_rmfiles $ac_file";;
- esac
-done
-rm -f $ac_rmfiles
-
-if { { ac_try="$ac_link_default"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_link_default") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then :
- # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
-# So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
-# in a Makefile. We should not override ac_cv_exeext if it was cached,
-# so that the user can short-circuit this test for compilers unknown to
-# Autoconf.
-for ac_file in $ac_files ''
-do
- test -f "$ac_file" || continue
- case $ac_file in
- *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
- ;;
- [ab].out )
- # We found the default executable, but exeext='' is most
- # certainly right.
- break;;
- *.* )
- if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
- then :; else
- ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
- fi
- # We set ac_cv_exeext here because the later test for it is not
- # safe: cross compilers may not add the suffix if given an `-o'
- # argument, so we may need to know it at that point already.
- # Even if this section looks crufty: it has the advantage of
- # actually working.
- break;;
- * )
- break;;
- esac
-done
-test "$ac_cv_exeext" = no && ac_cv_exeext=
-
-else
- ac_file=''
-fi
-if test -z "$ac_file"; then :
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-$as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error 77 "C compiler cannot create executables
-See \`config.log' for more details" "$LINENO" 5; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
-$as_echo_n "checking for C compiler default output file name... " >&6; }
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
-$as_echo "$ac_file" >&6; }
-ac_exeext=$ac_cv_exeext
-
-rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
-ac_clean_files=$ac_clean_files_save
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
-$as_echo_n "checking for suffix of executables... " >&6; }
-if { { ac_try="$ac_link"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_link") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then :
- # If both `conftest.exe' and `conftest' are `present' (well, observable)
-# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
-# work properly (i.e., refer to `conftest.exe'), while it won't with
-# `rm'.
-for ac_file in conftest.exe conftest conftest.*; do
- test -f "$ac_file" || continue
- case $ac_file in
- *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
- *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
- break;;
- * ) break;;
- esac
-done
-else
- { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "cannot compute suffix of executables: cannot compile and link
-See \`config.log' for more details" "$LINENO" 5; }
-fi
-rm -f conftest conftest$ac_cv_exeext
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
-$as_echo "$ac_cv_exeext" >&6; }
-
-rm -f conftest.$ac_ext
-EXEEXT=$ac_cv_exeext
-ac_exeext=$EXEEXT
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <stdio.h>
-int
-main ()
-{
-FILE *f = fopen ("conftest.out", "w");
- return ferror (f) || fclose (f) != 0;
-
- ;
- return 0;
-}
-_ACEOF
-ac_clean_files="$ac_clean_files conftest.out"
-# Check that the compiler produces executables we can run. If not, either
-# the compiler is broken, or we cross compile.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
-$as_echo_n "checking whether we are cross compiling... " >&6; }
-if test "$cross_compiling" != yes; then
- { { ac_try="$ac_link"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_link") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }
- if { ac_try='./conftest$ac_cv_exeext'
- { { case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_try") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; }; then
- cross_compiling=no
- else
- if test "$cross_compiling" = maybe; then
- cross_compiling=yes
- else
- { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "cannot run C compiled programs.
-If you meant to cross compile, use \`--host'.
-See \`config.log' for more details" "$LINENO" 5; }
- fi
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
-$as_echo "$cross_compiling" >&6; }
-
-rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
-ac_clean_files=$ac_clean_files_save
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
-$as_echo_n "checking for suffix of object files... " >&6; }
-if ${ac_cv_objext+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-rm -f conftest.o conftest.obj
-if { { ac_try="$ac_compile"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_compile") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then :
- for ac_file in conftest.o conftest.obj conftest.*; do
- test -f "$ac_file" || continue;
- case $ac_file in
- *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
- *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
- break;;
- esac
-done
-else
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "cannot compute suffix of object files: cannot compile
-See \`config.log' for more details" "$LINENO" 5; }
-fi
-rm -f conftest.$ac_cv_objext conftest.$ac_ext
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
-$as_echo "$ac_cv_objext" >&6; }
-OBJEXT=$ac_cv_objext
-ac_objext=$OBJEXT
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
-$as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
-if ${ac_cv_c_compiler_gnu+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-#ifndef __GNUC__
- choke me
-#endif
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_compiler_gnu=yes
-else
- ac_compiler_gnu=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-ac_cv_c_compiler_gnu=$ac_compiler_gnu
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
-$as_echo "$ac_cv_c_compiler_gnu" >&6; }
-if test $ac_compiler_gnu = yes; then
- GCC=yes
-else
- GCC=
-fi
-ac_test_CFLAGS=${CFLAGS+set}
-ac_save_CFLAGS=$CFLAGS
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
-$as_echo_n "checking whether $CC accepts -g... " >&6; }
-if ${ac_cv_prog_cc_g+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_save_c_werror_flag=$ac_c_werror_flag
- ac_c_werror_flag=yes
- ac_cv_prog_cc_g=no
- CFLAGS="-g"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_prog_cc_g=yes
-else
- CFLAGS=""
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
-
-else
- ac_c_werror_flag=$ac_save_c_werror_flag
- CFLAGS="-g"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_prog_cc_g=yes
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- ac_c_werror_flag=$ac_save_c_werror_flag
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
-$as_echo "$ac_cv_prog_cc_g" >&6; }
-if test "$ac_test_CFLAGS" = set; then
- CFLAGS=$ac_save_CFLAGS
-elif test $ac_cv_prog_cc_g = yes; then
- if test "$GCC" = yes; then
- CFLAGS="-g -O2"
- else
- CFLAGS="-g"
- fi
-else
- if test "$GCC" = yes; then
- CFLAGS="-O2"
- else
- CFLAGS=
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
-$as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
-if ${ac_cv_prog_cc_c89+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_cv_prog_cc_c89=no
-ac_save_CC=$CC
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <stdarg.h>
-#include <stdio.h>
-struct stat;
-/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
-struct buf { int x; };
-FILE * (*rcsopen) (struct buf *, struct stat *, int);
-static char *e (p, i)
- char **p;
- int i;
-{
- return p[i];
-}
-static char *f (char * (*g) (char **, int), char **p, ...)
-{
- char *s;
- va_list v;
- va_start (v,p);
- s = g (p, va_arg (v,int));
- va_end (v);
- return s;
-}
-
-/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
- function prototypes and stuff, but not '\xHH' hex character constants.
- These don't provoke an error unfortunately, instead are silently treated
- as 'x'. The following induces an error, until -std is added to get
- proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
- array size at least. It's necessary to write '\x00'==0 to get something
- that's true only with -std. */
-int osf4_cc_array ['\x00' == 0 ? 1 : -1];
-
-/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
- inside strings and character constants. */
-#define FOO(x) 'x'
-int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
-
-int test (int i, double x);
-struct s1 {int (*f) (int a);};
-struct s2 {int (*f) (double a);};
-int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
-int argc;
-char **argv;
-int
-main ()
-{
-return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
- ;
- return 0;
-}
-_ACEOF
-for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
- -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
-do
- CC="$ac_save_CC $ac_arg"
- if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_prog_cc_c89=$ac_arg
-fi
-rm -f core conftest.err conftest.$ac_objext
- test "x$ac_cv_prog_cc_c89" != "xno" && break
-done
-rm -f conftest.$ac_ext
-CC=$ac_save_CC
-
-fi
-# AC_CACHE_VAL
-case "x$ac_cv_prog_cc_c89" in
- x)
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
-$as_echo "none needed" >&6; } ;;
- xno)
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
-$as_echo "unsupported" >&6; } ;;
- *)
- CC="$CC $ac_cv_prog_cc_c89"
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
-$as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
-esac
-if test "x$ac_cv_prog_cc_c89" != xno; then :
-
-fi
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC understands -c and -o together" >&5
-$as_echo_n "checking whether $CC understands -c and -o together... " >&6; }
-if ${am_cv_prog_cc_c_o+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
- # Make sure it works both with $CC and with simple cc.
- # Following AC_PROG_CC_C_O, we do the test twice because some
- # compilers refuse to overwrite an existing .o file with -o,
- # though they will create one.
- am_cv_prog_cc_c_o=yes
- for am_i in 1 2; do
- if { echo "$as_me:$LINENO: $CC -c conftest.$ac_ext -o conftest2.$ac_objext" >&5
- ($CC -c conftest.$ac_ext -o conftest2.$ac_objext) >&5 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } \
- && test -f conftest2.$ac_objext; then
- : OK
- else
- am_cv_prog_cc_c_o=no
- break
- fi
- done
- rm -f core conftest*
- unset am_i
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_cc_c_o" >&5
-$as_echo "$am_cv_prog_cc_c_o" >&6; }
-if test "$am_cv_prog_cc_c_o" != yes; then
- # Losing compiler, so override with the script.
- # FIXME: It is wrong to rewrite CC.
- # But if we don't then we get into trouble of one sort or another.
- # A longer-term fix would be to have automake use am__CC in this case,
- # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
- CC="$am_aux_dir/compile $CC"
-fi
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-DEPDIR="${am__leading_dot}deps"
-
-ac_config_commands="$ac_config_commands depfiles"
-
-
-am_make=${MAKE-make}
-cat > confinc << 'END'
-am__doit:
- @echo this is the am__doit target
-.PHONY: am__doit
-END
-# If we don't find an include directive, just comment out the code.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5
-$as_echo_n "checking for style of include used by $am_make... " >&6; }
-am__include="#"
-am__quote=
-_am_result=none
-# First try GNU make style include.
-echo "include confinc" > confmf
-# Ignore all kinds of additional output from 'make'.
-case `$am_make -s -f confmf 2> /dev/null` in #(
-*the\ am__doit\ target*)
- am__include=include
- am__quote=
- _am_result=GNU
- ;;
-esac
-# Now try BSD make style include.
-if test "$am__include" = "#"; then
- echo '.include "confinc"' > confmf
- case `$am_make -s -f confmf 2> /dev/null` in #(
- *the\ am__doit\ target*)
- am__include=.include
- am__quote="\""
- _am_result=BSD
- ;;
- esac
-fi
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5
-$as_echo "$_am_result" >&6; }
-rm -f confinc confmf
-
-# Check whether --enable-dependency-tracking was given.
-if test "${enable_dependency_tracking+set}" = set; then :
- enableval=$enable_dependency_tracking;
-fi
-
-if test "x$enable_dependency_tracking" != xno; then
- am_depcomp="$ac_aux_dir/depcomp"
- AMDEPBACKSLASH='\'
- am__nodep='_no'
-fi
- if test "x$enable_dependency_tracking" != xno; then
- AMDEP_TRUE=
- AMDEP_FALSE='#'
-else
- AMDEP_TRUE='#'
- AMDEP_FALSE=
-fi
-
-
-
-depcc="$CC" am_compiler_list=
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
-$as_echo_n "checking dependency style of $depcc... " >&6; }
-if ${am_cv_CC_dependencies_compiler_type+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
- # We make a subdir and do the tests there. Otherwise we can end up
- # making bogus files that we don't know about and never remove. For
- # instance it was reported that on HP-UX the gcc test will end up
- # making a dummy file named 'D' -- because '-MD' means "put the output
- # in D".
- rm -rf conftest.dir
- mkdir conftest.dir
- # Copy depcomp to subdir because otherwise we won't find it if we're
- # using a relative directory.
- cp "$am_depcomp" conftest.dir
- cd conftest.dir
- # We will build objects and dependencies in a subdirectory because
- # it helps to detect inapplicable dependency modes. For instance
- # both Tru64's cc and ICC support -MD to output dependencies as a
- # side effect of compilation, but ICC will put the dependencies in
- # the current directory while Tru64 will put them in the object
- # directory.
- mkdir sub
-
- am_cv_CC_dependencies_compiler_type=none
- if test "$am_compiler_list" = ""; then
- am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
- fi
- am__universal=false
- case " $depcc " in #(
- *\ -arch\ *\ -arch\ *) am__universal=true ;;
- esac
-
- for depmode in $am_compiler_list; do
- # Setup a source with many dependencies, because some compilers
- # like to wrap large dependency lists on column 80 (with \), and
- # we should not choose a depcomp mode which is confused by this.
- #
- # We need to recreate these files for each test, as the compiler may
- # overwrite some of them when testing with obscure command lines.
- # This happens at least with the AIX C compiler.
- : > sub/conftest.c
- for i in 1 2 3 4 5 6; do
- echo '#include "conftst'$i'.h"' >> sub/conftest.c
- # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with
- # Solaris 10 /bin/sh.
- echo '/* dummy */' > sub/conftst$i.h
- done
- echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
-
- # We check with '-c' and '-o' for the sake of the "dashmstdout"
- # mode. It turns out that the SunPro C++ compiler does not properly
- # handle '-M -o', and we need to detect this. Also, some Intel
- # versions had trouble with output in subdirs.
- am__obj=sub/conftest.${OBJEXT-o}
- am__minus_obj="-o $am__obj"
- case $depmode in
- gcc)
- # This depmode causes a compiler race in universal mode.
- test "$am__universal" = false || continue
- ;;
- nosideeffect)
- # After this tag, mechanisms are not by side-effect, so they'll
- # only be used when explicitly requested.
- if test "x$enable_dependency_tracking" = xyes; then
- continue
- else
- break
- fi
- ;;
- msvc7 | msvc7msys | msvisualcpp | msvcmsys)
- # This compiler won't grok '-c -o', but also, the minuso test has
- # not run yet. These depmodes are late enough in the game, and
- # so weak that their functioning should not be impacted.
- am__obj=conftest.${OBJEXT-o}
- am__minus_obj=
- ;;
- none) break ;;
- esac
- if depmode=$depmode \
- source=sub/conftest.c object=$am__obj \
- depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
- $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
- >/dev/null 2>conftest.err &&
- grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
- grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
- grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
- ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
- # icc doesn't choke on unknown options, it will just issue warnings
- # or remarks (even with -Werror). So we grep stderr for any message
- # that says an option was ignored or not supported.
- # When given -MP, icc 7.0 and 7.1 complain thusly:
- # icc: Command line warning: ignoring option '-M'; no argument required
- # The diagnosis changed in icc 8.0:
- # icc: Command line remark: option '-MP' not supported
- if (grep 'ignoring option' conftest.err ||
- grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
- am_cv_CC_dependencies_compiler_type=$depmode
- break
- fi
- fi
- done
-
- cd ..
- rm -rf conftest.dir
-else
- am_cv_CC_dependencies_compiler_type=none
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
-$as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
-CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
-
- if
- test "x$enable_dependency_tracking" != xno \
- && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
- am__fastdepCC_TRUE=
- am__fastdepCC_FALSE='#'
-else
- am__fastdepCC_TRUE='#'
- am__fastdepCC_FALSE=
-fi
-
-
-ac_ext=cpp
-ac_cpp='$CXXCPP $CPPFLAGS'
-ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
-if test -z "$CXX"; then
- if test -n "$CCC"; then
- CXX=$CCC
- else
- if test -n "$ac_tool_prefix"; then
- for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC
- do
- # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
-set dummy $ac_tool_prefix$ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CXX+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$CXX"; then
- ac_cv_prog_CXX="$CXX" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_CXX="$ac_tool_prefix$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-CXX=$ac_cv_prog_CXX
-if test -n "$CXX"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5
-$as_echo "$CXX" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$CXX" && break
- done
-fi
-if test -z "$CXX"; then
- ac_ct_CXX=$CXX
- for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC
-do
- # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_CXX+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_CXX"; then
- ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_CXX="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_CXX=$ac_cv_prog_ac_ct_CXX
-if test -n "$ac_ct_CXX"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5
-$as_echo "$ac_ct_CXX" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$ac_ct_CXX" && break
-done
-
- if test "x$ac_ct_CXX" = x; then
- CXX="g++"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- CXX=$ac_ct_CXX
- fi
-fi
-
- fi
-fi
-# Provide some information about the compiler.
-$as_echo "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5
-set X $ac_compile
-ac_compiler=$2
-for ac_option in --version -v -V -qversion; do
- { { ac_try="$ac_compiler $ac_option >&5"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_compiler $ac_option >&5") 2>conftest.err
- ac_status=$?
- if test -s conftest.err; then
- sed '10a\
-... rest of stderr output deleted ...
- 10q' conftest.err >conftest.er1
- cat conftest.er1 >&5
- fi
- rm -f conftest.er1 conftest.err
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }
-done
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C++ compiler" >&5
-$as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; }
-if ${ac_cv_cxx_compiler_gnu+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-#ifndef __GNUC__
- choke me
-#endif
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_cxx_try_compile "$LINENO"; then :
- ac_compiler_gnu=yes
-else
- ac_compiler_gnu=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-ac_cv_cxx_compiler_gnu=$ac_compiler_gnu
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5
-$as_echo "$ac_cv_cxx_compiler_gnu" >&6; }
-if test $ac_compiler_gnu = yes; then
- GXX=yes
-else
- GXX=
-fi
-ac_test_CXXFLAGS=${CXXFLAGS+set}
-ac_save_CXXFLAGS=$CXXFLAGS
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5
-$as_echo_n "checking whether $CXX accepts -g... " >&6; }
-if ${ac_cv_prog_cxx_g+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_save_cxx_werror_flag=$ac_cxx_werror_flag
- ac_cxx_werror_flag=yes
- ac_cv_prog_cxx_g=no
- CXXFLAGS="-g"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_cxx_try_compile "$LINENO"; then :
- ac_cv_prog_cxx_g=yes
-else
- CXXFLAGS=""
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_cxx_try_compile "$LINENO"; then :
-
-else
- ac_cxx_werror_flag=$ac_save_cxx_werror_flag
- CXXFLAGS="-g"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_cxx_try_compile "$LINENO"; then :
- ac_cv_prog_cxx_g=yes
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- ac_cxx_werror_flag=$ac_save_cxx_werror_flag
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5
-$as_echo "$ac_cv_prog_cxx_g" >&6; }
-if test "$ac_test_CXXFLAGS" = set; then
- CXXFLAGS=$ac_save_CXXFLAGS
-elif test $ac_cv_prog_cxx_g = yes; then
- if test "$GXX" = yes; then
- CXXFLAGS="-g -O2"
- else
- CXXFLAGS="-g"
- fi
-else
- if test "$GXX" = yes; then
- CXXFLAGS="-O2"
- else
- CXXFLAGS=
- fi
-fi
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-depcc="$CXX" am_compiler_list=
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
-$as_echo_n "checking dependency style of $depcc... " >&6; }
-if ${am_cv_CXX_dependencies_compiler_type+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
- # We make a subdir and do the tests there. Otherwise we can end up
- # making bogus files that we don't know about and never remove. For
- # instance it was reported that on HP-UX the gcc test will end up
- # making a dummy file named 'D' -- because '-MD' means "put the output
- # in D".
- rm -rf conftest.dir
- mkdir conftest.dir
- # Copy depcomp to subdir because otherwise we won't find it if we're
- # using a relative directory.
- cp "$am_depcomp" conftest.dir
- cd conftest.dir
- # We will build objects and dependencies in a subdirectory because
- # it helps to detect inapplicable dependency modes. For instance
- # both Tru64's cc and ICC support -MD to output dependencies as a
- # side effect of compilation, but ICC will put the dependencies in
- # the current directory while Tru64 will put them in the object
- # directory.
- mkdir sub
-
- am_cv_CXX_dependencies_compiler_type=none
- if test "$am_compiler_list" = ""; then
- am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
- fi
- am__universal=false
- case " $depcc " in #(
- *\ -arch\ *\ -arch\ *) am__universal=true ;;
- esac
-
- for depmode in $am_compiler_list; do
- # Setup a source with many dependencies, because some compilers
- # like to wrap large dependency lists on column 80 (with \), and
- # we should not choose a depcomp mode which is confused by this.
- #
- # We need to recreate these files for each test, as the compiler may
- # overwrite some of them when testing with obscure command lines.
- # This happens at least with the AIX C compiler.
- : > sub/conftest.c
- for i in 1 2 3 4 5 6; do
- echo '#include "conftst'$i'.h"' >> sub/conftest.c
- # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with
- # Solaris 10 /bin/sh.
- echo '/* dummy */' > sub/conftst$i.h
- done
- echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
-
- # We check with '-c' and '-o' for the sake of the "dashmstdout"
- # mode. It turns out that the SunPro C++ compiler does not properly
- # handle '-M -o', and we need to detect this. Also, some Intel
- # versions had trouble with output in subdirs.
- am__obj=sub/conftest.${OBJEXT-o}
- am__minus_obj="-o $am__obj"
- case $depmode in
- gcc)
- # This depmode causes a compiler race in universal mode.
- test "$am__universal" = false || continue
- ;;
- nosideeffect)
- # After this tag, mechanisms are not by side-effect, so they'll
- # only be used when explicitly requested.
- if test "x$enable_dependency_tracking" = xyes; then
- continue
- else
- break
- fi
- ;;
- msvc7 | msvc7msys | msvisualcpp | msvcmsys)
- # This compiler won't grok '-c -o', but also, the minuso test has
- # not run yet. These depmodes are late enough in the game, and
- # so weak that their functioning should not be impacted.
- am__obj=conftest.${OBJEXT-o}
- am__minus_obj=
- ;;
- none) break ;;
- esac
- if depmode=$depmode \
- source=sub/conftest.c object=$am__obj \
- depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
- $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
- >/dev/null 2>conftest.err &&
- grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
- grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
- grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
- ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
- # icc doesn't choke on unknown options, it will just issue warnings
- # or remarks (even with -Werror). So we grep stderr for any message
- # that says an option was ignored or not supported.
- # When given -MP, icc 7.0 and 7.1 complain thusly:
- # icc: Command line warning: ignoring option '-M'; no argument required
- # The diagnosis changed in icc 8.0:
- # icc: Command line remark: option '-MP' not supported
- if (grep 'ignoring option' conftest.err ||
- grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
- am_cv_CXX_dependencies_compiler_type=$depmode
- break
- fi
- fi
- done
-
- cd ..
- rm -rf conftest.dir
-else
- am_cv_CXX_dependencies_compiler_type=none
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CXX_dependencies_compiler_type" >&5
-$as_echo "$am_cv_CXX_dependencies_compiler_type" >&6; }
-CXXDEPMODE=depmode=$am_cv_CXX_dependencies_compiler_type
-
- if
- test "x$enable_dependency_tracking" != xno \
- && test "$am_cv_CXX_dependencies_compiler_type" = gcc3; then
- am__fastdepCXX_TRUE=
- am__fastdepCXX_FALSE='#'
-else
- am__fastdepCXX_TRUE='#'
- am__fastdepCXX_FALSE=
-fi
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
-$as_echo_n "checking for grep that handles long lines and -e... " >&6; }
-if ${ac_cv_path_GREP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -z "$GREP"; then
- ac_path_GREP_found=false
- # Loop through the user's path and test for each of PROGNAME-LIST
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_prog in grep ggrep; do
- for ac_exec_ext in '' $ac_executable_extensions; do
- ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
- as_fn_executable_p "$ac_path_GREP" || continue
-# Check for GNU ac_path_GREP and select it if it is found.
- # Check for GNU $ac_path_GREP
-case `"$ac_path_GREP" --version 2>&1` in
-*GNU*)
- ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
-*)
- ac_count=0
- $as_echo_n 0123456789 >"conftest.in"
- while :
- do
- cat "conftest.in" "conftest.in" >"conftest.tmp"
- mv "conftest.tmp" "conftest.in"
- cp "conftest.in" "conftest.nl"
- $as_echo 'GREP' >> "conftest.nl"
- "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
- diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
- as_fn_arith $ac_count + 1 && ac_count=$as_val
- if test $ac_count -gt ${ac_path_GREP_max-0}; then
- # Best one so far, save it but keep looking for a better one
- ac_cv_path_GREP="$ac_path_GREP"
- ac_path_GREP_max=$ac_count
- fi
- # 10*(2^10) chars as input seems more than enough
- test $ac_count -gt 10 && break
- done
- rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
-esac
-
- $ac_path_GREP_found && break 3
- done
- done
- done
-IFS=$as_save_IFS
- if test -z "$ac_cv_path_GREP"; then
- as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
- fi
-else
- ac_cv_path_GREP=$GREP
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
-$as_echo "$ac_cv_path_GREP" >&6; }
- GREP="$ac_cv_path_GREP"
-
-
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
-$as_echo_n "checking how to run the C preprocessor... " >&6; }
-# On Suns, sometimes $CPP names a directory.
-if test -n "$CPP" && test -d "$CPP"; then
- CPP=
-fi
-if test -z "$CPP"; then
- if ${ac_cv_prog_CPP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- # Double quotes because CPP needs to be expanded
- for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
- do
- ac_preproc_ok=false
-for ac_c_preproc_warn_flag in '' yes
-do
- # Use a header file that comes with gcc, so configuring glibc
- # with a fresh cross-compiler works.
- # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
- # <limits.h> exists even on freestanding compilers.
- # On the NeXT, cc -E runs the code through the compiler's parser,
- # not just through cpp. "Syntax error" is here to catch this case.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#ifdef __STDC__
-# include <limits.h>
-#else
-# include <assert.h>
-#endif
- Syntax error
-_ACEOF
-if ac_fn_c_try_cpp "$LINENO"; then :
-
-else
- # Broken: fails on valid input.
-continue
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-
- # OK, works on sane cases. Now check whether nonexistent headers
- # can be detected and how.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <ac_nonexistent.h>
-_ACEOF
-if ac_fn_c_try_cpp "$LINENO"; then :
- # Broken: success on invalid input.
-continue
-else
- # Passes both tests.
-ac_preproc_ok=:
-break
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-
-done
-# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
-rm -f conftest.i conftest.err conftest.$ac_ext
-if $ac_preproc_ok; then :
- break
-fi
-
- done
- ac_cv_prog_CPP=$CPP
-
-fi
- CPP=$ac_cv_prog_CPP
-else
- ac_cv_prog_CPP=$CPP
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
-$as_echo "$CPP" >&6; }
-ac_preproc_ok=false
-for ac_c_preproc_warn_flag in '' yes
-do
- # Use a header file that comes with gcc, so configuring glibc
- # with a fresh cross-compiler works.
- # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
- # <limits.h> exists even on freestanding compilers.
- # On the NeXT, cc -E runs the code through the compiler's parser,
- # not just through cpp. "Syntax error" is here to catch this case.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#ifdef __STDC__
-# include <limits.h>
-#else
-# include <assert.h>
-#endif
- Syntax error
-_ACEOF
-if ac_fn_c_try_cpp "$LINENO"; then :
-
-else
- # Broken: fails on valid input.
-continue
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-
- # OK, works on sane cases. Now check whether nonexistent headers
- # can be detected and how.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <ac_nonexistent.h>
-_ACEOF
-if ac_fn_c_try_cpp "$LINENO"; then :
- # Broken: success on invalid input.
-continue
-else
- # Passes both tests.
-ac_preproc_ok=:
-break
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-
-done
-# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
-rm -f conftest.i conftest.err conftest.$ac_ext
-if $ac_preproc_ok; then :
-
-else
- { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
-See \`config.log' for more details" "$LINENO" 5; }
-fi
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
-$as_echo_n "checking for egrep... " >&6; }
-if ${ac_cv_path_EGREP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
- then ac_cv_path_EGREP="$GREP -E"
- else
- if test -z "$EGREP"; then
- ac_path_EGREP_found=false
- # Loop through the user's path and test for each of PROGNAME-LIST
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_prog in egrep; do
- for ac_exec_ext in '' $ac_executable_extensions; do
- ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
- as_fn_executable_p "$ac_path_EGREP" || continue
-# Check for GNU ac_path_EGREP and select it if it is found.
- # Check for GNU $ac_path_EGREP
-case `"$ac_path_EGREP" --version 2>&1` in
-*GNU*)
- ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
-*)
- ac_count=0
- $as_echo_n 0123456789 >"conftest.in"
- while :
- do
- cat "conftest.in" "conftest.in" >"conftest.tmp"
- mv "conftest.tmp" "conftest.in"
- cp "conftest.in" "conftest.nl"
- $as_echo 'EGREP' >> "conftest.nl"
- "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
- diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
- as_fn_arith $ac_count + 1 && ac_count=$as_val
- if test $ac_count -gt ${ac_path_EGREP_max-0}; then
- # Best one so far, save it but keep looking for a better one
- ac_cv_path_EGREP="$ac_path_EGREP"
- ac_path_EGREP_max=$ac_count
- fi
- # 10*(2^10) chars as input seems more than enough
- test $ac_count -gt 10 && break
- done
- rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
-esac
-
- $ac_path_EGREP_found && break 3
- done
- done
- done
-IFS=$as_save_IFS
- if test -z "$ac_cv_path_EGREP"; then
- as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
- fi
-else
- ac_cv_path_EGREP=$EGREP
-fi
-
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
-$as_echo "$ac_cv_path_EGREP" >&6; }
- EGREP="$ac_cv_path_EGREP"
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
-$as_echo_n "checking for ANSI C header files... " >&6; }
-if ${ac_cv_header_stdc+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <stdlib.h>
-#include <stdarg.h>
-#include <string.h>
-#include <float.h>
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_header_stdc=yes
-else
- ac_cv_header_stdc=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-
-if test $ac_cv_header_stdc = yes; then
- # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <string.h>
-
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "memchr" >/dev/null 2>&1; then :
-
-else
- ac_cv_header_stdc=no
-fi
-rm -f conftest*
-
-fi
-
-if test $ac_cv_header_stdc = yes; then
- # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <stdlib.h>
-
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "free" >/dev/null 2>&1; then :
-
-else
- ac_cv_header_stdc=no
-fi
-rm -f conftest*
-
-fi
-
-if test $ac_cv_header_stdc = yes; then
- # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
- if test "$cross_compiling" = yes; then :
- :
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <ctype.h>
-#include <stdlib.h>
-#if ((' ' & 0x0FF) == 0x020)
-# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
-# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
-#else
-# define ISLOWER(c) \
- (('a' <= (c) && (c) <= 'i') \
- || ('j' <= (c) && (c) <= 'r') \
- || ('s' <= (c) && (c) <= 'z'))
-# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
-#endif
-
-#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
-int
-main ()
-{
- int i;
- for (i = 0; i < 256; i++)
- if (XOR (islower (i), ISLOWER (i))
- || toupper (i) != TOUPPER (i))
- return 2;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_run "$LINENO"; then :
-
-else
- ac_cv_header_stdc=no
-fi
-rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
- conftest.$ac_objext conftest.beam conftest.$ac_ext
-fi
-
-fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
-$as_echo "$ac_cv_header_stdc" >&6; }
-if test $ac_cv_header_stdc = yes; then
-
-$as_echo "#define STDC_HEADERS 1" >>confdefs.h
-
-fi
-
-# On IRIX 5.3, sys/types and inttypes.h are conflicting.
-for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
- inttypes.h stdint.h unistd.h
-do :
- as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
-ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
-"
-if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
- cat >>confdefs.h <<_ACEOF
-#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
-_ACEOF
-
-fi
-
-done
-
-
-
- ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
-if test "x$ac_cv_header_minix_config_h" = xyes; then :
- MINIX=yes
-else
- MINIX=
-fi
-
-
- if test "$MINIX" = yes; then
-
-$as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
-
-
-$as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
-
-
-$as_echo "#define _MINIX 1" >>confdefs.h
-
- fi
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
-$as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
-if ${ac_cv_safe_to_define___extensions__+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-# define __EXTENSIONS__ 1
- $ac_includes_default
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_safe_to_define___extensions__=yes
-else
- ac_cv_safe_to_define___extensions__=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
-$as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
- test $ac_cv_safe_to_define___extensions__ = yes &&
- $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
-
- $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
-
- $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
-
- $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
-
- $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
-
-
-
-
-
-
-
-
-
-
-if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
-set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_PKG_CONFIG+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $PKG_CONFIG in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
- ;;
- *)
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
- ;;
-esac
-fi
-PKG_CONFIG=$ac_cv_path_PKG_CONFIG
-if test -n "$PKG_CONFIG"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
-$as_echo "$PKG_CONFIG" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_path_PKG_CONFIG"; then
- ac_pt_PKG_CONFIG=$PKG_CONFIG
- # Extract the first word of "pkg-config", so it can be a program name with args.
-set dummy pkg-config; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $ac_pt_PKG_CONFIG in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
- ;;
- *)
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
- ;;
-esac
-fi
-ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
-if test -n "$ac_pt_PKG_CONFIG"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5
-$as_echo "$ac_pt_PKG_CONFIG" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_pt_PKG_CONFIG" = x; then
- PKG_CONFIG=""
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- PKG_CONFIG=$ac_pt_PKG_CONFIG
- fi
-else
- PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
-fi
-
-fi
-if test -n "$PKG_CONFIG"; then
- _pkg_min_version=0.9.0
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5
-$as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; }
- if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- PKG_CONFIG=""
- fi
-fi
-
-case `pwd` in
- *\ * | *\ *)
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&5
-$as_echo "$as_me: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&2;} ;;
-esac
-
-
-
-macro_version='2.2.7a'
-macro_revision='1.3134'
-
-
-
-
-
-
-
-
-
-
-
-
-
-ltmain="$ac_aux_dir/ltmain.sh"
-
-# Backslashify metacharacters that are still active within
-# double-quoted strings.
-sed_quote_subst='s/\(["`$\\]\)/\\\1/g'
-
-# Same as above, but do not quote variable references.
-double_quote_subst='s/\(["`\\]\)/\\\1/g'
-
-# Sed substitution to delay expansion of an escaped shell variable in a
-# double_quote_subst'ed string.
-delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
-
-# Sed substitution to delay expansion of an escaped single quote.
-delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g'
-
-# Sed substitution to avoid accidental globbing in evaled expressions
-no_glob_subst='s/\*/\\\*/g'
-
-ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
-ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO
-ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5
-$as_echo_n "checking how to print strings... " >&6; }
-# Test print first, because it will be a builtin if present.
-if test "X`print -r -- -n 2>/dev/null`" = X-n && \
- test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
- ECHO='print -r --'
-elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
- ECHO='printf %s\n'
-else
- # Use this function as a fallback that always works.
- func_fallback_echo ()
- {
- eval 'cat <<_LTECHO_EOF
-$1
-_LTECHO_EOF'
- }
- ECHO='func_fallback_echo'
-fi
-
-# func_echo_all arg...
-# Invoke $ECHO with all args, space-separated.
-func_echo_all ()
-{
- $ECHO ""
-}
-
-case "$ECHO" in
- printf*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: printf" >&5
-$as_echo "printf" >&6; } ;;
- print*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: print -r" >&5
-$as_echo "print -r" >&6; } ;;
- *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: cat" >&5
-$as_echo "cat" >&6; } ;;
-esac
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
-$as_echo_n "checking for a sed that does not truncate output... " >&6; }
-if ${ac_cv_path_SED+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
- for ac_i in 1 2 3 4 5 6 7; do
- ac_script="$ac_script$as_nl$ac_script"
- done
- echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
- { ac_script=; unset ac_script;}
- if test -z "$SED"; then
- ac_path_SED_found=false
- # Loop through the user's path and test for each of PROGNAME-LIST
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_prog in sed gsed; do
- for ac_exec_ext in '' $ac_executable_extensions; do
- ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
- as_fn_executable_p "$ac_path_SED" || continue
-# Check for GNU ac_path_SED and select it if it is found.
- # Check for GNU $ac_path_SED
-case `"$ac_path_SED" --version 2>&1` in
-*GNU*)
- ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
-*)
- ac_count=0
- $as_echo_n 0123456789 >"conftest.in"
- while :
- do
- cat "conftest.in" "conftest.in" >"conftest.tmp"
- mv "conftest.tmp" "conftest.in"
- cp "conftest.in" "conftest.nl"
- $as_echo '' >> "conftest.nl"
- "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
- diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
- as_fn_arith $ac_count + 1 && ac_count=$as_val
- if test $ac_count -gt ${ac_path_SED_max-0}; then
- # Best one so far, save it but keep looking for a better one
- ac_cv_path_SED="$ac_path_SED"
- ac_path_SED_max=$ac_count
- fi
- # 10*(2^10) chars as input seems more than enough
- test $ac_count -gt 10 && break
- done
- rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
-esac
-
- $ac_path_SED_found && break 3
- done
- done
- done
-IFS=$as_save_IFS
- if test -z "$ac_cv_path_SED"; then
- as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
- fi
-else
- ac_cv_path_SED=$SED
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
-$as_echo "$ac_cv_path_SED" >&6; }
- SED="$ac_cv_path_SED"
- rm -f conftest.sed
-
-test -z "$SED" && SED=sed
-Xsed="$SED -e 1s/^X//"
-
-
-
-
-
-
-
-
-
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5
-$as_echo_n "checking for fgrep... " >&6; }
-if ${ac_cv_path_FGREP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1
- then ac_cv_path_FGREP="$GREP -F"
- else
- if test -z "$FGREP"; then
- ac_path_FGREP_found=false
- # Loop through the user's path and test for each of PROGNAME-LIST
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_prog in fgrep; do
- for ac_exec_ext in '' $ac_executable_extensions; do
- ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext"
- as_fn_executable_p "$ac_path_FGREP" || continue
-# Check for GNU ac_path_FGREP and select it if it is found.
- # Check for GNU $ac_path_FGREP
-case `"$ac_path_FGREP" --version 2>&1` in
-*GNU*)
- ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;;
-*)
- ac_count=0
- $as_echo_n 0123456789 >"conftest.in"
- while :
- do
- cat "conftest.in" "conftest.in" >"conftest.tmp"
- mv "conftest.tmp" "conftest.in"
- cp "conftest.in" "conftest.nl"
- $as_echo 'FGREP' >> "conftest.nl"
- "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break
- diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
- as_fn_arith $ac_count + 1 && ac_count=$as_val
- if test $ac_count -gt ${ac_path_FGREP_max-0}; then
- # Best one so far, save it but keep looking for a better one
- ac_cv_path_FGREP="$ac_path_FGREP"
- ac_path_FGREP_max=$ac_count
- fi
- # 10*(2^10) chars as input seems more than enough
- test $ac_count -gt 10 && break
- done
- rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
-esac
-
- $ac_path_FGREP_found && break 3
- done
- done
- done
-IFS=$as_save_IFS
- if test -z "$ac_cv_path_FGREP"; then
- as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
- fi
-else
- ac_cv_path_FGREP=$FGREP
-fi
-
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5
-$as_echo "$ac_cv_path_FGREP" >&6; }
- FGREP="$ac_cv_path_FGREP"
-
-
-test -z "$GREP" && GREP=grep
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-# Check whether --with-gnu-ld was given.
-if test "${with_gnu_ld+set}" = set; then :
- withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
-else
- with_gnu_ld=no
-fi
-
-ac_prog=ld
-if test "$GCC" = yes; then
- # Check if gcc -print-prog-name=ld gives a path.
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5
-$as_echo_n "checking for ld used by $CC... " >&6; }
- case $host in
- *-*-mingw*)
- # gcc leaves a trailing carriage return which upsets mingw
- ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
- *)
- ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
- esac
- case $ac_prog in
- # Accept absolute paths.
- [\\/]* | ?:[\\/]*)
- re_direlt='/[^/][^/]*/\.\./'
- # Canonicalize the pathname of ld
- ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'`
- while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do
- ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"`
- done
- test -z "$LD" && LD="$ac_prog"
- ;;
- "")
- # If it fails, then pretend we aren't using GCC.
- ac_prog=ld
- ;;
- *)
- # If it is relative, then search for the first ld in PATH.
- with_gnu_ld=unknown
- ;;
- esac
-elif test "$with_gnu_ld" = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
-$as_echo_n "checking for GNU ld... " >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
-$as_echo_n "checking for non-GNU ld... " >&6; }
-fi
-if ${lt_cv_path_LD+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -z "$LD"; then
- lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH; do
- IFS="$lt_save_ifs"
- test -z "$ac_dir" && ac_dir=.
- if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
- lt_cv_path_LD="$ac_dir/$ac_prog"
- # Check to see if the program is GNU ld. I'd rather use --version,
- # but apparently some variants of GNU ld only accept -v.
- # Break only if it was the GNU/non-GNU ld that we prefer.
- case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
- *GNU* | *'with BFD'*)
- test "$with_gnu_ld" != no && break
- ;;
- *)
- test "$with_gnu_ld" != yes && break
- ;;
- esac
- fi
- done
- IFS="$lt_save_ifs"
-else
- lt_cv_path_LD="$LD" # Let the user override the test with a path.
-fi
-fi
-
-LD="$lt_cv_path_LD"
-if test -n "$LD"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
-$as_echo "$LD" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
-$as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
-if ${lt_cv_prog_gnu_ld+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- # I'd rather use --version here, but apparently some GNU lds only accept -v.
-case `$LD -v 2>&1 </dev/null` in
-*GNU* | *'with BFD'*)
- lt_cv_prog_gnu_ld=yes
- ;;
-*)
- lt_cv_prog_gnu_ld=no
- ;;
-esac
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_gnu_ld" >&5
-$as_echo "$lt_cv_prog_gnu_ld" >&6; }
-with_gnu_ld=$lt_cv_prog_gnu_ld
-
-
-
-
-
-
-
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for BSD- or MS-compatible name lister (nm)" >&5
-$as_echo_n "checking for BSD- or MS-compatible name lister (nm)... " >&6; }
-if ${lt_cv_path_NM+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$NM"; then
- # Let the user override the nm to test.
- lt_nm_to_check="$NM"
- else
- lt_nm_to_check="${ac_tool_prefix}nm"
- if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
- lt_nm_to_check="$lt_nm_to_check nm"
- fi
- fi
- for lt_tmp_nm in "$lt_nm_to_check"; do
- lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
- IFS="$lt_save_ifs"
- test -z "$ac_dir" && ac_dir=.
- # Strip out any user-provided options from the nm to test twice,
- # the first time to test to see if nm (rather than its options) has
- # an explicit path, the second time to yield a file which can be
- # nm'ed itself.
- tmp_nm_path="`$ECHO "$lt_tmp_nm" | sed 's, -.*$,,'`"
- case "$tmp_nm_path" in
- */*|*\\*) tmp_nm="$lt_tmp_nm";;
- *) tmp_nm="$ac_dir/$lt_tmp_nm";;
- esac
- tmp_nm_to_nm="`$ECHO "$tmp_nm" | sed 's, -.*$,,'`"
- if test -f "$tmp_nm_to_nm" || test -f "$tmp_nm_to_nm$ac_exeext" ; then
- # Check to see if the nm accepts a BSD-compat flag.
- # Adding the `sed 1q' prevents false positives on HP-UX, which says:
- # nm: unknown option "B" ignored
- case `"$tmp_nm" -B "$tmp_nm_to_nm" 2>&1 | grep -v '^ *$' | sed '1q'` in
- *$tmp_nm*) lt_cv_path_NM="$tmp_nm -B"
- break
- ;;
- *)
- case `"$tmp_nm" -p "$tmp_nm_to_nm" 2>&1 | grep -v '^ *$' | sed '1q'` in
- *$tmp_nm*)
- lt_cv_path_NM="$tmp_nm -p"
- break
- ;;
- *)
- lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
- continue # so that we can try to find one that supports BSD flags
- ;;
- esac
- ;;
- esac
- fi
- done
- IFS="$lt_save_ifs"
- done
- : ${lt_cv_path_NM=no}
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_NM" >&5
-$as_echo "$lt_cv_path_NM" >&6; }
-if test "$lt_cv_path_NM" != "no"; then
- NM="$lt_cv_path_NM"
-else
- # Didn't find any BSD compatible name lister, look for dumpbin.
- if test -n "$DUMPBIN"; then :
- # Let the user override the test.
- else
- if test -n "$ac_tool_prefix"; then
- for ac_prog in dumpbin "link -dump"
- do
- # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
-set dummy $ac_tool_prefix$ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_DUMPBIN+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$DUMPBIN"; then
- ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_DUMPBIN="$ac_tool_prefix$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-DUMPBIN=$ac_cv_prog_DUMPBIN
-if test -n "$DUMPBIN"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5
-$as_echo "$DUMPBIN" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$DUMPBIN" && break
- done
-fi
-if test -z "$DUMPBIN"; then
- ac_ct_DUMPBIN=$DUMPBIN
- for ac_prog in dumpbin "link -dump"
-do
- # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_DUMPBIN+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_DUMPBIN"; then
- ac_cv_prog_ac_ct_DUMPBIN="$ac_ct_DUMPBIN" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_DUMPBIN="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_DUMPBIN=$ac_cv_prog_ac_ct_DUMPBIN
-if test -n "$ac_ct_DUMPBIN"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DUMPBIN" >&5
-$as_echo "$ac_ct_DUMPBIN" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$ac_ct_DUMPBIN" && break
-done
-
- if test "x$ac_ct_DUMPBIN" = x; then
- DUMPBIN=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- DUMPBIN=$ac_ct_DUMPBIN
- fi
-fi
-
- case `$DUMPBIN -symbols /dev/null 2>&1 | sed '1q'` in
- *COFF*)
- DUMPBIN="$DUMPBIN -symbols"
- ;;
- *)
- DUMPBIN=:
- ;;
- esac
- fi
-
- if test "$DUMPBIN" != ":"; then
- NM="$DUMPBIN"
- fi
-fi
-test -z "$NM" && NM=nm
-
-
-
-
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the name lister ($NM) interface" >&5
-$as_echo_n "checking the name lister ($NM) interface... " >&6; }
-if ${lt_cv_nm_interface+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_nm_interface="BSD nm"
- echo "int some_variable = 0;" > conftest.$ac_ext
- (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&5)
- (eval "$ac_compile" 2>conftest.err)
- cat conftest.err >&5
- (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&5)
- (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out)
- cat conftest.err >&5
- (eval echo "\"\$as_me:$LINENO: output\"" >&5)
- cat conftest.out >&5
- if $GREP 'External.*some_variable' conftest.out > /dev/null; then
- lt_cv_nm_interface="MS dumpbin"
- fi
- rm -f conftest*
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_nm_interface" >&5
-$as_echo "$lt_cv_nm_interface" >&6; }
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
-$as_echo_n "checking whether ln -s works... " >&6; }
-LN_S=$as_ln_s
-if test "$LN_S" = "ln -s"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
-$as_echo "no, using $LN_S" >&6; }
-fi
-
-# find the maximum length of command line arguments
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the maximum length of command line arguments" >&5
-$as_echo_n "checking the maximum length of command line arguments... " >&6; }
-if ${lt_cv_sys_max_cmd_len+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- i=0
- teststring="ABCD"
-
- case $build_os in
- msdosdjgpp*)
- # On DJGPP, this test can blow up pretty badly due to problems in libc
- # (any single argument exceeding 2000 bytes causes a buffer overrun
- # during glob expansion). Even if it were fixed, the result of this
- # check would be larger than it should be.
- lt_cv_sys_max_cmd_len=12288; # 12K is about right
- ;;
-
- gnu*)
- # Under GNU Hurd, this test is not required because there is
- # no limit to the length of command line arguments.
- # Libtool will interpret -1 as no limit whatsoever
- lt_cv_sys_max_cmd_len=-1;
- ;;
-
- cygwin* | mingw* | cegcc*)
- # On Win9x/ME, this test blows up -- it succeeds, but takes
- # about 5 minutes as the teststring grows exponentially.
- # Worse, since 9x/ME are not pre-emptively multitasking,
- # you end up with a "frozen" computer, even though with patience
- # the test eventually succeeds (with a max line length of 256k).
- # Instead, let's just punt: use the minimum linelength reported by
- # all of the supported platforms: 8192 (on NT/2K/XP).
- lt_cv_sys_max_cmd_len=8192;
- ;;
-
- mint*)
- # On MiNT this can take a long time and run out of memory.
- lt_cv_sys_max_cmd_len=8192;
- ;;
-
- amigaos*)
- # On AmigaOS with pdksh, this test takes hours, literally.
- # So we just punt and use a minimum line length of 8192.
- lt_cv_sys_max_cmd_len=8192;
- ;;
-
- netbsd* | freebsd* | openbsd* | darwin* | dragonfly*)
- # This has been around since 386BSD, at least. Likely further.
- if test -x /sbin/sysctl; then
- lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
- elif test -x /usr/sbin/sysctl; then
- lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
- else
- lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs
- fi
- # And add a safety zone
- lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
- lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
- ;;
-
- interix*)
- # We know the value 262144 and hardcode it with a safety zone (like BSD)
- lt_cv_sys_max_cmd_len=196608
- ;;
-
- osf*)
- # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
- # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
- # nice to cause kernel panics so lets avoid the loop below.
- # First set a reasonable default.
- lt_cv_sys_max_cmd_len=16384
- #
- if test -x /sbin/sysconfig; then
- case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
- *1*) lt_cv_sys_max_cmd_len=-1 ;;
- esac
- fi
- ;;
- sco3.2v5*)
- lt_cv_sys_max_cmd_len=102400
- ;;
- sysv5* | sco5v6* | sysv4.2uw2*)
- kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
- if test -n "$kargmax"; then
- lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[ ]//'`
- else
- lt_cv_sys_max_cmd_len=32768
- fi
- ;;
- *)
- lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null`
- if test -n "$lt_cv_sys_max_cmd_len"; then
- lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
- lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
- else
- # Make teststring a little bigger before we do anything with it.
- # a 1K string should be a reasonable start.
- for i in 1 2 3 4 5 6 7 8 ; do
- teststring=$teststring$teststring
- done
- SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
- # If test is not a shell built-in, we'll probably end up computing a
- # maximum length that is only half of the actual maximum length, but
- # we can't tell.
- while { test "X"`func_fallback_echo "$teststring$teststring" 2>/dev/null` \
- = "X$teststring$teststring"; } >/dev/null 2>&1 &&
- test $i != 17 # 1/2 MB should be enough
- do
- i=`expr $i + 1`
- teststring=$teststring$teststring
- done
- # Only check the string length outside the loop.
- lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1`
- teststring=
- # Add a significant safety factor because C++ compilers can tack on
- # massive amounts of additional arguments before passing them to the
- # linker. It appears as though 1/2 is a usable value.
- lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
- fi
- ;;
- esac
-
-fi
-
-if test -n $lt_cv_sys_max_cmd_len ; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sys_max_cmd_len" >&5
-$as_echo "$lt_cv_sys_max_cmd_len" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: none" >&5
-$as_echo "none" >&6; }
-fi
-max_cmd_len=$lt_cv_sys_max_cmd_len
-
-
-
-
-
-
-: ${CP="cp -f"}
-: ${MV="mv -f"}
-: ${RM="rm -f"}
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the shell understands some XSI constructs" >&5
-$as_echo_n "checking whether the shell understands some XSI constructs... " >&6; }
-# Try some XSI features
-xsi_shell=no
-( _lt_dummy="a/b/c"
- test "${_lt_dummy##*/},${_lt_dummy%/*},"${_lt_dummy%"$_lt_dummy"}, \
- = c,a/b,, \
- && eval 'test $(( 1 + 1 )) -eq 2 \
- && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \
- && xsi_shell=yes
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $xsi_shell" >&5
-$as_echo "$xsi_shell" >&6; }
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the shell understands \"+=\"" >&5
-$as_echo_n "checking whether the shell understands \"+=\"... " >&6; }
-lt_shell_append=no
-( foo=bar; set foo baz; eval "$1+=\$2" && test "$foo" = barbaz ) \
- >/dev/null 2>&1 \
- && lt_shell_append=yes
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_shell_append" >&5
-$as_echo "$lt_shell_append" >&6; }
-
-
-if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
- lt_unset=unset
-else
- lt_unset=false
-fi
-
-
-
-
-
-# test EBCDIC or ASCII
-case `echo X|tr X '\101'` in
- A) # ASCII based system
- # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr
- lt_SP2NL='tr \040 \012'
- lt_NL2SP='tr \015\012 \040\040'
- ;;
- *) # EBCDIC based system
- lt_SP2NL='tr \100 \n'
- lt_NL2SP='tr \r\n \100\100'
- ;;
-esac
-
-
-
-
-
-
-
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5
-$as_echo_n "checking for $LD option to reload object files... " >&6; }
-if ${lt_cv_ld_reload_flag+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_ld_reload_flag='-r'
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_reload_flag" >&5
-$as_echo "$lt_cv_ld_reload_flag" >&6; }
-reload_flag=$lt_cv_ld_reload_flag
-case $reload_flag in
-"" | " "*) ;;
-*) reload_flag=" $reload_flag" ;;
-esac
-reload_cmds='$LD$reload_flag -o $output$reload_objs'
-case $host_os in
- darwin*)
- if test "$GCC" = yes; then
- reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
- else
- reload_cmds='$LD$reload_flag -o $output$reload_objs'
- fi
- ;;
-esac
-
-
-
-
-
-
-
-
-
-if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args.
-set dummy ${ac_tool_prefix}objdump; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_OBJDUMP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$OBJDUMP"; then
- ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-OBJDUMP=$ac_cv_prog_OBJDUMP
-if test -n "$OBJDUMP"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
-$as_echo "$OBJDUMP" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_OBJDUMP"; then
- ac_ct_OBJDUMP=$OBJDUMP
- # Extract the first word of "objdump", so it can be a program name with args.
-set dummy objdump; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_OBJDUMP"; then
- ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_OBJDUMP="objdump"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP
-if test -n "$ac_ct_OBJDUMP"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5
-$as_echo "$ac_ct_OBJDUMP" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_OBJDUMP" = x; then
- OBJDUMP="false"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- OBJDUMP=$ac_ct_OBJDUMP
- fi
-else
- OBJDUMP="$ac_cv_prog_OBJDUMP"
-fi
-
-test -z "$OBJDUMP" && OBJDUMP=objdump
-
-
-
-
-
-
-
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to recognize dependent libraries" >&5
-$as_echo_n "checking how to recognize dependent libraries... " >&6; }
-if ${lt_cv_deplibs_check_method+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_file_magic_cmd='$MAGIC_CMD'
-lt_cv_file_magic_test_file=
-lt_cv_deplibs_check_method='unknown'
-# Need to set the preceding variable on all platforms that support
-# interlibrary dependencies.
-# 'none' -- dependencies not supported.
-# `unknown' -- same as none, but documents that we really don't know.
-# 'pass_all' -- all dependencies passed with no checks.
-# 'test_compile' -- check by making test program.
-# 'file_magic [[regex]]' -- check by looking for files in library path
-# which responds to the $file_magic_cmd with a given extended regex.
-# If you have `file' or equivalent on your system and you're not sure
-# whether `pass_all' will *always* work, you probably want this one.
-
-case $host_os in
-aix[4-9]*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-beos*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-bsdi[45]*)
- lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)'
- lt_cv_file_magic_cmd='/usr/bin/file -L'
- lt_cv_file_magic_test_file=/shlib/libc.so
- ;;
-
-cygwin*)
- # func_win32_libid is a shell function defined in ltmain.sh
- lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
- lt_cv_file_magic_cmd='func_win32_libid'
- ;;
-
-mingw* | pw32*)
- # Base MSYS/MinGW do not provide the 'file' command needed by
- # func_win32_libid shell function, so use a weaker test based on 'objdump',
- # unless we find 'file', for example because we are cross-compiling.
- # func_win32_libid assumes BSD nm, so disallow it if using MS dumpbin.
- if ( test "$lt_cv_nm_interface" = "BSD nm" && file / ) >/dev/null 2>&1; then
- lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
- lt_cv_file_magic_cmd='func_win32_libid'
- else
- lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
- lt_cv_file_magic_cmd='$OBJDUMP -f'
- fi
- ;;
-
-cegcc*)
- # use the weaker test based on 'objdump'. See mingw*.
- lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?'
- lt_cv_file_magic_cmd='$OBJDUMP -f'
- ;;
-
-darwin* | rhapsody*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-freebsd* | dragonfly*)
- if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
- case $host_cpu in
- i*86 )
- # Not sure whether the presence of OpenBSD here was a mistake.
- # Let's accept both of them until this is cleared up.
- lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library'
- lt_cv_file_magic_cmd=/usr/bin/file
- lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
- ;;
- esac
- else
- lt_cv_deplibs_check_method=pass_all
- fi
- ;;
-
-gnu*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-haiku*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-hpux10.20* | hpux11*)
- lt_cv_file_magic_cmd=/usr/bin/file
- case $host_cpu in
- ia64*)
- lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64'
- lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
- ;;
- hppa*64*)
- lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF[ -][0-9][0-9])(-bit)?( [LM]SB)? shared object( file)?[, -]* PA-RISC [0-9]\.[0-9]'
- lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
- ;;
- *)
- lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9]\.[0-9]) shared library'
- lt_cv_file_magic_test_file=/usr/lib/libc.sl
- ;;
- esac
- ;;
-
-interix[3-9]*)
- # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
- lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|\.a)$'
- ;;
-
-irix5* | irix6* | nonstopux*)
- case $LD in
- *-32|*"-32 ") libmagic=32-bit;;
- *-n32|*"-n32 ") libmagic=N32;;
- *-64|*"-64 ") libmagic=64-bit;;
- *) libmagic=never-match;;
- esac
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-# This must be Linux ELF.
-linux* | k*bsd*-gnu | kopensolaris*-gnu | uclinuxfdpiceabi)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-netbsd*)
- if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
- lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
- else
- lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$'
- fi
- ;;
-
-newos6*)
- lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)'
- lt_cv_file_magic_cmd=/usr/bin/file
- lt_cv_file_magic_test_file=/usr/lib/libnls.so
- ;;
-
-*nto* | *qnx*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-openbsd*)
- if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
- lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$'
- else
- lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
- fi
- ;;
-
-osf3* | osf4* | osf5*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-rdos*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-solaris*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-sysv4 | sysv4.3*)
- case $host_vendor in
- motorola)
- lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib) M[0-9][0-9]* Version [0-9]'
- lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
- ;;
- ncr)
- lt_cv_deplibs_check_method=pass_all
- ;;
- sequent)
- lt_cv_file_magic_cmd='/bin/file'
- lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )'
- ;;
- sni)
- lt_cv_file_magic_cmd='/bin/file'
- lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib"
- lt_cv_file_magic_test_file=/lib/libc.so
- ;;
- siemens)
- lt_cv_deplibs_check_method=pass_all
- ;;
- pc)
- lt_cv_deplibs_check_method=pass_all
- ;;
- esac
- ;;
-
-tpf*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-vxworks*)
- # Assume VxWorks cross toolchains are built on Linux, possibly
- # as canadian for Windows hosts.
- lt_cv_deplibs_check_method=pass_all
- ;;
-esac
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5
-$as_echo "$lt_cv_deplibs_check_method" >&6; }
-file_magic_cmd=$lt_cv_file_magic_cmd
-deplibs_check_method=$lt_cv_deplibs_check_method
-test -z "$deplibs_check_method" && deplibs_check_method=unknown
-
-
-
-
-
-
-
-
-
-
-
-
-plugin_option=
-plugin_names="liblto_plugin.so liblto_plugin-0.dll cyglto_plugin-0.dll"
-for plugin in $plugin_names; do
- plugin_so=`${CC} ${CFLAGS} --print-prog-name $plugin`
- if test x$plugin_so = x$plugin; then
- plugin_so=`${CC} ${CFLAGS} --print-file-name $plugin`
- fi
- if test x$plugin_so != x$plugin; then
- plugin_option="--plugin $plugin_so"
- break
- fi
-done
-
-if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
-set dummy ${ac_tool_prefix}ar; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_AR+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$AR"; then
- ac_cv_prog_AR="$AR" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_AR="${ac_tool_prefix}ar"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-AR=$ac_cv_prog_AR
-if test -n "$AR"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
-$as_echo "$AR" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_AR"; then
- ac_ct_AR=$AR
- # Extract the first word of "ar", so it can be a program name with args.
-set dummy ar; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_AR+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_AR"; then
- ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_AR="ar"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_AR=$ac_cv_prog_ac_ct_AR
-if test -n "$ac_ct_AR"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
-$as_echo "$ac_ct_AR" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_AR" = x; then
- AR="false"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- AR=$ac_ct_AR
- fi
-else
- AR="$ac_cv_prog_AR"
-fi
-
-test -z "$AR" && AR=ar
-if test -n "$plugin_option"; then
- if $AR --help 2>&1 | grep -q "\--plugin"; then
- touch conftest.c
- $AR $plugin_option rc conftest.a conftest.c
- if test "$?" != 0; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed: $AR $plugin_option rc" >&5
-$as_echo "$as_me: WARNING: Failed: $AR $plugin_option rc" >&2;}
- else
- AR="$AR $plugin_option"
- fi
- rm -f conftest.*
- fi
-fi
-test -z "$AR_FLAGS" && AR_FLAGS=cru
-
-
-
-
-
-
-
-
-
-
-
-if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
-set dummy ${ac_tool_prefix}strip; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_STRIP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$STRIP"; then
- ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_STRIP="${ac_tool_prefix}strip"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-STRIP=$ac_cv_prog_STRIP
-if test -n "$STRIP"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
-$as_echo "$STRIP" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_STRIP"; then
- ac_ct_STRIP=$STRIP
- # Extract the first word of "strip", so it can be a program name with args.
-set dummy strip; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_STRIP"; then
- ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_STRIP="strip"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
-if test -n "$ac_ct_STRIP"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
-$as_echo "$ac_ct_STRIP" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_STRIP" = x; then
- STRIP=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- STRIP=$ac_ct_STRIP
- fi
-else
- STRIP="$ac_cv_prog_STRIP"
-fi
-
-test -z "$STRIP" && STRIP=:
-
-
-
-
-
-
-if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
-set dummy ${ac_tool_prefix}ranlib; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_RANLIB+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$RANLIB"; then
- ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-RANLIB=$ac_cv_prog_RANLIB
-if test -n "$RANLIB"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
-$as_echo "$RANLIB" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_RANLIB"; then
- ac_ct_RANLIB=$RANLIB
- # Extract the first word of "ranlib", so it can be a program name with args.
-set dummy ranlib; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_RANLIB"; then
- ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_RANLIB="ranlib"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
-if test -n "$ac_ct_RANLIB"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
-$as_echo "$ac_ct_RANLIB" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_RANLIB" = x; then
- RANLIB=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- RANLIB=$ac_ct_RANLIB
- fi
-else
- RANLIB="$ac_cv_prog_RANLIB"
-fi
-
-test -z "$RANLIB" && RANLIB=:
-if test -n "$plugin_option" && test "$RANLIB" != ":"; then
- if $RANLIB --help 2>&1 | grep -q "\--plugin"; then
- RANLIB="$RANLIB $plugin_option"
- fi
-fi
-
-
-
-
-
-
-# Determine commands to create old-style static archives.
-old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs'
-old_postinstall_cmds='chmod 644 $oldlib'
-old_postuninstall_cmds=
-
-if test -n "$RANLIB"; then
- case $host_os in
- openbsd*)
- old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib"
- ;;
- *)
- old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib"
- ;;
- esac
- old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib"
-fi
-
-case $host_os in
- darwin*)
- lock_old_archive_extraction=yes ;;
- *)
- lock_old_archive_extraction=no ;;
-esac
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-# If no C compiler was specified, use CC.
-LTCC=${LTCC-"$CC"}
-
-# If no C compiler flags were specified, use CFLAGS.
-LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
-
-# Allow CC to be a program name with arguments.
-compiler=$CC
-
-
-# Check for command to grab the raw symbol name followed by C symbol from nm.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking command to parse $NM output from $compiler object" >&5
-$as_echo_n "checking command to parse $NM output from $compiler object... " >&6; }
-if ${lt_cv_sys_global_symbol_pipe+:} false; then :
- $as_echo_n "(cached) " >&6
-else
-
-# These are sane defaults that work on at least a few old systems.
-# [They come from Ultrix. What could be older than Ultrix?!! ;)]
-
-# Character class describing NM global symbol codes.
-symcode='[BCDEGRST]'
-
-# Regexp to match symbols that can be accessed directly from C.
-sympat='\([_A-Za-z][_A-Za-z0-9]*\)'
-
-# Define system-specific variables.
-case $host_os in
-aix*)
- symcode='[BCDT]'
- ;;
-cygwin* | mingw* | pw32* | cegcc*)
- symcode='[ABCDGISTW]'
- ;;
-hpux*)
- if test "$host_cpu" = ia64; then
- symcode='[ABCDEGRST]'
- fi
- ;;
-irix* | nonstopux*)
- symcode='[BCDEGRST]'
- ;;
-osf*)
- symcode='[BCDEGQRST]'
- ;;
-solaris*)
- symcode='[BCDRT]'
- ;;
-sco3.2v5*)
- symcode='[DT]'
- ;;
-sysv4.2uw2*)
- symcode='[DT]'
- ;;
-sysv5* | sco5v6* | unixware* | OpenUNIX*)
- symcode='[ABDT]'
- ;;
-sysv4)
- symcode='[DFNSTU]'
- ;;
-esac
-
-# If we're using GNU nm, then use its standard symbol codes.
-case `$NM -V 2>&1` in
-*GNU* | *'with BFD'*)
- symcode='[ABCDGIRSTW]' ;;
-esac
-
-# Transform an extracted symbol line into a proper C declaration.
-# Some systems (esp. on ia64) link data and code symbols differently,
-# so use this general approach.
-lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
-
-# Transform an extracted symbol line into symbol name and symbol address
-lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"\2\", (void *) \&\2},/p'"
-lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \(lib[^ ]*\)$/ {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"lib\2\", (void *) \&\2},/p'"
-
-# Handle CRLF in mingw tool chain
-opt_cr=
-case $build_os in
-mingw*)
- opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp
- ;;
-esac
-
-# Try without a prefix underscore, then with it.
-for ac_symprfx in "" "_"; do
-
- # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
- symxfrm="\\1 $ac_symprfx\\2 \\2"
-
- # Write the raw and C identifiers.
- if test "$lt_cv_nm_interface" = "MS dumpbin"; then
- # Fake it for dumpbin and say T for any non-static function
- # and D for any global variable.
- # Also find C++ and __fastcall symbols from MSVC++,
- # which start with @ or ?.
- lt_cv_sys_global_symbol_pipe="$AWK '"\
-" {last_section=section; section=\$ 3};"\
-" /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\
-" \$ 0!~/External *\|/{next};"\
-" / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\
-" {if(hide[section]) next};"\
-" {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\
-" {split(\$ 0, a, /\||\r/); split(a[2], s)};"\
-" s[1]~/^[@?]/{print s[1], s[1]; next};"\
-" s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\
-" ' prfx=^$ac_symprfx"
- else
- lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[ ]\($symcode$symcode*\)[ ][ ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
- fi
-
- # Check to see that the pipe works correctly.
- pipe_works=no
-
- rm -f conftest*
- cat > conftest.$ac_ext <<_LT_EOF
-#ifdef __cplusplus
-extern "C" {
-#endif
-char nm_test_var;
-void nm_test_func(void);
-void nm_test_func(void){}
-#ifdef __cplusplus
-}
-#endif
-int main(){nm_test_var='a';nm_test_func();return(0);}
-_LT_EOF
-
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
- (eval $ac_compile) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- # Now try to grab the symbols.
- nlist=conftest.nm
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist\""; } >&5
- (eval $NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && test -s "$nlist"; then
- # Try sorting and uniquifying the output.
- if sort "$nlist" | uniq > "$nlist"T; then
- mv -f "$nlist"T "$nlist"
- else
- rm -f "$nlist"T
- fi
-
- # Make sure that we snagged all the symbols we need.
- if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
- if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
- cat <<_LT_EOF > conftest.$ac_ext
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-_LT_EOF
- # Now generate the symbol file.
- eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext'
-
- cat <<_LT_EOF >> conftest.$ac_ext
-
-/* The mapping between symbol names and symbols. */
-const struct {
- const char *name;
- void *address;
-}
-lt__PROGRAM__LTX_preloaded_symbols[] =
-{
- { "@PROGRAM@", (void *) 0 },
-_LT_EOF
- $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext
- cat <<\_LT_EOF >> conftest.$ac_ext
- {0, (void *) 0}
-};
-
-/* This works around a problem in FreeBSD linker */
-#ifdef FREEBSD_WORKAROUND
-static const void *lt_preloaded_setup() {
- return lt__PROGRAM__LTX_preloaded_symbols;
-}
-#endif
-
-#ifdef __cplusplus
-}
-#endif
-_LT_EOF
- # Now try linking the two files.
- mv conftest.$ac_objext conftstm.$ac_objext
- lt_save_LIBS="$LIBS"
- lt_save_CFLAGS="$CFLAGS"
- LIBS="conftstm.$ac_objext"
- CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag"
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
- (eval $ac_link) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && test -s conftest${ac_exeext}; then
- pipe_works=yes
- fi
- LIBS="$lt_save_LIBS"
- CFLAGS="$lt_save_CFLAGS"
- else
- echo "cannot find nm_test_func in $nlist" >&5
- fi
- else
- echo "cannot find nm_test_var in $nlist" >&5
- fi
- else
- echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5
- fi
- else
- echo "$progname: failed program was:" >&5
- cat conftest.$ac_ext >&5
- fi
- rm -rf conftest* conftst*
-
- # Do not use the global_symbol_pipe unless it works.
- if test "$pipe_works" = yes; then
- break
- else
- lt_cv_sys_global_symbol_pipe=
- fi
-done
-
-fi
-
-if test -z "$lt_cv_sys_global_symbol_pipe"; then
- lt_cv_sys_global_symbol_to_cdecl=
-fi
-if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
-$as_echo "failed" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
-$as_echo "ok" >&6; }
-fi
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-# Check whether --enable-libtool-lock was given.
-if test "${enable_libtool_lock+set}" = set; then :
- enableval=$enable_libtool_lock;
-fi
-
-test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
-
-# Some flags need to be propagated to the compiler or linker for good
-# libtool support.
-case $host in
-ia64-*-hpux*)
- # Find out which ABI we are using.
- echo 'int i;' > conftest.$ac_ext
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
- (eval $ac_compile) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- case `/usr/bin/file conftest.$ac_objext` in
- *ELF-32*)
- HPUX_IA64_MODE="32"
- ;;
- *ELF-64*)
- HPUX_IA64_MODE="64"
- ;;
- esac
- fi
- rm -rf conftest*
- ;;
-*-*-irix6*)
- # Find out which ABI we are using.
- echo '#line '$LINENO' "configure"' > conftest.$ac_ext
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
- (eval $ac_compile) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- if test "$lt_cv_prog_gnu_ld" = yes; then
- case `/usr/bin/file conftest.$ac_objext` in
- *32-bit*)
- LD="${LD-ld} -melf32bsmip"
- ;;
- *N32*)
- LD="${LD-ld} -melf32bmipn32"
- ;;
- *64-bit*)
- LD="${LD-ld} -melf64bmip"
- ;;
- esac
- else
- case `/usr/bin/file conftest.$ac_objext` in
- *32-bit*)
- LD="${LD-ld} -32"
- ;;
- *N32*)
- LD="${LD-ld} -n32"
- ;;
- *64-bit*)
- LD="${LD-ld} -64"
- ;;
- esac
- fi
- fi
- rm -rf conftest*
- ;;
-
-x86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \
-s390*-*linux*|s390*-*tpf*|sparc*-*linux*)
- # Find out which ABI we are using.
- echo 'int i;' > conftest.$ac_ext
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
- (eval $ac_compile) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- case `/usr/bin/file conftest.o` in
- *32-bit*)
- case $host in
- x86_64-*kfreebsd*-gnu)
- LD="${LD-ld} -m elf_i386_fbsd"
- ;;
- x86_64-*linux*)
- case `/usr/bin/file conftest.o` in
- *x86-64*)
- LD="${LD-ld} -m elf32_x86_64"
- ;;
- *)
- LD="${LD-ld} -m elf_i386"
- ;;
- esac
- ;;
- powerpc64le-*linux*)
- LD="${LD-ld} -m elf32lppclinux"
- ;;
- powerpc64-*linux*)
- LD="${LD-ld} -m elf32ppclinux"
- ;;
- s390x-*linux*)
- LD="${LD-ld} -m elf_s390"
- ;;
- sparc64-*linux*)
- LD="${LD-ld} -m elf32_sparc"
- ;;
- esac
- ;;
- *64-bit*)
- case $host in
- x86_64-*kfreebsd*-gnu)
- LD="${LD-ld} -m elf_x86_64_fbsd"
- ;;
- x86_64-*linux*)
- LD="${LD-ld} -m elf_x86_64"
- ;;
- powerpcle-*linux*)
- LD="${LD-ld} -m elf64lppc"
- ;;
- powerpc-*linux*)
- LD="${LD-ld} -m elf64ppc"
- ;;
- s390*-*linux*|s390*-*tpf*)
- LD="${LD-ld} -m elf64_s390"
- ;;
- sparc*-*linux*)
- LD="${LD-ld} -m elf64_sparc"
- ;;
- esac
- ;;
- esac
- fi
- rm -rf conftest*
- ;;
-
-*-*-sco3.2v5*)
- # On SCO OpenServer 5, we need -belf to get full-featured binaries.
- SAVE_CFLAGS="$CFLAGS"
- CFLAGS="$CFLAGS -belf"
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler needs -belf" >&5
-$as_echo_n "checking whether the C compiler needs -belf... " >&6; }
-if ${lt_cv_cc_needs_belf+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- lt_cv_cc_needs_belf=yes
-else
- lt_cv_cc_needs_belf=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_cc_needs_belf" >&5
-$as_echo "$lt_cv_cc_needs_belf" >&6; }
- if test x"$lt_cv_cc_needs_belf" != x"yes"; then
- # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
- CFLAGS="$SAVE_CFLAGS"
- fi
- ;;
-sparc*-*solaris*)
- # Find out which ABI we are using.
- echo 'int i;' > conftest.$ac_ext
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
- (eval $ac_compile) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- case `/usr/bin/file conftest.o` in
- *64-bit*)
- case $lt_cv_prog_gnu_ld in
- yes*) LD="${LD-ld} -m elf64_sparc" ;;
- *)
- if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then
- LD="${LD-ld} -64"
- fi
- ;;
- esac
- ;;
- esac
- fi
- rm -rf conftest*
- ;;
-esac
-
-need_locks="$enable_libtool_lock"
-
-
- case $host_os in
- rhapsody* | darwin*)
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}dsymutil", so it can be a program name with args.
-set dummy ${ac_tool_prefix}dsymutil; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_DSYMUTIL+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$DSYMUTIL"; then
- ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_DSYMUTIL="${ac_tool_prefix}dsymutil"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-DSYMUTIL=$ac_cv_prog_DSYMUTIL
-if test -n "$DSYMUTIL"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5
-$as_echo "$DSYMUTIL" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_DSYMUTIL"; then
- ac_ct_DSYMUTIL=$DSYMUTIL
- # Extract the first word of "dsymutil", so it can be a program name with args.
-set dummy dsymutil; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_DSYMUTIL+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_DSYMUTIL"; then
- ac_cv_prog_ac_ct_DSYMUTIL="$ac_ct_DSYMUTIL" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_DSYMUTIL="dsymutil"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_DSYMUTIL=$ac_cv_prog_ac_ct_DSYMUTIL
-if test -n "$ac_ct_DSYMUTIL"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DSYMUTIL" >&5
-$as_echo "$ac_ct_DSYMUTIL" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_DSYMUTIL" = x; then
- DSYMUTIL=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- DSYMUTIL=$ac_ct_DSYMUTIL
- fi
-else
- DSYMUTIL="$ac_cv_prog_DSYMUTIL"
-fi
-
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}nmedit", so it can be a program name with args.
-set dummy ${ac_tool_prefix}nmedit; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_NMEDIT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$NMEDIT"; then
- ac_cv_prog_NMEDIT="$NMEDIT" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_NMEDIT="${ac_tool_prefix}nmedit"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-NMEDIT=$ac_cv_prog_NMEDIT
-if test -n "$NMEDIT"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NMEDIT" >&5
-$as_echo "$NMEDIT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_NMEDIT"; then
- ac_ct_NMEDIT=$NMEDIT
- # Extract the first word of "nmedit", so it can be a program name with args.
-set dummy nmedit; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_NMEDIT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_NMEDIT"; then
- ac_cv_prog_ac_ct_NMEDIT="$ac_ct_NMEDIT" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_NMEDIT="nmedit"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_NMEDIT=$ac_cv_prog_ac_ct_NMEDIT
-if test -n "$ac_ct_NMEDIT"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NMEDIT" >&5
-$as_echo "$ac_ct_NMEDIT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_NMEDIT" = x; then
- NMEDIT=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- NMEDIT=$ac_ct_NMEDIT
- fi
-else
- NMEDIT="$ac_cv_prog_NMEDIT"
-fi
-
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}lipo", so it can be a program name with args.
-set dummy ${ac_tool_prefix}lipo; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_LIPO+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$LIPO"; then
- ac_cv_prog_LIPO="$LIPO" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_LIPO="${ac_tool_prefix}lipo"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-LIPO=$ac_cv_prog_LIPO
-if test -n "$LIPO"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5
-$as_echo "$LIPO" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_LIPO"; then
- ac_ct_LIPO=$LIPO
- # Extract the first word of "lipo", so it can be a program name with args.
-set dummy lipo; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_LIPO+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_LIPO"; then
- ac_cv_prog_ac_ct_LIPO="$ac_ct_LIPO" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_LIPO="lipo"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_LIPO=$ac_cv_prog_ac_ct_LIPO
-if test -n "$ac_ct_LIPO"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LIPO" >&5
-$as_echo "$ac_ct_LIPO" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_LIPO" = x; then
- LIPO=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- LIPO=$ac_ct_LIPO
- fi
-else
- LIPO="$ac_cv_prog_LIPO"
-fi
-
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}otool", so it can be a program name with args.
-set dummy ${ac_tool_prefix}otool; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_OTOOL+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$OTOOL"; then
- ac_cv_prog_OTOOL="$OTOOL" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_OTOOL="${ac_tool_prefix}otool"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-OTOOL=$ac_cv_prog_OTOOL
-if test -n "$OTOOL"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5
-$as_echo "$OTOOL" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_OTOOL"; then
- ac_ct_OTOOL=$OTOOL
- # Extract the first word of "otool", so it can be a program name with args.
-set dummy otool; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_OTOOL+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_OTOOL"; then
- ac_cv_prog_ac_ct_OTOOL="$ac_ct_OTOOL" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_OTOOL="otool"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_OTOOL=$ac_cv_prog_ac_ct_OTOOL
-if test -n "$ac_ct_OTOOL"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL" >&5
-$as_echo "$ac_ct_OTOOL" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_OTOOL" = x; then
- OTOOL=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- OTOOL=$ac_ct_OTOOL
- fi
-else
- OTOOL="$ac_cv_prog_OTOOL"
-fi
-
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}otool64", so it can be a program name with args.
-set dummy ${ac_tool_prefix}otool64; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_OTOOL64+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$OTOOL64"; then
- ac_cv_prog_OTOOL64="$OTOOL64" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_OTOOL64="${ac_tool_prefix}otool64"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-OTOOL64=$ac_cv_prog_OTOOL64
-if test -n "$OTOOL64"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL64" >&5
-$as_echo "$OTOOL64" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_OTOOL64"; then
- ac_ct_OTOOL64=$OTOOL64
- # Extract the first word of "otool64", so it can be a program name with args.
-set dummy otool64; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_OTOOL64+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_OTOOL64"; then
- ac_cv_prog_ac_ct_OTOOL64="$ac_ct_OTOOL64" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_OTOOL64="otool64"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_OTOOL64=$ac_cv_prog_ac_ct_OTOOL64
-if test -n "$ac_ct_OTOOL64"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL64" >&5
-$as_echo "$ac_ct_OTOOL64" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_OTOOL64" = x; then
- OTOOL64=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- OTOOL64=$ac_ct_OTOOL64
- fi
-else
- OTOOL64="$ac_cv_prog_OTOOL64"
-fi
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -single_module linker flag" >&5
-$as_echo_n "checking for -single_module linker flag... " >&6; }
-if ${lt_cv_apple_cc_single_mod+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_apple_cc_single_mod=no
- if test -z "${LT_MULTI_MODULE}"; then
- # By default we will add the -single_module flag. You can override
- # by either setting the environment variable LT_MULTI_MODULE
- # non-empty at configure time, or by adding -multi_module to the
- # link flags.
- rm -rf libconftest.dylib*
- echo "int foo(void){return 1;}" > conftest.c
- echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
--dynamiclib -Wl,-single_module conftest.c" >&5
- $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
- -dynamiclib -Wl,-single_module conftest.c 2>conftest.err
- _lt_result=$?
- if test -f libconftest.dylib && test ! -s conftest.err && test $_lt_result = 0; then
- lt_cv_apple_cc_single_mod=yes
- else
- cat conftest.err >&5
- fi
- rm -rf libconftest.dylib*
- rm -f conftest.*
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_apple_cc_single_mod" >&5
-$as_echo "$lt_cv_apple_cc_single_mod" >&6; }
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -exported_symbols_list linker flag" >&5
-$as_echo_n "checking for -exported_symbols_list linker flag... " >&6; }
-if ${lt_cv_ld_exported_symbols_list+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_ld_exported_symbols_list=no
- save_LDFLAGS=$LDFLAGS
- echo "_main" > conftest.sym
- LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- lt_cv_ld_exported_symbols_list=yes
-else
- lt_cv_ld_exported_symbols_list=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LDFLAGS="$save_LDFLAGS"
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_exported_symbols_list" >&5
-$as_echo "$lt_cv_ld_exported_symbols_list" >&6; }
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -force_load linker flag" >&5
-$as_echo_n "checking for -force_load linker flag... " >&6; }
-if ${lt_cv_ld_force_load+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_ld_force_load=no
- cat > conftest.c << _LT_EOF
-int forced_loaded() { return 2;}
-_LT_EOF
- echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&5
- $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5
- echo "$AR cru libconftest.a conftest.o" >&5
- $AR cru libconftest.a conftest.o 2>&5
- cat > conftest.c << _LT_EOF
-int main() { return 0;}
-_LT_EOF
- echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&5
- $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err
- _lt_result=$?
- if test -f conftest && test ! -s conftest.err && test $_lt_result = 0 && $GREP forced_load conftest 2>&1 >/dev/null; then
- lt_cv_ld_force_load=yes
- else
- cat conftest.err >&5
- fi
- rm -f conftest.err libconftest.a conftest conftest.c
- rm -rf conftest.dSYM
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_force_load" >&5
-$as_echo "$lt_cv_ld_force_load" >&6; }
- # Allow for Darwin 4-7 (macOS 10.0-10.3) although these are not expect to
- # build without first building modern cctools / linker.
- case $host_cpu-$host_os in
- *-rhapsody* | *-darwin1.[012])
- _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;;
- *-darwin1.*)
- _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
- *-darwin*)
- # darwin 5.x (macOS 10.1) onwards we only need to adjust when the
- # deployment target is forced to an earlier version.
- case ${MACOSX_DEPLOYMENT_TARGET-UNSET},$host in
- UNSET,*-darwin[89]*|UNSET,*-darwin[12][0123456789]*)
- ;;
- 10.[012][,.]*)
- _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
- ;;
- *)
- ;;
- esac
- ;;
- esac
- if test "$lt_cv_apple_cc_single_mod" = "yes"; then
- _lt_dar_single_mod='$single_module'
- fi
- if test "$lt_cv_ld_exported_symbols_list" = "yes"; then
- _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym'
- else
- _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}'
- fi
- if test "$DSYMUTIL" != ":" && test "$lt_cv_ld_force_load" = "no"; then
- _lt_dsymutil='~$DSYMUTIL $lib || :'
- else
- _lt_dsymutil=
- fi
- ;;
- esac
-
-for ac_header in dlfcn.h
-do :
- ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default
-"
-if test "x$ac_cv_header_dlfcn_h" = xyes; then :
- cat >>confdefs.h <<_ACEOF
-#define HAVE_DLFCN_H 1
-_ACEOF
-
-fi
-
-done
-
-
-
-
-
-
-# Set options
-
-
-
- enable_dlopen=no
-
-
- enable_win32_dll=no
-
-
- # Check whether --enable-shared was given.
-if test "${enable_shared+set}" = set; then :
- enableval=$enable_shared; p=${PACKAGE-default}
- case $enableval in
- yes) enable_shared=yes ;;
- no) enable_shared=no ;;
- *)
- enable_shared=no
- # Look at the argument we got. We use all the common list separators.
- lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
- for pkg in $enableval; do
- IFS="$lt_save_ifs"
- if test "X$pkg" = "X$p"; then
- enable_shared=yes
- fi
- done
- IFS="$lt_save_ifs"
- ;;
- esac
-else
- enable_shared=yes
-fi
-
-
-
-
-
-
-
-
-
- # Check whether --enable-static was given.
-if test "${enable_static+set}" = set; then :
- enableval=$enable_static; p=${PACKAGE-default}
- case $enableval in
- yes) enable_static=yes ;;
- no) enable_static=no ;;
- *)
- enable_static=no
- # Look at the argument we got. We use all the common list separators.
- lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
- for pkg in $enableval; do
- IFS="$lt_save_ifs"
- if test "X$pkg" = "X$p"; then
- enable_static=yes
- fi
- done
- IFS="$lt_save_ifs"
- ;;
- esac
-else
- enable_static=yes
-fi
-
-
-
-
-
-
-
-
-
-
-# Check whether --with-pic was given.
-if test "${with_pic+set}" = set; then :
- withval=$with_pic; pic_mode="$withval"
-else
- pic_mode=default
-fi
-
-
-test -z "$pic_mode" && pic_mode=default
-
-
-
-
-
-
-
- # Check whether --enable-fast-install was given.
-if test "${enable_fast_install+set}" = set; then :
- enableval=$enable_fast_install; p=${PACKAGE-default}
- case $enableval in
- yes) enable_fast_install=yes ;;
- no) enable_fast_install=no ;;
- *)
- enable_fast_install=no
- # Look at the argument we got. We use all the common list separators.
- lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
- for pkg in $enableval; do
- IFS="$lt_save_ifs"
- if test "X$pkg" = "X$p"; then
- enable_fast_install=yes
- fi
- done
- IFS="$lt_save_ifs"
- ;;
- esac
-else
- enable_fast_install=yes
-fi
-
-
-
-
-
-
-
-
-
-
-
-# This can be used to rebuild libtool when needed
-LIBTOOL_DEPS="$ltmain"
-
-# Always use our own libtool.
-LIBTOOL='$(SHELL) $(top_builddir)/libtool'
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-test -z "$LN_S" && LN_S="ln -s"
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-if test -n "${ZSH_VERSION+set}" ; then
- setopt NO_GLOB_SUBST
-fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for objdir" >&5
-$as_echo_n "checking for objdir... " >&6; }
-if ${lt_cv_objdir+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- rm -f .libs 2>/dev/null
-mkdir .libs 2>/dev/null
-if test -d .libs; then
- lt_cv_objdir=.libs
-else
- # MS-DOS does not allow filenames that begin with a dot.
- lt_cv_objdir=_libs
-fi
-rmdir .libs 2>/dev/null
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_objdir" >&5
-$as_echo "$lt_cv_objdir" >&6; }
-objdir=$lt_cv_objdir
-
-
-
-
-
-cat >>confdefs.h <<_ACEOF
-#define LT_OBJDIR "$lt_cv_objdir/"
-_ACEOF
-
-
-
-
-case $host_os in
-aix3*)
- # AIX sometimes has problems with the GCC collect2 program. For some
- # reason, if we set the COLLECT_NAMES environment variable, the problems
- # vanish in a puff of smoke.
- if test "X${COLLECT_NAMES+set}" != Xset; then
- COLLECT_NAMES=
- export COLLECT_NAMES
- fi
- ;;
-esac
-
-# Global variables:
-ofile=libtool
-can_build_shared=yes
-
-# All known linkers require a `.a' archive for static linking (except MSVC,
-# which needs '.lib').
-libext=a
-
-with_gnu_ld="$lt_cv_prog_gnu_ld"
-
-old_CC="$CC"
-old_CFLAGS="$CFLAGS"
-
-# Set sane defaults for various variables
-test -z "$CC" && CC=cc
-test -z "$LTCC" && LTCC=$CC
-test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
-test -z "$LD" && LD=ld
-test -z "$ac_objext" && ac_objext=o
-
-for cc_temp in $compiler""; do
- case $cc_temp in
- compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
- distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
- \-*) ;;
- *) break;;
- esac
-done
-cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
-
-
-# Only perform the check for file, if the check method requires it
-test -z "$MAGIC_CMD" && MAGIC_CMD=file
-case $deplibs_check_method in
-file_magic*)
- if test "$file_magic_cmd" = '$MAGIC_CMD'; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ac_tool_prefix}file" >&5
-$as_echo_n "checking for ${ac_tool_prefix}file... " >&6; }
-if ${lt_cv_path_MAGIC_CMD+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $MAGIC_CMD in
-[\\/*] | ?:[\\/]*)
- lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
- ;;
-*)
- lt_save_MAGIC_CMD="$MAGIC_CMD"
- lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
- ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
- for ac_dir in $ac_dummy; do
- IFS="$lt_save_ifs"
- test -z "$ac_dir" && ac_dir=.
- if test -f $ac_dir/${ac_tool_prefix}file; then
- lt_cv_path_MAGIC_CMD="$ac_dir/${ac_tool_prefix}file"
- if test -n "$file_magic_test_file"; then
- case $deplibs_check_method in
- "file_magic "*)
- file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
- MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
- if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
- $EGREP "$file_magic_regex" > /dev/null; then
- :
- else
- cat <<_LT_EOF 1>&2
-
-*** Warning: the command libtool uses to detect shared libraries,
-*** $file_magic_cmd, produces output that libtool cannot recognize.
-*** The result is that libtool may fail to recognize shared libraries
-*** as such. This will affect the creation of libtool libraries that
-*** depend on shared libraries, but programs linked with such libtool
-*** libraries will work regardless of this problem. Nevertheless, you
-*** may want to report the problem to your system manager and/or to
-*** bug-libtool@gnu.org
-
-_LT_EOF
- fi ;;
- esac
- fi
- break
- fi
- done
- IFS="$lt_save_ifs"
- MAGIC_CMD="$lt_save_MAGIC_CMD"
- ;;
-esac
-fi
-
-MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
-if test -n "$MAGIC_CMD"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5
-$as_echo "$MAGIC_CMD" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-
-
-
-if test -z "$lt_cv_path_MAGIC_CMD"; then
- if test -n "$ac_tool_prefix"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for file" >&5
-$as_echo_n "checking for file... " >&6; }
-if ${lt_cv_path_MAGIC_CMD+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $MAGIC_CMD in
-[\\/*] | ?:[\\/]*)
- lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
- ;;
-*)
- lt_save_MAGIC_CMD="$MAGIC_CMD"
- lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
- ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
- for ac_dir in $ac_dummy; do
- IFS="$lt_save_ifs"
- test -z "$ac_dir" && ac_dir=.
- if test -f $ac_dir/file; then
- lt_cv_path_MAGIC_CMD="$ac_dir/file"
- if test -n "$file_magic_test_file"; then
- case $deplibs_check_method in
- "file_magic "*)
- file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
- MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
- if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
- $EGREP "$file_magic_regex" > /dev/null; then
- :
- else
- cat <<_LT_EOF 1>&2
-
-*** Warning: the command libtool uses to detect shared libraries,
-*** $file_magic_cmd, produces output that libtool cannot recognize.
-*** The result is that libtool may fail to recognize shared libraries
-*** as such. This will affect the creation of libtool libraries that
-*** depend on shared libraries, but programs linked with such libtool
-*** libraries will work regardless of this problem. Nevertheless, you
-*** may want to report the problem to your system manager and/or to
-*** bug-libtool@gnu.org
-
-_LT_EOF
- fi ;;
- esac
- fi
- break
- fi
- done
- IFS="$lt_save_ifs"
- MAGIC_CMD="$lt_save_MAGIC_CMD"
- ;;
-esac
-fi
-
-MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
-if test -n "$MAGIC_CMD"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5
-$as_echo "$MAGIC_CMD" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- else
- MAGIC_CMD=:
- fi
-fi
-
- fi
- ;;
-esac
-
-# Use C for the default configuration in the libtool script
-
-lt_save_CC="$CC"
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-
-# Source file extension for C test sources.
-ac_ext=c
-
-# Object file extension for compiled C test sources.
-objext=o
-objext=$objext
-
-# Code to be used in simple compile tests
-lt_simple_compile_test_code="int some_variable = 0;"
-
-# Code to be used in simple link tests
-lt_simple_link_test_code='int main(){return(0);}'
-
-
-
-
-
-
-
-# If no C compiler was specified, use CC.
-LTCC=${LTCC-"$CC"}
-
-# If no C compiler flags were specified, use CFLAGS.
-LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
-
-# Allow CC to be a program name with arguments.
-compiler=$CC
-
-# Save the default compiler, since it gets overwritten when the other
-# tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP.
-compiler_DEFAULT=$CC
-
-# save warnings/boilerplate of simple test code
-ac_outfile=conftest.$ac_objext
-echo "$lt_simple_compile_test_code" >conftest.$ac_ext
-eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
-_lt_compiler_boilerplate=`cat conftest.err`
-$RM conftest*
-
-ac_outfile=conftest.$ac_objext
-echo "$lt_simple_link_test_code" >conftest.$ac_ext
-eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
-_lt_linker_boilerplate=`cat conftest.err`
-$RM -r conftest*
-
-
-## CAVEAT EMPTOR:
-## There is no encapsulation within the following macros, do not change
-## the running order or otherwise move them around unless you know exactly
-## what you are doing...
-if test -n "$compiler"; then
-
-lt_prog_compiler_no_builtin_flag=
-
-if test "$GCC" = yes; then
- case $cc_basename in
- nvcc*)
- lt_prog_compiler_no_builtin_flag=' -Xcompiler -fno-builtin' ;;
- *)
- lt_prog_compiler_no_builtin_flag=' -fno-builtin' ;;
- esac
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -fno-rtti -fno-exceptions" >&5
-$as_echo_n "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; }
-if ${lt_cv_prog_compiler_rtti_exceptions+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_prog_compiler_rtti_exceptions=no
- ac_outfile=conftest.$ac_objext
- echo "$lt_simple_compile_test_code" > conftest.$ac_ext
- lt_compiler_flag="-fno-rtti -fno-exceptions"
- # Insert the option either (1) after the last *FLAGS variable, or
- # (2) before a word containing "conftest.", or (3) at the end.
- # Note that $ac_compile itself does not contain backslashes and begins
- # with a dollar sign (not a hyphen), so the echo should work correctly.
- # The option is referenced via a variable to avoid confusing sed.
- lt_compile=`echo "$ac_compile" | $SED \
- -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
- -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
- -e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
- (eval "$lt_compile" 2>conftest.err)
- ac_status=$?
- cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- if (exit $ac_status) && test -s "$ac_outfile"; then
- # The compiler can only warn and ignore the option if not recognized
- # So say no if there are warnings other than the usual output.
- $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
- $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
- if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
- lt_cv_prog_compiler_rtti_exceptions=yes
- fi
- fi
- $RM conftest*
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_rtti_exceptions" >&5
-$as_echo "$lt_cv_prog_compiler_rtti_exceptions" >&6; }
-
-if test x"$lt_cv_prog_compiler_rtti_exceptions" = xyes; then
- lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions"
-else
- :
-fi
-
-fi
-
-
-
-
-
-
- lt_prog_compiler_wl=
-lt_prog_compiler_pic=
-lt_prog_compiler_static=
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
-$as_echo_n "checking for $compiler option to produce PIC... " >&6; }
-
- if test "$GCC" = yes; then
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_static='-static'
-
- case $host_os in
- aix*)
- # All AIX code is PIC.
- if test "$host_cpu" = ia64; then
- # AIX 5 now supports IA64 processor
- lt_prog_compiler_static='-Bstatic'
- fi
- lt_prog_compiler_pic='-fPIC'
- ;;
-
- amigaos*)
- case $host_cpu in
- powerpc)
- # see comment about AmigaOS4 .so support
- lt_prog_compiler_pic='-fPIC'
- ;;
- m68k)
- # FIXME: we need at least 68020 code to build shared libraries, but
- # adding the `-m68020' flag to GCC prevents building anything better,
- # like `-m68040'.
- lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4'
- ;;
- esac
- ;;
-
- beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
- # PIC is the default for these OSes.
- ;;
-
- mingw* | cygwin* | pw32* | os2* | cegcc*)
- # This hack is so that the source file can tell whether it is being
- # built for inclusion in a dll (and should export symbols for example).
- # Although the cygwin gcc ignores -fPIC, still need this for old-style
- # (--disable-auto-import) libraries
- lt_prog_compiler_pic='-DDLL_EXPORT'
- ;;
-
- darwin* | rhapsody*)
- # PIC is the default on this platform
- # Common symbols not allowed in MH_DYLIB files
- lt_prog_compiler_pic='-fno-common'
- ;;
-
- haiku*)
- # PIC is the default for Haiku.
- # The "-static" flag exists, but is broken.
- lt_prog_compiler_static=
- ;;
-
- hpux*)
- # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
- # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag
- # sets the default TLS model and affects inlining.
- case $host_cpu in
- hppa*64*)
- # +Z the default
- ;;
- *)
- lt_prog_compiler_pic='-fPIC'
- ;;
- esac
- ;;
-
- interix[3-9]*)
- # Interix 3.x gcc -fpic/-fPIC options generate broken code.
- # Instead, we relocate shared libraries at runtime.
- ;;
-
- msdosdjgpp*)
- # Just because we use GCC doesn't mean we suddenly get shared libraries
- # on systems that don't support them.
- lt_prog_compiler_can_build_shared=no
- enable_shared=no
- ;;
-
- *nto* | *qnx*)
- # QNX uses GNU C++, but need to define -shared option too, otherwise
- # it will coredump.
- lt_prog_compiler_pic='-fPIC -shared'
- ;;
-
- sysv4*MP*)
- if test -d /usr/nec; then
- lt_prog_compiler_pic=-Kconform_pic
- fi
- ;;
-
- *)
- lt_prog_compiler_pic='-fPIC'
- ;;
- esac
-
- case $cc_basename in
- nvcc*) # Cuda Compiler Driver 2.2
- lt_prog_compiler_wl='-Xlinker '
- lt_prog_compiler_pic='-Xcompiler -fPIC'
- ;;
- esac
- else
- # PORTME Check for flag to pass linker flags through the system compiler.
- case $host_os in
- aix*)
- lt_prog_compiler_wl='-Wl,'
- if test "$host_cpu" = ia64; then
- # AIX 5 now supports IA64 processor
- lt_prog_compiler_static='-Bstatic'
- else
- lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp'
- fi
- ;;
-
- mingw* | cygwin* | pw32* | os2* | cegcc*)
- # This hack is so that the source file can tell whether it is being
- # built for inclusion in a dll (and should export symbols for example).
- lt_prog_compiler_pic='-DDLL_EXPORT'
- ;;
-
- hpux9* | hpux10* | hpux11*)
- lt_prog_compiler_wl='-Wl,'
- # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
- # not for PA HP-UX.
- case $host_cpu in
- hppa*64*|ia64*)
- # +Z the default
- ;;
- *)
- lt_prog_compiler_pic='+Z'
- ;;
- esac
- # Is there a better lt_prog_compiler_static that works with the bundled CC?
- lt_prog_compiler_static='${wl}-a ${wl}archive'
- ;;
-
- irix5* | irix6* | nonstopux*)
- lt_prog_compiler_wl='-Wl,'
- # PIC (with -KPIC) is the default.
- lt_prog_compiler_static='-non_shared'
- ;;
-
- linux* | k*bsd*-gnu | kopensolaris*-gnu)
- case $cc_basename in
- # old Intel for x86_64 which still supported -KPIC.
- ecc*)
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_pic='-KPIC'
- lt_prog_compiler_static='-static'
- ;;
- # icc used to be incompatible with GCC.
- # ICC 10 doesn't accept -KPIC any more.
- icc* | ifort*)
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_pic='-fPIC'
- lt_prog_compiler_static='-static'
- ;;
- # Lahey Fortran 8.1.
- lf95*)
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_pic='--shared'
- lt_prog_compiler_static='--static'
- ;;
- pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
- # Portland Group compilers (*not* the Pentium gcc compiler,
- # which looks to be a dead project)
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_pic='-fpic'
- lt_prog_compiler_static='-Bstatic'
- ;;
- ccc*)
- lt_prog_compiler_wl='-Wl,'
- # All Alpha code is PIC.
- lt_prog_compiler_static='-non_shared'
- ;;
- xl* | bgxl* | bgf* | mpixl*)
- # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_pic='-qpic'
- lt_prog_compiler_static='-qstaticlink'
- ;;
- *)
- case `$CC -V 2>&1 | sed 5q` in
- *Sun\ F* | *Sun*Fortran*)
- # Sun Fortran 8.3 passes all unrecognized flags to the linker
- lt_prog_compiler_pic='-KPIC'
- lt_prog_compiler_static='-Bstatic'
- lt_prog_compiler_wl=''
- ;;
- *Sun\ C*)
- # Sun C 5.9
- lt_prog_compiler_pic='-KPIC'
- lt_prog_compiler_static='-Bstatic'
- lt_prog_compiler_wl='-Wl,'
- ;;
- esac
- ;;
- esac
- ;;
-
- newsos6)
- lt_prog_compiler_pic='-KPIC'
- lt_prog_compiler_static='-Bstatic'
- ;;
-
- *nto* | *qnx*)
- # QNX uses GNU C++, but need to define -shared option too, otherwise
- # it will coredump.
- lt_prog_compiler_pic='-fPIC -shared'
- ;;
-
- osf3* | osf4* | osf5*)
- lt_prog_compiler_wl='-Wl,'
- # All OSF/1 code is PIC.
- lt_prog_compiler_static='-non_shared'
- ;;
-
- rdos*)
- lt_prog_compiler_static='-non_shared'
- ;;
-
- solaris*)
- lt_prog_compiler_pic='-KPIC'
- lt_prog_compiler_static='-Bstatic'
- case $cc_basename in
- f77* | f90* | f95*)
- lt_prog_compiler_wl='-Qoption ld ';;
- *)
- lt_prog_compiler_wl='-Wl,';;
- esac
- ;;
-
- sunos4*)
- lt_prog_compiler_wl='-Qoption ld '
- lt_prog_compiler_pic='-PIC'
- lt_prog_compiler_static='-Bstatic'
- ;;
-
- sysv4 | sysv4.2uw2* | sysv4.3*)
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_pic='-KPIC'
- lt_prog_compiler_static='-Bstatic'
- ;;
-
- sysv4*MP*)
- if test -d /usr/nec ;then
- lt_prog_compiler_pic='-Kconform_pic'
- lt_prog_compiler_static='-Bstatic'
- fi
- ;;
-
- sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_pic='-KPIC'
- lt_prog_compiler_static='-Bstatic'
- ;;
-
- unicos*)
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_can_build_shared=no
- ;;
-
- uts4*)
- lt_prog_compiler_pic='-pic'
- lt_prog_compiler_static='-Bstatic'
- ;;
-
- *)
- lt_prog_compiler_can_build_shared=no
- ;;
- esac
- fi
-
-case $host_os in
- # For platforms which do not support PIC, -DPIC is meaningless:
- *djgpp*)
- lt_prog_compiler_pic=
- ;;
- *)
- lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC"
- ;;
-esac
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_prog_compiler_pic" >&5
-$as_echo "$lt_prog_compiler_pic" >&6; }
-
-
-
-
-
-
-#
-# Check to make sure the PIC flag actually works.
-#
-if test -n "$lt_prog_compiler_pic"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5
-$as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic works... " >&6; }
-if ${lt_cv_prog_compiler_pic_works+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_prog_compiler_pic_works=no
- ac_outfile=conftest.$ac_objext
- echo "$lt_simple_compile_test_code" > conftest.$ac_ext
- lt_compiler_flag="$lt_prog_compiler_pic -DPIC"
- # Insert the option either (1) after the last *FLAGS variable, or
- # (2) before a word containing "conftest.", or (3) at the end.
- # Note that $ac_compile itself does not contain backslashes and begins
- # with a dollar sign (not a hyphen), so the echo should work correctly.
- # The option is referenced via a variable to avoid confusing sed.
- lt_compile=`echo "$ac_compile" | $SED \
- -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
- -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
- -e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
- (eval "$lt_compile" 2>conftest.err)
- ac_status=$?
- cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- if (exit $ac_status) && test -s "$ac_outfile"; then
- # The compiler can only warn and ignore the option if not recognized
- # So say no if there are warnings other than the usual output.
- $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
- $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
- if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
- lt_cv_prog_compiler_pic_works=yes
- fi
- fi
- $RM conftest*
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works" >&5
-$as_echo "$lt_cv_prog_compiler_pic_works" >&6; }
-
-if test x"$lt_cv_prog_compiler_pic_works" = xyes; then
- case $lt_prog_compiler_pic in
- "" | " "*) ;;
- *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;;
- esac
-else
- lt_prog_compiler_pic=
- lt_prog_compiler_can_build_shared=no
-fi
-
-fi
-
-
-
-
-
-
-#
-# Check to make sure the static flag actually works.
-#
-wl=$lt_prog_compiler_wl eval lt_tmp_static_flag=\"$lt_prog_compiler_static\"
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5
-$as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; }
-if ${lt_cv_prog_compiler_static_works+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_prog_compiler_static_works=no
- save_LDFLAGS="$LDFLAGS"
- LDFLAGS="$LDFLAGS $lt_tmp_static_flag"
- echo "$lt_simple_link_test_code" > conftest.$ac_ext
- if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
- # The linker can only warn and ignore the option if not recognized
- # So say no if there are warnings
- if test -s conftest.err; then
- # Append any errors to the config.log.
- cat conftest.err 1>&5
- $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
- $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
- if diff conftest.exp conftest.er2 >/dev/null; then
- lt_cv_prog_compiler_static_works=yes
- fi
- else
- lt_cv_prog_compiler_static_works=yes
- fi
- fi
- $RM -r conftest*
- LDFLAGS="$save_LDFLAGS"
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works" >&5
-$as_echo "$lt_cv_prog_compiler_static_works" >&6; }
-
-if test x"$lt_cv_prog_compiler_static_works" = xyes; then
- :
-else
- lt_prog_compiler_static=
-fi
-
-
-
-
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
-$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
-if ${lt_cv_prog_compiler_c_o+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_prog_compiler_c_o=no
- $RM -r conftest 2>/dev/null
- mkdir conftest
- cd conftest
- mkdir out
- echo "$lt_simple_compile_test_code" > conftest.$ac_ext
-
- lt_compiler_flag="-o out/conftest2.$ac_objext"
- # Insert the option either (1) after the last *FLAGS variable, or
- # (2) before a word containing "conftest.", or (3) at the end.
- # Note that $ac_compile itself does not contain backslashes and begins
- # with a dollar sign (not a hyphen), so the echo should work correctly.
- lt_compile=`echo "$ac_compile" | $SED \
- -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
- -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
- -e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
- (eval "$lt_compile" 2>out/conftest.err)
- ac_status=$?
- cat out/conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- if (exit $ac_status) && test -s out/conftest2.$ac_objext
- then
- # The compiler can only warn and ignore the option if not recognized
- # So say no if there are warnings
- $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
- $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
- if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
- lt_cv_prog_compiler_c_o=yes
- fi
- fi
- chmod u+w . 2>&5
- $RM conftest*
- # SGI C++ compiler will create directory out/ii_files/ for
- # template instantiation
- test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
- $RM out/* && rmdir out
- cd ..
- $RM -r conftest
- $RM conftest*
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5
-$as_echo "$lt_cv_prog_compiler_c_o" >&6; }
-
-
-
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
-$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
-if ${lt_cv_prog_compiler_c_o+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_prog_compiler_c_o=no
- $RM -r conftest 2>/dev/null
- mkdir conftest
- cd conftest
- mkdir out
- echo "$lt_simple_compile_test_code" > conftest.$ac_ext
-
- lt_compiler_flag="-o out/conftest2.$ac_objext"
- # Insert the option either (1) after the last *FLAGS variable, or
- # (2) before a word containing "conftest.", or (3) at the end.
- # Note that $ac_compile itself does not contain backslashes and begins
- # with a dollar sign (not a hyphen), so the echo should work correctly.
- lt_compile=`echo "$ac_compile" | $SED \
- -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
- -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
- -e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
- (eval "$lt_compile" 2>out/conftest.err)
- ac_status=$?
- cat out/conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- if (exit $ac_status) && test -s out/conftest2.$ac_objext
- then
- # The compiler can only warn and ignore the option if not recognized
- # So say no if there are warnings
- $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
- $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
- if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
- lt_cv_prog_compiler_c_o=yes
- fi
- fi
- chmod u+w . 2>&5
- $RM conftest*
- # SGI C++ compiler will create directory out/ii_files/ for
- # template instantiation
- test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
- $RM out/* && rmdir out
- cd ..
- $RM -r conftest
- $RM conftest*
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5
-$as_echo "$lt_cv_prog_compiler_c_o" >&6; }
-
-
-
-
-hard_links="nottested"
-if test "$lt_cv_prog_compiler_c_o" = no && test "$need_locks" != no; then
- # do not overwrite the value of need_locks provided by the user
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5
-$as_echo_n "checking if we can lock with hard links... " >&6; }
- hard_links=yes
- $RM conftest*
- ln conftest.a conftest.b 2>/dev/null && hard_links=no
- touch conftest.a
- ln conftest.a conftest.b 2>&5 || hard_links=no
- ln conftest.a conftest.b 2>/dev/null && hard_links=no
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5
-$as_echo "$hard_links" >&6; }
- if test "$hard_links" = no; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5
-$as_echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;}
- need_locks=warn
- fi
-else
- need_locks=no
-fi
-
-
-
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5
-$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; }
-
- runpath_var=
- allow_undefined_flag=
- always_export_symbols=no
- archive_cmds=
- archive_expsym_cmds=
- compiler_needs_object=no
- enable_shared_with_static_runtimes=no
- export_dynamic_flag_spec=
- export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
- hardcode_automatic=no
- hardcode_direct=no
- hardcode_direct_absolute=no
- hardcode_libdir_flag_spec=
- hardcode_libdir_flag_spec_ld=
- hardcode_libdir_separator=
- hardcode_minus_L=no
- hardcode_shlibpath_var=unsupported
- inherit_rpath=no
- link_all_deplibs=unknown
- module_cmds=
- module_expsym_cmds=
- old_archive_from_new_cmds=
- old_archive_from_expsyms_cmds=
- thread_safe_flag_spec=
- whole_archive_flag_spec=
- # include_expsyms should be a list of space-separated symbols to be *always*
- # included in the symbol list
- include_expsyms=
- # exclude_expsyms can be an extended regexp of symbols to exclude
- # it will be wrapped by ` (' and `)$', so one must not match beginning or
- # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
- # as well as any symbol that contains `d'.
- exclude_expsyms='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'
- # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
- # platforms (ab)use it in PIC code, but their linkers get confused if
- # the symbol is explicitly referenced. Since portable code cannot
- # rely on this symbol name, it's probably fine to never include it in
- # preloaded symbol tables.
- # Exclude shared library initialization/finalization symbols.
- extract_expsyms_cmds=
-
- case $host_os in
- cygwin* | mingw* | pw32* | cegcc*)
- # FIXME: the MSVC++ port hasn't been tested in a loooong time
- # When not using gcc, we currently assume that we are using
- # Microsoft Visual C++.
- if test "$GCC" != yes; then
- with_gnu_ld=no
- fi
- ;;
- interix*)
- # we just hope/assume this is gcc and not c89 (= MSVC++)
- with_gnu_ld=yes
- ;;
- openbsd*)
- with_gnu_ld=no
- ;;
- esac
-
- ld_shlibs=yes
-
- # On some targets, GNU ld is compatible enough with the native linker
- # that we're better off using the native interface for both.
- lt_use_gnu_ld_interface=no
- if test "$with_gnu_ld" = yes; then
- case $host_os in
- aix*)
- # The AIX port of GNU ld has always aspired to compatibility
- # with the native linker. However, as the warning in the GNU ld
- # block says, versions before 2.19.5* couldn't really create working
- # shared libraries, regardless of the interface used.
- case `$LD -v 2>&1` in
- *\ \(GNU\ Binutils\)\ 2.19.5*) ;;
- *\ \(GNU\ Binutils\)\ 2.[2-9]*) ;;
- *\ \(GNU\ Binutils\)\ [3-9]*) ;;
- *)
- lt_use_gnu_ld_interface=yes
- ;;
- esac
- ;;
- *)
- lt_use_gnu_ld_interface=yes
- ;;
- esac
- fi
-
- if test "$lt_use_gnu_ld_interface" = yes; then
- # If archive_cmds runs LD, not CC, wlarc should be empty
- wlarc='${wl}'
-
- # Set some defaults for GNU ld with shared library support. These
- # are reset later if shared libraries are not supported. Putting them
- # here allows them to be overridden if necessary.
- runpath_var=LD_RUN_PATH
- hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
- export_dynamic_flag_spec='${wl}--export-dynamic'
- # ancient GNU ld didn't support --whole-archive et. al.
- if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then
- whole_archive_flag_spec="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
- else
- whole_archive_flag_spec=
- fi
- supports_anon_versioning=no
- case `$LD -v 2>&1` in
- *GNU\ gold*) supports_anon_versioning=yes ;;
- *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11
- *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
- *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
- *\ 2.11.*) ;; # other 2.11 versions
- *) supports_anon_versioning=yes ;;
- esac
-
- # See if GNU ld supports shared libraries.
- case $host_os in
- aix[3-9]*)
- # On AIX/PPC, the GNU linker is very broken
- if test "$host_cpu" != ia64; then
- ld_shlibs=no
- cat <<_LT_EOF 1>&2
-
-*** Warning: the GNU linker, at least up to release 2.19, is reported
-*** to be unable to reliably create shared libraries on AIX.
-*** Therefore, libtool is disabling shared libraries support. If you
-*** really care for shared libraries, you may want to install binutils
-*** 2.20 or above, or modify your PATH so that a non-GNU linker is found.
-*** You will then need to restart the configuration process.
-
-_LT_EOF
- fi
- ;;
-
- amigaos*)
- case $host_cpu in
- powerpc)
- # see comment about AmigaOS4 .so support
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- archive_expsym_cmds=''
- ;;
- m68k)
- archive_cmds='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
- hardcode_libdir_flag_spec='-L$libdir'
- hardcode_minus_L=yes
- ;;
- esac
- ;;
-
- beos*)
- if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
- allow_undefined_flag=unsupported
- # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
- # support --undefined. This deserves some investigation. FIXME
- archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- else
- ld_shlibs=no
- fi
- ;;
-
- cygwin* | mingw* | pw32* | cegcc*)
- # _LT_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless,
- # as there is no search path for DLLs.
- hardcode_libdir_flag_spec='-L$libdir'
- export_dynamic_flag_spec='${wl}--export-all-symbols'
- allow_undefined_flag=unsupported
- always_export_symbols=no
- enable_shared_with_static_runtimes=yes
- export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
-
- if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
- # If the export-symbols file already is a .def file (1st line
- # is EXPORTS), use it as is; otherwise, prepend...
- archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
- cp $export_symbols $output_objdir/$soname.def;
- else
- echo EXPORTS > $output_objdir/$soname.def;
- cat $export_symbols >> $output_objdir/$soname.def;
- fi~
- $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
- else
- ld_shlibs=no
- fi
- ;;
-
- haiku*)
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- link_all_deplibs=yes
- ;;
-
- interix[3-9]*)
- hardcode_direct=no
- hardcode_shlibpath_var=no
- hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
- export_dynamic_flag_spec='${wl}-E'
- # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
- # Instead, shared libraries are loaded at an image base (0x10000000 by
- # default) and relocated if they conflict, which is a slow very memory
- # consuming and fragmenting process. To avoid this, we pick a random,
- # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
- # time. Moving up from 0x10000000 also allows more sbrk(2) space.
- archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
- archive_expsym_cmds='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
- ;;
-
- gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu | uclinuxfdpiceabi)
- tmp_diet=no
- if test "$host_os" = linux-dietlibc; then
- case $cc_basename in
- diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn)
- esac
- fi
- if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
- && test "$tmp_diet" = no
- then
- tmp_addflag=' $pic_flag'
- tmp_sharedflag='-shared'
- case $cc_basename,$host_cpu in
- pgcc*) # Portland Group C compiler
- whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
- tmp_addflag=' $pic_flag'
- ;;
- pgf77* | pgf90* | pgf95* | pgfortran*)
- # Portland Group f77 and f90 compilers
- whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
- tmp_addflag=' $pic_flag -Mnomain' ;;
- ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64
- tmp_addflag=' -i_dynamic' ;;
- efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64
- tmp_addflag=' -i_dynamic -nofor_main' ;;
- ifc* | ifort*) # Intel Fortran compiler
- tmp_addflag=' -nofor_main' ;;
- lf95*) # Lahey Fortran 8.1
- whole_archive_flag_spec=
- tmp_sharedflag='--shared' ;;
- xl[cC]* | bgxl[cC]* | mpixl[cC]*) # IBM XL C 8.0 on PPC (deal with xlf below)
- tmp_sharedflag='-qmkshrobj'
- tmp_addflag= ;;
- nvcc*) # Cuda Compiler Driver 2.2
- whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
- compiler_needs_object=yes
- ;;
- esac
- case `$CC -V 2>&1 | sed 5q` in
- *Sun\ C*) # Sun C 5.9
- whole_archive_flag_spec='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
- compiler_needs_object=yes
- tmp_sharedflag='-G' ;;
- *Sun\ F*) # Sun Fortran 8.3
- tmp_sharedflag='-G' ;;
- esac
- archive_cmds='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
-
- if test "x$supports_anon_versioning" = xyes; then
- archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
- cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
- echo "local: *; };" >> $output_objdir/$libname.ver~
- $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
- fi
-
- case $cc_basename in
- xlf* | bgf* | bgxlf* | mpixlf*)
- # IBM XL Fortran 10.1 on PPC cannot create shared libs itself
- whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive'
- hardcode_libdir_flag_spec=
- hardcode_libdir_flag_spec_ld='-rpath $libdir'
- archive_cmds='$LD -shared $libobjs $deplibs $compiler_flags -soname $soname -o $lib'
- if test "x$supports_anon_versioning" = xyes; then
- archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
- cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
- echo "local: *; };" >> $output_objdir/$libname.ver~
- $LD -shared $libobjs $deplibs $compiler_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
- fi
- ;;
- esac
- else
- ld_shlibs=no
- fi
- ;;
-
- netbsd*)
- if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
- archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
- wlarc=
- else
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
- fi
- ;;
-
- solaris*)
- if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then
- ld_shlibs=no
- cat <<_LT_EOF 1>&2
-
-*** Warning: The releases 2.8.* of the GNU linker cannot reliably
-*** create shared libraries on Solaris systems. Therefore, libtool
-*** is disabling shared libraries support. We urge you to upgrade GNU
-*** binutils to release 2.9.1 or newer. Another option is to modify
-*** your PATH or compiler configuration so that the native linker is
-*** used, and then restart.
-
-_LT_EOF
- elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
- else
- ld_shlibs=no
- fi
- ;;
-
- sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
- case `$LD -v 2>&1` in
- *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*)
- ld_shlibs=no
- cat <<_LT_EOF 1>&2
-
-*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not
-*** reliably create shared libraries on SCO systems. Therefore, libtool
-*** is disabling shared libraries support. We urge you to upgrade GNU
-*** binutils to release 2.16.91.0.3 or newer. Another option is to modify
-*** your PATH or compiler configuration so that the native linker is
-*** used, and then restart.
-
-_LT_EOF
- ;;
- *)
- # For security reasons, it is highly recommended that you always
- # use absolute paths for naming shared libraries, and exclude the
- # DT_RUNPATH tag from executables and libraries. But doing so
- # requires that you compile everything twice, which is a pain.
- if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
- hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
- else
- ld_shlibs=no
- fi
- ;;
- esac
- ;;
-
- sunos4*)
- archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
- wlarc=
- hardcode_direct=yes
- hardcode_shlibpath_var=no
- ;;
-
- *)
- if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
- else
- ld_shlibs=no
- fi
- ;;
- esac
-
- if test "$ld_shlibs" = no; then
- runpath_var=
- hardcode_libdir_flag_spec=
- export_dynamic_flag_spec=
- whole_archive_flag_spec=
- fi
- else
- # PORTME fill in a description of your system's linker (not GNU ld)
- case $host_os in
- aix3*)
- allow_undefined_flag=unsupported
- always_export_symbols=yes
- archive_expsym_cmds='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname'
- # Note: this linker hardcodes the directories in LIBPATH if there
- # are no directories specified by -L.
- hardcode_minus_L=yes
- if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then
- # Neither direct hardcoding nor static linking is supported with a
- # broken collect2.
- hardcode_direct=unsupported
- fi
- ;;
-
- aix[4-9]*)
- if test "$host_cpu" = ia64; then
- # On IA64, the linker does run time linking by default, so we don't
- # have to do anything special.
- aix_use_runtimelinking=no
- exp_sym_flag='-Bexport'
- no_entry_flag=""
- else
- # If we're using GNU nm, then we don't want the "-C" option.
- # -C means demangle to AIX nm, but means don't demangle with GNU nm
- # Also, AIX nm treats weak defined symbols like other global
- # defined symbols, whereas GNU nm marks them as "W".
- if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
- export_symbols_cmds='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
- else
- export_symbols_cmds='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "L")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
- fi
- aix_use_runtimelinking=no
-
- # Test if we are trying to use run time linking or normal
- # AIX style linking. If -brtl is somewhere in LDFLAGS, we
- # need to do runtime linking.
- case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*)
- for ld_flag in $LDFLAGS; do
- if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
- aix_use_runtimelinking=yes
- break
- fi
- done
- ;;
- esac
-
- exp_sym_flag='-bexport'
- no_entry_flag='-bnoentry'
- fi
-
- # When large executables or shared objects are built, AIX ld can
- # have problems creating the table of contents. If linking a library
- # or program results in "error TOC overflow" add -mminimal-toc to
- # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
- # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
-
- archive_cmds=''
- hardcode_direct=yes
- hardcode_direct_absolute=yes
- hardcode_libdir_separator=':'
- link_all_deplibs=yes
- file_list_spec='${wl}-f,'
-
- if test "$GCC" = yes; then
- case $host_os in aix4.[012]|aix4.[012].*)
- # We only want to do this on AIX 4.2 and lower, the check
- # below for broken collect2 doesn't work under 4.3+
- collect2name=`${CC} -print-prog-name=collect2`
- if test -f "$collect2name" &&
- strings "$collect2name" | $GREP resolve_lib_name >/dev/null
- then
- # We have reworked collect2
- :
- else
- # We have old collect2
- hardcode_direct=unsupported
- # It fails to find uninstalled libraries when the uninstalled
- # path is not listed in the libpath. Setting hardcode_minus_L
- # to unsupported forces relinking
- hardcode_minus_L=yes
- hardcode_libdir_flag_spec='-L$libdir'
- hardcode_libdir_separator=
- fi
- ;;
- esac
- shared_flag='-shared'
- if test "$aix_use_runtimelinking" = yes; then
- shared_flag="$shared_flag "'${wl}-G'
- fi
- else
- # not using gcc
- if test "$host_cpu" = ia64; then
- # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
- # chokes on -Wl,-G. The following line is correct:
- shared_flag='-G'
- else
- if test "$aix_use_runtimelinking" = yes; then
- shared_flag='${wl}-G'
- else
- shared_flag='${wl}-bM:SRE'
- fi
- fi
- fi
-
- export_dynamic_flag_spec='${wl}-bexpall'
- # It seems that -bexpall does not export symbols beginning with
- # underscore (_), so it is better to generate a list of symbols to export.
- always_export_symbols=yes
- if test "$aix_use_runtimelinking" = yes; then
- # Warning - without using the other runtime loading flags (-brtl),
- # -berok will link without error, but may produce a broken library.
- allow_undefined_flag='-berok'
- # Determine the default libpath from the value encoded in an
- # empty executable.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
-
-lt_aix_libpath_sed='
- /Import File Strings/,/^$/ {
- /^0/ {
- s/^0 *\(.*\)$/\1/
- p
- }
- }'
-aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
-# Check for a 64-bit object if we didn't find anything.
-if test -z "$aix_libpath"; then
- aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
-fi
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
-
- hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
- archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
- else
- if test "$host_cpu" = ia64; then
- hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib'
- allow_undefined_flag="-z nodefs"
- archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols"
- else
- # Determine the default libpath from the value encoded in an
- # empty executable.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
-
-lt_aix_libpath_sed='
- /Import File Strings/,/^$/ {
- /^0/ {
- s/^0 *\(.*\)$/\1/
- p
- }
- }'
-aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
-# Check for a 64-bit object if we didn't find anything.
-if test -z "$aix_libpath"; then
- aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
-fi
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
-
- hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
- # Warning - without using the other run time loading flags,
- # -berok will link without error, but may produce a broken library.
- no_undefined_flag=' ${wl}-bernotok'
- allow_undefined_flag=' ${wl}-berok'
- if test "$with_gnu_ld" = yes; then
- # We only use this code for GNU lds that support --whole-archive.
- whole_archive_flag_spec='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
- else
- # Exported symbols can be pulled into shared objects from archives
- whole_archive_flag_spec='$convenience'
- fi
- archive_cmds_need_lc=yes
- # This is similar to how AIX traditionally builds its shared libraries.
- archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
- fi
- fi
- ;;
-
- amigaos*)
- case $host_cpu in
- powerpc)
- # see comment about AmigaOS4 .so support
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- archive_expsym_cmds=''
- ;;
- m68k)
- archive_cmds='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
- hardcode_libdir_flag_spec='-L$libdir'
- hardcode_minus_L=yes
- ;;
- esac
- ;;
-
- bsdi[45]*)
- export_dynamic_flag_spec=-rdynamic
- ;;
-
- cygwin* | mingw* | pw32* | cegcc*)
- # When not using gcc, we currently assume that we are using
- # Microsoft Visual C++.
- # hardcode_libdir_flag_spec is actually meaningless, as there is
- # no search path for DLLs.
- hardcode_libdir_flag_spec=' '
- allow_undefined_flag=unsupported
- # Tell ltmain to make .lib files, not .a files.
- libext=lib
- # Tell ltmain to make .dll files, not .so files.
- shrext_cmds=".dll"
- # FIXME: Setting linknames here is a bad hack.
- archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
- # The linker will automatically build a .lib file if we build a DLL.
- old_archive_from_new_cmds='true'
- # FIXME: Should let the user specify the lib program.
- old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs'
- fix_srcfile_path='`cygpath -w "$srcfile"`'
- enable_shared_with_static_runtimes=yes
- ;;
-
- darwin* | rhapsody*)
-
-
- archive_cmds_need_lc=no
- hardcode_direct=no
- hardcode_automatic=yes
- hardcode_shlibpath_var=unsupported
- if test "$lt_cv_ld_force_load" = "yes"; then
- whole_archive_flag_spec='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience ${wl}-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`'
- else
- whole_archive_flag_spec=''
- fi
- link_all_deplibs=yes
- allow_undefined_flag="$_lt_dar_allow_undefined"
- case $cc_basename in
- ifort*) _lt_dar_can_shared=yes ;;
- *) _lt_dar_can_shared=$GCC ;;
- esac
- if test "$_lt_dar_can_shared" = "yes"; then
- output_verbose_link_cmd=func_echo_all
- archive_cmds="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}"
- module_cmds="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
- archive_expsym_cmds="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}"
- module_expsym_cmds="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}"
-
- else
- ld_shlibs=no
- fi
-
- ;;
-
- dgux*)
- archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
- hardcode_libdir_flag_spec='-L$libdir'
- hardcode_shlibpath_var=no
- ;;
-
- # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
- # support. Future versions do this automatically, but an explicit c++rt0.o
- # does not break anything, and helps significantly (at the cost of a little
- # extra space).
- freebsd2.2*)
- archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
- hardcode_libdir_flag_spec='-R$libdir'
- hardcode_direct=yes
- hardcode_shlibpath_var=no
- ;;
-
- # Unfortunately, older versions of FreeBSD 2 do not have this feature.
- freebsd2.*)
- archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
- hardcode_direct=yes
- hardcode_minus_L=yes
- hardcode_shlibpath_var=no
- ;;
-
- # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
- freebsd* | dragonfly*)
- archive_cmds='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
- hardcode_libdir_flag_spec='-R$libdir'
- hardcode_direct=yes
- hardcode_shlibpath_var=no
- ;;
-
- hpux9*)
- if test "$GCC" = yes; then
- archive_cmds='$RM $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
- else
- archive_cmds='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
- fi
- hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
- hardcode_libdir_separator=:
- hardcode_direct=yes
-
- # hardcode_minus_L: Not really in the search PATH,
- # but as the default location of the library.
- hardcode_minus_L=yes
- export_dynamic_flag_spec='${wl}-E'
- ;;
-
- hpux10*)
- if test "$GCC" = yes && test "$with_gnu_ld" = no; then
- archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
- else
- archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
- fi
- if test "$with_gnu_ld" = no; then
- hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
- hardcode_libdir_flag_spec_ld='+b $libdir'
- hardcode_libdir_separator=:
- hardcode_direct=yes
- hardcode_direct_absolute=yes
- export_dynamic_flag_spec='${wl}-E'
- # hardcode_minus_L: Not really in the search PATH,
- # but as the default location of the library.
- hardcode_minus_L=yes
- fi
- ;;
-
- hpux11*)
- if test "$GCC" = yes && test "$with_gnu_ld" = no; then
- case $host_cpu in
- hppa*64*)
- archive_cmds='$CC -shared ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
- ;;
- ia64*)
- archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
- ;;
- *)
- archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
- ;;
- esac
- else
- case $host_cpu in
- hppa*64*)
- archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
- ;;
- ia64*)
- archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
- ;;
- *)
-
- # Older versions of the 11.00 compiler do not understand -b yet
- # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does)
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC understands -b" >&5
-$as_echo_n "checking if $CC understands -b... " >&6; }
-if ${lt_cv_prog_compiler__b+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_prog_compiler__b=no
- save_LDFLAGS="$LDFLAGS"
- LDFLAGS="$LDFLAGS -b"
- echo "$lt_simple_link_test_code" > conftest.$ac_ext
- if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
- # The linker can only warn and ignore the option if not recognized
- # So say no if there are warnings
- if test -s conftest.err; then
- # Append any errors to the config.log.
- cat conftest.err 1>&5
- $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
- $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
- if diff conftest.exp conftest.er2 >/dev/null; then
- lt_cv_prog_compiler__b=yes
- fi
- else
- lt_cv_prog_compiler__b=yes
- fi
- fi
- $RM -r conftest*
- LDFLAGS="$save_LDFLAGS"
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler__b" >&5
-$as_echo "$lt_cv_prog_compiler__b" >&6; }
-
-if test x"$lt_cv_prog_compiler__b" = xyes; then
- archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
-else
- archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
-fi
-
- ;;
- esac
- fi
- if test "$with_gnu_ld" = no; then
- hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
- hardcode_libdir_separator=:
-
- case $host_cpu in
- hppa*64*|ia64*)
- hardcode_direct=no
- hardcode_shlibpath_var=no
- ;;
- *)
- hardcode_direct=yes
- hardcode_direct_absolute=yes
- export_dynamic_flag_spec='${wl}-E'
-
- # hardcode_minus_L: Not really in the search PATH,
- # but as the default location of the library.
- hardcode_minus_L=yes
- ;;
- esac
- fi
- ;;
-
- irix5* | irix6* | nonstopux*)
- if test "$GCC" = yes; then
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
- # Try to use the -exported_symbol ld option, if it does not
- # work, assume that -exports_file does not work either and
- # implicitly export all symbols.
- save_LDFLAGS="$LDFLAGS"
- LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-int foo(void) {}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
-
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LDFLAGS="$save_LDFLAGS"
- else
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
- fi
- archive_cmds_need_lc='no'
- hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
- hardcode_libdir_separator=:
- inherit_rpath=yes
- link_all_deplibs=yes
- ;;
-
- netbsd*)
- if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
- archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out
- else
- archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF
- fi
- hardcode_libdir_flag_spec='-R$libdir'
- hardcode_direct=yes
- hardcode_shlibpath_var=no
- ;;
-
- newsos6)
- archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
- hardcode_direct=yes
- hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
- hardcode_libdir_separator=:
- hardcode_shlibpath_var=no
- ;;
-
- *nto* | *qnx*)
- ;;
-
- openbsd*)
- if test -f /usr/libexec/ld.so; then
- hardcode_direct=yes
- hardcode_shlibpath_var=no
- hardcode_direct_absolute=yes
- if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
- archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
- archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
- hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
- export_dynamic_flag_spec='${wl}-E'
- else
- case $host_os in
- openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*)
- archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
- hardcode_libdir_flag_spec='-R$libdir'
- ;;
- *)
- archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
- hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
- ;;
- esac
- fi
- else
- ld_shlibs=no
- fi
- ;;
-
- os2*)
- hardcode_libdir_flag_spec='-L$libdir'
- hardcode_minus_L=yes
- allow_undefined_flag=unsupported
- archive_cmds='$ECHO "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~echo DATA >> $output_objdir/$libname.def~echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def'
- old_archive_from_new_cmds='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
- ;;
-
- osf3*)
- if test "$GCC" = yes; then
- allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
- archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
- else
- allow_undefined_flag=' -expect_unresolved \*'
- archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
- fi
- archive_cmds_need_lc='no'
- hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
- hardcode_libdir_separator=:
- ;;
-
- osf4* | osf5*) # as osf3* with the addition of -msym flag
- if test "$GCC" = yes; then
- allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
- archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
- hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
- else
- allow_undefined_flag=' -expect_unresolved \*'
- archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
- archive_expsym_cmds='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~
- $CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp'
-
- # Both c and cxx compiler support -rpath directly
- hardcode_libdir_flag_spec='-rpath $libdir'
- fi
- archive_cmds_need_lc='no'
- hardcode_libdir_separator=:
- ;;
-
- solaris*)
- no_undefined_flag=' -z defs'
- if test "$GCC" = yes; then
- wlarc='${wl}'
- archive_cmds='$CC -shared ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
- archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
- $CC -shared ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
- else
- case `$CC -V 2>&1` in
- *"Compilers 5.0"*)
- wlarc=''
- archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
- archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
- $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp'
- ;;
- *)
- wlarc='${wl}'
- archive_cmds='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags'
- archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
- $CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
- ;;
- esac
- fi
- hardcode_libdir_flag_spec='-R$libdir'
- hardcode_shlibpath_var=no
- case $host_os in
- solaris2.[0-5] | solaris2.[0-5].*) ;;
- *)
- # The compiler driver will combine and reorder linker options,
- # but understands `-z linker_flag'. GCC discards it without `$wl',
- # but is careful enough not to reorder.
- # Supported since Solaris 2.6 (maybe 2.5.1?)
- if test "$GCC" = yes; then
- whole_archive_flag_spec='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
- else
- whole_archive_flag_spec='-z allextract$convenience -z defaultextract'
- fi
- ;;
- esac
- link_all_deplibs=yes
- ;;
-
- sunos4*)
- if test "x$host_vendor" = xsequent; then
- # Use $CC to link under sequent, because it throws in some extra .o
- # files that make .init and .fini sections work.
- archive_cmds='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
- else
- archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
- fi
- hardcode_libdir_flag_spec='-L$libdir'
- hardcode_direct=yes
- hardcode_minus_L=yes
- hardcode_shlibpath_var=no
- ;;
-
- sysv4)
- case $host_vendor in
- sni)
- archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
- hardcode_direct=yes # is this really true???
- ;;
- siemens)
- ## LD is ld it makes a PLAMLIB
- ## CC just makes a GrossModule.
- archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags'
- reload_cmds='$CC -r -o $output$reload_objs'
- hardcode_direct=no
- ;;
- motorola)
- archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
- hardcode_direct=no #Motorola manual says yes, but my tests say they lie
- ;;
- esac
- runpath_var='LD_RUN_PATH'
- hardcode_shlibpath_var=no
- ;;
-
- sysv4.3*)
- archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
- hardcode_shlibpath_var=no
- export_dynamic_flag_spec='-Bexport'
- ;;
-
- sysv4*MP*)
- if test -d /usr/nec; then
- archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
- hardcode_shlibpath_var=no
- runpath_var=LD_RUN_PATH
- hardcode_runpath_var=yes
- ld_shlibs=yes
- fi
- ;;
-
- sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*)
- no_undefined_flag='${wl}-z,text'
- archive_cmds_need_lc=no
- hardcode_shlibpath_var=no
- runpath_var='LD_RUN_PATH'
-
- if test "$GCC" = yes; then
- archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- else
- archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- fi
- ;;
-
- sysv5* | sco3.2v5* | sco5v6*)
- # Note: We can NOT use -z defs as we might desire, because we do not
- # link with -lc, and that would cause any symbols used from libc to
- # always be unresolved, which means just about no library would
- # ever link correctly. If we're not using GNU ld we use -z text
- # though, which does catch some bad symbols but isn't as heavy-handed
- # as -z defs.
- no_undefined_flag='${wl}-z,text'
- allow_undefined_flag='${wl}-z,nodefs'
- archive_cmds_need_lc=no
- hardcode_shlibpath_var=no
- hardcode_libdir_flag_spec='${wl}-R,$libdir'
- hardcode_libdir_separator=':'
- link_all_deplibs=yes
- export_dynamic_flag_spec='${wl}-Bexport'
- runpath_var='LD_RUN_PATH'
-
- if test "$GCC" = yes; then
- archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- else
- archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- fi
- ;;
-
- uts4*)
- archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
- hardcode_libdir_flag_spec='-L$libdir'
- hardcode_shlibpath_var=no
- ;;
-
- *)
- ld_shlibs=no
- ;;
- esac
-
- if test x$host_vendor = xsni; then
- case $host in
- sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
- export_dynamic_flag_spec='${wl}-Blargedynsym'
- ;;
- esac
- fi
- fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs" >&5
-$as_echo "$ld_shlibs" >&6; }
-test "$ld_shlibs" = no && can_build_shared=no
-
-with_gnu_ld=$with_gnu_ld
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-#
-# Do we need to explicitly link libc?
-#
-case "x$archive_cmds_need_lc" in
-x|xyes)
- # Assume -lc should be added
- archive_cmds_need_lc=yes
-
- if test "$enable_shared" = yes && test "$GCC" = yes; then
- case $archive_cmds in
- *'~'*)
- # FIXME: we may have to deal with multi-command sequences.
- ;;
- '$CC '*)
- # Test whether the compiler implicitly links with -lc since on some
- # systems, -lgcc has to come before -lc. If gcc already passes -lc
- # to ld, don't add -lc before -lgcc.
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5
-$as_echo_n "checking whether -lc should be explicitly linked in... " >&6; }
-if ${lt_cv_archive_cmds_need_lc+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- $RM conftest*
- echo "$lt_simple_compile_test_code" > conftest.$ac_ext
-
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
- (eval $ac_compile) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } 2>conftest.err; then
- soname=conftest
- lib=conftest
- libobjs=conftest.$ac_objext
- deplibs=
- wl=$lt_prog_compiler_wl
- pic_flag=$lt_prog_compiler_pic
- compiler_flags=-v
- linker_flags=-v
- verstring=
- output_objdir=.
- libname=conftest
- lt_save_allow_undefined_flag=$allow_undefined_flag
- allow_undefined_flag=
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5
- (eval $archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }
- then
- lt_cv_archive_cmds_need_lc=no
- else
- lt_cv_archive_cmds_need_lc=yes
- fi
- allow_undefined_flag=$lt_save_allow_undefined_flag
- else
- cat conftest.err 1>&5
- fi
- $RM conftest*
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc" >&5
-$as_echo "$lt_cv_archive_cmds_need_lc" >&6; }
- archive_cmds_need_lc=$lt_cv_archive_cmds_need_lc
- ;;
- esac
- fi
- ;;
-esac
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5
-$as_echo_n "checking dynamic linker characteristics... " >&6; }
-
-if test "$GCC" = yes; then
- case $host_os in
- darwin*) lt_awk_arg="/^libraries:/,/LR/" ;;
- *) lt_awk_arg="/^libraries:/" ;;
- esac
- case $host_os in
- mingw* | cegcc*) lt_sed_strip_eq="s,=\([A-Za-z]:\),\1,g" ;;
- *) lt_sed_strip_eq="s,=/,/,g" ;;
- esac
- lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq`
- case $lt_search_path_spec in
- *\;*)
- # if the path contains ";" then we assume it to be the separator
- # otherwise default to the standard path separator (i.e. ":") - it is
- # assumed that no part of a normal pathname contains ";" but that should
- # okay in the real world where ";" in dirpaths is itself problematic.
- lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'`
- ;;
- *)
- lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"`
- ;;
- esac
- # Ok, now we have the path, separated by spaces, we can step through it
- # and add multilib dir if necessary.
- lt_tmp_lt_search_path_spec=
- lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
- for lt_sys_path in $lt_search_path_spec; do
- if test -d "$lt_sys_path/$lt_multi_os_dir"; then
- lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir"
- else
- test -d "$lt_sys_path" && \
- lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
- fi
- done
- lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk '
-BEGIN {RS=" "; FS="/|\n";} {
- lt_foo="";
- lt_count=0;
- for (lt_i = NF; lt_i > 0; lt_i--) {
- if ($lt_i != "" && $lt_i != ".") {
- if ($lt_i == "..") {
- lt_count++;
- } else {
- if (lt_count == 0) {
- lt_foo="/" $lt_i lt_foo;
- } else {
- lt_count--;
- }
- }
- }
- }
- if (lt_foo != "") { lt_freq[lt_foo]++; }
- if (lt_freq[lt_foo] == 1) { print lt_foo; }
-}'`
- # AWK program above erroneously prepends '/' to C:/dos/paths
- # for these hosts.
- case $host_os in
- mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\
- $SED 's,/\([A-Za-z]:\),\1,g'` ;;
- esac
- sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP`
-else
- sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
-fi
-library_names_spec=
-libname_spec='lib$name'
-soname_spec=
-shrext_cmds=".so"
-postinstall_cmds=
-postuninstall_cmds=
-finish_cmds=
-finish_eval=
-shlibpath_var=
-shlibpath_overrides_runpath=unknown
-version_type=none
-dynamic_linker="$host_os ld.so"
-sys_lib_dlsearch_path_spec="/lib /usr/lib"
-need_lib_prefix=unknown
-hardcode_into_libs=no
-
-# when you set need_version to no, make sure it does not cause -set_version
-# flags to be left without arguments
-need_version=unknown
-
-case $host_os in
-aix3*)
- version_type=linux
- library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
- shlibpath_var=LIBPATH
-
- # AIX 3 has no versioning support, so we append a major version to the name.
- soname_spec='${libname}${release}${shared_ext}$major'
- ;;
-
-aix[4-9]*)
- version_type=linux
- need_lib_prefix=no
- need_version=no
- hardcode_into_libs=yes
- if test "$host_cpu" = ia64; then
- # AIX 5 supports IA64
- library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
- shlibpath_var=LD_LIBRARY_PATH
- else
- # With GCC up to 2.95.x, collect2 would create an import file
- # for dependence libraries. The import file would start with
- # the line `#! .'. This would cause the generated library to
- # depend on `.', always an invalid library. This was fixed in
- # development snapshots of GCC prior to 3.0.
- case $host_os in
- aix4 | aix4.[01] | aix4.[01].*)
- if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
- echo ' yes '
- echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then
- :
- else
- can_build_shared=no
- fi
- ;;
- esac
- # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
- # soname into executable. Probably we can add versioning support to
- # collect2, so additional links can be useful in future.
- if test "$aix_use_runtimelinking" = yes; then
- # If using run time linking (on AIX 4.2 or later) use lib<name>.so
- # instead of lib<name>.a to let people know that these are not
- # typical AIX shared libraries.
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- else
- # We preserve .a as extension for shared libraries through AIX4.2
- # and later when we are not doing run time linking.
- library_names_spec='${libname}${release}.a $libname.a'
- soname_spec='${libname}${release}${shared_ext}$major'
- fi
- shlibpath_var=LIBPATH
- fi
- ;;
-
-amigaos*)
- case $host_cpu in
- powerpc)
- # Since July 2007 AmigaOS4 officially supports .so libraries.
- # When compiling the executable, add -use-dynld -Lsobjs: to the compileline.
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- ;;
- m68k)
- library_names_spec='$libname.ixlibrary $libname.a'
- # Create ${libname}_ixlibrary.a entries in /sys/libs.
- finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done'
- ;;
- esac
- ;;
-
-beos*)
- library_names_spec='${libname}${shared_ext}'
- dynamic_linker="$host_os ld.so"
- shlibpath_var=LIBRARY_PATH
- ;;
-
-bsdi[45]*)
- version_type=linux
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
- shlibpath_var=LD_LIBRARY_PATH
- sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
- sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
- # the default ld.so.conf also contains /usr/contrib/lib and
- # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
- # libtool to hard-code these into programs
- ;;
-
-cygwin* | mingw* | pw32* | cegcc*)
- version_type=windows
- shrext_cmds=".dll"
- need_version=no
- need_lib_prefix=no
-
- case $GCC,$host_os in
- yes,cygwin* | yes,mingw* | yes,pw32* | yes,cegcc*)
- library_names_spec='$libname.dll.a'
- # DLL is installed to $(libdir)/../bin by postinstall_cmds
- postinstall_cmds='base_file=`basename \${file}`~
- dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
- dldir=$destdir/`dirname \$dlpath`~
- test -d \$dldir || mkdir -p \$dldir~
- $install_prog $dir/$dlname \$dldir/$dlname~
- chmod a+x \$dldir/$dlname~
- if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
- eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
- fi'
- postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
- dlpath=$dir/\$dldll~
- $RM \$dlpath'
- shlibpath_overrides_runpath=yes
-
- case $host_os in
- cygwin*)
- # Cygwin DLLs use 'cyg' prefix rather than 'lib'
- soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
-
- sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"
- ;;
- mingw* | cegcc*)
- # MinGW DLLs use traditional 'lib' prefix
- soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
- ;;
- pw32*)
- # pw32 DLLs use 'pw' prefix rather than 'lib'
- library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
- ;;
- esac
- ;;
-
- *)
- library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib'
- ;;
- esac
- dynamic_linker='Win32 ld.exe'
- # FIXME: first we should search . and the directory the executable is in
- shlibpath_var=PATH
- ;;
-
-darwin* | rhapsody*)
- dynamic_linker="$host_os dyld"
- version_type=darwin
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext'
- soname_spec='${libname}${release}${major}$shared_ext'
- shlibpath_overrides_runpath=yes
- shlibpath_var=DYLD_LIBRARY_PATH
- shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
-
- sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"
- sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
- ;;
-
-dgux*)
- version_type=linux
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
- soname_spec='${libname}${release}${shared_ext}$major'
- shlibpath_var=LD_LIBRARY_PATH
- ;;
-
-freebsd* | dragonfly*)
- # DragonFly does not have aout. When/if they implement a new
- # versioning mechanism, adjust this.
- if test -x /usr/bin/objformat; then
- objformat=`/usr/bin/objformat`
- else
- case $host_os in
- freebsd[23].*) objformat=aout ;;
- *) objformat=elf ;;
- esac
- fi
- version_type=freebsd-$objformat
- case $version_type in
- freebsd-elf*)
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
- need_version=no
- need_lib_prefix=no
- ;;
- freebsd-*)
- library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
- need_version=yes
- ;;
- esac
- shlibpath_var=LD_LIBRARY_PATH
- case $host_os in
- freebsd2.*)
- shlibpath_overrides_runpath=yes
- ;;
- freebsd3.[01]* | freebsdelf3.[01]*)
- shlibpath_overrides_runpath=yes
- hardcode_into_libs=yes
- ;;
- freebsd3.[2-9]* | freebsdelf3.[2-9]* | \
- freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1)
- shlibpath_overrides_runpath=no
- hardcode_into_libs=yes
- ;;
- *) # from 4.6 on, and DragonFly
- shlibpath_overrides_runpath=yes
- hardcode_into_libs=yes
- ;;
- esac
- ;;
-
-haiku*)
- version_type=linux
- need_lib_prefix=no
- need_version=no
- dynamic_linker="$host_os runtime_loader"
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- shlibpath_var=LIBRARY_PATH
- shlibpath_overrides_runpath=yes
- sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
- hardcode_into_libs=yes
- ;;
-
-hpux9* | hpux10* | hpux11*)
- # Give a soname corresponding to the major version so that dld.sl refuses to
- # link against other versions.
- version_type=sunos
- need_lib_prefix=no
- need_version=no
- case $host_cpu in
- ia64*)
- shrext_cmds='.so'
- hardcode_into_libs=yes
- dynamic_linker="$host_os dld.so"
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- if test "X$HPUX_IA64_MODE" = X32; then
- sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
- else
- sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
- fi
- sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
- ;;
- hppa*64*)
- shrext_cmds='.sl'
- hardcode_into_libs=yes
- dynamic_linker="$host_os dld.sl"
- shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
- shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
- sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
- ;;
- *)
- shrext_cmds='.sl'
- dynamic_linker="$host_os dld.sl"
- shlibpath_var=SHLIB_PATH
- shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- ;;
- esac
- # HP-UX runs *really* slowly unless shared libraries are mode 555, ...
- postinstall_cmds='chmod 555 $lib'
- # or fails outright, so override atomically:
- install_override_mode=555
- ;;
-
-interix[3-9]*)
- version_type=linux
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=no
- hardcode_into_libs=yes
- ;;
-
-irix5* | irix6* | nonstopux*)
- case $host_os in
- nonstopux*) version_type=nonstopux ;;
- *)
- if test "$lt_cv_prog_gnu_ld" = yes; then
- version_type=linux
- else
- version_type=irix
- fi ;;
- esac
- need_lib_prefix=no
- need_version=no
- soname_spec='${libname}${release}${shared_ext}$major'
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
- case $host_os in
- irix5* | nonstopux*)
- libsuff= shlibsuff=
- ;;
- *)
- case $LD in # libtool.m4 will add one of these switches to LD
- *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
- libsuff= shlibsuff= libmagic=32-bit;;
- *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
- libsuff=32 shlibsuff=N32 libmagic=N32;;
- *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
- libsuff=64 shlibsuff=64 libmagic=64-bit;;
- *) libsuff= shlibsuff= libmagic=never-match;;
- esac
- ;;
- esac
- shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
- shlibpath_overrides_runpath=no
- sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
- sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
- hardcode_into_libs=yes
- ;;
-
-# No shared lib support for Linux oldld, aout, or coff.
-linux*oldld* | linux*aout* | linux*coff*)
- dynamic_linker=no
- ;;
-
-# This must be Linux ELF.
-
-# uclinux* changes (here and below) have been submitted to the libtool
-# project, but have not yet been accepted: they are GCC-local changes
-# for the time being. (See
-# https://lists.gnu.org/archive/html/libtool-patches/2018-05/msg00000.html)
-linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu* | uclinuxfdpiceabi)
- version_type=linux
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=no
-
- # Some binutils ld are patched to set DT_RUNPATH
- if ${lt_cv_shlibpath_overrides_runpath+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_shlibpath_overrides_runpath=no
- save_LDFLAGS=$LDFLAGS
- save_libdir=$libdir
- eval "libdir=/foo; wl=\"$lt_prog_compiler_wl\"; \
- LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec\""
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- if ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then :
- lt_cv_shlibpath_overrides_runpath=yes
-fi
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LDFLAGS=$save_LDFLAGS
- libdir=$save_libdir
-
-fi
-
- shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath
-
- # This implies no fast_install, which is unacceptable.
- # Some rework will be needed to allow for fast_install
- # before this can be enabled.
- hardcode_into_libs=yes
-
- # find out which ABI we are using
- libsuff=
- case "$host_cpu" in
- x86_64*|s390*|powerpc*|ppc*|sparc*)
- echo 'int i;' > conftest.$ac_ext
- if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; then
- case `/usr/bin/file conftest.$ac_objext` in
- *64-bit*)
- libsuff=
- if test x"$sys_lib_search_path_spec" = x"/lib /usr/lib /usr/local/lib"; then
- sys_lib_search_path_spec="/lib${libsuff} /usr/lib${libsuff} /usr/local/lib${libsuff}"
- fi
- sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff}"
- ;;
- *32-bit*)
- libsuff=32
- if test x"$sys_lib_search_path_spec" = x"/lib /usr/lib /usr/local/lib"; then
- sys_lib_search_path_spec="/lib${libsuff} /usr/lib${libsuff} /usr/local/lib${libsuff}"
- fi
- sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff}"
- ;;
- esac
- fi
- rm -rf conftest*
- ;;
- esac
-
- # Append ld.so.conf contents to the search path
- if test -f /etc/ld.so.conf; then
- lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '`
- sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff} $lt_ld_extra"
- fi
-
- # We used to test for /lib/ld.so.1 and disable shared libraries on
- # powerpc, because MkLinux only supported shared libraries with the
- # GNU dynamic linker. Since this was broken with cross compilers,
- # most powerpc-linux boxes support dynamic linking these days and
- # people can always --disable-shared, the test was removed, and we
- # assume the GNU/Linux dynamic linker is in use.
- dynamic_linker='GNU/Linux ld.so'
- ;;
-
-netbsd*)
- version_type=sunos
- need_lib_prefix=no
- need_version=no
- if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
- finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
- dynamic_linker='NetBSD (a.out) ld.so'
- else
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- dynamic_linker='NetBSD ld.elf_so'
- fi
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=yes
- hardcode_into_libs=yes
- ;;
-
-newsos6)
- version_type=linux
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=yes
- ;;
-
-*nto* | *qnx*)
- version_type=qnx
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=no
- hardcode_into_libs=yes
- dynamic_linker='ldqnx.so'
- ;;
-
-openbsd*)
- version_type=sunos
- sys_lib_dlsearch_path_spec="/usr/lib"
- need_lib_prefix=no
- # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
- case $host_os in
- openbsd3.3 | openbsd3.3.*) need_version=yes ;;
- *) need_version=no ;;
- esac
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
- finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
- shlibpath_var=LD_LIBRARY_PATH
- if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
- case $host_os in
- openbsd2.[89] | openbsd2.[89].*)
- shlibpath_overrides_runpath=no
- ;;
- *)
- shlibpath_overrides_runpath=yes
- ;;
- esac
- else
- shlibpath_overrides_runpath=yes
- fi
- ;;
-
-os2*)
- libname_spec='$name'
- shrext_cmds=".dll"
- need_lib_prefix=no
- library_names_spec='$libname${shared_ext} $libname.a'
- dynamic_linker='OS/2 ld.exe'
- shlibpath_var=LIBPATH
- ;;
-
-osf3* | osf4* | osf5*)
- version_type=osf
- need_lib_prefix=no
- need_version=no
- soname_spec='${libname}${release}${shared_ext}$major'
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- shlibpath_var=LD_LIBRARY_PATH
- sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
- sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
- ;;
-
-rdos*)
- dynamic_linker=no
- ;;
-
-solaris*)
- version_type=linux
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=yes
- hardcode_into_libs=yes
- # ldd complains unless libraries are executable
- postinstall_cmds='chmod +x $lib'
- ;;
-
-sunos4*)
- version_type=sunos
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
- finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=yes
- if test "$with_gnu_ld" = yes; then
- need_lib_prefix=no
- fi
- need_version=yes
- ;;
-
-sysv4 | sysv4.3*)
- version_type=linux
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- shlibpath_var=LD_LIBRARY_PATH
- case $host_vendor in
- sni)
- shlibpath_overrides_runpath=no
- need_lib_prefix=no
- runpath_var=LD_RUN_PATH
- ;;
- siemens)
- need_lib_prefix=no
- ;;
- motorola)
- need_lib_prefix=no
- need_version=no
- shlibpath_overrides_runpath=no
- sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
- ;;
- esac
- ;;
-
-sysv4*MP*)
- if test -d /usr/nec ;then
- version_type=linux
- library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
- soname_spec='$libname${shared_ext}.$major'
- shlibpath_var=LD_LIBRARY_PATH
- fi
- ;;
-
-sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
- version_type=freebsd-elf
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=yes
- hardcode_into_libs=yes
- if test "$with_gnu_ld" = yes; then
- sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
- else
- sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
- case $host_os in
- sco3.2v5*)
- sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
- ;;
- esac
- fi
- sys_lib_dlsearch_path_spec='/usr/lib'
- ;;
-
-tpf*)
- # TPF is a cross-target only. Preferred cross-host = GNU/Linux.
- version_type=linux
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=no
- hardcode_into_libs=yes
- ;;
-
-uts4*)
- version_type=linux
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- shlibpath_var=LD_LIBRARY_PATH
- ;;
-
-# Shared libraries for VwWorks, >= 7 only at this stage
-# and (fpic) still incompatible with "large" code models
-# in a few configurations. Only for RTP mode in any case,
-# and upon explicit request at configure time.
-vxworks7*)
- dynamic_linker=no
- case ${with_multisubdir}-${enable_shared} in
- *large*)
- ;;
- *mrtp*-yes)
- version_type=linux
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- dynamic_linker="$host_os module_loader"
- ;;
- esac
- ;;
-*)
- dynamic_linker=no
- ;;
-esac
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5
-$as_echo "$dynamic_linker" >&6; }
-test "$dynamic_linker" = no && can_build_shared=no
-
-variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
-if test "$GCC" = yes; then
- variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
-fi
-
-if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then
- sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec"
-fi
-if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then
- sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec"
-fi
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5
-$as_echo_n "checking how to hardcode library paths into programs... " >&6; }
-hardcode_action=
-if test -n "$hardcode_libdir_flag_spec" ||
- test -n "$runpath_var" ||
- test "X$hardcode_automatic" = "Xyes" ; then
-
- # We can hardcode non-existent directories.
- if test "$hardcode_direct" != no &&
- # If the only mechanism to avoid hardcoding is shlibpath_var, we
- # have to relink, otherwise we might link with an installed library
- # when we should be linking with a yet-to-be-installed one
- ## test "$_LT_TAGVAR(hardcode_shlibpath_var, )" != no &&
- test "$hardcode_minus_L" != no; then
- # Linking always hardcodes the temporary library directory.
- hardcode_action=relink
- else
- # We can link without hardcoding, and we can hardcode nonexisting dirs.
- hardcode_action=immediate
- fi
-else
- # We cannot hardcode anything, or else we can only hardcode existing
- # directories.
- hardcode_action=unsupported
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action" >&5
-$as_echo "$hardcode_action" >&6; }
-
-if test "$hardcode_action" = relink ||
- test "$inherit_rpath" = yes; then
- # Fast installation is not supported
- enable_fast_install=no
-elif test "$shlibpath_overrides_runpath" = yes ||
- test "$enable_shared" = no; then
- # Fast installation is not necessary
- enable_fast_install=needless
-fi
-
-
-
-
-
-
- if test "x$enable_dlopen" != xyes; then
- enable_dlopen=unknown
- enable_dlopen_self=unknown
- enable_dlopen_self_static=unknown
-else
- lt_cv_dlopen=no
- lt_cv_dlopen_libs=
-
- case $host_os in
- beos*)
- lt_cv_dlopen="load_add_on"
- lt_cv_dlopen_libs=
- lt_cv_dlopen_self=yes
- ;;
-
- mingw* | pw32* | cegcc*)
- lt_cv_dlopen="LoadLibrary"
- lt_cv_dlopen_libs=
- ;;
-
- cygwin*)
- lt_cv_dlopen="dlopen"
- lt_cv_dlopen_libs=
- ;;
-
- darwin*)
- # if libdl is installed we need to link against it
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
-$as_echo_n "checking for dlopen in -ldl... " >&6; }
-if ${ac_cv_lib_dl_dlopen+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-ldl $LIBS"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char dlopen ();
-int
-main ()
-{
-return dlopen ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_lib_dl_dlopen=yes
-else
- ac_cv_lib_dl_dlopen=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
-$as_echo "$ac_cv_lib_dl_dlopen" >&6; }
-if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
- lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
-else
-
- lt_cv_dlopen="dyld"
- lt_cv_dlopen_libs=
- lt_cv_dlopen_self=yes
-
-fi
-
- ;;
-
- *)
- ac_fn_c_check_func "$LINENO" "shl_load" "ac_cv_func_shl_load"
-if test "x$ac_cv_func_shl_load" = xyes; then :
- lt_cv_dlopen="shl_load"
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5
-$as_echo_n "checking for shl_load in -ldld... " >&6; }
-if ${ac_cv_lib_dld_shl_load+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-ldld $LIBS"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char shl_load ();
-int
-main ()
-{
-return shl_load ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_lib_dld_shl_load=yes
-else
- ac_cv_lib_dld_shl_load=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5
-$as_echo "$ac_cv_lib_dld_shl_load" >&6; }
-if test "x$ac_cv_lib_dld_shl_load" = xyes; then :
- lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"
-else
- ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen"
-if test "x$ac_cv_func_dlopen" = xyes; then :
- lt_cv_dlopen="dlopen"
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
-$as_echo_n "checking for dlopen in -ldl... " >&6; }
-if ${ac_cv_lib_dl_dlopen+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-ldl $LIBS"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char dlopen ();
-int
-main ()
-{
-return dlopen ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_lib_dl_dlopen=yes
-else
- ac_cv_lib_dl_dlopen=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
-$as_echo "$ac_cv_lib_dl_dlopen" >&6; }
-if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
- lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5
-$as_echo_n "checking for dlopen in -lsvld... " >&6; }
-if ${ac_cv_lib_svld_dlopen+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-lsvld $LIBS"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char dlopen ();
-int
-main ()
-{
-return dlopen ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_lib_svld_dlopen=yes
-else
- ac_cv_lib_svld_dlopen=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5
-$as_echo "$ac_cv_lib_svld_dlopen" >&6; }
-if test "x$ac_cv_lib_svld_dlopen" = xyes; then :
- lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5
-$as_echo_n "checking for dld_link in -ldld... " >&6; }
-if ${ac_cv_lib_dld_dld_link+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-ldld $LIBS"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char dld_link ();
-int
-main ()
-{
-return dld_link ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_lib_dld_dld_link=yes
-else
- ac_cv_lib_dld_dld_link=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_dld_link" >&5
-$as_echo "$ac_cv_lib_dld_dld_link" >&6; }
-if test "x$ac_cv_lib_dld_dld_link" = xyes; then :
- lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"
-fi
-
-
-fi
-
-
-fi
-
-
-fi
-
-
-fi
-
-
-fi
-
- ;;
- esac
-
- if test "x$lt_cv_dlopen" != xno; then
- enable_dlopen=yes
- else
- enable_dlopen=no
- fi
-
- case $lt_cv_dlopen in
- dlopen)
- save_CPPFLAGS="$CPPFLAGS"
- test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
-
- save_LDFLAGS="$LDFLAGS"
- wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
-
- save_LIBS="$LIBS"
- LIBS="$lt_cv_dlopen_libs $LIBS"
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a program can dlopen itself" >&5
-$as_echo_n "checking whether a program can dlopen itself... " >&6; }
-if ${lt_cv_dlopen_self+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test "$cross_compiling" = yes; then :
- lt_cv_dlopen_self=cross
-else
- lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
- lt_status=$lt_dlunknown
- cat > conftest.$ac_ext <<_LT_EOF
-#line 11686 "configure"
-#include "confdefs.h"
-
-#if HAVE_DLFCN_H
-#include <dlfcn.h>
-#endif
-
-#include <stdio.h>
-
-#ifdef RTLD_GLOBAL
-# define LT_DLGLOBAL RTLD_GLOBAL
-#else
-# ifdef DL_GLOBAL
-# define LT_DLGLOBAL DL_GLOBAL
-# else
-# define LT_DLGLOBAL 0
-# endif
-#endif
-
-/* We may have to define LT_DLLAZY_OR_NOW in the command line if we
- find out it does not work in some platform. */
-#ifndef LT_DLLAZY_OR_NOW
-# ifdef RTLD_LAZY
-# define LT_DLLAZY_OR_NOW RTLD_LAZY
-# else
-# ifdef DL_LAZY
-# define LT_DLLAZY_OR_NOW DL_LAZY
-# else
-# ifdef RTLD_NOW
-# define LT_DLLAZY_OR_NOW RTLD_NOW
-# else
-# ifdef DL_NOW
-# define LT_DLLAZY_OR_NOW DL_NOW
-# else
-# define LT_DLLAZY_OR_NOW 0
-# endif
-# endif
-# endif
-# endif
-#endif
-
-/* When -fvisbility=hidden is used, assume the code has been annotated
- correspondingly for the symbols needed. */
-#if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
-void fnord () __attribute__((visibility("default")));
-#endif
-
-void fnord () { int i=42; }
-int main ()
-{
- void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
- int status = $lt_dlunknown;
-
- if (self)
- {
- if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
- else
- {
- if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
- else puts (dlerror ());
- }
- /* dlclose (self); */
- }
- else
- puts (dlerror ());
-
- return status;
-}
-_LT_EOF
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
- (eval $ac_link) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then
- (./conftest; exit; ) >&5 2>/dev/null
- lt_status=$?
- case x$lt_status in
- x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;;
- x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;;
- x$lt_dlunknown|x*) lt_cv_dlopen_self=no ;;
- esac
- else :
- # compilation failed
- lt_cv_dlopen_self=no
- fi
-fi
-rm -fr conftest*
-
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self" >&5
-$as_echo "$lt_cv_dlopen_self" >&6; }
-
- if test "x$lt_cv_dlopen_self" = xyes; then
- wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a statically linked program can dlopen itself" >&5
-$as_echo_n "checking whether a statically linked program can dlopen itself... " >&6; }
-if ${lt_cv_dlopen_self_static+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test "$cross_compiling" = yes; then :
- lt_cv_dlopen_self_static=cross
-else
- lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
- lt_status=$lt_dlunknown
- cat > conftest.$ac_ext <<_LT_EOF
-#line 11792 "configure"
-#include "confdefs.h"
-
-#if HAVE_DLFCN_H
-#include <dlfcn.h>
-#endif
-
-#include <stdio.h>
-
-#ifdef RTLD_GLOBAL
-# define LT_DLGLOBAL RTLD_GLOBAL
-#else
-# ifdef DL_GLOBAL
-# define LT_DLGLOBAL DL_GLOBAL
-# else
-# define LT_DLGLOBAL 0
-# endif
-#endif
-
-/* We may have to define LT_DLLAZY_OR_NOW in the command line if we
- find out it does not work in some platform. */
-#ifndef LT_DLLAZY_OR_NOW
-# ifdef RTLD_LAZY
-# define LT_DLLAZY_OR_NOW RTLD_LAZY
-# else
-# ifdef DL_LAZY
-# define LT_DLLAZY_OR_NOW DL_LAZY
-# else
-# ifdef RTLD_NOW
-# define LT_DLLAZY_OR_NOW RTLD_NOW
-# else
-# ifdef DL_NOW
-# define LT_DLLAZY_OR_NOW DL_NOW
-# else
-# define LT_DLLAZY_OR_NOW 0
-# endif
-# endif
-# endif
-# endif
-#endif
-
-/* When -fvisbility=hidden is used, assume the code has been annotated
- correspondingly for the symbols needed. */
-#if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
-void fnord () __attribute__((visibility("default")));
-#endif
-
-void fnord () { int i=42; }
-int main ()
-{
- void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
- int status = $lt_dlunknown;
-
- if (self)
- {
- if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
- else
- {
- if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
- else puts (dlerror ());
- }
- /* dlclose (self); */
- }
- else
- puts (dlerror ());
-
- return status;
-}
-_LT_EOF
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
- (eval $ac_link) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then
- (./conftest; exit; ) >&5 2>/dev/null
- lt_status=$?
- case x$lt_status in
- x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;;
- x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;;
- x$lt_dlunknown|x*) lt_cv_dlopen_self_static=no ;;
- esac
- else :
- # compilation failed
- lt_cv_dlopen_self_static=no
- fi
-fi
-rm -fr conftest*
-
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self_static" >&5
-$as_echo "$lt_cv_dlopen_self_static" >&6; }
- fi
-
- CPPFLAGS="$save_CPPFLAGS"
- LDFLAGS="$save_LDFLAGS"
- LIBS="$save_LIBS"
- ;;
- esac
-
- case $lt_cv_dlopen_self in
- yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
- *) enable_dlopen_self=unknown ;;
- esac
-
- case $lt_cv_dlopen_self_static in
- yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
- *) enable_dlopen_self_static=unknown ;;
- esac
-fi
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-striplib=
-old_striplib=
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stripping libraries is possible" >&5
-$as_echo_n "checking whether stripping libraries is possible... " >&6; }
-if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then
- test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
- test -z "$striplib" && striplib="$STRIP --strip-unneeded"
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-else
-# FIXME - insert some real tests, host_os isn't really good enough
- case $host_os in
- darwin*)
- if test -n "$STRIP" ; then
- striplib="$STRIP -x"
- old_striplib="$STRIP -S"
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- fi
- ;;
- *)
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- ;;
- esac
-fi
-
-
-
-
-
-
-
-
-
-
-
-
- # Report which library types will actually be built
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libtool supports shared libraries" >&5
-$as_echo_n "checking if libtool supports shared libraries... " >&6; }
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $can_build_shared" >&5
-$as_echo "$can_build_shared" >&6; }
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries" >&5
-$as_echo_n "checking whether to build shared libraries... " >&6; }
- test "$can_build_shared" = "no" && enable_shared=no
-
- # On AIX, shared libraries and static libraries use the same namespace, and
- # are all built from PIC.
- case $host_os in
- aix3*)
- test "$enable_shared" = yes && enable_static=no
- if test -n "$RANLIB"; then
- archive_cmds="$archive_cmds~\$RANLIB \$lib"
- postinstall_cmds='$RANLIB $lib'
- fi
- ;;
-
- aix[4-9]*)
- if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
- test "$enable_shared" = yes && enable_static=no
- fi
- ;;
- esac
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5
-$as_echo "$enable_shared" >&6; }
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build static libraries" >&5
-$as_echo_n "checking whether to build static libraries... " >&6; }
- # Make sure either enable_shared or enable_static is yes.
- test "$enable_shared" = yes || enable_static=yes
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_static" >&5
-$as_echo "$enable_static" >&6; }
-
-
-
-
-fi
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-CC="$lt_save_CC"
-
- if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
- ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) ||
- (test "X$CXX" != "Xg++"))) ; then
- ac_ext=cpp
-ac_cpp='$CXXCPP $CPPFLAGS'
-ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C++ preprocessor" >&5
-$as_echo_n "checking how to run the C++ preprocessor... " >&6; }
-if test -z "$CXXCPP"; then
- if ${ac_cv_prog_CXXCPP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- # Double quotes because CXXCPP needs to be expanded
- for CXXCPP in "$CXX -E" "/lib/cpp"
- do
- ac_preproc_ok=false
-for ac_cxx_preproc_warn_flag in '' yes
-do
- # Use a header file that comes with gcc, so configuring glibc
- # with a fresh cross-compiler works.
- # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
- # <limits.h> exists even on freestanding compilers.
- # On the NeXT, cc -E runs the code through the compiler's parser,
- # not just through cpp. "Syntax error" is here to catch this case.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#ifdef __STDC__
-# include <limits.h>
-#else
-# include <assert.h>
-#endif
- Syntax error
-_ACEOF
-if ac_fn_cxx_try_cpp "$LINENO"; then :
-
-else
- # Broken: fails on valid input.
-continue
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-
- # OK, works on sane cases. Now check whether nonexistent headers
- # can be detected and how.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <ac_nonexistent.h>
-_ACEOF
-if ac_fn_cxx_try_cpp "$LINENO"; then :
- # Broken: success on invalid input.
-continue
-else
- # Passes both tests.
-ac_preproc_ok=:
-break
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-
-done
-# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
-rm -f conftest.i conftest.err conftest.$ac_ext
-if $ac_preproc_ok; then :
- break
-fi
-
- done
- ac_cv_prog_CXXCPP=$CXXCPP
-
-fi
- CXXCPP=$ac_cv_prog_CXXCPP
-else
- ac_cv_prog_CXXCPP=$CXXCPP
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXXCPP" >&5
-$as_echo "$CXXCPP" >&6; }
-ac_preproc_ok=false
-for ac_cxx_preproc_warn_flag in '' yes
-do
- # Use a header file that comes with gcc, so configuring glibc
- # with a fresh cross-compiler works.
- # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
- # <limits.h> exists even on freestanding compilers.
- # On the NeXT, cc -E runs the code through the compiler's parser,
- # not just through cpp. "Syntax error" is here to catch this case.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#ifdef __STDC__
-# include <limits.h>
-#else
-# include <assert.h>
-#endif
- Syntax error
-_ACEOF
-if ac_fn_cxx_try_cpp "$LINENO"; then :
-
-else
- # Broken: fails on valid input.
-continue
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-
- # OK, works on sane cases. Now check whether nonexistent headers
- # can be detected and how.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <ac_nonexistent.h>
-_ACEOF
-if ac_fn_cxx_try_cpp "$LINENO"; then :
- # Broken: success on invalid input.
-continue
-else
- # Passes both tests.
-ac_preproc_ok=:
-break
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-
-done
-# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
-rm -f conftest.i conftest.err conftest.$ac_ext
-if $ac_preproc_ok; then :
-
-else
- { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "C++ preprocessor \"$CXXCPP\" fails sanity check
-See \`config.log' for more details" "$LINENO" 5; }
-fi
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-else
- _lt_caught_CXX_error=yes
-fi
-
-ac_ext=cpp
-ac_cpp='$CXXCPP $CPPFLAGS'
-ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
-
-archive_cmds_need_lc_CXX=no
-allow_undefined_flag_CXX=
-always_export_symbols_CXX=no
-archive_expsym_cmds_CXX=
-compiler_needs_object_CXX=no
-export_dynamic_flag_spec_CXX=
-hardcode_direct_CXX=no
-hardcode_direct_absolute_CXX=no
-hardcode_libdir_flag_spec_CXX=
-hardcode_libdir_flag_spec_ld_CXX=
-hardcode_libdir_separator_CXX=
-hardcode_minus_L_CXX=no
-hardcode_shlibpath_var_CXX=unsupported
-hardcode_automatic_CXX=no
-inherit_rpath_CXX=no
-module_cmds_CXX=
-module_expsym_cmds_CXX=
-link_all_deplibs_CXX=unknown
-old_archive_cmds_CXX=$old_archive_cmds
-reload_flag_CXX=$reload_flag
-reload_cmds_CXX=$reload_cmds
-no_undefined_flag_CXX=
-whole_archive_flag_spec_CXX=
-enable_shared_with_static_runtimes_CXX=no
-
-# Source file extension for C++ test sources.
-ac_ext=cpp
-
-# Object file extension for compiled C++ test sources.
-objext=o
-objext_CXX=$objext
-
-# No sense in running all these tests if we already determined that
-# the CXX compiler isn't working. Some variables (like enable_shared)
-# are currently assumed to apply to all compilers on this platform,
-# and will be corrupted by setting them based on a non-working compiler.
-if test "$_lt_caught_CXX_error" != yes; then
- # Code to be used in simple compile tests
- lt_simple_compile_test_code="int some_variable = 0;"
-
- # Code to be used in simple link tests
- lt_simple_link_test_code='int main(int, char *[]) { return(0); }'
-
- # ltmain only uses $CC for tagged configurations so make sure $CC is set.
-
-
-
-
-
-
-# If no C compiler was specified, use CC.
-LTCC=${LTCC-"$CC"}
-
-# If no C compiler flags were specified, use CFLAGS.
-LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
-
-# Allow CC to be a program name with arguments.
-compiler=$CC
-
-
- # save warnings/boilerplate of simple test code
- ac_outfile=conftest.$ac_objext
-echo "$lt_simple_compile_test_code" >conftest.$ac_ext
-eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
-_lt_compiler_boilerplate=`cat conftest.err`
-$RM conftest*
-
- ac_outfile=conftest.$ac_objext
-echo "$lt_simple_link_test_code" >conftest.$ac_ext
-eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
-_lt_linker_boilerplate=`cat conftest.err`
-$RM -r conftest*
-
-
- # Allow CC to be a program name with arguments.
- lt_save_CC=$CC
- lt_save_LD=$LD
- lt_save_GCC=$GCC
- GCC=$GXX
- lt_save_with_gnu_ld=$with_gnu_ld
- lt_save_path_LD=$lt_cv_path_LD
- if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then
- lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx
- else
- $as_unset lt_cv_prog_gnu_ld
- fi
- if test -n "${lt_cv_path_LDCXX+set}"; then
- lt_cv_path_LD=$lt_cv_path_LDCXX
- else
- $as_unset lt_cv_path_LD
- fi
- test -z "${LDCXX+set}" || LD=$LDCXX
- CC=${CXX-"c++"}
- compiler=$CC
- compiler_CXX=$CC
- for cc_temp in $compiler""; do
- case $cc_temp in
- compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
- distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
- \-*) ;;
- *) break;;
- esac
-done
-cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
-
-
- if test -n "$compiler"; then
- # We don't want -fno-exception when compiling C++ code, so set the
- # no_builtin_flag separately
- if test "$GXX" = yes; then
- lt_prog_compiler_no_builtin_flag_CXX=' -fno-builtin'
- else
- lt_prog_compiler_no_builtin_flag_CXX=
- fi
-
- if test "$GXX" = yes; then
- # Set up default GNU C++ configuration
-
-
-
-# Check whether --with-gnu-ld was given.
-if test "${with_gnu_ld+set}" = set; then :
- withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
-else
- with_gnu_ld=no
-fi
-
-ac_prog=ld
-if test "$GCC" = yes; then
- # Check if gcc -print-prog-name=ld gives a path.
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5
-$as_echo_n "checking for ld used by $CC... " >&6; }
- case $host in
- *-*-mingw*)
- # gcc leaves a trailing carriage return which upsets mingw
- ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
- *)
- ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
- esac
- case $ac_prog in
- # Accept absolute paths.
- [\\/]* | ?:[\\/]*)
- re_direlt='/[^/][^/]*/\.\./'
- # Canonicalize the pathname of ld
- ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'`
- while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do
- ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"`
- done
- test -z "$LD" && LD="$ac_prog"
- ;;
- "")
- # If it fails, then pretend we aren't using GCC.
- ac_prog=ld
- ;;
- *)
- # If it is relative, then search for the first ld in PATH.
- with_gnu_ld=unknown
- ;;
- esac
-elif test "$with_gnu_ld" = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
-$as_echo_n "checking for GNU ld... " >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
-$as_echo_n "checking for non-GNU ld... " >&6; }
-fi
-if ${lt_cv_path_LD+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -z "$LD"; then
- lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH; do
- IFS="$lt_save_ifs"
- test -z "$ac_dir" && ac_dir=.
- if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
- lt_cv_path_LD="$ac_dir/$ac_prog"
- # Check to see if the program is GNU ld. I'd rather use --version,
- # but apparently some variants of GNU ld only accept -v.
- # Break only if it was the GNU/non-GNU ld that we prefer.
- case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
- *GNU* | *'with BFD'*)
- test "$with_gnu_ld" != no && break
- ;;
- *)
- test "$with_gnu_ld" != yes && break
- ;;
- esac
- fi
- done
- IFS="$lt_save_ifs"
-else
- lt_cv_path_LD="$LD" # Let the user override the test with a path.
-fi
-fi
-
-LD="$lt_cv_path_LD"
-if test -n "$LD"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
-$as_echo "$LD" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
-$as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
-if ${lt_cv_prog_gnu_ld+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- # I'd rather use --version here, but apparently some GNU lds only accept -v.
-case `$LD -v 2>&1 </dev/null` in
-*GNU* | *'with BFD'*)
- lt_cv_prog_gnu_ld=yes
- ;;
-*)
- lt_cv_prog_gnu_ld=no
- ;;
-esac
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_gnu_ld" >&5
-$as_echo "$lt_cv_prog_gnu_ld" >&6; }
-with_gnu_ld=$lt_cv_prog_gnu_ld
-
-
-
-
-
-
-
- # Check if GNU C++ uses GNU ld as the underlying linker, since the
- # archiving commands below assume that GNU ld is being used.
- if test "$with_gnu_ld" = yes; then
- archive_cmds_CXX='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
- archive_expsym_cmds_CXX='$CC $pic_flag -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
-
- hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir'
- export_dynamic_flag_spec_CXX='${wl}--export-dynamic'
-
- # If archive_cmds runs LD, not CC, wlarc should be empty
- # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to
- # investigate it a little bit more. (MM)
- wlarc='${wl}'
-
- # ancient GNU ld didn't support --whole-archive et. al.
- if eval "`$CC -print-prog-name=ld` --help 2>&1" |
- $GREP 'no-whole-archive' > /dev/null; then
- whole_archive_flag_spec_CXX="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
- else
- whole_archive_flag_spec_CXX=
- fi
- else
- with_gnu_ld=no
- wlarc=
-
- # A generic and very simple default shared library creation
- # command for GNU C++ for the case where it uses the native
- # linker, instead of GNU ld. If possible, this setting should
- # overridden to take advantage of the native linker features on
- # the platform it is being used on.
- archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
- fi
-
- # Commands to make compiler produce verbose output that lists
- # what "hidden" libraries, object files and flags are used when
- # linking a shared library.
- output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
-
- else
- GXX=no
- with_gnu_ld=no
- wlarc=
- fi
-
- # PORTME: fill in a description of your system's C++ link characteristics
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5
-$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; }
- ld_shlibs_CXX=yes
- case $host_os in
- aix3*)
- # FIXME: insert proper C++ library support
- ld_shlibs_CXX=no
- ;;
- aix[4-9]*)
- if test "$host_cpu" = ia64; then
- # On IA64, the linker does run time linking by default, so we don't
- # have to do anything special.
- aix_use_runtimelinking=no
- exp_sym_flag='-Bexport'
- no_entry_flag=""
- else
- aix_use_runtimelinking=no
-
- # Test if we are trying to use run time linking or normal
- # AIX style linking. If -brtl is somewhere in LDFLAGS, we
- # need to do runtime linking.
- case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*)
- for ld_flag in $LDFLAGS; do
- case $ld_flag in
- *-brtl*)
- aix_use_runtimelinking=yes
- break
- ;;
- esac
- done
- ;;
- esac
-
- exp_sym_flag='-bexport'
- no_entry_flag='-bnoentry'
- fi
-
- # When large executables or shared objects are built, AIX ld can
- # have problems creating the table of contents. If linking a library
- # or program results in "error TOC overflow" add -mminimal-toc to
- # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
- # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
-
- archive_cmds_CXX=''
- hardcode_direct_CXX=yes
- hardcode_direct_absolute_CXX=yes
- hardcode_libdir_separator_CXX=':'
- link_all_deplibs_CXX=yes
- file_list_spec_CXX='${wl}-f,'
-
- if test "$GXX" = yes; then
- case $host_os in aix4.[012]|aix4.[012].*)
- # We only want to do this on AIX 4.2 and lower, the check
- # below for broken collect2 doesn't work under 4.3+
- collect2name=`${CC} -print-prog-name=collect2`
- if test -f "$collect2name" &&
- strings "$collect2name" | $GREP resolve_lib_name >/dev/null
- then
- # We have reworked collect2
- :
- else
- # We have old collect2
- hardcode_direct_CXX=unsupported
- # It fails to find uninstalled libraries when the uninstalled
- # path is not listed in the libpath. Setting hardcode_minus_L
- # to unsupported forces relinking
- hardcode_minus_L_CXX=yes
- hardcode_libdir_flag_spec_CXX='-L$libdir'
- hardcode_libdir_separator_CXX=
- fi
- esac
- shared_flag='-shared'
- if test "$aix_use_runtimelinking" = yes; then
- shared_flag="$shared_flag "'${wl}-G'
- fi
- else
- # not using gcc
- if test "$host_cpu" = ia64; then
- # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
- # chokes on -Wl,-G. The following line is correct:
- shared_flag='-G'
- else
- if test "$aix_use_runtimelinking" = yes; then
- shared_flag='${wl}-G'
- else
- shared_flag='${wl}-bM:SRE'
- fi
- fi
- fi
-
- export_dynamic_flag_spec_CXX='${wl}-bexpall'
- # It seems that -bexpall does not export symbols beginning with
- # underscore (_), so it is better to generate a list of symbols to
- # export.
- always_export_symbols_CXX=yes
- if test "$aix_use_runtimelinking" = yes; then
- # Warning - without using the other runtime loading flags (-brtl),
- # -berok will link without error, but may produce a broken library.
- allow_undefined_flag_CXX='-berok'
- # Determine the default libpath from the value encoded in an empty
- # executable.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_cxx_try_link "$LINENO"; then :
-
-lt_aix_libpath_sed='
- /Import File Strings/,/^$/ {
- /^0/ {
- s/^0 *\(.*\)$/\1/
- p
- }
- }'
-aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
-# Check for a 64-bit object if we didn't find anything.
-if test -z "$aix_libpath"; then
- aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
-fi
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
-
- hardcode_libdir_flag_spec_CXX='${wl}-blibpath:$libdir:'"$aix_libpath"
-
- archive_expsym_cmds_CXX='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
- else
- if test "$host_cpu" = ia64; then
- hardcode_libdir_flag_spec_CXX='${wl}-R $libdir:/usr/lib:/lib'
- allow_undefined_flag_CXX="-z nodefs"
- archive_expsym_cmds_CXX="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols"
- else
- # Determine the default libpath from the value encoded in an
- # empty executable.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_cxx_try_link "$LINENO"; then :
-
-lt_aix_libpath_sed='
- /Import File Strings/,/^$/ {
- /^0/ {
- s/^0 *\(.*\)$/\1/
- p
- }
- }'
-aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
-# Check for a 64-bit object if we didn't find anything.
-if test -z "$aix_libpath"; then
- aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
-fi
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
-
- hardcode_libdir_flag_spec_CXX='${wl}-blibpath:$libdir:'"$aix_libpath"
- # Warning - without using the other run time loading flags,
- # -berok will link without error, but may produce a broken library.
- no_undefined_flag_CXX=' ${wl}-bernotok'
- allow_undefined_flag_CXX=' ${wl}-berok'
- if test "$with_gnu_ld" = yes; then
- # We only use this code for GNU lds that support --whole-archive.
- whole_archive_flag_spec_CXX='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
- else
- # Exported symbols can be pulled into shared objects from archives
- whole_archive_flag_spec_CXX='$convenience'
- fi
- archive_cmds_need_lc_CXX=yes
- # This is similar to how AIX traditionally builds its shared
- # libraries.
- archive_expsym_cmds_CXX="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
- fi
- fi
- ;;
-
- beos*)
- if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
- allow_undefined_flag_CXX=unsupported
- # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
- # support --undefined. This deserves some investigation. FIXME
- archive_cmds_CXX='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- else
- ld_shlibs_CXX=no
- fi
- ;;
-
- chorus*)
- case $cc_basename in
- *)
- # FIXME: insert proper C++ library support
- ld_shlibs_CXX=no
- ;;
- esac
- ;;
-
- cygwin* | mingw* | pw32* | cegcc*)
- # _LT_TAGVAR(hardcode_libdir_flag_spec, CXX) is actually meaningless,
- # as there is no search path for DLLs.
- hardcode_libdir_flag_spec_CXX='-L$libdir'
- export_dynamic_flag_spec_CXX='${wl}--export-all-symbols'
- allow_undefined_flag_CXX=unsupported
- always_export_symbols_CXX=no
- enable_shared_with_static_runtimes_CXX=yes
-
- if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
- archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
- # If the export-symbols file already is a .def file (1st line
- # is EXPORTS), use it as is; otherwise, prepend...
- archive_expsym_cmds_CXX='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
- cp $export_symbols $output_objdir/$soname.def;
- else
- echo EXPORTS > $output_objdir/$soname.def;
- cat $export_symbols >> $output_objdir/$soname.def;
- fi~
- $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
- else
- ld_shlibs_CXX=no
- fi
- ;;
- darwin* | rhapsody*)
-
-
- archive_cmds_need_lc_CXX=no
- hardcode_direct_CXX=no
- hardcode_automatic_CXX=yes
- hardcode_shlibpath_var_CXX=unsupported
- if test "$lt_cv_ld_force_load" = "yes"; then
- whole_archive_flag_spec_CXX='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience ${wl}-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`'
- else
- whole_archive_flag_spec_CXX=''
- fi
- link_all_deplibs_CXX=yes
- allow_undefined_flag_CXX="$_lt_dar_allow_undefined"
- case $cc_basename in
- ifort*) _lt_dar_can_shared=yes ;;
- *) _lt_dar_can_shared=$GCC ;;
- esac
- if test "$_lt_dar_can_shared" = "yes"; then
- output_verbose_link_cmd=func_echo_all
- archive_cmds_CXX="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}"
- module_cmds_CXX="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
- archive_expsym_cmds_CXX="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}"
- module_expsym_cmds_CXX="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}"
- if test "$lt_cv_apple_cc_single_mod" != "yes"; then
- archive_cmds_CXX="\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dsymutil}"
- archive_expsym_cmds_CXX="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dar_export_syms}${_lt_dsymutil}"
- fi
-
- else
- ld_shlibs_CXX=no
- fi
-
- ;;
-
- dgux*)
- case $cc_basename in
- ec++*)
- # FIXME: insert proper C++ library support
- ld_shlibs_CXX=no
- ;;
- ghcx*)
- # Green Hills C++ Compiler
- # FIXME: insert proper C++ library support
- ld_shlibs_CXX=no
- ;;
- *)
- # FIXME: insert proper C++ library support
- ld_shlibs_CXX=no
- ;;
- esac
- ;;
-
- freebsd2.*)
- # C++ shared libraries reported to be fairly broken before
- # switch to ELF
- ld_shlibs_CXX=no
- ;;
-
- freebsd-elf*)
- archive_cmds_need_lc_CXX=no
- ;;
-
- freebsd* | dragonfly*)
- # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF
- # conventions
- ld_shlibs_CXX=yes
- ;;
-
- gnu*)
- ;;
-
- haiku*)
- archive_cmds_CXX='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- link_all_deplibs_CXX=yes
- ;;
-
- hpux9*)
- hardcode_libdir_flag_spec_CXX='${wl}+b ${wl}$libdir'
- hardcode_libdir_separator_CXX=:
- export_dynamic_flag_spec_CXX='${wl}-E'
- hardcode_direct_CXX=yes
- hardcode_minus_L_CXX=yes # Not in the search PATH,
- # but as the default
- # location of the library.
-
- case $cc_basename in
- CC*)
- # FIXME: insert proper C++ library support
- ld_shlibs_CXX=no
- ;;
- aCC*)
- archive_cmds_CXX='$RM $output_objdir/$soname~$CC -b ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
- # Commands to make compiler produce verbose output that lists
- # what "hidden" libraries, object files and flags are used when
- # linking a shared library.
- #
- # There doesn't appear to be a way to prevent this compiler from
- # explicitly linking system object files so we need to strip them
- # from the output so that they don't get included in the library
- # dependencies.
- output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
- ;;
- *)
- if test "$GXX" = yes; then
- archive_cmds_CXX='$RM $output_objdir/$soname~$CC -shared -nostdlib -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
- else
- # FIXME: insert proper C++ library support
- ld_shlibs_CXX=no
- fi
- ;;
- esac
- ;;
-
- hpux10*|hpux11*)
- if test $with_gnu_ld = no; then
- hardcode_libdir_flag_spec_CXX='${wl}+b ${wl}$libdir'
- hardcode_libdir_separator_CXX=:
-
- case $host_cpu in
- hppa*64*|ia64*)
- ;;
- *)
- export_dynamic_flag_spec_CXX='${wl}-E'
- ;;
- esac
- fi
- case $host_cpu in
- hppa*64*|ia64*)
- hardcode_direct_CXX=no
- hardcode_shlibpath_var_CXX=no
- ;;
- *)
- hardcode_direct_CXX=yes
- hardcode_direct_absolute_CXX=yes
- hardcode_minus_L_CXX=yes # Not in the search PATH,
- # but as the default
- # location of the library.
- ;;
- esac
-
- case $cc_basename in
- CC*)
- # FIXME: insert proper C++ library support
- ld_shlibs_CXX=no
- ;;
- aCC*)
- case $host_cpu in
- hppa*64*)
- archive_cmds_CXX='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
- ;;
- ia64*)
- archive_cmds_CXX='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
- ;;
- *)
- archive_cmds_CXX='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
- ;;
- esac
- # Commands to make compiler produce verbose output that lists
- # what "hidden" libraries, object files and flags are used when
- # linking a shared library.
- #
- # There doesn't appear to be a way to prevent this compiler from
- # explicitly linking system object files so we need to strip them
- # from the output so that they don't get included in the library
- # dependencies.
- output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
- ;;
- *)
- if test "$GXX" = yes; then
- if test $with_gnu_ld = no; then
- case $host_cpu in
- hppa*64*)
- archive_cmds_CXX='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
- ;;
- ia64*)
- archive_cmds_CXX='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
- ;;
- *)
- archive_cmds_CXX='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
- ;;
- esac
- fi
- else
- # FIXME: insert proper C++ library support
- ld_shlibs_CXX=no
- fi
- ;;
- esac
- ;;
-
- interix[3-9]*)
- hardcode_direct_CXX=no
- hardcode_shlibpath_var_CXX=no
- hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir'
- export_dynamic_flag_spec_CXX='${wl}-E'
- # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
- # Instead, shared libraries are loaded at an image base (0x10000000 by
- # default) and relocated if they conflict, which is a slow very memory
- # consuming and fragmenting process. To avoid this, we pick a random,
- # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
- # time. Moving up from 0x10000000 also allows more sbrk(2) space.
- archive_cmds_CXX='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
- archive_expsym_cmds_CXX='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
- ;;
- irix5* | irix6*)
- case $cc_basename in
- CC*)
- # SGI C++
- archive_cmds_CXX='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
-
- # Archives containing C++ object files must be created using
- # "CC -ar", where "CC" is the IRIX C++ compiler. This is
- # necessary to make sure instantiated templates are included
- # in the archive.
- old_archive_cmds_CXX='$CC -ar -WR,-u -o $oldlib $oldobjs'
- ;;
- *)
- if test "$GXX" = yes; then
- if test "$with_gnu_ld" = no; then
- archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
- else
- archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` -o $lib'
- fi
- fi
- link_all_deplibs_CXX=yes
- ;;
- esac
- hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir'
- hardcode_libdir_separator_CXX=:
- inherit_rpath_CXX=yes
- ;;
-
- linux* | k*bsd*-gnu | kopensolaris*-gnu)
- case $cc_basename in
- KCC*)
- # Kuck and Associates, Inc. (KAI) C++ Compiler
-
- # KCC will only create a shared library if the output file
- # ends with ".so" (or ".sl" for HP-UX), so rename the library
- # to its proper name (with version) after linking.
- archive_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
- archive_expsym_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib ${wl}-retain-symbols-file,$export_symbols; mv \$templib $lib'
- # Commands to make compiler produce verbose output that lists
- # what "hidden" libraries, object files and flags are used when
- # linking a shared library.
- #
- # There doesn't appear to be a way to prevent this compiler from
- # explicitly linking system object files so we need to strip them
- # from the output so that they don't get included in the library
- # dependencies.
- output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | $GREP "ld"`; rm -f libconftest$shared_ext; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
-
- hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir'
- export_dynamic_flag_spec_CXX='${wl}--export-dynamic'
-
- # Archives containing C++ object files must be created using
- # "CC -Bstatic", where "CC" is the KAI C++ compiler.
- old_archive_cmds_CXX='$CC -Bstatic -o $oldlib $oldobjs'
- ;;
- icpc* | ecpc* )
- # Intel C++
- with_gnu_ld=yes
- # version 8.0 and above of icpc choke on multiply defined symbols
- # if we add $predep_objects and $postdep_objects, however 7.1 and
- # earlier do not add the objects themselves.
- case `$CC -V 2>&1` in
- *"Version 7."*)
- archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
- archive_expsym_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
- ;;
- *) # Version 8.0 or newer
- tmp_idyn=
- case $host_cpu in
- ia64*) tmp_idyn=' -i_dynamic';;
- esac
- archive_cmds_CXX='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- archive_expsym_cmds_CXX='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
- ;;
- esac
- archive_cmds_need_lc_CXX=no
- hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir'
- export_dynamic_flag_spec_CXX='${wl}--export-dynamic'
- whole_archive_flag_spec_CXX='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
- ;;
- pgCC* | pgcpp*)
- # Portland Group C++ compiler
- case `$CC -V` in
- *pgCC\ [1-5].* | *pgcpp\ [1-5].*)
- prelink_cmds_CXX='tpldir=Template.dir~
- rm -rf $tpldir~
- $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~
- compile_command="$compile_command `find $tpldir -name \*.o | sort | $NL2SP`"'
- old_archive_cmds_CXX='tpldir=Template.dir~
- rm -rf $tpldir~
- $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~
- $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | sort | $NL2SP`~
- $RANLIB $oldlib'
- archive_cmds_CXX='tpldir=Template.dir~
- rm -rf $tpldir~
- $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
- $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
- archive_expsym_cmds_CXX='tpldir=Template.dir~
- rm -rf $tpldir~
- $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~
- $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | sort | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib'
- ;;
- *) # Version 6 and above use weak symbols
- archive_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
- archive_expsym_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib'
- ;;
- esac
-
- hardcode_libdir_flag_spec_CXX='${wl}--rpath ${wl}$libdir'
- export_dynamic_flag_spec_CXX='${wl}--export-dynamic'
- whole_archive_flag_spec_CXX='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
- ;;
- cxx*)
- # Compaq C++
- archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
- archive_expsym_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib ${wl}-retain-symbols-file $wl$export_symbols'
-
- runpath_var=LD_RUN_PATH
- hardcode_libdir_flag_spec_CXX='-rpath $libdir'
- hardcode_libdir_separator_CXX=:
-
- # Commands to make compiler produce verbose output that lists
- # what "hidden" libraries, object files and flags are used when
- # linking a shared library.
- #
- # There doesn't appear to be a way to prevent this compiler from
- # explicitly linking system object files so we need to strip them
- # from the output so that they don't get included in the library
- # dependencies.
- output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "X$list" | $Xsed'
- ;;
- xl* | mpixl* | bgxl*)
- # IBM XL 8.0 on PPC, with GNU ld
- hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir'
- export_dynamic_flag_spec_CXX='${wl}--export-dynamic'
- archive_cmds_CXX='$CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- if test "x$supports_anon_versioning" = xyes; then
- archive_expsym_cmds_CXX='echo "{ global:" > $output_objdir/$libname.ver~
- cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
- echo "local: *; };" >> $output_objdir/$libname.ver~
- $CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
- fi
- ;;
- *)
- case `$CC -V 2>&1 | sed 5q` in
- *Sun\ C*)
- # Sun C++ 5.9
- no_undefined_flag_CXX=' -zdefs'
- archive_cmds_CXX='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
- archive_expsym_cmds_CXX='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file ${wl}$export_symbols'
- hardcode_libdir_flag_spec_CXX='-R$libdir'
- whole_archive_flag_spec_CXX='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
- compiler_needs_object_CXX=yes
-
- # Not sure whether something based on
- # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1
- # would be better.
- output_verbose_link_cmd='func_echo_all'
-
- # Archives containing C++ object files must be created using
- # "CC -xar", where "CC" is the Sun C++ compiler. This is
- # necessary to make sure instantiated templates are included
- # in the archive.
- old_archive_cmds_CXX='$CC -xar -o $oldlib $oldobjs'
- ;;
- esac
- ;;
- esac
- ;;
-
- lynxos*)
- # FIXME: insert proper C++ library support
- ld_shlibs_CXX=no
- ;;
-
- m88k*)
- # FIXME: insert proper C++ library support
- ld_shlibs_CXX=no
- ;;
-
- mvs*)
- case $cc_basename in
- cxx*)
- # FIXME: insert proper C++ library support
- ld_shlibs_CXX=no
- ;;
- *)
- # FIXME: insert proper C++ library support
- ld_shlibs_CXX=no
- ;;
- esac
- ;;
-
- netbsd*)
- if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
- archive_cmds_CXX='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags'
- wlarc=
- hardcode_libdir_flag_spec_CXX='-R$libdir'
- hardcode_direct_CXX=yes
- hardcode_shlibpath_var_CXX=no
- fi
- # Workaround some broken pre-1.5 toolchains
- output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"'
- ;;
-
- *nto* | *qnx*)
- ld_shlibs_CXX=yes
- ;;
-
- openbsd2*)
- # C++ shared libraries are fairly broken
- ld_shlibs_CXX=no
- ;;
-
- openbsd*)
- if test -f /usr/libexec/ld.so; then
- hardcode_direct_CXX=yes
- hardcode_shlibpath_var_CXX=no
- hardcode_direct_absolute_CXX=yes
- archive_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
- hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir'
- if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
- archive_expsym_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file,$export_symbols -o $lib'
- export_dynamic_flag_spec_CXX='${wl}-E'
- whole_archive_flag_spec_CXX="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
- fi
- output_verbose_link_cmd=func_echo_all
- else
- ld_shlibs_CXX=no
- fi
- ;;
-
- osf3* | osf4* | osf5*)
- case $cc_basename in
- KCC*)
- # Kuck and Associates, Inc. (KAI) C++ Compiler
-
- # KCC will only create a shared library if the output file
- # ends with ".so" (or ".sl" for HP-UX), so rename the library
- # to its proper name (with version) after linking.
- archive_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo "$lib" | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib'
-
- hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir'
- hardcode_libdir_separator_CXX=:
-
- # Archives containing C++ object files must be created using
- # the KAI C++ compiler.
- case $host in
- osf3*) old_archive_cmds_CXX='$CC -Bstatic -o $oldlib $oldobjs' ;;
- *) old_archive_cmds_CXX='$CC -o $oldlib $oldobjs' ;;
- esac
- ;;
- RCC*)
- # Rational C++ 2.4.1
- # FIXME: insert proper C++ library support
- ld_shlibs_CXX=no
- ;;
- cxx*)
- case $host in
- osf3*)
- allow_undefined_flag_CXX=' ${wl}-expect_unresolved ${wl}\*'
- archive_cmds_CXX='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && func_echo_all "${wl}-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
- hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir'
- ;;
- *)
- allow_undefined_flag_CXX=' -expect_unresolved \*'
- archive_cmds_CXX='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
- archive_expsym_cmds_CXX='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~
- echo "-hidden">> $lib.exp~
- $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname ${wl}-input ${wl}$lib.exp `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~
- $RM $lib.exp'
- hardcode_libdir_flag_spec_CXX='-rpath $libdir'
- ;;
- esac
-
- hardcode_libdir_separator_CXX=:
-
- # Commands to make compiler produce verbose output that lists
- # what "hidden" libraries, object files and flags are used when
- # linking a shared library.
- #
- # There doesn't appear to be a way to prevent this compiler from
- # explicitly linking system object files so we need to strip them
- # from the output so that they don't get included in the library
- # dependencies.
- output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"'
- ;;
- *)
- if test "$GXX" = yes && test "$with_gnu_ld" = no; then
- allow_undefined_flag_CXX=' ${wl}-expect_unresolved ${wl}\*'
- case $host in
- osf3*)
- archive_cmds_CXX='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
- ;;
- *)
- archive_cmds_CXX='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
- ;;
- esac
-
- hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir'
- hardcode_libdir_separator_CXX=:
-
- # Commands to make compiler produce verbose output that lists
- # what "hidden" libraries, object files and flags are used when
- # linking a shared library.
- output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
-
- else
- # FIXME: insert proper C++ library support
- ld_shlibs_CXX=no
- fi
- ;;
- esac
- ;;
-
- psos*)
- # FIXME: insert proper C++ library support
- ld_shlibs_CXX=no
- ;;
-
- sunos4*)
- case $cc_basename in
- CC*)
- # Sun C++ 4.x
- # FIXME: insert proper C++ library support
- ld_shlibs_CXX=no
- ;;
- lcc*)
- # Lucid
- # FIXME: insert proper C++ library support
- ld_shlibs_CXX=no
- ;;
- *)
- # FIXME: insert proper C++ library support
- ld_shlibs_CXX=no
- ;;
- esac
- ;;
-
- solaris*)
- case $cc_basename in
- CC*)
- # Sun C++ 4.2, 5.x and Centerline C++
- archive_cmds_need_lc_CXX=yes
- no_undefined_flag_CXX=' -zdefs'
- archive_cmds_CXX='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
- archive_expsym_cmds_CXX='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
- $CC -G${allow_undefined_flag} ${wl}-M ${wl}$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
-
- hardcode_libdir_flag_spec_CXX='-R$libdir'
- hardcode_shlibpath_var_CXX=no
- case $host_os in
- solaris2.[0-5] | solaris2.[0-5].*) ;;
- *)
- # The compiler driver will combine and reorder linker options,
- # but understands `-z linker_flag'.
- # Supported since Solaris 2.6 (maybe 2.5.1?)
- whole_archive_flag_spec_CXX='-z allextract$convenience -z defaultextract'
- ;;
- esac
- link_all_deplibs_CXX=yes
-
- output_verbose_link_cmd='func_echo_all'
-
- # Archives containing C++ object files must be created using
- # "CC -xar", where "CC" is the Sun C++ compiler. This is
- # necessary to make sure instantiated templates are included
- # in the archive.
- old_archive_cmds_CXX='$CC -xar -o $oldlib $oldobjs'
- ;;
- gcx*)
- # Green Hills C++ Compiler
- archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
-
- # The C++ compiler must be used to create the archive.
- old_archive_cmds_CXX='$CC $LDFLAGS -archive -o $oldlib $oldobjs'
- ;;
- *)
- # GNU C++ compiler with Solaris linker
- if test "$GXX" = yes && test "$with_gnu_ld" = no; then
- no_undefined_flag_CXX=' ${wl}-z ${wl}defs'
- if $CC --version | $GREP -v '^2\.7' > /dev/null; then
- archive_cmds_CXX='$CC -shared -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
- archive_expsym_cmds_CXX='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
- $CC -shared -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
-
- # Commands to make compiler produce verbose output that lists
- # what "hidden" libraries, object files and flags are used when
- # linking a shared library.
- output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
- else
- # g++ 2.7 appears to require `-G' NOT `-shared' on this
- # platform.
- archive_cmds_CXX='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
- archive_expsym_cmds_CXX='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
- $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp'
-
- # Commands to make compiler produce verbose output that lists
- # what "hidden" libraries, object files and flags are used when
- # linking a shared library.
- output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"'
- fi
-
- hardcode_libdir_flag_spec_CXX='${wl}-R $wl$libdir'
- case $host_os in
- solaris2.[0-5] | solaris2.[0-5].*) ;;
- *)
- whole_archive_flag_spec_CXX='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
- ;;
- esac
- fi
- ;;
- esac
- ;;
-
- sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*)
- no_undefined_flag_CXX='${wl}-z,text'
- archive_cmds_need_lc_CXX=no
- hardcode_shlibpath_var_CXX=no
- runpath_var='LD_RUN_PATH'
-
- case $cc_basename in
- CC*)
- archive_cmds_CXX='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- archive_expsym_cmds_CXX='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- ;;
- *)
- archive_cmds_CXX='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- archive_expsym_cmds_CXX='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- ;;
- esac
- ;;
-
- sysv5* | sco3.2v5* | sco5v6*)
- # Note: We can NOT use -z defs as we might desire, because we do not
- # link with -lc, and that would cause any symbols used from libc to
- # always be unresolved, which means just about no library would
- # ever link correctly. If we're not using GNU ld we use -z text
- # though, which does catch some bad symbols but isn't as heavy-handed
- # as -z defs.
- no_undefined_flag_CXX='${wl}-z,text'
- allow_undefined_flag_CXX='${wl}-z,nodefs'
- archive_cmds_need_lc_CXX=no
- hardcode_shlibpath_var_CXX=no
- hardcode_libdir_flag_spec_CXX='${wl}-R,$libdir'
- hardcode_libdir_separator_CXX=':'
- link_all_deplibs_CXX=yes
- export_dynamic_flag_spec_CXX='${wl}-Bexport'
- runpath_var='LD_RUN_PATH'
-
- case $cc_basename in
- CC*)
- archive_cmds_CXX='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- archive_expsym_cmds_CXX='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- old_archive_cmds_CXX='$CC -Tprelink_objects $oldobjs~
- '"$old_archive_cmds_CXX"
- reload_cmds_CXX='$CC -Tprelink_objects $reload_objs~
- '"$reload_cmds_CXX"
- ;;
- *)
- archive_cmds_CXX='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- archive_expsym_cmds_CXX='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- ;;
- esac
- ;;
-
- tandem*)
- case $cc_basename in
- NCC*)
- # NonStop-UX NCC 3.20
- # FIXME: insert proper C++ library support
- ld_shlibs_CXX=no
- ;;
- *)
- # FIXME: insert proper C++ library support
- ld_shlibs_CXX=no
- ;;
- esac
- ;;
-
- vxworks*)
- # For VxWorks ports, we assume the use of a GNU linker with
- # standard elf conventions.
- ld_shlibs_CXX=yes
- ;;
-
- *)
- # FIXME: insert proper C++ library support
- ld_shlibs_CXX=no
- ;;
- esac
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs_CXX" >&5
-$as_echo "$ld_shlibs_CXX" >&6; }
- test "$ld_shlibs_CXX" = no && can_build_shared=no
-
- GCC_CXX="$GXX"
- LD_CXX="$LD"
-
- ## CAVEAT EMPTOR:
- ## There is no encapsulation within the following macros, do not change
- ## the running order or otherwise move them around unless you know exactly
- ## what you are doing...
- # Dependencies to place before and after the object being linked:
-predep_objects_CXX=
-postdep_objects_CXX=
-predeps_CXX=
-postdeps_CXX=
-compiler_lib_search_path_CXX=
-
-cat > conftest.$ac_ext <<_LT_EOF
-class Foo
-{
-public:
- Foo (void) { a = 0; }
-private:
- int a;
-};
-_LT_EOF
-
-if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
- (eval $ac_compile) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- # Parse the compiler output and extract the necessary
- # objects, libraries and library flags.
-
- # Sentinel used to keep track of whether or not we are before
- # the conftest object file.
- pre_test_object_deps_done=no
-
- for p in `eval "$output_verbose_link_cmd"`; do
- case $p in
-
- -L* | -R* | -l*)
- # Some compilers place space between "-{L,R}" and the path.
- # Remove the space.
- if test $p = "-L" ||
- test $p = "-R"; then
- prev=$p
- continue
- else
- prev=
- fi
-
- if test "$pre_test_object_deps_done" = no; then
- case $p in
- -L* | -R*)
- # Internal compiler library paths should come after those
- # provided the user. The postdeps already come after the
- # user supplied libs so there is no need to process them.
- if test -z "$compiler_lib_search_path_CXX"; then
- compiler_lib_search_path_CXX="${prev}${p}"
- else
- compiler_lib_search_path_CXX="${compiler_lib_search_path_CXX} ${prev}${p}"
- fi
- ;;
- # The "-l" case would never come before the object being
- # linked, so don't bother handling this case.
- esac
- else
- if test -z "$postdeps_CXX"; then
- postdeps_CXX="${prev}${p}"
- else
- postdeps_CXX="${postdeps_CXX} ${prev}${p}"
- fi
- fi
- ;;
-
- *.$objext)
- # This assumes that the test object file only shows up
- # once in the compiler output.
- if test "$p" = "conftest.$objext"; then
- pre_test_object_deps_done=yes
- continue
- fi
-
- if test "$pre_test_object_deps_done" = no; then
- if test -z "$predep_objects_CXX"; then
- predep_objects_CXX="$p"
- else
- predep_objects_CXX="$predep_objects_CXX $p"
- fi
- else
- if test -z "$postdep_objects_CXX"; then
- postdep_objects_CXX="$p"
- else
- postdep_objects_CXX="$postdep_objects_CXX $p"
- fi
- fi
- ;;
-
- *) ;; # Ignore the rest.
-
- esac
- done
-
- # Clean up.
- rm -f a.out a.exe
-else
- echo "libtool.m4: error: problem compiling CXX test program"
-fi
-
-$RM -f confest.$objext
-
-# PORTME: override above test on systems where it is broken
-case $host_os in
-interix[3-9]*)
- # Interix 3.5 installs completely hosed .la files for C++, so rather than
- # hack all around it, let's just trust "g++" to DTRT.
- predep_objects_CXX=
- postdep_objects_CXX=
- postdeps_CXX=
- ;;
-
-linux*)
- case `$CC -V 2>&1 | sed 5q` in
- *Sun\ C*)
- # Sun C++ 5.9
-
- # The more standards-conforming stlport4 library is
- # incompatible with the Cstd library. Avoid specifying
- # it if it's in CXXFLAGS. Ignore libCrun as
- # -library=stlport4 depends on it.
- case " $CXX $CXXFLAGS " in
- *" -library=stlport4 "*)
- solaris_use_stlport4=yes
- ;;
- esac
-
- if test "$solaris_use_stlport4" != yes; then
- postdeps_CXX='-library=Cstd -library=Crun'
- fi
- ;;
- esac
- ;;
-
-solaris*)
- case $cc_basename in
- CC*)
- # The more standards-conforming stlport4 library is
- # incompatible with the Cstd library. Avoid specifying
- # it if it's in CXXFLAGS. Ignore libCrun as
- # -library=stlport4 depends on it.
- case " $CXX $CXXFLAGS " in
- *" -library=stlport4 "*)
- solaris_use_stlport4=yes
- ;;
- esac
-
- # Adding this requires a known-good setup of shared libraries for
- # Sun compiler versions before 5.6, else PIC objects from an old
- # archive will be linked into the output, leading to subtle bugs.
- if test "$solaris_use_stlport4" != yes; then
- postdeps_CXX='-library=Cstd -library=Crun'
- fi
- ;;
- esac
- ;;
-esac
-
-
-case " $postdeps_CXX " in
-*" -lc "*) archive_cmds_need_lc_CXX=no ;;
-esac
- compiler_lib_search_dirs_CXX=
-if test -n "${compiler_lib_search_path_CXX}"; then
- compiler_lib_search_dirs_CXX=`echo " ${compiler_lib_search_path_CXX}" | ${SED} -e 's! -L! !g' -e 's!^ !!'`
-fi
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- lt_prog_compiler_wl_CXX=
-lt_prog_compiler_pic_CXX=
-lt_prog_compiler_static_CXX=
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
-$as_echo_n "checking for $compiler option to produce PIC... " >&6; }
-
- # C++ specific cases for pic, static, wl, etc.
- if test "$GXX" = yes; then
- lt_prog_compiler_wl_CXX='-Wl,'
- lt_prog_compiler_static_CXX='-static'
-
- case $host_os in
- aix*)
- # All AIX code is PIC.
- if test "$host_cpu" = ia64; then
- # AIX 5 now supports IA64 processor
- lt_prog_compiler_static_CXX='-Bstatic'
- fi
- lt_prog_compiler_pic_CXX='-fPIC'
- ;;
-
- amigaos*)
- case $host_cpu in
- powerpc)
- # see comment about AmigaOS4 .so support
- lt_prog_compiler_pic_CXX='-fPIC'
- ;;
- m68k)
- # FIXME: we need at least 68020 code to build shared libraries, but
- # adding the `-m68020' flag to GCC prevents building anything better,
- # like `-m68040'.
- lt_prog_compiler_pic_CXX='-m68020 -resident32 -malways-restore-a4'
- ;;
- esac
- ;;
-
- beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
- # PIC is the default for these OSes.
- ;;
- mingw* | cygwin* | os2* | pw32* | cegcc*)
- # This hack is so that the source file can tell whether it is being
- # built for inclusion in a dll (and should export symbols for example).
- # Although the cygwin gcc ignores -fPIC, still need this for old-style
- # (--disable-auto-import) libraries
- lt_prog_compiler_pic_CXX='-DDLL_EXPORT'
- ;;
- darwin* | rhapsody*)
- # PIC is the default on this platform
- # Common symbols not allowed in MH_DYLIB files
- lt_prog_compiler_pic_CXX='-fno-common'
- ;;
- *djgpp*)
- # DJGPP does not support shared libraries at all
- lt_prog_compiler_pic_CXX=
- ;;
- haiku*)
- # PIC is the default for Haiku.
- # The "-static" flag exists, but is broken.
- lt_prog_compiler_static_CXX=
- ;;
- interix[3-9]*)
- # Interix 3.x gcc -fpic/-fPIC options generate broken code.
- # Instead, we relocate shared libraries at runtime.
- ;;
- sysv4*MP*)
- if test -d /usr/nec; then
- lt_prog_compiler_pic_CXX=-Kconform_pic
- fi
- ;;
- hpux*)
- # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
- # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag
- # sets the default TLS model and affects inlining.
- case $host_cpu in
- hppa*64*)
- ;;
- *)
- lt_prog_compiler_pic_CXX='-fPIC'
- ;;
- esac
- ;;
- *qnx* | *nto*)
- # QNX uses GNU C++, but need to define -shared option too, otherwise
- # it will coredump.
- lt_prog_compiler_pic_CXX='-fPIC -shared'
- ;;
- *)
- lt_prog_compiler_pic_CXX='-fPIC'
- ;;
- esac
- else
- case $host_os in
- aix[4-9]*)
- # All AIX code is PIC.
- if test "$host_cpu" = ia64; then
- # AIX 5 now supports IA64 processor
- lt_prog_compiler_static_CXX='-Bstatic'
- else
- lt_prog_compiler_static_CXX='-bnso -bI:/lib/syscalls.exp'
- fi
- ;;
- chorus*)
- case $cc_basename in
- cxch68*)
- # Green Hills C++ Compiler
- # _LT_TAGVAR(lt_prog_compiler_static, CXX)="--no_auto_instantiation -u __main -u __premain -u _abort -r $COOL_DIR/lib/libOrb.a $MVME_DIR/lib/CC/libC.a $MVME_DIR/lib/classix/libcx.s.a"
- ;;
- esac
- ;;
- dgux*)
- case $cc_basename in
- ec++*)
- lt_prog_compiler_pic_CXX='-KPIC'
- ;;
- ghcx*)
- # Green Hills C++ Compiler
- lt_prog_compiler_pic_CXX='-pic'
- ;;
- *)
- ;;
- esac
- ;;
- freebsd* | dragonfly*)
- # FreeBSD uses GNU C++
- ;;
- hpux9* | hpux10* | hpux11*)
- case $cc_basename in
- CC*)
- lt_prog_compiler_wl_CXX='-Wl,'
- lt_prog_compiler_static_CXX='${wl}-a ${wl}archive'
- if test "$host_cpu" != ia64; then
- lt_prog_compiler_pic_CXX='+Z'
- fi
- ;;
- aCC*)
- lt_prog_compiler_wl_CXX='-Wl,'
- lt_prog_compiler_static_CXX='${wl}-a ${wl}archive'
- case $host_cpu in
- hppa*64*|ia64*)
- # +Z the default
- ;;
- *)
- lt_prog_compiler_pic_CXX='+Z'
- ;;
- esac
- ;;
- *)
- ;;
- esac
- ;;
- interix*)
- # This is c89, which is MS Visual C++ (no shared libs)
- # Anyone wants to do a port?
- ;;
- irix5* | irix6* | nonstopux*)
- case $cc_basename in
- CC*)
- lt_prog_compiler_wl_CXX='-Wl,'
- lt_prog_compiler_static_CXX='-non_shared'
- # CC pic flag -KPIC is the default.
- ;;
- *)
- ;;
- esac
- ;;
- linux* | k*bsd*-gnu | kopensolaris*-gnu)
- case $cc_basename in
- KCC*)
- # KAI C++ Compiler
- lt_prog_compiler_wl_CXX='--backend -Wl,'
- lt_prog_compiler_pic_CXX='-fPIC'
- ;;
- ecpc* )
- # old Intel C++ for x86_64 which still supported -KPIC.
- lt_prog_compiler_wl_CXX='-Wl,'
- lt_prog_compiler_pic_CXX='-KPIC'
- lt_prog_compiler_static_CXX='-static'
- ;;
- icpc* )
- # Intel C++, used to be incompatible with GCC.
- # ICC 10 doesn't accept -KPIC any more.
- lt_prog_compiler_wl_CXX='-Wl,'
- lt_prog_compiler_pic_CXX='-fPIC'
- lt_prog_compiler_static_CXX='-static'
- ;;
- pgCC* | pgcpp*)
- # Portland Group C++ compiler
- lt_prog_compiler_wl_CXX='-Wl,'
- lt_prog_compiler_pic_CXX='-fpic'
- lt_prog_compiler_static_CXX='-Bstatic'
- ;;
- cxx*)
- # Compaq C++
- # Make sure the PIC flag is empty. It appears that all Alpha
- # Linux and Compaq Tru64 Unix objects are PIC.
- lt_prog_compiler_pic_CXX=
- lt_prog_compiler_static_CXX='-non_shared'
- ;;
- xlc* | xlC* | bgxl[cC]* | mpixl[cC]*)
- # IBM XL 8.0, 9.0 on PPC and BlueGene
- lt_prog_compiler_wl_CXX='-Wl,'
- lt_prog_compiler_pic_CXX='-qpic'
- lt_prog_compiler_static_CXX='-qstaticlink'
- ;;
- *)
- case `$CC -V 2>&1 | sed 5q` in
- *Sun\ C*)
- # Sun C++ 5.9
- lt_prog_compiler_pic_CXX='-KPIC'
- lt_prog_compiler_static_CXX='-Bstatic'
- lt_prog_compiler_wl_CXX='-Qoption ld '
- ;;
- esac
- ;;
- esac
- ;;
- lynxos*)
- ;;
- m88k*)
- ;;
- mvs*)
- case $cc_basename in
- cxx*)
- lt_prog_compiler_pic_CXX='-W c,exportall'
- ;;
- *)
- ;;
- esac
- ;;
- netbsd*)
- ;;
- *qnx* | *nto*)
- # QNX uses GNU C++, but need to define -shared option too, otherwise
- # it will coredump.
- lt_prog_compiler_pic_CXX='-fPIC -shared'
- ;;
- osf3* | osf4* | osf5*)
- case $cc_basename in
- KCC*)
- lt_prog_compiler_wl_CXX='--backend -Wl,'
- ;;
- RCC*)
- # Rational C++ 2.4.1
- lt_prog_compiler_pic_CXX='-pic'
- ;;
- cxx*)
- # Digital/Compaq C++
- lt_prog_compiler_wl_CXX='-Wl,'
- # Make sure the PIC flag is empty. It appears that all Alpha
- # Linux and Compaq Tru64 Unix objects are PIC.
- lt_prog_compiler_pic_CXX=
- lt_prog_compiler_static_CXX='-non_shared'
- ;;
- *)
- ;;
- esac
- ;;
- psos*)
- ;;
- solaris*)
- case $cc_basename in
- CC*)
- # Sun C++ 4.2, 5.x and Centerline C++
- lt_prog_compiler_pic_CXX='-KPIC'
- lt_prog_compiler_static_CXX='-Bstatic'
- lt_prog_compiler_wl_CXX='-Qoption ld '
- ;;
- gcx*)
- # Green Hills C++ Compiler
- lt_prog_compiler_pic_CXX='-PIC'
- ;;
- *)
- ;;
- esac
- ;;
- sunos4*)
- case $cc_basename in
- CC*)
- # Sun C++ 4.x
- lt_prog_compiler_pic_CXX='-pic'
- lt_prog_compiler_static_CXX='-Bstatic'
- ;;
- lcc*)
- # Lucid
- lt_prog_compiler_pic_CXX='-pic'
- ;;
- *)
- ;;
- esac
- ;;
- sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
- case $cc_basename in
- CC*)
- lt_prog_compiler_wl_CXX='-Wl,'
- lt_prog_compiler_pic_CXX='-KPIC'
- lt_prog_compiler_static_CXX='-Bstatic'
- ;;
- esac
- ;;
- tandem*)
- case $cc_basename in
- NCC*)
- # NonStop-UX NCC 3.20
- lt_prog_compiler_pic_CXX='-KPIC'
- ;;
- *)
- ;;
- esac
- ;;
- vxworks*)
- ;;
- *)
- lt_prog_compiler_can_build_shared_CXX=no
- ;;
- esac
- fi
-
-case $host_os in
- # For platforms which do not support PIC, -DPIC is meaningless:
- *djgpp*)
- lt_prog_compiler_pic_CXX=
- ;;
- *)
- lt_prog_compiler_pic_CXX="$lt_prog_compiler_pic_CXX -DPIC"
- ;;
-esac
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_prog_compiler_pic_CXX" >&5
-$as_echo "$lt_prog_compiler_pic_CXX" >&6; }
-
-
-
-#
-# Check to make sure the PIC flag actually works.
-#
-if test -n "$lt_prog_compiler_pic_CXX"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic_CXX works" >&5
-$as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic_CXX works... " >&6; }
-if ${lt_cv_prog_compiler_pic_works_CXX+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_prog_compiler_pic_works_CXX=no
- ac_outfile=conftest.$ac_objext
- echo "$lt_simple_compile_test_code" > conftest.$ac_ext
- lt_compiler_flag="$lt_prog_compiler_pic_CXX -DPIC"
- # Insert the option either (1) after the last *FLAGS variable, or
- # (2) before a word containing "conftest.", or (3) at the end.
- # Note that $ac_compile itself does not contain backslashes and begins
- # with a dollar sign (not a hyphen), so the echo should work correctly.
- # The option is referenced via a variable to avoid confusing sed.
- lt_compile=`echo "$ac_compile" | $SED \
- -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
- -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
- -e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
- (eval "$lt_compile" 2>conftest.err)
- ac_status=$?
- cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- if (exit $ac_status) && test -s "$ac_outfile"; then
- # The compiler can only warn and ignore the option if not recognized
- # So say no if there are warnings other than the usual output.
- $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
- $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
- if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
- lt_cv_prog_compiler_pic_works_CXX=yes
- fi
- fi
- $RM conftest*
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works_CXX" >&5
-$as_echo "$lt_cv_prog_compiler_pic_works_CXX" >&6; }
-
-if test x"$lt_cv_prog_compiler_pic_works_CXX" = xyes; then
- case $lt_prog_compiler_pic_CXX in
- "" | " "*) ;;
- *) lt_prog_compiler_pic_CXX=" $lt_prog_compiler_pic_CXX" ;;
- esac
-else
- lt_prog_compiler_pic_CXX=
- lt_prog_compiler_can_build_shared_CXX=no
-fi
-
-fi
-
-
-
-#
-# Check to make sure the static flag actually works.
-#
-wl=$lt_prog_compiler_wl_CXX eval lt_tmp_static_flag=\"$lt_prog_compiler_static_CXX\"
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5
-$as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; }
-if ${lt_cv_prog_compiler_static_works_CXX+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_prog_compiler_static_works_CXX=no
- save_LDFLAGS="$LDFLAGS"
- LDFLAGS="$LDFLAGS $lt_tmp_static_flag"
- echo "$lt_simple_link_test_code" > conftest.$ac_ext
- if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
- # The linker can only warn and ignore the option if not recognized
- # So say no if there are warnings
- if test -s conftest.err; then
- # Append any errors to the config.log.
- cat conftest.err 1>&5
- $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
- $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
- if diff conftest.exp conftest.er2 >/dev/null; then
- lt_cv_prog_compiler_static_works_CXX=yes
- fi
- else
- lt_cv_prog_compiler_static_works_CXX=yes
- fi
- fi
- $RM -r conftest*
- LDFLAGS="$save_LDFLAGS"
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works_CXX" >&5
-$as_echo "$lt_cv_prog_compiler_static_works_CXX" >&6; }
-
-if test x"$lt_cv_prog_compiler_static_works_CXX" = xyes; then
- :
-else
- lt_prog_compiler_static_CXX=
-fi
-
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
-$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
-if ${lt_cv_prog_compiler_c_o_CXX+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_prog_compiler_c_o_CXX=no
- $RM -r conftest 2>/dev/null
- mkdir conftest
- cd conftest
- mkdir out
- echo "$lt_simple_compile_test_code" > conftest.$ac_ext
-
- lt_compiler_flag="-o out/conftest2.$ac_objext"
- # Insert the option either (1) after the last *FLAGS variable, or
- # (2) before a word containing "conftest.", or (3) at the end.
- # Note that $ac_compile itself does not contain backslashes and begins
- # with a dollar sign (not a hyphen), so the echo should work correctly.
- lt_compile=`echo "$ac_compile" | $SED \
- -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
- -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
- -e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
- (eval "$lt_compile" 2>out/conftest.err)
- ac_status=$?
- cat out/conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- if (exit $ac_status) && test -s out/conftest2.$ac_objext
- then
- # The compiler can only warn and ignore the option if not recognized
- # So say no if there are warnings
- $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
- $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
- if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
- lt_cv_prog_compiler_c_o_CXX=yes
- fi
- fi
- chmod u+w . 2>&5
- $RM conftest*
- # SGI C++ compiler will create directory out/ii_files/ for
- # template instantiation
- test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
- $RM out/* && rmdir out
- cd ..
- $RM -r conftest
- $RM conftest*
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o_CXX" >&5
-$as_echo "$lt_cv_prog_compiler_c_o_CXX" >&6; }
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
-$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
-if ${lt_cv_prog_compiler_c_o_CXX+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_prog_compiler_c_o_CXX=no
- $RM -r conftest 2>/dev/null
- mkdir conftest
- cd conftest
- mkdir out
- echo "$lt_simple_compile_test_code" > conftest.$ac_ext
-
- lt_compiler_flag="-o out/conftest2.$ac_objext"
- # Insert the option either (1) after the last *FLAGS variable, or
- # (2) before a word containing "conftest.", or (3) at the end.
- # Note that $ac_compile itself does not contain backslashes and begins
- # with a dollar sign (not a hyphen), so the echo should work correctly.
- lt_compile=`echo "$ac_compile" | $SED \
- -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
- -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
- -e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
- (eval "$lt_compile" 2>out/conftest.err)
- ac_status=$?
- cat out/conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- if (exit $ac_status) && test -s out/conftest2.$ac_objext
- then
- # The compiler can only warn and ignore the option if not recognized
- # So say no if there are warnings
- $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
- $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
- if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
- lt_cv_prog_compiler_c_o_CXX=yes
- fi
- fi
- chmod u+w . 2>&5
- $RM conftest*
- # SGI C++ compiler will create directory out/ii_files/ for
- # template instantiation
- test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
- $RM out/* && rmdir out
- cd ..
- $RM -r conftest
- $RM conftest*
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o_CXX" >&5
-$as_echo "$lt_cv_prog_compiler_c_o_CXX" >&6; }
-
-
-
-
-hard_links="nottested"
-if test "$lt_cv_prog_compiler_c_o_CXX" = no && test "$need_locks" != no; then
- # do not overwrite the value of need_locks provided by the user
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5
-$as_echo_n "checking if we can lock with hard links... " >&6; }
- hard_links=yes
- $RM conftest*
- ln conftest.a conftest.b 2>/dev/null && hard_links=no
- touch conftest.a
- ln conftest.a conftest.b 2>&5 || hard_links=no
- ln conftest.a conftest.b 2>/dev/null && hard_links=no
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5
-$as_echo "$hard_links" >&6; }
- if test "$hard_links" = no; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5
-$as_echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;}
- need_locks=warn
- fi
-else
- need_locks=no
-fi
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5
-$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; }
-
- export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
- case $host_os in
- aix[4-9]*)
- # If we're using GNU nm, then we don't want the "-C" option.
- # -C means demangle to AIX nm, but means don't demangle with GNU nm
- # Also, AIX nm treats weak defined symbols like other global defined
- # symbols, whereas GNU nm marks them as "W".
- if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
- export_symbols_cmds_CXX='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
- else
- export_symbols_cmds_CXX='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "L")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
- fi
- ;;
- pw32*)
- export_symbols_cmds_CXX="$ltdll_cmds"
- ;;
- cygwin* | mingw* | cegcc*)
- export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;/^.*[ ]__nm__/s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.* //'\'' | sort | uniq > $export_symbols'
- ;;
- *)
- export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
- ;;
- esac
- exclude_expsyms_CXX='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs_CXX" >&5
-$as_echo "$ld_shlibs_CXX" >&6; }
-test "$ld_shlibs_CXX" = no && can_build_shared=no
-
-with_gnu_ld_CXX=$with_gnu_ld
-
-
-
-
-
-
-#
-# Do we need to explicitly link libc?
-#
-case "x$archive_cmds_need_lc_CXX" in
-x|xyes)
- # Assume -lc should be added
- archive_cmds_need_lc_CXX=yes
-
- if test "$enable_shared" = yes && test "$GCC" = yes; then
- case $archive_cmds_CXX in
- *'~'*)
- # FIXME: we may have to deal with multi-command sequences.
- ;;
- '$CC '*)
- # Test whether the compiler implicitly links with -lc since on some
- # systems, -lgcc has to come before -lc. If gcc already passes -lc
- # to ld, don't add -lc before -lgcc.
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5
-$as_echo_n "checking whether -lc should be explicitly linked in... " >&6; }
-if ${lt_cv_archive_cmds_need_lc_CXX+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- $RM conftest*
- echo "$lt_simple_compile_test_code" > conftest.$ac_ext
-
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
- (eval $ac_compile) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } 2>conftest.err; then
- soname=conftest
- lib=conftest
- libobjs=conftest.$ac_objext
- deplibs=
- wl=$lt_prog_compiler_wl_CXX
- pic_flag=$lt_prog_compiler_pic_CXX
- compiler_flags=-v
- linker_flags=-v
- verstring=
- output_objdir=.
- libname=conftest
- lt_save_allow_undefined_flag=$allow_undefined_flag_CXX
- allow_undefined_flag_CXX=
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds_CXX 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5
- (eval $archive_cmds_CXX 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }
- then
- lt_cv_archive_cmds_need_lc_CXX=no
- else
- lt_cv_archive_cmds_need_lc_CXX=yes
- fi
- allow_undefined_flag_CXX=$lt_save_allow_undefined_flag
- else
- cat conftest.err 1>&5
- fi
- $RM conftest*
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc_CXX" >&5
-$as_echo "$lt_cv_archive_cmds_need_lc_CXX" >&6; }
- archive_cmds_need_lc_CXX=$lt_cv_archive_cmds_need_lc_CXX
- ;;
- esac
- fi
- ;;
-esac
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5
-$as_echo_n "checking dynamic linker characteristics... " >&6; }
-
-library_names_spec=
-libname_spec='lib$name'
-soname_spec=
-shrext_cmds=".so"
-postinstall_cmds=
-postuninstall_cmds=
-finish_cmds=
-finish_eval=
-shlibpath_var=
-shlibpath_overrides_runpath=unknown
-version_type=none
-dynamic_linker="$host_os ld.so"
-sys_lib_dlsearch_path_spec="/lib /usr/lib"
-need_lib_prefix=unknown
-hardcode_into_libs=no
-
-# when you set need_version to no, make sure it does not cause -set_version
-# flags to be left without arguments
-need_version=unknown
-
-case $host_os in
-aix3*)
- version_type=linux
- library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
- shlibpath_var=LIBPATH
-
- # AIX 3 has no versioning support, so we append a major version to the name.
- soname_spec='${libname}${release}${shared_ext}$major'
- ;;
-
-aix[4-9]*)
- version_type=linux
- need_lib_prefix=no
- need_version=no
- hardcode_into_libs=yes
- if test "$host_cpu" = ia64; then
- # AIX 5 supports IA64
- library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
- shlibpath_var=LD_LIBRARY_PATH
- else
- # With GCC up to 2.95.x, collect2 would create an import file
- # for dependence libraries. The import file would start with
- # the line `#! .'. This would cause the generated library to
- # depend on `.', always an invalid library. This was fixed in
- # development snapshots of GCC prior to 3.0.
- case $host_os in
- aix4 | aix4.[01] | aix4.[01].*)
- if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
- echo ' yes '
- echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then
- :
- else
- can_build_shared=no
- fi
- ;;
- esac
- # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
- # soname into executable. Probably we can add versioning support to
- # collect2, so additional links can be useful in future.
- if test "$aix_use_runtimelinking" = yes; then
- # If using run time linking (on AIX 4.2 or later) use lib<name>.so
- # instead of lib<name>.a to let people know that these are not
- # typical AIX shared libraries.
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- else
- # We preserve .a as extension for shared libraries through AIX4.2
- # and later when we are not doing run time linking.
- library_names_spec='${libname}${release}.a $libname.a'
- soname_spec='${libname}${release}${shared_ext}$major'
- fi
- shlibpath_var=LIBPATH
- fi
- ;;
-
-amigaos*)
- case $host_cpu in
- powerpc)
- # Since July 2007 AmigaOS4 officially supports .so libraries.
- # When compiling the executable, add -use-dynld -Lsobjs: to the compileline.
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- ;;
- m68k)
- library_names_spec='$libname.ixlibrary $libname.a'
- # Create ${libname}_ixlibrary.a entries in /sys/libs.
- finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done'
- ;;
- esac
- ;;
-
-beos*)
- library_names_spec='${libname}${shared_ext}'
- dynamic_linker="$host_os ld.so"
- shlibpath_var=LIBRARY_PATH
- ;;
-
-bsdi[45]*)
- version_type=linux
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
- shlibpath_var=LD_LIBRARY_PATH
- sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
- sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
- # the default ld.so.conf also contains /usr/contrib/lib and
- # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
- # libtool to hard-code these into programs
- ;;
-
-cygwin* | mingw* | pw32* | cegcc*)
- version_type=windows
- shrext_cmds=".dll"
- need_version=no
- need_lib_prefix=no
-
- case $GCC,$host_os in
- yes,cygwin* | yes,mingw* | yes,pw32* | yes,cegcc*)
- library_names_spec='$libname.dll.a'
- # DLL is installed to $(libdir)/../bin by postinstall_cmds
- postinstall_cmds='base_file=`basename \${file}`~
- dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
- dldir=$destdir/`dirname \$dlpath`~
- test -d \$dldir || mkdir -p \$dldir~
- $install_prog $dir/$dlname \$dldir/$dlname~
- chmod a+x \$dldir/$dlname~
- if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
- eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
- fi'
- postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
- dlpath=$dir/\$dldll~
- $RM \$dlpath'
- shlibpath_overrides_runpath=yes
-
- case $host_os in
- cygwin*)
- # Cygwin DLLs use 'cyg' prefix rather than 'lib'
- soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
-
- ;;
- mingw* | cegcc*)
- # MinGW DLLs use traditional 'lib' prefix
- soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
- ;;
- pw32*)
- # pw32 DLLs use 'pw' prefix rather than 'lib'
- library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
- ;;
- esac
- ;;
-
- *)
- library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib'
- ;;
- esac
- dynamic_linker='Win32 ld.exe'
- # FIXME: first we should search . and the directory the executable is in
- shlibpath_var=PATH
- ;;
-
-darwin* | rhapsody*)
- dynamic_linker="$host_os dyld"
- version_type=darwin
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext'
- soname_spec='${libname}${release}${major}$shared_ext'
- shlibpath_overrides_runpath=yes
- shlibpath_var=DYLD_LIBRARY_PATH
- shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
-
- sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
- ;;
-
-dgux*)
- version_type=linux
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
- soname_spec='${libname}${release}${shared_ext}$major'
- shlibpath_var=LD_LIBRARY_PATH
- ;;
-
-freebsd* | dragonfly*)
- # DragonFly does not have aout. When/if they implement a new
- # versioning mechanism, adjust this.
- if test -x /usr/bin/objformat; then
- objformat=`/usr/bin/objformat`
- else
- case $host_os in
- freebsd[23].*) objformat=aout ;;
- *) objformat=elf ;;
- esac
- fi
- version_type=freebsd-$objformat
- case $version_type in
- freebsd-elf*)
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
- need_version=no
- need_lib_prefix=no
- ;;
- freebsd-*)
- library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
- need_version=yes
- ;;
- esac
- shlibpath_var=LD_LIBRARY_PATH
- case $host_os in
- freebsd2.*)
- shlibpath_overrides_runpath=yes
- ;;
- freebsd3.[01]* | freebsdelf3.[01]*)
- shlibpath_overrides_runpath=yes
- hardcode_into_libs=yes
- ;;
- freebsd3.[2-9]* | freebsdelf3.[2-9]* | \
- freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1)
- shlibpath_overrides_runpath=no
- hardcode_into_libs=yes
- ;;
- *) # from 4.6 on, and DragonFly
- shlibpath_overrides_runpath=yes
- hardcode_into_libs=yes
- ;;
- esac
- ;;
-
-haiku*)
- version_type=linux
- need_lib_prefix=no
- need_version=no
- dynamic_linker="$host_os runtime_loader"
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- shlibpath_var=LIBRARY_PATH
- shlibpath_overrides_runpath=yes
- sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
- hardcode_into_libs=yes
- ;;
-
-hpux9* | hpux10* | hpux11*)
- # Give a soname corresponding to the major version so that dld.sl refuses to
- # link against other versions.
- version_type=sunos
- need_lib_prefix=no
- need_version=no
- case $host_cpu in
- ia64*)
- shrext_cmds='.so'
- hardcode_into_libs=yes
- dynamic_linker="$host_os dld.so"
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- if test "X$HPUX_IA64_MODE" = X32; then
- sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
- else
- sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
- fi
- sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
- ;;
- hppa*64*)
- shrext_cmds='.sl'
- hardcode_into_libs=yes
- dynamic_linker="$host_os dld.sl"
- shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
- shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
- sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
- ;;
- *)
- shrext_cmds='.sl'
- dynamic_linker="$host_os dld.sl"
- shlibpath_var=SHLIB_PATH
- shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- ;;
- esac
- # HP-UX runs *really* slowly unless shared libraries are mode 555, ...
- postinstall_cmds='chmod 555 $lib'
- # or fails outright, so override atomically:
- install_override_mode=555
- ;;
-
-interix[3-9]*)
- version_type=linux
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=no
- hardcode_into_libs=yes
- ;;
-
-irix5* | irix6* | nonstopux*)
- case $host_os in
- nonstopux*) version_type=nonstopux ;;
- *)
- if test "$lt_cv_prog_gnu_ld" = yes; then
- version_type=linux
- else
- version_type=irix
- fi ;;
- esac
- need_lib_prefix=no
- need_version=no
- soname_spec='${libname}${release}${shared_ext}$major'
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
- case $host_os in
- irix5* | nonstopux*)
- libsuff= shlibsuff=
- ;;
- *)
- case $LD in # libtool.m4 will add one of these switches to LD
- *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
- libsuff= shlibsuff= libmagic=32-bit;;
- *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
- libsuff=32 shlibsuff=N32 libmagic=N32;;
- *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
- libsuff=64 shlibsuff=64 libmagic=64-bit;;
- *) libsuff= shlibsuff= libmagic=never-match;;
- esac
- ;;
- esac
- shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
- shlibpath_overrides_runpath=no
- sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
- sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
- hardcode_into_libs=yes
- ;;
-
-# No shared lib support for Linux oldld, aout, or coff.
-linux*oldld* | linux*aout* | linux*coff*)
- dynamic_linker=no
- ;;
-
-# This must be Linux ELF.
-
-# uclinux* changes (here and below) have been submitted to the libtool
-# project, but have not yet been accepted: they are GCC-local changes
-# for the time being. (See
-# https://lists.gnu.org/archive/html/libtool-patches/2018-05/msg00000.html)
-linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu* | uclinuxfdpiceabi)
- version_type=linux
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=no
-
- # Some binutils ld are patched to set DT_RUNPATH
- if ${lt_cv_shlibpath_overrides_runpath+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_shlibpath_overrides_runpath=no
- save_LDFLAGS=$LDFLAGS
- save_libdir=$libdir
- eval "libdir=/foo; wl=\"$lt_prog_compiler_wl_CXX\"; \
- LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec_CXX\""
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_cxx_try_link "$LINENO"; then :
- if ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then :
- lt_cv_shlibpath_overrides_runpath=yes
-fi
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LDFLAGS=$save_LDFLAGS
- libdir=$save_libdir
-
-fi
-
- shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath
-
- # This implies no fast_install, which is unacceptable.
- # Some rework will be needed to allow for fast_install
- # before this can be enabled.
- hardcode_into_libs=yes
-
- # Append ld.so.conf contents to the search path
- if test -f /etc/ld.so.conf; then
- lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '`
- sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
- fi
-
- # We used to test for /lib/ld.so.1 and disable shared libraries on
- # powerpc, because MkLinux only supported shared libraries with the
- # GNU dynamic linker. Since this was broken with cross compilers,
- # most powerpc-linux boxes support dynamic linking these days and
- # people can always --disable-shared, the test was removed, and we
- # assume the GNU/Linux dynamic linker is in use.
- dynamic_linker='GNU/Linux ld.so'
- ;;
-
-netbsd*)
- version_type=sunos
- need_lib_prefix=no
- need_version=no
- if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
- finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
- dynamic_linker='NetBSD (a.out) ld.so'
- else
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- dynamic_linker='NetBSD ld.elf_so'
- fi
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=yes
- hardcode_into_libs=yes
- ;;
-
-newsos6)
- version_type=linux
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=yes
- ;;
-
-*nto* | *qnx*)
- version_type=qnx
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=no
- hardcode_into_libs=yes
- dynamic_linker='ldqnx.so'
- ;;
-
-openbsd*)
- version_type=sunos
- sys_lib_dlsearch_path_spec="/usr/lib"
- need_lib_prefix=no
- # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
- case $host_os in
- openbsd3.3 | openbsd3.3.*) need_version=yes ;;
- *) need_version=no ;;
- esac
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
- finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
- shlibpath_var=LD_LIBRARY_PATH
- if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
- case $host_os in
- openbsd2.[89] | openbsd2.[89].*)
- shlibpath_overrides_runpath=no
- ;;
- *)
- shlibpath_overrides_runpath=yes
- ;;
- esac
- else
- shlibpath_overrides_runpath=yes
- fi
- ;;
-
-os2*)
- libname_spec='$name'
- shrext_cmds=".dll"
- need_lib_prefix=no
- library_names_spec='$libname${shared_ext} $libname.a'
- dynamic_linker='OS/2 ld.exe'
- shlibpath_var=LIBPATH
- ;;
-
-osf3* | osf4* | osf5*)
- version_type=osf
- need_lib_prefix=no
- need_version=no
- soname_spec='${libname}${release}${shared_ext}$major'
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- shlibpath_var=LD_LIBRARY_PATH
- sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
- sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
- ;;
-
-rdos*)
- dynamic_linker=no
- ;;
-
-solaris*)
- version_type=linux
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=yes
- hardcode_into_libs=yes
- # ldd complains unless libraries are executable
- postinstall_cmds='chmod +x $lib'
- ;;
-
-sunos4*)
- version_type=sunos
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
- finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=yes
- if test "$with_gnu_ld" = yes; then
- need_lib_prefix=no
- fi
- need_version=yes
- ;;
-
-sysv4 | sysv4.3*)
- version_type=linux
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- shlibpath_var=LD_LIBRARY_PATH
- case $host_vendor in
- sni)
- shlibpath_overrides_runpath=no
- need_lib_prefix=no
- runpath_var=LD_RUN_PATH
- ;;
- siemens)
- need_lib_prefix=no
- ;;
- motorola)
- need_lib_prefix=no
- need_version=no
- shlibpath_overrides_runpath=no
- sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
- ;;
- esac
- ;;
-
-sysv4*MP*)
- if test -d /usr/nec ;then
- version_type=linux
- library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
- soname_spec='$libname${shared_ext}.$major'
- shlibpath_var=LD_LIBRARY_PATH
- fi
- ;;
-
-sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
- version_type=freebsd-elf
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=yes
- hardcode_into_libs=yes
- if test "$with_gnu_ld" = yes; then
- sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
- else
- sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
- case $host_os in
- sco3.2v5*)
- sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
- ;;
- esac
- fi
- sys_lib_dlsearch_path_spec='/usr/lib'
- ;;
-
-tpf*)
- # TPF is a cross-target only. Preferred cross-host = GNU/Linux.
- version_type=linux
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=no
- hardcode_into_libs=yes
- ;;
-
-uts4*)
- version_type=linux
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- shlibpath_var=LD_LIBRARY_PATH
- ;;
-
-# Shared libraries for VwWorks, >= 7 only at this stage
-# and (fpic) still incompatible with "large" code models
-# in a few configurations. Only for RTP mode in any case,
-# and upon explicit request at configure time.
-vxworks7*)
- dynamic_linker=no
- case ${with_multisubdir}-${enable_shared} in
- *large*)
- ;;
- *mrtp*-yes)
- version_type=linux
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- dynamic_linker="$host_os module_loader"
- ;;
- esac
- ;;
-*)
- dynamic_linker=no
- ;;
-esac
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5
-$as_echo "$dynamic_linker" >&6; }
-test "$dynamic_linker" = no && can_build_shared=no
-
-variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
-if test "$GCC" = yes; then
- variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
-fi
-
-if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then
- sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec"
-fi
-if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then
- sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec"
-fi
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5
-$as_echo_n "checking how to hardcode library paths into programs... " >&6; }
-hardcode_action_CXX=
-if test -n "$hardcode_libdir_flag_spec_CXX" ||
- test -n "$runpath_var_CXX" ||
- test "X$hardcode_automatic_CXX" = "Xyes" ; then
-
- # We can hardcode non-existent directories.
- if test "$hardcode_direct_CXX" != no &&
- # If the only mechanism to avoid hardcoding is shlibpath_var, we
- # have to relink, otherwise we might link with an installed library
- # when we should be linking with a yet-to-be-installed one
- ## test "$_LT_TAGVAR(hardcode_shlibpath_var, CXX)" != no &&
- test "$hardcode_minus_L_CXX" != no; then
- # Linking always hardcodes the temporary library directory.
- hardcode_action_CXX=relink
- else
- # We can link without hardcoding, and we can hardcode nonexisting dirs.
- hardcode_action_CXX=immediate
- fi
-else
- # We cannot hardcode anything, or else we can only hardcode existing
- # directories.
- hardcode_action_CXX=unsupported
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action_CXX" >&5
-$as_echo "$hardcode_action_CXX" >&6; }
-
-if test "$hardcode_action_CXX" = relink ||
- test "$inherit_rpath_CXX" = yes; then
- # Fast installation is not supported
- enable_fast_install=no
-elif test "$shlibpath_overrides_runpath" = yes ||
- test "$enable_shared" = no; then
- # Fast installation is not necessary
- enable_fast_install=needless
-fi
-
-
-
-
-
-
-
- fi # test -n "$compiler"
-
- CC=$lt_save_CC
- LDCXX=$LD
- LD=$lt_save_LD
- GCC=$lt_save_GCC
- with_gnu_ld=$lt_save_with_gnu_ld
- lt_cv_path_LDCXX=$lt_cv_path_LD
- lt_cv_path_LD=$lt_save_path_LD
- lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld
- lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld
-fi # test "$_lt_caught_CXX_error" != yes
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-
-
-
-
-
-
-
-
-
-
-
-
- ac_config_commands="$ac_config_commands libtool"
-
-
-
-
-# Only expand once:
-
-
-
-# The tests for host and target for $enable_largefile require
-# canonical names.
-
-
-
-# As the $enable_largefile decision depends on --enable-plugins we must set it
-# even in directories otherwise not depending on the $plugins option.
-
-
- maybe_plugins=no
- for ac_header in dlfcn.h
-do :
- ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default
-"
-if test "x$ac_cv_header_dlfcn_h" = xyes; then :
- cat >>confdefs.h <<_ACEOF
-#define HAVE_DLFCN_H 1
-_ACEOF
- maybe_plugins=yes
-fi
-
-done
-
- for ac_header in windows.h
-do :
- ac_fn_c_check_header_compile "$LINENO" "windows.h" "ac_cv_header_windows_h" "$ac_includes_default
-"
-if test "x$ac_cv_header_windows_h" = xyes; then :
- cat >>confdefs.h <<_ACEOF
-#define HAVE_WINDOWS_H 1
-_ACEOF
- maybe_plugins=yes
-fi
-
-done
-
-
- # Check whether --enable-plugins was given.
-if test "${enable_plugins+set}" = set; then :
- enableval=$enable_plugins; case "${enableval}" in
- no) plugins=no ;;
- *) plugins=yes
- if test "$maybe_plugins" != "yes" ; then
- as_fn_error $? "Building with plugin support requires a host that supports dlopen." "$LINENO" 5
- fi ;;
- esac
-else
- plugins=$maybe_plugins
-
-fi
-
- if test "$plugins" = "yes"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing dlsym" >&5
-$as_echo_n "checking for library containing dlsym... " >&6; }
-if ${ac_cv_search_dlsym+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_func_search_save_LIBS=$LIBS
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char dlsym ();
-int
-main ()
-{
-return dlsym ();
- ;
- return 0;
-}
-_ACEOF
-for ac_lib in '' dl; do
- if test -z "$ac_lib"; then
- ac_res="none required"
- else
- ac_res=-l$ac_lib
- LIBS="-l$ac_lib $ac_func_search_save_LIBS"
- fi
- if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_search_dlsym=$ac_res
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext
- if ${ac_cv_search_dlsym+:} false; then :
- break
-fi
-done
-if ${ac_cv_search_dlsym+:} false; then :
-
-else
- ac_cv_search_dlsym=no
-fi
-rm conftest.$ac_ext
-LIBS=$ac_func_search_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_dlsym" >&5
-$as_echo "$ac_cv_search_dlsym" >&6; }
-ac_res=$ac_cv_search_dlsym
-if test "$ac_res" != no; then :
- test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
-
-fi
-
- fi
-
-
-case "${host}" in
- sparc-*-solaris*|i?86-*-solaris*)
- # On native 32-bit Solaris/SPARC and x86, large-file and procfs support
- # were mutually exclusive until Solaris 11.3. Without procfs support,
- # the bfd/ elf module cannot provide certain routines such as
- # elfcore_write_prpsinfo or elfcore_write_prstatus. So unless the user
- # explicitly requested large-file support through the
- # --enable-largefile switch, disable large-file support in favor of
- # procfs support.
- #
- # Check if <sys/procfs.h> is incompatible with large-file support.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#define _FILE_OFFSET_BITS 64
-#define _STRUCTURED_PROC 1
-#include <sys/procfs.h>
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- acx_cv_procfs_lfs=yes
-else
- acx_cv_procfs_lfs=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- #
- # Forcefully disable large-file support only if necessary, gdb is in
- # tree and enabled.
- if test "${target}" = "${host}" -a "$acx_cv_procfs_lfs" = no \
- -a -d $srcdir/../gdb -a "$enable_gdb" != no; then
- : ${enable_largefile="no"}
- if test "$plugins" = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
-plugin support disabled; require large-file support which is incompatible with GDB." >&5
-$as_echo "$as_me: WARNING:
-plugin support disabled; require large-file support which is incompatible with GDB." >&2;}
- plugins=no
- fi
- fi
- #
- # Explicitly undef _FILE_OFFSET_BITS if enable_largefile=no for the
- # benefit of g++ 9+ which predefines it on Solaris.
- if test "$enable_largefile" = no; then
- LARGEFILE_CPPFLAGS="-U_FILE_OFFSET_BITS"
-
- fi
- ;;
-esac
-
-# Check whether --enable-largefile was given.
-if test "${enable_largefile+set}" = set; then :
- enableval=$enable_largefile;
-fi
-
-if test "$enable_largefile" != no; then
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
-$as_echo_n "checking for special C compiler options needed for large files... " >&6; }
-if ${ac_cv_sys_largefile_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_cv_sys_largefile_CC=no
- if test "$GCC" != yes; then
- ac_save_CC=$CC
- while :; do
- # IRIX 6.2 and later do not support large files by default,
- # so use the C compiler's -n32 option if that helps.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <sys/types.h>
- /* Check that off_t can represent 2**63 - 1 correctly.
- We can't simply define LARGE_OFF_T to be 9223372036854775807,
- since some C++ compilers masquerading as C compilers
- incorrectly reject 9223372036854775807. */
-#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
- int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
- && LARGE_OFF_T % 2147483647 == 1)
- ? 1 : -1];
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
- if ac_fn_c_try_compile "$LINENO"; then :
- break
-fi
-rm -f core conftest.err conftest.$ac_objext
- CC="$CC -n32"
- if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_sys_largefile_CC=' -n32'; break
-fi
-rm -f core conftest.err conftest.$ac_objext
- break
- done
- CC=$ac_save_CC
- rm -f conftest.$ac_ext
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
-$as_echo "$ac_cv_sys_largefile_CC" >&6; }
- if test "$ac_cv_sys_largefile_CC" != no; then
- CC=$CC$ac_cv_sys_largefile_CC
- fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
-$as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
-if ${ac_cv_sys_file_offset_bits+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- while :; do
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <sys/types.h>
- /* Check that off_t can represent 2**63 - 1 correctly.
- We can't simply define LARGE_OFF_T to be 9223372036854775807,
- since some C++ compilers masquerading as C compilers
- incorrectly reject 9223372036854775807. */
-#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
- int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
- && LARGE_OFF_T % 2147483647 == 1)
- ? 1 : -1];
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_sys_file_offset_bits=no; break
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#define _FILE_OFFSET_BITS 64
-#include <sys/types.h>
- /* Check that off_t can represent 2**63 - 1 correctly.
- We can't simply define LARGE_OFF_T to be 9223372036854775807,
- since some C++ compilers masquerading as C compilers
- incorrectly reject 9223372036854775807. */
-#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
- int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
- && LARGE_OFF_T % 2147483647 == 1)
- ? 1 : -1];
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_sys_file_offset_bits=64; break
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- ac_cv_sys_file_offset_bits=unknown
- break
-done
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
-$as_echo "$ac_cv_sys_file_offset_bits" >&6; }
-case $ac_cv_sys_file_offset_bits in #(
- no | unknown) ;;
- *)
-cat >>confdefs.h <<_ACEOF
-#define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
-_ACEOF
-;;
-esac
-rm -rf conftest*
- if test $ac_cv_sys_file_offset_bits = unknown; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
-$as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
-if ${ac_cv_sys_large_files+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- while :; do
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <sys/types.h>
- /* Check that off_t can represent 2**63 - 1 correctly.
- We can't simply define LARGE_OFF_T to be 9223372036854775807,
- since some C++ compilers masquerading as C compilers
- incorrectly reject 9223372036854775807. */
-#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
- int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
- && LARGE_OFF_T % 2147483647 == 1)
- ? 1 : -1];
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_sys_large_files=no; break
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#define _LARGE_FILES 1
-#include <sys/types.h>
- /* Check that off_t can represent 2**63 - 1 correctly.
- We can't simply define LARGE_OFF_T to be 9223372036854775807,
- since some C++ compilers masquerading as C compilers
- incorrectly reject 9223372036854775807. */
-#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
- int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
- && LARGE_OFF_T % 2147483647 == 1)
- ? 1 : -1];
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_sys_large_files=1; break
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- ac_cv_sys_large_files=unknown
- break
-done
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
-$as_echo "$ac_cv_sys_large_files" >&6; }
-case $ac_cv_sys_large_files in #(
- no | unknown) ;;
- *)
-cat >>confdefs.h <<_ACEOF
-#define _LARGE_FILES $ac_cv_sys_large_files
-_ACEOF
-;;
-esac
-rm -rf conftest*
- fi
-
-
-fi
-
-
-
-ac_checking=
-. ${srcdir}/../bfd/development.sh
-test "$development" = true && ac_checking=yes
-# Check whether --enable-checking was given.
-if test "${enable_checking+set}" = set; then :
- enableval=$enable_checking; case "${enableval}" in
- no|none) ac_checking= ;;
- *) ac_checking=yes ;;
-esac
-fi
-if test x$ac_checking != x ; then
-
-$as_echo "#define ENABLE_CHECKING 1" >>confdefs.h
-
-fi
-
-
-# Check whether --with-lib-path was given.
-if test "${with_lib_path+set}" = set; then :
- withval=$with_lib_path; LIB_PATH=$withval
-fi
-
-# Check whether --enable-targets was given.
-if test "${enable_targets+set}" = set; then :
- enableval=$enable_targets; case "${enableval}" in
- yes | "") as_fn_error $? "enable-targets option must specify target names or 'all'" "$LINENO" 5
- ;;
- no) enable_targets= ;;
- *) enable_targets=$enableval ;;
-esac
-fi
-
-# Check whether --enable-64-bit-bfd was given.
-if test "${enable_64_bit_bfd+set}" = set; then :
- enableval=$enable_64_bit_bfd; case $enableval in #(
- yes|no) :
- ;; #(
- *) :
- as_fn_error $? "bad value ${enableval} for 64-bit-bfd option" "$LINENO" 5 ;; #(
- *) :
- ;;
-esac
-else
- enable_64_bit_bfd=no
-fi
-
-
-if test "x$enable_64_bit_bfd" = "xno"; then :
- # The cast to long int works around a bug in the HP C Compiler
-# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
-# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
-# This bug is HP SR number 8606223364.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of void *" >&5
-$as_echo_n "checking size of void *... " >&6; }
-if ${ac_cv_sizeof_void_p+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (void *))" "ac_cv_sizeof_void_p" "$ac_includes_default"; then :
-
-else
- if test "$ac_cv_type_void_p" = yes; then
- { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error 77 "cannot compute sizeof (void *)
-See \`config.log' for more details" "$LINENO" 5; }
- else
- ac_cv_sizeof_void_p=0
- fi
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_void_p" >&5
-$as_echo "$ac_cv_sizeof_void_p" >&6; }
-
-
-
-cat >>confdefs.h <<_ACEOF
-#define SIZEOF_VOID_P $ac_cv_sizeof_void_p
-_ACEOF
-
-
- if test "x$ac_cv_sizeof_void_p" = "x8"; then :
- enable_64_bit_bfd=yes
-fi
-
-fi
-
- if test "x$enable_64_bit_bfd" = "xyes"; then
- ENABLE_BFD_64_BIT_TRUE=
- ENABLE_BFD_64_BIT_FALSE='#'
-else
- ENABLE_BFD_64_BIT_TRUE='#'
- ENABLE_BFD_64_BIT_FALSE=
-fi
-
-
-
-
-# Check whether --with-sysroot was given.
-if test "${with_sysroot+set}" = set; then :
- withval=$with_sysroot;
- case ${with_sysroot} in
- yes) TARGET_SYSTEM_ROOT='${exec_prefix}/${target_alias}/sys-root' ;;
- *) TARGET_SYSTEM_ROOT=$with_sysroot ;;
- esac
-
- TARGET_SYSTEM_ROOT_DEFINE='-DTARGET_SYSTEM_ROOT=\"$(TARGET_SYSTEM_ROOT)\"'
- use_sysroot=yes
-
- if test "x$prefix" = xNONE; then
- test_prefix=/usr/local
- else
- test_prefix=$prefix
- fi
- if test "x$exec_prefix" = xNONE; then
- test_exec_prefix=$test_prefix
- else
- test_exec_prefix=$exec_prefix
- fi
- case ${TARGET_SYSTEM_ROOT} in
- "${test_prefix}"|"${test_prefix}/"*|\
- "${test_exec_prefix}"|"${test_exec_prefix}/"*|\
- '${prefix}'|'${prefix}/'*|\
- '${exec_prefix}'|'${exec_prefix}/'*)
- t="$TARGET_SYSTEM_ROOT_DEFINE -DTARGET_SYSTEM_ROOT_RELOCATABLE"
- TARGET_SYSTEM_ROOT_DEFINE="$t"
- ;;
- esac
-
-else
-
- use_sysroot=no
- TARGET_SYSTEM_ROOT=
- TARGET_SYSTEM_ROOT_DEFINE='-DTARGET_SYSTEM_ROOT=\"\"'
-
-fi
-
-
-
-
-
-# Check whether --enable-gold was given.
-if test "${enable_gold+set}" = set; then :
- enableval=$enable_gold; case "${enableval}" in
- default)
- install_as_default=no
- installed_linker=ld.bfd
- ;;
- yes|no)
- install_as_default=yes
- installed_linker=ld.bfd
- ;;
- *)
- as_fn_error $? "invalid --enable-gold argument" "$LINENO" 5
- ;;
- esac
-else
- install_as_default=yes
- installed_linker=ld.bfd
-fi
-
-
-
-
-# Check whether --enable-got was given.
-if test "${enable_got+set}" = set; then :
- enableval=$enable_got; case "${enableval}" in
- target | single | negative | multigot) got_handling=$enableval ;;
- *) as_fn_error $? "bad value ${enableval} for --enable-got option" "$LINENO" 5 ;;
-esac
-else
- got_handling=target
-fi
-
-
-case "${got_handling}" in
- target)
-
-$as_echo "#define GOT_HANDLING_DEFAULT GOT_HANDLING_TARGET_DEFAULT" >>confdefs.h
- ;;
- single)
-
-$as_echo "#define GOT_HANDLING_DEFAULT GOT_HANDLING_SINGLE" >>confdefs.h
- ;;
- negative)
-
-$as_echo "#define GOT_HANDLING_DEFAULT GOT_HANDLING_NEGATIVE" >>confdefs.h
- ;;
- multigot)
-
-$as_echo "#define GOT_HANDLING_DEFAULT GOT_HANDLING_MULTIGOT" >>confdefs.h
- ;;
- *) as_fn_error $? "bad value ${got_handling} for --enable-got option" "$LINENO" 5 ;;
-esac
-
-# PR gas/19109
-# Decide the default method for compressing debug sections.
-ac_default_compressed_debug_sections=unset
-# Provide a configure time option to override our default.
-# Check whether --enable-compressed_debug_sections was given.
-if test "${enable_compressed_debug_sections+set}" = set; then :
- enableval=$enable_compressed_debug_sections; case ,"${enableval}", in
- ,yes, | ,all, | *,ld,*) ac_default_compressed_debug_sections=yes ;;
- ,no, | ,none,) ac_default_compressed_debug_sections=no ;;
-esac
-fi
-
-# Select default compression algorithm.
-ac_default_compressed_debug_sections_algorithm=COMPRESS_DEBUG_GABI_ZLIB
-# Check whether --enable-default_compressed_debug_sections_algorithm was given.
-if test "${enable_default_compressed_debug_sections_algorithm+set}" = set; then :
- enableval=$enable_default_compressed_debug_sections_algorithm; case "${enableval}" in
- zstd) ac_default_compressed_debug_sections_algorithm=COMPRESS_DEBUG_ZSTD ;;
-esac
-fi
-
-# Decide setting DT_RUNPATH instead of DT_RPATH by default
-ac_default_new_dtags=unset
-# Provide a configure time option to override our default.
-# Check whether --enable-new_dtags was given.
-if test "${enable_new_dtags+set}" = set; then :
- enableval=$enable_new_dtags; case "${enableval}" in
- yes) ac_default_new_dtags=1 ;;
- no) ac_default_new_dtags=0 ;;
-esac
-fi
-
-# Decide if -z relro should be enabled in ELF linker by default.
-ac_default_ld_z_relro=unset
-# Provide a configure time option to override our default.
-# Check whether --enable-relro was given.
-if test "${enable_relro+set}" = set; then :
- enableval=$enable_relro; case "${enableval}" in
- yes) ac_default_ld_z_relro=1 ;;
- no) ac_default_ld_z_relro=0 ;;
-esac
-fi
-
-# Decide if DT_TEXTREL check should be enabled in ELF linker.
-ac_default_ld_textrel_check=unset
-# Check whether --enable-textrel-check was given.
-if test "${enable_textrel_check+set}" = set; then :
- enableval=$enable_textrel_check; case "${enableval}" in
- yes|no|warning|error) ac_default_ld_textrel_check=${enableval} ;;
-esac
-fi
-
-
-# Decide if -z separate-code should be enabled in ELF linker by default.
-ac_default_ld_z_separate_code=unset
-# Check whether --enable-separate-code was given.
-if test "${enable_separate_code+set}" = set; then :
- enableval=$enable_separate_code; case "${enableval}" in
- yes) ac_default_ld_z_separate_code=1 ;;
- no) ac_default_ld_z_separate_code=0 ;;
-esac
-fi
-
-
-# Decide if --rosegment should be enabled in the ELF linker by default.
-ac_default_ld_rosegment=unset
-# Check whether --enable-rosegment was given.
-if test "${enable_rosegment+set}" = set; then :
- enableval=$enable_rosegment; case "${enableval}" in
- yes) ac_default_ld_rosegment=1 ;;
- no) ac_default_ld_rosegment=0 ;;
-esac
-fi
-
-
-# Decide if -z mark-plt should be enabled in ELF x86-64 linker by default.
-ac_default_ld_z_mark_plt=unset
-# Check whether --enable-mark-plt was given.
-if test "${enable_mark_plt+set}" = set; then :
- enableval=$enable_mark_plt; case "${enableval}" in
- yes) ac_default_ld_z_mark_plt=1 ;;
- no) ac_default_ld_z_mark_plt=0 ;;
-esac
-fi
-
-
-
-# By default warn when an executable stack is created due to object files
-# requesting such, not when the user specifies -z execstack.
-ac_default_ld_warn_execstack=2
-# Check whether --enable-warn-execstack was given.
-if test "${enable_warn_execstack+set}" = set; then :
- enableval=$enable_warn_execstack; case "${enableval}" in
- yes) ac_default_ld_warn_execstack=1 ;;
- no) ac_default_ld_warn_execstack=0 ;;
-esac
-fi
-
-
-ac_default_ld_error_execstack=0
-# Check whether --enable-error-execstack was given.
-if test "${enable_error_execstack+set}" = set; then :
- enableval=$enable_error_execstack; case "${enableval}" in
- yes) ac_default_ld_error_execstack=1 ;;
- no) ac_default_ld_error_execstack=0 ;;
-esac
-fi
-
-
-ac_default_ld_warn_rwx_segments=unset
-# Check whether --enable-warn-rwx-segments was given.
-if test "${enable_warn_rwx_segments+set}" = set; then :
- enableval=$enable_warn_rwx_segments; case "${enableval}" in
- yes) ac_default_ld_warn_rwx_segments=1 ;;
- no) ac_default_ld_warn_rwx_segments=0 ;;
-esac
-fi
-
-
-ac_default_ld_error_rwx_segments=0
-# Check whether --enable-error-rwx-segments was given.
-if test "${enable_error_rwx_segments+set}" = set; then :
- enableval=$enable_error_rwx_segments; case "${enableval}" in
- yes) ac_default_ld_error_rwx_segments=1 ;;
- no) ac_default_ld_error_rwx_segments=0 ;;
-esac
-fi
-
-
-ac_default_ld_default_execstack=unset
-# Check whether --enable-default-execstack was given.
-if test "${enable_default_execstack+set}" = set; then :
- enableval=$enable_default_execstack; case "${enableval}" in
- yes) ac_default_ld_default_execstack=1 ;;
- no) ac_default_ld_default_execstack=0 ;;
-esac
-fi
-
-
-
-# Decide if --error-handling-script should be supported.
-ac_support_error_handling_script=unset
-# Check whether --enable-error-handling-script was given.
-if test "${enable_error_handling_script+set}" = set; then :
- enableval=$enable_error_handling_script; case "${enableval}" in
- yes) ac_support_error_handling_script=1 ;;
- no) ac_support_error_handling_script=0 ;;
-esac
-fi
-
-
-# Decide which "--hash-style" to use by default
-# Provide a configure time option to override our default.
-# Check whether --enable-default-hash-style was given.
-if test "${enable_default_hash_style+set}" = set; then :
- enableval=$enable_default_hash_style; case "${enable_default_hash_style}" in
- sysv | gnu | both) ;;
- *) as_fn_error $? "bad value ${enable_default_hash_style} for enable-default-hash-style option" "$LINENO" 5 ;;
-esac
-else
- case "${target}" in
- # Enable gnu hash only on GNU targets, but not mips
- mips*-*-*) enable_default_hash_style=sysv ;;
- *-*-gnu* | *-*-linux* | *-*-nacl*) enable_default_hash_style=both ;;
- *) enable_default_hash_style=sysv ;;
-esac
-fi
-
-
-case "${enable_default_hash_style}" in
- sysv | both) ac_default_emit_sysv_hash=1 ;;
- *) ac_default_emit_sysv_hash=0 ;;
-esac
-
-case "${enable_default_hash_style}" in
- gnu | both) ac_default_emit_gnu_hash=1 ;;
- *) ac_default_emit_gnu_hash=0 ;;
-esac
-
-# Check whether --enable-initfini-array was given.
-if test "${enable_initfini_array+set}" = set; then :
- enableval=$enable_initfini_array; case "${enableval}" in
- yes|no) ;;
- *) as_fn_error $? "invalid --enable-initfini-array argument" "$LINENO" 5 ;;
- esac
-else
- enable_initfini_array=yes
-fi
-
-
-if test $enable_initfini_array = yes; then
-
-$as_echo "#define HAVE_INITFINI_ARRAY 1" >>confdefs.h
-
-fi
-
- # Check whether --enable-libctf was given.
-if test "${enable_libctf+set}" = set; then :
- enableval=$enable_libctf;
- case "$enableval" in
- yes|no) ;;
- *) as_fn_error $? "Argument to enable/disable libctf must be yes or no" "$LINENO" 5 ;;
- esac
-
-else
- enable_libctf=yes
-fi
-
-
-if test "${enable_libctf}" = yes; then
-
-$as_echo "#define ENABLE_LIBCTF 1" >>confdefs.h
-
-fi
- if test "${enable_libctf}" = yes; then
- ENABLE_LIBCTF_TRUE=
- ENABLE_LIBCTF_FALSE='#'
-else
- ENABLE_LIBCTF_TRUE='#'
- ENABLE_LIBCTF_FALSE=
-fi
-
-
-
-# Used to validate --package-metadata= input. Disabled by default.
-# Check whether --enable-jansson was given.
-if test "${enable_jansson+set}" = set; then :
- enableval=$enable_jansson; enable_jansson=$enableval
-else
- enable_jansson="no"
-fi
-
-
-if test "x$enable_jansson" != "xno"; then :
-
-pkg_failed=no
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for jansson" >&5
-$as_echo_n "checking for jansson... " >&6; }
-
-if test -n "$JANSSON_CFLAGS"; then
- pkg_cv_JANSSON_CFLAGS="$JANSSON_CFLAGS"
- elif test -n "$PKG_CONFIG"; then
- if test -n "$PKG_CONFIG" && \
- { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"jansson\""; } >&5
- ($PKG_CONFIG --exists --print-errors "jansson") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- pkg_cv_JANSSON_CFLAGS=`$PKG_CONFIG --cflags "jansson" 2>/dev/null`
- test "x$?" != "x0" && pkg_failed=yes
-else
- pkg_failed=yes
-fi
- else
- pkg_failed=untried
-fi
-if test -n "$JANSSON_LIBS"; then
- pkg_cv_JANSSON_LIBS="$JANSSON_LIBS"
- elif test -n "$PKG_CONFIG"; then
- if test -n "$PKG_CONFIG" && \
- { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"jansson\""; } >&5
- ($PKG_CONFIG --exists --print-errors "jansson") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- pkg_cv_JANSSON_LIBS=`$PKG_CONFIG --libs "jansson" 2>/dev/null`
- test "x$?" != "x0" && pkg_failed=yes
-else
- pkg_failed=yes
-fi
- else
- pkg_failed=untried
-fi
-
-if test $pkg_failed = no; then
- pkg_save_LDFLAGS="$LDFLAGS"
- LDFLAGS="$LDFLAGS $pkg_cv_JANSSON_LIBS"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
-
-else
- pkg_failed=yes
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LDFLAGS=$pkg_save_LDFLAGS
-fi
-
-
-
-if test $pkg_failed = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-
-if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
- _pkg_short_errors_supported=yes
-else
- _pkg_short_errors_supported=no
-fi
- if test $_pkg_short_errors_supported = yes; then
- JANSSON_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "jansson" 2>&1`
- else
- JANSSON_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "jansson" 2>&1`
- fi
- # Put the nasty error message in config.log where it belongs
- echo "$JANSSON_PKG_ERRORS" >&5
-
- as_fn_error $? "Cannot find jansson library" "$LINENO" 5
-elif test $pkg_failed = untried; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- as_fn_error $? "Cannot find jansson library" "$LINENO" 5
-else
- JANSSON_CFLAGS=$pkg_cv_JANSSON_CFLAGS
- JANSSON_LIBS=$pkg_cv_JANSSON_LIBS
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-
-
-$as_echo "#define HAVE_JANSSON 1" >>confdefs.h
-
-
-
-
-fi
-
-fi
-
-
-# Set the 'development' global.
-. $srcdir/../bfd/development.sh
-
-# Set acp_cpp_for_build variable
-ac_cpp_for_build="$CC_FOR_BUILD -E $CPPFLAGS_FOR_BUILD"
-
-# Default set of GCC warnings to enable.
-GCC_WARN_CFLAGS="-W -Wall -Wstrict-prototypes -Wmissing-prototypes"
-GCC_WARN_CFLAGS_FOR_BUILD="-W -Wall -Wstrict-prototypes -Wmissing-prototypes"
-
-# Add -Wshadow if the compiler is a sufficiently recent version of GCC.
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-__GNUC__
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "(^[0-3]$|^__GNUC__$)" >/dev/null 2>&1; then :
-
-else
- GCC_WARN_CFLAGS="$GCC_WARN_CFLAGS -Wshadow"
-fi
-rm -f conftest*
-
-
-# Add -Wstack-usage if the compiler is a sufficiently recent version of GCC.
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-__GNUC__
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "(^[0-4]$|^__GNUC__$)" >/dev/null 2>&1; then :
-
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-__clang__
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "^__clang__$" >/dev/null 2>&1; then :
- GCC_WARN_CFLAGS="$GCC_WARN_CFLAGS -Wstack-usage=262144"
-fi
-rm -f conftest*
-
-fi
-rm -f conftest*
-
-
-# Set WARN_WRITE_STRINGS if the compiler supports -Wwrite-strings.
-WARN_WRITE_STRINGS=""
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-__GNUC__
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "(^[0-3]$|^__GNUC__$)" >/dev/null 2>&1; then :
-
-else
- WARN_WRITE_STRINGS="-Wwrite-strings"
-fi
-rm -f conftest*
-
-
-# Verify CC_FOR_BUILD to be compatible with warning flags
-
-# Add -Wshadow if the compiler is a sufficiently recent version of GCC.
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-__GNUC__
-_ACEOF
-if (eval "$ac_cpp_for_build conftest.$ac_ext") 2>&5 |
- $EGREP "(^[0-3]$|^__GNUC__$)" >/dev/null 2>&1; then :
-
-else
- GCC_WARN_CFLAGS_FOR_BUILD="$GCC_WARN_CFLAGS_FOR_BUILD -Wshadow"
-fi
-rm -f conftest*
-
-
-# Add -Wstack-usage if the compiler is a sufficiently recent version of GCC.
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-__GNUC__
-_ACEOF
-if (eval "$ac_cpp_for_build conftest.$ac_ext") 2>&5 |
- $EGREP "(^[0-4]$|^__GNUC__$)" >/dev/null 2>&1; then :
-
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-__clang__
-_ACEOF
-if (eval "$ac_cpp_for_build conftest.$ac_ext") 2>&5 |
- $EGREP "^__clang__$" >/dev/null 2>&1; then :
- GCC_WARN_CFLAGS_FOR_BUILD="$GCC_WARN_CFLAGS_FOR_BUILD -Wstack-usage=262144"
-fi
-rm -f conftest*
-
-fi
-rm -f conftest*
-
-
-# Check whether --enable-werror was given.
-if test "${enable_werror+set}" = set; then :
- enableval=$enable_werror; case "${enableval}" in
- yes | y) ERROR_ON_WARNING="yes" ;;
- no | n) ERROR_ON_WARNING="no" ;;
- *) as_fn_error $? "bad value ${enableval} for --enable-werror" "$LINENO" 5 ;;
- esac
-fi
-
-
-# Disable -Wformat by default when using gcc on mingw
-case "${host}" in
- *-*-mingw32*)
- if test "${GCC}" = yes -a -z "${ERROR_ON_WARNING}" ; then
- GCC_WARN_CFLAGS="$GCC_WARN_CFLAGS -Wno-format"
- GCC_WARN_CFLAGS_FOR_BUILD="$GCC_WARN_CFLAGS_FOR_BUILD -Wno-format"
- fi
- ;;
- *) ;;
-esac
-
-# Enable -Werror by default when using gcc. Turn it off for releases.
-if test "${GCC}" = yes -a -z "${ERROR_ON_WARNING}" -a "$development" = true ; then
- ERROR_ON_WARNING=yes
-fi
-
-NO_WERROR=
-if test "${ERROR_ON_WARNING}" = yes ; then
- GCC_WARN_CFLAGS="$GCC_WARN_CFLAGS -Werror"
- GCC_WARN_CFLAGS_FOR_BUILD="$GCC_WARN_CFLAGS_FOR_BUILD -Werror"
- NO_WERROR="-Wno-error"
-fi
-
-if test "${GCC}" = yes ; then
- WARN_CFLAGS="${GCC_WARN_CFLAGS}"
- WARN_CFLAGS_FOR_BUILD="${GCC_WARN_CFLAGS_FOR_BUILD}"
-fi
-
-# Check whether --enable-build-warnings was given.
-if test "${enable_build_warnings+set}" = set; then :
- enableval=$enable_build_warnings; case "${enableval}" in
- yes) WARN_CFLAGS="${GCC_WARN_CFLAGS}"
- WARN_CFLAGS_FOR_BUILD="${GCC_WARN_CFLAGS_FOR_BUILD}";;
- no) if test "${GCC}" = yes ; then
- WARN_CFLAGS="-w"
- WARN_CFLAGS_FOR_BUILD="-w"
- fi;;
- ,*) t=`echo "${enableval}" | sed -e "s/,/ /g"`
- WARN_CFLAGS="${GCC_WARN_CFLAGS} ${t}"
- WARN_CFLAGS_FOR_BUILD="${GCC_WARN_CFLAGS_FOR_BUILD} ${t}";;
- *,) t=`echo "${enableval}" | sed -e "s/,/ /g"`
- WARN_CFLAGS="${t} ${GCC_WARN_CFLAGS}"
- WARN_CFLAGS_FOR_BUILD="${t} ${GCC_WARN_CFLAGS_FOR_BUILD}";;
- *) WARN_CFLAGS=`echo "${enableval}" | sed -e "s/,/ /g"`
- WARN_CFLAGS_FOR_BUILD=`echo "${enableval}" | sed -e "s/,/ /g"`;;
-esac
-fi
-
-
-if test x"$silent" != x"yes" && test x"$WARN_CFLAGS" != x""; then
- echo "Setting warning flags = $WARN_CFLAGS" 6>&1
-fi
-
-
-
-
-
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LC_MESSAGES" >&5
-$as_echo_n "checking for LC_MESSAGES... " >&6; }
-if ${am_cv_val_LC_MESSAGES+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <locale.h>
-int
-main ()
-{
-return LC_MESSAGES
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- am_cv_val_LC_MESSAGES=yes
-else
- am_cv_val_LC_MESSAGES=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_val_LC_MESSAGES" >&5
-$as_echo "$am_cv_val_LC_MESSAGES" >&6; }
- if test $am_cv_val_LC_MESSAGES = yes; then
-
-$as_echo "#define HAVE_LC_MESSAGES 1" >>confdefs.h
-
- fi
-
-
-ac_config_headers="$ac_config_headers config.h:config.in"
-
-
-# PR 14072
-
-
-if test -z "$target" ; then
- as_fn_error $? "Unrecognized target system type; please check config.sub." "$LINENO" 5
-fi
-if test -z "$host" ; then
- as_fn_error $? "Unrecognized host system type; please check config.sub." "$LINENO" 5
-fi
-
-# host-specific stuff:
-
-ALL_LINGUAS="bg da de es fi fr ga id it ja pt_BR ru sr sv tr uk vi zh_CN zh_TW"
-
- MKINSTALLDIRS=
- if test -n "$ac_aux_dir"; then
- case "$ac_aux_dir" in
- /*) MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs" ;;
- *) MKINSTALLDIRS="\$(top_builddir)/$ac_aux_dir/mkinstalldirs" ;;
- esac
- fi
- if test -z "$MKINSTALLDIRS"; then
- MKINSTALLDIRS="\$(top_srcdir)/mkinstalldirs"
- fi
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NLS is requested" >&5
-$as_echo_n "checking whether NLS is requested... " >&6; }
- # Check whether --enable-nls was given.
-if test "${enable_nls+set}" = set; then :
- enableval=$enable_nls; USE_NLS=$enableval
-else
- USE_NLS=yes
-fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_NLS" >&5
-$as_echo "$USE_NLS" >&6; }
-
-
-
-
-
-
-# Prepare PATH_SEPARATOR.
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-
-# Find out how to test for executable files. Don't use a zero-byte file,
-# as systems may use methods other than mode bits to determine executability.
-cat >conf$$.file <<_ASEOF
-#! /bin/sh
-exit 0
-_ASEOF
-chmod +x conf$$.file
-if test -x conf$$.file >/dev/null 2>&1; then
- ac_executable_p="test -x"
-else
- ac_executable_p="test -f"
-fi
-rm -f conf$$.file
-
-# Extract the first word of "msgfmt", so it can be a program name with args.
-set dummy msgfmt; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_MSGFMT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case "$MSGFMT" in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
- ;;
- *)
- ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH; do
- IFS="$ac_save_IFS"
- test -z "$ac_dir" && ac_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
- if $ac_dir/$ac_word --statistics /dev/null >/dev/null 2>&1 &&
- (if $ac_dir/$ac_word --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- ac_cv_path_MSGFMT="$ac_dir/$ac_word$ac_exec_ext"
- break 2
- fi
- fi
- done
- done
- IFS="$ac_save_IFS"
- test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT=":"
- ;;
-esac
-fi
-MSGFMT="$ac_cv_path_MSGFMT"
-if test "$MSGFMT" != ":"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGFMT" >&5
-$as_echo "$MSGFMT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- # Extract the first word of "gmsgfmt", so it can be a program name with args.
-set dummy gmsgfmt; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_GMSGFMT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $GMSGFMT in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
- ;;
- *)
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_path_GMSGFMT="$as_dir/$ac_word$ac_exec_ext"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
- test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT"
- ;;
-esac
-fi
-GMSGFMT=$ac_cv_path_GMSGFMT
-if test -n "$GMSGFMT"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GMSGFMT" >&5
-$as_echo "$GMSGFMT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-
-
-# Prepare PATH_SEPARATOR.
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-
-# Find out how to test for executable files. Don't use a zero-byte file,
-# as systems may use methods other than mode bits to determine executability.
-cat >conf$$.file <<_ASEOF
-#! /bin/sh
-exit 0
-_ASEOF
-chmod +x conf$$.file
-if test -x conf$$.file >/dev/null 2>&1; then
- ac_executable_p="test -x"
-else
- ac_executable_p="test -f"
-fi
-rm -f conf$$.file
-
-# Extract the first word of "xgettext", so it can be a program name with args.
-set dummy xgettext; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_XGETTEXT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case "$XGETTEXT" in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
- ;;
- *)
- ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH; do
- IFS="$ac_save_IFS"
- test -z "$ac_dir" && ac_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
- if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >/dev/null 2>&1 &&
- (if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- ac_cv_path_XGETTEXT="$ac_dir/$ac_word$ac_exec_ext"
- break 2
- fi
- fi
- done
- done
- IFS="$ac_save_IFS"
- test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":"
- ;;
-esac
-fi
-XGETTEXT="$ac_cv_path_XGETTEXT"
-if test "$XGETTEXT" != ":"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XGETTEXT" >&5
-$as_echo "$XGETTEXT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- rm -f messages.po
-
-
-# Prepare PATH_SEPARATOR.
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-
-# Find out how to test for executable files. Don't use a zero-byte file,
-# as systems may use methods other than mode bits to determine executability.
-cat >conf$$.file <<_ASEOF
-#! /bin/sh
-exit 0
-_ASEOF
-chmod +x conf$$.file
-if test -x conf$$.file >/dev/null 2>&1; then
- ac_executable_p="test -x"
-else
- ac_executable_p="test -f"
-fi
-rm -f conf$$.file
-
-# Extract the first word of "msgmerge", so it can be a program name with args.
-set dummy msgmerge; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_MSGMERGE+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case "$MSGMERGE" in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_MSGMERGE="$MSGMERGE" # Let the user override the test with a path.
- ;;
- *)
- ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH; do
- IFS="$ac_save_IFS"
- test -z "$ac_dir" && ac_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
- if $ac_dir/$ac_word --update -q /dev/null /dev/null >/dev/null 2>&1; then
- ac_cv_path_MSGMERGE="$ac_dir/$ac_word$ac_exec_ext"
- break 2
- fi
- fi
- done
- done
- IFS="$ac_save_IFS"
- test -z "$ac_cv_path_MSGMERGE" && ac_cv_path_MSGMERGE=":"
- ;;
-esac
-fi
-MSGMERGE="$ac_cv_path_MSGMERGE"
-if test "$MSGMERGE" != ":"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGMERGE" >&5
-$as_echo "$MSGMERGE" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- if test "$GMSGFMT" != ":"; then
- if $GMSGFMT --statistics /dev/null >/dev/null 2>&1 &&
- (if $GMSGFMT --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- : ;
- else
- GMSGFMT=`echo "$GMSGFMT" | sed -e 's,^.*/,,'`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: found $GMSGFMT program is not GNU msgfmt; ignore it" >&5
-$as_echo "found $GMSGFMT program is not GNU msgfmt; ignore it" >&6; }
- GMSGFMT=":"
- fi
- fi
-
- if test "$XGETTEXT" != ":"; then
- if $XGETTEXT --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >/dev/null 2>&1 &&
- (if $XGETTEXT --omit-header --copyright-holder= --msgid-bugs-address= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- : ;
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: found xgettext program is not GNU xgettext; ignore it" >&5
-$as_echo "found xgettext program is not GNU xgettext; ignore it" >&6; }
- XGETTEXT=":"
- fi
- rm -f messages.po
- fi
-
- ac_config_commands="$ac_config_commands default-1"
-
-
-
- if test "X$prefix" = "XNONE"; then
- acl_final_prefix="$ac_default_prefix"
- else
- acl_final_prefix="$prefix"
- fi
- if test "X$exec_prefix" = "XNONE"; then
- acl_final_exec_prefix='${prefix}'
- else
- acl_final_exec_prefix="$exec_prefix"
- fi
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- eval acl_final_exec_prefix=\"$acl_final_exec_prefix\"
- prefix="$acl_save_prefix"
-
-
-# Check whether --with-gnu-ld was given.
-if test "${with_gnu_ld+set}" = set; then :
- withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
-else
- with_gnu_ld=no
-fi
-
-# Prepare PATH_SEPARATOR.
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-ac_prog=ld
-if test "$GCC" = yes; then
- # Check if gcc -print-prog-name=ld gives a path.
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by GCC" >&5
-$as_echo_n "checking for ld used by GCC... " >&6; }
- case $host in
- *-*-mingw*)
- # gcc leaves a trailing carriage return which upsets mingw
- ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
- *)
- ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
- esac
- case $ac_prog in
- # Accept absolute paths.
- [\\/]* | [A-Za-z]:[\\/]*)
- re_direlt='/[^/][^/]*/\.\./'
- # Canonicalize the path of ld
- ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
- while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
- ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
- done
- test -z "$LD" && LD="$ac_prog"
- ;;
- "")
- # If it fails, then pretend we aren't using GCC.
- ac_prog=ld
- ;;
- *)
- # If it is relative, then search for the first ld in PATH.
- with_gnu_ld=unknown
- ;;
- esac
-elif test "$with_gnu_ld" = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
-$as_echo_n "checking for GNU ld... " >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
-$as_echo_n "checking for non-GNU ld... " >&6; }
-fi
-if ${acl_cv_path_LD+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -z "$LD"; then
- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
- for ac_dir in $PATH; do
- test -z "$ac_dir" && ac_dir=.
- if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
- acl_cv_path_LD="$ac_dir/$ac_prog"
- # Check to see if the program is GNU ld. I'd rather use --version,
- # but apparently some GNU ld's only accept -v.
- # Break only if it was the GNU/non-GNU ld that we prefer.
- if "$acl_cv_path_LD" -v 2>&1 < /dev/null | $EGREP '(GNU|with BFD)' > /dev/null; then
- test "$with_gnu_ld" != no && break
- else
- test "$with_gnu_ld" != yes && break
- fi
- fi
- done
- IFS="$ac_save_ifs"
-else
- acl_cv_path_LD="$LD" # Let the user override the test with a path.
-fi
-fi
-
-LD="$acl_cv_path_LD"
-if test -n "$LD"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
-$as_echo "$LD" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
-$as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
-if ${acl_cv_prog_gnu_ld+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- # I'd rather use --version here, but apparently some GNU ld's only accept -v.
-if $LD -v 2>&1 </dev/null | $EGREP '(GNU|with BFD)' 1>&5; then
- acl_cv_prog_gnu_ld=yes
-else
- acl_cv_prog_gnu_ld=no
-fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $acl_cv_prog_gnu_ld" >&5
-$as_echo "$acl_cv_prog_gnu_ld" >&6; }
-with_gnu_ld=$acl_cv_prog_gnu_ld
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shared library run path origin" >&5
-$as_echo_n "checking for shared library run path origin... " >&6; }
-if ${acl_cv_rpath+:} false; then :
- $as_echo_n "(cached) " >&6
-else
-
- CC="$CC" GCC="$GCC" LDFLAGS="$LDFLAGS" LD="$LD" with_gnu_ld="$with_gnu_ld" \
- ${CONFIG_SHELL-/bin/sh} "$ac_aux_dir/config.rpath" "$host" > conftest.sh
- . ./conftest.sh
- rm -f ./conftest.sh
- acl_cv_rpath=done
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $acl_cv_rpath" >&5
-$as_echo "$acl_cv_rpath" >&6; }
- wl="$acl_cv_wl"
- libext="$acl_cv_libext"
- shlibext="$acl_cv_shlibext"
- hardcode_libdir_flag_spec="$acl_cv_hardcode_libdir_flag_spec"
- hardcode_libdir_separator="$acl_cv_hardcode_libdir_separator"
- hardcode_direct="$acl_cv_hardcode_direct"
- hardcode_minus_L="$acl_cv_hardcode_minus_L"
- # Check whether --enable-rpath was given.
-if test "${enable_rpath+set}" = set; then :
- enableval=$enable_rpath; :
-else
- enable_rpath=yes
-fi
-
-
-
-
-
-
-
-
- use_additional=yes
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
-
- eval additional_includedir=\"$includedir\"
- eval additional_libdir=\"$libdir\"
-
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
-
-# Check whether --with-libiconv-prefix was given.
-if test "${with_libiconv_prefix+set}" = set; then :
- withval=$with_libiconv_prefix;
- if test "X$withval" = "Xno"; then
- use_additional=no
- else
- if test "X$withval" = "X"; then
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
-
- eval additional_includedir=\"$includedir\"
- eval additional_libdir=\"$libdir\"
-
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- else
- additional_includedir="$withval/include"
- additional_libdir="$withval/lib"
- fi
- fi
-
-fi
-
-
-# Check whether --with-libiconv-type was given.
-if test "${with_libiconv_type+set}" = set; then :
- withval=$with_libiconv_type; with_libiconv_type=$withval
-else
- with_libiconv_type=auto
-fi
-
- lib_type=`eval echo \$with_libiconv_type`
-
- LIBICONV=
- LTLIBICONV=
- INCICONV=
- rpathdirs=
- ltrpathdirs=
- names_already_handled=
- names_next_round='iconv '
- while test -n "$names_next_round"; do
- names_this_round="$names_next_round"
- names_next_round=
- for name in $names_this_round; do
- already_handled=
- for n in $names_already_handled; do
- if test "$n" = "$name"; then
- already_handled=yes
- break
- fi
- done
- if test -z "$already_handled"; then
- names_already_handled="$names_already_handled $name"
- uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
- eval value=\"\$HAVE_LIB$uppername\"
- if test -n "$value"; then
- if test "$value" = yes; then
- eval value=\"\$LIB$uppername\"
- test -z "$value" || LIBICONV="${LIBICONV}${LIBICONV:+ }$value"
- eval value=\"\$LTLIB$uppername\"
- test -z "$value" || LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$value"
- else
- :
- fi
- else
- found_dir=
- found_la=
- found_so=
- found_a=
- if test $use_additional = yes; then
- if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext" && test x$lib_type != xstatic; then
- found_dir="$additional_libdir"
- found_so="$additional_libdir/lib$name.$shlibext"
- if test -f "$additional_libdir/lib$name.la"; then
- found_la="$additional_libdir/lib$name.la"
- fi
- elif test x$lib_type != xshared; then
- if test -f "$additional_libdir/lib$name.$libext"; then
- found_dir="$additional_libdir"
- found_a="$additional_libdir/lib$name.$libext"
- if test -f "$additional_libdir/lib$name.la"; then
- found_la="$additional_libdir/lib$name.la"
- fi
- fi
- fi
- fi
- if test "X$found_dir" = "X"; then
- for x in $LDFLAGS $LTLIBICONV; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- case "$x" in
- -L*)
- dir=`echo "X$x" | sed -e 's/^X-L//'`
- if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext" && test x$lib_type != xstatic; then
- found_dir="$dir"
- found_so="$dir/lib$name.$shlibext"
- if test -f "$dir/lib$name.la"; then
- found_la="$dir/lib$name.la"
- fi
- elif test x$lib_type != xshared; then
- if test -f "$dir/lib$name.$libext"; then
- found_dir="$dir"
- found_a="$dir/lib$name.$libext"
- if test -f "$dir/lib$name.la"; then
- found_la="$dir/lib$name.la"
- fi
- fi
- fi
- ;;
- esac
- if test "X$found_dir" != "X"; then
- break
- fi
- done
- fi
- if test "X$found_dir" != "X"; then
- LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$found_dir -l$name"
- if test "X$found_so" != "X"; then
- if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
- else
- haveit=
- for x in $ltrpathdirs; do
- if test "X$x" = "X$found_dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- ltrpathdirs="$ltrpathdirs $found_dir"
- fi
- if test "$hardcode_direct" = yes; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
- else
- if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
- haveit=
- for x in $rpathdirs; do
- if test "X$x" = "X$found_dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- rpathdirs="$rpathdirs $found_dir"
- fi
- else
- haveit=
- for x in $LDFLAGS $LIBICONV; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-L$found_dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir"
- fi
- if test "$hardcode_minus_L" != no; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
- else
- LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name"
- fi
- fi
- fi
- fi
- else
- if test "X$found_a" != "X"; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }$found_a"
- else
- LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir -l$name"
- fi
- fi
- additional_includedir=
- case "$found_dir" in
- */lib | */lib/)
- basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
- additional_includedir="$basedir/include"
- ;;
- esac
- if test "X$additional_includedir" != "X"; then
- if test "X$additional_includedir" != "X/usr/include"; then
- haveit=
- if test "X$additional_includedir" = "X/usr/local/include"; then
- if test -n "$GCC"; then
- case $host_os in
- linux*) haveit=yes;;
- esac
- fi
- fi
- if test -z "$haveit"; then
- for x in $CPPFLAGS $INCICONV; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-I$additional_includedir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- if test -d "$additional_includedir"; then
- INCICONV="${INCICONV}${INCICONV:+ }-I$additional_includedir"
- fi
- fi
- fi
- fi
- fi
- if test -n "$found_la"; then
- save_libdir="$libdir"
- case "$found_la" in
- */* | *\\*) . "$found_la" ;;
- *) . "./$found_la" ;;
- esac
- libdir="$save_libdir"
- for dep in $dependency_libs; do
- case "$dep" in
- -L*)
- additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
- if test "X$additional_libdir" != "X/usr/lib"; then
- haveit=
- if test "X$additional_libdir" = "X/usr/local/lib"; then
- if test -n "$GCC"; then
- case $host_os in
- linux*) haveit=yes;;
- esac
- fi
- fi
- if test -z "$haveit"; then
- haveit=
- for x in $LDFLAGS $LIBICONV; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-L$additional_libdir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- if test -d "$additional_libdir"; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }-L$additional_libdir"
- fi
- fi
- haveit=
- for x in $LDFLAGS $LTLIBICONV; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-L$additional_libdir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- if test -d "$additional_libdir"; then
- LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$additional_libdir"
- fi
- fi
- fi
- fi
- ;;
- -R*)
- dir=`echo "X$dep" | sed -e 's/^X-R//'`
- if test "$enable_rpath" != no; then
- haveit=
- for x in $rpathdirs; do
- if test "X$x" = "X$dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- rpathdirs="$rpathdirs $dir"
- fi
- haveit=
- for x in $ltrpathdirs; do
- if test "X$x" = "X$dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- ltrpathdirs="$ltrpathdirs $dir"
- fi
- fi
- ;;
- -l*)
- names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
- ;;
- *.la)
- names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
- ;;
- *)
- LIBICONV="${LIBICONV}${LIBICONV:+ }$dep"
- LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$dep"
- ;;
- esac
- done
- fi
- else
- if test "x$lib_type" = "xauto" || test "x$lib_type" = "xshared"; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name"
- LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-l$name"
- else
- LIBICONV="${LIBICONV}${LIBICONV:+ }-l:lib$name.$libext"
- LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-l:lib$name.$libext"
- fi
- fi
- fi
- fi
- done
- done
- if test "X$rpathdirs" != "X"; then
- if test -n "$hardcode_libdir_separator"; then
- alldirs=
- for found_dir in $rpathdirs; do
- alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
- done
- acl_save_libdir="$libdir"
- libdir="$alldirs"
- eval flag=\"$hardcode_libdir_flag_spec\"
- libdir="$acl_save_libdir"
- LIBICONV="${LIBICONV}${LIBICONV:+ }$flag"
- else
- for found_dir in $rpathdirs; do
- acl_save_libdir="$libdir"
- libdir="$found_dir"
- eval flag=\"$hardcode_libdir_flag_spec\"
- libdir="$acl_save_libdir"
- LIBICONV="${LIBICONV}${LIBICONV:+ }$flag"
- done
- fi
- fi
- if test "X$ltrpathdirs" != "X"; then
- for found_dir in $ltrpathdirs; do
- LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-R$found_dir"
- done
- fi
-
-
-
-
-
-if test -f ../gettext/uninstalled-config.sh; then
- relative_builddir='$(top_builddir)/../gettext'
- . ../gettext/uninstalled-config.sh
-else
- # The sister gettext directory doesn't exist and won't collect information on
- # using gettext for us. Call a bundled AM_GNU_GETTEXT.
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CFPreferencesCopyAppValue" >&5
-$as_echo_n "checking for CFPreferencesCopyAppValue... " >&6; }
-if ${gt_cv_func_CFPreferencesCopyAppValue+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- gt_save_LIBS="$LIBS"
- LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <CoreFoundation/CFPreferences.h>
-int
-main ()
-{
-CFPreferencesCopyAppValue(NULL, NULL)
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- gt_cv_func_CFPreferencesCopyAppValue=yes
-else
- gt_cv_func_CFPreferencesCopyAppValue=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LIBS="$gt_save_LIBS"
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_CFPreferencesCopyAppValue" >&5
-$as_echo "$gt_cv_func_CFPreferencesCopyAppValue" >&6; }
- if test $gt_cv_func_CFPreferencesCopyAppValue = yes; then
-
-$as_echo "#define HAVE_CFPREFERENCESCOPYAPPVALUE 1" >>confdefs.h
-
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CFLocaleCopyPreferredLanguages" >&5
-$as_echo_n "checking for CFLocaleCopyPreferredLanguages... " >&6; }
-if ${gt_cv_func_CFLocaleCopyPreferredLanguages+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- gt_save_LIBS="$LIBS"
- LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <CoreFoundation/CFLocale.h>
-int
-main ()
-{
-CFLocaleCopyPreferredLanguages();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- gt_cv_func_CFLocaleCopyPreferredLanguages=yes
-else
- gt_cv_func_CFLocaleCopyPreferredLanguages=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LIBS="$gt_save_LIBS"
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_CFLocaleCopyPreferredLanguages" >&5
-$as_echo "$gt_cv_func_CFLocaleCopyPreferredLanguages" >&6; }
- if test $gt_cv_func_CFLocaleCopyPreferredLanguages = yes; then
-
-$as_echo "#define HAVE_CFLOCALECOPYPREFERREDLANGUAGES 1" >>confdefs.h
-
- fi
- INTL_MACOSX_LIBS=
- if test $gt_cv_func_CFPreferencesCopyAppValue = yes \
- || test $gt_cv_func_CFLocaleCopyPreferredLanguages = yes; then
- INTL_MACOSX_LIBS="-Wl,-framework -Wl,CoreFoundation -Wl,-framework -Wl,CoreServices"
- fi
-
-
-
-
-
-
- LIBINTL=
- LTLIBINTL=
- POSUB=
-
- case " $gt_needs " in
- *" need-formatstring-macros "*) gt_api_version=3 ;;
- *" need-ngettext "*) gt_api_version=2 ;;
- *) gt_api_version=1 ;;
- esac
- gt_func_gnugettext_libc="gt_cv_func_gnugettext${gt_api_version}_libc"
- gt_func_gnugettext_libintl="gt_cv_func_gnugettext${gt_api_version}_libintl"
-
- if test "$USE_NLS" = "yes"; then
- gt_use_preinstalled_gnugettext=no
-
-
- if test $gt_api_version -ge 3; then
- gt_revision_test_code='
-#ifndef __GNU_GETTEXT_SUPPORTED_REVISION
-#define __GNU_GETTEXT_SUPPORTED_REVISION(major) ((major) == 0 ? 0 : -1)
-#endif
-typedef int array [2 * (__GNU_GETTEXT_SUPPORTED_REVISION(0) >= 1) - 1];
-'
- else
- gt_revision_test_code=
- fi
- if test $gt_api_version -ge 2; then
- gt_expression_test_code=' + * ngettext ("", "", 0)'
- else
- gt_expression_test_code=
- fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU gettext in libc" >&5
-$as_echo_n "checking for GNU gettext in libc... " >&6; }
-if eval \${$gt_func_gnugettext_libc+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <libintl.h>
-#ifndef __GNU_GETTEXT_SUPPORTED_REVISION
-extern int _nl_msg_cat_cntr;
-extern int *_nl_domain_bindings;
-#define __GNU_GETTEXT_SYMBOL_EXPRESSION (_nl_msg_cat_cntr + *_nl_domain_bindings)
-#else
-#define __GNU_GETTEXT_SYMBOL_EXPRESSION 0
-#endif
-$gt_revision_test_code
-
-int
-main ()
-{
-
-bindtextdomain ("", "");
-return * gettext ("")$gt_expression_test_code + __GNU_GETTEXT_SYMBOL_EXPRESSION
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- eval "$gt_func_gnugettext_libc=yes"
-else
- eval "$gt_func_gnugettext_libc=no"
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-fi
-eval ac_res=\$$gt_func_gnugettext_libc
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
-
- if { eval "gt_val=\$$gt_func_gnugettext_libc"; test "$gt_val" != "yes"; }; then
-
-
-
-
-
- am_save_CPPFLAGS="$CPPFLAGS"
-
- for element in $INCICONV; do
- haveit=
- for x in $CPPFLAGS; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X$element"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
- fi
- done
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for iconv" >&5
-$as_echo_n "checking for iconv... " >&6; }
-if ${am_cv_func_iconv+:} false; then :
- $as_echo_n "(cached) " >&6
-else
-
- am_cv_func_iconv="no, consider installing GNU libiconv"
- am_cv_lib_iconv=no
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <stdlib.h>
-#include <iconv.h>
-
-int
-main ()
-{
-iconv_t cd = iconv_open("","");
- iconv(cd,NULL,NULL,NULL,NULL);
- iconv_close(cd);
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- am_cv_func_iconv=yes
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- if test "$am_cv_func_iconv" != yes; then
- am_save_LIBS="$LIBS"
- LIBS="$LIBS $LIBICONV"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <stdlib.h>
-#include <iconv.h>
-
-int
-main ()
-{
-iconv_t cd = iconv_open("","");
- iconv(cd,NULL,NULL,NULL,NULL);
- iconv_close(cd);
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- am_cv_lib_iconv=yes
- am_cv_func_iconv=yes
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LIBS="$am_save_LIBS"
- fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv" >&5
-$as_echo "$am_cv_func_iconv" >&6; }
- if test "$am_cv_func_iconv" = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working iconv" >&5
-$as_echo_n "checking for working iconv... " >&6; }
-if ${am_cv_func_iconv_works+:} false; then :
- $as_echo_n "(cached) " >&6
-else
-
- am_save_LIBS="$LIBS"
- if test $am_cv_lib_iconv = yes; then
- LIBS="$LIBS $LIBICONV"
- fi
- am_cv_func_iconv_works=no
- for ac_iconv_const in '' 'const'; do
- if test "$cross_compiling" = yes; then :
- case "$host_os" in
- aix* | hpux*) am_cv_func_iconv_works="guessing no" ;;
- *) am_cv_func_iconv_works="guessing yes" ;;
- esac
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <iconv.h>
-#include <string.h>
-
-#ifndef ICONV_CONST
-# define ICONV_CONST $ac_iconv_const
-#endif
-
-int
-main ()
-{
-int result = 0;
- /* Test against AIX 5.1...7.2 bug: Failures are not distinguishable from
- successful returns. This is even documented in
- <https://www.ibm.com/support/knowledgecenter/ssw_aix_72/i_bostechref/iconv.html> */
- {
- iconv_t cd_utf8_to_88591 = iconv_open ("ISO8859-1", "UTF-8");
- if (cd_utf8_to_88591 != (iconv_t)(-1))
- {
- static ICONV_CONST char input[] = "\342\202\254"; /* EURO SIGN */
- char buf[10];
- ICONV_CONST char *inptr = input;
- size_t inbytesleft = strlen (input);
- char *outptr = buf;
- size_t outbytesleft = sizeof (buf);
- size_t res = iconv (cd_utf8_to_88591,
- &inptr, &inbytesleft,
- &outptr, &outbytesleft);
- if (res == 0)
- result |= 1;
- iconv_close (cd_utf8_to_88591);
- }
- }
- /* Test against Solaris 10 bug: Failures are not distinguishable from
- successful returns. */
- {
- iconv_t cd_ascii_to_88591 = iconv_open ("ISO8859-1", "646");
- if (cd_ascii_to_88591 != (iconv_t)(-1))
- {
- static ICONV_CONST char input[] = "\263";
- char buf[10];
- ICONV_CONST char *inptr = input;
- size_t inbytesleft = strlen (input);
- char *outptr = buf;
- size_t outbytesleft = sizeof (buf);
- size_t res = iconv (cd_ascii_to_88591,
- &inptr, &inbytesleft,
- &outptr, &outbytesleft);
- if (res == 0)
- result |= 2;
- iconv_close (cd_ascii_to_88591);
- }
- }
- /* Test against AIX 6.1..7.1 bug: Buffer overrun. */
- {
- iconv_t cd_88591_to_utf8 = iconv_open ("UTF-8", "ISO-8859-1");
- if (cd_88591_to_utf8 != (iconv_t)(-1))
- {
- static ICONV_CONST char input[] = "\304";
- static char buf[2] = { (char)0xDE, (char)0xAD };
- ICONV_CONST char *inptr = input;
- size_t inbytesleft = 1;
- char *outptr = buf;
- size_t outbytesleft = 1;
- size_t res = iconv (cd_88591_to_utf8,
- &inptr, &inbytesleft,
- &outptr, &outbytesleft);
- if (res != (size_t)(-1) || outptr - buf > 1 || buf[1] != (char)0xAD)
- result |= 4;
- iconv_close (cd_88591_to_utf8);
- }
- }
-#if 0 /* This bug could be worked around by the caller. */
- /* Test against HP-UX 11.11 bug: Positive return value instead of 0. */
- {
- iconv_t cd_88591_to_utf8 = iconv_open ("utf8", "iso88591");
- if (cd_88591_to_utf8 != (iconv_t)(-1))
- {
- static ICONV_CONST char input[] = "\304rger mit b\366sen B\374bchen ohne Augenma\337";
- char buf[50];
- ICONV_CONST char *inptr = input;
- size_t inbytesleft = strlen (input);
- char *outptr = buf;
- size_t outbytesleft = sizeof (buf);
- size_t res = iconv (cd_88591_to_utf8,
- &inptr, &inbytesleft,
- &outptr, &outbytesleft);
- if ((int)res > 0)
- result |= 8;
- iconv_close (cd_88591_to_utf8);
- }
- }
-#endif
- /* Test against HP-UX 11.11 bug: No converter from EUC-JP to UTF-8 is
- provided. */
- {
- /* Try standardized names. */
- iconv_t cd1 = iconv_open ("UTF-8", "EUC-JP");
- /* Try IRIX, OSF/1 names. */
- iconv_t cd2 = iconv_open ("UTF-8", "eucJP");
- /* Try AIX names. */
- iconv_t cd3 = iconv_open ("UTF-8", "IBM-eucJP");
- /* Try HP-UX names. */
- iconv_t cd4 = iconv_open ("utf8", "eucJP");
- if (cd1 == (iconv_t)(-1) && cd2 == (iconv_t)(-1)
- && cd3 == (iconv_t)(-1) && cd4 == (iconv_t)(-1))
- result |= 16;
- if (cd1 != (iconv_t)(-1))
- iconv_close (cd1);
- if (cd2 != (iconv_t)(-1))
- iconv_close (cd2);
- if (cd3 != (iconv_t)(-1))
- iconv_close (cd3);
- if (cd4 != (iconv_t)(-1))
- iconv_close (cd4);
- }
- return result;
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_run "$LINENO"; then :
- am_cv_func_iconv_works=yes
-fi
-rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
- conftest.$ac_objext conftest.beam conftest.$ac_ext
-fi
-
- test "$am_cv_func_iconv_works" = no || break
- done
- LIBS="$am_save_LIBS"
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv_works" >&5
-$as_echo "$am_cv_func_iconv_works" >&6; }
- case "$am_cv_func_iconv_works" in
- *no) am_func_iconv=no am_cv_lib_iconv=no ;;
- *) am_func_iconv=yes ;;
- esac
- else
- am_func_iconv=no am_cv_lib_iconv=no
- fi
- if test "$am_func_iconv" = yes; then
-
-$as_echo "#define HAVE_ICONV 1" >>confdefs.h
-
- fi
- if test "$am_cv_lib_iconv" = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libiconv" >&5
-$as_echo_n "checking how to link with libiconv... " >&6; }
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBICONV" >&5
-$as_echo "$LIBICONV" >&6; }
- else
- CPPFLAGS="$am_save_CPPFLAGS"
- LIBICONV=
- LTLIBICONV=
- fi
-
-
-
-
-
-
- use_additional=yes
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
-
- eval additional_includedir=\"$includedir\"
- eval additional_libdir=\"$libdir\"
-
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
-
-# Check whether --with-libintl-prefix was given.
-if test "${with_libintl_prefix+set}" = set; then :
- withval=$with_libintl_prefix;
- if test "X$withval" = "Xno"; then
- use_additional=no
- else
- if test "X$withval" = "X"; then
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
-
- eval additional_includedir=\"$includedir\"
- eval additional_libdir=\"$libdir\"
-
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- else
- additional_includedir="$withval/include"
- additional_libdir="$withval/lib"
- fi
- fi
-
-fi
-
-
-# Check whether --with-libintl-type was given.
-if test "${with_libintl_type+set}" = set; then :
- withval=$with_libintl_type; with_libintl_type=$withval
-else
- with_libintl_type=auto
-fi
-
- lib_type=`eval echo \$with_libintl_type`
-
- LIBINTL=
- LTLIBINTL=
- INCINTL=
- rpathdirs=
- ltrpathdirs=
- names_already_handled=
- names_next_round='intl '
- while test -n "$names_next_round"; do
- names_this_round="$names_next_round"
- names_next_round=
- for name in $names_this_round; do
- already_handled=
- for n in $names_already_handled; do
- if test "$n" = "$name"; then
- already_handled=yes
- break
- fi
- done
- if test -z "$already_handled"; then
- names_already_handled="$names_already_handled $name"
- uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
- eval value=\"\$HAVE_LIB$uppername\"
- if test -n "$value"; then
- if test "$value" = yes; then
- eval value=\"\$LIB$uppername\"
- test -z "$value" || LIBINTL="${LIBINTL}${LIBINTL:+ }$value"
- eval value=\"\$LTLIB$uppername\"
- test -z "$value" || LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }$value"
- else
- :
- fi
- else
- found_dir=
- found_la=
- found_so=
- found_a=
- if test $use_additional = yes; then
- if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext" && test x$lib_type != xstatic; then
- found_dir="$additional_libdir"
- found_so="$additional_libdir/lib$name.$shlibext"
- if test -f "$additional_libdir/lib$name.la"; then
- found_la="$additional_libdir/lib$name.la"
- fi
- elif test x$lib_type != xshared; then
- if test -f "$additional_libdir/lib$name.$libext"; then
- found_dir="$additional_libdir"
- found_a="$additional_libdir/lib$name.$libext"
- if test -f "$additional_libdir/lib$name.la"; then
- found_la="$additional_libdir/lib$name.la"
- fi
- fi
- fi
- fi
- if test "X$found_dir" = "X"; then
- for x in $LDFLAGS $LTLIBINTL; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- case "$x" in
- -L*)
- dir=`echo "X$x" | sed -e 's/^X-L//'`
- if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext" && test x$lib_type != xstatic; then
- found_dir="$dir"
- found_so="$dir/lib$name.$shlibext"
- if test -f "$dir/lib$name.la"; then
- found_la="$dir/lib$name.la"
- fi
- elif test x$lib_type != xshared; then
- if test -f "$dir/lib$name.$libext"; then
- found_dir="$dir"
- found_a="$dir/lib$name.$libext"
- if test -f "$dir/lib$name.la"; then
- found_la="$dir/lib$name.la"
- fi
- fi
- fi
- ;;
- esac
- if test "X$found_dir" != "X"; then
- break
- fi
- done
- fi
- if test "X$found_dir" != "X"; then
- LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-L$found_dir -l$name"
- if test "X$found_so" != "X"; then
- if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
- else
- haveit=
- for x in $ltrpathdirs; do
- if test "X$x" = "X$found_dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- ltrpathdirs="$ltrpathdirs $found_dir"
- fi
- if test "$hardcode_direct" = yes; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
- else
- if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
- haveit=
- for x in $rpathdirs; do
- if test "X$x" = "X$found_dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- rpathdirs="$rpathdirs $found_dir"
- fi
- else
- haveit=
- for x in $LDFLAGS $LIBINTL; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-L$found_dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }-L$found_dir"
- fi
- if test "$hardcode_minus_L" != no; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
- else
- LIBINTL="${LIBINTL}${LIBINTL:+ }-l$name"
- fi
- fi
- fi
- fi
- else
- if test "X$found_a" != "X"; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }$found_a"
- else
- LIBINTL="${LIBINTL}${LIBINTL:+ }-L$found_dir -l$name"
- fi
- fi
- additional_includedir=
- case "$found_dir" in
- */lib | */lib/)
- basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
- additional_includedir="$basedir/include"
- ;;
- esac
- if test "X$additional_includedir" != "X"; then
- if test "X$additional_includedir" != "X/usr/include"; then
- haveit=
- if test "X$additional_includedir" = "X/usr/local/include"; then
- if test -n "$GCC"; then
- case $host_os in
- linux*) haveit=yes;;
- esac
- fi
- fi
- if test -z "$haveit"; then
- for x in $CPPFLAGS $INCINTL; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-I$additional_includedir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- if test -d "$additional_includedir"; then
- INCINTL="${INCINTL}${INCINTL:+ }-I$additional_includedir"
- fi
- fi
- fi
- fi
- fi
- if test -n "$found_la"; then
- save_libdir="$libdir"
- case "$found_la" in
- */* | *\\*) . "$found_la" ;;
- *) . "./$found_la" ;;
- esac
- libdir="$save_libdir"
- for dep in $dependency_libs; do
- case "$dep" in
- -L*)
- additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
- if test "X$additional_libdir" != "X/usr/lib"; then
- haveit=
- if test "X$additional_libdir" = "X/usr/local/lib"; then
- if test -n "$GCC"; then
- case $host_os in
- linux*) haveit=yes;;
- esac
- fi
- fi
- if test -z "$haveit"; then
- haveit=
- for x in $LDFLAGS $LIBINTL; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-L$additional_libdir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- if test -d "$additional_libdir"; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }-L$additional_libdir"
- fi
- fi
- haveit=
- for x in $LDFLAGS $LTLIBINTL; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-L$additional_libdir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- if test -d "$additional_libdir"; then
- LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-L$additional_libdir"
- fi
- fi
- fi
- fi
- ;;
- -R*)
- dir=`echo "X$dep" | sed -e 's/^X-R//'`
- if test "$enable_rpath" != no; then
- haveit=
- for x in $rpathdirs; do
- if test "X$x" = "X$dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- rpathdirs="$rpathdirs $dir"
- fi
- haveit=
- for x in $ltrpathdirs; do
- if test "X$x" = "X$dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- ltrpathdirs="$ltrpathdirs $dir"
- fi
- fi
- ;;
- -l*)
- names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
- ;;
- *.la)
- names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
- ;;
- *)
- LIBINTL="${LIBINTL}${LIBINTL:+ }$dep"
- LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }$dep"
- ;;
- esac
- done
- fi
- else
- if test "x$lib_type" = "xauto" || test "x$lib_type" = "xshared"; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }-l$name"
- LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-l$name"
- else
- LIBINTL="${LIBINTL}${LIBINTL:+ }-l:lib$name.$libext"
- LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-l:lib$name.$libext"
- fi
- fi
- fi
- fi
- done
- done
- if test "X$rpathdirs" != "X"; then
- if test -n "$hardcode_libdir_separator"; then
- alldirs=
- for found_dir in $rpathdirs; do
- alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
- done
- acl_save_libdir="$libdir"
- libdir="$alldirs"
- eval flag=\"$hardcode_libdir_flag_spec\"
- libdir="$acl_save_libdir"
- LIBINTL="${LIBINTL}${LIBINTL:+ }$flag"
- else
- for found_dir in $rpathdirs; do
- acl_save_libdir="$libdir"
- libdir="$found_dir"
- eval flag=\"$hardcode_libdir_flag_spec\"
- libdir="$acl_save_libdir"
- LIBINTL="${LIBINTL}${LIBINTL:+ }$flag"
- done
- fi
- fi
- if test "X$ltrpathdirs" != "X"; then
- for found_dir in $ltrpathdirs; do
- LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-R$found_dir"
- done
- fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU gettext in libintl" >&5
-$as_echo_n "checking for GNU gettext in libintl... " >&6; }
-if eval \${$gt_func_gnugettext_libintl+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- gt_save_CPPFLAGS="$CPPFLAGS"
- CPPFLAGS="$CPPFLAGS $INCINTL"
- gt_save_LIBS="$LIBS"
- LIBS="$LIBS $LIBINTL"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <libintl.h>
-#ifndef __GNU_GETTEXT_SUPPORTED_REVISION
-extern int _nl_msg_cat_cntr;
-extern
-#ifdef __cplusplus
-"C"
-#endif
-const char *_nl_expand_alias (const char *);
-#define __GNU_GETTEXT_SYMBOL_EXPRESSION (_nl_msg_cat_cntr + *_nl_expand_alias (""))
-#else
-#define __GNU_GETTEXT_SYMBOL_EXPRESSION 0
-#endif
-$gt_revision_test_code
-
-int
-main ()
-{
-
-bindtextdomain ("", "");
-return * gettext ("")$gt_expression_test_code + __GNU_GETTEXT_SYMBOL_EXPRESSION
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- eval "$gt_func_gnugettext_libintl=yes"
-else
- eval "$gt_func_gnugettext_libintl=no"
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" != yes; } && test -n "$LIBICONV"; then
- LIBS="$LIBS $LIBICONV"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <libintl.h>
-#ifndef __GNU_GETTEXT_SUPPORTED_REVISION
-extern int _nl_msg_cat_cntr;
-extern
-#ifdef __cplusplus
-"C"
-#endif
-const char *_nl_expand_alias (const char *);
-#define __GNU_GETTEXT_SYMBOL_EXPRESSION (_nl_msg_cat_cntr + *_nl_expand_alias (""))
-#else
-#define __GNU_GETTEXT_SYMBOL_EXPRESSION 0
-#endif
-$gt_revision_test_code
-
-int
-main ()
-{
-
-bindtextdomain ("", "");
-return * gettext ("")$gt_expression_test_code + __GNU_GETTEXT_SYMBOL_EXPRESSION
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- LIBINTL="$LIBINTL $LIBICONV"
- LTLIBINTL="$LTLIBINTL $LTLIBICONV"
- eval "$gt_func_gnugettext_libintl=yes"
-
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- fi
- CPPFLAGS="$gt_save_CPPFLAGS"
- LIBS="$gt_save_LIBS"
-fi
-eval ac_res=\$$gt_func_gnugettext_libintl
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
- fi
-
- if { eval "gt_val=\$$gt_func_gnugettext_libc"; test "$gt_val" = "yes"; } \
- || { { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; } \
- && test "$PACKAGE" != gettext-runtime \
- && test "$PACKAGE" != gettext-tools; }; then
- gt_use_preinstalled_gnugettext=yes
- else
- LIBINTL=
- LTLIBINTL=
- INCINTL=
- fi
-
-
-
- if test -n "$INTL_MACOSX_LIBS"; then
- if test "$gt_use_preinstalled_gnugettext" = "yes" \
- || test "$nls_cv_use_gnu_gettext" = "yes"; then
- LIBINTL="$LIBINTL $INTL_MACOSX_LIBS"
- LTLIBINTL="$LTLIBINTL $INTL_MACOSX_LIBS"
- fi
- fi
-
- if test "$gt_use_preinstalled_gnugettext" = "yes" \
- || test "$nls_cv_use_gnu_gettext" = "yes"; then
-
-$as_echo "#define ENABLE_NLS 1" >>confdefs.h
-
- else
- USE_NLS=no
- fi
- fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use NLS" >&5
-$as_echo_n "checking whether to use NLS... " >&6; }
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_NLS" >&5
-$as_echo "$USE_NLS" >&6; }
- if test "$USE_NLS" = "yes"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking where the gettext function comes from" >&5
-$as_echo_n "checking where the gettext function comes from... " >&6; }
- if test "$gt_use_preinstalled_gnugettext" = "yes"; then
- if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; }; then
- gt_source="external libintl"
- else
- gt_source="libc"
- fi
- else
- gt_source="included intl directory"
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_source" >&5
-$as_echo "$gt_source" >&6; }
- fi
-
- if test "$USE_NLS" = "yes"; then
-
- if test "$gt_use_preinstalled_gnugettext" = "yes"; then
- if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; }; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libintl" >&5
-$as_echo_n "checking how to link with libintl... " >&6; }
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBINTL" >&5
-$as_echo "$LIBINTL" >&6; }
-
- for element in $INCINTL; do
- haveit=
- for x in $CPPFLAGS; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X$element"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
- fi
- done
-
- fi
-
-
-$as_echo "#define HAVE_GETTEXT 1" >>confdefs.h
-
-
-$as_echo "#define HAVE_DCGETTEXT 1" >>confdefs.h
-
- fi
-
- POSUB=po
- fi
-
-
-
- INTLLIBS="$LIBINTL"
-
-
-
-
-
-
-fi
-
-
-
-
-
-
-
-
-
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NLS is requested" >&5
-$as_echo_n "checking whether NLS is requested... " >&6; }
-if test x"$USE_NLS" != xyes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-
-$as_echo "#define ENABLE_NLS 1" >>confdefs.h
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for catalogs to be installed" >&5
-$as_echo_n "checking for catalogs to be installed... " >&6; }
- # Look for .po and .gmo files in the source directory.
- CATALOGS=
- XLINGUAS=
- for cat in $srcdir/po/*.gmo $srcdir/po/*.po; do
- # If there aren't any .gmo files the shell will give us the
- # literal string "../path/to/srcdir/po/*.gmo" which has to be
- # weeded out.
- case "$cat" in *\**)
- continue;;
- esac
- # The quadruple backslash is collapsed to a double backslash
- # by the backticks, then collapsed again by the double quotes,
- # leaving us with one backslash in the sed expression (right
- # before the dot that mustn't act as a wildcard).
- cat=`echo $cat | sed -e "s!$srcdir/po/!!" -e "s!\\\\.po!.gmo!"`
- lang=`echo $cat | sed -e "s!\\\\.gmo!!"`
- # The user is allowed to set LINGUAS to a list of languages to
- # install catalogs for. If it's empty that means "all of them."
- if test "x$LINGUAS" = x; then
- CATALOGS="$CATALOGS $cat"
- XLINGUAS="$XLINGUAS $lang"
- else
- case "$LINGUAS" in *$lang*)
- CATALOGS="$CATALOGS $cat"
- XLINGUAS="$XLINGUAS $lang"
- ;;
- esac
- fi
- done
- LINGUAS="$XLINGUAS"
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LINGUAS" >&5
-$as_echo "$LINGUAS" >&6; }
-
-
- DATADIRNAME=share
-
- INSTOBJEXT=.mo
-
- GENCAT=gencat
-
- CATOBJEXT=.gmo
-
-fi
-
-
-
-
-# Prepare PATH_SEPARATOR.
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-
-# Find out how to test for executable files. Don't use a zero-byte file,
-# as systems may use methods other than mode bits to determine executability.
-cat >conf$$.file <<_ASEOF
-#! /bin/sh
-exit 0
-_ASEOF
-chmod +x conf$$.file
-if test -x conf$$.file >/dev/null 2>&1; then
- ac_executable_p="test -x"
-else
- ac_executable_p="test -f"
-fi
-rm -f conf$$.file
-
-# Extract the first word of "msgfmt", so it can be a program name with args.
-set dummy msgfmt; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_MSGFMT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case "$MSGFMT" in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
- ;;
- *)
- ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH; do
- IFS="$ac_save_IFS"
- test -z "$ac_dir" && ac_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
- if $ac_dir/$ac_word --statistics /dev/null >/dev/null 2>&1 &&
- (if $ac_dir/$ac_word --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- ac_cv_path_MSGFMT="$ac_dir/$ac_word$ac_exec_ext"
- break 2
- fi
- fi
- done
- done
- IFS="$ac_save_IFS"
- test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT=":"
- ;;
-esac
-fi
-MSGFMT="$ac_cv_path_MSGFMT"
-if test "$MSGFMT" != ":"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGFMT" >&5
-$as_echo "$MSGFMT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- # Extract the first word of "gmsgfmt", so it can be a program name with args.
-set dummy gmsgfmt; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_GMSGFMT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $GMSGFMT in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
- ;;
- *)
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_path_GMSGFMT="$as_dir/$ac_word$ac_exec_ext"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
- test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT"
- ;;
-esac
-fi
-GMSGFMT=$ac_cv_path_GMSGFMT
-if test -n "$GMSGFMT"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GMSGFMT" >&5
-$as_echo "$GMSGFMT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-
-
-# Prepare PATH_SEPARATOR.
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-
-# Find out how to test for executable files. Don't use a zero-byte file,
-# as systems may use methods other than mode bits to determine executability.
-cat >conf$$.file <<_ASEOF
-#! /bin/sh
-exit 0
-_ASEOF
-chmod +x conf$$.file
-if test -x conf$$.file >/dev/null 2>&1; then
- ac_executable_p="test -x"
-else
- ac_executable_p="test -f"
-fi
-rm -f conf$$.file
-
-# Extract the first word of "xgettext", so it can be a program name with args.
-set dummy xgettext; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_XGETTEXT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case "$XGETTEXT" in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
- ;;
- *)
- ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH; do
- IFS="$ac_save_IFS"
- test -z "$ac_dir" && ac_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
- if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >/dev/null 2>&1 &&
- (if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- ac_cv_path_XGETTEXT="$ac_dir/$ac_word$ac_exec_ext"
- break 2
- fi
- fi
- done
- done
- IFS="$ac_save_IFS"
- test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":"
- ;;
-esac
-fi
-XGETTEXT="$ac_cv_path_XGETTEXT"
-if test "$XGETTEXT" != ":"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XGETTEXT" >&5
-$as_echo "$XGETTEXT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- rm -f messages.po
-
-
-# Prepare PATH_SEPARATOR.
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-
-# Find out how to test for executable files. Don't use a zero-byte file,
-# as systems may use methods other than mode bits to determine executability.
-cat >conf$$.file <<_ASEOF
-#! /bin/sh
-exit 0
-_ASEOF
-chmod +x conf$$.file
-if test -x conf$$.file >/dev/null 2>&1; then
- ac_executable_p="test -x"
-else
- ac_executable_p="test -f"
-fi
-rm -f conf$$.file
-
-# Extract the first word of "msgmerge", so it can be a program name with args.
-set dummy msgmerge; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_MSGMERGE+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case "$MSGMERGE" in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_MSGMERGE="$MSGMERGE" # Let the user override the test with a path.
- ;;
- *)
- ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH; do
- IFS="$ac_save_IFS"
- test -z "$ac_dir" && ac_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
- if $ac_dir/$ac_word --update -q /dev/null /dev/null >/dev/null 2>&1; then
- ac_cv_path_MSGMERGE="$ac_dir/$ac_word$ac_exec_ext"
- break 2
- fi
- fi
- done
- done
- IFS="$ac_save_IFS"
- test -z "$ac_cv_path_MSGMERGE" && ac_cv_path_MSGMERGE=":"
- ;;
-esac
-fi
-MSGMERGE="$ac_cv_path_MSGMERGE"
-if test "$MSGMERGE" != ":"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGMERGE" >&5
-$as_echo "$MSGMERGE" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- if test "$GMSGFMT" != ":"; then
- if $GMSGFMT --statistics /dev/null >/dev/null 2>&1 &&
- (if $GMSGFMT --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- : ;
- else
- GMSGFMT=`echo "$GMSGFMT" | sed -e 's,^.*/,,'`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: found $GMSGFMT program is not GNU msgfmt; ignore it" >&5
-$as_echo "found $GMSGFMT program is not GNU msgfmt; ignore it" >&6; }
- GMSGFMT=":"
- fi
- fi
-
- if test "$XGETTEXT" != ":"; then
- if $XGETTEXT --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >/dev/null 2>&1 &&
- (if $XGETTEXT --omit-header --copyright-holder= --msgid-bugs-address= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- : ;
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: found xgettext program is not GNU xgettext; ignore it" >&5
-$as_echo "found xgettext program is not GNU xgettext; ignore it" >&6; }
- XGETTEXT=":"
- fi
- rm -f messages.po
- fi
-
- ac_config_commands="$ac_config_commands default-2"
-
-
-
-
-
-for ac_prog in 'bison -y' byacc
-do
- # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_YACC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$YACC"; then
- ac_cv_prog_YACC="$YACC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_YACC="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-YACC=$ac_cv_prog_YACC
-if test -n "$YACC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $YACC" >&5
-$as_echo "$YACC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$YACC" && break
-done
-test -n "$YACC" || YACC="yacc"
-
-for ac_prog in flex lex
-do
- # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_LEX+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$LEX"; then
- ac_cv_prog_LEX="$LEX" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_LEX="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-LEX=$ac_cv_prog_LEX
-if test -n "$LEX"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LEX" >&5
-$as_echo "$LEX" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$LEX" && break
-done
-test -n "$LEX" || LEX=":"
-
-case "$LEX" in
- :|*"missing "*) ;;
- *) cat >conftest.l <<_ACEOF
-%%
-a { ECHO; }
-b { REJECT; }
-c { yymore (); }
-d { yyless (1); }
-e { /* IRIX 6.5 flex 2.5.4 underquotes its yyless argument. */
- yyless ((input () != 0)); }
-f { unput (yytext[0]); }
-. { BEGIN INITIAL; }
-%%
-#ifdef YYTEXT_POINTER
-extern char *yytext;
-#endif
-int
-main (void)
-{
- return ! yylex () + ! yywrap ();
-}
-_ACEOF
-{ { ac_try="$LEX conftest.l"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$LEX conftest.l") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking lex output file root" >&5
-$as_echo_n "checking lex output file root... " >&6; }
-if ${ac_cv_prog_lex_root+:} false; then :
- $as_echo_n "(cached) " >&6
-else
-
-if test -f lex.yy.c; then
- ac_cv_prog_lex_root=lex.yy
-elif test -f lexyy.c; then
- ac_cv_prog_lex_root=lexyy
-else
- as_fn_error $? "cannot find output from $LEX; giving up" "$LINENO" 5
-fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_lex_root" >&5
-$as_echo "$ac_cv_prog_lex_root" >&6; }
-LEX_OUTPUT_ROOT=$ac_cv_prog_lex_root
-
-if test -z "${LEXLIB+set}"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking lex library" >&5
-$as_echo_n "checking lex library... " >&6; }
-if ${ac_cv_lib_lex+:} false; then :
- $as_echo_n "(cached) " >&6
-else
-
- ac_save_LIBS=$LIBS
- ac_cv_lib_lex='none needed'
- for ac_lib in '' -lfl -ll; do
- LIBS="$ac_lib $ac_save_LIBS"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-`cat $LEX_OUTPUT_ROOT.c`
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_lib_lex=$ac_lib
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- test "$ac_cv_lib_lex" != 'none needed' && break
- done
- LIBS=$ac_save_LIBS
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_lex" >&5
-$as_echo "$ac_cv_lib_lex" >&6; }
- test "$ac_cv_lib_lex" != 'none needed' && LEXLIB=$ac_cv_lib_lex
-fi
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether yytext is a pointer" >&5
-$as_echo_n "checking whether yytext is a pointer... " >&6; }
-if ${ac_cv_prog_lex_yytext_pointer+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- # POSIX says lex can declare yytext either as a pointer or an array; the
-# default is implementation-dependent. Figure out which it is, since
-# not all implementations provide the %pointer and %array declarations.
-ac_cv_prog_lex_yytext_pointer=no
-ac_save_LIBS=$LIBS
-LIBS="$LEXLIB $ac_save_LIBS"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
- #define YYTEXT_POINTER 1
-`cat $LEX_OUTPUT_ROOT.c`
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_prog_lex_yytext_pointer=yes
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_save_LIBS
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_lex_yytext_pointer" >&5
-$as_echo "$ac_cv_prog_lex_yytext_pointer" >&6; }
-if test $ac_cv_prog_lex_yytext_pointer = yes; then
-
-$as_echo "#define YYTEXT_POINTER 1" >>confdefs.h
-
-fi
-rm -f conftest.l $LEX_OUTPUT_ROOT.c
- ;;
-esac
-if test "$LEX" = :; then
- LEX=${am_missing_run}flex
-fi
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable maintainer-specific portions of Makefiles" >&5
-$as_echo_n "checking whether to enable maintainer-specific portions of Makefiles... " >&6; }
- # Check whether --enable-maintainer-mode was given.
-if test "${enable_maintainer_mode+set}" = set; then :
- enableval=$enable_maintainer_mode; USE_MAINTAINER_MODE=$enableval
-else
- USE_MAINTAINER_MODE=no
-fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_MAINTAINER_MODE" >&5
-$as_echo "$USE_MAINTAINER_MODE" >&6; }
- if test $USE_MAINTAINER_MODE = yes; then
- MAINTAINER_MODE_TRUE=
- MAINTAINER_MODE_FALSE='#'
-else
- MAINTAINER_MODE_TRUE='#'
- MAINTAINER_MODE_FALSE=
-fi
-
- MAINT=$MAINTAINER_MODE_TRUE
-
-
- if false; then
- GENINSRC_NEVER_TRUE=
- GENINSRC_NEVER_FALSE='#'
-else
- GENINSRC_NEVER_TRUE='#'
- GENINSRC_NEVER_FALSE=
-fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to compare bootstrapped objects" >&5
-$as_echo_n "checking how to compare bootstrapped objects... " >&6; }
-if ${gcc_cv_prog_cmp_skip+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- echo abfoo >t1
- echo cdfoo >t2
- gcc_cv_prog_cmp_skip='tail -c +17 $$f1 > tmp-foo1; tail -c +17 $$f2 > tmp-foo2; cmp tmp-foo1 tmp-foo2'
- if cmp t1 t2 2 2 > /dev/null 2>&1; then
- if cmp t1 t2 1 1 > /dev/null 2>&1; then
- :
- else
- gcc_cv_prog_cmp_skip='cmp $$f1 $$f2 16 16'
- fi
- fi
- if cmp --ignore-initial=2 t1 t2 > /dev/null 2>&1; then
- if cmp --ignore-initial=1 t1 t2 > /dev/null 2>&1; then
- :
- else
- gcc_cv_prog_cmp_skip='cmp --ignore-initial=16 $$f1 $$f2'
- fi
- fi
- rm t1 t2
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_prog_cmp_skip" >&5
-$as_echo "$gcc_cv_prog_cmp_skip" >&6; }
-do_compare="$gcc_cv_prog_cmp_skip"
-
-
-
-. ${srcdir}/configure.host
-
-
-
-
-# We use headers from include/ that check various HAVE_*_H macros, thus
-# should ensure they are set by configure. This is true even when C99
-# guarantees they are available.
-# sha1.h and md4.h test HAVE_LIMITS_H, HAVE_SYS_TYPES_H and HAVE_STDINT_H
-# plugin-api.h tests HAVE_STDINT_H and HAVE_INTTYPES_H
-# Besides those, we need to check anything used in ld/ not in C99.
-for ac_header in fcntl.h elf-hints.h limits.h inttypes.h stdint.h \
- sys/file.h sys/mman.h sys/param.h sys/stat.h sys/time.h \
- sys/types.h unistd.h
-do :
- as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
-ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
-if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
- cat >>confdefs.h <<_ACEOF
-#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
-_ACEOF
-
-fi
-
-done
-
-for ac_func in close glob lseek mkstemp open realpath waitpid
-do :
- as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
-ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
-if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
- cat >>confdefs.h <<_ACEOF
-#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
-_ACEOF
-
-fi
-done
-
-
-
-case "${host}" in
-*-*-msdos* | *-*-go32* | *-*-mingw32* | *-*-cygwin* | *-*-windows*)
-
-$as_echo "#define USE_BINARY_FOPEN 1" >>confdefs.h
- ;;
-esac
-
-ac_fn_c_check_decl "$LINENO" "asprintf" "ac_cv_have_decl_asprintf" "$ac_includes_default"
-if test "x$ac_cv_have_decl_asprintf" = xyes; then :
- ac_have_decl=1
-else
- ac_have_decl=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define HAVE_DECL_ASPRINTF $ac_have_decl
-_ACEOF
-ac_fn_c_check_decl "$LINENO" "environ" "ac_cv_have_decl_environ" "$ac_includes_default"
-if test "x$ac_cv_have_decl_environ" = xyes; then :
- ac_have_decl=1
-else
- ac_have_decl=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define HAVE_DECL_ENVIRON $ac_have_decl
-_ACEOF
-ac_fn_c_check_decl "$LINENO" "stpcpy" "ac_cv_have_decl_stpcpy" "$ac_includes_default"
-if test "x$ac_cv_have_decl_stpcpy" = xyes; then :
- ac_have_decl=1
-else
- ac_have_decl=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define HAVE_DECL_STPCPY $ac_have_decl
-_ACEOF
-
-
-
-
-
- for ac_header in $ac_header_list
-do :
- as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
-ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
-"
-if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
- cat >>confdefs.h <<_ACEOF
-#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
-_ACEOF
-
-fi
-
-done
-
-
-
-
-
-
-
-save_ASAN_OPTIONS="$ASAN_OPTIONS"
- ASAN_OPTIONS=detect_leaks=0
- export ASAN_OPTIONS
-
-for ac_func in getpagesize
-do :
- ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize"
-if test "x$ac_cv_func_getpagesize" = xyes; then :
- cat >>confdefs.h <<_ACEOF
-#define HAVE_GETPAGESIZE 1
-_ACEOF
-
-fi
-done
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mmap" >&5
-$as_echo_n "checking for working mmap... " >&6; }
-if ${ac_cv_func_mmap_fixed_mapped+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test "$cross_compiling" = yes; then :
- ac_cv_func_mmap_fixed_mapped=no
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$ac_includes_default
-/* malloc might have been renamed as rpl_malloc. */
-#undef malloc
-
-/* Thanks to Mike Haertel and Jim Avera for this test.
- Here is a matrix of mmap possibilities:
- mmap private not fixed
- mmap private fixed at somewhere currently unmapped
- mmap private fixed at somewhere already mapped
- mmap shared not fixed
- mmap shared fixed at somewhere currently unmapped
- mmap shared fixed at somewhere already mapped
- For private mappings, we should verify that changes cannot be read()
- back from the file, nor mmap's back from the file at a different
- address. (There have been systems where private was not correctly
- implemented like the infamous i386 svr4.0, and systems where the
- VM page cache was not coherent with the file system buffer cache
- like early versions of FreeBSD and possibly contemporary NetBSD.)
- For shared mappings, we should conversely verify that changes get
- propagated back to all the places they're supposed to be.
-
- Grep wants private fixed already mapped.
- The main things grep needs to know about mmap are:
- * does it exist and is it safe to write into the mmap'd area
- * how to use it (BSD variants) */
-
-#include <fcntl.h>
-#include <sys/mman.h>
-
-#if !defined STDC_HEADERS && !defined HAVE_STDLIB_H
-char *malloc ();
-#endif
-
-/* This mess was copied from the GNU getpagesize.h. */
-#ifndef HAVE_GETPAGESIZE
-# ifdef _SC_PAGESIZE
-# define getpagesize() sysconf(_SC_PAGESIZE)
-# else /* no _SC_PAGESIZE */
-# ifdef HAVE_SYS_PARAM_H
-# include <sys/param.h>
-# ifdef EXEC_PAGESIZE
-# define getpagesize() EXEC_PAGESIZE
-# else /* no EXEC_PAGESIZE */
-# ifdef NBPG
-# define getpagesize() NBPG * CLSIZE
-# ifndef CLSIZE
-# define CLSIZE 1
-# endif /* no CLSIZE */
-# else /* no NBPG */
-# ifdef NBPC
-# define getpagesize() NBPC
-# else /* no NBPC */
-# ifdef PAGESIZE
-# define getpagesize() PAGESIZE
-# endif /* PAGESIZE */
-# endif /* no NBPC */
-# endif /* no NBPG */
-# endif /* no EXEC_PAGESIZE */
-# else /* no HAVE_SYS_PARAM_H */
-# define getpagesize() 8192 /* punt totally */
-# endif /* no HAVE_SYS_PARAM_H */
-# endif /* no _SC_PAGESIZE */
-
-#endif /* no HAVE_GETPAGESIZE */
-
-int
-main ()
-{
- char *data, *data2, *data3;
- const char *cdata2;
- int i, pagesize;
- int fd, fd2;
-
- pagesize = getpagesize ();
-
- /* First, make a file with some known garbage in it. */
- data = (char *) malloc (pagesize);
- if (!data)
- return 1;
- for (i = 0; i < pagesize; ++i)
- *(data + i) = rand ();
- umask (0);
- fd = creat ("conftest.mmap", 0600);
- if (fd < 0)
- return 2;
- if (write (fd, data, pagesize) != pagesize)
- return 3;
- close (fd);
-
- /* Next, check that the tail of a page is zero-filled. File must have
- non-zero length, otherwise we risk SIGBUS for entire page. */
- fd2 = open ("conftest.txt", O_RDWR | O_CREAT | O_TRUNC, 0600);
- if (fd2 < 0)
- return 4;
- cdata2 = "";
- if (write (fd2, cdata2, 1) != 1)
- return 5;
- data2 = (char *) mmap (0, pagesize, PROT_READ | PROT_WRITE, MAP_SHARED, fd2, 0L);
- if (data2 == MAP_FAILED)
- return 6;
- for (i = 0; i < pagesize; ++i)
- if (*(data2 + i))
- return 7;
- close (fd2);
- if (munmap (data2, pagesize))
- return 8;
-
- /* Next, try to mmap the file at a fixed address which already has
- something else allocated at it. If we can, also make sure that
- we see the same garbage. */
- fd = open ("conftest.mmap", O_RDWR);
- if (fd < 0)
- return 9;
- if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE,
- MAP_PRIVATE | MAP_FIXED, fd, 0L))
- return 10;
- for (i = 0; i < pagesize; ++i)
- if (*(data + i) != *(data2 + i))
- return 11;
-
- /* Finally, make sure that changes to the mapped area do not
- percolate back to the file as seen by read(). (This is a bug on
- some variants of i386 svr4.0.) */
- for (i = 0; i < pagesize; ++i)
- *(data2 + i) = *(data2 + i) + 1;
- data3 = (char *) malloc (pagesize);
- if (!data3)
- return 12;
- if (read (fd, data3, pagesize) != pagesize)
- return 13;
- for (i = 0; i < pagesize; ++i)
- if (*(data + i) != *(data3 + i))
- return 14;
- close (fd);
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_run "$LINENO"; then :
- ac_cv_func_mmap_fixed_mapped=yes
-else
- ac_cv_func_mmap_fixed_mapped=no
-fi
-rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
- conftest.$ac_objext conftest.beam conftest.$ac_ext
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mmap_fixed_mapped" >&5
-$as_echo "$ac_cv_func_mmap_fixed_mapped" >&6; }
-if test $ac_cv_func_mmap_fixed_mapped = yes; then
-
-$as_echo "#define HAVE_MMAP 1" >>confdefs.h
-
-fi
-rm -f conftest.mmap conftest.txt
-
- ASAN_OPTIONS="$save_ASAN_OPTIONS"
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing dlopen" >&5
-$as_echo_n "checking for library containing dlopen... " >&6; }
-if ${ac_cv_search_dlopen+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_func_search_save_LIBS=$LIBS
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char dlopen ();
-int
-main ()
-{
-return dlopen ();
- ;
- return 0;
-}
-_ACEOF
-for ac_lib in '' dl; do
- if test -z "$ac_lib"; then
- ac_res="none required"
- else
- ac_res=-l$ac_lib
- LIBS="-l$ac_lib $ac_func_search_save_LIBS"
- fi
- if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_search_dlopen=$ac_res
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext
- if ${ac_cv_search_dlopen+:} false; then :
- break
-fi
-done
-if ${ac_cv_search_dlopen+:} false; then :
-
-else
- ac_cv_search_dlopen=no
-fi
-rm conftest.$ac_ext
-LIBS=$ac_func_search_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_dlopen" >&5
-$as_echo "$ac_cv_search_dlopen" >&6; }
-ac_res=$ac_cv_search_dlopen
-if test "$ac_res" != no; then :
- test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
-
-fi
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a known getopt prototype in unistd.h" >&5
-$as_echo_n "checking for a known getopt prototype in unistd.h... " >&6; }
-if ${ld_cv_decl_getopt_unistd_h+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <unistd.h>
-int
-main ()
-{
-extern int getopt (int, char *const*, const char *);
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ld_cv_decl_getopt_unistd_h=yes
-else
- ld_cv_decl_getopt_unistd_h=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_cv_decl_getopt_unistd_h" >&5
-$as_echo "$ld_cv_decl_getopt_unistd_h" >&6; }
-if test $ld_cv_decl_getopt_unistd_h = yes; then
-
-$as_echo "#define HAVE_DECL_GETOPT 1" >>confdefs.h
-
-fi
-
-# Link in zlib/zstd if we can. This allows us to read and write
-# compressed debug sections.
-
- # Use the system's zlib library.
- zlibdir="-L\$(top_builddir)/../zlib"
- zlibinc="-I\$(top_srcdir)/../zlib"
-
-# Check whether --with-system-zlib was given.
-if test "${with_system_zlib+set}" = set; then :
- withval=$with_system_zlib; if test x$with_system_zlib = xyes ; then
- zlibdir=
- zlibinc=
- fi
-
-fi
-
-
-
-
-
-
-# Check whether --with-zstd was given.
-if test "${with_zstd+set}" = set; then :
- withval=$with_zstd;
-else
- with_zstd=auto
-fi
-
-
-if test "$with_zstd" != no; then :
-
-pkg_failed=no
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for libzstd >= 1.4.0" >&5
-$as_echo_n "checking for libzstd >= 1.4.0... " >&6; }
-
-if test -n "$ZSTD_CFLAGS"; then
- pkg_cv_ZSTD_CFLAGS="$ZSTD_CFLAGS"
- elif test -n "$PKG_CONFIG"; then
- if test -n "$PKG_CONFIG" && \
- { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libzstd >= 1.4.0\""; } >&5
- ($PKG_CONFIG --exists --print-errors "libzstd >= 1.4.0") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- pkg_cv_ZSTD_CFLAGS=`$PKG_CONFIG --cflags "libzstd >= 1.4.0" 2>/dev/null`
- test "x$?" != "x0" && pkg_failed=yes
-else
- pkg_failed=yes
-fi
- else
- pkg_failed=untried
-fi
-if test -n "$ZSTD_LIBS"; then
- pkg_cv_ZSTD_LIBS="$ZSTD_LIBS"
- elif test -n "$PKG_CONFIG"; then
- if test -n "$PKG_CONFIG" && \
- { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libzstd >= 1.4.0\""; } >&5
- ($PKG_CONFIG --exists --print-errors "libzstd >= 1.4.0") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- pkg_cv_ZSTD_LIBS=`$PKG_CONFIG --libs "libzstd >= 1.4.0" 2>/dev/null`
- test "x$?" != "x0" && pkg_failed=yes
-else
- pkg_failed=yes
-fi
- else
- pkg_failed=untried
-fi
-
-if test $pkg_failed = no; then
- pkg_save_LDFLAGS="$LDFLAGS"
- LDFLAGS="$LDFLAGS $pkg_cv_ZSTD_LIBS"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
-
-else
- pkg_failed=yes
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LDFLAGS=$pkg_save_LDFLAGS
-fi
-
-
-
-if test $pkg_failed = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-
-if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
- _pkg_short_errors_supported=yes
-else
- _pkg_short_errors_supported=no
-fi
- if test $_pkg_short_errors_supported = yes; then
- ZSTD_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libzstd >= 1.4.0" 2>&1`
- else
- ZSTD_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libzstd >= 1.4.0" 2>&1`
- fi
- # Put the nasty error message in config.log where it belongs
- echo "$ZSTD_PKG_ERRORS" >&5
-
-
- if test "$with_zstd" = yes; then
- as_fn_error $? "--with-zstd was given, but pkgconfig/libzstd.pc is not found" "$LINENO" 5
- fi
-
-elif test $pkg_failed = untried; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-
- if test "$with_zstd" = yes; then
- as_fn_error $? "--with-zstd was given, but pkgconfig/libzstd.pc is not found" "$LINENO" 5
- fi
-
-else
- ZSTD_CFLAGS=$pkg_cv_ZSTD_CFLAGS
- ZSTD_LIBS=$pkg_cv_ZSTD_LIBS
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-
-
-$as_echo "#define HAVE_ZSTD 1" >>confdefs.h
-
-
-fi
-
-fi
-
-
-# target-specific stuff:
-
-all_targets=
-EMUL=
-all_emuls=
-all_emul_extras=
-all_libpath=
-TDIRS=
-
-elf_list_options=false
-elf_shlib_list_options=false
-elf_plt_unwind_list_options=false
-for targ_alias in `echo $target_alias $enable_targets | sed 's/,/ /g'`
-do
- if test "$targ_alias" = "all"; then
- all_targets=true
- elf_list_options=true
- elf_shlib_list_options=true
- elf_plt_unwind_list_options=true
- else
- # Canonicalize the secondary target names.
- result=`$ac_config_sub $targ_alias 2>/dev/null`
- if test -n "$result"; then
- targ=$result
- else
- targ=$targ_alias
- fi
-
- . ${srcdir}/configure.tgt
-
- if test "$targ" = "$target"; then
- EMUL=$targ_emul
- fi
-
- if test x${enable_64_bit_bfd} = xno; then
- . ${srcdir}/../bfd/config.bfd
- fi
-
- if test x${enable_64_bit_bfd} = xyes; then
- targ_extra_emuls="$targ_extra_emuls $targ64_extra_emuls"
- targ_extra_libpath="$targ_extra_libpath $targ64_extra_libpath"
- fi
-
- for i in $targ_emul $targ_extra_emuls $targ_extra_libpath; do
- case " $all_emuls " in
- *" e${i}.o "*) ;;
- *)
- all_emuls="$all_emuls e${i}.o"
- eval result=\$tdir_$i
- test -z "$result" && result=$targ_alias
- TDIRS="$TDIRS
-tdir_$i=$result"
- case "${i}" in
- *elf*)
- elf_list_options=true
- ;;
- *)
- if $GREP "TEMPLATE_NAME=elf" ${srcdir}/emulparams/${i}.sh >/dev/null 2>/dev/null; then
- elf_list_options=true
- fi
- ;;
- esac
- if test "$elf_list_options" = "true"; then
- source_sh()
- {
- . $1
- }
- source_sh ${srcdir}/emulparams/${i}.sh
- if test x${GENERATE_SHLIB_SCRIPT} = xyes; then
- elf_shlib_list_options=true
- fi
- if test x${PLT_UNWIND} = xyes; then
- elf_plt_unwind_list_options=true
- fi
- fi
- ;;
- esac
- done
-
- for i in $targ_emul $targ_extra_libpath; do
- case " $all_libpath " in
- *" ${i} "*) ;;
- *)
- if test -z "$all_libpath"; then
- all_libpath=${i}
- else
- all_libpath="$all_libpath ${i}"
- fi
- ;;
- esac
- done
-
- for i in $targ_extra_ofiles; do
- case " $all_emul_extras " in
- *" ${i} "*) ;;
- *)
- all_emul_extras="$all_emul_extras ${i}"
- ;;
- esac
- done
-
- fi
-done
-
-if test x$ac_default_compressed_debug_sections = xyes ; then
-
-$as_echo "#define DEFAULT_FLAG_COMPRESS_DEBUG 1" >>confdefs.h
-
-fi
-
-
-cat >>confdefs.h <<_ACEOF
-#define DEFAULT_COMPRESSED_DEBUG_ALGORITHM $ac_default_compressed_debug_sections_algorithm
-_ACEOF
-
-
-if test "${ac_default_new_dtags}" = unset; then
- ac_default_new_dtags=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define DEFAULT_NEW_DTAGS $ac_default_new_dtags
-_ACEOF
-
-
-if test "${ac_default_ld_z_relro}" = unset; then
- ac_default_ld_z_relro=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define DEFAULT_LD_Z_RELRO $ac_default_ld_z_relro
-_ACEOF
-
-
-ac_default_ld_textrel_check_warning=0
-case "${ac_default_ld_textrel_check}" in
- unset|no)
- ac_default_ld_textrel_check=textrel_check_none
- ;;
- yes|warning)
- ac_default_ld_textrel_check=textrel_check_warning
- ac_default_ld_textrel_check_warning=1
- ;;
- error)
- ac_default_ld_textrel_check=textrel_check_error
- ;;
-esac
-
-cat >>confdefs.h <<_ACEOF
-#define DEFAULT_LD_TEXTREL_CHECK $ac_default_ld_textrel_check
-_ACEOF
-
-
-cat >>confdefs.h <<_ACEOF
-#define DEFAULT_LD_TEXTREL_CHECK_WARNING $ac_default_ld_textrel_check_warning
-_ACEOF
-
-
-if test "${ac_default_ld_z_separate_code}" = unset; then
- ac_default_ld_z_separate_code=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define DEFAULT_LD_Z_SEPARATE_CODE $ac_default_ld_z_separate_code
-_ACEOF
-
-
-if test "${ac_default_ld_rosegment}" = unset; then
- ac_default_ld_rosegment=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define DEFAULT_LD_ROSEGMENT $ac_default_ld_rosegment
-_ACEOF
-
-
-if test "${ac_default_ld_z_mark_plt}" = unset; then
- ac_default_ld_z_mark_plt=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define DEFAULT_LD_Z_MARK_PLT $ac_default_ld_z_mark_plt
-_ACEOF
-
-
-
-
-cat >>confdefs.h <<_ACEOF
-#define DEFAULT_LD_WARN_EXECSTACK $ac_default_ld_warn_execstack
-_ACEOF
-
-
-
-cat >>confdefs.h <<_ACEOF
-#define DEFAULT_LD_ERROR_EXECSTACK $ac_default_ld_error_execstack
-_ACEOF
-
-
-if test "${ac_default_ld_warn_rwx_segments}" = unset; then
- ac_default_ld_warn_rwx_segments=1
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define DEFAULT_LD_WARN_RWX_SEGMENTS $ac_default_ld_warn_rwx_segments
-_ACEOF
-
-
-
-cat >>confdefs.h <<_ACEOF
-#define DEFAULT_LD_ERROR_RWX_SEGMENTS $ac_default_ld_error_rwx_segments
-_ACEOF
-
-
-if test "${ac_default_ld_default_execstack}" = unset; then
- ac_default_ld_default_execstack=1
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define DEFAULT_LD_EXECSTACK $ac_default_ld_default_execstack
-_ACEOF
-
-
-
-if test "${ac_support_error_handling_script}" = unset; then
- ac_support_error_handling_script=1
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define SUPPORT_ERROR_HANDLING_SCRIPT $ac_support_error_handling_script
-_ACEOF
-
-
-
-cat >>confdefs.h <<_ACEOF
-#define DEFAULT_EMIT_SYSV_HASH $ac_default_emit_sysv_hash
-_ACEOF
-
-
-
-cat >>confdefs.h <<_ACEOF
-#define DEFAULT_EMIT_GNU_HASH $ac_default_emit_gnu_hash
-_ACEOF
-
-
-
-
-
-
-
-
-
-
-if test x${all_targets} = xtrue; then
- if test x${enable_64_bit_bfd} = xyes; then
- EMULATION_OFILES='$(ALL_EMULATIONS) $(ALL_64_EMULATIONS)'
- EMUL_EXTRA_OFILES='$(ALL_EMUL_EXTRA_OFILES) $(ALL_64_EMUL_EXTRA_OFILES)'
- else
- EMULATION_OFILES='$(ALL_EMULATIONS)'
- EMUL_EXTRA_OFILES='$(ALL_EMUL_EXTRA_OFILES)'
- fi
-else
- EMULATION_OFILES=$all_emuls
- EMUL_EXTRA_OFILES=$all_emul_extras
-fi
-
-
-
-
-EMULATION_LIBPATH=$all_libpath
-
-
-if test x${enable_static} = xno; then
- TESTBFDLIB="-Wl,--rpath,../bfd/.libs ../bfd/.libs/libbfd.so"
- TESTCTFLIB="-Wl,--rpath,../libctf/.libs ../libctf/.libs/libctf.so"
- TESTSFRAMELIB="-Wl,--rpath,../libsframe/.libs ../libsframe/.libs/libsframe.so"
-else
- TESTBFDLIB="../bfd/.libs/libbfd.a"
- TESTCTFLIB="../libctf/.libs/libctf.a"
- TESTSFRAMELIB="../libsframe/.libs/libsframe.a"
-fi
-if test "${enable_libctf}" = no; then
- TESTCTFLIB=
-fi
-
-
-
-
-target_vendor=${target_vendor=$host_vendor}
-case "$target_vendor" in
- hp) EXTRA_SHLIB_EXTENSION=".sl" ;;
- *) EXTRA_SHLIB_EXTENSION= ;;
-esac
-
-case "$target_os" in
- lynxos) EXTRA_SHLIB_EXTENSION=".a" ;;
-esac
-
-if test x${EXTRA_SHLIB_EXTENSION} != x ; then
-
-cat >>confdefs.h <<_ACEOF
-#define EXTRA_SHLIB_EXTENSION "$EXTRA_SHLIB_EXTENSION"
-_ACEOF
-
-fi
-
-ac_config_commands="$ac_config_commands default"
-
-
-
-
-
-
-
-ac_config_files="$ac_config_files Makefile po/Makefile.in:po/Make-in"
-
-cat >confcache <<\_ACEOF
-# This file is a shell script that caches the results of configure
-# tests run on this system so they can be shared between configure
-# scripts and configure runs, see configure's option --config-cache.
-# It is not useful on other systems. If it contains results you don't
-# want to keep, you may remove or edit it.
-#
-# config.status only pays attention to the cache file if you give it
-# the --recheck option to rerun configure.
-#
-# `ac_cv_env_foo' variables (set or unset) will be overridden when
-# loading this file, other *unset* `ac_cv_foo' will be assigned the
-# following values.
-
-_ACEOF
-
-# The following way of writing the cache mishandles newlines in values,
-# but we know of no workaround that is simple, portable, and efficient.
-# So, we kill variables containing newlines.
-# Ultrix sh set writes to stderr and can't be redirected directly,
-# and sets the high bit in the cache file unless we assign to the vars.
-(
- for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
- eval ac_val=\$$ac_var
- case $ac_val in #(
- *${as_nl}*)
- case $ac_var in #(
- *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
-$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
- esac
- case $ac_var in #(
- _ | IFS | as_nl) ;; #(
- BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
- *) { eval $ac_var=; unset $ac_var;} ;;
- esac ;;
- esac
- done
-
- (set) 2>&1 |
- case $as_nl`(ac_space=' '; set) 2>&1` in #(
- *${as_nl}ac_space=\ *)
- # `set' does not quote correctly, so add quotes: double-quote
- # substitution turns \\\\ into \\, and sed turns \\ into \.
- sed -n \
- "s/'/'\\\\''/g;
- s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
- ;; #(
- *)
- # `set' quotes correctly as required by POSIX, so do not add quotes.
- sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
- ;;
- esac |
- sort
-) |
- sed '
- /^ac_cv_env_/b end
- t clear
- :clear
- s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
- t end
- s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
- :end' >>confcache
-if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
- if test -w "$cache_file"; then
- if test "x$cache_file" != "x/dev/null"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
-$as_echo "$as_me: updating cache $cache_file" >&6;}
- if test ! -f "$cache_file" || test -h "$cache_file"; then
- cat confcache >"$cache_file"
- else
- case $cache_file in #(
- */* | ?:*)
- mv -f confcache "$cache_file"$$ &&
- mv -f "$cache_file"$$ "$cache_file" ;; #(
- *)
- mv -f confcache "$cache_file" ;;
- esac
- fi
- fi
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
-$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
- fi
-fi
-rm -f confcache
-
-test "x$prefix" = xNONE && prefix=$ac_default_prefix
-# Let make expand exec_prefix.
-test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
-
-DEFS=-DHAVE_CONFIG_H
-
-ac_libobjs=
-ac_ltlibobjs=
-U=
-for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
- # 1. Remove the extension, and $U if already installed.
- ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
- ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
- # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
- # will be set to the directory where LIBOBJS objects are built.
- as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
- as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
-done
-LIBOBJS=$ac_libobjs
-
-LTLIBOBJS=$ac_ltlibobjs
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking that generated files are newer than configure" >&5
-$as_echo_n "checking that generated files are newer than configure... " >&6; }
- if test -n "$am_sleep_pid"; then
- # Hide warnings about reused PIDs.
- wait $am_sleep_pid 2>/dev/null
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: done" >&5
-$as_echo "done" >&6; }
- if test -n "$EXEEXT"; then
- am__EXEEXT_TRUE=
- am__EXEEXT_FALSE='#'
-else
- am__EXEEXT_TRUE='#'
- am__EXEEXT_FALSE=
-fi
-
-if test -z "${MAINTAINER_MODE_TRUE}" && test -z "${MAINTAINER_MODE_FALSE}"; then
- as_fn_error $? "conditional \"MAINTAINER_MODE\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
- as_fn_error $? "conditional \"AMDEP\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
- as_fn_error $? "conditional \"am__fastdepCC\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${am__fastdepCXX_TRUE}" && test -z "${am__fastdepCXX_FALSE}"; then
- as_fn_error $? "conditional \"am__fastdepCXX\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${ENABLE_BFD_64_BIT_TRUE}" && test -z "${ENABLE_BFD_64_BIT_FALSE}"; then
- as_fn_error $? "conditional \"ENABLE_BFD_64_BIT\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${ENABLE_LIBCTF_TRUE}" && test -z "${ENABLE_LIBCTF_FALSE}"; then
- as_fn_error $? "conditional \"ENABLE_LIBCTF\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${MAINTAINER_MODE_TRUE}" && test -z "${MAINTAINER_MODE_FALSE}"; then
- as_fn_error $? "conditional \"MAINTAINER_MODE\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${GENINSRC_NEVER_TRUE}" && test -z "${GENINSRC_NEVER_FALSE}"; then
- as_fn_error $? "conditional \"GENINSRC_NEVER\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-
-: "${CONFIG_STATUS=./config.status}"
-ac_write_fail=0
-ac_clean_files_save=$ac_clean_files
-ac_clean_files="$ac_clean_files $CONFIG_STATUS"
-{ $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
-$as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
-as_write_fail=0
-cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
-#! $SHELL
-# Generated by $as_me.
-# Run this file to recreate the current configuration.
-# Compiler output produced by configure, useful for debugging
-# configure, is in config.log if it exists.
-
-debug=false
-ac_cs_recheck=false
-ac_cs_silent=false
-
-SHELL=\${CONFIG_SHELL-$SHELL}
-export SHELL
-_ASEOF
-cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
-## -------------------- ##
-## M4sh Initialization. ##
-## -------------------- ##
-
-# Be more Bourne compatible
-DUALCASE=1; export DUALCASE # for MKS sh
-if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
- emulate sh
- NULLCMD=:
- # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
- # is contrary to our usage. Disable this feature.
- alias -g '${1+"$@"}'='"$@"'
- setopt NO_GLOB_SUBST
-else
- case `(set -o) 2>/dev/null` in #(
- *posix*) :
- set -o posix ;; #(
- *) :
- ;;
-esac
-fi
-
-
-as_nl='
-'
-export as_nl
-# Printing a long string crashes Solaris 7 /usr/bin/printf.
-as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
-as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
-as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
-# Prefer a ksh shell builtin over an external printf program on Solaris,
-# but without wasting forks for bash or zsh.
-if test -z "$BASH_VERSION$ZSH_VERSION" \
- && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
- as_echo='print -r --'
- as_echo_n='print -rn --'
-elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
- as_echo='printf %s\n'
- as_echo_n='printf %s'
-else
- if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
- as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
- as_echo_n='/usr/ucb/echo -n'
- else
- as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
- as_echo_n_body='eval
- arg=$1;
- case $arg in #(
- *"$as_nl"*)
- expr "X$arg" : "X\\(.*\\)$as_nl";
- arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
- esac;
- expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
- '
- export as_echo_n_body
- as_echo_n='sh -c $as_echo_n_body as_echo'
- fi
- export as_echo_body
- as_echo='sh -c $as_echo_body as_echo'
-fi
-
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- PATH_SEPARATOR=:
- (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
- (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
- PATH_SEPARATOR=';'
- }
-fi
-
-
-# IFS
-# We need space, tab and new line, in precisely that order. Quoting is
-# there to prevent editors from complaining about space-tab.
-# (If _AS_PATH_WALK were called with IFS unset, it would disable word
-# splitting by setting IFS to empty value.)
-IFS=" "" $as_nl"
-
-# Find who we are. Look in the path if we contain no directory separator.
-as_myself=
-case $0 in #((
- *[\\/]* ) as_myself=$0 ;;
- *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
- done
-IFS=$as_save_IFS
-
- ;;
-esac
-# We did not find ourselves, most probably we were run as `sh COMMAND'
-# in which case we are not to be found in the path.
-if test "x$as_myself" = x; then
- as_myself=$0
-fi
-if test ! -f "$as_myself"; then
- $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
- exit 1
-fi
-
-# Unset variables that we do not need and which cause bugs (e.g. in
-# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
-# suppresses any "Segmentation fault" message there. '((' could
-# trigger a bug in pdksh 5.2.14.
-for as_var in BASH_ENV ENV MAIL MAILPATH
-do eval test x\${$as_var+set} = xset \
- && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
-done
-PS1='$ '
-PS2='> '
-PS4='+ '
-
-# NLS nuisances.
-LC_ALL=C
-export LC_ALL
-LANGUAGE=C
-export LANGUAGE
-
-# CDPATH.
-(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
-
-
-# as_fn_error STATUS ERROR [LINENO LOG_FD]
-# ----------------------------------------
-# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
-# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
-# script with STATUS, using 1 if that was 0.
-as_fn_error ()
-{
- as_status=$1; test $as_status -eq 0 && as_status=1
- if test "$4"; then
- as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
- fi
- $as_echo "$as_me: error: $2" >&2
- as_fn_exit $as_status
-} # as_fn_error
-
-
-# as_fn_set_status STATUS
-# -----------------------
-# Set $? to STATUS, without forking.
-as_fn_set_status ()
-{
- return $1
-} # as_fn_set_status
-
-# as_fn_exit STATUS
-# -----------------
-# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
-as_fn_exit ()
-{
- set +e
- as_fn_set_status $1
- exit $1
-} # as_fn_exit
-
-# as_fn_unset VAR
-# ---------------
-# Portably unset VAR.
-as_fn_unset ()
-{
- { eval $1=; unset $1;}
-}
-as_unset=as_fn_unset
-# as_fn_append VAR VALUE
-# ----------------------
-# Append the text in VALUE to the end of the definition contained in VAR. Take
-# advantage of any shell optimizations that allow amortized linear growth over
-# repeated appends, instead of the typical quadratic growth present in naive
-# implementations.
-if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
- eval 'as_fn_append ()
- {
- eval $1+=\$2
- }'
-else
- as_fn_append ()
- {
- eval $1=\$$1\$2
- }
-fi # as_fn_append
-
-# as_fn_arith ARG...
-# ------------------
-# Perform arithmetic evaluation on the ARGs, and store the result in the
-# global $as_val. Take advantage of shells that can avoid forks. The arguments
-# must be portable across $(()) and expr.
-if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
- eval 'as_fn_arith ()
- {
- as_val=$(( $* ))
- }'
-else
- as_fn_arith ()
- {
- as_val=`expr "$@" || test $? -eq 1`
- }
-fi # as_fn_arith
-
-
-if expr a : '\(a\)' >/dev/null 2>&1 &&
- test "X`expr 00001 : '.*\(...\)'`" = X001; then
- as_expr=expr
-else
- as_expr=false
-fi
-
-if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
- as_basename=basename
-else
- as_basename=false
-fi
-
-if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
- as_dirname=dirname
-else
- as_dirname=false
-fi
-
-as_me=`$as_basename -- "$0" ||
-$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
- X"$0" : 'X\(//\)$' \| \
- X"$0" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X/"$0" |
- sed '/^.*\/\([^/][^/]*\)\/*$/{
- s//\1/
- q
- }
- /^X\/\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\/\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
-
-# Avoid depending upon Character Ranges.
-as_cr_letters='abcdefghijklmnopqrstuvwxyz'
-as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
-as_cr_Letters=$as_cr_letters$as_cr_LETTERS
-as_cr_digits='0123456789'
-as_cr_alnum=$as_cr_Letters$as_cr_digits
-
-ECHO_C= ECHO_N= ECHO_T=
-case `echo -n x` in #(((((
--n*)
- case `echo 'xy\c'` in
- *c*) ECHO_T=' ';; # ECHO_T is single tab character.
- xy) ECHO_C='\c';;
- *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
- ECHO_T=' ';;
- esac;;
-*)
- ECHO_N='-n';;
-esac
-
-rm -f conf$$ conf$$.exe conf$$.file
-if test -d conf$$.dir; then
- rm -f conf$$.dir/conf$$.file
-else
- rm -f conf$$.dir
- mkdir conf$$.dir 2>/dev/null
-fi
-if (echo >conf$$.file) 2>/dev/null; then
- if ln -s conf$$.file conf$$ 2>/dev/null; then
- as_ln_s='ln -s'
- # ... but there are two gotchas:
- # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
- # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
- # In both cases, we have to default to `cp -pR'.
- ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
- as_ln_s='cp -pR'
- elif ln conf$$.file conf$$ 2>/dev/null; then
- as_ln_s=ln
- else
- as_ln_s='cp -pR'
- fi
-else
- as_ln_s='cp -pR'
-fi
-rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
-rmdir conf$$.dir 2>/dev/null
-
-
-# as_fn_mkdir_p
-# -------------
-# Create "$as_dir" as a directory, including parents if necessary.
-as_fn_mkdir_p ()
-{
-
- case $as_dir in #(
- -*) as_dir=./$as_dir;;
- esac
- test -d "$as_dir" || eval $as_mkdir_p || {
- as_dirs=
- while :; do
- case $as_dir in #(
- *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
- *) as_qdir=$as_dir;;
- esac
- as_dirs="'$as_qdir' $as_dirs"
- as_dir=`$as_dirname -- "$as_dir" ||
-$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$as_dir" : 'X\(//\)[^/]' \| \
- X"$as_dir" : 'X\(//\)$' \| \
- X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$as_dir" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
- test -d "$as_dir" && break
- done
- test -z "$as_dirs" || eval "mkdir $as_dirs"
- } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
-
-
-} # as_fn_mkdir_p
-if mkdir -p . 2>/dev/null; then
- as_mkdir_p='mkdir -p "$as_dir"'
-else
- test -d ./-p && rmdir ./-p
- as_mkdir_p=false
-fi
-
-
-# as_fn_executable_p FILE
-# -----------------------
-# Test if FILE is an executable regular file.
-as_fn_executable_p ()
-{
- test -f "$1" && test -x "$1"
-} # as_fn_executable_p
-as_test_x='test -x'
-as_executable_p=as_fn_executable_p
-
-# Sed expression to map a string onto a valid CPP name.
-as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
-
-# Sed expression to map a string onto a valid variable name.
-as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
-
-
-exec 6>&1
-## ----------------------------------- ##
-## Main body of $CONFIG_STATUS script. ##
-## ----------------------------------- ##
-_ASEOF
-test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
-
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-# Save the log message, to keep $0 and so on meaningful, and to
-# report actual input values of CONFIG_FILES etc. instead of their
-# values after options handling.
-ac_log="
-This file was extended by ld $as_me 2.43.1, which was
-generated by GNU Autoconf 2.69. Invocation command line was
-
- CONFIG_FILES = $CONFIG_FILES
- CONFIG_HEADERS = $CONFIG_HEADERS
- CONFIG_LINKS = $CONFIG_LINKS
- CONFIG_COMMANDS = $CONFIG_COMMANDS
- $ $0 $@
-
-on `(hostname || uname -n) 2>/dev/null | sed 1q`
-"
-
-_ACEOF
-
-case $ac_config_files in *"
-"*) set x $ac_config_files; shift; ac_config_files=$*;;
-esac
-
-case $ac_config_headers in *"
-"*) set x $ac_config_headers; shift; ac_config_headers=$*;;
-esac
-
-
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-# Files that config.status was made for.
-config_files="$ac_config_files"
-config_headers="$ac_config_headers"
-config_commands="$ac_config_commands"
-
-_ACEOF
-
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-ac_cs_usage="\
-\`$as_me' instantiates files and other configuration actions
-from templates according to the current configuration. Unless the files
-and actions are specified as TAGs, all are instantiated by default.
-
-Usage: $0 [OPTION]... [TAG]...
-
- -h, --help print this help, then exit
- -V, --version print version number and configuration settings, then exit
- --config print configuration, then exit
- -q, --quiet, --silent
- do not print progress messages
- -d, --debug don't remove temporary files
- --recheck update $as_me by reconfiguring in the same conditions
- --file=FILE[:TEMPLATE]
- instantiate the configuration file FILE
- --header=FILE[:TEMPLATE]
- instantiate the configuration header FILE
-
-Configuration files:
-$config_files
-
-Configuration headers:
-$config_headers
-
-Configuration commands:
-$config_commands
-
-Report bugs to the package provider."
-
-_ACEOF
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
-ac_cs_version="\\
-ld config.status 2.43.1
-configured by $0, generated by GNU Autoconf 2.69,
- with options \\"\$ac_cs_config\\"
-
-Copyright (C) 2012 Free Software Foundation, Inc.
-This config.status script is free software; the Free Software Foundation
-gives unlimited permission to copy, distribute and modify it."
-
-ac_pwd='$ac_pwd'
-srcdir='$srcdir'
-INSTALL='$INSTALL'
-MKDIR_P='$MKDIR_P'
-AWK='$AWK'
-test -n "\$AWK" || AWK=awk
-_ACEOF
-
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-# The default lists apply if the user does not specify any file.
-ac_need_defaults=:
-while test $# != 0
-do
- case $1 in
- --*=?*)
- ac_option=`expr "X$1" : 'X\([^=]*\)='`
- ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
- ac_shift=:
- ;;
- --*=)
- ac_option=`expr "X$1" : 'X\([^=]*\)='`
- ac_optarg=
- ac_shift=:
- ;;
- *)
- ac_option=$1
- ac_optarg=$2
- ac_shift=shift
- ;;
- esac
-
- case $ac_option in
- # Handling of the options.
- -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
- ac_cs_recheck=: ;;
- --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
- $as_echo "$ac_cs_version"; exit ;;
- --config | --confi | --conf | --con | --co | --c )
- $as_echo "$ac_cs_config"; exit ;;
- --debug | --debu | --deb | --de | --d | -d )
- debug=: ;;
- --file | --fil | --fi | --f )
- $ac_shift
- case $ac_optarg in
- *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
- '') as_fn_error $? "missing file argument" ;;
- esac
- as_fn_append CONFIG_FILES " '$ac_optarg'"
- ac_need_defaults=false;;
- --header | --heade | --head | --hea )
- $ac_shift
- case $ac_optarg in
- *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
- esac
- as_fn_append CONFIG_HEADERS " '$ac_optarg'"
- ac_need_defaults=false;;
- --he | --h)
- # Conflict between --help and --header
- as_fn_error $? "ambiguous option: \`$1'
-Try \`$0 --help' for more information.";;
- --help | --hel | -h )
- $as_echo "$ac_cs_usage"; exit ;;
- -q | -quiet | --quiet | --quie | --qui | --qu | --q \
- | -silent | --silent | --silen | --sile | --sil | --si | --s)
- ac_cs_silent=: ;;
-
- # This is an error.
- -*) as_fn_error $? "unrecognized option: \`$1'
-Try \`$0 --help' for more information." ;;
-
- *) as_fn_append ac_config_targets " $1"
- ac_need_defaults=false ;;
-
- esac
- shift
-done
-
-ac_configure_extra_args=
-
-if $ac_cs_silent; then
- exec 6>/dev/null
- ac_configure_extra_args="$ac_configure_extra_args --silent"
-fi
-
-_ACEOF
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-if \$ac_cs_recheck; then
- set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
- shift
- \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
- CONFIG_SHELL='$SHELL'
- export CONFIG_SHELL
- exec "\$@"
-fi
-
-_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-exec 5>>config.log
-{
- echo
- sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
-## Running $as_me. ##
-_ASBOX
- $as_echo "$ac_log"
-} >&5
-
-_ACEOF
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-#
-# INIT-COMMANDS
-#
-AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"
-
-
-# The HP-UX ksh and POSIX shell print the target directory to stdout
-# if CDPATH is set.
-(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
-
-sed_quote_subst='$sed_quote_subst'
-double_quote_subst='$double_quote_subst'
-delay_variable_subst='$delay_variable_subst'
-macro_version='`$ECHO "$macro_version" | $SED "$delay_single_quote_subst"`'
-macro_revision='`$ECHO "$macro_revision" | $SED "$delay_single_quote_subst"`'
-enable_shared='`$ECHO "$enable_shared" | $SED "$delay_single_quote_subst"`'
-enable_static='`$ECHO "$enable_static" | $SED "$delay_single_quote_subst"`'
-pic_mode='`$ECHO "$pic_mode" | $SED "$delay_single_quote_subst"`'
-enable_fast_install='`$ECHO "$enable_fast_install" | $SED "$delay_single_quote_subst"`'
-SHELL='`$ECHO "$SHELL" | $SED "$delay_single_quote_subst"`'
-ECHO='`$ECHO "$ECHO" | $SED "$delay_single_quote_subst"`'
-host_alias='`$ECHO "$host_alias" | $SED "$delay_single_quote_subst"`'
-host='`$ECHO "$host" | $SED "$delay_single_quote_subst"`'
-host_os='`$ECHO "$host_os" | $SED "$delay_single_quote_subst"`'
-build_alias='`$ECHO "$build_alias" | $SED "$delay_single_quote_subst"`'
-build='`$ECHO "$build" | $SED "$delay_single_quote_subst"`'
-build_os='`$ECHO "$build_os" | $SED "$delay_single_quote_subst"`'
-SED='`$ECHO "$SED" | $SED "$delay_single_quote_subst"`'
-Xsed='`$ECHO "$Xsed" | $SED "$delay_single_quote_subst"`'
-GREP='`$ECHO "$GREP" | $SED "$delay_single_quote_subst"`'
-EGREP='`$ECHO "$EGREP" | $SED "$delay_single_quote_subst"`'
-FGREP='`$ECHO "$FGREP" | $SED "$delay_single_quote_subst"`'
-LD='`$ECHO "$LD" | $SED "$delay_single_quote_subst"`'
-NM='`$ECHO "$NM" | $SED "$delay_single_quote_subst"`'
-LN_S='`$ECHO "$LN_S" | $SED "$delay_single_quote_subst"`'
-max_cmd_len='`$ECHO "$max_cmd_len" | $SED "$delay_single_quote_subst"`'
-ac_objext='`$ECHO "$ac_objext" | $SED "$delay_single_quote_subst"`'
-exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`'
-lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`'
-lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`'
-lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`'
-reload_flag='`$ECHO "$reload_flag" | $SED "$delay_single_quote_subst"`'
-reload_cmds='`$ECHO "$reload_cmds" | $SED "$delay_single_quote_subst"`'
-OBJDUMP='`$ECHO "$OBJDUMP" | $SED "$delay_single_quote_subst"`'
-deplibs_check_method='`$ECHO "$deplibs_check_method" | $SED "$delay_single_quote_subst"`'
-file_magic_cmd='`$ECHO "$file_magic_cmd" | $SED "$delay_single_quote_subst"`'
-AR='`$ECHO "$AR" | $SED "$delay_single_quote_subst"`'
-AR_FLAGS='`$ECHO "$AR_FLAGS" | $SED "$delay_single_quote_subst"`'
-STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`'
-RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`'
-old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`'
-old_postuninstall_cmds='`$ECHO "$old_postuninstall_cmds" | $SED "$delay_single_quote_subst"`'
-old_archive_cmds='`$ECHO "$old_archive_cmds" | $SED "$delay_single_quote_subst"`'
-lock_old_archive_extraction='`$ECHO "$lock_old_archive_extraction" | $SED "$delay_single_quote_subst"`'
-CC='`$ECHO "$CC" | $SED "$delay_single_quote_subst"`'
-CFLAGS='`$ECHO "$CFLAGS" | $SED "$delay_single_quote_subst"`'
-compiler='`$ECHO "$compiler" | $SED "$delay_single_quote_subst"`'
-GCC='`$ECHO "$GCC" | $SED "$delay_single_quote_subst"`'
-lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$delay_single_quote_subst"`'
-lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`'
-lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`'
-lt_cv_sys_global_symbol_to_c_name_address_lib_prefix='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address_lib_prefix" | $SED "$delay_single_quote_subst"`'
-objdir='`$ECHO "$objdir" | $SED "$delay_single_quote_subst"`'
-MAGIC_CMD='`$ECHO "$MAGIC_CMD" | $SED "$delay_single_quote_subst"`'
-lt_prog_compiler_no_builtin_flag='`$ECHO "$lt_prog_compiler_no_builtin_flag" | $SED "$delay_single_quote_subst"`'
-lt_prog_compiler_wl='`$ECHO "$lt_prog_compiler_wl" | $SED "$delay_single_quote_subst"`'
-lt_prog_compiler_pic='`$ECHO "$lt_prog_compiler_pic" | $SED "$delay_single_quote_subst"`'
-lt_prog_compiler_static='`$ECHO "$lt_prog_compiler_static" | $SED "$delay_single_quote_subst"`'
-lt_cv_prog_compiler_c_o='`$ECHO "$lt_cv_prog_compiler_c_o" | $SED "$delay_single_quote_subst"`'
-need_locks='`$ECHO "$need_locks" | $SED "$delay_single_quote_subst"`'
-DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`'
-NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`'
-LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`'
-OTOOL='`$ECHO "$OTOOL" | $SED "$delay_single_quote_subst"`'
-OTOOL64='`$ECHO "$OTOOL64" | $SED "$delay_single_quote_subst"`'
-libext='`$ECHO "$libext" | $SED "$delay_single_quote_subst"`'
-shrext_cmds='`$ECHO "$shrext_cmds" | $SED "$delay_single_quote_subst"`'
-extract_expsyms_cmds='`$ECHO "$extract_expsyms_cmds" | $SED "$delay_single_quote_subst"`'
-archive_cmds_need_lc='`$ECHO "$archive_cmds_need_lc" | $SED "$delay_single_quote_subst"`'
-enable_shared_with_static_runtimes='`$ECHO "$enable_shared_with_static_runtimes" | $SED "$delay_single_quote_subst"`'
-export_dynamic_flag_spec='`$ECHO "$export_dynamic_flag_spec" | $SED "$delay_single_quote_subst"`'
-whole_archive_flag_spec='`$ECHO "$whole_archive_flag_spec" | $SED "$delay_single_quote_subst"`'
-compiler_needs_object='`$ECHO "$compiler_needs_object" | $SED "$delay_single_quote_subst"`'
-old_archive_from_new_cmds='`$ECHO "$old_archive_from_new_cmds" | $SED "$delay_single_quote_subst"`'
-old_archive_from_expsyms_cmds='`$ECHO "$old_archive_from_expsyms_cmds" | $SED "$delay_single_quote_subst"`'
-archive_cmds='`$ECHO "$archive_cmds" | $SED "$delay_single_quote_subst"`'
-archive_expsym_cmds='`$ECHO "$archive_expsym_cmds" | $SED "$delay_single_quote_subst"`'
-module_cmds='`$ECHO "$module_cmds" | $SED "$delay_single_quote_subst"`'
-module_expsym_cmds='`$ECHO "$module_expsym_cmds" | $SED "$delay_single_quote_subst"`'
-with_gnu_ld='`$ECHO "$with_gnu_ld" | $SED "$delay_single_quote_subst"`'
-allow_undefined_flag='`$ECHO "$allow_undefined_flag" | $SED "$delay_single_quote_subst"`'
-no_undefined_flag='`$ECHO "$no_undefined_flag" | $SED "$delay_single_quote_subst"`'
-hardcode_libdir_flag_spec='`$ECHO "$hardcode_libdir_flag_spec" | $SED "$delay_single_quote_subst"`'
-hardcode_libdir_flag_spec_ld='`$ECHO "$hardcode_libdir_flag_spec_ld" | $SED "$delay_single_quote_subst"`'
-hardcode_libdir_separator='`$ECHO "$hardcode_libdir_separator" | $SED "$delay_single_quote_subst"`'
-hardcode_direct='`$ECHO "$hardcode_direct" | $SED "$delay_single_quote_subst"`'
-hardcode_direct_absolute='`$ECHO "$hardcode_direct_absolute" | $SED "$delay_single_quote_subst"`'
-hardcode_minus_L='`$ECHO "$hardcode_minus_L" | $SED "$delay_single_quote_subst"`'
-hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_quote_subst"`'
-hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`'
-inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`'
-link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`'
-fix_srcfile_path='`$ECHO "$fix_srcfile_path" | $SED "$delay_single_quote_subst"`'
-always_export_symbols='`$ECHO "$always_export_symbols" | $SED "$delay_single_quote_subst"`'
-export_symbols_cmds='`$ECHO "$export_symbols_cmds" | $SED "$delay_single_quote_subst"`'
-exclude_expsyms='`$ECHO "$exclude_expsyms" | $SED "$delay_single_quote_subst"`'
-include_expsyms='`$ECHO "$include_expsyms" | $SED "$delay_single_quote_subst"`'
-prelink_cmds='`$ECHO "$prelink_cmds" | $SED "$delay_single_quote_subst"`'
-file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`'
-variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`'
-need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`'
-need_version='`$ECHO "$need_version" | $SED "$delay_single_quote_subst"`'
-version_type='`$ECHO "$version_type" | $SED "$delay_single_quote_subst"`'
-runpath_var='`$ECHO "$runpath_var" | $SED "$delay_single_quote_subst"`'
-shlibpath_var='`$ECHO "$shlibpath_var" | $SED "$delay_single_quote_subst"`'
-shlibpath_overrides_runpath='`$ECHO "$shlibpath_overrides_runpath" | $SED "$delay_single_quote_subst"`'
-libname_spec='`$ECHO "$libname_spec" | $SED "$delay_single_quote_subst"`'
-library_names_spec='`$ECHO "$library_names_spec" | $SED "$delay_single_quote_subst"`'
-soname_spec='`$ECHO "$soname_spec" | $SED "$delay_single_quote_subst"`'
-install_override_mode='`$ECHO "$install_override_mode" | $SED "$delay_single_quote_subst"`'
-postinstall_cmds='`$ECHO "$postinstall_cmds" | $SED "$delay_single_quote_subst"`'
-postuninstall_cmds='`$ECHO "$postuninstall_cmds" | $SED "$delay_single_quote_subst"`'
-finish_cmds='`$ECHO "$finish_cmds" | $SED "$delay_single_quote_subst"`'
-finish_eval='`$ECHO "$finish_eval" | $SED "$delay_single_quote_subst"`'
-hardcode_into_libs='`$ECHO "$hardcode_into_libs" | $SED "$delay_single_quote_subst"`'
-sys_lib_search_path_spec='`$ECHO "$sys_lib_search_path_spec" | $SED "$delay_single_quote_subst"`'
-sys_lib_dlsearch_path_spec='`$ECHO "$sys_lib_dlsearch_path_spec" | $SED "$delay_single_quote_subst"`'
-hardcode_action='`$ECHO "$hardcode_action" | $SED "$delay_single_quote_subst"`'
-enable_dlopen='`$ECHO "$enable_dlopen" | $SED "$delay_single_quote_subst"`'
-enable_dlopen_self='`$ECHO "$enable_dlopen_self" | $SED "$delay_single_quote_subst"`'
-enable_dlopen_self_static='`$ECHO "$enable_dlopen_self_static" | $SED "$delay_single_quote_subst"`'
-old_striplib='`$ECHO "$old_striplib" | $SED "$delay_single_quote_subst"`'
-striplib='`$ECHO "$striplib" | $SED "$delay_single_quote_subst"`'
-compiler_lib_search_dirs='`$ECHO "$compiler_lib_search_dirs" | $SED "$delay_single_quote_subst"`'
-predep_objects='`$ECHO "$predep_objects" | $SED "$delay_single_quote_subst"`'
-postdep_objects='`$ECHO "$postdep_objects" | $SED "$delay_single_quote_subst"`'
-predeps='`$ECHO "$predeps" | $SED "$delay_single_quote_subst"`'
-postdeps='`$ECHO "$postdeps" | $SED "$delay_single_quote_subst"`'
-compiler_lib_search_path='`$ECHO "$compiler_lib_search_path" | $SED "$delay_single_quote_subst"`'
-LD_CXX='`$ECHO "$LD_CXX" | $SED "$delay_single_quote_subst"`'
-reload_flag_CXX='`$ECHO "$reload_flag_CXX" | $SED "$delay_single_quote_subst"`'
-reload_cmds_CXX='`$ECHO "$reload_cmds_CXX" | $SED "$delay_single_quote_subst"`'
-old_archive_cmds_CXX='`$ECHO "$old_archive_cmds_CXX" | $SED "$delay_single_quote_subst"`'
-compiler_CXX='`$ECHO "$compiler_CXX" | $SED "$delay_single_quote_subst"`'
-GCC_CXX='`$ECHO "$GCC_CXX" | $SED "$delay_single_quote_subst"`'
-lt_prog_compiler_no_builtin_flag_CXX='`$ECHO "$lt_prog_compiler_no_builtin_flag_CXX" | $SED "$delay_single_quote_subst"`'
-lt_prog_compiler_wl_CXX='`$ECHO "$lt_prog_compiler_wl_CXX" | $SED "$delay_single_quote_subst"`'
-lt_prog_compiler_pic_CXX='`$ECHO "$lt_prog_compiler_pic_CXX" | $SED "$delay_single_quote_subst"`'
-lt_prog_compiler_static_CXX='`$ECHO "$lt_prog_compiler_static_CXX" | $SED "$delay_single_quote_subst"`'
-lt_cv_prog_compiler_c_o_CXX='`$ECHO "$lt_cv_prog_compiler_c_o_CXX" | $SED "$delay_single_quote_subst"`'
-archive_cmds_need_lc_CXX='`$ECHO "$archive_cmds_need_lc_CXX" | $SED "$delay_single_quote_subst"`'
-enable_shared_with_static_runtimes_CXX='`$ECHO "$enable_shared_with_static_runtimes_CXX" | $SED "$delay_single_quote_subst"`'
-export_dynamic_flag_spec_CXX='`$ECHO "$export_dynamic_flag_spec_CXX" | $SED "$delay_single_quote_subst"`'
-whole_archive_flag_spec_CXX='`$ECHO "$whole_archive_flag_spec_CXX" | $SED "$delay_single_quote_subst"`'
-compiler_needs_object_CXX='`$ECHO "$compiler_needs_object_CXX" | $SED "$delay_single_quote_subst"`'
-old_archive_from_new_cmds_CXX='`$ECHO "$old_archive_from_new_cmds_CXX" | $SED "$delay_single_quote_subst"`'
-old_archive_from_expsyms_cmds_CXX='`$ECHO "$old_archive_from_expsyms_cmds_CXX" | $SED "$delay_single_quote_subst"`'
-archive_cmds_CXX='`$ECHO "$archive_cmds_CXX" | $SED "$delay_single_quote_subst"`'
-archive_expsym_cmds_CXX='`$ECHO "$archive_expsym_cmds_CXX" | $SED "$delay_single_quote_subst"`'
-module_cmds_CXX='`$ECHO "$module_cmds_CXX" | $SED "$delay_single_quote_subst"`'
-module_expsym_cmds_CXX='`$ECHO "$module_expsym_cmds_CXX" | $SED "$delay_single_quote_subst"`'
-with_gnu_ld_CXX='`$ECHO "$with_gnu_ld_CXX" | $SED "$delay_single_quote_subst"`'
-allow_undefined_flag_CXX='`$ECHO "$allow_undefined_flag_CXX" | $SED "$delay_single_quote_subst"`'
-no_undefined_flag_CXX='`$ECHO "$no_undefined_flag_CXX" | $SED "$delay_single_quote_subst"`'
-hardcode_libdir_flag_spec_CXX='`$ECHO "$hardcode_libdir_flag_spec_CXX" | $SED "$delay_single_quote_subst"`'
-hardcode_libdir_flag_spec_ld_CXX='`$ECHO "$hardcode_libdir_flag_spec_ld_CXX" | $SED "$delay_single_quote_subst"`'
-hardcode_libdir_separator_CXX='`$ECHO "$hardcode_libdir_separator_CXX" | $SED "$delay_single_quote_subst"`'
-hardcode_direct_CXX='`$ECHO "$hardcode_direct_CXX" | $SED "$delay_single_quote_subst"`'
-hardcode_direct_absolute_CXX='`$ECHO "$hardcode_direct_absolute_CXX" | $SED "$delay_single_quote_subst"`'
-hardcode_minus_L_CXX='`$ECHO "$hardcode_minus_L_CXX" | $SED "$delay_single_quote_subst"`'
-hardcode_shlibpath_var_CXX='`$ECHO "$hardcode_shlibpath_var_CXX" | $SED "$delay_single_quote_subst"`'
-hardcode_automatic_CXX='`$ECHO "$hardcode_automatic_CXX" | $SED "$delay_single_quote_subst"`'
-inherit_rpath_CXX='`$ECHO "$inherit_rpath_CXX" | $SED "$delay_single_quote_subst"`'
-link_all_deplibs_CXX='`$ECHO "$link_all_deplibs_CXX" | $SED "$delay_single_quote_subst"`'
-fix_srcfile_path_CXX='`$ECHO "$fix_srcfile_path_CXX" | $SED "$delay_single_quote_subst"`'
-always_export_symbols_CXX='`$ECHO "$always_export_symbols_CXX" | $SED "$delay_single_quote_subst"`'
-export_symbols_cmds_CXX='`$ECHO "$export_symbols_cmds_CXX" | $SED "$delay_single_quote_subst"`'
-exclude_expsyms_CXX='`$ECHO "$exclude_expsyms_CXX" | $SED "$delay_single_quote_subst"`'
-include_expsyms_CXX='`$ECHO "$include_expsyms_CXX" | $SED "$delay_single_quote_subst"`'
-prelink_cmds_CXX='`$ECHO "$prelink_cmds_CXX" | $SED "$delay_single_quote_subst"`'
-file_list_spec_CXX='`$ECHO "$file_list_spec_CXX" | $SED "$delay_single_quote_subst"`'
-hardcode_action_CXX='`$ECHO "$hardcode_action_CXX" | $SED "$delay_single_quote_subst"`'
-compiler_lib_search_dirs_CXX='`$ECHO "$compiler_lib_search_dirs_CXX" | $SED "$delay_single_quote_subst"`'
-predep_objects_CXX='`$ECHO "$predep_objects_CXX" | $SED "$delay_single_quote_subst"`'
-postdep_objects_CXX='`$ECHO "$postdep_objects_CXX" | $SED "$delay_single_quote_subst"`'
-predeps_CXX='`$ECHO "$predeps_CXX" | $SED "$delay_single_quote_subst"`'
-postdeps_CXX='`$ECHO "$postdeps_CXX" | $SED "$delay_single_quote_subst"`'
-compiler_lib_search_path_CXX='`$ECHO "$compiler_lib_search_path_CXX" | $SED "$delay_single_quote_subst"`'
-
-LTCC='$LTCC'
-LTCFLAGS='$LTCFLAGS'
-compiler='$compiler_DEFAULT'
-
-# A function that is used when there is no print builtin or printf.
-func_fallback_echo ()
-{
- eval 'cat <<_LTECHO_EOF
-\$1
-_LTECHO_EOF'
-}
-
-# Quote evaled strings.
-for var in SHELL \
-ECHO \
-SED \
-GREP \
-EGREP \
-FGREP \
-LD \
-NM \
-LN_S \
-lt_SP2NL \
-lt_NL2SP \
-reload_flag \
-OBJDUMP \
-deplibs_check_method \
-file_magic_cmd \
-AR \
-AR_FLAGS \
-STRIP \
-RANLIB \
-CC \
-CFLAGS \
-compiler \
-lt_cv_sys_global_symbol_pipe \
-lt_cv_sys_global_symbol_to_cdecl \
-lt_cv_sys_global_symbol_to_c_name_address \
-lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \
-lt_prog_compiler_no_builtin_flag \
-lt_prog_compiler_wl \
-lt_prog_compiler_pic \
-lt_prog_compiler_static \
-lt_cv_prog_compiler_c_o \
-need_locks \
-DSYMUTIL \
-NMEDIT \
-LIPO \
-OTOOL \
-OTOOL64 \
-shrext_cmds \
-export_dynamic_flag_spec \
-whole_archive_flag_spec \
-compiler_needs_object \
-with_gnu_ld \
-allow_undefined_flag \
-no_undefined_flag \
-hardcode_libdir_flag_spec \
-hardcode_libdir_flag_spec_ld \
-hardcode_libdir_separator \
-fix_srcfile_path \
-exclude_expsyms \
-include_expsyms \
-file_list_spec \
-variables_saved_for_relink \
-libname_spec \
-library_names_spec \
-soname_spec \
-install_override_mode \
-finish_eval \
-old_striplib \
-striplib \
-compiler_lib_search_dirs \
-predep_objects \
-postdep_objects \
-predeps \
-postdeps \
-compiler_lib_search_path \
-LD_CXX \
-reload_flag_CXX \
-compiler_CXX \
-lt_prog_compiler_no_builtin_flag_CXX \
-lt_prog_compiler_wl_CXX \
-lt_prog_compiler_pic_CXX \
-lt_prog_compiler_static_CXX \
-lt_cv_prog_compiler_c_o_CXX \
-export_dynamic_flag_spec_CXX \
-whole_archive_flag_spec_CXX \
-compiler_needs_object_CXX \
-with_gnu_ld_CXX \
-allow_undefined_flag_CXX \
-no_undefined_flag_CXX \
-hardcode_libdir_flag_spec_CXX \
-hardcode_libdir_flag_spec_ld_CXX \
-hardcode_libdir_separator_CXX \
-fix_srcfile_path_CXX \
-exclude_expsyms_CXX \
-include_expsyms_CXX \
-file_list_spec_CXX \
-compiler_lib_search_dirs_CXX \
-predep_objects_CXX \
-postdep_objects_CXX \
-predeps_CXX \
-postdeps_CXX \
-compiler_lib_search_path_CXX; do
- case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
- *[\\\\\\\`\\"\\\$]*)
- eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\""
- ;;
- *)
- eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
- ;;
- esac
-done
-
-# Double-quote double-evaled strings.
-for var in reload_cmds \
-old_postinstall_cmds \
-old_postuninstall_cmds \
-old_archive_cmds \
-extract_expsyms_cmds \
-old_archive_from_new_cmds \
-old_archive_from_expsyms_cmds \
-archive_cmds \
-archive_expsym_cmds \
-module_cmds \
-module_expsym_cmds \
-export_symbols_cmds \
-prelink_cmds \
-postinstall_cmds \
-postuninstall_cmds \
-finish_cmds \
-sys_lib_search_path_spec \
-sys_lib_dlsearch_path_spec \
-reload_cmds_CXX \
-old_archive_cmds_CXX \
-old_archive_from_new_cmds_CXX \
-old_archive_from_expsyms_cmds_CXX \
-archive_cmds_CXX \
-archive_expsym_cmds_CXX \
-module_cmds_CXX \
-module_expsym_cmds_CXX \
-export_symbols_cmds_CXX \
-prelink_cmds_CXX; do
- case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
- *[\\\\\\\`\\"\\\$]*)
- eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\""
- ;;
- *)
- eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
- ;;
- esac
-done
-
-ac_aux_dir='$ac_aux_dir'
-xsi_shell='$xsi_shell'
-lt_shell_append='$lt_shell_append'
-
-# See if we are running on zsh, and set the options which allow our
-# commands through without removal of \ escapes INIT.
-if test -n "\${ZSH_VERSION+set}" ; then
- setopt NO_GLOB_SUBST
-fi
-
-
- PACKAGE='$PACKAGE'
- VERSION='$VERSION'
- TIMESTAMP='$TIMESTAMP'
- RM='$RM'
- ofile='$ofile'
-
-
-
-
-
-# Capture the value of obsolete ALL_LINGUAS because we need it to compute
- # POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES, CATALOGS. But hide it
- # from automake.
- eval 'OBSOLETE_ALL_LINGUAS''="$ALL_LINGUAS"'
- # Capture the value of LINGUAS because we need it to compute CATALOGS.
- LINGUAS="${LINGUAS-%UNSET%}"
-
-# Capture the value of obsolete ALL_LINGUAS because we need it to compute
- # POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES, CATALOGS. But hide it
- # from automake.
- eval 'OBSOLETE_ALL_LINGUAS''="$ALL_LINGUAS"'
- # Capture the value of LINGUAS because we need it to compute CATALOGS.
- LINGUAS="${LINGUAS-%UNSET%}"
-
-
-
-_ACEOF
-
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-
-# Handling of arguments.
-for ac_config_target in $ac_config_targets
-do
- case $ac_config_target in
- "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
- "libtool") CONFIG_COMMANDS="$CONFIG_COMMANDS libtool" ;;
- "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h:config.in" ;;
- "default-1") CONFIG_COMMANDS="$CONFIG_COMMANDS default-1" ;;
- "default-2") CONFIG_COMMANDS="$CONFIG_COMMANDS default-2" ;;
- "default") CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
- "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
- "po/Makefile.in") CONFIG_FILES="$CONFIG_FILES po/Makefile.in:po/Make-in" ;;
-
- *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
- esac
-done
-
-
-# If the user did not use the arguments to specify the items to instantiate,
-# then the envvar interface is used. Set only those that are not.
-# We use the long form for the default assignment because of an extremely
-# bizarre bug on SunOS 4.1.3.
-if $ac_need_defaults; then
- test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
- test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
- test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
-fi
-
-# Have a temporary directory for convenience. Make it in the build tree
-# simply because there is no reason against having it here, and in addition,
-# creating and moving files from /tmp can sometimes cause problems.
-# Hook for its removal unless debugging.
-# Note that there is a small window in which the directory will not be cleaned:
-# after its creation but before its name has been assigned to `$tmp'.
-$debug ||
-{
- tmp= ac_tmp=
- trap 'exit_status=$?
- : "${ac_tmp:=$tmp}"
- { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
-' 0
- trap 'as_fn_exit 1' 1 2 13 15
-}
-# Create a (secure) tmp directory for tmp files.
-
-{
- tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
- test -d "$tmp"
-} ||
-{
- tmp=./conf$$-$RANDOM
- (umask 077 && mkdir "$tmp")
-} || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
-ac_tmp=$tmp
-
-# Set up the scripts for CONFIG_FILES section.
-# No need to generate them if there are no CONFIG_FILES.
-# This happens for instance with `./config.status config.h'.
-if test -n "$CONFIG_FILES"; then
-
-
-ac_cr=`echo X | tr X '\015'`
-# On cygwin, bash can eat \r inside `` if the user requested igncr.
-# But we know of no other shell where ac_cr would be empty at this
-# point, so we can use a bashism as a fallback.
-if test "x$ac_cr" = x; then
- eval ac_cr=\$\'\\r\'
-fi
-ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
-if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
- ac_cs_awk_cr='\\r'
-else
- ac_cs_awk_cr=$ac_cr
-fi
-
-echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
-_ACEOF
-
-
-{
- echo "cat >conf$$subs.awk <<_ACEOF" &&
- echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
- echo "_ACEOF"
-} >conf$$subs.sh ||
- as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
-ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
-ac_delim='%!_!# '
-for ac_last_try in false false false false false :; do
- . ./conf$$subs.sh ||
- as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
-
- ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
- if test $ac_delim_n = $ac_delim_num; then
- break
- elif $ac_last_try; then
- as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
- else
- ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
- fi
-done
-rm -f conf$$subs.sh
-
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
-_ACEOF
-sed -n '
-h
-s/^/S["/; s/!.*/"]=/
-p
-g
-s/^[^!]*!//
-:repl
-t repl
-s/'"$ac_delim"'$//
-t delim
-:nl
-h
-s/\(.\{148\}\)..*/\1/
-t more1
-s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
-p
-n
-b repl
-:more1
-s/["\\]/\\&/g; s/^/"/; s/$/"\\/
-p
-g
-s/.\{148\}//
-t nl
-:delim
-h
-s/\(.\{148\}\)..*/\1/
-t more2
-s/["\\]/\\&/g; s/^/"/; s/$/"/
-p
-b
-:more2
-s/["\\]/\\&/g; s/^/"/; s/$/"\\/
-p
-g
-s/.\{148\}//
-t delim
-' <conf$$subs.awk | sed '
-/^[^""]/{
- N
- s/\n//
-}
-' >>$CONFIG_STATUS || ac_write_fail=1
-rm -f conf$$subs.awk
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-_ACAWK
-cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
- for (key in S) S_is_set[key] = 1
- FS = ""
-
-}
-{
- line = $ 0
- nfields = split(line, field, "@")
- substed = 0
- len = length(field[1])
- for (i = 2; i < nfields; i++) {
- key = field[i]
- keylen = length(key)
- if (S_is_set[key]) {
- value = S[key]
- line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
- len += length(value) + length(field[++i])
- substed = 1
- } else
- len += 1 + keylen
- }
-
- print line
-}
-
-_ACAWK
-_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
- sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
-else
- cat
-fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
- || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
-_ACEOF
-
-# VPATH may cause trouble with some makes, so we remove sole $(srcdir),
-# ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
-# trailing colons and then remove the whole line if VPATH becomes empty
-# (actually we leave an empty line to preserve line numbers).
-if test "x$srcdir" = x.; then
- ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{
-h
-s///
-s/^/:/
-s/[ ]*$/:/
-s/:\$(srcdir):/:/g
-s/:\${srcdir}:/:/g
-s/:@srcdir@:/:/g
-s/^:*//
-s/:*$//
-x
-s/\(=[ ]*\).*/\1/
-G
-s/\n//
-s/^[^=]*=[ ]*$//
-}'
-fi
-
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-fi # test -n "$CONFIG_FILES"
-
-# Set up the scripts for CONFIG_HEADERS section.
-# No need to generate them if there are no CONFIG_HEADERS.
-# This happens for instance with `./config.status Makefile'.
-if test -n "$CONFIG_HEADERS"; then
-cat >"$ac_tmp/defines.awk" <<\_ACAWK ||
-BEGIN {
-_ACEOF
-
-# Transform confdefs.h into an awk script `defines.awk', embedded as
-# here-document in config.status, that substitutes the proper values into
-# config.h.in to produce config.h.
-
-# Create a delimiter string that does not exist in confdefs.h, to ease
-# handling of long lines.
-ac_delim='%!_!# '
-for ac_last_try in false false :; do
- ac_tt=`sed -n "/$ac_delim/p" confdefs.h`
- if test -z "$ac_tt"; then
- break
- elif $ac_last_try; then
- as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
- else
- ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
- fi
-done
-
-# For the awk script, D is an array of macro values keyed by name,
-# likewise P contains macro parameters if any. Preserve backslash
-# newline sequences.
-
-ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
-sed -n '
-s/.\{148\}/&'"$ac_delim"'/g
-t rset
-:rset
-s/^[ ]*#[ ]*define[ ][ ]*/ /
-t def
-d
-:def
-s/\\$//
-t bsnl
-s/["\\]/\\&/g
-s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
-D["\1"]=" \3"/p
-s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
-d
-:bsnl
-s/["\\]/\\&/g
-s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
-D["\1"]=" \3\\\\\\n"\\/p
-t cont
-s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
-t cont
-d
-:cont
-n
-s/.\{148\}/&'"$ac_delim"'/g
-t clear
-:clear
-s/\\$//
-t bsnlc
-s/["\\]/\\&/g; s/^/"/; s/$/"/p
-d
-:bsnlc
-s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
-b cont
-' <confdefs.h | sed '
-s/'"$ac_delim"'/"\\\
-"/g' >>$CONFIG_STATUS || ac_write_fail=1
-
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
- for (key in D) D_is_set[key] = 1
- FS = ""
-}
-/^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
- line = \$ 0
- split(line, arg, " ")
- if (arg[1] == "#") {
- defundef = arg[2]
- mac1 = arg[3]
- } else {
- defundef = substr(arg[1], 2)
- mac1 = arg[2]
- }
- split(mac1, mac2, "(") #)
- macro = mac2[1]
- prefix = substr(line, 1, index(line, defundef) - 1)
- if (D_is_set[macro]) {
- # Preserve the white space surrounding the "#".
- print prefix "define", macro P[macro] D[macro]
- next
- } else {
- # Replace #undef with comments. This is necessary, for example,
- # in the case of _POSIX_SOURCE, which is predefined and required
- # on some systems where configure will not decide to define it.
- if (defundef == "undef") {
- print "/*", prefix defundef, macro, "*/"
- next
- }
- }
-}
-{ print }
-_ACAWK
-_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
- as_fn_error $? "could not setup config headers machinery" "$LINENO" 5
-fi # test -n "$CONFIG_HEADERS"
-
-
-eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS"
-shift
-for ac_tag
-do
- case $ac_tag in
- :[FHLC]) ac_mode=$ac_tag; continue;;
- esac
- case $ac_mode$ac_tag in
- :[FHL]*:*);;
- :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
- :[FH]-) ac_tag=-:-;;
- :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
- esac
- ac_save_IFS=$IFS
- IFS=:
- set x $ac_tag
- IFS=$ac_save_IFS
- shift
- ac_file=$1
- shift
-
- case $ac_mode in
- :L) ac_source=$1;;
- :[FH])
- ac_file_inputs=
- for ac_f
- do
- case $ac_f in
- -) ac_f="$ac_tmp/stdin";;
- *) # Look for the file first in the build tree, then in the source tree
- # (if the path is not absolute). The absolute path cannot be DOS-style,
- # because $ac_f cannot contain `:'.
- test -f "$ac_f" ||
- case $ac_f in
- [\\/$]*) false;;
- *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
- esac ||
- as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
- esac
- case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
- as_fn_append ac_file_inputs " '$ac_f'"
- done
-
- # Let's still pretend it is `configure' which instantiates (i.e., don't
- # use $as_me), people would be surprised to read:
- # /* config.h. Generated by config.status. */
- configure_input='Generated from '`
- $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
- `' by configure.'
- if test x"$ac_file" != x-; then
- configure_input="$ac_file. $configure_input"
- { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
-$as_echo "$as_me: creating $ac_file" >&6;}
- fi
- # Neutralize special characters interpreted by sed in replacement strings.
- case $configure_input in #(
- *\&* | *\|* | *\\* )
- ac_sed_conf_input=`$as_echo "$configure_input" |
- sed 's/[\\\\&|]/\\\\&/g'`;; #(
- *) ac_sed_conf_input=$configure_input;;
- esac
-
- case $ac_tag in
- *:-:* | *:-) cat >"$ac_tmp/stdin" \
- || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
- esac
- ;;
- esac
-
- ac_dir=`$as_dirname -- "$ac_file" ||
-$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$ac_file" : 'X\(//\)[^/]' \| \
- X"$ac_file" : 'X\(//\)$' \| \
- X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$ac_file" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
- as_dir="$ac_dir"; as_fn_mkdir_p
- ac_builddir=.
-
-case "$ac_dir" in
-.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
-*)
- ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
- # A ".." for each directory in $ac_dir_suffix.
- ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
- case $ac_top_builddir_sub in
- "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
- *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
- esac ;;
-esac
-ac_abs_top_builddir=$ac_pwd
-ac_abs_builddir=$ac_pwd$ac_dir_suffix
-# for backward compatibility:
-ac_top_builddir=$ac_top_build_prefix
-
-case $srcdir in
- .) # We are building in place.
- ac_srcdir=.
- ac_top_srcdir=$ac_top_builddir_sub
- ac_abs_top_srcdir=$ac_pwd ;;
- [\\/]* | ?:[\\/]* ) # Absolute name.
- ac_srcdir=$srcdir$ac_dir_suffix;
- ac_top_srcdir=$srcdir
- ac_abs_top_srcdir=$srcdir ;;
- *) # Relative name.
- ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
- ac_top_srcdir=$ac_top_build_prefix$srcdir
- ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
-esac
-ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
-
-
- case $ac_mode in
- :F)
- #
- # CONFIG_FILE
- #
-
- case $INSTALL in
- [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
- *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
- esac
- ac_MKDIR_P=$MKDIR_P
- case $MKDIR_P in
- [\\/$]* | ?:[\\/]* ) ;;
- */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
- esac
-_ACEOF
-
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-# If the template does not know about datarootdir, expand it.
-# FIXME: This hack should be removed a few years after 2.60.
-ac_datarootdir_hack=; ac_datarootdir_seen=
-ac_sed_dataroot='
-/datarootdir/ {
- p
- q
-}
-/@datadir@/p
-/@docdir@/p
-/@infodir@/p
-/@localedir@/p
-/@mandir@/p'
-case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
-*datarootdir*) ac_datarootdir_seen=yes;;
-*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
-$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
-_ACEOF
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
- ac_datarootdir_hack='
- s&@datadir@&$datadir&g
- s&@docdir@&$docdir&g
- s&@infodir@&$infodir&g
- s&@localedir@&$localedir&g
- s&@mandir@&$mandir&g
- s&\\\${datarootdir}&$datarootdir&g' ;;
-esac
-_ACEOF
-
-# Neutralize VPATH when `$srcdir' = `.'.
-# Shell code in configure.ac might set extrasub.
-# FIXME: do we really want to maintain this feature?
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-ac_sed_extra="$ac_vpsub
-$extrasub
-_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-:t
-/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
-s|@configure_input@|$ac_sed_conf_input|;t t
-s&@top_builddir@&$ac_top_builddir_sub&;t t
-s&@top_build_prefix@&$ac_top_build_prefix&;t t
-s&@srcdir@&$ac_srcdir&;t t
-s&@abs_srcdir@&$ac_abs_srcdir&;t t
-s&@top_srcdir@&$ac_top_srcdir&;t t
-s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
-s&@builddir@&$ac_builddir&;t t
-s&@abs_builddir@&$ac_abs_builddir&;t t
-s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
-s&@INSTALL@&$ac_INSTALL&;t t
-s&@MKDIR_P@&$ac_MKDIR_P&;t t
-$ac_datarootdir_hack
-"
-eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \
- >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
-
-test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
- { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
- { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \
- "$ac_tmp/out"`; test -z "$ac_out"; } &&
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
-which seems to be undefined. Please make sure it is defined" >&5
-$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
-which seems to be undefined. Please make sure it is defined" >&2;}
-
- rm -f "$ac_tmp/stdin"
- case $ac_file in
- -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
- *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
- esac \
- || as_fn_error $? "could not create $ac_file" "$LINENO" 5
- ;;
- :H)
- #
- # CONFIG_HEADER
- #
- if test x"$ac_file" != x-; then
- {
- $as_echo "/* $configure_input */" \
- && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs"
- } >"$ac_tmp/config.h" \
- || as_fn_error $? "could not create $ac_file" "$LINENO" 5
- if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
-$as_echo "$as_me: $ac_file is unchanged" >&6;}
- else
- rm -f "$ac_file"
- mv "$ac_tmp/config.h" "$ac_file" \
- || as_fn_error $? "could not create $ac_file" "$LINENO" 5
- fi
- else
- $as_echo "/* $configure_input */" \
- && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \
- || as_fn_error $? "could not create -" "$LINENO" 5
- fi
-# Compute "$ac_file"'s index in $config_headers.
-_am_arg="$ac_file"
-_am_stamp_count=1
-for _am_header in $config_headers :; do
- case $_am_header in
- $_am_arg | $_am_arg:* )
- break ;;
- * )
- _am_stamp_count=`expr $_am_stamp_count + 1` ;;
- esac
-done
-echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" ||
-$as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$_am_arg" : 'X\(//\)[^/]' \| \
- X"$_am_arg" : 'X\(//\)$' \| \
- X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$_am_arg" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`/stamp-h$_am_stamp_count
- ;;
-
- :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
-$as_echo "$as_me: executing $ac_file commands" >&6;}
- ;;
- esac
-
-
- case $ac_file$ac_mode in
- "depfiles":C) test x"$AMDEP_TRUE" != x"" || {
- # Older Autoconf quotes --file arguments for eval, but not when files
- # are listed without --file. Let's play safe and only enable the eval
- # if we detect the quoting.
- case $CONFIG_FILES in
- *\'*) eval set x "$CONFIG_FILES" ;;
- *) set x $CONFIG_FILES ;;
- esac
- shift
- for mf
- do
- # Strip MF so we end up with the name of the file.
- mf=`echo "$mf" | sed -e 's/:.*$//'`
- # Check whether this is an Automake generated Makefile or not.
- # We used to match only the files named 'Makefile.in', but
- # some people rename them; so instead we look at the file content.
- # Grep'ing the first line is not enough: some people post-process
- # each Makefile.in and add a new line on top of each file to say so.
- # Grep'ing the whole file is not good either: AIX grep has a line
- # limit of 2048, but all sed's we know have understand at least 4000.
- if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
- dirpart=`$as_dirname -- "$mf" ||
-$as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$mf" : 'X\(//\)[^/]' \| \
- X"$mf" : 'X\(//\)$' \| \
- X"$mf" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$mf" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
- else
- continue
- fi
- # Extract the definition of DEPDIR, am__include, and am__quote
- # from the Makefile without running 'make'.
- DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
- test -z "$DEPDIR" && continue
- am__include=`sed -n 's/^am__include = //p' < "$mf"`
- test -z "$am__include" && continue
- am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
- # Find all dependency output files, they are included files with
- # $(DEPDIR) in their names. We invoke sed twice because it is the
- # simplest approach to changing $(DEPDIR) to its actual value in the
- # expansion.
- for file in `sed -n "
- s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
- sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g'`; do
- # Make sure the directory exists.
- test -f "$dirpart/$file" && continue
- fdir=`$as_dirname -- "$file" ||
-$as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$file" : 'X\(//\)[^/]' \| \
- X"$file" : 'X\(//\)$' \| \
- X"$file" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$file" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
- as_dir=$dirpart/$fdir; as_fn_mkdir_p
- # echo "creating $dirpart/$file"
- echo '# dummy' > "$dirpart/$file"
- done
- done
-}
- ;;
- "libtool":C)
-
- # See if we are running on zsh, and set the options which allow our
- # commands through without removal of \ escapes.
- if test -n "${ZSH_VERSION+set}" ; then
- setopt NO_GLOB_SUBST
- fi
-
- cfgfile="${ofile}T"
- trap "$RM \"$cfgfile\"; exit 1" 1 2 15
- $RM "$cfgfile"
-
- cat <<_LT_EOF >> "$cfgfile"
-#! $SHELL
-
-# `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
-# Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION
-# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
-# NOTE: Changes made to this file will be lost: look at ltmain.sh.
-#
-# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
-# 2006, 2007, 2008, 2009 Free Software Foundation, Inc.
-# Written by Gordon Matzigkeit, 1996
-#
-# This file is part of GNU Libtool.
-#
-# GNU Libtool is free software; you can redistribute it and/or
-# modify it under the terms of the GNU General Public License as
-# published by the Free Software Foundation; either version 2 of
-# the License, or (at your option) any later version.
-#
-# As a special exception to the GNU General Public License,
-# if you distribute this file as part of a program or library that
-# is built using GNU Libtool, you may include this file under the
-# same distribution terms that you use for the rest of that program.
-#
-# GNU Libtool is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with GNU Libtool; see the file COPYING. If not, a copy
-# can be downloaded from http://www.gnu.org/licenses/gpl.html, or
-# obtained by writing to the Free Software Foundation, Inc.,
-# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
-
-
-# The names of the tagged configurations supported by this script.
-available_tags="CXX "
-
-# ### BEGIN LIBTOOL CONFIG
-
-# Which release of libtool.m4 was used?
-macro_version=$macro_version
-macro_revision=$macro_revision
-
-# Whether or not to build shared libraries.
-build_libtool_libs=$enable_shared
-
-# Whether or not to build static libraries.
-build_old_libs=$enable_static
-
-# What type of objects to build.
-pic_mode=$pic_mode
-
-# Whether or not to optimize for fast installation.
-fast_install=$enable_fast_install
-
-# Shell to use when invoking shell scripts.
-SHELL=$lt_SHELL
-
-# An echo program that protects backslashes.
-ECHO=$lt_ECHO
-
-# The host system.
-host_alias=$host_alias
-host=$host
-host_os=$host_os
-
-# The build system.
-build_alias=$build_alias
-build=$build
-build_os=$build_os
-
-# A sed program that does not truncate output.
-SED=$lt_SED
-
-# Sed that helps us avoid accidentally triggering echo(1) options like -n.
-Xsed="\$SED -e 1s/^X//"
-
-# A grep program that handles long lines.
-GREP=$lt_GREP
-
-# An ERE matcher.
-EGREP=$lt_EGREP
-
-# A literal string matcher.
-FGREP=$lt_FGREP
-
-# A BSD- or MS-compatible name lister.
-NM=$lt_NM
-
-# Whether we need soft or hard links.
-LN_S=$lt_LN_S
-
-# What is the maximum length of a command?
-max_cmd_len=$max_cmd_len
-
-# Object file suffix (normally "o").
-objext=$ac_objext
-
-# Executable file suffix (normally "").
-exeext=$exeext
-
-# whether the shell understands "unset".
-lt_unset=$lt_unset
-
-# turn spaces into newlines.
-SP2NL=$lt_lt_SP2NL
-
-# turn newlines into spaces.
-NL2SP=$lt_lt_NL2SP
-
-# An object symbol dumper.
-OBJDUMP=$lt_OBJDUMP
-
-# Method to check whether dependent libraries are shared objects.
-deplibs_check_method=$lt_deplibs_check_method
-
-# Command to use when deplibs_check_method == "file_magic".
-file_magic_cmd=$lt_file_magic_cmd
-
-# The archiver.
-AR=$lt_AR
-AR_FLAGS=$lt_AR_FLAGS
-
-# A symbol stripping program.
-STRIP=$lt_STRIP
-
-# Commands used to install an old-style archive.
-RANLIB=$lt_RANLIB
-old_postinstall_cmds=$lt_old_postinstall_cmds
-old_postuninstall_cmds=$lt_old_postuninstall_cmds
-
-# Whether to use a lock for old archive extraction.
-lock_old_archive_extraction=$lock_old_archive_extraction
-
-# A C compiler.
-LTCC=$lt_CC
-
-# LTCC compiler flags.
-LTCFLAGS=$lt_CFLAGS
-
-# Take the output of nm and produce a listing of raw symbols and C names.
-global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe
-
-# Transform the output of nm in a proper C declaration.
-global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl
-
-# Transform the output of nm in a C name address pair.
-global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
-
-# Transform the output of nm in a C name address pair when lib prefix is needed.
-global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix
-
-# The name of the directory that contains temporary libtool files.
-objdir=$objdir
-
-# Used to examine libraries when file_magic_cmd begins with "file".
-MAGIC_CMD=$MAGIC_CMD
-
-# Must we lock files when doing compilation?
-need_locks=$lt_need_locks
-
-# Tool to manipulate archived DWARF debug symbol files on Mac OS X.
-DSYMUTIL=$lt_DSYMUTIL
-
-# Tool to change global to local symbols on Mac OS X.
-NMEDIT=$lt_NMEDIT
-
-# Tool to manipulate fat objects and archives on Mac OS X.
-LIPO=$lt_LIPO
-
-# ldd/readelf like tool for Mach-O binaries on Mac OS X.
-OTOOL=$lt_OTOOL
-
-# ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4.
-OTOOL64=$lt_OTOOL64
-
-# Old archive suffix (normally "a").
-libext=$libext
-
-# Shared library suffix (normally ".so").
-shrext_cmds=$lt_shrext_cmds
-
-# The commands to extract the exported symbol list from a shared archive.
-extract_expsyms_cmds=$lt_extract_expsyms_cmds
-
-# Variables whose values should be saved in libtool wrapper scripts and
-# restored at link time.
-variables_saved_for_relink=$lt_variables_saved_for_relink
-
-# Do we need the "lib" prefix for modules?
-need_lib_prefix=$need_lib_prefix
-
-# Do we need a version for libraries?
-need_version=$need_version
-
-# Library versioning type.
-version_type=$version_type
-
-# Shared library runtime path variable.
-runpath_var=$runpath_var
-
-# Shared library path variable.
-shlibpath_var=$shlibpath_var
-
-# Is shlibpath searched before the hard-coded library search path?
-shlibpath_overrides_runpath=$shlibpath_overrides_runpath
-
-# Format of library name prefix.
-libname_spec=$lt_libname_spec
-
-# List of archive names. First name is the real one, the rest are links.
-# The last name is the one that the linker finds with -lNAME
-library_names_spec=$lt_library_names_spec
-
-# The coded name of the library, if different from the real name.
-soname_spec=$lt_soname_spec
-
-# Permission mode override for installation of shared libraries.
-install_override_mode=$lt_install_override_mode
-
-# Command to use after installation of a shared archive.
-postinstall_cmds=$lt_postinstall_cmds
-
-# Command to use after uninstallation of a shared archive.
-postuninstall_cmds=$lt_postuninstall_cmds
-
-# Commands used to finish a libtool library installation in a directory.
-finish_cmds=$lt_finish_cmds
-
-# As "finish_cmds", except a single script fragment to be evaled but
-# not shown.
-finish_eval=$lt_finish_eval
-
-# Whether we should hardcode library paths into libraries.
-hardcode_into_libs=$hardcode_into_libs
-
-# Compile-time system search path for libraries.
-sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
-
-# Run-time system search path for libraries.
-sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
-
-# Whether dlopen is supported.
-dlopen_support=$enable_dlopen
-
-# Whether dlopen of programs is supported.
-dlopen_self=$enable_dlopen_self
-
-# Whether dlopen of statically linked programs is supported.
-dlopen_self_static=$enable_dlopen_self_static
-
-# Commands to strip libraries.
-old_striplib=$lt_old_striplib
-striplib=$lt_striplib
-
-
-# The linker used to build libraries.
-LD=$lt_LD
-
-# How to create reloadable object files.
-reload_flag=$lt_reload_flag
-reload_cmds=$lt_reload_cmds
-
-# Commands used to build an old-style archive.
-old_archive_cmds=$lt_old_archive_cmds
-
-# A language specific compiler.
-CC=$lt_compiler
-
-# Is the compiler the GNU compiler?
-with_gcc=$GCC
-
-# Compiler flag to turn off builtin functions.
-no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag
-
-# How to pass a linker flag through the compiler.
-wl=$lt_lt_prog_compiler_wl
-
-# Additional compiler flags for building library objects.
-pic_flag=$lt_lt_prog_compiler_pic
-
-# Compiler flag to prevent dynamic linking.
-link_static_flag=$lt_lt_prog_compiler_static
-
-# Does compiler simultaneously support -c and -o options?
-compiler_c_o=$lt_lt_cv_prog_compiler_c_o
-
-# Whether or not to add -lc for building shared libraries.
-build_libtool_need_lc=$archive_cmds_need_lc
-
-# Whether or not to disallow shared libs when runtime libs are static.
-allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes
-
-# Compiler flag to allow reflexive dlopens.
-export_dynamic_flag_spec=$lt_export_dynamic_flag_spec
-
-# Compiler flag to generate shared objects directly from archives.
-whole_archive_flag_spec=$lt_whole_archive_flag_spec
-
-# Whether the compiler copes with passing no objects directly.
-compiler_needs_object=$lt_compiler_needs_object
-
-# Create an old-style archive from a shared archive.
-old_archive_from_new_cmds=$lt_old_archive_from_new_cmds
-
-# Create a temporary old-style archive to link instead of a shared archive.
-old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds
-
-# Commands used to build a shared archive.
-archive_cmds=$lt_archive_cmds
-archive_expsym_cmds=$lt_archive_expsym_cmds
-
-# Commands used to build a loadable module if different from building
-# a shared archive.
-module_cmds=$lt_module_cmds
-module_expsym_cmds=$lt_module_expsym_cmds
-
-# Whether we are building with GNU ld or not.
-with_gnu_ld=$lt_with_gnu_ld
-
-# Flag that allows shared libraries with undefined symbols to be built.
-allow_undefined_flag=$lt_allow_undefined_flag
-
-# Flag that enforces no undefined symbols.
-no_undefined_flag=$lt_no_undefined_flag
-
-# Flag to hardcode \$libdir into a binary during linking.
-# This must work even if \$libdir does not exist
-hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec
-
-# If ld is used when linking, flag to hardcode \$libdir into a binary
-# during linking. This must work even if \$libdir does not exist.
-hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld
-
-# Whether we need a single "-rpath" flag with a separated argument.
-hardcode_libdir_separator=$lt_hardcode_libdir_separator
-
-# Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
-# DIR into the resulting binary.
-hardcode_direct=$hardcode_direct
-
-# Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
-# DIR into the resulting binary and the resulting library dependency is
-# "absolute",i.e impossible to change by setting \${shlibpath_var} if the
-# library is relocated.
-hardcode_direct_absolute=$hardcode_direct_absolute
-
-# Set to "yes" if using the -LDIR flag during linking hardcodes DIR
-# into the resulting binary.
-hardcode_minus_L=$hardcode_minus_L
-
-# Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR
-# into the resulting binary.
-hardcode_shlibpath_var=$hardcode_shlibpath_var
-
-# Set to "yes" if building a shared library automatically hardcodes DIR
-# into the library and all subsequent libraries and executables linked
-# against it.
-hardcode_automatic=$hardcode_automatic
-
-# Set to yes if linker adds runtime paths of dependent libraries
-# to runtime path list.
-inherit_rpath=$inherit_rpath
-
-# Whether libtool must link a program against all its dependency libraries.
-link_all_deplibs=$link_all_deplibs
-
-# Fix the shell variable \$srcfile for the compiler.
-fix_srcfile_path=$lt_fix_srcfile_path
-
-# Set to "yes" if exported symbols are required.
-always_export_symbols=$always_export_symbols
-
-# The commands to list exported symbols.
-export_symbols_cmds=$lt_export_symbols_cmds
-
-# Symbols that should not be listed in the preloaded symbols.
-exclude_expsyms=$lt_exclude_expsyms
-
-# Symbols that must always be exported.
-include_expsyms=$lt_include_expsyms
-
-# Commands necessary for linking programs (against libraries) with templates.
-prelink_cmds=$lt_prelink_cmds
-
-# Specify filename containing input files.
-file_list_spec=$lt_file_list_spec
-
-# How to hardcode a shared library path into an executable.
-hardcode_action=$hardcode_action
-
-# The directories searched by this compiler when creating a shared library.
-compiler_lib_search_dirs=$lt_compiler_lib_search_dirs
-
-# Dependencies to place before and after the objects being linked to
-# create a shared library.
-predep_objects=$lt_predep_objects
-postdep_objects=$lt_postdep_objects
-predeps=$lt_predeps
-postdeps=$lt_postdeps
-
-# The library search path used internally by the compiler when linking
-# a shared library.
-compiler_lib_search_path=$lt_compiler_lib_search_path
-
-# ### END LIBTOOL CONFIG
-
-_LT_EOF
-
- case $host_os in
- aix3*)
- cat <<\_LT_EOF >> "$cfgfile"
-# AIX sometimes has problems with the GCC collect2 program. For some
-# reason, if we set the COLLECT_NAMES environment variable, the problems
-# vanish in a puff of smoke.
-if test "X${COLLECT_NAMES+set}" != Xset; then
- COLLECT_NAMES=
- export COLLECT_NAMES
-fi
-_LT_EOF
- ;;
- esac
-
-
-ltmain="$ac_aux_dir/ltmain.sh"
-
-
- # We use sed instead of cat because bash on DJGPP gets confused if
- # if finds mixed CR/LF and LF-only lines. Since sed operates in
- # text mode, it properly converts lines to CR/LF. This bash problem
- # is reportedly fixed, but why not run on old versions too?
- sed '/^# Generated shell functions inserted here/q' "$ltmain" >> "$cfgfile" \
- || (rm -f "$cfgfile"; exit 1)
-
- case $xsi_shell in
- yes)
- cat << \_LT_EOF >> "$cfgfile"
-
-# func_dirname file append nondir_replacement
-# Compute the dirname of FILE. If nonempty, add APPEND to the result,
-# otherwise set result to NONDIR_REPLACEMENT.
-func_dirname ()
-{
- case ${1} in
- */*) func_dirname_result="${1%/*}${2}" ;;
- * ) func_dirname_result="${3}" ;;
- esac
-}
-
-# func_basename file
-func_basename ()
-{
- func_basename_result="${1##*/}"
-}
-
-# func_dirname_and_basename file append nondir_replacement
-# perform func_basename and func_dirname in a single function
-# call:
-# dirname: Compute the dirname of FILE. If nonempty,
-# add APPEND to the result, otherwise set result
-# to NONDIR_REPLACEMENT.
-# value returned in "$func_dirname_result"
-# basename: Compute filename of FILE.
-# value retuned in "$func_basename_result"
-# Implementation must be kept synchronized with func_dirname
-# and func_basename. For efficiency, we do not delegate to
-# those functions but instead duplicate the functionality here.
-func_dirname_and_basename ()
-{
- case ${1} in
- */*) func_dirname_result="${1%/*}${2}" ;;
- * ) func_dirname_result="${3}" ;;
- esac
- func_basename_result="${1##*/}"
-}
-
-# func_stripname prefix suffix name
-# strip PREFIX and SUFFIX off of NAME.
-# PREFIX and SUFFIX must not contain globbing or regex special
-# characters, hashes, percent signs, but SUFFIX may contain a leading
-# dot (in which case that matches only a dot).
-func_stripname ()
-{
- # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are
- # positional parameters, so assign one to ordinary parameter first.
- func_stripname_result=${3}
- func_stripname_result=${func_stripname_result#"${1}"}
- func_stripname_result=${func_stripname_result%"${2}"}
-}
-
-# func_opt_split
-func_opt_split ()
-{
- func_opt_split_opt=${1%%=*}
- func_opt_split_arg=${1#*=}
-}
-
-# func_lo2o object
-func_lo2o ()
-{
- case ${1} in
- *.lo) func_lo2o_result=${1%.lo}.${objext} ;;
- *) func_lo2o_result=${1} ;;
- esac
-}
-
-# func_xform libobj-or-source
-func_xform ()
-{
- func_xform_result=${1%.*}.lo
-}
-
-# func_arith arithmetic-term...
-func_arith ()
-{
- func_arith_result=$(( $* ))
-}
-
-# func_len string
-# STRING may not start with a hyphen.
-func_len ()
-{
- func_len_result=${#1}
-}
-
-_LT_EOF
- ;;
- *) # Bourne compatible functions.
- cat << \_LT_EOF >> "$cfgfile"
-
-# func_dirname file append nondir_replacement
-# Compute the dirname of FILE. If nonempty, add APPEND to the result,
-# otherwise set result to NONDIR_REPLACEMENT.
-func_dirname ()
-{
- # Extract subdirectory from the argument.
- func_dirname_result=`$ECHO "${1}" | $SED "$dirname"`
- if test "X$func_dirname_result" = "X${1}"; then
- func_dirname_result="${3}"
- else
- func_dirname_result="$func_dirname_result${2}"
- fi
-}
-
-# func_basename file
-func_basename ()
-{
- func_basename_result=`$ECHO "${1}" | $SED "$basename"`
-}
-
-
-# func_stripname prefix suffix name
-# strip PREFIX and SUFFIX off of NAME.
-# PREFIX and SUFFIX must not contain globbing or regex special
-# characters, hashes, percent signs, but SUFFIX may contain a leading
-# dot (in which case that matches only a dot).
-# func_strip_suffix prefix name
-func_stripname ()
-{
- case ${2} in
- .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;;
- *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;;
- esac
-}
-
-# sed scripts:
-my_sed_long_opt='1s/^\(-[^=]*\)=.*/\1/;q'
-my_sed_long_arg='1s/^-[^=]*=//'
-
-# func_opt_split
-func_opt_split ()
-{
- func_opt_split_opt=`$ECHO "${1}" | $SED "$my_sed_long_opt"`
- func_opt_split_arg=`$ECHO "${1}" | $SED "$my_sed_long_arg"`
-}
-
-# func_lo2o object
-func_lo2o ()
-{
- func_lo2o_result=`$ECHO "${1}" | $SED "$lo2o"`
-}
-
-# func_xform libobj-or-source
-func_xform ()
-{
- func_xform_result=`$ECHO "${1}" | $SED 's/\.[^.]*$/.lo/'`
-}
-
-# func_arith arithmetic-term...
-func_arith ()
-{
- func_arith_result=`expr "$@"`
-}
-
-# func_len string
-# STRING may not start with a hyphen.
-func_len ()
-{
- func_len_result=`expr "$1" : ".*" 2>/dev/null || echo $max_cmd_len`
-}
-
-_LT_EOF
-esac
-
-case $lt_shell_append in
- yes)
- cat << \_LT_EOF >> "$cfgfile"
-
-# func_append var value
-# Append VALUE to the end of shell variable VAR.
-func_append ()
-{
- eval "$1+=\$2"
-}
-_LT_EOF
- ;;
- *)
- cat << \_LT_EOF >> "$cfgfile"
-
-# func_append var value
-# Append VALUE to the end of shell variable VAR.
-func_append ()
-{
- eval "$1=\$$1\$2"
-}
-
-_LT_EOF
- ;;
- esac
-
-
- sed -n '/^# Generated shell functions inserted here/,$p' "$ltmain" >> "$cfgfile" \
- || (rm -f "$cfgfile"; exit 1)
-
- mv -f "$cfgfile" "$ofile" ||
- (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
- chmod +x "$ofile"
-
-
- cat <<_LT_EOF >> "$ofile"
-
-# ### BEGIN LIBTOOL TAG CONFIG: CXX
-
-# The linker used to build libraries.
-LD=$lt_LD_CXX
-
-# How to create reloadable object files.
-reload_flag=$lt_reload_flag_CXX
-reload_cmds=$lt_reload_cmds_CXX
-
-# Commands used to build an old-style archive.
-old_archive_cmds=$lt_old_archive_cmds_CXX
-
-# A language specific compiler.
-CC=$lt_compiler_CXX
-
-# Is the compiler the GNU compiler?
-with_gcc=$GCC_CXX
-
-# Compiler flag to turn off builtin functions.
-no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag_CXX
-
-# How to pass a linker flag through the compiler.
-wl=$lt_lt_prog_compiler_wl_CXX
-
-# Additional compiler flags for building library objects.
-pic_flag=$lt_lt_prog_compiler_pic_CXX
-
-# Compiler flag to prevent dynamic linking.
-link_static_flag=$lt_lt_prog_compiler_static_CXX
-
-# Does compiler simultaneously support -c and -o options?
-compiler_c_o=$lt_lt_cv_prog_compiler_c_o_CXX
-
-# Whether or not to add -lc for building shared libraries.
-build_libtool_need_lc=$archive_cmds_need_lc_CXX
-
-# Whether or not to disallow shared libs when runtime libs are static.
-allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes_CXX
-
-# Compiler flag to allow reflexive dlopens.
-export_dynamic_flag_spec=$lt_export_dynamic_flag_spec_CXX
-
-# Compiler flag to generate shared objects directly from archives.
-whole_archive_flag_spec=$lt_whole_archive_flag_spec_CXX
-
-# Whether the compiler copes with passing no objects directly.
-compiler_needs_object=$lt_compiler_needs_object_CXX
-
-# Create an old-style archive from a shared archive.
-old_archive_from_new_cmds=$lt_old_archive_from_new_cmds_CXX
-
-# Create a temporary old-style archive to link instead of a shared archive.
-old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds_CXX
-
-# Commands used to build a shared archive.
-archive_cmds=$lt_archive_cmds_CXX
-archive_expsym_cmds=$lt_archive_expsym_cmds_CXX
-
-# Commands used to build a loadable module if different from building
-# a shared archive.
-module_cmds=$lt_module_cmds_CXX
-module_expsym_cmds=$lt_module_expsym_cmds_CXX
-
-# Whether we are building with GNU ld or not.
-with_gnu_ld=$lt_with_gnu_ld_CXX
-
-# Flag that allows shared libraries with undefined symbols to be built.
-allow_undefined_flag=$lt_allow_undefined_flag_CXX
-
-# Flag that enforces no undefined symbols.
-no_undefined_flag=$lt_no_undefined_flag_CXX
-
-# Flag to hardcode \$libdir into a binary during linking.
-# This must work even if \$libdir does not exist
-hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec_CXX
-
-# If ld is used when linking, flag to hardcode \$libdir into a binary
-# during linking. This must work even if \$libdir does not exist.
-hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld_CXX
-
-# Whether we need a single "-rpath" flag with a separated argument.
-hardcode_libdir_separator=$lt_hardcode_libdir_separator_CXX
-
-# Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
-# DIR into the resulting binary.
-hardcode_direct=$hardcode_direct_CXX
-
-# Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
-# DIR into the resulting binary and the resulting library dependency is
-# "absolute",i.e impossible to change by setting \${shlibpath_var} if the
-# library is relocated.
-hardcode_direct_absolute=$hardcode_direct_absolute_CXX
-
-# Set to "yes" if using the -LDIR flag during linking hardcodes DIR
-# into the resulting binary.
-hardcode_minus_L=$hardcode_minus_L_CXX
-
-# Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR
-# into the resulting binary.
-hardcode_shlibpath_var=$hardcode_shlibpath_var_CXX
-
-# Set to "yes" if building a shared library automatically hardcodes DIR
-# into the library and all subsequent libraries and executables linked
-# against it.
-hardcode_automatic=$hardcode_automatic_CXX
-
-# Set to yes if linker adds runtime paths of dependent libraries
-# to runtime path list.
-inherit_rpath=$inherit_rpath_CXX
-
-# Whether libtool must link a program against all its dependency libraries.
-link_all_deplibs=$link_all_deplibs_CXX
-
-# Fix the shell variable \$srcfile for the compiler.
-fix_srcfile_path=$lt_fix_srcfile_path_CXX
-
-# Set to "yes" if exported symbols are required.
-always_export_symbols=$always_export_symbols_CXX
-
-# The commands to list exported symbols.
-export_symbols_cmds=$lt_export_symbols_cmds_CXX
-
-# Symbols that should not be listed in the preloaded symbols.
-exclude_expsyms=$lt_exclude_expsyms_CXX
-
-# Symbols that must always be exported.
-include_expsyms=$lt_include_expsyms_CXX
-
-# Commands necessary for linking programs (against libraries) with templates.
-prelink_cmds=$lt_prelink_cmds_CXX
-
-# Specify filename containing input files.
-file_list_spec=$lt_file_list_spec_CXX
-
-# How to hardcode a shared library path into an executable.
-hardcode_action=$hardcode_action_CXX
-
-# The directories searched by this compiler when creating a shared library.
-compiler_lib_search_dirs=$lt_compiler_lib_search_dirs_CXX
-
-# Dependencies to place before and after the objects being linked to
-# create a shared library.
-predep_objects=$lt_predep_objects_CXX
-postdep_objects=$lt_postdep_objects_CXX
-predeps=$lt_predeps_CXX
-postdeps=$lt_postdeps_CXX
-
-# The library search path used internally by the compiler when linking
-# a shared library.
-compiler_lib_search_path=$lt_compiler_lib_search_path_CXX
-
-# ### END LIBTOOL TAG CONFIG: CXX
-_LT_EOF
-
- ;;
- "default-1":C)
- for ac_file in $CONFIG_FILES; do
- # Support "outfile[:infile[:infile...]]"
- case "$ac_file" in
- *:*) ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
- esac
- # PO directories have a Makefile.in generated from Makefile.in.in.
- case "$ac_file" in */Makefile.in)
- # Adjust a relative srcdir.
- ac_dir=`echo "$ac_file"|sed 's%/[^/][^/]*$%%'`
- ac_dir_suffix=/`echo "$ac_dir"|sed 's%^\./%%'`
- ac_dots=`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'`
- # In autoconf-2.13 it is called $ac_given_srcdir.
- # In autoconf-2.50 it is called $srcdir.
- test -n "$ac_given_srcdir" || ac_given_srcdir="$srcdir"
- case "$ac_given_srcdir" in
- .) top_srcdir=`echo $ac_dots|sed 's%/$%%'` ;;
- /*) top_srcdir="$ac_given_srcdir" ;;
- *) top_srcdir="$ac_dots$ac_given_srcdir" ;;
- esac
- if test -f "$ac_given_srcdir/$ac_dir/POTFILES.in"; then
- rm -f "$ac_dir/POTFILES"
- test -n "$as_me" && echo "$as_me: creating $ac_dir/POTFILES" || echo "creating $ac_dir/POTFILES"
- cat "$ac_given_srcdir/$ac_dir/POTFILES.in" | sed -e "/^#/d" -e "/^[ ]*\$/d" -e "s,.*, $top_srcdir/& \\\\," | sed -e "\$s/\(.*\) \\\\/\1/" > "$ac_dir/POTFILES"
- POMAKEFILEDEPS="POTFILES.in"
- # ALL_LINGUAS, POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES depend
- # on $ac_dir but don't depend on user-specified configuration
- # parameters.
- if test -f "$ac_given_srcdir/$ac_dir/LINGUAS"; then
- # The LINGUAS file contains the set of available languages.
- if test -n "$OBSOLETE_ALL_LINGUAS"; then
- test -n "$as_me" && echo "$as_me: setting ALL_LINGUAS in configure.ac is obsolete" || echo "setting ALL_LINGUAS in configure.ac is obsolete"
- fi
- ALL_LINGUAS_=`sed -e "/^#/d" "$ac_given_srcdir/$ac_dir/LINGUAS"`
- # Hide the ALL_LINGUAS assigment from automake.
- eval 'ALL_LINGUAS''=$ALL_LINGUAS_'
- POMAKEFILEDEPS="$POMAKEFILEDEPS LINGUAS"
- else
- # The set of available languages was given in configure.ac.
- eval 'ALL_LINGUAS''=$OBSOLETE_ALL_LINGUAS'
- fi
- case "$ac_given_srcdir" in
- .) srcdirpre= ;;
- *) srcdirpre='$(srcdir)/' ;;
- esac
- POFILES=
- GMOFILES=
- UPDATEPOFILES=
- DUMMYPOFILES=
- for lang in $ALL_LINGUAS; do
- POFILES="$POFILES $srcdirpre$lang.po"
- GMOFILES="$GMOFILES $srcdirpre$lang.gmo"
- UPDATEPOFILES="$UPDATEPOFILES $lang.po-update"
- DUMMYPOFILES="$DUMMYPOFILES $lang.nop"
- done
- # CATALOGS depends on both $ac_dir and the user's LINGUAS
- # environment variable.
- INST_LINGUAS=
- if test -n "$ALL_LINGUAS"; then
- for presentlang in $ALL_LINGUAS; do
- useit=no
- if test "%UNSET%" != "$LINGUAS"; then
- desiredlanguages="$LINGUAS"
- else
- desiredlanguages="$ALL_LINGUAS"
- fi
- for desiredlang in $desiredlanguages; do
- # Use the presentlang catalog if desiredlang is
- # a. equal to presentlang, or
- # b. a variant of presentlang (because in this case,
- # presentlang can be used as a fallback for messages
- # which are not translated in the desiredlang catalog).
- case "$desiredlang" in
- "$presentlang"*) useit=yes;;
- esac
- done
- if test $useit = yes; then
- INST_LINGUAS="$INST_LINGUAS $presentlang"
- fi
- done
- fi
- CATALOGS=
- if test -n "$INST_LINGUAS"; then
- for lang in $INST_LINGUAS; do
- CATALOGS="$CATALOGS $lang.gmo"
- done
- fi
- test -n "$as_me" && echo "$as_me: creating $ac_dir/Makefile" || echo "creating $ac_dir/Makefile"
- sed -e "/^POTFILES =/r $ac_dir/POTFILES" -e "/^# Makevars/r $ac_given_srcdir/$ac_dir/Makevars" -e "s|@POFILES@|$POFILES|g" -e "s|@GMOFILES@|$GMOFILES|g" -e "s|@UPDATEPOFILES@|$UPDATEPOFILES|g" -e "s|@DUMMYPOFILES@|$DUMMYPOFILES|g" -e "s|@CATALOGS@|$CATALOGS|g" -e "s|@POMAKEFILEDEPS@|$POMAKEFILEDEPS|g" "$ac_dir/Makefile.in" > "$ac_dir/Makefile"
- for f in "$ac_given_srcdir/$ac_dir"/Rules-*; do
- if test -f "$f"; then
- case "$f" in
- *.orig | *.bak | *~) ;;
- *) cat "$f" >> "$ac_dir/Makefile" ;;
- esac
- fi
- done
- fi
- ;;
- esac
- done ;;
- "default-2":C)
- for ac_file in $CONFIG_FILES; do
- # Support "outfile[:infile[:infile...]]"
- case "$ac_file" in
- *:*) ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
- esac
- # PO directories have a Makefile.in generated from Makefile.in.in.
- case "$ac_file" in */Makefile.in)
- # Adjust a relative srcdir.
- ac_dir=`echo "$ac_file"|sed 's%/[^/][^/]*$%%'`
- ac_dir_suffix=/`echo "$ac_dir"|sed 's%^\./%%'`
- ac_dots=`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'`
- # In autoconf-2.13 it is called $ac_given_srcdir.
- # In autoconf-2.50 it is called $srcdir.
- test -n "$ac_given_srcdir" || ac_given_srcdir="$srcdir"
- case "$ac_given_srcdir" in
- .) top_srcdir=`echo $ac_dots|sed 's%/$%%'` ;;
- /*) top_srcdir="$ac_given_srcdir" ;;
- *) top_srcdir="$ac_dots$ac_given_srcdir" ;;
- esac
- if test -f "$ac_given_srcdir/$ac_dir/POTFILES.in"; then
- rm -f "$ac_dir/POTFILES"
- test -n "$as_me" && echo "$as_me: creating $ac_dir/POTFILES" || echo "creating $ac_dir/POTFILES"
- cat "$ac_given_srcdir/$ac_dir/POTFILES.in" | sed -e "/^#/d" -e "/^[ ]*\$/d" -e "s,.*, $top_srcdir/& \\\\," | sed -e "\$s/\(.*\) \\\\/\1/" > "$ac_dir/POTFILES"
- POMAKEFILEDEPS="POTFILES.in"
- # ALL_LINGUAS, POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES depend
- # on $ac_dir but don't depend on user-specified configuration
- # parameters.
- if test -f "$ac_given_srcdir/$ac_dir/LINGUAS"; then
- # The LINGUAS file contains the set of available languages.
- if test -n "$OBSOLETE_ALL_LINGUAS"; then
- test -n "$as_me" && echo "$as_me: setting ALL_LINGUAS in configure.ac is obsolete" || echo "setting ALL_LINGUAS in configure.ac is obsolete"
- fi
- ALL_LINGUAS_=`sed -e "/^#/d" "$ac_given_srcdir/$ac_dir/LINGUAS"`
- # Hide the ALL_LINGUAS assigment from automake.
- eval 'ALL_LINGUAS''=$ALL_LINGUAS_'
- POMAKEFILEDEPS="$POMAKEFILEDEPS LINGUAS"
- else
- # The set of available languages was given in configure.ac.
- eval 'ALL_LINGUAS''=$OBSOLETE_ALL_LINGUAS'
- fi
- case "$ac_given_srcdir" in
- .) srcdirpre= ;;
- *) srcdirpre='$(srcdir)/' ;;
- esac
- POFILES=
- GMOFILES=
- UPDATEPOFILES=
- DUMMYPOFILES=
- for lang in $ALL_LINGUAS; do
- POFILES="$POFILES $srcdirpre$lang.po"
- GMOFILES="$GMOFILES $srcdirpre$lang.gmo"
- UPDATEPOFILES="$UPDATEPOFILES $lang.po-update"
- DUMMYPOFILES="$DUMMYPOFILES $lang.nop"
- done
- # CATALOGS depends on both $ac_dir and the user's LINGUAS
- # environment variable.
- INST_LINGUAS=
- if test -n "$ALL_LINGUAS"; then
- for presentlang in $ALL_LINGUAS; do
- useit=no
- if test "%UNSET%" != "$LINGUAS"; then
- desiredlanguages="$LINGUAS"
- else
- desiredlanguages="$ALL_LINGUAS"
- fi
- for desiredlang in $desiredlanguages; do
- # Use the presentlang catalog if desiredlang is
- # a. equal to presentlang, or
- # b. a variant of presentlang (because in this case,
- # presentlang can be used as a fallback for messages
- # which are not translated in the desiredlang catalog).
- case "$desiredlang" in
- "$presentlang"*) useit=yes;;
- esac
- done
- if test $useit = yes; then
- INST_LINGUAS="$INST_LINGUAS $presentlang"
- fi
- done
- fi
- CATALOGS=
- if test -n "$INST_LINGUAS"; then
- for lang in $INST_LINGUAS; do
- CATALOGS="$CATALOGS $lang.gmo"
- done
- fi
- test -n "$as_me" && echo "$as_me: creating $ac_dir/Makefile" || echo "creating $ac_dir/Makefile"
- sed -e "/^POTFILES =/r $ac_dir/POTFILES" -e "/^# Makevars/r $ac_given_srcdir/$ac_dir/Makevars" -e "s|@POFILES@|$POFILES|g" -e "s|@GMOFILES@|$GMOFILES|g" -e "s|@UPDATEPOFILES@|$UPDATEPOFILES|g" -e "s|@DUMMYPOFILES@|$DUMMYPOFILES|g" -e "s|@CATALOGS@|$CATALOGS|g" -e "s|@POMAKEFILEDEPS@|$POMAKEFILEDEPS|g" "$ac_dir/Makefile.in" > "$ac_dir/Makefile"
- for f in "$ac_given_srcdir/$ac_dir"/Rules-*; do
- if test -f "$f"; then
- case "$f" in
- *.orig | *.bak | *~) ;;
- *) cat "$f" >> "$ac_dir/Makefile" ;;
- esac
- fi
- done
- fi
- ;;
- esac
- done ;;
- "default":C)
-case "$srcdir" in
- .) srcdirpre= ;;
- *) srcdirpre='$(srcdir)/' ;;
-esac
-POFILES=
-GMOFILES=
-for lang in dummy $OBSOLETE_ALL_LINGUAS; do
- if test $lang != dummy; then
- POFILES="$POFILES $srcdirpre$lang.po"
- GMOFILES="$GMOFILES $srcdirpre$lang.gmo"
- fi
-done
-sed -e '/^SRC-POTFILES =/r po/SRC-POTFILES' \
- -e '/^BLD-POTFILES =/r po/BLD-POTFILES' \
- -e "s,@POFILES@,$POFILES," \
- -e "s,@GMOFILES@,$GMOFILES," \
- po/Makefile.in > po/Makefile ;;
-
- esac
-done # for ac_tag
-
-
-as_fn_exit 0
-_ACEOF
-ac_clean_files=$ac_clean_files_save
-
-test $ac_write_fail = 0 ||
- as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
-
-
-# configure is writing to config.log, and then calls config.status.
-# config.status does its own redirection, appending to config.log.
-# Unfortunately, on DOS this fails, as config.log is still kept open
-# by configure, so config.status won't be able to write to it; its
-# output is simply discarded. So we exec the FD to /dev/null,
-# effectively closing config.log, so it can be properly (re)opened and
-# appended to by config.status. When coming back to configure, we
-# need to make the FD available again.
-if test "$no_create" != yes; then
- ac_cs_success=:
- ac_config_status_args=
- test "$silent" = yes &&
- ac_config_status_args="$ac_config_status_args --quiet"
- exec 5>/dev/null
- $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
- exec 5>>config.log
- # Use ||, not &&, to avoid exiting from the if with $? = 1, which
- # would make configure fail if this is the last instruction.
- $ac_cs_success || as_fn_exit 1
-fi
-if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
-$as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
-fi
-
-
-
-touch config.status.tmp
-if touch --reference=config.status config.status.tmp > /dev/null 2>&1; then
- sed '/as_fn_exit 0/i \
-sed -e \"s/^\t\\\(\\\$(AM_V_CCLD)\\\)/\t+ \\\1/\" Makefile > Makefile.tmp \
-touch --reference=Makefile Makefile.tmp \
-mv Makefile.tmp Makefile \
-' config.status > config.status.tmp
- touch --reference=config.status config.status.tmp
- mv config.status.tmp config.status
- chmod +x config.status
- sed -e "s/^\t\(\$(AM_V_CCLD)\)/\t+ \1/" Makefile > Makefile.tmp
- touch --reference=Makefile Makefile.tmp
- mv Makefile.tmp Makefile
-else
- rm -f config.status.tmp
-fi
Property changes on: sources/GNU/binutils/create-2.43.1-libtool-lib64-patch/binutils-2.43.1-new/ld/configure
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: sources/GNU/binutils/create-2.43.1-libtool-lib64-patch/binutils-2.43.1-new/binutils/configure
===================================================================
--- sources/GNU/binutils/create-2.43.1-libtool-lib64-patch/binutils-2.43.1-new/binutils/configure (revision 75)
+++ sources/GNU/binutils/create-2.43.1-libtool-lib64-patch/binutils-2.43.1-new/binutils/configure (nonexistent)
@@ -1,19264 +0,0 @@
-#! /bin/sh
-# Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.69 for binutils 2.43.1.
-#
-#
-# Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc.
-#
-#
-# This configure script is free software; the Free Software Foundation
-# gives unlimited permission to copy, distribute and modify it.
-## -------------------- ##
-## M4sh Initialization. ##
-## -------------------- ##
-
-# Be more Bourne compatible
-DUALCASE=1; export DUALCASE # for MKS sh
-if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
- emulate sh
- NULLCMD=:
- # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
- # is contrary to our usage. Disable this feature.
- alias -g '${1+"$@"}'='"$@"'
- setopt NO_GLOB_SUBST
-else
- case `(set -o) 2>/dev/null` in #(
- *posix*) :
- set -o posix ;; #(
- *) :
- ;;
-esac
-fi
-
-
-as_nl='
-'
-export as_nl
-# Printing a long string crashes Solaris 7 /usr/bin/printf.
-as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
-as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
-as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
-# Prefer a ksh shell builtin over an external printf program on Solaris,
-# but without wasting forks for bash or zsh.
-if test -z "$BASH_VERSION$ZSH_VERSION" \
- && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
- as_echo='print -r --'
- as_echo_n='print -rn --'
-elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
- as_echo='printf %s\n'
- as_echo_n='printf %s'
-else
- if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
- as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
- as_echo_n='/usr/ucb/echo -n'
- else
- as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
- as_echo_n_body='eval
- arg=$1;
- case $arg in #(
- *"$as_nl"*)
- expr "X$arg" : "X\\(.*\\)$as_nl";
- arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
- esac;
- expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
- '
- export as_echo_n_body
- as_echo_n='sh -c $as_echo_n_body as_echo'
- fi
- export as_echo_body
- as_echo='sh -c $as_echo_body as_echo'
-fi
-
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- PATH_SEPARATOR=:
- (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
- (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
- PATH_SEPARATOR=';'
- }
-fi
-
-
-# IFS
-# We need space, tab and new line, in precisely that order. Quoting is
-# there to prevent editors from complaining about space-tab.
-# (If _AS_PATH_WALK were called with IFS unset, it would disable word
-# splitting by setting IFS to empty value.)
-IFS=" "" $as_nl"
-
-# Find who we are. Look in the path if we contain no directory separator.
-as_myself=
-case $0 in #((
- *[\\/]* ) as_myself=$0 ;;
- *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
- done
-IFS=$as_save_IFS
-
- ;;
-esac
-# We did not find ourselves, most probably we were run as `sh COMMAND'
-# in which case we are not to be found in the path.
-if test "x$as_myself" = x; then
- as_myself=$0
-fi
-if test ! -f "$as_myself"; then
- $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
- exit 1
-fi
-
-# Unset variables that we do not need and which cause bugs (e.g. in
-# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
-# suppresses any "Segmentation fault" message there. '((' could
-# trigger a bug in pdksh 5.2.14.
-for as_var in BASH_ENV ENV MAIL MAILPATH
-do eval test x\${$as_var+set} = xset \
- && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
-done
-PS1='$ '
-PS2='> '
-PS4='+ '
-
-# NLS nuisances.
-LC_ALL=C
-export LC_ALL
-LANGUAGE=C
-export LANGUAGE
-
-# CDPATH.
-(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
-
-# Use a proper internal environment variable to ensure we don't fall
- # into an infinite loop, continuously re-executing ourselves.
- if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then
- _as_can_reexec=no; export _as_can_reexec;
- # We cannot yet assume a decent shell, so we have to provide a
-# neutralization value for shells without unset; and this also
-# works around shells that cannot unset nonexistent variables.
-# Preserve -v and -x to the replacement shell.
-BASH_ENV=/dev/null
-ENV=/dev/null
-(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
-case $- in # ((((
- *v*x* | *x*v* ) as_opts=-vx ;;
- *v* ) as_opts=-v ;;
- *x* ) as_opts=-x ;;
- * ) as_opts= ;;
-esac
-exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
-# Admittedly, this is quite paranoid, since all the known shells bail
-# out after a failed `exec'.
-$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
-as_fn_exit 255
- fi
- # We don't want this to propagate to other subprocesses.
- { _as_can_reexec=; unset _as_can_reexec;}
-if test "x$CONFIG_SHELL" = x; then
- as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
- emulate sh
- NULLCMD=:
- # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
- # is contrary to our usage. Disable this feature.
- alias -g '\${1+\"\$@\"}'='\"\$@\"'
- setopt NO_GLOB_SUBST
-else
- case \`(set -o) 2>/dev/null\` in #(
- *posix*) :
- set -o posix ;; #(
- *) :
- ;;
-esac
-fi
-"
- as_required="as_fn_return () { (exit \$1); }
-as_fn_success () { as_fn_return 0; }
-as_fn_failure () { as_fn_return 1; }
-as_fn_ret_success () { return 0; }
-as_fn_ret_failure () { return 1; }
-
-exitcode=0
-as_fn_success || { exitcode=1; echo as_fn_success failed.; }
-as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
-as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
-as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
-if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
-
-else
- exitcode=1; echo positional parameters were not saved.
-fi
-test x\$exitcode = x0 || exit 1
-test -x / || exit 1"
- as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
- as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
- eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
- test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
-test \$(( 1 + 1 )) = 2 || exit 1
-
- test -n \"\${ZSH_VERSION+set}\${BASH_VERSION+set}\" || (
- ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
- ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO
- ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO
- PATH=/empty FPATH=/empty; export PATH FPATH
- test \"X\`printf %s \$ECHO\`\" = \"X\$ECHO\" \\
- || test \"X\`print -r -- \$ECHO\`\" = \"X\$ECHO\" ) || exit 1"
- if (eval "$as_required") 2>/dev/null; then :
- as_have_required=yes
-else
- as_have_required=no
-fi
- if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
-
-else
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-as_found=false
-for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- as_found=:
- case $as_dir in #(
- /*)
- for as_base in sh bash ksh sh5; do
- # Try only shells that exist, to save several forks.
- as_shell=$as_dir/$as_base
- if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
- { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
- CONFIG_SHELL=$as_shell as_have_required=yes
- if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
- break 2
-fi
-fi
- done;;
- esac
- as_found=false
-done
-$as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
- { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
- CONFIG_SHELL=$SHELL as_have_required=yes
-fi; }
-IFS=$as_save_IFS
-
-
- if test "x$CONFIG_SHELL" != x; then :
- export CONFIG_SHELL
- # We cannot yet assume a decent shell, so we have to provide a
-# neutralization value for shells without unset; and this also
-# works around shells that cannot unset nonexistent variables.
-# Preserve -v and -x to the replacement shell.
-BASH_ENV=/dev/null
-ENV=/dev/null
-(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
-case $- in # ((((
- *v*x* | *x*v* ) as_opts=-vx ;;
- *v* ) as_opts=-v ;;
- *x* ) as_opts=-x ;;
- * ) as_opts= ;;
-esac
-exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
-# Admittedly, this is quite paranoid, since all the known shells bail
-# out after a failed `exec'.
-$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
-exit 255
-fi
-
- if test x$as_have_required = xno; then :
- $as_echo "$0: This script requires a shell more modern than all"
- $as_echo "$0: the shells that I found on your system."
- if test x${ZSH_VERSION+set} = xset ; then
- $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
- $as_echo "$0: be upgraded to zsh 4.3.4 or later."
- else
- $as_echo "$0: Please tell bug-autoconf@gnu.org about your system,
-$0: including any error possibly output before this
-$0: message. Then install a modern shell, or manually run
-$0: the script under such a shell if you do have one."
- fi
- exit 1
-fi
-fi
-fi
-SHELL=${CONFIG_SHELL-/bin/sh}
-export SHELL
-# Unset more variables known to interfere with behavior of common tools.
-CLICOLOR_FORCE= GREP_OPTIONS=
-unset CLICOLOR_FORCE GREP_OPTIONS
-
-## --------------------- ##
-## M4sh Shell Functions. ##
-## --------------------- ##
-# as_fn_unset VAR
-# ---------------
-# Portably unset VAR.
-as_fn_unset ()
-{
- { eval $1=; unset $1;}
-}
-as_unset=as_fn_unset
-
-# as_fn_set_status STATUS
-# -----------------------
-# Set $? to STATUS, without forking.
-as_fn_set_status ()
-{
- return $1
-} # as_fn_set_status
-
-# as_fn_exit STATUS
-# -----------------
-# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
-as_fn_exit ()
-{
- set +e
- as_fn_set_status $1
- exit $1
-} # as_fn_exit
-
-# as_fn_mkdir_p
-# -------------
-# Create "$as_dir" as a directory, including parents if necessary.
-as_fn_mkdir_p ()
-{
-
- case $as_dir in #(
- -*) as_dir=./$as_dir;;
- esac
- test -d "$as_dir" || eval $as_mkdir_p || {
- as_dirs=
- while :; do
- case $as_dir in #(
- *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
- *) as_qdir=$as_dir;;
- esac
- as_dirs="'$as_qdir' $as_dirs"
- as_dir=`$as_dirname -- "$as_dir" ||
-$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$as_dir" : 'X\(//\)[^/]' \| \
- X"$as_dir" : 'X\(//\)$' \| \
- X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$as_dir" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
- test -d "$as_dir" && break
- done
- test -z "$as_dirs" || eval "mkdir $as_dirs"
- } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
-
-
-} # as_fn_mkdir_p
-
-# as_fn_executable_p FILE
-# -----------------------
-# Test if FILE is an executable regular file.
-as_fn_executable_p ()
-{
- test -f "$1" && test -x "$1"
-} # as_fn_executable_p
-# as_fn_append VAR VALUE
-# ----------------------
-# Append the text in VALUE to the end of the definition contained in VAR. Take
-# advantage of any shell optimizations that allow amortized linear growth over
-# repeated appends, instead of the typical quadratic growth present in naive
-# implementations.
-if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
- eval 'as_fn_append ()
- {
- eval $1+=\$2
- }'
-else
- as_fn_append ()
- {
- eval $1=\$$1\$2
- }
-fi # as_fn_append
-
-# as_fn_arith ARG...
-# ------------------
-# Perform arithmetic evaluation on the ARGs, and store the result in the
-# global $as_val. Take advantage of shells that can avoid forks. The arguments
-# must be portable across $(()) and expr.
-if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
- eval 'as_fn_arith ()
- {
- as_val=$(( $* ))
- }'
-else
- as_fn_arith ()
- {
- as_val=`expr "$@" || test $? -eq 1`
- }
-fi # as_fn_arith
-
-
-# as_fn_error STATUS ERROR [LINENO LOG_FD]
-# ----------------------------------------
-# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
-# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
-# script with STATUS, using 1 if that was 0.
-as_fn_error ()
-{
- as_status=$1; test $as_status -eq 0 && as_status=1
- if test "$4"; then
- as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
- fi
- $as_echo "$as_me: error: $2" >&2
- as_fn_exit $as_status
-} # as_fn_error
-
-if expr a : '\(a\)' >/dev/null 2>&1 &&
- test "X`expr 00001 : '.*\(...\)'`" = X001; then
- as_expr=expr
-else
- as_expr=false
-fi
-
-if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
- as_basename=basename
-else
- as_basename=false
-fi
-
-if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
- as_dirname=dirname
-else
- as_dirname=false
-fi
-
-as_me=`$as_basename -- "$0" ||
-$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
- X"$0" : 'X\(//\)$' \| \
- X"$0" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X/"$0" |
- sed '/^.*\/\([^/][^/]*\)\/*$/{
- s//\1/
- q
- }
- /^X\/\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\/\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
-
-# Avoid depending upon Character Ranges.
-as_cr_letters='abcdefghijklmnopqrstuvwxyz'
-as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
-as_cr_Letters=$as_cr_letters$as_cr_LETTERS
-as_cr_digits='0123456789'
-as_cr_alnum=$as_cr_Letters$as_cr_digits
-
-
- as_lineno_1=$LINENO as_lineno_1a=$LINENO
- as_lineno_2=$LINENO as_lineno_2a=$LINENO
- eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
- test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
- # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-)
- sed -n '
- p
- /[$]LINENO/=
- ' <$as_myself |
- sed '
- s/[$]LINENO.*/&-/
- t lineno
- b
- :lineno
- N
- :loop
- s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
- t loop
- s/-\n.*//
- ' >$as_me.lineno &&
- chmod +x "$as_me.lineno" ||
- { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
-
- # If we had to re-execute with $CONFIG_SHELL, we're ensured to have
- # already done that, so ensure we don't try to do so again and fall
- # in an infinite loop. This has already happened in practice.
- _as_can_reexec=no; export _as_can_reexec
- # Don't try to exec as it changes $[0], causing all sort of problems
- # (the dirname of $[0] is not the place where we might find the
- # original and so on. Autoconf is especially sensitive to this).
- . "./$as_me.lineno"
- # Exit status is that of the last command.
- exit
-}
-
-ECHO_C= ECHO_N= ECHO_T=
-case `echo -n x` in #(((((
--n*)
- case `echo 'xy\c'` in
- *c*) ECHO_T=' ';; # ECHO_T is single tab character.
- xy) ECHO_C='\c';;
- *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
- ECHO_T=' ';;
- esac;;
-*)
- ECHO_N='-n';;
-esac
-
-rm -f conf$$ conf$$.exe conf$$.file
-if test -d conf$$.dir; then
- rm -f conf$$.dir/conf$$.file
-else
- rm -f conf$$.dir
- mkdir conf$$.dir 2>/dev/null
-fi
-if (echo >conf$$.file) 2>/dev/null; then
- if ln -s conf$$.file conf$$ 2>/dev/null; then
- as_ln_s='ln -s'
- # ... but there are two gotchas:
- # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
- # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
- # In both cases, we have to default to `cp -pR'.
- ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
- as_ln_s='cp -pR'
- elif ln conf$$.file conf$$ 2>/dev/null; then
- as_ln_s=ln
- else
- as_ln_s='cp -pR'
- fi
-else
- as_ln_s='cp -pR'
-fi
-rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
-rmdir conf$$.dir 2>/dev/null
-
-if mkdir -p . 2>/dev/null; then
- as_mkdir_p='mkdir -p "$as_dir"'
-else
- test -d ./-p && rmdir ./-p
- as_mkdir_p=false
-fi
-
-as_test_x='test -x'
-as_executable_p=as_fn_executable_p
-
-# Sed expression to map a string onto a valid CPP name.
-as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
-
-# Sed expression to map a string onto a valid variable name.
-as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
-
-SHELL=${CONFIG_SHELL-/bin/sh}
-
-
-test -n "$DJDIR" || exec 7<&0 </dev/null
-exec 6>&1
-
-# Name of the host.
-# hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status,
-# so uname gets run too.
-ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
-
-#
-# Initializations.
-#
-ac_default_prefix=/usr/local
-ac_clean_files=
-ac_config_libobj_dir=.
-LIBOBJS=
-cross_compiling=no
-subdirs=
-MFLAGS=
-MAKEFLAGS=
-
-# Identity of this package.
-PACKAGE_NAME='binutils'
-PACKAGE_TARNAME='binutils'
-PACKAGE_VERSION='2.43.1'
-PACKAGE_STRING='binutils 2.43.1'
-PACKAGE_BUGREPORT=''
-PACKAGE_URL=''
-
-ac_unique_file="ar.c"
-# Factoring default headers for most tests.
-ac_includes_default="\
-#include <stdio.h>
-#ifdef HAVE_SYS_TYPES_H
-# include <sys/types.h>
-#endif
-#ifdef HAVE_SYS_STAT_H
-# include <sys/stat.h>
-#endif
-#ifdef STDC_HEADERS
-# include <stdlib.h>
-# include <stddef.h>
-#else
-# ifdef HAVE_STDLIB_H
-# include <stdlib.h>
-# endif
-#endif
-#ifdef HAVE_STRING_H
-# if !defined STDC_HEADERS && defined HAVE_MEMORY_H
-# include <memory.h>
-# endif
-# include <string.h>
-#endif
-#ifdef HAVE_STRINGS_H
-# include <strings.h>
-#endif
-#ifdef HAVE_INTTYPES_H
-# include <inttypes.h>
-#endif
-#ifdef HAVE_STDINT_H
-# include <stdint.h>
-#endif
-#ifdef HAVE_UNISTD_H
-# include <unistd.h>
-#endif"
-
-gt_needs=
-ac_header_list=
-ac_subst_vars='am__EXEEXT_FALSE
-am__EXEEXT_TRUE
-LTLIBOBJS
-LIBOBJS
-EMULATION_VECTOR
-EMULATION
-OBJDUMP_PRIVATE_OFILES
-OBJDUMP_DEFS
-BUILD_INSTALL_MISC
-BUILD_MISC
-BUILD_DLLWRAP
-BUILD_WINDMC
-BUILD_WINDRES
-DLLTOOL_DEFS
-BUILD_DLLTOOL
-BUILD_SRCONV
-MSGPACK_LIBS
-MSGPACK_CFLAGS
-ZSTD_LIBS
-ZSTD_CFLAGS
-zlibinc
-zlibdir
-DEMANGLER_NAME
-EXEEXT_FOR_BUILD
-CC_FOR_BUILD
-HDEFINES
-GENINSRC_NEVER_FALSE
-GENINSRC_NEVER_TRUE
-MAINT
-MAINTAINER_MODE_FALSE
-MAINTAINER_MODE_TRUE
-CATOBJEXT
-GENCAT
-INSTOBJEXT
-DATADIRNAME
-CATALOGS
-INCINTL
-LIBINTL_DEP
-POSUB
-LTLIBINTL
-LIBINTL
-INTLLIBS
-LTLIBICONV
-LIBICONV
-INTL_MACOSX_LIBS
-MSGMERGE
-XGETTEXT
-GMSGFMT
-MSGFMT
-USE_NLS
-MKINSTALLDIRS
-LEXLIB
-LEX_OUTPUT_ROOT
-LEX
-YFLAGS
-YACC
-WARN_WRITE_STRINGS
-NO_WERROR
-WARN_CFLAGS_FOR_BUILD
-WARN_CFLAGS
-ENABLE_LIBCTF_FALSE
-ENABLE_LIBCTF_TRUE
-DEBUGINFOD_LIBS
-DEBUGINFOD_CFLAGS
-PKG_CONFIG_LIBDIR
-PKG_CONFIG_PATH
-PKG_CONFIG
-LARGEFILE_CPPFLAGS
-OTOOL64
-OTOOL
-LIPO
-NMEDIT
-DSYMUTIL
-RANLIB
-AR
-OBJDUMP
-LN_S
-NM
-ac_ct_DUMPBIN
-DUMPBIN
-LD
-FGREP
-SED
-LIBTOOL
-EGREP
-GREP
-CPP
-am__fastdepCC_FALSE
-am__fastdepCC_TRUE
-CCDEPMODE
-am__nodep
-AMDEPBACKSLASH
-AMDEP_FALSE
-AMDEP_TRUE
-am__quote
-am__include
-DEPDIR
-OBJEXT
-EXEEXT
-ac_ct_CC
-CPPFLAGS
-LDFLAGS
-CFLAGS
-CC
-AM_BACKSLASH
-AM_DEFAULT_VERBOSITY
-AM_DEFAULT_V
-AM_V
-am__untar
-am__tar
-AMTAR
-am__leading_dot
-SET_MAKE
-AWK
-mkdir_p
-MKDIR_P
-INSTALL_STRIP_PROGRAM
-STRIP
-install_sh
-MAKEINFO
-AUTOHEADER
-AUTOMAKE
-AUTOCONF
-ACLOCAL
-VERSION
-PACKAGE
-CYGPATH_W
-am__isrc
-INSTALL_DATA
-INSTALL_SCRIPT
-INSTALL_PROGRAM
-target_os
-target_vendor
-target_cpu
-target
-host_os
-host_vendor
-host_cpu
-host
-build_os
-build_vendor
-build_cpu
-build
-target_alias
-host_alias
-build_alias
-LIBS
-ECHO_T
-ECHO_N
-ECHO_C
-DEFS
-mandir
-localedir
-libdir
-psdir
-pdfdir
-dvidir
-htmldir
-infodir
-docdir
-oldincludedir
-includedir
-localstatedir
-sharedstatedir
-sysconfdir
-datadir
-datarootdir
-libexecdir
-sbindir
-bindir
-program_transform_name
-prefix
-exec_prefix
-PACKAGE_URL
-PACKAGE_BUGREPORT
-PACKAGE_STRING
-PACKAGE_VERSION
-PACKAGE_TARNAME
-PACKAGE_NAME
-PATH_SEPARATOR
-SHELL'
-ac_subst_files=''
-ac_user_opts='
-enable_option_checking
-enable_silent_rules
-enable_dependency_tracking
-enable_shared
-enable_static
-with_pic
-enable_fast_install
-with_gnu_ld
-enable_libtool_lock
-enable_plugins
-enable_largefile
-enable_checking
-enable_targets
-enable_deterministic_archives
-enable_default_strings_all
-enable_f_for_ifunc_symbols
-enable_follow_debug_links
-enable_colored_disassembly
-with_debuginfod
-enable_libctf
-enable_werror
-enable_build_warnings
-enable_nls
-enable_rpath
-with_libiconv_prefix
-with_libiconv_type
-with_libintl_prefix
-with_libintl_type
-enable_maintainer_mode
-with_system_zlib
-with_zstd
-with_msgpack
-'
- ac_precious_vars='build_alias
-host_alias
-target_alias
-CC
-CFLAGS
-LDFLAGS
-LIBS
-CPPFLAGS
-CPP
-PKG_CONFIG
-PKG_CONFIG_PATH
-PKG_CONFIG_LIBDIR
-DEBUGINFOD_CFLAGS
-DEBUGINFOD_LIBS
-YACC
-YFLAGS
-ZSTD_CFLAGS
-ZSTD_LIBS
-MSGPACK_CFLAGS
-MSGPACK_LIBS'
-
-
-# Initialize some variables set by options.
-ac_init_help=
-ac_init_version=false
-ac_unrecognized_opts=
-ac_unrecognized_sep=
-# The variables have the same names as the options, with
-# dashes changed to underlines.
-cache_file=/dev/null
-exec_prefix=NONE
-no_create=
-no_recursion=
-prefix=NONE
-program_prefix=NONE
-program_suffix=NONE
-program_transform_name=s,x,x,
-silent=
-site=
-srcdir=
-verbose=
-x_includes=NONE
-x_libraries=NONE
-
-# Installation directory options.
-# These are left unexpanded so users can "make install exec_prefix=/foo"
-# and all the variables that are supposed to be based on exec_prefix
-# by default will actually change.
-# Use braces instead of parens because sh, perl, etc. also accept them.
-# (The list follows the same order as the GNU Coding Standards.)
-bindir='${exec_prefix}/bin'
-sbindir='${exec_prefix}/sbin'
-libexecdir='${exec_prefix}/libexec'
-datarootdir='${prefix}/share'
-datadir='${datarootdir}'
-sysconfdir='${prefix}/etc'
-sharedstatedir='${prefix}/com'
-localstatedir='${prefix}/var'
-includedir='${prefix}/include'
-oldincludedir='/usr/include'
-docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
-infodir='${datarootdir}/info'
-htmldir='${docdir}'
-dvidir='${docdir}'
-pdfdir='${docdir}'
-psdir='${docdir}'
-libdir='${exec_prefix}/lib'
-localedir='${datarootdir}/locale'
-mandir='${datarootdir}/man'
-
-ac_prev=
-ac_dashdash=
-for ac_option
-do
- # If the previous option needs an argument, assign it.
- if test -n "$ac_prev"; then
- eval $ac_prev=\$ac_option
- ac_prev=
- continue
- fi
-
- case $ac_option in
- *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
- *=) ac_optarg= ;;
- *) ac_optarg=yes ;;
- esac
-
- # Accept the important Cygnus configure options, so we can diagnose typos.
-
- case $ac_dashdash$ac_option in
- --)
- ac_dashdash=yes ;;
-
- -bindir | --bindir | --bindi | --bind | --bin | --bi)
- ac_prev=bindir ;;
- -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
- bindir=$ac_optarg ;;
-
- -build | --build | --buil | --bui | --bu)
- ac_prev=build_alias ;;
- -build=* | --build=* | --buil=* | --bui=* | --bu=*)
- build_alias=$ac_optarg ;;
-
- -cache-file | --cache-file | --cache-fil | --cache-fi \
- | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
- ac_prev=cache_file ;;
- -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
- | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
- cache_file=$ac_optarg ;;
-
- --config-cache | -C)
- cache_file=config.cache ;;
-
- -datadir | --datadir | --datadi | --datad)
- ac_prev=datadir ;;
- -datadir=* | --datadir=* | --datadi=* | --datad=*)
- datadir=$ac_optarg ;;
-
- -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
- | --dataroo | --dataro | --datar)
- ac_prev=datarootdir ;;
- -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
- | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
- datarootdir=$ac_optarg ;;
-
- -disable-* | --disable-*)
- ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
- # Reject names that are not valid shell variable names.
- expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
- as_fn_error $? "invalid feature name: $ac_useropt"
- ac_useropt_orig=$ac_useropt
- ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
- case $ac_user_opts in
- *"
-"enable_$ac_useropt"
-"*) ;;
- *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
- ac_unrecognized_sep=', ';;
- esac
- eval enable_$ac_useropt=no ;;
-
- -docdir | --docdir | --docdi | --doc | --do)
- ac_prev=docdir ;;
- -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
- docdir=$ac_optarg ;;
-
- -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
- ac_prev=dvidir ;;
- -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
- dvidir=$ac_optarg ;;
-
- -enable-* | --enable-*)
- ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
- # Reject names that are not valid shell variable names.
- expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
- as_fn_error $? "invalid feature name: $ac_useropt"
- ac_useropt_orig=$ac_useropt
- ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
- case $ac_user_opts in
- *"
-"enable_$ac_useropt"
-"*) ;;
- *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
- ac_unrecognized_sep=', ';;
- esac
- eval enable_$ac_useropt=\$ac_optarg ;;
-
- -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
- | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
- | --exec | --exe | --ex)
- ac_prev=exec_prefix ;;
- -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
- | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
- | --exec=* | --exe=* | --ex=*)
- exec_prefix=$ac_optarg ;;
-
- -gas | --gas | --ga | --g)
- # Obsolete; use --with-gas.
- with_gas=yes ;;
-
- -help | --help | --hel | --he | -h)
- ac_init_help=long ;;
- -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
- ac_init_help=recursive ;;
- -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
- ac_init_help=short ;;
-
- -host | --host | --hos | --ho)
- ac_prev=host_alias ;;
- -host=* | --host=* | --hos=* | --ho=*)
- host_alias=$ac_optarg ;;
-
- -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
- ac_prev=htmldir ;;
- -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
- | --ht=*)
- htmldir=$ac_optarg ;;
-
- -includedir | --includedir | --includedi | --included | --include \
- | --includ | --inclu | --incl | --inc)
- ac_prev=includedir ;;
- -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
- | --includ=* | --inclu=* | --incl=* | --inc=*)
- includedir=$ac_optarg ;;
-
- -infodir | --infodir | --infodi | --infod | --info | --inf)
- ac_prev=infodir ;;
- -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
- infodir=$ac_optarg ;;
-
- -libdir | --libdir | --libdi | --libd)
- ac_prev=libdir ;;
- -libdir=* | --libdir=* | --libdi=* | --libd=*)
- libdir=$ac_optarg ;;
-
- -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
- | --libexe | --libex | --libe)
- ac_prev=libexecdir ;;
- -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
- | --libexe=* | --libex=* | --libe=*)
- libexecdir=$ac_optarg ;;
-
- -localedir | --localedir | --localedi | --localed | --locale)
- ac_prev=localedir ;;
- -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
- localedir=$ac_optarg ;;
-
- -localstatedir | --localstatedir | --localstatedi | --localstated \
- | --localstate | --localstat | --localsta | --localst | --locals)
- ac_prev=localstatedir ;;
- -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
- | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
- localstatedir=$ac_optarg ;;
-
- -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
- ac_prev=mandir ;;
- -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
- mandir=$ac_optarg ;;
-
- -nfp | --nfp | --nf)
- # Obsolete; use --without-fp.
- with_fp=no ;;
-
- -no-create | --no-create | --no-creat | --no-crea | --no-cre \
- | --no-cr | --no-c | -n)
- no_create=yes ;;
-
- -no-recursion | --no-recursion | --no-recursio | --no-recursi \
- | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
- no_recursion=yes ;;
-
- -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
- | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
- | --oldin | --oldi | --old | --ol | --o)
- ac_prev=oldincludedir ;;
- -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
- | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
- | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
- oldincludedir=$ac_optarg ;;
-
- -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
- ac_prev=prefix ;;
- -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
- prefix=$ac_optarg ;;
-
- -program-prefix | --program-prefix | --program-prefi | --program-pref \
- | --program-pre | --program-pr | --program-p)
- ac_prev=program_prefix ;;
- -program-prefix=* | --program-prefix=* | --program-prefi=* \
- | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
- program_prefix=$ac_optarg ;;
-
- -program-suffix | --program-suffix | --program-suffi | --program-suff \
- | --program-suf | --program-su | --program-s)
- ac_prev=program_suffix ;;
- -program-suffix=* | --program-suffix=* | --program-suffi=* \
- | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
- program_suffix=$ac_optarg ;;
-
- -program-transform-name | --program-transform-name \
- | --program-transform-nam | --program-transform-na \
- | --program-transform-n | --program-transform- \
- | --program-transform | --program-transfor \
- | --program-transfo | --program-transf \
- | --program-trans | --program-tran \
- | --progr-tra | --program-tr | --program-t)
- ac_prev=program_transform_name ;;
- -program-transform-name=* | --program-transform-name=* \
- | --program-transform-nam=* | --program-transform-na=* \
- | --program-transform-n=* | --program-transform-=* \
- | --program-transform=* | --program-transfor=* \
- | --program-transfo=* | --program-transf=* \
- | --program-trans=* | --program-tran=* \
- | --progr-tra=* | --program-tr=* | --program-t=*)
- program_transform_name=$ac_optarg ;;
-
- -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
- ac_prev=pdfdir ;;
- -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
- pdfdir=$ac_optarg ;;
-
- -psdir | --psdir | --psdi | --psd | --ps)
- ac_prev=psdir ;;
- -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
- psdir=$ac_optarg ;;
-
- -q | -quiet | --quiet | --quie | --qui | --qu | --q \
- | -silent | --silent | --silen | --sile | --sil)
- silent=yes ;;
-
- -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
- ac_prev=sbindir ;;
- -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
- | --sbi=* | --sb=*)
- sbindir=$ac_optarg ;;
-
- -sharedstatedir | --sharedstatedir | --sharedstatedi \
- | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
- | --sharedst | --shareds | --shared | --share | --shar \
- | --sha | --sh)
- ac_prev=sharedstatedir ;;
- -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
- | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
- | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
- | --sha=* | --sh=*)
- sharedstatedir=$ac_optarg ;;
-
- -site | --site | --sit)
- ac_prev=site ;;
- -site=* | --site=* | --sit=*)
- site=$ac_optarg ;;
-
- -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
- ac_prev=srcdir ;;
- -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
- srcdir=$ac_optarg ;;
-
- -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
- | --syscon | --sysco | --sysc | --sys | --sy)
- ac_prev=sysconfdir ;;
- -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
- | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
- sysconfdir=$ac_optarg ;;
-
- -target | --target | --targe | --targ | --tar | --ta | --t)
- ac_prev=target_alias ;;
- -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
- target_alias=$ac_optarg ;;
-
- -v | -verbose | --verbose | --verbos | --verbo | --verb)
- verbose=yes ;;
-
- -version | --version | --versio | --versi | --vers | -V)
- ac_init_version=: ;;
-
- -with-* | --with-*)
- ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
- # Reject names that are not valid shell variable names.
- expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
- as_fn_error $? "invalid package name: $ac_useropt"
- ac_useropt_orig=$ac_useropt
- ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
- case $ac_user_opts in
- *"
-"with_$ac_useropt"
-"*) ;;
- *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
- ac_unrecognized_sep=', ';;
- esac
- eval with_$ac_useropt=\$ac_optarg ;;
-
- -without-* | --without-*)
- ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
- # Reject names that are not valid shell variable names.
- expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
- as_fn_error $? "invalid package name: $ac_useropt"
- ac_useropt_orig=$ac_useropt
- ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
- case $ac_user_opts in
- *"
-"with_$ac_useropt"
-"*) ;;
- *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
- ac_unrecognized_sep=', ';;
- esac
- eval with_$ac_useropt=no ;;
-
- --x)
- # Obsolete; use --with-x.
- with_x=yes ;;
-
- -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
- | --x-incl | --x-inc | --x-in | --x-i)
- ac_prev=x_includes ;;
- -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
- | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
- x_includes=$ac_optarg ;;
-
- -x-libraries | --x-libraries | --x-librarie | --x-librari \
- | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
- ac_prev=x_libraries ;;
- -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
- | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
- x_libraries=$ac_optarg ;;
-
- -*) as_fn_error $? "unrecognized option: \`$ac_option'
-Try \`$0 --help' for more information"
- ;;
-
- *=*)
- ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
- # Reject names that are not valid shell variable names.
- case $ac_envvar in #(
- '' | [0-9]* | *[!_$as_cr_alnum]* )
- as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
- esac
- eval $ac_envvar=\$ac_optarg
- export $ac_envvar ;;
-
- *)
- # FIXME: should be removed in autoconf 3.0.
- $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
- expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
- $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
- : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
- ;;
-
- esac
-done
-
-if test -n "$ac_prev"; then
- ac_option=--`echo $ac_prev | sed 's/_/-/g'`
- as_fn_error $? "missing argument to $ac_option"
-fi
-
-if test -n "$ac_unrecognized_opts"; then
- case $enable_option_checking in
- no) ;;
- fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
- *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
- esac
-fi
-
-# Check all directory arguments for consistency.
-for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
- datadir sysconfdir sharedstatedir localstatedir includedir \
- oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
- libdir localedir mandir
-do
- eval ac_val=\$$ac_var
- # Remove trailing slashes.
- case $ac_val in
- */ )
- ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
- eval $ac_var=\$ac_val;;
- esac
- # Be sure to have absolute directory names.
- case $ac_val in
- [\\/$]* | ?:[\\/]* ) continue;;
- NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
- esac
- as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
-done
-
-# There might be people who depend on the old broken behavior: `$host'
-# used to hold the argument of --host etc.
-# FIXME: To remove some day.
-build=$build_alias
-host=$host_alias
-target=$target_alias
-
-# FIXME: To remove some day.
-if test "x$host_alias" != x; then
- if test "x$build_alias" = x; then
- cross_compiling=maybe
- elif test "x$build_alias" != "x$host_alias"; then
- cross_compiling=yes
- fi
-fi
-
-ac_tool_prefix=
-test -n "$host_alias" && ac_tool_prefix=$host_alias-
-
-test "$silent" = yes && exec 6>/dev/null
-
-
-ac_pwd=`pwd` && test -n "$ac_pwd" &&
-ac_ls_di=`ls -di .` &&
-ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
- as_fn_error $? "working directory cannot be determined"
-test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
- as_fn_error $? "pwd does not report name of working directory"
-
-
-# Find the source files, if location was not specified.
-if test -z "$srcdir"; then
- ac_srcdir_defaulted=yes
- # Try the directory containing this script, then the parent directory.
- ac_confdir=`$as_dirname -- "$as_myself" ||
-$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$as_myself" : 'X\(//\)[^/]' \| \
- X"$as_myself" : 'X\(//\)$' \| \
- X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$as_myself" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
- srcdir=$ac_confdir
- if test ! -r "$srcdir/$ac_unique_file"; then
- srcdir=..
- fi
-else
- ac_srcdir_defaulted=no
-fi
-if test ! -r "$srcdir/$ac_unique_file"; then
- test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
- as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
-fi
-ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
-ac_abs_confdir=`(
- cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
- pwd)`
-# When building in place, set srcdir=.
-if test "$ac_abs_confdir" = "$ac_pwd"; then
- srcdir=.
-fi
-# Remove unnecessary trailing slashes from srcdir.
-# Double slashes in file names in object file debugging info
-# mess up M-x gdb in Emacs.
-case $srcdir in
-*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
-esac
-for ac_var in $ac_precious_vars; do
- eval ac_env_${ac_var}_set=\${${ac_var}+set}
- eval ac_env_${ac_var}_value=\$${ac_var}
- eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
- eval ac_cv_env_${ac_var}_value=\$${ac_var}
-done
-
-#
-# Report the --help message.
-#
-if test "$ac_init_help" = "long"; then
- # Omit some internal or obsolete options to make the list less imposing.
- # This message is too long to be a string in the A/UX 3.1 sh.
- cat <<_ACEOF
-\`configure' configures binutils 2.43.1 to adapt to many kinds of systems.
-
-Usage: $0 [OPTION]... [VAR=VALUE]...
-
-To assign environment variables (e.g., CC, CFLAGS...), specify them as
-VAR=VALUE. See below for descriptions of some of the useful variables.
-
-Defaults for the options are specified in brackets.
-
-Configuration:
- -h, --help display this help and exit
- --help=short display options specific to this package
- --help=recursive display the short help of all the included packages
- -V, --version display version information and exit
- -q, --quiet, --silent do not print \`checking ...' messages
- --cache-file=FILE cache test results in FILE [disabled]
- -C, --config-cache alias for \`--cache-file=config.cache'
- -n, --no-create do not create output files
- --srcdir=DIR find the sources in DIR [configure dir or \`..']
-
-Installation directories:
- --prefix=PREFIX install architecture-independent files in PREFIX
- [$ac_default_prefix]
- --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
- [PREFIX]
-
-By default, \`make install' will install all the files in
-\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
-an installation prefix other than \`$ac_default_prefix' using \`--prefix',
-for instance \`--prefix=\$HOME'.
-
-For better control, use the options below.
-
-Fine tuning of the installation directories:
- --bindir=DIR user executables [EPREFIX/bin]
- --sbindir=DIR system admin executables [EPREFIX/sbin]
- --libexecdir=DIR program executables [EPREFIX/libexec]
- --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
- --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
- --localstatedir=DIR modifiable single-machine data [PREFIX/var]
- --libdir=DIR object code libraries [EPREFIX/lib]
- --includedir=DIR C header files [PREFIX/include]
- --oldincludedir=DIR C header files for non-gcc [/usr/include]
- --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
- --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
- --infodir=DIR info documentation [DATAROOTDIR/info]
- --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
- --mandir=DIR man documentation [DATAROOTDIR/man]
- --docdir=DIR documentation root [DATAROOTDIR/doc/binutils]
- --htmldir=DIR html documentation [DOCDIR]
- --dvidir=DIR dvi documentation [DOCDIR]
- --pdfdir=DIR pdf documentation [DOCDIR]
- --psdir=DIR ps documentation [DOCDIR]
-_ACEOF
-
- cat <<\_ACEOF
-
-Program names:
- --program-prefix=PREFIX prepend PREFIX to installed program names
- --program-suffix=SUFFIX append SUFFIX to installed program names
- --program-transform-name=PROGRAM run sed PROGRAM on installed program names
-
-System types:
- --build=BUILD configure for building on BUILD [guessed]
- --host=HOST cross-compile to build programs to run on HOST [BUILD]
- --target=TARGET configure for building compilers for TARGET [HOST]
-_ACEOF
-fi
-
-if test -n "$ac_init_help"; then
- case $ac_init_help in
- short | recursive ) echo "Configuration of binutils 2.43.1:";;
- esac
- cat <<\_ACEOF
-
-Optional Features:
- --disable-option-checking ignore unrecognized --enable/--with options
- --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
- --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
- --enable-silent-rules less verbose build output (undo: "make V=1")
- --disable-silent-rules verbose build output (undo: "make V=0")
- --enable-dependency-tracking
- do not reject slow dependency extractors
- --disable-dependency-tracking
- speeds up one-time build
- --enable-shared[=PKGS] build shared libraries [default=yes]
- --enable-static[=PKGS] build static libraries [default=yes]
- --enable-fast-install[=PKGS]
- optimize for fast installation [default=yes]
- --disable-libtool-lock avoid locking (might break parallel builds)
- --enable-plugins Enable support for plugins
- --disable-largefile omit support for large files
- --enable-checking enable run-time checks
- --enable-targets alternative target configurations
- --enable-deterministic-archives
- ar and ranlib default to -D behavior
- --disable-default-strings-all
- strings defaults to --data behavior
- --enable-f-for-ifunc-symbols
- Have nm use F and f for global and local ifunc
- symbols
- --enable-follow-debug-links
- Have readelf and objdump follow debug links by
- default
- --enable-colored-disassembly
- Have objdump use colors in its disassembly by
- default
- --enable-libctf Handle .ctf type-info sections [default=yes]
- --enable-werror treat compile warnings as errors
- --enable-build-warnings enable build-time compiler warnings
- --disable-nls do not use Native Language Support
- --disable-rpath do not hardcode runtime library paths
- --enable-maintainer-mode
- enable make rules and dependencies not useful (and
- sometimes confusing) to the casual installer
-
-Optional Packages:
- --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
- --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
- --with-pic try to use only PIC/non-PIC objects [default=use
- both]
- --with-gnu-ld assume the C compiler uses GNU ld [default=no]
- --with-debuginfod Enable debuginfo lookups with debuginfod
- (auto/yes/no)
- --with-gnu-ld assume the C compiler uses GNU ld default=no
- --with-libiconv-prefix[=DIR] search for libiconv in DIR/include and DIR/lib
- --without-libiconv-prefix don't search for libiconv in includedir and libdir
- --with-libiconv-type=TYPE type of library to search for (auto/static/shared)
- --with-libintl-prefix[=DIR] search for libintl in DIR/include and DIR/lib
- --without-libintl-prefix don't search for libintl in includedir and libdir
- --with-libintl-type=TYPE type of library to search for (auto/static/shared)
- --with-system-zlib use installed libz
- --with-zstd support zstd compressed debug sections
- (default=auto)
- --with-msgpack Enable msgpack support (auto/yes/no)
-
-Some influential environment variables:
- CC C compiler command
- CFLAGS C compiler flags
- LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
- nonstandard directory <lib dir>
- LIBS libraries to pass to the linker, e.g. -l<library>
- CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
- you have headers in a nonstandard directory <include dir>
- CPP C preprocessor
- PKG_CONFIG path to pkg-config utility
- PKG_CONFIG_PATH
- directories to add to pkg-config's search path
- PKG_CONFIG_LIBDIR
- path overriding pkg-config's built-in search path
- DEBUGINFOD_CFLAGS
- C compiler flags for DEBUGINFOD, overriding pkg-config
- DEBUGINFOD_LIBS
- linker flags for DEBUGINFOD, overriding pkg-config
- YACC The `Yet Another Compiler Compiler' implementation to use.
- Defaults to the first program found out of: `bison -y', `byacc',
- `yacc'.
- YFLAGS The list of arguments that will be passed by default to $YACC.
- This script will default YFLAGS to the empty string to avoid a
- default value of `-d' given by some make applications.
- ZSTD_CFLAGS C compiler flags for ZSTD, overriding pkg-config
- ZSTD_LIBS linker flags for ZSTD, overriding pkg-config
- MSGPACK_CFLAGS
- C compiler flags for MSGPACK, overriding pkg-config
- MSGPACK_LIBS
- linker flags for MSGPACK, overriding pkg-config
-
-Use these variables to override the choices made by `configure' or to help
-it to find libraries and programs with nonstandard names/locations.
-
-Report bugs to the package provider.
-_ACEOF
-ac_status=$?
-fi
-
-if test "$ac_init_help" = "recursive"; then
- # If there are subdirs, report their specific --help.
- for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
- test -d "$ac_dir" ||
- { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
- continue
- ac_builddir=.
-
-case "$ac_dir" in
-.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
-*)
- ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
- # A ".." for each directory in $ac_dir_suffix.
- ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
- case $ac_top_builddir_sub in
- "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
- *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
- esac ;;
-esac
-ac_abs_top_builddir=$ac_pwd
-ac_abs_builddir=$ac_pwd$ac_dir_suffix
-# for backward compatibility:
-ac_top_builddir=$ac_top_build_prefix
-
-case $srcdir in
- .) # We are building in place.
- ac_srcdir=.
- ac_top_srcdir=$ac_top_builddir_sub
- ac_abs_top_srcdir=$ac_pwd ;;
- [\\/]* | ?:[\\/]* ) # Absolute name.
- ac_srcdir=$srcdir$ac_dir_suffix;
- ac_top_srcdir=$srcdir
- ac_abs_top_srcdir=$srcdir ;;
- *) # Relative name.
- ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
- ac_top_srcdir=$ac_top_build_prefix$srcdir
- ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
-esac
-ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
-
- cd "$ac_dir" || { ac_status=$?; continue; }
- # Check for guested configure.
- if test -f "$ac_srcdir/configure.gnu"; then
- echo &&
- $SHELL "$ac_srcdir/configure.gnu" --help=recursive
- elif test -f "$ac_srcdir/configure"; then
- echo &&
- $SHELL "$ac_srcdir/configure" --help=recursive
- else
- $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
- fi || ac_status=$?
- cd "$ac_pwd" || { ac_status=$?; break; }
- done
-fi
-
-test -n "$ac_init_help" && exit $ac_status
-if $ac_init_version; then
- cat <<\_ACEOF
-binutils configure 2.43.1
-generated by GNU Autoconf 2.69
-
-Copyright (C) 2012 Free Software Foundation, Inc.
-This configure script is free software; the Free Software Foundation
-gives unlimited permission to copy, distribute and modify it.
-_ACEOF
- exit
-fi
-
-## ------------------------ ##
-## Autoconf initialization. ##
-## ------------------------ ##
-
-# ac_fn_c_try_compile LINENO
-# --------------------------
-# Try to compile conftest.$ac_ext, and return whether this succeeded.
-ac_fn_c_try_compile ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- rm -f conftest.$ac_objext
- if { { ac_try="$ac_compile"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_compile") 2>conftest.err
- ac_status=$?
- if test -s conftest.err; then
- grep -v '^ *+' conftest.err >conftest.er1
- cat conftest.er1 >&5
- mv -f conftest.er1 conftest.err
- fi
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && {
- test -z "$ac_c_werror_flag" ||
- test ! -s conftest.err
- } && test -s conftest.$ac_objext; then :
- ac_retval=0
-else
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
- ac_retval=1
-fi
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
- as_fn_set_status $ac_retval
-
-} # ac_fn_c_try_compile
-
-# ac_fn_c_try_cpp LINENO
-# ----------------------
-# Try to preprocess conftest.$ac_ext, and return whether this succeeded.
-ac_fn_c_try_cpp ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- if { { ac_try="$ac_cpp conftest.$ac_ext"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
- ac_status=$?
- if test -s conftest.err; then
- grep -v '^ *+' conftest.err >conftest.er1
- cat conftest.er1 >&5
- mv -f conftest.er1 conftest.err
- fi
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } > conftest.i && {
- test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
- test ! -s conftest.err
- }; then :
- ac_retval=0
-else
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
- ac_retval=1
-fi
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
- as_fn_set_status $ac_retval
-
-} # ac_fn_c_try_cpp
-
-# ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
-# -------------------------------------------------------
-# Tests whether HEADER exists, giving a warning if it cannot be compiled using
-# the include files in INCLUDES and setting the cache variable VAR
-# accordingly.
-ac_fn_c_check_header_mongrel ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- if eval \${$3+:} false; then :
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
-$as_echo_n "checking for $2... " >&6; }
-if eval \${$3+:} false; then :
- $as_echo_n "(cached) " >&6
-fi
-eval ac_res=\$$3
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
-else
- # Is the header compilable?
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
-$as_echo_n "checking $2 usability... " >&6; }
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$4
-#include <$2>
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_header_compiler=yes
-else
- ac_header_compiler=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
-$as_echo "$ac_header_compiler" >&6; }
-
-# Is the header present?
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
-$as_echo_n "checking $2 presence... " >&6; }
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <$2>
-_ACEOF
-if ac_fn_c_try_cpp "$LINENO"; then :
- ac_header_preproc=yes
-else
- ac_header_preproc=no
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
-$as_echo "$ac_header_preproc" >&6; }
-
-# So? What about this header?
-case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
- yes:no: )
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
-$as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
-$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
- ;;
- no:yes:* )
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
-$as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
-$as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
-$as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
-$as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
-$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
- ;;
-esac
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
-$as_echo_n "checking for $2... " >&6; }
-if eval \${$3+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- eval "$3=\$ac_header_compiler"
-fi
-eval ac_res=\$$3
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
-fi
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
-
-} # ac_fn_c_check_header_mongrel
-
-# ac_fn_c_try_run LINENO
-# ----------------------
-# Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
-# that executables *can* be run.
-ac_fn_c_try_run ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- if { { ac_try="$ac_link"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_link") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
- { { case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_try") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; }; then :
- ac_retval=0
-else
- $as_echo "$as_me: program exited with status $ac_status" >&5
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
- ac_retval=$ac_status
-fi
- rm -rf conftest.dSYM conftest_ipa8_conftest.oo
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
- as_fn_set_status $ac_retval
-
-} # ac_fn_c_try_run
-
-# ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
-# -------------------------------------------------------
-# Tests whether HEADER exists and can be compiled using the include files in
-# INCLUDES, setting the cache variable VAR accordingly.
-ac_fn_c_check_header_compile ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
-$as_echo_n "checking for $2... " >&6; }
-if eval \${$3+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$4
-#include <$2>
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- eval "$3=yes"
-else
- eval "$3=no"
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-eval ac_res=\$$3
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
-
-} # ac_fn_c_check_header_compile
-
-# ac_fn_c_try_link LINENO
-# -----------------------
-# Try to link conftest.$ac_ext, and return whether this succeeded.
-ac_fn_c_try_link ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- rm -f conftest.$ac_objext conftest$ac_exeext
- if { { ac_try="$ac_link"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_link") 2>conftest.err
- ac_status=$?
- if test -s conftest.err; then
- grep -v '^ *+' conftest.err >conftest.er1
- cat conftest.er1 >&5
- mv -f conftest.er1 conftest.err
- fi
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && {
- test -z "$ac_c_werror_flag" ||
- test ! -s conftest.err
- } && test -s conftest$ac_exeext && {
- test "$cross_compiling" = yes ||
- test -x conftest$ac_exeext
- }; then :
- ac_retval=0
-else
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
- ac_retval=1
-fi
- # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
- # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
- # interfere with the next link command; also delete a directory that is
- # left behind by Apple's compiler. We do this before executing the actions.
- rm -rf conftest.dSYM conftest_ipa8_conftest.oo
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
- as_fn_set_status $ac_retval
-
-} # ac_fn_c_try_link
-
-# ac_fn_c_check_func LINENO FUNC VAR
-# ----------------------------------
-# Tests whether FUNC exists, setting the cache variable VAR accordingly
-ac_fn_c_check_func ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
-$as_echo_n "checking for $2... " >&6; }
-if eval \${$3+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-/* Define $2 to an innocuous variant, in case <limits.h> declares $2.
- For example, HP-UX 11i <limits.h> declares gettimeofday. */
-#define $2 innocuous_$2
-
-/* System header to define __stub macros and hopefully few prototypes,
- which can conflict with char $2 (); below.
- Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
- <limits.h> exists even on freestanding compilers. */
-
-#ifdef __STDC__
-# include <limits.h>
-#else
-# include <assert.h>
-#endif
-
-#undef $2
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char $2 ();
-/* The GNU C library defines this for functions which it implements
- to always fail with ENOSYS. Some functions are actually named
- something starting with __ and the normal name is an alias. */
-#if defined __stub_$2 || defined __stub___$2
-choke me
-#endif
-
-int
-main ()
-{
-return $2 ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- eval "$3=yes"
-else
- eval "$3=no"
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-fi
-eval ac_res=\$$3
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
-
-} # ac_fn_c_check_func
-
-# ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
-# ----------------------------------------------------
-# Tries to find if the field MEMBER exists in type AGGR, after including
-# INCLUDES, setting cache variable VAR accordingly.
-ac_fn_c_check_member ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
-$as_echo_n "checking for $2.$3... " >&6; }
-if eval \${$4+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$5
-int
-main ()
-{
-static $2 ac_aggr;
-if (ac_aggr.$3)
-return 0;
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- eval "$4=yes"
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$5
-int
-main ()
-{
-static $2 ac_aggr;
-if (sizeof ac_aggr.$3)
-return 0;
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- eval "$4=yes"
-else
- eval "$4=no"
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-eval ac_res=\$$4
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
-
-} # ac_fn_c_check_member
-
-# ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES
-# ---------------------------------------------
-# Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR
-# accordingly.
-ac_fn_c_check_decl ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- as_decl_name=`echo $2|sed 's/ *(.*//'`
- as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'`
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5
-$as_echo_n "checking whether $as_decl_name is declared... " >&6; }
-if eval \${$3+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$4
-int
-main ()
-{
-#ifndef $as_decl_name
-#ifdef __cplusplus
- (void) $as_decl_use;
-#else
- (void) $as_decl_name;
-#endif
-#endif
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- eval "$3=yes"
-else
- eval "$3=no"
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-eval ac_res=\$$3
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
-
-} # ac_fn_c_check_decl
-cat >config.log <<_ACEOF
-This file contains any messages produced by compilers while
-running configure, to aid debugging if configure makes a mistake.
-
-It was created by binutils $as_me 2.43.1, which was
-generated by GNU Autoconf 2.69. Invocation command line was
-
- $ $0 $@
-
-_ACEOF
-exec 5>>config.log
-{
-cat <<_ASUNAME
-## --------- ##
-## Platform. ##
-## --------- ##
-
-hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
-uname -m = `(uname -m) 2>/dev/null || echo unknown`
-uname -r = `(uname -r) 2>/dev/null || echo unknown`
-uname -s = `(uname -s) 2>/dev/null || echo unknown`
-uname -v = `(uname -v) 2>/dev/null || echo unknown`
-
-/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
-/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
-
-/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
-/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
-/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
-/usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
-/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
-/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
-/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
-
-_ASUNAME
-
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- $as_echo "PATH: $as_dir"
- done
-IFS=$as_save_IFS
-
-} >&5
-
-cat >&5 <<_ACEOF
-
-
-## ----------- ##
-## Core tests. ##
-## ----------- ##
-
-_ACEOF
-
-
-# Keep a trace of the command line.
-# Strip out --no-create and --no-recursion so they do not pile up.
-# Strip out --silent because we don't want to record it for future runs.
-# Also quote any args containing shell meta-characters.
-# Make two passes to allow for proper duplicate-argument suppression.
-ac_configure_args=
-ac_configure_args0=
-ac_configure_args1=
-ac_must_keep_next=false
-for ac_pass in 1 2
-do
- for ac_arg
- do
- case $ac_arg in
- -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
- -q | -quiet | --quiet | --quie | --qui | --qu | --q \
- | -silent | --silent | --silen | --sile | --sil)
- continue ;;
- *\'*)
- ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
- esac
- case $ac_pass in
- 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
- 2)
- as_fn_append ac_configure_args1 " '$ac_arg'"
- if test $ac_must_keep_next = true; then
- ac_must_keep_next=false # Got value, back to normal.
- else
- case $ac_arg in
- *=* | --config-cache | -C | -disable-* | --disable-* \
- | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
- | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
- | -with-* | --with-* | -without-* | --without-* | --x)
- case "$ac_configure_args0 " in
- "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
- esac
- ;;
- -* ) ac_must_keep_next=true ;;
- esac
- fi
- as_fn_append ac_configure_args " '$ac_arg'"
- ;;
- esac
- done
-done
-{ ac_configure_args0=; unset ac_configure_args0;}
-{ ac_configure_args1=; unset ac_configure_args1;}
-
-# When interrupted or exit'd, cleanup temporary files, and complete
-# config.log. We remove comments because anyway the quotes in there
-# would cause problems or look ugly.
-# WARNING: Use '\'' to represent an apostrophe within the trap.
-# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
-trap 'exit_status=$?
- # Save into config.log some information that might help in debugging.
- {
- echo
-
- $as_echo "## ---------------- ##
-## Cache variables. ##
-## ---------------- ##"
- echo
- # The following way of writing the cache mishandles newlines in values,
-(
- for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
- eval ac_val=\$$ac_var
- case $ac_val in #(
- *${as_nl}*)
- case $ac_var in #(
- *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
-$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
- esac
- case $ac_var in #(
- _ | IFS | as_nl) ;; #(
- BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
- *) { eval $ac_var=; unset $ac_var;} ;;
- esac ;;
- esac
- done
- (set) 2>&1 |
- case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
- *${as_nl}ac_space=\ *)
- sed -n \
- "s/'\''/'\''\\\\'\'''\''/g;
- s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
- ;; #(
- *)
- sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
- ;;
- esac |
- sort
-)
- echo
-
- $as_echo "## ----------------- ##
-## Output variables. ##
-## ----------------- ##"
- echo
- for ac_var in $ac_subst_vars
- do
- eval ac_val=\$$ac_var
- case $ac_val in
- *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
- esac
- $as_echo "$ac_var='\''$ac_val'\''"
- done | sort
- echo
-
- if test -n "$ac_subst_files"; then
- $as_echo "## ------------------- ##
-## File substitutions. ##
-## ------------------- ##"
- echo
- for ac_var in $ac_subst_files
- do
- eval ac_val=\$$ac_var
- case $ac_val in
- *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
- esac
- $as_echo "$ac_var='\''$ac_val'\''"
- done | sort
- echo
- fi
-
- if test -s confdefs.h; then
- $as_echo "## ----------- ##
-## confdefs.h. ##
-## ----------- ##"
- echo
- cat confdefs.h
- echo
- fi
- test "$ac_signal" != 0 &&
- $as_echo "$as_me: caught signal $ac_signal"
- $as_echo "$as_me: exit $exit_status"
- } >&5
- rm -f core *.core core.conftest.* &&
- rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
- exit $exit_status
-' 0
-for ac_signal in 1 2 13 15; do
- trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
-done
-ac_signal=0
-
-# confdefs.h avoids OS command line length limits that DEFS can exceed.
-rm -f -r conftest* confdefs.h
-
-$as_echo "/* confdefs.h */" > confdefs.h
-
-# Predefined preprocessor variables.
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_NAME "$PACKAGE_NAME"
-_ACEOF
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
-_ACEOF
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_VERSION "$PACKAGE_VERSION"
-_ACEOF
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_STRING "$PACKAGE_STRING"
-_ACEOF
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
-_ACEOF
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_URL "$PACKAGE_URL"
-_ACEOF
-
-
-# Let the site file select an alternate cache file if it wants to.
-# Prefer an explicitly selected file to automatically selected ones.
-ac_site_file1=NONE
-ac_site_file2=NONE
-if test -n "$CONFIG_SITE"; then
- # We do not want a PATH search for config.site.
- case $CONFIG_SITE in #((
- -*) ac_site_file1=./$CONFIG_SITE;;
- */*) ac_site_file1=$CONFIG_SITE;;
- *) ac_site_file1=./$CONFIG_SITE;;
- esac
-elif test "x$prefix" != xNONE; then
- ac_site_file1=$prefix/share/config.site
- ac_site_file2=$prefix/etc/config.site
-else
- ac_site_file1=$ac_default_prefix/share/config.site
- ac_site_file2=$ac_default_prefix/etc/config.site
-fi
-for ac_site_file in "$ac_site_file1" "$ac_site_file2"
-do
- test "x$ac_site_file" = xNONE && continue
- if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
-$as_echo "$as_me: loading site script $ac_site_file" >&6;}
- sed 's/^/| /' "$ac_site_file" >&5
- . "$ac_site_file" \
- || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "failed to load site script $ac_site_file
-See \`config.log' for more details" "$LINENO" 5; }
- fi
-done
-
-if test -r "$cache_file"; then
- # Some versions of bash will fail to source /dev/null (special files
- # actually), so we avoid doing that. DJGPP emulates it as a regular file.
- if test /dev/null != "$cache_file" && test -f "$cache_file"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
-$as_echo "$as_me: loading cache $cache_file" >&6;}
- case $cache_file in
- [\\/]* | ?:[\\/]* ) . "$cache_file";;
- *) . "./$cache_file";;
- esac
- fi
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
-$as_echo "$as_me: creating cache $cache_file" >&6;}
- >$cache_file
-fi
-
-gt_needs="$gt_needs "
-as_fn_append ac_header_list " stdlib.h"
-as_fn_append ac_header_list " unistd.h"
-as_fn_append ac_header_list " sys/param.h"
-# Check that the precious variables saved in the cache have kept the same
-# value.
-ac_cache_corrupted=false
-for ac_var in $ac_precious_vars; do
- eval ac_old_set=\$ac_cv_env_${ac_var}_set
- eval ac_new_set=\$ac_env_${ac_var}_set
- eval ac_old_val=\$ac_cv_env_${ac_var}_value
- eval ac_new_val=\$ac_env_${ac_var}_value
- case $ac_old_set,$ac_new_set in
- set,)
- { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
-$as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
- ac_cache_corrupted=: ;;
- ,set)
- { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
-$as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
- ac_cache_corrupted=: ;;
- ,);;
- *)
- if test "x$ac_old_val" != "x$ac_new_val"; then
- # differences in whitespace do not lead to failure.
- ac_old_val_w=`echo x $ac_old_val`
- ac_new_val_w=`echo x $ac_new_val`
- if test "$ac_old_val_w" != "$ac_new_val_w"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
-$as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
- ac_cache_corrupted=:
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
-$as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
- eval $ac_var=\$ac_old_val
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
-$as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
-$as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
- fi;;
- esac
- # Pass precious variables to config.status.
- if test "$ac_new_set" = set; then
- case $ac_new_val in
- *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
- *) ac_arg=$ac_var=$ac_new_val ;;
- esac
- case " $ac_configure_args " in
- *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
- *) as_fn_append ac_configure_args " '$ac_arg'" ;;
- esac
- fi
-done
-if $ac_cache_corrupted; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
-$as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
- as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
-fi
-## -------------------- ##
-## Main body of script. ##
-## -------------------- ##
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-
-
-
-
-
-
-ac_aux_dir=
-for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
- if test -f "$ac_dir/install-sh"; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install-sh -c"
- break
- elif test -f "$ac_dir/install.sh"; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install.sh -c"
- break
- elif test -f "$ac_dir/shtool"; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/shtool install -c"
- break
- fi
-done
-if test -z "$ac_aux_dir"; then
- as_fn_error $? "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5
-fi
-
-# These three variables are undocumented and unsupported,
-# and are intended to be withdrawn in a future Autoconf release.
-# They can cause serious problems if a builder's source tree is in a directory
-# whose full name contains unusual characters.
-ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
-ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
-ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
-
-
-# Make sure we can run config.sub.
-$SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
- as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
-$as_echo_n "checking build system type... " >&6; }
-if ${ac_cv_build+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_build_alias=$build_alias
-test "x$ac_build_alias" = x &&
- ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
-test "x$ac_build_alias" = x &&
- as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
-ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
- as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
-$as_echo "$ac_cv_build" >&6; }
-case $ac_cv_build in
-*-*-*) ;;
-*) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
-esac
-build=$ac_cv_build
-ac_save_IFS=$IFS; IFS='-'
-set x $ac_cv_build
-shift
-build_cpu=$1
-build_vendor=$2
-shift; shift
-# Remember, the first character of IFS is used to create $*,
-# except with old shells:
-build_os=$*
-IFS=$ac_save_IFS
-case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
-$as_echo_n "checking host system type... " >&6; }
-if ${ac_cv_host+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test "x$host_alias" = x; then
- ac_cv_host=$ac_cv_build
-else
- ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
- as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
-$as_echo "$ac_cv_host" >&6; }
-case $ac_cv_host in
-*-*-*) ;;
-*) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
-esac
-host=$ac_cv_host
-ac_save_IFS=$IFS; IFS='-'
-set x $ac_cv_host
-shift
-host_cpu=$1
-host_vendor=$2
-shift; shift
-# Remember, the first character of IFS is used to create $*,
-# except with old shells:
-host_os=$*
-IFS=$ac_save_IFS
-case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking target system type" >&5
-$as_echo_n "checking target system type... " >&6; }
-if ${ac_cv_target+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test "x$target_alias" = x; then
- ac_cv_target=$ac_cv_host
-else
- ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` ||
- as_fn_error $? "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5
-$as_echo "$ac_cv_target" >&6; }
-case $ac_cv_target in
-*-*-*) ;;
-*) as_fn_error $? "invalid value of canonical target" "$LINENO" 5;;
-esac
-target=$ac_cv_target
-ac_save_IFS=$IFS; IFS='-'
-set x $ac_cv_target
-shift
-target_cpu=$1
-target_vendor=$2
-shift; shift
-# Remember, the first character of IFS is used to create $*,
-# except with old shells:
-target_os=$*
-IFS=$ac_save_IFS
-case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac
-
-
-# The aliases save the names the user supplied, while $host etc.
-# will get canonicalized.
-test -n "$target_alias" &&
- test "$program_prefix$program_suffix$program_transform_name" = \
- NONENONEs,x,x, &&
- program_prefix=${target_alias}-
-
-am__api_version='1.15'
-
-# Find a good install program. We prefer a C program (faster),
-# so one script is as good as another. But avoid the broken or
-# incompatible versions:
-# SysV /etc/install, /usr/sbin/install
-# SunOS /usr/etc/install
-# IRIX /sbin/install
-# AIX /bin/install
-# AmigaOS /C/install, which installs bootblocks on floppy discs
-# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
-# AFS /usr/afsws/bin/install, which mishandles nonexistent args
-# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
-# OS/2's system install, which has a completely different semantic
-# ./install, which can be erroneously created by make from ./install.sh.
-# Reject install programs that cannot install multiple files.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
-$as_echo_n "checking for a BSD-compatible install... " >&6; }
-if test -z "$INSTALL"; then
-if ${ac_cv_path_install+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- # Account for people who put trailing slashes in PATH elements.
-case $as_dir/ in #((
- ./ | .// | /[cC]/* | \
- /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
- ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
- /usr/ucb/* ) ;;
- *)
- # OSF1 and SCO ODT 3.0 have their own names for install.
- # Don't use installbsd from OSF since it installs stuff as root
- # by default.
- for ac_prog in ginstall scoinst install; do
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
- if test $ac_prog = install &&
- grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
- # AIX install. It has an incompatible calling convention.
- :
- elif test $ac_prog = install &&
- grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
- # program-specific install script used by HP pwplus--don't use.
- :
- else
- rm -rf conftest.one conftest.two conftest.dir
- echo one > conftest.one
- echo two > conftest.two
- mkdir conftest.dir
- if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
- test -s conftest.one && test -s conftest.two &&
- test -s conftest.dir/conftest.one &&
- test -s conftest.dir/conftest.two
- then
- ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
- break 3
- fi
- fi
- fi
- done
- done
- ;;
-esac
-
- done
-IFS=$as_save_IFS
-
-rm -rf conftest.one conftest.two conftest.dir
-
-fi
- if test "${ac_cv_path_install+set}" = set; then
- INSTALL=$ac_cv_path_install
- else
- # As a last resort, use the slow shell script. Don't cache a
- # value for INSTALL within a source directory, because that will
- # break other packages using the cache if that directory is
- # removed, or if the value is a relative name.
- INSTALL=$ac_install_sh
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
-$as_echo "$INSTALL" >&6; }
-
-# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
-# It thinks the first close brace ends the variable substitution.
-test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
-
-test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
-
-test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5
-$as_echo_n "checking whether build environment is sane... " >&6; }
-# Reject unsafe characters in $srcdir or the absolute working directory
-# name. Accept space and tab only in the latter.
-am_lf='
-'
-case `pwd` in
- *[\\\"\#\$\&\'\`$am_lf]*)
- as_fn_error $? "unsafe absolute working directory name" "$LINENO" 5;;
-esac
-case $srcdir in
- *[\\\"\#\$\&\'\`$am_lf\ \ ]*)
- as_fn_error $? "unsafe srcdir value: '$srcdir'" "$LINENO" 5;;
-esac
-
-# Do 'set' in a subshell so we don't clobber the current shell's
-# arguments. Must try -L first in case configure is actually a
-# symlink; some systems play weird games with the mod time of symlinks
-# (eg FreeBSD returns the mod time of the symlink's containing
-# directory).
-if (
- am_has_slept=no
- for am_try in 1 2; do
- echo "timestamp, slept: $am_has_slept" > conftest.file
- set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
- if test "$*" = "X"; then
- # -L didn't work.
- set X `ls -t "$srcdir/configure" conftest.file`
- fi
- if test "$*" != "X $srcdir/configure conftest.file" \
- && test "$*" != "X conftest.file $srcdir/configure"; then
-
- # If neither matched, then we have a broken ls. This can happen
- # if, for instance, CONFIG_SHELL is bash and it inherits a
- # broken ls alias from the environment. This has actually
- # happened. Such a system could not be considered "sane".
- as_fn_error $? "ls -t appears to fail. Make sure there is not a broken
- alias in your environment" "$LINENO" 5
- fi
- if test "$2" = conftest.file || test $am_try -eq 2; then
- break
- fi
- # Just in case.
- sleep 1
- am_has_slept=yes
- done
- test "$2" = conftest.file
- )
-then
- # Ok.
- :
-else
- as_fn_error $? "newly created file is older than distributed files!
-Check your system clock" "$LINENO" 5
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-# If we didn't sleep, we still need to ensure time stamps of config.status and
-# generated files are strictly newer.
-am_sleep_pid=
-if grep 'slept: no' conftest.file >/dev/null 2>&1; then
- ( sleep 1 ) &
- am_sleep_pid=$!
-fi
-
-rm -f conftest.file
-
-test "$program_prefix" != NONE &&
- program_transform_name="s&^&$program_prefix&;$program_transform_name"
-# Use a double $ so make ignores it.
-test "$program_suffix" != NONE &&
- program_transform_name="s&\$&$program_suffix&;$program_transform_name"
-# Double any \ or $.
-# By default was `s,x,x', remove it if useless.
-ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
-program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
-
-# Expand $ac_aux_dir to an absolute path.
-am_aux_dir=`cd "$ac_aux_dir" && pwd`
-
-if test x"${MISSING+set}" != xset; then
- case $am_aux_dir in
- *\ * | *\ *)
- MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
- *)
- MISSING="\${SHELL} $am_aux_dir/missing" ;;
- esac
-fi
-# Use eval to expand $SHELL
-if eval "$MISSING --is-lightweight"; then
- am_missing_run="$MISSING "
-else
- am_missing_run=
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: 'missing' script is too old or missing" >&5
-$as_echo "$as_me: WARNING: 'missing' script is too old or missing" >&2;}
-fi
-
-if test x"${install_sh+set}" != xset; then
- case $am_aux_dir in
- *\ * | *\ *)
- install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
- *)
- install_sh="\${SHELL} $am_aux_dir/install-sh"
- esac
-fi
-
-# Installed binaries are usually stripped using 'strip' when the user
-# run "make install-strip". However 'strip' might not be the right
-# tool to use in cross-compilation environments, therefore Automake
-# will honor the 'STRIP' environment variable to overrule this program.
-if test "$cross_compiling" != no; then
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
-set dummy ${ac_tool_prefix}strip; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_STRIP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$STRIP"; then
- ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_STRIP="${ac_tool_prefix}strip"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-STRIP=$ac_cv_prog_STRIP
-if test -n "$STRIP"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
-$as_echo "$STRIP" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_STRIP"; then
- ac_ct_STRIP=$STRIP
- # Extract the first word of "strip", so it can be a program name with args.
-set dummy strip; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_STRIP"; then
- ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_STRIP="strip"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
-if test -n "$ac_ct_STRIP"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
-$as_echo "$ac_ct_STRIP" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_STRIP" = x; then
- STRIP=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- STRIP=$ac_ct_STRIP
- fi
-else
- STRIP="$ac_cv_prog_STRIP"
-fi
-
-fi
-INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5
-$as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
-if test -z "$MKDIR_P"; then
- if ${ac_cv_path_mkdir+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_prog in mkdir gmkdir; do
- for ac_exec_ext in '' $ac_executable_extensions; do
- as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext" || continue
- case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
- 'mkdir (GNU coreutils) '* | \
- 'mkdir (coreutils) '* | \
- 'mkdir (fileutils) '4.1*)
- ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
- break 3;;
- esac
- done
- done
- done
-IFS=$as_save_IFS
-
-fi
-
- test -d ./--version && rmdir ./--version
- if test "${ac_cv_path_mkdir+set}" = set; then
- MKDIR_P="$ac_cv_path_mkdir -p"
- else
- # As a last resort, use the slow shell script. Don't cache a
- # value for MKDIR_P within a source directory, because that will
- # break other packages using the cache if that directory is
- # removed, or if the value is a relative name.
- MKDIR_P="$ac_install_sh -d"
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
-$as_echo "$MKDIR_P" >&6; }
-
-for ac_prog in gawk mawk nawk awk
-do
- # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_AWK+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$AWK"; then
- ac_cv_prog_AWK="$AWK" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_AWK="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-AWK=$ac_cv_prog_AWK
-if test -n "$AWK"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
-$as_echo "$AWK" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$AWK" && break
-done
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
-$as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
-set x ${MAKE-make}
-ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
-if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat >conftest.make <<\_ACEOF
-SHELL = /bin/sh
-all:
- @echo '@@@%%%=$(MAKE)=@@@%%%'
-_ACEOF
-# GNU make sometimes prints "make[1]: Entering ...", which would confuse us.
-case `${MAKE-make} -f conftest.make 2>/dev/null` in
- *@@@%%%=?*=@@@%%%*)
- eval ac_cv_prog_make_${ac_make}_set=yes;;
- *)
- eval ac_cv_prog_make_${ac_make}_set=no;;
-esac
-rm -f conftest.make
-fi
-if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- SET_MAKE=
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- SET_MAKE="MAKE=${MAKE-make}"
-fi
-
-rm -rf .tst 2>/dev/null
-mkdir .tst 2>/dev/null
-if test -d .tst; then
- am__leading_dot=.
-else
- am__leading_dot=_
-fi
-rmdir .tst 2>/dev/null
-
-# Check whether --enable-silent-rules was given.
-if test "${enable_silent_rules+set}" = set; then :
- enableval=$enable_silent_rules;
-fi
-
-case $enable_silent_rules in # (((
- yes) AM_DEFAULT_VERBOSITY=0;;
- no) AM_DEFAULT_VERBOSITY=1;;
- *) AM_DEFAULT_VERBOSITY=1;;
-esac
-am_make=${MAKE-make}
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5
-$as_echo_n "checking whether $am_make supports nested variables... " >&6; }
-if ${am_cv_make_support_nested_variables+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if $as_echo 'TRUE=$(BAR$(V))
-BAR0=false
-BAR1=true
-V=1
-am__doit:
- @$(TRUE)
-.PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then
- am_cv_make_support_nested_variables=yes
-else
- am_cv_make_support_nested_variables=no
-fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5
-$as_echo "$am_cv_make_support_nested_variables" >&6; }
-if test $am_cv_make_support_nested_variables = yes; then
- AM_V='$(V)'
- AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
-else
- AM_V=$AM_DEFAULT_VERBOSITY
- AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY
-fi
-AM_BACKSLASH='\'
-
-if test "`cd $srcdir && pwd`" != "`pwd`"; then
- # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
- # is not polluted with repeated "-I."
- am__isrc=' -I$(srcdir)'
- # test to see if srcdir already configured
- if test -f $srcdir/config.status; then
- as_fn_error $? "source directory already configured; run \"make distclean\" there first" "$LINENO" 5
- fi
-fi
-
-# test whether we have cygpath
-if test -z "$CYGPATH_W"; then
- if (cygpath --version) >/dev/null 2>/dev/null; then
- CYGPATH_W='cygpath -w'
- else
- CYGPATH_W=echo
- fi
-fi
-
-
-# Define the identity of the package.
- PACKAGE='binutils'
- VERSION='2.43.1'
-
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE "$PACKAGE"
-_ACEOF
-
-
-cat >>confdefs.h <<_ACEOF
-#define VERSION "$VERSION"
-_ACEOF
-
-# Some tools Automake needs.
-
-ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"}
-
-
-AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
-
-
-AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"}
-
-
-AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
-
-
-MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
-
-# For better backward compatibility. To be removed once Automake 1.9.x
-# dies out for good. For more background, see:
-# <http://lists.gnu.org/archive/html/automake/2012-07/msg00001.html>
-# <http://lists.gnu.org/archive/html/automake/2012-07/msg00014.html>
-mkdir_p='$(MKDIR_P)'
-
-# We need awk for the "check" target (and possibly the TAP driver). The
-# system "awk" is bad on some platforms.
-# Always define AMTAR for backward compatibility. Yes, it's still used
-# in the wild :-( We should find a proper way to deprecate it ...
-AMTAR='$${TAR-tar}'
-
-
-# We'll loop over all known methods to create a tar archive until one works.
-_am_tools='gnutar pax cpio none'
-
-am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -'
-
-
-
-
-
-
-# POSIX will say in a future version that running "rm -f" with no argument
-# is OK; and we want to be able to make that assumption in our Makefile
-# recipes. So use an aggressive probe to check that the usage we want is
-# actually supported "in the wild" to an acceptable degree.
-# See automake bug#10828.
-# To make any issue more visible, cause the running configure to be aborted
-# by default if the 'rm' program in use doesn't match our expectations; the
-# user can still override this though.
-if rm -f && rm -fr && rm -rf; then : OK; else
- cat >&2 <<'END'
-Oops!
-
-Your 'rm' program seems unable to run without file operands specified
-on the command line, even when the '-f' option is present. This is contrary
-to the behaviour of most rm programs out there, and not conforming with
-the upcoming POSIX standard: <http://austingroupbugs.net/view.php?id=542>
-
-Please tell bug-automake@gnu.org about your system, including the value
-of your $PATH and any error possibly output before this message. This
-can help us improve future automake versions.
-
-END
- if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then
- echo 'Configuration will proceed anyway, since you have set the' >&2
- echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2
- echo >&2
- else
- cat >&2 <<'END'
-Aborting the configuration process, to ensure you take notice of the issue.
-
-You can download and install GNU coreutils to get an 'rm' implementation
-that behaves properly: <http://www.gnu.org/software/coreutils/>.
-
-If you want to complete the configuration process using your problematic
-'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM
-to "yes", and re-run configure.
-
-END
- as_fn_error $? "Your 'rm' program is bad, sorry." "$LINENO" 5
- fi
-fi
-
-# Check whether --enable-silent-rules was given.
-if test "${enable_silent_rules+set}" = set; then :
- enableval=$enable_silent_rules;
-fi
-
-case $enable_silent_rules in # (((
- yes) AM_DEFAULT_VERBOSITY=0;;
- no) AM_DEFAULT_VERBOSITY=1;;
- *) AM_DEFAULT_VERBOSITY=0;;
-esac
-am_make=${MAKE-make}
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5
-$as_echo_n "checking whether $am_make supports nested variables... " >&6; }
-if ${am_cv_make_support_nested_variables+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if $as_echo 'TRUE=$(BAR$(V))
-BAR0=false
-BAR1=true
-V=1
-am__doit:
- @$(TRUE)
-.PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then
- am_cv_make_support_nested_variables=yes
-else
- am_cv_make_support_nested_variables=no
-fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5
-$as_echo "$am_cv_make_support_nested_variables" >&6; }
-if test $am_cv_make_support_nested_variables = yes; then
- AM_V='$(V)'
- AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
-else
- AM_V=$AM_DEFAULT_VERBOSITY
- AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY
-fi
-AM_BACKSLASH='\'
-
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
-set dummy ${ac_tool_prefix}gcc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_CC="${ac_tool_prefix}gcc"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
-$as_echo "$CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_CC"; then
- ac_ct_CC=$CC
- # Extract the first word of "gcc", so it can be a program name with args.
-set dummy gcc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_CC"; then
- ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_CC="gcc"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_CC=$ac_cv_prog_ac_ct_CC
-if test -n "$ac_ct_CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
-$as_echo "$ac_ct_CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_CC" = x; then
- CC=""
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- CC=$ac_ct_CC
- fi
-else
- CC="$ac_cv_prog_CC"
-fi
-
-if test -z "$CC"; then
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
-set dummy ${ac_tool_prefix}cc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_CC="${ac_tool_prefix}cc"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
-$as_echo "$CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
-fi
-if test -z "$CC"; then
- # Extract the first word of "cc", so it can be a program name with args.
-set dummy cc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
- ac_prog_rejected=no
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
- ac_prog_rejected=yes
- continue
- fi
- ac_cv_prog_CC="cc"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-if test $ac_prog_rejected = yes; then
- # We found a bogon in the path, so make sure we never use it.
- set dummy $ac_cv_prog_CC
- shift
- if test $# != 0; then
- # We chose a different compiler from the bogus one.
- # However, it has the same basename, so the bogon will be chosen
- # first if we set CC to just the basename; use the full file name.
- shift
- ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
- fi
-fi
-fi
-fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
-$as_echo "$CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$CC"; then
- if test -n "$ac_tool_prefix"; then
- for ac_prog in cl.exe
- do
- # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
-set dummy $ac_tool_prefix$ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
-$as_echo "$CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$CC" && break
- done
-fi
-if test -z "$CC"; then
- ac_ct_CC=$CC
- for ac_prog in cl.exe
-do
- # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_CC"; then
- ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_CC="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_CC=$ac_cv_prog_ac_ct_CC
-if test -n "$ac_ct_CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
-$as_echo "$ac_ct_CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$ac_ct_CC" && break
-done
-
- if test "x$ac_ct_CC" = x; then
- CC=""
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- CC=$ac_ct_CC
- fi
-fi
-
-fi
-
-
-test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "no acceptable C compiler found in \$PATH
-See \`config.log' for more details" "$LINENO" 5; }
-
-# Provide some information about the compiler.
-$as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
-set X $ac_compile
-ac_compiler=$2
-for ac_option in --version -v -V -qversion; do
- { { ac_try="$ac_compiler $ac_option >&5"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_compiler $ac_option >&5") 2>conftest.err
- ac_status=$?
- if test -s conftest.err; then
- sed '10a\
-... rest of stderr output deleted ...
- 10q' conftest.err >conftest.er1
- cat conftest.er1 >&5
- fi
- rm -f conftest.er1 conftest.err
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }
-done
-
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-ac_clean_files_save=$ac_clean_files
-ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
-# Try to create an executable without -o first, disregard a.out.
-# It will help us diagnose broken compilers, and finding out an intuition
-# of exeext.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
-$as_echo_n "checking whether the C compiler works... " >&6; }
-ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
-
-# The possible output files:
-ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
-
-ac_rmfiles=
-for ac_file in $ac_files
-do
- case $ac_file in
- *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
- * ) ac_rmfiles="$ac_rmfiles $ac_file";;
- esac
-done
-rm -f $ac_rmfiles
-
-if { { ac_try="$ac_link_default"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_link_default") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then :
- # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
-# So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
-# in a Makefile. We should not override ac_cv_exeext if it was cached,
-# so that the user can short-circuit this test for compilers unknown to
-# Autoconf.
-for ac_file in $ac_files ''
-do
- test -f "$ac_file" || continue
- case $ac_file in
- *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
- ;;
- [ab].out )
- # We found the default executable, but exeext='' is most
- # certainly right.
- break;;
- *.* )
- if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
- then :; else
- ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
- fi
- # We set ac_cv_exeext here because the later test for it is not
- # safe: cross compilers may not add the suffix if given an `-o'
- # argument, so we may need to know it at that point already.
- # Even if this section looks crufty: it has the advantage of
- # actually working.
- break;;
- * )
- break;;
- esac
-done
-test "$ac_cv_exeext" = no && ac_cv_exeext=
-
-else
- ac_file=''
-fi
-if test -z "$ac_file"; then :
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-$as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error 77 "C compiler cannot create executables
-See \`config.log' for more details" "$LINENO" 5; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
-$as_echo_n "checking for C compiler default output file name... " >&6; }
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
-$as_echo "$ac_file" >&6; }
-ac_exeext=$ac_cv_exeext
-
-rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
-ac_clean_files=$ac_clean_files_save
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
-$as_echo_n "checking for suffix of executables... " >&6; }
-if { { ac_try="$ac_link"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_link") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then :
- # If both `conftest.exe' and `conftest' are `present' (well, observable)
-# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
-# work properly (i.e., refer to `conftest.exe'), while it won't with
-# `rm'.
-for ac_file in conftest.exe conftest conftest.*; do
- test -f "$ac_file" || continue
- case $ac_file in
- *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
- *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
- break;;
- * ) break;;
- esac
-done
-else
- { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "cannot compute suffix of executables: cannot compile and link
-See \`config.log' for more details" "$LINENO" 5; }
-fi
-rm -f conftest conftest$ac_cv_exeext
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
-$as_echo "$ac_cv_exeext" >&6; }
-
-rm -f conftest.$ac_ext
-EXEEXT=$ac_cv_exeext
-ac_exeext=$EXEEXT
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <stdio.h>
-int
-main ()
-{
-FILE *f = fopen ("conftest.out", "w");
- return ferror (f) || fclose (f) != 0;
-
- ;
- return 0;
-}
-_ACEOF
-ac_clean_files="$ac_clean_files conftest.out"
-# Check that the compiler produces executables we can run. If not, either
-# the compiler is broken, or we cross compile.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
-$as_echo_n "checking whether we are cross compiling... " >&6; }
-if test "$cross_compiling" != yes; then
- { { ac_try="$ac_link"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_link") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }
- if { ac_try='./conftest$ac_cv_exeext'
- { { case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_try") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; }; then
- cross_compiling=no
- else
- if test "$cross_compiling" = maybe; then
- cross_compiling=yes
- else
- { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "cannot run C compiled programs.
-If you meant to cross compile, use \`--host'.
-See \`config.log' for more details" "$LINENO" 5; }
- fi
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
-$as_echo "$cross_compiling" >&6; }
-
-rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
-ac_clean_files=$ac_clean_files_save
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
-$as_echo_n "checking for suffix of object files... " >&6; }
-if ${ac_cv_objext+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-rm -f conftest.o conftest.obj
-if { { ac_try="$ac_compile"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_compile") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then :
- for ac_file in conftest.o conftest.obj conftest.*; do
- test -f "$ac_file" || continue;
- case $ac_file in
- *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
- *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
- break;;
- esac
-done
-else
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "cannot compute suffix of object files: cannot compile
-See \`config.log' for more details" "$LINENO" 5; }
-fi
-rm -f conftest.$ac_cv_objext conftest.$ac_ext
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
-$as_echo "$ac_cv_objext" >&6; }
-OBJEXT=$ac_cv_objext
-ac_objext=$OBJEXT
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
-$as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
-if ${ac_cv_c_compiler_gnu+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-#ifndef __GNUC__
- choke me
-#endif
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_compiler_gnu=yes
-else
- ac_compiler_gnu=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-ac_cv_c_compiler_gnu=$ac_compiler_gnu
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
-$as_echo "$ac_cv_c_compiler_gnu" >&6; }
-if test $ac_compiler_gnu = yes; then
- GCC=yes
-else
- GCC=
-fi
-ac_test_CFLAGS=${CFLAGS+set}
-ac_save_CFLAGS=$CFLAGS
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
-$as_echo_n "checking whether $CC accepts -g... " >&6; }
-if ${ac_cv_prog_cc_g+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_save_c_werror_flag=$ac_c_werror_flag
- ac_c_werror_flag=yes
- ac_cv_prog_cc_g=no
- CFLAGS="-g"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_prog_cc_g=yes
-else
- CFLAGS=""
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
-
-else
- ac_c_werror_flag=$ac_save_c_werror_flag
- CFLAGS="-g"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_prog_cc_g=yes
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- ac_c_werror_flag=$ac_save_c_werror_flag
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
-$as_echo "$ac_cv_prog_cc_g" >&6; }
-if test "$ac_test_CFLAGS" = set; then
- CFLAGS=$ac_save_CFLAGS
-elif test $ac_cv_prog_cc_g = yes; then
- if test "$GCC" = yes; then
- CFLAGS="-g -O2"
- else
- CFLAGS="-g"
- fi
-else
- if test "$GCC" = yes; then
- CFLAGS="-O2"
- else
- CFLAGS=
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
-$as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
-if ${ac_cv_prog_cc_c89+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_cv_prog_cc_c89=no
-ac_save_CC=$CC
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <stdarg.h>
-#include <stdio.h>
-struct stat;
-/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
-struct buf { int x; };
-FILE * (*rcsopen) (struct buf *, struct stat *, int);
-static char *e (p, i)
- char **p;
- int i;
-{
- return p[i];
-}
-static char *f (char * (*g) (char **, int), char **p, ...)
-{
- char *s;
- va_list v;
- va_start (v,p);
- s = g (p, va_arg (v,int));
- va_end (v);
- return s;
-}
-
-/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
- function prototypes and stuff, but not '\xHH' hex character constants.
- These don't provoke an error unfortunately, instead are silently treated
- as 'x'. The following induces an error, until -std is added to get
- proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
- array size at least. It's necessary to write '\x00'==0 to get something
- that's true only with -std. */
-int osf4_cc_array ['\x00' == 0 ? 1 : -1];
-
-/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
- inside strings and character constants. */
-#define FOO(x) 'x'
-int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
-
-int test (int i, double x);
-struct s1 {int (*f) (int a);};
-struct s2 {int (*f) (double a);};
-int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
-int argc;
-char **argv;
-int
-main ()
-{
-return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
- ;
- return 0;
-}
-_ACEOF
-for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
- -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
-do
- CC="$ac_save_CC $ac_arg"
- if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_prog_cc_c89=$ac_arg
-fi
-rm -f core conftest.err conftest.$ac_objext
- test "x$ac_cv_prog_cc_c89" != "xno" && break
-done
-rm -f conftest.$ac_ext
-CC=$ac_save_CC
-
-fi
-# AC_CACHE_VAL
-case "x$ac_cv_prog_cc_c89" in
- x)
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
-$as_echo "none needed" >&6; } ;;
- xno)
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
-$as_echo "unsupported" >&6; } ;;
- *)
- CC="$CC $ac_cv_prog_cc_c89"
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
-$as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
-esac
-if test "x$ac_cv_prog_cc_c89" != xno; then :
-
-fi
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC understands -c and -o together" >&5
-$as_echo_n "checking whether $CC understands -c and -o together... " >&6; }
-if ${am_cv_prog_cc_c_o+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
- # Make sure it works both with $CC and with simple cc.
- # Following AC_PROG_CC_C_O, we do the test twice because some
- # compilers refuse to overwrite an existing .o file with -o,
- # though they will create one.
- am_cv_prog_cc_c_o=yes
- for am_i in 1 2; do
- if { echo "$as_me:$LINENO: $CC -c conftest.$ac_ext -o conftest2.$ac_objext" >&5
- ($CC -c conftest.$ac_ext -o conftest2.$ac_objext) >&5 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } \
- && test -f conftest2.$ac_objext; then
- : OK
- else
- am_cv_prog_cc_c_o=no
- break
- fi
- done
- rm -f core conftest*
- unset am_i
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_cc_c_o" >&5
-$as_echo "$am_cv_prog_cc_c_o" >&6; }
-if test "$am_cv_prog_cc_c_o" != yes; then
- # Losing compiler, so override with the script.
- # FIXME: It is wrong to rewrite CC.
- # But if we don't then we get into trouble of one sort or another.
- # A longer-term fix would be to have automake use am__CC in this case,
- # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
- CC="$am_aux_dir/compile $CC"
-fi
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-DEPDIR="${am__leading_dot}deps"
-
-ac_config_commands="$ac_config_commands depfiles"
-
-
-am_make=${MAKE-make}
-cat > confinc << 'END'
-am__doit:
- @echo this is the am__doit target
-.PHONY: am__doit
-END
-# If we don't find an include directive, just comment out the code.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5
-$as_echo_n "checking for style of include used by $am_make... " >&6; }
-am__include="#"
-am__quote=
-_am_result=none
-# First try GNU make style include.
-echo "include confinc" > confmf
-# Ignore all kinds of additional output from 'make'.
-case `$am_make -s -f confmf 2> /dev/null` in #(
-*the\ am__doit\ target*)
- am__include=include
- am__quote=
- _am_result=GNU
- ;;
-esac
-# Now try BSD make style include.
-if test "$am__include" = "#"; then
- echo '.include "confinc"' > confmf
- case `$am_make -s -f confmf 2> /dev/null` in #(
- *the\ am__doit\ target*)
- am__include=.include
- am__quote="\""
- _am_result=BSD
- ;;
- esac
-fi
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5
-$as_echo "$_am_result" >&6; }
-rm -f confinc confmf
-
-# Check whether --enable-dependency-tracking was given.
-if test "${enable_dependency_tracking+set}" = set; then :
- enableval=$enable_dependency_tracking;
-fi
-
-if test "x$enable_dependency_tracking" != xno; then
- am_depcomp="$ac_aux_dir/depcomp"
- AMDEPBACKSLASH='\'
- am__nodep='_no'
-fi
- if test "x$enable_dependency_tracking" != xno; then
- AMDEP_TRUE=
- AMDEP_FALSE='#'
-else
- AMDEP_TRUE='#'
- AMDEP_FALSE=
-fi
-
-
-
-depcc="$CC" am_compiler_list=
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
-$as_echo_n "checking dependency style of $depcc... " >&6; }
-if ${am_cv_CC_dependencies_compiler_type+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
- # We make a subdir and do the tests there. Otherwise we can end up
- # making bogus files that we don't know about and never remove. For
- # instance it was reported that on HP-UX the gcc test will end up
- # making a dummy file named 'D' -- because '-MD' means "put the output
- # in D".
- rm -rf conftest.dir
- mkdir conftest.dir
- # Copy depcomp to subdir because otherwise we won't find it if we're
- # using a relative directory.
- cp "$am_depcomp" conftest.dir
- cd conftest.dir
- # We will build objects and dependencies in a subdirectory because
- # it helps to detect inapplicable dependency modes. For instance
- # both Tru64's cc and ICC support -MD to output dependencies as a
- # side effect of compilation, but ICC will put the dependencies in
- # the current directory while Tru64 will put them in the object
- # directory.
- mkdir sub
-
- am_cv_CC_dependencies_compiler_type=none
- if test "$am_compiler_list" = ""; then
- am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
- fi
- am__universal=false
- case " $depcc " in #(
- *\ -arch\ *\ -arch\ *) am__universal=true ;;
- esac
-
- for depmode in $am_compiler_list; do
- # Setup a source with many dependencies, because some compilers
- # like to wrap large dependency lists on column 80 (with \), and
- # we should not choose a depcomp mode which is confused by this.
- #
- # We need to recreate these files for each test, as the compiler may
- # overwrite some of them when testing with obscure command lines.
- # This happens at least with the AIX C compiler.
- : > sub/conftest.c
- for i in 1 2 3 4 5 6; do
- echo '#include "conftst'$i'.h"' >> sub/conftest.c
- # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with
- # Solaris 10 /bin/sh.
- echo '/* dummy */' > sub/conftst$i.h
- done
- echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
-
- # We check with '-c' and '-o' for the sake of the "dashmstdout"
- # mode. It turns out that the SunPro C++ compiler does not properly
- # handle '-M -o', and we need to detect this. Also, some Intel
- # versions had trouble with output in subdirs.
- am__obj=sub/conftest.${OBJEXT-o}
- am__minus_obj="-o $am__obj"
- case $depmode in
- gcc)
- # This depmode causes a compiler race in universal mode.
- test "$am__universal" = false || continue
- ;;
- nosideeffect)
- # After this tag, mechanisms are not by side-effect, so they'll
- # only be used when explicitly requested.
- if test "x$enable_dependency_tracking" = xyes; then
- continue
- else
- break
- fi
- ;;
- msvc7 | msvc7msys | msvisualcpp | msvcmsys)
- # This compiler won't grok '-c -o', but also, the minuso test has
- # not run yet. These depmodes are late enough in the game, and
- # so weak that their functioning should not be impacted.
- am__obj=conftest.${OBJEXT-o}
- am__minus_obj=
- ;;
- none) break ;;
- esac
- if depmode=$depmode \
- source=sub/conftest.c object=$am__obj \
- depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
- $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
- >/dev/null 2>conftest.err &&
- grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
- grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
- grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
- ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
- # icc doesn't choke on unknown options, it will just issue warnings
- # or remarks (even with -Werror). So we grep stderr for any message
- # that says an option was ignored or not supported.
- # When given -MP, icc 7.0 and 7.1 complain thusly:
- # icc: Command line warning: ignoring option '-M'; no argument required
- # The diagnosis changed in icc 8.0:
- # icc: Command line remark: option '-MP' not supported
- if (grep 'ignoring option' conftest.err ||
- grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
- am_cv_CC_dependencies_compiler_type=$depmode
- break
- fi
- fi
- done
-
- cd ..
- rm -rf conftest.dir
-else
- am_cv_CC_dependencies_compiler_type=none
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
-$as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
-CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
-
- if
- test "x$enable_dependency_tracking" != xno \
- && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
- am__fastdepCC_TRUE=
- am__fastdepCC_FALSE='#'
-else
- am__fastdepCC_TRUE='#'
- am__fastdepCC_FALSE=
-fi
-
-
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
-$as_echo_n "checking how to run the C preprocessor... " >&6; }
-# On Suns, sometimes $CPP names a directory.
-if test -n "$CPP" && test -d "$CPP"; then
- CPP=
-fi
-if test -z "$CPP"; then
- if ${ac_cv_prog_CPP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- # Double quotes because CPP needs to be expanded
- for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
- do
- ac_preproc_ok=false
-for ac_c_preproc_warn_flag in '' yes
-do
- # Use a header file that comes with gcc, so configuring glibc
- # with a fresh cross-compiler works.
- # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
- # <limits.h> exists even on freestanding compilers.
- # On the NeXT, cc -E runs the code through the compiler's parser,
- # not just through cpp. "Syntax error" is here to catch this case.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#ifdef __STDC__
-# include <limits.h>
-#else
-# include <assert.h>
-#endif
- Syntax error
-_ACEOF
-if ac_fn_c_try_cpp "$LINENO"; then :
-
-else
- # Broken: fails on valid input.
-continue
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-
- # OK, works on sane cases. Now check whether nonexistent headers
- # can be detected and how.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <ac_nonexistent.h>
-_ACEOF
-if ac_fn_c_try_cpp "$LINENO"; then :
- # Broken: success on invalid input.
-continue
-else
- # Passes both tests.
-ac_preproc_ok=:
-break
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-
-done
-# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
-rm -f conftest.i conftest.err conftest.$ac_ext
-if $ac_preproc_ok; then :
- break
-fi
-
- done
- ac_cv_prog_CPP=$CPP
-
-fi
- CPP=$ac_cv_prog_CPP
-else
- ac_cv_prog_CPP=$CPP
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
-$as_echo "$CPP" >&6; }
-ac_preproc_ok=false
-for ac_c_preproc_warn_flag in '' yes
-do
- # Use a header file that comes with gcc, so configuring glibc
- # with a fresh cross-compiler works.
- # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
- # <limits.h> exists even on freestanding compilers.
- # On the NeXT, cc -E runs the code through the compiler's parser,
- # not just through cpp. "Syntax error" is here to catch this case.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#ifdef __STDC__
-# include <limits.h>
-#else
-# include <assert.h>
-#endif
- Syntax error
-_ACEOF
-if ac_fn_c_try_cpp "$LINENO"; then :
-
-else
- # Broken: fails on valid input.
-continue
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-
- # OK, works on sane cases. Now check whether nonexistent headers
- # can be detected and how.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <ac_nonexistent.h>
-_ACEOF
-if ac_fn_c_try_cpp "$LINENO"; then :
- # Broken: success on invalid input.
-continue
-else
- # Passes both tests.
-ac_preproc_ok=:
-break
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-
-done
-# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
-rm -f conftest.i conftest.err conftest.$ac_ext
-if $ac_preproc_ok; then :
-
-else
- { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
-See \`config.log' for more details" "$LINENO" 5; }
-fi
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
-$as_echo_n "checking for grep that handles long lines and -e... " >&6; }
-if ${ac_cv_path_GREP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -z "$GREP"; then
- ac_path_GREP_found=false
- # Loop through the user's path and test for each of PROGNAME-LIST
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_prog in grep ggrep; do
- for ac_exec_ext in '' $ac_executable_extensions; do
- ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
- as_fn_executable_p "$ac_path_GREP" || continue
-# Check for GNU ac_path_GREP and select it if it is found.
- # Check for GNU $ac_path_GREP
-case `"$ac_path_GREP" --version 2>&1` in
-*GNU*)
- ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
-*)
- ac_count=0
- $as_echo_n 0123456789 >"conftest.in"
- while :
- do
- cat "conftest.in" "conftest.in" >"conftest.tmp"
- mv "conftest.tmp" "conftest.in"
- cp "conftest.in" "conftest.nl"
- $as_echo 'GREP' >> "conftest.nl"
- "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
- diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
- as_fn_arith $ac_count + 1 && ac_count=$as_val
- if test $ac_count -gt ${ac_path_GREP_max-0}; then
- # Best one so far, save it but keep looking for a better one
- ac_cv_path_GREP="$ac_path_GREP"
- ac_path_GREP_max=$ac_count
- fi
- # 10*(2^10) chars as input seems more than enough
- test $ac_count -gt 10 && break
- done
- rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
-esac
-
- $ac_path_GREP_found && break 3
- done
- done
- done
-IFS=$as_save_IFS
- if test -z "$ac_cv_path_GREP"; then
- as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
- fi
-else
- ac_cv_path_GREP=$GREP
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
-$as_echo "$ac_cv_path_GREP" >&6; }
- GREP="$ac_cv_path_GREP"
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
-$as_echo_n "checking for egrep... " >&6; }
-if ${ac_cv_path_EGREP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
- then ac_cv_path_EGREP="$GREP -E"
- else
- if test -z "$EGREP"; then
- ac_path_EGREP_found=false
- # Loop through the user's path and test for each of PROGNAME-LIST
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_prog in egrep; do
- for ac_exec_ext in '' $ac_executable_extensions; do
- ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
- as_fn_executable_p "$ac_path_EGREP" || continue
-# Check for GNU ac_path_EGREP and select it if it is found.
- # Check for GNU $ac_path_EGREP
-case `"$ac_path_EGREP" --version 2>&1` in
-*GNU*)
- ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
-*)
- ac_count=0
- $as_echo_n 0123456789 >"conftest.in"
- while :
- do
- cat "conftest.in" "conftest.in" >"conftest.tmp"
- mv "conftest.tmp" "conftest.in"
- cp "conftest.in" "conftest.nl"
- $as_echo 'EGREP' >> "conftest.nl"
- "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
- diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
- as_fn_arith $ac_count + 1 && ac_count=$as_val
- if test $ac_count -gt ${ac_path_EGREP_max-0}; then
- # Best one so far, save it but keep looking for a better one
- ac_cv_path_EGREP="$ac_path_EGREP"
- ac_path_EGREP_max=$ac_count
- fi
- # 10*(2^10) chars as input seems more than enough
- test $ac_count -gt 10 && break
- done
- rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
-esac
-
- $ac_path_EGREP_found && break 3
- done
- done
- done
-IFS=$as_save_IFS
- if test -z "$ac_cv_path_EGREP"; then
- as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
- fi
-else
- ac_cv_path_EGREP=$EGREP
-fi
-
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
-$as_echo "$ac_cv_path_EGREP" >&6; }
- EGREP="$ac_cv_path_EGREP"
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
-$as_echo_n "checking for ANSI C header files... " >&6; }
-if ${ac_cv_header_stdc+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <stdlib.h>
-#include <stdarg.h>
-#include <string.h>
-#include <float.h>
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_header_stdc=yes
-else
- ac_cv_header_stdc=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-
-if test $ac_cv_header_stdc = yes; then
- # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <string.h>
-
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "memchr" >/dev/null 2>&1; then :
-
-else
- ac_cv_header_stdc=no
-fi
-rm -f conftest*
-
-fi
-
-if test $ac_cv_header_stdc = yes; then
- # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <stdlib.h>
-
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "free" >/dev/null 2>&1; then :
-
-else
- ac_cv_header_stdc=no
-fi
-rm -f conftest*
-
-fi
-
-if test $ac_cv_header_stdc = yes; then
- # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
- if test "$cross_compiling" = yes; then :
- :
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <ctype.h>
-#include <stdlib.h>
-#if ((' ' & 0x0FF) == 0x020)
-# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
-# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
-#else
-# define ISLOWER(c) \
- (('a' <= (c) && (c) <= 'i') \
- || ('j' <= (c) && (c) <= 'r') \
- || ('s' <= (c) && (c) <= 'z'))
-# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
-#endif
-
-#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
-int
-main ()
-{
- int i;
- for (i = 0; i < 256; i++)
- if (XOR (islower (i), ISLOWER (i))
- || toupper (i) != TOUPPER (i))
- return 2;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_run "$LINENO"; then :
-
-else
- ac_cv_header_stdc=no
-fi
-rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
- conftest.$ac_objext conftest.beam conftest.$ac_ext
-fi
-
-fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
-$as_echo "$ac_cv_header_stdc" >&6; }
-if test $ac_cv_header_stdc = yes; then
-
-$as_echo "#define STDC_HEADERS 1" >>confdefs.h
-
-fi
-
-# On IRIX 5.3, sys/types and inttypes.h are conflicting.
-for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
- inttypes.h stdint.h unistd.h
-do :
- as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
-ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
-"
-if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
- cat >>confdefs.h <<_ACEOF
-#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
-_ACEOF
-
-fi
-
-done
-
-
-
- ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
-if test "x$ac_cv_header_minix_config_h" = xyes; then :
- MINIX=yes
-else
- MINIX=
-fi
-
-
- if test "$MINIX" = yes; then
-
-$as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
-
-
-$as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
-
-
-$as_echo "#define _MINIX 1" >>confdefs.h
-
- fi
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
-$as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
-if ${ac_cv_safe_to_define___extensions__+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-# define __EXTENSIONS__ 1
- $ac_includes_default
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_safe_to_define___extensions__=yes
-else
- ac_cv_safe_to_define___extensions__=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
-$as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
- test $ac_cv_safe_to_define___extensions__ = yes &&
- $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
-
- $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
-
- $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
-
- $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
-
- $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
-$as_echo_n "checking whether byte ordering is bigendian... " >&6; }
-if ${ac_cv_c_bigendian+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_cv_c_bigendian=unknown
- # See if we're dealing with a universal compiler.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#ifndef __APPLE_CC__
- not a universal capable compiler
- #endif
- typedef int dummy;
-
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
-
- # Check for potential -arch flags. It is not universal unless
- # there are at least two -arch flags with different values.
- ac_arch=
- ac_prev=
- for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
- if test -n "$ac_prev"; then
- case $ac_word in
- i?86 | x86_64 | ppc | ppc64)
- if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
- ac_arch=$ac_word
- else
- ac_cv_c_bigendian=universal
- break
- fi
- ;;
- esac
- ac_prev=
- elif test "x$ac_word" = "x-arch"; then
- ac_prev=arch
- fi
- done
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- if test $ac_cv_c_bigendian = unknown; then
- # See if sys/param.h defines the BYTE_ORDER macro.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <sys/types.h>
- #include <sys/param.h>
-
-int
-main ()
-{
-#if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
- && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
- && LITTLE_ENDIAN)
- bogus endian macros
- #endif
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- # It does; now see whether it defined to BIG_ENDIAN or not.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <sys/types.h>
- #include <sys/param.h>
-
-int
-main ()
-{
-#if BYTE_ORDER != BIG_ENDIAN
- not big endian
- #endif
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_c_bigendian=yes
-else
- ac_cv_c_bigendian=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- fi
- if test $ac_cv_c_bigendian = unknown; then
- # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <limits.h>
-
-int
-main ()
-{
-#if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
- bogus endian macros
- #endif
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- # It does; now see whether it defined to _BIG_ENDIAN or not.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <limits.h>
-
-int
-main ()
-{
-#ifndef _BIG_ENDIAN
- not big endian
- #endif
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_c_bigendian=yes
-else
- ac_cv_c_bigendian=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- fi
- if test $ac_cv_c_bigendian = unknown; then
- # Compile a test program.
- if test "$cross_compiling" = yes; then :
- # Try to guess by grepping values from an object file.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-short int ascii_mm[] =
- { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
- short int ascii_ii[] =
- { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
- int use_ascii (int i) {
- return ascii_mm[i] + ascii_ii[i];
- }
- short int ebcdic_ii[] =
- { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
- short int ebcdic_mm[] =
- { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
- int use_ebcdic (int i) {
- return ebcdic_mm[i] + ebcdic_ii[i];
- }
- extern int foo;
-
-int
-main ()
-{
-return use_ascii (foo) == use_ebcdic (foo);
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
- ac_cv_c_bigendian=yes
- fi
- if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
- if test "$ac_cv_c_bigendian" = unknown; then
- ac_cv_c_bigendian=no
- else
- # finding both strings is unlikely to happen, but who knows?
- ac_cv_c_bigendian=unknown
- fi
- fi
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$ac_includes_default
-int
-main ()
-{
-
- /* Are we little or big endian? From Harbison&Steele. */
- union
- {
- long int l;
- char c[sizeof (long int)];
- } u;
- u.l = 1;
- return u.c[sizeof (long int) - 1] == 1;
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_run "$LINENO"; then :
- ac_cv_c_bigendian=no
-else
- ac_cv_c_bigendian=yes
-fi
-rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
- conftest.$ac_objext conftest.beam conftest.$ac_ext
-fi
-
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
-$as_echo "$ac_cv_c_bigendian" >&6; }
- case $ac_cv_c_bigendian in #(
- yes)
- $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
-;; #(
- no)
- ;; #(
- universal)
-
-$as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
-
- ;; #(
- *)
- as_fn_error $? "unknown endianness
- presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
- esac
-
-
-case `pwd` in
- *\ * | *\ *)
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&5
-$as_echo "$as_me: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&2;} ;;
-esac
-
-
-
-macro_version='2.2.7a'
-macro_revision='1.3134'
-
-
-
-
-
-
-
-
-
-
-
-
-
-ltmain="$ac_aux_dir/ltmain.sh"
-
-# Backslashify metacharacters that are still active within
-# double-quoted strings.
-sed_quote_subst='s/\(["`$\\]\)/\\\1/g'
-
-# Same as above, but do not quote variable references.
-double_quote_subst='s/\(["`\\]\)/\\\1/g'
-
-# Sed substitution to delay expansion of an escaped shell variable in a
-# double_quote_subst'ed string.
-delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
-
-# Sed substitution to delay expansion of an escaped single quote.
-delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g'
-
-# Sed substitution to avoid accidental globbing in evaled expressions
-no_glob_subst='s/\*/\\\*/g'
-
-ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
-ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO
-ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5
-$as_echo_n "checking how to print strings... " >&6; }
-# Test print first, because it will be a builtin if present.
-if test "X`print -r -- -n 2>/dev/null`" = X-n && \
- test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
- ECHO='print -r --'
-elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
- ECHO='printf %s\n'
-else
- # Use this function as a fallback that always works.
- func_fallback_echo ()
- {
- eval 'cat <<_LTECHO_EOF
-$1
-_LTECHO_EOF'
- }
- ECHO='func_fallback_echo'
-fi
-
-# func_echo_all arg...
-# Invoke $ECHO with all args, space-separated.
-func_echo_all ()
-{
- $ECHO ""
-}
-
-case "$ECHO" in
- printf*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: printf" >&5
-$as_echo "printf" >&6; } ;;
- print*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: print -r" >&5
-$as_echo "print -r" >&6; } ;;
- *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: cat" >&5
-$as_echo "cat" >&6; } ;;
-esac
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
-$as_echo_n "checking for a sed that does not truncate output... " >&6; }
-if ${ac_cv_path_SED+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
- for ac_i in 1 2 3 4 5 6 7; do
- ac_script="$ac_script$as_nl$ac_script"
- done
- echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
- { ac_script=; unset ac_script;}
- if test -z "$SED"; then
- ac_path_SED_found=false
- # Loop through the user's path and test for each of PROGNAME-LIST
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_prog in sed gsed; do
- for ac_exec_ext in '' $ac_executable_extensions; do
- ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
- as_fn_executable_p "$ac_path_SED" || continue
-# Check for GNU ac_path_SED and select it if it is found.
- # Check for GNU $ac_path_SED
-case `"$ac_path_SED" --version 2>&1` in
-*GNU*)
- ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
-*)
- ac_count=0
- $as_echo_n 0123456789 >"conftest.in"
- while :
- do
- cat "conftest.in" "conftest.in" >"conftest.tmp"
- mv "conftest.tmp" "conftest.in"
- cp "conftest.in" "conftest.nl"
- $as_echo '' >> "conftest.nl"
- "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
- diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
- as_fn_arith $ac_count + 1 && ac_count=$as_val
- if test $ac_count -gt ${ac_path_SED_max-0}; then
- # Best one so far, save it but keep looking for a better one
- ac_cv_path_SED="$ac_path_SED"
- ac_path_SED_max=$ac_count
- fi
- # 10*(2^10) chars as input seems more than enough
- test $ac_count -gt 10 && break
- done
- rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
-esac
-
- $ac_path_SED_found && break 3
- done
- done
- done
-IFS=$as_save_IFS
- if test -z "$ac_cv_path_SED"; then
- as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
- fi
-else
- ac_cv_path_SED=$SED
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
-$as_echo "$ac_cv_path_SED" >&6; }
- SED="$ac_cv_path_SED"
- rm -f conftest.sed
-
-test -z "$SED" && SED=sed
-Xsed="$SED -e 1s/^X//"
-
-
-
-
-
-
-
-
-
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5
-$as_echo_n "checking for fgrep... " >&6; }
-if ${ac_cv_path_FGREP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1
- then ac_cv_path_FGREP="$GREP -F"
- else
- if test -z "$FGREP"; then
- ac_path_FGREP_found=false
- # Loop through the user's path and test for each of PROGNAME-LIST
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_prog in fgrep; do
- for ac_exec_ext in '' $ac_executable_extensions; do
- ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext"
- as_fn_executable_p "$ac_path_FGREP" || continue
-# Check for GNU ac_path_FGREP and select it if it is found.
- # Check for GNU $ac_path_FGREP
-case `"$ac_path_FGREP" --version 2>&1` in
-*GNU*)
- ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;;
-*)
- ac_count=0
- $as_echo_n 0123456789 >"conftest.in"
- while :
- do
- cat "conftest.in" "conftest.in" >"conftest.tmp"
- mv "conftest.tmp" "conftest.in"
- cp "conftest.in" "conftest.nl"
- $as_echo 'FGREP' >> "conftest.nl"
- "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break
- diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
- as_fn_arith $ac_count + 1 && ac_count=$as_val
- if test $ac_count -gt ${ac_path_FGREP_max-0}; then
- # Best one so far, save it but keep looking for a better one
- ac_cv_path_FGREP="$ac_path_FGREP"
- ac_path_FGREP_max=$ac_count
- fi
- # 10*(2^10) chars as input seems more than enough
- test $ac_count -gt 10 && break
- done
- rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
-esac
-
- $ac_path_FGREP_found && break 3
- done
- done
- done
-IFS=$as_save_IFS
- if test -z "$ac_cv_path_FGREP"; then
- as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
- fi
-else
- ac_cv_path_FGREP=$FGREP
-fi
-
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5
-$as_echo "$ac_cv_path_FGREP" >&6; }
- FGREP="$ac_cv_path_FGREP"
-
-
-test -z "$GREP" && GREP=grep
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-# Check whether --with-gnu-ld was given.
-if test "${with_gnu_ld+set}" = set; then :
- withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
-else
- with_gnu_ld=no
-fi
-
-ac_prog=ld
-if test "$GCC" = yes; then
- # Check if gcc -print-prog-name=ld gives a path.
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5
-$as_echo_n "checking for ld used by $CC... " >&6; }
- case $host in
- *-*-mingw*)
- # gcc leaves a trailing carriage return which upsets mingw
- ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
- *)
- ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
- esac
- case $ac_prog in
- # Accept absolute paths.
- [\\/]* | ?:[\\/]*)
- re_direlt='/[^/][^/]*/\.\./'
- # Canonicalize the pathname of ld
- ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'`
- while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do
- ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"`
- done
- test -z "$LD" && LD="$ac_prog"
- ;;
- "")
- # If it fails, then pretend we aren't using GCC.
- ac_prog=ld
- ;;
- *)
- # If it is relative, then search for the first ld in PATH.
- with_gnu_ld=unknown
- ;;
- esac
-elif test "$with_gnu_ld" = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
-$as_echo_n "checking for GNU ld... " >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
-$as_echo_n "checking for non-GNU ld... " >&6; }
-fi
-if ${lt_cv_path_LD+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -z "$LD"; then
- lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH; do
- IFS="$lt_save_ifs"
- test -z "$ac_dir" && ac_dir=.
- if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
- lt_cv_path_LD="$ac_dir/$ac_prog"
- # Check to see if the program is GNU ld. I'd rather use --version,
- # but apparently some variants of GNU ld only accept -v.
- # Break only if it was the GNU/non-GNU ld that we prefer.
- case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
- *GNU* | *'with BFD'*)
- test "$with_gnu_ld" != no && break
- ;;
- *)
- test "$with_gnu_ld" != yes && break
- ;;
- esac
- fi
- done
- IFS="$lt_save_ifs"
-else
- lt_cv_path_LD="$LD" # Let the user override the test with a path.
-fi
-fi
-
-LD="$lt_cv_path_LD"
-if test -n "$LD"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
-$as_echo "$LD" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
-$as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
-if ${lt_cv_prog_gnu_ld+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- # I'd rather use --version here, but apparently some GNU lds only accept -v.
-case `$LD -v 2>&1 </dev/null` in
-*GNU* | *'with BFD'*)
- lt_cv_prog_gnu_ld=yes
- ;;
-*)
- lt_cv_prog_gnu_ld=no
- ;;
-esac
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_gnu_ld" >&5
-$as_echo "$lt_cv_prog_gnu_ld" >&6; }
-with_gnu_ld=$lt_cv_prog_gnu_ld
-
-
-
-
-
-
-
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for BSD- or MS-compatible name lister (nm)" >&5
-$as_echo_n "checking for BSD- or MS-compatible name lister (nm)... " >&6; }
-if ${lt_cv_path_NM+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$NM"; then
- # Let the user override the nm to test.
- lt_nm_to_check="$NM"
- else
- lt_nm_to_check="${ac_tool_prefix}nm"
- if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
- lt_nm_to_check="$lt_nm_to_check nm"
- fi
- fi
- for lt_tmp_nm in "$lt_nm_to_check"; do
- lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
- IFS="$lt_save_ifs"
- test -z "$ac_dir" && ac_dir=.
- # Strip out any user-provided options from the nm to test twice,
- # the first time to test to see if nm (rather than its options) has
- # an explicit path, the second time to yield a file which can be
- # nm'ed itself.
- tmp_nm_path="`$ECHO "$lt_tmp_nm" | sed 's, -.*$,,'`"
- case "$tmp_nm_path" in
- */*|*\\*) tmp_nm="$lt_tmp_nm";;
- *) tmp_nm="$ac_dir/$lt_tmp_nm";;
- esac
- tmp_nm_to_nm="`$ECHO "$tmp_nm" | sed 's, -.*$,,'`"
- if test -f "$tmp_nm_to_nm" || test -f "$tmp_nm_to_nm$ac_exeext" ; then
- # Check to see if the nm accepts a BSD-compat flag.
- # Adding the `sed 1q' prevents false positives on HP-UX, which says:
- # nm: unknown option "B" ignored
- case `"$tmp_nm" -B "$tmp_nm_to_nm" 2>&1 | grep -v '^ *$' | sed '1q'` in
- *$tmp_nm*) lt_cv_path_NM="$tmp_nm -B"
- break
- ;;
- *)
- case `"$tmp_nm" -p "$tmp_nm_to_nm" 2>&1 | grep -v '^ *$' | sed '1q'` in
- *$tmp_nm*)
- lt_cv_path_NM="$tmp_nm -p"
- break
- ;;
- *)
- lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
- continue # so that we can try to find one that supports BSD flags
- ;;
- esac
- ;;
- esac
- fi
- done
- IFS="$lt_save_ifs"
- done
- : ${lt_cv_path_NM=no}
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_NM" >&5
-$as_echo "$lt_cv_path_NM" >&6; }
-if test "$lt_cv_path_NM" != "no"; then
- NM="$lt_cv_path_NM"
-else
- # Didn't find any BSD compatible name lister, look for dumpbin.
- if test -n "$DUMPBIN"; then :
- # Let the user override the test.
- else
- if test -n "$ac_tool_prefix"; then
- for ac_prog in dumpbin "link -dump"
- do
- # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
-set dummy $ac_tool_prefix$ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_DUMPBIN+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$DUMPBIN"; then
- ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_DUMPBIN="$ac_tool_prefix$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-DUMPBIN=$ac_cv_prog_DUMPBIN
-if test -n "$DUMPBIN"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5
-$as_echo "$DUMPBIN" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$DUMPBIN" && break
- done
-fi
-if test -z "$DUMPBIN"; then
- ac_ct_DUMPBIN=$DUMPBIN
- for ac_prog in dumpbin "link -dump"
-do
- # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_DUMPBIN+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_DUMPBIN"; then
- ac_cv_prog_ac_ct_DUMPBIN="$ac_ct_DUMPBIN" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_DUMPBIN="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_DUMPBIN=$ac_cv_prog_ac_ct_DUMPBIN
-if test -n "$ac_ct_DUMPBIN"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DUMPBIN" >&5
-$as_echo "$ac_ct_DUMPBIN" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$ac_ct_DUMPBIN" && break
-done
-
- if test "x$ac_ct_DUMPBIN" = x; then
- DUMPBIN=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- DUMPBIN=$ac_ct_DUMPBIN
- fi
-fi
-
- case `$DUMPBIN -symbols /dev/null 2>&1 | sed '1q'` in
- *COFF*)
- DUMPBIN="$DUMPBIN -symbols"
- ;;
- *)
- DUMPBIN=:
- ;;
- esac
- fi
-
- if test "$DUMPBIN" != ":"; then
- NM="$DUMPBIN"
- fi
-fi
-test -z "$NM" && NM=nm
-
-
-
-
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the name lister ($NM) interface" >&5
-$as_echo_n "checking the name lister ($NM) interface... " >&6; }
-if ${lt_cv_nm_interface+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_nm_interface="BSD nm"
- echo "int some_variable = 0;" > conftest.$ac_ext
- (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&5)
- (eval "$ac_compile" 2>conftest.err)
- cat conftest.err >&5
- (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&5)
- (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out)
- cat conftest.err >&5
- (eval echo "\"\$as_me:$LINENO: output\"" >&5)
- cat conftest.out >&5
- if $GREP 'External.*some_variable' conftest.out > /dev/null; then
- lt_cv_nm_interface="MS dumpbin"
- fi
- rm -f conftest*
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_nm_interface" >&5
-$as_echo "$lt_cv_nm_interface" >&6; }
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
-$as_echo_n "checking whether ln -s works... " >&6; }
-LN_S=$as_ln_s
-if test "$LN_S" = "ln -s"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
-$as_echo "no, using $LN_S" >&6; }
-fi
-
-# find the maximum length of command line arguments
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the maximum length of command line arguments" >&5
-$as_echo_n "checking the maximum length of command line arguments... " >&6; }
-if ${lt_cv_sys_max_cmd_len+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- i=0
- teststring="ABCD"
-
- case $build_os in
- msdosdjgpp*)
- # On DJGPP, this test can blow up pretty badly due to problems in libc
- # (any single argument exceeding 2000 bytes causes a buffer overrun
- # during glob expansion). Even if it were fixed, the result of this
- # check would be larger than it should be.
- lt_cv_sys_max_cmd_len=12288; # 12K is about right
- ;;
-
- gnu*)
- # Under GNU Hurd, this test is not required because there is
- # no limit to the length of command line arguments.
- # Libtool will interpret -1 as no limit whatsoever
- lt_cv_sys_max_cmd_len=-1;
- ;;
-
- cygwin* | mingw* | cegcc*)
- # On Win9x/ME, this test blows up -- it succeeds, but takes
- # about 5 minutes as the teststring grows exponentially.
- # Worse, since 9x/ME are not pre-emptively multitasking,
- # you end up with a "frozen" computer, even though with patience
- # the test eventually succeeds (with a max line length of 256k).
- # Instead, let's just punt: use the minimum linelength reported by
- # all of the supported platforms: 8192 (on NT/2K/XP).
- lt_cv_sys_max_cmd_len=8192;
- ;;
-
- mint*)
- # On MiNT this can take a long time and run out of memory.
- lt_cv_sys_max_cmd_len=8192;
- ;;
-
- amigaos*)
- # On AmigaOS with pdksh, this test takes hours, literally.
- # So we just punt and use a minimum line length of 8192.
- lt_cv_sys_max_cmd_len=8192;
- ;;
-
- netbsd* | freebsd* | openbsd* | darwin* | dragonfly*)
- # This has been around since 386BSD, at least. Likely further.
- if test -x /sbin/sysctl; then
- lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
- elif test -x /usr/sbin/sysctl; then
- lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
- else
- lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs
- fi
- # And add a safety zone
- lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
- lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
- ;;
-
- interix*)
- # We know the value 262144 and hardcode it with a safety zone (like BSD)
- lt_cv_sys_max_cmd_len=196608
- ;;
-
- osf*)
- # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
- # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
- # nice to cause kernel panics so lets avoid the loop below.
- # First set a reasonable default.
- lt_cv_sys_max_cmd_len=16384
- #
- if test -x /sbin/sysconfig; then
- case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
- *1*) lt_cv_sys_max_cmd_len=-1 ;;
- esac
- fi
- ;;
- sco3.2v5*)
- lt_cv_sys_max_cmd_len=102400
- ;;
- sysv5* | sco5v6* | sysv4.2uw2*)
- kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
- if test -n "$kargmax"; then
- lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[ ]//'`
- else
- lt_cv_sys_max_cmd_len=32768
- fi
- ;;
- *)
- lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null`
- if test -n "$lt_cv_sys_max_cmd_len"; then
- lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
- lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
- else
- # Make teststring a little bigger before we do anything with it.
- # a 1K string should be a reasonable start.
- for i in 1 2 3 4 5 6 7 8 ; do
- teststring=$teststring$teststring
- done
- SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
- # If test is not a shell built-in, we'll probably end up computing a
- # maximum length that is only half of the actual maximum length, but
- # we can't tell.
- while { test "X"`func_fallback_echo "$teststring$teststring" 2>/dev/null` \
- = "X$teststring$teststring"; } >/dev/null 2>&1 &&
- test $i != 17 # 1/2 MB should be enough
- do
- i=`expr $i + 1`
- teststring=$teststring$teststring
- done
- # Only check the string length outside the loop.
- lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1`
- teststring=
- # Add a significant safety factor because C++ compilers can tack on
- # massive amounts of additional arguments before passing them to the
- # linker. It appears as though 1/2 is a usable value.
- lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
- fi
- ;;
- esac
-
-fi
-
-if test -n $lt_cv_sys_max_cmd_len ; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sys_max_cmd_len" >&5
-$as_echo "$lt_cv_sys_max_cmd_len" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: none" >&5
-$as_echo "none" >&6; }
-fi
-max_cmd_len=$lt_cv_sys_max_cmd_len
-
-
-
-
-
-
-: ${CP="cp -f"}
-: ${MV="mv -f"}
-: ${RM="rm -f"}
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the shell understands some XSI constructs" >&5
-$as_echo_n "checking whether the shell understands some XSI constructs... " >&6; }
-# Try some XSI features
-xsi_shell=no
-( _lt_dummy="a/b/c"
- test "${_lt_dummy##*/},${_lt_dummy%/*},"${_lt_dummy%"$_lt_dummy"}, \
- = c,a/b,, \
- && eval 'test $(( 1 + 1 )) -eq 2 \
- && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \
- && xsi_shell=yes
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $xsi_shell" >&5
-$as_echo "$xsi_shell" >&6; }
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the shell understands \"+=\"" >&5
-$as_echo_n "checking whether the shell understands \"+=\"... " >&6; }
-lt_shell_append=no
-( foo=bar; set foo baz; eval "$1+=\$2" && test "$foo" = barbaz ) \
- >/dev/null 2>&1 \
- && lt_shell_append=yes
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_shell_append" >&5
-$as_echo "$lt_shell_append" >&6; }
-
-
-if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
- lt_unset=unset
-else
- lt_unset=false
-fi
-
-
-
-
-
-# test EBCDIC or ASCII
-case `echo X|tr X '\101'` in
- A) # ASCII based system
- # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr
- lt_SP2NL='tr \040 \012'
- lt_NL2SP='tr \015\012 \040\040'
- ;;
- *) # EBCDIC based system
- lt_SP2NL='tr \100 \n'
- lt_NL2SP='tr \r\n \100\100'
- ;;
-esac
-
-
-
-
-
-
-
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5
-$as_echo_n "checking for $LD option to reload object files... " >&6; }
-if ${lt_cv_ld_reload_flag+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_ld_reload_flag='-r'
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_reload_flag" >&5
-$as_echo "$lt_cv_ld_reload_flag" >&6; }
-reload_flag=$lt_cv_ld_reload_flag
-case $reload_flag in
-"" | " "*) ;;
-*) reload_flag=" $reload_flag" ;;
-esac
-reload_cmds='$LD$reload_flag -o $output$reload_objs'
-case $host_os in
- darwin*)
- if test "$GCC" = yes; then
- reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
- else
- reload_cmds='$LD$reload_flag -o $output$reload_objs'
- fi
- ;;
-esac
-
-
-
-
-
-
-
-
-
-if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args.
-set dummy ${ac_tool_prefix}objdump; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_OBJDUMP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$OBJDUMP"; then
- ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-OBJDUMP=$ac_cv_prog_OBJDUMP
-if test -n "$OBJDUMP"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
-$as_echo "$OBJDUMP" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_OBJDUMP"; then
- ac_ct_OBJDUMP=$OBJDUMP
- # Extract the first word of "objdump", so it can be a program name with args.
-set dummy objdump; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_OBJDUMP"; then
- ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_OBJDUMP="objdump"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP
-if test -n "$ac_ct_OBJDUMP"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5
-$as_echo "$ac_ct_OBJDUMP" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_OBJDUMP" = x; then
- OBJDUMP="false"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- OBJDUMP=$ac_ct_OBJDUMP
- fi
-else
- OBJDUMP="$ac_cv_prog_OBJDUMP"
-fi
-
-test -z "$OBJDUMP" && OBJDUMP=objdump
-
-
-
-
-
-
-
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to recognize dependent libraries" >&5
-$as_echo_n "checking how to recognize dependent libraries... " >&6; }
-if ${lt_cv_deplibs_check_method+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_file_magic_cmd='$MAGIC_CMD'
-lt_cv_file_magic_test_file=
-lt_cv_deplibs_check_method='unknown'
-# Need to set the preceding variable on all platforms that support
-# interlibrary dependencies.
-# 'none' -- dependencies not supported.
-# `unknown' -- same as none, but documents that we really don't know.
-# 'pass_all' -- all dependencies passed with no checks.
-# 'test_compile' -- check by making test program.
-# 'file_magic [[regex]]' -- check by looking for files in library path
-# which responds to the $file_magic_cmd with a given extended regex.
-# If you have `file' or equivalent on your system and you're not sure
-# whether `pass_all' will *always* work, you probably want this one.
-
-case $host_os in
-aix[4-9]*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-beos*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-bsdi[45]*)
- lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)'
- lt_cv_file_magic_cmd='/usr/bin/file -L'
- lt_cv_file_magic_test_file=/shlib/libc.so
- ;;
-
-cygwin*)
- # func_win32_libid is a shell function defined in ltmain.sh
- lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
- lt_cv_file_magic_cmd='func_win32_libid'
- ;;
-
-mingw* | pw32*)
- # Base MSYS/MinGW do not provide the 'file' command needed by
- # func_win32_libid shell function, so use a weaker test based on 'objdump',
- # unless we find 'file', for example because we are cross-compiling.
- # func_win32_libid assumes BSD nm, so disallow it if using MS dumpbin.
- if ( test "$lt_cv_nm_interface" = "BSD nm" && file / ) >/dev/null 2>&1; then
- lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
- lt_cv_file_magic_cmd='func_win32_libid'
- else
- lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
- lt_cv_file_magic_cmd='$OBJDUMP -f'
- fi
- ;;
-
-cegcc*)
- # use the weaker test based on 'objdump'. See mingw*.
- lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?'
- lt_cv_file_magic_cmd='$OBJDUMP -f'
- ;;
-
-darwin* | rhapsody*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-freebsd* | dragonfly*)
- if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
- case $host_cpu in
- i*86 )
- # Not sure whether the presence of OpenBSD here was a mistake.
- # Let's accept both of them until this is cleared up.
- lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library'
- lt_cv_file_magic_cmd=/usr/bin/file
- lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
- ;;
- esac
- else
- lt_cv_deplibs_check_method=pass_all
- fi
- ;;
-
-gnu*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-haiku*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-hpux10.20* | hpux11*)
- lt_cv_file_magic_cmd=/usr/bin/file
- case $host_cpu in
- ia64*)
- lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64'
- lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
- ;;
- hppa*64*)
- lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF[ -][0-9][0-9])(-bit)?( [LM]SB)? shared object( file)?[, -]* PA-RISC [0-9]\.[0-9]'
- lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
- ;;
- *)
- lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9]\.[0-9]) shared library'
- lt_cv_file_magic_test_file=/usr/lib/libc.sl
- ;;
- esac
- ;;
-
-interix[3-9]*)
- # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
- lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|\.a)$'
- ;;
-
-irix5* | irix6* | nonstopux*)
- case $LD in
- *-32|*"-32 ") libmagic=32-bit;;
- *-n32|*"-n32 ") libmagic=N32;;
- *-64|*"-64 ") libmagic=64-bit;;
- *) libmagic=never-match;;
- esac
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-# This must be Linux ELF.
-linux* | k*bsd*-gnu | kopensolaris*-gnu | uclinuxfdpiceabi)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-netbsd*)
- if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
- lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
- else
- lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$'
- fi
- ;;
-
-newos6*)
- lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)'
- lt_cv_file_magic_cmd=/usr/bin/file
- lt_cv_file_magic_test_file=/usr/lib/libnls.so
- ;;
-
-*nto* | *qnx*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-openbsd*)
- if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
- lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$'
- else
- lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
- fi
- ;;
-
-osf3* | osf4* | osf5*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-rdos*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-solaris*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-sysv4 | sysv4.3*)
- case $host_vendor in
- motorola)
- lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib) M[0-9][0-9]* Version [0-9]'
- lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
- ;;
- ncr)
- lt_cv_deplibs_check_method=pass_all
- ;;
- sequent)
- lt_cv_file_magic_cmd='/bin/file'
- lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )'
- ;;
- sni)
- lt_cv_file_magic_cmd='/bin/file'
- lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib"
- lt_cv_file_magic_test_file=/lib/libc.so
- ;;
- siemens)
- lt_cv_deplibs_check_method=pass_all
- ;;
- pc)
- lt_cv_deplibs_check_method=pass_all
- ;;
- esac
- ;;
-
-tpf*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-vxworks*)
- # Assume VxWorks cross toolchains are built on Linux, possibly
- # as canadian for Windows hosts.
- lt_cv_deplibs_check_method=pass_all
- ;;
-esac
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5
-$as_echo "$lt_cv_deplibs_check_method" >&6; }
-file_magic_cmd=$lt_cv_file_magic_cmd
-deplibs_check_method=$lt_cv_deplibs_check_method
-test -z "$deplibs_check_method" && deplibs_check_method=unknown
-
-
-
-
-
-
-
-
-
-
-
-
-plugin_option=
-plugin_names="liblto_plugin.so liblto_plugin-0.dll cyglto_plugin-0.dll"
-for plugin in $plugin_names; do
- plugin_so=`${CC} ${CFLAGS} --print-prog-name $plugin`
- if test x$plugin_so = x$plugin; then
- plugin_so=`${CC} ${CFLAGS} --print-file-name $plugin`
- fi
- if test x$plugin_so != x$plugin; then
- plugin_option="--plugin $plugin_so"
- break
- fi
-done
-
-if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
-set dummy ${ac_tool_prefix}ar; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_AR+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$AR"; then
- ac_cv_prog_AR="$AR" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_AR="${ac_tool_prefix}ar"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-AR=$ac_cv_prog_AR
-if test -n "$AR"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
-$as_echo "$AR" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_AR"; then
- ac_ct_AR=$AR
- # Extract the first word of "ar", so it can be a program name with args.
-set dummy ar; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_AR+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_AR"; then
- ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_AR="ar"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_AR=$ac_cv_prog_ac_ct_AR
-if test -n "$ac_ct_AR"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
-$as_echo "$ac_ct_AR" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_AR" = x; then
- AR="false"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- AR=$ac_ct_AR
- fi
-else
- AR="$ac_cv_prog_AR"
-fi
-
-test -z "$AR" && AR=ar
-if test -n "$plugin_option"; then
- if $AR --help 2>&1 | grep -q "\--plugin"; then
- touch conftest.c
- $AR $plugin_option rc conftest.a conftest.c
- if test "$?" != 0; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed: $AR $plugin_option rc" >&5
-$as_echo "$as_me: WARNING: Failed: $AR $plugin_option rc" >&2;}
- else
- AR="$AR $plugin_option"
- fi
- rm -f conftest.*
- fi
-fi
-test -z "$AR_FLAGS" && AR_FLAGS=cru
-
-
-
-
-
-
-
-
-
-
-
-if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
-set dummy ${ac_tool_prefix}strip; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_STRIP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$STRIP"; then
- ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_STRIP="${ac_tool_prefix}strip"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-STRIP=$ac_cv_prog_STRIP
-if test -n "$STRIP"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
-$as_echo "$STRIP" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_STRIP"; then
- ac_ct_STRIP=$STRIP
- # Extract the first word of "strip", so it can be a program name with args.
-set dummy strip; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_STRIP"; then
- ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_STRIP="strip"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
-if test -n "$ac_ct_STRIP"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
-$as_echo "$ac_ct_STRIP" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_STRIP" = x; then
- STRIP=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- STRIP=$ac_ct_STRIP
- fi
-else
- STRIP="$ac_cv_prog_STRIP"
-fi
-
-test -z "$STRIP" && STRIP=:
-
-
-
-
-
-
-if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
-set dummy ${ac_tool_prefix}ranlib; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_RANLIB+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$RANLIB"; then
- ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-RANLIB=$ac_cv_prog_RANLIB
-if test -n "$RANLIB"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
-$as_echo "$RANLIB" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_RANLIB"; then
- ac_ct_RANLIB=$RANLIB
- # Extract the first word of "ranlib", so it can be a program name with args.
-set dummy ranlib; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_RANLIB"; then
- ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_RANLIB="ranlib"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
-if test -n "$ac_ct_RANLIB"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
-$as_echo "$ac_ct_RANLIB" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_RANLIB" = x; then
- RANLIB=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- RANLIB=$ac_ct_RANLIB
- fi
-else
- RANLIB="$ac_cv_prog_RANLIB"
-fi
-
-test -z "$RANLIB" && RANLIB=:
-if test -n "$plugin_option" && test "$RANLIB" != ":"; then
- if $RANLIB --help 2>&1 | grep -q "\--plugin"; then
- RANLIB="$RANLIB $plugin_option"
- fi
-fi
-
-
-
-
-
-
-# Determine commands to create old-style static archives.
-old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs'
-old_postinstall_cmds='chmod 644 $oldlib'
-old_postuninstall_cmds=
-
-if test -n "$RANLIB"; then
- case $host_os in
- openbsd*)
- old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib"
- ;;
- *)
- old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib"
- ;;
- esac
- old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib"
-fi
-
-case $host_os in
- darwin*)
- lock_old_archive_extraction=yes ;;
- *)
- lock_old_archive_extraction=no ;;
-esac
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-# If no C compiler was specified, use CC.
-LTCC=${LTCC-"$CC"}
-
-# If no C compiler flags were specified, use CFLAGS.
-LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
-
-# Allow CC to be a program name with arguments.
-compiler=$CC
-
-
-# Check for command to grab the raw symbol name followed by C symbol from nm.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking command to parse $NM output from $compiler object" >&5
-$as_echo_n "checking command to parse $NM output from $compiler object... " >&6; }
-if ${lt_cv_sys_global_symbol_pipe+:} false; then :
- $as_echo_n "(cached) " >&6
-else
-
-# These are sane defaults that work on at least a few old systems.
-# [They come from Ultrix. What could be older than Ultrix?!! ;)]
-
-# Character class describing NM global symbol codes.
-symcode='[BCDEGRST]'
-
-# Regexp to match symbols that can be accessed directly from C.
-sympat='\([_A-Za-z][_A-Za-z0-9]*\)'
-
-# Define system-specific variables.
-case $host_os in
-aix*)
- symcode='[BCDT]'
- ;;
-cygwin* | mingw* | pw32* | cegcc*)
- symcode='[ABCDGISTW]'
- ;;
-hpux*)
- if test "$host_cpu" = ia64; then
- symcode='[ABCDEGRST]'
- fi
- ;;
-irix* | nonstopux*)
- symcode='[BCDEGRST]'
- ;;
-osf*)
- symcode='[BCDEGQRST]'
- ;;
-solaris*)
- symcode='[BCDRT]'
- ;;
-sco3.2v5*)
- symcode='[DT]'
- ;;
-sysv4.2uw2*)
- symcode='[DT]'
- ;;
-sysv5* | sco5v6* | unixware* | OpenUNIX*)
- symcode='[ABDT]'
- ;;
-sysv4)
- symcode='[DFNSTU]'
- ;;
-esac
-
-# If we're using GNU nm, then use its standard symbol codes.
-case `$NM -V 2>&1` in
-*GNU* | *'with BFD'*)
- symcode='[ABCDGIRSTW]' ;;
-esac
-
-# Transform an extracted symbol line into a proper C declaration.
-# Some systems (esp. on ia64) link data and code symbols differently,
-# so use this general approach.
-lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
-
-# Transform an extracted symbol line into symbol name and symbol address
-lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"\2\", (void *) \&\2},/p'"
-lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \(lib[^ ]*\)$/ {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"lib\2\", (void *) \&\2},/p'"
-
-# Handle CRLF in mingw tool chain
-opt_cr=
-case $build_os in
-mingw*)
- opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp
- ;;
-esac
-
-# Try without a prefix underscore, then with it.
-for ac_symprfx in "" "_"; do
-
- # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
- symxfrm="\\1 $ac_symprfx\\2 \\2"
-
- # Write the raw and C identifiers.
- if test "$lt_cv_nm_interface" = "MS dumpbin"; then
- # Fake it for dumpbin and say T for any non-static function
- # and D for any global variable.
- # Also find C++ and __fastcall symbols from MSVC++,
- # which start with @ or ?.
- lt_cv_sys_global_symbol_pipe="$AWK '"\
-" {last_section=section; section=\$ 3};"\
-" /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\
-" \$ 0!~/External *\|/{next};"\
-" / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\
-" {if(hide[section]) next};"\
-" {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\
-" {split(\$ 0, a, /\||\r/); split(a[2], s)};"\
-" s[1]~/^[@?]/{print s[1], s[1]; next};"\
-" s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\
-" ' prfx=^$ac_symprfx"
- else
- lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[ ]\($symcode$symcode*\)[ ][ ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
- fi
-
- # Check to see that the pipe works correctly.
- pipe_works=no
-
- rm -f conftest*
- cat > conftest.$ac_ext <<_LT_EOF
-#ifdef __cplusplus
-extern "C" {
-#endif
-char nm_test_var;
-void nm_test_func(void);
-void nm_test_func(void){}
-#ifdef __cplusplus
-}
-#endif
-int main(){nm_test_var='a';nm_test_func();return(0);}
-_LT_EOF
-
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
- (eval $ac_compile) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- # Now try to grab the symbols.
- nlist=conftest.nm
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist\""; } >&5
- (eval $NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && test -s "$nlist"; then
- # Try sorting and uniquifying the output.
- if sort "$nlist" | uniq > "$nlist"T; then
- mv -f "$nlist"T "$nlist"
- else
- rm -f "$nlist"T
- fi
-
- # Make sure that we snagged all the symbols we need.
- if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
- if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
- cat <<_LT_EOF > conftest.$ac_ext
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-_LT_EOF
- # Now generate the symbol file.
- eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext'
-
- cat <<_LT_EOF >> conftest.$ac_ext
-
-/* The mapping between symbol names and symbols. */
-const struct {
- const char *name;
- void *address;
-}
-lt__PROGRAM__LTX_preloaded_symbols[] =
-{
- { "@PROGRAM@", (void *) 0 },
-_LT_EOF
- $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext
- cat <<\_LT_EOF >> conftest.$ac_ext
- {0, (void *) 0}
-};
-
-/* This works around a problem in FreeBSD linker */
-#ifdef FREEBSD_WORKAROUND
-static const void *lt_preloaded_setup() {
- return lt__PROGRAM__LTX_preloaded_symbols;
-}
-#endif
-
-#ifdef __cplusplus
-}
-#endif
-_LT_EOF
- # Now try linking the two files.
- mv conftest.$ac_objext conftstm.$ac_objext
- lt_save_LIBS="$LIBS"
- lt_save_CFLAGS="$CFLAGS"
- LIBS="conftstm.$ac_objext"
- CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag"
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
- (eval $ac_link) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && test -s conftest${ac_exeext}; then
- pipe_works=yes
- fi
- LIBS="$lt_save_LIBS"
- CFLAGS="$lt_save_CFLAGS"
- else
- echo "cannot find nm_test_func in $nlist" >&5
- fi
- else
- echo "cannot find nm_test_var in $nlist" >&5
- fi
- else
- echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5
- fi
- else
- echo "$progname: failed program was:" >&5
- cat conftest.$ac_ext >&5
- fi
- rm -rf conftest* conftst*
-
- # Do not use the global_symbol_pipe unless it works.
- if test "$pipe_works" = yes; then
- break
- else
- lt_cv_sys_global_symbol_pipe=
- fi
-done
-
-fi
-
-if test -z "$lt_cv_sys_global_symbol_pipe"; then
- lt_cv_sys_global_symbol_to_cdecl=
-fi
-if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
-$as_echo "failed" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
-$as_echo "ok" >&6; }
-fi
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-# Check whether --enable-libtool-lock was given.
-if test "${enable_libtool_lock+set}" = set; then :
- enableval=$enable_libtool_lock;
-fi
-
-test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
-
-# Some flags need to be propagated to the compiler or linker for good
-# libtool support.
-case $host in
-ia64-*-hpux*)
- # Find out which ABI we are using.
- echo 'int i;' > conftest.$ac_ext
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
- (eval $ac_compile) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- case `/usr/bin/file conftest.$ac_objext` in
- *ELF-32*)
- HPUX_IA64_MODE="32"
- ;;
- *ELF-64*)
- HPUX_IA64_MODE="64"
- ;;
- esac
- fi
- rm -rf conftest*
- ;;
-*-*-irix6*)
- # Find out which ABI we are using.
- echo '#line '$LINENO' "configure"' > conftest.$ac_ext
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
- (eval $ac_compile) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- if test "$lt_cv_prog_gnu_ld" = yes; then
- case `/usr/bin/file conftest.$ac_objext` in
- *32-bit*)
- LD="${LD-ld} -melf32bsmip"
- ;;
- *N32*)
- LD="${LD-ld} -melf32bmipn32"
- ;;
- *64-bit*)
- LD="${LD-ld} -melf64bmip"
- ;;
- esac
- else
- case `/usr/bin/file conftest.$ac_objext` in
- *32-bit*)
- LD="${LD-ld} -32"
- ;;
- *N32*)
- LD="${LD-ld} -n32"
- ;;
- *64-bit*)
- LD="${LD-ld} -64"
- ;;
- esac
- fi
- fi
- rm -rf conftest*
- ;;
-
-x86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \
-s390*-*linux*|s390*-*tpf*|sparc*-*linux*)
- # Find out which ABI we are using.
- echo 'int i;' > conftest.$ac_ext
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
- (eval $ac_compile) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- case `/usr/bin/file conftest.o` in
- *32-bit*)
- case $host in
- x86_64-*kfreebsd*-gnu)
- LD="${LD-ld} -m elf_i386_fbsd"
- ;;
- x86_64-*linux*)
- case `/usr/bin/file conftest.o` in
- *x86-64*)
- LD="${LD-ld} -m elf32_x86_64"
- ;;
- *)
- LD="${LD-ld} -m elf_i386"
- ;;
- esac
- ;;
- powerpc64le-*linux*)
- LD="${LD-ld} -m elf32lppclinux"
- ;;
- powerpc64-*linux*)
- LD="${LD-ld} -m elf32ppclinux"
- ;;
- s390x-*linux*)
- LD="${LD-ld} -m elf_s390"
- ;;
- sparc64-*linux*)
- LD="${LD-ld} -m elf32_sparc"
- ;;
- esac
- ;;
- *64-bit*)
- case $host in
- x86_64-*kfreebsd*-gnu)
- LD="${LD-ld} -m elf_x86_64_fbsd"
- ;;
- x86_64-*linux*)
- LD="${LD-ld} -m elf_x86_64"
- ;;
- powerpcle-*linux*)
- LD="${LD-ld} -m elf64lppc"
- ;;
- powerpc-*linux*)
- LD="${LD-ld} -m elf64ppc"
- ;;
- s390*-*linux*|s390*-*tpf*)
- LD="${LD-ld} -m elf64_s390"
- ;;
- sparc*-*linux*)
- LD="${LD-ld} -m elf64_sparc"
- ;;
- esac
- ;;
- esac
- fi
- rm -rf conftest*
- ;;
-
-*-*-sco3.2v5*)
- # On SCO OpenServer 5, we need -belf to get full-featured binaries.
- SAVE_CFLAGS="$CFLAGS"
- CFLAGS="$CFLAGS -belf"
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler needs -belf" >&5
-$as_echo_n "checking whether the C compiler needs -belf... " >&6; }
-if ${lt_cv_cc_needs_belf+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- lt_cv_cc_needs_belf=yes
-else
- lt_cv_cc_needs_belf=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_cc_needs_belf" >&5
-$as_echo "$lt_cv_cc_needs_belf" >&6; }
- if test x"$lt_cv_cc_needs_belf" != x"yes"; then
- # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
- CFLAGS="$SAVE_CFLAGS"
- fi
- ;;
-sparc*-*solaris*)
- # Find out which ABI we are using.
- echo 'int i;' > conftest.$ac_ext
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
- (eval $ac_compile) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- case `/usr/bin/file conftest.o` in
- *64-bit*)
- case $lt_cv_prog_gnu_ld in
- yes*) LD="${LD-ld} -m elf64_sparc" ;;
- *)
- if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then
- LD="${LD-ld} -64"
- fi
- ;;
- esac
- ;;
- esac
- fi
- rm -rf conftest*
- ;;
-esac
-
-need_locks="$enable_libtool_lock"
-
-
- case $host_os in
- rhapsody* | darwin*)
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}dsymutil", so it can be a program name with args.
-set dummy ${ac_tool_prefix}dsymutil; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_DSYMUTIL+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$DSYMUTIL"; then
- ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_DSYMUTIL="${ac_tool_prefix}dsymutil"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-DSYMUTIL=$ac_cv_prog_DSYMUTIL
-if test -n "$DSYMUTIL"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5
-$as_echo "$DSYMUTIL" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_DSYMUTIL"; then
- ac_ct_DSYMUTIL=$DSYMUTIL
- # Extract the first word of "dsymutil", so it can be a program name with args.
-set dummy dsymutil; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_DSYMUTIL+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_DSYMUTIL"; then
- ac_cv_prog_ac_ct_DSYMUTIL="$ac_ct_DSYMUTIL" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_DSYMUTIL="dsymutil"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_DSYMUTIL=$ac_cv_prog_ac_ct_DSYMUTIL
-if test -n "$ac_ct_DSYMUTIL"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DSYMUTIL" >&5
-$as_echo "$ac_ct_DSYMUTIL" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_DSYMUTIL" = x; then
- DSYMUTIL=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- DSYMUTIL=$ac_ct_DSYMUTIL
- fi
-else
- DSYMUTIL="$ac_cv_prog_DSYMUTIL"
-fi
-
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}nmedit", so it can be a program name with args.
-set dummy ${ac_tool_prefix}nmedit; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_NMEDIT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$NMEDIT"; then
- ac_cv_prog_NMEDIT="$NMEDIT" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_NMEDIT="${ac_tool_prefix}nmedit"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-NMEDIT=$ac_cv_prog_NMEDIT
-if test -n "$NMEDIT"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NMEDIT" >&5
-$as_echo "$NMEDIT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_NMEDIT"; then
- ac_ct_NMEDIT=$NMEDIT
- # Extract the first word of "nmedit", so it can be a program name with args.
-set dummy nmedit; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_NMEDIT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_NMEDIT"; then
- ac_cv_prog_ac_ct_NMEDIT="$ac_ct_NMEDIT" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_NMEDIT="nmedit"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_NMEDIT=$ac_cv_prog_ac_ct_NMEDIT
-if test -n "$ac_ct_NMEDIT"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NMEDIT" >&5
-$as_echo "$ac_ct_NMEDIT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_NMEDIT" = x; then
- NMEDIT=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- NMEDIT=$ac_ct_NMEDIT
- fi
-else
- NMEDIT="$ac_cv_prog_NMEDIT"
-fi
-
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}lipo", so it can be a program name with args.
-set dummy ${ac_tool_prefix}lipo; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_LIPO+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$LIPO"; then
- ac_cv_prog_LIPO="$LIPO" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_LIPO="${ac_tool_prefix}lipo"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-LIPO=$ac_cv_prog_LIPO
-if test -n "$LIPO"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5
-$as_echo "$LIPO" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_LIPO"; then
- ac_ct_LIPO=$LIPO
- # Extract the first word of "lipo", so it can be a program name with args.
-set dummy lipo; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_LIPO+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_LIPO"; then
- ac_cv_prog_ac_ct_LIPO="$ac_ct_LIPO" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_LIPO="lipo"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_LIPO=$ac_cv_prog_ac_ct_LIPO
-if test -n "$ac_ct_LIPO"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LIPO" >&5
-$as_echo "$ac_ct_LIPO" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_LIPO" = x; then
- LIPO=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- LIPO=$ac_ct_LIPO
- fi
-else
- LIPO="$ac_cv_prog_LIPO"
-fi
-
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}otool", so it can be a program name with args.
-set dummy ${ac_tool_prefix}otool; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_OTOOL+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$OTOOL"; then
- ac_cv_prog_OTOOL="$OTOOL" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_OTOOL="${ac_tool_prefix}otool"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-OTOOL=$ac_cv_prog_OTOOL
-if test -n "$OTOOL"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5
-$as_echo "$OTOOL" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_OTOOL"; then
- ac_ct_OTOOL=$OTOOL
- # Extract the first word of "otool", so it can be a program name with args.
-set dummy otool; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_OTOOL+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_OTOOL"; then
- ac_cv_prog_ac_ct_OTOOL="$ac_ct_OTOOL" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_OTOOL="otool"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_OTOOL=$ac_cv_prog_ac_ct_OTOOL
-if test -n "$ac_ct_OTOOL"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL" >&5
-$as_echo "$ac_ct_OTOOL" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_OTOOL" = x; then
- OTOOL=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- OTOOL=$ac_ct_OTOOL
- fi
-else
- OTOOL="$ac_cv_prog_OTOOL"
-fi
-
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}otool64", so it can be a program name with args.
-set dummy ${ac_tool_prefix}otool64; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_OTOOL64+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$OTOOL64"; then
- ac_cv_prog_OTOOL64="$OTOOL64" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_OTOOL64="${ac_tool_prefix}otool64"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-OTOOL64=$ac_cv_prog_OTOOL64
-if test -n "$OTOOL64"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL64" >&5
-$as_echo "$OTOOL64" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_OTOOL64"; then
- ac_ct_OTOOL64=$OTOOL64
- # Extract the first word of "otool64", so it can be a program name with args.
-set dummy otool64; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_OTOOL64+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_OTOOL64"; then
- ac_cv_prog_ac_ct_OTOOL64="$ac_ct_OTOOL64" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_OTOOL64="otool64"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_OTOOL64=$ac_cv_prog_ac_ct_OTOOL64
-if test -n "$ac_ct_OTOOL64"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL64" >&5
-$as_echo "$ac_ct_OTOOL64" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_OTOOL64" = x; then
- OTOOL64=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- OTOOL64=$ac_ct_OTOOL64
- fi
-else
- OTOOL64="$ac_cv_prog_OTOOL64"
-fi
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -single_module linker flag" >&5
-$as_echo_n "checking for -single_module linker flag... " >&6; }
-if ${lt_cv_apple_cc_single_mod+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_apple_cc_single_mod=no
- if test -z "${LT_MULTI_MODULE}"; then
- # By default we will add the -single_module flag. You can override
- # by either setting the environment variable LT_MULTI_MODULE
- # non-empty at configure time, or by adding -multi_module to the
- # link flags.
- rm -rf libconftest.dylib*
- echo "int foo(void){return 1;}" > conftest.c
- echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
--dynamiclib -Wl,-single_module conftest.c" >&5
- $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
- -dynamiclib -Wl,-single_module conftest.c 2>conftest.err
- _lt_result=$?
- if test -f libconftest.dylib && test ! -s conftest.err && test $_lt_result = 0; then
- lt_cv_apple_cc_single_mod=yes
- else
- cat conftest.err >&5
- fi
- rm -rf libconftest.dylib*
- rm -f conftest.*
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_apple_cc_single_mod" >&5
-$as_echo "$lt_cv_apple_cc_single_mod" >&6; }
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -exported_symbols_list linker flag" >&5
-$as_echo_n "checking for -exported_symbols_list linker flag... " >&6; }
-if ${lt_cv_ld_exported_symbols_list+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_ld_exported_symbols_list=no
- save_LDFLAGS=$LDFLAGS
- echo "_main" > conftest.sym
- LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- lt_cv_ld_exported_symbols_list=yes
-else
- lt_cv_ld_exported_symbols_list=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LDFLAGS="$save_LDFLAGS"
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_exported_symbols_list" >&5
-$as_echo "$lt_cv_ld_exported_symbols_list" >&6; }
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -force_load linker flag" >&5
-$as_echo_n "checking for -force_load linker flag... " >&6; }
-if ${lt_cv_ld_force_load+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_ld_force_load=no
- cat > conftest.c << _LT_EOF
-int forced_loaded() { return 2;}
-_LT_EOF
- echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&5
- $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5
- echo "$AR cru libconftest.a conftest.o" >&5
- $AR cru libconftest.a conftest.o 2>&5
- cat > conftest.c << _LT_EOF
-int main() { return 0;}
-_LT_EOF
- echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&5
- $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err
- _lt_result=$?
- if test -f conftest && test ! -s conftest.err && test $_lt_result = 0 && $GREP forced_load conftest 2>&1 >/dev/null; then
- lt_cv_ld_force_load=yes
- else
- cat conftest.err >&5
- fi
- rm -f conftest.err libconftest.a conftest conftest.c
- rm -rf conftest.dSYM
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_force_load" >&5
-$as_echo "$lt_cv_ld_force_load" >&6; }
- # Allow for Darwin 4-7 (macOS 10.0-10.3) although these are not expect to
- # build without first building modern cctools / linker.
- case $host_cpu-$host_os in
- *-rhapsody* | *-darwin1.[012])
- _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;;
- *-darwin1.*)
- _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
- *-darwin*)
- # darwin 5.x (macOS 10.1) onwards we only need to adjust when the
- # deployment target is forced to an earlier version.
- case ${MACOSX_DEPLOYMENT_TARGET-UNSET},$host in
- UNSET,*-darwin[89]*|UNSET,*-darwin[12][0123456789]*)
- ;;
- 10.[012][,.]*)
- _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
- ;;
- *)
- ;;
- esac
- ;;
- esac
- if test "$lt_cv_apple_cc_single_mod" = "yes"; then
- _lt_dar_single_mod='$single_module'
- fi
- if test "$lt_cv_ld_exported_symbols_list" = "yes"; then
- _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym'
- else
- _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}'
- fi
- if test "$DSYMUTIL" != ":" && test "$lt_cv_ld_force_load" = "no"; then
- _lt_dsymutil='~$DSYMUTIL $lib || :'
- else
- _lt_dsymutil=
- fi
- ;;
- esac
-
-for ac_header in dlfcn.h
-do :
- ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default
-"
-if test "x$ac_cv_header_dlfcn_h" = xyes; then :
- cat >>confdefs.h <<_ACEOF
-#define HAVE_DLFCN_H 1
-_ACEOF
-
-fi
-
-done
-
-
-
-
-
-# Set options
-
-
-
- enable_dlopen=no
-
-
- enable_win32_dll=no
-
-
- # Check whether --enable-shared was given.
-if test "${enable_shared+set}" = set; then :
- enableval=$enable_shared; p=${PACKAGE-default}
- case $enableval in
- yes) enable_shared=yes ;;
- no) enable_shared=no ;;
- *)
- enable_shared=no
- # Look at the argument we got. We use all the common list separators.
- lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
- for pkg in $enableval; do
- IFS="$lt_save_ifs"
- if test "X$pkg" = "X$p"; then
- enable_shared=yes
- fi
- done
- IFS="$lt_save_ifs"
- ;;
- esac
-else
- enable_shared=yes
-fi
-
-
-
-
-
-
-
-
-
- # Check whether --enable-static was given.
-if test "${enable_static+set}" = set; then :
- enableval=$enable_static; p=${PACKAGE-default}
- case $enableval in
- yes) enable_static=yes ;;
- no) enable_static=no ;;
- *)
- enable_static=no
- # Look at the argument we got. We use all the common list separators.
- lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
- for pkg in $enableval; do
- IFS="$lt_save_ifs"
- if test "X$pkg" = "X$p"; then
- enable_static=yes
- fi
- done
- IFS="$lt_save_ifs"
- ;;
- esac
-else
- enable_static=yes
-fi
-
-
-
-
-
-
-
-
-
-
-# Check whether --with-pic was given.
-if test "${with_pic+set}" = set; then :
- withval=$with_pic; pic_mode="$withval"
-else
- pic_mode=default
-fi
-
-
-test -z "$pic_mode" && pic_mode=default
-
-
-
-
-
-
-
- # Check whether --enable-fast-install was given.
-if test "${enable_fast_install+set}" = set; then :
- enableval=$enable_fast_install; p=${PACKAGE-default}
- case $enableval in
- yes) enable_fast_install=yes ;;
- no) enable_fast_install=no ;;
- *)
- enable_fast_install=no
- # Look at the argument we got. We use all the common list separators.
- lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
- for pkg in $enableval; do
- IFS="$lt_save_ifs"
- if test "X$pkg" = "X$p"; then
- enable_fast_install=yes
- fi
- done
- IFS="$lt_save_ifs"
- ;;
- esac
-else
- enable_fast_install=yes
-fi
-
-
-
-
-
-
-
-
-
-
-
-# This can be used to rebuild libtool when needed
-LIBTOOL_DEPS="$ltmain"
-
-# Always use our own libtool.
-LIBTOOL='$(SHELL) $(top_builddir)/libtool'
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-test -z "$LN_S" && LN_S="ln -s"
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-if test -n "${ZSH_VERSION+set}" ; then
- setopt NO_GLOB_SUBST
-fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for objdir" >&5
-$as_echo_n "checking for objdir... " >&6; }
-if ${lt_cv_objdir+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- rm -f .libs 2>/dev/null
-mkdir .libs 2>/dev/null
-if test -d .libs; then
- lt_cv_objdir=.libs
-else
- # MS-DOS does not allow filenames that begin with a dot.
- lt_cv_objdir=_libs
-fi
-rmdir .libs 2>/dev/null
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_objdir" >&5
-$as_echo "$lt_cv_objdir" >&6; }
-objdir=$lt_cv_objdir
-
-
-
-
-
-cat >>confdefs.h <<_ACEOF
-#define LT_OBJDIR "$lt_cv_objdir/"
-_ACEOF
-
-
-
-
-case $host_os in
-aix3*)
- # AIX sometimes has problems with the GCC collect2 program. For some
- # reason, if we set the COLLECT_NAMES environment variable, the problems
- # vanish in a puff of smoke.
- if test "X${COLLECT_NAMES+set}" != Xset; then
- COLLECT_NAMES=
- export COLLECT_NAMES
- fi
- ;;
-esac
-
-# Global variables:
-ofile=libtool
-can_build_shared=yes
-
-# All known linkers require a `.a' archive for static linking (except MSVC,
-# which needs '.lib').
-libext=a
-
-with_gnu_ld="$lt_cv_prog_gnu_ld"
-
-old_CC="$CC"
-old_CFLAGS="$CFLAGS"
-
-# Set sane defaults for various variables
-test -z "$CC" && CC=cc
-test -z "$LTCC" && LTCC=$CC
-test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
-test -z "$LD" && LD=ld
-test -z "$ac_objext" && ac_objext=o
-
-for cc_temp in $compiler""; do
- case $cc_temp in
- compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
- distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
- \-*) ;;
- *) break;;
- esac
-done
-cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
-
-
-# Only perform the check for file, if the check method requires it
-test -z "$MAGIC_CMD" && MAGIC_CMD=file
-case $deplibs_check_method in
-file_magic*)
- if test "$file_magic_cmd" = '$MAGIC_CMD'; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ac_tool_prefix}file" >&5
-$as_echo_n "checking for ${ac_tool_prefix}file... " >&6; }
-if ${lt_cv_path_MAGIC_CMD+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $MAGIC_CMD in
-[\\/*] | ?:[\\/]*)
- lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
- ;;
-*)
- lt_save_MAGIC_CMD="$MAGIC_CMD"
- lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
- ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
- for ac_dir in $ac_dummy; do
- IFS="$lt_save_ifs"
- test -z "$ac_dir" && ac_dir=.
- if test -f $ac_dir/${ac_tool_prefix}file; then
- lt_cv_path_MAGIC_CMD="$ac_dir/${ac_tool_prefix}file"
- if test -n "$file_magic_test_file"; then
- case $deplibs_check_method in
- "file_magic "*)
- file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
- MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
- if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
- $EGREP "$file_magic_regex" > /dev/null; then
- :
- else
- cat <<_LT_EOF 1>&2
-
-*** Warning: the command libtool uses to detect shared libraries,
-*** $file_magic_cmd, produces output that libtool cannot recognize.
-*** The result is that libtool may fail to recognize shared libraries
-*** as such. This will affect the creation of libtool libraries that
-*** depend on shared libraries, but programs linked with such libtool
-*** libraries will work regardless of this problem. Nevertheless, you
-*** may want to report the problem to your system manager and/or to
-*** bug-libtool@gnu.org
-
-_LT_EOF
- fi ;;
- esac
- fi
- break
- fi
- done
- IFS="$lt_save_ifs"
- MAGIC_CMD="$lt_save_MAGIC_CMD"
- ;;
-esac
-fi
-
-MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
-if test -n "$MAGIC_CMD"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5
-$as_echo "$MAGIC_CMD" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-
-
-
-if test -z "$lt_cv_path_MAGIC_CMD"; then
- if test -n "$ac_tool_prefix"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for file" >&5
-$as_echo_n "checking for file... " >&6; }
-if ${lt_cv_path_MAGIC_CMD+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $MAGIC_CMD in
-[\\/*] | ?:[\\/]*)
- lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
- ;;
-*)
- lt_save_MAGIC_CMD="$MAGIC_CMD"
- lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
- ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
- for ac_dir in $ac_dummy; do
- IFS="$lt_save_ifs"
- test -z "$ac_dir" && ac_dir=.
- if test -f $ac_dir/file; then
- lt_cv_path_MAGIC_CMD="$ac_dir/file"
- if test -n "$file_magic_test_file"; then
- case $deplibs_check_method in
- "file_magic "*)
- file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
- MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
- if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
- $EGREP "$file_magic_regex" > /dev/null; then
- :
- else
- cat <<_LT_EOF 1>&2
-
-*** Warning: the command libtool uses to detect shared libraries,
-*** $file_magic_cmd, produces output that libtool cannot recognize.
-*** The result is that libtool may fail to recognize shared libraries
-*** as such. This will affect the creation of libtool libraries that
-*** depend on shared libraries, but programs linked with such libtool
-*** libraries will work regardless of this problem. Nevertheless, you
-*** may want to report the problem to your system manager and/or to
-*** bug-libtool@gnu.org
-
-_LT_EOF
- fi ;;
- esac
- fi
- break
- fi
- done
- IFS="$lt_save_ifs"
- MAGIC_CMD="$lt_save_MAGIC_CMD"
- ;;
-esac
-fi
-
-MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
-if test -n "$MAGIC_CMD"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5
-$as_echo "$MAGIC_CMD" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- else
- MAGIC_CMD=:
- fi
-fi
-
- fi
- ;;
-esac
-
-# Use C for the default configuration in the libtool script
-
-lt_save_CC="$CC"
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-
-# Source file extension for C test sources.
-ac_ext=c
-
-# Object file extension for compiled C test sources.
-objext=o
-objext=$objext
-
-# Code to be used in simple compile tests
-lt_simple_compile_test_code="int some_variable = 0;"
-
-# Code to be used in simple link tests
-lt_simple_link_test_code='int main(){return(0);}'
-
-
-
-
-
-
-
-# If no C compiler was specified, use CC.
-LTCC=${LTCC-"$CC"}
-
-# If no C compiler flags were specified, use CFLAGS.
-LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
-
-# Allow CC to be a program name with arguments.
-compiler=$CC
-
-# Save the default compiler, since it gets overwritten when the other
-# tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP.
-compiler_DEFAULT=$CC
-
-# save warnings/boilerplate of simple test code
-ac_outfile=conftest.$ac_objext
-echo "$lt_simple_compile_test_code" >conftest.$ac_ext
-eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
-_lt_compiler_boilerplate=`cat conftest.err`
-$RM conftest*
-
-ac_outfile=conftest.$ac_objext
-echo "$lt_simple_link_test_code" >conftest.$ac_ext
-eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
-_lt_linker_boilerplate=`cat conftest.err`
-$RM -r conftest*
-
-
-## CAVEAT EMPTOR:
-## There is no encapsulation within the following macros, do not change
-## the running order or otherwise move them around unless you know exactly
-## what you are doing...
-if test -n "$compiler"; then
-
-lt_prog_compiler_no_builtin_flag=
-
-if test "$GCC" = yes; then
- case $cc_basename in
- nvcc*)
- lt_prog_compiler_no_builtin_flag=' -Xcompiler -fno-builtin' ;;
- *)
- lt_prog_compiler_no_builtin_flag=' -fno-builtin' ;;
- esac
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -fno-rtti -fno-exceptions" >&5
-$as_echo_n "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; }
-if ${lt_cv_prog_compiler_rtti_exceptions+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_prog_compiler_rtti_exceptions=no
- ac_outfile=conftest.$ac_objext
- echo "$lt_simple_compile_test_code" > conftest.$ac_ext
- lt_compiler_flag="-fno-rtti -fno-exceptions"
- # Insert the option either (1) after the last *FLAGS variable, or
- # (2) before a word containing "conftest.", or (3) at the end.
- # Note that $ac_compile itself does not contain backslashes and begins
- # with a dollar sign (not a hyphen), so the echo should work correctly.
- # The option is referenced via a variable to avoid confusing sed.
- lt_compile=`echo "$ac_compile" | $SED \
- -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
- -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
- -e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
- (eval "$lt_compile" 2>conftest.err)
- ac_status=$?
- cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- if (exit $ac_status) && test -s "$ac_outfile"; then
- # The compiler can only warn and ignore the option if not recognized
- # So say no if there are warnings other than the usual output.
- $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
- $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
- if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
- lt_cv_prog_compiler_rtti_exceptions=yes
- fi
- fi
- $RM conftest*
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_rtti_exceptions" >&5
-$as_echo "$lt_cv_prog_compiler_rtti_exceptions" >&6; }
-
-if test x"$lt_cv_prog_compiler_rtti_exceptions" = xyes; then
- lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions"
-else
- :
-fi
-
-fi
-
-
-
-
-
-
- lt_prog_compiler_wl=
-lt_prog_compiler_pic=
-lt_prog_compiler_static=
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
-$as_echo_n "checking for $compiler option to produce PIC... " >&6; }
-
- if test "$GCC" = yes; then
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_static='-static'
-
- case $host_os in
- aix*)
- # All AIX code is PIC.
- if test "$host_cpu" = ia64; then
- # AIX 5 now supports IA64 processor
- lt_prog_compiler_static='-Bstatic'
- fi
- lt_prog_compiler_pic='-fPIC'
- ;;
-
- amigaos*)
- case $host_cpu in
- powerpc)
- # see comment about AmigaOS4 .so support
- lt_prog_compiler_pic='-fPIC'
- ;;
- m68k)
- # FIXME: we need at least 68020 code to build shared libraries, but
- # adding the `-m68020' flag to GCC prevents building anything better,
- # like `-m68040'.
- lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4'
- ;;
- esac
- ;;
-
- beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
- # PIC is the default for these OSes.
- ;;
-
- mingw* | cygwin* | pw32* | os2* | cegcc*)
- # This hack is so that the source file can tell whether it is being
- # built for inclusion in a dll (and should export symbols for example).
- # Although the cygwin gcc ignores -fPIC, still need this for old-style
- # (--disable-auto-import) libraries
- lt_prog_compiler_pic='-DDLL_EXPORT'
- ;;
-
- darwin* | rhapsody*)
- # PIC is the default on this platform
- # Common symbols not allowed in MH_DYLIB files
- lt_prog_compiler_pic='-fno-common'
- ;;
-
- haiku*)
- # PIC is the default for Haiku.
- # The "-static" flag exists, but is broken.
- lt_prog_compiler_static=
- ;;
-
- hpux*)
- # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
- # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag
- # sets the default TLS model and affects inlining.
- case $host_cpu in
- hppa*64*)
- # +Z the default
- ;;
- *)
- lt_prog_compiler_pic='-fPIC'
- ;;
- esac
- ;;
-
- interix[3-9]*)
- # Interix 3.x gcc -fpic/-fPIC options generate broken code.
- # Instead, we relocate shared libraries at runtime.
- ;;
-
- msdosdjgpp*)
- # Just because we use GCC doesn't mean we suddenly get shared libraries
- # on systems that don't support them.
- lt_prog_compiler_can_build_shared=no
- enable_shared=no
- ;;
-
- *nto* | *qnx*)
- # QNX uses GNU C++, but need to define -shared option too, otherwise
- # it will coredump.
- lt_prog_compiler_pic='-fPIC -shared'
- ;;
-
- sysv4*MP*)
- if test -d /usr/nec; then
- lt_prog_compiler_pic=-Kconform_pic
- fi
- ;;
-
- *)
- lt_prog_compiler_pic='-fPIC'
- ;;
- esac
-
- case $cc_basename in
- nvcc*) # Cuda Compiler Driver 2.2
- lt_prog_compiler_wl='-Xlinker '
- lt_prog_compiler_pic='-Xcompiler -fPIC'
- ;;
- esac
- else
- # PORTME Check for flag to pass linker flags through the system compiler.
- case $host_os in
- aix*)
- lt_prog_compiler_wl='-Wl,'
- if test "$host_cpu" = ia64; then
- # AIX 5 now supports IA64 processor
- lt_prog_compiler_static='-Bstatic'
- else
- lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp'
- fi
- ;;
-
- mingw* | cygwin* | pw32* | os2* | cegcc*)
- # This hack is so that the source file can tell whether it is being
- # built for inclusion in a dll (and should export symbols for example).
- lt_prog_compiler_pic='-DDLL_EXPORT'
- ;;
-
- hpux9* | hpux10* | hpux11*)
- lt_prog_compiler_wl='-Wl,'
- # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
- # not for PA HP-UX.
- case $host_cpu in
- hppa*64*|ia64*)
- # +Z the default
- ;;
- *)
- lt_prog_compiler_pic='+Z'
- ;;
- esac
- # Is there a better lt_prog_compiler_static that works with the bundled CC?
- lt_prog_compiler_static='${wl}-a ${wl}archive'
- ;;
-
- irix5* | irix6* | nonstopux*)
- lt_prog_compiler_wl='-Wl,'
- # PIC (with -KPIC) is the default.
- lt_prog_compiler_static='-non_shared'
- ;;
-
- linux* | k*bsd*-gnu | kopensolaris*-gnu)
- case $cc_basename in
- # old Intel for x86_64 which still supported -KPIC.
- ecc*)
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_pic='-KPIC'
- lt_prog_compiler_static='-static'
- ;;
- # icc used to be incompatible with GCC.
- # ICC 10 doesn't accept -KPIC any more.
- icc* | ifort*)
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_pic='-fPIC'
- lt_prog_compiler_static='-static'
- ;;
- # Lahey Fortran 8.1.
- lf95*)
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_pic='--shared'
- lt_prog_compiler_static='--static'
- ;;
- pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
- # Portland Group compilers (*not* the Pentium gcc compiler,
- # which looks to be a dead project)
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_pic='-fpic'
- lt_prog_compiler_static='-Bstatic'
- ;;
- ccc*)
- lt_prog_compiler_wl='-Wl,'
- # All Alpha code is PIC.
- lt_prog_compiler_static='-non_shared'
- ;;
- xl* | bgxl* | bgf* | mpixl*)
- # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_pic='-qpic'
- lt_prog_compiler_static='-qstaticlink'
- ;;
- *)
- case `$CC -V 2>&1 | sed 5q` in
- *Sun\ F* | *Sun*Fortran*)
- # Sun Fortran 8.3 passes all unrecognized flags to the linker
- lt_prog_compiler_pic='-KPIC'
- lt_prog_compiler_static='-Bstatic'
- lt_prog_compiler_wl=''
- ;;
- *Sun\ C*)
- # Sun C 5.9
- lt_prog_compiler_pic='-KPIC'
- lt_prog_compiler_static='-Bstatic'
- lt_prog_compiler_wl='-Wl,'
- ;;
- esac
- ;;
- esac
- ;;
-
- newsos6)
- lt_prog_compiler_pic='-KPIC'
- lt_prog_compiler_static='-Bstatic'
- ;;
-
- *nto* | *qnx*)
- # QNX uses GNU C++, but need to define -shared option too, otherwise
- # it will coredump.
- lt_prog_compiler_pic='-fPIC -shared'
- ;;
-
- osf3* | osf4* | osf5*)
- lt_prog_compiler_wl='-Wl,'
- # All OSF/1 code is PIC.
- lt_prog_compiler_static='-non_shared'
- ;;
-
- rdos*)
- lt_prog_compiler_static='-non_shared'
- ;;
-
- solaris*)
- lt_prog_compiler_pic='-KPIC'
- lt_prog_compiler_static='-Bstatic'
- case $cc_basename in
- f77* | f90* | f95*)
- lt_prog_compiler_wl='-Qoption ld ';;
- *)
- lt_prog_compiler_wl='-Wl,';;
- esac
- ;;
-
- sunos4*)
- lt_prog_compiler_wl='-Qoption ld '
- lt_prog_compiler_pic='-PIC'
- lt_prog_compiler_static='-Bstatic'
- ;;
-
- sysv4 | sysv4.2uw2* | sysv4.3*)
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_pic='-KPIC'
- lt_prog_compiler_static='-Bstatic'
- ;;
-
- sysv4*MP*)
- if test -d /usr/nec ;then
- lt_prog_compiler_pic='-Kconform_pic'
- lt_prog_compiler_static='-Bstatic'
- fi
- ;;
-
- sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_pic='-KPIC'
- lt_prog_compiler_static='-Bstatic'
- ;;
-
- unicos*)
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_can_build_shared=no
- ;;
-
- uts4*)
- lt_prog_compiler_pic='-pic'
- lt_prog_compiler_static='-Bstatic'
- ;;
-
- *)
- lt_prog_compiler_can_build_shared=no
- ;;
- esac
- fi
-
-case $host_os in
- # For platforms which do not support PIC, -DPIC is meaningless:
- *djgpp*)
- lt_prog_compiler_pic=
- ;;
- *)
- lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC"
- ;;
-esac
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_prog_compiler_pic" >&5
-$as_echo "$lt_prog_compiler_pic" >&6; }
-
-
-
-
-
-
-#
-# Check to make sure the PIC flag actually works.
-#
-if test -n "$lt_prog_compiler_pic"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5
-$as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic works... " >&6; }
-if ${lt_cv_prog_compiler_pic_works+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_prog_compiler_pic_works=no
- ac_outfile=conftest.$ac_objext
- echo "$lt_simple_compile_test_code" > conftest.$ac_ext
- lt_compiler_flag="$lt_prog_compiler_pic -DPIC"
- # Insert the option either (1) after the last *FLAGS variable, or
- # (2) before a word containing "conftest.", or (3) at the end.
- # Note that $ac_compile itself does not contain backslashes and begins
- # with a dollar sign (not a hyphen), so the echo should work correctly.
- # The option is referenced via a variable to avoid confusing sed.
- lt_compile=`echo "$ac_compile" | $SED \
- -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
- -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
- -e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
- (eval "$lt_compile" 2>conftest.err)
- ac_status=$?
- cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- if (exit $ac_status) && test -s "$ac_outfile"; then
- # The compiler can only warn and ignore the option if not recognized
- # So say no if there are warnings other than the usual output.
- $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
- $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
- if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
- lt_cv_prog_compiler_pic_works=yes
- fi
- fi
- $RM conftest*
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works" >&5
-$as_echo "$lt_cv_prog_compiler_pic_works" >&6; }
-
-if test x"$lt_cv_prog_compiler_pic_works" = xyes; then
- case $lt_prog_compiler_pic in
- "" | " "*) ;;
- *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;;
- esac
-else
- lt_prog_compiler_pic=
- lt_prog_compiler_can_build_shared=no
-fi
-
-fi
-
-
-
-
-
-
-#
-# Check to make sure the static flag actually works.
-#
-wl=$lt_prog_compiler_wl eval lt_tmp_static_flag=\"$lt_prog_compiler_static\"
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5
-$as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; }
-if ${lt_cv_prog_compiler_static_works+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_prog_compiler_static_works=no
- save_LDFLAGS="$LDFLAGS"
- LDFLAGS="$LDFLAGS $lt_tmp_static_flag"
- echo "$lt_simple_link_test_code" > conftest.$ac_ext
- if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
- # The linker can only warn and ignore the option if not recognized
- # So say no if there are warnings
- if test -s conftest.err; then
- # Append any errors to the config.log.
- cat conftest.err 1>&5
- $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
- $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
- if diff conftest.exp conftest.er2 >/dev/null; then
- lt_cv_prog_compiler_static_works=yes
- fi
- else
- lt_cv_prog_compiler_static_works=yes
- fi
- fi
- $RM -r conftest*
- LDFLAGS="$save_LDFLAGS"
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works" >&5
-$as_echo "$lt_cv_prog_compiler_static_works" >&6; }
-
-if test x"$lt_cv_prog_compiler_static_works" = xyes; then
- :
-else
- lt_prog_compiler_static=
-fi
-
-
-
-
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
-$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
-if ${lt_cv_prog_compiler_c_o+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_prog_compiler_c_o=no
- $RM -r conftest 2>/dev/null
- mkdir conftest
- cd conftest
- mkdir out
- echo "$lt_simple_compile_test_code" > conftest.$ac_ext
-
- lt_compiler_flag="-o out/conftest2.$ac_objext"
- # Insert the option either (1) after the last *FLAGS variable, or
- # (2) before a word containing "conftest.", or (3) at the end.
- # Note that $ac_compile itself does not contain backslashes and begins
- # with a dollar sign (not a hyphen), so the echo should work correctly.
- lt_compile=`echo "$ac_compile" | $SED \
- -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
- -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
- -e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
- (eval "$lt_compile" 2>out/conftest.err)
- ac_status=$?
- cat out/conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- if (exit $ac_status) && test -s out/conftest2.$ac_objext
- then
- # The compiler can only warn and ignore the option if not recognized
- # So say no if there are warnings
- $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
- $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
- if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
- lt_cv_prog_compiler_c_o=yes
- fi
- fi
- chmod u+w . 2>&5
- $RM conftest*
- # SGI C++ compiler will create directory out/ii_files/ for
- # template instantiation
- test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
- $RM out/* && rmdir out
- cd ..
- $RM -r conftest
- $RM conftest*
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5
-$as_echo "$lt_cv_prog_compiler_c_o" >&6; }
-
-
-
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
-$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
-if ${lt_cv_prog_compiler_c_o+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_prog_compiler_c_o=no
- $RM -r conftest 2>/dev/null
- mkdir conftest
- cd conftest
- mkdir out
- echo "$lt_simple_compile_test_code" > conftest.$ac_ext
-
- lt_compiler_flag="-o out/conftest2.$ac_objext"
- # Insert the option either (1) after the last *FLAGS variable, or
- # (2) before a word containing "conftest.", or (3) at the end.
- # Note that $ac_compile itself does not contain backslashes and begins
- # with a dollar sign (not a hyphen), so the echo should work correctly.
- lt_compile=`echo "$ac_compile" | $SED \
- -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
- -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
- -e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
- (eval "$lt_compile" 2>out/conftest.err)
- ac_status=$?
- cat out/conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- if (exit $ac_status) && test -s out/conftest2.$ac_objext
- then
- # The compiler can only warn and ignore the option if not recognized
- # So say no if there are warnings
- $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
- $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
- if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
- lt_cv_prog_compiler_c_o=yes
- fi
- fi
- chmod u+w . 2>&5
- $RM conftest*
- # SGI C++ compiler will create directory out/ii_files/ for
- # template instantiation
- test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
- $RM out/* && rmdir out
- cd ..
- $RM -r conftest
- $RM conftest*
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5
-$as_echo "$lt_cv_prog_compiler_c_o" >&6; }
-
-
-
-
-hard_links="nottested"
-if test "$lt_cv_prog_compiler_c_o" = no && test "$need_locks" != no; then
- # do not overwrite the value of need_locks provided by the user
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5
-$as_echo_n "checking if we can lock with hard links... " >&6; }
- hard_links=yes
- $RM conftest*
- ln conftest.a conftest.b 2>/dev/null && hard_links=no
- touch conftest.a
- ln conftest.a conftest.b 2>&5 || hard_links=no
- ln conftest.a conftest.b 2>/dev/null && hard_links=no
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5
-$as_echo "$hard_links" >&6; }
- if test "$hard_links" = no; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5
-$as_echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;}
- need_locks=warn
- fi
-else
- need_locks=no
-fi
-
-
-
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5
-$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; }
-
- runpath_var=
- allow_undefined_flag=
- always_export_symbols=no
- archive_cmds=
- archive_expsym_cmds=
- compiler_needs_object=no
- enable_shared_with_static_runtimes=no
- export_dynamic_flag_spec=
- export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
- hardcode_automatic=no
- hardcode_direct=no
- hardcode_direct_absolute=no
- hardcode_libdir_flag_spec=
- hardcode_libdir_flag_spec_ld=
- hardcode_libdir_separator=
- hardcode_minus_L=no
- hardcode_shlibpath_var=unsupported
- inherit_rpath=no
- link_all_deplibs=unknown
- module_cmds=
- module_expsym_cmds=
- old_archive_from_new_cmds=
- old_archive_from_expsyms_cmds=
- thread_safe_flag_spec=
- whole_archive_flag_spec=
- # include_expsyms should be a list of space-separated symbols to be *always*
- # included in the symbol list
- include_expsyms=
- # exclude_expsyms can be an extended regexp of symbols to exclude
- # it will be wrapped by ` (' and `)$', so one must not match beginning or
- # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
- # as well as any symbol that contains `d'.
- exclude_expsyms='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'
- # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
- # platforms (ab)use it in PIC code, but their linkers get confused if
- # the symbol is explicitly referenced. Since portable code cannot
- # rely on this symbol name, it's probably fine to never include it in
- # preloaded symbol tables.
- # Exclude shared library initialization/finalization symbols.
- extract_expsyms_cmds=
-
- case $host_os in
- cygwin* | mingw* | pw32* | cegcc*)
- # FIXME: the MSVC++ port hasn't been tested in a loooong time
- # When not using gcc, we currently assume that we are using
- # Microsoft Visual C++.
- if test "$GCC" != yes; then
- with_gnu_ld=no
- fi
- ;;
- interix*)
- # we just hope/assume this is gcc and not c89 (= MSVC++)
- with_gnu_ld=yes
- ;;
- openbsd*)
- with_gnu_ld=no
- ;;
- esac
-
- ld_shlibs=yes
-
- # On some targets, GNU ld is compatible enough with the native linker
- # that we're better off using the native interface for both.
- lt_use_gnu_ld_interface=no
- if test "$with_gnu_ld" = yes; then
- case $host_os in
- aix*)
- # The AIX port of GNU ld has always aspired to compatibility
- # with the native linker. However, as the warning in the GNU ld
- # block says, versions before 2.19.5* couldn't really create working
- # shared libraries, regardless of the interface used.
- case `$LD -v 2>&1` in
- *\ \(GNU\ Binutils\)\ 2.19.5*) ;;
- *\ \(GNU\ Binutils\)\ 2.[2-9]*) ;;
- *\ \(GNU\ Binutils\)\ [3-9]*) ;;
- *)
- lt_use_gnu_ld_interface=yes
- ;;
- esac
- ;;
- *)
- lt_use_gnu_ld_interface=yes
- ;;
- esac
- fi
-
- if test "$lt_use_gnu_ld_interface" = yes; then
- # If archive_cmds runs LD, not CC, wlarc should be empty
- wlarc='${wl}'
-
- # Set some defaults for GNU ld with shared library support. These
- # are reset later if shared libraries are not supported. Putting them
- # here allows them to be overridden if necessary.
- runpath_var=LD_RUN_PATH
- hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
- export_dynamic_flag_spec='${wl}--export-dynamic'
- # ancient GNU ld didn't support --whole-archive et. al.
- if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then
- whole_archive_flag_spec="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
- else
- whole_archive_flag_spec=
- fi
- supports_anon_versioning=no
- case `$LD -v 2>&1` in
- *GNU\ gold*) supports_anon_versioning=yes ;;
- *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11
- *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
- *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
- *\ 2.11.*) ;; # other 2.11 versions
- *) supports_anon_versioning=yes ;;
- esac
-
- # See if GNU ld supports shared libraries.
- case $host_os in
- aix[3-9]*)
- # On AIX/PPC, the GNU linker is very broken
- if test "$host_cpu" != ia64; then
- ld_shlibs=no
- cat <<_LT_EOF 1>&2
-
-*** Warning: the GNU linker, at least up to release 2.19, is reported
-*** to be unable to reliably create shared libraries on AIX.
-*** Therefore, libtool is disabling shared libraries support. If you
-*** really care for shared libraries, you may want to install binutils
-*** 2.20 or above, or modify your PATH so that a non-GNU linker is found.
-*** You will then need to restart the configuration process.
-
-_LT_EOF
- fi
- ;;
-
- amigaos*)
- case $host_cpu in
- powerpc)
- # see comment about AmigaOS4 .so support
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- archive_expsym_cmds=''
- ;;
- m68k)
- archive_cmds='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
- hardcode_libdir_flag_spec='-L$libdir'
- hardcode_minus_L=yes
- ;;
- esac
- ;;
-
- beos*)
- if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
- allow_undefined_flag=unsupported
- # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
- # support --undefined. This deserves some investigation. FIXME
- archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- else
- ld_shlibs=no
- fi
- ;;
-
- cygwin* | mingw* | pw32* | cegcc*)
- # _LT_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless,
- # as there is no search path for DLLs.
- hardcode_libdir_flag_spec='-L$libdir'
- export_dynamic_flag_spec='${wl}--export-all-symbols'
- allow_undefined_flag=unsupported
- always_export_symbols=no
- enable_shared_with_static_runtimes=yes
- export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
-
- if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
- # If the export-symbols file already is a .def file (1st line
- # is EXPORTS), use it as is; otherwise, prepend...
- archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
- cp $export_symbols $output_objdir/$soname.def;
- else
- echo EXPORTS > $output_objdir/$soname.def;
- cat $export_symbols >> $output_objdir/$soname.def;
- fi~
- $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
- else
- ld_shlibs=no
- fi
- ;;
-
- haiku*)
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- link_all_deplibs=yes
- ;;
-
- interix[3-9]*)
- hardcode_direct=no
- hardcode_shlibpath_var=no
- hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
- export_dynamic_flag_spec='${wl}-E'
- # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
- # Instead, shared libraries are loaded at an image base (0x10000000 by
- # default) and relocated if they conflict, which is a slow very memory
- # consuming and fragmenting process. To avoid this, we pick a random,
- # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
- # time. Moving up from 0x10000000 also allows more sbrk(2) space.
- archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
- archive_expsym_cmds='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
- ;;
-
- gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu | uclinuxfdpiceabi)
- tmp_diet=no
- if test "$host_os" = linux-dietlibc; then
- case $cc_basename in
- diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn)
- esac
- fi
- if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
- && test "$tmp_diet" = no
- then
- tmp_addflag=' $pic_flag'
- tmp_sharedflag='-shared'
- case $cc_basename,$host_cpu in
- pgcc*) # Portland Group C compiler
- whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
- tmp_addflag=' $pic_flag'
- ;;
- pgf77* | pgf90* | pgf95* | pgfortran*)
- # Portland Group f77 and f90 compilers
- whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
- tmp_addflag=' $pic_flag -Mnomain' ;;
- ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64
- tmp_addflag=' -i_dynamic' ;;
- efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64
- tmp_addflag=' -i_dynamic -nofor_main' ;;
- ifc* | ifort*) # Intel Fortran compiler
- tmp_addflag=' -nofor_main' ;;
- lf95*) # Lahey Fortran 8.1
- whole_archive_flag_spec=
- tmp_sharedflag='--shared' ;;
- xl[cC]* | bgxl[cC]* | mpixl[cC]*) # IBM XL C 8.0 on PPC (deal with xlf below)
- tmp_sharedflag='-qmkshrobj'
- tmp_addflag= ;;
- nvcc*) # Cuda Compiler Driver 2.2
- whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
- compiler_needs_object=yes
- ;;
- esac
- case `$CC -V 2>&1 | sed 5q` in
- *Sun\ C*) # Sun C 5.9
- whole_archive_flag_spec='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
- compiler_needs_object=yes
- tmp_sharedflag='-G' ;;
- *Sun\ F*) # Sun Fortran 8.3
- tmp_sharedflag='-G' ;;
- esac
- archive_cmds='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
-
- if test "x$supports_anon_versioning" = xyes; then
- archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
- cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
- echo "local: *; };" >> $output_objdir/$libname.ver~
- $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
- fi
-
- case $cc_basename in
- xlf* | bgf* | bgxlf* | mpixlf*)
- # IBM XL Fortran 10.1 on PPC cannot create shared libs itself
- whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive'
- hardcode_libdir_flag_spec=
- hardcode_libdir_flag_spec_ld='-rpath $libdir'
- archive_cmds='$LD -shared $libobjs $deplibs $compiler_flags -soname $soname -o $lib'
- if test "x$supports_anon_versioning" = xyes; then
- archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
- cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
- echo "local: *; };" >> $output_objdir/$libname.ver~
- $LD -shared $libobjs $deplibs $compiler_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
- fi
- ;;
- esac
- else
- ld_shlibs=no
- fi
- ;;
-
- netbsd*)
- if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
- archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
- wlarc=
- else
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
- fi
- ;;
-
- solaris*)
- if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then
- ld_shlibs=no
- cat <<_LT_EOF 1>&2
-
-*** Warning: The releases 2.8.* of the GNU linker cannot reliably
-*** create shared libraries on Solaris systems. Therefore, libtool
-*** is disabling shared libraries support. We urge you to upgrade GNU
-*** binutils to release 2.9.1 or newer. Another option is to modify
-*** your PATH or compiler configuration so that the native linker is
-*** used, and then restart.
-
-_LT_EOF
- elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
- else
- ld_shlibs=no
- fi
- ;;
-
- sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
- case `$LD -v 2>&1` in
- *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*)
- ld_shlibs=no
- cat <<_LT_EOF 1>&2
-
-*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not
-*** reliably create shared libraries on SCO systems. Therefore, libtool
-*** is disabling shared libraries support. We urge you to upgrade GNU
-*** binutils to release 2.16.91.0.3 or newer. Another option is to modify
-*** your PATH or compiler configuration so that the native linker is
-*** used, and then restart.
-
-_LT_EOF
- ;;
- *)
- # For security reasons, it is highly recommended that you always
- # use absolute paths for naming shared libraries, and exclude the
- # DT_RUNPATH tag from executables and libraries. But doing so
- # requires that you compile everything twice, which is a pain.
- if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
- hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
- else
- ld_shlibs=no
- fi
- ;;
- esac
- ;;
-
- sunos4*)
- archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
- wlarc=
- hardcode_direct=yes
- hardcode_shlibpath_var=no
- ;;
-
- *)
- if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
- else
- ld_shlibs=no
- fi
- ;;
- esac
-
- if test "$ld_shlibs" = no; then
- runpath_var=
- hardcode_libdir_flag_spec=
- export_dynamic_flag_spec=
- whole_archive_flag_spec=
- fi
- else
- # PORTME fill in a description of your system's linker (not GNU ld)
- case $host_os in
- aix3*)
- allow_undefined_flag=unsupported
- always_export_symbols=yes
- archive_expsym_cmds='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname'
- # Note: this linker hardcodes the directories in LIBPATH if there
- # are no directories specified by -L.
- hardcode_minus_L=yes
- if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then
- # Neither direct hardcoding nor static linking is supported with a
- # broken collect2.
- hardcode_direct=unsupported
- fi
- ;;
-
- aix[4-9]*)
- if test "$host_cpu" = ia64; then
- # On IA64, the linker does run time linking by default, so we don't
- # have to do anything special.
- aix_use_runtimelinking=no
- exp_sym_flag='-Bexport'
- no_entry_flag=""
- else
- # If we're using GNU nm, then we don't want the "-C" option.
- # -C means demangle to AIX nm, but means don't demangle with GNU nm
- # Also, AIX nm treats weak defined symbols like other global
- # defined symbols, whereas GNU nm marks them as "W".
- if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
- export_symbols_cmds='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
- else
- export_symbols_cmds='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "L")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
- fi
- aix_use_runtimelinking=no
-
- # Test if we are trying to use run time linking or normal
- # AIX style linking. If -brtl is somewhere in LDFLAGS, we
- # need to do runtime linking.
- case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*)
- for ld_flag in $LDFLAGS; do
- if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
- aix_use_runtimelinking=yes
- break
- fi
- done
- ;;
- esac
-
- exp_sym_flag='-bexport'
- no_entry_flag='-bnoentry'
- fi
-
- # When large executables or shared objects are built, AIX ld can
- # have problems creating the table of contents. If linking a library
- # or program results in "error TOC overflow" add -mminimal-toc to
- # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
- # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
-
- archive_cmds=''
- hardcode_direct=yes
- hardcode_direct_absolute=yes
- hardcode_libdir_separator=':'
- link_all_deplibs=yes
- file_list_spec='${wl}-f,'
-
- if test "$GCC" = yes; then
- case $host_os in aix4.[012]|aix4.[012].*)
- # We only want to do this on AIX 4.2 and lower, the check
- # below for broken collect2 doesn't work under 4.3+
- collect2name=`${CC} -print-prog-name=collect2`
- if test -f "$collect2name" &&
- strings "$collect2name" | $GREP resolve_lib_name >/dev/null
- then
- # We have reworked collect2
- :
- else
- # We have old collect2
- hardcode_direct=unsupported
- # It fails to find uninstalled libraries when the uninstalled
- # path is not listed in the libpath. Setting hardcode_minus_L
- # to unsupported forces relinking
- hardcode_minus_L=yes
- hardcode_libdir_flag_spec='-L$libdir'
- hardcode_libdir_separator=
- fi
- ;;
- esac
- shared_flag='-shared'
- if test "$aix_use_runtimelinking" = yes; then
- shared_flag="$shared_flag "'${wl}-G'
- fi
- else
- # not using gcc
- if test "$host_cpu" = ia64; then
- # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
- # chokes on -Wl,-G. The following line is correct:
- shared_flag='-G'
- else
- if test "$aix_use_runtimelinking" = yes; then
- shared_flag='${wl}-G'
- else
- shared_flag='${wl}-bM:SRE'
- fi
- fi
- fi
-
- export_dynamic_flag_spec='${wl}-bexpall'
- # It seems that -bexpall does not export symbols beginning with
- # underscore (_), so it is better to generate a list of symbols to export.
- always_export_symbols=yes
- if test "$aix_use_runtimelinking" = yes; then
- # Warning - without using the other runtime loading flags (-brtl),
- # -berok will link without error, but may produce a broken library.
- allow_undefined_flag='-berok'
- # Determine the default libpath from the value encoded in an
- # empty executable.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
-
-lt_aix_libpath_sed='
- /Import File Strings/,/^$/ {
- /^0/ {
- s/^0 *\(.*\)$/\1/
- p
- }
- }'
-aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
-# Check for a 64-bit object if we didn't find anything.
-if test -z "$aix_libpath"; then
- aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
-fi
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
-
- hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
- archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
- else
- if test "$host_cpu" = ia64; then
- hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib'
- allow_undefined_flag="-z nodefs"
- archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols"
- else
- # Determine the default libpath from the value encoded in an
- # empty executable.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
-
-lt_aix_libpath_sed='
- /Import File Strings/,/^$/ {
- /^0/ {
- s/^0 *\(.*\)$/\1/
- p
- }
- }'
-aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
-# Check for a 64-bit object if we didn't find anything.
-if test -z "$aix_libpath"; then
- aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
-fi
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
-
- hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
- # Warning - without using the other run time loading flags,
- # -berok will link without error, but may produce a broken library.
- no_undefined_flag=' ${wl}-bernotok'
- allow_undefined_flag=' ${wl}-berok'
- if test "$with_gnu_ld" = yes; then
- # We only use this code for GNU lds that support --whole-archive.
- whole_archive_flag_spec='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
- else
- # Exported symbols can be pulled into shared objects from archives
- whole_archive_flag_spec='$convenience'
- fi
- archive_cmds_need_lc=yes
- # This is similar to how AIX traditionally builds its shared libraries.
- archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
- fi
- fi
- ;;
-
- amigaos*)
- case $host_cpu in
- powerpc)
- # see comment about AmigaOS4 .so support
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- archive_expsym_cmds=''
- ;;
- m68k)
- archive_cmds='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
- hardcode_libdir_flag_spec='-L$libdir'
- hardcode_minus_L=yes
- ;;
- esac
- ;;
-
- bsdi[45]*)
- export_dynamic_flag_spec=-rdynamic
- ;;
-
- cygwin* | mingw* | pw32* | cegcc*)
- # When not using gcc, we currently assume that we are using
- # Microsoft Visual C++.
- # hardcode_libdir_flag_spec is actually meaningless, as there is
- # no search path for DLLs.
- hardcode_libdir_flag_spec=' '
- allow_undefined_flag=unsupported
- # Tell ltmain to make .lib files, not .a files.
- libext=lib
- # Tell ltmain to make .dll files, not .so files.
- shrext_cmds=".dll"
- # FIXME: Setting linknames here is a bad hack.
- archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
- # The linker will automatically build a .lib file if we build a DLL.
- old_archive_from_new_cmds='true'
- # FIXME: Should let the user specify the lib program.
- old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs'
- fix_srcfile_path='`cygpath -w "$srcfile"`'
- enable_shared_with_static_runtimes=yes
- ;;
-
- darwin* | rhapsody*)
-
-
- archive_cmds_need_lc=no
- hardcode_direct=no
- hardcode_automatic=yes
- hardcode_shlibpath_var=unsupported
- if test "$lt_cv_ld_force_load" = "yes"; then
- whole_archive_flag_spec='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience ${wl}-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`'
- else
- whole_archive_flag_spec=''
- fi
- link_all_deplibs=yes
- allow_undefined_flag="$_lt_dar_allow_undefined"
- case $cc_basename in
- ifort*) _lt_dar_can_shared=yes ;;
- *) _lt_dar_can_shared=$GCC ;;
- esac
- if test "$_lt_dar_can_shared" = "yes"; then
- output_verbose_link_cmd=func_echo_all
- archive_cmds="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}"
- module_cmds="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
- archive_expsym_cmds="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}"
- module_expsym_cmds="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}"
-
- else
- ld_shlibs=no
- fi
-
- ;;
-
- dgux*)
- archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
- hardcode_libdir_flag_spec='-L$libdir'
- hardcode_shlibpath_var=no
- ;;
-
- # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
- # support. Future versions do this automatically, but an explicit c++rt0.o
- # does not break anything, and helps significantly (at the cost of a little
- # extra space).
- freebsd2.2*)
- archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
- hardcode_libdir_flag_spec='-R$libdir'
- hardcode_direct=yes
- hardcode_shlibpath_var=no
- ;;
-
- # Unfortunately, older versions of FreeBSD 2 do not have this feature.
- freebsd2.*)
- archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
- hardcode_direct=yes
- hardcode_minus_L=yes
- hardcode_shlibpath_var=no
- ;;
-
- # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
- freebsd* | dragonfly*)
- archive_cmds='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
- hardcode_libdir_flag_spec='-R$libdir'
- hardcode_direct=yes
- hardcode_shlibpath_var=no
- ;;
-
- hpux9*)
- if test "$GCC" = yes; then
- archive_cmds='$RM $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
- else
- archive_cmds='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
- fi
- hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
- hardcode_libdir_separator=:
- hardcode_direct=yes
-
- # hardcode_minus_L: Not really in the search PATH,
- # but as the default location of the library.
- hardcode_minus_L=yes
- export_dynamic_flag_spec='${wl}-E'
- ;;
-
- hpux10*)
- if test "$GCC" = yes && test "$with_gnu_ld" = no; then
- archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
- else
- archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
- fi
- if test "$with_gnu_ld" = no; then
- hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
- hardcode_libdir_flag_spec_ld='+b $libdir'
- hardcode_libdir_separator=:
- hardcode_direct=yes
- hardcode_direct_absolute=yes
- export_dynamic_flag_spec='${wl}-E'
- # hardcode_minus_L: Not really in the search PATH,
- # but as the default location of the library.
- hardcode_minus_L=yes
- fi
- ;;
-
- hpux11*)
- if test "$GCC" = yes && test "$with_gnu_ld" = no; then
- case $host_cpu in
- hppa*64*)
- archive_cmds='$CC -shared ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
- ;;
- ia64*)
- archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
- ;;
- *)
- archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
- ;;
- esac
- else
- case $host_cpu in
- hppa*64*)
- archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
- ;;
- ia64*)
- archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
- ;;
- *)
-
- # Older versions of the 11.00 compiler do not understand -b yet
- # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does)
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC understands -b" >&5
-$as_echo_n "checking if $CC understands -b... " >&6; }
-if ${lt_cv_prog_compiler__b+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_prog_compiler__b=no
- save_LDFLAGS="$LDFLAGS"
- LDFLAGS="$LDFLAGS -b"
- echo "$lt_simple_link_test_code" > conftest.$ac_ext
- if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
- # The linker can only warn and ignore the option if not recognized
- # So say no if there are warnings
- if test -s conftest.err; then
- # Append any errors to the config.log.
- cat conftest.err 1>&5
- $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
- $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
- if diff conftest.exp conftest.er2 >/dev/null; then
- lt_cv_prog_compiler__b=yes
- fi
- else
- lt_cv_prog_compiler__b=yes
- fi
- fi
- $RM -r conftest*
- LDFLAGS="$save_LDFLAGS"
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler__b" >&5
-$as_echo "$lt_cv_prog_compiler__b" >&6; }
-
-if test x"$lt_cv_prog_compiler__b" = xyes; then
- archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
-else
- archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
-fi
-
- ;;
- esac
- fi
- if test "$with_gnu_ld" = no; then
- hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
- hardcode_libdir_separator=:
-
- case $host_cpu in
- hppa*64*|ia64*)
- hardcode_direct=no
- hardcode_shlibpath_var=no
- ;;
- *)
- hardcode_direct=yes
- hardcode_direct_absolute=yes
- export_dynamic_flag_spec='${wl}-E'
-
- # hardcode_minus_L: Not really in the search PATH,
- # but as the default location of the library.
- hardcode_minus_L=yes
- ;;
- esac
- fi
- ;;
-
- irix5* | irix6* | nonstopux*)
- if test "$GCC" = yes; then
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
- # Try to use the -exported_symbol ld option, if it does not
- # work, assume that -exports_file does not work either and
- # implicitly export all symbols.
- save_LDFLAGS="$LDFLAGS"
- LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-int foo(void) {}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
-
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LDFLAGS="$save_LDFLAGS"
- else
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
- fi
- archive_cmds_need_lc='no'
- hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
- hardcode_libdir_separator=:
- inherit_rpath=yes
- link_all_deplibs=yes
- ;;
-
- netbsd*)
- if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
- archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out
- else
- archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF
- fi
- hardcode_libdir_flag_spec='-R$libdir'
- hardcode_direct=yes
- hardcode_shlibpath_var=no
- ;;
-
- newsos6)
- archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
- hardcode_direct=yes
- hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
- hardcode_libdir_separator=:
- hardcode_shlibpath_var=no
- ;;
-
- *nto* | *qnx*)
- ;;
-
- openbsd*)
- if test -f /usr/libexec/ld.so; then
- hardcode_direct=yes
- hardcode_shlibpath_var=no
- hardcode_direct_absolute=yes
- if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
- archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
- archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
- hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
- export_dynamic_flag_spec='${wl}-E'
- else
- case $host_os in
- openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*)
- archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
- hardcode_libdir_flag_spec='-R$libdir'
- ;;
- *)
- archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
- hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
- ;;
- esac
- fi
- else
- ld_shlibs=no
- fi
- ;;
-
- os2*)
- hardcode_libdir_flag_spec='-L$libdir'
- hardcode_minus_L=yes
- allow_undefined_flag=unsupported
- archive_cmds='$ECHO "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~echo DATA >> $output_objdir/$libname.def~echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def'
- old_archive_from_new_cmds='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
- ;;
-
- osf3*)
- if test "$GCC" = yes; then
- allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
- archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
- else
- allow_undefined_flag=' -expect_unresolved \*'
- archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
- fi
- archive_cmds_need_lc='no'
- hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
- hardcode_libdir_separator=:
- ;;
-
- osf4* | osf5*) # as osf3* with the addition of -msym flag
- if test "$GCC" = yes; then
- allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
- archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
- hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
- else
- allow_undefined_flag=' -expect_unresolved \*'
- archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
- archive_expsym_cmds='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~
- $CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp'
-
- # Both c and cxx compiler support -rpath directly
- hardcode_libdir_flag_spec='-rpath $libdir'
- fi
- archive_cmds_need_lc='no'
- hardcode_libdir_separator=:
- ;;
-
- solaris*)
- no_undefined_flag=' -z defs'
- if test "$GCC" = yes; then
- wlarc='${wl}'
- archive_cmds='$CC -shared ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
- archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
- $CC -shared ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
- else
- case `$CC -V 2>&1` in
- *"Compilers 5.0"*)
- wlarc=''
- archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
- archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
- $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp'
- ;;
- *)
- wlarc='${wl}'
- archive_cmds='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags'
- archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
- $CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
- ;;
- esac
- fi
- hardcode_libdir_flag_spec='-R$libdir'
- hardcode_shlibpath_var=no
- case $host_os in
- solaris2.[0-5] | solaris2.[0-5].*) ;;
- *)
- # The compiler driver will combine and reorder linker options,
- # but understands `-z linker_flag'. GCC discards it without `$wl',
- # but is careful enough not to reorder.
- # Supported since Solaris 2.6 (maybe 2.5.1?)
- if test "$GCC" = yes; then
- whole_archive_flag_spec='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
- else
- whole_archive_flag_spec='-z allextract$convenience -z defaultextract'
- fi
- ;;
- esac
- link_all_deplibs=yes
- ;;
-
- sunos4*)
- if test "x$host_vendor" = xsequent; then
- # Use $CC to link under sequent, because it throws in some extra .o
- # files that make .init and .fini sections work.
- archive_cmds='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
- else
- archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
- fi
- hardcode_libdir_flag_spec='-L$libdir'
- hardcode_direct=yes
- hardcode_minus_L=yes
- hardcode_shlibpath_var=no
- ;;
-
- sysv4)
- case $host_vendor in
- sni)
- archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
- hardcode_direct=yes # is this really true???
- ;;
- siemens)
- ## LD is ld it makes a PLAMLIB
- ## CC just makes a GrossModule.
- archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags'
- reload_cmds='$CC -r -o $output$reload_objs'
- hardcode_direct=no
- ;;
- motorola)
- archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
- hardcode_direct=no #Motorola manual says yes, but my tests say they lie
- ;;
- esac
- runpath_var='LD_RUN_PATH'
- hardcode_shlibpath_var=no
- ;;
-
- sysv4.3*)
- archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
- hardcode_shlibpath_var=no
- export_dynamic_flag_spec='-Bexport'
- ;;
-
- sysv4*MP*)
- if test -d /usr/nec; then
- archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
- hardcode_shlibpath_var=no
- runpath_var=LD_RUN_PATH
- hardcode_runpath_var=yes
- ld_shlibs=yes
- fi
- ;;
-
- sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*)
- no_undefined_flag='${wl}-z,text'
- archive_cmds_need_lc=no
- hardcode_shlibpath_var=no
- runpath_var='LD_RUN_PATH'
-
- if test "$GCC" = yes; then
- archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- else
- archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- fi
- ;;
-
- sysv5* | sco3.2v5* | sco5v6*)
- # Note: We can NOT use -z defs as we might desire, because we do not
- # link with -lc, and that would cause any symbols used from libc to
- # always be unresolved, which means just about no library would
- # ever link correctly. If we're not using GNU ld we use -z text
- # though, which does catch some bad symbols but isn't as heavy-handed
- # as -z defs.
- no_undefined_flag='${wl}-z,text'
- allow_undefined_flag='${wl}-z,nodefs'
- archive_cmds_need_lc=no
- hardcode_shlibpath_var=no
- hardcode_libdir_flag_spec='${wl}-R,$libdir'
- hardcode_libdir_separator=':'
- link_all_deplibs=yes
- export_dynamic_flag_spec='${wl}-Bexport'
- runpath_var='LD_RUN_PATH'
-
- if test "$GCC" = yes; then
- archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- else
- archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- fi
- ;;
-
- uts4*)
- archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
- hardcode_libdir_flag_spec='-L$libdir'
- hardcode_shlibpath_var=no
- ;;
-
- *)
- ld_shlibs=no
- ;;
- esac
-
- if test x$host_vendor = xsni; then
- case $host in
- sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
- export_dynamic_flag_spec='${wl}-Blargedynsym'
- ;;
- esac
- fi
- fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs" >&5
-$as_echo "$ld_shlibs" >&6; }
-test "$ld_shlibs" = no && can_build_shared=no
-
-with_gnu_ld=$with_gnu_ld
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-#
-# Do we need to explicitly link libc?
-#
-case "x$archive_cmds_need_lc" in
-x|xyes)
- # Assume -lc should be added
- archive_cmds_need_lc=yes
-
- if test "$enable_shared" = yes && test "$GCC" = yes; then
- case $archive_cmds in
- *'~'*)
- # FIXME: we may have to deal with multi-command sequences.
- ;;
- '$CC '*)
- # Test whether the compiler implicitly links with -lc since on some
- # systems, -lgcc has to come before -lc. If gcc already passes -lc
- # to ld, don't add -lc before -lgcc.
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5
-$as_echo_n "checking whether -lc should be explicitly linked in... " >&6; }
-if ${lt_cv_archive_cmds_need_lc+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- $RM conftest*
- echo "$lt_simple_compile_test_code" > conftest.$ac_ext
-
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
- (eval $ac_compile) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } 2>conftest.err; then
- soname=conftest
- lib=conftest
- libobjs=conftest.$ac_objext
- deplibs=
- wl=$lt_prog_compiler_wl
- pic_flag=$lt_prog_compiler_pic
- compiler_flags=-v
- linker_flags=-v
- verstring=
- output_objdir=.
- libname=conftest
- lt_save_allow_undefined_flag=$allow_undefined_flag
- allow_undefined_flag=
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5
- (eval $archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }
- then
- lt_cv_archive_cmds_need_lc=no
- else
- lt_cv_archive_cmds_need_lc=yes
- fi
- allow_undefined_flag=$lt_save_allow_undefined_flag
- else
- cat conftest.err 1>&5
- fi
- $RM conftest*
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc" >&5
-$as_echo "$lt_cv_archive_cmds_need_lc" >&6; }
- archive_cmds_need_lc=$lt_cv_archive_cmds_need_lc
- ;;
- esac
- fi
- ;;
-esac
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5
-$as_echo_n "checking dynamic linker characteristics... " >&6; }
-
-if test "$GCC" = yes; then
- case $host_os in
- darwin*) lt_awk_arg="/^libraries:/,/LR/" ;;
- *) lt_awk_arg="/^libraries:/" ;;
- esac
- case $host_os in
- mingw* | cegcc*) lt_sed_strip_eq="s,=\([A-Za-z]:\),\1,g" ;;
- *) lt_sed_strip_eq="s,=/,/,g" ;;
- esac
- lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq`
- case $lt_search_path_spec in
- *\;*)
- # if the path contains ";" then we assume it to be the separator
- # otherwise default to the standard path separator (i.e. ":") - it is
- # assumed that no part of a normal pathname contains ";" but that should
- # okay in the real world where ";" in dirpaths is itself problematic.
- lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'`
- ;;
- *)
- lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"`
- ;;
- esac
- # Ok, now we have the path, separated by spaces, we can step through it
- # and add multilib dir if necessary.
- lt_tmp_lt_search_path_spec=
- lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
- for lt_sys_path in $lt_search_path_spec; do
- if test -d "$lt_sys_path/$lt_multi_os_dir"; then
- lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir"
- else
- test -d "$lt_sys_path" && \
- lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
- fi
- done
- lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk '
-BEGIN {RS=" "; FS="/|\n";} {
- lt_foo="";
- lt_count=0;
- for (lt_i = NF; lt_i > 0; lt_i--) {
- if ($lt_i != "" && $lt_i != ".") {
- if ($lt_i == "..") {
- lt_count++;
- } else {
- if (lt_count == 0) {
- lt_foo="/" $lt_i lt_foo;
- } else {
- lt_count--;
- }
- }
- }
- }
- if (lt_foo != "") { lt_freq[lt_foo]++; }
- if (lt_freq[lt_foo] == 1) { print lt_foo; }
-}'`
- # AWK program above erroneously prepends '/' to C:/dos/paths
- # for these hosts.
- case $host_os in
- mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\
- $SED 's,/\([A-Za-z]:\),\1,g'` ;;
- esac
- sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP`
-else
- sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
-fi
-library_names_spec=
-libname_spec='lib$name'
-soname_spec=
-shrext_cmds=".so"
-postinstall_cmds=
-postuninstall_cmds=
-finish_cmds=
-finish_eval=
-shlibpath_var=
-shlibpath_overrides_runpath=unknown
-version_type=none
-dynamic_linker="$host_os ld.so"
-sys_lib_dlsearch_path_spec="/lib /usr/lib"
-need_lib_prefix=unknown
-hardcode_into_libs=no
-
-# when you set need_version to no, make sure it does not cause -set_version
-# flags to be left without arguments
-need_version=unknown
-
-case $host_os in
-aix3*)
- version_type=linux
- library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
- shlibpath_var=LIBPATH
-
- # AIX 3 has no versioning support, so we append a major version to the name.
- soname_spec='${libname}${release}${shared_ext}$major'
- ;;
-
-aix[4-9]*)
- version_type=linux
- need_lib_prefix=no
- need_version=no
- hardcode_into_libs=yes
- if test "$host_cpu" = ia64; then
- # AIX 5 supports IA64
- library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
- shlibpath_var=LD_LIBRARY_PATH
- else
- # With GCC up to 2.95.x, collect2 would create an import file
- # for dependence libraries. The import file would start with
- # the line `#! .'. This would cause the generated library to
- # depend on `.', always an invalid library. This was fixed in
- # development snapshots of GCC prior to 3.0.
- case $host_os in
- aix4 | aix4.[01] | aix4.[01].*)
- if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
- echo ' yes '
- echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then
- :
- else
- can_build_shared=no
- fi
- ;;
- esac
- # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
- # soname into executable. Probably we can add versioning support to
- # collect2, so additional links can be useful in future.
- if test "$aix_use_runtimelinking" = yes; then
- # If using run time linking (on AIX 4.2 or later) use lib<name>.so
- # instead of lib<name>.a to let people know that these are not
- # typical AIX shared libraries.
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- else
- # We preserve .a as extension for shared libraries through AIX4.2
- # and later when we are not doing run time linking.
- library_names_spec='${libname}${release}.a $libname.a'
- soname_spec='${libname}${release}${shared_ext}$major'
- fi
- shlibpath_var=LIBPATH
- fi
- ;;
-
-amigaos*)
- case $host_cpu in
- powerpc)
- # Since July 2007 AmigaOS4 officially supports .so libraries.
- # When compiling the executable, add -use-dynld -Lsobjs: to the compileline.
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- ;;
- m68k)
- library_names_spec='$libname.ixlibrary $libname.a'
- # Create ${libname}_ixlibrary.a entries in /sys/libs.
- finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done'
- ;;
- esac
- ;;
-
-beos*)
- library_names_spec='${libname}${shared_ext}'
- dynamic_linker="$host_os ld.so"
- shlibpath_var=LIBRARY_PATH
- ;;
-
-bsdi[45]*)
- version_type=linux
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
- shlibpath_var=LD_LIBRARY_PATH
- sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
- sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
- # the default ld.so.conf also contains /usr/contrib/lib and
- # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
- # libtool to hard-code these into programs
- ;;
-
-cygwin* | mingw* | pw32* | cegcc*)
- version_type=windows
- shrext_cmds=".dll"
- need_version=no
- need_lib_prefix=no
-
- case $GCC,$host_os in
- yes,cygwin* | yes,mingw* | yes,pw32* | yes,cegcc*)
- library_names_spec='$libname.dll.a'
- # DLL is installed to $(libdir)/../bin by postinstall_cmds
- postinstall_cmds='base_file=`basename \${file}`~
- dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
- dldir=$destdir/`dirname \$dlpath`~
- test -d \$dldir || mkdir -p \$dldir~
- $install_prog $dir/$dlname \$dldir/$dlname~
- chmod a+x \$dldir/$dlname~
- if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
- eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
- fi'
- postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
- dlpath=$dir/\$dldll~
- $RM \$dlpath'
- shlibpath_overrides_runpath=yes
-
- case $host_os in
- cygwin*)
- # Cygwin DLLs use 'cyg' prefix rather than 'lib'
- soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
-
- sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"
- ;;
- mingw* | cegcc*)
- # MinGW DLLs use traditional 'lib' prefix
- soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
- ;;
- pw32*)
- # pw32 DLLs use 'pw' prefix rather than 'lib'
- library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
- ;;
- esac
- ;;
-
- *)
- library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib'
- ;;
- esac
- dynamic_linker='Win32 ld.exe'
- # FIXME: first we should search . and the directory the executable is in
- shlibpath_var=PATH
- ;;
-
-darwin* | rhapsody*)
- dynamic_linker="$host_os dyld"
- version_type=darwin
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext'
- soname_spec='${libname}${release}${major}$shared_ext'
- shlibpath_overrides_runpath=yes
- shlibpath_var=DYLD_LIBRARY_PATH
- shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
-
- sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"
- sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
- ;;
-
-dgux*)
- version_type=linux
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
- soname_spec='${libname}${release}${shared_ext}$major'
- shlibpath_var=LD_LIBRARY_PATH
- ;;
-
-freebsd* | dragonfly*)
- # DragonFly does not have aout. When/if they implement a new
- # versioning mechanism, adjust this.
- if test -x /usr/bin/objformat; then
- objformat=`/usr/bin/objformat`
- else
- case $host_os in
- freebsd[23].*) objformat=aout ;;
- *) objformat=elf ;;
- esac
- fi
- version_type=freebsd-$objformat
- case $version_type in
- freebsd-elf*)
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
- need_version=no
- need_lib_prefix=no
- ;;
- freebsd-*)
- library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
- need_version=yes
- ;;
- esac
- shlibpath_var=LD_LIBRARY_PATH
- case $host_os in
- freebsd2.*)
- shlibpath_overrides_runpath=yes
- ;;
- freebsd3.[01]* | freebsdelf3.[01]*)
- shlibpath_overrides_runpath=yes
- hardcode_into_libs=yes
- ;;
- freebsd3.[2-9]* | freebsdelf3.[2-9]* | \
- freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1)
- shlibpath_overrides_runpath=no
- hardcode_into_libs=yes
- ;;
- *) # from 4.6 on, and DragonFly
- shlibpath_overrides_runpath=yes
- hardcode_into_libs=yes
- ;;
- esac
- ;;
-
-haiku*)
- version_type=linux
- need_lib_prefix=no
- need_version=no
- dynamic_linker="$host_os runtime_loader"
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- shlibpath_var=LIBRARY_PATH
- shlibpath_overrides_runpath=yes
- sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
- hardcode_into_libs=yes
- ;;
-
-hpux9* | hpux10* | hpux11*)
- # Give a soname corresponding to the major version so that dld.sl refuses to
- # link against other versions.
- version_type=sunos
- need_lib_prefix=no
- need_version=no
- case $host_cpu in
- ia64*)
- shrext_cmds='.so'
- hardcode_into_libs=yes
- dynamic_linker="$host_os dld.so"
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- if test "X$HPUX_IA64_MODE" = X32; then
- sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
- else
- sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
- fi
- sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
- ;;
- hppa*64*)
- shrext_cmds='.sl'
- hardcode_into_libs=yes
- dynamic_linker="$host_os dld.sl"
- shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
- shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
- sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
- ;;
- *)
- shrext_cmds='.sl'
- dynamic_linker="$host_os dld.sl"
- shlibpath_var=SHLIB_PATH
- shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- ;;
- esac
- # HP-UX runs *really* slowly unless shared libraries are mode 555, ...
- postinstall_cmds='chmod 555 $lib'
- # or fails outright, so override atomically:
- install_override_mode=555
- ;;
-
-interix[3-9]*)
- version_type=linux
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=no
- hardcode_into_libs=yes
- ;;
-
-irix5* | irix6* | nonstopux*)
- case $host_os in
- nonstopux*) version_type=nonstopux ;;
- *)
- if test "$lt_cv_prog_gnu_ld" = yes; then
- version_type=linux
- else
- version_type=irix
- fi ;;
- esac
- need_lib_prefix=no
- need_version=no
- soname_spec='${libname}${release}${shared_ext}$major'
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
- case $host_os in
- irix5* | nonstopux*)
- libsuff= shlibsuff=
- ;;
- *)
- case $LD in # libtool.m4 will add one of these switches to LD
- *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
- libsuff= shlibsuff= libmagic=32-bit;;
- *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
- libsuff=32 shlibsuff=N32 libmagic=N32;;
- *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
- libsuff=64 shlibsuff=64 libmagic=64-bit;;
- *) libsuff= shlibsuff= libmagic=never-match;;
- esac
- ;;
- esac
- shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
- shlibpath_overrides_runpath=no
- sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
- sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
- hardcode_into_libs=yes
- ;;
-
-# No shared lib support for Linux oldld, aout, or coff.
-linux*oldld* | linux*aout* | linux*coff*)
- dynamic_linker=no
- ;;
-
-# This must be Linux ELF.
-
-# uclinux* changes (here and below) have been submitted to the libtool
-# project, but have not yet been accepted: they are GCC-local changes
-# for the time being. (See
-# https://lists.gnu.org/archive/html/libtool-patches/2018-05/msg00000.html)
-linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu* | uclinuxfdpiceabi)
- version_type=linux
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=no
-
- # Some binutils ld are patched to set DT_RUNPATH
- if ${lt_cv_shlibpath_overrides_runpath+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_shlibpath_overrides_runpath=no
- save_LDFLAGS=$LDFLAGS
- save_libdir=$libdir
- eval "libdir=/foo; wl=\"$lt_prog_compiler_wl\"; \
- LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec\""
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- if ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then :
- lt_cv_shlibpath_overrides_runpath=yes
-fi
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LDFLAGS=$save_LDFLAGS
- libdir=$save_libdir
-
-fi
-
- shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath
-
- # This implies no fast_install, which is unacceptable.
- # Some rework will be needed to allow for fast_install
- # before this can be enabled.
- hardcode_into_libs=yes
-
- # find out which ABI we are using
- libsuff=
- case "$host_cpu" in
- x86_64*|s390*|powerpc*|ppc*|sparc*)
- echo 'int i;' > conftest.$ac_ext
- if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; then
- case `/usr/bin/file conftest.$ac_objext` in
- *64-bit*)
- libsuff=
- if test x"$sys_lib_search_path_spec" = x"/lib /usr/lib /usr/local/lib"; then
- sys_lib_search_path_spec="/lib${libsuff} /usr/lib${libsuff} /usr/local/lib${libsuff}"
- fi
- sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff}"
- ;;
- *32-bit*)
- libsuff=32
- if test x"$sys_lib_search_path_spec" = x"/lib /usr/lib /usr/local/lib"; then
- sys_lib_search_path_spec="/lib${libsuff} /usr/lib${libsuff} /usr/local/lib${libsuff}"
- fi
- sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff}"
- ;;
- esac
- fi
- rm -rf conftest*
- ;;
- esac
-
- # Append ld.so.conf contents to the search path
- if test -f /etc/ld.so.conf; then
- lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '`
- sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff} $lt_ld_extra"
- fi
-
- # We used to test for /lib/ld.so.1 and disable shared libraries on
- # powerpc, because MkLinux only supported shared libraries with the
- # GNU dynamic linker. Since this was broken with cross compilers,
- # most powerpc-linux boxes support dynamic linking these days and
- # people can always --disable-shared, the test was removed, and we
- # assume the GNU/Linux dynamic linker is in use.
- dynamic_linker='GNU/Linux ld.so'
- ;;
-
-netbsd*)
- version_type=sunos
- need_lib_prefix=no
- need_version=no
- if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
- finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
- dynamic_linker='NetBSD (a.out) ld.so'
- else
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- dynamic_linker='NetBSD ld.elf_so'
- fi
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=yes
- hardcode_into_libs=yes
- ;;
-
-newsos6)
- version_type=linux
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=yes
- ;;
-
-*nto* | *qnx*)
- version_type=qnx
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=no
- hardcode_into_libs=yes
- dynamic_linker='ldqnx.so'
- ;;
-
-openbsd*)
- version_type=sunos
- sys_lib_dlsearch_path_spec="/usr/lib"
- need_lib_prefix=no
- # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
- case $host_os in
- openbsd3.3 | openbsd3.3.*) need_version=yes ;;
- *) need_version=no ;;
- esac
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
- finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
- shlibpath_var=LD_LIBRARY_PATH
- if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
- case $host_os in
- openbsd2.[89] | openbsd2.[89].*)
- shlibpath_overrides_runpath=no
- ;;
- *)
- shlibpath_overrides_runpath=yes
- ;;
- esac
- else
- shlibpath_overrides_runpath=yes
- fi
- ;;
-
-os2*)
- libname_spec='$name'
- shrext_cmds=".dll"
- need_lib_prefix=no
- library_names_spec='$libname${shared_ext} $libname.a'
- dynamic_linker='OS/2 ld.exe'
- shlibpath_var=LIBPATH
- ;;
-
-osf3* | osf4* | osf5*)
- version_type=osf
- need_lib_prefix=no
- need_version=no
- soname_spec='${libname}${release}${shared_ext}$major'
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- shlibpath_var=LD_LIBRARY_PATH
- sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
- sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
- ;;
-
-rdos*)
- dynamic_linker=no
- ;;
-
-solaris*)
- version_type=linux
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=yes
- hardcode_into_libs=yes
- # ldd complains unless libraries are executable
- postinstall_cmds='chmod +x $lib'
- ;;
-
-sunos4*)
- version_type=sunos
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
- finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=yes
- if test "$with_gnu_ld" = yes; then
- need_lib_prefix=no
- fi
- need_version=yes
- ;;
-
-sysv4 | sysv4.3*)
- version_type=linux
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- shlibpath_var=LD_LIBRARY_PATH
- case $host_vendor in
- sni)
- shlibpath_overrides_runpath=no
- need_lib_prefix=no
- runpath_var=LD_RUN_PATH
- ;;
- siemens)
- need_lib_prefix=no
- ;;
- motorola)
- need_lib_prefix=no
- need_version=no
- shlibpath_overrides_runpath=no
- sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
- ;;
- esac
- ;;
-
-sysv4*MP*)
- if test -d /usr/nec ;then
- version_type=linux
- library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
- soname_spec='$libname${shared_ext}.$major'
- shlibpath_var=LD_LIBRARY_PATH
- fi
- ;;
-
-sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
- version_type=freebsd-elf
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=yes
- hardcode_into_libs=yes
- if test "$with_gnu_ld" = yes; then
- sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
- else
- sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
- case $host_os in
- sco3.2v5*)
- sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
- ;;
- esac
- fi
- sys_lib_dlsearch_path_spec='/usr/lib'
- ;;
-
-tpf*)
- # TPF is a cross-target only. Preferred cross-host = GNU/Linux.
- version_type=linux
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=no
- hardcode_into_libs=yes
- ;;
-
-uts4*)
- version_type=linux
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- shlibpath_var=LD_LIBRARY_PATH
- ;;
-
-# Shared libraries for VwWorks, >= 7 only at this stage
-# and (fpic) still incompatible with "large" code models
-# in a few configurations. Only for RTP mode in any case,
-# and upon explicit request at configure time.
-vxworks7*)
- dynamic_linker=no
- case ${with_multisubdir}-${enable_shared} in
- *large*)
- ;;
- *mrtp*-yes)
- version_type=linux
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- dynamic_linker="$host_os module_loader"
- ;;
- esac
- ;;
-*)
- dynamic_linker=no
- ;;
-esac
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5
-$as_echo "$dynamic_linker" >&6; }
-test "$dynamic_linker" = no && can_build_shared=no
-
-variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
-if test "$GCC" = yes; then
- variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
-fi
-
-if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then
- sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec"
-fi
-if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then
- sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec"
-fi
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5
-$as_echo_n "checking how to hardcode library paths into programs... " >&6; }
-hardcode_action=
-if test -n "$hardcode_libdir_flag_spec" ||
- test -n "$runpath_var" ||
- test "X$hardcode_automatic" = "Xyes" ; then
-
- # We can hardcode non-existent directories.
- if test "$hardcode_direct" != no &&
- # If the only mechanism to avoid hardcoding is shlibpath_var, we
- # have to relink, otherwise we might link with an installed library
- # when we should be linking with a yet-to-be-installed one
- ## test "$_LT_TAGVAR(hardcode_shlibpath_var, )" != no &&
- test "$hardcode_minus_L" != no; then
- # Linking always hardcodes the temporary library directory.
- hardcode_action=relink
- else
- # We can link without hardcoding, and we can hardcode nonexisting dirs.
- hardcode_action=immediate
- fi
-else
- # We cannot hardcode anything, or else we can only hardcode existing
- # directories.
- hardcode_action=unsupported
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action" >&5
-$as_echo "$hardcode_action" >&6; }
-
-if test "$hardcode_action" = relink ||
- test "$inherit_rpath" = yes; then
- # Fast installation is not supported
- enable_fast_install=no
-elif test "$shlibpath_overrides_runpath" = yes ||
- test "$enable_shared" = no; then
- # Fast installation is not necessary
- enable_fast_install=needless
-fi
-
-
-
-
-
-
- if test "x$enable_dlopen" != xyes; then
- enable_dlopen=unknown
- enable_dlopen_self=unknown
- enable_dlopen_self_static=unknown
-else
- lt_cv_dlopen=no
- lt_cv_dlopen_libs=
-
- case $host_os in
- beos*)
- lt_cv_dlopen="load_add_on"
- lt_cv_dlopen_libs=
- lt_cv_dlopen_self=yes
- ;;
-
- mingw* | pw32* | cegcc*)
- lt_cv_dlopen="LoadLibrary"
- lt_cv_dlopen_libs=
- ;;
-
- cygwin*)
- lt_cv_dlopen="dlopen"
- lt_cv_dlopen_libs=
- ;;
-
- darwin*)
- # if libdl is installed we need to link against it
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
-$as_echo_n "checking for dlopen in -ldl... " >&6; }
-if ${ac_cv_lib_dl_dlopen+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-ldl $LIBS"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char dlopen ();
-int
-main ()
-{
-return dlopen ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_lib_dl_dlopen=yes
-else
- ac_cv_lib_dl_dlopen=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
-$as_echo "$ac_cv_lib_dl_dlopen" >&6; }
-if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
- lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
-else
-
- lt_cv_dlopen="dyld"
- lt_cv_dlopen_libs=
- lt_cv_dlopen_self=yes
-
-fi
-
- ;;
-
- *)
- ac_fn_c_check_func "$LINENO" "shl_load" "ac_cv_func_shl_load"
-if test "x$ac_cv_func_shl_load" = xyes; then :
- lt_cv_dlopen="shl_load"
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5
-$as_echo_n "checking for shl_load in -ldld... " >&6; }
-if ${ac_cv_lib_dld_shl_load+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-ldld $LIBS"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char shl_load ();
-int
-main ()
-{
-return shl_load ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_lib_dld_shl_load=yes
-else
- ac_cv_lib_dld_shl_load=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5
-$as_echo "$ac_cv_lib_dld_shl_load" >&6; }
-if test "x$ac_cv_lib_dld_shl_load" = xyes; then :
- lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"
-else
- ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen"
-if test "x$ac_cv_func_dlopen" = xyes; then :
- lt_cv_dlopen="dlopen"
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
-$as_echo_n "checking for dlopen in -ldl... " >&6; }
-if ${ac_cv_lib_dl_dlopen+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-ldl $LIBS"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char dlopen ();
-int
-main ()
-{
-return dlopen ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_lib_dl_dlopen=yes
-else
- ac_cv_lib_dl_dlopen=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
-$as_echo "$ac_cv_lib_dl_dlopen" >&6; }
-if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
- lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5
-$as_echo_n "checking for dlopen in -lsvld... " >&6; }
-if ${ac_cv_lib_svld_dlopen+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-lsvld $LIBS"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char dlopen ();
-int
-main ()
-{
-return dlopen ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_lib_svld_dlopen=yes
-else
- ac_cv_lib_svld_dlopen=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5
-$as_echo "$ac_cv_lib_svld_dlopen" >&6; }
-if test "x$ac_cv_lib_svld_dlopen" = xyes; then :
- lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5
-$as_echo_n "checking for dld_link in -ldld... " >&6; }
-if ${ac_cv_lib_dld_dld_link+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-ldld $LIBS"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char dld_link ();
-int
-main ()
-{
-return dld_link ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_lib_dld_dld_link=yes
-else
- ac_cv_lib_dld_dld_link=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_dld_link" >&5
-$as_echo "$ac_cv_lib_dld_dld_link" >&6; }
-if test "x$ac_cv_lib_dld_dld_link" = xyes; then :
- lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"
-fi
-
-
-fi
-
-
-fi
-
-
-fi
-
-
-fi
-
-
-fi
-
- ;;
- esac
-
- if test "x$lt_cv_dlopen" != xno; then
- enable_dlopen=yes
- else
- enable_dlopen=no
- fi
-
- case $lt_cv_dlopen in
- dlopen)
- save_CPPFLAGS="$CPPFLAGS"
- test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
-
- save_LDFLAGS="$LDFLAGS"
- wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
-
- save_LIBS="$LIBS"
- LIBS="$lt_cv_dlopen_libs $LIBS"
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a program can dlopen itself" >&5
-$as_echo_n "checking whether a program can dlopen itself... " >&6; }
-if ${lt_cv_dlopen_self+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test "$cross_compiling" = yes; then :
- lt_cv_dlopen_self=cross
-else
- lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
- lt_status=$lt_dlunknown
- cat > conftest.$ac_ext <<_LT_EOF
-#line 11084 "configure"
-#include "confdefs.h"
-
-#if HAVE_DLFCN_H
-#include <dlfcn.h>
-#endif
-
-#include <stdio.h>
-
-#ifdef RTLD_GLOBAL
-# define LT_DLGLOBAL RTLD_GLOBAL
-#else
-# ifdef DL_GLOBAL
-# define LT_DLGLOBAL DL_GLOBAL
-# else
-# define LT_DLGLOBAL 0
-# endif
-#endif
-
-/* We may have to define LT_DLLAZY_OR_NOW in the command line if we
- find out it does not work in some platform. */
-#ifndef LT_DLLAZY_OR_NOW
-# ifdef RTLD_LAZY
-# define LT_DLLAZY_OR_NOW RTLD_LAZY
-# else
-# ifdef DL_LAZY
-# define LT_DLLAZY_OR_NOW DL_LAZY
-# else
-# ifdef RTLD_NOW
-# define LT_DLLAZY_OR_NOW RTLD_NOW
-# else
-# ifdef DL_NOW
-# define LT_DLLAZY_OR_NOW DL_NOW
-# else
-# define LT_DLLAZY_OR_NOW 0
-# endif
-# endif
-# endif
-# endif
-#endif
-
-/* When -fvisbility=hidden is used, assume the code has been annotated
- correspondingly for the symbols needed. */
-#if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
-void fnord () __attribute__((visibility("default")));
-#endif
-
-void fnord () { int i=42; }
-int main ()
-{
- void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
- int status = $lt_dlunknown;
-
- if (self)
- {
- if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
- else
- {
- if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
- else puts (dlerror ());
- }
- /* dlclose (self); */
- }
- else
- puts (dlerror ());
-
- return status;
-}
-_LT_EOF
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
- (eval $ac_link) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then
- (./conftest; exit; ) >&5 2>/dev/null
- lt_status=$?
- case x$lt_status in
- x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;;
- x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;;
- x$lt_dlunknown|x*) lt_cv_dlopen_self=no ;;
- esac
- else :
- # compilation failed
- lt_cv_dlopen_self=no
- fi
-fi
-rm -fr conftest*
-
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self" >&5
-$as_echo "$lt_cv_dlopen_self" >&6; }
-
- if test "x$lt_cv_dlopen_self" = xyes; then
- wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a statically linked program can dlopen itself" >&5
-$as_echo_n "checking whether a statically linked program can dlopen itself... " >&6; }
-if ${lt_cv_dlopen_self_static+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test "$cross_compiling" = yes; then :
- lt_cv_dlopen_self_static=cross
-else
- lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
- lt_status=$lt_dlunknown
- cat > conftest.$ac_ext <<_LT_EOF
-#line 11190 "configure"
-#include "confdefs.h"
-
-#if HAVE_DLFCN_H
-#include <dlfcn.h>
-#endif
-
-#include <stdio.h>
-
-#ifdef RTLD_GLOBAL
-# define LT_DLGLOBAL RTLD_GLOBAL
-#else
-# ifdef DL_GLOBAL
-# define LT_DLGLOBAL DL_GLOBAL
-# else
-# define LT_DLGLOBAL 0
-# endif
-#endif
-
-/* We may have to define LT_DLLAZY_OR_NOW in the command line if we
- find out it does not work in some platform. */
-#ifndef LT_DLLAZY_OR_NOW
-# ifdef RTLD_LAZY
-# define LT_DLLAZY_OR_NOW RTLD_LAZY
-# else
-# ifdef DL_LAZY
-# define LT_DLLAZY_OR_NOW DL_LAZY
-# else
-# ifdef RTLD_NOW
-# define LT_DLLAZY_OR_NOW RTLD_NOW
-# else
-# ifdef DL_NOW
-# define LT_DLLAZY_OR_NOW DL_NOW
-# else
-# define LT_DLLAZY_OR_NOW 0
-# endif
-# endif
-# endif
-# endif
-#endif
-
-/* When -fvisbility=hidden is used, assume the code has been annotated
- correspondingly for the symbols needed. */
-#if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
-void fnord () __attribute__((visibility("default")));
-#endif
-
-void fnord () { int i=42; }
-int main ()
-{
- void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
- int status = $lt_dlunknown;
-
- if (self)
- {
- if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
- else
- {
- if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
- else puts (dlerror ());
- }
- /* dlclose (self); */
- }
- else
- puts (dlerror ());
-
- return status;
-}
-_LT_EOF
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
- (eval $ac_link) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then
- (./conftest; exit; ) >&5 2>/dev/null
- lt_status=$?
- case x$lt_status in
- x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;;
- x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;;
- x$lt_dlunknown|x*) lt_cv_dlopen_self_static=no ;;
- esac
- else :
- # compilation failed
- lt_cv_dlopen_self_static=no
- fi
-fi
-rm -fr conftest*
-
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self_static" >&5
-$as_echo "$lt_cv_dlopen_self_static" >&6; }
- fi
-
- CPPFLAGS="$save_CPPFLAGS"
- LDFLAGS="$save_LDFLAGS"
- LIBS="$save_LIBS"
- ;;
- esac
-
- case $lt_cv_dlopen_self in
- yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
- *) enable_dlopen_self=unknown ;;
- esac
-
- case $lt_cv_dlopen_self_static in
- yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
- *) enable_dlopen_self_static=unknown ;;
- esac
-fi
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-striplib=
-old_striplib=
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stripping libraries is possible" >&5
-$as_echo_n "checking whether stripping libraries is possible... " >&6; }
-if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then
- test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
- test -z "$striplib" && striplib="$STRIP --strip-unneeded"
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-else
-# FIXME - insert some real tests, host_os isn't really good enough
- case $host_os in
- darwin*)
- if test -n "$STRIP" ; then
- striplib="$STRIP -x"
- old_striplib="$STRIP -S"
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- fi
- ;;
- *)
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- ;;
- esac
-fi
-
-
-
-
-
-
-
-
-
-
-
-
- # Report which library types will actually be built
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libtool supports shared libraries" >&5
-$as_echo_n "checking if libtool supports shared libraries... " >&6; }
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $can_build_shared" >&5
-$as_echo "$can_build_shared" >&6; }
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries" >&5
-$as_echo_n "checking whether to build shared libraries... " >&6; }
- test "$can_build_shared" = "no" && enable_shared=no
-
- # On AIX, shared libraries and static libraries use the same namespace, and
- # are all built from PIC.
- case $host_os in
- aix3*)
- test "$enable_shared" = yes && enable_static=no
- if test -n "$RANLIB"; then
- archive_cmds="$archive_cmds~\$RANLIB \$lib"
- postinstall_cmds='$RANLIB $lib'
- fi
- ;;
-
- aix[4-9]*)
- if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
- test "$enable_shared" = yes && enable_static=no
- fi
- ;;
- esac
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5
-$as_echo "$enable_shared" >&6; }
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build static libraries" >&5
-$as_echo_n "checking whether to build static libraries... " >&6; }
- # Make sure either enable_shared or enable_static is yes.
- test "$enable_shared" = yes || enable_static=yes
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_static" >&5
-$as_echo "$enable_static" >&6; }
-
-
-
-
-fi
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-CC="$lt_save_CC"
-
-
-
-
-
-
-
-
-
-
-
-
-
- ac_config_commands="$ac_config_commands libtool"
-
-
-
-
-# Only expand once:
-
-
-
-# The tests for host and target for $enable_largefile require
-# canonical names.
-
-
-
-# As the $enable_largefile decision depends on --enable-plugins we must set it
-# even in directories otherwise not depending on the $plugins option.
-
-
- maybe_plugins=no
- for ac_header in dlfcn.h
-do :
- ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default
-"
-if test "x$ac_cv_header_dlfcn_h" = xyes; then :
- cat >>confdefs.h <<_ACEOF
-#define HAVE_DLFCN_H 1
-_ACEOF
- maybe_plugins=yes
-fi
-
-done
-
- for ac_header in windows.h
-do :
- ac_fn_c_check_header_compile "$LINENO" "windows.h" "ac_cv_header_windows_h" "$ac_includes_default
-"
-if test "x$ac_cv_header_windows_h" = xyes; then :
- cat >>confdefs.h <<_ACEOF
-#define HAVE_WINDOWS_H 1
-_ACEOF
- maybe_plugins=yes
-fi
-
-done
-
-
- # Check whether --enable-plugins was given.
-if test "${enable_plugins+set}" = set; then :
- enableval=$enable_plugins; case "${enableval}" in
- no) plugins=no ;;
- *) plugins=yes
- if test "$maybe_plugins" != "yes" ; then
- as_fn_error $? "Building with plugin support requires a host that supports dlopen." "$LINENO" 5
- fi ;;
- esac
-else
- plugins=$maybe_plugins
-
-fi
-
- if test "$plugins" = "yes"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing dlsym" >&5
-$as_echo_n "checking for library containing dlsym... " >&6; }
-if ${ac_cv_search_dlsym+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_func_search_save_LIBS=$LIBS
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char dlsym ();
-int
-main ()
-{
-return dlsym ();
- ;
- return 0;
-}
-_ACEOF
-for ac_lib in '' dl; do
- if test -z "$ac_lib"; then
- ac_res="none required"
- else
- ac_res=-l$ac_lib
- LIBS="-l$ac_lib $ac_func_search_save_LIBS"
- fi
- if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_search_dlsym=$ac_res
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext
- if ${ac_cv_search_dlsym+:} false; then :
- break
-fi
-done
-if ${ac_cv_search_dlsym+:} false; then :
-
-else
- ac_cv_search_dlsym=no
-fi
-rm conftest.$ac_ext
-LIBS=$ac_func_search_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_dlsym" >&5
-$as_echo "$ac_cv_search_dlsym" >&6; }
-ac_res=$ac_cv_search_dlsym
-if test "$ac_res" != no; then :
- test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
-
-fi
-
- fi
-
-
-case "${host}" in
- sparc-*-solaris*|i?86-*-solaris*)
- # On native 32-bit Solaris/SPARC and x86, large-file and procfs support
- # were mutually exclusive until Solaris 11.3. Without procfs support,
- # the bfd/ elf module cannot provide certain routines such as
- # elfcore_write_prpsinfo or elfcore_write_prstatus. So unless the user
- # explicitly requested large-file support through the
- # --enable-largefile switch, disable large-file support in favor of
- # procfs support.
- #
- # Check if <sys/procfs.h> is incompatible with large-file support.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#define _FILE_OFFSET_BITS 64
-#define _STRUCTURED_PROC 1
-#include <sys/procfs.h>
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- acx_cv_procfs_lfs=yes
-else
- acx_cv_procfs_lfs=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- #
- # Forcefully disable large-file support only if necessary, gdb is in
- # tree and enabled.
- if test "${target}" = "${host}" -a "$acx_cv_procfs_lfs" = no \
- -a -d $srcdir/../gdb -a "$enable_gdb" != no; then
- : ${enable_largefile="no"}
- if test "$plugins" = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
-plugin support disabled; require large-file support which is incompatible with GDB." >&5
-$as_echo "$as_me: WARNING:
-plugin support disabled; require large-file support which is incompatible with GDB." >&2;}
- plugins=no
- fi
- fi
- #
- # Explicitly undef _FILE_OFFSET_BITS if enable_largefile=no for the
- # benefit of g++ 9+ which predefines it on Solaris.
- if test "$enable_largefile" = no; then
- LARGEFILE_CPPFLAGS="-U_FILE_OFFSET_BITS"
-
- fi
- ;;
-esac
-
-# Check whether --enable-largefile was given.
-if test "${enable_largefile+set}" = set; then :
- enableval=$enable_largefile;
-fi
-
-if test "$enable_largefile" != no; then
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
-$as_echo_n "checking for special C compiler options needed for large files... " >&6; }
-if ${ac_cv_sys_largefile_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_cv_sys_largefile_CC=no
- if test "$GCC" != yes; then
- ac_save_CC=$CC
- while :; do
- # IRIX 6.2 and later do not support large files by default,
- # so use the C compiler's -n32 option if that helps.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <sys/types.h>
- /* Check that off_t can represent 2**63 - 1 correctly.
- We can't simply define LARGE_OFF_T to be 9223372036854775807,
- since some C++ compilers masquerading as C compilers
- incorrectly reject 9223372036854775807. */
-#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
- int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
- && LARGE_OFF_T % 2147483647 == 1)
- ? 1 : -1];
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
- if ac_fn_c_try_compile "$LINENO"; then :
- break
-fi
-rm -f core conftest.err conftest.$ac_objext
- CC="$CC -n32"
- if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_sys_largefile_CC=' -n32'; break
-fi
-rm -f core conftest.err conftest.$ac_objext
- break
- done
- CC=$ac_save_CC
- rm -f conftest.$ac_ext
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
-$as_echo "$ac_cv_sys_largefile_CC" >&6; }
- if test "$ac_cv_sys_largefile_CC" != no; then
- CC=$CC$ac_cv_sys_largefile_CC
- fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
-$as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
-if ${ac_cv_sys_file_offset_bits+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- while :; do
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <sys/types.h>
- /* Check that off_t can represent 2**63 - 1 correctly.
- We can't simply define LARGE_OFF_T to be 9223372036854775807,
- since some C++ compilers masquerading as C compilers
- incorrectly reject 9223372036854775807. */
-#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
- int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
- && LARGE_OFF_T % 2147483647 == 1)
- ? 1 : -1];
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_sys_file_offset_bits=no; break
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#define _FILE_OFFSET_BITS 64
-#include <sys/types.h>
- /* Check that off_t can represent 2**63 - 1 correctly.
- We can't simply define LARGE_OFF_T to be 9223372036854775807,
- since some C++ compilers masquerading as C compilers
- incorrectly reject 9223372036854775807. */
-#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
- int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
- && LARGE_OFF_T % 2147483647 == 1)
- ? 1 : -1];
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_sys_file_offset_bits=64; break
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- ac_cv_sys_file_offset_bits=unknown
- break
-done
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
-$as_echo "$ac_cv_sys_file_offset_bits" >&6; }
-case $ac_cv_sys_file_offset_bits in #(
- no | unknown) ;;
- *)
-cat >>confdefs.h <<_ACEOF
-#define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
-_ACEOF
-;;
-esac
-rm -rf conftest*
- if test $ac_cv_sys_file_offset_bits = unknown; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
-$as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
-if ${ac_cv_sys_large_files+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- while :; do
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <sys/types.h>
- /* Check that off_t can represent 2**63 - 1 correctly.
- We can't simply define LARGE_OFF_T to be 9223372036854775807,
- since some C++ compilers masquerading as C compilers
- incorrectly reject 9223372036854775807. */
-#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
- int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
- && LARGE_OFF_T % 2147483647 == 1)
- ? 1 : -1];
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_sys_large_files=no; break
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#define _LARGE_FILES 1
-#include <sys/types.h>
- /* Check that off_t can represent 2**63 - 1 correctly.
- We can't simply define LARGE_OFF_T to be 9223372036854775807,
- since some C++ compilers masquerading as C compilers
- incorrectly reject 9223372036854775807. */
-#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
- int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
- && LARGE_OFF_T % 2147483647 == 1)
- ? 1 : -1];
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_sys_large_files=1; break
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- ac_cv_sys_large_files=unknown
- break
-done
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
-$as_echo "$ac_cv_sys_large_files" >&6; }
-case $ac_cv_sys_large_files in #(
- no | unknown) ;;
- *)
-cat >>confdefs.h <<_ACEOF
-#define _LARGE_FILES $ac_cv_sys_large_files
-_ACEOF
-;;
-esac
-rm -rf conftest*
- fi
-
-
-fi
-
-
-
-ac_checking=
-. ${srcdir}/../bfd/development.sh
-test "$development" = true && ac_checking=yes
-# Check whether --enable-checking was given.
-if test "${enable_checking+set}" = set; then :
- enableval=$enable_checking; case "${enableval}" in
- no|none) ac_checking= ;;
- *) ac_checking=yes ;;
-esac
-fi
-if test x$ac_checking != x ; then
-
-$as_echo "#define ENABLE_CHECKING 1" >>confdefs.h
-
-fi
-
-# Check whether --enable-targets was given.
-if test "${enable_targets+set}" = set; then :
- enableval=$enable_targets; case "${enableval}" in
- yes | "") as_fn_error $? "enable-targets option must specify target names or 'all'" "$LINENO" 5
- ;;
- no) enable_targets= ;;
- *) enable_targets=$enableval ;;
-esac
-fi
-
-
-# Check whether --enable-deterministic-archives was given.
-if test "${enable_deterministic_archives+set}" = set; then :
- enableval=$enable_deterministic_archives;
-if test "${enableval}" = no; then
- default_ar_deterministic=0
-else
- default_ar_deterministic=1
-fi
-else
- default_ar_deterministic=0
-fi
-
-
-
-cat >>confdefs.h <<_ACEOF
-#define DEFAULT_AR_DETERMINISTIC $default_ar_deterministic
-_ACEOF
-
-
-
-# Check whether --enable-default-strings-all was given.
-if test "${enable_default_strings_all+set}" = set; then :
- enableval=$enable_default_strings_all;
-if test "${enableval}" = no; then
- default_strings_all=0
-else
- default_strings_all=1
-fi
-else
- default_strings_all=1
-fi
-
-
-
-cat >>confdefs.h <<_ACEOF
-#define DEFAULT_STRINGS_ALL $default_strings_all
-_ACEOF
-
-
-
-# Check whether --enable-f-for-ifunc-symbols was given.
-if test "${enable_f_for_ifunc_symbols+set}" = set; then :
- enableval=$enable_f_for_ifunc_symbols;
-if test "${enableval}" = no; then
- default_f_for_ifunc=0
-else
- default_f_for_ifunc=1
-fi
-else
- default_f_for_ifunc=0
-fi
-
-
-
-cat >>confdefs.h <<_ACEOF
-#define DEFAULT_F_FOR_IFUNC_SYMBOLS $default_f_for_ifunc
-_ACEOF
-
-
-
-# Check whether --enable-follow-debug-links was given.
-if test "${enable_follow_debug_links+set}" = set; then :
- enableval=$enable_follow_debug_links;
-if test "${enableval}" = no; then
- default_for_follow_links=0
-else
- default_for_follow_links=1
-fi
-else
- default_for_follow_links=1
-fi
-
-
-
-cat >>confdefs.h <<_ACEOF
-#define DEFAULT_FOR_FOLLOW_LINKS $default_for_follow_links
-_ACEOF
-
-
-
-
-
-# Check whether --enable-colored-disassembly was given.
-if test "${enable_colored_disassembly+set}" = set; then :
- enableval=$enable_colored_disassembly;
-if test "${enableval}" = no; then
- default_for_colored_disassembly=0
-else
- default_for_colored_disassembly=1
-fi
-else
- default_for_colored_disassembly=0
-fi
-
-
-
-cat >>confdefs.h <<_ACEOF
-#define DEFAULT_FOR_COLORED_DISASSEMBLY $default_for_colored_disassembly
-_ACEOF
-
-
-
-
-
-
-
-
-
-
-if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
-set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_PKG_CONFIG+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $PKG_CONFIG in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
- ;;
- *)
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
- ;;
-esac
-fi
-PKG_CONFIG=$ac_cv_path_PKG_CONFIG
-if test -n "$PKG_CONFIG"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
-$as_echo "$PKG_CONFIG" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_path_PKG_CONFIG"; then
- ac_pt_PKG_CONFIG=$PKG_CONFIG
- # Extract the first word of "pkg-config", so it can be a program name with args.
-set dummy pkg-config; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $ac_pt_PKG_CONFIG in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
- ;;
- *)
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
- ;;
-esac
-fi
-ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
-if test -n "$ac_pt_PKG_CONFIG"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5
-$as_echo "$ac_pt_PKG_CONFIG" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_pt_PKG_CONFIG" = x; then
- PKG_CONFIG=""
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- PKG_CONFIG=$ac_pt_PKG_CONFIG
- fi
-else
- PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
-fi
-
-fi
-if test -n "$PKG_CONFIG"; then
- _pkg_min_version=0.9.0
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5
-$as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; }
- if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- PKG_CONFIG=""
- fi
-fi
-
-# Handle optional debuginfod support as well as optional section
-# downloading support.
-#
-# Define HAVE_LIBDEBUGINFOD if libdebuginfod is found with version >= 0.179.
-#
-# Define HAVE_LIBDEBUGINFOD_FIND_SECTION if libdebuginfod is found with
-# version >= 0.188.
-
-# Check whether --with-debuginfod was given.
-if test "${with_debuginfod+set}" = set; then :
- withval=$with_debuginfod;
-else
- with_debuginfod=auto
-fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use debuginfod" >&5
-$as_echo_n "checking whether to use debuginfod... " >&6; }
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_debuginfod" >&5
-$as_echo "$with_debuginfod" >&6; }
-
-if test "x$with_debuginfod" != xno; then
-
-pkg_failed=no
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for libdebuginfod >= 0.188" >&5
-$as_echo_n "checking for libdebuginfod >= 0.188... " >&6; }
-
-if test -n "$DEBUGINFOD_CFLAGS"; then
- pkg_cv_DEBUGINFOD_CFLAGS="$DEBUGINFOD_CFLAGS"
- elif test -n "$PKG_CONFIG"; then
- if test -n "$PKG_CONFIG" && \
- { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libdebuginfod >= 0.188\""; } >&5
- ($PKG_CONFIG --exists --print-errors "libdebuginfod >= 0.188") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- pkg_cv_DEBUGINFOD_CFLAGS=`$PKG_CONFIG --cflags "libdebuginfod >= 0.188" 2>/dev/null`
- test "x$?" != "x0" && pkg_failed=yes
-else
- pkg_failed=yes
-fi
- else
- pkg_failed=untried
-fi
-if test -n "$DEBUGINFOD_LIBS"; then
- pkg_cv_DEBUGINFOD_LIBS="$DEBUGINFOD_LIBS"
- elif test -n "$PKG_CONFIG"; then
- if test -n "$PKG_CONFIG" && \
- { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libdebuginfod >= 0.188\""; } >&5
- ($PKG_CONFIG --exists --print-errors "libdebuginfod >= 0.188") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- pkg_cv_DEBUGINFOD_LIBS=`$PKG_CONFIG --libs "libdebuginfod >= 0.188" 2>/dev/null`
- test "x$?" != "x0" && pkg_failed=yes
-else
- pkg_failed=yes
-fi
- else
- pkg_failed=untried
-fi
-
-if test $pkg_failed = no; then
- pkg_save_LDFLAGS="$LDFLAGS"
- LDFLAGS="$LDFLAGS $pkg_cv_DEBUGINFOD_LIBS"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
-
-else
- pkg_failed=yes
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LDFLAGS=$pkg_save_LDFLAGS
-fi
-
-
-
-if test $pkg_failed = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-
-if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
- _pkg_short_errors_supported=yes
-else
- _pkg_short_errors_supported=no
-fi
- if test $_pkg_short_errors_supported = yes; then
- DEBUGINFOD_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libdebuginfod >= 0.188" 2>&1`
- else
- DEBUGINFOD_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libdebuginfod >= 0.188" 2>&1`
- fi
- # Put the nasty error message in config.log where it belongs
- echo "$DEBUGINFOD_PKG_ERRORS" >&5
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libdebuginfod is missing or some features may be unavailable." >&5
-$as_echo "$as_me: WARNING: libdebuginfod is missing or some features may be unavailable." >&2;}
-elif test $pkg_failed = untried; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libdebuginfod is missing or some features may be unavailable." >&5
-$as_echo "$as_me: WARNING: libdebuginfod is missing or some features may be unavailable." >&2;}
-else
- DEBUGINFOD_CFLAGS=$pkg_cv_DEBUGINFOD_CFLAGS
- DEBUGINFOD_LIBS=$pkg_cv_DEBUGINFOD_LIBS
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-
-$as_echo "#define HAVE_LIBDEBUGINFOD_FIND_SECTION 1" >>confdefs.h
-
-fi
-
-
-pkg_failed=no
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for libdebuginfod >= 0.179" >&5
-$as_echo_n "checking for libdebuginfod >= 0.179... " >&6; }
-
-if test -n "$DEBUGINFOD_CFLAGS"; then
- pkg_cv_DEBUGINFOD_CFLAGS="$DEBUGINFOD_CFLAGS"
- elif test -n "$PKG_CONFIG"; then
- if test -n "$PKG_CONFIG" && \
- { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libdebuginfod >= 0.179\""; } >&5
- ($PKG_CONFIG --exists --print-errors "libdebuginfod >= 0.179") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- pkg_cv_DEBUGINFOD_CFLAGS=`$PKG_CONFIG --cflags "libdebuginfod >= 0.179" 2>/dev/null`
- test "x$?" != "x0" && pkg_failed=yes
-else
- pkg_failed=yes
-fi
- else
- pkg_failed=untried
-fi
-if test -n "$DEBUGINFOD_LIBS"; then
- pkg_cv_DEBUGINFOD_LIBS="$DEBUGINFOD_LIBS"
- elif test -n "$PKG_CONFIG"; then
- if test -n "$PKG_CONFIG" && \
- { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libdebuginfod >= 0.179\""; } >&5
- ($PKG_CONFIG --exists --print-errors "libdebuginfod >= 0.179") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- pkg_cv_DEBUGINFOD_LIBS=`$PKG_CONFIG --libs "libdebuginfod >= 0.179" 2>/dev/null`
- test "x$?" != "x0" && pkg_failed=yes
-else
- pkg_failed=yes
-fi
- else
- pkg_failed=untried
-fi
-
-if test $pkg_failed = no; then
- pkg_save_LDFLAGS="$LDFLAGS"
- LDFLAGS="$LDFLAGS $pkg_cv_DEBUGINFOD_LIBS"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
-
-else
- pkg_failed=yes
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LDFLAGS=$pkg_save_LDFLAGS
-fi
-
-
-
-if test $pkg_failed = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-
-if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
- _pkg_short_errors_supported=yes
-else
- _pkg_short_errors_supported=no
-fi
- if test $_pkg_short_errors_supported = yes; then
- DEBUGINFOD_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libdebuginfod >= 0.179" 2>&1`
- else
- DEBUGINFOD_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libdebuginfod >= 0.179" 2>&1`
- fi
- # Put the nasty error message in config.log where it belongs
- echo "$DEBUGINFOD_PKG_ERRORS" >&5
-
- if test "x$with_debuginfod" = xyes; then
- as_fn_error $? "\"--with-debuginfod was given, but libdebuginfod is missing or unusable.\"" "$LINENO" 5
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libdebuginfod is missing or unusable; some features may be unavailable." >&5
-$as_echo "$as_me: WARNING: libdebuginfod is missing or unusable; some features may be unavailable." >&2;}
- fi
-elif test $pkg_failed = untried; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- if test "x$with_debuginfod" = xyes; then
- as_fn_error $? "\"--with-debuginfod was given, but libdebuginfod is missing or unusable.\"" "$LINENO" 5
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libdebuginfod is missing or unusable; some features may be unavailable." >&5
-$as_echo "$as_me: WARNING: libdebuginfod is missing or unusable; some features may be unavailable." >&2;}
- fi
-else
- DEBUGINFOD_CFLAGS=$pkg_cv_DEBUGINFOD_CFLAGS
- DEBUGINFOD_LIBS=$pkg_cv_DEBUGINFOD_LIBS
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-
-$as_echo "#define HAVE_LIBDEBUGINFOD 1" >>confdefs.h
-
-fi
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: debuginfod support disabled; some features may be unavailable." >&5
-$as_echo "$as_me: WARNING: debuginfod support disabled; some features may be unavailable." >&2;}
-fi
-
-
- # Check whether --enable-libctf was given.
-if test "${enable_libctf+set}" = set; then :
- enableval=$enable_libctf;
- case "$enableval" in
- yes|no) ;;
- *) as_fn_error $? "Argument to enable/disable libctf must be yes or no" "$LINENO" 5 ;;
- esac
-
-else
- enable_libctf=yes
-fi
-
-
-if test "${enable_libctf}" = yes; then
-
-$as_echo "#define ENABLE_LIBCTF 1" >>confdefs.h
-
-fi
- if test "${enable_libctf}" = yes; then
- ENABLE_LIBCTF_TRUE=
- ENABLE_LIBCTF_FALSE='#'
-else
- ENABLE_LIBCTF_TRUE='#'
- ENABLE_LIBCTF_FALSE=
-fi
-
-
-
-# Set the 'development' global.
-. $srcdir/../bfd/development.sh
-
-# Set acp_cpp_for_build variable
-ac_cpp_for_build="$CC_FOR_BUILD -E $CPPFLAGS_FOR_BUILD"
-
-# Default set of GCC warnings to enable.
-GCC_WARN_CFLAGS="-W -Wall -Wstrict-prototypes -Wmissing-prototypes"
-GCC_WARN_CFLAGS_FOR_BUILD="-W -Wall -Wstrict-prototypes -Wmissing-prototypes"
-
-# Add -Wshadow if the compiler is a sufficiently recent version of GCC.
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-__GNUC__
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "(^[0-3]$|^__GNUC__$)" >/dev/null 2>&1; then :
-
-else
- GCC_WARN_CFLAGS="$GCC_WARN_CFLAGS -Wshadow"
-fi
-rm -f conftest*
-
-
-# Add -Wstack-usage if the compiler is a sufficiently recent version of GCC.
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-__GNUC__
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "(^[0-4]$|^__GNUC__$)" >/dev/null 2>&1; then :
-
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-__clang__
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "^__clang__$" >/dev/null 2>&1; then :
- GCC_WARN_CFLAGS="$GCC_WARN_CFLAGS -Wstack-usage=262144"
-fi
-rm -f conftest*
-
-fi
-rm -f conftest*
-
-
-# Set WARN_WRITE_STRINGS if the compiler supports -Wwrite-strings.
-WARN_WRITE_STRINGS=""
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-__GNUC__
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "(^[0-3]$|^__GNUC__$)" >/dev/null 2>&1; then :
-
-else
- WARN_WRITE_STRINGS="-Wwrite-strings"
-fi
-rm -f conftest*
-
-
-# Verify CC_FOR_BUILD to be compatible with warning flags
-
-# Add -Wshadow if the compiler is a sufficiently recent version of GCC.
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-__GNUC__
-_ACEOF
-if (eval "$ac_cpp_for_build conftest.$ac_ext") 2>&5 |
- $EGREP "(^[0-3]$|^__GNUC__$)" >/dev/null 2>&1; then :
-
-else
- GCC_WARN_CFLAGS_FOR_BUILD="$GCC_WARN_CFLAGS_FOR_BUILD -Wshadow"
-fi
-rm -f conftest*
-
-
-# Add -Wstack-usage if the compiler is a sufficiently recent version of GCC.
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-__GNUC__
-_ACEOF
-if (eval "$ac_cpp_for_build conftest.$ac_ext") 2>&5 |
- $EGREP "(^[0-4]$|^__GNUC__$)" >/dev/null 2>&1; then :
-
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-__clang__
-_ACEOF
-if (eval "$ac_cpp_for_build conftest.$ac_ext") 2>&5 |
- $EGREP "^__clang__$" >/dev/null 2>&1; then :
- GCC_WARN_CFLAGS_FOR_BUILD="$GCC_WARN_CFLAGS_FOR_BUILD -Wstack-usage=262144"
-fi
-rm -f conftest*
-
-fi
-rm -f conftest*
-
-
-# Check whether --enable-werror was given.
-if test "${enable_werror+set}" = set; then :
- enableval=$enable_werror; case "${enableval}" in
- yes | y) ERROR_ON_WARNING="yes" ;;
- no | n) ERROR_ON_WARNING="no" ;;
- *) as_fn_error $? "bad value ${enableval} for --enable-werror" "$LINENO" 5 ;;
- esac
-fi
-
-
-# Disable -Wformat by default when using gcc on mingw
-case "${host}" in
- *-*-mingw32*)
- if test "${GCC}" = yes -a -z "${ERROR_ON_WARNING}" ; then
- GCC_WARN_CFLAGS="$GCC_WARN_CFLAGS -Wno-format"
- GCC_WARN_CFLAGS_FOR_BUILD="$GCC_WARN_CFLAGS_FOR_BUILD -Wno-format"
- fi
- ;;
- *) ;;
-esac
-
-# Enable -Werror by default when using gcc. Turn it off for releases.
-if test "${GCC}" = yes -a -z "${ERROR_ON_WARNING}" -a "$development" = true ; then
- ERROR_ON_WARNING=yes
-fi
-
-NO_WERROR=
-if test "${ERROR_ON_WARNING}" = yes ; then
- GCC_WARN_CFLAGS="$GCC_WARN_CFLAGS -Werror"
- GCC_WARN_CFLAGS_FOR_BUILD="$GCC_WARN_CFLAGS_FOR_BUILD -Werror"
- NO_WERROR="-Wno-error"
-fi
-
-if test "${GCC}" = yes ; then
- WARN_CFLAGS="${GCC_WARN_CFLAGS}"
- WARN_CFLAGS_FOR_BUILD="${GCC_WARN_CFLAGS_FOR_BUILD}"
-fi
-
-# Check whether --enable-build-warnings was given.
-if test "${enable_build_warnings+set}" = set; then :
- enableval=$enable_build_warnings; case "${enableval}" in
- yes) WARN_CFLAGS="${GCC_WARN_CFLAGS}"
- WARN_CFLAGS_FOR_BUILD="${GCC_WARN_CFLAGS_FOR_BUILD}";;
- no) if test "${GCC}" = yes ; then
- WARN_CFLAGS="-w"
- WARN_CFLAGS_FOR_BUILD="-w"
- fi;;
- ,*) t=`echo "${enableval}" | sed -e "s/,/ /g"`
- WARN_CFLAGS="${GCC_WARN_CFLAGS} ${t}"
- WARN_CFLAGS_FOR_BUILD="${GCC_WARN_CFLAGS_FOR_BUILD} ${t}";;
- *,) t=`echo "${enableval}" | sed -e "s/,/ /g"`
- WARN_CFLAGS="${t} ${GCC_WARN_CFLAGS}"
- WARN_CFLAGS_FOR_BUILD="${t} ${GCC_WARN_CFLAGS_FOR_BUILD}";;
- *) WARN_CFLAGS=`echo "${enableval}" | sed -e "s/,/ /g"`
- WARN_CFLAGS_FOR_BUILD=`echo "${enableval}" | sed -e "s/,/ /g"`;;
-esac
-fi
-
-
-if test x"$silent" != x"yes" && test x"$WARN_CFLAGS" != x""; then
- echo "Setting warning flags = $WARN_CFLAGS" 6>&1
-fi
-
-
-
-
-
-
-
-ac_config_headers="$ac_config_headers config.h:config.in"
-
-
-
-
-if test -z "$target" ; then
- as_fn_error $? "Unrecognized target system type; please check config.sub." "$LINENO" 5
-fi
-if test -z "$host" ; then
- as_fn_error $? "Unrecognized host system type; please check config.sub." "$LINENO" 5
-fi
-
-for ac_prog in 'bison -y' byacc
-do
- # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_YACC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$YACC"; then
- ac_cv_prog_YACC="$YACC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_YACC="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-YACC=$ac_cv_prog_YACC
-if test -n "$YACC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $YACC" >&5
-$as_echo "$YACC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$YACC" && break
-done
-test -n "$YACC" || YACC="yacc"
-
-for ac_prog in flex lex
-do
- # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_LEX+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$LEX"; then
- ac_cv_prog_LEX="$LEX" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_LEX="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-LEX=$ac_cv_prog_LEX
-if test -n "$LEX"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LEX" >&5
-$as_echo "$LEX" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$LEX" && break
-done
-test -n "$LEX" || LEX=":"
-
-case "$LEX" in
- :|*"missing "*) ;;
- *) cat >conftest.l <<_ACEOF
-%%
-a { ECHO; }
-b { REJECT; }
-c { yymore (); }
-d { yyless (1); }
-e { /* IRIX 6.5 flex 2.5.4 underquotes its yyless argument. */
- yyless ((input () != 0)); }
-f { unput (yytext[0]); }
-. { BEGIN INITIAL; }
-%%
-#ifdef YYTEXT_POINTER
-extern char *yytext;
-#endif
-int
-main (void)
-{
- return ! yylex () + ! yywrap ();
-}
-_ACEOF
-{ { ac_try="$LEX conftest.l"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$LEX conftest.l") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking lex output file root" >&5
-$as_echo_n "checking lex output file root... " >&6; }
-if ${ac_cv_prog_lex_root+:} false; then :
- $as_echo_n "(cached) " >&6
-else
-
-if test -f lex.yy.c; then
- ac_cv_prog_lex_root=lex.yy
-elif test -f lexyy.c; then
- ac_cv_prog_lex_root=lexyy
-else
- as_fn_error $? "cannot find output from $LEX; giving up" "$LINENO" 5
-fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_lex_root" >&5
-$as_echo "$ac_cv_prog_lex_root" >&6; }
-LEX_OUTPUT_ROOT=$ac_cv_prog_lex_root
-
-if test -z "${LEXLIB+set}"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking lex library" >&5
-$as_echo_n "checking lex library... " >&6; }
-if ${ac_cv_lib_lex+:} false; then :
- $as_echo_n "(cached) " >&6
-else
-
- ac_save_LIBS=$LIBS
- ac_cv_lib_lex='none needed'
- for ac_lib in '' -lfl -ll; do
- LIBS="$ac_lib $ac_save_LIBS"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-`cat $LEX_OUTPUT_ROOT.c`
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_lib_lex=$ac_lib
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- test "$ac_cv_lib_lex" != 'none needed' && break
- done
- LIBS=$ac_save_LIBS
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_lex" >&5
-$as_echo "$ac_cv_lib_lex" >&6; }
- test "$ac_cv_lib_lex" != 'none needed' && LEXLIB=$ac_cv_lib_lex
-fi
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether yytext is a pointer" >&5
-$as_echo_n "checking whether yytext is a pointer... " >&6; }
-if ${ac_cv_prog_lex_yytext_pointer+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- # POSIX says lex can declare yytext either as a pointer or an array; the
-# default is implementation-dependent. Figure out which it is, since
-# not all implementations provide the %pointer and %array declarations.
-ac_cv_prog_lex_yytext_pointer=no
-ac_save_LIBS=$LIBS
-LIBS="$LEXLIB $ac_save_LIBS"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
- #define YYTEXT_POINTER 1
-`cat $LEX_OUTPUT_ROOT.c`
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_prog_lex_yytext_pointer=yes
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_save_LIBS
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_lex_yytext_pointer" >&5
-$as_echo "$ac_cv_prog_lex_yytext_pointer" >&6; }
-if test $ac_cv_prog_lex_yytext_pointer = yes; then
-
-$as_echo "#define YYTEXT_POINTER 1" >>confdefs.h
-
-fi
-rm -f conftest.l $LEX_OUTPUT_ROOT.c
- ;;
-esac
-if test "$LEX" = :; then
- LEX=${am_missing_run}flex
-fi
-
-ALL_LINGUAS="bg ca da es fi fr hr id it ja pt ro ru rw sk sr sv tr uk vi zh_CN zh_TW"
-
- MKINSTALLDIRS=
- if test -n "$ac_aux_dir"; then
- case "$ac_aux_dir" in
- /*) MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs" ;;
- *) MKINSTALLDIRS="\$(top_builddir)/$ac_aux_dir/mkinstalldirs" ;;
- esac
- fi
- if test -z "$MKINSTALLDIRS"; then
- MKINSTALLDIRS="\$(top_srcdir)/mkinstalldirs"
- fi
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NLS is requested" >&5
-$as_echo_n "checking whether NLS is requested... " >&6; }
- # Check whether --enable-nls was given.
-if test "${enable_nls+set}" = set; then :
- enableval=$enable_nls; USE_NLS=$enableval
-else
- USE_NLS=yes
-fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_NLS" >&5
-$as_echo "$USE_NLS" >&6; }
-
-
-
-
-
-
-# Prepare PATH_SEPARATOR.
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-
-# Find out how to test for executable files. Don't use a zero-byte file,
-# as systems may use methods other than mode bits to determine executability.
-cat >conf$$.file <<_ASEOF
-#! /bin/sh
-exit 0
-_ASEOF
-chmod +x conf$$.file
-if test -x conf$$.file >/dev/null 2>&1; then
- ac_executable_p="test -x"
-else
- ac_executable_p="test -f"
-fi
-rm -f conf$$.file
-
-# Extract the first word of "msgfmt", so it can be a program name with args.
-set dummy msgfmt; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_MSGFMT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case "$MSGFMT" in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
- ;;
- *)
- ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH; do
- IFS="$ac_save_IFS"
- test -z "$ac_dir" && ac_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
- if $ac_dir/$ac_word --statistics /dev/null >/dev/null 2>&1 &&
- (if $ac_dir/$ac_word --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- ac_cv_path_MSGFMT="$ac_dir/$ac_word$ac_exec_ext"
- break 2
- fi
- fi
- done
- done
- IFS="$ac_save_IFS"
- test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT=":"
- ;;
-esac
-fi
-MSGFMT="$ac_cv_path_MSGFMT"
-if test "$MSGFMT" != ":"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGFMT" >&5
-$as_echo "$MSGFMT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- # Extract the first word of "gmsgfmt", so it can be a program name with args.
-set dummy gmsgfmt; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_GMSGFMT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $GMSGFMT in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
- ;;
- *)
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_path_GMSGFMT="$as_dir/$ac_word$ac_exec_ext"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
- test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT"
- ;;
-esac
-fi
-GMSGFMT=$ac_cv_path_GMSGFMT
-if test -n "$GMSGFMT"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GMSGFMT" >&5
-$as_echo "$GMSGFMT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-
-
-# Prepare PATH_SEPARATOR.
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-
-# Find out how to test for executable files. Don't use a zero-byte file,
-# as systems may use methods other than mode bits to determine executability.
-cat >conf$$.file <<_ASEOF
-#! /bin/sh
-exit 0
-_ASEOF
-chmod +x conf$$.file
-if test -x conf$$.file >/dev/null 2>&1; then
- ac_executable_p="test -x"
-else
- ac_executable_p="test -f"
-fi
-rm -f conf$$.file
-
-# Extract the first word of "xgettext", so it can be a program name with args.
-set dummy xgettext; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_XGETTEXT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case "$XGETTEXT" in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
- ;;
- *)
- ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH; do
- IFS="$ac_save_IFS"
- test -z "$ac_dir" && ac_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
- if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >/dev/null 2>&1 &&
- (if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- ac_cv_path_XGETTEXT="$ac_dir/$ac_word$ac_exec_ext"
- break 2
- fi
- fi
- done
- done
- IFS="$ac_save_IFS"
- test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":"
- ;;
-esac
-fi
-XGETTEXT="$ac_cv_path_XGETTEXT"
-if test "$XGETTEXT" != ":"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XGETTEXT" >&5
-$as_echo "$XGETTEXT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- rm -f messages.po
-
-
-# Prepare PATH_SEPARATOR.
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-
-# Find out how to test for executable files. Don't use a zero-byte file,
-# as systems may use methods other than mode bits to determine executability.
-cat >conf$$.file <<_ASEOF
-#! /bin/sh
-exit 0
-_ASEOF
-chmod +x conf$$.file
-if test -x conf$$.file >/dev/null 2>&1; then
- ac_executable_p="test -x"
-else
- ac_executable_p="test -f"
-fi
-rm -f conf$$.file
-
-# Extract the first word of "msgmerge", so it can be a program name with args.
-set dummy msgmerge; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_MSGMERGE+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case "$MSGMERGE" in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_MSGMERGE="$MSGMERGE" # Let the user override the test with a path.
- ;;
- *)
- ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH; do
- IFS="$ac_save_IFS"
- test -z "$ac_dir" && ac_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
- if $ac_dir/$ac_word --update -q /dev/null /dev/null >/dev/null 2>&1; then
- ac_cv_path_MSGMERGE="$ac_dir/$ac_word$ac_exec_ext"
- break 2
- fi
- fi
- done
- done
- IFS="$ac_save_IFS"
- test -z "$ac_cv_path_MSGMERGE" && ac_cv_path_MSGMERGE=":"
- ;;
-esac
-fi
-MSGMERGE="$ac_cv_path_MSGMERGE"
-if test "$MSGMERGE" != ":"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGMERGE" >&5
-$as_echo "$MSGMERGE" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- if test "$GMSGFMT" != ":"; then
- if $GMSGFMT --statistics /dev/null >/dev/null 2>&1 &&
- (if $GMSGFMT --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- : ;
- else
- GMSGFMT=`echo "$GMSGFMT" | sed -e 's,^.*/,,'`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: found $GMSGFMT program is not GNU msgfmt; ignore it" >&5
-$as_echo "found $GMSGFMT program is not GNU msgfmt; ignore it" >&6; }
- GMSGFMT=":"
- fi
- fi
-
- if test "$XGETTEXT" != ":"; then
- if $XGETTEXT --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >/dev/null 2>&1 &&
- (if $XGETTEXT --omit-header --copyright-holder= --msgid-bugs-address= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- : ;
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: found xgettext program is not GNU xgettext; ignore it" >&5
-$as_echo "found xgettext program is not GNU xgettext; ignore it" >&6; }
- XGETTEXT=":"
- fi
- rm -f messages.po
- fi
-
- ac_config_commands="$ac_config_commands default-1"
-
-
-
- if test "X$prefix" = "XNONE"; then
- acl_final_prefix="$ac_default_prefix"
- else
- acl_final_prefix="$prefix"
- fi
- if test "X$exec_prefix" = "XNONE"; then
- acl_final_exec_prefix='${prefix}'
- else
- acl_final_exec_prefix="$exec_prefix"
- fi
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- eval acl_final_exec_prefix=\"$acl_final_exec_prefix\"
- prefix="$acl_save_prefix"
-
-
-# Check whether --with-gnu-ld was given.
-if test "${with_gnu_ld+set}" = set; then :
- withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
-else
- with_gnu_ld=no
-fi
-
-# Prepare PATH_SEPARATOR.
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-ac_prog=ld
-if test "$GCC" = yes; then
- # Check if gcc -print-prog-name=ld gives a path.
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by GCC" >&5
-$as_echo_n "checking for ld used by GCC... " >&6; }
- case $host in
- *-*-mingw*)
- # gcc leaves a trailing carriage return which upsets mingw
- ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
- *)
- ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
- esac
- case $ac_prog in
- # Accept absolute paths.
- [\\/]* | [A-Za-z]:[\\/]*)
- re_direlt='/[^/][^/]*/\.\./'
- # Canonicalize the path of ld
- ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
- while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
- ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
- done
- test -z "$LD" && LD="$ac_prog"
- ;;
- "")
- # If it fails, then pretend we aren't using GCC.
- ac_prog=ld
- ;;
- *)
- # If it is relative, then search for the first ld in PATH.
- with_gnu_ld=unknown
- ;;
- esac
-elif test "$with_gnu_ld" = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
-$as_echo_n "checking for GNU ld... " >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
-$as_echo_n "checking for non-GNU ld... " >&6; }
-fi
-if ${acl_cv_path_LD+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -z "$LD"; then
- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
- for ac_dir in $PATH; do
- test -z "$ac_dir" && ac_dir=.
- if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
- acl_cv_path_LD="$ac_dir/$ac_prog"
- # Check to see if the program is GNU ld. I'd rather use --version,
- # but apparently some GNU ld's only accept -v.
- # Break only if it was the GNU/non-GNU ld that we prefer.
- if "$acl_cv_path_LD" -v 2>&1 < /dev/null | $EGREP '(GNU|with BFD)' > /dev/null; then
- test "$with_gnu_ld" != no && break
- else
- test "$with_gnu_ld" != yes && break
- fi
- fi
- done
- IFS="$ac_save_ifs"
-else
- acl_cv_path_LD="$LD" # Let the user override the test with a path.
-fi
-fi
-
-LD="$acl_cv_path_LD"
-if test -n "$LD"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
-$as_echo "$LD" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
-$as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
-if ${acl_cv_prog_gnu_ld+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- # I'd rather use --version here, but apparently some GNU ld's only accept -v.
-if $LD -v 2>&1 </dev/null | $EGREP '(GNU|with BFD)' 1>&5; then
- acl_cv_prog_gnu_ld=yes
-else
- acl_cv_prog_gnu_ld=no
-fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $acl_cv_prog_gnu_ld" >&5
-$as_echo "$acl_cv_prog_gnu_ld" >&6; }
-with_gnu_ld=$acl_cv_prog_gnu_ld
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shared library run path origin" >&5
-$as_echo_n "checking for shared library run path origin... " >&6; }
-if ${acl_cv_rpath+:} false; then :
- $as_echo_n "(cached) " >&6
-else
-
- CC="$CC" GCC="$GCC" LDFLAGS="$LDFLAGS" LD="$LD" with_gnu_ld="$with_gnu_ld" \
- ${CONFIG_SHELL-/bin/sh} "$ac_aux_dir/config.rpath" "$host" > conftest.sh
- . ./conftest.sh
- rm -f ./conftest.sh
- acl_cv_rpath=done
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $acl_cv_rpath" >&5
-$as_echo "$acl_cv_rpath" >&6; }
- wl="$acl_cv_wl"
- libext="$acl_cv_libext"
- shlibext="$acl_cv_shlibext"
- hardcode_libdir_flag_spec="$acl_cv_hardcode_libdir_flag_spec"
- hardcode_libdir_separator="$acl_cv_hardcode_libdir_separator"
- hardcode_direct="$acl_cv_hardcode_direct"
- hardcode_minus_L="$acl_cv_hardcode_minus_L"
- # Check whether --enable-rpath was given.
-if test "${enable_rpath+set}" = set; then :
- enableval=$enable_rpath; :
-else
- enable_rpath=yes
-fi
-
-
-
-
-
-
-
-
- use_additional=yes
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
-
- eval additional_includedir=\"$includedir\"
- eval additional_libdir=\"$libdir\"
-
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
-
-# Check whether --with-libiconv-prefix was given.
-if test "${with_libiconv_prefix+set}" = set; then :
- withval=$with_libiconv_prefix;
- if test "X$withval" = "Xno"; then
- use_additional=no
- else
- if test "X$withval" = "X"; then
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
-
- eval additional_includedir=\"$includedir\"
- eval additional_libdir=\"$libdir\"
-
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- else
- additional_includedir="$withval/include"
- additional_libdir="$withval/lib"
- fi
- fi
-
-fi
-
-
-# Check whether --with-libiconv-type was given.
-if test "${with_libiconv_type+set}" = set; then :
- withval=$with_libiconv_type; with_libiconv_type=$withval
-else
- with_libiconv_type=auto
-fi
-
- lib_type=`eval echo \$with_libiconv_type`
-
- LIBICONV=
- LTLIBICONV=
- INCICONV=
- rpathdirs=
- ltrpathdirs=
- names_already_handled=
- names_next_round='iconv '
- while test -n "$names_next_round"; do
- names_this_round="$names_next_round"
- names_next_round=
- for name in $names_this_round; do
- already_handled=
- for n in $names_already_handled; do
- if test "$n" = "$name"; then
- already_handled=yes
- break
- fi
- done
- if test -z "$already_handled"; then
- names_already_handled="$names_already_handled $name"
- uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
- eval value=\"\$HAVE_LIB$uppername\"
- if test -n "$value"; then
- if test "$value" = yes; then
- eval value=\"\$LIB$uppername\"
- test -z "$value" || LIBICONV="${LIBICONV}${LIBICONV:+ }$value"
- eval value=\"\$LTLIB$uppername\"
- test -z "$value" || LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$value"
- else
- :
- fi
- else
- found_dir=
- found_la=
- found_so=
- found_a=
- if test $use_additional = yes; then
- if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext" && test x$lib_type != xstatic; then
- found_dir="$additional_libdir"
- found_so="$additional_libdir/lib$name.$shlibext"
- if test -f "$additional_libdir/lib$name.la"; then
- found_la="$additional_libdir/lib$name.la"
- fi
- elif test x$lib_type != xshared; then
- if test -f "$additional_libdir/lib$name.$libext"; then
- found_dir="$additional_libdir"
- found_a="$additional_libdir/lib$name.$libext"
- if test -f "$additional_libdir/lib$name.la"; then
- found_la="$additional_libdir/lib$name.la"
- fi
- fi
- fi
- fi
- if test "X$found_dir" = "X"; then
- for x in $LDFLAGS $LTLIBICONV; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- case "$x" in
- -L*)
- dir=`echo "X$x" | sed -e 's/^X-L//'`
- if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext" && test x$lib_type != xstatic; then
- found_dir="$dir"
- found_so="$dir/lib$name.$shlibext"
- if test -f "$dir/lib$name.la"; then
- found_la="$dir/lib$name.la"
- fi
- elif test x$lib_type != xshared; then
- if test -f "$dir/lib$name.$libext"; then
- found_dir="$dir"
- found_a="$dir/lib$name.$libext"
- if test -f "$dir/lib$name.la"; then
- found_la="$dir/lib$name.la"
- fi
- fi
- fi
- ;;
- esac
- if test "X$found_dir" != "X"; then
- break
- fi
- done
- fi
- if test "X$found_dir" != "X"; then
- LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$found_dir -l$name"
- if test "X$found_so" != "X"; then
- if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
- else
- haveit=
- for x in $ltrpathdirs; do
- if test "X$x" = "X$found_dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- ltrpathdirs="$ltrpathdirs $found_dir"
- fi
- if test "$hardcode_direct" = yes; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
- else
- if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
- haveit=
- for x in $rpathdirs; do
- if test "X$x" = "X$found_dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- rpathdirs="$rpathdirs $found_dir"
- fi
- else
- haveit=
- for x in $LDFLAGS $LIBICONV; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-L$found_dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir"
- fi
- if test "$hardcode_minus_L" != no; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
- else
- LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name"
- fi
- fi
- fi
- fi
- else
- if test "X$found_a" != "X"; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }$found_a"
- else
- LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir -l$name"
- fi
- fi
- additional_includedir=
- case "$found_dir" in
- */lib | */lib/)
- basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
- additional_includedir="$basedir/include"
- ;;
- esac
- if test "X$additional_includedir" != "X"; then
- if test "X$additional_includedir" != "X/usr/include"; then
- haveit=
- if test "X$additional_includedir" = "X/usr/local/include"; then
- if test -n "$GCC"; then
- case $host_os in
- linux*) haveit=yes;;
- esac
- fi
- fi
- if test -z "$haveit"; then
- for x in $CPPFLAGS $INCICONV; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-I$additional_includedir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- if test -d "$additional_includedir"; then
- INCICONV="${INCICONV}${INCICONV:+ }-I$additional_includedir"
- fi
- fi
- fi
- fi
- fi
- if test -n "$found_la"; then
- save_libdir="$libdir"
- case "$found_la" in
- */* | *\\*) . "$found_la" ;;
- *) . "./$found_la" ;;
- esac
- libdir="$save_libdir"
- for dep in $dependency_libs; do
- case "$dep" in
- -L*)
- additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
- if test "X$additional_libdir" != "X/usr/lib"; then
- haveit=
- if test "X$additional_libdir" = "X/usr/local/lib"; then
- if test -n "$GCC"; then
- case $host_os in
- linux*) haveit=yes;;
- esac
- fi
- fi
- if test -z "$haveit"; then
- haveit=
- for x in $LDFLAGS $LIBICONV; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-L$additional_libdir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- if test -d "$additional_libdir"; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }-L$additional_libdir"
- fi
- fi
- haveit=
- for x in $LDFLAGS $LTLIBICONV; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-L$additional_libdir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- if test -d "$additional_libdir"; then
- LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$additional_libdir"
- fi
- fi
- fi
- fi
- ;;
- -R*)
- dir=`echo "X$dep" | sed -e 's/^X-R//'`
- if test "$enable_rpath" != no; then
- haveit=
- for x in $rpathdirs; do
- if test "X$x" = "X$dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- rpathdirs="$rpathdirs $dir"
- fi
- haveit=
- for x in $ltrpathdirs; do
- if test "X$x" = "X$dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- ltrpathdirs="$ltrpathdirs $dir"
- fi
- fi
- ;;
- -l*)
- names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
- ;;
- *.la)
- names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
- ;;
- *)
- LIBICONV="${LIBICONV}${LIBICONV:+ }$dep"
- LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$dep"
- ;;
- esac
- done
- fi
- else
- if test "x$lib_type" = "xauto" || test "x$lib_type" = "xshared"; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name"
- LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-l$name"
- else
- LIBICONV="${LIBICONV}${LIBICONV:+ }-l:lib$name.$libext"
- LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-l:lib$name.$libext"
- fi
- fi
- fi
- fi
- done
- done
- if test "X$rpathdirs" != "X"; then
- if test -n "$hardcode_libdir_separator"; then
- alldirs=
- for found_dir in $rpathdirs; do
- alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
- done
- acl_save_libdir="$libdir"
- libdir="$alldirs"
- eval flag=\"$hardcode_libdir_flag_spec\"
- libdir="$acl_save_libdir"
- LIBICONV="${LIBICONV}${LIBICONV:+ }$flag"
- else
- for found_dir in $rpathdirs; do
- acl_save_libdir="$libdir"
- libdir="$found_dir"
- eval flag=\"$hardcode_libdir_flag_spec\"
- libdir="$acl_save_libdir"
- LIBICONV="${LIBICONV}${LIBICONV:+ }$flag"
- done
- fi
- fi
- if test "X$ltrpathdirs" != "X"; then
- for found_dir in $ltrpathdirs; do
- LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-R$found_dir"
- done
- fi
-
-
-
-
-
-if test -f ../gettext/uninstalled-config.sh; then
- relative_builddir='$(top_builddir)/../gettext'
- . ../gettext/uninstalled-config.sh
-else
- # The sister gettext directory doesn't exist and won't collect information on
- # using gettext for us. Call a bundled AM_GNU_GETTEXT.
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CFPreferencesCopyAppValue" >&5
-$as_echo_n "checking for CFPreferencesCopyAppValue... " >&6; }
-if ${gt_cv_func_CFPreferencesCopyAppValue+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- gt_save_LIBS="$LIBS"
- LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <CoreFoundation/CFPreferences.h>
-int
-main ()
-{
-CFPreferencesCopyAppValue(NULL, NULL)
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- gt_cv_func_CFPreferencesCopyAppValue=yes
-else
- gt_cv_func_CFPreferencesCopyAppValue=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LIBS="$gt_save_LIBS"
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_CFPreferencesCopyAppValue" >&5
-$as_echo "$gt_cv_func_CFPreferencesCopyAppValue" >&6; }
- if test $gt_cv_func_CFPreferencesCopyAppValue = yes; then
-
-$as_echo "#define HAVE_CFPREFERENCESCOPYAPPVALUE 1" >>confdefs.h
-
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CFLocaleCopyPreferredLanguages" >&5
-$as_echo_n "checking for CFLocaleCopyPreferredLanguages... " >&6; }
-if ${gt_cv_func_CFLocaleCopyPreferredLanguages+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- gt_save_LIBS="$LIBS"
- LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <CoreFoundation/CFLocale.h>
-int
-main ()
-{
-CFLocaleCopyPreferredLanguages();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- gt_cv_func_CFLocaleCopyPreferredLanguages=yes
-else
- gt_cv_func_CFLocaleCopyPreferredLanguages=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LIBS="$gt_save_LIBS"
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_CFLocaleCopyPreferredLanguages" >&5
-$as_echo "$gt_cv_func_CFLocaleCopyPreferredLanguages" >&6; }
- if test $gt_cv_func_CFLocaleCopyPreferredLanguages = yes; then
-
-$as_echo "#define HAVE_CFLOCALECOPYPREFERREDLANGUAGES 1" >>confdefs.h
-
- fi
- INTL_MACOSX_LIBS=
- if test $gt_cv_func_CFPreferencesCopyAppValue = yes \
- || test $gt_cv_func_CFLocaleCopyPreferredLanguages = yes; then
- INTL_MACOSX_LIBS="-Wl,-framework -Wl,CoreFoundation -Wl,-framework -Wl,CoreServices"
- fi
-
-
-
-
-
-
- LIBINTL=
- LTLIBINTL=
- POSUB=
-
- case " $gt_needs " in
- *" need-formatstring-macros "*) gt_api_version=3 ;;
- *" need-ngettext "*) gt_api_version=2 ;;
- *) gt_api_version=1 ;;
- esac
- gt_func_gnugettext_libc="gt_cv_func_gnugettext${gt_api_version}_libc"
- gt_func_gnugettext_libintl="gt_cv_func_gnugettext${gt_api_version}_libintl"
-
- if test "$USE_NLS" = "yes"; then
- gt_use_preinstalled_gnugettext=no
-
-
- if test $gt_api_version -ge 3; then
- gt_revision_test_code='
-#ifndef __GNU_GETTEXT_SUPPORTED_REVISION
-#define __GNU_GETTEXT_SUPPORTED_REVISION(major) ((major) == 0 ? 0 : -1)
-#endif
-typedef int array [2 * (__GNU_GETTEXT_SUPPORTED_REVISION(0) >= 1) - 1];
-'
- else
- gt_revision_test_code=
- fi
- if test $gt_api_version -ge 2; then
- gt_expression_test_code=' + * ngettext ("", "", 0)'
- else
- gt_expression_test_code=
- fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU gettext in libc" >&5
-$as_echo_n "checking for GNU gettext in libc... " >&6; }
-if eval \${$gt_func_gnugettext_libc+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <libintl.h>
-#ifndef __GNU_GETTEXT_SUPPORTED_REVISION
-extern int _nl_msg_cat_cntr;
-extern int *_nl_domain_bindings;
-#define __GNU_GETTEXT_SYMBOL_EXPRESSION (_nl_msg_cat_cntr + *_nl_domain_bindings)
-#else
-#define __GNU_GETTEXT_SYMBOL_EXPRESSION 0
-#endif
-$gt_revision_test_code
-
-int
-main ()
-{
-
-bindtextdomain ("", "");
-return * gettext ("")$gt_expression_test_code + __GNU_GETTEXT_SYMBOL_EXPRESSION
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- eval "$gt_func_gnugettext_libc=yes"
-else
- eval "$gt_func_gnugettext_libc=no"
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-fi
-eval ac_res=\$$gt_func_gnugettext_libc
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
-
- if { eval "gt_val=\$$gt_func_gnugettext_libc"; test "$gt_val" != "yes"; }; then
-
-
-
-
-
- am_save_CPPFLAGS="$CPPFLAGS"
-
- for element in $INCICONV; do
- haveit=
- for x in $CPPFLAGS; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X$element"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
- fi
- done
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for iconv" >&5
-$as_echo_n "checking for iconv... " >&6; }
-if ${am_cv_func_iconv+:} false; then :
- $as_echo_n "(cached) " >&6
-else
-
- am_cv_func_iconv="no, consider installing GNU libiconv"
- am_cv_lib_iconv=no
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <stdlib.h>
-#include <iconv.h>
-
-int
-main ()
-{
-iconv_t cd = iconv_open("","");
- iconv(cd,NULL,NULL,NULL,NULL);
- iconv_close(cd);
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- am_cv_func_iconv=yes
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- if test "$am_cv_func_iconv" != yes; then
- am_save_LIBS="$LIBS"
- LIBS="$LIBS $LIBICONV"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <stdlib.h>
-#include <iconv.h>
-
-int
-main ()
-{
-iconv_t cd = iconv_open("","");
- iconv(cd,NULL,NULL,NULL,NULL);
- iconv_close(cd);
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- am_cv_lib_iconv=yes
- am_cv_func_iconv=yes
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LIBS="$am_save_LIBS"
- fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv" >&5
-$as_echo "$am_cv_func_iconv" >&6; }
- if test "$am_cv_func_iconv" = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working iconv" >&5
-$as_echo_n "checking for working iconv... " >&6; }
-if ${am_cv_func_iconv_works+:} false; then :
- $as_echo_n "(cached) " >&6
-else
-
- am_save_LIBS="$LIBS"
- if test $am_cv_lib_iconv = yes; then
- LIBS="$LIBS $LIBICONV"
- fi
- am_cv_func_iconv_works=no
- for ac_iconv_const in '' 'const'; do
- if test "$cross_compiling" = yes; then :
- case "$host_os" in
- aix* | hpux*) am_cv_func_iconv_works="guessing no" ;;
- *) am_cv_func_iconv_works="guessing yes" ;;
- esac
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <iconv.h>
-#include <string.h>
-
-#ifndef ICONV_CONST
-# define ICONV_CONST $ac_iconv_const
-#endif
-
-int
-main ()
-{
-int result = 0;
- /* Test against AIX 5.1...7.2 bug: Failures are not distinguishable from
- successful returns. This is even documented in
- <https://www.ibm.com/support/knowledgecenter/ssw_aix_72/i_bostechref/iconv.html> */
- {
- iconv_t cd_utf8_to_88591 = iconv_open ("ISO8859-1", "UTF-8");
- if (cd_utf8_to_88591 != (iconv_t)(-1))
- {
- static ICONV_CONST char input[] = "\342\202\254"; /* EURO SIGN */
- char buf[10];
- ICONV_CONST char *inptr = input;
- size_t inbytesleft = strlen (input);
- char *outptr = buf;
- size_t outbytesleft = sizeof (buf);
- size_t res = iconv (cd_utf8_to_88591,
- &inptr, &inbytesleft,
- &outptr, &outbytesleft);
- if (res == 0)
- result |= 1;
- iconv_close (cd_utf8_to_88591);
- }
- }
- /* Test against Solaris 10 bug: Failures are not distinguishable from
- successful returns. */
- {
- iconv_t cd_ascii_to_88591 = iconv_open ("ISO8859-1", "646");
- if (cd_ascii_to_88591 != (iconv_t)(-1))
- {
- static ICONV_CONST char input[] = "\263";
- char buf[10];
- ICONV_CONST char *inptr = input;
- size_t inbytesleft = strlen (input);
- char *outptr = buf;
- size_t outbytesleft = sizeof (buf);
- size_t res = iconv (cd_ascii_to_88591,
- &inptr, &inbytesleft,
- &outptr, &outbytesleft);
- if (res == 0)
- result |= 2;
- iconv_close (cd_ascii_to_88591);
- }
- }
- /* Test against AIX 6.1..7.1 bug: Buffer overrun. */
- {
- iconv_t cd_88591_to_utf8 = iconv_open ("UTF-8", "ISO-8859-1");
- if (cd_88591_to_utf8 != (iconv_t)(-1))
- {
- static ICONV_CONST char input[] = "\304";
- static char buf[2] = { (char)0xDE, (char)0xAD };
- ICONV_CONST char *inptr = input;
- size_t inbytesleft = 1;
- char *outptr = buf;
- size_t outbytesleft = 1;
- size_t res = iconv (cd_88591_to_utf8,
- &inptr, &inbytesleft,
- &outptr, &outbytesleft);
- if (res != (size_t)(-1) || outptr - buf > 1 || buf[1] != (char)0xAD)
- result |= 4;
- iconv_close (cd_88591_to_utf8);
- }
- }
-#if 0 /* This bug could be worked around by the caller. */
- /* Test against HP-UX 11.11 bug: Positive return value instead of 0. */
- {
- iconv_t cd_88591_to_utf8 = iconv_open ("utf8", "iso88591");
- if (cd_88591_to_utf8 != (iconv_t)(-1))
- {
- static ICONV_CONST char input[] = "\304rger mit b\366sen B\374bchen ohne Augenma\337";
- char buf[50];
- ICONV_CONST char *inptr = input;
- size_t inbytesleft = strlen (input);
- char *outptr = buf;
- size_t outbytesleft = sizeof (buf);
- size_t res = iconv (cd_88591_to_utf8,
- &inptr, &inbytesleft,
- &outptr, &outbytesleft);
- if ((int)res > 0)
- result |= 8;
- iconv_close (cd_88591_to_utf8);
- }
- }
-#endif
- /* Test against HP-UX 11.11 bug: No converter from EUC-JP to UTF-8 is
- provided. */
- {
- /* Try standardized names. */
- iconv_t cd1 = iconv_open ("UTF-8", "EUC-JP");
- /* Try IRIX, OSF/1 names. */
- iconv_t cd2 = iconv_open ("UTF-8", "eucJP");
- /* Try AIX names. */
- iconv_t cd3 = iconv_open ("UTF-8", "IBM-eucJP");
- /* Try HP-UX names. */
- iconv_t cd4 = iconv_open ("utf8", "eucJP");
- if (cd1 == (iconv_t)(-1) && cd2 == (iconv_t)(-1)
- && cd3 == (iconv_t)(-1) && cd4 == (iconv_t)(-1))
- result |= 16;
- if (cd1 != (iconv_t)(-1))
- iconv_close (cd1);
- if (cd2 != (iconv_t)(-1))
- iconv_close (cd2);
- if (cd3 != (iconv_t)(-1))
- iconv_close (cd3);
- if (cd4 != (iconv_t)(-1))
- iconv_close (cd4);
- }
- return result;
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_run "$LINENO"; then :
- am_cv_func_iconv_works=yes
-fi
-rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
- conftest.$ac_objext conftest.beam conftest.$ac_ext
-fi
-
- test "$am_cv_func_iconv_works" = no || break
- done
- LIBS="$am_save_LIBS"
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv_works" >&5
-$as_echo "$am_cv_func_iconv_works" >&6; }
- case "$am_cv_func_iconv_works" in
- *no) am_func_iconv=no am_cv_lib_iconv=no ;;
- *) am_func_iconv=yes ;;
- esac
- else
- am_func_iconv=no am_cv_lib_iconv=no
- fi
- if test "$am_func_iconv" = yes; then
-
-$as_echo "#define HAVE_ICONV 1" >>confdefs.h
-
- fi
- if test "$am_cv_lib_iconv" = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libiconv" >&5
-$as_echo_n "checking how to link with libiconv... " >&6; }
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBICONV" >&5
-$as_echo "$LIBICONV" >&6; }
- else
- CPPFLAGS="$am_save_CPPFLAGS"
- LIBICONV=
- LTLIBICONV=
- fi
-
-
-
-
-
-
- use_additional=yes
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
-
- eval additional_includedir=\"$includedir\"
- eval additional_libdir=\"$libdir\"
-
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
-
-# Check whether --with-libintl-prefix was given.
-if test "${with_libintl_prefix+set}" = set; then :
- withval=$with_libintl_prefix;
- if test "X$withval" = "Xno"; then
- use_additional=no
- else
- if test "X$withval" = "X"; then
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
-
- eval additional_includedir=\"$includedir\"
- eval additional_libdir=\"$libdir\"
-
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- else
- additional_includedir="$withval/include"
- additional_libdir="$withval/lib"
- fi
- fi
-
-fi
-
-
-# Check whether --with-libintl-type was given.
-if test "${with_libintl_type+set}" = set; then :
- withval=$with_libintl_type; with_libintl_type=$withval
-else
- with_libintl_type=auto
-fi
-
- lib_type=`eval echo \$with_libintl_type`
-
- LIBINTL=
- LTLIBINTL=
- INCINTL=
- rpathdirs=
- ltrpathdirs=
- names_already_handled=
- names_next_round='intl '
- while test -n "$names_next_round"; do
- names_this_round="$names_next_round"
- names_next_round=
- for name in $names_this_round; do
- already_handled=
- for n in $names_already_handled; do
- if test "$n" = "$name"; then
- already_handled=yes
- break
- fi
- done
- if test -z "$already_handled"; then
- names_already_handled="$names_already_handled $name"
- uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
- eval value=\"\$HAVE_LIB$uppername\"
- if test -n "$value"; then
- if test "$value" = yes; then
- eval value=\"\$LIB$uppername\"
- test -z "$value" || LIBINTL="${LIBINTL}${LIBINTL:+ }$value"
- eval value=\"\$LTLIB$uppername\"
- test -z "$value" || LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }$value"
- else
- :
- fi
- else
- found_dir=
- found_la=
- found_so=
- found_a=
- if test $use_additional = yes; then
- if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext" && test x$lib_type != xstatic; then
- found_dir="$additional_libdir"
- found_so="$additional_libdir/lib$name.$shlibext"
- if test -f "$additional_libdir/lib$name.la"; then
- found_la="$additional_libdir/lib$name.la"
- fi
- elif test x$lib_type != xshared; then
- if test -f "$additional_libdir/lib$name.$libext"; then
- found_dir="$additional_libdir"
- found_a="$additional_libdir/lib$name.$libext"
- if test -f "$additional_libdir/lib$name.la"; then
- found_la="$additional_libdir/lib$name.la"
- fi
- fi
- fi
- fi
- if test "X$found_dir" = "X"; then
- for x in $LDFLAGS $LTLIBINTL; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- case "$x" in
- -L*)
- dir=`echo "X$x" | sed -e 's/^X-L//'`
- if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext" && test x$lib_type != xstatic; then
- found_dir="$dir"
- found_so="$dir/lib$name.$shlibext"
- if test -f "$dir/lib$name.la"; then
- found_la="$dir/lib$name.la"
- fi
- elif test x$lib_type != xshared; then
- if test -f "$dir/lib$name.$libext"; then
- found_dir="$dir"
- found_a="$dir/lib$name.$libext"
- if test -f "$dir/lib$name.la"; then
- found_la="$dir/lib$name.la"
- fi
- fi
- fi
- ;;
- esac
- if test "X$found_dir" != "X"; then
- break
- fi
- done
- fi
- if test "X$found_dir" != "X"; then
- LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-L$found_dir -l$name"
- if test "X$found_so" != "X"; then
- if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
- else
- haveit=
- for x in $ltrpathdirs; do
- if test "X$x" = "X$found_dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- ltrpathdirs="$ltrpathdirs $found_dir"
- fi
- if test "$hardcode_direct" = yes; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
- else
- if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
- haveit=
- for x in $rpathdirs; do
- if test "X$x" = "X$found_dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- rpathdirs="$rpathdirs $found_dir"
- fi
- else
- haveit=
- for x in $LDFLAGS $LIBINTL; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-L$found_dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }-L$found_dir"
- fi
- if test "$hardcode_minus_L" != no; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
- else
- LIBINTL="${LIBINTL}${LIBINTL:+ }-l$name"
- fi
- fi
- fi
- fi
- else
- if test "X$found_a" != "X"; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }$found_a"
- else
- LIBINTL="${LIBINTL}${LIBINTL:+ }-L$found_dir -l$name"
- fi
- fi
- additional_includedir=
- case "$found_dir" in
- */lib | */lib/)
- basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
- additional_includedir="$basedir/include"
- ;;
- esac
- if test "X$additional_includedir" != "X"; then
- if test "X$additional_includedir" != "X/usr/include"; then
- haveit=
- if test "X$additional_includedir" = "X/usr/local/include"; then
- if test -n "$GCC"; then
- case $host_os in
- linux*) haveit=yes;;
- esac
- fi
- fi
- if test -z "$haveit"; then
- for x in $CPPFLAGS $INCINTL; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-I$additional_includedir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- if test -d "$additional_includedir"; then
- INCINTL="${INCINTL}${INCINTL:+ }-I$additional_includedir"
- fi
- fi
- fi
- fi
- fi
- if test -n "$found_la"; then
- save_libdir="$libdir"
- case "$found_la" in
- */* | *\\*) . "$found_la" ;;
- *) . "./$found_la" ;;
- esac
- libdir="$save_libdir"
- for dep in $dependency_libs; do
- case "$dep" in
- -L*)
- additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
- if test "X$additional_libdir" != "X/usr/lib"; then
- haveit=
- if test "X$additional_libdir" = "X/usr/local/lib"; then
- if test -n "$GCC"; then
- case $host_os in
- linux*) haveit=yes;;
- esac
- fi
- fi
- if test -z "$haveit"; then
- haveit=
- for x in $LDFLAGS $LIBINTL; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-L$additional_libdir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- if test -d "$additional_libdir"; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }-L$additional_libdir"
- fi
- fi
- haveit=
- for x in $LDFLAGS $LTLIBINTL; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-L$additional_libdir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- if test -d "$additional_libdir"; then
- LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-L$additional_libdir"
- fi
- fi
- fi
- fi
- ;;
- -R*)
- dir=`echo "X$dep" | sed -e 's/^X-R//'`
- if test "$enable_rpath" != no; then
- haveit=
- for x in $rpathdirs; do
- if test "X$x" = "X$dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- rpathdirs="$rpathdirs $dir"
- fi
- haveit=
- for x in $ltrpathdirs; do
- if test "X$x" = "X$dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- ltrpathdirs="$ltrpathdirs $dir"
- fi
- fi
- ;;
- -l*)
- names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
- ;;
- *.la)
- names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
- ;;
- *)
- LIBINTL="${LIBINTL}${LIBINTL:+ }$dep"
- LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }$dep"
- ;;
- esac
- done
- fi
- else
- if test "x$lib_type" = "xauto" || test "x$lib_type" = "xshared"; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }-l$name"
- LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-l$name"
- else
- LIBINTL="${LIBINTL}${LIBINTL:+ }-l:lib$name.$libext"
- LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-l:lib$name.$libext"
- fi
- fi
- fi
- fi
- done
- done
- if test "X$rpathdirs" != "X"; then
- if test -n "$hardcode_libdir_separator"; then
- alldirs=
- for found_dir in $rpathdirs; do
- alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
- done
- acl_save_libdir="$libdir"
- libdir="$alldirs"
- eval flag=\"$hardcode_libdir_flag_spec\"
- libdir="$acl_save_libdir"
- LIBINTL="${LIBINTL}${LIBINTL:+ }$flag"
- else
- for found_dir in $rpathdirs; do
- acl_save_libdir="$libdir"
- libdir="$found_dir"
- eval flag=\"$hardcode_libdir_flag_spec\"
- libdir="$acl_save_libdir"
- LIBINTL="${LIBINTL}${LIBINTL:+ }$flag"
- done
- fi
- fi
- if test "X$ltrpathdirs" != "X"; then
- for found_dir in $ltrpathdirs; do
- LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-R$found_dir"
- done
- fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU gettext in libintl" >&5
-$as_echo_n "checking for GNU gettext in libintl... " >&6; }
-if eval \${$gt_func_gnugettext_libintl+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- gt_save_CPPFLAGS="$CPPFLAGS"
- CPPFLAGS="$CPPFLAGS $INCINTL"
- gt_save_LIBS="$LIBS"
- LIBS="$LIBS $LIBINTL"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <libintl.h>
-#ifndef __GNU_GETTEXT_SUPPORTED_REVISION
-extern int _nl_msg_cat_cntr;
-extern
-#ifdef __cplusplus
-"C"
-#endif
-const char *_nl_expand_alias (const char *);
-#define __GNU_GETTEXT_SYMBOL_EXPRESSION (_nl_msg_cat_cntr + *_nl_expand_alias (""))
-#else
-#define __GNU_GETTEXT_SYMBOL_EXPRESSION 0
-#endif
-$gt_revision_test_code
-
-int
-main ()
-{
-
-bindtextdomain ("", "");
-return * gettext ("")$gt_expression_test_code + __GNU_GETTEXT_SYMBOL_EXPRESSION
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- eval "$gt_func_gnugettext_libintl=yes"
-else
- eval "$gt_func_gnugettext_libintl=no"
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" != yes; } && test -n "$LIBICONV"; then
- LIBS="$LIBS $LIBICONV"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <libintl.h>
-#ifndef __GNU_GETTEXT_SUPPORTED_REVISION
-extern int _nl_msg_cat_cntr;
-extern
-#ifdef __cplusplus
-"C"
-#endif
-const char *_nl_expand_alias (const char *);
-#define __GNU_GETTEXT_SYMBOL_EXPRESSION (_nl_msg_cat_cntr + *_nl_expand_alias (""))
-#else
-#define __GNU_GETTEXT_SYMBOL_EXPRESSION 0
-#endif
-$gt_revision_test_code
-
-int
-main ()
-{
-
-bindtextdomain ("", "");
-return * gettext ("")$gt_expression_test_code + __GNU_GETTEXT_SYMBOL_EXPRESSION
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- LIBINTL="$LIBINTL $LIBICONV"
- LTLIBINTL="$LTLIBINTL $LTLIBICONV"
- eval "$gt_func_gnugettext_libintl=yes"
-
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- fi
- CPPFLAGS="$gt_save_CPPFLAGS"
- LIBS="$gt_save_LIBS"
-fi
-eval ac_res=\$$gt_func_gnugettext_libintl
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
- fi
-
- if { eval "gt_val=\$$gt_func_gnugettext_libc"; test "$gt_val" = "yes"; } \
- || { { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; } \
- && test "$PACKAGE" != gettext-runtime \
- && test "$PACKAGE" != gettext-tools; }; then
- gt_use_preinstalled_gnugettext=yes
- else
- LIBINTL=
- LTLIBINTL=
- INCINTL=
- fi
-
-
-
- if test -n "$INTL_MACOSX_LIBS"; then
- if test "$gt_use_preinstalled_gnugettext" = "yes" \
- || test "$nls_cv_use_gnu_gettext" = "yes"; then
- LIBINTL="$LIBINTL $INTL_MACOSX_LIBS"
- LTLIBINTL="$LTLIBINTL $INTL_MACOSX_LIBS"
- fi
- fi
-
- if test "$gt_use_preinstalled_gnugettext" = "yes" \
- || test "$nls_cv_use_gnu_gettext" = "yes"; then
-
-$as_echo "#define ENABLE_NLS 1" >>confdefs.h
-
- else
- USE_NLS=no
- fi
- fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use NLS" >&5
-$as_echo_n "checking whether to use NLS... " >&6; }
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_NLS" >&5
-$as_echo "$USE_NLS" >&6; }
- if test "$USE_NLS" = "yes"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking where the gettext function comes from" >&5
-$as_echo_n "checking where the gettext function comes from... " >&6; }
- if test "$gt_use_preinstalled_gnugettext" = "yes"; then
- if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; }; then
- gt_source="external libintl"
- else
- gt_source="libc"
- fi
- else
- gt_source="included intl directory"
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_source" >&5
-$as_echo "$gt_source" >&6; }
- fi
-
- if test "$USE_NLS" = "yes"; then
-
- if test "$gt_use_preinstalled_gnugettext" = "yes"; then
- if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; }; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libintl" >&5
-$as_echo_n "checking how to link with libintl... " >&6; }
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBINTL" >&5
-$as_echo "$LIBINTL" >&6; }
-
- for element in $INCINTL; do
- haveit=
- for x in $CPPFLAGS; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X$element"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
- fi
- done
-
- fi
-
-
-$as_echo "#define HAVE_GETTEXT 1" >>confdefs.h
-
-
-$as_echo "#define HAVE_DCGETTEXT 1" >>confdefs.h
-
- fi
-
- POSUB=po
- fi
-
-
-
- INTLLIBS="$LIBINTL"
-
-
-
-
-
-
-fi
-
-
-
-
-
-
-
-
-
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NLS is requested" >&5
-$as_echo_n "checking whether NLS is requested... " >&6; }
-if test x"$USE_NLS" != xyes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-
-$as_echo "#define ENABLE_NLS 1" >>confdefs.h
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for catalogs to be installed" >&5
-$as_echo_n "checking for catalogs to be installed... " >&6; }
- # Look for .po and .gmo files in the source directory.
- CATALOGS=
- XLINGUAS=
- for cat in $srcdir/po/*.gmo $srcdir/po/*.po; do
- # If there aren't any .gmo files the shell will give us the
- # literal string "../path/to/srcdir/po/*.gmo" which has to be
- # weeded out.
- case "$cat" in *\**)
- continue;;
- esac
- # The quadruple backslash is collapsed to a double backslash
- # by the backticks, then collapsed again by the double quotes,
- # leaving us with one backslash in the sed expression (right
- # before the dot that mustn't act as a wildcard).
- cat=`echo $cat | sed -e "s!$srcdir/po/!!" -e "s!\\\\.po!.gmo!"`
- lang=`echo $cat | sed -e "s!\\\\.gmo!!"`
- # The user is allowed to set LINGUAS to a list of languages to
- # install catalogs for. If it's empty that means "all of them."
- if test "x$LINGUAS" = x; then
- CATALOGS="$CATALOGS $cat"
- XLINGUAS="$XLINGUAS $lang"
- else
- case "$LINGUAS" in *$lang*)
- CATALOGS="$CATALOGS $cat"
- XLINGUAS="$XLINGUAS $lang"
- ;;
- esac
- fi
- done
- LINGUAS="$XLINGUAS"
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LINGUAS" >&5
-$as_echo "$LINGUAS" >&6; }
-
-
- DATADIRNAME=share
-
- INSTOBJEXT=.mo
-
- GENCAT=gencat
-
- CATOBJEXT=.gmo
-
-fi
-
-
-
-
-# Prepare PATH_SEPARATOR.
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-
-# Find out how to test for executable files. Don't use a zero-byte file,
-# as systems may use methods other than mode bits to determine executability.
-cat >conf$$.file <<_ASEOF
-#! /bin/sh
-exit 0
-_ASEOF
-chmod +x conf$$.file
-if test -x conf$$.file >/dev/null 2>&1; then
- ac_executable_p="test -x"
-else
- ac_executable_p="test -f"
-fi
-rm -f conf$$.file
-
-# Extract the first word of "msgfmt", so it can be a program name with args.
-set dummy msgfmt; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_MSGFMT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case "$MSGFMT" in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
- ;;
- *)
- ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH; do
- IFS="$ac_save_IFS"
- test -z "$ac_dir" && ac_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
- if $ac_dir/$ac_word --statistics /dev/null >/dev/null 2>&1 &&
- (if $ac_dir/$ac_word --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- ac_cv_path_MSGFMT="$ac_dir/$ac_word$ac_exec_ext"
- break 2
- fi
- fi
- done
- done
- IFS="$ac_save_IFS"
- test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT=":"
- ;;
-esac
-fi
-MSGFMT="$ac_cv_path_MSGFMT"
-if test "$MSGFMT" != ":"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGFMT" >&5
-$as_echo "$MSGFMT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- # Extract the first word of "gmsgfmt", so it can be a program name with args.
-set dummy gmsgfmt; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_GMSGFMT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $GMSGFMT in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
- ;;
- *)
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_path_GMSGFMT="$as_dir/$ac_word$ac_exec_ext"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
- test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT"
- ;;
-esac
-fi
-GMSGFMT=$ac_cv_path_GMSGFMT
-if test -n "$GMSGFMT"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GMSGFMT" >&5
-$as_echo "$GMSGFMT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-
-
-# Prepare PATH_SEPARATOR.
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-
-# Find out how to test for executable files. Don't use a zero-byte file,
-# as systems may use methods other than mode bits to determine executability.
-cat >conf$$.file <<_ASEOF
-#! /bin/sh
-exit 0
-_ASEOF
-chmod +x conf$$.file
-if test -x conf$$.file >/dev/null 2>&1; then
- ac_executable_p="test -x"
-else
- ac_executable_p="test -f"
-fi
-rm -f conf$$.file
-
-# Extract the first word of "xgettext", so it can be a program name with args.
-set dummy xgettext; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_XGETTEXT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case "$XGETTEXT" in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
- ;;
- *)
- ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH; do
- IFS="$ac_save_IFS"
- test -z "$ac_dir" && ac_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
- if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >/dev/null 2>&1 &&
- (if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- ac_cv_path_XGETTEXT="$ac_dir/$ac_word$ac_exec_ext"
- break 2
- fi
- fi
- done
- done
- IFS="$ac_save_IFS"
- test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":"
- ;;
-esac
-fi
-XGETTEXT="$ac_cv_path_XGETTEXT"
-if test "$XGETTEXT" != ":"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XGETTEXT" >&5
-$as_echo "$XGETTEXT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- rm -f messages.po
-
-
-# Prepare PATH_SEPARATOR.
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-
-# Find out how to test for executable files. Don't use a zero-byte file,
-# as systems may use methods other than mode bits to determine executability.
-cat >conf$$.file <<_ASEOF
-#! /bin/sh
-exit 0
-_ASEOF
-chmod +x conf$$.file
-if test -x conf$$.file >/dev/null 2>&1; then
- ac_executable_p="test -x"
-else
- ac_executable_p="test -f"
-fi
-rm -f conf$$.file
-
-# Extract the first word of "msgmerge", so it can be a program name with args.
-set dummy msgmerge; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_MSGMERGE+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case "$MSGMERGE" in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_MSGMERGE="$MSGMERGE" # Let the user override the test with a path.
- ;;
- *)
- ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH; do
- IFS="$ac_save_IFS"
- test -z "$ac_dir" && ac_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
- if $ac_dir/$ac_word --update -q /dev/null /dev/null >/dev/null 2>&1; then
- ac_cv_path_MSGMERGE="$ac_dir/$ac_word$ac_exec_ext"
- break 2
- fi
- fi
- done
- done
- IFS="$ac_save_IFS"
- test -z "$ac_cv_path_MSGMERGE" && ac_cv_path_MSGMERGE=":"
- ;;
-esac
-fi
-MSGMERGE="$ac_cv_path_MSGMERGE"
-if test "$MSGMERGE" != ":"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGMERGE" >&5
-$as_echo "$MSGMERGE" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- if test "$GMSGFMT" != ":"; then
- if $GMSGFMT --statistics /dev/null >/dev/null 2>&1 &&
- (if $GMSGFMT --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- : ;
- else
- GMSGFMT=`echo "$GMSGFMT" | sed -e 's,^.*/,,'`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: found $GMSGFMT program is not GNU msgfmt; ignore it" >&5
-$as_echo "found $GMSGFMT program is not GNU msgfmt; ignore it" >&6; }
- GMSGFMT=":"
- fi
- fi
-
- if test "$XGETTEXT" != ":"; then
- if $XGETTEXT --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >/dev/null 2>&1 &&
- (if $XGETTEXT --omit-header --copyright-holder= --msgid-bugs-address= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- : ;
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: found xgettext program is not GNU xgettext; ignore it" >&5
-$as_echo "found xgettext program is not GNU xgettext; ignore it" >&6; }
- XGETTEXT=":"
- fi
- rm -f messages.po
- fi
-
- ac_config_commands="$ac_config_commands default-2"
-
-
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable maintainer-specific portions of Makefiles" >&5
-$as_echo_n "checking whether to enable maintainer-specific portions of Makefiles... " >&6; }
- # Check whether --enable-maintainer-mode was given.
-if test "${enable_maintainer_mode+set}" = set; then :
- enableval=$enable_maintainer_mode; USE_MAINTAINER_MODE=$enableval
-else
- USE_MAINTAINER_MODE=no
-fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_MAINTAINER_MODE" >&5
-$as_echo "$USE_MAINTAINER_MODE" >&6; }
- if test $USE_MAINTAINER_MODE = yes; then
- MAINTAINER_MODE_TRUE=
- MAINTAINER_MODE_FALSE='#'
-else
- MAINTAINER_MODE_TRUE='#'
- MAINTAINER_MODE_FALSE=
-fi
-
- MAINT=$MAINTAINER_MODE_TRUE
-
-
- if false; then
- GENINSRC_NEVER_TRUE=
- GENINSRC_NEVER_FALSE='#'
-else
- GENINSRC_NEVER_TRUE='#'
- GENINSRC_NEVER_FALSE=
-fi
-
-
-if test -n "$EXEEXT"; then
-
-$as_echo "#define HAVE_EXECUTABLE_SUFFIX 1" >>confdefs.h
-
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define EXECUTABLE_SUFFIX "${EXEEXT}"
-_ACEOF
-
-
-# host-specific stuff:
-
-HDEFINES=
-
-. ${srcdir}/../bfd/configure.host
-
-
-AR=${AR-ar}
-
-if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
-set dummy ${ac_tool_prefix}ranlib; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_RANLIB+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$RANLIB"; then
- ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-RANLIB=$ac_cv_prog_RANLIB
-if test -n "$RANLIB"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
-$as_echo "$RANLIB" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_RANLIB"; then
- ac_ct_RANLIB=$RANLIB
- # Extract the first word of "ranlib", so it can be a program name with args.
-set dummy ranlib; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_RANLIB"; then
- ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_RANLIB="ranlib"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
-if test -n "$ac_ct_RANLIB"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
-$as_echo "$ac_ct_RANLIB" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_RANLIB" = x; then
- RANLIB=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- RANLIB=$ac_ct_RANLIB
- fi
-else
- RANLIB="$ac_cv_prog_RANLIB"
-fi
-
-
-
-# Put a plausible default for CC_FOR_BUILD in Makefile.
-if test -z "$CC_FOR_BUILD"; then
- if test "x$cross_compiling" = "xno"; then
- CC_FOR_BUILD='$(CC)'
- else
- CC_FOR_BUILD=gcc
- fi
-fi
-
-# Also set EXEEXT_FOR_BUILD.
-if test "x$cross_compiling" = "xno"; then
- EXEEXT_FOR_BUILD='$(EXEEXT)'
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for build system executable suffix" >&5
-$as_echo_n "checking for build system executable suffix... " >&6; }
-if ${bfd_cv_build_exeext+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- rm -f conftest*
- echo 'int main () { return 0; }' > conftest.c
- bfd_cv_build_exeext=
- ${CC_FOR_BUILD} -o conftest conftest.c 1>&5 2>&5
- for file in conftest.*; do
- case $file in
- *.c | *.o | *.obj | *.ilk | *.pdb) ;;
- *) bfd_cv_build_exeext=`echo $file | sed -e s/conftest//` ;;
- esac
- done
- rm -f conftest*
- test x"${bfd_cv_build_exeext}" = x && bfd_cv_build_exeext=no
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_build_exeext" >&5
-$as_echo "$bfd_cv_build_exeext" >&6; }
- EXEEXT_FOR_BUILD=""
- test x"${bfd_cv_build_exeext}" != xno && EXEEXT_FOR_BUILD=${bfd_cv_build_exeext}
-fi
-
-
-DEMANGLER_NAME=c++filt
-case "${host}" in
- *-*-go32* | *-*-msdos*)
- DEMANGLER_NAME=cxxfilt
-esac
-
-
-# We use headers from include/ that check various HAVE_*_H macros, thus
-# should ensure they are set by configure. This is true even when C99
-# guarantees they are available.
-# plugin-api.h tests HAVE_STDINT_H and HAVE_INTTYPES_H
-# Besides those, we need to check anything used in binutils/ not in C99.
-for ac_header in fcntl.h inttypes.h stdint.h sys/file.h \
- sys/stat.h sys/time.h sys/types.h unistd.h
-do :
- as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
-ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
-if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
- cat >>confdefs.h <<_ACEOF
-#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
-_ACEOF
-
-fi
-
-done
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sys/wait.h that is POSIX.1 compatible" >&5
-$as_echo_n "checking for sys/wait.h that is POSIX.1 compatible... " >&6; }
-if ${ac_cv_header_sys_wait_h+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <sys/types.h>
-#include <sys/wait.h>
-#ifndef WEXITSTATUS
-# define WEXITSTATUS(stat_val) ((unsigned int) (stat_val) >> 8)
-#endif
-#ifndef WIFEXITED
-# define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
-#endif
-
-int
-main ()
-{
- int s;
- wait (&s);
- s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_header_sys_wait_h=yes
-else
- ac_cv_header_sys_wait_h=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_sys_wait_h" >&5
-$as_echo "$ac_cv_header_sys_wait_h" >&6; }
-if test $ac_cv_header_sys_wait_h = yes; then
-
-$as_echo "#define HAVE_SYS_WAIT_H 1" >>confdefs.h
-
-fi
-
-
-
-
- for ac_header in $ac_header_list
-do :
- as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
-ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
-"
-if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
- cat >>confdefs.h <<_ACEOF
-#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
-_ACEOF
-
-fi
-
-done
-
-
-
-
-
-
-
-save_ASAN_OPTIONS="$ASAN_OPTIONS"
- ASAN_OPTIONS=detect_leaks=0
- export ASAN_OPTIONS
-
-for ac_func in getpagesize
-do :
- ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize"
-if test "x$ac_cv_func_getpagesize" = xyes; then :
- cat >>confdefs.h <<_ACEOF
-#define HAVE_GETPAGESIZE 1
-_ACEOF
-
-fi
-done
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mmap" >&5
-$as_echo_n "checking for working mmap... " >&6; }
-if ${ac_cv_func_mmap_fixed_mapped+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test "$cross_compiling" = yes; then :
- ac_cv_func_mmap_fixed_mapped=no
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$ac_includes_default
-/* malloc might have been renamed as rpl_malloc. */
-#undef malloc
-
-/* Thanks to Mike Haertel and Jim Avera for this test.
- Here is a matrix of mmap possibilities:
- mmap private not fixed
- mmap private fixed at somewhere currently unmapped
- mmap private fixed at somewhere already mapped
- mmap shared not fixed
- mmap shared fixed at somewhere currently unmapped
- mmap shared fixed at somewhere already mapped
- For private mappings, we should verify that changes cannot be read()
- back from the file, nor mmap's back from the file at a different
- address. (There have been systems where private was not correctly
- implemented like the infamous i386 svr4.0, and systems where the
- VM page cache was not coherent with the file system buffer cache
- like early versions of FreeBSD and possibly contemporary NetBSD.)
- For shared mappings, we should conversely verify that changes get
- propagated back to all the places they're supposed to be.
-
- Grep wants private fixed already mapped.
- The main things grep needs to know about mmap are:
- * does it exist and is it safe to write into the mmap'd area
- * how to use it (BSD variants) */
-
-#include <fcntl.h>
-#include <sys/mman.h>
-
-#if !defined STDC_HEADERS && !defined HAVE_STDLIB_H
-char *malloc ();
-#endif
-
-/* This mess was copied from the GNU getpagesize.h. */
-#ifndef HAVE_GETPAGESIZE
-# ifdef _SC_PAGESIZE
-# define getpagesize() sysconf(_SC_PAGESIZE)
-# else /* no _SC_PAGESIZE */
-# ifdef HAVE_SYS_PARAM_H
-# include <sys/param.h>
-# ifdef EXEC_PAGESIZE
-# define getpagesize() EXEC_PAGESIZE
-# else /* no EXEC_PAGESIZE */
-# ifdef NBPG
-# define getpagesize() NBPG * CLSIZE
-# ifndef CLSIZE
-# define CLSIZE 1
-# endif /* no CLSIZE */
-# else /* no NBPG */
-# ifdef NBPC
-# define getpagesize() NBPC
-# else /* no NBPC */
-# ifdef PAGESIZE
-# define getpagesize() PAGESIZE
-# endif /* PAGESIZE */
-# endif /* no NBPC */
-# endif /* no NBPG */
-# endif /* no EXEC_PAGESIZE */
-# else /* no HAVE_SYS_PARAM_H */
-# define getpagesize() 8192 /* punt totally */
-# endif /* no HAVE_SYS_PARAM_H */
-# endif /* no _SC_PAGESIZE */
-
-#endif /* no HAVE_GETPAGESIZE */
-
-int
-main ()
-{
- char *data, *data2, *data3;
- const char *cdata2;
- int i, pagesize;
- int fd, fd2;
-
- pagesize = getpagesize ();
-
- /* First, make a file with some known garbage in it. */
- data = (char *) malloc (pagesize);
- if (!data)
- return 1;
- for (i = 0; i < pagesize; ++i)
- *(data + i) = rand ();
- umask (0);
- fd = creat ("conftest.mmap", 0600);
- if (fd < 0)
- return 2;
- if (write (fd, data, pagesize) != pagesize)
- return 3;
- close (fd);
-
- /* Next, check that the tail of a page is zero-filled. File must have
- non-zero length, otherwise we risk SIGBUS for entire page. */
- fd2 = open ("conftest.txt", O_RDWR | O_CREAT | O_TRUNC, 0600);
- if (fd2 < 0)
- return 4;
- cdata2 = "";
- if (write (fd2, cdata2, 1) != 1)
- return 5;
- data2 = (char *) mmap (0, pagesize, PROT_READ | PROT_WRITE, MAP_SHARED, fd2, 0L);
- if (data2 == MAP_FAILED)
- return 6;
- for (i = 0; i < pagesize; ++i)
- if (*(data2 + i))
- return 7;
- close (fd2);
- if (munmap (data2, pagesize))
- return 8;
-
- /* Next, try to mmap the file at a fixed address which already has
- something else allocated at it. If we can, also make sure that
- we see the same garbage. */
- fd = open ("conftest.mmap", O_RDWR);
- if (fd < 0)
- return 9;
- if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE,
- MAP_PRIVATE | MAP_FIXED, fd, 0L))
- return 10;
- for (i = 0; i < pagesize; ++i)
- if (*(data + i) != *(data2 + i))
- return 11;
-
- /* Finally, make sure that changes to the mapped area do not
- percolate back to the file as seen by read(). (This is a bug on
- some variants of i386 svr4.0.) */
- for (i = 0; i < pagesize; ++i)
- *(data2 + i) = *(data2 + i) + 1;
- data3 = (char *) malloc (pagesize);
- if (!data3)
- return 12;
- if (read (fd, data3, pagesize) != pagesize)
- return 13;
- for (i = 0; i < pagesize; ++i)
- if (*(data + i) != *(data3 + i))
- return 14;
- close (fd);
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_run "$LINENO"; then :
- ac_cv_func_mmap_fixed_mapped=yes
-else
- ac_cv_func_mmap_fixed_mapped=no
-fi
-rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
- conftest.$ac_objext conftest.beam conftest.$ac_ext
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mmap_fixed_mapped" >&5
-$as_echo "$ac_cv_func_mmap_fixed_mapped" >&6; }
-if test $ac_cv_func_mmap_fixed_mapped = yes; then
-
-$as_echo "#define HAVE_MMAP 1" >>confdefs.h
-
-fi
-rm -f conftest.mmap conftest.txt
-
- ASAN_OPTIONS="$save_ASAN_OPTIONS"
-
-for ac_func in fseeko fseeko64 getc_unlocked mkdtemp mkstemp utimensat utimes
-do :
- as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
-ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
-if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
- cat >>confdefs.h <<_ACEOF
-#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
-_ACEOF
-
-fi
-done
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for mbstate_t" >&5
-$as_echo_n "checking for mbstate_t... " >&6; }
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <wchar.h>
-int
-main ()
-{
-mbstate_t teststate;
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- have_mbstate_t=yes
-else
- have_mbstate_t=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_mbstate_t" >&5
-$as_echo "$have_mbstate_t" >&6; }
-if test x"$have_mbstate_t" = xyes; then
-
-$as_echo "#define HAVE_MBSTATE_T 1" >>confdefs.h
-
-fi
-
-# Copied from gnulib stat-time.m4.
-# We should just switch over to using gnulib.
-ac_fn_c_check_member "$LINENO" "struct stat" "st_atim.tv_nsec" "ac_cv_member_struct_stat_st_atim_tv_nsec" "#include <sys/types.h>
- #include <sys/stat.h>
-"
-if test "x$ac_cv_member_struct_stat_st_atim_tv_nsec" = xyes; then :
-
-cat >>confdefs.h <<_ACEOF
-#define HAVE_STRUCT_STAT_ST_ATIM_TV_NSEC 1
-_ACEOF
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct stat.st_atim is of type struct timespec" >&5
-$as_echo_n "checking whether struct stat.st_atim is of type struct timespec... " >&6; }
-if ${ac_cv_typeof_struct_stat_st_atim_is_struct_timespec+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
- #include <sys/types.h>
- #include <sys/stat.h>
- #if HAVE_SYS_TIME_H
- # include <sys/time.h>
- #endif
- #include <time.h>
- struct timespec ts;
- struct stat st;
-
-int
-main ()
-{
-
- st.st_atim = ts;
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_typeof_struct_stat_st_atim_is_struct_timespec=yes
-else
- ac_cv_typeof_struct_stat_st_atim_is_struct_timespec=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_typeof_struct_stat_st_atim_is_struct_timespec" >&5
-$as_echo "$ac_cv_typeof_struct_stat_st_atim_is_struct_timespec" >&6; }
- if test $ac_cv_typeof_struct_stat_st_atim_is_struct_timespec = yes; then
-
-$as_echo "#define TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC 1" >>confdefs.h
-
- fi
-else
- ac_fn_c_check_member "$LINENO" "struct stat" "st_atimespec.tv_nsec" "ac_cv_member_struct_stat_st_atimespec_tv_nsec" "#include <sys/types.h>
- #include <sys/stat.h>
-"
-if test "x$ac_cv_member_struct_stat_st_atimespec_tv_nsec" = xyes; then :
-
-cat >>confdefs.h <<_ACEOF
-#define HAVE_STRUCT_STAT_ST_ATIMESPEC_TV_NSEC 1
-_ACEOF
-
-
-else
- ac_fn_c_check_member "$LINENO" "struct stat" "st_atimensec" "ac_cv_member_struct_stat_st_atimensec" "#include <sys/types.h>
- #include <sys/stat.h>
-"
-if test "x$ac_cv_member_struct_stat_st_atimensec" = xyes; then :
-
-cat >>confdefs.h <<_ACEOF
-#define HAVE_STRUCT_STAT_ST_ATIMENSEC 1
-_ACEOF
-
-
-else
- ac_fn_c_check_member "$LINENO" "struct stat" "st_atim.st__tim.tv_nsec" "ac_cv_member_struct_stat_st_atim_st__tim_tv_nsec" "#include <sys/types.h>
- #include <sys/stat.h>
-"
-if test "x$ac_cv_member_struct_stat_st_atim_st__tim_tv_nsec" = xyes; then :
-
-cat >>confdefs.h <<_ACEOF
-#define HAVE_STRUCT_STAT_ST_ATIM_ST__TIM_TV_NSEC 1
-_ACEOF
-
-
-fi
-
-fi
-
-fi
-
-fi
-
-
-# Some systems have frexp only in -lm, not in -lc.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing frexp" >&5
-$as_echo_n "checking for library containing frexp... " >&6; }
-if ${ac_cv_search_frexp+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_func_search_save_LIBS=$LIBS
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char frexp ();
-int
-main ()
-{
-return frexp ();
- ;
- return 0;
-}
-_ACEOF
-for ac_lib in '' m; do
- if test -z "$ac_lib"; then
- ac_res="none required"
- else
- ac_res=-l$ac_lib
- LIBS="-l$ac_lib $ac_func_search_save_LIBS"
- fi
- if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_search_frexp=$ac_res
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext
- if ${ac_cv_search_frexp+:} false; then :
- break
-fi
-done
-if ${ac_cv_search_frexp+:} false; then :
-
-else
- ac_cv_search_frexp=no
-fi
-rm conftest.$ac_ext
-LIBS=$ac_func_search_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_frexp" >&5
-$as_echo "$ac_cv_search_frexp" >&6; }
-ac_res=$ac_cv_search_frexp
-if test "$ac_res" != no; then :
- test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
-
-fi
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LC_MESSAGES" >&5
-$as_echo_n "checking for LC_MESSAGES... " >&6; }
-if ${am_cv_val_LC_MESSAGES+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <locale.h>
-int
-main ()
-{
-return LC_MESSAGES
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- am_cv_val_LC_MESSAGES=yes
-else
- am_cv_val_LC_MESSAGES=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_val_LC_MESSAGES" >&5
-$as_echo "$am_cv_val_LC_MESSAGES" >&6; }
- if test $am_cv_val_LC_MESSAGES = yes; then
-
-$as_echo "#define HAVE_LC_MESSAGES 1" >>confdefs.h
-
- fi
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a known getopt prototype in unistd.h" >&5
-$as_echo_n "checking for a known getopt prototype in unistd.h... " >&6; }
-if ${bu_cv_decl_getopt_unistd_h+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <unistd.h>
-int
-main ()
-{
-extern int getopt (int, char *const*, const char *);
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- bu_cv_decl_getopt_unistd_h=yes
-else
- bu_cv_decl_getopt_unistd_h=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $bu_cv_decl_getopt_unistd_h" >&5
-$as_echo "$bu_cv_decl_getopt_unistd_h" >&6; }
-if test $bu_cv_decl_getopt_unistd_h = yes; then
-
-$as_echo "#define HAVE_DECL_GETOPT 1" >>confdefs.h
-
-fi
-
-# Under Next 3.2 <utime.h> apparently does not define struct utimbuf
-# by default.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for utime.h" >&5
-$as_echo_n "checking for utime.h... " >&6; }
-if ${bu_cv_header_utime_h+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <sys/types.h>
-#ifdef HAVE_TIME_H
-#include <time.h>
-#endif
-#include <utime.h>
-int
-main ()
-{
-struct utimbuf s;
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- bu_cv_header_utime_h=yes
-else
- bu_cv_header_utime_h=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $bu_cv_header_utime_h" >&5
-$as_echo "$bu_cv_header_utime_h" >&6; }
-if test $bu_cv_header_utime_h = yes; then
-
-$as_echo "#define HAVE_GOOD_UTIME_H 1" >>confdefs.h
-
-fi
-
-ac_fn_c_check_decl "$LINENO" "asprintf" "ac_cv_have_decl_asprintf" "$ac_includes_default"
-if test "x$ac_cv_have_decl_asprintf" = xyes; then :
- ac_have_decl=1
-else
- ac_have_decl=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define HAVE_DECL_ASPRINTF $ac_have_decl
-_ACEOF
-ac_fn_c_check_decl "$LINENO" "environ" "ac_cv_have_decl_environ" "$ac_includes_default"
-if test "x$ac_cv_have_decl_environ" = xyes; then :
- ac_have_decl=1
-else
- ac_have_decl=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define HAVE_DECL_ENVIRON $ac_have_decl
-_ACEOF
-ac_fn_c_check_decl "$LINENO" "getc_unlocked" "ac_cv_have_decl_getc_unlocked" "$ac_includes_default"
-if test "x$ac_cv_have_decl_getc_unlocked" = xyes; then :
- ac_have_decl=1
-else
- ac_have_decl=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define HAVE_DECL_GETC_UNLOCKED $ac_have_decl
-_ACEOF
-ac_fn_c_check_decl "$LINENO" "stpcpy" "ac_cv_have_decl_stpcpy" "$ac_includes_default"
-if test "x$ac_cv_have_decl_stpcpy" = xyes; then :
- ac_have_decl=1
-else
- ac_have_decl=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define HAVE_DECL_STPCPY $ac_have_decl
-_ACEOF
-ac_fn_c_check_decl "$LINENO" "strnlen" "ac_cv_have_decl_strnlen" "$ac_includes_default"
-if test "x$ac_cv_have_decl_strnlen" = xyes; then :
- ac_have_decl=1
-else
- ac_have_decl=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define HAVE_DECL_STRNLEN $ac_have_decl
-_ACEOF
-
-
-# Link in zlib/zstd if we can. This allows us to read compressed debug
-# sections. This is used only by readelf.c (objdump uses bfd for
-# reading compressed sections).
-
- # Use the system's zlib library.
- zlibdir="-L\$(top_builddir)/../zlib"
- zlibinc="-I\$(top_srcdir)/../zlib"
-
-# Check whether --with-system-zlib was given.
-if test "${with_system_zlib+set}" = set; then :
- withval=$with_system_zlib; if test x$with_system_zlib = xyes ; then
- zlibdir=
- zlibinc=
- fi
-
-fi
-
-
-
-
-
-
-# Check whether --with-zstd was given.
-if test "${with_zstd+set}" = set; then :
- withval=$with_zstd;
-else
- with_zstd=auto
-fi
-
-
-if test "$with_zstd" != no; then :
-
-pkg_failed=no
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for libzstd >= 1.4.0" >&5
-$as_echo_n "checking for libzstd >= 1.4.0... " >&6; }
-
-if test -n "$ZSTD_CFLAGS"; then
- pkg_cv_ZSTD_CFLAGS="$ZSTD_CFLAGS"
- elif test -n "$PKG_CONFIG"; then
- if test -n "$PKG_CONFIG" && \
- { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libzstd >= 1.4.0\""; } >&5
- ($PKG_CONFIG --exists --print-errors "libzstd >= 1.4.0") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- pkg_cv_ZSTD_CFLAGS=`$PKG_CONFIG --cflags "libzstd >= 1.4.0" 2>/dev/null`
- test "x$?" != "x0" && pkg_failed=yes
-else
- pkg_failed=yes
-fi
- else
- pkg_failed=untried
-fi
-if test -n "$ZSTD_LIBS"; then
- pkg_cv_ZSTD_LIBS="$ZSTD_LIBS"
- elif test -n "$PKG_CONFIG"; then
- if test -n "$PKG_CONFIG" && \
- { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libzstd >= 1.4.0\""; } >&5
- ($PKG_CONFIG --exists --print-errors "libzstd >= 1.4.0") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- pkg_cv_ZSTD_LIBS=`$PKG_CONFIG --libs "libzstd >= 1.4.0" 2>/dev/null`
- test "x$?" != "x0" && pkg_failed=yes
-else
- pkg_failed=yes
-fi
- else
- pkg_failed=untried
-fi
-
-if test $pkg_failed = no; then
- pkg_save_LDFLAGS="$LDFLAGS"
- LDFLAGS="$LDFLAGS $pkg_cv_ZSTD_LIBS"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
-
-else
- pkg_failed=yes
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LDFLAGS=$pkg_save_LDFLAGS
-fi
-
-
-
-if test $pkg_failed = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-
-if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
- _pkg_short_errors_supported=yes
-else
- _pkg_short_errors_supported=no
-fi
- if test $_pkg_short_errors_supported = yes; then
- ZSTD_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libzstd >= 1.4.0" 2>&1`
- else
- ZSTD_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libzstd >= 1.4.0" 2>&1`
- fi
- # Put the nasty error message in config.log where it belongs
- echo "$ZSTD_PKG_ERRORS" >&5
-
-
- if test "$with_zstd" = yes; then
- as_fn_error $? "--with-zstd was given, but pkgconfig/libzstd.pc is not found" "$LINENO" 5
- fi
-
-elif test $pkg_failed = untried; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-
- if test "$with_zstd" = yes; then
- as_fn_error $? "--with-zstd was given, but pkgconfig/libzstd.pc is not found" "$LINENO" 5
- fi
-
-else
- ZSTD_CFLAGS=$pkg_cv_ZSTD_CFLAGS
- ZSTD_LIBS=$pkg_cv_ZSTD_LIBS
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-
-
-$as_echo "#define HAVE_ZSTD 1" >>confdefs.h
-
-
-fi
-
-fi
-
-
-
-case "${host}" in
-*-*-msdos* | *-*-go32* | *-*-mingw32* | *-*-cygwin* | *-*-windows*)
-
-$as_echo "#define USE_BINARY_FOPEN 1" >>confdefs.h
- ;;
-esac
-
-# Support for the msgpack C library.
-
-# Check whether --with-msgpack was given.
-if test "${with_msgpack+set}" = set; then :
- withval=$with_msgpack;
-else
- with_msgpack=auto
-fi
-
-
-if test "$with_msgpack" != no; then :
-
-pkg_failed=no
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for msgpack" >&5
-$as_echo_n "checking for msgpack... " >&6; }
-
-if test -n "$MSGPACK_CFLAGS"; then
- pkg_cv_MSGPACK_CFLAGS="$MSGPACK_CFLAGS"
- elif test -n "$PKG_CONFIG"; then
- if test -n "$PKG_CONFIG" && \
- { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"msgpack\""; } >&5
- ($PKG_CONFIG --exists --print-errors "msgpack") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- pkg_cv_MSGPACK_CFLAGS=`$PKG_CONFIG --cflags "msgpack" 2>/dev/null`
- test "x$?" != "x0" && pkg_failed=yes
-else
- pkg_failed=yes
-fi
- else
- pkg_failed=untried
-fi
-if test -n "$MSGPACK_LIBS"; then
- pkg_cv_MSGPACK_LIBS="$MSGPACK_LIBS"
- elif test -n "$PKG_CONFIG"; then
- if test -n "$PKG_CONFIG" && \
- { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"msgpack\""; } >&5
- ($PKG_CONFIG --exists --print-errors "msgpack") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- pkg_cv_MSGPACK_LIBS=`$PKG_CONFIG --libs "msgpack" 2>/dev/null`
- test "x$?" != "x0" && pkg_failed=yes
-else
- pkg_failed=yes
-fi
- else
- pkg_failed=untried
-fi
-
-if test $pkg_failed = no; then
- pkg_save_LDFLAGS="$LDFLAGS"
- LDFLAGS="$LDFLAGS $pkg_cv_MSGPACK_LIBS"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
-
-else
- pkg_failed=yes
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LDFLAGS=$pkg_save_LDFLAGS
-fi
-
-
-
-if test $pkg_failed = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-
-if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
- _pkg_short_errors_supported=yes
-else
- _pkg_short_errors_supported=no
-fi
- if test $_pkg_short_errors_supported = yes; then
- MSGPACK_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "msgpack" 2>&1`
- else
- MSGPACK_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "msgpack" 2>&1`
- fi
- # Put the nasty error message in config.log where it belongs
- echo "$MSGPACK_PKG_ERRORS" >&5
-
- if test "$with_msgpack" = yes; then :
- as_fn_error $? "--with-msgpack was given, but msgpack is missing or unusable." "$LINENO" 5
-fi
-elif test $pkg_failed = untried; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- if test "$with_msgpack" = yes; then :
- as_fn_error $? "--with-msgpack was given, but msgpack is missing or unusable." "$LINENO" 5
-fi
-else
- MSGPACK_CFLAGS=$pkg_cv_MSGPACK_CFLAGS
- MSGPACK_LIBS=$pkg_cv_MSGPACK_LIBS
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-
-$as_echo "#define HAVE_MSGPACK 1" >>confdefs.h
-
-fi
-fi
-
-# target-specific stuff:
-
-# Canonicalize the secondary target names.
-if test -n "$enable_targets"; then
- for targ in `echo $enable_targets | sed 's/,/ /g'`
- do
- result=`$ac_config_sub $targ 2>/dev/null`
- if test -n "$result"; then
- canon_targets="$canon_targets $result"
- else
- # Allow targets that config.sub doesn't recognize, like "all".
- canon_targets="$canon_targets $targ"
- fi
- done
-fi
-
-ac_fn_c_check_header_mongrel "$LINENO" "iconv.h" "ac_cv_header_iconv_h" "$ac_includes_default"
-if test "x$ac_cv_header_iconv_h" = xyes; then :
-
-fi
-
-
-
-
-
-
-
- am_save_CPPFLAGS="$CPPFLAGS"
-
- for element in $INCICONV; do
- haveit=
- for x in $CPPFLAGS; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X$element"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
- fi
- done
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for iconv" >&5
-$as_echo_n "checking for iconv... " >&6; }
-if ${am_cv_func_iconv+:} false; then :
- $as_echo_n "(cached) " >&6
-else
-
- am_cv_func_iconv="no, consider installing GNU libiconv"
- am_cv_lib_iconv=no
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <stdlib.h>
-#include <iconv.h>
-
-int
-main ()
-{
-iconv_t cd = iconv_open("","");
- iconv(cd,NULL,NULL,NULL,NULL);
- iconv_close(cd);
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- am_cv_func_iconv=yes
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- if test "$am_cv_func_iconv" != yes; then
- am_save_LIBS="$LIBS"
- LIBS="$LIBS $LIBICONV"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <stdlib.h>
-#include <iconv.h>
-
-int
-main ()
-{
-iconv_t cd = iconv_open("","");
- iconv(cd,NULL,NULL,NULL,NULL);
- iconv_close(cd);
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- am_cv_lib_iconv=yes
- am_cv_func_iconv=yes
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LIBS="$am_save_LIBS"
- fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv" >&5
-$as_echo "$am_cv_func_iconv" >&6; }
- if test "$am_cv_func_iconv" = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working iconv" >&5
-$as_echo_n "checking for working iconv... " >&6; }
-if ${am_cv_func_iconv_works+:} false; then :
- $as_echo_n "(cached) " >&6
-else
-
- am_save_LIBS="$LIBS"
- if test $am_cv_lib_iconv = yes; then
- LIBS="$LIBS $LIBICONV"
- fi
- am_cv_func_iconv_works=no
- for ac_iconv_const in '' 'const'; do
- if test "$cross_compiling" = yes; then :
- case "$host_os" in
- aix* | hpux*) am_cv_func_iconv_works="guessing no" ;;
- *) am_cv_func_iconv_works="guessing yes" ;;
- esac
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <iconv.h>
-#include <string.h>
-
-#ifndef ICONV_CONST
-# define ICONV_CONST $ac_iconv_const
-#endif
-
-int
-main ()
-{
-int result = 0;
- /* Test against AIX 5.1...7.2 bug: Failures are not distinguishable from
- successful returns. This is even documented in
- <https://www.ibm.com/support/knowledgecenter/ssw_aix_72/i_bostechref/iconv.html> */
- {
- iconv_t cd_utf8_to_88591 = iconv_open ("ISO8859-1", "UTF-8");
- if (cd_utf8_to_88591 != (iconv_t)(-1))
- {
- static ICONV_CONST char input[] = "\342\202\254"; /* EURO SIGN */
- char buf[10];
- ICONV_CONST char *inptr = input;
- size_t inbytesleft = strlen (input);
- char *outptr = buf;
- size_t outbytesleft = sizeof (buf);
- size_t res = iconv (cd_utf8_to_88591,
- &inptr, &inbytesleft,
- &outptr, &outbytesleft);
- if (res == 0)
- result |= 1;
- iconv_close (cd_utf8_to_88591);
- }
- }
- /* Test against Solaris 10 bug: Failures are not distinguishable from
- successful returns. */
- {
- iconv_t cd_ascii_to_88591 = iconv_open ("ISO8859-1", "646");
- if (cd_ascii_to_88591 != (iconv_t)(-1))
- {
- static ICONV_CONST char input[] = "\263";
- char buf[10];
- ICONV_CONST char *inptr = input;
- size_t inbytesleft = strlen (input);
- char *outptr = buf;
- size_t outbytesleft = sizeof (buf);
- size_t res = iconv (cd_ascii_to_88591,
- &inptr, &inbytesleft,
- &outptr, &outbytesleft);
- if (res == 0)
- result |= 2;
- iconv_close (cd_ascii_to_88591);
- }
- }
- /* Test against AIX 6.1..7.1 bug: Buffer overrun. */
- {
- iconv_t cd_88591_to_utf8 = iconv_open ("UTF-8", "ISO-8859-1");
- if (cd_88591_to_utf8 != (iconv_t)(-1))
- {
- static ICONV_CONST char input[] = "\304";
- static char buf[2] = { (char)0xDE, (char)0xAD };
- ICONV_CONST char *inptr = input;
- size_t inbytesleft = 1;
- char *outptr = buf;
- size_t outbytesleft = 1;
- size_t res = iconv (cd_88591_to_utf8,
- &inptr, &inbytesleft,
- &outptr, &outbytesleft);
- if (res != (size_t)(-1) || outptr - buf > 1 || buf[1] != (char)0xAD)
- result |= 4;
- iconv_close (cd_88591_to_utf8);
- }
- }
-#if 0 /* This bug could be worked around by the caller. */
- /* Test against HP-UX 11.11 bug: Positive return value instead of 0. */
- {
- iconv_t cd_88591_to_utf8 = iconv_open ("utf8", "iso88591");
- if (cd_88591_to_utf8 != (iconv_t)(-1))
- {
- static ICONV_CONST char input[] = "\304rger mit b\366sen B\374bchen ohne Augenma\337";
- char buf[50];
- ICONV_CONST char *inptr = input;
- size_t inbytesleft = strlen (input);
- char *outptr = buf;
- size_t outbytesleft = sizeof (buf);
- size_t res = iconv (cd_88591_to_utf8,
- &inptr, &inbytesleft,
- &outptr, &outbytesleft);
- if ((int)res > 0)
- result |= 8;
- iconv_close (cd_88591_to_utf8);
- }
- }
-#endif
- /* Test against HP-UX 11.11 bug: No converter from EUC-JP to UTF-8 is
- provided. */
- {
- /* Try standardized names. */
- iconv_t cd1 = iconv_open ("UTF-8", "EUC-JP");
- /* Try IRIX, OSF/1 names. */
- iconv_t cd2 = iconv_open ("UTF-8", "eucJP");
- /* Try AIX names. */
- iconv_t cd3 = iconv_open ("UTF-8", "IBM-eucJP");
- /* Try HP-UX names. */
- iconv_t cd4 = iconv_open ("utf8", "eucJP");
- if (cd1 == (iconv_t)(-1) && cd2 == (iconv_t)(-1)
- && cd3 == (iconv_t)(-1) && cd4 == (iconv_t)(-1))
- result |= 16;
- if (cd1 != (iconv_t)(-1))
- iconv_close (cd1);
- if (cd2 != (iconv_t)(-1))
- iconv_close (cd2);
- if (cd3 != (iconv_t)(-1))
- iconv_close (cd3);
- if (cd4 != (iconv_t)(-1))
- iconv_close (cd4);
- }
- return result;
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_run "$LINENO"; then :
- am_cv_func_iconv_works=yes
-fi
-rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
- conftest.$ac_objext conftest.beam conftest.$ac_ext
-fi
-
- test "$am_cv_func_iconv_works" = no || break
- done
- LIBS="$am_save_LIBS"
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv_works" >&5
-$as_echo "$am_cv_func_iconv_works" >&6; }
- case "$am_cv_func_iconv_works" in
- *no) am_func_iconv=no am_cv_lib_iconv=no ;;
- *) am_func_iconv=yes ;;
- esac
- else
- am_func_iconv=no am_cv_lib_iconv=no
- fi
- if test "$am_func_iconv" = yes; then
-
-$as_echo "#define HAVE_ICONV 1" >>confdefs.h
-
- fi
- if test "$am_cv_lib_iconv" = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libiconv" >&5
-$as_echo_n "checking how to link with libiconv... " >&6; }
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBICONV" >&5
-$as_echo "$LIBICONV" >&6; }
- else
- CPPFLAGS="$am_save_CPPFLAGS"
- LIBICONV=
- LTLIBICONV=
- fi
-
-
-
- if test "$am_cv_func_iconv" = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether iconv is compatible with its POSIX signature" >&5
-$as_echo_n "checking whether iconv is compatible with its POSIX signature... " >&6; }
-if ${gl_cv_iconv_nonconst+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <stdlib.h>
-#include <iconv.h>
-extern
-#ifdef __cplusplus
-"C"
-#endif
-size_t iconv (iconv_t cd, char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft);
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- gl_cv_iconv_nonconst=yes
-else
- gl_cv_iconv_nonconst=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_iconv_nonconst" >&5
-$as_echo "$gl_cv_iconv_nonconst" >&6; }
- else
- gl_cv_iconv_nonconst=yes
- fi
- if test $gl_cv_iconv_nonconst = yes; then
- iconv_arg1=""
- else
- iconv_arg1="const"
- fi
-
-cat >>confdefs.h <<_ACEOF
-#define ICONV_CONST $iconv_arg1
-_ACEOF
-
-
-
- if test "$am_func_iconv" = yes; then
- if test -n "$LIBICONV"; then
- am_cv_func_iconv_summary='yes, in libiconv'
- else
- am_cv_func_iconv_summary='yes, in libc'
- fi
- else
- if test "$am_cv_func_iconv" = yes; then
- am_cv_func_iconv_summary='not working, consider installing GNU libiconv'
- else
- am_cv_func_iconv_summary='no, consider installing GNU libiconv'
- fi
- fi
-
-
-BUILD_SRCONV=
-BUILD_DLLTOOL=
-DLLTOOL_DEFS=
-DLLTOOL_DEFAULT=
-BUILD_WINDRES=
-BUILD_WINDMC=
-BUILD_DLLWRAP=
-BUILD_MISC=
-BUILD_INSTALL_MISC=
-OBJDUMP_DEFS=
-OBJDUMP_PRIVATE_VECTORS=
-OBJDUMP_PRIVATE_OFILES=
-od_vectors=
-
-for targ in $target $canon_targets
-do
- case $targ in
- all | *-*-hms*)
- BUILD_SRCONV='$(SRCONV_PROG)'
- ;;
- esac
-
- case $targ in
- all | spu-*-*)
- BUILD_MISC='bin2c$(EXEEXT_FOR_BUILD)'
- ;;
- esac
-
- case $targ in
- powerpc*-*-linux* | powerpc*-*-elf* | powerpc*-*-eabi*)
- BUILD_INSTALL_MISC=embedspu
- ;;
- esac
-
- case $targ in
- mep-*)
- OBJDUMP_DEFS="-DSKIP_ZEROES=256 -DSKIP_ZEROES_AT_END=0"
- ;;
- powerpc*-aix5.[01])
- ;;
- powerpc*-aix[5-9].*)
- OBJDUMP_DEFS="-DAIX_WEAK_SUPPORT"
- ;;
- esac
-
- case $targ in
- aarch64-*-mingw*)
- BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)'
- if test -z "$DLLTOOL_DEFAULT"; then
- DLLTOOL_DEFAULT="-DDLLTOOL_DEFAULT_AARCH64"
- fi
- DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_AARCH64"
- BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)'
- BUILD_WINDMC='$(WINDMC_PROG)$(EXEEXT)'
- BUILD_DLLWRAP='$(DLLWRAP_PROG)$(EXEEXT)'
- ;;
- arm-wince-pe* | arm-*-wince | arm*-*-cegcc* | arm*-*-mingw32ce*)
- BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)'
- if test -z "$DLLTOOL_DEFAULT"; then
- DLLTOOL_DEFAULT="-DDLLTOOL_DEFAULT_ARM_WINCE"
- fi
- DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_ARM_WINCE -DDLLTOOL_ARM"
- BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)'
- BUILD_WINDMC='$(WINDMC_PROG)$(EXEEXT)'
- ;;
- arm-*-pe*)
- BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)'
- if test -z "$DLLTOOL_DEFAULT"; then
- DLLTOOL_DEFAULT="-DDLLTOOL_DEFAULT_ARM"
- fi
- DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_ARM"
- BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)'
- BUILD_WINDMC='$(WINDMC_PROG)$(EXEEXT)'
- ;;
- i[3-7]86-*-pe* | i[3-7]86-*-cygwin* | i[3-7]86-*-mingw32** | all)
- BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)'
- if test -z "$DLLTOOL_DEFAULT"; then
- DLLTOOL_DEFAULT="-DDLLTOOL_DEFAULT_I386"
- fi
- DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_I386"
- BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)'
- BUILD_WINDMC='$(WINDMC_PROG)$(EXEEXT)'
- BUILD_DLLWRAP='$(DLLWRAP_PROG)$(EXEEXT)'
- ;;
- i[3-7]86-*-interix)
- BUILD_DLLTOOL='$(DLLTOOL_PROG)'
- if test -z "$DLLTOOL_DEFAULT"; then
- DLLTOOL_DEFAULT="-DDLLTOOL_DEFAULT_I386"
- fi
- DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_I386"
- ;;
- mcore-*-pe)
- BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)'
- if test -z "$DLLTOOL_DEFAULT"; then
- DLLTOOL_DEFAULT="-DDLLTOOL_DEFAULT_MCORE"
- fi
- DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_MCORE"
- BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)'
- BUILD_WINDMC='$(WINDMC_PROG)$(EXEEXT)'
- ;;
- mcore-*-elf)
- BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)'
- if test -z "$DLLTOOL_DEFAULT"; then
- DLLTOOL_DEFAULT="-DDLLTOOL_DEFAULT_MCORE_ELF"
- fi
- DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_MCORE_ELF"
- ;;
- sh*-*-pe)
- BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)'
- if test -z "$DLLTOOL_DEFAULT"; then
- DLLTOOL_DEFAULT="-DDLLTOOL_DEFAULT_SH"
- fi
- DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_SH"
- BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)'
- BUILD_WINDMC='$(WINDMC_PROG)$(EXEEXT)'
- ;;
- x86_64-*-mingw* | x86_64-*-cygwin*)
- BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)'
- if test -z "$DLLTOOL_DEFAULT"; then
- DLLTOOL_DEFAULT="-DDLLTOOL_DEFAULT_MX86_64"
- fi
- DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_MX86_64"
- BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)'
- BUILD_WINDMC='$(WINDMC_PROG)$(EXEEXT)'
- BUILD_DLLWRAP='$(DLLWRAP_PROG)$(EXEEXT)'
- ;;
- esac
-
- # Add objdump private vectors.
- case $targ in
- all)
- od_vectors="objdump_private_desc_elf32_avr objdump_private_desc_xcoff\
- objdump_private_desc_pe objdump_private_desc_mach_o"
- ;;
- avr-*-*)
- od_vectors="$od_vectors objdump_private_desc_elf32_avr"
- ;;
- powerpc*-*-aix* | rs6000-*-aix*)
- od_vectors="$od_vectors objdump_private_desc_xcoff"
- ;;
- *-*-pe* | *-*-cygwin* | *-*-mingw*)
- od_vectors="$od_vectors objdump_private_desc_pe"
- ;;
- *-*-darwin*)
- od_vectors="$od_vectors objdump_private_desc_mach_o"
- ;;
- esac
-done
-
-# Uniq objdump private vector, build objdump target ofiles.
-od_files=
-f=""
-for i in $od_vectors ; do
- case " $f " in
- *" $i "*) ;;
- *)
- f="$f $i"
- OBJDUMP_PRIVATE_VECTORS="$OBJDUMP_PRIVATE_VECTORS &$i,"
- case $i in
- objdump_private_desc_elf32_avr)
- od_files="$od_files od-elf32_avr" ;;
- objdump_private_desc_xcoff)
- od_files="$od_files od-xcoff" ;;
- objdump_private_desc_pe)
- od_files="$od_files od-pe" ;;
- objdump_private_desc_mach_o)
- od_files="$od_files od-macho" ;;
- *) as_fn_error $? "*** unknown private vector $i" "$LINENO" 5 ;;
- esac
- ;;
- esac
-done
-
-# Uniq objdump target ofiles
-f=""
-for i in $od_files ; do
- case " $f " in
- *" $i "*) ;;
- *)
- f="$f $i"
- OBJDUMP_PRIVATE_OFILES="$OBJDUMP_PRIVATE_OFILES $i.$objext"
- ;;
- esac
-done
-
-DLLTOOL_DEFS="$DLLTOOL_DEFS $DLLTOOL_DEFAULT"
-
-if test "${with_windres+set}" = set; then
- BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)'
-fi
-
-if test "${with_windmc+set}" = set; then
- BUILD_WINDMC='$(WINDMC_PROG)$(EXEEXT)'
-fi
-
-OBJDUMP_DEFS="${OBJDUMP_DEFS} -DOBJDUMP_PRIVATE_VECTORS=\"${OBJDUMP_PRIVATE_VECTORS}\""
-
-
-
-
-
-
-
-
-
-
-
-
-
-cat >>confdefs.h <<_ACEOF
-#define TARGET "${target}"
-_ACEOF
-
-
-targ=$target
-. $srcdir/../bfd/config.bfd
-if test "x$targ_underscore" = "xyes"; then
- UNDERSCORE=1
-else
- UNDERSCORE=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define TARGET_PREPENDS_UNDERSCORE $UNDERSCORE
-_ACEOF
-
-
-# Emulation
-targ=$target
-. ${srcdir}/configure.tgt
-EMULATION=$targ_emul
-EMULATION_VECTOR=$targ_emul_vector
-
-
-
-
-# Required for html and install-html
-
-
-
-
-
-ac_config_files="$ac_config_files Makefile po/Makefile.in:po/Make-in"
-
-cat >confcache <<\_ACEOF
-# This file is a shell script that caches the results of configure
-# tests run on this system so they can be shared between configure
-# scripts and configure runs, see configure's option --config-cache.
-# It is not useful on other systems. If it contains results you don't
-# want to keep, you may remove or edit it.
-#
-# config.status only pays attention to the cache file if you give it
-# the --recheck option to rerun configure.
-#
-# `ac_cv_env_foo' variables (set or unset) will be overridden when
-# loading this file, other *unset* `ac_cv_foo' will be assigned the
-# following values.
-
-_ACEOF
-
-# The following way of writing the cache mishandles newlines in values,
-# but we know of no workaround that is simple, portable, and efficient.
-# So, we kill variables containing newlines.
-# Ultrix sh set writes to stderr and can't be redirected directly,
-# and sets the high bit in the cache file unless we assign to the vars.
-(
- for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
- eval ac_val=\$$ac_var
- case $ac_val in #(
- *${as_nl}*)
- case $ac_var in #(
- *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
-$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
- esac
- case $ac_var in #(
- _ | IFS | as_nl) ;; #(
- BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
- *) { eval $ac_var=; unset $ac_var;} ;;
- esac ;;
- esac
- done
-
- (set) 2>&1 |
- case $as_nl`(ac_space=' '; set) 2>&1` in #(
- *${as_nl}ac_space=\ *)
- # `set' does not quote correctly, so add quotes: double-quote
- # substitution turns \\\\ into \\, and sed turns \\ into \.
- sed -n \
- "s/'/'\\\\''/g;
- s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
- ;; #(
- *)
- # `set' quotes correctly as required by POSIX, so do not add quotes.
- sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
- ;;
- esac |
- sort
-) |
- sed '
- /^ac_cv_env_/b end
- t clear
- :clear
- s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
- t end
- s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
- :end' >>confcache
-if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
- if test -w "$cache_file"; then
- if test "x$cache_file" != "x/dev/null"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
-$as_echo "$as_me: updating cache $cache_file" >&6;}
- if test ! -f "$cache_file" || test -h "$cache_file"; then
- cat confcache >"$cache_file"
- else
- case $cache_file in #(
- */* | ?:*)
- mv -f confcache "$cache_file"$$ &&
- mv -f "$cache_file"$$ "$cache_file" ;; #(
- *)
- mv -f confcache "$cache_file" ;;
- esac
- fi
- fi
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
-$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
- fi
-fi
-rm -f confcache
-
-test "x$prefix" = xNONE && prefix=$ac_default_prefix
-# Let make expand exec_prefix.
-test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
-
-DEFS=-DHAVE_CONFIG_H
-
-ac_libobjs=
-ac_ltlibobjs=
-U=
-for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
- # 1. Remove the extension, and $U if already installed.
- ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
- ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
- # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
- # will be set to the directory where LIBOBJS objects are built.
- as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
- as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
-done
-LIBOBJS=$ac_libobjs
-
-LTLIBOBJS=$ac_ltlibobjs
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking that generated files are newer than configure" >&5
-$as_echo_n "checking that generated files are newer than configure... " >&6; }
- if test -n "$am_sleep_pid"; then
- # Hide warnings about reused PIDs.
- wait $am_sleep_pid 2>/dev/null
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: done" >&5
-$as_echo "done" >&6; }
- if test -n "$EXEEXT"; then
- am__EXEEXT_TRUE=
- am__EXEEXT_FALSE='#'
-else
- am__EXEEXT_TRUE='#'
- am__EXEEXT_FALSE=
-fi
-
-if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
- as_fn_error $? "conditional \"AMDEP\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
- as_fn_error $? "conditional \"am__fastdepCC\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-
-if test -z "${ENABLE_LIBCTF_TRUE}" && test -z "${ENABLE_LIBCTF_FALSE}"; then
- as_fn_error $? "conditional \"ENABLE_LIBCTF\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${MAINTAINER_MODE_TRUE}" && test -z "${MAINTAINER_MODE_FALSE}"; then
- as_fn_error $? "conditional \"MAINTAINER_MODE\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${GENINSRC_NEVER_TRUE}" && test -z "${GENINSRC_NEVER_FALSE}"; then
- as_fn_error $? "conditional \"GENINSRC_NEVER\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-
-: "${CONFIG_STATUS=./config.status}"
-ac_write_fail=0
-ac_clean_files_save=$ac_clean_files
-ac_clean_files="$ac_clean_files $CONFIG_STATUS"
-{ $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
-$as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
-as_write_fail=0
-cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
-#! $SHELL
-# Generated by $as_me.
-# Run this file to recreate the current configuration.
-# Compiler output produced by configure, useful for debugging
-# configure, is in config.log if it exists.
-
-debug=false
-ac_cs_recheck=false
-ac_cs_silent=false
-
-SHELL=\${CONFIG_SHELL-$SHELL}
-export SHELL
-_ASEOF
-cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
-## -------------------- ##
-## M4sh Initialization. ##
-## -------------------- ##
-
-# Be more Bourne compatible
-DUALCASE=1; export DUALCASE # for MKS sh
-if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
- emulate sh
- NULLCMD=:
- # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
- # is contrary to our usage. Disable this feature.
- alias -g '${1+"$@"}'='"$@"'
- setopt NO_GLOB_SUBST
-else
- case `(set -o) 2>/dev/null` in #(
- *posix*) :
- set -o posix ;; #(
- *) :
- ;;
-esac
-fi
-
-
-as_nl='
-'
-export as_nl
-# Printing a long string crashes Solaris 7 /usr/bin/printf.
-as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
-as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
-as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
-# Prefer a ksh shell builtin over an external printf program on Solaris,
-# but without wasting forks for bash or zsh.
-if test -z "$BASH_VERSION$ZSH_VERSION" \
- && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
- as_echo='print -r --'
- as_echo_n='print -rn --'
-elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
- as_echo='printf %s\n'
- as_echo_n='printf %s'
-else
- if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
- as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
- as_echo_n='/usr/ucb/echo -n'
- else
- as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
- as_echo_n_body='eval
- arg=$1;
- case $arg in #(
- *"$as_nl"*)
- expr "X$arg" : "X\\(.*\\)$as_nl";
- arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
- esac;
- expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
- '
- export as_echo_n_body
- as_echo_n='sh -c $as_echo_n_body as_echo'
- fi
- export as_echo_body
- as_echo='sh -c $as_echo_body as_echo'
-fi
-
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- PATH_SEPARATOR=:
- (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
- (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
- PATH_SEPARATOR=';'
- }
-fi
-
-
-# IFS
-# We need space, tab and new line, in precisely that order. Quoting is
-# there to prevent editors from complaining about space-tab.
-# (If _AS_PATH_WALK were called with IFS unset, it would disable word
-# splitting by setting IFS to empty value.)
-IFS=" "" $as_nl"
-
-# Find who we are. Look in the path if we contain no directory separator.
-as_myself=
-case $0 in #((
- *[\\/]* ) as_myself=$0 ;;
- *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
- done
-IFS=$as_save_IFS
-
- ;;
-esac
-# We did not find ourselves, most probably we were run as `sh COMMAND'
-# in which case we are not to be found in the path.
-if test "x$as_myself" = x; then
- as_myself=$0
-fi
-if test ! -f "$as_myself"; then
- $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
- exit 1
-fi
-
-# Unset variables that we do not need and which cause bugs (e.g. in
-# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
-# suppresses any "Segmentation fault" message there. '((' could
-# trigger a bug in pdksh 5.2.14.
-for as_var in BASH_ENV ENV MAIL MAILPATH
-do eval test x\${$as_var+set} = xset \
- && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
-done
-PS1='$ '
-PS2='> '
-PS4='+ '
-
-# NLS nuisances.
-LC_ALL=C
-export LC_ALL
-LANGUAGE=C
-export LANGUAGE
-
-# CDPATH.
-(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
-
-
-# as_fn_error STATUS ERROR [LINENO LOG_FD]
-# ----------------------------------------
-# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
-# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
-# script with STATUS, using 1 if that was 0.
-as_fn_error ()
-{
- as_status=$1; test $as_status -eq 0 && as_status=1
- if test "$4"; then
- as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
- fi
- $as_echo "$as_me: error: $2" >&2
- as_fn_exit $as_status
-} # as_fn_error
-
-
-# as_fn_set_status STATUS
-# -----------------------
-# Set $? to STATUS, without forking.
-as_fn_set_status ()
-{
- return $1
-} # as_fn_set_status
-
-# as_fn_exit STATUS
-# -----------------
-# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
-as_fn_exit ()
-{
- set +e
- as_fn_set_status $1
- exit $1
-} # as_fn_exit
-
-# as_fn_unset VAR
-# ---------------
-# Portably unset VAR.
-as_fn_unset ()
-{
- { eval $1=; unset $1;}
-}
-as_unset=as_fn_unset
-# as_fn_append VAR VALUE
-# ----------------------
-# Append the text in VALUE to the end of the definition contained in VAR. Take
-# advantage of any shell optimizations that allow amortized linear growth over
-# repeated appends, instead of the typical quadratic growth present in naive
-# implementations.
-if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
- eval 'as_fn_append ()
- {
- eval $1+=\$2
- }'
-else
- as_fn_append ()
- {
- eval $1=\$$1\$2
- }
-fi # as_fn_append
-
-# as_fn_arith ARG...
-# ------------------
-# Perform arithmetic evaluation on the ARGs, and store the result in the
-# global $as_val. Take advantage of shells that can avoid forks. The arguments
-# must be portable across $(()) and expr.
-if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
- eval 'as_fn_arith ()
- {
- as_val=$(( $* ))
- }'
-else
- as_fn_arith ()
- {
- as_val=`expr "$@" || test $? -eq 1`
- }
-fi # as_fn_arith
-
-
-if expr a : '\(a\)' >/dev/null 2>&1 &&
- test "X`expr 00001 : '.*\(...\)'`" = X001; then
- as_expr=expr
-else
- as_expr=false
-fi
-
-if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
- as_basename=basename
-else
- as_basename=false
-fi
-
-if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
- as_dirname=dirname
-else
- as_dirname=false
-fi
-
-as_me=`$as_basename -- "$0" ||
-$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
- X"$0" : 'X\(//\)$' \| \
- X"$0" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X/"$0" |
- sed '/^.*\/\([^/][^/]*\)\/*$/{
- s//\1/
- q
- }
- /^X\/\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\/\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
-
-# Avoid depending upon Character Ranges.
-as_cr_letters='abcdefghijklmnopqrstuvwxyz'
-as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
-as_cr_Letters=$as_cr_letters$as_cr_LETTERS
-as_cr_digits='0123456789'
-as_cr_alnum=$as_cr_Letters$as_cr_digits
-
-ECHO_C= ECHO_N= ECHO_T=
-case `echo -n x` in #(((((
--n*)
- case `echo 'xy\c'` in
- *c*) ECHO_T=' ';; # ECHO_T is single tab character.
- xy) ECHO_C='\c';;
- *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
- ECHO_T=' ';;
- esac;;
-*)
- ECHO_N='-n';;
-esac
-
-rm -f conf$$ conf$$.exe conf$$.file
-if test -d conf$$.dir; then
- rm -f conf$$.dir/conf$$.file
-else
- rm -f conf$$.dir
- mkdir conf$$.dir 2>/dev/null
-fi
-if (echo >conf$$.file) 2>/dev/null; then
- if ln -s conf$$.file conf$$ 2>/dev/null; then
- as_ln_s='ln -s'
- # ... but there are two gotchas:
- # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
- # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
- # In both cases, we have to default to `cp -pR'.
- ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
- as_ln_s='cp -pR'
- elif ln conf$$.file conf$$ 2>/dev/null; then
- as_ln_s=ln
- else
- as_ln_s='cp -pR'
- fi
-else
- as_ln_s='cp -pR'
-fi
-rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
-rmdir conf$$.dir 2>/dev/null
-
-
-# as_fn_mkdir_p
-# -------------
-# Create "$as_dir" as a directory, including parents if necessary.
-as_fn_mkdir_p ()
-{
-
- case $as_dir in #(
- -*) as_dir=./$as_dir;;
- esac
- test -d "$as_dir" || eval $as_mkdir_p || {
- as_dirs=
- while :; do
- case $as_dir in #(
- *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
- *) as_qdir=$as_dir;;
- esac
- as_dirs="'$as_qdir' $as_dirs"
- as_dir=`$as_dirname -- "$as_dir" ||
-$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$as_dir" : 'X\(//\)[^/]' \| \
- X"$as_dir" : 'X\(//\)$' \| \
- X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$as_dir" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
- test -d "$as_dir" && break
- done
- test -z "$as_dirs" || eval "mkdir $as_dirs"
- } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
-
-
-} # as_fn_mkdir_p
-if mkdir -p . 2>/dev/null; then
- as_mkdir_p='mkdir -p "$as_dir"'
-else
- test -d ./-p && rmdir ./-p
- as_mkdir_p=false
-fi
-
-
-# as_fn_executable_p FILE
-# -----------------------
-# Test if FILE is an executable regular file.
-as_fn_executable_p ()
-{
- test -f "$1" && test -x "$1"
-} # as_fn_executable_p
-as_test_x='test -x'
-as_executable_p=as_fn_executable_p
-
-# Sed expression to map a string onto a valid CPP name.
-as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
-
-# Sed expression to map a string onto a valid variable name.
-as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
-
-
-exec 6>&1
-## ----------------------------------- ##
-## Main body of $CONFIG_STATUS script. ##
-## ----------------------------------- ##
-_ASEOF
-test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
-
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-# Save the log message, to keep $0 and so on meaningful, and to
-# report actual input values of CONFIG_FILES etc. instead of their
-# values after options handling.
-ac_log="
-This file was extended by binutils $as_me 2.43.1, which was
-generated by GNU Autoconf 2.69. Invocation command line was
-
- CONFIG_FILES = $CONFIG_FILES
- CONFIG_HEADERS = $CONFIG_HEADERS
- CONFIG_LINKS = $CONFIG_LINKS
- CONFIG_COMMANDS = $CONFIG_COMMANDS
- $ $0 $@
-
-on `(hostname || uname -n) 2>/dev/null | sed 1q`
-"
-
-_ACEOF
-
-case $ac_config_files in *"
-"*) set x $ac_config_files; shift; ac_config_files=$*;;
-esac
-
-case $ac_config_headers in *"
-"*) set x $ac_config_headers; shift; ac_config_headers=$*;;
-esac
-
-
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-# Files that config.status was made for.
-config_files="$ac_config_files"
-config_headers="$ac_config_headers"
-config_commands="$ac_config_commands"
-
-_ACEOF
-
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-ac_cs_usage="\
-\`$as_me' instantiates files and other configuration actions
-from templates according to the current configuration. Unless the files
-and actions are specified as TAGs, all are instantiated by default.
-
-Usage: $0 [OPTION]... [TAG]...
-
- -h, --help print this help, then exit
- -V, --version print version number and configuration settings, then exit
- --config print configuration, then exit
- -q, --quiet, --silent
- do not print progress messages
- -d, --debug don't remove temporary files
- --recheck update $as_me by reconfiguring in the same conditions
- --file=FILE[:TEMPLATE]
- instantiate the configuration file FILE
- --header=FILE[:TEMPLATE]
- instantiate the configuration header FILE
-
-Configuration files:
-$config_files
-
-Configuration headers:
-$config_headers
-
-Configuration commands:
-$config_commands
-
-Report bugs to the package provider."
-
-_ACEOF
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
-ac_cs_version="\\
-binutils config.status 2.43.1
-configured by $0, generated by GNU Autoconf 2.69,
- with options \\"\$ac_cs_config\\"
-
-Copyright (C) 2012 Free Software Foundation, Inc.
-This config.status script is free software; the Free Software Foundation
-gives unlimited permission to copy, distribute and modify it."
-
-ac_pwd='$ac_pwd'
-srcdir='$srcdir'
-INSTALL='$INSTALL'
-MKDIR_P='$MKDIR_P'
-AWK='$AWK'
-test -n "\$AWK" || AWK=awk
-_ACEOF
-
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-# The default lists apply if the user does not specify any file.
-ac_need_defaults=:
-while test $# != 0
-do
- case $1 in
- --*=?*)
- ac_option=`expr "X$1" : 'X\([^=]*\)='`
- ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
- ac_shift=:
- ;;
- --*=)
- ac_option=`expr "X$1" : 'X\([^=]*\)='`
- ac_optarg=
- ac_shift=:
- ;;
- *)
- ac_option=$1
- ac_optarg=$2
- ac_shift=shift
- ;;
- esac
-
- case $ac_option in
- # Handling of the options.
- -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
- ac_cs_recheck=: ;;
- --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
- $as_echo "$ac_cs_version"; exit ;;
- --config | --confi | --conf | --con | --co | --c )
- $as_echo "$ac_cs_config"; exit ;;
- --debug | --debu | --deb | --de | --d | -d )
- debug=: ;;
- --file | --fil | --fi | --f )
- $ac_shift
- case $ac_optarg in
- *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
- '') as_fn_error $? "missing file argument" ;;
- esac
- as_fn_append CONFIG_FILES " '$ac_optarg'"
- ac_need_defaults=false;;
- --header | --heade | --head | --hea )
- $ac_shift
- case $ac_optarg in
- *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
- esac
- as_fn_append CONFIG_HEADERS " '$ac_optarg'"
- ac_need_defaults=false;;
- --he | --h)
- # Conflict between --help and --header
- as_fn_error $? "ambiguous option: \`$1'
-Try \`$0 --help' for more information.";;
- --help | --hel | -h )
- $as_echo "$ac_cs_usage"; exit ;;
- -q | -quiet | --quiet | --quie | --qui | --qu | --q \
- | -silent | --silent | --silen | --sile | --sil | --si | --s)
- ac_cs_silent=: ;;
-
- # This is an error.
- -*) as_fn_error $? "unrecognized option: \`$1'
-Try \`$0 --help' for more information." ;;
-
- *) as_fn_append ac_config_targets " $1"
- ac_need_defaults=false ;;
-
- esac
- shift
-done
-
-ac_configure_extra_args=
-
-if $ac_cs_silent; then
- exec 6>/dev/null
- ac_configure_extra_args="$ac_configure_extra_args --silent"
-fi
-
-_ACEOF
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-if \$ac_cs_recheck; then
- set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
- shift
- \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
- CONFIG_SHELL='$SHELL'
- export CONFIG_SHELL
- exec "\$@"
-fi
-
-_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-exec 5>>config.log
-{
- echo
- sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
-## Running $as_me. ##
-_ASBOX
- $as_echo "$ac_log"
-} >&5
-
-_ACEOF
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-#
-# INIT-COMMANDS
-#
-AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"
-
-
-# The HP-UX ksh and POSIX shell print the target directory to stdout
-# if CDPATH is set.
-(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
-
-sed_quote_subst='$sed_quote_subst'
-double_quote_subst='$double_quote_subst'
-delay_variable_subst='$delay_variable_subst'
-macro_version='`$ECHO "$macro_version" | $SED "$delay_single_quote_subst"`'
-macro_revision='`$ECHO "$macro_revision" | $SED "$delay_single_quote_subst"`'
-enable_shared='`$ECHO "$enable_shared" | $SED "$delay_single_quote_subst"`'
-enable_static='`$ECHO "$enable_static" | $SED "$delay_single_quote_subst"`'
-pic_mode='`$ECHO "$pic_mode" | $SED "$delay_single_quote_subst"`'
-enable_fast_install='`$ECHO "$enable_fast_install" | $SED "$delay_single_quote_subst"`'
-SHELL='`$ECHO "$SHELL" | $SED "$delay_single_quote_subst"`'
-ECHO='`$ECHO "$ECHO" | $SED "$delay_single_quote_subst"`'
-host_alias='`$ECHO "$host_alias" | $SED "$delay_single_quote_subst"`'
-host='`$ECHO "$host" | $SED "$delay_single_quote_subst"`'
-host_os='`$ECHO "$host_os" | $SED "$delay_single_quote_subst"`'
-build_alias='`$ECHO "$build_alias" | $SED "$delay_single_quote_subst"`'
-build='`$ECHO "$build" | $SED "$delay_single_quote_subst"`'
-build_os='`$ECHO "$build_os" | $SED "$delay_single_quote_subst"`'
-SED='`$ECHO "$SED" | $SED "$delay_single_quote_subst"`'
-Xsed='`$ECHO "$Xsed" | $SED "$delay_single_quote_subst"`'
-GREP='`$ECHO "$GREP" | $SED "$delay_single_quote_subst"`'
-EGREP='`$ECHO "$EGREP" | $SED "$delay_single_quote_subst"`'
-FGREP='`$ECHO "$FGREP" | $SED "$delay_single_quote_subst"`'
-LD='`$ECHO "$LD" | $SED "$delay_single_quote_subst"`'
-NM='`$ECHO "$NM" | $SED "$delay_single_quote_subst"`'
-LN_S='`$ECHO "$LN_S" | $SED "$delay_single_quote_subst"`'
-max_cmd_len='`$ECHO "$max_cmd_len" | $SED "$delay_single_quote_subst"`'
-ac_objext='`$ECHO "$ac_objext" | $SED "$delay_single_quote_subst"`'
-exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`'
-lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`'
-lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`'
-lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`'
-reload_flag='`$ECHO "$reload_flag" | $SED "$delay_single_quote_subst"`'
-reload_cmds='`$ECHO "$reload_cmds" | $SED "$delay_single_quote_subst"`'
-OBJDUMP='`$ECHO "$OBJDUMP" | $SED "$delay_single_quote_subst"`'
-deplibs_check_method='`$ECHO "$deplibs_check_method" | $SED "$delay_single_quote_subst"`'
-file_magic_cmd='`$ECHO "$file_magic_cmd" | $SED "$delay_single_quote_subst"`'
-AR='`$ECHO "$AR" | $SED "$delay_single_quote_subst"`'
-AR_FLAGS='`$ECHO "$AR_FLAGS" | $SED "$delay_single_quote_subst"`'
-STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`'
-RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`'
-old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`'
-old_postuninstall_cmds='`$ECHO "$old_postuninstall_cmds" | $SED "$delay_single_quote_subst"`'
-old_archive_cmds='`$ECHO "$old_archive_cmds" | $SED "$delay_single_quote_subst"`'
-lock_old_archive_extraction='`$ECHO "$lock_old_archive_extraction" | $SED "$delay_single_quote_subst"`'
-CC='`$ECHO "$CC" | $SED "$delay_single_quote_subst"`'
-CFLAGS='`$ECHO "$CFLAGS" | $SED "$delay_single_quote_subst"`'
-compiler='`$ECHO "$compiler" | $SED "$delay_single_quote_subst"`'
-GCC='`$ECHO "$GCC" | $SED "$delay_single_quote_subst"`'
-lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$delay_single_quote_subst"`'
-lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`'
-lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`'
-lt_cv_sys_global_symbol_to_c_name_address_lib_prefix='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address_lib_prefix" | $SED "$delay_single_quote_subst"`'
-objdir='`$ECHO "$objdir" | $SED "$delay_single_quote_subst"`'
-MAGIC_CMD='`$ECHO "$MAGIC_CMD" | $SED "$delay_single_quote_subst"`'
-lt_prog_compiler_no_builtin_flag='`$ECHO "$lt_prog_compiler_no_builtin_flag" | $SED "$delay_single_quote_subst"`'
-lt_prog_compiler_wl='`$ECHO "$lt_prog_compiler_wl" | $SED "$delay_single_quote_subst"`'
-lt_prog_compiler_pic='`$ECHO "$lt_prog_compiler_pic" | $SED "$delay_single_quote_subst"`'
-lt_prog_compiler_static='`$ECHO "$lt_prog_compiler_static" | $SED "$delay_single_quote_subst"`'
-lt_cv_prog_compiler_c_o='`$ECHO "$lt_cv_prog_compiler_c_o" | $SED "$delay_single_quote_subst"`'
-need_locks='`$ECHO "$need_locks" | $SED "$delay_single_quote_subst"`'
-DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`'
-NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`'
-LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`'
-OTOOL='`$ECHO "$OTOOL" | $SED "$delay_single_quote_subst"`'
-OTOOL64='`$ECHO "$OTOOL64" | $SED "$delay_single_quote_subst"`'
-libext='`$ECHO "$libext" | $SED "$delay_single_quote_subst"`'
-shrext_cmds='`$ECHO "$shrext_cmds" | $SED "$delay_single_quote_subst"`'
-extract_expsyms_cmds='`$ECHO "$extract_expsyms_cmds" | $SED "$delay_single_quote_subst"`'
-archive_cmds_need_lc='`$ECHO "$archive_cmds_need_lc" | $SED "$delay_single_quote_subst"`'
-enable_shared_with_static_runtimes='`$ECHO "$enable_shared_with_static_runtimes" | $SED "$delay_single_quote_subst"`'
-export_dynamic_flag_spec='`$ECHO "$export_dynamic_flag_spec" | $SED "$delay_single_quote_subst"`'
-whole_archive_flag_spec='`$ECHO "$whole_archive_flag_spec" | $SED "$delay_single_quote_subst"`'
-compiler_needs_object='`$ECHO "$compiler_needs_object" | $SED "$delay_single_quote_subst"`'
-old_archive_from_new_cmds='`$ECHO "$old_archive_from_new_cmds" | $SED "$delay_single_quote_subst"`'
-old_archive_from_expsyms_cmds='`$ECHO "$old_archive_from_expsyms_cmds" | $SED "$delay_single_quote_subst"`'
-archive_cmds='`$ECHO "$archive_cmds" | $SED "$delay_single_quote_subst"`'
-archive_expsym_cmds='`$ECHO "$archive_expsym_cmds" | $SED "$delay_single_quote_subst"`'
-module_cmds='`$ECHO "$module_cmds" | $SED "$delay_single_quote_subst"`'
-module_expsym_cmds='`$ECHO "$module_expsym_cmds" | $SED "$delay_single_quote_subst"`'
-with_gnu_ld='`$ECHO "$with_gnu_ld" | $SED "$delay_single_quote_subst"`'
-allow_undefined_flag='`$ECHO "$allow_undefined_flag" | $SED "$delay_single_quote_subst"`'
-no_undefined_flag='`$ECHO "$no_undefined_flag" | $SED "$delay_single_quote_subst"`'
-hardcode_libdir_flag_spec='`$ECHO "$hardcode_libdir_flag_spec" | $SED "$delay_single_quote_subst"`'
-hardcode_libdir_flag_spec_ld='`$ECHO "$hardcode_libdir_flag_spec_ld" | $SED "$delay_single_quote_subst"`'
-hardcode_libdir_separator='`$ECHO "$hardcode_libdir_separator" | $SED "$delay_single_quote_subst"`'
-hardcode_direct='`$ECHO "$hardcode_direct" | $SED "$delay_single_quote_subst"`'
-hardcode_direct_absolute='`$ECHO "$hardcode_direct_absolute" | $SED "$delay_single_quote_subst"`'
-hardcode_minus_L='`$ECHO "$hardcode_minus_L" | $SED "$delay_single_quote_subst"`'
-hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_quote_subst"`'
-hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`'
-inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`'
-link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`'
-fix_srcfile_path='`$ECHO "$fix_srcfile_path" | $SED "$delay_single_quote_subst"`'
-always_export_symbols='`$ECHO "$always_export_symbols" | $SED "$delay_single_quote_subst"`'
-export_symbols_cmds='`$ECHO "$export_symbols_cmds" | $SED "$delay_single_quote_subst"`'
-exclude_expsyms='`$ECHO "$exclude_expsyms" | $SED "$delay_single_quote_subst"`'
-include_expsyms='`$ECHO "$include_expsyms" | $SED "$delay_single_quote_subst"`'
-prelink_cmds='`$ECHO "$prelink_cmds" | $SED "$delay_single_quote_subst"`'
-file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`'
-variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`'
-need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`'
-need_version='`$ECHO "$need_version" | $SED "$delay_single_quote_subst"`'
-version_type='`$ECHO "$version_type" | $SED "$delay_single_quote_subst"`'
-runpath_var='`$ECHO "$runpath_var" | $SED "$delay_single_quote_subst"`'
-shlibpath_var='`$ECHO "$shlibpath_var" | $SED "$delay_single_quote_subst"`'
-shlibpath_overrides_runpath='`$ECHO "$shlibpath_overrides_runpath" | $SED "$delay_single_quote_subst"`'
-libname_spec='`$ECHO "$libname_spec" | $SED "$delay_single_quote_subst"`'
-library_names_spec='`$ECHO "$library_names_spec" | $SED "$delay_single_quote_subst"`'
-soname_spec='`$ECHO "$soname_spec" | $SED "$delay_single_quote_subst"`'
-install_override_mode='`$ECHO "$install_override_mode" | $SED "$delay_single_quote_subst"`'
-postinstall_cmds='`$ECHO "$postinstall_cmds" | $SED "$delay_single_quote_subst"`'
-postuninstall_cmds='`$ECHO "$postuninstall_cmds" | $SED "$delay_single_quote_subst"`'
-finish_cmds='`$ECHO "$finish_cmds" | $SED "$delay_single_quote_subst"`'
-finish_eval='`$ECHO "$finish_eval" | $SED "$delay_single_quote_subst"`'
-hardcode_into_libs='`$ECHO "$hardcode_into_libs" | $SED "$delay_single_quote_subst"`'
-sys_lib_search_path_spec='`$ECHO "$sys_lib_search_path_spec" | $SED "$delay_single_quote_subst"`'
-sys_lib_dlsearch_path_spec='`$ECHO "$sys_lib_dlsearch_path_spec" | $SED "$delay_single_quote_subst"`'
-hardcode_action='`$ECHO "$hardcode_action" | $SED "$delay_single_quote_subst"`'
-enable_dlopen='`$ECHO "$enable_dlopen" | $SED "$delay_single_quote_subst"`'
-enable_dlopen_self='`$ECHO "$enable_dlopen_self" | $SED "$delay_single_quote_subst"`'
-enable_dlopen_self_static='`$ECHO "$enable_dlopen_self_static" | $SED "$delay_single_quote_subst"`'
-old_striplib='`$ECHO "$old_striplib" | $SED "$delay_single_quote_subst"`'
-striplib='`$ECHO "$striplib" | $SED "$delay_single_quote_subst"`'
-
-LTCC='$LTCC'
-LTCFLAGS='$LTCFLAGS'
-compiler='$compiler_DEFAULT'
-
-# A function that is used when there is no print builtin or printf.
-func_fallback_echo ()
-{
- eval 'cat <<_LTECHO_EOF
-\$1
-_LTECHO_EOF'
-}
-
-# Quote evaled strings.
-for var in SHELL \
-ECHO \
-SED \
-GREP \
-EGREP \
-FGREP \
-LD \
-NM \
-LN_S \
-lt_SP2NL \
-lt_NL2SP \
-reload_flag \
-OBJDUMP \
-deplibs_check_method \
-file_magic_cmd \
-AR \
-AR_FLAGS \
-STRIP \
-RANLIB \
-CC \
-CFLAGS \
-compiler \
-lt_cv_sys_global_symbol_pipe \
-lt_cv_sys_global_symbol_to_cdecl \
-lt_cv_sys_global_symbol_to_c_name_address \
-lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \
-lt_prog_compiler_no_builtin_flag \
-lt_prog_compiler_wl \
-lt_prog_compiler_pic \
-lt_prog_compiler_static \
-lt_cv_prog_compiler_c_o \
-need_locks \
-DSYMUTIL \
-NMEDIT \
-LIPO \
-OTOOL \
-OTOOL64 \
-shrext_cmds \
-export_dynamic_flag_spec \
-whole_archive_flag_spec \
-compiler_needs_object \
-with_gnu_ld \
-allow_undefined_flag \
-no_undefined_flag \
-hardcode_libdir_flag_spec \
-hardcode_libdir_flag_spec_ld \
-hardcode_libdir_separator \
-fix_srcfile_path \
-exclude_expsyms \
-include_expsyms \
-file_list_spec \
-variables_saved_for_relink \
-libname_spec \
-library_names_spec \
-soname_spec \
-install_override_mode \
-finish_eval \
-old_striplib \
-striplib; do
- case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
- *[\\\\\\\`\\"\\\$]*)
- eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\""
- ;;
- *)
- eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
- ;;
- esac
-done
-
-# Double-quote double-evaled strings.
-for var in reload_cmds \
-old_postinstall_cmds \
-old_postuninstall_cmds \
-old_archive_cmds \
-extract_expsyms_cmds \
-old_archive_from_new_cmds \
-old_archive_from_expsyms_cmds \
-archive_cmds \
-archive_expsym_cmds \
-module_cmds \
-module_expsym_cmds \
-export_symbols_cmds \
-prelink_cmds \
-postinstall_cmds \
-postuninstall_cmds \
-finish_cmds \
-sys_lib_search_path_spec \
-sys_lib_dlsearch_path_spec; do
- case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
- *[\\\\\\\`\\"\\\$]*)
- eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\""
- ;;
- *)
- eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
- ;;
- esac
-done
-
-ac_aux_dir='$ac_aux_dir'
-xsi_shell='$xsi_shell'
-lt_shell_append='$lt_shell_append'
-
-# See if we are running on zsh, and set the options which allow our
-# commands through without removal of \ escapes INIT.
-if test -n "\${ZSH_VERSION+set}" ; then
- setopt NO_GLOB_SUBST
-fi
-
-
- PACKAGE='$PACKAGE'
- VERSION='$VERSION'
- TIMESTAMP='$TIMESTAMP'
- RM='$RM'
- ofile='$ofile'
-
-
-
-# Capture the value of obsolete ALL_LINGUAS because we need it to compute
- # POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES, CATALOGS. But hide it
- # from automake.
- eval 'OBSOLETE_ALL_LINGUAS''="$ALL_LINGUAS"'
- # Capture the value of LINGUAS because we need it to compute CATALOGS.
- LINGUAS="${LINGUAS-%UNSET%}"
-
-# Capture the value of obsolete ALL_LINGUAS because we need it to compute
- # POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES, CATALOGS. But hide it
- # from automake.
- eval 'OBSOLETE_ALL_LINGUAS''="$ALL_LINGUAS"'
- # Capture the value of LINGUAS because we need it to compute CATALOGS.
- LINGUAS="${LINGUAS-%UNSET%}"
-
-
-_ACEOF
-
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-
-# Handling of arguments.
-for ac_config_target in $ac_config_targets
-do
- case $ac_config_target in
- "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
- "libtool") CONFIG_COMMANDS="$CONFIG_COMMANDS libtool" ;;
- "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h:config.in" ;;
- "default-1") CONFIG_COMMANDS="$CONFIG_COMMANDS default-1" ;;
- "default-2") CONFIG_COMMANDS="$CONFIG_COMMANDS default-2" ;;
- "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
- "po/Makefile.in") CONFIG_FILES="$CONFIG_FILES po/Makefile.in:po/Make-in" ;;
-
- *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
- esac
-done
-
-
-# If the user did not use the arguments to specify the items to instantiate,
-# then the envvar interface is used. Set only those that are not.
-# We use the long form for the default assignment because of an extremely
-# bizarre bug on SunOS 4.1.3.
-if $ac_need_defaults; then
- test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
- test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
- test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
-fi
-
-# Have a temporary directory for convenience. Make it in the build tree
-# simply because there is no reason against having it here, and in addition,
-# creating and moving files from /tmp can sometimes cause problems.
-# Hook for its removal unless debugging.
-# Note that there is a small window in which the directory will not be cleaned:
-# after its creation but before its name has been assigned to `$tmp'.
-$debug ||
-{
- tmp= ac_tmp=
- trap 'exit_status=$?
- : "${ac_tmp:=$tmp}"
- { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
-' 0
- trap 'as_fn_exit 1' 1 2 13 15
-}
-# Create a (secure) tmp directory for tmp files.
-
-{
- tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
- test -d "$tmp"
-} ||
-{
- tmp=./conf$$-$RANDOM
- (umask 077 && mkdir "$tmp")
-} || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
-ac_tmp=$tmp
-
-# Set up the scripts for CONFIG_FILES section.
-# No need to generate them if there are no CONFIG_FILES.
-# This happens for instance with `./config.status config.h'.
-if test -n "$CONFIG_FILES"; then
-
-
-ac_cr=`echo X | tr X '\015'`
-# On cygwin, bash can eat \r inside `` if the user requested igncr.
-# But we know of no other shell where ac_cr would be empty at this
-# point, so we can use a bashism as a fallback.
-if test "x$ac_cr" = x; then
- eval ac_cr=\$\'\\r\'
-fi
-ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
-if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
- ac_cs_awk_cr='\\r'
-else
- ac_cs_awk_cr=$ac_cr
-fi
-
-echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
-_ACEOF
-
-
-{
- echo "cat >conf$$subs.awk <<_ACEOF" &&
- echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
- echo "_ACEOF"
-} >conf$$subs.sh ||
- as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
-ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
-ac_delim='%!_!# '
-for ac_last_try in false false false false false :; do
- . ./conf$$subs.sh ||
- as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
-
- ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
- if test $ac_delim_n = $ac_delim_num; then
- break
- elif $ac_last_try; then
- as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
- else
- ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
- fi
-done
-rm -f conf$$subs.sh
-
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
-_ACEOF
-sed -n '
-h
-s/^/S["/; s/!.*/"]=/
-p
-g
-s/^[^!]*!//
-:repl
-t repl
-s/'"$ac_delim"'$//
-t delim
-:nl
-h
-s/\(.\{148\}\)..*/\1/
-t more1
-s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
-p
-n
-b repl
-:more1
-s/["\\]/\\&/g; s/^/"/; s/$/"\\/
-p
-g
-s/.\{148\}//
-t nl
-:delim
-h
-s/\(.\{148\}\)..*/\1/
-t more2
-s/["\\]/\\&/g; s/^/"/; s/$/"/
-p
-b
-:more2
-s/["\\]/\\&/g; s/^/"/; s/$/"\\/
-p
-g
-s/.\{148\}//
-t delim
-' <conf$$subs.awk | sed '
-/^[^""]/{
- N
- s/\n//
-}
-' >>$CONFIG_STATUS || ac_write_fail=1
-rm -f conf$$subs.awk
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-_ACAWK
-cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
- for (key in S) S_is_set[key] = 1
- FS = ""
-
-}
-{
- line = $ 0
- nfields = split(line, field, "@")
- substed = 0
- len = length(field[1])
- for (i = 2; i < nfields; i++) {
- key = field[i]
- keylen = length(key)
- if (S_is_set[key]) {
- value = S[key]
- line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
- len += length(value) + length(field[++i])
- substed = 1
- } else
- len += 1 + keylen
- }
-
- print line
-}
-
-_ACAWK
-_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
- sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
-else
- cat
-fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
- || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
-_ACEOF
-
-# VPATH may cause trouble with some makes, so we remove sole $(srcdir),
-# ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
-# trailing colons and then remove the whole line if VPATH becomes empty
-# (actually we leave an empty line to preserve line numbers).
-if test "x$srcdir" = x.; then
- ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{
-h
-s///
-s/^/:/
-s/[ ]*$/:/
-s/:\$(srcdir):/:/g
-s/:\${srcdir}:/:/g
-s/:@srcdir@:/:/g
-s/^:*//
-s/:*$//
-x
-s/\(=[ ]*\).*/\1/
-G
-s/\n//
-s/^[^=]*=[ ]*$//
-}'
-fi
-
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-fi # test -n "$CONFIG_FILES"
-
-# Set up the scripts for CONFIG_HEADERS section.
-# No need to generate them if there are no CONFIG_HEADERS.
-# This happens for instance with `./config.status Makefile'.
-if test -n "$CONFIG_HEADERS"; then
-cat >"$ac_tmp/defines.awk" <<\_ACAWK ||
-BEGIN {
-_ACEOF
-
-# Transform confdefs.h into an awk script `defines.awk', embedded as
-# here-document in config.status, that substitutes the proper values into
-# config.h.in to produce config.h.
-
-# Create a delimiter string that does not exist in confdefs.h, to ease
-# handling of long lines.
-ac_delim='%!_!# '
-for ac_last_try in false false :; do
- ac_tt=`sed -n "/$ac_delim/p" confdefs.h`
- if test -z "$ac_tt"; then
- break
- elif $ac_last_try; then
- as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
- else
- ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
- fi
-done
-
-# For the awk script, D is an array of macro values keyed by name,
-# likewise P contains macro parameters if any. Preserve backslash
-# newline sequences.
-
-ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
-sed -n '
-s/.\{148\}/&'"$ac_delim"'/g
-t rset
-:rset
-s/^[ ]*#[ ]*define[ ][ ]*/ /
-t def
-d
-:def
-s/\\$//
-t bsnl
-s/["\\]/\\&/g
-s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
-D["\1"]=" \3"/p
-s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
-d
-:bsnl
-s/["\\]/\\&/g
-s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
-D["\1"]=" \3\\\\\\n"\\/p
-t cont
-s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
-t cont
-d
-:cont
-n
-s/.\{148\}/&'"$ac_delim"'/g
-t clear
-:clear
-s/\\$//
-t bsnlc
-s/["\\]/\\&/g; s/^/"/; s/$/"/p
-d
-:bsnlc
-s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
-b cont
-' <confdefs.h | sed '
-s/'"$ac_delim"'/"\\\
-"/g' >>$CONFIG_STATUS || ac_write_fail=1
-
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
- for (key in D) D_is_set[key] = 1
- FS = ""
-}
-/^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
- line = \$ 0
- split(line, arg, " ")
- if (arg[1] == "#") {
- defundef = arg[2]
- mac1 = arg[3]
- } else {
- defundef = substr(arg[1], 2)
- mac1 = arg[2]
- }
- split(mac1, mac2, "(") #)
- macro = mac2[1]
- prefix = substr(line, 1, index(line, defundef) - 1)
- if (D_is_set[macro]) {
- # Preserve the white space surrounding the "#".
- print prefix "define", macro P[macro] D[macro]
- next
- } else {
- # Replace #undef with comments. This is necessary, for example,
- # in the case of _POSIX_SOURCE, which is predefined and required
- # on some systems where configure will not decide to define it.
- if (defundef == "undef") {
- print "/*", prefix defundef, macro, "*/"
- next
- }
- }
-}
-{ print }
-_ACAWK
-_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
- as_fn_error $? "could not setup config headers machinery" "$LINENO" 5
-fi # test -n "$CONFIG_HEADERS"
-
-
-eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS"
-shift
-for ac_tag
-do
- case $ac_tag in
- :[FHLC]) ac_mode=$ac_tag; continue;;
- esac
- case $ac_mode$ac_tag in
- :[FHL]*:*);;
- :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
- :[FH]-) ac_tag=-:-;;
- :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
- esac
- ac_save_IFS=$IFS
- IFS=:
- set x $ac_tag
- IFS=$ac_save_IFS
- shift
- ac_file=$1
- shift
-
- case $ac_mode in
- :L) ac_source=$1;;
- :[FH])
- ac_file_inputs=
- for ac_f
- do
- case $ac_f in
- -) ac_f="$ac_tmp/stdin";;
- *) # Look for the file first in the build tree, then in the source tree
- # (if the path is not absolute). The absolute path cannot be DOS-style,
- # because $ac_f cannot contain `:'.
- test -f "$ac_f" ||
- case $ac_f in
- [\\/$]*) false;;
- *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
- esac ||
- as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
- esac
- case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
- as_fn_append ac_file_inputs " '$ac_f'"
- done
-
- # Let's still pretend it is `configure' which instantiates (i.e., don't
- # use $as_me), people would be surprised to read:
- # /* config.h. Generated by config.status. */
- configure_input='Generated from '`
- $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
- `' by configure.'
- if test x"$ac_file" != x-; then
- configure_input="$ac_file. $configure_input"
- { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
-$as_echo "$as_me: creating $ac_file" >&6;}
- fi
- # Neutralize special characters interpreted by sed in replacement strings.
- case $configure_input in #(
- *\&* | *\|* | *\\* )
- ac_sed_conf_input=`$as_echo "$configure_input" |
- sed 's/[\\\\&|]/\\\\&/g'`;; #(
- *) ac_sed_conf_input=$configure_input;;
- esac
-
- case $ac_tag in
- *:-:* | *:-) cat >"$ac_tmp/stdin" \
- || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
- esac
- ;;
- esac
-
- ac_dir=`$as_dirname -- "$ac_file" ||
-$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$ac_file" : 'X\(//\)[^/]' \| \
- X"$ac_file" : 'X\(//\)$' \| \
- X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$ac_file" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
- as_dir="$ac_dir"; as_fn_mkdir_p
- ac_builddir=.
-
-case "$ac_dir" in
-.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
-*)
- ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
- # A ".." for each directory in $ac_dir_suffix.
- ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
- case $ac_top_builddir_sub in
- "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
- *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
- esac ;;
-esac
-ac_abs_top_builddir=$ac_pwd
-ac_abs_builddir=$ac_pwd$ac_dir_suffix
-# for backward compatibility:
-ac_top_builddir=$ac_top_build_prefix
-
-case $srcdir in
- .) # We are building in place.
- ac_srcdir=.
- ac_top_srcdir=$ac_top_builddir_sub
- ac_abs_top_srcdir=$ac_pwd ;;
- [\\/]* | ?:[\\/]* ) # Absolute name.
- ac_srcdir=$srcdir$ac_dir_suffix;
- ac_top_srcdir=$srcdir
- ac_abs_top_srcdir=$srcdir ;;
- *) # Relative name.
- ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
- ac_top_srcdir=$ac_top_build_prefix$srcdir
- ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
-esac
-ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
-
-
- case $ac_mode in
- :F)
- #
- # CONFIG_FILE
- #
-
- case $INSTALL in
- [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
- *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
- esac
- ac_MKDIR_P=$MKDIR_P
- case $MKDIR_P in
- [\\/$]* | ?:[\\/]* ) ;;
- */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
- esac
-_ACEOF
-
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-# If the template does not know about datarootdir, expand it.
-# FIXME: This hack should be removed a few years after 2.60.
-ac_datarootdir_hack=; ac_datarootdir_seen=
-ac_sed_dataroot='
-/datarootdir/ {
- p
- q
-}
-/@datadir@/p
-/@docdir@/p
-/@infodir@/p
-/@localedir@/p
-/@mandir@/p'
-case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
-*datarootdir*) ac_datarootdir_seen=yes;;
-*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
-$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
-_ACEOF
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
- ac_datarootdir_hack='
- s&@datadir@&$datadir&g
- s&@docdir@&$docdir&g
- s&@infodir@&$infodir&g
- s&@localedir@&$localedir&g
- s&@mandir@&$mandir&g
- s&\\\${datarootdir}&$datarootdir&g' ;;
-esac
-_ACEOF
-
-# Neutralize VPATH when `$srcdir' = `.'.
-# Shell code in configure.ac might set extrasub.
-# FIXME: do we really want to maintain this feature?
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-ac_sed_extra="$ac_vpsub
-$extrasub
-_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-:t
-/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
-s|@configure_input@|$ac_sed_conf_input|;t t
-s&@top_builddir@&$ac_top_builddir_sub&;t t
-s&@top_build_prefix@&$ac_top_build_prefix&;t t
-s&@srcdir@&$ac_srcdir&;t t
-s&@abs_srcdir@&$ac_abs_srcdir&;t t
-s&@top_srcdir@&$ac_top_srcdir&;t t
-s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
-s&@builddir@&$ac_builddir&;t t
-s&@abs_builddir@&$ac_abs_builddir&;t t
-s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
-s&@INSTALL@&$ac_INSTALL&;t t
-s&@MKDIR_P@&$ac_MKDIR_P&;t t
-$ac_datarootdir_hack
-"
-eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \
- >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
-
-test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
- { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
- { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \
- "$ac_tmp/out"`; test -z "$ac_out"; } &&
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
-which seems to be undefined. Please make sure it is defined" >&5
-$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
-which seems to be undefined. Please make sure it is defined" >&2;}
-
- rm -f "$ac_tmp/stdin"
- case $ac_file in
- -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
- *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
- esac \
- || as_fn_error $? "could not create $ac_file" "$LINENO" 5
- ;;
- :H)
- #
- # CONFIG_HEADER
- #
- if test x"$ac_file" != x-; then
- {
- $as_echo "/* $configure_input */" \
- && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs"
- } >"$ac_tmp/config.h" \
- || as_fn_error $? "could not create $ac_file" "$LINENO" 5
- if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
-$as_echo "$as_me: $ac_file is unchanged" >&6;}
- else
- rm -f "$ac_file"
- mv "$ac_tmp/config.h" "$ac_file" \
- || as_fn_error $? "could not create $ac_file" "$LINENO" 5
- fi
- else
- $as_echo "/* $configure_input */" \
- && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \
- || as_fn_error $? "could not create -" "$LINENO" 5
- fi
-# Compute "$ac_file"'s index in $config_headers.
-_am_arg="$ac_file"
-_am_stamp_count=1
-for _am_header in $config_headers :; do
- case $_am_header in
- $_am_arg | $_am_arg:* )
- break ;;
- * )
- _am_stamp_count=`expr $_am_stamp_count + 1` ;;
- esac
-done
-echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" ||
-$as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$_am_arg" : 'X\(//\)[^/]' \| \
- X"$_am_arg" : 'X\(//\)$' \| \
- X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$_am_arg" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`/stamp-h$_am_stamp_count
- ;;
-
- :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
-$as_echo "$as_me: executing $ac_file commands" >&6;}
- ;;
- esac
-
-
- case $ac_file$ac_mode in
- "depfiles":C) test x"$AMDEP_TRUE" != x"" || {
- # Older Autoconf quotes --file arguments for eval, but not when files
- # are listed without --file. Let's play safe and only enable the eval
- # if we detect the quoting.
- case $CONFIG_FILES in
- *\'*) eval set x "$CONFIG_FILES" ;;
- *) set x $CONFIG_FILES ;;
- esac
- shift
- for mf
- do
- # Strip MF so we end up with the name of the file.
- mf=`echo "$mf" | sed -e 's/:.*$//'`
- # Check whether this is an Automake generated Makefile or not.
- # We used to match only the files named 'Makefile.in', but
- # some people rename them; so instead we look at the file content.
- # Grep'ing the first line is not enough: some people post-process
- # each Makefile.in and add a new line on top of each file to say so.
- # Grep'ing the whole file is not good either: AIX grep has a line
- # limit of 2048, but all sed's we know have understand at least 4000.
- if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
- dirpart=`$as_dirname -- "$mf" ||
-$as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$mf" : 'X\(//\)[^/]' \| \
- X"$mf" : 'X\(//\)$' \| \
- X"$mf" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$mf" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
- else
- continue
- fi
- # Extract the definition of DEPDIR, am__include, and am__quote
- # from the Makefile without running 'make'.
- DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
- test -z "$DEPDIR" && continue
- am__include=`sed -n 's/^am__include = //p' < "$mf"`
- test -z "$am__include" && continue
- am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
- # Find all dependency output files, they are included files with
- # $(DEPDIR) in their names. We invoke sed twice because it is the
- # simplest approach to changing $(DEPDIR) to its actual value in the
- # expansion.
- for file in `sed -n "
- s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
- sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g'`; do
- # Make sure the directory exists.
- test -f "$dirpart/$file" && continue
- fdir=`$as_dirname -- "$file" ||
-$as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$file" : 'X\(//\)[^/]' \| \
- X"$file" : 'X\(//\)$' \| \
- X"$file" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$file" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
- as_dir=$dirpart/$fdir; as_fn_mkdir_p
- # echo "creating $dirpart/$file"
- echo '# dummy' > "$dirpart/$file"
- done
- done
-}
- ;;
- "libtool":C)
-
- # See if we are running on zsh, and set the options which allow our
- # commands through without removal of \ escapes.
- if test -n "${ZSH_VERSION+set}" ; then
- setopt NO_GLOB_SUBST
- fi
-
- cfgfile="${ofile}T"
- trap "$RM \"$cfgfile\"; exit 1" 1 2 15
- $RM "$cfgfile"
-
- cat <<_LT_EOF >> "$cfgfile"
-#! $SHELL
-
-# `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
-# Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION
-# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
-# NOTE: Changes made to this file will be lost: look at ltmain.sh.
-#
-# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
-# 2006, 2007, 2008, 2009 Free Software Foundation, Inc.
-# Written by Gordon Matzigkeit, 1996
-#
-# This file is part of GNU Libtool.
-#
-# GNU Libtool is free software; you can redistribute it and/or
-# modify it under the terms of the GNU General Public License as
-# published by the Free Software Foundation; either version 2 of
-# the License, or (at your option) any later version.
-#
-# As a special exception to the GNU General Public License,
-# if you distribute this file as part of a program or library that
-# is built using GNU Libtool, you may include this file under the
-# same distribution terms that you use for the rest of that program.
-#
-# GNU Libtool is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with GNU Libtool; see the file COPYING. If not, a copy
-# can be downloaded from http://www.gnu.org/licenses/gpl.html, or
-# obtained by writing to the Free Software Foundation, Inc.,
-# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
-
-
-# The names of the tagged configurations supported by this script.
-available_tags=""
-
-# ### BEGIN LIBTOOL CONFIG
-
-# Which release of libtool.m4 was used?
-macro_version=$macro_version
-macro_revision=$macro_revision
-
-# Whether or not to build shared libraries.
-build_libtool_libs=$enable_shared
-
-# Whether or not to build static libraries.
-build_old_libs=$enable_static
-
-# What type of objects to build.
-pic_mode=$pic_mode
-
-# Whether or not to optimize for fast installation.
-fast_install=$enable_fast_install
-
-# Shell to use when invoking shell scripts.
-SHELL=$lt_SHELL
-
-# An echo program that protects backslashes.
-ECHO=$lt_ECHO
-
-# The host system.
-host_alias=$host_alias
-host=$host
-host_os=$host_os
-
-# The build system.
-build_alias=$build_alias
-build=$build
-build_os=$build_os
-
-# A sed program that does not truncate output.
-SED=$lt_SED
-
-# Sed that helps us avoid accidentally triggering echo(1) options like -n.
-Xsed="\$SED -e 1s/^X//"
-
-# A grep program that handles long lines.
-GREP=$lt_GREP
-
-# An ERE matcher.
-EGREP=$lt_EGREP
-
-# A literal string matcher.
-FGREP=$lt_FGREP
-
-# A BSD- or MS-compatible name lister.
-NM=$lt_NM
-
-# Whether we need soft or hard links.
-LN_S=$lt_LN_S
-
-# What is the maximum length of a command?
-max_cmd_len=$max_cmd_len
-
-# Object file suffix (normally "o").
-objext=$ac_objext
-
-# Executable file suffix (normally "").
-exeext=$exeext
-
-# whether the shell understands "unset".
-lt_unset=$lt_unset
-
-# turn spaces into newlines.
-SP2NL=$lt_lt_SP2NL
-
-# turn newlines into spaces.
-NL2SP=$lt_lt_NL2SP
-
-# An object symbol dumper.
-OBJDUMP=$lt_OBJDUMP
-
-# Method to check whether dependent libraries are shared objects.
-deplibs_check_method=$lt_deplibs_check_method
-
-# Command to use when deplibs_check_method == "file_magic".
-file_magic_cmd=$lt_file_magic_cmd
-
-# The archiver.
-AR=$lt_AR
-AR_FLAGS=$lt_AR_FLAGS
-
-# A symbol stripping program.
-STRIP=$lt_STRIP
-
-# Commands used to install an old-style archive.
-RANLIB=$lt_RANLIB
-old_postinstall_cmds=$lt_old_postinstall_cmds
-old_postuninstall_cmds=$lt_old_postuninstall_cmds
-
-# Whether to use a lock for old archive extraction.
-lock_old_archive_extraction=$lock_old_archive_extraction
-
-# A C compiler.
-LTCC=$lt_CC
-
-# LTCC compiler flags.
-LTCFLAGS=$lt_CFLAGS
-
-# Take the output of nm and produce a listing of raw symbols and C names.
-global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe
-
-# Transform the output of nm in a proper C declaration.
-global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl
-
-# Transform the output of nm in a C name address pair.
-global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
-
-# Transform the output of nm in a C name address pair when lib prefix is needed.
-global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix
-
-# The name of the directory that contains temporary libtool files.
-objdir=$objdir
-
-# Used to examine libraries when file_magic_cmd begins with "file".
-MAGIC_CMD=$MAGIC_CMD
-
-# Must we lock files when doing compilation?
-need_locks=$lt_need_locks
-
-# Tool to manipulate archived DWARF debug symbol files on Mac OS X.
-DSYMUTIL=$lt_DSYMUTIL
-
-# Tool to change global to local symbols on Mac OS X.
-NMEDIT=$lt_NMEDIT
-
-# Tool to manipulate fat objects and archives on Mac OS X.
-LIPO=$lt_LIPO
-
-# ldd/readelf like tool for Mach-O binaries on Mac OS X.
-OTOOL=$lt_OTOOL
-
-# ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4.
-OTOOL64=$lt_OTOOL64
-
-# Old archive suffix (normally "a").
-libext=$libext
-
-# Shared library suffix (normally ".so").
-shrext_cmds=$lt_shrext_cmds
-
-# The commands to extract the exported symbol list from a shared archive.
-extract_expsyms_cmds=$lt_extract_expsyms_cmds
-
-# Variables whose values should be saved in libtool wrapper scripts and
-# restored at link time.
-variables_saved_for_relink=$lt_variables_saved_for_relink
-
-# Do we need the "lib" prefix for modules?
-need_lib_prefix=$need_lib_prefix
-
-# Do we need a version for libraries?
-need_version=$need_version
-
-# Library versioning type.
-version_type=$version_type
-
-# Shared library runtime path variable.
-runpath_var=$runpath_var
-
-# Shared library path variable.
-shlibpath_var=$shlibpath_var
-
-# Is shlibpath searched before the hard-coded library search path?
-shlibpath_overrides_runpath=$shlibpath_overrides_runpath
-
-# Format of library name prefix.
-libname_spec=$lt_libname_spec
-
-# List of archive names. First name is the real one, the rest are links.
-# The last name is the one that the linker finds with -lNAME
-library_names_spec=$lt_library_names_spec
-
-# The coded name of the library, if different from the real name.
-soname_spec=$lt_soname_spec
-
-# Permission mode override for installation of shared libraries.
-install_override_mode=$lt_install_override_mode
-
-# Command to use after installation of a shared archive.
-postinstall_cmds=$lt_postinstall_cmds
-
-# Command to use after uninstallation of a shared archive.
-postuninstall_cmds=$lt_postuninstall_cmds
-
-# Commands used to finish a libtool library installation in a directory.
-finish_cmds=$lt_finish_cmds
-
-# As "finish_cmds", except a single script fragment to be evaled but
-# not shown.
-finish_eval=$lt_finish_eval
-
-# Whether we should hardcode library paths into libraries.
-hardcode_into_libs=$hardcode_into_libs
-
-# Compile-time system search path for libraries.
-sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
-
-# Run-time system search path for libraries.
-sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
-
-# Whether dlopen is supported.
-dlopen_support=$enable_dlopen
-
-# Whether dlopen of programs is supported.
-dlopen_self=$enable_dlopen_self
-
-# Whether dlopen of statically linked programs is supported.
-dlopen_self_static=$enable_dlopen_self_static
-
-# Commands to strip libraries.
-old_striplib=$lt_old_striplib
-striplib=$lt_striplib
-
-
-# The linker used to build libraries.
-LD=$lt_LD
-
-# How to create reloadable object files.
-reload_flag=$lt_reload_flag
-reload_cmds=$lt_reload_cmds
-
-# Commands used to build an old-style archive.
-old_archive_cmds=$lt_old_archive_cmds
-
-# A language specific compiler.
-CC=$lt_compiler
-
-# Is the compiler the GNU compiler?
-with_gcc=$GCC
-
-# Compiler flag to turn off builtin functions.
-no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag
-
-# How to pass a linker flag through the compiler.
-wl=$lt_lt_prog_compiler_wl
-
-# Additional compiler flags for building library objects.
-pic_flag=$lt_lt_prog_compiler_pic
-
-# Compiler flag to prevent dynamic linking.
-link_static_flag=$lt_lt_prog_compiler_static
-
-# Does compiler simultaneously support -c and -o options?
-compiler_c_o=$lt_lt_cv_prog_compiler_c_o
-
-# Whether or not to add -lc for building shared libraries.
-build_libtool_need_lc=$archive_cmds_need_lc
-
-# Whether or not to disallow shared libs when runtime libs are static.
-allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes
-
-# Compiler flag to allow reflexive dlopens.
-export_dynamic_flag_spec=$lt_export_dynamic_flag_spec
-
-# Compiler flag to generate shared objects directly from archives.
-whole_archive_flag_spec=$lt_whole_archive_flag_spec
-
-# Whether the compiler copes with passing no objects directly.
-compiler_needs_object=$lt_compiler_needs_object
-
-# Create an old-style archive from a shared archive.
-old_archive_from_new_cmds=$lt_old_archive_from_new_cmds
-
-# Create a temporary old-style archive to link instead of a shared archive.
-old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds
-
-# Commands used to build a shared archive.
-archive_cmds=$lt_archive_cmds
-archive_expsym_cmds=$lt_archive_expsym_cmds
-
-# Commands used to build a loadable module if different from building
-# a shared archive.
-module_cmds=$lt_module_cmds
-module_expsym_cmds=$lt_module_expsym_cmds
-
-# Whether we are building with GNU ld or not.
-with_gnu_ld=$lt_with_gnu_ld
-
-# Flag that allows shared libraries with undefined symbols to be built.
-allow_undefined_flag=$lt_allow_undefined_flag
-
-# Flag that enforces no undefined symbols.
-no_undefined_flag=$lt_no_undefined_flag
-
-# Flag to hardcode \$libdir into a binary during linking.
-# This must work even if \$libdir does not exist
-hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec
-
-# If ld is used when linking, flag to hardcode \$libdir into a binary
-# during linking. This must work even if \$libdir does not exist.
-hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld
-
-# Whether we need a single "-rpath" flag with a separated argument.
-hardcode_libdir_separator=$lt_hardcode_libdir_separator
-
-# Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
-# DIR into the resulting binary.
-hardcode_direct=$hardcode_direct
-
-# Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
-# DIR into the resulting binary and the resulting library dependency is
-# "absolute",i.e impossible to change by setting \${shlibpath_var} if the
-# library is relocated.
-hardcode_direct_absolute=$hardcode_direct_absolute
-
-# Set to "yes" if using the -LDIR flag during linking hardcodes DIR
-# into the resulting binary.
-hardcode_minus_L=$hardcode_minus_L
-
-# Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR
-# into the resulting binary.
-hardcode_shlibpath_var=$hardcode_shlibpath_var
-
-# Set to "yes" if building a shared library automatically hardcodes DIR
-# into the library and all subsequent libraries and executables linked
-# against it.
-hardcode_automatic=$hardcode_automatic
-
-# Set to yes if linker adds runtime paths of dependent libraries
-# to runtime path list.
-inherit_rpath=$inherit_rpath
-
-# Whether libtool must link a program against all its dependency libraries.
-link_all_deplibs=$link_all_deplibs
-
-# Fix the shell variable \$srcfile for the compiler.
-fix_srcfile_path=$lt_fix_srcfile_path
-
-# Set to "yes" if exported symbols are required.
-always_export_symbols=$always_export_symbols
-
-# The commands to list exported symbols.
-export_symbols_cmds=$lt_export_symbols_cmds
-
-# Symbols that should not be listed in the preloaded symbols.
-exclude_expsyms=$lt_exclude_expsyms
-
-# Symbols that must always be exported.
-include_expsyms=$lt_include_expsyms
-
-# Commands necessary for linking programs (against libraries) with templates.
-prelink_cmds=$lt_prelink_cmds
-
-# Specify filename containing input files.
-file_list_spec=$lt_file_list_spec
-
-# How to hardcode a shared library path into an executable.
-hardcode_action=$hardcode_action
-
-# ### END LIBTOOL CONFIG
-
-_LT_EOF
-
- case $host_os in
- aix3*)
- cat <<\_LT_EOF >> "$cfgfile"
-# AIX sometimes has problems with the GCC collect2 program. For some
-# reason, if we set the COLLECT_NAMES environment variable, the problems
-# vanish in a puff of smoke.
-if test "X${COLLECT_NAMES+set}" != Xset; then
- COLLECT_NAMES=
- export COLLECT_NAMES
-fi
-_LT_EOF
- ;;
- esac
-
-
-ltmain="$ac_aux_dir/ltmain.sh"
-
-
- # We use sed instead of cat because bash on DJGPP gets confused if
- # if finds mixed CR/LF and LF-only lines. Since sed operates in
- # text mode, it properly converts lines to CR/LF. This bash problem
- # is reportedly fixed, but why not run on old versions too?
- sed '/^# Generated shell functions inserted here/q' "$ltmain" >> "$cfgfile" \
- || (rm -f "$cfgfile"; exit 1)
-
- case $xsi_shell in
- yes)
- cat << \_LT_EOF >> "$cfgfile"
-
-# func_dirname file append nondir_replacement
-# Compute the dirname of FILE. If nonempty, add APPEND to the result,
-# otherwise set result to NONDIR_REPLACEMENT.
-func_dirname ()
-{
- case ${1} in
- */*) func_dirname_result="${1%/*}${2}" ;;
- * ) func_dirname_result="${3}" ;;
- esac
-}
-
-# func_basename file
-func_basename ()
-{
- func_basename_result="${1##*/}"
-}
-
-# func_dirname_and_basename file append nondir_replacement
-# perform func_basename and func_dirname in a single function
-# call:
-# dirname: Compute the dirname of FILE. If nonempty,
-# add APPEND to the result, otherwise set result
-# to NONDIR_REPLACEMENT.
-# value returned in "$func_dirname_result"
-# basename: Compute filename of FILE.
-# value retuned in "$func_basename_result"
-# Implementation must be kept synchronized with func_dirname
-# and func_basename. For efficiency, we do not delegate to
-# those functions but instead duplicate the functionality here.
-func_dirname_and_basename ()
-{
- case ${1} in
- */*) func_dirname_result="${1%/*}${2}" ;;
- * ) func_dirname_result="${3}" ;;
- esac
- func_basename_result="${1##*/}"
-}
-
-# func_stripname prefix suffix name
-# strip PREFIX and SUFFIX off of NAME.
-# PREFIX and SUFFIX must not contain globbing or regex special
-# characters, hashes, percent signs, but SUFFIX may contain a leading
-# dot (in which case that matches only a dot).
-func_stripname ()
-{
- # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are
- # positional parameters, so assign one to ordinary parameter first.
- func_stripname_result=${3}
- func_stripname_result=${func_stripname_result#"${1}"}
- func_stripname_result=${func_stripname_result%"${2}"}
-}
-
-# func_opt_split
-func_opt_split ()
-{
- func_opt_split_opt=${1%%=*}
- func_opt_split_arg=${1#*=}
-}
-
-# func_lo2o object
-func_lo2o ()
-{
- case ${1} in
- *.lo) func_lo2o_result=${1%.lo}.${objext} ;;
- *) func_lo2o_result=${1} ;;
- esac
-}
-
-# func_xform libobj-or-source
-func_xform ()
-{
- func_xform_result=${1%.*}.lo
-}
-
-# func_arith arithmetic-term...
-func_arith ()
-{
- func_arith_result=$(( $* ))
-}
-
-# func_len string
-# STRING may not start with a hyphen.
-func_len ()
-{
- func_len_result=${#1}
-}
-
-_LT_EOF
- ;;
- *) # Bourne compatible functions.
- cat << \_LT_EOF >> "$cfgfile"
-
-# func_dirname file append nondir_replacement
-# Compute the dirname of FILE. If nonempty, add APPEND to the result,
-# otherwise set result to NONDIR_REPLACEMENT.
-func_dirname ()
-{
- # Extract subdirectory from the argument.
- func_dirname_result=`$ECHO "${1}" | $SED "$dirname"`
- if test "X$func_dirname_result" = "X${1}"; then
- func_dirname_result="${3}"
- else
- func_dirname_result="$func_dirname_result${2}"
- fi
-}
-
-# func_basename file
-func_basename ()
-{
- func_basename_result=`$ECHO "${1}" | $SED "$basename"`
-}
-
-
-# func_stripname prefix suffix name
-# strip PREFIX and SUFFIX off of NAME.
-# PREFIX and SUFFIX must not contain globbing or regex special
-# characters, hashes, percent signs, but SUFFIX may contain a leading
-# dot (in which case that matches only a dot).
-# func_strip_suffix prefix name
-func_stripname ()
-{
- case ${2} in
- .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;;
- *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;;
- esac
-}
-
-# sed scripts:
-my_sed_long_opt='1s/^\(-[^=]*\)=.*/\1/;q'
-my_sed_long_arg='1s/^-[^=]*=//'
-
-# func_opt_split
-func_opt_split ()
-{
- func_opt_split_opt=`$ECHO "${1}" | $SED "$my_sed_long_opt"`
- func_opt_split_arg=`$ECHO "${1}" | $SED "$my_sed_long_arg"`
-}
-
-# func_lo2o object
-func_lo2o ()
-{
- func_lo2o_result=`$ECHO "${1}" | $SED "$lo2o"`
-}
-
-# func_xform libobj-or-source
-func_xform ()
-{
- func_xform_result=`$ECHO "${1}" | $SED 's/\.[^.]*$/.lo/'`
-}
-
-# func_arith arithmetic-term...
-func_arith ()
-{
- func_arith_result=`expr "$@"`
-}
-
-# func_len string
-# STRING may not start with a hyphen.
-func_len ()
-{
- func_len_result=`expr "$1" : ".*" 2>/dev/null || echo $max_cmd_len`
-}
-
-_LT_EOF
-esac
-
-case $lt_shell_append in
- yes)
- cat << \_LT_EOF >> "$cfgfile"
-
-# func_append var value
-# Append VALUE to the end of shell variable VAR.
-func_append ()
-{
- eval "$1+=\$2"
-}
-_LT_EOF
- ;;
- *)
- cat << \_LT_EOF >> "$cfgfile"
-
-# func_append var value
-# Append VALUE to the end of shell variable VAR.
-func_append ()
-{
- eval "$1=\$$1\$2"
-}
-
-_LT_EOF
- ;;
- esac
-
-
- sed -n '/^# Generated shell functions inserted here/,$p' "$ltmain" >> "$cfgfile" \
- || (rm -f "$cfgfile"; exit 1)
-
- mv -f "$cfgfile" "$ofile" ||
- (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
- chmod +x "$ofile"
-
- ;;
- "default-1":C)
- for ac_file in $CONFIG_FILES; do
- # Support "outfile[:infile[:infile...]]"
- case "$ac_file" in
- *:*) ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
- esac
- # PO directories have a Makefile.in generated from Makefile.in.in.
- case "$ac_file" in */Makefile.in)
- # Adjust a relative srcdir.
- ac_dir=`echo "$ac_file"|sed 's%/[^/][^/]*$%%'`
- ac_dir_suffix=/`echo "$ac_dir"|sed 's%^\./%%'`
- ac_dots=`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'`
- # In autoconf-2.13 it is called $ac_given_srcdir.
- # In autoconf-2.50 it is called $srcdir.
- test -n "$ac_given_srcdir" || ac_given_srcdir="$srcdir"
- case "$ac_given_srcdir" in
- .) top_srcdir=`echo $ac_dots|sed 's%/$%%'` ;;
- /*) top_srcdir="$ac_given_srcdir" ;;
- *) top_srcdir="$ac_dots$ac_given_srcdir" ;;
- esac
- if test -f "$ac_given_srcdir/$ac_dir/POTFILES.in"; then
- rm -f "$ac_dir/POTFILES"
- test -n "$as_me" && echo "$as_me: creating $ac_dir/POTFILES" || echo "creating $ac_dir/POTFILES"
- cat "$ac_given_srcdir/$ac_dir/POTFILES.in" | sed -e "/^#/d" -e "/^[ ]*\$/d" -e "s,.*, $top_srcdir/& \\\\," | sed -e "\$s/\(.*\) \\\\/\1/" > "$ac_dir/POTFILES"
- POMAKEFILEDEPS="POTFILES.in"
- # ALL_LINGUAS, POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES depend
- # on $ac_dir but don't depend on user-specified configuration
- # parameters.
- if test -f "$ac_given_srcdir/$ac_dir/LINGUAS"; then
- # The LINGUAS file contains the set of available languages.
- if test -n "$OBSOLETE_ALL_LINGUAS"; then
- test -n "$as_me" && echo "$as_me: setting ALL_LINGUAS in configure.ac is obsolete" || echo "setting ALL_LINGUAS in configure.ac is obsolete"
- fi
- ALL_LINGUAS_=`sed -e "/^#/d" "$ac_given_srcdir/$ac_dir/LINGUAS"`
- # Hide the ALL_LINGUAS assigment from automake.
- eval 'ALL_LINGUAS''=$ALL_LINGUAS_'
- POMAKEFILEDEPS="$POMAKEFILEDEPS LINGUAS"
- else
- # The set of available languages was given in configure.ac.
- eval 'ALL_LINGUAS''=$OBSOLETE_ALL_LINGUAS'
- fi
- case "$ac_given_srcdir" in
- .) srcdirpre= ;;
- *) srcdirpre='$(srcdir)/' ;;
- esac
- POFILES=
- GMOFILES=
- UPDATEPOFILES=
- DUMMYPOFILES=
- for lang in $ALL_LINGUAS; do
- POFILES="$POFILES $srcdirpre$lang.po"
- GMOFILES="$GMOFILES $srcdirpre$lang.gmo"
- UPDATEPOFILES="$UPDATEPOFILES $lang.po-update"
- DUMMYPOFILES="$DUMMYPOFILES $lang.nop"
- done
- # CATALOGS depends on both $ac_dir and the user's LINGUAS
- # environment variable.
- INST_LINGUAS=
- if test -n "$ALL_LINGUAS"; then
- for presentlang in $ALL_LINGUAS; do
- useit=no
- if test "%UNSET%" != "$LINGUAS"; then
- desiredlanguages="$LINGUAS"
- else
- desiredlanguages="$ALL_LINGUAS"
- fi
- for desiredlang in $desiredlanguages; do
- # Use the presentlang catalog if desiredlang is
- # a. equal to presentlang, or
- # b. a variant of presentlang (because in this case,
- # presentlang can be used as a fallback for messages
- # which are not translated in the desiredlang catalog).
- case "$desiredlang" in
- "$presentlang"*) useit=yes;;
- esac
- done
- if test $useit = yes; then
- INST_LINGUAS="$INST_LINGUAS $presentlang"
- fi
- done
- fi
- CATALOGS=
- if test -n "$INST_LINGUAS"; then
- for lang in $INST_LINGUAS; do
- CATALOGS="$CATALOGS $lang.gmo"
- done
- fi
- test -n "$as_me" && echo "$as_me: creating $ac_dir/Makefile" || echo "creating $ac_dir/Makefile"
- sed -e "/^POTFILES =/r $ac_dir/POTFILES" -e "/^# Makevars/r $ac_given_srcdir/$ac_dir/Makevars" -e "s|@POFILES@|$POFILES|g" -e "s|@GMOFILES@|$GMOFILES|g" -e "s|@UPDATEPOFILES@|$UPDATEPOFILES|g" -e "s|@DUMMYPOFILES@|$DUMMYPOFILES|g" -e "s|@CATALOGS@|$CATALOGS|g" -e "s|@POMAKEFILEDEPS@|$POMAKEFILEDEPS|g" "$ac_dir/Makefile.in" > "$ac_dir/Makefile"
- for f in "$ac_given_srcdir/$ac_dir"/Rules-*; do
- if test -f "$f"; then
- case "$f" in
- *.orig | *.bak | *~) ;;
- *) cat "$f" >> "$ac_dir/Makefile" ;;
- esac
- fi
- done
- fi
- ;;
- esac
- done ;;
- "default-2":C)
- for ac_file in $CONFIG_FILES; do
- # Support "outfile[:infile[:infile...]]"
- case "$ac_file" in
- *:*) ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
- esac
- # PO directories have a Makefile.in generated from Makefile.in.in.
- case "$ac_file" in */Makefile.in)
- # Adjust a relative srcdir.
- ac_dir=`echo "$ac_file"|sed 's%/[^/][^/]*$%%'`
- ac_dir_suffix=/`echo "$ac_dir"|sed 's%^\./%%'`
- ac_dots=`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'`
- # In autoconf-2.13 it is called $ac_given_srcdir.
- # In autoconf-2.50 it is called $srcdir.
- test -n "$ac_given_srcdir" || ac_given_srcdir="$srcdir"
- case "$ac_given_srcdir" in
- .) top_srcdir=`echo $ac_dots|sed 's%/$%%'` ;;
- /*) top_srcdir="$ac_given_srcdir" ;;
- *) top_srcdir="$ac_dots$ac_given_srcdir" ;;
- esac
- if test -f "$ac_given_srcdir/$ac_dir/POTFILES.in"; then
- rm -f "$ac_dir/POTFILES"
- test -n "$as_me" && echo "$as_me: creating $ac_dir/POTFILES" || echo "creating $ac_dir/POTFILES"
- cat "$ac_given_srcdir/$ac_dir/POTFILES.in" | sed -e "/^#/d" -e "/^[ ]*\$/d" -e "s,.*, $top_srcdir/& \\\\," | sed -e "\$s/\(.*\) \\\\/\1/" > "$ac_dir/POTFILES"
- POMAKEFILEDEPS="POTFILES.in"
- # ALL_LINGUAS, POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES depend
- # on $ac_dir but don't depend on user-specified configuration
- # parameters.
- if test -f "$ac_given_srcdir/$ac_dir/LINGUAS"; then
- # The LINGUAS file contains the set of available languages.
- if test -n "$OBSOLETE_ALL_LINGUAS"; then
- test -n "$as_me" && echo "$as_me: setting ALL_LINGUAS in configure.ac is obsolete" || echo "setting ALL_LINGUAS in configure.ac is obsolete"
- fi
- ALL_LINGUAS_=`sed -e "/^#/d" "$ac_given_srcdir/$ac_dir/LINGUAS"`
- # Hide the ALL_LINGUAS assigment from automake.
- eval 'ALL_LINGUAS''=$ALL_LINGUAS_'
- POMAKEFILEDEPS="$POMAKEFILEDEPS LINGUAS"
- else
- # The set of available languages was given in configure.ac.
- eval 'ALL_LINGUAS''=$OBSOLETE_ALL_LINGUAS'
- fi
- case "$ac_given_srcdir" in
- .) srcdirpre= ;;
- *) srcdirpre='$(srcdir)/' ;;
- esac
- POFILES=
- GMOFILES=
- UPDATEPOFILES=
- DUMMYPOFILES=
- for lang in $ALL_LINGUAS; do
- POFILES="$POFILES $srcdirpre$lang.po"
- GMOFILES="$GMOFILES $srcdirpre$lang.gmo"
- UPDATEPOFILES="$UPDATEPOFILES $lang.po-update"
- DUMMYPOFILES="$DUMMYPOFILES $lang.nop"
- done
- # CATALOGS depends on both $ac_dir and the user's LINGUAS
- # environment variable.
- INST_LINGUAS=
- if test -n "$ALL_LINGUAS"; then
- for presentlang in $ALL_LINGUAS; do
- useit=no
- if test "%UNSET%" != "$LINGUAS"; then
- desiredlanguages="$LINGUAS"
- else
- desiredlanguages="$ALL_LINGUAS"
- fi
- for desiredlang in $desiredlanguages; do
- # Use the presentlang catalog if desiredlang is
- # a. equal to presentlang, or
- # b. a variant of presentlang (because in this case,
- # presentlang can be used as a fallback for messages
- # which are not translated in the desiredlang catalog).
- case "$desiredlang" in
- "$presentlang"*) useit=yes;;
- esac
- done
- if test $useit = yes; then
- INST_LINGUAS="$INST_LINGUAS $presentlang"
- fi
- done
- fi
- CATALOGS=
- if test -n "$INST_LINGUAS"; then
- for lang in $INST_LINGUAS; do
- CATALOGS="$CATALOGS $lang.gmo"
- done
- fi
- test -n "$as_me" && echo "$as_me: creating $ac_dir/Makefile" || echo "creating $ac_dir/Makefile"
- sed -e "/^POTFILES =/r $ac_dir/POTFILES" -e "/^# Makevars/r $ac_given_srcdir/$ac_dir/Makevars" -e "s|@POFILES@|$POFILES|g" -e "s|@GMOFILES@|$GMOFILES|g" -e "s|@UPDATEPOFILES@|$UPDATEPOFILES|g" -e "s|@DUMMYPOFILES@|$DUMMYPOFILES|g" -e "s|@CATALOGS@|$CATALOGS|g" -e "s|@POMAKEFILEDEPS@|$POMAKEFILEDEPS|g" "$ac_dir/Makefile.in" > "$ac_dir/Makefile"
- for f in "$ac_given_srcdir/$ac_dir"/Rules-*; do
- if test -f "$f"; then
- case "$f" in
- *.orig | *.bak | *~) ;;
- *) cat "$f" >> "$ac_dir/Makefile" ;;
- esac
- fi
- done
- fi
- ;;
- esac
- done ;;
-
- esac
-done # for ac_tag
-
-
-as_fn_exit 0
-_ACEOF
-ac_clean_files=$ac_clean_files_save
-
-test $ac_write_fail = 0 ||
- as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
-
-
-# configure is writing to config.log, and then calls config.status.
-# config.status does its own redirection, appending to config.log.
-# Unfortunately, on DOS this fails, as config.log is still kept open
-# by configure, so config.status won't be able to write to it; its
-# output is simply discarded. So we exec the FD to /dev/null,
-# effectively closing config.log, so it can be properly (re)opened and
-# appended to by config.status. When coming back to configure, we
-# need to make the FD available again.
-if test "$no_create" != yes; then
- ac_cs_success=:
- ac_config_status_args=
- test "$silent" = yes &&
- ac_config_status_args="$ac_config_status_args --quiet"
- exec 5>/dev/null
- $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
- exec 5>>config.log
- # Use ||, not &&, to avoid exiting from the if with $? = 1, which
- # would make configure fail if this is the last instruction.
- $ac_cs_success || as_fn_exit 1
-fi
-if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
-$as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
-fi
-
-
-
-touch config.status.tmp
-if touch --reference=config.status config.status.tmp > /dev/null 2>&1; then
- sed '/as_fn_exit 0/i \
-sed -e \"s/^\t\\\(\\\$(AM_V_CCLD)\\\)/\t+ \\\1/\" Makefile > Makefile.tmp \
-touch --reference=Makefile Makefile.tmp \
-mv Makefile.tmp Makefile \
-' config.status > config.status.tmp
- touch --reference=config.status config.status.tmp
- mv config.status.tmp config.status
- chmod +x config.status
- sed -e "s/^\t\(\$(AM_V_CCLD)\)/\t+ \1/" Makefile > Makefile.tmp
- touch --reference=Makefile Makefile.tmp
- mv Makefile.tmp Makefile
-else
- rm -f config.status.tmp
-fi
Property changes on: sources/GNU/binutils/create-2.43.1-libtool-lib64-patch/binutils-2.43.1-new/binutils/configure
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: sources/GNU/binutils/create-2.43.1-libtool-lib64-patch/binutils-2.43.1-new/gprof/configure
===================================================================
--- sources/GNU/binutils/create-2.43.1-libtool-lib64-patch/binutils-2.43.1-new/gprof/configure (revision 75)
+++ sources/GNU/binutils/create-2.43.1-libtool-lib64-patch/binutils-2.43.1-new/gprof/configure (nonexistent)
@@ -1,16597 +0,0 @@
-#! /bin/sh
-# Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.69 for gprof 2.43.1.
-#
-#
-# Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc.
-#
-#
-# This configure script is free software; the Free Software Foundation
-# gives unlimited permission to copy, distribute and modify it.
-## -------------------- ##
-## M4sh Initialization. ##
-## -------------------- ##
-
-# Be more Bourne compatible
-DUALCASE=1; export DUALCASE # for MKS sh
-if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
- emulate sh
- NULLCMD=:
- # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
- # is contrary to our usage. Disable this feature.
- alias -g '${1+"$@"}'='"$@"'
- setopt NO_GLOB_SUBST
-else
- case `(set -o) 2>/dev/null` in #(
- *posix*) :
- set -o posix ;; #(
- *) :
- ;;
-esac
-fi
-
-
-as_nl='
-'
-export as_nl
-# Printing a long string crashes Solaris 7 /usr/bin/printf.
-as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
-as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
-as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
-# Prefer a ksh shell builtin over an external printf program on Solaris,
-# but without wasting forks for bash or zsh.
-if test -z "$BASH_VERSION$ZSH_VERSION" \
- && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
- as_echo='print -r --'
- as_echo_n='print -rn --'
-elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
- as_echo='printf %s\n'
- as_echo_n='printf %s'
-else
- if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
- as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
- as_echo_n='/usr/ucb/echo -n'
- else
- as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
- as_echo_n_body='eval
- arg=$1;
- case $arg in #(
- *"$as_nl"*)
- expr "X$arg" : "X\\(.*\\)$as_nl";
- arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
- esac;
- expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
- '
- export as_echo_n_body
- as_echo_n='sh -c $as_echo_n_body as_echo'
- fi
- export as_echo_body
- as_echo='sh -c $as_echo_body as_echo'
-fi
-
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- PATH_SEPARATOR=:
- (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
- (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
- PATH_SEPARATOR=';'
- }
-fi
-
-
-# IFS
-# We need space, tab and new line, in precisely that order. Quoting is
-# there to prevent editors from complaining about space-tab.
-# (If _AS_PATH_WALK were called with IFS unset, it would disable word
-# splitting by setting IFS to empty value.)
-IFS=" "" $as_nl"
-
-# Find who we are. Look in the path if we contain no directory separator.
-as_myself=
-case $0 in #((
- *[\\/]* ) as_myself=$0 ;;
- *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
- done
-IFS=$as_save_IFS
-
- ;;
-esac
-# We did not find ourselves, most probably we were run as `sh COMMAND'
-# in which case we are not to be found in the path.
-if test "x$as_myself" = x; then
- as_myself=$0
-fi
-if test ! -f "$as_myself"; then
- $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
- exit 1
-fi
-
-# Unset variables that we do not need and which cause bugs (e.g. in
-# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
-# suppresses any "Segmentation fault" message there. '((' could
-# trigger a bug in pdksh 5.2.14.
-for as_var in BASH_ENV ENV MAIL MAILPATH
-do eval test x\${$as_var+set} = xset \
- && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
-done
-PS1='$ '
-PS2='> '
-PS4='+ '
-
-# NLS nuisances.
-LC_ALL=C
-export LC_ALL
-LANGUAGE=C
-export LANGUAGE
-
-# CDPATH.
-(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
-
-# Use a proper internal environment variable to ensure we don't fall
- # into an infinite loop, continuously re-executing ourselves.
- if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then
- _as_can_reexec=no; export _as_can_reexec;
- # We cannot yet assume a decent shell, so we have to provide a
-# neutralization value for shells without unset; and this also
-# works around shells that cannot unset nonexistent variables.
-# Preserve -v and -x to the replacement shell.
-BASH_ENV=/dev/null
-ENV=/dev/null
-(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
-case $- in # ((((
- *v*x* | *x*v* ) as_opts=-vx ;;
- *v* ) as_opts=-v ;;
- *x* ) as_opts=-x ;;
- * ) as_opts= ;;
-esac
-exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
-# Admittedly, this is quite paranoid, since all the known shells bail
-# out after a failed `exec'.
-$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
-as_fn_exit 255
- fi
- # We don't want this to propagate to other subprocesses.
- { _as_can_reexec=; unset _as_can_reexec;}
-if test "x$CONFIG_SHELL" = x; then
- as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
- emulate sh
- NULLCMD=:
- # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
- # is contrary to our usage. Disable this feature.
- alias -g '\${1+\"\$@\"}'='\"\$@\"'
- setopt NO_GLOB_SUBST
-else
- case \`(set -o) 2>/dev/null\` in #(
- *posix*) :
- set -o posix ;; #(
- *) :
- ;;
-esac
-fi
-"
- as_required="as_fn_return () { (exit \$1); }
-as_fn_success () { as_fn_return 0; }
-as_fn_failure () { as_fn_return 1; }
-as_fn_ret_success () { return 0; }
-as_fn_ret_failure () { return 1; }
-
-exitcode=0
-as_fn_success || { exitcode=1; echo as_fn_success failed.; }
-as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
-as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
-as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
-if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
-
-else
- exitcode=1; echo positional parameters were not saved.
-fi
-test x\$exitcode = x0 || exit 1
-test -x / || exit 1"
- as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
- as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
- eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
- test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
-test \$(( 1 + 1 )) = 2 || exit 1
-
- test -n \"\${ZSH_VERSION+set}\${BASH_VERSION+set}\" || (
- ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
- ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO
- ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO
- PATH=/empty FPATH=/empty; export PATH FPATH
- test \"X\`printf %s \$ECHO\`\" = \"X\$ECHO\" \\
- || test \"X\`print -r -- \$ECHO\`\" = \"X\$ECHO\" ) || exit 1"
- if (eval "$as_required") 2>/dev/null; then :
- as_have_required=yes
-else
- as_have_required=no
-fi
- if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
-
-else
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-as_found=false
-for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- as_found=:
- case $as_dir in #(
- /*)
- for as_base in sh bash ksh sh5; do
- # Try only shells that exist, to save several forks.
- as_shell=$as_dir/$as_base
- if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
- { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
- CONFIG_SHELL=$as_shell as_have_required=yes
- if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
- break 2
-fi
-fi
- done;;
- esac
- as_found=false
-done
-$as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
- { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
- CONFIG_SHELL=$SHELL as_have_required=yes
-fi; }
-IFS=$as_save_IFS
-
-
- if test "x$CONFIG_SHELL" != x; then :
- export CONFIG_SHELL
- # We cannot yet assume a decent shell, so we have to provide a
-# neutralization value for shells without unset; and this also
-# works around shells that cannot unset nonexistent variables.
-# Preserve -v and -x to the replacement shell.
-BASH_ENV=/dev/null
-ENV=/dev/null
-(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
-case $- in # ((((
- *v*x* | *x*v* ) as_opts=-vx ;;
- *v* ) as_opts=-v ;;
- *x* ) as_opts=-x ;;
- * ) as_opts= ;;
-esac
-exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
-# Admittedly, this is quite paranoid, since all the known shells bail
-# out after a failed `exec'.
-$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
-exit 255
-fi
-
- if test x$as_have_required = xno; then :
- $as_echo "$0: This script requires a shell more modern than all"
- $as_echo "$0: the shells that I found on your system."
- if test x${ZSH_VERSION+set} = xset ; then
- $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
- $as_echo "$0: be upgraded to zsh 4.3.4 or later."
- else
- $as_echo "$0: Please tell bug-autoconf@gnu.org about your system,
-$0: including any error possibly output before this
-$0: message. Then install a modern shell, or manually run
-$0: the script under such a shell if you do have one."
- fi
- exit 1
-fi
-fi
-fi
-SHELL=${CONFIG_SHELL-/bin/sh}
-export SHELL
-# Unset more variables known to interfere with behavior of common tools.
-CLICOLOR_FORCE= GREP_OPTIONS=
-unset CLICOLOR_FORCE GREP_OPTIONS
-
-## --------------------- ##
-## M4sh Shell Functions. ##
-## --------------------- ##
-# as_fn_unset VAR
-# ---------------
-# Portably unset VAR.
-as_fn_unset ()
-{
- { eval $1=; unset $1;}
-}
-as_unset=as_fn_unset
-
-# as_fn_set_status STATUS
-# -----------------------
-# Set $? to STATUS, without forking.
-as_fn_set_status ()
-{
- return $1
-} # as_fn_set_status
-
-# as_fn_exit STATUS
-# -----------------
-# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
-as_fn_exit ()
-{
- set +e
- as_fn_set_status $1
- exit $1
-} # as_fn_exit
-
-# as_fn_mkdir_p
-# -------------
-# Create "$as_dir" as a directory, including parents if necessary.
-as_fn_mkdir_p ()
-{
-
- case $as_dir in #(
- -*) as_dir=./$as_dir;;
- esac
- test -d "$as_dir" || eval $as_mkdir_p || {
- as_dirs=
- while :; do
- case $as_dir in #(
- *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
- *) as_qdir=$as_dir;;
- esac
- as_dirs="'$as_qdir' $as_dirs"
- as_dir=`$as_dirname -- "$as_dir" ||
-$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$as_dir" : 'X\(//\)[^/]' \| \
- X"$as_dir" : 'X\(//\)$' \| \
- X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$as_dir" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
- test -d "$as_dir" && break
- done
- test -z "$as_dirs" || eval "mkdir $as_dirs"
- } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
-
-
-} # as_fn_mkdir_p
-
-# as_fn_executable_p FILE
-# -----------------------
-# Test if FILE is an executable regular file.
-as_fn_executable_p ()
-{
- test -f "$1" && test -x "$1"
-} # as_fn_executable_p
-# as_fn_append VAR VALUE
-# ----------------------
-# Append the text in VALUE to the end of the definition contained in VAR. Take
-# advantage of any shell optimizations that allow amortized linear growth over
-# repeated appends, instead of the typical quadratic growth present in naive
-# implementations.
-if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
- eval 'as_fn_append ()
- {
- eval $1+=\$2
- }'
-else
- as_fn_append ()
- {
- eval $1=\$$1\$2
- }
-fi # as_fn_append
-
-# as_fn_arith ARG...
-# ------------------
-# Perform arithmetic evaluation on the ARGs, and store the result in the
-# global $as_val. Take advantage of shells that can avoid forks. The arguments
-# must be portable across $(()) and expr.
-if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
- eval 'as_fn_arith ()
- {
- as_val=$(( $* ))
- }'
-else
- as_fn_arith ()
- {
- as_val=`expr "$@" || test $? -eq 1`
- }
-fi # as_fn_arith
-
-
-# as_fn_error STATUS ERROR [LINENO LOG_FD]
-# ----------------------------------------
-# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
-# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
-# script with STATUS, using 1 if that was 0.
-as_fn_error ()
-{
- as_status=$1; test $as_status -eq 0 && as_status=1
- if test "$4"; then
- as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
- fi
- $as_echo "$as_me: error: $2" >&2
- as_fn_exit $as_status
-} # as_fn_error
-
-if expr a : '\(a\)' >/dev/null 2>&1 &&
- test "X`expr 00001 : '.*\(...\)'`" = X001; then
- as_expr=expr
-else
- as_expr=false
-fi
-
-if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
- as_basename=basename
-else
- as_basename=false
-fi
-
-if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
- as_dirname=dirname
-else
- as_dirname=false
-fi
-
-as_me=`$as_basename -- "$0" ||
-$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
- X"$0" : 'X\(//\)$' \| \
- X"$0" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X/"$0" |
- sed '/^.*\/\([^/][^/]*\)\/*$/{
- s//\1/
- q
- }
- /^X\/\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\/\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
-
-# Avoid depending upon Character Ranges.
-as_cr_letters='abcdefghijklmnopqrstuvwxyz'
-as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
-as_cr_Letters=$as_cr_letters$as_cr_LETTERS
-as_cr_digits='0123456789'
-as_cr_alnum=$as_cr_Letters$as_cr_digits
-
-
- as_lineno_1=$LINENO as_lineno_1a=$LINENO
- as_lineno_2=$LINENO as_lineno_2a=$LINENO
- eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
- test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
- # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-)
- sed -n '
- p
- /[$]LINENO/=
- ' <$as_myself |
- sed '
- s/[$]LINENO.*/&-/
- t lineno
- b
- :lineno
- N
- :loop
- s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
- t loop
- s/-\n.*//
- ' >$as_me.lineno &&
- chmod +x "$as_me.lineno" ||
- { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
-
- # If we had to re-execute with $CONFIG_SHELL, we're ensured to have
- # already done that, so ensure we don't try to do so again and fall
- # in an infinite loop. This has already happened in practice.
- _as_can_reexec=no; export _as_can_reexec
- # Don't try to exec as it changes $[0], causing all sort of problems
- # (the dirname of $[0] is not the place where we might find the
- # original and so on. Autoconf is especially sensitive to this).
- . "./$as_me.lineno"
- # Exit status is that of the last command.
- exit
-}
-
-ECHO_C= ECHO_N= ECHO_T=
-case `echo -n x` in #(((((
--n*)
- case `echo 'xy\c'` in
- *c*) ECHO_T=' ';; # ECHO_T is single tab character.
- xy) ECHO_C='\c';;
- *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
- ECHO_T=' ';;
- esac;;
-*)
- ECHO_N='-n';;
-esac
-
-rm -f conf$$ conf$$.exe conf$$.file
-if test -d conf$$.dir; then
- rm -f conf$$.dir/conf$$.file
-else
- rm -f conf$$.dir
- mkdir conf$$.dir 2>/dev/null
-fi
-if (echo >conf$$.file) 2>/dev/null; then
- if ln -s conf$$.file conf$$ 2>/dev/null; then
- as_ln_s='ln -s'
- # ... but there are two gotchas:
- # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
- # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
- # In both cases, we have to default to `cp -pR'.
- ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
- as_ln_s='cp -pR'
- elif ln conf$$.file conf$$ 2>/dev/null; then
- as_ln_s=ln
- else
- as_ln_s='cp -pR'
- fi
-else
- as_ln_s='cp -pR'
-fi
-rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
-rmdir conf$$.dir 2>/dev/null
-
-if mkdir -p . 2>/dev/null; then
- as_mkdir_p='mkdir -p "$as_dir"'
-else
- test -d ./-p && rmdir ./-p
- as_mkdir_p=false
-fi
-
-as_test_x='test -x'
-as_executable_p=as_fn_executable_p
-
-# Sed expression to map a string onto a valid CPP name.
-as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
-
-# Sed expression to map a string onto a valid variable name.
-as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
-
-SHELL=${CONFIG_SHELL-/bin/sh}
-
-
-test -n "$DJDIR" || exec 7<&0 </dev/null
-exec 6>&1
-
-# Name of the host.
-# hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status,
-# so uname gets run too.
-ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
-
-#
-# Initializations.
-#
-ac_default_prefix=/usr/local
-ac_clean_files=
-ac_config_libobj_dir=.
-LIBOBJS=
-cross_compiling=no
-subdirs=
-MFLAGS=
-MAKEFLAGS=
-
-# Identity of this package.
-PACKAGE_NAME='gprof'
-PACKAGE_TARNAME='gprof'
-PACKAGE_VERSION='2.43.1'
-PACKAGE_STRING='gprof 2.43.1'
-PACKAGE_BUGREPORT=''
-PACKAGE_URL=''
-
-ac_unique_file="gprof.c"
-# Factoring default headers for most tests.
-ac_includes_default="\
-#include <stdio.h>
-#ifdef HAVE_SYS_TYPES_H
-# include <sys/types.h>
-#endif
-#ifdef HAVE_SYS_STAT_H
-# include <sys/stat.h>
-#endif
-#ifdef STDC_HEADERS
-# include <stdlib.h>
-# include <stddef.h>
-#else
-# ifdef HAVE_STDLIB_H
-# include <stdlib.h>
-# endif
-#endif
-#ifdef HAVE_STRING_H
-# if !defined STDC_HEADERS && defined HAVE_MEMORY_H
-# include <memory.h>
-# endif
-# include <string.h>
-#endif
-#ifdef HAVE_STRINGS_H
-# include <strings.h>
-#endif
-#ifdef HAVE_INTTYPES_H
-# include <inttypes.h>
-#endif
-#ifdef HAVE_STDINT_H
-# include <stdint.h>
-#endif
-#ifdef HAVE_UNISTD_H
-# include <unistd.h>
-#endif"
-
-gt_needs=
-ac_subst_vars='am__EXEEXT_FALSE
-am__EXEEXT_TRUE
-LTLIBOBJS
-LIBOBJS
-WARN_WRITE_STRINGS
-NO_WERROR
-WARN_CFLAGS_FOR_BUILD
-WARN_CFLAGS
-GENINSRC_NEVER_FALSE
-GENINSRC_NEVER_TRUE
-MAINT
-MAINTAINER_MODE_FALSE
-MAINTAINER_MODE_TRUE
-CATOBJEXT
-GENCAT
-INSTOBJEXT
-DATADIRNAME
-CATALOGS
-INCINTL
-LIBINTL_DEP
-POSUB
-LTLIBINTL
-LIBINTL
-INTLLIBS
-LTLIBICONV
-LIBICONV
-INTL_MACOSX_LIBS
-MSGMERGE
-XGETTEXT
-GMSGFMT
-MSGFMT
-USE_NLS
-MKINSTALLDIRS
-LARGEFILE_CPPFLAGS
-OTOOL64
-OTOOL
-LIPO
-NMEDIT
-DSYMUTIL
-RANLIB
-AR
-OBJDUMP
-LN_S
-NM
-ac_ct_DUMPBIN
-DUMPBIN
-LD
-FGREP
-SED
-LIBTOOL
-EGREP
-GREP
-CPP
-am__fastdepCC_FALSE
-am__fastdepCC_TRUE
-CCDEPMODE
-am__nodep
-AMDEPBACKSLASH
-AMDEP_FALSE
-AMDEP_TRUE
-am__quote
-am__include
-DEPDIR
-OBJEXT
-EXEEXT
-ac_ct_CC
-CPPFLAGS
-LDFLAGS
-CFLAGS
-CC
-AM_BACKSLASH
-AM_DEFAULT_VERBOSITY
-AM_DEFAULT_V
-AM_V
-am__untar
-am__tar
-AMTAR
-am__leading_dot
-SET_MAKE
-AWK
-mkdir_p
-MKDIR_P
-INSTALL_STRIP_PROGRAM
-STRIP
-install_sh
-MAKEINFO
-AUTOHEADER
-AUTOMAKE
-AUTOCONF
-ACLOCAL
-VERSION
-PACKAGE
-CYGPATH_W
-am__isrc
-INSTALL_DATA
-INSTALL_SCRIPT
-INSTALL_PROGRAM
-target_os
-target_vendor
-target_cpu
-target
-host_os
-host_vendor
-host_cpu
-host
-build_os
-build_vendor
-build_cpu
-build
-target_alias
-host_alias
-build_alias
-LIBS
-ECHO_T
-ECHO_N
-ECHO_C
-DEFS
-mandir
-localedir
-libdir
-psdir
-pdfdir
-dvidir
-htmldir
-infodir
-docdir
-oldincludedir
-includedir
-localstatedir
-sharedstatedir
-sysconfdir
-datadir
-datarootdir
-libexecdir
-sbindir
-bindir
-program_transform_name
-prefix
-exec_prefix
-PACKAGE_URL
-PACKAGE_BUGREPORT
-PACKAGE_STRING
-PACKAGE_VERSION
-PACKAGE_TARNAME
-PACKAGE_NAME
-PATH_SEPARATOR
-SHELL'
-ac_subst_files=''
-ac_user_opts='
-enable_option_checking
-enable_silent_rules
-enable_dependency_tracking
-enable_shared
-enable_static
-with_pic
-enable_fast_install
-with_gnu_ld
-enable_libtool_lock
-enable_plugins
-enable_largefile
-enable_nls
-enable_rpath
-with_libiconv_prefix
-with_libiconv_type
-with_libintl_prefix
-with_libintl_type
-enable_maintainer_mode
-enable_werror
-enable_build_warnings
-'
- ac_precious_vars='build_alias
-host_alias
-target_alias
-CC
-CFLAGS
-LDFLAGS
-LIBS
-CPPFLAGS
-CPP'
-
-
-# Initialize some variables set by options.
-ac_init_help=
-ac_init_version=false
-ac_unrecognized_opts=
-ac_unrecognized_sep=
-# The variables have the same names as the options, with
-# dashes changed to underlines.
-cache_file=/dev/null
-exec_prefix=NONE
-no_create=
-no_recursion=
-prefix=NONE
-program_prefix=NONE
-program_suffix=NONE
-program_transform_name=s,x,x,
-silent=
-site=
-srcdir=
-verbose=
-x_includes=NONE
-x_libraries=NONE
-
-# Installation directory options.
-# These are left unexpanded so users can "make install exec_prefix=/foo"
-# and all the variables that are supposed to be based on exec_prefix
-# by default will actually change.
-# Use braces instead of parens because sh, perl, etc. also accept them.
-# (The list follows the same order as the GNU Coding Standards.)
-bindir='${exec_prefix}/bin'
-sbindir='${exec_prefix}/sbin'
-libexecdir='${exec_prefix}/libexec'
-datarootdir='${prefix}/share'
-datadir='${datarootdir}'
-sysconfdir='${prefix}/etc'
-sharedstatedir='${prefix}/com'
-localstatedir='${prefix}/var'
-includedir='${prefix}/include'
-oldincludedir='/usr/include'
-docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
-infodir='${datarootdir}/info'
-htmldir='${docdir}'
-dvidir='${docdir}'
-pdfdir='${docdir}'
-psdir='${docdir}'
-libdir='${exec_prefix}/lib'
-localedir='${datarootdir}/locale'
-mandir='${datarootdir}/man'
-
-ac_prev=
-ac_dashdash=
-for ac_option
-do
- # If the previous option needs an argument, assign it.
- if test -n "$ac_prev"; then
- eval $ac_prev=\$ac_option
- ac_prev=
- continue
- fi
-
- case $ac_option in
- *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
- *=) ac_optarg= ;;
- *) ac_optarg=yes ;;
- esac
-
- # Accept the important Cygnus configure options, so we can diagnose typos.
-
- case $ac_dashdash$ac_option in
- --)
- ac_dashdash=yes ;;
-
- -bindir | --bindir | --bindi | --bind | --bin | --bi)
- ac_prev=bindir ;;
- -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
- bindir=$ac_optarg ;;
-
- -build | --build | --buil | --bui | --bu)
- ac_prev=build_alias ;;
- -build=* | --build=* | --buil=* | --bui=* | --bu=*)
- build_alias=$ac_optarg ;;
-
- -cache-file | --cache-file | --cache-fil | --cache-fi \
- | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
- ac_prev=cache_file ;;
- -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
- | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
- cache_file=$ac_optarg ;;
-
- --config-cache | -C)
- cache_file=config.cache ;;
-
- -datadir | --datadir | --datadi | --datad)
- ac_prev=datadir ;;
- -datadir=* | --datadir=* | --datadi=* | --datad=*)
- datadir=$ac_optarg ;;
-
- -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
- | --dataroo | --dataro | --datar)
- ac_prev=datarootdir ;;
- -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
- | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
- datarootdir=$ac_optarg ;;
-
- -disable-* | --disable-*)
- ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
- # Reject names that are not valid shell variable names.
- expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
- as_fn_error $? "invalid feature name: $ac_useropt"
- ac_useropt_orig=$ac_useropt
- ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
- case $ac_user_opts in
- *"
-"enable_$ac_useropt"
-"*) ;;
- *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
- ac_unrecognized_sep=', ';;
- esac
- eval enable_$ac_useropt=no ;;
-
- -docdir | --docdir | --docdi | --doc | --do)
- ac_prev=docdir ;;
- -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
- docdir=$ac_optarg ;;
-
- -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
- ac_prev=dvidir ;;
- -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
- dvidir=$ac_optarg ;;
-
- -enable-* | --enable-*)
- ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
- # Reject names that are not valid shell variable names.
- expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
- as_fn_error $? "invalid feature name: $ac_useropt"
- ac_useropt_orig=$ac_useropt
- ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
- case $ac_user_opts in
- *"
-"enable_$ac_useropt"
-"*) ;;
- *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
- ac_unrecognized_sep=', ';;
- esac
- eval enable_$ac_useropt=\$ac_optarg ;;
-
- -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
- | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
- | --exec | --exe | --ex)
- ac_prev=exec_prefix ;;
- -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
- | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
- | --exec=* | --exe=* | --ex=*)
- exec_prefix=$ac_optarg ;;
-
- -gas | --gas | --ga | --g)
- # Obsolete; use --with-gas.
- with_gas=yes ;;
-
- -help | --help | --hel | --he | -h)
- ac_init_help=long ;;
- -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
- ac_init_help=recursive ;;
- -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
- ac_init_help=short ;;
-
- -host | --host | --hos | --ho)
- ac_prev=host_alias ;;
- -host=* | --host=* | --hos=* | --ho=*)
- host_alias=$ac_optarg ;;
-
- -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
- ac_prev=htmldir ;;
- -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
- | --ht=*)
- htmldir=$ac_optarg ;;
-
- -includedir | --includedir | --includedi | --included | --include \
- | --includ | --inclu | --incl | --inc)
- ac_prev=includedir ;;
- -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
- | --includ=* | --inclu=* | --incl=* | --inc=*)
- includedir=$ac_optarg ;;
-
- -infodir | --infodir | --infodi | --infod | --info | --inf)
- ac_prev=infodir ;;
- -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
- infodir=$ac_optarg ;;
-
- -libdir | --libdir | --libdi | --libd)
- ac_prev=libdir ;;
- -libdir=* | --libdir=* | --libdi=* | --libd=*)
- libdir=$ac_optarg ;;
-
- -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
- | --libexe | --libex | --libe)
- ac_prev=libexecdir ;;
- -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
- | --libexe=* | --libex=* | --libe=*)
- libexecdir=$ac_optarg ;;
-
- -localedir | --localedir | --localedi | --localed | --locale)
- ac_prev=localedir ;;
- -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
- localedir=$ac_optarg ;;
-
- -localstatedir | --localstatedir | --localstatedi | --localstated \
- | --localstate | --localstat | --localsta | --localst | --locals)
- ac_prev=localstatedir ;;
- -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
- | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
- localstatedir=$ac_optarg ;;
-
- -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
- ac_prev=mandir ;;
- -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
- mandir=$ac_optarg ;;
-
- -nfp | --nfp | --nf)
- # Obsolete; use --without-fp.
- with_fp=no ;;
-
- -no-create | --no-create | --no-creat | --no-crea | --no-cre \
- | --no-cr | --no-c | -n)
- no_create=yes ;;
-
- -no-recursion | --no-recursion | --no-recursio | --no-recursi \
- | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
- no_recursion=yes ;;
-
- -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
- | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
- | --oldin | --oldi | --old | --ol | --o)
- ac_prev=oldincludedir ;;
- -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
- | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
- | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
- oldincludedir=$ac_optarg ;;
-
- -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
- ac_prev=prefix ;;
- -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
- prefix=$ac_optarg ;;
-
- -program-prefix | --program-prefix | --program-prefi | --program-pref \
- | --program-pre | --program-pr | --program-p)
- ac_prev=program_prefix ;;
- -program-prefix=* | --program-prefix=* | --program-prefi=* \
- | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
- program_prefix=$ac_optarg ;;
-
- -program-suffix | --program-suffix | --program-suffi | --program-suff \
- | --program-suf | --program-su | --program-s)
- ac_prev=program_suffix ;;
- -program-suffix=* | --program-suffix=* | --program-suffi=* \
- | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
- program_suffix=$ac_optarg ;;
-
- -program-transform-name | --program-transform-name \
- | --program-transform-nam | --program-transform-na \
- | --program-transform-n | --program-transform- \
- | --program-transform | --program-transfor \
- | --program-transfo | --program-transf \
- | --program-trans | --program-tran \
- | --progr-tra | --program-tr | --program-t)
- ac_prev=program_transform_name ;;
- -program-transform-name=* | --program-transform-name=* \
- | --program-transform-nam=* | --program-transform-na=* \
- | --program-transform-n=* | --program-transform-=* \
- | --program-transform=* | --program-transfor=* \
- | --program-transfo=* | --program-transf=* \
- | --program-trans=* | --program-tran=* \
- | --progr-tra=* | --program-tr=* | --program-t=*)
- program_transform_name=$ac_optarg ;;
-
- -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
- ac_prev=pdfdir ;;
- -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
- pdfdir=$ac_optarg ;;
-
- -psdir | --psdir | --psdi | --psd | --ps)
- ac_prev=psdir ;;
- -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
- psdir=$ac_optarg ;;
-
- -q | -quiet | --quiet | --quie | --qui | --qu | --q \
- | -silent | --silent | --silen | --sile | --sil)
- silent=yes ;;
-
- -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
- ac_prev=sbindir ;;
- -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
- | --sbi=* | --sb=*)
- sbindir=$ac_optarg ;;
-
- -sharedstatedir | --sharedstatedir | --sharedstatedi \
- | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
- | --sharedst | --shareds | --shared | --share | --shar \
- | --sha | --sh)
- ac_prev=sharedstatedir ;;
- -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
- | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
- | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
- | --sha=* | --sh=*)
- sharedstatedir=$ac_optarg ;;
-
- -site | --site | --sit)
- ac_prev=site ;;
- -site=* | --site=* | --sit=*)
- site=$ac_optarg ;;
-
- -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
- ac_prev=srcdir ;;
- -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
- srcdir=$ac_optarg ;;
-
- -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
- | --syscon | --sysco | --sysc | --sys | --sy)
- ac_prev=sysconfdir ;;
- -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
- | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
- sysconfdir=$ac_optarg ;;
-
- -target | --target | --targe | --targ | --tar | --ta | --t)
- ac_prev=target_alias ;;
- -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
- target_alias=$ac_optarg ;;
-
- -v | -verbose | --verbose | --verbos | --verbo | --verb)
- verbose=yes ;;
-
- -version | --version | --versio | --versi | --vers | -V)
- ac_init_version=: ;;
-
- -with-* | --with-*)
- ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
- # Reject names that are not valid shell variable names.
- expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
- as_fn_error $? "invalid package name: $ac_useropt"
- ac_useropt_orig=$ac_useropt
- ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
- case $ac_user_opts in
- *"
-"with_$ac_useropt"
-"*) ;;
- *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
- ac_unrecognized_sep=', ';;
- esac
- eval with_$ac_useropt=\$ac_optarg ;;
-
- -without-* | --without-*)
- ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
- # Reject names that are not valid shell variable names.
- expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
- as_fn_error $? "invalid package name: $ac_useropt"
- ac_useropt_orig=$ac_useropt
- ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
- case $ac_user_opts in
- *"
-"with_$ac_useropt"
-"*) ;;
- *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
- ac_unrecognized_sep=', ';;
- esac
- eval with_$ac_useropt=no ;;
-
- --x)
- # Obsolete; use --with-x.
- with_x=yes ;;
-
- -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
- | --x-incl | --x-inc | --x-in | --x-i)
- ac_prev=x_includes ;;
- -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
- | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
- x_includes=$ac_optarg ;;
-
- -x-libraries | --x-libraries | --x-librarie | --x-librari \
- | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
- ac_prev=x_libraries ;;
- -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
- | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
- x_libraries=$ac_optarg ;;
-
- -*) as_fn_error $? "unrecognized option: \`$ac_option'
-Try \`$0 --help' for more information"
- ;;
-
- *=*)
- ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
- # Reject names that are not valid shell variable names.
- case $ac_envvar in #(
- '' | [0-9]* | *[!_$as_cr_alnum]* )
- as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
- esac
- eval $ac_envvar=\$ac_optarg
- export $ac_envvar ;;
-
- *)
- # FIXME: should be removed in autoconf 3.0.
- $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
- expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
- $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
- : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
- ;;
-
- esac
-done
-
-if test -n "$ac_prev"; then
- ac_option=--`echo $ac_prev | sed 's/_/-/g'`
- as_fn_error $? "missing argument to $ac_option"
-fi
-
-if test -n "$ac_unrecognized_opts"; then
- case $enable_option_checking in
- no) ;;
- fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
- *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
- esac
-fi
-
-# Check all directory arguments for consistency.
-for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
- datadir sysconfdir sharedstatedir localstatedir includedir \
- oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
- libdir localedir mandir
-do
- eval ac_val=\$$ac_var
- # Remove trailing slashes.
- case $ac_val in
- */ )
- ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
- eval $ac_var=\$ac_val;;
- esac
- # Be sure to have absolute directory names.
- case $ac_val in
- [\\/$]* | ?:[\\/]* ) continue;;
- NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
- esac
- as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
-done
-
-# There might be people who depend on the old broken behavior: `$host'
-# used to hold the argument of --host etc.
-# FIXME: To remove some day.
-build=$build_alias
-host=$host_alias
-target=$target_alias
-
-# FIXME: To remove some day.
-if test "x$host_alias" != x; then
- if test "x$build_alias" = x; then
- cross_compiling=maybe
- elif test "x$build_alias" != "x$host_alias"; then
- cross_compiling=yes
- fi
-fi
-
-ac_tool_prefix=
-test -n "$host_alias" && ac_tool_prefix=$host_alias-
-
-test "$silent" = yes && exec 6>/dev/null
-
-
-ac_pwd=`pwd` && test -n "$ac_pwd" &&
-ac_ls_di=`ls -di .` &&
-ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
- as_fn_error $? "working directory cannot be determined"
-test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
- as_fn_error $? "pwd does not report name of working directory"
-
-
-# Find the source files, if location was not specified.
-if test -z "$srcdir"; then
- ac_srcdir_defaulted=yes
- # Try the directory containing this script, then the parent directory.
- ac_confdir=`$as_dirname -- "$as_myself" ||
-$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$as_myself" : 'X\(//\)[^/]' \| \
- X"$as_myself" : 'X\(//\)$' \| \
- X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$as_myself" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
- srcdir=$ac_confdir
- if test ! -r "$srcdir/$ac_unique_file"; then
- srcdir=..
- fi
-else
- ac_srcdir_defaulted=no
-fi
-if test ! -r "$srcdir/$ac_unique_file"; then
- test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
- as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
-fi
-ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
-ac_abs_confdir=`(
- cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
- pwd)`
-# When building in place, set srcdir=.
-if test "$ac_abs_confdir" = "$ac_pwd"; then
- srcdir=.
-fi
-# Remove unnecessary trailing slashes from srcdir.
-# Double slashes in file names in object file debugging info
-# mess up M-x gdb in Emacs.
-case $srcdir in
-*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
-esac
-for ac_var in $ac_precious_vars; do
- eval ac_env_${ac_var}_set=\${${ac_var}+set}
- eval ac_env_${ac_var}_value=\$${ac_var}
- eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
- eval ac_cv_env_${ac_var}_value=\$${ac_var}
-done
-
-#
-# Report the --help message.
-#
-if test "$ac_init_help" = "long"; then
- # Omit some internal or obsolete options to make the list less imposing.
- # This message is too long to be a string in the A/UX 3.1 sh.
- cat <<_ACEOF
-\`configure' configures gprof 2.43.1 to adapt to many kinds of systems.
-
-Usage: $0 [OPTION]... [VAR=VALUE]...
-
-To assign environment variables (e.g., CC, CFLAGS...), specify them as
-VAR=VALUE. See below for descriptions of some of the useful variables.
-
-Defaults for the options are specified in brackets.
-
-Configuration:
- -h, --help display this help and exit
- --help=short display options specific to this package
- --help=recursive display the short help of all the included packages
- -V, --version display version information and exit
- -q, --quiet, --silent do not print \`checking ...' messages
- --cache-file=FILE cache test results in FILE [disabled]
- -C, --config-cache alias for \`--cache-file=config.cache'
- -n, --no-create do not create output files
- --srcdir=DIR find the sources in DIR [configure dir or \`..']
-
-Installation directories:
- --prefix=PREFIX install architecture-independent files in PREFIX
- [$ac_default_prefix]
- --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
- [PREFIX]
-
-By default, \`make install' will install all the files in
-\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
-an installation prefix other than \`$ac_default_prefix' using \`--prefix',
-for instance \`--prefix=\$HOME'.
-
-For better control, use the options below.
-
-Fine tuning of the installation directories:
- --bindir=DIR user executables [EPREFIX/bin]
- --sbindir=DIR system admin executables [EPREFIX/sbin]
- --libexecdir=DIR program executables [EPREFIX/libexec]
- --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
- --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
- --localstatedir=DIR modifiable single-machine data [PREFIX/var]
- --libdir=DIR object code libraries [EPREFIX/lib]
- --includedir=DIR C header files [PREFIX/include]
- --oldincludedir=DIR C header files for non-gcc [/usr/include]
- --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
- --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
- --infodir=DIR info documentation [DATAROOTDIR/info]
- --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
- --mandir=DIR man documentation [DATAROOTDIR/man]
- --docdir=DIR documentation root [DATAROOTDIR/doc/gprof]
- --htmldir=DIR html documentation [DOCDIR]
- --dvidir=DIR dvi documentation [DOCDIR]
- --pdfdir=DIR pdf documentation [DOCDIR]
- --psdir=DIR ps documentation [DOCDIR]
-_ACEOF
-
- cat <<\_ACEOF
-
-Program names:
- --program-prefix=PREFIX prepend PREFIX to installed program names
- --program-suffix=SUFFIX append SUFFIX to installed program names
- --program-transform-name=PROGRAM run sed PROGRAM on installed program names
-
-System types:
- --build=BUILD configure for building on BUILD [guessed]
- --host=HOST cross-compile to build programs to run on HOST [BUILD]
- --target=TARGET configure for building compilers for TARGET [HOST]
-_ACEOF
-fi
-
-if test -n "$ac_init_help"; then
- case $ac_init_help in
- short | recursive ) echo "Configuration of gprof 2.43.1:";;
- esac
- cat <<\_ACEOF
-
-Optional Features:
- --disable-option-checking ignore unrecognized --enable/--with options
- --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
- --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
- --enable-silent-rules less verbose build output (undo: "make V=1")
- --disable-silent-rules verbose build output (undo: "make V=0")
- --enable-dependency-tracking
- do not reject slow dependency extractors
- --disable-dependency-tracking
- speeds up one-time build
- --enable-shared[=PKGS] build shared libraries [default=yes]
- --enable-static[=PKGS] build static libraries [default=yes]
- --enable-fast-install[=PKGS]
- optimize for fast installation [default=yes]
- --disable-libtool-lock avoid locking (might break parallel builds)
- --enable-plugins Enable support for plugins
- --disable-largefile omit support for large files
- --disable-nls do not use Native Language Support
- --disable-rpath do not hardcode runtime library paths
- --enable-maintainer-mode
- enable make rules and dependencies not useful (and
- sometimes confusing) to the casual installer
- --enable-werror treat compile warnings as errors
- --enable-build-warnings enable build-time compiler warnings
-
-Optional Packages:
- --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
- --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
- --with-pic try to use only PIC/non-PIC objects [default=use
- both]
- --with-gnu-ld assume the C compiler uses GNU ld [default=no]
- --with-gnu-ld assume the C compiler uses GNU ld default=no
- --with-libiconv-prefix[=DIR] search for libiconv in DIR/include and DIR/lib
- --without-libiconv-prefix don't search for libiconv in includedir and libdir
- --with-libiconv-type=TYPE type of library to search for (auto/static/shared)
- --with-libintl-prefix[=DIR] search for libintl in DIR/include and DIR/lib
- --without-libintl-prefix don't search for libintl in includedir and libdir
- --with-libintl-type=TYPE type of library to search for (auto/static/shared)
-
-Some influential environment variables:
- CC C compiler command
- CFLAGS C compiler flags
- LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
- nonstandard directory <lib dir>
- LIBS libraries to pass to the linker, e.g. -l<library>
- CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
- you have headers in a nonstandard directory <include dir>
- CPP C preprocessor
-
-Use these variables to override the choices made by `configure' or to help
-it to find libraries and programs with nonstandard names/locations.
-
-Report bugs to the package provider.
-_ACEOF
-ac_status=$?
-fi
-
-if test "$ac_init_help" = "recursive"; then
- # If there are subdirs, report their specific --help.
- for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
- test -d "$ac_dir" ||
- { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
- continue
- ac_builddir=.
-
-case "$ac_dir" in
-.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
-*)
- ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
- # A ".." for each directory in $ac_dir_suffix.
- ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
- case $ac_top_builddir_sub in
- "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
- *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
- esac ;;
-esac
-ac_abs_top_builddir=$ac_pwd
-ac_abs_builddir=$ac_pwd$ac_dir_suffix
-# for backward compatibility:
-ac_top_builddir=$ac_top_build_prefix
-
-case $srcdir in
- .) # We are building in place.
- ac_srcdir=.
- ac_top_srcdir=$ac_top_builddir_sub
- ac_abs_top_srcdir=$ac_pwd ;;
- [\\/]* | ?:[\\/]* ) # Absolute name.
- ac_srcdir=$srcdir$ac_dir_suffix;
- ac_top_srcdir=$srcdir
- ac_abs_top_srcdir=$srcdir ;;
- *) # Relative name.
- ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
- ac_top_srcdir=$ac_top_build_prefix$srcdir
- ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
-esac
-ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
-
- cd "$ac_dir" || { ac_status=$?; continue; }
- # Check for guested configure.
- if test -f "$ac_srcdir/configure.gnu"; then
- echo &&
- $SHELL "$ac_srcdir/configure.gnu" --help=recursive
- elif test -f "$ac_srcdir/configure"; then
- echo &&
- $SHELL "$ac_srcdir/configure" --help=recursive
- else
- $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
- fi || ac_status=$?
- cd "$ac_pwd" || { ac_status=$?; break; }
- done
-fi
-
-test -n "$ac_init_help" && exit $ac_status
-if $ac_init_version; then
- cat <<\_ACEOF
-gprof configure 2.43.1
-generated by GNU Autoconf 2.69
-
-Copyright (C) 2012 Free Software Foundation, Inc.
-This configure script is free software; the Free Software Foundation
-gives unlimited permission to copy, distribute and modify it.
-_ACEOF
- exit
-fi
-
-## ------------------------ ##
-## Autoconf initialization. ##
-## ------------------------ ##
-
-# ac_fn_c_try_compile LINENO
-# --------------------------
-# Try to compile conftest.$ac_ext, and return whether this succeeded.
-ac_fn_c_try_compile ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- rm -f conftest.$ac_objext
- if { { ac_try="$ac_compile"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_compile") 2>conftest.err
- ac_status=$?
- if test -s conftest.err; then
- grep -v '^ *+' conftest.err >conftest.er1
- cat conftest.er1 >&5
- mv -f conftest.er1 conftest.err
- fi
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && {
- test -z "$ac_c_werror_flag" ||
- test ! -s conftest.err
- } && test -s conftest.$ac_objext; then :
- ac_retval=0
-else
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
- ac_retval=1
-fi
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
- as_fn_set_status $ac_retval
-
-} # ac_fn_c_try_compile
-
-# ac_fn_c_try_cpp LINENO
-# ----------------------
-# Try to preprocess conftest.$ac_ext, and return whether this succeeded.
-ac_fn_c_try_cpp ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- if { { ac_try="$ac_cpp conftest.$ac_ext"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
- ac_status=$?
- if test -s conftest.err; then
- grep -v '^ *+' conftest.err >conftest.er1
- cat conftest.er1 >&5
- mv -f conftest.er1 conftest.err
- fi
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } > conftest.i && {
- test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
- test ! -s conftest.err
- }; then :
- ac_retval=0
-else
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
- ac_retval=1
-fi
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
- as_fn_set_status $ac_retval
-
-} # ac_fn_c_try_cpp
-
-# ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
-# -------------------------------------------------------
-# Tests whether HEADER exists, giving a warning if it cannot be compiled using
-# the include files in INCLUDES and setting the cache variable VAR
-# accordingly.
-ac_fn_c_check_header_mongrel ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- if eval \${$3+:} false; then :
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
-$as_echo_n "checking for $2... " >&6; }
-if eval \${$3+:} false; then :
- $as_echo_n "(cached) " >&6
-fi
-eval ac_res=\$$3
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
-else
- # Is the header compilable?
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
-$as_echo_n "checking $2 usability... " >&6; }
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$4
-#include <$2>
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_header_compiler=yes
-else
- ac_header_compiler=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
-$as_echo "$ac_header_compiler" >&6; }
-
-# Is the header present?
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
-$as_echo_n "checking $2 presence... " >&6; }
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <$2>
-_ACEOF
-if ac_fn_c_try_cpp "$LINENO"; then :
- ac_header_preproc=yes
-else
- ac_header_preproc=no
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
-$as_echo "$ac_header_preproc" >&6; }
-
-# So? What about this header?
-case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
- yes:no: )
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
-$as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
-$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
- ;;
- no:yes:* )
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
-$as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
-$as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
-$as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
-$as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
-$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
- ;;
-esac
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
-$as_echo_n "checking for $2... " >&6; }
-if eval \${$3+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- eval "$3=\$ac_header_compiler"
-fi
-eval ac_res=\$$3
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
-fi
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
-
-} # ac_fn_c_check_header_mongrel
-
-# ac_fn_c_try_run LINENO
-# ----------------------
-# Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
-# that executables *can* be run.
-ac_fn_c_try_run ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- if { { ac_try="$ac_link"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_link") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
- { { case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_try") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; }; then :
- ac_retval=0
-else
- $as_echo "$as_me: program exited with status $ac_status" >&5
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
- ac_retval=$ac_status
-fi
- rm -rf conftest.dSYM conftest_ipa8_conftest.oo
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
- as_fn_set_status $ac_retval
-
-} # ac_fn_c_try_run
-
-# ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
-# -------------------------------------------------------
-# Tests whether HEADER exists and can be compiled using the include files in
-# INCLUDES, setting the cache variable VAR accordingly.
-ac_fn_c_check_header_compile ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
-$as_echo_n "checking for $2... " >&6; }
-if eval \${$3+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$4
-#include <$2>
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- eval "$3=yes"
-else
- eval "$3=no"
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-eval ac_res=\$$3
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
-
-} # ac_fn_c_check_header_compile
-
-# ac_fn_c_try_link LINENO
-# -----------------------
-# Try to link conftest.$ac_ext, and return whether this succeeded.
-ac_fn_c_try_link ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- rm -f conftest.$ac_objext conftest$ac_exeext
- if { { ac_try="$ac_link"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_link") 2>conftest.err
- ac_status=$?
- if test -s conftest.err; then
- grep -v '^ *+' conftest.err >conftest.er1
- cat conftest.er1 >&5
- mv -f conftest.er1 conftest.err
- fi
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && {
- test -z "$ac_c_werror_flag" ||
- test ! -s conftest.err
- } && test -s conftest$ac_exeext && {
- test "$cross_compiling" = yes ||
- test -x conftest$ac_exeext
- }; then :
- ac_retval=0
-else
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
- ac_retval=1
-fi
- # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
- # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
- # interfere with the next link command; also delete a directory that is
- # left behind by Apple's compiler. We do this before executing the actions.
- rm -rf conftest.dSYM conftest_ipa8_conftest.oo
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
- as_fn_set_status $ac_retval
-
-} # ac_fn_c_try_link
-
-# ac_fn_c_check_func LINENO FUNC VAR
-# ----------------------------------
-# Tests whether FUNC exists, setting the cache variable VAR accordingly
-ac_fn_c_check_func ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
-$as_echo_n "checking for $2... " >&6; }
-if eval \${$3+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-/* Define $2 to an innocuous variant, in case <limits.h> declares $2.
- For example, HP-UX 11i <limits.h> declares gettimeofday. */
-#define $2 innocuous_$2
-
-/* System header to define __stub macros and hopefully few prototypes,
- which can conflict with char $2 (); below.
- Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
- <limits.h> exists even on freestanding compilers. */
-
-#ifdef __STDC__
-# include <limits.h>
-#else
-# include <assert.h>
-#endif
-
-#undef $2
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char $2 ();
-/* The GNU C library defines this for functions which it implements
- to always fail with ENOSYS. Some functions are actually named
- something starting with __ and the normal name is an alias. */
-#if defined __stub_$2 || defined __stub___$2
-choke me
-#endif
-
-int
-main ()
-{
-return $2 ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- eval "$3=yes"
-else
- eval "$3=no"
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-fi
-eval ac_res=\$$3
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
-
-} # ac_fn_c_check_func
-cat >config.log <<_ACEOF
-This file contains any messages produced by compilers while
-running configure, to aid debugging if configure makes a mistake.
-
-It was created by gprof $as_me 2.43.1, which was
-generated by GNU Autoconf 2.69. Invocation command line was
-
- $ $0 $@
-
-_ACEOF
-exec 5>>config.log
-{
-cat <<_ASUNAME
-## --------- ##
-## Platform. ##
-## --------- ##
-
-hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
-uname -m = `(uname -m) 2>/dev/null || echo unknown`
-uname -r = `(uname -r) 2>/dev/null || echo unknown`
-uname -s = `(uname -s) 2>/dev/null || echo unknown`
-uname -v = `(uname -v) 2>/dev/null || echo unknown`
-
-/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
-/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
-
-/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
-/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
-/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
-/usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
-/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
-/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
-/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
-
-_ASUNAME
-
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- $as_echo "PATH: $as_dir"
- done
-IFS=$as_save_IFS
-
-} >&5
-
-cat >&5 <<_ACEOF
-
-
-## ----------- ##
-## Core tests. ##
-## ----------- ##
-
-_ACEOF
-
-
-# Keep a trace of the command line.
-# Strip out --no-create and --no-recursion so they do not pile up.
-# Strip out --silent because we don't want to record it for future runs.
-# Also quote any args containing shell meta-characters.
-# Make two passes to allow for proper duplicate-argument suppression.
-ac_configure_args=
-ac_configure_args0=
-ac_configure_args1=
-ac_must_keep_next=false
-for ac_pass in 1 2
-do
- for ac_arg
- do
- case $ac_arg in
- -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
- -q | -quiet | --quiet | --quie | --qui | --qu | --q \
- | -silent | --silent | --silen | --sile | --sil)
- continue ;;
- *\'*)
- ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
- esac
- case $ac_pass in
- 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
- 2)
- as_fn_append ac_configure_args1 " '$ac_arg'"
- if test $ac_must_keep_next = true; then
- ac_must_keep_next=false # Got value, back to normal.
- else
- case $ac_arg in
- *=* | --config-cache | -C | -disable-* | --disable-* \
- | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
- | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
- | -with-* | --with-* | -without-* | --without-* | --x)
- case "$ac_configure_args0 " in
- "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
- esac
- ;;
- -* ) ac_must_keep_next=true ;;
- esac
- fi
- as_fn_append ac_configure_args " '$ac_arg'"
- ;;
- esac
- done
-done
-{ ac_configure_args0=; unset ac_configure_args0;}
-{ ac_configure_args1=; unset ac_configure_args1;}
-
-# When interrupted or exit'd, cleanup temporary files, and complete
-# config.log. We remove comments because anyway the quotes in there
-# would cause problems or look ugly.
-# WARNING: Use '\'' to represent an apostrophe within the trap.
-# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
-trap 'exit_status=$?
- # Save into config.log some information that might help in debugging.
- {
- echo
-
- $as_echo "## ---------------- ##
-## Cache variables. ##
-## ---------------- ##"
- echo
- # The following way of writing the cache mishandles newlines in values,
-(
- for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
- eval ac_val=\$$ac_var
- case $ac_val in #(
- *${as_nl}*)
- case $ac_var in #(
- *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
-$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
- esac
- case $ac_var in #(
- _ | IFS | as_nl) ;; #(
- BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
- *) { eval $ac_var=; unset $ac_var;} ;;
- esac ;;
- esac
- done
- (set) 2>&1 |
- case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
- *${as_nl}ac_space=\ *)
- sed -n \
- "s/'\''/'\''\\\\'\'''\''/g;
- s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
- ;; #(
- *)
- sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
- ;;
- esac |
- sort
-)
- echo
-
- $as_echo "## ----------------- ##
-## Output variables. ##
-## ----------------- ##"
- echo
- for ac_var in $ac_subst_vars
- do
- eval ac_val=\$$ac_var
- case $ac_val in
- *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
- esac
- $as_echo "$ac_var='\''$ac_val'\''"
- done | sort
- echo
-
- if test -n "$ac_subst_files"; then
- $as_echo "## ------------------- ##
-## File substitutions. ##
-## ------------------- ##"
- echo
- for ac_var in $ac_subst_files
- do
- eval ac_val=\$$ac_var
- case $ac_val in
- *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
- esac
- $as_echo "$ac_var='\''$ac_val'\''"
- done | sort
- echo
- fi
-
- if test -s confdefs.h; then
- $as_echo "## ----------- ##
-## confdefs.h. ##
-## ----------- ##"
- echo
- cat confdefs.h
- echo
- fi
- test "$ac_signal" != 0 &&
- $as_echo "$as_me: caught signal $ac_signal"
- $as_echo "$as_me: exit $exit_status"
- } >&5
- rm -f core *.core core.conftest.* &&
- rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
- exit $exit_status
-' 0
-for ac_signal in 1 2 13 15; do
- trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
-done
-ac_signal=0
-
-# confdefs.h avoids OS command line length limits that DEFS can exceed.
-rm -f -r conftest* confdefs.h
-
-$as_echo "/* confdefs.h */" > confdefs.h
-
-# Predefined preprocessor variables.
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_NAME "$PACKAGE_NAME"
-_ACEOF
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
-_ACEOF
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_VERSION "$PACKAGE_VERSION"
-_ACEOF
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_STRING "$PACKAGE_STRING"
-_ACEOF
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
-_ACEOF
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_URL "$PACKAGE_URL"
-_ACEOF
-
-
-# Let the site file select an alternate cache file if it wants to.
-# Prefer an explicitly selected file to automatically selected ones.
-ac_site_file1=NONE
-ac_site_file2=NONE
-if test -n "$CONFIG_SITE"; then
- # We do not want a PATH search for config.site.
- case $CONFIG_SITE in #((
- -*) ac_site_file1=./$CONFIG_SITE;;
- */*) ac_site_file1=$CONFIG_SITE;;
- *) ac_site_file1=./$CONFIG_SITE;;
- esac
-elif test "x$prefix" != xNONE; then
- ac_site_file1=$prefix/share/config.site
- ac_site_file2=$prefix/etc/config.site
-else
- ac_site_file1=$ac_default_prefix/share/config.site
- ac_site_file2=$ac_default_prefix/etc/config.site
-fi
-for ac_site_file in "$ac_site_file1" "$ac_site_file2"
-do
- test "x$ac_site_file" = xNONE && continue
- if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
-$as_echo "$as_me: loading site script $ac_site_file" >&6;}
- sed 's/^/| /' "$ac_site_file" >&5
- . "$ac_site_file" \
- || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "failed to load site script $ac_site_file
-See \`config.log' for more details" "$LINENO" 5; }
- fi
-done
-
-if test -r "$cache_file"; then
- # Some versions of bash will fail to source /dev/null (special files
- # actually), so we avoid doing that. DJGPP emulates it as a regular file.
- if test /dev/null != "$cache_file" && test -f "$cache_file"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
-$as_echo "$as_me: loading cache $cache_file" >&6;}
- case $cache_file in
- [\\/]* | ?:[\\/]* ) . "$cache_file";;
- *) . "./$cache_file";;
- esac
- fi
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
-$as_echo "$as_me: creating cache $cache_file" >&6;}
- >$cache_file
-fi
-
-gt_needs="$gt_needs "
-# Check that the precious variables saved in the cache have kept the same
-# value.
-ac_cache_corrupted=false
-for ac_var in $ac_precious_vars; do
- eval ac_old_set=\$ac_cv_env_${ac_var}_set
- eval ac_new_set=\$ac_env_${ac_var}_set
- eval ac_old_val=\$ac_cv_env_${ac_var}_value
- eval ac_new_val=\$ac_env_${ac_var}_value
- case $ac_old_set,$ac_new_set in
- set,)
- { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
-$as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
- ac_cache_corrupted=: ;;
- ,set)
- { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
-$as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
- ac_cache_corrupted=: ;;
- ,);;
- *)
- if test "x$ac_old_val" != "x$ac_new_val"; then
- # differences in whitespace do not lead to failure.
- ac_old_val_w=`echo x $ac_old_val`
- ac_new_val_w=`echo x $ac_new_val`
- if test "$ac_old_val_w" != "$ac_new_val_w"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
-$as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
- ac_cache_corrupted=:
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
-$as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
- eval $ac_var=\$ac_old_val
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
-$as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
-$as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
- fi;;
- esac
- # Pass precious variables to config.status.
- if test "$ac_new_set" = set; then
- case $ac_new_val in
- *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
- *) ac_arg=$ac_var=$ac_new_val ;;
- esac
- case " $ac_configure_args " in
- *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
- *) as_fn_append ac_configure_args " '$ac_arg'" ;;
- esac
- fi
-done
-if $ac_cache_corrupted; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
-$as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
- as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
-fi
-## -------------------- ##
-## Main body of script. ##
-## -------------------- ##
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-
-
-
-
-
-
-ac_aux_dir=
-for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
- if test -f "$ac_dir/install-sh"; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install-sh -c"
- break
- elif test -f "$ac_dir/install.sh"; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install.sh -c"
- break
- elif test -f "$ac_dir/shtool"; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/shtool install -c"
- break
- fi
-done
-if test -z "$ac_aux_dir"; then
- as_fn_error $? "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5
-fi
-
-# These three variables are undocumented and unsupported,
-# and are intended to be withdrawn in a future Autoconf release.
-# They can cause serious problems if a builder's source tree is in a directory
-# whose full name contains unusual characters.
-ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
-ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
-ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
-
-
-# Make sure we can run config.sub.
-$SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
- as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
-$as_echo_n "checking build system type... " >&6; }
-if ${ac_cv_build+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_build_alias=$build_alias
-test "x$ac_build_alias" = x &&
- ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
-test "x$ac_build_alias" = x &&
- as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
-ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
- as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
-$as_echo "$ac_cv_build" >&6; }
-case $ac_cv_build in
-*-*-*) ;;
-*) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
-esac
-build=$ac_cv_build
-ac_save_IFS=$IFS; IFS='-'
-set x $ac_cv_build
-shift
-build_cpu=$1
-build_vendor=$2
-shift; shift
-# Remember, the first character of IFS is used to create $*,
-# except with old shells:
-build_os=$*
-IFS=$ac_save_IFS
-case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
-$as_echo_n "checking host system type... " >&6; }
-if ${ac_cv_host+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test "x$host_alias" = x; then
- ac_cv_host=$ac_cv_build
-else
- ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
- as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
-$as_echo "$ac_cv_host" >&6; }
-case $ac_cv_host in
-*-*-*) ;;
-*) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
-esac
-host=$ac_cv_host
-ac_save_IFS=$IFS; IFS='-'
-set x $ac_cv_host
-shift
-host_cpu=$1
-host_vendor=$2
-shift; shift
-# Remember, the first character of IFS is used to create $*,
-# except with old shells:
-host_os=$*
-IFS=$ac_save_IFS
-case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking target system type" >&5
-$as_echo_n "checking target system type... " >&6; }
-if ${ac_cv_target+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test "x$target_alias" = x; then
- ac_cv_target=$ac_cv_host
-else
- ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` ||
- as_fn_error $? "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5
-$as_echo "$ac_cv_target" >&6; }
-case $ac_cv_target in
-*-*-*) ;;
-*) as_fn_error $? "invalid value of canonical target" "$LINENO" 5;;
-esac
-target=$ac_cv_target
-ac_save_IFS=$IFS; IFS='-'
-set x $ac_cv_target
-shift
-target_cpu=$1
-target_vendor=$2
-shift; shift
-# Remember, the first character of IFS is used to create $*,
-# except with old shells:
-target_os=$*
-IFS=$ac_save_IFS
-case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac
-
-
-# The aliases save the names the user supplied, while $host etc.
-# will get canonicalized.
-test -n "$target_alias" &&
- test "$program_prefix$program_suffix$program_transform_name" = \
- NONENONEs,x,x, &&
- program_prefix=${target_alias}-
-
-am__api_version='1.15'
-
-# Find a good install program. We prefer a C program (faster),
-# so one script is as good as another. But avoid the broken or
-# incompatible versions:
-# SysV /etc/install, /usr/sbin/install
-# SunOS /usr/etc/install
-# IRIX /sbin/install
-# AIX /bin/install
-# AmigaOS /C/install, which installs bootblocks on floppy discs
-# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
-# AFS /usr/afsws/bin/install, which mishandles nonexistent args
-# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
-# OS/2's system install, which has a completely different semantic
-# ./install, which can be erroneously created by make from ./install.sh.
-# Reject install programs that cannot install multiple files.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
-$as_echo_n "checking for a BSD-compatible install... " >&6; }
-if test -z "$INSTALL"; then
-if ${ac_cv_path_install+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- # Account for people who put trailing slashes in PATH elements.
-case $as_dir/ in #((
- ./ | .// | /[cC]/* | \
- /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
- ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
- /usr/ucb/* ) ;;
- *)
- # OSF1 and SCO ODT 3.0 have their own names for install.
- # Don't use installbsd from OSF since it installs stuff as root
- # by default.
- for ac_prog in ginstall scoinst install; do
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
- if test $ac_prog = install &&
- grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
- # AIX install. It has an incompatible calling convention.
- :
- elif test $ac_prog = install &&
- grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
- # program-specific install script used by HP pwplus--don't use.
- :
- else
- rm -rf conftest.one conftest.two conftest.dir
- echo one > conftest.one
- echo two > conftest.two
- mkdir conftest.dir
- if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
- test -s conftest.one && test -s conftest.two &&
- test -s conftest.dir/conftest.one &&
- test -s conftest.dir/conftest.two
- then
- ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
- break 3
- fi
- fi
- fi
- done
- done
- ;;
-esac
-
- done
-IFS=$as_save_IFS
-
-rm -rf conftest.one conftest.two conftest.dir
-
-fi
- if test "${ac_cv_path_install+set}" = set; then
- INSTALL=$ac_cv_path_install
- else
- # As a last resort, use the slow shell script. Don't cache a
- # value for INSTALL within a source directory, because that will
- # break other packages using the cache if that directory is
- # removed, or if the value is a relative name.
- INSTALL=$ac_install_sh
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
-$as_echo "$INSTALL" >&6; }
-
-# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
-# It thinks the first close brace ends the variable substitution.
-test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
-
-test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
-
-test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5
-$as_echo_n "checking whether build environment is sane... " >&6; }
-# Reject unsafe characters in $srcdir or the absolute working directory
-# name. Accept space and tab only in the latter.
-am_lf='
-'
-case `pwd` in
- *[\\\"\#\$\&\'\`$am_lf]*)
- as_fn_error $? "unsafe absolute working directory name" "$LINENO" 5;;
-esac
-case $srcdir in
- *[\\\"\#\$\&\'\`$am_lf\ \ ]*)
- as_fn_error $? "unsafe srcdir value: '$srcdir'" "$LINENO" 5;;
-esac
-
-# Do 'set' in a subshell so we don't clobber the current shell's
-# arguments. Must try -L first in case configure is actually a
-# symlink; some systems play weird games with the mod time of symlinks
-# (eg FreeBSD returns the mod time of the symlink's containing
-# directory).
-if (
- am_has_slept=no
- for am_try in 1 2; do
- echo "timestamp, slept: $am_has_slept" > conftest.file
- set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
- if test "$*" = "X"; then
- # -L didn't work.
- set X `ls -t "$srcdir/configure" conftest.file`
- fi
- if test "$*" != "X $srcdir/configure conftest.file" \
- && test "$*" != "X conftest.file $srcdir/configure"; then
-
- # If neither matched, then we have a broken ls. This can happen
- # if, for instance, CONFIG_SHELL is bash and it inherits a
- # broken ls alias from the environment. This has actually
- # happened. Such a system could not be considered "sane".
- as_fn_error $? "ls -t appears to fail. Make sure there is not a broken
- alias in your environment" "$LINENO" 5
- fi
- if test "$2" = conftest.file || test $am_try -eq 2; then
- break
- fi
- # Just in case.
- sleep 1
- am_has_slept=yes
- done
- test "$2" = conftest.file
- )
-then
- # Ok.
- :
-else
- as_fn_error $? "newly created file is older than distributed files!
-Check your system clock" "$LINENO" 5
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-# If we didn't sleep, we still need to ensure time stamps of config.status and
-# generated files are strictly newer.
-am_sleep_pid=
-if grep 'slept: no' conftest.file >/dev/null 2>&1; then
- ( sleep 1 ) &
- am_sleep_pid=$!
-fi
-
-rm -f conftest.file
-
-test "$program_prefix" != NONE &&
- program_transform_name="s&^&$program_prefix&;$program_transform_name"
-# Use a double $ so make ignores it.
-test "$program_suffix" != NONE &&
- program_transform_name="s&\$&$program_suffix&;$program_transform_name"
-# Double any \ or $.
-# By default was `s,x,x', remove it if useless.
-ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
-program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
-
-# Expand $ac_aux_dir to an absolute path.
-am_aux_dir=`cd "$ac_aux_dir" && pwd`
-
-if test x"${MISSING+set}" != xset; then
- case $am_aux_dir in
- *\ * | *\ *)
- MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
- *)
- MISSING="\${SHELL} $am_aux_dir/missing" ;;
- esac
-fi
-# Use eval to expand $SHELL
-if eval "$MISSING --is-lightweight"; then
- am_missing_run="$MISSING "
-else
- am_missing_run=
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: 'missing' script is too old or missing" >&5
-$as_echo "$as_me: WARNING: 'missing' script is too old or missing" >&2;}
-fi
-
-if test x"${install_sh+set}" != xset; then
- case $am_aux_dir in
- *\ * | *\ *)
- install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
- *)
- install_sh="\${SHELL} $am_aux_dir/install-sh"
- esac
-fi
-
-# Installed binaries are usually stripped using 'strip' when the user
-# run "make install-strip". However 'strip' might not be the right
-# tool to use in cross-compilation environments, therefore Automake
-# will honor the 'STRIP' environment variable to overrule this program.
-if test "$cross_compiling" != no; then
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
-set dummy ${ac_tool_prefix}strip; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_STRIP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$STRIP"; then
- ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_STRIP="${ac_tool_prefix}strip"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-STRIP=$ac_cv_prog_STRIP
-if test -n "$STRIP"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
-$as_echo "$STRIP" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_STRIP"; then
- ac_ct_STRIP=$STRIP
- # Extract the first word of "strip", so it can be a program name with args.
-set dummy strip; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_STRIP"; then
- ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_STRIP="strip"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
-if test -n "$ac_ct_STRIP"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
-$as_echo "$ac_ct_STRIP" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_STRIP" = x; then
- STRIP=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- STRIP=$ac_ct_STRIP
- fi
-else
- STRIP="$ac_cv_prog_STRIP"
-fi
-
-fi
-INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5
-$as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
-if test -z "$MKDIR_P"; then
- if ${ac_cv_path_mkdir+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_prog in mkdir gmkdir; do
- for ac_exec_ext in '' $ac_executable_extensions; do
- as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext" || continue
- case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
- 'mkdir (GNU coreutils) '* | \
- 'mkdir (coreutils) '* | \
- 'mkdir (fileutils) '4.1*)
- ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
- break 3;;
- esac
- done
- done
- done
-IFS=$as_save_IFS
-
-fi
-
- test -d ./--version && rmdir ./--version
- if test "${ac_cv_path_mkdir+set}" = set; then
- MKDIR_P="$ac_cv_path_mkdir -p"
- else
- # As a last resort, use the slow shell script. Don't cache a
- # value for MKDIR_P within a source directory, because that will
- # break other packages using the cache if that directory is
- # removed, or if the value is a relative name.
- MKDIR_P="$ac_install_sh -d"
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
-$as_echo "$MKDIR_P" >&6; }
-
-for ac_prog in gawk mawk nawk awk
-do
- # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_AWK+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$AWK"; then
- ac_cv_prog_AWK="$AWK" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_AWK="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-AWK=$ac_cv_prog_AWK
-if test -n "$AWK"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
-$as_echo "$AWK" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$AWK" && break
-done
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
-$as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
-set x ${MAKE-make}
-ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
-if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat >conftest.make <<\_ACEOF
-SHELL = /bin/sh
-all:
- @echo '@@@%%%=$(MAKE)=@@@%%%'
-_ACEOF
-# GNU make sometimes prints "make[1]: Entering ...", which would confuse us.
-case `${MAKE-make} -f conftest.make 2>/dev/null` in
- *@@@%%%=?*=@@@%%%*)
- eval ac_cv_prog_make_${ac_make}_set=yes;;
- *)
- eval ac_cv_prog_make_${ac_make}_set=no;;
-esac
-rm -f conftest.make
-fi
-if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- SET_MAKE=
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- SET_MAKE="MAKE=${MAKE-make}"
-fi
-
-rm -rf .tst 2>/dev/null
-mkdir .tst 2>/dev/null
-if test -d .tst; then
- am__leading_dot=.
-else
- am__leading_dot=_
-fi
-rmdir .tst 2>/dev/null
-
-# Check whether --enable-silent-rules was given.
-if test "${enable_silent_rules+set}" = set; then :
- enableval=$enable_silent_rules;
-fi
-
-case $enable_silent_rules in # (((
- yes) AM_DEFAULT_VERBOSITY=0;;
- no) AM_DEFAULT_VERBOSITY=1;;
- *) AM_DEFAULT_VERBOSITY=1;;
-esac
-am_make=${MAKE-make}
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5
-$as_echo_n "checking whether $am_make supports nested variables... " >&6; }
-if ${am_cv_make_support_nested_variables+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if $as_echo 'TRUE=$(BAR$(V))
-BAR0=false
-BAR1=true
-V=1
-am__doit:
- @$(TRUE)
-.PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then
- am_cv_make_support_nested_variables=yes
-else
- am_cv_make_support_nested_variables=no
-fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5
-$as_echo "$am_cv_make_support_nested_variables" >&6; }
-if test $am_cv_make_support_nested_variables = yes; then
- AM_V='$(V)'
- AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
-else
- AM_V=$AM_DEFAULT_VERBOSITY
- AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY
-fi
-AM_BACKSLASH='\'
-
-if test "`cd $srcdir && pwd`" != "`pwd`"; then
- # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
- # is not polluted with repeated "-I."
- am__isrc=' -I$(srcdir)'
- # test to see if srcdir already configured
- if test -f $srcdir/config.status; then
- as_fn_error $? "source directory already configured; run \"make distclean\" there first" "$LINENO" 5
- fi
-fi
-
-# test whether we have cygpath
-if test -z "$CYGPATH_W"; then
- if (cygpath --version) >/dev/null 2>/dev/null; then
- CYGPATH_W='cygpath -w'
- else
- CYGPATH_W=echo
- fi
-fi
-
-
-# Define the identity of the package.
- PACKAGE='gprof'
- VERSION='2.43.1'
-
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE "$PACKAGE"
-_ACEOF
-
-
-cat >>confdefs.h <<_ACEOF
-#define VERSION "$VERSION"
-_ACEOF
-
-# Some tools Automake needs.
-
-ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"}
-
-
-AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
-
-
-AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"}
-
-
-AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
-
-
-MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
-
-# For better backward compatibility. To be removed once Automake 1.9.x
-# dies out for good. For more background, see:
-# <http://lists.gnu.org/archive/html/automake/2012-07/msg00001.html>
-# <http://lists.gnu.org/archive/html/automake/2012-07/msg00014.html>
-mkdir_p='$(MKDIR_P)'
-
-# We need awk for the "check" target (and possibly the TAP driver). The
-# system "awk" is bad on some platforms.
-# Always define AMTAR for backward compatibility. Yes, it's still used
-# in the wild :-( We should find a proper way to deprecate it ...
-AMTAR='$${TAR-tar}'
-
-
-# We'll loop over all known methods to create a tar archive until one works.
-_am_tools='gnutar pax cpio none'
-
-am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -'
-
-
-
-
-
-
-# POSIX will say in a future version that running "rm -f" with no argument
-# is OK; and we want to be able to make that assumption in our Makefile
-# recipes. So use an aggressive probe to check that the usage we want is
-# actually supported "in the wild" to an acceptable degree.
-# See automake bug#10828.
-# To make any issue more visible, cause the running configure to be aborted
-# by default if the 'rm' program in use doesn't match our expectations; the
-# user can still override this though.
-if rm -f && rm -fr && rm -rf; then : OK; else
- cat >&2 <<'END'
-Oops!
-
-Your 'rm' program seems unable to run without file operands specified
-on the command line, even when the '-f' option is present. This is contrary
-to the behaviour of most rm programs out there, and not conforming with
-the upcoming POSIX standard: <http://austingroupbugs.net/view.php?id=542>
-
-Please tell bug-automake@gnu.org about your system, including the value
-of your $PATH and any error possibly output before this message. This
-can help us improve future automake versions.
-
-END
- if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then
- echo 'Configuration will proceed anyway, since you have set the' >&2
- echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2
- echo >&2
- else
- cat >&2 <<'END'
-Aborting the configuration process, to ensure you take notice of the issue.
-
-You can download and install GNU coreutils to get an 'rm' implementation
-that behaves properly: <http://www.gnu.org/software/coreutils/>.
-
-If you want to complete the configuration process using your problematic
-'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM
-to "yes", and re-run configure.
-
-END
- as_fn_error $? "Your 'rm' program is bad, sorry." "$LINENO" 5
- fi
-fi
-
-# Check whether --enable-silent-rules was given.
-if test "${enable_silent_rules+set}" = set; then :
- enableval=$enable_silent_rules;
-fi
-
-case $enable_silent_rules in # (((
- yes) AM_DEFAULT_VERBOSITY=0;;
- no) AM_DEFAULT_VERBOSITY=1;;
- *) AM_DEFAULT_VERBOSITY=0;;
-esac
-am_make=${MAKE-make}
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5
-$as_echo_n "checking whether $am_make supports nested variables... " >&6; }
-if ${am_cv_make_support_nested_variables+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if $as_echo 'TRUE=$(BAR$(V))
-BAR0=false
-BAR1=true
-V=1
-am__doit:
- @$(TRUE)
-.PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then
- am_cv_make_support_nested_variables=yes
-else
- am_cv_make_support_nested_variables=no
-fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5
-$as_echo "$am_cv_make_support_nested_variables" >&6; }
-if test $am_cv_make_support_nested_variables = yes; then
- AM_V='$(V)'
- AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
-else
- AM_V=$AM_DEFAULT_VERBOSITY
- AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY
-fi
-AM_BACKSLASH='\'
-
-
-ac_config_headers="$ac_config_headers gconfig.h:gconfig.in"
-
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
-set dummy ${ac_tool_prefix}gcc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_CC="${ac_tool_prefix}gcc"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
-$as_echo "$CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_CC"; then
- ac_ct_CC=$CC
- # Extract the first word of "gcc", so it can be a program name with args.
-set dummy gcc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_CC"; then
- ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_CC="gcc"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_CC=$ac_cv_prog_ac_ct_CC
-if test -n "$ac_ct_CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
-$as_echo "$ac_ct_CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_CC" = x; then
- CC=""
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- CC=$ac_ct_CC
- fi
-else
- CC="$ac_cv_prog_CC"
-fi
-
-if test -z "$CC"; then
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
-set dummy ${ac_tool_prefix}cc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_CC="${ac_tool_prefix}cc"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
-$as_echo "$CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
-fi
-if test -z "$CC"; then
- # Extract the first word of "cc", so it can be a program name with args.
-set dummy cc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
- ac_prog_rejected=no
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
- ac_prog_rejected=yes
- continue
- fi
- ac_cv_prog_CC="cc"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-if test $ac_prog_rejected = yes; then
- # We found a bogon in the path, so make sure we never use it.
- set dummy $ac_cv_prog_CC
- shift
- if test $# != 0; then
- # We chose a different compiler from the bogus one.
- # However, it has the same basename, so the bogon will be chosen
- # first if we set CC to just the basename; use the full file name.
- shift
- ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
- fi
-fi
-fi
-fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
-$as_echo "$CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$CC"; then
- if test -n "$ac_tool_prefix"; then
- for ac_prog in cl.exe
- do
- # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
-set dummy $ac_tool_prefix$ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
-$as_echo "$CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$CC" && break
- done
-fi
-if test -z "$CC"; then
- ac_ct_CC=$CC
- for ac_prog in cl.exe
-do
- # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_CC"; then
- ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_CC="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_CC=$ac_cv_prog_ac_ct_CC
-if test -n "$ac_ct_CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
-$as_echo "$ac_ct_CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$ac_ct_CC" && break
-done
-
- if test "x$ac_ct_CC" = x; then
- CC=""
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- CC=$ac_ct_CC
- fi
-fi
-
-fi
-
-
-test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "no acceptable C compiler found in \$PATH
-See \`config.log' for more details" "$LINENO" 5; }
-
-# Provide some information about the compiler.
-$as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
-set X $ac_compile
-ac_compiler=$2
-for ac_option in --version -v -V -qversion; do
- { { ac_try="$ac_compiler $ac_option >&5"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_compiler $ac_option >&5") 2>conftest.err
- ac_status=$?
- if test -s conftest.err; then
- sed '10a\
-... rest of stderr output deleted ...
- 10q' conftest.err >conftest.er1
- cat conftest.er1 >&5
- fi
- rm -f conftest.er1 conftest.err
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }
-done
-
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-ac_clean_files_save=$ac_clean_files
-ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
-# Try to create an executable without -o first, disregard a.out.
-# It will help us diagnose broken compilers, and finding out an intuition
-# of exeext.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
-$as_echo_n "checking whether the C compiler works... " >&6; }
-ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
-
-# The possible output files:
-ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
-
-ac_rmfiles=
-for ac_file in $ac_files
-do
- case $ac_file in
- *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
- * ) ac_rmfiles="$ac_rmfiles $ac_file";;
- esac
-done
-rm -f $ac_rmfiles
-
-if { { ac_try="$ac_link_default"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_link_default") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then :
- # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
-# So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
-# in a Makefile. We should not override ac_cv_exeext if it was cached,
-# so that the user can short-circuit this test for compilers unknown to
-# Autoconf.
-for ac_file in $ac_files ''
-do
- test -f "$ac_file" || continue
- case $ac_file in
- *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
- ;;
- [ab].out )
- # We found the default executable, but exeext='' is most
- # certainly right.
- break;;
- *.* )
- if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
- then :; else
- ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
- fi
- # We set ac_cv_exeext here because the later test for it is not
- # safe: cross compilers may not add the suffix if given an `-o'
- # argument, so we may need to know it at that point already.
- # Even if this section looks crufty: it has the advantage of
- # actually working.
- break;;
- * )
- break;;
- esac
-done
-test "$ac_cv_exeext" = no && ac_cv_exeext=
-
-else
- ac_file=''
-fi
-if test -z "$ac_file"; then :
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-$as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error 77 "C compiler cannot create executables
-See \`config.log' for more details" "$LINENO" 5; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
-$as_echo_n "checking for C compiler default output file name... " >&6; }
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
-$as_echo "$ac_file" >&6; }
-ac_exeext=$ac_cv_exeext
-
-rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
-ac_clean_files=$ac_clean_files_save
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
-$as_echo_n "checking for suffix of executables... " >&6; }
-if { { ac_try="$ac_link"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_link") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then :
- # If both `conftest.exe' and `conftest' are `present' (well, observable)
-# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
-# work properly (i.e., refer to `conftest.exe'), while it won't with
-# `rm'.
-for ac_file in conftest.exe conftest conftest.*; do
- test -f "$ac_file" || continue
- case $ac_file in
- *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
- *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
- break;;
- * ) break;;
- esac
-done
-else
- { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "cannot compute suffix of executables: cannot compile and link
-See \`config.log' for more details" "$LINENO" 5; }
-fi
-rm -f conftest conftest$ac_cv_exeext
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
-$as_echo "$ac_cv_exeext" >&6; }
-
-rm -f conftest.$ac_ext
-EXEEXT=$ac_cv_exeext
-ac_exeext=$EXEEXT
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <stdio.h>
-int
-main ()
-{
-FILE *f = fopen ("conftest.out", "w");
- return ferror (f) || fclose (f) != 0;
-
- ;
- return 0;
-}
-_ACEOF
-ac_clean_files="$ac_clean_files conftest.out"
-# Check that the compiler produces executables we can run. If not, either
-# the compiler is broken, or we cross compile.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
-$as_echo_n "checking whether we are cross compiling... " >&6; }
-if test "$cross_compiling" != yes; then
- { { ac_try="$ac_link"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_link") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }
- if { ac_try='./conftest$ac_cv_exeext'
- { { case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_try") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; }; then
- cross_compiling=no
- else
- if test "$cross_compiling" = maybe; then
- cross_compiling=yes
- else
- { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "cannot run C compiled programs.
-If you meant to cross compile, use \`--host'.
-See \`config.log' for more details" "$LINENO" 5; }
- fi
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
-$as_echo "$cross_compiling" >&6; }
-
-rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
-ac_clean_files=$ac_clean_files_save
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
-$as_echo_n "checking for suffix of object files... " >&6; }
-if ${ac_cv_objext+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-rm -f conftest.o conftest.obj
-if { { ac_try="$ac_compile"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_compile") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then :
- for ac_file in conftest.o conftest.obj conftest.*; do
- test -f "$ac_file" || continue;
- case $ac_file in
- *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
- *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
- break;;
- esac
-done
-else
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "cannot compute suffix of object files: cannot compile
-See \`config.log' for more details" "$LINENO" 5; }
-fi
-rm -f conftest.$ac_cv_objext conftest.$ac_ext
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
-$as_echo "$ac_cv_objext" >&6; }
-OBJEXT=$ac_cv_objext
-ac_objext=$OBJEXT
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
-$as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
-if ${ac_cv_c_compiler_gnu+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-#ifndef __GNUC__
- choke me
-#endif
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_compiler_gnu=yes
-else
- ac_compiler_gnu=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-ac_cv_c_compiler_gnu=$ac_compiler_gnu
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
-$as_echo "$ac_cv_c_compiler_gnu" >&6; }
-if test $ac_compiler_gnu = yes; then
- GCC=yes
-else
- GCC=
-fi
-ac_test_CFLAGS=${CFLAGS+set}
-ac_save_CFLAGS=$CFLAGS
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
-$as_echo_n "checking whether $CC accepts -g... " >&6; }
-if ${ac_cv_prog_cc_g+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_save_c_werror_flag=$ac_c_werror_flag
- ac_c_werror_flag=yes
- ac_cv_prog_cc_g=no
- CFLAGS="-g"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_prog_cc_g=yes
-else
- CFLAGS=""
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
-
-else
- ac_c_werror_flag=$ac_save_c_werror_flag
- CFLAGS="-g"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_prog_cc_g=yes
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- ac_c_werror_flag=$ac_save_c_werror_flag
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
-$as_echo "$ac_cv_prog_cc_g" >&6; }
-if test "$ac_test_CFLAGS" = set; then
- CFLAGS=$ac_save_CFLAGS
-elif test $ac_cv_prog_cc_g = yes; then
- if test "$GCC" = yes; then
- CFLAGS="-g -O2"
- else
- CFLAGS="-g"
- fi
-else
- if test "$GCC" = yes; then
- CFLAGS="-O2"
- else
- CFLAGS=
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
-$as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
-if ${ac_cv_prog_cc_c89+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_cv_prog_cc_c89=no
-ac_save_CC=$CC
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <stdarg.h>
-#include <stdio.h>
-struct stat;
-/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
-struct buf { int x; };
-FILE * (*rcsopen) (struct buf *, struct stat *, int);
-static char *e (p, i)
- char **p;
- int i;
-{
- return p[i];
-}
-static char *f (char * (*g) (char **, int), char **p, ...)
-{
- char *s;
- va_list v;
- va_start (v,p);
- s = g (p, va_arg (v,int));
- va_end (v);
- return s;
-}
-
-/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
- function prototypes and stuff, but not '\xHH' hex character constants.
- These don't provoke an error unfortunately, instead are silently treated
- as 'x'. The following induces an error, until -std is added to get
- proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
- array size at least. It's necessary to write '\x00'==0 to get something
- that's true only with -std. */
-int osf4_cc_array ['\x00' == 0 ? 1 : -1];
-
-/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
- inside strings and character constants. */
-#define FOO(x) 'x'
-int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
-
-int test (int i, double x);
-struct s1 {int (*f) (int a);};
-struct s2 {int (*f) (double a);};
-int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
-int argc;
-char **argv;
-int
-main ()
-{
-return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
- ;
- return 0;
-}
-_ACEOF
-for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
- -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
-do
- CC="$ac_save_CC $ac_arg"
- if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_prog_cc_c89=$ac_arg
-fi
-rm -f core conftest.err conftest.$ac_objext
- test "x$ac_cv_prog_cc_c89" != "xno" && break
-done
-rm -f conftest.$ac_ext
-CC=$ac_save_CC
-
-fi
-# AC_CACHE_VAL
-case "x$ac_cv_prog_cc_c89" in
- x)
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
-$as_echo "none needed" >&6; } ;;
- xno)
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
-$as_echo "unsupported" >&6; } ;;
- *)
- CC="$CC $ac_cv_prog_cc_c89"
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
-$as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
-esac
-if test "x$ac_cv_prog_cc_c89" != xno; then :
-
-fi
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC understands -c and -o together" >&5
-$as_echo_n "checking whether $CC understands -c and -o together... " >&6; }
-if ${am_cv_prog_cc_c_o+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
- # Make sure it works both with $CC and with simple cc.
- # Following AC_PROG_CC_C_O, we do the test twice because some
- # compilers refuse to overwrite an existing .o file with -o,
- # though they will create one.
- am_cv_prog_cc_c_o=yes
- for am_i in 1 2; do
- if { echo "$as_me:$LINENO: $CC -c conftest.$ac_ext -o conftest2.$ac_objext" >&5
- ($CC -c conftest.$ac_ext -o conftest2.$ac_objext) >&5 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } \
- && test -f conftest2.$ac_objext; then
- : OK
- else
- am_cv_prog_cc_c_o=no
- break
- fi
- done
- rm -f core conftest*
- unset am_i
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_cc_c_o" >&5
-$as_echo "$am_cv_prog_cc_c_o" >&6; }
-if test "$am_cv_prog_cc_c_o" != yes; then
- # Losing compiler, so override with the script.
- # FIXME: It is wrong to rewrite CC.
- # But if we don't then we get into trouble of one sort or another.
- # A longer-term fix would be to have automake use am__CC in this case,
- # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
- CC="$am_aux_dir/compile $CC"
-fi
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-DEPDIR="${am__leading_dot}deps"
-
-ac_config_commands="$ac_config_commands depfiles"
-
-
-am_make=${MAKE-make}
-cat > confinc << 'END'
-am__doit:
- @echo this is the am__doit target
-.PHONY: am__doit
-END
-# If we don't find an include directive, just comment out the code.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5
-$as_echo_n "checking for style of include used by $am_make... " >&6; }
-am__include="#"
-am__quote=
-_am_result=none
-# First try GNU make style include.
-echo "include confinc" > confmf
-# Ignore all kinds of additional output from 'make'.
-case `$am_make -s -f confmf 2> /dev/null` in #(
-*the\ am__doit\ target*)
- am__include=include
- am__quote=
- _am_result=GNU
- ;;
-esac
-# Now try BSD make style include.
-if test "$am__include" = "#"; then
- echo '.include "confinc"' > confmf
- case `$am_make -s -f confmf 2> /dev/null` in #(
- *the\ am__doit\ target*)
- am__include=.include
- am__quote="\""
- _am_result=BSD
- ;;
- esac
-fi
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5
-$as_echo "$_am_result" >&6; }
-rm -f confinc confmf
-
-# Check whether --enable-dependency-tracking was given.
-if test "${enable_dependency_tracking+set}" = set; then :
- enableval=$enable_dependency_tracking;
-fi
-
-if test "x$enable_dependency_tracking" != xno; then
- am_depcomp="$ac_aux_dir/depcomp"
- AMDEPBACKSLASH='\'
- am__nodep='_no'
-fi
- if test "x$enable_dependency_tracking" != xno; then
- AMDEP_TRUE=
- AMDEP_FALSE='#'
-else
- AMDEP_TRUE='#'
- AMDEP_FALSE=
-fi
-
-
-
-depcc="$CC" am_compiler_list=
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
-$as_echo_n "checking dependency style of $depcc... " >&6; }
-if ${am_cv_CC_dependencies_compiler_type+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
- # We make a subdir and do the tests there. Otherwise we can end up
- # making bogus files that we don't know about and never remove. For
- # instance it was reported that on HP-UX the gcc test will end up
- # making a dummy file named 'D' -- because '-MD' means "put the output
- # in D".
- rm -rf conftest.dir
- mkdir conftest.dir
- # Copy depcomp to subdir because otherwise we won't find it if we're
- # using a relative directory.
- cp "$am_depcomp" conftest.dir
- cd conftest.dir
- # We will build objects and dependencies in a subdirectory because
- # it helps to detect inapplicable dependency modes. For instance
- # both Tru64's cc and ICC support -MD to output dependencies as a
- # side effect of compilation, but ICC will put the dependencies in
- # the current directory while Tru64 will put them in the object
- # directory.
- mkdir sub
-
- am_cv_CC_dependencies_compiler_type=none
- if test "$am_compiler_list" = ""; then
- am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
- fi
- am__universal=false
- case " $depcc " in #(
- *\ -arch\ *\ -arch\ *) am__universal=true ;;
- esac
-
- for depmode in $am_compiler_list; do
- # Setup a source with many dependencies, because some compilers
- # like to wrap large dependency lists on column 80 (with \), and
- # we should not choose a depcomp mode which is confused by this.
- #
- # We need to recreate these files for each test, as the compiler may
- # overwrite some of them when testing with obscure command lines.
- # This happens at least with the AIX C compiler.
- : > sub/conftest.c
- for i in 1 2 3 4 5 6; do
- echo '#include "conftst'$i'.h"' >> sub/conftest.c
- # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with
- # Solaris 10 /bin/sh.
- echo '/* dummy */' > sub/conftst$i.h
- done
- echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
-
- # We check with '-c' and '-o' for the sake of the "dashmstdout"
- # mode. It turns out that the SunPro C++ compiler does not properly
- # handle '-M -o', and we need to detect this. Also, some Intel
- # versions had trouble with output in subdirs.
- am__obj=sub/conftest.${OBJEXT-o}
- am__minus_obj="-o $am__obj"
- case $depmode in
- gcc)
- # This depmode causes a compiler race in universal mode.
- test "$am__universal" = false || continue
- ;;
- nosideeffect)
- # After this tag, mechanisms are not by side-effect, so they'll
- # only be used when explicitly requested.
- if test "x$enable_dependency_tracking" = xyes; then
- continue
- else
- break
- fi
- ;;
- msvc7 | msvc7msys | msvisualcpp | msvcmsys)
- # This compiler won't grok '-c -o', but also, the minuso test has
- # not run yet. These depmodes are late enough in the game, and
- # so weak that their functioning should not be impacted.
- am__obj=conftest.${OBJEXT-o}
- am__minus_obj=
- ;;
- none) break ;;
- esac
- if depmode=$depmode \
- source=sub/conftest.c object=$am__obj \
- depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
- $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
- >/dev/null 2>conftest.err &&
- grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
- grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
- grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
- ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
- # icc doesn't choke on unknown options, it will just issue warnings
- # or remarks (even with -Werror). So we grep stderr for any message
- # that says an option was ignored or not supported.
- # When given -MP, icc 7.0 and 7.1 complain thusly:
- # icc: Command line warning: ignoring option '-M'; no argument required
- # The diagnosis changed in icc 8.0:
- # icc: Command line remark: option '-MP' not supported
- if (grep 'ignoring option' conftest.err ||
- grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
- am_cv_CC_dependencies_compiler_type=$depmode
- break
- fi
- fi
- done
-
- cd ..
- rm -rf conftest.dir
-else
- am_cv_CC_dependencies_compiler_type=none
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
-$as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
-CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
-
- if
- test "x$enable_dependency_tracking" != xno \
- && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
- am__fastdepCC_TRUE=
- am__fastdepCC_FALSE='#'
-else
- am__fastdepCC_TRUE='#'
- am__fastdepCC_FALSE=
-fi
-
-
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
-$as_echo_n "checking how to run the C preprocessor... " >&6; }
-# On Suns, sometimes $CPP names a directory.
-if test -n "$CPP" && test -d "$CPP"; then
- CPP=
-fi
-if test -z "$CPP"; then
- if ${ac_cv_prog_CPP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- # Double quotes because CPP needs to be expanded
- for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
- do
- ac_preproc_ok=false
-for ac_c_preproc_warn_flag in '' yes
-do
- # Use a header file that comes with gcc, so configuring glibc
- # with a fresh cross-compiler works.
- # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
- # <limits.h> exists even on freestanding compilers.
- # On the NeXT, cc -E runs the code through the compiler's parser,
- # not just through cpp. "Syntax error" is here to catch this case.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#ifdef __STDC__
-# include <limits.h>
-#else
-# include <assert.h>
-#endif
- Syntax error
-_ACEOF
-if ac_fn_c_try_cpp "$LINENO"; then :
-
-else
- # Broken: fails on valid input.
-continue
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-
- # OK, works on sane cases. Now check whether nonexistent headers
- # can be detected and how.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <ac_nonexistent.h>
-_ACEOF
-if ac_fn_c_try_cpp "$LINENO"; then :
- # Broken: success on invalid input.
-continue
-else
- # Passes both tests.
-ac_preproc_ok=:
-break
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-
-done
-# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
-rm -f conftest.i conftest.err conftest.$ac_ext
-if $ac_preproc_ok; then :
- break
-fi
-
- done
- ac_cv_prog_CPP=$CPP
-
-fi
- CPP=$ac_cv_prog_CPP
-else
- ac_cv_prog_CPP=$CPP
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
-$as_echo "$CPP" >&6; }
-ac_preproc_ok=false
-for ac_c_preproc_warn_flag in '' yes
-do
- # Use a header file that comes with gcc, so configuring glibc
- # with a fresh cross-compiler works.
- # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
- # <limits.h> exists even on freestanding compilers.
- # On the NeXT, cc -E runs the code through the compiler's parser,
- # not just through cpp. "Syntax error" is here to catch this case.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#ifdef __STDC__
-# include <limits.h>
-#else
-# include <assert.h>
-#endif
- Syntax error
-_ACEOF
-if ac_fn_c_try_cpp "$LINENO"; then :
-
-else
- # Broken: fails on valid input.
-continue
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-
- # OK, works on sane cases. Now check whether nonexistent headers
- # can be detected and how.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <ac_nonexistent.h>
-_ACEOF
-if ac_fn_c_try_cpp "$LINENO"; then :
- # Broken: success on invalid input.
-continue
-else
- # Passes both tests.
-ac_preproc_ok=:
-break
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-
-done
-# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
-rm -f conftest.i conftest.err conftest.$ac_ext
-if $ac_preproc_ok; then :
-
-else
- { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
-See \`config.log' for more details" "$LINENO" 5; }
-fi
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
-$as_echo_n "checking for grep that handles long lines and -e... " >&6; }
-if ${ac_cv_path_GREP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -z "$GREP"; then
- ac_path_GREP_found=false
- # Loop through the user's path and test for each of PROGNAME-LIST
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_prog in grep ggrep; do
- for ac_exec_ext in '' $ac_executable_extensions; do
- ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
- as_fn_executable_p "$ac_path_GREP" || continue
-# Check for GNU ac_path_GREP and select it if it is found.
- # Check for GNU $ac_path_GREP
-case `"$ac_path_GREP" --version 2>&1` in
-*GNU*)
- ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
-*)
- ac_count=0
- $as_echo_n 0123456789 >"conftest.in"
- while :
- do
- cat "conftest.in" "conftest.in" >"conftest.tmp"
- mv "conftest.tmp" "conftest.in"
- cp "conftest.in" "conftest.nl"
- $as_echo 'GREP' >> "conftest.nl"
- "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
- diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
- as_fn_arith $ac_count + 1 && ac_count=$as_val
- if test $ac_count -gt ${ac_path_GREP_max-0}; then
- # Best one so far, save it but keep looking for a better one
- ac_cv_path_GREP="$ac_path_GREP"
- ac_path_GREP_max=$ac_count
- fi
- # 10*(2^10) chars as input seems more than enough
- test $ac_count -gt 10 && break
- done
- rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
-esac
-
- $ac_path_GREP_found && break 3
- done
- done
- done
-IFS=$as_save_IFS
- if test -z "$ac_cv_path_GREP"; then
- as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
- fi
-else
- ac_cv_path_GREP=$GREP
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
-$as_echo "$ac_cv_path_GREP" >&6; }
- GREP="$ac_cv_path_GREP"
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
-$as_echo_n "checking for egrep... " >&6; }
-if ${ac_cv_path_EGREP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
- then ac_cv_path_EGREP="$GREP -E"
- else
- if test -z "$EGREP"; then
- ac_path_EGREP_found=false
- # Loop through the user's path and test for each of PROGNAME-LIST
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_prog in egrep; do
- for ac_exec_ext in '' $ac_executable_extensions; do
- ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
- as_fn_executable_p "$ac_path_EGREP" || continue
-# Check for GNU ac_path_EGREP and select it if it is found.
- # Check for GNU $ac_path_EGREP
-case `"$ac_path_EGREP" --version 2>&1` in
-*GNU*)
- ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
-*)
- ac_count=0
- $as_echo_n 0123456789 >"conftest.in"
- while :
- do
- cat "conftest.in" "conftest.in" >"conftest.tmp"
- mv "conftest.tmp" "conftest.in"
- cp "conftest.in" "conftest.nl"
- $as_echo 'EGREP' >> "conftest.nl"
- "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
- diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
- as_fn_arith $ac_count + 1 && ac_count=$as_val
- if test $ac_count -gt ${ac_path_EGREP_max-0}; then
- # Best one so far, save it but keep looking for a better one
- ac_cv_path_EGREP="$ac_path_EGREP"
- ac_path_EGREP_max=$ac_count
- fi
- # 10*(2^10) chars as input seems more than enough
- test $ac_count -gt 10 && break
- done
- rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
-esac
-
- $ac_path_EGREP_found && break 3
- done
- done
- done
-IFS=$as_save_IFS
- if test -z "$ac_cv_path_EGREP"; then
- as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
- fi
-else
- ac_cv_path_EGREP=$EGREP
-fi
-
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
-$as_echo "$ac_cv_path_EGREP" >&6; }
- EGREP="$ac_cv_path_EGREP"
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
-$as_echo_n "checking for ANSI C header files... " >&6; }
-if ${ac_cv_header_stdc+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <stdlib.h>
-#include <stdarg.h>
-#include <string.h>
-#include <float.h>
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_header_stdc=yes
-else
- ac_cv_header_stdc=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-
-if test $ac_cv_header_stdc = yes; then
- # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <string.h>
-
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "memchr" >/dev/null 2>&1; then :
-
-else
- ac_cv_header_stdc=no
-fi
-rm -f conftest*
-
-fi
-
-if test $ac_cv_header_stdc = yes; then
- # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <stdlib.h>
-
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "free" >/dev/null 2>&1; then :
-
-else
- ac_cv_header_stdc=no
-fi
-rm -f conftest*
-
-fi
-
-if test $ac_cv_header_stdc = yes; then
- # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
- if test "$cross_compiling" = yes; then :
- :
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <ctype.h>
-#include <stdlib.h>
-#if ((' ' & 0x0FF) == 0x020)
-# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
-# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
-#else
-# define ISLOWER(c) \
- (('a' <= (c) && (c) <= 'i') \
- || ('j' <= (c) && (c) <= 'r') \
- || ('s' <= (c) && (c) <= 'z'))
-# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
-#endif
-
-#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
-int
-main ()
-{
- int i;
- for (i = 0; i < 256; i++)
- if (XOR (islower (i), ISLOWER (i))
- || toupper (i) != TOUPPER (i))
- return 2;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_run "$LINENO"; then :
-
-else
- ac_cv_header_stdc=no
-fi
-rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
- conftest.$ac_objext conftest.beam conftest.$ac_ext
-fi
-
-fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
-$as_echo "$ac_cv_header_stdc" >&6; }
-if test $ac_cv_header_stdc = yes; then
-
-$as_echo "#define STDC_HEADERS 1" >>confdefs.h
-
-fi
-
-# On IRIX 5.3, sys/types and inttypes.h are conflicting.
-for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
- inttypes.h stdint.h unistd.h
-do :
- as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
-ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
-"
-if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
- cat >>confdefs.h <<_ACEOF
-#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
-_ACEOF
-
-fi
-
-done
-
-
-
- ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
-if test "x$ac_cv_header_minix_config_h" = xyes; then :
- MINIX=yes
-else
- MINIX=
-fi
-
-
- if test "$MINIX" = yes; then
-
-$as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
-
-
-$as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
-
-
-$as_echo "#define _MINIX 1" >>confdefs.h
-
- fi
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
-$as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
-if ${ac_cv_safe_to_define___extensions__+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-# define __EXTENSIONS__ 1
- $ac_includes_default
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_safe_to_define___extensions__=yes
-else
- ac_cv_safe_to_define___extensions__=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
-$as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
- test $ac_cv_safe_to_define___extensions__ = yes &&
- $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
-
- $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
-
- $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
-
- $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
-
- $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
-
-
-
-
-case `pwd` in
- *\ * | *\ *)
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&5
-$as_echo "$as_me: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&2;} ;;
-esac
-
-
-
-macro_version='2.2.7a'
-macro_revision='1.3134'
-
-
-
-
-
-
-
-
-
-
-
-
-
-ltmain="$ac_aux_dir/ltmain.sh"
-
-# Backslashify metacharacters that are still active within
-# double-quoted strings.
-sed_quote_subst='s/\(["`$\\]\)/\\\1/g'
-
-# Same as above, but do not quote variable references.
-double_quote_subst='s/\(["`\\]\)/\\\1/g'
-
-# Sed substitution to delay expansion of an escaped shell variable in a
-# double_quote_subst'ed string.
-delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
-
-# Sed substitution to delay expansion of an escaped single quote.
-delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g'
-
-# Sed substitution to avoid accidental globbing in evaled expressions
-no_glob_subst='s/\*/\\\*/g'
-
-ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
-ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO
-ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5
-$as_echo_n "checking how to print strings... " >&6; }
-# Test print first, because it will be a builtin if present.
-if test "X`print -r -- -n 2>/dev/null`" = X-n && \
- test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
- ECHO='print -r --'
-elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
- ECHO='printf %s\n'
-else
- # Use this function as a fallback that always works.
- func_fallback_echo ()
- {
- eval 'cat <<_LTECHO_EOF
-$1
-_LTECHO_EOF'
- }
- ECHO='func_fallback_echo'
-fi
-
-# func_echo_all arg...
-# Invoke $ECHO with all args, space-separated.
-func_echo_all ()
-{
- $ECHO ""
-}
-
-case "$ECHO" in
- printf*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: printf" >&5
-$as_echo "printf" >&6; } ;;
- print*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: print -r" >&5
-$as_echo "print -r" >&6; } ;;
- *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: cat" >&5
-$as_echo "cat" >&6; } ;;
-esac
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
-$as_echo_n "checking for a sed that does not truncate output... " >&6; }
-if ${ac_cv_path_SED+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
- for ac_i in 1 2 3 4 5 6 7; do
- ac_script="$ac_script$as_nl$ac_script"
- done
- echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
- { ac_script=; unset ac_script;}
- if test -z "$SED"; then
- ac_path_SED_found=false
- # Loop through the user's path and test for each of PROGNAME-LIST
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_prog in sed gsed; do
- for ac_exec_ext in '' $ac_executable_extensions; do
- ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
- as_fn_executable_p "$ac_path_SED" || continue
-# Check for GNU ac_path_SED and select it if it is found.
- # Check for GNU $ac_path_SED
-case `"$ac_path_SED" --version 2>&1` in
-*GNU*)
- ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
-*)
- ac_count=0
- $as_echo_n 0123456789 >"conftest.in"
- while :
- do
- cat "conftest.in" "conftest.in" >"conftest.tmp"
- mv "conftest.tmp" "conftest.in"
- cp "conftest.in" "conftest.nl"
- $as_echo '' >> "conftest.nl"
- "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
- diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
- as_fn_arith $ac_count + 1 && ac_count=$as_val
- if test $ac_count -gt ${ac_path_SED_max-0}; then
- # Best one so far, save it but keep looking for a better one
- ac_cv_path_SED="$ac_path_SED"
- ac_path_SED_max=$ac_count
- fi
- # 10*(2^10) chars as input seems more than enough
- test $ac_count -gt 10 && break
- done
- rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
-esac
-
- $ac_path_SED_found && break 3
- done
- done
- done
-IFS=$as_save_IFS
- if test -z "$ac_cv_path_SED"; then
- as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
- fi
-else
- ac_cv_path_SED=$SED
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
-$as_echo "$ac_cv_path_SED" >&6; }
- SED="$ac_cv_path_SED"
- rm -f conftest.sed
-
-test -z "$SED" && SED=sed
-Xsed="$SED -e 1s/^X//"
-
-
-
-
-
-
-
-
-
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5
-$as_echo_n "checking for fgrep... " >&6; }
-if ${ac_cv_path_FGREP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1
- then ac_cv_path_FGREP="$GREP -F"
- else
- if test -z "$FGREP"; then
- ac_path_FGREP_found=false
- # Loop through the user's path and test for each of PROGNAME-LIST
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_prog in fgrep; do
- for ac_exec_ext in '' $ac_executable_extensions; do
- ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext"
- as_fn_executable_p "$ac_path_FGREP" || continue
-# Check for GNU ac_path_FGREP and select it if it is found.
- # Check for GNU $ac_path_FGREP
-case `"$ac_path_FGREP" --version 2>&1` in
-*GNU*)
- ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;;
-*)
- ac_count=0
- $as_echo_n 0123456789 >"conftest.in"
- while :
- do
- cat "conftest.in" "conftest.in" >"conftest.tmp"
- mv "conftest.tmp" "conftest.in"
- cp "conftest.in" "conftest.nl"
- $as_echo 'FGREP' >> "conftest.nl"
- "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break
- diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
- as_fn_arith $ac_count + 1 && ac_count=$as_val
- if test $ac_count -gt ${ac_path_FGREP_max-0}; then
- # Best one so far, save it but keep looking for a better one
- ac_cv_path_FGREP="$ac_path_FGREP"
- ac_path_FGREP_max=$ac_count
- fi
- # 10*(2^10) chars as input seems more than enough
- test $ac_count -gt 10 && break
- done
- rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
-esac
-
- $ac_path_FGREP_found && break 3
- done
- done
- done
-IFS=$as_save_IFS
- if test -z "$ac_cv_path_FGREP"; then
- as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
- fi
-else
- ac_cv_path_FGREP=$FGREP
-fi
-
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5
-$as_echo "$ac_cv_path_FGREP" >&6; }
- FGREP="$ac_cv_path_FGREP"
-
-
-test -z "$GREP" && GREP=grep
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-# Check whether --with-gnu-ld was given.
-if test "${with_gnu_ld+set}" = set; then :
- withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
-else
- with_gnu_ld=no
-fi
-
-ac_prog=ld
-if test "$GCC" = yes; then
- # Check if gcc -print-prog-name=ld gives a path.
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5
-$as_echo_n "checking for ld used by $CC... " >&6; }
- case $host in
- *-*-mingw*)
- # gcc leaves a trailing carriage return which upsets mingw
- ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
- *)
- ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
- esac
- case $ac_prog in
- # Accept absolute paths.
- [\\/]* | ?:[\\/]*)
- re_direlt='/[^/][^/]*/\.\./'
- # Canonicalize the pathname of ld
- ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'`
- while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do
- ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"`
- done
- test -z "$LD" && LD="$ac_prog"
- ;;
- "")
- # If it fails, then pretend we aren't using GCC.
- ac_prog=ld
- ;;
- *)
- # If it is relative, then search for the first ld in PATH.
- with_gnu_ld=unknown
- ;;
- esac
-elif test "$with_gnu_ld" = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
-$as_echo_n "checking for GNU ld... " >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
-$as_echo_n "checking for non-GNU ld... " >&6; }
-fi
-if ${lt_cv_path_LD+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -z "$LD"; then
- lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH; do
- IFS="$lt_save_ifs"
- test -z "$ac_dir" && ac_dir=.
- if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
- lt_cv_path_LD="$ac_dir/$ac_prog"
- # Check to see if the program is GNU ld. I'd rather use --version,
- # but apparently some variants of GNU ld only accept -v.
- # Break only if it was the GNU/non-GNU ld that we prefer.
- case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
- *GNU* | *'with BFD'*)
- test "$with_gnu_ld" != no && break
- ;;
- *)
- test "$with_gnu_ld" != yes && break
- ;;
- esac
- fi
- done
- IFS="$lt_save_ifs"
-else
- lt_cv_path_LD="$LD" # Let the user override the test with a path.
-fi
-fi
-
-LD="$lt_cv_path_LD"
-if test -n "$LD"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
-$as_echo "$LD" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
-$as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
-if ${lt_cv_prog_gnu_ld+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- # I'd rather use --version here, but apparently some GNU lds only accept -v.
-case `$LD -v 2>&1 </dev/null` in
-*GNU* | *'with BFD'*)
- lt_cv_prog_gnu_ld=yes
- ;;
-*)
- lt_cv_prog_gnu_ld=no
- ;;
-esac
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_gnu_ld" >&5
-$as_echo "$lt_cv_prog_gnu_ld" >&6; }
-with_gnu_ld=$lt_cv_prog_gnu_ld
-
-
-
-
-
-
-
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for BSD- or MS-compatible name lister (nm)" >&5
-$as_echo_n "checking for BSD- or MS-compatible name lister (nm)... " >&6; }
-if ${lt_cv_path_NM+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$NM"; then
- # Let the user override the nm to test.
- lt_nm_to_check="$NM"
- else
- lt_nm_to_check="${ac_tool_prefix}nm"
- if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
- lt_nm_to_check="$lt_nm_to_check nm"
- fi
- fi
- for lt_tmp_nm in "$lt_nm_to_check"; do
- lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
- IFS="$lt_save_ifs"
- test -z "$ac_dir" && ac_dir=.
- # Strip out any user-provided options from the nm to test twice,
- # the first time to test to see if nm (rather than its options) has
- # an explicit path, the second time to yield a file which can be
- # nm'ed itself.
- tmp_nm_path="`$ECHO "$lt_tmp_nm" | sed 's, -.*$,,'`"
- case "$tmp_nm_path" in
- */*|*\\*) tmp_nm="$lt_tmp_nm";;
- *) tmp_nm="$ac_dir/$lt_tmp_nm";;
- esac
- tmp_nm_to_nm="`$ECHO "$tmp_nm" | sed 's, -.*$,,'`"
- if test -f "$tmp_nm_to_nm" || test -f "$tmp_nm_to_nm$ac_exeext" ; then
- # Check to see if the nm accepts a BSD-compat flag.
- # Adding the `sed 1q' prevents false positives on HP-UX, which says:
- # nm: unknown option "B" ignored
- case `"$tmp_nm" -B "$tmp_nm_to_nm" 2>&1 | grep -v '^ *$' | sed '1q'` in
- *$tmp_nm*) lt_cv_path_NM="$tmp_nm -B"
- break
- ;;
- *)
- case `"$tmp_nm" -p "$tmp_nm_to_nm" 2>&1 | grep -v '^ *$' | sed '1q'` in
- *$tmp_nm*)
- lt_cv_path_NM="$tmp_nm -p"
- break
- ;;
- *)
- lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
- continue # so that we can try to find one that supports BSD flags
- ;;
- esac
- ;;
- esac
- fi
- done
- IFS="$lt_save_ifs"
- done
- : ${lt_cv_path_NM=no}
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_NM" >&5
-$as_echo "$lt_cv_path_NM" >&6; }
-if test "$lt_cv_path_NM" != "no"; then
- NM="$lt_cv_path_NM"
-else
- # Didn't find any BSD compatible name lister, look for dumpbin.
- if test -n "$DUMPBIN"; then :
- # Let the user override the test.
- else
- if test -n "$ac_tool_prefix"; then
- for ac_prog in dumpbin "link -dump"
- do
- # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
-set dummy $ac_tool_prefix$ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_DUMPBIN+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$DUMPBIN"; then
- ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_DUMPBIN="$ac_tool_prefix$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-DUMPBIN=$ac_cv_prog_DUMPBIN
-if test -n "$DUMPBIN"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5
-$as_echo "$DUMPBIN" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$DUMPBIN" && break
- done
-fi
-if test -z "$DUMPBIN"; then
- ac_ct_DUMPBIN=$DUMPBIN
- for ac_prog in dumpbin "link -dump"
-do
- # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_DUMPBIN+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_DUMPBIN"; then
- ac_cv_prog_ac_ct_DUMPBIN="$ac_ct_DUMPBIN" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_DUMPBIN="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_DUMPBIN=$ac_cv_prog_ac_ct_DUMPBIN
-if test -n "$ac_ct_DUMPBIN"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DUMPBIN" >&5
-$as_echo "$ac_ct_DUMPBIN" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$ac_ct_DUMPBIN" && break
-done
-
- if test "x$ac_ct_DUMPBIN" = x; then
- DUMPBIN=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- DUMPBIN=$ac_ct_DUMPBIN
- fi
-fi
-
- case `$DUMPBIN -symbols /dev/null 2>&1 | sed '1q'` in
- *COFF*)
- DUMPBIN="$DUMPBIN -symbols"
- ;;
- *)
- DUMPBIN=:
- ;;
- esac
- fi
-
- if test "$DUMPBIN" != ":"; then
- NM="$DUMPBIN"
- fi
-fi
-test -z "$NM" && NM=nm
-
-
-
-
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the name lister ($NM) interface" >&5
-$as_echo_n "checking the name lister ($NM) interface... " >&6; }
-if ${lt_cv_nm_interface+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_nm_interface="BSD nm"
- echo "int some_variable = 0;" > conftest.$ac_ext
- (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&5)
- (eval "$ac_compile" 2>conftest.err)
- cat conftest.err >&5
- (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&5)
- (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out)
- cat conftest.err >&5
- (eval echo "\"\$as_me:$LINENO: output\"" >&5)
- cat conftest.out >&5
- if $GREP 'External.*some_variable' conftest.out > /dev/null; then
- lt_cv_nm_interface="MS dumpbin"
- fi
- rm -f conftest*
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_nm_interface" >&5
-$as_echo "$lt_cv_nm_interface" >&6; }
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
-$as_echo_n "checking whether ln -s works... " >&6; }
-LN_S=$as_ln_s
-if test "$LN_S" = "ln -s"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
-$as_echo "no, using $LN_S" >&6; }
-fi
-
-# find the maximum length of command line arguments
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the maximum length of command line arguments" >&5
-$as_echo_n "checking the maximum length of command line arguments... " >&6; }
-if ${lt_cv_sys_max_cmd_len+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- i=0
- teststring="ABCD"
-
- case $build_os in
- msdosdjgpp*)
- # On DJGPP, this test can blow up pretty badly due to problems in libc
- # (any single argument exceeding 2000 bytes causes a buffer overrun
- # during glob expansion). Even if it were fixed, the result of this
- # check would be larger than it should be.
- lt_cv_sys_max_cmd_len=12288; # 12K is about right
- ;;
-
- gnu*)
- # Under GNU Hurd, this test is not required because there is
- # no limit to the length of command line arguments.
- # Libtool will interpret -1 as no limit whatsoever
- lt_cv_sys_max_cmd_len=-1;
- ;;
-
- cygwin* | mingw* | cegcc*)
- # On Win9x/ME, this test blows up -- it succeeds, but takes
- # about 5 minutes as the teststring grows exponentially.
- # Worse, since 9x/ME are not pre-emptively multitasking,
- # you end up with a "frozen" computer, even though with patience
- # the test eventually succeeds (with a max line length of 256k).
- # Instead, let's just punt: use the minimum linelength reported by
- # all of the supported platforms: 8192 (on NT/2K/XP).
- lt_cv_sys_max_cmd_len=8192;
- ;;
-
- mint*)
- # On MiNT this can take a long time and run out of memory.
- lt_cv_sys_max_cmd_len=8192;
- ;;
-
- amigaos*)
- # On AmigaOS with pdksh, this test takes hours, literally.
- # So we just punt and use a minimum line length of 8192.
- lt_cv_sys_max_cmd_len=8192;
- ;;
-
- netbsd* | freebsd* | openbsd* | darwin* | dragonfly*)
- # This has been around since 386BSD, at least. Likely further.
- if test -x /sbin/sysctl; then
- lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
- elif test -x /usr/sbin/sysctl; then
- lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
- else
- lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs
- fi
- # And add a safety zone
- lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
- lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
- ;;
-
- interix*)
- # We know the value 262144 and hardcode it with a safety zone (like BSD)
- lt_cv_sys_max_cmd_len=196608
- ;;
-
- osf*)
- # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
- # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
- # nice to cause kernel panics so lets avoid the loop below.
- # First set a reasonable default.
- lt_cv_sys_max_cmd_len=16384
- #
- if test -x /sbin/sysconfig; then
- case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
- *1*) lt_cv_sys_max_cmd_len=-1 ;;
- esac
- fi
- ;;
- sco3.2v5*)
- lt_cv_sys_max_cmd_len=102400
- ;;
- sysv5* | sco5v6* | sysv4.2uw2*)
- kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
- if test -n "$kargmax"; then
- lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[ ]//'`
- else
- lt_cv_sys_max_cmd_len=32768
- fi
- ;;
- *)
- lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null`
- if test -n "$lt_cv_sys_max_cmd_len"; then
- lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
- lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
- else
- # Make teststring a little bigger before we do anything with it.
- # a 1K string should be a reasonable start.
- for i in 1 2 3 4 5 6 7 8 ; do
- teststring=$teststring$teststring
- done
- SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
- # If test is not a shell built-in, we'll probably end up computing a
- # maximum length that is only half of the actual maximum length, but
- # we can't tell.
- while { test "X"`func_fallback_echo "$teststring$teststring" 2>/dev/null` \
- = "X$teststring$teststring"; } >/dev/null 2>&1 &&
- test $i != 17 # 1/2 MB should be enough
- do
- i=`expr $i + 1`
- teststring=$teststring$teststring
- done
- # Only check the string length outside the loop.
- lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1`
- teststring=
- # Add a significant safety factor because C++ compilers can tack on
- # massive amounts of additional arguments before passing them to the
- # linker. It appears as though 1/2 is a usable value.
- lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
- fi
- ;;
- esac
-
-fi
-
-if test -n $lt_cv_sys_max_cmd_len ; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sys_max_cmd_len" >&5
-$as_echo "$lt_cv_sys_max_cmd_len" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: none" >&5
-$as_echo "none" >&6; }
-fi
-max_cmd_len=$lt_cv_sys_max_cmd_len
-
-
-
-
-
-
-: ${CP="cp -f"}
-: ${MV="mv -f"}
-: ${RM="rm -f"}
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the shell understands some XSI constructs" >&5
-$as_echo_n "checking whether the shell understands some XSI constructs... " >&6; }
-# Try some XSI features
-xsi_shell=no
-( _lt_dummy="a/b/c"
- test "${_lt_dummy##*/},${_lt_dummy%/*},"${_lt_dummy%"$_lt_dummy"}, \
- = c,a/b,, \
- && eval 'test $(( 1 + 1 )) -eq 2 \
- && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \
- && xsi_shell=yes
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $xsi_shell" >&5
-$as_echo "$xsi_shell" >&6; }
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the shell understands \"+=\"" >&5
-$as_echo_n "checking whether the shell understands \"+=\"... " >&6; }
-lt_shell_append=no
-( foo=bar; set foo baz; eval "$1+=\$2" && test "$foo" = barbaz ) \
- >/dev/null 2>&1 \
- && lt_shell_append=yes
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_shell_append" >&5
-$as_echo "$lt_shell_append" >&6; }
-
-
-if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
- lt_unset=unset
-else
- lt_unset=false
-fi
-
-
-
-
-
-# test EBCDIC or ASCII
-case `echo X|tr X '\101'` in
- A) # ASCII based system
- # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr
- lt_SP2NL='tr \040 \012'
- lt_NL2SP='tr \015\012 \040\040'
- ;;
- *) # EBCDIC based system
- lt_SP2NL='tr \100 \n'
- lt_NL2SP='tr \r\n \100\100'
- ;;
-esac
-
-
-
-
-
-
-
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5
-$as_echo_n "checking for $LD option to reload object files... " >&6; }
-if ${lt_cv_ld_reload_flag+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_ld_reload_flag='-r'
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_reload_flag" >&5
-$as_echo "$lt_cv_ld_reload_flag" >&6; }
-reload_flag=$lt_cv_ld_reload_flag
-case $reload_flag in
-"" | " "*) ;;
-*) reload_flag=" $reload_flag" ;;
-esac
-reload_cmds='$LD$reload_flag -o $output$reload_objs'
-case $host_os in
- darwin*)
- if test "$GCC" = yes; then
- reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
- else
- reload_cmds='$LD$reload_flag -o $output$reload_objs'
- fi
- ;;
-esac
-
-
-
-
-
-
-
-
-
-if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args.
-set dummy ${ac_tool_prefix}objdump; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_OBJDUMP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$OBJDUMP"; then
- ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-OBJDUMP=$ac_cv_prog_OBJDUMP
-if test -n "$OBJDUMP"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
-$as_echo "$OBJDUMP" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_OBJDUMP"; then
- ac_ct_OBJDUMP=$OBJDUMP
- # Extract the first word of "objdump", so it can be a program name with args.
-set dummy objdump; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_OBJDUMP"; then
- ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_OBJDUMP="objdump"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP
-if test -n "$ac_ct_OBJDUMP"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5
-$as_echo "$ac_ct_OBJDUMP" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_OBJDUMP" = x; then
- OBJDUMP="false"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- OBJDUMP=$ac_ct_OBJDUMP
- fi
-else
- OBJDUMP="$ac_cv_prog_OBJDUMP"
-fi
-
-test -z "$OBJDUMP" && OBJDUMP=objdump
-
-
-
-
-
-
-
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to recognize dependent libraries" >&5
-$as_echo_n "checking how to recognize dependent libraries... " >&6; }
-if ${lt_cv_deplibs_check_method+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_file_magic_cmd='$MAGIC_CMD'
-lt_cv_file_magic_test_file=
-lt_cv_deplibs_check_method='unknown'
-# Need to set the preceding variable on all platforms that support
-# interlibrary dependencies.
-# 'none' -- dependencies not supported.
-# `unknown' -- same as none, but documents that we really don't know.
-# 'pass_all' -- all dependencies passed with no checks.
-# 'test_compile' -- check by making test program.
-# 'file_magic [[regex]]' -- check by looking for files in library path
-# which responds to the $file_magic_cmd with a given extended regex.
-# If you have `file' or equivalent on your system and you're not sure
-# whether `pass_all' will *always* work, you probably want this one.
-
-case $host_os in
-aix[4-9]*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-beos*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-bsdi[45]*)
- lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)'
- lt_cv_file_magic_cmd='/usr/bin/file -L'
- lt_cv_file_magic_test_file=/shlib/libc.so
- ;;
-
-cygwin*)
- # func_win32_libid is a shell function defined in ltmain.sh
- lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
- lt_cv_file_magic_cmd='func_win32_libid'
- ;;
-
-mingw* | pw32*)
- # Base MSYS/MinGW do not provide the 'file' command needed by
- # func_win32_libid shell function, so use a weaker test based on 'objdump',
- # unless we find 'file', for example because we are cross-compiling.
- # func_win32_libid assumes BSD nm, so disallow it if using MS dumpbin.
- if ( test "$lt_cv_nm_interface" = "BSD nm" && file / ) >/dev/null 2>&1; then
- lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
- lt_cv_file_magic_cmd='func_win32_libid'
- else
- lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
- lt_cv_file_magic_cmd='$OBJDUMP -f'
- fi
- ;;
-
-cegcc*)
- # use the weaker test based on 'objdump'. See mingw*.
- lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?'
- lt_cv_file_magic_cmd='$OBJDUMP -f'
- ;;
-
-darwin* | rhapsody*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-freebsd* | dragonfly*)
- if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
- case $host_cpu in
- i*86 )
- # Not sure whether the presence of OpenBSD here was a mistake.
- # Let's accept both of them until this is cleared up.
- lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library'
- lt_cv_file_magic_cmd=/usr/bin/file
- lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
- ;;
- esac
- else
- lt_cv_deplibs_check_method=pass_all
- fi
- ;;
-
-gnu*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-haiku*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-hpux10.20* | hpux11*)
- lt_cv_file_magic_cmd=/usr/bin/file
- case $host_cpu in
- ia64*)
- lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64'
- lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
- ;;
- hppa*64*)
- lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF[ -][0-9][0-9])(-bit)?( [LM]SB)? shared object( file)?[, -]* PA-RISC [0-9]\.[0-9]'
- lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
- ;;
- *)
- lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9]\.[0-9]) shared library'
- lt_cv_file_magic_test_file=/usr/lib/libc.sl
- ;;
- esac
- ;;
-
-interix[3-9]*)
- # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
- lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|\.a)$'
- ;;
-
-irix5* | irix6* | nonstopux*)
- case $LD in
- *-32|*"-32 ") libmagic=32-bit;;
- *-n32|*"-n32 ") libmagic=N32;;
- *-64|*"-64 ") libmagic=64-bit;;
- *) libmagic=never-match;;
- esac
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-# This must be Linux ELF.
-linux* | k*bsd*-gnu | kopensolaris*-gnu | uclinuxfdpiceabi)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-netbsd*)
- if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
- lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
- else
- lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$'
- fi
- ;;
-
-newos6*)
- lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)'
- lt_cv_file_magic_cmd=/usr/bin/file
- lt_cv_file_magic_test_file=/usr/lib/libnls.so
- ;;
-
-*nto* | *qnx*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-openbsd*)
- if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
- lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$'
- else
- lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
- fi
- ;;
-
-osf3* | osf4* | osf5*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-rdos*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-solaris*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-sysv4 | sysv4.3*)
- case $host_vendor in
- motorola)
- lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib) M[0-9][0-9]* Version [0-9]'
- lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
- ;;
- ncr)
- lt_cv_deplibs_check_method=pass_all
- ;;
- sequent)
- lt_cv_file_magic_cmd='/bin/file'
- lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )'
- ;;
- sni)
- lt_cv_file_magic_cmd='/bin/file'
- lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib"
- lt_cv_file_magic_test_file=/lib/libc.so
- ;;
- siemens)
- lt_cv_deplibs_check_method=pass_all
- ;;
- pc)
- lt_cv_deplibs_check_method=pass_all
- ;;
- esac
- ;;
-
-tpf*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-vxworks*)
- # Assume VxWorks cross toolchains are built on Linux, possibly
- # as canadian for Windows hosts.
- lt_cv_deplibs_check_method=pass_all
- ;;
-esac
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5
-$as_echo "$lt_cv_deplibs_check_method" >&6; }
-file_magic_cmd=$lt_cv_file_magic_cmd
-deplibs_check_method=$lt_cv_deplibs_check_method
-test -z "$deplibs_check_method" && deplibs_check_method=unknown
-
-
-
-
-
-
-
-
-
-
-
-
-plugin_option=
-plugin_names="liblto_plugin.so liblto_plugin-0.dll cyglto_plugin-0.dll"
-for plugin in $plugin_names; do
- plugin_so=`${CC} ${CFLAGS} --print-prog-name $plugin`
- if test x$plugin_so = x$plugin; then
- plugin_so=`${CC} ${CFLAGS} --print-file-name $plugin`
- fi
- if test x$plugin_so != x$plugin; then
- plugin_option="--plugin $plugin_so"
- break
- fi
-done
-
-if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
-set dummy ${ac_tool_prefix}ar; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_AR+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$AR"; then
- ac_cv_prog_AR="$AR" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_AR="${ac_tool_prefix}ar"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-AR=$ac_cv_prog_AR
-if test -n "$AR"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
-$as_echo "$AR" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_AR"; then
- ac_ct_AR=$AR
- # Extract the first word of "ar", so it can be a program name with args.
-set dummy ar; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_AR+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_AR"; then
- ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_AR="ar"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_AR=$ac_cv_prog_ac_ct_AR
-if test -n "$ac_ct_AR"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
-$as_echo "$ac_ct_AR" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_AR" = x; then
- AR="false"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- AR=$ac_ct_AR
- fi
-else
- AR="$ac_cv_prog_AR"
-fi
-
-test -z "$AR" && AR=ar
-if test -n "$plugin_option"; then
- if $AR --help 2>&1 | grep -q "\--plugin"; then
- touch conftest.c
- $AR $plugin_option rc conftest.a conftest.c
- if test "$?" != 0; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed: $AR $plugin_option rc" >&5
-$as_echo "$as_me: WARNING: Failed: $AR $plugin_option rc" >&2;}
- else
- AR="$AR $plugin_option"
- fi
- rm -f conftest.*
- fi
-fi
-test -z "$AR_FLAGS" && AR_FLAGS=cru
-
-
-
-
-
-
-
-
-
-
-
-if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
-set dummy ${ac_tool_prefix}strip; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_STRIP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$STRIP"; then
- ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_STRIP="${ac_tool_prefix}strip"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-STRIP=$ac_cv_prog_STRIP
-if test -n "$STRIP"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
-$as_echo "$STRIP" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_STRIP"; then
- ac_ct_STRIP=$STRIP
- # Extract the first word of "strip", so it can be a program name with args.
-set dummy strip; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_STRIP"; then
- ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_STRIP="strip"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
-if test -n "$ac_ct_STRIP"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
-$as_echo "$ac_ct_STRIP" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_STRIP" = x; then
- STRIP=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- STRIP=$ac_ct_STRIP
- fi
-else
- STRIP="$ac_cv_prog_STRIP"
-fi
-
-test -z "$STRIP" && STRIP=:
-
-
-
-
-
-
-if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
-set dummy ${ac_tool_prefix}ranlib; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_RANLIB+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$RANLIB"; then
- ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-RANLIB=$ac_cv_prog_RANLIB
-if test -n "$RANLIB"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
-$as_echo "$RANLIB" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_RANLIB"; then
- ac_ct_RANLIB=$RANLIB
- # Extract the first word of "ranlib", so it can be a program name with args.
-set dummy ranlib; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_RANLIB"; then
- ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_RANLIB="ranlib"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
-if test -n "$ac_ct_RANLIB"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
-$as_echo "$ac_ct_RANLIB" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_RANLIB" = x; then
- RANLIB=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- RANLIB=$ac_ct_RANLIB
- fi
-else
- RANLIB="$ac_cv_prog_RANLIB"
-fi
-
-test -z "$RANLIB" && RANLIB=:
-if test -n "$plugin_option" && test "$RANLIB" != ":"; then
- if $RANLIB --help 2>&1 | grep -q "\--plugin"; then
- RANLIB="$RANLIB $plugin_option"
- fi
-fi
-
-
-
-
-
-
-# Determine commands to create old-style static archives.
-old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs'
-old_postinstall_cmds='chmod 644 $oldlib'
-old_postuninstall_cmds=
-
-if test -n "$RANLIB"; then
- case $host_os in
- openbsd*)
- old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib"
- ;;
- *)
- old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib"
- ;;
- esac
- old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib"
-fi
-
-case $host_os in
- darwin*)
- lock_old_archive_extraction=yes ;;
- *)
- lock_old_archive_extraction=no ;;
-esac
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-# If no C compiler was specified, use CC.
-LTCC=${LTCC-"$CC"}
-
-# If no C compiler flags were specified, use CFLAGS.
-LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
-
-# Allow CC to be a program name with arguments.
-compiler=$CC
-
-
-# Check for command to grab the raw symbol name followed by C symbol from nm.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking command to parse $NM output from $compiler object" >&5
-$as_echo_n "checking command to parse $NM output from $compiler object... " >&6; }
-if ${lt_cv_sys_global_symbol_pipe+:} false; then :
- $as_echo_n "(cached) " >&6
-else
-
-# These are sane defaults that work on at least a few old systems.
-# [They come from Ultrix. What could be older than Ultrix?!! ;)]
-
-# Character class describing NM global symbol codes.
-symcode='[BCDEGRST]'
-
-# Regexp to match symbols that can be accessed directly from C.
-sympat='\([_A-Za-z][_A-Za-z0-9]*\)'
-
-# Define system-specific variables.
-case $host_os in
-aix*)
- symcode='[BCDT]'
- ;;
-cygwin* | mingw* | pw32* | cegcc*)
- symcode='[ABCDGISTW]'
- ;;
-hpux*)
- if test "$host_cpu" = ia64; then
- symcode='[ABCDEGRST]'
- fi
- ;;
-irix* | nonstopux*)
- symcode='[BCDEGRST]'
- ;;
-osf*)
- symcode='[BCDEGQRST]'
- ;;
-solaris*)
- symcode='[BCDRT]'
- ;;
-sco3.2v5*)
- symcode='[DT]'
- ;;
-sysv4.2uw2*)
- symcode='[DT]'
- ;;
-sysv5* | sco5v6* | unixware* | OpenUNIX*)
- symcode='[ABDT]'
- ;;
-sysv4)
- symcode='[DFNSTU]'
- ;;
-esac
-
-# If we're using GNU nm, then use its standard symbol codes.
-case `$NM -V 2>&1` in
-*GNU* | *'with BFD'*)
- symcode='[ABCDGIRSTW]' ;;
-esac
-
-# Transform an extracted symbol line into a proper C declaration.
-# Some systems (esp. on ia64) link data and code symbols differently,
-# so use this general approach.
-lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
-
-# Transform an extracted symbol line into symbol name and symbol address
-lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"\2\", (void *) \&\2},/p'"
-lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \(lib[^ ]*\)$/ {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"lib\2\", (void *) \&\2},/p'"
-
-# Handle CRLF in mingw tool chain
-opt_cr=
-case $build_os in
-mingw*)
- opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp
- ;;
-esac
-
-# Try without a prefix underscore, then with it.
-for ac_symprfx in "" "_"; do
-
- # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
- symxfrm="\\1 $ac_symprfx\\2 \\2"
-
- # Write the raw and C identifiers.
- if test "$lt_cv_nm_interface" = "MS dumpbin"; then
- # Fake it for dumpbin and say T for any non-static function
- # and D for any global variable.
- # Also find C++ and __fastcall symbols from MSVC++,
- # which start with @ or ?.
- lt_cv_sys_global_symbol_pipe="$AWK '"\
-" {last_section=section; section=\$ 3};"\
-" /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\
-" \$ 0!~/External *\|/{next};"\
-" / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\
-" {if(hide[section]) next};"\
-" {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\
-" {split(\$ 0, a, /\||\r/); split(a[2], s)};"\
-" s[1]~/^[@?]/{print s[1], s[1]; next};"\
-" s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\
-" ' prfx=^$ac_symprfx"
- else
- lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[ ]\($symcode$symcode*\)[ ][ ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
- fi
-
- # Check to see that the pipe works correctly.
- pipe_works=no
-
- rm -f conftest*
- cat > conftest.$ac_ext <<_LT_EOF
-#ifdef __cplusplus
-extern "C" {
-#endif
-char nm_test_var;
-void nm_test_func(void);
-void nm_test_func(void){}
-#ifdef __cplusplus
-}
-#endif
-int main(){nm_test_var='a';nm_test_func();return(0);}
-_LT_EOF
-
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
- (eval $ac_compile) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- # Now try to grab the symbols.
- nlist=conftest.nm
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist\""; } >&5
- (eval $NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && test -s "$nlist"; then
- # Try sorting and uniquifying the output.
- if sort "$nlist" | uniq > "$nlist"T; then
- mv -f "$nlist"T "$nlist"
- else
- rm -f "$nlist"T
- fi
-
- # Make sure that we snagged all the symbols we need.
- if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
- if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
- cat <<_LT_EOF > conftest.$ac_ext
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-_LT_EOF
- # Now generate the symbol file.
- eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext'
-
- cat <<_LT_EOF >> conftest.$ac_ext
-
-/* The mapping between symbol names and symbols. */
-const struct {
- const char *name;
- void *address;
-}
-lt__PROGRAM__LTX_preloaded_symbols[] =
-{
- { "@PROGRAM@", (void *) 0 },
-_LT_EOF
- $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext
- cat <<\_LT_EOF >> conftest.$ac_ext
- {0, (void *) 0}
-};
-
-/* This works around a problem in FreeBSD linker */
-#ifdef FREEBSD_WORKAROUND
-static const void *lt_preloaded_setup() {
- return lt__PROGRAM__LTX_preloaded_symbols;
-}
-#endif
-
-#ifdef __cplusplus
-}
-#endif
-_LT_EOF
- # Now try linking the two files.
- mv conftest.$ac_objext conftstm.$ac_objext
- lt_save_LIBS="$LIBS"
- lt_save_CFLAGS="$CFLAGS"
- LIBS="conftstm.$ac_objext"
- CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag"
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
- (eval $ac_link) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && test -s conftest${ac_exeext}; then
- pipe_works=yes
- fi
- LIBS="$lt_save_LIBS"
- CFLAGS="$lt_save_CFLAGS"
- else
- echo "cannot find nm_test_func in $nlist" >&5
- fi
- else
- echo "cannot find nm_test_var in $nlist" >&5
- fi
- else
- echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5
- fi
- else
- echo "$progname: failed program was:" >&5
- cat conftest.$ac_ext >&5
- fi
- rm -rf conftest* conftst*
-
- # Do not use the global_symbol_pipe unless it works.
- if test "$pipe_works" = yes; then
- break
- else
- lt_cv_sys_global_symbol_pipe=
- fi
-done
-
-fi
-
-if test -z "$lt_cv_sys_global_symbol_pipe"; then
- lt_cv_sys_global_symbol_to_cdecl=
-fi
-if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
-$as_echo "failed" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
-$as_echo "ok" >&6; }
-fi
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-# Check whether --enable-libtool-lock was given.
-if test "${enable_libtool_lock+set}" = set; then :
- enableval=$enable_libtool_lock;
-fi
-
-test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
-
-# Some flags need to be propagated to the compiler or linker for good
-# libtool support.
-case $host in
-ia64-*-hpux*)
- # Find out which ABI we are using.
- echo 'int i;' > conftest.$ac_ext
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
- (eval $ac_compile) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- case `/usr/bin/file conftest.$ac_objext` in
- *ELF-32*)
- HPUX_IA64_MODE="32"
- ;;
- *ELF-64*)
- HPUX_IA64_MODE="64"
- ;;
- esac
- fi
- rm -rf conftest*
- ;;
-*-*-irix6*)
- # Find out which ABI we are using.
- echo '#line '$LINENO' "configure"' > conftest.$ac_ext
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
- (eval $ac_compile) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- if test "$lt_cv_prog_gnu_ld" = yes; then
- case `/usr/bin/file conftest.$ac_objext` in
- *32-bit*)
- LD="${LD-ld} -melf32bsmip"
- ;;
- *N32*)
- LD="${LD-ld} -melf32bmipn32"
- ;;
- *64-bit*)
- LD="${LD-ld} -melf64bmip"
- ;;
- esac
- else
- case `/usr/bin/file conftest.$ac_objext` in
- *32-bit*)
- LD="${LD-ld} -32"
- ;;
- *N32*)
- LD="${LD-ld} -n32"
- ;;
- *64-bit*)
- LD="${LD-ld} -64"
- ;;
- esac
- fi
- fi
- rm -rf conftest*
- ;;
-
-x86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \
-s390*-*linux*|s390*-*tpf*|sparc*-*linux*)
- # Find out which ABI we are using.
- echo 'int i;' > conftest.$ac_ext
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
- (eval $ac_compile) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- case `/usr/bin/file conftest.o` in
- *32-bit*)
- case $host in
- x86_64-*kfreebsd*-gnu)
- LD="${LD-ld} -m elf_i386_fbsd"
- ;;
- x86_64-*linux*)
- case `/usr/bin/file conftest.o` in
- *x86-64*)
- LD="${LD-ld} -m elf32_x86_64"
- ;;
- *)
- LD="${LD-ld} -m elf_i386"
- ;;
- esac
- ;;
- powerpc64le-*linux*)
- LD="${LD-ld} -m elf32lppclinux"
- ;;
- powerpc64-*linux*)
- LD="${LD-ld} -m elf32ppclinux"
- ;;
- s390x-*linux*)
- LD="${LD-ld} -m elf_s390"
- ;;
- sparc64-*linux*)
- LD="${LD-ld} -m elf32_sparc"
- ;;
- esac
- ;;
- *64-bit*)
- case $host in
- x86_64-*kfreebsd*-gnu)
- LD="${LD-ld} -m elf_x86_64_fbsd"
- ;;
- x86_64-*linux*)
- LD="${LD-ld} -m elf_x86_64"
- ;;
- powerpcle-*linux*)
- LD="${LD-ld} -m elf64lppc"
- ;;
- powerpc-*linux*)
- LD="${LD-ld} -m elf64ppc"
- ;;
- s390*-*linux*|s390*-*tpf*)
- LD="${LD-ld} -m elf64_s390"
- ;;
- sparc*-*linux*)
- LD="${LD-ld} -m elf64_sparc"
- ;;
- esac
- ;;
- esac
- fi
- rm -rf conftest*
- ;;
-
-*-*-sco3.2v5*)
- # On SCO OpenServer 5, we need -belf to get full-featured binaries.
- SAVE_CFLAGS="$CFLAGS"
- CFLAGS="$CFLAGS -belf"
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler needs -belf" >&5
-$as_echo_n "checking whether the C compiler needs -belf... " >&6; }
-if ${lt_cv_cc_needs_belf+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- lt_cv_cc_needs_belf=yes
-else
- lt_cv_cc_needs_belf=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_cc_needs_belf" >&5
-$as_echo "$lt_cv_cc_needs_belf" >&6; }
- if test x"$lt_cv_cc_needs_belf" != x"yes"; then
- # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
- CFLAGS="$SAVE_CFLAGS"
- fi
- ;;
-sparc*-*solaris*)
- # Find out which ABI we are using.
- echo 'int i;' > conftest.$ac_ext
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
- (eval $ac_compile) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- case `/usr/bin/file conftest.o` in
- *64-bit*)
- case $lt_cv_prog_gnu_ld in
- yes*) LD="${LD-ld} -m elf64_sparc" ;;
- *)
- if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then
- LD="${LD-ld} -64"
- fi
- ;;
- esac
- ;;
- esac
- fi
- rm -rf conftest*
- ;;
-esac
-
-need_locks="$enable_libtool_lock"
-
-
- case $host_os in
- rhapsody* | darwin*)
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}dsymutil", so it can be a program name with args.
-set dummy ${ac_tool_prefix}dsymutil; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_DSYMUTIL+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$DSYMUTIL"; then
- ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_DSYMUTIL="${ac_tool_prefix}dsymutil"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-DSYMUTIL=$ac_cv_prog_DSYMUTIL
-if test -n "$DSYMUTIL"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5
-$as_echo "$DSYMUTIL" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_DSYMUTIL"; then
- ac_ct_DSYMUTIL=$DSYMUTIL
- # Extract the first word of "dsymutil", so it can be a program name with args.
-set dummy dsymutil; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_DSYMUTIL+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_DSYMUTIL"; then
- ac_cv_prog_ac_ct_DSYMUTIL="$ac_ct_DSYMUTIL" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_DSYMUTIL="dsymutil"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_DSYMUTIL=$ac_cv_prog_ac_ct_DSYMUTIL
-if test -n "$ac_ct_DSYMUTIL"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DSYMUTIL" >&5
-$as_echo "$ac_ct_DSYMUTIL" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_DSYMUTIL" = x; then
- DSYMUTIL=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- DSYMUTIL=$ac_ct_DSYMUTIL
- fi
-else
- DSYMUTIL="$ac_cv_prog_DSYMUTIL"
-fi
-
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}nmedit", so it can be a program name with args.
-set dummy ${ac_tool_prefix}nmedit; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_NMEDIT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$NMEDIT"; then
- ac_cv_prog_NMEDIT="$NMEDIT" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_NMEDIT="${ac_tool_prefix}nmedit"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-NMEDIT=$ac_cv_prog_NMEDIT
-if test -n "$NMEDIT"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NMEDIT" >&5
-$as_echo "$NMEDIT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_NMEDIT"; then
- ac_ct_NMEDIT=$NMEDIT
- # Extract the first word of "nmedit", so it can be a program name with args.
-set dummy nmedit; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_NMEDIT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_NMEDIT"; then
- ac_cv_prog_ac_ct_NMEDIT="$ac_ct_NMEDIT" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_NMEDIT="nmedit"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_NMEDIT=$ac_cv_prog_ac_ct_NMEDIT
-if test -n "$ac_ct_NMEDIT"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NMEDIT" >&5
-$as_echo "$ac_ct_NMEDIT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_NMEDIT" = x; then
- NMEDIT=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- NMEDIT=$ac_ct_NMEDIT
- fi
-else
- NMEDIT="$ac_cv_prog_NMEDIT"
-fi
-
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}lipo", so it can be a program name with args.
-set dummy ${ac_tool_prefix}lipo; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_LIPO+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$LIPO"; then
- ac_cv_prog_LIPO="$LIPO" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_LIPO="${ac_tool_prefix}lipo"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-LIPO=$ac_cv_prog_LIPO
-if test -n "$LIPO"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5
-$as_echo "$LIPO" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_LIPO"; then
- ac_ct_LIPO=$LIPO
- # Extract the first word of "lipo", so it can be a program name with args.
-set dummy lipo; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_LIPO+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_LIPO"; then
- ac_cv_prog_ac_ct_LIPO="$ac_ct_LIPO" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_LIPO="lipo"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_LIPO=$ac_cv_prog_ac_ct_LIPO
-if test -n "$ac_ct_LIPO"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LIPO" >&5
-$as_echo "$ac_ct_LIPO" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_LIPO" = x; then
- LIPO=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- LIPO=$ac_ct_LIPO
- fi
-else
- LIPO="$ac_cv_prog_LIPO"
-fi
-
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}otool", so it can be a program name with args.
-set dummy ${ac_tool_prefix}otool; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_OTOOL+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$OTOOL"; then
- ac_cv_prog_OTOOL="$OTOOL" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_OTOOL="${ac_tool_prefix}otool"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-OTOOL=$ac_cv_prog_OTOOL
-if test -n "$OTOOL"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5
-$as_echo "$OTOOL" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_OTOOL"; then
- ac_ct_OTOOL=$OTOOL
- # Extract the first word of "otool", so it can be a program name with args.
-set dummy otool; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_OTOOL+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_OTOOL"; then
- ac_cv_prog_ac_ct_OTOOL="$ac_ct_OTOOL" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_OTOOL="otool"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_OTOOL=$ac_cv_prog_ac_ct_OTOOL
-if test -n "$ac_ct_OTOOL"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL" >&5
-$as_echo "$ac_ct_OTOOL" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_OTOOL" = x; then
- OTOOL=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- OTOOL=$ac_ct_OTOOL
- fi
-else
- OTOOL="$ac_cv_prog_OTOOL"
-fi
-
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}otool64", so it can be a program name with args.
-set dummy ${ac_tool_prefix}otool64; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_OTOOL64+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$OTOOL64"; then
- ac_cv_prog_OTOOL64="$OTOOL64" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_OTOOL64="${ac_tool_prefix}otool64"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-OTOOL64=$ac_cv_prog_OTOOL64
-if test -n "$OTOOL64"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL64" >&5
-$as_echo "$OTOOL64" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_OTOOL64"; then
- ac_ct_OTOOL64=$OTOOL64
- # Extract the first word of "otool64", so it can be a program name with args.
-set dummy otool64; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_OTOOL64+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_OTOOL64"; then
- ac_cv_prog_ac_ct_OTOOL64="$ac_ct_OTOOL64" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_OTOOL64="otool64"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_OTOOL64=$ac_cv_prog_ac_ct_OTOOL64
-if test -n "$ac_ct_OTOOL64"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL64" >&5
-$as_echo "$ac_ct_OTOOL64" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_OTOOL64" = x; then
- OTOOL64=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- OTOOL64=$ac_ct_OTOOL64
- fi
-else
- OTOOL64="$ac_cv_prog_OTOOL64"
-fi
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -single_module linker flag" >&5
-$as_echo_n "checking for -single_module linker flag... " >&6; }
-if ${lt_cv_apple_cc_single_mod+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_apple_cc_single_mod=no
- if test -z "${LT_MULTI_MODULE}"; then
- # By default we will add the -single_module flag. You can override
- # by either setting the environment variable LT_MULTI_MODULE
- # non-empty at configure time, or by adding -multi_module to the
- # link flags.
- rm -rf libconftest.dylib*
- echo "int foo(void){return 1;}" > conftest.c
- echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
--dynamiclib -Wl,-single_module conftest.c" >&5
- $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
- -dynamiclib -Wl,-single_module conftest.c 2>conftest.err
- _lt_result=$?
- if test -f libconftest.dylib && test ! -s conftest.err && test $_lt_result = 0; then
- lt_cv_apple_cc_single_mod=yes
- else
- cat conftest.err >&5
- fi
- rm -rf libconftest.dylib*
- rm -f conftest.*
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_apple_cc_single_mod" >&5
-$as_echo "$lt_cv_apple_cc_single_mod" >&6; }
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -exported_symbols_list linker flag" >&5
-$as_echo_n "checking for -exported_symbols_list linker flag... " >&6; }
-if ${lt_cv_ld_exported_symbols_list+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_ld_exported_symbols_list=no
- save_LDFLAGS=$LDFLAGS
- echo "_main" > conftest.sym
- LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- lt_cv_ld_exported_symbols_list=yes
-else
- lt_cv_ld_exported_symbols_list=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LDFLAGS="$save_LDFLAGS"
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_exported_symbols_list" >&5
-$as_echo "$lt_cv_ld_exported_symbols_list" >&6; }
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -force_load linker flag" >&5
-$as_echo_n "checking for -force_load linker flag... " >&6; }
-if ${lt_cv_ld_force_load+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_ld_force_load=no
- cat > conftest.c << _LT_EOF
-int forced_loaded() { return 2;}
-_LT_EOF
- echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&5
- $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5
- echo "$AR cru libconftest.a conftest.o" >&5
- $AR cru libconftest.a conftest.o 2>&5
- cat > conftest.c << _LT_EOF
-int main() { return 0;}
-_LT_EOF
- echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&5
- $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err
- _lt_result=$?
- if test -f conftest && test ! -s conftest.err && test $_lt_result = 0 && $GREP forced_load conftest 2>&1 >/dev/null; then
- lt_cv_ld_force_load=yes
- else
- cat conftest.err >&5
- fi
- rm -f conftest.err libconftest.a conftest conftest.c
- rm -rf conftest.dSYM
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_force_load" >&5
-$as_echo "$lt_cv_ld_force_load" >&6; }
- # Allow for Darwin 4-7 (macOS 10.0-10.3) although these are not expect to
- # build without first building modern cctools / linker.
- case $host_cpu-$host_os in
- *-rhapsody* | *-darwin1.[012])
- _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;;
- *-darwin1.*)
- _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
- *-darwin*)
- # darwin 5.x (macOS 10.1) onwards we only need to adjust when the
- # deployment target is forced to an earlier version.
- case ${MACOSX_DEPLOYMENT_TARGET-UNSET},$host in
- UNSET,*-darwin[89]*|UNSET,*-darwin[12][0123456789]*)
- ;;
- 10.[012][,.]*)
- _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
- ;;
- *)
- ;;
- esac
- ;;
- esac
- if test "$lt_cv_apple_cc_single_mod" = "yes"; then
- _lt_dar_single_mod='$single_module'
- fi
- if test "$lt_cv_ld_exported_symbols_list" = "yes"; then
- _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym'
- else
- _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}'
- fi
- if test "$DSYMUTIL" != ":" && test "$lt_cv_ld_force_load" = "no"; then
- _lt_dsymutil='~$DSYMUTIL $lib || :'
- else
- _lt_dsymutil=
- fi
- ;;
- esac
-
-for ac_header in dlfcn.h
-do :
- ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default
-"
-if test "x$ac_cv_header_dlfcn_h" = xyes; then :
- cat >>confdefs.h <<_ACEOF
-#define HAVE_DLFCN_H 1
-_ACEOF
-
-fi
-
-done
-
-
-
-
-
-# Set options
-
-
-
- enable_dlopen=no
-
-
- enable_win32_dll=no
-
-
- # Check whether --enable-shared was given.
-if test "${enable_shared+set}" = set; then :
- enableval=$enable_shared; p=${PACKAGE-default}
- case $enableval in
- yes) enable_shared=yes ;;
- no) enable_shared=no ;;
- *)
- enable_shared=no
- # Look at the argument we got. We use all the common list separators.
- lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
- for pkg in $enableval; do
- IFS="$lt_save_ifs"
- if test "X$pkg" = "X$p"; then
- enable_shared=yes
- fi
- done
- IFS="$lt_save_ifs"
- ;;
- esac
-else
- enable_shared=yes
-fi
-
-
-
-
-
-
-
-
-
- # Check whether --enable-static was given.
-if test "${enable_static+set}" = set; then :
- enableval=$enable_static; p=${PACKAGE-default}
- case $enableval in
- yes) enable_static=yes ;;
- no) enable_static=no ;;
- *)
- enable_static=no
- # Look at the argument we got. We use all the common list separators.
- lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
- for pkg in $enableval; do
- IFS="$lt_save_ifs"
- if test "X$pkg" = "X$p"; then
- enable_static=yes
- fi
- done
- IFS="$lt_save_ifs"
- ;;
- esac
-else
- enable_static=yes
-fi
-
-
-
-
-
-
-
-
-
-
-# Check whether --with-pic was given.
-if test "${with_pic+set}" = set; then :
- withval=$with_pic; pic_mode="$withval"
-else
- pic_mode=default
-fi
-
-
-test -z "$pic_mode" && pic_mode=default
-
-
-
-
-
-
-
- # Check whether --enable-fast-install was given.
-if test "${enable_fast_install+set}" = set; then :
- enableval=$enable_fast_install; p=${PACKAGE-default}
- case $enableval in
- yes) enable_fast_install=yes ;;
- no) enable_fast_install=no ;;
- *)
- enable_fast_install=no
- # Look at the argument we got. We use all the common list separators.
- lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
- for pkg in $enableval; do
- IFS="$lt_save_ifs"
- if test "X$pkg" = "X$p"; then
- enable_fast_install=yes
- fi
- done
- IFS="$lt_save_ifs"
- ;;
- esac
-else
- enable_fast_install=yes
-fi
-
-
-
-
-
-
-
-
-
-
-
-# This can be used to rebuild libtool when needed
-LIBTOOL_DEPS="$ltmain"
-
-# Always use our own libtool.
-LIBTOOL='$(SHELL) $(top_builddir)/libtool'
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-test -z "$LN_S" && LN_S="ln -s"
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-if test -n "${ZSH_VERSION+set}" ; then
- setopt NO_GLOB_SUBST
-fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for objdir" >&5
-$as_echo_n "checking for objdir... " >&6; }
-if ${lt_cv_objdir+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- rm -f .libs 2>/dev/null
-mkdir .libs 2>/dev/null
-if test -d .libs; then
- lt_cv_objdir=.libs
-else
- # MS-DOS does not allow filenames that begin with a dot.
- lt_cv_objdir=_libs
-fi
-rmdir .libs 2>/dev/null
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_objdir" >&5
-$as_echo "$lt_cv_objdir" >&6; }
-objdir=$lt_cv_objdir
-
-
-
-
-
-cat >>confdefs.h <<_ACEOF
-#define LT_OBJDIR "$lt_cv_objdir/"
-_ACEOF
-
-
-
-
-case $host_os in
-aix3*)
- # AIX sometimes has problems with the GCC collect2 program. For some
- # reason, if we set the COLLECT_NAMES environment variable, the problems
- # vanish in a puff of smoke.
- if test "X${COLLECT_NAMES+set}" != Xset; then
- COLLECT_NAMES=
- export COLLECT_NAMES
- fi
- ;;
-esac
-
-# Global variables:
-ofile=libtool
-can_build_shared=yes
-
-# All known linkers require a `.a' archive for static linking (except MSVC,
-# which needs '.lib').
-libext=a
-
-with_gnu_ld="$lt_cv_prog_gnu_ld"
-
-old_CC="$CC"
-old_CFLAGS="$CFLAGS"
-
-# Set sane defaults for various variables
-test -z "$CC" && CC=cc
-test -z "$LTCC" && LTCC=$CC
-test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
-test -z "$LD" && LD=ld
-test -z "$ac_objext" && ac_objext=o
-
-for cc_temp in $compiler""; do
- case $cc_temp in
- compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
- distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
- \-*) ;;
- *) break;;
- esac
-done
-cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
-
-
-# Only perform the check for file, if the check method requires it
-test -z "$MAGIC_CMD" && MAGIC_CMD=file
-case $deplibs_check_method in
-file_magic*)
- if test "$file_magic_cmd" = '$MAGIC_CMD'; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ac_tool_prefix}file" >&5
-$as_echo_n "checking for ${ac_tool_prefix}file... " >&6; }
-if ${lt_cv_path_MAGIC_CMD+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $MAGIC_CMD in
-[\\/*] | ?:[\\/]*)
- lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
- ;;
-*)
- lt_save_MAGIC_CMD="$MAGIC_CMD"
- lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
- ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
- for ac_dir in $ac_dummy; do
- IFS="$lt_save_ifs"
- test -z "$ac_dir" && ac_dir=.
- if test -f $ac_dir/${ac_tool_prefix}file; then
- lt_cv_path_MAGIC_CMD="$ac_dir/${ac_tool_prefix}file"
- if test -n "$file_magic_test_file"; then
- case $deplibs_check_method in
- "file_magic "*)
- file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
- MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
- if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
- $EGREP "$file_magic_regex" > /dev/null; then
- :
- else
- cat <<_LT_EOF 1>&2
-
-*** Warning: the command libtool uses to detect shared libraries,
-*** $file_magic_cmd, produces output that libtool cannot recognize.
-*** The result is that libtool may fail to recognize shared libraries
-*** as such. This will affect the creation of libtool libraries that
-*** depend on shared libraries, but programs linked with such libtool
-*** libraries will work regardless of this problem. Nevertheless, you
-*** may want to report the problem to your system manager and/or to
-*** bug-libtool@gnu.org
-
-_LT_EOF
- fi ;;
- esac
- fi
- break
- fi
- done
- IFS="$lt_save_ifs"
- MAGIC_CMD="$lt_save_MAGIC_CMD"
- ;;
-esac
-fi
-
-MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
-if test -n "$MAGIC_CMD"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5
-$as_echo "$MAGIC_CMD" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-
-
-
-if test -z "$lt_cv_path_MAGIC_CMD"; then
- if test -n "$ac_tool_prefix"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for file" >&5
-$as_echo_n "checking for file... " >&6; }
-if ${lt_cv_path_MAGIC_CMD+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $MAGIC_CMD in
-[\\/*] | ?:[\\/]*)
- lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
- ;;
-*)
- lt_save_MAGIC_CMD="$MAGIC_CMD"
- lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
- ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
- for ac_dir in $ac_dummy; do
- IFS="$lt_save_ifs"
- test -z "$ac_dir" && ac_dir=.
- if test -f $ac_dir/file; then
- lt_cv_path_MAGIC_CMD="$ac_dir/file"
- if test -n "$file_magic_test_file"; then
- case $deplibs_check_method in
- "file_magic "*)
- file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
- MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
- if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
- $EGREP "$file_magic_regex" > /dev/null; then
- :
- else
- cat <<_LT_EOF 1>&2
-
-*** Warning: the command libtool uses to detect shared libraries,
-*** $file_magic_cmd, produces output that libtool cannot recognize.
-*** The result is that libtool may fail to recognize shared libraries
-*** as such. This will affect the creation of libtool libraries that
-*** depend on shared libraries, but programs linked with such libtool
-*** libraries will work regardless of this problem. Nevertheless, you
-*** may want to report the problem to your system manager and/or to
-*** bug-libtool@gnu.org
-
-_LT_EOF
- fi ;;
- esac
- fi
- break
- fi
- done
- IFS="$lt_save_ifs"
- MAGIC_CMD="$lt_save_MAGIC_CMD"
- ;;
-esac
-fi
-
-MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
-if test -n "$MAGIC_CMD"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5
-$as_echo "$MAGIC_CMD" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- else
- MAGIC_CMD=:
- fi
-fi
-
- fi
- ;;
-esac
-
-# Use C for the default configuration in the libtool script
-
-lt_save_CC="$CC"
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-
-# Source file extension for C test sources.
-ac_ext=c
-
-# Object file extension for compiled C test sources.
-objext=o
-objext=$objext
-
-# Code to be used in simple compile tests
-lt_simple_compile_test_code="int some_variable = 0;"
-
-# Code to be used in simple link tests
-lt_simple_link_test_code='int main(){return(0);}'
-
-
-
-
-
-
-
-# If no C compiler was specified, use CC.
-LTCC=${LTCC-"$CC"}
-
-# If no C compiler flags were specified, use CFLAGS.
-LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
-
-# Allow CC to be a program name with arguments.
-compiler=$CC
-
-# Save the default compiler, since it gets overwritten when the other
-# tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP.
-compiler_DEFAULT=$CC
-
-# save warnings/boilerplate of simple test code
-ac_outfile=conftest.$ac_objext
-echo "$lt_simple_compile_test_code" >conftest.$ac_ext
-eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
-_lt_compiler_boilerplate=`cat conftest.err`
-$RM conftest*
-
-ac_outfile=conftest.$ac_objext
-echo "$lt_simple_link_test_code" >conftest.$ac_ext
-eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
-_lt_linker_boilerplate=`cat conftest.err`
-$RM -r conftest*
-
-
-## CAVEAT EMPTOR:
-## There is no encapsulation within the following macros, do not change
-## the running order or otherwise move them around unless you know exactly
-## what you are doing...
-if test -n "$compiler"; then
-
-lt_prog_compiler_no_builtin_flag=
-
-if test "$GCC" = yes; then
- case $cc_basename in
- nvcc*)
- lt_prog_compiler_no_builtin_flag=' -Xcompiler -fno-builtin' ;;
- *)
- lt_prog_compiler_no_builtin_flag=' -fno-builtin' ;;
- esac
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -fno-rtti -fno-exceptions" >&5
-$as_echo_n "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; }
-if ${lt_cv_prog_compiler_rtti_exceptions+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_prog_compiler_rtti_exceptions=no
- ac_outfile=conftest.$ac_objext
- echo "$lt_simple_compile_test_code" > conftest.$ac_ext
- lt_compiler_flag="-fno-rtti -fno-exceptions"
- # Insert the option either (1) after the last *FLAGS variable, or
- # (2) before a word containing "conftest.", or (3) at the end.
- # Note that $ac_compile itself does not contain backslashes and begins
- # with a dollar sign (not a hyphen), so the echo should work correctly.
- # The option is referenced via a variable to avoid confusing sed.
- lt_compile=`echo "$ac_compile" | $SED \
- -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
- -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
- -e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
- (eval "$lt_compile" 2>conftest.err)
- ac_status=$?
- cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- if (exit $ac_status) && test -s "$ac_outfile"; then
- # The compiler can only warn and ignore the option if not recognized
- # So say no if there are warnings other than the usual output.
- $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
- $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
- if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
- lt_cv_prog_compiler_rtti_exceptions=yes
- fi
- fi
- $RM conftest*
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_rtti_exceptions" >&5
-$as_echo "$lt_cv_prog_compiler_rtti_exceptions" >&6; }
-
-if test x"$lt_cv_prog_compiler_rtti_exceptions" = xyes; then
- lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions"
-else
- :
-fi
-
-fi
-
-
-
-
-
-
- lt_prog_compiler_wl=
-lt_prog_compiler_pic=
-lt_prog_compiler_static=
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
-$as_echo_n "checking for $compiler option to produce PIC... " >&6; }
-
- if test "$GCC" = yes; then
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_static='-static'
-
- case $host_os in
- aix*)
- # All AIX code is PIC.
- if test "$host_cpu" = ia64; then
- # AIX 5 now supports IA64 processor
- lt_prog_compiler_static='-Bstatic'
- fi
- lt_prog_compiler_pic='-fPIC'
- ;;
-
- amigaos*)
- case $host_cpu in
- powerpc)
- # see comment about AmigaOS4 .so support
- lt_prog_compiler_pic='-fPIC'
- ;;
- m68k)
- # FIXME: we need at least 68020 code to build shared libraries, but
- # adding the `-m68020' flag to GCC prevents building anything better,
- # like `-m68040'.
- lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4'
- ;;
- esac
- ;;
-
- beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
- # PIC is the default for these OSes.
- ;;
-
- mingw* | cygwin* | pw32* | os2* | cegcc*)
- # This hack is so that the source file can tell whether it is being
- # built for inclusion in a dll (and should export symbols for example).
- # Although the cygwin gcc ignores -fPIC, still need this for old-style
- # (--disable-auto-import) libraries
- lt_prog_compiler_pic='-DDLL_EXPORT'
- ;;
-
- darwin* | rhapsody*)
- # PIC is the default on this platform
- # Common symbols not allowed in MH_DYLIB files
- lt_prog_compiler_pic='-fno-common'
- ;;
-
- haiku*)
- # PIC is the default for Haiku.
- # The "-static" flag exists, but is broken.
- lt_prog_compiler_static=
- ;;
-
- hpux*)
- # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
- # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag
- # sets the default TLS model and affects inlining.
- case $host_cpu in
- hppa*64*)
- # +Z the default
- ;;
- *)
- lt_prog_compiler_pic='-fPIC'
- ;;
- esac
- ;;
-
- interix[3-9]*)
- # Interix 3.x gcc -fpic/-fPIC options generate broken code.
- # Instead, we relocate shared libraries at runtime.
- ;;
-
- msdosdjgpp*)
- # Just because we use GCC doesn't mean we suddenly get shared libraries
- # on systems that don't support them.
- lt_prog_compiler_can_build_shared=no
- enable_shared=no
- ;;
-
- *nto* | *qnx*)
- # QNX uses GNU C++, but need to define -shared option too, otherwise
- # it will coredump.
- lt_prog_compiler_pic='-fPIC -shared'
- ;;
-
- sysv4*MP*)
- if test -d /usr/nec; then
- lt_prog_compiler_pic=-Kconform_pic
- fi
- ;;
-
- *)
- lt_prog_compiler_pic='-fPIC'
- ;;
- esac
-
- case $cc_basename in
- nvcc*) # Cuda Compiler Driver 2.2
- lt_prog_compiler_wl='-Xlinker '
- lt_prog_compiler_pic='-Xcompiler -fPIC'
- ;;
- esac
- else
- # PORTME Check for flag to pass linker flags through the system compiler.
- case $host_os in
- aix*)
- lt_prog_compiler_wl='-Wl,'
- if test "$host_cpu" = ia64; then
- # AIX 5 now supports IA64 processor
- lt_prog_compiler_static='-Bstatic'
- else
- lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp'
- fi
- ;;
-
- mingw* | cygwin* | pw32* | os2* | cegcc*)
- # This hack is so that the source file can tell whether it is being
- # built for inclusion in a dll (and should export symbols for example).
- lt_prog_compiler_pic='-DDLL_EXPORT'
- ;;
-
- hpux9* | hpux10* | hpux11*)
- lt_prog_compiler_wl='-Wl,'
- # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
- # not for PA HP-UX.
- case $host_cpu in
- hppa*64*|ia64*)
- # +Z the default
- ;;
- *)
- lt_prog_compiler_pic='+Z'
- ;;
- esac
- # Is there a better lt_prog_compiler_static that works with the bundled CC?
- lt_prog_compiler_static='${wl}-a ${wl}archive'
- ;;
-
- irix5* | irix6* | nonstopux*)
- lt_prog_compiler_wl='-Wl,'
- # PIC (with -KPIC) is the default.
- lt_prog_compiler_static='-non_shared'
- ;;
-
- linux* | k*bsd*-gnu | kopensolaris*-gnu)
- case $cc_basename in
- # old Intel for x86_64 which still supported -KPIC.
- ecc*)
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_pic='-KPIC'
- lt_prog_compiler_static='-static'
- ;;
- # icc used to be incompatible with GCC.
- # ICC 10 doesn't accept -KPIC any more.
- icc* | ifort*)
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_pic='-fPIC'
- lt_prog_compiler_static='-static'
- ;;
- # Lahey Fortran 8.1.
- lf95*)
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_pic='--shared'
- lt_prog_compiler_static='--static'
- ;;
- pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
- # Portland Group compilers (*not* the Pentium gcc compiler,
- # which looks to be a dead project)
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_pic='-fpic'
- lt_prog_compiler_static='-Bstatic'
- ;;
- ccc*)
- lt_prog_compiler_wl='-Wl,'
- # All Alpha code is PIC.
- lt_prog_compiler_static='-non_shared'
- ;;
- xl* | bgxl* | bgf* | mpixl*)
- # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_pic='-qpic'
- lt_prog_compiler_static='-qstaticlink'
- ;;
- *)
- case `$CC -V 2>&1 | sed 5q` in
- *Sun\ F* | *Sun*Fortran*)
- # Sun Fortran 8.3 passes all unrecognized flags to the linker
- lt_prog_compiler_pic='-KPIC'
- lt_prog_compiler_static='-Bstatic'
- lt_prog_compiler_wl=''
- ;;
- *Sun\ C*)
- # Sun C 5.9
- lt_prog_compiler_pic='-KPIC'
- lt_prog_compiler_static='-Bstatic'
- lt_prog_compiler_wl='-Wl,'
- ;;
- esac
- ;;
- esac
- ;;
-
- newsos6)
- lt_prog_compiler_pic='-KPIC'
- lt_prog_compiler_static='-Bstatic'
- ;;
-
- *nto* | *qnx*)
- # QNX uses GNU C++, but need to define -shared option too, otherwise
- # it will coredump.
- lt_prog_compiler_pic='-fPIC -shared'
- ;;
-
- osf3* | osf4* | osf5*)
- lt_prog_compiler_wl='-Wl,'
- # All OSF/1 code is PIC.
- lt_prog_compiler_static='-non_shared'
- ;;
-
- rdos*)
- lt_prog_compiler_static='-non_shared'
- ;;
-
- solaris*)
- lt_prog_compiler_pic='-KPIC'
- lt_prog_compiler_static='-Bstatic'
- case $cc_basename in
- f77* | f90* | f95*)
- lt_prog_compiler_wl='-Qoption ld ';;
- *)
- lt_prog_compiler_wl='-Wl,';;
- esac
- ;;
-
- sunos4*)
- lt_prog_compiler_wl='-Qoption ld '
- lt_prog_compiler_pic='-PIC'
- lt_prog_compiler_static='-Bstatic'
- ;;
-
- sysv4 | sysv4.2uw2* | sysv4.3*)
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_pic='-KPIC'
- lt_prog_compiler_static='-Bstatic'
- ;;
-
- sysv4*MP*)
- if test -d /usr/nec ;then
- lt_prog_compiler_pic='-Kconform_pic'
- lt_prog_compiler_static='-Bstatic'
- fi
- ;;
-
- sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_pic='-KPIC'
- lt_prog_compiler_static='-Bstatic'
- ;;
-
- unicos*)
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_can_build_shared=no
- ;;
-
- uts4*)
- lt_prog_compiler_pic='-pic'
- lt_prog_compiler_static='-Bstatic'
- ;;
-
- *)
- lt_prog_compiler_can_build_shared=no
- ;;
- esac
- fi
-
-case $host_os in
- # For platforms which do not support PIC, -DPIC is meaningless:
- *djgpp*)
- lt_prog_compiler_pic=
- ;;
- *)
- lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC"
- ;;
-esac
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_prog_compiler_pic" >&5
-$as_echo "$lt_prog_compiler_pic" >&6; }
-
-
-
-
-
-
-#
-# Check to make sure the PIC flag actually works.
-#
-if test -n "$lt_prog_compiler_pic"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5
-$as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic works... " >&6; }
-if ${lt_cv_prog_compiler_pic_works+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_prog_compiler_pic_works=no
- ac_outfile=conftest.$ac_objext
- echo "$lt_simple_compile_test_code" > conftest.$ac_ext
- lt_compiler_flag="$lt_prog_compiler_pic -DPIC"
- # Insert the option either (1) after the last *FLAGS variable, or
- # (2) before a word containing "conftest.", or (3) at the end.
- # Note that $ac_compile itself does not contain backslashes and begins
- # with a dollar sign (not a hyphen), so the echo should work correctly.
- # The option is referenced via a variable to avoid confusing sed.
- lt_compile=`echo "$ac_compile" | $SED \
- -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
- -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
- -e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
- (eval "$lt_compile" 2>conftest.err)
- ac_status=$?
- cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- if (exit $ac_status) && test -s "$ac_outfile"; then
- # The compiler can only warn and ignore the option if not recognized
- # So say no if there are warnings other than the usual output.
- $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
- $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
- if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
- lt_cv_prog_compiler_pic_works=yes
- fi
- fi
- $RM conftest*
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works" >&5
-$as_echo "$lt_cv_prog_compiler_pic_works" >&6; }
-
-if test x"$lt_cv_prog_compiler_pic_works" = xyes; then
- case $lt_prog_compiler_pic in
- "" | " "*) ;;
- *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;;
- esac
-else
- lt_prog_compiler_pic=
- lt_prog_compiler_can_build_shared=no
-fi
-
-fi
-
-
-
-
-
-
-#
-# Check to make sure the static flag actually works.
-#
-wl=$lt_prog_compiler_wl eval lt_tmp_static_flag=\"$lt_prog_compiler_static\"
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5
-$as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; }
-if ${lt_cv_prog_compiler_static_works+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_prog_compiler_static_works=no
- save_LDFLAGS="$LDFLAGS"
- LDFLAGS="$LDFLAGS $lt_tmp_static_flag"
- echo "$lt_simple_link_test_code" > conftest.$ac_ext
- if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
- # The linker can only warn and ignore the option if not recognized
- # So say no if there are warnings
- if test -s conftest.err; then
- # Append any errors to the config.log.
- cat conftest.err 1>&5
- $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
- $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
- if diff conftest.exp conftest.er2 >/dev/null; then
- lt_cv_prog_compiler_static_works=yes
- fi
- else
- lt_cv_prog_compiler_static_works=yes
- fi
- fi
- $RM -r conftest*
- LDFLAGS="$save_LDFLAGS"
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works" >&5
-$as_echo "$lt_cv_prog_compiler_static_works" >&6; }
-
-if test x"$lt_cv_prog_compiler_static_works" = xyes; then
- :
-else
- lt_prog_compiler_static=
-fi
-
-
-
-
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
-$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
-if ${lt_cv_prog_compiler_c_o+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_prog_compiler_c_o=no
- $RM -r conftest 2>/dev/null
- mkdir conftest
- cd conftest
- mkdir out
- echo "$lt_simple_compile_test_code" > conftest.$ac_ext
-
- lt_compiler_flag="-o out/conftest2.$ac_objext"
- # Insert the option either (1) after the last *FLAGS variable, or
- # (2) before a word containing "conftest.", or (3) at the end.
- # Note that $ac_compile itself does not contain backslashes and begins
- # with a dollar sign (not a hyphen), so the echo should work correctly.
- lt_compile=`echo "$ac_compile" | $SED \
- -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
- -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
- -e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
- (eval "$lt_compile" 2>out/conftest.err)
- ac_status=$?
- cat out/conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- if (exit $ac_status) && test -s out/conftest2.$ac_objext
- then
- # The compiler can only warn and ignore the option if not recognized
- # So say no if there are warnings
- $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
- $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
- if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
- lt_cv_prog_compiler_c_o=yes
- fi
- fi
- chmod u+w . 2>&5
- $RM conftest*
- # SGI C++ compiler will create directory out/ii_files/ for
- # template instantiation
- test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
- $RM out/* && rmdir out
- cd ..
- $RM -r conftest
- $RM conftest*
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5
-$as_echo "$lt_cv_prog_compiler_c_o" >&6; }
-
-
-
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
-$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
-if ${lt_cv_prog_compiler_c_o+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_prog_compiler_c_o=no
- $RM -r conftest 2>/dev/null
- mkdir conftest
- cd conftest
- mkdir out
- echo "$lt_simple_compile_test_code" > conftest.$ac_ext
-
- lt_compiler_flag="-o out/conftest2.$ac_objext"
- # Insert the option either (1) after the last *FLAGS variable, or
- # (2) before a word containing "conftest.", or (3) at the end.
- # Note that $ac_compile itself does not contain backslashes and begins
- # with a dollar sign (not a hyphen), so the echo should work correctly.
- lt_compile=`echo "$ac_compile" | $SED \
- -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
- -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
- -e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
- (eval "$lt_compile" 2>out/conftest.err)
- ac_status=$?
- cat out/conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- if (exit $ac_status) && test -s out/conftest2.$ac_objext
- then
- # The compiler can only warn and ignore the option if not recognized
- # So say no if there are warnings
- $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
- $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
- if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
- lt_cv_prog_compiler_c_o=yes
- fi
- fi
- chmod u+w . 2>&5
- $RM conftest*
- # SGI C++ compiler will create directory out/ii_files/ for
- # template instantiation
- test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
- $RM out/* && rmdir out
- cd ..
- $RM -r conftest
- $RM conftest*
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5
-$as_echo "$lt_cv_prog_compiler_c_o" >&6; }
-
-
-
-
-hard_links="nottested"
-if test "$lt_cv_prog_compiler_c_o" = no && test "$need_locks" != no; then
- # do not overwrite the value of need_locks provided by the user
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5
-$as_echo_n "checking if we can lock with hard links... " >&6; }
- hard_links=yes
- $RM conftest*
- ln conftest.a conftest.b 2>/dev/null && hard_links=no
- touch conftest.a
- ln conftest.a conftest.b 2>&5 || hard_links=no
- ln conftest.a conftest.b 2>/dev/null && hard_links=no
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5
-$as_echo "$hard_links" >&6; }
- if test "$hard_links" = no; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5
-$as_echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;}
- need_locks=warn
- fi
-else
- need_locks=no
-fi
-
-
-
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5
-$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; }
-
- runpath_var=
- allow_undefined_flag=
- always_export_symbols=no
- archive_cmds=
- archive_expsym_cmds=
- compiler_needs_object=no
- enable_shared_with_static_runtimes=no
- export_dynamic_flag_spec=
- export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
- hardcode_automatic=no
- hardcode_direct=no
- hardcode_direct_absolute=no
- hardcode_libdir_flag_spec=
- hardcode_libdir_flag_spec_ld=
- hardcode_libdir_separator=
- hardcode_minus_L=no
- hardcode_shlibpath_var=unsupported
- inherit_rpath=no
- link_all_deplibs=unknown
- module_cmds=
- module_expsym_cmds=
- old_archive_from_new_cmds=
- old_archive_from_expsyms_cmds=
- thread_safe_flag_spec=
- whole_archive_flag_spec=
- # include_expsyms should be a list of space-separated symbols to be *always*
- # included in the symbol list
- include_expsyms=
- # exclude_expsyms can be an extended regexp of symbols to exclude
- # it will be wrapped by ` (' and `)$', so one must not match beginning or
- # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
- # as well as any symbol that contains `d'.
- exclude_expsyms='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'
- # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
- # platforms (ab)use it in PIC code, but their linkers get confused if
- # the symbol is explicitly referenced. Since portable code cannot
- # rely on this symbol name, it's probably fine to never include it in
- # preloaded symbol tables.
- # Exclude shared library initialization/finalization symbols.
- extract_expsyms_cmds=
-
- case $host_os in
- cygwin* | mingw* | pw32* | cegcc*)
- # FIXME: the MSVC++ port hasn't been tested in a loooong time
- # When not using gcc, we currently assume that we are using
- # Microsoft Visual C++.
- if test "$GCC" != yes; then
- with_gnu_ld=no
- fi
- ;;
- interix*)
- # we just hope/assume this is gcc and not c89 (= MSVC++)
- with_gnu_ld=yes
- ;;
- openbsd*)
- with_gnu_ld=no
- ;;
- esac
-
- ld_shlibs=yes
-
- # On some targets, GNU ld is compatible enough with the native linker
- # that we're better off using the native interface for both.
- lt_use_gnu_ld_interface=no
- if test "$with_gnu_ld" = yes; then
- case $host_os in
- aix*)
- # The AIX port of GNU ld has always aspired to compatibility
- # with the native linker. However, as the warning in the GNU ld
- # block says, versions before 2.19.5* couldn't really create working
- # shared libraries, regardless of the interface used.
- case `$LD -v 2>&1` in
- *\ \(GNU\ Binutils\)\ 2.19.5*) ;;
- *\ \(GNU\ Binutils\)\ 2.[2-9]*) ;;
- *\ \(GNU\ Binutils\)\ [3-9]*) ;;
- *)
- lt_use_gnu_ld_interface=yes
- ;;
- esac
- ;;
- *)
- lt_use_gnu_ld_interface=yes
- ;;
- esac
- fi
-
- if test "$lt_use_gnu_ld_interface" = yes; then
- # If archive_cmds runs LD, not CC, wlarc should be empty
- wlarc='${wl}'
-
- # Set some defaults for GNU ld with shared library support. These
- # are reset later if shared libraries are not supported. Putting them
- # here allows them to be overridden if necessary.
- runpath_var=LD_RUN_PATH
- hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
- export_dynamic_flag_spec='${wl}--export-dynamic'
- # ancient GNU ld didn't support --whole-archive et. al.
- if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then
- whole_archive_flag_spec="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
- else
- whole_archive_flag_spec=
- fi
- supports_anon_versioning=no
- case `$LD -v 2>&1` in
- *GNU\ gold*) supports_anon_versioning=yes ;;
- *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11
- *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
- *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
- *\ 2.11.*) ;; # other 2.11 versions
- *) supports_anon_versioning=yes ;;
- esac
-
- # See if GNU ld supports shared libraries.
- case $host_os in
- aix[3-9]*)
- # On AIX/PPC, the GNU linker is very broken
- if test "$host_cpu" != ia64; then
- ld_shlibs=no
- cat <<_LT_EOF 1>&2
-
-*** Warning: the GNU linker, at least up to release 2.19, is reported
-*** to be unable to reliably create shared libraries on AIX.
-*** Therefore, libtool is disabling shared libraries support. If you
-*** really care for shared libraries, you may want to install binutils
-*** 2.20 or above, or modify your PATH so that a non-GNU linker is found.
-*** You will then need to restart the configuration process.
-
-_LT_EOF
- fi
- ;;
-
- amigaos*)
- case $host_cpu in
- powerpc)
- # see comment about AmigaOS4 .so support
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- archive_expsym_cmds=''
- ;;
- m68k)
- archive_cmds='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
- hardcode_libdir_flag_spec='-L$libdir'
- hardcode_minus_L=yes
- ;;
- esac
- ;;
-
- beos*)
- if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
- allow_undefined_flag=unsupported
- # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
- # support --undefined. This deserves some investigation. FIXME
- archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- else
- ld_shlibs=no
- fi
- ;;
-
- cygwin* | mingw* | pw32* | cegcc*)
- # _LT_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless,
- # as there is no search path for DLLs.
- hardcode_libdir_flag_spec='-L$libdir'
- export_dynamic_flag_spec='${wl}--export-all-symbols'
- allow_undefined_flag=unsupported
- always_export_symbols=no
- enable_shared_with_static_runtimes=yes
- export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
-
- if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
- # If the export-symbols file already is a .def file (1st line
- # is EXPORTS), use it as is; otherwise, prepend...
- archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
- cp $export_symbols $output_objdir/$soname.def;
- else
- echo EXPORTS > $output_objdir/$soname.def;
- cat $export_symbols >> $output_objdir/$soname.def;
- fi~
- $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
- else
- ld_shlibs=no
- fi
- ;;
-
- haiku*)
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- link_all_deplibs=yes
- ;;
-
- interix[3-9]*)
- hardcode_direct=no
- hardcode_shlibpath_var=no
- hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
- export_dynamic_flag_spec='${wl}-E'
- # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
- # Instead, shared libraries are loaded at an image base (0x10000000 by
- # default) and relocated if they conflict, which is a slow very memory
- # consuming and fragmenting process. To avoid this, we pick a random,
- # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
- # time. Moving up from 0x10000000 also allows more sbrk(2) space.
- archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
- archive_expsym_cmds='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
- ;;
-
- gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu | uclinuxfdpiceabi)
- tmp_diet=no
- if test "$host_os" = linux-dietlibc; then
- case $cc_basename in
- diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn)
- esac
- fi
- if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
- && test "$tmp_diet" = no
- then
- tmp_addflag=' $pic_flag'
- tmp_sharedflag='-shared'
- case $cc_basename,$host_cpu in
- pgcc*) # Portland Group C compiler
- whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
- tmp_addflag=' $pic_flag'
- ;;
- pgf77* | pgf90* | pgf95* | pgfortran*)
- # Portland Group f77 and f90 compilers
- whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
- tmp_addflag=' $pic_flag -Mnomain' ;;
- ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64
- tmp_addflag=' -i_dynamic' ;;
- efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64
- tmp_addflag=' -i_dynamic -nofor_main' ;;
- ifc* | ifort*) # Intel Fortran compiler
- tmp_addflag=' -nofor_main' ;;
- lf95*) # Lahey Fortran 8.1
- whole_archive_flag_spec=
- tmp_sharedflag='--shared' ;;
- xl[cC]* | bgxl[cC]* | mpixl[cC]*) # IBM XL C 8.0 on PPC (deal with xlf below)
- tmp_sharedflag='-qmkshrobj'
- tmp_addflag= ;;
- nvcc*) # Cuda Compiler Driver 2.2
- whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
- compiler_needs_object=yes
- ;;
- esac
- case `$CC -V 2>&1 | sed 5q` in
- *Sun\ C*) # Sun C 5.9
- whole_archive_flag_spec='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
- compiler_needs_object=yes
- tmp_sharedflag='-G' ;;
- *Sun\ F*) # Sun Fortran 8.3
- tmp_sharedflag='-G' ;;
- esac
- archive_cmds='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
-
- if test "x$supports_anon_versioning" = xyes; then
- archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
- cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
- echo "local: *; };" >> $output_objdir/$libname.ver~
- $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
- fi
-
- case $cc_basename in
- xlf* | bgf* | bgxlf* | mpixlf*)
- # IBM XL Fortran 10.1 on PPC cannot create shared libs itself
- whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive'
- hardcode_libdir_flag_spec=
- hardcode_libdir_flag_spec_ld='-rpath $libdir'
- archive_cmds='$LD -shared $libobjs $deplibs $compiler_flags -soname $soname -o $lib'
- if test "x$supports_anon_versioning" = xyes; then
- archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
- cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
- echo "local: *; };" >> $output_objdir/$libname.ver~
- $LD -shared $libobjs $deplibs $compiler_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
- fi
- ;;
- esac
- else
- ld_shlibs=no
- fi
- ;;
-
- netbsd*)
- if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
- archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
- wlarc=
- else
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
- fi
- ;;
-
- solaris*)
- if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then
- ld_shlibs=no
- cat <<_LT_EOF 1>&2
-
-*** Warning: The releases 2.8.* of the GNU linker cannot reliably
-*** create shared libraries on Solaris systems. Therefore, libtool
-*** is disabling shared libraries support. We urge you to upgrade GNU
-*** binutils to release 2.9.1 or newer. Another option is to modify
-*** your PATH or compiler configuration so that the native linker is
-*** used, and then restart.
-
-_LT_EOF
- elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
- else
- ld_shlibs=no
- fi
- ;;
-
- sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
- case `$LD -v 2>&1` in
- *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*)
- ld_shlibs=no
- cat <<_LT_EOF 1>&2
-
-*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not
-*** reliably create shared libraries on SCO systems. Therefore, libtool
-*** is disabling shared libraries support. We urge you to upgrade GNU
-*** binutils to release 2.16.91.0.3 or newer. Another option is to modify
-*** your PATH or compiler configuration so that the native linker is
-*** used, and then restart.
-
-_LT_EOF
- ;;
- *)
- # For security reasons, it is highly recommended that you always
- # use absolute paths for naming shared libraries, and exclude the
- # DT_RUNPATH tag from executables and libraries. But doing so
- # requires that you compile everything twice, which is a pain.
- if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
- hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
- else
- ld_shlibs=no
- fi
- ;;
- esac
- ;;
-
- sunos4*)
- archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
- wlarc=
- hardcode_direct=yes
- hardcode_shlibpath_var=no
- ;;
-
- *)
- if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
- else
- ld_shlibs=no
- fi
- ;;
- esac
-
- if test "$ld_shlibs" = no; then
- runpath_var=
- hardcode_libdir_flag_spec=
- export_dynamic_flag_spec=
- whole_archive_flag_spec=
- fi
- else
- # PORTME fill in a description of your system's linker (not GNU ld)
- case $host_os in
- aix3*)
- allow_undefined_flag=unsupported
- always_export_symbols=yes
- archive_expsym_cmds='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname'
- # Note: this linker hardcodes the directories in LIBPATH if there
- # are no directories specified by -L.
- hardcode_minus_L=yes
- if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then
- # Neither direct hardcoding nor static linking is supported with a
- # broken collect2.
- hardcode_direct=unsupported
- fi
- ;;
-
- aix[4-9]*)
- if test "$host_cpu" = ia64; then
- # On IA64, the linker does run time linking by default, so we don't
- # have to do anything special.
- aix_use_runtimelinking=no
- exp_sym_flag='-Bexport'
- no_entry_flag=""
- else
- # If we're using GNU nm, then we don't want the "-C" option.
- # -C means demangle to AIX nm, but means don't demangle with GNU nm
- # Also, AIX nm treats weak defined symbols like other global
- # defined symbols, whereas GNU nm marks them as "W".
- if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
- export_symbols_cmds='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
- else
- export_symbols_cmds='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "L")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
- fi
- aix_use_runtimelinking=no
-
- # Test if we are trying to use run time linking or normal
- # AIX style linking. If -brtl is somewhere in LDFLAGS, we
- # need to do runtime linking.
- case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*)
- for ld_flag in $LDFLAGS; do
- if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
- aix_use_runtimelinking=yes
- break
- fi
- done
- ;;
- esac
-
- exp_sym_flag='-bexport'
- no_entry_flag='-bnoentry'
- fi
-
- # When large executables or shared objects are built, AIX ld can
- # have problems creating the table of contents. If linking a library
- # or program results in "error TOC overflow" add -mminimal-toc to
- # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
- # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
-
- archive_cmds=''
- hardcode_direct=yes
- hardcode_direct_absolute=yes
- hardcode_libdir_separator=':'
- link_all_deplibs=yes
- file_list_spec='${wl}-f,'
-
- if test "$GCC" = yes; then
- case $host_os in aix4.[012]|aix4.[012].*)
- # We only want to do this on AIX 4.2 and lower, the check
- # below for broken collect2 doesn't work under 4.3+
- collect2name=`${CC} -print-prog-name=collect2`
- if test -f "$collect2name" &&
- strings "$collect2name" | $GREP resolve_lib_name >/dev/null
- then
- # We have reworked collect2
- :
- else
- # We have old collect2
- hardcode_direct=unsupported
- # It fails to find uninstalled libraries when the uninstalled
- # path is not listed in the libpath. Setting hardcode_minus_L
- # to unsupported forces relinking
- hardcode_minus_L=yes
- hardcode_libdir_flag_spec='-L$libdir'
- hardcode_libdir_separator=
- fi
- ;;
- esac
- shared_flag='-shared'
- if test "$aix_use_runtimelinking" = yes; then
- shared_flag="$shared_flag "'${wl}-G'
- fi
- else
- # not using gcc
- if test "$host_cpu" = ia64; then
- # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
- # chokes on -Wl,-G. The following line is correct:
- shared_flag='-G'
- else
- if test "$aix_use_runtimelinking" = yes; then
- shared_flag='${wl}-G'
- else
- shared_flag='${wl}-bM:SRE'
- fi
- fi
- fi
-
- export_dynamic_flag_spec='${wl}-bexpall'
- # It seems that -bexpall does not export symbols beginning with
- # underscore (_), so it is better to generate a list of symbols to export.
- always_export_symbols=yes
- if test "$aix_use_runtimelinking" = yes; then
- # Warning - without using the other runtime loading flags (-brtl),
- # -berok will link without error, but may produce a broken library.
- allow_undefined_flag='-berok'
- # Determine the default libpath from the value encoded in an
- # empty executable.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
-
-lt_aix_libpath_sed='
- /Import File Strings/,/^$/ {
- /^0/ {
- s/^0 *\(.*\)$/\1/
- p
- }
- }'
-aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
-# Check for a 64-bit object if we didn't find anything.
-if test -z "$aix_libpath"; then
- aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
-fi
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
-
- hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
- archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
- else
- if test "$host_cpu" = ia64; then
- hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib'
- allow_undefined_flag="-z nodefs"
- archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols"
- else
- # Determine the default libpath from the value encoded in an
- # empty executable.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
-
-lt_aix_libpath_sed='
- /Import File Strings/,/^$/ {
- /^0/ {
- s/^0 *\(.*\)$/\1/
- p
- }
- }'
-aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
-# Check for a 64-bit object if we didn't find anything.
-if test -z "$aix_libpath"; then
- aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
-fi
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
-
- hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
- # Warning - without using the other run time loading flags,
- # -berok will link without error, but may produce a broken library.
- no_undefined_flag=' ${wl}-bernotok'
- allow_undefined_flag=' ${wl}-berok'
- if test "$with_gnu_ld" = yes; then
- # We only use this code for GNU lds that support --whole-archive.
- whole_archive_flag_spec='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
- else
- # Exported symbols can be pulled into shared objects from archives
- whole_archive_flag_spec='$convenience'
- fi
- archive_cmds_need_lc=yes
- # This is similar to how AIX traditionally builds its shared libraries.
- archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
- fi
- fi
- ;;
-
- amigaos*)
- case $host_cpu in
- powerpc)
- # see comment about AmigaOS4 .so support
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- archive_expsym_cmds=''
- ;;
- m68k)
- archive_cmds='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
- hardcode_libdir_flag_spec='-L$libdir'
- hardcode_minus_L=yes
- ;;
- esac
- ;;
-
- bsdi[45]*)
- export_dynamic_flag_spec=-rdynamic
- ;;
-
- cygwin* | mingw* | pw32* | cegcc*)
- # When not using gcc, we currently assume that we are using
- # Microsoft Visual C++.
- # hardcode_libdir_flag_spec is actually meaningless, as there is
- # no search path for DLLs.
- hardcode_libdir_flag_spec=' '
- allow_undefined_flag=unsupported
- # Tell ltmain to make .lib files, not .a files.
- libext=lib
- # Tell ltmain to make .dll files, not .so files.
- shrext_cmds=".dll"
- # FIXME: Setting linknames here is a bad hack.
- archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
- # The linker will automatically build a .lib file if we build a DLL.
- old_archive_from_new_cmds='true'
- # FIXME: Should let the user specify the lib program.
- old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs'
- fix_srcfile_path='`cygpath -w "$srcfile"`'
- enable_shared_with_static_runtimes=yes
- ;;
-
- darwin* | rhapsody*)
-
-
- archive_cmds_need_lc=no
- hardcode_direct=no
- hardcode_automatic=yes
- hardcode_shlibpath_var=unsupported
- if test "$lt_cv_ld_force_load" = "yes"; then
- whole_archive_flag_spec='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience ${wl}-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`'
- else
- whole_archive_flag_spec=''
- fi
- link_all_deplibs=yes
- allow_undefined_flag="$_lt_dar_allow_undefined"
- case $cc_basename in
- ifort*) _lt_dar_can_shared=yes ;;
- *) _lt_dar_can_shared=$GCC ;;
- esac
- if test "$_lt_dar_can_shared" = "yes"; then
- output_verbose_link_cmd=func_echo_all
- archive_cmds="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}"
- module_cmds="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
- archive_expsym_cmds="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}"
- module_expsym_cmds="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}"
-
- else
- ld_shlibs=no
- fi
-
- ;;
-
- dgux*)
- archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
- hardcode_libdir_flag_spec='-L$libdir'
- hardcode_shlibpath_var=no
- ;;
-
- # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
- # support. Future versions do this automatically, but an explicit c++rt0.o
- # does not break anything, and helps significantly (at the cost of a little
- # extra space).
- freebsd2.2*)
- archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
- hardcode_libdir_flag_spec='-R$libdir'
- hardcode_direct=yes
- hardcode_shlibpath_var=no
- ;;
-
- # Unfortunately, older versions of FreeBSD 2 do not have this feature.
- freebsd2.*)
- archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
- hardcode_direct=yes
- hardcode_minus_L=yes
- hardcode_shlibpath_var=no
- ;;
-
- # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
- freebsd* | dragonfly*)
- archive_cmds='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
- hardcode_libdir_flag_spec='-R$libdir'
- hardcode_direct=yes
- hardcode_shlibpath_var=no
- ;;
-
- hpux9*)
- if test "$GCC" = yes; then
- archive_cmds='$RM $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
- else
- archive_cmds='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
- fi
- hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
- hardcode_libdir_separator=:
- hardcode_direct=yes
-
- # hardcode_minus_L: Not really in the search PATH,
- # but as the default location of the library.
- hardcode_minus_L=yes
- export_dynamic_flag_spec='${wl}-E'
- ;;
-
- hpux10*)
- if test "$GCC" = yes && test "$with_gnu_ld" = no; then
- archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
- else
- archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
- fi
- if test "$with_gnu_ld" = no; then
- hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
- hardcode_libdir_flag_spec_ld='+b $libdir'
- hardcode_libdir_separator=:
- hardcode_direct=yes
- hardcode_direct_absolute=yes
- export_dynamic_flag_spec='${wl}-E'
- # hardcode_minus_L: Not really in the search PATH,
- # but as the default location of the library.
- hardcode_minus_L=yes
- fi
- ;;
-
- hpux11*)
- if test "$GCC" = yes && test "$with_gnu_ld" = no; then
- case $host_cpu in
- hppa*64*)
- archive_cmds='$CC -shared ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
- ;;
- ia64*)
- archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
- ;;
- *)
- archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
- ;;
- esac
- else
- case $host_cpu in
- hppa*64*)
- archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
- ;;
- ia64*)
- archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
- ;;
- *)
-
- # Older versions of the 11.00 compiler do not understand -b yet
- # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does)
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC understands -b" >&5
-$as_echo_n "checking if $CC understands -b... " >&6; }
-if ${lt_cv_prog_compiler__b+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_prog_compiler__b=no
- save_LDFLAGS="$LDFLAGS"
- LDFLAGS="$LDFLAGS -b"
- echo "$lt_simple_link_test_code" > conftest.$ac_ext
- if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
- # The linker can only warn and ignore the option if not recognized
- # So say no if there are warnings
- if test -s conftest.err; then
- # Append any errors to the config.log.
- cat conftest.err 1>&5
- $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
- $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
- if diff conftest.exp conftest.er2 >/dev/null; then
- lt_cv_prog_compiler__b=yes
- fi
- else
- lt_cv_prog_compiler__b=yes
- fi
- fi
- $RM -r conftest*
- LDFLAGS="$save_LDFLAGS"
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler__b" >&5
-$as_echo "$lt_cv_prog_compiler__b" >&6; }
-
-if test x"$lt_cv_prog_compiler__b" = xyes; then
- archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
-else
- archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
-fi
-
- ;;
- esac
- fi
- if test "$with_gnu_ld" = no; then
- hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
- hardcode_libdir_separator=:
-
- case $host_cpu in
- hppa*64*|ia64*)
- hardcode_direct=no
- hardcode_shlibpath_var=no
- ;;
- *)
- hardcode_direct=yes
- hardcode_direct_absolute=yes
- export_dynamic_flag_spec='${wl}-E'
-
- # hardcode_minus_L: Not really in the search PATH,
- # but as the default location of the library.
- hardcode_minus_L=yes
- ;;
- esac
- fi
- ;;
-
- irix5* | irix6* | nonstopux*)
- if test "$GCC" = yes; then
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
- # Try to use the -exported_symbol ld option, if it does not
- # work, assume that -exports_file does not work either and
- # implicitly export all symbols.
- save_LDFLAGS="$LDFLAGS"
- LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-int foo(void) {}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
-
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LDFLAGS="$save_LDFLAGS"
- else
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
- fi
- archive_cmds_need_lc='no'
- hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
- hardcode_libdir_separator=:
- inherit_rpath=yes
- link_all_deplibs=yes
- ;;
-
- netbsd*)
- if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
- archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out
- else
- archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF
- fi
- hardcode_libdir_flag_spec='-R$libdir'
- hardcode_direct=yes
- hardcode_shlibpath_var=no
- ;;
-
- newsos6)
- archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
- hardcode_direct=yes
- hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
- hardcode_libdir_separator=:
- hardcode_shlibpath_var=no
- ;;
-
- *nto* | *qnx*)
- ;;
-
- openbsd*)
- if test -f /usr/libexec/ld.so; then
- hardcode_direct=yes
- hardcode_shlibpath_var=no
- hardcode_direct_absolute=yes
- if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
- archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
- archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
- hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
- export_dynamic_flag_spec='${wl}-E'
- else
- case $host_os in
- openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*)
- archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
- hardcode_libdir_flag_spec='-R$libdir'
- ;;
- *)
- archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
- hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
- ;;
- esac
- fi
- else
- ld_shlibs=no
- fi
- ;;
-
- os2*)
- hardcode_libdir_flag_spec='-L$libdir'
- hardcode_minus_L=yes
- allow_undefined_flag=unsupported
- archive_cmds='$ECHO "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~echo DATA >> $output_objdir/$libname.def~echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def'
- old_archive_from_new_cmds='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
- ;;
-
- osf3*)
- if test "$GCC" = yes; then
- allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
- archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
- else
- allow_undefined_flag=' -expect_unresolved \*'
- archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
- fi
- archive_cmds_need_lc='no'
- hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
- hardcode_libdir_separator=:
- ;;
-
- osf4* | osf5*) # as osf3* with the addition of -msym flag
- if test "$GCC" = yes; then
- allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
- archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
- hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
- else
- allow_undefined_flag=' -expect_unresolved \*'
- archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
- archive_expsym_cmds='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~
- $CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp'
-
- # Both c and cxx compiler support -rpath directly
- hardcode_libdir_flag_spec='-rpath $libdir'
- fi
- archive_cmds_need_lc='no'
- hardcode_libdir_separator=:
- ;;
-
- solaris*)
- no_undefined_flag=' -z defs'
- if test "$GCC" = yes; then
- wlarc='${wl}'
- archive_cmds='$CC -shared ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
- archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
- $CC -shared ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
- else
- case `$CC -V 2>&1` in
- *"Compilers 5.0"*)
- wlarc=''
- archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
- archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
- $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp'
- ;;
- *)
- wlarc='${wl}'
- archive_cmds='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags'
- archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
- $CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
- ;;
- esac
- fi
- hardcode_libdir_flag_spec='-R$libdir'
- hardcode_shlibpath_var=no
- case $host_os in
- solaris2.[0-5] | solaris2.[0-5].*) ;;
- *)
- # The compiler driver will combine and reorder linker options,
- # but understands `-z linker_flag'. GCC discards it without `$wl',
- # but is careful enough not to reorder.
- # Supported since Solaris 2.6 (maybe 2.5.1?)
- if test "$GCC" = yes; then
- whole_archive_flag_spec='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
- else
- whole_archive_flag_spec='-z allextract$convenience -z defaultextract'
- fi
- ;;
- esac
- link_all_deplibs=yes
- ;;
-
- sunos4*)
- if test "x$host_vendor" = xsequent; then
- # Use $CC to link under sequent, because it throws in some extra .o
- # files that make .init and .fini sections work.
- archive_cmds='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
- else
- archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
- fi
- hardcode_libdir_flag_spec='-L$libdir'
- hardcode_direct=yes
- hardcode_minus_L=yes
- hardcode_shlibpath_var=no
- ;;
-
- sysv4)
- case $host_vendor in
- sni)
- archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
- hardcode_direct=yes # is this really true???
- ;;
- siemens)
- ## LD is ld it makes a PLAMLIB
- ## CC just makes a GrossModule.
- archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags'
- reload_cmds='$CC -r -o $output$reload_objs'
- hardcode_direct=no
- ;;
- motorola)
- archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
- hardcode_direct=no #Motorola manual says yes, but my tests say they lie
- ;;
- esac
- runpath_var='LD_RUN_PATH'
- hardcode_shlibpath_var=no
- ;;
-
- sysv4.3*)
- archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
- hardcode_shlibpath_var=no
- export_dynamic_flag_spec='-Bexport'
- ;;
-
- sysv4*MP*)
- if test -d /usr/nec; then
- archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
- hardcode_shlibpath_var=no
- runpath_var=LD_RUN_PATH
- hardcode_runpath_var=yes
- ld_shlibs=yes
- fi
- ;;
-
- sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*)
- no_undefined_flag='${wl}-z,text'
- archive_cmds_need_lc=no
- hardcode_shlibpath_var=no
- runpath_var='LD_RUN_PATH'
-
- if test "$GCC" = yes; then
- archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- else
- archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- fi
- ;;
-
- sysv5* | sco3.2v5* | sco5v6*)
- # Note: We can NOT use -z defs as we might desire, because we do not
- # link with -lc, and that would cause any symbols used from libc to
- # always be unresolved, which means just about no library would
- # ever link correctly. If we're not using GNU ld we use -z text
- # though, which does catch some bad symbols but isn't as heavy-handed
- # as -z defs.
- no_undefined_flag='${wl}-z,text'
- allow_undefined_flag='${wl}-z,nodefs'
- archive_cmds_need_lc=no
- hardcode_shlibpath_var=no
- hardcode_libdir_flag_spec='${wl}-R,$libdir'
- hardcode_libdir_separator=':'
- link_all_deplibs=yes
- export_dynamic_flag_spec='${wl}-Bexport'
- runpath_var='LD_RUN_PATH'
-
- if test "$GCC" = yes; then
- archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- else
- archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- fi
- ;;
-
- uts4*)
- archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
- hardcode_libdir_flag_spec='-L$libdir'
- hardcode_shlibpath_var=no
- ;;
-
- *)
- ld_shlibs=no
- ;;
- esac
-
- if test x$host_vendor = xsni; then
- case $host in
- sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
- export_dynamic_flag_spec='${wl}-Blargedynsym'
- ;;
- esac
- fi
- fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs" >&5
-$as_echo "$ld_shlibs" >&6; }
-test "$ld_shlibs" = no && can_build_shared=no
-
-with_gnu_ld=$with_gnu_ld
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-#
-# Do we need to explicitly link libc?
-#
-case "x$archive_cmds_need_lc" in
-x|xyes)
- # Assume -lc should be added
- archive_cmds_need_lc=yes
-
- if test "$enable_shared" = yes && test "$GCC" = yes; then
- case $archive_cmds in
- *'~'*)
- # FIXME: we may have to deal with multi-command sequences.
- ;;
- '$CC '*)
- # Test whether the compiler implicitly links with -lc since on some
- # systems, -lgcc has to come before -lc. If gcc already passes -lc
- # to ld, don't add -lc before -lgcc.
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5
-$as_echo_n "checking whether -lc should be explicitly linked in... " >&6; }
-if ${lt_cv_archive_cmds_need_lc+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- $RM conftest*
- echo "$lt_simple_compile_test_code" > conftest.$ac_ext
-
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
- (eval $ac_compile) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } 2>conftest.err; then
- soname=conftest
- lib=conftest
- libobjs=conftest.$ac_objext
- deplibs=
- wl=$lt_prog_compiler_wl
- pic_flag=$lt_prog_compiler_pic
- compiler_flags=-v
- linker_flags=-v
- verstring=
- output_objdir=.
- libname=conftest
- lt_save_allow_undefined_flag=$allow_undefined_flag
- allow_undefined_flag=
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5
- (eval $archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }
- then
- lt_cv_archive_cmds_need_lc=no
- else
- lt_cv_archive_cmds_need_lc=yes
- fi
- allow_undefined_flag=$lt_save_allow_undefined_flag
- else
- cat conftest.err 1>&5
- fi
- $RM conftest*
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc" >&5
-$as_echo "$lt_cv_archive_cmds_need_lc" >&6; }
- archive_cmds_need_lc=$lt_cv_archive_cmds_need_lc
- ;;
- esac
- fi
- ;;
-esac
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5
-$as_echo_n "checking dynamic linker characteristics... " >&6; }
-
-if test "$GCC" = yes; then
- case $host_os in
- darwin*) lt_awk_arg="/^libraries:/,/LR/" ;;
- *) lt_awk_arg="/^libraries:/" ;;
- esac
- case $host_os in
- mingw* | cegcc*) lt_sed_strip_eq="s,=\([A-Za-z]:\),\1,g" ;;
- *) lt_sed_strip_eq="s,=/,/,g" ;;
- esac
- lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq`
- case $lt_search_path_spec in
- *\;*)
- # if the path contains ";" then we assume it to be the separator
- # otherwise default to the standard path separator (i.e. ":") - it is
- # assumed that no part of a normal pathname contains ";" but that should
- # okay in the real world where ";" in dirpaths is itself problematic.
- lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'`
- ;;
- *)
- lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"`
- ;;
- esac
- # Ok, now we have the path, separated by spaces, we can step through it
- # and add multilib dir if necessary.
- lt_tmp_lt_search_path_spec=
- lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
- for lt_sys_path in $lt_search_path_spec; do
- if test -d "$lt_sys_path/$lt_multi_os_dir"; then
- lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir"
- else
- test -d "$lt_sys_path" && \
- lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
- fi
- done
- lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk '
-BEGIN {RS=" "; FS="/|\n";} {
- lt_foo="";
- lt_count=0;
- for (lt_i = NF; lt_i > 0; lt_i--) {
- if ($lt_i != "" && $lt_i != ".") {
- if ($lt_i == "..") {
- lt_count++;
- } else {
- if (lt_count == 0) {
- lt_foo="/" $lt_i lt_foo;
- } else {
- lt_count--;
- }
- }
- }
- }
- if (lt_foo != "") { lt_freq[lt_foo]++; }
- if (lt_freq[lt_foo] == 1) { print lt_foo; }
-}'`
- # AWK program above erroneously prepends '/' to C:/dos/paths
- # for these hosts.
- case $host_os in
- mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\
- $SED 's,/\([A-Za-z]:\),\1,g'` ;;
- esac
- sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP`
-else
- sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
-fi
-library_names_spec=
-libname_spec='lib$name'
-soname_spec=
-shrext_cmds=".so"
-postinstall_cmds=
-postuninstall_cmds=
-finish_cmds=
-finish_eval=
-shlibpath_var=
-shlibpath_overrides_runpath=unknown
-version_type=none
-dynamic_linker="$host_os ld.so"
-sys_lib_dlsearch_path_spec="/lib /usr/lib"
-need_lib_prefix=unknown
-hardcode_into_libs=no
-
-# when you set need_version to no, make sure it does not cause -set_version
-# flags to be left without arguments
-need_version=unknown
-
-case $host_os in
-aix3*)
- version_type=linux
- library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
- shlibpath_var=LIBPATH
-
- # AIX 3 has no versioning support, so we append a major version to the name.
- soname_spec='${libname}${release}${shared_ext}$major'
- ;;
-
-aix[4-9]*)
- version_type=linux
- need_lib_prefix=no
- need_version=no
- hardcode_into_libs=yes
- if test "$host_cpu" = ia64; then
- # AIX 5 supports IA64
- library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
- shlibpath_var=LD_LIBRARY_PATH
- else
- # With GCC up to 2.95.x, collect2 would create an import file
- # for dependence libraries. The import file would start with
- # the line `#! .'. This would cause the generated library to
- # depend on `.', always an invalid library. This was fixed in
- # development snapshots of GCC prior to 3.0.
- case $host_os in
- aix4 | aix4.[01] | aix4.[01].*)
- if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
- echo ' yes '
- echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then
- :
- else
- can_build_shared=no
- fi
- ;;
- esac
- # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
- # soname into executable. Probably we can add versioning support to
- # collect2, so additional links can be useful in future.
- if test "$aix_use_runtimelinking" = yes; then
- # If using run time linking (on AIX 4.2 or later) use lib<name>.so
- # instead of lib<name>.a to let people know that these are not
- # typical AIX shared libraries.
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- else
- # We preserve .a as extension for shared libraries through AIX4.2
- # and later when we are not doing run time linking.
- library_names_spec='${libname}${release}.a $libname.a'
- soname_spec='${libname}${release}${shared_ext}$major'
- fi
- shlibpath_var=LIBPATH
- fi
- ;;
-
-amigaos*)
- case $host_cpu in
- powerpc)
- # Since July 2007 AmigaOS4 officially supports .so libraries.
- # When compiling the executable, add -use-dynld -Lsobjs: to the compileline.
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- ;;
- m68k)
- library_names_spec='$libname.ixlibrary $libname.a'
- # Create ${libname}_ixlibrary.a entries in /sys/libs.
- finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done'
- ;;
- esac
- ;;
-
-beos*)
- library_names_spec='${libname}${shared_ext}'
- dynamic_linker="$host_os ld.so"
- shlibpath_var=LIBRARY_PATH
- ;;
-
-bsdi[45]*)
- version_type=linux
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
- shlibpath_var=LD_LIBRARY_PATH
- sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
- sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
- # the default ld.so.conf also contains /usr/contrib/lib and
- # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
- # libtool to hard-code these into programs
- ;;
-
-cygwin* | mingw* | pw32* | cegcc*)
- version_type=windows
- shrext_cmds=".dll"
- need_version=no
- need_lib_prefix=no
-
- case $GCC,$host_os in
- yes,cygwin* | yes,mingw* | yes,pw32* | yes,cegcc*)
- library_names_spec='$libname.dll.a'
- # DLL is installed to $(libdir)/../bin by postinstall_cmds
- postinstall_cmds='base_file=`basename \${file}`~
- dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
- dldir=$destdir/`dirname \$dlpath`~
- test -d \$dldir || mkdir -p \$dldir~
- $install_prog $dir/$dlname \$dldir/$dlname~
- chmod a+x \$dldir/$dlname~
- if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
- eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
- fi'
- postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
- dlpath=$dir/\$dldll~
- $RM \$dlpath'
- shlibpath_overrides_runpath=yes
-
- case $host_os in
- cygwin*)
- # Cygwin DLLs use 'cyg' prefix rather than 'lib'
- soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
-
- sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"
- ;;
- mingw* | cegcc*)
- # MinGW DLLs use traditional 'lib' prefix
- soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
- ;;
- pw32*)
- # pw32 DLLs use 'pw' prefix rather than 'lib'
- library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
- ;;
- esac
- ;;
-
- *)
- library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib'
- ;;
- esac
- dynamic_linker='Win32 ld.exe'
- # FIXME: first we should search . and the directory the executable is in
- shlibpath_var=PATH
- ;;
-
-darwin* | rhapsody*)
- dynamic_linker="$host_os dyld"
- version_type=darwin
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext'
- soname_spec='${libname}${release}${major}$shared_ext'
- shlibpath_overrides_runpath=yes
- shlibpath_var=DYLD_LIBRARY_PATH
- shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
-
- sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"
- sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
- ;;
-
-dgux*)
- version_type=linux
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
- soname_spec='${libname}${release}${shared_ext}$major'
- shlibpath_var=LD_LIBRARY_PATH
- ;;
-
-freebsd* | dragonfly*)
- # DragonFly does not have aout. When/if they implement a new
- # versioning mechanism, adjust this.
- if test -x /usr/bin/objformat; then
- objformat=`/usr/bin/objformat`
- else
- case $host_os in
- freebsd[23].*) objformat=aout ;;
- *) objformat=elf ;;
- esac
- fi
- version_type=freebsd-$objformat
- case $version_type in
- freebsd-elf*)
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
- need_version=no
- need_lib_prefix=no
- ;;
- freebsd-*)
- library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
- need_version=yes
- ;;
- esac
- shlibpath_var=LD_LIBRARY_PATH
- case $host_os in
- freebsd2.*)
- shlibpath_overrides_runpath=yes
- ;;
- freebsd3.[01]* | freebsdelf3.[01]*)
- shlibpath_overrides_runpath=yes
- hardcode_into_libs=yes
- ;;
- freebsd3.[2-9]* | freebsdelf3.[2-9]* | \
- freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1)
- shlibpath_overrides_runpath=no
- hardcode_into_libs=yes
- ;;
- *) # from 4.6 on, and DragonFly
- shlibpath_overrides_runpath=yes
- hardcode_into_libs=yes
- ;;
- esac
- ;;
-
-haiku*)
- version_type=linux
- need_lib_prefix=no
- need_version=no
- dynamic_linker="$host_os runtime_loader"
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- shlibpath_var=LIBRARY_PATH
- shlibpath_overrides_runpath=yes
- sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
- hardcode_into_libs=yes
- ;;
-
-hpux9* | hpux10* | hpux11*)
- # Give a soname corresponding to the major version so that dld.sl refuses to
- # link against other versions.
- version_type=sunos
- need_lib_prefix=no
- need_version=no
- case $host_cpu in
- ia64*)
- shrext_cmds='.so'
- hardcode_into_libs=yes
- dynamic_linker="$host_os dld.so"
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- if test "X$HPUX_IA64_MODE" = X32; then
- sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
- else
- sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
- fi
- sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
- ;;
- hppa*64*)
- shrext_cmds='.sl'
- hardcode_into_libs=yes
- dynamic_linker="$host_os dld.sl"
- shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
- shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
- sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
- ;;
- *)
- shrext_cmds='.sl'
- dynamic_linker="$host_os dld.sl"
- shlibpath_var=SHLIB_PATH
- shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- ;;
- esac
- # HP-UX runs *really* slowly unless shared libraries are mode 555, ...
- postinstall_cmds='chmod 555 $lib'
- # or fails outright, so override atomically:
- install_override_mode=555
- ;;
-
-interix[3-9]*)
- version_type=linux
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=no
- hardcode_into_libs=yes
- ;;
-
-irix5* | irix6* | nonstopux*)
- case $host_os in
- nonstopux*) version_type=nonstopux ;;
- *)
- if test "$lt_cv_prog_gnu_ld" = yes; then
- version_type=linux
- else
- version_type=irix
- fi ;;
- esac
- need_lib_prefix=no
- need_version=no
- soname_spec='${libname}${release}${shared_ext}$major'
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
- case $host_os in
- irix5* | nonstopux*)
- libsuff= shlibsuff=
- ;;
- *)
- case $LD in # libtool.m4 will add one of these switches to LD
- *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
- libsuff= shlibsuff= libmagic=32-bit;;
- *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
- libsuff=32 shlibsuff=N32 libmagic=N32;;
- *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
- libsuff=64 shlibsuff=64 libmagic=64-bit;;
- *) libsuff= shlibsuff= libmagic=never-match;;
- esac
- ;;
- esac
- shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
- shlibpath_overrides_runpath=no
- sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
- sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
- hardcode_into_libs=yes
- ;;
-
-# No shared lib support for Linux oldld, aout, or coff.
-linux*oldld* | linux*aout* | linux*coff*)
- dynamic_linker=no
- ;;
-
-# This must be Linux ELF.
-
-# uclinux* changes (here and below) have been submitted to the libtool
-# project, but have not yet been accepted: they are GCC-local changes
-# for the time being. (See
-# https://lists.gnu.org/archive/html/libtool-patches/2018-05/msg00000.html)
-linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu* | uclinuxfdpiceabi)
- version_type=linux
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=no
-
- # Some binutils ld are patched to set DT_RUNPATH
- if ${lt_cv_shlibpath_overrides_runpath+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_shlibpath_overrides_runpath=no
- save_LDFLAGS=$LDFLAGS
- save_libdir=$libdir
- eval "libdir=/foo; wl=\"$lt_prog_compiler_wl\"; \
- LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec\""
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- if ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then :
- lt_cv_shlibpath_overrides_runpath=yes
-fi
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LDFLAGS=$save_LDFLAGS
- libdir=$save_libdir
-
-fi
-
- shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath
-
- # This implies no fast_install, which is unacceptable.
- # Some rework will be needed to allow for fast_install
- # before this can be enabled.
- hardcode_into_libs=yes
-
- # find out which ABI we are using
- libsuff=
- case "$host_cpu" in
- x86_64*|s390*|powerpc*|ppc*|sparc*)
- echo 'int i;' > conftest.$ac_ext
- if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; then
- case `/usr/bin/file conftest.$ac_objext` in
- *64-bit*)
- libsuff=
- if test x"$sys_lib_search_path_spec" = x"/lib /usr/lib /usr/local/lib"; then
- sys_lib_search_path_spec="/lib${libsuff} /usr/lib${libsuff} /usr/local/lib${libsuff}"
- fi
- sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff}"
- ;;
- *32-bit*)
- libsuff=32
- if test x"$sys_lib_search_path_spec" = x"/lib /usr/lib /usr/local/lib"; then
- sys_lib_search_path_spec="/lib${libsuff} /usr/lib${libsuff} /usr/local/lib${libsuff}"
- fi
- sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff}"
- ;;
- esac
- fi
- rm -rf conftest*
- ;;
- esac
-
- # Append ld.so.conf contents to the search path
- if test -f /etc/ld.so.conf; then
- lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '`
- sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff} $lt_ld_extra"
- fi
-
- # We used to test for /lib/ld.so.1 and disable shared libraries on
- # powerpc, because MkLinux only supported shared libraries with the
- # GNU dynamic linker. Since this was broken with cross compilers,
- # most powerpc-linux boxes support dynamic linking these days and
- # people can always --disable-shared, the test was removed, and we
- # assume the GNU/Linux dynamic linker is in use.
- dynamic_linker='GNU/Linux ld.so'
- ;;
-
-netbsd*)
- version_type=sunos
- need_lib_prefix=no
- need_version=no
- if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
- finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
- dynamic_linker='NetBSD (a.out) ld.so'
- else
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- dynamic_linker='NetBSD ld.elf_so'
- fi
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=yes
- hardcode_into_libs=yes
- ;;
-
-newsos6)
- version_type=linux
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=yes
- ;;
-
-*nto* | *qnx*)
- version_type=qnx
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=no
- hardcode_into_libs=yes
- dynamic_linker='ldqnx.so'
- ;;
-
-openbsd*)
- version_type=sunos
- sys_lib_dlsearch_path_spec="/usr/lib"
- need_lib_prefix=no
- # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
- case $host_os in
- openbsd3.3 | openbsd3.3.*) need_version=yes ;;
- *) need_version=no ;;
- esac
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
- finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
- shlibpath_var=LD_LIBRARY_PATH
- if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
- case $host_os in
- openbsd2.[89] | openbsd2.[89].*)
- shlibpath_overrides_runpath=no
- ;;
- *)
- shlibpath_overrides_runpath=yes
- ;;
- esac
- else
- shlibpath_overrides_runpath=yes
- fi
- ;;
-
-os2*)
- libname_spec='$name'
- shrext_cmds=".dll"
- need_lib_prefix=no
- library_names_spec='$libname${shared_ext} $libname.a'
- dynamic_linker='OS/2 ld.exe'
- shlibpath_var=LIBPATH
- ;;
-
-osf3* | osf4* | osf5*)
- version_type=osf
- need_lib_prefix=no
- need_version=no
- soname_spec='${libname}${release}${shared_ext}$major'
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- shlibpath_var=LD_LIBRARY_PATH
- sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
- sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
- ;;
-
-rdos*)
- dynamic_linker=no
- ;;
-
-solaris*)
- version_type=linux
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=yes
- hardcode_into_libs=yes
- # ldd complains unless libraries are executable
- postinstall_cmds='chmod +x $lib'
- ;;
-
-sunos4*)
- version_type=sunos
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
- finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=yes
- if test "$with_gnu_ld" = yes; then
- need_lib_prefix=no
- fi
- need_version=yes
- ;;
-
-sysv4 | sysv4.3*)
- version_type=linux
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- shlibpath_var=LD_LIBRARY_PATH
- case $host_vendor in
- sni)
- shlibpath_overrides_runpath=no
- need_lib_prefix=no
- runpath_var=LD_RUN_PATH
- ;;
- siemens)
- need_lib_prefix=no
- ;;
- motorola)
- need_lib_prefix=no
- need_version=no
- shlibpath_overrides_runpath=no
- sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
- ;;
- esac
- ;;
-
-sysv4*MP*)
- if test -d /usr/nec ;then
- version_type=linux
- library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
- soname_spec='$libname${shared_ext}.$major'
- shlibpath_var=LD_LIBRARY_PATH
- fi
- ;;
-
-sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
- version_type=freebsd-elf
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=yes
- hardcode_into_libs=yes
- if test "$with_gnu_ld" = yes; then
- sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
- else
- sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
- case $host_os in
- sco3.2v5*)
- sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
- ;;
- esac
- fi
- sys_lib_dlsearch_path_spec='/usr/lib'
- ;;
-
-tpf*)
- # TPF is a cross-target only. Preferred cross-host = GNU/Linux.
- version_type=linux
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=no
- hardcode_into_libs=yes
- ;;
-
-uts4*)
- version_type=linux
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- shlibpath_var=LD_LIBRARY_PATH
- ;;
-
-# Shared libraries for VwWorks, >= 7 only at this stage
-# and (fpic) still incompatible with "large" code models
-# in a few configurations. Only for RTP mode in any case,
-# and upon explicit request at configure time.
-vxworks7*)
- dynamic_linker=no
- case ${with_multisubdir}-${enable_shared} in
- *large*)
- ;;
- *mrtp*-yes)
- version_type=linux
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- dynamic_linker="$host_os module_loader"
- ;;
- esac
- ;;
-*)
- dynamic_linker=no
- ;;
-esac
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5
-$as_echo "$dynamic_linker" >&6; }
-test "$dynamic_linker" = no && can_build_shared=no
-
-variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
-if test "$GCC" = yes; then
- variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
-fi
-
-if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then
- sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec"
-fi
-if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then
- sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec"
-fi
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5
-$as_echo_n "checking how to hardcode library paths into programs... " >&6; }
-hardcode_action=
-if test -n "$hardcode_libdir_flag_spec" ||
- test -n "$runpath_var" ||
- test "X$hardcode_automatic" = "Xyes" ; then
-
- # We can hardcode non-existent directories.
- if test "$hardcode_direct" != no &&
- # If the only mechanism to avoid hardcoding is shlibpath_var, we
- # have to relink, otherwise we might link with an installed library
- # when we should be linking with a yet-to-be-installed one
- ## test "$_LT_TAGVAR(hardcode_shlibpath_var, )" != no &&
- test "$hardcode_minus_L" != no; then
- # Linking always hardcodes the temporary library directory.
- hardcode_action=relink
- else
- # We can link without hardcoding, and we can hardcode nonexisting dirs.
- hardcode_action=immediate
- fi
-else
- # We cannot hardcode anything, or else we can only hardcode existing
- # directories.
- hardcode_action=unsupported
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action" >&5
-$as_echo "$hardcode_action" >&6; }
-
-if test "$hardcode_action" = relink ||
- test "$inherit_rpath" = yes; then
- # Fast installation is not supported
- enable_fast_install=no
-elif test "$shlibpath_overrides_runpath" = yes ||
- test "$enable_shared" = no; then
- # Fast installation is not necessary
- enable_fast_install=needless
-fi
-
-
-
-
-
-
- if test "x$enable_dlopen" != xyes; then
- enable_dlopen=unknown
- enable_dlopen_self=unknown
- enable_dlopen_self_static=unknown
-else
- lt_cv_dlopen=no
- lt_cv_dlopen_libs=
-
- case $host_os in
- beos*)
- lt_cv_dlopen="load_add_on"
- lt_cv_dlopen_libs=
- lt_cv_dlopen_self=yes
- ;;
-
- mingw* | pw32* | cegcc*)
- lt_cv_dlopen="LoadLibrary"
- lt_cv_dlopen_libs=
- ;;
-
- cygwin*)
- lt_cv_dlopen="dlopen"
- lt_cv_dlopen_libs=
- ;;
-
- darwin*)
- # if libdl is installed we need to link against it
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
-$as_echo_n "checking for dlopen in -ldl... " >&6; }
-if ${ac_cv_lib_dl_dlopen+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-ldl $LIBS"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char dlopen ();
-int
-main ()
-{
-return dlopen ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_lib_dl_dlopen=yes
-else
- ac_cv_lib_dl_dlopen=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
-$as_echo "$ac_cv_lib_dl_dlopen" >&6; }
-if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
- lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
-else
-
- lt_cv_dlopen="dyld"
- lt_cv_dlopen_libs=
- lt_cv_dlopen_self=yes
-
-fi
-
- ;;
-
- *)
- ac_fn_c_check_func "$LINENO" "shl_load" "ac_cv_func_shl_load"
-if test "x$ac_cv_func_shl_load" = xyes; then :
- lt_cv_dlopen="shl_load"
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5
-$as_echo_n "checking for shl_load in -ldld... " >&6; }
-if ${ac_cv_lib_dld_shl_load+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-ldld $LIBS"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char shl_load ();
-int
-main ()
-{
-return shl_load ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_lib_dld_shl_load=yes
-else
- ac_cv_lib_dld_shl_load=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5
-$as_echo "$ac_cv_lib_dld_shl_load" >&6; }
-if test "x$ac_cv_lib_dld_shl_load" = xyes; then :
- lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"
-else
- ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen"
-if test "x$ac_cv_func_dlopen" = xyes; then :
- lt_cv_dlopen="dlopen"
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
-$as_echo_n "checking for dlopen in -ldl... " >&6; }
-if ${ac_cv_lib_dl_dlopen+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-ldl $LIBS"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char dlopen ();
-int
-main ()
-{
-return dlopen ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_lib_dl_dlopen=yes
-else
- ac_cv_lib_dl_dlopen=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
-$as_echo "$ac_cv_lib_dl_dlopen" >&6; }
-if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
- lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5
-$as_echo_n "checking for dlopen in -lsvld... " >&6; }
-if ${ac_cv_lib_svld_dlopen+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-lsvld $LIBS"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char dlopen ();
-int
-main ()
-{
-return dlopen ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_lib_svld_dlopen=yes
-else
- ac_cv_lib_svld_dlopen=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5
-$as_echo "$ac_cv_lib_svld_dlopen" >&6; }
-if test "x$ac_cv_lib_svld_dlopen" = xyes; then :
- lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5
-$as_echo_n "checking for dld_link in -ldld... " >&6; }
-if ${ac_cv_lib_dld_dld_link+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-ldld $LIBS"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char dld_link ();
-int
-main ()
-{
-return dld_link ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_lib_dld_dld_link=yes
-else
- ac_cv_lib_dld_dld_link=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_dld_link" >&5
-$as_echo "$ac_cv_lib_dld_dld_link" >&6; }
-if test "x$ac_cv_lib_dld_dld_link" = xyes; then :
- lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"
-fi
-
-
-fi
-
-
-fi
-
-
-fi
-
-
-fi
-
-
-fi
-
- ;;
- esac
-
- if test "x$lt_cv_dlopen" != xno; then
- enable_dlopen=yes
- else
- enable_dlopen=no
- fi
-
- case $lt_cv_dlopen in
- dlopen)
- save_CPPFLAGS="$CPPFLAGS"
- test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
-
- save_LDFLAGS="$LDFLAGS"
- wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
-
- save_LIBS="$LIBS"
- LIBS="$lt_cv_dlopen_libs $LIBS"
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a program can dlopen itself" >&5
-$as_echo_n "checking whether a program can dlopen itself... " >&6; }
-if ${lt_cv_dlopen_self+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test "$cross_compiling" = yes; then :
- lt_cv_dlopen_self=cross
-else
- lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
- lt_status=$lt_dlunknown
- cat > conftest.$ac_ext <<_LT_EOF
-#line 10656 "configure"
-#include "confdefs.h"
-
-#if HAVE_DLFCN_H
-#include <dlfcn.h>
-#endif
-
-#include <stdio.h>
-
-#ifdef RTLD_GLOBAL
-# define LT_DLGLOBAL RTLD_GLOBAL
-#else
-# ifdef DL_GLOBAL
-# define LT_DLGLOBAL DL_GLOBAL
-# else
-# define LT_DLGLOBAL 0
-# endif
-#endif
-
-/* We may have to define LT_DLLAZY_OR_NOW in the command line if we
- find out it does not work in some platform. */
-#ifndef LT_DLLAZY_OR_NOW
-# ifdef RTLD_LAZY
-# define LT_DLLAZY_OR_NOW RTLD_LAZY
-# else
-# ifdef DL_LAZY
-# define LT_DLLAZY_OR_NOW DL_LAZY
-# else
-# ifdef RTLD_NOW
-# define LT_DLLAZY_OR_NOW RTLD_NOW
-# else
-# ifdef DL_NOW
-# define LT_DLLAZY_OR_NOW DL_NOW
-# else
-# define LT_DLLAZY_OR_NOW 0
-# endif
-# endif
-# endif
-# endif
-#endif
-
-/* When -fvisbility=hidden is used, assume the code has been annotated
- correspondingly for the symbols needed. */
-#if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
-void fnord () __attribute__((visibility("default")));
-#endif
-
-void fnord () { int i=42; }
-int main ()
-{
- void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
- int status = $lt_dlunknown;
-
- if (self)
- {
- if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
- else
- {
- if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
- else puts (dlerror ());
- }
- /* dlclose (self); */
- }
- else
- puts (dlerror ());
-
- return status;
-}
-_LT_EOF
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
- (eval $ac_link) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then
- (./conftest; exit; ) >&5 2>/dev/null
- lt_status=$?
- case x$lt_status in
- x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;;
- x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;;
- x$lt_dlunknown|x*) lt_cv_dlopen_self=no ;;
- esac
- else :
- # compilation failed
- lt_cv_dlopen_self=no
- fi
-fi
-rm -fr conftest*
-
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self" >&5
-$as_echo "$lt_cv_dlopen_self" >&6; }
-
- if test "x$lt_cv_dlopen_self" = xyes; then
- wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a statically linked program can dlopen itself" >&5
-$as_echo_n "checking whether a statically linked program can dlopen itself... " >&6; }
-if ${lt_cv_dlopen_self_static+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test "$cross_compiling" = yes; then :
- lt_cv_dlopen_self_static=cross
-else
- lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
- lt_status=$lt_dlunknown
- cat > conftest.$ac_ext <<_LT_EOF
-#line 10762 "configure"
-#include "confdefs.h"
-
-#if HAVE_DLFCN_H
-#include <dlfcn.h>
-#endif
-
-#include <stdio.h>
-
-#ifdef RTLD_GLOBAL
-# define LT_DLGLOBAL RTLD_GLOBAL
-#else
-# ifdef DL_GLOBAL
-# define LT_DLGLOBAL DL_GLOBAL
-# else
-# define LT_DLGLOBAL 0
-# endif
-#endif
-
-/* We may have to define LT_DLLAZY_OR_NOW in the command line if we
- find out it does not work in some platform. */
-#ifndef LT_DLLAZY_OR_NOW
-# ifdef RTLD_LAZY
-# define LT_DLLAZY_OR_NOW RTLD_LAZY
-# else
-# ifdef DL_LAZY
-# define LT_DLLAZY_OR_NOW DL_LAZY
-# else
-# ifdef RTLD_NOW
-# define LT_DLLAZY_OR_NOW RTLD_NOW
-# else
-# ifdef DL_NOW
-# define LT_DLLAZY_OR_NOW DL_NOW
-# else
-# define LT_DLLAZY_OR_NOW 0
-# endif
-# endif
-# endif
-# endif
-#endif
-
-/* When -fvisbility=hidden is used, assume the code has been annotated
- correspondingly for the symbols needed. */
-#if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
-void fnord () __attribute__((visibility("default")));
-#endif
-
-void fnord () { int i=42; }
-int main ()
-{
- void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
- int status = $lt_dlunknown;
-
- if (self)
- {
- if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
- else
- {
- if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
- else puts (dlerror ());
- }
- /* dlclose (self); */
- }
- else
- puts (dlerror ());
-
- return status;
-}
-_LT_EOF
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
- (eval $ac_link) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then
- (./conftest; exit; ) >&5 2>/dev/null
- lt_status=$?
- case x$lt_status in
- x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;;
- x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;;
- x$lt_dlunknown|x*) lt_cv_dlopen_self_static=no ;;
- esac
- else :
- # compilation failed
- lt_cv_dlopen_self_static=no
- fi
-fi
-rm -fr conftest*
-
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self_static" >&5
-$as_echo "$lt_cv_dlopen_self_static" >&6; }
- fi
-
- CPPFLAGS="$save_CPPFLAGS"
- LDFLAGS="$save_LDFLAGS"
- LIBS="$save_LIBS"
- ;;
- esac
-
- case $lt_cv_dlopen_self in
- yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
- *) enable_dlopen_self=unknown ;;
- esac
-
- case $lt_cv_dlopen_self_static in
- yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
- *) enable_dlopen_self_static=unknown ;;
- esac
-fi
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-striplib=
-old_striplib=
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stripping libraries is possible" >&5
-$as_echo_n "checking whether stripping libraries is possible... " >&6; }
-if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then
- test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
- test -z "$striplib" && striplib="$STRIP --strip-unneeded"
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-else
-# FIXME - insert some real tests, host_os isn't really good enough
- case $host_os in
- darwin*)
- if test -n "$STRIP" ; then
- striplib="$STRIP -x"
- old_striplib="$STRIP -S"
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- fi
- ;;
- *)
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- ;;
- esac
-fi
-
-
-
-
-
-
-
-
-
-
-
-
- # Report which library types will actually be built
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libtool supports shared libraries" >&5
-$as_echo_n "checking if libtool supports shared libraries... " >&6; }
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $can_build_shared" >&5
-$as_echo "$can_build_shared" >&6; }
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries" >&5
-$as_echo_n "checking whether to build shared libraries... " >&6; }
- test "$can_build_shared" = "no" && enable_shared=no
-
- # On AIX, shared libraries and static libraries use the same namespace, and
- # are all built from PIC.
- case $host_os in
- aix3*)
- test "$enable_shared" = yes && enable_static=no
- if test -n "$RANLIB"; then
- archive_cmds="$archive_cmds~\$RANLIB \$lib"
- postinstall_cmds='$RANLIB $lib'
- fi
- ;;
-
- aix[4-9]*)
- if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
- test "$enable_shared" = yes && enable_static=no
- fi
- ;;
- esac
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5
-$as_echo "$enable_shared" >&6; }
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build static libraries" >&5
-$as_echo_n "checking whether to build static libraries... " >&6; }
- # Make sure either enable_shared or enable_static is yes.
- test "$enable_shared" = yes || enable_static=yes
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_static" >&5
-$as_echo "$enable_static" >&6; }
-
-
-
-
-fi
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-CC="$lt_save_CC"
-
-
-
-
-
-
-
-
-
-
-
-
-
- ac_config_commands="$ac_config_commands libtool"
-
-
-
-
-# Only expand once:
-
-
-
-# The tests for host and target for $enable_largefile require
-# canonical names.
-
-
-
-# As the $enable_largefile decision depends on --enable-plugins we must set it
-# even in directories otherwise not depending on the $plugins option.
-
-
- maybe_plugins=no
- for ac_header in dlfcn.h
-do :
- ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default
-"
-if test "x$ac_cv_header_dlfcn_h" = xyes; then :
- cat >>confdefs.h <<_ACEOF
-#define HAVE_DLFCN_H 1
-_ACEOF
- maybe_plugins=yes
-fi
-
-done
-
- for ac_header in windows.h
-do :
- ac_fn_c_check_header_compile "$LINENO" "windows.h" "ac_cv_header_windows_h" "$ac_includes_default
-"
-if test "x$ac_cv_header_windows_h" = xyes; then :
- cat >>confdefs.h <<_ACEOF
-#define HAVE_WINDOWS_H 1
-_ACEOF
- maybe_plugins=yes
-fi
-
-done
-
-
- # Check whether --enable-plugins was given.
-if test "${enable_plugins+set}" = set; then :
- enableval=$enable_plugins; case "${enableval}" in
- no) plugins=no ;;
- *) plugins=yes
- if test "$maybe_plugins" != "yes" ; then
- as_fn_error $? "Building with plugin support requires a host that supports dlopen." "$LINENO" 5
- fi ;;
- esac
-else
- plugins=$maybe_plugins
-
-fi
-
- if test "$plugins" = "yes"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing dlsym" >&5
-$as_echo_n "checking for library containing dlsym... " >&6; }
-if ${ac_cv_search_dlsym+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_func_search_save_LIBS=$LIBS
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char dlsym ();
-int
-main ()
-{
-return dlsym ();
- ;
- return 0;
-}
-_ACEOF
-for ac_lib in '' dl; do
- if test -z "$ac_lib"; then
- ac_res="none required"
- else
- ac_res=-l$ac_lib
- LIBS="-l$ac_lib $ac_func_search_save_LIBS"
- fi
- if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_search_dlsym=$ac_res
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext
- if ${ac_cv_search_dlsym+:} false; then :
- break
-fi
-done
-if ${ac_cv_search_dlsym+:} false; then :
-
-else
- ac_cv_search_dlsym=no
-fi
-rm conftest.$ac_ext
-LIBS=$ac_func_search_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_dlsym" >&5
-$as_echo "$ac_cv_search_dlsym" >&6; }
-ac_res=$ac_cv_search_dlsym
-if test "$ac_res" != no; then :
- test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
-
-fi
-
- fi
-
-
-case "${host}" in
- sparc-*-solaris*|i?86-*-solaris*)
- # On native 32-bit Solaris/SPARC and x86, large-file and procfs support
- # were mutually exclusive until Solaris 11.3. Without procfs support,
- # the bfd/ elf module cannot provide certain routines such as
- # elfcore_write_prpsinfo or elfcore_write_prstatus. So unless the user
- # explicitly requested large-file support through the
- # --enable-largefile switch, disable large-file support in favor of
- # procfs support.
- #
- # Check if <sys/procfs.h> is incompatible with large-file support.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#define _FILE_OFFSET_BITS 64
-#define _STRUCTURED_PROC 1
-#include <sys/procfs.h>
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- acx_cv_procfs_lfs=yes
-else
- acx_cv_procfs_lfs=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- #
- # Forcefully disable large-file support only if necessary, gdb is in
- # tree and enabled.
- if test "${target}" = "${host}" -a "$acx_cv_procfs_lfs" = no \
- -a -d $srcdir/../gdb -a "$enable_gdb" != no; then
- : ${enable_largefile="no"}
- if test "$plugins" = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
-plugin support disabled; require large-file support which is incompatible with GDB." >&5
-$as_echo "$as_me: WARNING:
-plugin support disabled; require large-file support which is incompatible with GDB." >&2;}
- plugins=no
- fi
- fi
- #
- # Explicitly undef _FILE_OFFSET_BITS if enable_largefile=no for the
- # benefit of g++ 9+ which predefines it on Solaris.
- if test "$enable_largefile" = no; then
- LARGEFILE_CPPFLAGS="-U_FILE_OFFSET_BITS"
-
- fi
- ;;
-esac
-
-# Check whether --enable-largefile was given.
-if test "${enable_largefile+set}" = set; then :
- enableval=$enable_largefile;
-fi
-
-if test "$enable_largefile" != no; then
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
-$as_echo_n "checking for special C compiler options needed for large files... " >&6; }
-if ${ac_cv_sys_largefile_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_cv_sys_largefile_CC=no
- if test "$GCC" != yes; then
- ac_save_CC=$CC
- while :; do
- # IRIX 6.2 and later do not support large files by default,
- # so use the C compiler's -n32 option if that helps.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <sys/types.h>
- /* Check that off_t can represent 2**63 - 1 correctly.
- We can't simply define LARGE_OFF_T to be 9223372036854775807,
- since some C++ compilers masquerading as C compilers
- incorrectly reject 9223372036854775807. */
-#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
- int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
- && LARGE_OFF_T % 2147483647 == 1)
- ? 1 : -1];
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
- if ac_fn_c_try_compile "$LINENO"; then :
- break
-fi
-rm -f core conftest.err conftest.$ac_objext
- CC="$CC -n32"
- if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_sys_largefile_CC=' -n32'; break
-fi
-rm -f core conftest.err conftest.$ac_objext
- break
- done
- CC=$ac_save_CC
- rm -f conftest.$ac_ext
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
-$as_echo "$ac_cv_sys_largefile_CC" >&6; }
- if test "$ac_cv_sys_largefile_CC" != no; then
- CC=$CC$ac_cv_sys_largefile_CC
- fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
-$as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
-if ${ac_cv_sys_file_offset_bits+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- while :; do
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <sys/types.h>
- /* Check that off_t can represent 2**63 - 1 correctly.
- We can't simply define LARGE_OFF_T to be 9223372036854775807,
- since some C++ compilers masquerading as C compilers
- incorrectly reject 9223372036854775807. */
-#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
- int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
- && LARGE_OFF_T % 2147483647 == 1)
- ? 1 : -1];
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_sys_file_offset_bits=no; break
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#define _FILE_OFFSET_BITS 64
-#include <sys/types.h>
- /* Check that off_t can represent 2**63 - 1 correctly.
- We can't simply define LARGE_OFF_T to be 9223372036854775807,
- since some C++ compilers masquerading as C compilers
- incorrectly reject 9223372036854775807. */
-#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
- int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
- && LARGE_OFF_T % 2147483647 == 1)
- ? 1 : -1];
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_sys_file_offset_bits=64; break
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- ac_cv_sys_file_offset_bits=unknown
- break
-done
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
-$as_echo "$ac_cv_sys_file_offset_bits" >&6; }
-case $ac_cv_sys_file_offset_bits in #(
- no | unknown) ;;
- *)
-cat >>confdefs.h <<_ACEOF
-#define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
-_ACEOF
-;;
-esac
-rm -rf conftest*
- if test $ac_cv_sys_file_offset_bits = unknown; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
-$as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
-if ${ac_cv_sys_large_files+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- while :; do
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <sys/types.h>
- /* Check that off_t can represent 2**63 - 1 correctly.
- We can't simply define LARGE_OFF_T to be 9223372036854775807,
- since some C++ compilers masquerading as C compilers
- incorrectly reject 9223372036854775807. */
-#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
- int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
- && LARGE_OFF_T % 2147483647 == 1)
- ? 1 : -1];
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_sys_large_files=no; break
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#define _LARGE_FILES 1
-#include <sys/types.h>
- /* Check that off_t can represent 2**63 - 1 correctly.
- We can't simply define LARGE_OFF_T to be 9223372036854775807,
- since some C++ compilers masquerading as C compilers
- incorrectly reject 9223372036854775807. */
-#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
- int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
- && LARGE_OFF_T % 2147483647 == 1)
- ? 1 : -1];
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_sys_large_files=1; break
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- ac_cv_sys_large_files=unknown
- break
-done
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
-$as_echo "$ac_cv_sys_large_files" >&6; }
-case $ac_cv_sys_large_files in #(
- no | unknown) ;;
- *)
-cat >>confdefs.h <<_ACEOF
-#define _LARGE_FILES $ac_cv_sys_large_files
-_ACEOF
-;;
-esac
-rm -rf conftest*
- fi
-
-
-fi
-
-
-
-# These are in addition to what is made available in bfd/.
-for ac_header in sys/time.h
-do :
- ac_fn_c_check_header_mongrel "$LINENO" "sys/time.h" "ac_cv_header_sys_time_h" "$ac_includes_default"
-if test "x$ac_cv_header_sys_time_h" = xyes; then :
- cat >>confdefs.h <<_ACEOF
-#define HAVE_SYS_TIME_H 1
-_ACEOF
-
-fi
-
-done
-
-for ac_func in setitimer
-do :
- ac_fn_c_check_func "$LINENO" "setitimer" "ac_cv_func_setitimer"
-if test "x$ac_cv_func_setitimer" = xyes; then :
- cat >>confdefs.h <<_ACEOF
-#define HAVE_SETITIMER 1
-_ACEOF
-
-fi
-done
-
-
-ALL_LINGUAS="bg da de eo es fi fr ga hu id it ja ms nl pt_BR ro ru rw sr sv tr uk vi"
-
- MKINSTALLDIRS=
- if test -n "$ac_aux_dir"; then
- case "$ac_aux_dir" in
- /*) MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs" ;;
- *) MKINSTALLDIRS="\$(top_builddir)/$ac_aux_dir/mkinstalldirs" ;;
- esac
- fi
- if test -z "$MKINSTALLDIRS"; then
- MKINSTALLDIRS="\$(top_srcdir)/mkinstalldirs"
- fi
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NLS is requested" >&5
-$as_echo_n "checking whether NLS is requested... " >&6; }
- # Check whether --enable-nls was given.
-if test "${enable_nls+set}" = set; then :
- enableval=$enable_nls; USE_NLS=$enableval
-else
- USE_NLS=yes
-fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_NLS" >&5
-$as_echo "$USE_NLS" >&6; }
-
-
-
-
-
-
-# Prepare PATH_SEPARATOR.
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-
-# Find out how to test for executable files. Don't use a zero-byte file,
-# as systems may use methods other than mode bits to determine executability.
-cat >conf$$.file <<_ASEOF
-#! /bin/sh
-exit 0
-_ASEOF
-chmod +x conf$$.file
-if test -x conf$$.file >/dev/null 2>&1; then
- ac_executable_p="test -x"
-else
- ac_executable_p="test -f"
-fi
-rm -f conf$$.file
-
-# Extract the first word of "msgfmt", so it can be a program name with args.
-set dummy msgfmt; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_MSGFMT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case "$MSGFMT" in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
- ;;
- *)
- ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH; do
- IFS="$ac_save_IFS"
- test -z "$ac_dir" && ac_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
- if $ac_dir/$ac_word --statistics /dev/null >/dev/null 2>&1 &&
- (if $ac_dir/$ac_word --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- ac_cv_path_MSGFMT="$ac_dir/$ac_word$ac_exec_ext"
- break 2
- fi
- fi
- done
- done
- IFS="$ac_save_IFS"
- test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT=":"
- ;;
-esac
-fi
-MSGFMT="$ac_cv_path_MSGFMT"
-if test "$MSGFMT" != ":"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGFMT" >&5
-$as_echo "$MSGFMT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- # Extract the first word of "gmsgfmt", so it can be a program name with args.
-set dummy gmsgfmt; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_GMSGFMT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $GMSGFMT in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
- ;;
- *)
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_path_GMSGFMT="$as_dir/$ac_word$ac_exec_ext"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
- test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT"
- ;;
-esac
-fi
-GMSGFMT=$ac_cv_path_GMSGFMT
-if test -n "$GMSGFMT"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GMSGFMT" >&5
-$as_echo "$GMSGFMT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-
-
-# Prepare PATH_SEPARATOR.
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-
-# Find out how to test for executable files. Don't use a zero-byte file,
-# as systems may use methods other than mode bits to determine executability.
-cat >conf$$.file <<_ASEOF
-#! /bin/sh
-exit 0
-_ASEOF
-chmod +x conf$$.file
-if test -x conf$$.file >/dev/null 2>&1; then
- ac_executable_p="test -x"
-else
- ac_executable_p="test -f"
-fi
-rm -f conf$$.file
-
-# Extract the first word of "xgettext", so it can be a program name with args.
-set dummy xgettext; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_XGETTEXT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case "$XGETTEXT" in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
- ;;
- *)
- ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH; do
- IFS="$ac_save_IFS"
- test -z "$ac_dir" && ac_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
- if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >/dev/null 2>&1 &&
- (if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- ac_cv_path_XGETTEXT="$ac_dir/$ac_word$ac_exec_ext"
- break 2
- fi
- fi
- done
- done
- IFS="$ac_save_IFS"
- test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":"
- ;;
-esac
-fi
-XGETTEXT="$ac_cv_path_XGETTEXT"
-if test "$XGETTEXT" != ":"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XGETTEXT" >&5
-$as_echo "$XGETTEXT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- rm -f messages.po
-
-
-# Prepare PATH_SEPARATOR.
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-
-# Find out how to test for executable files. Don't use a zero-byte file,
-# as systems may use methods other than mode bits to determine executability.
-cat >conf$$.file <<_ASEOF
-#! /bin/sh
-exit 0
-_ASEOF
-chmod +x conf$$.file
-if test -x conf$$.file >/dev/null 2>&1; then
- ac_executable_p="test -x"
-else
- ac_executable_p="test -f"
-fi
-rm -f conf$$.file
-
-# Extract the first word of "msgmerge", so it can be a program name with args.
-set dummy msgmerge; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_MSGMERGE+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case "$MSGMERGE" in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_MSGMERGE="$MSGMERGE" # Let the user override the test with a path.
- ;;
- *)
- ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH; do
- IFS="$ac_save_IFS"
- test -z "$ac_dir" && ac_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
- if $ac_dir/$ac_word --update -q /dev/null /dev/null >/dev/null 2>&1; then
- ac_cv_path_MSGMERGE="$ac_dir/$ac_word$ac_exec_ext"
- break 2
- fi
- fi
- done
- done
- IFS="$ac_save_IFS"
- test -z "$ac_cv_path_MSGMERGE" && ac_cv_path_MSGMERGE=":"
- ;;
-esac
-fi
-MSGMERGE="$ac_cv_path_MSGMERGE"
-if test "$MSGMERGE" != ":"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGMERGE" >&5
-$as_echo "$MSGMERGE" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- if test "$GMSGFMT" != ":"; then
- if $GMSGFMT --statistics /dev/null >/dev/null 2>&1 &&
- (if $GMSGFMT --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- : ;
- else
- GMSGFMT=`echo "$GMSGFMT" | sed -e 's,^.*/,,'`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: found $GMSGFMT program is not GNU msgfmt; ignore it" >&5
-$as_echo "found $GMSGFMT program is not GNU msgfmt; ignore it" >&6; }
- GMSGFMT=":"
- fi
- fi
-
- if test "$XGETTEXT" != ":"; then
- if $XGETTEXT --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >/dev/null 2>&1 &&
- (if $XGETTEXT --omit-header --copyright-holder= --msgid-bugs-address= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- : ;
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: found xgettext program is not GNU xgettext; ignore it" >&5
-$as_echo "found xgettext program is not GNU xgettext; ignore it" >&6; }
- XGETTEXT=":"
- fi
- rm -f messages.po
- fi
-
- ac_config_commands="$ac_config_commands default-1"
-
-
-
- if test "X$prefix" = "XNONE"; then
- acl_final_prefix="$ac_default_prefix"
- else
- acl_final_prefix="$prefix"
- fi
- if test "X$exec_prefix" = "XNONE"; then
- acl_final_exec_prefix='${prefix}'
- else
- acl_final_exec_prefix="$exec_prefix"
- fi
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- eval acl_final_exec_prefix=\"$acl_final_exec_prefix\"
- prefix="$acl_save_prefix"
-
-
-# Check whether --with-gnu-ld was given.
-if test "${with_gnu_ld+set}" = set; then :
- withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
-else
- with_gnu_ld=no
-fi
-
-# Prepare PATH_SEPARATOR.
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-ac_prog=ld
-if test "$GCC" = yes; then
- # Check if gcc -print-prog-name=ld gives a path.
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by GCC" >&5
-$as_echo_n "checking for ld used by GCC... " >&6; }
- case $host in
- *-*-mingw*)
- # gcc leaves a trailing carriage return which upsets mingw
- ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
- *)
- ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
- esac
- case $ac_prog in
- # Accept absolute paths.
- [\\/]* | [A-Za-z]:[\\/]*)
- re_direlt='/[^/][^/]*/\.\./'
- # Canonicalize the path of ld
- ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
- while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
- ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
- done
- test -z "$LD" && LD="$ac_prog"
- ;;
- "")
- # If it fails, then pretend we aren't using GCC.
- ac_prog=ld
- ;;
- *)
- # If it is relative, then search for the first ld in PATH.
- with_gnu_ld=unknown
- ;;
- esac
-elif test "$with_gnu_ld" = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
-$as_echo_n "checking for GNU ld... " >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
-$as_echo_n "checking for non-GNU ld... " >&6; }
-fi
-if ${acl_cv_path_LD+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -z "$LD"; then
- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
- for ac_dir in $PATH; do
- test -z "$ac_dir" && ac_dir=.
- if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
- acl_cv_path_LD="$ac_dir/$ac_prog"
- # Check to see if the program is GNU ld. I'd rather use --version,
- # but apparently some GNU ld's only accept -v.
- # Break only if it was the GNU/non-GNU ld that we prefer.
- if "$acl_cv_path_LD" -v 2>&1 < /dev/null | $EGREP '(GNU|with BFD)' > /dev/null; then
- test "$with_gnu_ld" != no && break
- else
- test "$with_gnu_ld" != yes && break
- fi
- fi
- done
- IFS="$ac_save_ifs"
-else
- acl_cv_path_LD="$LD" # Let the user override the test with a path.
-fi
-fi
-
-LD="$acl_cv_path_LD"
-if test -n "$LD"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
-$as_echo "$LD" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
-$as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
-if ${acl_cv_prog_gnu_ld+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- # I'd rather use --version here, but apparently some GNU ld's only accept -v.
-if $LD -v 2>&1 </dev/null | $EGREP '(GNU|with BFD)' 1>&5; then
- acl_cv_prog_gnu_ld=yes
-else
- acl_cv_prog_gnu_ld=no
-fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $acl_cv_prog_gnu_ld" >&5
-$as_echo "$acl_cv_prog_gnu_ld" >&6; }
-with_gnu_ld=$acl_cv_prog_gnu_ld
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shared library run path origin" >&5
-$as_echo_n "checking for shared library run path origin... " >&6; }
-if ${acl_cv_rpath+:} false; then :
- $as_echo_n "(cached) " >&6
-else
-
- CC="$CC" GCC="$GCC" LDFLAGS="$LDFLAGS" LD="$LD" with_gnu_ld="$with_gnu_ld" \
- ${CONFIG_SHELL-/bin/sh} "$ac_aux_dir/config.rpath" "$host" > conftest.sh
- . ./conftest.sh
- rm -f ./conftest.sh
- acl_cv_rpath=done
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $acl_cv_rpath" >&5
-$as_echo "$acl_cv_rpath" >&6; }
- wl="$acl_cv_wl"
- libext="$acl_cv_libext"
- shlibext="$acl_cv_shlibext"
- hardcode_libdir_flag_spec="$acl_cv_hardcode_libdir_flag_spec"
- hardcode_libdir_separator="$acl_cv_hardcode_libdir_separator"
- hardcode_direct="$acl_cv_hardcode_direct"
- hardcode_minus_L="$acl_cv_hardcode_minus_L"
- # Check whether --enable-rpath was given.
-if test "${enable_rpath+set}" = set; then :
- enableval=$enable_rpath; :
-else
- enable_rpath=yes
-fi
-
-
-
-
-
-
-
-
- use_additional=yes
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
-
- eval additional_includedir=\"$includedir\"
- eval additional_libdir=\"$libdir\"
-
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
-
-# Check whether --with-libiconv-prefix was given.
-if test "${with_libiconv_prefix+set}" = set; then :
- withval=$with_libiconv_prefix;
- if test "X$withval" = "Xno"; then
- use_additional=no
- else
- if test "X$withval" = "X"; then
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
-
- eval additional_includedir=\"$includedir\"
- eval additional_libdir=\"$libdir\"
-
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- else
- additional_includedir="$withval/include"
- additional_libdir="$withval/lib"
- fi
- fi
-
-fi
-
-
-# Check whether --with-libiconv-type was given.
-if test "${with_libiconv_type+set}" = set; then :
- withval=$with_libiconv_type; with_libiconv_type=$withval
-else
- with_libiconv_type=auto
-fi
-
- lib_type=`eval echo \$with_libiconv_type`
-
- LIBICONV=
- LTLIBICONV=
- INCICONV=
- rpathdirs=
- ltrpathdirs=
- names_already_handled=
- names_next_round='iconv '
- while test -n "$names_next_round"; do
- names_this_round="$names_next_round"
- names_next_round=
- for name in $names_this_round; do
- already_handled=
- for n in $names_already_handled; do
- if test "$n" = "$name"; then
- already_handled=yes
- break
- fi
- done
- if test -z "$already_handled"; then
- names_already_handled="$names_already_handled $name"
- uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
- eval value=\"\$HAVE_LIB$uppername\"
- if test -n "$value"; then
- if test "$value" = yes; then
- eval value=\"\$LIB$uppername\"
- test -z "$value" || LIBICONV="${LIBICONV}${LIBICONV:+ }$value"
- eval value=\"\$LTLIB$uppername\"
- test -z "$value" || LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$value"
- else
- :
- fi
- else
- found_dir=
- found_la=
- found_so=
- found_a=
- if test $use_additional = yes; then
- if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext" && test x$lib_type != xstatic; then
- found_dir="$additional_libdir"
- found_so="$additional_libdir/lib$name.$shlibext"
- if test -f "$additional_libdir/lib$name.la"; then
- found_la="$additional_libdir/lib$name.la"
- fi
- elif test x$lib_type != xshared; then
- if test -f "$additional_libdir/lib$name.$libext"; then
- found_dir="$additional_libdir"
- found_a="$additional_libdir/lib$name.$libext"
- if test -f "$additional_libdir/lib$name.la"; then
- found_la="$additional_libdir/lib$name.la"
- fi
- fi
- fi
- fi
- if test "X$found_dir" = "X"; then
- for x in $LDFLAGS $LTLIBICONV; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- case "$x" in
- -L*)
- dir=`echo "X$x" | sed -e 's/^X-L//'`
- if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext" && test x$lib_type != xstatic; then
- found_dir="$dir"
- found_so="$dir/lib$name.$shlibext"
- if test -f "$dir/lib$name.la"; then
- found_la="$dir/lib$name.la"
- fi
- elif test x$lib_type != xshared; then
- if test -f "$dir/lib$name.$libext"; then
- found_dir="$dir"
- found_a="$dir/lib$name.$libext"
- if test -f "$dir/lib$name.la"; then
- found_la="$dir/lib$name.la"
- fi
- fi
- fi
- ;;
- esac
- if test "X$found_dir" != "X"; then
- break
- fi
- done
- fi
- if test "X$found_dir" != "X"; then
- LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$found_dir -l$name"
- if test "X$found_so" != "X"; then
- if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
- else
- haveit=
- for x in $ltrpathdirs; do
- if test "X$x" = "X$found_dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- ltrpathdirs="$ltrpathdirs $found_dir"
- fi
- if test "$hardcode_direct" = yes; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
- else
- if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
- haveit=
- for x in $rpathdirs; do
- if test "X$x" = "X$found_dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- rpathdirs="$rpathdirs $found_dir"
- fi
- else
- haveit=
- for x in $LDFLAGS $LIBICONV; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-L$found_dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir"
- fi
- if test "$hardcode_minus_L" != no; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
- else
- LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name"
- fi
- fi
- fi
- fi
- else
- if test "X$found_a" != "X"; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }$found_a"
- else
- LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir -l$name"
- fi
- fi
- additional_includedir=
- case "$found_dir" in
- */lib | */lib/)
- basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
- additional_includedir="$basedir/include"
- ;;
- esac
- if test "X$additional_includedir" != "X"; then
- if test "X$additional_includedir" != "X/usr/include"; then
- haveit=
- if test "X$additional_includedir" = "X/usr/local/include"; then
- if test -n "$GCC"; then
- case $host_os in
- linux*) haveit=yes;;
- esac
- fi
- fi
- if test -z "$haveit"; then
- for x in $CPPFLAGS $INCICONV; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-I$additional_includedir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- if test -d "$additional_includedir"; then
- INCICONV="${INCICONV}${INCICONV:+ }-I$additional_includedir"
- fi
- fi
- fi
- fi
- fi
- if test -n "$found_la"; then
- save_libdir="$libdir"
- case "$found_la" in
- */* | *\\*) . "$found_la" ;;
- *) . "./$found_la" ;;
- esac
- libdir="$save_libdir"
- for dep in $dependency_libs; do
- case "$dep" in
- -L*)
- additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
- if test "X$additional_libdir" != "X/usr/lib"; then
- haveit=
- if test "X$additional_libdir" = "X/usr/local/lib"; then
- if test -n "$GCC"; then
- case $host_os in
- linux*) haveit=yes;;
- esac
- fi
- fi
- if test -z "$haveit"; then
- haveit=
- for x in $LDFLAGS $LIBICONV; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-L$additional_libdir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- if test -d "$additional_libdir"; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }-L$additional_libdir"
- fi
- fi
- haveit=
- for x in $LDFLAGS $LTLIBICONV; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-L$additional_libdir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- if test -d "$additional_libdir"; then
- LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$additional_libdir"
- fi
- fi
- fi
- fi
- ;;
- -R*)
- dir=`echo "X$dep" | sed -e 's/^X-R//'`
- if test "$enable_rpath" != no; then
- haveit=
- for x in $rpathdirs; do
- if test "X$x" = "X$dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- rpathdirs="$rpathdirs $dir"
- fi
- haveit=
- for x in $ltrpathdirs; do
- if test "X$x" = "X$dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- ltrpathdirs="$ltrpathdirs $dir"
- fi
- fi
- ;;
- -l*)
- names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
- ;;
- *.la)
- names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
- ;;
- *)
- LIBICONV="${LIBICONV}${LIBICONV:+ }$dep"
- LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$dep"
- ;;
- esac
- done
- fi
- else
- if test "x$lib_type" = "xauto" || test "x$lib_type" = "xshared"; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name"
- LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-l$name"
- else
- LIBICONV="${LIBICONV}${LIBICONV:+ }-l:lib$name.$libext"
- LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-l:lib$name.$libext"
- fi
- fi
- fi
- fi
- done
- done
- if test "X$rpathdirs" != "X"; then
- if test -n "$hardcode_libdir_separator"; then
- alldirs=
- for found_dir in $rpathdirs; do
- alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
- done
- acl_save_libdir="$libdir"
- libdir="$alldirs"
- eval flag=\"$hardcode_libdir_flag_spec\"
- libdir="$acl_save_libdir"
- LIBICONV="${LIBICONV}${LIBICONV:+ }$flag"
- else
- for found_dir in $rpathdirs; do
- acl_save_libdir="$libdir"
- libdir="$found_dir"
- eval flag=\"$hardcode_libdir_flag_spec\"
- libdir="$acl_save_libdir"
- LIBICONV="${LIBICONV}${LIBICONV:+ }$flag"
- done
- fi
- fi
- if test "X$ltrpathdirs" != "X"; then
- for found_dir in $ltrpathdirs; do
- LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-R$found_dir"
- done
- fi
-
-
-
-
-
-if test -f ../gettext/uninstalled-config.sh; then
- relative_builddir='$(top_builddir)/../gettext'
- . ../gettext/uninstalled-config.sh
-else
- # The sister gettext directory doesn't exist and won't collect information on
- # using gettext for us. Call a bundled AM_GNU_GETTEXT.
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CFPreferencesCopyAppValue" >&5
-$as_echo_n "checking for CFPreferencesCopyAppValue... " >&6; }
-if ${gt_cv_func_CFPreferencesCopyAppValue+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- gt_save_LIBS="$LIBS"
- LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <CoreFoundation/CFPreferences.h>
-int
-main ()
-{
-CFPreferencesCopyAppValue(NULL, NULL)
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- gt_cv_func_CFPreferencesCopyAppValue=yes
-else
- gt_cv_func_CFPreferencesCopyAppValue=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LIBS="$gt_save_LIBS"
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_CFPreferencesCopyAppValue" >&5
-$as_echo "$gt_cv_func_CFPreferencesCopyAppValue" >&6; }
- if test $gt_cv_func_CFPreferencesCopyAppValue = yes; then
-
-$as_echo "#define HAVE_CFPREFERENCESCOPYAPPVALUE 1" >>confdefs.h
-
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CFLocaleCopyPreferredLanguages" >&5
-$as_echo_n "checking for CFLocaleCopyPreferredLanguages... " >&6; }
-if ${gt_cv_func_CFLocaleCopyPreferredLanguages+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- gt_save_LIBS="$LIBS"
- LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <CoreFoundation/CFLocale.h>
-int
-main ()
-{
-CFLocaleCopyPreferredLanguages();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- gt_cv_func_CFLocaleCopyPreferredLanguages=yes
-else
- gt_cv_func_CFLocaleCopyPreferredLanguages=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LIBS="$gt_save_LIBS"
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_CFLocaleCopyPreferredLanguages" >&5
-$as_echo "$gt_cv_func_CFLocaleCopyPreferredLanguages" >&6; }
- if test $gt_cv_func_CFLocaleCopyPreferredLanguages = yes; then
-
-$as_echo "#define HAVE_CFLOCALECOPYPREFERREDLANGUAGES 1" >>confdefs.h
-
- fi
- INTL_MACOSX_LIBS=
- if test $gt_cv_func_CFPreferencesCopyAppValue = yes \
- || test $gt_cv_func_CFLocaleCopyPreferredLanguages = yes; then
- INTL_MACOSX_LIBS="-Wl,-framework -Wl,CoreFoundation -Wl,-framework -Wl,CoreServices"
- fi
-
-
-
-
-
-
- LIBINTL=
- LTLIBINTL=
- POSUB=
-
- case " $gt_needs " in
- *" need-formatstring-macros "*) gt_api_version=3 ;;
- *" need-ngettext "*) gt_api_version=2 ;;
- *) gt_api_version=1 ;;
- esac
- gt_func_gnugettext_libc="gt_cv_func_gnugettext${gt_api_version}_libc"
- gt_func_gnugettext_libintl="gt_cv_func_gnugettext${gt_api_version}_libintl"
-
- if test "$USE_NLS" = "yes"; then
- gt_use_preinstalled_gnugettext=no
-
-
- if test $gt_api_version -ge 3; then
- gt_revision_test_code='
-#ifndef __GNU_GETTEXT_SUPPORTED_REVISION
-#define __GNU_GETTEXT_SUPPORTED_REVISION(major) ((major) == 0 ? 0 : -1)
-#endif
-typedef int array [2 * (__GNU_GETTEXT_SUPPORTED_REVISION(0) >= 1) - 1];
-'
- else
- gt_revision_test_code=
- fi
- if test $gt_api_version -ge 2; then
- gt_expression_test_code=' + * ngettext ("", "", 0)'
- else
- gt_expression_test_code=
- fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU gettext in libc" >&5
-$as_echo_n "checking for GNU gettext in libc... " >&6; }
-if eval \${$gt_func_gnugettext_libc+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <libintl.h>
-#ifndef __GNU_GETTEXT_SUPPORTED_REVISION
-extern int _nl_msg_cat_cntr;
-extern int *_nl_domain_bindings;
-#define __GNU_GETTEXT_SYMBOL_EXPRESSION (_nl_msg_cat_cntr + *_nl_domain_bindings)
-#else
-#define __GNU_GETTEXT_SYMBOL_EXPRESSION 0
-#endif
-$gt_revision_test_code
-
-int
-main ()
-{
-
-bindtextdomain ("", "");
-return * gettext ("")$gt_expression_test_code + __GNU_GETTEXT_SYMBOL_EXPRESSION
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- eval "$gt_func_gnugettext_libc=yes"
-else
- eval "$gt_func_gnugettext_libc=no"
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-fi
-eval ac_res=\$$gt_func_gnugettext_libc
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
-
- if { eval "gt_val=\$$gt_func_gnugettext_libc"; test "$gt_val" != "yes"; }; then
-
-
-
-
-
- am_save_CPPFLAGS="$CPPFLAGS"
-
- for element in $INCICONV; do
- haveit=
- for x in $CPPFLAGS; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X$element"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
- fi
- done
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for iconv" >&5
-$as_echo_n "checking for iconv... " >&6; }
-if ${am_cv_func_iconv+:} false; then :
- $as_echo_n "(cached) " >&6
-else
-
- am_cv_func_iconv="no, consider installing GNU libiconv"
- am_cv_lib_iconv=no
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <stdlib.h>
-#include <iconv.h>
-
-int
-main ()
-{
-iconv_t cd = iconv_open("","");
- iconv(cd,NULL,NULL,NULL,NULL);
- iconv_close(cd);
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- am_cv_func_iconv=yes
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- if test "$am_cv_func_iconv" != yes; then
- am_save_LIBS="$LIBS"
- LIBS="$LIBS $LIBICONV"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <stdlib.h>
-#include <iconv.h>
-
-int
-main ()
-{
-iconv_t cd = iconv_open("","");
- iconv(cd,NULL,NULL,NULL,NULL);
- iconv_close(cd);
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- am_cv_lib_iconv=yes
- am_cv_func_iconv=yes
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LIBS="$am_save_LIBS"
- fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv" >&5
-$as_echo "$am_cv_func_iconv" >&6; }
- if test "$am_cv_func_iconv" = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working iconv" >&5
-$as_echo_n "checking for working iconv... " >&6; }
-if ${am_cv_func_iconv_works+:} false; then :
- $as_echo_n "(cached) " >&6
-else
-
- am_save_LIBS="$LIBS"
- if test $am_cv_lib_iconv = yes; then
- LIBS="$LIBS $LIBICONV"
- fi
- am_cv_func_iconv_works=no
- for ac_iconv_const in '' 'const'; do
- if test "$cross_compiling" = yes; then :
- case "$host_os" in
- aix* | hpux*) am_cv_func_iconv_works="guessing no" ;;
- *) am_cv_func_iconv_works="guessing yes" ;;
- esac
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <iconv.h>
-#include <string.h>
-
-#ifndef ICONV_CONST
-# define ICONV_CONST $ac_iconv_const
-#endif
-
-int
-main ()
-{
-int result = 0;
- /* Test against AIX 5.1...7.2 bug: Failures are not distinguishable from
- successful returns. This is even documented in
- <https://www.ibm.com/support/knowledgecenter/ssw_aix_72/i_bostechref/iconv.html> */
- {
- iconv_t cd_utf8_to_88591 = iconv_open ("ISO8859-1", "UTF-8");
- if (cd_utf8_to_88591 != (iconv_t)(-1))
- {
- static ICONV_CONST char input[] = "\342\202\254"; /* EURO SIGN */
- char buf[10];
- ICONV_CONST char *inptr = input;
- size_t inbytesleft = strlen (input);
- char *outptr = buf;
- size_t outbytesleft = sizeof (buf);
- size_t res = iconv (cd_utf8_to_88591,
- &inptr, &inbytesleft,
- &outptr, &outbytesleft);
- if (res == 0)
- result |= 1;
- iconv_close (cd_utf8_to_88591);
- }
- }
- /* Test against Solaris 10 bug: Failures are not distinguishable from
- successful returns. */
- {
- iconv_t cd_ascii_to_88591 = iconv_open ("ISO8859-1", "646");
- if (cd_ascii_to_88591 != (iconv_t)(-1))
- {
- static ICONV_CONST char input[] = "\263";
- char buf[10];
- ICONV_CONST char *inptr = input;
- size_t inbytesleft = strlen (input);
- char *outptr = buf;
- size_t outbytesleft = sizeof (buf);
- size_t res = iconv (cd_ascii_to_88591,
- &inptr, &inbytesleft,
- &outptr, &outbytesleft);
- if (res == 0)
- result |= 2;
- iconv_close (cd_ascii_to_88591);
- }
- }
- /* Test against AIX 6.1..7.1 bug: Buffer overrun. */
- {
- iconv_t cd_88591_to_utf8 = iconv_open ("UTF-8", "ISO-8859-1");
- if (cd_88591_to_utf8 != (iconv_t)(-1))
- {
- static ICONV_CONST char input[] = "\304";
- static char buf[2] = { (char)0xDE, (char)0xAD };
- ICONV_CONST char *inptr = input;
- size_t inbytesleft = 1;
- char *outptr = buf;
- size_t outbytesleft = 1;
- size_t res = iconv (cd_88591_to_utf8,
- &inptr, &inbytesleft,
- &outptr, &outbytesleft);
- if (res != (size_t)(-1) || outptr - buf > 1 || buf[1] != (char)0xAD)
- result |= 4;
- iconv_close (cd_88591_to_utf8);
- }
- }
-#if 0 /* This bug could be worked around by the caller. */
- /* Test against HP-UX 11.11 bug: Positive return value instead of 0. */
- {
- iconv_t cd_88591_to_utf8 = iconv_open ("utf8", "iso88591");
- if (cd_88591_to_utf8 != (iconv_t)(-1))
- {
- static ICONV_CONST char input[] = "\304rger mit b\366sen B\374bchen ohne Augenma\337";
- char buf[50];
- ICONV_CONST char *inptr = input;
- size_t inbytesleft = strlen (input);
- char *outptr = buf;
- size_t outbytesleft = sizeof (buf);
- size_t res = iconv (cd_88591_to_utf8,
- &inptr, &inbytesleft,
- &outptr, &outbytesleft);
- if ((int)res > 0)
- result |= 8;
- iconv_close (cd_88591_to_utf8);
- }
- }
-#endif
- /* Test against HP-UX 11.11 bug: No converter from EUC-JP to UTF-8 is
- provided. */
- {
- /* Try standardized names. */
- iconv_t cd1 = iconv_open ("UTF-8", "EUC-JP");
- /* Try IRIX, OSF/1 names. */
- iconv_t cd2 = iconv_open ("UTF-8", "eucJP");
- /* Try AIX names. */
- iconv_t cd3 = iconv_open ("UTF-8", "IBM-eucJP");
- /* Try HP-UX names. */
- iconv_t cd4 = iconv_open ("utf8", "eucJP");
- if (cd1 == (iconv_t)(-1) && cd2 == (iconv_t)(-1)
- && cd3 == (iconv_t)(-1) && cd4 == (iconv_t)(-1))
- result |= 16;
- if (cd1 != (iconv_t)(-1))
- iconv_close (cd1);
- if (cd2 != (iconv_t)(-1))
- iconv_close (cd2);
- if (cd3 != (iconv_t)(-1))
- iconv_close (cd3);
- if (cd4 != (iconv_t)(-1))
- iconv_close (cd4);
- }
- return result;
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_run "$LINENO"; then :
- am_cv_func_iconv_works=yes
-fi
-rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
- conftest.$ac_objext conftest.beam conftest.$ac_ext
-fi
-
- test "$am_cv_func_iconv_works" = no || break
- done
- LIBS="$am_save_LIBS"
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv_works" >&5
-$as_echo "$am_cv_func_iconv_works" >&6; }
- case "$am_cv_func_iconv_works" in
- *no) am_func_iconv=no am_cv_lib_iconv=no ;;
- *) am_func_iconv=yes ;;
- esac
- else
- am_func_iconv=no am_cv_lib_iconv=no
- fi
- if test "$am_func_iconv" = yes; then
-
-$as_echo "#define HAVE_ICONV 1" >>confdefs.h
-
- fi
- if test "$am_cv_lib_iconv" = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libiconv" >&5
-$as_echo_n "checking how to link with libiconv... " >&6; }
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBICONV" >&5
-$as_echo "$LIBICONV" >&6; }
- else
- CPPFLAGS="$am_save_CPPFLAGS"
- LIBICONV=
- LTLIBICONV=
- fi
-
-
-
-
-
-
- use_additional=yes
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
-
- eval additional_includedir=\"$includedir\"
- eval additional_libdir=\"$libdir\"
-
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
-
-# Check whether --with-libintl-prefix was given.
-if test "${with_libintl_prefix+set}" = set; then :
- withval=$with_libintl_prefix;
- if test "X$withval" = "Xno"; then
- use_additional=no
- else
- if test "X$withval" = "X"; then
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
-
- eval additional_includedir=\"$includedir\"
- eval additional_libdir=\"$libdir\"
-
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- else
- additional_includedir="$withval/include"
- additional_libdir="$withval/lib"
- fi
- fi
-
-fi
-
-
-# Check whether --with-libintl-type was given.
-if test "${with_libintl_type+set}" = set; then :
- withval=$with_libintl_type; with_libintl_type=$withval
-else
- with_libintl_type=auto
-fi
-
- lib_type=`eval echo \$with_libintl_type`
-
- LIBINTL=
- LTLIBINTL=
- INCINTL=
- rpathdirs=
- ltrpathdirs=
- names_already_handled=
- names_next_round='intl '
- while test -n "$names_next_round"; do
- names_this_round="$names_next_round"
- names_next_round=
- for name in $names_this_round; do
- already_handled=
- for n in $names_already_handled; do
- if test "$n" = "$name"; then
- already_handled=yes
- break
- fi
- done
- if test -z "$already_handled"; then
- names_already_handled="$names_already_handled $name"
- uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
- eval value=\"\$HAVE_LIB$uppername\"
- if test -n "$value"; then
- if test "$value" = yes; then
- eval value=\"\$LIB$uppername\"
- test -z "$value" || LIBINTL="${LIBINTL}${LIBINTL:+ }$value"
- eval value=\"\$LTLIB$uppername\"
- test -z "$value" || LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }$value"
- else
- :
- fi
- else
- found_dir=
- found_la=
- found_so=
- found_a=
- if test $use_additional = yes; then
- if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext" && test x$lib_type != xstatic; then
- found_dir="$additional_libdir"
- found_so="$additional_libdir/lib$name.$shlibext"
- if test -f "$additional_libdir/lib$name.la"; then
- found_la="$additional_libdir/lib$name.la"
- fi
- elif test x$lib_type != xshared; then
- if test -f "$additional_libdir/lib$name.$libext"; then
- found_dir="$additional_libdir"
- found_a="$additional_libdir/lib$name.$libext"
- if test -f "$additional_libdir/lib$name.la"; then
- found_la="$additional_libdir/lib$name.la"
- fi
- fi
- fi
- fi
- if test "X$found_dir" = "X"; then
- for x in $LDFLAGS $LTLIBINTL; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- case "$x" in
- -L*)
- dir=`echo "X$x" | sed -e 's/^X-L//'`
- if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext" && test x$lib_type != xstatic; then
- found_dir="$dir"
- found_so="$dir/lib$name.$shlibext"
- if test -f "$dir/lib$name.la"; then
- found_la="$dir/lib$name.la"
- fi
- elif test x$lib_type != xshared; then
- if test -f "$dir/lib$name.$libext"; then
- found_dir="$dir"
- found_a="$dir/lib$name.$libext"
- if test -f "$dir/lib$name.la"; then
- found_la="$dir/lib$name.la"
- fi
- fi
- fi
- ;;
- esac
- if test "X$found_dir" != "X"; then
- break
- fi
- done
- fi
- if test "X$found_dir" != "X"; then
- LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-L$found_dir -l$name"
- if test "X$found_so" != "X"; then
- if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
- else
- haveit=
- for x in $ltrpathdirs; do
- if test "X$x" = "X$found_dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- ltrpathdirs="$ltrpathdirs $found_dir"
- fi
- if test "$hardcode_direct" = yes; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
- else
- if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
- haveit=
- for x in $rpathdirs; do
- if test "X$x" = "X$found_dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- rpathdirs="$rpathdirs $found_dir"
- fi
- else
- haveit=
- for x in $LDFLAGS $LIBINTL; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-L$found_dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }-L$found_dir"
- fi
- if test "$hardcode_minus_L" != no; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
- else
- LIBINTL="${LIBINTL}${LIBINTL:+ }-l$name"
- fi
- fi
- fi
- fi
- else
- if test "X$found_a" != "X"; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }$found_a"
- else
- LIBINTL="${LIBINTL}${LIBINTL:+ }-L$found_dir -l$name"
- fi
- fi
- additional_includedir=
- case "$found_dir" in
- */lib | */lib/)
- basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
- additional_includedir="$basedir/include"
- ;;
- esac
- if test "X$additional_includedir" != "X"; then
- if test "X$additional_includedir" != "X/usr/include"; then
- haveit=
- if test "X$additional_includedir" = "X/usr/local/include"; then
- if test -n "$GCC"; then
- case $host_os in
- linux*) haveit=yes;;
- esac
- fi
- fi
- if test -z "$haveit"; then
- for x in $CPPFLAGS $INCINTL; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-I$additional_includedir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- if test -d "$additional_includedir"; then
- INCINTL="${INCINTL}${INCINTL:+ }-I$additional_includedir"
- fi
- fi
- fi
- fi
- fi
- if test -n "$found_la"; then
- save_libdir="$libdir"
- case "$found_la" in
- */* | *\\*) . "$found_la" ;;
- *) . "./$found_la" ;;
- esac
- libdir="$save_libdir"
- for dep in $dependency_libs; do
- case "$dep" in
- -L*)
- additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
- if test "X$additional_libdir" != "X/usr/lib"; then
- haveit=
- if test "X$additional_libdir" = "X/usr/local/lib"; then
- if test -n "$GCC"; then
- case $host_os in
- linux*) haveit=yes;;
- esac
- fi
- fi
- if test -z "$haveit"; then
- haveit=
- for x in $LDFLAGS $LIBINTL; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-L$additional_libdir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- if test -d "$additional_libdir"; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }-L$additional_libdir"
- fi
- fi
- haveit=
- for x in $LDFLAGS $LTLIBINTL; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-L$additional_libdir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- if test -d "$additional_libdir"; then
- LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-L$additional_libdir"
- fi
- fi
- fi
- fi
- ;;
- -R*)
- dir=`echo "X$dep" | sed -e 's/^X-R//'`
- if test "$enable_rpath" != no; then
- haveit=
- for x in $rpathdirs; do
- if test "X$x" = "X$dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- rpathdirs="$rpathdirs $dir"
- fi
- haveit=
- for x in $ltrpathdirs; do
- if test "X$x" = "X$dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- ltrpathdirs="$ltrpathdirs $dir"
- fi
- fi
- ;;
- -l*)
- names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
- ;;
- *.la)
- names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
- ;;
- *)
- LIBINTL="${LIBINTL}${LIBINTL:+ }$dep"
- LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }$dep"
- ;;
- esac
- done
- fi
- else
- if test "x$lib_type" = "xauto" || test "x$lib_type" = "xshared"; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }-l$name"
- LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-l$name"
- else
- LIBINTL="${LIBINTL}${LIBINTL:+ }-l:lib$name.$libext"
- LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-l:lib$name.$libext"
- fi
- fi
- fi
- fi
- done
- done
- if test "X$rpathdirs" != "X"; then
- if test -n "$hardcode_libdir_separator"; then
- alldirs=
- for found_dir in $rpathdirs; do
- alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
- done
- acl_save_libdir="$libdir"
- libdir="$alldirs"
- eval flag=\"$hardcode_libdir_flag_spec\"
- libdir="$acl_save_libdir"
- LIBINTL="${LIBINTL}${LIBINTL:+ }$flag"
- else
- for found_dir in $rpathdirs; do
- acl_save_libdir="$libdir"
- libdir="$found_dir"
- eval flag=\"$hardcode_libdir_flag_spec\"
- libdir="$acl_save_libdir"
- LIBINTL="${LIBINTL}${LIBINTL:+ }$flag"
- done
- fi
- fi
- if test "X$ltrpathdirs" != "X"; then
- for found_dir in $ltrpathdirs; do
- LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-R$found_dir"
- done
- fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU gettext in libintl" >&5
-$as_echo_n "checking for GNU gettext in libintl... " >&6; }
-if eval \${$gt_func_gnugettext_libintl+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- gt_save_CPPFLAGS="$CPPFLAGS"
- CPPFLAGS="$CPPFLAGS $INCINTL"
- gt_save_LIBS="$LIBS"
- LIBS="$LIBS $LIBINTL"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <libintl.h>
-#ifndef __GNU_GETTEXT_SUPPORTED_REVISION
-extern int _nl_msg_cat_cntr;
-extern
-#ifdef __cplusplus
-"C"
-#endif
-const char *_nl_expand_alias (const char *);
-#define __GNU_GETTEXT_SYMBOL_EXPRESSION (_nl_msg_cat_cntr + *_nl_expand_alias (""))
-#else
-#define __GNU_GETTEXT_SYMBOL_EXPRESSION 0
-#endif
-$gt_revision_test_code
-
-int
-main ()
-{
-
-bindtextdomain ("", "");
-return * gettext ("")$gt_expression_test_code + __GNU_GETTEXT_SYMBOL_EXPRESSION
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- eval "$gt_func_gnugettext_libintl=yes"
-else
- eval "$gt_func_gnugettext_libintl=no"
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" != yes; } && test -n "$LIBICONV"; then
- LIBS="$LIBS $LIBICONV"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <libintl.h>
-#ifndef __GNU_GETTEXT_SUPPORTED_REVISION
-extern int _nl_msg_cat_cntr;
-extern
-#ifdef __cplusplus
-"C"
-#endif
-const char *_nl_expand_alias (const char *);
-#define __GNU_GETTEXT_SYMBOL_EXPRESSION (_nl_msg_cat_cntr + *_nl_expand_alias (""))
-#else
-#define __GNU_GETTEXT_SYMBOL_EXPRESSION 0
-#endif
-$gt_revision_test_code
-
-int
-main ()
-{
-
-bindtextdomain ("", "");
-return * gettext ("")$gt_expression_test_code + __GNU_GETTEXT_SYMBOL_EXPRESSION
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- LIBINTL="$LIBINTL $LIBICONV"
- LTLIBINTL="$LTLIBINTL $LTLIBICONV"
- eval "$gt_func_gnugettext_libintl=yes"
-
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- fi
- CPPFLAGS="$gt_save_CPPFLAGS"
- LIBS="$gt_save_LIBS"
-fi
-eval ac_res=\$$gt_func_gnugettext_libintl
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
- fi
-
- if { eval "gt_val=\$$gt_func_gnugettext_libc"; test "$gt_val" = "yes"; } \
- || { { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; } \
- && test "$PACKAGE" != gettext-runtime \
- && test "$PACKAGE" != gettext-tools; }; then
- gt_use_preinstalled_gnugettext=yes
- else
- LIBINTL=
- LTLIBINTL=
- INCINTL=
- fi
-
-
-
- if test -n "$INTL_MACOSX_LIBS"; then
- if test "$gt_use_preinstalled_gnugettext" = "yes" \
- || test "$nls_cv_use_gnu_gettext" = "yes"; then
- LIBINTL="$LIBINTL $INTL_MACOSX_LIBS"
- LTLIBINTL="$LTLIBINTL $INTL_MACOSX_LIBS"
- fi
- fi
-
- if test "$gt_use_preinstalled_gnugettext" = "yes" \
- || test "$nls_cv_use_gnu_gettext" = "yes"; then
-
-$as_echo "#define ENABLE_NLS 1" >>confdefs.h
-
- else
- USE_NLS=no
- fi
- fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use NLS" >&5
-$as_echo_n "checking whether to use NLS... " >&6; }
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_NLS" >&5
-$as_echo "$USE_NLS" >&6; }
- if test "$USE_NLS" = "yes"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking where the gettext function comes from" >&5
-$as_echo_n "checking where the gettext function comes from... " >&6; }
- if test "$gt_use_preinstalled_gnugettext" = "yes"; then
- if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; }; then
- gt_source="external libintl"
- else
- gt_source="libc"
- fi
- else
- gt_source="included intl directory"
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_source" >&5
-$as_echo "$gt_source" >&6; }
- fi
-
- if test "$USE_NLS" = "yes"; then
-
- if test "$gt_use_preinstalled_gnugettext" = "yes"; then
- if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; }; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libintl" >&5
-$as_echo_n "checking how to link with libintl... " >&6; }
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBINTL" >&5
-$as_echo "$LIBINTL" >&6; }
-
- for element in $INCINTL; do
- haveit=
- for x in $CPPFLAGS; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X$element"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
- fi
- done
-
- fi
-
-
-$as_echo "#define HAVE_GETTEXT 1" >>confdefs.h
-
-
-$as_echo "#define HAVE_DCGETTEXT 1" >>confdefs.h
-
- fi
-
- POSUB=po
- fi
-
-
-
- INTLLIBS="$LIBINTL"
-
-
-
-
-
-
-fi
-
-
-
-
-
-
-
-
-
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NLS is requested" >&5
-$as_echo_n "checking whether NLS is requested... " >&6; }
-if test x"$USE_NLS" != xyes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-
-$as_echo "#define ENABLE_NLS 1" >>confdefs.h
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for catalogs to be installed" >&5
-$as_echo_n "checking for catalogs to be installed... " >&6; }
- # Look for .po and .gmo files in the source directory.
- CATALOGS=
- XLINGUAS=
- for cat in $srcdir/po/*.gmo $srcdir/po/*.po; do
- # If there aren't any .gmo files the shell will give us the
- # literal string "../path/to/srcdir/po/*.gmo" which has to be
- # weeded out.
- case "$cat" in *\**)
- continue;;
- esac
- # The quadruple backslash is collapsed to a double backslash
- # by the backticks, then collapsed again by the double quotes,
- # leaving us with one backslash in the sed expression (right
- # before the dot that mustn't act as a wildcard).
- cat=`echo $cat | sed -e "s!$srcdir/po/!!" -e "s!\\\\.po!.gmo!"`
- lang=`echo $cat | sed -e "s!\\\\.gmo!!"`
- # The user is allowed to set LINGUAS to a list of languages to
- # install catalogs for. If it's empty that means "all of them."
- if test "x$LINGUAS" = x; then
- CATALOGS="$CATALOGS $cat"
- XLINGUAS="$XLINGUAS $lang"
- else
- case "$LINGUAS" in *$lang*)
- CATALOGS="$CATALOGS $cat"
- XLINGUAS="$XLINGUAS $lang"
- ;;
- esac
- fi
- done
- LINGUAS="$XLINGUAS"
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LINGUAS" >&5
-$as_echo "$LINGUAS" >&6; }
-
-
- DATADIRNAME=share
-
- INSTOBJEXT=.mo
-
- GENCAT=gencat
-
- CATOBJEXT=.gmo
-
-fi
-
-
-
-
-# Prepare PATH_SEPARATOR.
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-
-# Find out how to test for executable files. Don't use a zero-byte file,
-# as systems may use methods other than mode bits to determine executability.
-cat >conf$$.file <<_ASEOF
-#! /bin/sh
-exit 0
-_ASEOF
-chmod +x conf$$.file
-if test -x conf$$.file >/dev/null 2>&1; then
- ac_executable_p="test -x"
-else
- ac_executable_p="test -f"
-fi
-rm -f conf$$.file
-
-# Extract the first word of "msgfmt", so it can be a program name with args.
-set dummy msgfmt; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_MSGFMT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case "$MSGFMT" in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
- ;;
- *)
- ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH; do
- IFS="$ac_save_IFS"
- test -z "$ac_dir" && ac_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
- if $ac_dir/$ac_word --statistics /dev/null >/dev/null 2>&1 &&
- (if $ac_dir/$ac_word --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- ac_cv_path_MSGFMT="$ac_dir/$ac_word$ac_exec_ext"
- break 2
- fi
- fi
- done
- done
- IFS="$ac_save_IFS"
- test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT=":"
- ;;
-esac
-fi
-MSGFMT="$ac_cv_path_MSGFMT"
-if test "$MSGFMT" != ":"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGFMT" >&5
-$as_echo "$MSGFMT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- # Extract the first word of "gmsgfmt", so it can be a program name with args.
-set dummy gmsgfmt; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_GMSGFMT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $GMSGFMT in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
- ;;
- *)
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_path_GMSGFMT="$as_dir/$ac_word$ac_exec_ext"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
- test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT"
- ;;
-esac
-fi
-GMSGFMT=$ac_cv_path_GMSGFMT
-if test -n "$GMSGFMT"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GMSGFMT" >&5
-$as_echo "$GMSGFMT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-
-
-# Prepare PATH_SEPARATOR.
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-
-# Find out how to test for executable files. Don't use a zero-byte file,
-# as systems may use methods other than mode bits to determine executability.
-cat >conf$$.file <<_ASEOF
-#! /bin/sh
-exit 0
-_ASEOF
-chmod +x conf$$.file
-if test -x conf$$.file >/dev/null 2>&1; then
- ac_executable_p="test -x"
-else
- ac_executable_p="test -f"
-fi
-rm -f conf$$.file
-
-# Extract the first word of "xgettext", so it can be a program name with args.
-set dummy xgettext; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_XGETTEXT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case "$XGETTEXT" in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
- ;;
- *)
- ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH; do
- IFS="$ac_save_IFS"
- test -z "$ac_dir" && ac_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
- if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >/dev/null 2>&1 &&
- (if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- ac_cv_path_XGETTEXT="$ac_dir/$ac_word$ac_exec_ext"
- break 2
- fi
- fi
- done
- done
- IFS="$ac_save_IFS"
- test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":"
- ;;
-esac
-fi
-XGETTEXT="$ac_cv_path_XGETTEXT"
-if test "$XGETTEXT" != ":"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XGETTEXT" >&5
-$as_echo "$XGETTEXT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- rm -f messages.po
-
-
-# Prepare PATH_SEPARATOR.
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-
-# Find out how to test for executable files. Don't use a zero-byte file,
-# as systems may use methods other than mode bits to determine executability.
-cat >conf$$.file <<_ASEOF
-#! /bin/sh
-exit 0
-_ASEOF
-chmod +x conf$$.file
-if test -x conf$$.file >/dev/null 2>&1; then
- ac_executable_p="test -x"
-else
- ac_executable_p="test -f"
-fi
-rm -f conf$$.file
-
-# Extract the first word of "msgmerge", so it can be a program name with args.
-set dummy msgmerge; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_MSGMERGE+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case "$MSGMERGE" in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_MSGMERGE="$MSGMERGE" # Let the user override the test with a path.
- ;;
- *)
- ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH; do
- IFS="$ac_save_IFS"
- test -z "$ac_dir" && ac_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
- if $ac_dir/$ac_word --update -q /dev/null /dev/null >/dev/null 2>&1; then
- ac_cv_path_MSGMERGE="$ac_dir/$ac_word$ac_exec_ext"
- break 2
- fi
- fi
- done
- done
- IFS="$ac_save_IFS"
- test -z "$ac_cv_path_MSGMERGE" && ac_cv_path_MSGMERGE=":"
- ;;
-esac
-fi
-MSGMERGE="$ac_cv_path_MSGMERGE"
-if test "$MSGMERGE" != ":"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGMERGE" >&5
-$as_echo "$MSGMERGE" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- if test "$GMSGFMT" != ":"; then
- if $GMSGFMT --statistics /dev/null >/dev/null 2>&1 &&
- (if $GMSGFMT --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- : ;
- else
- GMSGFMT=`echo "$GMSGFMT" | sed -e 's,^.*/,,'`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: found $GMSGFMT program is not GNU msgfmt; ignore it" >&5
-$as_echo "found $GMSGFMT program is not GNU msgfmt; ignore it" >&6; }
- GMSGFMT=":"
- fi
- fi
-
- if test "$XGETTEXT" != ":"; then
- if $XGETTEXT --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >/dev/null 2>&1 &&
- (if $XGETTEXT --omit-header --copyright-holder= --msgid-bugs-address= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- : ;
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: found xgettext program is not GNU xgettext; ignore it" >&5
-$as_echo "found xgettext program is not GNU xgettext; ignore it" >&6; }
- XGETTEXT=":"
- fi
- rm -f messages.po
- fi
-
- ac_config_commands="$ac_config_commands default-2"
-
-
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable maintainer-specific portions of Makefiles" >&5
-$as_echo_n "checking whether to enable maintainer-specific portions of Makefiles... " >&6; }
- # Check whether --enable-maintainer-mode was given.
-if test "${enable_maintainer_mode+set}" = set; then :
- enableval=$enable_maintainer_mode; USE_MAINTAINER_MODE=$enableval
-else
- USE_MAINTAINER_MODE=no
-fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_MAINTAINER_MODE" >&5
-$as_echo "$USE_MAINTAINER_MODE" >&6; }
- if test $USE_MAINTAINER_MODE = yes; then
- MAINTAINER_MODE_TRUE=
- MAINTAINER_MODE_FALSE='#'
-else
- MAINTAINER_MODE_TRUE='#'
- MAINTAINER_MODE_FALSE=
-fi
-
- MAINT=$MAINTAINER_MODE_TRUE
-
-
- if false; then
- GENINSRC_NEVER_TRUE=
- GENINSRC_NEVER_FALSE='#'
-else
- GENINSRC_NEVER_TRUE='#'
- GENINSRC_NEVER_FALSE=
-fi
-
-
-
-for ac_header in sys/gmon_out.h
-do :
- ac_fn_c_check_header_mongrel "$LINENO" "sys/gmon_out.h" "ac_cv_header_sys_gmon_out_h" "$ac_includes_default"
-if test "x$ac_cv_header_sys_gmon_out_h" = xyes; then :
- cat >>confdefs.h <<_ACEOF
-#define HAVE_SYS_GMON_OUT_H 1
-_ACEOF
-
-fi
-
-done
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a known getopt prototype in unistd.h" >&5
-$as_echo_n "checking for a known getopt prototype in unistd.h... " >&6; }
-if ${gprof_cv_decl_getopt_unistd_h+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <unistd.h>
-int
-main ()
-{
-extern int getopt (int, char *const*, const char *);
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- gprof_cv_decl_getopt_unistd_h=yes
-else
- gprof_cv_decl_getopt_unistd_h=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gprof_cv_decl_getopt_unistd_h" >&5
-$as_echo "$gprof_cv_decl_getopt_unistd_h" >&6; }
-if test $gprof_cv_decl_getopt_unistd_h = yes; then
-
-$as_echo "#define HAVE_DECL_GETOPT 1" >>confdefs.h
-
-fi
-
-# Some systems have fabs only in -lm, not in -lc.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing fabs" >&5
-$as_echo_n "checking for library containing fabs... " >&6; }
-if ${ac_cv_search_fabs+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_func_search_save_LIBS=$LIBS
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char fabs ();
-int
-main ()
-{
-return fabs ();
- ;
- return 0;
-}
-_ACEOF
-for ac_lib in '' m; do
- if test -z "$ac_lib"; then
- ac_res="none required"
- else
- ac_res=-l$ac_lib
- LIBS="-l$ac_lib $ac_func_search_save_LIBS"
- fi
- if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_search_fabs=$ac_res
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext
- if ${ac_cv_search_fabs+:} false; then :
- break
-fi
-done
-if ${ac_cv_search_fabs+:} false; then :
-
-else
- ac_cv_search_fabs=no
-fi
-rm conftest.$ac_ext
-LIBS=$ac_func_search_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_fabs" >&5
-$as_echo "$ac_cv_search_fabs" >&6; }
-ac_res=$ac_cv_search_fabs
-if test "$ac_res" != no; then :
- test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
-
-fi
-
-
-
-# Set the 'development' global.
-. $srcdir/../bfd/development.sh
-
-# Set acp_cpp_for_build variable
-ac_cpp_for_build="$CC_FOR_BUILD -E $CPPFLAGS_FOR_BUILD"
-
-# Default set of GCC warnings to enable.
-GCC_WARN_CFLAGS="-W -Wall -Wstrict-prototypes -Wmissing-prototypes"
-GCC_WARN_CFLAGS_FOR_BUILD="-W -Wall -Wstrict-prototypes -Wmissing-prototypes"
-
-# Add -Wshadow if the compiler is a sufficiently recent version of GCC.
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-__GNUC__
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "(^[0-3]$|^__GNUC__$)" >/dev/null 2>&1; then :
-
-else
- GCC_WARN_CFLAGS="$GCC_WARN_CFLAGS -Wshadow"
-fi
-rm -f conftest*
-
-
-# Add -Wstack-usage if the compiler is a sufficiently recent version of GCC.
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-__GNUC__
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "(^[0-4]$|^__GNUC__$)" >/dev/null 2>&1; then :
-
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-__clang__
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "^__clang__$" >/dev/null 2>&1; then :
- GCC_WARN_CFLAGS="$GCC_WARN_CFLAGS -Wstack-usage=262144"
-fi
-rm -f conftest*
-
-fi
-rm -f conftest*
-
-
-# Set WARN_WRITE_STRINGS if the compiler supports -Wwrite-strings.
-WARN_WRITE_STRINGS=""
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-__GNUC__
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "(^[0-3]$|^__GNUC__$)" >/dev/null 2>&1; then :
-
-else
- WARN_WRITE_STRINGS="-Wwrite-strings"
-fi
-rm -f conftest*
-
-
-# Verify CC_FOR_BUILD to be compatible with warning flags
-
-# Add -Wshadow if the compiler is a sufficiently recent version of GCC.
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-__GNUC__
-_ACEOF
-if (eval "$ac_cpp_for_build conftest.$ac_ext") 2>&5 |
- $EGREP "(^[0-3]$|^__GNUC__$)" >/dev/null 2>&1; then :
-
-else
- GCC_WARN_CFLAGS_FOR_BUILD="$GCC_WARN_CFLAGS_FOR_BUILD -Wshadow"
-fi
-rm -f conftest*
-
-
-# Add -Wstack-usage if the compiler is a sufficiently recent version of GCC.
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-__GNUC__
-_ACEOF
-if (eval "$ac_cpp_for_build conftest.$ac_ext") 2>&5 |
- $EGREP "(^[0-4]$|^__GNUC__$)" >/dev/null 2>&1; then :
-
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-__clang__
-_ACEOF
-if (eval "$ac_cpp_for_build conftest.$ac_ext") 2>&5 |
- $EGREP "^__clang__$" >/dev/null 2>&1; then :
- GCC_WARN_CFLAGS_FOR_BUILD="$GCC_WARN_CFLAGS_FOR_BUILD -Wstack-usage=262144"
-fi
-rm -f conftest*
-
-fi
-rm -f conftest*
-
-
-# Check whether --enable-werror was given.
-if test "${enable_werror+set}" = set; then :
- enableval=$enable_werror; case "${enableval}" in
- yes | y) ERROR_ON_WARNING="yes" ;;
- no | n) ERROR_ON_WARNING="no" ;;
- *) as_fn_error $? "bad value ${enableval} for --enable-werror" "$LINENO" 5 ;;
- esac
-fi
-
-
-# Disable -Wformat by default when using gcc on mingw
-case "${host}" in
- *-*-mingw32*)
- if test "${GCC}" = yes -a -z "${ERROR_ON_WARNING}" ; then
- GCC_WARN_CFLAGS="$GCC_WARN_CFLAGS -Wno-format"
- GCC_WARN_CFLAGS_FOR_BUILD="$GCC_WARN_CFLAGS_FOR_BUILD -Wno-format"
- fi
- ;;
- *) ;;
-esac
-
-# Enable -Werror by default when using gcc. Turn it off for releases.
-if test "${GCC}" = yes -a -z "${ERROR_ON_WARNING}" -a "$development" = true ; then
- ERROR_ON_WARNING=yes
-fi
-
-NO_WERROR=
-if test "${ERROR_ON_WARNING}" = yes ; then
- GCC_WARN_CFLAGS="$GCC_WARN_CFLAGS -Werror"
- GCC_WARN_CFLAGS_FOR_BUILD="$GCC_WARN_CFLAGS_FOR_BUILD -Werror"
- NO_WERROR="-Wno-error"
-fi
-
-if test "${GCC}" = yes ; then
- WARN_CFLAGS="${GCC_WARN_CFLAGS}"
- WARN_CFLAGS_FOR_BUILD="${GCC_WARN_CFLAGS_FOR_BUILD}"
-fi
-
-# Check whether --enable-build-warnings was given.
-if test "${enable_build_warnings+set}" = set; then :
- enableval=$enable_build_warnings; case "${enableval}" in
- yes) WARN_CFLAGS="${GCC_WARN_CFLAGS}"
- WARN_CFLAGS_FOR_BUILD="${GCC_WARN_CFLAGS_FOR_BUILD}";;
- no) if test "${GCC}" = yes ; then
- WARN_CFLAGS="-w"
- WARN_CFLAGS_FOR_BUILD="-w"
- fi;;
- ,*) t=`echo "${enableval}" | sed -e "s/,/ /g"`
- WARN_CFLAGS="${GCC_WARN_CFLAGS} ${t}"
- WARN_CFLAGS_FOR_BUILD="${GCC_WARN_CFLAGS_FOR_BUILD} ${t}";;
- *,) t=`echo "${enableval}" | sed -e "s/,/ /g"`
- WARN_CFLAGS="${t} ${GCC_WARN_CFLAGS}"
- WARN_CFLAGS_FOR_BUILD="${t} ${GCC_WARN_CFLAGS_FOR_BUILD}";;
- *) WARN_CFLAGS=`echo "${enableval}" | sed -e "s/,/ /g"`
- WARN_CFLAGS_FOR_BUILD=`echo "${enableval}" | sed -e "s/,/ /g"`;;
-esac
-fi
-
-
-if test x"$silent" != x"yes" && test x"$WARN_CFLAGS" != x""; then
- echo "Setting warning flags = $WARN_CFLAGS" 6>&1
-fi
-
-
-
-
-
-
-
-
-
-
-
-
-ac_config_files="$ac_config_files Makefile po/Makefile.in:po/Make-in"
-
-cat >confcache <<\_ACEOF
-# This file is a shell script that caches the results of configure
-# tests run on this system so they can be shared between configure
-# scripts and configure runs, see configure's option --config-cache.
-# It is not useful on other systems. If it contains results you don't
-# want to keep, you may remove or edit it.
-#
-# config.status only pays attention to the cache file if you give it
-# the --recheck option to rerun configure.
-#
-# `ac_cv_env_foo' variables (set or unset) will be overridden when
-# loading this file, other *unset* `ac_cv_foo' will be assigned the
-# following values.
-
-_ACEOF
-
-# The following way of writing the cache mishandles newlines in values,
-# but we know of no workaround that is simple, portable, and efficient.
-# So, we kill variables containing newlines.
-# Ultrix sh set writes to stderr and can't be redirected directly,
-# and sets the high bit in the cache file unless we assign to the vars.
-(
- for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
- eval ac_val=\$$ac_var
- case $ac_val in #(
- *${as_nl}*)
- case $ac_var in #(
- *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
-$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
- esac
- case $ac_var in #(
- _ | IFS | as_nl) ;; #(
- BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
- *) { eval $ac_var=; unset $ac_var;} ;;
- esac ;;
- esac
- done
-
- (set) 2>&1 |
- case $as_nl`(ac_space=' '; set) 2>&1` in #(
- *${as_nl}ac_space=\ *)
- # `set' does not quote correctly, so add quotes: double-quote
- # substitution turns \\\\ into \\, and sed turns \\ into \.
- sed -n \
- "s/'/'\\\\''/g;
- s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
- ;; #(
- *)
- # `set' quotes correctly as required by POSIX, so do not add quotes.
- sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
- ;;
- esac |
- sort
-) |
- sed '
- /^ac_cv_env_/b end
- t clear
- :clear
- s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
- t end
- s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
- :end' >>confcache
-if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
- if test -w "$cache_file"; then
- if test "x$cache_file" != "x/dev/null"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
-$as_echo "$as_me: updating cache $cache_file" >&6;}
- if test ! -f "$cache_file" || test -h "$cache_file"; then
- cat confcache >"$cache_file"
- else
- case $cache_file in #(
- */* | ?:*)
- mv -f confcache "$cache_file"$$ &&
- mv -f "$cache_file"$$ "$cache_file" ;; #(
- *)
- mv -f confcache "$cache_file" ;;
- esac
- fi
- fi
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
-$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
- fi
-fi
-rm -f confcache
-
-test "x$prefix" = xNONE && prefix=$ac_default_prefix
-# Let make expand exec_prefix.
-test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
-
-DEFS=-DHAVE_CONFIG_H
-
-ac_libobjs=
-ac_ltlibobjs=
-U=
-for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
- # 1. Remove the extension, and $U if already installed.
- ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
- ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
- # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
- # will be set to the directory where LIBOBJS objects are built.
- as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
- as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
-done
-LIBOBJS=$ac_libobjs
-
-LTLIBOBJS=$ac_ltlibobjs
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking that generated files are newer than configure" >&5
-$as_echo_n "checking that generated files are newer than configure... " >&6; }
- if test -n "$am_sleep_pid"; then
- # Hide warnings about reused PIDs.
- wait $am_sleep_pid 2>/dev/null
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: done" >&5
-$as_echo "done" >&6; }
- if test -n "$EXEEXT"; then
- am__EXEEXT_TRUE=
- am__EXEEXT_FALSE='#'
-else
- am__EXEEXT_TRUE='#'
- am__EXEEXT_FALSE=
-fi
-
-if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
- as_fn_error $? "conditional \"AMDEP\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
- as_fn_error $? "conditional \"am__fastdepCC\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${MAINTAINER_MODE_TRUE}" && test -z "${MAINTAINER_MODE_FALSE}"; then
- as_fn_error $? "conditional \"MAINTAINER_MODE\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${GENINSRC_NEVER_TRUE}" && test -z "${GENINSRC_NEVER_FALSE}"; then
- as_fn_error $? "conditional \"GENINSRC_NEVER\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-
-: "${CONFIG_STATUS=./config.status}"
-ac_write_fail=0
-ac_clean_files_save=$ac_clean_files
-ac_clean_files="$ac_clean_files $CONFIG_STATUS"
-{ $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
-$as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
-as_write_fail=0
-cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
-#! $SHELL
-# Generated by $as_me.
-# Run this file to recreate the current configuration.
-# Compiler output produced by configure, useful for debugging
-# configure, is in config.log if it exists.
-
-debug=false
-ac_cs_recheck=false
-ac_cs_silent=false
-
-SHELL=\${CONFIG_SHELL-$SHELL}
-export SHELL
-_ASEOF
-cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
-## -------------------- ##
-## M4sh Initialization. ##
-## -------------------- ##
-
-# Be more Bourne compatible
-DUALCASE=1; export DUALCASE # for MKS sh
-if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
- emulate sh
- NULLCMD=:
- # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
- # is contrary to our usage. Disable this feature.
- alias -g '${1+"$@"}'='"$@"'
- setopt NO_GLOB_SUBST
-else
- case `(set -o) 2>/dev/null` in #(
- *posix*) :
- set -o posix ;; #(
- *) :
- ;;
-esac
-fi
-
-
-as_nl='
-'
-export as_nl
-# Printing a long string crashes Solaris 7 /usr/bin/printf.
-as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
-as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
-as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
-# Prefer a ksh shell builtin over an external printf program on Solaris,
-# but without wasting forks for bash or zsh.
-if test -z "$BASH_VERSION$ZSH_VERSION" \
- && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
- as_echo='print -r --'
- as_echo_n='print -rn --'
-elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
- as_echo='printf %s\n'
- as_echo_n='printf %s'
-else
- if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
- as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
- as_echo_n='/usr/ucb/echo -n'
- else
- as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
- as_echo_n_body='eval
- arg=$1;
- case $arg in #(
- *"$as_nl"*)
- expr "X$arg" : "X\\(.*\\)$as_nl";
- arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
- esac;
- expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
- '
- export as_echo_n_body
- as_echo_n='sh -c $as_echo_n_body as_echo'
- fi
- export as_echo_body
- as_echo='sh -c $as_echo_body as_echo'
-fi
-
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- PATH_SEPARATOR=:
- (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
- (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
- PATH_SEPARATOR=';'
- }
-fi
-
-
-# IFS
-# We need space, tab and new line, in precisely that order. Quoting is
-# there to prevent editors from complaining about space-tab.
-# (If _AS_PATH_WALK were called with IFS unset, it would disable word
-# splitting by setting IFS to empty value.)
-IFS=" "" $as_nl"
-
-# Find who we are. Look in the path if we contain no directory separator.
-as_myself=
-case $0 in #((
- *[\\/]* ) as_myself=$0 ;;
- *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
- done
-IFS=$as_save_IFS
-
- ;;
-esac
-# We did not find ourselves, most probably we were run as `sh COMMAND'
-# in which case we are not to be found in the path.
-if test "x$as_myself" = x; then
- as_myself=$0
-fi
-if test ! -f "$as_myself"; then
- $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
- exit 1
-fi
-
-# Unset variables that we do not need and which cause bugs (e.g. in
-# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
-# suppresses any "Segmentation fault" message there. '((' could
-# trigger a bug in pdksh 5.2.14.
-for as_var in BASH_ENV ENV MAIL MAILPATH
-do eval test x\${$as_var+set} = xset \
- && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
-done
-PS1='$ '
-PS2='> '
-PS4='+ '
-
-# NLS nuisances.
-LC_ALL=C
-export LC_ALL
-LANGUAGE=C
-export LANGUAGE
-
-# CDPATH.
-(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
-
-
-# as_fn_error STATUS ERROR [LINENO LOG_FD]
-# ----------------------------------------
-# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
-# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
-# script with STATUS, using 1 if that was 0.
-as_fn_error ()
-{
- as_status=$1; test $as_status -eq 0 && as_status=1
- if test "$4"; then
- as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
- fi
- $as_echo "$as_me: error: $2" >&2
- as_fn_exit $as_status
-} # as_fn_error
-
-
-# as_fn_set_status STATUS
-# -----------------------
-# Set $? to STATUS, without forking.
-as_fn_set_status ()
-{
- return $1
-} # as_fn_set_status
-
-# as_fn_exit STATUS
-# -----------------
-# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
-as_fn_exit ()
-{
- set +e
- as_fn_set_status $1
- exit $1
-} # as_fn_exit
-
-# as_fn_unset VAR
-# ---------------
-# Portably unset VAR.
-as_fn_unset ()
-{
- { eval $1=; unset $1;}
-}
-as_unset=as_fn_unset
-# as_fn_append VAR VALUE
-# ----------------------
-# Append the text in VALUE to the end of the definition contained in VAR. Take
-# advantage of any shell optimizations that allow amortized linear growth over
-# repeated appends, instead of the typical quadratic growth present in naive
-# implementations.
-if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
- eval 'as_fn_append ()
- {
- eval $1+=\$2
- }'
-else
- as_fn_append ()
- {
- eval $1=\$$1\$2
- }
-fi # as_fn_append
-
-# as_fn_arith ARG...
-# ------------------
-# Perform arithmetic evaluation on the ARGs, and store the result in the
-# global $as_val. Take advantage of shells that can avoid forks. The arguments
-# must be portable across $(()) and expr.
-if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
- eval 'as_fn_arith ()
- {
- as_val=$(( $* ))
- }'
-else
- as_fn_arith ()
- {
- as_val=`expr "$@" || test $? -eq 1`
- }
-fi # as_fn_arith
-
-
-if expr a : '\(a\)' >/dev/null 2>&1 &&
- test "X`expr 00001 : '.*\(...\)'`" = X001; then
- as_expr=expr
-else
- as_expr=false
-fi
-
-if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
- as_basename=basename
-else
- as_basename=false
-fi
-
-if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
- as_dirname=dirname
-else
- as_dirname=false
-fi
-
-as_me=`$as_basename -- "$0" ||
-$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
- X"$0" : 'X\(//\)$' \| \
- X"$0" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X/"$0" |
- sed '/^.*\/\([^/][^/]*\)\/*$/{
- s//\1/
- q
- }
- /^X\/\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\/\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
-
-# Avoid depending upon Character Ranges.
-as_cr_letters='abcdefghijklmnopqrstuvwxyz'
-as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
-as_cr_Letters=$as_cr_letters$as_cr_LETTERS
-as_cr_digits='0123456789'
-as_cr_alnum=$as_cr_Letters$as_cr_digits
-
-ECHO_C= ECHO_N= ECHO_T=
-case `echo -n x` in #(((((
--n*)
- case `echo 'xy\c'` in
- *c*) ECHO_T=' ';; # ECHO_T is single tab character.
- xy) ECHO_C='\c';;
- *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
- ECHO_T=' ';;
- esac;;
-*)
- ECHO_N='-n';;
-esac
-
-rm -f conf$$ conf$$.exe conf$$.file
-if test -d conf$$.dir; then
- rm -f conf$$.dir/conf$$.file
-else
- rm -f conf$$.dir
- mkdir conf$$.dir 2>/dev/null
-fi
-if (echo >conf$$.file) 2>/dev/null; then
- if ln -s conf$$.file conf$$ 2>/dev/null; then
- as_ln_s='ln -s'
- # ... but there are two gotchas:
- # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
- # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
- # In both cases, we have to default to `cp -pR'.
- ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
- as_ln_s='cp -pR'
- elif ln conf$$.file conf$$ 2>/dev/null; then
- as_ln_s=ln
- else
- as_ln_s='cp -pR'
- fi
-else
- as_ln_s='cp -pR'
-fi
-rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
-rmdir conf$$.dir 2>/dev/null
-
-
-# as_fn_mkdir_p
-# -------------
-# Create "$as_dir" as a directory, including parents if necessary.
-as_fn_mkdir_p ()
-{
-
- case $as_dir in #(
- -*) as_dir=./$as_dir;;
- esac
- test -d "$as_dir" || eval $as_mkdir_p || {
- as_dirs=
- while :; do
- case $as_dir in #(
- *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
- *) as_qdir=$as_dir;;
- esac
- as_dirs="'$as_qdir' $as_dirs"
- as_dir=`$as_dirname -- "$as_dir" ||
-$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$as_dir" : 'X\(//\)[^/]' \| \
- X"$as_dir" : 'X\(//\)$' \| \
- X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$as_dir" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
- test -d "$as_dir" && break
- done
- test -z "$as_dirs" || eval "mkdir $as_dirs"
- } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
-
-
-} # as_fn_mkdir_p
-if mkdir -p . 2>/dev/null; then
- as_mkdir_p='mkdir -p "$as_dir"'
-else
- test -d ./-p && rmdir ./-p
- as_mkdir_p=false
-fi
-
-
-# as_fn_executable_p FILE
-# -----------------------
-# Test if FILE is an executable regular file.
-as_fn_executable_p ()
-{
- test -f "$1" && test -x "$1"
-} # as_fn_executable_p
-as_test_x='test -x'
-as_executable_p=as_fn_executable_p
-
-# Sed expression to map a string onto a valid CPP name.
-as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
-
-# Sed expression to map a string onto a valid variable name.
-as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
-
-
-exec 6>&1
-## ----------------------------------- ##
-## Main body of $CONFIG_STATUS script. ##
-## ----------------------------------- ##
-_ASEOF
-test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
-
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-# Save the log message, to keep $0 and so on meaningful, and to
-# report actual input values of CONFIG_FILES etc. instead of their
-# values after options handling.
-ac_log="
-This file was extended by gprof $as_me 2.43.1, which was
-generated by GNU Autoconf 2.69. Invocation command line was
-
- CONFIG_FILES = $CONFIG_FILES
- CONFIG_HEADERS = $CONFIG_HEADERS
- CONFIG_LINKS = $CONFIG_LINKS
- CONFIG_COMMANDS = $CONFIG_COMMANDS
- $ $0 $@
-
-on `(hostname || uname -n) 2>/dev/null | sed 1q`
-"
-
-_ACEOF
-
-case $ac_config_files in *"
-"*) set x $ac_config_files; shift; ac_config_files=$*;;
-esac
-
-case $ac_config_headers in *"
-"*) set x $ac_config_headers; shift; ac_config_headers=$*;;
-esac
-
-
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-# Files that config.status was made for.
-config_files="$ac_config_files"
-config_headers="$ac_config_headers"
-config_commands="$ac_config_commands"
-
-_ACEOF
-
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-ac_cs_usage="\
-\`$as_me' instantiates files and other configuration actions
-from templates according to the current configuration. Unless the files
-and actions are specified as TAGs, all are instantiated by default.
-
-Usage: $0 [OPTION]... [TAG]...
-
- -h, --help print this help, then exit
- -V, --version print version number and configuration settings, then exit
- --config print configuration, then exit
- -q, --quiet, --silent
- do not print progress messages
- -d, --debug don't remove temporary files
- --recheck update $as_me by reconfiguring in the same conditions
- --file=FILE[:TEMPLATE]
- instantiate the configuration file FILE
- --header=FILE[:TEMPLATE]
- instantiate the configuration header FILE
-
-Configuration files:
-$config_files
-
-Configuration headers:
-$config_headers
-
-Configuration commands:
-$config_commands
-
-Report bugs to the package provider."
-
-_ACEOF
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
-ac_cs_version="\\
-gprof config.status 2.43.1
-configured by $0, generated by GNU Autoconf 2.69,
- with options \\"\$ac_cs_config\\"
-
-Copyright (C) 2012 Free Software Foundation, Inc.
-This config.status script is free software; the Free Software Foundation
-gives unlimited permission to copy, distribute and modify it."
-
-ac_pwd='$ac_pwd'
-srcdir='$srcdir'
-INSTALL='$INSTALL'
-MKDIR_P='$MKDIR_P'
-AWK='$AWK'
-test -n "\$AWK" || AWK=awk
-_ACEOF
-
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-# The default lists apply if the user does not specify any file.
-ac_need_defaults=:
-while test $# != 0
-do
- case $1 in
- --*=?*)
- ac_option=`expr "X$1" : 'X\([^=]*\)='`
- ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
- ac_shift=:
- ;;
- --*=)
- ac_option=`expr "X$1" : 'X\([^=]*\)='`
- ac_optarg=
- ac_shift=:
- ;;
- *)
- ac_option=$1
- ac_optarg=$2
- ac_shift=shift
- ;;
- esac
-
- case $ac_option in
- # Handling of the options.
- -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
- ac_cs_recheck=: ;;
- --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
- $as_echo "$ac_cs_version"; exit ;;
- --config | --confi | --conf | --con | --co | --c )
- $as_echo "$ac_cs_config"; exit ;;
- --debug | --debu | --deb | --de | --d | -d )
- debug=: ;;
- --file | --fil | --fi | --f )
- $ac_shift
- case $ac_optarg in
- *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
- '') as_fn_error $? "missing file argument" ;;
- esac
- as_fn_append CONFIG_FILES " '$ac_optarg'"
- ac_need_defaults=false;;
- --header | --heade | --head | --hea )
- $ac_shift
- case $ac_optarg in
- *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
- esac
- as_fn_append CONFIG_HEADERS " '$ac_optarg'"
- ac_need_defaults=false;;
- --he | --h)
- # Conflict between --help and --header
- as_fn_error $? "ambiguous option: \`$1'
-Try \`$0 --help' for more information.";;
- --help | --hel | -h )
- $as_echo "$ac_cs_usage"; exit ;;
- -q | -quiet | --quiet | --quie | --qui | --qu | --q \
- | -silent | --silent | --silen | --sile | --sil | --si | --s)
- ac_cs_silent=: ;;
-
- # This is an error.
- -*) as_fn_error $? "unrecognized option: \`$1'
-Try \`$0 --help' for more information." ;;
-
- *) as_fn_append ac_config_targets " $1"
- ac_need_defaults=false ;;
-
- esac
- shift
-done
-
-ac_configure_extra_args=
-
-if $ac_cs_silent; then
- exec 6>/dev/null
- ac_configure_extra_args="$ac_configure_extra_args --silent"
-fi
-
-_ACEOF
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-if \$ac_cs_recheck; then
- set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
- shift
- \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
- CONFIG_SHELL='$SHELL'
- export CONFIG_SHELL
- exec "\$@"
-fi
-
-_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-exec 5>>config.log
-{
- echo
- sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
-## Running $as_me. ##
-_ASBOX
- $as_echo "$ac_log"
-} >&5
-
-_ACEOF
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-#
-# INIT-COMMANDS
-#
-AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"
-
-
-# The HP-UX ksh and POSIX shell print the target directory to stdout
-# if CDPATH is set.
-(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
-
-sed_quote_subst='$sed_quote_subst'
-double_quote_subst='$double_quote_subst'
-delay_variable_subst='$delay_variable_subst'
-macro_version='`$ECHO "$macro_version" | $SED "$delay_single_quote_subst"`'
-macro_revision='`$ECHO "$macro_revision" | $SED "$delay_single_quote_subst"`'
-enable_shared='`$ECHO "$enable_shared" | $SED "$delay_single_quote_subst"`'
-enable_static='`$ECHO "$enable_static" | $SED "$delay_single_quote_subst"`'
-pic_mode='`$ECHO "$pic_mode" | $SED "$delay_single_quote_subst"`'
-enable_fast_install='`$ECHO "$enable_fast_install" | $SED "$delay_single_quote_subst"`'
-SHELL='`$ECHO "$SHELL" | $SED "$delay_single_quote_subst"`'
-ECHO='`$ECHO "$ECHO" | $SED "$delay_single_quote_subst"`'
-host_alias='`$ECHO "$host_alias" | $SED "$delay_single_quote_subst"`'
-host='`$ECHO "$host" | $SED "$delay_single_quote_subst"`'
-host_os='`$ECHO "$host_os" | $SED "$delay_single_quote_subst"`'
-build_alias='`$ECHO "$build_alias" | $SED "$delay_single_quote_subst"`'
-build='`$ECHO "$build" | $SED "$delay_single_quote_subst"`'
-build_os='`$ECHO "$build_os" | $SED "$delay_single_quote_subst"`'
-SED='`$ECHO "$SED" | $SED "$delay_single_quote_subst"`'
-Xsed='`$ECHO "$Xsed" | $SED "$delay_single_quote_subst"`'
-GREP='`$ECHO "$GREP" | $SED "$delay_single_quote_subst"`'
-EGREP='`$ECHO "$EGREP" | $SED "$delay_single_quote_subst"`'
-FGREP='`$ECHO "$FGREP" | $SED "$delay_single_quote_subst"`'
-LD='`$ECHO "$LD" | $SED "$delay_single_quote_subst"`'
-NM='`$ECHO "$NM" | $SED "$delay_single_quote_subst"`'
-LN_S='`$ECHO "$LN_S" | $SED "$delay_single_quote_subst"`'
-max_cmd_len='`$ECHO "$max_cmd_len" | $SED "$delay_single_quote_subst"`'
-ac_objext='`$ECHO "$ac_objext" | $SED "$delay_single_quote_subst"`'
-exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`'
-lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`'
-lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`'
-lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`'
-reload_flag='`$ECHO "$reload_flag" | $SED "$delay_single_quote_subst"`'
-reload_cmds='`$ECHO "$reload_cmds" | $SED "$delay_single_quote_subst"`'
-OBJDUMP='`$ECHO "$OBJDUMP" | $SED "$delay_single_quote_subst"`'
-deplibs_check_method='`$ECHO "$deplibs_check_method" | $SED "$delay_single_quote_subst"`'
-file_magic_cmd='`$ECHO "$file_magic_cmd" | $SED "$delay_single_quote_subst"`'
-AR='`$ECHO "$AR" | $SED "$delay_single_quote_subst"`'
-AR_FLAGS='`$ECHO "$AR_FLAGS" | $SED "$delay_single_quote_subst"`'
-STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`'
-RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`'
-old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`'
-old_postuninstall_cmds='`$ECHO "$old_postuninstall_cmds" | $SED "$delay_single_quote_subst"`'
-old_archive_cmds='`$ECHO "$old_archive_cmds" | $SED "$delay_single_quote_subst"`'
-lock_old_archive_extraction='`$ECHO "$lock_old_archive_extraction" | $SED "$delay_single_quote_subst"`'
-CC='`$ECHO "$CC" | $SED "$delay_single_quote_subst"`'
-CFLAGS='`$ECHO "$CFLAGS" | $SED "$delay_single_quote_subst"`'
-compiler='`$ECHO "$compiler" | $SED "$delay_single_quote_subst"`'
-GCC='`$ECHO "$GCC" | $SED "$delay_single_quote_subst"`'
-lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$delay_single_quote_subst"`'
-lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`'
-lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`'
-lt_cv_sys_global_symbol_to_c_name_address_lib_prefix='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address_lib_prefix" | $SED "$delay_single_quote_subst"`'
-objdir='`$ECHO "$objdir" | $SED "$delay_single_quote_subst"`'
-MAGIC_CMD='`$ECHO "$MAGIC_CMD" | $SED "$delay_single_quote_subst"`'
-lt_prog_compiler_no_builtin_flag='`$ECHO "$lt_prog_compiler_no_builtin_flag" | $SED "$delay_single_quote_subst"`'
-lt_prog_compiler_wl='`$ECHO "$lt_prog_compiler_wl" | $SED "$delay_single_quote_subst"`'
-lt_prog_compiler_pic='`$ECHO "$lt_prog_compiler_pic" | $SED "$delay_single_quote_subst"`'
-lt_prog_compiler_static='`$ECHO "$lt_prog_compiler_static" | $SED "$delay_single_quote_subst"`'
-lt_cv_prog_compiler_c_o='`$ECHO "$lt_cv_prog_compiler_c_o" | $SED "$delay_single_quote_subst"`'
-need_locks='`$ECHO "$need_locks" | $SED "$delay_single_quote_subst"`'
-DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`'
-NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`'
-LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`'
-OTOOL='`$ECHO "$OTOOL" | $SED "$delay_single_quote_subst"`'
-OTOOL64='`$ECHO "$OTOOL64" | $SED "$delay_single_quote_subst"`'
-libext='`$ECHO "$libext" | $SED "$delay_single_quote_subst"`'
-shrext_cmds='`$ECHO "$shrext_cmds" | $SED "$delay_single_quote_subst"`'
-extract_expsyms_cmds='`$ECHO "$extract_expsyms_cmds" | $SED "$delay_single_quote_subst"`'
-archive_cmds_need_lc='`$ECHO "$archive_cmds_need_lc" | $SED "$delay_single_quote_subst"`'
-enable_shared_with_static_runtimes='`$ECHO "$enable_shared_with_static_runtimes" | $SED "$delay_single_quote_subst"`'
-export_dynamic_flag_spec='`$ECHO "$export_dynamic_flag_spec" | $SED "$delay_single_quote_subst"`'
-whole_archive_flag_spec='`$ECHO "$whole_archive_flag_spec" | $SED "$delay_single_quote_subst"`'
-compiler_needs_object='`$ECHO "$compiler_needs_object" | $SED "$delay_single_quote_subst"`'
-old_archive_from_new_cmds='`$ECHO "$old_archive_from_new_cmds" | $SED "$delay_single_quote_subst"`'
-old_archive_from_expsyms_cmds='`$ECHO "$old_archive_from_expsyms_cmds" | $SED "$delay_single_quote_subst"`'
-archive_cmds='`$ECHO "$archive_cmds" | $SED "$delay_single_quote_subst"`'
-archive_expsym_cmds='`$ECHO "$archive_expsym_cmds" | $SED "$delay_single_quote_subst"`'
-module_cmds='`$ECHO "$module_cmds" | $SED "$delay_single_quote_subst"`'
-module_expsym_cmds='`$ECHO "$module_expsym_cmds" | $SED "$delay_single_quote_subst"`'
-with_gnu_ld='`$ECHO "$with_gnu_ld" | $SED "$delay_single_quote_subst"`'
-allow_undefined_flag='`$ECHO "$allow_undefined_flag" | $SED "$delay_single_quote_subst"`'
-no_undefined_flag='`$ECHO "$no_undefined_flag" | $SED "$delay_single_quote_subst"`'
-hardcode_libdir_flag_spec='`$ECHO "$hardcode_libdir_flag_spec" | $SED "$delay_single_quote_subst"`'
-hardcode_libdir_flag_spec_ld='`$ECHO "$hardcode_libdir_flag_spec_ld" | $SED "$delay_single_quote_subst"`'
-hardcode_libdir_separator='`$ECHO "$hardcode_libdir_separator" | $SED "$delay_single_quote_subst"`'
-hardcode_direct='`$ECHO "$hardcode_direct" | $SED "$delay_single_quote_subst"`'
-hardcode_direct_absolute='`$ECHO "$hardcode_direct_absolute" | $SED "$delay_single_quote_subst"`'
-hardcode_minus_L='`$ECHO "$hardcode_minus_L" | $SED "$delay_single_quote_subst"`'
-hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_quote_subst"`'
-hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`'
-inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`'
-link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`'
-fix_srcfile_path='`$ECHO "$fix_srcfile_path" | $SED "$delay_single_quote_subst"`'
-always_export_symbols='`$ECHO "$always_export_symbols" | $SED "$delay_single_quote_subst"`'
-export_symbols_cmds='`$ECHO "$export_symbols_cmds" | $SED "$delay_single_quote_subst"`'
-exclude_expsyms='`$ECHO "$exclude_expsyms" | $SED "$delay_single_quote_subst"`'
-include_expsyms='`$ECHO "$include_expsyms" | $SED "$delay_single_quote_subst"`'
-prelink_cmds='`$ECHO "$prelink_cmds" | $SED "$delay_single_quote_subst"`'
-file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`'
-variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`'
-need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`'
-need_version='`$ECHO "$need_version" | $SED "$delay_single_quote_subst"`'
-version_type='`$ECHO "$version_type" | $SED "$delay_single_quote_subst"`'
-runpath_var='`$ECHO "$runpath_var" | $SED "$delay_single_quote_subst"`'
-shlibpath_var='`$ECHO "$shlibpath_var" | $SED "$delay_single_quote_subst"`'
-shlibpath_overrides_runpath='`$ECHO "$shlibpath_overrides_runpath" | $SED "$delay_single_quote_subst"`'
-libname_spec='`$ECHO "$libname_spec" | $SED "$delay_single_quote_subst"`'
-library_names_spec='`$ECHO "$library_names_spec" | $SED "$delay_single_quote_subst"`'
-soname_spec='`$ECHO "$soname_spec" | $SED "$delay_single_quote_subst"`'
-install_override_mode='`$ECHO "$install_override_mode" | $SED "$delay_single_quote_subst"`'
-postinstall_cmds='`$ECHO "$postinstall_cmds" | $SED "$delay_single_quote_subst"`'
-postuninstall_cmds='`$ECHO "$postuninstall_cmds" | $SED "$delay_single_quote_subst"`'
-finish_cmds='`$ECHO "$finish_cmds" | $SED "$delay_single_quote_subst"`'
-finish_eval='`$ECHO "$finish_eval" | $SED "$delay_single_quote_subst"`'
-hardcode_into_libs='`$ECHO "$hardcode_into_libs" | $SED "$delay_single_quote_subst"`'
-sys_lib_search_path_spec='`$ECHO "$sys_lib_search_path_spec" | $SED "$delay_single_quote_subst"`'
-sys_lib_dlsearch_path_spec='`$ECHO "$sys_lib_dlsearch_path_spec" | $SED "$delay_single_quote_subst"`'
-hardcode_action='`$ECHO "$hardcode_action" | $SED "$delay_single_quote_subst"`'
-enable_dlopen='`$ECHO "$enable_dlopen" | $SED "$delay_single_quote_subst"`'
-enable_dlopen_self='`$ECHO "$enable_dlopen_self" | $SED "$delay_single_quote_subst"`'
-enable_dlopen_self_static='`$ECHO "$enable_dlopen_self_static" | $SED "$delay_single_quote_subst"`'
-old_striplib='`$ECHO "$old_striplib" | $SED "$delay_single_quote_subst"`'
-striplib='`$ECHO "$striplib" | $SED "$delay_single_quote_subst"`'
-
-LTCC='$LTCC'
-LTCFLAGS='$LTCFLAGS'
-compiler='$compiler_DEFAULT'
-
-# A function that is used when there is no print builtin or printf.
-func_fallback_echo ()
-{
- eval 'cat <<_LTECHO_EOF
-\$1
-_LTECHO_EOF'
-}
-
-# Quote evaled strings.
-for var in SHELL \
-ECHO \
-SED \
-GREP \
-EGREP \
-FGREP \
-LD \
-NM \
-LN_S \
-lt_SP2NL \
-lt_NL2SP \
-reload_flag \
-OBJDUMP \
-deplibs_check_method \
-file_magic_cmd \
-AR \
-AR_FLAGS \
-STRIP \
-RANLIB \
-CC \
-CFLAGS \
-compiler \
-lt_cv_sys_global_symbol_pipe \
-lt_cv_sys_global_symbol_to_cdecl \
-lt_cv_sys_global_symbol_to_c_name_address \
-lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \
-lt_prog_compiler_no_builtin_flag \
-lt_prog_compiler_wl \
-lt_prog_compiler_pic \
-lt_prog_compiler_static \
-lt_cv_prog_compiler_c_o \
-need_locks \
-DSYMUTIL \
-NMEDIT \
-LIPO \
-OTOOL \
-OTOOL64 \
-shrext_cmds \
-export_dynamic_flag_spec \
-whole_archive_flag_spec \
-compiler_needs_object \
-with_gnu_ld \
-allow_undefined_flag \
-no_undefined_flag \
-hardcode_libdir_flag_spec \
-hardcode_libdir_flag_spec_ld \
-hardcode_libdir_separator \
-fix_srcfile_path \
-exclude_expsyms \
-include_expsyms \
-file_list_spec \
-variables_saved_for_relink \
-libname_spec \
-library_names_spec \
-soname_spec \
-install_override_mode \
-finish_eval \
-old_striplib \
-striplib; do
- case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
- *[\\\\\\\`\\"\\\$]*)
- eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\""
- ;;
- *)
- eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
- ;;
- esac
-done
-
-# Double-quote double-evaled strings.
-for var in reload_cmds \
-old_postinstall_cmds \
-old_postuninstall_cmds \
-old_archive_cmds \
-extract_expsyms_cmds \
-old_archive_from_new_cmds \
-old_archive_from_expsyms_cmds \
-archive_cmds \
-archive_expsym_cmds \
-module_cmds \
-module_expsym_cmds \
-export_symbols_cmds \
-prelink_cmds \
-postinstall_cmds \
-postuninstall_cmds \
-finish_cmds \
-sys_lib_search_path_spec \
-sys_lib_dlsearch_path_spec; do
- case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
- *[\\\\\\\`\\"\\\$]*)
- eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\""
- ;;
- *)
- eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
- ;;
- esac
-done
-
-ac_aux_dir='$ac_aux_dir'
-xsi_shell='$xsi_shell'
-lt_shell_append='$lt_shell_append'
-
-# See if we are running on zsh, and set the options which allow our
-# commands through without removal of \ escapes INIT.
-if test -n "\${ZSH_VERSION+set}" ; then
- setopt NO_GLOB_SUBST
-fi
-
-
- PACKAGE='$PACKAGE'
- VERSION='$VERSION'
- TIMESTAMP='$TIMESTAMP'
- RM='$RM'
- ofile='$ofile'
-
-
-
-# Capture the value of obsolete ALL_LINGUAS because we need it to compute
- # POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES, CATALOGS. But hide it
- # from automake.
- eval 'OBSOLETE_ALL_LINGUAS''="$ALL_LINGUAS"'
- # Capture the value of LINGUAS because we need it to compute CATALOGS.
- LINGUAS="${LINGUAS-%UNSET%}"
-
-# Capture the value of obsolete ALL_LINGUAS because we need it to compute
- # POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES, CATALOGS. But hide it
- # from automake.
- eval 'OBSOLETE_ALL_LINGUAS''="$ALL_LINGUAS"'
- # Capture the value of LINGUAS because we need it to compute CATALOGS.
- LINGUAS="${LINGUAS-%UNSET%}"
-
-
-_ACEOF
-
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-
-# Handling of arguments.
-for ac_config_target in $ac_config_targets
-do
- case $ac_config_target in
- "gconfig.h") CONFIG_HEADERS="$CONFIG_HEADERS gconfig.h:gconfig.in" ;;
- "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
- "libtool") CONFIG_COMMANDS="$CONFIG_COMMANDS libtool" ;;
- "default-1") CONFIG_COMMANDS="$CONFIG_COMMANDS default-1" ;;
- "default-2") CONFIG_COMMANDS="$CONFIG_COMMANDS default-2" ;;
- "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
- "po/Makefile.in") CONFIG_FILES="$CONFIG_FILES po/Makefile.in:po/Make-in" ;;
-
- *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
- esac
-done
-
-
-# If the user did not use the arguments to specify the items to instantiate,
-# then the envvar interface is used. Set only those that are not.
-# We use the long form for the default assignment because of an extremely
-# bizarre bug on SunOS 4.1.3.
-if $ac_need_defaults; then
- test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
- test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
- test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
-fi
-
-# Have a temporary directory for convenience. Make it in the build tree
-# simply because there is no reason against having it here, and in addition,
-# creating and moving files from /tmp can sometimes cause problems.
-# Hook for its removal unless debugging.
-# Note that there is a small window in which the directory will not be cleaned:
-# after its creation but before its name has been assigned to `$tmp'.
-$debug ||
-{
- tmp= ac_tmp=
- trap 'exit_status=$?
- : "${ac_tmp:=$tmp}"
- { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
-' 0
- trap 'as_fn_exit 1' 1 2 13 15
-}
-# Create a (secure) tmp directory for tmp files.
-
-{
- tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
- test -d "$tmp"
-} ||
-{
- tmp=./conf$$-$RANDOM
- (umask 077 && mkdir "$tmp")
-} || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
-ac_tmp=$tmp
-
-# Set up the scripts for CONFIG_FILES section.
-# No need to generate them if there are no CONFIG_FILES.
-# This happens for instance with `./config.status config.h'.
-if test -n "$CONFIG_FILES"; then
-
-
-ac_cr=`echo X | tr X '\015'`
-# On cygwin, bash can eat \r inside `` if the user requested igncr.
-# But we know of no other shell where ac_cr would be empty at this
-# point, so we can use a bashism as a fallback.
-if test "x$ac_cr" = x; then
- eval ac_cr=\$\'\\r\'
-fi
-ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
-if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
- ac_cs_awk_cr='\\r'
-else
- ac_cs_awk_cr=$ac_cr
-fi
-
-echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
-_ACEOF
-
-
-{
- echo "cat >conf$$subs.awk <<_ACEOF" &&
- echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
- echo "_ACEOF"
-} >conf$$subs.sh ||
- as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
-ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
-ac_delim='%!_!# '
-for ac_last_try in false false false false false :; do
- . ./conf$$subs.sh ||
- as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
-
- ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
- if test $ac_delim_n = $ac_delim_num; then
- break
- elif $ac_last_try; then
- as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
- else
- ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
- fi
-done
-rm -f conf$$subs.sh
-
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
-_ACEOF
-sed -n '
-h
-s/^/S["/; s/!.*/"]=/
-p
-g
-s/^[^!]*!//
-:repl
-t repl
-s/'"$ac_delim"'$//
-t delim
-:nl
-h
-s/\(.\{148\}\)..*/\1/
-t more1
-s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
-p
-n
-b repl
-:more1
-s/["\\]/\\&/g; s/^/"/; s/$/"\\/
-p
-g
-s/.\{148\}//
-t nl
-:delim
-h
-s/\(.\{148\}\)..*/\1/
-t more2
-s/["\\]/\\&/g; s/^/"/; s/$/"/
-p
-b
-:more2
-s/["\\]/\\&/g; s/^/"/; s/$/"\\/
-p
-g
-s/.\{148\}//
-t delim
-' <conf$$subs.awk | sed '
-/^[^""]/{
- N
- s/\n//
-}
-' >>$CONFIG_STATUS || ac_write_fail=1
-rm -f conf$$subs.awk
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-_ACAWK
-cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
- for (key in S) S_is_set[key] = 1
- FS = ""
-
-}
-{
- line = $ 0
- nfields = split(line, field, "@")
- substed = 0
- len = length(field[1])
- for (i = 2; i < nfields; i++) {
- key = field[i]
- keylen = length(key)
- if (S_is_set[key]) {
- value = S[key]
- line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
- len += length(value) + length(field[++i])
- substed = 1
- } else
- len += 1 + keylen
- }
-
- print line
-}
-
-_ACAWK
-_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
- sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
-else
- cat
-fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
- || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
-_ACEOF
-
-# VPATH may cause trouble with some makes, so we remove sole $(srcdir),
-# ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
-# trailing colons and then remove the whole line if VPATH becomes empty
-# (actually we leave an empty line to preserve line numbers).
-if test "x$srcdir" = x.; then
- ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{
-h
-s///
-s/^/:/
-s/[ ]*$/:/
-s/:\$(srcdir):/:/g
-s/:\${srcdir}:/:/g
-s/:@srcdir@:/:/g
-s/^:*//
-s/:*$//
-x
-s/\(=[ ]*\).*/\1/
-G
-s/\n//
-s/^[^=]*=[ ]*$//
-}'
-fi
-
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-fi # test -n "$CONFIG_FILES"
-
-# Set up the scripts for CONFIG_HEADERS section.
-# No need to generate them if there are no CONFIG_HEADERS.
-# This happens for instance with `./config.status Makefile'.
-if test -n "$CONFIG_HEADERS"; then
-cat >"$ac_tmp/defines.awk" <<\_ACAWK ||
-BEGIN {
-_ACEOF
-
-# Transform confdefs.h into an awk script `defines.awk', embedded as
-# here-document in config.status, that substitutes the proper values into
-# config.h.in to produce config.h.
-
-# Create a delimiter string that does not exist in confdefs.h, to ease
-# handling of long lines.
-ac_delim='%!_!# '
-for ac_last_try in false false :; do
- ac_tt=`sed -n "/$ac_delim/p" confdefs.h`
- if test -z "$ac_tt"; then
- break
- elif $ac_last_try; then
- as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
- else
- ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
- fi
-done
-
-# For the awk script, D is an array of macro values keyed by name,
-# likewise P contains macro parameters if any. Preserve backslash
-# newline sequences.
-
-ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
-sed -n '
-s/.\{148\}/&'"$ac_delim"'/g
-t rset
-:rset
-s/^[ ]*#[ ]*define[ ][ ]*/ /
-t def
-d
-:def
-s/\\$//
-t bsnl
-s/["\\]/\\&/g
-s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
-D["\1"]=" \3"/p
-s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
-d
-:bsnl
-s/["\\]/\\&/g
-s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
-D["\1"]=" \3\\\\\\n"\\/p
-t cont
-s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
-t cont
-d
-:cont
-n
-s/.\{148\}/&'"$ac_delim"'/g
-t clear
-:clear
-s/\\$//
-t bsnlc
-s/["\\]/\\&/g; s/^/"/; s/$/"/p
-d
-:bsnlc
-s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
-b cont
-' <confdefs.h | sed '
-s/'"$ac_delim"'/"\\\
-"/g' >>$CONFIG_STATUS || ac_write_fail=1
-
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
- for (key in D) D_is_set[key] = 1
- FS = ""
-}
-/^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
- line = \$ 0
- split(line, arg, " ")
- if (arg[1] == "#") {
- defundef = arg[2]
- mac1 = arg[3]
- } else {
- defundef = substr(arg[1], 2)
- mac1 = arg[2]
- }
- split(mac1, mac2, "(") #)
- macro = mac2[1]
- prefix = substr(line, 1, index(line, defundef) - 1)
- if (D_is_set[macro]) {
- # Preserve the white space surrounding the "#".
- print prefix "define", macro P[macro] D[macro]
- next
- } else {
- # Replace #undef with comments. This is necessary, for example,
- # in the case of _POSIX_SOURCE, which is predefined and required
- # on some systems where configure will not decide to define it.
- if (defundef == "undef") {
- print "/*", prefix defundef, macro, "*/"
- next
- }
- }
-}
-{ print }
-_ACAWK
-_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
- as_fn_error $? "could not setup config headers machinery" "$LINENO" 5
-fi # test -n "$CONFIG_HEADERS"
-
-
-eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS"
-shift
-for ac_tag
-do
- case $ac_tag in
- :[FHLC]) ac_mode=$ac_tag; continue;;
- esac
- case $ac_mode$ac_tag in
- :[FHL]*:*);;
- :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
- :[FH]-) ac_tag=-:-;;
- :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
- esac
- ac_save_IFS=$IFS
- IFS=:
- set x $ac_tag
- IFS=$ac_save_IFS
- shift
- ac_file=$1
- shift
-
- case $ac_mode in
- :L) ac_source=$1;;
- :[FH])
- ac_file_inputs=
- for ac_f
- do
- case $ac_f in
- -) ac_f="$ac_tmp/stdin";;
- *) # Look for the file first in the build tree, then in the source tree
- # (if the path is not absolute). The absolute path cannot be DOS-style,
- # because $ac_f cannot contain `:'.
- test -f "$ac_f" ||
- case $ac_f in
- [\\/$]*) false;;
- *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
- esac ||
- as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
- esac
- case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
- as_fn_append ac_file_inputs " '$ac_f'"
- done
-
- # Let's still pretend it is `configure' which instantiates (i.e., don't
- # use $as_me), people would be surprised to read:
- # /* config.h. Generated by config.status. */
- configure_input='Generated from '`
- $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
- `' by configure.'
- if test x"$ac_file" != x-; then
- configure_input="$ac_file. $configure_input"
- { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
-$as_echo "$as_me: creating $ac_file" >&6;}
- fi
- # Neutralize special characters interpreted by sed in replacement strings.
- case $configure_input in #(
- *\&* | *\|* | *\\* )
- ac_sed_conf_input=`$as_echo "$configure_input" |
- sed 's/[\\\\&|]/\\\\&/g'`;; #(
- *) ac_sed_conf_input=$configure_input;;
- esac
-
- case $ac_tag in
- *:-:* | *:-) cat >"$ac_tmp/stdin" \
- || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
- esac
- ;;
- esac
-
- ac_dir=`$as_dirname -- "$ac_file" ||
-$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$ac_file" : 'X\(//\)[^/]' \| \
- X"$ac_file" : 'X\(//\)$' \| \
- X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$ac_file" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
- as_dir="$ac_dir"; as_fn_mkdir_p
- ac_builddir=.
-
-case "$ac_dir" in
-.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
-*)
- ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
- # A ".." for each directory in $ac_dir_suffix.
- ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
- case $ac_top_builddir_sub in
- "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
- *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
- esac ;;
-esac
-ac_abs_top_builddir=$ac_pwd
-ac_abs_builddir=$ac_pwd$ac_dir_suffix
-# for backward compatibility:
-ac_top_builddir=$ac_top_build_prefix
-
-case $srcdir in
- .) # We are building in place.
- ac_srcdir=.
- ac_top_srcdir=$ac_top_builddir_sub
- ac_abs_top_srcdir=$ac_pwd ;;
- [\\/]* | ?:[\\/]* ) # Absolute name.
- ac_srcdir=$srcdir$ac_dir_suffix;
- ac_top_srcdir=$srcdir
- ac_abs_top_srcdir=$srcdir ;;
- *) # Relative name.
- ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
- ac_top_srcdir=$ac_top_build_prefix$srcdir
- ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
-esac
-ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
-
-
- case $ac_mode in
- :F)
- #
- # CONFIG_FILE
- #
-
- case $INSTALL in
- [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
- *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
- esac
- ac_MKDIR_P=$MKDIR_P
- case $MKDIR_P in
- [\\/$]* | ?:[\\/]* ) ;;
- */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
- esac
-_ACEOF
-
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-# If the template does not know about datarootdir, expand it.
-# FIXME: This hack should be removed a few years after 2.60.
-ac_datarootdir_hack=; ac_datarootdir_seen=
-ac_sed_dataroot='
-/datarootdir/ {
- p
- q
-}
-/@datadir@/p
-/@docdir@/p
-/@infodir@/p
-/@localedir@/p
-/@mandir@/p'
-case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
-*datarootdir*) ac_datarootdir_seen=yes;;
-*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
-$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
-_ACEOF
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
- ac_datarootdir_hack='
- s&@datadir@&$datadir&g
- s&@docdir@&$docdir&g
- s&@infodir@&$infodir&g
- s&@localedir@&$localedir&g
- s&@mandir@&$mandir&g
- s&\\\${datarootdir}&$datarootdir&g' ;;
-esac
-_ACEOF
-
-# Neutralize VPATH when `$srcdir' = `.'.
-# Shell code in configure.ac might set extrasub.
-# FIXME: do we really want to maintain this feature?
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-ac_sed_extra="$ac_vpsub
-$extrasub
-_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-:t
-/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
-s|@configure_input@|$ac_sed_conf_input|;t t
-s&@top_builddir@&$ac_top_builddir_sub&;t t
-s&@top_build_prefix@&$ac_top_build_prefix&;t t
-s&@srcdir@&$ac_srcdir&;t t
-s&@abs_srcdir@&$ac_abs_srcdir&;t t
-s&@top_srcdir@&$ac_top_srcdir&;t t
-s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
-s&@builddir@&$ac_builddir&;t t
-s&@abs_builddir@&$ac_abs_builddir&;t t
-s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
-s&@INSTALL@&$ac_INSTALL&;t t
-s&@MKDIR_P@&$ac_MKDIR_P&;t t
-$ac_datarootdir_hack
-"
-eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \
- >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
-
-test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
- { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
- { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \
- "$ac_tmp/out"`; test -z "$ac_out"; } &&
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
-which seems to be undefined. Please make sure it is defined" >&5
-$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
-which seems to be undefined. Please make sure it is defined" >&2;}
-
- rm -f "$ac_tmp/stdin"
- case $ac_file in
- -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
- *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
- esac \
- || as_fn_error $? "could not create $ac_file" "$LINENO" 5
- ;;
- :H)
- #
- # CONFIG_HEADER
- #
- if test x"$ac_file" != x-; then
- {
- $as_echo "/* $configure_input */" \
- && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs"
- } >"$ac_tmp/config.h" \
- || as_fn_error $? "could not create $ac_file" "$LINENO" 5
- if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
-$as_echo "$as_me: $ac_file is unchanged" >&6;}
- else
- rm -f "$ac_file"
- mv "$ac_tmp/config.h" "$ac_file" \
- || as_fn_error $? "could not create $ac_file" "$LINENO" 5
- fi
- else
- $as_echo "/* $configure_input */" \
- && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \
- || as_fn_error $? "could not create -" "$LINENO" 5
- fi
-# Compute "$ac_file"'s index in $config_headers.
-_am_arg="$ac_file"
-_am_stamp_count=1
-for _am_header in $config_headers :; do
- case $_am_header in
- $_am_arg | $_am_arg:* )
- break ;;
- * )
- _am_stamp_count=`expr $_am_stamp_count + 1` ;;
- esac
-done
-echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" ||
-$as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$_am_arg" : 'X\(//\)[^/]' \| \
- X"$_am_arg" : 'X\(//\)$' \| \
- X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$_am_arg" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`/stamp-h$_am_stamp_count
- ;;
-
- :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
-$as_echo "$as_me: executing $ac_file commands" >&6;}
- ;;
- esac
-
-
- case $ac_file$ac_mode in
- "depfiles":C) test x"$AMDEP_TRUE" != x"" || {
- # Older Autoconf quotes --file arguments for eval, but not when files
- # are listed without --file. Let's play safe and only enable the eval
- # if we detect the quoting.
- case $CONFIG_FILES in
- *\'*) eval set x "$CONFIG_FILES" ;;
- *) set x $CONFIG_FILES ;;
- esac
- shift
- for mf
- do
- # Strip MF so we end up with the name of the file.
- mf=`echo "$mf" | sed -e 's/:.*$//'`
- # Check whether this is an Automake generated Makefile or not.
- # We used to match only the files named 'Makefile.in', but
- # some people rename them; so instead we look at the file content.
- # Grep'ing the first line is not enough: some people post-process
- # each Makefile.in and add a new line on top of each file to say so.
- # Grep'ing the whole file is not good either: AIX grep has a line
- # limit of 2048, but all sed's we know have understand at least 4000.
- if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
- dirpart=`$as_dirname -- "$mf" ||
-$as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$mf" : 'X\(//\)[^/]' \| \
- X"$mf" : 'X\(//\)$' \| \
- X"$mf" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$mf" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
- else
- continue
- fi
- # Extract the definition of DEPDIR, am__include, and am__quote
- # from the Makefile without running 'make'.
- DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
- test -z "$DEPDIR" && continue
- am__include=`sed -n 's/^am__include = //p' < "$mf"`
- test -z "$am__include" && continue
- am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
- # Find all dependency output files, they are included files with
- # $(DEPDIR) in their names. We invoke sed twice because it is the
- # simplest approach to changing $(DEPDIR) to its actual value in the
- # expansion.
- for file in `sed -n "
- s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
- sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g'`; do
- # Make sure the directory exists.
- test -f "$dirpart/$file" && continue
- fdir=`$as_dirname -- "$file" ||
-$as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$file" : 'X\(//\)[^/]' \| \
- X"$file" : 'X\(//\)$' \| \
- X"$file" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$file" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
- as_dir=$dirpart/$fdir; as_fn_mkdir_p
- # echo "creating $dirpart/$file"
- echo '# dummy' > "$dirpart/$file"
- done
- done
-}
- ;;
- "libtool":C)
-
- # See if we are running on zsh, and set the options which allow our
- # commands through without removal of \ escapes.
- if test -n "${ZSH_VERSION+set}" ; then
- setopt NO_GLOB_SUBST
- fi
-
- cfgfile="${ofile}T"
- trap "$RM \"$cfgfile\"; exit 1" 1 2 15
- $RM "$cfgfile"
-
- cat <<_LT_EOF >> "$cfgfile"
-#! $SHELL
-
-# `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
-# Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION
-# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
-# NOTE: Changes made to this file will be lost: look at ltmain.sh.
-#
-# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
-# 2006, 2007, 2008, 2009 Free Software Foundation, Inc.
-# Written by Gordon Matzigkeit, 1996
-#
-# This file is part of GNU Libtool.
-#
-# GNU Libtool is free software; you can redistribute it and/or
-# modify it under the terms of the GNU General Public License as
-# published by the Free Software Foundation; either version 2 of
-# the License, or (at your option) any later version.
-#
-# As a special exception to the GNU General Public License,
-# if you distribute this file as part of a program or library that
-# is built using GNU Libtool, you may include this file under the
-# same distribution terms that you use for the rest of that program.
-#
-# GNU Libtool is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with GNU Libtool; see the file COPYING. If not, a copy
-# can be downloaded from http://www.gnu.org/licenses/gpl.html, or
-# obtained by writing to the Free Software Foundation, Inc.,
-# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
-
-
-# The names of the tagged configurations supported by this script.
-available_tags=""
-
-# ### BEGIN LIBTOOL CONFIG
-
-# Which release of libtool.m4 was used?
-macro_version=$macro_version
-macro_revision=$macro_revision
-
-# Whether or not to build shared libraries.
-build_libtool_libs=$enable_shared
-
-# Whether or not to build static libraries.
-build_old_libs=$enable_static
-
-# What type of objects to build.
-pic_mode=$pic_mode
-
-# Whether or not to optimize for fast installation.
-fast_install=$enable_fast_install
-
-# Shell to use when invoking shell scripts.
-SHELL=$lt_SHELL
-
-# An echo program that protects backslashes.
-ECHO=$lt_ECHO
-
-# The host system.
-host_alias=$host_alias
-host=$host
-host_os=$host_os
-
-# The build system.
-build_alias=$build_alias
-build=$build
-build_os=$build_os
-
-# A sed program that does not truncate output.
-SED=$lt_SED
-
-# Sed that helps us avoid accidentally triggering echo(1) options like -n.
-Xsed="\$SED -e 1s/^X//"
-
-# A grep program that handles long lines.
-GREP=$lt_GREP
-
-# An ERE matcher.
-EGREP=$lt_EGREP
-
-# A literal string matcher.
-FGREP=$lt_FGREP
-
-# A BSD- or MS-compatible name lister.
-NM=$lt_NM
-
-# Whether we need soft or hard links.
-LN_S=$lt_LN_S
-
-# What is the maximum length of a command?
-max_cmd_len=$max_cmd_len
-
-# Object file suffix (normally "o").
-objext=$ac_objext
-
-# Executable file suffix (normally "").
-exeext=$exeext
-
-# whether the shell understands "unset".
-lt_unset=$lt_unset
-
-# turn spaces into newlines.
-SP2NL=$lt_lt_SP2NL
-
-# turn newlines into spaces.
-NL2SP=$lt_lt_NL2SP
-
-# An object symbol dumper.
-OBJDUMP=$lt_OBJDUMP
-
-# Method to check whether dependent libraries are shared objects.
-deplibs_check_method=$lt_deplibs_check_method
-
-# Command to use when deplibs_check_method == "file_magic".
-file_magic_cmd=$lt_file_magic_cmd
-
-# The archiver.
-AR=$lt_AR
-AR_FLAGS=$lt_AR_FLAGS
-
-# A symbol stripping program.
-STRIP=$lt_STRIP
-
-# Commands used to install an old-style archive.
-RANLIB=$lt_RANLIB
-old_postinstall_cmds=$lt_old_postinstall_cmds
-old_postuninstall_cmds=$lt_old_postuninstall_cmds
-
-# Whether to use a lock for old archive extraction.
-lock_old_archive_extraction=$lock_old_archive_extraction
-
-# A C compiler.
-LTCC=$lt_CC
-
-# LTCC compiler flags.
-LTCFLAGS=$lt_CFLAGS
-
-# Take the output of nm and produce a listing of raw symbols and C names.
-global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe
-
-# Transform the output of nm in a proper C declaration.
-global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl
-
-# Transform the output of nm in a C name address pair.
-global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
-
-# Transform the output of nm in a C name address pair when lib prefix is needed.
-global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix
-
-# The name of the directory that contains temporary libtool files.
-objdir=$objdir
-
-# Used to examine libraries when file_magic_cmd begins with "file".
-MAGIC_CMD=$MAGIC_CMD
-
-# Must we lock files when doing compilation?
-need_locks=$lt_need_locks
-
-# Tool to manipulate archived DWARF debug symbol files on Mac OS X.
-DSYMUTIL=$lt_DSYMUTIL
-
-# Tool to change global to local symbols on Mac OS X.
-NMEDIT=$lt_NMEDIT
-
-# Tool to manipulate fat objects and archives on Mac OS X.
-LIPO=$lt_LIPO
-
-# ldd/readelf like tool for Mach-O binaries on Mac OS X.
-OTOOL=$lt_OTOOL
-
-# ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4.
-OTOOL64=$lt_OTOOL64
-
-# Old archive suffix (normally "a").
-libext=$libext
-
-# Shared library suffix (normally ".so").
-shrext_cmds=$lt_shrext_cmds
-
-# The commands to extract the exported symbol list from a shared archive.
-extract_expsyms_cmds=$lt_extract_expsyms_cmds
-
-# Variables whose values should be saved in libtool wrapper scripts and
-# restored at link time.
-variables_saved_for_relink=$lt_variables_saved_for_relink
-
-# Do we need the "lib" prefix for modules?
-need_lib_prefix=$need_lib_prefix
-
-# Do we need a version for libraries?
-need_version=$need_version
-
-# Library versioning type.
-version_type=$version_type
-
-# Shared library runtime path variable.
-runpath_var=$runpath_var
-
-# Shared library path variable.
-shlibpath_var=$shlibpath_var
-
-# Is shlibpath searched before the hard-coded library search path?
-shlibpath_overrides_runpath=$shlibpath_overrides_runpath
-
-# Format of library name prefix.
-libname_spec=$lt_libname_spec
-
-# List of archive names. First name is the real one, the rest are links.
-# The last name is the one that the linker finds with -lNAME
-library_names_spec=$lt_library_names_spec
-
-# The coded name of the library, if different from the real name.
-soname_spec=$lt_soname_spec
-
-# Permission mode override for installation of shared libraries.
-install_override_mode=$lt_install_override_mode
-
-# Command to use after installation of a shared archive.
-postinstall_cmds=$lt_postinstall_cmds
-
-# Command to use after uninstallation of a shared archive.
-postuninstall_cmds=$lt_postuninstall_cmds
-
-# Commands used to finish a libtool library installation in a directory.
-finish_cmds=$lt_finish_cmds
-
-# As "finish_cmds", except a single script fragment to be evaled but
-# not shown.
-finish_eval=$lt_finish_eval
-
-# Whether we should hardcode library paths into libraries.
-hardcode_into_libs=$hardcode_into_libs
-
-# Compile-time system search path for libraries.
-sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
-
-# Run-time system search path for libraries.
-sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
-
-# Whether dlopen is supported.
-dlopen_support=$enable_dlopen
-
-# Whether dlopen of programs is supported.
-dlopen_self=$enable_dlopen_self
-
-# Whether dlopen of statically linked programs is supported.
-dlopen_self_static=$enable_dlopen_self_static
-
-# Commands to strip libraries.
-old_striplib=$lt_old_striplib
-striplib=$lt_striplib
-
-
-# The linker used to build libraries.
-LD=$lt_LD
-
-# How to create reloadable object files.
-reload_flag=$lt_reload_flag
-reload_cmds=$lt_reload_cmds
-
-# Commands used to build an old-style archive.
-old_archive_cmds=$lt_old_archive_cmds
-
-# A language specific compiler.
-CC=$lt_compiler
-
-# Is the compiler the GNU compiler?
-with_gcc=$GCC
-
-# Compiler flag to turn off builtin functions.
-no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag
-
-# How to pass a linker flag through the compiler.
-wl=$lt_lt_prog_compiler_wl
-
-# Additional compiler flags for building library objects.
-pic_flag=$lt_lt_prog_compiler_pic
-
-# Compiler flag to prevent dynamic linking.
-link_static_flag=$lt_lt_prog_compiler_static
-
-# Does compiler simultaneously support -c and -o options?
-compiler_c_o=$lt_lt_cv_prog_compiler_c_o
-
-# Whether or not to add -lc for building shared libraries.
-build_libtool_need_lc=$archive_cmds_need_lc
-
-# Whether or not to disallow shared libs when runtime libs are static.
-allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes
-
-# Compiler flag to allow reflexive dlopens.
-export_dynamic_flag_spec=$lt_export_dynamic_flag_spec
-
-# Compiler flag to generate shared objects directly from archives.
-whole_archive_flag_spec=$lt_whole_archive_flag_spec
-
-# Whether the compiler copes with passing no objects directly.
-compiler_needs_object=$lt_compiler_needs_object
-
-# Create an old-style archive from a shared archive.
-old_archive_from_new_cmds=$lt_old_archive_from_new_cmds
-
-# Create a temporary old-style archive to link instead of a shared archive.
-old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds
-
-# Commands used to build a shared archive.
-archive_cmds=$lt_archive_cmds
-archive_expsym_cmds=$lt_archive_expsym_cmds
-
-# Commands used to build a loadable module if different from building
-# a shared archive.
-module_cmds=$lt_module_cmds
-module_expsym_cmds=$lt_module_expsym_cmds
-
-# Whether we are building with GNU ld or not.
-with_gnu_ld=$lt_with_gnu_ld
-
-# Flag that allows shared libraries with undefined symbols to be built.
-allow_undefined_flag=$lt_allow_undefined_flag
-
-# Flag that enforces no undefined symbols.
-no_undefined_flag=$lt_no_undefined_flag
-
-# Flag to hardcode \$libdir into a binary during linking.
-# This must work even if \$libdir does not exist
-hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec
-
-# If ld is used when linking, flag to hardcode \$libdir into a binary
-# during linking. This must work even if \$libdir does not exist.
-hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld
-
-# Whether we need a single "-rpath" flag with a separated argument.
-hardcode_libdir_separator=$lt_hardcode_libdir_separator
-
-# Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
-# DIR into the resulting binary.
-hardcode_direct=$hardcode_direct
-
-# Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
-# DIR into the resulting binary and the resulting library dependency is
-# "absolute",i.e impossible to change by setting \${shlibpath_var} if the
-# library is relocated.
-hardcode_direct_absolute=$hardcode_direct_absolute
-
-# Set to "yes" if using the -LDIR flag during linking hardcodes DIR
-# into the resulting binary.
-hardcode_minus_L=$hardcode_minus_L
-
-# Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR
-# into the resulting binary.
-hardcode_shlibpath_var=$hardcode_shlibpath_var
-
-# Set to "yes" if building a shared library automatically hardcodes DIR
-# into the library and all subsequent libraries and executables linked
-# against it.
-hardcode_automatic=$hardcode_automatic
-
-# Set to yes if linker adds runtime paths of dependent libraries
-# to runtime path list.
-inherit_rpath=$inherit_rpath
-
-# Whether libtool must link a program against all its dependency libraries.
-link_all_deplibs=$link_all_deplibs
-
-# Fix the shell variable \$srcfile for the compiler.
-fix_srcfile_path=$lt_fix_srcfile_path
-
-# Set to "yes" if exported symbols are required.
-always_export_symbols=$always_export_symbols
-
-# The commands to list exported symbols.
-export_symbols_cmds=$lt_export_symbols_cmds
-
-# Symbols that should not be listed in the preloaded symbols.
-exclude_expsyms=$lt_exclude_expsyms
-
-# Symbols that must always be exported.
-include_expsyms=$lt_include_expsyms
-
-# Commands necessary for linking programs (against libraries) with templates.
-prelink_cmds=$lt_prelink_cmds
-
-# Specify filename containing input files.
-file_list_spec=$lt_file_list_spec
-
-# How to hardcode a shared library path into an executable.
-hardcode_action=$hardcode_action
-
-# ### END LIBTOOL CONFIG
-
-_LT_EOF
-
- case $host_os in
- aix3*)
- cat <<\_LT_EOF >> "$cfgfile"
-# AIX sometimes has problems with the GCC collect2 program. For some
-# reason, if we set the COLLECT_NAMES environment variable, the problems
-# vanish in a puff of smoke.
-if test "X${COLLECT_NAMES+set}" != Xset; then
- COLLECT_NAMES=
- export COLLECT_NAMES
-fi
-_LT_EOF
- ;;
- esac
-
-
-ltmain="$ac_aux_dir/ltmain.sh"
-
-
- # We use sed instead of cat because bash on DJGPP gets confused if
- # if finds mixed CR/LF and LF-only lines. Since sed operates in
- # text mode, it properly converts lines to CR/LF. This bash problem
- # is reportedly fixed, but why not run on old versions too?
- sed '/^# Generated shell functions inserted here/q' "$ltmain" >> "$cfgfile" \
- || (rm -f "$cfgfile"; exit 1)
-
- case $xsi_shell in
- yes)
- cat << \_LT_EOF >> "$cfgfile"
-
-# func_dirname file append nondir_replacement
-# Compute the dirname of FILE. If nonempty, add APPEND to the result,
-# otherwise set result to NONDIR_REPLACEMENT.
-func_dirname ()
-{
- case ${1} in
- */*) func_dirname_result="${1%/*}${2}" ;;
- * ) func_dirname_result="${3}" ;;
- esac
-}
-
-# func_basename file
-func_basename ()
-{
- func_basename_result="${1##*/}"
-}
-
-# func_dirname_and_basename file append nondir_replacement
-# perform func_basename and func_dirname in a single function
-# call:
-# dirname: Compute the dirname of FILE. If nonempty,
-# add APPEND to the result, otherwise set result
-# to NONDIR_REPLACEMENT.
-# value returned in "$func_dirname_result"
-# basename: Compute filename of FILE.
-# value retuned in "$func_basename_result"
-# Implementation must be kept synchronized with func_dirname
-# and func_basename. For efficiency, we do not delegate to
-# those functions but instead duplicate the functionality here.
-func_dirname_and_basename ()
-{
- case ${1} in
- */*) func_dirname_result="${1%/*}${2}" ;;
- * ) func_dirname_result="${3}" ;;
- esac
- func_basename_result="${1##*/}"
-}
-
-# func_stripname prefix suffix name
-# strip PREFIX and SUFFIX off of NAME.
-# PREFIX and SUFFIX must not contain globbing or regex special
-# characters, hashes, percent signs, but SUFFIX may contain a leading
-# dot (in which case that matches only a dot).
-func_stripname ()
-{
- # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are
- # positional parameters, so assign one to ordinary parameter first.
- func_stripname_result=${3}
- func_stripname_result=${func_stripname_result#"${1}"}
- func_stripname_result=${func_stripname_result%"${2}"}
-}
-
-# func_opt_split
-func_opt_split ()
-{
- func_opt_split_opt=${1%%=*}
- func_opt_split_arg=${1#*=}
-}
-
-# func_lo2o object
-func_lo2o ()
-{
- case ${1} in
- *.lo) func_lo2o_result=${1%.lo}.${objext} ;;
- *) func_lo2o_result=${1} ;;
- esac
-}
-
-# func_xform libobj-or-source
-func_xform ()
-{
- func_xform_result=${1%.*}.lo
-}
-
-# func_arith arithmetic-term...
-func_arith ()
-{
- func_arith_result=$(( $* ))
-}
-
-# func_len string
-# STRING may not start with a hyphen.
-func_len ()
-{
- func_len_result=${#1}
-}
-
-_LT_EOF
- ;;
- *) # Bourne compatible functions.
- cat << \_LT_EOF >> "$cfgfile"
-
-# func_dirname file append nondir_replacement
-# Compute the dirname of FILE. If nonempty, add APPEND to the result,
-# otherwise set result to NONDIR_REPLACEMENT.
-func_dirname ()
-{
- # Extract subdirectory from the argument.
- func_dirname_result=`$ECHO "${1}" | $SED "$dirname"`
- if test "X$func_dirname_result" = "X${1}"; then
- func_dirname_result="${3}"
- else
- func_dirname_result="$func_dirname_result${2}"
- fi
-}
-
-# func_basename file
-func_basename ()
-{
- func_basename_result=`$ECHO "${1}" | $SED "$basename"`
-}
-
-
-# func_stripname prefix suffix name
-# strip PREFIX and SUFFIX off of NAME.
-# PREFIX and SUFFIX must not contain globbing or regex special
-# characters, hashes, percent signs, but SUFFIX may contain a leading
-# dot (in which case that matches only a dot).
-# func_strip_suffix prefix name
-func_stripname ()
-{
- case ${2} in
- .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;;
- *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;;
- esac
-}
-
-# sed scripts:
-my_sed_long_opt='1s/^\(-[^=]*\)=.*/\1/;q'
-my_sed_long_arg='1s/^-[^=]*=//'
-
-# func_opt_split
-func_opt_split ()
-{
- func_opt_split_opt=`$ECHO "${1}" | $SED "$my_sed_long_opt"`
- func_opt_split_arg=`$ECHO "${1}" | $SED "$my_sed_long_arg"`
-}
-
-# func_lo2o object
-func_lo2o ()
-{
- func_lo2o_result=`$ECHO "${1}" | $SED "$lo2o"`
-}
-
-# func_xform libobj-or-source
-func_xform ()
-{
- func_xform_result=`$ECHO "${1}" | $SED 's/\.[^.]*$/.lo/'`
-}
-
-# func_arith arithmetic-term...
-func_arith ()
-{
- func_arith_result=`expr "$@"`
-}
-
-# func_len string
-# STRING may not start with a hyphen.
-func_len ()
-{
- func_len_result=`expr "$1" : ".*" 2>/dev/null || echo $max_cmd_len`
-}
-
-_LT_EOF
-esac
-
-case $lt_shell_append in
- yes)
- cat << \_LT_EOF >> "$cfgfile"
-
-# func_append var value
-# Append VALUE to the end of shell variable VAR.
-func_append ()
-{
- eval "$1+=\$2"
-}
-_LT_EOF
- ;;
- *)
- cat << \_LT_EOF >> "$cfgfile"
-
-# func_append var value
-# Append VALUE to the end of shell variable VAR.
-func_append ()
-{
- eval "$1=\$$1\$2"
-}
-
-_LT_EOF
- ;;
- esac
-
-
- sed -n '/^# Generated shell functions inserted here/,$p' "$ltmain" >> "$cfgfile" \
- || (rm -f "$cfgfile"; exit 1)
-
- mv -f "$cfgfile" "$ofile" ||
- (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
- chmod +x "$ofile"
-
- ;;
- "default-1":C)
- for ac_file in $CONFIG_FILES; do
- # Support "outfile[:infile[:infile...]]"
- case "$ac_file" in
- *:*) ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
- esac
- # PO directories have a Makefile.in generated from Makefile.in.in.
- case "$ac_file" in */Makefile.in)
- # Adjust a relative srcdir.
- ac_dir=`echo "$ac_file"|sed 's%/[^/][^/]*$%%'`
- ac_dir_suffix=/`echo "$ac_dir"|sed 's%^\./%%'`
- ac_dots=`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'`
- # In autoconf-2.13 it is called $ac_given_srcdir.
- # In autoconf-2.50 it is called $srcdir.
- test -n "$ac_given_srcdir" || ac_given_srcdir="$srcdir"
- case "$ac_given_srcdir" in
- .) top_srcdir=`echo $ac_dots|sed 's%/$%%'` ;;
- /*) top_srcdir="$ac_given_srcdir" ;;
- *) top_srcdir="$ac_dots$ac_given_srcdir" ;;
- esac
- if test -f "$ac_given_srcdir/$ac_dir/POTFILES.in"; then
- rm -f "$ac_dir/POTFILES"
- test -n "$as_me" && echo "$as_me: creating $ac_dir/POTFILES" || echo "creating $ac_dir/POTFILES"
- cat "$ac_given_srcdir/$ac_dir/POTFILES.in" | sed -e "/^#/d" -e "/^[ ]*\$/d" -e "s,.*, $top_srcdir/& \\\\," | sed -e "\$s/\(.*\) \\\\/\1/" > "$ac_dir/POTFILES"
- POMAKEFILEDEPS="POTFILES.in"
- # ALL_LINGUAS, POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES depend
- # on $ac_dir but don't depend on user-specified configuration
- # parameters.
- if test -f "$ac_given_srcdir/$ac_dir/LINGUAS"; then
- # The LINGUAS file contains the set of available languages.
- if test -n "$OBSOLETE_ALL_LINGUAS"; then
- test -n "$as_me" && echo "$as_me: setting ALL_LINGUAS in configure.ac is obsolete" || echo "setting ALL_LINGUAS in configure.ac is obsolete"
- fi
- ALL_LINGUAS_=`sed -e "/^#/d" "$ac_given_srcdir/$ac_dir/LINGUAS"`
- # Hide the ALL_LINGUAS assigment from automake.
- eval 'ALL_LINGUAS''=$ALL_LINGUAS_'
- POMAKEFILEDEPS="$POMAKEFILEDEPS LINGUAS"
- else
- # The set of available languages was given in configure.ac.
- eval 'ALL_LINGUAS''=$OBSOLETE_ALL_LINGUAS'
- fi
- case "$ac_given_srcdir" in
- .) srcdirpre= ;;
- *) srcdirpre='$(srcdir)/' ;;
- esac
- POFILES=
- GMOFILES=
- UPDATEPOFILES=
- DUMMYPOFILES=
- for lang in $ALL_LINGUAS; do
- POFILES="$POFILES $srcdirpre$lang.po"
- GMOFILES="$GMOFILES $srcdirpre$lang.gmo"
- UPDATEPOFILES="$UPDATEPOFILES $lang.po-update"
- DUMMYPOFILES="$DUMMYPOFILES $lang.nop"
- done
- # CATALOGS depends on both $ac_dir and the user's LINGUAS
- # environment variable.
- INST_LINGUAS=
- if test -n "$ALL_LINGUAS"; then
- for presentlang in $ALL_LINGUAS; do
- useit=no
- if test "%UNSET%" != "$LINGUAS"; then
- desiredlanguages="$LINGUAS"
- else
- desiredlanguages="$ALL_LINGUAS"
- fi
- for desiredlang in $desiredlanguages; do
- # Use the presentlang catalog if desiredlang is
- # a. equal to presentlang, or
- # b. a variant of presentlang (because in this case,
- # presentlang can be used as a fallback for messages
- # which are not translated in the desiredlang catalog).
- case "$desiredlang" in
- "$presentlang"*) useit=yes;;
- esac
- done
- if test $useit = yes; then
- INST_LINGUAS="$INST_LINGUAS $presentlang"
- fi
- done
- fi
- CATALOGS=
- if test -n "$INST_LINGUAS"; then
- for lang in $INST_LINGUAS; do
- CATALOGS="$CATALOGS $lang.gmo"
- done
- fi
- test -n "$as_me" && echo "$as_me: creating $ac_dir/Makefile" || echo "creating $ac_dir/Makefile"
- sed -e "/^POTFILES =/r $ac_dir/POTFILES" -e "/^# Makevars/r $ac_given_srcdir/$ac_dir/Makevars" -e "s|@POFILES@|$POFILES|g" -e "s|@GMOFILES@|$GMOFILES|g" -e "s|@UPDATEPOFILES@|$UPDATEPOFILES|g" -e "s|@DUMMYPOFILES@|$DUMMYPOFILES|g" -e "s|@CATALOGS@|$CATALOGS|g" -e "s|@POMAKEFILEDEPS@|$POMAKEFILEDEPS|g" "$ac_dir/Makefile.in" > "$ac_dir/Makefile"
- for f in "$ac_given_srcdir/$ac_dir"/Rules-*; do
- if test -f "$f"; then
- case "$f" in
- *.orig | *.bak | *~) ;;
- *) cat "$f" >> "$ac_dir/Makefile" ;;
- esac
- fi
- done
- fi
- ;;
- esac
- done ;;
- "default-2":C)
- for ac_file in $CONFIG_FILES; do
- # Support "outfile[:infile[:infile...]]"
- case "$ac_file" in
- *:*) ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
- esac
- # PO directories have a Makefile.in generated from Makefile.in.in.
- case "$ac_file" in */Makefile.in)
- # Adjust a relative srcdir.
- ac_dir=`echo "$ac_file"|sed 's%/[^/][^/]*$%%'`
- ac_dir_suffix=/`echo "$ac_dir"|sed 's%^\./%%'`
- ac_dots=`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'`
- # In autoconf-2.13 it is called $ac_given_srcdir.
- # In autoconf-2.50 it is called $srcdir.
- test -n "$ac_given_srcdir" || ac_given_srcdir="$srcdir"
- case "$ac_given_srcdir" in
- .) top_srcdir=`echo $ac_dots|sed 's%/$%%'` ;;
- /*) top_srcdir="$ac_given_srcdir" ;;
- *) top_srcdir="$ac_dots$ac_given_srcdir" ;;
- esac
- if test -f "$ac_given_srcdir/$ac_dir/POTFILES.in"; then
- rm -f "$ac_dir/POTFILES"
- test -n "$as_me" && echo "$as_me: creating $ac_dir/POTFILES" || echo "creating $ac_dir/POTFILES"
- cat "$ac_given_srcdir/$ac_dir/POTFILES.in" | sed -e "/^#/d" -e "/^[ ]*\$/d" -e "s,.*, $top_srcdir/& \\\\," | sed -e "\$s/\(.*\) \\\\/\1/" > "$ac_dir/POTFILES"
- POMAKEFILEDEPS="POTFILES.in"
- # ALL_LINGUAS, POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES depend
- # on $ac_dir but don't depend on user-specified configuration
- # parameters.
- if test -f "$ac_given_srcdir/$ac_dir/LINGUAS"; then
- # The LINGUAS file contains the set of available languages.
- if test -n "$OBSOLETE_ALL_LINGUAS"; then
- test -n "$as_me" && echo "$as_me: setting ALL_LINGUAS in configure.ac is obsolete" || echo "setting ALL_LINGUAS in configure.ac is obsolete"
- fi
- ALL_LINGUAS_=`sed -e "/^#/d" "$ac_given_srcdir/$ac_dir/LINGUAS"`
- # Hide the ALL_LINGUAS assigment from automake.
- eval 'ALL_LINGUAS''=$ALL_LINGUAS_'
- POMAKEFILEDEPS="$POMAKEFILEDEPS LINGUAS"
- else
- # The set of available languages was given in configure.ac.
- eval 'ALL_LINGUAS''=$OBSOLETE_ALL_LINGUAS'
- fi
- case "$ac_given_srcdir" in
- .) srcdirpre= ;;
- *) srcdirpre='$(srcdir)/' ;;
- esac
- POFILES=
- GMOFILES=
- UPDATEPOFILES=
- DUMMYPOFILES=
- for lang in $ALL_LINGUAS; do
- POFILES="$POFILES $srcdirpre$lang.po"
- GMOFILES="$GMOFILES $srcdirpre$lang.gmo"
- UPDATEPOFILES="$UPDATEPOFILES $lang.po-update"
- DUMMYPOFILES="$DUMMYPOFILES $lang.nop"
- done
- # CATALOGS depends on both $ac_dir and the user's LINGUAS
- # environment variable.
- INST_LINGUAS=
- if test -n "$ALL_LINGUAS"; then
- for presentlang in $ALL_LINGUAS; do
- useit=no
- if test "%UNSET%" != "$LINGUAS"; then
- desiredlanguages="$LINGUAS"
- else
- desiredlanguages="$ALL_LINGUAS"
- fi
- for desiredlang in $desiredlanguages; do
- # Use the presentlang catalog if desiredlang is
- # a. equal to presentlang, or
- # b. a variant of presentlang (because in this case,
- # presentlang can be used as a fallback for messages
- # which are not translated in the desiredlang catalog).
- case "$desiredlang" in
- "$presentlang"*) useit=yes;;
- esac
- done
- if test $useit = yes; then
- INST_LINGUAS="$INST_LINGUAS $presentlang"
- fi
- done
- fi
- CATALOGS=
- if test -n "$INST_LINGUAS"; then
- for lang in $INST_LINGUAS; do
- CATALOGS="$CATALOGS $lang.gmo"
- done
- fi
- test -n "$as_me" && echo "$as_me: creating $ac_dir/Makefile" || echo "creating $ac_dir/Makefile"
- sed -e "/^POTFILES =/r $ac_dir/POTFILES" -e "/^# Makevars/r $ac_given_srcdir/$ac_dir/Makevars" -e "s|@POFILES@|$POFILES|g" -e "s|@GMOFILES@|$GMOFILES|g" -e "s|@UPDATEPOFILES@|$UPDATEPOFILES|g" -e "s|@DUMMYPOFILES@|$DUMMYPOFILES|g" -e "s|@CATALOGS@|$CATALOGS|g" -e "s|@POMAKEFILEDEPS@|$POMAKEFILEDEPS|g" "$ac_dir/Makefile.in" > "$ac_dir/Makefile"
- for f in "$ac_given_srcdir/$ac_dir"/Rules-*; do
- if test -f "$f"; then
- case "$f" in
- *.orig | *.bak | *~) ;;
- *) cat "$f" >> "$ac_dir/Makefile" ;;
- esac
- fi
- done
- fi
- ;;
- esac
- done ;;
-
- esac
-done # for ac_tag
-
-
-as_fn_exit 0
-_ACEOF
-ac_clean_files=$ac_clean_files_save
-
-test $ac_write_fail = 0 ||
- as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
-
-
-# configure is writing to config.log, and then calls config.status.
-# config.status does its own redirection, appending to config.log.
-# Unfortunately, on DOS this fails, as config.log is still kept open
-# by configure, so config.status won't be able to write to it; its
-# output is simply discarded. So we exec the FD to /dev/null,
-# effectively closing config.log, so it can be properly (re)opened and
-# appended to by config.status. When coming back to configure, we
-# need to make the FD available again.
-if test "$no_create" != yes; then
- ac_cs_success=:
- ac_config_status_args=
- test "$silent" = yes &&
- ac_config_status_args="$ac_config_status_args --quiet"
- exec 5>/dev/null
- $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
- exec 5>>config.log
- # Use ||, not &&, to avoid exiting from the if with $? = 1, which
- # would make configure fail if this is the last instruction.
- $ac_cs_success || as_fn_exit 1
-fi
-if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
-$as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
-fi
-
-
-
-touch config.status.tmp
-if touch --reference=config.status config.status.tmp > /dev/null 2>&1; then
- sed '/as_fn_exit 0/i \
-sed -e \"s/^\t\\\(\\\$(AM_V_CCLD)\\\)/\t+ \\\1/\" Makefile > Makefile.tmp \
-touch --reference=Makefile Makefile.tmp \
-mv Makefile.tmp Makefile \
-' config.status > config.status.tmp
- touch --reference=config.status config.status.tmp
- mv config.status.tmp config.status
- chmod +x config.status
- sed -e "s/^\t\(\$(AM_V_CCLD)\)/\t+ \1/" Makefile > Makefile.tmp
- touch --reference=Makefile Makefile.tmp
- mv Makefile.tmp Makefile
-else
- rm -f config.status.tmp
-fi
Property changes on: sources/GNU/binutils/create-2.43.1-libtool-lib64-patch/binutils-2.43.1-new/gprof/configure
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: sources/GNU/binutils/create-2.43.1-libtool-lib64-patch/binutils-2.43.1-new/gas/configure
===================================================================
--- sources/GNU/binutils/create-2.43.1-libtool-lib64-patch/binutils-2.43.1-new/gas/configure (revision 75)
+++ sources/GNU/binutils/create-2.43.1-libtool-lib64-patch/binutils-2.43.1-new/gas/configure (nonexistent)
@@ -1,18964 +0,0 @@
-#! /bin/sh
-# Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.69 for gas 2.43.1.
-#
-#
-# Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc.
-#
-#
-# This configure script is free software; the Free Software Foundation
-# gives unlimited permission to copy, distribute and modify it.
-## -------------------- ##
-## M4sh Initialization. ##
-## -------------------- ##
-
-# Be more Bourne compatible
-DUALCASE=1; export DUALCASE # for MKS sh
-if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
- emulate sh
- NULLCMD=:
- # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
- # is contrary to our usage. Disable this feature.
- alias -g '${1+"$@"}'='"$@"'
- setopt NO_GLOB_SUBST
-else
- case `(set -o) 2>/dev/null` in #(
- *posix*) :
- set -o posix ;; #(
- *) :
- ;;
-esac
-fi
-
-
-as_nl='
-'
-export as_nl
-# Printing a long string crashes Solaris 7 /usr/bin/printf.
-as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
-as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
-as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
-# Prefer a ksh shell builtin over an external printf program on Solaris,
-# but without wasting forks for bash or zsh.
-if test -z "$BASH_VERSION$ZSH_VERSION" \
- && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
- as_echo='print -r --'
- as_echo_n='print -rn --'
-elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
- as_echo='printf %s\n'
- as_echo_n='printf %s'
-else
- if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
- as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
- as_echo_n='/usr/ucb/echo -n'
- else
- as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
- as_echo_n_body='eval
- arg=$1;
- case $arg in #(
- *"$as_nl"*)
- expr "X$arg" : "X\\(.*\\)$as_nl";
- arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
- esac;
- expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
- '
- export as_echo_n_body
- as_echo_n='sh -c $as_echo_n_body as_echo'
- fi
- export as_echo_body
- as_echo='sh -c $as_echo_body as_echo'
-fi
-
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- PATH_SEPARATOR=:
- (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
- (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
- PATH_SEPARATOR=';'
- }
-fi
-
-
-# IFS
-# We need space, tab and new line, in precisely that order. Quoting is
-# there to prevent editors from complaining about space-tab.
-# (If _AS_PATH_WALK were called with IFS unset, it would disable word
-# splitting by setting IFS to empty value.)
-IFS=" "" $as_nl"
-
-# Find who we are. Look in the path if we contain no directory separator.
-as_myself=
-case $0 in #((
- *[\\/]* ) as_myself=$0 ;;
- *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
- done
-IFS=$as_save_IFS
-
- ;;
-esac
-# We did not find ourselves, most probably we were run as `sh COMMAND'
-# in which case we are not to be found in the path.
-if test "x$as_myself" = x; then
- as_myself=$0
-fi
-if test ! -f "$as_myself"; then
- $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
- exit 1
-fi
-
-# Unset variables that we do not need and which cause bugs (e.g. in
-# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
-# suppresses any "Segmentation fault" message there. '((' could
-# trigger a bug in pdksh 5.2.14.
-for as_var in BASH_ENV ENV MAIL MAILPATH
-do eval test x\${$as_var+set} = xset \
- && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
-done
-PS1='$ '
-PS2='> '
-PS4='+ '
-
-# NLS nuisances.
-LC_ALL=C
-export LC_ALL
-LANGUAGE=C
-export LANGUAGE
-
-# CDPATH.
-(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
-
-# Use a proper internal environment variable to ensure we don't fall
- # into an infinite loop, continuously re-executing ourselves.
- if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then
- _as_can_reexec=no; export _as_can_reexec;
- # We cannot yet assume a decent shell, so we have to provide a
-# neutralization value for shells without unset; and this also
-# works around shells that cannot unset nonexistent variables.
-# Preserve -v and -x to the replacement shell.
-BASH_ENV=/dev/null
-ENV=/dev/null
-(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
-case $- in # ((((
- *v*x* | *x*v* ) as_opts=-vx ;;
- *v* ) as_opts=-v ;;
- *x* ) as_opts=-x ;;
- * ) as_opts= ;;
-esac
-exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
-# Admittedly, this is quite paranoid, since all the known shells bail
-# out after a failed `exec'.
-$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
-as_fn_exit 255
- fi
- # We don't want this to propagate to other subprocesses.
- { _as_can_reexec=; unset _as_can_reexec;}
-if test "x$CONFIG_SHELL" = x; then
- as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
- emulate sh
- NULLCMD=:
- # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
- # is contrary to our usage. Disable this feature.
- alias -g '\${1+\"\$@\"}'='\"\$@\"'
- setopt NO_GLOB_SUBST
-else
- case \`(set -o) 2>/dev/null\` in #(
- *posix*) :
- set -o posix ;; #(
- *) :
- ;;
-esac
-fi
-"
- as_required="as_fn_return () { (exit \$1); }
-as_fn_success () { as_fn_return 0; }
-as_fn_failure () { as_fn_return 1; }
-as_fn_ret_success () { return 0; }
-as_fn_ret_failure () { return 1; }
-
-exitcode=0
-as_fn_success || { exitcode=1; echo as_fn_success failed.; }
-as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
-as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
-as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
-if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
-
-else
- exitcode=1; echo positional parameters were not saved.
-fi
-test x\$exitcode = x0 || exit 1
-test -x / || exit 1"
- as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
- as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
- eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
- test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
-test \$(( 1 + 1 )) = 2 || exit 1
-
- test -n \"\${ZSH_VERSION+set}\${BASH_VERSION+set}\" || (
- ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
- ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO
- ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO
- PATH=/empty FPATH=/empty; export PATH FPATH
- test \"X\`printf %s \$ECHO\`\" = \"X\$ECHO\" \\
- || test \"X\`print -r -- \$ECHO\`\" = \"X\$ECHO\" ) || exit 1"
- if (eval "$as_required") 2>/dev/null; then :
- as_have_required=yes
-else
- as_have_required=no
-fi
- if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
-
-else
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-as_found=false
-for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- as_found=:
- case $as_dir in #(
- /*)
- for as_base in sh bash ksh sh5; do
- # Try only shells that exist, to save several forks.
- as_shell=$as_dir/$as_base
- if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
- { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
- CONFIG_SHELL=$as_shell as_have_required=yes
- if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
- break 2
-fi
-fi
- done;;
- esac
- as_found=false
-done
-$as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
- { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
- CONFIG_SHELL=$SHELL as_have_required=yes
-fi; }
-IFS=$as_save_IFS
-
-
- if test "x$CONFIG_SHELL" != x; then :
- export CONFIG_SHELL
- # We cannot yet assume a decent shell, so we have to provide a
-# neutralization value for shells without unset; and this also
-# works around shells that cannot unset nonexistent variables.
-# Preserve -v and -x to the replacement shell.
-BASH_ENV=/dev/null
-ENV=/dev/null
-(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
-case $- in # ((((
- *v*x* | *x*v* ) as_opts=-vx ;;
- *v* ) as_opts=-v ;;
- *x* ) as_opts=-x ;;
- * ) as_opts= ;;
-esac
-exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
-# Admittedly, this is quite paranoid, since all the known shells bail
-# out after a failed `exec'.
-$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
-exit 255
-fi
-
- if test x$as_have_required = xno; then :
- $as_echo "$0: This script requires a shell more modern than all"
- $as_echo "$0: the shells that I found on your system."
- if test x${ZSH_VERSION+set} = xset ; then
- $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
- $as_echo "$0: be upgraded to zsh 4.3.4 or later."
- else
- $as_echo "$0: Please tell bug-autoconf@gnu.org about your system,
-$0: including any error possibly output before this
-$0: message. Then install a modern shell, or manually run
-$0: the script under such a shell if you do have one."
- fi
- exit 1
-fi
-fi
-fi
-SHELL=${CONFIG_SHELL-/bin/sh}
-export SHELL
-# Unset more variables known to interfere with behavior of common tools.
-CLICOLOR_FORCE= GREP_OPTIONS=
-unset CLICOLOR_FORCE GREP_OPTIONS
-
-## --------------------- ##
-## M4sh Shell Functions. ##
-## --------------------- ##
-# as_fn_unset VAR
-# ---------------
-# Portably unset VAR.
-as_fn_unset ()
-{
- { eval $1=; unset $1;}
-}
-as_unset=as_fn_unset
-
-# as_fn_set_status STATUS
-# -----------------------
-# Set $? to STATUS, without forking.
-as_fn_set_status ()
-{
- return $1
-} # as_fn_set_status
-
-# as_fn_exit STATUS
-# -----------------
-# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
-as_fn_exit ()
-{
- set +e
- as_fn_set_status $1
- exit $1
-} # as_fn_exit
-
-# as_fn_mkdir_p
-# -------------
-# Create "$as_dir" as a directory, including parents if necessary.
-as_fn_mkdir_p ()
-{
-
- case $as_dir in #(
- -*) as_dir=./$as_dir;;
- esac
- test -d "$as_dir" || eval $as_mkdir_p || {
- as_dirs=
- while :; do
- case $as_dir in #(
- *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
- *) as_qdir=$as_dir;;
- esac
- as_dirs="'$as_qdir' $as_dirs"
- as_dir=`$as_dirname -- "$as_dir" ||
-$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$as_dir" : 'X\(//\)[^/]' \| \
- X"$as_dir" : 'X\(//\)$' \| \
- X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$as_dir" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
- test -d "$as_dir" && break
- done
- test -z "$as_dirs" || eval "mkdir $as_dirs"
- } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
-
-
-} # as_fn_mkdir_p
-
-# as_fn_executable_p FILE
-# -----------------------
-# Test if FILE is an executable regular file.
-as_fn_executable_p ()
-{
- test -f "$1" && test -x "$1"
-} # as_fn_executable_p
-# as_fn_append VAR VALUE
-# ----------------------
-# Append the text in VALUE to the end of the definition contained in VAR. Take
-# advantage of any shell optimizations that allow amortized linear growth over
-# repeated appends, instead of the typical quadratic growth present in naive
-# implementations.
-if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
- eval 'as_fn_append ()
- {
- eval $1+=\$2
- }'
-else
- as_fn_append ()
- {
- eval $1=\$$1\$2
- }
-fi # as_fn_append
-
-# as_fn_arith ARG...
-# ------------------
-# Perform arithmetic evaluation on the ARGs, and store the result in the
-# global $as_val. Take advantage of shells that can avoid forks. The arguments
-# must be portable across $(()) and expr.
-if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
- eval 'as_fn_arith ()
- {
- as_val=$(( $* ))
- }'
-else
- as_fn_arith ()
- {
- as_val=`expr "$@" || test $? -eq 1`
- }
-fi # as_fn_arith
-
-
-# as_fn_error STATUS ERROR [LINENO LOG_FD]
-# ----------------------------------------
-# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
-# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
-# script with STATUS, using 1 if that was 0.
-as_fn_error ()
-{
- as_status=$1; test $as_status -eq 0 && as_status=1
- if test "$4"; then
- as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
- fi
- $as_echo "$as_me: error: $2" >&2
- as_fn_exit $as_status
-} # as_fn_error
-
-if expr a : '\(a\)' >/dev/null 2>&1 &&
- test "X`expr 00001 : '.*\(...\)'`" = X001; then
- as_expr=expr
-else
- as_expr=false
-fi
-
-if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
- as_basename=basename
-else
- as_basename=false
-fi
-
-if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
- as_dirname=dirname
-else
- as_dirname=false
-fi
-
-as_me=`$as_basename -- "$0" ||
-$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
- X"$0" : 'X\(//\)$' \| \
- X"$0" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X/"$0" |
- sed '/^.*\/\([^/][^/]*\)\/*$/{
- s//\1/
- q
- }
- /^X\/\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\/\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
-
-# Avoid depending upon Character Ranges.
-as_cr_letters='abcdefghijklmnopqrstuvwxyz'
-as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
-as_cr_Letters=$as_cr_letters$as_cr_LETTERS
-as_cr_digits='0123456789'
-as_cr_alnum=$as_cr_Letters$as_cr_digits
-
-
- as_lineno_1=$LINENO as_lineno_1a=$LINENO
- as_lineno_2=$LINENO as_lineno_2a=$LINENO
- eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
- test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
- # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-)
- sed -n '
- p
- /[$]LINENO/=
- ' <$as_myself |
- sed '
- s/[$]LINENO.*/&-/
- t lineno
- b
- :lineno
- N
- :loop
- s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
- t loop
- s/-\n.*//
- ' >$as_me.lineno &&
- chmod +x "$as_me.lineno" ||
- { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
-
- # If we had to re-execute with $CONFIG_SHELL, we're ensured to have
- # already done that, so ensure we don't try to do so again and fall
- # in an infinite loop. This has already happened in practice.
- _as_can_reexec=no; export _as_can_reexec
- # Don't try to exec as it changes $[0], causing all sort of problems
- # (the dirname of $[0] is not the place where we might find the
- # original and so on. Autoconf is especially sensitive to this).
- . "./$as_me.lineno"
- # Exit status is that of the last command.
- exit
-}
-
-ECHO_C= ECHO_N= ECHO_T=
-case `echo -n x` in #(((((
--n*)
- case `echo 'xy\c'` in
- *c*) ECHO_T=' ';; # ECHO_T is single tab character.
- xy) ECHO_C='\c';;
- *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
- ECHO_T=' ';;
- esac;;
-*)
- ECHO_N='-n';;
-esac
-
-rm -f conf$$ conf$$.exe conf$$.file
-if test -d conf$$.dir; then
- rm -f conf$$.dir/conf$$.file
-else
- rm -f conf$$.dir
- mkdir conf$$.dir 2>/dev/null
-fi
-if (echo >conf$$.file) 2>/dev/null; then
- if ln -s conf$$.file conf$$ 2>/dev/null; then
- as_ln_s='ln -s'
- # ... but there are two gotchas:
- # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
- # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
- # In both cases, we have to default to `cp -pR'.
- ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
- as_ln_s='cp -pR'
- elif ln conf$$.file conf$$ 2>/dev/null; then
- as_ln_s=ln
- else
- as_ln_s='cp -pR'
- fi
-else
- as_ln_s='cp -pR'
-fi
-rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
-rmdir conf$$.dir 2>/dev/null
-
-if mkdir -p . 2>/dev/null; then
- as_mkdir_p='mkdir -p "$as_dir"'
-else
- test -d ./-p && rmdir ./-p
- as_mkdir_p=false
-fi
-
-as_test_x='test -x'
-as_executable_p=as_fn_executable_p
-
-# Sed expression to map a string onto a valid CPP name.
-as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
-
-# Sed expression to map a string onto a valid variable name.
-as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
-
-SHELL=${CONFIG_SHELL-/bin/sh}
-
-
-test -n "$DJDIR" || exec 7<&0 </dev/null
-exec 6>&1
-
-# Name of the host.
-# hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status,
-# so uname gets run too.
-ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
-
-#
-# Initializations.
-#
-ac_default_prefix=/usr/local
-ac_clean_files=
-ac_config_libobj_dir=.
-LIBOBJS=
-cross_compiling=no
-subdirs=
-MFLAGS=
-MAKEFLAGS=
-
-# Identity of this package.
-PACKAGE_NAME='gas'
-PACKAGE_TARNAME='gas'
-PACKAGE_VERSION='2.43.1'
-PACKAGE_STRING='gas 2.43.1'
-PACKAGE_BUGREPORT=''
-PACKAGE_URL=''
-
-ac_unique_file="as.h"
-# Factoring default headers for most tests.
-ac_includes_default="\
-#include <stdio.h>
-#ifdef HAVE_SYS_TYPES_H
-# include <sys/types.h>
-#endif
-#ifdef HAVE_SYS_STAT_H
-# include <sys/stat.h>
-#endif
-#ifdef STDC_HEADERS
-# include <stdlib.h>
-# include <stddef.h>
-#else
-# ifdef HAVE_STDLIB_H
-# include <stdlib.h>
-# endif
-#endif
-#ifdef HAVE_STRING_H
-# if !defined STDC_HEADERS && defined HAVE_MEMORY_H
-# include <memory.h>
-# endif
-# include <string.h>
-#endif
-#ifdef HAVE_STRINGS_H
-# include <strings.h>
-#endif
-#ifdef HAVE_INTTYPES_H
-# include <inttypes.h>
-#endif
-#ifdef HAVE_STDINT_H
-# include <stdint.h>
-#endif
-#ifdef HAVE_UNISTD_H
-# include <unistd.h>
-#endif"
-
-gt_needs=
-ac_subst_vars='am__EXEEXT_FALSE
-am__EXEEXT_TRUE
-LTLIBOBJS
-LIBOBJS
-ZSTD_LIBS
-ZSTD_CFLAGS
-PKG_CONFIG_LIBDIR
-PKG_CONFIG_PATH
-PKG_CONFIG
-zlibinc
-zlibdir
-LIBM
-GENINSRC_NEVER_FALSE
-GENINSRC_NEVER_TRUE
-MAINT
-MAINTAINER_MODE_FALSE
-MAINTAINER_MODE_TRUE
-CATOBJEXT
-GENCAT
-INSTOBJEXT
-DATADIRNAME
-CATALOGS
-INCINTL
-LIBINTL_DEP
-POSUB
-LTLIBINTL
-LIBINTL
-INTLLIBS
-LTLIBICONV
-LIBICONV
-INTL_MACOSX_LIBS
-MSGMERGE
-XGETTEXT
-GMSGFMT
-MSGFMT
-USE_NLS
-MKINSTALLDIRS
-LEXLIB
-LEX_OUTPUT_ROOT
-LEX
-YFLAGS
-YACC
-OPCODES_LIB
-atof
-install_tooldir
-te_file
-obj_format
-target_cpu_type
-extra_objects
-cgen_cpu_prefix
-GDBINIT
-WARN_WRITE_STRINGS
-NO_WERROR
-WARN_CFLAGS_FOR_BUILD
-WARN_CFLAGS
-do_compare
-LARGEFILE_CPPFLAGS
-OTOOL64
-OTOOL
-LIPO
-NMEDIT
-DSYMUTIL
-RANLIB
-AR
-OBJDUMP
-LN_S
-NM
-ac_ct_DUMPBIN
-DUMPBIN
-LD
-FGREP
-SED
-LIBTOOL
-EGREP
-GREP
-CPP
-am__fastdepCC_FALSE
-am__fastdepCC_TRUE
-CCDEPMODE
-am__nodep
-AMDEPBACKSLASH
-AMDEP_FALSE
-AMDEP_TRUE
-am__quote
-am__include
-DEPDIR
-OBJEXT
-EXEEXT
-ac_ct_CC
-CPPFLAGS
-LDFLAGS
-CFLAGS
-CC
-AM_BACKSLASH
-AM_DEFAULT_VERBOSITY
-AM_DEFAULT_V
-AM_V
-am__untar
-am__tar
-AMTAR
-am__leading_dot
-SET_MAKE
-AWK
-mkdir_p
-MKDIR_P
-INSTALL_STRIP_PROGRAM
-STRIP
-install_sh
-MAKEINFO
-AUTOHEADER
-AUTOMAKE
-AUTOCONF
-ACLOCAL
-VERSION
-PACKAGE
-CYGPATH_W
-am__isrc
-INSTALL_DATA
-INSTALL_SCRIPT
-INSTALL_PROGRAM
-target_os
-target_vendor
-target_cpu
-target
-host_os
-host_vendor
-host_cpu
-host
-build_os
-build_vendor
-build_cpu
-build
-target_alias
-host_alias
-build_alias
-LIBS
-ECHO_T
-ECHO_N
-ECHO_C
-DEFS
-mandir
-localedir
-libdir
-psdir
-pdfdir
-dvidir
-htmldir
-infodir
-docdir
-oldincludedir
-includedir
-localstatedir
-sharedstatedir
-sysconfdir
-datadir
-datarootdir
-libexecdir
-sbindir
-bindir
-program_transform_name
-prefix
-exec_prefix
-PACKAGE_URL
-PACKAGE_BUGREPORT
-PACKAGE_STRING
-PACKAGE_VERSION
-PACKAGE_TARNAME
-PACKAGE_NAME
-PATH_SEPARATOR
-SHELL'
-ac_subst_files=''
-ac_user_opts='
-enable_option_checking
-enable_silent_rules
-enable_dependency_tracking
-enable_shared
-enable_static
-with_pic
-enable_fast_install
-with_gnu_ld
-enable_libtool_lock
-enable_plugins
-enable_largefile
-enable_targets
-enable_checking
-enable_compressed_debug_sections
-enable_default_compressed_debug_sections_algorithm
-enable_x86_relax_relocations
-enable_elf_stt_common
-enable_generate_build_notes
-enable_mips_fix_loongson3_llsc
-enable_x86_used_note
-enable_default_riscv_attribute
-enable_werror
-enable_build_warnings
-with_cpu
-enable_nls
-enable_rpath
-with_libiconv_prefix
-with_libiconv_type
-with_libintl_prefix
-with_libintl_type
-enable_maintainer_mode
-with_system_zlib
-with_zstd
-'
- ac_precious_vars='build_alias
-host_alias
-target_alias
-CC
-CFLAGS
-LDFLAGS
-LIBS
-CPPFLAGS
-CPP
-YACC
-YFLAGS
-PKG_CONFIG
-PKG_CONFIG_PATH
-PKG_CONFIG_LIBDIR
-ZSTD_CFLAGS
-ZSTD_LIBS'
-
-
-# Initialize some variables set by options.
-ac_init_help=
-ac_init_version=false
-ac_unrecognized_opts=
-ac_unrecognized_sep=
-# The variables have the same names as the options, with
-# dashes changed to underlines.
-cache_file=/dev/null
-exec_prefix=NONE
-no_create=
-no_recursion=
-prefix=NONE
-program_prefix=NONE
-program_suffix=NONE
-program_transform_name=s,x,x,
-silent=
-site=
-srcdir=
-verbose=
-x_includes=NONE
-x_libraries=NONE
-
-# Installation directory options.
-# These are left unexpanded so users can "make install exec_prefix=/foo"
-# and all the variables that are supposed to be based on exec_prefix
-# by default will actually change.
-# Use braces instead of parens because sh, perl, etc. also accept them.
-# (The list follows the same order as the GNU Coding Standards.)
-bindir='${exec_prefix}/bin'
-sbindir='${exec_prefix}/sbin'
-libexecdir='${exec_prefix}/libexec'
-datarootdir='${prefix}/share'
-datadir='${datarootdir}'
-sysconfdir='${prefix}/etc'
-sharedstatedir='${prefix}/com'
-localstatedir='${prefix}/var'
-includedir='${prefix}/include'
-oldincludedir='/usr/include'
-docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
-infodir='${datarootdir}/info'
-htmldir='${docdir}'
-dvidir='${docdir}'
-pdfdir='${docdir}'
-psdir='${docdir}'
-libdir='${exec_prefix}/lib'
-localedir='${datarootdir}/locale'
-mandir='${datarootdir}/man'
-
-ac_prev=
-ac_dashdash=
-for ac_option
-do
- # If the previous option needs an argument, assign it.
- if test -n "$ac_prev"; then
- eval $ac_prev=\$ac_option
- ac_prev=
- continue
- fi
-
- case $ac_option in
- *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
- *=) ac_optarg= ;;
- *) ac_optarg=yes ;;
- esac
-
- # Accept the important Cygnus configure options, so we can diagnose typos.
-
- case $ac_dashdash$ac_option in
- --)
- ac_dashdash=yes ;;
-
- -bindir | --bindir | --bindi | --bind | --bin | --bi)
- ac_prev=bindir ;;
- -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
- bindir=$ac_optarg ;;
-
- -build | --build | --buil | --bui | --bu)
- ac_prev=build_alias ;;
- -build=* | --build=* | --buil=* | --bui=* | --bu=*)
- build_alias=$ac_optarg ;;
-
- -cache-file | --cache-file | --cache-fil | --cache-fi \
- | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
- ac_prev=cache_file ;;
- -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
- | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
- cache_file=$ac_optarg ;;
-
- --config-cache | -C)
- cache_file=config.cache ;;
-
- -datadir | --datadir | --datadi | --datad)
- ac_prev=datadir ;;
- -datadir=* | --datadir=* | --datadi=* | --datad=*)
- datadir=$ac_optarg ;;
-
- -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
- | --dataroo | --dataro | --datar)
- ac_prev=datarootdir ;;
- -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
- | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
- datarootdir=$ac_optarg ;;
-
- -disable-* | --disable-*)
- ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
- # Reject names that are not valid shell variable names.
- expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
- as_fn_error $? "invalid feature name: $ac_useropt"
- ac_useropt_orig=$ac_useropt
- ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
- case $ac_user_opts in
- *"
-"enable_$ac_useropt"
-"*) ;;
- *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
- ac_unrecognized_sep=', ';;
- esac
- eval enable_$ac_useropt=no ;;
-
- -docdir | --docdir | --docdi | --doc | --do)
- ac_prev=docdir ;;
- -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
- docdir=$ac_optarg ;;
-
- -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
- ac_prev=dvidir ;;
- -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
- dvidir=$ac_optarg ;;
-
- -enable-* | --enable-*)
- ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
- # Reject names that are not valid shell variable names.
- expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
- as_fn_error $? "invalid feature name: $ac_useropt"
- ac_useropt_orig=$ac_useropt
- ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
- case $ac_user_opts in
- *"
-"enable_$ac_useropt"
-"*) ;;
- *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
- ac_unrecognized_sep=', ';;
- esac
- eval enable_$ac_useropt=\$ac_optarg ;;
-
- -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
- | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
- | --exec | --exe | --ex)
- ac_prev=exec_prefix ;;
- -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
- | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
- | --exec=* | --exe=* | --ex=*)
- exec_prefix=$ac_optarg ;;
-
- -gas | --gas | --ga | --g)
- # Obsolete; use --with-gas.
- with_gas=yes ;;
-
- -help | --help | --hel | --he | -h)
- ac_init_help=long ;;
- -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
- ac_init_help=recursive ;;
- -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
- ac_init_help=short ;;
-
- -host | --host | --hos | --ho)
- ac_prev=host_alias ;;
- -host=* | --host=* | --hos=* | --ho=*)
- host_alias=$ac_optarg ;;
-
- -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
- ac_prev=htmldir ;;
- -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
- | --ht=*)
- htmldir=$ac_optarg ;;
-
- -includedir | --includedir | --includedi | --included | --include \
- | --includ | --inclu | --incl | --inc)
- ac_prev=includedir ;;
- -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
- | --includ=* | --inclu=* | --incl=* | --inc=*)
- includedir=$ac_optarg ;;
-
- -infodir | --infodir | --infodi | --infod | --info | --inf)
- ac_prev=infodir ;;
- -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
- infodir=$ac_optarg ;;
-
- -libdir | --libdir | --libdi | --libd)
- ac_prev=libdir ;;
- -libdir=* | --libdir=* | --libdi=* | --libd=*)
- libdir=$ac_optarg ;;
-
- -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
- | --libexe | --libex | --libe)
- ac_prev=libexecdir ;;
- -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
- | --libexe=* | --libex=* | --libe=*)
- libexecdir=$ac_optarg ;;
-
- -localedir | --localedir | --localedi | --localed | --locale)
- ac_prev=localedir ;;
- -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
- localedir=$ac_optarg ;;
-
- -localstatedir | --localstatedir | --localstatedi | --localstated \
- | --localstate | --localstat | --localsta | --localst | --locals)
- ac_prev=localstatedir ;;
- -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
- | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
- localstatedir=$ac_optarg ;;
-
- -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
- ac_prev=mandir ;;
- -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
- mandir=$ac_optarg ;;
-
- -nfp | --nfp | --nf)
- # Obsolete; use --without-fp.
- with_fp=no ;;
-
- -no-create | --no-create | --no-creat | --no-crea | --no-cre \
- | --no-cr | --no-c | -n)
- no_create=yes ;;
-
- -no-recursion | --no-recursion | --no-recursio | --no-recursi \
- | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
- no_recursion=yes ;;
-
- -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
- | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
- | --oldin | --oldi | --old | --ol | --o)
- ac_prev=oldincludedir ;;
- -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
- | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
- | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
- oldincludedir=$ac_optarg ;;
-
- -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
- ac_prev=prefix ;;
- -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
- prefix=$ac_optarg ;;
-
- -program-prefix | --program-prefix | --program-prefi | --program-pref \
- | --program-pre | --program-pr | --program-p)
- ac_prev=program_prefix ;;
- -program-prefix=* | --program-prefix=* | --program-prefi=* \
- | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
- program_prefix=$ac_optarg ;;
-
- -program-suffix | --program-suffix | --program-suffi | --program-suff \
- | --program-suf | --program-su | --program-s)
- ac_prev=program_suffix ;;
- -program-suffix=* | --program-suffix=* | --program-suffi=* \
- | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
- program_suffix=$ac_optarg ;;
-
- -program-transform-name | --program-transform-name \
- | --program-transform-nam | --program-transform-na \
- | --program-transform-n | --program-transform- \
- | --program-transform | --program-transfor \
- | --program-transfo | --program-transf \
- | --program-trans | --program-tran \
- | --progr-tra | --program-tr | --program-t)
- ac_prev=program_transform_name ;;
- -program-transform-name=* | --program-transform-name=* \
- | --program-transform-nam=* | --program-transform-na=* \
- | --program-transform-n=* | --program-transform-=* \
- | --program-transform=* | --program-transfor=* \
- | --program-transfo=* | --program-transf=* \
- | --program-trans=* | --program-tran=* \
- | --progr-tra=* | --program-tr=* | --program-t=*)
- program_transform_name=$ac_optarg ;;
-
- -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
- ac_prev=pdfdir ;;
- -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
- pdfdir=$ac_optarg ;;
-
- -psdir | --psdir | --psdi | --psd | --ps)
- ac_prev=psdir ;;
- -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
- psdir=$ac_optarg ;;
-
- -q | -quiet | --quiet | --quie | --qui | --qu | --q \
- | -silent | --silent | --silen | --sile | --sil)
- silent=yes ;;
-
- -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
- ac_prev=sbindir ;;
- -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
- | --sbi=* | --sb=*)
- sbindir=$ac_optarg ;;
-
- -sharedstatedir | --sharedstatedir | --sharedstatedi \
- | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
- | --sharedst | --shareds | --shared | --share | --shar \
- | --sha | --sh)
- ac_prev=sharedstatedir ;;
- -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
- | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
- | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
- | --sha=* | --sh=*)
- sharedstatedir=$ac_optarg ;;
-
- -site | --site | --sit)
- ac_prev=site ;;
- -site=* | --site=* | --sit=*)
- site=$ac_optarg ;;
-
- -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
- ac_prev=srcdir ;;
- -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
- srcdir=$ac_optarg ;;
-
- -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
- | --syscon | --sysco | --sysc | --sys | --sy)
- ac_prev=sysconfdir ;;
- -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
- | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
- sysconfdir=$ac_optarg ;;
-
- -target | --target | --targe | --targ | --tar | --ta | --t)
- ac_prev=target_alias ;;
- -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
- target_alias=$ac_optarg ;;
-
- -v | -verbose | --verbose | --verbos | --verbo | --verb)
- verbose=yes ;;
-
- -version | --version | --versio | --versi | --vers | -V)
- ac_init_version=: ;;
-
- -with-* | --with-*)
- ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
- # Reject names that are not valid shell variable names.
- expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
- as_fn_error $? "invalid package name: $ac_useropt"
- ac_useropt_orig=$ac_useropt
- ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
- case $ac_user_opts in
- *"
-"with_$ac_useropt"
-"*) ;;
- *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
- ac_unrecognized_sep=', ';;
- esac
- eval with_$ac_useropt=\$ac_optarg ;;
-
- -without-* | --without-*)
- ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
- # Reject names that are not valid shell variable names.
- expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
- as_fn_error $? "invalid package name: $ac_useropt"
- ac_useropt_orig=$ac_useropt
- ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
- case $ac_user_opts in
- *"
-"with_$ac_useropt"
-"*) ;;
- *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
- ac_unrecognized_sep=', ';;
- esac
- eval with_$ac_useropt=no ;;
-
- --x)
- # Obsolete; use --with-x.
- with_x=yes ;;
-
- -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
- | --x-incl | --x-inc | --x-in | --x-i)
- ac_prev=x_includes ;;
- -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
- | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
- x_includes=$ac_optarg ;;
-
- -x-libraries | --x-libraries | --x-librarie | --x-librari \
- | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
- ac_prev=x_libraries ;;
- -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
- | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
- x_libraries=$ac_optarg ;;
-
- -*) as_fn_error $? "unrecognized option: \`$ac_option'
-Try \`$0 --help' for more information"
- ;;
-
- *=*)
- ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
- # Reject names that are not valid shell variable names.
- case $ac_envvar in #(
- '' | [0-9]* | *[!_$as_cr_alnum]* )
- as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
- esac
- eval $ac_envvar=\$ac_optarg
- export $ac_envvar ;;
-
- *)
- # FIXME: should be removed in autoconf 3.0.
- $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
- expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
- $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
- : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
- ;;
-
- esac
-done
-
-if test -n "$ac_prev"; then
- ac_option=--`echo $ac_prev | sed 's/_/-/g'`
- as_fn_error $? "missing argument to $ac_option"
-fi
-
-if test -n "$ac_unrecognized_opts"; then
- case $enable_option_checking in
- no) ;;
- fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
- *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
- esac
-fi
-
-# Check all directory arguments for consistency.
-for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
- datadir sysconfdir sharedstatedir localstatedir includedir \
- oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
- libdir localedir mandir
-do
- eval ac_val=\$$ac_var
- # Remove trailing slashes.
- case $ac_val in
- */ )
- ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
- eval $ac_var=\$ac_val;;
- esac
- # Be sure to have absolute directory names.
- case $ac_val in
- [\\/$]* | ?:[\\/]* ) continue;;
- NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
- esac
- as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
-done
-
-# There might be people who depend on the old broken behavior: `$host'
-# used to hold the argument of --host etc.
-# FIXME: To remove some day.
-build=$build_alias
-host=$host_alias
-target=$target_alias
-
-# FIXME: To remove some day.
-if test "x$host_alias" != x; then
- if test "x$build_alias" = x; then
- cross_compiling=maybe
- elif test "x$build_alias" != "x$host_alias"; then
- cross_compiling=yes
- fi
-fi
-
-ac_tool_prefix=
-test -n "$host_alias" && ac_tool_prefix=$host_alias-
-
-test "$silent" = yes && exec 6>/dev/null
-
-
-ac_pwd=`pwd` && test -n "$ac_pwd" &&
-ac_ls_di=`ls -di .` &&
-ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
- as_fn_error $? "working directory cannot be determined"
-test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
- as_fn_error $? "pwd does not report name of working directory"
-
-
-# Find the source files, if location was not specified.
-if test -z "$srcdir"; then
- ac_srcdir_defaulted=yes
- # Try the directory containing this script, then the parent directory.
- ac_confdir=`$as_dirname -- "$as_myself" ||
-$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$as_myself" : 'X\(//\)[^/]' \| \
- X"$as_myself" : 'X\(//\)$' \| \
- X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$as_myself" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
- srcdir=$ac_confdir
- if test ! -r "$srcdir/$ac_unique_file"; then
- srcdir=..
- fi
-else
- ac_srcdir_defaulted=no
-fi
-if test ! -r "$srcdir/$ac_unique_file"; then
- test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
- as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
-fi
-ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
-ac_abs_confdir=`(
- cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
- pwd)`
-# When building in place, set srcdir=.
-if test "$ac_abs_confdir" = "$ac_pwd"; then
- srcdir=.
-fi
-# Remove unnecessary trailing slashes from srcdir.
-# Double slashes in file names in object file debugging info
-# mess up M-x gdb in Emacs.
-case $srcdir in
-*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
-esac
-for ac_var in $ac_precious_vars; do
- eval ac_env_${ac_var}_set=\${${ac_var}+set}
- eval ac_env_${ac_var}_value=\$${ac_var}
- eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
- eval ac_cv_env_${ac_var}_value=\$${ac_var}
-done
-
-#
-# Report the --help message.
-#
-if test "$ac_init_help" = "long"; then
- # Omit some internal or obsolete options to make the list less imposing.
- # This message is too long to be a string in the A/UX 3.1 sh.
- cat <<_ACEOF
-\`configure' configures gas 2.43.1 to adapt to many kinds of systems.
-
-Usage: $0 [OPTION]... [VAR=VALUE]...
-
-To assign environment variables (e.g., CC, CFLAGS...), specify them as
-VAR=VALUE. See below for descriptions of some of the useful variables.
-
-Defaults for the options are specified in brackets.
-
-Configuration:
- -h, --help display this help and exit
- --help=short display options specific to this package
- --help=recursive display the short help of all the included packages
- -V, --version display version information and exit
- -q, --quiet, --silent do not print \`checking ...' messages
- --cache-file=FILE cache test results in FILE [disabled]
- -C, --config-cache alias for \`--cache-file=config.cache'
- -n, --no-create do not create output files
- --srcdir=DIR find the sources in DIR [configure dir or \`..']
-
-Installation directories:
- --prefix=PREFIX install architecture-independent files in PREFIX
- [$ac_default_prefix]
- --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
- [PREFIX]
-
-By default, \`make install' will install all the files in
-\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
-an installation prefix other than \`$ac_default_prefix' using \`--prefix',
-for instance \`--prefix=\$HOME'.
-
-For better control, use the options below.
-
-Fine tuning of the installation directories:
- --bindir=DIR user executables [EPREFIX/bin]
- --sbindir=DIR system admin executables [EPREFIX/sbin]
- --libexecdir=DIR program executables [EPREFIX/libexec]
- --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
- --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
- --localstatedir=DIR modifiable single-machine data [PREFIX/var]
- --libdir=DIR object code libraries [EPREFIX/lib]
- --includedir=DIR C header files [PREFIX/include]
- --oldincludedir=DIR C header files for non-gcc [/usr/include]
- --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
- --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
- --infodir=DIR info documentation [DATAROOTDIR/info]
- --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
- --mandir=DIR man documentation [DATAROOTDIR/man]
- --docdir=DIR documentation root [DATAROOTDIR/doc/gas]
- --htmldir=DIR html documentation [DOCDIR]
- --dvidir=DIR dvi documentation [DOCDIR]
- --pdfdir=DIR pdf documentation [DOCDIR]
- --psdir=DIR ps documentation [DOCDIR]
-_ACEOF
-
- cat <<\_ACEOF
-
-Program names:
- --program-prefix=PREFIX prepend PREFIX to installed program names
- --program-suffix=SUFFIX append SUFFIX to installed program names
- --program-transform-name=PROGRAM run sed PROGRAM on installed program names
-
-System types:
- --build=BUILD configure for building on BUILD [guessed]
- --host=HOST cross-compile to build programs to run on HOST [BUILD]
- --target=TARGET configure for building compilers for TARGET [HOST]
-_ACEOF
-fi
-
-if test -n "$ac_init_help"; then
- case $ac_init_help in
- short | recursive ) echo "Configuration of gas 2.43.1:";;
- esac
- cat <<\_ACEOF
-
-Optional Features:
- --disable-option-checking ignore unrecognized --enable/--with options
- --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
- --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
- --enable-silent-rules less verbose build output (undo: "make V=1")
- --disable-silent-rules verbose build output (undo: "make V=0")
- --enable-dependency-tracking
- do not reject slow dependency extractors
- --disable-dependency-tracking
- speeds up one-time build
- --enable-shared[=PKGS] build shared libraries [default=yes]
- --enable-static[=PKGS] build static libraries [default=yes]
- --enable-fast-install[=PKGS]
- optimize for fast installation [default=yes]
- --disable-libtool-lock avoid locking (might break parallel builds)
- --enable-plugins Enable support for plugins
- --disable-largefile omit support for large files
- --enable-targets alternative target configurations besides the primary
- --enable-checking enable run-time checks
- --enable-compressed-debug-sections={all,gas,none}
- compress debug sections by default
- --enable-default-compressed-debug-sections-algorithm={zlib,zstd}
- Default compression algorithm for
- --enable-compressed-debug-sections.
- --enable-x86-relax-relocations
- generate x86 relax relocations by default
- --enable-elf-stt-common generate ELF common symbols with STT_COMMON type by
- default
- --enable-generate-build-notes
- generate GNU Build notes if none are provided by the
- input
- --enable-mips-fix-loongson3-llsc
- enable MIPS fix Loongson3 LLSC errata
- --enable-x86-used-note generate GNU x86 used ISA and feature properties
- --enable-default-riscv-attribute
- generate RISC-V arch attribute by default
- --enable-werror treat compile warnings as errors
- --enable-build-warnings enable build-time compiler warnings
- --disable-nls do not use Native Language Support
- --disable-rpath do not hardcode runtime library paths
- --enable-maintainer-mode
- enable make rules and dependencies not useful (and
- sometimes confusing) to the casual installer
-
-Optional Packages:
- --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
- --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
- --with-pic try to use only PIC/non-PIC objects [default=use
- both]
- --with-gnu-ld assume the C compiler uses GNU ld [default=no]
- --with-cpu=CPU default cpu variant is CPU (currently only supported
- on ARC)
- --with-gnu-ld assume the C compiler uses GNU ld default=no
- --with-libiconv-prefix[=DIR] search for libiconv in DIR/include and DIR/lib
- --without-libiconv-prefix don't search for libiconv in includedir and libdir
- --with-libiconv-type=TYPE type of library to search for (auto/static/shared)
- --with-libintl-prefix[=DIR] search for libintl in DIR/include and DIR/lib
- --without-libintl-prefix don't search for libintl in includedir and libdir
- --with-libintl-type=TYPE type of library to search for (auto/static/shared)
- --with-system-zlib use installed libz
- --with-zstd support zstd compressed debug sections
- (default=auto)
-
-Some influential environment variables:
- CC C compiler command
- CFLAGS C compiler flags
- LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
- nonstandard directory <lib dir>
- LIBS libraries to pass to the linker, e.g. -l<library>
- CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
- you have headers in a nonstandard directory <include dir>
- CPP C preprocessor
- YACC The `Yet Another Compiler Compiler' implementation to use.
- Defaults to the first program found out of: `bison -y', `byacc',
- `yacc'.
- YFLAGS The list of arguments that will be passed by default to $YACC.
- This script will default YFLAGS to the empty string to avoid a
- default value of `-d' given by some make applications.
- PKG_CONFIG path to pkg-config utility
- PKG_CONFIG_PATH
- directories to add to pkg-config's search path
- PKG_CONFIG_LIBDIR
- path overriding pkg-config's built-in search path
- ZSTD_CFLAGS C compiler flags for ZSTD, overriding pkg-config
- ZSTD_LIBS linker flags for ZSTD, overriding pkg-config
-
-Use these variables to override the choices made by `configure' or to help
-it to find libraries and programs with nonstandard names/locations.
-
-Report bugs to the package provider.
-_ACEOF
-ac_status=$?
-fi
-
-if test "$ac_init_help" = "recursive"; then
- # If there are subdirs, report their specific --help.
- for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
- test -d "$ac_dir" ||
- { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
- continue
- ac_builddir=.
-
-case "$ac_dir" in
-.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
-*)
- ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
- # A ".." for each directory in $ac_dir_suffix.
- ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
- case $ac_top_builddir_sub in
- "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
- *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
- esac ;;
-esac
-ac_abs_top_builddir=$ac_pwd
-ac_abs_builddir=$ac_pwd$ac_dir_suffix
-# for backward compatibility:
-ac_top_builddir=$ac_top_build_prefix
-
-case $srcdir in
- .) # We are building in place.
- ac_srcdir=.
- ac_top_srcdir=$ac_top_builddir_sub
- ac_abs_top_srcdir=$ac_pwd ;;
- [\\/]* | ?:[\\/]* ) # Absolute name.
- ac_srcdir=$srcdir$ac_dir_suffix;
- ac_top_srcdir=$srcdir
- ac_abs_top_srcdir=$srcdir ;;
- *) # Relative name.
- ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
- ac_top_srcdir=$ac_top_build_prefix$srcdir
- ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
-esac
-ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
-
- cd "$ac_dir" || { ac_status=$?; continue; }
- # Check for guested configure.
- if test -f "$ac_srcdir/configure.gnu"; then
- echo &&
- $SHELL "$ac_srcdir/configure.gnu" --help=recursive
- elif test -f "$ac_srcdir/configure"; then
- echo &&
- $SHELL "$ac_srcdir/configure" --help=recursive
- else
- $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
- fi || ac_status=$?
- cd "$ac_pwd" || { ac_status=$?; break; }
- done
-fi
-
-test -n "$ac_init_help" && exit $ac_status
-if $ac_init_version; then
- cat <<\_ACEOF
-gas configure 2.43.1
-generated by GNU Autoconf 2.69
-
-Copyright (C) 2012 Free Software Foundation, Inc.
-This configure script is free software; the Free Software Foundation
-gives unlimited permission to copy, distribute and modify it.
-_ACEOF
- exit
-fi
-
-## ------------------------ ##
-## Autoconf initialization. ##
-## ------------------------ ##
-
-# ac_fn_c_try_compile LINENO
-# --------------------------
-# Try to compile conftest.$ac_ext, and return whether this succeeded.
-ac_fn_c_try_compile ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- rm -f conftest.$ac_objext
- if { { ac_try="$ac_compile"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_compile") 2>conftest.err
- ac_status=$?
- if test -s conftest.err; then
- grep -v '^ *+' conftest.err >conftest.er1
- cat conftest.er1 >&5
- mv -f conftest.er1 conftest.err
- fi
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && {
- test -z "$ac_c_werror_flag" ||
- test ! -s conftest.err
- } && test -s conftest.$ac_objext; then :
- ac_retval=0
-else
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
- ac_retval=1
-fi
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
- as_fn_set_status $ac_retval
-
-} # ac_fn_c_try_compile
-
-# ac_fn_c_try_cpp LINENO
-# ----------------------
-# Try to preprocess conftest.$ac_ext, and return whether this succeeded.
-ac_fn_c_try_cpp ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- if { { ac_try="$ac_cpp conftest.$ac_ext"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
- ac_status=$?
- if test -s conftest.err; then
- grep -v '^ *+' conftest.err >conftest.er1
- cat conftest.er1 >&5
- mv -f conftest.er1 conftest.err
- fi
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } > conftest.i && {
- test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
- test ! -s conftest.err
- }; then :
- ac_retval=0
-else
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
- ac_retval=1
-fi
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
- as_fn_set_status $ac_retval
-
-} # ac_fn_c_try_cpp
-
-# ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
-# -------------------------------------------------------
-# Tests whether HEADER exists, giving a warning if it cannot be compiled using
-# the include files in INCLUDES and setting the cache variable VAR
-# accordingly.
-ac_fn_c_check_header_mongrel ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- if eval \${$3+:} false; then :
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
-$as_echo_n "checking for $2... " >&6; }
-if eval \${$3+:} false; then :
- $as_echo_n "(cached) " >&6
-fi
-eval ac_res=\$$3
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
-else
- # Is the header compilable?
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
-$as_echo_n "checking $2 usability... " >&6; }
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$4
-#include <$2>
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_header_compiler=yes
-else
- ac_header_compiler=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
-$as_echo "$ac_header_compiler" >&6; }
-
-# Is the header present?
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
-$as_echo_n "checking $2 presence... " >&6; }
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <$2>
-_ACEOF
-if ac_fn_c_try_cpp "$LINENO"; then :
- ac_header_preproc=yes
-else
- ac_header_preproc=no
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
-$as_echo "$ac_header_preproc" >&6; }
-
-# So? What about this header?
-case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
- yes:no: )
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
-$as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
-$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
- ;;
- no:yes:* )
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
-$as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
-$as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
-$as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
-$as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
-$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
- ;;
-esac
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
-$as_echo_n "checking for $2... " >&6; }
-if eval \${$3+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- eval "$3=\$ac_header_compiler"
-fi
-eval ac_res=\$$3
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
-fi
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
-
-} # ac_fn_c_check_header_mongrel
-
-# ac_fn_c_try_run LINENO
-# ----------------------
-# Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
-# that executables *can* be run.
-ac_fn_c_try_run ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- if { { ac_try="$ac_link"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_link") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
- { { case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_try") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; }; then :
- ac_retval=0
-else
- $as_echo "$as_me: program exited with status $ac_status" >&5
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
- ac_retval=$ac_status
-fi
- rm -rf conftest.dSYM conftest_ipa8_conftest.oo
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
- as_fn_set_status $ac_retval
-
-} # ac_fn_c_try_run
-
-# ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
-# -------------------------------------------------------
-# Tests whether HEADER exists and can be compiled using the include files in
-# INCLUDES, setting the cache variable VAR accordingly.
-ac_fn_c_check_header_compile ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
-$as_echo_n "checking for $2... " >&6; }
-if eval \${$3+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$4
-#include <$2>
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- eval "$3=yes"
-else
- eval "$3=no"
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-eval ac_res=\$$3
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
-
-} # ac_fn_c_check_header_compile
-
-# ac_fn_c_try_link LINENO
-# -----------------------
-# Try to link conftest.$ac_ext, and return whether this succeeded.
-ac_fn_c_try_link ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- rm -f conftest.$ac_objext conftest$ac_exeext
- if { { ac_try="$ac_link"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_link") 2>conftest.err
- ac_status=$?
- if test -s conftest.err; then
- grep -v '^ *+' conftest.err >conftest.er1
- cat conftest.er1 >&5
- mv -f conftest.er1 conftest.err
- fi
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && {
- test -z "$ac_c_werror_flag" ||
- test ! -s conftest.err
- } && test -s conftest$ac_exeext && {
- test "$cross_compiling" = yes ||
- test -x conftest$ac_exeext
- }; then :
- ac_retval=0
-else
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
- ac_retval=1
-fi
- # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
- # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
- # interfere with the next link command; also delete a directory that is
- # left behind by Apple's compiler. We do this before executing the actions.
- rm -rf conftest.dSYM conftest_ipa8_conftest.oo
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
- as_fn_set_status $ac_retval
-
-} # ac_fn_c_try_link
-
-# ac_fn_c_check_func LINENO FUNC VAR
-# ----------------------------------
-# Tests whether FUNC exists, setting the cache variable VAR accordingly
-ac_fn_c_check_func ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
-$as_echo_n "checking for $2... " >&6; }
-if eval \${$3+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-/* Define $2 to an innocuous variant, in case <limits.h> declares $2.
- For example, HP-UX 11i <limits.h> declares gettimeofday. */
-#define $2 innocuous_$2
-
-/* System header to define __stub macros and hopefully few prototypes,
- which can conflict with char $2 (); below.
- Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
- <limits.h> exists even on freestanding compilers. */
-
-#ifdef __STDC__
-# include <limits.h>
-#else
-# include <assert.h>
-#endif
-
-#undef $2
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char $2 ();
-/* The GNU C library defines this for functions which it implements
- to always fail with ENOSYS. Some functions are actually named
- something starting with __ and the normal name is an alias. */
-#if defined __stub_$2 || defined __stub___$2
-choke me
-#endif
-
-int
-main ()
-{
-return $2 ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- eval "$3=yes"
-else
- eval "$3=no"
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-fi
-eval ac_res=\$$3
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
-
-} # ac_fn_c_check_func
-
-# ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES
-# ---------------------------------------------
-# Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR
-# accordingly.
-ac_fn_c_check_decl ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- as_decl_name=`echo $2|sed 's/ *(.*//'`
- as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'`
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5
-$as_echo_n "checking whether $as_decl_name is declared... " >&6; }
-if eval \${$3+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$4
-int
-main ()
-{
-#ifndef $as_decl_name
-#ifdef __cplusplus
- (void) $as_decl_use;
-#else
- (void) $as_decl_name;
-#endif
-#endif
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- eval "$3=yes"
-else
- eval "$3=no"
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-eval ac_res=\$$3
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
-
-} # ac_fn_c_check_decl
-cat >config.log <<_ACEOF
-This file contains any messages produced by compilers while
-running configure, to aid debugging if configure makes a mistake.
-
-It was created by gas $as_me 2.43.1, which was
-generated by GNU Autoconf 2.69. Invocation command line was
-
- $ $0 $@
-
-_ACEOF
-exec 5>>config.log
-{
-cat <<_ASUNAME
-## --------- ##
-## Platform. ##
-## --------- ##
-
-hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
-uname -m = `(uname -m) 2>/dev/null || echo unknown`
-uname -r = `(uname -r) 2>/dev/null || echo unknown`
-uname -s = `(uname -s) 2>/dev/null || echo unknown`
-uname -v = `(uname -v) 2>/dev/null || echo unknown`
-
-/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
-/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
-
-/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
-/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
-/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
-/usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
-/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
-/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
-/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
-
-_ASUNAME
-
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- $as_echo "PATH: $as_dir"
- done
-IFS=$as_save_IFS
-
-} >&5
-
-cat >&5 <<_ACEOF
-
-
-## ----------- ##
-## Core tests. ##
-## ----------- ##
-
-_ACEOF
-
-
-# Keep a trace of the command line.
-# Strip out --no-create and --no-recursion so they do not pile up.
-# Strip out --silent because we don't want to record it for future runs.
-# Also quote any args containing shell meta-characters.
-# Make two passes to allow for proper duplicate-argument suppression.
-ac_configure_args=
-ac_configure_args0=
-ac_configure_args1=
-ac_must_keep_next=false
-for ac_pass in 1 2
-do
- for ac_arg
- do
- case $ac_arg in
- -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
- -q | -quiet | --quiet | --quie | --qui | --qu | --q \
- | -silent | --silent | --silen | --sile | --sil)
- continue ;;
- *\'*)
- ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
- esac
- case $ac_pass in
- 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
- 2)
- as_fn_append ac_configure_args1 " '$ac_arg'"
- if test $ac_must_keep_next = true; then
- ac_must_keep_next=false # Got value, back to normal.
- else
- case $ac_arg in
- *=* | --config-cache | -C | -disable-* | --disable-* \
- | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
- | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
- | -with-* | --with-* | -without-* | --without-* | --x)
- case "$ac_configure_args0 " in
- "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
- esac
- ;;
- -* ) ac_must_keep_next=true ;;
- esac
- fi
- as_fn_append ac_configure_args " '$ac_arg'"
- ;;
- esac
- done
-done
-{ ac_configure_args0=; unset ac_configure_args0;}
-{ ac_configure_args1=; unset ac_configure_args1;}
-
-# When interrupted or exit'd, cleanup temporary files, and complete
-# config.log. We remove comments because anyway the quotes in there
-# would cause problems or look ugly.
-# WARNING: Use '\'' to represent an apostrophe within the trap.
-# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
-trap 'exit_status=$?
- # Save into config.log some information that might help in debugging.
- {
- echo
-
- $as_echo "## ---------------- ##
-## Cache variables. ##
-## ---------------- ##"
- echo
- # The following way of writing the cache mishandles newlines in values,
-(
- for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
- eval ac_val=\$$ac_var
- case $ac_val in #(
- *${as_nl}*)
- case $ac_var in #(
- *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
-$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
- esac
- case $ac_var in #(
- _ | IFS | as_nl) ;; #(
- BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
- *) { eval $ac_var=; unset $ac_var;} ;;
- esac ;;
- esac
- done
- (set) 2>&1 |
- case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
- *${as_nl}ac_space=\ *)
- sed -n \
- "s/'\''/'\''\\\\'\'''\''/g;
- s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
- ;; #(
- *)
- sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
- ;;
- esac |
- sort
-)
- echo
-
- $as_echo "## ----------------- ##
-## Output variables. ##
-## ----------------- ##"
- echo
- for ac_var in $ac_subst_vars
- do
- eval ac_val=\$$ac_var
- case $ac_val in
- *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
- esac
- $as_echo "$ac_var='\''$ac_val'\''"
- done | sort
- echo
-
- if test -n "$ac_subst_files"; then
- $as_echo "## ------------------- ##
-## File substitutions. ##
-## ------------------- ##"
- echo
- for ac_var in $ac_subst_files
- do
- eval ac_val=\$$ac_var
- case $ac_val in
- *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
- esac
- $as_echo "$ac_var='\''$ac_val'\''"
- done | sort
- echo
- fi
-
- if test -s confdefs.h; then
- $as_echo "## ----------- ##
-## confdefs.h. ##
-## ----------- ##"
- echo
- cat confdefs.h
- echo
- fi
- test "$ac_signal" != 0 &&
- $as_echo "$as_me: caught signal $ac_signal"
- $as_echo "$as_me: exit $exit_status"
- } >&5
- rm -f core *.core core.conftest.* &&
- rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
- exit $exit_status
-' 0
-for ac_signal in 1 2 13 15; do
- trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
-done
-ac_signal=0
-
-# confdefs.h avoids OS command line length limits that DEFS can exceed.
-rm -f -r conftest* confdefs.h
-
-$as_echo "/* confdefs.h */" > confdefs.h
-
-# Predefined preprocessor variables.
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_NAME "$PACKAGE_NAME"
-_ACEOF
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
-_ACEOF
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_VERSION "$PACKAGE_VERSION"
-_ACEOF
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_STRING "$PACKAGE_STRING"
-_ACEOF
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
-_ACEOF
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_URL "$PACKAGE_URL"
-_ACEOF
-
-
-# Let the site file select an alternate cache file if it wants to.
-# Prefer an explicitly selected file to automatically selected ones.
-ac_site_file1=NONE
-ac_site_file2=NONE
-if test -n "$CONFIG_SITE"; then
- # We do not want a PATH search for config.site.
- case $CONFIG_SITE in #((
- -*) ac_site_file1=./$CONFIG_SITE;;
- */*) ac_site_file1=$CONFIG_SITE;;
- *) ac_site_file1=./$CONFIG_SITE;;
- esac
-elif test "x$prefix" != xNONE; then
- ac_site_file1=$prefix/share/config.site
- ac_site_file2=$prefix/etc/config.site
-else
- ac_site_file1=$ac_default_prefix/share/config.site
- ac_site_file2=$ac_default_prefix/etc/config.site
-fi
-for ac_site_file in "$ac_site_file1" "$ac_site_file2"
-do
- test "x$ac_site_file" = xNONE && continue
- if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
-$as_echo "$as_me: loading site script $ac_site_file" >&6;}
- sed 's/^/| /' "$ac_site_file" >&5
- . "$ac_site_file" \
- || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "failed to load site script $ac_site_file
-See \`config.log' for more details" "$LINENO" 5; }
- fi
-done
-
-if test -r "$cache_file"; then
- # Some versions of bash will fail to source /dev/null (special files
- # actually), so we avoid doing that. DJGPP emulates it as a regular file.
- if test /dev/null != "$cache_file" && test -f "$cache_file"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
-$as_echo "$as_me: loading cache $cache_file" >&6;}
- case $cache_file in
- [\\/]* | ?:[\\/]* ) . "$cache_file";;
- *) . "./$cache_file";;
- esac
- fi
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
-$as_echo "$as_me: creating cache $cache_file" >&6;}
- >$cache_file
-fi
-
-gt_needs="$gt_needs "
-# Check that the precious variables saved in the cache have kept the same
-# value.
-ac_cache_corrupted=false
-for ac_var in $ac_precious_vars; do
- eval ac_old_set=\$ac_cv_env_${ac_var}_set
- eval ac_new_set=\$ac_env_${ac_var}_set
- eval ac_old_val=\$ac_cv_env_${ac_var}_value
- eval ac_new_val=\$ac_env_${ac_var}_value
- case $ac_old_set,$ac_new_set in
- set,)
- { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
-$as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
- ac_cache_corrupted=: ;;
- ,set)
- { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
-$as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
- ac_cache_corrupted=: ;;
- ,);;
- *)
- if test "x$ac_old_val" != "x$ac_new_val"; then
- # differences in whitespace do not lead to failure.
- ac_old_val_w=`echo x $ac_old_val`
- ac_new_val_w=`echo x $ac_new_val`
- if test "$ac_old_val_w" != "$ac_new_val_w"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
-$as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
- ac_cache_corrupted=:
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
-$as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
- eval $ac_var=\$ac_old_val
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
-$as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
-$as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
- fi;;
- esac
- # Pass precious variables to config.status.
- if test "$ac_new_set" = set; then
- case $ac_new_val in
- *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
- *) ac_arg=$ac_var=$ac_new_val ;;
- esac
- case " $ac_configure_args " in
- *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
- *) as_fn_append ac_configure_args " '$ac_arg'" ;;
- esac
- fi
-done
-if $ac_cache_corrupted; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
-$as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
- as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
-fi
-## -------------------- ##
-## Main body of script. ##
-## -------------------- ##
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-
-
-
-
-
-
-ac_aux_dir=
-for ac_dir in .. "$srcdir"/..; do
- if test -f "$ac_dir/install-sh"; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install-sh -c"
- break
- elif test -f "$ac_dir/install.sh"; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install.sh -c"
- break
- elif test -f "$ac_dir/shtool"; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/shtool install -c"
- break
- fi
-done
-if test -z "$ac_aux_dir"; then
- as_fn_error $? "cannot find install-sh, install.sh, or shtool in .. \"$srcdir\"/.." "$LINENO" 5
-fi
-
-# These three variables are undocumented and unsupported,
-# and are intended to be withdrawn in a future Autoconf release.
-# They can cause serious problems if a builder's source tree is in a directory
-# whose full name contains unusual characters.
-ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
-ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
-ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
-
-
-# Make sure we can run config.sub.
-$SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
- as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
-$as_echo_n "checking build system type... " >&6; }
-if ${ac_cv_build+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_build_alias=$build_alias
-test "x$ac_build_alias" = x &&
- ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
-test "x$ac_build_alias" = x &&
- as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
-ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
- as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
-$as_echo "$ac_cv_build" >&6; }
-case $ac_cv_build in
-*-*-*) ;;
-*) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
-esac
-build=$ac_cv_build
-ac_save_IFS=$IFS; IFS='-'
-set x $ac_cv_build
-shift
-build_cpu=$1
-build_vendor=$2
-shift; shift
-# Remember, the first character of IFS is used to create $*,
-# except with old shells:
-build_os=$*
-IFS=$ac_save_IFS
-case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
-$as_echo_n "checking host system type... " >&6; }
-if ${ac_cv_host+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test "x$host_alias" = x; then
- ac_cv_host=$ac_cv_build
-else
- ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
- as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
-$as_echo "$ac_cv_host" >&6; }
-case $ac_cv_host in
-*-*-*) ;;
-*) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
-esac
-host=$ac_cv_host
-ac_save_IFS=$IFS; IFS='-'
-set x $ac_cv_host
-shift
-host_cpu=$1
-host_vendor=$2
-shift; shift
-# Remember, the first character of IFS is used to create $*,
-# except with old shells:
-host_os=$*
-IFS=$ac_save_IFS
-case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking target system type" >&5
-$as_echo_n "checking target system type... " >&6; }
-if ${ac_cv_target+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test "x$target_alias" = x; then
- ac_cv_target=$ac_cv_host
-else
- ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` ||
- as_fn_error $? "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5
-$as_echo "$ac_cv_target" >&6; }
-case $ac_cv_target in
-*-*-*) ;;
-*) as_fn_error $? "invalid value of canonical target" "$LINENO" 5;;
-esac
-target=$ac_cv_target
-ac_save_IFS=$IFS; IFS='-'
-set x $ac_cv_target
-shift
-target_cpu=$1
-target_vendor=$2
-shift; shift
-# Remember, the first character of IFS is used to create $*,
-# except with old shells:
-target_os=$*
-IFS=$ac_save_IFS
-case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac
-
-
-# The aliases save the names the user supplied, while $host etc.
-# will get canonicalized.
-test -n "$target_alias" &&
- test "$program_prefix$program_suffix$program_transform_name" = \
- NONENONEs,x,x, &&
- program_prefix=${target_alias}-
-
-am__api_version='1.15'
-
-# Find a good install program. We prefer a C program (faster),
-# so one script is as good as another. But avoid the broken or
-# incompatible versions:
-# SysV /etc/install, /usr/sbin/install
-# SunOS /usr/etc/install
-# IRIX /sbin/install
-# AIX /bin/install
-# AmigaOS /C/install, which installs bootblocks on floppy discs
-# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
-# AFS /usr/afsws/bin/install, which mishandles nonexistent args
-# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
-# OS/2's system install, which has a completely different semantic
-# ./install, which can be erroneously created by make from ./install.sh.
-# Reject install programs that cannot install multiple files.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
-$as_echo_n "checking for a BSD-compatible install... " >&6; }
-if test -z "$INSTALL"; then
-if ${ac_cv_path_install+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- # Account for people who put trailing slashes in PATH elements.
-case $as_dir/ in #((
- ./ | .// | /[cC]/* | \
- /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
- ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
- /usr/ucb/* ) ;;
- *)
- # OSF1 and SCO ODT 3.0 have their own names for install.
- # Don't use installbsd from OSF since it installs stuff as root
- # by default.
- for ac_prog in ginstall scoinst install; do
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
- if test $ac_prog = install &&
- grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
- # AIX install. It has an incompatible calling convention.
- :
- elif test $ac_prog = install &&
- grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
- # program-specific install script used by HP pwplus--don't use.
- :
- else
- rm -rf conftest.one conftest.two conftest.dir
- echo one > conftest.one
- echo two > conftest.two
- mkdir conftest.dir
- if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
- test -s conftest.one && test -s conftest.two &&
- test -s conftest.dir/conftest.one &&
- test -s conftest.dir/conftest.two
- then
- ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
- break 3
- fi
- fi
- fi
- done
- done
- ;;
-esac
-
- done
-IFS=$as_save_IFS
-
-rm -rf conftest.one conftest.two conftest.dir
-
-fi
- if test "${ac_cv_path_install+set}" = set; then
- INSTALL=$ac_cv_path_install
- else
- # As a last resort, use the slow shell script. Don't cache a
- # value for INSTALL within a source directory, because that will
- # break other packages using the cache if that directory is
- # removed, or if the value is a relative name.
- INSTALL=$ac_install_sh
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
-$as_echo "$INSTALL" >&6; }
-
-# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
-# It thinks the first close brace ends the variable substitution.
-test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
-
-test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
-
-test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5
-$as_echo_n "checking whether build environment is sane... " >&6; }
-# Reject unsafe characters in $srcdir or the absolute working directory
-# name. Accept space and tab only in the latter.
-am_lf='
-'
-case `pwd` in
- *[\\\"\#\$\&\'\`$am_lf]*)
- as_fn_error $? "unsafe absolute working directory name" "$LINENO" 5;;
-esac
-case $srcdir in
- *[\\\"\#\$\&\'\`$am_lf\ \ ]*)
- as_fn_error $? "unsafe srcdir value: '$srcdir'" "$LINENO" 5;;
-esac
-
-# Do 'set' in a subshell so we don't clobber the current shell's
-# arguments. Must try -L first in case configure is actually a
-# symlink; some systems play weird games with the mod time of symlinks
-# (eg FreeBSD returns the mod time of the symlink's containing
-# directory).
-if (
- am_has_slept=no
- for am_try in 1 2; do
- echo "timestamp, slept: $am_has_slept" > conftest.file
- set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
- if test "$*" = "X"; then
- # -L didn't work.
- set X `ls -t "$srcdir/configure" conftest.file`
- fi
- if test "$*" != "X $srcdir/configure conftest.file" \
- && test "$*" != "X conftest.file $srcdir/configure"; then
-
- # If neither matched, then we have a broken ls. This can happen
- # if, for instance, CONFIG_SHELL is bash and it inherits a
- # broken ls alias from the environment. This has actually
- # happened. Such a system could not be considered "sane".
- as_fn_error $? "ls -t appears to fail. Make sure there is not a broken
- alias in your environment" "$LINENO" 5
- fi
- if test "$2" = conftest.file || test $am_try -eq 2; then
- break
- fi
- # Just in case.
- sleep 1
- am_has_slept=yes
- done
- test "$2" = conftest.file
- )
-then
- # Ok.
- :
-else
- as_fn_error $? "newly created file is older than distributed files!
-Check your system clock" "$LINENO" 5
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-# If we didn't sleep, we still need to ensure time stamps of config.status and
-# generated files are strictly newer.
-am_sleep_pid=
-if grep 'slept: no' conftest.file >/dev/null 2>&1; then
- ( sleep 1 ) &
- am_sleep_pid=$!
-fi
-
-rm -f conftest.file
-
-test "$program_prefix" != NONE &&
- program_transform_name="s&^&$program_prefix&;$program_transform_name"
-# Use a double $ so make ignores it.
-test "$program_suffix" != NONE &&
- program_transform_name="s&\$&$program_suffix&;$program_transform_name"
-# Double any \ or $.
-# By default was `s,x,x', remove it if useless.
-ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
-program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
-
-# Expand $ac_aux_dir to an absolute path.
-am_aux_dir=`cd "$ac_aux_dir" && pwd`
-
-if test x"${MISSING+set}" != xset; then
- case $am_aux_dir in
- *\ * | *\ *)
- MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
- *)
- MISSING="\${SHELL} $am_aux_dir/missing" ;;
- esac
-fi
-# Use eval to expand $SHELL
-if eval "$MISSING --is-lightweight"; then
- am_missing_run="$MISSING "
-else
- am_missing_run=
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: 'missing' script is too old or missing" >&5
-$as_echo "$as_me: WARNING: 'missing' script is too old or missing" >&2;}
-fi
-
-if test x"${install_sh+set}" != xset; then
- case $am_aux_dir in
- *\ * | *\ *)
- install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
- *)
- install_sh="\${SHELL} $am_aux_dir/install-sh"
- esac
-fi
-
-# Installed binaries are usually stripped using 'strip' when the user
-# run "make install-strip". However 'strip' might not be the right
-# tool to use in cross-compilation environments, therefore Automake
-# will honor the 'STRIP' environment variable to overrule this program.
-if test "$cross_compiling" != no; then
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
-set dummy ${ac_tool_prefix}strip; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_STRIP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$STRIP"; then
- ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_STRIP="${ac_tool_prefix}strip"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-STRIP=$ac_cv_prog_STRIP
-if test -n "$STRIP"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
-$as_echo "$STRIP" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_STRIP"; then
- ac_ct_STRIP=$STRIP
- # Extract the first word of "strip", so it can be a program name with args.
-set dummy strip; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_STRIP"; then
- ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_STRIP="strip"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
-if test -n "$ac_ct_STRIP"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
-$as_echo "$ac_ct_STRIP" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_STRIP" = x; then
- STRIP=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- STRIP=$ac_ct_STRIP
- fi
-else
- STRIP="$ac_cv_prog_STRIP"
-fi
-
-fi
-INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5
-$as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
-if test -z "$MKDIR_P"; then
- if ${ac_cv_path_mkdir+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_prog in mkdir gmkdir; do
- for ac_exec_ext in '' $ac_executable_extensions; do
- as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext" || continue
- case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
- 'mkdir (GNU coreutils) '* | \
- 'mkdir (coreutils) '* | \
- 'mkdir (fileutils) '4.1*)
- ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
- break 3;;
- esac
- done
- done
- done
-IFS=$as_save_IFS
-
-fi
-
- test -d ./--version && rmdir ./--version
- if test "${ac_cv_path_mkdir+set}" = set; then
- MKDIR_P="$ac_cv_path_mkdir -p"
- else
- # As a last resort, use the slow shell script. Don't cache a
- # value for MKDIR_P within a source directory, because that will
- # break other packages using the cache if that directory is
- # removed, or if the value is a relative name.
- MKDIR_P="$ac_install_sh -d"
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
-$as_echo "$MKDIR_P" >&6; }
-
-for ac_prog in gawk mawk nawk awk
-do
- # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_AWK+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$AWK"; then
- ac_cv_prog_AWK="$AWK" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_AWK="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-AWK=$ac_cv_prog_AWK
-if test -n "$AWK"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
-$as_echo "$AWK" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$AWK" && break
-done
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
-$as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
-set x ${MAKE-make}
-ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
-if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat >conftest.make <<\_ACEOF
-SHELL = /bin/sh
-all:
- @echo '@@@%%%=$(MAKE)=@@@%%%'
-_ACEOF
-# GNU make sometimes prints "make[1]: Entering ...", which would confuse us.
-case `${MAKE-make} -f conftest.make 2>/dev/null` in
- *@@@%%%=?*=@@@%%%*)
- eval ac_cv_prog_make_${ac_make}_set=yes;;
- *)
- eval ac_cv_prog_make_${ac_make}_set=no;;
-esac
-rm -f conftest.make
-fi
-if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- SET_MAKE=
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- SET_MAKE="MAKE=${MAKE-make}"
-fi
-
-rm -rf .tst 2>/dev/null
-mkdir .tst 2>/dev/null
-if test -d .tst; then
- am__leading_dot=.
-else
- am__leading_dot=_
-fi
-rmdir .tst 2>/dev/null
-
-# Check whether --enable-silent-rules was given.
-if test "${enable_silent_rules+set}" = set; then :
- enableval=$enable_silent_rules;
-fi
-
-case $enable_silent_rules in # (((
- yes) AM_DEFAULT_VERBOSITY=0;;
- no) AM_DEFAULT_VERBOSITY=1;;
- *) AM_DEFAULT_VERBOSITY=1;;
-esac
-am_make=${MAKE-make}
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5
-$as_echo_n "checking whether $am_make supports nested variables... " >&6; }
-if ${am_cv_make_support_nested_variables+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if $as_echo 'TRUE=$(BAR$(V))
-BAR0=false
-BAR1=true
-V=1
-am__doit:
- @$(TRUE)
-.PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then
- am_cv_make_support_nested_variables=yes
-else
- am_cv_make_support_nested_variables=no
-fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5
-$as_echo "$am_cv_make_support_nested_variables" >&6; }
-if test $am_cv_make_support_nested_variables = yes; then
- AM_V='$(V)'
- AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
-else
- AM_V=$AM_DEFAULT_VERBOSITY
- AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY
-fi
-AM_BACKSLASH='\'
-
-if test "`cd $srcdir && pwd`" != "`pwd`"; then
- # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
- # is not polluted with repeated "-I."
- am__isrc=' -I$(srcdir)'
- # test to see if srcdir already configured
- if test -f $srcdir/config.status; then
- as_fn_error $? "source directory already configured; run \"make distclean\" there first" "$LINENO" 5
- fi
-fi
-
-# test whether we have cygpath
-if test -z "$CYGPATH_W"; then
- if (cygpath --version) >/dev/null 2>/dev/null; then
- CYGPATH_W='cygpath -w'
- else
- CYGPATH_W=echo
- fi
-fi
-
-
-# Define the identity of the package.
- PACKAGE='gas'
- VERSION='2.43.1'
-
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE "$PACKAGE"
-_ACEOF
-
-
-cat >>confdefs.h <<_ACEOF
-#define VERSION "$VERSION"
-_ACEOF
-
-# Some tools Automake needs.
-
-ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"}
-
-
-AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
-
-
-AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"}
-
-
-AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
-
-
-MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
-
-# For better backward compatibility. To be removed once Automake 1.9.x
-# dies out for good. For more background, see:
-# <http://lists.gnu.org/archive/html/automake/2012-07/msg00001.html>
-# <http://lists.gnu.org/archive/html/automake/2012-07/msg00014.html>
-mkdir_p='$(MKDIR_P)'
-
-# We need awk for the "check" target (and possibly the TAP driver). The
-# system "awk" is bad on some platforms.
-# Always define AMTAR for backward compatibility. Yes, it's still used
-# in the wild :-( We should find a proper way to deprecate it ...
-AMTAR='$${TAR-tar}'
-
-
-# We'll loop over all known methods to create a tar archive until one works.
-_am_tools='gnutar pax cpio none'
-
-am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -'
-
-
-
-
-
-
-# POSIX will say in a future version that running "rm -f" with no argument
-# is OK; and we want to be able to make that assumption in our Makefile
-# recipes. So use an aggressive probe to check that the usage we want is
-# actually supported "in the wild" to an acceptable degree.
-# See automake bug#10828.
-# To make any issue more visible, cause the running configure to be aborted
-# by default if the 'rm' program in use doesn't match our expectations; the
-# user can still override this though.
-if rm -f && rm -fr && rm -rf; then : OK; else
- cat >&2 <<'END'
-Oops!
-
-Your 'rm' program seems unable to run without file operands specified
-on the command line, even when the '-f' option is present. This is contrary
-to the behaviour of most rm programs out there, and not conforming with
-the upcoming POSIX standard: <http://austingroupbugs.net/view.php?id=542>
-
-Please tell bug-automake@gnu.org about your system, including the value
-of your $PATH and any error possibly output before this message. This
-can help us improve future automake versions.
-
-END
- if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then
- echo 'Configuration will proceed anyway, since you have set the' >&2
- echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2
- echo >&2
- else
- cat >&2 <<'END'
-Aborting the configuration process, to ensure you take notice of the issue.
-
-You can download and install GNU coreutils to get an 'rm' implementation
-that behaves properly: <http://www.gnu.org/software/coreutils/>.
-
-If you want to complete the configuration process using your problematic
-'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM
-to "yes", and re-run configure.
-
-END
- as_fn_error $? "Your 'rm' program is bad, sorry." "$LINENO" 5
- fi
-fi
-
-# Check whether --enable-silent-rules was given.
-if test "${enable_silent_rules+set}" = set; then :
- enableval=$enable_silent_rules;
-fi
-
-case $enable_silent_rules in # (((
- yes) AM_DEFAULT_VERBOSITY=0;;
- no) AM_DEFAULT_VERBOSITY=1;;
- *) AM_DEFAULT_VERBOSITY=0;;
-esac
-am_make=${MAKE-make}
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5
-$as_echo_n "checking whether $am_make supports nested variables... " >&6; }
-if ${am_cv_make_support_nested_variables+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if $as_echo 'TRUE=$(BAR$(V))
-BAR0=false
-BAR1=true
-V=1
-am__doit:
- @$(TRUE)
-.PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then
- am_cv_make_support_nested_variables=yes
-else
- am_cv_make_support_nested_variables=no
-fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5
-$as_echo "$am_cv_make_support_nested_variables" >&6; }
-if test $am_cv_make_support_nested_variables = yes; then
- AM_V='$(V)'
- AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
-else
- AM_V=$AM_DEFAULT_VERBOSITY
- AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY
-fi
-AM_BACKSLASH='\'
-
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
-set dummy ${ac_tool_prefix}gcc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_CC="${ac_tool_prefix}gcc"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
-$as_echo "$CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_CC"; then
- ac_ct_CC=$CC
- # Extract the first word of "gcc", so it can be a program name with args.
-set dummy gcc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_CC"; then
- ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_CC="gcc"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_CC=$ac_cv_prog_ac_ct_CC
-if test -n "$ac_ct_CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
-$as_echo "$ac_ct_CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_CC" = x; then
- CC=""
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- CC=$ac_ct_CC
- fi
-else
- CC="$ac_cv_prog_CC"
-fi
-
-if test -z "$CC"; then
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
-set dummy ${ac_tool_prefix}cc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_CC="${ac_tool_prefix}cc"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
-$as_echo "$CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
-fi
-if test -z "$CC"; then
- # Extract the first word of "cc", so it can be a program name with args.
-set dummy cc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
- ac_prog_rejected=no
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
- ac_prog_rejected=yes
- continue
- fi
- ac_cv_prog_CC="cc"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-if test $ac_prog_rejected = yes; then
- # We found a bogon in the path, so make sure we never use it.
- set dummy $ac_cv_prog_CC
- shift
- if test $# != 0; then
- # We chose a different compiler from the bogus one.
- # However, it has the same basename, so the bogon will be chosen
- # first if we set CC to just the basename; use the full file name.
- shift
- ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
- fi
-fi
-fi
-fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
-$as_echo "$CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$CC"; then
- if test -n "$ac_tool_prefix"; then
- for ac_prog in cl.exe
- do
- # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
-set dummy $ac_tool_prefix$ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
-$as_echo "$CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$CC" && break
- done
-fi
-if test -z "$CC"; then
- ac_ct_CC=$CC
- for ac_prog in cl.exe
-do
- # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_CC"; then
- ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_CC="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_CC=$ac_cv_prog_ac_ct_CC
-if test -n "$ac_ct_CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
-$as_echo "$ac_ct_CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$ac_ct_CC" && break
-done
-
- if test "x$ac_ct_CC" = x; then
- CC=""
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- CC=$ac_ct_CC
- fi
-fi
-
-fi
-
-
-test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "no acceptable C compiler found in \$PATH
-See \`config.log' for more details" "$LINENO" 5; }
-
-# Provide some information about the compiler.
-$as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
-set X $ac_compile
-ac_compiler=$2
-for ac_option in --version -v -V -qversion; do
- { { ac_try="$ac_compiler $ac_option >&5"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_compiler $ac_option >&5") 2>conftest.err
- ac_status=$?
- if test -s conftest.err; then
- sed '10a\
-... rest of stderr output deleted ...
- 10q' conftest.err >conftest.er1
- cat conftest.er1 >&5
- fi
- rm -f conftest.er1 conftest.err
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }
-done
-
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-ac_clean_files_save=$ac_clean_files
-ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
-# Try to create an executable without -o first, disregard a.out.
-# It will help us diagnose broken compilers, and finding out an intuition
-# of exeext.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
-$as_echo_n "checking whether the C compiler works... " >&6; }
-ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
-
-# The possible output files:
-ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
-
-ac_rmfiles=
-for ac_file in $ac_files
-do
- case $ac_file in
- *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
- * ) ac_rmfiles="$ac_rmfiles $ac_file";;
- esac
-done
-rm -f $ac_rmfiles
-
-if { { ac_try="$ac_link_default"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_link_default") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then :
- # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
-# So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
-# in a Makefile. We should not override ac_cv_exeext if it was cached,
-# so that the user can short-circuit this test for compilers unknown to
-# Autoconf.
-for ac_file in $ac_files ''
-do
- test -f "$ac_file" || continue
- case $ac_file in
- *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
- ;;
- [ab].out )
- # We found the default executable, but exeext='' is most
- # certainly right.
- break;;
- *.* )
- if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
- then :; else
- ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
- fi
- # We set ac_cv_exeext here because the later test for it is not
- # safe: cross compilers may not add the suffix if given an `-o'
- # argument, so we may need to know it at that point already.
- # Even if this section looks crufty: it has the advantage of
- # actually working.
- break;;
- * )
- break;;
- esac
-done
-test "$ac_cv_exeext" = no && ac_cv_exeext=
-
-else
- ac_file=''
-fi
-if test -z "$ac_file"; then :
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-$as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error 77 "C compiler cannot create executables
-See \`config.log' for more details" "$LINENO" 5; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
-$as_echo_n "checking for C compiler default output file name... " >&6; }
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
-$as_echo "$ac_file" >&6; }
-ac_exeext=$ac_cv_exeext
-
-rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
-ac_clean_files=$ac_clean_files_save
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
-$as_echo_n "checking for suffix of executables... " >&6; }
-if { { ac_try="$ac_link"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_link") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then :
- # If both `conftest.exe' and `conftest' are `present' (well, observable)
-# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
-# work properly (i.e., refer to `conftest.exe'), while it won't with
-# `rm'.
-for ac_file in conftest.exe conftest conftest.*; do
- test -f "$ac_file" || continue
- case $ac_file in
- *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
- *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
- break;;
- * ) break;;
- esac
-done
-else
- { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "cannot compute suffix of executables: cannot compile and link
-See \`config.log' for more details" "$LINENO" 5; }
-fi
-rm -f conftest conftest$ac_cv_exeext
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
-$as_echo "$ac_cv_exeext" >&6; }
-
-rm -f conftest.$ac_ext
-EXEEXT=$ac_cv_exeext
-ac_exeext=$EXEEXT
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <stdio.h>
-int
-main ()
-{
-FILE *f = fopen ("conftest.out", "w");
- return ferror (f) || fclose (f) != 0;
-
- ;
- return 0;
-}
-_ACEOF
-ac_clean_files="$ac_clean_files conftest.out"
-# Check that the compiler produces executables we can run. If not, either
-# the compiler is broken, or we cross compile.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
-$as_echo_n "checking whether we are cross compiling... " >&6; }
-if test "$cross_compiling" != yes; then
- { { ac_try="$ac_link"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_link") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }
- if { ac_try='./conftest$ac_cv_exeext'
- { { case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_try") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; }; then
- cross_compiling=no
- else
- if test "$cross_compiling" = maybe; then
- cross_compiling=yes
- else
- { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "cannot run C compiled programs.
-If you meant to cross compile, use \`--host'.
-See \`config.log' for more details" "$LINENO" 5; }
- fi
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
-$as_echo "$cross_compiling" >&6; }
-
-rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
-ac_clean_files=$ac_clean_files_save
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
-$as_echo_n "checking for suffix of object files... " >&6; }
-if ${ac_cv_objext+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-rm -f conftest.o conftest.obj
-if { { ac_try="$ac_compile"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_compile") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then :
- for ac_file in conftest.o conftest.obj conftest.*; do
- test -f "$ac_file" || continue;
- case $ac_file in
- *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
- *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
- break;;
- esac
-done
-else
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "cannot compute suffix of object files: cannot compile
-See \`config.log' for more details" "$LINENO" 5; }
-fi
-rm -f conftest.$ac_cv_objext conftest.$ac_ext
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
-$as_echo "$ac_cv_objext" >&6; }
-OBJEXT=$ac_cv_objext
-ac_objext=$OBJEXT
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
-$as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
-if ${ac_cv_c_compiler_gnu+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-#ifndef __GNUC__
- choke me
-#endif
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_compiler_gnu=yes
-else
- ac_compiler_gnu=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-ac_cv_c_compiler_gnu=$ac_compiler_gnu
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
-$as_echo "$ac_cv_c_compiler_gnu" >&6; }
-if test $ac_compiler_gnu = yes; then
- GCC=yes
-else
- GCC=
-fi
-ac_test_CFLAGS=${CFLAGS+set}
-ac_save_CFLAGS=$CFLAGS
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
-$as_echo_n "checking whether $CC accepts -g... " >&6; }
-if ${ac_cv_prog_cc_g+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_save_c_werror_flag=$ac_c_werror_flag
- ac_c_werror_flag=yes
- ac_cv_prog_cc_g=no
- CFLAGS="-g"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_prog_cc_g=yes
-else
- CFLAGS=""
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
-
-else
- ac_c_werror_flag=$ac_save_c_werror_flag
- CFLAGS="-g"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_prog_cc_g=yes
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- ac_c_werror_flag=$ac_save_c_werror_flag
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
-$as_echo "$ac_cv_prog_cc_g" >&6; }
-if test "$ac_test_CFLAGS" = set; then
- CFLAGS=$ac_save_CFLAGS
-elif test $ac_cv_prog_cc_g = yes; then
- if test "$GCC" = yes; then
- CFLAGS="-g -O2"
- else
- CFLAGS="-g"
- fi
-else
- if test "$GCC" = yes; then
- CFLAGS="-O2"
- else
- CFLAGS=
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
-$as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
-if ${ac_cv_prog_cc_c89+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_cv_prog_cc_c89=no
-ac_save_CC=$CC
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <stdarg.h>
-#include <stdio.h>
-struct stat;
-/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
-struct buf { int x; };
-FILE * (*rcsopen) (struct buf *, struct stat *, int);
-static char *e (p, i)
- char **p;
- int i;
-{
- return p[i];
-}
-static char *f (char * (*g) (char **, int), char **p, ...)
-{
- char *s;
- va_list v;
- va_start (v,p);
- s = g (p, va_arg (v,int));
- va_end (v);
- return s;
-}
-
-/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
- function prototypes and stuff, but not '\xHH' hex character constants.
- These don't provoke an error unfortunately, instead are silently treated
- as 'x'. The following induces an error, until -std is added to get
- proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
- array size at least. It's necessary to write '\x00'==0 to get something
- that's true only with -std. */
-int osf4_cc_array ['\x00' == 0 ? 1 : -1];
-
-/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
- inside strings and character constants. */
-#define FOO(x) 'x'
-int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
-
-int test (int i, double x);
-struct s1 {int (*f) (int a);};
-struct s2 {int (*f) (double a);};
-int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
-int argc;
-char **argv;
-int
-main ()
-{
-return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
- ;
- return 0;
-}
-_ACEOF
-for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
- -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
-do
- CC="$ac_save_CC $ac_arg"
- if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_prog_cc_c89=$ac_arg
-fi
-rm -f core conftest.err conftest.$ac_objext
- test "x$ac_cv_prog_cc_c89" != "xno" && break
-done
-rm -f conftest.$ac_ext
-CC=$ac_save_CC
-
-fi
-# AC_CACHE_VAL
-case "x$ac_cv_prog_cc_c89" in
- x)
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
-$as_echo "none needed" >&6; } ;;
- xno)
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
-$as_echo "unsupported" >&6; } ;;
- *)
- CC="$CC $ac_cv_prog_cc_c89"
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
-$as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
-esac
-if test "x$ac_cv_prog_cc_c89" != xno; then :
-
-fi
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC understands -c and -o together" >&5
-$as_echo_n "checking whether $CC understands -c and -o together... " >&6; }
-if ${am_cv_prog_cc_c_o+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
- # Make sure it works both with $CC and with simple cc.
- # Following AC_PROG_CC_C_O, we do the test twice because some
- # compilers refuse to overwrite an existing .o file with -o,
- # though they will create one.
- am_cv_prog_cc_c_o=yes
- for am_i in 1 2; do
- if { echo "$as_me:$LINENO: $CC -c conftest.$ac_ext -o conftest2.$ac_objext" >&5
- ($CC -c conftest.$ac_ext -o conftest2.$ac_objext) >&5 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } \
- && test -f conftest2.$ac_objext; then
- : OK
- else
- am_cv_prog_cc_c_o=no
- break
- fi
- done
- rm -f core conftest*
- unset am_i
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_cc_c_o" >&5
-$as_echo "$am_cv_prog_cc_c_o" >&6; }
-if test "$am_cv_prog_cc_c_o" != yes; then
- # Losing compiler, so override with the script.
- # FIXME: It is wrong to rewrite CC.
- # But if we don't then we get into trouble of one sort or another.
- # A longer-term fix would be to have automake use am__CC in this case,
- # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
- CC="$am_aux_dir/compile $CC"
-fi
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-DEPDIR="${am__leading_dot}deps"
-
-ac_config_commands="$ac_config_commands depfiles"
-
-
-am_make=${MAKE-make}
-cat > confinc << 'END'
-am__doit:
- @echo this is the am__doit target
-.PHONY: am__doit
-END
-# If we don't find an include directive, just comment out the code.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5
-$as_echo_n "checking for style of include used by $am_make... " >&6; }
-am__include="#"
-am__quote=
-_am_result=none
-# First try GNU make style include.
-echo "include confinc" > confmf
-# Ignore all kinds of additional output from 'make'.
-case `$am_make -s -f confmf 2> /dev/null` in #(
-*the\ am__doit\ target*)
- am__include=include
- am__quote=
- _am_result=GNU
- ;;
-esac
-# Now try BSD make style include.
-if test "$am__include" = "#"; then
- echo '.include "confinc"' > confmf
- case `$am_make -s -f confmf 2> /dev/null` in #(
- *the\ am__doit\ target*)
- am__include=.include
- am__quote="\""
- _am_result=BSD
- ;;
- esac
-fi
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5
-$as_echo "$_am_result" >&6; }
-rm -f confinc confmf
-
-# Check whether --enable-dependency-tracking was given.
-if test "${enable_dependency_tracking+set}" = set; then :
- enableval=$enable_dependency_tracking;
-fi
-
-if test "x$enable_dependency_tracking" != xno; then
- am_depcomp="$ac_aux_dir/depcomp"
- AMDEPBACKSLASH='\'
- am__nodep='_no'
-fi
- if test "x$enable_dependency_tracking" != xno; then
- AMDEP_TRUE=
- AMDEP_FALSE='#'
-else
- AMDEP_TRUE='#'
- AMDEP_FALSE=
-fi
-
-
-
-depcc="$CC" am_compiler_list=
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
-$as_echo_n "checking dependency style of $depcc... " >&6; }
-if ${am_cv_CC_dependencies_compiler_type+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
- # We make a subdir and do the tests there. Otherwise we can end up
- # making bogus files that we don't know about and never remove. For
- # instance it was reported that on HP-UX the gcc test will end up
- # making a dummy file named 'D' -- because '-MD' means "put the output
- # in D".
- rm -rf conftest.dir
- mkdir conftest.dir
- # Copy depcomp to subdir because otherwise we won't find it if we're
- # using a relative directory.
- cp "$am_depcomp" conftest.dir
- cd conftest.dir
- # We will build objects and dependencies in a subdirectory because
- # it helps to detect inapplicable dependency modes. For instance
- # both Tru64's cc and ICC support -MD to output dependencies as a
- # side effect of compilation, but ICC will put the dependencies in
- # the current directory while Tru64 will put them in the object
- # directory.
- mkdir sub
-
- am_cv_CC_dependencies_compiler_type=none
- if test "$am_compiler_list" = ""; then
- am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
- fi
- am__universal=false
- case " $depcc " in #(
- *\ -arch\ *\ -arch\ *) am__universal=true ;;
- esac
-
- for depmode in $am_compiler_list; do
- # Setup a source with many dependencies, because some compilers
- # like to wrap large dependency lists on column 80 (with \), and
- # we should not choose a depcomp mode which is confused by this.
- #
- # We need to recreate these files for each test, as the compiler may
- # overwrite some of them when testing with obscure command lines.
- # This happens at least with the AIX C compiler.
- : > sub/conftest.c
- for i in 1 2 3 4 5 6; do
- echo '#include "conftst'$i'.h"' >> sub/conftest.c
- # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with
- # Solaris 10 /bin/sh.
- echo '/* dummy */' > sub/conftst$i.h
- done
- echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
-
- # We check with '-c' and '-o' for the sake of the "dashmstdout"
- # mode. It turns out that the SunPro C++ compiler does not properly
- # handle '-M -o', and we need to detect this. Also, some Intel
- # versions had trouble with output in subdirs.
- am__obj=sub/conftest.${OBJEXT-o}
- am__minus_obj="-o $am__obj"
- case $depmode in
- gcc)
- # This depmode causes a compiler race in universal mode.
- test "$am__universal" = false || continue
- ;;
- nosideeffect)
- # After this tag, mechanisms are not by side-effect, so they'll
- # only be used when explicitly requested.
- if test "x$enable_dependency_tracking" = xyes; then
- continue
- else
- break
- fi
- ;;
- msvc7 | msvc7msys | msvisualcpp | msvcmsys)
- # This compiler won't grok '-c -o', but also, the minuso test has
- # not run yet. These depmodes are late enough in the game, and
- # so weak that their functioning should not be impacted.
- am__obj=conftest.${OBJEXT-o}
- am__minus_obj=
- ;;
- none) break ;;
- esac
- if depmode=$depmode \
- source=sub/conftest.c object=$am__obj \
- depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
- $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
- >/dev/null 2>conftest.err &&
- grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
- grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
- grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
- ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
- # icc doesn't choke on unknown options, it will just issue warnings
- # or remarks (even with -Werror). So we grep stderr for any message
- # that says an option was ignored or not supported.
- # When given -MP, icc 7.0 and 7.1 complain thusly:
- # icc: Command line warning: ignoring option '-M'; no argument required
- # The diagnosis changed in icc 8.0:
- # icc: Command line remark: option '-MP' not supported
- if (grep 'ignoring option' conftest.err ||
- grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
- am_cv_CC_dependencies_compiler_type=$depmode
- break
- fi
- fi
- done
-
- cd ..
- rm -rf conftest.dir
-else
- am_cv_CC_dependencies_compiler_type=none
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
-$as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
-CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
-
- if
- test "x$enable_dependency_tracking" != xno \
- && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
- am__fastdepCC_TRUE=
- am__fastdepCC_FALSE='#'
-else
- am__fastdepCC_TRUE='#'
- am__fastdepCC_FALSE=
-fi
-
-
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
-$as_echo_n "checking how to run the C preprocessor... " >&6; }
-# On Suns, sometimes $CPP names a directory.
-if test -n "$CPP" && test -d "$CPP"; then
- CPP=
-fi
-if test -z "$CPP"; then
- if ${ac_cv_prog_CPP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- # Double quotes because CPP needs to be expanded
- for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
- do
- ac_preproc_ok=false
-for ac_c_preproc_warn_flag in '' yes
-do
- # Use a header file that comes with gcc, so configuring glibc
- # with a fresh cross-compiler works.
- # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
- # <limits.h> exists even on freestanding compilers.
- # On the NeXT, cc -E runs the code through the compiler's parser,
- # not just through cpp. "Syntax error" is here to catch this case.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#ifdef __STDC__
-# include <limits.h>
-#else
-# include <assert.h>
-#endif
- Syntax error
-_ACEOF
-if ac_fn_c_try_cpp "$LINENO"; then :
-
-else
- # Broken: fails on valid input.
-continue
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-
- # OK, works on sane cases. Now check whether nonexistent headers
- # can be detected and how.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <ac_nonexistent.h>
-_ACEOF
-if ac_fn_c_try_cpp "$LINENO"; then :
- # Broken: success on invalid input.
-continue
-else
- # Passes both tests.
-ac_preproc_ok=:
-break
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-
-done
-# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
-rm -f conftest.i conftest.err conftest.$ac_ext
-if $ac_preproc_ok; then :
- break
-fi
-
- done
- ac_cv_prog_CPP=$CPP
-
-fi
- CPP=$ac_cv_prog_CPP
-else
- ac_cv_prog_CPP=$CPP
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
-$as_echo "$CPP" >&6; }
-ac_preproc_ok=false
-for ac_c_preproc_warn_flag in '' yes
-do
- # Use a header file that comes with gcc, so configuring glibc
- # with a fresh cross-compiler works.
- # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
- # <limits.h> exists even on freestanding compilers.
- # On the NeXT, cc -E runs the code through the compiler's parser,
- # not just through cpp. "Syntax error" is here to catch this case.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#ifdef __STDC__
-# include <limits.h>
-#else
-# include <assert.h>
-#endif
- Syntax error
-_ACEOF
-if ac_fn_c_try_cpp "$LINENO"; then :
-
-else
- # Broken: fails on valid input.
-continue
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-
- # OK, works on sane cases. Now check whether nonexistent headers
- # can be detected and how.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <ac_nonexistent.h>
-_ACEOF
-if ac_fn_c_try_cpp "$LINENO"; then :
- # Broken: success on invalid input.
-continue
-else
- # Passes both tests.
-ac_preproc_ok=:
-break
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-
-done
-# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
-rm -f conftest.i conftest.err conftest.$ac_ext
-if $ac_preproc_ok; then :
-
-else
- { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
-See \`config.log' for more details" "$LINENO" 5; }
-fi
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
-$as_echo_n "checking for grep that handles long lines and -e... " >&6; }
-if ${ac_cv_path_GREP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -z "$GREP"; then
- ac_path_GREP_found=false
- # Loop through the user's path and test for each of PROGNAME-LIST
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_prog in grep ggrep; do
- for ac_exec_ext in '' $ac_executable_extensions; do
- ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
- as_fn_executable_p "$ac_path_GREP" || continue
-# Check for GNU ac_path_GREP and select it if it is found.
- # Check for GNU $ac_path_GREP
-case `"$ac_path_GREP" --version 2>&1` in
-*GNU*)
- ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
-*)
- ac_count=0
- $as_echo_n 0123456789 >"conftest.in"
- while :
- do
- cat "conftest.in" "conftest.in" >"conftest.tmp"
- mv "conftest.tmp" "conftest.in"
- cp "conftest.in" "conftest.nl"
- $as_echo 'GREP' >> "conftest.nl"
- "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
- diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
- as_fn_arith $ac_count + 1 && ac_count=$as_val
- if test $ac_count -gt ${ac_path_GREP_max-0}; then
- # Best one so far, save it but keep looking for a better one
- ac_cv_path_GREP="$ac_path_GREP"
- ac_path_GREP_max=$ac_count
- fi
- # 10*(2^10) chars as input seems more than enough
- test $ac_count -gt 10 && break
- done
- rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
-esac
-
- $ac_path_GREP_found && break 3
- done
- done
- done
-IFS=$as_save_IFS
- if test -z "$ac_cv_path_GREP"; then
- as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
- fi
-else
- ac_cv_path_GREP=$GREP
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
-$as_echo "$ac_cv_path_GREP" >&6; }
- GREP="$ac_cv_path_GREP"
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
-$as_echo_n "checking for egrep... " >&6; }
-if ${ac_cv_path_EGREP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
- then ac_cv_path_EGREP="$GREP -E"
- else
- if test -z "$EGREP"; then
- ac_path_EGREP_found=false
- # Loop through the user's path and test for each of PROGNAME-LIST
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_prog in egrep; do
- for ac_exec_ext in '' $ac_executable_extensions; do
- ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
- as_fn_executable_p "$ac_path_EGREP" || continue
-# Check for GNU ac_path_EGREP and select it if it is found.
- # Check for GNU $ac_path_EGREP
-case `"$ac_path_EGREP" --version 2>&1` in
-*GNU*)
- ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
-*)
- ac_count=0
- $as_echo_n 0123456789 >"conftest.in"
- while :
- do
- cat "conftest.in" "conftest.in" >"conftest.tmp"
- mv "conftest.tmp" "conftest.in"
- cp "conftest.in" "conftest.nl"
- $as_echo 'EGREP' >> "conftest.nl"
- "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
- diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
- as_fn_arith $ac_count + 1 && ac_count=$as_val
- if test $ac_count -gt ${ac_path_EGREP_max-0}; then
- # Best one so far, save it but keep looking for a better one
- ac_cv_path_EGREP="$ac_path_EGREP"
- ac_path_EGREP_max=$ac_count
- fi
- # 10*(2^10) chars as input seems more than enough
- test $ac_count -gt 10 && break
- done
- rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
-esac
-
- $ac_path_EGREP_found && break 3
- done
- done
- done
-IFS=$as_save_IFS
- if test -z "$ac_cv_path_EGREP"; then
- as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
- fi
-else
- ac_cv_path_EGREP=$EGREP
-fi
-
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
-$as_echo "$ac_cv_path_EGREP" >&6; }
- EGREP="$ac_cv_path_EGREP"
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
-$as_echo_n "checking for ANSI C header files... " >&6; }
-if ${ac_cv_header_stdc+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <stdlib.h>
-#include <stdarg.h>
-#include <string.h>
-#include <float.h>
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_header_stdc=yes
-else
- ac_cv_header_stdc=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-
-if test $ac_cv_header_stdc = yes; then
- # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <string.h>
-
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "memchr" >/dev/null 2>&1; then :
-
-else
- ac_cv_header_stdc=no
-fi
-rm -f conftest*
-
-fi
-
-if test $ac_cv_header_stdc = yes; then
- # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <stdlib.h>
-
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "free" >/dev/null 2>&1; then :
-
-else
- ac_cv_header_stdc=no
-fi
-rm -f conftest*
-
-fi
-
-if test $ac_cv_header_stdc = yes; then
- # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
- if test "$cross_compiling" = yes; then :
- :
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <ctype.h>
-#include <stdlib.h>
-#if ((' ' & 0x0FF) == 0x020)
-# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
-# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
-#else
-# define ISLOWER(c) \
- (('a' <= (c) && (c) <= 'i') \
- || ('j' <= (c) && (c) <= 'r') \
- || ('s' <= (c) && (c) <= 'z'))
-# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
-#endif
-
-#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
-int
-main ()
-{
- int i;
- for (i = 0; i < 256; i++)
- if (XOR (islower (i), ISLOWER (i))
- || toupper (i) != TOUPPER (i))
- return 2;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_run "$LINENO"; then :
-
-else
- ac_cv_header_stdc=no
-fi
-rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
- conftest.$ac_objext conftest.beam conftest.$ac_ext
-fi
-
-fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
-$as_echo "$ac_cv_header_stdc" >&6; }
-if test $ac_cv_header_stdc = yes; then
-
-$as_echo "#define STDC_HEADERS 1" >>confdefs.h
-
-fi
-
-# On IRIX 5.3, sys/types and inttypes.h are conflicting.
-for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
- inttypes.h stdint.h unistd.h
-do :
- as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
-ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
-"
-if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
- cat >>confdefs.h <<_ACEOF
-#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
-_ACEOF
-
-fi
-
-done
-
-
-
- ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
-if test "x$ac_cv_header_minix_config_h" = xyes; then :
- MINIX=yes
-else
- MINIX=
-fi
-
-
- if test "$MINIX" = yes; then
-
-$as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
-
-
-$as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
-
-
-$as_echo "#define _MINIX 1" >>confdefs.h
-
- fi
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
-$as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
-if ${ac_cv_safe_to_define___extensions__+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-# define __EXTENSIONS__ 1
- $ac_includes_default
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_safe_to_define___extensions__=yes
-else
- ac_cv_safe_to_define___extensions__=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
-$as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
- test $ac_cv_safe_to_define___extensions__ = yes &&
- $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
-
- $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
-
- $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
-
- $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
-
- $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
-
-
-
-case `pwd` in
- *\ * | *\ *)
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&5
-$as_echo "$as_me: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&2;} ;;
-esac
-
-
-
-macro_version='2.2.7a'
-macro_revision='1.3134'
-
-
-
-
-
-
-
-
-
-
-
-
-
-ltmain="$ac_aux_dir/ltmain.sh"
-
-# Backslashify metacharacters that are still active within
-# double-quoted strings.
-sed_quote_subst='s/\(["`$\\]\)/\\\1/g'
-
-# Same as above, but do not quote variable references.
-double_quote_subst='s/\(["`\\]\)/\\\1/g'
-
-# Sed substitution to delay expansion of an escaped shell variable in a
-# double_quote_subst'ed string.
-delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
-
-# Sed substitution to delay expansion of an escaped single quote.
-delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g'
-
-# Sed substitution to avoid accidental globbing in evaled expressions
-no_glob_subst='s/\*/\\\*/g'
-
-ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
-ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO
-ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5
-$as_echo_n "checking how to print strings... " >&6; }
-# Test print first, because it will be a builtin if present.
-if test "X`print -r -- -n 2>/dev/null`" = X-n && \
- test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
- ECHO='print -r --'
-elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
- ECHO='printf %s\n'
-else
- # Use this function as a fallback that always works.
- func_fallback_echo ()
- {
- eval 'cat <<_LTECHO_EOF
-$1
-_LTECHO_EOF'
- }
- ECHO='func_fallback_echo'
-fi
-
-# func_echo_all arg...
-# Invoke $ECHO with all args, space-separated.
-func_echo_all ()
-{
- $ECHO ""
-}
-
-case "$ECHO" in
- printf*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: printf" >&5
-$as_echo "printf" >&6; } ;;
- print*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: print -r" >&5
-$as_echo "print -r" >&6; } ;;
- *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: cat" >&5
-$as_echo "cat" >&6; } ;;
-esac
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
-$as_echo_n "checking for a sed that does not truncate output... " >&6; }
-if ${ac_cv_path_SED+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
- for ac_i in 1 2 3 4 5 6 7; do
- ac_script="$ac_script$as_nl$ac_script"
- done
- echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
- { ac_script=; unset ac_script;}
- if test -z "$SED"; then
- ac_path_SED_found=false
- # Loop through the user's path and test for each of PROGNAME-LIST
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_prog in sed gsed; do
- for ac_exec_ext in '' $ac_executable_extensions; do
- ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
- as_fn_executable_p "$ac_path_SED" || continue
-# Check for GNU ac_path_SED and select it if it is found.
- # Check for GNU $ac_path_SED
-case `"$ac_path_SED" --version 2>&1` in
-*GNU*)
- ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
-*)
- ac_count=0
- $as_echo_n 0123456789 >"conftest.in"
- while :
- do
- cat "conftest.in" "conftest.in" >"conftest.tmp"
- mv "conftest.tmp" "conftest.in"
- cp "conftest.in" "conftest.nl"
- $as_echo '' >> "conftest.nl"
- "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
- diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
- as_fn_arith $ac_count + 1 && ac_count=$as_val
- if test $ac_count -gt ${ac_path_SED_max-0}; then
- # Best one so far, save it but keep looking for a better one
- ac_cv_path_SED="$ac_path_SED"
- ac_path_SED_max=$ac_count
- fi
- # 10*(2^10) chars as input seems more than enough
- test $ac_count -gt 10 && break
- done
- rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
-esac
-
- $ac_path_SED_found && break 3
- done
- done
- done
-IFS=$as_save_IFS
- if test -z "$ac_cv_path_SED"; then
- as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
- fi
-else
- ac_cv_path_SED=$SED
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
-$as_echo "$ac_cv_path_SED" >&6; }
- SED="$ac_cv_path_SED"
- rm -f conftest.sed
-
-test -z "$SED" && SED=sed
-Xsed="$SED -e 1s/^X//"
-
-
-
-
-
-
-
-
-
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5
-$as_echo_n "checking for fgrep... " >&6; }
-if ${ac_cv_path_FGREP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1
- then ac_cv_path_FGREP="$GREP -F"
- else
- if test -z "$FGREP"; then
- ac_path_FGREP_found=false
- # Loop through the user's path and test for each of PROGNAME-LIST
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_prog in fgrep; do
- for ac_exec_ext in '' $ac_executable_extensions; do
- ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext"
- as_fn_executable_p "$ac_path_FGREP" || continue
-# Check for GNU ac_path_FGREP and select it if it is found.
- # Check for GNU $ac_path_FGREP
-case `"$ac_path_FGREP" --version 2>&1` in
-*GNU*)
- ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;;
-*)
- ac_count=0
- $as_echo_n 0123456789 >"conftest.in"
- while :
- do
- cat "conftest.in" "conftest.in" >"conftest.tmp"
- mv "conftest.tmp" "conftest.in"
- cp "conftest.in" "conftest.nl"
- $as_echo 'FGREP' >> "conftest.nl"
- "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break
- diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
- as_fn_arith $ac_count + 1 && ac_count=$as_val
- if test $ac_count -gt ${ac_path_FGREP_max-0}; then
- # Best one so far, save it but keep looking for a better one
- ac_cv_path_FGREP="$ac_path_FGREP"
- ac_path_FGREP_max=$ac_count
- fi
- # 10*(2^10) chars as input seems more than enough
- test $ac_count -gt 10 && break
- done
- rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
-esac
-
- $ac_path_FGREP_found && break 3
- done
- done
- done
-IFS=$as_save_IFS
- if test -z "$ac_cv_path_FGREP"; then
- as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
- fi
-else
- ac_cv_path_FGREP=$FGREP
-fi
-
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5
-$as_echo "$ac_cv_path_FGREP" >&6; }
- FGREP="$ac_cv_path_FGREP"
-
-
-test -z "$GREP" && GREP=grep
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-# Check whether --with-gnu-ld was given.
-if test "${with_gnu_ld+set}" = set; then :
- withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
-else
- with_gnu_ld=no
-fi
-
-ac_prog=ld
-if test "$GCC" = yes; then
- # Check if gcc -print-prog-name=ld gives a path.
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5
-$as_echo_n "checking for ld used by $CC... " >&6; }
- case $host in
- *-*-mingw*)
- # gcc leaves a trailing carriage return which upsets mingw
- ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
- *)
- ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
- esac
- case $ac_prog in
- # Accept absolute paths.
- [\\/]* | ?:[\\/]*)
- re_direlt='/[^/][^/]*/\.\./'
- # Canonicalize the pathname of ld
- ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'`
- while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do
- ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"`
- done
- test -z "$LD" && LD="$ac_prog"
- ;;
- "")
- # If it fails, then pretend we aren't using GCC.
- ac_prog=ld
- ;;
- *)
- # If it is relative, then search for the first ld in PATH.
- with_gnu_ld=unknown
- ;;
- esac
-elif test "$with_gnu_ld" = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
-$as_echo_n "checking for GNU ld... " >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
-$as_echo_n "checking for non-GNU ld... " >&6; }
-fi
-if ${lt_cv_path_LD+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -z "$LD"; then
- lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH; do
- IFS="$lt_save_ifs"
- test -z "$ac_dir" && ac_dir=.
- if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
- lt_cv_path_LD="$ac_dir/$ac_prog"
- # Check to see if the program is GNU ld. I'd rather use --version,
- # but apparently some variants of GNU ld only accept -v.
- # Break only if it was the GNU/non-GNU ld that we prefer.
- case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
- *GNU* | *'with BFD'*)
- test "$with_gnu_ld" != no && break
- ;;
- *)
- test "$with_gnu_ld" != yes && break
- ;;
- esac
- fi
- done
- IFS="$lt_save_ifs"
-else
- lt_cv_path_LD="$LD" # Let the user override the test with a path.
-fi
-fi
-
-LD="$lt_cv_path_LD"
-if test -n "$LD"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
-$as_echo "$LD" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
-$as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
-if ${lt_cv_prog_gnu_ld+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- # I'd rather use --version here, but apparently some GNU lds only accept -v.
-case `$LD -v 2>&1 </dev/null` in
-*GNU* | *'with BFD'*)
- lt_cv_prog_gnu_ld=yes
- ;;
-*)
- lt_cv_prog_gnu_ld=no
- ;;
-esac
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_gnu_ld" >&5
-$as_echo "$lt_cv_prog_gnu_ld" >&6; }
-with_gnu_ld=$lt_cv_prog_gnu_ld
-
-
-
-
-
-
-
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for BSD- or MS-compatible name lister (nm)" >&5
-$as_echo_n "checking for BSD- or MS-compatible name lister (nm)... " >&6; }
-if ${lt_cv_path_NM+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$NM"; then
- # Let the user override the nm to test.
- lt_nm_to_check="$NM"
- else
- lt_nm_to_check="${ac_tool_prefix}nm"
- if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
- lt_nm_to_check="$lt_nm_to_check nm"
- fi
- fi
- for lt_tmp_nm in "$lt_nm_to_check"; do
- lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
- IFS="$lt_save_ifs"
- test -z "$ac_dir" && ac_dir=.
- # Strip out any user-provided options from the nm to test twice,
- # the first time to test to see if nm (rather than its options) has
- # an explicit path, the second time to yield a file which can be
- # nm'ed itself.
- tmp_nm_path="`$ECHO "$lt_tmp_nm" | sed 's, -.*$,,'`"
- case "$tmp_nm_path" in
- */*|*\\*) tmp_nm="$lt_tmp_nm";;
- *) tmp_nm="$ac_dir/$lt_tmp_nm";;
- esac
- tmp_nm_to_nm="`$ECHO "$tmp_nm" | sed 's, -.*$,,'`"
- if test -f "$tmp_nm_to_nm" || test -f "$tmp_nm_to_nm$ac_exeext" ; then
- # Check to see if the nm accepts a BSD-compat flag.
- # Adding the `sed 1q' prevents false positives on HP-UX, which says:
- # nm: unknown option "B" ignored
- case `"$tmp_nm" -B "$tmp_nm_to_nm" 2>&1 | grep -v '^ *$' | sed '1q'` in
- *$tmp_nm*) lt_cv_path_NM="$tmp_nm -B"
- break
- ;;
- *)
- case `"$tmp_nm" -p "$tmp_nm_to_nm" 2>&1 | grep -v '^ *$' | sed '1q'` in
- *$tmp_nm*)
- lt_cv_path_NM="$tmp_nm -p"
- break
- ;;
- *)
- lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
- continue # so that we can try to find one that supports BSD flags
- ;;
- esac
- ;;
- esac
- fi
- done
- IFS="$lt_save_ifs"
- done
- : ${lt_cv_path_NM=no}
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_NM" >&5
-$as_echo "$lt_cv_path_NM" >&6; }
-if test "$lt_cv_path_NM" != "no"; then
- NM="$lt_cv_path_NM"
-else
- # Didn't find any BSD compatible name lister, look for dumpbin.
- if test -n "$DUMPBIN"; then :
- # Let the user override the test.
- else
- if test -n "$ac_tool_prefix"; then
- for ac_prog in dumpbin "link -dump"
- do
- # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
-set dummy $ac_tool_prefix$ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_DUMPBIN+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$DUMPBIN"; then
- ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_DUMPBIN="$ac_tool_prefix$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-DUMPBIN=$ac_cv_prog_DUMPBIN
-if test -n "$DUMPBIN"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5
-$as_echo "$DUMPBIN" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$DUMPBIN" && break
- done
-fi
-if test -z "$DUMPBIN"; then
- ac_ct_DUMPBIN=$DUMPBIN
- for ac_prog in dumpbin "link -dump"
-do
- # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_DUMPBIN+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_DUMPBIN"; then
- ac_cv_prog_ac_ct_DUMPBIN="$ac_ct_DUMPBIN" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_DUMPBIN="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_DUMPBIN=$ac_cv_prog_ac_ct_DUMPBIN
-if test -n "$ac_ct_DUMPBIN"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DUMPBIN" >&5
-$as_echo "$ac_ct_DUMPBIN" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$ac_ct_DUMPBIN" && break
-done
-
- if test "x$ac_ct_DUMPBIN" = x; then
- DUMPBIN=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- DUMPBIN=$ac_ct_DUMPBIN
- fi
-fi
-
- case `$DUMPBIN -symbols /dev/null 2>&1 | sed '1q'` in
- *COFF*)
- DUMPBIN="$DUMPBIN -symbols"
- ;;
- *)
- DUMPBIN=:
- ;;
- esac
- fi
-
- if test "$DUMPBIN" != ":"; then
- NM="$DUMPBIN"
- fi
-fi
-test -z "$NM" && NM=nm
-
-
-
-
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the name lister ($NM) interface" >&5
-$as_echo_n "checking the name lister ($NM) interface... " >&6; }
-if ${lt_cv_nm_interface+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_nm_interface="BSD nm"
- echo "int some_variable = 0;" > conftest.$ac_ext
- (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&5)
- (eval "$ac_compile" 2>conftest.err)
- cat conftest.err >&5
- (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&5)
- (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out)
- cat conftest.err >&5
- (eval echo "\"\$as_me:$LINENO: output\"" >&5)
- cat conftest.out >&5
- if $GREP 'External.*some_variable' conftest.out > /dev/null; then
- lt_cv_nm_interface="MS dumpbin"
- fi
- rm -f conftest*
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_nm_interface" >&5
-$as_echo "$lt_cv_nm_interface" >&6; }
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
-$as_echo_n "checking whether ln -s works... " >&6; }
-LN_S=$as_ln_s
-if test "$LN_S" = "ln -s"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
-$as_echo "no, using $LN_S" >&6; }
-fi
-
-# find the maximum length of command line arguments
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the maximum length of command line arguments" >&5
-$as_echo_n "checking the maximum length of command line arguments... " >&6; }
-if ${lt_cv_sys_max_cmd_len+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- i=0
- teststring="ABCD"
-
- case $build_os in
- msdosdjgpp*)
- # On DJGPP, this test can blow up pretty badly due to problems in libc
- # (any single argument exceeding 2000 bytes causes a buffer overrun
- # during glob expansion). Even if it were fixed, the result of this
- # check would be larger than it should be.
- lt_cv_sys_max_cmd_len=12288; # 12K is about right
- ;;
-
- gnu*)
- # Under GNU Hurd, this test is not required because there is
- # no limit to the length of command line arguments.
- # Libtool will interpret -1 as no limit whatsoever
- lt_cv_sys_max_cmd_len=-1;
- ;;
-
- cygwin* | mingw* | cegcc*)
- # On Win9x/ME, this test blows up -- it succeeds, but takes
- # about 5 minutes as the teststring grows exponentially.
- # Worse, since 9x/ME are not pre-emptively multitasking,
- # you end up with a "frozen" computer, even though with patience
- # the test eventually succeeds (with a max line length of 256k).
- # Instead, let's just punt: use the minimum linelength reported by
- # all of the supported platforms: 8192 (on NT/2K/XP).
- lt_cv_sys_max_cmd_len=8192;
- ;;
-
- mint*)
- # On MiNT this can take a long time and run out of memory.
- lt_cv_sys_max_cmd_len=8192;
- ;;
-
- amigaos*)
- # On AmigaOS with pdksh, this test takes hours, literally.
- # So we just punt and use a minimum line length of 8192.
- lt_cv_sys_max_cmd_len=8192;
- ;;
-
- netbsd* | freebsd* | openbsd* | darwin* | dragonfly*)
- # This has been around since 386BSD, at least. Likely further.
- if test -x /sbin/sysctl; then
- lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
- elif test -x /usr/sbin/sysctl; then
- lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
- else
- lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs
- fi
- # And add a safety zone
- lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
- lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
- ;;
-
- interix*)
- # We know the value 262144 and hardcode it with a safety zone (like BSD)
- lt_cv_sys_max_cmd_len=196608
- ;;
-
- osf*)
- # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
- # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
- # nice to cause kernel panics so lets avoid the loop below.
- # First set a reasonable default.
- lt_cv_sys_max_cmd_len=16384
- #
- if test -x /sbin/sysconfig; then
- case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
- *1*) lt_cv_sys_max_cmd_len=-1 ;;
- esac
- fi
- ;;
- sco3.2v5*)
- lt_cv_sys_max_cmd_len=102400
- ;;
- sysv5* | sco5v6* | sysv4.2uw2*)
- kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
- if test -n "$kargmax"; then
- lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[ ]//'`
- else
- lt_cv_sys_max_cmd_len=32768
- fi
- ;;
- *)
- lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null`
- if test -n "$lt_cv_sys_max_cmd_len"; then
- lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
- lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
- else
- # Make teststring a little bigger before we do anything with it.
- # a 1K string should be a reasonable start.
- for i in 1 2 3 4 5 6 7 8 ; do
- teststring=$teststring$teststring
- done
- SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
- # If test is not a shell built-in, we'll probably end up computing a
- # maximum length that is only half of the actual maximum length, but
- # we can't tell.
- while { test "X"`func_fallback_echo "$teststring$teststring" 2>/dev/null` \
- = "X$teststring$teststring"; } >/dev/null 2>&1 &&
- test $i != 17 # 1/2 MB should be enough
- do
- i=`expr $i + 1`
- teststring=$teststring$teststring
- done
- # Only check the string length outside the loop.
- lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1`
- teststring=
- # Add a significant safety factor because C++ compilers can tack on
- # massive amounts of additional arguments before passing them to the
- # linker. It appears as though 1/2 is a usable value.
- lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
- fi
- ;;
- esac
-
-fi
-
-if test -n $lt_cv_sys_max_cmd_len ; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sys_max_cmd_len" >&5
-$as_echo "$lt_cv_sys_max_cmd_len" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: none" >&5
-$as_echo "none" >&6; }
-fi
-max_cmd_len=$lt_cv_sys_max_cmd_len
-
-
-
-
-
-
-: ${CP="cp -f"}
-: ${MV="mv -f"}
-: ${RM="rm -f"}
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the shell understands some XSI constructs" >&5
-$as_echo_n "checking whether the shell understands some XSI constructs... " >&6; }
-# Try some XSI features
-xsi_shell=no
-( _lt_dummy="a/b/c"
- test "${_lt_dummy##*/},${_lt_dummy%/*},"${_lt_dummy%"$_lt_dummy"}, \
- = c,a/b,, \
- && eval 'test $(( 1 + 1 )) -eq 2 \
- && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \
- && xsi_shell=yes
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $xsi_shell" >&5
-$as_echo "$xsi_shell" >&6; }
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the shell understands \"+=\"" >&5
-$as_echo_n "checking whether the shell understands \"+=\"... " >&6; }
-lt_shell_append=no
-( foo=bar; set foo baz; eval "$1+=\$2" && test "$foo" = barbaz ) \
- >/dev/null 2>&1 \
- && lt_shell_append=yes
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_shell_append" >&5
-$as_echo "$lt_shell_append" >&6; }
-
-
-if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
- lt_unset=unset
-else
- lt_unset=false
-fi
-
-
-
-
-
-# test EBCDIC or ASCII
-case `echo X|tr X '\101'` in
- A) # ASCII based system
- # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr
- lt_SP2NL='tr \040 \012'
- lt_NL2SP='tr \015\012 \040\040'
- ;;
- *) # EBCDIC based system
- lt_SP2NL='tr \100 \n'
- lt_NL2SP='tr \r\n \100\100'
- ;;
-esac
-
-
-
-
-
-
-
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5
-$as_echo_n "checking for $LD option to reload object files... " >&6; }
-if ${lt_cv_ld_reload_flag+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_ld_reload_flag='-r'
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_reload_flag" >&5
-$as_echo "$lt_cv_ld_reload_flag" >&6; }
-reload_flag=$lt_cv_ld_reload_flag
-case $reload_flag in
-"" | " "*) ;;
-*) reload_flag=" $reload_flag" ;;
-esac
-reload_cmds='$LD$reload_flag -o $output$reload_objs'
-case $host_os in
- darwin*)
- if test "$GCC" = yes; then
- reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
- else
- reload_cmds='$LD$reload_flag -o $output$reload_objs'
- fi
- ;;
-esac
-
-
-
-
-
-
-
-
-
-if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args.
-set dummy ${ac_tool_prefix}objdump; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_OBJDUMP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$OBJDUMP"; then
- ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-OBJDUMP=$ac_cv_prog_OBJDUMP
-if test -n "$OBJDUMP"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
-$as_echo "$OBJDUMP" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_OBJDUMP"; then
- ac_ct_OBJDUMP=$OBJDUMP
- # Extract the first word of "objdump", so it can be a program name with args.
-set dummy objdump; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_OBJDUMP"; then
- ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_OBJDUMP="objdump"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP
-if test -n "$ac_ct_OBJDUMP"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5
-$as_echo "$ac_ct_OBJDUMP" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_OBJDUMP" = x; then
- OBJDUMP="false"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- OBJDUMP=$ac_ct_OBJDUMP
- fi
-else
- OBJDUMP="$ac_cv_prog_OBJDUMP"
-fi
-
-test -z "$OBJDUMP" && OBJDUMP=objdump
-
-
-
-
-
-
-
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to recognize dependent libraries" >&5
-$as_echo_n "checking how to recognize dependent libraries... " >&6; }
-if ${lt_cv_deplibs_check_method+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_file_magic_cmd='$MAGIC_CMD'
-lt_cv_file_magic_test_file=
-lt_cv_deplibs_check_method='unknown'
-# Need to set the preceding variable on all platforms that support
-# interlibrary dependencies.
-# 'none' -- dependencies not supported.
-# `unknown' -- same as none, but documents that we really don't know.
-# 'pass_all' -- all dependencies passed with no checks.
-# 'test_compile' -- check by making test program.
-# 'file_magic [[regex]]' -- check by looking for files in library path
-# which responds to the $file_magic_cmd with a given extended regex.
-# If you have `file' or equivalent on your system and you're not sure
-# whether `pass_all' will *always* work, you probably want this one.
-
-case $host_os in
-aix[4-9]*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-beos*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-bsdi[45]*)
- lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)'
- lt_cv_file_magic_cmd='/usr/bin/file -L'
- lt_cv_file_magic_test_file=/shlib/libc.so
- ;;
-
-cygwin*)
- # func_win32_libid is a shell function defined in ltmain.sh
- lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
- lt_cv_file_magic_cmd='func_win32_libid'
- ;;
-
-mingw* | pw32*)
- # Base MSYS/MinGW do not provide the 'file' command needed by
- # func_win32_libid shell function, so use a weaker test based on 'objdump',
- # unless we find 'file', for example because we are cross-compiling.
- # func_win32_libid assumes BSD nm, so disallow it if using MS dumpbin.
- if ( test "$lt_cv_nm_interface" = "BSD nm" && file / ) >/dev/null 2>&1; then
- lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
- lt_cv_file_magic_cmd='func_win32_libid'
- else
- lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
- lt_cv_file_magic_cmd='$OBJDUMP -f'
- fi
- ;;
-
-cegcc*)
- # use the weaker test based on 'objdump'. See mingw*.
- lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?'
- lt_cv_file_magic_cmd='$OBJDUMP -f'
- ;;
-
-darwin* | rhapsody*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-freebsd* | dragonfly*)
- if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
- case $host_cpu in
- i*86 )
- # Not sure whether the presence of OpenBSD here was a mistake.
- # Let's accept both of them until this is cleared up.
- lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library'
- lt_cv_file_magic_cmd=/usr/bin/file
- lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
- ;;
- esac
- else
- lt_cv_deplibs_check_method=pass_all
- fi
- ;;
-
-gnu*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-haiku*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-hpux10.20* | hpux11*)
- lt_cv_file_magic_cmd=/usr/bin/file
- case $host_cpu in
- ia64*)
- lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64'
- lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
- ;;
- hppa*64*)
- lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF[ -][0-9][0-9])(-bit)?( [LM]SB)? shared object( file)?[, -]* PA-RISC [0-9]\.[0-9]'
- lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
- ;;
- *)
- lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9]\.[0-9]) shared library'
- lt_cv_file_magic_test_file=/usr/lib/libc.sl
- ;;
- esac
- ;;
-
-interix[3-9]*)
- # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
- lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|\.a)$'
- ;;
-
-irix5* | irix6* | nonstopux*)
- case $LD in
- *-32|*"-32 ") libmagic=32-bit;;
- *-n32|*"-n32 ") libmagic=N32;;
- *-64|*"-64 ") libmagic=64-bit;;
- *) libmagic=never-match;;
- esac
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-# This must be Linux ELF.
-linux* | k*bsd*-gnu | kopensolaris*-gnu | uclinuxfdpiceabi)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-netbsd*)
- if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
- lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
- else
- lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$'
- fi
- ;;
-
-newos6*)
- lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)'
- lt_cv_file_magic_cmd=/usr/bin/file
- lt_cv_file_magic_test_file=/usr/lib/libnls.so
- ;;
-
-*nto* | *qnx*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-openbsd*)
- if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
- lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$'
- else
- lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
- fi
- ;;
-
-osf3* | osf4* | osf5*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-rdos*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-solaris*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-sysv4 | sysv4.3*)
- case $host_vendor in
- motorola)
- lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib) M[0-9][0-9]* Version [0-9]'
- lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
- ;;
- ncr)
- lt_cv_deplibs_check_method=pass_all
- ;;
- sequent)
- lt_cv_file_magic_cmd='/bin/file'
- lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )'
- ;;
- sni)
- lt_cv_file_magic_cmd='/bin/file'
- lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib"
- lt_cv_file_magic_test_file=/lib/libc.so
- ;;
- siemens)
- lt_cv_deplibs_check_method=pass_all
- ;;
- pc)
- lt_cv_deplibs_check_method=pass_all
- ;;
- esac
- ;;
-
-tpf*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-vxworks*)
- # Assume VxWorks cross toolchains are built on Linux, possibly
- # as canadian for Windows hosts.
- lt_cv_deplibs_check_method=pass_all
- ;;
-esac
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5
-$as_echo "$lt_cv_deplibs_check_method" >&6; }
-file_magic_cmd=$lt_cv_file_magic_cmd
-deplibs_check_method=$lt_cv_deplibs_check_method
-test -z "$deplibs_check_method" && deplibs_check_method=unknown
-
-
-
-
-
-
-
-
-
-
-
-
-plugin_option=
-plugin_names="liblto_plugin.so liblto_plugin-0.dll cyglto_plugin-0.dll"
-for plugin in $plugin_names; do
- plugin_so=`${CC} ${CFLAGS} --print-prog-name $plugin`
- if test x$plugin_so = x$plugin; then
- plugin_so=`${CC} ${CFLAGS} --print-file-name $plugin`
- fi
- if test x$plugin_so != x$plugin; then
- plugin_option="--plugin $plugin_so"
- break
- fi
-done
-
-if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
-set dummy ${ac_tool_prefix}ar; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_AR+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$AR"; then
- ac_cv_prog_AR="$AR" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_AR="${ac_tool_prefix}ar"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-AR=$ac_cv_prog_AR
-if test -n "$AR"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
-$as_echo "$AR" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_AR"; then
- ac_ct_AR=$AR
- # Extract the first word of "ar", so it can be a program name with args.
-set dummy ar; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_AR+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_AR"; then
- ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_AR="ar"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_AR=$ac_cv_prog_ac_ct_AR
-if test -n "$ac_ct_AR"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
-$as_echo "$ac_ct_AR" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_AR" = x; then
- AR="false"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- AR=$ac_ct_AR
- fi
-else
- AR="$ac_cv_prog_AR"
-fi
-
-test -z "$AR" && AR=ar
-if test -n "$plugin_option"; then
- if $AR --help 2>&1 | grep -q "\--plugin"; then
- touch conftest.c
- $AR $plugin_option rc conftest.a conftest.c
- if test "$?" != 0; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed: $AR $plugin_option rc" >&5
-$as_echo "$as_me: WARNING: Failed: $AR $plugin_option rc" >&2;}
- else
- AR="$AR $plugin_option"
- fi
- rm -f conftest.*
- fi
-fi
-test -z "$AR_FLAGS" && AR_FLAGS=cru
-
-
-
-
-
-
-
-
-
-
-
-if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
-set dummy ${ac_tool_prefix}strip; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_STRIP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$STRIP"; then
- ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_STRIP="${ac_tool_prefix}strip"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-STRIP=$ac_cv_prog_STRIP
-if test -n "$STRIP"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
-$as_echo "$STRIP" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_STRIP"; then
- ac_ct_STRIP=$STRIP
- # Extract the first word of "strip", so it can be a program name with args.
-set dummy strip; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_STRIP"; then
- ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_STRIP="strip"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
-if test -n "$ac_ct_STRIP"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
-$as_echo "$ac_ct_STRIP" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_STRIP" = x; then
- STRIP=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- STRIP=$ac_ct_STRIP
- fi
-else
- STRIP="$ac_cv_prog_STRIP"
-fi
-
-test -z "$STRIP" && STRIP=:
-
-
-
-
-
-
-if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
-set dummy ${ac_tool_prefix}ranlib; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_RANLIB+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$RANLIB"; then
- ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-RANLIB=$ac_cv_prog_RANLIB
-if test -n "$RANLIB"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
-$as_echo "$RANLIB" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_RANLIB"; then
- ac_ct_RANLIB=$RANLIB
- # Extract the first word of "ranlib", so it can be a program name with args.
-set dummy ranlib; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_RANLIB"; then
- ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_RANLIB="ranlib"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
-if test -n "$ac_ct_RANLIB"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
-$as_echo "$ac_ct_RANLIB" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_RANLIB" = x; then
- RANLIB=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- RANLIB=$ac_ct_RANLIB
- fi
-else
- RANLIB="$ac_cv_prog_RANLIB"
-fi
-
-test -z "$RANLIB" && RANLIB=:
-if test -n "$plugin_option" && test "$RANLIB" != ":"; then
- if $RANLIB --help 2>&1 | grep -q "\--plugin"; then
- RANLIB="$RANLIB $plugin_option"
- fi
-fi
-
-
-
-
-
-
-# Determine commands to create old-style static archives.
-old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs'
-old_postinstall_cmds='chmod 644 $oldlib'
-old_postuninstall_cmds=
-
-if test -n "$RANLIB"; then
- case $host_os in
- openbsd*)
- old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib"
- ;;
- *)
- old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib"
- ;;
- esac
- old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib"
-fi
-
-case $host_os in
- darwin*)
- lock_old_archive_extraction=yes ;;
- *)
- lock_old_archive_extraction=no ;;
-esac
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-# If no C compiler was specified, use CC.
-LTCC=${LTCC-"$CC"}
-
-# If no C compiler flags were specified, use CFLAGS.
-LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
-
-# Allow CC to be a program name with arguments.
-compiler=$CC
-
-
-# Check for command to grab the raw symbol name followed by C symbol from nm.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking command to parse $NM output from $compiler object" >&5
-$as_echo_n "checking command to parse $NM output from $compiler object... " >&6; }
-if ${lt_cv_sys_global_symbol_pipe+:} false; then :
- $as_echo_n "(cached) " >&6
-else
-
-# These are sane defaults that work on at least a few old systems.
-# [They come from Ultrix. What could be older than Ultrix?!! ;)]
-
-# Character class describing NM global symbol codes.
-symcode='[BCDEGRST]'
-
-# Regexp to match symbols that can be accessed directly from C.
-sympat='\([_A-Za-z][_A-Za-z0-9]*\)'
-
-# Define system-specific variables.
-case $host_os in
-aix*)
- symcode='[BCDT]'
- ;;
-cygwin* | mingw* | pw32* | cegcc*)
- symcode='[ABCDGISTW]'
- ;;
-hpux*)
- if test "$host_cpu" = ia64; then
- symcode='[ABCDEGRST]'
- fi
- ;;
-irix* | nonstopux*)
- symcode='[BCDEGRST]'
- ;;
-osf*)
- symcode='[BCDEGQRST]'
- ;;
-solaris*)
- symcode='[BCDRT]'
- ;;
-sco3.2v5*)
- symcode='[DT]'
- ;;
-sysv4.2uw2*)
- symcode='[DT]'
- ;;
-sysv5* | sco5v6* | unixware* | OpenUNIX*)
- symcode='[ABDT]'
- ;;
-sysv4)
- symcode='[DFNSTU]'
- ;;
-esac
-
-# If we're using GNU nm, then use its standard symbol codes.
-case `$NM -V 2>&1` in
-*GNU* | *'with BFD'*)
- symcode='[ABCDGIRSTW]' ;;
-esac
-
-# Transform an extracted symbol line into a proper C declaration.
-# Some systems (esp. on ia64) link data and code symbols differently,
-# so use this general approach.
-lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
-
-# Transform an extracted symbol line into symbol name and symbol address
-lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"\2\", (void *) \&\2},/p'"
-lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \(lib[^ ]*\)$/ {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"lib\2\", (void *) \&\2},/p'"
-
-# Handle CRLF in mingw tool chain
-opt_cr=
-case $build_os in
-mingw*)
- opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp
- ;;
-esac
-
-# Try without a prefix underscore, then with it.
-for ac_symprfx in "" "_"; do
-
- # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
- symxfrm="\\1 $ac_symprfx\\2 \\2"
-
- # Write the raw and C identifiers.
- if test "$lt_cv_nm_interface" = "MS dumpbin"; then
- # Fake it for dumpbin and say T for any non-static function
- # and D for any global variable.
- # Also find C++ and __fastcall symbols from MSVC++,
- # which start with @ or ?.
- lt_cv_sys_global_symbol_pipe="$AWK '"\
-" {last_section=section; section=\$ 3};"\
-" /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\
-" \$ 0!~/External *\|/{next};"\
-" / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\
-" {if(hide[section]) next};"\
-" {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\
-" {split(\$ 0, a, /\||\r/); split(a[2], s)};"\
-" s[1]~/^[@?]/{print s[1], s[1]; next};"\
-" s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\
-" ' prfx=^$ac_symprfx"
- else
- lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[ ]\($symcode$symcode*\)[ ][ ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
- fi
-
- # Check to see that the pipe works correctly.
- pipe_works=no
-
- rm -f conftest*
- cat > conftest.$ac_ext <<_LT_EOF
-#ifdef __cplusplus
-extern "C" {
-#endif
-char nm_test_var;
-void nm_test_func(void);
-void nm_test_func(void){}
-#ifdef __cplusplus
-}
-#endif
-int main(){nm_test_var='a';nm_test_func();return(0);}
-_LT_EOF
-
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
- (eval $ac_compile) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- # Now try to grab the symbols.
- nlist=conftest.nm
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist\""; } >&5
- (eval $NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && test -s "$nlist"; then
- # Try sorting and uniquifying the output.
- if sort "$nlist" | uniq > "$nlist"T; then
- mv -f "$nlist"T "$nlist"
- else
- rm -f "$nlist"T
- fi
-
- # Make sure that we snagged all the symbols we need.
- if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
- if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
- cat <<_LT_EOF > conftest.$ac_ext
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-_LT_EOF
- # Now generate the symbol file.
- eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext'
-
- cat <<_LT_EOF >> conftest.$ac_ext
-
-/* The mapping between symbol names and symbols. */
-const struct {
- const char *name;
- void *address;
-}
-lt__PROGRAM__LTX_preloaded_symbols[] =
-{
- { "@PROGRAM@", (void *) 0 },
-_LT_EOF
- $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext
- cat <<\_LT_EOF >> conftest.$ac_ext
- {0, (void *) 0}
-};
-
-/* This works around a problem in FreeBSD linker */
-#ifdef FREEBSD_WORKAROUND
-static const void *lt_preloaded_setup() {
- return lt__PROGRAM__LTX_preloaded_symbols;
-}
-#endif
-
-#ifdef __cplusplus
-}
-#endif
-_LT_EOF
- # Now try linking the two files.
- mv conftest.$ac_objext conftstm.$ac_objext
- lt_save_LIBS="$LIBS"
- lt_save_CFLAGS="$CFLAGS"
- LIBS="conftstm.$ac_objext"
- CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag"
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
- (eval $ac_link) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && test -s conftest${ac_exeext}; then
- pipe_works=yes
- fi
- LIBS="$lt_save_LIBS"
- CFLAGS="$lt_save_CFLAGS"
- else
- echo "cannot find nm_test_func in $nlist" >&5
- fi
- else
- echo "cannot find nm_test_var in $nlist" >&5
- fi
- else
- echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5
- fi
- else
- echo "$progname: failed program was:" >&5
- cat conftest.$ac_ext >&5
- fi
- rm -rf conftest* conftst*
-
- # Do not use the global_symbol_pipe unless it works.
- if test "$pipe_works" = yes; then
- break
- else
- lt_cv_sys_global_symbol_pipe=
- fi
-done
-
-fi
-
-if test -z "$lt_cv_sys_global_symbol_pipe"; then
- lt_cv_sys_global_symbol_to_cdecl=
-fi
-if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
-$as_echo "failed" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
-$as_echo "ok" >&6; }
-fi
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-# Check whether --enable-libtool-lock was given.
-if test "${enable_libtool_lock+set}" = set; then :
- enableval=$enable_libtool_lock;
-fi
-
-test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
-
-# Some flags need to be propagated to the compiler or linker for good
-# libtool support.
-case $host in
-ia64-*-hpux*)
- # Find out which ABI we are using.
- echo 'int i;' > conftest.$ac_ext
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
- (eval $ac_compile) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- case `/usr/bin/file conftest.$ac_objext` in
- *ELF-32*)
- HPUX_IA64_MODE="32"
- ;;
- *ELF-64*)
- HPUX_IA64_MODE="64"
- ;;
- esac
- fi
- rm -rf conftest*
- ;;
-*-*-irix6*)
- # Find out which ABI we are using.
- echo '#line '$LINENO' "configure"' > conftest.$ac_ext
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
- (eval $ac_compile) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- if test "$lt_cv_prog_gnu_ld" = yes; then
- case `/usr/bin/file conftest.$ac_objext` in
- *32-bit*)
- LD="${LD-ld} -melf32bsmip"
- ;;
- *N32*)
- LD="${LD-ld} -melf32bmipn32"
- ;;
- *64-bit*)
- LD="${LD-ld} -melf64bmip"
- ;;
- esac
- else
- case `/usr/bin/file conftest.$ac_objext` in
- *32-bit*)
- LD="${LD-ld} -32"
- ;;
- *N32*)
- LD="${LD-ld} -n32"
- ;;
- *64-bit*)
- LD="${LD-ld} -64"
- ;;
- esac
- fi
- fi
- rm -rf conftest*
- ;;
-
-x86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \
-s390*-*linux*|s390*-*tpf*|sparc*-*linux*)
- # Find out which ABI we are using.
- echo 'int i;' > conftest.$ac_ext
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
- (eval $ac_compile) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- case `/usr/bin/file conftest.o` in
- *32-bit*)
- case $host in
- x86_64-*kfreebsd*-gnu)
- LD="${LD-ld} -m elf_i386_fbsd"
- ;;
- x86_64-*linux*)
- case `/usr/bin/file conftest.o` in
- *x86-64*)
- LD="${LD-ld} -m elf32_x86_64"
- ;;
- *)
- LD="${LD-ld} -m elf_i386"
- ;;
- esac
- ;;
- powerpc64le-*linux*)
- LD="${LD-ld} -m elf32lppclinux"
- ;;
- powerpc64-*linux*)
- LD="${LD-ld} -m elf32ppclinux"
- ;;
- s390x-*linux*)
- LD="${LD-ld} -m elf_s390"
- ;;
- sparc64-*linux*)
- LD="${LD-ld} -m elf32_sparc"
- ;;
- esac
- ;;
- *64-bit*)
- case $host in
- x86_64-*kfreebsd*-gnu)
- LD="${LD-ld} -m elf_x86_64_fbsd"
- ;;
- x86_64-*linux*)
- LD="${LD-ld} -m elf_x86_64"
- ;;
- powerpcle-*linux*)
- LD="${LD-ld} -m elf64lppc"
- ;;
- powerpc-*linux*)
- LD="${LD-ld} -m elf64ppc"
- ;;
- s390*-*linux*|s390*-*tpf*)
- LD="${LD-ld} -m elf64_s390"
- ;;
- sparc*-*linux*)
- LD="${LD-ld} -m elf64_sparc"
- ;;
- esac
- ;;
- esac
- fi
- rm -rf conftest*
- ;;
-
-*-*-sco3.2v5*)
- # On SCO OpenServer 5, we need -belf to get full-featured binaries.
- SAVE_CFLAGS="$CFLAGS"
- CFLAGS="$CFLAGS -belf"
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler needs -belf" >&5
-$as_echo_n "checking whether the C compiler needs -belf... " >&6; }
-if ${lt_cv_cc_needs_belf+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- lt_cv_cc_needs_belf=yes
-else
- lt_cv_cc_needs_belf=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_cc_needs_belf" >&5
-$as_echo "$lt_cv_cc_needs_belf" >&6; }
- if test x"$lt_cv_cc_needs_belf" != x"yes"; then
- # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
- CFLAGS="$SAVE_CFLAGS"
- fi
- ;;
-sparc*-*solaris*)
- # Find out which ABI we are using.
- echo 'int i;' > conftest.$ac_ext
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
- (eval $ac_compile) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- case `/usr/bin/file conftest.o` in
- *64-bit*)
- case $lt_cv_prog_gnu_ld in
- yes*) LD="${LD-ld} -m elf64_sparc" ;;
- *)
- if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then
- LD="${LD-ld} -64"
- fi
- ;;
- esac
- ;;
- esac
- fi
- rm -rf conftest*
- ;;
-esac
-
-need_locks="$enable_libtool_lock"
-
-
- case $host_os in
- rhapsody* | darwin*)
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}dsymutil", so it can be a program name with args.
-set dummy ${ac_tool_prefix}dsymutil; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_DSYMUTIL+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$DSYMUTIL"; then
- ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_DSYMUTIL="${ac_tool_prefix}dsymutil"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-DSYMUTIL=$ac_cv_prog_DSYMUTIL
-if test -n "$DSYMUTIL"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5
-$as_echo "$DSYMUTIL" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_DSYMUTIL"; then
- ac_ct_DSYMUTIL=$DSYMUTIL
- # Extract the first word of "dsymutil", so it can be a program name with args.
-set dummy dsymutil; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_DSYMUTIL+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_DSYMUTIL"; then
- ac_cv_prog_ac_ct_DSYMUTIL="$ac_ct_DSYMUTIL" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_DSYMUTIL="dsymutil"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_DSYMUTIL=$ac_cv_prog_ac_ct_DSYMUTIL
-if test -n "$ac_ct_DSYMUTIL"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DSYMUTIL" >&5
-$as_echo "$ac_ct_DSYMUTIL" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_DSYMUTIL" = x; then
- DSYMUTIL=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- DSYMUTIL=$ac_ct_DSYMUTIL
- fi
-else
- DSYMUTIL="$ac_cv_prog_DSYMUTIL"
-fi
-
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}nmedit", so it can be a program name with args.
-set dummy ${ac_tool_prefix}nmedit; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_NMEDIT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$NMEDIT"; then
- ac_cv_prog_NMEDIT="$NMEDIT" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_NMEDIT="${ac_tool_prefix}nmedit"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-NMEDIT=$ac_cv_prog_NMEDIT
-if test -n "$NMEDIT"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NMEDIT" >&5
-$as_echo "$NMEDIT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_NMEDIT"; then
- ac_ct_NMEDIT=$NMEDIT
- # Extract the first word of "nmedit", so it can be a program name with args.
-set dummy nmedit; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_NMEDIT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_NMEDIT"; then
- ac_cv_prog_ac_ct_NMEDIT="$ac_ct_NMEDIT" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_NMEDIT="nmedit"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_NMEDIT=$ac_cv_prog_ac_ct_NMEDIT
-if test -n "$ac_ct_NMEDIT"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NMEDIT" >&5
-$as_echo "$ac_ct_NMEDIT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_NMEDIT" = x; then
- NMEDIT=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- NMEDIT=$ac_ct_NMEDIT
- fi
-else
- NMEDIT="$ac_cv_prog_NMEDIT"
-fi
-
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}lipo", so it can be a program name with args.
-set dummy ${ac_tool_prefix}lipo; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_LIPO+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$LIPO"; then
- ac_cv_prog_LIPO="$LIPO" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_LIPO="${ac_tool_prefix}lipo"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-LIPO=$ac_cv_prog_LIPO
-if test -n "$LIPO"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5
-$as_echo "$LIPO" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_LIPO"; then
- ac_ct_LIPO=$LIPO
- # Extract the first word of "lipo", so it can be a program name with args.
-set dummy lipo; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_LIPO+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_LIPO"; then
- ac_cv_prog_ac_ct_LIPO="$ac_ct_LIPO" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_LIPO="lipo"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_LIPO=$ac_cv_prog_ac_ct_LIPO
-if test -n "$ac_ct_LIPO"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LIPO" >&5
-$as_echo "$ac_ct_LIPO" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_LIPO" = x; then
- LIPO=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- LIPO=$ac_ct_LIPO
- fi
-else
- LIPO="$ac_cv_prog_LIPO"
-fi
-
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}otool", so it can be a program name with args.
-set dummy ${ac_tool_prefix}otool; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_OTOOL+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$OTOOL"; then
- ac_cv_prog_OTOOL="$OTOOL" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_OTOOL="${ac_tool_prefix}otool"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-OTOOL=$ac_cv_prog_OTOOL
-if test -n "$OTOOL"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5
-$as_echo "$OTOOL" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_OTOOL"; then
- ac_ct_OTOOL=$OTOOL
- # Extract the first word of "otool", so it can be a program name with args.
-set dummy otool; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_OTOOL+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_OTOOL"; then
- ac_cv_prog_ac_ct_OTOOL="$ac_ct_OTOOL" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_OTOOL="otool"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_OTOOL=$ac_cv_prog_ac_ct_OTOOL
-if test -n "$ac_ct_OTOOL"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL" >&5
-$as_echo "$ac_ct_OTOOL" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_OTOOL" = x; then
- OTOOL=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- OTOOL=$ac_ct_OTOOL
- fi
-else
- OTOOL="$ac_cv_prog_OTOOL"
-fi
-
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}otool64", so it can be a program name with args.
-set dummy ${ac_tool_prefix}otool64; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_OTOOL64+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$OTOOL64"; then
- ac_cv_prog_OTOOL64="$OTOOL64" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_OTOOL64="${ac_tool_prefix}otool64"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-OTOOL64=$ac_cv_prog_OTOOL64
-if test -n "$OTOOL64"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL64" >&5
-$as_echo "$OTOOL64" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_OTOOL64"; then
- ac_ct_OTOOL64=$OTOOL64
- # Extract the first word of "otool64", so it can be a program name with args.
-set dummy otool64; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_OTOOL64+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_OTOOL64"; then
- ac_cv_prog_ac_ct_OTOOL64="$ac_ct_OTOOL64" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_OTOOL64="otool64"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_OTOOL64=$ac_cv_prog_ac_ct_OTOOL64
-if test -n "$ac_ct_OTOOL64"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL64" >&5
-$as_echo "$ac_ct_OTOOL64" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_OTOOL64" = x; then
- OTOOL64=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- OTOOL64=$ac_ct_OTOOL64
- fi
-else
- OTOOL64="$ac_cv_prog_OTOOL64"
-fi
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -single_module linker flag" >&5
-$as_echo_n "checking for -single_module linker flag... " >&6; }
-if ${lt_cv_apple_cc_single_mod+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_apple_cc_single_mod=no
- if test -z "${LT_MULTI_MODULE}"; then
- # By default we will add the -single_module flag. You can override
- # by either setting the environment variable LT_MULTI_MODULE
- # non-empty at configure time, or by adding -multi_module to the
- # link flags.
- rm -rf libconftest.dylib*
- echo "int foo(void){return 1;}" > conftest.c
- echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
--dynamiclib -Wl,-single_module conftest.c" >&5
- $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
- -dynamiclib -Wl,-single_module conftest.c 2>conftest.err
- _lt_result=$?
- if test -f libconftest.dylib && test ! -s conftest.err && test $_lt_result = 0; then
- lt_cv_apple_cc_single_mod=yes
- else
- cat conftest.err >&5
- fi
- rm -rf libconftest.dylib*
- rm -f conftest.*
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_apple_cc_single_mod" >&5
-$as_echo "$lt_cv_apple_cc_single_mod" >&6; }
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -exported_symbols_list linker flag" >&5
-$as_echo_n "checking for -exported_symbols_list linker flag... " >&6; }
-if ${lt_cv_ld_exported_symbols_list+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_ld_exported_symbols_list=no
- save_LDFLAGS=$LDFLAGS
- echo "_main" > conftest.sym
- LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- lt_cv_ld_exported_symbols_list=yes
-else
- lt_cv_ld_exported_symbols_list=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LDFLAGS="$save_LDFLAGS"
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_exported_symbols_list" >&5
-$as_echo "$lt_cv_ld_exported_symbols_list" >&6; }
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -force_load linker flag" >&5
-$as_echo_n "checking for -force_load linker flag... " >&6; }
-if ${lt_cv_ld_force_load+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_ld_force_load=no
- cat > conftest.c << _LT_EOF
-int forced_loaded() { return 2;}
-_LT_EOF
- echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&5
- $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5
- echo "$AR cru libconftest.a conftest.o" >&5
- $AR cru libconftest.a conftest.o 2>&5
- cat > conftest.c << _LT_EOF
-int main() { return 0;}
-_LT_EOF
- echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&5
- $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err
- _lt_result=$?
- if test -f conftest && test ! -s conftest.err && test $_lt_result = 0 && $GREP forced_load conftest 2>&1 >/dev/null; then
- lt_cv_ld_force_load=yes
- else
- cat conftest.err >&5
- fi
- rm -f conftest.err libconftest.a conftest conftest.c
- rm -rf conftest.dSYM
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_force_load" >&5
-$as_echo "$lt_cv_ld_force_load" >&6; }
- # Allow for Darwin 4-7 (macOS 10.0-10.3) although these are not expect to
- # build without first building modern cctools / linker.
- case $host_cpu-$host_os in
- *-rhapsody* | *-darwin1.[012])
- _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;;
- *-darwin1.*)
- _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
- *-darwin*)
- # darwin 5.x (macOS 10.1) onwards we only need to adjust when the
- # deployment target is forced to an earlier version.
- case ${MACOSX_DEPLOYMENT_TARGET-UNSET},$host in
- UNSET,*-darwin[89]*|UNSET,*-darwin[12][0123456789]*)
- ;;
- 10.[012][,.]*)
- _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
- ;;
- *)
- ;;
- esac
- ;;
- esac
- if test "$lt_cv_apple_cc_single_mod" = "yes"; then
- _lt_dar_single_mod='$single_module'
- fi
- if test "$lt_cv_ld_exported_symbols_list" = "yes"; then
- _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym'
- else
- _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}'
- fi
- if test "$DSYMUTIL" != ":" && test "$lt_cv_ld_force_load" = "no"; then
- _lt_dsymutil='~$DSYMUTIL $lib || :'
- else
- _lt_dsymutil=
- fi
- ;;
- esac
-
-for ac_header in dlfcn.h
-do :
- ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default
-"
-if test "x$ac_cv_header_dlfcn_h" = xyes; then :
- cat >>confdefs.h <<_ACEOF
-#define HAVE_DLFCN_H 1
-_ACEOF
-
-fi
-
-done
-
-
-
-
-
-# Set options
-
-
-
- enable_dlopen=no
-
-
- enable_win32_dll=no
-
-
- # Check whether --enable-shared was given.
-if test "${enable_shared+set}" = set; then :
- enableval=$enable_shared; p=${PACKAGE-default}
- case $enableval in
- yes) enable_shared=yes ;;
- no) enable_shared=no ;;
- *)
- enable_shared=no
- # Look at the argument we got. We use all the common list separators.
- lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
- for pkg in $enableval; do
- IFS="$lt_save_ifs"
- if test "X$pkg" = "X$p"; then
- enable_shared=yes
- fi
- done
- IFS="$lt_save_ifs"
- ;;
- esac
-else
- enable_shared=yes
-fi
-
-
-
-
-
-
-
-
-
- # Check whether --enable-static was given.
-if test "${enable_static+set}" = set; then :
- enableval=$enable_static; p=${PACKAGE-default}
- case $enableval in
- yes) enable_static=yes ;;
- no) enable_static=no ;;
- *)
- enable_static=no
- # Look at the argument we got. We use all the common list separators.
- lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
- for pkg in $enableval; do
- IFS="$lt_save_ifs"
- if test "X$pkg" = "X$p"; then
- enable_static=yes
- fi
- done
- IFS="$lt_save_ifs"
- ;;
- esac
-else
- enable_static=yes
-fi
-
-
-
-
-
-
-
-
-
-
-# Check whether --with-pic was given.
-if test "${with_pic+set}" = set; then :
- withval=$with_pic; pic_mode="$withval"
-else
- pic_mode=default
-fi
-
-
-test -z "$pic_mode" && pic_mode=default
-
-
-
-
-
-
-
- # Check whether --enable-fast-install was given.
-if test "${enable_fast_install+set}" = set; then :
- enableval=$enable_fast_install; p=${PACKAGE-default}
- case $enableval in
- yes) enable_fast_install=yes ;;
- no) enable_fast_install=no ;;
- *)
- enable_fast_install=no
- # Look at the argument we got. We use all the common list separators.
- lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
- for pkg in $enableval; do
- IFS="$lt_save_ifs"
- if test "X$pkg" = "X$p"; then
- enable_fast_install=yes
- fi
- done
- IFS="$lt_save_ifs"
- ;;
- esac
-else
- enable_fast_install=yes
-fi
-
-
-
-
-
-
-
-
-
-
-
-# This can be used to rebuild libtool when needed
-LIBTOOL_DEPS="$ltmain"
-
-# Always use our own libtool.
-LIBTOOL='$(SHELL) $(top_builddir)/libtool'
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-test -z "$LN_S" && LN_S="ln -s"
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-if test -n "${ZSH_VERSION+set}" ; then
- setopt NO_GLOB_SUBST
-fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for objdir" >&5
-$as_echo_n "checking for objdir... " >&6; }
-if ${lt_cv_objdir+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- rm -f .libs 2>/dev/null
-mkdir .libs 2>/dev/null
-if test -d .libs; then
- lt_cv_objdir=.libs
-else
- # MS-DOS does not allow filenames that begin with a dot.
- lt_cv_objdir=_libs
-fi
-rmdir .libs 2>/dev/null
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_objdir" >&5
-$as_echo "$lt_cv_objdir" >&6; }
-objdir=$lt_cv_objdir
-
-
-
-
-
-cat >>confdefs.h <<_ACEOF
-#define LT_OBJDIR "$lt_cv_objdir/"
-_ACEOF
-
-
-
-
-case $host_os in
-aix3*)
- # AIX sometimes has problems with the GCC collect2 program. For some
- # reason, if we set the COLLECT_NAMES environment variable, the problems
- # vanish in a puff of smoke.
- if test "X${COLLECT_NAMES+set}" != Xset; then
- COLLECT_NAMES=
- export COLLECT_NAMES
- fi
- ;;
-esac
-
-# Global variables:
-ofile=libtool
-can_build_shared=yes
-
-# All known linkers require a `.a' archive for static linking (except MSVC,
-# which needs '.lib').
-libext=a
-
-with_gnu_ld="$lt_cv_prog_gnu_ld"
-
-old_CC="$CC"
-old_CFLAGS="$CFLAGS"
-
-# Set sane defaults for various variables
-test -z "$CC" && CC=cc
-test -z "$LTCC" && LTCC=$CC
-test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
-test -z "$LD" && LD=ld
-test -z "$ac_objext" && ac_objext=o
-
-for cc_temp in $compiler""; do
- case $cc_temp in
- compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
- distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
- \-*) ;;
- *) break;;
- esac
-done
-cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
-
-
-# Only perform the check for file, if the check method requires it
-test -z "$MAGIC_CMD" && MAGIC_CMD=file
-case $deplibs_check_method in
-file_magic*)
- if test "$file_magic_cmd" = '$MAGIC_CMD'; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ac_tool_prefix}file" >&5
-$as_echo_n "checking for ${ac_tool_prefix}file... " >&6; }
-if ${lt_cv_path_MAGIC_CMD+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $MAGIC_CMD in
-[\\/*] | ?:[\\/]*)
- lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
- ;;
-*)
- lt_save_MAGIC_CMD="$MAGIC_CMD"
- lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
- ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
- for ac_dir in $ac_dummy; do
- IFS="$lt_save_ifs"
- test -z "$ac_dir" && ac_dir=.
- if test -f $ac_dir/${ac_tool_prefix}file; then
- lt_cv_path_MAGIC_CMD="$ac_dir/${ac_tool_prefix}file"
- if test -n "$file_magic_test_file"; then
- case $deplibs_check_method in
- "file_magic "*)
- file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
- MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
- if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
- $EGREP "$file_magic_regex" > /dev/null; then
- :
- else
- cat <<_LT_EOF 1>&2
-
-*** Warning: the command libtool uses to detect shared libraries,
-*** $file_magic_cmd, produces output that libtool cannot recognize.
-*** The result is that libtool may fail to recognize shared libraries
-*** as such. This will affect the creation of libtool libraries that
-*** depend on shared libraries, but programs linked with such libtool
-*** libraries will work regardless of this problem. Nevertheless, you
-*** may want to report the problem to your system manager and/or to
-*** bug-libtool@gnu.org
-
-_LT_EOF
- fi ;;
- esac
- fi
- break
- fi
- done
- IFS="$lt_save_ifs"
- MAGIC_CMD="$lt_save_MAGIC_CMD"
- ;;
-esac
-fi
-
-MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
-if test -n "$MAGIC_CMD"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5
-$as_echo "$MAGIC_CMD" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-
-
-
-if test -z "$lt_cv_path_MAGIC_CMD"; then
- if test -n "$ac_tool_prefix"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for file" >&5
-$as_echo_n "checking for file... " >&6; }
-if ${lt_cv_path_MAGIC_CMD+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $MAGIC_CMD in
-[\\/*] | ?:[\\/]*)
- lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
- ;;
-*)
- lt_save_MAGIC_CMD="$MAGIC_CMD"
- lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
- ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
- for ac_dir in $ac_dummy; do
- IFS="$lt_save_ifs"
- test -z "$ac_dir" && ac_dir=.
- if test -f $ac_dir/file; then
- lt_cv_path_MAGIC_CMD="$ac_dir/file"
- if test -n "$file_magic_test_file"; then
- case $deplibs_check_method in
- "file_magic "*)
- file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
- MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
- if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
- $EGREP "$file_magic_regex" > /dev/null; then
- :
- else
- cat <<_LT_EOF 1>&2
-
-*** Warning: the command libtool uses to detect shared libraries,
-*** $file_magic_cmd, produces output that libtool cannot recognize.
-*** The result is that libtool may fail to recognize shared libraries
-*** as such. This will affect the creation of libtool libraries that
-*** depend on shared libraries, but programs linked with such libtool
-*** libraries will work regardless of this problem. Nevertheless, you
-*** may want to report the problem to your system manager and/or to
-*** bug-libtool@gnu.org
-
-_LT_EOF
- fi ;;
- esac
- fi
- break
- fi
- done
- IFS="$lt_save_ifs"
- MAGIC_CMD="$lt_save_MAGIC_CMD"
- ;;
-esac
-fi
-
-MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
-if test -n "$MAGIC_CMD"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5
-$as_echo "$MAGIC_CMD" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- else
- MAGIC_CMD=:
- fi
-fi
-
- fi
- ;;
-esac
-
-# Use C for the default configuration in the libtool script
-
-lt_save_CC="$CC"
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-
-# Source file extension for C test sources.
-ac_ext=c
-
-# Object file extension for compiled C test sources.
-objext=o
-objext=$objext
-
-# Code to be used in simple compile tests
-lt_simple_compile_test_code="int some_variable = 0;"
-
-# Code to be used in simple link tests
-lt_simple_link_test_code='int main(){return(0);}'
-
-
-
-
-
-
-
-# If no C compiler was specified, use CC.
-LTCC=${LTCC-"$CC"}
-
-# If no C compiler flags were specified, use CFLAGS.
-LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
-
-# Allow CC to be a program name with arguments.
-compiler=$CC
-
-# Save the default compiler, since it gets overwritten when the other
-# tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP.
-compiler_DEFAULT=$CC
-
-# save warnings/boilerplate of simple test code
-ac_outfile=conftest.$ac_objext
-echo "$lt_simple_compile_test_code" >conftest.$ac_ext
-eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
-_lt_compiler_boilerplate=`cat conftest.err`
-$RM conftest*
-
-ac_outfile=conftest.$ac_objext
-echo "$lt_simple_link_test_code" >conftest.$ac_ext
-eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
-_lt_linker_boilerplate=`cat conftest.err`
-$RM -r conftest*
-
-
-## CAVEAT EMPTOR:
-## There is no encapsulation within the following macros, do not change
-## the running order or otherwise move them around unless you know exactly
-## what you are doing...
-if test -n "$compiler"; then
-
-lt_prog_compiler_no_builtin_flag=
-
-if test "$GCC" = yes; then
- case $cc_basename in
- nvcc*)
- lt_prog_compiler_no_builtin_flag=' -Xcompiler -fno-builtin' ;;
- *)
- lt_prog_compiler_no_builtin_flag=' -fno-builtin' ;;
- esac
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -fno-rtti -fno-exceptions" >&5
-$as_echo_n "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; }
-if ${lt_cv_prog_compiler_rtti_exceptions+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_prog_compiler_rtti_exceptions=no
- ac_outfile=conftest.$ac_objext
- echo "$lt_simple_compile_test_code" > conftest.$ac_ext
- lt_compiler_flag="-fno-rtti -fno-exceptions"
- # Insert the option either (1) after the last *FLAGS variable, or
- # (2) before a word containing "conftest.", or (3) at the end.
- # Note that $ac_compile itself does not contain backslashes and begins
- # with a dollar sign (not a hyphen), so the echo should work correctly.
- # The option is referenced via a variable to avoid confusing sed.
- lt_compile=`echo "$ac_compile" | $SED \
- -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
- -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
- -e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
- (eval "$lt_compile" 2>conftest.err)
- ac_status=$?
- cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- if (exit $ac_status) && test -s "$ac_outfile"; then
- # The compiler can only warn and ignore the option if not recognized
- # So say no if there are warnings other than the usual output.
- $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
- $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
- if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
- lt_cv_prog_compiler_rtti_exceptions=yes
- fi
- fi
- $RM conftest*
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_rtti_exceptions" >&5
-$as_echo "$lt_cv_prog_compiler_rtti_exceptions" >&6; }
-
-if test x"$lt_cv_prog_compiler_rtti_exceptions" = xyes; then
- lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions"
-else
- :
-fi
-
-fi
-
-
-
-
-
-
- lt_prog_compiler_wl=
-lt_prog_compiler_pic=
-lt_prog_compiler_static=
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
-$as_echo_n "checking for $compiler option to produce PIC... " >&6; }
-
- if test "$GCC" = yes; then
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_static='-static'
-
- case $host_os in
- aix*)
- # All AIX code is PIC.
- if test "$host_cpu" = ia64; then
- # AIX 5 now supports IA64 processor
- lt_prog_compiler_static='-Bstatic'
- fi
- lt_prog_compiler_pic='-fPIC'
- ;;
-
- amigaos*)
- case $host_cpu in
- powerpc)
- # see comment about AmigaOS4 .so support
- lt_prog_compiler_pic='-fPIC'
- ;;
- m68k)
- # FIXME: we need at least 68020 code to build shared libraries, but
- # adding the `-m68020' flag to GCC prevents building anything better,
- # like `-m68040'.
- lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4'
- ;;
- esac
- ;;
-
- beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
- # PIC is the default for these OSes.
- ;;
-
- mingw* | cygwin* | pw32* | os2* | cegcc*)
- # This hack is so that the source file can tell whether it is being
- # built for inclusion in a dll (and should export symbols for example).
- # Although the cygwin gcc ignores -fPIC, still need this for old-style
- # (--disable-auto-import) libraries
- lt_prog_compiler_pic='-DDLL_EXPORT'
- ;;
-
- darwin* | rhapsody*)
- # PIC is the default on this platform
- # Common symbols not allowed in MH_DYLIB files
- lt_prog_compiler_pic='-fno-common'
- ;;
-
- haiku*)
- # PIC is the default for Haiku.
- # The "-static" flag exists, but is broken.
- lt_prog_compiler_static=
- ;;
-
- hpux*)
- # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
- # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag
- # sets the default TLS model and affects inlining.
- case $host_cpu in
- hppa*64*)
- # +Z the default
- ;;
- *)
- lt_prog_compiler_pic='-fPIC'
- ;;
- esac
- ;;
-
- interix[3-9]*)
- # Interix 3.x gcc -fpic/-fPIC options generate broken code.
- # Instead, we relocate shared libraries at runtime.
- ;;
-
- msdosdjgpp*)
- # Just because we use GCC doesn't mean we suddenly get shared libraries
- # on systems that don't support them.
- lt_prog_compiler_can_build_shared=no
- enable_shared=no
- ;;
-
- *nto* | *qnx*)
- # QNX uses GNU C++, but need to define -shared option too, otherwise
- # it will coredump.
- lt_prog_compiler_pic='-fPIC -shared'
- ;;
-
- sysv4*MP*)
- if test -d /usr/nec; then
- lt_prog_compiler_pic=-Kconform_pic
- fi
- ;;
-
- *)
- lt_prog_compiler_pic='-fPIC'
- ;;
- esac
-
- case $cc_basename in
- nvcc*) # Cuda Compiler Driver 2.2
- lt_prog_compiler_wl='-Xlinker '
- lt_prog_compiler_pic='-Xcompiler -fPIC'
- ;;
- esac
- else
- # PORTME Check for flag to pass linker flags through the system compiler.
- case $host_os in
- aix*)
- lt_prog_compiler_wl='-Wl,'
- if test "$host_cpu" = ia64; then
- # AIX 5 now supports IA64 processor
- lt_prog_compiler_static='-Bstatic'
- else
- lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp'
- fi
- ;;
-
- mingw* | cygwin* | pw32* | os2* | cegcc*)
- # This hack is so that the source file can tell whether it is being
- # built for inclusion in a dll (and should export symbols for example).
- lt_prog_compiler_pic='-DDLL_EXPORT'
- ;;
-
- hpux9* | hpux10* | hpux11*)
- lt_prog_compiler_wl='-Wl,'
- # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
- # not for PA HP-UX.
- case $host_cpu in
- hppa*64*|ia64*)
- # +Z the default
- ;;
- *)
- lt_prog_compiler_pic='+Z'
- ;;
- esac
- # Is there a better lt_prog_compiler_static that works with the bundled CC?
- lt_prog_compiler_static='${wl}-a ${wl}archive'
- ;;
-
- irix5* | irix6* | nonstopux*)
- lt_prog_compiler_wl='-Wl,'
- # PIC (with -KPIC) is the default.
- lt_prog_compiler_static='-non_shared'
- ;;
-
- linux* | k*bsd*-gnu | kopensolaris*-gnu)
- case $cc_basename in
- # old Intel for x86_64 which still supported -KPIC.
- ecc*)
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_pic='-KPIC'
- lt_prog_compiler_static='-static'
- ;;
- # icc used to be incompatible with GCC.
- # ICC 10 doesn't accept -KPIC any more.
- icc* | ifort*)
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_pic='-fPIC'
- lt_prog_compiler_static='-static'
- ;;
- # Lahey Fortran 8.1.
- lf95*)
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_pic='--shared'
- lt_prog_compiler_static='--static'
- ;;
- pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
- # Portland Group compilers (*not* the Pentium gcc compiler,
- # which looks to be a dead project)
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_pic='-fpic'
- lt_prog_compiler_static='-Bstatic'
- ;;
- ccc*)
- lt_prog_compiler_wl='-Wl,'
- # All Alpha code is PIC.
- lt_prog_compiler_static='-non_shared'
- ;;
- xl* | bgxl* | bgf* | mpixl*)
- # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_pic='-qpic'
- lt_prog_compiler_static='-qstaticlink'
- ;;
- *)
- case `$CC -V 2>&1 | sed 5q` in
- *Sun\ F* | *Sun*Fortran*)
- # Sun Fortran 8.3 passes all unrecognized flags to the linker
- lt_prog_compiler_pic='-KPIC'
- lt_prog_compiler_static='-Bstatic'
- lt_prog_compiler_wl=''
- ;;
- *Sun\ C*)
- # Sun C 5.9
- lt_prog_compiler_pic='-KPIC'
- lt_prog_compiler_static='-Bstatic'
- lt_prog_compiler_wl='-Wl,'
- ;;
- esac
- ;;
- esac
- ;;
-
- newsos6)
- lt_prog_compiler_pic='-KPIC'
- lt_prog_compiler_static='-Bstatic'
- ;;
-
- *nto* | *qnx*)
- # QNX uses GNU C++, but need to define -shared option too, otherwise
- # it will coredump.
- lt_prog_compiler_pic='-fPIC -shared'
- ;;
-
- osf3* | osf4* | osf5*)
- lt_prog_compiler_wl='-Wl,'
- # All OSF/1 code is PIC.
- lt_prog_compiler_static='-non_shared'
- ;;
-
- rdos*)
- lt_prog_compiler_static='-non_shared'
- ;;
-
- solaris*)
- lt_prog_compiler_pic='-KPIC'
- lt_prog_compiler_static='-Bstatic'
- case $cc_basename in
- f77* | f90* | f95*)
- lt_prog_compiler_wl='-Qoption ld ';;
- *)
- lt_prog_compiler_wl='-Wl,';;
- esac
- ;;
-
- sunos4*)
- lt_prog_compiler_wl='-Qoption ld '
- lt_prog_compiler_pic='-PIC'
- lt_prog_compiler_static='-Bstatic'
- ;;
-
- sysv4 | sysv4.2uw2* | sysv4.3*)
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_pic='-KPIC'
- lt_prog_compiler_static='-Bstatic'
- ;;
-
- sysv4*MP*)
- if test -d /usr/nec ;then
- lt_prog_compiler_pic='-Kconform_pic'
- lt_prog_compiler_static='-Bstatic'
- fi
- ;;
-
- sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_pic='-KPIC'
- lt_prog_compiler_static='-Bstatic'
- ;;
-
- unicos*)
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_can_build_shared=no
- ;;
-
- uts4*)
- lt_prog_compiler_pic='-pic'
- lt_prog_compiler_static='-Bstatic'
- ;;
-
- *)
- lt_prog_compiler_can_build_shared=no
- ;;
- esac
- fi
-
-case $host_os in
- # For platforms which do not support PIC, -DPIC is meaningless:
- *djgpp*)
- lt_prog_compiler_pic=
- ;;
- *)
- lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC"
- ;;
-esac
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_prog_compiler_pic" >&5
-$as_echo "$lt_prog_compiler_pic" >&6; }
-
-
-
-
-
-
-#
-# Check to make sure the PIC flag actually works.
-#
-if test -n "$lt_prog_compiler_pic"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5
-$as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic works... " >&6; }
-if ${lt_cv_prog_compiler_pic_works+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_prog_compiler_pic_works=no
- ac_outfile=conftest.$ac_objext
- echo "$lt_simple_compile_test_code" > conftest.$ac_ext
- lt_compiler_flag="$lt_prog_compiler_pic -DPIC"
- # Insert the option either (1) after the last *FLAGS variable, or
- # (2) before a word containing "conftest.", or (3) at the end.
- # Note that $ac_compile itself does not contain backslashes and begins
- # with a dollar sign (not a hyphen), so the echo should work correctly.
- # The option is referenced via a variable to avoid confusing sed.
- lt_compile=`echo "$ac_compile" | $SED \
- -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
- -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
- -e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
- (eval "$lt_compile" 2>conftest.err)
- ac_status=$?
- cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- if (exit $ac_status) && test -s "$ac_outfile"; then
- # The compiler can only warn and ignore the option if not recognized
- # So say no if there are warnings other than the usual output.
- $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
- $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
- if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
- lt_cv_prog_compiler_pic_works=yes
- fi
- fi
- $RM conftest*
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works" >&5
-$as_echo "$lt_cv_prog_compiler_pic_works" >&6; }
-
-if test x"$lt_cv_prog_compiler_pic_works" = xyes; then
- case $lt_prog_compiler_pic in
- "" | " "*) ;;
- *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;;
- esac
-else
- lt_prog_compiler_pic=
- lt_prog_compiler_can_build_shared=no
-fi
-
-fi
-
-
-
-
-
-
-#
-# Check to make sure the static flag actually works.
-#
-wl=$lt_prog_compiler_wl eval lt_tmp_static_flag=\"$lt_prog_compiler_static\"
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5
-$as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; }
-if ${lt_cv_prog_compiler_static_works+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_prog_compiler_static_works=no
- save_LDFLAGS="$LDFLAGS"
- LDFLAGS="$LDFLAGS $lt_tmp_static_flag"
- echo "$lt_simple_link_test_code" > conftest.$ac_ext
- if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
- # The linker can only warn and ignore the option if not recognized
- # So say no if there are warnings
- if test -s conftest.err; then
- # Append any errors to the config.log.
- cat conftest.err 1>&5
- $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
- $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
- if diff conftest.exp conftest.er2 >/dev/null; then
- lt_cv_prog_compiler_static_works=yes
- fi
- else
- lt_cv_prog_compiler_static_works=yes
- fi
- fi
- $RM -r conftest*
- LDFLAGS="$save_LDFLAGS"
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works" >&5
-$as_echo "$lt_cv_prog_compiler_static_works" >&6; }
-
-if test x"$lt_cv_prog_compiler_static_works" = xyes; then
- :
-else
- lt_prog_compiler_static=
-fi
-
-
-
-
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
-$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
-if ${lt_cv_prog_compiler_c_o+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_prog_compiler_c_o=no
- $RM -r conftest 2>/dev/null
- mkdir conftest
- cd conftest
- mkdir out
- echo "$lt_simple_compile_test_code" > conftest.$ac_ext
-
- lt_compiler_flag="-o out/conftest2.$ac_objext"
- # Insert the option either (1) after the last *FLAGS variable, or
- # (2) before a word containing "conftest.", or (3) at the end.
- # Note that $ac_compile itself does not contain backslashes and begins
- # with a dollar sign (not a hyphen), so the echo should work correctly.
- lt_compile=`echo "$ac_compile" | $SED \
- -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
- -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
- -e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
- (eval "$lt_compile" 2>out/conftest.err)
- ac_status=$?
- cat out/conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- if (exit $ac_status) && test -s out/conftest2.$ac_objext
- then
- # The compiler can only warn and ignore the option if not recognized
- # So say no if there are warnings
- $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
- $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
- if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
- lt_cv_prog_compiler_c_o=yes
- fi
- fi
- chmod u+w . 2>&5
- $RM conftest*
- # SGI C++ compiler will create directory out/ii_files/ for
- # template instantiation
- test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
- $RM out/* && rmdir out
- cd ..
- $RM -r conftest
- $RM conftest*
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5
-$as_echo "$lt_cv_prog_compiler_c_o" >&6; }
-
-
-
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
-$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
-if ${lt_cv_prog_compiler_c_o+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_prog_compiler_c_o=no
- $RM -r conftest 2>/dev/null
- mkdir conftest
- cd conftest
- mkdir out
- echo "$lt_simple_compile_test_code" > conftest.$ac_ext
-
- lt_compiler_flag="-o out/conftest2.$ac_objext"
- # Insert the option either (1) after the last *FLAGS variable, or
- # (2) before a word containing "conftest.", or (3) at the end.
- # Note that $ac_compile itself does not contain backslashes and begins
- # with a dollar sign (not a hyphen), so the echo should work correctly.
- lt_compile=`echo "$ac_compile" | $SED \
- -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
- -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
- -e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
- (eval "$lt_compile" 2>out/conftest.err)
- ac_status=$?
- cat out/conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- if (exit $ac_status) && test -s out/conftest2.$ac_objext
- then
- # The compiler can only warn and ignore the option if not recognized
- # So say no if there are warnings
- $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
- $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
- if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
- lt_cv_prog_compiler_c_o=yes
- fi
- fi
- chmod u+w . 2>&5
- $RM conftest*
- # SGI C++ compiler will create directory out/ii_files/ for
- # template instantiation
- test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
- $RM out/* && rmdir out
- cd ..
- $RM -r conftest
- $RM conftest*
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5
-$as_echo "$lt_cv_prog_compiler_c_o" >&6; }
-
-
-
-
-hard_links="nottested"
-if test "$lt_cv_prog_compiler_c_o" = no && test "$need_locks" != no; then
- # do not overwrite the value of need_locks provided by the user
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5
-$as_echo_n "checking if we can lock with hard links... " >&6; }
- hard_links=yes
- $RM conftest*
- ln conftest.a conftest.b 2>/dev/null && hard_links=no
- touch conftest.a
- ln conftest.a conftest.b 2>&5 || hard_links=no
- ln conftest.a conftest.b 2>/dev/null && hard_links=no
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5
-$as_echo "$hard_links" >&6; }
- if test "$hard_links" = no; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5
-$as_echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;}
- need_locks=warn
- fi
-else
- need_locks=no
-fi
-
-
-
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5
-$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; }
-
- runpath_var=
- allow_undefined_flag=
- always_export_symbols=no
- archive_cmds=
- archive_expsym_cmds=
- compiler_needs_object=no
- enable_shared_with_static_runtimes=no
- export_dynamic_flag_spec=
- export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
- hardcode_automatic=no
- hardcode_direct=no
- hardcode_direct_absolute=no
- hardcode_libdir_flag_spec=
- hardcode_libdir_flag_spec_ld=
- hardcode_libdir_separator=
- hardcode_minus_L=no
- hardcode_shlibpath_var=unsupported
- inherit_rpath=no
- link_all_deplibs=unknown
- module_cmds=
- module_expsym_cmds=
- old_archive_from_new_cmds=
- old_archive_from_expsyms_cmds=
- thread_safe_flag_spec=
- whole_archive_flag_spec=
- # include_expsyms should be a list of space-separated symbols to be *always*
- # included in the symbol list
- include_expsyms=
- # exclude_expsyms can be an extended regexp of symbols to exclude
- # it will be wrapped by ` (' and `)$', so one must not match beginning or
- # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
- # as well as any symbol that contains `d'.
- exclude_expsyms='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'
- # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
- # platforms (ab)use it in PIC code, but their linkers get confused if
- # the symbol is explicitly referenced. Since portable code cannot
- # rely on this symbol name, it's probably fine to never include it in
- # preloaded symbol tables.
- # Exclude shared library initialization/finalization symbols.
- extract_expsyms_cmds=
-
- case $host_os in
- cygwin* | mingw* | pw32* | cegcc*)
- # FIXME: the MSVC++ port hasn't been tested in a loooong time
- # When not using gcc, we currently assume that we are using
- # Microsoft Visual C++.
- if test "$GCC" != yes; then
- with_gnu_ld=no
- fi
- ;;
- interix*)
- # we just hope/assume this is gcc and not c89 (= MSVC++)
- with_gnu_ld=yes
- ;;
- openbsd*)
- with_gnu_ld=no
- ;;
- esac
-
- ld_shlibs=yes
-
- # On some targets, GNU ld is compatible enough with the native linker
- # that we're better off using the native interface for both.
- lt_use_gnu_ld_interface=no
- if test "$with_gnu_ld" = yes; then
- case $host_os in
- aix*)
- # The AIX port of GNU ld has always aspired to compatibility
- # with the native linker. However, as the warning in the GNU ld
- # block says, versions before 2.19.5* couldn't really create working
- # shared libraries, regardless of the interface used.
- case `$LD -v 2>&1` in
- *\ \(GNU\ Binutils\)\ 2.19.5*) ;;
- *\ \(GNU\ Binutils\)\ 2.[2-9]*) ;;
- *\ \(GNU\ Binutils\)\ [3-9]*) ;;
- *)
- lt_use_gnu_ld_interface=yes
- ;;
- esac
- ;;
- *)
- lt_use_gnu_ld_interface=yes
- ;;
- esac
- fi
-
- if test "$lt_use_gnu_ld_interface" = yes; then
- # If archive_cmds runs LD, not CC, wlarc should be empty
- wlarc='${wl}'
-
- # Set some defaults for GNU ld with shared library support. These
- # are reset later if shared libraries are not supported. Putting them
- # here allows them to be overridden if necessary.
- runpath_var=LD_RUN_PATH
- hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
- export_dynamic_flag_spec='${wl}--export-dynamic'
- # ancient GNU ld didn't support --whole-archive et. al.
- if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then
- whole_archive_flag_spec="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
- else
- whole_archive_flag_spec=
- fi
- supports_anon_versioning=no
- case `$LD -v 2>&1` in
- *GNU\ gold*) supports_anon_versioning=yes ;;
- *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11
- *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
- *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
- *\ 2.11.*) ;; # other 2.11 versions
- *) supports_anon_versioning=yes ;;
- esac
-
- # See if GNU ld supports shared libraries.
- case $host_os in
- aix[3-9]*)
- # On AIX/PPC, the GNU linker is very broken
- if test "$host_cpu" != ia64; then
- ld_shlibs=no
- cat <<_LT_EOF 1>&2
-
-*** Warning: the GNU linker, at least up to release 2.19, is reported
-*** to be unable to reliably create shared libraries on AIX.
-*** Therefore, libtool is disabling shared libraries support. If you
-*** really care for shared libraries, you may want to install binutils
-*** 2.20 or above, or modify your PATH so that a non-GNU linker is found.
-*** You will then need to restart the configuration process.
-
-_LT_EOF
- fi
- ;;
-
- amigaos*)
- case $host_cpu in
- powerpc)
- # see comment about AmigaOS4 .so support
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- archive_expsym_cmds=''
- ;;
- m68k)
- archive_cmds='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
- hardcode_libdir_flag_spec='-L$libdir'
- hardcode_minus_L=yes
- ;;
- esac
- ;;
-
- beos*)
- if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
- allow_undefined_flag=unsupported
- # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
- # support --undefined. This deserves some investigation. FIXME
- archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- else
- ld_shlibs=no
- fi
- ;;
-
- cygwin* | mingw* | pw32* | cegcc*)
- # _LT_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless,
- # as there is no search path for DLLs.
- hardcode_libdir_flag_spec='-L$libdir'
- export_dynamic_flag_spec='${wl}--export-all-symbols'
- allow_undefined_flag=unsupported
- always_export_symbols=no
- enable_shared_with_static_runtimes=yes
- export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
-
- if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
- # If the export-symbols file already is a .def file (1st line
- # is EXPORTS), use it as is; otherwise, prepend...
- archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
- cp $export_symbols $output_objdir/$soname.def;
- else
- echo EXPORTS > $output_objdir/$soname.def;
- cat $export_symbols >> $output_objdir/$soname.def;
- fi~
- $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
- else
- ld_shlibs=no
- fi
- ;;
-
- haiku*)
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- link_all_deplibs=yes
- ;;
-
- interix[3-9]*)
- hardcode_direct=no
- hardcode_shlibpath_var=no
- hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
- export_dynamic_flag_spec='${wl}-E'
- # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
- # Instead, shared libraries are loaded at an image base (0x10000000 by
- # default) and relocated if they conflict, which is a slow very memory
- # consuming and fragmenting process. To avoid this, we pick a random,
- # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
- # time. Moving up from 0x10000000 also allows more sbrk(2) space.
- archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
- archive_expsym_cmds='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
- ;;
-
- gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu | uclinuxfdpiceabi)
- tmp_diet=no
- if test "$host_os" = linux-dietlibc; then
- case $cc_basename in
- diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn)
- esac
- fi
- if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
- && test "$tmp_diet" = no
- then
- tmp_addflag=' $pic_flag'
- tmp_sharedflag='-shared'
- case $cc_basename,$host_cpu in
- pgcc*) # Portland Group C compiler
- whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
- tmp_addflag=' $pic_flag'
- ;;
- pgf77* | pgf90* | pgf95* | pgfortran*)
- # Portland Group f77 and f90 compilers
- whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
- tmp_addflag=' $pic_flag -Mnomain' ;;
- ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64
- tmp_addflag=' -i_dynamic' ;;
- efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64
- tmp_addflag=' -i_dynamic -nofor_main' ;;
- ifc* | ifort*) # Intel Fortran compiler
- tmp_addflag=' -nofor_main' ;;
- lf95*) # Lahey Fortran 8.1
- whole_archive_flag_spec=
- tmp_sharedflag='--shared' ;;
- xl[cC]* | bgxl[cC]* | mpixl[cC]*) # IBM XL C 8.0 on PPC (deal with xlf below)
- tmp_sharedflag='-qmkshrobj'
- tmp_addflag= ;;
- nvcc*) # Cuda Compiler Driver 2.2
- whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
- compiler_needs_object=yes
- ;;
- esac
- case `$CC -V 2>&1 | sed 5q` in
- *Sun\ C*) # Sun C 5.9
- whole_archive_flag_spec='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
- compiler_needs_object=yes
- tmp_sharedflag='-G' ;;
- *Sun\ F*) # Sun Fortran 8.3
- tmp_sharedflag='-G' ;;
- esac
- archive_cmds='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
-
- if test "x$supports_anon_versioning" = xyes; then
- archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
- cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
- echo "local: *; };" >> $output_objdir/$libname.ver~
- $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
- fi
-
- case $cc_basename in
- xlf* | bgf* | bgxlf* | mpixlf*)
- # IBM XL Fortran 10.1 on PPC cannot create shared libs itself
- whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive'
- hardcode_libdir_flag_spec=
- hardcode_libdir_flag_spec_ld='-rpath $libdir'
- archive_cmds='$LD -shared $libobjs $deplibs $compiler_flags -soname $soname -o $lib'
- if test "x$supports_anon_versioning" = xyes; then
- archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
- cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
- echo "local: *; };" >> $output_objdir/$libname.ver~
- $LD -shared $libobjs $deplibs $compiler_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
- fi
- ;;
- esac
- else
- ld_shlibs=no
- fi
- ;;
-
- netbsd*)
- if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
- archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
- wlarc=
- else
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
- fi
- ;;
-
- solaris*)
- if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then
- ld_shlibs=no
- cat <<_LT_EOF 1>&2
-
-*** Warning: The releases 2.8.* of the GNU linker cannot reliably
-*** create shared libraries on Solaris systems. Therefore, libtool
-*** is disabling shared libraries support. We urge you to upgrade GNU
-*** binutils to release 2.9.1 or newer. Another option is to modify
-*** your PATH or compiler configuration so that the native linker is
-*** used, and then restart.
-
-_LT_EOF
- elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
- else
- ld_shlibs=no
- fi
- ;;
-
- sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
- case `$LD -v 2>&1` in
- *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*)
- ld_shlibs=no
- cat <<_LT_EOF 1>&2
-
-*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not
-*** reliably create shared libraries on SCO systems. Therefore, libtool
-*** is disabling shared libraries support. We urge you to upgrade GNU
-*** binutils to release 2.16.91.0.3 or newer. Another option is to modify
-*** your PATH or compiler configuration so that the native linker is
-*** used, and then restart.
-
-_LT_EOF
- ;;
- *)
- # For security reasons, it is highly recommended that you always
- # use absolute paths for naming shared libraries, and exclude the
- # DT_RUNPATH tag from executables and libraries. But doing so
- # requires that you compile everything twice, which is a pain.
- if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
- hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
- else
- ld_shlibs=no
- fi
- ;;
- esac
- ;;
-
- sunos4*)
- archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
- wlarc=
- hardcode_direct=yes
- hardcode_shlibpath_var=no
- ;;
-
- *)
- if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
- else
- ld_shlibs=no
- fi
- ;;
- esac
-
- if test "$ld_shlibs" = no; then
- runpath_var=
- hardcode_libdir_flag_spec=
- export_dynamic_flag_spec=
- whole_archive_flag_spec=
- fi
- else
- # PORTME fill in a description of your system's linker (not GNU ld)
- case $host_os in
- aix3*)
- allow_undefined_flag=unsupported
- always_export_symbols=yes
- archive_expsym_cmds='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname'
- # Note: this linker hardcodes the directories in LIBPATH if there
- # are no directories specified by -L.
- hardcode_minus_L=yes
- if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then
- # Neither direct hardcoding nor static linking is supported with a
- # broken collect2.
- hardcode_direct=unsupported
- fi
- ;;
-
- aix[4-9]*)
- if test "$host_cpu" = ia64; then
- # On IA64, the linker does run time linking by default, so we don't
- # have to do anything special.
- aix_use_runtimelinking=no
- exp_sym_flag='-Bexport'
- no_entry_flag=""
- else
- # If we're using GNU nm, then we don't want the "-C" option.
- # -C means demangle to AIX nm, but means don't demangle with GNU nm
- # Also, AIX nm treats weak defined symbols like other global
- # defined symbols, whereas GNU nm marks them as "W".
- if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
- export_symbols_cmds='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
- else
- export_symbols_cmds='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "L")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
- fi
- aix_use_runtimelinking=no
-
- # Test if we are trying to use run time linking or normal
- # AIX style linking. If -brtl is somewhere in LDFLAGS, we
- # need to do runtime linking.
- case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*)
- for ld_flag in $LDFLAGS; do
- if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
- aix_use_runtimelinking=yes
- break
- fi
- done
- ;;
- esac
-
- exp_sym_flag='-bexport'
- no_entry_flag='-bnoentry'
- fi
-
- # When large executables or shared objects are built, AIX ld can
- # have problems creating the table of contents. If linking a library
- # or program results in "error TOC overflow" add -mminimal-toc to
- # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
- # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
-
- archive_cmds=''
- hardcode_direct=yes
- hardcode_direct_absolute=yes
- hardcode_libdir_separator=':'
- link_all_deplibs=yes
- file_list_spec='${wl}-f,'
-
- if test "$GCC" = yes; then
- case $host_os in aix4.[012]|aix4.[012].*)
- # We only want to do this on AIX 4.2 and lower, the check
- # below for broken collect2 doesn't work under 4.3+
- collect2name=`${CC} -print-prog-name=collect2`
- if test -f "$collect2name" &&
- strings "$collect2name" | $GREP resolve_lib_name >/dev/null
- then
- # We have reworked collect2
- :
- else
- # We have old collect2
- hardcode_direct=unsupported
- # It fails to find uninstalled libraries when the uninstalled
- # path is not listed in the libpath. Setting hardcode_minus_L
- # to unsupported forces relinking
- hardcode_minus_L=yes
- hardcode_libdir_flag_spec='-L$libdir'
- hardcode_libdir_separator=
- fi
- ;;
- esac
- shared_flag='-shared'
- if test "$aix_use_runtimelinking" = yes; then
- shared_flag="$shared_flag "'${wl}-G'
- fi
- else
- # not using gcc
- if test "$host_cpu" = ia64; then
- # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
- # chokes on -Wl,-G. The following line is correct:
- shared_flag='-G'
- else
- if test "$aix_use_runtimelinking" = yes; then
- shared_flag='${wl}-G'
- else
- shared_flag='${wl}-bM:SRE'
- fi
- fi
- fi
-
- export_dynamic_flag_spec='${wl}-bexpall'
- # It seems that -bexpall does not export symbols beginning with
- # underscore (_), so it is better to generate a list of symbols to export.
- always_export_symbols=yes
- if test "$aix_use_runtimelinking" = yes; then
- # Warning - without using the other runtime loading flags (-brtl),
- # -berok will link without error, but may produce a broken library.
- allow_undefined_flag='-berok'
- # Determine the default libpath from the value encoded in an
- # empty executable.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
-
-lt_aix_libpath_sed='
- /Import File Strings/,/^$/ {
- /^0/ {
- s/^0 *\(.*\)$/\1/
- p
- }
- }'
-aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
-# Check for a 64-bit object if we didn't find anything.
-if test -z "$aix_libpath"; then
- aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
-fi
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
-
- hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
- archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
- else
- if test "$host_cpu" = ia64; then
- hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib'
- allow_undefined_flag="-z nodefs"
- archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols"
- else
- # Determine the default libpath from the value encoded in an
- # empty executable.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
-
-lt_aix_libpath_sed='
- /Import File Strings/,/^$/ {
- /^0/ {
- s/^0 *\(.*\)$/\1/
- p
- }
- }'
-aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
-# Check for a 64-bit object if we didn't find anything.
-if test -z "$aix_libpath"; then
- aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
-fi
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
-
- hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
- # Warning - without using the other run time loading flags,
- # -berok will link without error, but may produce a broken library.
- no_undefined_flag=' ${wl}-bernotok'
- allow_undefined_flag=' ${wl}-berok'
- if test "$with_gnu_ld" = yes; then
- # We only use this code for GNU lds that support --whole-archive.
- whole_archive_flag_spec='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
- else
- # Exported symbols can be pulled into shared objects from archives
- whole_archive_flag_spec='$convenience'
- fi
- archive_cmds_need_lc=yes
- # This is similar to how AIX traditionally builds its shared libraries.
- archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
- fi
- fi
- ;;
-
- amigaos*)
- case $host_cpu in
- powerpc)
- # see comment about AmigaOS4 .so support
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- archive_expsym_cmds=''
- ;;
- m68k)
- archive_cmds='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
- hardcode_libdir_flag_spec='-L$libdir'
- hardcode_minus_L=yes
- ;;
- esac
- ;;
-
- bsdi[45]*)
- export_dynamic_flag_spec=-rdynamic
- ;;
-
- cygwin* | mingw* | pw32* | cegcc*)
- # When not using gcc, we currently assume that we are using
- # Microsoft Visual C++.
- # hardcode_libdir_flag_spec is actually meaningless, as there is
- # no search path for DLLs.
- hardcode_libdir_flag_spec=' '
- allow_undefined_flag=unsupported
- # Tell ltmain to make .lib files, not .a files.
- libext=lib
- # Tell ltmain to make .dll files, not .so files.
- shrext_cmds=".dll"
- # FIXME: Setting linknames here is a bad hack.
- archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
- # The linker will automatically build a .lib file if we build a DLL.
- old_archive_from_new_cmds='true'
- # FIXME: Should let the user specify the lib program.
- old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs'
- fix_srcfile_path='`cygpath -w "$srcfile"`'
- enable_shared_with_static_runtimes=yes
- ;;
-
- darwin* | rhapsody*)
-
-
- archive_cmds_need_lc=no
- hardcode_direct=no
- hardcode_automatic=yes
- hardcode_shlibpath_var=unsupported
- if test "$lt_cv_ld_force_load" = "yes"; then
- whole_archive_flag_spec='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience ${wl}-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`'
- else
- whole_archive_flag_spec=''
- fi
- link_all_deplibs=yes
- allow_undefined_flag="$_lt_dar_allow_undefined"
- case $cc_basename in
- ifort*) _lt_dar_can_shared=yes ;;
- *) _lt_dar_can_shared=$GCC ;;
- esac
- if test "$_lt_dar_can_shared" = "yes"; then
- output_verbose_link_cmd=func_echo_all
- archive_cmds="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}"
- module_cmds="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
- archive_expsym_cmds="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}"
- module_expsym_cmds="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}"
-
- else
- ld_shlibs=no
- fi
-
- ;;
-
- dgux*)
- archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
- hardcode_libdir_flag_spec='-L$libdir'
- hardcode_shlibpath_var=no
- ;;
-
- # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
- # support. Future versions do this automatically, but an explicit c++rt0.o
- # does not break anything, and helps significantly (at the cost of a little
- # extra space).
- freebsd2.2*)
- archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
- hardcode_libdir_flag_spec='-R$libdir'
- hardcode_direct=yes
- hardcode_shlibpath_var=no
- ;;
-
- # Unfortunately, older versions of FreeBSD 2 do not have this feature.
- freebsd2.*)
- archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
- hardcode_direct=yes
- hardcode_minus_L=yes
- hardcode_shlibpath_var=no
- ;;
-
- # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
- freebsd* | dragonfly*)
- archive_cmds='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
- hardcode_libdir_flag_spec='-R$libdir'
- hardcode_direct=yes
- hardcode_shlibpath_var=no
- ;;
-
- hpux9*)
- if test "$GCC" = yes; then
- archive_cmds='$RM $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
- else
- archive_cmds='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
- fi
- hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
- hardcode_libdir_separator=:
- hardcode_direct=yes
-
- # hardcode_minus_L: Not really in the search PATH,
- # but as the default location of the library.
- hardcode_minus_L=yes
- export_dynamic_flag_spec='${wl}-E'
- ;;
-
- hpux10*)
- if test "$GCC" = yes && test "$with_gnu_ld" = no; then
- archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
- else
- archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
- fi
- if test "$with_gnu_ld" = no; then
- hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
- hardcode_libdir_flag_spec_ld='+b $libdir'
- hardcode_libdir_separator=:
- hardcode_direct=yes
- hardcode_direct_absolute=yes
- export_dynamic_flag_spec='${wl}-E'
- # hardcode_minus_L: Not really in the search PATH,
- # but as the default location of the library.
- hardcode_minus_L=yes
- fi
- ;;
-
- hpux11*)
- if test "$GCC" = yes && test "$with_gnu_ld" = no; then
- case $host_cpu in
- hppa*64*)
- archive_cmds='$CC -shared ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
- ;;
- ia64*)
- archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
- ;;
- *)
- archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
- ;;
- esac
- else
- case $host_cpu in
- hppa*64*)
- archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
- ;;
- ia64*)
- archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
- ;;
- *)
-
- # Older versions of the 11.00 compiler do not understand -b yet
- # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does)
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC understands -b" >&5
-$as_echo_n "checking if $CC understands -b... " >&6; }
-if ${lt_cv_prog_compiler__b+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_prog_compiler__b=no
- save_LDFLAGS="$LDFLAGS"
- LDFLAGS="$LDFLAGS -b"
- echo "$lt_simple_link_test_code" > conftest.$ac_ext
- if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
- # The linker can only warn and ignore the option if not recognized
- # So say no if there are warnings
- if test -s conftest.err; then
- # Append any errors to the config.log.
- cat conftest.err 1>&5
- $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
- $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
- if diff conftest.exp conftest.er2 >/dev/null; then
- lt_cv_prog_compiler__b=yes
- fi
- else
- lt_cv_prog_compiler__b=yes
- fi
- fi
- $RM -r conftest*
- LDFLAGS="$save_LDFLAGS"
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler__b" >&5
-$as_echo "$lt_cv_prog_compiler__b" >&6; }
-
-if test x"$lt_cv_prog_compiler__b" = xyes; then
- archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
-else
- archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
-fi
-
- ;;
- esac
- fi
- if test "$with_gnu_ld" = no; then
- hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
- hardcode_libdir_separator=:
-
- case $host_cpu in
- hppa*64*|ia64*)
- hardcode_direct=no
- hardcode_shlibpath_var=no
- ;;
- *)
- hardcode_direct=yes
- hardcode_direct_absolute=yes
- export_dynamic_flag_spec='${wl}-E'
-
- # hardcode_minus_L: Not really in the search PATH,
- # but as the default location of the library.
- hardcode_minus_L=yes
- ;;
- esac
- fi
- ;;
-
- irix5* | irix6* | nonstopux*)
- if test "$GCC" = yes; then
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
- # Try to use the -exported_symbol ld option, if it does not
- # work, assume that -exports_file does not work either and
- # implicitly export all symbols.
- save_LDFLAGS="$LDFLAGS"
- LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-int foo(void) {}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
-
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LDFLAGS="$save_LDFLAGS"
- else
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
- fi
- archive_cmds_need_lc='no'
- hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
- hardcode_libdir_separator=:
- inherit_rpath=yes
- link_all_deplibs=yes
- ;;
-
- netbsd*)
- if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
- archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out
- else
- archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF
- fi
- hardcode_libdir_flag_spec='-R$libdir'
- hardcode_direct=yes
- hardcode_shlibpath_var=no
- ;;
-
- newsos6)
- archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
- hardcode_direct=yes
- hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
- hardcode_libdir_separator=:
- hardcode_shlibpath_var=no
- ;;
-
- *nto* | *qnx*)
- ;;
-
- openbsd*)
- if test -f /usr/libexec/ld.so; then
- hardcode_direct=yes
- hardcode_shlibpath_var=no
- hardcode_direct_absolute=yes
- if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
- archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
- archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
- hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
- export_dynamic_flag_spec='${wl}-E'
- else
- case $host_os in
- openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*)
- archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
- hardcode_libdir_flag_spec='-R$libdir'
- ;;
- *)
- archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
- hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
- ;;
- esac
- fi
- else
- ld_shlibs=no
- fi
- ;;
-
- os2*)
- hardcode_libdir_flag_spec='-L$libdir'
- hardcode_minus_L=yes
- allow_undefined_flag=unsupported
- archive_cmds='$ECHO "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~echo DATA >> $output_objdir/$libname.def~echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def'
- old_archive_from_new_cmds='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
- ;;
-
- osf3*)
- if test "$GCC" = yes; then
- allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
- archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
- else
- allow_undefined_flag=' -expect_unresolved \*'
- archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
- fi
- archive_cmds_need_lc='no'
- hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
- hardcode_libdir_separator=:
- ;;
-
- osf4* | osf5*) # as osf3* with the addition of -msym flag
- if test "$GCC" = yes; then
- allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
- archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
- hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
- else
- allow_undefined_flag=' -expect_unresolved \*'
- archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
- archive_expsym_cmds='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~
- $CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp'
-
- # Both c and cxx compiler support -rpath directly
- hardcode_libdir_flag_spec='-rpath $libdir'
- fi
- archive_cmds_need_lc='no'
- hardcode_libdir_separator=:
- ;;
-
- solaris*)
- no_undefined_flag=' -z defs'
- if test "$GCC" = yes; then
- wlarc='${wl}'
- archive_cmds='$CC -shared ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
- archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
- $CC -shared ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
- else
- case `$CC -V 2>&1` in
- *"Compilers 5.0"*)
- wlarc=''
- archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
- archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
- $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp'
- ;;
- *)
- wlarc='${wl}'
- archive_cmds='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags'
- archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
- $CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
- ;;
- esac
- fi
- hardcode_libdir_flag_spec='-R$libdir'
- hardcode_shlibpath_var=no
- case $host_os in
- solaris2.[0-5] | solaris2.[0-5].*) ;;
- *)
- # The compiler driver will combine and reorder linker options,
- # but understands `-z linker_flag'. GCC discards it without `$wl',
- # but is careful enough not to reorder.
- # Supported since Solaris 2.6 (maybe 2.5.1?)
- if test "$GCC" = yes; then
- whole_archive_flag_spec='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
- else
- whole_archive_flag_spec='-z allextract$convenience -z defaultextract'
- fi
- ;;
- esac
- link_all_deplibs=yes
- ;;
-
- sunos4*)
- if test "x$host_vendor" = xsequent; then
- # Use $CC to link under sequent, because it throws in some extra .o
- # files that make .init and .fini sections work.
- archive_cmds='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
- else
- archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
- fi
- hardcode_libdir_flag_spec='-L$libdir'
- hardcode_direct=yes
- hardcode_minus_L=yes
- hardcode_shlibpath_var=no
- ;;
-
- sysv4)
- case $host_vendor in
- sni)
- archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
- hardcode_direct=yes # is this really true???
- ;;
- siemens)
- ## LD is ld it makes a PLAMLIB
- ## CC just makes a GrossModule.
- archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags'
- reload_cmds='$CC -r -o $output$reload_objs'
- hardcode_direct=no
- ;;
- motorola)
- archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
- hardcode_direct=no #Motorola manual says yes, but my tests say they lie
- ;;
- esac
- runpath_var='LD_RUN_PATH'
- hardcode_shlibpath_var=no
- ;;
-
- sysv4.3*)
- archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
- hardcode_shlibpath_var=no
- export_dynamic_flag_spec='-Bexport'
- ;;
-
- sysv4*MP*)
- if test -d /usr/nec; then
- archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
- hardcode_shlibpath_var=no
- runpath_var=LD_RUN_PATH
- hardcode_runpath_var=yes
- ld_shlibs=yes
- fi
- ;;
-
- sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*)
- no_undefined_flag='${wl}-z,text'
- archive_cmds_need_lc=no
- hardcode_shlibpath_var=no
- runpath_var='LD_RUN_PATH'
-
- if test "$GCC" = yes; then
- archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- else
- archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- fi
- ;;
-
- sysv5* | sco3.2v5* | sco5v6*)
- # Note: We can NOT use -z defs as we might desire, because we do not
- # link with -lc, and that would cause any symbols used from libc to
- # always be unresolved, which means just about no library would
- # ever link correctly. If we're not using GNU ld we use -z text
- # though, which does catch some bad symbols but isn't as heavy-handed
- # as -z defs.
- no_undefined_flag='${wl}-z,text'
- allow_undefined_flag='${wl}-z,nodefs'
- archive_cmds_need_lc=no
- hardcode_shlibpath_var=no
- hardcode_libdir_flag_spec='${wl}-R,$libdir'
- hardcode_libdir_separator=':'
- link_all_deplibs=yes
- export_dynamic_flag_spec='${wl}-Bexport'
- runpath_var='LD_RUN_PATH'
-
- if test "$GCC" = yes; then
- archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- else
- archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- fi
- ;;
-
- uts4*)
- archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
- hardcode_libdir_flag_spec='-L$libdir'
- hardcode_shlibpath_var=no
- ;;
-
- *)
- ld_shlibs=no
- ;;
- esac
-
- if test x$host_vendor = xsni; then
- case $host in
- sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
- export_dynamic_flag_spec='${wl}-Blargedynsym'
- ;;
- esac
- fi
- fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs" >&5
-$as_echo "$ld_shlibs" >&6; }
-test "$ld_shlibs" = no && can_build_shared=no
-
-with_gnu_ld=$with_gnu_ld
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-#
-# Do we need to explicitly link libc?
-#
-case "x$archive_cmds_need_lc" in
-x|xyes)
- # Assume -lc should be added
- archive_cmds_need_lc=yes
-
- if test "$enable_shared" = yes && test "$GCC" = yes; then
- case $archive_cmds in
- *'~'*)
- # FIXME: we may have to deal with multi-command sequences.
- ;;
- '$CC '*)
- # Test whether the compiler implicitly links with -lc since on some
- # systems, -lgcc has to come before -lc. If gcc already passes -lc
- # to ld, don't add -lc before -lgcc.
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5
-$as_echo_n "checking whether -lc should be explicitly linked in... " >&6; }
-if ${lt_cv_archive_cmds_need_lc+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- $RM conftest*
- echo "$lt_simple_compile_test_code" > conftest.$ac_ext
-
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
- (eval $ac_compile) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } 2>conftest.err; then
- soname=conftest
- lib=conftest
- libobjs=conftest.$ac_objext
- deplibs=
- wl=$lt_prog_compiler_wl
- pic_flag=$lt_prog_compiler_pic
- compiler_flags=-v
- linker_flags=-v
- verstring=
- output_objdir=.
- libname=conftest
- lt_save_allow_undefined_flag=$allow_undefined_flag
- allow_undefined_flag=
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5
- (eval $archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }
- then
- lt_cv_archive_cmds_need_lc=no
- else
- lt_cv_archive_cmds_need_lc=yes
- fi
- allow_undefined_flag=$lt_save_allow_undefined_flag
- else
- cat conftest.err 1>&5
- fi
- $RM conftest*
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc" >&5
-$as_echo "$lt_cv_archive_cmds_need_lc" >&6; }
- archive_cmds_need_lc=$lt_cv_archive_cmds_need_lc
- ;;
- esac
- fi
- ;;
-esac
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5
-$as_echo_n "checking dynamic linker characteristics... " >&6; }
-
-if test "$GCC" = yes; then
- case $host_os in
- darwin*) lt_awk_arg="/^libraries:/,/LR/" ;;
- *) lt_awk_arg="/^libraries:/" ;;
- esac
- case $host_os in
- mingw* | cegcc*) lt_sed_strip_eq="s,=\([A-Za-z]:\),\1,g" ;;
- *) lt_sed_strip_eq="s,=/,/,g" ;;
- esac
- lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq`
- case $lt_search_path_spec in
- *\;*)
- # if the path contains ";" then we assume it to be the separator
- # otherwise default to the standard path separator (i.e. ":") - it is
- # assumed that no part of a normal pathname contains ";" but that should
- # okay in the real world where ";" in dirpaths is itself problematic.
- lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'`
- ;;
- *)
- lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"`
- ;;
- esac
- # Ok, now we have the path, separated by spaces, we can step through it
- # and add multilib dir if necessary.
- lt_tmp_lt_search_path_spec=
- lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
- for lt_sys_path in $lt_search_path_spec; do
- if test -d "$lt_sys_path/$lt_multi_os_dir"; then
- lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir"
- else
- test -d "$lt_sys_path" && \
- lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
- fi
- done
- lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk '
-BEGIN {RS=" "; FS="/|\n";} {
- lt_foo="";
- lt_count=0;
- for (lt_i = NF; lt_i > 0; lt_i--) {
- if ($lt_i != "" && $lt_i != ".") {
- if ($lt_i == "..") {
- lt_count++;
- } else {
- if (lt_count == 0) {
- lt_foo="/" $lt_i lt_foo;
- } else {
- lt_count--;
- }
- }
- }
- }
- if (lt_foo != "") { lt_freq[lt_foo]++; }
- if (lt_freq[lt_foo] == 1) { print lt_foo; }
-}'`
- # AWK program above erroneously prepends '/' to C:/dos/paths
- # for these hosts.
- case $host_os in
- mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\
- $SED 's,/\([A-Za-z]:\),\1,g'` ;;
- esac
- sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP`
-else
- sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
-fi
-library_names_spec=
-libname_spec='lib$name'
-soname_spec=
-shrext_cmds=".so"
-postinstall_cmds=
-postuninstall_cmds=
-finish_cmds=
-finish_eval=
-shlibpath_var=
-shlibpath_overrides_runpath=unknown
-version_type=none
-dynamic_linker="$host_os ld.so"
-sys_lib_dlsearch_path_spec="/lib /usr/lib"
-need_lib_prefix=unknown
-hardcode_into_libs=no
-
-# when you set need_version to no, make sure it does not cause -set_version
-# flags to be left without arguments
-need_version=unknown
-
-case $host_os in
-aix3*)
- version_type=linux
- library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
- shlibpath_var=LIBPATH
-
- # AIX 3 has no versioning support, so we append a major version to the name.
- soname_spec='${libname}${release}${shared_ext}$major'
- ;;
-
-aix[4-9]*)
- version_type=linux
- need_lib_prefix=no
- need_version=no
- hardcode_into_libs=yes
- if test "$host_cpu" = ia64; then
- # AIX 5 supports IA64
- library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
- shlibpath_var=LD_LIBRARY_PATH
- else
- # With GCC up to 2.95.x, collect2 would create an import file
- # for dependence libraries. The import file would start with
- # the line `#! .'. This would cause the generated library to
- # depend on `.', always an invalid library. This was fixed in
- # development snapshots of GCC prior to 3.0.
- case $host_os in
- aix4 | aix4.[01] | aix4.[01].*)
- if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
- echo ' yes '
- echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then
- :
- else
- can_build_shared=no
- fi
- ;;
- esac
- # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
- # soname into executable. Probably we can add versioning support to
- # collect2, so additional links can be useful in future.
- if test "$aix_use_runtimelinking" = yes; then
- # If using run time linking (on AIX 4.2 or later) use lib<name>.so
- # instead of lib<name>.a to let people know that these are not
- # typical AIX shared libraries.
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- else
- # We preserve .a as extension for shared libraries through AIX4.2
- # and later when we are not doing run time linking.
- library_names_spec='${libname}${release}.a $libname.a'
- soname_spec='${libname}${release}${shared_ext}$major'
- fi
- shlibpath_var=LIBPATH
- fi
- ;;
-
-amigaos*)
- case $host_cpu in
- powerpc)
- # Since July 2007 AmigaOS4 officially supports .so libraries.
- # When compiling the executable, add -use-dynld -Lsobjs: to the compileline.
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- ;;
- m68k)
- library_names_spec='$libname.ixlibrary $libname.a'
- # Create ${libname}_ixlibrary.a entries in /sys/libs.
- finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done'
- ;;
- esac
- ;;
-
-beos*)
- library_names_spec='${libname}${shared_ext}'
- dynamic_linker="$host_os ld.so"
- shlibpath_var=LIBRARY_PATH
- ;;
-
-bsdi[45]*)
- version_type=linux
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
- shlibpath_var=LD_LIBRARY_PATH
- sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
- sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
- # the default ld.so.conf also contains /usr/contrib/lib and
- # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
- # libtool to hard-code these into programs
- ;;
-
-cygwin* | mingw* | pw32* | cegcc*)
- version_type=windows
- shrext_cmds=".dll"
- need_version=no
- need_lib_prefix=no
-
- case $GCC,$host_os in
- yes,cygwin* | yes,mingw* | yes,pw32* | yes,cegcc*)
- library_names_spec='$libname.dll.a'
- # DLL is installed to $(libdir)/../bin by postinstall_cmds
- postinstall_cmds='base_file=`basename \${file}`~
- dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
- dldir=$destdir/`dirname \$dlpath`~
- test -d \$dldir || mkdir -p \$dldir~
- $install_prog $dir/$dlname \$dldir/$dlname~
- chmod a+x \$dldir/$dlname~
- if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
- eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
- fi'
- postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
- dlpath=$dir/\$dldll~
- $RM \$dlpath'
- shlibpath_overrides_runpath=yes
-
- case $host_os in
- cygwin*)
- # Cygwin DLLs use 'cyg' prefix rather than 'lib'
- soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
-
- sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"
- ;;
- mingw* | cegcc*)
- # MinGW DLLs use traditional 'lib' prefix
- soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
- ;;
- pw32*)
- # pw32 DLLs use 'pw' prefix rather than 'lib'
- library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
- ;;
- esac
- ;;
-
- *)
- library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib'
- ;;
- esac
- dynamic_linker='Win32 ld.exe'
- # FIXME: first we should search . and the directory the executable is in
- shlibpath_var=PATH
- ;;
-
-darwin* | rhapsody*)
- dynamic_linker="$host_os dyld"
- version_type=darwin
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext'
- soname_spec='${libname}${release}${major}$shared_ext'
- shlibpath_overrides_runpath=yes
- shlibpath_var=DYLD_LIBRARY_PATH
- shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
-
- sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"
- sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
- ;;
-
-dgux*)
- version_type=linux
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
- soname_spec='${libname}${release}${shared_ext}$major'
- shlibpath_var=LD_LIBRARY_PATH
- ;;
-
-freebsd* | dragonfly*)
- # DragonFly does not have aout. When/if they implement a new
- # versioning mechanism, adjust this.
- if test -x /usr/bin/objformat; then
- objformat=`/usr/bin/objformat`
- else
- case $host_os in
- freebsd[23].*) objformat=aout ;;
- *) objformat=elf ;;
- esac
- fi
- version_type=freebsd-$objformat
- case $version_type in
- freebsd-elf*)
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
- need_version=no
- need_lib_prefix=no
- ;;
- freebsd-*)
- library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
- need_version=yes
- ;;
- esac
- shlibpath_var=LD_LIBRARY_PATH
- case $host_os in
- freebsd2.*)
- shlibpath_overrides_runpath=yes
- ;;
- freebsd3.[01]* | freebsdelf3.[01]*)
- shlibpath_overrides_runpath=yes
- hardcode_into_libs=yes
- ;;
- freebsd3.[2-9]* | freebsdelf3.[2-9]* | \
- freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1)
- shlibpath_overrides_runpath=no
- hardcode_into_libs=yes
- ;;
- *) # from 4.6 on, and DragonFly
- shlibpath_overrides_runpath=yes
- hardcode_into_libs=yes
- ;;
- esac
- ;;
-
-haiku*)
- version_type=linux
- need_lib_prefix=no
- need_version=no
- dynamic_linker="$host_os runtime_loader"
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- shlibpath_var=LIBRARY_PATH
- shlibpath_overrides_runpath=yes
- sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
- hardcode_into_libs=yes
- ;;
-
-hpux9* | hpux10* | hpux11*)
- # Give a soname corresponding to the major version so that dld.sl refuses to
- # link against other versions.
- version_type=sunos
- need_lib_prefix=no
- need_version=no
- case $host_cpu in
- ia64*)
- shrext_cmds='.so'
- hardcode_into_libs=yes
- dynamic_linker="$host_os dld.so"
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- if test "X$HPUX_IA64_MODE" = X32; then
- sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
- else
- sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
- fi
- sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
- ;;
- hppa*64*)
- shrext_cmds='.sl'
- hardcode_into_libs=yes
- dynamic_linker="$host_os dld.sl"
- shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
- shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
- sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
- ;;
- *)
- shrext_cmds='.sl'
- dynamic_linker="$host_os dld.sl"
- shlibpath_var=SHLIB_PATH
- shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- ;;
- esac
- # HP-UX runs *really* slowly unless shared libraries are mode 555, ...
- postinstall_cmds='chmod 555 $lib'
- # or fails outright, so override atomically:
- install_override_mode=555
- ;;
-
-interix[3-9]*)
- version_type=linux
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=no
- hardcode_into_libs=yes
- ;;
-
-irix5* | irix6* | nonstopux*)
- case $host_os in
- nonstopux*) version_type=nonstopux ;;
- *)
- if test "$lt_cv_prog_gnu_ld" = yes; then
- version_type=linux
- else
- version_type=irix
- fi ;;
- esac
- need_lib_prefix=no
- need_version=no
- soname_spec='${libname}${release}${shared_ext}$major'
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
- case $host_os in
- irix5* | nonstopux*)
- libsuff= shlibsuff=
- ;;
- *)
- case $LD in # libtool.m4 will add one of these switches to LD
- *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
- libsuff= shlibsuff= libmagic=32-bit;;
- *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
- libsuff=32 shlibsuff=N32 libmagic=N32;;
- *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
- libsuff=64 shlibsuff=64 libmagic=64-bit;;
- *) libsuff= shlibsuff= libmagic=never-match;;
- esac
- ;;
- esac
- shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
- shlibpath_overrides_runpath=no
- sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
- sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
- hardcode_into_libs=yes
- ;;
-
-# No shared lib support for Linux oldld, aout, or coff.
-linux*oldld* | linux*aout* | linux*coff*)
- dynamic_linker=no
- ;;
-
-# This must be Linux ELF.
-
-# uclinux* changes (here and below) have been submitted to the libtool
-# project, but have not yet been accepted: they are GCC-local changes
-# for the time being. (See
-# https://lists.gnu.org/archive/html/libtool-patches/2018-05/msg00000.html)
-linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu* | uclinuxfdpiceabi)
- version_type=linux
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=no
-
- # Some binutils ld are patched to set DT_RUNPATH
- if ${lt_cv_shlibpath_overrides_runpath+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_shlibpath_overrides_runpath=no
- save_LDFLAGS=$LDFLAGS
- save_libdir=$libdir
- eval "libdir=/foo; wl=\"$lt_prog_compiler_wl\"; \
- LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec\""
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- if ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then :
- lt_cv_shlibpath_overrides_runpath=yes
-fi
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LDFLAGS=$save_LDFLAGS
- libdir=$save_libdir
-
-fi
-
- shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath
-
- # This implies no fast_install, which is unacceptable.
- # Some rework will be needed to allow for fast_install
- # before this can be enabled.
- hardcode_into_libs=yes
-
- # find out which ABI we are using
- libsuff=
- case "$host_cpu" in
- x86_64*|s390*|powerpc*|ppc*|sparc*)
- echo 'int i;' > conftest.$ac_ext
- if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; then
- case `/usr/bin/file conftest.$ac_objext` in
- *64-bit*)
- libsuff=
- if test x"$sys_lib_search_path_spec" = x"/lib /usr/lib /usr/local/lib"; then
- sys_lib_search_path_spec="/lib${libsuff} /usr/lib${libsuff} /usr/local/lib${libsuff}"
- fi
- sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff}"
- ;;
- *32-bit*)
- libsuff=32
- if test x"$sys_lib_search_path_spec" = x"/lib /usr/lib /usr/local/lib"; then
- sys_lib_search_path_spec="/lib${libsuff} /usr/lib${libsuff} /usr/local/lib${libsuff}"
- fi
- sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff}"
- ;;
- esac
- fi
- rm -rf conftest*
- ;;
- esac
-
- # Append ld.so.conf contents to the search path
- if test -f /etc/ld.so.conf; then
- lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '`
- sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff} $lt_ld_extra"
- fi
-
- # We used to test for /lib/ld.so.1 and disable shared libraries on
- # powerpc, because MkLinux only supported shared libraries with the
- # GNU dynamic linker. Since this was broken with cross compilers,
- # most powerpc-linux boxes support dynamic linking these days and
- # people can always --disable-shared, the test was removed, and we
- # assume the GNU/Linux dynamic linker is in use.
- dynamic_linker='GNU/Linux ld.so'
- ;;
-
-netbsd*)
- version_type=sunos
- need_lib_prefix=no
- need_version=no
- if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
- finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
- dynamic_linker='NetBSD (a.out) ld.so'
- else
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- dynamic_linker='NetBSD ld.elf_so'
- fi
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=yes
- hardcode_into_libs=yes
- ;;
-
-newsos6)
- version_type=linux
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=yes
- ;;
-
-*nto* | *qnx*)
- version_type=qnx
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=no
- hardcode_into_libs=yes
- dynamic_linker='ldqnx.so'
- ;;
-
-openbsd*)
- version_type=sunos
- sys_lib_dlsearch_path_spec="/usr/lib"
- need_lib_prefix=no
- # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
- case $host_os in
- openbsd3.3 | openbsd3.3.*) need_version=yes ;;
- *) need_version=no ;;
- esac
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
- finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
- shlibpath_var=LD_LIBRARY_PATH
- if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
- case $host_os in
- openbsd2.[89] | openbsd2.[89].*)
- shlibpath_overrides_runpath=no
- ;;
- *)
- shlibpath_overrides_runpath=yes
- ;;
- esac
- else
- shlibpath_overrides_runpath=yes
- fi
- ;;
-
-os2*)
- libname_spec='$name'
- shrext_cmds=".dll"
- need_lib_prefix=no
- library_names_spec='$libname${shared_ext} $libname.a'
- dynamic_linker='OS/2 ld.exe'
- shlibpath_var=LIBPATH
- ;;
-
-osf3* | osf4* | osf5*)
- version_type=osf
- need_lib_prefix=no
- need_version=no
- soname_spec='${libname}${release}${shared_ext}$major'
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- shlibpath_var=LD_LIBRARY_PATH
- sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
- sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
- ;;
-
-rdos*)
- dynamic_linker=no
- ;;
-
-solaris*)
- version_type=linux
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=yes
- hardcode_into_libs=yes
- # ldd complains unless libraries are executable
- postinstall_cmds='chmod +x $lib'
- ;;
-
-sunos4*)
- version_type=sunos
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
- finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=yes
- if test "$with_gnu_ld" = yes; then
- need_lib_prefix=no
- fi
- need_version=yes
- ;;
-
-sysv4 | sysv4.3*)
- version_type=linux
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- shlibpath_var=LD_LIBRARY_PATH
- case $host_vendor in
- sni)
- shlibpath_overrides_runpath=no
- need_lib_prefix=no
- runpath_var=LD_RUN_PATH
- ;;
- siemens)
- need_lib_prefix=no
- ;;
- motorola)
- need_lib_prefix=no
- need_version=no
- shlibpath_overrides_runpath=no
- sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
- ;;
- esac
- ;;
-
-sysv4*MP*)
- if test -d /usr/nec ;then
- version_type=linux
- library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
- soname_spec='$libname${shared_ext}.$major'
- shlibpath_var=LD_LIBRARY_PATH
- fi
- ;;
-
-sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
- version_type=freebsd-elf
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=yes
- hardcode_into_libs=yes
- if test "$with_gnu_ld" = yes; then
- sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
- else
- sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
- case $host_os in
- sco3.2v5*)
- sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
- ;;
- esac
- fi
- sys_lib_dlsearch_path_spec='/usr/lib'
- ;;
-
-tpf*)
- # TPF is a cross-target only. Preferred cross-host = GNU/Linux.
- version_type=linux
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=no
- hardcode_into_libs=yes
- ;;
-
-uts4*)
- version_type=linux
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- shlibpath_var=LD_LIBRARY_PATH
- ;;
-
-# Shared libraries for VwWorks, >= 7 only at this stage
-# and (fpic) still incompatible with "large" code models
-# in a few configurations. Only for RTP mode in any case,
-# and upon explicit request at configure time.
-vxworks7*)
- dynamic_linker=no
- case ${with_multisubdir}-${enable_shared} in
- *large*)
- ;;
- *mrtp*-yes)
- version_type=linux
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- dynamic_linker="$host_os module_loader"
- ;;
- esac
- ;;
-*)
- dynamic_linker=no
- ;;
-esac
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5
-$as_echo "$dynamic_linker" >&6; }
-test "$dynamic_linker" = no && can_build_shared=no
-
-variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
-if test "$GCC" = yes; then
- variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
-fi
-
-if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then
- sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec"
-fi
-if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then
- sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec"
-fi
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5
-$as_echo_n "checking how to hardcode library paths into programs... " >&6; }
-hardcode_action=
-if test -n "$hardcode_libdir_flag_spec" ||
- test -n "$runpath_var" ||
- test "X$hardcode_automatic" = "Xyes" ; then
-
- # We can hardcode non-existent directories.
- if test "$hardcode_direct" != no &&
- # If the only mechanism to avoid hardcoding is shlibpath_var, we
- # have to relink, otherwise we might link with an installed library
- # when we should be linking with a yet-to-be-installed one
- ## test "$_LT_TAGVAR(hardcode_shlibpath_var, )" != no &&
- test "$hardcode_minus_L" != no; then
- # Linking always hardcodes the temporary library directory.
- hardcode_action=relink
- else
- # We can link without hardcoding, and we can hardcode nonexisting dirs.
- hardcode_action=immediate
- fi
-else
- # We cannot hardcode anything, or else we can only hardcode existing
- # directories.
- hardcode_action=unsupported
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action" >&5
-$as_echo "$hardcode_action" >&6; }
-
-if test "$hardcode_action" = relink ||
- test "$inherit_rpath" = yes; then
- # Fast installation is not supported
- enable_fast_install=no
-elif test "$shlibpath_overrides_runpath" = yes ||
- test "$enable_shared" = no; then
- # Fast installation is not necessary
- enable_fast_install=needless
-fi
-
-
-
-
-
-
- if test "x$enable_dlopen" != xyes; then
- enable_dlopen=unknown
- enable_dlopen_self=unknown
- enable_dlopen_self_static=unknown
-else
- lt_cv_dlopen=no
- lt_cv_dlopen_libs=
-
- case $host_os in
- beos*)
- lt_cv_dlopen="load_add_on"
- lt_cv_dlopen_libs=
- lt_cv_dlopen_self=yes
- ;;
-
- mingw* | pw32* | cegcc*)
- lt_cv_dlopen="LoadLibrary"
- lt_cv_dlopen_libs=
- ;;
-
- cygwin*)
- lt_cv_dlopen="dlopen"
- lt_cv_dlopen_libs=
- ;;
-
- darwin*)
- # if libdl is installed we need to link against it
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
-$as_echo_n "checking for dlopen in -ldl... " >&6; }
-if ${ac_cv_lib_dl_dlopen+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-ldl $LIBS"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char dlopen ();
-int
-main ()
-{
-return dlopen ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_lib_dl_dlopen=yes
-else
- ac_cv_lib_dl_dlopen=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
-$as_echo "$ac_cv_lib_dl_dlopen" >&6; }
-if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
- lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
-else
-
- lt_cv_dlopen="dyld"
- lt_cv_dlopen_libs=
- lt_cv_dlopen_self=yes
-
-fi
-
- ;;
-
- *)
- ac_fn_c_check_func "$LINENO" "shl_load" "ac_cv_func_shl_load"
-if test "x$ac_cv_func_shl_load" = xyes; then :
- lt_cv_dlopen="shl_load"
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5
-$as_echo_n "checking for shl_load in -ldld... " >&6; }
-if ${ac_cv_lib_dld_shl_load+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-ldld $LIBS"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char shl_load ();
-int
-main ()
-{
-return shl_load ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_lib_dld_shl_load=yes
-else
- ac_cv_lib_dld_shl_load=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5
-$as_echo "$ac_cv_lib_dld_shl_load" >&6; }
-if test "x$ac_cv_lib_dld_shl_load" = xyes; then :
- lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"
-else
- ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen"
-if test "x$ac_cv_func_dlopen" = xyes; then :
- lt_cv_dlopen="dlopen"
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
-$as_echo_n "checking for dlopen in -ldl... " >&6; }
-if ${ac_cv_lib_dl_dlopen+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-ldl $LIBS"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char dlopen ();
-int
-main ()
-{
-return dlopen ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_lib_dl_dlopen=yes
-else
- ac_cv_lib_dl_dlopen=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
-$as_echo "$ac_cv_lib_dl_dlopen" >&6; }
-if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
- lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5
-$as_echo_n "checking for dlopen in -lsvld... " >&6; }
-if ${ac_cv_lib_svld_dlopen+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-lsvld $LIBS"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char dlopen ();
-int
-main ()
-{
-return dlopen ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_lib_svld_dlopen=yes
-else
- ac_cv_lib_svld_dlopen=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5
-$as_echo "$ac_cv_lib_svld_dlopen" >&6; }
-if test "x$ac_cv_lib_svld_dlopen" = xyes; then :
- lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5
-$as_echo_n "checking for dld_link in -ldld... " >&6; }
-if ${ac_cv_lib_dld_dld_link+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-ldld $LIBS"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char dld_link ();
-int
-main ()
-{
-return dld_link ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_lib_dld_dld_link=yes
-else
- ac_cv_lib_dld_dld_link=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_dld_link" >&5
-$as_echo "$ac_cv_lib_dld_dld_link" >&6; }
-if test "x$ac_cv_lib_dld_dld_link" = xyes; then :
- lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"
-fi
-
-
-fi
-
-
-fi
-
-
-fi
-
-
-fi
-
-
-fi
-
- ;;
- esac
-
- if test "x$lt_cv_dlopen" != xno; then
- enable_dlopen=yes
- else
- enable_dlopen=no
- fi
-
- case $lt_cv_dlopen in
- dlopen)
- save_CPPFLAGS="$CPPFLAGS"
- test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
-
- save_LDFLAGS="$LDFLAGS"
- wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
-
- save_LIBS="$LIBS"
- LIBS="$lt_cv_dlopen_libs $LIBS"
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a program can dlopen itself" >&5
-$as_echo_n "checking whether a program can dlopen itself... " >&6; }
-if ${lt_cv_dlopen_self+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test "$cross_compiling" = yes; then :
- lt_cv_dlopen_self=cross
-else
- lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
- lt_status=$lt_dlunknown
- cat > conftest.$ac_ext <<_LT_EOF
-#line 10778 "configure"
-#include "confdefs.h"
-
-#if HAVE_DLFCN_H
-#include <dlfcn.h>
-#endif
-
-#include <stdio.h>
-
-#ifdef RTLD_GLOBAL
-# define LT_DLGLOBAL RTLD_GLOBAL
-#else
-# ifdef DL_GLOBAL
-# define LT_DLGLOBAL DL_GLOBAL
-# else
-# define LT_DLGLOBAL 0
-# endif
-#endif
-
-/* We may have to define LT_DLLAZY_OR_NOW in the command line if we
- find out it does not work in some platform. */
-#ifndef LT_DLLAZY_OR_NOW
-# ifdef RTLD_LAZY
-# define LT_DLLAZY_OR_NOW RTLD_LAZY
-# else
-# ifdef DL_LAZY
-# define LT_DLLAZY_OR_NOW DL_LAZY
-# else
-# ifdef RTLD_NOW
-# define LT_DLLAZY_OR_NOW RTLD_NOW
-# else
-# ifdef DL_NOW
-# define LT_DLLAZY_OR_NOW DL_NOW
-# else
-# define LT_DLLAZY_OR_NOW 0
-# endif
-# endif
-# endif
-# endif
-#endif
-
-/* When -fvisbility=hidden is used, assume the code has been annotated
- correspondingly for the symbols needed. */
-#if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
-void fnord () __attribute__((visibility("default")));
-#endif
-
-void fnord () { int i=42; }
-int main ()
-{
- void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
- int status = $lt_dlunknown;
-
- if (self)
- {
- if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
- else
- {
- if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
- else puts (dlerror ());
- }
- /* dlclose (self); */
- }
- else
- puts (dlerror ());
-
- return status;
-}
-_LT_EOF
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
- (eval $ac_link) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then
- (./conftest; exit; ) >&5 2>/dev/null
- lt_status=$?
- case x$lt_status in
- x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;;
- x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;;
- x$lt_dlunknown|x*) lt_cv_dlopen_self=no ;;
- esac
- else :
- # compilation failed
- lt_cv_dlopen_self=no
- fi
-fi
-rm -fr conftest*
-
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self" >&5
-$as_echo "$lt_cv_dlopen_self" >&6; }
-
- if test "x$lt_cv_dlopen_self" = xyes; then
- wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a statically linked program can dlopen itself" >&5
-$as_echo_n "checking whether a statically linked program can dlopen itself... " >&6; }
-if ${lt_cv_dlopen_self_static+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test "$cross_compiling" = yes; then :
- lt_cv_dlopen_self_static=cross
-else
- lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
- lt_status=$lt_dlunknown
- cat > conftest.$ac_ext <<_LT_EOF
-#line 10884 "configure"
-#include "confdefs.h"
-
-#if HAVE_DLFCN_H
-#include <dlfcn.h>
-#endif
-
-#include <stdio.h>
-
-#ifdef RTLD_GLOBAL
-# define LT_DLGLOBAL RTLD_GLOBAL
-#else
-# ifdef DL_GLOBAL
-# define LT_DLGLOBAL DL_GLOBAL
-# else
-# define LT_DLGLOBAL 0
-# endif
-#endif
-
-/* We may have to define LT_DLLAZY_OR_NOW in the command line if we
- find out it does not work in some platform. */
-#ifndef LT_DLLAZY_OR_NOW
-# ifdef RTLD_LAZY
-# define LT_DLLAZY_OR_NOW RTLD_LAZY
-# else
-# ifdef DL_LAZY
-# define LT_DLLAZY_OR_NOW DL_LAZY
-# else
-# ifdef RTLD_NOW
-# define LT_DLLAZY_OR_NOW RTLD_NOW
-# else
-# ifdef DL_NOW
-# define LT_DLLAZY_OR_NOW DL_NOW
-# else
-# define LT_DLLAZY_OR_NOW 0
-# endif
-# endif
-# endif
-# endif
-#endif
-
-/* When -fvisbility=hidden is used, assume the code has been annotated
- correspondingly for the symbols needed. */
-#if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
-void fnord () __attribute__((visibility("default")));
-#endif
-
-void fnord () { int i=42; }
-int main ()
-{
- void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
- int status = $lt_dlunknown;
-
- if (self)
- {
- if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
- else
- {
- if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
- else puts (dlerror ());
- }
- /* dlclose (self); */
- }
- else
- puts (dlerror ());
-
- return status;
-}
-_LT_EOF
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
- (eval $ac_link) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then
- (./conftest; exit; ) >&5 2>/dev/null
- lt_status=$?
- case x$lt_status in
- x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;;
- x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;;
- x$lt_dlunknown|x*) lt_cv_dlopen_self_static=no ;;
- esac
- else :
- # compilation failed
- lt_cv_dlopen_self_static=no
- fi
-fi
-rm -fr conftest*
-
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self_static" >&5
-$as_echo "$lt_cv_dlopen_self_static" >&6; }
- fi
-
- CPPFLAGS="$save_CPPFLAGS"
- LDFLAGS="$save_LDFLAGS"
- LIBS="$save_LIBS"
- ;;
- esac
-
- case $lt_cv_dlopen_self in
- yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
- *) enable_dlopen_self=unknown ;;
- esac
-
- case $lt_cv_dlopen_self_static in
- yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
- *) enable_dlopen_self_static=unknown ;;
- esac
-fi
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-striplib=
-old_striplib=
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stripping libraries is possible" >&5
-$as_echo_n "checking whether stripping libraries is possible... " >&6; }
-if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then
- test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
- test -z "$striplib" && striplib="$STRIP --strip-unneeded"
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-else
-# FIXME - insert some real tests, host_os isn't really good enough
- case $host_os in
- darwin*)
- if test -n "$STRIP" ; then
- striplib="$STRIP -x"
- old_striplib="$STRIP -S"
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- fi
- ;;
- *)
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- ;;
- esac
-fi
-
-
-
-
-
-
-
-
-
-
-
-
- # Report which library types will actually be built
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libtool supports shared libraries" >&5
-$as_echo_n "checking if libtool supports shared libraries... " >&6; }
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $can_build_shared" >&5
-$as_echo "$can_build_shared" >&6; }
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries" >&5
-$as_echo_n "checking whether to build shared libraries... " >&6; }
- test "$can_build_shared" = "no" && enable_shared=no
-
- # On AIX, shared libraries and static libraries use the same namespace, and
- # are all built from PIC.
- case $host_os in
- aix3*)
- test "$enable_shared" = yes && enable_static=no
- if test -n "$RANLIB"; then
- archive_cmds="$archive_cmds~\$RANLIB \$lib"
- postinstall_cmds='$RANLIB $lib'
- fi
- ;;
-
- aix[4-9]*)
- if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
- test "$enable_shared" = yes && enable_static=no
- fi
- ;;
- esac
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5
-$as_echo "$enable_shared" >&6; }
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build static libraries" >&5
-$as_echo_n "checking whether to build static libraries... " >&6; }
- # Make sure either enable_shared or enable_static is yes.
- test "$enable_shared" = yes || enable_static=yes
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_static" >&5
-$as_echo "$enable_static" >&6; }
-
-
-
-
-fi
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-CC="$lt_save_CC"
-
-
-
-
-
-
-
-
-
-
-
-
-
- ac_config_commands="$ac_config_commands libtool"
-
-
-
-
-# Only expand once:
-
-
-
-# The tests for host and target for $enable_largefile require
-# canonical names.
-
-
-
-# As the $enable_largefile decision depends on --enable-plugins we must set it
-# even in directories otherwise not depending on the $plugins option.
-
-
- maybe_plugins=no
- for ac_header in dlfcn.h
-do :
- ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default
-"
-if test "x$ac_cv_header_dlfcn_h" = xyes; then :
- cat >>confdefs.h <<_ACEOF
-#define HAVE_DLFCN_H 1
-_ACEOF
- maybe_plugins=yes
-fi
-
-done
-
- for ac_header in windows.h
-do :
- ac_fn_c_check_header_compile "$LINENO" "windows.h" "ac_cv_header_windows_h" "$ac_includes_default
-"
-if test "x$ac_cv_header_windows_h" = xyes; then :
- cat >>confdefs.h <<_ACEOF
-#define HAVE_WINDOWS_H 1
-_ACEOF
- maybe_plugins=yes
-fi
-
-done
-
-
- # Check whether --enable-plugins was given.
-if test "${enable_plugins+set}" = set; then :
- enableval=$enable_plugins; case "${enableval}" in
- no) plugins=no ;;
- *) plugins=yes
- if test "$maybe_plugins" != "yes" ; then
- as_fn_error $? "Building with plugin support requires a host that supports dlopen." "$LINENO" 5
- fi ;;
- esac
-else
- plugins=$maybe_plugins
-
-fi
-
- if test "$plugins" = "yes"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing dlsym" >&5
-$as_echo_n "checking for library containing dlsym... " >&6; }
-if ${ac_cv_search_dlsym+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_func_search_save_LIBS=$LIBS
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char dlsym ();
-int
-main ()
-{
-return dlsym ();
- ;
- return 0;
-}
-_ACEOF
-for ac_lib in '' dl; do
- if test -z "$ac_lib"; then
- ac_res="none required"
- else
- ac_res=-l$ac_lib
- LIBS="-l$ac_lib $ac_func_search_save_LIBS"
- fi
- if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_search_dlsym=$ac_res
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext
- if ${ac_cv_search_dlsym+:} false; then :
- break
-fi
-done
-if ${ac_cv_search_dlsym+:} false; then :
-
-else
- ac_cv_search_dlsym=no
-fi
-rm conftest.$ac_ext
-LIBS=$ac_func_search_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_dlsym" >&5
-$as_echo "$ac_cv_search_dlsym" >&6; }
-ac_res=$ac_cv_search_dlsym
-if test "$ac_res" != no; then :
- test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
-
-fi
-
- fi
-
-
-case "${host}" in
- sparc-*-solaris*|i?86-*-solaris*)
- # On native 32-bit Solaris/SPARC and x86, large-file and procfs support
- # were mutually exclusive until Solaris 11.3. Without procfs support,
- # the bfd/ elf module cannot provide certain routines such as
- # elfcore_write_prpsinfo or elfcore_write_prstatus. So unless the user
- # explicitly requested large-file support through the
- # --enable-largefile switch, disable large-file support in favor of
- # procfs support.
- #
- # Check if <sys/procfs.h> is incompatible with large-file support.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#define _FILE_OFFSET_BITS 64
-#define _STRUCTURED_PROC 1
-#include <sys/procfs.h>
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- acx_cv_procfs_lfs=yes
-else
- acx_cv_procfs_lfs=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- #
- # Forcefully disable large-file support only if necessary, gdb is in
- # tree and enabled.
- if test "${target}" = "${host}" -a "$acx_cv_procfs_lfs" = no \
- -a -d $srcdir/../gdb -a "$enable_gdb" != no; then
- : ${enable_largefile="no"}
- if test "$plugins" = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
-plugin support disabled; require large-file support which is incompatible with GDB." >&5
-$as_echo "$as_me: WARNING:
-plugin support disabled; require large-file support which is incompatible with GDB." >&2;}
- plugins=no
- fi
- fi
- #
- # Explicitly undef _FILE_OFFSET_BITS if enable_largefile=no for the
- # benefit of g++ 9+ which predefines it on Solaris.
- if test "$enable_largefile" = no; then
- LARGEFILE_CPPFLAGS="-U_FILE_OFFSET_BITS"
-
- fi
- ;;
-esac
-
-# Check whether --enable-largefile was given.
-if test "${enable_largefile+set}" = set; then :
- enableval=$enable_largefile;
-fi
-
-if test "$enable_largefile" != no; then
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
-$as_echo_n "checking for special C compiler options needed for large files... " >&6; }
-if ${ac_cv_sys_largefile_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_cv_sys_largefile_CC=no
- if test "$GCC" != yes; then
- ac_save_CC=$CC
- while :; do
- # IRIX 6.2 and later do not support large files by default,
- # so use the C compiler's -n32 option if that helps.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <sys/types.h>
- /* Check that off_t can represent 2**63 - 1 correctly.
- We can't simply define LARGE_OFF_T to be 9223372036854775807,
- since some C++ compilers masquerading as C compilers
- incorrectly reject 9223372036854775807. */
-#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
- int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
- && LARGE_OFF_T % 2147483647 == 1)
- ? 1 : -1];
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
- if ac_fn_c_try_compile "$LINENO"; then :
- break
-fi
-rm -f core conftest.err conftest.$ac_objext
- CC="$CC -n32"
- if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_sys_largefile_CC=' -n32'; break
-fi
-rm -f core conftest.err conftest.$ac_objext
- break
- done
- CC=$ac_save_CC
- rm -f conftest.$ac_ext
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
-$as_echo "$ac_cv_sys_largefile_CC" >&6; }
- if test "$ac_cv_sys_largefile_CC" != no; then
- CC=$CC$ac_cv_sys_largefile_CC
- fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
-$as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
-if ${ac_cv_sys_file_offset_bits+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- while :; do
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <sys/types.h>
- /* Check that off_t can represent 2**63 - 1 correctly.
- We can't simply define LARGE_OFF_T to be 9223372036854775807,
- since some C++ compilers masquerading as C compilers
- incorrectly reject 9223372036854775807. */
-#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
- int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
- && LARGE_OFF_T % 2147483647 == 1)
- ? 1 : -1];
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_sys_file_offset_bits=no; break
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#define _FILE_OFFSET_BITS 64
-#include <sys/types.h>
- /* Check that off_t can represent 2**63 - 1 correctly.
- We can't simply define LARGE_OFF_T to be 9223372036854775807,
- since some C++ compilers masquerading as C compilers
- incorrectly reject 9223372036854775807. */
-#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
- int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
- && LARGE_OFF_T % 2147483647 == 1)
- ? 1 : -1];
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_sys_file_offset_bits=64; break
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- ac_cv_sys_file_offset_bits=unknown
- break
-done
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
-$as_echo "$ac_cv_sys_file_offset_bits" >&6; }
-case $ac_cv_sys_file_offset_bits in #(
- no | unknown) ;;
- *)
-cat >>confdefs.h <<_ACEOF
-#define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
-_ACEOF
-;;
-esac
-rm -rf conftest*
- if test $ac_cv_sys_file_offset_bits = unknown; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
-$as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
-if ${ac_cv_sys_large_files+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- while :; do
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <sys/types.h>
- /* Check that off_t can represent 2**63 - 1 correctly.
- We can't simply define LARGE_OFF_T to be 9223372036854775807,
- since some C++ compilers masquerading as C compilers
- incorrectly reject 9223372036854775807. */
-#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
- int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
- && LARGE_OFF_T % 2147483647 == 1)
- ? 1 : -1];
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_sys_large_files=no; break
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#define _LARGE_FILES 1
-#include <sys/types.h>
- /* Check that off_t can represent 2**63 - 1 correctly.
- We can't simply define LARGE_OFF_T to be 9223372036854775807,
- since some C++ compilers masquerading as C compilers
- incorrectly reject 9223372036854775807. */
-#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
- int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
- && LARGE_OFF_T % 2147483647 == 1)
- ? 1 : -1];
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_sys_large_files=1; break
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- ac_cv_sys_large_files=unknown
- break
-done
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
-$as_echo "$ac_cv_sys_large_files" >&6; }
-case $ac_cv_sys_large_files in #(
- no | unknown) ;;
- *)
-cat >>confdefs.h <<_ACEOF
-#define _LARGE_FILES $ac_cv_sys_large_files
-_ACEOF
-;;
-esac
-rm -rf conftest*
- fi
-
-
-fi
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to compare bootstrapped objects" >&5
-$as_echo_n "checking how to compare bootstrapped objects... " >&6; }
-if ${gcc_cv_prog_cmp_skip+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- echo abfoo >t1
- echo cdfoo >t2
- gcc_cv_prog_cmp_skip='tail -c +17 $$f1 > tmp-foo1; tail -c +17 $$f2 > tmp-foo2; cmp tmp-foo1 tmp-foo2'
- if cmp t1 t2 2 2 > /dev/null 2>&1; then
- if cmp t1 t2 1 1 > /dev/null 2>&1; then
- :
- else
- gcc_cv_prog_cmp_skip='cmp $$f1 $$f2 16 16'
- fi
- fi
- if cmp --ignore-initial=2 t1 t2 > /dev/null 2>&1; then
- if cmp --ignore-initial=1 t1 t2 > /dev/null 2>&1; then
- :
- else
- gcc_cv_prog_cmp_skip='cmp --ignore-initial=16 $$f1 $$f2'
- fi
- fi
- rm t1 t2
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_prog_cmp_skip" >&5
-$as_echo "$gcc_cv_prog_cmp_skip" >&6; }
-do_compare="$gcc_cv_prog_cmp_skip"
-
-
-
-# Check whether --enable-targets was given.
-if test "${enable_targets+set}" = set; then :
- enableval=$enable_targets; case "${enableval}" in
- yes | "") as_fn_error $? "enable-targets option must specify target names or 'all'" "$LINENO" 5
- ;;
- no) enable_targets= ;;
- *) enable_targets=$enableval ;;
-esac
-fi
-
-ac_checking=
-. ${srcdir}/../bfd/development.sh
-test "$development" = true && ac_checking=yes
-# Check whether --enable-checking was given.
-if test "${enable_checking+set}" = set; then :
- enableval=$enable_checking; case "${enableval}" in
- no|none) ac_checking= ;;
- *) ac_checking=yes ;;
-esac
-fi
-if test x$ac_checking != x ; then
-
-$as_echo "#define ENABLE_CHECKING 1" >>confdefs.h
-
-fi
-
-# PR gas/19109
-# Decide the default method for compressing debug sections.
-ac_default_compressed_debug_sections=unset
-# Provide a configure time option to override our default.
-# Check whether --enable-compressed_debug_sections was given.
-if test "${enable_compressed_debug_sections+set}" = set; then :
- enableval=$enable_compressed_debug_sections; case ,"${enableval}", in
- ,yes, | ,all, | *,gas,*) ac_default_compressed_debug_sections=yes ;;
- ,no, | ,none,) ac_default_compressed_debug_sections=no ;;
- *) ac_default_compressed_debug_sections=unset ;;
-esac
-fi
-
-# Select default compression algorithm.
-ac_default_compressed_debug_sections_algorithm=COMPRESS_DEBUG_GABI_ZLIB
-# Check whether --enable-default_compressed_debug_sections_algorithm was given.
-if test "${enable_default_compressed_debug_sections_algorithm+set}" = set; then :
- enableval=$enable_default_compressed_debug_sections_algorithm; case "${enableval}" in
- zstd) ac_default_compressed_debug_sections_algorithm=COMPRESS_DEBUG_ZSTD ;;
-esac
-fi
-
-# PR gas/19520
-# Decide if x86 assembler should generate relax relocations.
-ac_default_x86_relax_relocations=unset
-# Provide a configure time option to override our default.
-# Check whether --enable-x86_relax_relocations was given.
-if test "${enable_x86_relax_relocations+set}" = set; then :
- enableval=$enable_x86_relax_relocations; case "${enableval}" in
- no) ac_default_x86_relax_relocations=0 ;;
-esac
-fi
-
-# Decide if ELF assembler should generate common symbols with the
-# STT_COMMON type.
-ac_default_elf_stt_common=unset
-# Provide a configure time option to override our default.
-# Check whether --enable-elf_stt_common was given.
-if test "${enable_elf_stt_common+set}" = set; then :
- enableval=$enable_elf_stt_common; case "${enableval}" in
- yes) ac_default_elf_stt_common=1 ;;
-esac
-fi
-
-
-# Decide if the ELF assembler should default to generating
-# GNU Build notes if none are provided by the input.
-ac_default_generate_build_notes=0
-# Provide a configuration option to override the default.
-# Check whether --enable-generate_build_notes was given.
-if test "${enable_generate_build_notes+set}" = set; then :
- enableval=$enable_generate_build_notes; case "${enableval}" in
- yes) ac_default_generate_build_notes=1 ;;
- no) ac_default_generate_build_notes=0 ;;
-esac
-fi
-
-# Decide if the MIPS assembler should default to enable MIPS fix Loongson3
-# LLSC errata.
-ac_default_mips_fix_loongson3_llsc=unset
-# Provide a configuration option to override the default.
-# Check whether --enable-mips-fix-loongson3-llsc was given.
-if test "${enable_mips_fix_loongson3_llsc+set}" = set; then :
- enableval=$enable_mips_fix_loongson3_llsc; case "${enableval}" in
- yes) ac_default_mips_fix_loongson3_llsc=1 ;;
- no) ac_default_mips_fix_loongson3_llsc=0 ;;
-esac
-fi
-
-# Decide if the x86 ELF assembler should default to generating GNU x86
-# used ISA and feature properties.
-ac_default_generate_x86_used_note=unset
-# Provide a configuration option to override the default.
-# Check whether --enable-x86-used-note was given.
-if test "${enable_x86_used_note+set}" = set; then :
- enableval=$enable_x86_used_note; case "${enableval}" in
- yes) ac_default_generate_x86_used_note=1 ;;
- no) ac_default_generate_x86_used_note=0 ;;
-esac
-fi
-
-# Decide if the RISC-V ELF assembler should default to generating attribute.
-ac_default_generate_riscv_attr=unset
-# Provide a configuration option to override the default.
-# Check whether --enable-default-riscv-attribute was given.
-if test "${enable_default_riscv_attribute+set}" = set; then :
- enableval=$enable_default_riscv_attribute; case "${enableval}" in
- yes) ac_default_generate_riscv_attr=1 ;;
- no) ac_default_generate_riscv_attr=0 ;;
-esac
-fi
-
-using_cgen=no
-
-
-# Set the 'development' global.
-. $srcdir/../bfd/development.sh
-
-# Set acp_cpp_for_build variable
-ac_cpp_for_build="$CC_FOR_BUILD -E $CPPFLAGS_FOR_BUILD"
-
-# Default set of GCC warnings to enable.
-GCC_WARN_CFLAGS="-W -Wall -Wstrict-prototypes -Wmissing-prototypes"
-GCC_WARN_CFLAGS_FOR_BUILD="-W -Wall -Wstrict-prototypes -Wmissing-prototypes"
-
-# Add -Wshadow if the compiler is a sufficiently recent version of GCC.
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-__GNUC__
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "(^[0-3]$|^__GNUC__$)" >/dev/null 2>&1; then :
-
-else
- GCC_WARN_CFLAGS="$GCC_WARN_CFLAGS -Wshadow"
-fi
-rm -f conftest*
-
-
-# Add -Wstack-usage if the compiler is a sufficiently recent version of GCC.
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-__GNUC__
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "(^[0-4]$|^__GNUC__$)" >/dev/null 2>&1; then :
-
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-__clang__
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "^__clang__$" >/dev/null 2>&1; then :
- GCC_WARN_CFLAGS="$GCC_WARN_CFLAGS -Wstack-usage=262144"
-fi
-rm -f conftest*
-
-fi
-rm -f conftest*
-
-
-# Set WARN_WRITE_STRINGS if the compiler supports -Wwrite-strings.
-WARN_WRITE_STRINGS=""
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-__GNUC__
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "(^[0-3]$|^__GNUC__$)" >/dev/null 2>&1; then :
-
-else
- WARN_WRITE_STRINGS="-Wwrite-strings"
-fi
-rm -f conftest*
-
-
-# Verify CC_FOR_BUILD to be compatible with warning flags
-
-# Add -Wshadow if the compiler is a sufficiently recent version of GCC.
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-__GNUC__
-_ACEOF
-if (eval "$ac_cpp_for_build conftest.$ac_ext") 2>&5 |
- $EGREP "(^[0-3]$|^__GNUC__$)" >/dev/null 2>&1; then :
-
-else
- GCC_WARN_CFLAGS_FOR_BUILD="$GCC_WARN_CFLAGS_FOR_BUILD -Wshadow"
-fi
-rm -f conftest*
-
-
-# Add -Wstack-usage if the compiler is a sufficiently recent version of GCC.
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-__GNUC__
-_ACEOF
-if (eval "$ac_cpp_for_build conftest.$ac_ext") 2>&5 |
- $EGREP "(^[0-4]$|^__GNUC__$)" >/dev/null 2>&1; then :
-
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-__clang__
-_ACEOF
-if (eval "$ac_cpp_for_build conftest.$ac_ext") 2>&5 |
- $EGREP "^__clang__$" >/dev/null 2>&1; then :
- GCC_WARN_CFLAGS_FOR_BUILD="$GCC_WARN_CFLAGS_FOR_BUILD -Wstack-usage=262144"
-fi
-rm -f conftest*
-
-fi
-rm -f conftest*
-
-
-# Check whether --enable-werror was given.
-if test "${enable_werror+set}" = set; then :
- enableval=$enable_werror; case "${enableval}" in
- yes | y) ERROR_ON_WARNING="yes" ;;
- no | n) ERROR_ON_WARNING="no" ;;
- *) as_fn_error $? "bad value ${enableval} for --enable-werror" "$LINENO" 5 ;;
- esac
-fi
-
-
-# Disable -Wformat by default when using gcc on mingw
-case "${host}" in
- *-*-mingw32*)
- if test "${GCC}" = yes -a -z "${ERROR_ON_WARNING}" ; then
- GCC_WARN_CFLAGS="$GCC_WARN_CFLAGS -Wno-format"
- GCC_WARN_CFLAGS_FOR_BUILD="$GCC_WARN_CFLAGS_FOR_BUILD -Wno-format"
- fi
- ;;
- *) ;;
-esac
-
-# Enable -Werror by default when using gcc. Turn it off for releases.
-if test "${GCC}" = yes -a -z "${ERROR_ON_WARNING}" -a "$development" = true ; then
- ERROR_ON_WARNING=yes
-fi
-
-NO_WERROR=
-if test "${ERROR_ON_WARNING}" = yes ; then
- GCC_WARN_CFLAGS="$GCC_WARN_CFLAGS -Werror"
- GCC_WARN_CFLAGS_FOR_BUILD="$GCC_WARN_CFLAGS_FOR_BUILD -Werror"
- NO_WERROR="-Wno-error"
-fi
-
-if test "${GCC}" = yes ; then
- WARN_CFLAGS="${GCC_WARN_CFLAGS}"
- WARN_CFLAGS_FOR_BUILD="${GCC_WARN_CFLAGS_FOR_BUILD}"
-fi
-
-# Check whether --enable-build-warnings was given.
-if test "${enable_build_warnings+set}" = set; then :
- enableval=$enable_build_warnings; case "${enableval}" in
- yes) WARN_CFLAGS="${GCC_WARN_CFLAGS}"
- WARN_CFLAGS_FOR_BUILD="${GCC_WARN_CFLAGS_FOR_BUILD}";;
- no) if test "${GCC}" = yes ; then
- WARN_CFLAGS="-w"
- WARN_CFLAGS_FOR_BUILD="-w"
- fi;;
- ,*) t=`echo "${enableval}" | sed -e "s/,/ /g"`
- WARN_CFLAGS="${GCC_WARN_CFLAGS} ${t}"
- WARN_CFLAGS_FOR_BUILD="${GCC_WARN_CFLAGS_FOR_BUILD} ${t}";;
- *,) t=`echo "${enableval}" | sed -e "s/,/ /g"`
- WARN_CFLAGS="${t} ${GCC_WARN_CFLAGS}"
- WARN_CFLAGS_FOR_BUILD="${t} ${GCC_WARN_CFLAGS_FOR_BUILD}";;
- *) WARN_CFLAGS=`echo "${enableval}" | sed -e "s/,/ /g"`
- WARN_CFLAGS_FOR_BUILD=`echo "${enableval}" | sed -e "s/,/ /g"`;;
-esac
-fi
-
-
-if test x"$silent" != x"yes" && test x"$WARN_CFLAGS" != x""; then
- echo "Setting warning flags = $WARN_CFLAGS" 6>&1
-fi
-
-
-
-
-
-
-
-# Generate a header file
-ac_config_headers="$ac_config_headers config.h:config.in"
-
-
-
-# Check whether --with-cpu was given.
-if test "${with_cpu+set}" = set; then :
- withval=$with_cpu;
-cat >>confdefs.h <<_ACEOF
-#define TARGET_WITH_CPU "${with_cpu}"
-_ACEOF
-
-fi
-
-
-# PR 14072
-
-
-# If we are on a DOS filesystem, we must use gdb.ini rather than
-# .gdbinit.
-case "${host}" in
- *-*-msdos* | *-*-go32* | *-*-mingw32* | *-*-windows*)
- GDBINIT="gdb.ini"
- ac_config_files="$ac_config_files gdb.ini:gdbinit.in"
-
- ;;
- *)
- GDBINIT=".gdbinit"
- ac_config_files="$ac_config_files .gdbinit:gdbinit.in"
-
- ;;
-esac
-
-
-#We need this for the host.
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
-$as_echo_n "checking whether byte ordering is bigendian... " >&6; }
-if ${ac_cv_c_bigendian+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_cv_c_bigendian=unknown
- # See if we're dealing with a universal compiler.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#ifndef __APPLE_CC__
- not a universal capable compiler
- #endif
- typedef int dummy;
-
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
-
- # Check for potential -arch flags. It is not universal unless
- # there are at least two -arch flags with different values.
- ac_arch=
- ac_prev=
- for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
- if test -n "$ac_prev"; then
- case $ac_word in
- i?86 | x86_64 | ppc | ppc64)
- if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
- ac_arch=$ac_word
- else
- ac_cv_c_bigendian=universal
- break
- fi
- ;;
- esac
- ac_prev=
- elif test "x$ac_word" = "x-arch"; then
- ac_prev=arch
- fi
- done
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- if test $ac_cv_c_bigendian = unknown; then
- # See if sys/param.h defines the BYTE_ORDER macro.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <sys/types.h>
- #include <sys/param.h>
-
-int
-main ()
-{
-#if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
- && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
- && LITTLE_ENDIAN)
- bogus endian macros
- #endif
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- # It does; now see whether it defined to BIG_ENDIAN or not.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <sys/types.h>
- #include <sys/param.h>
-
-int
-main ()
-{
-#if BYTE_ORDER != BIG_ENDIAN
- not big endian
- #endif
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_c_bigendian=yes
-else
- ac_cv_c_bigendian=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- fi
- if test $ac_cv_c_bigendian = unknown; then
- # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <limits.h>
-
-int
-main ()
-{
-#if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
- bogus endian macros
- #endif
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- # It does; now see whether it defined to _BIG_ENDIAN or not.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <limits.h>
-
-int
-main ()
-{
-#ifndef _BIG_ENDIAN
- not big endian
- #endif
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_c_bigendian=yes
-else
- ac_cv_c_bigendian=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- fi
- if test $ac_cv_c_bigendian = unknown; then
- # Compile a test program.
- if test "$cross_compiling" = yes; then :
- # Try to guess by grepping values from an object file.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-short int ascii_mm[] =
- { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
- short int ascii_ii[] =
- { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
- int use_ascii (int i) {
- return ascii_mm[i] + ascii_ii[i];
- }
- short int ebcdic_ii[] =
- { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
- short int ebcdic_mm[] =
- { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
- int use_ebcdic (int i) {
- return ebcdic_mm[i] + ebcdic_ii[i];
- }
- extern int foo;
-
-int
-main ()
-{
-return use_ascii (foo) == use_ebcdic (foo);
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
- ac_cv_c_bigendian=yes
- fi
- if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
- if test "$ac_cv_c_bigendian" = unknown; then
- ac_cv_c_bigendian=no
- else
- # finding both strings is unlikely to happen, but who knows?
- ac_cv_c_bigendian=unknown
- fi
- fi
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$ac_includes_default
-int
-main ()
-{
-
- /* Are we little or big endian? From Harbison&Steele. */
- union
- {
- long int l;
- char c[sizeof (long int)];
- } u;
- u.l = 1;
- return u.c[sizeof (long int) - 1] == 1;
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_run "$LINENO"; then :
- ac_cv_c_bigendian=no
-else
- ac_cv_c_bigendian=yes
-fi
-rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
- conftest.$ac_objext conftest.beam conftest.$ac_ext
-fi
-
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
-$as_echo "$ac_cv_c_bigendian" >&6; }
- case $ac_cv_c_bigendian in #(
- yes)
- $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
-;; #(
- no)
- ;; #(
- universal)
-
-$as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
-
- ;; #(
- *)
- as_fn_error $? "unknown endianness
- presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
- esac
-
-
-te_file=generic
-
-# Makefile target for installing gas in $(tooldir)/bin.
-install_tooldir=install-exec-tooldir
-
-canon_targets=""
-all_targets=no
-if test -n "$enable_targets" ; then
- for t in `echo $enable_targets | sed 's/,/ /g'`; do
- if test $t = "all"; then
- all_targets=yes
- continue
- fi
- result=`$ac_config_sub $t 2>/dev/null`
- if test -n "$result" ; then
- canon_targets="$canon_targets $result"
-# else
-# # Permit "all", etc. We don't support it yet though.
-# canon_targets="$canon_targets $t"
- fi
- done
- _gas_uniq_list="$canon_targets"
-_gas_uniq_newlist=""
-for _gas_uniq_i in _gas_uniq_dummy $_gas_uniq_list ; do
- case $_gas_uniq_i in
- _gas_uniq_dummy) ;;
- *) case " $_gas_uniq_newlist " in
- *" $_gas_uniq_i "*) ;;
- *) _gas_uniq_newlist="$_gas_uniq_newlist $_gas_uniq_i" ;;
- esac ;;
- esac
-done
-canon_targets=$_gas_uniq_newlist
-
-fi
-
-emulations=""
-
-for this_target in $target $canon_targets ; do
-
- targ=${this_target}
- . ${srcdir}/configure.tgt
-
- case ${target_cpu} in
- crisv32)
-
-cat >>confdefs.h <<_ACEOF
-#define DEFAULT_CRIS_ARCH $arch
-_ACEOF
-
- ;;
- esac
-
- if test ${this_target} = $target ; then
- target_cpu_type=${cpu_type}
- elif test ${target_cpu_type} != ${cpu_type} ; then
- continue
- fi
-
- generic_target=${cpu_type}-${target_vendor}-${target_os}
- case ${generic_target} in
- i386-*-msdosdjgpp* \
- | i386-*-go32*)
-
-$as_echo "#define STRICTCOFF 1" >>confdefs.h
-
- ;;
-
- i386-*-linux-* | x86_64-*-linux-*)
- if test ${this_target} = $target \
- && test ${ac_default_generate_x86_used_note} = unset; then
- ac_default_generate_x86_used_note=1
- fi
- ;;
-
- i386-*-solaris2 \
- | x86_64-*-solaris2 \
- | i386-*-solaris2.[0-9] \
- | i386-*-solaris2.1[01] \
- | x86_64-*-solaris2.1[01])
- if test ${this_target} = $target \
- && test ${ac_default_x86_relax_relocations} = unset; then
- ac_default_x86_relax_relocations=0
- fi
- ;;
-
- microblaze*)
- ;;
-
- ppc-*-aix5.[01]*)
- ;;
- ppc-*-aix[5-9].*)
-
-$as_echo "#define AIX_WEAK_SUPPORT 1" >>confdefs.h
-
- ;;
- ppc-*-solaris*)
- if test ${this_target} = $target; then
-
-$as_echo "#define TARGET_SOLARIS_COMMENT 1" >>confdefs.h
-
- fi
- if test x${endian} = xbig; then
- as_fn_error $? "Solaris must be configured little endian" "$LINENO" 5
- fi
- ;;
- esac
-
- if test ${this_target} = $target ; then
- endian_def=
- if test x${endian} = xbig; then
- endian_def=1
- elif test x${endian} = xlittle; then
- endian_def=0
- fi
- if test x${endian_def} != x; then
-
-cat >>confdefs.h <<_ACEOF
-#define TARGET_BYTES_BIG_ENDIAN $endian_def
-_ACEOF
-
- fi
- fi
-
-# Other random stuff.
-
- case ${cpu_type} in
- mips)
- # Set mips_cpu to the name of the default CPU.
- case ${target_cpu} in
- mips | mipsbe | mipseb | mipsle | mipsel | mips64 | mips64el)
- mips_cpu=from-abi
- ;;
- mipsisa32 | mipsisa32el)
- mips_cpu=mips32
- ;;
- mipsisa32r2 | mipsisa32r2el)
- mips_cpu=mips32r2
- ;;
- mipsisa32r3 | mipsisa32r3el)
- mips_cpu=mips32r3
- ;;
- mipsisa32r5 | mipsisa32r5el)
- mips_cpu=mips32r5
- ;;
- mipsisa32r6 | mipsisa32r6el)
- mips_cpu=mips32r6
- ;;
- mipsisa64 | mipsisa64el)
- mips_cpu=mips64
- ;;
- mipsisa64r2 | mipsisa64r2el)
- mips_cpu=mips64r2
- ;;
- mipsisa64r3 | mipsisa64r3el)
- mips_cpu=mips64r3
- ;;
- mipsisa64r5 | mipsisa64r5el)
- mips_cpu=mips64r5
- ;;
- mipsisa64r6 | mipsisa64r6el)
- mips_cpu=mips64r6
- ;;
- mipstx39 | mipstx39el)
- mips_cpu=r3900
- ;;
- mips64vr | mips64vrel)
- mips_cpu=vr4100
- ;;
- mipsisa32r2* | mipsisa64r2*)
- mips_cpu=`echo $target_cpu | sed -e 's/[a-z]*..r2//' -e 's/el$//'`
- ;;
- mipsisa32r6* | mipsisa64r6*)
- mips_cpu=`echo $target_cpu | sed -e 's/[a-z]*..r6//' -e 's/el$//'`
- ;;
- mips64* | mipsisa64* | mipsisa32*)
- mips_cpu=`echo $target_cpu | sed -e 's/[a-z]*..//' -e 's/el$//'`
- ;;
- mips*)
- mips_cpu=`echo $target_cpu | sed -e 's/^mips//' -e 's/el$//'`
- ;;
- *)
- as_fn_error $? "$target_cpu isn't a supported MIPS CPU name" "$LINENO" 5
- ;;
- esac
- # See whether it's appropriate to set EF_MIPS_ABI_O32 for o32
- # binaries. It's a GNU extension that some OSes don't understand.
- case ${target} in
- *-*-irix*)
- use_ef_mips_abi_o32=0
- ;;
- *)
- use_ef_mips_abi_o32=1
- ;;
- esac
- # If Vendor is IMG, then MIPSr6 is used
- case ${target} in
- mips*-img-*)
- mips_cpu=mips32r6
- ;;
- esac
- # Decide whether to generate 32-bit or 64-bit code by default.
- # Used to resolve -march=from-abi when an embedded ABI is selected.
- case ${target} in
- mips64*-*-* | mipsisa64*-*-*)
- mips_default_64bit=1
- ;;
- *)
- mips_default_64bit=0
- ;;
- esac
- # Decide which ABI to target by default.
- case ${target} in
- mips64*-openbsd* | mips64*-linux-gnuabi64)
- mips_default_abi=N64_ABI
- ;;
- mips64*-linux* | mips-sgi-irix6* | mips64*-freebsd* \
- | mips64*-kfreebsd*-gnu | mips64*-ps2-elf*)
- mips_default_abi=N32_ABI
- ;;
- mips*-linux* | mips*-freebsd* | mips*-kfreebsd*-gnu)
- mips_default_abi=O32_ABI
- ;;
- *)
- mips_default_abi=NO_ABI
- ;;
- esac
-
-cat >>confdefs.h <<_ACEOF
-#define MIPS_CPU_STRING_DEFAULT "$mips_cpu"
-_ACEOF
-
-
-cat >>confdefs.h <<_ACEOF
-#define USE_EF_MIPS_ABI_O32 $use_ef_mips_abi_o32
-_ACEOF
-
-
-cat >>confdefs.h <<_ACEOF
-#define MIPS_DEFAULT_64BIT $mips_default_64bit
-_ACEOF
-
-
-cat >>confdefs.h <<_ACEOF
-#define MIPS_DEFAULT_ABI $mips_default_abi
-_ACEOF
-
- ;;
- esac
-
- # Do we need the opcodes library?
- case ${cpu_type} in
- vax | tic30 | i386 | arm)
- ;;
-
- *)
- need_opcodes=yes
-
- case "${enable_shared}" in
- yes) shared_opcodes=true ;;
- *opcodes*) shared_opcodes=true ;;
- *) shared_opcodes=false ;;
- esac
- ;;
- esac
-
- # Any other special object files needed ?
- case ${cpu_type} in
-
- bfin)
- for f in config/bfin-parse.o config/bfin-lex-wrapper.o; do
- case " $extra_objects " in
- *" $f "*) ;;
- *) extra_objects="$extra_objects $f" ;;
- esac
- done
- ;;
-
- bpf)
- if test $this_target = $target ; then
-
-cat >>confdefs.h <<_ACEOF
-#define DEFAULT_ARCH "${arch}"
-_ACEOF
-
- fi
- ;;
- epiphany | fr30 | ip2k | iq2000 | lm32 | m32r | or1k)
- using_cgen=yes
- ;;
-
- loongarch)
- for f in config/loongarch-parse.o config/loongarch-lex-wrapper.o; do
- case " $extra_objects " in
- *" $f "*) ;;
- *) extra_objects="$extra_objects $f" ;;
- esac
- done
- # --target=loongarch[32|64]-*-*. */
- if test $this_target = $target ; then
-
-cat >>confdefs.h <<_ACEOF
-#define DEFAULT_ARCH "${arch}"
-_ACEOF
-
- fi
- ;;
-
- m32c)
- using_cgen=yes
- ;;
- frv)
- using_cgen=yes
- ;;
- kvx)
- for f in config/kvx-parse.o; do
- case " $extra_objects " in
- *" $f "*) ;;
- *) extra_objects="$extra_objects $f" ;;
- esac
- done
- ;;
- m68k)
- f=config/m68k-parse.o
- case " $extra_objects " in
- *" $f "*) ;;
- *) extra_objects="$extra_objects $f" ;;
- esac
- ;;
-
- mep)
- using_cgen=yes
- ;;
-
- mips)
- for f in itbl-parse.o itbl-lex-wrapper.o itbl-ops.o; do
- case " $extra_objects " in
- *" $f "*) ;;
- *) extra_objects="$extra_objects $f" ;;
- esac
- done
- ;;
-
- mt)
- using_cgen=yes
- ;;
-
- nds32)
- # setup NDS32_LINUX_TOOLCHAIN definition
- if test "linux" = $em; then
-
-$as_echo "#define NDS32_LINUX_TOOLCHAIN 1" >>confdefs.h
-
- else
-
-$as_echo "#define NDS32_LINUX_TOOLCHAIN 0" >>confdefs.h
-
- fi
-
- # Decide BASELINE, REDUCED_REGS, FPU_DP_EXT, FPU_SP_EXT features
- # based on arch_name.
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for default configuration of --with-arch" >&5
-$as_echo_n "checking for default configuration of --with-arch... " >&6; }
- if test "x${with_arch}" != x; then
- case ${with_arch} in
- v2j | v2s | v2f | v2 | v3m | v3j | v3s | v3f | v3 )
-
-cat >>confdefs.h <<_ACEOF
-#define NDS32_DEFAULT_ARCH_NAME "$with_arch"
-_ACEOF
-
- ;;
- *)
- as_fn_error $? "This kind of arch name does *NOT* exist!" "$LINENO" 5
- ;;
- esac
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_arch" >&5
-$as_echo "$with_arch" >&6; }
-
- # Decide features one by one.
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for default configuration of --enable-dx-regs" >&5
-$as_echo_n "checking for default configuration of --enable-dx-regs... " >&6; }
- if test "x${enable_dx_regs}" = xyes; then
-
-$as_echo "#define NDS32_DEFAULT_DX_REGS 1" >>confdefs.h
-
- else
-
-$as_echo "#define NDS32_DEFAULT_DX_REGS 0" >>confdefs.h
-
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_dx_regs" >&5
-$as_echo "$enable_dx_regs" >&6; }
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for default configuration of --enable-perf-ext" >&5
-$as_echo_n "checking for default configuration of --enable-perf-ext... " >&6; }
- if test "x${enable_perf_ext}" = xno; then
-
-$as_echo "#define NDS32_DEFAULT_PERF_EXT 0" >>confdefs.h
-
- else
-
-$as_echo "#define NDS32_DEFAULT_PERF_EXT 1" >>confdefs.h
-
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_perf_ext" >&5
-$as_echo "$enable_perf_ext" >&6; }
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for default configuration of --enable-perf-ext2" >&5
-$as_echo_n "checking for default configuration of --enable-perf-ext2... " >&6; }
- if test "x${enable_perf_ext2}" = xno; then
-
-$as_echo "#define NDS32_DEFAULT_PERF_EXT2 0" >>confdefs.h
-
- else
-
-$as_echo "#define NDS32_DEFAULT_PERF_EXT2 1" >>confdefs.h
-
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_perf_ext2" >&5
-$as_echo "$enable_perf_ext2" >&6; }
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for default configuration of --enable-string-ext" >&5
-$as_echo_n "checking for default configuration of --enable-string-ext... " >&6; }
- if test "x${enable_string_ext}" = xno; then
-
-$as_echo "#define NDS32_DEFAULT_STRING_EXT 0" >>confdefs.h
-
- else
-
-$as_echo "#define NDS32_DEFAULT_STRING_EXT 1" >>confdefs.h
-
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_string_ext" >&5
-$as_echo "$enable_string_ext" >&6; }
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for default configuration of --enable-audio-ext" >&5
-$as_echo_n "checking for default configuration of --enable-audio-ext... " >&6; }
- if test "x${enable_audio_ext}" = xno; then
-
-$as_echo "#define NDS32_DEFAULT_AUDIO_EXT 0" >>confdefs.h
-
- else
-
-$as_echo "#define NDS32_DEFAULT_AUDIO_EXT 1" >>confdefs.h
-
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_audio_ext" >&5
-$as_echo "$enable_audio_ext" >&6; }
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for default configuration of --enable-dsp-ext" >&5
-$as_echo_n "checking for default configuration of --enable-dsp-ext... " >&6; }
- if test "x${enable_dsp_ext}" = xno; then
-
-$as_echo "#define NDS32_DEFAULT_DSP_EXT 0" >>confdefs.h
-
- else
-
-$as_echo "#define NDS32_DEFAULT_DSP_EXT 1" >>confdefs.h
-
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_dsp_ext" >&5
-$as_echo "$enable_dsp_ext" >&6; }
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for default configuration of --enable-zol-ext" >&5
-$as_echo_n "checking for default configuration of --enable-zol-ext... " >&6; }
- if test "x${enable_zol_ext}" = xno; then
-
-$as_echo "#define NDS32_DEFAULT_ZOL_EXT 0" >>confdefs.h
-
- else
-
-$as_echo "#define NDS32_DEFAULT_ZOL_EXT 1" >>confdefs.h
-
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_zol_ext" >&5
-$as_echo "$enable_zol_ext" >&6; }
- ;;
-
- aarch64 | i386 | s390 | sparc)
- if test $this_target = $target ; then
-
-cat >>confdefs.h <<_ACEOF
-#define DEFAULT_ARCH "${arch}"
-_ACEOF
-
- fi
- ;;
-
- riscv)
- # --target=riscv[32|64]-*-*. */
- if test $this_target = $target ; then
-
-cat >>confdefs.h <<_ACEOF
-#define DEFAULT_ARCH "${arch}"
-_ACEOF
-
- fi
-
- # --with-arch=<value>. The syntax of <value> is same as Gas option -march.
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for default configuration of --with-arch" >&5
-$as_echo_n "checking for default configuration of --with-arch... " >&6; }
- if test "x${with_arch}" != x; then
-
-cat >>confdefs.h <<_ACEOF
-#define DEFAULT_RISCV_ARCH_WITH_EXT "$with_arch"
-_ACEOF
-
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_arch" >&5
-$as_echo "$with_arch" >&6; }
-
- # --with-isa-spec=[2.2|20190608|20191213].
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for default configuration of --with-isa-spec" >&5
-$as_echo_n "checking for default configuration of --with-isa-spec... " >&6; }
- if test "x${with_isa_spec}" != x; then
-
-cat >>confdefs.h <<_ACEOF
-#define DEFAULT_RISCV_ISA_SPEC "$with_isa_spec"
-_ACEOF
-
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_isa_spec" >&5
-$as_echo "$with_isa_spec" >&6; }
-
- # --with-priv-spec=[1.9.1|1.10|1.11|1.12].
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for default configuration of --with-priv-spec" >&5
-$as_echo_n "checking for default configuration of --with-priv-spec... " >&6; }
- if test "x${with_priv_spec}" != x; then
-
-cat >>confdefs.h <<_ACEOF
-#define DEFAULT_RISCV_PRIV_SPEC "$with_priv_spec"
-_ACEOF
-
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_priv_spec" >&5
-$as_echo "$with_priv_spec" >&6; }
- ;;
-
- rl78)
- f=config/rl78-parse.o
- case " $extra_objects " in
- *" $f "*) ;;
- *) extra_objects="$extra_objects $f" ;;
- esac
- ;;
-
- rx)
- f=config/rx-parse.o
- case " $extra_objects " in
- *" $f "*) ;;
- *) extra_objects="$extra_objects $f" ;;
- esac
- ;;
-
- xstormy16)
- using_cgen=yes
- ;;
-
- xtensa)
- f=config/xtensa-relax.o
- case " $extra_objects " in
- *" $f "*) ;;
- *) extra_objects="$extra_objects $f" ;;
- esac
- ;;
-
- *)
- ;;
- esac
-
- if test $using_cgen = yes ; then
- f=cgen.o
- case " $extra_objects " in
- *" $f "*) ;;
- *) extra_objects="$extra_objects $f" ;;
- esac
- fi
-
-# See if we really can support this configuration with the emulation code.
-
- if test $this_target = $target ; then
- obj_format=$fmt
- te_file=$em
- fi
-
- case ${te_file} in
- vms)
- f=config/te-vms.o
- case " $extra_objects " in
- *" $f "*) ;;
- *) extra_objects="$extra_objects $f" ;;
- esac ;;
- esac
-
-# From target name and format, produce a list of supported emulations.
-
- case ${generic_target}-${fmt} in
- mips-*-*-*) case "$endian" in
- big) emulation="mipsbelf mipslelf mipself" ;;
- *) emulation="mipslelf mipsbelf mipself" ;;
- esac ;;
- # i386-pc-pe-coff != i386-pc-coff.
- i386-*-pe-coff) ;;
- # Uncommenting the next line will turn on support for i386 AOUT
- # for the default linux configuration
- # i386-*-linux*-elf) emulation="i386elf i386aout" ;;
- #
- i386-*-aout) emulation="i386aout" ;;
- i386-*-coff) emulation="i386coff" ;;
- i386-*-elf) emulation="i386elf" ;;
-
- # Always all formats. The first stated emulation becomes the default.
- cris-*-*aout*) emulation="crisaout criself" ;;
- cris-*-*) emulation="criself crisaout" ;;
- esac
-
- emulations="$emulations $emulation"
-
-done
-
-if test ${ac_default_x86_relax_relocations} = unset; then
- ac_default_x86_relax_relocations=1
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define DEFAULT_GENERATE_X86_RELAX_RELOCATIONS $ac_default_x86_relax_relocations
-_ACEOF
-
-
-if test ${ac_default_elf_stt_common} = unset; then
- ac_default_elf_stt_common=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define DEFAULT_GENERATE_ELF_STT_COMMON $ac_default_elf_stt_common
-_ACEOF
-
-
-
-cat >>confdefs.h <<_ACEOF
-#define DEFAULT_GENERATE_BUILD_NOTES $ac_default_generate_build_notes
-_ACEOF
-
-
-if test ${ac_default_generate_x86_used_note} = unset; then
- ac_default_generate_x86_used_note=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define DEFAULT_X86_USED_NOTE $ac_default_generate_x86_used_note
-_ACEOF
-
-
-if test ${ac_default_generate_riscv_attr} = unset; then
- ac_default_generate_riscv_attr=1
-fi
-
-
-cat >>confdefs.h <<_ACEOF
-#define DEFAULT_RISCV_ATTR $ac_default_generate_riscv_attr
-_ACEOF
-
-
-if test ${ac_default_mips_fix_loongson3_llsc} = unset; then
- ac_default_mips_fix_loongson3_llsc=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define DEFAULT_MIPS_FIX_LOONGSON3_LLSC $ac_default_mips_fix_loongson3_llsc
-_ACEOF
-
-
-if test x$ac_default_compressed_debug_sections = xyes ; then
-
-$as_echo "#define DEFAULT_FLAG_COMPRESS_DEBUG 1" >>confdefs.h
-
-fi
-
-
-cat >>confdefs.h <<_ACEOF
-#define DEFAULT_COMPRESSED_DEBUG_ALGORITHM $ac_default_compressed_debug_sections_algorithm
-_ACEOF
-
-
-# Turn on all targets if possible
-if test ${all_targets} = "yes"; then
- case ${target_cpu_type} in
- i386)
- case ${obj_format} in
- aout)
- emulations="$emulations i386coff i386elf"
- ;;
- coff)
- emulations="$emulations i386aout i386elf"
- ;;
- elf)
- emulations="$emulations i386aout i386coff"
- ;;
- esac
- ;;
- x86_64)
- case ${obj_format} in
- aout)
- emulations="$emulations i386coff i386elf"
- ;;
- coff)
- emulations="$emulations i386aout i386elf"
- ;;
- elf)
- emulations="$emulations i386aout i386coff"
- ;;
- esac
- ;;
- esac
-fi
-
-# PE code has way too many macros tweaking behaviour
-case ${te_file} in
- pe*) emulations="" ;;
-esac
-
-# Assign floating point type. Most processors with FP support
-# IEEE FP. On those that don't support FP at all, usually IEEE
-# is emulated.
-case ${target_cpu} in
- vax | pdp11 ) atof=vax ;;
- *) atof=ieee ;;
-esac
-
-case "${obj_format}" in
- "") as_fn_error $? "GAS does not know what format to use for target ${target}" "$LINENO" 5 ;;
-esac
-
-# Unfortunately the cpu in cpu-opc.h file isn't always $(TARGET_CPU).
-cgen_cpu_prefix=""
-if test $using_cgen = yes ; then
- case ${target_cpu} in
- or1knd)
- cgen_cpu_prefix=or1k ;;
- *) cgen_cpu_prefix=${target_cpu} ;;
- esac
-
-
-$as_echo "#define USING_CGEN 1" >>confdefs.h
-
-fi
-
-
-if test ! -r ${srcdir}/config/tc-${target_cpu_type}.c; then
- as_fn_error $? "GAS does not support target CPU ${target_cpu_type}" "$LINENO" 5
-fi
-
-if test ! -r ${srcdir}/config/obj-${obj_format}.c; then
- as_fn_error $? "GAS does not have support for object file format ${obj_format}" "$LINENO" 5
-fi
-
-# Some COFF configurations want these random other flags set.
-case ${obj_format} in
- coff)
- case ${target_cpu_type} in
- i386)
-$as_echo "#define I386COFF 1" >>confdefs.h
- ;;
- x86_64)
-$as_echo "#define I386COFF 1" >>confdefs.h
- ;;
- esac
- ;;
-esac
-
-# Getting this done right is going to be a bitch. Each configuration specified
-# with --enable-targets=... should be checked for environment, format, cpu
-# setting.
-#
-# For each configuration, the necessary object file support code must be linked
-# in. This might be only one, it might be up to four. The necessary emulation
-# code needs to be provided, too.
-#
-# And then there's "--enable-targets=all"....
-#
-# For now, just always do it for MIPS ELF configurations. Sigh.
-
-formats="${obj_format}"
-emfiles=""
-EMULATIONS=""
-_gas_uniq_list="$emulations"
-_gas_uniq_newlist=""
-for _gas_uniq_i in _gas_uniq_dummy $_gas_uniq_list ; do
- case $_gas_uniq_i in
- _gas_uniq_dummy) ;;
- *) case " $_gas_uniq_newlist " in
- *" $_gas_uniq_i "*) ;;
- *) _gas_uniq_newlist="$_gas_uniq_newlist $_gas_uniq_i" ;;
- esac ;;
- esac
-done
-emulations=$_gas_uniq_newlist
-
-for em in . $emulations ; do
- case $em in
- .) continue ;;
- mipsbelf | mipslelf | mipself)
- fmt=elf file=mipself ;;
- *coff)
- fmt=coff file=$em ;;
- *aout)
- fmt=aout file=$em ;;
- *elf)
- fmt=elf file=$em ;;
- esac
- formats="$formats $fmt"
- emfiles="$emfiles config/e-$file.o"
- EMULATIONS="$EMULATIONS &$em,"
-done
-_gas_uniq_list="$formats"
-_gas_uniq_newlist=""
-for _gas_uniq_i in _gas_uniq_dummy $_gas_uniq_list ; do
- case $_gas_uniq_i in
- _gas_uniq_dummy) ;;
- *) case " $_gas_uniq_newlist " in
- *" $_gas_uniq_i "*) ;;
- *) _gas_uniq_newlist="$_gas_uniq_newlist $_gas_uniq_i" ;;
- esac ;;
- esac
-done
-formats=$_gas_uniq_newlist
-
-_gas_uniq_list="$emfiles"
-_gas_uniq_newlist=""
-for _gas_uniq_i in _gas_uniq_dummy $_gas_uniq_list ; do
- case $_gas_uniq_i in
- _gas_uniq_dummy) ;;
- *) case " $_gas_uniq_newlist " in
- *" $_gas_uniq_i "*) ;;
- *) _gas_uniq_newlist="$_gas_uniq_newlist $_gas_uniq_i" ;;
- esac ;;
- esac
-done
-emfiles=$_gas_uniq_newlist
-
-if test `set . $formats ; shift ; echo $#` -gt 1 ; then
- for fmt in $formats ; do
- case $fmt in
- aout)
-$as_echo "#define OBJ_MAYBE_AOUT 1" >>confdefs.h
- ;;
- coff)
-$as_echo "#define OBJ_MAYBE_COFF 1" >>confdefs.h
- ;;
- ecoff)
-$as_echo "#define OBJ_MAYBE_ECOFF 1" >>confdefs.h
- ;;
- elf)
-$as_echo "#define OBJ_MAYBE_ELF 1" >>confdefs.h
- ;;
- generic)
-$as_echo "#define OBJ_MAYBE_GENERIC 1" >>confdefs.h
- ;;
- som)
-$as_echo "#define OBJ_MAYBE_SOM 1" >>confdefs.h
- ;;
- esac
- extra_objects="$extra_objects config/obj-$fmt.o"
- done
- obj_format=multi
-fi
-if test `set . $emfiles ; shift ; echo $#` -gt 0 ; then
- DEFAULT_EMULATION=`set . $emulations ; echo $2`
- # e-mipself has more than one emulation per file, e-i386* has just one at the
- # moment. If only one emulation is specified, then don't define
- # USE_EMULATIONS or include any of the e-files as they will only be bloat.
- case "${obj_format}${emfiles}" in
- multi* | *mipself*)
- extra_objects="$extra_objects $emfiles"
-
-$as_echo "#define USE_EMULATIONS 1" >>confdefs.h
- ;;
- esac
-fi
-
-
-cat >>confdefs.h <<_ACEOF
-#define EMULATIONS $EMULATIONS
-_ACEOF
-
-
-cat >>confdefs.h <<_ACEOF
-#define DEFAULT_EMULATION "$DEFAULT_EMULATION"
-_ACEOF
-
-
-reject_dev_configs=yes
-
-case ${reject_dev_configs}-${dev} in
- yes-yes) # Oops.
- as_fn_error $? "GAS does not support the ${generic_target} configuration." "$LINENO" 5
- ;;
-esac
-
-
-
-
-
-
-
-# do we need the opcodes library?
-case "${need_opcodes}" in
-yes)
- OPCODES_LIB=../opcodes/libopcodes.la
- ;;
-esac
-
-
-
-
-cat >>confdefs.h <<_ACEOF
-#define TARGET_ALIAS "${target_alias}"
-_ACEOF
-
-
-cat >>confdefs.h <<_ACEOF
-#define TARGET_CANONICAL "${target}"
-_ACEOF
-
-
-cat >>confdefs.h <<_ACEOF
-#define TARGET_CPU "${target_cpu}"
-_ACEOF
-
-
-cat >>confdefs.h <<_ACEOF
-#define TARGET_VENDOR "${target_vendor}"
-_ACEOF
-
-
-cat >>confdefs.h <<_ACEOF
-#define TARGET_OS "${target_os}"
-_ACEOF
-
-
-for ac_prog in 'bison -y' byacc
-do
- # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_YACC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$YACC"; then
- ac_cv_prog_YACC="$YACC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_YACC="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-YACC=$ac_cv_prog_YACC
-if test -n "$YACC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $YACC" >&5
-$as_echo "$YACC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$YACC" && break
-done
-test -n "$YACC" || YACC="yacc"
-
-for ac_prog in flex lex
-do
- # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_LEX+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$LEX"; then
- ac_cv_prog_LEX="$LEX" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_LEX="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-LEX=$ac_cv_prog_LEX
-if test -n "$LEX"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LEX" >&5
-$as_echo "$LEX" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$LEX" && break
-done
-test -n "$LEX" || LEX=":"
-
-case "$LEX" in
- :|*"missing "*) ;;
- *) cat >conftest.l <<_ACEOF
-%%
-a { ECHO; }
-b { REJECT; }
-c { yymore (); }
-d { yyless (1); }
-e { /* IRIX 6.5 flex 2.5.4 underquotes its yyless argument. */
- yyless ((input () != 0)); }
-f { unput (yytext[0]); }
-. { BEGIN INITIAL; }
-%%
-#ifdef YYTEXT_POINTER
-extern char *yytext;
-#endif
-int
-main (void)
-{
- return ! yylex () + ! yywrap ();
-}
-_ACEOF
-{ { ac_try="$LEX conftest.l"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$LEX conftest.l") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking lex output file root" >&5
-$as_echo_n "checking lex output file root... " >&6; }
-if ${ac_cv_prog_lex_root+:} false; then :
- $as_echo_n "(cached) " >&6
-else
-
-if test -f lex.yy.c; then
- ac_cv_prog_lex_root=lex.yy
-elif test -f lexyy.c; then
- ac_cv_prog_lex_root=lexyy
-else
- as_fn_error $? "cannot find output from $LEX; giving up" "$LINENO" 5
-fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_lex_root" >&5
-$as_echo "$ac_cv_prog_lex_root" >&6; }
-LEX_OUTPUT_ROOT=$ac_cv_prog_lex_root
-
-if test -z "${LEXLIB+set}"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking lex library" >&5
-$as_echo_n "checking lex library... " >&6; }
-if ${ac_cv_lib_lex+:} false; then :
- $as_echo_n "(cached) " >&6
-else
-
- ac_save_LIBS=$LIBS
- ac_cv_lib_lex='none needed'
- for ac_lib in '' -lfl -ll; do
- LIBS="$ac_lib $ac_save_LIBS"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-`cat $LEX_OUTPUT_ROOT.c`
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_lib_lex=$ac_lib
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- test "$ac_cv_lib_lex" != 'none needed' && break
- done
- LIBS=$ac_save_LIBS
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_lex" >&5
-$as_echo "$ac_cv_lib_lex" >&6; }
- test "$ac_cv_lib_lex" != 'none needed' && LEXLIB=$ac_cv_lib_lex
-fi
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether yytext is a pointer" >&5
-$as_echo_n "checking whether yytext is a pointer... " >&6; }
-if ${ac_cv_prog_lex_yytext_pointer+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- # POSIX says lex can declare yytext either as a pointer or an array; the
-# default is implementation-dependent. Figure out which it is, since
-# not all implementations provide the %pointer and %array declarations.
-ac_cv_prog_lex_yytext_pointer=no
-ac_save_LIBS=$LIBS
-LIBS="$LEXLIB $ac_save_LIBS"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
- #define YYTEXT_POINTER 1
-`cat $LEX_OUTPUT_ROOT.c`
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_prog_lex_yytext_pointer=yes
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_save_LIBS
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_lex_yytext_pointer" >&5
-$as_echo "$ac_cv_prog_lex_yytext_pointer" >&6; }
-if test $ac_cv_prog_lex_yytext_pointer = yes; then
-
-$as_echo "#define YYTEXT_POINTER 1" >>confdefs.h
-
-fi
-rm -f conftest.l $LEX_OUTPUT_ROOT.c
- ;;
-esac
-if test "$LEX" = :; then
- LEX=${am_missing_run}flex
-fi
-
-ALL_LINGUAS="es fi fr id ja ru rw sv tr uk zh_CN"
-
- MKINSTALLDIRS=
- if test -n "$ac_aux_dir"; then
- case "$ac_aux_dir" in
- /*) MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs" ;;
- *) MKINSTALLDIRS="\$(top_builddir)/$ac_aux_dir/mkinstalldirs" ;;
- esac
- fi
- if test -z "$MKINSTALLDIRS"; then
- MKINSTALLDIRS="\$(top_srcdir)/mkinstalldirs"
- fi
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NLS is requested" >&5
-$as_echo_n "checking whether NLS is requested... " >&6; }
- # Check whether --enable-nls was given.
-if test "${enable_nls+set}" = set; then :
- enableval=$enable_nls; USE_NLS=$enableval
-else
- USE_NLS=yes
-fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_NLS" >&5
-$as_echo "$USE_NLS" >&6; }
-
-
-
-
-
-
-# Prepare PATH_SEPARATOR.
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-
-# Find out how to test for executable files. Don't use a zero-byte file,
-# as systems may use methods other than mode bits to determine executability.
-cat >conf$$.file <<_ASEOF
-#! /bin/sh
-exit 0
-_ASEOF
-chmod +x conf$$.file
-if test -x conf$$.file >/dev/null 2>&1; then
- ac_executable_p="test -x"
-else
- ac_executable_p="test -f"
-fi
-rm -f conf$$.file
-
-# Extract the first word of "msgfmt", so it can be a program name with args.
-set dummy msgfmt; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_MSGFMT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case "$MSGFMT" in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
- ;;
- *)
- ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH; do
- IFS="$ac_save_IFS"
- test -z "$ac_dir" && ac_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
- if $ac_dir/$ac_word --statistics /dev/null >/dev/null 2>&1 &&
- (if $ac_dir/$ac_word --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- ac_cv_path_MSGFMT="$ac_dir/$ac_word$ac_exec_ext"
- break 2
- fi
- fi
- done
- done
- IFS="$ac_save_IFS"
- test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT=":"
- ;;
-esac
-fi
-MSGFMT="$ac_cv_path_MSGFMT"
-if test "$MSGFMT" != ":"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGFMT" >&5
-$as_echo "$MSGFMT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- # Extract the first word of "gmsgfmt", so it can be a program name with args.
-set dummy gmsgfmt; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_GMSGFMT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $GMSGFMT in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
- ;;
- *)
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_path_GMSGFMT="$as_dir/$ac_word$ac_exec_ext"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
- test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT"
- ;;
-esac
-fi
-GMSGFMT=$ac_cv_path_GMSGFMT
-if test -n "$GMSGFMT"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GMSGFMT" >&5
-$as_echo "$GMSGFMT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-
-
-# Prepare PATH_SEPARATOR.
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-
-# Find out how to test for executable files. Don't use a zero-byte file,
-# as systems may use methods other than mode bits to determine executability.
-cat >conf$$.file <<_ASEOF
-#! /bin/sh
-exit 0
-_ASEOF
-chmod +x conf$$.file
-if test -x conf$$.file >/dev/null 2>&1; then
- ac_executable_p="test -x"
-else
- ac_executable_p="test -f"
-fi
-rm -f conf$$.file
-
-# Extract the first word of "xgettext", so it can be a program name with args.
-set dummy xgettext; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_XGETTEXT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case "$XGETTEXT" in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
- ;;
- *)
- ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH; do
- IFS="$ac_save_IFS"
- test -z "$ac_dir" && ac_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
- if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >/dev/null 2>&1 &&
- (if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- ac_cv_path_XGETTEXT="$ac_dir/$ac_word$ac_exec_ext"
- break 2
- fi
- fi
- done
- done
- IFS="$ac_save_IFS"
- test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":"
- ;;
-esac
-fi
-XGETTEXT="$ac_cv_path_XGETTEXT"
-if test "$XGETTEXT" != ":"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XGETTEXT" >&5
-$as_echo "$XGETTEXT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- rm -f messages.po
-
-
-# Prepare PATH_SEPARATOR.
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-
-# Find out how to test for executable files. Don't use a zero-byte file,
-# as systems may use methods other than mode bits to determine executability.
-cat >conf$$.file <<_ASEOF
-#! /bin/sh
-exit 0
-_ASEOF
-chmod +x conf$$.file
-if test -x conf$$.file >/dev/null 2>&1; then
- ac_executable_p="test -x"
-else
- ac_executable_p="test -f"
-fi
-rm -f conf$$.file
-
-# Extract the first word of "msgmerge", so it can be a program name with args.
-set dummy msgmerge; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_MSGMERGE+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case "$MSGMERGE" in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_MSGMERGE="$MSGMERGE" # Let the user override the test with a path.
- ;;
- *)
- ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH; do
- IFS="$ac_save_IFS"
- test -z "$ac_dir" && ac_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
- if $ac_dir/$ac_word --update -q /dev/null /dev/null >/dev/null 2>&1; then
- ac_cv_path_MSGMERGE="$ac_dir/$ac_word$ac_exec_ext"
- break 2
- fi
- fi
- done
- done
- IFS="$ac_save_IFS"
- test -z "$ac_cv_path_MSGMERGE" && ac_cv_path_MSGMERGE=":"
- ;;
-esac
-fi
-MSGMERGE="$ac_cv_path_MSGMERGE"
-if test "$MSGMERGE" != ":"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGMERGE" >&5
-$as_echo "$MSGMERGE" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- if test "$GMSGFMT" != ":"; then
- if $GMSGFMT --statistics /dev/null >/dev/null 2>&1 &&
- (if $GMSGFMT --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- : ;
- else
- GMSGFMT=`echo "$GMSGFMT" | sed -e 's,^.*/,,'`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: found $GMSGFMT program is not GNU msgfmt; ignore it" >&5
-$as_echo "found $GMSGFMT program is not GNU msgfmt; ignore it" >&6; }
- GMSGFMT=":"
- fi
- fi
-
- if test "$XGETTEXT" != ":"; then
- if $XGETTEXT --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >/dev/null 2>&1 &&
- (if $XGETTEXT --omit-header --copyright-holder= --msgid-bugs-address= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- : ;
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: found xgettext program is not GNU xgettext; ignore it" >&5
-$as_echo "found xgettext program is not GNU xgettext; ignore it" >&6; }
- XGETTEXT=":"
- fi
- rm -f messages.po
- fi
-
- ac_config_commands="$ac_config_commands default-1"
-
-
-
- if test "X$prefix" = "XNONE"; then
- acl_final_prefix="$ac_default_prefix"
- else
- acl_final_prefix="$prefix"
- fi
- if test "X$exec_prefix" = "XNONE"; then
- acl_final_exec_prefix='${prefix}'
- else
- acl_final_exec_prefix="$exec_prefix"
- fi
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- eval acl_final_exec_prefix=\"$acl_final_exec_prefix\"
- prefix="$acl_save_prefix"
-
-
-# Check whether --with-gnu-ld was given.
-if test "${with_gnu_ld+set}" = set; then :
- withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
-else
- with_gnu_ld=no
-fi
-
-# Prepare PATH_SEPARATOR.
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-ac_prog=ld
-if test "$GCC" = yes; then
- # Check if gcc -print-prog-name=ld gives a path.
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by GCC" >&5
-$as_echo_n "checking for ld used by GCC... " >&6; }
- case $host in
- *-*-mingw*)
- # gcc leaves a trailing carriage return which upsets mingw
- ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
- *)
- ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
- esac
- case $ac_prog in
- # Accept absolute paths.
- [\\/]* | [A-Za-z]:[\\/]*)
- re_direlt='/[^/][^/]*/\.\./'
- # Canonicalize the path of ld
- ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
- while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
- ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
- done
- test -z "$LD" && LD="$ac_prog"
- ;;
- "")
- # If it fails, then pretend we aren't using GCC.
- ac_prog=ld
- ;;
- *)
- # If it is relative, then search for the first ld in PATH.
- with_gnu_ld=unknown
- ;;
- esac
-elif test "$with_gnu_ld" = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
-$as_echo_n "checking for GNU ld... " >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
-$as_echo_n "checking for non-GNU ld... " >&6; }
-fi
-if ${acl_cv_path_LD+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -z "$LD"; then
- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
- for ac_dir in $PATH; do
- test -z "$ac_dir" && ac_dir=.
- if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
- acl_cv_path_LD="$ac_dir/$ac_prog"
- # Check to see if the program is GNU ld. I'd rather use --version,
- # but apparently some GNU ld's only accept -v.
- # Break only if it was the GNU/non-GNU ld that we prefer.
- if "$acl_cv_path_LD" -v 2>&1 < /dev/null | $EGREP '(GNU|with BFD)' > /dev/null; then
- test "$with_gnu_ld" != no && break
- else
- test "$with_gnu_ld" != yes && break
- fi
- fi
- done
- IFS="$ac_save_ifs"
-else
- acl_cv_path_LD="$LD" # Let the user override the test with a path.
-fi
-fi
-
-LD="$acl_cv_path_LD"
-if test -n "$LD"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
-$as_echo "$LD" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
-$as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
-if ${acl_cv_prog_gnu_ld+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- # I'd rather use --version here, but apparently some GNU ld's only accept -v.
-if $LD -v 2>&1 </dev/null | $EGREP '(GNU|with BFD)' 1>&5; then
- acl_cv_prog_gnu_ld=yes
-else
- acl_cv_prog_gnu_ld=no
-fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $acl_cv_prog_gnu_ld" >&5
-$as_echo "$acl_cv_prog_gnu_ld" >&6; }
-with_gnu_ld=$acl_cv_prog_gnu_ld
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shared library run path origin" >&5
-$as_echo_n "checking for shared library run path origin... " >&6; }
-if ${acl_cv_rpath+:} false; then :
- $as_echo_n "(cached) " >&6
-else
-
- CC="$CC" GCC="$GCC" LDFLAGS="$LDFLAGS" LD="$LD" with_gnu_ld="$with_gnu_ld" \
- ${CONFIG_SHELL-/bin/sh} "$ac_aux_dir/config.rpath" "$host" > conftest.sh
- . ./conftest.sh
- rm -f ./conftest.sh
- acl_cv_rpath=done
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $acl_cv_rpath" >&5
-$as_echo "$acl_cv_rpath" >&6; }
- wl="$acl_cv_wl"
- libext="$acl_cv_libext"
- shlibext="$acl_cv_shlibext"
- hardcode_libdir_flag_spec="$acl_cv_hardcode_libdir_flag_spec"
- hardcode_libdir_separator="$acl_cv_hardcode_libdir_separator"
- hardcode_direct="$acl_cv_hardcode_direct"
- hardcode_minus_L="$acl_cv_hardcode_minus_L"
- # Check whether --enable-rpath was given.
-if test "${enable_rpath+set}" = set; then :
- enableval=$enable_rpath; :
-else
- enable_rpath=yes
-fi
-
-
-
-
-
-
-
-
- use_additional=yes
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
-
- eval additional_includedir=\"$includedir\"
- eval additional_libdir=\"$libdir\"
-
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
-
-# Check whether --with-libiconv-prefix was given.
-if test "${with_libiconv_prefix+set}" = set; then :
- withval=$with_libiconv_prefix;
- if test "X$withval" = "Xno"; then
- use_additional=no
- else
- if test "X$withval" = "X"; then
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
-
- eval additional_includedir=\"$includedir\"
- eval additional_libdir=\"$libdir\"
-
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- else
- additional_includedir="$withval/include"
- additional_libdir="$withval/lib"
- fi
- fi
-
-fi
-
-
-# Check whether --with-libiconv-type was given.
-if test "${with_libiconv_type+set}" = set; then :
- withval=$with_libiconv_type; with_libiconv_type=$withval
-else
- with_libiconv_type=auto
-fi
-
- lib_type=`eval echo \$with_libiconv_type`
-
- LIBICONV=
- LTLIBICONV=
- INCICONV=
- rpathdirs=
- ltrpathdirs=
- names_already_handled=
- names_next_round='iconv '
- while test -n "$names_next_round"; do
- names_this_round="$names_next_round"
- names_next_round=
- for name in $names_this_round; do
- already_handled=
- for n in $names_already_handled; do
- if test "$n" = "$name"; then
- already_handled=yes
- break
- fi
- done
- if test -z "$already_handled"; then
- names_already_handled="$names_already_handled $name"
- uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
- eval value=\"\$HAVE_LIB$uppername\"
- if test -n "$value"; then
- if test "$value" = yes; then
- eval value=\"\$LIB$uppername\"
- test -z "$value" || LIBICONV="${LIBICONV}${LIBICONV:+ }$value"
- eval value=\"\$LTLIB$uppername\"
- test -z "$value" || LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$value"
- else
- :
- fi
- else
- found_dir=
- found_la=
- found_so=
- found_a=
- if test $use_additional = yes; then
- if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext" && test x$lib_type != xstatic; then
- found_dir="$additional_libdir"
- found_so="$additional_libdir/lib$name.$shlibext"
- if test -f "$additional_libdir/lib$name.la"; then
- found_la="$additional_libdir/lib$name.la"
- fi
- elif test x$lib_type != xshared; then
- if test -f "$additional_libdir/lib$name.$libext"; then
- found_dir="$additional_libdir"
- found_a="$additional_libdir/lib$name.$libext"
- if test -f "$additional_libdir/lib$name.la"; then
- found_la="$additional_libdir/lib$name.la"
- fi
- fi
- fi
- fi
- if test "X$found_dir" = "X"; then
- for x in $LDFLAGS $LTLIBICONV; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- case "$x" in
- -L*)
- dir=`echo "X$x" | sed -e 's/^X-L//'`
- if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext" && test x$lib_type != xstatic; then
- found_dir="$dir"
- found_so="$dir/lib$name.$shlibext"
- if test -f "$dir/lib$name.la"; then
- found_la="$dir/lib$name.la"
- fi
- elif test x$lib_type != xshared; then
- if test -f "$dir/lib$name.$libext"; then
- found_dir="$dir"
- found_a="$dir/lib$name.$libext"
- if test -f "$dir/lib$name.la"; then
- found_la="$dir/lib$name.la"
- fi
- fi
- fi
- ;;
- esac
- if test "X$found_dir" != "X"; then
- break
- fi
- done
- fi
- if test "X$found_dir" != "X"; then
- LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$found_dir -l$name"
- if test "X$found_so" != "X"; then
- if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
- else
- haveit=
- for x in $ltrpathdirs; do
- if test "X$x" = "X$found_dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- ltrpathdirs="$ltrpathdirs $found_dir"
- fi
- if test "$hardcode_direct" = yes; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
- else
- if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
- haveit=
- for x in $rpathdirs; do
- if test "X$x" = "X$found_dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- rpathdirs="$rpathdirs $found_dir"
- fi
- else
- haveit=
- for x in $LDFLAGS $LIBICONV; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-L$found_dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir"
- fi
- if test "$hardcode_minus_L" != no; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
- else
- LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name"
- fi
- fi
- fi
- fi
- else
- if test "X$found_a" != "X"; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }$found_a"
- else
- LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir -l$name"
- fi
- fi
- additional_includedir=
- case "$found_dir" in
- */lib | */lib/)
- basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
- additional_includedir="$basedir/include"
- ;;
- esac
- if test "X$additional_includedir" != "X"; then
- if test "X$additional_includedir" != "X/usr/include"; then
- haveit=
- if test "X$additional_includedir" = "X/usr/local/include"; then
- if test -n "$GCC"; then
- case $host_os in
- linux*) haveit=yes;;
- esac
- fi
- fi
- if test -z "$haveit"; then
- for x in $CPPFLAGS $INCICONV; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-I$additional_includedir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- if test -d "$additional_includedir"; then
- INCICONV="${INCICONV}${INCICONV:+ }-I$additional_includedir"
- fi
- fi
- fi
- fi
- fi
- if test -n "$found_la"; then
- save_libdir="$libdir"
- case "$found_la" in
- */* | *\\*) . "$found_la" ;;
- *) . "./$found_la" ;;
- esac
- libdir="$save_libdir"
- for dep in $dependency_libs; do
- case "$dep" in
- -L*)
- additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
- if test "X$additional_libdir" != "X/usr/lib"; then
- haveit=
- if test "X$additional_libdir" = "X/usr/local/lib"; then
- if test -n "$GCC"; then
- case $host_os in
- linux*) haveit=yes;;
- esac
- fi
- fi
- if test -z "$haveit"; then
- haveit=
- for x in $LDFLAGS $LIBICONV; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-L$additional_libdir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- if test -d "$additional_libdir"; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }-L$additional_libdir"
- fi
- fi
- haveit=
- for x in $LDFLAGS $LTLIBICONV; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-L$additional_libdir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- if test -d "$additional_libdir"; then
- LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$additional_libdir"
- fi
- fi
- fi
- fi
- ;;
- -R*)
- dir=`echo "X$dep" | sed -e 's/^X-R//'`
- if test "$enable_rpath" != no; then
- haveit=
- for x in $rpathdirs; do
- if test "X$x" = "X$dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- rpathdirs="$rpathdirs $dir"
- fi
- haveit=
- for x in $ltrpathdirs; do
- if test "X$x" = "X$dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- ltrpathdirs="$ltrpathdirs $dir"
- fi
- fi
- ;;
- -l*)
- names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
- ;;
- *.la)
- names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
- ;;
- *)
- LIBICONV="${LIBICONV}${LIBICONV:+ }$dep"
- LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$dep"
- ;;
- esac
- done
- fi
- else
- if test "x$lib_type" = "xauto" || test "x$lib_type" = "xshared"; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name"
- LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-l$name"
- else
- LIBICONV="${LIBICONV}${LIBICONV:+ }-l:lib$name.$libext"
- LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-l:lib$name.$libext"
- fi
- fi
- fi
- fi
- done
- done
- if test "X$rpathdirs" != "X"; then
- if test -n "$hardcode_libdir_separator"; then
- alldirs=
- for found_dir in $rpathdirs; do
- alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
- done
- acl_save_libdir="$libdir"
- libdir="$alldirs"
- eval flag=\"$hardcode_libdir_flag_spec\"
- libdir="$acl_save_libdir"
- LIBICONV="${LIBICONV}${LIBICONV:+ }$flag"
- else
- for found_dir in $rpathdirs; do
- acl_save_libdir="$libdir"
- libdir="$found_dir"
- eval flag=\"$hardcode_libdir_flag_spec\"
- libdir="$acl_save_libdir"
- LIBICONV="${LIBICONV}${LIBICONV:+ }$flag"
- done
- fi
- fi
- if test "X$ltrpathdirs" != "X"; then
- for found_dir in $ltrpathdirs; do
- LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-R$found_dir"
- done
- fi
-
-
-
-
-
-if test -f ../gettext/uninstalled-config.sh; then
- relative_builddir='$(top_builddir)/../gettext'
- . ../gettext/uninstalled-config.sh
-else
- # The sister gettext directory doesn't exist and won't collect information on
- # using gettext for us. Call a bundled AM_GNU_GETTEXT.
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CFPreferencesCopyAppValue" >&5
-$as_echo_n "checking for CFPreferencesCopyAppValue... " >&6; }
-if ${gt_cv_func_CFPreferencesCopyAppValue+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- gt_save_LIBS="$LIBS"
- LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <CoreFoundation/CFPreferences.h>
-int
-main ()
-{
-CFPreferencesCopyAppValue(NULL, NULL)
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- gt_cv_func_CFPreferencesCopyAppValue=yes
-else
- gt_cv_func_CFPreferencesCopyAppValue=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LIBS="$gt_save_LIBS"
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_CFPreferencesCopyAppValue" >&5
-$as_echo "$gt_cv_func_CFPreferencesCopyAppValue" >&6; }
- if test $gt_cv_func_CFPreferencesCopyAppValue = yes; then
-
-$as_echo "#define HAVE_CFPREFERENCESCOPYAPPVALUE 1" >>confdefs.h
-
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CFLocaleCopyPreferredLanguages" >&5
-$as_echo_n "checking for CFLocaleCopyPreferredLanguages... " >&6; }
-if ${gt_cv_func_CFLocaleCopyPreferredLanguages+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- gt_save_LIBS="$LIBS"
- LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <CoreFoundation/CFLocale.h>
-int
-main ()
-{
-CFLocaleCopyPreferredLanguages();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- gt_cv_func_CFLocaleCopyPreferredLanguages=yes
-else
- gt_cv_func_CFLocaleCopyPreferredLanguages=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LIBS="$gt_save_LIBS"
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_CFLocaleCopyPreferredLanguages" >&5
-$as_echo "$gt_cv_func_CFLocaleCopyPreferredLanguages" >&6; }
- if test $gt_cv_func_CFLocaleCopyPreferredLanguages = yes; then
-
-$as_echo "#define HAVE_CFLOCALECOPYPREFERREDLANGUAGES 1" >>confdefs.h
-
- fi
- INTL_MACOSX_LIBS=
- if test $gt_cv_func_CFPreferencesCopyAppValue = yes \
- || test $gt_cv_func_CFLocaleCopyPreferredLanguages = yes; then
- INTL_MACOSX_LIBS="-Wl,-framework -Wl,CoreFoundation -Wl,-framework -Wl,CoreServices"
- fi
-
-
-
-
-
-
- LIBINTL=
- LTLIBINTL=
- POSUB=
-
- case " $gt_needs " in
- *" need-formatstring-macros "*) gt_api_version=3 ;;
- *" need-ngettext "*) gt_api_version=2 ;;
- *) gt_api_version=1 ;;
- esac
- gt_func_gnugettext_libc="gt_cv_func_gnugettext${gt_api_version}_libc"
- gt_func_gnugettext_libintl="gt_cv_func_gnugettext${gt_api_version}_libintl"
-
- if test "$USE_NLS" = "yes"; then
- gt_use_preinstalled_gnugettext=no
-
-
- if test $gt_api_version -ge 3; then
- gt_revision_test_code='
-#ifndef __GNU_GETTEXT_SUPPORTED_REVISION
-#define __GNU_GETTEXT_SUPPORTED_REVISION(major) ((major) == 0 ? 0 : -1)
-#endif
-typedef int array [2 * (__GNU_GETTEXT_SUPPORTED_REVISION(0) >= 1) - 1];
-'
- else
- gt_revision_test_code=
- fi
- if test $gt_api_version -ge 2; then
- gt_expression_test_code=' + * ngettext ("", "", 0)'
- else
- gt_expression_test_code=
- fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU gettext in libc" >&5
-$as_echo_n "checking for GNU gettext in libc... " >&6; }
-if eval \${$gt_func_gnugettext_libc+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <libintl.h>
-#ifndef __GNU_GETTEXT_SUPPORTED_REVISION
-extern int _nl_msg_cat_cntr;
-extern int *_nl_domain_bindings;
-#define __GNU_GETTEXT_SYMBOL_EXPRESSION (_nl_msg_cat_cntr + *_nl_domain_bindings)
-#else
-#define __GNU_GETTEXT_SYMBOL_EXPRESSION 0
-#endif
-$gt_revision_test_code
-
-int
-main ()
-{
-
-bindtextdomain ("", "");
-return * gettext ("")$gt_expression_test_code + __GNU_GETTEXT_SYMBOL_EXPRESSION
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- eval "$gt_func_gnugettext_libc=yes"
-else
- eval "$gt_func_gnugettext_libc=no"
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-fi
-eval ac_res=\$$gt_func_gnugettext_libc
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
-
- if { eval "gt_val=\$$gt_func_gnugettext_libc"; test "$gt_val" != "yes"; }; then
-
-
-
-
-
- am_save_CPPFLAGS="$CPPFLAGS"
-
- for element in $INCICONV; do
- haveit=
- for x in $CPPFLAGS; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X$element"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
- fi
- done
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for iconv" >&5
-$as_echo_n "checking for iconv... " >&6; }
-if ${am_cv_func_iconv+:} false; then :
- $as_echo_n "(cached) " >&6
-else
-
- am_cv_func_iconv="no, consider installing GNU libiconv"
- am_cv_lib_iconv=no
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <stdlib.h>
-#include <iconv.h>
-
-int
-main ()
-{
-iconv_t cd = iconv_open("","");
- iconv(cd,NULL,NULL,NULL,NULL);
- iconv_close(cd);
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- am_cv_func_iconv=yes
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- if test "$am_cv_func_iconv" != yes; then
- am_save_LIBS="$LIBS"
- LIBS="$LIBS $LIBICONV"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <stdlib.h>
-#include <iconv.h>
-
-int
-main ()
-{
-iconv_t cd = iconv_open("","");
- iconv(cd,NULL,NULL,NULL,NULL);
- iconv_close(cd);
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- am_cv_lib_iconv=yes
- am_cv_func_iconv=yes
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LIBS="$am_save_LIBS"
- fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv" >&5
-$as_echo "$am_cv_func_iconv" >&6; }
- if test "$am_cv_func_iconv" = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working iconv" >&5
-$as_echo_n "checking for working iconv... " >&6; }
-if ${am_cv_func_iconv_works+:} false; then :
- $as_echo_n "(cached) " >&6
-else
-
- am_save_LIBS="$LIBS"
- if test $am_cv_lib_iconv = yes; then
- LIBS="$LIBS $LIBICONV"
- fi
- am_cv_func_iconv_works=no
- for ac_iconv_const in '' 'const'; do
- if test "$cross_compiling" = yes; then :
- case "$host_os" in
- aix* | hpux*) am_cv_func_iconv_works="guessing no" ;;
- *) am_cv_func_iconv_works="guessing yes" ;;
- esac
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <iconv.h>
-#include <string.h>
-
-#ifndef ICONV_CONST
-# define ICONV_CONST $ac_iconv_const
-#endif
-
-int
-main ()
-{
-int result = 0;
- /* Test against AIX 5.1...7.2 bug: Failures are not distinguishable from
- successful returns. This is even documented in
- <https://www.ibm.com/support/knowledgecenter/ssw_aix_72/i_bostechref/iconv.html> */
- {
- iconv_t cd_utf8_to_88591 = iconv_open ("ISO8859-1", "UTF-8");
- if (cd_utf8_to_88591 != (iconv_t)(-1))
- {
- static ICONV_CONST char input[] = "\342\202\254"; /* EURO SIGN */
- char buf[10];
- ICONV_CONST char *inptr = input;
- size_t inbytesleft = strlen (input);
- char *outptr = buf;
- size_t outbytesleft = sizeof (buf);
- size_t res = iconv (cd_utf8_to_88591,
- &inptr, &inbytesleft,
- &outptr, &outbytesleft);
- if (res == 0)
- result |= 1;
- iconv_close (cd_utf8_to_88591);
- }
- }
- /* Test against Solaris 10 bug: Failures are not distinguishable from
- successful returns. */
- {
- iconv_t cd_ascii_to_88591 = iconv_open ("ISO8859-1", "646");
- if (cd_ascii_to_88591 != (iconv_t)(-1))
- {
- static ICONV_CONST char input[] = "\263";
- char buf[10];
- ICONV_CONST char *inptr = input;
- size_t inbytesleft = strlen (input);
- char *outptr = buf;
- size_t outbytesleft = sizeof (buf);
- size_t res = iconv (cd_ascii_to_88591,
- &inptr, &inbytesleft,
- &outptr, &outbytesleft);
- if (res == 0)
- result |= 2;
- iconv_close (cd_ascii_to_88591);
- }
- }
- /* Test against AIX 6.1..7.1 bug: Buffer overrun. */
- {
- iconv_t cd_88591_to_utf8 = iconv_open ("UTF-8", "ISO-8859-1");
- if (cd_88591_to_utf8 != (iconv_t)(-1))
- {
- static ICONV_CONST char input[] = "\304";
- static char buf[2] = { (char)0xDE, (char)0xAD };
- ICONV_CONST char *inptr = input;
- size_t inbytesleft = 1;
- char *outptr = buf;
- size_t outbytesleft = 1;
- size_t res = iconv (cd_88591_to_utf8,
- &inptr, &inbytesleft,
- &outptr, &outbytesleft);
- if (res != (size_t)(-1) || outptr - buf > 1 || buf[1] != (char)0xAD)
- result |= 4;
- iconv_close (cd_88591_to_utf8);
- }
- }
-#if 0 /* This bug could be worked around by the caller. */
- /* Test against HP-UX 11.11 bug: Positive return value instead of 0. */
- {
- iconv_t cd_88591_to_utf8 = iconv_open ("utf8", "iso88591");
- if (cd_88591_to_utf8 != (iconv_t)(-1))
- {
- static ICONV_CONST char input[] = "\304rger mit b\366sen B\374bchen ohne Augenma\337";
- char buf[50];
- ICONV_CONST char *inptr = input;
- size_t inbytesleft = strlen (input);
- char *outptr = buf;
- size_t outbytesleft = sizeof (buf);
- size_t res = iconv (cd_88591_to_utf8,
- &inptr, &inbytesleft,
- &outptr, &outbytesleft);
- if ((int)res > 0)
- result |= 8;
- iconv_close (cd_88591_to_utf8);
- }
- }
-#endif
- /* Test against HP-UX 11.11 bug: No converter from EUC-JP to UTF-8 is
- provided. */
- {
- /* Try standardized names. */
- iconv_t cd1 = iconv_open ("UTF-8", "EUC-JP");
- /* Try IRIX, OSF/1 names. */
- iconv_t cd2 = iconv_open ("UTF-8", "eucJP");
- /* Try AIX names. */
- iconv_t cd3 = iconv_open ("UTF-8", "IBM-eucJP");
- /* Try HP-UX names. */
- iconv_t cd4 = iconv_open ("utf8", "eucJP");
- if (cd1 == (iconv_t)(-1) && cd2 == (iconv_t)(-1)
- && cd3 == (iconv_t)(-1) && cd4 == (iconv_t)(-1))
- result |= 16;
- if (cd1 != (iconv_t)(-1))
- iconv_close (cd1);
- if (cd2 != (iconv_t)(-1))
- iconv_close (cd2);
- if (cd3 != (iconv_t)(-1))
- iconv_close (cd3);
- if (cd4 != (iconv_t)(-1))
- iconv_close (cd4);
- }
- return result;
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_run "$LINENO"; then :
- am_cv_func_iconv_works=yes
-fi
-rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
- conftest.$ac_objext conftest.beam conftest.$ac_ext
-fi
-
- test "$am_cv_func_iconv_works" = no || break
- done
- LIBS="$am_save_LIBS"
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv_works" >&5
-$as_echo "$am_cv_func_iconv_works" >&6; }
- case "$am_cv_func_iconv_works" in
- *no) am_func_iconv=no am_cv_lib_iconv=no ;;
- *) am_func_iconv=yes ;;
- esac
- else
- am_func_iconv=no am_cv_lib_iconv=no
- fi
- if test "$am_func_iconv" = yes; then
-
-$as_echo "#define HAVE_ICONV 1" >>confdefs.h
-
- fi
- if test "$am_cv_lib_iconv" = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libiconv" >&5
-$as_echo_n "checking how to link with libiconv... " >&6; }
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBICONV" >&5
-$as_echo "$LIBICONV" >&6; }
- else
- CPPFLAGS="$am_save_CPPFLAGS"
- LIBICONV=
- LTLIBICONV=
- fi
-
-
-
-
-
-
- use_additional=yes
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
-
- eval additional_includedir=\"$includedir\"
- eval additional_libdir=\"$libdir\"
-
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
-
-# Check whether --with-libintl-prefix was given.
-if test "${with_libintl_prefix+set}" = set; then :
- withval=$with_libintl_prefix;
- if test "X$withval" = "Xno"; then
- use_additional=no
- else
- if test "X$withval" = "X"; then
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
-
- eval additional_includedir=\"$includedir\"
- eval additional_libdir=\"$libdir\"
-
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- else
- additional_includedir="$withval/include"
- additional_libdir="$withval/lib"
- fi
- fi
-
-fi
-
-
-# Check whether --with-libintl-type was given.
-if test "${with_libintl_type+set}" = set; then :
- withval=$with_libintl_type; with_libintl_type=$withval
-else
- with_libintl_type=auto
-fi
-
- lib_type=`eval echo \$with_libintl_type`
-
- LIBINTL=
- LTLIBINTL=
- INCINTL=
- rpathdirs=
- ltrpathdirs=
- names_already_handled=
- names_next_round='intl '
- while test -n "$names_next_round"; do
- names_this_round="$names_next_round"
- names_next_round=
- for name in $names_this_round; do
- already_handled=
- for n in $names_already_handled; do
- if test "$n" = "$name"; then
- already_handled=yes
- break
- fi
- done
- if test -z "$already_handled"; then
- names_already_handled="$names_already_handled $name"
- uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
- eval value=\"\$HAVE_LIB$uppername\"
- if test -n "$value"; then
- if test "$value" = yes; then
- eval value=\"\$LIB$uppername\"
- test -z "$value" || LIBINTL="${LIBINTL}${LIBINTL:+ }$value"
- eval value=\"\$LTLIB$uppername\"
- test -z "$value" || LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }$value"
- else
- :
- fi
- else
- found_dir=
- found_la=
- found_so=
- found_a=
- if test $use_additional = yes; then
- if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext" && test x$lib_type != xstatic; then
- found_dir="$additional_libdir"
- found_so="$additional_libdir/lib$name.$shlibext"
- if test -f "$additional_libdir/lib$name.la"; then
- found_la="$additional_libdir/lib$name.la"
- fi
- elif test x$lib_type != xshared; then
- if test -f "$additional_libdir/lib$name.$libext"; then
- found_dir="$additional_libdir"
- found_a="$additional_libdir/lib$name.$libext"
- if test -f "$additional_libdir/lib$name.la"; then
- found_la="$additional_libdir/lib$name.la"
- fi
- fi
- fi
- fi
- if test "X$found_dir" = "X"; then
- for x in $LDFLAGS $LTLIBINTL; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- case "$x" in
- -L*)
- dir=`echo "X$x" | sed -e 's/^X-L//'`
- if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext" && test x$lib_type != xstatic; then
- found_dir="$dir"
- found_so="$dir/lib$name.$shlibext"
- if test -f "$dir/lib$name.la"; then
- found_la="$dir/lib$name.la"
- fi
- elif test x$lib_type != xshared; then
- if test -f "$dir/lib$name.$libext"; then
- found_dir="$dir"
- found_a="$dir/lib$name.$libext"
- if test -f "$dir/lib$name.la"; then
- found_la="$dir/lib$name.la"
- fi
- fi
- fi
- ;;
- esac
- if test "X$found_dir" != "X"; then
- break
- fi
- done
- fi
- if test "X$found_dir" != "X"; then
- LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-L$found_dir -l$name"
- if test "X$found_so" != "X"; then
- if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
- else
- haveit=
- for x in $ltrpathdirs; do
- if test "X$x" = "X$found_dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- ltrpathdirs="$ltrpathdirs $found_dir"
- fi
- if test "$hardcode_direct" = yes; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
- else
- if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
- haveit=
- for x in $rpathdirs; do
- if test "X$x" = "X$found_dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- rpathdirs="$rpathdirs $found_dir"
- fi
- else
- haveit=
- for x in $LDFLAGS $LIBINTL; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-L$found_dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }-L$found_dir"
- fi
- if test "$hardcode_minus_L" != no; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
- else
- LIBINTL="${LIBINTL}${LIBINTL:+ }-l$name"
- fi
- fi
- fi
- fi
- else
- if test "X$found_a" != "X"; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }$found_a"
- else
- LIBINTL="${LIBINTL}${LIBINTL:+ }-L$found_dir -l$name"
- fi
- fi
- additional_includedir=
- case "$found_dir" in
- */lib | */lib/)
- basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
- additional_includedir="$basedir/include"
- ;;
- esac
- if test "X$additional_includedir" != "X"; then
- if test "X$additional_includedir" != "X/usr/include"; then
- haveit=
- if test "X$additional_includedir" = "X/usr/local/include"; then
- if test -n "$GCC"; then
- case $host_os in
- linux*) haveit=yes;;
- esac
- fi
- fi
- if test -z "$haveit"; then
- for x in $CPPFLAGS $INCINTL; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-I$additional_includedir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- if test -d "$additional_includedir"; then
- INCINTL="${INCINTL}${INCINTL:+ }-I$additional_includedir"
- fi
- fi
- fi
- fi
- fi
- if test -n "$found_la"; then
- save_libdir="$libdir"
- case "$found_la" in
- */* | *\\*) . "$found_la" ;;
- *) . "./$found_la" ;;
- esac
- libdir="$save_libdir"
- for dep in $dependency_libs; do
- case "$dep" in
- -L*)
- additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
- if test "X$additional_libdir" != "X/usr/lib"; then
- haveit=
- if test "X$additional_libdir" = "X/usr/local/lib"; then
- if test -n "$GCC"; then
- case $host_os in
- linux*) haveit=yes;;
- esac
- fi
- fi
- if test -z "$haveit"; then
- haveit=
- for x in $LDFLAGS $LIBINTL; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-L$additional_libdir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- if test -d "$additional_libdir"; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }-L$additional_libdir"
- fi
- fi
- haveit=
- for x in $LDFLAGS $LTLIBINTL; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-L$additional_libdir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- if test -d "$additional_libdir"; then
- LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-L$additional_libdir"
- fi
- fi
- fi
- fi
- ;;
- -R*)
- dir=`echo "X$dep" | sed -e 's/^X-R//'`
- if test "$enable_rpath" != no; then
- haveit=
- for x in $rpathdirs; do
- if test "X$x" = "X$dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- rpathdirs="$rpathdirs $dir"
- fi
- haveit=
- for x in $ltrpathdirs; do
- if test "X$x" = "X$dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- ltrpathdirs="$ltrpathdirs $dir"
- fi
- fi
- ;;
- -l*)
- names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
- ;;
- *.la)
- names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
- ;;
- *)
- LIBINTL="${LIBINTL}${LIBINTL:+ }$dep"
- LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }$dep"
- ;;
- esac
- done
- fi
- else
- if test "x$lib_type" = "xauto" || test "x$lib_type" = "xshared"; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }-l$name"
- LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-l$name"
- else
- LIBINTL="${LIBINTL}${LIBINTL:+ }-l:lib$name.$libext"
- LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-l:lib$name.$libext"
- fi
- fi
- fi
- fi
- done
- done
- if test "X$rpathdirs" != "X"; then
- if test -n "$hardcode_libdir_separator"; then
- alldirs=
- for found_dir in $rpathdirs; do
- alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
- done
- acl_save_libdir="$libdir"
- libdir="$alldirs"
- eval flag=\"$hardcode_libdir_flag_spec\"
- libdir="$acl_save_libdir"
- LIBINTL="${LIBINTL}${LIBINTL:+ }$flag"
- else
- for found_dir in $rpathdirs; do
- acl_save_libdir="$libdir"
- libdir="$found_dir"
- eval flag=\"$hardcode_libdir_flag_spec\"
- libdir="$acl_save_libdir"
- LIBINTL="${LIBINTL}${LIBINTL:+ }$flag"
- done
- fi
- fi
- if test "X$ltrpathdirs" != "X"; then
- for found_dir in $ltrpathdirs; do
- LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-R$found_dir"
- done
- fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU gettext in libintl" >&5
-$as_echo_n "checking for GNU gettext in libintl... " >&6; }
-if eval \${$gt_func_gnugettext_libintl+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- gt_save_CPPFLAGS="$CPPFLAGS"
- CPPFLAGS="$CPPFLAGS $INCINTL"
- gt_save_LIBS="$LIBS"
- LIBS="$LIBS $LIBINTL"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <libintl.h>
-#ifndef __GNU_GETTEXT_SUPPORTED_REVISION
-extern int _nl_msg_cat_cntr;
-extern
-#ifdef __cplusplus
-"C"
-#endif
-const char *_nl_expand_alias (const char *);
-#define __GNU_GETTEXT_SYMBOL_EXPRESSION (_nl_msg_cat_cntr + *_nl_expand_alias (""))
-#else
-#define __GNU_GETTEXT_SYMBOL_EXPRESSION 0
-#endif
-$gt_revision_test_code
-
-int
-main ()
-{
-
-bindtextdomain ("", "");
-return * gettext ("")$gt_expression_test_code + __GNU_GETTEXT_SYMBOL_EXPRESSION
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- eval "$gt_func_gnugettext_libintl=yes"
-else
- eval "$gt_func_gnugettext_libintl=no"
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" != yes; } && test -n "$LIBICONV"; then
- LIBS="$LIBS $LIBICONV"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <libintl.h>
-#ifndef __GNU_GETTEXT_SUPPORTED_REVISION
-extern int _nl_msg_cat_cntr;
-extern
-#ifdef __cplusplus
-"C"
-#endif
-const char *_nl_expand_alias (const char *);
-#define __GNU_GETTEXT_SYMBOL_EXPRESSION (_nl_msg_cat_cntr + *_nl_expand_alias (""))
-#else
-#define __GNU_GETTEXT_SYMBOL_EXPRESSION 0
-#endif
-$gt_revision_test_code
-
-int
-main ()
-{
-
-bindtextdomain ("", "");
-return * gettext ("")$gt_expression_test_code + __GNU_GETTEXT_SYMBOL_EXPRESSION
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- LIBINTL="$LIBINTL $LIBICONV"
- LTLIBINTL="$LTLIBINTL $LTLIBICONV"
- eval "$gt_func_gnugettext_libintl=yes"
-
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- fi
- CPPFLAGS="$gt_save_CPPFLAGS"
- LIBS="$gt_save_LIBS"
-fi
-eval ac_res=\$$gt_func_gnugettext_libintl
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
- fi
-
- if { eval "gt_val=\$$gt_func_gnugettext_libc"; test "$gt_val" = "yes"; } \
- || { { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; } \
- && test "$PACKAGE" != gettext-runtime \
- && test "$PACKAGE" != gettext-tools; }; then
- gt_use_preinstalled_gnugettext=yes
- else
- LIBINTL=
- LTLIBINTL=
- INCINTL=
- fi
-
-
-
- if test -n "$INTL_MACOSX_LIBS"; then
- if test "$gt_use_preinstalled_gnugettext" = "yes" \
- || test "$nls_cv_use_gnu_gettext" = "yes"; then
- LIBINTL="$LIBINTL $INTL_MACOSX_LIBS"
- LTLIBINTL="$LTLIBINTL $INTL_MACOSX_LIBS"
- fi
- fi
-
- if test "$gt_use_preinstalled_gnugettext" = "yes" \
- || test "$nls_cv_use_gnu_gettext" = "yes"; then
-
-$as_echo "#define ENABLE_NLS 1" >>confdefs.h
-
- else
- USE_NLS=no
- fi
- fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use NLS" >&5
-$as_echo_n "checking whether to use NLS... " >&6; }
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_NLS" >&5
-$as_echo "$USE_NLS" >&6; }
- if test "$USE_NLS" = "yes"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking where the gettext function comes from" >&5
-$as_echo_n "checking where the gettext function comes from... " >&6; }
- if test "$gt_use_preinstalled_gnugettext" = "yes"; then
- if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; }; then
- gt_source="external libintl"
- else
- gt_source="libc"
- fi
- else
- gt_source="included intl directory"
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_source" >&5
-$as_echo "$gt_source" >&6; }
- fi
-
- if test "$USE_NLS" = "yes"; then
-
- if test "$gt_use_preinstalled_gnugettext" = "yes"; then
- if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; }; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libintl" >&5
-$as_echo_n "checking how to link with libintl... " >&6; }
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBINTL" >&5
-$as_echo "$LIBINTL" >&6; }
-
- for element in $INCINTL; do
- haveit=
- for x in $CPPFLAGS; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X$element"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
- fi
- done
-
- fi
-
-
-$as_echo "#define HAVE_GETTEXT 1" >>confdefs.h
-
-
-$as_echo "#define HAVE_DCGETTEXT 1" >>confdefs.h
-
- fi
-
- POSUB=po
- fi
-
-
-
- INTLLIBS="$LIBINTL"
-
-
-
-
-
-
-fi
-
-
-
-
-
-
-
-
-
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NLS is requested" >&5
-$as_echo_n "checking whether NLS is requested... " >&6; }
-if test x"$USE_NLS" != xyes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-
-$as_echo "#define ENABLE_NLS 1" >>confdefs.h
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for catalogs to be installed" >&5
-$as_echo_n "checking for catalogs to be installed... " >&6; }
- # Look for .po and .gmo files in the source directory.
- CATALOGS=
- XLINGUAS=
- for cat in $srcdir/po/*.gmo $srcdir/po/*.po; do
- # If there aren't any .gmo files the shell will give us the
- # literal string "../path/to/srcdir/po/*.gmo" which has to be
- # weeded out.
- case "$cat" in *\**)
- continue;;
- esac
- # The quadruple backslash is collapsed to a double backslash
- # by the backticks, then collapsed again by the double quotes,
- # leaving us with one backslash in the sed expression (right
- # before the dot that mustn't act as a wildcard).
- cat=`echo $cat | sed -e "s!$srcdir/po/!!" -e "s!\\\\.po!.gmo!"`
- lang=`echo $cat | sed -e "s!\\\\.gmo!!"`
- # The user is allowed to set LINGUAS to a list of languages to
- # install catalogs for. If it's empty that means "all of them."
- if test "x$LINGUAS" = x; then
- CATALOGS="$CATALOGS $cat"
- XLINGUAS="$XLINGUAS $lang"
- else
- case "$LINGUAS" in *$lang*)
- CATALOGS="$CATALOGS $cat"
- XLINGUAS="$XLINGUAS $lang"
- ;;
- esac
- fi
- done
- LINGUAS="$XLINGUAS"
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LINGUAS" >&5
-$as_echo "$LINGUAS" >&6; }
-
-
- DATADIRNAME=share
-
- INSTOBJEXT=.mo
-
- GENCAT=gencat
-
- CATOBJEXT=.gmo
-
-fi
-
-
-
-
-# Prepare PATH_SEPARATOR.
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-
-# Find out how to test for executable files. Don't use a zero-byte file,
-# as systems may use methods other than mode bits to determine executability.
-cat >conf$$.file <<_ASEOF
-#! /bin/sh
-exit 0
-_ASEOF
-chmod +x conf$$.file
-if test -x conf$$.file >/dev/null 2>&1; then
- ac_executable_p="test -x"
-else
- ac_executable_p="test -f"
-fi
-rm -f conf$$.file
-
-# Extract the first word of "msgfmt", so it can be a program name with args.
-set dummy msgfmt; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_MSGFMT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case "$MSGFMT" in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
- ;;
- *)
- ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH; do
- IFS="$ac_save_IFS"
- test -z "$ac_dir" && ac_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
- if $ac_dir/$ac_word --statistics /dev/null >/dev/null 2>&1 &&
- (if $ac_dir/$ac_word --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- ac_cv_path_MSGFMT="$ac_dir/$ac_word$ac_exec_ext"
- break 2
- fi
- fi
- done
- done
- IFS="$ac_save_IFS"
- test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT=":"
- ;;
-esac
-fi
-MSGFMT="$ac_cv_path_MSGFMT"
-if test "$MSGFMT" != ":"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGFMT" >&5
-$as_echo "$MSGFMT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- # Extract the first word of "gmsgfmt", so it can be a program name with args.
-set dummy gmsgfmt; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_GMSGFMT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $GMSGFMT in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
- ;;
- *)
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_path_GMSGFMT="$as_dir/$ac_word$ac_exec_ext"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
- test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT"
- ;;
-esac
-fi
-GMSGFMT=$ac_cv_path_GMSGFMT
-if test -n "$GMSGFMT"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GMSGFMT" >&5
-$as_echo "$GMSGFMT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-
-
-# Prepare PATH_SEPARATOR.
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-
-# Find out how to test for executable files. Don't use a zero-byte file,
-# as systems may use methods other than mode bits to determine executability.
-cat >conf$$.file <<_ASEOF
-#! /bin/sh
-exit 0
-_ASEOF
-chmod +x conf$$.file
-if test -x conf$$.file >/dev/null 2>&1; then
- ac_executable_p="test -x"
-else
- ac_executable_p="test -f"
-fi
-rm -f conf$$.file
-
-# Extract the first word of "xgettext", so it can be a program name with args.
-set dummy xgettext; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_XGETTEXT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case "$XGETTEXT" in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
- ;;
- *)
- ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH; do
- IFS="$ac_save_IFS"
- test -z "$ac_dir" && ac_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
- if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >/dev/null 2>&1 &&
- (if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- ac_cv_path_XGETTEXT="$ac_dir/$ac_word$ac_exec_ext"
- break 2
- fi
- fi
- done
- done
- IFS="$ac_save_IFS"
- test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":"
- ;;
-esac
-fi
-XGETTEXT="$ac_cv_path_XGETTEXT"
-if test "$XGETTEXT" != ":"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XGETTEXT" >&5
-$as_echo "$XGETTEXT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- rm -f messages.po
-
-
-# Prepare PATH_SEPARATOR.
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-
-# Find out how to test for executable files. Don't use a zero-byte file,
-# as systems may use methods other than mode bits to determine executability.
-cat >conf$$.file <<_ASEOF
-#! /bin/sh
-exit 0
-_ASEOF
-chmod +x conf$$.file
-if test -x conf$$.file >/dev/null 2>&1; then
- ac_executable_p="test -x"
-else
- ac_executable_p="test -f"
-fi
-rm -f conf$$.file
-
-# Extract the first word of "msgmerge", so it can be a program name with args.
-set dummy msgmerge; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_MSGMERGE+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case "$MSGMERGE" in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_MSGMERGE="$MSGMERGE" # Let the user override the test with a path.
- ;;
- *)
- ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH; do
- IFS="$ac_save_IFS"
- test -z "$ac_dir" && ac_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
- if $ac_dir/$ac_word --update -q /dev/null /dev/null >/dev/null 2>&1; then
- ac_cv_path_MSGMERGE="$ac_dir/$ac_word$ac_exec_ext"
- break 2
- fi
- fi
- done
- done
- IFS="$ac_save_IFS"
- test -z "$ac_cv_path_MSGMERGE" && ac_cv_path_MSGMERGE=":"
- ;;
-esac
-fi
-MSGMERGE="$ac_cv_path_MSGMERGE"
-if test "$MSGMERGE" != ":"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGMERGE" >&5
-$as_echo "$MSGMERGE" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- if test "$GMSGFMT" != ":"; then
- if $GMSGFMT --statistics /dev/null >/dev/null 2>&1 &&
- (if $GMSGFMT --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- : ;
- else
- GMSGFMT=`echo "$GMSGFMT" | sed -e 's,^.*/,,'`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: found $GMSGFMT program is not GNU msgfmt; ignore it" >&5
-$as_echo "found $GMSGFMT program is not GNU msgfmt; ignore it" >&6; }
- GMSGFMT=":"
- fi
- fi
-
- if test "$XGETTEXT" != ":"; then
- if $XGETTEXT --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >/dev/null 2>&1 &&
- (if $XGETTEXT --omit-header --copyright-holder= --msgid-bugs-address= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- : ;
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: found xgettext program is not GNU xgettext; ignore it" >&5
-$as_echo "found xgettext program is not GNU xgettext; ignore it" >&6; }
- XGETTEXT=":"
- fi
- rm -f messages.po
- fi
-
- ac_config_commands="$ac_config_commands default-2"
-
-
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable maintainer-specific portions of Makefiles" >&5
-$as_echo_n "checking whether to enable maintainer-specific portions of Makefiles... " >&6; }
- # Check whether --enable-maintainer-mode was given.
-if test "${enable_maintainer_mode+set}" = set; then :
- enableval=$enable_maintainer_mode; USE_MAINTAINER_MODE=$enableval
-else
- USE_MAINTAINER_MODE=no
-fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_MAINTAINER_MODE" >&5
-$as_echo "$USE_MAINTAINER_MODE" >&6; }
- if test $USE_MAINTAINER_MODE = yes; then
- MAINTAINER_MODE_TRUE=
- MAINTAINER_MODE_FALSE='#'
-else
- MAINTAINER_MODE_TRUE='#'
- MAINTAINER_MODE_FALSE=
-fi
-
- MAINT=$MAINTAINER_MODE_TRUE
-
-
- if false; then
- GENINSRC_NEVER_TRUE=
- GENINSRC_NEVER_FALSE='#'
-else
- GENINSRC_NEVER_TRUE='#'
- GENINSRC_NEVER_FALSE=
-fi
-
-
-
-for ac_header in memory.h sys/stat.h sys/types.h unistd.h
-do :
- as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
-ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
-if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
- cat >>confdefs.h <<_ACEOF
-#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
-_ACEOF
-
-fi
-
-done
-
-
-# Put this here so that autoconf's "cross-compiling" message doesn't confuse
-# people who are not cross-compiling but are compiling cross-assemblers.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether compiling a cross-assembler" >&5
-$as_echo_n "checking whether compiling a cross-assembler... " >&6; }
-if test "${host}" = "${target}"; then
- cross_gas=no
-else
- cross_gas=yes
-
-$as_echo "#define CROSS_COMPILE 1" >>confdefs.h
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_gas" >&5
-$as_echo "$cross_gas" >&6; }
-
-for ac_func in strsignal
-do :
- ac_fn_c_check_func "$LINENO" "strsignal" "ac_cv_func_strsignal"
-if test "x$ac_cv_func_strsignal" = xyes; then :
- cat >>confdefs.h <<_ACEOF
-#define HAVE_STRSIGNAL 1
-_ACEOF
-
-fi
-done
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LC_MESSAGES" >&5
-$as_echo_n "checking for LC_MESSAGES... " >&6; }
-if ${am_cv_val_LC_MESSAGES+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <locale.h>
-int
-main ()
-{
-return LC_MESSAGES
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- am_cv_val_LC_MESSAGES=yes
-else
- am_cv_val_LC_MESSAGES=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_val_LC_MESSAGES" >&5
-$as_echo "$am_cv_val_LC_MESSAGES" >&6; }
- if test $am_cv_val_LC_MESSAGES = yes; then
-
-$as_echo "#define HAVE_LC_MESSAGES 1" >>confdefs.h
-
- fi
-
-
-# do we need the math library?
-case "${need_libm}" in
-yes)
- LIBM=
-case $host in
-*-*-beos* | *-*-cegcc* | *-*-cygwin* | *-*-haiku* | *-*-pw32* | *-*-darwin*)
- # These system don't have libm, or don't need it
- ;;
-*-ncr-sysv4.3*)
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _mwvalidcheckl in -lmw" >&5
-$as_echo_n "checking for _mwvalidcheckl in -lmw... " >&6; }
-if ${ac_cv_lib_mw__mwvalidcheckl+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-lmw $LIBS"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char _mwvalidcheckl ();
-int
-main ()
-{
-return _mwvalidcheckl ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_lib_mw__mwvalidcheckl=yes
-else
- ac_cv_lib_mw__mwvalidcheckl=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_mw__mwvalidcheckl" >&5
-$as_echo "$ac_cv_lib_mw__mwvalidcheckl" >&6; }
-if test "x$ac_cv_lib_mw__mwvalidcheckl" = xyes; then :
- LIBM="-lmw"
-fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cos in -lm" >&5
-$as_echo_n "checking for cos in -lm... " >&6; }
-if ${ac_cv_lib_m_cos+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-lm $LIBS"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char cos ();
-int
-main ()
-{
-return cos ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_lib_m_cos=yes
-else
- ac_cv_lib_m_cos=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_cos" >&5
-$as_echo "$ac_cv_lib_m_cos" >&6; }
-if test "x$ac_cv_lib_m_cos" = xyes; then :
- LIBM="$LIBM -lm"
-fi
-
- ;;
-*)
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cos in -lm" >&5
-$as_echo_n "checking for cos in -lm... " >&6; }
-if ${ac_cv_lib_m_cos+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-lm $LIBS"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char cos ();
-int
-main ()
-{
-return cos ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_lib_m_cos=yes
-else
- ac_cv_lib_m_cos=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_cos" >&5
-$as_echo "$ac_cv_lib_m_cos" >&6; }
-if test "x$ac_cv_lib_m_cos" = xyes; then :
- LIBM="-lm"
-fi
-
- ;;
-esac
-
-
-
- ;;
-esac
-
-# Some non-ANSI preprocessors botch requoting inside strings. That's bad
-# enough, but on some of those systems, the assert macro relies on requoting
-# working properly!
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for working assert macro" >&5
-$as_echo_n "checking for working assert macro... " >&6; }
-if ${gas_cv_assert_ok+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <assert.h>
-#include <string.h>
-#include <stdio.h>
-int
-main ()
-{
-
-/* check for requoting problems */
-static int a, b, c, d;
-static char *s;
-assert (!strcmp(s, "foo bar baz quux"));
-/* check for newline handling */
-assert (a == b
- || c == d);
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- gas_cv_assert_ok=yes
-else
- gas_cv_assert_ok=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gas_cv_assert_ok" >&5
-$as_echo "$gas_cv_assert_ok" >&6; }
-test $gas_cv_assert_ok = yes ||
-$as_echo "#define BROKEN_ASSERT 1" >>confdefs.h
-
-
-
-# On some systems, the system header files may not declare malloc, realloc,
-# and free. There are places where gas needs these functions to have been
-# declared -- such as when taking their addresses.
-gas_test_headers="
-#ifdef HAVE_MEMORY_H
-#include <memory.h>
-#endif
-#include <string.h>
-#include <stdlib.h>
-#ifdef HAVE_UNISTD_H
-#include <unistd.h>
-#endif
-"
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a known getopt prototype in unistd.h" >&5
-$as_echo_n "checking for a known getopt prototype in unistd.h... " >&6; }
-if ${gas_cv_decl_getopt_unistd_h+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <unistd.h>
-int
-main ()
-{
-extern int getopt (int, char *const*, const char *);
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- gas_cv_decl_getopt_unistd_h=yes
-else
- gas_cv_decl_getopt_unistd_h=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gas_cv_decl_getopt_unistd_h" >&5
-$as_echo "$gas_cv_decl_getopt_unistd_h" >&6; }
-if test $gas_cv_decl_getopt_unistd_h = yes; then
-
-$as_echo "#define HAVE_DECL_GETOPT 1" >>confdefs.h
-
-fi
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether declaration is required for environ" >&5
-$as_echo_n "checking whether declaration is required for environ... " >&6; }
-if ${gas_cv_decl_needed_environ+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$gas_test_headers
-int
-main ()
-{
-
-typedef char **f;
-f x;
-x = (f) environ;
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- gas_cv_decl_needed_environ=no
-else
- gas_cv_decl_needed_environ=yes
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gas_cv_decl_needed_environ" >&5
-$as_echo "$gas_cv_decl_needed_environ" >&6; }
-if test $gas_cv_decl_needed_environ = yes; then
-
-$as_echo "#define NEED_DECLARATION_ENVIRON 1" >>confdefs.h
-
-fi
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether declaration is required for ffs" >&5
-$as_echo_n "checking whether declaration is required for ffs... " >&6; }
-if ${gas_cv_decl_needed_ffs+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$gas_test_headers
-int
-main ()
-{
-
-typedef int (*f)(int);
-f x;
-x = (f) ffs;
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- gas_cv_decl_needed_ffs=no
-else
- gas_cv_decl_needed_ffs=yes
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gas_cv_decl_needed_ffs" >&5
-$as_echo "$gas_cv_decl_needed_ffs" >&6; }
-if test $gas_cv_decl_needed_ffs = yes; then
-
-$as_echo "#define NEED_DECLARATION_FFS 1" >>confdefs.h
-
-fi
-
-
-ac_fn_c_check_decl "$LINENO" "asprintf" "ac_cv_have_decl_asprintf" "$ac_includes_default"
-if test "x$ac_cv_have_decl_asprintf" = xyes; then :
- ac_have_decl=1
-else
- ac_have_decl=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define HAVE_DECL_ASPRINTF $ac_have_decl
-_ACEOF
-ac_fn_c_check_decl "$LINENO" "mempcpy" "ac_cv_have_decl_mempcpy" "$ac_includes_default"
-if test "x$ac_cv_have_decl_mempcpy" = xyes; then :
- ac_have_decl=1
-else
- ac_have_decl=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define HAVE_DECL_MEMPCPY $ac_have_decl
-_ACEOF
-ac_fn_c_check_decl "$LINENO" "stpcpy" "ac_cv_have_decl_stpcpy" "$ac_includes_default"
-if test "x$ac_cv_have_decl_stpcpy" = xyes; then :
- ac_have_decl=1
-else
- ac_have_decl=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define HAVE_DECL_STPCPY $ac_have_decl
-_ACEOF
-
-
-
-case "${host}" in
-*-*-msdos* | *-*-go32* | *-*-mingw32* | *-*-cygwin* | *-*-windows*)
-
-$as_echo "#define USE_BINARY_FOPEN 1" >>confdefs.h
- ;;
-esac
-
-# Link in zlib/zstd if we can. This allows us to write compressed debug sections.
-
- # Use the system's zlib library.
- zlibdir="-L\$(top_builddir)/../zlib"
- zlibinc="-I\$(top_srcdir)/../zlib"
-
-# Check whether --with-system-zlib was given.
-if test "${with_system_zlib+set}" = set; then :
- withval=$with_system_zlib; if test x$with_system_zlib = xyes ; then
- zlibdir=
- zlibinc=
- fi
-
-fi
-
-
-
-
-
-
-
-
-
-
-
-if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
-set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_PKG_CONFIG+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $PKG_CONFIG in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
- ;;
- *)
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
- ;;
-esac
-fi
-PKG_CONFIG=$ac_cv_path_PKG_CONFIG
-if test -n "$PKG_CONFIG"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
-$as_echo "$PKG_CONFIG" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_path_PKG_CONFIG"; then
- ac_pt_PKG_CONFIG=$PKG_CONFIG
- # Extract the first word of "pkg-config", so it can be a program name with args.
-set dummy pkg-config; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $ac_pt_PKG_CONFIG in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
- ;;
- *)
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
- ;;
-esac
-fi
-ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
-if test -n "$ac_pt_PKG_CONFIG"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5
-$as_echo "$ac_pt_PKG_CONFIG" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_pt_PKG_CONFIG" = x; then
- PKG_CONFIG=""
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- PKG_CONFIG=$ac_pt_PKG_CONFIG
- fi
-else
- PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
-fi
-
-fi
-if test -n "$PKG_CONFIG"; then
- _pkg_min_version=0.9.0
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5
-$as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; }
- if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- PKG_CONFIG=""
- fi
-fi
-
-
-# Check whether --with-zstd was given.
-if test "${with_zstd+set}" = set; then :
- withval=$with_zstd;
-else
- with_zstd=auto
-fi
-
-
-if test "$with_zstd" != no; then :
-
-pkg_failed=no
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for libzstd >= 1.4.0" >&5
-$as_echo_n "checking for libzstd >= 1.4.0... " >&6; }
-
-if test -n "$ZSTD_CFLAGS"; then
- pkg_cv_ZSTD_CFLAGS="$ZSTD_CFLAGS"
- elif test -n "$PKG_CONFIG"; then
- if test -n "$PKG_CONFIG" && \
- { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libzstd >= 1.4.0\""; } >&5
- ($PKG_CONFIG --exists --print-errors "libzstd >= 1.4.0") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- pkg_cv_ZSTD_CFLAGS=`$PKG_CONFIG --cflags "libzstd >= 1.4.0" 2>/dev/null`
- test "x$?" != "x0" && pkg_failed=yes
-else
- pkg_failed=yes
-fi
- else
- pkg_failed=untried
-fi
-if test -n "$ZSTD_LIBS"; then
- pkg_cv_ZSTD_LIBS="$ZSTD_LIBS"
- elif test -n "$PKG_CONFIG"; then
- if test -n "$PKG_CONFIG" && \
- { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libzstd >= 1.4.0\""; } >&5
- ($PKG_CONFIG --exists --print-errors "libzstd >= 1.4.0") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- pkg_cv_ZSTD_LIBS=`$PKG_CONFIG --libs "libzstd >= 1.4.0" 2>/dev/null`
- test "x$?" != "x0" && pkg_failed=yes
-else
- pkg_failed=yes
-fi
- else
- pkg_failed=untried
-fi
-
-if test $pkg_failed = no; then
- pkg_save_LDFLAGS="$LDFLAGS"
- LDFLAGS="$LDFLAGS $pkg_cv_ZSTD_LIBS"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
-
-else
- pkg_failed=yes
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LDFLAGS=$pkg_save_LDFLAGS
-fi
-
-
-
-if test $pkg_failed = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-
-if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
- _pkg_short_errors_supported=yes
-else
- _pkg_short_errors_supported=no
-fi
- if test $_pkg_short_errors_supported = yes; then
- ZSTD_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libzstd >= 1.4.0" 2>&1`
- else
- ZSTD_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libzstd >= 1.4.0" 2>&1`
- fi
- # Put the nasty error message in config.log where it belongs
- echo "$ZSTD_PKG_ERRORS" >&5
-
-
- if test "$with_zstd" = yes; then
- as_fn_error $? "--with-zstd was given, but pkgconfig/libzstd.pc is not found" "$LINENO" 5
- fi
-
-elif test $pkg_failed = untried; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-
- if test "$with_zstd" = yes; then
- as_fn_error $? "--with-zstd was given, but pkgconfig/libzstd.pc is not found" "$LINENO" 5
- fi
-
-else
- ZSTD_CFLAGS=$pkg_cv_ZSTD_CFLAGS
- ZSTD_LIBS=$pkg_cv_ZSTD_LIBS
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-
-
-$as_echo "#define HAVE_ZSTD 1" >>confdefs.h
-
-
-fi
-
-fi
-
-
-# Support for VMS timestamps via cross compile
-
-if test "$ac_cv_header_time_h" = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct tm.tm_gmtoff in time.h" >&5
-$as_echo_n "checking for struct tm.tm_gmtoff in time.h... " >&6; }
- if ${gas_cv_have_time_type_member_tm_gmtoff+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#define _BSD_SOURCE 1
-#include <time.h>
-int
-main ()
-{
-struct tm avar; void* aref = (void*) &avar.tm_gmtoff
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- gas_cv_have_time_type_member_tm_gmtoff=yes
-else
- gas_cv_have_time_type_member_tm_gmtoff=no
-
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-
- if test $gas_cv_have_time_type_member_tm_gmtoff = yes; then
-
-$as_echo "#define HAVE_TM_GMTOFF 1" >>confdefs.h
-
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gas_cv_have_time_type_member_tm_gmtoff" >&5
-$as_echo "$gas_cv_have_time_type_member_tm_gmtoff" >&6; }
-
-fi
-
-if test "$ac_cv_header_sys_stat_h" = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct stat.st_mtim.tv_sec in sys/stat.h" >&5
-$as_echo_n "checking for struct stat.st_mtim.tv_sec in sys/stat.h... " >&6; }
- if ${gas_cv_have_sys_stat_type_member_st_mtim_tv_sec+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#define _BSD_SOURCE 1
-#include <sys/stat.h>
-int
-main ()
-{
-struct stat avar; void* aref = (void*) &avar.st_mtim.tv_sec
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- gas_cv_have_sys_stat_type_member_st_mtim_tv_sec=yes
-else
- gas_cv_have_sys_stat_type_member_st_mtim_tv_sec=no
-
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-
- if test $gas_cv_have_sys_stat_type_member_st_mtim_tv_sec = yes; then
-
-$as_echo "#define HAVE_ST_MTIM_TV_SEC 1" >>confdefs.h
-
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gas_cv_have_sys_stat_type_member_st_mtim_tv_sec" >&5
-$as_echo "$gas_cv_have_sys_stat_type_member_st_mtim_tv_sec" >&6; }
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct stat.st_mtim.tv_nsec in sys/stat.h" >&5
-$as_echo_n "checking for struct stat.st_mtim.tv_nsec in sys/stat.h... " >&6; }
- if ${gas_cv_have_sys_stat_type_member_st_mtim_tv_nsec+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#define _BSD_SOURCE 1
-#include <sys/stat.h>
-int
-main ()
-{
-struct stat avar; void* aref = (void*) &avar.st_mtim.tv_nsec
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- gas_cv_have_sys_stat_type_member_st_mtim_tv_nsec=yes
-else
- gas_cv_have_sys_stat_type_member_st_mtim_tv_nsec=no
-
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-
- if test $gas_cv_have_sys_stat_type_member_st_mtim_tv_nsec = yes; then
-
-$as_echo "#define HAVE_ST_MTIM_TV_NSEC 1" >>confdefs.h
-
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gas_cv_have_sys_stat_type_member_st_mtim_tv_nsec" >&5
-$as_echo "$gas_cv_have_sys_stat_type_member_st_mtim_tv_nsec" >&6; }
-
-fi
-
-
-
-
-
-
-
-
-
-ac_config_files="$ac_config_files Makefile po/Makefile.in:po/Make-in"
-
-ac_config_commands="$ac_config_commands default"
-
-
-cat >confcache <<\_ACEOF
-# This file is a shell script that caches the results of configure
-# tests run on this system so they can be shared between configure
-# scripts and configure runs, see configure's option --config-cache.
-# It is not useful on other systems. If it contains results you don't
-# want to keep, you may remove or edit it.
-#
-# config.status only pays attention to the cache file if you give it
-# the --recheck option to rerun configure.
-#
-# `ac_cv_env_foo' variables (set or unset) will be overridden when
-# loading this file, other *unset* `ac_cv_foo' will be assigned the
-# following values.
-
-_ACEOF
-
-# The following way of writing the cache mishandles newlines in values,
-# but we know of no workaround that is simple, portable, and efficient.
-# So, we kill variables containing newlines.
-# Ultrix sh set writes to stderr and can't be redirected directly,
-# and sets the high bit in the cache file unless we assign to the vars.
-(
- for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
- eval ac_val=\$$ac_var
- case $ac_val in #(
- *${as_nl}*)
- case $ac_var in #(
- *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
-$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
- esac
- case $ac_var in #(
- _ | IFS | as_nl) ;; #(
- BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
- *) { eval $ac_var=; unset $ac_var;} ;;
- esac ;;
- esac
- done
-
- (set) 2>&1 |
- case $as_nl`(ac_space=' '; set) 2>&1` in #(
- *${as_nl}ac_space=\ *)
- # `set' does not quote correctly, so add quotes: double-quote
- # substitution turns \\\\ into \\, and sed turns \\ into \.
- sed -n \
- "s/'/'\\\\''/g;
- s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
- ;; #(
- *)
- # `set' quotes correctly as required by POSIX, so do not add quotes.
- sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
- ;;
- esac |
- sort
-) |
- sed '
- /^ac_cv_env_/b end
- t clear
- :clear
- s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
- t end
- s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
- :end' >>confcache
-if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
- if test -w "$cache_file"; then
- if test "x$cache_file" != "x/dev/null"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
-$as_echo "$as_me: updating cache $cache_file" >&6;}
- if test ! -f "$cache_file" || test -h "$cache_file"; then
- cat confcache >"$cache_file"
- else
- case $cache_file in #(
- */* | ?:*)
- mv -f confcache "$cache_file"$$ &&
- mv -f "$cache_file"$$ "$cache_file" ;; #(
- *)
- mv -f confcache "$cache_file" ;;
- esac
- fi
- fi
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
-$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
- fi
-fi
-rm -f confcache
-
-test "x$prefix" = xNONE && prefix=$ac_default_prefix
-# Let make expand exec_prefix.
-test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
-
-DEFS=-DHAVE_CONFIG_H
-
-ac_libobjs=
-ac_ltlibobjs=
-U=
-for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
- # 1. Remove the extension, and $U if already installed.
- ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
- ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
- # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
- # will be set to the directory where LIBOBJS objects are built.
- as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
- as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
-done
-LIBOBJS=$ac_libobjs
-
-LTLIBOBJS=$ac_ltlibobjs
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking that generated files are newer than configure" >&5
-$as_echo_n "checking that generated files are newer than configure... " >&6; }
- if test -n "$am_sleep_pid"; then
- # Hide warnings about reused PIDs.
- wait $am_sleep_pid 2>/dev/null
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: done" >&5
-$as_echo "done" >&6; }
- if test -n "$EXEEXT"; then
- am__EXEEXT_TRUE=
- am__EXEEXT_FALSE='#'
-else
- am__EXEEXT_TRUE='#'
- am__EXEEXT_FALSE=
-fi
-
-if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
- as_fn_error $? "conditional \"AMDEP\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
- as_fn_error $? "conditional \"am__fastdepCC\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-
-if test -z "${MAINTAINER_MODE_TRUE}" && test -z "${MAINTAINER_MODE_FALSE}"; then
- as_fn_error $? "conditional \"MAINTAINER_MODE\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${GENINSRC_NEVER_TRUE}" && test -z "${GENINSRC_NEVER_FALSE}"; then
- as_fn_error $? "conditional \"GENINSRC_NEVER\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-
-: "${CONFIG_STATUS=./config.status}"
-ac_write_fail=0
-ac_clean_files_save=$ac_clean_files
-ac_clean_files="$ac_clean_files $CONFIG_STATUS"
-{ $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
-$as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
-as_write_fail=0
-cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
-#! $SHELL
-# Generated by $as_me.
-# Run this file to recreate the current configuration.
-# Compiler output produced by configure, useful for debugging
-# configure, is in config.log if it exists.
-
-debug=false
-ac_cs_recheck=false
-ac_cs_silent=false
-
-SHELL=\${CONFIG_SHELL-$SHELL}
-export SHELL
-_ASEOF
-cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
-## -------------------- ##
-## M4sh Initialization. ##
-## -------------------- ##
-
-# Be more Bourne compatible
-DUALCASE=1; export DUALCASE # for MKS sh
-if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
- emulate sh
- NULLCMD=:
- # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
- # is contrary to our usage. Disable this feature.
- alias -g '${1+"$@"}'='"$@"'
- setopt NO_GLOB_SUBST
-else
- case `(set -o) 2>/dev/null` in #(
- *posix*) :
- set -o posix ;; #(
- *) :
- ;;
-esac
-fi
-
-
-as_nl='
-'
-export as_nl
-# Printing a long string crashes Solaris 7 /usr/bin/printf.
-as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
-as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
-as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
-# Prefer a ksh shell builtin over an external printf program on Solaris,
-# but without wasting forks for bash or zsh.
-if test -z "$BASH_VERSION$ZSH_VERSION" \
- && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
- as_echo='print -r --'
- as_echo_n='print -rn --'
-elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
- as_echo='printf %s\n'
- as_echo_n='printf %s'
-else
- if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
- as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
- as_echo_n='/usr/ucb/echo -n'
- else
- as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
- as_echo_n_body='eval
- arg=$1;
- case $arg in #(
- *"$as_nl"*)
- expr "X$arg" : "X\\(.*\\)$as_nl";
- arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
- esac;
- expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
- '
- export as_echo_n_body
- as_echo_n='sh -c $as_echo_n_body as_echo'
- fi
- export as_echo_body
- as_echo='sh -c $as_echo_body as_echo'
-fi
-
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- PATH_SEPARATOR=:
- (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
- (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
- PATH_SEPARATOR=';'
- }
-fi
-
-
-# IFS
-# We need space, tab and new line, in precisely that order. Quoting is
-# there to prevent editors from complaining about space-tab.
-# (If _AS_PATH_WALK were called with IFS unset, it would disable word
-# splitting by setting IFS to empty value.)
-IFS=" "" $as_nl"
-
-# Find who we are. Look in the path if we contain no directory separator.
-as_myself=
-case $0 in #((
- *[\\/]* ) as_myself=$0 ;;
- *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
- done
-IFS=$as_save_IFS
-
- ;;
-esac
-# We did not find ourselves, most probably we were run as `sh COMMAND'
-# in which case we are not to be found in the path.
-if test "x$as_myself" = x; then
- as_myself=$0
-fi
-if test ! -f "$as_myself"; then
- $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
- exit 1
-fi
-
-# Unset variables that we do not need and which cause bugs (e.g. in
-# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
-# suppresses any "Segmentation fault" message there. '((' could
-# trigger a bug in pdksh 5.2.14.
-for as_var in BASH_ENV ENV MAIL MAILPATH
-do eval test x\${$as_var+set} = xset \
- && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
-done
-PS1='$ '
-PS2='> '
-PS4='+ '
-
-# NLS nuisances.
-LC_ALL=C
-export LC_ALL
-LANGUAGE=C
-export LANGUAGE
-
-# CDPATH.
-(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
-
-
-# as_fn_error STATUS ERROR [LINENO LOG_FD]
-# ----------------------------------------
-# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
-# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
-# script with STATUS, using 1 if that was 0.
-as_fn_error ()
-{
- as_status=$1; test $as_status -eq 0 && as_status=1
- if test "$4"; then
- as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
- fi
- $as_echo "$as_me: error: $2" >&2
- as_fn_exit $as_status
-} # as_fn_error
-
-
-# as_fn_set_status STATUS
-# -----------------------
-# Set $? to STATUS, without forking.
-as_fn_set_status ()
-{
- return $1
-} # as_fn_set_status
-
-# as_fn_exit STATUS
-# -----------------
-# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
-as_fn_exit ()
-{
- set +e
- as_fn_set_status $1
- exit $1
-} # as_fn_exit
-
-# as_fn_unset VAR
-# ---------------
-# Portably unset VAR.
-as_fn_unset ()
-{
- { eval $1=; unset $1;}
-}
-as_unset=as_fn_unset
-# as_fn_append VAR VALUE
-# ----------------------
-# Append the text in VALUE to the end of the definition contained in VAR. Take
-# advantage of any shell optimizations that allow amortized linear growth over
-# repeated appends, instead of the typical quadratic growth present in naive
-# implementations.
-if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
- eval 'as_fn_append ()
- {
- eval $1+=\$2
- }'
-else
- as_fn_append ()
- {
- eval $1=\$$1\$2
- }
-fi # as_fn_append
-
-# as_fn_arith ARG...
-# ------------------
-# Perform arithmetic evaluation on the ARGs, and store the result in the
-# global $as_val. Take advantage of shells that can avoid forks. The arguments
-# must be portable across $(()) and expr.
-if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
- eval 'as_fn_arith ()
- {
- as_val=$(( $* ))
- }'
-else
- as_fn_arith ()
- {
- as_val=`expr "$@" || test $? -eq 1`
- }
-fi # as_fn_arith
-
-
-if expr a : '\(a\)' >/dev/null 2>&1 &&
- test "X`expr 00001 : '.*\(...\)'`" = X001; then
- as_expr=expr
-else
- as_expr=false
-fi
-
-if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
- as_basename=basename
-else
- as_basename=false
-fi
-
-if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
- as_dirname=dirname
-else
- as_dirname=false
-fi
-
-as_me=`$as_basename -- "$0" ||
-$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
- X"$0" : 'X\(//\)$' \| \
- X"$0" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X/"$0" |
- sed '/^.*\/\([^/][^/]*\)\/*$/{
- s//\1/
- q
- }
- /^X\/\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\/\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
-
-# Avoid depending upon Character Ranges.
-as_cr_letters='abcdefghijklmnopqrstuvwxyz'
-as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
-as_cr_Letters=$as_cr_letters$as_cr_LETTERS
-as_cr_digits='0123456789'
-as_cr_alnum=$as_cr_Letters$as_cr_digits
-
-ECHO_C= ECHO_N= ECHO_T=
-case `echo -n x` in #(((((
--n*)
- case `echo 'xy\c'` in
- *c*) ECHO_T=' ';; # ECHO_T is single tab character.
- xy) ECHO_C='\c';;
- *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
- ECHO_T=' ';;
- esac;;
-*)
- ECHO_N='-n';;
-esac
-
-rm -f conf$$ conf$$.exe conf$$.file
-if test -d conf$$.dir; then
- rm -f conf$$.dir/conf$$.file
-else
- rm -f conf$$.dir
- mkdir conf$$.dir 2>/dev/null
-fi
-if (echo >conf$$.file) 2>/dev/null; then
- if ln -s conf$$.file conf$$ 2>/dev/null; then
- as_ln_s='ln -s'
- # ... but there are two gotchas:
- # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
- # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
- # In both cases, we have to default to `cp -pR'.
- ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
- as_ln_s='cp -pR'
- elif ln conf$$.file conf$$ 2>/dev/null; then
- as_ln_s=ln
- else
- as_ln_s='cp -pR'
- fi
-else
- as_ln_s='cp -pR'
-fi
-rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
-rmdir conf$$.dir 2>/dev/null
-
-
-# as_fn_mkdir_p
-# -------------
-# Create "$as_dir" as a directory, including parents if necessary.
-as_fn_mkdir_p ()
-{
-
- case $as_dir in #(
- -*) as_dir=./$as_dir;;
- esac
- test -d "$as_dir" || eval $as_mkdir_p || {
- as_dirs=
- while :; do
- case $as_dir in #(
- *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
- *) as_qdir=$as_dir;;
- esac
- as_dirs="'$as_qdir' $as_dirs"
- as_dir=`$as_dirname -- "$as_dir" ||
-$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$as_dir" : 'X\(//\)[^/]' \| \
- X"$as_dir" : 'X\(//\)$' \| \
- X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$as_dir" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
- test -d "$as_dir" && break
- done
- test -z "$as_dirs" || eval "mkdir $as_dirs"
- } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
-
-
-} # as_fn_mkdir_p
-if mkdir -p . 2>/dev/null; then
- as_mkdir_p='mkdir -p "$as_dir"'
-else
- test -d ./-p && rmdir ./-p
- as_mkdir_p=false
-fi
-
-
-# as_fn_executable_p FILE
-# -----------------------
-# Test if FILE is an executable regular file.
-as_fn_executable_p ()
-{
- test -f "$1" && test -x "$1"
-} # as_fn_executable_p
-as_test_x='test -x'
-as_executable_p=as_fn_executable_p
-
-# Sed expression to map a string onto a valid CPP name.
-as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
-
-# Sed expression to map a string onto a valid variable name.
-as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
-
-
-exec 6>&1
-## ----------------------------------- ##
-## Main body of $CONFIG_STATUS script. ##
-## ----------------------------------- ##
-_ASEOF
-test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
-
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-# Save the log message, to keep $0 and so on meaningful, and to
-# report actual input values of CONFIG_FILES etc. instead of their
-# values after options handling.
-ac_log="
-This file was extended by gas $as_me 2.43.1, which was
-generated by GNU Autoconf 2.69. Invocation command line was
-
- CONFIG_FILES = $CONFIG_FILES
- CONFIG_HEADERS = $CONFIG_HEADERS
- CONFIG_LINKS = $CONFIG_LINKS
- CONFIG_COMMANDS = $CONFIG_COMMANDS
- $ $0 $@
-
-on `(hostname || uname -n) 2>/dev/null | sed 1q`
-"
-
-_ACEOF
-
-case $ac_config_files in *"
-"*) set x $ac_config_files; shift; ac_config_files=$*;;
-esac
-
-case $ac_config_headers in *"
-"*) set x $ac_config_headers; shift; ac_config_headers=$*;;
-esac
-
-
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-# Files that config.status was made for.
-config_files="$ac_config_files"
-config_headers="$ac_config_headers"
-config_commands="$ac_config_commands"
-
-_ACEOF
-
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-ac_cs_usage="\
-\`$as_me' instantiates files and other configuration actions
-from templates according to the current configuration. Unless the files
-and actions are specified as TAGs, all are instantiated by default.
-
-Usage: $0 [OPTION]... [TAG]...
-
- -h, --help print this help, then exit
- -V, --version print version number and configuration settings, then exit
- --config print configuration, then exit
- -q, --quiet, --silent
- do not print progress messages
- -d, --debug don't remove temporary files
- --recheck update $as_me by reconfiguring in the same conditions
- --file=FILE[:TEMPLATE]
- instantiate the configuration file FILE
- --header=FILE[:TEMPLATE]
- instantiate the configuration header FILE
-
-Configuration files:
-$config_files
-
-Configuration headers:
-$config_headers
-
-Configuration commands:
-$config_commands
-
-Report bugs to the package provider."
-
-_ACEOF
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
-ac_cs_version="\\
-gas config.status 2.43.1
-configured by $0, generated by GNU Autoconf 2.69,
- with options \\"\$ac_cs_config\\"
-
-Copyright (C) 2012 Free Software Foundation, Inc.
-This config.status script is free software; the Free Software Foundation
-gives unlimited permission to copy, distribute and modify it."
-
-ac_pwd='$ac_pwd'
-srcdir='$srcdir'
-INSTALL='$INSTALL'
-MKDIR_P='$MKDIR_P'
-AWK='$AWK'
-test -n "\$AWK" || AWK=awk
-_ACEOF
-
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-# The default lists apply if the user does not specify any file.
-ac_need_defaults=:
-while test $# != 0
-do
- case $1 in
- --*=?*)
- ac_option=`expr "X$1" : 'X\([^=]*\)='`
- ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
- ac_shift=:
- ;;
- --*=)
- ac_option=`expr "X$1" : 'X\([^=]*\)='`
- ac_optarg=
- ac_shift=:
- ;;
- *)
- ac_option=$1
- ac_optarg=$2
- ac_shift=shift
- ;;
- esac
-
- case $ac_option in
- # Handling of the options.
- -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
- ac_cs_recheck=: ;;
- --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
- $as_echo "$ac_cs_version"; exit ;;
- --config | --confi | --conf | --con | --co | --c )
- $as_echo "$ac_cs_config"; exit ;;
- --debug | --debu | --deb | --de | --d | -d )
- debug=: ;;
- --file | --fil | --fi | --f )
- $ac_shift
- case $ac_optarg in
- *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
- '') as_fn_error $? "missing file argument" ;;
- esac
- as_fn_append CONFIG_FILES " '$ac_optarg'"
- ac_need_defaults=false;;
- --header | --heade | --head | --hea )
- $ac_shift
- case $ac_optarg in
- *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
- esac
- as_fn_append CONFIG_HEADERS " '$ac_optarg'"
- ac_need_defaults=false;;
- --he | --h)
- # Conflict between --help and --header
- as_fn_error $? "ambiguous option: \`$1'
-Try \`$0 --help' for more information.";;
- --help | --hel | -h )
- $as_echo "$ac_cs_usage"; exit ;;
- -q | -quiet | --quiet | --quie | --qui | --qu | --q \
- | -silent | --silent | --silen | --sile | --sil | --si | --s)
- ac_cs_silent=: ;;
-
- # This is an error.
- -*) as_fn_error $? "unrecognized option: \`$1'
-Try \`$0 --help' for more information." ;;
-
- *) as_fn_append ac_config_targets " $1"
- ac_need_defaults=false ;;
-
- esac
- shift
-done
-
-ac_configure_extra_args=
-
-if $ac_cs_silent; then
- exec 6>/dev/null
- ac_configure_extra_args="$ac_configure_extra_args --silent"
-fi
-
-_ACEOF
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-if \$ac_cs_recheck; then
- set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
- shift
- \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
- CONFIG_SHELL='$SHELL'
- export CONFIG_SHELL
- exec "\$@"
-fi
-
-_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-exec 5>>config.log
-{
- echo
- sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
-## Running $as_me. ##
-_ASBOX
- $as_echo "$ac_log"
-} >&5
-
-_ACEOF
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-#
-# INIT-COMMANDS
-#
-AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"
-
-
-# The HP-UX ksh and POSIX shell print the target directory to stdout
-# if CDPATH is set.
-(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
-
-sed_quote_subst='$sed_quote_subst'
-double_quote_subst='$double_quote_subst'
-delay_variable_subst='$delay_variable_subst'
-macro_version='`$ECHO "$macro_version" | $SED "$delay_single_quote_subst"`'
-macro_revision='`$ECHO "$macro_revision" | $SED "$delay_single_quote_subst"`'
-enable_shared='`$ECHO "$enable_shared" | $SED "$delay_single_quote_subst"`'
-enable_static='`$ECHO "$enable_static" | $SED "$delay_single_quote_subst"`'
-pic_mode='`$ECHO "$pic_mode" | $SED "$delay_single_quote_subst"`'
-enable_fast_install='`$ECHO "$enable_fast_install" | $SED "$delay_single_quote_subst"`'
-SHELL='`$ECHO "$SHELL" | $SED "$delay_single_quote_subst"`'
-ECHO='`$ECHO "$ECHO" | $SED "$delay_single_quote_subst"`'
-host_alias='`$ECHO "$host_alias" | $SED "$delay_single_quote_subst"`'
-host='`$ECHO "$host" | $SED "$delay_single_quote_subst"`'
-host_os='`$ECHO "$host_os" | $SED "$delay_single_quote_subst"`'
-build_alias='`$ECHO "$build_alias" | $SED "$delay_single_quote_subst"`'
-build='`$ECHO "$build" | $SED "$delay_single_quote_subst"`'
-build_os='`$ECHO "$build_os" | $SED "$delay_single_quote_subst"`'
-SED='`$ECHO "$SED" | $SED "$delay_single_quote_subst"`'
-Xsed='`$ECHO "$Xsed" | $SED "$delay_single_quote_subst"`'
-GREP='`$ECHO "$GREP" | $SED "$delay_single_quote_subst"`'
-EGREP='`$ECHO "$EGREP" | $SED "$delay_single_quote_subst"`'
-FGREP='`$ECHO "$FGREP" | $SED "$delay_single_quote_subst"`'
-LD='`$ECHO "$LD" | $SED "$delay_single_quote_subst"`'
-NM='`$ECHO "$NM" | $SED "$delay_single_quote_subst"`'
-LN_S='`$ECHO "$LN_S" | $SED "$delay_single_quote_subst"`'
-max_cmd_len='`$ECHO "$max_cmd_len" | $SED "$delay_single_quote_subst"`'
-ac_objext='`$ECHO "$ac_objext" | $SED "$delay_single_quote_subst"`'
-exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`'
-lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`'
-lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`'
-lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`'
-reload_flag='`$ECHO "$reload_flag" | $SED "$delay_single_quote_subst"`'
-reload_cmds='`$ECHO "$reload_cmds" | $SED "$delay_single_quote_subst"`'
-OBJDUMP='`$ECHO "$OBJDUMP" | $SED "$delay_single_quote_subst"`'
-deplibs_check_method='`$ECHO "$deplibs_check_method" | $SED "$delay_single_quote_subst"`'
-file_magic_cmd='`$ECHO "$file_magic_cmd" | $SED "$delay_single_quote_subst"`'
-AR='`$ECHO "$AR" | $SED "$delay_single_quote_subst"`'
-AR_FLAGS='`$ECHO "$AR_FLAGS" | $SED "$delay_single_quote_subst"`'
-STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`'
-RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`'
-old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`'
-old_postuninstall_cmds='`$ECHO "$old_postuninstall_cmds" | $SED "$delay_single_quote_subst"`'
-old_archive_cmds='`$ECHO "$old_archive_cmds" | $SED "$delay_single_quote_subst"`'
-lock_old_archive_extraction='`$ECHO "$lock_old_archive_extraction" | $SED "$delay_single_quote_subst"`'
-CC='`$ECHO "$CC" | $SED "$delay_single_quote_subst"`'
-CFLAGS='`$ECHO "$CFLAGS" | $SED "$delay_single_quote_subst"`'
-compiler='`$ECHO "$compiler" | $SED "$delay_single_quote_subst"`'
-GCC='`$ECHO "$GCC" | $SED "$delay_single_quote_subst"`'
-lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$delay_single_quote_subst"`'
-lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`'
-lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`'
-lt_cv_sys_global_symbol_to_c_name_address_lib_prefix='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address_lib_prefix" | $SED "$delay_single_quote_subst"`'
-objdir='`$ECHO "$objdir" | $SED "$delay_single_quote_subst"`'
-MAGIC_CMD='`$ECHO "$MAGIC_CMD" | $SED "$delay_single_quote_subst"`'
-lt_prog_compiler_no_builtin_flag='`$ECHO "$lt_prog_compiler_no_builtin_flag" | $SED "$delay_single_quote_subst"`'
-lt_prog_compiler_wl='`$ECHO "$lt_prog_compiler_wl" | $SED "$delay_single_quote_subst"`'
-lt_prog_compiler_pic='`$ECHO "$lt_prog_compiler_pic" | $SED "$delay_single_quote_subst"`'
-lt_prog_compiler_static='`$ECHO "$lt_prog_compiler_static" | $SED "$delay_single_quote_subst"`'
-lt_cv_prog_compiler_c_o='`$ECHO "$lt_cv_prog_compiler_c_o" | $SED "$delay_single_quote_subst"`'
-need_locks='`$ECHO "$need_locks" | $SED "$delay_single_quote_subst"`'
-DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`'
-NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`'
-LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`'
-OTOOL='`$ECHO "$OTOOL" | $SED "$delay_single_quote_subst"`'
-OTOOL64='`$ECHO "$OTOOL64" | $SED "$delay_single_quote_subst"`'
-libext='`$ECHO "$libext" | $SED "$delay_single_quote_subst"`'
-shrext_cmds='`$ECHO "$shrext_cmds" | $SED "$delay_single_quote_subst"`'
-extract_expsyms_cmds='`$ECHO "$extract_expsyms_cmds" | $SED "$delay_single_quote_subst"`'
-archive_cmds_need_lc='`$ECHO "$archive_cmds_need_lc" | $SED "$delay_single_quote_subst"`'
-enable_shared_with_static_runtimes='`$ECHO "$enable_shared_with_static_runtimes" | $SED "$delay_single_quote_subst"`'
-export_dynamic_flag_spec='`$ECHO "$export_dynamic_flag_spec" | $SED "$delay_single_quote_subst"`'
-whole_archive_flag_spec='`$ECHO "$whole_archive_flag_spec" | $SED "$delay_single_quote_subst"`'
-compiler_needs_object='`$ECHO "$compiler_needs_object" | $SED "$delay_single_quote_subst"`'
-old_archive_from_new_cmds='`$ECHO "$old_archive_from_new_cmds" | $SED "$delay_single_quote_subst"`'
-old_archive_from_expsyms_cmds='`$ECHO "$old_archive_from_expsyms_cmds" | $SED "$delay_single_quote_subst"`'
-archive_cmds='`$ECHO "$archive_cmds" | $SED "$delay_single_quote_subst"`'
-archive_expsym_cmds='`$ECHO "$archive_expsym_cmds" | $SED "$delay_single_quote_subst"`'
-module_cmds='`$ECHO "$module_cmds" | $SED "$delay_single_quote_subst"`'
-module_expsym_cmds='`$ECHO "$module_expsym_cmds" | $SED "$delay_single_quote_subst"`'
-with_gnu_ld='`$ECHO "$with_gnu_ld" | $SED "$delay_single_quote_subst"`'
-allow_undefined_flag='`$ECHO "$allow_undefined_flag" | $SED "$delay_single_quote_subst"`'
-no_undefined_flag='`$ECHO "$no_undefined_flag" | $SED "$delay_single_quote_subst"`'
-hardcode_libdir_flag_spec='`$ECHO "$hardcode_libdir_flag_spec" | $SED "$delay_single_quote_subst"`'
-hardcode_libdir_flag_spec_ld='`$ECHO "$hardcode_libdir_flag_spec_ld" | $SED "$delay_single_quote_subst"`'
-hardcode_libdir_separator='`$ECHO "$hardcode_libdir_separator" | $SED "$delay_single_quote_subst"`'
-hardcode_direct='`$ECHO "$hardcode_direct" | $SED "$delay_single_quote_subst"`'
-hardcode_direct_absolute='`$ECHO "$hardcode_direct_absolute" | $SED "$delay_single_quote_subst"`'
-hardcode_minus_L='`$ECHO "$hardcode_minus_L" | $SED "$delay_single_quote_subst"`'
-hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_quote_subst"`'
-hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`'
-inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`'
-link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`'
-fix_srcfile_path='`$ECHO "$fix_srcfile_path" | $SED "$delay_single_quote_subst"`'
-always_export_symbols='`$ECHO "$always_export_symbols" | $SED "$delay_single_quote_subst"`'
-export_symbols_cmds='`$ECHO "$export_symbols_cmds" | $SED "$delay_single_quote_subst"`'
-exclude_expsyms='`$ECHO "$exclude_expsyms" | $SED "$delay_single_quote_subst"`'
-include_expsyms='`$ECHO "$include_expsyms" | $SED "$delay_single_quote_subst"`'
-prelink_cmds='`$ECHO "$prelink_cmds" | $SED "$delay_single_quote_subst"`'
-file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`'
-variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`'
-need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`'
-need_version='`$ECHO "$need_version" | $SED "$delay_single_quote_subst"`'
-version_type='`$ECHO "$version_type" | $SED "$delay_single_quote_subst"`'
-runpath_var='`$ECHO "$runpath_var" | $SED "$delay_single_quote_subst"`'
-shlibpath_var='`$ECHO "$shlibpath_var" | $SED "$delay_single_quote_subst"`'
-shlibpath_overrides_runpath='`$ECHO "$shlibpath_overrides_runpath" | $SED "$delay_single_quote_subst"`'
-libname_spec='`$ECHO "$libname_spec" | $SED "$delay_single_quote_subst"`'
-library_names_spec='`$ECHO "$library_names_spec" | $SED "$delay_single_quote_subst"`'
-soname_spec='`$ECHO "$soname_spec" | $SED "$delay_single_quote_subst"`'
-install_override_mode='`$ECHO "$install_override_mode" | $SED "$delay_single_quote_subst"`'
-postinstall_cmds='`$ECHO "$postinstall_cmds" | $SED "$delay_single_quote_subst"`'
-postuninstall_cmds='`$ECHO "$postuninstall_cmds" | $SED "$delay_single_quote_subst"`'
-finish_cmds='`$ECHO "$finish_cmds" | $SED "$delay_single_quote_subst"`'
-finish_eval='`$ECHO "$finish_eval" | $SED "$delay_single_quote_subst"`'
-hardcode_into_libs='`$ECHO "$hardcode_into_libs" | $SED "$delay_single_quote_subst"`'
-sys_lib_search_path_spec='`$ECHO "$sys_lib_search_path_spec" | $SED "$delay_single_quote_subst"`'
-sys_lib_dlsearch_path_spec='`$ECHO "$sys_lib_dlsearch_path_spec" | $SED "$delay_single_quote_subst"`'
-hardcode_action='`$ECHO "$hardcode_action" | $SED "$delay_single_quote_subst"`'
-enable_dlopen='`$ECHO "$enable_dlopen" | $SED "$delay_single_quote_subst"`'
-enable_dlopen_self='`$ECHO "$enable_dlopen_self" | $SED "$delay_single_quote_subst"`'
-enable_dlopen_self_static='`$ECHO "$enable_dlopen_self_static" | $SED "$delay_single_quote_subst"`'
-old_striplib='`$ECHO "$old_striplib" | $SED "$delay_single_quote_subst"`'
-striplib='`$ECHO "$striplib" | $SED "$delay_single_quote_subst"`'
-
-LTCC='$LTCC'
-LTCFLAGS='$LTCFLAGS'
-compiler='$compiler_DEFAULT'
-
-# A function that is used when there is no print builtin or printf.
-func_fallback_echo ()
-{
- eval 'cat <<_LTECHO_EOF
-\$1
-_LTECHO_EOF'
-}
-
-# Quote evaled strings.
-for var in SHELL \
-ECHO \
-SED \
-GREP \
-EGREP \
-FGREP \
-LD \
-NM \
-LN_S \
-lt_SP2NL \
-lt_NL2SP \
-reload_flag \
-OBJDUMP \
-deplibs_check_method \
-file_magic_cmd \
-AR \
-AR_FLAGS \
-STRIP \
-RANLIB \
-CC \
-CFLAGS \
-compiler \
-lt_cv_sys_global_symbol_pipe \
-lt_cv_sys_global_symbol_to_cdecl \
-lt_cv_sys_global_symbol_to_c_name_address \
-lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \
-lt_prog_compiler_no_builtin_flag \
-lt_prog_compiler_wl \
-lt_prog_compiler_pic \
-lt_prog_compiler_static \
-lt_cv_prog_compiler_c_o \
-need_locks \
-DSYMUTIL \
-NMEDIT \
-LIPO \
-OTOOL \
-OTOOL64 \
-shrext_cmds \
-export_dynamic_flag_spec \
-whole_archive_flag_spec \
-compiler_needs_object \
-with_gnu_ld \
-allow_undefined_flag \
-no_undefined_flag \
-hardcode_libdir_flag_spec \
-hardcode_libdir_flag_spec_ld \
-hardcode_libdir_separator \
-fix_srcfile_path \
-exclude_expsyms \
-include_expsyms \
-file_list_spec \
-variables_saved_for_relink \
-libname_spec \
-library_names_spec \
-soname_spec \
-install_override_mode \
-finish_eval \
-old_striplib \
-striplib; do
- case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
- *[\\\\\\\`\\"\\\$]*)
- eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\""
- ;;
- *)
- eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
- ;;
- esac
-done
-
-# Double-quote double-evaled strings.
-for var in reload_cmds \
-old_postinstall_cmds \
-old_postuninstall_cmds \
-old_archive_cmds \
-extract_expsyms_cmds \
-old_archive_from_new_cmds \
-old_archive_from_expsyms_cmds \
-archive_cmds \
-archive_expsym_cmds \
-module_cmds \
-module_expsym_cmds \
-export_symbols_cmds \
-prelink_cmds \
-postinstall_cmds \
-postuninstall_cmds \
-finish_cmds \
-sys_lib_search_path_spec \
-sys_lib_dlsearch_path_spec; do
- case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
- *[\\\\\\\`\\"\\\$]*)
- eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\""
- ;;
- *)
- eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
- ;;
- esac
-done
-
-ac_aux_dir='$ac_aux_dir'
-xsi_shell='$xsi_shell'
-lt_shell_append='$lt_shell_append'
-
-# See if we are running on zsh, and set the options which allow our
-# commands through without removal of \ escapes INIT.
-if test -n "\${ZSH_VERSION+set}" ; then
- setopt NO_GLOB_SUBST
-fi
-
-
- PACKAGE='$PACKAGE'
- VERSION='$VERSION'
- TIMESTAMP='$TIMESTAMP'
- RM='$RM'
- ofile='$ofile'
-
-
-
-# Capture the value of obsolete ALL_LINGUAS because we need it to compute
- # POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES, CATALOGS. But hide it
- # from automake.
- eval 'OBSOLETE_ALL_LINGUAS''="$ALL_LINGUAS"'
- # Capture the value of LINGUAS because we need it to compute CATALOGS.
- LINGUAS="${LINGUAS-%UNSET%}"
-
-# Capture the value of obsolete ALL_LINGUAS because we need it to compute
- # POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES, CATALOGS. But hide it
- # from automake.
- eval 'OBSOLETE_ALL_LINGUAS''="$ALL_LINGUAS"'
- # Capture the value of LINGUAS because we need it to compute CATALOGS.
- LINGUAS="${LINGUAS-%UNSET%}"
-
-target_cpu_type=${target_cpu_type}
- cgen_cpu_prefix=${cgen_cpu_prefix}
- obj_format=${obj_format}
- te_file=${te_file}
-
-_ACEOF
-
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-
-# Handling of arguments.
-for ac_config_target in $ac_config_targets
-do
- case $ac_config_target in
- "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
- "libtool") CONFIG_COMMANDS="$CONFIG_COMMANDS libtool" ;;
- "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h:config.in" ;;
- "gdb.ini") CONFIG_FILES="$CONFIG_FILES gdb.ini:gdbinit.in" ;;
- ".gdbinit") CONFIG_FILES="$CONFIG_FILES .gdbinit:gdbinit.in" ;;
- "default-1") CONFIG_COMMANDS="$CONFIG_COMMANDS default-1" ;;
- "default-2") CONFIG_COMMANDS="$CONFIG_COMMANDS default-2" ;;
- "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
- "po/Makefile.in") CONFIG_FILES="$CONFIG_FILES po/Makefile.in:po/Make-in" ;;
- "default") CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
-
- *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
- esac
-done
-
-
-# If the user did not use the arguments to specify the items to instantiate,
-# then the envvar interface is used. Set only those that are not.
-# We use the long form for the default assignment because of an extremely
-# bizarre bug on SunOS 4.1.3.
-if $ac_need_defaults; then
- test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
- test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
- test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
-fi
-
-# Have a temporary directory for convenience. Make it in the build tree
-# simply because there is no reason against having it here, and in addition,
-# creating and moving files from /tmp can sometimes cause problems.
-# Hook for its removal unless debugging.
-# Note that there is a small window in which the directory will not be cleaned:
-# after its creation but before its name has been assigned to `$tmp'.
-$debug ||
-{
- tmp= ac_tmp=
- trap 'exit_status=$?
- : "${ac_tmp:=$tmp}"
- { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
-' 0
- trap 'as_fn_exit 1' 1 2 13 15
-}
-# Create a (secure) tmp directory for tmp files.
-
-{
- tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
- test -d "$tmp"
-} ||
-{
- tmp=./conf$$-$RANDOM
- (umask 077 && mkdir "$tmp")
-} || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
-ac_tmp=$tmp
-
-# Set up the scripts for CONFIG_FILES section.
-# No need to generate them if there are no CONFIG_FILES.
-# This happens for instance with `./config.status config.h'.
-if test -n "$CONFIG_FILES"; then
-
-
-ac_cr=`echo X | tr X '\015'`
-# On cygwin, bash can eat \r inside `` if the user requested igncr.
-# But we know of no other shell where ac_cr would be empty at this
-# point, so we can use a bashism as a fallback.
-if test "x$ac_cr" = x; then
- eval ac_cr=\$\'\\r\'
-fi
-ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
-if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
- ac_cs_awk_cr='\\r'
-else
- ac_cs_awk_cr=$ac_cr
-fi
-
-echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
-_ACEOF
-
-
-{
- echo "cat >conf$$subs.awk <<_ACEOF" &&
- echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
- echo "_ACEOF"
-} >conf$$subs.sh ||
- as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
-ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
-ac_delim='%!_!# '
-for ac_last_try in false false false false false :; do
- . ./conf$$subs.sh ||
- as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
-
- ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
- if test $ac_delim_n = $ac_delim_num; then
- break
- elif $ac_last_try; then
- as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
- else
- ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
- fi
-done
-rm -f conf$$subs.sh
-
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
-_ACEOF
-sed -n '
-h
-s/^/S["/; s/!.*/"]=/
-p
-g
-s/^[^!]*!//
-:repl
-t repl
-s/'"$ac_delim"'$//
-t delim
-:nl
-h
-s/\(.\{148\}\)..*/\1/
-t more1
-s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
-p
-n
-b repl
-:more1
-s/["\\]/\\&/g; s/^/"/; s/$/"\\/
-p
-g
-s/.\{148\}//
-t nl
-:delim
-h
-s/\(.\{148\}\)..*/\1/
-t more2
-s/["\\]/\\&/g; s/^/"/; s/$/"/
-p
-b
-:more2
-s/["\\]/\\&/g; s/^/"/; s/$/"\\/
-p
-g
-s/.\{148\}//
-t delim
-' <conf$$subs.awk | sed '
-/^[^""]/{
- N
- s/\n//
-}
-' >>$CONFIG_STATUS || ac_write_fail=1
-rm -f conf$$subs.awk
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-_ACAWK
-cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
- for (key in S) S_is_set[key] = 1
- FS = ""
-
-}
-{
- line = $ 0
- nfields = split(line, field, "@")
- substed = 0
- len = length(field[1])
- for (i = 2; i < nfields; i++) {
- key = field[i]
- keylen = length(key)
- if (S_is_set[key]) {
- value = S[key]
- line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
- len += length(value) + length(field[++i])
- substed = 1
- } else
- len += 1 + keylen
- }
-
- print line
-}
-
-_ACAWK
-_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
- sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
-else
- cat
-fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
- || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
-_ACEOF
-
-# VPATH may cause trouble with some makes, so we remove sole $(srcdir),
-# ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
-# trailing colons and then remove the whole line if VPATH becomes empty
-# (actually we leave an empty line to preserve line numbers).
-if test "x$srcdir" = x.; then
- ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{
-h
-s///
-s/^/:/
-s/[ ]*$/:/
-s/:\$(srcdir):/:/g
-s/:\${srcdir}:/:/g
-s/:@srcdir@:/:/g
-s/^:*//
-s/:*$//
-x
-s/\(=[ ]*\).*/\1/
-G
-s/\n//
-s/^[^=]*=[ ]*$//
-}'
-fi
-
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-fi # test -n "$CONFIG_FILES"
-
-# Set up the scripts for CONFIG_HEADERS section.
-# No need to generate them if there are no CONFIG_HEADERS.
-# This happens for instance with `./config.status Makefile'.
-if test -n "$CONFIG_HEADERS"; then
-cat >"$ac_tmp/defines.awk" <<\_ACAWK ||
-BEGIN {
-_ACEOF
-
-# Transform confdefs.h into an awk script `defines.awk', embedded as
-# here-document in config.status, that substitutes the proper values into
-# config.h.in to produce config.h.
-
-# Create a delimiter string that does not exist in confdefs.h, to ease
-# handling of long lines.
-ac_delim='%!_!# '
-for ac_last_try in false false :; do
- ac_tt=`sed -n "/$ac_delim/p" confdefs.h`
- if test -z "$ac_tt"; then
- break
- elif $ac_last_try; then
- as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
- else
- ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
- fi
-done
-
-# For the awk script, D is an array of macro values keyed by name,
-# likewise P contains macro parameters if any. Preserve backslash
-# newline sequences.
-
-ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
-sed -n '
-s/.\{148\}/&'"$ac_delim"'/g
-t rset
-:rset
-s/^[ ]*#[ ]*define[ ][ ]*/ /
-t def
-d
-:def
-s/\\$//
-t bsnl
-s/["\\]/\\&/g
-s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
-D["\1"]=" \3"/p
-s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
-d
-:bsnl
-s/["\\]/\\&/g
-s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
-D["\1"]=" \3\\\\\\n"\\/p
-t cont
-s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
-t cont
-d
-:cont
-n
-s/.\{148\}/&'"$ac_delim"'/g
-t clear
-:clear
-s/\\$//
-t bsnlc
-s/["\\]/\\&/g; s/^/"/; s/$/"/p
-d
-:bsnlc
-s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
-b cont
-' <confdefs.h | sed '
-s/'"$ac_delim"'/"\\\
-"/g' >>$CONFIG_STATUS || ac_write_fail=1
-
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
- for (key in D) D_is_set[key] = 1
- FS = ""
-}
-/^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
- line = \$ 0
- split(line, arg, " ")
- if (arg[1] == "#") {
- defundef = arg[2]
- mac1 = arg[3]
- } else {
- defundef = substr(arg[1], 2)
- mac1 = arg[2]
- }
- split(mac1, mac2, "(") #)
- macro = mac2[1]
- prefix = substr(line, 1, index(line, defundef) - 1)
- if (D_is_set[macro]) {
- # Preserve the white space surrounding the "#".
- print prefix "define", macro P[macro] D[macro]
- next
- } else {
- # Replace #undef with comments. This is necessary, for example,
- # in the case of _POSIX_SOURCE, which is predefined and required
- # on some systems where configure will not decide to define it.
- if (defundef == "undef") {
- print "/*", prefix defundef, macro, "*/"
- next
- }
- }
-}
-{ print }
-_ACAWK
-_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
- as_fn_error $? "could not setup config headers machinery" "$LINENO" 5
-fi # test -n "$CONFIG_HEADERS"
-
-
-eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS"
-shift
-for ac_tag
-do
- case $ac_tag in
- :[FHLC]) ac_mode=$ac_tag; continue;;
- esac
- case $ac_mode$ac_tag in
- :[FHL]*:*);;
- :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
- :[FH]-) ac_tag=-:-;;
- :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
- esac
- ac_save_IFS=$IFS
- IFS=:
- set x $ac_tag
- IFS=$ac_save_IFS
- shift
- ac_file=$1
- shift
-
- case $ac_mode in
- :L) ac_source=$1;;
- :[FH])
- ac_file_inputs=
- for ac_f
- do
- case $ac_f in
- -) ac_f="$ac_tmp/stdin";;
- *) # Look for the file first in the build tree, then in the source tree
- # (if the path is not absolute). The absolute path cannot be DOS-style,
- # because $ac_f cannot contain `:'.
- test -f "$ac_f" ||
- case $ac_f in
- [\\/$]*) false;;
- *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
- esac ||
- as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
- esac
- case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
- as_fn_append ac_file_inputs " '$ac_f'"
- done
-
- # Let's still pretend it is `configure' which instantiates (i.e., don't
- # use $as_me), people would be surprised to read:
- # /* config.h. Generated by config.status. */
- configure_input='Generated from '`
- $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
- `' by configure.'
- if test x"$ac_file" != x-; then
- configure_input="$ac_file. $configure_input"
- { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
-$as_echo "$as_me: creating $ac_file" >&6;}
- fi
- # Neutralize special characters interpreted by sed in replacement strings.
- case $configure_input in #(
- *\&* | *\|* | *\\* )
- ac_sed_conf_input=`$as_echo "$configure_input" |
- sed 's/[\\\\&|]/\\\\&/g'`;; #(
- *) ac_sed_conf_input=$configure_input;;
- esac
-
- case $ac_tag in
- *:-:* | *:-) cat >"$ac_tmp/stdin" \
- || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
- esac
- ;;
- esac
-
- ac_dir=`$as_dirname -- "$ac_file" ||
-$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$ac_file" : 'X\(//\)[^/]' \| \
- X"$ac_file" : 'X\(//\)$' \| \
- X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$ac_file" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
- as_dir="$ac_dir"; as_fn_mkdir_p
- ac_builddir=.
-
-case "$ac_dir" in
-.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
-*)
- ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
- # A ".." for each directory in $ac_dir_suffix.
- ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
- case $ac_top_builddir_sub in
- "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
- *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
- esac ;;
-esac
-ac_abs_top_builddir=$ac_pwd
-ac_abs_builddir=$ac_pwd$ac_dir_suffix
-# for backward compatibility:
-ac_top_builddir=$ac_top_build_prefix
-
-case $srcdir in
- .) # We are building in place.
- ac_srcdir=.
- ac_top_srcdir=$ac_top_builddir_sub
- ac_abs_top_srcdir=$ac_pwd ;;
- [\\/]* | ?:[\\/]* ) # Absolute name.
- ac_srcdir=$srcdir$ac_dir_suffix;
- ac_top_srcdir=$srcdir
- ac_abs_top_srcdir=$srcdir ;;
- *) # Relative name.
- ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
- ac_top_srcdir=$ac_top_build_prefix$srcdir
- ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
-esac
-ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
-
-
- case $ac_mode in
- :F)
- #
- # CONFIG_FILE
- #
-
- case $INSTALL in
- [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
- *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
- esac
- ac_MKDIR_P=$MKDIR_P
- case $MKDIR_P in
- [\\/$]* | ?:[\\/]* ) ;;
- */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
- esac
-_ACEOF
-
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-# If the template does not know about datarootdir, expand it.
-# FIXME: This hack should be removed a few years after 2.60.
-ac_datarootdir_hack=; ac_datarootdir_seen=
-ac_sed_dataroot='
-/datarootdir/ {
- p
- q
-}
-/@datadir@/p
-/@docdir@/p
-/@infodir@/p
-/@localedir@/p
-/@mandir@/p'
-case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
-*datarootdir*) ac_datarootdir_seen=yes;;
-*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
-$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
-_ACEOF
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
- ac_datarootdir_hack='
- s&@datadir@&$datadir&g
- s&@docdir@&$docdir&g
- s&@infodir@&$infodir&g
- s&@localedir@&$localedir&g
- s&@mandir@&$mandir&g
- s&\\\${datarootdir}&$datarootdir&g' ;;
-esac
-_ACEOF
-
-# Neutralize VPATH when `$srcdir' = `.'.
-# Shell code in configure.ac might set extrasub.
-# FIXME: do we really want to maintain this feature?
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-ac_sed_extra="$ac_vpsub
-$extrasub
-_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-:t
-/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
-s|@configure_input@|$ac_sed_conf_input|;t t
-s&@top_builddir@&$ac_top_builddir_sub&;t t
-s&@top_build_prefix@&$ac_top_build_prefix&;t t
-s&@srcdir@&$ac_srcdir&;t t
-s&@abs_srcdir@&$ac_abs_srcdir&;t t
-s&@top_srcdir@&$ac_top_srcdir&;t t
-s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
-s&@builddir@&$ac_builddir&;t t
-s&@abs_builddir@&$ac_abs_builddir&;t t
-s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
-s&@INSTALL@&$ac_INSTALL&;t t
-s&@MKDIR_P@&$ac_MKDIR_P&;t t
-$ac_datarootdir_hack
-"
-eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \
- >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
-
-test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
- { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
- { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \
- "$ac_tmp/out"`; test -z "$ac_out"; } &&
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
-which seems to be undefined. Please make sure it is defined" >&5
-$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
-which seems to be undefined. Please make sure it is defined" >&2;}
-
- rm -f "$ac_tmp/stdin"
- case $ac_file in
- -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
- *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
- esac \
- || as_fn_error $? "could not create $ac_file" "$LINENO" 5
- ;;
- :H)
- #
- # CONFIG_HEADER
- #
- if test x"$ac_file" != x-; then
- {
- $as_echo "/* $configure_input */" \
- && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs"
- } >"$ac_tmp/config.h" \
- || as_fn_error $? "could not create $ac_file" "$LINENO" 5
- if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
-$as_echo "$as_me: $ac_file is unchanged" >&6;}
- else
- rm -f "$ac_file"
- mv "$ac_tmp/config.h" "$ac_file" \
- || as_fn_error $? "could not create $ac_file" "$LINENO" 5
- fi
- else
- $as_echo "/* $configure_input */" \
- && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \
- || as_fn_error $? "could not create -" "$LINENO" 5
- fi
-# Compute "$ac_file"'s index in $config_headers.
-_am_arg="$ac_file"
-_am_stamp_count=1
-for _am_header in $config_headers :; do
- case $_am_header in
- $_am_arg | $_am_arg:* )
- break ;;
- * )
- _am_stamp_count=`expr $_am_stamp_count + 1` ;;
- esac
-done
-echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" ||
-$as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$_am_arg" : 'X\(//\)[^/]' \| \
- X"$_am_arg" : 'X\(//\)$' \| \
- X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$_am_arg" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`/stamp-h$_am_stamp_count
- ;;
-
- :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
-$as_echo "$as_me: executing $ac_file commands" >&6;}
- ;;
- esac
-
-
- case $ac_file$ac_mode in
- "depfiles":C) test x"$AMDEP_TRUE" != x"" || {
- # Older Autoconf quotes --file arguments for eval, but not when files
- # are listed without --file. Let's play safe and only enable the eval
- # if we detect the quoting.
- case $CONFIG_FILES in
- *\'*) eval set x "$CONFIG_FILES" ;;
- *) set x $CONFIG_FILES ;;
- esac
- shift
- for mf
- do
- # Strip MF so we end up with the name of the file.
- mf=`echo "$mf" | sed -e 's/:.*$//'`
- # Check whether this is an Automake generated Makefile or not.
- # We used to match only the files named 'Makefile.in', but
- # some people rename them; so instead we look at the file content.
- # Grep'ing the first line is not enough: some people post-process
- # each Makefile.in and add a new line on top of each file to say so.
- # Grep'ing the whole file is not good either: AIX grep has a line
- # limit of 2048, but all sed's we know have understand at least 4000.
- if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
- dirpart=`$as_dirname -- "$mf" ||
-$as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$mf" : 'X\(//\)[^/]' \| \
- X"$mf" : 'X\(//\)$' \| \
- X"$mf" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$mf" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
- else
- continue
- fi
- # Extract the definition of DEPDIR, am__include, and am__quote
- # from the Makefile without running 'make'.
- DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
- test -z "$DEPDIR" && continue
- am__include=`sed -n 's/^am__include = //p' < "$mf"`
- test -z "$am__include" && continue
- am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
- # Find all dependency output files, they are included files with
- # $(DEPDIR) in their names. We invoke sed twice because it is the
- # simplest approach to changing $(DEPDIR) to its actual value in the
- # expansion.
- for file in `sed -n "
- s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
- sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g'`; do
- # Make sure the directory exists.
- test -f "$dirpart/$file" && continue
- fdir=`$as_dirname -- "$file" ||
-$as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$file" : 'X\(//\)[^/]' \| \
- X"$file" : 'X\(//\)$' \| \
- X"$file" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$file" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
- as_dir=$dirpart/$fdir; as_fn_mkdir_p
- # echo "creating $dirpart/$file"
- echo '# dummy' > "$dirpart/$file"
- done
- done
-}
- ;;
- "libtool":C)
-
- # See if we are running on zsh, and set the options which allow our
- # commands through without removal of \ escapes.
- if test -n "${ZSH_VERSION+set}" ; then
- setopt NO_GLOB_SUBST
- fi
-
- cfgfile="${ofile}T"
- trap "$RM \"$cfgfile\"; exit 1" 1 2 15
- $RM "$cfgfile"
-
- cat <<_LT_EOF >> "$cfgfile"
-#! $SHELL
-
-# `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
-# Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION
-# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
-# NOTE: Changes made to this file will be lost: look at ltmain.sh.
-#
-# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
-# 2006, 2007, 2008, 2009 Free Software Foundation, Inc.
-# Written by Gordon Matzigkeit, 1996
-#
-# This file is part of GNU Libtool.
-#
-# GNU Libtool is free software; you can redistribute it and/or
-# modify it under the terms of the GNU General Public License as
-# published by the Free Software Foundation; either version 2 of
-# the License, or (at your option) any later version.
-#
-# As a special exception to the GNU General Public License,
-# if you distribute this file as part of a program or library that
-# is built using GNU Libtool, you may include this file under the
-# same distribution terms that you use for the rest of that program.
-#
-# GNU Libtool is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with GNU Libtool; see the file COPYING. If not, a copy
-# can be downloaded from http://www.gnu.org/licenses/gpl.html, or
-# obtained by writing to the Free Software Foundation, Inc.,
-# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
-
-
-# The names of the tagged configurations supported by this script.
-available_tags=""
-
-# ### BEGIN LIBTOOL CONFIG
-
-# Which release of libtool.m4 was used?
-macro_version=$macro_version
-macro_revision=$macro_revision
-
-# Whether or not to build shared libraries.
-build_libtool_libs=$enable_shared
-
-# Whether or not to build static libraries.
-build_old_libs=$enable_static
-
-# What type of objects to build.
-pic_mode=$pic_mode
-
-# Whether or not to optimize for fast installation.
-fast_install=$enable_fast_install
-
-# Shell to use when invoking shell scripts.
-SHELL=$lt_SHELL
-
-# An echo program that protects backslashes.
-ECHO=$lt_ECHO
-
-# The host system.
-host_alias=$host_alias
-host=$host
-host_os=$host_os
-
-# The build system.
-build_alias=$build_alias
-build=$build
-build_os=$build_os
-
-# A sed program that does not truncate output.
-SED=$lt_SED
-
-# Sed that helps us avoid accidentally triggering echo(1) options like -n.
-Xsed="\$SED -e 1s/^X//"
-
-# A grep program that handles long lines.
-GREP=$lt_GREP
-
-# An ERE matcher.
-EGREP=$lt_EGREP
-
-# A literal string matcher.
-FGREP=$lt_FGREP
-
-# A BSD- or MS-compatible name lister.
-NM=$lt_NM
-
-# Whether we need soft or hard links.
-LN_S=$lt_LN_S
-
-# What is the maximum length of a command?
-max_cmd_len=$max_cmd_len
-
-# Object file suffix (normally "o").
-objext=$ac_objext
-
-# Executable file suffix (normally "").
-exeext=$exeext
-
-# whether the shell understands "unset".
-lt_unset=$lt_unset
-
-# turn spaces into newlines.
-SP2NL=$lt_lt_SP2NL
-
-# turn newlines into spaces.
-NL2SP=$lt_lt_NL2SP
-
-# An object symbol dumper.
-OBJDUMP=$lt_OBJDUMP
-
-# Method to check whether dependent libraries are shared objects.
-deplibs_check_method=$lt_deplibs_check_method
-
-# Command to use when deplibs_check_method == "file_magic".
-file_magic_cmd=$lt_file_magic_cmd
-
-# The archiver.
-AR=$lt_AR
-AR_FLAGS=$lt_AR_FLAGS
-
-# A symbol stripping program.
-STRIP=$lt_STRIP
-
-# Commands used to install an old-style archive.
-RANLIB=$lt_RANLIB
-old_postinstall_cmds=$lt_old_postinstall_cmds
-old_postuninstall_cmds=$lt_old_postuninstall_cmds
-
-# Whether to use a lock for old archive extraction.
-lock_old_archive_extraction=$lock_old_archive_extraction
-
-# A C compiler.
-LTCC=$lt_CC
-
-# LTCC compiler flags.
-LTCFLAGS=$lt_CFLAGS
-
-# Take the output of nm and produce a listing of raw symbols and C names.
-global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe
-
-# Transform the output of nm in a proper C declaration.
-global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl
-
-# Transform the output of nm in a C name address pair.
-global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
-
-# Transform the output of nm in a C name address pair when lib prefix is needed.
-global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix
-
-# The name of the directory that contains temporary libtool files.
-objdir=$objdir
-
-# Used to examine libraries when file_magic_cmd begins with "file".
-MAGIC_CMD=$MAGIC_CMD
-
-# Must we lock files when doing compilation?
-need_locks=$lt_need_locks
-
-# Tool to manipulate archived DWARF debug symbol files on Mac OS X.
-DSYMUTIL=$lt_DSYMUTIL
-
-# Tool to change global to local symbols on Mac OS X.
-NMEDIT=$lt_NMEDIT
-
-# Tool to manipulate fat objects and archives on Mac OS X.
-LIPO=$lt_LIPO
-
-# ldd/readelf like tool for Mach-O binaries on Mac OS X.
-OTOOL=$lt_OTOOL
-
-# ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4.
-OTOOL64=$lt_OTOOL64
-
-# Old archive suffix (normally "a").
-libext=$libext
-
-# Shared library suffix (normally ".so").
-shrext_cmds=$lt_shrext_cmds
-
-# The commands to extract the exported symbol list from a shared archive.
-extract_expsyms_cmds=$lt_extract_expsyms_cmds
-
-# Variables whose values should be saved in libtool wrapper scripts and
-# restored at link time.
-variables_saved_for_relink=$lt_variables_saved_for_relink
-
-# Do we need the "lib" prefix for modules?
-need_lib_prefix=$need_lib_prefix
-
-# Do we need a version for libraries?
-need_version=$need_version
-
-# Library versioning type.
-version_type=$version_type
-
-# Shared library runtime path variable.
-runpath_var=$runpath_var
-
-# Shared library path variable.
-shlibpath_var=$shlibpath_var
-
-# Is shlibpath searched before the hard-coded library search path?
-shlibpath_overrides_runpath=$shlibpath_overrides_runpath
-
-# Format of library name prefix.
-libname_spec=$lt_libname_spec
-
-# List of archive names. First name is the real one, the rest are links.
-# The last name is the one that the linker finds with -lNAME
-library_names_spec=$lt_library_names_spec
-
-# The coded name of the library, if different from the real name.
-soname_spec=$lt_soname_spec
-
-# Permission mode override for installation of shared libraries.
-install_override_mode=$lt_install_override_mode
-
-# Command to use after installation of a shared archive.
-postinstall_cmds=$lt_postinstall_cmds
-
-# Command to use after uninstallation of a shared archive.
-postuninstall_cmds=$lt_postuninstall_cmds
-
-# Commands used to finish a libtool library installation in a directory.
-finish_cmds=$lt_finish_cmds
-
-# As "finish_cmds", except a single script fragment to be evaled but
-# not shown.
-finish_eval=$lt_finish_eval
-
-# Whether we should hardcode library paths into libraries.
-hardcode_into_libs=$hardcode_into_libs
-
-# Compile-time system search path for libraries.
-sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
-
-# Run-time system search path for libraries.
-sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
-
-# Whether dlopen is supported.
-dlopen_support=$enable_dlopen
-
-# Whether dlopen of programs is supported.
-dlopen_self=$enable_dlopen_self
-
-# Whether dlopen of statically linked programs is supported.
-dlopen_self_static=$enable_dlopen_self_static
-
-# Commands to strip libraries.
-old_striplib=$lt_old_striplib
-striplib=$lt_striplib
-
-
-# The linker used to build libraries.
-LD=$lt_LD
-
-# How to create reloadable object files.
-reload_flag=$lt_reload_flag
-reload_cmds=$lt_reload_cmds
-
-# Commands used to build an old-style archive.
-old_archive_cmds=$lt_old_archive_cmds
-
-# A language specific compiler.
-CC=$lt_compiler
-
-# Is the compiler the GNU compiler?
-with_gcc=$GCC
-
-# Compiler flag to turn off builtin functions.
-no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag
-
-# How to pass a linker flag through the compiler.
-wl=$lt_lt_prog_compiler_wl
-
-# Additional compiler flags for building library objects.
-pic_flag=$lt_lt_prog_compiler_pic
-
-# Compiler flag to prevent dynamic linking.
-link_static_flag=$lt_lt_prog_compiler_static
-
-# Does compiler simultaneously support -c and -o options?
-compiler_c_o=$lt_lt_cv_prog_compiler_c_o
-
-# Whether or not to add -lc for building shared libraries.
-build_libtool_need_lc=$archive_cmds_need_lc
-
-# Whether or not to disallow shared libs when runtime libs are static.
-allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes
-
-# Compiler flag to allow reflexive dlopens.
-export_dynamic_flag_spec=$lt_export_dynamic_flag_spec
-
-# Compiler flag to generate shared objects directly from archives.
-whole_archive_flag_spec=$lt_whole_archive_flag_spec
-
-# Whether the compiler copes with passing no objects directly.
-compiler_needs_object=$lt_compiler_needs_object
-
-# Create an old-style archive from a shared archive.
-old_archive_from_new_cmds=$lt_old_archive_from_new_cmds
-
-# Create a temporary old-style archive to link instead of a shared archive.
-old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds
-
-# Commands used to build a shared archive.
-archive_cmds=$lt_archive_cmds
-archive_expsym_cmds=$lt_archive_expsym_cmds
-
-# Commands used to build a loadable module if different from building
-# a shared archive.
-module_cmds=$lt_module_cmds
-module_expsym_cmds=$lt_module_expsym_cmds
-
-# Whether we are building with GNU ld or not.
-with_gnu_ld=$lt_with_gnu_ld
-
-# Flag that allows shared libraries with undefined symbols to be built.
-allow_undefined_flag=$lt_allow_undefined_flag
-
-# Flag that enforces no undefined symbols.
-no_undefined_flag=$lt_no_undefined_flag
-
-# Flag to hardcode \$libdir into a binary during linking.
-# This must work even if \$libdir does not exist
-hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec
-
-# If ld is used when linking, flag to hardcode \$libdir into a binary
-# during linking. This must work even if \$libdir does not exist.
-hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld
-
-# Whether we need a single "-rpath" flag with a separated argument.
-hardcode_libdir_separator=$lt_hardcode_libdir_separator
-
-# Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
-# DIR into the resulting binary.
-hardcode_direct=$hardcode_direct
-
-# Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
-# DIR into the resulting binary and the resulting library dependency is
-# "absolute",i.e impossible to change by setting \${shlibpath_var} if the
-# library is relocated.
-hardcode_direct_absolute=$hardcode_direct_absolute
-
-# Set to "yes" if using the -LDIR flag during linking hardcodes DIR
-# into the resulting binary.
-hardcode_minus_L=$hardcode_minus_L
-
-# Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR
-# into the resulting binary.
-hardcode_shlibpath_var=$hardcode_shlibpath_var
-
-# Set to "yes" if building a shared library automatically hardcodes DIR
-# into the library and all subsequent libraries and executables linked
-# against it.
-hardcode_automatic=$hardcode_automatic
-
-# Set to yes if linker adds runtime paths of dependent libraries
-# to runtime path list.
-inherit_rpath=$inherit_rpath
-
-# Whether libtool must link a program against all its dependency libraries.
-link_all_deplibs=$link_all_deplibs
-
-# Fix the shell variable \$srcfile for the compiler.
-fix_srcfile_path=$lt_fix_srcfile_path
-
-# Set to "yes" if exported symbols are required.
-always_export_symbols=$always_export_symbols
-
-# The commands to list exported symbols.
-export_symbols_cmds=$lt_export_symbols_cmds
-
-# Symbols that should not be listed in the preloaded symbols.
-exclude_expsyms=$lt_exclude_expsyms
-
-# Symbols that must always be exported.
-include_expsyms=$lt_include_expsyms
-
-# Commands necessary for linking programs (against libraries) with templates.
-prelink_cmds=$lt_prelink_cmds
-
-# Specify filename containing input files.
-file_list_spec=$lt_file_list_spec
-
-# How to hardcode a shared library path into an executable.
-hardcode_action=$hardcode_action
-
-# ### END LIBTOOL CONFIG
-
-_LT_EOF
-
- case $host_os in
- aix3*)
- cat <<\_LT_EOF >> "$cfgfile"
-# AIX sometimes has problems with the GCC collect2 program. For some
-# reason, if we set the COLLECT_NAMES environment variable, the problems
-# vanish in a puff of smoke.
-if test "X${COLLECT_NAMES+set}" != Xset; then
- COLLECT_NAMES=
- export COLLECT_NAMES
-fi
-_LT_EOF
- ;;
- esac
-
-
-ltmain="$ac_aux_dir/ltmain.sh"
-
-
- # We use sed instead of cat because bash on DJGPP gets confused if
- # if finds mixed CR/LF and LF-only lines. Since sed operates in
- # text mode, it properly converts lines to CR/LF. This bash problem
- # is reportedly fixed, but why not run on old versions too?
- sed '/^# Generated shell functions inserted here/q' "$ltmain" >> "$cfgfile" \
- || (rm -f "$cfgfile"; exit 1)
-
- case $xsi_shell in
- yes)
- cat << \_LT_EOF >> "$cfgfile"
-
-# func_dirname file append nondir_replacement
-# Compute the dirname of FILE. If nonempty, add APPEND to the result,
-# otherwise set result to NONDIR_REPLACEMENT.
-func_dirname ()
-{
- case ${1} in
- */*) func_dirname_result="${1%/*}${2}" ;;
- * ) func_dirname_result="${3}" ;;
- esac
-}
-
-# func_basename file
-func_basename ()
-{
- func_basename_result="${1##*/}"
-}
-
-# func_dirname_and_basename file append nondir_replacement
-# perform func_basename and func_dirname in a single function
-# call:
-# dirname: Compute the dirname of FILE. If nonempty,
-# add APPEND to the result, otherwise set result
-# to NONDIR_REPLACEMENT.
-# value returned in "$func_dirname_result"
-# basename: Compute filename of FILE.
-# value retuned in "$func_basename_result"
-# Implementation must be kept synchronized with func_dirname
-# and func_basename. For efficiency, we do not delegate to
-# those functions but instead duplicate the functionality here.
-func_dirname_and_basename ()
-{
- case ${1} in
- */*) func_dirname_result="${1%/*}${2}" ;;
- * ) func_dirname_result="${3}" ;;
- esac
- func_basename_result="${1##*/}"
-}
-
-# func_stripname prefix suffix name
-# strip PREFIX and SUFFIX off of NAME.
-# PREFIX and SUFFIX must not contain globbing or regex special
-# characters, hashes, percent signs, but SUFFIX may contain a leading
-# dot (in which case that matches only a dot).
-func_stripname ()
-{
- # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are
- # positional parameters, so assign one to ordinary parameter first.
- func_stripname_result=${3}
- func_stripname_result=${func_stripname_result#"${1}"}
- func_stripname_result=${func_stripname_result%"${2}"}
-}
-
-# func_opt_split
-func_opt_split ()
-{
- func_opt_split_opt=${1%%=*}
- func_opt_split_arg=${1#*=}
-}
-
-# func_lo2o object
-func_lo2o ()
-{
- case ${1} in
- *.lo) func_lo2o_result=${1%.lo}.${objext} ;;
- *) func_lo2o_result=${1} ;;
- esac
-}
-
-# func_xform libobj-or-source
-func_xform ()
-{
- func_xform_result=${1%.*}.lo
-}
-
-# func_arith arithmetic-term...
-func_arith ()
-{
- func_arith_result=$(( $* ))
-}
-
-# func_len string
-# STRING may not start with a hyphen.
-func_len ()
-{
- func_len_result=${#1}
-}
-
-_LT_EOF
- ;;
- *) # Bourne compatible functions.
- cat << \_LT_EOF >> "$cfgfile"
-
-# func_dirname file append nondir_replacement
-# Compute the dirname of FILE. If nonempty, add APPEND to the result,
-# otherwise set result to NONDIR_REPLACEMENT.
-func_dirname ()
-{
- # Extract subdirectory from the argument.
- func_dirname_result=`$ECHO "${1}" | $SED "$dirname"`
- if test "X$func_dirname_result" = "X${1}"; then
- func_dirname_result="${3}"
- else
- func_dirname_result="$func_dirname_result${2}"
- fi
-}
-
-# func_basename file
-func_basename ()
-{
- func_basename_result=`$ECHO "${1}" | $SED "$basename"`
-}
-
-
-# func_stripname prefix suffix name
-# strip PREFIX and SUFFIX off of NAME.
-# PREFIX and SUFFIX must not contain globbing or regex special
-# characters, hashes, percent signs, but SUFFIX may contain a leading
-# dot (in which case that matches only a dot).
-# func_strip_suffix prefix name
-func_stripname ()
-{
- case ${2} in
- .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;;
- *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;;
- esac
-}
-
-# sed scripts:
-my_sed_long_opt='1s/^\(-[^=]*\)=.*/\1/;q'
-my_sed_long_arg='1s/^-[^=]*=//'
-
-# func_opt_split
-func_opt_split ()
-{
- func_opt_split_opt=`$ECHO "${1}" | $SED "$my_sed_long_opt"`
- func_opt_split_arg=`$ECHO "${1}" | $SED "$my_sed_long_arg"`
-}
-
-# func_lo2o object
-func_lo2o ()
-{
- func_lo2o_result=`$ECHO "${1}" | $SED "$lo2o"`
-}
-
-# func_xform libobj-or-source
-func_xform ()
-{
- func_xform_result=`$ECHO "${1}" | $SED 's/\.[^.]*$/.lo/'`
-}
-
-# func_arith arithmetic-term...
-func_arith ()
-{
- func_arith_result=`expr "$@"`
-}
-
-# func_len string
-# STRING may not start with a hyphen.
-func_len ()
-{
- func_len_result=`expr "$1" : ".*" 2>/dev/null || echo $max_cmd_len`
-}
-
-_LT_EOF
-esac
-
-case $lt_shell_append in
- yes)
- cat << \_LT_EOF >> "$cfgfile"
-
-# func_append var value
-# Append VALUE to the end of shell variable VAR.
-func_append ()
-{
- eval "$1+=\$2"
-}
-_LT_EOF
- ;;
- *)
- cat << \_LT_EOF >> "$cfgfile"
-
-# func_append var value
-# Append VALUE to the end of shell variable VAR.
-func_append ()
-{
- eval "$1=\$$1\$2"
-}
-
-_LT_EOF
- ;;
- esac
-
-
- sed -n '/^# Generated shell functions inserted here/,$p' "$ltmain" >> "$cfgfile" \
- || (rm -f "$cfgfile"; exit 1)
-
- mv -f "$cfgfile" "$ofile" ||
- (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
- chmod +x "$ofile"
-
- ;;
- "default-1":C)
- for ac_file in $CONFIG_FILES; do
- # Support "outfile[:infile[:infile...]]"
- case "$ac_file" in
- *:*) ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
- esac
- # PO directories have a Makefile.in generated from Makefile.in.in.
- case "$ac_file" in */Makefile.in)
- # Adjust a relative srcdir.
- ac_dir=`echo "$ac_file"|sed 's%/[^/][^/]*$%%'`
- ac_dir_suffix=/`echo "$ac_dir"|sed 's%^\./%%'`
- ac_dots=`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'`
- # In autoconf-2.13 it is called $ac_given_srcdir.
- # In autoconf-2.50 it is called $srcdir.
- test -n "$ac_given_srcdir" || ac_given_srcdir="$srcdir"
- case "$ac_given_srcdir" in
- .) top_srcdir=`echo $ac_dots|sed 's%/$%%'` ;;
- /*) top_srcdir="$ac_given_srcdir" ;;
- *) top_srcdir="$ac_dots$ac_given_srcdir" ;;
- esac
- if test -f "$ac_given_srcdir/$ac_dir/POTFILES.in"; then
- rm -f "$ac_dir/POTFILES"
- test -n "$as_me" && echo "$as_me: creating $ac_dir/POTFILES" || echo "creating $ac_dir/POTFILES"
- cat "$ac_given_srcdir/$ac_dir/POTFILES.in" | sed -e "/^#/d" -e "/^[ ]*\$/d" -e "s,.*, $top_srcdir/& \\\\," | sed -e "\$s/\(.*\) \\\\/\1/" > "$ac_dir/POTFILES"
- POMAKEFILEDEPS="POTFILES.in"
- # ALL_LINGUAS, POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES depend
- # on $ac_dir but don't depend on user-specified configuration
- # parameters.
- if test -f "$ac_given_srcdir/$ac_dir/LINGUAS"; then
- # The LINGUAS file contains the set of available languages.
- if test -n "$OBSOLETE_ALL_LINGUAS"; then
- test -n "$as_me" && echo "$as_me: setting ALL_LINGUAS in configure.ac is obsolete" || echo "setting ALL_LINGUAS in configure.ac is obsolete"
- fi
- ALL_LINGUAS_=`sed -e "/^#/d" "$ac_given_srcdir/$ac_dir/LINGUAS"`
- # Hide the ALL_LINGUAS assigment from automake.
- eval 'ALL_LINGUAS''=$ALL_LINGUAS_'
- POMAKEFILEDEPS="$POMAKEFILEDEPS LINGUAS"
- else
- # The set of available languages was given in configure.ac.
- eval 'ALL_LINGUAS''=$OBSOLETE_ALL_LINGUAS'
- fi
- case "$ac_given_srcdir" in
- .) srcdirpre= ;;
- *) srcdirpre='$(srcdir)/' ;;
- esac
- POFILES=
- GMOFILES=
- UPDATEPOFILES=
- DUMMYPOFILES=
- for lang in $ALL_LINGUAS; do
- POFILES="$POFILES $srcdirpre$lang.po"
- GMOFILES="$GMOFILES $srcdirpre$lang.gmo"
- UPDATEPOFILES="$UPDATEPOFILES $lang.po-update"
- DUMMYPOFILES="$DUMMYPOFILES $lang.nop"
- done
- # CATALOGS depends on both $ac_dir and the user's LINGUAS
- # environment variable.
- INST_LINGUAS=
- if test -n "$ALL_LINGUAS"; then
- for presentlang in $ALL_LINGUAS; do
- useit=no
- if test "%UNSET%" != "$LINGUAS"; then
- desiredlanguages="$LINGUAS"
- else
- desiredlanguages="$ALL_LINGUAS"
- fi
- for desiredlang in $desiredlanguages; do
- # Use the presentlang catalog if desiredlang is
- # a. equal to presentlang, or
- # b. a variant of presentlang (because in this case,
- # presentlang can be used as a fallback for messages
- # which are not translated in the desiredlang catalog).
- case "$desiredlang" in
- "$presentlang"*) useit=yes;;
- esac
- done
- if test $useit = yes; then
- INST_LINGUAS="$INST_LINGUAS $presentlang"
- fi
- done
- fi
- CATALOGS=
- if test -n "$INST_LINGUAS"; then
- for lang in $INST_LINGUAS; do
- CATALOGS="$CATALOGS $lang.gmo"
- done
- fi
- test -n "$as_me" && echo "$as_me: creating $ac_dir/Makefile" || echo "creating $ac_dir/Makefile"
- sed -e "/^POTFILES =/r $ac_dir/POTFILES" -e "/^# Makevars/r $ac_given_srcdir/$ac_dir/Makevars" -e "s|@POFILES@|$POFILES|g" -e "s|@GMOFILES@|$GMOFILES|g" -e "s|@UPDATEPOFILES@|$UPDATEPOFILES|g" -e "s|@DUMMYPOFILES@|$DUMMYPOFILES|g" -e "s|@CATALOGS@|$CATALOGS|g" -e "s|@POMAKEFILEDEPS@|$POMAKEFILEDEPS|g" "$ac_dir/Makefile.in" > "$ac_dir/Makefile"
- for f in "$ac_given_srcdir/$ac_dir"/Rules-*; do
- if test -f "$f"; then
- case "$f" in
- *.orig | *.bak | *~) ;;
- *) cat "$f" >> "$ac_dir/Makefile" ;;
- esac
- fi
- done
- fi
- ;;
- esac
- done ;;
- "default-2":C)
- for ac_file in $CONFIG_FILES; do
- # Support "outfile[:infile[:infile...]]"
- case "$ac_file" in
- *:*) ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
- esac
- # PO directories have a Makefile.in generated from Makefile.in.in.
- case "$ac_file" in */Makefile.in)
- # Adjust a relative srcdir.
- ac_dir=`echo "$ac_file"|sed 's%/[^/][^/]*$%%'`
- ac_dir_suffix=/`echo "$ac_dir"|sed 's%^\./%%'`
- ac_dots=`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'`
- # In autoconf-2.13 it is called $ac_given_srcdir.
- # In autoconf-2.50 it is called $srcdir.
- test -n "$ac_given_srcdir" || ac_given_srcdir="$srcdir"
- case "$ac_given_srcdir" in
- .) top_srcdir=`echo $ac_dots|sed 's%/$%%'` ;;
- /*) top_srcdir="$ac_given_srcdir" ;;
- *) top_srcdir="$ac_dots$ac_given_srcdir" ;;
- esac
- if test -f "$ac_given_srcdir/$ac_dir/POTFILES.in"; then
- rm -f "$ac_dir/POTFILES"
- test -n "$as_me" && echo "$as_me: creating $ac_dir/POTFILES" || echo "creating $ac_dir/POTFILES"
- cat "$ac_given_srcdir/$ac_dir/POTFILES.in" | sed -e "/^#/d" -e "/^[ ]*\$/d" -e "s,.*, $top_srcdir/& \\\\," | sed -e "\$s/\(.*\) \\\\/\1/" > "$ac_dir/POTFILES"
- POMAKEFILEDEPS="POTFILES.in"
- # ALL_LINGUAS, POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES depend
- # on $ac_dir but don't depend on user-specified configuration
- # parameters.
- if test -f "$ac_given_srcdir/$ac_dir/LINGUAS"; then
- # The LINGUAS file contains the set of available languages.
- if test -n "$OBSOLETE_ALL_LINGUAS"; then
- test -n "$as_me" && echo "$as_me: setting ALL_LINGUAS in configure.ac is obsolete" || echo "setting ALL_LINGUAS in configure.ac is obsolete"
- fi
- ALL_LINGUAS_=`sed -e "/^#/d" "$ac_given_srcdir/$ac_dir/LINGUAS"`
- # Hide the ALL_LINGUAS assigment from automake.
- eval 'ALL_LINGUAS''=$ALL_LINGUAS_'
- POMAKEFILEDEPS="$POMAKEFILEDEPS LINGUAS"
- else
- # The set of available languages was given in configure.ac.
- eval 'ALL_LINGUAS''=$OBSOLETE_ALL_LINGUAS'
- fi
- case "$ac_given_srcdir" in
- .) srcdirpre= ;;
- *) srcdirpre='$(srcdir)/' ;;
- esac
- POFILES=
- GMOFILES=
- UPDATEPOFILES=
- DUMMYPOFILES=
- for lang in $ALL_LINGUAS; do
- POFILES="$POFILES $srcdirpre$lang.po"
- GMOFILES="$GMOFILES $srcdirpre$lang.gmo"
- UPDATEPOFILES="$UPDATEPOFILES $lang.po-update"
- DUMMYPOFILES="$DUMMYPOFILES $lang.nop"
- done
- # CATALOGS depends on both $ac_dir and the user's LINGUAS
- # environment variable.
- INST_LINGUAS=
- if test -n "$ALL_LINGUAS"; then
- for presentlang in $ALL_LINGUAS; do
- useit=no
- if test "%UNSET%" != "$LINGUAS"; then
- desiredlanguages="$LINGUAS"
- else
- desiredlanguages="$ALL_LINGUAS"
- fi
- for desiredlang in $desiredlanguages; do
- # Use the presentlang catalog if desiredlang is
- # a. equal to presentlang, or
- # b. a variant of presentlang (because in this case,
- # presentlang can be used as a fallback for messages
- # which are not translated in the desiredlang catalog).
- case "$desiredlang" in
- "$presentlang"*) useit=yes;;
- esac
- done
- if test $useit = yes; then
- INST_LINGUAS="$INST_LINGUAS $presentlang"
- fi
- done
- fi
- CATALOGS=
- if test -n "$INST_LINGUAS"; then
- for lang in $INST_LINGUAS; do
- CATALOGS="$CATALOGS $lang.gmo"
- done
- fi
- test -n "$as_me" && echo "$as_me: creating $ac_dir/Makefile" || echo "creating $ac_dir/Makefile"
- sed -e "/^POTFILES =/r $ac_dir/POTFILES" -e "/^# Makevars/r $ac_given_srcdir/$ac_dir/Makevars" -e "s|@POFILES@|$POFILES|g" -e "s|@GMOFILES@|$GMOFILES|g" -e "s|@UPDATEPOFILES@|$UPDATEPOFILES|g" -e "s|@DUMMYPOFILES@|$DUMMYPOFILES|g" -e "s|@CATALOGS@|$CATALOGS|g" -e "s|@POMAKEFILEDEPS@|$POMAKEFILEDEPS|g" "$ac_dir/Makefile.in" > "$ac_dir/Makefile"
- for f in "$ac_given_srcdir/$ac_dir"/Rules-*; do
- if test -f "$f"; then
- case "$f" in
- *.orig | *.bak | *~) ;;
- *) cat "$f" >> "$ac_dir/Makefile" ;;
- esac
- fi
- done
- fi
- ;;
- esac
- done ;;
- "default":C) rm -f targ-cpu.c targ-cpu.h obj-format.h obj-format.c targ-env.h atof-targ.c itbl-cpu.h
- echo '#include "tc-'"${target_cpu_type}"'.h"' > targ-cpu.h
- echo '#include "obj-'"${obj_format}"'.h"' > obj-format.h
- echo '#include "te-'"${te_file}"'.h"' > targ-env.h
- echo '#include "itbl-'"${target_cpu_type}"'.h"' > itbl-cpu.h
- if test "x$cgen_cpu_prefix" != x ; then
- echo '#include "opcodes/'"${cgen_cpu_prefix}"'-desc.h"' > cgen-desc.h
- fi ;;
-
- esac
-done # for ac_tag
-
-
-as_fn_exit 0
-_ACEOF
-ac_clean_files=$ac_clean_files_save
-
-test $ac_write_fail = 0 ||
- as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
-
-
-# configure is writing to config.log, and then calls config.status.
-# config.status does its own redirection, appending to config.log.
-# Unfortunately, on DOS this fails, as config.log is still kept open
-# by configure, so config.status won't be able to write to it; its
-# output is simply discarded. So we exec the FD to /dev/null,
-# effectively closing config.log, so it can be properly (re)opened and
-# appended to by config.status. When coming back to configure, we
-# need to make the FD available again.
-if test "$no_create" != yes; then
- ac_cs_success=:
- ac_config_status_args=
- test "$silent" = yes &&
- ac_config_status_args="$ac_config_status_args --quiet"
- exec 5>/dev/null
- $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
- exec 5>>config.log
- # Use ||, not &&, to avoid exiting from the if with $? = 1, which
- # would make configure fail if this is the last instruction.
- $ac_cs_success || as_fn_exit 1
-fi
-if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
-$as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
-fi
-
-
-
-touch config.status.tmp
-if touch --reference=config.status config.status.tmp > /dev/null 2>&1; then
- sed '/as_fn_exit 0/i \
-sed -e \"s/^\t\\\(\\\$(AM_V_CCLD)\\\)/\t+ \\\1/\" Makefile > Makefile.tmp \
-touch --reference=Makefile Makefile.tmp \
-mv Makefile.tmp Makefile \
-' config.status > config.status.tmp
- touch --reference=config.status config.status.tmp
- mv config.status.tmp config.status
- chmod +x config.status
- sed -e "s/^\t\(\$(AM_V_CCLD)\)/\t+ \1/" Makefile > Makefile.tmp
- touch --reference=Makefile Makefile.tmp
- mv Makefile.tmp Makefile
-else
- rm -f config.status.tmp
-fi
Property changes on: sources/GNU/binutils/create-2.43.1-libtool-lib64-patch/binutils-2.43.1-new/gas/configure
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: sources/GNU/binutils/create-2.43.1-libtool-lib64-patch/binutils-2.43.1-new/bfd/configure
===================================================================
--- sources/GNU/binutils/create-2.43.1-libtool-lib64-patch/binutils-2.43.1-new/bfd/configure (revision 75)
+++ sources/GNU/binutils/create-2.43.1-libtool-lib64-patch/binutils-2.43.1-new/bfd/configure (nonexistent)
@@ -1,20208 +0,0 @@
-#! /bin/sh
-# Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.69 for bfd 2.43.1.
-#
-#
-# Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc.
-#
-#
-# This configure script is free software; the Free Software Foundation
-# gives unlimited permission to copy, distribute and modify it.
-## -------------------- ##
-## M4sh Initialization. ##
-## -------------------- ##
-
-# Be more Bourne compatible
-DUALCASE=1; export DUALCASE # for MKS sh
-if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
- emulate sh
- NULLCMD=:
- # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
- # is contrary to our usage. Disable this feature.
- alias -g '${1+"$@"}'='"$@"'
- setopt NO_GLOB_SUBST
-else
- case `(set -o) 2>/dev/null` in #(
- *posix*) :
- set -o posix ;; #(
- *) :
- ;;
-esac
-fi
-
-
-as_nl='
-'
-export as_nl
-# Printing a long string crashes Solaris 7 /usr/bin/printf.
-as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
-as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
-as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
-# Prefer a ksh shell builtin over an external printf program on Solaris,
-# but without wasting forks for bash or zsh.
-if test -z "$BASH_VERSION$ZSH_VERSION" \
- && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
- as_echo='print -r --'
- as_echo_n='print -rn --'
-elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
- as_echo='printf %s\n'
- as_echo_n='printf %s'
-else
- if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
- as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
- as_echo_n='/usr/ucb/echo -n'
- else
- as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
- as_echo_n_body='eval
- arg=$1;
- case $arg in #(
- *"$as_nl"*)
- expr "X$arg" : "X\\(.*\\)$as_nl";
- arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
- esac;
- expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
- '
- export as_echo_n_body
- as_echo_n='sh -c $as_echo_n_body as_echo'
- fi
- export as_echo_body
- as_echo='sh -c $as_echo_body as_echo'
-fi
-
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- PATH_SEPARATOR=:
- (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
- (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
- PATH_SEPARATOR=';'
- }
-fi
-
-
-# IFS
-# We need space, tab and new line, in precisely that order. Quoting is
-# there to prevent editors from complaining about space-tab.
-# (If _AS_PATH_WALK were called with IFS unset, it would disable word
-# splitting by setting IFS to empty value.)
-IFS=" "" $as_nl"
-
-# Find who we are. Look in the path if we contain no directory separator.
-as_myself=
-case $0 in #((
- *[\\/]* ) as_myself=$0 ;;
- *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
- done
-IFS=$as_save_IFS
-
- ;;
-esac
-# We did not find ourselves, most probably we were run as `sh COMMAND'
-# in which case we are not to be found in the path.
-if test "x$as_myself" = x; then
- as_myself=$0
-fi
-if test ! -f "$as_myself"; then
- $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
- exit 1
-fi
-
-# Unset variables that we do not need and which cause bugs (e.g. in
-# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
-# suppresses any "Segmentation fault" message there. '((' could
-# trigger a bug in pdksh 5.2.14.
-for as_var in BASH_ENV ENV MAIL MAILPATH
-do eval test x\${$as_var+set} = xset \
- && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
-done
-PS1='$ '
-PS2='> '
-PS4='+ '
-
-# NLS nuisances.
-LC_ALL=C
-export LC_ALL
-LANGUAGE=C
-export LANGUAGE
-
-# CDPATH.
-(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
-
-# Use a proper internal environment variable to ensure we don't fall
- # into an infinite loop, continuously re-executing ourselves.
- if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then
- _as_can_reexec=no; export _as_can_reexec;
- # We cannot yet assume a decent shell, so we have to provide a
-# neutralization value for shells without unset; and this also
-# works around shells that cannot unset nonexistent variables.
-# Preserve -v and -x to the replacement shell.
-BASH_ENV=/dev/null
-ENV=/dev/null
-(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
-case $- in # ((((
- *v*x* | *x*v* ) as_opts=-vx ;;
- *v* ) as_opts=-v ;;
- *x* ) as_opts=-x ;;
- * ) as_opts= ;;
-esac
-exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
-# Admittedly, this is quite paranoid, since all the known shells bail
-# out after a failed `exec'.
-$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
-as_fn_exit 255
- fi
- # We don't want this to propagate to other subprocesses.
- { _as_can_reexec=; unset _as_can_reexec;}
-if test "x$CONFIG_SHELL" = x; then
- as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
- emulate sh
- NULLCMD=:
- # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
- # is contrary to our usage. Disable this feature.
- alias -g '\${1+\"\$@\"}'='\"\$@\"'
- setopt NO_GLOB_SUBST
-else
- case \`(set -o) 2>/dev/null\` in #(
- *posix*) :
- set -o posix ;; #(
- *) :
- ;;
-esac
-fi
-"
- as_required="as_fn_return () { (exit \$1); }
-as_fn_success () { as_fn_return 0; }
-as_fn_failure () { as_fn_return 1; }
-as_fn_ret_success () { return 0; }
-as_fn_ret_failure () { return 1; }
-
-exitcode=0
-as_fn_success || { exitcode=1; echo as_fn_success failed.; }
-as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
-as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
-as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
-if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
-
-else
- exitcode=1; echo positional parameters were not saved.
-fi
-test x\$exitcode = x0 || exit 1
-test -x / || exit 1"
- as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
- as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
- eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
- test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
-test \$(( 1 + 1 )) = 2 || exit 1
-
- test -n \"\${ZSH_VERSION+set}\${BASH_VERSION+set}\" || (
- ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
- ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO
- ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO
- PATH=/empty FPATH=/empty; export PATH FPATH
- test \"X\`printf %s \$ECHO\`\" = \"X\$ECHO\" \\
- || test \"X\`print -r -- \$ECHO\`\" = \"X\$ECHO\" ) || exit 1"
- if (eval "$as_required") 2>/dev/null; then :
- as_have_required=yes
-else
- as_have_required=no
-fi
- if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
-
-else
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-as_found=false
-for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- as_found=:
- case $as_dir in #(
- /*)
- for as_base in sh bash ksh sh5; do
- # Try only shells that exist, to save several forks.
- as_shell=$as_dir/$as_base
- if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
- { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
- CONFIG_SHELL=$as_shell as_have_required=yes
- if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
- break 2
-fi
-fi
- done;;
- esac
- as_found=false
-done
-$as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
- { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
- CONFIG_SHELL=$SHELL as_have_required=yes
-fi; }
-IFS=$as_save_IFS
-
-
- if test "x$CONFIG_SHELL" != x; then :
- export CONFIG_SHELL
- # We cannot yet assume a decent shell, so we have to provide a
-# neutralization value for shells without unset; and this also
-# works around shells that cannot unset nonexistent variables.
-# Preserve -v and -x to the replacement shell.
-BASH_ENV=/dev/null
-ENV=/dev/null
-(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
-case $- in # ((((
- *v*x* | *x*v* ) as_opts=-vx ;;
- *v* ) as_opts=-v ;;
- *x* ) as_opts=-x ;;
- * ) as_opts= ;;
-esac
-exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
-# Admittedly, this is quite paranoid, since all the known shells bail
-# out after a failed `exec'.
-$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
-exit 255
-fi
-
- if test x$as_have_required = xno; then :
- $as_echo "$0: This script requires a shell more modern than all"
- $as_echo "$0: the shells that I found on your system."
- if test x${ZSH_VERSION+set} = xset ; then
- $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
- $as_echo "$0: be upgraded to zsh 4.3.4 or later."
- else
- $as_echo "$0: Please tell bug-autoconf@gnu.org about your system,
-$0: including any error possibly output before this
-$0: message. Then install a modern shell, or manually run
-$0: the script under such a shell if you do have one."
- fi
- exit 1
-fi
-fi
-fi
-SHELL=${CONFIG_SHELL-/bin/sh}
-export SHELL
-# Unset more variables known to interfere with behavior of common tools.
-CLICOLOR_FORCE= GREP_OPTIONS=
-unset CLICOLOR_FORCE GREP_OPTIONS
-
-## --------------------- ##
-## M4sh Shell Functions. ##
-## --------------------- ##
-# as_fn_unset VAR
-# ---------------
-# Portably unset VAR.
-as_fn_unset ()
-{
- { eval $1=; unset $1;}
-}
-as_unset=as_fn_unset
-
-# as_fn_set_status STATUS
-# -----------------------
-# Set $? to STATUS, without forking.
-as_fn_set_status ()
-{
- return $1
-} # as_fn_set_status
-
-# as_fn_exit STATUS
-# -----------------
-# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
-as_fn_exit ()
-{
- set +e
- as_fn_set_status $1
- exit $1
-} # as_fn_exit
-
-# as_fn_mkdir_p
-# -------------
-# Create "$as_dir" as a directory, including parents if necessary.
-as_fn_mkdir_p ()
-{
-
- case $as_dir in #(
- -*) as_dir=./$as_dir;;
- esac
- test -d "$as_dir" || eval $as_mkdir_p || {
- as_dirs=
- while :; do
- case $as_dir in #(
- *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
- *) as_qdir=$as_dir;;
- esac
- as_dirs="'$as_qdir' $as_dirs"
- as_dir=`$as_dirname -- "$as_dir" ||
-$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$as_dir" : 'X\(//\)[^/]' \| \
- X"$as_dir" : 'X\(//\)$' \| \
- X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$as_dir" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
- test -d "$as_dir" && break
- done
- test -z "$as_dirs" || eval "mkdir $as_dirs"
- } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
-
-
-} # as_fn_mkdir_p
-
-# as_fn_executable_p FILE
-# -----------------------
-# Test if FILE is an executable regular file.
-as_fn_executable_p ()
-{
- test -f "$1" && test -x "$1"
-} # as_fn_executable_p
-# as_fn_append VAR VALUE
-# ----------------------
-# Append the text in VALUE to the end of the definition contained in VAR. Take
-# advantage of any shell optimizations that allow amortized linear growth over
-# repeated appends, instead of the typical quadratic growth present in naive
-# implementations.
-if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
- eval 'as_fn_append ()
- {
- eval $1+=\$2
- }'
-else
- as_fn_append ()
- {
- eval $1=\$$1\$2
- }
-fi # as_fn_append
-
-# as_fn_arith ARG...
-# ------------------
-# Perform arithmetic evaluation on the ARGs, and store the result in the
-# global $as_val. Take advantage of shells that can avoid forks. The arguments
-# must be portable across $(()) and expr.
-if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
- eval 'as_fn_arith ()
- {
- as_val=$(( $* ))
- }'
-else
- as_fn_arith ()
- {
- as_val=`expr "$@" || test $? -eq 1`
- }
-fi # as_fn_arith
-
-
-# as_fn_error STATUS ERROR [LINENO LOG_FD]
-# ----------------------------------------
-# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
-# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
-# script with STATUS, using 1 if that was 0.
-as_fn_error ()
-{
- as_status=$1; test $as_status -eq 0 && as_status=1
- if test "$4"; then
- as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
- fi
- $as_echo "$as_me: error: $2" >&2
- as_fn_exit $as_status
-} # as_fn_error
-
-if expr a : '\(a\)' >/dev/null 2>&1 &&
- test "X`expr 00001 : '.*\(...\)'`" = X001; then
- as_expr=expr
-else
- as_expr=false
-fi
-
-if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
- as_basename=basename
-else
- as_basename=false
-fi
-
-if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
- as_dirname=dirname
-else
- as_dirname=false
-fi
-
-as_me=`$as_basename -- "$0" ||
-$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
- X"$0" : 'X\(//\)$' \| \
- X"$0" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X/"$0" |
- sed '/^.*\/\([^/][^/]*\)\/*$/{
- s//\1/
- q
- }
- /^X\/\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\/\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
-
-# Avoid depending upon Character Ranges.
-as_cr_letters='abcdefghijklmnopqrstuvwxyz'
-as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
-as_cr_Letters=$as_cr_letters$as_cr_LETTERS
-as_cr_digits='0123456789'
-as_cr_alnum=$as_cr_Letters$as_cr_digits
-
-
- as_lineno_1=$LINENO as_lineno_1a=$LINENO
- as_lineno_2=$LINENO as_lineno_2a=$LINENO
- eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
- test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
- # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-)
- sed -n '
- p
- /[$]LINENO/=
- ' <$as_myself |
- sed '
- s/[$]LINENO.*/&-/
- t lineno
- b
- :lineno
- N
- :loop
- s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
- t loop
- s/-\n.*//
- ' >$as_me.lineno &&
- chmod +x "$as_me.lineno" ||
- { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
-
- # If we had to re-execute with $CONFIG_SHELL, we're ensured to have
- # already done that, so ensure we don't try to do so again and fall
- # in an infinite loop. This has already happened in practice.
- _as_can_reexec=no; export _as_can_reexec
- # Don't try to exec as it changes $[0], causing all sort of problems
- # (the dirname of $[0] is not the place where we might find the
- # original and so on. Autoconf is especially sensitive to this).
- . "./$as_me.lineno"
- # Exit status is that of the last command.
- exit
-}
-
-ECHO_C= ECHO_N= ECHO_T=
-case `echo -n x` in #(((((
--n*)
- case `echo 'xy\c'` in
- *c*) ECHO_T=' ';; # ECHO_T is single tab character.
- xy) ECHO_C='\c';;
- *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
- ECHO_T=' ';;
- esac;;
-*)
- ECHO_N='-n';;
-esac
-
-rm -f conf$$ conf$$.exe conf$$.file
-if test -d conf$$.dir; then
- rm -f conf$$.dir/conf$$.file
-else
- rm -f conf$$.dir
- mkdir conf$$.dir 2>/dev/null
-fi
-if (echo >conf$$.file) 2>/dev/null; then
- if ln -s conf$$.file conf$$ 2>/dev/null; then
- as_ln_s='ln -s'
- # ... but there are two gotchas:
- # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
- # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
- # In both cases, we have to default to `cp -pR'.
- ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
- as_ln_s='cp -pR'
- elif ln conf$$.file conf$$ 2>/dev/null; then
- as_ln_s=ln
- else
- as_ln_s='cp -pR'
- fi
-else
- as_ln_s='cp -pR'
-fi
-rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
-rmdir conf$$.dir 2>/dev/null
-
-if mkdir -p . 2>/dev/null; then
- as_mkdir_p='mkdir -p "$as_dir"'
-else
- test -d ./-p && rmdir ./-p
- as_mkdir_p=false
-fi
-
-as_test_x='test -x'
-as_executable_p=as_fn_executable_p
-
-# Sed expression to map a string onto a valid CPP name.
-as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
-
-# Sed expression to map a string onto a valid variable name.
-as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
-
-SHELL=${CONFIG_SHELL-/bin/sh}
-
-
-test -n "$DJDIR" || exec 7<&0 </dev/null
-exec 6>&1
-
-# Name of the host.
-# hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status,
-# so uname gets run too.
-ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
-
-#
-# Initializations.
-#
-ac_default_prefix=/usr/local
-ac_clean_files=
-ac_config_libobj_dir=.
-LIBOBJS=
-cross_compiling=no
-subdirs=
-MFLAGS=
-MAKEFLAGS=
-
-# Identity of this package.
-PACKAGE_NAME='bfd'
-PACKAGE_TARNAME='bfd'
-PACKAGE_VERSION='2.43.1'
-PACKAGE_STRING='bfd 2.43.1'
-PACKAGE_BUGREPORT=''
-PACKAGE_URL=''
-
-ac_unique_file="libbfd.c"
-# Factoring default headers for most tests.
-ac_includes_default="\
-#include <stdio.h>
-#ifdef HAVE_SYS_TYPES_H
-# include <sys/types.h>
-#endif
-#ifdef HAVE_SYS_STAT_H
-# include <sys/stat.h>
-#endif
-#ifdef STDC_HEADERS
-# include <stdlib.h>
-# include <stddef.h>
-#else
-# ifdef HAVE_STDLIB_H
-# include <stdlib.h>
-# endif
-#endif
-#ifdef HAVE_STRING_H
-# if !defined STDC_HEADERS && defined HAVE_MEMORY_H
-# include <memory.h>
-# endif
-# include <string.h>
-#endif
-#ifdef HAVE_STRINGS_H
-# include <strings.h>
-#endif
-#ifdef HAVE_INTTYPES_H
-# include <inttypes.h>
-#endif
-#ifdef HAVE_STDINT_H
-# include <stdint.h>
-#endif
-#ifdef HAVE_UNISTD_H
-# include <unistd.h>
-#endif"
-
-gt_needs=
-ac_header_list=
-ac_subst_vars='am__EXEEXT_FALSE
-am__EXEEXT_TRUE
-LTLIBOBJS
-LIBOBJS
-bfd_ufile_ptr
-bfd_file_ptr
-lt_cv_dlopen_libs
-supports_plugins
-COREFLAG
-COREFILE
-havevecs
-tdefaults
-bfd_default_target_size
-bfd_machines
-bfd_backends
-all_backends
-bfd64_libs
-wordsize
-TDEFINES
-SHARED_LIBADD
-SHARED_LDFLAGS
-LIBM
-ZSTD_LIBS
-ZSTD_CFLAGS
-PKG_CONFIG_LIBDIR
-PKG_CONFIG_PATH
-PKG_CONFIG
-zlibinc
-zlibdir
-EXEEXT_FOR_BUILD
-CC_FOR_BUILD
-HDEFINES
-CATOBJEXT
-GENCAT
-INSTOBJEXT
-DATADIRNAME
-CATALOGS
-INCINTL
-LIBINTL_DEP
-POSUB
-LTLIBINTL
-LIBINTL
-INTLLIBS
-LTLIBICONV
-LIBICONV
-INTL_MACOSX_LIBS
-MSGMERGE
-XGETTEXT
-GMSGFMT
-MSGFMT
-USE_NLS
-MKINSTALLDIRS
-bfdincludedir
-bfdlibdir
-target_noncanonical
-host_noncanonical
-INSTALL_LIBBFD_FALSE
-INSTALL_LIBBFD_TRUE
-GENINSRC_NEVER_FALSE
-GENINSRC_NEVER_TRUE
-MAINT
-MAINTAINER_MODE_FALSE
-MAINTAINER_MODE_TRUE
-WARN_WRITE_STRINGS
-NO_WERROR
-WARN_CFLAGS_FOR_BUILD
-WARN_CFLAGS
-REPORT_BUGS_TEXI
-REPORT_BUGS_TO
-PKGVERSION
-DEBUGDIR
-ENABLE_BFD_64_BIT_FALSE
-ENABLE_BFD_64_BIT_TRUE
-PLUGINS_FALSE
-PLUGINS_TRUE
-LARGEFILE_CPPFLAGS
-OTOOL64
-OTOOL
-LIPO
-NMEDIT
-DSYMUTIL
-OBJDUMP
-LN_S
-NM
-ac_ct_DUMPBIN
-DUMPBIN
-LD
-FGREP
-SED
-LIBTOOL
-EGREP
-GREP
-CPP
-am__fastdepCC_FALSE
-am__fastdepCC_TRUE
-CCDEPMODE
-am__nodep
-AMDEPBACKSLASH
-AMDEP_FALSE
-AMDEP_TRUE
-am__quote
-am__include
-DEPDIR
-OBJEXT
-EXEEXT
-ac_ct_CC
-CPPFLAGS
-LDFLAGS
-CFLAGS
-CC
-RANLIB
-AR
-AM_BACKSLASH
-AM_DEFAULT_VERBOSITY
-AM_DEFAULT_V
-AM_V
-am__untar
-am__tar
-AMTAR
-am__leading_dot
-SET_MAKE
-AWK
-mkdir_p
-MKDIR_P
-INSTALL_STRIP_PROGRAM
-STRIP
-install_sh
-MAKEINFO
-AUTOHEADER
-AUTOMAKE
-AUTOCONF
-ACLOCAL
-VERSION
-PACKAGE
-CYGPATH_W
-am__isrc
-INSTALL_DATA
-INSTALL_SCRIPT
-INSTALL_PROGRAM
-target_os
-target_vendor
-target_cpu
-target
-host_os
-host_vendor
-host_cpu
-host
-build_os
-build_vendor
-build_cpu
-build
-target_alias
-host_alias
-build_alias
-LIBS
-ECHO_T
-ECHO_N
-ECHO_C
-DEFS
-mandir
-localedir
-libdir
-psdir
-pdfdir
-dvidir
-htmldir
-infodir
-docdir
-oldincludedir
-includedir
-localstatedir
-sharedstatedir
-sysconfdir
-datadir
-datarootdir
-libexecdir
-sbindir
-bindir
-program_transform_name
-prefix
-exec_prefix
-PACKAGE_URL
-PACKAGE_BUGREPORT
-PACKAGE_STRING
-PACKAGE_VERSION
-PACKAGE_TARNAME
-PACKAGE_NAME
-PATH_SEPARATOR
-SHELL'
-ac_subst_files=''
-ac_user_opts='
-enable_option_checking
-enable_silent_rules
-enable_shared
-enable_dependency_tracking
-enable_static
-with_pic
-enable_fast_install
-with_gnu_ld
-enable_libtool_lock
-enable_plugins
-enable_largefile
-enable_checking
-enable_64_bit_bfd
-enable_targets
-enable_64_bit_archive
-with_mmap
-enable_secureplt
-enable_separate_code
-enable_leading_mingw64_underscores
-with_separate_debug_dir
-with_pkgversion
-with_bugurl
-enable_werror
-enable_build_warnings
-enable_maintainer_mode
-enable_install_libbfd
-enable_nls
-enable_rpath
-with_libiconv_prefix
-with_libiconv_type
-with_libintl_prefix
-with_libintl_type
-with_system_zlib
-with_zstd
-'
- ac_precious_vars='build_alias
-host_alias
-target_alias
-CC
-CFLAGS
-LDFLAGS
-LIBS
-CPPFLAGS
-CPP
-PKG_CONFIG
-PKG_CONFIG_PATH
-PKG_CONFIG_LIBDIR
-ZSTD_CFLAGS
-ZSTD_LIBS'
-
-
-# Initialize some variables set by options.
-ac_init_help=
-ac_init_version=false
-ac_unrecognized_opts=
-ac_unrecognized_sep=
-# The variables have the same names as the options, with
-# dashes changed to underlines.
-cache_file=/dev/null
-exec_prefix=NONE
-no_create=
-no_recursion=
-prefix=NONE
-program_prefix=NONE
-program_suffix=NONE
-program_transform_name=s,x,x,
-silent=
-site=
-srcdir=
-verbose=
-x_includes=NONE
-x_libraries=NONE
-
-# Installation directory options.
-# These are left unexpanded so users can "make install exec_prefix=/foo"
-# and all the variables that are supposed to be based on exec_prefix
-# by default will actually change.
-# Use braces instead of parens because sh, perl, etc. also accept them.
-# (The list follows the same order as the GNU Coding Standards.)
-bindir='${exec_prefix}/bin'
-sbindir='${exec_prefix}/sbin'
-libexecdir='${exec_prefix}/libexec'
-datarootdir='${prefix}/share'
-datadir='${datarootdir}'
-sysconfdir='${prefix}/etc'
-sharedstatedir='${prefix}/com'
-localstatedir='${prefix}/var'
-includedir='${prefix}/include'
-oldincludedir='/usr/include'
-docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
-infodir='${datarootdir}/info'
-htmldir='${docdir}'
-dvidir='${docdir}'
-pdfdir='${docdir}'
-psdir='${docdir}'
-libdir='${exec_prefix}/lib'
-localedir='${datarootdir}/locale'
-mandir='${datarootdir}/man'
-
-ac_prev=
-ac_dashdash=
-for ac_option
-do
- # If the previous option needs an argument, assign it.
- if test -n "$ac_prev"; then
- eval $ac_prev=\$ac_option
- ac_prev=
- continue
- fi
-
- case $ac_option in
- *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
- *=) ac_optarg= ;;
- *) ac_optarg=yes ;;
- esac
-
- # Accept the important Cygnus configure options, so we can diagnose typos.
-
- case $ac_dashdash$ac_option in
- --)
- ac_dashdash=yes ;;
-
- -bindir | --bindir | --bindi | --bind | --bin | --bi)
- ac_prev=bindir ;;
- -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
- bindir=$ac_optarg ;;
-
- -build | --build | --buil | --bui | --bu)
- ac_prev=build_alias ;;
- -build=* | --build=* | --buil=* | --bui=* | --bu=*)
- build_alias=$ac_optarg ;;
-
- -cache-file | --cache-file | --cache-fil | --cache-fi \
- | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
- ac_prev=cache_file ;;
- -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
- | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
- cache_file=$ac_optarg ;;
-
- --config-cache | -C)
- cache_file=config.cache ;;
-
- -datadir | --datadir | --datadi | --datad)
- ac_prev=datadir ;;
- -datadir=* | --datadir=* | --datadi=* | --datad=*)
- datadir=$ac_optarg ;;
-
- -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
- | --dataroo | --dataro | --datar)
- ac_prev=datarootdir ;;
- -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
- | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
- datarootdir=$ac_optarg ;;
-
- -disable-* | --disable-*)
- ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
- # Reject names that are not valid shell variable names.
- expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
- as_fn_error $? "invalid feature name: $ac_useropt"
- ac_useropt_orig=$ac_useropt
- ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
- case $ac_user_opts in
- *"
-"enable_$ac_useropt"
-"*) ;;
- *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
- ac_unrecognized_sep=', ';;
- esac
- eval enable_$ac_useropt=no ;;
-
- -docdir | --docdir | --docdi | --doc | --do)
- ac_prev=docdir ;;
- -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
- docdir=$ac_optarg ;;
-
- -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
- ac_prev=dvidir ;;
- -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
- dvidir=$ac_optarg ;;
-
- -enable-* | --enable-*)
- ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
- # Reject names that are not valid shell variable names.
- expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
- as_fn_error $? "invalid feature name: $ac_useropt"
- ac_useropt_orig=$ac_useropt
- ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
- case $ac_user_opts in
- *"
-"enable_$ac_useropt"
-"*) ;;
- *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
- ac_unrecognized_sep=', ';;
- esac
- eval enable_$ac_useropt=\$ac_optarg ;;
-
- -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
- | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
- | --exec | --exe | --ex)
- ac_prev=exec_prefix ;;
- -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
- | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
- | --exec=* | --exe=* | --ex=*)
- exec_prefix=$ac_optarg ;;
-
- -gas | --gas | --ga | --g)
- # Obsolete; use --with-gas.
- with_gas=yes ;;
-
- -help | --help | --hel | --he | -h)
- ac_init_help=long ;;
- -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
- ac_init_help=recursive ;;
- -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
- ac_init_help=short ;;
-
- -host | --host | --hos | --ho)
- ac_prev=host_alias ;;
- -host=* | --host=* | --hos=* | --ho=*)
- host_alias=$ac_optarg ;;
-
- -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
- ac_prev=htmldir ;;
- -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
- | --ht=*)
- htmldir=$ac_optarg ;;
-
- -includedir | --includedir | --includedi | --included | --include \
- | --includ | --inclu | --incl | --inc)
- ac_prev=includedir ;;
- -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
- | --includ=* | --inclu=* | --incl=* | --inc=*)
- includedir=$ac_optarg ;;
-
- -infodir | --infodir | --infodi | --infod | --info | --inf)
- ac_prev=infodir ;;
- -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
- infodir=$ac_optarg ;;
-
- -libdir | --libdir | --libdi | --libd)
- ac_prev=libdir ;;
- -libdir=* | --libdir=* | --libdi=* | --libd=*)
- libdir=$ac_optarg ;;
-
- -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
- | --libexe | --libex | --libe)
- ac_prev=libexecdir ;;
- -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
- | --libexe=* | --libex=* | --libe=*)
- libexecdir=$ac_optarg ;;
-
- -localedir | --localedir | --localedi | --localed | --locale)
- ac_prev=localedir ;;
- -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
- localedir=$ac_optarg ;;
-
- -localstatedir | --localstatedir | --localstatedi | --localstated \
- | --localstate | --localstat | --localsta | --localst | --locals)
- ac_prev=localstatedir ;;
- -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
- | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
- localstatedir=$ac_optarg ;;
-
- -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
- ac_prev=mandir ;;
- -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
- mandir=$ac_optarg ;;
-
- -nfp | --nfp | --nf)
- # Obsolete; use --without-fp.
- with_fp=no ;;
-
- -no-create | --no-create | --no-creat | --no-crea | --no-cre \
- | --no-cr | --no-c | -n)
- no_create=yes ;;
-
- -no-recursion | --no-recursion | --no-recursio | --no-recursi \
- | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
- no_recursion=yes ;;
-
- -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
- | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
- | --oldin | --oldi | --old | --ol | --o)
- ac_prev=oldincludedir ;;
- -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
- | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
- | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
- oldincludedir=$ac_optarg ;;
-
- -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
- ac_prev=prefix ;;
- -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
- prefix=$ac_optarg ;;
-
- -program-prefix | --program-prefix | --program-prefi | --program-pref \
- | --program-pre | --program-pr | --program-p)
- ac_prev=program_prefix ;;
- -program-prefix=* | --program-prefix=* | --program-prefi=* \
- | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
- program_prefix=$ac_optarg ;;
-
- -program-suffix | --program-suffix | --program-suffi | --program-suff \
- | --program-suf | --program-su | --program-s)
- ac_prev=program_suffix ;;
- -program-suffix=* | --program-suffix=* | --program-suffi=* \
- | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
- program_suffix=$ac_optarg ;;
-
- -program-transform-name | --program-transform-name \
- | --program-transform-nam | --program-transform-na \
- | --program-transform-n | --program-transform- \
- | --program-transform | --program-transfor \
- | --program-transfo | --program-transf \
- | --program-trans | --program-tran \
- | --progr-tra | --program-tr | --program-t)
- ac_prev=program_transform_name ;;
- -program-transform-name=* | --program-transform-name=* \
- | --program-transform-nam=* | --program-transform-na=* \
- | --program-transform-n=* | --program-transform-=* \
- | --program-transform=* | --program-transfor=* \
- | --program-transfo=* | --program-transf=* \
- | --program-trans=* | --program-tran=* \
- | --progr-tra=* | --program-tr=* | --program-t=*)
- program_transform_name=$ac_optarg ;;
-
- -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
- ac_prev=pdfdir ;;
- -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
- pdfdir=$ac_optarg ;;
-
- -psdir | --psdir | --psdi | --psd | --ps)
- ac_prev=psdir ;;
- -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
- psdir=$ac_optarg ;;
-
- -q | -quiet | --quiet | --quie | --qui | --qu | --q \
- | -silent | --silent | --silen | --sile | --sil)
- silent=yes ;;
-
- -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
- ac_prev=sbindir ;;
- -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
- | --sbi=* | --sb=*)
- sbindir=$ac_optarg ;;
-
- -sharedstatedir | --sharedstatedir | --sharedstatedi \
- | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
- | --sharedst | --shareds | --shared | --share | --shar \
- | --sha | --sh)
- ac_prev=sharedstatedir ;;
- -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
- | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
- | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
- | --sha=* | --sh=*)
- sharedstatedir=$ac_optarg ;;
-
- -site | --site | --sit)
- ac_prev=site ;;
- -site=* | --site=* | --sit=*)
- site=$ac_optarg ;;
-
- -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
- ac_prev=srcdir ;;
- -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
- srcdir=$ac_optarg ;;
-
- -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
- | --syscon | --sysco | --sysc | --sys | --sy)
- ac_prev=sysconfdir ;;
- -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
- | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
- sysconfdir=$ac_optarg ;;
-
- -target | --target | --targe | --targ | --tar | --ta | --t)
- ac_prev=target_alias ;;
- -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
- target_alias=$ac_optarg ;;
-
- -v | -verbose | --verbose | --verbos | --verbo | --verb)
- verbose=yes ;;
-
- -version | --version | --versio | --versi | --vers | -V)
- ac_init_version=: ;;
-
- -with-* | --with-*)
- ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
- # Reject names that are not valid shell variable names.
- expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
- as_fn_error $? "invalid package name: $ac_useropt"
- ac_useropt_orig=$ac_useropt
- ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
- case $ac_user_opts in
- *"
-"with_$ac_useropt"
-"*) ;;
- *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
- ac_unrecognized_sep=', ';;
- esac
- eval with_$ac_useropt=\$ac_optarg ;;
-
- -without-* | --without-*)
- ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
- # Reject names that are not valid shell variable names.
- expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
- as_fn_error $? "invalid package name: $ac_useropt"
- ac_useropt_orig=$ac_useropt
- ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
- case $ac_user_opts in
- *"
-"with_$ac_useropt"
-"*) ;;
- *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
- ac_unrecognized_sep=', ';;
- esac
- eval with_$ac_useropt=no ;;
-
- --x)
- # Obsolete; use --with-x.
- with_x=yes ;;
-
- -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
- | --x-incl | --x-inc | --x-in | --x-i)
- ac_prev=x_includes ;;
- -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
- | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
- x_includes=$ac_optarg ;;
-
- -x-libraries | --x-libraries | --x-librarie | --x-librari \
- | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
- ac_prev=x_libraries ;;
- -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
- | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
- x_libraries=$ac_optarg ;;
-
- -*) as_fn_error $? "unrecognized option: \`$ac_option'
-Try \`$0 --help' for more information"
- ;;
-
- *=*)
- ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
- # Reject names that are not valid shell variable names.
- case $ac_envvar in #(
- '' | [0-9]* | *[!_$as_cr_alnum]* )
- as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
- esac
- eval $ac_envvar=\$ac_optarg
- export $ac_envvar ;;
-
- *)
- # FIXME: should be removed in autoconf 3.0.
- $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
- expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
- $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
- : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
- ;;
-
- esac
-done
-
-if test -n "$ac_prev"; then
- ac_option=--`echo $ac_prev | sed 's/_/-/g'`
- as_fn_error $? "missing argument to $ac_option"
-fi
-
-if test -n "$ac_unrecognized_opts"; then
- case $enable_option_checking in
- no) ;;
- fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
- *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
- esac
-fi
-
-# Check all directory arguments for consistency.
-for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
- datadir sysconfdir sharedstatedir localstatedir includedir \
- oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
- libdir localedir mandir
-do
- eval ac_val=\$$ac_var
- # Remove trailing slashes.
- case $ac_val in
- */ )
- ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
- eval $ac_var=\$ac_val;;
- esac
- # Be sure to have absolute directory names.
- case $ac_val in
- [\\/$]* | ?:[\\/]* ) continue;;
- NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
- esac
- as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
-done
-
-# There might be people who depend on the old broken behavior: `$host'
-# used to hold the argument of --host etc.
-# FIXME: To remove some day.
-build=$build_alias
-host=$host_alias
-target=$target_alias
-
-# FIXME: To remove some day.
-if test "x$host_alias" != x; then
- if test "x$build_alias" = x; then
- cross_compiling=maybe
- elif test "x$build_alias" != "x$host_alias"; then
- cross_compiling=yes
- fi
-fi
-
-ac_tool_prefix=
-test -n "$host_alias" && ac_tool_prefix=$host_alias-
-
-test "$silent" = yes && exec 6>/dev/null
-
-
-ac_pwd=`pwd` && test -n "$ac_pwd" &&
-ac_ls_di=`ls -di .` &&
-ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
- as_fn_error $? "working directory cannot be determined"
-test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
- as_fn_error $? "pwd does not report name of working directory"
-
-
-# Find the source files, if location was not specified.
-if test -z "$srcdir"; then
- ac_srcdir_defaulted=yes
- # Try the directory containing this script, then the parent directory.
- ac_confdir=`$as_dirname -- "$as_myself" ||
-$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$as_myself" : 'X\(//\)[^/]' \| \
- X"$as_myself" : 'X\(//\)$' \| \
- X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$as_myself" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
- srcdir=$ac_confdir
- if test ! -r "$srcdir/$ac_unique_file"; then
- srcdir=..
- fi
-else
- ac_srcdir_defaulted=no
-fi
-if test ! -r "$srcdir/$ac_unique_file"; then
- test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
- as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
-fi
-ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
-ac_abs_confdir=`(
- cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
- pwd)`
-# When building in place, set srcdir=.
-if test "$ac_abs_confdir" = "$ac_pwd"; then
- srcdir=.
-fi
-# Remove unnecessary trailing slashes from srcdir.
-# Double slashes in file names in object file debugging info
-# mess up M-x gdb in Emacs.
-case $srcdir in
-*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
-esac
-for ac_var in $ac_precious_vars; do
- eval ac_env_${ac_var}_set=\${${ac_var}+set}
- eval ac_env_${ac_var}_value=\$${ac_var}
- eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
- eval ac_cv_env_${ac_var}_value=\$${ac_var}
-done
-
-#
-# Report the --help message.
-#
-if test "$ac_init_help" = "long"; then
- # Omit some internal or obsolete options to make the list less imposing.
- # This message is too long to be a string in the A/UX 3.1 sh.
- cat <<_ACEOF
-\`configure' configures bfd 2.43.1 to adapt to many kinds of systems.
-
-Usage: $0 [OPTION]... [VAR=VALUE]...
-
-To assign environment variables (e.g., CC, CFLAGS...), specify them as
-VAR=VALUE. See below for descriptions of some of the useful variables.
-
-Defaults for the options are specified in brackets.
-
-Configuration:
- -h, --help display this help and exit
- --help=short display options specific to this package
- --help=recursive display the short help of all the included packages
- -V, --version display version information and exit
- -q, --quiet, --silent do not print \`checking ...' messages
- --cache-file=FILE cache test results in FILE [disabled]
- -C, --config-cache alias for \`--cache-file=config.cache'
- -n, --no-create do not create output files
- --srcdir=DIR find the sources in DIR [configure dir or \`..']
-
-Installation directories:
- --prefix=PREFIX install architecture-independent files in PREFIX
- [$ac_default_prefix]
- --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
- [PREFIX]
-
-By default, \`make install' will install all the files in
-\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
-an installation prefix other than \`$ac_default_prefix' using \`--prefix',
-for instance \`--prefix=\$HOME'.
-
-For better control, use the options below.
-
-Fine tuning of the installation directories:
- --bindir=DIR user executables [EPREFIX/bin]
- --sbindir=DIR system admin executables [EPREFIX/sbin]
- --libexecdir=DIR program executables [EPREFIX/libexec]
- --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
- --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
- --localstatedir=DIR modifiable single-machine data [PREFIX/var]
- --libdir=DIR object code libraries [EPREFIX/lib]
- --includedir=DIR C header files [PREFIX/include]
- --oldincludedir=DIR C header files for non-gcc [/usr/include]
- --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
- --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
- --infodir=DIR info documentation [DATAROOTDIR/info]
- --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
- --mandir=DIR man documentation [DATAROOTDIR/man]
- --docdir=DIR documentation root [DATAROOTDIR/doc/bfd]
- --htmldir=DIR html documentation [DOCDIR]
- --dvidir=DIR dvi documentation [DOCDIR]
- --pdfdir=DIR pdf documentation [DOCDIR]
- --psdir=DIR ps documentation [DOCDIR]
-_ACEOF
-
- cat <<\_ACEOF
-
-Program names:
- --program-prefix=PREFIX prepend PREFIX to installed program names
- --program-suffix=SUFFIX append SUFFIX to installed program names
- --program-transform-name=PROGRAM run sed PROGRAM on installed program names
-
-System types:
- --build=BUILD configure for building on BUILD [guessed]
- --host=HOST cross-compile to build programs to run on HOST [BUILD]
- --target=TARGET configure for building compilers for TARGET [HOST]
-_ACEOF
-fi
-
-if test -n "$ac_init_help"; then
- case $ac_init_help in
- short | recursive ) echo "Configuration of bfd 2.43.1:";;
- esac
- cat <<\_ACEOF
-
-Optional Features:
- --disable-option-checking ignore unrecognized --enable/--with options
- --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
- --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
- --enable-silent-rules less verbose build output (undo: "make V=1")
- --disable-silent-rules verbose build output (undo: "make V=0")
- --enable-shared[=PKGS] build shared libraries [default=no]
- --enable-dependency-tracking
- do not reject slow dependency extractors
- --disable-dependency-tracking
- speeds up one-time build
- --enable-static[=PKGS] build static libraries [default=yes]
- --enable-fast-install[=PKGS]
- optimize for fast installation [default=yes]
- --disable-libtool-lock avoid locking (might break parallel builds)
- --enable-plugins Enable support for plugins
- --disable-largefile omit support for large files
- --enable-checking enable run-time checks
- --enable-64-bit-bfd 64-bit support (on hosts with narrower word sizes)
- --enable-targets alternative target configurations
- --enable-64-bit-archive force 64-bit archives
- --enable-secureplt Default to creating read-only plt entries
- --enable-separate-code enable -z separate-code in ELF linker by default
- --enable-leading-mingw64-underscores
- Enable leading underscores on 64 bit mingw targets
- --enable-werror treat compile warnings as errors
- --enable-build-warnings enable build-time compiler warnings
- --enable-maintainer-mode
- enable make rules and dependencies not useful (and
- sometimes confusing) to the casual installer
- --enable-install-libbfd controls installation of libbfd and related headers
- --disable-nls do not use Native Language Support
- --disable-rpath do not hardcode runtime library paths
-
-Optional Packages:
- --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
- --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
- --with-pic try to use only PIC/non-PIC objects [default=use
- both]
- --with-gnu-ld assume the C compiler uses GNU ld [default=no]
- --with-mmap try using mmap for BFD input files if available
- --with-separate-debug-dir=DIR
- Look for global separate debug info in DIR
- [[default=LIBDIR/debug]]
- --with-pkgversion=PKG Use PKG in the version string in place of "GNU
- Binutils"
- --with-bugurl=URL Direct users to URL to report a bug
- --with-gnu-ld assume the C compiler uses GNU ld default=no
- --with-libiconv-prefix[=DIR] search for libiconv in DIR/include and DIR/lib
- --without-libiconv-prefix don't search for libiconv in includedir and libdir
- --with-libiconv-type=TYPE type of library to search for (auto/static/shared)
- --with-libintl-prefix[=DIR] search for libintl in DIR/include and DIR/lib
- --without-libintl-prefix don't search for libintl in includedir and libdir
- --with-libintl-type=TYPE type of library to search for (auto/static/shared)
- --with-system-zlib use installed libz
- --with-zstd support zstd compressed debug sections
- (default=auto)
-
-Some influential environment variables:
- CC C compiler command
- CFLAGS C compiler flags
- LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
- nonstandard directory <lib dir>
- LIBS libraries to pass to the linker, e.g. -l<library>
- CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
- you have headers in a nonstandard directory <include dir>
- CPP C preprocessor
- PKG_CONFIG path to pkg-config utility
- PKG_CONFIG_PATH
- directories to add to pkg-config's search path
- PKG_CONFIG_LIBDIR
- path overriding pkg-config's built-in search path
- ZSTD_CFLAGS C compiler flags for ZSTD, overriding pkg-config
- ZSTD_LIBS linker flags for ZSTD, overriding pkg-config
-
-Use these variables to override the choices made by `configure' or to help
-it to find libraries and programs with nonstandard names/locations.
-
-Report bugs to the package provider.
-_ACEOF
-ac_status=$?
-fi
-
-if test "$ac_init_help" = "recursive"; then
- # If there are subdirs, report their specific --help.
- for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
- test -d "$ac_dir" ||
- { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
- continue
- ac_builddir=.
-
-case "$ac_dir" in
-.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
-*)
- ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
- # A ".." for each directory in $ac_dir_suffix.
- ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
- case $ac_top_builddir_sub in
- "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
- *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
- esac ;;
-esac
-ac_abs_top_builddir=$ac_pwd
-ac_abs_builddir=$ac_pwd$ac_dir_suffix
-# for backward compatibility:
-ac_top_builddir=$ac_top_build_prefix
-
-case $srcdir in
- .) # We are building in place.
- ac_srcdir=.
- ac_top_srcdir=$ac_top_builddir_sub
- ac_abs_top_srcdir=$ac_pwd ;;
- [\\/]* | ?:[\\/]* ) # Absolute name.
- ac_srcdir=$srcdir$ac_dir_suffix;
- ac_top_srcdir=$srcdir
- ac_abs_top_srcdir=$srcdir ;;
- *) # Relative name.
- ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
- ac_top_srcdir=$ac_top_build_prefix$srcdir
- ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
-esac
-ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
-
- cd "$ac_dir" || { ac_status=$?; continue; }
- # Check for guested configure.
- if test -f "$ac_srcdir/configure.gnu"; then
- echo &&
- $SHELL "$ac_srcdir/configure.gnu" --help=recursive
- elif test -f "$ac_srcdir/configure"; then
- echo &&
- $SHELL "$ac_srcdir/configure" --help=recursive
- else
- $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
- fi || ac_status=$?
- cd "$ac_pwd" || { ac_status=$?; break; }
- done
-fi
-
-test -n "$ac_init_help" && exit $ac_status
-if $ac_init_version; then
- cat <<\_ACEOF
-bfd configure 2.43.1
-generated by GNU Autoconf 2.69
-
-Copyright (C) 2012 Free Software Foundation, Inc.
-This configure script is free software; the Free Software Foundation
-gives unlimited permission to copy, distribute and modify it.
-_ACEOF
- exit
-fi
-
-## ------------------------ ##
-## Autoconf initialization. ##
-## ------------------------ ##
-
-# ac_fn_c_try_compile LINENO
-# --------------------------
-# Try to compile conftest.$ac_ext, and return whether this succeeded.
-ac_fn_c_try_compile ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- rm -f conftest.$ac_objext
- if { { ac_try="$ac_compile"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_compile") 2>conftest.err
- ac_status=$?
- if test -s conftest.err; then
- grep -v '^ *+' conftest.err >conftest.er1
- cat conftest.er1 >&5
- mv -f conftest.er1 conftest.err
- fi
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && {
- test -z "$ac_c_werror_flag" ||
- test ! -s conftest.err
- } && test -s conftest.$ac_objext; then :
- ac_retval=0
-else
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
- ac_retval=1
-fi
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
- as_fn_set_status $ac_retval
-
-} # ac_fn_c_try_compile
-
-# ac_fn_c_try_cpp LINENO
-# ----------------------
-# Try to preprocess conftest.$ac_ext, and return whether this succeeded.
-ac_fn_c_try_cpp ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- if { { ac_try="$ac_cpp conftest.$ac_ext"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
- ac_status=$?
- if test -s conftest.err; then
- grep -v '^ *+' conftest.err >conftest.er1
- cat conftest.er1 >&5
- mv -f conftest.er1 conftest.err
- fi
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } > conftest.i && {
- test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
- test ! -s conftest.err
- }; then :
- ac_retval=0
-else
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
- ac_retval=1
-fi
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
- as_fn_set_status $ac_retval
-
-} # ac_fn_c_try_cpp
-
-# ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
-# -------------------------------------------------------
-# Tests whether HEADER exists, giving a warning if it cannot be compiled using
-# the include files in INCLUDES and setting the cache variable VAR
-# accordingly.
-ac_fn_c_check_header_mongrel ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- if eval \${$3+:} false; then :
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
-$as_echo_n "checking for $2... " >&6; }
-if eval \${$3+:} false; then :
- $as_echo_n "(cached) " >&6
-fi
-eval ac_res=\$$3
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
-else
- # Is the header compilable?
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
-$as_echo_n "checking $2 usability... " >&6; }
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$4
-#include <$2>
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_header_compiler=yes
-else
- ac_header_compiler=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
-$as_echo "$ac_header_compiler" >&6; }
-
-# Is the header present?
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
-$as_echo_n "checking $2 presence... " >&6; }
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <$2>
-_ACEOF
-if ac_fn_c_try_cpp "$LINENO"; then :
- ac_header_preproc=yes
-else
- ac_header_preproc=no
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
-$as_echo "$ac_header_preproc" >&6; }
-
-# So? What about this header?
-case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
- yes:no: )
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
-$as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
-$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
- ;;
- no:yes:* )
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
-$as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
-$as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
-$as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
-$as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
-$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
- ;;
-esac
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
-$as_echo_n "checking for $2... " >&6; }
-if eval \${$3+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- eval "$3=\$ac_header_compiler"
-fi
-eval ac_res=\$$3
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
-fi
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
-
-} # ac_fn_c_check_header_mongrel
-
-# ac_fn_c_try_run LINENO
-# ----------------------
-# Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
-# that executables *can* be run.
-ac_fn_c_try_run ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- if { { ac_try="$ac_link"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_link") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
- { { case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_try") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; }; then :
- ac_retval=0
-else
- $as_echo "$as_me: program exited with status $ac_status" >&5
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
- ac_retval=$ac_status
-fi
- rm -rf conftest.dSYM conftest_ipa8_conftest.oo
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
- as_fn_set_status $ac_retval
-
-} # ac_fn_c_try_run
-
-# ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
-# -------------------------------------------------------
-# Tests whether HEADER exists and can be compiled using the include files in
-# INCLUDES, setting the cache variable VAR accordingly.
-ac_fn_c_check_header_compile ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
-$as_echo_n "checking for $2... " >&6; }
-if eval \${$3+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$4
-#include <$2>
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- eval "$3=yes"
-else
- eval "$3=no"
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-eval ac_res=\$$3
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
-
-} # ac_fn_c_check_header_compile
-
-# ac_fn_c_try_link LINENO
-# -----------------------
-# Try to link conftest.$ac_ext, and return whether this succeeded.
-ac_fn_c_try_link ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- rm -f conftest.$ac_objext conftest$ac_exeext
- if { { ac_try="$ac_link"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_link") 2>conftest.err
- ac_status=$?
- if test -s conftest.err; then
- grep -v '^ *+' conftest.err >conftest.er1
- cat conftest.er1 >&5
- mv -f conftest.er1 conftest.err
- fi
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && {
- test -z "$ac_c_werror_flag" ||
- test ! -s conftest.err
- } && test -s conftest$ac_exeext && {
- test "$cross_compiling" = yes ||
- test -x conftest$ac_exeext
- }; then :
- ac_retval=0
-else
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
- ac_retval=1
-fi
- # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
- # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
- # interfere with the next link command; also delete a directory that is
- # left behind by Apple's compiler. We do this before executing the actions.
- rm -rf conftest.dSYM conftest_ipa8_conftest.oo
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
- as_fn_set_status $ac_retval
-
-} # ac_fn_c_try_link
-
-# ac_fn_c_check_func LINENO FUNC VAR
-# ----------------------------------
-# Tests whether FUNC exists, setting the cache variable VAR accordingly
-ac_fn_c_check_func ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
-$as_echo_n "checking for $2... " >&6; }
-if eval \${$3+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-/* Define $2 to an innocuous variant, in case <limits.h> declares $2.
- For example, HP-UX 11i <limits.h> declares gettimeofday. */
-#define $2 innocuous_$2
-
-/* System header to define __stub macros and hopefully few prototypes,
- which can conflict with char $2 (); below.
- Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
- <limits.h> exists even on freestanding compilers. */
-
-#ifdef __STDC__
-# include <limits.h>
-#else
-# include <assert.h>
-#endif
-
-#undef $2
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char $2 ();
-/* The GNU C library defines this for functions which it implements
- to always fail with ENOSYS. Some functions are actually named
- something starting with __ and the normal name is an alias. */
-#if defined __stub_$2 || defined __stub___$2
-choke me
-#endif
-
-int
-main ()
-{
-return $2 ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- eval "$3=yes"
-else
- eval "$3=no"
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-fi
-eval ac_res=\$$3
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
-
-} # ac_fn_c_check_func
-
-# ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
-# --------------------------------------------
-# Tries to find the compile-time value of EXPR in a program that includes
-# INCLUDES, setting VAR accordingly. Returns whether the value could be
-# computed
-ac_fn_c_compute_int ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- if test "$cross_compiling" = yes; then
- # Depending upon the size, compute the lo and hi bounds.
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$4
-int
-main ()
-{
-static int test_array [1 - 2 * !(($2) >= 0)];
-test_array [0] = 0;
-return test_array [0];
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_lo=0 ac_mid=0
- while :; do
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$4
-int
-main ()
-{
-static int test_array [1 - 2 * !(($2) <= $ac_mid)];
-test_array [0] = 0;
-return test_array [0];
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_hi=$ac_mid; break
-else
- as_fn_arith $ac_mid + 1 && ac_lo=$as_val
- if test $ac_lo -le $ac_mid; then
- ac_lo= ac_hi=
- break
- fi
- as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- done
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$4
-int
-main ()
-{
-static int test_array [1 - 2 * !(($2) < 0)];
-test_array [0] = 0;
-return test_array [0];
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_hi=-1 ac_mid=-1
- while :; do
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$4
-int
-main ()
-{
-static int test_array [1 - 2 * !(($2) >= $ac_mid)];
-test_array [0] = 0;
-return test_array [0];
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_lo=$ac_mid; break
-else
- as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
- if test $ac_mid -le $ac_hi; then
- ac_lo= ac_hi=
- break
- fi
- as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- done
-else
- ac_lo= ac_hi=
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-# Binary search between lo and hi bounds.
-while test "x$ac_lo" != "x$ac_hi"; do
- as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$4
-int
-main ()
-{
-static int test_array [1 - 2 * !(($2) <= $ac_mid)];
-test_array [0] = 0;
-return test_array [0];
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_hi=$ac_mid
-else
- as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-done
-case $ac_lo in #((
-?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
-'') ac_retval=1 ;;
-esac
- else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$4
-static long int longval () { return $2; }
-static unsigned long int ulongval () { return $2; }
-#include <stdio.h>
-#include <stdlib.h>
-int
-main ()
-{
-
- FILE *f = fopen ("conftest.val", "w");
- if (! f)
- return 1;
- if (($2) < 0)
- {
- long int i = longval ();
- if (i != ($2))
- return 1;
- fprintf (f, "%ld", i);
- }
- else
- {
- unsigned long int i = ulongval ();
- if (i != ($2))
- return 1;
- fprintf (f, "%lu", i);
- }
- /* Do not output a trailing newline, as this causes \r\n confusion
- on some platforms. */
- return ferror (f) || fclose (f) != 0;
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_run "$LINENO"; then :
- echo >>conftest.val; read $3 <conftest.val; ac_retval=0
-else
- ac_retval=1
-fi
-rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
- conftest.$ac_objext conftest.beam conftest.$ac_ext
-rm -f conftest.val
-
- fi
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
- as_fn_set_status $ac_retval
-
-} # ac_fn_c_compute_int
-
-# ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES
-# ---------------------------------------------
-# Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR
-# accordingly.
-ac_fn_c_check_decl ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- as_decl_name=`echo $2|sed 's/ *(.*//'`
- as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'`
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5
-$as_echo_n "checking whether $as_decl_name is declared... " >&6; }
-if eval \${$3+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$4
-int
-main ()
-{
-#ifndef $as_decl_name
-#ifdef __cplusplus
- (void) $as_decl_use;
-#else
- (void) $as_decl_name;
-#endif
-#endif
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- eval "$3=yes"
-else
- eval "$3=no"
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-eval ac_res=\$$3
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
-
-} # ac_fn_c_check_decl
-cat >config.log <<_ACEOF
-This file contains any messages produced by compilers while
-running configure, to aid debugging if configure makes a mistake.
-
-It was created by bfd $as_me 2.43.1, which was
-generated by GNU Autoconf 2.69. Invocation command line was
-
- $ $0 $@
-
-_ACEOF
-exec 5>>config.log
-{
-cat <<_ASUNAME
-## --------- ##
-## Platform. ##
-## --------- ##
-
-hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
-uname -m = `(uname -m) 2>/dev/null || echo unknown`
-uname -r = `(uname -r) 2>/dev/null || echo unknown`
-uname -s = `(uname -s) 2>/dev/null || echo unknown`
-uname -v = `(uname -v) 2>/dev/null || echo unknown`
-
-/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
-/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
-
-/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
-/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
-/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
-/usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
-/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
-/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
-/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
-
-_ASUNAME
-
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- $as_echo "PATH: $as_dir"
- done
-IFS=$as_save_IFS
-
-} >&5
-
-cat >&5 <<_ACEOF
-
-
-## ----------- ##
-## Core tests. ##
-## ----------- ##
-
-_ACEOF
-
-
-# Keep a trace of the command line.
-# Strip out --no-create and --no-recursion so they do not pile up.
-# Strip out --silent because we don't want to record it for future runs.
-# Also quote any args containing shell meta-characters.
-# Make two passes to allow for proper duplicate-argument suppression.
-ac_configure_args=
-ac_configure_args0=
-ac_configure_args1=
-ac_must_keep_next=false
-for ac_pass in 1 2
-do
- for ac_arg
- do
- case $ac_arg in
- -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
- -q | -quiet | --quiet | --quie | --qui | --qu | --q \
- | -silent | --silent | --silen | --sile | --sil)
- continue ;;
- *\'*)
- ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
- esac
- case $ac_pass in
- 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
- 2)
- as_fn_append ac_configure_args1 " '$ac_arg'"
- if test $ac_must_keep_next = true; then
- ac_must_keep_next=false # Got value, back to normal.
- else
- case $ac_arg in
- *=* | --config-cache | -C | -disable-* | --disable-* \
- | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
- | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
- | -with-* | --with-* | -without-* | --without-* | --x)
- case "$ac_configure_args0 " in
- "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
- esac
- ;;
- -* ) ac_must_keep_next=true ;;
- esac
- fi
- as_fn_append ac_configure_args " '$ac_arg'"
- ;;
- esac
- done
-done
-{ ac_configure_args0=; unset ac_configure_args0;}
-{ ac_configure_args1=; unset ac_configure_args1;}
-
-# When interrupted or exit'd, cleanup temporary files, and complete
-# config.log. We remove comments because anyway the quotes in there
-# would cause problems or look ugly.
-# WARNING: Use '\'' to represent an apostrophe within the trap.
-# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
-trap 'exit_status=$?
- # Save into config.log some information that might help in debugging.
- {
- echo
-
- $as_echo "## ---------------- ##
-## Cache variables. ##
-## ---------------- ##"
- echo
- # The following way of writing the cache mishandles newlines in values,
-(
- for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
- eval ac_val=\$$ac_var
- case $ac_val in #(
- *${as_nl}*)
- case $ac_var in #(
- *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
-$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
- esac
- case $ac_var in #(
- _ | IFS | as_nl) ;; #(
- BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
- *) { eval $ac_var=; unset $ac_var;} ;;
- esac ;;
- esac
- done
- (set) 2>&1 |
- case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
- *${as_nl}ac_space=\ *)
- sed -n \
- "s/'\''/'\''\\\\'\'''\''/g;
- s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
- ;; #(
- *)
- sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
- ;;
- esac |
- sort
-)
- echo
-
- $as_echo "## ----------------- ##
-## Output variables. ##
-## ----------------- ##"
- echo
- for ac_var in $ac_subst_vars
- do
- eval ac_val=\$$ac_var
- case $ac_val in
- *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
- esac
- $as_echo "$ac_var='\''$ac_val'\''"
- done | sort
- echo
-
- if test -n "$ac_subst_files"; then
- $as_echo "## ------------------- ##
-## File substitutions. ##
-## ------------------- ##"
- echo
- for ac_var in $ac_subst_files
- do
- eval ac_val=\$$ac_var
- case $ac_val in
- *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
- esac
- $as_echo "$ac_var='\''$ac_val'\''"
- done | sort
- echo
- fi
-
- if test -s confdefs.h; then
- $as_echo "## ----------- ##
-## confdefs.h. ##
-## ----------- ##"
- echo
- cat confdefs.h
- echo
- fi
- test "$ac_signal" != 0 &&
- $as_echo "$as_me: caught signal $ac_signal"
- $as_echo "$as_me: exit $exit_status"
- } >&5
- rm -f core *.core core.conftest.* &&
- rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
- exit $exit_status
-' 0
-for ac_signal in 1 2 13 15; do
- trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
-done
-ac_signal=0
-
-# confdefs.h avoids OS command line length limits that DEFS can exceed.
-rm -f -r conftest* confdefs.h
-
-$as_echo "/* confdefs.h */" > confdefs.h
-
-# Predefined preprocessor variables.
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_NAME "$PACKAGE_NAME"
-_ACEOF
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
-_ACEOF
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_VERSION "$PACKAGE_VERSION"
-_ACEOF
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_STRING "$PACKAGE_STRING"
-_ACEOF
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
-_ACEOF
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_URL "$PACKAGE_URL"
-_ACEOF
-
-
-# Let the site file select an alternate cache file if it wants to.
-# Prefer an explicitly selected file to automatically selected ones.
-ac_site_file1=NONE
-ac_site_file2=NONE
-if test -n "$CONFIG_SITE"; then
- # We do not want a PATH search for config.site.
- case $CONFIG_SITE in #((
- -*) ac_site_file1=./$CONFIG_SITE;;
- */*) ac_site_file1=$CONFIG_SITE;;
- *) ac_site_file1=./$CONFIG_SITE;;
- esac
-elif test "x$prefix" != xNONE; then
- ac_site_file1=$prefix/share/config.site
- ac_site_file2=$prefix/etc/config.site
-else
- ac_site_file1=$ac_default_prefix/share/config.site
- ac_site_file2=$ac_default_prefix/etc/config.site
-fi
-for ac_site_file in "$ac_site_file1" "$ac_site_file2"
-do
- test "x$ac_site_file" = xNONE && continue
- if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
-$as_echo "$as_me: loading site script $ac_site_file" >&6;}
- sed 's/^/| /' "$ac_site_file" >&5
- . "$ac_site_file" \
- || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "failed to load site script $ac_site_file
-See \`config.log' for more details" "$LINENO" 5; }
- fi
-done
-
-if test -r "$cache_file"; then
- # Some versions of bash will fail to source /dev/null (special files
- # actually), so we avoid doing that. DJGPP emulates it as a regular file.
- if test /dev/null != "$cache_file" && test -f "$cache_file"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
-$as_echo "$as_me: loading cache $cache_file" >&6;}
- case $cache_file in
- [\\/]* | ?:[\\/]* ) . "$cache_file";;
- *) . "./$cache_file";;
- esac
- fi
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
-$as_echo "$as_me: creating cache $cache_file" >&6;}
- >$cache_file
-fi
-
-gt_needs="$gt_needs "
-as_fn_append ac_header_list " stdlib.h"
-as_fn_append ac_header_list " unistd.h"
-as_fn_append ac_header_list " sys/param.h"
-# Check that the precious variables saved in the cache have kept the same
-# value.
-ac_cache_corrupted=false
-for ac_var in $ac_precious_vars; do
- eval ac_old_set=\$ac_cv_env_${ac_var}_set
- eval ac_new_set=\$ac_env_${ac_var}_set
- eval ac_old_val=\$ac_cv_env_${ac_var}_value
- eval ac_new_val=\$ac_env_${ac_var}_value
- case $ac_old_set,$ac_new_set in
- set,)
- { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
-$as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
- ac_cache_corrupted=: ;;
- ,set)
- { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
-$as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
- ac_cache_corrupted=: ;;
- ,);;
- *)
- if test "x$ac_old_val" != "x$ac_new_val"; then
- # differences in whitespace do not lead to failure.
- ac_old_val_w=`echo x $ac_old_val`
- ac_new_val_w=`echo x $ac_new_val`
- if test "$ac_old_val_w" != "$ac_new_val_w"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
-$as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
- ac_cache_corrupted=:
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
-$as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
- eval $ac_var=\$ac_old_val
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
-$as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
-$as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
- fi;;
- esac
- # Pass precious variables to config.status.
- if test "$ac_new_set" = set; then
- case $ac_new_val in
- *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
- *) ac_arg=$ac_var=$ac_new_val ;;
- esac
- case " $ac_configure_args " in
- *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
- *) as_fn_append ac_configure_args " '$ac_arg'" ;;
- esac
- fi
-done
-if $ac_cache_corrupted; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
-$as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
- as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
-fi
-## -------------------- ##
-## Main body of script. ##
-## -------------------- ##
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-
-
-
-
-
-
-ac_aux_dir=
-for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
- if test -f "$ac_dir/install-sh"; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install-sh -c"
- break
- elif test -f "$ac_dir/install.sh"; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install.sh -c"
- break
- elif test -f "$ac_dir/shtool"; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/shtool install -c"
- break
- fi
-done
-if test -z "$ac_aux_dir"; then
- as_fn_error $? "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5
-fi
-
-# These three variables are undocumented and unsupported,
-# and are intended to be withdrawn in a future Autoconf release.
-# They can cause serious problems if a builder's source tree is in a directory
-# whose full name contains unusual characters.
-ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
-ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
-ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
-
-
-# Make sure we can run config.sub.
-$SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
- as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
-$as_echo_n "checking build system type... " >&6; }
-if ${ac_cv_build+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_build_alias=$build_alias
-test "x$ac_build_alias" = x &&
- ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
-test "x$ac_build_alias" = x &&
- as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
-ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
- as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
-$as_echo "$ac_cv_build" >&6; }
-case $ac_cv_build in
-*-*-*) ;;
-*) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
-esac
-build=$ac_cv_build
-ac_save_IFS=$IFS; IFS='-'
-set x $ac_cv_build
-shift
-build_cpu=$1
-build_vendor=$2
-shift; shift
-# Remember, the first character of IFS is used to create $*,
-# except with old shells:
-build_os=$*
-IFS=$ac_save_IFS
-case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
-$as_echo_n "checking host system type... " >&6; }
-if ${ac_cv_host+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test "x$host_alias" = x; then
- ac_cv_host=$ac_cv_build
-else
- ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
- as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
-$as_echo "$ac_cv_host" >&6; }
-case $ac_cv_host in
-*-*-*) ;;
-*) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
-esac
-host=$ac_cv_host
-ac_save_IFS=$IFS; IFS='-'
-set x $ac_cv_host
-shift
-host_cpu=$1
-host_vendor=$2
-shift; shift
-# Remember, the first character of IFS is used to create $*,
-# except with old shells:
-host_os=$*
-IFS=$ac_save_IFS
-case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking target system type" >&5
-$as_echo_n "checking target system type... " >&6; }
-if ${ac_cv_target+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test "x$target_alias" = x; then
- ac_cv_target=$ac_cv_host
-else
- ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` ||
- as_fn_error $? "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5
-$as_echo "$ac_cv_target" >&6; }
-case $ac_cv_target in
-*-*-*) ;;
-*) as_fn_error $? "invalid value of canonical target" "$LINENO" 5;;
-esac
-target=$ac_cv_target
-ac_save_IFS=$IFS; IFS='-'
-set x $ac_cv_target
-shift
-target_cpu=$1
-target_vendor=$2
-shift; shift
-# Remember, the first character of IFS is used to create $*,
-# except with old shells:
-target_os=$*
-IFS=$ac_save_IFS
-case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac
-
-
-# The aliases save the names the user supplied, while $host etc.
-# will get canonicalized.
-test -n "$target_alias" &&
- test "$program_prefix$program_suffix$program_transform_name" = \
- NONENONEs,x,x, &&
- program_prefix=${target_alias}-
-
-am__api_version='1.15'
-
-# Find a good install program. We prefer a C program (faster),
-# so one script is as good as another. But avoid the broken or
-# incompatible versions:
-# SysV /etc/install, /usr/sbin/install
-# SunOS /usr/etc/install
-# IRIX /sbin/install
-# AIX /bin/install
-# AmigaOS /C/install, which installs bootblocks on floppy discs
-# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
-# AFS /usr/afsws/bin/install, which mishandles nonexistent args
-# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
-# OS/2's system install, which has a completely different semantic
-# ./install, which can be erroneously created by make from ./install.sh.
-# Reject install programs that cannot install multiple files.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
-$as_echo_n "checking for a BSD-compatible install... " >&6; }
-if test -z "$INSTALL"; then
-if ${ac_cv_path_install+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- # Account for people who put trailing slashes in PATH elements.
-case $as_dir/ in #((
- ./ | .// | /[cC]/* | \
- /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
- ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
- /usr/ucb/* ) ;;
- *)
- # OSF1 and SCO ODT 3.0 have their own names for install.
- # Don't use installbsd from OSF since it installs stuff as root
- # by default.
- for ac_prog in ginstall scoinst install; do
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
- if test $ac_prog = install &&
- grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
- # AIX install. It has an incompatible calling convention.
- :
- elif test $ac_prog = install &&
- grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
- # program-specific install script used by HP pwplus--don't use.
- :
- else
- rm -rf conftest.one conftest.two conftest.dir
- echo one > conftest.one
- echo two > conftest.two
- mkdir conftest.dir
- if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
- test -s conftest.one && test -s conftest.two &&
- test -s conftest.dir/conftest.one &&
- test -s conftest.dir/conftest.two
- then
- ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
- break 3
- fi
- fi
- fi
- done
- done
- ;;
-esac
-
- done
-IFS=$as_save_IFS
-
-rm -rf conftest.one conftest.two conftest.dir
-
-fi
- if test "${ac_cv_path_install+set}" = set; then
- INSTALL=$ac_cv_path_install
- else
- # As a last resort, use the slow shell script. Don't cache a
- # value for INSTALL within a source directory, because that will
- # break other packages using the cache if that directory is
- # removed, or if the value is a relative name.
- INSTALL=$ac_install_sh
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
-$as_echo "$INSTALL" >&6; }
-
-# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
-# It thinks the first close brace ends the variable substitution.
-test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
-
-test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
-
-test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5
-$as_echo_n "checking whether build environment is sane... " >&6; }
-# Reject unsafe characters in $srcdir or the absolute working directory
-# name. Accept space and tab only in the latter.
-am_lf='
-'
-case `pwd` in
- *[\\\"\#\$\&\'\`$am_lf]*)
- as_fn_error $? "unsafe absolute working directory name" "$LINENO" 5;;
-esac
-case $srcdir in
- *[\\\"\#\$\&\'\`$am_lf\ \ ]*)
- as_fn_error $? "unsafe srcdir value: '$srcdir'" "$LINENO" 5;;
-esac
-
-# Do 'set' in a subshell so we don't clobber the current shell's
-# arguments. Must try -L first in case configure is actually a
-# symlink; some systems play weird games with the mod time of symlinks
-# (eg FreeBSD returns the mod time of the symlink's containing
-# directory).
-if (
- am_has_slept=no
- for am_try in 1 2; do
- echo "timestamp, slept: $am_has_slept" > conftest.file
- set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
- if test "$*" = "X"; then
- # -L didn't work.
- set X `ls -t "$srcdir/configure" conftest.file`
- fi
- if test "$*" != "X $srcdir/configure conftest.file" \
- && test "$*" != "X conftest.file $srcdir/configure"; then
-
- # If neither matched, then we have a broken ls. This can happen
- # if, for instance, CONFIG_SHELL is bash and it inherits a
- # broken ls alias from the environment. This has actually
- # happened. Such a system could not be considered "sane".
- as_fn_error $? "ls -t appears to fail. Make sure there is not a broken
- alias in your environment" "$LINENO" 5
- fi
- if test "$2" = conftest.file || test $am_try -eq 2; then
- break
- fi
- # Just in case.
- sleep 1
- am_has_slept=yes
- done
- test "$2" = conftest.file
- )
-then
- # Ok.
- :
-else
- as_fn_error $? "newly created file is older than distributed files!
-Check your system clock" "$LINENO" 5
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-# If we didn't sleep, we still need to ensure time stamps of config.status and
-# generated files are strictly newer.
-am_sleep_pid=
-if grep 'slept: no' conftest.file >/dev/null 2>&1; then
- ( sleep 1 ) &
- am_sleep_pid=$!
-fi
-
-rm -f conftest.file
-
-test "$program_prefix" != NONE &&
- program_transform_name="s&^&$program_prefix&;$program_transform_name"
-# Use a double $ so make ignores it.
-test "$program_suffix" != NONE &&
- program_transform_name="s&\$&$program_suffix&;$program_transform_name"
-# Double any \ or $.
-# By default was `s,x,x', remove it if useless.
-ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
-program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
-
-# Expand $ac_aux_dir to an absolute path.
-am_aux_dir=`cd "$ac_aux_dir" && pwd`
-
-if test x"${MISSING+set}" != xset; then
- case $am_aux_dir in
- *\ * | *\ *)
- MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
- *)
- MISSING="\${SHELL} $am_aux_dir/missing" ;;
- esac
-fi
-# Use eval to expand $SHELL
-if eval "$MISSING --is-lightweight"; then
- am_missing_run="$MISSING "
-else
- am_missing_run=
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: 'missing' script is too old or missing" >&5
-$as_echo "$as_me: WARNING: 'missing' script is too old or missing" >&2;}
-fi
-
-if test x"${install_sh+set}" != xset; then
- case $am_aux_dir in
- *\ * | *\ *)
- install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
- *)
- install_sh="\${SHELL} $am_aux_dir/install-sh"
- esac
-fi
-
-# Installed binaries are usually stripped using 'strip' when the user
-# run "make install-strip". However 'strip' might not be the right
-# tool to use in cross-compilation environments, therefore Automake
-# will honor the 'STRIP' environment variable to overrule this program.
-if test "$cross_compiling" != no; then
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
-set dummy ${ac_tool_prefix}strip; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_STRIP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$STRIP"; then
- ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_STRIP="${ac_tool_prefix}strip"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-STRIP=$ac_cv_prog_STRIP
-if test -n "$STRIP"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
-$as_echo "$STRIP" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_STRIP"; then
- ac_ct_STRIP=$STRIP
- # Extract the first word of "strip", so it can be a program name with args.
-set dummy strip; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_STRIP"; then
- ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_STRIP="strip"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
-if test -n "$ac_ct_STRIP"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
-$as_echo "$ac_ct_STRIP" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_STRIP" = x; then
- STRIP=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- STRIP=$ac_ct_STRIP
- fi
-else
- STRIP="$ac_cv_prog_STRIP"
-fi
-
-fi
-INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5
-$as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
-if test -z "$MKDIR_P"; then
- if ${ac_cv_path_mkdir+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_prog in mkdir gmkdir; do
- for ac_exec_ext in '' $ac_executable_extensions; do
- as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext" || continue
- case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
- 'mkdir (GNU coreutils) '* | \
- 'mkdir (coreutils) '* | \
- 'mkdir (fileutils) '4.1*)
- ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
- break 3;;
- esac
- done
- done
- done
-IFS=$as_save_IFS
-
-fi
-
- test -d ./--version && rmdir ./--version
- if test "${ac_cv_path_mkdir+set}" = set; then
- MKDIR_P="$ac_cv_path_mkdir -p"
- else
- # As a last resort, use the slow shell script. Don't cache a
- # value for MKDIR_P within a source directory, because that will
- # break other packages using the cache if that directory is
- # removed, or if the value is a relative name.
- MKDIR_P="$ac_install_sh -d"
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
-$as_echo "$MKDIR_P" >&6; }
-
-for ac_prog in gawk mawk nawk awk
-do
- # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_AWK+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$AWK"; then
- ac_cv_prog_AWK="$AWK" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_AWK="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-AWK=$ac_cv_prog_AWK
-if test -n "$AWK"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
-$as_echo "$AWK" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$AWK" && break
-done
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
-$as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
-set x ${MAKE-make}
-ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
-if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat >conftest.make <<\_ACEOF
-SHELL = /bin/sh
-all:
- @echo '@@@%%%=$(MAKE)=@@@%%%'
-_ACEOF
-# GNU make sometimes prints "make[1]: Entering ...", which would confuse us.
-case `${MAKE-make} -f conftest.make 2>/dev/null` in
- *@@@%%%=?*=@@@%%%*)
- eval ac_cv_prog_make_${ac_make}_set=yes;;
- *)
- eval ac_cv_prog_make_${ac_make}_set=no;;
-esac
-rm -f conftest.make
-fi
-if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- SET_MAKE=
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- SET_MAKE="MAKE=${MAKE-make}"
-fi
-
-rm -rf .tst 2>/dev/null
-mkdir .tst 2>/dev/null
-if test -d .tst; then
- am__leading_dot=.
-else
- am__leading_dot=_
-fi
-rmdir .tst 2>/dev/null
-
-# Check whether --enable-silent-rules was given.
-if test "${enable_silent_rules+set}" = set; then :
- enableval=$enable_silent_rules;
-fi
-
-case $enable_silent_rules in # (((
- yes) AM_DEFAULT_VERBOSITY=0;;
- no) AM_DEFAULT_VERBOSITY=1;;
- *) AM_DEFAULT_VERBOSITY=1;;
-esac
-am_make=${MAKE-make}
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5
-$as_echo_n "checking whether $am_make supports nested variables... " >&6; }
-if ${am_cv_make_support_nested_variables+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if $as_echo 'TRUE=$(BAR$(V))
-BAR0=false
-BAR1=true
-V=1
-am__doit:
- @$(TRUE)
-.PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then
- am_cv_make_support_nested_variables=yes
-else
- am_cv_make_support_nested_variables=no
-fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5
-$as_echo "$am_cv_make_support_nested_variables" >&6; }
-if test $am_cv_make_support_nested_variables = yes; then
- AM_V='$(V)'
- AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
-else
- AM_V=$AM_DEFAULT_VERBOSITY
- AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY
-fi
-AM_BACKSLASH='\'
-
-if test "`cd $srcdir && pwd`" != "`pwd`"; then
- # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
- # is not polluted with repeated "-I."
- am__isrc=' -I$(srcdir)'
- # test to see if srcdir already configured
- if test -f $srcdir/config.status; then
- as_fn_error $? "source directory already configured; run \"make distclean\" there first" "$LINENO" 5
- fi
-fi
-
-# test whether we have cygpath
-if test -z "$CYGPATH_W"; then
- if (cygpath --version) >/dev/null 2>/dev/null; then
- CYGPATH_W='cygpath -w'
- else
- CYGPATH_W=echo
- fi
-fi
-
-
-# Define the identity of the package.
- PACKAGE='bfd'
- VERSION='2.43.1'
-
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE "$PACKAGE"
-_ACEOF
-
-
-cat >>confdefs.h <<_ACEOF
-#define VERSION "$VERSION"
-_ACEOF
-
-# Some tools Automake needs.
-
-ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"}
-
-
-AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
-
-
-AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"}
-
-
-AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
-
-
-MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
-
-# For better backward compatibility. To be removed once Automake 1.9.x
-# dies out for good. For more background, see:
-# <http://lists.gnu.org/archive/html/automake/2012-07/msg00001.html>
-# <http://lists.gnu.org/archive/html/automake/2012-07/msg00014.html>
-mkdir_p='$(MKDIR_P)'
-
-# We need awk for the "check" target (and possibly the TAP driver). The
-# system "awk" is bad on some platforms.
-# Always define AMTAR for backward compatibility. Yes, it's still used
-# in the wild :-( We should find a proper way to deprecate it ...
-AMTAR='$${TAR-tar}'
-
-
-# We'll loop over all known methods to create a tar archive until one works.
-_am_tools='gnutar pax cpio none'
-
-am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -'
-
-
-
-
-
-
-# POSIX will say in a future version that running "rm -f" with no argument
-# is OK; and we want to be able to make that assumption in our Makefile
-# recipes. So use an aggressive probe to check that the usage we want is
-# actually supported "in the wild" to an acceptable degree.
-# See automake bug#10828.
-# To make any issue more visible, cause the running configure to be aborted
-# by default if the 'rm' program in use doesn't match our expectations; the
-# user can still override this though.
-if rm -f && rm -fr && rm -rf; then : OK; else
- cat >&2 <<'END'
-Oops!
-
-Your 'rm' program seems unable to run without file operands specified
-on the command line, even when the '-f' option is present. This is contrary
-to the behaviour of most rm programs out there, and not conforming with
-the upcoming POSIX standard: <http://austingroupbugs.net/view.php?id=542>
-
-Please tell bug-automake@gnu.org about your system, including the value
-of your $PATH and any error possibly output before this message. This
-can help us improve future automake versions.
-
-END
- if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then
- echo 'Configuration will proceed anyway, since you have set the' >&2
- echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2
- echo >&2
- else
- cat >&2 <<'END'
-Aborting the configuration process, to ensure you take notice of the issue.
-
-You can download and install GNU coreutils to get an 'rm' implementation
-that behaves properly: <http://www.gnu.org/software/coreutils/>.
-
-If you want to complete the configuration process using your problematic
-'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM
-to "yes", and re-run configure.
-
-END
- as_fn_error $? "Your 'rm' program is bad, sorry." "$LINENO" 5
- fi
-fi
-
-# Check whether --enable-silent-rules was given.
-if test "${enable_silent_rules+set}" = set; then :
- enableval=$enable_silent_rules;
-fi
-
-case $enable_silent_rules in # (((
- yes) AM_DEFAULT_VERBOSITY=0;;
- no) AM_DEFAULT_VERBOSITY=1;;
- *) AM_DEFAULT_VERBOSITY=0;;
-esac
-am_make=${MAKE-make}
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5
-$as_echo_n "checking whether $am_make supports nested variables... " >&6; }
-if ${am_cv_make_support_nested_variables+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if $as_echo 'TRUE=$(BAR$(V))
-BAR0=false
-BAR1=true
-V=1
-am__doit:
- @$(TRUE)
-.PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then
- am_cv_make_support_nested_variables=yes
-else
- am_cv_make_support_nested_variables=no
-fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5
-$as_echo "$am_cv_make_support_nested_variables" >&6; }
-if test $am_cv_make_support_nested_variables = yes; then
- AM_V='$(V)'
- AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
-else
- AM_V=$AM_DEFAULT_VERBOSITY
- AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY
-fi
-AM_BACKSLASH='\'
-
-
-if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
-set dummy ${ac_tool_prefix}ar; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_AR+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$AR"; then
- ac_cv_prog_AR="$AR" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_AR="${ac_tool_prefix}ar"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-AR=$ac_cv_prog_AR
-if test -n "$AR"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
-$as_echo "$AR" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_AR"; then
- ac_ct_AR=$AR
- # Extract the first word of "ar", so it can be a program name with args.
-set dummy ar; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_AR+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_AR"; then
- ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_AR="ar"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_AR=$ac_cv_prog_ac_ct_AR
-if test -n "$ac_ct_AR"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
-$as_echo "$ac_ct_AR" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_AR" = x; then
- AR=""
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- AR=$ac_ct_AR
- fi
-else
- AR="$ac_cv_prog_AR"
-fi
-
-if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
-set dummy ${ac_tool_prefix}ranlib; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_RANLIB+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$RANLIB"; then
- ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-RANLIB=$ac_cv_prog_RANLIB
-if test -n "$RANLIB"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
-$as_echo "$RANLIB" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_RANLIB"; then
- ac_ct_RANLIB=$RANLIB
- # Extract the first word of "ranlib", so it can be a program name with args.
-set dummy ranlib; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_RANLIB"; then
- ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_RANLIB="ranlib"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
-if test -n "$ac_ct_RANLIB"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
-$as_echo "$ac_ct_RANLIB" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_RANLIB" = x; then
- RANLIB=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- RANLIB=$ac_ct_RANLIB
- fi
-else
- RANLIB="$ac_cv_prog_RANLIB"
-fi
-
-
-# Check whether --enable-shared was given.
-if test "${enable_shared+set}" = set; then :
- enableval=$enable_shared; p=${PACKAGE-default}
- case $enableval in
- yes) enable_shared=yes ;;
- no) enable_shared=no ;;
- *)
- enable_shared=no
- # Look at the argument we got. We use all the common list separators.
- lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
- for pkg in $enableval; do
- IFS="$lt_save_ifs"
- if test "X$pkg" = "X$p"; then
- enable_shared=yes
- fi
- done
- IFS="$lt_save_ifs"
- ;;
- esac
-else
- enable_shared=no
-fi
-
-
-
-
-
-
-
-
-
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
-set dummy ${ac_tool_prefix}gcc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_CC="${ac_tool_prefix}gcc"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
-$as_echo "$CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_CC"; then
- ac_ct_CC=$CC
- # Extract the first word of "gcc", so it can be a program name with args.
-set dummy gcc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_CC"; then
- ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_CC="gcc"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_CC=$ac_cv_prog_ac_ct_CC
-if test -n "$ac_ct_CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
-$as_echo "$ac_ct_CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_CC" = x; then
- CC=""
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- CC=$ac_ct_CC
- fi
-else
- CC="$ac_cv_prog_CC"
-fi
-
-if test -z "$CC"; then
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
-set dummy ${ac_tool_prefix}cc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_CC="${ac_tool_prefix}cc"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
-$as_echo "$CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
-fi
-if test -z "$CC"; then
- # Extract the first word of "cc", so it can be a program name with args.
-set dummy cc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
- ac_prog_rejected=no
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
- ac_prog_rejected=yes
- continue
- fi
- ac_cv_prog_CC="cc"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-if test $ac_prog_rejected = yes; then
- # We found a bogon in the path, so make sure we never use it.
- set dummy $ac_cv_prog_CC
- shift
- if test $# != 0; then
- # We chose a different compiler from the bogus one.
- # However, it has the same basename, so the bogon will be chosen
- # first if we set CC to just the basename; use the full file name.
- shift
- ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
- fi
-fi
-fi
-fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
-$as_echo "$CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$CC"; then
- if test -n "$ac_tool_prefix"; then
- for ac_prog in cl.exe
- do
- # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
-set dummy $ac_tool_prefix$ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
-$as_echo "$CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$CC" && break
- done
-fi
-if test -z "$CC"; then
- ac_ct_CC=$CC
- for ac_prog in cl.exe
-do
- # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_CC"; then
- ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_CC="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_CC=$ac_cv_prog_ac_ct_CC
-if test -n "$ac_ct_CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
-$as_echo "$ac_ct_CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$ac_ct_CC" && break
-done
-
- if test "x$ac_ct_CC" = x; then
- CC=""
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- CC=$ac_ct_CC
- fi
-fi
-
-fi
-
-
-test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "no acceptable C compiler found in \$PATH
-See \`config.log' for more details" "$LINENO" 5; }
-
-# Provide some information about the compiler.
-$as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
-set X $ac_compile
-ac_compiler=$2
-for ac_option in --version -v -V -qversion; do
- { { ac_try="$ac_compiler $ac_option >&5"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_compiler $ac_option >&5") 2>conftest.err
- ac_status=$?
- if test -s conftest.err; then
- sed '10a\
-... rest of stderr output deleted ...
- 10q' conftest.err >conftest.er1
- cat conftest.er1 >&5
- fi
- rm -f conftest.er1 conftest.err
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }
-done
-
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-ac_clean_files_save=$ac_clean_files
-ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
-# Try to create an executable without -o first, disregard a.out.
-# It will help us diagnose broken compilers, and finding out an intuition
-# of exeext.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
-$as_echo_n "checking whether the C compiler works... " >&6; }
-ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
-
-# The possible output files:
-ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
-
-ac_rmfiles=
-for ac_file in $ac_files
-do
- case $ac_file in
- *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
- * ) ac_rmfiles="$ac_rmfiles $ac_file";;
- esac
-done
-rm -f $ac_rmfiles
-
-if { { ac_try="$ac_link_default"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_link_default") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then :
- # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
-# So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
-# in a Makefile. We should not override ac_cv_exeext if it was cached,
-# so that the user can short-circuit this test for compilers unknown to
-# Autoconf.
-for ac_file in $ac_files ''
-do
- test -f "$ac_file" || continue
- case $ac_file in
- *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
- ;;
- [ab].out )
- # We found the default executable, but exeext='' is most
- # certainly right.
- break;;
- *.* )
- if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
- then :; else
- ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
- fi
- # We set ac_cv_exeext here because the later test for it is not
- # safe: cross compilers may not add the suffix if given an `-o'
- # argument, so we may need to know it at that point already.
- # Even if this section looks crufty: it has the advantage of
- # actually working.
- break;;
- * )
- break;;
- esac
-done
-test "$ac_cv_exeext" = no && ac_cv_exeext=
-
-else
- ac_file=''
-fi
-if test -z "$ac_file"; then :
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-$as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error 77 "C compiler cannot create executables
-See \`config.log' for more details" "$LINENO" 5; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
-$as_echo_n "checking for C compiler default output file name... " >&6; }
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
-$as_echo "$ac_file" >&6; }
-ac_exeext=$ac_cv_exeext
-
-rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
-ac_clean_files=$ac_clean_files_save
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
-$as_echo_n "checking for suffix of executables... " >&6; }
-if { { ac_try="$ac_link"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_link") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then :
- # If both `conftest.exe' and `conftest' are `present' (well, observable)
-# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
-# work properly (i.e., refer to `conftest.exe'), while it won't with
-# `rm'.
-for ac_file in conftest.exe conftest conftest.*; do
- test -f "$ac_file" || continue
- case $ac_file in
- *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
- *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
- break;;
- * ) break;;
- esac
-done
-else
- { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "cannot compute suffix of executables: cannot compile and link
-See \`config.log' for more details" "$LINENO" 5; }
-fi
-rm -f conftest conftest$ac_cv_exeext
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
-$as_echo "$ac_cv_exeext" >&6; }
-
-rm -f conftest.$ac_ext
-EXEEXT=$ac_cv_exeext
-ac_exeext=$EXEEXT
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <stdio.h>
-int
-main ()
-{
-FILE *f = fopen ("conftest.out", "w");
- return ferror (f) || fclose (f) != 0;
-
- ;
- return 0;
-}
-_ACEOF
-ac_clean_files="$ac_clean_files conftest.out"
-# Check that the compiler produces executables we can run. If not, either
-# the compiler is broken, or we cross compile.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
-$as_echo_n "checking whether we are cross compiling... " >&6; }
-if test "$cross_compiling" != yes; then
- { { ac_try="$ac_link"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_link") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }
- if { ac_try='./conftest$ac_cv_exeext'
- { { case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_try") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; }; then
- cross_compiling=no
- else
- if test "$cross_compiling" = maybe; then
- cross_compiling=yes
- else
- { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "cannot run C compiled programs.
-If you meant to cross compile, use \`--host'.
-See \`config.log' for more details" "$LINENO" 5; }
- fi
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
-$as_echo "$cross_compiling" >&6; }
-
-rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
-ac_clean_files=$ac_clean_files_save
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
-$as_echo_n "checking for suffix of object files... " >&6; }
-if ${ac_cv_objext+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-rm -f conftest.o conftest.obj
-if { { ac_try="$ac_compile"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_compile") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then :
- for ac_file in conftest.o conftest.obj conftest.*; do
- test -f "$ac_file" || continue;
- case $ac_file in
- *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
- *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
- break;;
- esac
-done
-else
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "cannot compute suffix of object files: cannot compile
-See \`config.log' for more details" "$LINENO" 5; }
-fi
-rm -f conftest.$ac_cv_objext conftest.$ac_ext
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
-$as_echo "$ac_cv_objext" >&6; }
-OBJEXT=$ac_cv_objext
-ac_objext=$OBJEXT
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
-$as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
-if ${ac_cv_c_compiler_gnu+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-#ifndef __GNUC__
- choke me
-#endif
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_compiler_gnu=yes
-else
- ac_compiler_gnu=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-ac_cv_c_compiler_gnu=$ac_compiler_gnu
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
-$as_echo "$ac_cv_c_compiler_gnu" >&6; }
-if test $ac_compiler_gnu = yes; then
- GCC=yes
-else
- GCC=
-fi
-ac_test_CFLAGS=${CFLAGS+set}
-ac_save_CFLAGS=$CFLAGS
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
-$as_echo_n "checking whether $CC accepts -g... " >&6; }
-if ${ac_cv_prog_cc_g+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_save_c_werror_flag=$ac_c_werror_flag
- ac_c_werror_flag=yes
- ac_cv_prog_cc_g=no
- CFLAGS="-g"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_prog_cc_g=yes
-else
- CFLAGS=""
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
-
-else
- ac_c_werror_flag=$ac_save_c_werror_flag
- CFLAGS="-g"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_prog_cc_g=yes
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- ac_c_werror_flag=$ac_save_c_werror_flag
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
-$as_echo "$ac_cv_prog_cc_g" >&6; }
-if test "$ac_test_CFLAGS" = set; then
- CFLAGS=$ac_save_CFLAGS
-elif test $ac_cv_prog_cc_g = yes; then
- if test "$GCC" = yes; then
- CFLAGS="-g -O2"
- else
- CFLAGS="-g"
- fi
-else
- if test "$GCC" = yes; then
- CFLAGS="-O2"
- else
- CFLAGS=
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
-$as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
-if ${ac_cv_prog_cc_c89+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_cv_prog_cc_c89=no
-ac_save_CC=$CC
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <stdarg.h>
-#include <stdio.h>
-struct stat;
-/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
-struct buf { int x; };
-FILE * (*rcsopen) (struct buf *, struct stat *, int);
-static char *e (p, i)
- char **p;
- int i;
-{
- return p[i];
-}
-static char *f (char * (*g) (char **, int), char **p, ...)
-{
- char *s;
- va_list v;
- va_start (v,p);
- s = g (p, va_arg (v,int));
- va_end (v);
- return s;
-}
-
-/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
- function prototypes and stuff, but not '\xHH' hex character constants.
- These don't provoke an error unfortunately, instead are silently treated
- as 'x'. The following induces an error, until -std is added to get
- proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
- array size at least. It's necessary to write '\x00'==0 to get something
- that's true only with -std. */
-int osf4_cc_array ['\x00' == 0 ? 1 : -1];
-
-/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
- inside strings and character constants. */
-#define FOO(x) 'x'
-int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
-
-int test (int i, double x);
-struct s1 {int (*f) (int a);};
-struct s2 {int (*f) (double a);};
-int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
-int argc;
-char **argv;
-int
-main ()
-{
-return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
- ;
- return 0;
-}
-_ACEOF
-for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
- -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
-do
- CC="$ac_save_CC $ac_arg"
- if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_prog_cc_c89=$ac_arg
-fi
-rm -f core conftest.err conftest.$ac_objext
- test "x$ac_cv_prog_cc_c89" != "xno" && break
-done
-rm -f conftest.$ac_ext
-CC=$ac_save_CC
-
-fi
-# AC_CACHE_VAL
-case "x$ac_cv_prog_cc_c89" in
- x)
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
-$as_echo "none needed" >&6; } ;;
- xno)
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
-$as_echo "unsupported" >&6; } ;;
- *)
- CC="$CC $ac_cv_prog_cc_c89"
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
-$as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
-esac
-if test "x$ac_cv_prog_cc_c89" != xno; then :
-
-fi
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC understands -c and -o together" >&5
-$as_echo_n "checking whether $CC understands -c and -o together... " >&6; }
-if ${am_cv_prog_cc_c_o+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
- # Make sure it works both with $CC and with simple cc.
- # Following AC_PROG_CC_C_O, we do the test twice because some
- # compilers refuse to overwrite an existing .o file with -o,
- # though they will create one.
- am_cv_prog_cc_c_o=yes
- for am_i in 1 2; do
- if { echo "$as_me:$LINENO: $CC -c conftest.$ac_ext -o conftest2.$ac_objext" >&5
- ($CC -c conftest.$ac_ext -o conftest2.$ac_objext) >&5 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } \
- && test -f conftest2.$ac_objext; then
- : OK
- else
- am_cv_prog_cc_c_o=no
- break
- fi
- done
- rm -f core conftest*
- unset am_i
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_cc_c_o" >&5
-$as_echo "$am_cv_prog_cc_c_o" >&6; }
-if test "$am_cv_prog_cc_c_o" != yes; then
- # Losing compiler, so override with the script.
- # FIXME: It is wrong to rewrite CC.
- # But if we don't then we get into trouble of one sort or another.
- # A longer-term fix would be to have automake use am__CC in this case,
- # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
- CC="$am_aux_dir/compile $CC"
-fi
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-DEPDIR="${am__leading_dot}deps"
-
-ac_config_commands="$ac_config_commands depfiles"
-
-
-am_make=${MAKE-make}
-cat > confinc << 'END'
-am__doit:
- @echo this is the am__doit target
-.PHONY: am__doit
-END
-# If we don't find an include directive, just comment out the code.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5
-$as_echo_n "checking for style of include used by $am_make... " >&6; }
-am__include="#"
-am__quote=
-_am_result=none
-# First try GNU make style include.
-echo "include confinc" > confmf
-# Ignore all kinds of additional output from 'make'.
-case `$am_make -s -f confmf 2> /dev/null` in #(
-*the\ am__doit\ target*)
- am__include=include
- am__quote=
- _am_result=GNU
- ;;
-esac
-# Now try BSD make style include.
-if test "$am__include" = "#"; then
- echo '.include "confinc"' > confmf
- case `$am_make -s -f confmf 2> /dev/null` in #(
- *the\ am__doit\ target*)
- am__include=.include
- am__quote="\""
- _am_result=BSD
- ;;
- esac
-fi
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5
-$as_echo "$_am_result" >&6; }
-rm -f confinc confmf
-
-# Check whether --enable-dependency-tracking was given.
-if test "${enable_dependency_tracking+set}" = set; then :
- enableval=$enable_dependency_tracking;
-fi
-
-if test "x$enable_dependency_tracking" != xno; then
- am_depcomp="$ac_aux_dir/depcomp"
- AMDEPBACKSLASH='\'
- am__nodep='_no'
-fi
- if test "x$enable_dependency_tracking" != xno; then
- AMDEP_TRUE=
- AMDEP_FALSE='#'
-else
- AMDEP_TRUE='#'
- AMDEP_FALSE=
-fi
-
-
-
-depcc="$CC" am_compiler_list=
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
-$as_echo_n "checking dependency style of $depcc... " >&6; }
-if ${am_cv_CC_dependencies_compiler_type+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
- # We make a subdir and do the tests there. Otherwise we can end up
- # making bogus files that we don't know about and never remove. For
- # instance it was reported that on HP-UX the gcc test will end up
- # making a dummy file named 'D' -- because '-MD' means "put the output
- # in D".
- rm -rf conftest.dir
- mkdir conftest.dir
- # Copy depcomp to subdir because otherwise we won't find it if we're
- # using a relative directory.
- cp "$am_depcomp" conftest.dir
- cd conftest.dir
- # We will build objects and dependencies in a subdirectory because
- # it helps to detect inapplicable dependency modes. For instance
- # both Tru64's cc and ICC support -MD to output dependencies as a
- # side effect of compilation, but ICC will put the dependencies in
- # the current directory while Tru64 will put them in the object
- # directory.
- mkdir sub
-
- am_cv_CC_dependencies_compiler_type=none
- if test "$am_compiler_list" = ""; then
- am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
- fi
- am__universal=false
- case " $depcc " in #(
- *\ -arch\ *\ -arch\ *) am__universal=true ;;
- esac
-
- for depmode in $am_compiler_list; do
- # Setup a source with many dependencies, because some compilers
- # like to wrap large dependency lists on column 80 (with \), and
- # we should not choose a depcomp mode which is confused by this.
- #
- # We need to recreate these files for each test, as the compiler may
- # overwrite some of them when testing with obscure command lines.
- # This happens at least with the AIX C compiler.
- : > sub/conftest.c
- for i in 1 2 3 4 5 6; do
- echo '#include "conftst'$i'.h"' >> sub/conftest.c
- # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with
- # Solaris 10 /bin/sh.
- echo '/* dummy */' > sub/conftst$i.h
- done
- echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
-
- # We check with '-c' and '-o' for the sake of the "dashmstdout"
- # mode. It turns out that the SunPro C++ compiler does not properly
- # handle '-M -o', and we need to detect this. Also, some Intel
- # versions had trouble with output in subdirs.
- am__obj=sub/conftest.${OBJEXT-o}
- am__minus_obj="-o $am__obj"
- case $depmode in
- gcc)
- # This depmode causes a compiler race in universal mode.
- test "$am__universal" = false || continue
- ;;
- nosideeffect)
- # After this tag, mechanisms are not by side-effect, so they'll
- # only be used when explicitly requested.
- if test "x$enable_dependency_tracking" = xyes; then
- continue
- else
- break
- fi
- ;;
- msvc7 | msvc7msys | msvisualcpp | msvcmsys)
- # This compiler won't grok '-c -o', but also, the minuso test has
- # not run yet. These depmodes are late enough in the game, and
- # so weak that their functioning should not be impacted.
- am__obj=conftest.${OBJEXT-o}
- am__minus_obj=
- ;;
- none) break ;;
- esac
- if depmode=$depmode \
- source=sub/conftest.c object=$am__obj \
- depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
- $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
- >/dev/null 2>conftest.err &&
- grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
- grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
- grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
- ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
- # icc doesn't choke on unknown options, it will just issue warnings
- # or remarks (even with -Werror). So we grep stderr for any message
- # that says an option was ignored or not supported.
- # When given -MP, icc 7.0 and 7.1 complain thusly:
- # icc: Command line warning: ignoring option '-M'; no argument required
- # The diagnosis changed in icc 8.0:
- # icc: Command line remark: option '-MP' not supported
- if (grep 'ignoring option' conftest.err ||
- grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
- am_cv_CC_dependencies_compiler_type=$depmode
- break
- fi
- fi
- done
-
- cd ..
- rm -rf conftest.dir
-else
- am_cv_CC_dependencies_compiler_type=none
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
-$as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
-CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
-
- if
- test "x$enable_dependency_tracking" != xno \
- && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
- am__fastdepCC_TRUE=
- am__fastdepCC_FALSE='#'
-else
- am__fastdepCC_TRUE='#'
- am__fastdepCC_FALSE=
-fi
-
-
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
-$as_echo_n "checking how to run the C preprocessor... " >&6; }
-# On Suns, sometimes $CPP names a directory.
-if test -n "$CPP" && test -d "$CPP"; then
- CPP=
-fi
-if test -z "$CPP"; then
- if ${ac_cv_prog_CPP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- # Double quotes because CPP needs to be expanded
- for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
- do
- ac_preproc_ok=false
-for ac_c_preproc_warn_flag in '' yes
-do
- # Use a header file that comes with gcc, so configuring glibc
- # with a fresh cross-compiler works.
- # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
- # <limits.h> exists even on freestanding compilers.
- # On the NeXT, cc -E runs the code through the compiler's parser,
- # not just through cpp. "Syntax error" is here to catch this case.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#ifdef __STDC__
-# include <limits.h>
-#else
-# include <assert.h>
-#endif
- Syntax error
-_ACEOF
-if ac_fn_c_try_cpp "$LINENO"; then :
-
-else
- # Broken: fails on valid input.
-continue
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-
- # OK, works on sane cases. Now check whether nonexistent headers
- # can be detected and how.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <ac_nonexistent.h>
-_ACEOF
-if ac_fn_c_try_cpp "$LINENO"; then :
- # Broken: success on invalid input.
-continue
-else
- # Passes both tests.
-ac_preproc_ok=:
-break
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-
-done
-# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
-rm -f conftest.i conftest.err conftest.$ac_ext
-if $ac_preproc_ok; then :
- break
-fi
-
- done
- ac_cv_prog_CPP=$CPP
-
-fi
- CPP=$ac_cv_prog_CPP
-else
- ac_cv_prog_CPP=$CPP
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
-$as_echo "$CPP" >&6; }
-ac_preproc_ok=false
-for ac_c_preproc_warn_flag in '' yes
-do
- # Use a header file that comes with gcc, so configuring glibc
- # with a fresh cross-compiler works.
- # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
- # <limits.h> exists even on freestanding compilers.
- # On the NeXT, cc -E runs the code through the compiler's parser,
- # not just through cpp. "Syntax error" is here to catch this case.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#ifdef __STDC__
-# include <limits.h>
-#else
-# include <assert.h>
-#endif
- Syntax error
-_ACEOF
-if ac_fn_c_try_cpp "$LINENO"; then :
-
-else
- # Broken: fails on valid input.
-continue
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-
- # OK, works on sane cases. Now check whether nonexistent headers
- # can be detected and how.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <ac_nonexistent.h>
-_ACEOF
-if ac_fn_c_try_cpp "$LINENO"; then :
- # Broken: success on invalid input.
-continue
-else
- # Passes both tests.
-ac_preproc_ok=:
-break
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-
-done
-# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
-rm -f conftest.i conftest.err conftest.$ac_ext
-if $ac_preproc_ok; then :
-
-else
- { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
-See \`config.log' for more details" "$LINENO" 5; }
-fi
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
-$as_echo_n "checking for grep that handles long lines and -e... " >&6; }
-if ${ac_cv_path_GREP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -z "$GREP"; then
- ac_path_GREP_found=false
- # Loop through the user's path and test for each of PROGNAME-LIST
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_prog in grep ggrep; do
- for ac_exec_ext in '' $ac_executable_extensions; do
- ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
- as_fn_executable_p "$ac_path_GREP" || continue
-# Check for GNU ac_path_GREP and select it if it is found.
- # Check for GNU $ac_path_GREP
-case `"$ac_path_GREP" --version 2>&1` in
-*GNU*)
- ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
-*)
- ac_count=0
- $as_echo_n 0123456789 >"conftest.in"
- while :
- do
- cat "conftest.in" "conftest.in" >"conftest.tmp"
- mv "conftest.tmp" "conftest.in"
- cp "conftest.in" "conftest.nl"
- $as_echo 'GREP' >> "conftest.nl"
- "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
- diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
- as_fn_arith $ac_count + 1 && ac_count=$as_val
- if test $ac_count -gt ${ac_path_GREP_max-0}; then
- # Best one so far, save it but keep looking for a better one
- ac_cv_path_GREP="$ac_path_GREP"
- ac_path_GREP_max=$ac_count
- fi
- # 10*(2^10) chars as input seems more than enough
- test $ac_count -gt 10 && break
- done
- rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
-esac
-
- $ac_path_GREP_found && break 3
- done
- done
- done
-IFS=$as_save_IFS
- if test -z "$ac_cv_path_GREP"; then
- as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
- fi
-else
- ac_cv_path_GREP=$GREP
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
-$as_echo "$ac_cv_path_GREP" >&6; }
- GREP="$ac_cv_path_GREP"
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
-$as_echo_n "checking for egrep... " >&6; }
-if ${ac_cv_path_EGREP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
- then ac_cv_path_EGREP="$GREP -E"
- else
- if test -z "$EGREP"; then
- ac_path_EGREP_found=false
- # Loop through the user's path and test for each of PROGNAME-LIST
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_prog in egrep; do
- for ac_exec_ext in '' $ac_executable_extensions; do
- ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
- as_fn_executable_p "$ac_path_EGREP" || continue
-# Check for GNU ac_path_EGREP and select it if it is found.
- # Check for GNU $ac_path_EGREP
-case `"$ac_path_EGREP" --version 2>&1` in
-*GNU*)
- ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
-*)
- ac_count=0
- $as_echo_n 0123456789 >"conftest.in"
- while :
- do
- cat "conftest.in" "conftest.in" >"conftest.tmp"
- mv "conftest.tmp" "conftest.in"
- cp "conftest.in" "conftest.nl"
- $as_echo 'EGREP' >> "conftest.nl"
- "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
- diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
- as_fn_arith $ac_count + 1 && ac_count=$as_val
- if test $ac_count -gt ${ac_path_EGREP_max-0}; then
- # Best one so far, save it but keep looking for a better one
- ac_cv_path_EGREP="$ac_path_EGREP"
- ac_path_EGREP_max=$ac_count
- fi
- # 10*(2^10) chars as input seems more than enough
- test $ac_count -gt 10 && break
- done
- rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
-esac
-
- $ac_path_EGREP_found && break 3
- done
- done
- done
-IFS=$as_save_IFS
- if test -z "$ac_cv_path_EGREP"; then
- as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
- fi
-else
- ac_cv_path_EGREP=$EGREP
-fi
-
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
-$as_echo "$ac_cv_path_EGREP" >&6; }
- EGREP="$ac_cv_path_EGREP"
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
-$as_echo_n "checking for ANSI C header files... " >&6; }
-if ${ac_cv_header_stdc+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <stdlib.h>
-#include <stdarg.h>
-#include <string.h>
-#include <float.h>
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_header_stdc=yes
-else
- ac_cv_header_stdc=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-
-if test $ac_cv_header_stdc = yes; then
- # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <string.h>
-
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "memchr" >/dev/null 2>&1; then :
-
-else
- ac_cv_header_stdc=no
-fi
-rm -f conftest*
-
-fi
-
-if test $ac_cv_header_stdc = yes; then
- # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <stdlib.h>
-
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "free" >/dev/null 2>&1; then :
-
-else
- ac_cv_header_stdc=no
-fi
-rm -f conftest*
-
-fi
-
-if test $ac_cv_header_stdc = yes; then
- # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
- if test "$cross_compiling" = yes; then :
- :
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <ctype.h>
-#include <stdlib.h>
-#if ((' ' & 0x0FF) == 0x020)
-# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
-# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
-#else
-# define ISLOWER(c) \
- (('a' <= (c) && (c) <= 'i') \
- || ('j' <= (c) && (c) <= 'r') \
- || ('s' <= (c) && (c) <= 'z'))
-# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
-#endif
-
-#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
-int
-main ()
-{
- int i;
- for (i = 0; i < 256; i++)
- if (XOR (islower (i), ISLOWER (i))
- || toupper (i) != TOUPPER (i))
- return 2;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_run "$LINENO"; then :
-
-else
- ac_cv_header_stdc=no
-fi
-rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
- conftest.$ac_objext conftest.beam conftest.$ac_ext
-fi
-
-fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
-$as_echo "$ac_cv_header_stdc" >&6; }
-if test $ac_cv_header_stdc = yes; then
-
-$as_echo "#define STDC_HEADERS 1" >>confdefs.h
-
-fi
-
-# On IRIX 5.3, sys/types and inttypes.h are conflicting.
-for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
- inttypes.h stdint.h unistd.h
-do :
- as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
-ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
-"
-if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
- cat >>confdefs.h <<_ACEOF
-#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
-_ACEOF
-
-fi
-
-done
-
-
-
- ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
-if test "x$ac_cv_header_minix_config_h" = xyes; then :
- MINIX=yes
-else
- MINIX=
-fi
-
-
- if test "$MINIX" = yes; then
-
-$as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
-
-
-$as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
-
-
-$as_echo "#define _MINIX 1" >>confdefs.h
-
- fi
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
-$as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
-if ${ac_cv_safe_to_define___extensions__+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-# define __EXTENSIONS__ 1
- $ac_includes_default
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_safe_to_define___extensions__=yes
-else
- ac_cv_safe_to_define___extensions__=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
-$as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
- test $ac_cv_safe_to_define___extensions__ = yes &&
- $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
-
- $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
-
- $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
-
- $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
-
- $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
-
-
-
-case `pwd` in
- *\ * | *\ *)
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&5
-$as_echo "$as_me: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&2;} ;;
-esac
-
-
-
-macro_version='2.2.7a'
-macro_revision='1.3134'
-
-
-
-
-
-
-
-
-
-
-
-
-
-ltmain="$ac_aux_dir/ltmain.sh"
-
-# Backslashify metacharacters that are still active within
-# double-quoted strings.
-sed_quote_subst='s/\(["`$\\]\)/\\\1/g'
-
-# Same as above, but do not quote variable references.
-double_quote_subst='s/\(["`\\]\)/\\\1/g'
-
-# Sed substitution to delay expansion of an escaped shell variable in a
-# double_quote_subst'ed string.
-delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
-
-# Sed substitution to delay expansion of an escaped single quote.
-delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g'
-
-# Sed substitution to avoid accidental globbing in evaled expressions
-no_glob_subst='s/\*/\\\*/g'
-
-ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
-ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO
-ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5
-$as_echo_n "checking how to print strings... " >&6; }
-# Test print first, because it will be a builtin if present.
-if test "X`print -r -- -n 2>/dev/null`" = X-n && \
- test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
- ECHO='print -r --'
-elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
- ECHO='printf %s\n'
-else
- # Use this function as a fallback that always works.
- func_fallback_echo ()
- {
- eval 'cat <<_LTECHO_EOF
-$1
-_LTECHO_EOF'
- }
- ECHO='func_fallback_echo'
-fi
-
-# func_echo_all arg...
-# Invoke $ECHO with all args, space-separated.
-func_echo_all ()
-{
- $ECHO ""
-}
-
-case "$ECHO" in
- printf*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: printf" >&5
-$as_echo "printf" >&6; } ;;
- print*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: print -r" >&5
-$as_echo "print -r" >&6; } ;;
- *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: cat" >&5
-$as_echo "cat" >&6; } ;;
-esac
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
-$as_echo_n "checking for a sed that does not truncate output... " >&6; }
-if ${ac_cv_path_SED+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
- for ac_i in 1 2 3 4 5 6 7; do
- ac_script="$ac_script$as_nl$ac_script"
- done
- echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
- { ac_script=; unset ac_script;}
- if test -z "$SED"; then
- ac_path_SED_found=false
- # Loop through the user's path and test for each of PROGNAME-LIST
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_prog in sed gsed; do
- for ac_exec_ext in '' $ac_executable_extensions; do
- ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
- as_fn_executable_p "$ac_path_SED" || continue
-# Check for GNU ac_path_SED and select it if it is found.
- # Check for GNU $ac_path_SED
-case `"$ac_path_SED" --version 2>&1` in
-*GNU*)
- ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
-*)
- ac_count=0
- $as_echo_n 0123456789 >"conftest.in"
- while :
- do
- cat "conftest.in" "conftest.in" >"conftest.tmp"
- mv "conftest.tmp" "conftest.in"
- cp "conftest.in" "conftest.nl"
- $as_echo '' >> "conftest.nl"
- "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
- diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
- as_fn_arith $ac_count + 1 && ac_count=$as_val
- if test $ac_count -gt ${ac_path_SED_max-0}; then
- # Best one so far, save it but keep looking for a better one
- ac_cv_path_SED="$ac_path_SED"
- ac_path_SED_max=$ac_count
- fi
- # 10*(2^10) chars as input seems more than enough
- test $ac_count -gt 10 && break
- done
- rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
-esac
-
- $ac_path_SED_found && break 3
- done
- done
- done
-IFS=$as_save_IFS
- if test -z "$ac_cv_path_SED"; then
- as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
- fi
-else
- ac_cv_path_SED=$SED
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
-$as_echo "$ac_cv_path_SED" >&6; }
- SED="$ac_cv_path_SED"
- rm -f conftest.sed
-
-test -z "$SED" && SED=sed
-Xsed="$SED -e 1s/^X//"
-
-
-
-
-
-
-
-
-
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5
-$as_echo_n "checking for fgrep... " >&6; }
-if ${ac_cv_path_FGREP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1
- then ac_cv_path_FGREP="$GREP -F"
- else
- if test -z "$FGREP"; then
- ac_path_FGREP_found=false
- # Loop through the user's path and test for each of PROGNAME-LIST
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_prog in fgrep; do
- for ac_exec_ext in '' $ac_executable_extensions; do
- ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext"
- as_fn_executable_p "$ac_path_FGREP" || continue
-# Check for GNU ac_path_FGREP and select it if it is found.
- # Check for GNU $ac_path_FGREP
-case `"$ac_path_FGREP" --version 2>&1` in
-*GNU*)
- ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;;
-*)
- ac_count=0
- $as_echo_n 0123456789 >"conftest.in"
- while :
- do
- cat "conftest.in" "conftest.in" >"conftest.tmp"
- mv "conftest.tmp" "conftest.in"
- cp "conftest.in" "conftest.nl"
- $as_echo 'FGREP' >> "conftest.nl"
- "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break
- diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
- as_fn_arith $ac_count + 1 && ac_count=$as_val
- if test $ac_count -gt ${ac_path_FGREP_max-0}; then
- # Best one so far, save it but keep looking for a better one
- ac_cv_path_FGREP="$ac_path_FGREP"
- ac_path_FGREP_max=$ac_count
- fi
- # 10*(2^10) chars as input seems more than enough
- test $ac_count -gt 10 && break
- done
- rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
-esac
-
- $ac_path_FGREP_found && break 3
- done
- done
- done
-IFS=$as_save_IFS
- if test -z "$ac_cv_path_FGREP"; then
- as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
- fi
-else
- ac_cv_path_FGREP=$FGREP
-fi
-
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5
-$as_echo "$ac_cv_path_FGREP" >&6; }
- FGREP="$ac_cv_path_FGREP"
-
-
-test -z "$GREP" && GREP=grep
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-# Check whether --with-gnu-ld was given.
-if test "${with_gnu_ld+set}" = set; then :
- withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
-else
- with_gnu_ld=no
-fi
-
-ac_prog=ld
-if test "$GCC" = yes; then
- # Check if gcc -print-prog-name=ld gives a path.
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5
-$as_echo_n "checking for ld used by $CC... " >&6; }
- case $host in
- *-*-mingw*)
- # gcc leaves a trailing carriage return which upsets mingw
- ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
- *)
- ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
- esac
- case $ac_prog in
- # Accept absolute paths.
- [\\/]* | ?:[\\/]*)
- re_direlt='/[^/][^/]*/\.\./'
- # Canonicalize the pathname of ld
- ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'`
- while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do
- ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"`
- done
- test -z "$LD" && LD="$ac_prog"
- ;;
- "")
- # If it fails, then pretend we aren't using GCC.
- ac_prog=ld
- ;;
- *)
- # If it is relative, then search for the first ld in PATH.
- with_gnu_ld=unknown
- ;;
- esac
-elif test "$with_gnu_ld" = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
-$as_echo_n "checking for GNU ld... " >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
-$as_echo_n "checking for non-GNU ld... " >&6; }
-fi
-if ${lt_cv_path_LD+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -z "$LD"; then
- lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH; do
- IFS="$lt_save_ifs"
- test -z "$ac_dir" && ac_dir=.
- if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
- lt_cv_path_LD="$ac_dir/$ac_prog"
- # Check to see if the program is GNU ld. I'd rather use --version,
- # but apparently some variants of GNU ld only accept -v.
- # Break only if it was the GNU/non-GNU ld that we prefer.
- case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
- *GNU* | *'with BFD'*)
- test "$with_gnu_ld" != no && break
- ;;
- *)
- test "$with_gnu_ld" != yes && break
- ;;
- esac
- fi
- done
- IFS="$lt_save_ifs"
-else
- lt_cv_path_LD="$LD" # Let the user override the test with a path.
-fi
-fi
-
-LD="$lt_cv_path_LD"
-if test -n "$LD"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
-$as_echo "$LD" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
-$as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
-if ${lt_cv_prog_gnu_ld+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- # I'd rather use --version here, but apparently some GNU lds only accept -v.
-case `$LD -v 2>&1 </dev/null` in
-*GNU* | *'with BFD'*)
- lt_cv_prog_gnu_ld=yes
- ;;
-*)
- lt_cv_prog_gnu_ld=no
- ;;
-esac
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_gnu_ld" >&5
-$as_echo "$lt_cv_prog_gnu_ld" >&6; }
-with_gnu_ld=$lt_cv_prog_gnu_ld
-
-
-
-
-
-
-
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for BSD- or MS-compatible name lister (nm)" >&5
-$as_echo_n "checking for BSD- or MS-compatible name lister (nm)... " >&6; }
-if ${lt_cv_path_NM+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$NM"; then
- # Let the user override the nm to test.
- lt_nm_to_check="$NM"
- else
- lt_nm_to_check="${ac_tool_prefix}nm"
- if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
- lt_nm_to_check="$lt_nm_to_check nm"
- fi
- fi
- for lt_tmp_nm in "$lt_nm_to_check"; do
- lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
- IFS="$lt_save_ifs"
- test -z "$ac_dir" && ac_dir=.
- # Strip out any user-provided options from the nm to test twice,
- # the first time to test to see if nm (rather than its options) has
- # an explicit path, the second time to yield a file which can be
- # nm'ed itself.
- tmp_nm_path="`$ECHO "$lt_tmp_nm" | sed 's, -.*$,,'`"
- case "$tmp_nm_path" in
- */*|*\\*) tmp_nm="$lt_tmp_nm";;
- *) tmp_nm="$ac_dir/$lt_tmp_nm";;
- esac
- tmp_nm_to_nm="`$ECHO "$tmp_nm" | sed 's, -.*$,,'`"
- if test -f "$tmp_nm_to_nm" || test -f "$tmp_nm_to_nm$ac_exeext" ; then
- # Check to see if the nm accepts a BSD-compat flag.
- # Adding the `sed 1q' prevents false positives on HP-UX, which says:
- # nm: unknown option "B" ignored
- case `"$tmp_nm" -B "$tmp_nm_to_nm" 2>&1 | grep -v '^ *$' | sed '1q'` in
- *$tmp_nm*) lt_cv_path_NM="$tmp_nm -B"
- break
- ;;
- *)
- case `"$tmp_nm" -p "$tmp_nm_to_nm" 2>&1 | grep -v '^ *$' | sed '1q'` in
- *$tmp_nm*)
- lt_cv_path_NM="$tmp_nm -p"
- break
- ;;
- *)
- lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
- continue # so that we can try to find one that supports BSD flags
- ;;
- esac
- ;;
- esac
- fi
- done
- IFS="$lt_save_ifs"
- done
- : ${lt_cv_path_NM=no}
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_NM" >&5
-$as_echo "$lt_cv_path_NM" >&6; }
-if test "$lt_cv_path_NM" != "no"; then
- NM="$lt_cv_path_NM"
-else
- # Didn't find any BSD compatible name lister, look for dumpbin.
- if test -n "$DUMPBIN"; then :
- # Let the user override the test.
- else
- if test -n "$ac_tool_prefix"; then
- for ac_prog in dumpbin "link -dump"
- do
- # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
-set dummy $ac_tool_prefix$ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_DUMPBIN+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$DUMPBIN"; then
- ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_DUMPBIN="$ac_tool_prefix$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-DUMPBIN=$ac_cv_prog_DUMPBIN
-if test -n "$DUMPBIN"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5
-$as_echo "$DUMPBIN" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$DUMPBIN" && break
- done
-fi
-if test -z "$DUMPBIN"; then
- ac_ct_DUMPBIN=$DUMPBIN
- for ac_prog in dumpbin "link -dump"
-do
- # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_DUMPBIN+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_DUMPBIN"; then
- ac_cv_prog_ac_ct_DUMPBIN="$ac_ct_DUMPBIN" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_DUMPBIN="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_DUMPBIN=$ac_cv_prog_ac_ct_DUMPBIN
-if test -n "$ac_ct_DUMPBIN"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DUMPBIN" >&5
-$as_echo "$ac_ct_DUMPBIN" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$ac_ct_DUMPBIN" && break
-done
-
- if test "x$ac_ct_DUMPBIN" = x; then
- DUMPBIN=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- DUMPBIN=$ac_ct_DUMPBIN
- fi
-fi
-
- case `$DUMPBIN -symbols /dev/null 2>&1 | sed '1q'` in
- *COFF*)
- DUMPBIN="$DUMPBIN -symbols"
- ;;
- *)
- DUMPBIN=:
- ;;
- esac
- fi
-
- if test "$DUMPBIN" != ":"; then
- NM="$DUMPBIN"
- fi
-fi
-test -z "$NM" && NM=nm
-
-
-
-
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the name lister ($NM) interface" >&5
-$as_echo_n "checking the name lister ($NM) interface... " >&6; }
-if ${lt_cv_nm_interface+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_nm_interface="BSD nm"
- echo "int some_variable = 0;" > conftest.$ac_ext
- (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&5)
- (eval "$ac_compile" 2>conftest.err)
- cat conftest.err >&5
- (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&5)
- (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out)
- cat conftest.err >&5
- (eval echo "\"\$as_me:$LINENO: output\"" >&5)
- cat conftest.out >&5
- if $GREP 'External.*some_variable' conftest.out > /dev/null; then
- lt_cv_nm_interface="MS dumpbin"
- fi
- rm -f conftest*
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_nm_interface" >&5
-$as_echo "$lt_cv_nm_interface" >&6; }
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
-$as_echo_n "checking whether ln -s works... " >&6; }
-LN_S=$as_ln_s
-if test "$LN_S" = "ln -s"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
-$as_echo "no, using $LN_S" >&6; }
-fi
-
-# find the maximum length of command line arguments
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the maximum length of command line arguments" >&5
-$as_echo_n "checking the maximum length of command line arguments... " >&6; }
-if ${lt_cv_sys_max_cmd_len+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- i=0
- teststring="ABCD"
-
- case $build_os in
- msdosdjgpp*)
- # On DJGPP, this test can blow up pretty badly due to problems in libc
- # (any single argument exceeding 2000 bytes causes a buffer overrun
- # during glob expansion). Even if it were fixed, the result of this
- # check would be larger than it should be.
- lt_cv_sys_max_cmd_len=12288; # 12K is about right
- ;;
-
- gnu*)
- # Under GNU Hurd, this test is not required because there is
- # no limit to the length of command line arguments.
- # Libtool will interpret -1 as no limit whatsoever
- lt_cv_sys_max_cmd_len=-1;
- ;;
-
- cygwin* | mingw* | cegcc*)
- # On Win9x/ME, this test blows up -- it succeeds, but takes
- # about 5 minutes as the teststring grows exponentially.
- # Worse, since 9x/ME are not pre-emptively multitasking,
- # you end up with a "frozen" computer, even though with patience
- # the test eventually succeeds (with a max line length of 256k).
- # Instead, let's just punt: use the minimum linelength reported by
- # all of the supported platforms: 8192 (on NT/2K/XP).
- lt_cv_sys_max_cmd_len=8192;
- ;;
-
- mint*)
- # On MiNT this can take a long time and run out of memory.
- lt_cv_sys_max_cmd_len=8192;
- ;;
-
- amigaos*)
- # On AmigaOS with pdksh, this test takes hours, literally.
- # So we just punt and use a minimum line length of 8192.
- lt_cv_sys_max_cmd_len=8192;
- ;;
-
- netbsd* | freebsd* | openbsd* | darwin* | dragonfly*)
- # This has been around since 386BSD, at least. Likely further.
- if test -x /sbin/sysctl; then
- lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
- elif test -x /usr/sbin/sysctl; then
- lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
- else
- lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs
- fi
- # And add a safety zone
- lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
- lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
- ;;
-
- interix*)
- # We know the value 262144 and hardcode it with a safety zone (like BSD)
- lt_cv_sys_max_cmd_len=196608
- ;;
-
- osf*)
- # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
- # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
- # nice to cause kernel panics so lets avoid the loop below.
- # First set a reasonable default.
- lt_cv_sys_max_cmd_len=16384
- #
- if test -x /sbin/sysconfig; then
- case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
- *1*) lt_cv_sys_max_cmd_len=-1 ;;
- esac
- fi
- ;;
- sco3.2v5*)
- lt_cv_sys_max_cmd_len=102400
- ;;
- sysv5* | sco5v6* | sysv4.2uw2*)
- kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
- if test -n "$kargmax"; then
- lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[ ]//'`
- else
- lt_cv_sys_max_cmd_len=32768
- fi
- ;;
- *)
- lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null`
- if test -n "$lt_cv_sys_max_cmd_len"; then
- lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
- lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
- else
- # Make teststring a little bigger before we do anything with it.
- # a 1K string should be a reasonable start.
- for i in 1 2 3 4 5 6 7 8 ; do
- teststring=$teststring$teststring
- done
- SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
- # If test is not a shell built-in, we'll probably end up computing a
- # maximum length that is only half of the actual maximum length, but
- # we can't tell.
- while { test "X"`func_fallback_echo "$teststring$teststring" 2>/dev/null` \
- = "X$teststring$teststring"; } >/dev/null 2>&1 &&
- test $i != 17 # 1/2 MB should be enough
- do
- i=`expr $i + 1`
- teststring=$teststring$teststring
- done
- # Only check the string length outside the loop.
- lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1`
- teststring=
- # Add a significant safety factor because C++ compilers can tack on
- # massive amounts of additional arguments before passing them to the
- # linker. It appears as though 1/2 is a usable value.
- lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
- fi
- ;;
- esac
-
-fi
-
-if test -n $lt_cv_sys_max_cmd_len ; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sys_max_cmd_len" >&5
-$as_echo "$lt_cv_sys_max_cmd_len" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: none" >&5
-$as_echo "none" >&6; }
-fi
-max_cmd_len=$lt_cv_sys_max_cmd_len
-
-
-
-
-
-
-: ${CP="cp -f"}
-: ${MV="mv -f"}
-: ${RM="rm -f"}
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the shell understands some XSI constructs" >&5
-$as_echo_n "checking whether the shell understands some XSI constructs... " >&6; }
-# Try some XSI features
-xsi_shell=no
-( _lt_dummy="a/b/c"
- test "${_lt_dummy##*/},${_lt_dummy%/*},"${_lt_dummy%"$_lt_dummy"}, \
- = c,a/b,, \
- && eval 'test $(( 1 + 1 )) -eq 2 \
- && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \
- && xsi_shell=yes
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $xsi_shell" >&5
-$as_echo "$xsi_shell" >&6; }
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the shell understands \"+=\"" >&5
-$as_echo_n "checking whether the shell understands \"+=\"... " >&6; }
-lt_shell_append=no
-( foo=bar; set foo baz; eval "$1+=\$2" && test "$foo" = barbaz ) \
- >/dev/null 2>&1 \
- && lt_shell_append=yes
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_shell_append" >&5
-$as_echo "$lt_shell_append" >&6; }
-
-
-if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
- lt_unset=unset
-else
- lt_unset=false
-fi
-
-
-
-
-
-# test EBCDIC or ASCII
-case `echo X|tr X '\101'` in
- A) # ASCII based system
- # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr
- lt_SP2NL='tr \040 \012'
- lt_NL2SP='tr \015\012 \040\040'
- ;;
- *) # EBCDIC based system
- lt_SP2NL='tr \100 \n'
- lt_NL2SP='tr \r\n \100\100'
- ;;
-esac
-
-
-
-
-
-
-
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5
-$as_echo_n "checking for $LD option to reload object files... " >&6; }
-if ${lt_cv_ld_reload_flag+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_ld_reload_flag='-r'
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_reload_flag" >&5
-$as_echo "$lt_cv_ld_reload_flag" >&6; }
-reload_flag=$lt_cv_ld_reload_flag
-case $reload_flag in
-"" | " "*) ;;
-*) reload_flag=" $reload_flag" ;;
-esac
-reload_cmds='$LD$reload_flag -o $output$reload_objs'
-case $host_os in
- darwin*)
- if test "$GCC" = yes; then
- reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
- else
- reload_cmds='$LD$reload_flag -o $output$reload_objs'
- fi
- ;;
-esac
-
-
-
-
-
-
-
-
-
-if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args.
-set dummy ${ac_tool_prefix}objdump; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_OBJDUMP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$OBJDUMP"; then
- ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-OBJDUMP=$ac_cv_prog_OBJDUMP
-if test -n "$OBJDUMP"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
-$as_echo "$OBJDUMP" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_OBJDUMP"; then
- ac_ct_OBJDUMP=$OBJDUMP
- # Extract the first word of "objdump", so it can be a program name with args.
-set dummy objdump; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_OBJDUMP"; then
- ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_OBJDUMP="objdump"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP
-if test -n "$ac_ct_OBJDUMP"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5
-$as_echo "$ac_ct_OBJDUMP" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_OBJDUMP" = x; then
- OBJDUMP="false"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- OBJDUMP=$ac_ct_OBJDUMP
- fi
-else
- OBJDUMP="$ac_cv_prog_OBJDUMP"
-fi
-
-test -z "$OBJDUMP" && OBJDUMP=objdump
-
-
-
-
-
-
-
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to recognize dependent libraries" >&5
-$as_echo_n "checking how to recognize dependent libraries... " >&6; }
-if ${lt_cv_deplibs_check_method+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_file_magic_cmd='$MAGIC_CMD'
-lt_cv_file_magic_test_file=
-lt_cv_deplibs_check_method='unknown'
-# Need to set the preceding variable on all platforms that support
-# interlibrary dependencies.
-# 'none' -- dependencies not supported.
-# `unknown' -- same as none, but documents that we really don't know.
-# 'pass_all' -- all dependencies passed with no checks.
-# 'test_compile' -- check by making test program.
-# 'file_magic [[regex]]' -- check by looking for files in library path
-# which responds to the $file_magic_cmd with a given extended regex.
-# If you have `file' or equivalent on your system and you're not sure
-# whether `pass_all' will *always* work, you probably want this one.
-
-case $host_os in
-aix[4-9]*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-beos*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-bsdi[45]*)
- lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)'
- lt_cv_file_magic_cmd='/usr/bin/file -L'
- lt_cv_file_magic_test_file=/shlib/libc.so
- ;;
-
-cygwin*)
- # func_win32_libid is a shell function defined in ltmain.sh
- lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
- lt_cv_file_magic_cmd='func_win32_libid'
- ;;
-
-mingw* | pw32*)
- # Base MSYS/MinGW do not provide the 'file' command needed by
- # func_win32_libid shell function, so use a weaker test based on 'objdump',
- # unless we find 'file', for example because we are cross-compiling.
- # func_win32_libid assumes BSD nm, so disallow it if using MS dumpbin.
- if ( test "$lt_cv_nm_interface" = "BSD nm" && file / ) >/dev/null 2>&1; then
- lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
- lt_cv_file_magic_cmd='func_win32_libid'
- else
- lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
- lt_cv_file_magic_cmd='$OBJDUMP -f'
- fi
- ;;
-
-cegcc*)
- # use the weaker test based on 'objdump'. See mingw*.
- lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?'
- lt_cv_file_magic_cmd='$OBJDUMP -f'
- ;;
-
-darwin* | rhapsody*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-freebsd* | dragonfly*)
- if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
- case $host_cpu in
- i*86 )
- # Not sure whether the presence of OpenBSD here was a mistake.
- # Let's accept both of them until this is cleared up.
- lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library'
- lt_cv_file_magic_cmd=/usr/bin/file
- lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
- ;;
- esac
- else
- lt_cv_deplibs_check_method=pass_all
- fi
- ;;
-
-gnu*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-haiku*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-hpux10.20* | hpux11*)
- lt_cv_file_magic_cmd=/usr/bin/file
- case $host_cpu in
- ia64*)
- lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64'
- lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
- ;;
- hppa*64*)
- lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF[ -][0-9][0-9])(-bit)?( [LM]SB)? shared object( file)?[, -]* PA-RISC [0-9]\.[0-9]'
- lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
- ;;
- *)
- lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9]\.[0-9]) shared library'
- lt_cv_file_magic_test_file=/usr/lib/libc.sl
- ;;
- esac
- ;;
-
-interix[3-9]*)
- # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
- lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|\.a)$'
- ;;
-
-irix5* | irix6* | nonstopux*)
- case $LD in
- *-32|*"-32 ") libmagic=32-bit;;
- *-n32|*"-n32 ") libmagic=N32;;
- *-64|*"-64 ") libmagic=64-bit;;
- *) libmagic=never-match;;
- esac
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-# This must be Linux ELF.
-linux* | k*bsd*-gnu | kopensolaris*-gnu | uclinuxfdpiceabi)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-netbsd*)
- if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
- lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
- else
- lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$'
- fi
- ;;
-
-newos6*)
- lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)'
- lt_cv_file_magic_cmd=/usr/bin/file
- lt_cv_file_magic_test_file=/usr/lib/libnls.so
- ;;
-
-*nto* | *qnx*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-openbsd*)
- if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
- lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$'
- else
- lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
- fi
- ;;
-
-osf3* | osf4* | osf5*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-rdos*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-solaris*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-sysv4 | sysv4.3*)
- case $host_vendor in
- motorola)
- lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib) M[0-9][0-9]* Version [0-9]'
- lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
- ;;
- ncr)
- lt_cv_deplibs_check_method=pass_all
- ;;
- sequent)
- lt_cv_file_magic_cmd='/bin/file'
- lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )'
- ;;
- sni)
- lt_cv_file_magic_cmd='/bin/file'
- lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib"
- lt_cv_file_magic_test_file=/lib/libc.so
- ;;
- siemens)
- lt_cv_deplibs_check_method=pass_all
- ;;
- pc)
- lt_cv_deplibs_check_method=pass_all
- ;;
- esac
- ;;
-
-tpf*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-vxworks*)
- # Assume VxWorks cross toolchains are built on Linux, possibly
- # as canadian for Windows hosts.
- lt_cv_deplibs_check_method=pass_all
- ;;
-esac
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5
-$as_echo "$lt_cv_deplibs_check_method" >&6; }
-file_magic_cmd=$lt_cv_file_magic_cmd
-deplibs_check_method=$lt_cv_deplibs_check_method
-test -z "$deplibs_check_method" && deplibs_check_method=unknown
-
-
-
-
-
-
-
-
-
-
-
-
-plugin_option=
-plugin_names="liblto_plugin.so liblto_plugin-0.dll cyglto_plugin-0.dll"
-for plugin in $plugin_names; do
- plugin_so=`${CC} ${CFLAGS} --print-prog-name $plugin`
- if test x$plugin_so = x$plugin; then
- plugin_so=`${CC} ${CFLAGS} --print-file-name $plugin`
- fi
- if test x$plugin_so != x$plugin; then
- plugin_option="--plugin $plugin_so"
- break
- fi
-done
-
-if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
-set dummy ${ac_tool_prefix}ar; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_AR+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$AR"; then
- ac_cv_prog_AR="$AR" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_AR="${ac_tool_prefix}ar"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-AR=$ac_cv_prog_AR
-if test -n "$AR"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
-$as_echo "$AR" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_AR"; then
- ac_ct_AR=$AR
- # Extract the first word of "ar", so it can be a program name with args.
-set dummy ar; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_AR+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_AR"; then
- ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_AR="ar"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_AR=$ac_cv_prog_ac_ct_AR
-if test -n "$ac_ct_AR"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
-$as_echo "$ac_ct_AR" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_AR" = x; then
- AR="false"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- AR=$ac_ct_AR
- fi
-else
- AR="$ac_cv_prog_AR"
-fi
-
-test -z "$AR" && AR=ar
-if test -n "$plugin_option"; then
- if $AR --help 2>&1 | grep -q "\--plugin"; then
- touch conftest.c
- $AR $plugin_option rc conftest.a conftest.c
- if test "$?" != 0; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed: $AR $plugin_option rc" >&5
-$as_echo "$as_me: WARNING: Failed: $AR $plugin_option rc" >&2;}
- else
- AR="$AR $plugin_option"
- fi
- rm -f conftest.*
- fi
-fi
-test -z "$AR_FLAGS" && AR_FLAGS=cru
-
-
-
-
-
-
-
-
-
-
-
-if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
-set dummy ${ac_tool_prefix}strip; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_STRIP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$STRIP"; then
- ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_STRIP="${ac_tool_prefix}strip"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-STRIP=$ac_cv_prog_STRIP
-if test -n "$STRIP"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
-$as_echo "$STRIP" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_STRIP"; then
- ac_ct_STRIP=$STRIP
- # Extract the first word of "strip", so it can be a program name with args.
-set dummy strip; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_STRIP"; then
- ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_STRIP="strip"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
-if test -n "$ac_ct_STRIP"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
-$as_echo "$ac_ct_STRIP" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_STRIP" = x; then
- STRIP=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- STRIP=$ac_ct_STRIP
- fi
-else
- STRIP="$ac_cv_prog_STRIP"
-fi
-
-test -z "$STRIP" && STRIP=:
-
-
-
-
-
-
-if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
-set dummy ${ac_tool_prefix}ranlib; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_RANLIB+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$RANLIB"; then
- ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-RANLIB=$ac_cv_prog_RANLIB
-if test -n "$RANLIB"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
-$as_echo "$RANLIB" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_RANLIB"; then
- ac_ct_RANLIB=$RANLIB
- # Extract the first word of "ranlib", so it can be a program name with args.
-set dummy ranlib; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_RANLIB"; then
- ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_RANLIB="ranlib"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
-if test -n "$ac_ct_RANLIB"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
-$as_echo "$ac_ct_RANLIB" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_RANLIB" = x; then
- RANLIB=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- RANLIB=$ac_ct_RANLIB
- fi
-else
- RANLIB="$ac_cv_prog_RANLIB"
-fi
-
-test -z "$RANLIB" && RANLIB=:
-if test -n "$plugin_option" && test "$RANLIB" != ":"; then
- if $RANLIB --help 2>&1 | grep -q "\--plugin"; then
- RANLIB="$RANLIB $plugin_option"
- fi
-fi
-
-
-
-
-
-
-# Determine commands to create old-style static archives.
-old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs'
-old_postinstall_cmds='chmod 644 $oldlib'
-old_postuninstall_cmds=
-
-if test -n "$RANLIB"; then
- case $host_os in
- openbsd*)
- old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib"
- ;;
- *)
- old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib"
- ;;
- esac
- old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib"
-fi
-
-case $host_os in
- darwin*)
- lock_old_archive_extraction=yes ;;
- *)
- lock_old_archive_extraction=no ;;
-esac
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-# If no C compiler was specified, use CC.
-LTCC=${LTCC-"$CC"}
-
-# If no C compiler flags were specified, use CFLAGS.
-LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
-
-# Allow CC to be a program name with arguments.
-compiler=$CC
-
-
-# Check for command to grab the raw symbol name followed by C symbol from nm.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking command to parse $NM output from $compiler object" >&5
-$as_echo_n "checking command to parse $NM output from $compiler object... " >&6; }
-if ${lt_cv_sys_global_symbol_pipe+:} false; then :
- $as_echo_n "(cached) " >&6
-else
-
-# These are sane defaults that work on at least a few old systems.
-# [They come from Ultrix. What could be older than Ultrix?!! ;)]
-
-# Character class describing NM global symbol codes.
-symcode='[BCDEGRST]'
-
-# Regexp to match symbols that can be accessed directly from C.
-sympat='\([_A-Za-z][_A-Za-z0-9]*\)'
-
-# Define system-specific variables.
-case $host_os in
-aix*)
- symcode='[BCDT]'
- ;;
-cygwin* | mingw* | pw32* | cegcc*)
- symcode='[ABCDGISTW]'
- ;;
-hpux*)
- if test "$host_cpu" = ia64; then
- symcode='[ABCDEGRST]'
- fi
- ;;
-irix* | nonstopux*)
- symcode='[BCDEGRST]'
- ;;
-osf*)
- symcode='[BCDEGQRST]'
- ;;
-solaris*)
- symcode='[BCDRT]'
- ;;
-sco3.2v5*)
- symcode='[DT]'
- ;;
-sysv4.2uw2*)
- symcode='[DT]'
- ;;
-sysv5* | sco5v6* | unixware* | OpenUNIX*)
- symcode='[ABDT]'
- ;;
-sysv4)
- symcode='[DFNSTU]'
- ;;
-esac
-
-# If we're using GNU nm, then use its standard symbol codes.
-case `$NM -V 2>&1` in
-*GNU* | *'with BFD'*)
- symcode='[ABCDGIRSTW]' ;;
-esac
-
-# Transform an extracted symbol line into a proper C declaration.
-# Some systems (esp. on ia64) link data and code symbols differently,
-# so use this general approach.
-lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
-
-# Transform an extracted symbol line into symbol name and symbol address
-lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"\2\", (void *) \&\2},/p'"
-lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \(lib[^ ]*\)$/ {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"lib\2\", (void *) \&\2},/p'"
-
-# Handle CRLF in mingw tool chain
-opt_cr=
-case $build_os in
-mingw*)
- opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp
- ;;
-esac
-
-# Try without a prefix underscore, then with it.
-for ac_symprfx in "" "_"; do
-
- # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
- symxfrm="\\1 $ac_symprfx\\2 \\2"
-
- # Write the raw and C identifiers.
- if test "$lt_cv_nm_interface" = "MS dumpbin"; then
- # Fake it for dumpbin and say T for any non-static function
- # and D for any global variable.
- # Also find C++ and __fastcall symbols from MSVC++,
- # which start with @ or ?.
- lt_cv_sys_global_symbol_pipe="$AWK '"\
-" {last_section=section; section=\$ 3};"\
-" /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\
-" \$ 0!~/External *\|/{next};"\
-" / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\
-" {if(hide[section]) next};"\
-" {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\
-" {split(\$ 0, a, /\||\r/); split(a[2], s)};"\
-" s[1]~/^[@?]/{print s[1], s[1]; next};"\
-" s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\
-" ' prfx=^$ac_symprfx"
- else
- lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[ ]\($symcode$symcode*\)[ ][ ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
- fi
-
- # Check to see that the pipe works correctly.
- pipe_works=no
-
- rm -f conftest*
- cat > conftest.$ac_ext <<_LT_EOF
-#ifdef __cplusplus
-extern "C" {
-#endif
-char nm_test_var;
-void nm_test_func(void);
-void nm_test_func(void){}
-#ifdef __cplusplus
-}
-#endif
-int main(){nm_test_var='a';nm_test_func();return(0);}
-_LT_EOF
-
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
- (eval $ac_compile) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- # Now try to grab the symbols.
- nlist=conftest.nm
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist\""; } >&5
- (eval $NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && test -s "$nlist"; then
- # Try sorting and uniquifying the output.
- if sort "$nlist" | uniq > "$nlist"T; then
- mv -f "$nlist"T "$nlist"
- else
- rm -f "$nlist"T
- fi
-
- # Make sure that we snagged all the symbols we need.
- if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
- if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
- cat <<_LT_EOF > conftest.$ac_ext
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-_LT_EOF
- # Now generate the symbol file.
- eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext'
-
- cat <<_LT_EOF >> conftest.$ac_ext
-
-/* The mapping between symbol names and symbols. */
-const struct {
- const char *name;
- void *address;
-}
-lt__PROGRAM__LTX_preloaded_symbols[] =
-{
- { "@PROGRAM@", (void *) 0 },
-_LT_EOF
- $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext
- cat <<\_LT_EOF >> conftest.$ac_ext
- {0, (void *) 0}
-};
-
-/* This works around a problem in FreeBSD linker */
-#ifdef FREEBSD_WORKAROUND
-static const void *lt_preloaded_setup() {
- return lt__PROGRAM__LTX_preloaded_symbols;
-}
-#endif
-
-#ifdef __cplusplus
-}
-#endif
-_LT_EOF
- # Now try linking the two files.
- mv conftest.$ac_objext conftstm.$ac_objext
- lt_save_LIBS="$LIBS"
- lt_save_CFLAGS="$CFLAGS"
- LIBS="conftstm.$ac_objext"
- CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag"
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
- (eval $ac_link) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && test -s conftest${ac_exeext}; then
- pipe_works=yes
- fi
- LIBS="$lt_save_LIBS"
- CFLAGS="$lt_save_CFLAGS"
- else
- echo "cannot find nm_test_func in $nlist" >&5
- fi
- else
- echo "cannot find nm_test_var in $nlist" >&5
- fi
- else
- echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5
- fi
- else
- echo "$progname: failed program was:" >&5
- cat conftest.$ac_ext >&5
- fi
- rm -rf conftest* conftst*
-
- # Do not use the global_symbol_pipe unless it works.
- if test "$pipe_works" = yes; then
- break
- else
- lt_cv_sys_global_symbol_pipe=
- fi
-done
-
-fi
-
-if test -z "$lt_cv_sys_global_symbol_pipe"; then
- lt_cv_sys_global_symbol_to_cdecl=
-fi
-if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
-$as_echo "failed" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
-$as_echo "ok" >&6; }
-fi
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-# Check whether --enable-libtool-lock was given.
-if test "${enable_libtool_lock+set}" = set; then :
- enableval=$enable_libtool_lock;
-fi
-
-test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
-
-# Some flags need to be propagated to the compiler or linker for good
-# libtool support.
-case $host in
-ia64-*-hpux*)
- # Find out which ABI we are using.
- echo 'int i;' > conftest.$ac_ext
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
- (eval $ac_compile) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- case `/usr/bin/file conftest.$ac_objext` in
- *ELF-32*)
- HPUX_IA64_MODE="32"
- ;;
- *ELF-64*)
- HPUX_IA64_MODE="64"
- ;;
- esac
- fi
- rm -rf conftest*
- ;;
-*-*-irix6*)
- # Find out which ABI we are using.
- echo '#line '$LINENO' "configure"' > conftest.$ac_ext
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
- (eval $ac_compile) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- if test "$lt_cv_prog_gnu_ld" = yes; then
- case `/usr/bin/file conftest.$ac_objext` in
- *32-bit*)
- LD="${LD-ld} -melf32bsmip"
- ;;
- *N32*)
- LD="${LD-ld} -melf32bmipn32"
- ;;
- *64-bit*)
- LD="${LD-ld} -melf64bmip"
- ;;
- esac
- else
- case `/usr/bin/file conftest.$ac_objext` in
- *32-bit*)
- LD="${LD-ld} -32"
- ;;
- *N32*)
- LD="${LD-ld} -n32"
- ;;
- *64-bit*)
- LD="${LD-ld} -64"
- ;;
- esac
- fi
- fi
- rm -rf conftest*
- ;;
-
-x86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \
-s390*-*linux*|s390*-*tpf*|sparc*-*linux*)
- # Find out which ABI we are using.
- echo 'int i;' > conftest.$ac_ext
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
- (eval $ac_compile) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- case `/usr/bin/file conftest.o` in
- *32-bit*)
- case $host in
- x86_64-*kfreebsd*-gnu)
- LD="${LD-ld} -m elf_i386_fbsd"
- ;;
- x86_64-*linux*)
- case `/usr/bin/file conftest.o` in
- *x86-64*)
- LD="${LD-ld} -m elf32_x86_64"
- ;;
- *)
- LD="${LD-ld} -m elf_i386"
- ;;
- esac
- ;;
- powerpc64le-*linux*)
- LD="${LD-ld} -m elf32lppclinux"
- ;;
- powerpc64-*linux*)
- LD="${LD-ld} -m elf32ppclinux"
- ;;
- s390x-*linux*)
- LD="${LD-ld} -m elf_s390"
- ;;
- sparc64-*linux*)
- LD="${LD-ld} -m elf32_sparc"
- ;;
- esac
- ;;
- *64-bit*)
- case $host in
- x86_64-*kfreebsd*-gnu)
- LD="${LD-ld} -m elf_x86_64_fbsd"
- ;;
- x86_64-*linux*)
- LD="${LD-ld} -m elf_x86_64"
- ;;
- powerpcle-*linux*)
- LD="${LD-ld} -m elf64lppc"
- ;;
- powerpc-*linux*)
- LD="${LD-ld} -m elf64ppc"
- ;;
- s390*-*linux*|s390*-*tpf*)
- LD="${LD-ld} -m elf64_s390"
- ;;
- sparc*-*linux*)
- LD="${LD-ld} -m elf64_sparc"
- ;;
- esac
- ;;
- esac
- fi
- rm -rf conftest*
- ;;
-
-*-*-sco3.2v5*)
- # On SCO OpenServer 5, we need -belf to get full-featured binaries.
- SAVE_CFLAGS="$CFLAGS"
- CFLAGS="$CFLAGS -belf"
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler needs -belf" >&5
-$as_echo_n "checking whether the C compiler needs -belf... " >&6; }
-if ${lt_cv_cc_needs_belf+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- lt_cv_cc_needs_belf=yes
-else
- lt_cv_cc_needs_belf=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_cc_needs_belf" >&5
-$as_echo "$lt_cv_cc_needs_belf" >&6; }
- if test x"$lt_cv_cc_needs_belf" != x"yes"; then
- # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
- CFLAGS="$SAVE_CFLAGS"
- fi
- ;;
-sparc*-*solaris*)
- # Find out which ABI we are using.
- echo 'int i;' > conftest.$ac_ext
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
- (eval $ac_compile) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- case `/usr/bin/file conftest.o` in
- *64-bit*)
- case $lt_cv_prog_gnu_ld in
- yes*) LD="${LD-ld} -m elf64_sparc" ;;
- *)
- if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then
- LD="${LD-ld} -64"
- fi
- ;;
- esac
- ;;
- esac
- fi
- rm -rf conftest*
- ;;
-esac
-
-need_locks="$enable_libtool_lock"
-
-
- case $host_os in
- rhapsody* | darwin*)
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}dsymutil", so it can be a program name with args.
-set dummy ${ac_tool_prefix}dsymutil; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_DSYMUTIL+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$DSYMUTIL"; then
- ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_DSYMUTIL="${ac_tool_prefix}dsymutil"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-DSYMUTIL=$ac_cv_prog_DSYMUTIL
-if test -n "$DSYMUTIL"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5
-$as_echo "$DSYMUTIL" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_DSYMUTIL"; then
- ac_ct_DSYMUTIL=$DSYMUTIL
- # Extract the first word of "dsymutil", so it can be a program name with args.
-set dummy dsymutil; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_DSYMUTIL+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_DSYMUTIL"; then
- ac_cv_prog_ac_ct_DSYMUTIL="$ac_ct_DSYMUTIL" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_DSYMUTIL="dsymutil"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_DSYMUTIL=$ac_cv_prog_ac_ct_DSYMUTIL
-if test -n "$ac_ct_DSYMUTIL"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DSYMUTIL" >&5
-$as_echo "$ac_ct_DSYMUTIL" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_DSYMUTIL" = x; then
- DSYMUTIL=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- DSYMUTIL=$ac_ct_DSYMUTIL
- fi
-else
- DSYMUTIL="$ac_cv_prog_DSYMUTIL"
-fi
-
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}nmedit", so it can be a program name with args.
-set dummy ${ac_tool_prefix}nmedit; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_NMEDIT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$NMEDIT"; then
- ac_cv_prog_NMEDIT="$NMEDIT" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_NMEDIT="${ac_tool_prefix}nmedit"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-NMEDIT=$ac_cv_prog_NMEDIT
-if test -n "$NMEDIT"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NMEDIT" >&5
-$as_echo "$NMEDIT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_NMEDIT"; then
- ac_ct_NMEDIT=$NMEDIT
- # Extract the first word of "nmedit", so it can be a program name with args.
-set dummy nmedit; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_NMEDIT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_NMEDIT"; then
- ac_cv_prog_ac_ct_NMEDIT="$ac_ct_NMEDIT" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_NMEDIT="nmedit"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_NMEDIT=$ac_cv_prog_ac_ct_NMEDIT
-if test -n "$ac_ct_NMEDIT"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NMEDIT" >&5
-$as_echo "$ac_ct_NMEDIT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_NMEDIT" = x; then
- NMEDIT=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- NMEDIT=$ac_ct_NMEDIT
- fi
-else
- NMEDIT="$ac_cv_prog_NMEDIT"
-fi
-
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}lipo", so it can be a program name with args.
-set dummy ${ac_tool_prefix}lipo; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_LIPO+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$LIPO"; then
- ac_cv_prog_LIPO="$LIPO" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_LIPO="${ac_tool_prefix}lipo"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-LIPO=$ac_cv_prog_LIPO
-if test -n "$LIPO"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5
-$as_echo "$LIPO" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_LIPO"; then
- ac_ct_LIPO=$LIPO
- # Extract the first word of "lipo", so it can be a program name with args.
-set dummy lipo; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_LIPO+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_LIPO"; then
- ac_cv_prog_ac_ct_LIPO="$ac_ct_LIPO" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_LIPO="lipo"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_LIPO=$ac_cv_prog_ac_ct_LIPO
-if test -n "$ac_ct_LIPO"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LIPO" >&5
-$as_echo "$ac_ct_LIPO" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_LIPO" = x; then
- LIPO=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- LIPO=$ac_ct_LIPO
- fi
-else
- LIPO="$ac_cv_prog_LIPO"
-fi
-
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}otool", so it can be a program name with args.
-set dummy ${ac_tool_prefix}otool; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_OTOOL+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$OTOOL"; then
- ac_cv_prog_OTOOL="$OTOOL" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_OTOOL="${ac_tool_prefix}otool"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-OTOOL=$ac_cv_prog_OTOOL
-if test -n "$OTOOL"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5
-$as_echo "$OTOOL" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_OTOOL"; then
- ac_ct_OTOOL=$OTOOL
- # Extract the first word of "otool", so it can be a program name with args.
-set dummy otool; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_OTOOL+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_OTOOL"; then
- ac_cv_prog_ac_ct_OTOOL="$ac_ct_OTOOL" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_OTOOL="otool"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_OTOOL=$ac_cv_prog_ac_ct_OTOOL
-if test -n "$ac_ct_OTOOL"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL" >&5
-$as_echo "$ac_ct_OTOOL" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_OTOOL" = x; then
- OTOOL=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- OTOOL=$ac_ct_OTOOL
- fi
-else
- OTOOL="$ac_cv_prog_OTOOL"
-fi
-
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}otool64", so it can be a program name with args.
-set dummy ${ac_tool_prefix}otool64; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_OTOOL64+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$OTOOL64"; then
- ac_cv_prog_OTOOL64="$OTOOL64" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_OTOOL64="${ac_tool_prefix}otool64"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-OTOOL64=$ac_cv_prog_OTOOL64
-if test -n "$OTOOL64"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL64" >&5
-$as_echo "$OTOOL64" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_OTOOL64"; then
- ac_ct_OTOOL64=$OTOOL64
- # Extract the first word of "otool64", so it can be a program name with args.
-set dummy otool64; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_OTOOL64+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_OTOOL64"; then
- ac_cv_prog_ac_ct_OTOOL64="$ac_ct_OTOOL64" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_OTOOL64="otool64"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_OTOOL64=$ac_cv_prog_ac_ct_OTOOL64
-if test -n "$ac_ct_OTOOL64"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL64" >&5
-$as_echo "$ac_ct_OTOOL64" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_OTOOL64" = x; then
- OTOOL64=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- OTOOL64=$ac_ct_OTOOL64
- fi
-else
- OTOOL64="$ac_cv_prog_OTOOL64"
-fi
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -single_module linker flag" >&5
-$as_echo_n "checking for -single_module linker flag... " >&6; }
-if ${lt_cv_apple_cc_single_mod+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_apple_cc_single_mod=no
- if test -z "${LT_MULTI_MODULE}"; then
- # By default we will add the -single_module flag. You can override
- # by either setting the environment variable LT_MULTI_MODULE
- # non-empty at configure time, or by adding -multi_module to the
- # link flags.
- rm -rf libconftest.dylib*
- echo "int foo(void){return 1;}" > conftest.c
- echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
--dynamiclib -Wl,-single_module conftest.c" >&5
- $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
- -dynamiclib -Wl,-single_module conftest.c 2>conftest.err
- _lt_result=$?
- if test -f libconftest.dylib && test ! -s conftest.err && test $_lt_result = 0; then
- lt_cv_apple_cc_single_mod=yes
- else
- cat conftest.err >&5
- fi
- rm -rf libconftest.dylib*
- rm -f conftest.*
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_apple_cc_single_mod" >&5
-$as_echo "$lt_cv_apple_cc_single_mod" >&6; }
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -exported_symbols_list linker flag" >&5
-$as_echo_n "checking for -exported_symbols_list linker flag... " >&6; }
-if ${lt_cv_ld_exported_symbols_list+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_ld_exported_symbols_list=no
- save_LDFLAGS=$LDFLAGS
- echo "_main" > conftest.sym
- LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- lt_cv_ld_exported_symbols_list=yes
-else
- lt_cv_ld_exported_symbols_list=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LDFLAGS="$save_LDFLAGS"
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_exported_symbols_list" >&5
-$as_echo "$lt_cv_ld_exported_symbols_list" >&6; }
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -force_load linker flag" >&5
-$as_echo_n "checking for -force_load linker flag... " >&6; }
-if ${lt_cv_ld_force_load+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_ld_force_load=no
- cat > conftest.c << _LT_EOF
-int forced_loaded() { return 2;}
-_LT_EOF
- echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&5
- $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5
- echo "$AR cru libconftest.a conftest.o" >&5
- $AR cru libconftest.a conftest.o 2>&5
- cat > conftest.c << _LT_EOF
-int main() { return 0;}
-_LT_EOF
- echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&5
- $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err
- _lt_result=$?
- if test -f conftest && test ! -s conftest.err && test $_lt_result = 0 && $GREP forced_load conftest 2>&1 >/dev/null; then
- lt_cv_ld_force_load=yes
- else
- cat conftest.err >&5
- fi
- rm -f conftest.err libconftest.a conftest conftest.c
- rm -rf conftest.dSYM
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_force_load" >&5
-$as_echo "$lt_cv_ld_force_load" >&6; }
- # Allow for Darwin 4-7 (macOS 10.0-10.3) although these are not expect to
- # build without first building modern cctools / linker.
- case $host_cpu-$host_os in
- *-rhapsody* | *-darwin1.[012])
- _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;;
- *-darwin1.*)
- _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
- *-darwin*)
- # darwin 5.x (macOS 10.1) onwards we only need to adjust when the
- # deployment target is forced to an earlier version.
- case ${MACOSX_DEPLOYMENT_TARGET-UNSET},$host in
- UNSET,*-darwin[89]*|UNSET,*-darwin[12][0123456789]*)
- ;;
- 10.[012][,.]*)
- _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
- ;;
- *)
- ;;
- esac
- ;;
- esac
- if test "$lt_cv_apple_cc_single_mod" = "yes"; then
- _lt_dar_single_mod='$single_module'
- fi
- if test "$lt_cv_ld_exported_symbols_list" = "yes"; then
- _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym'
- else
- _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}'
- fi
- if test "$DSYMUTIL" != ":" && test "$lt_cv_ld_force_load" = "no"; then
- _lt_dsymutil='~$DSYMUTIL $lib || :'
- else
- _lt_dsymutil=
- fi
- ;;
- esac
-
-for ac_header in dlfcn.h
-do :
- ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default
-"
-if test "x$ac_cv_header_dlfcn_h" = xyes; then :
- cat >>confdefs.h <<_ACEOF
-#define HAVE_DLFCN_H 1
-_ACEOF
-
-fi
-
-done
-
-
-
-
-
-# Set options
-enable_dlopen=yes
-
-
-
-
- enable_win32_dll=no
-
-
-
- # Check whether --enable-static was given.
-if test "${enable_static+set}" = set; then :
- enableval=$enable_static; p=${PACKAGE-default}
- case $enableval in
- yes) enable_static=yes ;;
- no) enable_static=no ;;
- *)
- enable_static=no
- # Look at the argument we got. We use all the common list separators.
- lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
- for pkg in $enableval; do
- IFS="$lt_save_ifs"
- if test "X$pkg" = "X$p"; then
- enable_static=yes
- fi
- done
- IFS="$lt_save_ifs"
- ;;
- esac
-else
- enable_static=yes
-fi
-
-
-
-
-
-
-
-
-
-
-# Check whether --with-pic was given.
-if test "${with_pic+set}" = set; then :
- withval=$with_pic; pic_mode="$withval"
-else
- pic_mode=default
-fi
-
-
-test -z "$pic_mode" && pic_mode=default
-
-
-
-
-
-
-
- # Check whether --enable-fast-install was given.
-if test "${enable_fast_install+set}" = set; then :
- enableval=$enable_fast_install; p=${PACKAGE-default}
- case $enableval in
- yes) enable_fast_install=yes ;;
- no) enable_fast_install=no ;;
- *)
- enable_fast_install=no
- # Look at the argument we got. We use all the common list separators.
- lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
- for pkg in $enableval; do
- IFS="$lt_save_ifs"
- if test "X$pkg" = "X$p"; then
- enable_fast_install=yes
- fi
- done
- IFS="$lt_save_ifs"
- ;;
- esac
-else
- enable_fast_install=yes
-fi
-
-
-
-
-
-
-
-
-
-
-
-# This can be used to rebuild libtool when needed
-LIBTOOL_DEPS="$ltmain"
-
-# Always use our own libtool.
-LIBTOOL='$(SHELL) $(top_builddir)/libtool'
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-test -z "$LN_S" && LN_S="ln -s"
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-if test -n "${ZSH_VERSION+set}" ; then
- setopt NO_GLOB_SUBST
-fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for objdir" >&5
-$as_echo_n "checking for objdir... " >&6; }
-if ${lt_cv_objdir+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- rm -f .libs 2>/dev/null
-mkdir .libs 2>/dev/null
-if test -d .libs; then
- lt_cv_objdir=.libs
-else
- # MS-DOS does not allow filenames that begin with a dot.
- lt_cv_objdir=_libs
-fi
-rmdir .libs 2>/dev/null
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_objdir" >&5
-$as_echo "$lt_cv_objdir" >&6; }
-objdir=$lt_cv_objdir
-
-
-
-
-
-cat >>confdefs.h <<_ACEOF
-#define LT_OBJDIR "$lt_cv_objdir/"
-_ACEOF
-
-
-
-
-case $host_os in
-aix3*)
- # AIX sometimes has problems with the GCC collect2 program. For some
- # reason, if we set the COLLECT_NAMES environment variable, the problems
- # vanish in a puff of smoke.
- if test "X${COLLECT_NAMES+set}" != Xset; then
- COLLECT_NAMES=
- export COLLECT_NAMES
- fi
- ;;
-esac
-
-# Global variables:
-ofile=libtool
-can_build_shared=yes
-
-# All known linkers require a `.a' archive for static linking (except MSVC,
-# which needs '.lib').
-libext=a
-
-with_gnu_ld="$lt_cv_prog_gnu_ld"
-
-old_CC="$CC"
-old_CFLAGS="$CFLAGS"
-
-# Set sane defaults for various variables
-test -z "$CC" && CC=cc
-test -z "$LTCC" && LTCC=$CC
-test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
-test -z "$LD" && LD=ld
-test -z "$ac_objext" && ac_objext=o
-
-for cc_temp in $compiler""; do
- case $cc_temp in
- compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
- distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
- \-*) ;;
- *) break;;
- esac
-done
-cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
-
-
-# Only perform the check for file, if the check method requires it
-test -z "$MAGIC_CMD" && MAGIC_CMD=file
-case $deplibs_check_method in
-file_magic*)
- if test "$file_magic_cmd" = '$MAGIC_CMD'; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ac_tool_prefix}file" >&5
-$as_echo_n "checking for ${ac_tool_prefix}file... " >&6; }
-if ${lt_cv_path_MAGIC_CMD+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $MAGIC_CMD in
-[\\/*] | ?:[\\/]*)
- lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
- ;;
-*)
- lt_save_MAGIC_CMD="$MAGIC_CMD"
- lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
- ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
- for ac_dir in $ac_dummy; do
- IFS="$lt_save_ifs"
- test -z "$ac_dir" && ac_dir=.
- if test -f $ac_dir/${ac_tool_prefix}file; then
- lt_cv_path_MAGIC_CMD="$ac_dir/${ac_tool_prefix}file"
- if test -n "$file_magic_test_file"; then
- case $deplibs_check_method in
- "file_magic "*)
- file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
- MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
- if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
- $EGREP "$file_magic_regex" > /dev/null; then
- :
- else
- cat <<_LT_EOF 1>&2
-
-*** Warning: the command libtool uses to detect shared libraries,
-*** $file_magic_cmd, produces output that libtool cannot recognize.
-*** The result is that libtool may fail to recognize shared libraries
-*** as such. This will affect the creation of libtool libraries that
-*** depend on shared libraries, but programs linked with such libtool
-*** libraries will work regardless of this problem. Nevertheless, you
-*** may want to report the problem to your system manager and/or to
-*** bug-libtool@gnu.org
-
-_LT_EOF
- fi ;;
- esac
- fi
- break
- fi
- done
- IFS="$lt_save_ifs"
- MAGIC_CMD="$lt_save_MAGIC_CMD"
- ;;
-esac
-fi
-
-MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
-if test -n "$MAGIC_CMD"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5
-$as_echo "$MAGIC_CMD" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-
-
-
-if test -z "$lt_cv_path_MAGIC_CMD"; then
- if test -n "$ac_tool_prefix"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for file" >&5
-$as_echo_n "checking for file... " >&6; }
-if ${lt_cv_path_MAGIC_CMD+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $MAGIC_CMD in
-[\\/*] | ?:[\\/]*)
- lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
- ;;
-*)
- lt_save_MAGIC_CMD="$MAGIC_CMD"
- lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
- ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
- for ac_dir in $ac_dummy; do
- IFS="$lt_save_ifs"
- test -z "$ac_dir" && ac_dir=.
- if test -f $ac_dir/file; then
- lt_cv_path_MAGIC_CMD="$ac_dir/file"
- if test -n "$file_magic_test_file"; then
- case $deplibs_check_method in
- "file_magic "*)
- file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
- MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
- if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
- $EGREP "$file_magic_regex" > /dev/null; then
- :
- else
- cat <<_LT_EOF 1>&2
-
-*** Warning: the command libtool uses to detect shared libraries,
-*** $file_magic_cmd, produces output that libtool cannot recognize.
-*** The result is that libtool may fail to recognize shared libraries
-*** as such. This will affect the creation of libtool libraries that
-*** depend on shared libraries, but programs linked with such libtool
-*** libraries will work regardless of this problem. Nevertheless, you
-*** may want to report the problem to your system manager and/or to
-*** bug-libtool@gnu.org
-
-_LT_EOF
- fi ;;
- esac
- fi
- break
- fi
- done
- IFS="$lt_save_ifs"
- MAGIC_CMD="$lt_save_MAGIC_CMD"
- ;;
-esac
-fi
-
-MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
-if test -n "$MAGIC_CMD"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5
-$as_echo "$MAGIC_CMD" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- else
- MAGIC_CMD=:
- fi
-fi
-
- fi
- ;;
-esac
-
-# Use C for the default configuration in the libtool script
-
-lt_save_CC="$CC"
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-
-# Source file extension for C test sources.
-ac_ext=c
-
-# Object file extension for compiled C test sources.
-objext=o
-objext=$objext
-
-# Code to be used in simple compile tests
-lt_simple_compile_test_code="int some_variable = 0;"
-
-# Code to be used in simple link tests
-lt_simple_link_test_code='int main(){return(0);}'
-
-
-
-
-
-
-
-# If no C compiler was specified, use CC.
-LTCC=${LTCC-"$CC"}
-
-# If no C compiler flags were specified, use CFLAGS.
-LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
-
-# Allow CC to be a program name with arguments.
-compiler=$CC
-
-# Save the default compiler, since it gets overwritten when the other
-# tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP.
-compiler_DEFAULT=$CC
-
-# save warnings/boilerplate of simple test code
-ac_outfile=conftest.$ac_objext
-echo "$lt_simple_compile_test_code" >conftest.$ac_ext
-eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
-_lt_compiler_boilerplate=`cat conftest.err`
-$RM conftest*
-
-ac_outfile=conftest.$ac_objext
-echo "$lt_simple_link_test_code" >conftest.$ac_ext
-eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
-_lt_linker_boilerplate=`cat conftest.err`
-$RM -r conftest*
-
-
-## CAVEAT EMPTOR:
-## There is no encapsulation within the following macros, do not change
-## the running order or otherwise move them around unless you know exactly
-## what you are doing...
-if test -n "$compiler"; then
-
-lt_prog_compiler_no_builtin_flag=
-
-if test "$GCC" = yes; then
- case $cc_basename in
- nvcc*)
- lt_prog_compiler_no_builtin_flag=' -Xcompiler -fno-builtin' ;;
- *)
- lt_prog_compiler_no_builtin_flag=' -fno-builtin' ;;
- esac
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -fno-rtti -fno-exceptions" >&5
-$as_echo_n "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; }
-if ${lt_cv_prog_compiler_rtti_exceptions+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_prog_compiler_rtti_exceptions=no
- ac_outfile=conftest.$ac_objext
- echo "$lt_simple_compile_test_code" > conftest.$ac_ext
- lt_compiler_flag="-fno-rtti -fno-exceptions"
- # Insert the option either (1) after the last *FLAGS variable, or
- # (2) before a word containing "conftest.", or (3) at the end.
- # Note that $ac_compile itself does not contain backslashes and begins
- # with a dollar sign (not a hyphen), so the echo should work correctly.
- # The option is referenced via a variable to avoid confusing sed.
- lt_compile=`echo "$ac_compile" | $SED \
- -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
- -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
- -e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
- (eval "$lt_compile" 2>conftest.err)
- ac_status=$?
- cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- if (exit $ac_status) && test -s "$ac_outfile"; then
- # The compiler can only warn and ignore the option if not recognized
- # So say no if there are warnings other than the usual output.
- $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
- $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
- if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
- lt_cv_prog_compiler_rtti_exceptions=yes
- fi
- fi
- $RM conftest*
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_rtti_exceptions" >&5
-$as_echo "$lt_cv_prog_compiler_rtti_exceptions" >&6; }
-
-if test x"$lt_cv_prog_compiler_rtti_exceptions" = xyes; then
- lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions"
-else
- :
-fi
-
-fi
-
-
-
-
-
-
- lt_prog_compiler_wl=
-lt_prog_compiler_pic=
-lt_prog_compiler_static=
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
-$as_echo_n "checking for $compiler option to produce PIC... " >&6; }
-
- if test "$GCC" = yes; then
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_static='-static'
-
- case $host_os in
- aix*)
- # All AIX code is PIC.
- if test "$host_cpu" = ia64; then
- # AIX 5 now supports IA64 processor
- lt_prog_compiler_static='-Bstatic'
- fi
- lt_prog_compiler_pic='-fPIC'
- ;;
-
- amigaos*)
- case $host_cpu in
- powerpc)
- # see comment about AmigaOS4 .so support
- lt_prog_compiler_pic='-fPIC'
- ;;
- m68k)
- # FIXME: we need at least 68020 code to build shared libraries, but
- # adding the `-m68020' flag to GCC prevents building anything better,
- # like `-m68040'.
- lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4'
- ;;
- esac
- ;;
-
- beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
- # PIC is the default for these OSes.
- ;;
-
- mingw* | cygwin* | pw32* | os2* | cegcc*)
- # This hack is so that the source file can tell whether it is being
- # built for inclusion in a dll (and should export symbols for example).
- # Although the cygwin gcc ignores -fPIC, still need this for old-style
- # (--disable-auto-import) libraries
- lt_prog_compiler_pic='-DDLL_EXPORT'
- ;;
-
- darwin* | rhapsody*)
- # PIC is the default on this platform
- # Common symbols not allowed in MH_DYLIB files
- lt_prog_compiler_pic='-fno-common'
- ;;
-
- haiku*)
- # PIC is the default for Haiku.
- # The "-static" flag exists, but is broken.
- lt_prog_compiler_static=
- ;;
-
- hpux*)
- # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
- # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag
- # sets the default TLS model and affects inlining.
- case $host_cpu in
- hppa*64*)
- # +Z the default
- ;;
- *)
- lt_prog_compiler_pic='-fPIC'
- ;;
- esac
- ;;
-
- interix[3-9]*)
- # Interix 3.x gcc -fpic/-fPIC options generate broken code.
- # Instead, we relocate shared libraries at runtime.
- ;;
-
- msdosdjgpp*)
- # Just because we use GCC doesn't mean we suddenly get shared libraries
- # on systems that don't support them.
- lt_prog_compiler_can_build_shared=no
- enable_shared=no
- ;;
-
- *nto* | *qnx*)
- # QNX uses GNU C++, but need to define -shared option too, otherwise
- # it will coredump.
- lt_prog_compiler_pic='-fPIC -shared'
- ;;
-
- sysv4*MP*)
- if test -d /usr/nec; then
- lt_prog_compiler_pic=-Kconform_pic
- fi
- ;;
-
- *)
- lt_prog_compiler_pic='-fPIC'
- ;;
- esac
-
- case $cc_basename in
- nvcc*) # Cuda Compiler Driver 2.2
- lt_prog_compiler_wl='-Xlinker '
- lt_prog_compiler_pic='-Xcompiler -fPIC'
- ;;
- esac
- else
- # PORTME Check for flag to pass linker flags through the system compiler.
- case $host_os in
- aix*)
- lt_prog_compiler_wl='-Wl,'
- if test "$host_cpu" = ia64; then
- # AIX 5 now supports IA64 processor
- lt_prog_compiler_static='-Bstatic'
- else
- lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp'
- fi
- ;;
-
- mingw* | cygwin* | pw32* | os2* | cegcc*)
- # This hack is so that the source file can tell whether it is being
- # built for inclusion in a dll (and should export symbols for example).
- lt_prog_compiler_pic='-DDLL_EXPORT'
- ;;
-
- hpux9* | hpux10* | hpux11*)
- lt_prog_compiler_wl='-Wl,'
- # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
- # not for PA HP-UX.
- case $host_cpu in
- hppa*64*|ia64*)
- # +Z the default
- ;;
- *)
- lt_prog_compiler_pic='+Z'
- ;;
- esac
- # Is there a better lt_prog_compiler_static that works with the bundled CC?
- lt_prog_compiler_static='${wl}-a ${wl}archive'
- ;;
-
- irix5* | irix6* | nonstopux*)
- lt_prog_compiler_wl='-Wl,'
- # PIC (with -KPIC) is the default.
- lt_prog_compiler_static='-non_shared'
- ;;
-
- linux* | k*bsd*-gnu | kopensolaris*-gnu)
- case $cc_basename in
- # old Intel for x86_64 which still supported -KPIC.
- ecc*)
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_pic='-KPIC'
- lt_prog_compiler_static='-static'
- ;;
- # icc used to be incompatible with GCC.
- # ICC 10 doesn't accept -KPIC any more.
- icc* | ifort*)
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_pic='-fPIC'
- lt_prog_compiler_static='-static'
- ;;
- # Lahey Fortran 8.1.
- lf95*)
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_pic='--shared'
- lt_prog_compiler_static='--static'
- ;;
- pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
- # Portland Group compilers (*not* the Pentium gcc compiler,
- # which looks to be a dead project)
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_pic='-fpic'
- lt_prog_compiler_static='-Bstatic'
- ;;
- ccc*)
- lt_prog_compiler_wl='-Wl,'
- # All Alpha code is PIC.
- lt_prog_compiler_static='-non_shared'
- ;;
- xl* | bgxl* | bgf* | mpixl*)
- # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_pic='-qpic'
- lt_prog_compiler_static='-qstaticlink'
- ;;
- *)
- case `$CC -V 2>&1 | sed 5q` in
- *Sun\ F* | *Sun*Fortran*)
- # Sun Fortran 8.3 passes all unrecognized flags to the linker
- lt_prog_compiler_pic='-KPIC'
- lt_prog_compiler_static='-Bstatic'
- lt_prog_compiler_wl=''
- ;;
- *Sun\ C*)
- # Sun C 5.9
- lt_prog_compiler_pic='-KPIC'
- lt_prog_compiler_static='-Bstatic'
- lt_prog_compiler_wl='-Wl,'
- ;;
- esac
- ;;
- esac
- ;;
-
- newsos6)
- lt_prog_compiler_pic='-KPIC'
- lt_prog_compiler_static='-Bstatic'
- ;;
-
- *nto* | *qnx*)
- # QNX uses GNU C++, but need to define -shared option too, otherwise
- # it will coredump.
- lt_prog_compiler_pic='-fPIC -shared'
- ;;
-
- osf3* | osf4* | osf5*)
- lt_prog_compiler_wl='-Wl,'
- # All OSF/1 code is PIC.
- lt_prog_compiler_static='-non_shared'
- ;;
-
- rdos*)
- lt_prog_compiler_static='-non_shared'
- ;;
-
- solaris*)
- lt_prog_compiler_pic='-KPIC'
- lt_prog_compiler_static='-Bstatic'
- case $cc_basename in
- f77* | f90* | f95*)
- lt_prog_compiler_wl='-Qoption ld ';;
- *)
- lt_prog_compiler_wl='-Wl,';;
- esac
- ;;
-
- sunos4*)
- lt_prog_compiler_wl='-Qoption ld '
- lt_prog_compiler_pic='-PIC'
- lt_prog_compiler_static='-Bstatic'
- ;;
-
- sysv4 | sysv4.2uw2* | sysv4.3*)
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_pic='-KPIC'
- lt_prog_compiler_static='-Bstatic'
- ;;
-
- sysv4*MP*)
- if test -d /usr/nec ;then
- lt_prog_compiler_pic='-Kconform_pic'
- lt_prog_compiler_static='-Bstatic'
- fi
- ;;
-
- sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_pic='-KPIC'
- lt_prog_compiler_static='-Bstatic'
- ;;
-
- unicos*)
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_can_build_shared=no
- ;;
-
- uts4*)
- lt_prog_compiler_pic='-pic'
- lt_prog_compiler_static='-Bstatic'
- ;;
-
- *)
- lt_prog_compiler_can_build_shared=no
- ;;
- esac
- fi
-
-case $host_os in
- # For platforms which do not support PIC, -DPIC is meaningless:
- *djgpp*)
- lt_prog_compiler_pic=
- ;;
- *)
- lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC"
- ;;
-esac
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_prog_compiler_pic" >&5
-$as_echo "$lt_prog_compiler_pic" >&6; }
-
-
-
-
-
-
-#
-# Check to make sure the PIC flag actually works.
-#
-if test -n "$lt_prog_compiler_pic"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5
-$as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic works... " >&6; }
-if ${lt_cv_prog_compiler_pic_works+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_prog_compiler_pic_works=no
- ac_outfile=conftest.$ac_objext
- echo "$lt_simple_compile_test_code" > conftest.$ac_ext
- lt_compiler_flag="$lt_prog_compiler_pic -DPIC"
- # Insert the option either (1) after the last *FLAGS variable, or
- # (2) before a word containing "conftest.", or (3) at the end.
- # Note that $ac_compile itself does not contain backslashes and begins
- # with a dollar sign (not a hyphen), so the echo should work correctly.
- # The option is referenced via a variable to avoid confusing sed.
- lt_compile=`echo "$ac_compile" | $SED \
- -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
- -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
- -e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
- (eval "$lt_compile" 2>conftest.err)
- ac_status=$?
- cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- if (exit $ac_status) && test -s "$ac_outfile"; then
- # The compiler can only warn and ignore the option if not recognized
- # So say no if there are warnings other than the usual output.
- $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
- $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
- if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
- lt_cv_prog_compiler_pic_works=yes
- fi
- fi
- $RM conftest*
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works" >&5
-$as_echo "$lt_cv_prog_compiler_pic_works" >&6; }
-
-if test x"$lt_cv_prog_compiler_pic_works" = xyes; then
- case $lt_prog_compiler_pic in
- "" | " "*) ;;
- *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;;
- esac
-else
- lt_prog_compiler_pic=
- lt_prog_compiler_can_build_shared=no
-fi
-
-fi
-
-
-
-
-
-
-#
-# Check to make sure the static flag actually works.
-#
-wl=$lt_prog_compiler_wl eval lt_tmp_static_flag=\"$lt_prog_compiler_static\"
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5
-$as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; }
-if ${lt_cv_prog_compiler_static_works+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_prog_compiler_static_works=no
- save_LDFLAGS="$LDFLAGS"
- LDFLAGS="$LDFLAGS $lt_tmp_static_flag"
- echo "$lt_simple_link_test_code" > conftest.$ac_ext
- if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
- # The linker can only warn and ignore the option if not recognized
- # So say no if there are warnings
- if test -s conftest.err; then
- # Append any errors to the config.log.
- cat conftest.err 1>&5
- $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
- $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
- if diff conftest.exp conftest.er2 >/dev/null; then
- lt_cv_prog_compiler_static_works=yes
- fi
- else
- lt_cv_prog_compiler_static_works=yes
- fi
- fi
- $RM -r conftest*
- LDFLAGS="$save_LDFLAGS"
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works" >&5
-$as_echo "$lt_cv_prog_compiler_static_works" >&6; }
-
-if test x"$lt_cv_prog_compiler_static_works" = xyes; then
- :
-else
- lt_prog_compiler_static=
-fi
-
-
-
-
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
-$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
-if ${lt_cv_prog_compiler_c_o+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_prog_compiler_c_o=no
- $RM -r conftest 2>/dev/null
- mkdir conftest
- cd conftest
- mkdir out
- echo "$lt_simple_compile_test_code" > conftest.$ac_ext
-
- lt_compiler_flag="-o out/conftest2.$ac_objext"
- # Insert the option either (1) after the last *FLAGS variable, or
- # (2) before a word containing "conftest.", or (3) at the end.
- # Note that $ac_compile itself does not contain backslashes and begins
- # with a dollar sign (not a hyphen), so the echo should work correctly.
- lt_compile=`echo "$ac_compile" | $SED \
- -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
- -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
- -e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
- (eval "$lt_compile" 2>out/conftest.err)
- ac_status=$?
- cat out/conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- if (exit $ac_status) && test -s out/conftest2.$ac_objext
- then
- # The compiler can only warn and ignore the option if not recognized
- # So say no if there are warnings
- $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
- $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
- if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
- lt_cv_prog_compiler_c_o=yes
- fi
- fi
- chmod u+w . 2>&5
- $RM conftest*
- # SGI C++ compiler will create directory out/ii_files/ for
- # template instantiation
- test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
- $RM out/* && rmdir out
- cd ..
- $RM -r conftest
- $RM conftest*
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5
-$as_echo "$lt_cv_prog_compiler_c_o" >&6; }
-
-
-
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
-$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
-if ${lt_cv_prog_compiler_c_o+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_prog_compiler_c_o=no
- $RM -r conftest 2>/dev/null
- mkdir conftest
- cd conftest
- mkdir out
- echo "$lt_simple_compile_test_code" > conftest.$ac_ext
-
- lt_compiler_flag="-o out/conftest2.$ac_objext"
- # Insert the option either (1) after the last *FLAGS variable, or
- # (2) before a word containing "conftest.", or (3) at the end.
- # Note that $ac_compile itself does not contain backslashes and begins
- # with a dollar sign (not a hyphen), so the echo should work correctly.
- lt_compile=`echo "$ac_compile" | $SED \
- -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
- -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
- -e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
- (eval "$lt_compile" 2>out/conftest.err)
- ac_status=$?
- cat out/conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- if (exit $ac_status) && test -s out/conftest2.$ac_objext
- then
- # The compiler can only warn and ignore the option if not recognized
- # So say no if there are warnings
- $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
- $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
- if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
- lt_cv_prog_compiler_c_o=yes
- fi
- fi
- chmod u+w . 2>&5
- $RM conftest*
- # SGI C++ compiler will create directory out/ii_files/ for
- # template instantiation
- test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
- $RM out/* && rmdir out
- cd ..
- $RM -r conftest
- $RM conftest*
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5
-$as_echo "$lt_cv_prog_compiler_c_o" >&6; }
-
-
-
-
-hard_links="nottested"
-if test "$lt_cv_prog_compiler_c_o" = no && test "$need_locks" != no; then
- # do not overwrite the value of need_locks provided by the user
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5
-$as_echo_n "checking if we can lock with hard links... " >&6; }
- hard_links=yes
- $RM conftest*
- ln conftest.a conftest.b 2>/dev/null && hard_links=no
- touch conftest.a
- ln conftest.a conftest.b 2>&5 || hard_links=no
- ln conftest.a conftest.b 2>/dev/null && hard_links=no
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5
-$as_echo "$hard_links" >&6; }
- if test "$hard_links" = no; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5
-$as_echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;}
- need_locks=warn
- fi
-else
- need_locks=no
-fi
-
-
-
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5
-$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; }
-
- runpath_var=
- allow_undefined_flag=
- always_export_symbols=no
- archive_cmds=
- archive_expsym_cmds=
- compiler_needs_object=no
- enable_shared_with_static_runtimes=no
- export_dynamic_flag_spec=
- export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
- hardcode_automatic=no
- hardcode_direct=no
- hardcode_direct_absolute=no
- hardcode_libdir_flag_spec=
- hardcode_libdir_flag_spec_ld=
- hardcode_libdir_separator=
- hardcode_minus_L=no
- hardcode_shlibpath_var=unsupported
- inherit_rpath=no
- link_all_deplibs=unknown
- module_cmds=
- module_expsym_cmds=
- old_archive_from_new_cmds=
- old_archive_from_expsyms_cmds=
- thread_safe_flag_spec=
- whole_archive_flag_spec=
- # include_expsyms should be a list of space-separated symbols to be *always*
- # included in the symbol list
- include_expsyms=
- # exclude_expsyms can be an extended regexp of symbols to exclude
- # it will be wrapped by ` (' and `)$', so one must not match beginning or
- # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
- # as well as any symbol that contains `d'.
- exclude_expsyms='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'
- # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
- # platforms (ab)use it in PIC code, but their linkers get confused if
- # the symbol is explicitly referenced. Since portable code cannot
- # rely on this symbol name, it's probably fine to never include it in
- # preloaded symbol tables.
- # Exclude shared library initialization/finalization symbols.
- extract_expsyms_cmds=
-
- case $host_os in
- cygwin* | mingw* | pw32* | cegcc*)
- # FIXME: the MSVC++ port hasn't been tested in a loooong time
- # When not using gcc, we currently assume that we are using
- # Microsoft Visual C++.
- if test "$GCC" != yes; then
- with_gnu_ld=no
- fi
- ;;
- interix*)
- # we just hope/assume this is gcc and not c89 (= MSVC++)
- with_gnu_ld=yes
- ;;
- openbsd*)
- with_gnu_ld=no
- ;;
- esac
-
- ld_shlibs=yes
-
- # On some targets, GNU ld is compatible enough with the native linker
- # that we're better off using the native interface for both.
- lt_use_gnu_ld_interface=no
- if test "$with_gnu_ld" = yes; then
- case $host_os in
- aix*)
- # The AIX port of GNU ld has always aspired to compatibility
- # with the native linker. However, as the warning in the GNU ld
- # block says, versions before 2.19.5* couldn't really create working
- # shared libraries, regardless of the interface used.
- case `$LD -v 2>&1` in
- *\ \(GNU\ Binutils\)\ 2.19.5*) ;;
- *\ \(GNU\ Binutils\)\ 2.[2-9]*) ;;
- *\ \(GNU\ Binutils\)\ [3-9]*) ;;
- *)
- lt_use_gnu_ld_interface=yes
- ;;
- esac
- ;;
- *)
- lt_use_gnu_ld_interface=yes
- ;;
- esac
- fi
-
- if test "$lt_use_gnu_ld_interface" = yes; then
- # If archive_cmds runs LD, not CC, wlarc should be empty
- wlarc='${wl}'
-
- # Set some defaults for GNU ld with shared library support. These
- # are reset later if shared libraries are not supported. Putting them
- # here allows them to be overridden if necessary.
- runpath_var=LD_RUN_PATH
- hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
- export_dynamic_flag_spec='${wl}--export-dynamic'
- # ancient GNU ld didn't support --whole-archive et. al.
- if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then
- whole_archive_flag_spec="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
- else
- whole_archive_flag_spec=
- fi
- supports_anon_versioning=no
- case `$LD -v 2>&1` in
- *GNU\ gold*) supports_anon_versioning=yes ;;
- *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11
- *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
- *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
- *\ 2.11.*) ;; # other 2.11 versions
- *) supports_anon_versioning=yes ;;
- esac
-
- # See if GNU ld supports shared libraries.
- case $host_os in
- aix[3-9]*)
- # On AIX/PPC, the GNU linker is very broken
- if test "$host_cpu" != ia64; then
- ld_shlibs=no
- cat <<_LT_EOF 1>&2
-
-*** Warning: the GNU linker, at least up to release 2.19, is reported
-*** to be unable to reliably create shared libraries on AIX.
-*** Therefore, libtool is disabling shared libraries support. If you
-*** really care for shared libraries, you may want to install binutils
-*** 2.20 or above, or modify your PATH so that a non-GNU linker is found.
-*** You will then need to restart the configuration process.
-
-_LT_EOF
- fi
- ;;
-
- amigaos*)
- case $host_cpu in
- powerpc)
- # see comment about AmigaOS4 .so support
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- archive_expsym_cmds=''
- ;;
- m68k)
- archive_cmds='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
- hardcode_libdir_flag_spec='-L$libdir'
- hardcode_minus_L=yes
- ;;
- esac
- ;;
-
- beos*)
- if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
- allow_undefined_flag=unsupported
- # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
- # support --undefined. This deserves some investigation. FIXME
- archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- else
- ld_shlibs=no
- fi
- ;;
-
- cygwin* | mingw* | pw32* | cegcc*)
- # _LT_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless,
- # as there is no search path for DLLs.
- hardcode_libdir_flag_spec='-L$libdir'
- export_dynamic_flag_spec='${wl}--export-all-symbols'
- allow_undefined_flag=unsupported
- always_export_symbols=no
- enable_shared_with_static_runtimes=yes
- export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
-
- if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
- # If the export-symbols file already is a .def file (1st line
- # is EXPORTS), use it as is; otherwise, prepend...
- archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
- cp $export_symbols $output_objdir/$soname.def;
- else
- echo EXPORTS > $output_objdir/$soname.def;
- cat $export_symbols >> $output_objdir/$soname.def;
- fi~
- $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
- else
- ld_shlibs=no
- fi
- ;;
-
- haiku*)
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- link_all_deplibs=yes
- ;;
-
- interix[3-9]*)
- hardcode_direct=no
- hardcode_shlibpath_var=no
- hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
- export_dynamic_flag_spec='${wl}-E'
- # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
- # Instead, shared libraries are loaded at an image base (0x10000000 by
- # default) and relocated if they conflict, which is a slow very memory
- # consuming and fragmenting process. To avoid this, we pick a random,
- # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
- # time. Moving up from 0x10000000 also allows more sbrk(2) space.
- archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
- archive_expsym_cmds='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
- ;;
-
- gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu | uclinuxfdpiceabi)
- tmp_diet=no
- if test "$host_os" = linux-dietlibc; then
- case $cc_basename in
- diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn)
- esac
- fi
- if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
- && test "$tmp_diet" = no
- then
- tmp_addflag=' $pic_flag'
- tmp_sharedflag='-shared'
- case $cc_basename,$host_cpu in
- pgcc*) # Portland Group C compiler
- whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
- tmp_addflag=' $pic_flag'
- ;;
- pgf77* | pgf90* | pgf95* | pgfortran*)
- # Portland Group f77 and f90 compilers
- whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
- tmp_addflag=' $pic_flag -Mnomain' ;;
- ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64
- tmp_addflag=' -i_dynamic' ;;
- efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64
- tmp_addflag=' -i_dynamic -nofor_main' ;;
- ifc* | ifort*) # Intel Fortran compiler
- tmp_addflag=' -nofor_main' ;;
- lf95*) # Lahey Fortran 8.1
- whole_archive_flag_spec=
- tmp_sharedflag='--shared' ;;
- xl[cC]* | bgxl[cC]* | mpixl[cC]*) # IBM XL C 8.0 on PPC (deal with xlf below)
- tmp_sharedflag='-qmkshrobj'
- tmp_addflag= ;;
- nvcc*) # Cuda Compiler Driver 2.2
- whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
- compiler_needs_object=yes
- ;;
- esac
- case `$CC -V 2>&1 | sed 5q` in
- *Sun\ C*) # Sun C 5.9
- whole_archive_flag_spec='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
- compiler_needs_object=yes
- tmp_sharedflag='-G' ;;
- *Sun\ F*) # Sun Fortran 8.3
- tmp_sharedflag='-G' ;;
- esac
- archive_cmds='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
-
- if test "x$supports_anon_versioning" = xyes; then
- archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
- cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
- echo "local: *; };" >> $output_objdir/$libname.ver~
- $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
- fi
-
- case $cc_basename in
- xlf* | bgf* | bgxlf* | mpixlf*)
- # IBM XL Fortran 10.1 on PPC cannot create shared libs itself
- whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive'
- hardcode_libdir_flag_spec=
- hardcode_libdir_flag_spec_ld='-rpath $libdir'
- archive_cmds='$LD -shared $libobjs $deplibs $compiler_flags -soname $soname -o $lib'
- if test "x$supports_anon_versioning" = xyes; then
- archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
- cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
- echo "local: *; };" >> $output_objdir/$libname.ver~
- $LD -shared $libobjs $deplibs $compiler_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
- fi
- ;;
- esac
- else
- ld_shlibs=no
- fi
- ;;
-
- netbsd*)
- if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
- archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
- wlarc=
- else
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
- fi
- ;;
-
- solaris*)
- if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then
- ld_shlibs=no
- cat <<_LT_EOF 1>&2
-
-*** Warning: The releases 2.8.* of the GNU linker cannot reliably
-*** create shared libraries on Solaris systems. Therefore, libtool
-*** is disabling shared libraries support. We urge you to upgrade GNU
-*** binutils to release 2.9.1 or newer. Another option is to modify
-*** your PATH or compiler configuration so that the native linker is
-*** used, and then restart.
-
-_LT_EOF
- elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
- else
- ld_shlibs=no
- fi
- ;;
-
- sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
- case `$LD -v 2>&1` in
- *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*)
- ld_shlibs=no
- cat <<_LT_EOF 1>&2
-
-*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not
-*** reliably create shared libraries on SCO systems. Therefore, libtool
-*** is disabling shared libraries support. We urge you to upgrade GNU
-*** binutils to release 2.16.91.0.3 or newer. Another option is to modify
-*** your PATH or compiler configuration so that the native linker is
-*** used, and then restart.
-
-_LT_EOF
- ;;
- *)
- # For security reasons, it is highly recommended that you always
- # use absolute paths for naming shared libraries, and exclude the
- # DT_RUNPATH tag from executables and libraries. But doing so
- # requires that you compile everything twice, which is a pain.
- if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
- hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
- else
- ld_shlibs=no
- fi
- ;;
- esac
- ;;
-
- sunos4*)
- archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
- wlarc=
- hardcode_direct=yes
- hardcode_shlibpath_var=no
- ;;
-
- *)
- if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
- else
- ld_shlibs=no
- fi
- ;;
- esac
-
- if test "$ld_shlibs" = no; then
- runpath_var=
- hardcode_libdir_flag_spec=
- export_dynamic_flag_spec=
- whole_archive_flag_spec=
- fi
- else
- # PORTME fill in a description of your system's linker (not GNU ld)
- case $host_os in
- aix3*)
- allow_undefined_flag=unsupported
- always_export_symbols=yes
- archive_expsym_cmds='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname'
- # Note: this linker hardcodes the directories in LIBPATH if there
- # are no directories specified by -L.
- hardcode_minus_L=yes
- if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then
- # Neither direct hardcoding nor static linking is supported with a
- # broken collect2.
- hardcode_direct=unsupported
- fi
- ;;
-
- aix[4-9]*)
- if test "$host_cpu" = ia64; then
- # On IA64, the linker does run time linking by default, so we don't
- # have to do anything special.
- aix_use_runtimelinking=no
- exp_sym_flag='-Bexport'
- no_entry_flag=""
- else
- # If we're using GNU nm, then we don't want the "-C" option.
- # -C means demangle to AIX nm, but means don't demangle with GNU nm
- # Also, AIX nm treats weak defined symbols like other global
- # defined symbols, whereas GNU nm marks them as "W".
- if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
- export_symbols_cmds='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
- else
- export_symbols_cmds='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "L")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
- fi
- aix_use_runtimelinking=no
-
- # Test if we are trying to use run time linking or normal
- # AIX style linking. If -brtl is somewhere in LDFLAGS, we
- # need to do runtime linking.
- case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*)
- for ld_flag in $LDFLAGS; do
- if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
- aix_use_runtimelinking=yes
- break
- fi
- done
- ;;
- esac
-
- exp_sym_flag='-bexport'
- no_entry_flag='-bnoentry'
- fi
-
- # When large executables or shared objects are built, AIX ld can
- # have problems creating the table of contents. If linking a library
- # or program results in "error TOC overflow" add -mminimal-toc to
- # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
- # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
-
- archive_cmds=''
- hardcode_direct=yes
- hardcode_direct_absolute=yes
- hardcode_libdir_separator=':'
- link_all_deplibs=yes
- file_list_spec='${wl}-f,'
-
- if test "$GCC" = yes; then
- case $host_os in aix4.[012]|aix4.[012].*)
- # We only want to do this on AIX 4.2 and lower, the check
- # below for broken collect2 doesn't work under 4.3+
- collect2name=`${CC} -print-prog-name=collect2`
- if test -f "$collect2name" &&
- strings "$collect2name" | $GREP resolve_lib_name >/dev/null
- then
- # We have reworked collect2
- :
- else
- # We have old collect2
- hardcode_direct=unsupported
- # It fails to find uninstalled libraries when the uninstalled
- # path is not listed in the libpath. Setting hardcode_minus_L
- # to unsupported forces relinking
- hardcode_minus_L=yes
- hardcode_libdir_flag_spec='-L$libdir'
- hardcode_libdir_separator=
- fi
- ;;
- esac
- shared_flag='-shared'
- if test "$aix_use_runtimelinking" = yes; then
- shared_flag="$shared_flag "'${wl}-G'
- fi
- else
- # not using gcc
- if test "$host_cpu" = ia64; then
- # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
- # chokes on -Wl,-G. The following line is correct:
- shared_flag='-G'
- else
- if test "$aix_use_runtimelinking" = yes; then
- shared_flag='${wl}-G'
- else
- shared_flag='${wl}-bM:SRE'
- fi
- fi
- fi
-
- export_dynamic_flag_spec='${wl}-bexpall'
- # It seems that -bexpall does not export symbols beginning with
- # underscore (_), so it is better to generate a list of symbols to export.
- always_export_symbols=yes
- if test "$aix_use_runtimelinking" = yes; then
- # Warning - without using the other runtime loading flags (-brtl),
- # -berok will link without error, but may produce a broken library.
- allow_undefined_flag='-berok'
- # Determine the default libpath from the value encoded in an
- # empty executable.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
-
-lt_aix_libpath_sed='
- /Import File Strings/,/^$/ {
- /^0/ {
- s/^0 *\(.*\)$/\1/
- p
- }
- }'
-aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
-# Check for a 64-bit object if we didn't find anything.
-if test -z "$aix_libpath"; then
- aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
-fi
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
-
- hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
- archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
- else
- if test "$host_cpu" = ia64; then
- hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib'
- allow_undefined_flag="-z nodefs"
- archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols"
- else
- # Determine the default libpath from the value encoded in an
- # empty executable.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
-
-lt_aix_libpath_sed='
- /Import File Strings/,/^$/ {
- /^0/ {
- s/^0 *\(.*\)$/\1/
- p
- }
- }'
-aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
-# Check for a 64-bit object if we didn't find anything.
-if test -z "$aix_libpath"; then
- aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
-fi
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
-
- hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
- # Warning - without using the other run time loading flags,
- # -berok will link without error, but may produce a broken library.
- no_undefined_flag=' ${wl}-bernotok'
- allow_undefined_flag=' ${wl}-berok'
- if test "$with_gnu_ld" = yes; then
- # We only use this code for GNU lds that support --whole-archive.
- whole_archive_flag_spec='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
- else
- # Exported symbols can be pulled into shared objects from archives
- whole_archive_flag_spec='$convenience'
- fi
- archive_cmds_need_lc=yes
- # This is similar to how AIX traditionally builds its shared libraries.
- archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
- fi
- fi
- ;;
-
- amigaos*)
- case $host_cpu in
- powerpc)
- # see comment about AmigaOS4 .so support
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- archive_expsym_cmds=''
- ;;
- m68k)
- archive_cmds='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
- hardcode_libdir_flag_spec='-L$libdir'
- hardcode_minus_L=yes
- ;;
- esac
- ;;
-
- bsdi[45]*)
- export_dynamic_flag_spec=-rdynamic
- ;;
-
- cygwin* | mingw* | pw32* | cegcc*)
- # When not using gcc, we currently assume that we are using
- # Microsoft Visual C++.
- # hardcode_libdir_flag_spec is actually meaningless, as there is
- # no search path for DLLs.
- hardcode_libdir_flag_spec=' '
- allow_undefined_flag=unsupported
- # Tell ltmain to make .lib files, not .a files.
- libext=lib
- # Tell ltmain to make .dll files, not .so files.
- shrext_cmds=".dll"
- # FIXME: Setting linknames here is a bad hack.
- archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
- # The linker will automatically build a .lib file if we build a DLL.
- old_archive_from_new_cmds='true'
- # FIXME: Should let the user specify the lib program.
- old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs'
- fix_srcfile_path='`cygpath -w "$srcfile"`'
- enable_shared_with_static_runtimes=yes
- ;;
-
- darwin* | rhapsody*)
-
-
- archive_cmds_need_lc=no
- hardcode_direct=no
- hardcode_automatic=yes
- hardcode_shlibpath_var=unsupported
- if test "$lt_cv_ld_force_load" = "yes"; then
- whole_archive_flag_spec='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience ${wl}-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`'
- else
- whole_archive_flag_spec=''
- fi
- link_all_deplibs=yes
- allow_undefined_flag="$_lt_dar_allow_undefined"
- case $cc_basename in
- ifort*) _lt_dar_can_shared=yes ;;
- *) _lt_dar_can_shared=$GCC ;;
- esac
- if test "$_lt_dar_can_shared" = "yes"; then
- output_verbose_link_cmd=func_echo_all
- archive_cmds="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}"
- module_cmds="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
- archive_expsym_cmds="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}"
- module_expsym_cmds="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}"
-
- else
- ld_shlibs=no
- fi
-
- ;;
-
- dgux*)
- archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
- hardcode_libdir_flag_spec='-L$libdir'
- hardcode_shlibpath_var=no
- ;;
-
- # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
- # support. Future versions do this automatically, but an explicit c++rt0.o
- # does not break anything, and helps significantly (at the cost of a little
- # extra space).
- freebsd2.2*)
- archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
- hardcode_libdir_flag_spec='-R$libdir'
- hardcode_direct=yes
- hardcode_shlibpath_var=no
- ;;
-
- # Unfortunately, older versions of FreeBSD 2 do not have this feature.
- freebsd2.*)
- archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
- hardcode_direct=yes
- hardcode_minus_L=yes
- hardcode_shlibpath_var=no
- ;;
-
- # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
- freebsd* | dragonfly*)
- archive_cmds='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
- hardcode_libdir_flag_spec='-R$libdir'
- hardcode_direct=yes
- hardcode_shlibpath_var=no
- ;;
-
- hpux9*)
- if test "$GCC" = yes; then
- archive_cmds='$RM $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
- else
- archive_cmds='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
- fi
- hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
- hardcode_libdir_separator=:
- hardcode_direct=yes
-
- # hardcode_minus_L: Not really in the search PATH,
- # but as the default location of the library.
- hardcode_minus_L=yes
- export_dynamic_flag_spec='${wl}-E'
- ;;
-
- hpux10*)
- if test "$GCC" = yes && test "$with_gnu_ld" = no; then
- archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
- else
- archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
- fi
- if test "$with_gnu_ld" = no; then
- hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
- hardcode_libdir_flag_spec_ld='+b $libdir'
- hardcode_libdir_separator=:
- hardcode_direct=yes
- hardcode_direct_absolute=yes
- export_dynamic_flag_spec='${wl}-E'
- # hardcode_minus_L: Not really in the search PATH,
- # but as the default location of the library.
- hardcode_minus_L=yes
- fi
- ;;
-
- hpux11*)
- if test "$GCC" = yes && test "$with_gnu_ld" = no; then
- case $host_cpu in
- hppa*64*)
- archive_cmds='$CC -shared ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
- ;;
- ia64*)
- archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
- ;;
- *)
- archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
- ;;
- esac
- else
- case $host_cpu in
- hppa*64*)
- archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
- ;;
- ia64*)
- archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
- ;;
- *)
-
- # Older versions of the 11.00 compiler do not understand -b yet
- # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does)
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC understands -b" >&5
-$as_echo_n "checking if $CC understands -b... " >&6; }
-if ${lt_cv_prog_compiler__b+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_prog_compiler__b=no
- save_LDFLAGS="$LDFLAGS"
- LDFLAGS="$LDFLAGS -b"
- echo "$lt_simple_link_test_code" > conftest.$ac_ext
- if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
- # The linker can only warn and ignore the option if not recognized
- # So say no if there are warnings
- if test -s conftest.err; then
- # Append any errors to the config.log.
- cat conftest.err 1>&5
- $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
- $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
- if diff conftest.exp conftest.er2 >/dev/null; then
- lt_cv_prog_compiler__b=yes
- fi
- else
- lt_cv_prog_compiler__b=yes
- fi
- fi
- $RM -r conftest*
- LDFLAGS="$save_LDFLAGS"
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler__b" >&5
-$as_echo "$lt_cv_prog_compiler__b" >&6; }
-
-if test x"$lt_cv_prog_compiler__b" = xyes; then
- archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
-else
- archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
-fi
-
- ;;
- esac
- fi
- if test "$with_gnu_ld" = no; then
- hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
- hardcode_libdir_separator=:
-
- case $host_cpu in
- hppa*64*|ia64*)
- hardcode_direct=no
- hardcode_shlibpath_var=no
- ;;
- *)
- hardcode_direct=yes
- hardcode_direct_absolute=yes
- export_dynamic_flag_spec='${wl}-E'
-
- # hardcode_minus_L: Not really in the search PATH,
- # but as the default location of the library.
- hardcode_minus_L=yes
- ;;
- esac
- fi
- ;;
-
- irix5* | irix6* | nonstopux*)
- if test "$GCC" = yes; then
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
- # Try to use the -exported_symbol ld option, if it does not
- # work, assume that -exports_file does not work either and
- # implicitly export all symbols.
- save_LDFLAGS="$LDFLAGS"
- LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-int foo(void) {}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
-
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LDFLAGS="$save_LDFLAGS"
- else
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
- fi
- archive_cmds_need_lc='no'
- hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
- hardcode_libdir_separator=:
- inherit_rpath=yes
- link_all_deplibs=yes
- ;;
-
- netbsd*)
- if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
- archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out
- else
- archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF
- fi
- hardcode_libdir_flag_spec='-R$libdir'
- hardcode_direct=yes
- hardcode_shlibpath_var=no
- ;;
-
- newsos6)
- archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
- hardcode_direct=yes
- hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
- hardcode_libdir_separator=:
- hardcode_shlibpath_var=no
- ;;
-
- *nto* | *qnx*)
- ;;
-
- openbsd*)
- if test -f /usr/libexec/ld.so; then
- hardcode_direct=yes
- hardcode_shlibpath_var=no
- hardcode_direct_absolute=yes
- if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
- archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
- archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
- hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
- export_dynamic_flag_spec='${wl}-E'
- else
- case $host_os in
- openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*)
- archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
- hardcode_libdir_flag_spec='-R$libdir'
- ;;
- *)
- archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
- hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
- ;;
- esac
- fi
- else
- ld_shlibs=no
- fi
- ;;
-
- os2*)
- hardcode_libdir_flag_spec='-L$libdir'
- hardcode_minus_L=yes
- allow_undefined_flag=unsupported
- archive_cmds='$ECHO "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~echo DATA >> $output_objdir/$libname.def~echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def'
- old_archive_from_new_cmds='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
- ;;
-
- osf3*)
- if test "$GCC" = yes; then
- allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
- archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
- else
- allow_undefined_flag=' -expect_unresolved \*'
- archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
- fi
- archive_cmds_need_lc='no'
- hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
- hardcode_libdir_separator=:
- ;;
-
- osf4* | osf5*) # as osf3* with the addition of -msym flag
- if test "$GCC" = yes; then
- allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
- archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
- hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
- else
- allow_undefined_flag=' -expect_unresolved \*'
- archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
- archive_expsym_cmds='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~
- $CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp'
-
- # Both c and cxx compiler support -rpath directly
- hardcode_libdir_flag_spec='-rpath $libdir'
- fi
- archive_cmds_need_lc='no'
- hardcode_libdir_separator=:
- ;;
-
- solaris*)
- no_undefined_flag=' -z defs'
- if test "$GCC" = yes; then
- wlarc='${wl}'
- archive_cmds='$CC -shared ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
- archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
- $CC -shared ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
- else
- case `$CC -V 2>&1` in
- *"Compilers 5.0"*)
- wlarc=''
- archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
- archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
- $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp'
- ;;
- *)
- wlarc='${wl}'
- archive_cmds='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags'
- archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
- $CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
- ;;
- esac
- fi
- hardcode_libdir_flag_spec='-R$libdir'
- hardcode_shlibpath_var=no
- case $host_os in
- solaris2.[0-5] | solaris2.[0-5].*) ;;
- *)
- # The compiler driver will combine and reorder linker options,
- # but understands `-z linker_flag'. GCC discards it without `$wl',
- # but is careful enough not to reorder.
- # Supported since Solaris 2.6 (maybe 2.5.1?)
- if test "$GCC" = yes; then
- whole_archive_flag_spec='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
- else
- whole_archive_flag_spec='-z allextract$convenience -z defaultextract'
- fi
- ;;
- esac
- link_all_deplibs=yes
- ;;
-
- sunos4*)
- if test "x$host_vendor" = xsequent; then
- # Use $CC to link under sequent, because it throws in some extra .o
- # files that make .init and .fini sections work.
- archive_cmds='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
- else
- archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
- fi
- hardcode_libdir_flag_spec='-L$libdir'
- hardcode_direct=yes
- hardcode_minus_L=yes
- hardcode_shlibpath_var=no
- ;;
-
- sysv4)
- case $host_vendor in
- sni)
- archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
- hardcode_direct=yes # is this really true???
- ;;
- siemens)
- ## LD is ld it makes a PLAMLIB
- ## CC just makes a GrossModule.
- archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags'
- reload_cmds='$CC -r -o $output$reload_objs'
- hardcode_direct=no
- ;;
- motorola)
- archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
- hardcode_direct=no #Motorola manual says yes, but my tests say they lie
- ;;
- esac
- runpath_var='LD_RUN_PATH'
- hardcode_shlibpath_var=no
- ;;
-
- sysv4.3*)
- archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
- hardcode_shlibpath_var=no
- export_dynamic_flag_spec='-Bexport'
- ;;
-
- sysv4*MP*)
- if test -d /usr/nec; then
- archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
- hardcode_shlibpath_var=no
- runpath_var=LD_RUN_PATH
- hardcode_runpath_var=yes
- ld_shlibs=yes
- fi
- ;;
-
- sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*)
- no_undefined_flag='${wl}-z,text'
- archive_cmds_need_lc=no
- hardcode_shlibpath_var=no
- runpath_var='LD_RUN_PATH'
-
- if test "$GCC" = yes; then
- archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- else
- archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- fi
- ;;
-
- sysv5* | sco3.2v5* | sco5v6*)
- # Note: We can NOT use -z defs as we might desire, because we do not
- # link with -lc, and that would cause any symbols used from libc to
- # always be unresolved, which means just about no library would
- # ever link correctly. If we're not using GNU ld we use -z text
- # though, which does catch some bad symbols but isn't as heavy-handed
- # as -z defs.
- no_undefined_flag='${wl}-z,text'
- allow_undefined_flag='${wl}-z,nodefs'
- archive_cmds_need_lc=no
- hardcode_shlibpath_var=no
- hardcode_libdir_flag_spec='${wl}-R,$libdir'
- hardcode_libdir_separator=':'
- link_all_deplibs=yes
- export_dynamic_flag_spec='${wl}-Bexport'
- runpath_var='LD_RUN_PATH'
-
- if test "$GCC" = yes; then
- archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- else
- archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- fi
- ;;
-
- uts4*)
- archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
- hardcode_libdir_flag_spec='-L$libdir'
- hardcode_shlibpath_var=no
- ;;
-
- *)
- ld_shlibs=no
- ;;
- esac
-
- if test x$host_vendor = xsni; then
- case $host in
- sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
- export_dynamic_flag_spec='${wl}-Blargedynsym'
- ;;
- esac
- fi
- fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs" >&5
-$as_echo "$ld_shlibs" >&6; }
-test "$ld_shlibs" = no && can_build_shared=no
-
-with_gnu_ld=$with_gnu_ld
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-#
-# Do we need to explicitly link libc?
-#
-case "x$archive_cmds_need_lc" in
-x|xyes)
- # Assume -lc should be added
- archive_cmds_need_lc=yes
-
- if test "$enable_shared" = yes && test "$GCC" = yes; then
- case $archive_cmds in
- *'~'*)
- # FIXME: we may have to deal with multi-command sequences.
- ;;
- '$CC '*)
- # Test whether the compiler implicitly links with -lc since on some
- # systems, -lgcc has to come before -lc. If gcc already passes -lc
- # to ld, don't add -lc before -lgcc.
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5
-$as_echo_n "checking whether -lc should be explicitly linked in... " >&6; }
-if ${lt_cv_archive_cmds_need_lc+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- $RM conftest*
- echo "$lt_simple_compile_test_code" > conftest.$ac_ext
-
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
- (eval $ac_compile) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } 2>conftest.err; then
- soname=conftest
- lib=conftest
- libobjs=conftest.$ac_objext
- deplibs=
- wl=$lt_prog_compiler_wl
- pic_flag=$lt_prog_compiler_pic
- compiler_flags=-v
- linker_flags=-v
- verstring=
- output_objdir=.
- libname=conftest
- lt_save_allow_undefined_flag=$allow_undefined_flag
- allow_undefined_flag=
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5
- (eval $archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }
- then
- lt_cv_archive_cmds_need_lc=no
- else
- lt_cv_archive_cmds_need_lc=yes
- fi
- allow_undefined_flag=$lt_save_allow_undefined_flag
- else
- cat conftest.err 1>&5
- fi
- $RM conftest*
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc" >&5
-$as_echo "$lt_cv_archive_cmds_need_lc" >&6; }
- archive_cmds_need_lc=$lt_cv_archive_cmds_need_lc
- ;;
- esac
- fi
- ;;
-esac
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5
-$as_echo_n "checking dynamic linker characteristics... " >&6; }
-
-if test "$GCC" = yes; then
- case $host_os in
- darwin*) lt_awk_arg="/^libraries:/,/LR/" ;;
- *) lt_awk_arg="/^libraries:/" ;;
- esac
- case $host_os in
- mingw* | cegcc*) lt_sed_strip_eq="s,=\([A-Za-z]:\),\1,g" ;;
- *) lt_sed_strip_eq="s,=/,/,g" ;;
- esac
- lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq`
- case $lt_search_path_spec in
- *\;*)
- # if the path contains ";" then we assume it to be the separator
- # otherwise default to the standard path separator (i.e. ":") - it is
- # assumed that no part of a normal pathname contains ";" but that should
- # okay in the real world where ";" in dirpaths is itself problematic.
- lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'`
- ;;
- *)
- lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"`
- ;;
- esac
- # Ok, now we have the path, separated by spaces, we can step through it
- # and add multilib dir if necessary.
- lt_tmp_lt_search_path_spec=
- lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
- for lt_sys_path in $lt_search_path_spec; do
- if test -d "$lt_sys_path/$lt_multi_os_dir"; then
- lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir"
- else
- test -d "$lt_sys_path" && \
- lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
- fi
- done
- lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk '
-BEGIN {RS=" "; FS="/|\n";} {
- lt_foo="";
- lt_count=0;
- for (lt_i = NF; lt_i > 0; lt_i--) {
- if ($lt_i != "" && $lt_i != ".") {
- if ($lt_i == "..") {
- lt_count++;
- } else {
- if (lt_count == 0) {
- lt_foo="/" $lt_i lt_foo;
- } else {
- lt_count--;
- }
- }
- }
- }
- if (lt_foo != "") { lt_freq[lt_foo]++; }
- if (lt_freq[lt_foo] == 1) { print lt_foo; }
-}'`
- # AWK program above erroneously prepends '/' to C:/dos/paths
- # for these hosts.
- case $host_os in
- mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\
- $SED 's,/\([A-Za-z]:\),\1,g'` ;;
- esac
- sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP`
-else
- sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
-fi
-library_names_spec=
-libname_spec='lib$name'
-soname_spec=
-shrext_cmds=".so"
-postinstall_cmds=
-postuninstall_cmds=
-finish_cmds=
-finish_eval=
-shlibpath_var=
-shlibpath_overrides_runpath=unknown
-version_type=none
-dynamic_linker="$host_os ld.so"
-sys_lib_dlsearch_path_spec="/lib /usr/lib"
-need_lib_prefix=unknown
-hardcode_into_libs=no
-
-# when you set need_version to no, make sure it does not cause -set_version
-# flags to be left without arguments
-need_version=unknown
-
-case $host_os in
-aix3*)
- version_type=linux
- library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
- shlibpath_var=LIBPATH
-
- # AIX 3 has no versioning support, so we append a major version to the name.
- soname_spec='${libname}${release}${shared_ext}$major'
- ;;
-
-aix[4-9]*)
- version_type=linux
- need_lib_prefix=no
- need_version=no
- hardcode_into_libs=yes
- if test "$host_cpu" = ia64; then
- # AIX 5 supports IA64
- library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
- shlibpath_var=LD_LIBRARY_PATH
- else
- # With GCC up to 2.95.x, collect2 would create an import file
- # for dependence libraries. The import file would start with
- # the line `#! .'. This would cause the generated library to
- # depend on `.', always an invalid library. This was fixed in
- # development snapshots of GCC prior to 3.0.
- case $host_os in
- aix4 | aix4.[01] | aix4.[01].*)
- if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
- echo ' yes '
- echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then
- :
- else
- can_build_shared=no
- fi
- ;;
- esac
- # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
- # soname into executable. Probably we can add versioning support to
- # collect2, so additional links can be useful in future.
- if test "$aix_use_runtimelinking" = yes; then
- # If using run time linking (on AIX 4.2 or later) use lib<name>.so
- # instead of lib<name>.a to let people know that these are not
- # typical AIX shared libraries.
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- else
- # We preserve .a as extension for shared libraries through AIX4.2
- # and later when we are not doing run time linking.
- library_names_spec='${libname}${release}.a $libname.a'
- soname_spec='${libname}${release}${shared_ext}$major'
- fi
- shlibpath_var=LIBPATH
- fi
- ;;
-
-amigaos*)
- case $host_cpu in
- powerpc)
- # Since July 2007 AmigaOS4 officially supports .so libraries.
- # When compiling the executable, add -use-dynld -Lsobjs: to the compileline.
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- ;;
- m68k)
- library_names_spec='$libname.ixlibrary $libname.a'
- # Create ${libname}_ixlibrary.a entries in /sys/libs.
- finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done'
- ;;
- esac
- ;;
-
-beos*)
- library_names_spec='${libname}${shared_ext}'
- dynamic_linker="$host_os ld.so"
- shlibpath_var=LIBRARY_PATH
- ;;
-
-bsdi[45]*)
- version_type=linux
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
- shlibpath_var=LD_LIBRARY_PATH
- sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
- sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
- # the default ld.so.conf also contains /usr/contrib/lib and
- # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
- # libtool to hard-code these into programs
- ;;
-
-cygwin* | mingw* | pw32* | cegcc*)
- version_type=windows
- shrext_cmds=".dll"
- need_version=no
- need_lib_prefix=no
-
- case $GCC,$host_os in
- yes,cygwin* | yes,mingw* | yes,pw32* | yes,cegcc*)
- library_names_spec='$libname.dll.a'
- # DLL is installed to $(libdir)/../bin by postinstall_cmds
- postinstall_cmds='base_file=`basename \${file}`~
- dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
- dldir=$destdir/`dirname \$dlpath`~
- test -d \$dldir || mkdir -p \$dldir~
- $install_prog $dir/$dlname \$dldir/$dlname~
- chmod a+x \$dldir/$dlname~
- if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
- eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
- fi'
- postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
- dlpath=$dir/\$dldll~
- $RM \$dlpath'
- shlibpath_overrides_runpath=yes
-
- case $host_os in
- cygwin*)
- # Cygwin DLLs use 'cyg' prefix rather than 'lib'
- soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
-
- sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"
- ;;
- mingw* | cegcc*)
- # MinGW DLLs use traditional 'lib' prefix
- soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
- ;;
- pw32*)
- # pw32 DLLs use 'pw' prefix rather than 'lib'
- library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
- ;;
- esac
- ;;
-
- *)
- library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib'
- ;;
- esac
- dynamic_linker='Win32 ld.exe'
- # FIXME: first we should search . and the directory the executable is in
- shlibpath_var=PATH
- ;;
-
-darwin* | rhapsody*)
- dynamic_linker="$host_os dyld"
- version_type=darwin
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext'
- soname_spec='${libname}${release}${major}$shared_ext'
- shlibpath_overrides_runpath=yes
- shlibpath_var=DYLD_LIBRARY_PATH
- shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
-
- sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"
- sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
- ;;
-
-dgux*)
- version_type=linux
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
- soname_spec='${libname}${release}${shared_ext}$major'
- shlibpath_var=LD_LIBRARY_PATH
- ;;
-
-freebsd* | dragonfly*)
- # DragonFly does not have aout. When/if they implement a new
- # versioning mechanism, adjust this.
- if test -x /usr/bin/objformat; then
- objformat=`/usr/bin/objformat`
- else
- case $host_os in
- freebsd[23].*) objformat=aout ;;
- *) objformat=elf ;;
- esac
- fi
- version_type=freebsd-$objformat
- case $version_type in
- freebsd-elf*)
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
- need_version=no
- need_lib_prefix=no
- ;;
- freebsd-*)
- library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
- need_version=yes
- ;;
- esac
- shlibpath_var=LD_LIBRARY_PATH
- case $host_os in
- freebsd2.*)
- shlibpath_overrides_runpath=yes
- ;;
- freebsd3.[01]* | freebsdelf3.[01]*)
- shlibpath_overrides_runpath=yes
- hardcode_into_libs=yes
- ;;
- freebsd3.[2-9]* | freebsdelf3.[2-9]* | \
- freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1)
- shlibpath_overrides_runpath=no
- hardcode_into_libs=yes
- ;;
- *) # from 4.6 on, and DragonFly
- shlibpath_overrides_runpath=yes
- hardcode_into_libs=yes
- ;;
- esac
- ;;
-
-haiku*)
- version_type=linux
- need_lib_prefix=no
- need_version=no
- dynamic_linker="$host_os runtime_loader"
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- shlibpath_var=LIBRARY_PATH
- shlibpath_overrides_runpath=yes
- sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
- hardcode_into_libs=yes
- ;;
-
-hpux9* | hpux10* | hpux11*)
- # Give a soname corresponding to the major version so that dld.sl refuses to
- # link against other versions.
- version_type=sunos
- need_lib_prefix=no
- need_version=no
- case $host_cpu in
- ia64*)
- shrext_cmds='.so'
- hardcode_into_libs=yes
- dynamic_linker="$host_os dld.so"
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- if test "X$HPUX_IA64_MODE" = X32; then
- sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
- else
- sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
- fi
- sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
- ;;
- hppa*64*)
- shrext_cmds='.sl'
- hardcode_into_libs=yes
- dynamic_linker="$host_os dld.sl"
- shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
- shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
- sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
- ;;
- *)
- shrext_cmds='.sl'
- dynamic_linker="$host_os dld.sl"
- shlibpath_var=SHLIB_PATH
- shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- ;;
- esac
- # HP-UX runs *really* slowly unless shared libraries are mode 555, ...
- postinstall_cmds='chmod 555 $lib'
- # or fails outright, so override atomically:
- install_override_mode=555
- ;;
-
-interix[3-9]*)
- version_type=linux
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=no
- hardcode_into_libs=yes
- ;;
-
-irix5* | irix6* | nonstopux*)
- case $host_os in
- nonstopux*) version_type=nonstopux ;;
- *)
- if test "$lt_cv_prog_gnu_ld" = yes; then
- version_type=linux
- else
- version_type=irix
- fi ;;
- esac
- need_lib_prefix=no
- need_version=no
- soname_spec='${libname}${release}${shared_ext}$major'
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
- case $host_os in
- irix5* | nonstopux*)
- libsuff= shlibsuff=
- ;;
- *)
- case $LD in # libtool.m4 will add one of these switches to LD
- *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
- libsuff= shlibsuff= libmagic=32-bit;;
- *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
- libsuff=32 shlibsuff=N32 libmagic=N32;;
- *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
- libsuff=64 shlibsuff=64 libmagic=64-bit;;
- *) libsuff= shlibsuff= libmagic=never-match;;
- esac
- ;;
- esac
- shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
- shlibpath_overrides_runpath=no
- sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
- sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
- hardcode_into_libs=yes
- ;;
-
-# No shared lib support for Linux oldld, aout, or coff.
-linux*oldld* | linux*aout* | linux*coff*)
- dynamic_linker=no
- ;;
-
-# This must be Linux ELF.
-
-# uclinux* changes (here and below) have been submitted to the libtool
-# project, but have not yet been accepted: they are GCC-local changes
-# for the time being. (See
-# https://lists.gnu.org/archive/html/libtool-patches/2018-05/msg00000.html)
-linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu* | uclinuxfdpiceabi)
- version_type=linux
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=no
-
- # Some binutils ld are patched to set DT_RUNPATH
- if ${lt_cv_shlibpath_overrides_runpath+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_shlibpath_overrides_runpath=no
- save_LDFLAGS=$LDFLAGS
- save_libdir=$libdir
- eval "libdir=/foo; wl=\"$lt_prog_compiler_wl\"; \
- LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec\""
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- if ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then :
- lt_cv_shlibpath_overrides_runpath=yes
-fi
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LDFLAGS=$save_LDFLAGS
- libdir=$save_libdir
-
-fi
-
- shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath
-
- # This implies no fast_install, which is unacceptable.
- # Some rework will be needed to allow for fast_install
- # before this can be enabled.
- hardcode_into_libs=yes
-
- # find out which ABI we are using
- libsuff=
- case "$host_cpu" in
- x86_64*|s390*|powerpc*|ppc*|sparc*)
- echo 'int i;' > conftest.$ac_ext
- if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; then
- case `/usr/bin/file conftest.$ac_objext` in
- *64-bit*)
- libsuff=
- if test x"$sys_lib_search_path_spec" = x"/lib /usr/lib /usr/local/lib"; then
- sys_lib_search_path_spec="/lib${libsuff} /usr/lib${libsuff} /usr/local/lib${libsuff}"
- fi
- sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff}"
- ;;
- *32-bit*)
- libsuff=32
- if test x"$sys_lib_search_path_spec" = x"/lib /usr/lib /usr/local/lib"; then
- sys_lib_search_path_spec="/lib${libsuff} /usr/lib${libsuff} /usr/local/lib${libsuff}"
- fi
- sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff}"
- ;;
- esac
- fi
- rm -rf conftest*
- ;;
- esac
-
- # Append ld.so.conf contents to the search path
- if test -f /etc/ld.so.conf; then
- lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '`
- sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff} $lt_ld_extra"
- fi
-
- # We used to test for /lib/ld.so.1 and disable shared libraries on
- # powerpc, because MkLinux only supported shared libraries with the
- # GNU dynamic linker. Since this was broken with cross compilers,
- # most powerpc-linux boxes support dynamic linking these days and
- # people can always --disable-shared, the test was removed, and we
- # assume the GNU/Linux dynamic linker is in use.
- dynamic_linker='GNU/Linux ld.so'
- ;;
-
-netbsd*)
- version_type=sunos
- need_lib_prefix=no
- need_version=no
- if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
- finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
- dynamic_linker='NetBSD (a.out) ld.so'
- else
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- dynamic_linker='NetBSD ld.elf_so'
- fi
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=yes
- hardcode_into_libs=yes
- ;;
-
-newsos6)
- version_type=linux
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=yes
- ;;
-
-*nto* | *qnx*)
- version_type=qnx
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=no
- hardcode_into_libs=yes
- dynamic_linker='ldqnx.so'
- ;;
-
-openbsd*)
- version_type=sunos
- sys_lib_dlsearch_path_spec="/usr/lib"
- need_lib_prefix=no
- # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
- case $host_os in
- openbsd3.3 | openbsd3.3.*) need_version=yes ;;
- *) need_version=no ;;
- esac
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
- finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
- shlibpath_var=LD_LIBRARY_PATH
- if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
- case $host_os in
- openbsd2.[89] | openbsd2.[89].*)
- shlibpath_overrides_runpath=no
- ;;
- *)
- shlibpath_overrides_runpath=yes
- ;;
- esac
- else
- shlibpath_overrides_runpath=yes
- fi
- ;;
-
-os2*)
- libname_spec='$name'
- shrext_cmds=".dll"
- need_lib_prefix=no
- library_names_spec='$libname${shared_ext} $libname.a'
- dynamic_linker='OS/2 ld.exe'
- shlibpath_var=LIBPATH
- ;;
-
-osf3* | osf4* | osf5*)
- version_type=osf
- need_lib_prefix=no
- need_version=no
- soname_spec='${libname}${release}${shared_ext}$major'
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- shlibpath_var=LD_LIBRARY_PATH
- sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
- sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
- ;;
-
-rdos*)
- dynamic_linker=no
- ;;
-
-solaris*)
- version_type=linux
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=yes
- hardcode_into_libs=yes
- # ldd complains unless libraries are executable
- postinstall_cmds='chmod +x $lib'
- ;;
-
-sunos4*)
- version_type=sunos
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
- finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=yes
- if test "$with_gnu_ld" = yes; then
- need_lib_prefix=no
- fi
- need_version=yes
- ;;
-
-sysv4 | sysv4.3*)
- version_type=linux
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- shlibpath_var=LD_LIBRARY_PATH
- case $host_vendor in
- sni)
- shlibpath_overrides_runpath=no
- need_lib_prefix=no
- runpath_var=LD_RUN_PATH
- ;;
- siemens)
- need_lib_prefix=no
- ;;
- motorola)
- need_lib_prefix=no
- need_version=no
- shlibpath_overrides_runpath=no
- sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
- ;;
- esac
- ;;
-
-sysv4*MP*)
- if test -d /usr/nec ;then
- version_type=linux
- library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
- soname_spec='$libname${shared_ext}.$major'
- shlibpath_var=LD_LIBRARY_PATH
- fi
- ;;
-
-sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
- version_type=freebsd-elf
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=yes
- hardcode_into_libs=yes
- if test "$with_gnu_ld" = yes; then
- sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
- else
- sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
- case $host_os in
- sco3.2v5*)
- sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
- ;;
- esac
- fi
- sys_lib_dlsearch_path_spec='/usr/lib'
- ;;
-
-tpf*)
- # TPF is a cross-target only. Preferred cross-host = GNU/Linux.
- version_type=linux
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=no
- hardcode_into_libs=yes
- ;;
-
-uts4*)
- version_type=linux
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- shlibpath_var=LD_LIBRARY_PATH
- ;;
-
-# Shared libraries for VwWorks, >= 7 only at this stage
-# and (fpic) still incompatible with "large" code models
-# in a few configurations. Only for RTP mode in any case,
-# and upon explicit request at configure time.
-vxworks7*)
- dynamic_linker=no
- case ${with_multisubdir}-${enable_shared} in
- *large*)
- ;;
- *mrtp*-yes)
- version_type=linux
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- dynamic_linker="$host_os module_loader"
- ;;
- esac
- ;;
-*)
- dynamic_linker=no
- ;;
-esac
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5
-$as_echo "$dynamic_linker" >&6; }
-test "$dynamic_linker" = no && can_build_shared=no
-
-variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
-if test "$GCC" = yes; then
- variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
-fi
-
-if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then
- sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec"
-fi
-if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then
- sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec"
-fi
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5
-$as_echo_n "checking how to hardcode library paths into programs... " >&6; }
-hardcode_action=
-if test -n "$hardcode_libdir_flag_spec" ||
- test -n "$runpath_var" ||
- test "X$hardcode_automatic" = "Xyes" ; then
-
- # We can hardcode non-existent directories.
- if test "$hardcode_direct" != no &&
- # If the only mechanism to avoid hardcoding is shlibpath_var, we
- # have to relink, otherwise we might link with an installed library
- # when we should be linking with a yet-to-be-installed one
- ## test "$_LT_TAGVAR(hardcode_shlibpath_var, )" != no &&
- test "$hardcode_minus_L" != no; then
- # Linking always hardcodes the temporary library directory.
- hardcode_action=relink
- else
- # We can link without hardcoding, and we can hardcode nonexisting dirs.
- hardcode_action=immediate
- fi
-else
- # We cannot hardcode anything, or else we can only hardcode existing
- # directories.
- hardcode_action=unsupported
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action" >&5
-$as_echo "$hardcode_action" >&6; }
-
-if test "$hardcode_action" = relink ||
- test "$inherit_rpath" = yes; then
- # Fast installation is not supported
- enable_fast_install=no
-elif test "$shlibpath_overrides_runpath" = yes ||
- test "$enable_shared" = no; then
- # Fast installation is not necessary
- enable_fast_install=needless
-fi
-
-
-
-
-
-
- if test "x$enable_dlopen" != xyes; then
- enable_dlopen=unknown
- enable_dlopen_self=unknown
- enable_dlopen_self_static=unknown
-else
- lt_cv_dlopen=no
- lt_cv_dlopen_libs=
-
- case $host_os in
- beos*)
- lt_cv_dlopen="load_add_on"
- lt_cv_dlopen_libs=
- lt_cv_dlopen_self=yes
- ;;
-
- mingw* | pw32* | cegcc*)
- lt_cv_dlopen="LoadLibrary"
- lt_cv_dlopen_libs=
- ;;
-
- cygwin*)
- lt_cv_dlopen="dlopen"
- lt_cv_dlopen_libs=
- ;;
-
- darwin*)
- # if libdl is installed we need to link against it
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
-$as_echo_n "checking for dlopen in -ldl... " >&6; }
-if ${ac_cv_lib_dl_dlopen+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-ldl $LIBS"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char dlopen ();
-int
-main ()
-{
-return dlopen ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_lib_dl_dlopen=yes
-else
- ac_cv_lib_dl_dlopen=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
-$as_echo "$ac_cv_lib_dl_dlopen" >&6; }
-if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
- lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
-else
-
- lt_cv_dlopen="dyld"
- lt_cv_dlopen_libs=
- lt_cv_dlopen_self=yes
-
-fi
-
- ;;
-
- *)
- ac_fn_c_check_func "$LINENO" "shl_load" "ac_cv_func_shl_load"
-if test "x$ac_cv_func_shl_load" = xyes; then :
- lt_cv_dlopen="shl_load"
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5
-$as_echo_n "checking for shl_load in -ldld... " >&6; }
-if ${ac_cv_lib_dld_shl_load+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-ldld $LIBS"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char shl_load ();
-int
-main ()
-{
-return shl_load ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_lib_dld_shl_load=yes
-else
- ac_cv_lib_dld_shl_load=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5
-$as_echo "$ac_cv_lib_dld_shl_load" >&6; }
-if test "x$ac_cv_lib_dld_shl_load" = xyes; then :
- lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"
-else
- ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen"
-if test "x$ac_cv_func_dlopen" = xyes; then :
- lt_cv_dlopen="dlopen"
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
-$as_echo_n "checking for dlopen in -ldl... " >&6; }
-if ${ac_cv_lib_dl_dlopen+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-ldl $LIBS"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char dlopen ();
-int
-main ()
-{
-return dlopen ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_lib_dl_dlopen=yes
-else
- ac_cv_lib_dl_dlopen=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
-$as_echo "$ac_cv_lib_dl_dlopen" >&6; }
-if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
- lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5
-$as_echo_n "checking for dlopen in -lsvld... " >&6; }
-if ${ac_cv_lib_svld_dlopen+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-lsvld $LIBS"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char dlopen ();
-int
-main ()
-{
-return dlopen ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_lib_svld_dlopen=yes
-else
- ac_cv_lib_svld_dlopen=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5
-$as_echo "$ac_cv_lib_svld_dlopen" >&6; }
-if test "x$ac_cv_lib_svld_dlopen" = xyes; then :
- lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5
-$as_echo_n "checking for dld_link in -ldld... " >&6; }
-if ${ac_cv_lib_dld_dld_link+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-ldld $LIBS"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char dld_link ();
-int
-main ()
-{
-return dld_link ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_lib_dld_dld_link=yes
-else
- ac_cv_lib_dld_dld_link=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_dld_link" >&5
-$as_echo "$ac_cv_lib_dld_dld_link" >&6; }
-if test "x$ac_cv_lib_dld_dld_link" = xyes; then :
- lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"
-fi
-
-
-fi
-
-
-fi
-
-
-fi
-
-
-fi
-
-
-fi
-
- ;;
- esac
-
- if test "x$lt_cv_dlopen" != xno; then
- enable_dlopen=yes
- else
- enable_dlopen=no
- fi
-
- case $lt_cv_dlopen in
- dlopen)
- save_CPPFLAGS="$CPPFLAGS"
- test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
-
- save_LDFLAGS="$LDFLAGS"
- wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
-
- save_LIBS="$LIBS"
- LIBS="$lt_cv_dlopen_libs $LIBS"
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a program can dlopen itself" >&5
-$as_echo_n "checking whether a program can dlopen itself... " >&6; }
-if ${lt_cv_dlopen_self+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test "$cross_compiling" = yes; then :
- lt_cv_dlopen_self=cross
-else
- lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
- lt_status=$lt_dlunknown
- cat > conftest.$ac_ext <<_LT_EOF
-#line 11158 "configure"
-#include "confdefs.h"
-
-#if HAVE_DLFCN_H
-#include <dlfcn.h>
-#endif
-
-#include <stdio.h>
-
-#ifdef RTLD_GLOBAL
-# define LT_DLGLOBAL RTLD_GLOBAL
-#else
-# ifdef DL_GLOBAL
-# define LT_DLGLOBAL DL_GLOBAL
-# else
-# define LT_DLGLOBAL 0
-# endif
-#endif
-
-/* We may have to define LT_DLLAZY_OR_NOW in the command line if we
- find out it does not work in some platform. */
-#ifndef LT_DLLAZY_OR_NOW
-# ifdef RTLD_LAZY
-# define LT_DLLAZY_OR_NOW RTLD_LAZY
-# else
-# ifdef DL_LAZY
-# define LT_DLLAZY_OR_NOW DL_LAZY
-# else
-# ifdef RTLD_NOW
-# define LT_DLLAZY_OR_NOW RTLD_NOW
-# else
-# ifdef DL_NOW
-# define LT_DLLAZY_OR_NOW DL_NOW
-# else
-# define LT_DLLAZY_OR_NOW 0
-# endif
-# endif
-# endif
-# endif
-#endif
-
-/* When -fvisbility=hidden is used, assume the code has been annotated
- correspondingly for the symbols needed. */
-#if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
-void fnord () __attribute__((visibility("default")));
-#endif
-
-void fnord () { int i=42; }
-int main ()
-{
- void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
- int status = $lt_dlunknown;
-
- if (self)
- {
- if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
- else
- {
- if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
- else puts (dlerror ());
- }
- /* dlclose (self); */
- }
- else
- puts (dlerror ());
-
- return status;
-}
-_LT_EOF
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
- (eval $ac_link) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then
- (./conftest; exit; ) >&5 2>/dev/null
- lt_status=$?
- case x$lt_status in
- x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;;
- x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;;
- x$lt_dlunknown|x*) lt_cv_dlopen_self=no ;;
- esac
- else :
- # compilation failed
- lt_cv_dlopen_self=no
- fi
-fi
-rm -fr conftest*
-
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self" >&5
-$as_echo "$lt_cv_dlopen_self" >&6; }
-
- if test "x$lt_cv_dlopen_self" = xyes; then
- wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a statically linked program can dlopen itself" >&5
-$as_echo_n "checking whether a statically linked program can dlopen itself... " >&6; }
-if ${lt_cv_dlopen_self_static+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test "$cross_compiling" = yes; then :
- lt_cv_dlopen_self_static=cross
-else
- lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
- lt_status=$lt_dlunknown
- cat > conftest.$ac_ext <<_LT_EOF
-#line 11264 "configure"
-#include "confdefs.h"
-
-#if HAVE_DLFCN_H
-#include <dlfcn.h>
-#endif
-
-#include <stdio.h>
-
-#ifdef RTLD_GLOBAL
-# define LT_DLGLOBAL RTLD_GLOBAL
-#else
-# ifdef DL_GLOBAL
-# define LT_DLGLOBAL DL_GLOBAL
-# else
-# define LT_DLGLOBAL 0
-# endif
-#endif
-
-/* We may have to define LT_DLLAZY_OR_NOW in the command line if we
- find out it does not work in some platform. */
-#ifndef LT_DLLAZY_OR_NOW
-# ifdef RTLD_LAZY
-# define LT_DLLAZY_OR_NOW RTLD_LAZY
-# else
-# ifdef DL_LAZY
-# define LT_DLLAZY_OR_NOW DL_LAZY
-# else
-# ifdef RTLD_NOW
-# define LT_DLLAZY_OR_NOW RTLD_NOW
-# else
-# ifdef DL_NOW
-# define LT_DLLAZY_OR_NOW DL_NOW
-# else
-# define LT_DLLAZY_OR_NOW 0
-# endif
-# endif
-# endif
-# endif
-#endif
-
-/* When -fvisbility=hidden is used, assume the code has been annotated
- correspondingly for the symbols needed. */
-#if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
-void fnord () __attribute__((visibility("default")));
-#endif
-
-void fnord () { int i=42; }
-int main ()
-{
- void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
- int status = $lt_dlunknown;
-
- if (self)
- {
- if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
- else
- {
- if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
- else puts (dlerror ());
- }
- /* dlclose (self); */
- }
- else
- puts (dlerror ());
-
- return status;
-}
-_LT_EOF
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
- (eval $ac_link) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then
- (./conftest; exit; ) >&5 2>/dev/null
- lt_status=$?
- case x$lt_status in
- x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;;
- x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;;
- x$lt_dlunknown|x*) lt_cv_dlopen_self_static=no ;;
- esac
- else :
- # compilation failed
- lt_cv_dlopen_self_static=no
- fi
-fi
-rm -fr conftest*
-
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self_static" >&5
-$as_echo "$lt_cv_dlopen_self_static" >&6; }
- fi
-
- CPPFLAGS="$save_CPPFLAGS"
- LDFLAGS="$save_LDFLAGS"
- LIBS="$save_LIBS"
- ;;
- esac
-
- case $lt_cv_dlopen_self in
- yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
- *) enable_dlopen_self=unknown ;;
- esac
-
- case $lt_cv_dlopen_self_static in
- yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
- *) enable_dlopen_self_static=unknown ;;
- esac
-fi
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-striplib=
-old_striplib=
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stripping libraries is possible" >&5
-$as_echo_n "checking whether stripping libraries is possible... " >&6; }
-if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then
- test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
- test -z "$striplib" && striplib="$STRIP --strip-unneeded"
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-else
-# FIXME - insert some real tests, host_os isn't really good enough
- case $host_os in
- darwin*)
- if test -n "$STRIP" ; then
- striplib="$STRIP -x"
- old_striplib="$STRIP -S"
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- fi
- ;;
- *)
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- ;;
- esac
-fi
-
-
-
-
-
-
-
-
-
-
-
-
- # Report which library types will actually be built
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libtool supports shared libraries" >&5
-$as_echo_n "checking if libtool supports shared libraries... " >&6; }
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $can_build_shared" >&5
-$as_echo "$can_build_shared" >&6; }
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries" >&5
-$as_echo_n "checking whether to build shared libraries... " >&6; }
- test "$can_build_shared" = "no" && enable_shared=no
-
- # On AIX, shared libraries and static libraries use the same namespace, and
- # are all built from PIC.
- case $host_os in
- aix3*)
- test "$enable_shared" = yes && enable_static=no
- if test -n "$RANLIB"; then
- archive_cmds="$archive_cmds~\$RANLIB \$lib"
- postinstall_cmds='$RANLIB $lib'
- fi
- ;;
-
- aix[4-9]*)
- if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
- test "$enable_shared" = yes && enable_static=no
- fi
- ;;
- esac
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5
-$as_echo "$enable_shared" >&6; }
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build static libraries" >&5
-$as_echo_n "checking whether to build static libraries... " >&6; }
- # Make sure either enable_shared or enable_static is yes.
- test "$enable_shared" = yes || enable_static=yes
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_static" >&5
-$as_echo "$enable_static" >&6; }
-
-
-
-
-fi
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-CC="$lt_save_CC"
-
-
-
-
-
-
-
-
-
-
-
-
-
- ac_config_commands="$ac_config_commands libtool"
-
-
-
-
-# Only expand once:
-
-
-
-# AC_PLUGINS setting $plugins is called by ACX_LARGEFILE.
-
-# The tests for host and target for $enable_largefile require
-# canonical names.
-
-
-
-# As the $enable_largefile decision depends on --enable-plugins we must set it
-# even in directories otherwise not depending on the $plugins option.
-
-
- maybe_plugins=no
- for ac_header in dlfcn.h
-do :
- ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default
-"
-if test "x$ac_cv_header_dlfcn_h" = xyes; then :
- cat >>confdefs.h <<_ACEOF
-#define HAVE_DLFCN_H 1
-_ACEOF
- maybe_plugins=yes
-fi
-
-done
-
- for ac_header in windows.h
-do :
- ac_fn_c_check_header_compile "$LINENO" "windows.h" "ac_cv_header_windows_h" "$ac_includes_default
-"
-if test "x$ac_cv_header_windows_h" = xyes; then :
- cat >>confdefs.h <<_ACEOF
-#define HAVE_WINDOWS_H 1
-_ACEOF
- maybe_plugins=yes
-fi
-
-done
-
-
- # Check whether --enable-plugins was given.
-if test "${enable_plugins+set}" = set; then :
- enableval=$enable_plugins; case "${enableval}" in
- no) plugins=no ;;
- *) plugins=yes
- if test "$maybe_plugins" != "yes" ; then
- as_fn_error $? "Building with plugin support requires a host that supports dlopen." "$LINENO" 5
- fi ;;
- esac
-else
- plugins=$maybe_plugins
-
-fi
-
- if test "$plugins" = "yes"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing dlsym" >&5
-$as_echo_n "checking for library containing dlsym... " >&6; }
-if ${ac_cv_search_dlsym+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_func_search_save_LIBS=$LIBS
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char dlsym ();
-int
-main ()
-{
-return dlsym ();
- ;
- return 0;
-}
-_ACEOF
-for ac_lib in '' dl; do
- if test -z "$ac_lib"; then
- ac_res="none required"
- else
- ac_res=-l$ac_lib
- LIBS="-l$ac_lib $ac_func_search_save_LIBS"
- fi
- if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_search_dlsym=$ac_res
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext
- if ${ac_cv_search_dlsym+:} false; then :
- break
-fi
-done
-if ${ac_cv_search_dlsym+:} false; then :
-
-else
- ac_cv_search_dlsym=no
-fi
-rm conftest.$ac_ext
-LIBS=$ac_func_search_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_dlsym" >&5
-$as_echo "$ac_cv_search_dlsym" >&6; }
-ac_res=$ac_cv_search_dlsym
-if test "$ac_res" != no; then :
- test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
-
-fi
-
- fi
-
-
-case "${host}" in
- sparc-*-solaris*|i?86-*-solaris*)
- # On native 32-bit Solaris/SPARC and x86, large-file and procfs support
- # were mutually exclusive until Solaris 11.3. Without procfs support,
- # the bfd/ elf module cannot provide certain routines such as
- # elfcore_write_prpsinfo or elfcore_write_prstatus. So unless the user
- # explicitly requested large-file support through the
- # --enable-largefile switch, disable large-file support in favor of
- # procfs support.
- #
- # Check if <sys/procfs.h> is incompatible with large-file support.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#define _FILE_OFFSET_BITS 64
-#define _STRUCTURED_PROC 1
-#include <sys/procfs.h>
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- acx_cv_procfs_lfs=yes
-else
- acx_cv_procfs_lfs=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- #
- # Forcefully disable large-file support only if necessary, gdb is in
- # tree and enabled.
- if test "${target}" = "${host}" -a "$acx_cv_procfs_lfs" = no \
- -a -d $srcdir/../gdb -a "$enable_gdb" != no; then
- : ${enable_largefile="no"}
- if test "$plugins" = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
-plugin support disabled; require large-file support which is incompatible with GDB." >&5
-$as_echo "$as_me: WARNING:
-plugin support disabled; require large-file support which is incompatible with GDB." >&2;}
- plugins=no
- fi
- fi
- #
- # Explicitly undef _FILE_OFFSET_BITS if enable_largefile=no for the
- # benefit of g++ 9+ which predefines it on Solaris.
- if test "$enable_largefile" = no; then
- LARGEFILE_CPPFLAGS="-U_FILE_OFFSET_BITS"
-
- fi
- ;;
-esac
-
-# Check whether --enable-largefile was given.
-if test "${enable_largefile+set}" = set; then :
- enableval=$enable_largefile;
-fi
-
-if test "$enable_largefile" != no; then
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
-$as_echo_n "checking for special C compiler options needed for large files... " >&6; }
-if ${ac_cv_sys_largefile_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_cv_sys_largefile_CC=no
- if test "$GCC" != yes; then
- ac_save_CC=$CC
- while :; do
- # IRIX 6.2 and later do not support large files by default,
- # so use the C compiler's -n32 option if that helps.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <sys/types.h>
- /* Check that off_t can represent 2**63 - 1 correctly.
- We can't simply define LARGE_OFF_T to be 9223372036854775807,
- since some C++ compilers masquerading as C compilers
- incorrectly reject 9223372036854775807. */
-#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
- int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
- && LARGE_OFF_T % 2147483647 == 1)
- ? 1 : -1];
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
- if ac_fn_c_try_compile "$LINENO"; then :
- break
-fi
-rm -f core conftest.err conftest.$ac_objext
- CC="$CC -n32"
- if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_sys_largefile_CC=' -n32'; break
-fi
-rm -f core conftest.err conftest.$ac_objext
- break
- done
- CC=$ac_save_CC
- rm -f conftest.$ac_ext
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
-$as_echo "$ac_cv_sys_largefile_CC" >&6; }
- if test "$ac_cv_sys_largefile_CC" != no; then
- CC=$CC$ac_cv_sys_largefile_CC
- fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
-$as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
-if ${ac_cv_sys_file_offset_bits+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- while :; do
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <sys/types.h>
- /* Check that off_t can represent 2**63 - 1 correctly.
- We can't simply define LARGE_OFF_T to be 9223372036854775807,
- since some C++ compilers masquerading as C compilers
- incorrectly reject 9223372036854775807. */
-#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
- int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
- && LARGE_OFF_T % 2147483647 == 1)
- ? 1 : -1];
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_sys_file_offset_bits=no; break
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#define _FILE_OFFSET_BITS 64
-#include <sys/types.h>
- /* Check that off_t can represent 2**63 - 1 correctly.
- We can't simply define LARGE_OFF_T to be 9223372036854775807,
- since some C++ compilers masquerading as C compilers
- incorrectly reject 9223372036854775807. */
-#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
- int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
- && LARGE_OFF_T % 2147483647 == 1)
- ? 1 : -1];
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_sys_file_offset_bits=64; break
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- ac_cv_sys_file_offset_bits=unknown
- break
-done
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
-$as_echo "$ac_cv_sys_file_offset_bits" >&6; }
-case $ac_cv_sys_file_offset_bits in #(
- no | unknown) ;;
- *)
-cat >>confdefs.h <<_ACEOF
-#define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
-_ACEOF
-;;
-esac
-rm -rf conftest*
- if test $ac_cv_sys_file_offset_bits = unknown; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
-$as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
-if ${ac_cv_sys_large_files+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- while :; do
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <sys/types.h>
- /* Check that off_t can represent 2**63 - 1 correctly.
- We can't simply define LARGE_OFF_T to be 9223372036854775807,
- since some C++ compilers masquerading as C compilers
- incorrectly reject 9223372036854775807. */
-#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
- int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
- && LARGE_OFF_T % 2147483647 == 1)
- ? 1 : -1];
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_sys_large_files=no; break
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#define _LARGE_FILES 1
-#include <sys/types.h>
- /* Check that off_t can represent 2**63 - 1 correctly.
- We can't simply define LARGE_OFF_T to be 9223372036854775807,
- since some C++ compilers masquerading as C compilers
- incorrectly reject 9223372036854775807. */
-#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
- int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
- && LARGE_OFF_T % 2147483647 == 1)
- ? 1 : -1];
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_sys_large_files=1; break
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- ac_cv_sys_large_files=unknown
- break
-done
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
-$as_echo "$ac_cv_sys_large_files" >&6; }
-case $ac_cv_sys_large_files in #(
- no | unknown) ;;
- *)
-cat >>confdefs.h <<_ACEOF
-#define _LARGE_FILES $ac_cv_sys_large_files
-_ACEOF
-;;
-esac
-rm -rf conftest*
- fi
-
-
-fi
-
-
-
-case "${target}" in
- hppa*64*-*-*) ;;
- *-*-*aout*| i[3-7]86-*-msdos* | ns32k-*-* | pdp11-*-*)
- if test "$plugins" = "yes"; then
- if test "${enable_plugins+set}" = set; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Enabling plugins for AOUT is experimental" >&5
-$as_echo "$as_me: WARNING: Enabling plugins for AOUT is experimental" >&2;}
- else
- plugins=no
- fi
- fi ;;
- hppa*-*-hpux* | *-*-*vms* | \
- powerpc*-*-aix* | powerpc-*-beos* | powerpc-*-macos* | rs6000-*-*)
- if test "$plugins" = "yes"; then
- if test "${enable_plugins+set}" = set; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Enabling plugins may result in ar creating non-standard archives for ${target}" >&5
-$as_echo "$as_me: WARNING: Enabling plugins may result in ar creating non-standard archives for ${target}" >&2;}
- else
- plugins=no
- fi
- fi ;;
-esac
-
- if test "$plugins" = "yes"; then
- PLUGINS_TRUE=
- PLUGINS_FALSE='#'
-else
- PLUGINS_TRUE='#'
- PLUGINS_FALSE=
-fi
-
-
-ac_checking=
-. ${srcdir}/development.sh
-test "$development" = true && ac_checking=yes
-# Check whether --enable-checking was given.
-if test "${enable_checking+set}" = set; then :
- enableval=$enable_checking; case "${enableval}" in
- no|none) ac_checking= ;;
- *) ac_checking=yes ;;
-esac
-fi
-if test x$ac_checking != x ; then
-
-$as_echo "#define ENABLE_CHECKING 1" >>confdefs.h
-
-fi
-
-# Check whether --enable-64-bit-bfd was given.
-if test "${enable_64_bit_bfd+set}" = set; then :
- enableval=$enable_64_bit_bfd; case $enableval in #(
- yes|no) :
- ;; #(
- *) :
- as_fn_error $? "bad value ${enableval} for 64-bit-bfd option" "$LINENO" 5 ;; #(
- *) :
- ;;
-esac
-else
- enable_64_bit_bfd=no
-fi
-
-
-if test "x$enable_64_bit_bfd" = "xno"; then :
- # The cast to long int works around a bug in the HP C Compiler
-# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
-# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
-# This bug is HP SR number 8606223364.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of void *" >&5
-$as_echo_n "checking size of void *... " >&6; }
-if ${ac_cv_sizeof_void_p+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (void *))" "ac_cv_sizeof_void_p" "$ac_includes_default"; then :
-
-else
- if test "$ac_cv_type_void_p" = yes; then
- { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error 77 "cannot compute sizeof (void *)
-See \`config.log' for more details" "$LINENO" 5; }
- else
- ac_cv_sizeof_void_p=0
- fi
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_void_p" >&5
-$as_echo "$ac_cv_sizeof_void_p" >&6; }
-
-
-
-cat >>confdefs.h <<_ACEOF
-#define SIZEOF_VOID_P $ac_cv_sizeof_void_p
-_ACEOF
-
-
- if test "x$ac_cv_sizeof_void_p" = "x8"; then :
- enable_64_bit_bfd=yes
-fi
-
-fi
-
- if test "x$enable_64_bit_bfd" = "xyes"; then
- ENABLE_BFD_64_BIT_TRUE=
- ENABLE_BFD_64_BIT_FALSE='#'
-else
- ENABLE_BFD_64_BIT_TRUE='#'
- ENABLE_BFD_64_BIT_FALSE=
-fi
-
-
-if test $enable_64_bit_bfd = yes ; then
- want64=true
-else
- want64=false
-fi
-
-# Check whether --enable-targets was given.
-if test "${enable_targets+set}" = set; then :
- enableval=$enable_targets; case "${enableval}" in
- yes | "") as_fn_error $? "enable-targets option must specify target names or 'all'" "$LINENO" 5
- ;;
- no) enable_targets= ;;
- *) enable_targets=$enableval ;;
-esac
-fi
-
-# Check whether --enable-64_bit_archive was given.
-if test "${enable_64_bit_archive+set}" = set; then :
- enableval=$enable_64_bit_archive; case "${enableval}" in
- yes) want_64_bit_archive=true ;;
- no) want_64_bit_archive=false ;;
- *) as_fn_error $? "bad value ${enableval} for 64-bit-archive option" "$LINENO" 5 ;;
-esac
-else
- want_64_bit_archive=unset
-fi
-
-
-# Check whether --with-mmap was given.
-if test "${with_mmap+set}" = set; then :
- withval=$with_mmap; case "${withval}" in
- yes) want_mmap=true ;;
- no) want_mmap=false ;;
- *) as_fn_error $? "bad value ${withval} for BFD with-mmap option" "$LINENO" 5 ;;
-esac
-else
- want_mmap=true
-fi
-
-# Check whether --enable-secureplt was given.
-if test "${enable_secureplt+set}" = set; then :
- enableval=$enable_secureplt; case "${enableval}" in
- yes) use_secureplt=true ;;
- no) use_secureplt=false ;;
- *) as_fn_error $? "bad value ${enableval} for secureplt option" "$LINENO" 5 ;;
-esac
-else
- use_secureplt=true
-fi
-if test $use_secureplt = true; then
-
-$as_echo "#define USE_SECUREPLT 1" >>confdefs.h
-
-fi
-
-# Decide if -z separate-code should be enabled in ELF linker by default.
-ac_default_ld_z_separate_code=unset
-# Check whether --enable-separate-code was given.
-if test "${enable_separate_code+set}" = set; then :
- enableval=$enable_separate_code; case "${enableval}" in
- yes) ac_default_ld_z_separate_code=1 ;;
- no) ac_default_ld_z_separate_code=0 ;;
-esac
-fi
-
-# Enable -z separate-code by default for Linux/x86.
-case "${target}" in
-i[3-7]86-*-linux-* | x86_64-*-linux-*)
- if test ${ac_default_ld_z_separate_code} = unset; then
- ac_default_ld_z_separate_code=1
- fi
- ;;
-esac
-if test "${ac_default_ld_z_separate_code}" = unset; then
- ac_default_ld_z_separate_code=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define DEFAULT_LD_Z_SEPARATE_CODE $ac_default_ld_z_separate_code
-_ACEOF
-
-
-# Check whether --enable-leading-mingw64-underscores was given.
-if test "${enable_leading_mingw64_underscores+set}" = set; then :
- enableval=$enable_leading_mingw64_underscores;
-fi
-
-if test x"$enable_leading_mingw64_underscores" = xyes ; then :
-
-$as_echo "#define USE_MINGW64_LEADING_UNDERSCORES 1" >>confdefs.h
-
-fi
-
-DEBUGDIR=${libdir}/debug
-
-# Check whether --with-separate-debug-dir was given.
-if test "${with_separate_debug_dir+set}" = set; then :
- withval=$with_separate_debug_dir; DEBUGDIR="${withval}"
-fi
-
-
-
-
-
-# Check whether --with-pkgversion was given.
-if test "${with_pkgversion+set}" = set; then :
- withval=$with_pkgversion; case "$withval" in
- yes) as_fn_error $? "package version not specified" "$LINENO" 5 ;;
- no) PKGVERSION= ;;
- *) PKGVERSION="($withval) " ;;
- esac
-else
- PKGVERSION="(GNU Binutils) "
-
-fi
-
-
-
-
-
-# Check whether --with-bugurl was given.
-if test "${with_bugurl+set}" = set; then :
- withval=$with_bugurl; case "$withval" in
- yes) as_fn_error $? "bug URL not specified" "$LINENO" 5 ;;
- no) BUGURL=
- ;;
- *) BUGURL="$withval"
- ;;
- esac
-else
- BUGURL="https://sourceware.org/bugzilla/"
-
-fi
-
- case ${BUGURL} in
- "")
- REPORT_BUGS_TO=
- REPORT_BUGS_TEXI=
- ;;
- *)
- REPORT_BUGS_TO="<$BUGURL>"
- REPORT_BUGS_TEXI=@uref{`echo "$BUGURL" | sed 's/@/@@/g'`}
- ;;
- esac;
-
-
-
-
-
-# Set the 'development' global.
-. $srcdir/../bfd/development.sh
-
-# Set acp_cpp_for_build variable
-ac_cpp_for_build="$CC_FOR_BUILD -E $CPPFLAGS_FOR_BUILD"
-
-# Default set of GCC warnings to enable.
-GCC_WARN_CFLAGS="-W -Wall -Wstrict-prototypes -Wmissing-prototypes"
-GCC_WARN_CFLAGS_FOR_BUILD="-W -Wall -Wstrict-prototypes -Wmissing-prototypes"
-
-# Add -Wshadow if the compiler is a sufficiently recent version of GCC.
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-__GNUC__
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "(^[0-3]$|^__GNUC__$)" >/dev/null 2>&1; then :
-
-else
- GCC_WARN_CFLAGS="$GCC_WARN_CFLAGS -Wshadow"
-fi
-rm -f conftest*
-
-
-# Add -Wstack-usage if the compiler is a sufficiently recent version of GCC.
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-__GNUC__
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "(^[0-4]$|^__GNUC__$)" >/dev/null 2>&1; then :
-
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-__clang__
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "^__clang__$" >/dev/null 2>&1; then :
- GCC_WARN_CFLAGS="$GCC_WARN_CFLAGS -Wstack-usage=262144"
-fi
-rm -f conftest*
-
-fi
-rm -f conftest*
-
-
-# Set WARN_WRITE_STRINGS if the compiler supports -Wwrite-strings.
-WARN_WRITE_STRINGS=""
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-__GNUC__
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "(^[0-3]$|^__GNUC__$)" >/dev/null 2>&1; then :
-
-else
- WARN_WRITE_STRINGS="-Wwrite-strings"
-fi
-rm -f conftest*
-
-
-# Verify CC_FOR_BUILD to be compatible with warning flags
-
-# Add -Wshadow if the compiler is a sufficiently recent version of GCC.
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-__GNUC__
-_ACEOF
-if (eval "$ac_cpp_for_build conftest.$ac_ext") 2>&5 |
- $EGREP "(^[0-3]$|^__GNUC__$)" >/dev/null 2>&1; then :
-
-else
- GCC_WARN_CFLAGS_FOR_BUILD="$GCC_WARN_CFLAGS_FOR_BUILD -Wshadow"
-fi
-rm -f conftest*
-
-
-# Add -Wstack-usage if the compiler is a sufficiently recent version of GCC.
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-__GNUC__
-_ACEOF
-if (eval "$ac_cpp_for_build conftest.$ac_ext") 2>&5 |
- $EGREP "(^[0-4]$|^__GNUC__$)" >/dev/null 2>&1; then :
-
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-__clang__
-_ACEOF
-if (eval "$ac_cpp_for_build conftest.$ac_ext") 2>&5 |
- $EGREP "^__clang__$" >/dev/null 2>&1; then :
- GCC_WARN_CFLAGS_FOR_BUILD="$GCC_WARN_CFLAGS_FOR_BUILD -Wstack-usage=262144"
-fi
-rm -f conftest*
-
-fi
-rm -f conftest*
-
-
-# Check whether --enable-werror was given.
-if test "${enable_werror+set}" = set; then :
- enableval=$enable_werror; case "${enableval}" in
- yes | y) ERROR_ON_WARNING="yes" ;;
- no | n) ERROR_ON_WARNING="no" ;;
- *) as_fn_error $? "bad value ${enableval} for --enable-werror" "$LINENO" 5 ;;
- esac
-fi
-
-
-# Disable -Wformat by default when using gcc on mingw
-case "${host}" in
- *-*-mingw32*)
- if test "${GCC}" = yes -a -z "${ERROR_ON_WARNING}" ; then
- GCC_WARN_CFLAGS="$GCC_WARN_CFLAGS -Wno-format"
- GCC_WARN_CFLAGS_FOR_BUILD="$GCC_WARN_CFLAGS_FOR_BUILD -Wno-format"
- fi
- ;;
- *) ;;
-esac
-
-# Enable -Werror by default when using gcc. Turn it off for releases.
-if test "${GCC}" = yes -a -z "${ERROR_ON_WARNING}" -a "$development" = true ; then
- ERROR_ON_WARNING=yes
-fi
-
-NO_WERROR=
-if test "${ERROR_ON_WARNING}" = yes ; then
- GCC_WARN_CFLAGS="$GCC_WARN_CFLAGS -Werror"
- GCC_WARN_CFLAGS_FOR_BUILD="$GCC_WARN_CFLAGS_FOR_BUILD -Werror"
- NO_WERROR="-Wno-error"
-fi
-
-if test "${GCC}" = yes ; then
- WARN_CFLAGS="${GCC_WARN_CFLAGS}"
- WARN_CFLAGS_FOR_BUILD="${GCC_WARN_CFLAGS_FOR_BUILD}"
-fi
-
-# Check whether --enable-build-warnings was given.
-if test "${enable_build_warnings+set}" = set; then :
- enableval=$enable_build_warnings; case "${enableval}" in
- yes) WARN_CFLAGS="${GCC_WARN_CFLAGS}"
- WARN_CFLAGS_FOR_BUILD="${GCC_WARN_CFLAGS_FOR_BUILD}";;
- no) if test "${GCC}" = yes ; then
- WARN_CFLAGS="-w"
- WARN_CFLAGS_FOR_BUILD="-w"
- fi;;
- ,*) t=`echo "${enableval}" | sed -e "s/,/ /g"`
- WARN_CFLAGS="${GCC_WARN_CFLAGS} ${t}"
- WARN_CFLAGS_FOR_BUILD="${GCC_WARN_CFLAGS_FOR_BUILD} ${t}";;
- *,) t=`echo "${enableval}" | sed -e "s/,/ /g"`
- WARN_CFLAGS="${t} ${GCC_WARN_CFLAGS}"
- WARN_CFLAGS_FOR_BUILD="${t} ${GCC_WARN_CFLAGS_FOR_BUILD}";;
- *) WARN_CFLAGS=`echo "${enableval}" | sed -e "s/,/ /g"`
- WARN_CFLAGS_FOR_BUILD=`echo "${enableval}" | sed -e "s/,/ /g"`;;
-esac
-fi
-
-
-if test x"$silent" != x"yes" && test x"$WARN_CFLAGS" != x""; then
- echo "Setting warning flags = $WARN_CFLAGS" 6>&1
-fi
-
-
-
-
-
-
-
-ac_config_headers="$ac_config_headers config.h:config.in"
-
-
-# PR 14072
-
-
-if test -z "$target" ; then
- as_fn_error $? "Unrecognized target system type; please check config.sub." "$LINENO" 5
-fi
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable maintainer-specific portions of Makefiles" >&5
-$as_echo_n "checking whether to enable maintainer-specific portions of Makefiles... " >&6; }
- # Check whether --enable-maintainer-mode was given.
-if test "${enable_maintainer_mode+set}" = set; then :
- enableval=$enable_maintainer_mode; USE_MAINTAINER_MODE=$enableval
-else
- USE_MAINTAINER_MODE=no
-fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_MAINTAINER_MODE" >&5
-$as_echo "$USE_MAINTAINER_MODE" >&6; }
- if test $USE_MAINTAINER_MODE = yes; then
- MAINTAINER_MODE_TRUE=
- MAINTAINER_MODE_FALSE='#'
-else
- MAINTAINER_MODE_TRUE='#'
- MAINTAINER_MODE_FALSE=
-fi
-
- MAINT=$MAINTAINER_MODE_TRUE
-
-
- if false; then
- GENINSRC_NEVER_TRUE=
- GENINSRC_NEVER_FALSE='#'
-else
- GENINSRC_NEVER_TRUE='#'
- GENINSRC_NEVER_FALSE=
-fi
-
- case ${build_alias} in
- "") build_noncanonical=${build} ;;
- *) build_noncanonical=${build_alias} ;;
-esac
-
- case ${host_alias} in
- "") host_noncanonical=${build_noncanonical} ;;
- *) host_noncanonical=${host_alias} ;;
-esac
-
- case ${target_alias} in
- "") target_noncanonical=${host_noncanonical} ;;
- *) target_noncanonical=${target_alias} ;;
-esac
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to install libbfd" >&5
-$as_echo_n "checking whether to install libbfd... " >&6; }
- # Check whether --enable-install-libbfd was given.
-if test "${enable_install_libbfd+set}" = set; then :
- enableval=$enable_install_libbfd; install_libbfd_p=$enableval
-else
- if test "${host}" = "${target}" || test "$enable_shared" = "yes"; then
- install_libbfd_p=yes
- else
- install_libbfd_p=no
- fi
-fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $install_libbfd_p" >&5
-$as_echo "$install_libbfd_p" >&6; }
- if test $install_libbfd_p = yes; then
- INSTALL_LIBBFD_TRUE=
- INSTALL_LIBBFD_FALSE='#'
-else
- INSTALL_LIBBFD_TRUE='#'
- INSTALL_LIBBFD_FALSE=
-fi
-
- # Need _noncanonical variables for this.
-
-
-
-
- # libbfd.a is a host library containing target dependent code
- bfdlibdir='$(libdir)'
- bfdincludedir='$(includedir)'
- if test "${host}" != "${target}"; then
- bfdlibdir='$(exec_prefix)/$(host_noncanonical)/$(target_noncanonical)/lib'
- bfdincludedir='$(exec_prefix)/$(host_noncanonical)/$(target_noncanonical)/include'
- fi
-
-
-
-
-
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
-$as_echo_n "checking whether byte ordering is bigendian... " >&6; }
-if ${ac_cv_c_bigendian+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_cv_c_bigendian=unknown
- # See if we're dealing with a universal compiler.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#ifndef __APPLE_CC__
- not a universal capable compiler
- #endif
- typedef int dummy;
-
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
-
- # Check for potential -arch flags. It is not universal unless
- # there are at least two -arch flags with different values.
- ac_arch=
- ac_prev=
- for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
- if test -n "$ac_prev"; then
- case $ac_word in
- i?86 | x86_64 | ppc | ppc64)
- if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
- ac_arch=$ac_word
- else
- ac_cv_c_bigendian=universal
- break
- fi
- ;;
- esac
- ac_prev=
- elif test "x$ac_word" = "x-arch"; then
- ac_prev=arch
- fi
- done
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- if test $ac_cv_c_bigendian = unknown; then
- # See if sys/param.h defines the BYTE_ORDER macro.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <sys/types.h>
- #include <sys/param.h>
-
-int
-main ()
-{
-#if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
- && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
- && LITTLE_ENDIAN)
- bogus endian macros
- #endif
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- # It does; now see whether it defined to BIG_ENDIAN or not.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <sys/types.h>
- #include <sys/param.h>
-
-int
-main ()
-{
-#if BYTE_ORDER != BIG_ENDIAN
- not big endian
- #endif
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_c_bigendian=yes
-else
- ac_cv_c_bigendian=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- fi
- if test $ac_cv_c_bigendian = unknown; then
- # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <limits.h>
-
-int
-main ()
-{
-#if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
- bogus endian macros
- #endif
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- # It does; now see whether it defined to _BIG_ENDIAN or not.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <limits.h>
-
-int
-main ()
-{
-#ifndef _BIG_ENDIAN
- not big endian
- #endif
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_c_bigendian=yes
-else
- ac_cv_c_bigendian=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- fi
- if test $ac_cv_c_bigendian = unknown; then
- # Compile a test program.
- if test "$cross_compiling" = yes; then :
- # Try to guess by grepping values from an object file.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-short int ascii_mm[] =
- { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
- short int ascii_ii[] =
- { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
- int use_ascii (int i) {
- return ascii_mm[i] + ascii_ii[i];
- }
- short int ebcdic_ii[] =
- { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
- short int ebcdic_mm[] =
- { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
- int use_ebcdic (int i) {
- return ebcdic_mm[i] + ebcdic_ii[i];
- }
- extern int foo;
-
-int
-main ()
-{
-return use_ascii (foo) == use_ebcdic (foo);
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
- ac_cv_c_bigendian=yes
- fi
- if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
- if test "$ac_cv_c_bigendian" = unknown; then
- ac_cv_c_bigendian=no
- else
- # finding both strings is unlikely to happen, but who knows?
- ac_cv_c_bigendian=unknown
- fi
- fi
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$ac_includes_default
-int
-main ()
-{
-
- /* Are we little or big endian? From Harbison&Steele. */
- union
- {
- long int l;
- char c[sizeof (long int)];
- } u;
- u.l = 1;
- return u.c[sizeof (long int) - 1] == 1;
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_run "$LINENO"; then :
- ac_cv_c_bigendian=no
-else
- ac_cv_c_bigendian=yes
-fi
-rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
- conftest.$ac_objext conftest.beam conftest.$ac_ext
-fi
-
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
-$as_echo "$ac_cv_c_bigendian" >&6; }
- case $ac_cv_c_bigendian in #(
- yes)
- $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
-;; #(
- no)
- ;; #(
- universal)
-
-$as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
-
- ;; #(
- *)
- as_fn_error $? "unknown endianness
- presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
- esac
-
-
-host64=false
-target64=false
-bfd_default_target_size=32
-
-# host stuff:
-
-ALL_LINGUAS="da es fi fr hr id ja ro ru rw sr sv tr uk vi zh_CN pt"
-
- MKINSTALLDIRS=
- if test -n "$ac_aux_dir"; then
- case "$ac_aux_dir" in
- /*) MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs" ;;
- *) MKINSTALLDIRS="\$(top_builddir)/$ac_aux_dir/mkinstalldirs" ;;
- esac
- fi
- if test -z "$MKINSTALLDIRS"; then
- MKINSTALLDIRS="\$(top_srcdir)/mkinstalldirs"
- fi
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NLS is requested" >&5
-$as_echo_n "checking whether NLS is requested... " >&6; }
- # Check whether --enable-nls was given.
-if test "${enable_nls+set}" = set; then :
- enableval=$enable_nls; USE_NLS=$enableval
-else
- USE_NLS=yes
-fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_NLS" >&5
-$as_echo "$USE_NLS" >&6; }
-
-
-
-
-
-
-# Prepare PATH_SEPARATOR.
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-
-# Find out how to test for executable files. Don't use a zero-byte file,
-# as systems may use methods other than mode bits to determine executability.
-cat >conf$$.file <<_ASEOF
-#! /bin/sh
-exit 0
-_ASEOF
-chmod +x conf$$.file
-if test -x conf$$.file >/dev/null 2>&1; then
- ac_executable_p="test -x"
-else
- ac_executable_p="test -f"
-fi
-rm -f conf$$.file
-
-# Extract the first word of "msgfmt", so it can be a program name with args.
-set dummy msgfmt; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_MSGFMT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case "$MSGFMT" in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
- ;;
- *)
- ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH; do
- IFS="$ac_save_IFS"
- test -z "$ac_dir" && ac_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
- if $ac_dir/$ac_word --statistics /dev/null >/dev/null 2>&1 &&
- (if $ac_dir/$ac_word --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- ac_cv_path_MSGFMT="$ac_dir/$ac_word$ac_exec_ext"
- break 2
- fi
- fi
- done
- done
- IFS="$ac_save_IFS"
- test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT=":"
- ;;
-esac
-fi
-MSGFMT="$ac_cv_path_MSGFMT"
-if test "$MSGFMT" != ":"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGFMT" >&5
-$as_echo "$MSGFMT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- # Extract the first word of "gmsgfmt", so it can be a program name with args.
-set dummy gmsgfmt; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_GMSGFMT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $GMSGFMT in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
- ;;
- *)
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_path_GMSGFMT="$as_dir/$ac_word$ac_exec_ext"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
- test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT"
- ;;
-esac
-fi
-GMSGFMT=$ac_cv_path_GMSGFMT
-if test -n "$GMSGFMT"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GMSGFMT" >&5
-$as_echo "$GMSGFMT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-
-
-# Prepare PATH_SEPARATOR.
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-
-# Find out how to test for executable files. Don't use a zero-byte file,
-# as systems may use methods other than mode bits to determine executability.
-cat >conf$$.file <<_ASEOF
-#! /bin/sh
-exit 0
-_ASEOF
-chmod +x conf$$.file
-if test -x conf$$.file >/dev/null 2>&1; then
- ac_executable_p="test -x"
-else
- ac_executable_p="test -f"
-fi
-rm -f conf$$.file
-
-# Extract the first word of "xgettext", so it can be a program name with args.
-set dummy xgettext; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_XGETTEXT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case "$XGETTEXT" in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
- ;;
- *)
- ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH; do
- IFS="$ac_save_IFS"
- test -z "$ac_dir" && ac_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
- if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >/dev/null 2>&1 &&
- (if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- ac_cv_path_XGETTEXT="$ac_dir/$ac_word$ac_exec_ext"
- break 2
- fi
- fi
- done
- done
- IFS="$ac_save_IFS"
- test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":"
- ;;
-esac
-fi
-XGETTEXT="$ac_cv_path_XGETTEXT"
-if test "$XGETTEXT" != ":"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XGETTEXT" >&5
-$as_echo "$XGETTEXT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- rm -f messages.po
-
-
-# Prepare PATH_SEPARATOR.
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-
-# Find out how to test for executable files. Don't use a zero-byte file,
-# as systems may use methods other than mode bits to determine executability.
-cat >conf$$.file <<_ASEOF
-#! /bin/sh
-exit 0
-_ASEOF
-chmod +x conf$$.file
-if test -x conf$$.file >/dev/null 2>&1; then
- ac_executable_p="test -x"
-else
- ac_executable_p="test -f"
-fi
-rm -f conf$$.file
-
-# Extract the first word of "msgmerge", so it can be a program name with args.
-set dummy msgmerge; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_MSGMERGE+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case "$MSGMERGE" in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_MSGMERGE="$MSGMERGE" # Let the user override the test with a path.
- ;;
- *)
- ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH; do
- IFS="$ac_save_IFS"
- test -z "$ac_dir" && ac_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
- if $ac_dir/$ac_word --update -q /dev/null /dev/null >/dev/null 2>&1; then
- ac_cv_path_MSGMERGE="$ac_dir/$ac_word$ac_exec_ext"
- break 2
- fi
- fi
- done
- done
- IFS="$ac_save_IFS"
- test -z "$ac_cv_path_MSGMERGE" && ac_cv_path_MSGMERGE=":"
- ;;
-esac
-fi
-MSGMERGE="$ac_cv_path_MSGMERGE"
-if test "$MSGMERGE" != ":"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGMERGE" >&5
-$as_echo "$MSGMERGE" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- if test "$GMSGFMT" != ":"; then
- if $GMSGFMT --statistics /dev/null >/dev/null 2>&1 &&
- (if $GMSGFMT --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- : ;
- else
- GMSGFMT=`echo "$GMSGFMT" | sed -e 's,^.*/,,'`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: found $GMSGFMT program is not GNU msgfmt; ignore it" >&5
-$as_echo "found $GMSGFMT program is not GNU msgfmt; ignore it" >&6; }
- GMSGFMT=":"
- fi
- fi
-
- if test "$XGETTEXT" != ":"; then
- if $XGETTEXT --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >/dev/null 2>&1 &&
- (if $XGETTEXT --omit-header --copyright-holder= --msgid-bugs-address= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- : ;
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: found xgettext program is not GNU xgettext; ignore it" >&5
-$as_echo "found xgettext program is not GNU xgettext; ignore it" >&6; }
- XGETTEXT=":"
- fi
- rm -f messages.po
- fi
-
- ac_config_commands="$ac_config_commands default-1"
-
-
-
- if test "X$prefix" = "XNONE"; then
- acl_final_prefix="$ac_default_prefix"
- else
- acl_final_prefix="$prefix"
- fi
- if test "X$exec_prefix" = "XNONE"; then
- acl_final_exec_prefix='${prefix}'
- else
- acl_final_exec_prefix="$exec_prefix"
- fi
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- eval acl_final_exec_prefix=\"$acl_final_exec_prefix\"
- prefix="$acl_save_prefix"
-
-
-# Check whether --with-gnu-ld was given.
-if test "${with_gnu_ld+set}" = set; then :
- withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
-else
- with_gnu_ld=no
-fi
-
-# Prepare PATH_SEPARATOR.
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-ac_prog=ld
-if test "$GCC" = yes; then
- # Check if gcc -print-prog-name=ld gives a path.
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by GCC" >&5
-$as_echo_n "checking for ld used by GCC... " >&6; }
- case $host in
- *-*-mingw*)
- # gcc leaves a trailing carriage return which upsets mingw
- ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
- *)
- ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
- esac
- case $ac_prog in
- # Accept absolute paths.
- [\\/]* | [A-Za-z]:[\\/]*)
- re_direlt='/[^/][^/]*/\.\./'
- # Canonicalize the path of ld
- ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
- while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
- ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
- done
- test -z "$LD" && LD="$ac_prog"
- ;;
- "")
- # If it fails, then pretend we aren't using GCC.
- ac_prog=ld
- ;;
- *)
- # If it is relative, then search for the first ld in PATH.
- with_gnu_ld=unknown
- ;;
- esac
-elif test "$with_gnu_ld" = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
-$as_echo_n "checking for GNU ld... " >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
-$as_echo_n "checking for non-GNU ld... " >&6; }
-fi
-if ${acl_cv_path_LD+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -z "$LD"; then
- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
- for ac_dir in $PATH; do
- test -z "$ac_dir" && ac_dir=.
- if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
- acl_cv_path_LD="$ac_dir/$ac_prog"
- # Check to see if the program is GNU ld. I'd rather use --version,
- # but apparently some GNU ld's only accept -v.
- # Break only if it was the GNU/non-GNU ld that we prefer.
- if "$acl_cv_path_LD" -v 2>&1 < /dev/null | $EGREP '(GNU|with BFD)' > /dev/null; then
- test "$with_gnu_ld" != no && break
- else
- test "$with_gnu_ld" != yes && break
- fi
- fi
- done
- IFS="$ac_save_ifs"
-else
- acl_cv_path_LD="$LD" # Let the user override the test with a path.
-fi
-fi
-
-LD="$acl_cv_path_LD"
-if test -n "$LD"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
-$as_echo "$LD" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
-$as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
-if ${acl_cv_prog_gnu_ld+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- # I'd rather use --version here, but apparently some GNU ld's only accept -v.
-if $LD -v 2>&1 </dev/null | $EGREP '(GNU|with BFD)' 1>&5; then
- acl_cv_prog_gnu_ld=yes
-else
- acl_cv_prog_gnu_ld=no
-fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $acl_cv_prog_gnu_ld" >&5
-$as_echo "$acl_cv_prog_gnu_ld" >&6; }
-with_gnu_ld=$acl_cv_prog_gnu_ld
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shared library run path origin" >&5
-$as_echo_n "checking for shared library run path origin... " >&6; }
-if ${acl_cv_rpath+:} false; then :
- $as_echo_n "(cached) " >&6
-else
-
- CC="$CC" GCC="$GCC" LDFLAGS="$LDFLAGS" LD="$LD" with_gnu_ld="$with_gnu_ld" \
- ${CONFIG_SHELL-/bin/sh} "$ac_aux_dir/config.rpath" "$host" > conftest.sh
- . ./conftest.sh
- rm -f ./conftest.sh
- acl_cv_rpath=done
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $acl_cv_rpath" >&5
-$as_echo "$acl_cv_rpath" >&6; }
- wl="$acl_cv_wl"
- libext="$acl_cv_libext"
- shlibext="$acl_cv_shlibext"
- hardcode_libdir_flag_spec="$acl_cv_hardcode_libdir_flag_spec"
- hardcode_libdir_separator="$acl_cv_hardcode_libdir_separator"
- hardcode_direct="$acl_cv_hardcode_direct"
- hardcode_minus_L="$acl_cv_hardcode_minus_L"
- # Check whether --enable-rpath was given.
-if test "${enable_rpath+set}" = set; then :
- enableval=$enable_rpath; :
-else
- enable_rpath=yes
-fi
-
-
-
-
-
-
-
-
- use_additional=yes
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
-
- eval additional_includedir=\"$includedir\"
- eval additional_libdir=\"$libdir\"
-
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
-
-# Check whether --with-libiconv-prefix was given.
-if test "${with_libiconv_prefix+set}" = set; then :
- withval=$with_libiconv_prefix;
- if test "X$withval" = "Xno"; then
- use_additional=no
- else
- if test "X$withval" = "X"; then
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
-
- eval additional_includedir=\"$includedir\"
- eval additional_libdir=\"$libdir\"
-
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- else
- additional_includedir="$withval/include"
- additional_libdir="$withval/lib"
- fi
- fi
-
-fi
-
-
-# Check whether --with-libiconv-type was given.
-if test "${with_libiconv_type+set}" = set; then :
- withval=$with_libiconv_type; with_libiconv_type=$withval
-else
- with_libiconv_type=auto
-fi
-
- lib_type=`eval echo \$with_libiconv_type`
-
- LIBICONV=
- LTLIBICONV=
- INCICONV=
- rpathdirs=
- ltrpathdirs=
- names_already_handled=
- names_next_round='iconv '
- while test -n "$names_next_round"; do
- names_this_round="$names_next_round"
- names_next_round=
- for name in $names_this_round; do
- already_handled=
- for n in $names_already_handled; do
- if test "$n" = "$name"; then
- already_handled=yes
- break
- fi
- done
- if test -z "$already_handled"; then
- names_already_handled="$names_already_handled $name"
- uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
- eval value=\"\$HAVE_LIB$uppername\"
- if test -n "$value"; then
- if test "$value" = yes; then
- eval value=\"\$LIB$uppername\"
- test -z "$value" || LIBICONV="${LIBICONV}${LIBICONV:+ }$value"
- eval value=\"\$LTLIB$uppername\"
- test -z "$value" || LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$value"
- else
- :
- fi
- else
- found_dir=
- found_la=
- found_so=
- found_a=
- if test $use_additional = yes; then
- if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext" && test x$lib_type != xstatic; then
- found_dir="$additional_libdir"
- found_so="$additional_libdir/lib$name.$shlibext"
- if test -f "$additional_libdir/lib$name.la"; then
- found_la="$additional_libdir/lib$name.la"
- fi
- elif test x$lib_type != xshared; then
- if test -f "$additional_libdir/lib$name.$libext"; then
- found_dir="$additional_libdir"
- found_a="$additional_libdir/lib$name.$libext"
- if test -f "$additional_libdir/lib$name.la"; then
- found_la="$additional_libdir/lib$name.la"
- fi
- fi
- fi
- fi
- if test "X$found_dir" = "X"; then
- for x in $LDFLAGS $LTLIBICONV; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- case "$x" in
- -L*)
- dir=`echo "X$x" | sed -e 's/^X-L//'`
- if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext" && test x$lib_type != xstatic; then
- found_dir="$dir"
- found_so="$dir/lib$name.$shlibext"
- if test -f "$dir/lib$name.la"; then
- found_la="$dir/lib$name.la"
- fi
- elif test x$lib_type != xshared; then
- if test -f "$dir/lib$name.$libext"; then
- found_dir="$dir"
- found_a="$dir/lib$name.$libext"
- if test -f "$dir/lib$name.la"; then
- found_la="$dir/lib$name.la"
- fi
- fi
- fi
- ;;
- esac
- if test "X$found_dir" != "X"; then
- break
- fi
- done
- fi
- if test "X$found_dir" != "X"; then
- LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$found_dir -l$name"
- if test "X$found_so" != "X"; then
- if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
- else
- haveit=
- for x in $ltrpathdirs; do
- if test "X$x" = "X$found_dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- ltrpathdirs="$ltrpathdirs $found_dir"
- fi
- if test "$hardcode_direct" = yes; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
- else
- if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
- haveit=
- for x in $rpathdirs; do
- if test "X$x" = "X$found_dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- rpathdirs="$rpathdirs $found_dir"
- fi
- else
- haveit=
- for x in $LDFLAGS $LIBICONV; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-L$found_dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir"
- fi
- if test "$hardcode_minus_L" != no; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
- else
- LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name"
- fi
- fi
- fi
- fi
- else
- if test "X$found_a" != "X"; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }$found_a"
- else
- LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir -l$name"
- fi
- fi
- additional_includedir=
- case "$found_dir" in
- */lib | */lib/)
- basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
- additional_includedir="$basedir/include"
- ;;
- esac
- if test "X$additional_includedir" != "X"; then
- if test "X$additional_includedir" != "X/usr/include"; then
- haveit=
- if test "X$additional_includedir" = "X/usr/local/include"; then
- if test -n "$GCC"; then
- case $host_os in
- linux*) haveit=yes;;
- esac
- fi
- fi
- if test -z "$haveit"; then
- for x in $CPPFLAGS $INCICONV; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-I$additional_includedir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- if test -d "$additional_includedir"; then
- INCICONV="${INCICONV}${INCICONV:+ }-I$additional_includedir"
- fi
- fi
- fi
- fi
- fi
- if test -n "$found_la"; then
- save_libdir="$libdir"
- case "$found_la" in
- */* | *\\*) . "$found_la" ;;
- *) . "./$found_la" ;;
- esac
- libdir="$save_libdir"
- for dep in $dependency_libs; do
- case "$dep" in
- -L*)
- additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
- if test "X$additional_libdir" != "X/usr/lib"; then
- haveit=
- if test "X$additional_libdir" = "X/usr/local/lib"; then
- if test -n "$GCC"; then
- case $host_os in
- linux*) haveit=yes;;
- esac
- fi
- fi
- if test -z "$haveit"; then
- haveit=
- for x in $LDFLAGS $LIBICONV; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-L$additional_libdir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- if test -d "$additional_libdir"; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }-L$additional_libdir"
- fi
- fi
- haveit=
- for x in $LDFLAGS $LTLIBICONV; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-L$additional_libdir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- if test -d "$additional_libdir"; then
- LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$additional_libdir"
- fi
- fi
- fi
- fi
- ;;
- -R*)
- dir=`echo "X$dep" | sed -e 's/^X-R//'`
- if test "$enable_rpath" != no; then
- haveit=
- for x in $rpathdirs; do
- if test "X$x" = "X$dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- rpathdirs="$rpathdirs $dir"
- fi
- haveit=
- for x in $ltrpathdirs; do
- if test "X$x" = "X$dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- ltrpathdirs="$ltrpathdirs $dir"
- fi
- fi
- ;;
- -l*)
- names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
- ;;
- *.la)
- names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
- ;;
- *)
- LIBICONV="${LIBICONV}${LIBICONV:+ }$dep"
- LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$dep"
- ;;
- esac
- done
- fi
- else
- if test "x$lib_type" = "xauto" || test "x$lib_type" = "xshared"; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name"
- LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-l$name"
- else
- LIBICONV="${LIBICONV}${LIBICONV:+ }-l:lib$name.$libext"
- LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-l:lib$name.$libext"
- fi
- fi
- fi
- fi
- done
- done
- if test "X$rpathdirs" != "X"; then
- if test -n "$hardcode_libdir_separator"; then
- alldirs=
- for found_dir in $rpathdirs; do
- alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
- done
- acl_save_libdir="$libdir"
- libdir="$alldirs"
- eval flag=\"$hardcode_libdir_flag_spec\"
- libdir="$acl_save_libdir"
- LIBICONV="${LIBICONV}${LIBICONV:+ }$flag"
- else
- for found_dir in $rpathdirs; do
- acl_save_libdir="$libdir"
- libdir="$found_dir"
- eval flag=\"$hardcode_libdir_flag_spec\"
- libdir="$acl_save_libdir"
- LIBICONV="${LIBICONV}${LIBICONV:+ }$flag"
- done
- fi
- fi
- if test "X$ltrpathdirs" != "X"; then
- for found_dir in $ltrpathdirs; do
- LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-R$found_dir"
- done
- fi
-
-
-
-
-
-if test -f ../gettext/uninstalled-config.sh; then
- relative_builddir='$(top_builddir)/../gettext'
- . ../gettext/uninstalled-config.sh
-else
- # The sister gettext directory doesn't exist and won't collect information on
- # using gettext for us. Call a bundled AM_GNU_GETTEXT.
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CFPreferencesCopyAppValue" >&5
-$as_echo_n "checking for CFPreferencesCopyAppValue... " >&6; }
-if ${gt_cv_func_CFPreferencesCopyAppValue+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- gt_save_LIBS="$LIBS"
- LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <CoreFoundation/CFPreferences.h>
-int
-main ()
-{
-CFPreferencesCopyAppValue(NULL, NULL)
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- gt_cv_func_CFPreferencesCopyAppValue=yes
-else
- gt_cv_func_CFPreferencesCopyAppValue=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LIBS="$gt_save_LIBS"
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_CFPreferencesCopyAppValue" >&5
-$as_echo "$gt_cv_func_CFPreferencesCopyAppValue" >&6; }
- if test $gt_cv_func_CFPreferencesCopyAppValue = yes; then
-
-$as_echo "#define HAVE_CFPREFERENCESCOPYAPPVALUE 1" >>confdefs.h
-
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CFLocaleCopyPreferredLanguages" >&5
-$as_echo_n "checking for CFLocaleCopyPreferredLanguages... " >&6; }
-if ${gt_cv_func_CFLocaleCopyPreferredLanguages+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- gt_save_LIBS="$LIBS"
- LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <CoreFoundation/CFLocale.h>
-int
-main ()
-{
-CFLocaleCopyPreferredLanguages();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- gt_cv_func_CFLocaleCopyPreferredLanguages=yes
-else
- gt_cv_func_CFLocaleCopyPreferredLanguages=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LIBS="$gt_save_LIBS"
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_CFLocaleCopyPreferredLanguages" >&5
-$as_echo "$gt_cv_func_CFLocaleCopyPreferredLanguages" >&6; }
- if test $gt_cv_func_CFLocaleCopyPreferredLanguages = yes; then
-
-$as_echo "#define HAVE_CFLOCALECOPYPREFERREDLANGUAGES 1" >>confdefs.h
-
- fi
- INTL_MACOSX_LIBS=
- if test $gt_cv_func_CFPreferencesCopyAppValue = yes \
- || test $gt_cv_func_CFLocaleCopyPreferredLanguages = yes; then
- INTL_MACOSX_LIBS="-Wl,-framework -Wl,CoreFoundation -Wl,-framework -Wl,CoreServices"
- fi
-
-
-
-
-
-
- LIBINTL=
- LTLIBINTL=
- POSUB=
-
- case " $gt_needs " in
- *" need-formatstring-macros "*) gt_api_version=3 ;;
- *" need-ngettext "*) gt_api_version=2 ;;
- *) gt_api_version=1 ;;
- esac
- gt_func_gnugettext_libc="gt_cv_func_gnugettext${gt_api_version}_libc"
- gt_func_gnugettext_libintl="gt_cv_func_gnugettext${gt_api_version}_libintl"
-
- if test "$USE_NLS" = "yes"; then
- gt_use_preinstalled_gnugettext=no
-
-
- if test $gt_api_version -ge 3; then
- gt_revision_test_code='
-#ifndef __GNU_GETTEXT_SUPPORTED_REVISION
-#define __GNU_GETTEXT_SUPPORTED_REVISION(major) ((major) == 0 ? 0 : -1)
-#endif
-typedef int array [2 * (__GNU_GETTEXT_SUPPORTED_REVISION(0) >= 1) - 1];
-'
- else
- gt_revision_test_code=
- fi
- if test $gt_api_version -ge 2; then
- gt_expression_test_code=' + * ngettext ("", "", 0)'
- else
- gt_expression_test_code=
- fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU gettext in libc" >&5
-$as_echo_n "checking for GNU gettext in libc... " >&6; }
-if eval \${$gt_func_gnugettext_libc+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <libintl.h>
-#ifndef __GNU_GETTEXT_SUPPORTED_REVISION
-extern int _nl_msg_cat_cntr;
-extern int *_nl_domain_bindings;
-#define __GNU_GETTEXT_SYMBOL_EXPRESSION (_nl_msg_cat_cntr + *_nl_domain_bindings)
-#else
-#define __GNU_GETTEXT_SYMBOL_EXPRESSION 0
-#endif
-$gt_revision_test_code
-
-int
-main ()
-{
-
-bindtextdomain ("", "");
-return * gettext ("")$gt_expression_test_code + __GNU_GETTEXT_SYMBOL_EXPRESSION
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- eval "$gt_func_gnugettext_libc=yes"
-else
- eval "$gt_func_gnugettext_libc=no"
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-fi
-eval ac_res=\$$gt_func_gnugettext_libc
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
-
- if { eval "gt_val=\$$gt_func_gnugettext_libc"; test "$gt_val" != "yes"; }; then
-
-
-
-
-
- am_save_CPPFLAGS="$CPPFLAGS"
-
- for element in $INCICONV; do
- haveit=
- for x in $CPPFLAGS; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X$element"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
- fi
- done
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for iconv" >&5
-$as_echo_n "checking for iconv... " >&6; }
-if ${am_cv_func_iconv+:} false; then :
- $as_echo_n "(cached) " >&6
-else
-
- am_cv_func_iconv="no, consider installing GNU libiconv"
- am_cv_lib_iconv=no
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <stdlib.h>
-#include <iconv.h>
-
-int
-main ()
-{
-iconv_t cd = iconv_open("","");
- iconv(cd,NULL,NULL,NULL,NULL);
- iconv_close(cd);
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- am_cv_func_iconv=yes
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- if test "$am_cv_func_iconv" != yes; then
- am_save_LIBS="$LIBS"
- LIBS="$LIBS $LIBICONV"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <stdlib.h>
-#include <iconv.h>
-
-int
-main ()
-{
-iconv_t cd = iconv_open("","");
- iconv(cd,NULL,NULL,NULL,NULL);
- iconv_close(cd);
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- am_cv_lib_iconv=yes
- am_cv_func_iconv=yes
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LIBS="$am_save_LIBS"
- fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv" >&5
-$as_echo "$am_cv_func_iconv" >&6; }
- if test "$am_cv_func_iconv" = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working iconv" >&5
-$as_echo_n "checking for working iconv... " >&6; }
-if ${am_cv_func_iconv_works+:} false; then :
- $as_echo_n "(cached) " >&6
-else
-
- am_save_LIBS="$LIBS"
- if test $am_cv_lib_iconv = yes; then
- LIBS="$LIBS $LIBICONV"
- fi
- am_cv_func_iconv_works=no
- for ac_iconv_const in '' 'const'; do
- if test "$cross_compiling" = yes; then :
- case "$host_os" in
- aix* | hpux*) am_cv_func_iconv_works="guessing no" ;;
- *) am_cv_func_iconv_works="guessing yes" ;;
- esac
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <iconv.h>
-#include <string.h>
-
-#ifndef ICONV_CONST
-# define ICONV_CONST $ac_iconv_const
-#endif
-
-int
-main ()
-{
-int result = 0;
- /* Test against AIX 5.1...7.2 bug: Failures are not distinguishable from
- successful returns. This is even documented in
- <https://www.ibm.com/support/knowledgecenter/ssw_aix_72/i_bostechref/iconv.html> */
- {
- iconv_t cd_utf8_to_88591 = iconv_open ("ISO8859-1", "UTF-8");
- if (cd_utf8_to_88591 != (iconv_t)(-1))
- {
- static ICONV_CONST char input[] = "\342\202\254"; /* EURO SIGN */
- char buf[10];
- ICONV_CONST char *inptr = input;
- size_t inbytesleft = strlen (input);
- char *outptr = buf;
- size_t outbytesleft = sizeof (buf);
- size_t res = iconv (cd_utf8_to_88591,
- &inptr, &inbytesleft,
- &outptr, &outbytesleft);
- if (res == 0)
- result |= 1;
- iconv_close (cd_utf8_to_88591);
- }
- }
- /* Test against Solaris 10 bug: Failures are not distinguishable from
- successful returns. */
- {
- iconv_t cd_ascii_to_88591 = iconv_open ("ISO8859-1", "646");
- if (cd_ascii_to_88591 != (iconv_t)(-1))
- {
- static ICONV_CONST char input[] = "\263";
- char buf[10];
- ICONV_CONST char *inptr = input;
- size_t inbytesleft = strlen (input);
- char *outptr = buf;
- size_t outbytesleft = sizeof (buf);
- size_t res = iconv (cd_ascii_to_88591,
- &inptr, &inbytesleft,
- &outptr, &outbytesleft);
- if (res == 0)
- result |= 2;
- iconv_close (cd_ascii_to_88591);
- }
- }
- /* Test against AIX 6.1..7.1 bug: Buffer overrun. */
- {
- iconv_t cd_88591_to_utf8 = iconv_open ("UTF-8", "ISO-8859-1");
- if (cd_88591_to_utf8 != (iconv_t)(-1))
- {
- static ICONV_CONST char input[] = "\304";
- static char buf[2] = { (char)0xDE, (char)0xAD };
- ICONV_CONST char *inptr = input;
- size_t inbytesleft = 1;
- char *outptr = buf;
- size_t outbytesleft = 1;
- size_t res = iconv (cd_88591_to_utf8,
- &inptr, &inbytesleft,
- &outptr, &outbytesleft);
- if (res != (size_t)(-1) || outptr - buf > 1 || buf[1] != (char)0xAD)
- result |= 4;
- iconv_close (cd_88591_to_utf8);
- }
- }
-#if 0 /* This bug could be worked around by the caller. */
- /* Test against HP-UX 11.11 bug: Positive return value instead of 0. */
- {
- iconv_t cd_88591_to_utf8 = iconv_open ("utf8", "iso88591");
- if (cd_88591_to_utf8 != (iconv_t)(-1))
- {
- static ICONV_CONST char input[] = "\304rger mit b\366sen B\374bchen ohne Augenma\337";
- char buf[50];
- ICONV_CONST char *inptr = input;
- size_t inbytesleft = strlen (input);
- char *outptr = buf;
- size_t outbytesleft = sizeof (buf);
- size_t res = iconv (cd_88591_to_utf8,
- &inptr, &inbytesleft,
- &outptr, &outbytesleft);
- if ((int)res > 0)
- result |= 8;
- iconv_close (cd_88591_to_utf8);
- }
- }
-#endif
- /* Test against HP-UX 11.11 bug: No converter from EUC-JP to UTF-8 is
- provided. */
- {
- /* Try standardized names. */
- iconv_t cd1 = iconv_open ("UTF-8", "EUC-JP");
- /* Try IRIX, OSF/1 names. */
- iconv_t cd2 = iconv_open ("UTF-8", "eucJP");
- /* Try AIX names. */
- iconv_t cd3 = iconv_open ("UTF-8", "IBM-eucJP");
- /* Try HP-UX names. */
- iconv_t cd4 = iconv_open ("utf8", "eucJP");
- if (cd1 == (iconv_t)(-1) && cd2 == (iconv_t)(-1)
- && cd3 == (iconv_t)(-1) && cd4 == (iconv_t)(-1))
- result |= 16;
- if (cd1 != (iconv_t)(-1))
- iconv_close (cd1);
- if (cd2 != (iconv_t)(-1))
- iconv_close (cd2);
- if (cd3 != (iconv_t)(-1))
- iconv_close (cd3);
- if (cd4 != (iconv_t)(-1))
- iconv_close (cd4);
- }
- return result;
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_run "$LINENO"; then :
- am_cv_func_iconv_works=yes
-fi
-rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
- conftest.$ac_objext conftest.beam conftest.$ac_ext
-fi
-
- test "$am_cv_func_iconv_works" = no || break
- done
- LIBS="$am_save_LIBS"
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv_works" >&5
-$as_echo "$am_cv_func_iconv_works" >&6; }
- case "$am_cv_func_iconv_works" in
- *no) am_func_iconv=no am_cv_lib_iconv=no ;;
- *) am_func_iconv=yes ;;
- esac
- else
- am_func_iconv=no am_cv_lib_iconv=no
- fi
- if test "$am_func_iconv" = yes; then
-
-$as_echo "#define HAVE_ICONV 1" >>confdefs.h
-
- fi
- if test "$am_cv_lib_iconv" = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libiconv" >&5
-$as_echo_n "checking how to link with libiconv... " >&6; }
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBICONV" >&5
-$as_echo "$LIBICONV" >&6; }
- else
- CPPFLAGS="$am_save_CPPFLAGS"
- LIBICONV=
- LTLIBICONV=
- fi
-
-
-
-
-
-
- use_additional=yes
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
-
- eval additional_includedir=\"$includedir\"
- eval additional_libdir=\"$libdir\"
-
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
-
-# Check whether --with-libintl-prefix was given.
-if test "${with_libintl_prefix+set}" = set; then :
- withval=$with_libintl_prefix;
- if test "X$withval" = "Xno"; then
- use_additional=no
- else
- if test "X$withval" = "X"; then
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
-
- eval additional_includedir=\"$includedir\"
- eval additional_libdir=\"$libdir\"
-
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- else
- additional_includedir="$withval/include"
- additional_libdir="$withval/lib"
- fi
- fi
-
-fi
-
-
-# Check whether --with-libintl-type was given.
-if test "${with_libintl_type+set}" = set; then :
- withval=$with_libintl_type; with_libintl_type=$withval
-else
- with_libintl_type=auto
-fi
-
- lib_type=`eval echo \$with_libintl_type`
-
- LIBINTL=
- LTLIBINTL=
- INCINTL=
- rpathdirs=
- ltrpathdirs=
- names_already_handled=
- names_next_round='intl '
- while test -n "$names_next_round"; do
- names_this_round="$names_next_round"
- names_next_round=
- for name in $names_this_round; do
- already_handled=
- for n in $names_already_handled; do
- if test "$n" = "$name"; then
- already_handled=yes
- break
- fi
- done
- if test -z "$already_handled"; then
- names_already_handled="$names_already_handled $name"
- uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
- eval value=\"\$HAVE_LIB$uppername\"
- if test -n "$value"; then
- if test "$value" = yes; then
- eval value=\"\$LIB$uppername\"
- test -z "$value" || LIBINTL="${LIBINTL}${LIBINTL:+ }$value"
- eval value=\"\$LTLIB$uppername\"
- test -z "$value" || LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }$value"
- else
- :
- fi
- else
- found_dir=
- found_la=
- found_so=
- found_a=
- if test $use_additional = yes; then
- if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext" && test x$lib_type != xstatic; then
- found_dir="$additional_libdir"
- found_so="$additional_libdir/lib$name.$shlibext"
- if test -f "$additional_libdir/lib$name.la"; then
- found_la="$additional_libdir/lib$name.la"
- fi
- elif test x$lib_type != xshared; then
- if test -f "$additional_libdir/lib$name.$libext"; then
- found_dir="$additional_libdir"
- found_a="$additional_libdir/lib$name.$libext"
- if test -f "$additional_libdir/lib$name.la"; then
- found_la="$additional_libdir/lib$name.la"
- fi
- fi
- fi
- fi
- if test "X$found_dir" = "X"; then
- for x in $LDFLAGS $LTLIBINTL; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- case "$x" in
- -L*)
- dir=`echo "X$x" | sed -e 's/^X-L//'`
- if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext" && test x$lib_type != xstatic; then
- found_dir="$dir"
- found_so="$dir/lib$name.$shlibext"
- if test -f "$dir/lib$name.la"; then
- found_la="$dir/lib$name.la"
- fi
- elif test x$lib_type != xshared; then
- if test -f "$dir/lib$name.$libext"; then
- found_dir="$dir"
- found_a="$dir/lib$name.$libext"
- if test -f "$dir/lib$name.la"; then
- found_la="$dir/lib$name.la"
- fi
- fi
- fi
- ;;
- esac
- if test "X$found_dir" != "X"; then
- break
- fi
- done
- fi
- if test "X$found_dir" != "X"; then
- LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-L$found_dir -l$name"
- if test "X$found_so" != "X"; then
- if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
- else
- haveit=
- for x in $ltrpathdirs; do
- if test "X$x" = "X$found_dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- ltrpathdirs="$ltrpathdirs $found_dir"
- fi
- if test "$hardcode_direct" = yes; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
- else
- if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
- haveit=
- for x in $rpathdirs; do
- if test "X$x" = "X$found_dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- rpathdirs="$rpathdirs $found_dir"
- fi
- else
- haveit=
- for x in $LDFLAGS $LIBINTL; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-L$found_dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }-L$found_dir"
- fi
- if test "$hardcode_minus_L" != no; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
- else
- LIBINTL="${LIBINTL}${LIBINTL:+ }-l$name"
- fi
- fi
- fi
- fi
- else
- if test "X$found_a" != "X"; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }$found_a"
- else
- LIBINTL="${LIBINTL}${LIBINTL:+ }-L$found_dir -l$name"
- fi
- fi
- additional_includedir=
- case "$found_dir" in
- */lib | */lib/)
- basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
- additional_includedir="$basedir/include"
- ;;
- esac
- if test "X$additional_includedir" != "X"; then
- if test "X$additional_includedir" != "X/usr/include"; then
- haveit=
- if test "X$additional_includedir" = "X/usr/local/include"; then
- if test -n "$GCC"; then
- case $host_os in
- linux*) haveit=yes;;
- esac
- fi
- fi
- if test -z "$haveit"; then
- for x in $CPPFLAGS $INCINTL; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-I$additional_includedir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- if test -d "$additional_includedir"; then
- INCINTL="${INCINTL}${INCINTL:+ }-I$additional_includedir"
- fi
- fi
- fi
- fi
- fi
- if test -n "$found_la"; then
- save_libdir="$libdir"
- case "$found_la" in
- */* | *\\*) . "$found_la" ;;
- *) . "./$found_la" ;;
- esac
- libdir="$save_libdir"
- for dep in $dependency_libs; do
- case "$dep" in
- -L*)
- additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
- if test "X$additional_libdir" != "X/usr/lib"; then
- haveit=
- if test "X$additional_libdir" = "X/usr/local/lib"; then
- if test -n "$GCC"; then
- case $host_os in
- linux*) haveit=yes;;
- esac
- fi
- fi
- if test -z "$haveit"; then
- haveit=
- for x in $LDFLAGS $LIBINTL; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-L$additional_libdir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- if test -d "$additional_libdir"; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }-L$additional_libdir"
- fi
- fi
- haveit=
- for x in $LDFLAGS $LTLIBINTL; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-L$additional_libdir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- if test -d "$additional_libdir"; then
- LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-L$additional_libdir"
- fi
- fi
- fi
- fi
- ;;
- -R*)
- dir=`echo "X$dep" | sed -e 's/^X-R//'`
- if test "$enable_rpath" != no; then
- haveit=
- for x in $rpathdirs; do
- if test "X$x" = "X$dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- rpathdirs="$rpathdirs $dir"
- fi
- haveit=
- for x in $ltrpathdirs; do
- if test "X$x" = "X$dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- ltrpathdirs="$ltrpathdirs $dir"
- fi
- fi
- ;;
- -l*)
- names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
- ;;
- *.la)
- names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
- ;;
- *)
- LIBINTL="${LIBINTL}${LIBINTL:+ }$dep"
- LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }$dep"
- ;;
- esac
- done
- fi
- else
- if test "x$lib_type" = "xauto" || test "x$lib_type" = "xshared"; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }-l$name"
- LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-l$name"
- else
- LIBINTL="${LIBINTL}${LIBINTL:+ }-l:lib$name.$libext"
- LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-l:lib$name.$libext"
- fi
- fi
- fi
- fi
- done
- done
- if test "X$rpathdirs" != "X"; then
- if test -n "$hardcode_libdir_separator"; then
- alldirs=
- for found_dir in $rpathdirs; do
- alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
- done
- acl_save_libdir="$libdir"
- libdir="$alldirs"
- eval flag=\"$hardcode_libdir_flag_spec\"
- libdir="$acl_save_libdir"
- LIBINTL="${LIBINTL}${LIBINTL:+ }$flag"
- else
- for found_dir in $rpathdirs; do
- acl_save_libdir="$libdir"
- libdir="$found_dir"
- eval flag=\"$hardcode_libdir_flag_spec\"
- libdir="$acl_save_libdir"
- LIBINTL="${LIBINTL}${LIBINTL:+ }$flag"
- done
- fi
- fi
- if test "X$ltrpathdirs" != "X"; then
- for found_dir in $ltrpathdirs; do
- LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-R$found_dir"
- done
- fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU gettext in libintl" >&5
-$as_echo_n "checking for GNU gettext in libintl... " >&6; }
-if eval \${$gt_func_gnugettext_libintl+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- gt_save_CPPFLAGS="$CPPFLAGS"
- CPPFLAGS="$CPPFLAGS $INCINTL"
- gt_save_LIBS="$LIBS"
- LIBS="$LIBS $LIBINTL"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <libintl.h>
-#ifndef __GNU_GETTEXT_SUPPORTED_REVISION
-extern int _nl_msg_cat_cntr;
-extern
-#ifdef __cplusplus
-"C"
-#endif
-const char *_nl_expand_alias (const char *);
-#define __GNU_GETTEXT_SYMBOL_EXPRESSION (_nl_msg_cat_cntr + *_nl_expand_alias (""))
-#else
-#define __GNU_GETTEXT_SYMBOL_EXPRESSION 0
-#endif
-$gt_revision_test_code
-
-int
-main ()
-{
-
-bindtextdomain ("", "");
-return * gettext ("")$gt_expression_test_code + __GNU_GETTEXT_SYMBOL_EXPRESSION
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- eval "$gt_func_gnugettext_libintl=yes"
-else
- eval "$gt_func_gnugettext_libintl=no"
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" != yes; } && test -n "$LIBICONV"; then
- LIBS="$LIBS $LIBICONV"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <libintl.h>
-#ifndef __GNU_GETTEXT_SUPPORTED_REVISION
-extern int _nl_msg_cat_cntr;
-extern
-#ifdef __cplusplus
-"C"
-#endif
-const char *_nl_expand_alias (const char *);
-#define __GNU_GETTEXT_SYMBOL_EXPRESSION (_nl_msg_cat_cntr + *_nl_expand_alias (""))
-#else
-#define __GNU_GETTEXT_SYMBOL_EXPRESSION 0
-#endif
-$gt_revision_test_code
-
-int
-main ()
-{
-
-bindtextdomain ("", "");
-return * gettext ("")$gt_expression_test_code + __GNU_GETTEXT_SYMBOL_EXPRESSION
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- LIBINTL="$LIBINTL $LIBICONV"
- LTLIBINTL="$LTLIBINTL $LTLIBICONV"
- eval "$gt_func_gnugettext_libintl=yes"
-
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- fi
- CPPFLAGS="$gt_save_CPPFLAGS"
- LIBS="$gt_save_LIBS"
-fi
-eval ac_res=\$$gt_func_gnugettext_libintl
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
- fi
-
- if { eval "gt_val=\$$gt_func_gnugettext_libc"; test "$gt_val" = "yes"; } \
- || { { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; } \
- && test "$PACKAGE" != gettext-runtime \
- && test "$PACKAGE" != gettext-tools; }; then
- gt_use_preinstalled_gnugettext=yes
- else
- LIBINTL=
- LTLIBINTL=
- INCINTL=
- fi
-
-
-
- if test -n "$INTL_MACOSX_LIBS"; then
- if test "$gt_use_preinstalled_gnugettext" = "yes" \
- || test "$nls_cv_use_gnu_gettext" = "yes"; then
- LIBINTL="$LIBINTL $INTL_MACOSX_LIBS"
- LTLIBINTL="$LTLIBINTL $INTL_MACOSX_LIBS"
- fi
- fi
-
- if test "$gt_use_preinstalled_gnugettext" = "yes" \
- || test "$nls_cv_use_gnu_gettext" = "yes"; then
-
-$as_echo "#define ENABLE_NLS 1" >>confdefs.h
-
- else
- USE_NLS=no
- fi
- fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use NLS" >&5
-$as_echo_n "checking whether to use NLS... " >&6; }
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_NLS" >&5
-$as_echo "$USE_NLS" >&6; }
- if test "$USE_NLS" = "yes"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking where the gettext function comes from" >&5
-$as_echo_n "checking where the gettext function comes from... " >&6; }
- if test "$gt_use_preinstalled_gnugettext" = "yes"; then
- if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; }; then
- gt_source="external libintl"
- else
- gt_source="libc"
- fi
- else
- gt_source="included intl directory"
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_source" >&5
-$as_echo "$gt_source" >&6; }
- fi
-
- if test "$USE_NLS" = "yes"; then
-
- if test "$gt_use_preinstalled_gnugettext" = "yes"; then
- if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; }; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libintl" >&5
-$as_echo_n "checking how to link with libintl... " >&6; }
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBINTL" >&5
-$as_echo "$LIBINTL" >&6; }
-
- for element in $INCINTL; do
- haveit=
- for x in $CPPFLAGS; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X$element"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
- fi
- done
-
- fi
-
-
-$as_echo "#define HAVE_GETTEXT 1" >>confdefs.h
-
-
-$as_echo "#define HAVE_DCGETTEXT 1" >>confdefs.h
-
- fi
-
- POSUB=po
- fi
-
-
-
- INTLLIBS="$LIBINTL"
-
-
-
-
-
-
-fi
-
-
-
-
-
-
-
-
-
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NLS is requested" >&5
-$as_echo_n "checking whether NLS is requested... " >&6; }
-if test x"$USE_NLS" != xyes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-
-$as_echo "#define ENABLE_NLS 1" >>confdefs.h
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for catalogs to be installed" >&5
-$as_echo_n "checking for catalogs to be installed... " >&6; }
- # Look for .po and .gmo files in the source directory.
- CATALOGS=
- XLINGUAS=
- for cat in $srcdir/po/*.gmo $srcdir/po/*.po; do
- # If there aren't any .gmo files the shell will give us the
- # literal string "../path/to/srcdir/po/*.gmo" which has to be
- # weeded out.
- case "$cat" in *\**)
- continue;;
- esac
- # The quadruple backslash is collapsed to a double backslash
- # by the backticks, then collapsed again by the double quotes,
- # leaving us with one backslash in the sed expression (right
- # before the dot that mustn't act as a wildcard).
- cat=`echo $cat | sed -e "s!$srcdir/po/!!" -e "s!\\\\.po!.gmo!"`
- lang=`echo $cat | sed -e "s!\\\\.gmo!!"`
- # The user is allowed to set LINGUAS to a list of languages to
- # install catalogs for. If it's empty that means "all of them."
- if test "x$LINGUAS" = x; then
- CATALOGS="$CATALOGS $cat"
- XLINGUAS="$XLINGUAS $lang"
- else
- case "$LINGUAS" in *$lang*)
- CATALOGS="$CATALOGS $cat"
- XLINGUAS="$XLINGUAS $lang"
- ;;
- esac
- fi
- done
- LINGUAS="$XLINGUAS"
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LINGUAS" >&5
-$as_echo "$LINGUAS" >&6; }
-
-
- DATADIRNAME=share
-
- INSTOBJEXT=.mo
-
- GENCAT=gencat
-
- CATOBJEXT=.gmo
-
-fi
-
-
-
-
-# Prepare PATH_SEPARATOR.
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-
-# Find out how to test for executable files. Don't use a zero-byte file,
-# as systems may use methods other than mode bits to determine executability.
-cat >conf$$.file <<_ASEOF
-#! /bin/sh
-exit 0
-_ASEOF
-chmod +x conf$$.file
-if test -x conf$$.file >/dev/null 2>&1; then
- ac_executable_p="test -x"
-else
- ac_executable_p="test -f"
-fi
-rm -f conf$$.file
-
-# Extract the first word of "msgfmt", so it can be a program name with args.
-set dummy msgfmt; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_MSGFMT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case "$MSGFMT" in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
- ;;
- *)
- ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH; do
- IFS="$ac_save_IFS"
- test -z "$ac_dir" && ac_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
- if $ac_dir/$ac_word --statistics /dev/null >/dev/null 2>&1 &&
- (if $ac_dir/$ac_word --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- ac_cv_path_MSGFMT="$ac_dir/$ac_word$ac_exec_ext"
- break 2
- fi
- fi
- done
- done
- IFS="$ac_save_IFS"
- test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT=":"
- ;;
-esac
-fi
-MSGFMT="$ac_cv_path_MSGFMT"
-if test "$MSGFMT" != ":"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGFMT" >&5
-$as_echo "$MSGFMT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- # Extract the first word of "gmsgfmt", so it can be a program name with args.
-set dummy gmsgfmt; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_GMSGFMT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $GMSGFMT in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
- ;;
- *)
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_path_GMSGFMT="$as_dir/$ac_word$ac_exec_ext"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
- test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT"
- ;;
-esac
-fi
-GMSGFMT=$ac_cv_path_GMSGFMT
-if test -n "$GMSGFMT"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GMSGFMT" >&5
-$as_echo "$GMSGFMT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-
-
-# Prepare PATH_SEPARATOR.
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-
-# Find out how to test for executable files. Don't use a zero-byte file,
-# as systems may use methods other than mode bits to determine executability.
-cat >conf$$.file <<_ASEOF
-#! /bin/sh
-exit 0
-_ASEOF
-chmod +x conf$$.file
-if test -x conf$$.file >/dev/null 2>&1; then
- ac_executable_p="test -x"
-else
- ac_executable_p="test -f"
-fi
-rm -f conf$$.file
-
-# Extract the first word of "xgettext", so it can be a program name with args.
-set dummy xgettext; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_XGETTEXT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case "$XGETTEXT" in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
- ;;
- *)
- ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH; do
- IFS="$ac_save_IFS"
- test -z "$ac_dir" && ac_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
- if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >/dev/null 2>&1 &&
- (if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- ac_cv_path_XGETTEXT="$ac_dir/$ac_word$ac_exec_ext"
- break 2
- fi
- fi
- done
- done
- IFS="$ac_save_IFS"
- test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":"
- ;;
-esac
-fi
-XGETTEXT="$ac_cv_path_XGETTEXT"
-if test "$XGETTEXT" != ":"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XGETTEXT" >&5
-$as_echo "$XGETTEXT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- rm -f messages.po
-
-
-# Prepare PATH_SEPARATOR.
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-
-# Find out how to test for executable files. Don't use a zero-byte file,
-# as systems may use methods other than mode bits to determine executability.
-cat >conf$$.file <<_ASEOF
-#! /bin/sh
-exit 0
-_ASEOF
-chmod +x conf$$.file
-if test -x conf$$.file >/dev/null 2>&1; then
- ac_executable_p="test -x"
-else
- ac_executable_p="test -f"
-fi
-rm -f conf$$.file
-
-# Extract the first word of "msgmerge", so it can be a program name with args.
-set dummy msgmerge; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_MSGMERGE+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case "$MSGMERGE" in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_MSGMERGE="$MSGMERGE" # Let the user override the test with a path.
- ;;
- *)
- ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH; do
- IFS="$ac_save_IFS"
- test -z "$ac_dir" && ac_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
- if $ac_dir/$ac_word --update -q /dev/null /dev/null >/dev/null 2>&1; then
- ac_cv_path_MSGMERGE="$ac_dir/$ac_word$ac_exec_ext"
- break 2
- fi
- fi
- done
- done
- IFS="$ac_save_IFS"
- test -z "$ac_cv_path_MSGMERGE" && ac_cv_path_MSGMERGE=":"
- ;;
-esac
-fi
-MSGMERGE="$ac_cv_path_MSGMERGE"
-if test "$MSGMERGE" != ":"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGMERGE" >&5
-$as_echo "$MSGMERGE" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- if test "$GMSGFMT" != ":"; then
- if $GMSGFMT --statistics /dev/null >/dev/null 2>&1 &&
- (if $GMSGFMT --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- : ;
- else
- GMSGFMT=`echo "$GMSGFMT" | sed -e 's,^.*/,,'`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: found $GMSGFMT program is not GNU msgfmt; ignore it" >&5
-$as_echo "found $GMSGFMT program is not GNU msgfmt; ignore it" >&6; }
- GMSGFMT=":"
- fi
- fi
-
- if test "$XGETTEXT" != ":"; then
- if $XGETTEXT --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >/dev/null 2>&1 &&
- (if $XGETTEXT --omit-header --copyright-holder= --msgid-bugs-address= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- : ;
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: found xgettext program is not GNU xgettext; ignore it" >&5
-$as_echo "found xgettext program is not GNU xgettext; ignore it" >&6; }
- XGETTEXT=":"
- fi
- rm -f messages.po
- fi
-
- ac_config_commands="$ac_config_commands default-2"
-
-
-
-# Permit host specific settings.
-. ${srcdir}/configure.host
-
-
-
-
-# The cast to long int works around a bug in the HP C Compiler
-# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
-# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
-# This bug is HP SR number 8606223364.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long long" >&5
-$as_echo_n "checking size of long long... " >&6; }
-if ${ac_cv_sizeof_long_long+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long long))" "ac_cv_sizeof_long_long" "$ac_includes_default"; then :
-
-else
- if test "$ac_cv_type_long_long" = yes; then
- { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error 77 "cannot compute sizeof (long long)
-See \`config.log' for more details" "$LINENO" 5; }
- else
- ac_cv_sizeof_long_long=0
- fi
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_long" >&5
-$as_echo "$ac_cv_sizeof_long_long" >&6; }
-
-
-
-cat >>confdefs.h <<_ACEOF
-#define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long
-_ACEOF
-
-
-# The cast to long int works around a bug in the HP C Compiler
-# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
-# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
-# This bug is HP SR number 8606223364.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of void *" >&5
-$as_echo_n "checking size of void *... " >&6; }
-if ${ac_cv_sizeof_void_p+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (void *))" "ac_cv_sizeof_void_p" "$ac_includes_default"; then :
-
-else
- if test "$ac_cv_type_void_p" = yes; then
- { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error 77 "cannot compute sizeof (void *)
-See \`config.log' for more details" "$LINENO" 5; }
- else
- ac_cv_sizeof_void_p=0
- fi
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_void_p" >&5
-$as_echo "$ac_cv_sizeof_void_p" >&6; }
-
-
-
-cat >>confdefs.h <<_ACEOF
-#define SIZEOF_VOID_P $ac_cv_sizeof_void_p
-_ACEOF
-
-
-# The cast to long int works around a bug in the HP C Compiler
-# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
-# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
-# This bug is HP SR number 8606223364.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5
-$as_echo_n "checking size of long... " >&6; }
-if ${ac_cv_sizeof_long+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long" "$ac_includes_default"; then :
-
-else
- if test "$ac_cv_type_long" = yes; then
- { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error 77 "cannot compute sizeof (long)
-See \`config.log' for more details" "$LINENO" 5; }
- else
- ac_cv_sizeof_long=0
- fi
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5
-$as_echo "$ac_cv_sizeof_long" >&6; }
-
-
-
-cat >>confdefs.h <<_ACEOF
-#define SIZEOF_LONG $ac_cv_sizeof_long
-_ACEOF
-
-
-# The cast to long int works around a bug in the HP C Compiler
-# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
-# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
-# This bug is HP SR number 8606223364.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int" >&5
-$as_echo_n "checking size of int... " >&6; }
-if ${ac_cv_sizeof_int+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (int))" "ac_cv_sizeof_int" "$ac_includes_default"; then :
-
-else
- if test "$ac_cv_type_int" = yes; then
- { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error 77 "cannot compute sizeof (int)
-See \`config.log' for more details" "$LINENO" 5; }
- else
- ac_cv_sizeof_int=0
- fi
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int" >&5
-$as_echo "$ac_cv_sizeof_int" >&6; }
-
-
-
-cat >>confdefs.h <<_ACEOF
-#define SIZEOF_INT $ac_cv_sizeof_int
-_ACEOF
-
-
-
-if test "x${ac_cv_sizeof_void_p}" = "x8"; then
- host64=true
-fi
-
-# Put a plausible default for CC_FOR_BUILD in Makefile.
-if test -z "$CC_FOR_BUILD"; then
- if test "x$cross_compiling" = "xno"; then
- CC_FOR_BUILD='$(CC)'
- else
- CC_FOR_BUILD=gcc
- fi
-fi
-
-# Also set EXEEXT_FOR_BUILD.
-if test "x$cross_compiling" = "xno"; then
- EXEEXT_FOR_BUILD='$(EXEEXT)'
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for build system executable suffix" >&5
-$as_echo_n "checking for build system executable suffix... " >&6; }
-if ${bfd_cv_build_exeext+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- rm -f conftest*
- echo 'int main () { return 0; }' > conftest.c
- bfd_cv_build_exeext=
- ${CC_FOR_BUILD} -o conftest conftest.c 1>&5 2>&5
- for file in conftest.*; do
- case $file in
- *.c | *.o | *.obj | *.ilk | *.pdb) ;;
- *) bfd_cv_build_exeext=`echo $file | sed -e s/conftest//` ;;
- esac
- done
- rm -f conftest*
- test x"${bfd_cv_build_exeext}" = x && bfd_cv_build_exeext=no
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_build_exeext" >&5
-$as_echo "$bfd_cv_build_exeext" >&6; }
- EXEEXT_FOR_BUILD=""
- test x"${bfd_cv_build_exeext}" != xno && EXEEXT_FOR_BUILD=${bfd_cv_build_exeext}
-fi
-
-
-for ac_header in fcntl.h sys/file.h sys/resource.h sys/stat.h sys/types.h \
- unistd.h
-do :
- as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
-ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
-if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
- cat >>confdefs.h <<_ACEOF
-#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
-_ACEOF
-
-fi
-
-done
-
-
-for ac_func in fcntl fdopen fileno fls getgid getpagesize getrlimit getuid \
- sysconf
-do :
- as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
-ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
-if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
- cat >>confdefs.h <<_ACEOF
-#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
-_ACEOF
-
-fi
-done
-
-
-ac_fn_c_check_decl "$LINENO" "basename" "ac_cv_have_decl_basename" "$ac_includes_default"
-if test "x$ac_cv_have_decl_basename" = xyes; then :
- ac_have_decl=1
-else
- ac_have_decl=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define HAVE_DECL_BASENAME $ac_have_decl
-_ACEOF
-ac_fn_c_check_decl "$LINENO" "ffs" "ac_cv_have_decl_ffs" "$ac_includes_default"
-if test "x$ac_cv_have_decl_ffs" = xyes; then :
- ac_have_decl=1
-else
- ac_have_decl=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define HAVE_DECL_FFS $ac_have_decl
-_ACEOF
-ac_fn_c_check_decl "$LINENO" "stpcpy" "ac_cv_have_decl_stpcpy" "$ac_includes_default"
-if test "x$ac_cv_have_decl_stpcpy" = xyes; then :
- ac_have_decl=1
-else
- ac_have_decl=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define HAVE_DECL_STPCPY $ac_have_decl
-_ACEOF
-ac_fn_c_check_decl "$LINENO" "asprintf" "ac_cv_have_decl_asprintf" "$ac_includes_default"
-if test "x$ac_cv_have_decl_asprintf" = xyes; then :
- ac_have_decl=1
-else
- ac_have_decl=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define HAVE_DECL_ASPRINTF $ac_have_decl
-_ACEOF
-ac_fn_c_check_decl "$LINENO" "vasprintf" "ac_cv_have_decl_vasprintf" "$ac_includes_default"
-if test "x$ac_cv_have_decl_vasprintf" = xyes; then :
- ac_have_decl=1
-else
- ac_have_decl=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define HAVE_DECL_VASPRINTF $ac_have_decl
-_ACEOF
-ac_fn_c_check_decl "$LINENO" "strnlen" "ac_cv_have_decl_strnlen" "$ac_includes_default"
-if test "x$ac_cv_have_decl_strnlen" = xyes; then :
- ac_have_decl=1
-else
- ac_have_decl=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define HAVE_DECL_STRNLEN $ac_have_decl
-_ACEOF
-
-ac_fn_c_check_decl "$LINENO" "___lc_codepage_func" "ac_cv_have_decl____lc_codepage_func" "#include <locale.h>
-"
-if test "x$ac_cv_have_decl____lc_codepage_func" = xyes; then :
- ac_have_decl=1
-else
- ac_have_decl=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define HAVE_DECL____LC_CODEPAGE_FUNC $ac_have_decl
-_ACEOF
-
-
-
-case "${host}" in
-*-*-msdos* | *-*-go32* | *-*-mingw32* | *-*-cygwin* | *-*-windows*)
-
-$as_echo "#define USE_BINARY_FOPEN 1" >>confdefs.h
- ;;
-esac
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for thread local storage (TLS) class" >&5
-$as_echo_n "checking for thread local storage (TLS) class... " >&6; }
- if ${ac_cv_tls+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- for ax_tls_keyword in thread_local _Thread_local __thread '__declspec(thread)' none; do
- case $ax_tls_keyword in #(
- none) :
- ac_cv_tls=none ; break ;; #(
- *) :
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <stdlib.h>
-int
-main ()
-{
-static $ax_tls_keyword int bar;
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_tls=$ax_tls_keyword ; break
-else
- ac_cv_tls=none
-
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- ;;
-esac
- done
-
-fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_tls" >&5
-$as_echo "$ac_cv_tls" >&6; }
-
- if test "$ac_cv_tls" != "none"; then :
-
-cat >>confdefs.h <<_ACEOF
-#define TLS $ac_cv_tls
-_ACEOF
-
- :
-else
- :
-fi
-
-
-# Link in zlib/zstd if we can. This allows us to read compressed debug sections.
-# This is used only by compress.c.
-
- # Use the system's zlib library.
- zlibdir="-L\$(top_builddir)/../zlib"
- zlibinc="-I\$(top_srcdir)/../zlib"
-
-# Check whether --with-system-zlib was given.
-if test "${with_system_zlib+set}" = set; then :
- withval=$with_system_zlib; if test x$with_system_zlib = xyes ; then
- zlibdir=
- zlibinc=
- fi
-
-fi
-
-
-
-
-
-
-
-
-
-
-
-if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
-set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_PKG_CONFIG+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $PKG_CONFIG in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
- ;;
- *)
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
- ;;
-esac
-fi
-PKG_CONFIG=$ac_cv_path_PKG_CONFIG
-if test -n "$PKG_CONFIG"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
-$as_echo "$PKG_CONFIG" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_path_PKG_CONFIG"; then
- ac_pt_PKG_CONFIG=$PKG_CONFIG
- # Extract the first word of "pkg-config", so it can be a program name with args.
-set dummy pkg-config; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $ac_pt_PKG_CONFIG in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
- ;;
- *)
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
- ;;
-esac
-fi
-ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
-if test -n "$ac_pt_PKG_CONFIG"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5
-$as_echo "$ac_pt_PKG_CONFIG" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_pt_PKG_CONFIG" = x; then
- PKG_CONFIG=""
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- PKG_CONFIG=$ac_pt_PKG_CONFIG
- fi
-else
- PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
-fi
-
-fi
-if test -n "$PKG_CONFIG"; then
- _pkg_min_version=0.9.0
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5
-$as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; }
- if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- PKG_CONFIG=""
- fi
-fi
-
-
-# Check whether --with-zstd was given.
-if test "${with_zstd+set}" = set; then :
- withval=$with_zstd;
-else
- with_zstd=auto
-fi
-
-
-if test "$with_zstd" != no; then :
-
-pkg_failed=no
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for libzstd >= 1.4.0" >&5
-$as_echo_n "checking for libzstd >= 1.4.0... " >&6; }
-
-if test -n "$ZSTD_CFLAGS"; then
- pkg_cv_ZSTD_CFLAGS="$ZSTD_CFLAGS"
- elif test -n "$PKG_CONFIG"; then
- if test -n "$PKG_CONFIG" && \
- { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libzstd >= 1.4.0\""; } >&5
- ($PKG_CONFIG --exists --print-errors "libzstd >= 1.4.0") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- pkg_cv_ZSTD_CFLAGS=`$PKG_CONFIG --cflags "libzstd >= 1.4.0" 2>/dev/null`
- test "x$?" != "x0" && pkg_failed=yes
-else
- pkg_failed=yes
-fi
- else
- pkg_failed=untried
-fi
-if test -n "$ZSTD_LIBS"; then
- pkg_cv_ZSTD_LIBS="$ZSTD_LIBS"
- elif test -n "$PKG_CONFIG"; then
- if test -n "$PKG_CONFIG" && \
- { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libzstd >= 1.4.0\""; } >&5
- ($PKG_CONFIG --exists --print-errors "libzstd >= 1.4.0") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- pkg_cv_ZSTD_LIBS=`$PKG_CONFIG --libs "libzstd >= 1.4.0" 2>/dev/null`
- test "x$?" != "x0" && pkg_failed=yes
-else
- pkg_failed=yes
-fi
- else
- pkg_failed=untried
-fi
-
-if test $pkg_failed = no; then
- pkg_save_LDFLAGS="$LDFLAGS"
- LDFLAGS="$LDFLAGS $pkg_cv_ZSTD_LIBS"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
-
-else
- pkg_failed=yes
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LDFLAGS=$pkg_save_LDFLAGS
-fi
-
-
-
-if test $pkg_failed = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-
-if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then
- _pkg_short_errors_supported=yes
-else
- _pkg_short_errors_supported=no
-fi
- if test $_pkg_short_errors_supported = yes; then
- ZSTD_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "libzstd >= 1.4.0" 2>&1`
- else
- ZSTD_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "libzstd >= 1.4.0" 2>&1`
- fi
- # Put the nasty error message in config.log where it belongs
- echo "$ZSTD_PKG_ERRORS" >&5
-
-
- if test "$with_zstd" = yes; then
- as_fn_error $? "--with-zstd was given, but pkgconfig/libzstd.pc is not found" "$LINENO" 5
- fi
-
-elif test $pkg_failed = untried; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-
- if test "$with_zstd" = yes; then
- as_fn_error $? "--with-zstd was given, but pkgconfig/libzstd.pc is not found" "$LINENO" 5
- fi
-
-else
- ZSTD_CFLAGS=$pkg_cv_ZSTD_CFLAGS
- ZSTD_LIBS=$pkg_cv_ZSTD_LIBS
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-
-
-$as_echo "#define HAVE_ZSTD 1" >>confdefs.h
-
-
-fi
-
-fi
-
-
-save_CFLAGS="$CFLAGS"
-CFLAGS="$CFLAGS -Werror"
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking compiler support for hidden visibility" >&5
-$as_echo_n "checking compiler support for hidden visibility... " >&6; }
-if ${bfd_cv_hidden+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-const char hw[] __attribute__ ((__visibility__ ("hidden"))) = "Hello, World\n";
-extern void print (const char *) __attribute__ ((__visibility__ ("hidden")));
-int
-main ()
-{
-print (hw);
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- bfd_cv_hidden=yes
-else
- bfd_cv_hidden=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_hidden" >&5
-$as_echo "$bfd_cv_hidden" >&6; }
-CFLAGS="$save_CFLAGS"
-if test $bfd_cv_hidden = yes; then
-
-$as_echo "#define HAVE_HIDDEN 1" >>confdefs.h
-
-fi
-
-# Check if linker supports --as-needed and --no-as-needed options
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking linker --as-needed support" >&5
-$as_echo_n "checking linker --as-needed support... " >&6; }
-if ${bfd_cv_ld_as_needed+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- bfd_cv_ld_as_needed=no
- if $LD --help 2>/dev/null | grep as-needed > /dev/null; then
- bfd_cv_ld_as_needed=yes
- fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_ld_as_needed" >&5
-$as_echo "$bfd_cv_ld_as_needed" >&6; }
-
-LIBM=
-case $host in
-*-*-beos* | *-*-cegcc* | *-*-cygwin* | *-*-haiku* | *-*-pw32* | *-*-darwin*)
- # These system don't have libm, or don't need it
- ;;
-*-ncr-sysv4.3*)
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _mwvalidcheckl in -lmw" >&5
-$as_echo_n "checking for _mwvalidcheckl in -lmw... " >&6; }
-if ${ac_cv_lib_mw__mwvalidcheckl+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-lmw $LIBS"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char _mwvalidcheckl ();
-int
-main ()
-{
-return _mwvalidcheckl ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_lib_mw__mwvalidcheckl=yes
-else
- ac_cv_lib_mw__mwvalidcheckl=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_mw__mwvalidcheckl" >&5
-$as_echo "$ac_cv_lib_mw__mwvalidcheckl" >&6; }
-if test "x$ac_cv_lib_mw__mwvalidcheckl" = xyes; then :
- LIBM="-lmw"
-fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cos in -lm" >&5
-$as_echo_n "checking for cos in -lm... " >&6; }
-if ${ac_cv_lib_m_cos+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-lm $LIBS"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char cos ();
-int
-main ()
-{
-return cos ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_lib_m_cos=yes
-else
- ac_cv_lib_m_cos=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_cos" >&5
-$as_echo "$ac_cv_lib_m_cos" >&6; }
-if test "x$ac_cv_lib_m_cos" = xyes; then :
- LIBM="$LIBM -lm"
-fi
-
- ;;
-*)
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cos in -lm" >&5
-$as_echo_n "checking for cos in -lm... " >&6; }
-if ${ac_cv_lib_m_cos+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-lm $LIBS"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char cos ();
-int
-main ()
-{
-return cos ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_lib_m_cos=yes
-else
- ac_cv_lib_m_cos=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_cos" >&5
-$as_echo "$ac_cv_lib_m_cos" >&6; }
-if test "x$ac_cv_lib_m_cos" = xyes; then :
- LIBM="-lm"
-fi
-
- ;;
-esac
-
-
-
-# When building a shared libbfd, link against the pic version of libiberty
-# so that apps that use libbfd won't need libiberty just to satisfy any
-# libbfd references.
-# We can't do that if a pic libiberty is unavailable since including non-pic
-# code would insert text relocations into libbfd.
-SHARED_LIBADD=
-SHARED_LDFLAGS=
-if test "$enable_shared" = "yes"; then
- x=`sed -n -e 's/^[ ]*PICFLAG[ ]*=[ ]*//p' < ../libiberty/Makefile | sed -n '$p'`
- if test -n "$x"; then
- SHARED_LIBADD="-L`pwd`/../libiberty/pic -liberty"
- fi
-fi
-
-SHARED_LIBADD="$SHARED_LIBADD $LTLIBINTL"
-
-if test "$enable_shared" = "yes"; then
- case "${host}" in
- # More hacks to build DLLs on Windows.
- *-*-cygwin*)
- SHARED_LDFLAGS="-no-undefined"
- SHARED_LIBADD="-L`pwd`/../libiberty -liberty $SHARED_LIBADD -lcygwin -lkernel32"
- ;;
- esac
-
- if test -n "$SHARED_LIBADD"; then
- if test -n "$LIBM"; then
- if test x"$bfd_cv_ld_as_needed" = xyes; then
- # Link against libm only when needed. Put -lc, -lm inside -Wl
- # to stop libtool reordering these options.
- SHARED_LIBADD="$SHARED_LIBADD -Wl,-lc,--as-needed,`echo $LIBM | sed 's/ /,/g'`,--no-as-needed"
- else
- SHARED_LIBADD="$SHARED_LIBADD $LIBM"
- fi
- fi
- fi
-fi
-
-
-
-# target stuff:
-
-# Canonicalize the secondary target names.
-if test -n "$enable_targets" ; then
- for targ in `echo $enable_targets | sed 's/,/ /g'`
- do
- result=`$ac_config_sub $targ 2>/dev/null`
- if test -n "$result" ; then
- canon_targets="$canon_targets $result"
- else
- # Allow targets that config.sub doesn't recognize, like "all".
- canon_targets="$canon_targets $targ"
- fi
- done
-fi
-
-all_targets=false
-defvec=
-selvecs=
-assocvecs=
-selarchs=
-TDEFINES=
-for targ in $target $canon_targets
-do
- if test $targ = all; then
- all_targets=true
- assocvecs="$assocvecs $targ_defvec $targ_selvecs"
- elif test $targ != plugin; then
- . $srcdir/config.bfd
- if test $targ = $target; then
- defvec=$targ_defvec
- fi
- selvecs="$selvecs $targ_defvec $targ_selvecs"
- selarchs="$selarchs $targ_archs"
- TDEFINES="$TDEFINES $targ_cflags"
- fi
-done
-
-
-# This processing still needs to be done if we're to decide properly whether
-# 64-bit support needs to be compiled in. Currently, it will be included if
-# the default or any other explicitly requested target requires it; it
-# will not be included on a 32-bit host if no 64-bit target is requested, and
-# no "--with-64-bit-bfd" option is given, even if "--enable-targets=all" is
-# used.
-
-# uniq the default and selected vectors in all the configured targets.
-f=""
-for i in $selvecs ; do
- case " $f " in
- *" $i "*) ;;
- *) f="$f $i" ;;
- esac
-done
-selvecs="$f"
-
-
-# uniq the associated vectors in all the configured targets.
-f=""
-for i in $assocvecs ; do
- case " $f " in
- *" $i "*) ;;
- *) f="$f $i" ;;
- esac
-done
-assocvecs="$f"
-
-
-# uniq the architectures in all the configured targets.
-f=""
-for i in $selarchs ; do
- case " $f " in
- *" $i "*) ;;
- *) f="$f $i" ;;
- esac
-done
-selarchs="$f"
-
-# Target backend .o files.
-tb=
-
-elf="elf.lo elflink.lo elf-attrs.lo elf-strtab.lo elf-eh-frame.lo
- elf-sframe.lo dwarf1.lo dwarf2.lo"
-coffgen="coffgen.lo dwarf2.lo"
-coff="cofflink.lo $coffgen"
-ecoff="ecofflink.lo $coffgen"
-xcoff="xcofflink.lo $coffgen"
-
-elfxx_x86="elfxx-x86.lo elf-ifunc.lo elf-vxworks.lo"
-for vec in $selvecs
-do
- target_size=32
- case "$vec" in
- # This list is alphabetized to make it easy to compare
- # with the two vector lists in targets.c. For the same reason,
- # use one entry per line, even though this leads to long lines.
- aarch64_elf32_be_vec) tb="$tb elf32-aarch64.lo elfxx-aarch64.lo elf-ifunc.lo elf32.lo $elf"; target_size=64 ;;
- aarch64_elf32_le_vec) tb="$tb elf32-aarch64.lo elfxx-aarch64.lo elf-ifunc.lo elf32.lo $elf"; target_size=64 ;;
- aarch64_elf64_be_vec) tb="$tb elf64-aarch64.lo elfxx-aarch64.lo elf-ifunc.lo elf64.lo $elf"; target_size=64 ;;
- aarch64_elf64_be_cloudabi_vec) tb="$tb elf64-aarch64.lo elfxx-aarch64.lo elf-ifunc.lo elf64.lo $elf"; target_size=64 ;;
- aarch64_elf64_le_vec) tb="$tb elf64-aarch64.lo elfxx-aarch64.lo elf-ifunc.lo elf64.lo $elf"; target_size=64 ;;
- aarch64_elf64_le_cloudabi_vec) tb="$tb elf64-aarch64.lo elfxx-aarch64.lo elf-ifunc.lo elf64.lo $elf"; target_size=64 ;;
- aarch64_mach_o_vec) tb="$tb mach-o-aarch64.lo"; target_size=64 ;;
- aarch64_pei_le_vec) tb="$tb pei-aarch64.lo pe-aarch64igen.lo $coff"; target_size=64 ;;
- aarch64_pe_le_vec) tb="$tb pe-aarch64.lo pe-aarch64igen.lo $coff"; target_size=64 ;;
- alpha_ecoff_le_vec) tb="$tb coff-alpha.lo ecoff.lo $ecoff"; target_size=64 ;;
- alpha_elf64_vec) tb="$tb elf64-alpha.lo elf64.lo $elf"; target_size=64 ;;
- alpha_elf64_fbsd_vec) tb="$tb elf64-alpha.lo elf64.lo $elf"; target_size=64 ;;
- alpha_vms_vec) tb="$tb vms-alpha.lo vms-misc.lo vms-lib.lo"; target_size=64 ;;
- alpha_vms_lib_txt_vec) tb="$tb vms-lib.lo vms-misc.lo" ;;
- am33_elf32_linux_vec) tb="$tb elf32-am33lin.lo elf32.lo $elf" ;;
- amdgcn_elf64_le_vec) tb="$tb elf64-amdgcn.lo elf64.lo $elf"; target_size=64 ;;
- aout0_be_vec) tb="$tb aout0.lo aout32.lo" ;;
- aout64_vec) tb="$tb demo64.lo aout64.lo"; target_size=64 ;;
- aout_vec) tb="$tb host-aout.lo aout32.lo" ;;
- arc_elf32_be_vec) tb="$tb elf32-arc.lo elf32.lo $elf" ;;
- arc_elf32_le_vec) tb="$tb elf32-arc.lo elf32.lo $elf" ;;
- arm_elf32_be_vec) tb="$tb elf32-arm.lo elf32.lo elf-nacl.lo elf-vxworks.lo $elf" ;;
- arm_elf32_le_vec) tb="$tb elf32-arm.lo elf32.lo elf-nacl.lo elf-vxworks.lo $elf" ;;
- arm_elf32_fdpic_be_vec) tb="$tb elf32-arm.lo elf32.lo elf-nacl.lo elf-vxworks.lo $elf" ;;
- arm_elf32_fdpic_le_vec) tb="$tb elf32-arm.lo elf32.lo elf-nacl.lo elf-vxworks.lo $elf" ;;
- arm_elf32_nacl_be_vec) tb="$tb elf32-arm.lo elf32.lo elf-nacl.lo elf-vxworks.lo $elf" ;;
- arm_elf32_nacl_le_vec) tb="$tb elf32-arm.lo elf32.lo elf-nacl.lo elf-vxworks.lo $elf" ;;
- arm_elf32_vxworks_be_vec) tb="$tb elf32-arm.lo elf32.lo elf-nacl.lo elf-vxworks.lo $elf" ;;
- arm_elf32_vxworks_le_vec) tb="$tb elf32-arm.lo elf32.lo elf-nacl.lo elf-vxworks.lo $elf" ;;
- arm_pe_be_vec) tb="$tb pe-arm.lo peigen.lo $coff" ;;
- arm_pe_le_vec) tb="$tb pe-arm.lo peigen.lo $coff" ;;
- arm_pe_wince_be_vec) tb="$tb pe-arm-wince.lo pe-arm.lo peigen.lo $coff" ;;
- arm_pe_wince_le_vec) tb="$tb pe-arm-wince.lo pe-arm.lo peigen.lo $coff" ;;
- arm_pei_be_vec) tb="$tb pei-arm.lo peigen.lo $coff" ;;
- arm_pei_le_vec) tb="$tb pei-arm.lo peigen.lo $coff" ;;
- arm_pei_wince_be_vec) tb="$tb pei-arm-wince.lo pei-arm.lo peigen.lo $coff" ;;
- arm_pei_wince_le_vec) tb="$tb pei-arm-wince.lo pei-arm.lo peigen.lo $coff" ;;
- arm_mach_o_vec) tb="$tb mach-o-arm.lo" ;;
- avr_elf32_vec) tb="$tb elf32-avr.lo elf32.lo $elf" ;;
- bfin_elf32_vec) tb="$tb elf32-bfin.lo elf32.lo $elf" ;;
- bfin_elf32_fdpic_vec) tb="$tb elf32-bfin.lo elf32.lo $elf" ;;
- cr16_elf32_vec) tb="$tb elf32-cr16.lo elf32.lo $elf" ;;
- cris_aout_vec) tb="$tb aout-cris.lo" ;;
- cris_elf32_vec) tb="$tb elf32-cris.lo elf32.lo $elf" ;;
- cris_elf32_us_vec) tb="$tb elf32-cris.lo elf32.lo $elf" ;;
- crx_elf32_vec) tb="$tb elf32-crx.lo elf32.lo $elf" ;;
- csky_elf32_be_vec) tb="$tb elf32-csky.lo elf32.lo $elf" ;;
- csky_elf32_le_vec) tb="$tb elf32-csky.lo elf32.lo $elf" ;;
- d10v_elf32_vec) tb="$tb elf32-d10v.lo elf32.lo $elf" ;;
- d30v_elf32_vec) tb="$tb elf32-d30v.lo elf32.lo $elf" ;;
- dlx_elf32_be_vec) tb="$tb elf32-dlx.lo elf32.lo $elf" ;;
- elf32_be_vec) tb="$tb elf32-gen.lo elf32.lo $elf" ;;
- elf32_le_vec) tb="$tb elf32-gen.lo elf32.lo $elf" ;;
- elf64_be_vec) tb="$tb elf64-gen.lo elf64.lo $elf"; target_size=64 ;;
- elf64_le_vec) tb="$tb elf64-gen.lo elf64.lo $elf"; target_size=64 ;;
- bpf_elf64_le_vec) tb="$tb elf64-bpf.lo elf64.lo $elf"; target_size=64;;
- bpf_elf64_be_vec) tb="$tb elf64-bpf.lo elf64.lo $elf"; target_size=64 ;;
- epiphany_elf32_vec) tb="$tb elf32-epiphany.lo elf32.lo $elf" ;;
- fr30_elf32_vec) tb="$tb elf32-fr30.lo elf32.lo $elf" ;;
- frv_elf32_vec) tb="$tb elf32-frv.lo elf32.lo $elf" ;;
- frv_elf32_fdpic_vec) tb="$tb elf32-frv.lo elf32.lo $elf" ;;
- h8300_elf32_vec) tb="$tb elf32-h8300.lo elf32.lo $elf" ;;
- h8300_elf32_linux_vec) tb="$tb elf32-h8300.lo elf32.lo $elf" ;;
- hppa_elf32_vec) tb="$tb elf32-hppa.lo elf32.lo $elf" ;;
- hppa_elf32_linux_vec) tb="$tb elf32-hppa.lo elf32.lo $elf" ;;
- hppa_elf32_nbsd_vec) tb="$tb elf32-hppa.lo elf32.lo $elf" ;;
- hppa_elf64_vec) tb="$tb elf64-hppa.lo elf64.lo $elf"; target_size=64 ;;
- hppa_elf64_linux_vec) tb="$tb elf64-hppa.lo elf64.lo $elf"; target_size=64 ;;
- hppa_som_vec) tb="$tb som.lo" ;;
- i386_aout_vec) tb="$tb i386aout.lo aout32.lo" ;;
- i386_aout_bsd_vec) tb="$tb i386bsd.lo aout32.lo" ;;
- i386_aout_lynx_vec) tb="$tb i386lynx.lo lynx-core.lo aout32.lo" ;;
- i386_coff_vec) tb="$tb coff-i386.lo $coff" ;;
- i386_coff_go32_vec) tb="$tb coff-go32.lo $coff" ;;
- i386_coff_go32stubbed_vec) tb="$tb coff-stgo32.lo $coff" ;;
- i386_coff_lynx_vec) tb="$tb cf-i386lynx.lo lynx-core.lo $coff" ;;
- i386_elf32_vec) tb="$tb elf32-i386.lo $elfxx_x86 elf32.lo $elf" ;;
- i386_elf32_fbsd_vec) tb="$tb elf32-i386.lo $elfxx_x86 elf32.lo $elf" ;;
- i386_elf32_sol2_vec) tb="$tb elf32-i386.lo $elfxx_x86 elf32.lo $elf" ;;
- i386_elf32_vxworks_vec) tb="$tb elf32-i386.lo $elfxx_x86 elf32.lo $elf" ;;
- i386_mach_o_vec) tb="$tb mach-o-i386.lo" ;;
- i386_msdos_vec) tb="$tb i386msdos.lo" ;;
- i386_pe_vec) tb="$tb pe-i386.lo peigen.lo $coff" ;;
- i386_pe_big_vec) tb="$tb pe-i386.lo peigen.lo $coff" ;;
- i386_pei_vec) tb="$tb pei-i386.lo peigen.lo $coff" ;;
- iamcu_elf32_vec) tb="$tb elf32-i386.lo $elfxx_x86 elf32.lo $elf" ;;
- ia64_elf32_be_vec) tb="$tb elf32-ia64.lo elfxx-ia64.lo elf32.lo $elf" ;;
- ia64_elf32_hpux_be_vec) tb="$tb elf32-ia64.lo elfxx-ia64.lo elf32.lo $elf" ;;
- ia64_elf64_be_vec) tb="$tb elf64-ia64.lo elfxx-ia64.lo elf64.lo $elf"; target_size=64 ;;
- ia64_elf64_le_vec) tb="$tb elf64-ia64.lo elfxx-ia64.lo elf64.lo $elf"; target_size=64 ;;
- ia64_elf64_hpux_be_vec) tb="$tb elf64-ia64.lo elfxx-ia64.lo elf64.lo $elf"; target_size=64 ;;
- ia64_elf64_vms_vec) tb="$tb elf64-ia64-vms.lo elf64-ia64.lo elfxx-ia64.lo elf64.lo vms-lib.lo vms-misc.lo $elf"; target_size=64 ;;
- ia64_pei_vec) tb="$tb pei-ia64.lo pepigen.lo $coff"; target_size=64 ;;
- ip2k_elf32_vec) tb="$tb elf32-ip2k.lo elf32.lo $elf" ;;
- iq2000_elf32_vec) tb="$tb elf32-iq2000.lo elf32.lo $elf" ;;
- kvx_elf32_vec) tb="$tb elf32-kvx.lo elfxx-kvx.lo elf32.lo $elf $ipa" ;;
- kvx_elf64_vec) tb="$tb elf64-kvx.lo elfxx-kvx.lo elf64.lo $elf $ipa"; target_size=64 ;;
- lm32_elf32_vec) tb="$tb elf32-lm32.lo elf32.lo $elf" ;;
- lm32_elf32_fdpic_vec) tb="$tb elf32-lm32.lo elf32.lo $elf" ;;
- loongarch_elf32_vec) tb="$tb elf32-loongarch.lo elfxx-loongarch.lo elf32.lo elf-ifunc.lo $elf" ;;
- loongarch_elf64_vec) tb="$tb elf64-loongarch.lo elf64.lo elfxx-loongarch.lo elf32.lo elf-ifunc.lo $elf"; target_size=64 ;;
- loongarch64_pei_vec) tb="$tb pei-loongarch64.lo pe-loongarch64igen.lo $coff"; target_size=64 ;;
- m32c_elf32_vec) tb="$tb elf32-m32c.lo elf32.lo $elf" ;;
- m32r_elf32_vec) tb="$tb elf32-m32r.lo elf32.lo $elf" ;;
- m32r_elf32_le_vec) tb="$tb elf32-m32r.lo elf32.lo $elf" ;;
- m32r_elf32_linux_vec) tb="$tb elf32-m32r.lo elf32.lo $elf" ;;
- m32r_elf32_linux_le_vec) tb="$tb elf32-m32r.lo elf32.lo $elf" ;;
- m68hc11_elf32_vec) tb="$tb elf32-m68hc11.lo elf32-m68hc1x.lo elf32.lo $elf" ;;
- m68hc12_elf32_vec) tb="$tb elf32-m68hc12.lo elf32-m68hc1x.lo elf32.lo $elf" ;;
- m68k_elf32_vec) tb="$tb elf32-m68k.lo elf32.lo $elf" ;;
- s12z_elf32_vec) tb="$tb elf32-s12z.lo elf32.lo $elf" ;;
- mach_o_be_vec) tb="$tb mach-o.lo dwarf2.lo" ;;
- mach_o_le_vec) tb="$tb mach-o.lo dwarf2.lo" ;;
- mach_o_fat_vec) tb="$tb mach-o.lo dwarf2.lo" ;;
- mcore_elf32_be_vec) tb="$tb elf32-mcore.lo elf32.lo $elf" ;;
- mcore_elf32_le_vec) tb="$tb elf32-mcore.lo elf32.lo $elf" ;;
- mcore_pe_be_vec) tb="$tb pe-mcore.lo peigen.lo $coff" ;;
- mcore_pe_le_vec) tb="$tb pe-mcore.lo peigen.lo $coff" ;;
- mcore_pei_be_vec) tb="$tb pei-mcore.lo peigen.lo $coff" ;;
- mcore_pei_le_vec) tb="$tb pei-mcore.lo peigen.lo $coff" ;;
- mep_elf32_vec) tb="$tb elf32-mep.lo elf32.lo $elf" ;;
- mep_elf32_le_vec) tb="$tb elf32-mep.lo elf32.lo $elf" ;;
- metag_elf32_vec) tb="$tb elf32-metag.lo elf32.lo $elf" ;;
- microblaze_elf32_vec) tb="$tb elf32-microblaze.lo elf32.lo $elf" ;;
- microblaze_elf32_le_vec) tb="$tb elf32-microblaze.lo elf32.lo $elf" ;;
- mips_ecoff_be_vec) tb="$tb coff-mips.lo ecoff.lo $ecoff" ;;
- mips_ecoff_le_vec) tb="$tb coff-mips.lo ecoff.lo $ecoff" ;;
- mips_ecoff_bele_vec) tb="$tb coff-mips.lo ecoff.lo $ecoff" ;;
- mips_elf32_be_vec) tb="$tb elf32-mips.lo elfxx-mips.lo elf-vxworks.lo elf32.lo $elf $ecoff" ;;
- mips_elf32_le_vec) tb="$tb elf32-mips.lo elfxx-mips.lo elf-vxworks.lo elf32.lo $elf $ecoff" ;;
- mips_elf32_n_be_vec) tb="$tb elfn32-mips.lo elfxx-mips.lo elf-vxworks.lo elf32.lo $elf $ecoff"; target_size=64 ;;
- mips_elf32_n_le_vec) tb="$tb elfn32-mips.lo elfxx-mips.lo elf-vxworks.lo elf32.lo $elf $ecoff"; target_size=64 ;;
- mips_elf32_ntrad_be_vec) tb="$tb elfn32-mips.lo elfxx-mips.lo elf-vxworks.lo elf32.lo $elf $ecoff"; target_size=64 ;;
- mips_elf32_ntrad_le_vec) tb="$tb elfn32-mips.lo elfxx-mips.lo elf-vxworks.lo elf32.lo $elf $ecoff"; target_size=64 ;;
- mips_elf32_ntradfbsd_be_vec) tb="$tb elfn32-mips.lo elfxx-mips.lo elf-vxworks.lo elf32.lo $elf $ecoff"; target_size=64 ;;
- mips_elf32_ntradfbsd_le_vec) tb="$tb elfn32-mips.lo elfxx-mips.lo elf-vxworks.lo elf32.lo $elf $ecoff"; target_size=64 ;;
- mips_elf32_trad_be_vec) tb="$tb elf32-mips.lo elfxx-mips.lo elf-vxworks.lo elf32.lo $elf $ecoff" ;;
- mips_elf32_trad_le_vec) tb="$tb elf32-mips.lo elfxx-mips.lo elf-vxworks.lo elf32.lo $elf $ecoff" ;;
- mips_elf32_tradfbsd_be_vec) tb="$tb elf32-mips.lo elfxx-mips.lo elf-vxworks.lo elf32.lo $elf $ecoff" ;;
- mips_elf32_tradfbsd_le_vec) tb="$tb elf32-mips.lo elfxx-mips.lo elf-vxworks.lo elf32.lo $elf $ecoff" ;;
- mips_elf32_vxworks_be_vec) tb="$tb elf32-mips.lo elfxx-mips.lo elf-vxworks.lo elf32.lo $elf $ecoff" ;;
- mips_elf32_vxworks_le_vec) tb="$tb elf32-mips.lo elfxx-mips.lo elf-vxworks.lo elf32.lo $elf $ecoff" ;;
- mips_elf64_be_vec) tb="$tb elf64-mips.lo elf64.lo elfxx-mips.lo elf-vxworks.lo elf32.lo $elf $ecoff"; target_size=64 ;;
- mips_elf64_le_vec) tb="$tb elf64-mips.lo elf64.lo elfxx-mips.lo elf-vxworks.lo elf32.lo $elf $ecoff"; target_size=64 ;;
- mips_elf64_trad_be_vec) tb="$tb elf64-mips.lo elf64.lo elfxx-mips.lo elf-vxworks.lo elf32.lo $elf $ecoff"; target_size=64 ;;
- mips_elf64_trad_le_vec) tb="$tb elf64-mips.lo elf64.lo elfxx-mips.lo elf-vxworks.lo elf32.lo $elf $ecoff"; target_size=64 ;;
- mips_elf64_tradfbsd_be_vec) tb="$tb elf64-mips.lo elf64.lo elfxx-mips.lo elf-vxworks.lo elf32.lo $elf $ecoff"; target_size=64 ;;
- mips_elf64_tradfbsd_le_vec) tb="$tb elf64-mips.lo elf64.lo elfxx-mips.lo elf-vxworks.lo elf32.lo $elf $ecoff"; target_size=64 ;;
- mmix_elf64_vec) tb="$tb elf64-mmix.lo elf64.lo $elf" target_size=64 ;;
- mmix_mmo_vec) tb="$tb mmo.lo" target_size=64 ;;
- mn10200_elf32_vec) tb="$tb elf-m10200.lo elf32.lo $elf" ;;
- mn10300_elf32_vec) tb="$tb elf-m10300.lo elf32.lo $elf" ;;
- moxie_elf32_be_vec) tb="$tb elf32-moxie.lo elf32.lo $elf" ;;
- moxie_elf32_le_vec) tb="$tb elf32-moxie.lo elf32.lo $elf" ;;
- msp430_elf32_vec) tb="$tb elf32-msp430.lo elf32.lo $elf" ;;
- msp430_elf32_ti_vec) tb="$tb elf32-msp430.lo elf32.lo $elf" ;;
- mt_elf32_vec) tb="$tb elf32-mt.lo elf32.lo $elf" ;;
- nds32_elf32_be_vec) tb="$tb elf32-nds32.lo elf32.lo $elf" ;;
- nds32_elf32_le_vec) tb="$tb elf32-nds32.lo elf32.lo $elf" ;;
- nds32_elf32_linux_be_vec) tb="$tb elf32-nds32.lo elf32.lo $elf" ;;
- nds32_elf32_linux_le_vec) tb="$tb elf32-nds32.lo elf32.lo $elf" ;;
- nfp_elf64_vec) tb="$tb elf64-nfp.lo elf64.lo $elf" ;;
- nios2_elf32_be_vec) tb="$tb elf32-nios2.lo elf32.lo $elf" ;;
- nios2_elf32_le_vec) tb="$tb elf32-nios2.lo elf32.lo $elf" ;;
- ns32k_aout_pc532mach_vec) tb="$tb pc532-mach.lo aout-ns32k.lo" ;;
- ns32k_aout_pc532nbsd_vec) tb="$tb ns32knetbsd.lo aout-ns32k.lo" ;;
- or1k_elf32_vec) tb="$tb elf32-or1k.lo elf32.lo $elf" ;;
- pdb_vec) tb="$tb pdb.lo" ;;
- pdp11_aout_vec) tb="$tb pdp11.lo" ;;
- pef_vec) tb="$tb pef.lo" ;;
- pef_xlib_vec) tb="$tb pef.lo" ;;
- pj_elf32_vec) tb="$tb elf32-pj.lo elf32.lo $elf" ;;
- pj_elf32_le_vec) tb="$tb elf32-pj.lo elf32.lo $elf" ;;
- powerpc_boot_vec) tb="$tb ppcboot.lo" ;;
- powerpc_elf32_vec) tb="$tb elf32-ppc.lo elf-vxworks.lo elf32.lo $elf" ;;
- powerpc_elf32_le_vec) tb="$tb elf32-ppc.lo elf-vxworks.lo elf32.lo $elf" ;;
- powerpc_elf32_fbsd_vec) tb="$tb elf32-ppc.lo elf-vxworks.lo elf32.lo $elf" ;;
- powerpc_elf32_vxworks_vec) tb="$tb elf32-ppc.lo elf-vxworks.lo elf32.lo $elf" ;;
- powerpc_elf64_vec) tb="$tb elf64-ppc.lo elf64-gen.lo elf64.lo $elf"; target_size=64 ;;
- powerpc_elf64_le_vec) tb="$tb elf64-ppc.lo elf64-gen.lo elf64.lo $elf" target_size=64 ;;
- powerpc_elf64_fbsd_vec) tb="$tb elf64-ppc.lo elf64-gen.lo elf64.lo $elf" target_size=64 ;;
- powerpc_elf64_fbsd_le_vec) tb="$tb elf64-ppc.lo elf64-gen.lo elf64.lo $elf" target_size=64 ;;
- powerpc_xcoff_vec) tb="$tb coff-rs6000.lo $xcoff" ;;
- pru_elf32_vec) tb="$tb elf32-pru.lo elf32.lo $elf" ;;
- riscv_elf32_vec) tb="$tb elf32-riscv.lo elfxx-riscv.lo elf-ifunc.lo elf32.lo $elf" ;;
- riscv_elf64_vec) tb="$tb elf64-riscv.lo elf64.lo elfxx-riscv.lo elf-ifunc.lo elf32.lo $elf"; target_size=64 ;;
- riscv_elf32_be_vec) tb="$tb elf32-riscv.lo elfxx-riscv.lo elf-ifunc.lo elf32.lo $elf" ;;
- riscv_elf64_be_vec) tb="$tb elf64-riscv.lo elf64.lo elfxx-riscv.lo elf-ifunc.lo elf32.lo $elf"; target_size=64 ;;
- riscv64_pei_vec) tb="$tb pei-riscv64.lo pe-riscv64igen.lo $coff"; target_size=64 ;;
- rl78_elf32_vec) tb="$tb elf32-rl78.lo elf32.lo $elf" ;;
- rs6000_xcoff64_vec) tb="$tb coff64-rs6000.lo aix5ppc-core.lo $xcoff"; target_size=64 ;;
- rs6000_xcoff64_aix_vec) tb="$tb coff64-rs6000.lo aix5ppc-core.lo $xcoff"; target_size=64 ;;
- rs6000_xcoff_vec) tb="$tb coff-rs6000.lo $xcoff" ;;
- rx_elf32_be_vec) tb="$tb elf32-rx.lo elf32.lo $elf" ;;
- rx_elf32_be_ns_vec) tb="$tb elf32-rx.lo elf32.lo $elf" ;;
- rx_elf32_le_vec) tb="$tb elf32-rx.lo elf32.lo $elf" ;;
- rx_elf32_linux_le_vec) tb="$tb elf32-rx.lo elf32.lo $elf" ;;
- s390_elf32_vec) tb="$tb elf32-s390.lo elf32.lo $elf" ;;
- s390_elf64_vec) tb="$tb elf64-s390.lo elf64.lo $elf"; target_size=64 ;;
- score_elf32_be_vec) tb="$tb elf32-score.lo elf32-score7.lo elf32.lo elf64.lo $elf"; want64=true; target_size=64 ;;
- score_elf32_le_vec) tb="$tb elf32-score.lo elf32-score7.lo elf32.lo elf64.lo $elf"; want64=true; target_size=64 ;;
- sh_coff_vec) tb="$tb coff-sh.lo $coff" ;;
- sh_coff_le_vec) tb="$tb coff-sh.lo $coff" ;;
- sh_coff_small_vec) tb="$tb coff-sh.lo $coff" ;;
- sh_coff_small_le_vec) tb="$tb coff-sh.lo $coff" ;;
- sh_elf32_vec) tb="$tb elf32-sh.lo elf-vxworks.lo elf32.lo $elf coff-sh.lo $coff" ;;
- sh_elf32_le_vec) tb="$tb elf32-sh.lo elf-vxworks.lo elf32.lo $elf coff-sh.lo $coff" ;;
- sh_elf32_fdpic_be_vec) tb="$tb elf32-sh.lo elf-vxworks.lo elf32.lo $elf coff-sh.lo $coff" ;;
- sh_elf32_fdpic_le_vec) tb="$tb elf32-sh.lo elf-vxworks.lo elf32.lo $elf coff-sh.lo $coff" ;;
- sh_elf32_linux_vec) tb="$tb elf32-sh.lo elf-vxworks.lo elf32.lo $elf coff-sh.lo $coff" ;;
- sh_elf32_linux_be_vec) tb="$tb elf32-sh.lo elf-vxworks.lo elf32.lo $elf coff-sh.lo $coff" ;;
- sh_elf32_nbsd_vec) tb="$tb elf32-sh.lo elf-vxworks.lo elf32.lo $elf coff-sh.lo $coff" ;;
- sh_elf32_nbsd_le_vec) tb="$tb elf32-sh.lo elf-vxworks.lo elf32.lo $elf coff-sh.lo $coff" ;;
- sh_elf32_vxworks_vec) tb="$tb elf32-sh.lo elf-vxworks.lo elf32.lo $elf coff-sh.lo $coff" ;;
- sh_elf32_vxworks_le_vec) tb="$tb elf32-sh.lo elf-vxworks.lo elf32.lo $elf coff-sh.lo $coff" ;;
- sh_pe_le_vec) tb="$tb pe-sh.lo coff-sh.lo peigen.lo $coff" ;;
- sh_pei_le_vec) tb="$tb pei-sh.lo coff-sh.lo peigen.lo $coff" ;;
- sparc_elf32_vec) tb="$tb elf32-sparc.lo elfxx-sparc.lo elf-vxworks.lo elf32.lo $elf" ;;
- sparc_elf32_sol2_vec) tb="$tb elf32-sparc.lo elfxx-sparc.lo elf-vxworks.lo elf32.lo $elf" ;;
- sparc_elf32_vxworks_vec) tb="$tb elf32-sparc.lo elfxx-sparc.lo elf-vxworks.lo elf32.lo $elf" ;;
- sparc_elf64_vec) tb="$tb elf64-sparc.lo elfxx-sparc.lo elf-vxworks.lo elf64.lo $elf"; target_size=64 ;;
- sparc_elf64_fbsd_vec) tb="$tb elf64-sparc.lo elfxx-sparc.lo elf-vxworks.lo elf64.lo $elf"; target_size=64 ;;
- sparc_elf64_sol2_vec) tb="$tb elf64-sparc.lo elfxx-sparc.lo elf-vxworks.lo elf64.lo $elf"; target_size=64 ;;
- spu_elf32_vec) tb="$tb elf32-spu.lo elf32.lo $elf" ;;
- sym_vec) tb="$tb xsym.lo" ;;
- tic30_coff_vec) tb="$tb coff-tic30.lo $coffgen" ;;
- tic4x_coff0_vec) tb="$tb coff-tic4x.lo $coffgen" ;;
- tic4x_coff0_beh_vec) tb="$tb coff-tic4x.lo $coffgen" ;;
- tic4x_coff1_vec) tb="$tb coff-tic4x.lo $coffgen" ;;
- tic4x_coff1_beh_vec) tb="$tb coff-tic4x.lo $coffgen" ;;
- tic4x_coff2_vec) tb="$tb coff-tic4x.lo $coffgen" ;;
- tic4x_coff2_beh_vec) tb="$tb coff-tic4x.lo $coffgen" ;;
- tic54x_coff0_vec) tb="$tb coff-tic54x.lo $coffgen" ;;
- tic54x_coff0_beh_vec) tb="$tb coff-tic54x.lo $coffgen" ;;
- tic54x_coff1_vec) tb="$tb coff-tic54x.lo $coffgen" ;;
- tic54x_coff1_beh_vec) tb="$tb coff-tic54x.lo $coffgen" ;;
- tic54x_coff2_vec) tb="$tb coff-tic54x.lo $coffgen" ;;
- tic54x_coff2_beh_vec) tb="$tb coff-tic54x.lo $coffgen" ;;
- tic6x_elf32_be_vec) tb="$tb elf32-tic6x.lo elf32.lo $elf" ;;
- tic6x_elf32_le_vec) tb="$tb elf32-tic6x.lo elf32.lo $elf" ;;
- tic6x_elf32_c6000_be_vec) tb="$tb elf32-tic6x.lo elf32.lo $elf" ;;
- tic6x_elf32_c6000_le_vec) tb="$tb elf32-tic6x.lo elf32.lo $elf" ;;
- tic6x_elf32_linux_be_vec) tb="$tb elf32-tic6x.lo elf32.lo $elf" ;;
- tic6x_elf32_linux_le_vec) tb="$tb elf32-tic6x.lo elf32.lo $elf" ;;
- tilegx_elf32_be_vec) tb="$tb elf32-tilegx.lo elfxx-tilegx.lo elf32.lo $elf" ; target_size=32 ;;
- tilegx_elf32_le_vec) tb="$tb elf32-tilegx.lo elfxx-tilegx.lo elf32.lo $elf" ; target_size=32 ;;
- tilegx_elf64_be_vec) tb="$tb elf64-tilegx.lo elfxx-tilegx.lo elf64.lo $elf" ; target_size=64 ;;
- tilegx_elf64_le_vec) tb="$tb elf64-tilegx.lo elfxx-tilegx.lo elf64.lo $elf" ; target_size=64 ;;
- tilepro_elf32_vec) tb="$tb elf32-tilepro.lo elf32.lo $elf" ;;
- v800_elf32_vec) tb="$tb elf32-v850.lo elf32.lo $elf" ;;
- v850_elf32_vec) tb="$tb elf32-v850.lo elf32.lo $elf" ;;
- vax_aout_1knbsd_vec) tb="$tb vax1knetbsd.lo aout32.lo" ;;
- vax_aout_nbsd_vec) tb="$tb vaxnetbsd.lo aout32.lo" ;;
- vax_elf32_vec) tb="$tb elf32-vax.lo elf32.lo $elf" ;;
- ft32_elf32_vec) tb="$tb elf32-ft32.lo elf32.lo $elf" ;;
- visium_elf32_vec) tb="$tb elf32-visium.lo elf32.lo $elf" ;;
- wasm_vec) tb="$tb wasm-module.lo" ;;
- wasm32_elf32_vec) tb="$tb elf32-wasm32.lo elf32.lo $elf" ;;
- x86_64_coff_vec) tb="$tb coff-x86_64.lo $coff"; target_size=64 ;;
- x86_64_elf32_vec) tb="$tb elf64-x86-64.lo $elfxx_x86 elf64.lo elf32.lo $elf"; target_size=64 ;;
- x86_64_elf64_vec) tb="$tb elf64-x86-64.lo $elfxx_x86 elf64.lo $elf"; target_size=64 ;;
- x86_64_elf64_cloudabi_vec) tb="$tb elf64-x86-64.lo $elfxx_x86 elf64.lo $elf"; target_size=64 ;;
- x86_64_elf64_fbsd_vec) tb="$tb elf64-x86-64.lo $elfxx_x86 elf64.lo $elf"; target_size=64 ;;
- x86_64_elf64_sol2_vec) tb="$tb elf64-x86-64.lo $elfxx_x86 elf64.lo $elf"; target_size=64 ;;
- x86_64_mach_o_vec) tb="$tb mach-o-x86-64.lo" ;;
- x86_64_pe_vec) tb="$tb pe-x86_64.lo pex64igen.lo $coff"; target_size=64 ;;
- x86_64_pe_big_vec) tb="$tb pe-x86_64.lo pex64igen.lo $coff"; target_size=64 ;;
- x86_64_pei_vec) tb="$tb pei-x86_64.lo pex64igen.lo $coff"; target_size=64 ;;
- xgate_elf32_vec) tb="$tb elf32-xgate.lo elf32.lo $elf" ;;
- xstormy16_elf32_vec) tb="$tb elf32-xstormy16.lo elf32.lo $elf" ;;
- xtensa_elf32_be_vec) tb="$tb xtensa-dynconfig.lo xtensa-isa.lo xtensa-modules.lo elf32-xtensa.lo elf32.lo $elf" ;;
- xtensa_elf32_le_vec) tb="$tb xtensa-dynconfig.lo xtensa-isa.lo xtensa-modules.lo elf32-xtensa.lo elf32.lo $elf" ;;
- z80_coff_vec) tb="$tb coff-z80.lo reloc16.lo $coffgen" ;;
- z80_elf32_vec) tb="$tb elf32-z80.lo elf32.lo $elf" ;;
- z8k_coff_vec) tb="$tb coff-z8k.lo reloc16.lo $coff" ;;
-
- # These appear out of order in targets.c
- srec_vec) tb="$tb srec.lo" ;;
- symbolsrec_vec) tb="$tb srec.lo" ;;
- tekhex_vec) tb="$tb tekhex.lo" ;;
- core_cisco_be_vec) tb="$tb cisco-core.lo" ;;
- core_cisco_le_vec) tb="$tb cisco-core.lo" ;;
-
- "") ;;
- *) as_fn_error $? "*** unknown target vector $vec" "$LINENO" 5 ;;
- esac
-
- if test ${target_size} = 64; then
- target64=true
- fi
- if test x"${vec}" = x"${defvec}"; then
- bfd_default_target_size=${target_size}
- fi
-done
-
-if test "$plugins" = "yes"; then
- tb="$tb plugin.lo"
-fi
-
-# Target architecture .o files.
-# A couple of CPUs use shorter file names to avoid problems on DOS
-# filesystems.
-ta=`echo $selarchs | sed -e s/bfd_/cpu-/g -e s/_arch/.lo/g -e s/mn10200/m10200/ -e s/mn10300/m10300/`
-
-# Weed out duplicate .o files.
-f=""
-for i in $tb ; do
- case " $f " in
- *" $i "*) ;;
- *) f="$f $i" ;;
- esac
-done
-tb="$f"
-
-f=""
-for i in $ta ; do
- case " $f " in
- *" $i "*) ;;
- *) f="$f $i" ;;
- esac
-done
-ta="$f"
-
-bfd_backends="$tb"
-bfd_machines="$ta"
-
-if test x${all_targets} = xtrue ; then
- bfd_backends="${bfd_backends}"' $(ALL_BACKENDS)'
- bfd_machines="${bfd_machines}"' $(ALL_MACHINES)'
- selvecs=
- havevecs=-DHAVE_all_vecs
- selarchs=
- test -n "$assocvecs" &&
- assocvecs=`echo $assocvecs | sed -e 's/^/\&/' -e 's/ \(.\)/,\&\1/g'`
-else # all_targets is true
- # Only set these if they will be nonempty, for the clever echo.
- havevecs=
- assocvecs=
- test -n "$selvecs" &&
- havevecs=`echo $selvecs | sed -e 's/^/-DHAVE_/' -e 's/ \(.\)/ -DHAVE_\1/g'`
- test -n "$selvecs" &&
- selvecs=`echo $selvecs | sed -e 's/^/\&/' -e 's/ \(.\)/,\&\1/g'`
- test -n "$selarchs" &&
- selarchs=`echo $selarchs | sed -e 's/^/\&/' -e 's/ \(.\)/,\&\1/g'`
-fi # all_targets is true
-
-# 64-bit archives need a 64-bit bfd_vma.
-if test "x$want_64_bit_archive" = xtrue; then
- want64=true
-
-$as_echo "#define USE_64_BIT_ARCHIVE 1" >>confdefs.h
-
-fi
-
-case ${host64}-${target64}-${want64} in
- *true*)
- wordsize=64
- bfd64_libs='$(BFD64_LIBS)'
- all_backends='$(BFD64_BACKENDS) $(BFD32_BACKENDS)'
- if test -n "$GCC" ; then
- bad_64bit_gcc=no;
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gcc version with buggy 64-bit support" >&5
-$as_echo_n "checking for gcc version with buggy 64-bit support... " >&6; }
- # Add more tests for gcc versions with non-working 64-bit support here.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-:__GNUC__:__GNUC_MINOR__:__i386__:
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP ": 2 : 91 : 1 :" >/dev/null 2>&1; then :
- bad_64bit_gcc=yes;
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes: egcs-1.1.2 on ix86 spotted" >&5
-$as_echo "yes: egcs-1.1.2 on ix86 spotted" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-rm -f conftest*
-
- if test $bad_64bit_gcc = yes ; then
- as_fn_error $? "A newer version of gcc is needed for the requested 64-bit BFD configuration" "$LINENO" 5
- fi
- fi
- ;;
- false-false-false)
- wordsize=32
- all_backends='$(BFD32_BACKENDS)'
- ;;
-esac
-
-tdefaults=""
-test -n "${defvec}" && tdefaults="${tdefaults} -DDEFAULT_VECTOR=${defvec}"
-test -n "${selvecs}" && tdefaults="${tdefaults} -DSELECT_VECS='${selvecs}'"
-test -n "${assocvecs}" && tdefaults="${tdefaults} -DASSOCIATED_VECS='${assocvecs}'"
-test -n "${selarchs}" && tdefaults="${tdefaults} -DSELECT_ARCHITECTURES='${selarchs}'"
-
-
-
-
-
-
-
-
-
-
-# If we are configured native, pick a core file support file.
-COREFILE=
-COREFLAG=
-CORE_HEADER=
-TRAD_HEADER=
-if test "${target}" = "${host}"; then
- case "${host}" in
- alpha*-*-freebsd* | alpha*-*-kfreebsd*-gnu | alpha*-*-*vms*)
- COREFILE=''
- ;;
- alpha*-*-linux-*)
- COREFILE=trad-core.lo
- TRAD_HEADER='"hosts/alphalinux.h"'
- ;;
- alpha*-*-netbsd* | alpha*-*-openbsd*)
- COREFILE=netbsd-core.lo
- ;;
- alpha*-*-*)
- COREFILE=osf-core.lo
- ;;
- arm-*-freebsd* | arm-*-kfreebsd*-gnu)
- COREFILE='' ;;
- arm*-*-netbsd* | arm-*-openbsd*)
- COREFILE=netbsd-core.lo
- ;;
- hppa*-*-hpux*) COREFILE=hpux-core.lo ;;
- hppa*-*-hiux*) COREFILE=hpux-core.lo ;;
- hppa*-*-mpeix*) COREFILE=hpux-core.lo ;;
- hppa*-*-bsd*) COREFILE="hpux-core.lo hppabsd-core.lo"
- COREFLAG="-DHPUX_CORE -DHPPABSD_CORE" ;;
- hppa*-*-netbsd* | hppa*-*-openbsd*)
- COREFILE=netbsd-core.lo
- ;;
-
- i[3-7]86-*-bsdi)
- COREFILE=
- ;;
- i[3-7]86-*-bsd* | i[3-7]86-*-freebsd[123] | i[3-7]86-*-freebsd[123]\.* | i[3-7]86-*-freebsd4\.[01234] | i[3-7]86-*-freebsd4\.[01234]\.*)
- COREFILE=trad-core.lo
- TRAD_HEADER='"hosts/i386bsd.h"'
- ;;
- i[3-7]86-*-freebsd* | i[3-7]86-*-kfreebsd*-gnu | i[3-7]86-*-dragonfly*)
- COREFILE=''
- TRAD_HEADER='"hosts/i386bsd.h"'
- ;;
- i[3-7]86-*-netbsd* | i[3-7]86-*-knetbsd*-gnu | i[3-7]86-*-openbsd*)
- COREFILE=netbsd-core.lo
- ;;
- i[3-7]86-esix-sysv3*)
- COREFILE=trad-core.lo
- TRAD_HEADER='"hosts/esix.h"'
- ;;
- i[3-7]86-*-mach3*)
- COREFILE=trad-core.lo
- TRAD_HEADER='"hosts/i386mach3.h"'
- ;;
- i[3-7]86-*-linux-*)
- COREFILE=trad-core.lo
- TRAD_HEADER='"hosts/i386linux.h"'
- case "$enable_targets"-"$want64" in
- *x86_64-*linux*|*-true)
- CORE_HEADER='"hosts/x86-64linux.h"'
- esac
- ;;
- mips*-*-netbsd* | mips*-*-openbsd*)
- COREFILE=netbsd-core.lo
- ;;
- mips-*-irix*)
- COREFILE=irix-core.lo
- ;;
- m68*-*-linux-*)
- COREFILE=trad-core.lo
- TRAD_HEADER='"hosts/m68klinux.h"'
- ;;
- m68*-*-netbsd*)
- COREFILE=netbsd-core.lo
- ;;
- ns32k-pc532-mach)
- COREFILE=trad-core.lo
- TRAD_HEADER='"hosts/pc532mach.h"'
- ;;
- ns32k-*-netbsd* | ns32k-*-openbsd*)
- COREFILE=netbsd-core.lo
- ;;
- rs6000-*-lynx*)
- COREFILE=lynx-core.lo
- ;;
- rs6000-*-aix[5-9].* | powerpc-*-aix[5-9].* | powerpc64-*-aix[5-9].*)
- COREFILE=rs6000-core.lo
- COREFLAG="$COREFLAG -DAIX_5_CORE -DAIX_CORE_DUMPX_CORE"
- ;;
- rs6000-*-aix4.[3-9]* | powerpc-*-aix4.[3-9]*)
- COREFILE=rs6000-core.lo
- COREFLAG="$COREFLAG -DAIX_CORE_DUMPX_CORE"
- # Not all versions of AIX with -DAIX_CORE_DUMPX_CORE
- # have c_impl as a member of struct core_dumpx
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for c_impl in struct core_dumpx" >&5
-$as_echo_n "checking for c_impl in struct core_dumpx... " >&6; }
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <core.h>
-int
-main ()
-{
-struct core_dumpx c; c.c_impl = 0;
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
-
-$as_echo "#define HAVE_ST_C_IMPL 1" >>confdefs.h
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- ;;
- rs6000-*-aix4*) COREFILE=rs6000-core.lo ;;
- rs6000-*-*) COREFILE=rs6000-core.lo ;;
- powerpc64-*-aix*) COREFILE=rs6000-core.lo ;;
- powerpc-*-aix4*) COREFILE=rs6000-core.lo ;;
- powerpc-*-aix*) COREFILE=rs6000-core.lo ;;
- powerpc-*-beos*) ;;
- powerpc-*-freebsd* | powerpc-*-kfreebsd*-gnu)
- COREFILE='' ;;
- powerpc-*-netbsd*) COREFILE=netbsd-core.lo ;;
- powerpc-*-*bsd*) COREFILE=netbsd-core.lo ;;
- s390*-*-*) COREFILE=trad-core.lo ;;
- sh*-*-netbsd* | sh*-*-openbsd*)
- COREFILE=netbsd-core.lo
- ;;
- sparc-*-netbsd* | sparc*-*-openbsd*)
- COREFILE=netbsd-core.lo
- ;;
- vax-*-netbsd* | vax-*-openbsd*)
- COREFILE=netbsd-core.lo
- ;;
- vax-*-linux-*)
- COREFILE=trad-core.lo
- TRAD_HEADER='"hosts/vaxlinux.h"'
- ;;
- vax-*-*)
- COREFILE=trad-core.lo
- TRAD_HEADER='"hosts/vaxbsd.h"'
- ;;
- x86_64-*-linux*)
- CORE_HEADER='"hosts/x86-64linux.h"'
- ;;
- x86_64-*-netbsd* | x86_64-*-openbsd*)
- COREFILE=netbsd-core.lo
- ;;
- esac
-
- case "$COREFILE" in
- hppabsd-core.lo) COREFLAG=-DHPPABSD_CORE ;;
- hpux-core.lo) COREFLAG=-DHPUX_CORE ;;
- irix-core.lo) COREFLAG=-DIRIX_CORE ;;
- lynx-core.lo) COREFLAG=-DLYNX_CORE ;;
- netbsd-core.lo) COREFLAG=-DNETBSD_CORE ;;
- osf-core.lo) COREFLAG=-DOSF_CORE ;;
- ptrace-core.lo) COREFLAG=-DPTRACE_CORE ;;
- rs6000-core.lo) COREFLAG="$COREFLAG -DAIX_CORE" ;;
- trad-core.lo) COREFLAG="$COREFLAG -DTRAD_CORE" ;;
- esac
-
- # ELF corefile support has several flavors, but all of
- # them use something called <sys/procfs.h>
-
-$as_echo "#define _STRUCTURED_PROC 1" >>confdefs.h
-
- for ac_header in sys/procfs.h
-do :
- ac_fn_c_check_header_mongrel "$LINENO" "sys/procfs.h" "ac_cv_header_sys_procfs_h" "$ac_includes_default"
-if test "x$ac_cv_header_sys_procfs_h" = xyes; then :
- cat >>confdefs.h <<_ACEOF
-#define HAVE_SYS_PROCFS_H 1
-_ACEOF
-
-fi
-
-done
-
- if test "$ac_cv_header_sys_procfs_h" = yes; then
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prstatus_t in sys/procfs.h" >&5
-$as_echo_n "checking for prstatus_t in sys/procfs.h... " >&6; }
- if ${bfd_cv_have_sys_procfs_type_prstatus_t+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#define _SYSCALL32
-#include <sys/procfs.h>
-int
-main ()
-{
-prstatus_t avar
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- bfd_cv_have_sys_procfs_type_prstatus_t=yes
-else
- bfd_cv_have_sys_procfs_type_prstatus_t=no
-
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-
- if test $bfd_cv_have_sys_procfs_type_prstatus_t = yes; then
-
-$as_echo "#define HAVE_PRSTATUS_T 1" >>confdefs.h
-
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_prstatus_t" >&5
-$as_echo "$bfd_cv_have_sys_procfs_type_prstatus_t" >&6; }
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prstatus32_t in sys/procfs.h" >&5
-$as_echo_n "checking for prstatus32_t in sys/procfs.h... " >&6; }
- if ${bfd_cv_have_sys_procfs_type_prstatus32_t+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#define _SYSCALL32
-#include <sys/procfs.h>
-int
-main ()
-{
-prstatus32_t avar
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- bfd_cv_have_sys_procfs_type_prstatus32_t=yes
-else
- bfd_cv_have_sys_procfs_type_prstatus32_t=no
-
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-
- if test $bfd_cv_have_sys_procfs_type_prstatus32_t = yes; then
-
-$as_echo "#define HAVE_PRSTATUS32_T 1" >>confdefs.h
-
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_prstatus32_t" >&5
-$as_echo "$bfd_cv_have_sys_procfs_type_prstatus32_t" >&6; }
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prstatus_t.pr_who in sys/procfs.h" >&5
-$as_echo_n "checking for prstatus_t.pr_who in sys/procfs.h... " >&6; }
- if ${bfd_cv_have_sys_procfs_type_member_prstatus_t_pr_who+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#define _SYSCALL32
-#include <sys/procfs.h>
-int
-main ()
-{
-prstatus_t avar; void* aref = (void*) &avar.pr_who
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- bfd_cv_have_sys_procfs_type_member_prstatus_t_pr_who=yes
-else
- bfd_cv_have_sys_procfs_type_member_prstatus_t_pr_who=no
-
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-
- if test $bfd_cv_have_sys_procfs_type_member_prstatus_t_pr_who = yes; then
-
-$as_echo "#define HAVE_PRSTATUS_T_PR_WHO 1" >>confdefs.h
-
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_member_prstatus_t_pr_who" >&5
-$as_echo "$bfd_cv_have_sys_procfs_type_member_prstatus_t_pr_who" >&6; }
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prstatus32_t.pr_who in sys/procfs.h" >&5
-$as_echo_n "checking for prstatus32_t.pr_who in sys/procfs.h... " >&6; }
- if ${bfd_cv_have_sys_procfs_type_member_prstatus32_t_pr_who+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#define _SYSCALL32
-#include <sys/procfs.h>
-int
-main ()
-{
-prstatus32_t avar; void* aref = (void*) &avar.pr_who
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- bfd_cv_have_sys_procfs_type_member_prstatus32_t_pr_who=yes
-else
- bfd_cv_have_sys_procfs_type_member_prstatus32_t_pr_who=no
-
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-
- if test $bfd_cv_have_sys_procfs_type_member_prstatus32_t_pr_who = yes; then
-
-$as_echo "#define HAVE_PRSTATUS32_T_PR_WHO 1" >>confdefs.h
-
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_member_prstatus32_t_pr_who" >&5
-$as_echo "$bfd_cv_have_sys_procfs_type_member_prstatus32_t_pr_who" >&6; }
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pstatus_t in sys/procfs.h" >&5
-$as_echo_n "checking for pstatus_t in sys/procfs.h... " >&6; }
- if ${bfd_cv_have_sys_procfs_type_pstatus_t+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#define _SYSCALL32
-#include <sys/procfs.h>
-int
-main ()
-{
-pstatus_t avar
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- bfd_cv_have_sys_procfs_type_pstatus_t=yes
-else
- bfd_cv_have_sys_procfs_type_pstatus_t=no
-
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-
- if test $bfd_cv_have_sys_procfs_type_pstatus_t = yes; then
-
-$as_echo "#define HAVE_PSTATUS_T 1" >>confdefs.h
-
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_pstatus_t" >&5
-$as_echo "$bfd_cv_have_sys_procfs_type_pstatus_t" >&6; }
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pxstatus_t in sys/procfs.h" >&5
-$as_echo_n "checking for pxstatus_t in sys/procfs.h... " >&6; }
- if ${bfd_cv_have_sys_procfs_type_pxstatus_t+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#define _SYSCALL32
-#include <sys/procfs.h>
-int
-main ()
-{
-pxstatus_t avar
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- bfd_cv_have_sys_procfs_type_pxstatus_t=yes
-else
- bfd_cv_have_sys_procfs_type_pxstatus_t=no
-
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-
- if test $bfd_cv_have_sys_procfs_type_pxstatus_t = yes; then
-
-$as_echo "#define HAVE_PXSTATUS_T 1" >>confdefs.h
-
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_pxstatus_t" >&5
-$as_echo "$bfd_cv_have_sys_procfs_type_pxstatus_t" >&6; }
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pstatus32_t in sys/procfs.h" >&5
-$as_echo_n "checking for pstatus32_t in sys/procfs.h... " >&6; }
- if ${bfd_cv_have_sys_procfs_type_pstatus32_t+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#define _SYSCALL32
-#include <sys/procfs.h>
-int
-main ()
-{
-pstatus32_t avar
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- bfd_cv_have_sys_procfs_type_pstatus32_t=yes
-else
- bfd_cv_have_sys_procfs_type_pstatus32_t=no
-
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-
- if test $bfd_cv_have_sys_procfs_type_pstatus32_t = yes; then
-
-$as_echo "#define HAVE_PSTATUS32_T 1" >>confdefs.h
-
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_pstatus32_t" >&5
-$as_echo "$bfd_cv_have_sys_procfs_type_pstatus32_t" >&6; }
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prpsinfo_t in sys/procfs.h" >&5
-$as_echo_n "checking for prpsinfo_t in sys/procfs.h... " >&6; }
- if ${bfd_cv_have_sys_procfs_type_prpsinfo_t+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#define _SYSCALL32
-#include <sys/procfs.h>
-int
-main ()
-{
-prpsinfo_t avar
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- bfd_cv_have_sys_procfs_type_prpsinfo_t=yes
-else
- bfd_cv_have_sys_procfs_type_prpsinfo_t=no
-
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-
- if test $bfd_cv_have_sys_procfs_type_prpsinfo_t = yes; then
-
-$as_echo "#define HAVE_PRPSINFO_T 1" >>confdefs.h
-
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_prpsinfo_t" >&5
-$as_echo "$bfd_cv_have_sys_procfs_type_prpsinfo_t" >&6; }
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prpsinfo_t.pr_pid in sys/procfs.h" >&5
-$as_echo_n "checking for prpsinfo_t.pr_pid in sys/procfs.h... " >&6; }
- if ${bfd_cv_have_sys_procfs_type_member_prpsinfo_t_pr_pid+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#define _SYSCALL32
-#include <sys/procfs.h>
-int
-main ()
-{
-prpsinfo_t avar; void* aref = (void*) &avar.pr_pid
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- bfd_cv_have_sys_procfs_type_member_prpsinfo_t_pr_pid=yes
-else
- bfd_cv_have_sys_procfs_type_member_prpsinfo_t_pr_pid=no
-
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-
- if test $bfd_cv_have_sys_procfs_type_member_prpsinfo_t_pr_pid = yes; then
-
-$as_echo "#define HAVE_PRPSINFO_T_PR_PID 1" >>confdefs.h
-
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_member_prpsinfo_t_pr_pid" >&5
-$as_echo "$bfd_cv_have_sys_procfs_type_member_prpsinfo_t_pr_pid" >&6; }
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prpsinfo32_t in sys/procfs.h" >&5
-$as_echo_n "checking for prpsinfo32_t in sys/procfs.h... " >&6; }
- if ${bfd_cv_have_sys_procfs_type_prpsinfo32_t+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#define _SYSCALL32
-#include <sys/procfs.h>
-int
-main ()
-{
-prpsinfo32_t avar
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- bfd_cv_have_sys_procfs_type_prpsinfo32_t=yes
-else
- bfd_cv_have_sys_procfs_type_prpsinfo32_t=no
-
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-
- if test $bfd_cv_have_sys_procfs_type_prpsinfo32_t = yes; then
-
-$as_echo "#define HAVE_PRPSINFO32_T 1" >>confdefs.h
-
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_prpsinfo32_t" >&5
-$as_echo "$bfd_cv_have_sys_procfs_type_prpsinfo32_t" >&6; }
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for prpsinfo32_t.pr_pid in sys/procfs.h" >&5
-$as_echo_n "checking for prpsinfo32_t.pr_pid in sys/procfs.h... " >&6; }
- if ${bfd_cv_have_sys_procfs_type_member_prpsinfo32_t_pr_pid+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#define _SYSCALL32
-#include <sys/procfs.h>
-int
-main ()
-{
-prpsinfo32_t avar; void* aref = (void*) &avar.pr_pid
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- bfd_cv_have_sys_procfs_type_member_prpsinfo32_t_pr_pid=yes
-else
- bfd_cv_have_sys_procfs_type_member_prpsinfo32_t_pr_pid=no
-
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-
- if test $bfd_cv_have_sys_procfs_type_member_prpsinfo32_t_pr_pid = yes; then
-
-$as_echo "#define HAVE_PRPSINFO32_T_PR_PID 1" >>confdefs.h
-
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_member_prpsinfo32_t_pr_pid" >&5
-$as_echo "$bfd_cv_have_sys_procfs_type_member_prpsinfo32_t_pr_pid" >&6; }
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for psinfo_t in sys/procfs.h" >&5
-$as_echo_n "checking for psinfo_t in sys/procfs.h... " >&6; }
- if ${bfd_cv_have_sys_procfs_type_psinfo_t+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#define _SYSCALL32
-#include <sys/procfs.h>
-int
-main ()
-{
-psinfo_t avar
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- bfd_cv_have_sys_procfs_type_psinfo_t=yes
-else
- bfd_cv_have_sys_procfs_type_psinfo_t=no
-
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-
- if test $bfd_cv_have_sys_procfs_type_psinfo_t = yes; then
-
-$as_echo "#define HAVE_PSINFO_T 1" >>confdefs.h
-
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_psinfo_t" >&5
-$as_echo "$bfd_cv_have_sys_procfs_type_psinfo_t" >&6; }
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for psinfo_t.pr_pid in sys/procfs.h" >&5
-$as_echo_n "checking for psinfo_t.pr_pid in sys/procfs.h... " >&6; }
- if ${bfd_cv_have_sys_procfs_type_member_psinfo_t_pr_pid+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#define _SYSCALL32
-#include <sys/procfs.h>
-int
-main ()
-{
-psinfo_t avar; void* aref = (void*) &avar.pr_pid
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- bfd_cv_have_sys_procfs_type_member_psinfo_t_pr_pid=yes
-else
- bfd_cv_have_sys_procfs_type_member_psinfo_t_pr_pid=no
-
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-
- if test $bfd_cv_have_sys_procfs_type_member_psinfo_t_pr_pid = yes; then
-
-$as_echo "#define HAVE_PSINFO_T_PR_PID 1" >>confdefs.h
-
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_member_psinfo_t_pr_pid" >&5
-$as_echo "$bfd_cv_have_sys_procfs_type_member_psinfo_t_pr_pid" >&6; }
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for psinfo32_t in sys/procfs.h" >&5
-$as_echo_n "checking for psinfo32_t in sys/procfs.h... " >&6; }
- if ${bfd_cv_have_sys_procfs_type_psinfo32_t+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#define _SYSCALL32
-#include <sys/procfs.h>
-int
-main ()
-{
-psinfo32_t avar
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- bfd_cv_have_sys_procfs_type_psinfo32_t=yes
-else
- bfd_cv_have_sys_procfs_type_psinfo32_t=no
-
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-
- if test $bfd_cv_have_sys_procfs_type_psinfo32_t = yes; then
-
-$as_echo "#define HAVE_PSINFO32_T 1" >>confdefs.h
-
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_psinfo32_t" >&5
-$as_echo "$bfd_cv_have_sys_procfs_type_psinfo32_t" >&6; }
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for psinfo32_t.pr_pid in sys/procfs.h" >&5
-$as_echo_n "checking for psinfo32_t.pr_pid in sys/procfs.h... " >&6; }
- if ${bfd_cv_have_sys_procfs_type_member_psinfo32_t_pr_pid+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#define _SYSCALL32
-#include <sys/procfs.h>
-int
-main ()
-{
-psinfo32_t avar; void* aref = (void*) &avar.pr_pid
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- bfd_cv_have_sys_procfs_type_member_psinfo32_t_pr_pid=yes
-else
- bfd_cv_have_sys_procfs_type_member_psinfo32_t_pr_pid=no
-
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-
- if test $bfd_cv_have_sys_procfs_type_member_psinfo32_t_pr_pid = yes; then
-
-$as_echo "#define HAVE_PSINFO32_T_PR_PID 1" >>confdefs.h
-
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_member_psinfo32_t_pr_pid" >&5
-$as_echo "$bfd_cv_have_sys_procfs_type_member_psinfo32_t_pr_pid" >&6; }
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lwpstatus_t in sys/procfs.h" >&5
-$as_echo_n "checking for lwpstatus_t in sys/procfs.h... " >&6; }
- if ${bfd_cv_have_sys_procfs_type_lwpstatus_t+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#define _SYSCALL32
-#include <sys/procfs.h>
-int
-main ()
-{
-lwpstatus_t avar
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- bfd_cv_have_sys_procfs_type_lwpstatus_t=yes
-else
- bfd_cv_have_sys_procfs_type_lwpstatus_t=no
-
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-
- if test $bfd_cv_have_sys_procfs_type_lwpstatus_t = yes; then
-
-$as_echo "#define HAVE_LWPSTATUS_T 1" >>confdefs.h
-
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_lwpstatus_t" >&5
-$as_echo "$bfd_cv_have_sys_procfs_type_lwpstatus_t" >&6; }
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lwpxstatus_t in sys/procfs.h" >&5
-$as_echo_n "checking for lwpxstatus_t in sys/procfs.h... " >&6; }
- if ${bfd_cv_have_sys_procfs_type_lwpxstatus_t+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#define _SYSCALL32
-#include <sys/procfs.h>
-int
-main ()
-{
-lwpxstatus_t avar
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- bfd_cv_have_sys_procfs_type_lwpxstatus_t=yes
-else
- bfd_cv_have_sys_procfs_type_lwpxstatus_t=no
-
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-
- if test $bfd_cv_have_sys_procfs_type_lwpxstatus_t = yes; then
-
-$as_echo "#define HAVE_LWPXSTATUS_T 1" >>confdefs.h
-
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_lwpxstatus_t" >&5
-$as_echo "$bfd_cv_have_sys_procfs_type_lwpxstatus_t" >&6; }
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lwpstatus_t.pr_context in sys/procfs.h" >&5
-$as_echo_n "checking for lwpstatus_t.pr_context in sys/procfs.h... " >&6; }
- if ${bfd_cv_have_sys_procfs_type_member_lwpstatus_t_pr_context+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#define _SYSCALL32
-#include <sys/procfs.h>
-int
-main ()
-{
-lwpstatus_t avar; void* aref = (void*) &avar.pr_context
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- bfd_cv_have_sys_procfs_type_member_lwpstatus_t_pr_context=yes
-else
- bfd_cv_have_sys_procfs_type_member_lwpstatus_t_pr_context=no
-
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-
- if test $bfd_cv_have_sys_procfs_type_member_lwpstatus_t_pr_context = yes; then
-
-$as_echo "#define HAVE_LWPSTATUS_T_PR_CONTEXT 1" >>confdefs.h
-
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_member_lwpstatus_t_pr_context" >&5
-$as_echo "$bfd_cv_have_sys_procfs_type_member_lwpstatus_t_pr_context" >&6; }
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lwpstatus_t.pr_reg in sys/procfs.h" >&5
-$as_echo_n "checking for lwpstatus_t.pr_reg in sys/procfs.h... " >&6; }
- if ${bfd_cv_have_sys_procfs_type_member_lwpstatus_t_pr_reg+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#define _SYSCALL32
-#include <sys/procfs.h>
-int
-main ()
-{
-lwpstatus_t avar; void* aref = (void*) &avar.pr_reg
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- bfd_cv_have_sys_procfs_type_member_lwpstatus_t_pr_reg=yes
-else
- bfd_cv_have_sys_procfs_type_member_lwpstatus_t_pr_reg=no
-
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-
- if test $bfd_cv_have_sys_procfs_type_member_lwpstatus_t_pr_reg = yes; then
-
-$as_echo "#define HAVE_LWPSTATUS_T_PR_REG 1" >>confdefs.h
-
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_member_lwpstatus_t_pr_reg" >&5
-$as_echo "$bfd_cv_have_sys_procfs_type_member_lwpstatus_t_pr_reg" >&6; }
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lwpstatus_t.pr_fpreg in sys/procfs.h" >&5
-$as_echo_n "checking for lwpstatus_t.pr_fpreg in sys/procfs.h... " >&6; }
- if ${bfd_cv_have_sys_procfs_type_member_lwpstatus_t_pr_fpreg+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#define _SYSCALL32
-#include <sys/procfs.h>
-int
-main ()
-{
-lwpstatus_t avar; void* aref = (void*) &avar.pr_fpreg
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- bfd_cv_have_sys_procfs_type_member_lwpstatus_t_pr_fpreg=yes
-else
- bfd_cv_have_sys_procfs_type_member_lwpstatus_t_pr_fpreg=no
-
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-
- if test $bfd_cv_have_sys_procfs_type_member_lwpstatus_t_pr_fpreg = yes; then
-
-$as_echo "#define HAVE_LWPSTATUS_T_PR_FPREG 1" >>confdefs.h
-
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_member_lwpstatus_t_pr_fpreg" >&5
-$as_echo "$bfd_cv_have_sys_procfs_type_member_lwpstatus_t_pr_fpreg" >&6; }
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for win32_pstatus_t in sys/procfs.h" >&5
-$as_echo_n "checking for win32_pstatus_t in sys/procfs.h... " >&6; }
- if ${bfd_cv_have_sys_procfs_type_win32_pstatus_t+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#define _SYSCALL32
-#include <sys/procfs.h>
-int
-main ()
-{
-win32_pstatus_t avar
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- bfd_cv_have_sys_procfs_type_win32_pstatus_t=yes
-else
- bfd_cv_have_sys_procfs_type_win32_pstatus_t=no
-
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-
- if test $bfd_cv_have_sys_procfs_type_win32_pstatus_t = yes; then
-
-$as_echo "#define HAVE_WIN32_PSTATUS_T 1" >>confdefs.h
-
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_have_sys_procfs_type_win32_pstatus_t" >&5
-$as_echo "$bfd_cv_have_sys_procfs_type_win32_pstatus_t" >&6; }
-
- fi
-fi
-
-
-if test -n "$CORE_HEADER"; then
-
-cat >>confdefs.h <<_ACEOF
-#define CORE_HEADER $CORE_HEADER
-_ACEOF
-
-fi
-if test -n "$TRAD_HEADER"; then
-
-cat >>confdefs.h <<_ACEOF
-#define TRAD_HEADER $TRAD_HEADER
-_ACEOF
-
-fi
-
-if test "$plugins" = "yes"; then
- supports_plugins=1
-else
- supports_plugins=0
-fi
-
-
-
-# Determine the host dependent file_ptr a.k.a. off_t type. In order
-# prefer: off64_t - if ftello64 and fseeko64, off_t - if ftello and
-# fseeko, long. This assumes that sizeof off_t is .ge. sizeof long.
-# Hopefully a reasonable assumption since fseeko et.al. should be
-# upward compatible.
-for ac_func in ftello ftello64 fseeko fseeko64 fopen64
-do :
- as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
-ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
-if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
- cat >>confdefs.h <<_ACEOF
-#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
-_ACEOF
-
-fi
-done
-
-ac_fn_c_check_decl "$LINENO" "ftello" "ac_cv_have_decl_ftello" "$ac_includes_default"
-if test "x$ac_cv_have_decl_ftello" = xyes; then :
- ac_have_decl=1
-else
- ac_have_decl=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define HAVE_DECL_FTELLO $ac_have_decl
-_ACEOF
-ac_fn_c_check_decl "$LINENO" "ftello64" "ac_cv_have_decl_ftello64" "$ac_includes_default"
-if test "x$ac_cv_have_decl_ftello64" = xyes; then :
- ac_have_decl=1
-else
- ac_have_decl=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define HAVE_DECL_FTELLO64 $ac_have_decl
-_ACEOF
-ac_fn_c_check_decl "$LINENO" "fseeko" "ac_cv_have_decl_fseeko" "$ac_includes_default"
-if test "x$ac_cv_have_decl_fseeko" = xyes; then :
- ac_have_decl=1
-else
- ac_have_decl=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define HAVE_DECL_FSEEKO $ac_have_decl
-_ACEOF
-ac_fn_c_check_decl "$LINENO" "fseeko64" "ac_cv_have_decl_fseeko64" "$ac_includes_default"
-if test "x$ac_cv_have_decl_fseeko64" = xyes; then :
- ac_have_decl=1
-else
- ac_have_decl=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define HAVE_DECL_FSEEKO64 $ac_have_decl
-_ACEOF
-ac_fn_c_check_decl "$LINENO" "fopen64" "ac_cv_have_decl_fopen64" "$ac_includes_default"
-if test "x$ac_cv_have_decl_fopen64" = xyes; then :
- ac_have_decl=1
-else
- ac_have_decl=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define HAVE_DECL_FOPEN64 $ac_have_decl
-_ACEOF
-
-if test x"$ac_cv_func_ftello" = xyes -a x"$ac_cv_func_fseeko" = xyes; then
- # The cast to long int works around a bug in the HP C Compiler
-# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
-# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
-# This bug is HP SR number 8606223364.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of off_t" >&5
-$as_echo_n "checking size of off_t... " >&6; }
-if ${ac_cv_sizeof_off_t+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (off_t))" "ac_cv_sizeof_off_t" "$ac_includes_default"; then :
-
-else
- if test "$ac_cv_type_off_t" = yes; then
- { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error 77 "cannot compute sizeof (off_t)
-See \`config.log' for more details" "$LINENO" 5; }
- else
- ac_cv_sizeof_off_t=0
- fi
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_off_t" >&5
-$as_echo "$ac_cv_sizeof_off_t" >&6; }
-
-
-
-cat >>confdefs.h <<_ACEOF
-#define SIZEOF_OFF_T $ac_cv_sizeof_off_t
-_ACEOF
-
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking file_ptr type" >&5
-$as_echo_n "checking file_ptr type... " >&6; }
-bfd_file_ptr="long"
-bfd_ufile_ptr="unsigned long"
-if test x"$ac_cv_func_ftello64" = xyes -a x"$ac_cv_func_fseeko64" = xyes \
- -o x"${ac_cv_sizeof_off_t}" = x8; then
- bfd_file_ptr=int64_t
- bfd_ufile_ptr=uint64_t
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_file_ptr" >&5
-$as_echo "$bfd_file_ptr" >&6; }
-
-
-
-
-
-
- for ac_header in $ac_header_list
-do :
- as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
-ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
-"
-if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
- cat >>confdefs.h <<_ACEOF
-#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
-_ACEOF
-
-fi
-
-done
-
-
-
-
-
-
-
-save_ASAN_OPTIONS="$ASAN_OPTIONS"
- ASAN_OPTIONS=detect_leaks=0
- export ASAN_OPTIONS
-
-for ac_func in getpagesize
-do :
- ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize"
-if test "x$ac_cv_func_getpagesize" = xyes; then :
- cat >>confdefs.h <<_ACEOF
-#define HAVE_GETPAGESIZE 1
-_ACEOF
-
-fi
-done
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mmap" >&5
-$as_echo_n "checking for working mmap... " >&6; }
-if ${ac_cv_func_mmap_fixed_mapped+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test "$cross_compiling" = yes; then :
- ac_cv_func_mmap_fixed_mapped=no
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$ac_includes_default
-/* malloc might have been renamed as rpl_malloc. */
-#undef malloc
-
-/* Thanks to Mike Haertel and Jim Avera for this test.
- Here is a matrix of mmap possibilities:
- mmap private not fixed
- mmap private fixed at somewhere currently unmapped
- mmap private fixed at somewhere already mapped
- mmap shared not fixed
- mmap shared fixed at somewhere currently unmapped
- mmap shared fixed at somewhere already mapped
- For private mappings, we should verify that changes cannot be read()
- back from the file, nor mmap's back from the file at a different
- address. (There have been systems where private was not correctly
- implemented like the infamous i386 svr4.0, and systems where the
- VM page cache was not coherent with the file system buffer cache
- like early versions of FreeBSD and possibly contemporary NetBSD.)
- For shared mappings, we should conversely verify that changes get
- propagated back to all the places they're supposed to be.
-
- Grep wants private fixed already mapped.
- The main things grep needs to know about mmap are:
- * does it exist and is it safe to write into the mmap'd area
- * how to use it (BSD variants) */
-
-#include <fcntl.h>
-#include <sys/mman.h>
-
-#if !defined STDC_HEADERS && !defined HAVE_STDLIB_H
-char *malloc ();
-#endif
-
-/* This mess was copied from the GNU getpagesize.h. */
-#ifndef HAVE_GETPAGESIZE
-# ifdef _SC_PAGESIZE
-# define getpagesize() sysconf(_SC_PAGESIZE)
-# else /* no _SC_PAGESIZE */
-# ifdef HAVE_SYS_PARAM_H
-# include <sys/param.h>
-# ifdef EXEC_PAGESIZE
-# define getpagesize() EXEC_PAGESIZE
-# else /* no EXEC_PAGESIZE */
-# ifdef NBPG
-# define getpagesize() NBPG * CLSIZE
-# ifndef CLSIZE
-# define CLSIZE 1
-# endif /* no CLSIZE */
-# else /* no NBPG */
-# ifdef NBPC
-# define getpagesize() NBPC
-# else /* no NBPC */
-# ifdef PAGESIZE
-# define getpagesize() PAGESIZE
-# endif /* PAGESIZE */
-# endif /* no NBPC */
-# endif /* no NBPG */
-# endif /* no EXEC_PAGESIZE */
-# else /* no HAVE_SYS_PARAM_H */
-# define getpagesize() 8192 /* punt totally */
-# endif /* no HAVE_SYS_PARAM_H */
-# endif /* no _SC_PAGESIZE */
-
-#endif /* no HAVE_GETPAGESIZE */
-
-int
-main ()
-{
- char *data, *data2, *data3;
- const char *cdata2;
- int i, pagesize;
- int fd, fd2;
-
- pagesize = getpagesize ();
-
- /* First, make a file with some known garbage in it. */
- data = (char *) malloc (pagesize);
- if (!data)
- return 1;
- for (i = 0; i < pagesize; ++i)
- *(data + i) = rand ();
- umask (0);
- fd = creat ("conftest.mmap", 0600);
- if (fd < 0)
- return 2;
- if (write (fd, data, pagesize) != pagesize)
- return 3;
- close (fd);
-
- /* Next, check that the tail of a page is zero-filled. File must have
- non-zero length, otherwise we risk SIGBUS for entire page. */
- fd2 = open ("conftest.txt", O_RDWR | O_CREAT | O_TRUNC, 0600);
- if (fd2 < 0)
- return 4;
- cdata2 = "";
- if (write (fd2, cdata2, 1) != 1)
- return 5;
- data2 = (char *) mmap (0, pagesize, PROT_READ | PROT_WRITE, MAP_SHARED, fd2, 0L);
- if (data2 == MAP_FAILED)
- return 6;
- for (i = 0; i < pagesize; ++i)
- if (*(data2 + i))
- return 7;
- close (fd2);
- if (munmap (data2, pagesize))
- return 8;
-
- /* Next, try to mmap the file at a fixed address which already has
- something else allocated at it. If we can, also make sure that
- we see the same garbage. */
- fd = open ("conftest.mmap", O_RDWR);
- if (fd < 0)
- return 9;
- if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE,
- MAP_PRIVATE | MAP_FIXED, fd, 0L))
- return 10;
- for (i = 0; i < pagesize; ++i)
- if (*(data + i) != *(data2 + i))
- return 11;
-
- /* Finally, make sure that changes to the mapped area do not
- percolate back to the file as seen by read(). (This is a bug on
- some variants of i386 svr4.0.) */
- for (i = 0; i < pagesize; ++i)
- *(data2 + i) = *(data2 + i) + 1;
- data3 = (char *) malloc (pagesize);
- if (!data3)
- return 12;
- if (read (fd, data3, pagesize) != pagesize)
- return 13;
- for (i = 0; i < pagesize; ++i)
- if (*(data + i) != *(data3 + i))
- return 14;
- close (fd);
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_run "$LINENO"; then :
- ac_cv_func_mmap_fixed_mapped=yes
-else
- ac_cv_func_mmap_fixed_mapped=no
-fi
-rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
- conftest.$ac_objext conftest.beam conftest.$ac_ext
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mmap_fixed_mapped" >&5
-$as_echo "$ac_cv_func_mmap_fixed_mapped" >&6; }
-if test $ac_cv_func_mmap_fixed_mapped = yes; then
-
-$as_echo "#define HAVE_MMAP 1" >>confdefs.h
-
-fi
-rm -f conftest.mmap conftest.txt
-
- ASAN_OPTIONS="$save_ASAN_OPTIONS"
-
-for ac_func in madvise mprotect
-do :
- as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
-ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
-if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
- cat >>confdefs.h <<_ACEOF
-#define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
-_ACEOF
-
-fi
-done
-
-case ${want_mmap}+${ac_cv_func_mmap_fixed_mapped} in
- true+yes )
-$as_echo "#define USE_MMAP 1" >>confdefs.h
- ;;
-esac
-
-ac_config_files="$ac_config_files Makefile bfd-in3.h:bfd-in2.h po/Makefile.in:po/Make-in"
-
-
-ac_config_commands="$ac_config_commands default"
-
-
-
-
-
-
-
-cat >confcache <<\_ACEOF
-# This file is a shell script that caches the results of configure
-# tests run on this system so they can be shared between configure
-# scripts and configure runs, see configure's option --config-cache.
-# It is not useful on other systems. If it contains results you don't
-# want to keep, you may remove or edit it.
-#
-# config.status only pays attention to the cache file if you give it
-# the --recheck option to rerun configure.
-#
-# `ac_cv_env_foo' variables (set or unset) will be overridden when
-# loading this file, other *unset* `ac_cv_foo' will be assigned the
-# following values.
-
-_ACEOF
-
-# The following way of writing the cache mishandles newlines in values,
-# but we know of no workaround that is simple, portable, and efficient.
-# So, we kill variables containing newlines.
-# Ultrix sh set writes to stderr and can't be redirected directly,
-# and sets the high bit in the cache file unless we assign to the vars.
-(
- for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
- eval ac_val=\$$ac_var
- case $ac_val in #(
- *${as_nl}*)
- case $ac_var in #(
- *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
-$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
- esac
- case $ac_var in #(
- _ | IFS | as_nl) ;; #(
- BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
- *) { eval $ac_var=; unset $ac_var;} ;;
- esac ;;
- esac
- done
-
- (set) 2>&1 |
- case $as_nl`(ac_space=' '; set) 2>&1` in #(
- *${as_nl}ac_space=\ *)
- # `set' does not quote correctly, so add quotes: double-quote
- # substitution turns \\\\ into \\, and sed turns \\ into \.
- sed -n \
- "s/'/'\\\\''/g;
- s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
- ;; #(
- *)
- # `set' quotes correctly as required by POSIX, so do not add quotes.
- sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
- ;;
- esac |
- sort
-) |
- sed '
- /^ac_cv_env_/b end
- t clear
- :clear
- s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
- t end
- s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
- :end' >>confcache
-if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
- if test -w "$cache_file"; then
- if test "x$cache_file" != "x/dev/null"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
-$as_echo "$as_me: updating cache $cache_file" >&6;}
- if test ! -f "$cache_file" || test -h "$cache_file"; then
- cat confcache >"$cache_file"
- else
- case $cache_file in #(
- */* | ?:*)
- mv -f confcache "$cache_file"$$ &&
- mv -f "$cache_file"$$ "$cache_file" ;; #(
- *)
- mv -f confcache "$cache_file" ;;
- esac
- fi
- fi
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
-$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
- fi
-fi
-rm -f confcache
-
-test "x$prefix" = xNONE && prefix=$ac_default_prefix
-# Let make expand exec_prefix.
-test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
-
-DEFS=-DHAVE_CONFIG_H
-
-ac_libobjs=
-ac_ltlibobjs=
-U=
-for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
- # 1. Remove the extension, and $U if already installed.
- ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
- ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
- # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
- # will be set to the directory where LIBOBJS objects are built.
- as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
- as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
-done
-LIBOBJS=$ac_libobjs
-
-LTLIBOBJS=$ac_ltlibobjs
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking that generated files are newer than configure" >&5
-$as_echo_n "checking that generated files are newer than configure... " >&6; }
- if test -n "$am_sleep_pid"; then
- # Hide warnings about reused PIDs.
- wait $am_sleep_pid 2>/dev/null
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: done" >&5
-$as_echo "done" >&6; }
- if test -n "$EXEEXT"; then
- am__EXEEXT_TRUE=
- am__EXEEXT_FALSE='#'
-else
- am__EXEEXT_TRUE='#'
- am__EXEEXT_FALSE=
-fi
-
-if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
- as_fn_error $? "conditional \"AMDEP\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
- as_fn_error $? "conditional \"am__fastdepCC\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${PLUGINS_TRUE}" && test -z "${PLUGINS_FALSE}"; then
- as_fn_error $? "conditional \"PLUGINS\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${ENABLE_BFD_64_BIT_TRUE}" && test -z "${ENABLE_BFD_64_BIT_FALSE}"; then
- as_fn_error $? "conditional \"ENABLE_BFD_64_BIT\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${MAINTAINER_MODE_TRUE}" && test -z "${MAINTAINER_MODE_FALSE}"; then
- as_fn_error $? "conditional \"MAINTAINER_MODE\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${GENINSRC_NEVER_TRUE}" && test -z "${GENINSRC_NEVER_FALSE}"; then
- as_fn_error $? "conditional \"GENINSRC_NEVER\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${INSTALL_LIBBFD_TRUE}" && test -z "${INSTALL_LIBBFD_FALSE}"; then
- as_fn_error $? "conditional \"INSTALL_LIBBFD\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-
-
-: "${CONFIG_STATUS=./config.status}"
-ac_write_fail=0
-ac_clean_files_save=$ac_clean_files
-ac_clean_files="$ac_clean_files $CONFIG_STATUS"
-{ $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
-$as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
-as_write_fail=0
-cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
-#! $SHELL
-# Generated by $as_me.
-# Run this file to recreate the current configuration.
-# Compiler output produced by configure, useful for debugging
-# configure, is in config.log if it exists.
-
-debug=false
-ac_cs_recheck=false
-ac_cs_silent=false
-
-SHELL=\${CONFIG_SHELL-$SHELL}
-export SHELL
-_ASEOF
-cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
-## -------------------- ##
-## M4sh Initialization. ##
-## -------------------- ##
-
-# Be more Bourne compatible
-DUALCASE=1; export DUALCASE # for MKS sh
-if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
- emulate sh
- NULLCMD=:
- # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
- # is contrary to our usage. Disable this feature.
- alias -g '${1+"$@"}'='"$@"'
- setopt NO_GLOB_SUBST
-else
- case `(set -o) 2>/dev/null` in #(
- *posix*) :
- set -o posix ;; #(
- *) :
- ;;
-esac
-fi
-
-
-as_nl='
-'
-export as_nl
-# Printing a long string crashes Solaris 7 /usr/bin/printf.
-as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
-as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
-as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
-# Prefer a ksh shell builtin over an external printf program on Solaris,
-# but without wasting forks for bash or zsh.
-if test -z "$BASH_VERSION$ZSH_VERSION" \
- && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
- as_echo='print -r --'
- as_echo_n='print -rn --'
-elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
- as_echo='printf %s\n'
- as_echo_n='printf %s'
-else
- if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
- as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
- as_echo_n='/usr/ucb/echo -n'
- else
- as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
- as_echo_n_body='eval
- arg=$1;
- case $arg in #(
- *"$as_nl"*)
- expr "X$arg" : "X\\(.*\\)$as_nl";
- arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
- esac;
- expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
- '
- export as_echo_n_body
- as_echo_n='sh -c $as_echo_n_body as_echo'
- fi
- export as_echo_body
- as_echo='sh -c $as_echo_body as_echo'
-fi
-
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- PATH_SEPARATOR=:
- (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
- (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
- PATH_SEPARATOR=';'
- }
-fi
-
-
-# IFS
-# We need space, tab and new line, in precisely that order. Quoting is
-# there to prevent editors from complaining about space-tab.
-# (If _AS_PATH_WALK were called with IFS unset, it would disable word
-# splitting by setting IFS to empty value.)
-IFS=" "" $as_nl"
-
-# Find who we are. Look in the path if we contain no directory separator.
-as_myself=
-case $0 in #((
- *[\\/]* ) as_myself=$0 ;;
- *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
- done
-IFS=$as_save_IFS
-
- ;;
-esac
-# We did not find ourselves, most probably we were run as `sh COMMAND'
-# in which case we are not to be found in the path.
-if test "x$as_myself" = x; then
- as_myself=$0
-fi
-if test ! -f "$as_myself"; then
- $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
- exit 1
-fi
-
-# Unset variables that we do not need and which cause bugs (e.g. in
-# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
-# suppresses any "Segmentation fault" message there. '((' could
-# trigger a bug in pdksh 5.2.14.
-for as_var in BASH_ENV ENV MAIL MAILPATH
-do eval test x\${$as_var+set} = xset \
- && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
-done
-PS1='$ '
-PS2='> '
-PS4='+ '
-
-# NLS nuisances.
-LC_ALL=C
-export LC_ALL
-LANGUAGE=C
-export LANGUAGE
-
-# CDPATH.
-(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
-
-
-# as_fn_error STATUS ERROR [LINENO LOG_FD]
-# ----------------------------------------
-# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
-# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
-# script with STATUS, using 1 if that was 0.
-as_fn_error ()
-{
- as_status=$1; test $as_status -eq 0 && as_status=1
- if test "$4"; then
- as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
- fi
- $as_echo "$as_me: error: $2" >&2
- as_fn_exit $as_status
-} # as_fn_error
-
-
-# as_fn_set_status STATUS
-# -----------------------
-# Set $? to STATUS, without forking.
-as_fn_set_status ()
-{
- return $1
-} # as_fn_set_status
-
-# as_fn_exit STATUS
-# -----------------
-# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
-as_fn_exit ()
-{
- set +e
- as_fn_set_status $1
- exit $1
-} # as_fn_exit
-
-# as_fn_unset VAR
-# ---------------
-# Portably unset VAR.
-as_fn_unset ()
-{
- { eval $1=; unset $1;}
-}
-as_unset=as_fn_unset
-# as_fn_append VAR VALUE
-# ----------------------
-# Append the text in VALUE to the end of the definition contained in VAR. Take
-# advantage of any shell optimizations that allow amortized linear growth over
-# repeated appends, instead of the typical quadratic growth present in naive
-# implementations.
-if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
- eval 'as_fn_append ()
- {
- eval $1+=\$2
- }'
-else
- as_fn_append ()
- {
- eval $1=\$$1\$2
- }
-fi # as_fn_append
-
-# as_fn_arith ARG...
-# ------------------
-# Perform arithmetic evaluation on the ARGs, and store the result in the
-# global $as_val. Take advantage of shells that can avoid forks. The arguments
-# must be portable across $(()) and expr.
-if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
- eval 'as_fn_arith ()
- {
- as_val=$(( $* ))
- }'
-else
- as_fn_arith ()
- {
- as_val=`expr "$@" || test $? -eq 1`
- }
-fi # as_fn_arith
-
-
-if expr a : '\(a\)' >/dev/null 2>&1 &&
- test "X`expr 00001 : '.*\(...\)'`" = X001; then
- as_expr=expr
-else
- as_expr=false
-fi
-
-if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
- as_basename=basename
-else
- as_basename=false
-fi
-
-if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
- as_dirname=dirname
-else
- as_dirname=false
-fi
-
-as_me=`$as_basename -- "$0" ||
-$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
- X"$0" : 'X\(//\)$' \| \
- X"$0" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X/"$0" |
- sed '/^.*\/\([^/][^/]*\)\/*$/{
- s//\1/
- q
- }
- /^X\/\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\/\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
-
-# Avoid depending upon Character Ranges.
-as_cr_letters='abcdefghijklmnopqrstuvwxyz'
-as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
-as_cr_Letters=$as_cr_letters$as_cr_LETTERS
-as_cr_digits='0123456789'
-as_cr_alnum=$as_cr_Letters$as_cr_digits
-
-ECHO_C= ECHO_N= ECHO_T=
-case `echo -n x` in #(((((
--n*)
- case `echo 'xy\c'` in
- *c*) ECHO_T=' ';; # ECHO_T is single tab character.
- xy) ECHO_C='\c';;
- *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
- ECHO_T=' ';;
- esac;;
-*)
- ECHO_N='-n';;
-esac
-
-rm -f conf$$ conf$$.exe conf$$.file
-if test -d conf$$.dir; then
- rm -f conf$$.dir/conf$$.file
-else
- rm -f conf$$.dir
- mkdir conf$$.dir 2>/dev/null
-fi
-if (echo >conf$$.file) 2>/dev/null; then
- if ln -s conf$$.file conf$$ 2>/dev/null; then
- as_ln_s='ln -s'
- # ... but there are two gotchas:
- # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
- # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
- # In both cases, we have to default to `cp -pR'.
- ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
- as_ln_s='cp -pR'
- elif ln conf$$.file conf$$ 2>/dev/null; then
- as_ln_s=ln
- else
- as_ln_s='cp -pR'
- fi
-else
- as_ln_s='cp -pR'
-fi
-rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
-rmdir conf$$.dir 2>/dev/null
-
-
-# as_fn_mkdir_p
-# -------------
-# Create "$as_dir" as a directory, including parents if necessary.
-as_fn_mkdir_p ()
-{
-
- case $as_dir in #(
- -*) as_dir=./$as_dir;;
- esac
- test -d "$as_dir" || eval $as_mkdir_p || {
- as_dirs=
- while :; do
- case $as_dir in #(
- *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
- *) as_qdir=$as_dir;;
- esac
- as_dirs="'$as_qdir' $as_dirs"
- as_dir=`$as_dirname -- "$as_dir" ||
-$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$as_dir" : 'X\(//\)[^/]' \| \
- X"$as_dir" : 'X\(//\)$' \| \
- X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$as_dir" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
- test -d "$as_dir" && break
- done
- test -z "$as_dirs" || eval "mkdir $as_dirs"
- } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
-
-
-} # as_fn_mkdir_p
-if mkdir -p . 2>/dev/null; then
- as_mkdir_p='mkdir -p "$as_dir"'
-else
- test -d ./-p && rmdir ./-p
- as_mkdir_p=false
-fi
-
-
-# as_fn_executable_p FILE
-# -----------------------
-# Test if FILE is an executable regular file.
-as_fn_executable_p ()
-{
- test -f "$1" && test -x "$1"
-} # as_fn_executable_p
-as_test_x='test -x'
-as_executable_p=as_fn_executable_p
-
-# Sed expression to map a string onto a valid CPP name.
-as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
-
-# Sed expression to map a string onto a valid variable name.
-as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
-
-
-exec 6>&1
-## ----------------------------------- ##
-## Main body of $CONFIG_STATUS script. ##
-## ----------------------------------- ##
-_ASEOF
-test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
-
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-# Save the log message, to keep $0 and so on meaningful, and to
-# report actual input values of CONFIG_FILES etc. instead of their
-# values after options handling.
-ac_log="
-This file was extended by bfd $as_me 2.43.1, which was
-generated by GNU Autoconf 2.69. Invocation command line was
-
- CONFIG_FILES = $CONFIG_FILES
- CONFIG_HEADERS = $CONFIG_HEADERS
- CONFIG_LINKS = $CONFIG_LINKS
- CONFIG_COMMANDS = $CONFIG_COMMANDS
- $ $0 $@
-
-on `(hostname || uname -n) 2>/dev/null | sed 1q`
-"
-
-_ACEOF
-
-case $ac_config_files in *"
-"*) set x $ac_config_files; shift; ac_config_files=$*;;
-esac
-
-case $ac_config_headers in *"
-"*) set x $ac_config_headers; shift; ac_config_headers=$*;;
-esac
-
-
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-# Files that config.status was made for.
-config_files="$ac_config_files"
-config_headers="$ac_config_headers"
-config_commands="$ac_config_commands"
-
-_ACEOF
-
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-ac_cs_usage="\
-\`$as_me' instantiates files and other configuration actions
-from templates according to the current configuration. Unless the files
-and actions are specified as TAGs, all are instantiated by default.
-
-Usage: $0 [OPTION]... [TAG]...
-
- -h, --help print this help, then exit
- -V, --version print version number and configuration settings, then exit
- --config print configuration, then exit
- -q, --quiet, --silent
- do not print progress messages
- -d, --debug don't remove temporary files
- --recheck update $as_me by reconfiguring in the same conditions
- --file=FILE[:TEMPLATE]
- instantiate the configuration file FILE
- --header=FILE[:TEMPLATE]
- instantiate the configuration header FILE
-
-Configuration files:
-$config_files
-
-Configuration headers:
-$config_headers
-
-Configuration commands:
-$config_commands
-
-Report bugs to the package provider."
-
-_ACEOF
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
-ac_cs_version="\\
-bfd config.status 2.43.1
-configured by $0, generated by GNU Autoconf 2.69,
- with options \\"\$ac_cs_config\\"
-
-Copyright (C) 2012 Free Software Foundation, Inc.
-This config.status script is free software; the Free Software Foundation
-gives unlimited permission to copy, distribute and modify it."
-
-ac_pwd='$ac_pwd'
-srcdir='$srcdir'
-INSTALL='$INSTALL'
-MKDIR_P='$MKDIR_P'
-AWK='$AWK'
-test -n "\$AWK" || AWK=awk
-_ACEOF
-
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-# The default lists apply if the user does not specify any file.
-ac_need_defaults=:
-while test $# != 0
-do
- case $1 in
- --*=?*)
- ac_option=`expr "X$1" : 'X\([^=]*\)='`
- ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
- ac_shift=:
- ;;
- --*=)
- ac_option=`expr "X$1" : 'X\([^=]*\)='`
- ac_optarg=
- ac_shift=:
- ;;
- *)
- ac_option=$1
- ac_optarg=$2
- ac_shift=shift
- ;;
- esac
-
- case $ac_option in
- # Handling of the options.
- -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
- ac_cs_recheck=: ;;
- --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
- $as_echo "$ac_cs_version"; exit ;;
- --config | --confi | --conf | --con | --co | --c )
- $as_echo "$ac_cs_config"; exit ;;
- --debug | --debu | --deb | --de | --d | -d )
- debug=: ;;
- --file | --fil | --fi | --f )
- $ac_shift
- case $ac_optarg in
- *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
- '') as_fn_error $? "missing file argument" ;;
- esac
- as_fn_append CONFIG_FILES " '$ac_optarg'"
- ac_need_defaults=false;;
- --header | --heade | --head | --hea )
- $ac_shift
- case $ac_optarg in
- *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
- esac
- as_fn_append CONFIG_HEADERS " '$ac_optarg'"
- ac_need_defaults=false;;
- --he | --h)
- # Conflict between --help and --header
- as_fn_error $? "ambiguous option: \`$1'
-Try \`$0 --help' for more information.";;
- --help | --hel | -h )
- $as_echo "$ac_cs_usage"; exit ;;
- -q | -quiet | --quiet | --quie | --qui | --qu | --q \
- | -silent | --silent | --silen | --sile | --sil | --si | --s)
- ac_cs_silent=: ;;
-
- # This is an error.
- -*) as_fn_error $? "unrecognized option: \`$1'
-Try \`$0 --help' for more information." ;;
-
- *) as_fn_append ac_config_targets " $1"
- ac_need_defaults=false ;;
-
- esac
- shift
-done
-
-ac_configure_extra_args=
-
-if $ac_cs_silent; then
- exec 6>/dev/null
- ac_configure_extra_args="$ac_configure_extra_args --silent"
-fi
-
-_ACEOF
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-if \$ac_cs_recheck; then
- set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
- shift
- \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
- CONFIG_SHELL='$SHELL'
- export CONFIG_SHELL
- exec "\$@"
-fi
-
-_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-exec 5>>config.log
-{
- echo
- sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
-## Running $as_me. ##
-_ASBOX
- $as_echo "$ac_log"
-} >&5
-
-_ACEOF
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-#
-# INIT-COMMANDS
-#
-AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"
-
-
-# The HP-UX ksh and POSIX shell print the target directory to stdout
-# if CDPATH is set.
-(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
-
-sed_quote_subst='$sed_quote_subst'
-double_quote_subst='$double_quote_subst'
-delay_variable_subst='$delay_variable_subst'
-enable_shared='`$ECHO "$enable_shared" | $SED "$delay_single_quote_subst"`'
-macro_version='`$ECHO "$macro_version" | $SED "$delay_single_quote_subst"`'
-macro_revision='`$ECHO "$macro_revision" | $SED "$delay_single_quote_subst"`'
-enable_static='`$ECHO "$enable_static" | $SED "$delay_single_quote_subst"`'
-pic_mode='`$ECHO "$pic_mode" | $SED "$delay_single_quote_subst"`'
-enable_fast_install='`$ECHO "$enable_fast_install" | $SED "$delay_single_quote_subst"`'
-SHELL='`$ECHO "$SHELL" | $SED "$delay_single_quote_subst"`'
-ECHO='`$ECHO "$ECHO" | $SED "$delay_single_quote_subst"`'
-host_alias='`$ECHO "$host_alias" | $SED "$delay_single_quote_subst"`'
-host='`$ECHO "$host" | $SED "$delay_single_quote_subst"`'
-host_os='`$ECHO "$host_os" | $SED "$delay_single_quote_subst"`'
-build_alias='`$ECHO "$build_alias" | $SED "$delay_single_quote_subst"`'
-build='`$ECHO "$build" | $SED "$delay_single_quote_subst"`'
-build_os='`$ECHO "$build_os" | $SED "$delay_single_quote_subst"`'
-SED='`$ECHO "$SED" | $SED "$delay_single_quote_subst"`'
-Xsed='`$ECHO "$Xsed" | $SED "$delay_single_quote_subst"`'
-GREP='`$ECHO "$GREP" | $SED "$delay_single_quote_subst"`'
-EGREP='`$ECHO "$EGREP" | $SED "$delay_single_quote_subst"`'
-FGREP='`$ECHO "$FGREP" | $SED "$delay_single_quote_subst"`'
-LD='`$ECHO "$LD" | $SED "$delay_single_quote_subst"`'
-NM='`$ECHO "$NM" | $SED "$delay_single_quote_subst"`'
-LN_S='`$ECHO "$LN_S" | $SED "$delay_single_quote_subst"`'
-max_cmd_len='`$ECHO "$max_cmd_len" | $SED "$delay_single_quote_subst"`'
-ac_objext='`$ECHO "$ac_objext" | $SED "$delay_single_quote_subst"`'
-exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`'
-lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`'
-lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`'
-lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`'
-reload_flag='`$ECHO "$reload_flag" | $SED "$delay_single_quote_subst"`'
-reload_cmds='`$ECHO "$reload_cmds" | $SED "$delay_single_quote_subst"`'
-OBJDUMP='`$ECHO "$OBJDUMP" | $SED "$delay_single_quote_subst"`'
-deplibs_check_method='`$ECHO "$deplibs_check_method" | $SED "$delay_single_quote_subst"`'
-file_magic_cmd='`$ECHO "$file_magic_cmd" | $SED "$delay_single_quote_subst"`'
-AR='`$ECHO "$AR" | $SED "$delay_single_quote_subst"`'
-AR_FLAGS='`$ECHO "$AR_FLAGS" | $SED "$delay_single_quote_subst"`'
-STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`'
-RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`'
-old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`'
-old_postuninstall_cmds='`$ECHO "$old_postuninstall_cmds" | $SED "$delay_single_quote_subst"`'
-old_archive_cmds='`$ECHO "$old_archive_cmds" | $SED "$delay_single_quote_subst"`'
-lock_old_archive_extraction='`$ECHO "$lock_old_archive_extraction" | $SED "$delay_single_quote_subst"`'
-CC='`$ECHO "$CC" | $SED "$delay_single_quote_subst"`'
-CFLAGS='`$ECHO "$CFLAGS" | $SED "$delay_single_quote_subst"`'
-compiler='`$ECHO "$compiler" | $SED "$delay_single_quote_subst"`'
-GCC='`$ECHO "$GCC" | $SED "$delay_single_quote_subst"`'
-lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$delay_single_quote_subst"`'
-lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`'
-lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`'
-lt_cv_sys_global_symbol_to_c_name_address_lib_prefix='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address_lib_prefix" | $SED "$delay_single_quote_subst"`'
-objdir='`$ECHO "$objdir" | $SED "$delay_single_quote_subst"`'
-MAGIC_CMD='`$ECHO "$MAGIC_CMD" | $SED "$delay_single_quote_subst"`'
-lt_prog_compiler_no_builtin_flag='`$ECHO "$lt_prog_compiler_no_builtin_flag" | $SED "$delay_single_quote_subst"`'
-lt_prog_compiler_wl='`$ECHO "$lt_prog_compiler_wl" | $SED "$delay_single_quote_subst"`'
-lt_prog_compiler_pic='`$ECHO "$lt_prog_compiler_pic" | $SED "$delay_single_quote_subst"`'
-lt_prog_compiler_static='`$ECHO "$lt_prog_compiler_static" | $SED "$delay_single_quote_subst"`'
-lt_cv_prog_compiler_c_o='`$ECHO "$lt_cv_prog_compiler_c_o" | $SED "$delay_single_quote_subst"`'
-need_locks='`$ECHO "$need_locks" | $SED "$delay_single_quote_subst"`'
-DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`'
-NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`'
-LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`'
-OTOOL='`$ECHO "$OTOOL" | $SED "$delay_single_quote_subst"`'
-OTOOL64='`$ECHO "$OTOOL64" | $SED "$delay_single_quote_subst"`'
-libext='`$ECHO "$libext" | $SED "$delay_single_quote_subst"`'
-shrext_cmds='`$ECHO "$shrext_cmds" | $SED "$delay_single_quote_subst"`'
-extract_expsyms_cmds='`$ECHO "$extract_expsyms_cmds" | $SED "$delay_single_quote_subst"`'
-archive_cmds_need_lc='`$ECHO "$archive_cmds_need_lc" | $SED "$delay_single_quote_subst"`'
-enable_shared_with_static_runtimes='`$ECHO "$enable_shared_with_static_runtimes" | $SED "$delay_single_quote_subst"`'
-export_dynamic_flag_spec='`$ECHO "$export_dynamic_flag_spec" | $SED "$delay_single_quote_subst"`'
-whole_archive_flag_spec='`$ECHO "$whole_archive_flag_spec" | $SED "$delay_single_quote_subst"`'
-compiler_needs_object='`$ECHO "$compiler_needs_object" | $SED "$delay_single_quote_subst"`'
-old_archive_from_new_cmds='`$ECHO "$old_archive_from_new_cmds" | $SED "$delay_single_quote_subst"`'
-old_archive_from_expsyms_cmds='`$ECHO "$old_archive_from_expsyms_cmds" | $SED "$delay_single_quote_subst"`'
-archive_cmds='`$ECHO "$archive_cmds" | $SED "$delay_single_quote_subst"`'
-archive_expsym_cmds='`$ECHO "$archive_expsym_cmds" | $SED "$delay_single_quote_subst"`'
-module_cmds='`$ECHO "$module_cmds" | $SED "$delay_single_quote_subst"`'
-module_expsym_cmds='`$ECHO "$module_expsym_cmds" | $SED "$delay_single_quote_subst"`'
-with_gnu_ld='`$ECHO "$with_gnu_ld" | $SED "$delay_single_quote_subst"`'
-allow_undefined_flag='`$ECHO "$allow_undefined_flag" | $SED "$delay_single_quote_subst"`'
-no_undefined_flag='`$ECHO "$no_undefined_flag" | $SED "$delay_single_quote_subst"`'
-hardcode_libdir_flag_spec='`$ECHO "$hardcode_libdir_flag_spec" | $SED "$delay_single_quote_subst"`'
-hardcode_libdir_flag_spec_ld='`$ECHO "$hardcode_libdir_flag_spec_ld" | $SED "$delay_single_quote_subst"`'
-hardcode_libdir_separator='`$ECHO "$hardcode_libdir_separator" | $SED "$delay_single_quote_subst"`'
-hardcode_direct='`$ECHO "$hardcode_direct" | $SED "$delay_single_quote_subst"`'
-hardcode_direct_absolute='`$ECHO "$hardcode_direct_absolute" | $SED "$delay_single_quote_subst"`'
-hardcode_minus_L='`$ECHO "$hardcode_minus_L" | $SED "$delay_single_quote_subst"`'
-hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_quote_subst"`'
-hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`'
-inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`'
-link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`'
-fix_srcfile_path='`$ECHO "$fix_srcfile_path" | $SED "$delay_single_quote_subst"`'
-always_export_symbols='`$ECHO "$always_export_symbols" | $SED "$delay_single_quote_subst"`'
-export_symbols_cmds='`$ECHO "$export_symbols_cmds" | $SED "$delay_single_quote_subst"`'
-exclude_expsyms='`$ECHO "$exclude_expsyms" | $SED "$delay_single_quote_subst"`'
-include_expsyms='`$ECHO "$include_expsyms" | $SED "$delay_single_quote_subst"`'
-prelink_cmds='`$ECHO "$prelink_cmds" | $SED "$delay_single_quote_subst"`'
-file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`'
-variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`'
-need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`'
-need_version='`$ECHO "$need_version" | $SED "$delay_single_quote_subst"`'
-version_type='`$ECHO "$version_type" | $SED "$delay_single_quote_subst"`'
-runpath_var='`$ECHO "$runpath_var" | $SED "$delay_single_quote_subst"`'
-shlibpath_var='`$ECHO "$shlibpath_var" | $SED "$delay_single_quote_subst"`'
-shlibpath_overrides_runpath='`$ECHO "$shlibpath_overrides_runpath" | $SED "$delay_single_quote_subst"`'
-libname_spec='`$ECHO "$libname_spec" | $SED "$delay_single_quote_subst"`'
-library_names_spec='`$ECHO "$library_names_spec" | $SED "$delay_single_quote_subst"`'
-soname_spec='`$ECHO "$soname_spec" | $SED "$delay_single_quote_subst"`'
-install_override_mode='`$ECHO "$install_override_mode" | $SED "$delay_single_quote_subst"`'
-postinstall_cmds='`$ECHO "$postinstall_cmds" | $SED "$delay_single_quote_subst"`'
-postuninstall_cmds='`$ECHO "$postuninstall_cmds" | $SED "$delay_single_quote_subst"`'
-finish_cmds='`$ECHO "$finish_cmds" | $SED "$delay_single_quote_subst"`'
-finish_eval='`$ECHO "$finish_eval" | $SED "$delay_single_quote_subst"`'
-hardcode_into_libs='`$ECHO "$hardcode_into_libs" | $SED "$delay_single_quote_subst"`'
-sys_lib_search_path_spec='`$ECHO "$sys_lib_search_path_spec" | $SED "$delay_single_quote_subst"`'
-sys_lib_dlsearch_path_spec='`$ECHO "$sys_lib_dlsearch_path_spec" | $SED "$delay_single_quote_subst"`'
-hardcode_action='`$ECHO "$hardcode_action" | $SED "$delay_single_quote_subst"`'
-enable_dlopen='`$ECHO "$enable_dlopen" | $SED "$delay_single_quote_subst"`'
-enable_dlopen_self='`$ECHO "$enable_dlopen_self" | $SED "$delay_single_quote_subst"`'
-enable_dlopen_self_static='`$ECHO "$enable_dlopen_self_static" | $SED "$delay_single_quote_subst"`'
-old_striplib='`$ECHO "$old_striplib" | $SED "$delay_single_quote_subst"`'
-striplib='`$ECHO "$striplib" | $SED "$delay_single_quote_subst"`'
-
-LTCC='$LTCC'
-LTCFLAGS='$LTCFLAGS'
-compiler='$compiler_DEFAULT'
-
-# A function that is used when there is no print builtin or printf.
-func_fallback_echo ()
-{
- eval 'cat <<_LTECHO_EOF
-\$1
-_LTECHO_EOF'
-}
-
-# Quote evaled strings.
-for var in SHELL \
-ECHO \
-SED \
-GREP \
-EGREP \
-FGREP \
-LD \
-NM \
-LN_S \
-lt_SP2NL \
-lt_NL2SP \
-reload_flag \
-OBJDUMP \
-deplibs_check_method \
-file_magic_cmd \
-AR \
-AR_FLAGS \
-STRIP \
-RANLIB \
-CC \
-CFLAGS \
-compiler \
-lt_cv_sys_global_symbol_pipe \
-lt_cv_sys_global_symbol_to_cdecl \
-lt_cv_sys_global_symbol_to_c_name_address \
-lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \
-lt_prog_compiler_no_builtin_flag \
-lt_prog_compiler_wl \
-lt_prog_compiler_pic \
-lt_prog_compiler_static \
-lt_cv_prog_compiler_c_o \
-need_locks \
-DSYMUTIL \
-NMEDIT \
-LIPO \
-OTOOL \
-OTOOL64 \
-shrext_cmds \
-export_dynamic_flag_spec \
-whole_archive_flag_spec \
-compiler_needs_object \
-with_gnu_ld \
-allow_undefined_flag \
-no_undefined_flag \
-hardcode_libdir_flag_spec \
-hardcode_libdir_flag_spec_ld \
-hardcode_libdir_separator \
-fix_srcfile_path \
-exclude_expsyms \
-include_expsyms \
-file_list_spec \
-variables_saved_for_relink \
-libname_spec \
-library_names_spec \
-soname_spec \
-install_override_mode \
-finish_eval \
-old_striplib \
-striplib; do
- case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
- *[\\\\\\\`\\"\\\$]*)
- eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\""
- ;;
- *)
- eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
- ;;
- esac
-done
-
-# Double-quote double-evaled strings.
-for var in reload_cmds \
-old_postinstall_cmds \
-old_postuninstall_cmds \
-old_archive_cmds \
-extract_expsyms_cmds \
-old_archive_from_new_cmds \
-old_archive_from_expsyms_cmds \
-archive_cmds \
-archive_expsym_cmds \
-module_cmds \
-module_expsym_cmds \
-export_symbols_cmds \
-prelink_cmds \
-postinstall_cmds \
-postuninstall_cmds \
-finish_cmds \
-sys_lib_search_path_spec \
-sys_lib_dlsearch_path_spec; do
- case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
- *[\\\\\\\`\\"\\\$]*)
- eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\""
- ;;
- *)
- eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
- ;;
- esac
-done
-
-ac_aux_dir='$ac_aux_dir'
-xsi_shell='$xsi_shell'
-lt_shell_append='$lt_shell_append'
-
-# See if we are running on zsh, and set the options which allow our
-# commands through without removal of \ escapes INIT.
-if test -n "\${ZSH_VERSION+set}" ; then
- setopt NO_GLOB_SUBST
-fi
-
-
- PACKAGE='$PACKAGE'
- VERSION='$VERSION'
- TIMESTAMP='$TIMESTAMP'
- RM='$RM'
- ofile='$ofile'
-
-
-
-# Capture the value of obsolete ALL_LINGUAS because we need it to compute
- # POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES, CATALOGS. But hide it
- # from automake.
- eval 'OBSOLETE_ALL_LINGUAS''="$ALL_LINGUAS"'
- # Capture the value of LINGUAS because we need it to compute CATALOGS.
- LINGUAS="${LINGUAS-%UNSET%}"
-
-# Capture the value of obsolete ALL_LINGUAS because we need it to compute
- # POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES, CATALOGS. But hide it
- # from automake.
- eval 'OBSOLETE_ALL_LINGUAS''="$ALL_LINGUAS"'
- # Capture the value of LINGUAS because we need it to compute CATALOGS.
- LINGUAS="${LINGUAS-%UNSET%}"
-
-
-
-_ACEOF
-
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-
-# Handling of arguments.
-for ac_config_target in $ac_config_targets
-do
- case $ac_config_target in
- "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
- "libtool") CONFIG_COMMANDS="$CONFIG_COMMANDS libtool" ;;
- "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h:config.in" ;;
- "default-1") CONFIG_COMMANDS="$CONFIG_COMMANDS default-1" ;;
- "default-2") CONFIG_COMMANDS="$CONFIG_COMMANDS default-2" ;;
- "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
- "bfd-in3.h") CONFIG_FILES="$CONFIG_FILES bfd-in3.h:bfd-in2.h" ;;
- "po/Makefile.in") CONFIG_FILES="$CONFIG_FILES po/Makefile.in:po/Make-in" ;;
- "default") CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
-
- *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
- esac
-done
-
-
-# If the user did not use the arguments to specify the items to instantiate,
-# then the envvar interface is used. Set only those that are not.
-# We use the long form for the default assignment because of an extremely
-# bizarre bug on SunOS 4.1.3.
-if $ac_need_defaults; then
- test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
- test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
- test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
-fi
-
-# Have a temporary directory for convenience. Make it in the build tree
-# simply because there is no reason against having it here, and in addition,
-# creating and moving files from /tmp can sometimes cause problems.
-# Hook for its removal unless debugging.
-# Note that there is a small window in which the directory will not be cleaned:
-# after its creation but before its name has been assigned to `$tmp'.
-$debug ||
-{
- tmp= ac_tmp=
- trap 'exit_status=$?
- : "${ac_tmp:=$tmp}"
- { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
-' 0
- trap 'as_fn_exit 1' 1 2 13 15
-}
-# Create a (secure) tmp directory for tmp files.
-
-{
- tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
- test -d "$tmp"
-} ||
-{
- tmp=./conf$$-$RANDOM
- (umask 077 && mkdir "$tmp")
-} || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
-ac_tmp=$tmp
-
-# Set up the scripts for CONFIG_FILES section.
-# No need to generate them if there are no CONFIG_FILES.
-# This happens for instance with `./config.status config.h'.
-if test -n "$CONFIG_FILES"; then
-
-
-ac_cr=`echo X | tr X '\015'`
-# On cygwin, bash can eat \r inside `` if the user requested igncr.
-# But we know of no other shell where ac_cr would be empty at this
-# point, so we can use a bashism as a fallback.
-if test "x$ac_cr" = x; then
- eval ac_cr=\$\'\\r\'
-fi
-ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
-if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
- ac_cs_awk_cr='\\r'
-else
- ac_cs_awk_cr=$ac_cr
-fi
-
-echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
-_ACEOF
-
-
-{
- echo "cat >conf$$subs.awk <<_ACEOF" &&
- echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
- echo "_ACEOF"
-} >conf$$subs.sh ||
- as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
-ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
-ac_delim='%!_!# '
-for ac_last_try in false false false false false :; do
- . ./conf$$subs.sh ||
- as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
-
- ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
- if test $ac_delim_n = $ac_delim_num; then
- break
- elif $ac_last_try; then
- as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
- else
- ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
- fi
-done
-rm -f conf$$subs.sh
-
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
-_ACEOF
-sed -n '
-h
-s/^/S["/; s/!.*/"]=/
-p
-g
-s/^[^!]*!//
-:repl
-t repl
-s/'"$ac_delim"'$//
-t delim
-:nl
-h
-s/\(.\{148\}\)..*/\1/
-t more1
-s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
-p
-n
-b repl
-:more1
-s/["\\]/\\&/g; s/^/"/; s/$/"\\/
-p
-g
-s/.\{148\}//
-t nl
-:delim
-h
-s/\(.\{148\}\)..*/\1/
-t more2
-s/["\\]/\\&/g; s/^/"/; s/$/"/
-p
-b
-:more2
-s/["\\]/\\&/g; s/^/"/; s/$/"\\/
-p
-g
-s/.\{148\}//
-t delim
-' <conf$$subs.awk | sed '
-/^[^""]/{
- N
- s/\n//
-}
-' >>$CONFIG_STATUS || ac_write_fail=1
-rm -f conf$$subs.awk
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-_ACAWK
-cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
- for (key in S) S_is_set[key] = 1
- FS = ""
-
-}
-{
- line = $ 0
- nfields = split(line, field, "@")
- substed = 0
- len = length(field[1])
- for (i = 2; i < nfields; i++) {
- key = field[i]
- keylen = length(key)
- if (S_is_set[key]) {
- value = S[key]
- line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
- len += length(value) + length(field[++i])
- substed = 1
- } else
- len += 1 + keylen
- }
-
- print line
-}
-
-_ACAWK
-_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
- sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
-else
- cat
-fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
- || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
-_ACEOF
-
-# VPATH may cause trouble with some makes, so we remove sole $(srcdir),
-# ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
-# trailing colons and then remove the whole line if VPATH becomes empty
-# (actually we leave an empty line to preserve line numbers).
-if test "x$srcdir" = x.; then
- ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{
-h
-s///
-s/^/:/
-s/[ ]*$/:/
-s/:\$(srcdir):/:/g
-s/:\${srcdir}:/:/g
-s/:@srcdir@:/:/g
-s/^:*//
-s/:*$//
-x
-s/\(=[ ]*\).*/\1/
-G
-s/\n//
-s/^[^=]*=[ ]*$//
-}'
-fi
-
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-fi # test -n "$CONFIG_FILES"
-
-# Set up the scripts for CONFIG_HEADERS section.
-# No need to generate them if there are no CONFIG_HEADERS.
-# This happens for instance with `./config.status Makefile'.
-if test -n "$CONFIG_HEADERS"; then
-cat >"$ac_tmp/defines.awk" <<\_ACAWK ||
-BEGIN {
-_ACEOF
-
-# Transform confdefs.h into an awk script `defines.awk', embedded as
-# here-document in config.status, that substitutes the proper values into
-# config.h.in to produce config.h.
-
-# Create a delimiter string that does not exist in confdefs.h, to ease
-# handling of long lines.
-ac_delim='%!_!# '
-for ac_last_try in false false :; do
- ac_tt=`sed -n "/$ac_delim/p" confdefs.h`
- if test -z "$ac_tt"; then
- break
- elif $ac_last_try; then
- as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
- else
- ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
- fi
-done
-
-# For the awk script, D is an array of macro values keyed by name,
-# likewise P contains macro parameters if any. Preserve backslash
-# newline sequences.
-
-ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
-sed -n '
-s/.\{148\}/&'"$ac_delim"'/g
-t rset
-:rset
-s/^[ ]*#[ ]*define[ ][ ]*/ /
-t def
-d
-:def
-s/\\$//
-t bsnl
-s/["\\]/\\&/g
-s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
-D["\1"]=" \3"/p
-s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
-d
-:bsnl
-s/["\\]/\\&/g
-s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
-D["\1"]=" \3\\\\\\n"\\/p
-t cont
-s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
-t cont
-d
-:cont
-n
-s/.\{148\}/&'"$ac_delim"'/g
-t clear
-:clear
-s/\\$//
-t bsnlc
-s/["\\]/\\&/g; s/^/"/; s/$/"/p
-d
-:bsnlc
-s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
-b cont
-' <confdefs.h | sed '
-s/'"$ac_delim"'/"\\\
-"/g' >>$CONFIG_STATUS || ac_write_fail=1
-
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
- for (key in D) D_is_set[key] = 1
- FS = ""
-}
-/^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
- line = \$ 0
- split(line, arg, " ")
- if (arg[1] == "#") {
- defundef = arg[2]
- mac1 = arg[3]
- } else {
- defundef = substr(arg[1], 2)
- mac1 = arg[2]
- }
- split(mac1, mac2, "(") #)
- macro = mac2[1]
- prefix = substr(line, 1, index(line, defundef) - 1)
- if (D_is_set[macro]) {
- # Preserve the white space surrounding the "#".
- print prefix "define", macro P[macro] D[macro]
- next
- } else {
- # Replace #undef with comments. This is necessary, for example,
- # in the case of _POSIX_SOURCE, which is predefined and required
- # on some systems where configure will not decide to define it.
- if (defundef == "undef") {
- print "/*", prefix defundef, macro, "*/"
- next
- }
- }
-}
-{ print }
-_ACAWK
-_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
- as_fn_error $? "could not setup config headers machinery" "$LINENO" 5
-fi # test -n "$CONFIG_HEADERS"
-
-
-eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS"
-shift
-for ac_tag
-do
- case $ac_tag in
- :[FHLC]) ac_mode=$ac_tag; continue;;
- esac
- case $ac_mode$ac_tag in
- :[FHL]*:*);;
- :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
- :[FH]-) ac_tag=-:-;;
- :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
- esac
- ac_save_IFS=$IFS
- IFS=:
- set x $ac_tag
- IFS=$ac_save_IFS
- shift
- ac_file=$1
- shift
-
- case $ac_mode in
- :L) ac_source=$1;;
- :[FH])
- ac_file_inputs=
- for ac_f
- do
- case $ac_f in
- -) ac_f="$ac_tmp/stdin";;
- *) # Look for the file first in the build tree, then in the source tree
- # (if the path is not absolute). The absolute path cannot be DOS-style,
- # because $ac_f cannot contain `:'.
- test -f "$ac_f" ||
- case $ac_f in
- [\\/$]*) false;;
- *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
- esac ||
- as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
- esac
- case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
- as_fn_append ac_file_inputs " '$ac_f'"
- done
-
- # Let's still pretend it is `configure' which instantiates (i.e., don't
- # use $as_me), people would be surprised to read:
- # /* config.h. Generated by config.status. */
- configure_input='Generated from '`
- $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
- `' by configure.'
- if test x"$ac_file" != x-; then
- configure_input="$ac_file. $configure_input"
- { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
-$as_echo "$as_me: creating $ac_file" >&6;}
- fi
- # Neutralize special characters interpreted by sed in replacement strings.
- case $configure_input in #(
- *\&* | *\|* | *\\* )
- ac_sed_conf_input=`$as_echo "$configure_input" |
- sed 's/[\\\\&|]/\\\\&/g'`;; #(
- *) ac_sed_conf_input=$configure_input;;
- esac
-
- case $ac_tag in
- *:-:* | *:-) cat >"$ac_tmp/stdin" \
- || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
- esac
- ;;
- esac
-
- ac_dir=`$as_dirname -- "$ac_file" ||
-$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$ac_file" : 'X\(//\)[^/]' \| \
- X"$ac_file" : 'X\(//\)$' \| \
- X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$ac_file" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
- as_dir="$ac_dir"; as_fn_mkdir_p
- ac_builddir=.
-
-case "$ac_dir" in
-.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
-*)
- ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
- # A ".." for each directory in $ac_dir_suffix.
- ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
- case $ac_top_builddir_sub in
- "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
- *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
- esac ;;
-esac
-ac_abs_top_builddir=$ac_pwd
-ac_abs_builddir=$ac_pwd$ac_dir_suffix
-# for backward compatibility:
-ac_top_builddir=$ac_top_build_prefix
-
-case $srcdir in
- .) # We are building in place.
- ac_srcdir=.
- ac_top_srcdir=$ac_top_builddir_sub
- ac_abs_top_srcdir=$ac_pwd ;;
- [\\/]* | ?:[\\/]* ) # Absolute name.
- ac_srcdir=$srcdir$ac_dir_suffix;
- ac_top_srcdir=$srcdir
- ac_abs_top_srcdir=$srcdir ;;
- *) # Relative name.
- ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
- ac_top_srcdir=$ac_top_build_prefix$srcdir
- ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
-esac
-ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
-
-
- case $ac_mode in
- :F)
- #
- # CONFIG_FILE
- #
-
- case $INSTALL in
- [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
- *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
- esac
- ac_MKDIR_P=$MKDIR_P
- case $MKDIR_P in
- [\\/$]* | ?:[\\/]* ) ;;
- */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
- esac
-_ACEOF
-
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-# If the template does not know about datarootdir, expand it.
-# FIXME: This hack should be removed a few years after 2.60.
-ac_datarootdir_hack=; ac_datarootdir_seen=
-ac_sed_dataroot='
-/datarootdir/ {
- p
- q
-}
-/@datadir@/p
-/@docdir@/p
-/@infodir@/p
-/@localedir@/p
-/@mandir@/p'
-case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
-*datarootdir*) ac_datarootdir_seen=yes;;
-*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
-$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
-_ACEOF
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
- ac_datarootdir_hack='
- s&@datadir@&$datadir&g
- s&@docdir@&$docdir&g
- s&@infodir@&$infodir&g
- s&@localedir@&$localedir&g
- s&@mandir@&$mandir&g
- s&\\\${datarootdir}&$datarootdir&g' ;;
-esac
-_ACEOF
-
-# Neutralize VPATH when `$srcdir' = `.'.
-# Shell code in configure.ac might set extrasub.
-# FIXME: do we really want to maintain this feature?
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-ac_sed_extra="$ac_vpsub
-$extrasub
-_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-:t
-/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
-s|@configure_input@|$ac_sed_conf_input|;t t
-s&@top_builddir@&$ac_top_builddir_sub&;t t
-s&@top_build_prefix@&$ac_top_build_prefix&;t t
-s&@srcdir@&$ac_srcdir&;t t
-s&@abs_srcdir@&$ac_abs_srcdir&;t t
-s&@top_srcdir@&$ac_top_srcdir&;t t
-s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
-s&@builddir@&$ac_builddir&;t t
-s&@abs_builddir@&$ac_abs_builddir&;t t
-s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
-s&@INSTALL@&$ac_INSTALL&;t t
-s&@MKDIR_P@&$ac_MKDIR_P&;t t
-$ac_datarootdir_hack
-"
-eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \
- >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
-
-test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
- { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
- { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \
- "$ac_tmp/out"`; test -z "$ac_out"; } &&
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
-which seems to be undefined. Please make sure it is defined" >&5
-$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
-which seems to be undefined. Please make sure it is defined" >&2;}
-
- rm -f "$ac_tmp/stdin"
- case $ac_file in
- -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
- *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
- esac \
- || as_fn_error $? "could not create $ac_file" "$LINENO" 5
- ;;
- :H)
- #
- # CONFIG_HEADER
- #
- if test x"$ac_file" != x-; then
- {
- $as_echo "/* $configure_input */" \
- && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs"
- } >"$ac_tmp/config.h" \
- || as_fn_error $? "could not create $ac_file" "$LINENO" 5
- if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
-$as_echo "$as_me: $ac_file is unchanged" >&6;}
- else
- rm -f "$ac_file"
- mv "$ac_tmp/config.h" "$ac_file" \
- || as_fn_error $? "could not create $ac_file" "$LINENO" 5
- fi
- else
- $as_echo "/* $configure_input */" \
- && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \
- || as_fn_error $? "could not create -" "$LINENO" 5
- fi
-# Compute "$ac_file"'s index in $config_headers.
-_am_arg="$ac_file"
-_am_stamp_count=1
-for _am_header in $config_headers :; do
- case $_am_header in
- $_am_arg | $_am_arg:* )
- break ;;
- * )
- _am_stamp_count=`expr $_am_stamp_count + 1` ;;
- esac
-done
-echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" ||
-$as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$_am_arg" : 'X\(//\)[^/]' \| \
- X"$_am_arg" : 'X\(//\)$' \| \
- X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$_am_arg" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`/stamp-h$_am_stamp_count
- ;;
-
- :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
-$as_echo "$as_me: executing $ac_file commands" >&6;}
- ;;
- esac
-
-
- case $ac_file$ac_mode in
- "depfiles":C) test x"$AMDEP_TRUE" != x"" || {
- # Older Autoconf quotes --file arguments for eval, but not when files
- # are listed without --file. Let's play safe and only enable the eval
- # if we detect the quoting.
- case $CONFIG_FILES in
- *\'*) eval set x "$CONFIG_FILES" ;;
- *) set x $CONFIG_FILES ;;
- esac
- shift
- for mf
- do
- # Strip MF so we end up with the name of the file.
- mf=`echo "$mf" | sed -e 's/:.*$//'`
- # Check whether this is an Automake generated Makefile or not.
- # We used to match only the files named 'Makefile.in', but
- # some people rename them; so instead we look at the file content.
- # Grep'ing the first line is not enough: some people post-process
- # each Makefile.in and add a new line on top of each file to say so.
- # Grep'ing the whole file is not good either: AIX grep has a line
- # limit of 2048, but all sed's we know have understand at least 4000.
- if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
- dirpart=`$as_dirname -- "$mf" ||
-$as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$mf" : 'X\(//\)[^/]' \| \
- X"$mf" : 'X\(//\)$' \| \
- X"$mf" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$mf" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
- else
- continue
- fi
- # Extract the definition of DEPDIR, am__include, and am__quote
- # from the Makefile without running 'make'.
- DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
- test -z "$DEPDIR" && continue
- am__include=`sed -n 's/^am__include = //p' < "$mf"`
- test -z "$am__include" && continue
- am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
- # Find all dependency output files, they are included files with
- # $(DEPDIR) in their names. We invoke sed twice because it is the
- # simplest approach to changing $(DEPDIR) to its actual value in the
- # expansion.
- for file in `sed -n "
- s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
- sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g'`; do
- # Make sure the directory exists.
- test -f "$dirpart/$file" && continue
- fdir=`$as_dirname -- "$file" ||
-$as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$file" : 'X\(//\)[^/]' \| \
- X"$file" : 'X\(//\)$' \| \
- X"$file" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$file" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
- as_dir=$dirpart/$fdir; as_fn_mkdir_p
- # echo "creating $dirpart/$file"
- echo '# dummy' > "$dirpart/$file"
- done
- done
-}
- ;;
- "libtool":C)
-
- # See if we are running on zsh, and set the options which allow our
- # commands through without removal of \ escapes.
- if test -n "${ZSH_VERSION+set}" ; then
- setopt NO_GLOB_SUBST
- fi
-
- cfgfile="${ofile}T"
- trap "$RM \"$cfgfile\"; exit 1" 1 2 15
- $RM "$cfgfile"
-
- cat <<_LT_EOF >> "$cfgfile"
-#! $SHELL
-
-# `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
-# Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION
-# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
-# NOTE: Changes made to this file will be lost: look at ltmain.sh.
-#
-# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
-# 2006, 2007, 2008, 2009 Free Software Foundation, Inc.
-# Written by Gordon Matzigkeit, 1996
-#
-# This file is part of GNU Libtool.
-#
-# GNU Libtool is free software; you can redistribute it and/or
-# modify it under the terms of the GNU General Public License as
-# published by the Free Software Foundation; either version 2 of
-# the License, or (at your option) any later version.
-#
-# As a special exception to the GNU General Public License,
-# if you distribute this file as part of a program or library that
-# is built using GNU Libtool, you may include this file under the
-# same distribution terms that you use for the rest of that program.
-#
-# GNU Libtool is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with GNU Libtool; see the file COPYING. If not, a copy
-# can be downloaded from http://www.gnu.org/licenses/gpl.html, or
-# obtained by writing to the Free Software Foundation, Inc.,
-# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
-
-
-# The names of the tagged configurations supported by this script.
-available_tags=""
-
-# ### BEGIN LIBTOOL CONFIG
-
-# Whether or not to build shared libraries.
-build_libtool_libs=$enable_shared
-
-# Which release of libtool.m4 was used?
-macro_version=$macro_version
-macro_revision=$macro_revision
-
-# Whether or not to build static libraries.
-build_old_libs=$enable_static
-
-# What type of objects to build.
-pic_mode=$pic_mode
-
-# Whether or not to optimize for fast installation.
-fast_install=$enable_fast_install
-
-# Shell to use when invoking shell scripts.
-SHELL=$lt_SHELL
-
-# An echo program that protects backslashes.
-ECHO=$lt_ECHO
-
-# The host system.
-host_alias=$host_alias
-host=$host
-host_os=$host_os
-
-# The build system.
-build_alias=$build_alias
-build=$build
-build_os=$build_os
-
-# A sed program that does not truncate output.
-SED=$lt_SED
-
-# Sed that helps us avoid accidentally triggering echo(1) options like -n.
-Xsed="\$SED -e 1s/^X//"
-
-# A grep program that handles long lines.
-GREP=$lt_GREP
-
-# An ERE matcher.
-EGREP=$lt_EGREP
-
-# A literal string matcher.
-FGREP=$lt_FGREP
-
-# A BSD- or MS-compatible name lister.
-NM=$lt_NM
-
-# Whether we need soft or hard links.
-LN_S=$lt_LN_S
-
-# What is the maximum length of a command?
-max_cmd_len=$max_cmd_len
-
-# Object file suffix (normally "o").
-objext=$ac_objext
-
-# Executable file suffix (normally "").
-exeext=$exeext
-
-# whether the shell understands "unset".
-lt_unset=$lt_unset
-
-# turn spaces into newlines.
-SP2NL=$lt_lt_SP2NL
-
-# turn newlines into spaces.
-NL2SP=$lt_lt_NL2SP
-
-# An object symbol dumper.
-OBJDUMP=$lt_OBJDUMP
-
-# Method to check whether dependent libraries are shared objects.
-deplibs_check_method=$lt_deplibs_check_method
-
-# Command to use when deplibs_check_method == "file_magic".
-file_magic_cmd=$lt_file_magic_cmd
-
-# The archiver.
-AR=$lt_AR
-AR_FLAGS=$lt_AR_FLAGS
-
-# A symbol stripping program.
-STRIP=$lt_STRIP
-
-# Commands used to install an old-style archive.
-RANLIB=$lt_RANLIB
-old_postinstall_cmds=$lt_old_postinstall_cmds
-old_postuninstall_cmds=$lt_old_postuninstall_cmds
-
-# Whether to use a lock for old archive extraction.
-lock_old_archive_extraction=$lock_old_archive_extraction
-
-# A C compiler.
-LTCC=$lt_CC
-
-# LTCC compiler flags.
-LTCFLAGS=$lt_CFLAGS
-
-# Take the output of nm and produce a listing of raw symbols and C names.
-global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe
-
-# Transform the output of nm in a proper C declaration.
-global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl
-
-# Transform the output of nm in a C name address pair.
-global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
-
-# Transform the output of nm in a C name address pair when lib prefix is needed.
-global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix
-
-# The name of the directory that contains temporary libtool files.
-objdir=$objdir
-
-# Used to examine libraries when file_magic_cmd begins with "file".
-MAGIC_CMD=$MAGIC_CMD
-
-# Must we lock files when doing compilation?
-need_locks=$lt_need_locks
-
-# Tool to manipulate archived DWARF debug symbol files on Mac OS X.
-DSYMUTIL=$lt_DSYMUTIL
-
-# Tool to change global to local symbols on Mac OS X.
-NMEDIT=$lt_NMEDIT
-
-# Tool to manipulate fat objects and archives on Mac OS X.
-LIPO=$lt_LIPO
-
-# ldd/readelf like tool for Mach-O binaries on Mac OS X.
-OTOOL=$lt_OTOOL
-
-# ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4.
-OTOOL64=$lt_OTOOL64
-
-# Old archive suffix (normally "a").
-libext=$libext
-
-# Shared library suffix (normally ".so").
-shrext_cmds=$lt_shrext_cmds
-
-# The commands to extract the exported symbol list from a shared archive.
-extract_expsyms_cmds=$lt_extract_expsyms_cmds
-
-# Variables whose values should be saved in libtool wrapper scripts and
-# restored at link time.
-variables_saved_for_relink=$lt_variables_saved_for_relink
-
-# Do we need the "lib" prefix for modules?
-need_lib_prefix=$need_lib_prefix
-
-# Do we need a version for libraries?
-need_version=$need_version
-
-# Library versioning type.
-version_type=$version_type
-
-# Shared library runtime path variable.
-runpath_var=$runpath_var
-
-# Shared library path variable.
-shlibpath_var=$shlibpath_var
-
-# Is shlibpath searched before the hard-coded library search path?
-shlibpath_overrides_runpath=$shlibpath_overrides_runpath
-
-# Format of library name prefix.
-libname_spec=$lt_libname_spec
-
-# List of archive names. First name is the real one, the rest are links.
-# The last name is the one that the linker finds with -lNAME
-library_names_spec=$lt_library_names_spec
-
-# The coded name of the library, if different from the real name.
-soname_spec=$lt_soname_spec
-
-# Permission mode override for installation of shared libraries.
-install_override_mode=$lt_install_override_mode
-
-# Command to use after installation of a shared archive.
-postinstall_cmds=$lt_postinstall_cmds
-
-# Command to use after uninstallation of a shared archive.
-postuninstall_cmds=$lt_postuninstall_cmds
-
-# Commands used to finish a libtool library installation in a directory.
-finish_cmds=$lt_finish_cmds
-
-# As "finish_cmds", except a single script fragment to be evaled but
-# not shown.
-finish_eval=$lt_finish_eval
-
-# Whether we should hardcode library paths into libraries.
-hardcode_into_libs=$hardcode_into_libs
-
-# Compile-time system search path for libraries.
-sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
-
-# Run-time system search path for libraries.
-sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
-
-# Whether dlopen is supported.
-dlopen_support=$enable_dlopen
-
-# Whether dlopen of programs is supported.
-dlopen_self=$enable_dlopen_self
-
-# Whether dlopen of statically linked programs is supported.
-dlopen_self_static=$enable_dlopen_self_static
-
-# Commands to strip libraries.
-old_striplib=$lt_old_striplib
-striplib=$lt_striplib
-
-
-# The linker used to build libraries.
-LD=$lt_LD
-
-# How to create reloadable object files.
-reload_flag=$lt_reload_flag
-reload_cmds=$lt_reload_cmds
-
-# Commands used to build an old-style archive.
-old_archive_cmds=$lt_old_archive_cmds
-
-# A language specific compiler.
-CC=$lt_compiler
-
-# Is the compiler the GNU compiler?
-with_gcc=$GCC
-
-# Compiler flag to turn off builtin functions.
-no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag
-
-# How to pass a linker flag through the compiler.
-wl=$lt_lt_prog_compiler_wl
-
-# Additional compiler flags for building library objects.
-pic_flag=$lt_lt_prog_compiler_pic
-
-# Compiler flag to prevent dynamic linking.
-link_static_flag=$lt_lt_prog_compiler_static
-
-# Does compiler simultaneously support -c and -o options?
-compiler_c_o=$lt_lt_cv_prog_compiler_c_o
-
-# Whether or not to add -lc for building shared libraries.
-build_libtool_need_lc=$archive_cmds_need_lc
-
-# Whether or not to disallow shared libs when runtime libs are static.
-allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes
-
-# Compiler flag to allow reflexive dlopens.
-export_dynamic_flag_spec=$lt_export_dynamic_flag_spec
-
-# Compiler flag to generate shared objects directly from archives.
-whole_archive_flag_spec=$lt_whole_archive_flag_spec
-
-# Whether the compiler copes with passing no objects directly.
-compiler_needs_object=$lt_compiler_needs_object
-
-# Create an old-style archive from a shared archive.
-old_archive_from_new_cmds=$lt_old_archive_from_new_cmds
-
-# Create a temporary old-style archive to link instead of a shared archive.
-old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds
-
-# Commands used to build a shared archive.
-archive_cmds=$lt_archive_cmds
-archive_expsym_cmds=$lt_archive_expsym_cmds
-
-# Commands used to build a loadable module if different from building
-# a shared archive.
-module_cmds=$lt_module_cmds
-module_expsym_cmds=$lt_module_expsym_cmds
-
-# Whether we are building with GNU ld or not.
-with_gnu_ld=$lt_with_gnu_ld
-
-# Flag that allows shared libraries with undefined symbols to be built.
-allow_undefined_flag=$lt_allow_undefined_flag
-
-# Flag that enforces no undefined symbols.
-no_undefined_flag=$lt_no_undefined_flag
-
-# Flag to hardcode \$libdir into a binary during linking.
-# This must work even if \$libdir does not exist
-hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec
-
-# If ld is used when linking, flag to hardcode \$libdir into a binary
-# during linking. This must work even if \$libdir does not exist.
-hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld
-
-# Whether we need a single "-rpath" flag with a separated argument.
-hardcode_libdir_separator=$lt_hardcode_libdir_separator
-
-# Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
-# DIR into the resulting binary.
-hardcode_direct=$hardcode_direct
-
-# Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
-# DIR into the resulting binary and the resulting library dependency is
-# "absolute",i.e impossible to change by setting \${shlibpath_var} if the
-# library is relocated.
-hardcode_direct_absolute=$hardcode_direct_absolute
-
-# Set to "yes" if using the -LDIR flag during linking hardcodes DIR
-# into the resulting binary.
-hardcode_minus_L=$hardcode_minus_L
-
-# Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR
-# into the resulting binary.
-hardcode_shlibpath_var=$hardcode_shlibpath_var
-
-# Set to "yes" if building a shared library automatically hardcodes DIR
-# into the library and all subsequent libraries and executables linked
-# against it.
-hardcode_automatic=$hardcode_automatic
-
-# Set to yes if linker adds runtime paths of dependent libraries
-# to runtime path list.
-inherit_rpath=$inherit_rpath
-
-# Whether libtool must link a program against all its dependency libraries.
-link_all_deplibs=$link_all_deplibs
-
-# Fix the shell variable \$srcfile for the compiler.
-fix_srcfile_path=$lt_fix_srcfile_path
-
-# Set to "yes" if exported symbols are required.
-always_export_symbols=$always_export_symbols
-
-# The commands to list exported symbols.
-export_symbols_cmds=$lt_export_symbols_cmds
-
-# Symbols that should not be listed in the preloaded symbols.
-exclude_expsyms=$lt_exclude_expsyms
-
-# Symbols that must always be exported.
-include_expsyms=$lt_include_expsyms
-
-# Commands necessary for linking programs (against libraries) with templates.
-prelink_cmds=$lt_prelink_cmds
-
-# Specify filename containing input files.
-file_list_spec=$lt_file_list_spec
-
-# How to hardcode a shared library path into an executable.
-hardcode_action=$hardcode_action
-
-# ### END LIBTOOL CONFIG
-
-_LT_EOF
-
- case $host_os in
- aix3*)
- cat <<\_LT_EOF >> "$cfgfile"
-# AIX sometimes has problems with the GCC collect2 program. For some
-# reason, if we set the COLLECT_NAMES environment variable, the problems
-# vanish in a puff of smoke.
-if test "X${COLLECT_NAMES+set}" != Xset; then
- COLLECT_NAMES=
- export COLLECT_NAMES
-fi
-_LT_EOF
- ;;
- esac
-
-
-ltmain="$ac_aux_dir/ltmain.sh"
-
-
- # We use sed instead of cat because bash on DJGPP gets confused if
- # if finds mixed CR/LF and LF-only lines. Since sed operates in
- # text mode, it properly converts lines to CR/LF. This bash problem
- # is reportedly fixed, but why not run on old versions too?
- sed '/^# Generated shell functions inserted here/q' "$ltmain" >> "$cfgfile" \
- || (rm -f "$cfgfile"; exit 1)
-
- case $xsi_shell in
- yes)
- cat << \_LT_EOF >> "$cfgfile"
-
-# func_dirname file append nondir_replacement
-# Compute the dirname of FILE. If nonempty, add APPEND to the result,
-# otherwise set result to NONDIR_REPLACEMENT.
-func_dirname ()
-{
- case ${1} in
- */*) func_dirname_result="${1%/*}${2}" ;;
- * ) func_dirname_result="${3}" ;;
- esac
-}
-
-# func_basename file
-func_basename ()
-{
- func_basename_result="${1##*/}"
-}
-
-# func_dirname_and_basename file append nondir_replacement
-# perform func_basename and func_dirname in a single function
-# call:
-# dirname: Compute the dirname of FILE. If nonempty,
-# add APPEND to the result, otherwise set result
-# to NONDIR_REPLACEMENT.
-# value returned in "$func_dirname_result"
-# basename: Compute filename of FILE.
-# value retuned in "$func_basename_result"
-# Implementation must be kept synchronized with func_dirname
-# and func_basename. For efficiency, we do not delegate to
-# those functions but instead duplicate the functionality here.
-func_dirname_and_basename ()
-{
- case ${1} in
- */*) func_dirname_result="${1%/*}${2}" ;;
- * ) func_dirname_result="${3}" ;;
- esac
- func_basename_result="${1##*/}"
-}
-
-# func_stripname prefix suffix name
-# strip PREFIX and SUFFIX off of NAME.
-# PREFIX and SUFFIX must not contain globbing or regex special
-# characters, hashes, percent signs, but SUFFIX may contain a leading
-# dot (in which case that matches only a dot).
-func_stripname ()
-{
- # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are
- # positional parameters, so assign one to ordinary parameter first.
- func_stripname_result=${3}
- func_stripname_result=${func_stripname_result#"${1}"}
- func_stripname_result=${func_stripname_result%"${2}"}
-}
-
-# func_opt_split
-func_opt_split ()
-{
- func_opt_split_opt=${1%%=*}
- func_opt_split_arg=${1#*=}
-}
-
-# func_lo2o object
-func_lo2o ()
-{
- case ${1} in
- *.lo) func_lo2o_result=${1%.lo}.${objext} ;;
- *) func_lo2o_result=${1} ;;
- esac
-}
-
-# func_xform libobj-or-source
-func_xform ()
-{
- func_xform_result=${1%.*}.lo
-}
-
-# func_arith arithmetic-term...
-func_arith ()
-{
- func_arith_result=$(( $* ))
-}
-
-# func_len string
-# STRING may not start with a hyphen.
-func_len ()
-{
- func_len_result=${#1}
-}
-
-_LT_EOF
- ;;
- *) # Bourne compatible functions.
- cat << \_LT_EOF >> "$cfgfile"
-
-# func_dirname file append nondir_replacement
-# Compute the dirname of FILE. If nonempty, add APPEND to the result,
-# otherwise set result to NONDIR_REPLACEMENT.
-func_dirname ()
-{
- # Extract subdirectory from the argument.
- func_dirname_result=`$ECHO "${1}" | $SED "$dirname"`
- if test "X$func_dirname_result" = "X${1}"; then
- func_dirname_result="${3}"
- else
- func_dirname_result="$func_dirname_result${2}"
- fi
-}
-
-# func_basename file
-func_basename ()
-{
- func_basename_result=`$ECHO "${1}" | $SED "$basename"`
-}
-
-
-# func_stripname prefix suffix name
-# strip PREFIX and SUFFIX off of NAME.
-# PREFIX and SUFFIX must not contain globbing or regex special
-# characters, hashes, percent signs, but SUFFIX may contain a leading
-# dot (in which case that matches only a dot).
-# func_strip_suffix prefix name
-func_stripname ()
-{
- case ${2} in
- .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;;
- *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;;
- esac
-}
-
-# sed scripts:
-my_sed_long_opt='1s/^\(-[^=]*\)=.*/\1/;q'
-my_sed_long_arg='1s/^-[^=]*=//'
-
-# func_opt_split
-func_opt_split ()
-{
- func_opt_split_opt=`$ECHO "${1}" | $SED "$my_sed_long_opt"`
- func_opt_split_arg=`$ECHO "${1}" | $SED "$my_sed_long_arg"`
-}
-
-# func_lo2o object
-func_lo2o ()
-{
- func_lo2o_result=`$ECHO "${1}" | $SED "$lo2o"`
-}
-
-# func_xform libobj-or-source
-func_xform ()
-{
- func_xform_result=`$ECHO "${1}" | $SED 's/\.[^.]*$/.lo/'`
-}
-
-# func_arith arithmetic-term...
-func_arith ()
-{
- func_arith_result=`expr "$@"`
-}
-
-# func_len string
-# STRING may not start with a hyphen.
-func_len ()
-{
- func_len_result=`expr "$1" : ".*" 2>/dev/null || echo $max_cmd_len`
-}
-
-_LT_EOF
-esac
-
-case $lt_shell_append in
- yes)
- cat << \_LT_EOF >> "$cfgfile"
-
-# func_append var value
-# Append VALUE to the end of shell variable VAR.
-func_append ()
-{
- eval "$1+=\$2"
-}
-_LT_EOF
- ;;
- *)
- cat << \_LT_EOF >> "$cfgfile"
-
-# func_append var value
-# Append VALUE to the end of shell variable VAR.
-func_append ()
-{
- eval "$1=\$$1\$2"
-}
-
-_LT_EOF
- ;;
- esac
-
-
- sed -n '/^# Generated shell functions inserted here/,$p' "$ltmain" >> "$cfgfile" \
- || (rm -f "$cfgfile"; exit 1)
-
- mv -f "$cfgfile" "$ofile" ||
- (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
- chmod +x "$ofile"
-
- ;;
- "default-1":C)
- for ac_file in $CONFIG_FILES; do
- # Support "outfile[:infile[:infile...]]"
- case "$ac_file" in
- *:*) ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
- esac
- # PO directories have a Makefile.in generated from Makefile.in.in.
- case "$ac_file" in */Makefile.in)
- # Adjust a relative srcdir.
- ac_dir=`echo "$ac_file"|sed 's%/[^/][^/]*$%%'`
- ac_dir_suffix=/`echo "$ac_dir"|sed 's%^\./%%'`
- ac_dots=`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'`
- # In autoconf-2.13 it is called $ac_given_srcdir.
- # In autoconf-2.50 it is called $srcdir.
- test -n "$ac_given_srcdir" || ac_given_srcdir="$srcdir"
- case "$ac_given_srcdir" in
- .) top_srcdir=`echo $ac_dots|sed 's%/$%%'` ;;
- /*) top_srcdir="$ac_given_srcdir" ;;
- *) top_srcdir="$ac_dots$ac_given_srcdir" ;;
- esac
- if test -f "$ac_given_srcdir/$ac_dir/POTFILES.in"; then
- rm -f "$ac_dir/POTFILES"
- test -n "$as_me" && echo "$as_me: creating $ac_dir/POTFILES" || echo "creating $ac_dir/POTFILES"
- cat "$ac_given_srcdir/$ac_dir/POTFILES.in" | sed -e "/^#/d" -e "/^[ ]*\$/d" -e "s,.*, $top_srcdir/& \\\\," | sed -e "\$s/\(.*\) \\\\/\1/" > "$ac_dir/POTFILES"
- POMAKEFILEDEPS="POTFILES.in"
- # ALL_LINGUAS, POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES depend
- # on $ac_dir but don't depend on user-specified configuration
- # parameters.
- if test -f "$ac_given_srcdir/$ac_dir/LINGUAS"; then
- # The LINGUAS file contains the set of available languages.
- if test -n "$OBSOLETE_ALL_LINGUAS"; then
- test -n "$as_me" && echo "$as_me: setting ALL_LINGUAS in configure.ac is obsolete" || echo "setting ALL_LINGUAS in configure.ac is obsolete"
- fi
- ALL_LINGUAS_=`sed -e "/^#/d" "$ac_given_srcdir/$ac_dir/LINGUAS"`
- # Hide the ALL_LINGUAS assigment from automake.
- eval 'ALL_LINGUAS''=$ALL_LINGUAS_'
- POMAKEFILEDEPS="$POMAKEFILEDEPS LINGUAS"
- else
- # The set of available languages was given in configure.ac.
- eval 'ALL_LINGUAS''=$OBSOLETE_ALL_LINGUAS'
- fi
- case "$ac_given_srcdir" in
- .) srcdirpre= ;;
- *) srcdirpre='$(srcdir)/' ;;
- esac
- POFILES=
- GMOFILES=
- UPDATEPOFILES=
- DUMMYPOFILES=
- for lang in $ALL_LINGUAS; do
- POFILES="$POFILES $srcdirpre$lang.po"
- GMOFILES="$GMOFILES $srcdirpre$lang.gmo"
- UPDATEPOFILES="$UPDATEPOFILES $lang.po-update"
- DUMMYPOFILES="$DUMMYPOFILES $lang.nop"
- done
- # CATALOGS depends on both $ac_dir and the user's LINGUAS
- # environment variable.
- INST_LINGUAS=
- if test -n "$ALL_LINGUAS"; then
- for presentlang in $ALL_LINGUAS; do
- useit=no
- if test "%UNSET%" != "$LINGUAS"; then
- desiredlanguages="$LINGUAS"
- else
- desiredlanguages="$ALL_LINGUAS"
- fi
- for desiredlang in $desiredlanguages; do
- # Use the presentlang catalog if desiredlang is
- # a. equal to presentlang, or
- # b. a variant of presentlang (because in this case,
- # presentlang can be used as a fallback for messages
- # which are not translated in the desiredlang catalog).
- case "$desiredlang" in
- "$presentlang"*) useit=yes;;
- esac
- done
- if test $useit = yes; then
- INST_LINGUAS="$INST_LINGUAS $presentlang"
- fi
- done
- fi
- CATALOGS=
- if test -n "$INST_LINGUAS"; then
- for lang in $INST_LINGUAS; do
- CATALOGS="$CATALOGS $lang.gmo"
- done
- fi
- test -n "$as_me" && echo "$as_me: creating $ac_dir/Makefile" || echo "creating $ac_dir/Makefile"
- sed -e "/^POTFILES =/r $ac_dir/POTFILES" -e "/^# Makevars/r $ac_given_srcdir/$ac_dir/Makevars" -e "s|@POFILES@|$POFILES|g" -e "s|@GMOFILES@|$GMOFILES|g" -e "s|@UPDATEPOFILES@|$UPDATEPOFILES|g" -e "s|@DUMMYPOFILES@|$DUMMYPOFILES|g" -e "s|@CATALOGS@|$CATALOGS|g" -e "s|@POMAKEFILEDEPS@|$POMAKEFILEDEPS|g" "$ac_dir/Makefile.in" > "$ac_dir/Makefile"
- for f in "$ac_given_srcdir/$ac_dir"/Rules-*; do
- if test -f "$f"; then
- case "$f" in
- *.orig | *.bak | *~) ;;
- *) cat "$f" >> "$ac_dir/Makefile" ;;
- esac
- fi
- done
- fi
- ;;
- esac
- done ;;
- "default-2":C)
- for ac_file in $CONFIG_FILES; do
- # Support "outfile[:infile[:infile...]]"
- case "$ac_file" in
- *:*) ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
- esac
- # PO directories have a Makefile.in generated from Makefile.in.in.
- case "$ac_file" in */Makefile.in)
- # Adjust a relative srcdir.
- ac_dir=`echo "$ac_file"|sed 's%/[^/][^/]*$%%'`
- ac_dir_suffix=/`echo "$ac_dir"|sed 's%^\./%%'`
- ac_dots=`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'`
- # In autoconf-2.13 it is called $ac_given_srcdir.
- # In autoconf-2.50 it is called $srcdir.
- test -n "$ac_given_srcdir" || ac_given_srcdir="$srcdir"
- case "$ac_given_srcdir" in
- .) top_srcdir=`echo $ac_dots|sed 's%/$%%'` ;;
- /*) top_srcdir="$ac_given_srcdir" ;;
- *) top_srcdir="$ac_dots$ac_given_srcdir" ;;
- esac
- if test -f "$ac_given_srcdir/$ac_dir/POTFILES.in"; then
- rm -f "$ac_dir/POTFILES"
- test -n "$as_me" && echo "$as_me: creating $ac_dir/POTFILES" || echo "creating $ac_dir/POTFILES"
- cat "$ac_given_srcdir/$ac_dir/POTFILES.in" | sed -e "/^#/d" -e "/^[ ]*\$/d" -e "s,.*, $top_srcdir/& \\\\," | sed -e "\$s/\(.*\) \\\\/\1/" > "$ac_dir/POTFILES"
- POMAKEFILEDEPS="POTFILES.in"
- # ALL_LINGUAS, POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES depend
- # on $ac_dir but don't depend on user-specified configuration
- # parameters.
- if test -f "$ac_given_srcdir/$ac_dir/LINGUAS"; then
- # The LINGUAS file contains the set of available languages.
- if test -n "$OBSOLETE_ALL_LINGUAS"; then
- test -n "$as_me" && echo "$as_me: setting ALL_LINGUAS in configure.ac is obsolete" || echo "setting ALL_LINGUAS in configure.ac is obsolete"
- fi
- ALL_LINGUAS_=`sed -e "/^#/d" "$ac_given_srcdir/$ac_dir/LINGUAS"`
- # Hide the ALL_LINGUAS assigment from automake.
- eval 'ALL_LINGUAS''=$ALL_LINGUAS_'
- POMAKEFILEDEPS="$POMAKEFILEDEPS LINGUAS"
- else
- # The set of available languages was given in configure.ac.
- eval 'ALL_LINGUAS''=$OBSOLETE_ALL_LINGUAS'
- fi
- case "$ac_given_srcdir" in
- .) srcdirpre= ;;
- *) srcdirpre='$(srcdir)/' ;;
- esac
- POFILES=
- GMOFILES=
- UPDATEPOFILES=
- DUMMYPOFILES=
- for lang in $ALL_LINGUAS; do
- POFILES="$POFILES $srcdirpre$lang.po"
- GMOFILES="$GMOFILES $srcdirpre$lang.gmo"
- UPDATEPOFILES="$UPDATEPOFILES $lang.po-update"
- DUMMYPOFILES="$DUMMYPOFILES $lang.nop"
- done
- # CATALOGS depends on both $ac_dir and the user's LINGUAS
- # environment variable.
- INST_LINGUAS=
- if test -n "$ALL_LINGUAS"; then
- for presentlang in $ALL_LINGUAS; do
- useit=no
- if test "%UNSET%" != "$LINGUAS"; then
- desiredlanguages="$LINGUAS"
- else
- desiredlanguages="$ALL_LINGUAS"
- fi
- for desiredlang in $desiredlanguages; do
- # Use the presentlang catalog if desiredlang is
- # a. equal to presentlang, or
- # b. a variant of presentlang (because in this case,
- # presentlang can be used as a fallback for messages
- # which are not translated in the desiredlang catalog).
- case "$desiredlang" in
- "$presentlang"*) useit=yes;;
- esac
- done
- if test $useit = yes; then
- INST_LINGUAS="$INST_LINGUAS $presentlang"
- fi
- done
- fi
- CATALOGS=
- if test -n "$INST_LINGUAS"; then
- for lang in $INST_LINGUAS; do
- CATALOGS="$CATALOGS $lang.gmo"
- done
- fi
- test -n "$as_me" && echo "$as_me: creating $ac_dir/Makefile" || echo "creating $ac_dir/Makefile"
- sed -e "/^POTFILES =/r $ac_dir/POTFILES" -e "/^# Makevars/r $ac_given_srcdir/$ac_dir/Makevars" -e "s|@POFILES@|$POFILES|g" -e "s|@GMOFILES@|$GMOFILES|g" -e "s|@UPDATEPOFILES@|$UPDATEPOFILES|g" -e "s|@DUMMYPOFILES@|$DUMMYPOFILES|g" -e "s|@CATALOGS@|$CATALOGS|g" -e "s|@POMAKEFILEDEPS@|$POMAKEFILEDEPS|g" "$ac_dir/Makefile.in" > "$ac_dir/Makefile"
- for f in "$ac_given_srcdir/$ac_dir"/Rules-*; do
- if test -f "$f"; then
- case "$f" in
- *.orig | *.bak | *~) ;;
- *) cat "$f" >> "$ac_dir/Makefile" ;;
- esac
- fi
- done
- fi
- ;;
- esac
- done ;;
- "default":C)
-case "$srcdir" in
- .) srcdirpre= ;;
- *) srcdirpre='$(srcdir)/' ;;
-esac
-POFILES=
-GMOFILES=
-for lang in dummy $OBSOLETE_ALL_LINGUAS; do
- if test $lang != dummy; then
- POFILES="$POFILES $srcdirpre$lang.po"
- GMOFILES="$GMOFILES $srcdirpre$lang.gmo"
- fi
-done
-sed -e '/SRC-POTFILES =/r po/SRC-POTFILES' \
- -e '/BLD-POTFILES =/r po/BLD-POTFILES' \
- -e "s,@POFILES@,$POFILES," \
- -e "s,@GMOFILES@,$GMOFILES," \
- po/Makefile.in > po/Makefile ;;
-
- esac
-done # for ac_tag
-
-
-as_fn_exit 0
-_ACEOF
-ac_clean_files=$ac_clean_files_save
-
-test $ac_write_fail = 0 ||
- as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
-
-
-# configure is writing to config.log, and then calls config.status.
-# config.status does its own redirection, appending to config.log.
-# Unfortunately, on DOS this fails, as config.log is still kept open
-# by configure, so config.status won't be able to write to it; its
-# output is simply discarded. So we exec the FD to /dev/null,
-# effectively closing config.log, so it can be properly (re)opened and
-# appended to by config.status. When coming back to configure, we
-# need to make the FD available again.
-if test "$no_create" != yes; then
- ac_cs_success=:
- ac_config_status_args=
- test "$silent" = yes &&
- ac_config_status_args="$ac_config_status_args --quiet"
- exec 5>/dev/null
- $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
- exec 5>>config.log
- # Use ||, not &&, to avoid exiting from the if with $? = 1, which
- # would make configure fail if this is the last instruction.
- $ac_cs_success || as_fn_exit 1
-fi
-if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
-$as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
-fi
-
-
-
-touch config.status.tmp
-if touch --reference=config.status config.status.tmp > /dev/null 2>&1; then
- sed '/as_fn_exit 0/i \
-sed -e \"s/^\t\\\(\\\$(AM_V_CCLD)\\\)/\t+ \\\1/\" Makefile > Makefile.tmp \
-touch --reference=Makefile Makefile.tmp \
-mv Makefile.tmp Makefile \
-' config.status > config.status.tmp
- touch --reference=config.status config.status.tmp
- mv config.status.tmp config.status
- chmod +x config.status
- sed -e "s/^\t\(\$(AM_V_CCLD)\)/\t+ \1/" Makefile > Makefile.tmp
- touch --reference=Makefile Makefile.tmp
- mv Makefile.tmp Makefile
-else
- rm -f config.status.tmp
-fi
Property changes on: sources/GNU/binutils/create-2.43.1-libtool-lib64-patch/binutils-2.43.1-new/bfd/configure
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: sources/GNU/binutils/create-2.43.1-libtool-lib64-patch/binutils-2.43.1-new/opcodes/configure
===================================================================
--- sources/GNU/binutils/create-2.43.1-libtool-lib64-patch/binutils-2.43.1-new/opcodes/configure (revision 75)
+++ sources/GNU/binutils/create-2.43.1-libtool-lib64-patch/binutils-2.43.1-new/opcodes/configure (nonexistent)
@@ -1,17220 +0,0 @@
-#! /bin/sh
-# Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.69 for opcodes 2.43.1.
-#
-#
-# Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc.
-#
-#
-# This configure script is free software; the Free Software Foundation
-# gives unlimited permission to copy, distribute and modify it.
-## -------------------- ##
-## M4sh Initialization. ##
-## -------------------- ##
-
-# Be more Bourne compatible
-DUALCASE=1; export DUALCASE # for MKS sh
-if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
- emulate sh
- NULLCMD=:
- # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
- # is contrary to our usage. Disable this feature.
- alias -g '${1+"$@"}'='"$@"'
- setopt NO_GLOB_SUBST
-else
- case `(set -o) 2>/dev/null` in #(
- *posix*) :
- set -o posix ;; #(
- *) :
- ;;
-esac
-fi
-
-
-as_nl='
-'
-export as_nl
-# Printing a long string crashes Solaris 7 /usr/bin/printf.
-as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
-as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
-as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
-# Prefer a ksh shell builtin over an external printf program on Solaris,
-# but without wasting forks for bash or zsh.
-if test -z "$BASH_VERSION$ZSH_VERSION" \
- && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
- as_echo='print -r --'
- as_echo_n='print -rn --'
-elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
- as_echo='printf %s\n'
- as_echo_n='printf %s'
-else
- if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
- as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
- as_echo_n='/usr/ucb/echo -n'
- else
- as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
- as_echo_n_body='eval
- arg=$1;
- case $arg in #(
- *"$as_nl"*)
- expr "X$arg" : "X\\(.*\\)$as_nl";
- arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
- esac;
- expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
- '
- export as_echo_n_body
- as_echo_n='sh -c $as_echo_n_body as_echo'
- fi
- export as_echo_body
- as_echo='sh -c $as_echo_body as_echo'
-fi
-
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- PATH_SEPARATOR=:
- (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
- (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
- PATH_SEPARATOR=';'
- }
-fi
-
-
-# IFS
-# We need space, tab and new line, in precisely that order. Quoting is
-# there to prevent editors from complaining about space-tab.
-# (If _AS_PATH_WALK were called with IFS unset, it would disable word
-# splitting by setting IFS to empty value.)
-IFS=" "" $as_nl"
-
-# Find who we are. Look in the path if we contain no directory separator.
-as_myself=
-case $0 in #((
- *[\\/]* ) as_myself=$0 ;;
- *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
- done
-IFS=$as_save_IFS
-
- ;;
-esac
-# We did not find ourselves, most probably we were run as `sh COMMAND'
-# in which case we are not to be found in the path.
-if test "x$as_myself" = x; then
- as_myself=$0
-fi
-if test ! -f "$as_myself"; then
- $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
- exit 1
-fi
-
-# Unset variables that we do not need and which cause bugs (e.g. in
-# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
-# suppresses any "Segmentation fault" message there. '((' could
-# trigger a bug in pdksh 5.2.14.
-for as_var in BASH_ENV ENV MAIL MAILPATH
-do eval test x\${$as_var+set} = xset \
- && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
-done
-PS1='$ '
-PS2='> '
-PS4='+ '
-
-# NLS nuisances.
-LC_ALL=C
-export LC_ALL
-LANGUAGE=C
-export LANGUAGE
-
-# CDPATH.
-(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
-
-# Use a proper internal environment variable to ensure we don't fall
- # into an infinite loop, continuously re-executing ourselves.
- if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then
- _as_can_reexec=no; export _as_can_reexec;
- # We cannot yet assume a decent shell, so we have to provide a
-# neutralization value for shells without unset; and this also
-# works around shells that cannot unset nonexistent variables.
-# Preserve -v and -x to the replacement shell.
-BASH_ENV=/dev/null
-ENV=/dev/null
-(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
-case $- in # ((((
- *v*x* | *x*v* ) as_opts=-vx ;;
- *v* ) as_opts=-v ;;
- *x* ) as_opts=-x ;;
- * ) as_opts= ;;
-esac
-exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
-# Admittedly, this is quite paranoid, since all the known shells bail
-# out after a failed `exec'.
-$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
-as_fn_exit 255
- fi
- # We don't want this to propagate to other subprocesses.
- { _as_can_reexec=; unset _as_can_reexec;}
-if test "x$CONFIG_SHELL" = x; then
- as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
- emulate sh
- NULLCMD=:
- # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
- # is contrary to our usage. Disable this feature.
- alias -g '\${1+\"\$@\"}'='\"\$@\"'
- setopt NO_GLOB_SUBST
-else
- case \`(set -o) 2>/dev/null\` in #(
- *posix*) :
- set -o posix ;; #(
- *) :
- ;;
-esac
-fi
-"
- as_required="as_fn_return () { (exit \$1); }
-as_fn_success () { as_fn_return 0; }
-as_fn_failure () { as_fn_return 1; }
-as_fn_ret_success () { return 0; }
-as_fn_ret_failure () { return 1; }
-
-exitcode=0
-as_fn_success || { exitcode=1; echo as_fn_success failed.; }
-as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
-as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
-as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
-if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
-
-else
- exitcode=1; echo positional parameters were not saved.
-fi
-test x\$exitcode = x0 || exit 1
-test -x / || exit 1"
- as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
- as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
- eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
- test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
-test \$(( 1 + 1 )) = 2 || exit 1
-
- test -n \"\${ZSH_VERSION+set}\${BASH_VERSION+set}\" || (
- ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
- ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO
- ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO
- PATH=/empty FPATH=/empty; export PATH FPATH
- test \"X\`printf %s \$ECHO\`\" = \"X\$ECHO\" \\
- || test \"X\`print -r -- \$ECHO\`\" = \"X\$ECHO\" ) || exit 1"
- if (eval "$as_required") 2>/dev/null; then :
- as_have_required=yes
-else
- as_have_required=no
-fi
- if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
-
-else
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-as_found=false
-for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- as_found=:
- case $as_dir in #(
- /*)
- for as_base in sh bash ksh sh5; do
- # Try only shells that exist, to save several forks.
- as_shell=$as_dir/$as_base
- if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
- { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
- CONFIG_SHELL=$as_shell as_have_required=yes
- if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
- break 2
-fi
-fi
- done;;
- esac
- as_found=false
-done
-$as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
- { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
- CONFIG_SHELL=$SHELL as_have_required=yes
-fi; }
-IFS=$as_save_IFS
-
-
- if test "x$CONFIG_SHELL" != x; then :
- export CONFIG_SHELL
- # We cannot yet assume a decent shell, so we have to provide a
-# neutralization value for shells without unset; and this also
-# works around shells that cannot unset nonexistent variables.
-# Preserve -v and -x to the replacement shell.
-BASH_ENV=/dev/null
-ENV=/dev/null
-(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
-case $- in # ((((
- *v*x* | *x*v* ) as_opts=-vx ;;
- *v* ) as_opts=-v ;;
- *x* ) as_opts=-x ;;
- * ) as_opts= ;;
-esac
-exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
-# Admittedly, this is quite paranoid, since all the known shells bail
-# out after a failed `exec'.
-$as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2
-exit 255
-fi
-
- if test x$as_have_required = xno; then :
- $as_echo "$0: This script requires a shell more modern than all"
- $as_echo "$0: the shells that I found on your system."
- if test x${ZSH_VERSION+set} = xset ; then
- $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
- $as_echo "$0: be upgraded to zsh 4.3.4 or later."
- else
- $as_echo "$0: Please tell bug-autoconf@gnu.org about your system,
-$0: including any error possibly output before this
-$0: message. Then install a modern shell, or manually run
-$0: the script under such a shell if you do have one."
- fi
- exit 1
-fi
-fi
-fi
-SHELL=${CONFIG_SHELL-/bin/sh}
-export SHELL
-# Unset more variables known to interfere with behavior of common tools.
-CLICOLOR_FORCE= GREP_OPTIONS=
-unset CLICOLOR_FORCE GREP_OPTIONS
-
-## --------------------- ##
-## M4sh Shell Functions. ##
-## --------------------- ##
-# as_fn_unset VAR
-# ---------------
-# Portably unset VAR.
-as_fn_unset ()
-{
- { eval $1=; unset $1;}
-}
-as_unset=as_fn_unset
-
-# as_fn_set_status STATUS
-# -----------------------
-# Set $? to STATUS, without forking.
-as_fn_set_status ()
-{
- return $1
-} # as_fn_set_status
-
-# as_fn_exit STATUS
-# -----------------
-# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
-as_fn_exit ()
-{
- set +e
- as_fn_set_status $1
- exit $1
-} # as_fn_exit
-
-# as_fn_mkdir_p
-# -------------
-# Create "$as_dir" as a directory, including parents if necessary.
-as_fn_mkdir_p ()
-{
-
- case $as_dir in #(
- -*) as_dir=./$as_dir;;
- esac
- test -d "$as_dir" || eval $as_mkdir_p || {
- as_dirs=
- while :; do
- case $as_dir in #(
- *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
- *) as_qdir=$as_dir;;
- esac
- as_dirs="'$as_qdir' $as_dirs"
- as_dir=`$as_dirname -- "$as_dir" ||
-$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$as_dir" : 'X\(//\)[^/]' \| \
- X"$as_dir" : 'X\(//\)$' \| \
- X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$as_dir" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
- test -d "$as_dir" && break
- done
- test -z "$as_dirs" || eval "mkdir $as_dirs"
- } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
-
-
-} # as_fn_mkdir_p
-
-# as_fn_executable_p FILE
-# -----------------------
-# Test if FILE is an executable regular file.
-as_fn_executable_p ()
-{
- test -f "$1" && test -x "$1"
-} # as_fn_executable_p
-# as_fn_append VAR VALUE
-# ----------------------
-# Append the text in VALUE to the end of the definition contained in VAR. Take
-# advantage of any shell optimizations that allow amortized linear growth over
-# repeated appends, instead of the typical quadratic growth present in naive
-# implementations.
-if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
- eval 'as_fn_append ()
- {
- eval $1+=\$2
- }'
-else
- as_fn_append ()
- {
- eval $1=\$$1\$2
- }
-fi # as_fn_append
-
-# as_fn_arith ARG...
-# ------------------
-# Perform arithmetic evaluation on the ARGs, and store the result in the
-# global $as_val. Take advantage of shells that can avoid forks. The arguments
-# must be portable across $(()) and expr.
-if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
- eval 'as_fn_arith ()
- {
- as_val=$(( $* ))
- }'
-else
- as_fn_arith ()
- {
- as_val=`expr "$@" || test $? -eq 1`
- }
-fi # as_fn_arith
-
-
-# as_fn_error STATUS ERROR [LINENO LOG_FD]
-# ----------------------------------------
-# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
-# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
-# script with STATUS, using 1 if that was 0.
-as_fn_error ()
-{
- as_status=$1; test $as_status -eq 0 && as_status=1
- if test "$4"; then
- as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
- fi
- $as_echo "$as_me: error: $2" >&2
- as_fn_exit $as_status
-} # as_fn_error
-
-if expr a : '\(a\)' >/dev/null 2>&1 &&
- test "X`expr 00001 : '.*\(...\)'`" = X001; then
- as_expr=expr
-else
- as_expr=false
-fi
-
-if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
- as_basename=basename
-else
- as_basename=false
-fi
-
-if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
- as_dirname=dirname
-else
- as_dirname=false
-fi
-
-as_me=`$as_basename -- "$0" ||
-$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
- X"$0" : 'X\(//\)$' \| \
- X"$0" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X/"$0" |
- sed '/^.*\/\([^/][^/]*\)\/*$/{
- s//\1/
- q
- }
- /^X\/\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\/\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
-
-# Avoid depending upon Character Ranges.
-as_cr_letters='abcdefghijklmnopqrstuvwxyz'
-as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
-as_cr_Letters=$as_cr_letters$as_cr_LETTERS
-as_cr_digits='0123456789'
-as_cr_alnum=$as_cr_Letters$as_cr_digits
-
-
- as_lineno_1=$LINENO as_lineno_1a=$LINENO
- as_lineno_2=$LINENO as_lineno_2a=$LINENO
- eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
- test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
- # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-)
- sed -n '
- p
- /[$]LINENO/=
- ' <$as_myself |
- sed '
- s/[$]LINENO.*/&-/
- t lineno
- b
- :lineno
- N
- :loop
- s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
- t loop
- s/-\n.*//
- ' >$as_me.lineno &&
- chmod +x "$as_me.lineno" ||
- { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
-
- # If we had to re-execute with $CONFIG_SHELL, we're ensured to have
- # already done that, so ensure we don't try to do so again and fall
- # in an infinite loop. This has already happened in practice.
- _as_can_reexec=no; export _as_can_reexec
- # Don't try to exec as it changes $[0], causing all sort of problems
- # (the dirname of $[0] is not the place where we might find the
- # original and so on. Autoconf is especially sensitive to this).
- . "./$as_me.lineno"
- # Exit status is that of the last command.
- exit
-}
-
-ECHO_C= ECHO_N= ECHO_T=
-case `echo -n x` in #(((((
--n*)
- case `echo 'xy\c'` in
- *c*) ECHO_T=' ';; # ECHO_T is single tab character.
- xy) ECHO_C='\c';;
- *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
- ECHO_T=' ';;
- esac;;
-*)
- ECHO_N='-n';;
-esac
-
-rm -f conf$$ conf$$.exe conf$$.file
-if test -d conf$$.dir; then
- rm -f conf$$.dir/conf$$.file
-else
- rm -f conf$$.dir
- mkdir conf$$.dir 2>/dev/null
-fi
-if (echo >conf$$.file) 2>/dev/null; then
- if ln -s conf$$.file conf$$ 2>/dev/null; then
- as_ln_s='ln -s'
- # ... but there are two gotchas:
- # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
- # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
- # In both cases, we have to default to `cp -pR'.
- ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
- as_ln_s='cp -pR'
- elif ln conf$$.file conf$$ 2>/dev/null; then
- as_ln_s=ln
- else
- as_ln_s='cp -pR'
- fi
-else
- as_ln_s='cp -pR'
-fi
-rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
-rmdir conf$$.dir 2>/dev/null
-
-if mkdir -p . 2>/dev/null; then
- as_mkdir_p='mkdir -p "$as_dir"'
-else
- test -d ./-p && rmdir ./-p
- as_mkdir_p=false
-fi
-
-as_test_x='test -x'
-as_executable_p=as_fn_executable_p
-
-# Sed expression to map a string onto a valid CPP name.
-as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
-
-# Sed expression to map a string onto a valid variable name.
-as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
-
-SHELL=${CONFIG_SHELL-/bin/sh}
-
-
-test -n "$DJDIR" || exec 7<&0 </dev/null
-exec 6>&1
-
-# Name of the host.
-# hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status,
-# so uname gets run too.
-ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
-
-#
-# Initializations.
-#
-ac_default_prefix=/usr/local
-ac_clean_files=
-ac_config_libobj_dir=.
-LIBOBJS=
-cross_compiling=no
-subdirs=
-MFLAGS=
-MAKEFLAGS=
-
-# Identity of this package.
-PACKAGE_NAME='opcodes'
-PACKAGE_TARNAME='opcodes'
-PACKAGE_VERSION='2.43.1'
-PACKAGE_STRING='opcodes 2.43.1'
-PACKAGE_BUGREPORT=''
-PACKAGE_URL=''
-
-ac_unique_file="z8k-dis.c"
-# Factoring default headers for most tests.
-ac_includes_default="\
-#include <stdio.h>
-#ifdef HAVE_SYS_TYPES_H
-# include <sys/types.h>
-#endif
-#ifdef HAVE_SYS_STAT_H
-# include <sys/stat.h>
-#endif
-#ifdef STDC_HEADERS
-# include <stdlib.h>
-# include <stddef.h>
-#else
-# ifdef HAVE_STDLIB_H
-# include <stdlib.h>
-# endif
-#endif
-#ifdef HAVE_STRING_H
-# if !defined STDC_HEADERS && defined HAVE_MEMORY_H
-# include <memory.h>
-# endif
-# include <string.h>
-#endif
-#ifdef HAVE_STRINGS_H
-# include <strings.h>
-#endif
-#ifdef HAVE_INTTYPES_H
-# include <inttypes.h>
-#endif
-#ifdef HAVE_STDINT_H
-# include <stdint.h>
-#endif
-#ifdef HAVE_UNISTD_H
-# include <unistd.h>
-#endif"
-
-gt_needs=
-ac_subst_vars='am__EXEEXT_FALSE
-am__EXEEXT_TRUE
-LTLIBOBJS
-LIBOBJS
-BFD_MACHINES
-archdefs
-SHARED_DEPENDENCIES
-SHARED_LIBADD
-SHARED_LDFLAGS
-BUILD_LIB_DEPS
-BUILD_LIBS
-LIBM
-cgendir
-CGEN_MAINT_FALSE
-CGEN_MAINT_TRUE
-HDEFINES
-ENABLE_BFD_64_BIT_FALSE
-ENABLE_BFD_64_BIT_TRUE
-EXEEXT_FOR_BUILD
-CC_FOR_BUILD
-CATOBJEXT
-GENCAT
-INSTOBJEXT
-DATADIRNAME
-CATALOGS
-INCINTL
-LIBINTL_DEP
-POSUB
-LTLIBINTL
-LIBINTL
-INTLLIBS
-LTLIBICONV
-LIBICONV
-INTL_MACOSX_LIBS
-MSGMERGE
-XGETTEXT
-GMSGFMT
-MSGFMT
-USE_NLS
-MKINSTALLDIRS
-bfdincludedir
-bfdlibdir
-target_noncanonical
-host_noncanonical
-INSTALL_LIBBFD_FALSE
-INSTALL_LIBBFD_TRUE
-MAINT
-MAINTAINER_MODE_FALSE
-MAINTAINER_MODE_TRUE
-WARN_WRITE_STRINGS
-NO_WERROR
-WARN_CFLAGS_FOR_BUILD
-WARN_CFLAGS
-OTOOL64
-OTOOL
-LIPO
-NMEDIT
-DSYMUTIL
-OBJDUMP
-LN_S
-NM
-ac_ct_DUMPBIN
-DUMPBIN
-LD
-FGREP
-SED
-LIBTOOL
-RANLIB
-AR
-EGREP
-GREP
-CPP
-am__fastdepCC_FALSE
-am__fastdepCC_TRUE
-CCDEPMODE
-am__nodep
-AMDEPBACKSLASH
-AMDEP_FALSE
-AMDEP_TRUE
-am__quote
-am__include
-DEPDIR
-OBJEXT
-EXEEXT
-ac_ct_CC
-CPPFLAGS
-LDFLAGS
-CFLAGS
-CC
-AM_BACKSLASH
-AM_DEFAULT_VERBOSITY
-AM_DEFAULT_V
-AM_V
-am__untar
-am__tar
-AMTAR
-am__leading_dot
-SET_MAKE
-AWK
-mkdir_p
-MKDIR_P
-INSTALL_STRIP_PROGRAM
-STRIP
-install_sh
-MAKEINFO
-AUTOHEADER
-AUTOMAKE
-AUTOCONF
-ACLOCAL
-VERSION
-PACKAGE
-CYGPATH_W
-am__isrc
-INSTALL_DATA
-INSTALL_SCRIPT
-INSTALL_PROGRAM
-target_os
-target_vendor
-target_cpu
-target
-host_os
-host_vendor
-host_cpu
-host
-build_os
-build_vendor
-build_cpu
-build
-target_alias
-host_alias
-build_alias
-LIBS
-ECHO_T
-ECHO_N
-ECHO_C
-DEFS
-mandir
-localedir
-libdir
-psdir
-pdfdir
-dvidir
-htmldir
-infodir
-docdir
-oldincludedir
-includedir
-localstatedir
-sharedstatedir
-sysconfdir
-datadir
-datarootdir
-libexecdir
-sbindir
-bindir
-program_transform_name
-prefix
-exec_prefix
-PACKAGE_URL
-PACKAGE_BUGREPORT
-PACKAGE_STRING
-PACKAGE_VERSION
-PACKAGE_TARNAME
-PACKAGE_NAME
-PATH_SEPARATOR
-SHELL'
-ac_subst_files=''
-ac_user_opts='
-enable_option_checking
-enable_silent_rules
-enable_dependency_tracking
-enable_shared
-enable_static
-with_pic
-enable_fast_install
-with_gnu_ld
-enable_libtool_lock
-enable_checking
-enable_targets
-enable_werror
-enable_build_warnings
-enable_maintainer_mode
-enable_install_libbfd
-enable_nls
-enable_rpath
-with_libiconv_prefix
-with_libiconv_type
-with_libintl_prefix
-with_libintl_type
-enable_64_bit_bfd
-enable_cgen_maint
-'
- ac_precious_vars='build_alias
-host_alias
-target_alias
-CC
-CFLAGS
-LDFLAGS
-LIBS
-CPPFLAGS
-CPP'
-
-
-# Initialize some variables set by options.
-ac_init_help=
-ac_init_version=false
-ac_unrecognized_opts=
-ac_unrecognized_sep=
-# The variables have the same names as the options, with
-# dashes changed to underlines.
-cache_file=/dev/null
-exec_prefix=NONE
-no_create=
-no_recursion=
-prefix=NONE
-program_prefix=NONE
-program_suffix=NONE
-program_transform_name=s,x,x,
-silent=
-site=
-srcdir=
-verbose=
-x_includes=NONE
-x_libraries=NONE
-
-# Installation directory options.
-# These are left unexpanded so users can "make install exec_prefix=/foo"
-# and all the variables that are supposed to be based on exec_prefix
-# by default will actually change.
-# Use braces instead of parens because sh, perl, etc. also accept them.
-# (The list follows the same order as the GNU Coding Standards.)
-bindir='${exec_prefix}/bin'
-sbindir='${exec_prefix}/sbin'
-libexecdir='${exec_prefix}/libexec'
-datarootdir='${prefix}/share'
-datadir='${datarootdir}'
-sysconfdir='${prefix}/etc'
-sharedstatedir='${prefix}/com'
-localstatedir='${prefix}/var'
-includedir='${prefix}/include'
-oldincludedir='/usr/include'
-docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
-infodir='${datarootdir}/info'
-htmldir='${docdir}'
-dvidir='${docdir}'
-pdfdir='${docdir}'
-psdir='${docdir}'
-libdir='${exec_prefix}/lib'
-localedir='${datarootdir}/locale'
-mandir='${datarootdir}/man'
-
-ac_prev=
-ac_dashdash=
-for ac_option
-do
- # If the previous option needs an argument, assign it.
- if test -n "$ac_prev"; then
- eval $ac_prev=\$ac_option
- ac_prev=
- continue
- fi
-
- case $ac_option in
- *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
- *=) ac_optarg= ;;
- *) ac_optarg=yes ;;
- esac
-
- # Accept the important Cygnus configure options, so we can diagnose typos.
-
- case $ac_dashdash$ac_option in
- --)
- ac_dashdash=yes ;;
-
- -bindir | --bindir | --bindi | --bind | --bin | --bi)
- ac_prev=bindir ;;
- -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
- bindir=$ac_optarg ;;
-
- -build | --build | --buil | --bui | --bu)
- ac_prev=build_alias ;;
- -build=* | --build=* | --buil=* | --bui=* | --bu=*)
- build_alias=$ac_optarg ;;
-
- -cache-file | --cache-file | --cache-fil | --cache-fi \
- | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
- ac_prev=cache_file ;;
- -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
- | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
- cache_file=$ac_optarg ;;
-
- --config-cache | -C)
- cache_file=config.cache ;;
-
- -datadir | --datadir | --datadi | --datad)
- ac_prev=datadir ;;
- -datadir=* | --datadir=* | --datadi=* | --datad=*)
- datadir=$ac_optarg ;;
-
- -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
- | --dataroo | --dataro | --datar)
- ac_prev=datarootdir ;;
- -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
- | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
- datarootdir=$ac_optarg ;;
-
- -disable-* | --disable-*)
- ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
- # Reject names that are not valid shell variable names.
- expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
- as_fn_error $? "invalid feature name: $ac_useropt"
- ac_useropt_orig=$ac_useropt
- ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
- case $ac_user_opts in
- *"
-"enable_$ac_useropt"
-"*) ;;
- *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
- ac_unrecognized_sep=', ';;
- esac
- eval enable_$ac_useropt=no ;;
-
- -docdir | --docdir | --docdi | --doc | --do)
- ac_prev=docdir ;;
- -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
- docdir=$ac_optarg ;;
-
- -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
- ac_prev=dvidir ;;
- -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
- dvidir=$ac_optarg ;;
-
- -enable-* | --enable-*)
- ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
- # Reject names that are not valid shell variable names.
- expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
- as_fn_error $? "invalid feature name: $ac_useropt"
- ac_useropt_orig=$ac_useropt
- ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
- case $ac_user_opts in
- *"
-"enable_$ac_useropt"
-"*) ;;
- *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
- ac_unrecognized_sep=', ';;
- esac
- eval enable_$ac_useropt=\$ac_optarg ;;
-
- -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
- | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
- | --exec | --exe | --ex)
- ac_prev=exec_prefix ;;
- -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
- | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
- | --exec=* | --exe=* | --ex=*)
- exec_prefix=$ac_optarg ;;
-
- -gas | --gas | --ga | --g)
- # Obsolete; use --with-gas.
- with_gas=yes ;;
-
- -help | --help | --hel | --he | -h)
- ac_init_help=long ;;
- -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
- ac_init_help=recursive ;;
- -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
- ac_init_help=short ;;
-
- -host | --host | --hos | --ho)
- ac_prev=host_alias ;;
- -host=* | --host=* | --hos=* | --ho=*)
- host_alias=$ac_optarg ;;
-
- -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
- ac_prev=htmldir ;;
- -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
- | --ht=*)
- htmldir=$ac_optarg ;;
-
- -includedir | --includedir | --includedi | --included | --include \
- | --includ | --inclu | --incl | --inc)
- ac_prev=includedir ;;
- -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
- | --includ=* | --inclu=* | --incl=* | --inc=*)
- includedir=$ac_optarg ;;
-
- -infodir | --infodir | --infodi | --infod | --info | --inf)
- ac_prev=infodir ;;
- -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
- infodir=$ac_optarg ;;
-
- -libdir | --libdir | --libdi | --libd)
- ac_prev=libdir ;;
- -libdir=* | --libdir=* | --libdi=* | --libd=*)
- libdir=$ac_optarg ;;
-
- -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
- | --libexe | --libex | --libe)
- ac_prev=libexecdir ;;
- -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
- | --libexe=* | --libex=* | --libe=*)
- libexecdir=$ac_optarg ;;
-
- -localedir | --localedir | --localedi | --localed | --locale)
- ac_prev=localedir ;;
- -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
- localedir=$ac_optarg ;;
-
- -localstatedir | --localstatedir | --localstatedi | --localstated \
- | --localstate | --localstat | --localsta | --localst | --locals)
- ac_prev=localstatedir ;;
- -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
- | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
- localstatedir=$ac_optarg ;;
-
- -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
- ac_prev=mandir ;;
- -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
- mandir=$ac_optarg ;;
-
- -nfp | --nfp | --nf)
- # Obsolete; use --without-fp.
- with_fp=no ;;
-
- -no-create | --no-create | --no-creat | --no-crea | --no-cre \
- | --no-cr | --no-c | -n)
- no_create=yes ;;
-
- -no-recursion | --no-recursion | --no-recursio | --no-recursi \
- | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
- no_recursion=yes ;;
-
- -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
- | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
- | --oldin | --oldi | --old | --ol | --o)
- ac_prev=oldincludedir ;;
- -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
- | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
- | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
- oldincludedir=$ac_optarg ;;
-
- -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
- ac_prev=prefix ;;
- -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
- prefix=$ac_optarg ;;
-
- -program-prefix | --program-prefix | --program-prefi | --program-pref \
- | --program-pre | --program-pr | --program-p)
- ac_prev=program_prefix ;;
- -program-prefix=* | --program-prefix=* | --program-prefi=* \
- | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
- program_prefix=$ac_optarg ;;
-
- -program-suffix | --program-suffix | --program-suffi | --program-suff \
- | --program-suf | --program-su | --program-s)
- ac_prev=program_suffix ;;
- -program-suffix=* | --program-suffix=* | --program-suffi=* \
- | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
- program_suffix=$ac_optarg ;;
-
- -program-transform-name | --program-transform-name \
- | --program-transform-nam | --program-transform-na \
- | --program-transform-n | --program-transform- \
- | --program-transform | --program-transfor \
- | --program-transfo | --program-transf \
- | --program-trans | --program-tran \
- | --progr-tra | --program-tr | --program-t)
- ac_prev=program_transform_name ;;
- -program-transform-name=* | --program-transform-name=* \
- | --program-transform-nam=* | --program-transform-na=* \
- | --program-transform-n=* | --program-transform-=* \
- | --program-transform=* | --program-transfor=* \
- | --program-transfo=* | --program-transf=* \
- | --program-trans=* | --program-tran=* \
- | --progr-tra=* | --program-tr=* | --program-t=*)
- program_transform_name=$ac_optarg ;;
-
- -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
- ac_prev=pdfdir ;;
- -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
- pdfdir=$ac_optarg ;;
-
- -psdir | --psdir | --psdi | --psd | --ps)
- ac_prev=psdir ;;
- -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
- psdir=$ac_optarg ;;
-
- -q | -quiet | --quiet | --quie | --qui | --qu | --q \
- | -silent | --silent | --silen | --sile | --sil)
- silent=yes ;;
-
- -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
- ac_prev=sbindir ;;
- -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
- | --sbi=* | --sb=*)
- sbindir=$ac_optarg ;;
-
- -sharedstatedir | --sharedstatedir | --sharedstatedi \
- | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
- | --sharedst | --shareds | --shared | --share | --shar \
- | --sha | --sh)
- ac_prev=sharedstatedir ;;
- -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
- | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
- | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
- | --sha=* | --sh=*)
- sharedstatedir=$ac_optarg ;;
-
- -site | --site | --sit)
- ac_prev=site ;;
- -site=* | --site=* | --sit=*)
- site=$ac_optarg ;;
-
- -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
- ac_prev=srcdir ;;
- -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
- srcdir=$ac_optarg ;;
-
- -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
- | --syscon | --sysco | --sysc | --sys | --sy)
- ac_prev=sysconfdir ;;
- -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
- | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
- sysconfdir=$ac_optarg ;;
-
- -target | --target | --targe | --targ | --tar | --ta | --t)
- ac_prev=target_alias ;;
- -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
- target_alias=$ac_optarg ;;
-
- -v | -verbose | --verbose | --verbos | --verbo | --verb)
- verbose=yes ;;
-
- -version | --version | --versio | --versi | --vers | -V)
- ac_init_version=: ;;
-
- -with-* | --with-*)
- ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
- # Reject names that are not valid shell variable names.
- expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
- as_fn_error $? "invalid package name: $ac_useropt"
- ac_useropt_orig=$ac_useropt
- ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
- case $ac_user_opts in
- *"
-"with_$ac_useropt"
-"*) ;;
- *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
- ac_unrecognized_sep=', ';;
- esac
- eval with_$ac_useropt=\$ac_optarg ;;
-
- -without-* | --without-*)
- ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
- # Reject names that are not valid shell variable names.
- expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
- as_fn_error $? "invalid package name: $ac_useropt"
- ac_useropt_orig=$ac_useropt
- ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
- case $ac_user_opts in
- *"
-"with_$ac_useropt"
-"*) ;;
- *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
- ac_unrecognized_sep=', ';;
- esac
- eval with_$ac_useropt=no ;;
-
- --x)
- # Obsolete; use --with-x.
- with_x=yes ;;
-
- -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
- | --x-incl | --x-inc | --x-in | --x-i)
- ac_prev=x_includes ;;
- -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
- | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
- x_includes=$ac_optarg ;;
-
- -x-libraries | --x-libraries | --x-librarie | --x-librari \
- | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
- ac_prev=x_libraries ;;
- -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
- | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
- x_libraries=$ac_optarg ;;
-
- -*) as_fn_error $? "unrecognized option: \`$ac_option'
-Try \`$0 --help' for more information"
- ;;
-
- *=*)
- ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
- # Reject names that are not valid shell variable names.
- case $ac_envvar in #(
- '' | [0-9]* | *[!_$as_cr_alnum]* )
- as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
- esac
- eval $ac_envvar=\$ac_optarg
- export $ac_envvar ;;
-
- *)
- # FIXME: should be removed in autoconf 3.0.
- $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
- expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
- $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
- : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
- ;;
-
- esac
-done
-
-if test -n "$ac_prev"; then
- ac_option=--`echo $ac_prev | sed 's/_/-/g'`
- as_fn_error $? "missing argument to $ac_option"
-fi
-
-if test -n "$ac_unrecognized_opts"; then
- case $enable_option_checking in
- no) ;;
- fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
- *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
- esac
-fi
-
-# Check all directory arguments for consistency.
-for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
- datadir sysconfdir sharedstatedir localstatedir includedir \
- oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
- libdir localedir mandir
-do
- eval ac_val=\$$ac_var
- # Remove trailing slashes.
- case $ac_val in
- */ )
- ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
- eval $ac_var=\$ac_val;;
- esac
- # Be sure to have absolute directory names.
- case $ac_val in
- [\\/$]* | ?:[\\/]* ) continue;;
- NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
- esac
- as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
-done
-
-# There might be people who depend on the old broken behavior: `$host'
-# used to hold the argument of --host etc.
-# FIXME: To remove some day.
-build=$build_alias
-host=$host_alias
-target=$target_alias
-
-# FIXME: To remove some day.
-if test "x$host_alias" != x; then
- if test "x$build_alias" = x; then
- cross_compiling=maybe
- elif test "x$build_alias" != "x$host_alias"; then
- cross_compiling=yes
- fi
-fi
-
-ac_tool_prefix=
-test -n "$host_alias" && ac_tool_prefix=$host_alias-
-
-test "$silent" = yes && exec 6>/dev/null
-
-
-ac_pwd=`pwd` && test -n "$ac_pwd" &&
-ac_ls_di=`ls -di .` &&
-ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
- as_fn_error $? "working directory cannot be determined"
-test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
- as_fn_error $? "pwd does not report name of working directory"
-
-
-# Find the source files, if location was not specified.
-if test -z "$srcdir"; then
- ac_srcdir_defaulted=yes
- # Try the directory containing this script, then the parent directory.
- ac_confdir=`$as_dirname -- "$as_myself" ||
-$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$as_myself" : 'X\(//\)[^/]' \| \
- X"$as_myself" : 'X\(//\)$' \| \
- X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$as_myself" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
- srcdir=$ac_confdir
- if test ! -r "$srcdir/$ac_unique_file"; then
- srcdir=..
- fi
-else
- ac_srcdir_defaulted=no
-fi
-if test ! -r "$srcdir/$ac_unique_file"; then
- test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
- as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
-fi
-ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
-ac_abs_confdir=`(
- cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
- pwd)`
-# When building in place, set srcdir=.
-if test "$ac_abs_confdir" = "$ac_pwd"; then
- srcdir=.
-fi
-# Remove unnecessary trailing slashes from srcdir.
-# Double slashes in file names in object file debugging info
-# mess up M-x gdb in Emacs.
-case $srcdir in
-*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
-esac
-for ac_var in $ac_precious_vars; do
- eval ac_env_${ac_var}_set=\${${ac_var}+set}
- eval ac_env_${ac_var}_value=\$${ac_var}
- eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
- eval ac_cv_env_${ac_var}_value=\$${ac_var}
-done
-
-#
-# Report the --help message.
-#
-if test "$ac_init_help" = "long"; then
- # Omit some internal or obsolete options to make the list less imposing.
- # This message is too long to be a string in the A/UX 3.1 sh.
- cat <<_ACEOF
-\`configure' configures opcodes 2.43.1 to adapt to many kinds of systems.
-
-Usage: $0 [OPTION]... [VAR=VALUE]...
-
-To assign environment variables (e.g., CC, CFLAGS...), specify them as
-VAR=VALUE. See below for descriptions of some of the useful variables.
-
-Defaults for the options are specified in brackets.
-
-Configuration:
- -h, --help display this help and exit
- --help=short display options specific to this package
- --help=recursive display the short help of all the included packages
- -V, --version display version information and exit
- -q, --quiet, --silent do not print \`checking ...' messages
- --cache-file=FILE cache test results in FILE [disabled]
- -C, --config-cache alias for \`--cache-file=config.cache'
- -n, --no-create do not create output files
- --srcdir=DIR find the sources in DIR [configure dir or \`..']
-
-Installation directories:
- --prefix=PREFIX install architecture-independent files in PREFIX
- [$ac_default_prefix]
- --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
- [PREFIX]
-
-By default, \`make install' will install all the files in
-\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
-an installation prefix other than \`$ac_default_prefix' using \`--prefix',
-for instance \`--prefix=\$HOME'.
-
-For better control, use the options below.
-
-Fine tuning of the installation directories:
- --bindir=DIR user executables [EPREFIX/bin]
- --sbindir=DIR system admin executables [EPREFIX/sbin]
- --libexecdir=DIR program executables [EPREFIX/libexec]
- --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
- --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
- --localstatedir=DIR modifiable single-machine data [PREFIX/var]
- --libdir=DIR object code libraries [EPREFIX/lib]
- --includedir=DIR C header files [PREFIX/include]
- --oldincludedir=DIR C header files for non-gcc [/usr/include]
- --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
- --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
- --infodir=DIR info documentation [DATAROOTDIR/info]
- --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
- --mandir=DIR man documentation [DATAROOTDIR/man]
- --docdir=DIR documentation root [DATAROOTDIR/doc/opcodes]
- --htmldir=DIR html documentation [DOCDIR]
- --dvidir=DIR dvi documentation [DOCDIR]
- --pdfdir=DIR pdf documentation [DOCDIR]
- --psdir=DIR ps documentation [DOCDIR]
-_ACEOF
-
- cat <<\_ACEOF
-
-Program names:
- --program-prefix=PREFIX prepend PREFIX to installed program names
- --program-suffix=SUFFIX append SUFFIX to installed program names
- --program-transform-name=PROGRAM run sed PROGRAM on installed program names
-
-System types:
- --build=BUILD configure for building on BUILD [guessed]
- --host=HOST cross-compile to build programs to run on HOST [BUILD]
- --target=TARGET configure for building compilers for TARGET [HOST]
-_ACEOF
-fi
-
-if test -n "$ac_init_help"; then
- case $ac_init_help in
- short | recursive ) echo "Configuration of opcodes 2.43.1:";;
- esac
- cat <<\_ACEOF
-
-Optional Features:
- --disable-option-checking ignore unrecognized --enable/--with options
- --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
- --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
- --enable-silent-rules less verbose build output (undo: "make V=1")
- --disable-silent-rules verbose build output (undo: "make V=0")
- --enable-dependency-tracking
- do not reject slow dependency extractors
- --disable-dependency-tracking
- speeds up one-time build
- --enable-shared[=PKGS] build shared libraries [default=no]
- --enable-static[=PKGS] build static libraries [default=yes]
- --enable-fast-install[=PKGS]
- optimize for fast installation [default=yes]
- --disable-libtool-lock avoid locking (might break parallel builds)
- --enable-checking enable run-time checks
- --enable-targets alternative target configurations
- --enable-werror treat compile warnings as errors
- --enable-build-warnings enable build-time compiler warnings
- --enable-maintainer-mode
- enable make rules and dependencies not useful (and
- sometimes confusing) to the casual installer
- --enable-install-libbfd controls installation of libbfd and related headers
- --disable-nls do not use Native Language Support
- --disable-rpath do not hardcode runtime library paths
- --enable-64-bit-bfd 64-bit support (on hosts with narrower word sizes)
- --enable-cgen-maint=dir build cgen generated files
-
-Optional Packages:
- --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
- --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
- --with-pic try to use only PIC/non-PIC objects [default=use
- both]
- --with-gnu-ld assume the C compiler uses GNU ld [default=no]
- --with-gnu-ld assume the C compiler uses GNU ld default=no
- --with-libiconv-prefix[=DIR] search for libiconv in DIR/include and DIR/lib
- --without-libiconv-prefix don't search for libiconv in includedir and libdir
- --with-libiconv-type=TYPE type of library to search for (auto/static/shared)
- --with-libintl-prefix[=DIR] search for libintl in DIR/include and DIR/lib
- --without-libintl-prefix don't search for libintl in includedir and libdir
- --with-libintl-type=TYPE type of library to search for (auto/static/shared)
-
-Some influential environment variables:
- CC C compiler command
- CFLAGS C compiler flags
- LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
- nonstandard directory <lib dir>
- LIBS libraries to pass to the linker, e.g. -l<library>
- CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
- you have headers in a nonstandard directory <include dir>
- CPP C preprocessor
-
-Use these variables to override the choices made by `configure' or to help
-it to find libraries and programs with nonstandard names/locations.
-
-Report bugs to the package provider.
-_ACEOF
-ac_status=$?
-fi
-
-if test "$ac_init_help" = "recursive"; then
- # If there are subdirs, report their specific --help.
- for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
- test -d "$ac_dir" ||
- { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
- continue
- ac_builddir=.
-
-case "$ac_dir" in
-.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
-*)
- ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
- # A ".." for each directory in $ac_dir_suffix.
- ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
- case $ac_top_builddir_sub in
- "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
- *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
- esac ;;
-esac
-ac_abs_top_builddir=$ac_pwd
-ac_abs_builddir=$ac_pwd$ac_dir_suffix
-# for backward compatibility:
-ac_top_builddir=$ac_top_build_prefix
-
-case $srcdir in
- .) # We are building in place.
- ac_srcdir=.
- ac_top_srcdir=$ac_top_builddir_sub
- ac_abs_top_srcdir=$ac_pwd ;;
- [\\/]* | ?:[\\/]* ) # Absolute name.
- ac_srcdir=$srcdir$ac_dir_suffix;
- ac_top_srcdir=$srcdir
- ac_abs_top_srcdir=$srcdir ;;
- *) # Relative name.
- ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
- ac_top_srcdir=$ac_top_build_prefix$srcdir
- ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
-esac
-ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
-
- cd "$ac_dir" || { ac_status=$?; continue; }
- # Check for guested configure.
- if test -f "$ac_srcdir/configure.gnu"; then
- echo &&
- $SHELL "$ac_srcdir/configure.gnu" --help=recursive
- elif test -f "$ac_srcdir/configure"; then
- echo &&
- $SHELL "$ac_srcdir/configure" --help=recursive
- else
- $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
- fi || ac_status=$?
- cd "$ac_pwd" || { ac_status=$?; break; }
- done
-fi
-
-test -n "$ac_init_help" && exit $ac_status
-if $ac_init_version; then
- cat <<\_ACEOF
-opcodes configure 2.43.1
-generated by GNU Autoconf 2.69
-
-Copyright (C) 2012 Free Software Foundation, Inc.
-This configure script is free software; the Free Software Foundation
-gives unlimited permission to copy, distribute and modify it.
-_ACEOF
- exit
-fi
-
-## ------------------------ ##
-## Autoconf initialization. ##
-## ------------------------ ##
-
-# ac_fn_c_try_compile LINENO
-# --------------------------
-# Try to compile conftest.$ac_ext, and return whether this succeeded.
-ac_fn_c_try_compile ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- rm -f conftest.$ac_objext
- if { { ac_try="$ac_compile"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_compile") 2>conftest.err
- ac_status=$?
- if test -s conftest.err; then
- grep -v '^ *+' conftest.err >conftest.er1
- cat conftest.er1 >&5
- mv -f conftest.er1 conftest.err
- fi
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && {
- test -z "$ac_c_werror_flag" ||
- test ! -s conftest.err
- } && test -s conftest.$ac_objext; then :
- ac_retval=0
-else
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
- ac_retval=1
-fi
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
- as_fn_set_status $ac_retval
-
-} # ac_fn_c_try_compile
-
-# ac_fn_c_try_cpp LINENO
-# ----------------------
-# Try to preprocess conftest.$ac_ext, and return whether this succeeded.
-ac_fn_c_try_cpp ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- if { { ac_try="$ac_cpp conftest.$ac_ext"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
- ac_status=$?
- if test -s conftest.err; then
- grep -v '^ *+' conftest.err >conftest.er1
- cat conftest.er1 >&5
- mv -f conftest.er1 conftest.err
- fi
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } > conftest.i && {
- test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
- test ! -s conftest.err
- }; then :
- ac_retval=0
-else
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
- ac_retval=1
-fi
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
- as_fn_set_status $ac_retval
-
-} # ac_fn_c_try_cpp
-
-# ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
-# -------------------------------------------------------
-# Tests whether HEADER exists, giving a warning if it cannot be compiled using
-# the include files in INCLUDES and setting the cache variable VAR
-# accordingly.
-ac_fn_c_check_header_mongrel ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- if eval \${$3+:} false; then :
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
-$as_echo_n "checking for $2... " >&6; }
-if eval \${$3+:} false; then :
- $as_echo_n "(cached) " >&6
-fi
-eval ac_res=\$$3
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
-else
- # Is the header compilable?
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
-$as_echo_n "checking $2 usability... " >&6; }
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$4
-#include <$2>
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_header_compiler=yes
-else
- ac_header_compiler=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
-$as_echo "$ac_header_compiler" >&6; }
-
-# Is the header present?
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
-$as_echo_n "checking $2 presence... " >&6; }
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <$2>
-_ACEOF
-if ac_fn_c_try_cpp "$LINENO"; then :
- ac_header_preproc=yes
-else
- ac_header_preproc=no
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
-$as_echo "$ac_header_preproc" >&6; }
-
-# So? What about this header?
-case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
- yes:no: )
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
-$as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
-$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
- ;;
- no:yes:* )
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
-$as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
-$as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
-$as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
-$as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
-$as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
- ;;
-esac
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
-$as_echo_n "checking for $2... " >&6; }
-if eval \${$3+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- eval "$3=\$ac_header_compiler"
-fi
-eval ac_res=\$$3
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
-fi
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
-
-} # ac_fn_c_check_header_mongrel
-
-# ac_fn_c_try_run LINENO
-# ----------------------
-# Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
-# that executables *can* be run.
-ac_fn_c_try_run ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- if { { ac_try="$ac_link"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_link") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
- { { case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_try") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; }; then :
- ac_retval=0
-else
- $as_echo "$as_me: program exited with status $ac_status" >&5
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
- ac_retval=$ac_status
-fi
- rm -rf conftest.dSYM conftest_ipa8_conftest.oo
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
- as_fn_set_status $ac_retval
-
-} # ac_fn_c_try_run
-
-# ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
-# -------------------------------------------------------
-# Tests whether HEADER exists and can be compiled using the include files in
-# INCLUDES, setting the cache variable VAR accordingly.
-ac_fn_c_check_header_compile ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
-$as_echo_n "checking for $2... " >&6; }
-if eval \${$3+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$4
-#include <$2>
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- eval "$3=yes"
-else
- eval "$3=no"
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-eval ac_res=\$$3
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
-
-} # ac_fn_c_check_header_compile
-
-# ac_fn_c_try_link LINENO
-# -----------------------
-# Try to link conftest.$ac_ext, and return whether this succeeded.
-ac_fn_c_try_link ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- rm -f conftest.$ac_objext conftest$ac_exeext
- if { { ac_try="$ac_link"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_link") 2>conftest.err
- ac_status=$?
- if test -s conftest.err; then
- grep -v '^ *+' conftest.err >conftest.er1
- cat conftest.er1 >&5
- mv -f conftest.er1 conftest.err
- fi
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && {
- test -z "$ac_c_werror_flag" ||
- test ! -s conftest.err
- } && test -s conftest$ac_exeext && {
- test "$cross_compiling" = yes ||
- test -x conftest$ac_exeext
- }; then :
- ac_retval=0
-else
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
- ac_retval=1
-fi
- # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
- # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
- # interfere with the next link command; also delete a directory that is
- # left behind by Apple's compiler. We do this before executing the actions.
- rm -rf conftest.dSYM conftest_ipa8_conftest.oo
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
- as_fn_set_status $ac_retval
-
-} # ac_fn_c_try_link
-
-# ac_fn_c_check_func LINENO FUNC VAR
-# ----------------------------------
-# Tests whether FUNC exists, setting the cache variable VAR accordingly
-ac_fn_c_check_func ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
-$as_echo_n "checking for $2... " >&6; }
-if eval \${$3+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-/* Define $2 to an innocuous variant, in case <limits.h> declares $2.
- For example, HP-UX 11i <limits.h> declares gettimeofday. */
-#define $2 innocuous_$2
-
-/* System header to define __stub macros and hopefully few prototypes,
- which can conflict with char $2 (); below.
- Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
- <limits.h> exists even on freestanding compilers. */
-
-#ifdef __STDC__
-# include <limits.h>
-#else
-# include <assert.h>
-#endif
-
-#undef $2
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char $2 ();
-/* The GNU C library defines this for functions which it implements
- to always fail with ENOSYS. Some functions are actually named
- something starting with __ and the normal name is an alias. */
-#if defined __stub_$2 || defined __stub___$2
-choke me
-#endif
-
-int
-main ()
-{
-return $2 ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- eval "$3=yes"
-else
- eval "$3=no"
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-fi
-eval ac_res=\$$3
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
-
-} # ac_fn_c_check_func
-
-# ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
-# --------------------------------------------
-# Tries to find the compile-time value of EXPR in a program that includes
-# INCLUDES, setting VAR accordingly. Returns whether the value could be
-# computed
-ac_fn_c_compute_int ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- if test "$cross_compiling" = yes; then
- # Depending upon the size, compute the lo and hi bounds.
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$4
-int
-main ()
-{
-static int test_array [1 - 2 * !(($2) >= 0)];
-test_array [0] = 0;
-return test_array [0];
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_lo=0 ac_mid=0
- while :; do
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$4
-int
-main ()
-{
-static int test_array [1 - 2 * !(($2) <= $ac_mid)];
-test_array [0] = 0;
-return test_array [0];
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_hi=$ac_mid; break
-else
- as_fn_arith $ac_mid + 1 && ac_lo=$as_val
- if test $ac_lo -le $ac_mid; then
- ac_lo= ac_hi=
- break
- fi
- as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- done
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$4
-int
-main ()
-{
-static int test_array [1 - 2 * !(($2) < 0)];
-test_array [0] = 0;
-return test_array [0];
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_hi=-1 ac_mid=-1
- while :; do
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$4
-int
-main ()
-{
-static int test_array [1 - 2 * !(($2) >= $ac_mid)];
-test_array [0] = 0;
-return test_array [0];
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_lo=$ac_mid; break
-else
- as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
- if test $ac_mid -le $ac_hi; then
- ac_lo= ac_hi=
- break
- fi
- as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- done
-else
- ac_lo= ac_hi=
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-# Binary search between lo and hi bounds.
-while test "x$ac_lo" != "x$ac_hi"; do
- as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$4
-int
-main ()
-{
-static int test_array [1 - 2 * !(($2) <= $ac_mid)];
-test_array [0] = 0;
-return test_array [0];
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_hi=$ac_mid
-else
- as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-done
-case $ac_lo in #((
-?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
-'') ac_retval=1 ;;
-esac
- else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$4
-static long int longval () { return $2; }
-static unsigned long int ulongval () { return $2; }
-#include <stdio.h>
-#include <stdlib.h>
-int
-main ()
-{
-
- FILE *f = fopen ("conftest.val", "w");
- if (! f)
- return 1;
- if (($2) < 0)
- {
- long int i = longval ();
- if (i != ($2))
- return 1;
- fprintf (f, "%ld", i);
- }
- else
- {
- unsigned long int i = ulongval ();
- if (i != ($2))
- return 1;
- fprintf (f, "%lu", i);
- }
- /* Do not output a trailing newline, as this causes \r\n confusion
- on some platforms. */
- return ferror (f) || fclose (f) != 0;
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_run "$LINENO"; then :
- echo >>conftest.val; read $3 <conftest.val; ac_retval=0
-else
- ac_retval=1
-fi
-rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
- conftest.$ac_objext conftest.beam conftest.$ac_ext
-rm -f conftest.val
-
- fi
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
- as_fn_set_status $ac_retval
-
-} # ac_fn_c_compute_int
-
-# ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES
-# ---------------------------------------------
-# Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR
-# accordingly.
-ac_fn_c_check_decl ()
-{
- as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- as_decl_name=`echo $2|sed 's/ *(.*//'`
- as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'`
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5
-$as_echo_n "checking whether $as_decl_name is declared... " >&6; }
-if eval \${$3+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-$4
-int
-main ()
-{
-#ifndef $as_decl_name
-#ifdef __cplusplus
- (void) $as_decl_use;
-#else
- (void) $as_decl_name;
-#endif
-#endif
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- eval "$3=yes"
-else
- eval "$3=no"
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-eval ac_res=\$$3
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
- eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
-
-} # ac_fn_c_check_decl
-cat >config.log <<_ACEOF
-This file contains any messages produced by compilers while
-running configure, to aid debugging if configure makes a mistake.
-
-It was created by opcodes $as_me 2.43.1, which was
-generated by GNU Autoconf 2.69. Invocation command line was
-
- $ $0 $@
-
-_ACEOF
-exec 5>>config.log
-{
-cat <<_ASUNAME
-## --------- ##
-## Platform. ##
-## --------- ##
-
-hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
-uname -m = `(uname -m) 2>/dev/null || echo unknown`
-uname -r = `(uname -r) 2>/dev/null || echo unknown`
-uname -s = `(uname -s) 2>/dev/null || echo unknown`
-uname -v = `(uname -v) 2>/dev/null || echo unknown`
-
-/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
-/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
-
-/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
-/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
-/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
-/usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
-/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
-/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
-/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
-
-_ASUNAME
-
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- $as_echo "PATH: $as_dir"
- done
-IFS=$as_save_IFS
-
-} >&5
-
-cat >&5 <<_ACEOF
-
-
-## ----------- ##
-## Core tests. ##
-## ----------- ##
-
-_ACEOF
-
-
-# Keep a trace of the command line.
-# Strip out --no-create and --no-recursion so they do not pile up.
-# Strip out --silent because we don't want to record it for future runs.
-# Also quote any args containing shell meta-characters.
-# Make two passes to allow for proper duplicate-argument suppression.
-ac_configure_args=
-ac_configure_args0=
-ac_configure_args1=
-ac_must_keep_next=false
-for ac_pass in 1 2
-do
- for ac_arg
- do
- case $ac_arg in
- -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
- -q | -quiet | --quiet | --quie | --qui | --qu | --q \
- | -silent | --silent | --silen | --sile | --sil)
- continue ;;
- *\'*)
- ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
- esac
- case $ac_pass in
- 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
- 2)
- as_fn_append ac_configure_args1 " '$ac_arg'"
- if test $ac_must_keep_next = true; then
- ac_must_keep_next=false # Got value, back to normal.
- else
- case $ac_arg in
- *=* | --config-cache | -C | -disable-* | --disable-* \
- | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
- | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
- | -with-* | --with-* | -without-* | --without-* | --x)
- case "$ac_configure_args0 " in
- "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
- esac
- ;;
- -* ) ac_must_keep_next=true ;;
- esac
- fi
- as_fn_append ac_configure_args " '$ac_arg'"
- ;;
- esac
- done
-done
-{ ac_configure_args0=; unset ac_configure_args0;}
-{ ac_configure_args1=; unset ac_configure_args1;}
-
-# When interrupted or exit'd, cleanup temporary files, and complete
-# config.log. We remove comments because anyway the quotes in there
-# would cause problems or look ugly.
-# WARNING: Use '\'' to represent an apostrophe within the trap.
-# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
-trap 'exit_status=$?
- # Save into config.log some information that might help in debugging.
- {
- echo
-
- $as_echo "## ---------------- ##
-## Cache variables. ##
-## ---------------- ##"
- echo
- # The following way of writing the cache mishandles newlines in values,
-(
- for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
- eval ac_val=\$$ac_var
- case $ac_val in #(
- *${as_nl}*)
- case $ac_var in #(
- *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
-$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
- esac
- case $ac_var in #(
- _ | IFS | as_nl) ;; #(
- BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
- *) { eval $ac_var=; unset $ac_var;} ;;
- esac ;;
- esac
- done
- (set) 2>&1 |
- case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
- *${as_nl}ac_space=\ *)
- sed -n \
- "s/'\''/'\''\\\\'\'''\''/g;
- s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
- ;; #(
- *)
- sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
- ;;
- esac |
- sort
-)
- echo
-
- $as_echo "## ----------------- ##
-## Output variables. ##
-## ----------------- ##"
- echo
- for ac_var in $ac_subst_vars
- do
- eval ac_val=\$$ac_var
- case $ac_val in
- *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
- esac
- $as_echo "$ac_var='\''$ac_val'\''"
- done | sort
- echo
-
- if test -n "$ac_subst_files"; then
- $as_echo "## ------------------- ##
-## File substitutions. ##
-## ------------------- ##"
- echo
- for ac_var in $ac_subst_files
- do
- eval ac_val=\$$ac_var
- case $ac_val in
- *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
- esac
- $as_echo "$ac_var='\''$ac_val'\''"
- done | sort
- echo
- fi
-
- if test -s confdefs.h; then
- $as_echo "## ----------- ##
-## confdefs.h. ##
-## ----------- ##"
- echo
- cat confdefs.h
- echo
- fi
- test "$ac_signal" != 0 &&
- $as_echo "$as_me: caught signal $ac_signal"
- $as_echo "$as_me: exit $exit_status"
- } >&5
- rm -f core *.core core.conftest.* &&
- rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
- exit $exit_status
-' 0
-for ac_signal in 1 2 13 15; do
- trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
-done
-ac_signal=0
-
-# confdefs.h avoids OS command line length limits that DEFS can exceed.
-rm -f -r conftest* confdefs.h
-
-$as_echo "/* confdefs.h */" > confdefs.h
-
-# Predefined preprocessor variables.
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_NAME "$PACKAGE_NAME"
-_ACEOF
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
-_ACEOF
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_VERSION "$PACKAGE_VERSION"
-_ACEOF
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_STRING "$PACKAGE_STRING"
-_ACEOF
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
-_ACEOF
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE_URL "$PACKAGE_URL"
-_ACEOF
-
-
-# Let the site file select an alternate cache file if it wants to.
-# Prefer an explicitly selected file to automatically selected ones.
-ac_site_file1=NONE
-ac_site_file2=NONE
-if test -n "$CONFIG_SITE"; then
- # We do not want a PATH search for config.site.
- case $CONFIG_SITE in #((
- -*) ac_site_file1=./$CONFIG_SITE;;
- */*) ac_site_file1=$CONFIG_SITE;;
- *) ac_site_file1=./$CONFIG_SITE;;
- esac
-elif test "x$prefix" != xNONE; then
- ac_site_file1=$prefix/share/config.site
- ac_site_file2=$prefix/etc/config.site
-else
- ac_site_file1=$ac_default_prefix/share/config.site
- ac_site_file2=$ac_default_prefix/etc/config.site
-fi
-for ac_site_file in "$ac_site_file1" "$ac_site_file2"
-do
- test "x$ac_site_file" = xNONE && continue
- if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
-$as_echo "$as_me: loading site script $ac_site_file" >&6;}
- sed 's/^/| /' "$ac_site_file" >&5
- . "$ac_site_file" \
- || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "failed to load site script $ac_site_file
-See \`config.log' for more details" "$LINENO" 5; }
- fi
-done
-
-if test -r "$cache_file"; then
- # Some versions of bash will fail to source /dev/null (special files
- # actually), so we avoid doing that. DJGPP emulates it as a regular file.
- if test /dev/null != "$cache_file" && test -f "$cache_file"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
-$as_echo "$as_me: loading cache $cache_file" >&6;}
- case $cache_file in
- [\\/]* | ?:[\\/]* ) . "$cache_file";;
- *) . "./$cache_file";;
- esac
- fi
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
-$as_echo "$as_me: creating cache $cache_file" >&6;}
- >$cache_file
-fi
-
-gt_needs="$gt_needs "
-# Check that the precious variables saved in the cache have kept the same
-# value.
-ac_cache_corrupted=false
-for ac_var in $ac_precious_vars; do
- eval ac_old_set=\$ac_cv_env_${ac_var}_set
- eval ac_new_set=\$ac_env_${ac_var}_set
- eval ac_old_val=\$ac_cv_env_${ac_var}_value
- eval ac_new_val=\$ac_env_${ac_var}_value
- case $ac_old_set,$ac_new_set in
- set,)
- { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
-$as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
- ac_cache_corrupted=: ;;
- ,set)
- { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
-$as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
- ac_cache_corrupted=: ;;
- ,);;
- *)
- if test "x$ac_old_val" != "x$ac_new_val"; then
- # differences in whitespace do not lead to failure.
- ac_old_val_w=`echo x $ac_old_val`
- ac_new_val_w=`echo x $ac_new_val`
- if test "$ac_old_val_w" != "$ac_new_val_w"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
-$as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
- ac_cache_corrupted=:
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
-$as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
- eval $ac_var=\$ac_old_val
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
-$as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
-$as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
- fi;;
- esac
- # Pass precious variables to config.status.
- if test "$ac_new_set" = set; then
- case $ac_new_val in
- *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
- *) ac_arg=$ac_var=$ac_new_val ;;
- esac
- case " $ac_configure_args " in
- *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
- *) as_fn_append ac_configure_args " '$ac_arg'" ;;
- esac
- fi
-done
-if $ac_cache_corrupted; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
- { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
-$as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
- as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
-fi
-## -------------------- ##
-## Main body of script. ##
-## -------------------- ##
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-
-
-
-
-
-
-ac_aux_dir=
-for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
- if test -f "$ac_dir/install-sh"; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install-sh -c"
- break
- elif test -f "$ac_dir/install.sh"; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/install.sh -c"
- break
- elif test -f "$ac_dir/shtool"; then
- ac_aux_dir=$ac_dir
- ac_install_sh="$ac_aux_dir/shtool install -c"
- break
- fi
-done
-if test -z "$ac_aux_dir"; then
- as_fn_error $? "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5
-fi
-
-# These three variables are undocumented and unsupported,
-# and are intended to be withdrawn in a future Autoconf release.
-# They can cause serious problems if a builder's source tree is in a directory
-# whose full name contains unusual characters.
-ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
-ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
-ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
-
-
-# Make sure we can run config.sub.
-$SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
- as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
-$as_echo_n "checking build system type... " >&6; }
-if ${ac_cv_build+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_build_alias=$build_alias
-test "x$ac_build_alias" = x &&
- ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
-test "x$ac_build_alias" = x &&
- as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
-ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
- as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
-$as_echo "$ac_cv_build" >&6; }
-case $ac_cv_build in
-*-*-*) ;;
-*) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
-esac
-build=$ac_cv_build
-ac_save_IFS=$IFS; IFS='-'
-set x $ac_cv_build
-shift
-build_cpu=$1
-build_vendor=$2
-shift; shift
-# Remember, the first character of IFS is used to create $*,
-# except with old shells:
-build_os=$*
-IFS=$ac_save_IFS
-case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
-$as_echo_n "checking host system type... " >&6; }
-if ${ac_cv_host+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test "x$host_alias" = x; then
- ac_cv_host=$ac_cv_build
-else
- ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
- as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
-$as_echo "$ac_cv_host" >&6; }
-case $ac_cv_host in
-*-*-*) ;;
-*) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
-esac
-host=$ac_cv_host
-ac_save_IFS=$IFS; IFS='-'
-set x $ac_cv_host
-shift
-host_cpu=$1
-host_vendor=$2
-shift; shift
-# Remember, the first character of IFS is used to create $*,
-# except with old shells:
-host_os=$*
-IFS=$ac_save_IFS
-case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking target system type" >&5
-$as_echo_n "checking target system type... " >&6; }
-if ${ac_cv_target+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test "x$target_alias" = x; then
- ac_cv_target=$ac_cv_host
-else
- ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` ||
- as_fn_error $? "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5
-$as_echo "$ac_cv_target" >&6; }
-case $ac_cv_target in
-*-*-*) ;;
-*) as_fn_error $? "invalid value of canonical target" "$LINENO" 5;;
-esac
-target=$ac_cv_target
-ac_save_IFS=$IFS; IFS='-'
-set x $ac_cv_target
-shift
-target_cpu=$1
-target_vendor=$2
-shift; shift
-# Remember, the first character of IFS is used to create $*,
-# except with old shells:
-target_os=$*
-IFS=$ac_save_IFS
-case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac
-
-
-# The aliases save the names the user supplied, while $host etc.
-# will get canonicalized.
-test -n "$target_alias" &&
- test "$program_prefix$program_suffix$program_transform_name" = \
- NONENONEs,x,x, &&
- program_prefix=${target_alias}-
-
-am__api_version='1.15'
-
-# Find a good install program. We prefer a C program (faster),
-# so one script is as good as another. But avoid the broken or
-# incompatible versions:
-# SysV /etc/install, /usr/sbin/install
-# SunOS /usr/etc/install
-# IRIX /sbin/install
-# AIX /bin/install
-# AmigaOS /C/install, which installs bootblocks on floppy discs
-# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
-# AFS /usr/afsws/bin/install, which mishandles nonexistent args
-# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
-# OS/2's system install, which has a completely different semantic
-# ./install, which can be erroneously created by make from ./install.sh.
-# Reject install programs that cannot install multiple files.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
-$as_echo_n "checking for a BSD-compatible install... " >&6; }
-if test -z "$INSTALL"; then
-if ${ac_cv_path_install+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- # Account for people who put trailing slashes in PATH elements.
-case $as_dir/ in #((
- ./ | .// | /[cC]/* | \
- /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
- ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
- /usr/ucb/* ) ;;
- *)
- # OSF1 and SCO ODT 3.0 have their own names for install.
- # Don't use installbsd from OSF since it installs stuff as root
- # by default.
- for ac_prog in ginstall scoinst install; do
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
- if test $ac_prog = install &&
- grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
- # AIX install. It has an incompatible calling convention.
- :
- elif test $ac_prog = install &&
- grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
- # program-specific install script used by HP pwplus--don't use.
- :
- else
- rm -rf conftest.one conftest.two conftest.dir
- echo one > conftest.one
- echo two > conftest.two
- mkdir conftest.dir
- if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
- test -s conftest.one && test -s conftest.two &&
- test -s conftest.dir/conftest.one &&
- test -s conftest.dir/conftest.two
- then
- ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
- break 3
- fi
- fi
- fi
- done
- done
- ;;
-esac
-
- done
-IFS=$as_save_IFS
-
-rm -rf conftest.one conftest.two conftest.dir
-
-fi
- if test "${ac_cv_path_install+set}" = set; then
- INSTALL=$ac_cv_path_install
- else
- # As a last resort, use the slow shell script. Don't cache a
- # value for INSTALL within a source directory, because that will
- # break other packages using the cache if that directory is
- # removed, or if the value is a relative name.
- INSTALL=$ac_install_sh
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
-$as_echo "$INSTALL" >&6; }
-
-# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
-# It thinks the first close brace ends the variable substitution.
-test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
-
-test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
-
-test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5
-$as_echo_n "checking whether build environment is sane... " >&6; }
-# Reject unsafe characters in $srcdir or the absolute working directory
-# name. Accept space and tab only in the latter.
-am_lf='
-'
-case `pwd` in
- *[\\\"\#\$\&\'\`$am_lf]*)
- as_fn_error $? "unsafe absolute working directory name" "$LINENO" 5;;
-esac
-case $srcdir in
- *[\\\"\#\$\&\'\`$am_lf\ \ ]*)
- as_fn_error $? "unsafe srcdir value: '$srcdir'" "$LINENO" 5;;
-esac
-
-# Do 'set' in a subshell so we don't clobber the current shell's
-# arguments. Must try -L first in case configure is actually a
-# symlink; some systems play weird games with the mod time of symlinks
-# (eg FreeBSD returns the mod time of the symlink's containing
-# directory).
-if (
- am_has_slept=no
- for am_try in 1 2; do
- echo "timestamp, slept: $am_has_slept" > conftest.file
- set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
- if test "$*" = "X"; then
- # -L didn't work.
- set X `ls -t "$srcdir/configure" conftest.file`
- fi
- if test "$*" != "X $srcdir/configure conftest.file" \
- && test "$*" != "X conftest.file $srcdir/configure"; then
-
- # If neither matched, then we have a broken ls. This can happen
- # if, for instance, CONFIG_SHELL is bash and it inherits a
- # broken ls alias from the environment. This has actually
- # happened. Such a system could not be considered "sane".
- as_fn_error $? "ls -t appears to fail. Make sure there is not a broken
- alias in your environment" "$LINENO" 5
- fi
- if test "$2" = conftest.file || test $am_try -eq 2; then
- break
- fi
- # Just in case.
- sleep 1
- am_has_slept=yes
- done
- test "$2" = conftest.file
- )
-then
- # Ok.
- :
-else
- as_fn_error $? "newly created file is older than distributed files!
-Check your system clock" "$LINENO" 5
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-# If we didn't sleep, we still need to ensure time stamps of config.status and
-# generated files are strictly newer.
-am_sleep_pid=
-if grep 'slept: no' conftest.file >/dev/null 2>&1; then
- ( sleep 1 ) &
- am_sleep_pid=$!
-fi
-
-rm -f conftest.file
-
-test "$program_prefix" != NONE &&
- program_transform_name="s&^&$program_prefix&;$program_transform_name"
-# Use a double $ so make ignores it.
-test "$program_suffix" != NONE &&
- program_transform_name="s&\$&$program_suffix&;$program_transform_name"
-# Double any \ or $.
-# By default was `s,x,x', remove it if useless.
-ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
-program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
-
-# Expand $ac_aux_dir to an absolute path.
-am_aux_dir=`cd "$ac_aux_dir" && pwd`
-
-if test x"${MISSING+set}" != xset; then
- case $am_aux_dir in
- *\ * | *\ *)
- MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
- *)
- MISSING="\${SHELL} $am_aux_dir/missing" ;;
- esac
-fi
-# Use eval to expand $SHELL
-if eval "$MISSING --is-lightweight"; then
- am_missing_run="$MISSING "
-else
- am_missing_run=
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: 'missing' script is too old or missing" >&5
-$as_echo "$as_me: WARNING: 'missing' script is too old or missing" >&2;}
-fi
-
-if test x"${install_sh+set}" != xset; then
- case $am_aux_dir in
- *\ * | *\ *)
- install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
- *)
- install_sh="\${SHELL} $am_aux_dir/install-sh"
- esac
-fi
-
-# Installed binaries are usually stripped using 'strip' when the user
-# run "make install-strip". However 'strip' might not be the right
-# tool to use in cross-compilation environments, therefore Automake
-# will honor the 'STRIP' environment variable to overrule this program.
-if test "$cross_compiling" != no; then
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
-set dummy ${ac_tool_prefix}strip; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_STRIP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$STRIP"; then
- ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_STRIP="${ac_tool_prefix}strip"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-STRIP=$ac_cv_prog_STRIP
-if test -n "$STRIP"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
-$as_echo "$STRIP" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_STRIP"; then
- ac_ct_STRIP=$STRIP
- # Extract the first word of "strip", so it can be a program name with args.
-set dummy strip; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_STRIP"; then
- ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_STRIP="strip"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
-if test -n "$ac_ct_STRIP"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
-$as_echo "$ac_ct_STRIP" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_STRIP" = x; then
- STRIP=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- STRIP=$ac_ct_STRIP
- fi
-else
- STRIP="$ac_cv_prog_STRIP"
-fi
-
-fi
-INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5
-$as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
-if test -z "$MKDIR_P"; then
- if ${ac_cv_path_mkdir+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_prog in mkdir gmkdir; do
- for ac_exec_ext in '' $ac_executable_extensions; do
- as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext" || continue
- case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
- 'mkdir (GNU coreutils) '* | \
- 'mkdir (coreutils) '* | \
- 'mkdir (fileutils) '4.1*)
- ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
- break 3;;
- esac
- done
- done
- done
-IFS=$as_save_IFS
-
-fi
-
- test -d ./--version && rmdir ./--version
- if test "${ac_cv_path_mkdir+set}" = set; then
- MKDIR_P="$ac_cv_path_mkdir -p"
- else
- # As a last resort, use the slow shell script. Don't cache a
- # value for MKDIR_P within a source directory, because that will
- # break other packages using the cache if that directory is
- # removed, or if the value is a relative name.
- MKDIR_P="$ac_install_sh -d"
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
-$as_echo "$MKDIR_P" >&6; }
-
-for ac_prog in gawk mawk nawk awk
-do
- # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_AWK+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$AWK"; then
- ac_cv_prog_AWK="$AWK" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_AWK="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-AWK=$ac_cv_prog_AWK
-if test -n "$AWK"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
-$as_echo "$AWK" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$AWK" && break
-done
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
-$as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
-set x ${MAKE-make}
-ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
-if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat >conftest.make <<\_ACEOF
-SHELL = /bin/sh
-all:
- @echo '@@@%%%=$(MAKE)=@@@%%%'
-_ACEOF
-# GNU make sometimes prints "make[1]: Entering ...", which would confuse us.
-case `${MAKE-make} -f conftest.make 2>/dev/null` in
- *@@@%%%=?*=@@@%%%*)
- eval ac_cv_prog_make_${ac_make}_set=yes;;
- *)
- eval ac_cv_prog_make_${ac_make}_set=no;;
-esac
-rm -f conftest.make
-fi
-if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- SET_MAKE=
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- SET_MAKE="MAKE=${MAKE-make}"
-fi
-
-rm -rf .tst 2>/dev/null
-mkdir .tst 2>/dev/null
-if test -d .tst; then
- am__leading_dot=.
-else
- am__leading_dot=_
-fi
-rmdir .tst 2>/dev/null
-
-# Check whether --enable-silent-rules was given.
-if test "${enable_silent_rules+set}" = set; then :
- enableval=$enable_silent_rules;
-fi
-
-case $enable_silent_rules in # (((
- yes) AM_DEFAULT_VERBOSITY=0;;
- no) AM_DEFAULT_VERBOSITY=1;;
- *) AM_DEFAULT_VERBOSITY=1;;
-esac
-am_make=${MAKE-make}
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5
-$as_echo_n "checking whether $am_make supports nested variables... " >&6; }
-if ${am_cv_make_support_nested_variables+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if $as_echo 'TRUE=$(BAR$(V))
-BAR0=false
-BAR1=true
-V=1
-am__doit:
- @$(TRUE)
-.PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then
- am_cv_make_support_nested_variables=yes
-else
- am_cv_make_support_nested_variables=no
-fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5
-$as_echo "$am_cv_make_support_nested_variables" >&6; }
-if test $am_cv_make_support_nested_variables = yes; then
- AM_V='$(V)'
- AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
-else
- AM_V=$AM_DEFAULT_VERBOSITY
- AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY
-fi
-AM_BACKSLASH='\'
-
-if test "`cd $srcdir && pwd`" != "`pwd`"; then
- # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
- # is not polluted with repeated "-I."
- am__isrc=' -I$(srcdir)'
- # test to see if srcdir already configured
- if test -f $srcdir/config.status; then
- as_fn_error $? "source directory already configured; run \"make distclean\" there first" "$LINENO" 5
- fi
-fi
-
-# test whether we have cygpath
-if test -z "$CYGPATH_W"; then
- if (cygpath --version) >/dev/null 2>/dev/null; then
- CYGPATH_W='cygpath -w'
- else
- CYGPATH_W=echo
- fi
-fi
-
-
-# Define the identity of the package.
- PACKAGE='opcodes'
- VERSION='2.43.1'
-
-
-cat >>confdefs.h <<_ACEOF
-#define PACKAGE "$PACKAGE"
-_ACEOF
-
-
-cat >>confdefs.h <<_ACEOF
-#define VERSION "$VERSION"
-_ACEOF
-
-# Some tools Automake needs.
-
-ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"}
-
-
-AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
-
-
-AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"}
-
-
-AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
-
-
-MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
-
-# For better backward compatibility. To be removed once Automake 1.9.x
-# dies out for good. For more background, see:
-# <http://lists.gnu.org/archive/html/automake/2012-07/msg00001.html>
-# <http://lists.gnu.org/archive/html/automake/2012-07/msg00014.html>
-mkdir_p='$(MKDIR_P)'
-
-# We need awk for the "check" target (and possibly the TAP driver). The
-# system "awk" is bad on some platforms.
-# Always define AMTAR for backward compatibility. Yes, it's still used
-# in the wild :-( We should find a proper way to deprecate it ...
-AMTAR='$${TAR-tar}'
-
-
-# We'll loop over all known methods to create a tar archive until one works.
-_am_tools='gnutar pax cpio none'
-
-am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -'
-
-
-
-
-
-
-# POSIX will say in a future version that running "rm -f" with no argument
-# is OK; and we want to be able to make that assumption in our Makefile
-# recipes. So use an aggressive probe to check that the usage we want is
-# actually supported "in the wild" to an acceptable degree.
-# See automake bug#10828.
-# To make any issue more visible, cause the running configure to be aborted
-# by default if the 'rm' program in use doesn't match our expectations; the
-# user can still override this though.
-if rm -f && rm -fr && rm -rf; then : OK; else
- cat >&2 <<'END'
-Oops!
-
-Your 'rm' program seems unable to run without file operands specified
-on the command line, even when the '-f' option is present. This is contrary
-to the behaviour of most rm programs out there, and not conforming with
-the upcoming POSIX standard: <http://austingroupbugs.net/view.php?id=542>
-
-Please tell bug-automake@gnu.org about your system, including the value
-of your $PATH and any error possibly output before this message. This
-can help us improve future automake versions.
-
-END
- if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then
- echo 'Configuration will proceed anyway, since you have set the' >&2
- echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2
- echo >&2
- else
- cat >&2 <<'END'
-Aborting the configuration process, to ensure you take notice of the issue.
-
-You can download and install GNU coreutils to get an 'rm' implementation
-that behaves properly: <http://www.gnu.org/software/coreutils/>.
-
-If you want to complete the configuration process using your problematic
-'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM
-to "yes", and re-run configure.
-
-END
- as_fn_error $? "Your 'rm' program is bad, sorry." "$LINENO" 5
- fi
-fi
-
-# Check whether --enable-silent-rules was given.
-if test "${enable_silent_rules+set}" = set; then :
- enableval=$enable_silent_rules;
-fi
-
-case $enable_silent_rules in # (((
- yes) AM_DEFAULT_VERBOSITY=0;;
- no) AM_DEFAULT_VERBOSITY=1;;
- *) AM_DEFAULT_VERBOSITY=0;;
-esac
-am_make=${MAKE-make}
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5
-$as_echo_n "checking whether $am_make supports nested variables... " >&6; }
-if ${am_cv_make_support_nested_variables+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if $as_echo 'TRUE=$(BAR$(V))
-BAR0=false
-BAR1=true
-V=1
-am__doit:
- @$(TRUE)
-.PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then
- am_cv_make_support_nested_variables=yes
-else
- am_cv_make_support_nested_variables=no
-fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5
-$as_echo "$am_cv_make_support_nested_variables" >&6; }
-if test $am_cv_make_support_nested_variables = yes; then
- AM_V='$(V)'
- AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
-else
- AM_V=$AM_DEFAULT_VERBOSITY
- AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY
-fi
-AM_BACKSLASH='\'
-
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
-set dummy ${ac_tool_prefix}gcc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_CC="${ac_tool_prefix}gcc"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
-$as_echo "$CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_CC"; then
- ac_ct_CC=$CC
- # Extract the first word of "gcc", so it can be a program name with args.
-set dummy gcc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_CC"; then
- ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_CC="gcc"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_CC=$ac_cv_prog_ac_ct_CC
-if test -n "$ac_ct_CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
-$as_echo "$ac_ct_CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_CC" = x; then
- CC=""
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- CC=$ac_ct_CC
- fi
-else
- CC="$ac_cv_prog_CC"
-fi
-
-if test -z "$CC"; then
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
-set dummy ${ac_tool_prefix}cc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_CC="${ac_tool_prefix}cc"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
-$as_echo "$CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- fi
-fi
-if test -z "$CC"; then
- # Extract the first word of "cc", so it can be a program name with args.
-set dummy cc; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
- ac_prog_rejected=no
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
- ac_prog_rejected=yes
- continue
- fi
- ac_cv_prog_CC="cc"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-if test $ac_prog_rejected = yes; then
- # We found a bogon in the path, so make sure we never use it.
- set dummy $ac_cv_prog_CC
- shift
- if test $# != 0; then
- # We chose a different compiler from the bogus one.
- # However, it has the same basename, so the bogon will be chosen
- # first if we set CC to just the basename; use the full file name.
- shift
- ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
- fi
-fi
-fi
-fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
-$as_echo "$CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$CC"; then
- if test -n "$ac_tool_prefix"; then
- for ac_prog in cl.exe
- do
- # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
-set dummy $ac_tool_prefix$ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-CC=$ac_cv_prog_CC
-if test -n "$CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
-$as_echo "$CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$CC" && break
- done
-fi
-if test -z "$CC"; then
- ac_ct_CC=$CC
- for ac_prog in cl.exe
-do
- # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_CC+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_CC"; then
- ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_CC="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_CC=$ac_cv_prog_ac_ct_CC
-if test -n "$ac_ct_CC"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
-$as_echo "$ac_ct_CC" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$ac_ct_CC" && break
-done
-
- if test "x$ac_ct_CC" = x; then
- CC=""
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- CC=$ac_ct_CC
- fi
-fi
-
-fi
-
-
-test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "no acceptable C compiler found in \$PATH
-See \`config.log' for more details" "$LINENO" 5; }
-
-# Provide some information about the compiler.
-$as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
-set X $ac_compile
-ac_compiler=$2
-for ac_option in --version -v -V -qversion; do
- { { ac_try="$ac_compiler $ac_option >&5"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_compiler $ac_option >&5") 2>conftest.err
- ac_status=$?
- if test -s conftest.err; then
- sed '10a\
-... rest of stderr output deleted ...
- 10q' conftest.err >conftest.er1
- cat conftest.er1 >&5
- fi
- rm -f conftest.er1 conftest.err
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }
-done
-
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-ac_clean_files_save=$ac_clean_files
-ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
-# Try to create an executable without -o first, disregard a.out.
-# It will help us diagnose broken compilers, and finding out an intuition
-# of exeext.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
-$as_echo_n "checking whether the C compiler works... " >&6; }
-ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
-
-# The possible output files:
-ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
-
-ac_rmfiles=
-for ac_file in $ac_files
-do
- case $ac_file in
- *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
- * ) ac_rmfiles="$ac_rmfiles $ac_file";;
- esac
-done
-rm -f $ac_rmfiles
-
-if { { ac_try="$ac_link_default"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_link_default") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then :
- # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
-# So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
-# in a Makefile. We should not override ac_cv_exeext if it was cached,
-# so that the user can short-circuit this test for compilers unknown to
-# Autoconf.
-for ac_file in $ac_files ''
-do
- test -f "$ac_file" || continue
- case $ac_file in
- *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
- ;;
- [ab].out )
- # We found the default executable, but exeext='' is most
- # certainly right.
- break;;
- *.* )
- if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
- then :; else
- ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
- fi
- # We set ac_cv_exeext here because the later test for it is not
- # safe: cross compilers may not add the suffix if given an `-o'
- # argument, so we may need to know it at that point already.
- # Even if this section looks crufty: it has the advantage of
- # actually working.
- break;;
- * )
- break;;
- esac
-done
-test "$ac_cv_exeext" = no && ac_cv_exeext=
-
-else
- ac_file=''
-fi
-if test -z "$ac_file"; then :
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-$as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error 77 "C compiler cannot create executables
-See \`config.log' for more details" "$LINENO" 5; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
-$as_echo_n "checking for C compiler default output file name... " >&6; }
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
-$as_echo "$ac_file" >&6; }
-ac_exeext=$ac_cv_exeext
-
-rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
-ac_clean_files=$ac_clean_files_save
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
-$as_echo_n "checking for suffix of executables... " >&6; }
-if { { ac_try="$ac_link"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_link") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then :
- # If both `conftest.exe' and `conftest' are `present' (well, observable)
-# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
-# work properly (i.e., refer to `conftest.exe'), while it won't with
-# `rm'.
-for ac_file in conftest.exe conftest conftest.*; do
- test -f "$ac_file" || continue
- case $ac_file in
- *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
- *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
- break;;
- * ) break;;
- esac
-done
-else
- { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "cannot compute suffix of executables: cannot compile and link
-See \`config.log' for more details" "$LINENO" 5; }
-fi
-rm -f conftest conftest$ac_cv_exeext
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
-$as_echo "$ac_cv_exeext" >&6; }
-
-rm -f conftest.$ac_ext
-EXEEXT=$ac_cv_exeext
-ac_exeext=$EXEEXT
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <stdio.h>
-int
-main ()
-{
-FILE *f = fopen ("conftest.out", "w");
- return ferror (f) || fclose (f) != 0;
-
- ;
- return 0;
-}
-_ACEOF
-ac_clean_files="$ac_clean_files conftest.out"
-# Check that the compiler produces executables we can run. If not, either
-# the compiler is broken, or we cross compile.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
-$as_echo_n "checking whether we are cross compiling... " >&6; }
-if test "$cross_compiling" != yes; then
- { { ac_try="$ac_link"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_link") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }
- if { ac_try='./conftest$ac_cv_exeext'
- { { case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_try") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; }; then
- cross_compiling=no
- else
- if test "$cross_compiling" = maybe; then
- cross_compiling=yes
- else
- { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "cannot run C compiled programs.
-If you meant to cross compile, use \`--host'.
-See \`config.log' for more details" "$LINENO" 5; }
- fi
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
-$as_echo "$cross_compiling" >&6; }
-
-rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
-ac_clean_files=$ac_clean_files_save
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
-$as_echo_n "checking for suffix of object files... " >&6; }
-if ${ac_cv_objext+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-rm -f conftest.o conftest.obj
-if { { ac_try="$ac_compile"
-case "(($ac_try" in
- *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
- *) ac_try_echo=$ac_try;;
-esac
-eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
-$as_echo "$ac_try_echo"; } >&5
- (eval "$ac_compile") 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then :
- for ac_file in conftest.o conftest.obj conftest.*; do
- test -f "$ac_file" || continue;
- case $ac_file in
- *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
- *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
- break;;
- esac
-done
-else
- $as_echo "$as_me: failed program was:" >&5
-sed 's/^/| /' conftest.$ac_ext >&5
-
-{ { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "cannot compute suffix of object files: cannot compile
-See \`config.log' for more details" "$LINENO" 5; }
-fi
-rm -f conftest.$ac_cv_objext conftest.$ac_ext
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
-$as_echo "$ac_cv_objext" >&6; }
-OBJEXT=$ac_cv_objext
-ac_objext=$OBJEXT
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
-$as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
-if ${ac_cv_c_compiler_gnu+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-#ifndef __GNUC__
- choke me
-#endif
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_compiler_gnu=yes
-else
- ac_compiler_gnu=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-ac_cv_c_compiler_gnu=$ac_compiler_gnu
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
-$as_echo "$ac_cv_c_compiler_gnu" >&6; }
-if test $ac_compiler_gnu = yes; then
- GCC=yes
-else
- GCC=
-fi
-ac_test_CFLAGS=${CFLAGS+set}
-ac_save_CFLAGS=$CFLAGS
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
-$as_echo_n "checking whether $CC accepts -g... " >&6; }
-if ${ac_cv_prog_cc_g+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_save_c_werror_flag=$ac_c_werror_flag
- ac_c_werror_flag=yes
- ac_cv_prog_cc_g=no
- CFLAGS="-g"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_prog_cc_g=yes
-else
- CFLAGS=""
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
-
-else
- ac_c_werror_flag=$ac_save_c_werror_flag
- CFLAGS="-g"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_prog_cc_g=yes
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
- ac_c_werror_flag=$ac_save_c_werror_flag
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
-$as_echo "$ac_cv_prog_cc_g" >&6; }
-if test "$ac_test_CFLAGS" = set; then
- CFLAGS=$ac_save_CFLAGS
-elif test $ac_cv_prog_cc_g = yes; then
- if test "$GCC" = yes; then
- CFLAGS="-g -O2"
- else
- CFLAGS="-g"
- fi
-else
- if test "$GCC" = yes; then
- CFLAGS="-O2"
- else
- CFLAGS=
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
-$as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
-if ${ac_cv_prog_cc_c89+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_cv_prog_cc_c89=no
-ac_save_CC=$CC
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <stdarg.h>
-#include <stdio.h>
-struct stat;
-/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
-struct buf { int x; };
-FILE * (*rcsopen) (struct buf *, struct stat *, int);
-static char *e (p, i)
- char **p;
- int i;
-{
- return p[i];
-}
-static char *f (char * (*g) (char **, int), char **p, ...)
-{
- char *s;
- va_list v;
- va_start (v,p);
- s = g (p, va_arg (v,int));
- va_end (v);
- return s;
-}
-
-/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
- function prototypes and stuff, but not '\xHH' hex character constants.
- These don't provoke an error unfortunately, instead are silently treated
- as 'x'. The following induces an error, until -std is added to get
- proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
- array size at least. It's necessary to write '\x00'==0 to get something
- that's true only with -std. */
-int osf4_cc_array ['\x00' == 0 ? 1 : -1];
-
-/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
- inside strings and character constants. */
-#define FOO(x) 'x'
-int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
-
-int test (int i, double x);
-struct s1 {int (*f) (int a);};
-struct s2 {int (*f) (double a);};
-int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
-int argc;
-char **argv;
-int
-main ()
-{
-return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
- ;
- return 0;
-}
-_ACEOF
-for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
- -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
-do
- CC="$ac_save_CC $ac_arg"
- if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_prog_cc_c89=$ac_arg
-fi
-rm -f core conftest.err conftest.$ac_objext
- test "x$ac_cv_prog_cc_c89" != "xno" && break
-done
-rm -f conftest.$ac_ext
-CC=$ac_save_CC
-
-fi
-# AC_CACHE_VAL
-case "x$ac_cv_prog_cc_c89" in
- x)
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
-$as_echo "none needed" >&6; } ;;
- xno)
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
-$as_echo "unsupported" >&6; } ;;
- *)
- CC="$CC $ac_cv_prog_cc_c89"
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
-$as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
-esac
-if test "x$ac_cv_prog_cc_c89" != xno; then :
-
-fi
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC understands -c and -o together" >&5
-$as_echo_n "checking whether $CC understands -c and -o together... " >&6; }
-if ${am_cv_prog_cc_c_o+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
- # Make sure it works both with $CC and with simple cc.
- # Following AC_PROG_CC_C_O, we do the test twice because some
- # compilers refuse to overwrite an existing .o file with -o,
- # though they will create one.
- am_cv_prog_cc_c_o=yes
- for am_i in 1 2; do
- if { echo "$as_me:$LINENO: $CC -c conftest.$ac_ext -o conftest2.$ac_objext" >&5
- ($CC -c conftest.$ac_ext -o conftest2.$ac_objext) >&5 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); } \
- && test -f conftest2.$ac_objext; then
- : OK
- else
- am_cv_prog_cc_c_o=no
- break
- fi
- done
- rm -f core conftest*
- unset am_i
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_cc_c_o" >&5
-$as_echo "$am_cv_prog_cc_c_o" >&6; }
-if test "$am_cv_prog_cc_c_o" != yes; then
- # Losing compiler, so override with the script.
- # FIXME: It is wrong to rewrite CC.
- # But if we don't then we get into trouble of one sort or another.
- # A longer-term fix would be to have automake use am__CC in this case,
- # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
- CC="$am_aux_dir/compile $CC"
-fi
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-DEPDIR="${am__leading_dot}deps"
-
-ac_config_commands="$ac_config_commands depfiles"
-
-
-am_make=${MAKE-make}
-cat > confinc << 'END'
-am__doit:
- @echo this is the am__doit target
-.PHONY: am__doit
-END
-# If we don't find an include directive, just comment out the code.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5
-$as_echo_n "checking for style of include used by $am_make... " >&6; }
-am__include="#"
-am__quote=
-_am_result=none
-# First try GNU make style include.
-echo "include confinc" > confmf
-# Ignore all kinds of additional output from 'make'.
-case `$am_make -s -f confmf 2> /dev/null` in #(
-*the\ am__doit\ target*)
- am__include=include
- am__quote=
- _am_result=GNU
- ;;
-esac
-# Now try BSD make style include.
-if test "$am__include" = "#"; then
- echo '.include "confinc"' > confmf
- case `$am_make -s -f confmf 2> /dev/null` in #(
- *the\ am__doit\ target*)
- am__include=.include
- am__quote="\""
- _am_result=BSD
- ;;
- esac
-fi
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5
-$as_echo "$_am_result" >&6; }
-rm -f confinc confmf
-
-# Check whether --enable-dependency-tracking was given.
-if test "${enable_dependency_tracking+set}" = set; then :
- enableval=$enable_dependency_tracking;
-fi
-
-if test "x$enable_dependency_tracking" != xno; then
- am_depcomp="$ac_aux_dir/depcomp"
- AMDEPBACKSLASH='\'
- am__nodep='_no'
-fi
- if test "x$enable_dependency_tracking" != xno; then
- AMDEP_TRUE=
- AMDEP_FALSE='#'
-else
- AMDEP_TRUE='#'
- AMDEP_FALSE=
-fi
-
-
-
-depcc="$CC" am_compiler_list=
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
-$as_echo_n "checking dependency style of $depcc... " >&6; }
-if ${am_cv_CC_dependencies_compiler_type+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
- # We make a subdir and do the tests there. Otherwise we can end up
- # making bogus files that we don't know about and never remove. For
- # instance it was reported that on HP-UX the gcc test will end up
- # making a dummy file named 'D' -- because '-MD' means "put the output
- # in D".
- rm -rf conftest.dir
- mkdir conftest.dir
- # Copy depcomp to subdir because otherwise we won't find it if we're
- # using a relative directory.
- cp "$am_depcomp" conftest.dir
- cd conftest.dir
- # We will build objects and dependencies in a subdirectory because
- # it helps to detect inapplicable dependency modes. For instance
- # both Tru64's cc and ICC support -MD to output dependencies as a
- # side effect of compilation, but ICC will put the dependencies in
- # the current directory while Tru64 will put them in the object
- # directory.
- mkdir sub
-
- am_cv_CC_dependencies_compiler_type=none
- if test "$am_compiler_list" = ""; then
- am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
- fi
- am__universal=false
- case " $depcc " in #(
- *\ -arch\ *\ -arch\ *) am__universal=true ;;
- esac
-
- for depmode in $am_compiler_list; do
- # Setup a source with many dependencies, because some compilers
- # like to wrap large dependency lists on column 80 (with \), and
- # we should not choose a depcomp mode which is confused by this.
- #
- # We need to recreate these files for each test, as the compiler may
- # overwrite some of them when testing with obscure command lines.
- # This happens at least with the AIX C compiler.
- : > sub/conftest.c
- for i in 1 2 3 4 5 6; do
- echo '#include "conftst'$i'.h"' >> sub/conftest.c
- # Using ": > sub/conftst$i.h" creates only sub/conftst1.h with
- # Solaris 10 /bin/sh.
- echo '/* dummy */' > sub/conftst$i.h
- done
- echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
-
- # We check with '-c' and '-o' for the sake of the "dashmstdout"
- # mode. It turns out that the SunPro C++ compiler does not properly
- # handle '-M -o', and we need to detect this. Also, some Intel
- # versions had trouble with output in subdirs.
- am__obj=sub/conftest.${OBJEXT-o}
- am__minus_obj="-o $am__obj"
- case $depmode in
- gcc)
- # This depmode causes a compiler race in universal mode.
- test "$am__universal" = false || continue
- ;;
- nosideeffect)
- # After this tag, mechanisms are not by side-effect, so they'll
- # only be used when explicitly requested.
- if test "x$enable_dependency_tracking" = xyes; then
- continue
- else
- break
- fi
- ;;
- msvc7 | msvc7msys | msvisualcpp | msvcmsys)
- # This compiler won't grok '-c -o', but also, the minuso test has
- # not run yet. These depmodes are late enough in the game, and
- # so weak that their functioning should not be impacted.
- am__obj=conftest.${OBJEXT-o}
- am__minus_obj=
- ;;
- none) break ;;
- esac
- if depmode=$depmode \
- source=sub/conftest.c object=$am__obj \
- depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
- $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
- >/dev/null 2>conftest.err &&
- grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
- grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
- grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
- ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
- # icc doesn't choke on unknown options, it will just issue warnings
- # or remarks (even with -Werror). So we grep stderr for any message
- # that says an option was ignored or not supported.
- # When given -MP, icc 7.0 and 7.1 complain thusly:
- # icc: Command line warning: ignoring option '-M'; no argument required
- # The diagnosis changed in icc 8.0:
- # icc: Command line remark: option '-MP' not supported
- if (grep 'ignoring option' conftest.err ||
- grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
- am_cv_CC_dependencies_compiler_type=$depmode
- break
- fi
- fi
- done
-
- cd ..
- rm -rf conftest.dir
-else
- am_cv_CC_dependencies_compiler_type=none
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
-$as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
-CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
-
- if
- test "x$enable_dependency_tracking" != xno \
- && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
- am__fastdepCC_TRUE=
- am__fastdepCC_FALSE='#'
-else
- am__fastdepCC_TRUE='#'
- am__fastdepCC_FALSE=
-fi
-
-
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
-$as_echo_n "checking how to run the C preprocessor... " >&6; }
-# On Suns, sometimes $CPP names a directory.
-if test -n "$CPP" && test -d "$CPP"; then
- CPP=
-fi
-if test -z "$CPP"; then
- if ${ac_cv_prog_CPP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- # Double quotes because CPP needs to be expanded
- for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
- do
- ac_preproc_ok=false
-for ac_c_preproc_warn_flag in '' yes
-do
- # Use a header file that comes with gcc, so configuring glibc
- # with a fresh cross-compiler works.
- # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
- # <limits.h> exists even on freestanding compilers.
- # On the NeXT, cc -E runs the code through the compiler's parser,
- # not just through cpp. "Syntax error" is here to catch this case.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#ifdef __STDC__
-# include <limits.h>
-#else
-# include <assert.h>
-#endif
- Syntax error
-_ACEOF
-if ac_fn_c_try_cpp "$LINENO"; then :
-
-else
- # Broken: fails on valid input.
-continue
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-
- # OK, works on sane cases. Now check whether nonexistent headers
- # can be detected and how.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <ac_nonexistent.h>
-_ACEOF
-if ac_fn_c_try_cpp "$LINENO"; then :
- # Broken: success on invalid input.
-continue
-else
- # Passes both tests.
-ac_preproc_ok=:
-break
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-
-done
-# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
-rm -f conftest.i conftest.err conftest.$ac_ext
-if $ac_preproc_ok; then :
- break
-fi
-
- done
- ac_cv_prog_CPP=$CPP
-
-fi
- CPP=$ac_cv_prog_CPP
-else
- ac_cv_prog_CPP=$CPP
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
-$as_echo "$CPP" >&6; }
-ac_preproc_ok=false
-for ac_c_preproc_warn_flag in '' yes
-do
- # Use a header file that comes with gcc, so configuring glibc
- # with a fresh cross-compiler works.
- # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
- # <limits.h> exists even on freestanding compilers.
- # On the NeXT, cc -E runs the code through the compiler's parser,
- # not just through cpp. "Syntax error" is here to catch this case.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#ifdef __STDC__
-# include <limits.h>
-#else
-# include <assert.h>
-#endif
- Syntax error
-_ACEOF
-if ac_fn_c_try_cpp "$LINENO"; then :
-
-else
- # Broken: fails on valid input.
-continue
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-
- # OK, works on sane cases. Now check whether nonexistent headers
- # can be detected and how.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <ac_nonexistent.h>
-_ACEOF
-if ac_fn_c_try_cpp "$LINENO"; then :
- # Broken: success on invalid input.
-continue
-else
- # Passes both tests.
-ac_preproc_ok=:
-break
-fi
-rm -f conftest.err conftest.i conftest.$ac_ext
-
-done
-# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
-rm -f conftest.i conftest.err conftest.$ac_ext
-if $ac_preproc_ok; then :
-
-else
- { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
-See \`config.log' for more details" "$LINENO" 5; }
-fi
-
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
-$as_echo_n "checking for grep that handles long lines and -e... " >&6; }
-if ${ac_cv_path_GREP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -z "$GREP"; then
- ac_path_GREP_found=false
- # Loop through the user's path and test for each of PROGNAME-LIST
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_prog in grep ggrep; do
- for ac_exec_ext in '' $ac_executable_extensions; do
- ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
- as_fn_executable_p "$ac_path_GREP" || continue
-# Check for GNU ac_path_GREP and select it if it is found.
- # Check for GNU $ac_path_GREP
-case `"$ac_path_GREP" --version 2>&1` in
-*GNU*)
- ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
-*)
- ac_count=0
- $as_echo_n 0123456789 >"conftest.in"
- while :
- do
- cat "conftest.in" "conftest.in" >"conftest.tmp"
- mv "conftest.tmp" "conftest.in"
- cp "conftest.in" "conftest.nl"
- $as_echo 'GREP' >> "conftest.nl"
- "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
- diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
- as_fn_arith $ac_count + 1 && ac_count=$as_val
- if test $ac_count -gt ${ac_path_GREP_max-0}; then
- # Best one so far, save it but keep looking for a better one
- ac_cv_path_GREP="$ac_path_GREP"
- ac_path_GREP_max=$ac_count
- fi
- # 10*(2^10) chars as input seems more than enough
- test $ac_count -gt 10 && break
- done
- rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
-esac
-
- $ac_path_GREP_found && break 3
- done
- done
- done
-IFS=$as_save_IFS
- if test -z "$ac_cv_path_GREP"; then
- as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
- fi
-else
- ac_cv_path_GREP=$GREP
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
-$as_echo "$ac_cv_path_GREP" >&6; }
- GREP="$ac_cv_path_GREP"
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
-$as_echo_n "checking for egrep... " >&6; }
-if ${ac_cv_path_EGREP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
- then ac_cv_path_EGREP="$GREP -E"
- else
- if test -z "$EGREP"; then
- ac_path_EGREP_found=false
- # Loop through the user's path and test for each of PROGNAME-LIST
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_prog in egrep; do
- for ac_exec_ext in '' $ac_executable_extensions; do
- ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
- as_fn_executable_p "$ac_path_EGREP" || continue
-# Check for GNU ac_path_EGREP and select it if it is found.
- # Check for GNU $ac_path_EGREP
-case `"$ac_path_EGREP" --version 2>&1` in
-*GNU*)
- ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
-*)
- ac_count=0
- $as_echo_n 0123456789 >"conftest.in"
- while :
- do
- cat "conftest.in" "conftest.in" >"conftest.tmp"
- mv "conftest.tmp" "conftest.in"
- cp "conftest.in" "conftest.nl"
- $as_echo 'EGREP' >> "conftest.nl"
- "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
- diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
- as_fn_arith $ac_count + 1 && ac_count=$as_val
- if test $ac_count -gt ${ac_path_EGREP_max-0}; then
- # Best one so far, save it but keep looking for a better one
- ac_cv_path_EGREP="$ac_path_EGREP"
- ac_path_EGREP_max=$ac_count
- fi
- # 10*(2^10) chars as input seems more than enough
- test $ac_count -gt 10 && break
- done
- rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
-esac
-
- $ac_path_EGREP_found && break 3
- done
- done
- done
-IFS=$as_save_IFS
- if test -z "$ac_cv_path_EGREP"; then
- as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
- fi
-else
- ac_cv_path_EGREP=$EGREP
-fi
-
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
-$as_echo "$ac_cv_path_EGREP" >&6; }
- EGREP="$ac_cv_path_EGREP"
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
-$as_echo_n "checking for ANSI C header files... " >&6; }
-if ${ac_cv_header_stdc+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <stdlib.h>
-#include <stdarg.h>
-#include <string.h>
-#include <float.h>
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_header_stdc=yes
-else
- ac_cv_header_stdc=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-
-if test $ac_cv_header_stdc = yes; then
- # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <string.h>
-
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "memchr" >/dev/null 2>&1; then :
-
-else
- ac_cv_header_stdc=no
-fi
-rm -f conftest*
-
-fi
-
-if test $ac_cv_header_stdc = yes; then
- # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <stdlib.h>
-
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "free" >/dev/null 2>&1; then :
-
-else
- ac_cv_header_stdc=no
-fi
-rm -f conftest*
-
-fi
-
-if test $ac_cv_header_stdc = yes; then
- # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
- if test "$cross_compiling" = yes; then :
- :
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <ctype.h>
-#include <stdlib.h>
-#if ((' ' & 0x0FF) == 0x020)
-# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
-# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
-#else
-# define ISLOWER(c) \
- (('a' <= (c) && (c) <= 'i') \
- || ('j' <= (c) && (c) <= 'r') \
- || ('s' <= (c) && (c) <= 'z'))
-# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
-#endif
-
-#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
-int
-main ()
-{
- int i;
- for (i = 0; i < 256; i++)
- if (XOR (islower (i), ISLOWER (i))
- || toupper (i) != TOUPPER (i))
- return 2;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_run "$LINENO"; then :
-
-else
- ac_cv_header_stdc=no
-fi
-rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
- conftest.$ac_objext conftest.beam conftest.$ac_ext
-fi
-
-fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
-$as_echo "$ac_cv_header_stdc" >&6; }
-if test $ac_cv_header_stdc = yes; then
-
-$as_echo "#define STDC_HEADERS 1" >>confdefs.h
-
-fi
-
-# On IRIX 5.3, sys/types and inttypes.h are conflicting.
-for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
- inttypes.h stdint.h unistd.h
-do :
- as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
-ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
-"
-if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
- cat >>confdefs.h <<_ACEOF
-#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
-_ACEOF
-
-fi
-
-done
-
-
-
- ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
-if test "x$ac_cv_header_minix_config_h" = xyes; then :
- MINIX=yes
-else
- MINIX=
-fi
-
-
- if test "$MINIX" = yes; then
-
-$as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
-
-
-$as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
-
-
-$as_echo "#define _MINIX 1" >>confdefs.h
-
- fi
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
-$as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
-if ${ac_cv_safe_to_define___extensions__+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-# define __EXTENSIONS__ 1
- $ac_includes_default
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- ac_cv_safe_to_define___extensions__=yes
-else
- ac_cv_safe_to_define___extensions__=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
-$as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
- test $ac_cv_safe_to_define___extensions__ = yes &&
- $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
-
- $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
-
- $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
-
- $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
-
- $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
-
-
-
-if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
-set dummy ${ac_tool_prefix}ar; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_AR+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$AR"; then
- ac_cv_prog_AR="$AR" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_AR="${ac_tool_prefix}ar"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-AR=$ac_cv_prog_AR
-if test -n "$AR"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
-$as_echo "$AR" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_AR"; then
- ac_ct_AR=$AR
- # Extract the first word of "ar", so it can be a program name with args.
-set dummy ar; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_AR+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_AR"; then
- ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_AR="ar"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_AR=$ac_cv_prog_ac_ct_AR
-if test -n "$ac_ct_AR"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
-$as_echo "$ac_ct_AR" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_AR" = x; then
- AR=""
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- AR=$ac_ct_AR
- fi
-else
- AR="$ac_cv_prog_AR"
-fi
-
-if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
-set dummy ${ac_tool_prefix}ranlib; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_RANLIB+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$RANLIB"; then
- ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-RANLIB=$ac_cv_prog_RANLIB
-if test -n "$RANLIB"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
-$as_echo "$RANLIB" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_RANLIB"; then
- ac_ct_RANLIB=$RANLIB
- # Extract the first word of "ranlib", so it can be a program name with args.
-set dummy ranlib; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_RANLIB"; then
- ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_RANLIB="ranlib"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
-if test -n "$ac_ct_RANLIB"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
-$as_echo "$ac_ct_RANLIB" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_RANLIB" = x; then
- RANLIB=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- RANLIB=$ac_ct_RANLIB
- fi
-else
- RANLIB="$ac_cv_prog_RANLIB"
-fi
-
-
-# Check whether --enable-shared was given.
-if test "${enable_shared+set}" = set; then :
- enableval=$enable_shared; p=${PACKAGE-default}
- case $enableval in
- yes) enable_shared=yes ;;
- no) enable_shared=no ;;
- *)
- enable_shared=no
- # Look at the argument we got. We use all the common list separators.
- lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
- for pkg in $enableval; do
- IFS="$lt_save_ifs"
- if test "X$pkg" = "X$p"; then
- enable_shared=yes
- fi
- done
- IFS="$lt_save_ifs"
- ;;
- esac
-else
- enable_shared=no
-fi
-
-
-
-
-
-
-
-
-
-
-case `pwd` in
- *\ * | *\ *)
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&5
-$as_echo "$as_me: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&2;} ;;
-esac
-
-
-
-macro_version='2.2.7a'
-macro_revision='1.3134'
-
-
-
-
-
-
-
-
-
-
-
-
-
-ltmain="$ac_aux_dir/ltmain.sh"
-
-# Backslashify metacharacters that are still active within
-# double-quoted strings.
-sed_quote_subst='s/\(["`$\\]\)/\\\1/g'
-
-# Same as above, but do not quote variable references.
-double_quote_subst='s/\(["`\\]\)/\\\1/g'
-
-# Sed substitution to delay expansion of an escaped shell variable in a
-# double_quote_subst'ed string.
-delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g'
-
-# Sed substitution to delay expansion of an escaped single quote.
-delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g'
-
-# Sed substitution to avoid accidental globbing in evaled expressions
-no_glob_subst='s/\*/\\\*/g'
-
-ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
-ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO
-ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5
-$as_echo_n "checking how to print strings... " >&6; }
-# Test print first, because it will be a builtin if present.
-if test "X`print -r -- -n 2>/dev/null`" = X-n && \
- test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then
- ECHO='print -r --'
-elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then
- ECHO='printf %s\n'
-else
- # Use this function as a fallback that always works.
- func_fallback_echo ()
- {
- eval 'cat <<_LTECHO_EOF
-$1
-_LTECHO_EOF'
- }
- ECHO='func_fallback_echo'
-fi
-
-# func_echo_all arg...
-# Invoke $ECHO with all args, space-separated.
-func_echo_all ()
-{
- $ECHO ""
-}
-
-case "$ECHO" in
- printf*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: printf" >&5
-$as_echo "printf" >&6; } ;;
- print*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: print -r" >&5
-$as_echo "print -r" >&6; } ;;
- *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: cat" >&5
-$as_echo "cat" >&6; } ;;
-esac
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
-$as_echo_n "checking for a sed that does not truncate output... " >&6; }
-if ${ac_cv_path_SED+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
- for ac_i in 1 2 3 4 5 6 7; do
- ac_script="$ac_script$as_nl$ac_script"
- done
- echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
- { ac_script=; unset ac_script;}
- if test -z "$SED"; then
- ac_path_SED_found=false
- # Loop through the user's path and test for each of PROGNAME-LIST
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_prog in sed gsed; do
- for ac_exec_ext in '' $ac_executable_extensions; do
- ac_path_SED="$as_dir/$ac_prog$ac_exec_ext"
- as_fn_executable_p "$ac_path_SED" || continue
-# Check for GNU ac_path_SED and select it if it is found.
- # Check for GNU $ac_path_SED
-case `"$ac_path_SED" --version 2>&1` in
-*GNU*)
- ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
-*)
- ac_count=0
- $as_echo_n 0123456789 >"conftest.in"
- while :
- do
- cat "conftest.in" "conftest.in" >"conftest.tmp"
- mv "conftest.tmp" "conftest.in"
- cp "conftest.in" "conftest.nl"
- $as_echo '' >> "conftest.nl"
- "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
- diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
- as_fn_arith $ac_count + 1 && ac_count=$as_val
- if test $ac_count -gt ${ac_path_SED_max-0}; then
- # Best one so far, save it but keep looking for a better one
- ac_cv_path_SED="$ac_path_SED"
- ac_path_SED_max=$ac_count
- fi
- # 10*(2^10) chars as input seems more than enough
- test $ac_count -gt 10 && break
- done
- rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
-esac
-
- $ac_path_SED_found && break 3
- done
- done
- done
-IFS=$as_save_IFS
- if test -z "$ac_cv_path_SED"; then
- as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
- fi
-else
- ac_cv_path_SED=$SED
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
-$as_echo "$ac_cv_path_SED" >&6; }
- SED="$ac_cv_path_SED"
- rm -f conftest.sed
-
-test -z "$SED" && SED=sed
-Xsed="$SED -e 1s/^X//"
-
-
-
-
-
-
-
-
-
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5
-$as_echo_n "checking for fgrep... " >&6; }
-if ${ac_cv_path_FGREP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1
- then ac_cv_path_FGREP="$GREP -F"
- else
- if test -z "$FGREP"; then
- ac_path_FGREP_found=false
- # Loop through the user's path and test for each of PROGNAME-LIST
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_prog in fgrep; do
- for ac_exec_ext in '' $ac_executable_extensions; do
- ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext"
- as_fn_executable_p "$ac_path_FGREP" || continue
-# Check for GNU ac_path_FGREP and select it if it is found.
- # Check for GNU $ac_path_FGREP
-case `"$ac_path_FGREP" --version 2>&1` in
-*GNU*)
- ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;;
-*)
- ac_count=0
- $as_echo_n 0123456789 >"conftest.in"
- while :
- do
- cat "conftest.in" "conftest.in" >"conftest.tmp"
- mv "conftest.tmp" "conftest.in"
- cp "conftest.in" "conftest.nl"
- $as_echo 'FGREP' >> "conftest.nl"
- "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break
- diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
- as_fn_arith $ac_count + 1 && ac_count=$as_val
- if test $ac_count -gt ${ac_path_FGREP_max-0}; then
- # Best one so far, save it but keep looking for a better one
- ac_cv_path_FGREP="$ac_path_FGREP"
- ac_path_FGREP_max=$ac_count
- fi
- # 10*(2^10) chars as input seems more than enough
- test $ac_count -gt 10 && break
- done
- rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
-esac
-
- $ac_path_FGREP_found && break 3
- done
- done
- done
-IFS=$as_save_IFS
- if test -z "$ac_cv_path_FGREP"; then
- as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
- fi
-else
- ac_cv_path_FGREP=$FGREP
-fi
-
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5
-$as_echo "$ac_cv_path_FGREP" >&6; }
- FGREP="$ac_cv_path_FGREP"
-
-
-test -z "$GREP" && GREP=grep
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-# Check whether --with-gnu-ld was given.
-if test "${with_gnu_ld+set}" = set; then :
- withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
-else
- with_gnu_ld=no
-fi
-
-ac_prog=ld
-if test "$GCC" = yes; then
- # Check if gcc -print-prog-name=ld gives a path.
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5
-$as_echo_n "checking for ld used by $CC... " >&6; }
- case $host in
- *-*-mingw*)
- # gcc leaves a trailing carriage return which upsets mingw
- ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
- *)
- ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
- esac
- case $ac_prog in
- # Accept absolute paths.
- [\\/]* | ?:[\\/]*)
- re_direlt='/[^/][^/]*/\.\./'
- # Canonicalize the pathname of ld
- ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'`
- while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do
- ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"`
- done
- test -z "$LD" && LD="$ac_prog"
- ;;
- "")
- # If it fails, then pretend we aren't using GCC.
- ac_prog=ld
- ;;
- *)
- # If it is relative, then search for the first ld in PATH.
- with_gnu_ld=unknown
- ;;
- esac
-elif test "$with_gnu_ld" = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
-$as_echo_n "checking for GNU ld... " >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
-$as_echo_n "checking for non-GNU ld... " >&6; }
-fi
-if ${lt_cv_path_LD+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -z "$LD"; then
- lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH; do
- IFS="$lt_save_ifs"
- test -z "$ac_dir" && ac_dir=.
- if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
- lt_cv_path_LD="$ac_dir/$ac_prog"
- # Check to see if the program is GNU ld. I'd rather use --version,
- # but apparently some variants of GNU ld only accept -v.
- # Break only if it was the GNU/non-GNU ld that we prefer.
- case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in
- *GNU* | *'with BFD'*)
- test "$with_gnu_ld" != no && break
- ;;
- *)
- test "$with_gnu_ld" != yes && break
- ;;
- esac
- fi
- done
- IFS="$lt_save_ifs"
-else
- lt_cv_path_LD="$LD" # Let the user override the test with a path.
-fi
-fi
-
-LD="$lt_cv_path_LD"
-if test -n "$LD"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
-$as_echo "$LD" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
-$as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
-if ${lt_cv_prog_gnu_ld+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- # I'd rather use --version here, but apparently some GNU lds only accept -v.
-case `$LD -v 2>&1 </dev/null` in
-*GNU* | *'with BFD'*)
- lt_cv_prog_gnu_ld=yes
- ;;
-*)
- lt_cv_prog_gnu_ld=no
- ;;
-esac
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_gnu_ld" >&5
-$as_echo "$lt_cv_prog_gnu_ld" >&6; }
-with_gnu_ld=$lt_cv_prog_gnu_ld
-
-
-
-
-
-
-
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for BSD- or MS-compatible name lister (nm)" >&5
-$as_echo_n "checking for BSD- or MS-compatible name lister (nm)... " >&6; }
-if ${lt_cv_path_NM+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$NM"; then
- # Let the user override the nm to test.
- lt_nm_to_check="$NM"
- else
- lt_nm_to_check="${ac_tool_prefix}nm"
- if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
- lt_nm_to_check="$lt_nm_to_check nm"
- fi
- fi
- for lt_tmp_nm in "$lt_nm_to_check"; do
- lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
- IFS="$lt_save_ifs"
- test -z "$ac_dir" && ac_dir=.
- # Strip out any user-provided options from the nm to test twice,
- # the first time to test to see if nm (rather than its options) has
- # an explicit path, the second time to yield a file which can be
- # nm'ed itself.
- tmp_nm_path="`$ECHO "$lt_tmp_nm" | sed 's, -.*$,,'`"
- case "$tmp_nm_path" in
- */*|*\\*) tmp_nm="$lt_tmp_nm";;
- *) tmp_nm="$ac_dir/$lt_tmp_nm";;
- esac
- tmp_nm_to_nm="`$ECHO "$tmp_nm" | sed 's, -.*$,,'`"
- if test -f "$tmp_nm_to_nm" || test -f "$tmp_nm_to_nm$ac_exeext" ; then
- # Check to see if the nm accepts a BSD-compat flag.
- # Adding the `sed 1q' prevents false positives on HP-UX, which says:
- # nm: unknown option "B" ignored
- case `"$tmp_nm" -B "$tmp_nm_to_nm" 2>&1 | grep -v '^ *$' | sed '1q'` in
- *$tmp_nm*) lt_cv_path_NM="$tmp_nm -B"
- break
- ;;
- *)
- case `"$tmp_nm" -p "$tmp_nm_to_nm" 2>&1 | grep -v '^ *$' | sed '1q'` in
- *$tmp_nm*)
- lt_cv_path_NM="$tmp_nm -p"
- break
- ;;
- *)
- lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
- continue # so that we can try to find one that supports BSD flags
- ;;
- esac
- ;;
- esac
- fi
- done
- IFS="$lt_save_ifs"
- done
- : ${lt_cv_path_NM=no}
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_NM" >&5
-$as_echo "$lt_cv_path_NM" >&6; }
-if test "$lt_cv_path_NM" != "no"; then
- NM="$lt_cv_path_NM"
-else
- # Didn't find any BSD compatible name lister, look for dumpbin.
- if test -n "$DUMPBIN"; then :
- # Let the user override the test.
- else
- if test -n "$ac_tool_prefix"; then
- for ac_prog in dumpbin "link -dump"
- do
- # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
-set dummy $ac_tool_prefix$ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_DUMPBIN+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$DUMPBIN"; then
- ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_DUMPBIN="$ac_tool_prefix$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-DUMPBIN=$ac_cv_prog_DUMPBIN
-if test -n "$DUMPBIN"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5
-$as_echo "$DUMPBIN" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$DUMPBIN" && break
- done
-fi
-if test -z "$DUMPBIN"; then
- ac_ct_DUMPBIN=$DUMPBIN
- for ac_prog in dumpbin "link -dump"
-do
- # Extract the first word of "$ac_prog", so it can be a program name with args.
-set dummy $ac_prog; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_DUMPBIN+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_DUMPBIN"; then
- ac_cv_prog_ac_ct_DUMPBIN="$ac_ct_DUMPBIN" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_DUMPBIN="$ac_prog"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_DUMPBIN=$ac_cv_prog_ac_ct_DUMPBIN
-if test -n "$ac_ct_DUMPBIN"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DUMPBIN" >&5
-$as_echo "$ac_ct_DUMPBIN" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- test -n "$ac_ct_DUMPBIN" && break
-done
-
- if test "x$ac_ct_DUMPBIN" = x; then
- DUMPBIN=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- DUMPBIN=$ac_ct_DUMPBIN
- fi
-fi
-
- case `$DUMPBIN -symbols /dev/null 2>&1 | sed '1q'` in
- *COFF*)
- DUMPBIN="$DUMPBIN -symbols"
- ;;
- *)
- DUMPBIN=:
- ;;
- esac
- fi
-
- if test "$DUMPBIN" != ":"; then
- NM="$DUMPBIN"
- fi
-fi
-test -z "$NM" && NM=nm
-
-
-
-
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the name lister ($NM) interface" >&5
-$as_echo_n "checking the name lister ($NM) interface... " >&6; }
-if ${lt_cv_nm_interface+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_nm_interface="BSD nm"
- echo "int some_variable = 0;" > conftest.$ac_ext
- (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&5)
- (eval "$ac_compile" 2>conftest.err)
- cat conftest.err >&5
- (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&5)
- (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out)
- cat conftest.err >&5
- (eval echo "\"\$as_me:$LINENO: output\"" >&5)
- cat conftest.out >&5
- if $GREP 'External.*some_variable' conftest.out > /dev/null; then
- lt_cv_nm_interface="MS dumpbin"
- fi
- rm -f conftest*
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_nm_interface" >&5
-$as_echo "$lt_cv_nm_interface" >&6; }
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
-$as_echo_n "checking whether ln -s works... " >&6; }
-LN_S=$as_ln_s
-if test "$LN_S" = "ln -s"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
-$as_echo "no, using $LN_S" >&6; }
-fi
-
-# find the maximum length of command line arguments
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking the maximum length of command line arguments" >&5
-$as_echo_n "checking the maximum length of command line arguments... " >&6; }
-if ${lt_cv_sys_max_cmd_len+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- i=0
- teststring="ABCD"
-
- case $build_os in
- msdosdjgpp*)
- # On DJGPP, this test can blow up pretty badly due to problems in libc
- # (any single argument exceeding 2000 bytes causes a buffer overrun
- # during glob expansion). Even if it were fixed, the result of this
- # check would be larger than it should be.
- lt_cv_sys_max_cmd_len=12288; # 12K is about right
- ;;
-
- gnu*)
- # Under GNU Hurd, this test is not required because there is
- # no limit to the length of command line arguments.
- # Libtool will interpret -1 as no limit whatsoever
- lt_cv_sys_max_cmd_len=-1;
- ;;
-
- cygwin* | mingw* | cegcc*)
- # On Win9x/ME, this test blows up -- it succeeds, but takes
- # about 5 minutes as the teststring grows exponentially.
- # Worse, since 9x/ME are not pre-emptively multitasking,
- # you end up with a "frozen" computer, even though with patience
- # the test eventually succeeds (with a max line length of 256k).
- # Instead, let's just punt: use the minimum linelength reported by
- # all of the supported platforms: 8192 (on NT/2K/XP).
- lt_cv_sys_max_cmd_len=8192;
- ;;
-
- mint*)
- # On MiNT this can take a long time and run out of memory.
- lt_cv_sys_max_cmd_len=8192;
- ;;
-
- amigaos*)
- # On AmigaOS with pdksh, this test takes hours, literally.
- # So we just punt and use a minimum line length of 8192.
- lt_cv_sys_max_cmd_len=8192;
- ;;
-
- netbsd* | freebsd* | openbsd* | darwin* | dragonfly*)
- # This has been around since 386BSD, at least. Likely further.
- if test -x /sbin/sysctl; then
- lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax`
- elif test -x /usr/sbin/sysctl; then
- lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
- else
- lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs
- fi
- # And add a safety zone
- lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
- lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
- ;;
-
- interix*)
- # We know the value 262144 and hardcode it with a safety zone (like BSD)
- lt_cv_sys_max_cmd_len=196608
- ;;
-
- osf*)
- # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
- # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
- # nice to cause kernel panics so lets avoid the loop below.
- # First set a reasonable default.
- lt_cv_sys_max_cmd_len=16384
- #
- if test -x /sbin/sysconfig; then
- case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
- *1*) lt_cv_sys_max_cmd_len=-1 ;;
- esac
- fi
- ;;
- sco3.2v5*)
- lt_cv_sys_max_cmd_len=102400
- ;;
- sysv5* | sco5v6* | sysv4.2uw2*)
- kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
- if test -n "$kargmax"; then
- lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[ ]//'`
- else
- lt_cv_sys_max_cmd_len=32768
- fi
- ;;
- *)
- lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null`
- if test -n "$lt_cv_sys_max_cmd_len"; then
- lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
- lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
- else
- # Make teststring a little bigger before we do anything with it.
- # a 1K string should be a reasonable start.
- for i in 1 2 3 4 5 6 7 8 ; do
- teststring=$teststring$teststring
- done
- SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
- # If test is not a shell built-in, we'll probably end up computing a
- # maximum length that is only half of the actual maximum length, but
- # we can't tell.
- while { test "X"`func_fallback_echo "$teststring$teststring" 2>/dev/null` \
- = "X$teststring$teststring"; } >/dev/null 2>&1 &&
- test $i != 17 # 1/2 MB should be enough
- do
- i=`expr $i + 1`
- teststring=$teststring$teststring
- done
- # Only check the string length outside the loop.
- lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1`
- teststring=
- # Add a significant safety factor because C++ compilers can tack on
- # massive amounts of additional arguments before passing them to the
- # linker. It appears as though 1/2 is a usable value.
- lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
- fi
- ;;
- esac
-
-fi
-
-if test -n $lt_cv_sys_max_cmd_len ; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sys_max_cmd_len" >&5
-$as_echo "$lt_cv_sys_max_cmd_len" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: none" >&5
-$as_echo "none" >&6; }
-fi
-max_cmd_len=$lt_cv_sys_max_cmd_len
-
-
-
-
-
-
-: ${CP="cp -f"}
-: ${MV="mv -f"}
-: ${RM="rm -f"}
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the shell understands some XSI constructs" >&5
-$as_echo_n "checking whether the shell understands some XSI constructs... " >&6; }
-# Try some XSI features
-xsi_shell=no
-( _lt_dummy="a/b/c"
- test "${_lt_dummy##*/},${_lt_dummy%/*},"${_lt_dummy%"$_lt_dummy"}, \
- = c,a/b,, \
- && eval 'test $(( 1 + 1 )) -eq 2 \
- && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \
- && xsi_shell=yes
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $xsi_shell" >&5
-$as_echo "$xsi_shell" >&6; }
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the shell understands \"+=\"" >&5
-$as_echo_n "checking whether the shell understands \"+=\"... " >&6; }
-lt_shell_append=no
-( foo=bar; set foo baz; eval "$1+=\$2" && test "$foo" = barbaz ) \
- >/dev/null 2>&1 \
- && lt_shell_append=yes
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_shell_append" >&5
-$as_echo "$lt_shell_append" >&6; }
-
-
-if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
- lt_unset=unset
-else
- lt_unset=false
-fi
-
-
-
-
-
-# test EBCDIC or ASCII
-case `echo X|tr X '\101'` in
- A) # ASCII based system
- # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr
- lt_SP2NL='tr \040 \012'
- lt_NL2SP='tr \015\012 \040\040'
- ;;
- *) # EBCDIC based system
- lt_SP2NL='tr \100 \n'
- lt_NL2SP='tr \r\n \100\100'
- ;;
-esac
-
-
-
-
-
-
-
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5
-$as_echo_n "checking for $LD option to reload object files... " >&6; }
-if ${lt_cv_ld_reload_flag+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_ld_reload_flag='-r'
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_reload_flag" >&5
-$as_echo "$lt_cv_ld_reload_flag" >&6; }
-reload_flag=$lt_cv_ld_reload_flag
-case $reload_flag in
-"" | " "*) ;;
-*) reload_flag=" $reload_flag" ;;
-esac
-reload_cmds='$LD$reload_flag -o $output$reload_objs'
-case $host_os in
- darwin*)
- if test "$GCC" = yes; then
- reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
- else
- reload_cmds='$LD$reload_flag -o $output$reload_objs'
- fi
- ;;
-esac
-
-
-
-
-
-
-
-
-
-if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args.
-set dummy ${ac_tool_prefix}objdump; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_OBJDUMP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$OBJDUMP"; then
- ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-OBJDUMP=$ac_cv_prog_OBJDUMP
-if test -n "$OBJDUMP"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5
-$as_echo "$OBJDUMP" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_OBJDUMP"; then
- ac_ct_OBJDUMP=$OBJDUMP
- # Extract the first word of "objdump", so it can be a program name with args.
-set dummy objdump; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_OBJDUMP"; then
- ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_OBJDUMP="objdump"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP
-if test -n "$ac_ct_OBJDUMP"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5
-$as_echo "$ac_ct_OBJDUMP" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_OBJDUMP" = x; then
- OBJDUMP="false"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- OBJDUMP=$ac_ct_OBJDUMP
- fi
-else
- OBJDUMP="$ac_cv_prog_OBJDUMP"
-fi
-
-test -z "$OBJDUMP" && OBJDUMP=objdump
-
-
-
-
-
-
-
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking how to recognize dependent libraries" >&5
-$as_echo_n "checking how to recognize dependent libraries... " >&6; }
-if ${lt_cv_deplibs_check_method+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_file_magic_cmd='$MAGIC_CMD'
-lt_cv_file_magic_test_file=
-lt_cv_deplibs_check_method='unknown'
-# Need to set the preceding variable on all platforms that support
-# interlibrary dependencies.
-# 'none' -- dependencies not supported.
-# `unknown' -- same as none, but documents that we really don't know.
-# 'pass_all' -- all dependencies passed with no checks.
-# 'test_compile' -- check by making test program.
-# 'file_magic [[regex]]' -- check by looking for files in library path
-# which responds to the $file_magic_cmd with a given extended regex.
-# If you have `file' or equivalent on your system and you're not sure
-# whether `pass_all' will *always* work, you probably want this one.
-
-case $host_os in
-aix[4-9]*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-beos*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-bsdi[45]*)
- lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)'
- lt_cv_file_magic_cmd='/usr/bin/file -L'
- lt_cv_file_magic_test_file=/shlib/libc.so
- ;;
-
-cygwin*)
- # func_win32_libid is a shell function defined in ltmain.sh
- lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
- lt_cv_file_magic_cmd='func_win32_libid'
- ;;
-
-mingw* | pw32*)
- # Base MSYS/MinGW do not provide the 'file' command needed by
- # func_win32_libid shell function, so use a weaker test based on 'objdump',
- # unless we find 'file', for example because we are cross-compiling.
- # func_win32_libid assumes BSD nm, so disallow it if using MS dumpbin.
- if ( test "$lt_cv_nm_interface" = "BSD nm" && file / ) >/dev/null 2>&1; then
- lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
- lt_cv_file_magic_cmd='func_win32_libid'
- else
- lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
- lt_cv_file_magic_cmd='$OBJDUMP -f'
- fi
- ;;
-
-cegcc*)
- # use the weaker test based on 'objdump'. See mingw*.
- lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?'
- lt_cv_file_magic_cmd='$OBJDUMP -f'
- ;;
-
-darwin* | rhapsody*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-freebsd* | dragonfly*)
- if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
- case $host_cpu in
- i*86 )
- # Not sure whether the presence of OpenBSD here was a mistake.
- # Let's accept both of them until this is cleared up.
- lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library'
- lt_cv_file_magic_cmd=/usr/bin/file
- lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*`
- ;;
- esac
- else
- lt_cv_deplibs_check_method=pass_all
- fi
- ;;
-
-gnu*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-haiku*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-hpux10.20* | hpux11*)
- lt_cv_file_magic_cmd=/usr/bin/file
- case $host_cpu in
- ia64*)
- lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64'
- lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so
- ;;
- hppa*64*)
- lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF[ -][0-9][0-9])(-bit)?( [LM]SB)? shared object( file)?[, -]* PA-RISC [0-9]\.[0-9]'
- lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl
- ;;
- *)
- lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9]\.[0-9]) shared library'
- lt_cv_file_magic_test_file=/usr/lib/libc.sl
- ;;
- esac
- ;;
-
-interix[3-9]*)
- # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
- lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|\.a)$'
- ;;
-
-irix5* | irix6* | nonstopux*)
- case $LD in
- *-32|*"-32 ") libmagic=32-bit;;
- *-n32|*"-n32 ") libmagic=N32;;
- *-64|*"-64 ") libmagic=64-bit;;
- *) libmagic=never-match;;
- esac
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-# This must be Linux ELF.
-linux* | k*bsd*-gnu | kopensolaris*-gnu | uclinuxfdpiceabi)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-netbsd*)
- if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then
- lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
- else
- lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$'
- fi
- ;;
-
-newos6*)
- lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)'
- lt_cv_file_magic_cmd=/usr/bin/file
- lt_cv_file_magic_test_file=/usr/lib/libnls.so
- ;;
-
-*nto* | *qnx*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-openbsd*)
- if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
- lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$'
- else
- lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$'
- fi
- ;;
-
-osf3* | osf4* | osf5*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-rdos*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-solaris*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-
-sysv4 | sysv4.3*)
- case $host_vendor in
- motorola)
- lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib) M[0-9][0-9]* Version [0-9]'
- lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*`
- ;;
- ncr)
- lt_cv_deplibs_check_method=pass_all
- ;;
- sequent)
- lt_cv_file_magic_cmd='/bin/file'
- lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )'
- ;;
- sni)
- lt_cv_file_magic_cmd='/bin/file'
- lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib"
- lt_cv_file_magic_test_file=/lib/libc.so
- ;;
- siemens)
- lt_cv_deplibs_check_method=pass_all
- ;;
- pc)
- lt_cv_deplibs_check_method=pass_all
- ;;
- esac
- ;;
-
-tpf*)
- lt_cv_deplibs_check_method=pass_all
- ;;
-vxworks*)
- # Assume VxWorks cross toolchains are built on Linux, possibly
- # as canadian for Windows hosts.
- lt_cv_deplibs_check_method=pass_all
- ;;
-esac
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5
-$as_echo "$lt_cv_deplibs_check_method" >&6; }
-file_magic_cmd=$lt_cv_file_magic_cmd
-deplibs_check_method=$lt_cv_deplibs_check_method
-test -z "$deplibs_check_method" && deplibs_check_method=unknown
-
-
-
-
-
-
-
-
-
-
-
-
-plugin_option=
-plugin_names="liblto_plugin.so liblto_plugin-0.dll cyglto_plugin-0.dll"
-for plugin in $plugin_names; do
- plugin_so=`${CC} ${CFLAGS} --print-prog-name $plugin`
- if test x$plugin_so = x$plugin; then
- plugin_so=`${CC} ${CFLAGS} --print-file-name $plugin`
- fi
- if test x$plugin_so != x$plugin; then
- plugin_option="--plugin $plugin_so"
- break
- fi
-done
-
-if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
-set dummy ${ac_tool_prefix}ar; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_AR+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$AR"; then
- ac_cv_prog_AR="$AR" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_AR="${ac_tool_prefix}ar"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-AR=$ac_cv_prog_AR
-if test -n "$AR"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
-$as_echo "$AR" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_AR"; then
- ac_ct_AR=$AR
- # Extract the first word of "ar", so it can be a program name with args.
-set dummy ar; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_AR+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_AR"; then
- ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_AR="ar"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_AR=$ac_cv_prog_ac_ct_AR
-if test -n "$ac_ct_AR"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
-$as_echo "$ac_ct_AR" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_AR" = x; then
- AR="false"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- AR=$ac_ct_AR
- fi
-else
- AR="$ac_cv_prog_AR"
-fi
-
-test -z "$AR" && AR=ar
-if test -n "$plugin_option"; then
- if $AR --help 2>&1 | grep -q "\--plugin"; then
- touch conftest.c
- $AR $plugin_option rc conftest.a conftest.c
- if test "$?" != 0; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed: $AR $plugin_option rc" >&5
-$as_echo "$as_me: WARNING: Failed: $AR $plugin_option rc" >&2;}
- else
- AR="$AR $plugin_option"
- fi
- rm -f conftest.*
- fi
-fi
-test -z "$AR_FLAGS" && AR_FLAGS=cru
-
-
-
-
-
-
-
-
-
-
-
-if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
-set dummy ${ac_tool_prefix}strip; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_STRIP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$STRIP"; then
- ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_STRIP="${ac_tool_prefix}strip"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-STRIP=$ac_cv_prog_STRIP
-if test -n "$STRIP"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
-$as_echo "$STRIP" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_STRIP"; then
- ac_ct_STRIP=$STRIP
- # Extract the first word of "strip", so it can be a program name with args.
-set dummy strip; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_STRIP+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_STRIP"; then
- ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_STRIP="strip"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
-if test -n "$ac_ct_STRIP"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
-$as_echo "$ac_ct_STRIP" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_STRIP" = x; then
- STRIP=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- STRIP=$ac_ct_STRIP
- fi
-else
- STRIP="$ac_cv_prog_STRIP"
-fi
-
-test -z "$STRIP" && STRIP=:
-
-
-
-
-
-
-if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
-set dummy ${ac_tool_prefix}ranlib; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_RANLIB+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$RANLIB"; then
- ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-RANLIB=$ac_cv_prog_RANLIB
-if test -n "$RANLIB"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
-$as_echo "$RANLIB" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_RANLIB"; then
- ac_ct_RANLIB=$RANLIB
- # Extract the first word of "ranlib", so it can be a program name with args.
-set dummy ranlib; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_RANLIB+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_RANLIB"; then
- ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_RANLIB="ranlib"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
-if test -n "$ac_ct_RANLIB"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
-$as_echo "$ac_ct_RANLIB" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_RANLIB" = x; then
- RANLIB=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- RANLIB=$ac_ct_RANLIB
- fi
-else
- RANLIB="$ac_cv_prog_RANLIB"
-fi
-
-test -z "$RANLIB" && RANLIB=:
-if test -n "$plugin_option" && test "$RANLIB" != ":"; then
- if $RANLIB --help 2>&1 | grep -q "\--plugin"; then
- RANLIB="$RANLIB $plugin_option"
- fi
-fi
-
-
-
-
-
-
-# Determine commands to create old-style static archives.
-old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs'
-old_postinstall_cmds='chmod 644 $oldlib'
-old_postuninstall_cmds=
-
-if test -n "$RANLIB"; then
- case $host_os in
- openbsd*)
- old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib"
- ;;
- *)
- old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib"
- ;;
- esac
- old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib"
-fi
-
-case $host_os in
- darwin*)
- lock_old_archive_extraction=yes ;;
- *)
- lock_old_archive_extraction=no ;;
-esac
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-# If no C compiler was specified, use CC.
-LTCC=${LTCC-"$CC"}
-
-# If no C compiler flags were specified, use CFLAGS.
-LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
-
-# Allow CC to be a program name with arguments.
-compiler=$CC
-
-
-# Check for command to grab the raw symbol name followed by C symbol from nm.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking command to parse $NM output from $compiler object" >&5
-$as_echo_n "checking command to parse $NM output from $compiler object... " >&6; }
-if ${lt_cv_sys_global_symbol_pipe+:} false; then :
- $as_echo_n "(cached) " >&6
-else
-
-# These are sane defaults that work on at least a few old systems.
-# [They come from Ultrix. What could be older than Ultrix?!! ;)]
-
-# Character class describing NM global symbol codes.
-symcode='[BCDEGRST]'
-
-# Regexp to match symbols that can be accessed directly from C.
-sympat='\([_A-Za-z][_A-Za-z0-9]*\)'
-
-# Define system-specific variables.
-case $host_os in
-aix*)
- symcode='[BCDT]'
- ;;
-cygwin* | mingw* | pw32* | cegcc*)
- symcode='[ABCDGISTW]'
- ;;
-hpux*)
- if test "$host_cpu" = ia64; then
- symcode='[ABCDEGRST]'
- fi
- ;;
-irix* | nonstopux*)
- symcode='[BCDEGRST]'
- ;;
-osf*)
- symcode='[BCDEGQRST]'
- ;;
-solaris*)
- symcode='[BCDRT]'
- ;;
-sco3.2v5*)
- symcode='[DT]'
- ;;
-sysv4.2uw2*)
- symcode='[DT]'
- ;;
-sysv5* | sco5v6* | unixware* | OpenUNIX*)
- symcode='[ABDT]'
- ;;
-sysv4)
- symcode='[DFNSTU]'
- ;;
-esac
-
-# If we're using GNU nm, then use its standard symbol codes.
-case `$NM -V 2>&1` in
-*GNU* | *'with BFD'*)
- symcode='[ABCDGIRSTW]' ;;
-esac
-
-# Transform an extracted symbol line into a proper C declaration.
-# Some systems (esp. on ia64) link data and code symbols differently,
-# so use this general approach.
-lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
-
-# Transform an extracted symbol line into symbol name and symbol address
-lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"\2\", (void *) \&\2},/p'"
-lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \(lib[^ ]*\)$/ {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"lib\2\", (void *) \&\2},/p'"
-
-# Handle CRLF in mingw tool chain
-opt_cr=
-case $build_os in
-mingw*)
- opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp
- ;;
-esac
-
-# Try without a prefix underscore, then with it.
-for ac_symprfx in "" "_"; do
-
- # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol.
- symxfrm="\\1 $ac_symprfx\\2 \\2"
-
- # Write the raw and C identifiers.
- if test "$lt_cv_nm_interface" = "MS dumpbin"; then
- # Fake it for dumpbin and say T for any non-static function
- # and D for any global variable.
- # Also find C++ and __fastcall symbols from MSVC++,
- # which start with @ or ?.
- lt_cv_sys_global_symbol_pipe="$AWK '"\
-" {last_section=section; section=\$ 3};"\
-" /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\
-" \$ 0!~/External *\|/{next};"\
-" / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\
-" {if(hide[section]) next};"\
-" {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\
-" {split(\$ 0, a, /\||\r/); split(a[2], s)};"\
-" s[1]~/^[@?]/{print s[1], s[1]; next};"\
-" s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\
-" ' prfx=^$ac_symprfx"
- else
- lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[ ]\($symcode$symcode*\)[ ][ ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'"
- fi
-
- # Check to see that the pipe works correctly.
- pipe_works=no
-
- rm -f conftest*
- cat > conftest.$ac_ext <<_LT_EOF
-#ifdef __cplusplus
-extern "C" {
-#endif
-char nm_test_var;
-void nm_test_func(void);
-void nm_test_func(void){}
-#ifdef __cplusplus
-}
-#endif
-int main(){nm_test_var='a';nm_test_func();return(0);}
-_LT_EOF
-
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
- (eval $ac_compile) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- # Now try to grab the symbols.
- nlist=conftest.nm
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist\""; } >&5
- (eval $NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && test -s "$nlist"; then
- # Try sorting and uniquifying the output.
- if sort "$nlist" | uniq > "$nlist"T; then
- mv -f "$nlist"T "$nlist"
- else
- rm -f "$nlist"T
- fi
-
- # Make sure that we snagged all the symbols we need.
- if $GREP ' nm_test_var$' "$nlist" >/dev/null; then
- if $GREP ' nm_test_func$' "$nlist" >/dev/null; then
- cat <<_LT_EOF > conftest.$ac_ext
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-_LT_EOF
- # Now generate the symbol file.
- eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext'
-
- cat <<_LT_EOF >> conftest.$ac_ext
-
-/* The mapping between symbol names and symbols. */
-const struct {
- const char *name;
- void *address;
-}
-lt__PROGRAM__LTX_preloaded_symbols[] =
-{
- { "@PROGRAM@", (void *) 0 },
-_LT_EOF
- $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext
- cat <<\_LT_EOF >> conftest.$ac_ext
- {0, (void *) 0}
-};
-
-/* This works around a problem in FreeBSD linker */
-#ifdef FREEBSD_WORKAROUND
-static const void *lt_preloaded_setup() {
- return lt__PROGRAM__LTX_preloaded_symbols;
-}
-#endif
-
-#ifdef __cplusplus
-}
-#endif
-_LT_EOF
- # Now try linking the two files.
- mv conftest.$ac_objext conftstm.$ac_objext
- lt_save_LIBS="$LIBS"
- lt_save_CFLAGS="$CFLAGS"
- LIBS="conftstm.$ac_objext"
- CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag"
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
- (eval $ac_link) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && test -s conftest${ac_exeext}; then
- pipe_works=yes
- fi
- LIBS="$lt_save_LIBS"
- CFLAGS="$lt_save_CFLAGS"
- else
- echo "cannot find nm_test_func in $nlist" >&5
- fi
- else
- echo "cannot find nm_test_var in $nlist" >&5
- fi
- else
- echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5
- fi
- else
- echo "$progname: failed program was:" >&5
- cat conftest.$ac_ext >&5
- fi
- rm -rf conftest* conftst*
-
- # Do not use the global_symbol_pipe unless it works.
- if test "$pipe_works" = yes; then
- break
- else
- lt_cv_sys_global_symbol_pipe=
- fi
-done
-
-fi
-
-if test -z "$lt_cv_sys_global_symbol_pipe"; then
- lt_cv_sys_global_symbol_to_cdecl=
-fi
-if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5
-$as_echo "failed" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5
-$as_echo "ok" >&6; }
-fi
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-# Check whether --enable-libtool-lock was given.
-if test "${enable_libtool_lock+set}" = set; then :
- enableval=$enable_libtool_lock;
-fi
-
-test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes
-
-# Some flags need to be propagated to the compiler or linker for good
-# libtool support.
-case $host in
-ia64-*-hpux*)
- # Find out which ABI we are using.
- echo 'int i;' > conftest.$ac_ext
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
- (eval $ac_compile) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- case `/usr/bin/file conftest.$ac_objext` in
- *ELF-32*)
- HPUX_IA64_MODE="32"
- ;;
- *ELF-64*)
- HPUX_IA64_MODE="64"
- ;;
- esac
- fi
- rm -rf conftest*
- ;;
-*-*-irix6*)
- # Find out which ABI we are using.
- echo '#line '$LINENO' "configure"' > conftest.$ac_ext
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
- (eval $ac_compile) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- if test "$lt_cv_prog_gnu_ld" = yes; then
- case `/usr/bin/file conftest.$ac_objext` in
- *32-bit*)
- LD="${LD-ld} -melf32bsmip"
- ;;
- *N32*)
- LD="${LD-ld} -melf32bmipn32"
- ;;
- *64-bit*)
- LD="${LD-ld} -melf64bmip"
- ;;
- esac
- else
- case `/usr/bin/file conftest.$ac_objext` in
- *32-bit*)
- LD="${LD-ld} -32"
- ;;
- *N32*)
- LD="${LD-ld} -n32"
- ;;
- *64-bit*)
- LD="${LD-ld} -64"
- ;;
- esac
- fi
- fi
- rm -rf conftest*
- ;;
-
-x86_64-*kfreebsd*-gnu|x86_64-*linux*|powerpc*-*linux*| \
-s390*-*linux*|s390*-*tpf*|sparc*-*linux*)
- # Find out which ABI we are using.
- echo 'int i;' > conftest.$ac_ext
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
- (eval $ac_compile) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- case `/usr/bin/file conftest.o` in
- *32-bit*)
- case $host in
- x86_64-*kfreebsd*-gnu)
- LD="${LD-ld} -m elf_i386_fbsd"
- ;;
- x86_64-*linux*)
- case `/usr/bin/file conftest.o` in
- *x86-64*)
- LD="${LD-ld} -m elf32_x86_64"
- ;;
- *)
- LD="${LD-ld} -m elf_i386"
- ;;
- esac
- ;;
- powerpc64le-*linux*)
- LD="${LD-ld} -m elf32lppclinux"
- ;;
- powerpc64-*linux*)
- LD="${LD-ld} -m elf32ppclinux"
- ;;
- s390x-*linux*)
- LD="${LD-ld} -m elf_s390"
- ;;
- sparc64-*linux*)
- LD="${LD-ld} -m elf32_sparc"
- ;;
- esac
- ;;
- *64-bit*)
- case $host in
- x86_64-*kfreebsd*-gnu)
- LD="${LD-ld} -m elf_x86_64_fbsd"
- ;;
- x86_64-*linux*)
- LD="${LD-ld} -m elf_x86_64"
- ;;
- powerpcle-*linux*)
- LD="${LD-ld} -m elf64lppc"
- ;;
- powerpc-*linux*)
- LD="${LD-ld} -m elf64ppc"
- ;;
- s390*-*linux*|s390*-*tpf*)
- LD="${LD-ld} -m elf64_s390"
- ;;
- sparc*-*linux*)
- LD="${LD-ld} -m elf64_sparc"
- ;;
- esac
- ;;
- esac
- fi
- rm -rf conftest*
- ;;
-
-*-*-sco3.2v5*)
- # On SCO OpenServer 5, we need -belf to get full-featured binaries.
- SAVE_CFLAGS="$CFLAGS"
- CFLAGS="$CFLAGS -belf"
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler needs -belf" >&5
-$as_echo_n "checking whether the C compiler needs -belf... " >&6; }
-if ${lt_cv_cc_needs_belf+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- lt_cv_cc_needs_belf=yes
-else
- lt_cv_cc_needs_belf=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_cc_needs_belf" >&5
-$as_echo "$lt_cv_cc_needs_belf" >&6; }
- if test x"$lt_cv_cc_needs_belf" != x"yes"; then
- # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf
- CFLAGS="$SAVE_CFLAGS"
- fi
- ;;
-sparc*-*solaris*)
- # Find out which ABI we are using.
- echo 'int i;' > conftest.$ac_ext
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
- (eval $ac_compile) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }; then
- case `/usr/bin/file conftest.o` in
- *64-bit*)
- case $lt_cv_prog_gnu_ld in
- yes*) LD="${LD-ld} -m elf64_sparc" ;;
- *)
- if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then
- LD="${LD-ld} -64"
- fi
- ;;
- esac
- ;;
- esac
- fi
- rm -rf conftest*
- ;;
-esac
-
-need_locks="$enable_libtool_lock"
-
-
- case $host_os in
- rhapsody* | darwin*)
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}dsymutil", so it can be a program name with args.
-set dummy ${ac_tool_prefix}dsymutil; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_DSYMUTIL+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$DSYMUTIL"; then
- ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_DSYMUTIL="${ac_tool_prefix}dsymutil"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-DSYMUTIL=$ac_cv_prog_DSYMUTIL
-if test -n "$DSYMUTIL"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5
-$as_echo "$DSYMUTIL" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_DSYMUTIL"; then
- ac_ct_DSYMUTIL=$DSYMUTIL
- # Extract the first word of "dsymutil", so it can be a program name with args.
-set dummy dsymutil; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_DSYMUTIL+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_DSYMUTIL"; then
- ac_cv_prog_ac_ct_DSYMUTIL="$ac_ct_DSYMUTIL" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_DSYMUTIL="dsymutil"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_DSYMUTIL=$ac_cv_prog_ac_ct_DSYMUTIL
-if test -n "$ac_ct_DSYMUTIL"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DSYMUTIL" >&5
-$as_echo "$ac_ct_DSYMUTIL" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_DSYMUTIL" = x; then
- DSYMUTIL=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- DSYMUTIL=$ac_ct_DSYMUTIL
- fi
-else
- DSYMUTIL="$ac_cv_prog_DSYMUTIL"
-fi
-
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}nmedit", so it can be a program name with args.
-set dummy ${ac_tool_prefix}nmedit; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_NMEDIT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$NMEDIT"; then
- ac_cv_prog_NMEDIT="$NMEDIT" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_NMEDIT="${ac_tool_prefix}nmedit"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-NMEDIT=$ac_cv_prog_NMEDIT
-if test -n "$NMEDIT"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NMEDIT" >&5
-$as_echo "$NMEDIT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_NMEDIT"; then
- ac_ct_NMEDIT=$NMEDIT
- # Extract the first word of "nmedit", so it can be a program name with args.
-set dummy nmedit; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_NMEDIT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_NMEDIT"; then
- ac_cv_prog_ac_ct_NMEDIT="$ac_ct_NMEDIT" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_NMEDIT="nmedit"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_NMEDIT=$ac_cv_prog_ac_ct_NMEDIT
-if test -n "$ac_ct_NMEDIT"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NMEDIT" >&5
-$as_echo "$ac_ct_NMEDIT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_NMEDIT" = x; then
- NMEDIT=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- NMEDIT=$ac_ct_NMEDIT
- fi
-else
- NMEDIT="$ac_cv_prog_NMEDIT"
-fi
-
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}lipo", so it can be a program name with args.
-set dummy ${ac_tool_prefix}lipo; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_LIPO+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$LIPO"; then
- ac_cv_prog_LIPO="$LIPO" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_LIPO="${ac_tool_prefix}lipo"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-LIPO=$ac_cv_prog_LIPO
-if test -n "$LIPO"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5
-$as_echo "$LIPO" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_LIPO"; then
- ac_ct_LIPO=$LIPO
- # Extract the first word of "lipo", so it can be a program name with args.
-set dummy lipo; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_LIPO+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_LIPO"; then
- ac_cv_prog_ac_ct_LIPO="$ac_ct_LIPO" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_LIPO="lipo"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_LIPO=$ac_cv_prog_ac_ct_LIPO
-if test -n "$ac_ct_LIPO"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LIPO" >&5
-$as_echo "$ac_ct_LIPO" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_LIPO" = x; then
- LIPO=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- LIPO=$ac_ct_LIPO
- fi
-else
- LIPO="$ac_cv_prog_LIPO"
-fi
-
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}otool", so it can be a program name with args.
-set dummy ${ac_tool_prefix}otool; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_OTOOL+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$OTOOL"; then
- ac_cv_prog_OTOOL="$OTOOL" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_OTOOL="${ac_tool_prefix}otool"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-OTOOL=$ac_cv_prog_OTOOL
-if test -n "$OTOOL"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5
-$as_echo "$OTOOL" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_OTOOL"; then
- ac_ct_OTOOL=$OTOOL
- # Extract the first word of "otool", so it can be a program name with args.
-set dummy otool; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_OTOOL+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_OTOOL"; then
- ac_cv_prog_ac_ct_OTOOL="$ac_ct_OTOOL" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_OTOOL="otool"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_OTOOL=$ac_cv_prog_ac_ct_OTOOL
-if test -n "$ac_ct_OTOOL"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL" >&5
-$as_echo "$ac_ct_OTOOL" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_OTOOL" = x; then
- OTOOL=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- OTOOL=$ac_ct_OTOOL
- fi
-else
- OTOOL="$ac_cv_prog_OTOOL"
-fi
-
- if test -n "$ac_tool_prefix"; then
- # Extract the first word of "${ac_tool_prefix}otool64", so it can be a program name with args.
-set dummy ${ac_tool_prefix}otool64; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_OTOOL64+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$OTOOL64"; then
- ac_cv_prog_OTOOL64="$OTOOL64" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_OTOOL64="${ac_tool_prefix}otool64"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-OTOOL64=$ac_cv_prog_OTOOL64
-if test -n "$OTOOL64"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL64" >&5
-$as_echo "$OTOOL64" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-fi
-if test -z "$ac_cv_prog_OTOOL64"; then
- ac_ct_OTOOL64=$OTOOL64
- # Extract the first word of "otool64", so it can be a program name with args.
-set dummy otool64; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_prog_ac_ct_OTOOL64+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -n "$ac_ct_OTOOL64"; then
- ac_cv_prog_ac_ct_OTOOL64="$ac_ct_OTOOL64" # Let the user override the test.
-else
-as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_prog_ac_ct_OTOOL64="otool64"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
-fi
-fi
-ac_ct_OTOOL64=$ac_cv_prog_ac_ct_OTOOL64
-if test -n "$ac_ct_OTOOL64"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL64" >&5
-$as_echo "$ac_ct_OTOOL64" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- if test "x$ac_ct_OTOOL64" = x; then
- OTOOL64=":"
- else
- case $cross_compiling:$ac_tool_warned in
-yes:)
-{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
-$as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
-ac_tool_warned=yes ;;
-esac
- OTOOL64=$ac_ct_OTOOL64
- fi
-else
- OTOOL64="$ac_cv_prog_OTOOL64"
-fi
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -single_module linker flag" >&5
-$as_echo_n "checking for -single_module linker flag... " >&6; }
-if ${lt_cv_apple_cc_single_mod+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_apple_cc_single_mod=no
- if test -z "${LT_MULTI_MODULE}"; then
- # By default we will add the -single_module flag. You can override
- # by either setting the environment variable LT_MULTI_MODULE
- # non-empty at configure time, or by adding -multi_module to the
- # link flags.
- rm -rf libconftest.dylib*
- echo "int foo(void){return 1;}" > conftest.c
- echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
--dynamiclib -Wl,-single_module conftest.c" >&5
- $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
- -dynamiclib -Wl,-single_module conftest.c 2>conftest.err
- _lt_result=$?
- if test -f libconftest.dylib && test ! -s conftest.err && test $_lt_result = 0; then
- lt_cv_apple_cc_single_mod=yes
- else
- cat conftest.err >&5
- fi
- rm -rf libconftest.dylib*
- rm -f conftest.*
- fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_apple_cc_single_mod" >&5
-$as_echo "$lt_cv_apple_cc_single_mod" >&6; }
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -exported_symbols_list linker flag" >&5
-$as_echo_n "checking for -exported_symbols_list linker flag... " >&6; }
-if ${lt_cv_ld_exported_symbols_list+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_ld_exported_symbols_list=no
- save_LDFLAGS=$LDFLAGS
- echo "_main" > conftest.sym
- LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- lt_cv_ld_exported_symbols_list=yes
-else
- lt_cv_ld_exported_symbols_list=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LDFLAGS="$save_LDFLAGS"
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_exported_symbols_list" >&5
-$as_echo "$lt_cv_ld_exported_symbols_list" >&6; }
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -force_load linker flag" >&5
-$as_echo_n "checking for -force_load linker flag... " >&6; }
-if ${lt_cv_ld_force_load+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_ld_force_load=no
- cat > conftest.c << _LT_EOF
-int forced_loaded() { return 2;}
-_LT_EOF
- echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&5
- $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5
- echo "$AR cru libconftest.a conftest.o" >&5
- $AR cru libconftest.a conftest.o 2>&5
- cat > conftest.c << _LT_EOF
-int main() { return 0;}
-_LT_EOF
- echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&5
- $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err
- _lt_result=$?
- if test -f conftest && test ! -s conftest.err && test $_lt_result = 0 && $GREP forced_load conftest 2>&1 >/dev/null; then
- lt_cv_ld_force_load=yes
- else
- cat conftest.err >&5
- fi
- rm -f conftest.err libconftest.a conftest conftest.c
- rm -rf conftest.dSYM
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_force_load" >&5
-$as_echo "$lt_cv_ld_force_load" >&6; }
- # Allow for Darwin 4-7 (macOS 10.0-10.3) although these are not expect to
- # build without first building modern cctools / linker.
- case $host_cpu-$host_os in
- *-rhapsody* | *-darwin1.[012])
- _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;;
- *-darwin1.*)
- _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
- *-darwin*)
- # darwin 5.x (macOS 10.1) onwards we only need to adjust when the
- # deployment target is forced to an earlier version.
- case ${MACOSX_DEPLOYMENT_TARGET-UNSET},$host in
- UNSET,*-darwin[89]*|UNSET,*-darwin[12][0123456789]*)
- ;;
- 10.[012][,.]*)
- _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
- ;;
- *)
- ;;
- esac
- ;;
- esac
- if test "$lt_cv_apple_cc_single_mod" = "yes"; then
- _lt_dar_single_mod='$single_module'
- fi
- if test "$lt_cv_ld_exported_symbols_list" = "yes"; then
- _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym'
- else
- _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}'
- fi
- if test "$DSYMUTIL" != ":" && test "$lt_cv_ld_force_load" = "no"; then
- _lt_dsymutil='~$DSYMUTIL $lib || :'
- else
- _lt_dsymutil=
- fi
- ;;
- esac
-
-for ac_header in dlfcn.h
-do :
- ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default
-"
-if test "x$ac_cv_header_dlfcn_h" = xyes; then :
- cat >>confdefs.h <<_ACEOF
-#define HAVE_DLFCN_H 1
-_ACEOF
-
-fi
-
-done
-
-
-
-
-
-# Set options
-
-
-
- enable_dlopen=no
-
-
- enable_win32_dll=no
-
-
-
- # Check whether --enable-static was given.
-if test "${enable_static+set}" = set; then :
- enableval=$enable_static; p=${PACKAGE-default}
- case $enableval in
- yes) enable_static=yes ;;
- no) enable_static=no ;;
- *)
- enable_static=no
- # Look at the argument we got. We use all the common list separators.
- lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
- for pkg in $enableval; do
- IFS="$lt_save_ifs"
- if test "X$pkg" = "X$p"; then
- enable_static=yes
- fi
- done
- IFS="$lt_save_ifs"
- ;;
- esac
-else
- enable_static=yes
-fi
-
-
-
-
-
-
-
-
-
-
-# Check whether --with-pic was given.
-if test "${with_pic+set}" = set; then :
- withval=$with_pic; pic_mode="$withval"
-else
- pic_mode=default
-fi
-
-
-test -z "$pic_mode" && pic_mode=default
-
-
-
-
-
-
-
- # Check whether --enable-fast-install was given.
-if test "${enable_fast_install+set}" = set; then :
- enableval=$enable_fast_install; p=${PACKAGE-default}
- case $enableval in
- yes) enable_fast_install=yes ;;
- no) enable_fast_install=no ;;
- *)
- enable_fast_install=no
- # Look at the argument we got. We use all the common list separators.
- lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR,"
- for pkg in $enableval; do
- IFS="$lt_save_ifs"
- if test "X$pkg" = "X$p"; then
- enable_fast_install=yes
- fi
- done
- IFS="$lt_save_ifs"
- ;;
- esac
-else
- enable_fast_install=yes
-fi
-
-
-
-
-
-
-
-
-
-
-
-# This can be used to rebuild libtool when needed
-LIBTOOL_DEPS="$ltmain"
-
-# Always use our own libtool.
-LIBTOOL='$(SHELL) $(top_builddir)/libtool'
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-test -z "$LN_S" && LN_S="ln -s"
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-if test -n "${ZSH_VERSION+set}" ; then
- setopt NO_GLOB_SUBST
-fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for objdir" >&5
-$as_echo_n "checking for objdir... " >&6; }
-if ${lt_cv_objdir+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- rm -f .libs 2>/dev/null
-mkdir .libs 2>/dev/null
-if test -d .libs; then
- lt_cv_objdir=.libs
-else
- # MS-DOS does not allow filenames that begin with a dot.
- lt_cv_objdir=_libs
-fi
-rmdir .libs 2>/dev/null
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_objdir" >&5
-$as_echo "$lt_cv_objdir" >&6; }
-objdir=$lt_cv_objdir
-
-
-
-
-
-cat >>confdefs.h <<_ACEOF
-#define LT_OBJDIR "$lt_cv_objdir/"
-_ACEOF
-
-
-
-
-case $host_os in
-aix3*)
- # AIX sometimes has problems with the GCC collect2 program. For some
- # reason, if we set the COLLECT_NAMES environment variable, the problems
- # vanish in a puff of smoke.
- if test "X${COLLECT_NAMES+set}" != Xset; then
- COLLECT_NAMES=
- export COLLECT_NAMES
- fi
- ;;
-esac
-
-# Global variables:
-ofile=libtool
-can_build_shared=yes
-
-# All known linkers require a `.a' archive for static linking (except MSVC,
-# which needs '.lib').
-libext=a
-
-with_gnu_ld="$lt_cv_prog_gnu_ld"
-
-old_CC="$CC"
-old_CFLAGS="$CFLAGS"
-
-# Set sane defaults for various variables
-test -z "$CC" && CC=cc
-test -z "$LTCC" && LTCC=$CC
-test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
-test -z "$LD" && LD=ld
-test -z "$ac_objext" && ac_objext=o
-
-for cc_temp in $compiler""; do
- case $cc_temp in
- compile | *[\\/]compile | ccache | *[\\/]ccache ) ;;
- distcc | *[\\/]distcc | purify | *[\\/]purify ) ;;
- \-*) ;;
- *) break;;
- esac
-done
-cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"`
-
-
-# Only perform the check for file, if the check method requires it
-test -z "$MAGIC_CMD" && MAGIC_CMD=file
-case $deplibs_check_method in
-file_magic*)
- if test "$file_magic_cmd" = '$MAGIC_CMD'; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ac_tool_prefix}file" >&5
-$as_echo_n "checking for ${ac_tool_prefix}file... " >&6; }
-if ${lt_cv_path_MAGIC_CMD+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $MAGIC_CMD in
-[\\/*] | ?:[\\/]*)
- lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
- ;;
-*)
- lt_save_MAGIC_CMD="$MAGIC_CMD"
- lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
- ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
- for ac_dir in $ac_dummy; do
- IFS="$lt_save_ifs"
- test -z "$ac_dir" && ac_dir=.
- if test -f $ac_dir/${ac_tool_prefix}file; then
- lt_cv_path_MAGIC_CMD="$ac_dir/${ac_tool_prefix}file"
- if test -n "$file_magic_test_file"; then
- case $deplibs_check_method in
- "file_magic "*)
- file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
- MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
- if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
- $EGREP "$file_magic_regex" > /dev/null; then
- :
- else
- cat <<_LT_EOF 1>&2
-
-*** Warning: the command libtool uses to detect shared libraries,
-*** $file_magic_cmd, produces output that libtool cannot recognize.
-*** The result is that libtool may fail to recognize shared libraries
-*** as such. This will affect the creation of libtool libraries that
-*** depend on shared libraries, but programs linked with such libtool
-*** libraries will work regardless of this problem. Nevertheless, you
-*** may want to report the problem to your system manager and/or to
-*** bug-libtool@gnu.org
-
-_LT_EOF
- fi ;;
- esac
- fi
- break
- fi
- done
- IFS="$lt_save_ifs"
- MAGIC_CMD="$lt_save_MAGIC_CMD"
- ;;
-esac
-fi
-
-MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
-if test -n "$MAGIC_CMD"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5
-$as_echo "$MAGIC_CMD" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-
-
-
-if test -z "$lt_cv_path_MAGIC_CMD"; then
- if test -n "$ac_tool_prefix"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for file" >&5
-$as_echo_n "checking for file... " >&6; }
-if ${lt_cv_path_MAGIC_CMD+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $MAGIC_CMD in
-[\\/*] | ?:[\\/]*)
- lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path.
- ;;
-*)
- lt_save_MAGIC_CMD="$MAGIC_CMD"
- lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
- ac_dummy="/usr/bin$PATH_SEPARATOR$PATH"
- for ac_dir in $ac_dummy; do
- IFS="$lt_save_ifs"
- test -z "$ac_dir" && ac_dir=.
- if test -f $ac_dir/file; then
- lt_cv_path_MAGIC_CMD="$ac_dir/file"
- if test -n "$file_magic_test_file"; then
- case $deplibs_check_method in
- "file_magic "*)
- file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"`
- MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
- if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null |
- $EGREP "$file_magic_regex" > /dev/null; then
- :
- else
- cat <<_LT_EOF 1>&2
-
-*** Warning: the command libtool uses to detect shared libraries,
-*** $file_magic_cmd, produces output that libtool cannot recognize.
-*** The result is that libtool may fail to recognize shared libraries
-*** as such. This will affect the creation of libtool libraries that
-*** depend on shared libraries, but programs linked with such libtool
-*** libraries will work regardless of this problem. Nevertheless, you
-*** may want to report the problem to your system manager and/or to
-*** bug-libtool@gnu.org
-
-_LT_EOF
- fi ;;
- esac
- fi
- break
- fi
- done
- IFS="$lt_save_ifs"
- MAGIC_CMD="$lt_save_MAGIC_CMD"
- ;;
-esac
-fi
-
-MAGIC_CMD="$lt_cv_path_MAGIC_CMD"
-if test -n "$MAGIC_CMD"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5
-$as_echo "$MAGIC_CMD" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- else
- MAGIC_CMD=:
- fi
-fi
-
- fi
- ;;
-esac
-
-# Use C for the default configuration in the libtool script
-
-lt_save_CC="$CC"
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-
-# Source file extension for C test sources.
-ac_ext=c
-
-# Object file extension for compiled C test sources.
-objext=o
-objext=$objext
-
-# Code to be used in simple compile tests
-lt_simple_compile_test_code="int some_variable = 0;"
-
-# Code to be used in simple link tests
-lt_simple_link_test_code='int main(){return(0);}'
-
-
-
-
-
-
-
-# If no C compiler was specified, use CC.
-LTCC=${LTCC-"$CC"}
-
-# If no C compiler flags were specified, use CFLAGS.
-LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
-
-# Allow CC to be a program name with arguments.
-compiler=$CC
-
-# Save the default compiler, since it gets overwritten when the other
-# tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP.
-compiler_DEFAULT=$CC
-
-# save warnings/boilerplate of simple test code
-ac_outfile=conftest.$ac_objext
-echo "$lt_simple_compile_test_code" >conftest.$ac_ext
-eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
-_lt_compiler_boilerplate=`cat conftest.err`
-$RM conftest*
-
-ac_outfile=conftest.$ac_objext
-echo "$lt_simple_link_test_code" >conftest.$ac_ext
-eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
-_lt_linker_boilerplate=`cat conftest.err`
-$RM -r conftest*
-
-
-## CAVEAT EMPTOR:
-## There is no encapsulation within the following macros, do not change
-## the running order or otherwise move them around unless you know exactly
-## what you are doing...
-if test -n "$compiler"; then
-
-lt_prog_compiler_no_builtin_flag=
-
-if test "$GCC" = yes; then
- case $cc_basename in
- nvcc*)
- lt_prog_compiler_no_builtin_flag=' -Xcompiler -fno-builtin' ;;
- *)
- lt_prog_compiler_no_builtin_flag=' -fno-builtin' ;;
- esac
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -fno-rtti -fno-exceptions" >&5
-$as_echo_n "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; }
-if ${lt_cv_prog_compiler_rtti_exceptions+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_prog_compiler_rtti_exceptions=no
- ac_outfile=conftest.$ac_objext
- echo "$lt_simple_compile_test_code" > conftest.$ac_ext
- lt_compiler_flag="-fno-rtti -fno-exceptions"
- # Insert the option either (1) after the last *FLAGS variable, or
- # (2) before a word containing "conftest.", or (3) at the end.
- # Note that $ac_compile itself does not contain backslashes and begins
- # with a dollar sign (not a hyphen), so the echo should work correctly.
- # The option is referenced via a variable to avoid confusing sed.
- lt_compile=`echo "$ac_compile" | $SED \
- -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
- -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
- -e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
- (eval "$lt_compile" 2>conftest.err)
- ac_status=$?
- cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- if (exit $ac_status) && test -s "$ac_outfile"; then
- # The compiler can only warn and ignore the option if not recognized
- # So say no if there are warnings other than the usual output.
- $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
- $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
- if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
- lt_cv_prog_compiler_rtti_exceptions=yes
- fi
- fi
- $RM conftest*
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_rtti_exceptions" >&5
-$as_echo "$lt_cv_prog_compiler_rtti_exceptions" >&6; }
-
-if test x"$lt_cv_prog_compiler_rtti_exceptions" = xyes; then
- lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions"
-else
- :
-fi
-
-fi
-
-
-
-
-
-
- lt_prog_compiler_wl=
-lt_prog_compiler_pic=
-lt_prog_compiler_static=
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5
-$as_echo_n "checking for $compiler option to produce PIC... " >&6; }
-
- if test "$GCC" = yes; then
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_static='-static'
-
- case $host_os in
- aix*)
- # All AIX code is PIC.
- if test "$host_cpu" = ia64; then
- # AIX 5 now supports IA64 processor
- lt_prog_compiler_static='-Bstatic'
- fi
- lt_prog_compiler_pic='-fPIC'
- ;;
-
- amigaos*)
- case $host_cpu in
- powerpc)
- # see comment about AmigaOS4 .so support
- lt_prog_compiler_pic='-fPIC'
- ;;
- m68k)
- # FIXME: we need at least 68020 code to build shared libraries, but
- # adding the `-m68020' flag to GCC prevents building anything better,
- # like `-m68040'.
- lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4'
- ;;
- esac
- ;;
-
- beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
- # PIC is the default for these OSes.
- ;;
-
- mingw* | cygwin* | pw32* | os2* | cegcc*)
- # This hack is so that the source file can tell whether it is being
- # built for inclusion in a dll (and should export symbols for example).
- # Although the cygwin gcc ignores -fPIC, still need this for old-style
- # (--disable-auto-import) libraries
- lt_prog_compiler_pic='-DDLL_EXPORT'
- ;;
-
- darwin* | rhapsody*)
- # PIC is the default on this platform
- # Common symbols not allowed in MH_DYLIB files
- lt_prog_compiler_pic='-fno-common'
- ;;
-
- haiku*)
- # PIC is the default for Haiku.
- # The "-static" flag exists, but is broken.
- lt_prog_compiler_static=
- ;;
-
- hpux*)
- # PIC is the default for 64-bit PA HP-UX, but not for 32-bit
- # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag
- # sets the default TLS model and affects inlining.
- case $host_cpu in
- hppa*64*)
- # +Z the default
- ;;
- *)
- lt_prog_compiler_pic='-fPIC'
- ;;
- esac
- ;;
-
- interix[3-9]*)
- # Interix 3.x gcc -fpic/-fPIC options generate broken code.
- # Instead, we relocate shared libraries at runtime.
- ;;
-
- msdosdjgpp*)
- # Just because we use GCC doesn't mean we suddenly get shared libraries
- # on systems that don't support them.
- lt_prog_compiler_can_build_shared=no
- enable_shared=no
- ;;
-
- *nto* | *qnx*)
- # QNX uses GNU C++, but need to define -shared option too, otherwise
- # it will coredump.
- lt_prog_compiler_pic='-fPIC -shared'
- ;;
-
- sysv4*MP*)
- if test -d /usr/nec; then
- lt_prog_compiler_pic=-Kconform_pic
- fi
- ;;
-
- *)
- lt_prog_compiler_pic='-fPIC'
- ;;
- esac
-
- case $cc_basename in
- nvcc*) # Cuda Compiler Driver 2.2
- lt_prog_compiler_wl='-Xlinker '
- lt_prog_compiler_pic='-Xcompiler -fPIC'
- ;;
- esac
- else
- # PORTME Check for flag to pass linker flags through the system compiler.
- case $host_os in
- aix*)
- lt_prog_compiler_wl='-Wl,'
- if test "$host_cpu" = ia64; then
- # AIX 5 now supports IA64 processor
- lt_prog_compiler_static='-Bstatic'
- else
- lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp'
- fi
- ;;
-
- mingw* | cygwin* | pw32* | os2* | cegcc*)
- # This hack is so that the source file can tell whether it is being
- # built for inclusion in a dll (and should export symbols for example).
- lt_prog_compiler_pic='-DDLL_EXPORT'
- ;;
-
- hpux9* | hpux10* | hpux11*)
- lt_prog_compiler_wl='-Wl,'
- # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but
- # not for PA HP-UX.
- case $host_cpu in
- hppa*64*|ia64*)
- # +Z the default
- ;;
- *)
- lt_prog_compiler_pic='+Z'
- ;;
- esac
- # Is there a better lt_prog_compiler_static that works with the bundled CC?
- lt_prog_compiler_static='${wl}-a ${wl}archive'
- ;;
-
- irix5* | irix6* | nonstopux*)
- lt_prog_compiler_wl='-Wl,'
- # PIC (with -KPIC) is the default.
- lt_prog_compiler_static='-non_shared'
- ;;
-
- linux* | k*bsd*-gnu | kopensolaris*-gnu)
- case $cc_basename in
- # old Intel for x86_64 which still supported -KPIC.
- ecc*)
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_pic='-KPIC'
- lt_prog_compiler_static='-static'
- ;;
- # icc used to be incompatible with GCC.
- # ICC 10 doesn't accept -KPIC any more.
- icc* | ifort*)
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_pic='-fPIC'
- lt_prog_compiler_static='-static'
- ;;
- # Lahey Fortran 8.1.
- lf95*)
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_pic='--shared'
- lt_prog_compiler_static='--static'
- ;;
- pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*)
- # Portland Group compilers (*not* the Pentium gcc compiler,
- # which looks to be a dead project)
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_pic='-fpic'
- lt_prog_compiler_static='-Bstatic'
- ;;
- ccc*)
- lt_prog_compiler_wl='-Wl,'
- # All Alpha code is PIC.
- lt_prog_compiler_static='-non_shared'
- ;;
- xl* | bgxl* | bgf* | mpixl*)
- # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_pic='-qpic'
- lt_prog_compiler_static='-qstaticlink'
- ;;
- *)
- case `$CC -V 2>&1 | sed 5q` in
- *Sun\ F* | *Sun*Fortran*)
- # Sun Fortran 8.3 passes all unrecognized flags to the linker
- lt_prog_compiler_pic='-KPIC'
- lt_prog_compiler_static='-Bstatic'
- lt_prog_compiler_wl=''
- ;;
- *Sun\ C*)
- # Sun C 5.9
- lt_prog_compiler_pic='-KPIC'
- lt_prog_compiler_static='-Bstatic'
- lt_prog_compiler_wl='-Wl,'
- ;;
- esac
- ;;
- esac
- ;;
-
- newsos6)
- lt_prog_compiler_pic='-KPIC'
- lt_prog_compiler_static='-Bstatic'
- ;;
-
- *nto* | *qnx*)
- # QNX uses GNU C++, but need to define -shared option too, otherwise
- # it will coredump.
- lt_prog_compiler_pic='-fPIC -shared'
- ;;
-
- osf3* | osf4* | osf5*)
- lt_prog_compiler_wl='-Wl,'
- # All OSF/1 code is PIC.
- lt_prog_compiler_static='-non_shared'
- ;;
-
- rdos*)
- lt_prog_compiler_static='-non_shared'
- ;;
-
- solaris*)
- lt_prog_compiler_pic='-KPIC'
- lt_prog_compiler_static='-Bstatic'
- case $cc_basename in
- f77* | f90* | f95*)
- lt_prog_compiler_wl='-Qoption ld ';;
- *)
- lt_prog_compiler_wl='-Wl,';;
- esac
- ;;
-
- sunos4*)
- lt_prog_compiler_wl='-Qoption ld '
- lt_prog_compiler_pic='-PIC'
- lt_prog_compiler_static='-Bstatic'
- ;;
-
- sysv4 | sysv4.2uw2* | sysv4.3*)
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_pic='-KPIC'
- lt_prog_compiler_static='-Bstatic'
- ;;
-
- sysv4*MP*)
- if test -d /usr/nec ;then
- lt_prog_compiler_pic='-Kconform_pic'
- lt_prog_compiler_static='-Bstatic'
- fi
- ;;
-
- sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_pic='-KPIC'
- lt_prog_compiler_static='-Bstatic'
- ;;
-
- unicos*)
- lt_prog_compiler_wl='-Wl,'
- lt_prog_compiler_can_build_shared=no
- ;;
-
- uts4*)
- lt_prog_compiler_pic='-pic'
- lt_prog_compiler_static='-Bstatic'
- ;;
-
- *)
- lt_prog_compiler_can_build_shared=no
- ;;
- esac
- fi
-
-case $host_os in
- # For platforms which do not support PIC, -DPIC is meaningless:
- *djgpp*)
- lt_prog_compiler_pic=
- ;;
- *)
- lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC"
- ;;
-esac
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_prog_compiler_pic" >&5
-$as_echo "$lt_prog_compiler_pic" >&6; }
-
-
-
-
-
-
-#
-# Check to make sure the PIC flag actually works.
-#
-if test -n "$lt_prog_compiler_pic"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5
-$as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic works... " >&6; }
-if ${lt_cv_prog_compiler_pic_works+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_prog_compiler_pic_works=no
- ac_outfile=conftest.$ac_objext
- echo "$lt_simple_compile_test_code" > conftest.$ac_ext
- lt_compiler_flag="$lt_prog_compiler_pic -DPIC"
- # Insert the option either (1) after the last *FLAGS variable, or
- # (2) before a word containing "conftest.", or (3) at the end.
- # Note that $ac_compile itself does not contain backslashes and begins
- # with a dollar sign (not a hyphen), so the echo should work correctly.
- # The option is referenced via a variable to avoid confusing sed.
- lt_compile=`echo "$ac_compile" | $SED \
- -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
- -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
- -e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
- (eval "$lt_compile" 2>conftest.err)
- ac_status=$?
- cat conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- if (exit $ac_status) && test -s "$ac_outfile"; then
- # The compiler can only warn and ignore the option if not recognized
- # So say no if there are warnings other than the usual output.
- $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp
- $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
- if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
- lt_cv_prog_compiler_pic_works=yes
- fi
- fi
- $RM conftest*
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works" >&5
-$as_echo "$lt_cv_prog_compiler_pic_works" >&6; }
-
-if test x"$lt_cv_prog_compiler_pic_works" = xyes; then
- case $lt_prog_compiler_pic in
- "" | " "*) ;;
- *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;;
- esac
-else
- lt_prog_compiler_pic=
- lt_prog_compiler_can_build_shared=no
-fi
-
-fi
-
-
-
-
-
-
-#
-# Check to make sure the static flag actually works.
-#
-wl=$lt_prog_compiler_wl eval lt_tmp_static_flag=\"$lt_prog_compiler_static\"
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5
-$as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; }
-if ${lt_cv_prog_compiler_static_works+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_prog_compiler_static_works=no
- save_LDFLAGS="$LDFLAGS"
- LDFLAGS="$LDFLAGS $lt_tmp_static_flag"
- echo "$lt_simple_link_test_code" > conftest.$ac_ext
- if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
- # The linker can only warn and ignore the option if not recognized
- # So say no if there are warnings
- if test -s conftest.err; then
- # Append any errors to the config.log.
- cat conftest.err 1>&5
- $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
- $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
- if diff conftest.exp conftest.er2 >/dev/null; then
- lt_cv_prog_compiler_static_works=yes
- fi
- else
- lt_cv_prog_compiler_static_works=yes
- fi
- fi
- $RM -r conftest*
- LDFLAGS="$save_LDFLAGS"
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works" >&5
-$as_echo "$lt_cv_prog_compiler_static_works" >&6; }
-
-if test x"$lt_cv_prog_compiler_static_works" = xyes; then
- :
-else
- lt_prog_compiler_static=
-fi
-
-
-
-
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
-$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
-if ${lt_cv_prog_compiler_c_o+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_prog_compiler_c_o=no
- $RM -r conftest 2>/dev/null
- mkdir conftest
- cd conftest
- mkdir out
- echo "$lt_simple_compile_test_code" > conftest.$ac_ext
-
- lt_compiler_flag="-o out/conftest2.$ac_objext"
- # Insert the option either (1) after the last *FLAGS variable, or
- # (2) before a word containing "conftest.", or (3) at the end.
- # Note that $ac_compile itself does not contain backslashes and begins
- # with a dollar sign (not a hyphen), so the echo should work correctly.
- lt_compile=`echo "$ac_compile" | $SED \
- -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
- -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
- -e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
- (eval "$lt_compile" 2>out/conftest.err)
- ac_status=$?
- cat out/conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- if (exit $ac_status) && test -s out/conftest2.$ac_objext
- then
- # The compiler can only warn and ignore the option if not recognized
- # So say no if there are warnings
- $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
- $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
- if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
- lt_cv_prog_compiler_c_o=yes
- fi
- fi
- chmod u+w . 2>&5
- $RM conftest*
- # SGI C++ compiler will create directory out/ii_files/ for
- # template instantiation
- test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
- $RM out/* && rmdir out
- cd ..
- $RM -r conftest
- $RM conftest*
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5
-$as_echo "$lt_cv_prog_compiler_c_o" >&6; }
-
-
-
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5
-$as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; }
-if ${lt_cv_prog_compiler_c_o+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_prog_compiler_c_o=no
- $RM -r conftest 2>/dev/null
- mkdir conftest
- cd conftest
- mkdir out
- echo "$lt_simple_compile_test_code" > conftest.$ac_ext
-
- lt_compiler_flag="-o out/conftest2.$ac_objext"
- # Insert the option either (1) after the last *FLAGS variable, or
- # (2) before a word containing "conftest.", or (3) at the end.
- # Note that $ac_compile itself does not contain backslashes and begins
- # with a dollar sign (not a hyphen), so the echo should work correctly.
- lt_compile=`echo "$ac_compile" | $SED \
- -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
- -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
- -e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5)
- (eval "$lt_compile" 2>out/conftest.err)
- ac_status=$?
- cat out/conftest.err >&5
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- if (exit $ac_status) && test -s out/conftest2.$ac_objext
- then
- # The compiler can only warn and ignore the option if not recognized
- # So say no if there are warnings
- $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp
- $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
- if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
- lt_cv_prog_compiler_c_o=yes
- fi
- fi
- chmod u+w . 2>&5
- $RM conftest*
- # SGI C++ compiler will create directory out/ii_files/ for
- # template instantiation
- test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files
- $RM out/* && rmdir out
- cd ..
- $RM -r conftest
- $RM conftest*
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5
-$as_echo "$lt_cv_prog_compiler_c_o" >&6; }
-
-
-
-
-hard_links="nottested"
-if test "$lt_cv_prog_compiler_c_o" = no && test "$need_locks" != no; then
- # do not overwrite the value of need_locks provided by the user
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5
-$as_echo_n "checking if we can lock with hard links... " >&6; }
- hard_links=yes
- $RM conftest*
- ln conftest.a conftest.b 2>/dev/null && hard_links=no
- touch conftest.a
- ln conftest.a conftest.b 2>&5 || hard_links=no
- ln conftest.a conftest.b 2>/dev/null && hard_links=no
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5
-$as_echo "$hard_links" >&6; }
- if test "$hard_links" = no; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5
-$as_echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;}
- need_locks=warn
- fi
-else
- need_locks=no
-fi
-
-
-
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5
-$as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; }
-
- runpath_var=
- allow_undefined_flag=
- always_export_symbols=no
- archive_cmds=
- archive_expsym_cmds=
- compiler_needs_object=no
- enable_shared_with_static_runtimes=no
- export_dynamic_flag_spec=
- export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
- hardcode_automatic=no
- hardcode_direct=no
- hardcode_direct_absolute=no
- hardcode_libdir_flag_spec=
- hardcode_libdir_flag_spec_ld=
- hardcode_libdir_separator=
- hardcode_minus_L=no
- hardcode_shlibpath_var=unsupported
- inherit_rpath=no
- link_all_deplibs=unknown
- module_cmds=
- module_expsym_cmds=
- old_archive_from_new_cmds=
- old_archive_from_expsyms_cmds=
- thread_safe_flag_spec=
- whole_archive_flag_spec=
- # include_expsyms should be a list of space-separated symbols to be *always*
- # included in the symbol list
- include_expsyms=
- # exclude_expsyms can be an extended regexp of symbols to exclude
- # it will be wrapped by ` (' and `)$', so one must not match beginning or
- # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
- # as well as any symbol that contains `d'.
- exclude_expsyms='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'
- # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
- # platforms (ab)use it in PIC code, but their linkers get confused if
- # the symbol is explicitly referenced. Since portable code cannot
- # rely on this symbol name, it's probably fine to never include it in
- # preloaded symbol tables.
- # Exclude shared library initialization/finalization symbols.
- extract_expsyms_cmds=
-
- case $host_os in
- cygwin* | mingw* | pw32* | cegcc*)
- # FIXME: the MSVC++ port hasn't been tested in a loooong time
- # When not using gcc, we currently assume that we are using
- # Microsoft Visual C++.
- if test "$GCC" != yes; then
- with_gnu_ld=no
- fi
- ;;
- interix*)
- # we just hope/assume this is gcc and not c89 (= MSVC++)
- with_gnu_ld=yes
- ;;
- openbsd*)
- with_gnu_ld=no
- ;;
- esac
-
- ld_shlibs=yes
-
- # On some targets, GNU ld is compatible enough with the native linker
- # that we're better off using the native interface for both.
- lt_use_gnu_ld_interface=no
- if test "$with_gnu_ld" = yes; then
- case $host_os in
- aix*)
- # The AIX port of GNU ld has always aspired to compatibility
- # with the native linker. However, as the warning in the GNU ld
- # block says, versions before 2.19.5* couldn't really create working
- # shared libraries, regardless of the interface used.
- case `$LD -v 2>&1` in
- *\ \(GNU\ Binutils\)\ 2.19.5*) ;;
- *\ \(GNU\ Binutils\)\ 2.[2-9]*) ;;
- *\ \(GNU\ Binutils\)\ [3-9]*) ;;
- *)
- lt_use_gnu_ld_interface=yes
- ;;
- esac
- ;;
- *)
- lt_use_gnu_ld_interface=yes
- ;;
- esac
- fi
-
- if test "$lt_use_gnu_ld_interface" = yes; then
- # If archive_cmds runs LD, not CC, wlarc should be empty
- wlarc='${wl}'
-
- # Set some defaults for GNU ld with shared library support. These
- # are reset later if shared libraries are not supported. Putting them
- # here allows them to be overridden if necessary.
- runpath_var=LD_RUN_PATH
- hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
- export_dynamic_flag_spec='${wl}--export-dynamic'
- # ancient GNU ld didn't support --whole-archive et. al.
- if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then
- whole_archive_flag_spec="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
- else
- whole_archive_flag_spec=
- fi
- supports_anon_versioning=no
- case `$LD -v 2>&1` in
- *GNU\ gold*) supports_anon_versioning=yes ;;
- *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11
- *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ...
- *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ...
- *\ 2.11.*) ;; # other 2.11 versions
- *) supports_anon_versioning=yes ;;
- esac
-
- # See if GNU ld supports shared libraries.
- case $host_os in
- aix[3-9]*)
- # On AIX/PPC, the GNU linker is very broken
- if test "$host_cpu" != ia64; then
- ld_shlibs=no
- cat <<_LT_EOF 1>&2
-
-*** Warning: the GNU linker, at least up to release 2.19, is reported
-*** to be unable to reliably create shared libraries on AIX.
-*** Therefore, libtool is disabling shared libraries support. If you
-*** really care for shared libraries, you may want to install binutils
-*** 2.20 or above, or modify your PATH so that a non-GNU linker is found.
-*** You will then need to restart the configuration process.
-
-_LT_EOF
- fi
- ;;
-
- amigaos*)
- case $host_cpu in
- powerpc)
- # see comment about AmigaOS4 .so support
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- archive_expsym_cmds=''
- ;;
- m68k)
- archive_cmds='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
- hardcode_libdir_flag_spec='-L$libdir'
- hardcode_minus_L=yes
- ;;
- esac
- ;;
-
- beos*)
- if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
- allow_undefined_flag=unsupported
- # Joseph Beckenbach <jrb3@best.com> says some releases of gcc
- # support --undefined. This deserves some investigation. FIXME
- archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- else
- ld_shlibs=no
- fi
- ;;
-
- cygwin* | mingw* | pw32* | cegcc*)
- # _LT_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless,
- # as there is no search path for DLLs.
- hardcode_libdir_flag_spec='-L$libdir'
- export_dynamic_flag_spec='${wl}--export-all-symbols'
- allow_undefined_flag=unsupported
- always_export_symbols=no
- enable_shared_with_static_runtimes=yes
- export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
-
- if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
- # If the export-symbols file already is a .def file (1st line
- # is EXPORTS), use it as is; otherwise, prepend...
- archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
- cp $export_symbols $output_objdir/$soname.def;
- else
- echo EXPORTS > $output_objdir/$soname.def;
- cat $export_symbols >> $output_objdir/$soname.def;
- fi~
- $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
- else
- ld_shlibs=no
- fi
- ;;
-
- haiku*)
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- link_all_deplibs=yes
- ;;
-
- interix[3-9]*)
- hardcode_direct=no
- hardcode_shlibpath_var=no
- hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
- export_dynamic_flag_spec='${wl}-E'
- # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
- # Instead, shared libraries are loaded at an image base (0x10000000 by
- # default) and relocated if they conflict, which is a slow very memory
- # consuming and fragmenting process. To avoid this, we pick a random,
- # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
- # time. Moving up from 0x10000000 also allows more sbrk(2) space.
- archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
- archive_expsym_cmds='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
- ;;
-
- gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu | uclinuxfdpiceabi)
- tmp_diet=no
- if test "$host_os" = linux-dietlibc; then
- case $cc_basename in
- diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn)
- esac
- fi
- if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \
- && test "$tmp_diet" = no
- then
- tmp_addflag=' $pic_flag'
- tmp_sharedflag='-shared'
- case $cc_basename,$host_cpu in
- pgcc*) # Portland Group C compiler
- whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
- tmp_addflag=' $pic_flag'
- ;;
- pgf77* | pgf90* | pgf95* | pgfortran*)
- # Portland Group f77 and f90 compilers
- whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
- tmp_addflag=' $pic_flag -Mnomain' ;;
- ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64
- tmp_addflag=' -i_dynamic' ;;
- efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64
- tmp_addflag=' -i_dynamic -nofor_main' ;;
- ifc* | ifort*) # Intel Fortran compiler
- tmp_addflag=' -nofor_main' ;;
- lf95*) # Lahey Fortran 8.1
- whole_archive_flag_spec=
- tmp_sharedflag='--shared' ;;
- xl[cC]* | bgxl[cC]* | mpixl[cC]*) # IBM XL C 8.0 on PPC (deal with xlf below)
- tmp_sharedflag='-qmkshrobj'
- tmp_addflag= ;;
- nvcc*) # Cuda Compiler Driver 2.2
- whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
- compiler_needs_object=yes
- ;;
- esac
- case `$CC -V 2>&1 | sed 5q` in
- *Sun\ C*) # Sun C 5.9
- whole_archive_flag_spec='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive'
- compiler_needs_object=yes
- tmp_sharedflag='-G' ;;
- *Sun\ F*) # Sun Fortran 8.3
- tmp_sharedflag='-G' ;;
- esac
- archive_cmds='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
-
- if test "x$supports_anon_versioning" = xyes; then
- archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
- cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
- echo "local: *; };" >> $output_objdir/$libname.ver~
- $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
- fi
-
- case $cc_basename in
- xlf* | bgf* | bgxlf* | mpixlf*)
- # IBM XL Fortran 10.1 on PPC cannot create shared libs itself
- whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive'
- hardcode_libdir_flag_spec=
- hardcode_libdir_flag_spec_ld='-rpath $libdir'
- archive_cmds='$LD -shared $libobjs $deplibs $compiler_flags -soname $soname -o $lib'
- if test "x$supports_anon_versioning" = xyes; then
- archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~
- cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
- echo "local: *; };" >> $output_objdir/$libname.ver~
- $LD -shared $libobjs $deplibs $compiler_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib'
- fi
- ;;
- esac
- else
- ld_shlibs=no
- fi
- ;;
-
- netbsd*)
- if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
- archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib'
- wlarc=
- else
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
- fi
- ;;
-
- solaris*)
- if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then
- ld_shlibs=no
- cat <<_LT_EOF 1>&2
-
-*** Warning: The releases 2.8.* of the GNU linker cannot reliably
-*** create shared libraries on Solaris systems. Therefore, libtool
-*** is disabling shared libraries support. We urge you to upgrade GNU
-*** binutils to release 2.9.1 or newer. Another option is to modify
-*** your PATH or compiler configuration so that the native linker is
-*** used, and then restart.
-
-_LT_EOF
- elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
- else
- ld_shlibs=no
- fi
- ;;
-
- sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
- case `$LD -v 2>&1` in
- *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*)
- ld_shlibs=no
- cat <<_LT_EOF 1>&2
-
-*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not
-*** reliably create shared libraries on SCO systems. Therefore, libtool
-*** is disabling shared libraries support. We urge you to upgrade GNU
-*** binutils to release 2.16.91.0.3 or newer. Another option is to modify
-*** your PATH or compiler configuration so that the native linker is
-*** used, and then restart.
-
-_LT_EOF
- ;;
- *)
- # For security reasons, it is highly recommended that you always
- # use absolute paths for naming shared libraries, and exclude the
- # DT_RUNPATH tag from executables and libraries. But doing so
- # requires that you compile everything twice, which is a pain.
- if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
- hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
- else
- ld_shlibs=no
- fi
- ;;
- esac
- ;;
-
- sunos4*)
- archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
- wlarc=
- hardcode_direct=yes
- hardcode_shlibpath_var=no
- ;;
-
- *)
- if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
- else
- ld_shlibs=no
- fi
- ;;
- esac
-
- if test "$ld_shlibs" = no; then
- runpath_var=
- hardcode_libdir_flag_spec=
- export_dynamic_flag_spec=
- whole_archive_flag_spec=
- fi
- else
- # PORTME fill in a description of your system's linker (not GNU ld)
- case $host_os in
- aix3*)
- allow_undefined_flag=unsupported
- always_export_symbols=yes
- archive_expsym_cmds='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname'
- # Note: this linker hardcodes the directories in LIBPATH if there
- # are no directories specified by -L.
- hardcode_minus_L=yes
- if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then
- # Neither direct hardcoding nor static linking is supported with a
- # broken collect2.
- hardcode_direct=unsupported
- fi
- ;;
-
- aix[4-9]*)
- if test "$host_cpu" = ia64; then
- # On IA64, the linker does run time linking by default, so we don't
- # have to do anything special.
- aix_use_runtimelinking=no
- exp_sym_flag='-Bexport'
- no_entry_flag=""
- else
- # If we're using GNU nm, then we don't want the "-C" option.
- # -C means demangle to AIX nm, but means don't demangle with GNU nm
- # Also, AIX nm treats weak defined symbols like other global
- # defined symbols, whereas GNU nm marks them as "W".
- if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then
- export_symbols_cmds='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
- else
- export_symbols_cmds='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "L")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols'
- fi
- aix_use_runtimelinking=no
-
- # Test if we are trying to use run time linking or normal
- # AIX style linking. If -brtl is somewhere in LDFLAGS, we
- # need to do runtime linking.
- case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*)
- for ld_flag in $LDFLAGS; do
- if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
- aix_use_runtimelinking=yes
- break
- fi
- done
- ;;
- esac
-
- exp_sym_flag='-bexport'
- no_entry_flag='-bnoentry'
- fi
-
- # When large executables or shared objects are built, AIX ld can
- # have problems creating the table of contents. If linking a library
- # or program results in "error TOC overflow" add -mminimal-toc to
- # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not
- # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS.
-
- archive_cmds=''
- hardcode_direct=yes
- hardcode_direct_absolute=yes
- hardcode_libdir_separator=':'
- link_all_deplibs=yes
- file_list_spec='${wl}-f,'
-
- if test "$GCC" = yes; then
- case $host_os in aix4.[012]|aix4.[012].*)
- # We only want to do this on AIX 4.2 and lower, the check
- # below for broken collect2 doesn't work under 4.3+
- collect2name=`${CC} -print-prog-name=collect2`
- if test -f "$collect2name" &&
- strings "$collect2name" | $GREP resolve_lib_name >/dev/null
- then
- # We have reworked collect2
- :
- else
- # We have old collect2
- hardcode_direct=unsupported
- # It fails to find uninstalled libraries when the uninstalled
- # path is not listed in the libpath. Setting hardcode_minus_L
- # to unsupported forces relinking
- hardcode_minus_L=yes
- hardcode_libdir_flag_spec='-L$libdir'
- hardcode_libdir_separator=
- fi
- ;;
- esac
- shared_flag='-shared'
- if test "$aix_use_runtimelinking" = yes; then
- shared_flag="$shared_flag "'${wl}-G'
- fi
- else
- # not using gcc
- if test "$host_cpu" = ia64; then
- # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release
- # chokes on -Wl,-G. The following line is correct:
- shared_flag='-G'
- else
- if test "$aix_use_runtimelinking" = yes; then
- shared_flag='${wl}-G'
- else
- shared_flag='${wl}-bM:SRE'
- fi
- fi
- fi
-
- export_dynamic_flag_spec='${wl}-bexpall'
- # It seems that -bexpall does not export symbols beginning with
- # underscore (_), so it is better to generate a list of symbols to export.
- always_export_symbols=yes
- if test "$aix_use_runtimelinking" = yes; then
- # Warning - without using the other runtime loading flags (-brtl),
- # -berok will link without error, but may produce a broken library.
- allow_undefined_flag='-berok'
- # Determine the default libpath from the value encoded in an
- # empty executable.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
-
-lt_aix_libpath_sed='
- /Import File Strings/,/^$/ {
- /^0/ {
- s/^0 *\(.*\)$/\1/
- p
- }
- }'
-aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
-# Check for a 64-bit object if we didn't find anything.
-if test -z "$aix_libpath"; then
- aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
-fi
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
-
- hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
- archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
- else
- if test "$host_cpu" = ia64; then
- hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib'
- allow_undefined_flag="-z nodefs"
- archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols"
- else
- # Determine the default libpath from the value encoded in an
- # empty executable.
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
-
-lt_aix_libpath_sed='
- /Import File Strings/,/^$/ {
- /^0/ {
- s/^0 *\(.*\)$/\1/
- p
- }
- }'
-aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
-# Check for a 64-bit object if we didn't find anything.
-if test -z "$aix_libpath"; then
- aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
-fi
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
-
- hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
- # Warning - without using the other run time loading flags,
- # -berok will link without error, but may produce a broken library.
- no_undefined_flag=' ${wl}-bernotok'
- allow_undefined_flag=' ${wl}-berok'
- if test "$with_gnu_ld" = yes; then
- # We only use this code for GNU lds that support --whole-archive.
- whole_archive_flag_spec='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
- else
- # Exported symbols can be pulled into shared objects from archives
- whole_archive_flag_spec='$convenience'
- fi
- archive_cmds_need_lc=yes
- # This is similar to how AIX traditionally builds its shared libraries.
- archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
- fi
- fi
- ;;
-
- amigaos*)
- case $host_cpu in
- powerpc)
- # see comment about AmigaOS4 .so support
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
- archive_expsym_cmds=''
- ;;
- m68k)
- archive_cmds='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)'
- hardcode_libdir_flag_spec='-L$libdir'
- hardcode_minus_L=yes
- ;;
- esac
- ;;
-
- bsdi[45]*)
- export_dynamic_flag_spec=-rdynamic
- ;;
-
- cygwin* | mingw* | pw32* | cegcc*)
- # When not using gcc, we currently assume that we are using
- # Microsoft Visual C++.
- # hardcode_libdir_flag_spec is actually meaningless, as there is
- # no search path for DLLs.
- hardcode_libdir_flag_spec=' '
- allow_undefined_flag=unsupported
- # Tell ltmain to make .lib files, not .a files.
- libext=lib
- # Tell ltmain to make .dll files, not .so files.
- shrext_cmds=".dll"
- # FIXME: Setting linknames here is a bad hack.
- archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames='
- # The linker will automatically build a .lib file if we build a DLL.
- old_archive_from_new_cmds='true'
- # FIXME: Should let the user specify the lib program.
- old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs'
- fix_srcfile_path='`cygpath -w "$srcfile"`'
- enable_shared_with_static_runtimes=yes
- ;;
-
- darwin* | rhapsody*)
-
-
- archive_cmds_need_lc=no
- hardcode_direct=no
- hardcode_automatic=yes
- hardcode_shlibpath_var=unsupported
- if test "$lt_cv_ld_force_load" = "yes"; then
- whole_archive_flag_spec='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience ${wl}-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`'
- else
- whole_archive_flag_spec=''
- fi
- link_all_deplibs=yes
- allow_undefined_flag="$_lt_dar_allow_undefined"
- case $cc_basename in
- ifort*) _lt_dar_can_shared=yes ;;
- *) _lt_dar_can_shared=$GCC ;;
- esac
- if test "$_lt_dar_can_shared" = "yes"; then
- output_verbose_link_cmd=func_echo_all
- archive_cmds="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}"
- module_cmds="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
- archive_expsym_cmds="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}"
- module_expsym_cmds="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}"
-
- else
- ld_shlibs=no
- fi
-
- ;;
-
- dgux*)
- archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
- hardcode_libdir_flag_spec='-L$libdir'
- hardcode_shlibpath_var=no
- ;;
-
- # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor
- # support. Future versions do this automatically, but an explicit c++rt0.o
- # does not break anything, and helps significantly (at the cost of a little
- # extra space).
- freebsd2.2*)
- archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o'
- hardcode_libdir_flag_spec='-R$libdir'
- hardcode_direct=yes
- hardcode_shlibpath_var=no
- ;;
-
- # Unfortunately, older versions of FreeBSD 2 do not have this feature.
- freebsd2.*)
- archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
- hardcode_direct=yes
- hardcode_minus_L=yes
- hardcode_shlibpath_var=no
- ;;
-
- # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
- freebsd* | dragonfly*)
- archive_cmds='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
- hardcode_libdir_flag_spec='-R$libdir'
- hardcode_direct=yes
- hardcode_shlibpath_var=no
- ;;
-
- hpux9*)
- if test "$GCC" = yes; then
- archive_cmds='$RM $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
- else
- archive_cmds='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib'
- fi
- hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
- hardcode_libdir_separator=:
- hardcode_direct=yes
-
- # hardcode_minus_L: Not really in the search PATH,
- # but as the default location of the library.
- hardcode_minus_L=yes
- export_dynamic_flag_spec='${wl}-E'
- ;;
-
- hpux10*)
- if test "$GCC" = yes && test "$with_gnu_ld" = no; then
- archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
- else
- archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
- fi
- if test "$with_gnu_ld" = no; then
- hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
- hardcode_libdir_flag_spec_ld='+b $libdir'
- hardcode_libdir_separator=:
- hardcode_direct=yes
- hardcode_direct_absolute=yes
- export_dynamic_flag_spec='${wl}-E'
- # hardcode_minus_L: Not really in the search PATH,
- # but as the default location of the library.
- hardcode_minus_L=yes
- fi
- ;;
-
- hpux11*)
- if test "$GCC" = yes && test "$with_gnu_ld" = no; then
- case $host_cpu in
- hppa*64*)
- archive_cmds='$CC -shared ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
- ;;
- ia64*)
- archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
- ;;
- *)
- archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
- ;;
- esac
- else
- case $host_cpu in
- hppa*64*)
- archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
- ;;
- ia64*)
- archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
- ;;
- *)
-
- # Older versions of the 11.00 compiler do not understand -b yet
- # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does)
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC understands -b" >&5
-$as_echo_n "checking if $CC understands -b... " >&6; }
-if ${lt_cv_prog_compiler__b+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_prog_compiler__b=no
- save_LDFLAGS="$LDFLAGS"
- LDFLAGS="$LDFLAGS -b"
- echo "$lt_simple_link_test_code" > conftest.$ac_ext
- if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
- # The linker can only warn and ignore the option if not recognized
- # So say no if there are warnings
- if test -s conftest.err; then
- # Append any errors to the config.log.
- cat conftest.err 1>&5
- $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp
- $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
- if diff conftest.exp conftest.er2 >/dev/null; then
- lt_cv_prog_compiler__b=yes
- fi
- else
- lt_cv_prog_compiler__b=yes
- fi
- fi
- $RM -r conftest*
- LDFLAGS="$save_LDFLAGS"
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler__b" >&5
-$as_echo "$lt_cv_prog_compiler__b" >&6; }
-
-if test x"$lt_cv_prog_compiler__b" = xyes; then
- archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
-else
- archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
-fi
-
- ;;
- esac
- fi
- if test "$with_gnu_ld" = no; then
- hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
- hardcode_libdir_separator=:
-
- case $host_cpu in
- hppa*64*|ia64*)
- hardcode_direct=no
- hardcode_shlibpath_var=no
- ;;
- *)
- hardcode_direct=yes
- hardcode_direct_absolute=yes
- export_dynamic_flag_spec='${wl}-E'
-
- # hardcode_minus_L: Not really in the search PATH,
- # but as the default location of the library.
- hardcode_minus_L=yes
- ;;
- esac
- fi
- ;;
-
- irix5* | irix6* | nonstopux*)
- if test "$GCC" = yes; then
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
- # Try to use the -exported_symbol ld option, if it does not
- # work, assume that -exports_file does not work either and
- # implicitly export all symbols.
- save_LDFLAGS="$LDFLAGS"
- LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-int foo(void) {}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib'
-
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LDFLAGS="$save_LDFLAGS"
- else
- archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
- archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib'
- fi
- archive_cmds_need_lc='no'
- hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
- hardcode_libdir_separator=:
- inherit_rpath=yes
- link_all_deplibs=yes
- ;;
-
- netbsd*)
- if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
- archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out
- else
- archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF
- fi
- hardcode_libdir_flag_spec='-R$libdir'
- hardcode_direct=yes
- hardcode_shlibpath_var=no
- ;;
-
- newsos6)
- archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
- hardcode_direct=yes
- hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
- hardcode_libdir_separator=:
- hardcode_shlibpath_var=no
- ;;
-
- *nto* | *qnx*)
- ;;
-
- openbsd*)
- if test -f /usr/libexec/ld.so; then
- hardcode_direct=yes
- hardcode_shlibpath_var=no
- hardcode_direct_absolute=yes
- if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
- archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
- archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
- hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
- export_dynamic_flag_spec='${wl}-E'
- else
- case $host_os in
- openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*)
- archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
- hardcode_libdir_flag_spec='-R$libdir'
- ;;
- *)
- archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
- hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
- ;;
- esac
- fi
- else
- ld_shlibs=no
- fi
- ;;
-
- os2*)
- hardcode_libdir_flag_spec='-L$libdir'
- hardcode_minus_L=yes
- allow_undefined_flag=unsupported
- archive_cmds='$ECHO "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~echo DATA >> $output_objdir/$libname.def~echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def'
- old_archive_from_new_cmds='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def'
- ;;
-
- osf3*)
- if test "$GCC" = yes; then
- allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
- archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
- else
- allow_undefined_flag=' -expect_unresolved \*'
- archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
- fi
- archive_cmds_need_lc='no'
- hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
- hardcode_libdir_separator=:
- ;;
-
- osf4* | osf5*) # as osf3* with the addition of -msym flag
- if test "$GCC" = yes; then
- allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*'
- archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib'
- hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
- else
- allow_undefined_flag=' -expect_unresolved \*'
- archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib'
- archive_expsym_cmds='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~
- $CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp'
-
- # Both c and cxx compiler support -rpath directly
- hardcode_libdir_flag_spec='-rpath $libdir'
- fi
- archive_cmds_need_lc='no'
- hardcode_libdir_separator=:
- ;;
-
- solaris*)
- no_undefined_flag=' -z defs'
- if test "$GCC" = yes; then
- wlarc='${wl}'
- archive_cmds='$CC -shared ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
- archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
- $CC -shared ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
- else
- case `$CC -V 2>&1` in
- *"Compilers 5.0"*)
- wlarc=''
- archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
- archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
- $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp'
- ;;
- *)
- wlarc='${wl}'
- archive_cmds='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags'
- archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~
- $CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp'
- ;;
- esac
- fi
- hardcode_libdir_flag_spec='-R$libdir'
- hardcode_shlibpath_var=no
- case $host_os in
- solaris2.[0-5] | solaris2.[0-5].*) ;;
- *)
- # The compiler driver will combine and reorder linker options,
- # but understands `-z linker_flag'. GCC discards it without `$wl',
- # but is careful enough not to reorder.
- # Supported since Solaris 2.6 (maybe 2.5.1?)
- if test "$GCC" = yes; then
- whole_archive_flag_spec='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
- else
- whole_archive_flag_spec='-z allextract$convenience -z defaultextract'
- fi
- ;;
- esac
- link_all_deplibs=yes
- ;;
-
- sunos4*)
- if test "x$host_vendor" = xsequent; then
- # Use $CC to link under sequent, because it throws in some extra .o
- # files that make .init and .fini sections work.
- archive_cmds='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags'
- else
- archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags'
- fi
- hardcode_libdir_flag_spec='-L$libdir'
- hardcode_direct=yes
- hardcode_minus_L=yes
- hardcode_shlibpath_var=no
- ;;
-
- sysv4)
- case $host_vendor in
- sni)
- archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
- hardcode_direct=yes # is this really true???
- ;;
- siemens)
- ## LD is ld it makes a PLAMLIB
- ## CC just makes a GrossModule.
- archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags'
- reload_cmds='$CC -r -o $output$reload_objs'
- hardcode_direct=no
- ;;
- motorola)
- archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
- hardcode_direct=no #Motorola manual says yes, but my tests say they lie
- ;;
- esac
- runpath_var='LD_RUN_PATH'
- hardcode_shlibpath_var=no
- ;;
-
- sysv4.3*)
- archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
- hardcode_shlibpath_var=no
- export_dynamic_flag_spec='-Bexport'
- ;;
-
- sysv4*MP*)
- if test -d /usr/nec; then
- archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
- hardcode_shlibpath_var=no
- runpath_var=LD_RUN_PATH
- hardcode_runpath_var=yes
- ld_shlibs=yes
- fi
- ;;
-
- sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*)
- no_undefined_flag='${wl}-z,text'
- archive_cmds_need_lc=no
- hardcode_shlibpath_var=no
- runpath_var='LD_RUN_PATH'
-
- if test "$GCC" = yes; then
- archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- else
- archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- fi
- ;;
-
- sysv5* | sco3.2v5* | sco5v6*)
- # Note: We can NOT use -z defs as we might desire, because we do not
- # link with -lc, and that would cause any symbols used from libc to
- # always be unresolved, which means just about no library would
- # ever link correctly. If we're not using GNU ld we use -z text
- # though, which does catch some bad symbols but isn't as heavy-handed
- # as -z defs.
- no_undefined_flag='${wl}-z,text'
- allow_undefined_flag='${wl}-z,nodefs'
- archive_cmds_need_lc=no
- hardcode_shlibpath_var=no
- hardcode_libdir_flag_spec='${wl}-R,$libdir'
- hardcode_libdir_separator=':'
- link_all_deplibs=yes
- export_dynamic_flag_spec='${wl}-Bexport'
- runpath_var='LD_RUN_PATH'
-
- if test "$GCC" = yes; then
- archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- else
- archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
- fi
- ;;
-
- uts4*)
- archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
- hardcode_libdir_flag_spec='-L$libdir'
- hardcode_shlibpath_var=no
- ;;
-
- *)
- ld_shlibs=no
- ;;
- esac
-
- if test x$host_vendor = xsni; then
- case $host in
- sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
- export_dynamic_flag_spec='${wl}-Blargedynsym'
- ;;
- esac
- fi
- fi
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs" >&5
-$as_echo "$ld_shlibs" >&6; }
-test "$ld_shlibs" = no && can_build_shared=no
-
-with_gnu_ld=$with_gnu_ld
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-#
-# Do we need to explicitly link libc?
-#
-case "x$archive_cmds_need_lc" in
-x|xyes)
- # Assume -lc should be added
- archive_cmds_need_lc=yes
-
- if test "$enable_shared" = yes && test "$GCC" = yes; then
- case $archive_cmds in
- *'~'*)
- # FIXME: we may have to deal with multi-command sequences.
- ;;
- '$CC '*)
- # Test whether the compiler implicitly links with -lc since on some
- # systems, -lgcc has to come before -lc. If gcc already passes -lc
- # to ld, don't add -lc before -lgcc.
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5
-$as_echo_n "checking whether -lc should be explicitly linked in... " >&6; }
-if ${lt_cv_archive_cmds_need_lc+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- $RM conftest*
- echo "$lt_simple_compile_test_code" > conftest.$ac_ext
-
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5
- (eval $ac_compile) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } 2>conftest.err; then
- soname=conftest
- lib=conftest
- libobjs=conftest.$ac_objext
- deplibs=
- wl=$lt_prog_compiler_wl
- pic_flag=$lt_prog_compiler_pic
- compiler_flags=-v
- linker_flags=-v
- verstring=
- output_objdir=.
- libname=conftest
- lt_save_allow_undefined_flag=$allow_undefined_flag
- allow_undefined_flag=
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5
- (eval $archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; }
- then
- lt_cv_archive_cmds_need_lc=no
- else
- lt_cv_archive_cmds_need_lc=yes
- fi
- allow_undefined_flag=$lt_save_allow_undefined_flag
- else
- cat conftest.err 1>&5
- fi
- $RM conftest*
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc" >&5
-$as_echo "$lt_cv_archive_cmds_need_lc" >&6; }
- archive_cmds_need_lc=$lt_cv_archive_cmds_need_lc
- ;;
- esac
- fi
- ;;
-esac
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5
-$as_echo_n "checking dynamic linker characteristics... " >&6; }
-
-if test "$GCC" = yes; then
- case $host_os in
- darwin*) lt_awk_arg="/^libraries:/,/LR/" ;;
- *) lt_awk_arg="/^libraries:/" ;;
- esac
- case $host_os in
- mingw* | cegcc*) lt_sed_strip_eq="s,=\([A-Za-z]:\),\1,g" ;;
- *) lt_sed_strip_eq="s,=/,/,g" ;;
- esac
- lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq`
- case $lt_search_path_spec in
- *\;*)
- # if the path contains ";" then we assume it to be the separator
- # otherwise default to the standard path separator (i.e. ":") - it is
- # assumed that no part of a normal pathname contains ";" but that should
- # okay in the real world where ";" in dirpaths is itself problematic.
- lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'`
- ;;
- *)
- lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"`
- ;;
- esac
- # Ok, now we have the path, separated by spaces, we can step through it
- # and add multilib dir if necessary.
- lt_tmp_lt_search_path_spec=
- lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
- for lt_sys_path in $lt_search_path_spec; do
- if test -d "$lt_sys_path/$lt_multi_os_dir"; then
- lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir"
- else
- test -d "$lt_sys_path" && \
- lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
- fi
- done
- lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk '
-BEGIN {RS=" "; FS="/|\n";} {
- lt_foo="";
- lt_count=0;
- for (lt_i = NF; lt_i > 0; lt_i--) {
- if ($lt_i != "" && $lt_i != ".") {
- if ($lt_i == "..") {
- lt_count++;
- } else {
- if (lt_count == 0) {
- lt_foo="/" $lt_i lt_foo;
- } else {
- lt_count--;
- }
- }
- }
- }
- if (lt_foo != "") { lt_freq[lt_foo]++; }
- if (lt_freq[lt_foo] == 1) { print lt_foo; }
-}'`
- # AWK program above erroneously prepends '/' to C:/dos/paths
- # for these hosts.
- case $host_os in
- mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\
- $SED 's,/\([A-Za-z]:\),\1,g'` ;;
- esac
- sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP`
-else
- sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
-fi
-library_names_spec=
-libname_spec='lib$name'
-soname_spec=
-shrext_cmds=".so"
-postinstall_cmds=
-postuninstall_cmds=
-finish_cmds=
-finish_eval=
-shlibpath_var=
-shlibpath_overrides_runpath=unknown
-version_type=none
-dynamic_linker="$host_os ld.so"
-sys_lib_dlsearch_path_spec="/lib /usr/lib"
-need_lib_prefix=unknown
-hardcode_into_libs=no
-
-# when you set need_version to no, make sure it does not cause -set_version
-# flags to be left without arguments
-need_version=unknown
-
-case $host_os in
-aix3*)
- version_type=linux
- library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a'
- shlibpath_var=LIBPATH
-
- # AIX 3 has no versioning support, so we append a major version to the name.
- soname_spec='${libname}${release}${shared_ext}$major'
- ;;
-
-aix[4-9]*)
- version_type=linux
- need_lib_prefix=no
- need_version=no
- hardcode_into_libs=yes
- if test "$host_cpu" = ia64; then
- # AIX 5 supports IA64
- library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}'
- shlibpath_var=LD_LIBRARY_PATH
- else
- # With GCC up to 2.95.x, collect2 would create an import file
- # for dependence libraries. The import file would start with
- # the line `#! .'. This would cause the generated library to
- # depend on `.', always an invalid library. This was fixed in
- # development snapshots of GCC prior to 3.0.
- case $host_os in
- aix4 | aix4.[01] | aix4.[01].*)
- if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)'
- echo ' yes '
- echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then
- :
- else
- can_build_shared=no
- fi
- ;;
- esac
- # AIX (on Power*) has no versioning support, so currently we can not hardcode correct
- # soname into executable. Probably we can add versioning support to
- # collect2, so additional links can be useful in future.
- if test "$aix_use_runtimelinking" = yes; then
- # If using run time linking (on AIX 4.2 or later) use lib<name>.so
- # instead of lib<name>.a to let people know that these are not
- # typical AIX shared libraries.
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- else
- # We preserve .a as extension for shared libraries through AIX4.2
- # and later when we are not doing run time linking.
- library_names_spec='${libname}${release}.a $libname.a'
- soname_spec='${libname}${release}${shared_ext}$major'
- fi
- shlibpath_var=LIBPATH
- fi
- ;;
-
-amigaos*)
- case $host_cpu in
- powerpc)
- # Since July 2007 AmigaOS4 officially supports .so libraries.
- # When compiling the executable, add -use-dynld -Lsobjs: to the compileline.
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- ;;
- m68k)
- library_names_spec='$libname.ixlibrary $libname.a'
- # Create ${libname}_ixlibrary.a entries in /sys/libs.
- finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done'
- ;;
- esac
- ;;
-
-beos*)
- library_names_spec='${libname}${shared_ext}'
- dynamic_linker="$host_os ld.so"
- shlibpath_var=LIBRARY_PATH
- ;;
-
-bsdi[45]*)
- version_type=linux
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir'
- shlibpath_var=LD_LIBRARY_PATH
- sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib"
- sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib"
- # the default ld.so.conf also contains /usr/contrib/lib and
- # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow
- # libtool to hard-code these into programs
- ;;
-
-cygwin* | mingw* | pw32* | cegcc*)
- version_type=windows
- shrext_cmds=".dll"
- need_version=no
- need_lib_prefix=no
-
- case $GCC,$host_os in
- yes,cygwin* | yes,mingw* | yes,pw32* | yes,cegcc*)
- library_names_spec='$libname.dll.a'
- # DLL is installed to $(libdir)/../bin by postinstall_cmds
- postinstall_cmds='base_file=`basename \${file}`~
- dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~
- dldir=$destdir/`dirname \$dlpath`~
- test -d \$dldir || mkdir -p \$dldir~
- $install_prog $dir/$dlname \$dldir/$dlname~
- chmod a+x \$dldir/$dlname~
- if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then
- eval '\''$striplib \$dldir/$dlname'\'' || exit \$?;
- fi'
- postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~
- dlpath=$dir/\$dldll~
- $RM \$dlpath'
- shlibpath_overrides_runpath=yes
-
- case $host_os in
- cygwin*)
- # Cygwin DLLs use 'cyg' prefix rather than 'lib'
- soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
-
- sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api"
- ;;
- mingw* | cegcc*)
- # MinGW DLLs use traditional 'lib' prefix
- soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
- ;;
- pw32*)
- # pw32 DLLs use 'pw' prefix rather than 'lib'
- library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}'
- ;;
- esac
- ;;
-
- *)
- library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib'
- ;;
- esac
- dynamic_linker='Win32 ld.exe'
- # FIXME: first we should search . and the directory the executable is in
- shlibpath_var=PATH
- ;;
-
-darwin* | rhapsody*)
- dynamic_linker="$host_os dyld"
- version_type=darwin
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext'
- soname_spec='${libname}${release}${major}$shared_ext'
- shlibpath_overrides_runpath=yes
- shlibpath_var=DYLD_LIBRARY_PATH
- shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
-
- sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"
- sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
- ;;
-
-dgux*)
- version_type=linux
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext'
- soname_spec='${libname}${release}${shared_ext}$major'
- shlibpath_var=LD_LIBRARY_PATH
- ;;
-
-freebsd* | dragonfly*)
- # DragonFly does not have aout. When/if they implement a new
- # versioning mechanism, adjust this.
- if test -x /usr/bin/objformat; then
- objformat=`/usr/bin/objformat`
- else
- case $host_os in
- freebsd[23].*) objformat=aout ;;
- *) objformat=elf ;;
- esac
- fi
- version_type=freebsd-$objformat
- case $version_type in
- freebsd-elf*)
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
- need_version=no
- need_lib_prefix=no
- ;;
- freebsd-*)
- library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix'
- need_version=yes
- ;;
- esac
- shlibpath_var=LD_LIBRARY_PATH
- case $host_os in
- freebsd2.*)
- shlibpath_overrides_runpath=yes
- ;;
- freebsd3.[01]* | freebsdelf3.[01]*)
- shlibpath_overrides_runpath=yes
- hardcode_into_libs=yes
- ;;
- freebsd3.[2-9]* | freebsdelf3.[2-9]* | \
- freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1)
- shlibpath_overrides_runpath=no
- hardcode_into_libs=yes
- ;;
- *) # from 4.6 on, and DragonFly
- shlibpath_overrides_runpath=yes
- hardcode_into_libs=yes
- ;;
- esac
- ;;
-
-haiku*)
- version_type=linux
- need_lib_prefix=no
- need_version=no
- dynamic_linker="$host_os runtime_loader"
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- shlibpath_var=LIBRARY_PATH
- shlibpath_overrides_runpath=yes
- sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/system/lib'
- hardcode_into_libs=yes
- ;;
-
-hpux9* | hpux10* | hpux11*)
- # Give a soname corresponding to the major version so that dld.sl refuses to
- # link against other versions.
- version_type=sunos
- need_lib_prefix=no
- need_version=no
- case $host_cpu in
- ia64*)
- shrext_cmds='.so'
- hardcode_into_libs=yes
- dynamic_linker="$host_os dld.so"
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- if test "X$HPUX_IA64_MODE" = X32; then
- sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
- else
- sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
- fi
- sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
- ;;
- hppa*64*)
- shrext_cmds='.sl'
- hardcode_into_libs=yes
- dynamic_linker="$host_os dld.sl"
- shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH
- shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64"
- sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec
- ;;
- *)
- shrext_cmds='.sl'
- dynamic_linker="$host_os dld.sl"
- shlibpath_var=SHLIB_PATH
- shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- ;;
- esac
- # HP-UX runs *really* slowly unless shared libraries are mode 555, ...
- postinstall_cmds='chmod 555 $lib'
- # or fails outright, so override atomically:
- install_override_mode=555
- ;;
-
-interix[3-9]*)
- version_type=linux
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=no
- hardcode_into_libs=yes
- ;;
-
-irix5* | irix6* | nonstopux*)
- case $host_os in
- nonstopux*) version_type=nonstopux ;;
- *)
- if test "$lt_cv_prog_gnu_ld" = yes; then
- version_type=linux
- else
- version_type=irix
- fi ;;
- esac
- need_lib_prefix=no
- need_version=no
- soname_spec='${libname}${release}${shared_ext}$major'
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}'
- case $host_os in
- irix5* | nonstopux*)
- libsuff= shlibsuff=
- ;;
- *)
- case $LD in # libtool.m4 will add one of these switches to LD
- *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
- libsuff= shlibsuff= libmagic=32-bit;;
- *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
- libsuff=32 shlibsuff=N32 libmagic=N32;;
- *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
- libsuff=64 shlibsuff=64 libmagic=64-bit;;
- *) libsuff= shlibsuff= libmagic=never-match;;
- esac
- ;;
- esac
- shlibpath_var=LD_LIBRARY${shlibsuff}_PATH
- shlibpath_overrides_runpath=no
- sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}"
- sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}"
- hardcode_into_libs=yes
- ;;
-
-# No shared lib support for Linux oldld, aout, or coff.
-linux*oldld* | linux*aout* | linux*coff*)
- dynamic_linker=no
- ;;
-
-# This must be Linux ELF.
-
-# uclinux* changes (here and below) have been submitted to the libtool
-# project, but have not yet been accepted: they are GCC-local changes
-# for the time being. (See
-# https://lists.gnu.org/archive/html/libtool-patches/2018-05/msg00000.html)
-linux* | k*bsd*-gnu | kopensolaris*-gnu | gnu* | uclinuxfdpiceabi)
- version_type=linux
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=no
-
- # Some binutils ld are patched to set DT_RUNPATH
- if ${lt_cv_shlibpath_overrides_runpath+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- lt_cv_shlibpath_overrides_runpath=no
- save_LDFLAGS=$LDFLAGS
- save_libdir=$libdir
- eval "libdir=/foo; wl=\"$lt_prog_compiler_wl\"; \
- LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec\""
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-int
-main ()
-{
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- if ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then :
- lt_cv_shlibpath_overrides_runpath=yes
-fi
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LDFLAGS=$save_LDFLAGS
- libdir=$save_libdir
-
-fi
-
- shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath
-
- # This implies no fast_install, which is unacceptable.
- # Some rework will be needed to allow for fast_install
- # before this can be enabled.
- hardcode_into_libs=yes
-
- # find out which ABI we are using
- libsuff=
- case "$host_cpu" in
- x86_64*|s390*|powerpc*|ppc*|sparc*)
- echo 'int i;' > conftest.$ac_ext
- if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
- (eval $ac_compile) 2>&5
- ac_status=$?
- echo "$as_me:$LINENO: \$? = $ac_status" >&5
- (exit $ac_status); }; then
- case `/usr/bin/file conftest.$ac_objext` in
- *64-bit*)
- libsuff=
- if test x"$sys_lib_search_path_spec" = x"/lib /usr/lib /usr/local/lib"; then
- sys_lib_search_path_spec="/lib${libsuff} /usr/lib${libsuff} /usr/local/lib${libsuff}"
- fi
- sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff}"
- ;;
- *32-bit*)
- libsuff=32
- if test x"$sys_lib_search_path_spec" = x"/lib /usr/lib /usr/local/lib"; then
- sys_lib_search_path_spec="/lib${libsuff} /usr/lib${libsuff} /usr/local/lib${libsuff}"
- fi
- sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff}"
- ;;
- esac
- fi
- rm -rf conftest*
- ;;
- esac
-
- # Append ld.so.conf contents to the search path
- if test -f /etc/ld.so.conf; then
- lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '`
- sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff} $lt_ld_extra"
- fi
-
- # We used to test for /lib/ld.so.1 and disable shared libraries on
- # powerpc, because MkLinux only supported shared libraries with the
- # GNU dynamic linker. Since this was broken with cross compilers,
- # most powerpc-linux boxes support dynamic linking these days and
- # people can always --disable-shared, the test was removed, and we
- # assume the GNU/Linux dynamic linker is in use.
- dynamic_linker='GNU/Linux ld.so'
- ;;
-
-netbsd*)
- version_type=sunos
- need_lib_prefix=no
- need_version=no
- if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
- finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
- dynamic_linker='NetBSD (a.out) ld.so'
- else
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- dynamic_linker='NetBSD ld.elf_so'
- fi
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=yes
- hardcode_into_libs=yes
- ;;
-
-newsos6)
- version_type=linux
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=yes
- ;;
-
-*nto* | *qnx*)
- version_type=qnx
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=no
- hardcode_into_libs=yes
- dynamic_linker='ldqnx.so'
- ;;
-
-openbsd*)
- version_type=sunos
- sys_lib_dlsearch_path_spec="/usr/lib"
- need_lib_prefix=no
- # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
- case $host_os in
- openbsd3.3 | openbsd3.3.*) need_version=yes ;;
- *) need_version=no ;;
- esac
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
- finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir'
- shlibpath_var=LD_LIBRARY_PATH
- if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
- case $host_os in
- openbsd2.[89] | openbsd2.[89].*)
- shlibpath_overrides_runpath=no
- ;;
- *)
- shlibpath_overrides_runpath=yes
- ;;
- esac
- else
- shlibpath_overrides_runpath=yes
- fi
- ;;
-
-os2*)
- libname_spec='$name'
- shrext_cmds=".dll"
- need_lib_prefix=no
- library_names_spec='$libname${shared_ext} $libname.a'
- dynamic_linker='OS/2 ld.exe'
- shlibpath_var=LIBPATH
- ;;
-
-osf3* | osf4* | osf5*)
- version_type=osf
- need_lib_prefix=no
- need_version=no
- soname_spec='${libname}${release}${shared_ext}$major'
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- shlibpath_var=LD_LIBRARY_PATH
- sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib"
- sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
- ;;
-
-rdos*)
- dynamic_linker=no
- ;;
-
-solaris*)
- version_type=linux
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=yes
- hardcode_into_libs=yes
- # ldd complains unless libraries are executable
- postinstall_cmds='chmod +x $lib'
- ;;
-
-sunos4*)
- version_type=sunos
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix'
- finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=yes
- if test "$with_gnu_ld" = yes; then
- need_lib_prefix=no
- fi
- need_version=yes
- ;;
-
-sysv4 | sysv4.3*)
- version_type=linux
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- shlibpath_var=LD_LIBRARY_PATH
- case $host_vendor in
- sni)
- shlibpath_overrides_runpath=no
- need_lib_prefix=no
- runpath_var=LD_RUN_PATH
- ;;
- siemens)
- need_lib_prefix=no
- ;;
- motorola)
- need_lib_prefix=no
- need_version=no
- shlibpath_overrides_runpath=no
- sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib'
- ;;
- esac
- ;;
-
-sysv4*MP*)
- if test -d /usr/nec ;then
- version_type=linux
- library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}'
- soname_spec='$libname${shared_ext}.$major'
- shlibpath_var=LD_LIBRARY_PATH
- fi
- ;;
-
-sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
- version_type=freebsd-elf
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=yes
- hardcode_into_libs=yes
- if test "$with_gnu_ld" = yes; then
- sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
- else
- sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
- case $host_os in
- sco3.2v5*)
- sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
- ;;
- esac
- fi
- sys_lib_dlsearch_path_spec='/usr/lib'
- ;;
-
-tpf*)
- # TPF is a cross-target only. Preferred cross-host = GNU/Linux.
- version_type=linux
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- shlibpath_var=LD_LIBRARY_PATH
- shlibpath_overrides_runpath=no
- hardcode_into_libs=yes
- ;;
-
-uts4*)
- version_type=linux
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- shlibpath_var=LD_LIBRARY_PATH
- ;;
-
-# Shared libraries for VwWorks, >= 7 only at this stage
-# and (fpic) still incompatible with "large" code models
-# in a few configurations. Only for RTP mode in any case,
-# and upon explicit request at configure time.
-vxworks7*)
- dynamic_linker=no
- case ${with_multisubdir}-${enable_shared} in
- *large*)
- ;;
- *mrtp*-yes)
- version_type=linux
- need_lib_prefix=no
- need_version=no
- library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
- soname_spec='${libname}${release}${shared_ext}$major'
- dynamic_linker="$host_os module_loader"
- ;;
- esac
- ;;
-*)
- dynamic_linker=no
- ;;
-esac
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5
-$as_echo "$dynamic_linker" >&6; }
-test "$dynamic_linker" = no && can_build_shared=no
-
-variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
-if test "$GCC" = yes; then
- variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
-fi
-
-if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then
- sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec"
-fi
-if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then
- sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec"
-fi
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5
-$as_echo_n "checking how to hardcode library paths into programs... " >&6; }
-hardcode_action=
-if test -n "$hardcode_libdir_flag_spec" ||
- test -n "$runpath_var" ||
- test "X$hardcode_automatic" = "Xyes" ; then
-
- # We can hardcode non-existent directories.
- if test "$hardcode_direct" != no &&
- # If the only mechanism to avoid hardcoding is shlibpath_var, we
- # have to relink, otherwise we might link with an installed library
- # when we should be linking with a yet-to-be-installed one
- ## test "$_LT_TAGVAR(hardcode_shlibpath_var, )" != no &&
- test "$hardcode_minus_L" != no; then
- # Linking always hardcodes the temporary library directory.
- hardcode_action=relink
- else
- # We can link without hardcoding, and we can hardcode nonexisting dirs.
- hardcode_action=immediate
- fi
-else
- # We cannot hardcode anything, or else we can only hardcode existing
- # directories.
- hardcode_action=unsupported
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action" >&5
-$as_echo "$hardcode_action" >&6; }
-
-if test "$hardcode_action" = relink ||
- test "$inherit_rpath" = yes; then
- # Fast installation is not supported
- enable_fast_install=no
-elif test "$shlibpath_overrides_runpath" = yes ||
- test "$enable_shared" = no; then
- # Fast installation is not necessary
- enable_fast_install=needless
-fi
-
-
-
-
-
-
- if test "x$enable_dlopen" != xyes; then
- enable_dlopen=unknown
- enable_dlopen_self=unknown
- enable_dlopen_self_static=unknown
-else
- lt_cv_dlopen=no
- lt_cv_dlopen_libs=
-
- case $host_os in
- beos*)
- lt_cv_dlopen="load_add_on"
- lt_cv_dlopen_libs=
- lt_cv_dlopen_self=yes
- ;;
-
- mingw* | pw32* | cegcc*)
- lt_cv_dlopen="LoadLibrary"
- lt_cv_dlopen_libs=
- ;;
-
- cygwin*)
- lt_cv_dlopen="dlopen"
- lt_cv_dlopen_libs=
- ;;
-
- darwin*)
- # if libdl is installed we need to link against it
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
-$as_echo_n "checking for dlopen in -ldl... " >&6; }
-if ${ac_cv_lib_dl_dlopen+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-ldl $LIBS"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char dlopen ();
-int
-main ()
-{
-return dlopen ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_lib_dl_dlopen=yes
-else
- ac_cv_lib_dl_dlopen=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
-$as_echo "$ac_cv_lib_dl_dlopen" >&6; }
-if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
- lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
-else
-
- lt_cv_dlopen="dyld"
- lt_cv_dlopen_libs=
- lt_cv_dlopen_self=yes
-
-fi
-
- ;;
-
- *)
- ac_fn_c_check_func "$LINENO" "shl_load" "ac_cv_func_shl_load"
-if test "x$ac_cv_func_shl_load" = xyes; then :
- lt_cv_dlopen="shl_load"
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5
-$as_echo_n "checking for shl_load in -ldld... " >&6; }
-if ${ac_cv_lib_dld_shl_load+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-ldld $LIBS"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char shl_load ();
-int
-main ()
-{
-return shl_load ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_lib_dld_shl_load=yes
-else
- ac_cv_lib_dld_shl_load=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5
-$as_echo "$ac_cv_lib_dld_shl_load" >&6; }
-if test "x$ac_cv_lib_dld_shl_load" = xyes; then :
- lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"
-else
- ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen"
-if test "x$ac_cv_func_dlopen" = xyes; then :
- lt_cv_dlopen="dlopen"
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
-$as_echo_n "checking for dlopen in -ldl... " >&6; }
-if ${ac_cv_lib_dl_dlopen+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-ldl $LIBS"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char dlopen ();
-int
-main ()
-{
-return dlopen ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_lib_dl_dlopen=yes
-else
- ac_cv_lib_dl_dlopen=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
-$as_echo "$ac_cv_lib_dl_dlopen" >&6; }
-if test "x$ac_cv_lib_dl_dlopen" = xyes; then :
- lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5
-$as_echo_n "checking for dlopen in -lsvld... " >&6; }
-if ${ac_cv_lib_svld_dlopen+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-lsvld $LIBS"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char dlopen ();
-int
-main ()
-{
-return dlopen ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_lib_svld_dlopen=yes
-else
- ac_cv_lib_svld_dlopen=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5
-$as_echo "$ac_cv_lib_svld_dlopen" >&6; }
-if test "x$ac_cv_lib_svld_dlopen" = xyes; then :
- lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5
-$as_echo_n "checking for dld_link in -ldld... " >&6; }
-if ${ac_cv_lib_dld_dld_link+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-ldld $LIBS"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char dld_link ();
-int
-main ()
-{
-return dld_link ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_lib_dld_dld_link=yes
-else
- ac_cv_lib_dld_dld_link=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_dld_link" >&5
-$as_echo "$ac_cv_lib_dld_dld_link" >&6; }
-if test "x$ac_cv_lib_dld_dld_link" = xyes; then :
- lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"
-fi
-
-
-fi
-
-
-fi
-
-
-fi
-
-
-fi
-
-
-fi
-
- ;;
- esac
-
- if test "x$lt_cv_dlopen" != xno; then
- enable_dlopen=yes
- else
- enable_dlopen=no
- fi
-
- case $lt_cv_dlopen in
- dlopen)
- save_CPPFLAGS="$CPPFLAGS"
- test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
-
- save_LDFLAGS="$LDFLAGS"
- wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
-
- save_LIBS="$LIBS"
- LIBS="$lt_cv_dlopen_libs $LIBS"
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a program can dlopen itself" >&5
-$as_echo_n "checking whether a program can dlopen itself... " >&6; }
-if ${lt_cv_dlopen_self+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test "$cross_compiling" = yes; then :
- lt_cv_dlopen_self=cross
-else
- lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
- lt_status=$lt_dlunknown
- cat > conftest.$ac_ext <<_LT_EOF
-#line 11093 "configure"
-#include "confdefs.h"
-
-#if HAVE_DLFCN_H
-#include <dlfcn.h>
-#endif
-
-#include <stdio.h>
-
-#ifdef RTLD_GLOBAL
-# define LT_DLGLOBAL RTLD_GLOBAL
-#else
-# ifdef DL_GLOBAL
-# define LT_DLGLOBAL DL_GLOBAL
-# else
-# define LT_DLGLOBAL 0
-# endif
-#endif
-
-/* We may have to define LT_DLLAZY_OR_NOW in the command line if we
- find out it does not work in some platform. */
-#ifndef LT_DLLAZY_OR_NOW
-# ifdef RTLD_LAZY
-# define LT_DLLAZY_OR_NOW RTLD_LAZY
-# else
-# ifdef DL_LAZY
-# define LT_DLLAZY_OR_NOW DL_LAZY
-# else
-# ifdef RTLD_NOW
-# define LT_DLLAZY_OR_NOW RTLD_NOW
-# else
-# ifdef DL_NOW
-# define LT_DLLAZY_OR_NOW DL_NOW
-# else
-# define LT_DLLAZY_OR_NOW 0
-# endif
-# endif
-# endif
-# endif
-#endif
-
-/* When -fvisbility=hidden is used, assume the code has been annotated
- correspondingly for the symbols needed. */
-#if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
-void fnord () __attribute__((visibility("default")));
-#endif
-
-void fnord () { int i=42; }
-int main ()
-{
- void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
- int status = $lt_dlunknown;
-
- if (self)
- {
- if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
- else
- {
- if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
- else puts (dlerror ());
- }
- /* dlclose (self); */
- }
- else
- puts (dlerror ());
-
- return status;
-}
-_LT_EOF
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
- (eval $ac_link) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then
- (./conftest; exit; ) >&5 2>/dev/null
- lt_status=$?
- case x$lt_status in
- x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;;
- x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;;
- x$lt_dlunknown|x*) lt_cv_dlopen_self=no ;;
- esac
- else :
- # compilation failed
- lt_cv_dlopen_self=no
- fi
-fi
-rm -fr conftest*
-
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self" >&5
-$as_echo "$lt_cv_dlopen_self" >&6; }
-
- if test "x$lt_cv_dlopen_self" = xyes; then
- wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a statically linked program can dlopen itself" >&5
-$as_echo_n "checking whether a statically linked program can dlopen itself... " >&6; }
-if ${lt_cv_dlopen_self_static+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test "$cross_compiling" = yes; then :
- lt_cv_dlopen_self_static=cross
-else
- lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
- lt_status=$lt_dlunknown
- cat > conftest.$ac_ext <<_LT_EOF
-#line 11199 "configure"
-#include "confdefs.h"
-
-#if HAVE_DLFCN_H
-#include <dlfcn.h>
-#endif
-
-#include <stdio.h>
-
-#ifdef RTLD_GLOBAL
-# define LT_DLGLOBAL RTLD_GLOBAL
-#else
-# ifdef DL_GLOBAL
-# define LT_DLGLOBAL DL_GLOBAL
-# else
-# define LT_DLGLOBAL 0
-# endif
-#endif
-
-/* We may have to define LT_DLLAZY_OR_NOW in the command line if we
- find out it does not work in some platform. */
-#ifndef LT_DLLAZY_OR_NOW
-# ifdef RTLD_LAZY
-# define LT_DLLAZY_OR_NOW RTLD_LAZY
-# else
-# ifdef DL_LAZY
-# define LT_DLLAZY_OR_NOW DL_LAZY
-# else
-# ifdef RTLD_NOW
-# define LT_DLLAZY_OR_NOW RTLD_NOW
-# else
-# ifdef DL_NOW
-# define LT_DLLAZY_OR_NOW DL_NOW
-# else
-# define LT_DLLAZY_OR_NOW 0
-# endif
-# endif
-# endif
-# endif
-#endif
-
-/* When -fvisbility=hidden is used, assume the code has been annotated
- correspondingly for the symbols needed. */
-#if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3))
-void fnord () __attribute__((visibility("default")));
-#endif
-
-void fnord () { int i=42; }
-int main ()
-{
- void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
- int status = $lt_dlunknown;
-
- if (self)
- {
- if (dlsym (self,"fnord")) status = $lt_dlno_uscore;
- else
- {
- if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
- else puts (dlerror ());
- }
- /* dlclose (self); */
- }
- else
- puts (dlerror ());
-
- return status;
-}
-_LT_EOF
- if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5
- (eval $ac_link) 2>&5
- ac_status=$?
- $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
- test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then
- (./conftest; exit; ) >&5 2>/dev/null
- lt_status=$?
- case x$lt_status in
- x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;;
- x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;;
- x$lt_dlunknown|x*) lt_cv_dlopen_self_static=no ;;
- esac
- else :
- # compilation failed
- lt_cv_dlopen_self_static=no
- fi
-fi
-rm -fr conftest*
-
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self_static" >&5
-$as_echo "$lt_cv_dlopen_self_static" >&6; }
- fi
-
- CPPFLAGS="$save_CPPFLAGS"
- LDFLAGS="$save_LDFLAGS"
- LIBS="$save_LIBS"
- ;;
- esac
-
- case $lt_cv_dlopen_self in
- yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
- *) enable_dlopen_self=unknown ;;
- esac
-
- case $lt_cv_dlopen_self_static in
- yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
- *) enable_dlopen_self_static=unknown ;;
- esac
-fi
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-striplib=
-old_striplib=
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stripping libraries is possible" >&5
-$as_echo_n "checking whether stripping libraries is possible... " >&6; }
-if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then
- test -z "$old_striplib" && old_striplib="$STRIP --strip-debug"
- test -z "$striplib" && striplib="$STRIP --strip-unneeded"
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-else
-# FIXME - insert some real tests, host_os isn't really good enough
- case $host_os in
- darwin*)
- if test -n "$STRIP" ; then
- striplib="$STRIP -x"
- old_striplib="$STRIP -S"
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- fi
- ;;
- *)
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
- ;;
- esac
-fi
-
-
-
-
-
-
-
-
-
-
-
-
- # Report which library types will actually be built
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libtool supports shared libraries" >&5
-$as_echo_n "checking if libtool supports shared libraries... " >&6; }
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $can_build_shared" >&5
-$as_echo "$can_build_shared" >&6; }
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries" >&5
-$as_echo_n "checking whether to build shared libraries... " >&6; }
- test "$can_build_shared" = "no" && enable_shared=no
-
- # On AIX, shared libraries and static libraries use the same namespace, and
- # are all built from PIC.
- case $host_os in
- aix3*)
- test "$enable_shared" = yes && enable_static=no
- if test -n "$RANLIB"; then
- archive_cmds="$archive_cmds~\$RANLIB \$lib"
- postinstall_cmds='$RANLIB $lib'
- fi
- ;;
-
- aix[4-9]*)
- if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
- test "$enable_shared" = yes && enable_static=no
- fi
- ;;
- esac
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5
-$as_echo "$enable_shared" >&6; }
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build static libraries" >&5
-$as_echo_n "checking whether to build static libraries... " >&6; }
- # Make sure either enable_shared or enable_static is yes.
- test "$enable_shared" = yes || enable_static=yes
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_static" >&5
-$as_echo "$enable_static" >&6; }
-
-
-
-
-fi
-ac_ext=c
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
-ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
-ac_compiler_gnu=$ac_cv_c_compiler_gnu
-
-CC="$lt_save_CC"
-
-
-
-
-
-
-
-
-
-
-
-
-
- ac_config_commands="$ac_config_commands libtool"
-
-
-
-
-# Only expand once:
-
-
-
-ac_checking=
-. ${srcdir}/../bfd/development.sh
-test "$development" = true && ac_checking=yes
-# Check whether --enable-checking was given.
-if test "${enable_checking+set}" = set; then :
- enableval=$enable_checking; case "${enableval}" in
- no|none) ac_checking= ;;
- *) ac_checking=yes ;;
-esac
-fi
-if test x$ac_checking != x ; then
-
-$as_echo "#define ENABLE_CHECKING 1" >>confdefs.h
-
-fi
-
-# Check whether --enable-targets was given.
-if test "${enable_targets+set}" = set; then :
- enableval=$enable_targets; case "${enableval}" in
- yes | "") as_fn_error $? "enable-targets option must specify target names or 'all'" "$LINENO" 5
- ;;
- no) enable_targets= ;;
- *) enable_targets=$enableval ;;
-esac
-fi
-
-
-# Set the 'development' global.
-. $srcdir/../bfd/development.sh
-
-# Set acp_cpp_for_build variable
-ac_cpp_for_build="$CC_FOR_BUILD -E $CPPFLAGS_FOR_BUILD"
-
-# Default set of GCC warnings to enable.
-GCC_WARN_CFLAGS="-W -Wall -Wstrict-prototypes -Wmissing-prototypes"
-GCC_WARN_CFLAGS_FOR_BUILD="-W -Wall -Wstrict-prototypes -Wmissing-prototypes"
-
-# Add -Wshadow if the compiler is a sufficiently recent version of GCC.
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-__GNUC__
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "(^[0-3]$|^__GNUC__$)" >/dev/null 2>&1; then :
-
-else
- GCC_WARN_CFLAGS="$GCC_WARN_CFLAGS -Wshadow"
-fi
-rm -f conftest*
-
-
-# Add -Wstack-usage if the compiler is a sufficiently recent version of GCC.
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-__GNUC__
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "(^[0-4]$|^__GNUC__$)" >/dev/null 2>&1; then :
-
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-__clang__
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "^__clang__$" >/dev/null 2>&1; then :
- GCC_WARN_CFLAGS="$GCC_WARN_CFLAGS -Wstack-usage=262144"
-fi
-rm -f conftest*
-
-fi
-rm -f conftest*
-
-
-# Set WARN_WRITE_STRINGS if the compiler supports -Wwrite-strings.
-WARN_WRITE_STRINGS=""
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-__GNUC__
-_ACEOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- $EGREP "(^[0-3]$|^__GNUC__$)" >/dev/null 2>&1; then :
-
-else
- WARN_WRITE_STRINGS="-Wwrite-strings"
-fi
-rm -f conftest*
-
-
-# Verify CC_FOR_BUILD to be compatible with warning flags
-
-# Add -Wshadow if the compiler is a sufficiently recent version of GCC.
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-__GNUC__
-_ACEOF
-if (eval "$ac_cpp_for_build conftest.$ac_ext") 2>&5 |
- $EGREP "(^[0-3]$|^__GNUC__$)" >/dev/null 2>&1; then :
-
-else
- GCC_WARN_CFLAGS_FOR_BUILD="$GCC_WARN_CFLAGS_FOR_BUILD -Wshadow"
-fi
-rm -f conftest*
-
-
-# Add -Wstack-usage if the compiler is a sufficiently recent version of GCC.
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-__GNUC__
-_ACEOF
-if (eval "$ac_cpp_for_build conftest.$ac_ext") 2>&5 |
- $EGREP "(^[0-4]$|^__GNUC__$)" >/dev/null 2>&1; then :
-
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-__clang__
-_ACEOF
-if (eval "$ac_cpp_for_build conftest.$ac_ext") 2>&5 |
- $EGREP "^__clang__$" >/dev/null 2>&1; then :
- GCC_WARN_CFLAGS_FOR_BUILD="$GCC_WARN_CFLAGS_FOR_BUILD -Wstack-usage=262144"
-fi
-rm -f conftest*
-
-fi
-rm -f conftest*
-
-
-# Check whether --enable-werror was given.
-if test "${enable_werror+set}" = set; then :
- enableval=$enable_werror; case "${enableval}" in
- yes | y) ERROR_ON_WARNING="yes" ;;
- no | n) ERROR_ON_WARNING="no" ;;
- *) as_fn_error $? "bad value ${enableval} for --enable-werror" "$LINENO" 5 ;;
- esac
-fi
-
-
-# Disable -Wformat by default when using gcc on mingw
-case "${host}" in
- *-*-mingw32*)
- if test "${GCC}" = yes -a -z "${ERROR_ON_WARNING}" ; then
- GCC_WARN_CFLAGS="$GCC_WARN_CFLAGS -Wno-format"
- GCC_WARN_CFLAGS_FOR_BUILD="$GCC_WARN_CFLAGS_FOR_BUILD -Wno-format"
- fi
- ;;
- *) ;;
-esac
-
-# Enable -Werror by default when using gcc. Turn it off for releases.
-if test "${GCC}" = yes -a -z "${ERROR_ON_WARNING}" -a "$development" = true ; then
- ERROR_ON_WARNING=yes
-fi
-
-NO_WERROR=
-if test "${ERROR_ON_WARNING}" = yes ; then
- GCC_WARN_CFLAGS="$GCC_WARN_CFLAGS -Werror"
- GCC_WARN_CFLAGS_FOR_BUILD="$GCC_WARN_CFLAGS_FOR_BUILD -Werror"
- NO_WERROR="-Wno-error"
-fi
-
-if test "${GCC}" = yes ; then
- WARN_CFLAGS="${GCC_WARN_CFLAGS}"
- WARN_CFLAGS_FOR_BUILD="${GCC_WARN_CFLAGS_FOR_BUILD}"
-fi
-
-# Check whether --enable-build-warnings was given.
-if test "${enable_build_warnings+set}" = set; then :
- enableval=$enable_build_warnings; case "${enableval}" in
- yes) WARN_CFLAGS="${GCC_WARN_CFLAGS}"
- WARN_CFLAGS_FOR_BUILD="${GCC_WARN_CFLAGS_FOR_BUILD}";;
- no) if test "${GCC}" = yes ; then
- WARN_CFLAGS="-w"
- WARN_CFLAGS_FOR_BUILD="-w"
- fi;;
- ,*) t=`echo "${enableval}" | sed -e "s/,/ /g"`
- WARN_CFLAGS="${GCC_WARN_CFLAGS} ${t}"
- WARN_CFLAGS_FOR_BUILD="${GCC_WARN_CFLAGS_FOR_BUILD} ${t}";;
- *,) t=`echo "${enableval}" | sed -e "s/,/ /g"`
- WARN_CFLAGS="${t} ${GCC_WARN_CFLAGS}"
- WARN_CFLAGS_FOR_BUILD="${t} ${GCC_WARN_CFLAGS_FOR_BUILD}";;
- *) WARN_CFLAGS=`echo "${enableval}" | sed -e "s/,/ /g"`
- WARN_CFLAGS_FOR_BUILD=`echo "${enableval}" | sed -e "s/,/ /g"`;;
-esac
-fi
-
-
-if test x"$silent" != x"yes" && test x"$WARN_CFLAGS" != x""; then
- echo "Setting warning flags = $WARN_CFLAGS" 6>&1
-fi
-
-
-
-
-
-
-
-ac_config_headers="$ac_config_headers config.h:config.in"
-
-
-# PR 14072
-
-
-if test -z "$target" ; then
- as_fn_error $? "Unrecognized target system type; please check config.sub." "$LINENO" 5
-fi
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable maintainer-specific portions of Makefiles" >&5
-$as_echo_n "checking whether to enable maintainer-specific portions of Makefiles... " >&6; }
- # Check whether --enable-maintainer-mode was given.
-if test "${enable_maintainer_mode+set}" = set; then :
- enableval=$enable_maintainer_mode; USE_MAINTAINER_MODE=$enableval
-else
- USE_MAINTAINER_MODE=no
-fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_MAINTAINER_MODE" >&5
-$as_echo "$USE_MAINTAINER_MODE" >&6; }
- if test $USE_MAINTAINER_MODE = yes; then
- MAINTAINER_MODE_TRUE=
- MAINTAINER_MODE_FALSE='#'
-else
- MAINTAINER_MODE_TRUE='#'
- MAINTAINER_MODE_FALSE=
-fi
-
- MAINT=$MAINTAINER_MODE_TRUE
-
-
- case ${build_alias} in
- "") build_noncanonical=${build} ;;
- *) build_noncanonical=${build_alias} ;;
-esac
-
- case ${host_alias} in
- "") host_noncanonical=${build_noncanonical} ;;
- *) host_noncanonical=${host_alias} ;;
-esac
-
- case ${target_alias} in
- "") target_noncanonical=${host_noncanonical} ;;
- *) target_noncanonical=${target_alias} ;;
-esac
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to install libbfd" >&5
-$as_echo_n "checking whether to install libbfd... " >&6; }
- # Check whether --enable-install-libbfd was given.
-if test "${enable_install_libbfd+set}" = set; then :
- enableval=$enable_install_libbfd; install_libbfd_p=$enableval
-else
- if test "${host}" = "${target}" || test "$enable_shared" = "yes"; then
- install_libbfd_p=yes
- else
- install_libbfd_p=no
- fi
-fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $install_libbfd_p" >&5
-$as_echo "$install_libbfd_p" >&6; }
- if test $install_libbfd_p = yes; then
- INSTALL_LIBBFD_TRUE=
- INSTALL_LIBBFD_FALSE='#'
-else
- INSTALL_LIBBFD_TRUE='#'
- INSTALL_LIBBFD_FALSE=
-fi
-
- # Need _noncanonical variables for this.
-
-
-
-
- # libbfd.a is a host library containing target dependent code
- bfdlibdir='$(libdir)'
- bfdincludedir='$(includedir)'
- if test "${host}" != "${target}"; then
- bfdlibdir='$(exec_prefix)/$(host_noncanonical)/$(target_noncanonical)/lib'
- bfdincludedir='$(exec_prefix)/$(host_noncanonical)/$(target_noncanonical)/include'
- fi
-
-
-
-
-
-
-
-
-# host-specific stuff:
-
-ALL_LINGUAS="da de es fi fr ga id it nl pt_BR ro sr sv tr uk vi zh_CN"
-
- MKINSTALLDIRS=
- if test -n "$ac_aux_dir"; then
- case "$ac_aux_dir" in
- /*) MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs" ;;
- *) MKINSTALLDIRS="\$(top_builddir)/$ac_aux_dir/mkinstalldirs" ;;
- esac
- fi
- if test -z "$MKINSTALLDIRS"; then
- MKINSTALLDIRS="\$(top_srcdir)/mkinstalldirs"
- fi
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NLS is requested" >&5
-$as_echo_n "checking whether NLS is requested... " >&6; }
- # Check whether --enable-nls was given.
-if test "${enable_nls+set}" = set; then :
- enableval=$enable_nls; USE_NLS=$enableval
-else
- USE_NLS=yes
-fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_NLS" >&5
-$as_echo "$USE_NLS" >&6; }
-
-
-
-
-
-
-# Prepare PATH_SEPARATOR.
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-
-# Find out how to test for executable files. Don't use a zero-byte file,
-# as systems may use methods other than mode bits to determine executability.
-cat >conf$$.file <<_ASEOF
-#! /bin/sh
-exit 0
-_ASEOF
-chmod +x conf$$.file
-if test -x conf$$.file >/dev/null 2>&1; then
- ac_executable_p="test -x"
-else
- ac_executable_p="test -f"
-fi
-rm -f conf$$.file
-
-# Extract the first word of "msgfmt", so it can be a program name with args.
-set dummy msgfmt; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_MSGFMT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case "$MSGFMT" in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
- ;;
- *)
- ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH; do
- IFS="$ac_save_IFS"
- test -z "$ac_dir" && ac_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
- if $ac_dir/$ac_word --statistics /dev/null >/dev/null 2>&1 &&
- (if $ac_dir/$ac_word --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- ac_cv_path_MSGFMT="$ac_dir/$ac_word$ac_exec_ext"
- break 2
- fi
- fi
- done
- done
- IFS="$ac_save_IFS"
- test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT=":"
- ;;
-esac
-fi
-MSGFMT="$ac_cv_path_MSGFMT"
-if test "$MSGFMT" != ":"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGFMT" >&5
-$as_echo "$MSGFMT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- # Extract the first word of "gmsgfmt", so it can be a program name with args.
-set dummy gmsgfmt; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_GMSGFMT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $GMSGFMT in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
- ;;
- *)
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_path_GMSGFMT="$as_dir/$ac_word$ac_exec_ext"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
- test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT"
- ;;
-esac
-fi
-GMSGFMT=$ac_cv_path_GMSGFMT
-if test -n "$GMSGFMT"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GMSGFMT" >&5
-$as_echo "$GMSGFMT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-
-
-# Prepare PATH_SEPARATOR.
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-
-# Find out how to test for executable files. Don't use a zero-byte file,
-# as systems may use methods other than mode bits to determine executability.
-cat >conf$$.file <<_ASEOF
-#! /bin/sh
-exit 0
-_ASEOF
-chmod +x conf$$.file
-if test -x conf$$.file >/dev/null 2>&1; then
- ac_executable_p="test -x"
-else
- ac_executable_p="test -f"
-fi
-rm -f conf$$.file
-
-# Extract the first word of "xgettext", so it can be a program name with args.
-set dummy xgettext; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_XGETTEXT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case "$XGETTEXT" in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
- ;;
- *)
- ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH; do
- IFS="$ac_save_IFS"
- test -z "$ac_dir" && ac_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
- if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >/dev/null 2>&1 &&
- (if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- ac_cv_path_XGETTEXT="$ac_dir/$ac_word$ac_exec_ext"
- break 2
- fi
- fi
- done
- done
- IFS="$ac_save_IFS"
- test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":"
- ;;
-esac
-fi
-XGETTEXT="$ac_cv_path_XGETTEXT"
-if test "$XGETTEXT" != ":"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XGETTEXT" >&5
-$as_echo "$XGETTEXT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- rm -f messages.po
-
-
-# Prepare PATH_SEPARATOR.
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-
-# Find out how to test for executable files. Don't use a zero-byte file,
-# as systems may use methods other than mode bits to determine executability.
-cat >conf$$.file <<_ASEOF
-#! /bin/sh
-exit 0
-_ASEOF
-chmod +x conf$$.file
-if test -x conf$$.file >/dev/null 2>&1; then
- ac_executable_p="test -x"
-else
- ac_executable_p="test -f"
-fi
-rm -f conf$$.file
-
-# Extract the first word of "msgmerge", so it can be a program name with args.
-set dummy msgmerge; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_MSGMERGE+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case "$MSGMERGE" in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_MSGMERGE="$MSGMERGE" # Let the user override the test with a path.
- ;;
- *)
- ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH; do
- IFS="$ac_save_IFS"
- test -z "$ac_dir" && ac_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
- if $ac_dir/$ac_word --update -q /dev/null /dev/null >/dev/null 2>&1; then
- ac_cv_path_MSGMERGE="$ac_dir/$ac_word$ac_exec_ext"
- break 2
- fi
- fi
- done
- done
- IFS="$ac_save_IFS"
- test -z "$ac_cv_path_MSGMERGE" && ac_cv_path_MSGMERGE=":"
- ;;
-esac
-fi
-MSGMERGE="$ac_cv_path_MSGMERGE"
-if test "$MSGMERGE" != ":"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGMERGE" >&5
-$as_echo "$MSGMERGE" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- if test "$GMSGFMT" != ":"; then
- if $GMSGFMT --statistics /dev/null >/dev/null 2>&1 &&
- (if $GMSGFMT --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- : ;
- else
- GMSGFMT=`echo "$GMSGFMT" | sed -e 's,^.*/,,'`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: found $GMSGFMT program is not GNU msgfmt; ignore it" >&5
-$as_echo "found $GMSGFMT program is not GNU msgfmt; ignore it" >&6; }
- GMSGFMT=":"
- fi
- fi
-
- if test "$XGETTEXT" != ":"; then
- if $XGETTEXT --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >/dev/null 2>&1 &&
- (if $XGETTEXT --omit-header --copyright-holder= --msgid-bugs-address= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- : ;
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: found xgettext program is not GNU xgettext; ignore it" >&5
-$as_echo "found xgettext program is not GNU xgettext; ignore it" >&6; }
- XGETTEXT=":"
- fi
- rm -f messages.po
- fi
-
- ac_config_commands="$ac_config_commands default-1"
-
-
-
- if test "X$prefix" = "XNONE"; then
- acl_final_prefix="$ac_default_prefix"
- else
- acl_final_prefix="$prefix"
- fi
- if test "X$exec_prefix" = "XNONE"; then
- acl_final_exec_prefix='${prefix}'
- else
- acl_final_exec_prefix="$exec_prefix"
- fi
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- eval acl_final_exec_prefix=\"$acl_final_exec_prefix\"
- prefix="$acl_save_prefix"
-
-
-# Check whether --with-gnu-ld was given.
-if test "${with_gnu_ld+set}" = set; then :
- withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
-else
- with_gnu_ld=no
-fi
-
-# Prepare PATH_SEPARATOR.
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-ac_prog=ld
-if test "$GCC" = yes; then
- # Check if gcc -print-prog-name=ld gives a path.
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by GCC" >&5
-$as_echo_n "checking for ld used by GCC... " >&6; }
- case $host in
- *-*-mingw*)
- # gcc leaves a trailing carriage return which upsets mingw
- ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
- *)
- ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
- esac
- case $ac_prog in
- # Accept absolute paths.
- [\\/]* | [A-Za-z]:[\\/]*)
- re_direlt='/[^/][^/]*/\.\./'
- # Canonicalize the path of ld
- ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
- while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
- ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
- done
- test -z "$LD" && LD="$ac_prog"
- ;;
- "")
- # If it fails, then pretend we aren't using GCC.
- ac_prog=ld
- ;;
- *)
- # If it is relative, then search for the first ld in PATH.
- with_gnu_ld=unknown
- ;;
- esac
-elif test "$with_gnu_ld" = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
-$as_echo_n "checking for GNU ld... " >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
-$as_echo_n "checking for non-GNU ld... " >&6; }
-fi
-if ${acl_cv_path_LD+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if test -z "$LD"; then
- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
- for ac_dir in $PATH; do
- test -z "$ac_dir" && ac_dir=.
- if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
- acl_cv_path_LD="$ac_dir/$ac_prog"
- # Check to see if the program is GNU ld. I'd rather use --version,
- # but apparently some GNU ld's only accept -v.
- # Break only if it was the GNU/non-GNU ld that we prefer.
- if "$acl_cv_path_LD" -v 2>&1 < /dev/null | $EGREP '(GNU|with BFD)' > /dev/null; then
- test "$with_gnu_ld" != no && break
- else
- test "$with_gnu_ld" != yes && break
- fi
- fi
- done
- IFS="$ac_save_ifs"
-else
- acl_cv_path_LD="$LD" # Let the user override the test with a path.
-fi
-fi
-
-LD="$acl_cv_path_LD"
-if test -n "$LD"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
-$as_echo "$LD" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
-$as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
-if ${acl_cv_prog_gnu_ld+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- # I'd rather use --version here, but apparently some GNU ld's only accept -v.
-if $LD -v 2>&1 </dev/null | $EGREP '(GNU|with BFD)' 1>&5; then
- acl_cv_prog_gnu_ld=yes
-else
- acl_cv_prog_gnu_ld=no
-fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $acl_cv_prog_gnu_ld" >&5
-$as_echo "$acl_cv_prog_gnu_ld" >&6; }
-with_gnu_ld=$acl_cv_prog_gnu_ld
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shared library run path origin" >&5
-$as_echo_n "checking for shared library run path origin... " >&6; }
-if ${acl_cv_rpath+:} false; then :
- $as_echo_n "(cached) " >&6
-else
-
- CC="$CC" GCC="$GCC" LDFLAGS="$LDFLAGS" LD="$LD" with_gnu_ld="$with_gnu_ld" \
- ${CONFIG_SHELL-/bin/sh} "$ac_aux_dir/config.rpath" "$host" > conftest.sh
- . ./conftest.sh
- rm -f ./conftest.sh
- acl_cv_rpath=done
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $acl_cv_rpath" >&5
-$as_echo "$acl_cv_rpath" >&6; }
- wl="$acl_cv_wl"
- libext="$acl_cv_libext"
- shlibext="$acl_cv_shlibext"
- hardcode_libdir_flag_spec="$acl_cv_hardcode_libdir_flag_spec"
- hardcode_libdir_separator="$acl_cv_hardcode_libdir_separator"
- hardcode_direct="$acl_cv_hardcode_direct"
- hardcode_minus_L="$acl_cv_hardcode_minus_L"
- # Check whether --enable-rpath was given.
-if test "${enable_rpath+set}" = set; then :
- enableval=$enable_rpath; :
-else
- enable_rpath=yes
-fi
-
-
-
-
-
-
-
-
- use_additional=yes
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
-
- eval additional_includedir=\"$includedir\"
- eval additional_libdir=\"$libdir\"
-
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
-
-# Check whether --with-libiconv-prefix was given.
-if test "${with_libiconv_prefix+set}" = set; then :
- withval=$with_libiconv_prefix;
- if test "X$withval" = "Xno"; then
- use_additional=no
- else
- if test "X$withval" = "X"; then
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
-
- eval additional_includedir=\"$includedir\"
- eval additional_libdir=\"$libdir\"
-
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- else
- additional_includedir="$withval/include"
- additional_libdir="$withval/lib"
- fi
- fi
-
-fi
-
-
-# Check whether --with-libiconv-type was given.
-if test "${with_libiconv_type+set}" = set; then :
- withval=$with_libiconv_type; with_libiconv_type=$withval
-else
- with_libiconv_type=auto
-fi
-
- lib_type=`eval echo \$with_libiconv_type`
-
- LIBICONV=
- LTLIBICONV=
- INCICONV=
- rpathdirs=
- ltrpathdirs=
- names_already_handled=
- names_next_round='iconv '
- while test -n "$names_next_round"; do
- names_this_round="$names_next_round"
- names_next_round=
- for name in $names_this_round; do
- already_handled=
- for n in $names_already_handled; do
- if test "$n" = "$name"; then
- already_handled=yes
- break
- fi
- done
- if test -z "$already_handled"; then
- names_already_handled="$names_already_handled $name"
- uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
- eval value=\"\$HAVE_LIB$uppername\"
- if test -n "$value"; then
- if test "$value" = yes; then
- eval value=\"\$LIB$uppername\"
- test -z "$value" || LIBICONV="${LIBICONV}${LIBICONV:+ }$value"
- eval value=\"\$LTLIB$uppername\"
- test -z "$value" || LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$value"
- else
- :
- fi
- else
- found_dir=
- found_la=
- found_so=
- found_a=
- if test $use_additional = yes; then
- if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext" && test x$lib_type != xstatic; then
- found_dir="$additional_libdir"
- found_so="$additional_libdir/lib$name.$shlibext"
- if test -f "$additional_libdir/lib$name.la"; then
- found_la="$additional_libdir/lib$name.la"
- fi
- elif test x$lib_type != xshared; then
- if test -f "$additional_libdir/lib$name.$libext"; then
- found_dir="$additional_libdir"
- found_a="$additional_libdir/lib$name.$libext"
- if test -f "$additional_libdir/lib$name.la"; then
- found_la="$additional_libdir/lib$name.la"
- fi
- fi
- fi
- fi
- if test "X$found_dir" = "X"; then
- for x in $LDFLAGS $LTLIBICONV; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- case "$x" in
- -L*)
- dir=`echo "X$x" | sed -e 's/^X-L//'`
- if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext" && test x$lib_type != xstatic; then
- found_dir="$dir"
- found_so="$dir/lib$name.$shlibext"
- if test -f "$dir/lib$name.la"; then
- found_la="$dir/lib$name.la"
- fi
- elif test x$lib_type != xshared; then
- if test -f "$dir/lib$name.$libext"; then
- found_dir="$dir"
- found_a="$dir/lib$name.$libext"
- if test -f "$dir/lib$name.la"; then
- found_la="$dir/lib$name.la"
- fi
- fi
- fi
- ;;
- esac
- if test "X$found_dir" != "X"; then
- break
- fi
- done
- fi
- if test "X$found_dir" != "X"; then
- LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$found_dir -l$name"
- if test "X$found_so" != "X"; then
- if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
- else
- haveit=
- for x in $ltrpathdirs; do
- if test "X$x" = "X$found_dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- ltrpathdirs="$ltrpathdirs $found_dir"
- fi
- if test "$hardcode_direct" = yes; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
- else
- if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
- haveit=
- for x in $rpathdirs; do
- if test "X$x" = "X$found_dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- rpathdirs="$rpathdirs $found_dir"
- fi
- else
- haveit=
- for x in $LDFLAGS $LIBICONV; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-L$found_dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir"
- fi
- if test "$hardcode_minus_L" != no; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
- else
- LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name"
- fi
- fi
- fi
- fi
- else
- if test "X$found_a" != "X"; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }$found_a"
- else
- LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir -l$name"
- fi
- fi
- additional_includedir=
- case "$found_dir" in
- */lib | */lib/)
- basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
- additional_includedir="$basedir/include"
- ;;
- esac
- if test "X$additional_includedir" != "X"; then
- if test "X$additional_includedir" != "X/usr/include"; then
- haveit=
- if test "X$additional_includedir" = "X/usr/local/include"; then
- if test -n "$GCC"; then
- case $host_os in
- linux*) haveit=yes;;
- esac
- fi
- fi
- if test -z "$haveit"; then
- for x in $CPPFLAGS $INCICONV; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-I$additional_includedir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- if test -d "$additional_includedir"; then
- INCICONV="${INCICONV}${INCICONV:+ }-I$additional_includedir"
- fi
- fi
- fi
- fi
- fi
- if test -n "$found_la"; then
- save_libdir="$libdir"
- case "$found_la" in
- */* | *\\*) . "$found_la" ;;
- *) . "./$found_la" ;;
- esac
- libdir="$save_libdir"
- for dep in $dependency_libs; do
- case "$dep" in
- -L*)
- additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
- if test "X$additional_libdir" != "X/usr/lib"; then
- haveit=
- if test "X$additional_libdir" = "X/usr/local/lib"; then
- if test -n "$GCC"; then
- case $host_os in
- linux*) haveit=yes;;
- esac
- fi
- fi
- if test -z "$haveit"; then
- haveit=
- for x in $LDFLAGS $LIBICONV; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-L$additional_libdir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- if test -d "$additional_libdir"; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }-L$additional_libdir"
- fi
- fi
- haveit=
- for x in $LDFLAGS $LTLIBICONV; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-L$additional_libdir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- if test -d "$additional_libdir"; then
- LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$additional_libdir"
- fi
- fi
- fi
- fi
- ;;
- -R*)
- dir=`echo "X$dep" | sed -e 's/^X-R//'`
- if test "$enable_rpath" != no; then
- haveit=
- for x in $rpathdirs; do
- if test "X$x" = "X$dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- rpathdirs="$rpathdirs $dir"
- fi
- haveit=
- for x in $ltrpathdirs; do
- if test "X$x" = "X$dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- ltrpathdirs="$ltrpathdirs $dir"
- fi
- fi
- ;;
- -l*)
- names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
- ;;
- *.la)
- names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
- ;;
- *)
- LIBICONV="${LIBICONV}${LIBICONV:+ }$dep"
- LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$dep"
- ;;
- esac
- done
- fi
- else
- if test "x$lib_type" = "xauto" || test "x$lib_type" = "xshared"; then
- LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name"
- LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-l$name"
- else
- LIBICONV="${LIBICONV}${LIBICONV:+ }-l:lib$name.$libext"
- LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-l:lib$name.$libext"
- fi
- fi
- fi
- fi
- done
- done
- if test "X$rpathdirs" != "X"; then
- if test -n "$hardcode_libdir_separator"; then
- alldirs=
- for found_dir in $rpathdirs; do
- alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
- done
- acl_save_libdir="$libdir"
- libdir="$alldirs"
- eval flag=\"$hardcode_libdir_flag_spec\"
- libdir="$acl_save_libdir"
- LIBICONV="${LIBICONV}${LIBICONV:+ }$flag"
- else
- for found_dir in $rpathdirs; do
- acl_save_libdir="$libdir"
- libdir="$found_dir"
- eval flag=\"$hardcode_libdir_flag_spec\"
- libdir="$acl_save_libdir"
- LIBICONV="${LIBICONV}${LIBICONV:+ }$flag"
- done
- fi
- fi
- if test "X$ltrpathdirs" != "X"; then
- for found_dir in $ltrpathdirs; do
- LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-R$found_dir"
- done
- fi
-
-
-
-
-
-if test -f ../gettext/uninstalled-config.sh; then
- relative_builddir='$(top_builddir)/../gettext'
- . ../gettext/uninstalled-config.sh
-else
- # The sister gettext directory doesn't exist and won't collect information on
- # using gettext for us. Call a bundled AM_GNU_GETTEXT.
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CFPreferencesCopyAppValue" >&5
-$as_echo_n "checking for CFPreferencesCopyAppValue... " >&6; }
-if ${gt_cv_func_CFPreferencesCopyAppValue+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- gt_save_LIBS="$LIBS"
- LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <CoreFoundation/CFPreferences.h>
-int
-main ()
-{
-CFPreferencesCopyAppValue(NULL, NULL)
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- gt_cv_func_CFPreferencesCopyAppValue=yes
-else
- gt_cv_func_CFPreferencesCopyAppValue=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LIBS="$gt_save_LIBS"
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_CFPreferencesCopyAppValue" >&5
-$as_echo "$gt_cv_func_CFPreferencesCopyAppValue" >&6; }
- if test $gt_cv_func_CFPreferencesCopyAppValue = yes; then
-
-$as_echo "#define HAVE_CFPREFERENCESCOPYAPPVALUE 1" >>confdefs.h
-
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CFLocaleCopyPreferredLanguages" >&5
-$as_echo_n "checking for CFLocaleCopyPreferredLanguages... " >&6; }
-if ${gt_cv_func_CFLocaleCopyPreferredLanguages+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- gt_save_LIBS="$LIBS"
- LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-#include <CoreFoundation/CFLocale.h>
-int
-main ()
-{
-CFLocaleCopyPreferredLanguages();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- gt_cv_func_CFLocaleCopyPreferredLanguages=yes
-else
- gt_cv_func_CFLocaleCopyPreferredLanguages=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LIBS="$gt_save_LIBS"
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_CFLocaleCopyPreferredLanguages" >&5
-$as_echo "$gt_cv_func_CFLocaleCopyPreferredLanguages" >&6; }
- if test $gt_cv_func_CFLocaleCopyPreferredLanguages = yes; then
-
-$as_echo "#define HAVE_CFLOCALECOPYPREFERREDLANGUAGES 1" >>confdefs.h
-
- fi
- INTL_MACOSX_LIBS=
- if test $gt_cv_func_CFPreferencesCopyAppValue = yes \
- || test $gt_cv_func_CFLocaleCopyPreferredLanguages = yes; then
- INTL_MACOSX_LIBS="-Wl,-framework -Wl,CoreFoundation -Wl,-framework -Wl,CoreServices"
- fi
-
-
-
-
-
-
- LIBINTL=
- LTLIBINTL=
- POSUB=
-
- case " $gt_needs " in
- *" need-formatstring-macros "*) gt_api_version=3 ;;
- *" need-ngettext "*) gt_api_version=2 ;;
- *) gt_api_version=1 ;;
- esac
- gt_func_gnugettext_libc="gt_cv_func_gnugettext${gt_api_version}_libc"
- gt_func_gnugettext_libintl="gt_cv_func_gnugettext${gt_api_version}_libintl"
-
- if test "$USE_NLS" = "yes"; then
- gt_use_preinstalled_gnugettext=no
-
-
- if test $gt_api_version -ge 3; then
- gt_revision_test_code='
-#ifndef __GNU_GETTEXT_SUPPORTED_REVISION
-#define __GNU_GETTEXT_SUPPORTED_REVISION(major) ((major) == 0 ? 0 : -1)
-#endif
-typedef int array [2 * (__GNU_GETTEXT_SUPPORTED_REVISION(0) >= 1) - 1];
-'
- else
- gt_revision_test_code=
- fi
- if test $gt_api_version -ge 2; then
- gt_expression_test_code=' + * ngettext ("", "", 0)'
- else
- gt_expression_test_code=
- fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU gettext in libc" >&5
-$as_echo_n "checking for GNU gettext in libc... " >&6; }
-if eval \${$gt_func_gnugettext_libc+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <libintl.h>
-#ifndef __GNU_GETTEXT_SUPPORTED_REVISION
-extern int _nl_msg_cat_cntr;
-extern int *_nl_domain_bindings;
-#define __GNU_GETTEXT_SYMBOL_EXPRESSION (_nl_msg_cat_cntr + *_nl_domain_bindings)
-#else
-#define __GNU_GETTEXT_SYMBOL_EXPRESSION 0
-#endif
-$gt_revision_test_code
-
-int
-main ()
-{
-
-bindtextdomain ("", "");
-return * gettext ("")$gt_expression_test_code + __GNU_GETTEXT_SYMBOL_EXPRESSION
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- eval "$gt_func_gnugettext_libc=yes"
-else
- eval "$gt_func_gnugettext_libc=no"
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-fi
-eval ac_res=\$$gt_func_gnugettext_libc
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
-
- if { eval "gt_val=\$$gt_func_gnugettext_libc"; test "$gt_val" != "yes"; }; then
-
-
-
-
-
- am_save_CPPFLAGS="$CPPFLAGS"
-
- for element in $INCICONV; do
- haveit=
- for x in $CPPFLAGS; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X$element"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
- fi
- done
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for iconv" >&5
-$as_echo_n "checking for iconv... " >&6; }
-if ${am_cv_func_iconv+:} false; then :
- $as_echo_n "(cached) " >&6
-else
-
- am_cv_func_iconv="no, consider installing GNU libiconv"
- am_cv_lib_iconv=no
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <stdlib.h>
-#include <iconv.h>
-
-int
-main ()
-{
-iconv_t cd = iconv_open("","");
- iconv(cd,NULL,NULL,NULL,NULL);
- iconv_close(cd);
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- am_cv_func_iconv=yes
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- if test "$am_cv_func_iconv" != yes; then
- am_save_LIBS="$LIBS"
- LIBS="$LIBS $LIBICONV"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <stdlib.h>
-#include <iconv.h>
-
-int
-main ()
-{
-iconv_t cd = iconv_open("","");
- iconv(cd,NULL,NULL,NULL,NULL);
- iconv_close(cd);
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- am_cv_lib_iconv=yes
- am_cv_func_iconv=yes
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- LIBS="$am_save_LIBS"
- fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv" >&5
-$as_echo "$am_cv_func_iconv" >&6; }
- if test "$am_cv_func_iconv" = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working iconv" >&5
-$as_echo_n "checking for working iconv... " >&6; }
-if ${am_cv_func_iconv_works+:} false; then :
- $as_echo_n "(cached) " >&6
-else
-
- am_save_LIBS="$LIBS"
- if test $am_cv_lib_iconv = yes; then
- LIBS="$LIBS $LIBICONV"
- fi
- am_cv_func_iconv_works=no
- for ac_iconv_const in '' 'const'; do
- if test "$cross_compiling" = yes; then :
- case "$host_os" in
- aix* | hpux*) am_cv_func_iconv_works="guessing no" ;;
- *) am_cv_func_iconv_works="guessing yes" ;;
- esac
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <iconv.h>
-#include <string.h>
-
-#ifndef ICONV_CONST
-# define ICONV_CONST $ac_iconv_const
-#endif
-
-int
-main ()
-{
-int result = 0;
- /* Test against AIX 5.1...7.2 bug: Failures are not distinguishable from
- successful returns. This is even documented in
- <https://www.ibm.com/support/knowledgecenter/ssw_aix_72/i_bostechref/iconv.html> */
- {
- iconv_t cd_utf8_to_88591 = iconv_open ("ISO8859-1", "UTF-8");
- if (cd_utf8_to_88591 != (iconv_t)(-1))
- {
- static ICONV_CONST char input[] = "\342\202\254"; /* EURO SIGN */
- char buf[10];
- ICONV_CONST char *inptr = input;
- size_t inbytesleft = strlen (input);
- char *outptr = buf;
- size_t outbytesleft = sizeof (buf);
- size_t res = iconv (cd_utf8_to_88591,
- &inptr, &inbytesleft,
- &outptr, &outbytesleft);
- if (res == 0)
- result |= 1;
- iconv_close (cd_utf8_to_88591);
- }
- }
- /* Test against Solaris 10 bug: Failures are not distinguishable from
- successful returns. */
- {
- iconv_t cd_ascii_to_88591 = iconv_open ("ISO8859-1", "646");
- if (cd_ascii_to_88591 != (iconv_t)(-1))
- {
- static ICONV_CONST char input[] = "\263";
- char buf[10];
- ICONV_CONST char *inptr = input;
- size_t inbytesleft = strlen (input);
- char *outptr = buf;
- size_t outbytesleft = sizeof (buf);
- size_t res = iconv (cd_ascii_to_88591,
- &inptr, &inbytesleft,
- &outptr, &outbytesleft);
- if (res == 0)
- result |= 2;
- iconv_close (cd_ascii_to_88591);
- }
- }
- /* Test against AIX 6.1..7.1 bug: Buffer overrun. */
- {
- iconv_t cd_88591_to_utf8 = iconv_open ("UTF-8", "ISO-8859-1");
- if (cd_88591_to_utf8 != (iconv_t)(-1))
- {
- static ICONV_CONST char input[] = "\304";
- static char buf[2] = { (char)0xDE, (char)0xAD };
- ICONV_CONST char *inptr = input;
- size_t inbytesleft = 1;
- char *outptr = buf;
- size_t outbytesleft = 1;
- size_t res = iconv (cd_88591_to_utf8,
- &inptr, &inbytesleft,
- &outptr, &outbytesleft);
- if (res != (size_t)(-1) || outptr - buf > 1 || buf[1] != (char)0xAD)
- result |= 4;
- iconv_close (cd_88591_to_utf8);
- }
- }
-#if 0 /* This bug could be worked around by the caller. */
- /* Test against HP-UX 11.11 bug: Positive return value instead of 0. */
- {
- iconv_t cd_88591_to_utf8 = iconv_open ("utf8", "iso88591");
- if (cd_88591_to_utf8 != (iconv_t)(-1))
- {
- static ICONV_CONST char input[] = "\304rger mit b\366sen B\374bchen ohne Augenma\337";
- char buf[50];
- ICONV_CONST char *inptr = input;
- size_t inbytesleft = strlen (input);
- char *outptr = buf;
- size_t outbytesleft = sizeof (buf);
- size_t res = iconv (cd_88591_to_utf8,
- &inptr, &inbytesleft,
- &outptr, &outbytesleft);
- if ((int)res > 0)
- result |= 8;
- iconv_close (cd_88591_to_utf8);
- }
- }
-#endif
- /* Test against HP-UX 11.11 bug: No converter from EUC-JP to UTF-8 is
- provided. */
- {
- /* Try standardized names. */
- iconv_t cd1 = iconv_open ("UTF-8", "EUC-JP");
- /* Try IRIX, OSF/1 names. */
- iconv_t cd2 = iconv_open ("UTF-8", "eucJP");
- /* Try AIX names. */
- iconv_t cd3 = iconv_open ("UTF-8", "IBM-eucJP");
- /* Try HP-UX names. */
- iconv_t cd4 = iconv_open ("utf8", "eucJP");
- if (cd1 == (iconv_t)(-1) && cd2 == (iconv_t)(-1)
- && cd3 == (iconv_t)(-1) && cd4 == (iconv_t)(-1))
- result |= 16;
- if (cd1 != (iconv_t)(-1))
- iconv_close (cd1);
- if (cd2 != (iconv_t)(-1))
- iconv_close (cd2);
- if (cd3 != (iconv_t)(-1))
- iconv_close (cd3);
- if (cd4 != (iconv_t)(-1))
- iconv_close (cd4);
- }
- return result;
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_run "$LINENO"; then :
- am_cv_func_iconv_works=yes
-fi
-rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
- conftest.$ac_objext conftest.beam conftest.$ac_ext
-fi
-
- test "$am_cv_func_iconv_works" = no || break
- done
- LIBS="$am_save_LIBS"
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv_works" >&5
-$as_echo "$am_cv_func_iconv_works" >&6; }
- case "$am_cv_func_iconv_works" in
- *no) am_func_iconv=no am_cv_lib_iconv=no ;;
- *) am_func_iconv=yes ;;
- esac
- else
- am_func_iconv=no am_cv_lib_iconv=no
- fi
- if test "$am_func_iconv" = yes; then
-
-$as_echo "#define HAVE_ICONV 1" >>confdefs.h
-
- fi
- if test "$am_cv_lib_iconv" = yes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libiconv" >&5
-$as_echo_n "checking how to link with libiconv... " >&6; }
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBICONV" >&5
-$as_echo "$LIBICONV" >&6; }
- else
- CPPFLAGS="$am_save_CPPFLAGS"
- LIBICONV=
- LTLIBICONV=
- fi
-
-
-
-
-
-
- use_additional=yes
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
-
- eval additional_includedir=\"$includedir\"
- eval additional_libdir=\"$libdir\"
-
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
-
-# Check whether --with-libintl-prefix was given.
-if test "${with_libintl_prefix+set}" = set; then :
- withval=$with_libintl_prefix;
- if test "X$withval" = "Xno"; then
- use_additional=no
- else
- if test "X$withval" = "X"; then
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
-
- eval additional_includedir=\"$includedir\"
- eval additional_libdir=\"$libdir\"
-
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- else
- additional_includedir="$withval/include"
- additional_libdir="$withval/lib"
- fi
- fi
-
-fi
-
-
-# Check whether --with-libintl-type was given.
-if test "${with_libintl_type+set}" = set; then :
- withval=$with_libintl_type; with_libintl_type=$withval
-else
- with_libintl_type=auto
-fi
-
- lib_type=`eval echo \$with_libintl_type`
-
- LIBINTL=
- LTLIBINTL=
- INCINTL=
- rpathdirs=
- ltrpathdirs=
- names_already_handled=
- names_next_round='intl '
- while test -n "$names_next_round"; do
- names_this_round="$names_next_round"
- names_next_round=
- for name in $names_this_round; do
- already_handled=
- for n in $names_already_handled; do
- if test "$n" = "$name"; then
- already_handled=yes
- break
- fi
- done
- if test -z "$already_handled"; then
- names_already_handled="$names_already_handled $name"
- uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'`
- eval value=\"\$HAVE_LIB$uppername\"
- if test -n "$value"; then
- if test "$value" = yes; then
- eval value=\"\$LIB$uppername\"
- test -z "$value" || LIBINTL="${LIBINTL}${LIBINTL:+ }$value"
- eval value=\"\$LTLIB$uppername\"
- test -z "$value" || LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }$value"
- else
- :
- fi
- else
- found_dir=
- found_la=
- found_so=
- found_a=
- if test $use_additional = yes; then
- if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext" && test x$lib_type != xstatic; then
- found_dir="$additional_libdir"
- found_so="$additional_libdir/lib$name.$shlibext"
- if test -f "$additional_libdir/lib$name.la"; then
- found_la="$additional_libdir/lib$name.la"
- fi
- elif test x$lib_type != xshared; then
- if test -f "$additional_libdir/lib$name.$libext"; then
- found_dir="$additional_libdir"
- found_a="$additional_libdir/lib$name.$libext"
- if test -f "$additional_libdir/lib$name.la"; then
- found_la="$additional_libdir/lib$name.la"
- fi
- fi
- fi
- fi
- if test "X$found_dir" = "X"; then
- for x in $LDFLAGS $LTLIBINTL; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- case "$x" in
- -L*)
- dir=`echo "X$x" | sed -e 's/^X-L//'`
- if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext" && test x$lib_type != xstatic; then
- found_dir="$dir"
- found_so="$dir/lib$name.$shlibext"
- if test -f "$dir/lib$name.la"; then
- found_la="$dir/lib$name.la"
- fi
- elif test x$lib_type != xshared; then
- if test -f "$dir/lib$name.$libext"; then
- found_dir="$dir"
- found_a="$dir/lib$name.$libext"
- if test -f "$dir/lib$name.la"; then
- found_la="$dir/lib$name.la"
- fi
- fi
- fi
- ;;
- esac
- if test "X$found_dir" != "X"; then
- break
- fi
- done
- fi
- if test "X$found_dir" != "X"; then
- LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-L$found_dir -l$name"
- if test "X$found_so" != "X"; then
- if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
- else
- haveit=
- for x in $ltrpathdirs; do
- if test "X$x" = "X$found_dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- ltrpathdirs="$ltrpathdirs $found_dir"
- fi
- if test "$hardcode_direct" = yes; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
- else
- if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
- haveit=
- for x in $rpathdirs; do
- if test "X$x" = "X$found_dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- rpathdirs="$rpathdirs $found_dir"
- fi
- else
- haveit=
- for x in $LDFLAGS $LIBINTL; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-L$found_dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }-L$found_dir"
- fi
- if test "$hardcode_minus_L" != no; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
- else
- LIBINTL="${LIBINTL}${LIBINTL:+ }-l$name"
- fi
- fi
- fi
- fi
- else
- if test "X$found_a" != "X"; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }$found_a"
- else
- LIBINTL="${LIBINTL}${LIBINTL:+ }-L$found_dir -l$name"
- fi
- fi
- additional_includedir=
- case "$found_dir" in
- */lib | */lib/)
- basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'`
- additional_includedir="$basedir/include"
- ;;
- esac
- if test "X$additional_includedir" != "X"; then
- if test "X$additional_includedir" != "X/usr/include"; then
- haveit=
- if test "X$additional_includedir" = "X/usr/local/include"; then
- if test -n "$GCC"; then
- case $host_os in
- linux*) haveit=yes;;
- esac
- fi
- fi
- if test -z "$haveit"; then
- for x in $CPPFLAGS $INCINTL; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-I$additional_includedir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- if test -d "$additional_includedir"; then
- INCINTL="${INCINTL}${INCINTL:+ }-I$additional_includedir"
- fi
- fi
- fi
- fi
- fi
- if test -n "$found_la"; then
- save_libdir="$libdir"
- case "$found_la" in
- */* | *\\*) . "$found_la" ;;
- *) . "./$found_la" ;;
- esac
- libdir="$save_libdir"
- for dep in $dependency_libs; do
- case "$dep" in
- -L*)
- additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
- if test "X$additional_libdir" != "X/usr/lib"; then
- haveit=
- if test "X$additional_libdir" = "X/usr/local/lib"; then
- if test -n "$GCC"; then
- case $host_os in
- linux*) haveit=yes;;
- esac
- fi
- fi
- if test -z "$haveit"; then
- haveit=
- for x in $LDFLAGS $LIBINTL; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-L$additional_libdir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- if test -d "$additional_libdir"; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }-L$additional_libdir"
- fi
- fi
- haveit=
- for x in $LDFLAGS $LTLIBINTL; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X-L$additional_libdir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- if test -d "$additional_libdir"; then
- LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-L$additional_libdir"
- fi
- fi
- fi
- fi
- ;;
- -R*)
- dir=`echo "X$dep" | sed -e 's/^X-R//'`
- if test "$enable_rpath" != no; then
- haveit=
- for x in $rpathdirs; do
- if test "X$x" = "X$dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- rpathdirs="$rpathdirs $dir"
- fi
- haveit=
- for x in $ltrpathdirs; do
- if test "X$x" = "X$dir"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- ltrpathdirs="$ltrpathdirs $dir"
- fi
- fi
- ;;
- -l*)
- names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'`
- ;;
- *.la)
- names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
- ;;
- *)
- LIBINTL="${LIBINTL}${LIBINTL:+ }$dep"
- LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }$dep"
- ;;
- esac
- done
- fi
- else
- if test "x$lib_type" = "xauto" || test "x$lib_type" = "xshared"; then
- LIBINTL="${LIBINTL}${LIBINTL:+ }-l$name"
- LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-l$name"
- else
- LIBINTL="${LIBINTL}${LIBINTL:+ }-l:lib$name.$libext"
- LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-l:lib$name.$libext"
- fi
- fi
- fi
- fi
- done
- done
- if test "X$rpathdirs" != "X"; then
- if test -n "$hardcode_libdir_separator"; then
- alldirs=
- for found_dir in $rpathdirs; do
- alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir"
- done
- acl_save_libdir="$libdir"
- libdir="$alldirs"
- eval flag=\"$hardcode_libdir_flag_spec\"
- libdir="$acl_save_libdir"
- LIBINTL="${LIBINTL}${LIBINTL:+ }$flag"
- else
- for found_dir in $rpathdirs; do
- acl_save_libdir="$libdir"
- libdir="$found_dir"
- eval flag=\"$hardcode_libdir_flag_spec\"
- libdir="$acl_save_libdir"
- LIBINTL="${LIBINTL}${LIBINTL:+ }$flag"
- done
- fi
- fi
- if test "X$ltrpathdirs" != "X"; then
- for found_dir in $ltrpathdirs; do
- LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-R$found_dir"
- done
- fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU gettext in libintl" >&5
-$as_echo_n "checking for GNU gettext in libintl... " >&6; }
-if eval \${$gt_func_gnugettext_libintl+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- gt_save_CPPFLAGS="$CPPFLAGS"
- CPPFLAGS="$CPPFLAGS $INCINTL"
- gt_save_LIBS="$LIBS"
- LIBS="$LIBS $LIBINTL"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <libintl.h>
-#ifndef __GNU_GETTEXT_SUPPORTED_REVISION
-extern int _nl_msg_cat_cntr;
-extern
-#ifdef __cplusplus
-"C"
-#endif
-const char *_nl_expand_alias (const char *);
-#define __GNU_GETTEXT_SYMBOL_EXPRESSION (_nl_msg_cat_cntr + *_nl_expand_alias (""))
-#else
-#define __GNU_GETTEXT_SYMBOL_EXPRESSION 0
-#endif
-$gt_revision_test_code
-
-int
-main ()
-{
-
-bindtextdomain ("", "");
-return * gettext ("")$gt_expression_test_code + __GNU_GETTEXT_SYMBOL_EXPRESSION
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- eval "$gt_func_gnugettext_libintl=yes"
-else
- eval "$gt_func_gnugettext_libintl=no"
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" != yes; } && test -n "$LIBICONV"; then
- LIBS="$LIBS $LIBICONV"
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <libintl.h>
-#ifndef __GNU_GETTEXT_SUPPORTED_REVISION
-extern int _nl_msg_cat_cntr;
-extern
-#ifdef __cplusplus
-"C"
-#endif
-const char *_nl_expand_alias (const char *);
-#define __GNU_GETTEXT_SYMBOL_EXPRESSION (_nl_msg_cat_cntr + *_nl_expand_alias (""))
-#else
-#define __GNU_GETTEXT_SYMBOL_EXPRESSION 0
-#endif
-$gt_revision_test_code
-
-int
-main ()
-{
-
-bindtextdomain ("", "");
-return * gettext ("")$gt_expression_test_code + __GNU_GETTEXT_SYMBOL_EXPRESSION
-
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- LIBINTL="$LIBINTL $LIBICONV"
- LTLIBINTL="$LTLIBINTL $LTLIBICONV"
- eval "$gt_func_gnugettext_libintl=yes"
-
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
- fi
- CPPFLAGS="$gt_save_CPPFLAGS"
- LIBS="$gt_save_LIBS"
-fi
-eval ac_res=\$$gt_func_gnugettext_libintl
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
-$as_echo "$ac_res" >&6; }
- fi
-
- if { eval "gt_val=\$$gt_func_gnugettext_libc"; test "$gt_val" = "yes"; } \
- || { { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; } \
- && test "$PACKAGE" != gettext-runtime \
- && test "$PACKAGE" != gettext-tools; }; then
- gt_use_preinstalled_gnugettext=yes
- else
- LIBINTL=
- LTLIBINTL=
- INCINTL=
- fi
-
-
-
- if test -n "$INTL_MACOSX_LIBS"; then
- if test "$gt_use_preinstalled_gnugettext" = "yes" \
- || test "$nls_cv_use_gnu_gettext" = "yes"; then
- LIBINTL="$LIBINTL $INTL_MACOSX_LIBS"
- LTLIBINTL="$LTLIBINTL $INTL_MACOSX_LIBS"
- fi
- fi
-
- if test "$gt_use_preinstalled_gnugettext" = "yes" \
- || test "$nls_cv_use_gnu_gettext" = "yes"; then
-
-$as_echo "#define ENABLE_NLS 1" >>confdefs.h
-
- else
- USE_NLS=no
- fi
- fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use NLS" >&5
-$as_echo_n "checking whether to use NLS... " >&6; }
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_NLS" >&5
-$as_echo "$USE_NLS" >&6; }
- if test "$USE_NLS" = "yes"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking where the gettext function comes from" >&5
-$as_echo_n "checking where the gettext function comes from... " >&6; }
- if test "$gt_use_preinstalled_gnugettext" = "yes"; then
- if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; }; then
- gt_source="external libintl"
- else
- gt_source="libc"
- fi
- else
- gt_source="included intl directory"
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_source" >&5
-$as_echo "$gt_source" >&6; }
- fi
-
- if test "$USE_NLS" = "yes"; then
-
- if test "$gt_use_preinstalled_gnugettext" = "yes"; then
- if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; }; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libintl" >&5
-$as_echo_n "checking how to link with libintl... " >&6; }
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBINTL" >&5
-$as_echo "$LIBINTL" >&6; }
-
- for element in $INCINTL; do
- haveit=
- for x in $CPPFLAGS; do
-
- acl_save_prefix="$prefix"
- prefix="$acl_final_prefix"
- acl_save_exec_prefix="$exec_prefix"
- exec_prefix="$acl_final_exec_prefix"
- eval x=\"$x\"
- exec_prefix="$acl_save_exec_prefix"
- prefix="$acl_save_prefix"
-
- if test "X$x" = "X$element"; then
- haveit=yes
- break
- fi
- done
- if test -z "$haveit"; then
- CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
- fi
- done
-
- fi
-
-
-$as_echo "#define HAVE_GETTEXT 1" >>confdefs.h
-
-
-$as_echo "#define HAVE_DCGETTEXT 1" >>confdefs.h
-
- fi
-
- POSUB=po
- fi
-
-
-
- INTLLIBS="$LIBINTL"
-
-
-
-
-
-
-fi
-
-
-
-
-
-
-
-
-
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NLS is requested" >&5
-$as_echo_n "checking whether NLS is requested... " >&6; }
-if test x"$USE_NLS" != xyes; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
-$as_echo "yes" >&6; }
-
-$as_echo "#define ENABLE_NLS 1" >>confdefs.h
-
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for catalogs to be installed" >&5
-$as_echo_n "checking for catalogs to be installed... " >&6; }
- # Look for .po and .gmo files in the source directory.
- CATALOGS=
- XLINGUAS=
- for cat in $srcdir/po/*.gmo $srcdir/po/*.po; do
- # If there aren't any .gmo files the shell will give us the
- # literal string "../path/to/srcdir/po/*.gmo" which has to be
- # weeded out.
- case "$cat" in *\**)
- continue;;
- esac
- # The quadruple backslash is collapsed to a double backslash
- # by the backticks, then collapsed again by the double quotes,
- # leaving us with one backslash in the sed expression (right
- # before the dot that mustn't act as a wildcard).
- cat=`echo $cat | sed -e "s!$srcdir/po/!!" -e "s!\\\\.po!.gmo!"`
- lang=`echo $cat | sed -e "s!\\\\.gmo!!"`
- # The user is allowed to set LINGUAS to a list of languages to
- # install catalogs for. If it's empty that means "all of them."
- if test "x$LINGUAS" = x; then
- CATALOGS="$CATALOGS $cat"
- XLINGUAS="$XLINGUAS $lang"
- else
- case "$LINGUAS" in *$lang*)
- CATALOGS="$CATALOGS $cat"
- XLINGUAS="$XLINGUAS $lang"
- ;;
- esac
- fi
- done
- LINGUAS="$XLINGUAS"
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LINGUAS" >&5
-$as_echo "$LINGUAS" >&6; }
-
-
- DATADIRNAME=share
-
- INSTOBJEXT=.mo
-
- GENCAT=gencat
-
- CATOBJEXT=.gmo
-
-fi
-
-
-
-
-# Prepare PATH_SEPARATOR.
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-
-# Find out how to test for executable files. Don't use a zero-byte file,
-# as systems may use methods other than mode bits to determine executability.
-cat >conf$$.file <<_ASEOF
-#! /bin/sh
-exit 0
-_ASEOF
-chmod +x conf$$.file
-if test -x conf$$.file >/dev/null 2>&1; then
- ac_executable_p="test -x"
-else
- ac_executable_p="test -f"
-fi
-rm -f conf$$.file
-
-# Extract the first word of "msgfmt", so it can be a program name with args.
-set dummy msgfmt; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_MSGFMT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case "$MSGFMT" in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
- ;;
- *)
- ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH; do
- IFS="$ac_save_IFS"
- test -z "$ac_dir" && ac_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
- if $ac_dir/$ac_word --statistics /dev/null >/dev/null 2>&1 &&
- (if $ac_dir/$ac_word --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- ac_cv_path_MSGFMT="$ac_dir/$ac_word$ac_exec_ext"
- break 2
- fi
- fi
- done
- done
- IFS="$ac_save_IFS"
- test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT=":"
- ;;
-esac
-fi
-MSGFMT="$ac_cv_path_MSGFMT"
-if test "$MSGFMT" != ":"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGFMT" >&5
-$as_echo "$MSGFMT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- # Extract the first word of "gmsgfmt", so it can be a program name with args.
-set dummy gmsgfmt; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_GMSGFMT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case $GMSGFMT in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
- ;;
- *)
- as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
- ac_cv_path_GMSGFMT="$as_dir/$ac_word$ac_exec_ext"
- $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
- break 2
- fi
-done
- done
-IFS=$as_save_IFS
-
- test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT"
- ;;
-esac
-fi
-GMSGFMT=$ac_cv_path_GMSGFMT
-if test -n "$GMSGFMT"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GMSGFMT" >&5
-$as_echo "$GMSGFMT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
-
-
-# Prepare PATH_SEPARATOR.
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-
-# Find out how to test for executable files. Don't use a zero-byte file,
-# as systems may use methods other than mode bits to determine executability.
-cat >conf$$.file <<_ASEOF
-#! /bin/sh
-exit 0
-_ASEOF
-chmod +x conf$$.file
-if test -x conf$$.file >/dev/null 2>&1; then
- ac_executable_p="test -x"
-else
- ac_executable_p="test -f"
-fi
-rm -f conf$$.file
-
-# Extract the first word of "xgettext", so it can be a program name with args.
-set dummy xgettext; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_XGETTEXT+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case "$XGETTEXT" in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
- ;;
- *)
- ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH; do
- IFS="$ac_save_IFS"
- test -z "$ac_dir" && ac_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
- if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >/dev/null 2>&1 &&
- (if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- ac_cv_path_XGETTEXT="$ac_dir/$ac_word$ac_exec_ext"
- break 2
- fi
- fi
- done
- done
- IFS="$ac_save_IFS"
- test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":"
- ;;
-esac
-fi
-XGETTEXT="$ac_cv_path_XGETTEXT"
-if test "$XGETTEXT" != ":"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XGETTEXT" >&5
-$as_echo "$XGETTEXT" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
- rm -f messages.po
-
-
-# Prepare PATH_SEPARATOR.
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- echo "#! /bin/sh" >conf$$.sh
- echo "exit 0" >>conf$$.sh
- chmod +x conf$$.sh
- if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
- PATH_SEPARATOR=';'
- else
- PATH_SEPARATOR=:
- fi
- rm -f conf$$.sh
-fi
-
-# Find out how to test for executable files. Don't use a zero-byte file,
-# as systems may use methods other than mode bits to determine executability.
-cat >conf$$.file <<_ASEOF
-#! /bin/sh
-exit 0
-_ASEOF
-chmod +x conf$$.file
-if test -x conf$$.file >/dev/null 2>&1; then
- ac_executable_p="test -x"
-else
- ac_executable_p="test -f"
-fi
-rm -f conf$$.file
-
-# Extract the first word of "msgmerge", so it can be a program name with args.
-set dummy msgmerge; ac_word=$2
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
-$as_echo_n "checking for $ac_word... " >&6; }
-if ${ac_cv_path_MSGMERGE+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- case "$MSGMERGE" in
- [\\/]* | ?:[\\/]*)
- ac_cv_path_MSGMERGE="$MSGMERGE" # Let the user override the test with a path.
- ;;
- *)
- ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
- for ac_dir in $PATH; do
- IFS="$ac_save_IFS"
- test -z "$ac_dir" && ac_dir=.
- for ac_exec_ext in '' $ac_executable_extensions; do
- if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
- if $ac_dir/$ac_word --update -q /dev/null /dev/null >/dev/null 2>&1; then
- ac_cv_path_MSGMERGE="$ac_dir/$ac_word$ac_exec_ext"
- break 2
- fi
- fi
- done
- done
- IFS="$ac_save_IFS"
- test -z "$ac_cv_path_MSGMERGE" && ac_cv_path_MSGMERGE=":"
- ;;
-esac
-fi
-MSGMERGE="$ac_cv_path_MSGMERGE"
-if test "$MSGMERGE" != ":"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGMERGE" >&5
-$as_echo "$MSGMERGE" >&6; }
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
-$as_echo "no" >&6; }
-fi
-
-
- if test "$GMSGFMT" != ":"; then
- if $GMSGFMT --statistics /dev/null >/dev/null 2>&1 &&
- (if $GMSGFMT --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- : ;
- else
- GMSGFMT=`echo "$GMSGFMT" | sed -e 's,^.*/,,'`
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: found $GMSGFMT program is not GNU msgfmt; ignore it" >&5
-$as_echo "found $GMSGFMT program is not GNU msgfmt; ignore it" >&6; }
- GMSGFMT=":"
- fi
- fi
-
- if test "$XGETTEXT" != ":"; then
- if $XGETTEXT --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >/dev/null 2>&1 &&
- (if $XGETTEXT --omit-header --copyright-holder= --msgid-bugs-address= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
- : ;
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: found xgettext program is not GNU xgettext; ignore it" >&5
-$as_echo "found xgettext program is not GNU xgettext; ignore it" >&6; }
- XGETTEXT=":"
- fi
- rm -f messages.po
- fi
-
- ac_config_commands="$ac_config_commands default-2"
-
-
-
-. ${srcdir}/../bfd/configure.host
-
-# Put a plausible default for CC_FOR_BUILD in Makefile.
-if test -z "$CC_FOR_BUILD"; then
- if test "x$cross_compiling" = "xno"; then
- CC_FOR_BUILD='$(CC)'
- else
- CC_FOR_BUILD=gcc
- fi
-fi
-
-# Also set EXEEXT_FOR_BUILD.
-if test "x$cross_compiling" = "xno"; then
- EXEEXT_FOR_BUILD='$(EXEEXT)'
-else
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for build system executable suffix" >&5
-$as_echo_n "checking for build system executable suffix... " >&6; }
-if ${bfd_cv_build_exeext+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- rm -f conftest*
- echo 'int main () { return 0; }' > conftest.c
- bfd_cv_build_exeext=
- ${CC_FOR_BUILD} -o conftest conftest.c 1>&5 2>&5
- for file in conftest.*; do
- case $file in
- *.c | *.o | *.obj | *.ilk | *.pdb) ;;
- *) bfd_cv_build_exeext=`echo $file | sed -e s/conftest//` ;;
- esac
- done
- rm -f conftest*
- test x"${bfd_cv_build_exeext}" = x && bfd_cv_build_exeext=no
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_build_exeext" >&5
-$as_echo "$bfd_cv_build_exeext" >&6; }
- EXEEXT_FOR_BUILD=""
- test x"${bfd_cv_build_exeext}" != xno && EXEEXT_FOR_BUILD=${bfd_cv_build_exeext}
-fi
-
-# Check whether --enable-64-bit-bfd was given.
-if test "${enable_64_bit_bfd+set}" = set; then :
- enableval=$enable_64_bit_bfd; case $enableval in #(
- yes|no) :
- ;; #(
- *) :
- as_fn_error $? "bad value ${enableval} for 64-bit-bfd option" "$LINENO" 5 ;; #(
- *) :
- ;;
-esac
-else
- enable_64_bit_bfd=no
-fi
-
-
-if test "x$enable_64_bit_bfd" = "xno"; then :
- # The cast to long int works around a bug in the HP C Compiler
-# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
-# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
-# This bug is HP SR number 8606223364.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking size of void *" >&5
-$as_echo_n "checking size of void *... " >&6; }
-if ${ac_cv_sizeof_void_p+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (void *))" "ac_cv_sizeof_void_p" "$ac_includes_default"; then :
-
-else
- if test "$ac_cv_type_void_p" = yes; then
- { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
-$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
-as_fn_error 77 "cannot compute sizeof (void *)
-See \`config.log' for more details" "$LINENO" 5; }
- else
- ac_cv_sizeof_void_p=0
- fi
-fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_void_p" >&5
-$as_echo "$ac_cv_sizeof_void_p" >&6; }
-
-
-
-cat >>confdefs.h <<_ACEOF
-#define SIZEOF_VOID_P $ac_cv_sizeof_void_p
-_ACEOF
-
-
- if test "x$ac_cv_sizeof_void_p" = "x8"; then :
- enable_64_bit_bfd=yes
-fi
-
-fi
-
- if test "x$enable_64_bit_bfd" = "xyes"; then
- ENABLE_BFD_64_BIT_TRUE=
- ENABLE_BFD_64_BIT_FALSE='#'
-else
- ENABLE_BFD_64_BIT_TRUE='#'
- ENABLE_BFD_64_BIT_FALSE=
-fi
-
-
-
-
-
-
-ac_fn_c_check_decl "$LINENO" "basename" "ac_cv_have_decl_basename" "$ac_includes_default"
-if test "x$ac_cv_have_decl_basename" = xyes; then :
- ac_have_decl=1
-else
- ac_have_decl=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define HAVE_DECL_BASENAME $ac_have_decl
-_ACEOF
-ac_fn_c_check_decl "$LINENO" "stpcpy" "ac_cv_have_decl_stpcpy" "$ac_includes_default"
-if test "x$ac_cv_have_decl_stpcpy" = xyes; then :
- ac_have_decl=1
-else
- ac_have_decl=0
-fi
-
-cat >>confdefs.h <<_ACEOF
-#define HAVE_DECL_STPCPY $ac_have_decl
-_ACEOF
-
-
-# Check if sigsetjmp is available. Using AC_CHECK_FUNCS won't do
-# since sigsetjmp might only be defined as a macro.
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for sigsetjmp" >&5
-$as_echo_n "checking for sigsetjmp... " >&6; }
-if ${gdb_cv_func_sigsetjmp+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-#include <setjmp.h>
-
-int
-main ()
-{
-sigjmp_buf env; while (! sigsetjmp (env, 1)) siglongjmp (env, 1);
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_compile "$LINENO"; then :
- bfd_cv_func_sigsetjmp=yes
-else
- bfd_cv_func_sigsetjmp=no
-fi
-rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_func_sigsetjmp" >&5
-$as_echo "$gdb_cv_func_sigsetjmp" >&6; }
-if test $bfd_cv_func_sigsetjmp = yes; then
-
-$as_echo "#define HAVE_SIGSETJMP 1" >>confdefs.h
-
-fi
-
-cgen_maint=no
-cgendir='$(srcdir)/../../cgen'
-if test -r ${srcdir}/../cgen/iformat.scm; then
- cgendir='$(srcdir)/../cgen'
-fi
-
-# Check whether --enable-cgen-maint was given.
-if test "${enable_cgen_maint+set}" = set; then :
- enableval=$enable_cgen_maint; case "${enableval}" in
- yes) cgen_maint=yes ;;
- no) cgen_maint=no ;;
- *)
- # Argument is a directory where cgen can be found. In some
- # future world cgen could be installable, but right now this
- # is not the case. Instead we assume the directory is a path
- # to the cgen source tree.
- cgen_maint=yes
- if test -r ${enableval}/iformat.scm; then
- # This looks like a cgen source tree.
- cgendir=${enableval}
- else
- as_fn_error $? "${enableval} doesn't look like a cgen source tree" "$LINENO" 5
- fi
- ;;
-esac
-fi
- if test x${cgen_maint} = xyes; then
- CGEN_MAINT_TRUE=
- CGEN_MAINT_FALSE='#'
-else
- CGEN_MAINT_TRUE='#'
- CGEN_MAINT_FALSE=
-fi
-
-
-
-using_cgen=no
-
-# Check if linker supports --as-needed and --no-as-needed options
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking linker --as-needed support" >&5
-$as_echo_n "checking linker --as-needed support... " >&6; }
-if ${bfd_cv_ld_as_needed+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- bfd_cv_ld_as_needed=no
- if $LD --help 2>/dev/null | grep as-needed > /dev/null; then
- bfd_cv_ld_as_needed=yes
- fi
-
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $bfd_cv_ld_as_needed" >&5
-$as_echo "$bfd_cv_ld_as_needed" >&6; }
-
-LIBM=
-case $host in
-*-*-beos* | *-*-cegcc* | *-*-cygwin* | *-*-haiku* | *-*-pw32* | *-*-darwin*)
- # These system don't have libm, or don't need it
- ;;
-*-ncr-sysv4.3*)
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _mwvalidcheckl in -lmw" >&5
-$as_echo_n "checking for _mwvalidcheckl in -lmw... " >&6; }
-if ${ac_cv_lib_mw__mwvalidcheckl+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-lmw $LIBS"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char _mwvalidcheckl ();
-int
-main ()
-{
-return _mwvalidcheckl ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_lib_mw__mwvalidcheckl=yes
-else
- ac_cv_lib_mw__mwvalidcheckl=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_mw__mwvalidcheckl" >&5
-$as_echo "$ac_cv_lib_mw__mwvalidcheckl" >&6; }
-if test "x$ac_cv_lib_mw__mwvalidcheckl" = xyes; then :
- LIBM="-lmw"
-fi
-
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cos in -lm" >&5
-$as_echo_n "checking for cos in -lm... " >&6; }
-if ${ac_cv_lib_m_cos+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-lm $LIBS"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char cos ();
-int
-main ()
-{
-return cos ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_lib_m_cos=yes
-else
- ac_cv_lib_m_cos=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_cos" >&5
-$as_echo "$ac_cv_lib_m_cos" >&6; }
-if test "x$ac_cv_lib_m_cos" = xyes; then :
- LIBM="$LIBM -lm"
-fi
-
- ;;
-*)
- { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cos in -lm" >&5
-$as_echo_n "checking for cos in -lm... " >&6; }
-if ${ac_cv_lib_m_cos+:} false; then :
- $as_echo_n "(cached) " >&6
-else
- ac_check_lib_save_LIBS=$LIBS
-LIBS="-lm $LIBS"
-cat confdefs.h - <<_ACEOF >conftest.$ac_ext
-/* end confdefs.h. */
-
-/* Override any GCC internal prototype to avoid an error.
- Use char because int might match the return type of a GCC
- builtin and then its argument prototype would still apply. */
-#ifdef __cplusplus
-extern "C"
-#endif
-char cos ();
-int
-main ()
-{
-return cos ();
- ;
- return 0;
-}
-_ACEOF
-if ac_fn_c_try_link "$LINENO"; then :
- ac_cv_lib_m_cos=yes
-else
- ac_cv_lib_m_cos=no
-fi
-rm -f core conftest.err conftest.$ac_objext \
- conftest$ac_exeext conftest.$ac_ext
-LIBS=$ac_check_lib_save_LIBS
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_cos" >&5
-$as_echo "$ac_cv_lib_m_cos" >&6; }
-if test "x$ac_cv_lib_m_cos" = xyes; then :
- LIBM="-lm"
-fi
-
- ;;
-esac
-
-
-
-#Libs for generator progs
-if test "x$cross_compiling" = "xno"; then
- BUILD_LIBS=../libiberty/libiberty.a
- BUILD_LIB_DEPS=$BUILD_LIBS
-else
- # if cross-compiling, assume that the system provides -liberty
- # and that the version is compatible with new headers.
- BUILD_LIBS=-liberty
- BUILD_LIB_DEPS=
-fi
-BUILD_LIBS="$BUILD_LIBS $LIBINTL"
-BUILD_LIB_DEPS="$BUILD_LIB_DEPS $LIBINTL_DEP"
-
-
-
-
-# Horrible hacks to build DLLs on Windows and a shared library elsewhere.
-SHARED_LDFLAGS=
-SHARED_LIBADD=
-SHARED_DEPENDENCIES=
-if test "$enable_shared" = "yes"; then
-# When building a shared libopcodes, link against the pic version of libiberty
-# so that apps that use libopcodes won't need libiberty just to satisfy any
-# libopcodes references.
-# We can't do that if a pic libiberty is unavailable since including non-pic
-# code would insert text relocations into libopcodes.
-# Note that linking against libbfd as we do here, which is itself linked
-# against libiberty, may not satisfy all the libopcodes libiberty references
-# since libbfd may not pull in the entirety of libiberty.
-# Also, jam libintl into the right place in all of this: after libiberty,
-# which uses it, but before -lcygwin, which it uses.
- x=`sed -n -e 's/^[ ]*PICFLAG[ ]*=[ ]*//p' < ../libiberty/Makefile | sed -n '$p'`
- if test -n "$x"; then
- SHARED_LIBADD="-L`pwd`/../libiberty/pic -liberty"
- fi
-fi
-
-SHARED_LIBADD="$SHARED_LIBADD $LTLIBINTL"
-
-if test "$enable_shared" = "yes"; then
- case "${host}" in
- *-*-cygwin*)
- SHARED_LDFLAGS="-no-undefined"
- SHARED_LIBADD="-L`pwd`/../bfd -lbfd -L`pwd`/../libiberty -liberty $SHARED_LIBADD"
- ;;
- *)
- SHARED_LIBADD="../bfd/libbfd.la ${SHARED_LIBADD}"
- SHARED_DEPENDENCIES="../bfd/libbfd.la"
- ;;
- esac
-
- if test -n "$SHARED_LIBADD"; then
- if test -n "$LIBM"; then
- if test x"$bfd_cv_ld_as_needed" = xyes; then
- # Link against libm only when needed. Put -lc, -lm inside -Wl
- # to stop libtool reordering these options.
- SHARED_LIBADD="$SHARED_LIBADD -Wl,-lc,--as-needed,`echo $LIBM | sed 's/ /,/g'`,--no-as-needed"
- else
- SHARED_LIBADD="$SHARED_LIBADD $LIBM"
- fi
- fi
- fi
-fi
-
-
-
-
-# target-specific stuff:
-
-# Canonicalize the secondary target names.
-if test -n "$enable_targets" ; then
- for targ in `echo $enable_targets | sed 's/,/ /g'`
- do
- result=`$ac_config_sub $targ 2>/dev/null`
- if test -n "$result" ; then
- canon_targets="$canon_targets $result"
- else
- # Allow targets that config.sub doesn't recognize, like "all".
- canon_targets="$canon_targets $targ"
- fi
- done
-fi
-
-all_targets=false
-selarchs=
-for targ in $target $canon_targets
-do
- if test "x$targ" = "xall" ; then
- all_targets=true
- else
- . $srcdir/../bfd/config.bfd
- selarchs="$selarchs $targ_archs"
- fi
-done
-
-# Utility var, documents generic cgen support files.
-
-cgen_files="cgen-opc.lo cgen-asm.lo cgen-dis.lo cgen-bitset.lo"
-
-# We don't do any links based on the target system, just makefile config.
-
-if test x${all_targets} = xfalse ; then
-
- # Target architecture .o files.
- ta=
-
- for arch in $selarchs
- do
- ad=`echo $arch | sed -e s/bfd_//g -e s/_arch//g`
- archdefs="$archdefs -DARCH_$ad"
- case "$arch" in
- bfd_aarch64_arch) ta="$ta aarch64-asm.lo aarch64-dis.lo aarch64-opc.lo aarch64-asm-2.lo aarch64-dis-2.lo aarch64-opc-2.lo" ;;
- bfd_alpha_arch) ta="$ta alpha-dis.lo alpha-opc.lo" ;;
- bfd_amdgcn_arch) ;;
- bfd_arc_arch) ta="$ta arc-dis.lo arc-opc.lo arc-ext.lo" ;;
- bfd_arm_arch) ta="$ta arm-dis.lo" ;;
- bfd_avr_arch) ta="$ta avr-dis.lo" ;;
- bfd_bfin_arch) ta="$ta bfin-dis.lo" ;;
- bfd_cr16_arch) ta="$ta cr16-dis.lo cr16-opc.lo" ;;
- bfd_cris_arch) ta="$ta cris-desc.lo cris-dis.lo cris-opc.lo cgen-bitset.lo" ;;
- bfd_crx_arch) ta="$ta crx-dis.lo crx-opc.lo" ;;
- bfd_csky_arch) ta="$ta csky-dis.lo" ;;
- bfd_d10v_arch) ta="$ta d10v-dis.lo d10v-opc.lo" ;;
- bfd_d30v_arch) ta="$ta d30v-dis.lo d30v-opc.lo" ;;
- bfd_dlx_arch) ta="$ta dlx-dis.lo" ;;
- bfd_fr30_arch) ta="$ta fr30-asm.lo fr30-desc.lo fr30-dis.lo fr30-ibld.lo fr30-opc.lo" using_cgen=yes ;;
- bfd_frv_arch) ta="$ta frv-asm.lo frv-desc.lo frv-dis.lo frv-ibld.lo frv-opc.lo" using_cgen=yes ;;
- bfd_ft32_arch) ta="$ta ft32-opc.lo ft32-dis.lo" ;;
- bfd_moxie_arch) ta="$ta moxie-dis.lo moxie-opc.lo" ;;
- bfd_h8300_arch) ta="$ta h8300-dis.lo" ;;
- bfd_hppa_arch) ta="$ta hppa-dis.lo" ;;
- bfd_i386_arch|bfd_iamcu_arch)
- ta="$ta i386-dis.lo" ;;
- bfd_ia64_arch) ta="$ta ia64-dis.lo ia64-opc.lo" ;;
- bfd_ip2k_arch) ta="$ta ip2k-asm.lo ip2k-desc.lo ip2k-dis.lo ip2k-ibld.lo ip2k-opc.lo" using_cgen=yes ;;
- bfd_epiphany_arch) ta="$ta epiphany-asm.lo epiphany-desc.lo epiphany-dis.lo epiphany-ibld.lo epiphany-opc.lo" using_cgen=yes ;;
- bfd_iq2000_arch) ta="$ta iq2000-asm.lo iq2000-desc.lo iq2000-dis.lo iq2000-ibld.lo iq2000-opc.lo" using_cgen=yes ;;
- bfd_kvx_arch) ta="$ta kvx-opc.lo kvx-dis.lo" ;;
- bfd_lm32_arch) ta="$ta lm32-asm.lo lm32-desc.lo lm32-dis.lo lm32-ibld.lo lm32-opc.lo lm32-opinst.lo" using_cgen=yes ;;
- bfd_m32c_arch) ta="$ta m32c-asm.lo m32c-desc.lo m32c-dis.lo m32c-ibld.lo m32c-opc.lo" using_cgen=yes ;;
- bfd_m32r_arch) ta="$ta m32r-asm.lo m32r-desc.lo m32r-dis.lo m32r-ibld.lo m32r-opc.lo m32r-opinst.lo" using_cgen=yes ;;
- bfd_m68hc11_arch) ta="$ta m68hc11-dis.lo m68hc11-opc.lo" ;;
- bfd_m68hc12_arch) ta="$ta m68hc11-dis.lo m68hc11-opc.lo" ;;
- bfd_m9s12x_arch) ta="$ta m68hc11-dis.lo m68hc11-opc.lo" ;;
- bfd_m9s12xg_arch) ta="$ta m68hc11-dis.lo m68hc11-opc.lo" ;;
- bfd_s12z_arch) ta="$ta s12z-dis.lo s12z-opc.lo" ;;
- bfd_m68k_arch) ta="$ta m68k-dis.lo m68k-opc.lo" ;;
- bfd_mcore_arch) ta="$ta mcore-dis.lo" ;;
- bfd_mep_arch) ta="$ta mep-asm.lo mep-desc.lo mep-dis.lo mep-ibld.lo mep-opc.lo" using_cgen=yes ;;
- bfd_metag_arch) ta="$ta metag-dis.lo" ;;
- bfd_microblaze_arch) ta="$ta microblaze-dis.lo" ;;
- bfd_mips_arch) ta="$ta mips-dis.lo mips-opc.lo mips16-opc.lo micromips-opc.lo" ;;
- bfd_mmix_arch) ta="$ta mmix-dis.lo mmix-opc.lo" ;;
- bfd_mn10200_arch) ta="$ta m10200-dis.lo m10200-opc.lo" ;;
- bfd_mn10300_arch) ta="$ta m10300-dis.lo m10300-opc.lo" ;;
- bfd_mt_arch) ta="$ta mt-asm.lo mt-desc.lo mt-dis.lo mt-ibld.lo mt-opc.lo" using_cgen=yes ;;
- bfd_msp430_arch) ta="$ta msp430-dis.lo msp430-decode.lo" ;;
- bfd_nds32_arch) ta="$ta nds32-asm.lo nds32-dis.lo" ;;
- bfd_nfp_arch) ta="$ta nfp-dis.lo" ;;
- bfd_nios2_arch) ta="$ta nios2-dis.lo nios2-opc.lo" ;;
- bfd_ns32k_arch) ta="$ta ns32k-dis.lo" ;;
- bfd_or1k_arch) ta="$ta or1k-asm.lo or1k-desc.lo or1k-dis.lo or1k-ibld.lo or1k-opc.lo" using_cgen=yes ;;
- bfd_pdp11_arch) ta="$ta pdp11-dis.lo pdp11-opc.lo" ;;
- bfd_pj_arch) ta="$ta pj-dis.lo pj-opc.lo" ;;
- bfd_powerpc_arch) ta="$ta ppc-dis.lo ppc-opc.lo" ;;
- bfd_powerpc_64_arch) ta="$ta ppc-dis.lo ppc-opc.lo" ;;
- bfd_pru_arch) ta="$ta pru-dis.lo pru-opc.lo" ;;
- bfd_pyramid_arch) ;;
- bfd_romp_arch) ;;
- bfd_riscv_arch) ta="$ta riscv-dis.lo riscv-opc.lo" ;;
- bfd_rs6000_arch) ta="$ta ppc-dis.lo ppc-opc.lo" ;;
- bfd_rl78_arch) ta="$ta rl78-dis.lo rl78-decode.lo";;
- bfd_rx_arch) ta="$ta rx-dis.lo rx-decode.lo";;
- bfd_s390_arch) ta="$ta s390-dis.lo s390-opc.lo" ;;
- bfd_score_arch) ta="$ta score-dis.lo score7-dis.lo" ;;
- bfd_sh_arch) ta="$ta sh-dis.lo cgen-bitset.lo" ;;
- bfd_sparc_arch) ta="$ta sparc-dis.lo sparc-opc.lo" ;;
- bfd_spu_arch) ta="$ta spu-dis.lo spu-opc.lo" ;;
- bfd_tic30_arch) ta="$ta tic30-dis.lo" ;;
- bfd_tic4x_arch) ta="$ta tic4x-dis.lo" ;;
- bfd_tic54x_arch) ta="$ta tic54x-dis.lo tic54x-opc.lo" ;;
- bfd_tic6x_arch) ta="$ta tic6x-dis.lo" ;;
- bfd_tilegx_arch) ta="$ta tilegx-dis.lo tilegx-opc.lo" ;;
- bfd_tilepro_arch) ta="$ta tilepro-dis.lo tilepro-opc.lo" ;;
- bfd_v850_arch) ta="$ta v850-opc.lo v850-dis.lo" ;;
- bfd_v850e_arch) ta="$ta v850-opc.lo v850-dis.lo" ;;
- bfd_v850ea_arch) ta="$ta v850-opc.lo v850-dis.lo" ;;
- bfd_v850_rh850_arch) ta="$ta v850-opc.lo v850-dis.lo" ;;
- bfd_vax_arch) ta="$ta vax-dis.lo" ;;
- bfd_visium_arch) ta="$ta visium-dis.lo visium-opc.lo" ;;
- bfd_wasm32_arch) ta="$ta wasm32-dis.lo" ;;
- bfd_xgate_arch) ta="$ta xgate-dis.lo xgate-opc.lo" ;;
- bfd_xstormy16_arch) ta="$ta xstormy16-asm.lo xstormy16-desc.lo xstormy16-dis.lo xstormy16-ibld.lo xstormy16-opc.lo" using_cgen=yes ;;
- bfd_xtensa_arch) ta="$ta xtensa-dis.lo" ;;
- bfd_z80_arch) ta="$ta z80-dis.lo" ;;
- bfd_z8k_arch) ta="$ta z8k-dis.lo" ;;
- bfd_bpf_arch) ta="$ta bpf-dis.lo bpf-opc.lo" ;;
- bfd_loongarch_arch) ta="$ta loongarch-dis.lo loongarch-opc.lo loongarch-coder.lo" ;;
-
- "") ;;
- *) as_fn_error $? "*** unknown target architecture $arch" "$LINENO" 5 ;;
- esac
- done
-
- if test $using_cgen = yes ; then
- ta="$ta $cgen_files"
- fi
-
- # Weed out duplicate .o files.
- f=""
- for i in $ta ; do
- case " $f " in
- *" $i "*) ;;
- *) f="$f $i" ;;
- esac
- done
- ta="$f"
-
- # And duplicate -D flags.
- f=""
- for i in $archdefs ; do
- case " $f " in
- *" $i "*) ;;
- *) f="$f $i" ;;
- esac
- done
- archdefs="$f"
-
- BFD_MACHINES="$ta"
-
-else # all_targets is true
- archdefs=-DARCH_all
- if test "$enable_64_bit_bfd" = "yes" ; then
- BFD_MACHINES='$(ALL32_MACHINES) $(ALL64_MACHINES)'
- else
- BFD_MACHINES='$(ALL32_MACHINES)'
- fi
-fi
-
-
-
-
-ac_config_files="$ac_config_files Makefile po/Makefile.in:po/Make-in"
-
-cat >confcache <<\_ACEOF
-# This file is a shell script that caches the results of configure
-# tests run on this system so they can be shared between configure
-# scripts and configure runs, see configure's option --config-cache.
-# It is not useful on other systems. If it contains results you don't
-# want to keep, you may remove or edit it.
-#
-# config.status only pays attention to the cache file if you give it
-# the --recheck option to rerun configure.
-#
-# `ac_cv_env_foo' variables (set or unset) will be overridden when
-# loading this file, other *unset* `ac_cv_foo' will be assigned the
-# following values.
-
-_ACEOF
-
-# The following way of writing the cache mishandles newlines in values,
-# but we know of no workaround that is simple, portable, and efficient.
-# So, we kill variables containing newlines.
-# Ultrix sh set writes to stderr and can't be redirected directly,
-# and sets the high bit in the cache file unless we assign to the vars.
-(
- for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
- eval ac_val=\$$ac_var
- case $ac_val in #(
- *${as_nl}*)
- case $ac_var in #(
- *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
-$as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
- esac
- case $ac_var in #(
- _ | IFS | as_nl) ;; #(
- BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
- *) { eval $ac_var=; unset $ac_var;} ;;
- esac ;;
- esac
- done
-
- (set) 2>&1 |
- case $as_nl`(ac_space=' '; set) 2>&1` in #(
- *${as_nl}ac_space=\ *)
- # `set' does not quote correctly, so add quotes: double-quote
- # substitution turns \\\\ into \\, and sed turns \\ into \.
- sed -n \
- "s/'/'\\\\''/g;
- s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
- ;; #(
- *)
- # `set' quotes correctly as required by POSIX, so do not add quotes.
- sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
- ;;
- esac |
- sort
-) |
- sed '
- /^ac_cv_env_/b end
- t clear
- :clear
- s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
- t end
- s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
- :end' >>confcache
-if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
- if test -w "$cache_file"; then
- if test "x$cache_file" != "x/dev/null"; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
-$as_echo "$as_me: updating cache $cache_file" >&6;}
- if test ! -f "$cache_file" || test -h "$cache_file"; then
- cat confcache >"$cache_file"
- else
- case $cache_file in #(
- */* | ?:*)
- mv -f confcache "$cache_file"$$ &&
- mv -f "$cache_file"$$ "$cache_file" ;; #(
- *)
- mv -f confcache "$cache_file" ;;
- esac
- fi
- fi
- else
- { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
-$as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
- fi
-fi
-rm -f confcache
-
-test "x$prefix" = xNONE && prefix=$ac_default_prefix
-# Let make expand exec_prefix.
-test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
-
-DEFS=-DHAVE_CONFIG_H
-
-ac_libobjs=
-ac_ltlibobjs=
-U=
-for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
- # 1. Remove the extension, and $U if already installed.
- ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
- ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
- # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
- # will be set to the directory where LIBOBJS objects are built.
- as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
- as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
-done
-LIBOBJS=$ac_libobjs
-
-LTLIBOBJS=$ac_ltlibobjs
-
-
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking that generated files are newer than configure" >&5
-$as_echo_n "checking that generated files are newer than configure... " >&6; }
- if test -n "$am_sleep_pid"; then
- # Hide warnings about reused PIDs.
- wait $am_sleep_pid 2>/dev/null
- fi
- { $as_echo "$as_me:${as_lineno-$LINENO}: result: done" >&5
-$as_echo "done" >&6; }
- if test -n "$EXEEXT"; then
- am__EXEEXT_TRUE=
- am__EXEEXT_FALSE='#'
-else
- am__EXEEXT_TRUE='#'
- am__EXEEXT_FALSE=
-fi
-
-if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
- as_fn_error $? "conditional \"AMDEP\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
- as_fn_error $? "conditional \"am__fastdepCC\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${MAINTAINER_MODE_TRUE}" && test -z "${MAINTAINER_MODE_FALSE}"; then
- as_fn_error $? "conditional \"MAINTAINER_MODE\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${INSTALL_LIBBFD_TRUE}" && test -z "${INSTALL_LIBBFD_FALSE}"; then
- as_fn_error $? "conditional \"INSTALL_LIBBFD\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${ENABLE_BFD_64_BIT_TRUE}" && test -z "${ENABLE_BFD_64_BIT_FALSE}"; then
- as_fn_error $? "conditional \"ENABLE_BFD_64_BIT\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-if test -z "${CGEN_MAINT_TRUE}" && test -z "${CGEN_MAINT_FALSE}"; then
- as_fn_error $? "conditional \"CGEN_MAINT\" was never defined.
-Usually this means the macro was only invoked conditionally." "$LINENO" 5
-fi
-
-: "${CONFIG_STATUS=./config.status}"
-ac_write_fail=0
-ac_clean_files_save=$ac_clean_files
-ac_clean_files="$ac_clean_files $CONFIG_STATUS"
-{ $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
-$as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
-as_write_fail=0
-cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
-#! $SHELL
-# Generated by $as_me.
-# Run this file to recreate the current configuration.
-# Compiler output produced by configure, useful for debugging
-# configure, is in config.log if it exists.
-
-debug=false
-ac_cs_recheck=false
-ac_cs_silent=false
-
-SHELL=\${CONFIG_SHELL-$SHELL}
-export SHELL
-_ASEOF
-cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
-## -------------------- ##
-## M4sh Initialization. ##
-## -------------------- ##
-
-# Be more Bourne compatible
-DUALCASE=1; export DUALCASE # for MKS sh
-if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
- emulate sh
- NULLCMD=:
- # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
- # is contrary to our usage. Disable this feature.
- alias -g '${1+"$@"}'='"$@"'
- setopt NO_GLOB_SUBST
-else
- case `(set -o) 2>/dev/null` in #(
- *posix*) :
- set -o posix ;; #(
- *) :
- ;;
-esac
-fi
-
-
-as_nl='
-'
-export as_nl
-# Printing a long string crashes Solaris 7 /usr/bin/printf.
-as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
-as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
-as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
-# Prefer a ksh shell builtin over an external printf program on Solaris,
-# but without wasting forks for bash or zsh.
-if test -z "$BASH_VERSION$ZSH_VERSION" \
- && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
- as_echo='print -r --'
- as_echo_n='print -rn --'
-elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
- as_echo='printf %s\n'
- as_echo_n='printf %s'
-else
- if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
- as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
- as_echo_n='/usr/ucb/echo -n'
- else
- as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
- as_echo_n_body='eval
- arg=$1;
- case $arg in #(
- *"$as_nl"*)
- expr "X$arg" : "X\\(.*\\)$as_nl";
- arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
- esac;
- expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
- '
- export as_echo_n_body
- as_echo_n='sh -c $as_echo_n_body as_echo'
- fi
- export as_echo_body
- as_echo='sh -c $as_echo_body as_echo'
-fi
-
-# The user is always right.
-if test "${PATH_SEPARATOR+set}" != set; then
- PATH_SEPARATOR=:
- (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
- (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
- PATH_SEPARATOR=';'
- }
-fi
-
-
-# IFS
-# We need space, tab and new line, in precisely that order. Quoting is
-# there to prevent editors from complaining about space-tab.
-# (If _AS_PATH_WALK were called with IFS unset, it would disable word
-# splitting by setting IFS to empty value.)
-IFS=" "" $as_nl"
-
-# Find who we are. Look in the path if we contain no directory separator.
-as_myself=
-case $0 in #((
- *[\\/]* ) as_myself=$0 ;;
- *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
-for as_dir in $PATH
-do
- IFS=$as_save_IFS
- test -z "$as_dir" && as_dir=.
- test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
- done
-IFS=$as_save_IFS
-
- ;;
-esac
-# We did not find ourselves, most probably we were run as `sh COMMAND'
-# in which case we are not to be found in the path.
-if test "x$as_myself" = x; then
- as_myself=$0
-fi
-if test ! -f "$as_myself"; then
- $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
- exit 1
-fi
-
-# Unset variables that we do not need and which cause bugs (e.g. in
-# pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
-# suppresses any "Segmentation fault" message there. '((' could
-# trigger a bug in pdksh 5.2.14.
-for as_var in BASH_ENV ENV MAIL MAILPATH
-do eval test x\${$as_var+set} = xset \
- && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
-done
-PS1='$ '
-PS2='> '
-PS4='+ '
-
-# NLS nuisances.
-LC_ALL=C
-export LC_ALL
-LANGUAGE=C
-export LANGUAGE
-
-# CDPATH.
-(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
-
-
-# as_fn_error STATUS ERROR [LINENO LOG_FD]
-# ----------------------------------------
-# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
-# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
-# script with STATUS, using 1 if that was 0.
-as_fn_error ()
-{
- as_status=$1; test $as_status -eq 0 && as_status=1
- if test "$4"; then
- as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
- $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
- fi
- $as_echo "$as_me: error: $2" >&2
- as_fn_exit $as_status
-} # as_fn_error
-
-
-# as_fn_set_status STATUS
-# -----------------------
-# Set $? to STATUS, without forking.
-as_fn_set_status ()
-{
- return $1
-} # as_fn_set_status
-
-# as_fn_exit STATUS
-# -----------------
-# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
-as_fn_exit ()
-{
- set +e
- as_fn_set_status $1
- exit $1
-} # as_fn_exit
-
-# as_fn_unset VAR
-# ---------------
-# Portably unset VAR.
-as_fn_unset ()
-{
- { eval $1=; unset $1;}
-}
-as_unset=as_fn_unset
-# as_fn_append VAR VALUE
-# ----------------------
-# Append the text in VALUE to the end of the definition contained in VAR. Take
-# advantage of any shell optimizations that allow amortized linear growth over
-# repeated appends, instead of the typical quadratic growth present in naive
-# implementations.
-if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
- eval 'as_fn_append ()
- {
- eval $1+=\$2
- }'
-else
- as_fn_append ()
- {
- eval $1=\$$1\$2
- }
-fi # as_fn_append
-
-# as_fn_arith ARG...
-# ------------------
-# Perform arithmetic evaluation on the ARGs, and store the result in the
-# global $as_val. Take advantage of shells that can avoid forks. The arguments
-# must be portable across $(()) and expr.
-if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
- eval 'as_fn_arith ()
- {
- as_val=$(( $* ))
- }'
-else
- as_fn_arith ()
- {
- as_val=`expr "$@" || test $? -eq 1`
- }
-fi # as_fn_arith
-
-
-if expr a : '\(a\)' >/dev/null 2>&1 &&
- test "X`expr 00001 : '.*\(...\)'`" = X001; then
- as_expr=expr
-else
- as_expr=false
-fi
-
-if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
- as_basename=basename
-else
- as_basename=false
-fi
-
-if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
- as_dirname=dirname
-else
- as_dirname=false
-fi
-
-as_me=`$as_basename -- "$0" ||
-$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
- X"$0" : 'X\(//\)$' \| \
- X"$0" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X/"$0" |
- sed '/^.*\/\([^/][^/]*\)\/*$/{
- s//\1/
- q
- }
- /^X\/\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\/\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
-
-# Avoid depending upon Character Ranges.
-as_cr_letters='abcdefghijklmnopqrstuvwxyz'
-as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
-as_cr_Letters=$as_cr_letters$as_cr_LETTERS
-as_cr_digits='0123456789'
-as_cr_alnum=$as_cr_Letters$as_cr_digits
-
-ECHO_C= ECHO_N= ECHO_T=
-case `echo -n x` in #(((((
--n*)
- case `echo 'xy\c'` in
- *c*) ECHO_T=' ';; # ECHO_T is single tab character.
- xy) ECHO_C='\c';;
- *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
- ECHO_T=' ';;
- esac;;
-*)
- ECHO_N='-n';;
-esac
-
-rm -f conf$$ conf$$.exe conf$$.file
-if test -d conf$$.dir; then
- rm -f conf$$.dir/conf$$.file
-else
- rm -f conf$$.dir
- mkdir conf$$.dir 2>/dev/null
-fi
-if (echo >conf$$.file) 2>/dev/null; then
- if ln -s conf$$.file conf$$ 2>/dev/null; then
- as_ln_s='ln -s'
- # ... but there are two gotchas:
- # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
- # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
- # In both cases, we have to default to `cp -pR'.
- ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
- as_ln_s='cp -pR'
- elif ln conf$$.file conf$$ 2>/dev/null; then
- as_ln_s=ln
- else
- as_ln_s='cp -pR'
- fi
-else
- as_ln_s='cp -pR'
-fi
-rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
-rmdir conf$$.dir 2>/dev/null
-
-
-# as_fn_mkdir_p
-# -------------
-# Create "$as_dir" as a directory, including parents if necessary.
-as_fn_mkdir_p ()
-{
-
- case $as_dir in #(
- -*) as_dir=./$as_dir;;
- esac
- test -d "$as_dir" || eval $as_mkdir_p || {
- as_dirs=
- while :; do
- case $as_dir in #(
- *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
- *) as_qdir=$as_dir;;
- esac
- as_dirs="'$as_qdir' $as_dirs"
- as_dir=`$as_dirname -- "$as_dir" ||
-$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$as_dir" : 'X\(//\)[^/]' \| \
- X"$as_dir" : 'X\(//\)$' \| \
- X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$as_dir" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
- test -d "$as_dir" && break
- done
- test -z "$as_dirs" || eval "mkdir $as_dirs"
- } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
-
-
-} # as_fn_mkdir_p
-if mkdir -p . 2>/dev/null; then
- as_mkdir_p='mkdir -p "$as_dir"'
-else
- test -d ./-p && rmdir ./-p
- as_mkdir_p=false
-fi
-
-
-# as_fn_executable_p FILE
-# -----------------------
-# Test if FILE is an executable regular file.
-as_fn_executable_p ()
-{
- test -f "$1" && test -x "$1"
-} # as_fn_executable_p
-as_test_x='test -x'
-as_executable_p=as_fn_executable_p
-
-# Sed expression to map a string onto a valid CPP name.
-as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
-
-# Sed expression to map a string onto a valid variable name.
-as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
-
-
-exec 6>&1
-## ----------------------------------- ##
-## Main body of $CONFIG_STATUS script. ##
-## ----------------------------------- ##
-_ASEOF
-test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
-
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-# Save the log message, to keep $0 and so on meaningful, and to
-# report actual input values of CONFIG_FILES etc. instead of their
-# values after options handling.
-ac_log="
-This file was extended by opcodes $as_me 2.43.1, which was
-generated by GNU Autoconf 2.69. Invocation command line was
-
- CONFIG_FILES = $CONFIG_FILES
- CONFIG_HEADERS = $CONFIG_HEADERS
- CONFIG_LINKS = $CONFIG_LINKS
- CONFIG_COMMANDS = $CONFIG_COMMANDS
- $ $0 $@
-
-on `(hostname || uname -n) 2>/dev/null | sed 1q`
-"
-
-_ACEOF
-
-case $ac_config_files in *"
-"*) set x $ac_config_files; shift; ac_config_files=$*;;
-esac
-
-case $ac_config_headers in *"
-"*) set x $ac_config_headers; shift; ac_config_headers=$*;;
-esac
-
-
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-# Files that config.status was made for.
-config_files="$ac_config_files"
-config_headers="$ac_config_headers"
-config_commands="$ac_config_commands"
-
-_ACEOF
-
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-ac_cs_usage="\
-\`$as_me' instantiates files and other configuration actions
-from templates according to the current configuration. Unless the files
-and actions are specified as TAGs, all are instantiated by default.
-
-Usage: $0 [OPTION]... [TAG]...
-
- -h, --help print this help, then exit
- -V, --version print version number and configuration settings, then exit
- --config print configuration, then exit
- -q, --quiet, --silent
- do not print progress messages
- -d, --debug don't remove temporary files
- --recheck update $as_me by reconfiguring in the same conditions
- --file=FILE[:TEMPLATE]
- instantiate the configuration file FILE
- --header=FILE[:TEMPLATE]
- instantiate the configuration header FILE
-
-Configuration files:
-$config_files
-
-Configuration headers:
-$config_headers
-
-Configuration commands:
-$config_commands
-
-Report bugs to the package provider."
-
-_ACEOF
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
-ac_cs_version="\\
-opcodes config.status 2.43.1
-configured by $0, generated by GNU Autoconf 2.69,
- with options \\"\$ac_cs_config\\"
-
-Copyright (C) 2012 Free Software Foundation, Inc.
-This config.status script is free software; the Free Software Foundation
-gives unlimited permission to copy, distribute and modify it."
-
-ac_pwd='$ac_pwd'
-srcdir='$srcdir'
-INSTALL='$INSTALL'
-MKDIR_P='$MKDIR_P'
-AWK='$AWK'
-test -n "\$AWK" || AWK=awk
-_ACEOF
-
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-# The default lists apply if the user does not specify any file.
-ac_need_defaults=:
-while test $# != 0
-do
- case $1 in
- --*=?*)
- ac_option=`expr "X$1" : 'X\([^=]*\)='`
- ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
- ac_shift=:
- ;;
- --*=)
- ac_option=`expr "X$1" : 'X\([^=]*\)='`
- ac_optarg=
- ac_shift=:
- ;;
- *)
- ac_option=$1
- ac_optarg=$2
- ac_shift=shift
- ;;
- esac
-
- case $ac_option in
- # Handling of the options.
- -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
- ac_cs_recheck=: ;;
- --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
- $as_echo "$ac_cs_version"; exit ;;
- --config | --confi | --conf | --con | --co | --c )
- $as_echo "$ac_cs_config"; exit ;;
- --debug | --debu | --deb | --de | --d | -d )
- debug=: ;;
- --file | --fil | --fi | --f )
- $ac_shift
- case $ac_optarg in
- *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
- '') as_fn_error $? "missing file argument" ;;
- esac
- as_fn_append CONFIG_FILES " '$ac_optarg'"
- ac_need_defaults=false;;
- --header | --heade | --head | --hea )
- $ac_shift
- case $ac_optarg in
- *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
- esac
- as_fn_append CONFIG_HEADERS " '$ac_optarg'"
- ac_need_defaults=false;;
- --he | --h)
- # Conflict between --help and --header
- as_fn_error $? "ambiguous option: \`$1'
-Try \`$0 --help' for more information.";;
- --help | --hel | -h )
- $as_echo "$ac_cs_usage"; exit ;;
- -q | -quiet | --quiet | --quie | --qui | --qu | --q \
- | -silent | --silent | --silen | --sile | --sil | --si | --s)
- ac_cs_silent=: ;;
-
- # This is an error.
- -*) as_fn_error $? "unrecognized option: \`$1'
-Try \`$0 --help' for more information." ;;
-
- *) as_fn_append ac_config_targets " $1"
- ac_need_defaults=false ;;
-
- esac
- shift
-done
-
-ac_configure_extra_args=
-
-if $ac_cs_silent; then
- exec 6>/dev/null
- ac_configure_extra_args="$ac_configure_extra_args --silent"
-fi
-
-_ACEOF
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-if \$ac_cs_recheck; then
- set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
- shift
- \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
- CONFIG_SHELL='$SHELL'
- export CONFIG_SHELL
- exec "\$@"
-fi
-
-_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-exec 5>>config.log
-{
- echo
- sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
-## Running $as_me. ##
-_ASBOX
- $as_echo "$ac_log"
-} >&5
-
-_ACEOF
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-#
-# INIT-COMMANDS
-#
-AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"
-
-
-# The HP-UX ksh and POSIX shell print the target directory to stdout
-# if CDPATH is set.
-(unset CDPATH) >/dev/null 2>&1 && unset CDPATH
-
-sed_quote_subst='$sed_quote_subst'
-double_quote_subst='$double_quote_subst'
-delay_variable_subst='$delay_variable_subst'
-enable_shared='`$ECHO "$enable_shared" | $SED "$delay_single_quote_subst"`'
-macro_version='`$ECHO "$macro_version" | $SED "$delay_single_quote_subst"`'
-macro_revision='`$ECHO "$macro_revision" | $SED "$delay_single_quote_subst"`'
-enable_static='`$ECHO "$enable_static" | $SED "$delay_single_quote_subst"`'
-pic_mode='`$ECHO "$pic_mode" | $SED "$delay_single_quote_subst"`'
-enable_fast_install='`$ECHO "$enable_fast_install" | $SED "$delay_single_quote_subst"`'
-SHELL='`$ECHO "$SHELL" | $SED "$delay_single_quote_subst"`'
-ECHO='`$ECHO "$ECHO" | $SED "$delay_single_quote_subst"`'
-host_alias='`$ECHO "$host_alias" | $SED "$delay_single_quote_subst"`'
-host='`$ECHO "$host" | $SED "$delay_single_quote_subst"`'
-host_os='`$ECHO "$host_os" | $SED "$delay_single_quote_subst"`'
-build_alias='`$ECHO "$build_alias" | $SED "$delay_single_quote_subst"`'
-build='`$ECHO "$build" | $SED "$delay_single_quote_subst"`'
-build_os='`$ECHO "$build_os" | $SED "$delay_single_quote_subst"`'
-SED='`$ECHO "$SED" | $SED "$delay_single_quote_subst"`'
-Xsed='`$ECHO "$Xsed" | $SED "$delay_single_quote_subst"`'
-GREP='`$ECHO "$GREP" | $SED "$delay_single_quote_subst"`'
-EGREP='`$ECHO "$EGREP" | $SED "$delay_single_quote_subst"`'
-FGREP='`$ECHO "$FGREP" | $SED "$delay_single_quote_subst"`'
-LD='`$ECHO "$LD" | $SED "$delay_single_quote_subst"`'
-NM='`$ECHO "$NM" | $SED "$delay_single_quote_subst"`'
-LN_S='`$ECHO "$LN_S" | $SED "$delay_single_quote_subst"`'
-max_cmd_len='`$ECHO "$max_cmd_len" | $SED "$delay_single_quote_subst"`'
-ac_objext='`$ECHO "$ac_objext" | $SED "$delay_single_quote_subst"`'
-exeext='`$ECHO "$exeext" | $SED "$delay_single_quote_subst"`'
-lt_unset='`$ECHO "$lt_unset" | $SED "$delay_single_quote_subst"`'
-lt_SP2NL='`$ECHO "$lt_SP2NL" | $SED "$delay_single_quote_subst"`'
-lt_NL2SP='`$ECHO "$lt_NL2SP" | $SED "$delay_single_quote_subst"`'
-reload_flag='`$ECHO "$reload_flag" | $SED "$delay_single_quote_subst"`'
-reload_cmds='`$ECHO "$reload_cmds" | $SED "$delay_single_quote_subst"`'
-OBJDUMP='`$ECHO "$OBJDUMP" | $SED "$delay_single_quote_subst"`'
-deplibs_check_method='`$ECHO "$deplibs_check_method" | $SED "$delay_single_quote_subst"`'
-file_magic_cmd='`$ECHO "$file_magic_cmd" | $SED "$delay_single_quote_subst"`'
-AR='`$ECHO "$AR" | $SED "$delay_single_quote_subst"`'
-AR_FLAGS='`$ECHO "$AR_FLAGS" | $SED "$delay_single_quote_subst"`'
-STRIP='`$ECHO "$STRIP" | $SED "$delay_single_quote_subst"`'
-RANLIB='`$ECHO "$RANLIB" | $SED "$delay_single_quote_subst"`'
-old_postinstall_cmds='`$ECHO "$old_postinstall_cmds" | $SED "$delay_single_quote_subst"`'
-old_postuninstall_cmds='`$ECHO "$old_postuninstall_cmds" | $SED "$delay_single_quote_subst"`'
-old_archive_cmds='`$ECHO "$old_archive_cmds" | $SED "$delay_single_quote_subst"`'
-lock_old_archive_extraction='`$ECHO "$lock_old_archive_extraction" | $SED "$delay_single_quote_subst"`'
-CC='`$ECHO "$CC" | $SED "$delay_single_quote_subst"`'
-CFLAGS='`$ECHO "$CFLAGS" | $SED "$delay_single_quote_subst"`'
-compiler='`$ECHO "$compiler" | $SED "$delay_single_quote_subst"`'
-GCC='`$ECHO "$GCC" | $SED "$delay_single_quote_subst"`'
-lt_cv_sys_global_symbol_pipe='`$ECHO "$lt_cv_sys_global_symbol_pipe" | $SED "$delay_single_quote_subst"`'
-lt_cv_sys_global_symbol_to_cdecl='`$ECHO "$lt_cv_sys_global_symbol_to_cdecl" | $SED "$delay_single_quote_subst"`'
-lt_cv_sys_global_symbol_to_c_name_address='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address" | $SED "$delay_single_quote_subst"`'
-lt_cv_sys_global_symbol_to_c_name_address_lib_prefix='`$ECHO "$lt_cv_sys_global_symbol_to_c_name_address_lib_prefix" | $SED "$delay_single_quote_subst"`'
-objdir='`$ECHO "$objdir" | $SED "$delay_single_quote_subst"`'
-MAGIC_CMD='`$ECHO "$MAGIC_CMD" | $SED "$delay_single_quote_subst"`'
-lt_prog_compiler_no_builtin_flag='`$ECHO "$lt_prog_compiler_no_builtin_flag" | $SED "$delay_single_quote_subst"`'
-lt_prog_compiler_wl='`$ECHO "$lt_prog_compiler_wl" | $SED "$delay_single_quote_subst"`'
-lt_prog_compiler_pic='`$ECHO "$lt_prog_compiler_pic" | $SED "$delay_single_quote_subst"`'
-lt_prog_compiler_static='`$ECHO "$lt_prog_compiler_static" | $SED "$delay_single_quote_subst"`'
-lt_cv_prog_compiler_c_o='`$ECHO "$lt_cv_prog_compiler_c_o" | $SED "$delay_single_quote_subst"`'
-need_locks='`$ECHO "$need_locks" | $SED "$delay_single_quote_subst"`'
-DSYMUTIL='`$ECHO "$DSYMUTIL" | $SED "$delay_single_quote_subst"`'
-NMEDIT='`$ECHO "$NMEDIT" | $SED "$delay_single_quote_subst"`'
-LIPO='`$ECHO "$LIPO" | $SED "$delay_single_quote_subst"`'
-OTOOL='`$ECHO "$OTOOL" | $SED "$delay_single_quote_subst"`'
-OTOOL64='`$ECHO "$OTOOL64" | $SED "$delay_single_quote_subst"`'
-libext='`$ECHO "$libext" | $SED "$delay_single_quote_subst"`'
-shrext_cmds='`$ECHO "$shrext_cmds" | $SED "$delay_single_quote_subst"`'
-extract_expsyms_cmds='`$ECHO "$extract_expsyms_cmds" | $SED "$delay_single_quote_subst"`'
-archive_cmds_need_lc='`$ECHO "$archive_cmds_need_lc" | $SED "$delay_single_quote_subst"`'
-enable_shared_with_static_runtimes='`$ECHO "$enable_shared_with_static_runtimes" | $SED "$delay_single_quote_subst"`'
-export_dynamic_flag_spec='`$ECHO "$export_dynamic_flag_spec" | $SED "$delay_single_quote_subst"`'
-whole_archive_flag_spec='`$ECHO "$whole_archive_flag_spec" | $SED "$delay_single_quote_subst"`'
-compiler_needs_object='`$ECHO "$compiler_needs_object" | $SED "$delay_single_quote_subst"`'
-old_archive_from_new_cmds='`$ECHO "$old_archive_from_new_cmds" | $SED "$delay_single_quote_subst"`'
-old_archive_from_expsyms_cmds='`$ECHO "$old_archive_from_expsyms_cmds" | $SED "$delay_single_quote_subst"`'
-archive_cmds='`$ECHO "$archive_cmds" | $SED "$delay_single_quote_subst"`'
-archive_expsym_cmds='`$ECHO "$archive_expsym_cmds" | $SED "$delay_single_quote_subst"`'
-module_cmds='`$ECHO "$module_cmds" | $SED "$delay_single_quote_subst"`'
-module_expsym_cmds='`$ECHO "$module_expsym_cmds" | $SED "$delay_single_quote_subst"`'
-with_gnu_ld='`$ECHO "$with_gnu_ld" | $SED "$delay_single_quote_subst"`'
-allow_undefined_flag='`$ECHO "$allow_undefined_flag" | $SED "$delay_single_quote_subst"`'
-no_undefined_flag='`$ECHO "$no_undefined_flag" | $SED "$delay_single_quote_subst"`'
-hardcode_libdir_flag_spec='`$ECHO "$hardcode_libdir_flag_spec" | $SED "$delay_single_quote_subst"`'
-hardcode_libdir_flag_spec_ld='`$ECHO "$hardcode_libdir_flag_spec_ld" | $SED "$delay_single_quote_subst"`'
-hardcode_libdir_separator='`$ECHO "$hardcode_libdir_separator" | $SED "$delay_single_quote_subst"`'
-hardcode_direct='`$ECHO "$hardcode_direct" | $SED "$delay_single_quote_subst"`'
-hardcode_direct_absolute='`$ECHO "$hardcode_direct_absolute" | $SED "$delay_single_quote_subst"`'
-hardcode_minus_L='`$ECHO "$hardcode_minus_L" | $SED "$delay_single_quote_subst"`'
-hardcode_shlibpath_var='`$ECHO "$hardcode_shlibpath_var" | $SED "$delay_single_quote_subst"`'
-hardcode_automatic='`$ECHO "$hardcode_automatic" | $SED "$delay_single_quote_subst"`'
-inherit_rpath='`$ECHO "$inherit_rpath" | $SED "$delay_single_quote_subst"`'
-link_all_deplibs='`$ECHO "$link_all_deplibs" | $SED "$delay_single_quote_subst"`'
-fix_srcfile_path='`$ECHO "$fix_srcfile_path" | $SED "$delay_single_quote_subst"`'
-always_export_symbols='`$ECHO "$always_export_symbols" | $SED "$delay_single_quote_subst"`'
-export_symbols_cmds='`$ECHO "$export_symbols_cmds" | $SED "$delay_single_quote_subst"`'
-exclude_expsyms='`$ECHO "$exclude_expsyms" | $SED "$delay_single_quote_subst"`'
-include_expsyms='`$ECHO "$include_expsyms" | $SED "$delay_single_quote_subst"`'
-prelink_cmds='`$ECHO "$prelink_cmds" | $SED "$delay_single_quote_subst"`'
-file_list_spec='`$ECHO "$file_list_spec" | $SED "$delay_single_quote_subst"`'
-variables_saved_for_relink='`$ECHO "$variables_saved_for_relink" | $SED "$delay_single_quote_subst"`'
-need_lib_prefix='`$ECHO "$need_lib_prefix" | $SED "$delay_single_quote_subst"`'
-need_version='`$ECHO "$need_version" | $SED "$delay_single_quote_subst"`'
-version_type='`$ECHO "$version_type" | $SED "$delay_single_quote_subst"`'
-runpath_var='`$ECHO "$runpath_var" | $SED "$delay_single_quote_subst"`'
-shlibpath_var='`$ECHO "$shlibpath_var" | $SED "$delay_single_quote_subst"`'
-shlibpath_overrides_runpath='`$ECHO "$shlibpath_overrides_runpath" | $SED "$delay_single_quote_subst"`'
-libname_spec='`$ECHO "$libname_spec" | $SED "$delay_single_quote_subst"`'
-library_names_spec='`$ECHO "$library_names_spec" | $SED "$delay_single_quote_subst"`'
-soname_spec='`$ECHO "$soname_spec" | $SED "$delay_single_quote_subst"`'
-install_override_mode='`$ECHO "$install_override_mode" | $SED "$delay_single_quote_subst"`'
-postinstall_cmds='`$ECHO "$postinstall_cmds" | $SED "$delay_single_quote_subst"`'
-postuninstall_cmds='`$ECHO "$postuninstall_cmds" | $SED "$delay_single_quote_subst"`'
-finish_cmds='`$ECHO "$finish_cmds" | $SED "$delay_single_quote_subst"`'
-finish_eval='`$ECHO "$finish_eval" | $SED "$delay_single_quote_subst"`'
-hardcode_into_libs='`$ECHO "$hardcode_into_libs" | $SED "$delay_single_quote_subst"`'
-sys_lib_search_path_spec='`$ECHO "$sys_lib_search_path_spec" | $SED "$delay_single_quote_subst"`'
-sys_lib_dlsearch_path_spec='`$ECHO "$sys_lib_dlsearch_path_spec" | $SED "$delay_single_quote_subst"`'
-hardcode_action='`$ECHO "$hardcode_action" | $SED "$delay_single_quote_subst"`'
-enable_dlopen='`$ECHO "$enable_dlopen" | $SED "$delay_single_quote_subst"`'
-enable_dlopen_self='`$ECHO "$enable_dlopen_self" | $SED "$delay_single_quote_subst"`'
-enable_dlopen_self_static='`$ECHO "$enable_dlopen_self_static" | $SED "$delay_single_quote_subst"`'
-old_striplib='`$ECHO "$old_striplib" | $SED "$delay_single_quote_subst"`'
-striplib='`$ECHO "$striplib" | $SED "$delay_single_quote_subst"`'
-
-LTCC='$LTCC'
-LTCFLAGS='$LTCFLAGS'
-compiler='$compiler_DEFAULT'
-
-# A function that is used when there is no print builtin or printf.
-func_fallback_echo ()
-{
- eval 'cat <<_LTECHO_EOF
-\$1
-_LTECHO_EOF'
-}
-
-# Quote evaled strings.
-for var in SHELL \
-ECHO \
-SED \
-GREP \
-EGREP \
-FGREP \
-LD \
-NM \
-LN_S \
-lt_SP2NL \
-lt_NL2SP \
-reload_flag \
-OBJDUMP \
-deplibs_check_method \
-file_magic_cmd \
-AR \
-AR_FLAGS \
-STRIP \
-RANLIB \
-CC \
-CFLAGS \
-compiler \
-lt_cv_sys_global_symbol_pipe \
-lt_cv_sys_global_symbol_to_cdecl \
-lt_cv_sys_global_symbol_to_c_name_address \
-lt_cv_sys_global_symbol_to_c_name_address_lib_prefix \
-lt_prog_compiler_no_builtin_flag \
-lt_prog_compiler_wl \
-lt_prog_compiler_pic \
-lt_prog_compiler_static \
-lt_cv_prog_compiler_c_o \
-need_locks \
-DSYMUTIL \
-NMEDIT \
-LIPO \
-OTOOL \
-OTOOL64 \
-shrext_cmds \
-export_dynamic_flag_spec \
-whole_archive_flag_spec \
-compiler_needs_object \
-with_gnu_ld \
-allow_undefined_flag \
-no_undefined_flag \
-hardcode_libdir_flag_spec \
-hardcode_libdir_flag_spec_ld \
-hardcode_libdir_separator \
-fix_srcfile_path \
-exclude_expsyms \
-include_expsyms \
-file_list_spec \
-variables_saved_for_relink \
-libname_spec \
-library_names_spec \
-soname_spec \
-install_override_mode \
-finish_eval \
-old_striplib \
-striplib; do
- case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
- *[\\\\\\\`\\"\\\$]*)
- eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED \\"\\\$sed_quote_subst\\"\\\`\\\\\\""
- ;;
- *)
- eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
- ;;
- esac
-done
-
-# Double-quote double-evaled strings.
-for var in reload_cmds \
-old_postinstall_cmds \
-old_postuninstall_cmds \
-old_archive_cmds \
-extract_expsyms_cmds \
-old_archive_from_new_cmds \
-old_archive_from_expsyms_cmds \
-archive_cmds \
-archive_expsym_cmds \
-module_cmds \
-module_expsym_cmds \
-export_symbols_cmds \
-prelink_cmds \
-postinstall_cmds \
-postuninstall_cmds \
-finish_cmds \
-sys_lib_search_path_spec \
-sys_lib_dlsearch_path_spec; do
- case \`eval \\\\\$ECHO \\\\""\\\\\$\$var"\\\\"\` in
- *[\\\\\\\`\\"\\\$]*)
- eval "lt_\$var=\\\\\\"\\\`\\\$ECHO \\"\\\$\$var\\" | \\\$SED -e \\"\\\$double_quote_subst\\" -e \\"\\\$sed_quote_subst\\" -e \\"\\\$delay_variable_subst\\"\\\`\\\\\\""
- ;;
- *)
- eval "lt_\$var=\\\\\\"\\\$\$var\\\\\\""
- ;;
- esac
-done
-
-ac_aux_dir='$ac_aux_dir'
-xsi_shell='$xsi_shell'
-lt_shell_append='$lt_shell_append'
-
-# See if we are running on zsh, and set the options which allow our
-# commands through without removal of \ escapes INIT.
-if test -n "\${ZSH_VERSION+set}" ; then
- setopt NO_GLOB_SUBST
-fi
-
-
- PACKAGE='$PACKAGE'
- VERSION='$VERSION'
- TIMESTAMP='$TIMESTAMP'
- RM='$RM'
- ofile='$ofile'
-
-
-
-# Capture the value of obsolete ALL_LINGUAS because we need it to compute
- # POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES, CATALOGS. But hide it
- # from automake.
- eval 'OBSOLETE_ALL_LINGUAS''="$ALL_LINGUAS"'
- # Capture the value of LINGUAS because we need it to compute CATALOGS.
- LINGUAS="${LINGUAS-%UNSET%}"
-
-# Capture the value of obsolete ALL_LINGUAS because we need it to compute
- # POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES, CATALOGS. But hide it
- # from automake.
- eval 'OBSOLETE_ALL_LINGUAS''="$ALL_LINGUAS"'
- # Capture the value of LINGUAS because we need it to compute CATALOGS.
- LINGUAS="${LINGUAS-%UNSET%}"
-
-
-_ACEOF
-
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-
-# Handling of arguments.
-for ac_config_target in $ac_config_targets
-do
- case $ac_config_target in
- "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
- "libtool") CONFIG_COMMANDS="$CONFIG_COMMANDS libtool" ;;
- "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h:config.in" ;;
- "default-1") CONFIG_COMMANDS="$CONFIG_COMMANDS default-1" ;;
- "default-2") CONFIG_COMMANDS="$CONFIG_COMMANDS default-2" ;;
- "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
- "po/Makefile.in") CONFIG_FILES="$CONFIG_FILES po/Makefile.in:po/Make-in" ;;
-
- *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
- esac
-done
-
-
-# If the user did not use the arguments to specify the items to instantiate,
-# then the envvar interface is used. Set only those that are not.
-# We use the long form for the default assignment because of an extremely
-# bizarre bug on SunOS 4.1.3.
-if $ac_need_defaults; then
- test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
- test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
- test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
-fi
-
-# Have a temporary directory for convenience. Make it in the build tree
-# simply because there is no reason against having it here, and in addition,
-# creating and moving files from /tmp can sometimes cause problems.
-# Hook for its removal unless debugging.
-# Note that there is a small window in which the directory will not be cleaned:
-# after its creation but before its name has been assigned to `$tmp'.
-$debug ||
-{
- tmp= ac_tmp=
- trap 'exit_status=$?
- : "${ac_tmp:=$tmp}"
- { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
-' 0
- trap 'as_fn_exit 1' 1 2 13 15
-}
-# Create a (secure) tmp directory for tmp files.
-
-{
- tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
- test -d "$tmp"
-} ||
-{
- tmp=./conf$$-$RANDOM
- (umask 077 && mkdir "$tmp")
-} || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
-ac_tmp=$tmp
-
-# Set up the scripts for CONFIG_FILES section.
-# No need to generate them if there are no CONFIG_FILES.
-# This happens for instance with `./config.status config.h'.
-if test -n "$CONFIG_FILES"; then
-
-
-ac_cr=`echo X | tr X '\015'`
-# On cygwin, bash can eat \r inside `` if the user requested igncr.
-# But we know of no other shell where ac_cr would be empty at this
-# point, so we can use a bashism as a fallback.
-if test "x$ac_cr" = x; then
- eval ac_cr=\$\'\\r\'
-fi
-ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
-if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
- ac_cs_awk_cr='\\r'
-else
- ac_cs_awk_cr=$ac_cr
-fi
-
-echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
-_ACEOF
-
-
-{
- echo "cat >conf$$subs.awk <<_ACEOF" &&
- echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
- echo "_ACEOF"
-} >conf$$subs.sh ||
- as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
-ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
-ac_delim='%!_!# '
-for ac_last_try in false false false false false :; do
- . ./conf$$subs.sh ||
- as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
-
- ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
- if test $ac_delim_n = $ac_delim_num; then
- break
- elif $ac_last_try; then
- as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
- else
- ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
- fi
-done
-rm -f conf$$subs.sh
-
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
-_ACEOF
-sed -n '
-h
-s/^/S["/; s/!.*/"]=/
-p
-g
-s/^[^!]*!//
-:repl
-t repl
-s/'"$ac_delim"'$//
-t delim
-:nl
-h
-s/\(.\{148\}\)..*/\1/
-t more1
-s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
-p
-n
-b repl
-:more1
-s/["\\]/\\&/g; s/^/"/; s/$/"\\/
-p
-g
-s/.\{148\}//
-t nl
-:delim
-h
-s/\(.\{148\}\)..*/\1/
-t more2
-s/["\\]/\\&/g; s/^/"/; s/$/"/
-p
-b
-:more2
-s/["\\]/\\&/g; s/^/"/; s/$/"\\/
-p
-g
-s/.\{148\}//
-t delim
-' <conf$$subs.awk | sed '
-/^[^""]/{
- N
- s/\n//
-}
-' >>$CONFIG_STATUS || ac_write_fail=1
-rm -f conf$$subs.awk
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-_ACAWK
-cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
- for (key in S) S_is_set[key] = 1
- FS = ""
-
-}
-{
- line = $ 0
- nfields = split(line, field, "@")
- substed = 0
- len = length(field[1])
- for (i = 2; i < nfields; i++) {
- key = field[i]
- keylen = length(key)
- if (S_is_set[key]) {
- value = S[key]
- line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
- len += length(value) + length(field[++i])
- substed = 1
- } else
- len += 1 + keylen
- }
-
- print line
-}
-
-_ACAWK
-_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
- sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
-else
- cat
-fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
- || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
-_ACEOF
-
-# VPATH may cause trouble with some makes, so we remove sole $(srcdir),
-# ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
-# trailing colons and then remove the whole line if VPATH becomes empty
-# (actually we leave an empty line to preserve line numbers).
-if test "x$srcdir" = x.; then
- ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{
-h
-s///
-s/^/:/
-s/[ ]*$/:/
-s/:\$(srcdir):/:/g
-s/:\${srcdir}:/:/g
-s/:@srcdir@:/:/g
-s/^:*//
-s/:*$//
-x
-s/\(=[ ]*\).*/\1/
-G
-s/\n//
-s/^[^=]*=[ ]*$//
-}'
-fi
-
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-fi # test -n "$CONFIG_FILES"
-
-# Set up the scripts for CONFIG_HEADERS section.
-# No need to generate them if there are no CONFIG_HEADERS.
-# This happens for instance with `./config.status Makefile'.
-if test -n "$CONFIG_HEADERS"; then
-cat >"$ac_tmp/defines.awk" <<\_ACAWK ||
-BEGIN {
-_ACEOF
-
-# Transform confdefs.h into an awk script `defines.awk', embedded as
-# here-document in config.status, that substitutes the proper values into
-# config.h.in to produce config.h.
-
-# Create a delimiter string that does not exist in confdefs.h, to ease
-# handling of long lines.
-ac_delim='%!_!# '
-for ac_last_try in false false :; do
- ac_tt=`sed -n "/$ac_delim/p" confdefs.h`
- if test -z "$ac_tt"; then
- break
- elif $ac_last_try; then
- as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
- else
- ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
- fi
-done
-
-# For the awk script, D is an array of macro values keyed by name,
-# likewise P contains macro parameters if any. Preserve backslash
-# newline sequences.
-
-ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
-sed -n '
-s/.\{148\}/&'"$ac_delim"'/g
-t rset
-:rset
-s/^[ ]*#[ ]*define[ ][ ]*/ /
-t def
-d
-:def
-s/\\$//
-t bsnl
-s/["\\]/\\&/g
-s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
-D["\1"]=" \3"/p
-s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
-d
-:bsnl
-s/["\\]/\\&/g
-s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
-D["\1"]=" \3\\\\\\n"\\/p
-t cont
-s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
-t cont
-d
-:cont
-n
-s/.\{148\}/&'"$ac_delim"'/g
-t clear
-:clear
-s/\\$//
-t bsnlc
-s/["\\]/\\&/g; s/^/"/; s/$/"/p
-d
-:bsnlc
-s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
-b cont
-' <confdefs.h | sed '
-s/'"$ac_delim"'/"\\\
-"/g' >>$CONFIG_STATUS || ac_write_fail=1
-
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
- for (key in D) D_is_set[key] = 1
- FS = ""
-}
-/^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
- line = \$ 0
- split(line, arg, " ")
- if (arg[1] == "#") {
- defundef = arg[2]
- mac1 = arg[3]
- } else {
- defundef = substr(arg[1], 2)
- mac1 = arg[2]
- }
- split(mac1, mac2, "(") #)
- macro = mac2[1]
- prefix = substr(line, 1, index(line, defundef) - 1)
- if (D_is_set[macro]) {
- # Preserve the white space surrounding the "#".
- print prefix "define", macro P[macro] D[macro]
- next
- } else {
- # Replace #undef with comments. This is necessary, for example,
- # in the case of _POSIX_SOURCE, which is predefined and required
- # on some systems where configure will not decide to define it.
- if (defundef == "undef") {
- print "/*", prefix defundef, macro, "*/"
- next
- }
- }
-}
-{ print }
-_ACAWK
-_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
- as_fn_error $? "could not setup config headers machinery" "$LINENO" 5
-fi # test -n "$CONFIG_HEADERS"
-
-
-eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS"
-shift
-for ac_tag
-do
- case $ac_tag in
- :[FHLC]) ac_mode=$ac_tag; continue;;
- esac
- case $ac_mode$ac_tag in
- :[FHL]*:*);;
- :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;;
- :[FH]-) ac_tag=-:-;;
- :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
- esac
- ac_save_IFS=$IFS
- IFS=:
- set x $ac_tag
- IFS=$ac_save_IFS
- shift
- ac_file=$1
- shift
-
- case $ac_mode in
- :L) ac_source=$1;;
- :[FH])
- ac_file_inputs=
- for ac_f
- do
- case $ac_f in
- -) ac_f="$ac_tmp/stdin";;
- *) # Look for the file first in the build tree, then in the source tree
- # (if the path is not absolute). The absolute path cannot be DOS-style,
- # because $ac_f cannot contain `:'.
- test -f "$ac_f" ||
- case $ac_f in
- [\\/$]*) false;;
- *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
- esac ||
- as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;;
- esac
- case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
- as_fn_append ac_file_inputs " '$ac_f'"
- done
-
- # Let's still pretend it is `configure' which instantiates (i.e., don't
- # use $as_me), people would be surprised to read:
- # /* config.h. Generated by config.status. */
- configure_input='Generated from '`
- $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
- `' by configure.'
- if test x"$ac_file" != x-; then
- configure_input="$ac_file. $configure_input"
- { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
-$as_echo "$as_me: creating $ac_file" >&6;}
- fi
- # Neutralize special characters interpreted by sed in replacement strings.
- case $configure_input in #(
- *\&* | *\|* | *\\* )
- ac_sed_conf_input=`$as_echo "$configure_input" |
- sed 's/[\\\\&|]/\\\\&/g'`;; #(
- *) ac_sed_conf_input=$configure_input;;
- esac
-
- case $ac_tag in
- *:-:* | *:-) cat >"$ac_tmp/stdin" \
- || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
- esac
- ;;
- esac
-
- ac_dir=`$as_dirname -- "$ac_file" ||
-$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$ac_file" : 'X\(//\)[^/]' \| \
- X"$ac_file" : 'X\(//\)$' \| \
- X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$ac_file" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
- as_dir="$ac_dir"; as_fn_mkdir_p
- ac_builddir=.
-
-case "$ac_dir" in
-.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
-*)
- ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
- # A ".." for each directory in $ac_dir_suffix.
- ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
- case $ac_top_builddir_sub in
- "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
- *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
- esac ;;
-esac
-ac_abs_top_builddir=$ac_pwd
-ac_abs_builddir=$ac_pwd$ac_dir_suffix
-# for backward compatibility:
-ac_top_builddir=$ac_top_build_prefix
-
-case $srcdir in
- .) # We are building in place.
- ac_srcdir=.
- ac_top_srcdir=$ac_top_builddir_sub
- ac_abs_top_srcdir=$ac_pwd ;;
- [\\/]* | ?:[\\/]* ) # Absolute name.
- ac_srcdir=$srcdir$ac_dir_suffix;
- ac_top_srcdir=$srcdir
- ac_abs_top_srcdir=$srcdir ;;
- *) # Relative name.
- ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
- ac_top_srcdir=$ac_top_build_prefix$srcdir
- ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
-esac
-ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
-
-
- case $ac_mode in
- :F)
- #
- # CONFIG_FILE
- #
-
- case $INSTALL in
- [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
- *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
- esac
- ac_MKDIR_P=$MKDIR_P
- case $MKDIR_P in
- [\\/$]* | ?:[\\/]* ) ;;
- */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
- esac
-_ACEOF
-
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-# If the template does not know about datarootdir, expand it.
-# FIXME: This hack should be removed a few years after 2.60.
-ac_datarootdir_hack=; ac_datarootdir_seen=
-ac_sed_dataroot='
-/datarootdir/ {
- p
- q
-}
-/@datadir@/p
-/@docdir@/p
-/@infodir@/p
-/@localedir@/p
-/@mandir@/p'
-case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
-*datarootdir*) ac_datarootdir_seen=yes;;
-*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
-$as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
-_ACEOF
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
- ac_datarootdir_hack='
- s&@datadir@&$datadir&g
- s&@docdir@&$docdir&g
- s&@infodir@&$infodir&g
- s&@localedir@&$localedir&g
- s&@mandir@&$mandir&g
- s&\\\${datarootdir}&$datarootdir&g' ;;
-esac
-_ACEOF
-
-# Neutralize VPATH when `$srcdir' = `.'.
-# Shell code in configure.ac might set extrasub.
-# FIXME: do we really want to maintain this feature?
-cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
-ac_sed_extra="$ac_vpsub
-$extrasub
-_ACEOF
-cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
-:t
-/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
-s|@configure_input@|$ac_sed_conf_input|;t t
-s&@top_builddir@&$ac_top_builddir_sub&;t t
-s&@top_build_prefix@&$ac_top_build_prefix&;t t
-s&@srcdir@&$ac_srcdir&;t t
-s&@abs_srcdir@&$ac_abs_srcdir&;t t
-s&@top_srcdir@&$ac_top_srcdir&;t t
-s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
-s&@builddir@&$ac_builddir&;t t
-s&@abs_builddir@&$ac_abs_builddir&;t t
-s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
-s&@INSTALL@&$ac_INSTALL&;t t
-s&@MKDIR_P@&$ac_MKDIR_P&;t t
-$ac_datarootdir_hack
-"
-eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \
- >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
-
-test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
- { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
- { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \
- "$ac_tmp/out"`; test -z "$ac_out"; } &&
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
-which seems to be undefined. Please make sure it is defined" >&5
-$as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
-which seems to be undefined. Please make sure it is defined" >&2;}
-
- rm -f "$ac_tmp/stdin"
- case $ac_file in
- -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
- *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
- esac \
- || as_fn_error $? "could not create $ac_file" "$LINENO" 5
- ;;
- :H)
- #
- # CONFIG_HEADER
- #
- if test x"$ac_file" != x-; then
- {
- $as_echo "/* $configure_input */" \
- && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs"
- } >"$ac_tmp/config.h" \
- || as_fn_error $? "could not create $ac_file" "$LINENO" 5
- if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
-$as_echo "$as_me: $ac_file is unchanged" >&6;}
- else
- rm -f "$ac_file"
- mv "$ac_tmp/config.h" "$ac_file" \
- || as_fn_error $? "could not create $ac_file" "$LINENO" 5
- fi
- else
- $as_echo "/* $configure_input */" \
- && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \
- || as_fn_error $? "could not create -" "$LINENO" 5
- fi
-# Compute "$ac_file"'s index in $config_headers.
-_am_arg="$ac_file"
-_am_stamp_count=1
-for _am_header in $config_headers :; do
- case $_am_header in
- $_am_arg | $_am_arg:* )
- break ;;
- * )
- _am_stamp_count=`expr $_am_stamp_count + 1` ;;
- esac
-done
-echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" ||
-$as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$_am_arg" : 'X\(//\)[^/]' \| \
- X"$_am_arg" : 'X\(//\)$' \| \
- X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$_am_arg" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`/stamp-h$_am_stamp_count
- ;;
-
- :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
-$as_echo "$as_me: executing $ac_file commands" >&6;}
- ;;
- esac
-
-
- case $ac_file$ac_mode in
- "depfiles":C) test x"$AMDEP_TRUE" != x"" || {
- # Older Autoconf quotes --file arguments for eval, but not when files
- # are listed without --file. Let's play safe and only enable the eval
- # if we detect the quoting.
- case $CONFIG_FILES in
- *\'*) eval set x "$CONFIG_FILES" ;;
- *) set x $CONFIG_FILES ;;
- esac
- shift
- for mf
- do
- # Strip MF so we end up with the name of the file.
- mf=`echo "$mf" | sed -e 's/:.*$//'`
- # Check whether this is an Automake generated Makefile or not.
- # We used to match only the files named 'Makefile.in', but
- # some people rename them; so instead we look at the file content.
- # Grep'ing the first line is not enough: some people post-process
- # each Makefile.in and add a new line on top of each file to say so.
- # Grep'ing the whole file is not good either: AIX grep has a line
- # limit of 2048, but all sed's we know have understand at least 4000.
- if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
- dirpart=`$as_dirname -- "$mf" ||
-$as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$mf" : 'X\(//\)[^/]' \| \
- X"$mf" : 'X\(//\)$' \| \
- X"$mf" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$mf" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
- else
- continue
- fi
- # Extract the definition of DEPDIR, am__include, and am__quote
- # from the Makefile without running 'make'.
- DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
- test -z "$DEPDIR" && continue
- am__include=`sed -n 's/^am__include = //p' < "$mf"`
- test -z "$am__include" && continue
- am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
- # Find all dependency output files, they are included files with
- # $(DEPDIR) in their names. We invoke sed twice because it is the
- # simplest approach to changing $(DEPDIR) to its actual value in the
- # expansion.
- for file in `sed -n "
- s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
- sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g'`; do
- # Make sure the directory exists.
- test -f "$dirpart/$file" && continue
- fdir=`$as_dirname -- "$file" ||
-$as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
- X"$file" : 'X\(//\)[^/]' \| \
- X"$file" : 'X\(//\)$' \| \
- X"$file" : 'X\(/\)' \| . 2>/dev/null ||
-$as_echo X"$file" |
- sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
- s//\1/
- q
- }
- /^X\(\/\/\)[^/].*/{
- s//\1/
- q
- }
- /^X\(\/\/\)$/{
- s//\1/
- q
- }
- /^X\(\/\).*/{
- s//\1/
- q
- }
- s/.*/./; q'`
- as_dir=$dirpart/$fdir; as_fn_mkdir_p
- # echo "creating $dirpart/$file"
- echo '# dummy' > "$dirpart/$file"
- done
- done
-}
- ;;
- "libtool":C)
-
- # See if we are running on zsh, and set the options which allow our
- # commands through without removal of \ escapes.
- if test -n "${ZSH_VERSION+set}" ; then
- setopt NO_GLOB_SUBST
- fi
-
- cfgfile="${ofile}T"
- trap "$RM \"$cfgfile\"; exit 1" 1 2 15
- $RM "$cfgfile"
-
- cat <<_LT_EOF >> "$cfgfile"
-#! $SHELL
-
-# `$ECHO "$ofile" | sed 's%^.*/%%'` - Provide generalized library-building support services.
-# Generated automatically by $as_me ($PACKAGE$TIMESTAMP) $VERSION
-# Libtool was configured on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
-# NOTE: Changes made to this file will be lost: look at ltmain.sh.
-#
-# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005,
-# 2006, 2007, 2008, 2009 Free Software Foundation, Inc.
-# Written by Gordon Matzigkeit, 1996
-#
-# This file is part of GNU Libtool.
-#
-# GNU Libtool is free software; you can redistribute it and/or
-# modify it under the terms of the GNU General Public License as
-# published by the Free Software Foundation; either version 2 of
-# the License, or (at your option) any later version.
-#
-# As a special exception to the GNU General Public License,
-# if you distribute this file as part of a program or library that
-# is built using GNU Libtool, you may include this file under the
-# same distribution terms that you use for the rest of that program.
-#
-# GNU Libtool is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with GNU Libtool; see the file COPYING. If not, a copy
-# can be downloaded from http://www.gnu.org/licenses/gpl.html, or
-# obtained by writing to the Free Software Foundation, Inc.,
-# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
-
-
-# The names of the tagged configurations supported by this script.
-available_tags=""
-
-# ### BEGIN LIBTOOL CONFIG
-
-# Whether or not to build shared libraries.
-build_libtool_libs=$enable_shared
-
-# Which release of libtool.m4 was used?
-macro_version=$macro_version
-macro_revision=$macro_revision
-
-# Whether or not to build static libraries.
-build_old_libs=$enable_static
-
-# What type of objects to build.
-pic_mode=$pic_mode
-
-# Whether or not to optimize for fast installation.
-fast_install=$enable_fast_install
-
-# Shell to use when invoking shell scripts.
-SHELL=$lt_SHELL
-
-# An echo program that protects backslashes.
-ECHO=$lt_ECHO
-
-# The host system.
-host_alias=$host_alias
-host=$host
-host_os=$host_os
-
-# The build system.
-build_alias=$build_alias
-build=$build
-build_os=$build_os
-
-# A sed program that does not truncate output.
-SED=$lt_SED
-
-# Sed that helps us avoid accidentally triggering echo(1) options like -n.
-Xsed="\$SED -e 1s/^X//"
-
-# A grep program that handles long lines.
-GREP=$lt_GREP
-
-# An ERE matcher.
-EGREP=$lt_EGREP
-
-# A literal string matcher.
-FGREP=$lt_FGREP
-
-# A BSD- or MS-compatible name lister.
-NM=$lt_NM
-
-# Whether we need soft or hard links.
-LN_S=$lt_LN_S
-
-# What is the maximum length of a command?
-max_cmd_len=$max_cmd_len
-
-# Object file suffix (normally "o").
-objext=$ac_objext
-
-# Executable file suffix (normally "").
-exeext=$exeext
-
-# whether the shell understands "unset".
-lt_unset=$lt_unset
-
-# turn spaces into newlines.
-SP2NL=$lt_lt_SP2NL
-
-# turn newlines into spaces.
-NL2SP=$lt_lt_NL2SP
-
-# An object symbol dumper.
-OBJDUMP=$lt_OBJDUMP
-
-# Method to check whether dependent libraries are shared objects.
-deplibs_check_method=$lt_deplibs_check_method
-
-# Command to use when deplibs_check_method == "file_magic".
-file_magic_cmd=$lt_file_magic_cmd
-
-# The archiver.
-AR=$lt_AR
-AR_FLAGS=$lt_AR_FLAGS
-
-# A symbol stripping program.
-STRIP=$lt_STRIP
-
-# Commands used to install an old-style archive.
-RANLIB=$lt_RANLIB
-old_postinstall_cmds=$lt_old_postinstall_cmds
-old_postuninstall_cmds=$lt_old_postuninstall_cmds
-
-# Whether to use a lock for old archive extraction.
-lock_old_archive_extraction=$lock_old_archive_extraction
-
-# A C compiler.
-LTCC=$lt_CC
-
-# LTCC compiler flags.
-LTCFLAGS=$lt_CFLAGS
-
-# Take the output of nm and produce a listing of raw symbols and C names.
-global_symbol_pipe=$lt_lt_cv_sys_global_symbol_pipe
-
-# Transform the output of nm in a proper C declaration.
-global_symbol_to_cdecl=$lt_lt_cv_sys_global_symbol_to_cdecl
-
-# Transform the output of nm in a C name address pair.
-global_symbol_to_c_name_address=$lt_lt_cv_sys_global_symbol_to_c_name_address
-
-# Transform the output of nm in a C name address pair when lib prefix is needed.
-global_symbol_to_c_name_address_lib_prefix=$lt_lt_cv_sys_global_symbol_to_c_name_address_lib_prefix
-
-# The name of the directory that contains temporary libtool files.
-objdir=$objdir
-
-# Used to examine libraries when file_magic_cmd begins with "file".
-MAGIC_CMD=$MAGIC_CMD
-
-# Must we lock files when doing compilation?
-need_locks=$lt_need_locks
-
-# Tool to manipulate archived DWARF debug symbol files on Mac OS X.
-DSYMUTIL=$lt_DSYMUTIL
-
-# Tool to change global to local symbols on Mac OS X.
-NMEDIT=$lt_NMEDIT
-
-# Tool to manipulate fat objects and archives on Mac OS X.
-LIPO=$lt_LIPO
-
-# ldd/readelf like tool for Mach-O binaries on Mac OS X.
-OTOOL=$lt_OTOOL
-
-# ldd/readelf like tool for 64 bit Mach-O binaries on Mac OS X 10.4.
-OTOOL64=$lt_OTOOL64
-
-# Old archive suffix (normally "a").
-libext=$libext
-
-# Shared library suffix (normally ".so").
-shrext_cmds=$lt_shrext_cmds
-
-# The commands to extract the exported symbol list from a shared archive.
-extract_expsyms_cmds=$lt_extract_expsyms_cmds
-
-# Variables whose values should be saved in libtool wrapper scripts and
-# restored at link time.
-variables_saved_for_relink=$lt_variables_saved_for_relink
-
-# Do we need the "lib" prefix for modules?
-need_lib_prefix=$need_lib_prefix
-
-# Do we need a version for libraries?
-need_version=$need_version
-
-# Library versioning type.
-version_type=$version_type
-
-# Shared library runtime path variable.
-runpath_var=$runpath_var
-
-# Shared library path variable.
-shlibpath_var=$shlibpath_var
-
-# Is shlibpath searched before the hard-coded library search path?
-shlibpath_overrides_runpath=$shlibpath_overrides_runpath
-
-# Format of library name prefix.
-libname_spec=$lt_libname_spec
-
-# List of archive names. First name is the real one, the rest are links.
-# The last name is the one that the linker finds with -lNAME
-library_names_spec=$lt_library_names_spec
-
-# The coded name of the library, if different from the real name.
-soname_spec=$lt_soname_spec
-
-# Permission mode override for installation of shared libraries.
-install_override_mode=$lt_install_override_mode
-
-# Command to use after installation of a shared archive.
-postinstall_cmds=$lt_postinstall_cmds
-
-# Command to use after uninstallation of a shared archive.
-postuninstall_cmds=$lt_postuninstall_cmds
-
-# Commands used to finish a libtool library installation in a directory.
-finish_cmds=$lt_finish_cmds
-
-# As "finish_cmds", except a single script fragment to be evaled but
-# not shown.
-finish_eval=$lt_finish_eval
-
-# Whether we should hardcode library paths into libraries.
-hardcode_into_libs=$hardcode_into_libs
-
-# Compile-time system search path for libraries.
-sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
-
-# Run-time system search path for libraries.
-sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
-
-# Whether dlopen is supported.
-dlopen_support=$enable_dlopen
-
-# Whether dlopen of programs is supported.
-dlopen_self=$enable_dlopen_self
-
-# Whether dlopen of statically linked programs is supported.
-dlopen_self_static=$enable_dlopen_self_static
-
-# Commands to strip libraries.
-old_striplib=$lt_old_striplib
-striplib=$lt_striplib
-
-
-# The linker used to build libraries.
-LD=$lt_LD
-
-# How to create reloadable object files.
-reload_flag=$lt_reload_flag
-reload_cmds=$lt_reload_cmds
-
-# Commands used to build an old-style archive.
-old_archive_cmds=$lt_old_archive_cmds
-
-# A language specific compiler.
-CC=$lt_compiler
-
-# Is the compiler the GNU compiler?
-with_gcc=$GCC
-
-# Compiler flag to turn off builtin functions.
-no_builtin_flag=$lt_lt_prog_compiler_no_builtin_flag
-
-# How to pass a linker flag through the compiler.
-wl=$lt_lt_prog_compiler_wl
-
-# Additional compiler flags for building library objects.
-pic_flag=$lt_lt_prog_compiler_pic
-
-# Compiler flag to prevent dynamic linking.
-link_static_flag=$lt_lt_prog_compiler_static
-
-# Does compiler simultaneously support -c and -o options?
-compiler_c_o=$lt_lt_cv_prog_compiler_c_o
-
-# Whether or not to add -lc for building shared libraries.
-build_libtool_need_lc=$archive_cmds_need_lc
-
-# Whether or not to disallow shared libs when runtime libs are static.
-allow_libtool_libs_with_static_runtimes=$enable_shared_with_static_runtimes
-
-# Compiler flag to allow reflexive dlopens.
-export_dynamic_flag_spec=$lt_export_dynamic_flag_spec
-
-# Compiler flag to generate shared objects directly from archives.
-whole_archive_flag_spec=$lt_whole_archive_flag_spec
-
-# Whether the compiler copes with passing no objects directly.
-compiler_needs_object=$lt_compiler_needs_object
-
-# Create an old-style archive from a shared archive.
-old_archive_from_new_cmds=$lt_old_archive_from_new_cmds
-
-# Create a temporary old-style archive to link instead of a shared archive.
-old_archive_from_expsyms_cmds=$lt_old_archive_from_expsyms_cmds
-
-# Commands used to build a shared archive.
-archive_cmds=$lt_archive_cmds
-archive_expsym_cmds=$lt_archive_expsym_cmds
-
-# Commands used to build a loadable module if different from building
-# a shared archive.
-module_cmds=$lt_module_cmds
-module_expsym_cmds=$lt_module_expsym_cmds
-
-# Whether we are building with GNU ld or not.
-with_gnu_ld=$lt_with_gnu_ld
-
-# Flag that allows shared libraries with undefined symbols to be built.
-allow_undefined_flag=$lt_allow_undefined_flag
-
-# Flag that enforces no undefined symbols.
-no_undefined_flag=$lt_no_undefined_flag
-
-# Flag to hardcode \$libdir into a binary during linking.
-# This must work even if \$libdir does not exist
-hardcode_libdir_flag_spec=$lt_hardcode_libdir_flag_spec
-
-# If ld is used when linking, flag to hardcode \$libdir into a binary
-# during linking. This must work even if \$libdir does not exist.
-hardcode_libdir_flag_spec_ld=$lt_hardcode_libdir_flag_spec_ld
-
-# Whether we need a single "-rpath" flag with a separated argument.
-hardcode_libdir_separator=$lt_hardcode_libdir_separator
-
-# Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
-# DIR into the resulting binary.
-hardcode_direct=$hardcode_direct
-
-# Set to "yes" if using DIR/libNAME\${shared_ext} during linking hardcodes
-# DIR into the resulting binary and the resulting library dependency is
-# "absolute",i.e impossible to change by setting \${shlibpath_var} if the
-# library is relocated.
-hardcode_direct_absolute=$hardcode_direct_absolute
-
-# Set to "yes" if using the -LDIR flag during linking hardcodes DIR
-# into the resulting binary.
-hardcode_minus_L=$hardcode_minus_L
-
-# Set to "yes" if using SHLIBPATH_VAR=DIR during linking hardcodes DIR
-# into the resulting binary.
-hardcode_shlibpath_var=$hardcode_shlibpath_var
-
-# Set to "yes" if building a shared library automatically hardcodes DIR
-# into the library and all subsequent libraries and executables linked
-# against it.
-hardcode_automatic=$hardcode_automatic
-
-# Set to yes if linker adds runtime paths of dependent libraries
-# to runtime path list.
-inherit_rpath=$inherit_rpath
-
-# Whether libtool must link a program against all its dependency libraries.
-link_all_deplibs=$link_all_deplibs
-
-# Fix the shell variable \$srcfile for the compiler.
-fix_srcfile_path=$lt_fix_srcfile_path
-
-# Set to "yes" if exported symbols are required.
-always_export_symbols=$always_export_symbols
-
-# The commands to list exported symbols.
-export_symbols_cmds=$lt_export_symbols_cmds
-
-# Symbols that should not be listed in the preloaded symbols.
-exclude_expsyms=$lt_exclude_expsyms
-
-# Symbols that must always be exported.
-include_expsyms=$lt_include_expsyms
-
-# Commands necessary for linking programs (against libraries) with templates.
-prelink_cmds=$lt_prelink_cmds
-
-# Specify filename containing input files.
-file_list_spec=$lt_file_list_spec
-
-# How to hardcode a shared library path into an executable.
-hardcode_action=$hardcode_action
-
-# ### END LIBTOOL CONFIG
-
-_LT_EOF
-
- case $host_os in
- aix3*)
- cat <<\_LT_EOF >> "$cfgfile"
-# AIX sometimes has problems with the GCC collect2 program. For some
-# reason, if we set the COLLECT_NAMES environment variable, the problems
-# vanish in a puff of smoke.
-if test "X${COLLECT_NAMES+set}" != Xset; then
- COLLECT_NAMES=
- export COLLECT_NAMES
-fi
-_LT_EOF
- ;;
- esac
-
-
-ltmain="$ac_aux_dir/ltmain.sh"
-
-
- # We use sed instead of cat because bash on DJGPP gets confused if
- # if finds mixed CR/LF and LF-only lines. Since sed operates in
- # text mode, it properly converts lines to CR/LF. This bash problem
- # is reportedly fixed, but why not run on old versions too?
- sed '/^# Generated shell functions inserted here/q' "$ltmain" >> "$cfgfile" \
- || (rm -f "$cfgfile"; exit 1)
-
- case $xsi_shell in
- yes)
- cat << \_LT_EOF >> "$cfgfile"
-
-# func_dirname file append nondir_replacement
-# Compute the dirname of FILE. If nonempty, add APPEND to the result,
-# otherwise set result to NONDIR_REPLACEMENT.
-func_dirname ()
-{
- case ${1} in
- */*) func_dirname_result="${1%/*}${2}" ;;
- * ) func_dirname_result="${3}" ;;
- esac
-}
-
-# func_basename file
-func_basename ()
-{
- func_basename_result="${1##*/}"
-}
-
-# func_dirname_and_basename file append nondir_replacement
-# perform func_basename and func_dirname in a single function
-# call:
-# dirname: Compute the dirname of FILE. If nonempty,
-# add APPEND to the result, otherwise set result
-# to NONDIR_REPLACEMENT.
-# value returned in "$func_dirname_result"
-# basename: Compute filename of FILE.
-# value retuned in "$func_basename_result"
-# Implementation must be kept synchronized with func_dirname
-# and func_basename. For efficiency, we do not delegate to
-# those functions but instead duplicate the functionality here.
-func_dirname_and_basename ()
-{
- case ${1} in
- */*) func_dirname_result="${1%/*}${2}" ;;
- * ) func_dirname_result="${3}" ;;
- esac
- func_basename_result="${1##*/}"
-}
-
-# func_stripname prefix suffix name
-# strip PREFIX and SUFFIX off of NAME.
-# PREFIX and SUFFIX must not contain globbing or regex special
-# characters, hashes, percent signs, but SUFFIX may contain a leading
-# dot (in which case that matches only a dot).
-func_stripname ()
-{
- # pdksh 5.2.14 does not do ${X%$Y} correctly if both X and Y are
- # positional parameters, so assign one to ordinary parameter first.
- func_stripname_result=${3}
- func_stripname_result=${func_stripname_result#"${1}"}
- func_stripname_result=${func_stripname_result%"${2}"}
-}
-
-# func_opt_split
-func_opt_split ()
-{
- func_opt_split_opt=${1%%=*}
- func_opt_split_arg=${1#*=}
-}
-
-# func_lo2o object
-func_lo2o ()
-{
- case ${1} in
- *.lo) func_lo2o_result=${1%.lo}.${objext} ;;
- *) func_lo2o_result=${1} ;;
- esac
-}
-
-# func_xform libobj-or-source
-func_xform ()
-{
- func_xform_result=${1%.*}.lo
-}
-
-# func_arith arithmetic-term...
-func_arith ()
-{
- func_arith_result=$(( $* ))
-}
-
-# func_len string
-# STRING may not start with a hyphen.
-func_len ()
-{
- func_len_result=${#1}
-}
-
-_LT_EOF
- ;;
- *) # Bourne compatible functions.
- cat << \_LT_EOF >> "$cfgfile"
-
-# func_dirname file append nondir_replacement
-# Compute the dirname of FILE. If nonempty, add APPEND to the result,
-# otherwise set result to NONDIR_REPLACEMENT.
-func_dirname ()
-{
- # Extract subdirectory from the argument.
- func_dirname_result=`$ECHO "${1}" | $SED "$dirname"`
- if test "X$func_dirname_result" = "X${1}"; then
- func_dirname_result="${3}"
- else
- func_dirname_result="$func_dirname_result${2}"
- fi
-}
-
-# func_basename file
-func_basename ()
-{
- func_basename_result=`$ECHO "${1}" | $SED "$basename"`
-}
-
-
-# func_stripname prefix suffix name
-# strip PREFIX and SUFFIX off of NAME.
-# PREFIX and SUFFIX must not contain globbing or regex special
-# characters, hashes, percent signs, but SUFFIX may contain a leading
-# dot (in which case that matches only a dot).
-# func_strip_suffix prefix name
-func_stripname ()
-{
- case ${2} in
- .*) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%\\\\${2}\$%%"`;;
- *) func_stripname_result=`$ECHO "${3}" | $SED "s%^${1}%%; s%${2}\$%%"`;;
- esac
-}
-
-# sed scripts:
-my_sed_long_opt='1s/^\(-[^=]*\)=.*/\1/;q'
-my_sed_long_arg='1s/^-[^=]*=//'
-
-# func_opt_split
-func_opt_split ()
-{
- func_opt_split_opt=`$ECHO "${1}" | $SED "$my_sed_long_opt"`
- func_opt_split_arg=`$ECHO "${1}" | $SED "$my_sed_long_arg"`
-}
-
-# func_lo2o object
-func_lo2o ()
-{
- func_lo2o_result=`$ECHO "${1}" | $SED "$lo2o"`
-}
-
-# func_xform libobj-or-source
-func_xform ()
-{
- func_xform_result=`$ECHO "${1}" | $SED 's/\.[^.]*$/.lo/'`
-}
-
-# func_arith arithmetic-term...
-func_arith ()
-{
- func_arith_result=`expr "$@"`
-}
-
-# func_len string
-# STRING may not start with a hyphen.
-func_len ()
-{
- func_len_result=`expr "$1" : ".*" 2>/dev/null || echo $max_cmd_len`
-}
-
-_LT_EOF
-esac
-
-case $lt_shell_append in
- yes)
- cat << \_LT_EOF >> "$cfgfile"
-
-# func_append var value
-# Append VALUE to the end of shell variable VAR.
-func_append ()
-{
- eval "$1+=\$2"
-}
-_LT_EOF
- ;;
- *)
- cat << \_LT_EOF >> "$cfgfile"
-
-# func_append var value
-# Append VALUE to the end of shell variable VAR.
-func_append ()
-{
- eval "$1=\$$1\$2"
-}
-
-_LT_EOF
- ;;
- esac
-
-
- sed -n '/^# Generated shell functions inserted here/,$p' "$ltmain" >> "$cfgfile" \
- || (rm -f "$cfgfile"; exit 1)
-
- mv -f "$cfgfile" "$ofile" ||
- (rm -f "$ofile" && cp "$cfgfile" "$ofile" && rm -f "$cfgfile")
- chmod +x "$ofile"
-
- ;;
- "default-1":C)
- for ac_file in $CONFIG_FILES; do
- # Support "outfile[:infile[:infile...]]"
- case "$ac_file" in
- *:*) ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
- esac
- # PO directories have a Makefile.in generated from Makefile.in.in.
- case "$ac_file" in */Makefile.in)
- # Adjust a relative srcdir.
- ac_dir=`echo "$ac_file"|sed 's%/[^/][^/]*$%%'`
- ac_dir_suffix=/`echo "$ac_dir"|sed 's%^\./%%'`
- ac_dots=`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'`
- # In autoconf-2.13 it is called $ac_given_srcdir.
- # In autoconf-2.50 it is called $srcdir.
- test -n "$ac_given_srcdir" || ac_given_srcdir="$srcdir"
- case "$ac_given_srcdir" in
- .) top_srcdir=`echo $ac_dots|sed 's%/$%%'` ;;
- /*) top_srcdir="$ac_given_srcdir" ;;
- *) top_srcdir="$ac_dots$ac_given_srcdir" ;;
- esac
- if test -f "$ac_given_srcdir/$ac_dir/POTFILES.in"; then
- rm -f "$ac_dir/POTFILES"
- test -n "$as_me" && echo "$as_me: creating $ac_dir/POTFILES" || echo "creating $ac_dir/POTFILES"
- cat "$ac_given_srcdir/$ac_dir/POTFILES.in" | sed -e "/^#/d" -e "/^[ ]*\$/d" -e "s,.*, $top_srcdir/& \\\\," | sed -e "\$s/\(.*\) \\\\/\1/" > "$ac_dir/POTFILES"
- POMAKEFILEDEPS="POTFILES.in"
- # ALL_LINGUAS, POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES depend
- # on $ac_dir but don't depend on user-specified configuration
- # parameters.
- if test -f "$ac_given_srcdir/$ac_dir/LINGUAS"; then
- # The LINGUAS file contains the set of available languages.
- if test -n "$OBSOLETE_ALL_LINGUAS"; then
- test -n "$as_me" && echo "$as_me: setting ALL_LINGUAS in configure.ac is obsolete" || echo "setting ALL_LINGUAS in configure.ac is obsolete"
- fi
- ALL_LINGUAS_=`sed -e "/^#/d" "$ac_given_srcdir/$ac_dir/LINGUAS"`
- # Hide the ALL_LINGUAS assigment from automake.
- eval 'ALL_LINGUAS''=$ALL_LINGUAS_'
- POMAKEFILEDEPS="$POMAKEFILEDEPS LINGUAS"
- else
- # The set of available languages was given in configure.ac.
- eval 'ALL_LINGUAS''=$OBSOLETE_ALL_LINGUAS'
- fi
- case "$ac_given_srcdir" in
- .) srcdirpre= ;;
- *) srcdirpre='$(srcdir)/' ;;
- esac
- POFILES=
- GMOFILES=
- UPDATEPOFILES=
- DUMMYPOFILES=
- for lang in $ALL_LINGUAS; do
- POFILES="$POFILES $srcdirpre$lang.po"
- GMOFILES="$GMOFILES $srcdirpre$lang.gmo"
- UPDATEPOFILES="$UPDATEPOFILES $lang.po-update"
- DUMMYPOFILES="$DUMMYPOFILES $lang.nop"
- done
- # CATALOGS depends on both $ac_dir and the user's LINGUAS
- # environment variable.
- INST_LINGUAS=
- if test -n "$ALL_LINGUAS"; then
- for presentlang in $ALL_LINGUAS; do
- useit=no
- if test "%UNSET%" != "$LINGUAS"; then
- desiredlanguages="$LINGUAS"
- else
- desiredlanguages="$ALL_LINGUAS"
- fi
- for desiredlang in $desiredlanguages; do
- # Use the presentlang catalog if desiredlang is
- # a. equal to presentlang, or
- # b. a variant of presentlang (because in this case,
- # presentlang can be used as a fallback for messages
- # which are not translated in the desiredlang catalog).
- case "$desiredlang" in
- "$presentlang"*) useit=yes;;
- esac
- done
- if test $useit = yes; then
- INST_LINGUAS="$INST_LINGUAS $presentlang"
- fi
- done
- fi
- CATALOGS=
- if test -n "$INST_LINGUAS"; then
- for lang in $INST_LINGUAS; do
- CATALOGS="$CATALOGS $lang.gmo"
- done
- fi
- test -n "$as_me" && echo "$as_me: creating $ac_dir/Makefile" || echo "creating $ac_dir/Makefile"
- sed -e "/^POTFILES =/r $ac_dir/POTFILES" -e "/^# Makevars/r $ac_given_srcdir/$ac_dir/Makevars" -e "s|@POFILES@|$POFILES|g" -e "s|@GMOFILES@|$GMOFILES|g" -e "s|@UPDATEPOFILES@|$UPDATEPOFILES|g" -e "s|@DUMMYPOFILES@|$DUMMYPOFILES|g" -e "s|@CATALOGS@|$CATALOGS|g" -e "s|@POMAKEFILEDEPS@|$POMAKEFILEDEPS|g" "$ac_dir/Makefile.in" > "$ac_dir/Makefile"
- for f in "$ac_given_srcdir/$ac_dir"/Rules-*; do
- if test -f "$f"; then
- case "$f" in
- *.orig | *.bak | *~) ;;
- *) cat "$f" >> "$ac_dir/Makefile" ;;
- esac
- fi
- done
- fi
- ;;
- esac
- done ;;
- "default-2":C)
- for ac_file in $CONFIG_FILES; do
- # Support "outfile[:infile[:infile...]]"
- case "$ac_file" in
- *:*) ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
- esac
- # PO directories have a Makefile.in generated from Makefile.in.in.
- case "$ac_file" in */Makefile.in)
- # Adjust a relative srcdir.
- ac_dir=`echo "$ac_file"|sed 's%/[^/][^/]*$%%'`
- ac_dir_suffix=/`echo "$ac_dir"|sed 's%^\./%%'`
- ac_dots=`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'`
- # In autoconf-2.13 it is called $ac_given_srcdir.
- # In autoconf-2.50 it is called $srcdir.
- test -n "$ac_given_srcdir" || ac_given_srcdir="$srcdir"
- case "$ac_given_srcdir" in
- .) top_srcdir=`echo $ac_dots|sed 's%/$%%'` ;;
- /*) top_srcdir="$ac_given_srcdir" ;;
- *) top_srcdir="$ac_dots$ac_given_srcdir" ;;
- esac
- if test -f "$ac_given_srcdir/$ac_dir/POTFILES.in"; then
- rm -f "$ac_dir/POTFILES"
- test -n "$as_me" && echo "$as_me: creating $ac_dir/POTFILES" || echo "creating $ac_dir/POTFILES"
- cat "$ac_given_srcdir/$ac_dir/POTFILES.in" | sed -e "/^#/d" -e "/^[ ]*\$/d" -e "s,.*, $top_srcdir/& \\\\," | sed -e "\$s/\(.*\) \\\\/\1/" > "$ac_dir/POTFILES"
- POMAKEFILEDEPS="POTFILES.in"
- # ALL_LINGUAS, POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES depend
- # on $ac_dir but don't depend on user-specified configuration
- # parameters.
- if test -f "$ac_given_srcdir/$ac_dir/LINGUAS"; then
- # The LINGUAS file contains the set of available languages.
- if test -n "$OBSOLETE_ALL_LINGUAS"; then
- test -n "$as_me" && echo "$as_me: setting ALL_LINGUAS in configure.ac is obsolete" || echo "setting ALL_LINGUAS in configure.ac is obsolete"
- fi
- ALL_LINGUAS_=`sed -e "/^#/d" "$ac_given_srcdir/$ac_dir/LINGUAS"`
- # Hide the ALL_LINGUAS assigment from automake.
- eval 'ALL_LINGUAS''=$ALL_LINGUAS_'
- POMAKEFILEDEPS="$POMAKEFILEDEPS LINGUAS"
- else
- # The set of available languages was given in configure.ac.
- eval 'ALL_LINGUAS''=$OBSOLETE_ALL_LINGUAS'
- fi
- case "$ac_given_srcdir" in
- .) srcdirpre= ;;
- *) srcdirpre='$(srcdir)/' ;;
- esac
- POFILES=
- GMOFILES=
- UPDATEPOFILES=
- DUMMYPOFILES=
- for lang in $ALL_LINGUAS; do
- POFILES="$POFILES $srcdirpre$lang.po"
- GMOFILES="$GMOFILES $srcdirpre$lang.gmo"
- UPDATEPOFILES="$UPDATEPOFILES $lang.po-update"
- DUMMYPOFILES="$DUMMYPOFILES $lang.nop"
- done
- # CATALOGS depends on both $ac_dir and the user's LINGUAS
- # environment variable.
- INST_LINGUAS=
- if test -n "$ALL_LINGUAS"; then
- for presentlang in $ALL_LINGUAS; do
- useit=no
- if test "%UNSET%" != "$LINGUAS"; then
- desiredlanguages="$LINGUAS"
- else
- desiredlanguages="$ALL_LINGUAS"
- fi
- for desiredlang in $desiredlanguages; do
- # Use the presentlang catalog if desiredlang is
- # a. equal to presentlang, or
- # b. a variant of presentlang (because in this case,
- # presentlang can be used as a fallback for messages
- # which are not translated in the desiredlang catalog).
- case "$desiredlang" in
- "$presentlang"*) useit=yes;;
- esac
- done
- if test $useit = yes; then
- INST_LINGUAS="$INST_LINGUAS $presentlang"
- fi
- done
- fi
- CATALOGS=
- if test -n "$INST_LINGUAS"; then
- for lang in $INST_LINGUAS; do
- CATALOGS="$CATALOGS $lang.gmo"
- done
- fi
- test -n "$as_me" && echo "$as_me: creating $ac_dir/Makefile" || echo "creating $ac_dir/Makefile"
- sed -e "/^POTFILES =/r $ac_dir/POTFILES" -e "/^# Makevars/r $ac_given_srcdir/$ac_dir/Makevars" -e "s|@POFILES@|$POFILES|g" -e "s|@GMOFILES@|$GMOFILES|g" -e "s|@UPDATEPOFILES@|$UPDATEPOFILES|g" -e "s|@DUMMYPOFILES@|$DUMMYPOFILES|g" -e "s|@CATALOGS@|$CATALOGS|g" -e "s|@POMAKEFILEDEPS@|$POMAKEFILEDEPS|g" "$ac_dir/Makefile.in" > "$ac_dir/Makefile"
- for f in "$ac_given_srcdir/$ac_dir"/Rules-*; do
- if test -f "$f"; then
- case "$f" in
- *.orig | *.bak | *~) ;;
- *) cat "$f" >> "$ac_dir/Makefile" ;;
- esac
- fi
- done
- fi
- ;;
- esac
- done ;;
-
- esac
-done # for ac_tag
-
-
-as_fn_exit 0
-_ACEOF
-ac_clean_files=$ac_clean_files_save
-
-test $ac_write_fail = 0 ||
- as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
-
-
-# configure is writing to config.log, and then calls config.status.
-# config.status does its own redirection, appending to config.log.
-# Unfortunately, on DOS this fails, as config.log is still kept open
-# by configure, so config.status won't be able to write to it; its
-# output is simply discarded. So we exec the FD to /dev/null,
-# effectively closing config.log, so it can be properly (re)opened and
-# appended to by config.status. When coming back to configure, we
-# need to make the FD available again.
-if test "$no_create" != yes; then
- ac_cs_success=:
- ac_config_status_args=
- test "$silent" = yes &&
- ac_config_status_args="$ac_config_status_args --quiet"
- exec 5>/dev/null
- $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
- exec 5>>config.log
- # Use ||, not &&, to avoid exiting from the if with $? = 1, which
- # would make configure fail if this is the last instruction.
- $ac_cs_success || as_fn_exit 1
-fi
-if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
-$as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
-fi
-
-
-
-touch config.status.tmp
-if touch --reference=config.status config.status.tmp > /dev/null 2>&1; then
- sed '/as_fn_exit 0/i \
-sed -e \"s/^\t\\\(\\\$(AM_V_CCLD)\\\)/\t+ \\\1/\" Makefile > Makefile.tmp \
-touch --reference=Makefile Makefile.tmp \
-mv Makefile.tmp Makefile \
-' config.status > config.status.tmp
- touch --reference=config.status config.status.tmp
- mv config.status.tmp config.status
- chmod +x config.status
- sed -e "s/^\t\(\$(AM_V_CCLD)\)/\t+ \1/" Makefile > Makefile.tmp
- touch --reference=Makefile Makefile.tmp
- mv Makefile.tmp Makefile
-else
- rm -f config.status.tmp
-fi
Property changes on: sources/GNU/binutils/create-2.43.1-libtool-lib64-patch/binutils-2.43.1-new/opcodes/configure
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: sources/GNU/binutils/create-2.43.1-copy-osabi-patch/file.list
===================================================================
--- sources/GNU/binutils/create-2.43.1-copy-osabi-patch/file.list (revision 75)
+++ sources/GNU/binutils/create-2.43.1-copy-osabi-patch/file.list (nonexistent)
@@ -1 +0,0 @@
-binutils-2.43.1/bfd/elf.c
Index: sources/GNU/binutils/create-2.43.1-copy-osabi-patch/create.patch.sh
===================================================================
--- sources/GNU/binutils/create-2.43.1-copy-osabi-patch/create.patch.sh (revision 75)
+++ sources/GNU/binutils/create-2.43.1-copy-osabi-patch/create.patch.sh (nonexistent)
@@ -1,15 +0,0 @@
-#!/bin/bash
-
-VERSION=2.43.1
-
-tar --files-from=file.list -xJvf ../binutils-$VERSION.tar.xz
-mv binutils-$VERSION binutils-$VERSION-orig
-
-cp -rf ./binutils-$VERSION-new ./binutils-$VERSION
-
-diff --unified -Nr binutils-$VERSION-orig binutils-$VERSION > binutils-$VERSION-copy-osabi.patch
-
-mv binutils-$VERSION-copy-osabi.patch ../patches
-
-rm -rf ./binutils-$VERSION
-rm -rf ./binutils-$VERSION-orig
Property changes on: sources/GNU/binutils/create-2.43.1-copy-osabi-patch/create.patch.sh
___________________________________________________________________
Deleted: svn:executable
## -1 +0,0 ##
-*
\ No newline at end of property
Index: sources/GNU/binutils/create-2.43.1-copy-osabi-patch/binutils-2.43.1-new/bfd/elf.c
===================================================================
--- sources/GNU/binutils/create-2.43.1-copy-osabi-patch/binutils-2.43.1-new/bfd/elf.c (revision 75)
+++ sources/GNU/binutils/create-2.43.1-copy-osabi-patch/binutils-2.43.1-new/bfd/elf.c (nonexistent)
@@ -1,14318 +0,0 @@
-/* ELF executable support for BFD.
-
- Copyright (C) 1993-2024 Free Software Foundation, Inc.
-
- This file is part of BFD, the Binary File Descriptor library.
-
- This program is free software; you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation; either version 3 of the License, or
- (at your option) any later version.
-
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program; if not, write to the Free Software
- Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston,
- MA 02110-1301, USA. */
-
-
-/*
-SECTION
- ELF backends
-
- BFD support for ELF formats is being worked on.
- Currently, the best supported back ends are for sparc and i386
- (running svr4 or Solaris 2).
-
- Documentation of the internals of the support code still needs
- to be written. The code is changing quickly enough that we
- haven't bothered yet. */
-
-/* For sparc64-cross-sparc32. */
-#define _SYSCALL32
-#include "sysdep.h"
-#include <limits.h>
-#include "bfd.h"
-#include "bfdlink.h"
-#include "libbfd.h"
-#define ARCH_SIZE 0
-#include "elf-bfd.h"
-#include "libiberty.h"
-#include "safe-ctype.h"
-#include "elf-linux-core.h"
-
-#ifdef CORE_HEADER
-#include CORE_HEADER
-#endif
-
-static int elf_sort_sections (const void *, const void *);
-static bool assign_file_positions_except_relocs (bfd *, struct bfd_link_info *);
-static bool swap_out_syms (bfd *, struct elf_strtab_hash **, int,
- struct bfd_link_info *);
-static bool elf_parse_notes (bfd *abfd, char *buf, size_t size,
- file_ptr offset, size_t align);
-
-/* Swap version information in and out. The version information is
- currently size independent. If that ever changes, this code will
- need to move into elfcode.h. */
-
-/* Swap in a Verdef structure. */
-
-void
-_bfd_elf_swap_verdef_in (bfd *abfd,
- const Elf_External_Verdef *src,
- Elf_Internal_Verdef *dst)
-{
- dst->vd_version = H_GET_16 (abfd, src->vd_version);
- dst->vd_flags = H_GET_16 (abfd, src->vd_flags);
- dst->vd_ndx = H_GET_16 (abfd, src->vd_ndx);
- dst->vd_cnt = H_GET_16 (abfd, src->vd_cnt);
- dst->vd_hash = H_GET_32 (abfd, src->vd_hash);
- dst->vd_aux = H_GET_32 (abfd, src->vd_aux);
- dst->vd_next = H_GET_32 (abfd, src->vd_next);
-}
-
-/* Swap out a Verdef structure. */
-
-void
-_bfd_elf_swap_verdef_out (bfd *abfd,
- const Elf_Internal_Verdef *src,
- Elf_External_Verdef *dst)
-{
- H_PUT_16 (abfd, src->vd_version, dst->vd_version);
- H_PUT_16 (abfd, src->vd_flags, dst->vd_flags);
- H_PUT_16 (abfd, src->vd_ndx, dst->vd_ndx);
- H_PUT_16 (abfd, src->vd_cnt, dst->vd_cnt);
- H_PUT_32 (abfd, src->vd_hash, dst->vd_hash);
- H_PUT_32 (abfd, src->vd_aux, dst->vd_aux);
- H_PUT_32 (abfd, src->vd_next, dst->vd_next);
-}
-
-/* Swap in a Verdaux structure. */
-
-void
-_bfd_elf_swap_verdaux_in (bfd *abfd,
- const Elf_External_Verdaux *src,
- Elf_Internal_Verdaux *dst)
-{
- dst->vda_name = H_GET_32 (abfd, src->vda_name);
- dst->vda_next = H_GET_32 (abfd, src->vda_next);
-}
-
-/* Swap out a Verdaux structure. */
-
-void
-_bfd_elf_swap_verdaux_out (bfd *abfd,
- const Elf_Internal_Verdaux *src,
- Elf_External_Verdaux *dst)
-{
- H_PUT_32 (abfd, src->vda_name, dst->vda_name);
- H_PUT_32 (abfd, src->vda_next, dst->vda_next);
-}
-
-/* Swap in a Verneed structure. */
-
-void
-_bfd_elf_swap_verneed_in (bfd *abfd,
- const Elf_External_Verneed *src,
- Elf_Internal_Verneed *dst)
-{
- dst->vn_version = H_GET_16 (abfd, src->vn_version);
- dst->vn_cnt = H_GET_16 (abfd, src->vn_cnt);
- dst->vn_file = H_GET_32 (abfd, src->vn_file);
- dst->vn_aux = H_GET_32 (abfd, src->vn_aux);
- dst->vn_next = H_GET_32 (abfd, src->vn_next);
-}
-
-/* Swap out a Verneed structure. */
-
-void
-_bfd_elf_swap_verneed_out (bfd *abfd,
- const Elf_Internal_Verneed *src,
- Elf_External_Verneed *dst)
-{
- H_PUT_16 (abfd, src->vn_version, dst->vn_version);
- H_PUT_16 (abfd, src->vn_cnt, dst->vn_cnt);
- H_PUT_32 (abfd, src->vn_file, dst->vn_file);
- H_PUT_32 (abfd, src->vn_aux, dst->vn_aux);
- H_PUT_32 (abfd, src->vn_next, dst->vn_next);
-}
-
-/* Swap in a Vernaux structure. */
-
-void
-_bfd_elf_swap_vernaux_in (bfd *abfd,
- const Elf_External_Vernaux *src,
- Elf_Internal_Vernaux *dst)
-{
- dst->vna_hash = H_GET_32 (abfd, src->vna_hash);
- dst->vna_flags = H_GET_16 (abfd, src->vna_flags);
- dst->vna_other = H_GET_16 (abfd, src->vna_other);
- dst->vna_name = H_GET_32 (abfd, src->vna_name);
- dst->vna_next = H_GET_32 (abfd, src->vna_next);
-}
-
-/* Swap out a Vernaux structure. */
-
-void
-_bfd_elf_swap_vernaux_out (bfd *abfd,
- const Elf_Internal_Vernaux *src,
- Elf_External_Vernaux *dst)
-{
- H_PUT_32 (abfd, src->vna_hash, dst->vna_hash);
- H_PUT_16 (abfd, src->vna_flags, dst->vna_flags);
- H_PUT_16 (abfd, src->vna_other, dst->vna_other);
- H_PUT_32 (abfd, src->vna_name, dst->vna_name);
- H_PUT_32 (abfd, src->vna_next, dst->vna_next);
-}
-
-/* Swap in a Versym structure. */
-
-void
-_bfd_elf_swap_versym_in (bfd *abfd,
- const Elf_External_Versym *src,
- Elf_Internal_Versym *dst)
-{
- dst->vs_vers = H_GET_16 (abfd, src->vs_vers);
-}
-
-/* Swap out a Versym structure. */
-
-void
-_bfd_elf_swap_versym_out (bfd *abfd,
- const Elf_Internal_Versym *src,
- Elf_External_Versym *dst)
-{
- H_PUT_16 (abfd, src->vs_vers, dst->vs_vers);
-}
-
-/* Standard ELF hash function. Do not change this function; you will
- cause invalid hash tables to be generated. */
-
-unsigned long
-bfd_elf_hash (const char *namearg)
-{
- uint32_t h = 0;
-
- for (const unsigned char *name = (const unsigned char *) namearg;
- *name; name++)
- {
- h = (h << 4) + *name;
- h ^= (h >> 24) & 0xf0;
- }
- return h & 0x0fffffff;
-}
-
-/* DT_GNU_HASH hash function. Do not change this function; you will
- cause invalid hash tables to be generated. */
-
-unsigned long
-bfd_elf_gnu_hash (const char *namearg)
-{
- uint32_t h = 5381;
-
- for (const unsigned char *name = (const unsigned char *) namearg;
- *name; name++)
- h = (h << 5) + h + *name;
- return h;
-}
-
-/* Create a tdata field OBJECT_SIZE bytes in length, zeroed out and with
- the object_id field of an elf_obj_tdata field set to OBJECT_ID. */
-bool
-bfd_elf_allocate_object (bfd *abfd,
- size_t object_size,
- enum elf_target_id object_id)
-{
- BFD_ASSERT (object_size >= sizeof (struct elf_obj_tdata));
- abfd->tdata.any = bfd_zalloc (abfd, object_size);
- if (abfd->tdata.any == NULL)
- return false;
-
- elf_object_id (abfd) = object_id;
- if (abfd->direction != read_direction)
- {
- struct output_elf_obj_tdata *o = bfd_zalloc (abfd, sizeof *o);
- if (o == NULL)
- return false;
- elf_tdata (abfd)->o = o;
- elf_program_header_size (abfd) = (bfd_size_type) -1;
- }
- return true;
-}
-
-
-bool
-bfd_elf_make_object (bfd *abfd)
-{
- const struct elf_backend_data *bed = get_elf_backend_data (abfd);
- return bfd_elf_allocate_object (abfd, sizeof (struct elf_obj_tdata),
- bed->target_id);
-}
-
-bool
-bfd_elf_mkcorefile (bfd *abfd)
-{
- /* I think this can be done just like an object file. */
- if (!abfd->xvec->_bfd_set_format[(int) bfd_object] (abfd))
- return false;
- elf_tdata (abfd)->core = bfd_zalloc (abfd, sizeof (*elf_tdata (abfd)->core));
- return elf_tdata (abfd)->core != NULL;
-}
-
-char *
-bfd_elf_get_str_section (bfd *abfd, unsigned int shindex)
-{
- Elf_Internal_Shdr **i_shdrp;
- bfd_byte *shstrtab = NULL;
- file_ptr offset;
- bfd_size_type shstrtabsize;
-
- i_shdrp = elf_elfsections (abfd);
- if (i_shdrp == 0
- || shindex >= elf_numsections (abfd)
- || i_shdrp[shindex] == 0)
- return NULL;
-
- shstrtab = i_shdrp[shindex]->contents;
- if (shstrtab == NULL)
- {
- /* No cached one, attempt to read, and cache what we read. */
- offset = i_shdrp[shindex]->sh_offset;
- shstrtabsize = i_shdrp[shindex]->sh_size;
-
- /* Allocate and clear an extra byte at the end, to prevent crashes
- in case the string table is not terminated. */
- if (shstrtabsize + 1 <= 1
- || bfd_seek (abfd, offset, SEEK_SET) != 0
- || (shstrtab
- = _bfd_mmap_readonly_persistent (abfd, shstrtabsize)) == NULL)
- {
- /* Once we've failed to read it, make sure we don't keep
- trying. Otherwise, we'll keep allocating space for
- the string table over and over. */
- i_shdrp[shindex]->sh_size = 0;
- }
- else if (shstrtab[shstrtabsize - 1] != '\0')
- {
- /* It is an error if a string table isn't terminated. */
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB(%pA): string table is corrupt"),
- abfd, i_shdrp[shindex]->bfd_section);
- return NULL;
- }
- i_shdrp[shindex]->contents = shstrtab;
- }
- return (char *) shstrtab;
-}
-
-char *
-bfd_elf_string_from_elf_section (bfd *abfd,
- unsigned int shindex,
- unsigned int strindex)
-{
- Elf_Internal_Shdr *hdr;
-
- if (strindex == 0)
- return "";
-
- if (elf_elfsections (abfd) == NULL || shindex >= elf_numsections (abfd))
- return NULL;
-
- hdr = elf_elfsections (abfd)[shindex];
-
- if (hdr->contents == NULL)
- {
- if (hdr->sh_type != SHT_STRTAB && hdr->sh_type < SHT_LOOS)
- {
- /* PR 17512: file: f057ec89. */
- /* xgettext:c-format */
- _bfd_error_handler (_("%pB: attempt to load strings from"
- " a non-string section (number %d)"),
- abfd, shindex);
- return NULL;
- }
-
- if (bfd_elf_get_str_section (abfd, shindex) == NULL)
- return NULL;
- }
- else
- {
- /* PR 24273: The string section's contents may have already
- been loaded elsewhere, eg because a corrupt file has the
- string section index in the ELF header pointing at a group
- section. So be paranoid, and test that the last byte of
- the section is zero. */
- if (hdr->sh_size == 0 || hdr->contents[hdr->sh_size - 1] != 0)
- return NULL;
- }
-
- if (strindex >= hdr->sh_size)
- {
- unsigned int shstrndx = elf_elfheader(abfd)->e_shstrndx;
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB: invalid string offset %u >= %" PRIu64 " for section `%s'"),
- abfd, strindex, (uint64_t) hdr->sh_size,
- (shindex == shstrndx && strindex == hdr->sh_name
- ? ".shstrtab"
- : bfd_elf_string_from_elf_section (abfd, shstrndx, hdr->sh_name)));
- return NULL;
- }
-
- return ((char *) hdr->contents) + strindex;
-}
-
-/* Read and convert symbols to internal format.
- SYMCOUNT specifies the number of symbols to read, starting from
- symbol SYMOFFSET. If any of INTSYM_BUF, EXTSYM_BUF or EXTSHNDX_BUF
- are non-NULL, they are used to store the internal symbols, external
- symbols, and symbol section index extensions, respectively.
- Returns a pointer to the internal symbol buffer (malloced if necessary)
- or NULL if there were no symbols or some kind of problem. */
-
-Elf_Internal_Sym *
-bfd_elf_get_elf_syms (bfd *ibfd,
- Elf_Internal_Shdr *symtab_hdr,
- size_t symcount,
- size_t symoffset,
- Elf_Internal_Sym *intsym_buf,
- void *extsym_buf,
- Elf_External_Sym_Shndx *extshndx_buf)
-{
- Elf_Internal_Shdr *shndx_hdr;
- void *alloc_ext;
- const bfd_byte *esym;
- Elf_External_Sym_Shndx *alloc_extshndx;
- Elf_External_Sym_Shndx *shndx;
- Elf_Internal_Sym *alloc_intsym;
- Elf_Internal_Sym *isym;
- Elf_Internal_Sym *isymend;
- const struct elf_backend_data *bed;
- size_t extsym_size;
- size_t amt;
- file_ptr pos;
-
- if (bfd_get_flavour (ibfd) != bfd_target_elf_flavour)
- abort ();
-
- if (symcount == 0)
- return intsym_buf;
-
- if (elf_use_dt_symtab_p (ibfd))
- {
- /* Use dynamic symbol table. */
- if (elf_tdata (ibfd)->dt_symtab_count != symcount + symoffset)
- {
- bfd_set_error (bfd_error_invalid_operation);
- return NULL;
- }
- return elf_tdata (ibfd)->dt_symtab + symoffset;
- }
-
- /* Normal syms might have section extension entries. */
- shndx_hdr = NULL;
- if (elf_symtab_shndx_list (ibfd) != NULL)
- {
- elf_section_list * entry;
- Elf_Internal_Shdr **sections = elf_elfsections (ibfd);
-
- /* Find an index section that is linked to this symtab section. */
- for (entry = elf_symtab_shndx_list (ibfd); entry != NULL; entry = entry->next)
- {
- /* PR 20063. */
- if (entry->hdr.sh_link >= elf_numsections (ibfd))
- continue;
-
- if (sections[entry->hdr.sh_link] == symtab_hdr)
- {
- shndx_hdr = & entry->hdr;
- break;
- };
- }
-
- if (shndx_hdr == NULL)
- {
- if (symtab_hdr == &elf_symtab_hdr (ibfd))
- /* Not really accurate, but this was how the old code used
- to work. */
- shndx_hdr = &elf_symtab_shndx_list (ibfd)->hdr;
- /* Otherwise we do nothing. The assumption is that
- the index table will not be needed. */
- }
- }
-
- /* Read the symbols. */
- alloc_ext = NULL;
- alloc_extshndx = NULL;
- alloc_intsym = NULL;
- bed = get_elf_backend_data (ibfd);
- extsym_size = bed->s->sizeof_sym;
- if (_bfd_mul_overflow (symcount, extsym_size, &amt))
- {
- bfd_set_error (bfd_error_file_too_big);
- return NULL;
- }
- pos = symtab_hdr->sh_offset + symoffset * extsym_size;
- size_t alloc_ext_size = amt;
- if (bfd_seek (ibfd, pos, SEEK_SET) != 0
- || !_bfd_mmap_read_temporary (&extsym_buf, &alloc_ext_size,
- &alloc_ext, ibfd, false))
- {
- intsym_buf = NULL;
- goto out2;
- }
-
- size_t alloc_extshndx_size = 0;
- if (shndx_hdr == NULL || shndx_hdr->sh_size == 0)
- extshndx_buf = NULL;
- else
- {
- if (_bfd_mul_overflow (symcount, sizeof (Elf_External_Sym_Shndx), &amt))
- {
- bfd_set_error (bfd_error_file_too_big);
- intsym_buf = NULL;
- goto out1;
- }
- alloc_extshndx_size = amt;
- pos = shndx_hdr->sh_offset + symoffset * sizeof (Elf_External_Sym_Shndx);
- if (bfd_seek (ibfd, pos, SEEK_SET) != 0
- || !_bfd_mmap_read_temporary ((void **) &extshndx_buf,
- &alloc_extshndx_size,
- (void **) &alloc_extshndx,
- ibfd, false))
- {
- intsym_buf = NULL;
- goto out1;
- }
- }
-
- if (intsym_buf == NULL)
- {
- if (_bfd_mul_overflow (symcount, sizeof (Elf_Internal_Sym), &amt))
- {
- bfd_set_error (bfd_error_file_too_big);
- goto out1;
- }
- alloc_intsym = (Elf_Internal_Sym *) bfd_malloc (amt);
- intsym_buf = alloc_intsym;
- if (intsym_buf == NULL)
- goto out1;
- }
-
- /* Convert the symbols to internal form. */
- isymend = intsym_buf + symcount;
- for (esym = (const bfd_byte *) extsym_buf, isym = intsym_buf,
- shndx = extshndx_buf;
- isym < isymend;
- esym += extsym_size, isym++, shndx = shndx != NULL ? shndx + 1 : NULL)
- if (!(*bed->s->swap_symbol_in) (ibfd, esym, shndx, isym))
- {
- symoffset += (esym - (bfd_byte *) extsym_buf) / extsym_size;
- /* xgettext:c-format */
- _bfd_error_handler (_("%pB symbol number %lu references"
- " nonexistent SHT_SYMTAB_SHNDX section"),
- ibfd, (unsigned long) symoffset);
- free (alloc_intsym);
- intsym_buf = NULL;
- goto out1;
- }
-
- out1:
- _bfd_munmap_readonly_temporary (alloc_extshndx, alloc_extshndx_size);
- out2:
- _bfd_munmap_readonly_temporary (alloc_ext, alloc_ext_size);
-
- return intsym_buf;
-}
-
-/* Look up a symbol name. */
-const char *
-bfd_elf_sym_name (bfd *abfd,
- Elf_Internal_Shdr *symtab_hdr,
- Elf_Internal_Sym *isym,
- asection *sym_sec)
-{
- const char *name;
- unsigned int iname = isym->st_name;
- unsigned int shindex = symtab_hdr->sh_link;
-
- if (iname == 0 && ELF_ST_TYPE (isym->st_info) == STT_SECTION
- /* Check for a bogus st_shndx to avoid crashing. */
- && isym->st_shndx < elf_numsections (abfd))
- {
- iname = elf_elfsections (abfd)[isym->st_shndx]->sh_name;
- shindex = elf_elfheader (abfd)->e_shstrndx;
- }
-
- name = bfd_elf_string_from_elf_section (abfd, shindex, iname);
- if (name == NULL)
- name = "(null)";
- else if (sym_sec && *name == '\0')
- name = bfd_section_name (sym_sec);
-
- return name;
-}
-
-/* Return the name of the group signature symbol. Why isn't the
- signature just a string? */
-
-static const char *
-group_signature (bfd *abfd, Elf_Internal_Shdr *ghdr)
-{
- Elf_Internal_Shdr *hdr;
- unsigned char esym[sizeof (Elf64_External_Sym)];
- Elf_External_Sym_Shndx eshndx;
- Elf_Internal_Sym isym;
-
- /* First we need to ensure the symbol table is available. Make sure
- that it is a symbol table section. */
- if (ghdr->sh_link >= elf_numsections (abfd))
- return NULL;
- hdr = elf_elfsections (abfd) [ghdr->sh_link];
- if (hdr->sh_type != SHT_SYMTAB
- || ! bfd_section_from_shdr (abfd, ghdr->sh_link))
- return NULL;
-
- /* Go read the symbol. */
- hdr = &elf_tdata (abfd)->symtab_hdr;
- if (bfd_elf_get_elf_syms (abfd, hdr, 1, ghdr->sh_info,
- &isym, esym, &eshndx) == NULL)
- return NULL;
-
- return bfd_elf_sym_name (abfd, hdr, &isym, NULL);
-}
-
-static bool
-is_valid_group_section_header (Elf_Internal_Shdr *shdr, size_t minsize)
-{
- return (shdr->sh_size >= minsize
- && shdr->sh_entsize == GRP_ENTRY_SIZE
- && shdr->sh_size % GRP_ENTRY_SIZE == 0
- && shdr->bfd_section != NULL);
-}
-
-
-/* Set next_in_group, sec_group list pointers, and group names. */
-
-static bool
-process_sht_group_entries (bfd *abfd,
- Elf_Internal_Shdr *ghdr, unsigned int gidx)
-{
- unsigned char *contents;
-
- /* Read the raw contents. */
- if (!bfd_malloc_and_get_section (abfd, ghdr->bfd_section, &contents))
- {
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB: could not read contents of group [%u]"), abfd, gidx);
- return false;
- }
-
- asection *last_elt = NULL;
- const char *gname = NULL;
- unsigned char *p = contents + ghdr->sh_size;
- while (1)
- {
- unsigned int idx;
- Elf_Internal_Shdr *shdr;
- asection *elt;
-
- p -= 4;
- idx = H_GET_32 (abfd, p);
- if (p == contents)
- {
- if ((idx & GRP_COMDAT) != 0)
- ghdr->bfd_section->flags
- |= SEC_LINK_ONCE | SEC_LINK_DUPLICATES_DISCARD;
- break;
- }
-
- if (idx == 0
- || idx >= elf_numsections (abfd)
- || (shdr = elf_elfsections (abfd)[idx])->sh_type == SHT_GROUP
- || ((elt = shdr->bfd_section) != NULL
- && elf_sec_group (elt) != NULL
- && elf_sec_group (elt) != ghdr->bfd_section))
- {
- _bfd_error_handler
- (_("%pB: invalid entry (%#x) in group [%u]"),
- abfd, idx, gidx);
- continue;
- }
-
- /* PR binutils/23199: According to the ELF gABI all sections in
- a group must be marked with SHF_GROUP, but some tools
- generate broken objects. Fix them up here. */
- shdr->sh_flags |= SHF_GROUP;
-
- if (elt == NULL)
- {
- if (shdr->sh_type != SHT_RELA && shdr->sh_type != SHT_REL)
- {
- const char *name = bfd_elf_string_from_elf_section
- (abfd, elf_elfheader (abfd)->e_shstrndx, shdr->sh_name);
-
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB: unexpected type (%#x) section `%s' in group [%u]"),
- abfd, shdr->sh_type, name, gidx);
- }
- continue;
- }
-
- /* Don't try to add a section to elf_next_in_group list twice. */
- if (elf_sec_group (elt) != NULL)
- continue;
-
- if (last_elt == NULL)
- {
- /* Start a circular list with one element.
- It will be in reverse order to match what gas does. */
- elf_next_in_group (elt) = elt;
- /* Point the group section to it. */
- elf_next_in_group (ghdr->bfd_section) = elt;
- gname = group_signature (abfd, ghdr);
- if (gname == NULL)
- {
- free (contents);
- return false;
- }
- }
- else
- {
- elf_next_in_group (elt) = elf_next_in_group (last_elt);
- elf_next_in_group (last_elt) = elt;
- }
- last_elt = elt;
- elf_group_name (elt) = gname;
- elf_sec_group (elt) = ghdr->bfd_section;
- }
-
- free (contents);
- return true;
-}
-
-bool
-_bfd_elf_setup_sections (bfd *abfd)
-{
- bool result = true;
-
- /* Process SHF_LINK_ORDER. */
- for (asection *s = abfd->sections; s != NULL; s = s->next)
- {
- Elf_Internal_Shdr *this_hdr = &elf_section_data (s)->this_hdr;
- if ((this_hdr->sh_flags & SHF_LINK_ORDER) != 0)
- {
- unsigned int elfsec = this_hdr->sh_link;
- /* An sh_link value of 0 is now allowed. It indicates that linked
- to section has already been discarded, but that the current
- section has been retained for some other reason. This linking
- section is still a candidate for later garbage collection
- however. */
- if (elfsec == 0)
- {
- elf_linked_to_section (s) = NULL;
- }
- else
- {
- asection *linksec = NULL;
-
- if (elfsec < elf_numsections (abfd))
- {
- this_hdr = elf_elfsections (abfd)[elfsec];
- linksec = this_hdr->bfd_section;
- }
-
- /* PR 1991, 2008:
- Some strip/objcopy may leave an incorrect value in
- sh_link. We don't want to proceed. */
- if (linksec == NULL)
- {
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB: sh_link [%d] in section `%pA' is incorrect"),
- s->owner, elfsec, s);
- result = false;
- }
-
- elf_linked_to_section (s) = linksec;
- }
- }
- }
-
- /* Process section groups. */
- for (unsigned int i = 1; i < elf_numsections (abfd); i++)
- {
- Elf_Internal_Shdr *shdr = elf_elfsections (abfd)[i];
-
- if (shdr && shdr->sh_type == SHT_GROUP)
- {
- if (is_valid_group_section_header (shdr, GRP_ENTRY_SIZE))
- {
- if (shdr->sh_size >= 2 * GRP_ENTRY_SIZE
- && !process_sht_group_entries (abfd, shdr, i))
- result = false;
- }
- else
- {
- /* PR binutils/18758: Beware of corrupt binaries with
- invalid group data. */
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB: section group entry number %u is corrupt"), abfd, i);
- result = false;
- }
- }
- }
-
- return result;
-}
-
-bool
-bfd_elf_is_group_section (bfd *abfd ATTRIBUTE_UNUSED, const asection *sec)
-{
- return elf_next_in_group (sec) != NULL;
-}
-
-const char *
-bfd_elf_group_name (bfd *abfd ATTRIBUTE_UNUSED, const asection *sec)
-{
- if (elf_sec_group (sec) != NULL)
- return elf_group_name (sec);
- return NULL;
-}
-
-/* Make a BFD section from an ELF section. We store a pointer to the
- BFD section in the bfd_section field of the header. */
-
-bool
-_bfd_elf_make_section_from_shdr (bfd *abfd,
- Elf_Internal_Shdr *hdr,
- const char *name,
- int shindex)
-{
- asection *newsect;
- flagword flags;
- const struct elf_backend_data *bed;
- unsigned int opb = bfd_octets_per_byte (abfd, NULL);
-
- if (hdr->bfd_section != NULL)
- return true;
-
- newsect = bfd_make_section_anyway (abfd, name);
- if (newsect == NULL)
- return false;
-
- hdr->bfd_section = newsect;
- elf_section_data (newsect)->this_hdr = *hdr;
- elf_section_data (newsect)->this_idx = shindex;
-
- /* Always use the real type/flags. */
- elf_section_type (newsect) = hdr->sh_type;
- elf_section_flags (newsect) = hdr->sh_flags;
-
- newsect->filepos = hdr->sh_offset;
-
- flags = SEC_NO_FLAGS;
- if (hdr->sh_type != SHT_NOBITS)
- flags |= SEC_HAS_CONTENTS;
- if (hdr->sh_type == SHT_GROUP)
- flags |= SEC_GROUP;
- if ((hdr->sh_flags & SHF_ALLOC) != 0)
- {
- flags |= SEC_ALLOC;
- if (hdr->sh_type != SHT_NOBITS)
- flags |= SEC_LOAD;
- }
- if ((hdr->sh_flags & SHF_WRITE) == 0)
- flags |= SEC_READONLY;
- if ((hdr->sh_flags & SHF_EXECINSTR) != 0)
- flags |= SEC_CODE;
- else if ((flags & SEC_LOAD) != 0)
- flags |= SEC_DATA;
- if ((hdr->sh_flags & SHF_MERGE) != 0)
- {
- flags |= SEC_MERGE;
- newsect->entsize = hdr->sh_entsize;
- }
- if ((hdr->sh_flags & SHF_STRINGS) != 0)
- flags |= SEC_STRINGS;
- if ((hdr->sh_flags & SHF_TLS) != 0)
- flags |= SEC_THREAD_LOCAL;
- if ((hdr->sh_flags & SHF_EXCLUDE) != 0)
- flags |= SEC_EXCLUDE;
-
- switch (elf_elfheader (abfd)->e_ident[EI_OSABI])
- {
- /* FIXME: We should not recognize SHF_GNU_MBIND for ELFOSABI_NONE,
- but binutils as of 2019-07-23 did not set the EI_OSABI header
- byte. */
- case ELFOSABI_GNU:
- case ELFOSABI_FREEBSD:
- if ((hdr->sh_flags & SHF_GNU_RETAIN) != 0)
- elf_tdata (abfd)->has_gnu_osabi |= elf_gnu_osabi_retain;
- /* Fall through */
- case ELFOSABI_NONE:
- if ((hdr->sh_flags & SHF_GNU_MBIND) != 0)
- elf_tdata (abfd)->has_gnu_osabi |= elf_gnu_osabi_mbind;
- break;
- }
-
- if ((flags & SEC_ALLOC) == 0)
- {
- /* The debugging sections appear to be recognized only by name,
- not any sort of flag. Their SEC_ALLOC bits are cleared. */
- if (name [0] == '.')
- {
- if (startswith (name, ".debug")
- || startswith (name, ".gnu.debuglto_.debug_")
- || startswith (name, ".gnu.linkonce.wi.")
- || startswith (name, ".zdebug"))
- flags |= SEC_DEBUGGING | SEC_ELF_OCTETS;
- else if (startswith (name, GNU_BUILD_ATTRS_SECTION_NAME)
- || startswith (name, ".note.gnu"))
- {
- flags |= SEC_ELF_OCTETS;
- opb = 1;
- }
- else if (startswith (name, ".line")
- || startswith (name, ".stab")
- || strcmp (name, ".gdb_index") == 0)
- flags |= SEC_DEBUGGING;
- }
- }
-
- if (!bfd_set_section_vma (newsect, hdr->sh_addr / opb)
- || !bfd_set_section_size (newsect, hdr->sh_size)
- || !bfd_set_section_alignment (newsect, bfd_log2 (hdr->sh_addralign
- & -hdr->sh_addralign)))
- return false;
-
- /* As a GNU extension, if the name begins with .gnu.linkonce, we
- only link a single copy of the section. This is used to support
- g++. g++ will emit each template expansion in its own section.
- The symbols will be defined as weak, so that multiple definitions
- are permitted. The GNU linker extension is to actually discard
- all but one of the sections. */
- if (startswith (name, ".gnu.linkonce")
- && elf_next_in_group (newsect) == NULL)
- flags |= SEC_LINK_ONCE | SEC_LINK_DUPLICATES_DISCARD;
-
- if (!bfd_set_section_flags (newsect, flags))
- return false;
-
- bed = get_elf_backend_data (abfd);
- if (bed->elf_backend_section_flags)
- if (!bed->elf_backend_section_flags (hdr))
- return false;
-
- /* We do not parse the PT_NOTE segments as we are interested even in the
- separate debug info files which may have the segments offsets corrupted.
- PT_NOTEs from the core files are currently not parsed using BFD. */
- if (hdr->sh_type == SHT_NOTE && hdr->sh_size != 0)
- {
- bfd_byte *contents;
-
- if (!_bfd_elf_mmap_section_contents (abfd, newsect, &contents))
- return false;
-
- elf_parse_notes (abfd, (char *) contents, hdr->sh_size,
- hdr->sh_offset, hdr->sh_addralign);
- _bfd_elf_munmap_section_contents (newsect, contents);
- }
-
- if ((newsect->flags & SEC_ALLOC) != 0)
- {
- Elf_Internal_Phdr *phdr;
- unsigned int i, nload;
-
- /* Some ELF linkers produce binaries with all the program header
- p_paddr fields zero. If we have such a binary with more than
- one PT_LOAD header, then leave the section lma equal to vma
- so that we don't create sections with overlapping lma. */
- phdr = elf_tdata (abfd)->phdr;
- for (nload = 0, i = 0; i < elf_elfheader (abfd)->e_phnum; i++, phdr++)
- if (phdr->p_paddr != 0)
- break;
- else if (phdr->p_type == PT_LOAD && phdr->p_memsz != 0)
- ++nload;
- if (i >= elf_elfheader (abfd)->e_phnum && nload > 1)
- return true;
-
- phdr = elf_tdata (abfd)->phdr;
- for (i = 0; i < elf_elfheader (abfd)->e_phnum; i++, phdr++)
- {
- if (((phdr->p_type == PT_LOAD
- && (hdr->sh_flags & SHF_TLS) == 0)
- || phdr->p_type == PT_TLS)
- && ELF_SECTION_IN_SEGMENT (hdr, phdr))
- {
- if ((newsect->flags & SEC_LOAD) == 0)
- newsect->lma = (phdr->p_paddr
- + hdr->sh_addr - phdr->p_vaddr) / opb;
- else
- /* We used to use the same adjustment for SEC_LOAD
- sections, but that doesn't work if the segment
- is packed with code from multiple VMAs.
- Instead we calculate the section LMA based on
- the segment LMA. It is assumed that the
- segment will contain sections with contiguous
- LMAs, even if the VMAs are not. */
- newsect->lma = (phdr->p_paddr
- + hdr->sh_offset - phdr->p_offset) / opb;
-
- /* With contiguous segments, we can't tell from file
- offsets whether a section with zero size should
- be placed at the end of one segment or the
- beginning of the next. Decide based on vaddr. */
- if (hdr->sh_addr >= phdr->p_vaddr
- && (hdr->sh_addr + hdr->sh_size
- <= phdr->p_vaddr + phdr->p_memsz))
- break;
- }
- }
- }
-
- /* Compress/decompress DWARF debug sections with names: .debug_*,
- .zdebug_*, .gnu.debuglto_.debug_, after the section flags is set. */
- if ((newsect->flags & SEC_DEBUGGING) != 0
- && (newsect->flags & SEC_HAS_CONTENTS) != 0
- && (newsect->flags & SEC_ELF_OCTETS) != 0)
- {
- enum { nothing, compress, decompress } action = nothing;
- int compression_header_size;
- bfd_size_type uncompressed_size;
- unsigned int uncompressed_align_power;
- enum compression_type ch_type = ch_none;
- bool compressed
- = bfd_is_section_compressed_info (abfd, newsect,
- &compression_header_size,
- &uncompressed_size,
- &uncompressed_align_power,
- &ch_type);
-
- /* Should we decompress? */
- if ((abfd->flags & BFD_DECOMPRESS) != 0 && compressed)
- action = decompress;
-
- /* Should we compress? Or convert to a different compression? */
- else if ((abfd->flags & BFD_COMPRESS) != 0
- && newsect->size != 0
- && compression_header_size >= 0
- && uncompressed_size > 0)
- {
- if (!compressed)
- action = compress;
- else
- {
- enum compression_type new_ch_type = ch_none;
- if ((abfd->flags & BFD_COMPRESS_GABI) != 0)
- new_ch_type = ((abfd->flags & BFD_COMPRESS_ZSTD) != 0
- ? ch_compress_zstd : ch_compress_zlib);
- if (new_ch_type != ch_type)
- action = compress;
- }
- }
-
- if (action == compress)
- {
- if (!bfd_init_section_compress_status (abfd, newsect))
- {
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB: unable to compress section %s"), abfd, name);
- return false;
- }
- }
- else if (action == decompress)
- {
- if (!bfd_init_section_decompress_status (abfd, newsect))
- {
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB: unable to decompress section %s"), abfd, name);
- return false;
- }
-#ifndef HAVE_ZSTD
- if (newsect->compress_status == DECOMPRESS_SECTION_ZSTD)
- {
- _bfd_error_handler
- /* xgettext:c-format */
- (_ ("%pB: section %s is compressed with zstd, but BFD "
- "is not built with zstd support"),
- abfd, name);
- newsect->compress_status = COMPRESS_SECTION_NONE;
- return false;
- }
-#endif
- if (abfd->is_linker_input
- && name[1] == 'z')
- {
- /* Rename section from .zdebug_* to .debug_* so that ld
- scripts will see this section as a debug section. */
- char *new_name = bfd_zdebug_name_to_debug (abfd, name);
- if (new_name == NULL)
- return false;
- bfd_rename_section (newsect, new_name);
- }
- }
- }
-
- return true;
-}
-
-const char *const bfd_elf_section_type_names[] =
-{
- "SHT_NULL", "SHT_PROGBITS", "SHT_SYMTAB", "SHT_STRTAB",
- "SHT_RELA", "SHT_HASH", "SHT_DYNAMIC", "SHT_NOTE",
- "SHT_NOBITS", "SHT_REL", "SHT_SHLIB", "SHT_DYNSYM",
-};
-
-/* ELF relocs are against symbols. If we are producing relocatable
- output, and the reloc is against an external symbol, and nothing
- has given us any additional addend, the resulting reloc will also
- be against the same symbol. In such a case, we don't want to
- change anything about the way the reloc is handled, since it will
- all be done at final link time. Rather than put special case code
- into bfd_perform_relocation, all the reloc types use this howto
- function, or should call this function for relocatable output. */
-
-bfd_reloc_status_type
-bfd_elf_generic_reloc (bfd *abfd ATTRIBUTE_UNUSED,
- arelent *reloc_entry,
- asymbol *symbol,
- void *data ATTRIBUTE_UNUSED,
- asection *input_section,
- bfd *output_bfd,
- char **error_message ATTRIBUTE_UNUSED)
-{
- if (output_bfd != NULL
- && (symbol->flags & BSF_SECTION_SYM) == 0
- && (! reloc_entry->howto->partial_inplace
- || reloc_entry->addend == 0))
- {
- reloc_entry->address += input_section->output_offset;
- return bfd_reloc_ok;
- }
-
- /* In some cases the relocation should be treated as output section
- relative, as when linking ELF DWARF into PE COFF. Many ELF
- targets lack section relative relocations and instead use
- ordinary absolute relocations for references between DWARF
- sections. That is arguably a bug in those targets but it happens
- to work for the usual case of linking to non-loaded ELF debug
- sections with VMAs forced to zero. PE COFF on the other hand
- doesn't allow a section VMA of zero. */
- if (output_bfd == NULL
- && !reloc_entry->howto->pc_relative
- && (symbol->section->flags & SEC_DEBUGGING) != 0
- && (input_section->flags & SEC_DEBUGGING) != 0)
- reloc_entry->addend -= symbol->section->output_section->vma;
-
- return bfd_reloc_continue;
-}
-
-/* Returns TRUE if section A matches section B.
- Names, addresses and links may be different, but everything else
- should be the same. */
-
-static bool
-section_match (const Elf_Internal_Shdr * a,
- const Elf_Internal_Shdr * b)
-{
- if (a->sh_type != b->sh_type
- || ((a->sh_flags ^ b->sh_flags) & ~SHF_INFO_LINK) != 0
- || a->sh_addralign != b->sh_addralign
- || a->sh_entsize != b->sh_entsize)
- return false;
- if (a->sh_type == SHT_SYMTAB
- || a->sh_type == SHT_STRTAB)
- return true;
- return a->sh_size == b->sh_size;
-}
-
-/* Find a section in OBFD that has the same characteristics
- as IHEADER. Return the index of this section or SHN_UNDEF if
- none can be found. Check's section HINT first, as this is likely
- to be the correct section. */
-
-static unsigned int
-find_link (const bfd *obfd, const Elf_Internal_Shdr *iheader,
- const unsigned int hint)
-{
- Elf_Internal_Shdr ** oheaders = elf_elfsections (obfd);
- unsigned int i;
-
- BFD_ASSERT (iheader != NULL);
-
- /* See PR 20922 for a reproducer of the NULL test. */
- if (hint < elf_numsections (obfd)
- && oheaders[hint] != NULL
- && section_match (oheaders[hint], iheader))
- return hint;
-
- for (i = 1; i < elf_numsections (obfd); i++)
- {
- Elf_Internal_Shdr * oheader = oheaders[i];
-
- if (oheader == NULL)
- continue;
- if (section_match (oheader, iheader))
- /* FIXME: Do we care if there is a potential for
- multiple matches ? */
- return i;
- }
-
- return SHN_UNDEF;
-}
-
-/* PR 19938: Attempt to set the ELF section header fields of an OS or
- Processor specific section, based upon a matching input section.
- Returns TRUE upon success, FALSE otherwise. */
-
-static bool
-copy_special_section_fields (const bfd *ibfd,
- bfd *obfd,
- const Elf_Internal_Shdr *iheader,
- Elf_Internal_Shdr *oheader,
- const unsigned int secnum)
-{
- const struct elf_backend_data *bed = get_elf_backend_data (obfd);
- const Elf_Internal_Shdr **iheaders
- = (const Elf_Internal_Shdr **) elf_elfsections (ibfd);
- bool changed = false;
- unsigned int sh_link;
-
- if (oheader->sh_type == SHT_NOBITS)
- {
- /* This is a feature for objcopy --only-keep-debug:
- When a section's type is changed to NOBITS, we preserve
- the sh_link and sh_info fields so that they can be
- matched up with the original.
-
- Note: Strictly speaking these assignments are wrong.
- The sh_link and sh_info fields should point to the
- relevent sections in the output BFD, which may not be in
- the same location as they were in the input BFD. But
- the whole point of this action is to preserve the
- original values of the sh_link and sh_info fields, so
- that they can be matched up with the section headers in
- the original file. So strictly speaking we may be
- creating an invalid ELF file, but it is only for a file
- that just contains debug info and only for sections
- without any contents. */
- if (oheader->sh_link == 0)
- oheader->sh_link = iheader->sh_link;
- if (oheader->sh_info == 0)
- oheader->sh_info = iheader->sh_info;
- return true;
- }
-
- /* Allow the target a chance to decide how these fields should be set. */
- if (bed->elf_backend_copy_special_section_fields (ibfd, obfd,
- iheader, oheader))
- return true;
-
- /* We have an iheader which might match oheader, and which has non-zero
- sh_info and/or sh_link fields. Attempt to follow those links and find
- the section in the output bfd which corresponds to the linked section
- in the input bfd. */
- if (iheader->sh_link != SHN_UNDEF)
- {
- /* See PR 20931 for a reproducer. */
- if (iheader->sh_link >= elf_numsections (ibfd))
- {
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB: invalid sh_link field (%d) in section number %d"),
- ibfd, iheader->sh_link, secnum);
- return false;
- }
-
- sh_link = find_link (obfd, iheaders[iheader->sh_link], iheader->sh_link);
- if (sh_link != SHN_UNDEF)
- {
- oheader->sh_link = sh_link;
- changed = true;
- }
- else
- /* FIXME: Should we install iheader->sh_link
- if we could not find a match ? */
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB: failed to find link section for section %d"), obfd, secnum);
- }
-
- if (iheader->sh_info)
- {
- /* The sh_info field can hold arbitrary information, but if the
- SHF_LINK_INFO flag is set then it should be interpreted as a
- section index. */
- if (iheader->sh_flags & SHF_INFO_LINK)
- {
- sh_link = find_link (obfd, iheaders[iheader->sh_info],
- iheader->sh_info);
- if (sh_link != SHN_UNDEF)
- oheader->sh_flags |= SHF_INFO_LINK;
- }
- else
- /* No idea what it means - just copy it. */
- sh_link = iheader->sh_info;
-
- if (sh_link != SHN_UNDEF)
- {
- oheader->sh_info = sh_link;
- changed = true;
- }
- else
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB: failed to find info section for section %d"), obfd, secnum);
- }
-
- return changed;
-}
-
-/* Copy the program header and other data from one object module to
- another. */
-
-bool
-_bfd_elf_copy_private_bfd_data (bfd *ibfd, bfd *obfd)
-{
- const Elf_Internal_Shdr **iheaders
- = (const Elf_Internal_Shdr **) elf_elfsections (ibfd);
- Elf_Internal_Shdr **oheaders = elf_elfsections (obfd);
- const struct elf_backend_data *bed;
- unsigned int i;
-
- if (bfd_get_flavour (ibfd) != bfd_target_elf_flavour
- || bfd_get_flavour (obfd) != bfd_target_elf_flavour)
- return true;
-
- if (!elf_flags_init (obfd))
- {
- elf_elfheader (obfd)->e_flags = elf_elfheader (ibfd)->e_flags;
- elf_flags_init (obfd) = true;
- }
-
- elf_gp (obfd) = elf_gp (ibfd);
-
- /* Also copy the EI_OSABI field. */
- elf_elfheader (obfd)->e_ident[EI_OSABI] =
- elf_elfheader (ibfd)->e_ident[EI_OSABI];
-
- /* If set, copy the EI_ABIVERSION field. */
- if (elf_elfheader (ibfd)->e_ident[EI_ABIVERSION])
- elf_elfheader (obfd)->e_ident[EI_ABIVERSION]
- = elf_elfheader (ibfd)->e_ident[EI_ABIVERSION];
-
- /* Copy object attributes. */
- _bfd_elf_copy_obj_attributes (ibfd, obfd);
-
- if (iheaders == NULL || oheaders == NULL)
- return true;
-
- bed = get_elf_backend_data (obfd);
-
- /* Possibly copy other fields in the section header. */
- for (i = 1; i < elf_numsections (obfd); i++)
- {
- unsigned int j;
- Elf_Internal_Shdr * oheader = oheaders[i];
-
- /* Ignore ordinary sections. SHT_NOBITS sections are considered however
- because of a special case need for generating separate debug info
- files. See below for more details. */
- if (oheader == NULL
- || (oheader->sh_type != SHT_NOBITS
- && oheader->sh_type < SHT_LOOS))
- continue;
-
- /* Ignore empty sections, and sections whose
- fields have already been initialised. */
- if (oheader->sh_size == 0
- || (oheader->sh_info != 0 && oheader->sh_link != 0))
- continue;
-
- /* Scan for the matching section in the input bfd.
- First we try for a direct mapping between the input and
- output sections. */
- for (j = 1; j < elf_numsections (ibfd); j++)
- {
- const Elf_Internal_Shdr * iheader = iheaders[j];
-
- if (iheader == NULL)
- continue;
-
- if (oheader->bfd_section != NULL
- && iheader->bfd_section != NULL
- && iheader->bfd_section->output_section != NULL
- && iheader->bfd_section->output_section == oheader->bfd_section)
- {
- /* We have found a connection from the input section to
- the output section. Attempt to copy the header fields.
- If this fails then do not try any further sections -
- there should only be a one-to-one mapping between
- input and output. */
- if (!copy_special_section_fields (ibfd, obfd,
- iheader, oheader, i))
- j = elf_numsections (ibfd);
- break;
- }
- }
-
- if (j < elf_numsections (ibfd))
- continue;
-
- /* That failed. So try to deduce the corresponding input section.
- Unfortunately we cannot compare names as the output string table
- is empty, so instead we check size, address and type. */
- for (j = 1; j < elf_numsections (ibfd); j++)
- {
- const Elf_Internal_Shdr * iheader = iheaders[j];
-
- if (iheader == NULL)
- continue;
-
- /* Try matching fields in the input section's header.
- Since --only-keep-debug turns all non-debug sections into
- SHT_NOBITS sections, the output SHT_NOBITS type matches any
- input type. */
- if ((oheader->sh_type == SHT_NOBITS
- || iheader->sh_type == oheader->sh_type)
- && (iheader->sh_flags & ~ SHF_INFO_LINK)
- == (oheader->sh_flags & ~ SHF_INFO_LINK)
- && iheader->sh_addralign == oheader->sh_addralign
- && iheader->sh_entsize == oheader->sh_entsize
- && iheader->sh_size == oheader->sh_size
- && iheader->sh_addr == oheader->sh_addr
- && (iheader->sh_info != oheader->sh_info
- || iheader->sh_link != oheader->sh_link))
- {
- if (copy_special_section_fields (ibfd, obfd, iheader, oheader, i))
- break;
- }
- }
-
- if (j == elf_numsections (ibfd) && oheader->sh_type >= SHT_LOOS)
- {
- /* Final attempt. Call the backend copy function
- with a NULL input section. */
- (void) bed->elf_backend_copy_special_section_fields (ibfd, obfd,
- NULL, oheader);
- }
- }
-
- /* If the input BFD has the OSABI field set and the
- output BFD does not, then copy the value. */
- if (elf_elfheader (ibfd)->e_ident [EI_OSABI] != ELFOSABI_NONE
- && elf_elfheader (obfd)->e_ident [EI_OSABI] == ELFOSABI_NONE)
- elf_elfheader (obfd)->e_ident [EI_OSABI] =
- elf_elfheader (ibfd)->e_ident [EI_OSABI];
-
- return true;
-}
-
-static const char *
-get_segment_type (unsigned int p_type)
-{
- const char *pt;
- switch (p_type)
- {
- case PT_NULL: pt = "NULL"; break;
- case PT_LOAD: pt = "LOAD"; break;
- case PT_DYNAMIC: pt = "DYNAMIC"; break;
- case PT_INTERP: pt = "INTERP"; break;
- case PT_NOTE: pt = "NOTE"; break;
- case PT_SHLIB: pt = "SHLIB"; break;
- case PT_PHDR: pt = "PHDR"; break;
- case PT_TLS: pt = "TLS"; break;
- case PT_GNU_EH_FRAME: pt = "EH_FRAME"; break;
- case PT_GNU_STACK: pt = "STACK"; break;
- case PT_GNU_RELRO: pt = "RELRO"; break;
- case PT_GNU_SFRAME: pt = "SFRAME"; break;
- default: pt = NULL; break;
- }
- return pt;
-}
-
-/* Print out the program headers. */
-
-bool
-_bfd_elf_print_private_bfd_data (bfd *abfd, void *farg)
-{
- FILE *f = (FILE *) farg;
- Elf_Internal_Phdr *p;
- asection *s;
- bfd_byte *dynbuf = NULL;
-
- p = elf_tdata (abfd)->phdr;
- if (p != NULL)
- {
- unsigned int i, c;
-
- fprintf (f, _("\nProgram Header:\n"));
- c = elf_elfheader (abfd)->e_phnum;
- for (i = 0; i < c; i++, p++)
- {
- const char *pt = get_segment_type (p->p_type);
- char buf[20];
-
- if (pt == NULL)
- {
- sprintf (buf, "0x%lx", p->p_type);
- pt = buf;
- }
- fprintf (f, "%8s off 0x", pt);
- bfd_fprintf_vma (abfd, f, p->p_offset);
- fprintf (f, " vaddr 0x");
- bfd_fprintf_vma (abfd, f, p->p_vaddr);
- fprintf (f, " paddr 0x");
- bfd_fprintf_vma (abfd, f, p->p_paddr);
- fprintf (f, " align 2**%u\n", bfd_log2 (p->p_align));
- fprintf (f, " filesz 0x");
- bfd_fprintf_vma (abfd, f, p->p_filesz);
- fprintf (f, " memsz 0x");
- bfd_fprintf_vma (abfd, f, p->p_memsz);
- fprintf (f, " flags %c%c%c",
- (p->p_flags & PF_R) != 0 ? 'r' : '-',
- (p->p_flags & PF_W) != 0 ? 'w' : '-',
- (p->p_flags & PF_X) != 0 ? 'x' : '-');
- if ((p->p_flags &~ (unsigned) (PF_R | PF_W | PF_X)) != 0)
- fprintf (f, " %lx", p->p_flags &~ (unsigned) (PF_R | PF_W | PF_X));
- fprintf (f, "\n");
- }
- }
-
- s = bfd_get_section_by_name (abfd, ".dynamic");
- if (s != NULL && (s->flags & SEC_HAS_CONTENTS) != 0)
- {
- unsigned int elfsec;
- unsigned long shlink;
- bfd_byte *extdyn, *extdynend;
- size_t extdynsize;
- void (*swap_dyn_in) (bfd *, const void *, Elf_Internal_Dyn *);
-
- fprintf (f, _("\nDynamic Section:\n"));
-
- if (!_bfd_elf_mmap_section_contents (abfd, s, &dynbuf))
- goto error_return;
-
- elfsec = _bfd_elf_section_from_bfd_section (abfd, s);
- if (elfsec == SHN_BAD)
- goto error_return;
- shlink = elf_elfsections (abfd)[elfsec]->sh_link;
-
- extdynsize = get_elf_backend_data (abfd)->s->sizeof_dyn;
- swap_dyn_in = get_elf_backend_data (abfd)->s->swap_dyn_in;
-
- for (extdyn = dynbuf, extdynend = dynbuf + s->size;
- (size_t) (extdynend - extdyn) >= extdynsize;
- extdyn += extdynsize)
- {
- Elf_Internal_Dyn dyn;
- const char *name = "";
- char ab[20];
- bool stringp;
- const struct elf_backend_data *bed = get_elf_backend_data (abfd);
-
- (*swap_dyn_in) (abfd, extdyn, &dyn);
-
- if (dyn.d_tag == DT_NULL)
- break;
-
- stringp = false;
- switch (dyn.d_tag)
- {
- default:
- if (bed->elf_backend_get_target_dtag)
- name = (*bed->elf_backend_get_target_dtag) (dyn.d_tag);
-
- if (!strcmp (name, ""))
- {
- sprintf (ab, "%#" PRIx64, (uint64_t) dyn.d_tag);
- name = ab;
- }
- break;
-
- case DT_NEEDED: name = "NEEDED"; stringp = true; break;
- case DT_PLTRELSZ: name = "PLTRELSZ"; break;
- case DT_PLTGOT: name = "PLTGOT"; break;
- case DT_HASH: name = "HASH"; break;
- case DT_STRTAB: name = "STRTAB"; break;
- case DT_SYMTAB: name = "SYMTAB"; break;
- case DT_RELA: name = "RELA"; break;
- case DT_RELASZ: name = "RELASZ"; break;
- case DT_RELAENT: name = "RELAENT"; break;
- case DT_STRSZ: name = "STRSZ"; break;
- case DT_SYMENT: name = "SYMENT"; break;
- case DT_INIT: name = "INIT"; break;
- case DT_FINI: name = "FINI"; break;
- case DT_SONAME: name = "SONAME"; stringp = true; break;
- case DT_RPATH: name = "RPATH"; stringp = true; break;
- case DT_SYMBOLIC: name = "SYMBOLIC"; break;
- case DT_REL: name = "REL"; break;
- case DT_RELSZ: name = "RELSZ"; break;
- case DT_RELENT: name = "RELENT"; break;
- case DT_RELR: name = "RELR"; break;
- case DT_RELRSZ: name = "RELRSZ"; break;
- case DT_RELRENT: name = "RELRENT"; break;
- case DT_PLTREL: name = "PLTREL"; break;
- case DT_DEBUG: name = "DEBUG"; break;
- case DT_TEXTREL: name = "TEXTREL"; break;
- case DT_JMPREL: name = "JMPREL"; break;
- case DT_BIND_NOW: name = "BIND_NOW"; break;
- case DT_INIT_ARRAY: name = "INIT_ARRAY"; break;
- case DT_FINI_ARRAY: name = "FINI_ARRAY"; break;
- case DT_INIT_ARRAYSZ: name = "INIT_ARRAYSZ"; break;
- case DT_FINI_ARRAYSZ: name = "FINI_ARRAYSZ"; break;
- case DT_RUNPATH: name = "RUNPATH"; stringp = true; break;
- case DT_FLAGS: name = "FLAGS"; break;
- case DT_PREINIT_ARRAY: name = "PREINIT_ARRAY"; break;
- case DT_PREINIT_ARRAYSZ: name = "PREINIT_ARRAYSZ"; break;
- case DT_CHECKSUM: name = "CHECKSUM"; break;
- case DT_PLTPADSZ: name = "PLTPADSZ"; break;
- case DT_MOVEENT: name = "MOVEENT"; break;
- case DT_MOVESZ: name = "MOVESZ"; break;
- case DT_FEATURE: name = "FEATURE"; break;
- case DT_POSFLAG_1: name = "POSFLAG_1"; break;
- case DT_SYMINSZ: name = "SYMINSZ"; break;
- case DT_SYMINENT: name = "SYMINENT"; break;
- case DT_CONFIG: name = "CONFIG"; stringp = true; break;
- case DT_DEPAUDIT: name = "DEPAUDIT"; stringp = true; break;
- case DT_AUDIT: name = "AUDIT"; stringp = true; break;
- case DT_PLTPAD: name = "PLTPAD"; break;
- case DT_MOVETAB: name = "MOVETAB"; break;
- case DT_SYMINFO: name = "SYMINFO"; break;
- case DT_RELACOUNT: name = "RELACOUNT"; break;
- case DT_RELCOUNT: name = "RELCOUNT"; break;
- case DT_FLAGS_1: name = "FLAGS_1"; break;
- case DT_VERSYM: name = "VERSYM"; break;
- case DT_VERDEF: name = "VERDEF"; break;
- case DT_VERDEFNUM: name = "VERDEFNUM"; break;
- case DT_VERNEED: name = "VERNEED"; break;
- case DT_VERNEEDNUM: name = "VERNEEDNUM"; break;
- case DT_AUXILIARY: name = "AUXILIARY"; stringp = true; break;
- case DT_USED: name = "USED"; break;
- case DT_FILTER: name = "FILTER"; stringp = true; break;
- case DT_GNU_HASH: name = "GNU_HASH"; break;
- }
-
- fprintf (f, " %-20s ", name);
- if (! stringp)
- {
- fprintf (f, "0x");
- bfd_fprintf_vma (abfd, f, dyn.d_un.d_val);
- }
- else
- {
- const char *string;
- unsigned int tagv = dyn.d_un.d_val;
-
- string = bfd_elf_string_from_elf_section (abfd, shlink, tagv);
- if (string == NULL)
- goto error_return;
- fprintf (f, "%s", string);
- }
- fprintf (f, "\n");
- }
-
- _bfd_elf_munmap_section_contents (s, dynbuf);
- dynbuf = NULL;
- }
-
- if ((elf_dynverdef (abfd) != 0 && elf_tdata (abfd)->verdef == NULL)
- || (elf_dynverref (abfd) != 0 && elf_tdata (abfd)->verref == NULL))
- {
- if (! _bfd_elf_slurp_version_tables (abfd, false))
- return false;
- }
-
- if (elf_dynverdef (abfd) != 0)
- {
- Elf_Internal_Verdef *t;
-
- fprintf (f, _("\nVersion definitions:\n"));
- for (t = elf_tdata (abfd)->verdef; t != NULL; t = t->vd_nextdef)
- {
- fprintf (f, "%d 0x%2.2x 0x%8.8lx %s\n", t->vd_ndx,
- t->vd_flags, t->vd_hash,
- t->vd_nodename ? t->vd_nodename : "<corrupt>");
- if (t->vd_auxptr != NULL && t->vd_auxptr->vda_nextptr != NULL)
- {
- Elf_Internal_Verdaux *a;
-
- fprintf (f, "\t");
- for (a = t->vd_auxptr->vda_nextptr;
- a != NULL;
- a = a->vda_nextptr)
- fprintf (f, "%s ",
- a->vda_nodename ? a->vda_nodename : "<corrupt>");
- fprintf (f, "\n");
- }
- }
- }
-
- if (elf_dynverref (abfd) != 0)
- {
- Elf_Internal_Verneed *t;
-
- fprintf (f, _("\nVersion References:\n"));
- for (t = elf_tdata (abfd)->verref; t != NULL; t = t->vn_nextref)
- {
- Elf_Internal_Vernaux *a;
-
- fprintf (f, _(" required from %s:\n"),
- t->vn_filename ? t->vn_filename : "<corrupt>");
- for (a = t->vn_auxptr; a != NULL; a = a->vna_nextptr)
- fprintf (f, " 0x%8.8lx 0x%2.2x %2.2d %s\n", a->vna_hash,
- a->vna_flags, a->vna_other,
- a->vna_nodename ? a->vna_nodename : "<corrupt>");
- }
- }
-
- return true;
-
- error_return:
- _bfd_elf_munmap_section_contents (s, dynbuf);
- return false;
-}
-
-/* Find the file offset corresponding to VMA by using the program
- headers. */
-
-static file_ptr
-offset_from_vma (Elf_Internal_Phdr *phdrs, size_t phnum, bfd_vma vma,
- size_t size, size_t *max_size_p)
-{
- Elf_Internal_Phdr *seg;
- size_t i;
-
- for (seg = phdrs, i = 0; i < phnum; ++seg, ++i)
- if (seg->p_type == PT_LOAD
- && vma >= (seg->p_vaddr & -seg->p_align)
- && vma + size <= seg->p_vaddr + seg->p_filesz)
- {
- if (max_size_p)
- *max_size_p = seg->p_vaddr + seg->p_filesz - vma;
- return vma - seg->p_vaddr + seg->p_offset;
- }
-
- if (max_size_p)
- *max_size_p = 0;
- bfd_set_error (bfd_error_invalid_operation);
- return (file_ptr) -1;
-}
-
-/* Convert hash table to internal form. */
-
-static bfd_vma *
-get_hash_table_data (bfd *abfd, bfd_size_type number,
- unsigned int ent_size, bfd_size_type filesize)
-{
- unsigned char *e_data = NULL;
- bfd_vma *i_data = NULL;
- bfd_size_type size;
- void *e_data_addr;
- size_t e_data_size ATTRIBUTE_UNUSED;
-
- if (ent_size != 4 && ent_size != 8)
- return NULL;
-
- if ((size_t) number != number)
- {
- bfd_set_error (bfd_error_file_too_big);
- return NULL;
- }
-
- size = ent_size * number;
- /* Be kind to memory checkers (eg valgrind, address sanitizer) by not
- attempting to allocate memory when the read is bound to fail. */
- if (size > filesize
- || number >= ~(size_t) 0 / ent_size
- || number >= ~(size_t) 0 / sizeof (*i_data))
- {
- bfd_set_error (bfd_error_file_too_big);
- return NULL;
- }
-
- e_data = _bfd_mmap_readonly_temporary (abfd, size, &e_data_addr,
- &e_data_size);
- if (e_data == NULL)
- return NULL;
-
- i_data = (bfd_vma *) bfd_malloc (number * sizeof (*i_data));
- if (i_data == NULL)
- {
- free (e_data);
- return NULL;
- }
-
- if (ent_size == 4)
- while (number--)
- i_data[number] = bfd_get_32 (abfd, e_data + number * ent_size);
- else
- while (number--)
- i_data[number] = bfd_get_64 (abfd, e_data + number * ent_size);
-
- _bfd_munmap_readonly_temporary (e_data_addr, e_data_size);
- return i_data;
-}
-
-/* Address of .MIPS.xhash section. FIXME: What is the best way to
- support DT_MIPS_XHASH? */
-#define DT_MIPS_XHASH 0x70000036
-
-/* Reconstruct dynamic symbol table from PT_DYNAMIC segment. */
-
-bool
-_bfd_elf_get_dynamic_symbols (bfd *abfd, Elf_Internal_Phdr *phdr,
- Elf_Internal_Phdr *phdrs, size_t phnum,
- bfd_size_type filesize)
-{
- bfd_byte *extdyn, *extdynend;
- size_t extdynsize;
- void (*swap_dyn_in) (bfd *, const void *, Elf_Internal_Dyn *);
- bool (*swap_symbol_in) (bfd *, const void *, const void *,
- Elf_Internal_Sym *);
- Elf_Internal_Dyn dyn;
- bfd_vma dt_hash = 0;
- bfd_vma dt_gnu_hash = 0;
- bfd_vma dt_mips_xhash = 0;
- bfd_vma dt_strtab = 0;
- bfd_vma dt_symtab = 0;
- size_t dt_strsz = 0;
- bfd_vma dt_versym = 0;
- bfd_vma dt_verdef = 0;
- bfd_vma dt_verneed = 0;
- bfd_byte *dynbuf = NULL;
- char *strbuf = NULL;
- bfd_vma *gnubuckets = NULL;
- bfd_vma *gnuchains = NULL;
- bfd_vma *mipsxlat = NULL;
- file_ptr saved_filepos, filepos;
- bool res = false;
- size_t amt;
- bfd_byte *esymbuf = NULL, *esym;
- bfd_size_type symcount;
- Elf_Internal_Sym *isymbuf = NULL;
- Elf_Internal_Sym *isym, *isymend;
- bfd_byte *versym = NULL;
- bfd_byte *verdef = NULL;
- bfd_byte *verneed = NULL;
- size_t verdef_size = 0;
- size_t verneed_size = 0;
- size_t extsym_size;
- const struct elf_backend_data *bed;
- void *dynbuf_addr = NULL;
- void *esymbuf_addr = NULL;
- size_t dynbuf_size = 0;
- size_t esymbuf_size = 0;
-
- /* Return TRUE if symbol table is bad. */
- if (elf_bad_symtab (abfd))
- return true;
-
- /* Return TRUE if DT_HASH/DT_GNU_HASH have bee processed before. */
- if (elf_tdata (abfd)->dt_strtab != NULL)
- return true;
-
- bed = get_elf_backend_data (abfd);
-
- /* Save file position for elf_object_p. */
- saved_filepos = bfd_tell (abfd);
-
- if (bfd_seek (abfd, phdr->p_offset, SEEK_SET) != 0)
- goto error_return;
-
- dynbuf_size = phdr->p_filesz;
- dynbuf = _bfd_mmap_readonly_temporary (abfd, dynbuf_size,
- &dynbuf_addr, &dynbuf_size);
- if (dynbuf == NULL)
- goto error_return;
-
- extsym_size = bed->s->sizeof_sym;
- extdynsize = bed->s->sizeof_dyn;
- swap_dyn_in = bed->s->swap_dyn_in;
-
- extdyn = dynbuf;
- if (phdr->p_filesz < extdynsize)
- goto error_return;
- extdynend = extdyn + phdr->p_filesz;
- for (; extdyn <= (extdynend - extdynsize); extdyn += extdynsize)
- {
- swap_dyn_in (abfd, extdyn, &dyn);
-
- if (dyn.d_tag == DT_NULL)
- break;
-
- switch (dyn.d_tag)
- {
- case DT_HASH:
- dt_hash = dyn.d_un.d_val;
- break;
- case DT_GNU_HASH:
- if (bed->elf_machine_code != EM_MIPS
- && bed->elf_machine_code != EM_MIPS_RS3_LE)
- dt_gnu_hash = dyn.d_un.d_val;
- break;
- case DT_STRTAB:
- dt_strtab = dyn.d_un.d_val;
- break;
- case DT_SYMTAB:
- dt_symtab = dyn.d_un.d_val;
- break;
- case DT_STRSZ:
- dt_strsz = dyn.d_un.d_val;
- break;
- case DT_SYMENT:
- if (dyn.d_un.d_val != extsym_size)
- goto error_return;
- break;
- case DT_VERSYM:
- dt_versym = dyn.d_un.d_val;
- break;
- case DT_VERDEF:
- dt_verdef = dyn.d_un.d_val;
- break;
- case DT_VERNEED:
- dt_verneed = dyn.d_un.d_val;
- break;
- default:
- if (dyn.d_tag == DT_MIPS_XHASH
- && (bed->elf_machine_code == EM_MIPS
- || bed->elf_machine_code == EM_MIPS_RS3_LE))
- {
- dt_gnu_hash = dyn.d_un.d_val;
- dt_mips_xhash = dyn.d_un.d_val;
- }
- break;
- }
- }
-
- /* Check if we can reconstruct dynamic symbol table from PT_DYNAMIC
- segment. */
- if ((!dt_hash && !dt_gnu_hash)
- || !dt_strtab
- || !dt_symtab
- || !dt_strsz)
- goto error_return;
-
- /* Get dynamic string table. */
- filepos = offset_from_vma (phdrs, phnum, dt_strtab, dt_strsz, NULL);
- if (filepos == (file_ptr) -1
- || bfd_seek (abfd, filepos, SEEK_SET) != 0)
- goto error_return;
-
- /* Dynamic string table must be valid until ABFD is closed. */
- strbuf = (char *) _bfd_mmap_readonly_persistent (abfd, dt_strsz);
- if (strbuf == NULL)
- goto error_return;
- if (strbuf[dt_strsz - 1] != 0)
- {
- /* It is an error if a string table is't terminated. */
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB: DT_STRTAB table is corrupt"), abfd);
- goto error_return;
- }
-
- /* Get the real symbol count from DT_HASH or DT_GNU_HASH. Prefer
- DT_HASH since it is simpler than DT_GNU_HASH. */
- if (dt_hash)
- {
- unsigned char nb[16];
- unsigned int hash_ent_size;
-
- switch (bed->elf_machine_code)
- {
- case EM_ALPHA:
- case EM_S390:
- case EM_S390_OLD:
- if (bed->s->elfclass == ELFCLASS64)
- {
- hash_ent_size = 8;
- break;
- }
- /* FALLTHROUGH */
- default:
- hash_ent_size = 4;
- break;
- }
-
- filepos = offset_from_vma (phdrs, phnum, dt_hash, sizeof (nb),
- NULL);
- if (filepos == (file_ptr) -1
- || bfd_seek (abfd, filepos, SEEK_SET) != 0
- || bfd_read (nb, 2 * hash_ent_size, abfd) != 2 * hash_ent_size)
- goto error_return;
-
- /* The number of dynamic symbol table entries equals the number
- of chains. */
- if (hash_ent_size == 8)
- symcount = bfd_get_64 (abfd, nb + hash_ent_size);
- else
- symcount = bfd_get_32 (abfd, nb + hash_ent_size);
- }
- else
- {
- /* For DT_GNU_HASH, only defined symbols with non-STB_LOCAL
- bindings are in hash table. Since in dynamic symbol table,
- all symbols with STB_LOCAL binding are placed before symbols
- with other bindings and all undefined symbols are placed
- before defined ones, the highest symbol index in DT_GNU_HASH
- is the highest dynamic symbol table index. */
- unsigned char nb[16];
- bfd_vma ngnubuckets;
- bfd_vma gnusymidx;
- size_t i, ngnuchains;
- bfd_vma maxchain = 0xffffffff, bitmaskwords;
- bfd_vma buckets_vma;
-
- filepos = offset_from_vma (phdrs, phnum, dt_gnu_hash,
- sizeof (nb), NULL);
- if (filepos == (file_ptr) -1
- || bfd_seek (abfd, filepos, SEEK_SET) != 0
- || bfd_read (nb, sizeof (nb), abfd) != sizeof (nb))
- goto error_return;
-
- ngnubuckets = bfd_get_32 (abfd, nb);
- gnusymidx = bfd_get_32 (abfd, nb + 4);
- bitmaskwords = bfd_get_32 (abfd, nb + 8);
- buckets_vma = dt_gnu_hash + 16;
- if (bed->s->elfclass == ELFCLASS32)
- buckets_vma += bitmaskwords * 4;
- else
- buckets_vma += bitmaskwords * 8;
- filepos = offset_from_vma (phdrs, phnum, buckets_vma, 4, NULL);
- if (filepos == (file_ptr) -1
- || bfd_seek (abfd, filepos, SEEK_SET) != 0)
- goto error_return;
-
- gnubuckets = get_hash_table_data (abfd, ngnubuckets, 4, filesize);
- if (gnubuckets == NULL)
- goto error_return;
-
- for (i = 0; i < ngnubuckets; i++)
- if (gnubuckets[i] != 0)
- {
- if (gnubuckets[i] < gnusymidx)
- goto error_return;
-
- if (maxchain == 0xffffffff || gnubuckets[i] > maxchain)
- maxchain = gnubuckets[i];
- }
-
- if (maxchain == 0xffffffff)
- {
- symcount = 0;
- goto empty_gnu_hash;
- }
-
- maxchain -= gnusymidx;
- filepos = offset_from_vma (phdrs, phnum,
- (buckets_vma +
- 4 * (ngnubuckets + maxchain)),
- 4, NULL);
- if (filepos == (file_ptr) -1
- || bfd_seek (abfd, filepos, SEEK_SET) != 0)
- goto error_return;
-
- do
- {
- if (bfd_read (nb, 4, abfd) != 4)
- goto error_return;
- ++maxchain;
- if (maxchain == 0)
- goto error_return;
- }
- while ((bfd_get_32 (abfd, nb) & 1) == 0);
-
- filepos = offset_from_vma (phdrs, phnum,
- (buckets_vma + 4 * ngnubuckets),
- 4, NULL);
- if (filepos == (file_ptr) -1
- || bfd_seek (abfd, filepos, SEEK_SET) != 0)
- goto error_return;
-
- gnuchains = get_hash_table_data (abfd, maxchain, 4, filesize);
- if (gnuchains == NULL)
- goto error_return;
- ngnuchains = maxchain;
-
- if (dt_mips_xhash)
- {
- filepos = offset_from_vma (phdrs, phnum,
- (buckets_vma
- + 4 * (ngnubuckets + maxchain)),
- 4, NULL);
- if (filepos == (file_ptr) -1
- || bfd_seek (abfd, filepos, SEEK_SET) != 0)
- goto error_return;
-
- mipsxlat = get_hash_table_data (abfd, maxchain, 4, filesize);
- if (mipsxlat == NULL)
- goto error_return;
- }
-
- symcount = 0;
- for (i = 0; i < ngnubuckets; ++i)
- if (gnubuckets[i] != 0)
- {
- bfd_vma si = gnubuckets[i];
- bfd_vma off = si - gnusymidx;
- do
- {
- if (mipsxlat)
- {
- if (mipsxlat[off] >= symcount)
- symcount = mipsxlat[off] + 1;
- }
- else
- {
- if (si >= symcount)
- symcount = si + 1;
- }
- si++;
- }
- while (off < ngnuchains && (gnuchains[off++] & 1) == 0);
- }
- }
-
- /* Swap in dynamic symbol table. */
- if (_bfd_mul_overflow (symcount, extsym_size, &amt))
- {
- bfd_set_error (bfd_error_file_too_big);
- goto error_return;
- }
-
- filepos = offset_from_vma (phdrs, phnum, dt_symtab, amt, NULL);
- if (filepos == (file_ptr) -1
- || bfd_seek (abfd, filepos, SEEK_SET) != 0)
- goto error_return;
- esymbuf_size = amt;
- esymbuf = _bfd_mmap_readonly_temporary (abfd, esymbuf_size,
- &esymbuf_addr,
- &esymbuf_size);
- if (esymbuf == NULL)
- goto error_return;
-
- if (_bfd_mul_overflow (symcount, sizeof (Elf_Internal_Sym), &amt))
- {
- bfd_set_error (bfd_error_file_too_big);
- goto error_return;
- }
-
- /* Dynamic symbol table must be valid until ABFD is closed. */
- isymbuf = (Elf_Internal_Sym *) bfd_alloc (abfd, amt);
- if (isymbuf == NULL)
- goto error_return;
-
- swap_symbol_in = bed->s->swap_symbol_in;
-
- /* Convert the symbols to internal form. */
- isymend = isymbuf + symcount;
- for (esym = esymbuf, isym = isymbuf;
- isym < isymend;
- esym += extsym_size, isym++)
- if (!swap_symbol_in (abfd, esym, NULL, isym)
- || isym->st_name >= dt_strsz)
- {
- bfd_set_error (bfd_error_invalid_operation);
- goto error_return;
- }
-
- if (dt_versym)
- {
- /* Swap in DT_VERSYM. */
- if (_bfd_mul_overflow (symcount, 2, &amt))
- {
- bfd_set_error (bfd_error_file_too_big);
- goto error_return;
- }
-
- filepos = offset_from_vma (phdrs, phnum, dt_versym, amt, NULL);
- if (filepos == (file_ptr) -1
- || bfd_seek (abfd, filepos, SEEK_SET) != 0)
- goto error_return;
-
- /* DT_VERSYM info must be valid until ABFD is closed. */
- versym = _bfd_mmap_readonly_persistent (abfd, amt);
-
- if (dt_verdef)
- {
- /* Read in DT_VERDEF. */
- filepos = offset_from_vma (phdrs, phnum, dt_verdef,
- 0, &verdef_size);
- if (filepos == (file_ptr) -1
- || bfd_seek (abfd, filepos, SEEK_SET) != 0)
- goto error_return;
-
- /* DT_VERDEF info must be valid until ABFD is closed. */
- verdef = _bfd_mmap_readonly_persistent (abfd, verdef_size);
- }
-
- if (dt_verneed)
- {
- /* Read in DT_VERNEED. */
- filepos = offset_from_vma (phdrs, phnum, dt_verneed,
- 0, &verneed_size);
- if (filepos == (file_ptr) -1
- || bfd_seek (abfd, filepos, SEEK_SET) != 0)
- goto error_return;
-
- /* DT_VERNEED info must be valid until ABFD is closed. */
- verneed = _bfd_mmap_readonly_persistent (abfd, verneed_size);
- }
- }
-
- empty_gnu_hash:
- elf_tdata (abfd)->dt_strtab = strbuf;
- elf_tdata (abfd)->dt_strsz = dt_strsz;
- elf_tdata (abfd)->dt_symtab = isymbuf;
- elf_tdata (abfd)->dt_symtab_count = symcount;
- elf_tdata (abfd)->dt_versym = versym;
- elf_tdata (abfd)->dt_verdef = verdef;
- elf_tdata (abfd)->dt_verneed = verneed;
- elf_tdata (abfd)->dt_verdef_count
- = verdef_size / sizeof (Elf_External_Verdef);
- elf_tdata (abfd)->dt_verneed_count
- = verneed_size / sizeof (Elf_External_Verneed);
-
- res = true;
-
- error_return:
- /* Restore file position for elf_object_p. */
- if (bfd_seek (abfd, saved_filepos, SEEK_SET) != 0)
- res = false;
- _bfd_munmap_readonly_temporary (dynbuf_addr, dynbuf_size);
- _bfd_munmap_readonly_temporary (esymbuf_addr, esymbuf_size);
- free (gnubuckets);
- free (gnuchains);
- free (mipsxlat);
- return res;
-}
-
-/* Reconstruct section from dynamic symbol. */
-
-asection *
-_bfd_elf_get_section_from_dynamic_symbol (bfd *abfd,
- Elf_Internal_Sym *isym)
-{
- asection *sec;
- flagword flags;
-
- if (!elf_use_dt_symtab_p (abfd))
- return NULL;
-
- flags = SEC_ALLOC | SEC_LOAD;
- switch (ELF_ST_TYPE (isym->st_info))
- {
- case STT_FUNC:
- case STT_GNU_IFUNC:
- sec = bfd_get_section_by_name (abfd, ".text");
- if (sec == NULL)
- sec = bfd_make_section_with_flags (abfd,
- ".text",
- flags | SEC_CODE);
- break;
- case STT_COMMON:
- sec = bfd_com_section_ptr;
- break;
- case STT_OBJECT:
- sec = bfd_get_section_by_name (abfd, ".data");
- if (sec == NULL)
- sec = bfd_make_section_with_flags (abfd,
- ".data",
- flags | SEC_DATA);
- break;
- case STT_TLS:
- sec = bfd_get_section_by_name (abfd, ".tdata");
- if (sec == NULL)
- sec = bfd_make_section_with_flags (abfd,
- ".tdata",
- (flags
- | SEC_DATA
- | SEC_THREAD_LOCAL));
- break;
- default:
- sec = bfd_abs_section_ptr;
- break;
- }
-
- return sec;
-}
-
-/* Get version name. If BASE_P is TRUE, return "Base" for VER_FLG_BASE
- and return symbol version for symbol version itself. */
-
-const char *
-_bfd_elf_get_symbol_version_string (bfd *abfd, asymbol *symbol,
- bool base_p,
- bool *hidden)
-{
- const char *version_string = NULL;
- if ((elf_dynversym (abfd) != 0
- && (elf_dynverdef (abfd) != 0 || elf_dynverref (abfd) != 0))
- || (elf_tdata (abfd)->dt_versym != NULL
- && (elf_tdata (abfd)->dt_verdef != NULL
- || elf_tdata (abfd)->dt_verneed != NULL)))
- {
- unsigned int vernum = ((elf_symbol_type *) symbol)->version;
-
- *hidden = (vernum & VERSYM_HIDDEN) != 0;
- vernum &= VERSYM_VERSION;
-
- if (vernum == 0)
- version_string = "";
- else if (vernum == 1
- && (vernum > elf_tdata (abfd)->cverdefs
- || (elf_tdata (abfd)->verdef[0].vd_flags
- == VER_FLG_BASE)))
- version_string = base_p ? "Base" : "";
- else if (vernum <= elf_tdata (abfd)->cverdefs)
- {
- const char *nodename
- = elf_tdata (abfd)->verdef[vernum - 1].vd_nodename;
- version_string = "";
- if (base_p
- || nodename == NULL
- || symbol->name == NULL
- || strcmp (symbol->name, nodename) != 0)
- version_string = nodename;
- }
- else
- {
- Elf_Internal_Verneed *t;
-
- version_string = _("<corrupt>");
- for (t = elf_tdata (abfd)->verref;
- t != NULL;
- t = t->vn_nextref)
- {
- Elf_Internal_Vernaux *a;
-
- for (a = t->vn_auxptr; a != NULL; a = a->vna_nextptr)
- {
- if (a->vna_other == vernum)
- {
- *hidden = true;
- version_string = a->vna_nodename;
- break;
- }
- }
- }
- }
- }
- return version_string;
-}
-
-/* Display ELF-specific fields of a symbol. */
-
-void
-bfd_elf_print_symbol (bfd *abfd,
- void *filep,
- asymbol *symbol,
- bfd_print_symbol_type how)
-{
- FILE *file = (FILE *) filep;
- switch (how)
- {
- case bfd_print_symbol_name:
- fprintf (file, "%s", symbol->name);
- break;
- case bfd_print_symbol_more:
- fprintf (file, "elf ");
- bfd_fprintf_vma (abfd, file, symbol->value);
- fprintf (file, " %x", symbol->flags);
- break;
- case bfd_print_symbol_all:
- {
- const char *section_name;
- const char *name = NULL;
- const struct elf_backend_data *bed;
- unsigned char st_other;
- bfd_vma val;
- const char *version_string;
- bool hidden;
-
- section_name = symbol->section ? symbol->section->name : "(*none*)";
-
- bed = get_elf_backend_data (abfd);
- if (bed->elf_backend_print_symbol_all)
- name = (*bed->elf_backend_print_symbol_all) (abfd, filep, symbol);
-
- if (name == NULL)
- {
- name = symbol->name;
- bfd_print_symbol_vandf (abfd, file, symbol);
- }
-
- fprintf (file, " %s\t", section_name);
- /* Print the "other" value for a symbol. For common symbols,
- we've already printed the size; now print the alignment.
- For other symbols, we have no specified alignment, and
- we've printed the address; now print the size. */
- if (symbol->section && bfd_is_com_section (symbol->section))
- val = ((elf_symbol_type *) symbol)->internal_elf_sym.st_value;
- else
- val = ((elf_symbol_type *) symbol)->internal_elf_sym.st_size;
- bfd_fprintf_vma (abfd, file, val);
-
- /* If we have version information, print it. */
- version_string = _bfd_elf_get_symbol_version_string (abfd,
- symbol,
- true,
- &hidden);
- if (version_string)
- {
- if (!hidden)
- fprintf (file, " %-11s", version_string);
- else
- {
- int i;
-
- fprintf (file, " (%s)", version_string);
- for (i = 10 - strlen (version_string); i > 0; --i)
- putc (' ', file);
- }
- }
-
- /* If the st_other field is not zero, print it. */
- st_other = ((elf_symbol_type *) symbol)->internal_elf_sym.st_other;
-
- switch (st_other)
- {
- case 0: break;
- case STV_INTERNAL: fprintf (file, " .internal"); break;
- case STV_HIDDEN: fprintf (file, " .hidden"); break;
- case STV_PROTECTED: fprintf (file, " .protected"); break;
- default:
- /* Some other non-defined flags are also present, so print
- everything hex. */
- fprintf (file, " 0x%02x", (unsigned int) st_other);
- }
-
- fprintf (file, " %s", name);
- }
- break;
- }
-}
-
-/* ELF .o/exec file reading */
-
-/* Create a new bfd section from an ELF section header. */
-
-bool
-bfd_section_from_shdr (bfd *abfd, unsigned int shindex)
-{
- Elf_Internal_Shdr *hdr;
- Elf_Internal_Ehdr *ehdr;
- const struct elf_backend_data *bed;
- const char *name;
- bool ret = true;
-
- if (shindex >= elf_numsections (abfd))
- return false;
-
- /* PR17512: A corrupt ELF binary might contain a loop of sections via
- sh_link or sh_info. Detect this here, by refusing to load a
- section that we are already in the process of loading. */
- if (elf_tdata (abfd)->being_created[shindex])
- {
- _bfd_error_handler
- (_("%pB: warning: loop in section dependencies detected"), abfd);
- return false;
- }
- elf_tdata (abfd)->being_created[shindex] = true;
-
- hdr = elf_elfsections (abfd)[shindex];
- ehdr = elf_elfheader (abfd);
- name = bfd_elf_string_from_elf_section (abfd, ehdr->e_shstrndx,
- hdr->sh_name);
- if (name == NULL)
- goto fail;
-
- bed = get_elf_backend_data (abfd);
- switch (hdr->sh_type)
- {
- case SHT_NULL:
- /* Inactive section. Throw it away. */
- goto success;
-
- case SHT_PROGBITS: /* Normal section with contents. */
- case SHT_NOBITS: /* .bss section. */
- case SHT_HASH: /* .hash section. */
- case SHT_NOTE: /* .note section. */
- case SHT_INIT_ARRAY: /* .init_array section. */
- case SHT_FINI_ARRAY: /* .fini_array section. */
- case SHT_PREINIT_ARRAY: /* .preinit_array section. */
- case SHT_GNU_LIBLIST: /* .gnu.liblist section. */
- case SHT_GNU_HASH: /* .gnu.hash section. */
- ret = _bfd_elf_make_section_from_shdr (abfd, hdr, name, shindex);
- goto success;
-
- case SHT_DYNAMIC: /* Dynamic linking information. */
- if (! _bfd_elf_make_section_from_shdr (abfd, hdr, name, shindex))
- goto fail;
-
- if (hdr->sh_link > elf_numsections (abfd))
- {
- /* PR 10478: Accept Solaris binaries with a sh_link field
- set to SHN_BEFORE (LORESERVE) or SHN_AFTER (LORESERVE+1). */
- switch (bfd_get_arch (abfd))
- {
- case bfd_arch_i386:
- case bfd_arch_sparc:
- if (hdr->sh_link == (SHN_LORESERVE & 0xffff)
- || hdr->sh_link == ((SHN_LORESERVE + 1) & 0xffff))
- break;
- /* Otherwise fall through. */
- default:
- goto fail;
- }
- }
- else if (elf_elfsections (abfd)[hdr->sh_link] == NULL)
- goto fail;
- else if (elf_elfsections (abfd)[hdr->sh_link]->sh_type != SHT_STRTAB)
- {
- Elf_Internal_Shdr *dynsymhdr;
-
- /* The shared libraries distributed with hpux11 have a bogus
- sh_link field for the ".dynamic" section. Find the
- string table for the ".dynsym" section instead. */
- if (elf_dynsymtab (abfd) != 0)
- {
- dynsymhdr = elf_elfsections (abfd)[elf_dynsymtab (abfd)];
- hdr->sh_link = dynsymhdr->sh_link;
- }
- else
- {
- unsigned int i, num_sec;
-
- num_sec = elf_numsections (abfd);
- for (i = 1; i < num_sec; i++)
- {
- dynsymhdr = elf_elfsections (abfd)[i];
- if (dynsymhdr->sh_type == SHT_DYNSYM)
- {
- hdr->sh_link = dynsymhdr->sh_link;
- break;
- }
- }
- }
- }
- goto success;
-
- case SHT_SYMTAB: /* A symbol table. */
- if (elf_onesymtab (abfd) == shindex)
- goto success;
-
- if (hdr->sh_entsize != bed->s->sizeof_sym)
- goto fail;
-
- if (hdr->sh_info * hdr->sh_entsize > hdr->sh_size)
- {
- if (hdr->sh_size != 0)
- goto fail;
- /* Some assemblers erroneously set sh_info to one with a
- zero sh_size. ld sees this as a global symbol count
- of (unsigned) -1. Fix it here. */
- hdr->sh_info = 0;
- goto success;
- }
-
- /* PR 18854: A binary might contain more than one symbol table.
- Unusual, but possible. Warn, but continue. */
- if (elf_onesymtab (abfd) != 0)
- {
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB: warning: multiple symbol tables detected"
- " - ignoring the table in section %u"),
- abfd, shindex);
- goto success;
- }
- elf_onesymtab (abfd) = shindex;
- elf_symtab_hdr (abfd) = *hdr;
- elf_elfsections (abfd)[shindex] = hdr = & elf_symtab_hdr (abfd);
- abfd->flags |= HAS_SYMS;
-
- /* Sometimes a shared object will map in the symbol table. If
- SHF_ALLOC is set, and this is a shared object, then we also
- treat this section as a BFD section. We can not base the
- decision purely on SHF_ALLOC, because that flag is sometimes
- set in a relocatable object file, which would confuse the
- linker. */
- if ((hdr->sh_flags & SHF_ALLOC) != 0
- && (abfd->flags & DYNAMIC) != 0
- && ! _bfd_elf_make_section_from_shdr (abfd, hdr, name,
- shindex))
- goto fail;
-
- /* Go looking for SHT_SYMTAB_SHNDX too, since if there is one we
- can't read symbols without that section loaded as well. It
- is most likely specified by the next section header. */
- {
- elf_section_list * entry;
- unsigned int i, num_sec;
-
- for (entry = elf_symtab_shndx_list (abfd); entry; entry = entry->next)
- if (entry->hdr.sh_link == shindex)
- goto success;
-
- num_sec = elf_numsections (abfd);
- for (i = shindex + 1; i < num_sec; i++)
- {
- Elf_Internal_Shdr *hdr2 = elf_elfsections (abfd)[i];
-
- if (hdr2->sh_type == SHT_SYMTAB_SHNDX
- && hdr2->sh_link == shindex)
- break;
- }
-
- if (i == num_sec)
- for (i = 1; i < shindex; i++)
- {
- Elf_Internal_Shdr *hdr2 = elf_elfsections (abfd)[i];
-
- if (hdr2->sh_type == SHT_SYMTAB_SHNDX
- && hdr2->sh_link == shindex)
- break;
- }
-
- if (i != shindex)
- ret = bfd_section_from_shdr (abfd, i);
- /* else FIXME: we have failed to find the symbol table.
- Should we issue an error? */
- goto success;
- }
-
- case SHT_DYNSYM: /* A dynamic symbol table. */
- if (elf_dynsymtab (abfd) == shindex)
- goto success;
-
- if (hdr->sh_entsize != bed->s->sizeof_sym)
- goto fail;
-
- if (hdr->sh_info * hdr->sh_entsize > hdr->sh_size)
- {
- if (hdr->sh_size != 0)
- goto fail;
-
- /* Some linkers erroneously set sh_info to one with a
- zero sh_size. ld sees this as a global symbol count
- of (unsigned) -1. Fix it here. */
- hdr->sh_info = 0;
- goto success;
- }
-
- /* PR 18854: A binary might contain more than one dynamic symbol table.
- Unusual, but possible. Warn, but continue. */
- if (elf_dynsymtab (abfd) != 0)
- {
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB: warning: multiple dynamic symbol tables detected"
- " - ignoring the table in section %u"),
- abfd, shindex);
- goto success;
- }
- elf_dynsymtab (abfd) = shindex;
- elf_tdata (abfd)->dynsymtab_hdr = *hdr;
- elf_elfsections (abfd)[shindex] = hdr = &elf_tdata (abfd)->dynsymtab_hdr;
- abfd->flags |= HAS_SYMS;
-
- /* Besides being a symbol table, we also treat this as a regular
- section, so that objcopy can handle it. */
- ret = _bfd_elf_make_section_from_shdr (abfd, hdr, name, shindex);
- goto success;
-
- case SHT_SYMTAB_SHNDX: /* Symbol section indices when >64k sections. */
- {
- elf_section_list * entry;
-
- for (entry = elf_symtab_shndx_list (abfd); entry; entry = entry->next)
- if (entry->ndx == shindex)
- goto success;
-
- entry = bfd_alloc (abfd, sizeof (*entry));
- if (entry == NULL)
- goto fail;
- entry->ndx = shindex;
- entry->hdr = * hdr;
- entry->next = elf_symtab_shndx_list (abfd);
- elf_symtab_shndx_list (abfd) = entry;
- elf_elfsections (abfd)[shindex] = & entry->hdr;
- goto success;
- }
-
- case SHT_STRTAB: /* A string table. */
- if (hdr->bfd_section != NULL)
- goto success;
-
- if (ehdr->e_shstrndx == shindex)
- {
- elf_tdata (abfd)->shstrtab_hdr = *hdr;
- elf_elfsections (abfd)[shindex] = &elf_tdata (abfd)->shstrtab_hdr;
- goto success;
- }
-
- if (elf_elfsections (abfd)[elf_onesymtab (abfd)]->sh_link == shindex)
- {
- symtab_strtab:
- elf_tdata (abfd)->strtab_hdr = *hdr;
- elf_elfsections (abfd)[shindex] = &elf_tdata (abfd)->strtab_hdr;
- goto success;
- }
-
- if (elf_elfsections (abfd)[elf_dynsymtab (abfd)]->sh_link == shindex)
- {
- dynsymtab_strtab:
- elf_tdata (abfd)->dynstrtab_hdr = *hdr;
- hdr = &elf_tdata (abfd)->dynstrtab_hdr;
- elf_elfsections (abfd)[shindex] = hdr;
- /* We also treat this as a regular section, so that objcopy
- can handle it. */
- ret = _bfd_elf_make_section_from_shdr (abfd, hdr, name,
- shindex);
- goto success;
- }
-
- /* If the string table isn't one of the above, then treat it as a
- regular section. We need to scan all the headers to be sure,
- just in case this strtab section appeared before the above. */
- if (elf_onesymtab (abfd) == 0 || elf_dynsymtab (abfd) == 0)
- {
- unsigned int i, num_sec;
-
- num_sec = elf_numsections (abfd);
- for (i = 1; i < num_sec; i++)
- {
- Elf_Internal_Shdr *hdr2 = elf_elfsections (abfd)[i];
- if (hdr2->sh_link == shindex)
- {
- /* Prevent endless recursion on broken objects. */
- if (i == shindex)
- goto fail;
- if (! bfd_section_from_shdr (abfd, i))
- goto fail;
- if (elf_onesymtab (abfd) == i)
- goto symtab_strtab;
- if (elf_dynsymtab (abfd) == i)
- goto dynsymtab_strtab;
- }
- }
- }
- ret = _bfd_elf_make_section_from_shdr (abfd, hdr, name, shindex);
- goto success;
-
- case SHT_REL:
- case SHT_RELA:
- case SHT_RELR:
- /* *These* do a lot of work -- but build no sections! */
- {
- asection *target_sect;
- Elf_Internal_Shdr *hdr2, **p_hdr;
- unsigned int num_sec = elf_numsections (abfd);
- struct bfd_elf_section_data *esdt;
- bfd_size_type size;
-
- if (hdr->sh_type == SHT_REL)
- size = bed->s->sizeof_rel;
- else if (hdr->sh_type == SHT_RELA)
- size = bed->s->sizeof_rela;
- else
- size = bed->s->arch_size / 8;
- if (hdr->sh_entsize != size)
- goto fail;
-
- /* Check for a bogus link to avoid crashing. */
- if (hdr->sh_link >= num_sec)
- {
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB: invalid link %u for reloc section %s (index %u)"),
- abfd, hdr->sh_link, name, shindex);
- ret = _bfd_elf_make_section_from_shdr (abfd, hdr, name, shindex);
- goto success;
- }
-
- /* Get the symbol table. */
- if ((elf_elfsections (abfd)[hdr->sh_link]->sh_type == SHT_SYMTAB
- || elf_elfsections (abfd)[hdr->sh_link]->sh_type == SHT_DYNSYM)
- && ! bfd_section_from_shdr (abfd, hdr->sh_link))
- goto fail;
-
- /* If this is an alloc section in an executable or shared
- library, or the reloc section does not use the main symbol
- table we don't treat it as a reloc section. BFD can't
- adequately represent such a section, so at least for now,
- we don't try. We just present it as a normal section. We
- also can't use it as a reloc section if it points to the
- null section, an invalid section, another reloc section, or
- its sh_link points to the null section. */
- if (((abfd->flags & (DYNAMIC | EXEC_P)) != 0
- && (hdr->sh_flags & SHF_ALLOC) != 0)
- || (hdr->sh_flags & SHF_COMPRESSED) != 0
- || hdr->sh_type == SHT_RELR
- || hdr->sh_link == SHN_UNDEF
- || hdr->sh_link != elf_onesymtab (abfd)
- || hdr->sh_info == SHN_UNDEF
- || hdr->sh_info >= num_sec
- || elf_elfsections (abfd)[hdr->sh_info]->sh_type == SHT_REL
- || elf_elfsections (abfd)[hdr->sh_info]->sh_type == SHT_RELA)
- {
- ret = _bfd_elf_make_section_from_shdr (abfd, hdr, name, shindex);
- goto success;
- }
-
- if (! bfd_section_from_shdr (abfd, hdr->sh_info))
- goto fail;
-
- target_sect = bfd_section_from_elf_index (abfd, hdr->sh_info);
- if (target_sect == NULL)
- goto fail;
-
- esdt = elf_section_data (target_sect);
- if (hdr->sh_type == SHT_RELA)
- p_hdr = &esdt->rela.hdr;
- else
- p_hdr = &esdt->rel.hdr;
-
- /* PR 17512: file: 0b4f81b7.
- Also see PR 24456, for a file which deliberately has two reloc
- sections. */
- if (*p_hdr != NULL)
- {
- if (!bed->init_secondary_reloc_section (abfd, hdr, name, shindex))
- {
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB: warning: secondary relocation section '%s' "
- "for section %pA found - ignoring"),
- abfd, name, target_sect);
- }
- else
- esdt->has_secondary_relocs = true;
- goto success;
- }
-
- hdr2 = (Elf_Internal_Shdr *) bfd_alloc (abfd, sizeof (*hdr2));
- if (hdr2 == NULL)
- goto fail;
- *hdr2 = *hdr;
- *p_hdr = hdr2;
- elf_elfsections (abfd)[shindex] = hdr2;
- target_sect->reloc_count += (NUM_SHDR_ENTRIES (hdr)
- * bed->s->int_rels_per_ext_rel);
- target_sect->flags |= SEC_RELOC;
- target_sect->relocation = NULL;
- target_sect->rel_filepos = hdr->sh_offset;
- /* In the section to which the relocations apply, mark whether
- its relocations are of the REL or RELA variety. */
- if (hdr->sh_size != 0)
- {
- if (hdr->sh_type == SHT_RELA)
- target_sect->use_rela_p = 1;
- }
- abfd->flags |= HAS_RELOC;
- goto success;
- }
-
- case SHT_GNU_verdef:
- if (hdr->sh_info != 0)
- elf_dynverdef (abfd) = shindex;
- elf_tdata (abfd)->dynverdef_hdr = *hdr;
- ret = _bfd_elf_make_section_from_shdr (abfd, hdr, name, shindex);
- goto success;
-
- case SHT_GNU_versym:
- if (hdr->sh_entsize != sizeof (Elf_External_Versym))
- goto fail;
-
- elf_dynversym (abfd) = shindex;
- elf_tdata (abfd)->dynversym_hdr = *hdr;
- ret = _bfd_elf_make_section_from_shdr (abfd, hdr, name, shindex);
- goto success;
-
- case SHT_GNU_verneed:
- if (hdr->sh_info != 0)
- elf_dynverref (abfd) = shindex;
- elf_tdata (abfd)->dynverref_hdr = *hdr;
- ret = _bfd_elf_make_section_from_shdr (abfd, hdr, name, shindex);
- goto success;
-
- case SHT_SHLIB:
- goto success;
-
- case SHT_GROUP:
- if (!_bfd_elf_make_section_from_shdr (abfd, hdr, name, shindex))
- goto fail;
-
- goto success;
-
- default:
- /* Possibly an attributes section. */
- if (hdr->sh_type == SHT_GNU_ATTRIBUTES
- || hdr->sh_type == bed->obj_attrs_section_type)
- {
- if (! _bfd_elf_make_section_from_shdr (abfd, hdr, name, shindex))
- goto fail;
- _bfd_elf_parse_attributes (abfd, hdr);
- goto success;
- }
-
- /* Check for any processor-specific section types. */
- if (bed->elf_backend_section_from_shdr (abfd, hdr, name, shindex))
- goto success;
-
- if (hdr->sh_type >= SHT_LOUSER && hdr->sh_type <= SHT_HIUSER)
- {
- if ((hdr->sh_flags & SHF_ALLOC) != 0)
- /* FIXME: How to properly handle allocated section reserved
- for applications? */
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB: unknown type [%#x] section `%s'"),
- abfd, hdr->sh_type, name);
- else
- {
- /* Allow sections reserved for applications. */
- ret = _bfd_elf_make_section_from_shdr (abfd, hdr, name, shindex);
- goto success;
- }
- }
- else if (hdr->sh_type >= SHT_LOPROC
- && hdr->sh_type <= SHT_HIPROC)
- /* FIXME: We should handle this section. */
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB: unknown type [%#x] section `%s'"),
- abfd, hdr->sh_type, name);
- else if (hdr->sh_type >= SHT_LOOS && hdr->sh_type <= SHT_HIOS)
- {
- /* Unrecognised OS-specific sections. */
- if ((hdr->sh_flags & SHF_OS_NONCONFORMING) != 0)
- /* SHF_OS_NONCONFORMING indicates that special knowledge is
- required to correctly process the section and the file should
- be rejected with an error message. */
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB: unknown type [%#x] section `%s'"),
- abfd, hdr->sh_type, name);
- else
- {
- /* Otherwise it should be processed. */
- ret = _bfd_elf_make_section_from_shdr (abfd, hdr, name, shindex);
- goto success;
- }
- }
- else
- /* FIXME: We should handle this section. */
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB: unknown type [%#x] section `%s'"),
- abfd, hdr->sh_type, name);
-
- goto fail;
- }
-
- fail:
- ret = false;
- success:
- elf_tdata (abfd)->being_created[shindex] = false;
- return ret;
-}
-
-/* Return the local symbol specified by ABFD, R_SYMNDX. */
-
-Elf_Internal_Sym *
-bfd_sym_from_r_symndx (struct sym_cache *cache,
- bfd *abfd,
- unsigned long r_symndx)
-{
- unsigned int ent = r_symndx % LOCAL_SYM_CACHE_SIZE;
-
- if (cache->abfd != abfd || cache->indx[ent] != r_symndx)
- {
- Elf_Internal_Shdr *symtab_hdr;
- unsigned char esym[sizeof (Elf64_External_Sym)];
- Elf_External_Sym_Shndx eshndx;
-
- symtab_hdr = &elf_tdata (abfd)->symtab_hdr;
- if (bfd_elf_get_elf_syms (abfd, symtab_hdr, 1, r_symndx,
- &cache->sym[ent], esym, &eshndx) == NULL)
- return NULL;
-
- if (cache->abfd != abfd)
- {
- memset (cache->indx, -1, sizeof (cache->indx));
- cache->abfd = abfd;
- }
- cache->indx[ent] = r_symndx;
- }
-
- return &cache->sym[ent];
-}
-
-/* Given an ELF section number, retrieve the corresponding BFD
- section. */
-
-asection *
-bfd_section_from_elf_index (bfd *abfd, unsigned int sec_index)
-{
- if (sec_index >= elf_numsections (abfd))
- return NULL;
- return elf_elfsections (abfd)[sec_index]->bfd_section;
-}
-
-static const struct bfd_elf_special_section special_sections_b[] =
-{
- { STRING_COMMA_LEN (".bss"), -2, SHT_NOBITS, SHF_ALLOC + SHF_WRITE },
- { NULL, 0, 0, 0, 0 }
-};
-
-static const struct bfd_elf_special_section special_sections_c[] =
-{
- { STRING_COMMA_LEN (".comment"), 0, SHT_PROGBITS, 0 },
- { STRING_COMMA_LEN (".ctf"), 0, SHT_PROGBITS, 0 },
- { NULL, 0, 0, 0, 0 }
-};
-
-static const struct bfd_elf_special_section special_sections_d[] =
-{
- { STRING_COMMA_LEN (".data"), -2, SHT_PROGBITS, SHF_ALLOC + SHF_WRITE },
- { STRING_COMMA_LEN (".data1"), 0, SHT_PROGBITS, SHF_ALLOC + SHF_WRITE },
- /* There are more DWARF sections than these, but they needn't be added here
- unless you have to cope with broken compilers that don't emit section
- attributes or you want to help the user writing assembler. */
- { STRING_COMMA_LEN (".debug"), 0, SHT_PROGBITS, 0 },
- { STRING_COMMA_LEN (".debug_line"), 0, SHT_PROGBITS, 0 },
- { STRING_COMMA_LEN (".debug_info"), 0, SHT_PROGBITS, 0 },
- { STRING_COMMA_LEN (".debug_abbrev"), 0, SHT_PROGBITS, 0 },
- { STRING_COMMA_LEN (".debug_aranges"), 0, SHT_PROGBITS, 0 },
- { STRING_COMMA_LEN (".dynamic"), 0, SHT_DYNAMIC, SHF_ALLOC },
- { STRING_COMMA_LEN (".dynstr"), 0, SHT_STRTAB, SHF_ALLOC },
- { STRING_COMMA_LEN (".dynsym"), 0, SHT_DYNSYM, SHF_ALLOC },
- { NULL, 0, 0, 0, 0 }
-};
-
-static const struct bfd_elf_special_section special_sections_f[] =
-{
- { STRING_COMMA_LEN (".fini"), 0, SHT_PROGBITS, SHF_ALLOC + SHF_EXECINSTR },
- { STRING_COMMA_LEN (".fini_array"), -2, SHT_FINI_ARRAY, SHF_ALLOC + SHF_WRITE },
- { NULL, 0 , 0, 0, 0 }
-};
-
-static const struct bfd_elf_special_section special_sections_g[] =
-{
- { STRING_COMMA_LEN (".gnu.linkonce.b"), -2, SHT_NOBITS, SHF_ALLOC + SHF_WRITE },
- { STRING_COMMA_LEN (".gnu.linkonce.n"), -2, SHT_NOBITS, SHF_ALLOC + SHF_WRITE },
- { STRING_COMMA_LEN (".gnu.linkonce.p"), -2, SHT_PROGBITS, SHF_ALLOC + SHF_WRITE },
- { STRING_COMMA_LEN (".gnu.lto_"), -1, SHT_PROGBITS, SHF_EXCLUDE },
- { STRING_COMMA_LEN (".got"), 0, SHT_PROGBITS, SHF_ALLOC + SHF_WRITE },
- { STRING_COMMA_LEN (".gnu.version"), 0, SHT_GNU_versym, 0 },
- { STRING_COMMA_LEN (".gnu.version_d"), 0, SHT_GNU_verdef, 0 },
- { STRING_COMMA_LEN (".gnu.version_r"), 0, SHT_GNU_verneed, 0 },
- { STRING_COMMA_LEN (".gnu.liblist"), 0, SHT_GNU_LIBLIST, SHF_ALLOC },
- { STRING_COMMA_LEN (".gnu.conflict"), 0, SHT_RELA, SHF_ALLOC },
- { STRING_COMMA_LEN (".gnu.hash"), 0, SHT_GNU_HASH, SHF_ALLOC },
- { NULL, 0, 0, 0, 0 }
-};
-
-static const struct bfd_elf_special_section special_sections_h[] =
-{
- { STRING_COMMA_LEN (".hash"), 0, SHT_HASH, SHF_ALLOC },
- { NULL, 0, 0, 0, 0 }
-};
-
-static const struct bfd_elf_special_section special_sections_i[] =
-{
- { STRING_COMMA_LEN (".init"), 0, SHT_PROGBITS, SHF_ALLOC + SHF_EXECINSTR },
- { STRING_COMMA_LEN (".init_array"), -2, SHT_INIT_ARRAY, SHF_ALLOC + SHF_WRITE },
- { STRING_COMMA_LEN (".interp"), 0, SHT_PROGBITS, 0 },
- { NULL, 0, 0, 0, 0 }
-};
-
-static const struct bfd_elf_special_section special_sections_l[] =
-{
- { STRING_COMMA_LEN (".line"), 0, SHT_PROGBITS, 0 },
- { NULL, 0, 0, 0, 0 }
-};
-
-static const struct bfd_elf_special_section special_sections_n[] =
-{
- { STRING_COMMA_LEN (".noinit"), -2, SHT_NOBITS, SHF_ALLOC + SHF_WRITE },
- { STRING_COMMA_LEN (".note.GNU-stack"), 0, SHT_PROGBITS, 0 },
- { STRING_COMMA_LEN (".note"), -1, SHT_NOTE, 0 },
- { NULL, 0, 0, 0, 0 }
-};
-
-static const struct bfd_elf_special_section special_sections_p[] =
-{
- { STRING_COMMA_LEN (".persistent.bss"), 0, SHT_NOBITS, SHF_ALLOC + SHF_WRITE },
- { STRING_COMMA_LEN (".persistent"), -2, SHT_PROGBITS, SHF_ALLOC + SHF_WRITE },
- { STRING_COMMA_LEN (".preinit_array"), -2, SHT_PREINIT_ARRAY, SHF_ALLOC + SHF_WRITE },
- { STRING_COMMA_LEN (".plt"), 0, SHT_PROGBITS, SHF_ALLOC + SHF_EXECINSTR },
- { NULL, 0, 0, 0, 0 }
-};
-
-static const struct bfd_elf_special_section special_sections_r[] =
-{
- { STRING_COMMA_LEN (".rodata"), -2, SHT_PROGBITS, SHF_ALLOC },
- { STRING_COMMA_LEN (".rodata1"), 0, SHT_PROGBITS, SHF_ALLOC },
- { STRING_COMMA_LEN (".relr.dyn"), 0, SHT_RELR, SHF_ALLOC },
- { STRING_COMMA_LEN (".rela"), -1, SHT_RELA, 0 },
- { STRING_COMMA_LEN (".rel"), -1, SHT_REL, 0 },
- { NULL, 0, 0, 0, 0 }
-};
-
-static const struct bfd_elf_special_section special_sections_s[] =
-{
- { STRING_COMMA_LEN (".shstrtab"), 0, SHT_STRTAB, 0 },
- { STRING_COMMA_LEN (".strtab"), 0, SHT_STRTAB, 0 },
- { STRING_COMMA_LEN (".symtab"), 0, SHT_SYMTAB, 0 },
- /* See struct bfd_elf_special_section declaration for the semantics of
- this special case where .prefix_length != strlen (.prefix). */
- { ".stabstr", 5, 3, SHT_STRTAB, 0 },
- { NULL, 0, 0, 0, 0 }
-};
-
-static const struct bfd_elf_special_section special_sections_t[] =
-{
- { STRING_COMMA_LEN (".text"), -2, SHT_PROGBITS, SHF_ALLOC + SHF_EXECINSTR },
- { STRING_COMMA_LEN (".tbss"), -2, SHT_NOBITS, SHF_ALLOC + SHF_WRITE + SHF_TLS },
- { STRING_COMMA_LEN (".tdata"), -2, SHT_PROGBITS, SHF_ALLOC + SHF_WRITE + SHF_TLS },
- { NULL, 0, 0, 0, 0 }
-};
-
-static const struct bfd_elf_special_section special_sections_z[] =
-{
- { STRING_COMMA_LEN (".zdebug_line"), 0, SHT_PROGBITS, 0 },
- { STRING_COMMA_LEN (".zdebug_info"), 0, SHT_PROGBITS, 0 },
- { STRING_COMMA_LEN (".zdebug_abbrev"), 0, SHT_PROGBITS, 0 },
- { STRING_COMMA_LEN (".zdebug_aranges"), 0, SHT_PROGBITS, 0 },
- { NULL, 0, 0, 0, 0 }
-};
-
-static const struct bfd_elf_special_section * const special_sections[] =
-{
- special_sections_b, /* 'b' */
- special_sections_c, /* 'c' */
- special_sections_d, /* 'd' */
- NULL, /* 'e' */
- special_sections_f, /* 'f' */
- special_sections_g, /* 'g' */
- special_sections_h, /* 'h' */
- special_sections_i, /* 'i' */
- NULL, /* 'j' */
- NULL, /* 'k' */
- special_sections_l, /* 'l' */
- NULL, /* 'm' */
- special_sections_n, /* 'n' */
- NULL, /* 'o' */
- special_sections_p, /* 'p' */
- NULL, /* 'q' */
- special_sections_r, /* 'r' */
- special_sections_s, /* 's' */
- special_sections_t, /* 't' */
- NULL, /* 'u' */
- NULL, /* 'v' */
- NULL, /* 'w' */
- NULL, /* 'x' */
- NULL, /* 'y' */
- special_sections_z /* 'z' */
-};
-
-const struct bfd_elf_special_section *
-_bfd_elf_get_special_section (const char *name,
- const struct bfd_elf_special_section *spec,
- unsigned int rela)
-{
- int i;
- int len;
-
- len = strlen (name);
-
- for (i = 0; spec[i].prefix != NULL; i++)
- {
- int suffix_len;
- int prefix_len = spec[i].prefix_length;
-
- if (len < prefix_len)
- continue;
- if (memcmp (name, spec[i].prefix, prefix_len) != 0)
- continue;
-
- suffix_len = spec[i].suffix_length;
- if (suffix_len <= 0)
- {
- if (name[prefix_len] != 0)
- {
- if (suffix_len == 0)
- continue;
- if (name[prefix_len] != '.'
- && (suffix_len == -2
- || (rela && spec[i].type == SHT_REL)))
- continue;
- }
- }
- else
- {
- if (len < prefix_len + suffix_len)
- continue;
- if (memcmp (name + len - suffix_len,
- spec[i].prefix + prefix_len,
- suffix_len) != 0)
- continue;
- }
- return &spec[i];
- }
-
- return NULL;
-}
-
-const struct bfd_elf_special_section *
-_bfd_elf_get_sec_type_attr (bfd *abfd, asection *sec)
-{
- int i;
- const struct bfd_elf_special_section *spec;
- const struct elf_backend_data *bed;
-
- /* See if this is one of the special sections. */
- if (sec->name == NULL)
- return NULL;
-
- bed = get_elf_backend_data (abfd);
- spec = bed->special_sections;
- if (spec)
- {
- spec = _bfd_elf_get_special_section (sec->name,
- bed->special_sections,
- sec->use_rela_p);
- if (spec != NULL)
- return spec;
- }
-
- if (sec->name[0] != '.')
- return NULL;
-
- i = sec->name[1] - 'b';
- if (i < 0 || i > 'z' - 'b')
- return NULL;
-
- spec = special_sections[i];
-
- if (spec == NULL)
- return NULL;
-
- return _bfd_elf_get_special_section (sec->name, spec, sec->use_rela_p);
-}
-
-bool
-_bfd_elf_new_section_hook (bfd *abfd, asection *sec)
-{
- struct bfd_elf_section_data *sdata;
- const struct elf_backend_data *bed;
- const struct bfd_elf_special_section *ssect;
-
- sdata = (struct bfd_elf_section_data *) sec->used_by_bfd;
- if (sdata == NULL)
- {
- sdata = (struct bfd_elf_section_data *) bfd_zalloc (abfd,
- sizeof (*sdata));
- if (sdata == NULL)
- return false;
- sec->used_by_bfd = sdata;
- }
-
- /* Indicate whether or not this section should use RELA relocations. */
- bed = get_elf_backend_data (abfd);
- sec->use_rela_p = bed->default_use_rela_p;
-
- /* Set up ELF section type and flags for newly created sections, if
- there is an ABI mandated section. */
- ssect = (*bed->get_sec_type_attr) (abfd, sec);
- if (ssect != NULL)
- {
- elf_section_type (sec) = ssect->type;
- elf_section_flags (sec) = ssect->attr;
- }
-
- return _bfd_generic_new_section_hook (abfd, sec);
-}
-
-/* Create a new bfd section from an ELF program header.
-
- Since program segments have no names, we generate a synthetic name
- of the form segment<NUM>, where NUM is generally the index in the
- program header table. For segments that are split (see below) we
- generate the names segment<NUM>a and segment<NUM>b.
-
- Note that some program segments may have a file size that is different than
- (less than) the memory size. All this means is that at execution the
- system must allocate the amount of memory specified by the memory size,
- but only initialize it with the first "file size" bytes read from the
- file. This would occur for example, with program segments consisting
- of combined data+bss.
-
- To handle the above situation, this routine generates TWO bfd sections
- for the single program segment. The first has the length specified by
- the file size of the segment, and the second has the length specified
- by the difference between the two sizes. In effect, the segment is split
- into its initialized and uninitialized parts. */
-
-bool
-_bfd_elf_make_section_from_phdr (bfd *abfd,
- Elf_Internal_Phdr *hdr,
- int hdr_index,
- const char *type_name)
-{
- asection *newsect;
- char *name;
- char namebuf[64];
- size_t len;
- int split;
- unsigned int opb = bfd_octets_per_byte (abfd, NULL);
-
- split = ((hdr->p_memsz > 0)
- && (hdr->p_filesz > 0)
- && (hdr->p_memsz > hdr->p_filesz));
-
- if (hdr->p_filesz > 0)
- {
- sprintf (namebuf, "%s%d%s", type_name, hdr_index, split ? "a" : "");
- len = strlen (namebuf) + 1;
- name = (char *) bfd_alloc (abfd, len);
- if (!name)
- return false;
- memcpy (name, namebuf, len);
- newsect = bfd_make_section (abfd, name);
- if (newsect == NULL)
- return false;
- newsect->vma = hdr->p_vaddr / opb;
- newsect->lma = hdr->p_paddr / opb;
- newsect->size = hdr->p_filesz;
- newsect->filepos = hdr->p_offset;
- newsect->flags |= SEC_HAS_CONTENTS;
- newsect->alignment_power = bfd_log2 (hdr->p_align);
- if (hdr->p_type == PT_LOAD)
- {
- newsect->flags |= SEC_ALLOC;
- newsect->flags |= SEC_LOAD;
- if (hdr->p_flags & PF_X)
- {
- /* FIXME: all we known is that it has execute PERMISSION,
- may be data. */
- newsect->flags |= SEC_CODE;
- }
- }
- if (!(hdr->p_flags & PF_W))
- {
- newsect->flags |= SEC_READONLY;
- }
- }
-
- if (hdr->p_memsz > hdr->p_filesz)
- {
- bfd_vma align;
-
- sprintf (namebuf, "%s%d%s", type_name, hdr_index, split ? "b" : "");
- len = strlen (namebuf) + 1;
- name = (char *) bfd_alloc (abfd, len);
- if (!name)
- return false;
- memcpy (name, namebuf, len);
- newsect = bfd_make_section (abfd, name);
- if (newsect == NULL)
- return false;
- newsect->vma = (hdr->p_vaddr + hdr->p_filesz) / opb;
- newsect->lma = (hdr->p_paddr + hdr->p_filesz) / opb;
- newsect->size = hdr->p_memsz - hdr->p_filesz;
- newsect->filepos = hdr->p_offset + hdr->p_filesz;
- align = newsect->vma & -newsect->vma;
- if (align == 0 || align > hdr->p_align)
- align = hdr->p_align;
- newsect->alignment_power = bfd_log2 (align);
- if (hdr->p_type == PT_LOAD)
- {
- newsect->flags |= SEC_ALLOC;
- if (hdr->p_flags & PF_X)
- newsect->flags |= SEC_CODE;
- }
- if (!(hdr->p_flags & PF_W))
- newsect->flags |= SEC_READONLY;
- }
-
- return true;
-}
-
-static bool
-_bfd_elf_core_find_build_id (bfd *templ, bfd_vma offset)
-{
- /* The return value is ignored. Build-ids are considered optional. */
- if (templ->xvec->flavour == bfd_target_elf_flavour)
- return (*get_elf_backend_data (templ)->elf_backend_core_find_build_id)
- (templ, offset);
- return false;
-}
-
-bool
-bfd_section_from_phdr (bfd *abfd, Elf_Internal_Phdr *hdr, int hdr_index)
-{
- const struct elf_backend_data *bed;
-
- switch (hdr->p_type)
- {
- case PT_NULL:
- return _bfd_elf_make_section_from_phdr (abfd, hdr, hdr_index, "null");
-
- case PT_LOAD:
- if (! _bfd_elf_make_section_from_phdr (abfd, hdr, hdr_index, "load"))
- return false;
- if (bfd_get_format (abfd) == bfd_core && abfd->build_id == NULL)
- _bfd_elf_core_find_build_id (abfd, hdr->p_offset);
- return true;
-
- case PT_DYNAMIC:
- return _bfd_elf_make_section_from_phdr (abfd, hdr, hdr_index, "dynamic");
-
- case PT_INTERP:
- return _bfd_elf_make_section_from_phdr (abfd, hdr, hdr_index, "interp");
-
- case PT_NOTE:
- if (! _bfd_elf_make_section_from_phdr (abfd, hdr, hdr_index, "note"))
- return false;
- if (! elf_read_notes (abfd, hdr->p_offset, hdr->p_filesz,
- hdr->p_align))
- return false;
- return true;
-
- case PT_SHLIB:
- return _bfd_elf_make_section_from_phdr (abfd, hdr, hdr_index, "shlib");
-
- case PT_PHDR:
- return _bfd_elf_make_section_from_phdr (abfd, hdr, hdr_index, "phdr");
-
- case PT_GNU_EH_FRAME:
- return _bfd_elf_make_section_from_phdr (abfd, hdr, hdr_index,
- "eh_frame_hdr");
-
- case PT_GNU_STACK:
- return _bfd_elf_make_section_from_phdr (abfd, hdr, hdr_index, "stack");
-
- case PT_GNU_RELRO:
- return _bfd_elf_make_section_from_phdr (abfd, hdr, hdr_index, "relro");
-
- case PT_GNU_SFRAME:
- return _bfd_elf_make_section_from_phdr (abfd, hdr, hdr_index,
- "sframe");
-
- default:
- /* Check for any processor-specific program segment types. */
- bed = get_elf_backend_data (abfd);
- return bed->elf_backend_section_from_phdr (abfd, hdr, hdr_index, "proc");
- }
-}
-
-/* Return the REL_HDR for SEC, assuming there is only a single one, either
- REL or RELA. */
-
-Elf_Internal_Shdr *
-_bfd_elf_single_rel_hdr (asection *sec)
-{
- if (elf_section_data (sec)->rel.hdr)
- {
- BFD_ASSERT (elf_section_data (sec)->rela.hdr == NULL);
- return elf_section_data (sec)->rel.hdr;
- }
- else
- return elf_section_data (sec)->rela.hdr;
-}
-
-static bool
-_bfd_elf_set_reloc_sh_name (bfd *abfd,
- Elf_Internal_Shdr *rel_hdr,
- const char *sec_name,
- bool use_rela_p)
-{
- char *name = (char *) bfd_alloc (abfd,
- sizeof ".rela" + strlen (sec_name));
- if (name == NULL)
- return false;
-
- sprintf (name, "%s%s", use_rela_p ? ".rela" : ".rel", sec_name);
- rel_hdr->sh_name =
- (unsigned int) _bfd_elf_strtab_add (elf_shstrtab (abfd), name,
- false);
- if (rel_hdr->sh_name == (unsigned int) -1)
- return false;
-
- return true;
-}
-
-/* Allocate and initialize a section-header for a new reloc section,
- containing relocations against ASECT. It is stored in RELDATA. If
- USE_RELA_P is TRUE, we use RELA relocations; otherwise, we use REL
- relocations. */
-
-static bool
-_bfd_elf_init_reloc_shdr (bfd *abfd,
- struct bfd_elf_section_reloc_data *reldata,
- const char *sec_name,
- bool use_rela_p,
- bool delay_st_name_p)
-{
- Elf_Internal_Shdr *rel_hdr;
- const struct elf_backend_data *bed = get_elf_backend_data (abfd);
-
- BFD_ASSERT (reldata->hdr == NULL);
- rel_hdr = bfd_zalloc (abfd, sizeof (*rel_hdr));
- if (rel_hdr == NULL)
- return false;
- reldata->hdr = rel_hdr;
-
- if (delay_st_name_p)
- rel_hdr->sh_name = (unsigned int) -1;
- else if (!_bfd_elf_set_reloc_sh_name (abfd, rel_hdr, sec_name,
- use_rela_p))
- return false;
- rel_hdr->sh_type = use_rela_p ? SHT_RELA : SHT_REL;
- rel_hdr->sh_entsize = (use_rela_p
- ? bed->s->sizeof_rela
- : bed->s->sizeof_rel);
- rel_hdr->sh_addralign = (bfd_vma) 1 << bed->s->log_file_align;
- rel_hdr->sh_flags = 0;
- rel_hdr->sh_addr = 0;
- rel_hdr->sh_size = 0;
- rel_hdr->sh_offset = 0;
-
- return true;
-}
-
-/* Return the default section type based on the passed in section flags. */
-
-int
-bfd_elf_get_default_section_type (flagword flags)
-{
- if ((flags & (SEC_ALLOC | SEC_IS_COMMON)) != 0
- && (flags & (SEC_LOAD | SEC_HAS_CONTENTS)) == 0)
- return SHT_NOBITS;
- return SHT_PROGBITS;
-}
-
-struct fake_section_arg
-{
- struct bfd_link_info *link_info;
- bool failed;
-};
-
-/* Set up an ELF internal section header for a section. */
-
-static void
-elf_fake_sections (bfd *abfd, asection *asect, void *fsarg)
-{
- struct fake_section_arg *arg = (struct fake_section_arg *)fsarg;
- const struct elf_backend_data *bed = get_elf_backend_data (abfd);
- struct bfd_elf_section_data *esd = elf_section_data (asect);
- Elf_Internal_Shdr *this_hdr;
- unsigned int sh_type;
- const char *name = asect->name;
- bool delay_st_name_p = false;
- bfd_vma mask;
-
- if (arg->failed)
- {
- /* We already failed; just get out of the bfd_map_over_sections
- loop. */
- return;
- }
-
- this_hdr = &esd->this_hdr;
-
- /* ld: compress DWARF debug sections with names: .debug_*. */
- if (arg->link_info
- && (abfd->flags & BFD_COMPRESS) != 0
- && (asect->flags & SEC_DEBUGGING) != 0
- && name[1] == 'd'
- && name[6] == '_')
- {
- /* If this section will be compressed, delay adding section
- name to section name section after it is compressed in
- _bfd_elf_assign_file_positions_for_non_load. */
- delay_st_name_p = true;
- }
-
- if (delay_st_name_p)
- this_hdr->sh_name = (unsigned int) -1;
- else
- {
- this_hdr->sh_name
- = (unsigned int) _bfd_elf_strtab_add (elf_shstrtab (abfd),
- name, false);
- if (this_hdr->sh_name == (unsigned int) -1)
- {
- arg->failed = true;
- return;
- }
- }
-
- /* Don't clear sh_flags. Assembler may set additional bits. */
-
- if ((asect->flags & SEC_ALLOC) != 0
- || asect->user_set_vma)
- this_hdr->sh_addr = asect->vma * bfd_octets_per_byte (abfd, asect);
- else
- this_hdr->sh_addr = 0;
-
- this_hdr->sh_offset = 0;
- this_hdr->sh_size = asect->size;
- this_hdr->sh_link = 0;
- /* PR 17512: file: 0eb809fe, 8b0535ee. */
- if (asect->alignment_power >= (sizeof (bfd_vma) * 8) - 1)
- {
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB: error: alignment power %d of section `%pA' is too big"),
- abfd, asect->alignment_power, asect);
- arg->failed = true;
- return;
- }
- /* Set sh_addralign to the highest power of two given by alignment
- consistent with the section VMA. Linker scripts can force VMA. */
- mask = ((bfd_vma) 1 << asect->alignment_power) | this_hdr->sh_addr;
- this_hdr->sh_addralign = mask & -mask;
- /* The sh_entsize and sh_info fields may have been set already by
- copy_private_section_data. */
-
- this_hdr->bfd_section = asect;
- this_hdr->contents = NULL;
-
- /* If the section type is unspecified, we set it based on
- asect->flags. */
- if (asect->type != 0)
- sh_type = asect->type;
- else if ((asect->flags & SEC_GROUP) != 0)
- sh_type = SHT_GROUP;
- else
- sh_type = bfd_elf_get_default_section_type (asect->flags);
-
- if (this_hdr->sh_type == SHT_NULL)
- this_hdr->sh_type = sh_type;
- else if (this_hdr->sh_type == SHT_NOBITS
- && sh_type == SHT_PROGBITS
- && (asect->flags & SEC_ALLOC) != 0)
- {
- /* Warn if we are changing a NOBITS section to PROGBITS, but
- allow the link to proceed. This can happen when users link
- non-bss input sections to bss output sections, or emit data
- to a bss output section via a linker script. */
- _bfd_error_handler
- (_("warning: section `%pA' type changed to PROGBITS"), asect);
- this_hdr->sh_type = sh_type;
- }
-
- switch (this_hdr->sh_type)
- {
- default:
- break;
-
- case SHT_STRTAB:
- case SHT_NOTE:
- case SHT_NOBITS:
- case SHT_PROGBITS:
- break;
-
- case SHT_INIT_ARRAY:
- case SHT_FINI_ARRAY:
- case SHT_PREINIT_ARRAY:
- this_hdr->sh_entsize = bed->s->arch_size / 8;
- break;
-
- case SHT_HASH:
- this_hdr->sh_entsize = bed->s->sizeof_hash_entry;
- break;
-
- case SHT_DYNSYM:
- this_hdr->sh_entsize = bed->s->sizeof_sym;
- break;
-
- case SHT_DYNAMIC:
- this_hdr->sh_entsize = bed->s->sizeof_dyn;
- break;
-
- case SHT_RELA:
- if (get_elf_backend_data (abfd)->may_use_rela_p)
- this_hdr->sh_entsize = bed->s->sizeof_rela;
- break;
-
- case SHT_REL:
- if (get_elf_backend_data (abfd)->may_use_rel_p)
- this_hdr->sh_entsize = bed->s->sizeof_rel;
- break;
-
- case SHT_GNU_versym:
- this_hdr->sh_entsize = sizeof (Elf_External_Versym);
- break;
-
- case SHT_GNU_verdef:
- this_hdr->sh_entsize = 0;
- /* objcopy or strip will copy over sh_info, but may not set
- cverdefs. The linker will set cverdefs, but sh_info will be
- zero. */
- if (this_hdr->sh_info == 0)
- this_hdr->sh_info = elf_tdata (abfd)->cverdefs;
- else
- BFD_ASSERT (elf_tdata (abfd)->cverdefs == 0
- || this_hdr->sh_info == elf_tdata (abfd)->cverdefs);
- break;
-
- case SHT_GNU_verneed:
- this_hdr->sh_entsize = 0;
- /* objcopy or strip will copy over sh_info, but may not set
- cverrefs. The linker will set cverrefs, but sh_info will be
- zero. */
- if (this_hdr->sh_info == 0)
- this_hdr->sh_info = elf_tdata (abfd)->cverrefs;
- else
- BFD_ASSERT (elf_tdata (abfd)->cverrefs == 0
- || this_hdr->sh_info == elf_tdata (abfd)->cverrefs);
- break;
-
- case SHT_GROUP:
- this_hdr->sh_entsize = GRP_ENTRY_SIZE;
- break;
-
- case SHT_GNU_HASH:
- this_hdr->sh_entsize = bed->s->arch_size == 64 ? 0 : 4;
- break;
- }
-
- if ((asect->flags & SEC_ALLOC) != 0)
- this_hdr->sh_flags |= SHF_ALLOC;
- if ((asect->flags & SEC_READONLY) == 0)
- this_hdr->sh_flags |= SHF_WRITE;
- if ((asect->flags & SEC_CODE) != 0)
- this_hdr->sh_flags |= SHF_EXECINSTR;
- if ((asect->flags & SEC_MERGE) != 0)
- {
- this_hdr->sh_flags |= SHF_MERGE;
- this_hdr->sh_entsize = asect->entsize;
- }
- if ((asect->flags & SEC_STRINGS) != 0)
- this_hdr->sh_flags |= SHF_STRINGS;
- if ((asect->flags & SEC_GROUP) == 0 && elf_group_name (asect) != NULL)
- this_hdr->sh_flags |= SHF_GROUP;
- if ((asect->flags & SEC_THREAD_LOCAL) != 0)
- {
- this_hdr->sh_flags |= SHF_TLS;
- if (asect->size == 0
- && (asect->flags & SEC_HAS_CONTENTS) == 0)
- {
- struct bfd_link_order *o = asect->map_tail.link_order;
-
- this_hdr->sh_size = 0;
- if (o != NULL)
- {
- this_hdr->sh_size = o->offset + o->size;
- if (this_hdr->sh_size != 0)
- this_hdr->sh_type = SHT_NOBITS;
- }
- }
- }
- if ((asect->flags & (SEC_GROUP | SEC_EXCLUDE)) == SEC_EXCLUDE)
- this_hdr->sh_flags |= SHF_EXCLUDE;
-
- /* If the section has relocs, set up a section header for the
- SHT_REL[A] section. If two relocation sections are required for
- this section, it is up to the processor-specific back-end to
- create the other. */
- if ((asect->flags & SEC_RELOC) != 0)
- {
- /* When doing a relocatable link, create both REL and RELA sections if
- needed. */
- if (arg->link_info
- /* Do the normal setup if we wouldn't create any sections here. */
- && esd->rel.count + esd->rela.count > 0
- && (bfd_link_relocatable (arg->link_info)
- || arg->link_info->emitrelocations))
- {
- if (esd->rel.count && esd->rel.hdr == NULL
- && !_bfd_elf_init_reloc_shdr (abfd, &esd->rel, name,
- false, delay_st_name_p))
- {
- arg->failed = true;
- return;
- }
- if (esd->rela.count && esd->rela.hdr == NULL
- && !_bfd_elf_init_reloc_shdr (abfd, &esd->rela, name,
- true, delay_st_name_p))
- {
- arg->failed = true;
- return;
- }
- }
- else if (!_bfd_elf_init_reloc_shdr (abfd,
- (asect->use_rela_p
- ? &esd->rela : &esd->rel),
- name,
- asect->use_rela_p,
- delay_st_name_p))
- {
- arg->failed = true;
- return;
- }
- }
-
- /* Check for processor-specific section types. */
- sh_type = this_hdr->sh_type;
- if (bed->elf_backend_fake_sections
- && !(*bed->elf_backend_fake_sections) (abfd, this_hdr, asect))
- {
- arg->failed = true;
- return;
- }
-
- if (sh_type == SHT_NOBITS && asect->size != 0)
- {
- /* Don't change the header type from NOBITS if we are being
- called for objcopy --only-keep-debug. */
- this_hdr->sh_type = sh_type;
- }
-}
-
-/* Fill in the contents of a SHT_GROUP section. Called from
- _bfd_elf_compute_section_file_positions for gas, objcopy, and
- when ELF targets use the generic linker, ld. Called for ld -r
- from bfd_elf_final_link. */
-
-void
-bfd_elf_set_group_contents (bfd *abfd, asection *sec, void *failedptrarg)
-{
- bool *failedptr = (bool *) failedptrarg;
- asection *elt, *first;
- unsigned char *loc;
- bool gas;
-
- /* Ignore linker created group section. See elfNN_ia64_object_p in
- elfxx-ia64.c. */
- if ((sec->flags & (SEC_GROUP | SEC_LINKER_CREATED)) != SEC_GROUP
- || sec->size == 0
- || *failedptr)
- return;
-
- if (elf_section_data (sec)->this_hdr.sh_info == 0)
- {
- unsigned long symindx = 0;
-
- /* elf_group_id will have been set up by objcopy and the
- generic linker. */
- if (elf_group_id (sec) != NULL)
- symindx = elf_group_id (sec)->udata.i;
-
- if (symindx == 0)
- {
- /* If called from the assembler, swap_out_syms will have set up
- elf_section_syms.
- PR 25699: A corrupt input file could contain bogus group info. */
- if (sec->index >= elf_num_section_syms (abfd)
- || elf_section_syms (abfd)[sec->index] == NULL)
- {
- *failedptr = true;
- return;
- }
- symindx = elf_section_syms (abfd)[sec->index]->udata.i;
- }
- elf_section_data (sec)->this_hdr.sh_info = symindx;
- }
- else if (elf_section_data (sec)->this_hdr.sh_info == (unsigned int) -2)
- {
- /* The ELF backend linker sets sh_info to -2 when the group
- signature symbol is global, and thus the index can't be
- set until all local symbols are output. */
- asection *igroup;
- struct bfd_elf_section_data *sec_data;
- unsigned long symndx;
- unsigned long extsymoff;
- struct elf_link_hash_entry *h;
-
- /* The point of this little dance to the first SHF_GROUP section
- then back to the SHT_GROUP section is that this gets us to
- the SHT_GROUP in the input object. */
- igroup = elf_sec_group (elf_next_in_group (sec));
- sec_data = elf_section_data (igroup);
- symndx = sec_data->this_hdr.sh_info;
- extsymoff = 0;
- if (!elf_bad_symtab (igroup->owner))
- {
- Elf_Internal_Shdr *symtab_hdr;
-
- symtab_hdr = &elf_tdata (igroup->owner)->symtab_hdr;
- extsymoff = symtab_hdr->sh_info;
- }
- h = elf_sym_hashes (igroup->owner)[symndx - extsymoff];
- while (h->root.type == bfd_link_hash_indirect
- || h->root.type == bfd_link_hash_warning)
- h = (struct elf_link_hash_entry *) h->root.u.i.link;
-
- elf_section_data (sec)->this_hdr.sh_info = h->indx;
- }
-
- /* The contents won't be allocated for "ld -r" or objcopy. */
- gas = true;
- if (sec->contents == NULL)
- {
- gas = false;
- sec->contents = (unsigned char *) bfd_alloc (abfd, sec->size);
-
- /* Arrange for the section to be written out. */
- elf_section_data (sec)->this_hdr.contents = sec->contents;
- if (sec->contents == NULL)
- {
- *failedptr = true;
- return;
- }
- }
-
- loc = sec->contents + sec->size;
-
- /* Get the pointer to the first section in the group that gas
- squirreled away here. objcopy arranges for this to be set to the
- start of the input section group. */
- first = elt = elf_next_in_group (sec);
-
- /* First element is a flag word. Rest of section is elf section
- indices for all the sections of the group. Write them backwards
- just to keep the group in the same order as given in .section
- directives, not that it matters. */
- while (elt != NULL)
- {
- asection *s;
-
- s = elt;
- if (!gas)
- s = s->output_section;
- if (s != NULL
- && !bfd_is_abs_section (s))
- {
- struct bfd_elf_section_data *elf_sec = elf_section_data (s);
- struct bfd_elf_section_data *input_elf_sec = elf_section_data (elt);
-
- if (elf_sec->rel.hdr != NULL
- && (gas
- || (input_elf_sec->rel.hdr != NULL
- && input_elf_sec->rel.hdr->sh_flags & SHF_GROUP) != 0))
- {
- elf_sec->rel.hdr->sh_flags |= SHF_GROUP;
- loc -= 4;
- if (loc == sec->contents)
- break;
- H_PUT_32 (abfd, elf_sec->rel.idx, loc);
- }
- if (elf_sec->rela.hdr != NULL
- && (gas
- || (input_elf_sec->rela.hdr != NULL
- && input_elf_sec->rela.hdr->sh_flags & SHF_GROUP) != 0))
- {
- elf_sec->rela.hdr->sh_flags |= SHF_GROUP;
- loc -= 4;
- if (loc == sec->contents)
- break;
- H_PUT_32 (abfd, elf_sec->rela.idx, loc);
- }
- loc -= 4;
- if (loc == sec->contents)
- break;
- H_PUT_32 (abfd, elf_sec->this_idx, loc);
- }
- elt = elf_next_in_group (elt);
- if (elt == first)
- break;
- }
-
- /* We should always get here with loc == sec->contents + 4, but it is
- possible to craft bogus SHT_GROUP sections that will cause segfaults
- in objcopy without checking loc here and in the loop above. */
- if (loc == sec->contents)
- BFD_ASSERT (0);
- else
- {
- loc -= 4;
- if (loc != sec->contents)
- {
- BFD_ASSERT (0);
- memset (sec->contents + 4, 0, loc - sec->contents);
- loc = sec->contents;
- }
- }
-
- H_PUT_32 (abfd, sec->flags & SEC_LINK_ONCE ? GRP_COMDAT : 0, loc);
-}
-
-/* Given NAME, the name of a relocation section stripped of its
- .rel/.rela prefix, return the section in ABFD to which the
- relocations apply. */
-
-asection *
-_bfd_elf_plt_get_reloc_section (bfd *abfd, const char *name)
-{
- /* If a target needs .got.plt section, relocations in rela.plt/rel.plt
- section likely apply to .got.plt or .got section. */
- if (get_elf_backend_data (abfd)->want_got_plt
- && strcmp (name, ".plt") == 0)
- {
- asection *sec;
-
- name = ".got.plt";
- sec = bfd_get_section_by_name (abfd, name);
- if (sec != NULL)
- return sec;
- name = ".got";
- }
-
- return bfd_get_section_by_name (abfd, name);
-}
-
-/* Return the section to which RELOC_SEC applies. */
-
-static asection *
-elf_get_reloc_section (asection *reloc_sec)
-{
- const char *name;
- unsigned int type;
- bfd *abfd;
- const struct elf_backend_data *bed;
-
- type = elf_section_data (reloc_sec)->this_hdr.sh_type;
- if (type != SHT_REL && type != SHT_RELA)
- return NULL;
-
- /* We look up the section the relocs apply to by name. */
- name = reloc_sec->name;
- if (!startswith (name, ".rel"))
- return NULL;
- name += 4;
- if (type == SHT_RELA && *name++ != 'a')
- return NULL;
-
- abfd = reloc_sec->owner;
- bed = get_elf_backend_data (abfd);
- return bed->get_reloc_section (abfd, name);
-}
-
-/* Assign all ELF section numbers. The dummy first section is handled here
- too. The link/info pointers for the standard section types are filled
- in here too, while we're at it. LINK_INFO will be 0 when arriving
- here for gas, objcopy, and when using the generic ELF linker. */
-
-static bool
-assign_section_numbers (bfd *abfd, struct bfd_link_info *link_info)
-{
- struct elf_obj_tdata *t = elf_tdata (abfd);
- asection *sec;
- unsigned int section_number;
- Elf_Internal_Shdr **i_shdrp;
- struct bfd_elf_section_data *d;
- bool need_symtab;
- size_t amt;
-
- section_number = 1;
-
- _bfd_elf_strtab_clear_all_refs (elf_shstrtab (abfd));
-
- /* SHT_GROUP sections are in relocatable files only. */
- if (link_info == NULL || !link_info->resolve_section_groups)
- {
- size_t reloc_count = 0;
-
- /* Put SHT_GROUP sections first. */
- for (sec = abfd->sections; sec != NULL; sec = sec->next)
- {
- d = elf_section_data (sec);
-
- if (d->this_hdr.sh_type == SHT_GROUP)
- {
- if (sec->flags & SEC_LINKER_CREATED)
- {
- /* Remove the linker created SHT_GROUP sections. */
- bfd_section_list_remove (abfd, sec);
- abfd->section_count--;
- }
- else
- d->this_idx = section_number++;
- }
-
- /* Count relocations. */
- reloc_count += sec->reloc_count;
- }
-
- /* Set/clear HAS_RELOC depending on whether there are relocations. */
- if (reloc_count == 0)
- abfd->flags &= ~HAS_RELOC;
- else
- abfd->flags |= HAS_RELOC;
- }
-
- for (sec = abfd->sections; sec; sec = sec->next)
- {
- d = elf_section_data (sec);
-
- if (d->this_hdr.sh_type != SHT_GROUP)
- d->this_idx = section_number++;
- if (d->this_hdr.sh_name != (unsigned int) -1)
- _bfd_elf_strtab_addref (elf_shstrtab (abfd), d->this_hdr.sh_name);
- if (d->rel.hdr)
- {
- d->rel.idx = section_number++;
- if (d->rel.hdr->sh_name != (unsigned int) -1)
- _bfd_elf_strtab_addref (elf_shstrtab (abfd), d->rel.hdr->sh_name);
- }
- else
- d->rel.idx = 0;
-
- if (d->rela.hdr)
- {
- d->rela.idx = section_number++;
- if (d->rela.hdr->sh_name != (unsigned int) -1)
- _bfd_elf_strtab_addref (elf_shstrtab (abfd), d->rela.hdr->sh_name);
- }
- else
- d->rela.idx = 0;
- }
-
- need_symtab = (bfd_get_symcount (abfd) > 0
- || (link_info == NULL
- && ((abfd->flags & (EXEC_P | DYNAMIC | HAS_RELOC))
- == HAS_RELOC)));
- if (need_symtab)
- {
- elf_onesymtab (abfd) = section_number++;
- _bfd_elf_strtab_addref (elf_shstrtab (abfd), t->symtab_hdr.sh_name);
- if (section_number > ((SHN_LORESERVE - 2) & 0xFFFF))
- {
- elf_section_list *entry;
-
- BFD_ASSERT (elf_symtab_shndx_list (abfd) == NULL);
-
- entry = bfd_zalloc (abfd, sizeof (*entry));
- entry->ndx = section_number++;
- elf_symtab_shndx_list (abfd) = entry;
- entry->hdr.sh_name
- = (unsigned int) _bfd_elf_strtab_add (elf_shstrtab (abfd),
- ".symtab_shndx", false);
- if (entry->hdr.sh_name == (unsigned int) -1)
- return false;
- }
- elf_strtab_sec (abfd) = section_number++;
- _bfd_elf_strtab_addref (elf_shstrtab (abfd), t->strtab_hdr.sh_name);
- }
-
- elf_shstrtab_sec (abfd) = section_number++;
- _bfd_elf_strtab_addref (elf_shstrtab (abfd), t->shstrtab_hdr.sh_name);
- elf_elfheader (abfd)->e_shstrndx = elf_shstrtab_sec (abfd);
-
- if (section_number >= SHN_LORESERVE)
- {
- /* xgettext:c-format */
- _bfd_error_handler (_("%pB: too many sections: %u"),
- abfd, section_number);
- return false;
- }
-
- elf_numsections (abfd) = section_number;
- elf_elfheader (abfd)->e_shnum = section_number;
-
- /* Set up the list of section header pointers, in agreement with the
- indices. */
- amt = section_number * sizeof (Elf_Internal_Shdr *);
- i_shdrp = (Elf_Internal_Shdr **) bfd_zalloc (abfd, amt);
- if (i_shdrp == NULL)
- return false;
-
- i_shdrp[0] = (Elf_Internal_Shdr *) bfd_zalloc (abfd,
- sizeof (Elf_Internal_Shdr));
- if (i_shdrp[0] == NULL)
- {
- bfd_release (abfd, i_shdrp);
- return false;
- }
-
- elf_elfsections (abfd) = i_shdrp;
-
- i_shdrp[elf_shstrtab_sec (abfd)] = &t->shstrtab_hdr;
- if (need_symtab)
- {
- i_shdrp[elf_onesymtab (abfd)] = &t->symtab_hdr;
- if (elf_numsections (abfd) > (SHN_LORESERVE & 0xFFFF))
- {
- elf_section_list * entry = elf_symtab_shndx_list (abfd);
- BFD_ASSERT (entry != NULL);
- i_shdrp[entry->ndx] = & entry->hdr;
- entry->hdr.sh_link = elf_onesymtab (abfd);
- }
- i_shdrp[elf_strtab_sec (abfd)] = &t->strtab_hdr;
- t->symtab_hdr.sh_link = elf_strtab_sec (abfd);
- }
-
- for (sec = abfd->sections; sec; sec = sec->next)
- {
- asection *s;
-
- d = elf_section_data (sec);
-
- i_shdrp[d->this_idx] = &d->this_hdr;
- if (d->rel.idx != 0)
- i_shdrp[d->rel.idx] = d->rel.hdr;
- if (d->rela.idx != 0)
- i_shdrp[d->rela.idx] = d->rela.hdr;
-
- /* Fill in the sh_link and sh_info fields while we're at it. */
-
- /* sh_link of a reloc section is the section index of the symbol
- table. sh_info is the section index of the section to which
- the relocation entries apply. */
- if (d->rel.idx != 0)
- {
- d->rel.hdr->sh_link = elf_onesymtab (abfd);
- d->rel.hdr->sh_info = d->this_idx;
- d->rel.hdr->sh_flags |= SHF_INFO_LINK;
- }
- if (d->rela.idx != 0)
- {
- d->rela.hdr->sh_link = elf_onesymtab (abfd);
- d->rela.hdr->sh_info = d->this_idx;
- d->rela.hdr->sh_flags |= SHF_INFO_LINK;
- }
-
- /* We need to set up sh_link for SHF_LINK_ORDER. */
- if ((d->this_hdr.sh_flags & SHF_LINK_ORDER) != 0)
- {
- s = elf_linked_to_section (sec);
- /* We can now have a NULL linked section pointer.
- This happens when the sh_link field is 0, which is done
- when a linked to section is discarded but the linking
- section has been retained for some reason. */
- if (s)
- {
- /* Check discarded linkonce section. */
- if (discarded_section (s))
- {
- asection *kept;
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB: sh_link of section `%pA' points to"
- " discarded section `%pA' of `%pB'"),
- abfd, d->this_hdr.bfd_section, s, s->owner);
- /* Point to the kept section if it has the same
- size as the discarded one. */
- kept = _bfd_elf_check_kept_section (s, link_info);
- if (kept == NULL)
- {
- bfd_set_error (bfd_error_bad_value);
- return false;
- }
- s = kept;
- }
- /* Handle objcopy. */
- else if (s->output_section == NULL)
- {
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB: sh_link of section `%pA' points to"
- " removed section `%pA' of `%pB'"),
- abfd, d->this_hdr.bfd_section, s, s->owner);
- bfd_set_error (bfd_error_bad_value);
- return false;
- }
- s = s->output_section;
- d->this_hdr.sh_link = elf_section_data (s)->this_idx;
- }
- }
-
- switch (d->this_hdr.sh_type)
- {
- case SHT_REL:
- case SHT_RELA:
- /* sh_link is the section index of the symbol table.
- sh_info is the section index of the section to which the
- relocation entries apply. */
- if (d->this_hdr.sh_link == 0)
- {
- /* FIXME maybe: If this is a reloc section which we are
- treating as a normal section then we likely should
- not be assuming its sh_link is .dynsym or .symtab. */
- if ((sec->flags & SEC_ALLOC) != 0)
- {
- s = bfd_get_section_by_name (abfd, ".dynsym");
- if (s != NULL)
- d->this_hdr.sh_link = elf_section_data (s)->this_idx;
- }
- else
- d->this_hdr.sh_link = elf_onesymtab (abfd);
- }
-
- s = elf_get_reloc_section (sec);
- if (s != NULL)
- {
- d->this_hdr.sh_info = elf_section_data (s)->this_idx;
- d->this_hdr.sh_flags |= SHF_INFO_LINK;
- }
- break;
-
- case SHT_STRTAB:
- /* We assume that a section named .stab*str is a stabs
- string section. We look for a section with the same name
- but without the trailing ``str'', and set its sh_link
- field to point to this section. */
- if (startswith (sec->name, ".stab")
- && strcmp (sec->name + strlen (sec->name) - 3, "str") == 0)
- {
- size_t len;
- char *alc;
-
- len = strlen (sec->name);
- alc = (char *) bfd_malloc (len - 2);
- if (alc == NULL)
- return false;
- memcpy (alc, sec->name, len - 3);
- alc[len - 3] = '\0';
- s = bfd_get_section_by_name (abfd, alc);
- free (alc);
- if (s != NULL)
- {
- elf_section_data (s)->this_hdr.sh_link = d->this_idx;
-
- /* This is a .stab section. */
- elf_section_data (s)->this_hdr.sh_entsize = 12;
- }
- }
- break;
-
- case SHT_DYNAMIC:
- case SHT_DYNSYM:
- case SHT_GNU_verneed:
- case SHT_GNU_verdef:
- /* sh_link is the section header index of the string table
- used for the dynamic entries, or the symbol table, or the
- version strings. */
- s = bfd_get_section_by_name (abfd, ".dynstr");
- if (s != NULL)
- d->this_hdr.sh_link = elf_section_data (s)->this_idx;
- break;
-
- case SHT_GNU_LIBLIST:
- /* sh_link is the section header index of the prelink library
- list used for the dynamic entries, or the symbol table, or
- the version strings. */
- s = bfd_get_section_by_name (abfd, ((sec->flags & SEC_ALLOC)
- ? ".dynstr" : ".gnu.libstr"));
- if (s != NULL)
- d->this_hdr.sh_link = elf_section_data (s)->this_idx;
- break;
-
- case SHT_HASH:
- case SHT_GNU_HASH:
- case SHT_GNU_versym:
- /* sh_link is the section header index of the symbol table
- this hash table or version table is for. */
- s = bfd_get_section_by_name (abfd, ".dynsym");
- if (s != NULL)
- d->this_hdr.sh_link = elf_section_data (s)->this_idx;
- break;
-
- case SHT_GROUP:
- d->this_hdr.sh_link = elf_onesymtab (abfd);
- }
- }
-
- /* Delay setting sh_name to _bfd_elf_write_object_contents so that
- _bfd_elf_assign_file_positions_for_non_load can convert DWARF
- debug section name from .debug_* to .zdebug_* if needed. */
-
- return true;
-}
-
-static bool
-sym_is_global (bfd *abfd, asymbol *sym)
-{
- /* If the backend has a special mapping, use it. */
- const struct elf_backend_data *bed = get_elf_backend_data (abfd);
- if (bed->elf_backend_sym_is_global)
- return (*bed->elf_backend_sym_is_global) (abfd, sym);
-
- return ((sym->flags & (BSF_GLOBAL | BSF_WEAK | BSF_GNU_UNIQUE)) != 0
- || bfd_is_und_section (bfd_asymbol_section (sym))
- || bfd_is_com_section (bfd_asymbol_section (sym)));
-}
-
-/* Filter global symbols of ABFD to include in the import library. All
- SYMCOUNT symbols of ABFD can be examined from their pointers in
- SYMS. Pointers of symbols to keep should be stored contiguously at
- the beginning of that array.
-
- Returns the number of symbols to keep. */
-
-unsigned int
-_bfd_elf_filter_global_symbols (bfd *abfd, struct bfd_link_info *info,
- asymbol **syms, long symcount)
-{
- long src_count, dst_count = 0;
-
- for (src_count = 0; src_count < symcount; src_count++)
- {
- asymbol *sym = syms[src_count];
- char *name = (char *) bfd_asymbol_name (sym);
- struct bfd_link_hash_entry *h;
-
- if (!sym_is_global (abfd, sym))
- continue;
-
- h = bfd_link_hash_lookup (info->hash, name, false, false, false);
- if (h == NULL)
- continue;
- if (h->type != bfd_link_hash_defined && h->type != bfd_link_hash_defweak)
- continue;
- if (h->linker_def || h->ldscript_def)
- continue;
-
- syms[dst_count++] = sym;
- }
-
- syms[dst_count] = NULL;
-
- return dst_count;
-}
-
-/* Don't output symbols for sections that are not going to be output,
- that are duplicates or there is no BFD section. */
-
-static bool
-ignore_sym (asymbol *sym)
-{
- if (sym == NULL)
- return false;
-
- if (sym->section == NULL)
- return true;
-
- if ((sym->flags & BSF_SECTION_SYM) != 0)
- {
- if ((sym->flags & BSF_SECTION_SYM_USED) == 0)
- return true;
- /* With ld -r on generic elf targets it is possible to have
- multiple section symbols in the output for a given section.
- We'd like to get rid of all but the first one. This drops
- them if the first input section is non-zero size, but fails
- to do so if the first input section is zero sized. */
- if (sym->section->output_offset != 0)
- return true;
- }
-
- return discarded_section (sym->section);
-}
-
-/* Map symbol from it's internal number to the external number, moving
- all local symbols to be at the head of the list. */
-
-static bool
-elf_map_symbols (bfd *abfd, unsigned int *pnum_locals)
-{
- unsigned int symcount = bfd_get_symcount (abfd);
- asymbol **syms = bfd_get_outsymbols (abfd);
- asymbol **sect_syms;
- unsigned int num_locals = 0;
- unsigned int num_globals = 0;
- unsigned int max_index = 0;
- unsigned int idx;
- asection *asect;
- asymbol **new_syms;
- size_t amt;
-
-#ifdef DEBUG
- fprintf (stderr, "elf_map_symbols\n");
- fflush (stderr);
-#endif
-
- for (asect = abfd->sections; asect; asect = asect->next)
- {
- if (max_index < asect->index)
- max_index = asect->index;
- }
-
- max_index++;
- amt = max_index * sizeof (asymbol *);
- sect_syms = (asymbol **) bfd_zalloc (abfd, amt);
- if (sect_syms == NULL)
- return false;
- elf_section_syms (abfd) = sect_syms;
- elf_num_section_syms (abfd) = max_index;
-
- /* Init sect_syms entries for any section symbols we have already
- decided to output. */
- for (idx = 0; idx < symcount; idx++)
- {
- asymbol *sym = syms[idx];
-
- if ((sym->flags & BSF_SECTION_SYM) != 0
- && sym->value == 0
- && !ignore_sym (sym)
- && !bfd_is_abs_section (sym->section))
- {
- asection *sec = sym->section;
-
- if (sec->owner != abfd)
- sec = sec->output_section;
-
- sect_syms[sec->index] = syms[idx];
- }
- }
-
- /* Classify all of the symbols. */
- for (idx = 0; idx < symcount; idx++)
- {
- if (ignore_sym (syms[idx]))
- continue;
- if (sym_is_global (abfd, syms[idx]))
- num_globals++;
- else
- num_locals++;
- }
-
- /* We will be adding a section symbol for each normal BFD section. Most
- sections will already have a section symbol in outsymbols, but
- eg. SHT_GROUP sections will not, and we need the section symbol mapped
- at least in that case. */
- for (asect = abfd->sections; asect; asect = asect->next)
- {
- asymbol *sym = asect->symbol;
- /* Don't include ignored section symbols. */
- if (!ignore_sym (sym)
- && sect_syms[asect->index] == NULL)
- {
- if (sym_is_global (abfd, asect->symbol))
- num_globals++;
- else
- num_locals++;
- }
- }
-
- /* Now sort the symbols so the local symbols are first. */
- amt = (num_locals + num_globals) * sizeof (asymbol *);
- new_syms = (asymbol **) bfd_alloc (abfd, amt);
- if (new_syms == NULL)
- return false;
-
- unsigned int num_globals2 = 0;
- unsigned int num_locals2 = 0;
- for (idx = 0; idx < symcount; idx++)
- {
- asymbol *sym = syms[idx];
- unsigned int i;
-
- if (ignore_sym (sym))
- continue;
-
- if (sym_is_global (abfd, sym))
- i = num_locals + num_globals2++;
- else
- i = num_locals2++;
- new_syms[i] = sym;
- sym->udata.i = i + 1;
- }
- for (asect = abfd->sections; asect; asect = asect->next)
- {
- asymbol *sym = asect->symbol;
- if (!ignore_sym (sym)
- && sect_syms[asect->index] == NULL)
- {
- unsigned int i;
-
- sect_syms[asect->index] = sym;
- if (sym_is_global (abfd, sym))
- i = num_locals + num_globals2++;
- else
- i = num_locals2++;
- new_syms[i] = sym;
- sym->udata.i = i + 1;
- }
- }
-
- bfd_set_symtab (abfd, new_syms, num_locals + num_globals);
-
- *pnum_locals = num_locals;
- return true;
-}
-
-/* Align to the maximum file alignment that could be required for any
- ELF data structure. */
-
-static inline file_ptr
-align_file_position (file_ptr off, int align)
-{
- return (off + align - 1) & ~(align - 1);
-}
-
-/* Assign a file position to a section, optionally aligning to the
- required section alignment. */
-
-file_ptr
-_bfd_elf_assign_file_position_for_section (Elf_Internal_Shdr *i_shdrp,
- file_ptr offset,
- bool align)
-{
- if (align && i_shdrp->sh_addralign > 1)
- offset = BFD_ALIGN (offset, i_shdrp->sh_addralign & -i_shdrp->sh_addralign);
- i_shdrp->sh_offset = offset;
- if (i_shdrp->bfd_section != NULL)
- i_shdrp->bfd_section->filepos = offset;
- if (i_shdrp->sh_type != SHT_NOBITS)
- offset += i_shdrp->sh_size;
- return offset;
-}
-
-/* Compute the file positions we are going to put the sections at, and
- otherwise prepare to begin writing out the ELF file. If LINK_INFO
- is not NULL, this is being called by the ELF backend linker. */
-
-bool
-_bfd_elf_compute_section_file_positions (bfd *abfd,
- struct bfd_link_info *link_info)
-{
- const struct elf_backend_data *bed = get_elf_backend_data (abfd);
- struct fake_section_arg fsargs;
- bool failed;
- struct elf_strtab_hash *strtab = NULL;
- Elf_Internal_Shdr *shstrtab_hdr;
- bool need_symtab;
-
- if (abfd->output_has_begun)
- return true;
-
- /* Do any elf backend specific processing first. */
- if (bed->elf_backend_begin_write_processing)
- (*bed->elf_backend_begin_write_processing) (abfd, link_info);
-
- if (!(*bed->elf_backend_init_file_header) (abfd, link_info))
- return false;
-
- fsargs.failed = false;
- fsargs.link_info = link_info;
- bfd_map_over_sections (abfd, elf_fake_sections, &fsargs);
- if (fsargs.failed)
- return false;
-
- if (!assign_section_numbers (abfd, link_info))
- return false;
-
- /* The backend linker builds symbol table information itself. */
- need_symtab = (link_info == NULL
- && (bfd_get_symcount (abfd) > 0
- || ((abfd->flags & (EXEC_P | DYNAMIC | HAS_RELOC))
- == HAS_RELOC)));
- if (need_symtab)
- {
- /* Non-zero if doing a relocatable link. */
- int relocatable_p = ! (abfd->flags & (EXEC_P | DYNAMIC));
-
- if (! swap_out_syms (abfd, &strtab, relocatable_p, link_info))
- return false;
- }
-
- failed = false;
- if (link_info == NULL)
- {
- bfd_map_over_sections (abfd, bfd_elf_set_group_contents, &failed);
- if (failed)
- goto err_free_strtab;
- }
-
- shstrtab_hdr = &elf_tdata (abfd)->shstrtab_hdr;
- /* sh_name was set in init_file_header. */
- shstrtab_hdr->sh_type = SHT_STRTAB;
- shstrtab_hdr->sh_flags = bed->elf_strtab_flags;
- shstrtab_hdr->sh_addr = 0;
- /* sh_size is set in _bfd_elf_assign_file_positions_for_non_load. */
- shstrtab_hdr->sh_entsize = 0;
- shstrtab_hdr->sh_link = 0;
- shstrtab_hdr->sh_info = 0;
- /* sh_offset is set in _bfd_elf_assign_file_positions_for_non_load. */
- shstrtab_hdr->sh_addralign = 1;
-
- if (!assign_file_positions_except_relocs (abfd, link_info))
- goto err_free_strtab;
-
- if (strtab != NULL)
- {
- file_ptr off;
- Elf_Internal_Shdr *hdr;
-
- off = elf_next_file_pos (abfd);
-
- hdr = & elf_symtab_hdr (abfd);
- off = _bfd_elf_assign_file_position_for_section (hdr, off, true);
-
- if (elf_symtab_shndx_list (abfd) != NULL)
- {
- hdr = & elf_symtab_shndx_list (abfd)->hdr;
- if (hdr->sh_size != 0)
- off = _bfd_elf_assign_file_position_for_section (hdr, off, true);
- /* FIXME: What about other symtab_shndx sections in the list ? */
- }
-
- hdr = &elf_tdata (abfd)->strtab_hdr;
- off = _bfd_elf_assign_file_position_for_section (hdr, off, true);
-
- elf_next_file_pos (abfd) = off;
-
- /* Now that we know where the .strtab section goes, write it
- out. */
- if (bfd_seek (abfd, hdr->sh_offset, SEEK_SET) != 0
- || ! _bfd_elf_strtab_emit (abfd, strtab))
- goto err_free_strtab;
- _bfd_elf_strtab_free (strtab);
- }
-
- abfd->output_has_begun = true;
- return true;
-
- err_free_strtab:
- if (strtab != NULL)
- _bfd_elf_strtab_free (strtab);
- return false;
-}
-
-/* Retrieve .eh_frame_hdr. Prior to size_dynamic_sections the
- function effectively returns whether --eh-frame-hdr is given on the
- command line. After size_dynamic_sections the result reflects
- whether .eh_frame_hdr will actually be output (sizing isn't done
- until ldemul_after_allocation). */
-
-static asection *
-elf_eh_frame_hdr (const struct bfd_link_info *info)
-{
- if (info != NULL && is_elf_hash_table (info->hash))
- return elf_hash_table (info)->eh_info.hdr_sec;
- return NULL;
-}
-
-/* Make an initial estimate of the size of the program header. If we
- get the number wrong here, we'll redo section placement. */
-
-static bfd_size_type
-get_program_header_size (bfd *abfd, struct bfd_link_info *info)
-{
- size_t segs;
- asection *s;
- const struct elf_backend_data *bed;
-
- /* Assume we will need exactly two PT_LOAD segments: one for text
- and one for data. */
- segs = 2;
-
- s = bfd_get_section_by_name (abfd, ".interp");
- if (s != NULL && (s->flags & SEC_LOAD) != 0 && s->size != 0)
- {
- /* If we have a loadable interpreter section, we need a
- PT_INTERP segment. In this case, assume we also need a
- PT_PHDR segment, although that may not be true for all
- targets. */
- segs += 2;
- }
-
- if (bfd_get_section_by_name (abfd, ".dynamic") != NULL)
- {
- /* We need a PT_DYNAMIC segment. */
- ++segs;
- }
-
- if (info != NULL && info->relro)
- {
- /* We need a PT_GNU_RELRO segment. */
- ++segs;
- }
-
- if (elf_eh_frame_hdr (info))
- {
- /* We need a PT_GNU_EH_FRAME segment. */
- ++segs;
- }
-
- if (elf_stack_flags (abfd))
- {
- /* We need a PT_GNU_STACK segment. */
- ++segs;
- }
-
- if (elf_sframe (abfd))
- {
- /* We need a PT_GNU_SFRAME segment. */
- ++segs;
- }
-
- s = bfd_get_section_by_name (abfd,
- NOTE_GNU_PROPERTY_SECTION_NAME);
- if (s != NULL && s->size != 0)
- {
- /* We need a PT_GNU_PROPERTY segment. */
- ++segs;
- }
-
- for (s = abfd->sections; s != NULL; s = s->next)
- {
- if ((s->flags & SEC_LOAD) != 0
- && elf_section_type (s) == SHT_NOTE)
- {
- unsigned int alignment_power;
- /* We need a PT_NOTE segment. */
- ++segs;
- /* Try to create just one PT_NOTE segment for all adjacent
- loadable SHT_NOTE sections. gABI requires that within a
- PT_NOTE segment (and also inside of each SHT_NOTE section)
- each note should have the same alignment. So we check
- whether the sections are correctly aligned. */
- alignment_power = s->alignment_power;
- while (s->next != NULL
- && s->next->alignment_power == alignment_power
- && (s->next->flags & SEC_LOAD) != 0
- && elf_section_type (s->next) == SHT_NOTE)
- s = s->next;
- }
- }
-
- for (s = abfd->sections; s != NULL; s = s->next)
- {
- if (s->flags & SEC_THREAD_LOCAL)
- {
- /* We need a PT_TLS segment. */
- ++segs;
- break;
- }
- }
-
- bed = get_elf_backend_data (abfd);
-
- if ((abfd->flags & D_PAGED) != 0
- && (elf_tdata (abfd)->has_gnu_osabi & elf_gnu_osabi_mbind) != 0)
- {
- /* Add a PT_GNU_MBIND segment for each mbind section. */
- bfd_vma commonpagesize;
- unsigned int page_align_power;
-
- if (info != NULL)
- commonpagesize = info->commonpagesize;
- else
- commonpagesize = bed->commonpagesize;
- page_align_power = bfd_log2 (commonpagesize);
- for (s = abfd->sections; s != NULL; s = s->next)
- if (elf_section_flags (s) & SHF_GNU_MBIND)
- {
- if (elf_section_data (s)->this_hdr.sh_info > PT_GNU_MBIND_NUM)
- {
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB: GNU_MBIND section `%pA' has invalid "
- "sh_info field: %d"),
- abfd, s, elf_section_data (s)->this_hdr.sh_info);
- continue;
- }
- /* Align mbind section to page size. */
- if (s->alignment_power < page_align_power)
- s->alignment_power = page_align_power;
- segs ++;
- }
- }
-
- /* Let the backend count up any program headers it might need. */
- if (bed->elf_backend_additional_program_headers)
- {
- int a;
-
- a = (*bed->elf_backend_additional_program_headers) (abfd, info);
- if (a == -1)
- abort ();
- segs += a;
- }
-
- return segs * bed->s->sizeof_phdr;
-}
-
-/* Find the segment that contains the output_section of section. */
-
-Elf_Internal_Phdr *
-_bfd_elf_find_segment_containing_section (bfd * abfd, asection * section)
-{
- struct elf_segment_map *m;
- Elf_Internal_Phdr *p;
-
- for (m = elf_seg_map (abfd), p = elf_tdata (abfd)->phdr;
- m != NULL;
- m = m->next, p++)
- {
- int i;
-
- for (i = m->count - 1; i >= 0; i--)
- if (m->sections[i] == section)
- return p;
- }
-
- return NULL;
-}
-
-/* Create a mapping from a set of sections to a program segment. */
-
-static struct elf_segment_map *
-make_mapping (bfd *abfd,
- asection **sections,
- unsigned int from,
- unsigned int to,
- bool phdr)
-{
- struct elf_segment_map *m;
- unsigned int i;
- asection **hdrpp;
- size_t amt;
-
- amt = sizeof (struct elf_segment_map) - sizeof (asection *);
- amt += (to - from) * sizeof (asection *);
- m = (struct elf_segment_map *) bfd_zalloc (abfd, amt);
- if (m == NULL)
- return NULL;
- m->next = NULL;
- m->p_type = PT_LOAD;
- for (i = from, hdrpp = sections + from; i < to; i++, hdrpp++)
- m->sections[i - from] = *hdrpp;
- m->count = to - from;
-
- if (from == 0 && phdr)
- {
- /* Include the headers in the first PT_LOAD segment. */
- m->includes_filehdr = 1;
- m->includes_phdrs = 1;
- }
-
- return m;
-}
-
-/* Create the PT_DYNAMIC segment, which includes DYNSEC. Returns NULL
- on failure. */
-
-struct elf_segment_map *
-_bfd_elf_make_dynamic_segment (bfd *abfd, asection *dynsec)
-{
- struct elf_segment_map *m;
-
- m = (struct elf_segment_map *) bfd_zalloc (abfd,
- sizeof (struct elf_segment_map));
- if (m == NULL)
- return NULL;
- m->next = NULL;
- m->p_type = PT_DYNAMIC;
- m->count = 1;
- m->sections[0] = dynsec;
-
- return m;
-}
-
-/* Possibly add or remove segments from the segment map. */
-
-static bool
-elf_modify_segment_map (bfd *abfd,
- struct bfd_link_info *info,
- bool remove_empty_load)
-{
- struct elf_segment_map **m;
- const struct elf_backend_data *bed;
-
- /* The placement algorithm assumes that non allocated sections are
- not in PT_LOAD segments. We ensure this here by removing such
- sections from the segment map. We also remove excluded
- sections. Finally, any PT_LOAD segment without sections is
- removed. */
- m = &elf_seg_map (abfd);
- while (*m)
- {
- unsigned int i, new_count;
-
- for (new_count = 0, i = 0; i < (*m)->count; i++)
- {
- if (((*m)->sections[i]->flags & SEC_EXCLUDE) == 0
- && (((*m)->sections[i]->flags & SEC_ALLOC) != 0
- || (*m)->p_type != PT_LOAD))
- {
- (*m)->sections[new_count] = (*m)->sections[i];
- new_count++;
- }
- }
- (*m)->count = new_count;
-
- if (remove_empty_load
- && (*m)->p_type == PT_LOAD
- && (*m)->count == 0
- && !(*m)->includes_phdrs)
- *m = (*m)->next;
- else
- m = &(*m)->next;
- }
-
- bed = get_elf_backend_data (abfd);
- if (bed->elf_backend_modify_segment_map != NULL)
- {
- if (!(*bed->elf_backend_modify_segment_map) (abfd, info))
- return false;
- }
-
- return true;
-}
-
-#define IS_TBSS(s) \
- ((s->flags & (SEC_THREAD_LOCAL | SEC_LOAD)) == SEC_THREAD_LOCAL)
-
-/* Set up a mapping from BFD sections to program segments. Update
- NEED_LAYOUT if the section layout is changed. */
-
-bool
-_bfd_elf_map_sections_to_segments (bfd *abfd,
- struct bfd_link_info *info,
- bool *need_layout)
-{
- unsigned int count;
- struct elf_segment_map *m;
- asection **sections = NULL;
- const struct elf_backend_data *bed = get_elf_backend_data (abfd);
- bool no_user_phdrs;
-
- no_user_phdrs = elf_seg_map (abfd) == NULL;
-
- if (info != NULL)
- {
- info->user_phdrs = !no_user_phdrs;
-
- /* Size the relative relocations if DT_RELR is enabled. */
- if (info->enable_dt_relr
- && need_layout != NULL
- && bed->size_relative_relocs
- && !bed->size_relative_relocs (info, need_layout))
- info->callbacks->einfo
- (_("%F%P: failed to size relative relocations\n"));
- }
-
- if (no_user_phdrs && bfd_count_sections (abfd) != 0)
- {
- asection *s;
- unsigned int i;
- struct elf_segment_map *mfirst;
- struct elf_segment_map **pm;
- asection *last_hdr;
- bfd_vma last_size;
- unsigned int hdr_index;
- bfd_vma maxpagesize;
- asection **hdrpp;
- bool phdr_in_segment;
- bool writable;
- bool executable;
- unsigned int tls_count = 0;
- asection *first_tls = NULL;
- asection *first_mbind = NULL;
- asection *dynsec, *eh_frame_hdr;
- asection *sframe;
- size_t amt;
- bfd_vma addr_mask, wrap_to = 0; /* Bytes. */
- bfd_size_type phdr_size; /* Octets/bytes. */
- unsigned int opb = bfd_octets_per_byte (abfd, NULL);
-
- /* Select the allocated sections, and sort them. */
-
- amt = bfd_count_sections (abfd) * sizeof (asection *);
- sections = (asection **) bfd_malloc (amt);
- if (sections == NULL)
- goto error_return;
-
- /* Calculate top address, avoiding undefined behaviour of shift
- left operator when shift count is equal to size of type
- being shifted. */
- addr_mask = ((bfd_vma) 1 << (bfd_arch_bits_per_address (abfd) - 1)) - 1;
- addr_mask = (addr_mask << 1) + 1;
-
- i = 0;
- for (s = abfd->sections; s != NULL; s = s->next)
- {
- if ((s->flags & SEC_ALLOC) != 0)
- {
- /* target_index is unused until bfd_elf_final_link
- starts output of section symbols. Use it to make
- qsort stable. */
- s->target_index = i;
- sections[i] = s;
- ++i;
- /* A wrapping section potentially clashes with header. */
- if (((s->lma + s->size / opb) & addr_mask) < (s->lma & addr_mask))
- wrap_to = (s->lma + s->size / opb) & addr_mask;
- }
- }
- BFD_ASSERT (i <= bfd_count_sections (abfd));
- count = i;
-
- qsort (sections, (size_t) count, sizeof (asection *), elf_sort_sections);
-
- phdr_size = elf_program_header_size (abfd);
- if (phdr_size == (bfd_size_type) -1)
- phdr_size = get_program_header_size (abfd, info);
- phdr_size += bed->s->sizeof_ehdr;
- /* phdr_size is compared to LMA values which are in bytes. */
- phdr_size /= opb;
- if (info != NULL)
- maxpagesize = info->maxpagesize;
- else
- maxpagesize = bed->maxpagesize;
- if (maxpagesize == 0)
- maxpagesize = 1;
- phdr_in_segment = info != NULL && info->load_phdrs;
- if (count != 0
- && (((sections[0]->lma & addr_mask) & (maxpagesize - 1))
- >= (phdr_size & (maxpagesize - 1))))
- /* For compatibility with old scripts that may not be using
- SIZEOF_HEADERS, add headers when it looks like space has
- been left for them. */
- phdr_in_segment = true;
-
- /* Build the mapping. */
- mfirst = NULL;
- pm = &mfirst;
-
- /* If we have a .interp section, then create a PT_PHDR segment for
- the program headers and a PT_INTERP segment for the .interp
- section. */
- s = bfd_get_section_by_name (abfd, ".interp");
- if (s != NULL && (s->flags & SEC_LOAD) != 0 && s->size != 0)
- {
- amt = sizeof (struct elf_segment_map);
- m = (struct elf_segment_map *) bfd_zalloc (abfd, amt);
- if (m == NULL)
- goto error_return;
- m->next = NULL;
- m->p_type = PT_PHDR;
- m->p_flags = PF_R;
- m->p_flags_valid = 1;
- m->includes_phdrs = 1;
- phdr_in_segment = true;
- *pm = m;
- pm = &m->next;
-
- amt = sizeof (struct elf_segment_map);
- m = (struct elf_segment_map *) bfd_zalloc (abfd, amt);
- if (m == NULL)
- goto error_return;
- m->next = NULL;
- m->p_type = PT_INTERP;
- m->count = 1;
- m->sections[0] = s;
-
- *pm = m;
- pm = &m->next;
- }
-
- /* Look through the sections. We put sections in the same program
- segment when the start of the second section can be placed within
- a few bytes of the end of the first section. */
- last_hdr = NULL;
- last_size = 0;
- hdr_index = 0;
- writable = false;
- executable = false;
- dynsec = bfd_get_section_by_name (abfd, ".dynamic");
- if (dynsec != NULL
- && (dynsec->flags & SEC_LOAD) == 0)
- dynsec = NULL;
-
- if ((abfd->flags & D_PAGED) == 0)
- phdr_in_segment = false;
-
- /* Deal with -Ttext or something similar such that the first section
- is not adjacent to the program headers. This is an
- approximation, since at this point we don't know exactly how many
- program headers we will need. */
- if (phdr_in_segment && count > 0)
- {
- bfd_vma phdr_lma; /* Bytes. */
- bool separate_phdr = false;
-
- phdr_lma = (sections[0]->lma - phdr_size) & addr_mask & -maxpagesize;
- if (info != NULL
- && info->separate_code
- && (sections[0]->flags & SEC_CODE) != 0)
- {
- /* If data sections should be separate from code and
- thus not executable, and the first section is
- executable then put the file and program headers in
- their own PT_LOAD. */
- if (!info->one_rosegment)
- separate_phdr = true;
-
- if ((((phdr_lma + phdr_size - 1) & addr_mask & -maxpagesize)
- == (sections[0]->lma & addr_mask & -maxpagesize)))
- {
- /* The file and program headers are currently on the
- same page as the first section. Put them on the
- previous page if we can. */
- if (phdr_lma >= maxpagesize)
- phdr_lma -= maxpagesize;
- else
- separate_phdr = false;
- }
- }
- if ((sections[0]->lma & addr_mask) < phdr_lma
- || (sections[0]->lma & addr_mask) < phdr_size)
- /* If file and program headers would be placed at the end
- of memory then it's probably better to omit them. */
- phdr_in_segment = false;
- else if (phdr_lma < wrap_to)
- /* If a section wraps around to where we'll be placing
- file and program headers, then the headers will be
- overwritten. */
- phdr_in_segment = false;
- else if (separate_phdr)
- {
- m = make_mapping (abfd, sections, 0, 0, phdr_in_segment);
- if (m == NULL)
- goto error_return;
- m->p_paddr = phdr_lma * opb;
- m->p_vaddr_offset
- = (sections[0]->vma - phdr_size) & addr_mask & -maxpagesize;
- m->p_paddr_valid = 1;
- *pm = m;
- pm = &m->next;
- phdr_in_segment = false;
- }
- }
-
- for (i = 0, hdrpp = sections; i < count; i++, hdrpp++)
- {
- asection *hdr;
- bool new_segment;
-
- hdr = *hdrpp;
-
- /* See if this section and the last one will fit in the same
- segment. */
-
- if (last_hdr == NULL)
- {
- /* If we don't have a segment yet, then we don't need a new
- one (we build the last one after this loop). */
- new_segment = false;
- }
- else if (last_hdr->lma - last_hdr->vma != hdr->lma - hdr->vma)
- {
- /* If this section has a different relation between the
- virtual address and the load address, then we need a new
- segment. */
- new_segment = true;
- }
- else if (hdr->lma < last_hdr->lma + last_size
- || last_hdr->lma + last_size < last_hdr->lma)
- {
- /* If this section has a load address that makes it overlap
- the previous section, then we need a new segment. */
- new_segment = true;
- }
- else if ((abfd->flags & D_PAGED) != 0
- && (((last_hdr->lma + last_size - 1) & -maxpagesize)
- == (hdr->lma & -maxpagesize)))
- {
- /* If we are demand paged then we can't map two disk
- pages onto the same memory page. */
- new_segment = false;
- }
- /* In the next test we have to be careful when last_hdr->lma is close
- to the end of the address space. If the aligned address wraps
- around to the start of the address space, then there are no more
- pages left in memory and it is OK to assume that the current
- section can be included in the current segment. */
- else if ((BFD_ALIGN (last_hdr->lma + last_size, maxpagesize)
- + maxpagesize > last_hdr->lma)
- && (BFD_ALIGN (last_hdr->lma + last_size, maxpagesize)
- + maxpagesize <= hdr->lma))
- {
- /* If putting this section in this segment would force us to
- skip a page in the segment, then we need a new segment. */
- new_segment = true;
- }
- else if ((last_hdr->flags & (SEC_LOAD | SEC_THREAD_LOCAL)) == 0
- && (hdr->flags & (SEC_LOAD | SEC_THREAD_LOCAL)) != 0)
- {
- /* We don't want to put a loaded section after a
- nonloaded (ie. bss style) section in the same segment
- as that will force the non-loaded section to be loaded.
- Consider .tbss sections as loaded for this purpose. */
- new_segment = true;
- }
- else if ((abfd->flags & D_PAGED) == 0)
- {
- /* If the file is not demand paged, which means that we
- don't require the sections to be correctly aligned in the
- file, then there is no other reason for a new segment. */
- new_segment = false;
- }
- else if (info != NULL
- && info->separate_code
- && executable != ((hdr->flags & SEC_CODE) != 0))
- {
- new_segment = true;
- }
- else if (! writable
- && (hdr->flags & SEC_READONLY) == 0)
- {
- /* We don't want to put a writable section in a read only
- segment. */
- new_segment = true;
- }
- else
- {
- /* Otherwise, we can use the same segment. */
- new_segment = false;
- }
-
- /* Allow interested parties a chance to override our decision. */
- if (last_hdr != NULL
- && info != NULL
- && info->callbacks->override_segment_assignment != NULL)
- new_segment
- = info->callbacks->override_segment_assignment (info, abfd, hdr,
- last_hdr,
- new_segment);
-
- if (! new_segment)
- {
- if ((hdr->flags & SEC_READONLY) == 0)
- writable = true;
- if ((hdr->flags & SEC_CODE) != 0)
- executable = true;
- last_hdr = hdr;
- /* .tbss sections effectively have zero size. */
- last_size = (!IS_TBSS (hdr) ? hdr->size : 0) / opb;
- continue;
- }
-
- /* We need a new program segment. We must create a new program
- header holding all the sections from hdr_index until hdr. */
-
- m = make_mapping (abfd, sections, hdr_index, i, phdr_in_segment);
- if (m == NULL)
- goto error_return;
-
- *pm = m;
- pm = &m->next;
-
- if ((hdr->flags & SEC_READONLY) == 0)
- writable = true;
- else
- writable = false;
-
- if ((hdr->flags & SEC_CODE) == 0)
- executable = false;
- else
- executable = true;
-
- last_hdr = hdr;
- /* .tbss sections effectively have zero size. */
- last_size = (!IS_TBSS (hdr) ? hdr->size : 0) / opb;
- hdr_index = i;
- phdr_in_segment = false;
- }
-
- /* Create a final PT_LOAD program segment, but not if it's just
- for .tbss. */
- if (last_hdr != NULL
- && (i - hdr_index != 1
- || !IS_TBSS (last_hdr)))
- {
- m = make_mapping (abfd, sections, hdr_index, i, phdr_in_segment);
- if (m == NULL)
- goto error_return;
-
- *pm = m;
- pm = &m->next;
- }
-
- /* If there is a .dynamic section, throw in a PT_DYNAMIC segment. */
- if (dynsec != NULL)
- {
- m = _bfd_elf_make_dynamic_segment (abfd, dynsec);
- if (m == NULL)
- goto error_return;
- *pm = m;
- pm = &m->next;
- }
-
- /* For each batch of consecutive loadable SHT_NOTE sections,
- add a PT_NOTE segment. We don't use bfd_get_section_by_name,
- because if we link together nonloadable .note sections and
- loadable .note sections, we will generate two .note sections
- in the output file. */
- for (s = abfd->sections; s != NULL; s = s->next)
- {
- if ((s->flags & SEC_LOAD) != 0
- && elf_section_type (s) == SHT_NOTE)
- {
- asection *s2;
- unsigned int alignment_power = s->alignment_power;
-
- count = 1;
- for (s2 = s; s2->next != NULL; s2 = s2->next)
- {
- if (s2->next->alignment_power == alignment_power
- && (s2->next->flags & SEC_LOAD) != 0
- && elf_section_type (s2->next) == SHT_NOTE
- && align_power (s2->lma + s2->size / opb,
- alignment_power)
- == s2->next->lma)
- count++;
- else
- break;
- }
- amt = sizeof (struct elf_segment_map) - sizeof (asection *);
- amt += count * sizeof (asection *);
- m = (struct elf_segment_map *) bfd_zalloc (abfd, amt);
- if (m == NULL)
- goto error_return;
- m->next = NULL;
- m->p_type = PT_NOTE;
- m->count = count;
- while (count > 1)
- {
- m->sections[m->count - count--] = s;
- BFD_ASSERT ((s->flags & SEC_THREAD_LOCAL) == 0);
- s = s->next;
- }
- m->sections[m->count - 1] = s;
- BFD_ASSERT ((s->flags & SEC_THREAD_LOCAL) == 0);
- *pm = m;
- pm = &m->next;
- }
- if (s->flags & SEC_THREAD_LOCAL)
- {
- if (! tls_count)
- first_tls = s;
- tls_count++;
- }
- if (first_mbind == NULL
- && (elf_section_flags (s) & SHF_GNU_MBIND) != 0)
- first_mbind = s;
- }
-
- /* If there are any SHF_TLS output sections, add PT_TLS segment. */
- if (tls_count > 0)
- {
- amt = sizeof (struct elf_segment_map) - sizeof (asection *);
- amt += tls_count * sizeof (asection *);
- m = (struct elf_segment_map *) bfd_zalloc (abfd, amt);
- if (m == NULL)
- goto error_return;
- m->next = NULL;
- m->p_type = PT_TLS;
- m->count = tls_count;
- /* Mandated PF_R. */
- m->p_flags = PF_R;
- m->p_flags_valid = 1;
- s = first_tls;
- for (i = 0; i < tls_count; ++i)
- {
- if ((s->flags & SEC_THREAD_LOCAL) == 0)
- {
- _bfd_error_handler
- (_("%pB: TLS sections are not adjacent:"), abfd);
- s = first_tls;
- i = 0;
- while (i < tls_count)
- {
- if ((s->flags & SEC_THREAD_LOCAL) != 0)
- {
- _bfd_error_handler (_(" TLS: %pA"), s);
- i++;
- }
- else
- _bfd_error_handler (_(" non-TLS: %pA"), s);
- s = s->next;
- }
- bfd_set_error (bfd_error_bad_value);
- goto error_return;
- }
- m->sections[i] = s;
- s = s->next;
- }
-
- *pm = m;
- pm = &m->next;
- }
-
- if (first_mbind
- && (abfd->flags & D_PAGED) != 0
- && (elf_tdata (abfd)->has_gnu_osabi & elf_gnu_osabi_mbind) != 0)
- for (s = first_mbind; s != NULL; s = s->next)
- if ((elf_section_flags (s) & SHF_GNU_MBIND) != 0
- && elf_section_data (s)->this_hdr.sh_info <= PT_GNU_MBIND_NUM)
- {
- /* Mandated PF_R. */
- unsigned long p_flags = PF_R;
- if ((s->flags & SEC_READONLY) == 0)
- p_flags |= PF_W;
- if ((s->flags & SEC_CODE) != 0)
- p_flags |= PF_X;
-
- amt = sizeof (struct elf_segment_map) + sizeof (asection *);
- m = bfd_zalloc (abfd, amt);
- if (m == NULL)
- goto error_return;
- m->next = NULL;
- m->p_type = (PT_GNU_MBIND_LO
- + elf_section_data (s)->this_hdr.sh_info);
- m->count = 1;
- m->p_flags_valid = 1;
- m->sections[0] = s;
- m->p_flags = p_flags;
-
- *pm = m;
- pm = &m->next;
- }
-
- s = bfd_get_section_by_name (abfd,
- NOTE_GNU_PROPERTY_SECTION_NAME);
- if (s != NULL && s->size != 0)
- {
- amt = sizeof (struct elf_segment_map) + sizeof (asection *);
- m = bfd_zalloc (abfd, amt);
- if (m == NULL)
- goto error_return;
- m->next = NULL;
- m->p_type = PT_GNU_PROPERTY;
- m->count = 1;
- m->p_flags_valid = 1;
- m->sections[0] = s;
- m->p_flags = PF_R;
- *pm = m;
- pm = &m->next;
- }
-
- /* If there is a .eh_frame_hdr section, throw in a PT_GNU_EH_FRAME
- segment. */
- eh_frame_hdr = elf_eh_frame_hdr (info);
- if (eh_frame_hdr != NULL
- && (eh_frame_hdr->output_section->flags & SEC_LOAD) != 0)
- {
- amt = sizeof (struct elf_segment_map);
- m = (struct elf_segment_map *) bfd_zalloc (abfd, amt);
- if (m == NULL)
- goto error_return;
- m->next = NULL;
- m->p_type = PT_GNU_EH_FRAME;
- m->count = 1;
- m->sections[0] = eh_frame_hdr->output_section;
-
- *pm = m;
- pm = &m->next;
- }
-
- /* If there is a .sframe section, throw in a PT_GNU_SFRAME
- segment. */
- sframe = elf_sframe (abfd);
- if (sframe != NULL
- && (sframe->output_section->flags & SEC_LOAD) != 0
- && sframe->size != 0)
- {
- amt = sizeof (struct elf_segment_map);
- m = (struct elf_segment_map *) bfd_zalloc (abfd, amt);
- if (m == NULL)
- goto error_return;
- m->next = NULL;
- m->p_type = PT_GNU_SFRAME;
- m->count = 1;
- m->sections[0] = sframe->output_section;
-
- *pm = m;
- pm = &m->next;
- }
-
- if (elf_stack_flags (abfd))
- {
- amt = sizeof (struct elf_segment_map);
- m = (struct elf_segment_map *) bfd_zalloc (abfd, amt);
- if (m == NULL)
- goto error_return;
- m->next = NULL;
- m->p_type = PT_GNU_STACK;
- m->p_flags = elf_stack_flags (abfd);
- m->p_align = bed->stack_align;
- m->p_flags_valid = 1;
- m->p_align_valid = m->p_align != 0;
- if (info->stacksize > 0)
- {
- m->p_size = info->stacksize;
- m->p_size_valid = 1;
- }
-
- *pm = m;
- pm = &m->next;
- }
-
- if (info != NULL && info->relro)
- {
- for (m = mfirst; m != NULL; m = m->next)
- {
- if (m->p_type == PT_LOAD
- && m->count != 0
- && m->sections[0]->vma >= info->relro_start
- && m->sections[0]->vma < info->relro_end)
- {
- i = m->count;
- while (--i != (unsigned) -1)
- {
- if (m->sections[i]->size > 0
- && (m->sections[i]->flags & SEC_LOAD) != 0
- && (m->sections[i]->flags & SEC_HAS_CONTENTS) != 0)
- break;
- }
-
- if (i != (unsigned) -1)
- break;
- }
- }
-
- /* Make a PT_GNU_RELRO segment only when it isn't empty. */
- if (m != NULL)
- {
- amt = sizeof (struct elf_segment_map);
- m = (struct elf_segment_map *) bfd_zalloc (abfd, amt);
- if (m == NULL)
- goto error_return;
- m->next = NULL;
- m->p_type = PT_GNU_RELRO;
- *pm = m;
- pm = &m->next;
- }
- }
-
- free (sections);
- elf_seg_map (abfd) = mfirst;
- }
-
- if (!elf_modify_segment_map (abfd, info, no_user_phdrs || info == NULL))
- return false;
-
- for (count = 0, m = elf_seg_map (abfd); m != NULL; m = m->next)
- ++count;
- elf_program_header_size (abfd) = count * bed->s->sizeof_phdr;
-
- return true;
-
- error_return:
- free (sections);
- return false;
-}
-
-/* Sort sections by address. */
-
-static int
-elf_sort_sections (const void *arg1, const void *arg2)
-{
- const asection *sec1 = *(const asection **) arg1;
- const asection *sec2 = *(const asection **) arg2;
- bfd_size_type size1, size2;
-
- /* Sort by LMA first, since this is the address used to
- place the section into a segment. */
- if (sec1->lma < sec2->lma)
- return -1;
- else if (sec1->lma > sec2->lma)
- return 1;
-
- /* Then sort by VMA. Normally the LMA and the VMA will be
- the same, and this will do nothing. */
- if (sec1->vma < sec2->vma)
- return -1;
- else if (sec1->vma > sec2->vma)
- return 1;
-
- /* Put !SEC_LOAD sections after SEC_LOAD ones. */
-
-#define TOEND(x) (((x)->flags & (SEC_LOAD | SEC_THREAD_LOCAL)) == 0 \
- && (x)->size != 0)
-
- if (TOEND (sec1))
- {
- if (!TOEND (sec2))
- return 1;
- }
- else if (TOEND (sec2))
- return -1;
-
-#undef TOEND
-
- /* Sort by size, to put zero sized sections
- before others at the same address. */
-
- size1 = (sec1->flags & SEC_LOAD) ? sec1->size : 0;
- size2 = (sec2->flags & SEC_LOAD) ? sec2->size : 0;
-
- if (size1 < size2)
- return -1;
- if (size1 > size2)
- return 1;
-
- return sec1->target_index - sec2->target_index;
-}
-
-/* This qsort comparison functions sorts PT_LOAD segments first and
- by p_paddr, for assign_file_positions_for_load_sections. */
-
-static int
-elf_sort_segments (const void *arg1, const void *arg2)
-{
- const struct elf_segment_map *m1 = *(const struct elf_segment_map **) arg1;
- const struct elf_segment_map *m2 = *(const struct elf_segment_map **) arg2;
-
- if (m1->p_type != m2->p_type)
- {
- if (m1->p_type == PT_NULL)
- return 1;
- if (m2->p_type == PT_NULL)
- return -1;
- return m1->p_type < m2->p_type ? -1 : 1;
- }
- if (m1->includes_filehdr != m2->includes_filehdr)
- return m1->includes_filehdr ? -1 : 1;
- if (m1->no_sort_lma != m2->no_sort_lma)
- return m1->no_sort_lma ? -1 : 1;
- if (m1->p_type == PT_LOAD && !m1->no_sort_lma)
- {
- bfd_vma lma1, lma2; /* Octets. */
- lma1 = 0;
- if (m1->p_paddr_valid)
- lma1 = m1->p_paddr;
- else if (m1->count != 0)
- {
- unsigned int opb = bfd_octets_per_byte (m1->sections[0]->owner,
- m1->sections[0]);
- lma1 = (m1->sections[0]->lma + m1->p_vaddr_offset) * opb;
- }
- lma2 = 0;
- if (m2->p_paddr_valid)
- lma2 = m2->p_paddr;
- else if (m2->count != 0)
- {
- unsigned int opb = bfd_octets_per_byte (m2->sections[0]->owner,
- m2->sections[0]);
- lma2 = (m2->sections[0]->lma + m2->p_vaddr_offset) * opb;
- }
- if (lma1 != lma2)
- return lma1 < lma2 ? -1 : 1;
- }
- if (m1->idx != m2->idx)
- return m1->idx < m2->idx ? -1 : 1;
- return 0;
-}
-
-/* Ian Lance Taylor writes:
-
- We shouldn't be using % with a negative signed number. That's just
- not good. We have to make sure either that the number is not
- negative, or that the number has an unsigned type. When the types
- are all the same size they wind up as unsigned. When file_ptr is a
- larger signed type, the arithmetic winds up as signed long long,
- which is wrong.
-
- What we're trying to say here is something like ``increase OFF by
- the least amount that will cause it to be equal to the VMA modulo
- the page size.'' */
-/* In other words, something like:
-
- vma_offset = m->sections[0]->vma % bed->maxpagesize;
- off_offset = off % bed->maxpagesize;
- if (vma_offset < off_offset)
- adjustment = vma_offset + bed->maxpagesize - off_offset;
- else
- adjustment = vma_offset - off_offset;
-
- which can be collapsed into the expression below. */
-
-static file_ptr
-vma_page_aligned_bias (bfd_vma vma, ufile_ptr off, bfd_vma maxpagesize)
-{
- /* PR binutils/16199: Handle an alignment of zero. */
- if (maxpagesize == 0)
- maxpagesize = 1;
- return ((vma - off) % maxpagesize);
-}
-
-static void
-print_segment_map (const struct elf_segment_map *m)
-{
- unsigned int j;
- const char *pt = get_segment_type (m->p_type);
- char buf[32];
-
- if (pt == NULL)
- {
- if (m->p_type >= PT_LOPROC && m->p_type <= PT_HIPROC)
- sprintf (buf, "LOPROC+%7.7x",
- (unsigned int) (m->p_type - PT_LOPROC));
- else if (m->p_type >= PT_LOOS && m->p_type <= PT_HIOS)
- sprintf (buf, "LOOS+%7.7x",
- (unsigned int) (m->p_type - PT_LOOS));
- else
- snprintf (buf, sizeof (buf), "%8.8x",
- (unsigned int) m->p_type);
- pt = buf;
- }
- fflush (stdout);
- fprintf (stderr, "%s:", pt);
- for (j = 0; j < m->count; j++)
- fprintf (stderr, " %s", m->sections [j]->name);
- putc ('\n',stderr);
- fflush (stderr);
-}
-
-/* Assign file positions to the sections based on the mapping from
- sections to segments. This function also sets up some fields in
- the file header. */
-
-static bool
-assign_file_positions_for_load_sections (bfd *abfd,
- struct bfd_link_info *link_info)
-{
- const struct elf_backend_data *bed = get_elf_backend_data (abfd);
- struct elf_segment_map *m;
- struct elf_segment_map *phdr_load_seg;
- Elf_Internal_Phdr *phdrs;
- Elf_Internal_Phdr *p;
- file_ptr off; /* Octets. */
- bfd_size_type maxpagesize;
- unsigned int alloc, actual;
- unsigned int i, j;
- struct elf_segment_map **sorted_seg_map;
- unsigned int opb = bfd_octets_per_byte (abfd, NULL);
-
- if (link_info == NULL
- && !_bfd_elf_map_sections_to_segments (abfd, link_info, NULL))
- return false;
-
- alloc = 0;
- for (m = elf_seg_map (abfd); m != NULL; m = m->next)
- m->idx = alloc++;
-
- if (alloc)
- {
- elf_elfheader (abfd)->e_phoff = bed->s->sizeof_ehdr;
- elf_elfheader (abfd)->e_phentsize = bed->s->sizeof_phdr;
- }
- else
- {
- /* PR binutils/12467. */
- elf_elfheader (abfd)->e_phoff = 0;
- elf_elfheader (abfd)->e_phentsize = 0;
- }
-
- elf_elfheader (abfd)->e_phnum = alloc;
-
- if (elf_program_header_size (abfd) == (bfd_size_type) -1)
- {
- actual = alloc;
- elf_program_header_size (abfd) = alloc * bed->s->sizeof_phdr;
- }
- else
- {
- actual = elf_program_header_size (abfd) / bed->s->sizeof_phdr;
- BFD_ASSERT (elf_program_header_size (abfd)
- == actual * bed->s->sizeof_phdr);
- BFD_ASSERT (actual >= alloc);
- }
-
- if (alloc == 0)
- {
- elf_next_file_pos (abfd) = bed->s->sizeof_ehdr;
- return true;
- }
-
- /* We're writing the size in elf_program_header_size (abfd),
- see assign_file_positions_except_relocs, so make sure we have
- that amount allocated, with trailing space cleared.
- The variable alloc contains the computed need, while
- elf_program_header_size (abfd) contains the size used for the
- layout.
- See ld/emultempl/elf-generic.em:gld${EMULATION_NAME}_map_segments
- where the layout is forced to according to a larger size in the
- last iterations for the testcase ld-elf/header. */
- phdrs = bfd_zalloc (abfd, (actual * sizeof (*phdrs)
- + alloc * sizeof (*sorted_seg_map)));
- sorted_seg_map = (struct elf_segment_map **) (phdrs + actual);
- elf_tdata (abfd)->phdr = phdrs;
- if (phdrs == NULL)
- return false;
-
- for (m = elf_seg_map (abfd), j = 0; m != NULL; m = m->next, j++)
- {
- sorted_seg_map[j] = m;
- /* If elf_segment_map is not from map_sections_to_segments, the
- sections may not be correctly ordered. NOTE: sorting should
- not be done to the PT_NOTE section of a corefile, which may
- contain several pseudo-sections artificially created by bfd.
- Sorting these pseudo-sections breaks things badly. */
- if (m->count > 1
- && !(elf_elfheader (abfd)->e_type == ET_CORE
- && m->p_type == PT_NOTE))
- {
- for (i = 0; i < m->count; i++)
- m->sections[i]->target_index = i;
- qsort (m->sections, (size_t) m->count, sizeof (asection *),
- elf_sort_sections);
- }
- }
- if (alloc > 1)
- qsort (sorted_seg_map, alloc, sizeof (*sorted_seg_map),
- elf_sort_segments);
-
- maxpagesize = 1;
- if ((abfd->flags & D_PAGED) != 0)
- {
- if (link_info != NULL)
- maxpagesize = link_info->maxpagesize;
- else
- maxpagesize = bed->maxpagesize;
- }
-
- /* Sections must map to file offsets past the ELF file header. */
- off = bed->s->sizeof_ehdr;
- /* And if one of the PT_LOAD headers doesn't include the program
- headers then we'll be mapping program headers in the usual
- position after the ELF file header. */
- phdr_load_seg = NULL;
- for (j = 0; j < alloc; j++)
- {
- m = sorted_seg_map[j];
- if (m->p_type != PT_LOAD)
- break;
- if (m->includes_phdrs)
- {
- phdr_load_seg = m;
- break;
- }
- }
- if (phdr_load_seg == NULL)
- off += actual * bed->s->sizeof_phdr;
-
- for (j = 0; j < alloc; j++)
- {
- asection **secpp;
- bfd_vma off_adjust; /* Octets. */
- bool no_contents;
- bfd_size_type p_align;
- bool p_align_p;
-
- /* An ELF segment (described by Elf_Internal_Phdr) may contain a
- number of sections with contents contributing to both p_filesz
- and p_memsz, followed by a number of sections with no contents
- that just contribute to p_memsz. In this loop, OFF tracks next
- available file offset for PT_LOAD and PT_NOTE segments. */
- m = sorted_seg_map[j];
- p = phdrs + m->idx;
- p->p_type = m->p_type;
- p->p_flags = m->p_flags;
- p_align = bed->p_align;
- p_align_p = false;
-
- if (m->count == 0)
- p->p_vaddr = m->p_vaddr_offset * opb;
- else
- p->p_vaddr = (m->sections[0]->vma + m->p_vaddr_offset) * opb;
-
- if (m->p_paddr_valid)
- p->p_paddr = m->p_paddr;
- else if (m->count == 0)
- p->p_paddr = 0;
- else
- p->p_paddr = (m->sections[0]->lma + m->p_vaddr_offset) * opb;
-
- if (p->p_type == PT_LOAD
- && (abfd->flags & D_PAGED) != 0)
- {
- /* p_align in demand paged PT_LOAD segments effectively stores
- the maximum page size. When copying an executable with
- objcopy, we set m->p_align from the input file. Use this
- value for maxpagesize rather than bed->maxpagesize, which
- may be different. Note that we use maxpagesize for PT_TLS
- segment alignment later in this function, so we are relying
- on at least one PT_LOAD segment appearing before a PT_TLS
- segment. */
- if (m->p_align_valid)
- maxpagesize = m->p_align;
- else if (p_align != 0
- && (link_info == NULL
- || !link_info->maxpagesize_is_set))
- /* Set p_align to the default p_align value while laying
- out segments aligning to the maximum page size or the
- largest section alignment. The run-time loader can
- align segments to the default p_align value or the
- maximum page size, depending on system page size. */
- p_align_p = true;
-
- p->p_align = maxpagesize;
- }
- else if (m->p_align_valid)
- p->p_align = m->p_align;
- else if (m->count == 0)
- p->p_align = 1 << bed->s->log_file_align;
-
- if (m == phdr_load_seg)
- {
- if (!m->includes_filehdr)
- p->p_offset = off;
- off += actual * bed->s->sizeof_phdr;
- }
-
- no_contents = false;
- off_adjust = 0;
- if (p->p_type == PT_LOAD
- && m->count > 0)
- {
- bfd_size_type align; /* Bytes. */
- unsigned int align_power = 0;
-
- if (m->p_align_valid)
- align = p->p_align;
- else
- {
- for (i = 0, secpp = m->sections; i < m->count; i++, secpp++)
- {
- unsigned int secalign;
-
- secalign = bfd_section_alignment (*secpp);
- if (secalign > align_power)
- align_power = secalign;
- }
- align = (bfd_size_type) 1 << align_power;
- if (align < maxpagesize)
- {
- /* If a section requires alignment higher than the
- default p_align value, don't set p_align to the
- default p_align value. */
- if (align > p_align)
- p_align_p = false;
- align = maxpagesize;
- }
- else
- {
- /* If a section requires alignment higher than the
- maximum page size, set p_align to the section
- alignment. */
- p_align_p = true;
- p_align = align;
- }
- }
-
- for (i = 0; i < m->count; i++)
- if ((m->sections[i]->flags & (SEC_LOAD | SEC_HAS_CONTENTS)) == 0)
- /* If we aren't making room for this section, then
- it must be SHT_NOBITS regardless of what we've
- set via struct bfd_elf_special_section. */
- elf_section_type (m->sections[i]) = SHT_NOBITS;
-
- /* Find out whether this segment contains any loadable
- sections. */
- no_contents = true;
- for (i = 0; i < m->count; i++)
- if (elf_section_type (m->sections[i]) != SHT_NOBITS)
- {
- no_contents = false;
- break;
- }
-
- off_adjust = vma_page_aligned_bias (p->p_vaddr, off, align * opb);
-
- /* Broken hardware and/or kernel require that files do not
- map the same page with different permissions on some hppa
- processors. */
- if (j != 0
- && (abfd->flags & D_PAGED) != 0
- && bed->no_page_alias
- && (off & (maxpagesize - 1)) != 0
- && ((off & -maxpagesize)
- == ((off + off_adjust) & -maxpagesize)))
- off_adjust += maxpagesize;
- off += off_adjust;
- if (no_contents)
- {
- /* We shouldn't need to align the segment on disk since
- the segment doesn't need file space, but the gABI
- arguably requires the alignment and glibc ld.so
- checks it. So to comply with the alignment
- requirement but not waste file space, we adjust
- p_offset for just this segment. (OFF_ADJUST is
- subtracted from OFF later.) This may put p_offset
- past the end of file, but that shouldn't matter. */
- }
- else
- off_adjust = 0;
- }
- /* Make sure the .dynamic section is the first section in the
- PT_DYNAMIC segment. */
- else if (p->p_type == PT_DYNAMIC
- && m->count > 1
- && strcmp (m->sections[0]->name, ".dynamic") != 0)
- {
- _bfd_error_handler
- (_("%pB: The first section in the PT_DYNAMIC segment"
- " is not the .dynamic section"),
- abfd);
- bfd_set_error (bfd_error_bad_value);
- return false;
- }
- /* Set the note section type to SHT_NOTE. */
- else if (p->p_type == PT_NOTE)
- for (i = 0; i < m->count; i++)
- elf_section_type (m->sections[i]) = SHT_NOTE;
-
- if (m->includes_filehdr)
- {
- if (!m->p_flags_valid)
- p->p_flags |= PF_R;
- p->p_filesz = bed->s->sizeof_ehdr;
- p->p_memsz = bed->s->sizeof_ehdr;
- if (p->p_type == PT_LOAD)
- {
- if (m->count > 0)
- {
- if (p->p_vaddr < (bfd_vma) off
- || (!m->p_paddr_valid
- && p->p_paddr < (bfd_vma) off))
- {
- _bfd_error_handler
- (_("%pB: not enough room for program headers,"
- " try linking with -N"),
- abfd);
- bfd_set_error (bfd_error_bad_value);
- return false;
- }
- p->p_vaddr -= off;
- if (!m->p_paddr_valid)
- p->p_paddr -= off;
- }
- }
- else if (sorted_seg_map[0]->includes_filehdr)
- {
- Elf_Internal_Phdr *filehdr = phdrs + sorted_seg_map[0]->idx;
- p->p_vaddr = filehdr->p_vaddr;
- if (!m->p_paddr_valid)
- p->p_paddr = filehdr->p_paddr;
- }
- }
-
- if (m->includes_phdrs)
- {
- if (!m->p_flags_valid)
- p->p_flags |= PF_R;
- p->p_filesz += actual * bed->s->sizeof_phdr;
- p->p_memsz += actual * bed->s->sizeof_phdr;
- if (!m->includes_filehdr)
- {
- if (p->p_type == PT_LOAD)
- {
- elf_elfheader (abfd)->e_phoff = p->p_offset;
- if (m->count > 0)
- {
- p->p_vaddr -= off - p->p_offset;
- if (!m->p_paddr_valid)
- p->p_paddr -= off - p->p_offset;
- }
- }
- else if (phdr_load_seg != NULL)
- {
- Elf_Internal_Phdr *phdr = phdrs + phdr_load_seg->idx;
- bfd_vma phdr_off = 0; /* Octets. */
- if (phdr_load_seg->includes_filehdr)
- phdr_off = bed->s->sizeof_ehdr;
- p->p_vaddr = phdr->p_vaddr + phdr_off;
- if (!m->p_paddr_valid)
- p->p_paddr = phdr->p_paddr + phdr_off;
- p->p_offset = phdr->p_offset + phdr_off;
- }
- else
- p->p_offset = bed->s->sizeof_ehdr;
- }
- }
-
- if (p->p_type == PT_LOAD
- || (p->p_type == PT_NOTE && bfd_get_format (abfd) == bfd_core))
- {
- if (!m->includes_filehdr && !m->includes_phdrs)
- {
- p->p_offset = off;
- if (no_contents)
- {
- /* Put meaningless p_offset for PT_LOAD segments
- without file contents somewhere within the first
- page, in an attempt to not point past EOF. */
- bfd_size_type align = maxpagesize;
- if (align < p->p_align)
- align = p->p_align;
- if (align < 1)
- align = 1;
- p->p_offset = off % align;
- }
- }
- else
- {
- file_ptr adjust; /* Octets. */
-
- adjust = off - (p->p_offset + p->p_filesz);
- if (!no_contents)
- p->p_filesz += adjust;
- p->p_memsz += adjust;
- }
- }
-
- /* Set up p_filesz, p_memsz, p_align and p_flags from the section
- maps. Set filepos for sections in PT_LOAD segments, and in
- core files, for sections in PT_NOTE segments.
- assign_file_positions_for_non_load_sections will set filepos
- for other sections and update p_filesz for other segments. */
- for (i = 0, secpp = m->sections; i < m->count; i++, secpp++)
- {
- asection *sec;
- bfd_size_type align;
- Elf_Internal_Shdr *this_hdr;
-
- sec = *secpp;
- this_hdr = &elf_section_data (sec)->this_hdr;
- align = (bfd_size_type) 1 << bfd_section_alignment (sec);
-
- if ((p->p_type == PT_LOAD
- || p->p_type == PT_TLS)
- && (this_hdr->sh_type != SHT_NOBITS
- || ((this_hdr->sh_flags & SHF_ALLOC) != 0
- && ((this_hdr->sh_flags & SHF_TLS) == 0
- || p->p_type == PT_TLS))))
- {
- bfd_vma p_start = p->p_paddr; /* Octets. */
- bfd_vma p_end = p_start + p->p_memsz; /* Octets. */
- bfd_vma s_start = sec->lma * opb; /* Octets. */
- bfd_vma adjust = s_start - p_end; /* Octets. */
-
- if (adjust != 0
- && (s_start < p_end
- || p_end < p_start))
- {
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB: section %pA lma %#" PRIx64
- " adjusted to %#" PRIx64),
- abfd, sec, (uint64_t) s_start / opb,
- (uint64_t) p_end / opb);
- adjust = 0;
- sec->lma = p_end / opb;
- }
- p->p_memsz += adjust;
-
- if (p->p_type == PT_LOAD)
- {
- if (this_hdr->sh_type != SHT_NOBITS)
- {
- off_adjust = 0;
- if (p->p_filesz + adjust < p->p_memsz)
- {
- /* We have a PROGBITS section following NOBITS ones.
- Allocate file space for the NOBITS section(s).
- We don't need to write out the zeros, posix
- fseek past the end of data already written
- followed by a write at that location is
- guaranteed to result in zeros being read
- from the gap. */
- adjust = p->p_memsz - p->p_filesz;
- }
- }
- /* We only adjust sh_offset in SHT_NOBITS sections
- as would seem proper for their address when the
- section is first in the segment. sh_offset
- doesn't really have any significance for
- SHT_NOBITS anyway, apart from a notional position
- relative to other sections. Historically we
- didn't bother with adjusting sh_offset and some
- programs depend on it not being adjusted. See
- pr12921 and pr25662. */
- if (this_hdr->sh_type != SHT_NOBITS || i == 0)
- {
- off += adjust;
- if (this_hdr->sh_type == SHT_NOBITS)
- off_adjust += adjust;
- }
- }
- if (this_hdr->sh_type != SHT_NOBITS)
- p->p_filesz += adjust;
- }
-
- if (p->p_type == PT_NOTE && bfd_get_format (abfd) == bfd_core)
- {
- /* The section at i == 0 is the one that actually contains
- everything. */
- if (i == 0)
- {
- this_hdr->sh_offset = sec->filepos = off;
- off += this_hdr->sh_size;
- p->p_filesz = this_hdr->sh_size;
- p->p_memsz = 0;
- p->p_align = 1;
- }
- else
- {
- /* The rest are fake sections that shouldn't be written. */
- sec->filepos = 0;
- sec->size = 0;
- sec->flags = 0;
- continue;
- }
- }
- else
- {
- if (p->p_type == PT_LOAD)
- {
- this_hdr->sh_offset = sec->filepos = off;
- if (this_hdr->sh_type != SHT_NOBITS)
- off += this_hdr->sh_size;
- }
- else if (this_hdr->sh_type == SHT_NOBITS
- && (this_hdr->sh_flags & SHF_TLS) != 0
- && this_hdr->sh_offset == 0)
- {
- /* This is a .tbss section that didn't get a PT_LOAD.
- (See _bfd_elf_map_sections_to_segments "Create a
- final PT_LOAD".) Set sh_offset to the value it
- would have if we had created a zero p_filesz and
- p_memsz PT_LOAD header for the section. This
- also makes the PT_TLS header have the same
- p_offset value. */
- bfd_vma adjust = vma_page_aligned_bias (this_hdr->sh_addr,
- off, align);
- this_hdr->sh_offset = sec->filepos = off + adjust;
- }
-
- if (this_hdr->sh_type != SHT_NOBITS)
- {
- p->p_filesz += this_hdr->sh_size;
- /* A load section without SHF_ALLOC is something like
- a note section in a PT_NOTE segment. These take
- file space but are not loaded into memory. */
- if ((this_hdr->sh_flags & SHF_ALLOC) != 0)
- p->p_memsz += this_hdr->sh_size;
- }
- else if ((this_hdr->sh_flags & SHF_ALLOC) != 0)
- {
- if (p->p_type == PT_TLS)
- p->p_memsz += this_hdr->sh_size;
-
- /* .tbss is special. It doesn't contribute to p_memsz of
- normal segments. */
- else if ((this_hdr->sh_flags & SHF_TLS) == 0)
- p->p_memsz += this_hdr->sh_size;
- }
-
- if (align > p->p_align
- && !m->p_align_valid
- && (p->p_type != PT_LOAD
- || (abfd->flags & D_PAGED) == 0))
- p->p_align = align;
- }
-
- if (!m->p_flags_valid)
- {
- p->p_flags |= PF_R;
- if ((this_hdr->sh_flags & SHF_EXECINSTR) != 0)
- p->p_flags |= PF_X;
- if ((this_hdr->sh_flags & SHF_WRITE) != 0)
- p->p_flags |= PF_W;
- }
- }
-
- off -= off_adjust;
-
- /* PR ld/20815 - Check that the program header segment, if
- present, will be loaded into memory. */
- if (p->p_type == PT_PHDR
- && phdr_load_seg == NULL
- && !(bed->elf_backend_allow_non_load_phdr != NULL
- && bed->elf_backend_allow_non_load_phdr (abfd, phdrs, alloc)))
- {
- /* The fix for this error is usually to edit the linker script being
- used and set up the program headers manually. Either that or
- leave room for the headers at the start of the SECTIONS. */
- _bfd_error_handler (_("%pB: error: PHDR segment not covered"
- " by LOAD segment"),
- abfd);
- if (link_info == NULL)
- return false;
- /* Arrange for the linker to exit with an error, deleting
- the output file unless --noinhibit-exec is given. */
- link_info->callbacks->info ("%X");
- }
-
- /* Check that all sections are in a PT_LOAD segment.
- Don't check funky gdb generated core files. */
- if (p->p_type == PT_LOAD && bfd_get_format (abfd) != bfd_core)
- {
- bool check_vma = true;
-
- for (i = 1; i < m->count; i++)
- if (m->sections[i]->vma == m->sections[i - 1]->vma
- && ELF_SECTION_SIZE (&(elf_section_data (m->sections[i])
- ->this_hdr), p) != 0
- && ELF_SECTION_SIZE (&(elf_section_data (m->sections[i - 1])
- ->this_hdr), p) != 0)
- {
- /* Looks like we have overlays packed into the segment. */
- check_vma = false;
- break;
- }
-
- for (i = 0; i < m->count; i++)
- {
- Elf_Internal_Shdr *this_hdr;
- asection *sec;
-
- sec = m->sections[i];
- this_hdr = &(elf_section_data(sec)->this_hdr);
- if (!ELF_SECTION_IN_SEGMENT_1 (this_hdr, p, check_vma, 0)
- && !ELF_TBSS_SPECIAL (this_hdr, p))
- {
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB: section `%pA' can't be allocated in segment %d"),
- abfd, sec, j);
- print_segment_map (m);
- }
- }
-
- if (p_align_p)
- p->p_align = p_align;
- }
- }
-
- elf_next_file_pos (abfd) = off;
-
- if (link_info != NULL
- && phdr_load_seg != NULL
- && phdr_load_seg->includes_filehdr)
- {
- /* There is a segment that contains both the file headers and the
- program headers, so provide a symbol __ehdr_start pointing there.
- A program can use this to examine itself robustly. */
-
- struct elf_link_hash_entry *hash
- = elf_link_hash_lookup (elf_hash_table (link_info), "__ehdr_start",
- false, false, true);
- /* If the symbol was referenced and not defined, define it. */
- if (hash != NULL
- && (hash->root.type == bfd_link_hash_new
- || hash->root.type == bfd_link_hash_undefined
- || hash->root.type == bfd_link_hash_undefweak
- || hash->root.type == bfd_link_hash_common))
- {
- asection *s = NULL;
- bfd_vma filehdr_vaddr = phdrs[phdr_load_seg->idx].p_vaddr / opb;
-
- if (phdr_load_seg->count != 0)
- /* The segment contains sections, so use the first one. */
- s = phdr_load_seg->sections[0];
- else
- /* Use the first (i.e. lowest-addressed) section in any segment. */
- for (m = elf_seg_map (abfd); m != NULL; m = m->next)
- if (m->p_type == PT_LOAD && m->count != 0)
- {
- s = m->sections[0];
- break;
- }
-
- if (s != NULL)
- {
- hash->root.u.def.value = filehdr_vaddr - s->vma;
- hash->root.u.def.section = s;
- }
- else
- {
- hash->root.u.def.value = filehdr_vaddr;
- hash->root.u.def.section = bfd_abs_section_ptr;
- }
-
- hash->root.type = bfd_link_hash_defined;
- hash->def_regular = 1;
- hash->non_elf = 0;
- }
- }
-
- return true;
-}
-
-/* Determine if a bfd is a debuginfo file. Unfortunately there
- is no defined method for detecting such files, so we have to
- use heuristics instead. */
-
-bool
-is_debuginfo_file (bfd *abfd)
-{
- if (abfd == NULL || bfd_get_flavour (abfd) != bfd_target_elf_flavour)
- return false;
-
- Elf_Internal_Shdr **start_headers = elf_elfsections (abfd);
- Elf_Internal_Shdr **end_headers = start_headers + elf_numsections (abfd);
- Elf_Internal_Shdr **headerp;
-
- for (headerp = start_headers; headerp < end_headers; headerp ++)
- {
- Elf_Internal_Shdr *header = * headerp;
-
- /* Debuginfo files do not have any allocated SHT_PROGBITS sections.
- The only allocated sections are SHT_NOBITS or SHT_NOTES. */
- if ((header->sh_flags & SHF_ALLOC) == SHF_ALLOC
- && header->sh_type != SHT_NOBITS
- && header->sh_type != SHT_NOTE)
- return false;
- }
-
- return true;
-}
-
-/* Assign file positions for other sections, except for compressed debug
- and sections assigned in _bfd_elf_assign_file_positions_for_non_load. */
-
-static bool
-assign_file_positions_for_non_load_sections (bfd *abfd,
- struct bfd_link_info *link_info)
-{
- const struct elf_backend_data *bed = get_elf_backend_data (abfd);
- Elf_Internal_Shdr **i_shdrpp;
- Elf_Internal_Shdr **hdrpp, **end_hdrpp;
- Elf_Internal_Phdr *phdrs;
- Elf_Internal_Phdr *p;
- struct elf_segment_map *m;
- file_ptr off;
- unsigned int opb = bfd_octets_per_byte (abfd, NULL);
- bfd_vma maxpagesize;
-
- if (link_info != NULL)
- maxpagesize = link_info->maxpagesize;
- else
- maxpagesize = bed->maxpagesize;
- i_shdrpp = elf_elfsections (abfd);
- end_hdrpp = i_shdrpp + elf_numsections (abfd);
- off = elf_next_file_pos (abfd);
- for (hdrpp = i_shdrpp + 1; hdrpp < end_hdrpp; hdrpp++)
- {
- Elf_Internal_Shdr *hdr;
- bfd_vma align;
-
- hdr = *hdrpp;
- if (hdr->bfd_section != NULL
- && (hdr->bfd_section->filepos != 0
- || (hdr->sh_type == SHT_NOBITS
- && hdr->contents == NULL)))
- BFD_ASSERT (hdr->sh_offset == hdr->bfd_section->filepos);
- else if ((hdr->sh_flags & SHF_ALLOC) != 0)
- {
- if (hdr->sh_size != 0
- /* PR 24717 - debuginfo files are known to be not strictly
- compliant with the ELF standard. In particular they often
- have .note.gnu.property sections that are outside of any
- loadable segment. This is not a problem for such files,
- so do not warn about them. */
- && ! is_debuginfo_file (abfd))
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB: warning: allocated section `%s' not in segment"),
- abfd,
- (hdr->bfd_section == NULL
- ? "*unknown*"
- : hdr->bfd_section->name));
- /* We don't need to page align empty sections. */
- if ((abfd->flags & D_PAGED) != 0 && hdr->sh_size != 0)
- align = maxpagesize;
- else
- align = hdr->sh_addralign & -hdr->sh_addralign;
- off += vma_page_aligned_bias (hdr->sh_addr, off, align);
- off = _bfd_elf_assign_file_position_for_section (hdr, off,
- false);
- }
- else if (((hdr->sh_type == SHT_REL || hdr->sh_type == SHT_RELA)
- && hdr->bfd_section == NULL)
- /* We don't know the offset of these sections yet:
- their size has not been decided. */
- || (abfd->is_linker_output
- && hdr->bfd_section != NULL
- && (hdr->sh_name == -1u
- || bfd_section_is_ctf (hdr->bfd_section)))
- || hdr == i_shdrpp[elf_onesymtab (abfd)]
- || (elf_symtab_shndx_list (abfd) != NULL
- && hdr == i_shdrpp[elf_symtab_shndx_list (abfd)->ndx])
- || hdr == i_shdrpp[elf_strtab_sec (abfd)]
- || hdr == i_shdrpp[elf_shstrtab_sec (abfd)])
- hdr->sh_offset = -1;
- else
- off = _bfd_elf_assign_file_position_for_section (hdr, off, true);
- }
- elf_next_file_pos (abfd) = off;
-
- /* Now that we have set the section file positions, we can set up
- the file positions for the non PT_LOAD segments. */
- phdrs = elf_tdata (abfd)->phdr;
- for (m = elf_seg_map (abfd), p = phdrs; m != NULL; m = m->next, p++)
- {
- if (p->p_type == PT_GNU_RELRO)
- {
- bfd_vma start, end; /* Bytes. */
- bool ok;
-
- if (link_info != NULL)
- {
- /* During linking the range of the RELRO segment is passed
- in link_info. Note that there may be padding between
- relro_start and the first RELRO section. */
- start = link_info->relro_start;
- end = link_info->relro_end;
- }
- else if (m->count != 0)
- {
- if (!m->p_size_valid)
- abort ();
- start = m->sections[0]->vma;
- end = start + m->p_size / opb;
- }
- else
- {
- start = 0;
- end = 0;
- }
-
- ok = false;
- if (start < end)
- {
- struct elf_segment_map *lm;
- const Elf_Internal_Phdr *lp;
- unsigned int i;
-
- /* Find a LOAD segment containing a section in the RELRO
- segment. */
- for (lm = elf_seg_map (abfd), lp = phdrs;
- lm != NULL;
- lm = lm->next, lp++)
- {
- if (lp->p_type == PT_LOAD
- && lm->count != 0
- && (lm->sections[lm->count - 1]->vma
- + (!IS_TBSS (lm->sections[lm->count - 1])
- ? lm->sections[lm->count - 1]->size / opb
- : 0)) > start
- && lm->sections[0]->vma < end)
- break;
- }
-
- if (lm != NULL)
- {
- /* Find the section starting the RELRO segment. */
- for (i = 0; i < lm->count; i++)
- {
- asection *s = lm->sections[i];
- if (s->vma >= start
- && s->vma < end
- && s->size != 0)
- break;
- }
-
- if (i < lm->count)
- {
- p->p_vaddr = lm->sections[i]->vma * opb;
- p->p_paddr = lm->sections[i]->lma * opb;
- p->p_offset = lm->sections[i]->filepos;
- p->p_memsz = end * opb - p->p_vaddr;
- p->p_filesz = p->p_memsz;
-
- /* The RELRO segment typically ends a few bytes
- into .got.plt but other layouts are possible.
- In cases where the end does not match any
- loaded section (for instance is in file
- padding), trim p_filesz back to correspond to
- the end of loaded section contents. */
- if (p->p_filesz > lp->p_vaddr + lp->p_filesz - p->p_vaddr)
- p->p_filesz = lp->p_vaddr + lp->p_filesz - p->p_vaddr;
-
- /* Preserve the alignment and flags if they are
- valid. The gold linker generates RW/4 for
- the PT_GNU_RELRO section. It is better for
- objcopy/strip to honor these attributes
- otherwise gdb will choke when using separate
- debug files. */
- if (!m->p_align_valid)
- p->p_align = 1;
- if (!m->p_flags_valid)
- p->p_flags = PF_R;
- ok = true;
- }
- }
- }
-
- if (!ok)
- {
- if (link_info != NULL)
- _bfd_error_handler
- (_("%pB: warning: unable to allocate any sections"
- " to PT_GNU_RELRO segment"),
- abfd);
- memset (p, 0, sizeof *p);
- }
- }
- else if (p->p_type == PT_GNU_STACK)
- {
- if (m->p_size_valid)
- p->p_memsz = m->p_size;
- }
- else if (m->count != 0)
- {
- unsigned int i;
-
- if (p->p_type != PT_LOAD
- && (p->p_type != PT_NOTE
- || bfd_get_format (abfd) != bfd_core))
- {
- /* A user specified segment layout may include a PHDR
- segment that overlaps with a LOAD segment... */
- if (p->p_type == PT_PHDR)
- {
- m->count = 0;
- continue;
- }
-
- if (m->includes_filehdr || m->includes_phdrs)
- {
- /* PR 17512: file: 2195325e. */
- _bfd_error_handler
- (_("%pB: error: non-load segment %d includes file header "
- "and/or program header"),
- abfd, (int) (p - phdrs));
- return false;
- }
-
- p->p_filesz = 0;
- p->p_offset = m->sections[0]->filepos;
- for (i = m->count; i-- != 0;)
- {
- asection *sect = m->sections[i];
- Elf_Internal_Shdr *hdr = &elf_section_data (sect)->this_hdr;
- if (hdr->sh_type != SHT_NOBITS)
- {
- p->p_filesz = sect->filepos - p->p_offset + hdr->sh_size;
- /* NB: p_memsz of the loadable PT_NOTE segment
- should be the same as p_filesz. */
- if (p->p_type == PT_NOTE
- && (hdr->sh_flags & SHF_ALLOC) != 0)
- p->p_memsz = p->p_filesz;
- break;
- }
- }
- }
- }
- }
-
- return true;
-}
-
-static elf_section_list *
-find_section_in_list (unsigned int i, elf_section_list * list)
-{
- for (;list != NULL; list = list->next)
- if (list->ndx == i)
- break;
- return list;
-}
-
-/* Work out the file positions of all the sections. This is called by
- _bfd_elf_compute_section_file_positions. All the section sizes and
- VMAs must be known before this is called.
-
- Reloc sections come in two flavours: Those processed specially as
- "side-channel" data attached to a section to which they apply, and
- those that bfd doesn't process as relocations. The latter sort are
- stored in a normal bfd section by bfd_section_from_shdr. We don't
- consider the former sort here, unless they form part of the loadable
- image. Reloc sections not assigned here (and compressed debugging
- sections and CTF sections which nothing else in the file can rely
- upon) will be handled later by assign_file_positions_for_relocs.
-
- We also don't set the positions of the .symtab and .strtab here. */
-
-static bool
-assign_file_positions_except_relocs (bfd *abfd,
- struct bfd_link_info *link_info)
-{
- struct elf_obj_tdata *tdata = elf_tdata (abfd);
- Elf_Internal_Ehdr *i_ehdrp = elf_elfheader (abfd);
- const struct elf_backend_data *bed = get_elf_backend_data (abfd);
- unsigned int alloc;
-
- if ((abfd->flags & (EXEC_P | DYNAMIC)) == 0
- && bfd_get_format (abfd) != bfd_core)
- {
- Elf_Internal_Shdr ** const i_shdrpp = elf_elfsections (abfd);
- unsigned int num_sec = elf_numsections (abfd);
- Elf_Internal_Shdr **hdrpp;
- unsigned int i;
- file_ptr off;
-
- /* Start after the ELF header. */
- off = i_ehdrp->e_ehsize;
-
- /* We are not creating an executable, which means that we are
- not creating a program header, and that the actual order of
- the sections in the file is unimportant. */
- for (i = 1, hdrpp = i_shdrpp + 1; i < num_sec; i++, hdrpp++)
- {
- Elf_Internal_Shdr *hdr;
-
- hdr = *hdrpp;
- if (((hdr->sh_type == SHT_REL || hdr->sh_type == SHT_RELA)
- && hdr->bfd_section == NULL)
- /* Do not assign offsets for these sections yet: we don't know
- their sizes. */
- || (abfd->is_linker_output
- && hdr->bfd_section != NULL
- && (hdr->sh_name == -1u
- || bfd_section_is_ctf (hdr->bfd_section)))
- || i == elf_onesymtab (abfd)
- || (elf_symtab_shndx_list (abfd) != NULL
- && hdr == i_shdrpp[elf_symtab_shndx_list (abfd)->ndx])
- || i == elf_strtab_sec (abfd)
- || i == elf_shstrtab_sec (abfd))
- {
- hdr->sh_offset = -1;
- }
- else
- off = _bfd_elf_assign_file_position_for_section (hdr, off, true);
- }
-
- elf_next_file_pos (abfd) = off;
- elf_program_header_size (abfd) = 0;
- }
- else
- {
- /* Assign file positions for the loaded sections based on the
- assignment of sections to segments. */
- if (!assign_file_positions_for_load_sections (abfd, link_info))
- return false;
-
- /* And for non-load sections. */
- if (!assign_file_positions_for_non_load_sections (abfd, link_info))
- return false;
- }
-
- if (!(*bed->elf_backend_modify_headers) (abfd, link_info))
- return false;
-
- /* Write out the program headers. */
- alloc = i_ehdrp->e_phnum;
- if (alloc != 0)
- {
- if (link_info != NULL && ! link_info->no_warn_rwx_segments)
- {
- bool warned_tls = false;
- bool warned_rwx = false;
-
- /* Memory resident segments with non-zero size and RWX
- permissions are a security risk, so we generate a warning
- here if we are creating any. */
- unsigned int i;
-
- for (i = 0; i < alloc; i++)
- {
- const Elf_Internal_Phdr * phdr = tdata->phdr + i;
-
- if (phdr->p_memsz == 0)
- continue;
-
- if (! warned_tls
- && phdr->p_type == PT_TLS
- && (phdr->p_flags & PF_X))
- {
- if (link_info->warn_is_error_for_rwx_segments)
- {
- _bfd_error_handler (_("\
-error: %pB has a TLS segment with execute permission"),
- abfd);
- return false;
- }
-
- _bfd_error_handler (_("\
-warning: %pB has a TLS segment with execute permission"),
- abfd);
- if (warned_rwx)
- break;
-
- warned_tls = true;
- }
- else if (! warned_rwx
- && phdr->p_type == PT_LOAD
- && ((phdr->p_flags & (PF_R | PF_W | PF_X))
- == (PF_R | PF_W | PF_X)))
- {
- if (link_info->warn_is_error_for_rwx_segments)
- {
- _bfd_error_handler (_("\
-error: %pB has a LOAD segment with RWX permissions"),
- abfd);
- return false;
- }
-
- _bfd_error_handler (_("\
-warning: %pB has a LOAD segment with RWX permissions"),
- abfd);
- if (warned_tls)
- break;
-
- warned_rwx = true;
- }
- }
- }
-
- if (bfd_seek (abfd, i_ehdrp->e_phoff, SEEK_SET) != 0
- || bed->s->write_out_phdrs (abfd, tdata->phdr, alloc) != 0)
- return false;
- }
-
- return true;
-}
-
-bool
-_bfd_elf_init_file_header (bfd *abfd,
- struct bfd_link_info *info ATTRIBUTE_UNUSED)
-{
- Elf_Internal_Ehdr *i_ehdrp; /* Elf file header, internal form. */
- struct elf_strtab_hash *shstrtab;
- const struct elf_backend_data *bed = get_elf_backend_data (abfd);
-
- i_ehdrp = elf_elfheader (abfd);
-
- shstrtab = _bfd_elf_strtab_init ();
- if (shstrtab == NULL)
- return false;
-
- elf_shstrtab (abfd) = shstrtab;
-
- i_ehdrp->e_ident[EI_MAG0] = ELFMAG0;
- i_ehdrp->e_ident[EI_MAG1] = ELFMAG1;
- i_ehdrp->e_ident[EI_MAG2] = ELFMAG2;
- i_ehdrp->e_ident[EI_MAG3] = ELFMAG3;
-
- i_ehdrp->e_ident[EI_CLASS] = bed->s->elfclass;
- i_ehdrp->e_ident[EI_DATA] =
- bfd_big_endian (abfd) ? ELFDATA2MSB : ELFDATA2LSB;
- i_ehdrp->e_ident[EI_VERSION] = bed->s->ev_current;
-
- if ((abfd->flags & DYNAMIC) != 0)
- i_ehdrp->e_type = ET_DYN;
- else if ((abfd->flags & EXEC_P) != 0)
- i_ehdrp->e_type = ET_EXEC;
- else if (bfd_get_format (abfd) == bfd_core)
- i_ehdrp->e_type = ET_CORE;
- else
- i_ehdrp->e_type = ET_REL;
-
- switch (bfd_get_arch (abfd))
- {
- case bfd_arch_unknown:
- i_ehdrp->e_machine = EM_NONE;
- break;
-
- /* There used to be a long list of cases here, each one setting
- e_machine to the same EM_* macro #defined as ELF_MACHINE_CODE
- in the corresponding bfd definition. To avoid duplication,
- the switch was removed. Machines that need special handling
- can generally do it in elf_backend_final_write_processing(),
- unless they need the information earlier than the final write.
- Such need can generally be supplied by replacing the tests for
- e_machine with the conditions used to determine it. */
- default:
- i_ehdrp->e_machine = bed->elf_machine_code;
- }
-
- i_ehdrp->e_version = bed->s->ev_current;
- i_ehdrp->e_ehsize = bed->s->sizeof_ehdr;
-
- /* No program header, for now. */
- i_ehdrp->e_phoff = 0;
- i_ehdrp->e_phentsize = 0;
- i_ehdrp->e_phnum = 0;
-
- /* Each bfd section is section header entry. */
- i_ehdrp->e_entry = bfd_get_start_address (abfd);
- i_ehdrp->e_shentsize = bed->s->sizeof_shdr;
-
- elf_tdata (abfd)->symtab_hdr.sh_name =
- (unsigned int) _bfd_elf_strtab_add (shstrtab, ".symtab", false);
- elf_tdata (abfd)->strtab_hdr.sh_name =
- (unsigned int) _bfd_elf_strtab_add (shstrtab, ".strtab", false);
- elf_tdata (abfd)->shstrtab_hdr.sh_name =
- (unsigned int) _bfd_elf_strtab_add (shstrtab, ".shstrtab", false);
- if (elf_tdata (abfd)->symtab_hdr.sh_name == (unsigned int) -1
- || elf_tdata (abfd)->strtab_hdr.sh_name == (unsigned int) -1
- || elf_tdata (abfd)->shstrtab_hdr.sh_name == (unsigned int) -1)
- return false;
-
- return true;
-}
-
-/* Set e_type in ELF header to ET_EXEC for -pie -Ttext-segment=.
-
- FIXME: We used to have code here to sort the PT_LOAD segments into
- ascending order, as per the ELF spec. But this breaks some programs,
- including the Linux kernel. But really either the spec should be
- changed or the programs updated. */
-
-bool
-_bfd_elf_modify_headers (bfd *obfd, struct bfd_link_info *link_info)
-{
- if (link_info != NULL && bfd_link_pie (link_info))
- {
- Elf_Internal_Ehdr *i_ehdrp = elf_elfheader (obfd);
- unsigned int num_segments = i_ehdrp->e_phnum;
- struct elf_obj_tdata *tdata = elf_tdata (obfd);
- Elf_Internal_Phdr *segment = tdata->phdr;
- Elf_Internal_Phdr *end_segment = &segment[num_segments];
-
- /* Find the lowest p_vaddr in PT_LOAD segments. */
- bfd_vma p_vaddr = (bfd_vma) -1;
- for (; segment < end_segment; segment++)
- if (segment->p_type == PT_LOAD && p_vaddr > segment->p_vaddr)
- p_vaddr = segment->p_vaddr;
-
- /* Set e_type to ET_EXEC if the lowest p_vaddr in PT_LOAD
- segments is non-zero. */
- if (p_vaddr)
- i_ehdrp->e_type = ET_EXEC;
- }
- return true;
-}
-
-/* Assign file positions for all the reloc sections which are not part
- of the loadable file image, and the file position of section headers. */
-
-static bool
-_bfd_elf_assign_file_positions_for_non_load (bfd *abfd)
-{
- file_ptr off;
- Elf_Internal_Shdr **shdrpp, **end_shdrpp;
- Elf_Internal_Shdr *shdrp;
- Elf_Internal_Ehdr *i_ehdrp;
- const struct elf_backend_data *bed;
-
- /* Skip non-load sections without section header. */
- if ((abfd->flags & BFD_NO_SECTION_HEADER) != 0)
- return true;
-
- off = elf_next_file_pos (abfd);
-
- shdrpp = elf_elfsections (abfd);
- end_shdrpp = shdrpp + elf_numsections (abfd);
- for (shdrpp++; shdrpp < end_shdrpp; shdrpp++)
- {
- shdrp = *shdrpp;
- if (shdrp->sh_offset == -1)
- {
- asection *sec = shdrp->bfd_section;
- if (sec == NULL
- || shdrp->sh_type == SHT_REL
- || shdrp->sh_type == SHT_RELA)
- ;
- else if (bfd_section_is_ctf (sec))
- {
- /* Update section size and contents. */
- shdrp->sh_size = sec->size;
- shdrp->contents = sec->contents;
- }
- else if (shdrp->sh_name == -1u)
- {
- const char *name = sec->name;
- struct bfd_elf_section_data *d;
-
- /* Compress DWARF debug sections. */
- if (!bfd_compress_section (abfd, sec, shdrp->contents))
- return false;
-
- if (sec->compress_status == COMPRESS_SECTION_DONE
- && (abfd->flags & BFD_COMPRESS_GABI) == 0
- && name[1] == 'd')
- {
- /* If section is compressed with zlib-gnu, convert
- section name from .debug_* to .zdebug_*. */
- char *new_name = bfd_debug_name_to_zdebug (abfd, name);
- if (new_name == NULL)
- return false;
- name = new_name;
- }
- /* Add section name to section name section. */
- shdrp->sh_name
- = (unsigned int) _bfd_elf_strtab_add (elf_shstrtab (abfd),
- name, false);
- d = elf_section_data (sec);
-
- /* Add reloc section name to section name section. */
- if (d->rel.hdr
- && !_bfd_elf_set_reloc_sh_name (abfd, d->rel.hdr,
- name, false))
- return false;
- if (d->rela.hdr
- && !_bfd_elf_set_reloc_sh_name (abfd, d->rela.hdr,
- name, true))
- return false;
-
- /* Update section size and contents. */
- shdrp->sh_size = sec->size;
- shdrp->contents = sec->contents;
- sec->contents = NULL;
- }
-
- off = _bfd_elf_assign_file_position_for_section (shdrp, off, true);
- }
- }
-
- /* Place section name section after DWARF debug sections have been
- compressed. */
- _bfd_elf_strtab_finalize (elf_shstrtab (abfd));
- shdrp = &elf_tdata (abfd)->shstrtab_hdr;
- shdrp->sh_size = _bfd_elf_strtab_size (elf_shstrtab (abfd));
- off = _bfd_elf_assign_file_position_for_section (shdrp, off, true);
-
- /* Place the section headers. */
- i_ehdrp = elf_elfheader (abfd);
- bed = get_elf_backend_data (abfd);
- off = align_file_position (off, 1 << bed->s->log_file_align);
- i_ehdrp->e_shoff = off;
- off += i_ehdrp->e_shnum * i_ehdrp->e_shentsize;
- elf_next_file_pos (abfd) = off;
-
- return true;
-}
-
-bool
-_bfd_elf_write_object_contents (bfd *abfd)
-{
- const struct elf_backend_data *bed = get_elf_backend_data (abfd);
- Elf_Internal_Shdr **i_shdrp;
- bool failed;
- unsigned int count, num_sec;
- struct elf_obj_tdata *t;
-
- if (! abfd->output_has_begun
- && ! _bfd_elf_compute_section_file_positions (abfd, NULL))
- return false;
- /* Do not rewrite ELF data when the BFD has been opened for update.
- abfd->output_has_begun was set to TRUE on opening, so creation of
- new sections, and modification of existing section sizes was
- restricted. This means the ELF header, program headers and
- section headers can't have changed. If the contents of any
- sections has been modified, then those changes have already been
- written to the BFD. */
- else if (abfd->direction == both_direction)
- {
- BFD_ASSERT (abfd->output_has_begun);
- return true;
- }
-
- i_shdrp = elf_elfsections (abfd);
-
- failed = false;
- bfd_map_over_sections (abfd, bed->s->write_relocs, &failed);
- if (failed)
- return false;
-
- if (!_bfd_elf_assign_file_positions_for_non_load (abfd))
- return false;
-
- /* After writing the headers, we need to write the sections too... */
- num_sec = elf_numsections (abfd);
- for (count = 1; count < num_sec; count++)
- {
- /* Don't set the sh_name field without section header. */
- if ((abfd->flags & BFD_NO_SECTION_HEADER) == 0)
- i_shdrp[count]->sh_name
- = _bfd_elf_strtab_offset (elf_shstrtab (abfd),
- i_shdrp[count]->sh_name);
- if (bed->elf_backend_section_processing)
- if (!(*bed->elf_backend_section_processing) (abfd, i_shdrp[count]))
- return false;
- if (i_shdrp[count]->contents)
- {
- bfd_size_type amt = i_shdrp[count]->sh_size;
-
- if (bfd_seek (abfd, i_shdrp[count]->sh_offset, SEEK_SET) != 0
- || bfd_write (i_shdrp[count]->contents, amt, abfd) != amt)
- return false;
- }
- }
-
- /* Write out the section header names. */
- t = elf_tdata (abfd);
- if (elf_shstrtab (abfd) != NULL
- && t->shstrtab_hdr.sh_offset != -1
- && (bfd_seek (abfd, t->shstrtab_hdr.sh_offset, SEEK_SET) != 0
- || !_bfd_elf_strtab_emit (abfd, elf_shstrtab (abfd))))
- return false;
-
- if (!(*bed->elf_backend_final_write_processing) (abfd))
- return false;
-
- if (!bed->s->write_shdrs_and_ehdr (abfd))
- return false;
-
- /* This is last since write_shdrs_and_ehdr can touch i_shdrp[0]. */
- if (t->o->build_id.after_write_object_contents != NULL
- && !(*t->o->build_id.after_write_object_contents) (abfd))
- return false;
- if (t->o->package_metadata.after_write_object_contents != NULL
- && !(*t->o->package_metadata.after_write_object_contents) (abfd))
- return false;
-
- return true;
-}
-
-bool
-_bfd_elf_write_corefile_contents (bfd *abfd)
-{
- /* Hopefully this can be done just like an object file. */
- return _bfd_elf_write_object_contents (abfd);
-}
-
-/* Given a section, search the header to find them. */
-
-unsigned int
-_bfd_elf_section_from_bfd_section (bfd *abfd, struct bfd_section *asect)
-{
- const struct elf_backend_data *bed;
- unsigned int sec_index;
-
- if (elf_section_data (asect) != NULL
- && elf_section_data (asect)->this_idx != 0)
- return elf_section_data (asect)->this_idx;
-
- if (bfd_is_abs_section (asect))
- sec_index = SHN_ABS;
- else if (bfd_is_com_section (asect))
- sec_index = SHN_COMMON;
- else if (bfd_is_und_section (asect))
- sec_index = SHN_UNDEF;
- else
- sec_index = SHN_BAD;
-
- bed = get_elf_backend_data (abfd);
- if (bed->elf_backend_section_from_bfd_section)
- {
- int retval = sec_index;
-
- if ((*bed->elf_backend_section_from_bfd_section) (abfd, asect, &retval))
- return retval;
- }
-
- if (sec_index == SHN_BAD)
- bfd_set_error (bfd_error_nonrepresentable_section);
-
- return sec_index;
-}
-
-/* Given a BFD symbol, return the index in the ELF symbol table, or -1
- on error. */
-
-int
-_bfd_elf_symbol_from_bfd_symbol (bfd *abfd, asymbol **asym_ptr_ptr)
-{
- asymbol *asym_ptr = *asym_ptr_ptr;
- int idx;
- flagword flags = asym_ptr->flags;
-
- /* When gas creates relocations against local labels, it creates its
- own symbol for the section, but does put the symbol into the
- symbol chain, so udata is 0. When the linker is generating
- relocatable output, this section symbol may be for one of the
- input sections rather than the output section. */
- if (asym_ptr->udata.i == 0
- && (flags & BSF_SECTION_SYM)
- && asym_ptr->section)
- {
- asection *sec;
-
- sec = asym_ptr->section;
- if (sec->owner != abfd && sec->output_section != NULL)
- sec = sec->output_section;
- if (sec->owner == abfd
- && sec->index < elf_num_section_syms (abfd)
- && elf_section_syms (abfd)[sec->index] != NULL)
- asym_ptr->udata.i = elf_section_syms (abfd)[sec->index]->udata.i;
- }
-
- idx = asym_ptr->udata.i;
-
- if (idx == 0)
- {
- /* This case can occur when using --strip-symbol on a symbol
- which is used in a relocation entry. */
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB: symbol `%s' required but not present"),
- abfd, bfd_asymbol_name (asym_ptr));
- bfd_set_error (bfd_error_no_symbols);
- return -1;
- }
-
-#if DEBUG & 4
- {
- fprintf (stderr,
- "elf_symbol_from_bfd_symbol 0x%.8lx, name = %s, sym num = %d,"
- " flags = 0x%.8x\n",
- (long) asym_ptr, asym_ptr->name, idx, flags);
- fflush (stderr);
- }
-#endif
-
- return idx;
-}
-
-static inline bfd_vma
-segment_size (Elf_Internal_Phdr *segment)
-{
- return (segment->p_memsz > segment->p_filesz
- ? segment->p_memsz : segment->p_filesz);
-}
-
-
-/* Returns the end address of the segment + 1. */
-static inline bfd_vma
-segment_end (Elf_Internal_Phdr *segment, bfd_vma start)
-{
- return start + segment_size (segment);
-}
-
-static inline bfd_size_type
-section_size (asection *section, Elf_Internal_Phdr *segment)
-{
- if ((section->flags & SEC_HAS_CONTENTS) != 0
- || (section->flags & SEC_THREAD_LOCAL) == 0
- || segment->p_type == PT_TLS)
- return section->size;
- return 0;
-}
-
-/* Returns TRUE if the given section is contained within the given
- segment. LMA addresses are compared against PADDR when
- USE_VADDR is false, VMA against VADDR when true. */
-static bool
-is_contained_by (asection *section, Elf_Internal_Phdr *segment,
- bfd_vma paddr, bfd_vma vaddr, unsigned int opb,
- bool use_vaddr)
-{
- bfd_vma seg_addr = !use_vaddr ? paddr : vaddr;
- bfd_vma addr = !use_vaddr ? section->lma : section->vma;
- bfd_vma octet;
- if (_bfd_mul_overflow (addr, opb, &octet))
- return false;
- /* The third and fourth lines below are testing that the section end
- address is within the segment. It's written this way to avoid
- overflow. Add seg_addr + section_size to both sides of the
- inequality to make it obvious. */
- return (octet >= seg_addr
- && segment_size (segment) >= section_size (section, segment)
- && (octet - seg_addr
- <= segment_size (segment) - section_size (section, segment)));
-}
-
-/* Handle PT_NOTE segment. */
-static bool
-is_note (asection *s, Elf_Internal_Phdr *p)
-{
- return (p->p_type == PT_NOTE
- && elf_section_type (s) == SHT_NOTE
- && (ufile_ptr) s->filepos >= p->p_offset
- && p->p_filesz >= s->size
- && (ufile_ptr) s->filepos - p->p_offset <= p->p_filesz - s->size);
-}
-
-/* Rewrite program header information. */
-
-static bool
-rewrite_elf_program_header (bfd *ibfd, bfd *obfd, bfd_vma maxpagesize)
-{
- Elf_Internal_Ehdr *iehdr;
- struct elf_segment_map *map;
- struct elf_segment_map *map_first;
- struct elf_segment_map **pointer_to_map;
- Elf_Internal_Phdr *segment;
- asection *section;
- unsigned int i;
- unsigned int num_segments;
- bool phdr_included = false;
- bool p_paddr_valid;
- struct elf_segment_map *phdr_adjust_seg = NULL;
- unsigned int phdr_adjust_num = 0;
- const struct elf_backend_data *bed;
- unsigned int opb = bfd_octets_per_byte (ibfd, NULL);
-
- bed = get_elf_backend_data (ibfd);
- iehdr = elf_elfheader (ibfd);
-
- map_first = NULL;
- pointer_to_map = &map_first;
-
- num_segments = elf_elfheader (ibfd)->e_phnum;
-
- /* The complicated case when p_vaddr is 0 is to handle the Solaris
- linker, which generates a PT_INTERP section with p_vaddr and
- p_memsz set to 0. */
-#define IS_SOLARIS_PT_INTERP(p, s) \
- (p->p_vaddr == 0 \
- && p->p_paddr == 0 \
- && p->p_memsz == 0 \
- && p->p_filesz > 0 \
- && (s->flags & SEC_HAS_CONTENTS) != 0 \
- && s->size > 0 \
- && (bfd_vma) s->filepos >= p->p_offset \
- && ((bfd_vma) s->filepos + s->size \
- <= p->p_offset + p->p_filesz))
-
- /* Decide if the given section should be included in the given segment.
- A section will be included if:
- 1. It is within the address space of the segment -- we use the LMA
- if that is set for the segment and the VMA otherwise,
- 2. It is an allocated section or a NOTE section in a PT_NOTE
- segment.
- 3. There is an output section associated with it,
- 4. The section has not already been allocated to a previous segment.
- 5. PT_GNU_STACK segments do not include any sections.
- 6. PT_TLS segment includes only SHF_TLS sections.
- 7. SHF_TLS sections are only in PT_TLS or PT_LOAD segments.
- 8. PT_DYNAMIC should not contain empty sections at the beginning
- (with the possible exception of .dynamic). */
-#define IS_SECTION_IN_INPUT_SEGMENT(section, segment, opb, paddr_valid) \
- (((is_contained_by (section, segment, segment->p_paddr, \
- segment->p_vaddr, opb, !paddr_valid) \
- && (section->flags & SEC_ALLOC) != 0) \
- || is_note (section, segment)) \
- && segment->p_type != PT_GNU_STACK \
- && (segment->p_type != PT_TLS \
- || (section->flags & SEC_THREAD_LOCAL)) \
- && (segment->p_type == PT_LOAD \
- || segment->p_type == PT_TLS \
- || (section->flags & SEC_THREAD_LOCAL) == 0) \
- && (segment->p_type != PT_DYNAMIC \
- || section_size (section, segment) > 0 \
- || (segment->p_paddr \
- ? segment->p_paddr != section->lma * (opb) \
- : segment->p_vaddr != section->vma * (opb)) \
- || (strcmp (bfd_section_name (section), ".dynamic") == 0)) \
- && (segment->p_type != PT_LOAD || !section->segment_mark))
-
-/* If the output section of a section in the input segment is NULL,
- it is removed from the corresponding output segment. */
-#define INCLUDE_SECTION_IN_SEGMENT(section, segment, opb, paddr_valid) \
- (IS_SECTION_IN_INPUT_SEGMENT (section, segment, opb, paddr_valid) \
- && section->output_section != NULL)
-
- /* Returns TRUE iff seg1 starts after the end of seg2. */
-#define SEGMENT_AFTER_SEGMENT(seg1, seg2, field) \
- (seg1->field >= segment_end (seg2, seg2->field))
-
- /* Returns TRUE iff seg1 and seg2 overlap. Segments overlap iff both
- their VMA address ranges and their LMA address ranges overlap.
- It is possible to have overlapping VMA ranges without overlapping LMA
- ranges. RedBoot images for example can have both .data and .bss mapped
- to the same VMA range, but with the .data section mapped to a different
- LMA. */
-#define SEGMENT_OVERLAPS(seg1, seg2) \
- ( !(SEGMENT_AFTER_SEGMENT (seg1, seg2, p_vaddr) \
- || SEGMENT_AFTER_SEGMENT (seg2, seg1, p_vaddr)) \
- && !(SEGMENT_AFTER_SEGMENT (seg1, seg2, p_paddr) \
- || SEGMENT_AFTER_SEGMENT (seg2, seg1, p_paddr)))
-
- /* Initialise the segment mark field, and discard stupid alignment. */
- for (section = ibfd->sections; section != NULL; section = section->next)
- {
- asection *o = section->output_section;
- if (o != NULL && o->alignment_power >= (sizeof (bfd_vma) * 8) - 1)
- o->alignment_power = 0;
- section->segment_mark = false;
- }
-
- /* The Solaris linker creates program headers in which all the
- p_paddr fields are zero. When we try to objcopy or strip such a
- file, we get confused. Check for this case, and if we find it
- don't set the p_paddr_valid fields. */
- p_paddr_valid = false;
- for (i = 0, segment = elf_tdata (ibfd)->phdr;
- i < num_segments;
- i++, segment++)
- if (segment->p_paddr != 0)
- {
- p_paddr_valid = true;
- break;
- }
-
- /* Scan through the segments specified in the program header
- of the input BFD. For this first scan we look for overlaps
- in the loadable segments. These can be created by weird
- parameters to objcopy. Also, fix some solaris weirdness. */
- for (i = 0, segment = elf_tdata (ibfd)->phdr;
- i < num_segments;
- i++, segment++)
- {
- unsigned int j;
- Elf_Internal_Phdr *segment2;
-
- if (segment->p_type == PT_INTERP)
- for (section = ibfd->sections; section; section = section->next)
- if (IS_SOLARIS_PT_INTERP (segment, section))
- {
- /* Mininal change so that the normal section to segment
- assignment code will work. */
- segment->p_vaddr = section->vma * opb;
- break;
- }
-
- if (segment->p_type != PT_LOAD)
- {
- /* Remove PT_GNU_RELRO segment. */
- if (segment->p_type == PT_GNU_RELRO)
- segment->p_type = PT_NULL;
- continue;
- }
-
- /* Determine if this segment overlaps any previous segments. */
- for (j = 0, segment2 = elf_tdata (ibfd)->phdr; j < i; j++, segment2++)
- {
- bfd_signed_vma extra_length;
-
- if (segment2->p_type != PT_LOAD
- || !SEGMENT_OVERLAPS (segment, segment2))
- continue;
-
- /* Merge the two segments together. */
- if (segment2->p_vaddr < segment->p_vaddr)
- {
- /* Extend SEGMENT2 to include SEGMENT and then delete
- SEGMENT. */
- extra_length = (segment_end (segment, segment->p_vaddr)
- - segment_end (segment2, segment2->p_vaddr));
-
- if (extra_length > 0)
- {
- segment2->p_memsz += extra_length;
- segment2->p_filesz += extra_length;
- }
-
- segment->p_type = PT_NULL;
-
- /* Since we have deleted P we must restart the outer loop. */
- i = 0;
- segment = elf_tdata (ibfd)->phdr;
- break;
- }
- else
- {
- /* Extend SEGMENT to include SEGMENT2 and then delete
- SEGMENT2. */
- extra_length = (segment_end (segment2, segment2->p_vaddr)
- - segment_end (segment, segment->p_vaddr));
-
- if (extra_length > 0)
- {
- segment->p_memsz += extra_length;
- segment->p_filesz += extra_length;
- }
-
- segment2->p_type = PT_NULL;
- }
- }
- }
-
- /* The second scan attempts to assign sections to segments. */
- for (i = 0, segment = elf_tdata (ibfd)->phdr;
- i < num_segments;
- i++, segment++)
- {
- unsigned int section_count;
- asection **sections;
- asection *output_section;
- unsigned int isec;
- asection *matching_lma;
- asection *suggested_lma;
- unsigned int j;
- size_t amt;
- asection *first_section;
-
- if (segment->p_type == PT_NULL)
- continue;
-
- first_section = NULL;
- /* Compute how many sections might be placed into this segment. */
- for (section = ibfd->sections, section_count = 0;
- section != NULL;
- section = section->next)
- {
- /* Find the first section in the input segment, which may be
- removed from the corresponding output segment. */
- if (IS_SECTION_IN_INPUT_SEGMENT (section, segment, opb, p_paddr_valid))
- {
- if (first_section == NULL)
- first_section = section;
- if (section->output_section != NULL)
- ++section_count;
- }
- }
-
- /* Allocate a segment map big enough to contain
- all of the sections we have selected. */
- amt = sizeof (struct elf_segment_map) - sizeof (asection *);
- amt += section_count * sizeof (asection *);
- map = (struct elf_segment_map *) bfd_zalloc (obfd, amt);
- if (map == NULL)
- return false;
-
- /* Initialise the fields of the segment map. Default to
- using the physical address of the segment in the input BFD. */
- map->next = NULL;
- map->p_type = segment->p_type;
- map->p_flags = segment->p_flags;
- map->p_flags_valid = 1;
-
- if (map->p_type == PT_LOAD
- && (ibfd->flags & D_PAGED) != 0
- && maxpagesize > 1
- && segment->p_align > 1)
- {
- map->p_align = segment->p_align;
- if (segment->p_align > maxpagesize)
- map->p_align = maxpagesize;
- map->p_align_valid = 1;
- }
-
- /* If the first section in the input segment is removed, there is
- no need to preserve segment physical address in the corresponding
- output segment. */
- if (!first_section || first_section->output_section != NULL)
- {
- map->p_paddr = segment->p_paddr;
- map->p_paddr_valid = p_paddr_valid;
- }
-
- /* Determine if this segment contains the ELF file header
- and if it contains the program headers themselves. */
- map->includes_filehdr = (segment->p_offset == 0
- && segment->p_filesz >= iehdr->e_ehsize);
- map->includes_phdrs = 0;
-
- if (!phdr_included || segment->p_type != PT_LOAD)
- {
- map->includes_phdrs =
- (segment->p_offset <= (bfd_vma) iehdr->e_phoff
- && (segment->p_offset + segment->p_filesz
- >= ((bfd_vma) iehdr->e_phoff
- + iehdr->e_phnum * iehdr->e_phentsize)));
-
- if (segment->p_type == PT_LOAD && map->includes_phdrs)
- phdr_included = true;
- }
-
- if (section_count == 0)
- {
- /* Special segments, such as the PT_PHDR segment, may contain
- no sections, but ordinary, loadable segments should contain
- something. They are allowed by the ELF spec however, so only
- a warning is produced.
- Don't warn if an empty PT_LOAD contains the program headers.
- There is however the valid use case of embedded systems which
- have segments with p_filesz of 0 and a p_memsz > 0 to initialize
- flash memory with zeros. No warning is shown for that case. */
- if (segment->p_type == PT_LOAD
- && !map->includes_phdrs
- && (segment->p_filesz > 0 || segment->p_memsz == 0))
- /* xgettext:c-format */
- _bfd_error_handler
- (_("%pB: warning: empty loadable segment detected"
- " at vaddr=%#" PRIx64 ", is this intentional?"),
- ibfd, (uint64_t) segment->p_vaddr);
-
- map->p_vaddr_offset = segment->p_vaddr / opb;
- map->count = 0;
- *pointer_to_map = map;
- pointer_to_map = &map->next;
-
- continue;
- }
-
- /* Now scan the sections in the input BFD again and attempt
- to add their corresponding output sections to the segment map.
- The problem here is how to handle an output section which has
- been moved (ie had its LMA changed). There are four possibilities:
-
- 1. None of the sections have been moved.
- In this case we can continue to use the segment LMA from the
- input BFD.
-
- 2. All of the sections have been moved by the same amount.
- In this case we can change the segment's LMA to match the LMA
- of the first section.
-
- 3. Some of the sections have been moved, others have not.
- In this case those sections which have not been moved can be
- placed in the current segment which will have to have its size,
- and possibly its LMA changed, and a new segment or segments will
- have to be created to contain the other sections.
-
- 4. The sections have been moved, but not by the same amount.
- In this case we can change the segment's LMA to match the LMA
- of the first section and we will have to create a new segment
- or segments to contain the other sections.
-
- In order to save time, we allocate an array to hold the section
- pointers that we are interested in. As these sections get assigned
- to a segment, they are removed from this array. */
-
- amt = section_count * sizeof (asection *);
- sections = (asection **) bfd_malloc (amt);
- if (sections == NULL)
- return false;
-
- /* Step One: Scan for segment vs section LMA conflicts.
- Also add the sections to the section array allocated above.
- Also add the sections to the current segment. In the common
- case, where the sections have not been moved, this means that
- we have completely filled the segment, and there is nothing
- more to do. */
- isec = 0;
- matching_lma = NULL;
- suggested_lma = NULL;
-
- for (section = first_section, j = 0;
- section != NULL;
- section = section->next)
- {
- if (INCLUDE_SECTION_IN_SEGMENT (section, segment, opb, p_paddr_valid))
- {
- output_section = section->output_section;
-
- sections[j++] = section;
-
- /* The Solaris native linker always sets p_paddr to 0.
- We try to catch that case here, and set it to the
- correct value. Note - some backends require that
- p_paddr be left as zero. */
- if (!p_paddr_valid
- && segment->p_vaddr != 0
- && !bed->want_p_paddr_set_to_zero
- && isec == 0
- && output_section->lma != 0
- && (align_power (segment->p_vaddr
- + (map->includes_filehdr
- ? iehdr->e_ehsize : 0)
- + (map->includes_phdrs
- ? iehdr->e_phnum * iehdr->e_phentsize
- : 0),
- output_section->alignment_power * opb)
- == (output_section->vma * opb)))
- map->p_paddr = segment->p_vaddr;
-
- /* Match up the physical address of the segment with the
- LMA address of the output section. */
- if (is_contained_by (output_section, segment, map->p_paddr,
- 0, opb, false)
- || is_note (section, segment))
- {
- if (matching_lma == NULL
- || output_section->lma < matching_lma->lma)
- matching_lma = output_section;
-
- /* We assume that if the section fits within the segment
- then it does not overlap any other section within that
- segment. */
- map->sections[isec++] = output_section;
- }
- else if (suggested_lma == NULL)
- suggested_lma = output_section;
-
- if (j == section_count)
- break;
- }
- }
-
- BFD_ASSERT (j == section_count);
-
- /* Step Two: Adjust the physical address of the current segment,
- if necessary. */
- if (isec == section_count)
- {
- /* All of the sections fitted within the segment as currently
- specified. This is the default case. Add the segment to
- the list of built segments and carry on to process the next
- program header in the input BFD. */
- map->count = section_count;
- *pointer_to_map = map;
- pointer_to_map = &map->next;
-
- if (p_paddr_valid
- && !bed->want_p_paddr_set_to_zero)
- {
- bfd_vma hdr_size = 0;
- if (map->includes_filehdr)
- hdr_size = iehdr->e_ehsize;
- if (map->includes_phdrs)
- hdr_size += iehdr->e_phnum * iehdr->e_phentsize;
-
- /* Account for padding before the first section in the
- segment. */
- map->p_vaddr_offset = ((map->p_paddr + hdr_size) / opb
- - matching_lma->lma);
- }
-
- free (sections);
- continue;
- }
- else
- {
- /* Change the current segment's physical address to match
- the LMA of the first section that fitted, or if no
- section fitted, the first section. */
- if (matching_lma == NULL)
- matching_lma = suggested_lma;
-
- map->p_paddr = matching_lma->lma * opb;
-
- /* Offset the segment physical address from the lma
- to allow for space taken up by elf headers. */
- if (map->includes_phdrs)
- {
- map->p_paddr -= iehdr->e_phnum * iehdr->e_phentsize;
-
- /* iehdr->e_phnum is just an estimate of the number
- of program headers that we will need. Make a note
- here of the number we used and the segment we chose
- to hold these headers, so that we can adjust the
- offset when we know the correct value. */
- phdr_adjust_num = iehdr->e_phnum;
- phdr_adjust_seg = map;
- }
-
- if (map->includes_filehdr)
- {
- bfd_vma align = (bfd_vma) 1 << matching_lma->alignment_power;
- map->p_paddr -= iehdr->e_ehsize;
- /* We've subtracted off the size of headers from the
- first section lma, but there may have been some
- alignment padding before that section too. Try to
- account for that by adjusting the segment lma down to
- the same alignment. */
- if (segment->p_align != 0 && segment->p_align < align)
- align = segment->p_align;
- map->p_paddr &= -(align * opb);
- }
- }
-
- /* Step Three: Loop over the sections again, this time assigning
- those that fit to the current segment and removing them from the
- sections array; but making sure not to leave large gaps. Once all
- possible sections have been assigned to the current segment it is
- added to the list of built segments and if sections still remain
- to be assigned, a new segment is constructed before repeating
- the loop. */
- isec = 0;
- do
- {
- map->count = 0;
- suggested_lma = NULL;
-
- /* Fill the current segment with sections that fit. */
- for (j = 0; j < section_count; j++)
- {
- section = sections[j];
-
- if (section == NULL)
- continue;
-
- output_section = section->output_section;
-
- BFD_ASSERT (output_section != NULL);
-
- if (is_contained_by (output_section, segment, map->p_paddr,
- 0, opb, false)
- || is_note (section, segment))
- {
- if (map->count == 0)
- {
- /* If the first section in a segment does not start at
- the beginning of the segment, then something is
- wrong. */
- if (align_power (map->p_paddr
- + (map->includes_filehdr
- ? iehdr->e_ehsize : 0)
- + (map->includes_phdrs
- ? iehdr->e_phnum * iehdr->e_phentsize
- : 0),
- output_section->alignment_power * opb)
- != output_section->lma * opb)
- goto sorry;
- }
- else
- {
- asection *prev_sec;
-
- prev_sec = map->sections[map->count - 1];
-
- /* If the gap between the end of the previous section
- and the start of this section is more than
- maxpagesize then we need to start a new segment. */
- if ((BFD_ALIGN (prev_sec->lma + prev_sec->size,
- maxpagesize)
- < BFD_ALIGN (output_section->lma, maxpagesize))
- || (prev_sec->lma + prev_sec->size
- > output_section->lma))
- {
- if (suggested_lma == NULL)
- suggested_lma = output_section;
-
- continue;
- }
- }
-
- map->sections[map->count++] = output_section;
- ++isec;
- sections[j] = NULL;
- if (segment->p_type == PT_LOAD)
- section->segment_mark = true;
- }
- else if (suggested_lma == NULL)
- suggested_lma = output_section;
- }
-
- /* PR 23932. A corrupt input file may contain sections that cannot
- be assigned to any segment - because for example they have a
- negative size - or segments that do not contain any sections.
- But there are also valid reasons why a segment can be empty.
- So allow a count of zero. */
-
- /* Add the current segment to the list of built segments. */
- *pointer_to_map = map;
- pointer_to_map = &map->next;
-
- if (isec < section_count)
- {
- /* We still have not allocated all of the sections to
- segments. Create a new segment here, initialise it
- and carry on looping. */
- amt = sizeof (struct elf_segment_map) - sizeof (asection *);
- amt += section_count * sizeof (asection *);
- map = (struct elf_segment_map *) bfd_zalloc (obfd, amt);
- if (map == NULL)
- {
- free (sections);
- return false;
- }
-
- /* Initialise the fields of the segment map. Set the physical
- physical address to the LMA of the first section that has
- not yet been assigned. */
- map->next = NULL;
- map->p_type = segment->p_type;
- map->p_flags = segment->p_flags;
- map->p_flags_valid = 1;
- map->p_paddr = suggested_lma->lma * opb;
- map->p_paddr_valid = p_paddr_valid;
- map->includes_filehdr = 0;
- map->includes_phdrs = 0;
- }
-
- continue;
- sorry:
- bfd_set_error (bfd_error_sorry);
- free (sections);
- return false;
- }
- while (isec < section_count);
-
- free (sections);
- }
-
- elf_seg_map (obfd) = map_first;
-
- /* If we had to estimate the number of program headers that were
- going to be needed, then check our estimate now and adjust
- the offset if necessary. */
- if (phdr_adjust_seg != NULL)
- {
- unsigned int count;
-
- for (count = 0, map = map_first; map != NULL; map = map->next)
- count++;
-
- if (count > phdr_adjust_num)
- phdr_adjust_seg->p_paddr
- -= (count - phdr_adjust_num) * iehdr->e_phentsize;
-
- for (map = map_first; map != NULL; map = map->next)
- if (map->p_type == PT_PHDR)
- {
- bfd_vma adjust
- = phdr_adjust_seg->includes_filehdr ? iehdr->e_ehsize : 0;
- map->p_paddr = phdr_adjust_seg->p_paddr + adjust;
- break;
- }
- }
-
-#undef IS_SOLARIS_PT_INTERP
-#undef IS_SECTION_IN_INPUT_SEGMENT
-#undef INCLUDE_SECTION_IN_SEGMENT
-#undef SEGMENT_AFTER_SEGMENT
-#undef SEGMENT_OVERLAPS
- return true;
-}
-
-/* Return true if p_align in the ELF program header in ABFD is valid. */
-
-static bool
-elf_is_p_align_valid (bfd *abfd)
-{
- unsigned int i;
- Elf_Internal_Phdr *segment;
- unsigned int num_segments;
- const struct elf_backend_data *bed = get_elf_backend_data (abfd);
- bfd_size_type maxpagesize = bed->maxpagesize;
- bfd_size_type p_align = bed->p_align;
-
- /* Return true if the default p_align value isn't set or the maximum
- page size is the same as the minimum page size. */
- if (p_align == 0 || maxpagesize == bed->minpagesize)
- return true;
-
- /* When the default p_align value is set, p_align may be set to the
- default p_align value while segments are aligned to the maximum
- page size. In this case, the input p_align will be ignored and
- the maximum page size will be used to align the output segments. */
- segment = elf_tdata (abfd)->phdr;
- num_segments = elf_elfheader (abfd)->e_phnum;
- for (i = 0; i < num_segments; i++, segment++)
- if (segment->p_type == PT_LOAD
- && (segment->p_align != p_align
- || vma_page_aligned_bias (segment->p_vaddr,
- segment->p_offset,
- maxpagesize) != 0))
- return true;
-
- return false;
-}
-
-/* Copy ELF program header information. */
-
-static bool
-copy_elf_program_header (bfd *ibfd, bfd *obfd)
-{
- Elf_Internal_Ehdr *iehdr;
- struct elf_segment_map *map;
- struct elf_segment_map *map_first;
- struct elf_segment_map **pointer_to_map;
- Elf_Internal_Phdr *segment;
- unsigned int i;
- unsigned int num_segments;
- bool phdr_included = false;
- bool p_paddr_valid;
- bool p_palign_valid;
- unsigned int opb = bfd_octets_per_byte (ibfd, NULL);
-
- iehdr = elf_elfheader (ibfd);
-
- map_first = NULL;
- pointer_to_map = &map_first;
-
- /* If all the segment p_paddr fields are zero, don't set
- map->p_paddr_valid. */
- p_paddr_valid = false;
- num_segments = elf_elfheader (ibfd)->e_phnum;
- for (i = 0, segment = elf_tdata (ibfd)->phdr;
- i < num_segments;
- i++, segment++)
- if (segment->p_paddr != 0)
- {
- p_paddr_valid = true;
- break;
- }
-
- p_palign_valid = elf_is_p_align_valid (ibfd);
-
- for (i = 0, segment = elf_tdata (ibfd)->phdr;
- i < num_segments;
- i++, segment++)
- {
- asection *section;
- unsigned int section_count;
- size_t amt;
- Elf_Internal_Shdr *this_hdr;
- asection *first_section = NULL;
- asection *lowest_section;
-
- /* Compute how many sections are in this segment. */
- for (section = ibfd->sections, section_count = 0;
- section != NULL;
- section = section->next)
- {
- this_hdr = &(elf_section_data(section)->this_hdr);
- if (ELF_SECTION_IN_SEGMENT (this_hdr, segment))
- {
- if (first_section == NULL)
- first_section = section;
- section_count++;
- }
- }
-
- /* Allocate a segment map big enough to contain
- all of the sections we have selected. */
- amt = sizeof (struct elf_segment_map) - sizeof (asection *);
- amt += section_count * sizeof (asection *);
- map = (struct elf_segment_map *) bfd_zalloc (obfd, amt);
- if (map == NULL)
- return false;
-
- /* Initialize the fields of the output segment map with the
- input segment. */
- map->next = NULL;
- map->p_type = segment->p_type;
- map->p_flags = segment->p_flags;
- map->p_flags_valid = 1;
- map->p_paddr = segment->p_paddr;
- map->p_paddr_valid = p_paddr_valid;
- map->p_align = segment->p_align;
- /* Keep p_align of PT_GNU_STACK for stack alignment. */
- map->p_align_valid = (map->p_type == PT_GNU_STACK
- || p_palign_valid);
- map->p_vaddr_offset = 0;
-
- if (map->p_type == PT_GNU_RELRO
- || map->p_type == PT_GNU_STACK)
- {
- /* The PT_GNU_RELRO segment may contain the first a few
- bytes in the .got.plt section even if the whole .got.plt
- section isn't in the PT_GNU_RELRO segment. We won't
- change the size of the PT_GNU_RELRO segment.
- Similarly, PT_GNU_STACK size is significant on uclinux
- systems. */
- map->p_size = segment->p_memsz;
- map->p_size_valid = 1;
- }
-
- /* Determine if this segment contains the ELF file header
- and if it contains the program headers themselves. */
- map->includes_filehdr = (segment->p_offset == 0
- && segment->p_filesz >= iehdr->e_ehsize);
-
- map->includes_phdrs = 0;
- if (! phdr_included || segment->p_type != PT_LOAD)
- {
- map->includes_phdrs =
- (segment->p_offset <= (bfd_vma) iehdr->e_phoff
- && (segment->p_offset + segment->p_filesz
- >= ((bfd_vma) iehdr->e_phoff
- + iehdr->e_phnum * iehdr->e_phentsize)));
-
- if (segment->p_type == PT_LOAD && map->includes_phdrs)
- phdr_included = true;
- }
-
- lowest_section = NULL;
- if (section_count != 0)
- {
- unsigned int isec = 0;
-
- for (section = first_section;
- section != NULL;
- section = section->next)
- {
- this_hdr = &(elf_section_data(section)->this_hdr);
- if (ELF_SECTION_IN_SEGMENT (this_hdr, segment))
- {
- map->sections[isec++] = section->output_section;
- if ((section->flags & SEC_ALLOC) != 0)
- {
- bfd_vma seg_off;
-
- if (lowest_section == NULL
- || section->lma < lowest_section->lma)
- lowest_section = section;
-
- /* Section lmas are set up from PT_LOAD header
- p_paddr in _bfd_elf_make_section_from_shdr.
- If this header has a p_paddr that disagrees
- with the section lma, flag the p_paddr as
- invalid. */
- if ((section->flags & SEC_LOAD) != 0)
- seg_off = this_hdr->sh_offset - segment->p_offset;
- else
- seg_off = this_hdr->sh_addr - segment->p_vaddr;
- if (section->lma * opb - segment->p_paddr != seg_off)
- map->p_paddr_valid = false;
- }
- if (isec == section_count)
- break;
- }
- }
- }
-
- if (section_count == 0)
- map->p_vaddr_offset = segment->p_vaddr / opb;
- else if (map->p_paddr_valid)
- {
- /* Account for padding before the first section in the segment. */
- bfd_vma hdr_size = 0;
- if (map->includes_filehdr)
- hdr_size = iehdr->e_ehsize;
- if (map->includes_phdrs)
- hdr_size += iehdr->e_phnum * iehdr->e_phentsize;
-
- map->p_vaddr_offset = ((map->p_paddr + hdr_size) / opb
- - (lowest_section ? lowest_section->lma : 0));
- }
-
- map->count = section_count;
- *pointer_to_map = map;
- pointer_to_map = &map->next;
- }
-
- elf_seg_map (obfd) = map_first;
- return true;
-}
-
-/* Copy private BFD data. This copies or rewrites ELF program header
- information. */
-
-static bool
-copy_private_bfd_data (bfd *ibfd, bfd *obfd)
-{
- bfd_vma maxpagesize;
-
- if (bfd_get_flavour (ibfd) != bfd_target_elf_flavour
- || bfd_get_flavour (obfd) != bfd_target_elf_flavour)
- return true;
-
- if (elf_tdata (ibfd)->phdr == NULL)
- return true;
-
- if (ibfd->xvec == obfd->xvec)
- {
- /* Check to see if any sections in the input BFD
- covered by ELF program header have changed. */
- Elf_Internal_Phdr *segment;
- asection * section;
- asection * osec;
- asection * prev;
- unsigned int i, num_segments;
- Elf_Internal_Shdr *this_hdr;
- const struct elf_backend_data *bed;
-
- bed = get_elf_backend_data (ibfd);
-
- /* Regenerate the segment map if p_paddr is set to 0. */
- if (bed->want_p_paddr_set_to_zero)
- goto rewrite;
-
- /* Initialize the segment mark field. */
- for (section = obfd->sections; section != NULL;
- section = section->next)
- section->segment_mark = false;
-
- num_segments = elf_elfheader (ibfd)->e_phnum;
- for (i = 0, segment = elf_tdata (ibfd)->phdr;
- i < num_segments;
- i++, segment++)
- {
- /* PR binutils/3535. The Solaris linker always sets the p_paddr
- and p_memsz fields of special segments (DYNAMIC, INTERP) to 0
- which severly confuses things, so always regenerate the segment
- map in this case. */
- if (segment->p_paddr == 0
- && segment->p_memsz == 0
- && (segment->p_type == PT_INTERP
- || segment->p_type == PT_DYNAMIC))
- goto rewrite;
-
- for (section = ibfd->sections, prev = NULL;
- section != NULL; section = section->next)
- {
- /* We mark the output section so that we know it comes
- from the input BFD. */
- osec = section->output_section;
- if (osec)
- osec->segment_mark = true;
-
- /* Check if this section is covered by the segment. */
- this_hdr = &(elf_section_data(section)->this_hdr);
- if (ELF_SECTION_IN_SEGMENT (this_hdr, segment))
- {
- /* FIXME: Check if its output section is changed or
- removed. What else do we need to check? */
- if (osec == NULL
- || section->flags != osec->flags
- || section->lma != osec->lma
- || section->vma != osec->vma
- || section->size != osec->size
- || section->rawsize != osec->rawsize
- || section->alignment_power != osec->alignment_power)
- goto rewrite;
-
- /* PR 31450: If this is an allocated section then make sure
- that this section's vma to lma relationship is the same
- as previous (allocated) section's. */
- if (prev != NULL
- && section->flags & SEC_ALLOC
- && section->lma - section->vma != prev->lma - prev->vma)
- goto rewrite;
-
- if (section->flags & SEC_ALLOC)
- prev = section;
- }
- }
- }
-
- /* Check to see if any output section do not come from the
- input BFD. */
- for (section = obfd->sections; section != NULL;
- section = section->next)
- {
- if (!section->segment_mark)
- goto rewrite;
- else
- section->segment_mark = false;
- }
-
- return copy_elf_program_header (ibfd, obfd);
- }
-
- rewrite:
- maxpagesize = 0;
- if (ibfd->xvec == obfd->xvec)
- {
- /* When rewriting program header, set the output maxpagesize to
- the maximum alignment of input PT_LOAD segments. */
- Elf_Internal_Phdr *segment;
- unsigned int i;
- unsigned int num_segments = elf_elfheader (ibfd)->e_phnum;
-
- for (i = 0, segment = elf_tdata (ibfd)->phdr;
- i < num_segments;
- i++, segment++)
- if (segment->p_type == PT_LOAD
- && maxpagesize < segment->p_align)
- {
- /* PR 17512: file: f17299af. */
- if (segment->p_align > (bfd_vma) 1 << ((sizeof (bfd_vma) * 8) - 2))
- /* xgettext:c-format */
- _bfd_error_handler (_("%pB: warning: segment alignment of %#"
- PRIx64 " is too large"),
- ibfd, (uint64_t) segment->p_align);
- else
- maxpagesize = segment->p_align;
- }
- }
- if (maxpagesize == 0)
- maxpagesize = get_elf_backend_data (obfd)->maxpagesize;
-
- return rewrite_elf_program_header (ibfd, obfd, maxpagesize);
-}
-
-/* Initialize private output section information from input section. */
-
-bool
-_bfd_elf_init_private_section_data (bfd *ibfd,
- asection *isec,
- bfd *obfd,
- asection *osec,
- struct bfd_link_info *link_info)
-
-{
- Elf_Internal_Shdr *ihdr, *ohdr;
- bool final_link = (link_info != NULL
- && !bfd_link_relocatable (link_info));
-
- if (ibfd->xvec->flavour != bfd_target_elf_flavour
- || obfd->xvec->flavour != bfd_target_elf_flavour)
- return true;
-
- BFD_ASSERT (elf_section_data (osec) != NULL);
-
- /* If this is a known ABI section, ELF section type and flags may
- have been set up when OSEC was created. For normal sections we
- allow the user to override the type and flags other than
- SHF_MASKOS and SHF_MASKPROC. */
- if (elf_section_type (osec) == SHT_PROGBITS
- || elf_section_type (osec) == SHT_NOTE
- || elf_section_type (osec) == SHT_NOBITS)
- elf_section_type (osec) = SHT_NULL;
- /* For objcopy and relocatable link, copy the ELF section type from
- the input file if the BFD section flags are the same. (If they
- are different the user may be doing something like
- "objcopy --set-section-flags .text=alloc,data".) For a final
- link allow some flags that the linker clears to differ. */
- if (elf_section_type (osec) == SHT_NULL
- && (osec->flags == isec->flags
- || (final_link
- && ((osec->flags ^ isec->flags)
- & ~(SEC_LINK_ONCE | SEC_LINK_DUPLICATES | SEC_RELOC)) == 0)))
- elf_section_type (osec) = elf_section_type (isec);
-
- /* FIXME: Is this correct for all OS/PROC specific flags? */
- elf_section_flags (osec) = (elf_section_flags (isec)
- & (SHF_MASKOS | SHF_MASKPROC));
-
- /* Copy sh_info from input for mbind section. */
- if ((elf_tdata (ibfd)->has_gnu_osabi & elf_gnu_osabi_mbind) != 0
- && elf_section_flags (isec) & SHF_GNU_MBIND)
- elf_section_data (osec)->this_hdr.sh_info
- = elf_section_data (isec)->this_hdr.sh_info;
-
- /* Set things up for objcopy and relocatable link. The output
- SHT_GROUP section will have its elf_next_in_group pointing back
- to the input group members. Ignore linker created group section.
- See elfNN_ia64_object_p in elfxx-ia64.c. */
- if ((link_info == NULL
- || !link_info->resolve_section_groups)
- && (elf_sec_group (isec) == NULL
- || (elf_sec_group (isec)->flags & SEC_LINKER_CREATED) == 0))
- {
- if (elf_section_flags (isec) & SHF_GROUP)
- elf_section_flags (osec) |= SHF_GROUP;
- elf_next_in_group (osec) = elf_next_in_group (isec);
- elf_section_data (osec)->group = elf_section_data (isec)->group;
- }
-
- /* If not decompress, preserve SHF_COMPRESSED. */
- if (!final_link && (ibfd->flags & BFD_DECOMPRESS) == 0)
- elf_section_flags (osec) |= (elf_section_flags (isec)
- & SHF_COMPRESSED);
-
- ihdr = &elf_section_data (isec)->this_hdr;
-
- /* We need to handle elf_linked_to_section for SHF_LINK_ORDER. We
- don't use the output section of the linked-to section since it
- may be NULL at this point. */
- if ((ihdr->sh_flags & SHF_LINK_ORDER) != 0)
- {
- ohdr = &elf_section_data (osec)->this_hdr;
- ohdr->sh_flags |= SHF_LINK_ORDER;
- elf_linked_to_section (osec) = elf_linked_to_section (isec);
- }
-
- osec->use_rela_p = isec->use_rela_p;
-
- return true;
-}
-
-/* Copy private section information. This copies over the entsize
- field, and sometimes the info field. */
-
-bool
-_bfd_elf_copy_private_section_data (bfd *ibfd,
- asection *isec,
- bfd *obfd,
- asection *osec)
-{
- Elf_Internal_Shdr *ihdr, *ohdr;
-
- if (ibfd->xvec->flavour != bfd_target_elf_flavour
- || obfd->xvec->flavour != bfd_target_elf_flavour)
- return true;
-
- ihdr = &elf_section_data (isec)->this_hdr;
- ohdr = &elf_section_data (osec)->this_hdr;
-
- ohdr->sh_entsize = ihdr->sh_entsize;
-
- if (ihdr->sh_type == SHT_SYMTAB
- || ihdr->sh_type == SHT_DYNSYM
- || ihdr->sh_type == SHT_GNU_verneed
- || ihdr->sh_type == SHT_GNU_verdef)
- ohdr->sh_info = ihdr->sh_info;
-
- return _bfd_elf_init_private_section_data (ibfd, isec, obfd, osec,
- NULL);
-}
-
-/* Look at all the SHT_GROUP sections in IBFD, making any adjustments
- necessary if we are removing either the SHT_GROUP section or any of
- the group member sections. DISCARDED is the value that a section's
- output_section has if the section will be discarded, NULL when this
- function is called from objcopy, bfd_abs_section_ptr when called
- from the linker. */
-
-bool
-_bfd_elf_fixup_group_sections (bfd *ibfd, asection *discarded)
-{
- asection *isec;
-
- for (isec = ibfd->sections; isec != NULL; isec = isec->next)
- if (elf_section_type (isec) == SHT_GROUP)
- {
- asection *first = elf_next_in_group (isec);
- asection *s = first;
- bfd_size_type removed = 0;
-
- while (s != NULL)
- {
- /* If this member section is being output but the
- SHT_GROUP section is not, then clear the group info
- set up by _bfd_elf_copy_private_section_data. */
- if (s->output_section != discarded
- && isec->output_section == discarded)
- {
- elf_section_flags (s->output_section) &= ~SHF_GROUP;
- elf_group_name (s->output_section) = NULL;
- }
- else
- {
- struct bfd_elf_section_data *elf_sec = elf_section_data (s);
- if (s->output_section == discarded
- && isec->output_section != discarded)
- {
- /* Conversely, if the member section is not being
- output but the SHT_GROUP section is, then adjust
- its size. */
- removed += 4;
- if (elf_sec->rel.hdr != NULL
- && (elf_sec->rel.hdr->sh_flags & SHF_GROUP) != 0)
- removed += 4;
- if (elf_sec->rela.hdr != NULL
- && (elf_sec->rela.hdr->sh_flags & SHF_GROUP) != 0)
- removed += 4;
- }
- else
- {
- /* Also adjust for zero-sized relocation member
- section. */
- if (elf_sec->rel.hdr != NULL
- && elf_sec->rel.hdr->sh_size == 0)
- removed += 4;
- if (elf_sec->rela.hdr != NULL
- && elf_sec->rela.hdr->sh_size == 0)
- removed += 4;
- }
- }
- s = elf_next_in_group (s);
- if (s == first)
- break;
- }
- if (removed != 0)
- {
- if (discarded != NULL)
- {
- /* If we've been called for ld -r, then we need to
- adjust the input section size. */
- if (isec->rawsize == 0)
- isec->rawsize = isec->size;
- isec->size = isec->rawsize - removed;
- if (isec->size <= 4)
- {
- isec->size = 0;
- isec->flags |= SEC_EXCLUDE;
- }
- }
- else if (isec->output_section != NULL)
- {
- /* Adjust the output section size when called from
- objcopy. */
- isec->output_section->size -= removed;
- if (isec->output_section->size <= 4)
- {
- isec->output_section->size = 0;
- isec->output_section->flags |= SEC_EXCLUDE;
- }
- }
- }
- }
-
- return true;
-}
-
-/* Copy private header information. */
-
-bool
-_bfd_elf_copy_private_header_data (bfd *ibfd, bfd *obfd)
-{
- if (bfd_get_flavour (ibfd) != bfd_target_elf_flavour
- || bfd_get_flavour (obfd) != bfd_target_elf_flavour)
- return true;
-
- /* Copy over private BFD data if it has not already been copied.
- This must be done here, rather than in the copy_private_bfd_data
- entry point, because the latter is called after the section
- contents have been set, which means that the program headers have
- already been worked out. */
- if (elf_seg_map (obfd) == NULL && elf_tdata (ibfd)->phdr != NULL)
- {
- if (! copy_private_bfd_data (ibfd, obfd))
- return false;
- }
-
- return _bfd_elf_fixup_group_sections (ibfd, NULL);
-}
-
-/* Copy private symbol information. If this symbol is in a section
- which we did not map into a BFD section, try to map the section
- index correctly. We use special macro definitions for the mapped
- section indices; these definitions are interpreted by the
- swap_out_syms function. */
-
-#define MAP_ONESYMTAB (SHN_HIOS + 1)
-#define MAP_DYNSYMTAB (SHN_HIOS + 2)
-#define MAP_STRTAB (SHN_HIOS + 3)
-#define MAP_SHSTRTAB (SHN_HIOS + 4)
-#define MAP_SYM_SHNDX (SHN_HIOS + 5)
-
-bool
-_bfd_elf_copy_private_symbol_data (bfd *ibfd,
- asymbol *isymarg,
- bfd *obfd,
- asymbol *osymarg)
-{
- elf_symbol_type *isym, *osym;
-
- if (bfd_get_flavour (ibfd) != bfd_target_elf_flavour
- || bfd_get_flavour (obfd) != bfd_target_elf_flavour)
- return true;
-
- isym = elf_symbol_from (isymarg);
- osym = elf_symbol_from (osymarg);
-
- if (isym != NULL
- && isym->internal_elf_sym.st_shndx != 0
- && osym != NULL
- && bfd_is_abs_section (isym->symbol.section))
- {
- unsigned int shndx;
-
- shndx = isym->internal_elf_sym.st_shndx;
- if (shndx == elf_onesymtab (ibfd))
- shndx = MAP_ONESYMTAB;
- else if (shndx == elf_dynsymtab (ibfd))
- shndx = MAP_DYNSYMTAB;
- else if (shndx == elf_elfsections (ibfd)[elf_onesymtab (ibfd)]->sh_link)
- shndx = MAP_STRTAB;
- else if (shndx == elf_elfheader (ibfd)->e_shstrndx)
- shndx = MAP_SHSTRTAB;
- else if (find_section_in_list (shndx, elf_symtab_shndx_list (ibfd)))
- shndx = MAP_SYM_SHNDX;
- osym->internal_elf_sym.st_shndx = shndx;
- }
-
- return true;
-}
-
-/* Swap out the symbols. */
-
-static bool
-swap_out_syms (bfd *abfd,
- struct elf_strtab_hash **sttp,
- int relocatable_p,
- struct bfd_link_info *info)
-{
- const struct elf_backend_data *bed;
- unsigned int symcount;
- asymbol **syms;
- struct elf_strtab_hash *stt;
- Elf_Internal_Shdr *symtab_hdr;
- Elf_Internal_Shdr *symtab_shndx_hdr;
- Elf_Internal_Shdr *symstrtab_hdr;
- struct elf_sym_strtab *symstrtab;
- bfd_byte *outbound_syms;
- bfd_byte *outbound_shndx;
- unsigned long outbound_syms_index;
- unsigned int idx;
- unsigned int num_locals;
- size_t amt;
- bool name_local_sections;
-
- if (!elf_map_symbols (abfd, &num_locals))
- return false;
-
- /* Dump out the symtabs. */
- stt = _bfd_elf_strtab_init ();
- if (stt == NULL)
- return false;
-
- bed = get_elf_backend_data (abfd);
- symcount = bfd_get_symcount (abfd);
- symtab_hdr = &elf_tdata (abfd)->symtab_hdr;
- symtab_hdr->sh_type = SHT_SYMTAB;
- symtab_hdr->sh_entsize = bed->s->sizeof_sym;
- symtab_hdr->sh_size = symtab_hdr->sh_entsize * (symcount + 1);
- symtab_hdr->sh_info = num_locals + 1;
- symtab_hdr->sh_addralign = (bfd_vma) 1 << bed->s->log_file_align;
-
- symstrtab_hdr = &elf_tdata (abfd)->strtab_hdr;
- symstrtab_hdr->sh_type = SHT_STRTAB;
-
- /* Allocate buffer to swap out the .strtab section. */
- if (_bfd_mul_overflow (symcount + 1, sizeof (*symstrtab), &amt)
- || (symstrtab = (struct elf_sym_strtab *) bfd_malloc (amt)) == NULL)
- {
- bfd_set_error (bfd_error_no_memory);
- _bfd_elf_strtab_free (stt);
- return false;
- }
-
- if (_bfd_mul_overflow (symcount + 1, bed->s->sizeof_sym, &amt)
- || (outbound_syms = (bfd_byte *) bfd_alloc (abfd, amt)) == NULL)
- {
- error_no_mem:
- bfd_set_error (bfd_error_no_memory);
- error_return:
- free (symstrtab);
- _bfd_elf_strtab_free (stt);
- return false;
- }
- symtab_hdr->contents = outbound_syms;
- outbound_syms_index = 0;
-
- outbound_shndx = NULL;
-
- if (elf_symtab_shndx_list (abfd))
- {
- symtab_shndx_hdr = & elf_symtab_shndx_list (abfd)->hdr;
- if (symtab_shndx_hdr->sh_name != 0)
- {
- if (_bfd_mul_overflow (symcount + 1,
- sizeof (Elf_External_Sym_Shndx), &amt))
- goto error_no_mem;
- outbound_shndx = (bfd_byte *) bfd_zalloc (abfd, amt);
- if (outbound_shndx == NULL)
- goto error_return;
-
- symtab_shndx_hdr->contents = outbound_shndx;
- symtab_shndx_hdr->sh_type = SHT_SYMTAB_SHNDX;
- symtab_shndx_hdr->sh_size = amt;
- symtab_shndx_hdr->sh_addralign = sizeof (Elf_External_Sym_Shndx);
- symtab_shndx_hdr->sh_entsize = sizeof (Elf_External_Sym_Shndx);
- }
- /* FIXME: What about any other headers in the list ? */
- }
-
- /* Now generate the data (for "contents"). */
- {
- /* Fill in zeroth symbol and swap it out. */
- Elf_Internal_Sym sym;
- sym.st_name = 0;
- sym.st_value = 0;
- sym.st_size = 0;
- sym.st_info = 0;
- sym.st_other = 0;
- sym.st_shndx = SHN_UNDEF;
- sym.st_target_internal = 0;
- symstrtab[outbound_syms_index].sym = sym;
- symstrtab[outbound_syms_index].dest_index = outbound_syms_index;
- outbound_syms_index++;
- }
-
- name_local_sections
- = (bed->elf_backend_name_local_section_symbols
- && bed->elf_backend_name_local_section_symbols (abfd));
-
- syms = bfd_get_outsymbols (abfd);
- for (idx = 0; idx < symcount; idx++)
- {
- Elf_Internal_Sym sym;
-
- flagword flags = syms[idx]->flags;
- if (!name_local_sections
- && (flags & (BSF_SECTION_SYM | BSF_GLOBAL)) == BSF_SECTION_SYM)
- {
- /* Local section symbols have no name. */
- sym.st_name = (unsigned long) -1;
- }
- else
- {
- /* Call _bfd_elf_strtab_offset after _bfd_elf_strtab_finalize
- to get the final offset for st_name. */
- sym.st_name
- = (unsigned long) _bfd_elf_strtab_add (stt, syms[idx]->name,
- false);
- if (sym.st_name == (unsigned long) -1)
- goto error_return;
- }
-
- bfd_vma value = syms[idx]->value;
- elf_symbol_type *type_ptr = elf_symbol_from (syms[idx]);
- asection *sec = syms[idx]->section;
-
- if ((flags & BSF_SECTION_SYM) == 0 && bfd_is_com_section (sec))
- {
- /* ELF common symbols put the alignment into the `value' field,
- and the size into the `size' field. This is backwards from
- how BFD handles it, so reverse it here. */
- sym.st_size = value;
- if (type_ptr == NULL
- || type_ptr->internal_elf_sym.st_value == 0)
- sym.st_value = value >= 16 ? 16 : (1 << bfd_log2 (value));
- else
- sym.st_value = type_ptr->internal_elf_sym.st_value;
- sym.st_shndx = _bfd_elf_section_from_bfd_section (abfd, sec);
- }
- else
- {
- unsigned int shndx;
-
- if (sec->output_section)
- {
- value += sec->output_offset;
- sec = sec->output_section;
- }
-
- /* Don't add in the section vma for relocatable output. */
- if (! relocatable_p)
- value += sec->vma;
- sym.st_value = value;
- sym.st_size = type_ptr ? type_ptr->internal_elf_sym.st_size : 0;
-
- if (bfd_is_abs_section (sec)
- && type_ptr != NULL
- && type_ptr->internal_elf_sym.st_shndx != 0)
- {
- /* This symbol is in a real ELF section which we did
- not create as a BFD section. Undo the mapping done
- by copy_private_symbol_data. */
- shndx = type_ptr->internal_elf_sym.st_shndx;
- switch (shndx)
- {
- case MAP_ONESYMTAB:
- shndx = elf_onesymtab (abfd);
- break;
- case MAP_DYNSYMTAB:
- shndx = elf_dynsymtab (abfd);
- break;
- case MAP_STRTAB:
- shndx = elf_strtab_sec (abfd);
- break;
- case MAP_SHSTRTAB:
- shndx = elf_shstrtab_sec (abfd);
- break;
- case MAP_SYM_SHNDX:
- if (elf_symtab_shndx_list (abfd))
- shndx = elf_symtab_shndx_list (abfd)->ndx;
- break;
- case SHN_COMMON:
- case SHN_ABS:
- shndx = SHN_ABS;
- break;
- default:
- if (shndx >= SHN_LOPROC && shndx <= SHN_HIOS)
- {
- if (bed->symbol_section_index)
- shndx = bed->symbol_section_index (abfd, type_ptr);
- /* Otherwise just leave the index alone. */
- }
- else
- {
- if (shndx > SHN_HIOS && shndx < SHN_HIRESERVE)
- _bfd_error_handler (_("%pB: \
-Unable to handle section index %x in ELF symbol. Using ABS instead."),
- abfd, shndx);
- shndx = SHN_ABS;
- }
- break;
- }
- }
- else
- {
- shndx = _bfd_elf_section_from_bfd_section (abfd, sec);
-
- if (shndx == SHN_BAD)
- {
- asection *sec2;
-
- /* Writing this would be a hell of a lot easier if
- we had some decent documentation on bfd, and
- knew what to expect of the library, and what to
- demand of applications. For example, it
- appears that `objcopy' might not set the
- section of a symbol to be a section that is
- actually in the output file. */
- sec2 = bfd_get_section_by_name (abfd, sec->name);
- if (sec2 != NULL)
- shndx = _bfd_elf_section_from_bfd_section (abfd, sec2);
- if (shndx == SHN_BAD)
- {
- /* xgettext:c-format */
- _bfd_error_handler
- (_("unable to find equivalent output section"
- " for symbol '%s' from section '%s'"),
- syms[idx]->name ? syms[idx]->name : "<Local sym>",
- sec->name);
- bfd_set_error (bfd_error_invalid_operation);
- goto error_return;
- }
- }
- }
-
- sym.st_shndx = shndx;
- }
-
- int type;
- if ((flags & BSF_THREAD_LOCAL) != 0)
- type = STT_TLS;
- else if ((flags & BSF_GNU_INDIRECT_FUNCTION) != 0)
- type = STT_GNU_IFUNC;
- else if ((flags & BSF_FUNCTION) != 0)
- type = STT_FUNC;
- else if ((flags & BSF_OBJECT) != 0)
- type = STT_OBJECT;
- else if ((flags & BSF_RELC) != 0)
- type = STT_RELC;
- else if ((flags & BSF_SRELC) != 0)
- type = STT_SRELC;
- else
- type = STT_NOTYPE;
-
- if (syms[idx]->section->flags & SEC_THREAD_LOCAL)
- type = STT_TLS;
-
- /* Processor-specific types. */
- if (type_ptr != NULL
- && bed->elf_backend_get_symbol_type)
- type = ((*bed->elf_backend_get_symbol_type)
- (&type_ptr->internal_elf_sym, type));
-
- if (flags & BSF_SECTION_SYM)
- {
- if (flags & BSF_GLOBAL)
- sym.st_info = ELF_ST_INFO (STB_GLOBAL, STT_SECTION);
- else
- sym.st_info = ELF_ST_INFO (STB_LOCAL, STT_SECTION);
- }
- else if (bfd_is_com_section (syms[idx]->section))
- {
- if (type != STT_TLS)
- {
- if ((abfd->flags & BFD_CONVERT_ELF_COMMON))
- type = ((abfd->flags & BFD_USE_ELF_STT_COMMON)
- ? STT_COMMON : STT_OBJECT);
- else
- type = ((flags & BSF_ELF_COMMON) != 0
- ? STT_COMMON : STT_OBJECT);
- }
- sym.st_info = ELF_ST_INFO (STB_GLOBAL, type);
- }
- else if (bfd_is_und_section (syms[idx]->section))
- sym.st_info = ELF_ST_INFO (((flags & BSF_WEAK)
- ? STB_WEAK
- : STB_GLOBAL),
- type);
- else if (flags & BSF_FILE)
- sym.st_info = ELF_ST_INFO (STB_LOCAL, STT_FILE);
- else
- {
- int bind = STB_LOCAL;
-
- if (flags & BSF_LOCAL)
- bind = STB_LOCAL;
- else if (flags & BSF_GNU_UNIQUE)
- bind = STB_GNU_UNIQUE;
- else if (flags & BSF_WEAK)
- bind = STB_WEAK;
- else if (flags & BSF_GLOBAL)
- bind = STB_GLOBAL;
-
- sym.st_info = ELF_ST_INFO (bind, type);
- }
-
- if (type_ptr != NULL)
- {
- sym.st_other = type_ptr->internal_elf_sym.st_other;
- sym.st_target_internal
- = type_ptr->internal_elf_sym.st_target_internal;
- }
- else
- {
- sym.st_other = 0;
- sym.st_target_internal = 0;
- }
-
- symstrtab[outbound_syms_index].sym = sym;
- symstrtab[outbound_syms_index].dest_index = outbound_syms_index;
- outbound_syms_index++;
- }
-
- /* Finalize the .strtab section. */
- _bfd_elf_strtab_finalize (stt);
-
- /* Swap out the .strtab section. */
- for (idx = 0; idx < outbound_syms_index; idx++)
- {
- struct elf_sym_strtab *elfsym = &symstrtab[idx];
- if (elfsym->sym.st_name == (unsigned long) -1)
- elfsym->sym.st_name = 0;
- else
- elfsym->sym.st_name = _bfd_elf_strtab_offset (stt,
- elfsym->sym.st_name);
- if (info && info->callbacks->ctf_new_symbol)
- info->callbacks->ctf_new_symbol (elfsym->dest_index,
- &elfsym->sym);
-
- /* Inform the linker of the addition of this symbol. */
-
- bed->s->swap_symbol_out (abfd, &elfsym->sym,
- (outbound_syms
- + (elfsym->dest_index
- * bed->s->sizeof_sym)),
- NPTR_ADD (outbound_shndx,
- (elfsym->dest_index
- * sizeof (Elf_External_Sym_Shndx))));
- }
- free (symstrtab);
-
- *sttp = stt;
- symstrtab_hdr->sh_size = _bfd_elf_strtab_size (stt);
- symstrtab_hdr->sh_type = SHT_STRTAB;
- symstrtab_hdr->sh_flags = bed->elf_strtab_flags;
- symstrtab_hdr->sh_addr = 0;
- symstrtab_hdr->sh_entsize = 0;
- symstrtab_hdr->sh_link = 0;
- symstrtab_hdr->sh_info = 0;
- symstrtab_hdr->sh_addralign = 1;
-
- return true;
-}
-
-/* Return the number of bytes required to hold the symtab vector.
-
- Note that we base it on the count plus 1, since we will null terminate
- the vector allocated based on this size. However, the ELF symbol table
- always has a dummy entry as symbol #0, so it ends up even. */
-
-long
-_bfd_elf_get_symtab_upper_bound (bfd *abfd)
-{
- bfd_size_type symcount;
- long symtab_size;
- Elf_Internal_Shdr *hdr = &elf_tdata (abfd)->symtab_hdr;
-
- symcount = hdr->sh_size / get_elf_backend_data (abfd)->s->sizeof_sym;
- if (symcount > LONG_MAX / sizeof (asymbol *))
- {
- bfd_set_error (bfd_error_file_too_big);
- return -1;
- }
- symtab_size = symcount * (sizeof (asymbol *));
- if (symcount == 0)
- symtab_size = sizeof (asymbol *);
- else if (!bfd_write_p (abfd))
- {
- ufile_ptr filesize = bfd_get_file_size (abfd);
-
- if (filesize != 0 && (unsigned long) symtab_size > filesize)
- {
- bfd_set_error (bfd_error_file_truncated);
- return -1;
- }
- }
-
- return symtab_size;
-}
-
-long
-_bfd_elf_get_dynamic_symtab_upper_bound (bfd *abfd)
-{
- bfd_size_type symcount;
- long symtab_size;
- Elf_Internal_Shdr *hdr = &elf_tdata (abfd)->dynsymtab_hdr;
-
- if (elf_dynsymtab (abfd) == 0)
- {
- /* Check if there is dynamic symbol table. */
- symcount = elf_tdata (abfd)->dt_symtab_count;
- if (symcount)
- goto compute_symtab_size;
-
- bfd_set_error (bfd_error_invalid_operation);
- return -1;
- }
-
- symcount = hdr->sh_size / get_elf_backend_data (abfd)->s->sizeof_sym;
- if (symcount > LONG_MAX / sizeof (asymbol *))
- {
- bfd_set_error (bfd_error_file_too_big);
- return -1;
- }
-
- compute_symtab_size:
- symtab_size = symcount * (sizeof (asymbol *));
- if (symcount == 0)
- symtab_size = sizeof (asymbol *);
- else if (!bfd_write_p (abfd))
- {
- ufile_ptr filesize = bfd_get_file_size (abfd);
-
- if (filesize != 0 && (unsigned long) symtab_size > filesize)
- {
- bfd_set_error (bfd_error_file_truncated);
- return -1;
- }
- }
-
- return symtab_size;
-}
-
-long
-_bfd_elf_get_reloc_upper_bound (bfd *abfd, sec_ptr asect)
-{
- if (asect->reloc_count != 0 && !bfd_write_p (abfd))
- {
- /* Sanity check reloc section size. */
- ufile_ptr filesize = bfd_get_file_size (abfd);
-
- if (filesize != 0)
- {
- struct bfd_elf_section_data *d = elf_section_data (asect);
- bfd_size_type rel_size = d->rel.hdr ? d->rel.hdr->sh_size : 0;
- bfd_size_type rela_size = d->rela.hdr ? d->rela.hdr->sh_size : 0;
-
- if (rel_size + rela_size > filesize
- || rel_size + rela_size < rel_size)
- {
- bfd_set_error (bfd_error_file_truncated);
- return -1;
- }
- }
- }
-
-#if SIZEOF_LONG == SIZEOF_INT
- if (asect->reloc_count >= LONG_MAX / sizeof (arelent *))
- {
- bfd_set_error (bfd_error_file_too_big);
- return -1;
- }
-#endif
- return (asect->reloc_count + 1L) * sizeof (arelent *);
-}
-
-/* Canonicalize the relocs. */
-
-long
-_bfd_elf_canonicalize_reloc (bfd *abfd,
- sec_ptr section,
- arelent **relptr,
- asymbol **symbols)
-{
- arelent *tblptr;
- unsigned int i;
- const struct elf_backend_data *bed = get_elf_backend_data (abfd);
-
- if (! bed->s->slurp_reloc_table (abfd, section, symbols, false))
- return -1;
-
- tblptr = section->relocation;
- for (i = 0; i < section->reloc_count; i++)
- *relptr++ = tblptr++;
-
- *relptr = NULL;
-
- return section->reloc_count;
-}
-
-long
-_bfd_elf_canonicalize_symtab (bfd *abfd, asymbol **allocation)
-{
- const struct elf_backend_data *bed = get_elf_backend_data (abfd);
- long symcount = bed->s->slurp_symbol_table (abfd, allocation, false);
-
- if (symcount >= 0)
- abfd->symcount = symcount;
- return symcount;
-}
-
-long
-_bfd_elf_canonicalize_dynamic_symtab (bfd *abfd,
- asymbol **allocation)
-{
- const struct elf_backend_data *bed = get_elf_backend_data (abfd);
- long symcount = bed->s->slurp_symbol_table (abfd, allocation, true);
-
- if (symcount >= 0)
- abfd->dynsymcount = symcount;
- return symcount;
-}
-
-/* Return the size required for the dynamic reloc entries. Any loadable
- section that was actually installed in the BFD, and has type SHT_REL
- or SHT_RELA, and uses the dynamic symbol table, is considered to be a
- dynamic reloc section. */
-
-long
-_bfd_elf_get_dynamic_reloc_upper_bound (bfd *abfd)
-{
- bfd_size_type count, ext_rel_size;
- asection *s;
-
- if (elf_dynsymtab (abfd) == 0)
- {
- bfd_set_error (bfd_error_invalid_operation);
- return -1;
- }
-
- count = 1;
- ext_rel_size = 0;
- for (s = abfd->sections; s != NULL; s = s->next)
- if (elf_section_data (s)->this_hdr.sh_link == elf_dynsymtab (abfd)
- && (elf_section_data (s)->this_hdr.sh_type == SHT_REL
- || elf_section_data (s)->this_hdr.sh_type == SHT_RELA)
- && (elf_section_data (s)->this_hdr.sh_flags & SHF_COMPRESSED) == 0)
- {
- ext_rel_size += elf_section_data (s)->this_hdr.sh_size;
- if (ext_rel_size < elf_section_data (s)->this_hdr.sh_size)
- {
- bfd_set_error (bfd_error_file_truncated);
- return -1;
- }
- count += NUM_SHDR_ENTRIES (&elf_section_data (s)->this_hdr);
- if (count > LONG_MAX / sizeof (arelent *))
- {
- bfd_set_error (bfd_error_file_too_big);
- return -1;
- }
- }
- if (count > 1 && !bfd_write_p (abfd))
- {
- /* Sanity check reloc section sizes. */
- ufile_ptr filesize = bfd_get_file_size (abfd);
- if (filesize != 0 && ext_rel_size > filesize)
- {
- bfd_set_error (bfd_error_file_truncated);
- return -1;
- }
- }
- return count * sizeof (arelent *);
-}
-
-/* Canonicalize the dynamic relocation entries. Note that we return the
- dynamic relocations as a single block, although they are actually
- associated with particular sections; the interface, which was
- designed for SunOS style shared libraries, expects that there is only
- one set of dynamic relocs. Any loadable section that was actually
- installed in the BFD, and has type SHT_REL or SHT_RELA, and uses the
- dynamic symbol table, is considered to be a dynamic reloc section. */
-
-long
-_bfd_elf_canonicalize_dynamic_reloc (bfd *abfd,
- arelent **storage,
- asymbol **syms)
-{
- bool (*slurp_relocs) (bfd *, asection *, asymbol **, bool);
- asection *s;
- long ret;
-
- if (elf_dynsymtab (abfd) == 0)
- {
- bfd_set_error (bfd_error_invalid_operation);
- return -1;
- }
-
- slurp_relocs = get_elf_backend_data (abfd)->s->slurp_reloc_table;
- ret = 0;
- for (s = abfd->sections; s != NULL; s = s->next)
- {
- if (elf_section_data (s)->this_hdr.sh_link == elf_dynsymtab (abfd)
- && (elf_section_data (s)->this_hdr.sh_type == SHT_REL
- || elf_section_data (s)->this_hdr.sh_type == SHT_RELA)
- && (elf_section_data (s)->this_hdr.sh_flags & SHF_COMPRESSED) == 0)
- {
- arelent *p;
- long count, i;
-
- if (! (*slurp_relocs) (abfd, s, syms, true))
- return -1;
- count = NUM_SHDR_ENTRIES (&elf_section_data (s)->this_hdr);
- p = s->relocation;
- for (i = 0; i < count; i++)
- *storage++ = p++;
- ret += count;
- }
- }
-
- *storage = NULL;
-
- return ret;
-}
-
-/* Read in the version information. */
-
-bool
-_bfd_elf_slurp_version_tables (bfd *abfd, bool default_imported_symver)
-{
- bfd_byte *contents = NULL;
- unsigned int freeidx = 0;
- size_t amt;
- void *contents_addr = NULL;
- size_t contents_size = 0;
-
- if (elf_dynverref (abfd) != 0 || elf_tdata (abfd)->dt_verneed != NULL)
- {
- Elf_Internal_Shdr *hdr;
- Elf_External_Verneed *everneed;
- Elf_Internal_Verneed *iverneed;
- unsigned int i;
- bfd_byte *contents_end;
- size_t verneed_count;
- size_t verneed_size;
-
- if (elf_tdata (abfd)->dt_verneed != NULL)
- {
- hdr = NULL;
- contents = elf_tdata (abfd)->dt_verneed;
- verneed_count = elf_tdata (abfd)->dt_verneed_count;
- verneed_size = verneed_count * sizeof (Elf_External_Verneed);
- }
- else
- {
- hdr = &elf_tdata (abfd)->dynverref_hdr;
-
- if (hdr->sh_info > hdr->sh_size / sizeof (Elf_External_Verneed))
- {
- error_return_bad_verref:
- _bfd_error_handler
- (_("%pB: .gnu.version_r invalid entry"), abfd);
- bfd_set_error (bfd_error_bad_value);
- error_return_verref:
- elf_tdata (abfd)->verref = NULL;
- elf_tdata (abfd)->cverrefs = 0;
- goto error_return;
- }
-
- if (bfd_seek (abfd, hdr->sh_offset, SEEK_SET) != 0)
- goto error_return_verref;
- contents_size = hdr->sh_size;
- contents = _bfd_mmap_readonly_temporary (abfd, contents_size,
- &contents_addr,
- &contents_size);
- if (contents == NULL)
- goto error_return_verref;
-
- verneed_size = hdr->sh_size;
- verneed_count = hdr->sh_info;
- }
-
- if (_bfd_mul_overflow (verneed_count,
- sizeof (Elf_Internal_Verneed), &amt))
- {
- bfd_set_error (bfd_error_file_too_big);
- goto error_return_verref;
- }
- if (amt == 0)
- goto error_return_verref;
- elf_tdata (abfd)->verref = (Elf_Internal_Verneed *) bfd_zalloc (abfd, amt);
- if (elf_tdata (abfd)->verref == NULL)
- goto error_return_verref;
-
- BFD_ASSERT (sizeof (Elf_External_Verneed)
- == sizeof (Elf_External_Vernaux));
- contents_end = (contents + verneed_size
- - sizeof (Elf_External_Verneed));
- everneed = (Elf_External_Verneed *) contents;
- iverneed = elf_tdata (abfd)->verref;
- for (i = 0; i < verneed_count; i++, iverneed++)
- {
- Elf_External_Vernaux *evernaux;
- Elf_Internal_Vernaux *ivernaux;
- unsigned int j;
-
- _bfd_elf_swap_verneed_in (abfd, everneed, iverneed);
-
- iverneed->vn_bfd = abfd;
-
- if (elf_use_dt_symtab_p (abfd))
- {
- if (iverneed->vn_file < elf_tdata (abfd)->dt_strsz)
- iverneed->vn_filename
- = elf_tdata (abfd)->dt_strtab + iverneed->vn_file;
- else
- iverneed->vn_filename = NULL;
- }
- else if (hdr == NULL)
- goto error_return_bad_verref;
- else
- iverneed->vn_filename
- = bfd_elf_string_from_elf_section (abfd, hdr->sh_link,
- iverneed->vn_file);
- if (iverneed->vn_filename == NULL)
- goto error_return_bad_verref;
-
- if (iverneed->vn_cnt == 0)
- iverneed->vn_auxptr = NULL;
- else
- {
- if (_bfd_mul_overflow (iverneed->vn_cnt,
- sizeof (Elf_Internal_Vernaux), &amt))
- {
- bfd_set_error (bfd_error_file_too_big);
- goto error_return_verref;
- }
- iverneed->vn_auxptr = (struct elf_internal_vernaux *)
- bfd_alloc (abfd, amt);
- if (iverneed->vn_auxptr == NULL)
- goto error_return_verref;
- }
-
- if (iverneed->vn_aux
- > (size_t) (contents_end - (bfd_byte *) everneed))
- goto error_return_bad_verref;
-
- evernaux = ((Elf_External_Vernaux *)
- ((bfd_byte *) everneed + iverneed->vn_aux));
- ivernaux = iverneed->vn_auxptr;
- for (j = 0; j < iverneed->vn_cnt; j++, ivernaux++)
- {
- _bfd_elf_swap_vernaux_in (abfd, evernaux, ivernaux);
-
- if (elf_use_dt_symtab_p (abfd))
- {
- if (ivernaux->vna_name < elf_tdata (abfd)->dt_strsz)
- ivernaux->vna_nodename
- = elf_tdata (abfd)->dt_strtab + ivernaux->vna_name;
- else
- ivernaux->vna_nodename = NULL;
- }
- else if (hdr == NULL)
- goto error_return_bad_verref;
- else
- ivernaux->vna_nodename
- = bfd_elf_string_from_elf_section (abfd, hdr->sh_link,
- ivernaux->vna_name);
- if (ivernaux->vna_nodename == NULL)
- goto error_return_bad_verref;
-
- if (ivernaux->vna_other > freeidx)
- freeidx = ivernaux->vna_other;
-
- ivernaux->vna_nextptr = NULL;
- if (ivernaux->vna_next == 0)
- {
- iverneed->vn_cnt = j + 1;
- break;
- }
- if (j + 1 < iverneed->vn_cnt)
- ivernaux->vna_nextptr = ivernaux + 1;
-
- if (ivernaux->vna_next
- > (size_t) (contents_end - (bfd_byte *) evernaux))
- goto error_return_bad_verref;
-
- evernaux = ((Elf_External_Vernaux *)
- ((bfd_byte *) evernaux + ivernaux->vna_next));
- }
-
- iverneed->vn_nextref = NULL;
- if (iverneed->vn_next == 0)
- break;
- if (hdr != NULL && (i + 1 < hdr->sh_info))
- iverneed->vn_nextref = iverneed + 1;
-
- if (iverneed->vn_next
- > (size_t) (contents_end - (bfd_byte *) everneed))
- goto error_return_bad_verref;
-
- everneed = ((Elf_External_Verneed *)
- ((bfd_byte *) everneed + iverneed->vn_next));
- }
- elf_tdata (abfd)->cverrefs = i;
-
- if (contents != elf_tdata (abfd)->dt_verneed)
- _bfd_munmap_readonly_temporary (contents_addr, contents_size);
- contents = NULL;
- contents_addr = NULL;
- }
-
- if (elf_dynverdef (abfd) != 0 || elf_tdata (abfd)->dt_verdef != NULL)
- {
- Elf_Internal_Shdr *hdr;
- Elf_External_Verdef *everdef;
- Elf_Internal_Verdef *iverdef;
- Elf_Internal_Verdef *iverdefarr;
- Elf_Internal_Verdef iverdefmem;
- unsigned int i;
- unsigned int maxidx;
- bfd_byte *contents_end_def, *contents_end_aux;
- size_t verdef_count;
- size_t verdef_size;
-
- if (elf_tdata (abfd)->dt_verdef != NULL)
- {
- hdr = NULL;
- contents = elf_tdata (abfd)->dt_verdef;
- verdef_count = elf_tdata (abfd)->dt_verdef_count;
- verdef_size = verdef_count * sizeof (Elf_External_Verdef);
- }
- else
- {
- hdr = &elf_tdata (abfd)->dynverdef_hdr;
-
- if (hdr->sh_size < sizeof (Elf_External_Verdef))
- {
- error_return_bad_verdef:
- _bfd_error_handler
- (_("%pB: .gnu.version_d invalid entry"), abfd);
- bfd_set_error (bfd_error_bad_value);
- error_return_verdef:
- elf_tdata (abfd)->verdef = NULL;
- elf_tdata (abfd)->cverdefs = 0;
- goto error_return;
- }
-
- if (bfd_seek (abfd, hdr->sh_offset, SEEK_SET) != 0)
- goto error_return_verdef;
- contents_size = hdr->sh_size;
- contents = _bfd_mmap_readonly_temporary (abfd, contents_size,
- &contents_addr,
- &contents_size);
- if (contents == NULL)
- goto error_return_verdef;
-
- BFD_ASSERT (sizeof (Elf_External_Verdef)
- >= sizeof (Elf_External_Verdaux));
-
- verdef_count = hdr->sh_info;
- verdef_size = hdr->sh_size;
- }
-
- contents_end_def = (contents + verdef_size
- - sizeof (Elf_External_Verdef));
- contents_end_aux = (contents + verdef_size
- - sizeof (Elf_External_Verdaux));
-
- /* We know the number of entries in the section but not the maximum
- index. Therefore we have to run through all entries and find
- the maximum. */
- everdef = (Elf_External_Verdef *) contents;
- maxidx = 0;
- for (i = 0; i < verdef_count; ++i)
- {
- _bfd_elf_swap_verdef_in (abfd, everdef, &iverdefmem);
-
- if ((iverdefmem.vd_ndx & ((unsigned) VERSYM_VERSION)) == 0)
- goto error_return_bad_verdef;
- if ((iverdefmem.vd_ndx & ((unsigned) VERSYM_VERSION)) > maxidx)
- maxidx = iverdefmem.vd_ndx & ((unsigned) VERSYM_VERSION);
-
- if (iverdefmem.vd_next == 0)
- break;
-
- if (iverdefmem.vd_next
- > (size_t) (contents_end_def - (bfd_byte *) everdef))
- goto error_return_bad_verdef;
-
- everdef = ((Elf_External_Verdef *)
- ((bfd_byte *) everdef + iverdefmem.vd_next));
- }
-
- if (default_imported_symver)
- {
- if (freeidx > maxidx)
- maxidx = ++freeidx;
- else
- freeidx = ++maxidx;
- }
- if (_bfd_mul_overflow (maxidx, sizeof (Elf_Internal_Verdef), &amt))
- {
- bfd_set_error (bfd_error_file_too_big);
- goto error_return_verdef;
- }
-
- if (amt == 0)
- goto error_return_verdef;
- elf_tdata (abfd)->verdef = (Elf_Internal_Verdef *) bfd_zalloc (abfd, amt);
- if (elf_tdata (abfd)->verdef == NULL)
- goto error_return_verdef;
-
- elf_tdata (abfd)->cverdefs = maxidx;
-
- everdef = (Elf_External_Verdef *) contents;
- iverdefarr = elf_tdata (abfd)->verdef;
- for (i = 0; i < verdef_count; ++i)
- {
- Elf_External_Verdaux *everdaux;
- Elf_Internal_Verdaux *iverdaux;
- unsigned int j;
-
- _bfd_elf_swap_verdef_in (abfd, everdef, &iverdefmem);
-
- if ((iverdefmem.vd_ndx & VERSYM_VERSION) == 0)
- goto error_return_bad_verdef;
-
- iverdef = &iverdefarr[(iverdefmem.vd_ndx & VERSYM_VERSION) - 1];
- memcpy (iverdef, &iverdefmem, offsetof (Elf_Internal_Verdef, vd_bfd));
-
- iverdef->vd_bfd = abfd;
-
- if (iverdef->vd_cnt == 0)
- iverdef->vd_auxptr = NULL;
- else
- {
- if (_bfd_mul_overflow (iverdef->vd_cnt,
- sizeof (Elf_Internal_Verdaux), &amt))
- {
- bfd_set_error (bfd_error_file_too_big);
- goto error_return_verdef;
- }
- iverdef->vd_auxptr = (struct elf_internal_verdaux *)
- bfd_alloc (abfd, amt);
- if (iverdef->vd_auxptr == NULL)
- goto error_return_verdef;
- }
-
- if (iverdef->vd_aux
- > (size_t) (contents_end_aux - (bfd_byte *) everdef))
- goto error_return_bad_verdef;
-
- everdaux = ((Elf_External_Verdaux *)
- ((bfd_byte *) everdef + iverdef->vd_aux));
- iverdaux = iverdef->vd_auxptr;
- for (j = 0; j < iverdef->vd_cnt; j++, iverdaux++)
- {
- _bfd_elf_swap_verdaux_in (abfd, everdaux, iverdaux);
-
- if (elf_use_dt_symtab_p (abfd))
- {
- if (iverdaux->vda_name < elf_tdata (abfd)->dt_strsz)
- iverdaux->vda_nodename
- = elf_tdata (abfd)->dt_strtab + iverdaux->vda_name;
- else
- iverdaux->vda_nodename = NULL;
- }
- else
- iverdaux->vda_nodename
- = bfd_elf_string_from_elf_section (abfd, hdr->sh_link,
- iverdaux->vda_name);
- if (iverdaux->vda_nodename == NULL)
- goto error_return_bad_verdef;
-
- iverdaux->vda_nextptr = NULL;
- if (iverdaux->vda_next == 0)
- {
- iverdef->vd_cnt = j + 1;
- break;
- }
- if (j + 1 < iverdef->vd_cnt)
- iverdaux->vda_nextptr = iverdaux + 1;
-
- if (iverdaux->vda_next
- > (size_t) (contents_end_aux - (bfd_byte *) everdaux))
- goto error_return_bad_verdef;
-
- everdaux = ((Elf_External_Verdaux *)
- ((bfd_byte *) everdaux + iverdaux->vda_next));
- }
-
- iverdef->vd_nodename = NULL;
- if (iverdef->vd_cnt)
- iverdef->vd_nodename = iverdef->vd_auxptr->vda_nodename;
-
- iverdef->vd_nextdef = NULL;
- if (iverdef->vd_next == 0)
- break;
- if ((size_t) (iverdef - iverdefarr) + 1 < maxidx)
- iverdef->vd_nextdef = iverdef + 1;
-
- everdef = ((Elf_External_Verdef *)
- ((bfd_byte *) everdef + iverdef->vd_next));
- }
-
- if (contents != elf_tdata (abfd)->dt_verdef)
- _bfd_munmap_readonly_temporary (contents_addr, contents_size);
- contents = NULL;
- contents_addr = NULL;
- }
- else if (default_imported_symver)
- {
- if (freeidx < 3)
- freeidx = 3;
- else
- freeidx++;
-
- if (_bfd_mul_overflow (freeidx, sizeof (Elf_Internal_Verdef), &amt))
- {
- bfd_set_error (bfd_error_file_too_big);
- goto error_return;
- }
- if (amt == 0)
- goto error_return;
- elf_tdata (abfd)->verdef = (Elf_Internal_Verdef *) bfd_zalloc (abfd, amt);
- if (elf_tdata (abfd)->verdef == NULL)
- goto error_return;
-
- elf_tdata (abfd)->cverdefs = freeidx;
- }
-
- /* Create a default version based on the soname. */
- if (default_imported_symver)
- {
- Elf_Internal_Verdef *iverdef;
- Elf_Internal_Verdaux *iverdaux;
-
- iverdef = &elf_tdata (abfd)->verdef[freeidx - 1];
-
- iverdef->vd_version = VER_DEF_CURRENT;
- iverdef->vd_flags = 0;
- iverdef->vd_ndx = freeidx;
- iverdef->vd_cnt = 1;
-
- iverdef->vd_bfd = abfd;
-
- iverdef->vd_nodename = bfd_elf_get_dt_soname (abfd);
- if (iverdef->vd_nodename == NULL)
- goto error_return_verdef;
- iverdef->vd_nextdef = NULL;
- iverdef->vd_auxptr = ((struct elf_internal_verdaux *)
- bfd_zalloc (abfd, sizeof (Elf_Internal_Verdaux)));
- if (iverdef->vd_auxptr == NULL)
- goto error_return_verdef;
-
- iverdaux = iverdef->vd_auxptr;
- iverdaux->vda_nodename = iverdef->vd_nodename;
- }
-
- return true;
-
- error_return:
- if (contents != elf_tdata (abfd)->dt_verneed
- && contents != elf_tdata (abfd)->dt_verdef)
- _bfd_munmap_readonly_temporary (contents_addr, contents_size);
- return false;
-}
-
-asymbol *
-_bfd_elf_make_empty_symbol (bfd *abfd)
-{
- elf_symbol_type *newsym;
-
- newsym = (elf_symbol_type *) bfd_zalloc (abfd, sizeof (*newsym));
- if (!newsym)
- return NULL;
- newsym->symbol.the_bfd = abfd;
- return &newsym->symbol;
-}
-
-void
-_bfd_elf_get_symbol_info (bfd *abfd ATTRIBUTE_UNUSED,
- asymbol *symbol,
- symbol_info *ret)
-{
- bfd_symbol_info (symbol, ret);
-}
-
-/* Return whether a symbol name implies a local symbol. Most targets
- use this function for the is_local_label_name entry point, but some
- override it. */
-
-bool
-_bfd_elf_is_local_label_name (bfd *abfd ATTRIBUTE_UNUSED,
- const char *name)
-{
- /* Normal local symbols start with ``.L''. */
- if (name[0] == '.' && name[1] == 'L')
- return true;
-
- /* At least some SVR4 compilers (e.g., UnixWare 2.1 cc) generate
- DWARF debugging symbols starting with ``..''. */
- if (name[0] == '.' && name[1] == '.')
- return true;
-
- /* gcc will sometimes generate symbols beginning with ``_.L_'' when
- emitting DWARF debugging output. I suspect this is actually a
- small bug in gcc (it calls ASM_OUTPUT_LABEL when it should call
- ASM_GENERATE_INTERNAL_LABEL, and this causes the leading
- underscore to be emitted on some ELF targets). For ease of use,
- we treat such symbols as local. */
- if (name[0] == '_' && name[1] == '.' && name[2] == 'L' && name[3] == '_')
- return true;
-
- /* Treat assembler generated fake symbols, dollar local labels and
- forward-backward labels (aka local labels) as locals.
- These labels have the form:
-
- L0^A.* (fake symbols)
-
- [.]?L[0123456789]+{^A|^B}[0123456789]* (local labels)
-
- Versions which start with .L will have already been matched above,
- so we only need to match the rest. */
- if (name[0] == 'L' && ISDIGIT (name[1]))
- {
- bool ret = false;
- const char * p;
- char c;
-
- for (p = name + 2; (c = *p); p++)
- {
- if (c == 1 || c == 2)
- {
- if (c == 1 && p == name + 2)
- /* A fake symbol. */
- return true;
-
- /* FIXME: We are being paranoid here and treating symbols like
- L0^Bfoo as if there were non-local, on the grounds that the
- assembler will never generate them. But can any symbol
- containing an ASCII value in the range 1-31 ever be anything
- other than some kind of local ? */
- ret = true;
- }
-
- if (! ISDIGIT (c))
- {
- ret = false;
- break;
- }
- }
- return ret;
- }
-
- return false;
-}
-
-alent *
-_bfd_elf_get_lineno (bfd *abfd ATTRIBUTE_UNUSED,
- asymbol *symbol ATTRIBUTE_UNUSED)
-{
- abort ();
- return NULL;
-}
-
-bool
-_bfd_elf_set_arch_mach (bfd *abfd,
- enum bfd_architecture arch,
- unsigned long machine)
-{
- /* If this isn't the right architecture for this backend, and this
- isn't the generic backend, fail. */
- if (arch != get_elf_backend_data (abfd)->arch
- && arch != bfd_arch_unknown
- && get_elf_backend_data (abfd)->arch != bfd_arch_unknown)
- return false;
-
- return bfd_default_set_arch_mach (abfd, arch, machine);
-}
-
-/* Find the nearest line to a particular section and offset,
- for error reporting. */
-
-bool
-_bfd_elf_find_nearest_line (bfd *abfd,
- asymbol **symbols,
- asection *section,
- bfd_vma offset,
- const char **filename_ptr,
- const char **functionname_ptr,
- unsigned int *line_ptr,
- unsigned int *discriminator_ptr)
-{
- return _bfd_elf_find_nearest_line_with_alt (abfd, NULL, symbols, section,
- offset, filename_ptr,
- functionname_ptr, line_ptr,
- discriminator_ptr);
-}
-
-/* Find the nearest line to a particular section and offset,
- for error reporting. ALT_BFD representing a .gnu_debugaltlink file
- can be optionally specified. */
-
-bool
-_bfd_elf_find_nearest_line_with_alt (bfd *abfd,
- const char *alt_filename,
- asymbol **symbols,
- asection *section,
- bfd_vma offset,
- const char **filename_ptr,
- const char **functionname_ptr,
- unsigned int *line_ptr,
- unsigned int *discriminator_ptr)
-{
- bool found;
-
- if (_bfd_dwarf2_find_nearest_line_with_alt (abfd, alt_filename, symbols, NULL,
- section, offset, filename_ptr,
- functionname_ptr, line_ptr,
- discriminator_ptr,
- dwarf_debug_sections,
- &elf_tdata (abfd)->dwarf2_find_line_info))
- return true;
-
- if (_bfd_dwarf1_find_nearest_line (abfd, symbols, section, offset,
- filename_ptr, functionname_ptr, line_ptr))
- {
- if (!*functionname_ptr)
- _bfd_elf_find_function (abfd, symbols, section, offset,
- *filename_ptr ? NULL : filename_ptr,
- functionname_ptr);
- return true;
- }
-
- if (! _bfd_stab_section_find_nearest_line (abfd, symbols, section, offset,
- &found, filename_ptr,
- functionname_ptr, line_ptr,
- &elf_tdata (abfd)->line_info))
- return false;
- if (found && (*functionname_ptr || *line_ptr))
- return true;
-
- if (symbols == NULL)
- return false;
-
- if (! _bfd_elf_find_function (abfd, symbols, section, offset,
- filename_ptr, functionname_ptr))
- return false;
-
- *line_ptr = 0;
- return true;
-}
-
-/* Find the line for a symbol. */
-
-bool
-_bfd_elf_find_line (bfd *abfd, asymbol **symbols, asymbol *symbol,
- const char **filename_ptr, unsigned int *line_ptr)
-{
- struct elf_obj_tdata *tdata = elf_tdata (abfd);
- return _bfd_dwarf2_find_nearest_line (abfd, symbols, symbol, NULL, 0,
- filename_ptr, NULL, line_ptr, NULL,
- dwarf_debug_sections,
- &tdata->dwarf2_find_line_info);
-}
-
-/* After a call to bfd_find_nearest_line, successive calls to
- bfd_find_inliner_info can be used to get source information about
- each level of function inlining that terminated at the address
- passed to bfd_find_nearest_line. Currently this is only supported
- for DWARF2 with appropriate DWARF3 extensions. */
-
-bool
-_bfd_elf_find_inliner_info (bfd *abfd,
- const char **filename_ptr,
- const char **functionname_ptr,
- unsigned int *line_ptr)
-{
- struct elf_obj_tdata *tdata = elf_tdata (abfd);
- return _bfd_dwarf2_find_inliner_info (abfd, filename_ptr,
- functionname_ptr, line_ptr,
- &tdata->dwarf2_find_line_info);
-}
-
-int
-_bfd_elf_sizeof_headers (bfd *abfd, struct bfd_link_info *info)
-{
- const struct elf_backend_data *bed = get_elf_backend_data (abfd);
- int ret = bed->s->sizeof_ehdr;
-
- if (!bfd_link_relocatable (info))
- {
- bfd_size_type phdr_size = elf_program_header_size (abfd);
-
- if (phdr_size == (bfd_size_type) -1)
- {
- struct elf_segment_map *m;
-
- phdr_size = 0;
- for (m = elf_seg_map (abfd); m != NULL; m = m->next)
- phdr_size += bed->s->sizeof_phdr;
-
- if (phdr_size == 0)
- phdr_size = get_program_header_size (abfd, info);
- }
-
- elf_program_header_size (abfd) = phdr_size;
- ret += phdr_size;
- }
-
- return ret;
-}
-
-bool
-_bfd_elf_set_section_contents (bfd *abfd,
- sec_ptr section,
- const void *location,
- file_ptr offset,
- bfd_size_type count)
-{
- Elf_Internal_Shdr *hdr;
-
- if (! abfd->output_has_begun
- && ! _bfd_elf_compute_section_file_positions (abfd, NULL))
- return false;
-
- if (!count)
- return true;
-
- hdr = &elf_section_data (section)->this_hdr;
- if (hdr->sh_offset == (file_ptr) -1)
- {
- unsigned char *contents;
-
- if (bfd_section_is_ctf (section))
- /* Nothing to do with this section: the contents are generated
- later. */
- return true;
-
- if ((offset + count) > hdr->sh_size)
- {
- _bfd_error_handler
- (_("%pB:%pA: error: attempting to write"
- " over the end of the section"),
- abfd, section);
-
- bfd_set_error (bfd_error_invalid_operation);
- return false;
- }
-
- contents = hdr->contents;
- if (contents == NULL)
- {
- _bfd_error_handler
- (_("%pB:%pA: error: attempting to write"
- " section into an empty buffer"),
- abfd, section);
-
- bfd_set_error (bfd_error_invalid_operation);
- return false;
- }
-
- memcpy (contents + offset, location, count);
- return true;
- }
-
- return _bfd_generic_set_section_contents (abfd, section,
- location, offset, count);
-}
-
-bool
-_bfd_elf_no_info_to_howto (bfd *abfd ATTRIBUTE_UNUSED,
- arelent *cache_ptr ATTRIBUTE_UNUSED,
- Elf_Internal_Rela *dst ATTRIBUTE_UNUSED)
-{
- abort ();
- return false;
-}
-
-/* Try to convert a non-ELF reloc into an ELF one. */
-
-bool
-_bfd_elf_validate_reloc (bfd *abfd, arelent *areloc)
-{
- /* Check whether we really have an ELF howto. */
-
- if ((*areloc->sym_ptr_ptr)->the_bfd->xvec != abfd->xvec)
- {
- bfd_reloc_code_real_type code;
- reloc_howto_type *howto;
-
- /* Alien reloc: Try to determine its type to replace it with an
- equivalent ELF reloc. */
-
- if (areloc->howto->pc_relative)
- {
- switch (areloc->howto->bitsize)
- {
- case 8:
- code = BFD_RELOC_8_PCREL;
- break;
- case 12:
- code = BFD_RELOC_12_PCREL;
- break;
- case 16:
- code = BFD_RELOC_16_PCREL;
- break;
- case 24:
- code = BFD_RELOC_24_PCREL;
- break;
- case 32:
- code = BFD_RELOC_32_PCREL;
- break;
- case 64:
- code = BFD_RELOC_64_PCREL;
- break;
- default:
- goto fail;
- }
-
- howto = bfd_reloc_type_lookup (abfd, code);
-
- if (howto && areloc->howto->pcrel_offset != howto->pcrel_offset)
- {
- if (howto->pcrel_offset)
- areloc->addend += areloc->address;
- else
- areloc->addend -= areloc->address; /* addend is unsigned!! */
- }
- }
- else
- {
- switch (areloc->howto->bitsize)
- {
- case 8:
- code = BFD_RELOC_8;
- break;
- case 14:
- code = BFD_RELOC_14;
- break;
- case 16:
- code = BFD_RELOC_16;
- break;
- case 26:
- code = BFD_RELOC_26;
- break;
- case 32:
- code = BFD_RELOC_32;
- break;
- case 64:
- code = BFD_RELOC_64;
- break;
- default:
- goto fail;
- }
-
- howto = bfd_reloc_type_lookup (abfd, code);
- }
-
- if (howto)
- areloc->howto = howto;
- else
- goto fail;
- }
-
- return true;
-
- fail:
- /* xgettext:c-format */
- _bfd_error_handler (_("%pB: %s unsupported"),
- abfd, areloc->howto->name);
- bfd_set_error (bfd_error_sorry);
- return false;
-}
-
-bool
-_bfd_elf_free_cached_info (bfd *abfd)
-{
- struct elf_obj_tdata *tdata;
-
- if ((bfd_get_format (abfd) == bfd_object
- || bfd_get_format (abfd) == bfd_core)
- && (tdata = elf_tdata (abfd)) != NULL)
- {
- if (tdata->o != NULL && elf_shstrtab (abfd) != NULL)
- _bfd_elf_strtab_free (elf_shstrtab (abfd));
- _bfd_dwarf2_cleanup_debug_info (abfd, &tdata->dwarf2_find_line_info);
- _bfd_dwarf1_cleanup_debug_info (abfd, &tdata->dwarf1_find_line_info);
- _bfd_stab_cleanup (abfd, &tdata->line_info);
- }
-
- return _bfd_generic_bfd_free_cached_info (abfd);
-}
-
-/* For Rel targets, we encode meaningful data for BFD_RELOC_VTABLE_ENTRY
- in the relocation's offset. Thus we cannot allow any sort of sanity
- range-checking to interfere. There is nothing else to do in processing
- this reloc. */
-
-bfd_reloc_status_type
-_bfd_elf_rel_vtable_reloc_fn
- (bfd *abfd ATTRIBUTE_UNUSED, arelent *re ATTRIBUTE_UNUSED,
- struct bfd_symbol *symbol ATTRIBUTE_UNUSED,
- void *data ATTRIBUTE_UNUSED, asection *is ATTRIBUTE_UNUSED,
- bfd *obfd ATTRIBUTE_UNUSED, char **errmsg ATTRIBUTE_UNUSED)
-{
- return bfd_reloc_ok;
-}
-
-/* Elf core file support. Much of this only works on native
- toolchains, since we rely on knowing the
- machine-dependent procfs structure in order to pick
- out details about the corefile. */
-
-#ifdef HAVE_SYS_PROCFS_H
-# include <sys/procfs.h>
-#endif
-
-/* Return a PID that identifies a "thread" for threaded cores, or the
- PID of the main process for non-threaded cores. */
-
-static int
-elfcore_make_pid (bfd *abfd)
-{
- int pid;
-
- pid = elf_tdata (abfd)->core->lwpid;
- if (pid == 0)
- pid = elf_tdata (abfd)->core->pid;
-
- return pid;
-}
-
-/* If there isn't a section called NAME, make one, using data from
- SECT. Note, this function will generate a reference to NAME, so
- you shouldn't deallocate or overwrite it. */
-
-static bool
-elfcore_maybe_make_sect (bfd *abfd, char *name, asection *sect)
-{
- asection *sect2;
-
- if (bfd_get_section_by_name (abfd, name) != NULL)
- return true;
-
- sect2 = bfd_make_section_with_flags (abfd, name, sect->flags);
- if (sect2 == NULL)
- return false;
-
- sect2->size = sect->size;
- sect2->filepos = sect->filepos;
- sect2->alignment_power = sect->alignment_power;
- return true;
-}
-
-/* Create a pseudosection containing SIZE bytes at FILEPOS. This
- actually creates up to two pseudosections:
- - For the single-threaded case, a section named NAME, unless
- such a section already exists.
- - For the multi-threaded case, a section named "NAME/PID", where
- PID is elfcore_make_pid (abfd).
- Both pseudosections have identical contents. */
-bool
-_bfd_elfcore_make_pseudosection (bfd *abfd,
- char *name,
- size_t size,
- ufile_ptr filepos)
-{
- char buf[100];
- char *threaded_name;
- size_t len;
- asection *sect;
-
- /* Build the section name. */
-
- sprintf (buf, "%s/%d", name, elfcore_make_pid (abfd));
- len = strlen (buf) + 1;
- threaded_name = (char *) bfd_alloc (abfd, len);
- if (threaded_name == NULL)
- return false;
- memcpy (threaded_name, buf, len);
-
- sect = bfd_make_section_anyway_with_flags (abfd, threaded_name,
- SEC_HAS_CONTENTS);
- if (sect == NULL)
- return false;
- sect->size = size;
- sect->filepos = filepos;
- sect->alignment_power = 2;
-
- return elfcore_maybe_make_sect (abfd, name, sect);
-}
-
-static bool
-elfcore_make_auxv_note_section (bfd *abfd, Elf_Internal_Note *note,
- size_t offs)
-{
- asection *sect = bfd_make_section_anyway_with_flags (abfd, ".auxv",
- SEC_HAS_CONTENTS);
-
- if (sect == NULL)
- return false;
-
- sect->size = note->descsz - offs;
- sect->filepos = note->descpos + offs;
- sect->alignment_power = 1 + bfd_get_arch_size (abfd) / 32;
-
- return true;
-}
-
-/* prstatus_t exists on:
- solaris 2.5+
- linux 2.[01] + glibc
- unixware 4.2
-*/
-
-#if defined (HAVE_PRSTATUS_T)
-
-static bool
-elfcore_grok_prstatus (bfd *abfd, Elf_Internal_Note *note)
-{
- size_t size;
- int offset;
-
- if (note->descsz == sizeof (prstatus_t))
- {
- prstatus_t prstat;
-
- size = sizeof (prstat.pr_reg);
- offset = offsetof (prstatus_t, pr_reg);
- memcpy (&prstat, note->descdata, sizeof (prstat));
-
- /* Do not overwrite the core signal if it
- has already been set by another thread. */
- if (elf_tdata (abfd)->core->signal == 0)
- elf_tdata (abfd)->core->signal = prstat.pr_cursig;
- if (elf_tdata (abfd)->core->pid == 0)
- elf_tdata (abfd)->core->pid = prstat.pr_pid;
-
- /* pr_who exists on:
- solaris 2.5+
- unixware 4.2
- pr_who doesn't exist on:
- linux 2.[01]
- */
-#if defined (HAVE_PRSTATUS_T_PR_WHO)
- elf_tdata (abfd)->core->lwpid = prstat.pr_who;
-#else
- elf_tdata (abfd)->core->lwpid = prstat.pr_pid;
-#endif
- }
-#if defined (HAVE_PRSTATUS32_T)
- else if (note->descsz == sizeof (prstatus32_t))
- {
- /* 64-bit host, 32-bit corefile */
- prstatus32_t prstat;
-
- size = sizeof (prstat.pr_reg);
- offset = offsetof (prstatus32_t, pr_reg);
- memcpy (&prstat, note->descdata, sizeof (prstat));
-
- /* Do not overwrite the core signal if it
- has already been set by another thread. */
- if (elf_tdata (abfd)->core->signal == 0)
- elf_tdata (abfd)->core->signal = prstat.pr_cursig;
- if (elf_tdata (abfd)->core->pid == 0)
- elf_tdata (abfd)->core->pid = prstat.pr_pid;
-
- /* pr_who exists on:
- solaris 2.5+
- unixware 4.2
- pr_who doesn't exist on:
- linux 2.[01]
- */
-#if defined (HAVE_PRSTATUS32_T_PR_WHO)
- elf_tdata (abfd)->core->lwpid = prstat.pr_who;
-#else
- elf_tdata (abfd)->core->lwpid = prstat.pr_pid;
-#endif
- }
-#endif /* HAVE_PRSTATUS32_T */
- else
- {
- /* Fail - we don't know how to handle any other
- note size (ie. data object type). */
- return true;
- }
-
- /* Make a ".reg/999" section and a ".reg" section. */
- return _bfd_elfcore_make_pseudosection (abfd, ".reg",
- size, note->descpos + offset);
-}
-#endif /* defined (HAVE_PRSTATUS_T) */
-
-/* Create a pseudosection containing the exact contents of NOTE. */
-static bool
-elfcore_make_note_pseudosection (bfd *abfd,
- char *name,
- Elf_Internal_Note *note)
-{
- return _bfd_elfcore_make_pseudosection (abfd, name,
- note->descsz, note->descpos);
-}
-
-/* There isn't a consistent prfpregset_t across platforms,
- but it doesn't matter, because we don't have to pick this
- data structure apart. */
-
-static bool
-elfcore_grok_prfpreg (bfd *abfd, Elf_Internal_Note *note)
-{
- return elfcore_make_note_pseudosection (abfd, ".reg2", note);
-}
-
-/* Linux dumps the Intel SSE regs in a note named "LINUX" with a note
- type of NT_PRXFPREG. Just include the whole note's contents
- literally. */
-
-static bool
-elfcore_grok_prxfpreg (bfd *abfd, Elf_Internal_Note *note)
-{
- return elfcore_make_note_pseudosection (abfd, ".reg-xfp", note);
-}
-
-/* Linux dumps the Intel XSAVE extended state in a note named "LINUX"
- with a note type of NT_X86_XSTATE. Just include the whole note's
- contents literally. */
-
-static bool
-elfcore_grok_xstatereg (bfd *abfd, Elf_Internal_Note *note)
-{
- return elfcore_make_note_pseudosection (abfd, ".reg-xstate", note);
-}
-
-static bool
-elfcore_grok_ppc_vmx (bfd *abfd, Elf_Internal_Note *note)
-{
- return elfcore_make_note_pseudosection (abfd, ".reg-ppc-vmx", note);
-}
-
-static bool
-elfcore_grok_ppc_vsx (bfd *abfd, Elf_Internal_Note *note)
-{
- return elfcore_make_note_pseudosection (abfd, ".reg-ppc-vsx", note);
-}
-
-static bool
-elfcore_grok_ppc_tar (bfd *abfd, Elf_Internal_Note *note)
-{
- return elfcore_make_note_pseudosection (abfd, ".reg-ppc-tar", note);
-}
-
-static bool
-elfcore_grok_ppc_ppr (bfd *abfd, Elf_Internal_Note *note)
-{
- return elfcore_make_note_pseudosection (abfd, ".reg-ppc-ppr", note);
-}
-
-static bool
-elfcore_grok_ppc_dscr (bfd *abfd, Elf_Internal_Note *note)
-{
- return elfcore_make_note_pseudosection (abfd, ".reg-ppc-dscr", note);
-}
-
-static bool
-elfcore_grok_ppc_ebb (bfd *abfd, Elf_Internal_Note *note)
-{
- return elfcore_make_note_pseudosection (abfd, ".reg-ppc-ebb", note);
-}
-
-static bool
-elfcore_grok_ppc_pmu (bfd *abfd, Elf_Internal_Note *note)
-{
- return elfcore_make_note_pseudosection (abfd, ".reg-ppc-pmu", note);
-}
-
-static bool
-elfcore_grok_ppc_tm_cgpr (bfd *abfd, Elf_Internal_Note *note)
-{
- return elfcore_make_note_pseudosection (abfd, ".reg-ppc-tm-cgpr", note);
-}
-
-static bool
-elfcore_grok_ppc_tm_cfpr (bfd *abfd, Elf_Internal_Note *note)
-{
- return elfcore_make_note_pseudosection (abfd, ".reg-ppc-tm-cfpr", note);
-}
-
-static bool
-elfcore_grok_ppc_tm_cvmx (bfd *abfd, Elf_Internal_Note *note)
-{
- return elfcore_make_note_pseudosection (abfd, ".reg-ppc-tm-cvmx", note);
-}
-
-static bool
-elfcore_grok_ppc_tm_cvsx (bfd *abfd, Elf_Internal_Note *note)
-{
- return elfcore_make_note_pseudosection (abfd, ".reg-ppc-tm-cvsx", note);
-}
-
-static bool
-elfcore_grok_ppc_tm_spr (bfd *abfd, Elf_Internal_Note *note)
-{
- return elfcore_make_note_pseudosection (abfd, ".reg-ppc-tm-spr", note);
-}
-
-static bool
-elfcore_grok_ppc_tm_ctar (bfd *abfd, Elf_Internal_Note *note)
-{
- return elfcore_make_note_pseudosection (abfd, ".reg-ppc-tm-ctar", note);
-}
-
-static bool
-elfcore_grok_ppc_tm_cppr (bfd *abfd, Elf_Internal_Note *note)
-{
- return elfcore_make_note_pseudosection (abfd, ".reg-ppc-tm-cppr", note);
-}
-
-static bool
-elfcore_grok_ppc_tm_cdscr (bfd *abfd, Elf_Internal_Note *note)
-{
- return elfcore_make_note_pseudosection (abfd, ".reg-ppc-tm-cdscr", note);
-}
-
-static bool
-elfcore_grok_s390_high_gprs (bfd *abfd, Elf_Internal_Note *note)
-{
- return elfcore_make_note_pseudosection (abfd, ".reg-s390-high-gprs", note);
-}
-
-static bool
-elfcore_grok_s390_timer (bfd *abfd, Elf_Internal_Note *note)
-{
- return elfcore_make_note_pseudosection (abfd, ".reg-s390-timer", note);
-}
-
-static bool
-elfcore_grok_s390_todcmp (bfd *abfd, Elf_Internal_Note *note)
-{
- return elfcore_make_note_pseudosection (abfd, ".reg-s390-todcmp", note);
-}
-
-static bool
-elfcore_grok_s390_todpreg (bfd *abfd, Elf_Internal_Note *note)
-{
- return elfcore_make_note_pseudosection (abfd, ".reg-s390-todpreg", note);
-}
-
-static bool
-elfcore_grok_s390_ctrs (bfd *abfd, Elf_Internal_Note *note)
-{
- return elfcore_make_note_pseudosection (abfd, ".reg-s390-ctrs", note);
-}
-
-static bool
-elfcore_grok_s390_prefix (bfd *abfd, Elf_Internal_Note *note)
-{
- return elfcore_make_note_pseudosection (abfd, ".reg-s390-prefix", note);
-}
-
-static bool
-elfcore_grok_s390_last_break (bfd *abfd, Elf_Internal_Note *note)
-{
- return elfcore_make_note_pseudosection (abfd, ".reg-s390-last-break", note);
-}
-
-static bool
-elfcore_grok_s390_system_call (bfd *abfd, Elf_Internal_Note *note)
-{
- return elfcore_make_note_pseudosection (abfd, ".reg-s390-system-call", note);
-}
-
-static bool
-elfcore_grok_s390_tdb (bfd *abfd, Elf_Internal_Note *note)
-{
- return elfcore_make_note_pseudosection (abfd, ".reg-s390-tdb", note);
-}
-
-static bool
-elfcore_grok_s390_vxrs_low (bfd *abfd, Elf_Internal_Note *note)
-{
- return elfcore_make_note_pseudosection (abfd, ".reg-s390-vxrs-low", note);
-}
-
-static bool
-elfcore_grok_s390_vxrs_high (bfd *abfd, Elf_Internal_Note *note)
-{
- return elfcore_make_note_pseudosection (abfd, ".reg-s390-vxrs-high", note);
-}
-
-static bool
-elfcore_grok_s390_gs_cb (bfd *abfd, Elf_Internal_Note *note)
-{
- return elfcore_make_note_pseudosection (abfd, ".reg-s390-gs-cb", note);
-}
-
-static bool
-elfcore_grok_s390_gs_bc (bfd *abfd, Elf_Internal_Note *note)
-{
- return elfcore_make_note_pseudosection (abfd, ".reg-s390-gs-bc", note);
-}
-
-static bool
-elfcore_grok_arm_vfp (bfd *abfd, Elf_Internal_Note *note)
-{
- return elfcore_make_note_pseudosection (abfd, ".reg-arm-vfp", note);
-}
-
-static bool
-elfcore_grok_aarch_tls (bfd *abfd, Elf_Internal_Note *note)
-{
- return elfcore_make_note_pseudosection (abfd, ".reg-aarch-tls", note);
-}
-
-static bool
-elfcore_grok_aarch_hw_break (bfd *abfd, Elf_Internal_Note *note)
-{
- return elfcore_make_note_pseudosection (abfd, ".reg-aarch-hw-break", note);
-}
-
-static bool
-elfcore_grok_aarch_hw_watch (bfd *abfd, Elf_Internal_Note *note)
-{
- return elfcore_make_note_pseudosection (abfd, ".reg-aarch-hw-watch", note);
-}
-
-static bool
-elfcore_grok_aarch_sve (bfd *abfd, Elf_Internal_Note *note)
-{
- return elfcore_make_note_pseudosection (abfd, ".reg-aarch-sve", note);
-}
-
-static bool
-elfcore_grok_aarch_pauth (bfd *abfd, Elf_Internal_Note *note)
-{
- return elfcore_make_note_pseudosection (abfd, ".reg-aarch-pauth", note);
-}
-
-static bool
-elfcore_grok_aarch_mte (bfd *abfd, Elf_Internal_Note *note)
-{
- return elfcore_make_note_pseudosection (abfd, ".reg-aarch-mte",
- note);
-}
-
-static bool
-elfcore_grok_aarch_ssve (bfd *abfd, Elf_Internal_Note *note)
-{
- return elfcore_make_note_pseudosection (abfd, ".reg-aarch-ssve", note);
-}
-
-static bool
-elfcore_grok_aarch_za (bfd *abfd, Elf_Internal_Note *note)
-{
- return elfcore_make_note_pseudosection (abfd, ".reg-aarch-za", note);
-}
-
-/* Convert NOTE into a bfd_section called ".reg-aarch-zt". Return TRUE if
- successful, otherwise return FALSE. */
-
-static bool
-elfcore_grok_aarch_zt (bfd *abfd, Elf_Internal_Note *note)
-{
- return elfcore_make_note_pseudosection (abfd, ".reg-aarch-zt", note);
-}
-
-static bool
-elfcore_grok_arc_v2 (bfd *abfd, Elf_Internal_Note *note)
-{
- return elfcore_make_note_pseudosection (abfd, ".reg-arc-v2", note);
-}
-
-/* Convert NOTE into a bfd_section called ".reg-riscv-csr". Return TRUE if
- successful otherwise, return FALSE. */
-
-static bool
-elfcore_grok_riscv_csr (bfd *abfd, Elf_Internal_Note *note)
-{
- return elfcore_make_note_pseudosection (abfd, ".reg-riscv-csr", note);
-}
-
-/* Convert NOTE into a bfd_section called ".gdb-tdesc". Return TRUE if
- successful otherwise, return FALSE. */
-
-static bool
-elfcore_grok_gdb_tdesc (bfd *abfd, Elf_Internal_Note *note)
-{
- return elfcore_make_note_pseudosection (abfd, ".gdb-tdesc", note);
-}
-
-static bool
-elfcore_grok_loongarch_cpucfg (bfd *abfd, Elf_Internal_Note *note)
-{
- return elfcore_make_note_pseudosection (abfd, ".reg-loongarch-cpucfg", note);
-}
-
-static bool
-elfcore_grok_loongarch_lbt (bfd *abfd, Elf_Internal_Note *note)
-{
- return elfcore_make_note_pseudosection (abfd, ".reg-loongarch-lbt", note);
-}
-
-static bool
-elfcore_grok_loongarch_lsx (bfd *abfd, Elf_Internal_Note *note)
-{
- return elfcore_make_note_pseudosection (abfd, ".reg-loongarch-lsx", note);
-}
-
-static bool
-elfcore_grok_loongarch_lasx (bfd *abfd, Elf_Internal_Note *note)
-{
- return elfcore_make_note_pseudosection (abfd, ".reg-loongarch-lasx", note);
-}
-
-#if defined (HAVE_PRPSINFO_T)
-typedef prpsinfo_t elfcore_psinfo_t;
-#if defined (HAVE_PRPSINFO32_T) /* Sparc64 cross Sparc32 */
-typedef prpsinfo32_t elfcore_psinfo32_t;
-#endif
-#endif
-
-#if defined (HAVE_PSINFO_T)
-typedef psinfo_t elfcore_psinfo_t;
-#if defined (HAVE_PSINFO32_T) /* Sparc64 cross Sparc32 */
-typedef psinfo32_t elfcore_psinfo32_t;
-#endif
-#endif
-
-/* return a malloc'ed copy of a string at START which is at
- most MAX bytes long, possibly without a terminating '\0'.
- the copy will always have a terminating '\0'. */
-
-char *
-_bfd_elfcore_strndup (bfd *abfd, char *start, size_t max)
-{
- char *dups;
- char *end = (char *) memchr (start, '\0', max);
- size_t len;
-
- if (end == NULL)
- len = max;
- else
- len = end - start;
-
- dups = (char *) bfd_alloc (abfd, len + 1);
- if (dups == NULL)
- return NULL;
-
- memcpy (dups, start, len);
- dups[len] = '\0';
-
- return dups;
-}
-
-#if defined (HAVE_PRPSINFO_T) || defined (HAVE_PSINFO_T)
-static bool
-elfcore_grok_psinfo (bfd *abfd, Elf_Internal_Note *note)
-{
- if (note->descsz == sizeof (elfcore_psinfo_t))
- {
- elfcore_psinfo_t psinfo;
-
- memcpy (&psinfo, note->descdata, sizeof (psinfo));
-
-#if defined (HAVE_PSINFO_T_PR_PID) || defined (HAVE_PRPSINFO_T_PR_PID)
- elf_tdata (abfd)->core->pid = psinfo.pr_pid;
-#endif
- elf_tdata (abfd)->core->program
- = _bfd_elfcore_strndup (abfd, psinfo.pr_fname,
- sizeof (psinfo.pr_fname));
-
- elf_tdata (abfd)->core->command
- = _bfd_elfcore_strndup (abfd, psinfo.pr_psargs,
- sizeof (psinfo.pr_psargs));
- }
-#if defined (HAVE_PRPSINFO32_T) || defined (HAVE_PSINFO32_T)
- else if (note->descsz == sizeof (elfcore_psinfo32_t))
- {
- /* 64-bit host, 32-bit corefile */
- elfcore_psinfo32_t psinfo;
-
- memcpy (&psinfo, note->descdata, sizeof (psinfo));
-
-#if defined (HAVE_PSINFO32_T_PR_PID) || defined (HAVE_PRPSINFO32_T_PR_PID)
- elf_tdata (abfd)->core->pid = psinfo.pr_pid;
-#endif
- elf_tdata (abfd)->core->program
- = _bfd_elfcore_strndup (abfd, psinfo.pr_fname,
- sizeof (psinfo.pr_fname));
-
- elf_tdata (abfd)->core->command
- = _bfd_elfcore_strndup (abfd, psinfo.pr_psargs,
- sizeof (psinfo.pr_psargs));
- }
-#endif
-
- else
- {
- /* Fail - we don't know how to handle any other
- note size (ie. data object type). */
- return true;
- }
-
- /* Note that for some reason, a spurious space is tacked
- onto the end of the args in some (at least one anyway)
- implementations, so strip it off if it exists. */
-
- {
- char *command = elf_tdata (abfd)->core->command;
- int n = strlen (command);
-
- if (0 < n && command[n - 1] == ' ')
- command[n - 1] = '\0';
- }
-
- return true;
-}
-#endif /* defined (HAVE_PRPSINFO_T) || defined (HAVE_PSINFO_T) */
-
-#if defined (HAVE_PSTATUS_T)
-static bool
-elfcore_grok_pstatus (bfd *abfd, Elf_Internal_Note *note)
-{
- if (note->descsz == sizeof (pstatus_t)
-#if defined (HAVE_PXSTATUS_T)
- || note->descsz == sizeof (pxstatus_t)
-#endif
- )
- {
- pstatus_t pstat;
-
- memcpy (&pstat, note->descdata, sizeof (pstat));
-
- elf_tdata (abfd)->core->pid = pstat.pr_pid;
- }
-#if defined (HAVE_PSTATUS32_T)
- else if (note->descsz == sizeof (pstatus32_t))
- {
- /* 64-bit host, 32-bit corefile */
- pstatus32_t pstat;
-
- memcpy (&pstat, note->descdata, sizeof (pstat));
-
- elf_tdata (abfd)->core->pid = pstat.pr_pid;
- }
-#endif
- /* Could grab some more details from the "representative"
- lwpstatus_t in pstat.pr_lwp, but we'll catch it all in an
- NT_LWPSTATUS note, presumably. */
-
- return true;
-}
-#endif /* defined (HAVE_PSTATUS_T) */
-
-#if defined (HAVE_LWPSTATUS_T)
-static bool
-elfcore_grok_lwpstatus (bfd *abfd, Elf_Internal_Note *note)
-{
- lwpstatus_t lwpstat;
- char buf[100];
- char *name;
- size_t len;
- asection *sect;
-
- if (note->descsz != sizeof (lwpstat)
-#if defined (HAVE_LWPXSTATUS_T)
- && note->descsz != sizeof (lwpxstatus_t)
-#endif
- )
- return true;
-
- memcpy (&lwpstat, note->descdata, sizeof (lwpstat));
-
- elf_tdata (abfd)->core->lwpid = lwpstat.pr_lwpid;
- /* Do not overwrite the core signal if it has already been set by
- another thread. */
- if (elf_tdata (abfd)->core->signal == 0)
- elf_tdata (abfd)->core->signal = lwpstat.pr_cursig;
-
- /* Make a ".reg/999" section. */
-
- sprintf (buf, ".reg/%d", elfcore_make_pid (abfd));
- len = strlen (buf) + 1;
- name = bfd_alloc (abfd, len);
- if (name == NULL)
- return false;
- memcpy (name, buf, len);
-
- sect = bfd_make_section_anyway_with_flags (abfd, name, SEC_HAS_CONTENTS);
- if (sect == NULL)
- return false;
-
-#if defined (HAVE_LWPSTATUS_T_PR_CONTEXT)
- sect->size = sizeof (lwpstat.pr_context.uc_mcontext.gregs);
- sect->filepos = note->descpos
- + offsetof (lwpstatus_t, pr_context.uc_mcontext.gregs);
-#endif
-
-#if defined (HAVE_LWPSTATUS_T_PR_REG)
- sect->size = sizeof (lwpstat.pr_reg);
- sect->filepos = note->descpos + offsetof (lwpstatus_t, pr_reg);
-#endif
-
- sect->alignment_power = 2;
-
- if (!elfcore_maybe_make_sect (abfd, ".reg", sect))
- return false;
-
- /* Make a ".reg2/999" section */
-
- sprintf (buf, ".reg2/%d", elfcore_make_pid (abfd));
- len = strlen (buf) + 1;
- name = bfd_alloc (abfd, len);
- if (name == NULL)
- return false;
- memcpy (name, buf, len);
-
- sect = bfd_make_section_anyway_with_flags (abfd, name, SEC_HAS_CONTENTS);
- if (sect == NULL)
- return false;
-
-#if defined (HAVE_LWPSTATUS_T_PR_CONTEXT)
- sect->size = sizeof (lwpstat.pr_context.uc_mcontext.fpregs);
- sect->filepos = note->descpos
- + offsetof (lwpstatus_t, pr_context.uc_mcontext.fpregs);
-#endif
-
-#if defined (HAVE_LWPSTATUS_T_PR_FPREG)
- sect->size = sizeof (lwpstat.pr_fpreg);
- sect->filepos = note->descpos + offsetof (lwpstatus_t, pr_fpreg);
-#endif
-
- sect->alignment_power = 2;
-
- return elfcore_maybe_make_sect (abfd, ".reg2", sect);
-}
-#endif /* defined (HAVE_LWPSTATUS_T) */
-
-/* These constants, and the structure offsets used below, are defined by
- Cygwin's core_dump.h */
-#define NOTE_INFO_PROCESS 1
-#define NOTE_INFO_THREAD 2
-#define NOTE_INFO_MODULE 3
-#define NOTE_INFO_MODULE64 4
-
-static bool
-elfcore_grok_win32pstatus (bfd *abfd, Elf_Internal_Note *note)
-{
- char buf[30];
- char *name;
- size_t len;
- unsigned int name_size;
- asection *sect;
- unsigned int type;
- int is_active_thread;
- bfd_vma base_addr;
-
- if (note->descsz < 4)
- return true;
-
- if (! startswith (note->namedata, "win32"))
- return true;
-
- type = bfd_get_32 (abfd, note->descdata);
-
- struct
- {
- const char *type_name;
- unsigned long min_size;
- } size_check[] =
- {
- { "NOTE_INFO_PROCESS", 12 },
- { "NOTE_INFO_THREAD", 12 },
- { "NOTE_INFO_MODULE", 12 },
- { "NOTE_INFO_MODULE64", 16 },
- };
-
- if (type == 0 || type > (sizeof(size_check)/sizeof(size_check[0])))
- return true;
-
- if (note->descsz < size_check[type - 1].min_size)
- {
- _bfd_error_handler (_("%pB: warning: win32pstatus %s of size %lu bytes"
- " is too small"),
- abfd, size_check[type - 1].type_name, note->descsz);
- return true;
- }
-
- switch (type)
- {
- case NOTE_INFO_PROCESS:
- /* FIXME: need to add ->core->command. */
- elf_tdata (abfd)->core->pid = bfd_get_32 (abfd, note->descdata + 4);
- elf_tdata (abfd)->core->signal = bfd_get_32 (abfd, note->descdata + 8);
- break;
-
- case NOTE_INFO_THREAD:
- /* Make a ".reg/<tid>" section containing the Win32 API thread CONTEXT
- structure. */
- /* thread_info.tid */
- sprintf (buf, ".reg/%ld", (long) bfd_get_32 (abfd, note->descdata + 4));
-
- len = strlen (buf) + 1;
- name = (char *) bfd_alloc (abfd, len);
- if (name == NULL)
- return false;
-
- memcpy (name, buf, len);
-
- sect = bfd_make_section_anyway_with_flags (abfd, name, SEC_HAS_CONTENTS);
- if (sect == NULL)
- return false;
-
- /* sizeof (thread_info.thread_context) */
- sect->size = note->descsz - 12;
- /* offsetof (thread_info.thread_context) */
- sect->filepos = note->descpos + 12;
- sect->alignment_power = 2;
-
- /* thread_info.is_active_thread */
- is_active_thread = bfd_get_32 (abfd, note->descdata + 8);
-
- if (is_active_thread)
- if (! elfcore_maybe_make_sect (abfd, ".reg", sect))
- return false;
- break;
-
- case NOTE_INFO_MODULE:
- case NOTE_INFO_MODULE64:
- /* Make a ".module/xxxxxxxx" section. */
- if (type == NOTE_INFO_MODULE)
- {
- /* module_info.base_address */
- base_addr = bfd_get_32 (abfd, note->descdata + 4);
- sprintf (buf, ".module/%08lx", (unsigned long) base_addr);
- /* module_info.module_name_size */
- name_size = bfd_get_32 (abfd, note->descdata + 8);
- }
- else /* NOTE_INFO_MODULE64 */
- {
- /* module_info.base_address */
- base_addr = bfd_get_64 (abfd, note->descdata + 4);
- sprintf (buf, ".module/%016lx", (unsigned long) base_addr);
- /* module_info.module_name_size */
- name_size = bfd_get_32 (abfd, note->descdata + 12);
- }
-
- len = strlen (buf) + 1;
- name = (char *) bfd_alloc (abfd, len);
- if (name == NULL)
- return false;
-
- memcpy (name, buf, len);
-
- sect = bfd_make_section_anyway_with_flags (abfd, name, SEC_HAS_CONTENTS);
-
- if (sect == NULL)
- return false;
-
- if (note->descsz < 12 + name_size)
- {
- _bfd_error_handler (_("%pB: win32pstatus NOTE_INFO_MODULE of size %lu"
- " is too small to contain a name of size %u"),
- abfd, note->descsz, name_size);
- return true;
- }
-
- sect->size = note->descsz;
- sect->filepos = note->descpos;
- sect->alignment_power = 2;
- break;
-
- default:
- return true;
- }
-
- return true;
-}
-
-static bool
-elfcore_grok_note (bfd *abfd, Elf_Internal_Note *note)
-{
- const struct elf_backend_data *bed = get_elf_backend_data (abfd);
-
- switch (note->type)
- {
- default:
- return true;
-
- case NT_PRSTATUS:
- if (bed->elf_backend_grok_prstatus)
- if ((*bed->elf_backend_grok_prstatus) (abfd, note))
- return true;
-#if defined (HAVE_PRSTATUS_T)
- return elfcore_grok_prstatus (abfd, note);
-#else
- return true;
-#endif
-
-#if defined (HAVE_PSTATUS_T)
- case NT_PSTATUS:
- return elfcore_grok_pstatus (abfd, note);
-#endif
-
-#if defined (HAVE_LWPSTATUS_T)
- case NT_LWPSTATUS:
- return elfcore_grok_lwpstatus (abfd, note);
-#endif
-
- case NT_FPREGSET: /* FIXME: rename to NT_PRFPREG */
- return elfcore_grok_prfpreg (abfd, note);
-
- case NT_WIN32PSTATUS:
- return elfcore_grok_win32pstatus (abfd, note);
-
- case NT_PRXFPREG: /* Linux SSE extension */
- if (note->namesz == 6
- && strcmp (note->namedata, "LINUX") == 0)
- return elfcore_grok_prxfpreg (abfd, note);
- else
- return true;
-
- case NT_X86_XSTATE: /* Linux XSAVE extension */
- if (note->namesz == 6
- && strcmp (note->namedata, "LINUX") == 0)
- return elfcore_grok_xstatereg (abfd, note);
- else
- return true;
-
- case NT_PPC_VMX:
- if (note->namesz == 6
- && strcmp (note->namedata, "LINUX") == 0)
- return elfcore_grok_ppc_vmx (abfd, note);
- else
- return true;
-
- case NT_PPC_VSX:
- if (note->namesz == 6
- && strcmp (note->namedata, "LINUX") == 0)
- return elfcore_grok_ppc_vsx (abfd, note);
- else
- return true;
-
- case NT_PPC_TAR:
- if (note->namesz == 6
- && strcmp (note->namedata, "LINUX") == 0)
- return elfcore_grok_ppc_tar (abfd, note);
- else
- return true;
-
- case NT_PPC_PPR:
- if (note->namesz == 6
- && strcmp (note->namedata, "LINUX") == 0)
- return elfcore_grok_ppc_ppr (abfd, note);
- else
- return true;
-
- case NT_PPC_DSCR:
- if (note->namesz == 6
- && strcmp (note->namedata, "LINUX") == 0)
- return elfcore_grok_ppc_dscr (abfd, note);
- else
- return true;
-
- case NT_PPC_EBB:
- if (note->namesz == 6
- && strcmp (note->namedata, "LINUX") == 0)
- return elfcore_grok_ppc_ebb (abfd, note);
- else
- return true;
-
- case NT_PPC_PMU:
- if (note->namesz == 6
- && strcmp (note->namedata, "LINUX") == 0)
- return elfcore_grok_ppc_pmu (abfd, note);
- else
- return true;
-
- case NT_PPC_TM_CGPR:
- if (note->namesz == 6
- && strcmp (note->namedata, "LINUX") == 0)
- return elfcore_grok_ppc_tm_cgpr (abfd, note);
- else
- return true;
-
- case NT_PPC_TM_CFPR:
- if (note->namesz == 6
- && strcmp (note->namedata, "LINUX") == 0)
- return elfcore_grok_ppc_tm_cfpr (abfd, note);
- else
- return true;
-
- case NT_PPC_TM_CVMX:
- if (note->namesz == 6
- && strcmp (note->namedata, "LINUX") == 0)
- return elfcore_grok_ppc_tm_cvmx (abfd, note);
- else
- return true;
-
- case NT_PPC_TM_CVSX:
- if (note->namesz == 6
- && strcmp (note->namedata, "LINUX") == 0)
- return elfcore_grok_ppc_tm_cvsx (abfd, note);
- else
- return true;
-
- case NT_PPC_TM_SPR:
- if (note->namesz == 6
- && strcmp (note->namedata, "LINUX") == 0)
- return elfcore_grok_ppc_tm_spr (abfd, note);
- else
- return true;
-
- case NT_PPC_TM_CTAR:
- if (note->namesz == 6
- && strcmp (note->namedata, "LINUX") == 0)
- return elfcore_grok_ppc_tm_ctar (abfd, note);
- else
- return true;
-
- case NT_PPC_TM_CPPR:
- if (note->namesz == 6
- && strcmp (note->namedata, "LINUX") == 0)
- return elfcore_grok_ppc_tm_cppr (abfd, note);
- else
- return true;
-
- case NT_PPC_TM_CDSCR:
- if (note->namesz == 6
- && strcmp (note->namedata, "LINUX") == 0)
- return elfcore_grok_ppc_tm_cdscr (abfd, note);
- else
- return true;
-
- case NT_S390_HIGH_GPRS:
- if (note->namesz == 6
- && strcmp (note->namedata, "LINUX") == 0)
- return elfcore_grok_s390_high_gprs (abfd, note);
- else
- return true;
-
- case NT_S390_TIMER:
- if (note->namesz == 6
- && strcmp (note->namedata, "LINUX") == 0)
- return elfcore_grok_s390_timer (abfd, note);
- else
- return true;
-
- case NT_S390_TODCMP:
- if (note->namesz == 6
- && strcmp (note->namedata, "LINUX") == 0)
- return elfcore_grok_s390_todcmp (abfd, note);
- else
- return true;
-
- case NT_S390_TODPREG:
- if (note->namesz == 6
- && strcmp (note->namedata, "LINUX") == 0)
- return elfcore_grok_s390_todpreg (abfd, note);
- else
- return true;
-
- case NT_S390_CTRS:
- if (note->namesz == 6
- && strcmp (note->namedata, "LINUX") == 0)
- return elfcore_grok_s390_ctrs (abfd, note);
- else
- return true;
-
- case NT_S390_PREFIX:
- if (note->namesz == 6
- && strcmp (note->namedata, "LINUX") == 0)
- return elfcore_grok_s390_prefix (abfd, note);
- else
- return true;
-
- case NT_S390_LAST_BREAK:
- if (note->namesz == 6
- && strcmp (note->namedata, "LINUX") == 0)
- return elfcore_grok_s390_last_break (abfd, note);
- else
- return true;
-
- case NT_S390_SYSTEM_CALL:
- if (note->namesz == 6
- && strcmp (note->namedata, "LINUX") == 0)
- return elfcore_grok_s390_system_call (abfd, note);
- else
- return true;
-
- case NT_S390_TDB:
- if (note->namesz == 6
- && strcmp (note->namedata, "LINUX") == 0)
- return elfcore_grok_s390_tdb (abfd, note);
- else
- return true;
-
- case NT_S390_VXRS_LOW:
- if (note->namesz == 6
- && strcmp (note->namedata, "LINUX") == 0)
- return elfcore_grok_s390_vxrs_low (abfd, note);
- else
- return true;
-
- case NT_S390_VXRS_HIGH:
- if (note->namesz == 6
- && strcmp (note->namedata, "LINUX") == 0)
- return elfcore_grok_s390_vxrs_high (abfd, note);
- else
- return true;
-
- case NT_S390_GS_CB:
- if (note->namesz == 6
- && strcmp (note->namedata, "LINUX") == 0)
- return elfcore_grok_s390_gs_cb (abfd, note);
- else
- return true;
-
- case NT_S390_GS_BC:
- if (note->namesz == 6
- && strcmp (note->namedata, "LINUX") == 0)
- return elfcore_grok_s390_gs_bc (abfd, note);
- else
- return true;
-
- case NT_ARC_V2:
- if (note->namesz == 6
- && strcmp (note->namedata, "LINUX") == 0)
- return elfcore_grok_arc_v2 (abfd, note);
- else
- return true;
-
- case NT_ARM_VFP:
- if (note->namesz == 6
- && strcmp (note->namedata, "LINUX") == 0)
- return elfcore_grok_arm_vfp (abfd, note);
- else
- return true;
-
- case NT_ARM_TLS:
- if (note->namesz == 6
- && strcmp (note->namedata, "LINUX") == 0)
- return elfcore_grok_aarch_tls (abfd, note);
- else
- return true;
-
- case NT_ARM_HW_BREAK:
- if (note->namesz == 6
- && strcmp (note->namedata, "LINUX") == 0)
- return elfcore_grok_aarch_hw_break (abfd, note);
- else
- return true;
-
- case NT_ARM_HW_WATCH:
- if (note->namesz == 6
- && strcmp (note->namedata, "LINUX") == 0)
- return elfcore_grok_aarch_hw_watch (abfd, note);
- else
- return true;
-
- case NT_ARM_SVE:
- if (note->namesz == 6
- && strcmp (note->namedata, "LINUX") == 0)
- return elfcore_grok_aarch_sve (abfd, note);
- else
- return true;
-
- case NT_ARM_PAC_MASK:
- if (note->namesz == 6
- && strcmp (note->namedata, "LINUX") == 0)
- return elfcore_grok_aarch_pauth (abfd, note);
- else
- return true;
-
- case NT_ARM_TAGGED_ADDR_CTRL:
- if (note->namesz == 6
- && strcmp (note->namedata, "LINUX") == 0)
- return elfcore_grok_aarch_mte (abfd, note);
- else
- return true;
-
- case NT_ARM_SSVE:
- if (note->namesz == 6
- && strcmp (note->namedata, "LINUX") == 0)
- return elfcore_grok_aarch_ssve (abfd, note);
- else
- return true;
-
- case NT_ARM_ZA:
- if (note->namesz == 6
- && strcmp (note->namedata, "LINUX") == 0)
- return elfcore_grok_aarch_za (abfd, note);
- else
- return true;
-
- case NT_ARM_ZT:
- if (note->namesz == 6
- && strcmp (note->namedata, "LINUX") == 0)
- return elfcore_grok_aarch_zt (abfd, note);
- else
- return true;
-
- case NT_GDB_TDESC:
- if (note->namesz == 4
- && strcmp (note->namedata, "GDB") == 0)
- return elfcore_grok_gdb_tdesc (abfd, note);
- else
- return true;
-
- case NT_RISCV_CSR:
- if (note->namesz == 4
- && strcmp (note->namedata, "GDB") == 0)
- return elfcore_grok_riscv_csr (abfd, note);
- else
- return true;
-
- case NT_LARCH_CPUCFG:
- if (note->namesz == 6
- && strcmp (note->namedata, "LINUX") == 0)
- return elfcore_grok_loongarch_cpucfg (abfd, note);
- else
- return true;
-
- case NT_LARCH_LBT:
- if (note->namesz == 6
- && strcmp (note->namedata, "LINUX") == 0)
- return elfcore_grok_loongarch_lbt (abfd, note);
- else
- return true;
-
- case NT_LARCH_LSX:
- if (note->namesz == 6
- && strcmp (note->namedata, "LINUX") == 0)
- return elfcore_grok_loongarch_lsx (abfd, note);
- else
- return true;
-
- case NT_LARCH_LASX:
- if (note->namesz == 6
- && strcmp (note->namedata, "LINUX") == 0)
- return elfcore_grok_loongarch_lasx (abfd, note);
- else
- return true;
-
- case NT_PRPSINFO:
- case NT_PSINFO:
- if (bed->elf_backend_grok_psinfo)
- if ((*bed->elf_backend_grok_psinfo) (abfd, note))
- return true;
-#if defined (HAVE_PRPSINFO_T) || defined (HAVE_PSINFO_T)
- return elfcore_grok_psinfo (abfd, note);
-#else
- return true;
-#endif
-
- case NT_AUXV:
- return elfcore_make_auxv_note_section (abfd, note, 0);
-
- case NT_FILE:
- return elfcore_make_note_pseudosection (abfd, ".note.linuxcore.file",
- note);
-
- case NT_SIGINFO:
- return elfcore_make_note_pseudosection (abfd, ".note.linuxcore.siginfo",
- note);
-
- }
-}
-
-static bool
-elfobj_grok_gnu_build_id (bfd *abfd, Elf_Internal_Note *note)
-{
- struct bfd_build_id* build_id;
-
- if (note->descsz == 0)
- return false;
-
- build_id = bfd_alloc (abfd, sizeof (struct bfd_build_id) - 1 + note->descsz);
- if (build_id == NULL)
- return false;
-
- build_id->size = note->descsz;
- memcpy (build_id->data, note->descdata, note->descsz);
- abfd->build_id = build_id;
-
- return true;
-}
-
-static bool
-elfobj_grok_gnu_note (bfd *abfd, Elf_Internal_Note *note)
-{
- switch (note->type)
- {
- default:
- return true;
-
- case NT_GNU_PROPERTY_TYPE_0:
- return _bfd_elf_parse_gnu_properties (abfd, note);
-
- case NT_GNU_BUILD_ID:
- return elfobj_grok_gnu_build_id (abfd, note);
- }
-}
-
-static bool
-elfobj_grok_stapsdt_note_1 (bfd *abfd, Elf_Internal_Note *note)
-{
- struct sdt_note *cur =
- (struct sdt_note *) bfd_alloc (abfd,
- sizeof (struct sdt_note) + note->descsz);
-
- cur->next = (struct sdt_note *) (elf_tdata (abfd))->sdt_note_head;
- cur->size = (bfd_size_type) note->descsz;
- memcpy (cur->data, note->descdata, note->descsz);
-
- elf_tdata (abfd)->sdt_note_head = cur;
-
- return true;
-}
-
-static bool
-elfobj_grok_stapsdt_note (bfd *abfd, Elf_Internal_Note *note)
-{
- switch (note->type)
- {
- case NT_STAPSDT:
- return elfobj_grok_stapsdt_note_1 (abfd, note);
-
- default:
- return true;
- }
-}
-
-static bool
-elfcore_grok_freebsd_psinfo (bfd *abfd, Elf_Internal_Note *note)
-{
- size_t offset;
-
- switch (elf_elfheader (abfd)->e_ident[EI_CLASS])
- {
- case ELFCLASS32:
- if (note->descsz < 108)
- return false;
- break;
-
- case ELFCLASS64:
- if (note->descsz < 120)
- return false;
- break;
-
- default:
- return false;
- }
-
- /* Check for version 1 in pr_version. */
- if (bfd_h_get_32 (abfd, (bfd_byte *) note->descdata) != 1)
- return false;
-
- offset = 4;
-
- /* Skip over pr_psinfosz. */
- if (elf_elfheader (abfd)->e_ident[EI_CLASS] == ELFCLASS32)
- offset += 4;
- else
- {
- offset += 4; /* Padding before pr_psinfosz. */
- offset += 8;
- }
-
- /* pr_fname is PRFNAMESZ (16) + 1 bytes in size. */
- elf_tdata (abfd)->core->program
- = _bfd_elfcore_strndup (abfd, note->descdata + offset, 17);
- offset += 17;
-
- /* pr_psargs is PRARGSZ (80) + 1 bytes in size. */
- elf_tdata (abfd)->core->command
- = _bfd_elfcore_strndup (abfd, note->descdata + offset, 81);
- offset += 81;
-
- /* Padding before pr_pid. */
- offset += 2;
-
- /* The pr_pid field was added in version "1a". */
- if (note->descsz < offset + 4)
- return true;
-
- elf_tdata (abfd)->core->pid
- = bfd_h_get_32 (abfd, (bfd_byte *) note->descdata + offset);
-
- return true;
-}
-
-static bool
-elfcore_grok_freebsd_prstatus (bfd *abfd, Elf_Internal_Note *note)
-{
- size_t offset;
- size_t size;
- size_t min_size;
-
- /* Compute offset of pr_getregsz, skipping over pr_statussz.
- Also compute minimum size of this note. */
- switch (elf_elfheader (abfd)->e_ident[EI_CLASS])
- {
- case ELFCLASS32:
- offset = 4 + 4;
- min_size = offset + (4 * 2) + 4 + 4 + 4;
- break;
-
- case ELFCLASS64:
- offset = 4 + 4 + 8; /* Includes padding before pr_statussz. */
- min_size = offset + (8 * 2) + 4 + 4 + 4 + 4;
- break;
-
- default:
- return false;
- }
-
- if (note->descsz < min_size)
- return false;
-
- /* Check for version 1 in pr_version. */
- if (bfd_h_get_32 (abfd, (bfd_byte *) note->descdata) != 1)
- return false;
-
- /* Extract size of pr_reg from pr_gregsetsz. */
- /* Skip over pr_gregsetsz and pr_fpregsetsz. */
- if (elf_elfheader (abfd)->e_ident[EI_CLASS] == ELFCLASS32)
- {
- size = bfd_h_get_32 (abfd, (bfd_byte *) note->descdata + offset);
- offset += 4 * 2;
- }
- else
- {
- size = bfd_h_get_64 (abfd, (bfd_byte *) note->descdata + offset);
- offset += 8 * 2;
- }
-
- /* Skip over pr_osreldate. */
- offset += 4;
-
- /* Read signal from pr_cursig. */
- if (elf_tdata (abfd)->core->signal == 0)
- elf_tdata (abfd)->core->signal
- = bfd_h_get_32 (abfd, (bfd_byte *) note->descdata + offset);
- offset += 4;
-
- /* Read TID from pr_pid. */
- elf_tdata (abfd)->core->lwpid
- = bfd_h_get_32 (abfd, (bfd_byte *) note->descdata + offset);
- offset += 4;
-
- /* Padding before pr_reg. */
- if (elf_elfheader (abfd)->e_ident[EI_CLASS] == ELFCLASS64)
- offset += 4;
-
- /* Make sure that there is enough data remaining in the note. */
- if ((note->descsz - offset) < size)
- return false;
-
- /* Make a ".reg/999" section and a ".reg" section. */
- return _bfd_elfcore_make_pseudosection (abfd, ".reg",
- size, note->descpos + offset);
-}
-
-static bool
-elfcore_grok_freebsd_note (bfd *abfd, Elf_Internal_Note *note)
-{
- const struct elf_backend_data *bed = get_elf_backend_data (abfd);
-
- switch (note->type)
- {
- case NT_PRSTATUS:
- if (bed->elf_backend_grok_freebsd_prstatus)
- if ((*bed->elf_backend_grok_freebsd_prstatus) (abfd, note))
- return true;
- return elfcore_grok_freebsd_prstatus (abfd, note);
-
- case NT_FPREGSET:
- return elfcore_grok_prfpreg (abfd, note);
-
- case NT_PRPSINFO:
- return elfcore_grok_freebsd_psinfo (abfd, note);
-
- case NT_FREEBSD_THRMISC:
- return elfcore_make_note_pseudosection (abfd, ".thrmisc", note);
-
- case NT_FREEBSD_PROCSTAT_PROC:
- return elfcore_make_note_pseudosection (abfd, ".note.freebsdcore.proc",
- note);
-
- case NT_FREEBSD_PROCSTAT_FILES:
- return elfcore_make_note_pseudosection (abfd, ".note.freebsdcore.files",
- note);
-
- case NT_FREEBSD_PROCSTAT_VMMAP:
- return elfcore_make_note_pseudosection (abfd, ".note.freebsdcore.vmmap",
- note);
-
- case NT_FREEBSD_PROCSTAT_AUXV:
- return elfcore_make_auxv_note_section (abfd, note, 4);
-
- case NT_FREEBSD_X86_SEGBASES:
- return elfcore_make_note_pseudosection (abfd, ".reg-x86-segbases", note);
-
- case NT_X86_XSTATE:
- return elfcore_grok_xstatereg (abfd, note);
-
- case NT_FREEBSD_PTLWPINFO:
- return elfcore_make_note_pseudosection (abfd, ".note.freebsdcore.lwpinfo",
- note);
-
- case NT_ARM_TLS:
- return elfcore_grok_aarch_tls (abfd, note);
-
- case NT_ARM_VFP:
- return elfcore_grok_arm_vfp (abfd, note);
-
- default:
- return true;
- }
-}
-
-static bool
-elfcore_netbsd_get_lwpid (Elf_Internal_Note *note, int *lwpidp)
-{
- char *cp;
-
- cp = strchr (note->namedata, '@');
- if (cp != NULL)
- {
- *lwpidp = atoi(cp + 1);
- return true;
- }
- return false;
-}
-
-static bool
-elfcore_grok_netbsd_procinfo (bfd *abfd, Elf_Internal_Note *note)
-{
- if (note->descsz <= 0x7c + 31)
- return false;
-
- /* Signal number at offset 0x08. */
- elf_tdata (abfd)->core->signal
- = bfd_h_get_32 (abfd, (bfd_byte *) note->descdata + 0x08);
-
- /* Process ID at offset 0x50. */
- elf_tdata (abfd)->core->pid
- = bfd_h_get_32 (abfd, (bfd_byte *) note->descdata + 0x50);
-
- /* Command name at 0x7c (max 32 bytes, including nul). */
- elf_tdata (abfd)->core->command
- = _bfd_elfcore_strndup (abfd, note->descdata + 0x7c, 31);
-
- return elfcore_make_note_pseudosection (abfd, ".note.netbsdcore.procinfo",
- note);
-}
-
-static bool
-elfcore_grok_netbsd_note (bfd *abfd, Elf_Internal_Note *note)
-{
- int lwp;
-
- if (elfcore_netbsd_get_lwpid (note, &lwp))
- elf_tdata (abfd)->core->lwpid = lwp;
-
- switch (note->type)
- {
- case NT_NETBSDCORE_PROCINFO:
- /* NetBSD-specific core "procinfo". Note that we expect to
- find this note before any of the others, which is fine,
- since the kernel writes this note out first when it
- creates a core file. */
- return elfcore_grok_netbsd_procinfo (abfd, note);
- case NT_NETBSDCORE_AUXV:
- /* NetBSD-specific Elf Auxiliary Vector data. */
- return elfcore_make_auxv_note_section (abfd, note, 4);
- case NT_NETBSDCORE_LWPSTATUS:
- return elfcore_make_note_pseudosection (abfd,
- ".note.netbsdcore.lwpstatus",
- note);
- default:
- break;
- }
-
- /* As of March 2020 there are no other machine-independent notes
- defined for NetBSD core files. If the note type is less
- than the start of the machine-dependent note types, we don't
- understand it. */
-
- if (note->type < NT_NETBSDCORE_FIRSTMACH)
- return true;
-
-
- switch (bfd_get_arch (abfd))
- {
- /* On the Alpha, SPARC (32-bit and 64-bit), PT_GETREGS == mach+0 and
- PT_GETFPREGS == mach+2. */
-
- case bfd_arch_aarch64:
- case bfd_arch_alpha:
- case bfd_arch_sparc:
- switch (note->type)
- {
- case NT_NETBSDCORE_FIRSTMACH+0:
- return elfcore_make_note_pseudosection (abfd, ".reg", note);
-
- case NT_NETBSDCORE_FIRSTMACH+2:
- return elfcore_make_note_pseudosection (abfd, ".reg2", note);
-
- default:
- return true;
- }
-
- /* On SuperH, PT_GETREGS == mach+3 and PT_GETFPREGS == mach+5.
- There's also old PT___GETREGS40 == mach + 1 for old reg
- structure which lacks GBR. */
-
- case bfd_arch_sh:
- switch (note->type)
- {
- case NT_NETBSDCORE_FIRSTMACH+3:
- return elfcore_make_note_pseudosection (abfd, ".reg", note);
-
- case NT_NETBSDCORE_FIRSTMACH+5:
- return elfcore_make_note_pseudosection (abfd, ".reg2", note);
-
- default:
- return true;
- }
-
- /* On all other arch's, PT_GETREGS == mach+1 and
- PT_GETFPREGS == mach+3. */
-
- default:
- switch (note->type)
- {
- case NT_NETBSDCORE_FIRSTMACH+1:
- return elfcore_make_note_pseudosection (abfd, ".reg", note);
-
- case NT_NETBSDCORE_FIRSTMACH+3:
- return elfcore_make_note_pseudosection (abfd, ".reg2", note);
-
- default:
- return true;
- }
- }
- /* NOTREACHED */
-}
-
-static bool
-elfcore_grok_openbsd_procinfo (bfd *abfd, Elf_Internal_Note *note)
-{
- if (note->descsz <= 0x48 + 31)
- return false;
-
- /* Signal number at offset 0x08. */
- elf_tdata (abfd)->core->signal
- = bfd_h_get_32 (abfd, (bfd_byte *) note->descdata + 0x08);
-
- /* Process ID at offset 0x20. */
- elf_tdata (abfd)->core->pid
- = bfd_h_get_32 (abfd, (bfd_byte *) note->descdata + 0x20);
-
- /* Command name at 0x48 (max 32 bytes, including nul). */
- elf_tdata (abfd)->core->command
- = _bfd_elfcore_strndup (abfd, note->descdata + 0x48, 31);
-
- return true;
-}
-
-/* Processes Solaris's process status note.
- sig_off ~ offsetof(prstatus_t, pr_cursig)
- pid_off ~ offsetof(prstatus_t, pr_pid)
- lwpid_off ~ offsetof(prstatus_t, pr_who)
- gregset_size ~ sizeof(gregset_t)
- gregset_offset ~ offsetof(prstatus_t, pr_reg) */
-
-static bool
-elfcore_grok_solaris_prstatus (bfd *abfd, Elf_Internal_Note* note, int sig_off,
- int pid_off, int lwpid_off, size_t gregset_size,
- size_t gregset_offset)
-{
- asection *sect = NULL;
- elf_tdata (abfd)->core->signal
- = bfd_get_16 (abfd, note->descdata + sig_off);
- elf_tdata (abfd)->core->pid
- = bfd_get_32 (abfd, note->descdata + pid_off);
- elf_tdata (abfd)->core->lwpid
- = bfd_get_32 (abfd, note->descdata + lwpid_off);
-
- sect = bfd_get_section_by_name (abfd, ".reg");
- if (sect != NULL)
- sect->size = gregset_size;
-
- return _bfd_elfcore_make_pseudosection (abfd, ".reg", gregset_size,
- note->descpos + gregset_offset);
-}
-
-/* Gets program and arguments from a core.
- prog_off ~ offsetof(prpsinfo | psinfo_t, pr_fname)
- comm_off ~ offsetof(prpsinfo | psinfo_t, pr_psargs) */
-
-static bool
-elfcore_grok_solaris_info(bfd *abfd, Elf_Internal_Note* note,
- int prog_off, int comm_off)
-{
- elf_tdata (abfd)->core->program
- = _bfd_elfcore_strndup (abfd, note->descdata + prog_off, 16);
- elf_tdata (abfd)->core->command
- = _bfd_elfcore_strndup (abfd, note->descdata + comm_off, 80);
-
- return true;
-}
-
-/* Processes Solaris's LWP status note.
- gregset_size ~ sizeof(gregset_t)
- gregset_off ~ offsetof(lwpstatus_t, pr_reg)
- fpregset_size ~ sizeof(fpregset_t)
- fpregset_off ~ offsetof(lwpstatus_t, pr_fpreg) */
-
-static bool
-elfcore_grok_solaris_lwpstatus (bfd *abfd, Elf_Internal_Note* note,
- size_t gregset_size, int gregset_off,
- size_t fpregset_size, int fpregset_off)
-{
- asection *sect = NULL;
- char reg2_section_name[16] = { 0 };
-
- (void) snprintf (reg2_section_name, 16, "%s/%i", ".reg2",
- elf_tdata (abfd)->core->lwpid);
-
- /* offsetof(lwpstatus_t, pr_lwpid) */
- elf_tdata (abfd)->core->lwpid
- = bfd_get_32 (abfd, note->descdata + 4);
- /* offsetof(lwpstatus_t, pr_cursig) */
- elf_tdata (abfd)->core->signal
- = bfd_get_16 (abfd, note->descdata + 12);
-
- sect = bfd_get_section_by_name (abfd, ".reg");
- if (sect != NULL)
- sect->size = gregset_size;
- else if (!_bfd_elfcore_make_pseudosection (abfd, ".reg", gregset_size,
- note->descpos + gregset_off))
- return false;
-
- sect = bfd_get_section_by_name (abfd, reg2_section_name);
- if (sect != NULL)
- {
- sect->size = fpregset_size;
- sect->filepos = note->descpos + fpregset_off;
- sect->alignment_power = 2;
- }
- else if (!_bfd_elfcore_make_pseudosection (abfd, ".reg2", fpregset_size,
- note->descpos + fpregset_off))
- return false;
-
- return true;
-}
-
-static bool
-elfcore_grok_solaris_note_impl (bfd *abfd, Elf_Internal_Note *note)
-{
- if (note == NULL)
- return false;
-
- /* core files are identified as 32- or 64-bit, SPARC or x86,
- by the size of the descsz which matches the sizeof()
- the type appropriate for that note type (e.g., prstatus_t for
- SOLARIS_NT_PRSTATUS) for the corresponding architecture
- on Solaris. The core file bitness may differ from the bitness of
- gdb itself, so fixed values are used instead of sizeof().
- Appropriate fixed offsets are also used to obtain data from
- the note. */
-
- switch ((int) note->type)
- {
- case SOLARIS_NT_PRSTATUS:
- switch (note->descsz)
- {
- case 508: /* sizeof(prstatus_t) SPARC 32-bit */
- return elfcore_grok_solaris_prstatus(abfd, note,
- 136, 216, 308, 152, 356);
- case 904: /* sizeof(prstatus_t) SPARC 64-bit */
- return elfcore_grok_solaris_prstatus(abfd, note,
- 264, 360, 520, 304, 600);
- case 432: /* sizeof(prstatus_t) Intel 32-bit */
- return elfcore_grok_solaris_prstatus(abfd, note,
- 136, 216, 308, 76, 356);
- case 824: /* sizeof(prstatus_t) Intel 64-bit */
- return elfcore_grok_solaris_prstatus(abfd, note,
- 264, 360, 520, 224, 600);
- default:
- return true;
- }
-
- case SOLARIS_NT_PSINFO:
- case SOLARIS_NT_PRPSINFO:
- switch (note->descsz)
- {
- case 260: /* sizeof(prpsinfo_t) SPARC and Intel 32-bit */
- return elfcore_grok_solaris_info(abfd, note, 84, 100);
- case 328: /* sizeof(prpsinfo_t) SPARC and Intel 64-bit */
- return elfcore_grok_solaris_info(abfd, note, 120, 136);
- case 360: /* sizeof(psinfo_t) SPARC and Intel 32-bit */
- return elfcore_grok_solaris_info(abfd, note, 88, 104);
- case 440: /* sizeof(psinfo_t) SPARC and Intel 64-bit */
- return elfcore_grok_solaris_info(abfd, note, 136, 152);
- default:
- return true;
- }
-
- case SOLARIS_NT_LWPSTATUS:
- switch (note->descsz)
- {
- case 896: /* sizeof(lwpstatus_t) SPARC 32-bit */
- return elfcore_grok_solaris_lwpstatus(abfd, note,
- 152, 344, 400, 496);
- case 1392: /* sizeof(lwpstatus_t) SPARC 64-bit */
- return elfcore_grok_solaris_lwpstatus(abfd, note,
- 304, 544, 544, 848);
- case 800: /* sizeof(lwpstatus_t) Intel 32-bit */
- return elfcore_grok_solaris_lwpstatus(abfd, note,
- 76, 344, 380, 420);
- case 1296: /* sizeof(lwpstatus_t) Intel 64-bit */
- return elfcore_grok_solaris_lwpstatus(abfd, note,
- 224, 544, 528, 768);
- default:
- return true;
- }
-
- case SOLARIS_NT_LWPSINFO:
- /* sizeof(lwpsinfo_t) on 32- and 64-bit, respectively */
- if (note->descsz == 128 || note->descsz == 152)
- elf_tdata (abfd)->core->lwpid =
- bfd_get_32 (abfd, note->descdata + 4);
- break;
-
- default:
- break;
- }
-
- return true;
-}
-
-/* For name starting with "CORE" this may be either a Solaris
- core file or a gdb-generated core file. Do Solaris-specific
- processing on selected note types first with
- elfcore_grok_solaris_note(), then process the note
- in elfcore_grok_note(). */
-
-static bool
-elfcore_grok_solaris_note (bfd *abfd, Elf_Internal_Note *note)
-{
- if (!elfcore_grok_solaris_note_impl (abfd, note))
- return false;
-
- return elfcore_grok_note (abfd, note);
-}
-
-static bool
-elfcore_grok_openbsd_note (bfd *abfd, Elf_Internal_Note *note)
-{
- if (note->type == NT_OPENBSD_PROCINFO)
- return elfcore_grok_openbsd_procinfo (abfd, note);
-
- if (note->type == NT_OPENBSD_REGS)
- return elfcore_make_note_pseudosection (abfd, ".reg", note);
-
- if (note->type == NT_OPENBSD_FPREGS)
- return elfcore_make_note_pseudosection (abfd, ".reg2", note);
-
- if (note->type == NT_OPENBSD_XFPREGS)
- return elfcore_make_note_pseudosection (abfd, ".reg-xfp", note);
-
- if (note->type == NT_OPENBSD_AUXV)
- return elfcore_make_auxv_note_section (abfd, note, 0);
-
- if (note->type == NT_OPENBSD_WCOOKIE)
- {
- asection *sect = bfd_make_section_anyway_with_flags (abfd, ".wcookie",
- SEC_HAS_CONTENTS);
-
- if (sect == NULL)
- return false;
- sect->size = note->descsz;
- sect->filepos = note->descpos;
- sect->alignment_power = 1 + bfd_get_arch_size (abfd) / 32;
-
- return true;
- }
-
- return true;
-}
-
-static bool
-elfcore_grok_nto_status (bfd *abfd, Elf_Internal_Note *note, long *tid)
-{
- void *ddata = note->descdata;
- char buf[100];
- char *name;
- asection *sect;
- short sig;
- unsigned flags;
-
- if (note->descsz < 16)
- return false;
-
- /* nto_procfs_status 'pid' field is at offset 0. */
- elf_tdata (abfd)->core->pid = bfd_get_32 (abfd, (bfd_byte *) ddata);
-
- /* nto_procfs_status 'tid' field is at offset 4. Pass it back. */
- *tid = bfd_get_32 (abfd, (bfd_byte *) ddata + 4);
-
- /* nto_procfs_status 'flags' field is at offset 8. */
- flags = bfd_get_32 (abfd, (bfd_byte *) ddata + 8);
-
- /* nto_procfs_status 'what' field is at offset 14. */
- if ((sig = bfd_get_16 (abfd, (bfd_byte *) ddata + 14)) > 0)
- {
- elf_tdata (abfd)->core->signal = sig;
- elf_tdata (abfd)->core->lwpid = *tid;
- }
-
- /* _DEBUG_FLAG_CURTID (current thread) is 0x80. Some cores
- do not come from signals so we make sure we set the current
- thread just in case. */
- if (flags & 0x00000080)
- elf_tdata (abfd)->core->lwpid = *tid;
-
- /* Make a ".qnx_core_status/%d" section. */
- sprintf (buf, ".qnx_core_status/%ld", *tid);
-
- name = (char *) bfd_alloc (abfd, strlen (buf) + 1);
- if (name == NULL)
- return false;
- strcpy (name, buf);
-
- sect = bfd_make_section_anyway_with_flags (abfd, name, SEC_HAS_CONTENTS);
- if (sect == NULL)
- return false;
-
- sect->size = note->descsz;
- sect->filepos = note->descpos;
- sect->alignment_power = 2;
-
- return (elfcore_maybe_make_sect (abfd, ".qnx_core_status", sect));
-}
-
-static bool
-elfcore_grok_nto_regs (bfd *abfd,
- Elf_Internal_Note *note,
- long tid,
- char *base)
-{
- char buf[100];
- char *name;
- asection *sect;
-
- /* Make a "(base)/%d" section. */
- sprintf (buf, "%s/%ld", base, tid);
-
- name = (char *) bfd_alloc (abfd, strlen (buf) + 1);
- if (name == NULL)
- return false;
- strcpy (name, buf);
-
- sect = bfd_make_section_anyway_with_flags (abfd, name, SEC_HAS_CONTENTS);
- if (sect == NULL)
- return false;
-
- sect->size = note->descsz;
- sect->filepos = note->descpos;
- sect->alignment_power = 2;
-
- /* This is the current thread. */
- if (elf_tdata (abfd)->core->lwpid == tid)
- return elfcore_maybe_make_sect (abfd, base, sect);
-
- return true;
-}
-
-static bool
-elfcore_grok_nto_note (bfd *abfd, Elf_Internal_Note *note)
-{
- /* Every GREG section has a STATUS section before it. Store the
- tid from the previous call to pass down to the next gregs
- function. */
- static long tid = 1;
-
- switch (note->type)
- {
- case QNT_CORE_INFO:
- return elfcore_make_note_pseudosection (abfd, ".qnx_core_info", note);
- case QNT_CORE_STATUS:
- return elfcore_grok_nto_status (abfd, note, &tid);
- case QNT_CORE_GREG:
- return elfcore_grok_nto_regs (abfd, note, tid, ".reg");
- case QNT_CORE_FPREG:
- return elfcore_grok_nto_regs (abfd, note, tid, ".reg2");
- default:
- return true;
- }
-}
-
-static bool
-elfcore_grok_spu_note (bfd *abfd, Elf_Internal_Note *note)
-{
- char *name;
- asection *sect;
- size_t len;
-
- /* Use note name as section name. */
- len = note->namesz;
- name = (char *) bfd_alloc (abfd, len);
- if (name == NULL)
- return false;
- memcpy (name, note->namedata, len);
- name[len - 1] = '\0';
-
- sect = bfd_make_section_anyway_with_flags (abfd, name, SEC_HAS_CONTENTS);
- if (sect == NULL)
- return false;
-
- sect->size = note->descsz;
- sect->filepos = note->descpos;
- sect->alignment_power = 1;
-
- return true;
-}
-
-/* Function: elfcore_write_note
-
- Inputs:
- buffer to hold note, and current size of buffer
- name of note
- type of note
- data for note
- size of data for note
-
- Writes note to end of buffer. ELF64 notes are written exactly as
- for ELF32, despite the current (as of 2006) ELF gabi specifying
- that they ought to have 8-byte namesz and descsz field, and have
- 8-byte alignment. Other writers, eg. Linux kernel, do the same.
-
- Return:
- Pointer to realloc'd buffer, *BUFSIZ updated. */
-
-char *
-elfcore_write_note (bfd *abfd,
- char *buf,
- int *bufsiz,
- const char *name,
- int type,
- const void *input,
- int size)
-{
- Elf_External_Note *xnp;
- size_t namesz;
- size_t newspace;
- char *dest;
-
- namesz = 0;
- if (name != NULL)
- namesz = strlen (name) + 1;
-
- newspace = 12 + ((namesz + 3) & -4) + ((size + 3) & -4);
-
- buf = (char *) realloc (buf, *bufsiz + newspace);
- if (buf == NULL)
- return buf;
- dest = buf + *bufsiz;
- *bufsiz += newspace;
- xnp = (Elf_External_Note *) dest;
- H_PUT_32 (abfd, namesz, xnp->namesz);
- H_PUT_32 (abfd, size, xnp->descsz);
- H_PUT_32 (abfd, type, xnp->type);
- dest = xnp->name;
- if (name != NULL)
- {
- memcpy (dest, name, namesz);
- dest += namesz;
- while (namesz & 3)
- {
- *dest++ = '\0';
- ++namesz;
- }
- }
- memcpy (dest, input, size);
- dest += size;
- while (size & 3)
- {
- *dest++ = '\0';
- ++size;
- }
- return buf;
-}
-
-/* gcc-8 warns (*) on all the strncpy calls in this function about
- possible string truncation. The "truncation" is not a bug. We
- have an external representation of structs with fields that are not
- necessarily NULL terminated and corresponding internal
- representation fields that are one larger so that they can always
- be NULL terminated.
- gcc versions between 4.2 and 4.6 do not allow pragma control of
- diagnostics inside functions, giving a hard error if you try to use
- the finer control available with later versions.
- gcc prior to 4.2 warns about diagnostic push and pop.
- gcc-5, gcc-6 and gcc-7 warn that -Wstringop-truncation is unknown,
- unless you also add #pragma GCC diagnostic ignored "-Wpragma".
- (*) Depending on your system header files! */
-#if GCC_VERSION >= 8000
-# pragma GCC diagnostic push
-# pragma GCC diagnostic ignored "-Wstringop-truncation"
-#endif
-char *
-elfcore_write_prpsinfo (bfd *abfd,
- char *buf,
- int *bufsiz,
- const char *fname,
- const char *psargs)
-{
- const struct elf_backend_data *bed = get_elf_backend_data (abfd);
-
- if (bed->elf_backend_write_core_note != NULL)
- {
- char *ret;
- ret = (*bed->elf_backend_write_core_note) (abfd, buf, bufsiz,
- NT_PRPSINFO, fname, psargs);
- if (ret != NULL)
- return ret;
- }
-
-#if defined (HAVE_PRPSINFO_T) || defined (HAVE_PSINFO_T)
-# if defined (HAVE_PRPSINFO32_T) || defined (HAVE_PSINFO32_T)
- if (bed->s->elfclass == ELFCLASS32)
- {
-# if defined (HAVE_PSINFO32_T)
- psinfo32_t data;
- int note_type = NT_PSINFO;
-# else
- prpsinfo32_t data;
- int note_type = NT_PRPSINFO;
-# endif
-
- memset (&data, 0, sizeof (data));
- strncpy (data.pr_fname, fname, sizeof (data.pr_fname));
- strncpy (data.pr_psargs, psargs, sizeof (data.pr_psargs));
- return elfcore_write_note (abfd, buf, bufsiz,
- "CORE", note_type, &data, sizeof (data));
- }
- else
-# endif
- {
-# if defined (HAVE_PSINFO_T)
- psinfo_t data;
- int note_type = NT_PSINFO;
-# else
- prpsinfo_t data;
- int note_type = NT_PRPSINFO;
-# endif
-
- memset (&data, 0, sizeof (data));
- strncpy (data.pr_fname, fname, sizeof (data.pr_fname));
- strncpy (data.pr_psargs, psargs, sizeof (data.pr_psargs));
- return elfcore_write_note (abfd, buf, bufsiz,
- "CORE", note_type, &data, sizeof (data));
- }
-#endif /* PSINFO_T or PRPSINFO_T */
-
- free (buf);
- return NULL;
-}
-#if GCC_VERSION >= 8000
-# pragma GCC diagnostic pop
-#endif
-
-char *
-elfcore_write_linux_prpsinfo32
- (bfd *abfd, char *buf, int *bufsiz,
- const struct elf_internal_linux_prpsinfo *prpsinfo)
-{
- if (get_elf_backend_data (abfd)->linux_prpsinfo32_ugid16)
- {
- struct elf_external_linux_prpsinfo32_ugid16 data;
-
- swap_linux_prpsinfo32_ugid16_out (abfd, prpsinfo, &data);
- return elfcore_write_note (abfd, buf, bufsiz, "CORE", NT_PRPSINFO,
- &data, sizeof (data));
- }
- else
- {
- struct elf_external_linux_prpsinfo32_ugid32 data;
-
- swap_linux_prpsinfo32_ugid32_out (abfd, prpsinfo, &data);
- return elfcore_write_note (abfd, buf, bufsiz, "CORE", NT_PRPSINFO,
- &data, sizeof (data));
- }
-}
-
-char *
-elfcore_write_linux_prpsinfo64
- (bfd *abfd, char *buf, int *bufsiz,
- const struct elf_internal_linux_prpsinfo *prpsinfo)
-{
- if (get_elf_backend_data (abfd)->linux_prpsinfo64_ugid16)
- {
- struct elf_external_linux_prpsinfo64_ugid16 data;
-
- swap_linux_prpsinfo64_ugid16_out (abfd, prpsinfo, &data);
- return elfcore_write_note (abfd, buf, bufsiz,
- "CORE", NT_PRPSINFO, &data, sizeof (data));
- }
- else
- {
- struct elf_external_linux_prpsinfo64_ugid32 data;
-
- swap_linux_prpsinfo64_ugid32_out (abfd, prpsinfo, &data);
- return elfcore_write_note (abfd, buf, bufsiz,
- "CORE", NT_PRPSINFO, &data, sizeof (data));
- }
-}
-
-char *
-elfcore_write_prstatus (bfd *abfd,
- char *buf,
- int *bufsiz,
- long pid,
- int cursig,
- const void *gregs)
-{
- const struct elf_backend_data *bed = get_elf_backend_data (abfd);
-
- if (bed->elf_backend_write_core_note != NULL)
- {
- char *ret;
- ret = (*bed->elf_backend_write_core_note) (abfd, buf, bufsiz,
- NT_PRSTATUS,
- pid, cursig, gregs);
- if (ret != NULL)
- return ret;
- }
-
-#if defined (HAVE_PRSTATUS_T)
-#if defined (HAVE_PRSTATUS32_T)
- if (bed->s->elfclass == ELFCLASS32)
- {
- prstatus32_t prstat;
-
- memset (&prstat, 0, sizeof (prstat));
- prstat.pr_pid = pid;
- prstat.pr_cursig = cursig;
- memcpy (&prstat.pr_reg, gregs, sizeof (prstat.pr_reg));
- return elfcore_write_note (abfd, buf, bufsiz, "CORE",
- NT_PRSTATUS, &prstat, sizeof (prstat));
- }
- else
-#endif
- {
- prstatus_t prstat;
-
- memset (&prstat, 0, sizeof (prstat));
- prstat.pr_pid = pid;
- prstat.pr_cursig = cursig;
- memcpy (&prstat.pr_reg, gregs, sizeof (prstat.pr_reg));
- return elfcore_write_note (abfd, buf, bufsiz, "CORE",
- NT_PRSTATUS, &prstat, sizeof (prstat));
- }
-#endif /* HAVE_PRSTATUS_T */
-
- free (buf);
- return NULL;
-}
-
-#if defined (HAVE_LWPSTATUS_T)
-char *
-elfcore_write_lwpstatus (bfd *abfd,
- char *buf,
- int *bufsiz,
- long pid,
- int cursig,
- const void *gregs)
-{
- lwpstatus_t lwpstat;
- const char *note_name = "CORE";
-
- memset (&lwpstat, 0, sizeof (lwpstat));
- lwpstat.pr_lwpid = pid >> 16;
- lwpstat.pr_cursig = cursig;
-#if defined (HAVE_LWPSTATUS_T_PR_REG)
- memcpy (&lwpstat.pr_reg, gregs, sizeof (lwpstat.pr_reg));
-#elif defined (HAVE_LWPSTATUS_T_PR_CONTEXT)
-#if !defined(gregs)
- memcpy (lwpstat.pr_context.uc_mcontext.gregs,
- gregs, sizeof (lwpstat.pr_context.uc_mcontext.gregs));
-#else
- memcpy (lwpstat.pr_context.uc_mcontext.__gregs,
- gregs, sizeof (lwpstat.pr_context.uc_mcontext.__gregs));
-#endif
-#endif
- return elfcore_write_note (abfd, buf, bufsiz, note_name,
- NT_LWPSTATUS, &lwpstat, sizeof (lwpstat));
-}
-#endif /* HAVE_LWPSTATUS_T */
-
-#if defined (HAVE_PSTATUS_T)
-char *
-elfcore_write_pstatus (bfd *abfd,
- char *buf,
- int *bufsiz,
- long pid,
- int cursig ATTRIBUTE_UNUSED,
- const void *gregs ATTRIBUTE_UNUSED)
-{
- const char *note_name = "CORE";
-#if defined (HAVE_PSTATUS32_T)
- const struct elf_backend_data *bed = get_elf_backend_data (abfd);
-
- if (bed->s->elfclass == ELFCLASS32)
- {
- pstatus32_t pstat;
-
- memset (&pstat, 0, sizeof (pstat));
- pstat.pr_pid = pid & 0xffff;
- buf = elfcore_write_note (abfd, buf, bufsiz, note_name,
- NT_PSTATUS, &pstat, sizeof (pstat));
- return buf;
- }
- else
-#endif
- {
- pstatus_t pstat;
-
- memset (&pstat, 0, sizeof (pstat));
- pstat.pr_pid = pid & 0xffff;
- buf = elfcore_write_note (abfd, buf, bufsiz, note_name,
- NT_PSTATUS, &pstat, sizeof (pstat));
- return buf;
- }
-}
-#endif /* HAVE_PSTATUS_T */
-
-char *
-elfcore_write_prfpreg (bfd *abfd,
- char *buf,
- int *bufsiz,
- const void *fpregs,
- int size)
-{
- const char *note_name = "CORE";
- return elfcore_write_note (abfd, buf, bufsiz,
- note_name, NT_FPREGSET, fpregs, size);
-}
-
-char *
-elfcore_write_prxfpreg (bfd *abfd,
- char *buf,
- int *bufsiz,
- const void *xfpregs,
- int size)
-{
- char *note_name = "LINUX";
- return elfcore_write_note (abfd, buf, bufsiz,
- note_name, NT_PRXFPREG, xfpregs, size);
-}
-
-char *
-elfcore_write_xstatereg (bfd *abfd, char *buf, int *bufsiz,
- const void *xfpregs, int size)
-{
- char *note_name;
- if (get_elf_backend_data (abfd)->elf_osabi == ELFOSABI_FREEBSD)
- note_name = "FreeBSD";
- else
- note_name = "LINUX";
- return elfcore_write_note (abfd, buf, bufsiz,
- note_name, NT_X86_XSTATE, xfpregs, size);
-}
-
-char *
-elfcore_write_x86_segbases (bfd *abfd, char *buf, int *bufsiz,
- const void *regs, int size)
-{
- char *note_name = "FreeBSD";
- return elfcore_write_note (abfd, buf, bufsiz,
- note_name, NT_FREEBSD_X86_SEGBASES, regs, size);
-}
-
-char *
-elfcore_write_ppc_vmx (bfd *abfd,
- char *buf,
- int *bufsiz,
- const void *ppc_vmx,
- int size)
-{
- char *note_name = "LINUX";
- return elfcore_write_note (abfd, buf, bufsiz,
- note_name, NT_PPC_VMX, ppc_vmx, size);
-}
-
-char *
-elfcore_write_ppc_vsx (bfd *abfd,
- char *buf,
- int *bufsiz,
- const void *ppc_vsx,
- int size)
-{
- char *note_name = "LINUX";
- return elfcore_write_note (abfd, buf, bufsiz,
- note_name, NT_PPC_VSX, ppc_vsx, size);
-}
-
-char *
-elfcore_write_ppc_tar (bfd *abfd,
- char *buf,
- int *bufsiz,
- const void *ppc_tar,
- int size)
-{
- char *note_name = "LINUX";
- return elfcore_write_note (abfd, buf, bufsiz,
- note_name, NT_PPC_TAR, ppc_tar, size);
-}
-
-char *
-elfcore_write_ppc_ppr (bfd *abfd,
- char *buf,
- int *bufsiz,
- const void *ppc_ppr,
- int size)
-{
- char *note_name = "LINUX";
- return elfcore_write_note (abfd, buf, bufsiz,
- note_name, NT_PPC_PPR, ppc_ppr, size);
-}
-
-char *
-elfcore_write_ppc_dscr (bfd *abfd,
- char *buf,
- int *bufsiz,
- const void *ppc_dscr,
- int size)
-{
- char *note_name = "LINUX";
- return elfcore_write_note (abfd, buf, bufsiz,
- note_name, NT_PPC_DSCR, ppc_dscr, size);
-}
-
-char *
-elfcore_write_ppc_ebb (bfd *abfd,
- char *buf,
- int *bufsiz,
- const void *ppc_ebb,
- int size)
-{
- char *note_name = "LINUX";
- return elfcore_write_note (abfd, buf, bufsiz,
- note_name, NT_PPC_EBB, ppc_ebb, size);
-}
-
-char *
-elfcore_write_ppc_pmu (bfd *abfd,
- char *buf,
- int *bufsiz,
- const void *ppc_pmu,
- int size)
-{
- char *note_name = "LINUX";
- return elfcore_write_note (abfd, buf, bufsiz,
- note_name, NT_PPC_PMU, ppc_pmu, size);
-}
-
-char *
-elfcore_write_ppc_tm_cgpr (bfd *abfd,
- char *buf,
- int *bufsiz,
- const void *ppc_tm_cgpr,
- int size)
-{
- char *note_name = "LINUX";
- return elfcore_write_note (abfd, buf, bufsiz,
- note_name, NT_PPC_TM_CGPR, ppc_tm_cgpr, size);
-}
-
-char *
-elfcore_write_ppc_tm_cfpr (bfd *abfd,
- char *buf,
- int *bufsiz,
- const void *ppc_tm_cfpr,
- int size)
-{
- char *note_name = "LINUX";
- return elfcore_write_note (abfd, buf, bufsiz,
- note_name, NT_PPC_TM_CFPR, ppc_tm_cfpr, size);
-}
-
-char *
-elfcore_write_ppc_tm_cvmx (bfd *abfd,
- char *buf,
- int *bufsiz,
- const void *ppc_tm_cvmx,
- int size)
-{
- char *note_name = "LINUX";
- return elfcore_write_note (abfd, buf, bufsiz,
- note_name, NT_PPC_TM_CVMX, ppc_tm_cvmx, size);
-}
-
-char *
-elfcore_write_ppc_tm_cvsx (bfd *abfd,
- char *buf,
- int *bufsiz,
- const void *ppc_tm_cvsx,
- int size)
-{
- char *note_name = "LINUX";
- return elfcore_write_note (abfd, buf, bufsiz,
- note_name, NT_PPC_TM_CVSX, ppc_tm_cvsx, size);
-}
-
-char *
-elfcore_write_ppc_tm_spr (bfd *abfd,
- char *buf,
- int *bufsiz,
- const void *ppc_tm_spr,
- int size)
-{
- char *note_name = "LINUX";
- return elfcore_write_note (abfd, buf, bufsiz,
- note_name, NT_PPC_TM_SPR, ppc_tm_spr, size);
-}
-
-char *
-elfcore_write_ppc_tm_ctar (bfd *abfd,
- char *buf,
- int *bufsiz,
- const void *ppc_tm_ctar,
- int size)
-{
- char *note_name = "LINUX";
- return elfcore_write_note (abfd, buf, bufsiz,
- note_name, NT_PPC_TM_CTAR, ppc_tm_ctar, size);
-}
-
-char *
-elfcore_write_ppc_tm_cppr (bfd *abfd,
- char *buf,
- int *bufsiz,
- const void *ppc_tm_cppr,
- int size)
-{
- char *note_name = "LINUX";
- return elfcore_write_note (abfd, buf, bufsiz,
- note_name, NT_PPC_TM_CPPR, ppc_tm_cppr, size);
-}
-
-char *
-elfcore_write_ppc_tm_cdscr (bfd *abfd,
- char *buf,
- int *bufsiz,
- const void *ppc_tm_cdscr,
- int size)
-{
- char *note_name = "LINUX";
- return elfcore_write_note (abfd, buf, bufsiz,
- note_name, NT_PPC_TM_CDSCR, ppc_tm_cdscr, size);
-}
-
-static char *
-elfcore_write_s390_high_gprs (bfd *abfd,
- char *buf,
- int *bufsiz,
- const void *s390_high_gprs,
- int size)
-{
- char *note_name = "LINUX";
- return elfcore_write_note (abfd, buf, bufsiz,
- note_name, NT_S390_HIGH_GPRS,
- s390_high_gprs, size);
-}
-
-char *
-elfcore_write_s390_timer (bfd *abfd,
- char *buf,
- int *bufsiz,
- const void *s390_timer,
- int size)
-{
- char *note_name = "LINUX";
- return elfcore_write_note (abfd, buf, bufsiz,
- note_name, NT_S390_TIMER, s390_timer, size);
-}
-
-char *
-elfcore_write_s390_todcmp (bfd *abfd,
- char *buf,
- int *bufsiz,
- const void *s390_todcmp,
- int size)
-{
- char *note_name = "LINUX";
- return elfcore_write_note (abfd, buf, bufsiz,
- note_name, NT_S390_TODCMP, s390_todcmp, size);
-}
-
-char *
-elfcore_write_s390_todpreg (bfd *abfd,
- char *buf,
- int *bufsiz,
- const void *s390_todpreg,
- int size)
-{
- char *note_name = "LINUX";
- return elfcore_write_note (abfd, buf, bufsiz,
- note_name, NT_S390_TODPREG, s390_todpreg, size);
-}
-
-char *
-elfcore_write_s390_ctrs (bfd *abfd,
- char *buf,
- int *bufsiz,
- const void *s390_ctrs,
- int size)
-{
- char *note_name = "LINUX";
- return elfcore_write_note (abfd, buf, bufsiz,
- note_name, NT_S390_CTRS, s390_ctrs, size);
-}
-
-char *
-elfcore_write_s390_prefix (bfd *abfd,
- char *buf,
- int *bufsiz,
- const void *s390_prefix,
- int size)
-{
- char *note_name = "LINUX";
- return elfcore_write_note (abfd, buf, bufsiz,
- note_name, NT_S390_PREFIX, s390_prefix, size);
-}
-
-char *
-elfcore_write_s390_last_break (bfd *abfd,
- char *buf,
- int *bufsiz,
- const void *s390_last_break,
- int size)
-{
- char *note_name = "LINUX";
- return elfcore_write_note (abfd, buf, bufsiz,
- note_name, NT_S390_LAST_BREAK,
- s390_last_break, size);
-}
-
-char *
-elfcore_write_s390_system_call (bfd *abfd,
- char *buf,
- int *bufsiz,
- const void *s390_system_call,
- int size)
-{
- char *note_name = "LINUX";
- return elfcore_write_note (abfd, buf, bufsiz,
- note_name, NT_S390_SYSTEM_CALL,
- s390_system_call, size);
-}
-
-char *
-elfcore_write_s390_tdb (bfd *abfd,
- char *buf,
- int *bufsiz,
- const void *s390_tdb,
- int size)
-{
- char *note_name = "LINUX";
- return elfcore_write_note (abfd, buf, bufsiz,
- note_name, NT_S390_TDB, s390_tdb, size);
-}
-
-char *
-elfcore_write_s390_vxrs_low (bfd *abfd,
- char *buf,
- int *bufsiz,
- const void *s390_vxrs_low,
- int size)
-{
- char *note_name = "LINUX";
- return elfcore_write_note (abfd, buf, bufsiz,
- note_name, NT_S390_VXRS_LOW, s390_vxrs_low, size);
-}
-
-char *
-elfcore_write_s390_vxrs_high (bfd *abfd,
- char *buf,
- int *bufsiz,
- const void *s390_vxrs_high,
- int size)
-{
- char *note_name = "LINUX";
- return elfcore_write_note (abfd, buf, bufsiz,
- note_name, NT_S390_VXRS_HIGH,
- s390_vxrs_high, size);
-}
-
-char *
-elfcore_write_s390_gs_cb (bfd *abfd,
- char *buf,
- int *bufsiz,
- const void *s390_gs_cb,
- int size)
-{
- char *note_name = "LINUX";
- return elfcore_write_note (abfd, buf, bufsiz,
- note_name, NT_S390_GS_CB,
- s390_gs_cb, size);
-}
-
-char *
-elfcore_write_s390_gs_bc (bfd *abfd,
- char *buf,
- int *bufsiz,
- const void *s390_gs_bc,
- int size)
-{
- char *note_name = "LINUX";
- return elfcore_write_note (abfd, buf, bufsiz,
- note_name, NT_S390_GS_BC,
- s390_gs_bc, size);
-}
-
-char *
-elfcore_write_arm_vfp (bfd *abfd,
- char *buf,
- int *bufsiz,
- const void *arm_vfp,
- int size)
-{
- char *note_name = "LINUX";
- return elfcore_write_note (abfd, buf, bufsiz,
- note_name, NT_ARM_VFP, arm_vfp, size);
-}
-
-char *
-elfcore_write_aarch_tls (bfd *abfd,
- char *buf,
- int *bufsiz,
- const void *aarch_tls,
- int size)
-{
- char *note_name = "LINUX";
- return elfcore_write_note (abfd, buf, bufsiz,
- note_name, NT_ARM_TLS, aarch_tls, size);
-}
-
-char *
-elfcore_write_aarch_hw_break (bfd *abfd,
- char *buf,
- int *bufsiz,
- const void *aarch_hw_break,
- int size)
-{
- char *note_name = "LINUX";
- return elfcore_write_note (abfd, buf, bufsiz,
- note_name, NT_ARM_HW_BREAK, aarch_hw_break, size);
-}
-
-char *
-elfcore_write_aarch_hw_watch (bfd *abfd,
- char *buf,
- int *bufsiz,
- const void *aarch_hw_watch,
- int size)
-{
- char *note_name = "LINUX";
- return elfcore_write_note (abfd, buf, bufsiz,
- note_name, NT_ARM_HW_WATCH, aarch_hw_watch, size);
-}
-
-char *
-elfcore_write_aarch_sve (bfd *abfd,
- char *buf,
- int *bufsiz,
- const void *aarch_sve,
- int size)
-{
- char *note_name = "LINUX";
- return elfcore_write_note (abfd, buf, bufsiz,
- note_name, NT_ARM_SVE, aarch_sve, size);
-}
-
-char *
-elfcore_write_aarch_pauth (bfd *abfd,
- char *buf,
- int *bufsiz,
- const void *aarch_pauth,
- int size)
-{
- char *note_name = "LINUX";
- return elfcore_write_note (abfd, buf, bufsiz,
- note_name, NT_ARM_PAC_MASK, aarch_pauth, size);
-}
-
-char *
-elfcore_write_aarch_mte (bfd *abfd,
- char *buf,
- int *bufsiz,
- const void *aarch_mte,
- int size)
-{
- char *note_name = "LINUX";
- return elfcore_write_note (abfd, buf, bufsiz,
- note_name, NT_ARM_TAGGED_ADDR_CTRL,
- aarch_mte,
- size);
-}
-
-char *
-elfcore_write_aarch_ssve (bfd *abfd,
- char *buf,
- int *bufsiz,
- const void *aarch_ssve,
- int size)
-{
- char *note_name = "LINUX";
- return elfcore_write_note (abfd, buf, bufsiz,
- note_name, NT_ARM_SSVE,
- aarch_ssve,
- size);
-}
-
-char *
-elfcore_write_aarch_za (bfd *abfd,
- char *buf,
- int *bufsiz,
- const void *aarch_za,
- int size)
-{
- char *note_name = "LINUX";
- return elfcore_write_note (abfd, buf, bufsiz,
- note_name, NT_ARM_ZA,
- aarch_za,
- size);
-}
-
-/* Write the buffer of zt register values in aarch_zt (length SIZE) into
- the note buffer BUF and update *BUFSIZ. ABFD is the bfd the note is being
- written into. Return a pointer to the new start of the note buffer, to
- replace BUF which may no longer be valid. */
-
-char *
-elfcore_write_aarch_zt (bfd *abfd,
- char *buf,
- int *bufsiz,
- const void *aarch_zt,
- int size)
-{
- char *note_name = "LINUX";
- return elfcore_write_note (abfd, buf, bufsiz,
- note_name, NT_ARM_ZT,
- aarch_zt,
- size);
-}
-
-char *
-elfcore_write_arc_v2 (bfd *abfd,
- char *buf,
- int *bufsiz,
- const void *arc_v2,
- int size)
-{
- char *note_name = "LINUX";
- return elfcore_write_note (abfd, buf, bufsiz,
- note_name, NT_ARC_V2, arc_v2, size);
-}
-
-char *
-elfcore_write_loongarch_cpucfg (bfd *abfd,
- char *buf,
- int *bufsiz,
- const void *loongarch_cpucfg,
- int size)
-{
- char *note_name = "LINUX";
- return elfcore_write_note (abfd, buf, bufsiz,
- note_name, NT_LARCH_CPUCFG,
- loongarch_cpucfg, size);
-}
-
-char *
-elfcore_write_loongarch_lbt (bfd *abfd,
- char *buf,
- int *bufsiz,
- const void *loongarch_lbt,
- int size)
-{
- char *note_name = "LINUX";
- return elfcore_write_note (abfd, buf, bufsiz,
- note_name, NT_LARCH_LBT, loongarch_lbt, size);
-}
-
-char *
-elfcore_write_loongarch_lsx (bfd *abfd,
- char *buf,
- int *bufsiz,
- const void *loongarch_lsx,
- int size)
-{
- char *note_name = "LINUX";
- return elfcore_write_note (abfd, buf, bufsiz,
- note_name, NT_LARCH_LSX, loongarch_lsx, size);
-}
-
-char *
-elfcore_write_loongarch_lasx (bfd *abfd,
- char *buf,
- int *bufsiz,
- const void *loongarch_lasx,
- int size)
-{
- char *note_name = "LINUX";
- return elfcore_write_note (abfd, buf, bufsiz,
- note_name, NT_LARCH_LASX, loongarch_lasx, size);
-}
-
-/* Write the buffer of csr values in CSRS (length SIZE) into the note
- buffer BUF and update *BUFSIZ. ABFD is the bfd the note is being
- written into. Return a pointer to the new start of the note buffer, to
- replace BUF which may no longer be valid. */
-
-char *
-elfcore_write_riscv_csr (bfd *abfd,
- char *buf,
- int *bufsiz,
- const void *csrs,
- int size)
-{
- const char *note_name = "GDB";
- return elfcore_write_note (abfd, buf, bufsiz,
- note_name, NT_RISCV_CSR, csrs, size);
-}
-
-/* Write the target description (a string) pointed to by TDESC, length
- SIZE, into the note buffer BUF, and update *BUFSIZ. ABFD is the bfd the
- note is being written into. Return a pointer to the new start of the
- note buffer, to replace BUF which may no longer be valid. */
-
-char *
-elfcore_write_gdb_tdesc (bfd *abfd,
- char *buf,
- int *bufsiz,
- const void *tdesc,
- int size)
-{
- const char *note_name = "GDB";
- return elfcore_write_note (abfd, buf, bufsiz,
- note_name, NT_GDB_TDESC, tdesc, size);
-}
-
-char *
-elfcore_write_register_note (bfd *abfd,
- char *buf,
- int *bufsiz,
- const char *section,
- const void *data,
- int size)
-{
- if (strcmp (section, ".reg2") == 0)
- return elfcore_write_prfpreg (abfd, buf, bufsiz, data, size);
- if (strcmp (section, ".reg-xfp") == 0)
- return elfcore_write_prxfpreg (abfd, buf, bufsiz, data, size);
- if (strcmp (section, ".reg-xstate") == 0)
- return elfcore_write_xstatereg (abfd, buf, bufsiz, data, size);
- if (strcmp (section, ".reg-x86-segbases") == 0)
- return elfcore_write_x86_segbases (abfd, buf, bufsiz, data, size);
- if (strcmp (section, ".reg-ppc-vmx") == 0)
- return elfcore_write_ppc_vmx (abfd, buf, bufsiz, data, size);
- if (strcmp (section, ".reg-ppc-vsx") == 0)
- return elfcore_write_ppc_vsx (abfd, buf, bufsiz, data, size);
- if (strcmp (section, ".reg-ppc-tar") == 0)
- return elfcore_write_ppc_tar (abfd, buf, bufsiz, data, size);
- if (strcmp (section, ".reg-ppc-ppr") == 0)
- return elfcore_write_ppc_ppr (abfd, buf, bufsiz, data, size);
- if (strcmp (section, ".reg-ppc-dscr") == 0)
- return elfcore_write_ppc_dscr (abfd, buf, bufsiz, data, size);
- if (strcmp (section, ".reg-ppc-ebb") == 0)
- return elfcore_write_ppc_ebb (abfd, buf, bufsiz, data, size);
- if (strcmp (section, ".reg-ppc-pmu") == 0)
- return elfcore_write_ppc_pmu (abfd, buf, bufsiz, data, size);
- if (strcmp (section, ".reg-ppc-tm-cgpr") == 0)
- return elfcore_write_ppc_tm_cgpr (abfd, buf, bufsiz, data, size);
- if (strcmp (section, ".reg-ppc-tm-cfpr") == 0)
- return elfcore_write_ppc_tm_cfpr (abfd, buf, bufsiz, data, size);
- if (strcmp (section, ".reg-ppc-tm-cvmx") == 0)
- return elfcore_write_ppc_tm_cvmx (abfd, buf, bufsiz, data, size);
- if (strcmp (section, ".reg-ppc-tm-cvsx") == 0)
- return elfcore_write_ppc_tm_cvsx (abfd, buf, bufsiz, data, size);
- if (strcmp (section, ".reg-ppc-tm-spr") == 0)
- return elfcore_write_ppc_tm_spr (abfd, buf, bufsiz, data, size);
- if (strcmp (section, ".reg-ppc-tm-ctar") == 0)
- return elfcore_write_ppc_tm_ctar (abfd, buf, bufsiz, data, size);
- if (strcmp (section, ".reg-ppc-tm-cppr") == 0)
- return elfcore_write_ppc_tm_cppr (abfd, buf, bufsiz, data, size);
- if (strcmp (section, ".reg-ppc-tm-cdscr") == 0)
- return elfcore_write_ppc_tm_cdscr (abfd, buf, bufsiz, data, size);
- if (strcmp (section, ".reg-s390-high-gprs") == 0)
- return elfcore_write_s390_high_gprs (abfd, buf, bufsiz, data, size);
- if (strcmp (section, ".reg-s390-timer") == 0)
- return elfcore_write_s390_timer (abfd, buf, bufsiz, data, size);
- if (strcmp (section, ".reg-s390-todcmp") == 0)
- return elfcore_write_s390_todcmp (abfd, buf, bufsiz, data, size);
- if (strcmp (section, ".reg-s390-todpreg") == 0)
- return elfcore_write_s390_todpreg (abfd, buf, bufsiz, data, size);
- if (strcmp (section, ".reg-s390-ctrs") == 0)
- return elfcore_write_s390_ctrs (abfd, buf, bufsiz, data, size);
- if (strcmp (section, ".reg-s390-prefix") == 0)
- return elfcore_write_s390_prefix (abfd, buf, bufsiz, data, size);
- if (strcmp (section, ".reg-s390-last-break") == 0)
- return elfcore_write_s390_last_break (abfd, buf, bufsiz, data, size);
- if (strcmp (section, ".reg-s390-system-call") == 0)
- return elfcore_write_s390_system_call (abfd, buf, bufsiz, data, size);
- if (strcmp (section, ".reg-s390-tdb") == 0)
- return elfcore_write_s390_tdb (abfd, buf, bufsiz, data, size);
- if (strcmp (section, ".reg-s390-vxrs-low") == 0)
- return elfcore_write_s390_vxrs_low (abfd, buf, bufsiz, data, size);
- if (strcmp (section, ".reg-s390-vxrs-high") == 0)
- return elfcore_write_s390_vxrs_high (abfd, buf, bufsiz, data, size);
- if (strcmp (section, ".reg-s390-gs-cb") == 0)
- return elfcore_write_s390_gs_cb (abfd, buf, bufsiz, data, size);
- if (strcmp (section, ".reg-s390-gs-bc") == 0)
- return elfcore_write_s390_gs_bc (abfd, buf, bufsiz, data, size);
- if (strcmp (section, ".reg-arm-vfp") == 0)
- return elfcore_write_arm_vfp (abfd, buf, bufsiz, data, size);
- if (strcmp (section, ".reg-aarch-tls") == 0)
- return elfcore_write_aarch_tls (abfd, buf, bufsiz, data, size);
- if (strcmp (section, ".reg-aarch-hw-break") == 0)
- return elfcore_write_aarch_hw_break (abfd, buf, bufsiz, data, size);
- if (strcmp (section, ".reg-aarch-hw-watch") == 0)
- return elfcore_write_aarch_hw_watch (abfd, buf, bufsiz, data, size);
- if (strcmp (section, ".reg-aarch-sve") == 0)
- return elfcore_write_aarch_sve (abfd, buf, bufsiz, data, size);
- if (strcmp (section, ".reg-aarch-pauth") == 0)
- return elfcore_write_aarch_pauth (abfd, buf, bufsiz, data, size);
- if (strcmp (section, ".reg-aarch-mte") == 0)
- return elfcore_write_aarch_mte (abfd, buf, bufsiz, data, size);
- if (strcmp (section, ".reg-aarch-ssve") == 0)
- return elfcore_write_aarch_ssve (abfd, buf, bufsiz, data, size);
- if (strcmp (section, ".reg-aarch-za") == 0)
- return elfcore_write_aarch_za (abfd, buf, bufsiz, data, size);
- if (strcmp (section, ".reg-aarch-zt") == 0)
- return elfcore_write_aarch_zt (abfd, buf, bufsiz, data, size);
- if (strcmp (section, ".reg-arc-v2") == 0)
- return elfcore_write_arc_v2 (abfd, buf, bufsiz, data, size);
- if (strcmp (section, ".gdb-tdesc") == 0)
- return elfcore_write_gdb_tdesc (abfd, buf, bufsiz, data, size);
- if (strcmp (section, ".reg-riscv-csr") == 0)
- return elfcore_write_riscv_csr (abfd, buf, bufsiz, data, size);
- if (strcmp (section, ".reg-loongarch-cpucfg") == 0)
- return elfcore_write_loongarch_cpucfg (abfd, buf, bufsiz, data, size);
- if (strcmp (section, ".reg-loongarch-lbt") == 0)
- return elfcore_write_loongarch_lbt (abfd, buf, bufsiz, data, size);
- if (strcmp (section, ".reg-loongarch-lsx") == 0)
- return elfcore_write_loongarch_lsx (abfd, buf, bufsiz, data, size);
- if (strcmp (section, ".reg-loongarch-lasx") == 0)
- return elfcore_write_loongarch_lasx (abfd, buf, bufsiz, data, size);
- return NULL;
-}
-
-char *
-elfcore_write_file_note (bfd *obfd, char *note_data, int *note_size,
- const void *buf, int bufsiz)
-{
- return elfcore_write_note (obfd, note_data, note_size,
- "CORE", NT_FILE, buf, bufsiz);
-}
-
-static bool
-elf_parse_notes (bfd *abfd, char *buf, size_t size, file_ptr offset,
- size_t align)
-{
- char *p;
-
- /* NB: CORE PT_NOTE segments may have p_align values of 0 or 1.
- gABI specifies that PT_NOTE alignment should be aligned to 4
- bytes for 32-bit objects and to 8 bytes for 64-bit objects. If
- align is less than 4, we use 4 byte alignment. */
- if (align < 4)
- align = 4;
- if (align != 4 && align != 8)
- return false;
-
- p = buf;
- while (p < buf + size)
- {
- Elf_External_Note *xnp = (Elf_External_Note *) p;
- Elf_Internal_Note in;
-
- if (offsetof (Elf_External_Note, name) > buf - p + size)
- return false;
-
- in.type = H_GET_32 (abfd, xnp->type);
-
- in.namesz = H_GET_32 (abfd, xnp->namesz);
- in.namedata = xnp->name;
- if (in.namesz > buf - in.namedata + size)
- return false;
-
- in.descsz = H_GET_32 (abfd, xnp->descsz);
- in.descdata = p + ELF_NOTE_DESC_OFFSET (in.namesz, align);
- in.descpos = offset + (in.descdata - buf);
- if (in.descsz != 0
- && (in.descdata >= buf + size
- || in.descsz > buf - in.descdata + size))
- return false;
-
- switch (bfd_get_format (abfd))
- {
- default:
- return true;
-
- case bfd_core:
- {
-#define GROKER_ELEMENT(S,F) {S, sizeof (S) - 1, F}
- struct
- {
- const char * string;
- size_t len;
- bool (*func) (bfd *, Elf_Internal_Note *);
- }
- grokers[] =
- {
- GROKER_ELEMENT ("", elfcore_grok_note),
- GROKER_ELEMENT ("FreeBSD", elfcore_grok_freebsd_note),
- GROKER_ELEMENT ("NetBSD-CORE", elfcore_grok_netbsd_note),
- GROKER_ELEMENT ("OpenBSD", elfcore_grok_openbsd_note),
- GROKER_ELEMENT ("QNX", elfcore_grok_nto_note),
- GROKER_ELEMENT ("SPU/", elfcore_grok_spu_note),
- GROKER_ELEMENT ("GNU", elfobj_grok_gnu_note),
- GROKER_ELEMENT ("CORE", elfcore_grok_solaris_note)
- };
-#undef GROKER_ELEMENT
- int i;
-
- for (i = ARRAY_SIZE (grokers); i--;)
- {
- if (in.namesz >= grokers[i].len
- && strncmp (in.namedata, grokers[i].string,
- grokers[i].len) == 0)
- {
- if (! grokers[i].func (abfd, & in))
- return false;
- break;
- }
- }
- break;
- }
-
- case bfd_object:
- if (in.namesz == sizeof "GNU" && strcmp (in.namedata, "GNU") == 0)
- {
- if (! elfobj_grok_gnu_note (abfd, &in))
- return false;
- }
- else if (in.namesz == sizeof "stapsdt"
- && strcmp (in.namedata, "stapsdt") == 0)
- {
- if (! elfobj_grok_stapsdt_note (abfd, &in))
- return false;
- }
- break;
- }
-
- p += ELF_NOTE_NEXT_OFFSET (in.namesz, in.descsz, align);
- }
-
- return true;
-}
-
-bool
-elf_read_notes (bfd *abfd, file_ptr offset, bfd_size_type size,
- size_t align)
-{
- char *buf;
-
- if (size == 0 || (size + 1) == 0)
- return true;
-
- if (bfd_seek (abfd, offset, SEEK_SET) != 0)
- return false;
-
- buf = (char *) _bfd_malloc_and_read (abfd, size + 1, size);
- if (buf == NULL)
- return false;
-
- /* PR 17512: file: ec08f814
- 0-termintate the buffer so that string searches will not overflow. */
- buf[size] = 0;
-
- if (!elf_parse_notes (abfd, buf, size, offset, align))
- {
- free (buf);
- return false;
- }
-
- free (buf);
- return true;
-}
-
-/* Providing external access to the ELF program header table. */
-
-/* Return an upper bound on the number of bytes required to store a
- copy of ABFD's program header table entries. Return -1 if an error
- occurs; bfd_get_error will return an appropriate code. */
-
-long
-bfd_get_elf_phdr_upper_bound (bfd *abfd)
-{
- if (abfd->xvec->flavour != bfd_target_elf_flavour)
- {
- bfd_set_error (bfd_error_wrong_format);
- return -1;
- }
-
- return elf_elfheader (abfd)->e_phnum * sizeof (Elf_Internal_Phdr);
-}
-
-/* Copy ABFD's program header table entries to *PHDRS. The entries
- will be stored as an array of Elf_Internal_Phdr structures, as
- defined in include/elf/internal.h. To find out how large the
- buffer needs to be, call bfd_get_elf_phdr_upper_bound.
-
- Return the number of program header table entries read, or -1 if an
- error occurs; bfd_get_error will return an appropriate code. */
-
-int
-bfd_get_elf_phdrs (bfd *abfd, void *phdrs)
-{
- int num_phdrs;
-
- if (abfd->xvec->flavour != bfd_target_elf_flavour)
- {
- bfd_set_error (bfd_error_wrong_format);
- return -1;
- }
-
- num_phdrs = elf_elfheader (abfd)->e_phnum;
- if (num_phdrs != 0)
- memcpy (phdrs, elf_tdata (abfd)->phdr,
- num_phdrs * sizeof (Elf_Internal_Phdr));
-
- return num_phdrs;
-}
-
-enum elf_reloc_type_class
-_bfd_elf_reloc_type_class (const struct bfd_link_info *info ATTRIBUTE_UNUSED,
- const asection *rel_sec ATTRIBUTE_UNUSED,
- const Elf_Internal_Rela *rela ATTRIBUTE_UNUSED)
-{
- return reloc_class_normal;
-}
-
-/* For RELA architectures, return the relocation value for a
- relocation against a local symbol. */
-
-bfd_vma
-_bfd_elf_rela_local_sym (bfd *abfd,
- Elf_Internal_Sym *sym,
- asection **psec,
- Elf_Internal_Rela *rel)
-{
- asection *sec = *psec;
- bfd_vma relocation;
-
- relocation = (sec->output_section->vma
- + sec->output_offset
- + sym->st_value);
- if ((sec->flags & SEC_MERGE)
- && ELF_ST_TYPE (sym->st_info) == STT_SECTION
- && sec->sec_info_type == SEC_INFO_TYPE_MERGE)
- {
- rel->r_addend =
- _bfd_merged_section_offset (abfd, psec,
- elf_section_data (sec)->sec_info,
- sym->st_value + rel->r_addend);
- if (sec != *psec)
- {
- /* If we have changed the section, and our original section is
- marked with SEC_EXCLUDE, it means that the original
- SEC_MERGE section has been completely subsumed in some
- other SEC_MERGE section. In this case, we need to leave
- some info around for --emit-relocs. */
- if ((sec->flags & SEC_EXCLUDE) != 0)
- sec->kept_section = *psec;
- sec = *psec;
- }
- rel->r_addend -= relocation;
- rel->r_addend += sec->output_section->vma + sec->output_offset;
- }
- return relocation;
-}
-
-bfd_vma
-_bfd_elf_rel_local_sym (bfd *abfd,
- Elf_Internal_Sym *sym,
- asection **psec,
- bfd_vma addend)
-{
- asection *sec = *psec;
-
- if (sec->sec_info_type != SEC_INFO_TYPE_MERGE)
- return sym->st_value + addend;
-
- return _bfd_merged_section_offset (abfd, psec,
- elf_section_data (sec)->sec_info,
- sym->st_value + addend);
-}
-
-/* Adjust an address within a section. Given OFFSET within SEC, return
- the new offset within the section, based upon changes made to the
- section. Returns -1 if the offset is now invalid.
- The offset (in abnd out) is in target sized bytes, however big a
- byte may be. */
-
-bfd_vma
-_bfd_elf_section_offset (bfd *abfd,
- struct bfd_link_info *info,
- asection *sec,
- bfd_vma offset)
-{
- switch (sec->sec_info_type)
- {
- case SEC_INFO_TYPE_STABS:
- return _bfd_stab_section_offset (sec, elf_section_data (sec)->sec_info,
- offset);
- case SEC_INFO_TYPE_EH_FRAME:
- return _bfd_elf_eh_frame_section_offset (abfd, info, sec, offset);
-
- default:
- if ((sec->flags & SEC_ELF_REVERSE_COPY) != 0)
- {
- /* Reverse the offset. */
- const struct elf_backend_data *bed = get_elf_backend_data (abfd);
- bfd_size_type address_size = bed->s->arch_size / 8;
-
- /* address_size and sec->size are in octets. Convert
- to bytes before subtracting the original offset. */
- offset = ((sec->size - address_size)
- / bfd_octets_per_byte (abfd, sec) - offset);
- }
- return offset;
- }
-}
-
-long
-_bfd_elf_get_synthetic_symtab (bfd *abfd,
- long symcount ATTRIBUTE_UNUSED,
- asymbol **syms ATTRIBUTE_UNUSED,
- long dynsymcount,
- asymbol **dynsyms,
- asymbol **ret)
-{
- const struct elf_backend_data *bed = get_elf_backend_data (abfd);
- asection *relplt;
- asymbol *s;
- const char *relplt_name;
- bool (*slurp_relocs) (bfd *, asection *, asymbol **, bool);
- arelent *p;
- long count, i, n;
- size_t size;
- Elf_Internal_Shdr *hdr;
- char *names;
- asection *plt;
-
- *ret = NULL;
-
- if ((abfd->flags & (DYNAMIC | EXEC_P)) == 0)
- return 0;
-
- if (dynsymcount <= 0)
- return 0;
-
- if (!bed->plt_sym_val)
- return 0;
-
- relplt_name = bed->relplt_name;
- if (relplt_name == NULL)
- relplt_name = bed->rela_plts_and_copies_p ? ".rela.plt" : ".rel.plt";
- relplt = bfd_get_section_by_name (abfd, relplt_name);
- if (relplt == NULL)
- return 0;
-
- hdr = &elf_section_data (relplt)->this_hdr;
- if (hdr->sh_link != elf_dynsymtab (abfd)
- || (hdr->sh_type != SHT_REL && hdr->sh_type != SHT_RELA))
- return 0;
-
- plt = bfd_get_section_by_name (abfd, ".plt");
- if (plt == NULL)
- return 0;
-
- slurp_relocs = get_elf_backend_data (abfd)->s->slurp_reloc_table;
- if (! (*slurp_relocs) (abfd, relplt, dynsyms, true))
- return -1;
-
- count = NUM_SHDR_ENTRIES (hdr);
- size = count * sizeof (asymbol);
- p = relplt->relocation;
- for (i = 0; i < count; i++, p += bed->s->int_rels_per_ext_rel)
- {
- size += strlen ((*p->sym_ptr_ptr)->name) + sizeof ("@plt");
- if (p->addend != 0)
- {
-#ifdef BFD64
- size += sizeof ("+0x") - 1 + 8 + 8 * (bed->s->elfclass == ELFCLASS64);
-#else
- size += sizeof ("+0x") - 1 + 8;
-#endif
- }
- }
-
- s = *ret = (asymbol *) bfd_malloc (size);
- if (s == NULL)
- return -1;
-
- names = (char *) (s + count);
- p = relplt->relocation;
- n = 0;
- for (i = 0; i < count; i++, p += bed->s->int_rels_per_ext_rel)
- {
- size_t len;
- bfd_vma addr;
-
- addr = bed->plt_sym_val (i, plt, p);
- if (addr == (bfd_vma) -1)
- continue;
-
- *s = **p->sym_ptr_ptr;
- /* Undefined syms won't have BSF_LOCAL or BSF_GLOBAL set. Since
- we are defining a symbol, ensure one of them is set. */
- if ((s->flags & BSF_LOCAL) == 0)
- s->flags |= BSF_GLOBAL;
- s->flags |= BSF_SYNTHETIC;
- s->section = plt;
- s->value = addr - plt->vma;
- s->name = names;
- s->udata.p = NULL;
- len = strlen ((*p->sym_ptr_ptr)->name);
- memcpy (names, (*p->sym_ptr_ptr)->name, len);
- names += len;
- if (p->addend != 0)
- {
- char buf[30], *a;
-
- memcpy (names, "+0x", sizeof ("+0x") - 1);
- names += sizeof ("+0x") - 1;
- bfd_sprintf_vma (abfd, buf, p->addend);
- for (a = buf; *a == '0'; ++a)
- ;
- len = strlen (a);
- memcpy (names, a, len);
- names += len;
- }
- memcpy (names, "@plt", sizeof ("@plt"));
- names += sizeof ("@plt");
- ++s, ++n;
- }
-
- return n;
-}
-
-/* It is only used by x86-64 so far.
- ??? This repeats *COM* id of zero. sec->id is supposed to be unique,
- but current usage would allow all of _bfd_std_section to be zero. */
-static const asymbol lcomm_sym
- = GLOBAL_SYM_INIT ("LARGE_COMMON", &_bfd_elf_large_com_section);
-asection _bfd_elf_large_com_section
- = BFD_FAKE_SECTION (_bfd_elf_large_com_section, &lcomm_sym,
- "LARGE_COMMON", 0, SEC_IS_COMMON);
-
-bool
-_bfd_elf_final_write_processing (bfd *abfd)
-{
- Elf_Internal_Ehdr *i_ehdrp; /* ELF file header, internal form. */
-
- i_ehdrp = elf_elfheader (abfd);
-
- if (i_ehdrp->e_ident[EI_OSABI] == ELFOSABI_NONE)
- i_ehdrp->e_ident[EI_OSABI] = get_elf_backend_data (abfd)->elf_osabi;
-
- /* Set the osabi field to ELFOSABI_GNU if the binary contains
- SHF_GNU_MBIND or SHF_GNU_RETAIN sections or symbols of STT_GNU_IFUNC type
- or STB_GNU_UNIQUE binding. */
- if (elf_tdata (abfd)->has_gnu_osabi != 0)
- {
- if (i_ehdrp->e_ident[EI_OSABI] == ELFOSABI_NONE)
- i_ehdrp->e_ident[EI_OSABI] = ELFOSABI_GNU;
- else if (i_ehdrp->e_ident[EI_OSABI] != ELFOSABI_GNU
- && i_ehdrp->e_ident[EI_OSABI] != ELFOSABI_FREEBSD)
- {
- if (elf_tdata (abfd)->has_gnu_osabi & elf_gnu_osabi_mbind)
- _bfd_error_handler (_("GNU_MBIND section is supported only by GNU "
- "and FreeBSD targets"));
- if (elf_tdata (abfd)->has_gnu_osabi & elf_gnu_osabi_ifunc)
- _bfd_error_handler (_("symbol type STT_GNU_IFUNC is supported "
- "only by GNU and FreeBSD targets"));
- if (elf_tdata (abfd)->has_gnu_osabi & elf_gnu_osabi_unique)
- _bfd_error_handler (_("symbol binding STB_GNU_UNIQUE is supported "
- "only by GNU and FreeBSD targets"));
- if (elf_tdata (abfd)->has_gnu_osabi & elf_gnu_osabi_retain)
- _bfd_error_handler (_("GNU_RETAIN section is supported "
- "only by GNU and FreeBSD targets"));
- bfd_set_error (bfd_error_sorry);
- return false;
- }
- }
- return true;
-}
-
-
-/* Return TRUE for ELF symbol types that represent functions.
- This is the default version of this function, which is sufficient for
- most targets. It returns true if TYPE is STT_FUNC or STT_GNU_IFUNC. */
-
-bool
-_bfd_elf_is_function_type (unsigned int type)
-{
- return (type == STT_FUNC
- || type == STT_GNU_IFUNC);
-}
-
-/* If the ELF symbol SYM might be a function in SEC, return the
- function size and set *CODE_OFF to the function's entry point,
- otherwise return zero. */
-
-bfd_size_type
-_bfd_elf_maybe_function_sym (const asymbol *sym, asection *sec,
- bfd_vma *code_off)
-{
- bfd_size_type size;
- elf_symbol_type * elf_sym = (elf_symbol_type *) sym;
-
- if ((sym->flags & (BSF_SECTION_SYM | BSF_FILE | BSF_OBJECT
- | BSF_THREAD_LOCAL | BSF_RELC | BSF_SRELC)) != 0
- || sym->section != sec)
- return 0;
-
- size = (sym->flags & BSF_SYNTHETIC) ? 0 : elf_sym->internal_elf_sym.st_size;
-
- /* In theory we should check that the symbol's type satisfies
- _bfd_elf_is_function_type(), but there are some function-like
- symbols which would fail this test. (eg _start). Instead
- we check for hidden, local, notype symbols with zero size.
- This type of symbol is generated by the annobin plugin for gcc
- and clang, and should not be considered to be a function symbol. */
- if (size == 0
- && ((sym->flags & (BSF_SYNTHETIC | BSF_LOCAL)) == BSF_LOCAL)
- && ELF_ST_TYPE (elf_sym->internal_elf_sym.st_info) == STT_NOTYPE
- && ELF_ST_VISIBILITY (elf_sym->internal_elf_sym.st_other) == STV_HIDDEN)
- return 0;
-
- *code_off = sym->value;
- /* Do not return 0 for the function's size. */
- return size ? size : 1;
-}
-
-/* Set to non-zero to enable some debug messages. */
-#define DEBUG_SECONDARY_RELOCS 0
-
-/* An internal-to-the-bfd-library only section type
- used to indicate a cached secondary reloc section. */
-#define SHT_SECONDARY_RELOC (SHT_LOOS + SHT_RELA)
-
-/* Create a BFD section to hold a secondary reloc section. */
-
-bool
-_bfd_elf_init_secondary_reloc_section (bfd * abfd,
- Elf_Internal_Shdr *hdr,
- const char * name,
- unsigned int shindex)
-{
- /* We only support RELA secondary relocs. */
- if (hdr->sh_type != SHT_RELA)
- return false;
-
-#if DEBUG_SECONDARY_RELOCS
- fprintf (stderr, "secondary reloc section %s encountered\n", name);
-#endif
- hdr->sh_type = SHT_SECONDARY_RELOC;
- return _bfd_elf_make_section_from_shdr (abfd, hdr, name, shindex);
-}
-
-/* Read in any secondary relocs associated with SEC. */
-
-bool
-_bfd_elf_slurp_secondary_reloc_section (bfd * abfd,
- asection * sec,
- asymbol ** symbols,
- bool dynamic)
-{
- const struct elf_backend_data * const ebd = get_elf_backend_data (abfd);
- asection * relsec;
- bool result = true;
- bfd_vma (*r_sym) (bfd_vma);
- ufile_ptr filesize;
-
-#if BFD_DEFAULT_TARGET_SIZE > 32
- if (bfd_arch_bits_per_address (abfd) != 32)
- r_sym = elf64_r_sym;
- else
-#endif
- r_sym = elf32_r_sym;
-
- if (!elf_section_data (sec)->has_secondary_relocs)
- return true;
-
- /* Discover if there are any secondary reloc sections
- associated with SEC. */
- filesize = bfd_get_file_size (abfd);
- for (relsec = abfd->sections; relsec != NULL; relsec = relsec->next)
- {
- Elf_Internal_Shdr * hdr = & elf_section_data (relsec)->this_hdr;
-
- if (hdr->sh_type == SHT_SECONDARY_RELOC
- && hdr->sh_info == (unsigned) elf_section_data (sec)->this_idx
- && (hdr->sh_entsize == ebd->s->sizeof_rel
- || hdr->sh_entsize == ebd->s->sizeof_rela))
- {
- bfd_byte * native_relocs;
- bfd_byte * native_reloc;
- arelent * internal_relocs;
- arelent * internal_reloc;
- size_t i;
- unsigned int entsize;
- unsigned int symcount;
- bfd_size_type reloc_count;
- size_t amt;
-
- if (ebd->elf_info_to_howto == NULL)
- return false;
-
-#if DEBUG_SECONDARY_RELOCS
- fprintf (stderr, "read secondary relocs for %s from %s\n",
- sec->name, relsec->name);
-#endif
- entsize = hdr->sh_entsize;
-
- if (filesize != 0
- && ((ufile_ptr) hdr->sh_offset > filesize
- || hdr->sh_size > filesize - hdr->sh_offset))
- {
- bfd_set_error (bfd_error_file_truncated);
- result = false;
- continue;
- }
-
- native_relocs = bfd_malloc (hdr->sh_size);
- if (native_relocs == NULL)
- {
- result = false;
- continue;
- }
-
- reloc_count = NUM_SHDR_ENTRIES (hdr);
- if (_bfd_mul_overflow (reloc_count, sizeof (arelent), & amt))
- {
- free (native_relocs);
- bfd_set_error (bfd_error_file_too_big);
- result = false;
- continue;
- }
-
- internal_relocs = (arelent *) bfd_alloc (abfd, amt);
- if (internal_relocs == NULL)
- {
- free (native_relocs);
- result = false;
- continue;
- }
-
- if (bfd_seek (abfd, hdr->sh_offset, SEEK_SET) != 0
- || bfd_read (native_relocs, hdr->sh_size, abfd) != hdr->sh_size)
- {
- free (native_relocs);
- /* The internal_relocs will be freed when
- the memory for the bfd is released. */
- result = false;
- continue;
- }
-
- if (dynamic)
- symcount = bfd_get_dynamic_symcount (abfd);
- else
- symcount = bfd_get_symcount (abfd);
-
- for (i = 0, internal_reloc = internal_relocs,
- native_reloc = native_relocs;
- i < reloc_count;
- i++, internal_reloc++, native_reloc += entsize)
- {
- bool res;
- Elf_Internal_Rela rela;
-
- if (entsize == ebd->s->sizeof_rel)
- ebd->s->swap_reloc_in (abfd, native_reloc, & rela);
- else /* entsize == ebd->s->sizeof_rela */
- ebd->s->swap_reloca_in (abfd, native_reloc, & rela);
-
- /* The address of an ELF reloc is section relative for an object
- file, and absolute for an executable file or shared library.
- The address of a normal BFD reloc is always section relative,
- and the address of a dynamic reloc is absolute.. */
- if ((abfd->flags & (EXEC_P | DYNAMIC)) == 0)
- internal_reloc->address = rela.r_offset;
- else
- internal_reloc->address = rela.r_offset - sec->vma;
-
- if (r_sym (rela.r_info) == STN_UNDEF)
- {
- /* FIXME: This and the error case below mean that we
- have a symbol on relocs that is not elf_symbol_type. */
- internal_reloc->sym_ptr_ptr =
- bfd_abs_section_ptr->symbol_ptr_ptr;
- }
- else if (r_sym (rela.r_info) > symcount)
- {
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB(%pA): relocation %zu has invalid symbol index %lu"),
- abfd, sec, i, (long) r_sym (rela.r_info));
- bfd_set_error (bfd_error_bad_value);
- internal_reloc->sym_ptr_ptr =
- bfd_abs_section_ptr->symbol_ptr_ptr;
- result = false;
- }
- else
- {
- asymbol **ps;
-
- ps = symbols + r_sym (rela.r_info) - 1;
- internal_reloc->sym_ptr_ptr = ps;
- /* Make sure that this symbol is not removed by strip. */
- (*ps)->flags |= BSF_KEEP;
- }
-
- internal_reloc->addend = rela.r_addend;
-
- res = ebd->elf_info_to_howto (abfd, internal_reloc, & rela);
- if (! res || internal_reloc->howto == NULL)
- {
-#if DEBUG_SECONDARY_RELOCS
- fprintf (stderr,
- "there is no howto associated with reloc %lx\n",
- rela.r_info);
-#endif
- result = false;
- }
- }
-
- free (native_relocs);
- /* Store the internal relocs. */
- elf_section_data (relsec)->sec_info = internal_relocs;
- }
- }
-
- return result;
-}
-
-/* Set the ELF section header fields of an output secondary reloc section. */
-
-bool
-_bfd_elf_copy_special_section_fields (const bfd *ibfd ATTRIBUTE_UNUSED,
- bfd *obfd ATTRIBUTE_UNUSED,
- const Elf_Internal_Shdr *isection,
- Elf_Internal_Shdr *osection)
-{
- asection * isec;
- asection * osec;
- struct bfd_elf_section_data * esd;
-
- if (isection == NULL)
- return false;
-
- if (isection->sh_type != SHT_SECONDARY_RELOC)
- return true;
-
- isec = isection->bfd_section;
- if (isec == NULL)
- return false;
-
- osec = osection->bfd_section;
- if (osec == NULL)
- return false;
-
- esd = elf_section_data (osec);
- BFD_ASSERT (esd->sec_info == NULL);
- esd->sec_info = elf_section_data (isec)->sec_info;
- osection->sh_type = SHT_RELA;
- osection->sh_link = elf_onesymtab (obfd);
- if (osection->sh_link == 0)
- {
- /* There is no symbol table - we are hosed... */
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB(%pA): link section cannot be set"
- " because the output file does not have a symbol table"),
- obfd, osec);
- bfd_set_error (bfd_error_bad_value);
- return false;
- }
-
- /* Find the output section that corresponds to the isection's
- sh_info link. */
- if (isection->sh_info == 0
- || isection->sh_info >= elf_numsections (ibfd))
- {
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB(%pA): info section index is invalid"),
- obfd, osec);
- bfd_set_error (bfd_error_bad_value);
- return false;
- }
-
- isection = elf_elfsections (ibfd)[isection->sh_info];
-
- if (isection == NULL
- || isection->bfd_section == NULL
- || isection->bfd_section->output_section == NULL)
- {
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB(%pA): info section index cannot be set"
- " because the section is not in the output"),
- obfd, osec);
- bfd_set_error (bfd_error_bad_value);
- return false;
- }
-
- esd = elf_section_data (isection->bfd_section->output_section);
- BFD_ASSERT (esd != NULL);
- osection->sh_info = esd->this_idx;
- esd->has_secondary_relocs = true;
-#if DEBUG_SECONDARY_RELOCS
- fprintf (stderr, "update header of %s, sh_link = %u, sh_info = %u\n",
- osec->name, osection->sh_link, osection->sh_info);
- fprintf (stderr, "mark section %s as having secondary relocs\n",
- bfd_section_name (isection->bfd_section->output_section));
-#endif
-
- return true;
-}
-
-/* Write out a secondary reloc section.
-
- FIXME: Currently this function can result in a serious performance penalty
- for files with secondary relocs and lots of sections. The proper way to
- fix this is for _bfd_elf_copy_special_section_fields() to chain secondary
- relocs together and then to have this function just walk that chain. */
-
-bool
-_bfd_elf_write_secondary_reloc_section (bfd *abfd, asection *sec)
-{
- const struct elf_backend_data * const ebd = get_elf_backend_data (abfd);
- bfd_vma addr_offset;
- asection * relsec;
- bfd_vma (*r_info) (bfd_vma, bfd_vma);
- bool result = true;
-
- if (sec == NULL)
- return false;
-
-#if BFD_DEFAULT_TARGET_SIZE > 32
- if (bfd_arch_bits_per_address (abfd) != 32)
- r_info = elf64_r_info;
- else
-#endif
- r_info = elf32_r_info;
-
- /* The address of an ELF reloc is section relative for an object
- file, and absolute for an executable file or shared library.
- The address of a BFD reloc is always section relative. */
- addr_offset = 0;
- if ((abfd->flags & (EXEC_P | DYNAMIC)) != 0)
- addr_offset = sec->vma;
-
- /* Discover if there are any secondary reloc sections
- associated with SEC. */
- for (relsec = abfd->sections; relsec != NULL; relsec = relsec->next)
- {
- const struct bfd_elf_section_data * const esd = elf_section_data (relsec);
- Elf_Internal_Shdr * const hdr = (Elf_Internal_Shdr *) & esd->this_hdr;
-
- if (hdr->sh_type == SHT_RELA
- && hdr->sh_info == (unsigned) elf_section_data (sec)->this_idx)
- {
- asymbol * last_sym;
- int last_sym_idx;
- size_t reloc_count;
- size_t idx;
- bfd_size_type entsize;
- arelent * src_irel;
- bfd_byte * dst_rela;
-
- if (hdr->contents != NULL)
- {
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB(%pA): error: secondary reloc section processed twice"),
- abfd, relsec);
- bfd_set_error (bfd_error_bad_value);
- result = false;
- continue;
- }
-
- entsize = hdr->sh_entsize;
- if (entsize == 0)
- {
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB(%pA): error: secondary reloc section"
- " has zero sized entries"),
- abfd, relsec);
- bfd_set_error (bfd_error_bad_value);
- result = false;
- continue;
- }
- else if (entsize != ebd->s->sizeof_rel
- && entsize != ebd->s->sizeof_rela)
- {
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB(%pA): error: secondary reloc section"
- " has non-standard sized entries"),
- abfd, relsec);
- bfd_set_error (bfd_error_bad_value);
- result = false;
- continue;
- }
-
- reloc_count = hdr->sh_size / entsize;
- hdr->sh_size = entsize * reloc_count;
- if (reloc_count == 0)
- {
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB(%pA): error: secondary reloc section is empty!"),
- abfd, relsec);
- bfd_set_error (bfd_error_bad_value);
- result = false;
- continue;
- }
-
- hdr->contents = bfd_alloc (abfd, hdr->sh_size);
- if (hdr->contents == NULL)
- continue;
-
-#if DEBUG_SECONDARY_RELOCS
- fprintf (stderr, "write %u secondary relocs for %s from %s\n",
- reloc_count, sec->name, relsec->name);
-#endif
- last_sym = NULL;
- last_sym_idx = 0;
- dst_rela = hdr->contents;
- src_irel = (arelent *) esd->sec_info;
- if (src_irel == NULL)
- {
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB(%pA): error: internal relocs missing"
- " for secondary reloc section"),
- abfd, relsec);
- bfd_set_error (bfd_error_bad_value);
- result = false;
- continue;
- }
-
- for (idx = 0; idx < reloc_count; idx++, dst_rela += entsize)
- {
- Elf_Internal_Rela src_rela;
- arelent *ptr;
- asymbol *sym;
- int n;
-
- ptr = src_irel + idx;
- if (ptr == NULL)
- {
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB(%pA): error: reloc table entry %zu is empty"),
- abfd, relsec, idx);
- bfd_set_error (bfd_error_bad_value);
- result = false;
- break;
- }
-
- if (ptr->sym_ptr_ptr == NULL)
- {
- /* FIXME: Is this an error ? */
- n = 0;
- }
- else
- {
- sym = *ptr->sym_ptr_ptr;
-
- if (sym == last_sym)
- n = last_sym_idx;
- else
- {
- n = _bfd_elf_symbol_from_bfd_symbol (abfd, & sym);
- if (n < 0)
- {
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB(%pA): error: secondary reloc %zu"
- " references a missing symbol"),
- abfd, relsec, idx);
- bfd_set_error (bfd_error_bad_value);
- result = false;
- n = 0;
- }
-
- last_sym = sym;
- last_sym_idx = n;
- }
-
- if (sym->the_bfd != NULL
- && sym->the_bfd->xvec != abfd->xvec
- && ! _bfd_elf_validate_reloc (abfd, ptr))
- {
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB(%pA): error: secondary reloc %zu"
- " references a deleted symbol"),
- abfd, relsec, idx);
- bfd_set_error (bfd_error_bad_value);
- result = false;
- n = 0;
- }
- }
-
- src_rela.r_offset = ptr->address + addr_offset;
- if (ptr->howto == NULL)
- {
- _bfd_error_handler
- /* xgettext:c-format */
- (_("%pB(%pA): error: secondary reloc %zu"
- " is of an unknown type"),
- abfd, relsec, idx);
- bfd_set_error (bfd_error_bad_value);
- result = false;
- src_rela.r_info = r_info (0, 0);
- }
- else
- src_rela.r_info = r_info (n, ptr->howto->type);
- src_rela.r_addend = ptr->addend;
-
- if (entsize == ebd->s->sizeof_rel)
- ebd->s->swap_reloc_out (abfd, &src_rela, dst_rela);
- else /* entsize == ebd->s->sizeof_rela */
- ebd->s->swap_reloca_out (abfd, &src_rela, dst_rela);
- }
- }
- }
-
- return result;
-}
-
-/* Mmap in section contents. If FINAL_LINK is false, set *BUF to NULL
- before calling bfd_get_full_section_contents. */
-
-static bool
-elf_mmap_section_contents (bfd *abfd, sec_ptr sec, bfd_byte **buf,
- bool final_link)
-{
-#ifdef USE_MMAP
- const struct elf_backend_data *bed = get_elf_backend_data (abfd);
- if (bed->use_mmap
- && sec->compress_status == COMPRESS_SECTION_NONE
- && (sec->flags & SEC_LINKER_CREATED) == 0)
- {
- /* Use mmap only if section size >= the minimum mmap section
- size. */
- size_t readsz = bfd_get_section_limit_octets (abfd, sec);
- size_t allocsz = bfd_get_section_alloc_size (abfd, sec);
- if (readsz == allocsz && readsz >= _bfd_minimum_mmap_size)
- {
- if (sec->contents != NULL)
- {
- if (!sec->mmapped_p)
- abort ();
- *buf = sec->contents;
- return true;
- }
- if (sec->mmapped_p)
- abort ();
- sec->mmapped_p = 1;
-
- /* Never use the preallocated buffer if mmapp is used. */
- *buf = NULL;
- }
- }
-#endif
- /* NB: When this is called from elf_link_input_bfd, FINAL_LINK is
- true. If FINAL_LINK is false, *BUF is set to the preallocated
- buffer if USE_MMAP is undefined and *BUF is set to NULL if
- USE_MMAP is defined. */
- if (!final_link)
- *buf = NULL;
- bool ret = bfd_get_full_section_contents (abfd, sec, buf);
- if (ret && sec->mmapped_p)
- *buf = sec->contents;
- return ret;
-}
-
-/* Mmap in section contents. */
-
-bool
-_bfd_elf_mmap_section_contents (bfd *abfd, sec_ptr sec, bfd_byte **buf)
-{
- return elf_mmap_section_contents (abfd, sec, buf, false);
-}
-
-/* Mmap in the full section contents for the final link. */
-
-bool
-_bfd_elf_link_mmap_section_contents (bfd *abfd, sec_ptr sec,
- bfd_byte **buf)
-{
- return elf_mmap_section_contents (abfd, sec, buf, true);
-}
-
-/* Munmap section contents. */
-
-void
-_bfd_elf_munmap_section_contents (asection *sec ATTRIBUTE_UNUSED,
- void *contents)
-{
- /* NB: Since _bfd_elf_munmap_section_contents is called like free,
- CONTENTS may be NULL. */
- if (contents == NULL)
- return;
-
-#ifdef USE_MMAP
- if (sec->mmapped_p)
- {
- /* _bfd_elf_mmap_section_contents may return the previously
- mapped section contents. Munmap the section contents only
- if they haven't been cached. */
- if (elf_section_data (sec)->this_hdr.contents == contents)
- return;
-
- /* When _bfd_elf_mmap_section_contents returns CONTENTS as
- malloced, CONTENTS_ADDR is set to NULL. */
- if (elf_section_data (sec)->contents_addr != NULL)
- {
- /* NB: CONTENTS_ADDR and CONTENTS_SIZE must be valid. */
- if (munmap (elf_section_data (sec)->contents_addr,
- elf_section_data (sec)->contents_size) != 0)
- abort ();
- sec->mmapped_p = 0;
- sec->contents = NULL;
- elf_section_data (sec)->contents_addr = NULL;
- elf_section_data (sec)->contents_size = 0;
- return;
- }
- }
-#endif
-
- free (contents);
-}
-
-/* Munmap the full section contents for the final link. */
-
-void
-_bfd_elf_link_munmap_section_contents (asection *sec ATTRIBUTE_UNUSED)
-{
-#ifdef USE_MMAP
- if (sec->mmapped_p && elf_section_data (sec)->contents_addr != NULL)
- {
- /* When _bfd_elf_link_mmap_section_contents returns CONTENTS as
- malloced, CONTENTS_ADDR is set to NULL. */
- /* NB: CONTENTS_ADDR and CONTENTS_SIZE must be valid. */
- if (munmap (elf_section_data (sec)->contents_addr,
- elf_section_data (sec)->contents_size) != 0)
- abort ();
- sec->mmapped_p = 0;
- sec->contents = NULL;
- elf_section_data (sec)->contents_addr = NULL;
- elf_section_data (sec)->contents_size = 0;
- }
-#endif
-}
Index: sources/GNU/binutils/Makefile
===================================================================
--- sources/GNU/binutils/Makefile (revision 75)
+++ sources/GNU/binutils/Makefile (revision 76)
@@ -15,26 +15,19 @@
url = $(DOWNLOAD_SERVER)/sources/GNU/binutils
-versions = 2.43.1
+versions = 2.44
tarballs = $(addsuffix .tar.xz, $(addprefix binutils-, $(versions)))
sha1s = $(addsuffix .sha1sum, $(tarballs))
-patches = $(CURDIR)/patches/binutils-2.43.1-aarch64-ifunc.patch
-patches += $(CURDIR)/patches/binutils-2.43.1-not-link-static-libstdc++.patch
-patches += $(CURDIR)/patches/binutils-2.43.1-fname-in-error-messages.patch
-patches += $(CURDIR)/patches/binutils-2.43.1-gold-i386-gnu-property-notes.patch
-patches += $(CURDIR)/patches/binutils-2.43.1-gold-mismatched-section-flags.patch
-patches += $(CURDIR)/patches/binutils-2.43.1-gold-warn-unsupported.patch
-patches += $(CURDIR)/patches/binutils-2.43.1-readelf-other-sym-info.patch
-patches += $(CURDIR)/patches/binutils-2.43.1-testsuite-failures.patch
+patches = $(CURDIR)/patches/binutils-2.44-aarch64-ifunc.patch
+patches += $(CURDIR)/patches/binutils-2.44-not-link-static-libstdc++.patch
+patches += $(CURDIR)/patches/binutils-2.44-readelf-other-sym-info.patch
-patches += $(CURDIR)/patches/binutils-2.43.1-cleansweep.patch
-patches += $(CURDIR)/patches/binutils-2.43.1-copy-osabi.patch
-patches += $(CURDIR)/patches/binutils-2.43.1-export-demangle.patch
-patches += $(CURDIR)/patches/binutils-2.43.1-ldforcele.patch
-patches += $(CURDIR)/patches/binutils-2.43.1-libtool-lib64.patch
-patches += $(CURDIR)/patches/binutils-2.43.1-no-config-check.patch
+patches += $(CURDIR)/patches/binutils-2.44-export-demangle.patch
+patches += $(CURDIR)/patches/binutils-2.44-ldforcele.patch
+patches += $(CURDIR)/patches/binutils-2.44-libtool-lib64.patch
+patches += $(CURDIR)/patches/binutils-2.44-no-config-check.patch
.NOTPARALLEL: $(patches)
@@ -69,20 +62,13 @@
$(patches): $(sha1s)
@echo -e "\n======= Create Patches =======\n" ; \
- ( cd create-2.43.1-aarch64-ifunc-patch ; ./create.patch.sh ) ; \
- ( cd create-2.43.1-not-link-static-libstdc++-patch ; ./create.patch.sh ) ; \
- ( cd create-2.43.1-fname-in-error-messages-patch ; ./create.patch.sh ) ; \
- ( cd create-2.43.1-gold-i386-gnu-property-notes-patch ; ./create.patch.sh ) ; \
- ( cd create-2.43.1-gold-mismatched-section-flags-patch ; ./create.patch.sh ) ; \
- ( cd create-2.43.1-gold-warn-unsupported-patch ; ./create.patch.sh ) ; \
- ( cd create-2.43.1-readelf-other-sym-info-patch ; ./create.patch.sh ) ; \
- ( cd create-2.43.1-testsuite-failures-patch ; ./create.patch.sh ) ; \
- ( cd create-2.43.1-cleansweep-patch ; ./create.patch.sh ) ; \
- ( cd create-2.43.1-copy-osabi-patch ; ./create.patch.sh ) ; \
- ( cd create-2.43.1-export-demangle-patch ; ./create.patch.sh ) ; \
- ( cd create-2.43.1-ldforcele-patch ; ./create.patch.sh ) ; \
- ( cd create-2.43.1-libtool-lib64-patch ; ./create.patch.sh ) ; \
- ( cd create-2.43.1-no-config-check-patch ; ./create.patch.sh ) ; \
+ ( cd create-2.44-aarch64-ifunc-patch ; ./create.patch.sh ) ; \
+ ( cd create-2.44-not-link-static-libstdc++-patch ; ./create.patch.sh ) ; \
+ ( cd create-2.44-readelf-other-sym-info-patch ; ./create.patch.sh ) ; \
+ ( cd create-2.44-export-demangle-patch ; ./create.patch.sh ) ; \
+ ( cd create-2.44-ldforcele-patch ; ./create.patch.sh ) ; \
+ ( cd create-2.44-libtool-lib64-patch ; ./create.patch.sh ) ; \
+ ( cd create-2.44-no-config-check-patch ; ./create.patch.sh ) ; \
echo -e "\n"
download_clean:
Index: sources/GNU/binutils/create-2.44-aarch64-ifunc-patch/binutils-2.44-new/bfd/elfnn-aarch64.c
===================================================================
--- sources/GNU/binutils/create-2.44-aarch64-ifunc-patch/binutils-2.44-new/bfd/elfnn-aarch64.c (nonexistent)
+++ sources/GNU/binutils/create-2.44-aarch64-ifunc-patch/binutils-2.44-new/bfd/elfnn-aarch64.c (revision 76)
@@ -0,0 +1,10782 @@
+/* AArch64-specific support for NN-bit ELF.
+ Copyright (C) 2009-2025 Free Software Foundation, Inc.
+ Contributed by ARM Ltd.
+
+ This file is part of BFD, the Binary File Descriptor library.
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 3 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; see the file COPYING3. If not,
+ see <http://www.gnu.org/licenses/>. */
+
+/* Notes on implementation:
+
+ Thread Local Store (TLS)
+
+ Overview:
+
+ The implementation currently supports both traditional TLS and TLS
+ descriptors, but only general dynamic (GD).
+
+ For traditional TLS the assembler will present us with code
+ fragments of the form:
+
+ adrp x0, :tlsgd:foo
+ R_AARCH64_TLSGD_ADR_PAGE21(foo)
+ add x0, :tlsgd_lo12:foo
+ R_AARCH64_TLSGD_ADD_LO12_NC(foo)
+ bl __tls_get_addr
+ nop
+
+ For TLS descriptors the assembler will present us with code
+ fragments of the form:
+
+ adrp x0, :tlsdesc:foo R_AARCH64_TLSDESC_ADR_PAGE21(foo)
+ ldr x1, [x0, #:tlsdesc_lo12:foo] R_AARCH64_TLSDESC_LD64_LO12(foo)
+ add x0, x0, #:tlsdesc_lo12:foo R_AARCH64_TLSDESC_ADD_LO12(foo)
+ .tlsdesccall foo
+ blr x1 R_AARCH64_TLSDESC_CALL(foo)
+
+ The relocations R_AARCH64_TLSGD_{ADR_PREL21,ADD_LO12_NC} against foo
+ indicate that foo is thread local and should be accessed via the
+ traditional TLS mechanims.
+
+ The relocations R_AARCH64_TLSDESC_{ADR_PAGE21,LD64_LO12_NC,ADD_LO12_NC}
+ against foo indicate that 'foo' is thread local and should be accessed
+ via a TLS descriptor mechanism.
+
+ The precise instruction sequence is only relevant from the
+ perspective of linker relaxation which is currently not implemented.
+
+ The static linker must detect that 'foo' is a TLS object and
+ allocate a double GOT entry. The GOT entry must be created for both
+ global and local TLS symbols. Note that this is different to none
+ TLS local objects which do not need a GOT entry.
+
+ In the traditional TLS mechanism, the double GOT entry is used to
+ provide the tls_index structure, containing module and offset
+ entries. The static linker places the relocation R_AARCH64_TLS_DTPMOD
+ on the module entry. The loader will subsequently fixup this
+ relocation with the module identity.
+
+ For global traditional TLS symbols the static linker places an
+ R_AARCH64_TLS_DTPREL relocation on the offset entry. The loader
+ will subsequently fixup the offset. For local TLS symbols the static
+ linker fixes up offset.
+
+ In the TLS descriptor mechanism the double GOT entry is used to
+ provide the descriptor. The static linker places the relocation
+ R_AARCH64_TLSDESC on the first GOT slot. The loader will
+ subsequently fix this up.
+
+ Implementation:
+
+ The handling of TLS symbols is implemented across a number of
+ different backend functions. The following is a top level view of
+ what processing is performed where.
+
+ The TLS implementation maintains state information for each TLS
+ symbol. The state information for local and global symbols is kept
+ in different places. Global symbols use generic BFD structures while
+ local symbols use backend specific structures that are allocated and
+ maintained entirely by the backend.
+
+ The flow:
+
+ elfNN_aarch64_check_relocs()
+
+ This function is invoked for each relocation.
+
+ The TLS relocations R_AARCH64_TLSGD_{ADR_PREL21,ADD_LO12_NC} and
+ R_AARCH64_TLSDESC_{ADR_PAGE21,LD64_LO12_NC,ADD_LO12_NC} are
+ spotted. One time creation of local symbol data structures are
+ created when the first local symbol is seen.
+
+ The reference count for a symbol is incremented. The GOT type for
+ each symbol is marked as general dynamic.
+
+ elfNN_aarch64_allocate_dynrelocs ()
+
+ For each global with positive reference count we allocate a double
+ GOT slot. For a traditional TLS symbol we allocate space for two
+ relocation entries on the GOT, for a TLS descriptor symbol we
+ allocate space for one relocation on the slot. Record the GOT offset
+ for this symbol.
+
+ elfNN_aarch64_late_size_sections ()
+
+ Iterate all input BFDS, look for in the local symbol data structure
+ constructed earlier for local TLS symbols and allocate them double
+ GOT slots along with space for a single GOT relocation. Update the
+ local symbol structure to record the GOT offset allocated.
+
+ elfNN_aarch64_relocate_section ()
+
+ Calls elfNN_aarch64_final_link_relocate ()
+
+ Emit the relevant TLS relocations against the GOT for each TLS
+ symbol. For local TLS symbols emit the GOT offset directly. The GOT
+ relocations are emitted once the first time a TLS symbol is
+ encountered. The implementation uses the LSB of the GOT offset to
+ flag that the relevant GOT relocations for a symbol have been
+ emitted. All of the TLS code that uses the GOT offset needs to take
+ care to mask out this flag bit before using the offset.
+
+ elfNN_aarch64_final_link_relocate ()
+
+ Fixup the R_AARCH64_TLSGD_{ADR_PREL21, ADD_LO12_NC} relocations. */
+
+#include "sysdep.h"
+#include "bfd.h"
+#include "libiberty.h"
+#include "libbfd.h"
+#include "elf-bfd.h"
+#include "bfdlink.h"
+#include "objalloc.h"
+#include "elf/aarch64.h"
+#include "elfxx-aarch64.h"
+#include "cpu-aarch64.h"
+
+#define ARCH_SIZE NN
+
+#if ARCH_SIZE == 64
+#define AARCH64_R(NAME) R_AARCH64_ ## NAME
+#define AARCH64_R_STR(NAME) "R_AARCH64_" #NAME
+#define HOWTO64(...) HOWTO (__VA_ARGS__)
+#define HOWTO32(...) EMPTY_HOWTO (0)
+#define LOG_FILE_ALIGN 3
+#define BFD_RELOC_AARCH64_TLSDESC_LD64_LO12_NC BFD_RELOC_AARCH64_TLSDESC_LD64_LO12
+#endif
+
+#if ARCH_SIZE == 32
+#define AARCH64_R(NAME) R_AARCH64_P32_ ## NAME
+#define AARCH64_R_STR(NAME) "R_AARCH64_P32_" #NAME
+#define HOWTO64(...) EMPTY_HOWTO (0)
+#define HOWTO32(...) HOWTO (__VA_ARGS__)
+#define LOG_FILE_ALIGN 2
+#define BFD_RELOC_AARCH64_TLSDESC_LD32_LO12 BFD_RELOC_AARCH64_TLSDESC_LD32_LO12_NC
+#define R_AARCH64_P32_TLSDESC_ADD_LO12 R_AARCH64_P32_TLSDESC_ADD_LO12_NC
+#endif
+
+#define IS_AARCH64_TLS_RELOC(R_TYPE) \
+ ((R_TYPE) == BFD_RELOC_AARCH64_TLSGD_ADD_LO12_NC \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSGD_ADR_PAGE21 \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSGD_ADR_PREL21 \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSGD_MOVW_G0_NC \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSGD_MOVW_G1 \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSIE_ADR_GOTTPREL_PAGE21 \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSIE_LD32_GOTTPREL_LO12_NC \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSIE_LD64_GOTTPREL_LO12_NC \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSIE_LD_GOTTPREL_PREL19 \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSIE_MOVW_GOTTPREL_G0_NC \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSIE_MOVW_GOTTPREL_G1 \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSLD_ADD_DTPREL_HI12 \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSLD_ADD_DTPREL_LO12 \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSLD_ADD_DTPREL_LO12_NC \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSLD_ADD_LO12_NC \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSLD_ADR_PAGE21 \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSLD_ADR_PREL21 \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSLD_LDST16_DTPREL_LO12 \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSLD_LDST16_DTPREL_LO12_NC \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSLD_LDST32_DTPREL_LO12 \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSLD_LDST32_DTPREL_LO12_NC \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSLD_LDST64_DTPREL_LO12 \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSLD_LDST64_DTPREL_LO12_NC \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSLD_LDST8_DTPREL_LO12 \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSLD_LDST8_DTPREL_LO12_NC \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSLD_MOVW_DTPREL_G0 \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSLD_MOVW_DTPREL_G0_NC \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSLD_MOVW_DTPREL_G1 \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSLD_MOVW_DTPREL_G1_NC \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSLD_MOVW_DTPREL_G2 \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSLE_ADD_TPREL_HI12 \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSLE_ADD_TPREL_LO12 \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSLE_ADD_TPREL_LO12_NC \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSLE_LDST16_TPREL_LO12 \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSLE_LDST16_TPREL_LO12_NC \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSLE_LDST32_TPREL_LO12 \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSLE_LDST32_TPREL_LO12_NC \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSLE_LDST64_TPREL_LO12 \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSLE_LDST64_TPREL_LO12_NC \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSLE_LDST8_TPREL_LO12 \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSLE_LDST8_TPREL_LO12_NC \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G0 \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G0_NC \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G1 \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G1_NC \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G2 \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLS_DTPMOD \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLS_DTPREL \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLS_TPREL \
+ || IS_AARCH64_TLSDESC_RELOC ((R_TYPE)))
+
+#define IS_AARCH64_TLS_RELAX_RELOC(R_TYPE) \
+ ((R_TYPE) == BFD_RELOC_AARCH64_TLSDESC_ADD \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSDESC_ADD_LO12 \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSDESC_ADR_PAGE21 \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSDESC_ADR_PREL21 \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSDESC_CALL \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSDESC_LD_PREL19 \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSDESC_LDNN_LO12_NC \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSDESC_LDR \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSDESC_OFF_G0_NC \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSDESC_OFF_G1 \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSDESC_LDR \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSGD_ADR_PAGE21 \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSGD_ADR_PREL21 \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSGD_ADD_LO12_NC \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSGD_MOVW_G0_NC \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSGD_MOVW_G1 \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSIE_ADR_GOTTPREL_PAGE21 \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSIE_LD_GOTTPREL_PREL19 \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSIE_LDNN_GOTTPREL_LO12_NC \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSLD_ADD_LO12_NC \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSLD_ADR_PAGE21 \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSLD_ADR_PREL21)
+
+#define IS_AARCH64_TLSDESC_RELOC(R_TYPE) \
+ ((R_TYPE) == BFD_RELOC_AARCH64_TLSDESC \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSDESC_ADD \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSDESC_ADD_LO12 \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSDESC_ADR_PAGE21 \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSDESC_ADR_PREL21 \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSDESC_CALL \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSDESC_LD32_LO12_NC \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSDESC_LD64_LO12 \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSDESC_LDR \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSDESC_LD_PREL19 \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSDESC_OFF_G0_NC \
+ || (R_TYPE) == BFD_RELOC_AARCH64_TLSDESC_OFF_G1)
+
+#define ELIMINATE_COPY_RELOCS 1
+
+/* Return size of a relocation entry. HTAB is the bfd's
+ elf_aarch64_link_hash_entry. */
+#define RELOC_SIZE(HTAB) (sizeof (ElfNN_External_Rela))
+
+/* GOT Entry size - 8 bytes in ELF64 and 4 bytes in ELF32. */
+#define GOT_ENTRY_SIZE (ARCH_SIZE / 8)
+#define PLT_ENTRY_SIZE (32)
+#define PLT_SMALL_ENTRY_SIZE (16)
+#define PLT_TLSDESC_ENTRY_SIZE (32)
+/* PLT sizes with BTI insn. */
+#define PLT_BTI_SMALL_ENTRY_SIZE (24)
+/* PLT sizes with PAC insn. */
+#define PLT_PAC_SMALL_ENTRY_SIZE (24)
+/* PLT sizes with BTI and PAC insn. */
+#define PLT_BTI_PAC_SMALL_ENTRY_SIZE (24)
+
+/* Encoding of the nop instruction. */
+#define INSN_NOP 0xd503201f
+
+#define aarch64_compute_jump_table_size(htab) \
+ (((htab)->root.srelplt == NULL) ? 0 \
+ : (htab)->root.srelplt->reloc_count * GOT_ENTRY_SIZE)
+
+/* The first entry in a procedure linkage table looks like this
+ if the distance between the PLTGOT and the PLT is < 4GB use
+ these PLT entries. Note that the dynamic linker gets &PLTGOT[2]
+ in x16 and needs to work out PLTGOT[1] by using an address of
+ [x16,#-GOT_ENTRY_SIZE]. */
+static const bfd_byte elfNN_aarch64_small_plt0_entry[PLT_ENTRY_SIZE] =
+{
+ 0xf0, 0x7b, 0xbf, 0xa9, /* stp x16, x30, [sp, #-16]! */
+ 0x10, 0x00, 0x00, 0x90, /* adrp x16, (GOT+16) */
+#if ARCH_SIZE == 64
+ 0x11, 0x0A, 0x40, 0xf9, /* ldr x17, [x16, #PLT_GOT+0x10] */
+ 0x10, 0x42, 0x00, 0x91, /* add x16, x16,#PLT_GOT+0x10 */
+#else
+ 0x11, 0x0A, 0x40, 0xb9, /* ldr w17, [x16, #PLT_GOT+0x8] */
+ 0x10, 0x22, 0x00, 0x11, /* add w16, w16,#PLT_GOT+0x8 */
+#endif
+ 0x20, 0x02, 0x1f, 0xd6, /* br x17 */
+ 0x1f, 0x20, 0x03, 0xd5, /* nop */
+ 0x1f, 0x20, 0x03, 0xd5, /* nop */
+ 0x1f, 0x20, 0x03, 0xd5, /* nop */
+};
+
+static const bfd_byte elfNN_aarch64_small_plt0_bti_entry[PLT_ENTRY_SIZE] =
+{
+ 0x5f, 0x24, 0x03, 0xd5, /* bti c. */
+ 0xf0, 0x7b, 0xbf, 0xa9, /* stp x16, x30, [sp, #-16]! */
+ 0x10, 0x00, 0x00, 0x90, /* adrp x16, (GOT+16) */
+#if ARCH_SIZE == 64
+ 0x11, 0x0A, 0x40, 0xf9, /* ldr x17, [x16, #PLT_GOT+0x10] */
+ 0x10, 0x42, 0x00, 0x91, /* add x16, x16,#PLT_GOT+0x10 */
+#else
+ 0x11, 0x0A, 0x40, 0xb9, /* ldr w17, [x16, #PLT_GOT+0x8] */
+ 0x10, 0x22, 0x00, 0x11, /* add w16, w16,#PLT_GOT+0x8 */
+#endif
+ 0x20, 0x02, 0x1f, 0xd6, /* br x17 */
+ 0x1f, 0x20, 0x03, 0xd5, /* nop */
+ 0x1f, 0x20, 0x03, 0xd5, /* nop */
+};
+
+/* Per function entry in a procedure linkage table looks like this
+ if the distance between the PLTGOT and the PLT is < 4GB use
+ these PLT entries. Use BTI versions of the PLTs when enabled. */
+static const bfd_byte elfNN_aarch64_small_plt_entry[PLT_SMALL_ENTRY_SIZE] =
+{
+ 0x10, 0x00, 0x00, 0x90, /* adrp x16, PLTGOT + n * 8 */
+#if ARCH_SIZE == 64
+ 0x11, 0x02, 0x40, 0xf9, /* ldr x17, [x16, PLTGOT + n * 8] */
+ 0x10, 0x02, 0x00, 0x91, /* add x16, x16, :lo12:PLTGOT + n * 8 */
+#else
+ 0x11, 0x02, 0x40, 0xb9, /* ldr w17, [x16, PLTGOT + n * 4] */
+ 0x10, 0x02, 0x00, 0x11, /* add w16, w16, :lo12:PLTGOT + n * 4 */
+#endif
+ 0x20, 0x02, 0x1f, 0xd6, /* br x17. */
+};
+
+static const bfd_byte
+elfNN_aarch64_small_plt_bti_entry[PLT_BTI_SMALL_ENTRY_SIZE] =
+{
+ 0x5f, 0x24, 0x03, 0xd5, /* bti c. */
+ 0x10, 0x00, 0x00, 0x90, /* adrp x16, PLTGOT + n * 8 */
+#if ARCH_SIZE == 64
+ 0x11, 0x02, 0x40, 0xf9, /* ldr x17, [x16, PLTGOT + n * 8] */
+ 0x10, 0x02, 0x00, 0x91, /* add x16, x16, :lo12:PLTGOT + n * 8 */
+#else
+ 0x11, 0x02, 0x40, 0xb9, /* ldr w17, [x16, PLTGOT + n * 4] */
+ 0x10, 0x02, 0x00, 0x11, /* add w16, w16, :lo12:PLTGOT + n * 4 */
+#endif
+ 0x20, 0x02, 0x1f, 0xd6, /* br x17. */
+ 0x1f, 0x20, 0x03, 0xd5, /* nop */
+};
+
+static const bfd_byte
+elfNN_aarch64_small_plt_pac_entry[PLT_PAC_SMALL_ENTRY_SIZE] =
+{
+ 0x10, 0x00, 0x00, 0x90, /* adrp x16, PLTGOT + n * 8 */
+#if ARCH_SIZE == 64
+ 0x11, 0x02, 0x40, 0xf9, /* ldr x17, [x16, PLTGOT + n * 8] */
+ 0x10, 0x02, 0x00, 0x91, /* add x16, x16, :lo12:PLTGOT + n * 8 */
+#else
+ 0x11, 0x02, 0x40, 0xb9, /* ldr w17, [x16, PLTGOT + n * 4] */
+ 0x10, 0x02, 0x00, 0x11, /* add w16, w16, :lo12:PLTGOT + n * 4 */
+#endif
+ 0x9f, 0x21, 0x03, 0xd5, /* autia1716 */
+ 0x20, 0x02, 0x1f, 0xd6, /* br x17. */
+ 0x1f, 0x20, 0x03, 0xd5, /* nop */
+};
+
+static const bfd_byte
+elfNN_aarch64_small_plt_bti_pac_entry[PLT_BTI_PAC_SMALL_ENTRY_SIZE] =
+{
+ 0x5f, 0x24, 0x03, 0xd5, /* bti c. */
+ 0x10, 0x00, 0x00, 0x90, /* adrp x16, PLTGOT + n * 8 */
+#if ARCH_SIZE == 64
+ 0x11, 0x02, 0x40, 0xf9, /* ldr x17, [x16, PLTGOT + n * 8] */
+ 0x10, 0x02, 0x00, 0x91, /* add x16, x16, :lo12:PLTGOT + n * 8 */
+#else
+ 0x11, 0x02, 0x40, 0xb9, /* ldr w17, [x16, PLTGOT + n * 4] */
+ 0x10, 0x02, 0x00, 0x11, /* add w16, w16, :lo12:PLTGOT + n * 4 */
+#endif
+ 0x9f, 0x21, 0x03, 0xd5, /* autia1716 */
+ 0x20, 0x02, 0x1f, 0xd6, /* br x17. */
+};
+
+static const bfd_byte
+elfNN_aarch64_tlsdesc_small_plt_entry[PLT_TLSDESC_ENTRY_SIZE] =
+{
+ 0xe2, 0x0f, 0xbf, 0xa9, /* stp x2, x3, [sp, #-16]! */
+ 0x02, 0x00, 0x00, 0x90, /* adrp x2, 0 */
+ 0x03, 0x00, 0x00, 0x90, /* adrp x3, 0 */
+#if ARCH_SIZE == 64
+ 0x42, 0x00, 0x40, 0xf9, /* ldr x2, [x2, #0] */
+ 0x63, 0x00, 0x00, 0x91, /* add x3, x3, 0 */
+#else
+ 0x42, 0x00, 0x40, 0xb9, /* ldr w2, [x2, #0] */
+ 0x63, 0x00, 0x00, 0x11, /* add w3, w3, 0 */
+#endif
+ 0x40, 0x00, 0x1f, 0xd6, /* br x2 */
+ 0x1f, 0x20, 0x03, 0xd5, /* nop */
+ 0x1f, 0x20, 0x03, 0xd5, /* nop */
+};
+
+static const bfd_byte
+elfNN_aarch64_tlsdesc_small_plt_bti_entry[PLT_TLSDESC_ENTRY_SIZE] =
+{
+ 0x5f, 0x24, 0x03, 0xd5, /* bti c. */
+ 0xe2, 0x0f, 0xbf, 0xa9, /* stp x2, x3, [sp, #-16]! */
+ 0x02, 0x00, 0x00, 0x90, /* adrp x2, 0 */
+ 0x03, 0x00, 0x00, 0x90, /* adrp x3, 0 */
+#if ARCH_SIZE == 64
+ 0x42, 0x00, 0x40, 0xf9, /* ldr x2, [x2, #0] */
+ 0x63, 0x00, 0x00, 0x91, /* add x3, x3, 0 */
+#else
+ 0x42, 0x00, 0x40, 0xb9, /* ldr w2, [x2, #0] */
+ 0x63, 0x00, 0x00, 0x11, /* add w3, w3, 0 */
+#endif
+ 0x40, 0x00, 0x1f, 0xd6, /* br x2 */
+ 0x1f, 0x20, 0x03, 0xd5, /* nop */
+};
+
+#define elf_info_to_howto elfNN_aarch64_info_to_howto
+#define elf_info_to_howto_rel elfNN_aarch64_info_to_howto
+
+#define AARCH64_ELF_ABI_VERSION 0
+
+/* In case we're on a 32-bit machine, construct a 64-bit "-1" value. */
+#define ALL_ONES (~ (bfd_vma) 0)
+
+/* Indexed by the bfd interal reloc enumerators.
+ Therefore, the table needs to be synced with BFD_RELOC_AARCH64_*
+ in reloc.c. */
+
+static reloc_howto_type elfNN_aarch64_howto_table[] =
+{
+ EMPTY_HOWTO (0),
+
+ /* Basic data relocations. */
+
+ /* Deprecated, but retained for backwards compatibility. */
+ HOWTO64 (R_AARCH64_NULL, /* type */
+ 0, /* rightshift */
+ 0, /* size */
+ 0, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ "R_AARCH64_NULL", /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0, /* dst_mask */
+ false), /* pcrel_offset */
+ HOWTO (R_AARCH64_NONE, /* type */
+ 0, /* rightshift */
+ 0, /* size */
+ 0, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ "R_AARCH64_NONE", /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* .xword: (S+A) */
+ HOWTO64 (AARCH64_R (ABS64), /* type */
+ 0, /* rightshift */
+ 8, /* size */
+ 64, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_unsigned, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (ABS64), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ ALL_ONES, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* .word: (S+A) */
+ HOWTO (AARCH64_R (ABS32), /* type */
+ 0, /* rightshift */
+ 4, /* size */
+ 32, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_unsigned, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (ABS32), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffffffff, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* .half: (S+A) */
+ HOWTO (AARCH64_R (ABS16), /* type */
+ 0, /* rightshift */
+ 2, /* size */
+ 16, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_unsigned, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (ABS16), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* .xword: (S+A-P) */
+ HOWTO64 (AARCH64_R (PREL64), /* type */
+ 0, /* rightshift */
+ 8, /* size */
+ 64, /* bitsize */
+ true, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (PREL64), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ ALL_ONES, /* dst_mask */
+ true), /* pcrel_offset */
+
+ /* .word: (S+A-P) */
+ HOWTO (AARCH64_R (PREL32), /* type */
+ 0, /* rightshift */
+ 4, /* size */
+ 32, /* bitsize */
+ true, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (PREL32), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffffffff, /* dst_mask */
+ true), /* pcrel_offset */
+
+ /* .half: (S+A-P) */
+ HOWTO (AARCH64_R (PREL16), /* type */
+ 0, /* rightshift */
+ 2, /* size */
+ 16, /* bitsize */
+ true, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (PREL16), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ true), /* pcrel_offset */
+
+ /* Group relocations to create a 16, 32, 48 or 64 bit
+ unsigned data or abs address inline. */
+
+ /* MOVZ: ((S+A) >> 0) & 0xffff */
+ HOWTO (AARCH64_R (MOVW_UABS_G0), /* type */
+ 0, /* rightshift */
+ 4, /* size */
+ 16, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_unsigned, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (MOVW_UABS_G0), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* MOVK: ((S+A) >> 0) & 0xffff [no overflow check] */
+ HOWTO (AARCH64_R (MOVW_UABS_G0_NC), /* type */
+ 0, /* rightshift */
+ 4, /* size */
+ 16, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (MOVW_UABS_G0_NC), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* MOVZ: ((S+A) >> 16) & 0xffff */
+ HOWTO (AARCH64_R (MOVW_UABS_G1), /* type */
+ 16, /* rightshift */
+ 4, /* size */
+ 16, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_unsigned, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (MOVW_UABS_G1), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* MOVK: ((S+A) >> 16) & 0xffff [no overflow check] */
+ HOWTO64 (AARCH64_R (MOVW_UABS_G1_NC), /* type */
+ 16, /* rightshift */
+ 4, /* size */
+ 16, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (MOVW_UABS_G1_NC), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* MOVZ: ((S+A) >> 32) & 0xffff */
+ HOWTO64 (AARCH64_R (MOVW_UABS_G2), /* type */
+ 32, /* rightshift */
+ 4, /* size */
+ 16, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_unsigned, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (MOVW_UABS_G2), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* MOVK: ((S+A) >> 32) & 0xffff [no overflow check] */
+ HOWTO64 (AARCH64_R (MOVW_UABS_G2_NC), /* type */
+ 32, /* rightshift */
+ 4, /* size */
+ 16, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (MOVW_UABS_G2_NC), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* MOVZ: ((S+A) >> 48) & 0xffff */
+ HOWTO64 (AARCH64_R (MOVW_UABS_G3), /* type */
+ 48, /* rightshift */
+ 4, /* size */
+ 16, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_unsigned, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (MOVW_UABS_G3), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* Group relocations to create high part of a 16, 32, 48 or 64 bit
+ signed data or abs address inline. Will change instruction
+ to MOVN or MOVZ depending on sign of calculated value. */
+
+ /* MOV[ZN]: ((S+A) >> 0) & 0xffff */
+ HOWTO (AARCH64_R (MOVW_SABS_G0), /* type */
+ 0, /* rightshift */
+ 4, /* size */
+ 17, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (MOVW_SABS_G0), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* MOV[ZN]: ((S+A) >> 16) & 0xffff */
+ HOWTO64 (AARCH64_R (MOVW_SABS_G1), /* type */
+ 16, /* rightshift */
+ 4, /* size */
+ 17, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (MOVW_SABS_G1), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* MOV[ZN]: ((S+A) >> 32) & 0xffff */
+ HOWTO64 (AARCH64_R (MOVW_SABS_G2), /* type */
+ 32, /* rightshift */
+ 4, /* size */
+ 17, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (MOVW_SABS_G2), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* Group relocations to create a 16, 32, 48 or 64 bit
+ PC relative address inline. */
+
+ /* MOV[NZ]: ((S+A-P) >> 0) & 0xffff */
+ HOWTO (AARCH64_R (MOVW_PREL_G0), /* type */
+ 0, /* rightshift */
+ 4, /* size */
+ 17, /* bitsize */
+ true, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (MOVW_PREL_G0), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ true), /* pcrel_offset */
+
+ /* MOVK: ((S+A-P) >> 0) & 0xffff [no overflow check] */
+ HOWTO (AARCH64_R (MOVW_PREL_G0_NC), /* type */
+ 0, /* rightshift */
+ 4, /* size */
+ 16, /* bitsize */
+ true, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (MOVW_PREL_G0_NC), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ true), /* pcrel_offset */
+
+ /* MOV[NZ]: ((S+A-P) >> 16) & 0xffff */
+ HOWTO (AARCH64_R (MOVW_PREL_G1), /* type */
+ 16, /* rightshift */
+ 4, /* size */
+ 17, /* bitsize */
+ true, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (MOVW_PREL_G1), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ true), /* pcrel_offset */
+
+ /* MOVK: ((S+A-P) >> 16) & 0xffff [no overflow check] */
+ HOWTO64 (AARCH64_R (MOVW_PREL_G1_NC), /* type */
+ 16, /* rightshift */
+ 4, /* size */
+ 16, /* bitsize */
+ true, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (MOVW_PREL_G1_NC), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ true), /* pcrel_offset */
+
+ /* MOV[NZ]: ((S+A-P) >> 32) & 0xffff */
+ HOWTO64 (AARCH64_R (MOVW_PREL_G2), /* type */
+ 32, /* rightshift */
+ 4, /* size */
+ 17, /* bitsize */
+ true, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (MOVW_PREL_G2), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ true), /* pcrel_offset */
+
+ /* MOVK: ((S+A-P) >> 32) & 0xffff [no overflow check] */
+ HOWTO64 (AARCH64_R (MOVW_PREL_G2_NC), /* type */
+ 32, /* rightshift */
+ 4, /* size */
+ 16, /* bitsize */
+ true, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (MOVW_PREL_G2_NC), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ true), /* pcrel_offset */
+
+ /* MOV[NZ]: ((S+A-P) >> 48) & 0xffff */
+ HOWTO64 (AARCH64_R (MOVW_PREL_G3), /* type */
+ 48, /* rightshift */
+ 4, /* size */
+ 16, /* bitsize */
+ true, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (MOVW_PREL_G3), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ true), /* pcrel_offset */
+
+/* Relocations to generate 19, 21 and 33 bit PC-relative load/store
+ addresses: PG(x) is (x & ~0xfff). */
+
+ /* LD-lit: ((S+A-P) >> 2) & 0x7ffff */
+ HOWTO (AARCH64_R (LD_PREL_LO19), /* type */
+ 2, /* rightshift */
+ 4, /* size */
+ 19, /* bitsize */
+ true, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (LD_PREL_LO19), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0x7ffff, /* dst_mask */
+ true), /* pcrel_offset */
+
+ /* ADR: (S+A-P) & 0x1fffff */
+ HOWTO (AARCH64_R (ADR_PREL_LO21), /* type */
+ 0, /* rightshift */
+ 4, /* size */
+ 21, /* bitsize */
+ true, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (ADR_PREL_LO21), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0x1fffff, /* dst_mask */
+ true), /* pcrel_offset */
+
+ /* ADRP: ((PG(S+A)-PG(P)) >> 12) & 0x1fffff */
+ HOWTO (AARCH64_R (ADR_PREL_PG_HI21), /* type */
+ 12, /* rightshift */
+ 4, /* size */
+ 21, /* bitsize */
+ true, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (ADR_PREL_PG_HI21), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0x1fffff, /* dst_mask */
+ true), /* pcrel_offset */
+
+ /* ADRP: ((PG(S+A)-PG(P)) >> 12) & 0x1fffff [no overflow check] */
+ HOWTO64 (AARCH64_R (ADR_PREL_PG_HI21_NC), /* type */
+ 12, /* rightshift */
+ 4, /* size */
+ 21, /* bitsize */
+ true, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (ADR_PREL_PG_HI21_NC), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0x1fffff, /* dst_mask */
+ true), /* pcrel_offset */
+
+ /* ADD: (S+A) & 0xfff [no overflow check] */
+ HOWTO (AARCH64_R (ADD_ABS_LO12_NC), /* type */
+ 0, /* rightshift */
+ 4, /* size */
+ 12, /* bitsize */
+ false, /* pc_relative */
+ 10, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (ADD_ABS_LO12_NC), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0x3ffc00, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* LD/ST8: (S+A) & 0xfff */
+ HOWTO (AARCH64_R (LDST8_ABS_LO12_NC), /* type */
+ 0, /* rightshift */
+ 4, /* size */
+ 12, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (LDST8_ABS_LO12_NC), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xfff, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* Relocations for control-flow instructions. */
+
+ /* TBZ/NZ: ((S+A-P) >> 2) & 0x3fff */
+ HOWTO (AARCH64_R (TSTBR14), /* type */
+ 2, /* rightshift */
+ 4, /* size */
+ 14, /* bitsize */
+ true, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TSTBR14), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0x3fff, /* dst_mask */
+ true), /* pcrel_offset */
+
+ /* B.cond: ((S+A-P) >> 2) & 0x7ffff */
+ HOWTO (AARCH64_R (CONDBR19), /* type */
+ 2, /* rightshift */
+ 4, /* size */
+ 19, /* bitsize */
+ true, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (CONDBR19), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0x7ffff, /* dst_mask */
+ true), /* pcrel_offset */
+
+ /* B: ((S+A-P) >> 2) & 0x3ffffff */
+ HOWTO (AARCH64_R (JUMP26), /* type */
+ 2, /* rightshift */
+ 4, /* size */
+ 26, /* bitsize */
+ true, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (JUMP26), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0x3ffffff, /* dst_mask */
+ true), /* pcrel_offset */
+
+ /* BL: ((S+A-P) >> 2) & 0x3ffffff */
+ HOWTO (AARCH64_R (CALL26), /* type */
+ 2, /* rightshift */
+ 4, /* size */
+ 26, /* bitsize */
+ true, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (CALL26), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0x3ffffff, /* dst_mask */
+ true), /* pcrel_offset */
+
+ /* LD/ST16: (S+A) & 0xffe */
+ HOWTO (AARCH64_R (LDST16_ABS_LO12_NC), /* type */
+ 1, /* rightshift */
+ 4, /* size */
+ 12, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (LDST16_ABS_LO12_NC), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffe, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* LD/ST32: (S+A) & 0xffc */
+ HOWTO (AARCH64_R (LDST32_ABS_LO12_NC), /* type */
+ 2, /* rightshift */
+ 4, /* size */
+ 12, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (LDST32_ABS_LO12_NC), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffc, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* LD/ST64: (S+A) & 0xff8 */
+ HOWTO (AARCH64_R (LDST64_ABS_LO12_NC), /* type */
+ 3, /* rightshift */
+ 4, /* size */
+ 12, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (LDST64_ABS_LO12_NC), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xff8, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* LD/ST128: (S+A) & 0xff0 */
+ HOWTO (AARCH64_R (LDST128_ABS_LO12_NC), /* type */
+ 4, /* rightshift */
+ 4, /* size */
+ 12, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (LDST128_ABS_LO12_NC), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xff0, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* Set a load-literal immediate field to bits
+ 0x1FFFFC of G(S)-P */
+ HOWTO (AARCH64_R (GOT_LD_PREL19), /* type */
+ 2, /* rightshift */
+ 4, /* size */
+ 19, /* bitsize */
+ true, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (GOT_LD_PREL19), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffffe0, /* dst_mask */
+ true), /* pcrel_offset */
+
+ /* Get to the page for the GOT entry for the symbol
+ (G(S) - P) using an ADRP instruction. */
+ HOWTO (AARCH64_R (ADR_GOT_PAGE), /* type */
+ 12, /* rightshift */
+ 4, /* size */
+ 21, /* bitsize */
+ true, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (ADR_GOT_PAGE), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0x1fffff, /* dst_mask */
+ true), /* pcrel_offset */
+
+ /* LD64: GOT offset G(S) & 0xff8 */
+ HOWTO64 (AARCH64_R (LD64_GOT_LO12_NC), /* type */
+ 3, /* rightshift */
+ 4, /* size */
+ 12, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (LD64_GOT_LO12_NC), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xff8, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* LD32: GOT offset G(S) & 0xffc */
+ HOWTO32 (AARCH64_R (LD32_GOT_LO12_NC), /* type */
+ 2, /* rightshift */
+ 4, /* size */
+ 12, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (LD32_GOT_LO12_NC), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffc, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* Lower 16 bits of GOT offset for the symbol. */
+ HOWTO64 (AARCH64_R (MOVW_GOTOFF_G0_NC), /* type */
+ 0, /* rightshift */
+ 4, /* size */
+ 16, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (MOVW_GOTOFF_G0_NC), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* Higher 16 bits of GOT offset for the symbol. */
+ HOWTO64 (AARCH64_R (MOVW_GOTOFF_G1), /* type */
+ 16, /* rightshift */
+ 4, /* size */
+ 16, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_unsigned, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (MOVW_GOTOFF_G1), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* LD64: GOT offset for the symbol. */
+ HOWTO64 (AARCH64_R (LD64_GOTOFF_LO15), /* type */
+ 3, /* rightshift */
+ 4, /* size */
+ 12, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_unsigned, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (LD64_GOTOFF_LO15), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0x7ff8, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* LD32: GOT offset to the page address of GOT table.
+ (G(S) - PAGE (_GLOBAL_OFFSET_TABLE_)) & 0x5ffc. */
+ HOWTO32 (AARCH64_R (LD32_GOTPAGE_LO14), /* type */
+ 2, /* rightshift */
+ 4, /* size */
+ 12, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_unsigned, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (LD32_GOTPAGE_LO14), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0x5ffc, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* LD64: GOT offset to the page address of GOT table.
+ (G(S) - PAGE (_GLOBAL_OFFSET_TABLE_)) & 0x7ff8. */
+ HOWTO64 (AARCH64_R (LD64_GOTPAGE_LO15), /* type */
+ 3, /* rightshift */
+ 4, /* size */
+ 12, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_unsigned, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (LD64_GOTPAGE_LO15), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0x7ff8, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* Get to the page for the GOT entry for the symbol
+ (G(S) - P) using an ADRP instruction. */
+ HOWTO (AARCH64_R (TLSGD_ADR_PAGE21), /* type */
+ 12, /* rightshift */
+ 4, /* size */
+ 21, /* bitsize */
+ true, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSGD_ADR_PAGE21), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0x1fffff, /* dst_mask */
+ true), /* pcrel_offset */
+
+ HOWTO (AARCH64_R (TLSGD_ADR_PREL21), /* type */
+ 0, /* rightshift */
+ 4, /* size */
+ 21, /* bitsize */
+ true, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSGD_ADR_PREL21), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0x1fffff, /* dst_mask */
+ true), /* pcrel_offset */
+
+ /* ADD: GOT offset G(S) & 0xff8 [no overflow check] */
+ HOWTO (AARCH64_R (TLSGD_ADD_LO12_NC), /* type */
+ 0, /* rightshift */
+ 4, /* size */
+ 12, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSGD_ADD_LO12_NC), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xfff, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* Lower 16 bits of GOT offset to tls_index. */
+ HOWTO64 (AARCH64_R (TLSGD_MOVW_G0_NC), /* type */
+ 0, /* rightshift */
+ 4, /* size */
+ 16, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSGD_MOVW_G0_NC), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* Higher 16 bits of GOT offset to tls_index. */
+ HOWTO64 (AARCH64_R (TLSGD_MOVW_G1), /* type */
+ 16, /* rightshift */
+ 4, /* size */
+ 16, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_unsigned, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSGD_MOVW_G1), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ false), /* pcrel_offset */
+
+ HOWTO (AARCH64_R (TLSIE_ADR_GOTTPREL_PAGE21), /* type */
+ 12, /* rightshift */
+ 4, /* size */
+ 21, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSIE_ADR_GOTTPREL_PAGE21), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0x1fffff, /* dst_mask */
+ false), /* pcrel_offset */
+
+ HOWTO64 (AARCH64_R (TLSIE_LD64_GOTTPREL_LO12_NC), /* type */
+ 3, /* rightshift */
+ 4, /* size */
+ 12, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSIE_LD64_GOTTPREL_LO12_NC), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xff8, /* dst_mask */
+ false), /* pcrel_offset */
+
+ HOWTO32 (AARCH64_R (TLSIE_LD32_GOTTPREL_LO12_NC), /* type */
+ 2, /* rightshift */
+ 4, /* size */
+ 12, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSIE_LD32_GOTTPREL_LO12_NC), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffc, /* dst_mask */
+ false), /* pcrel_offset */
+
+ HOWTO (AARCH64_R (TLSIE_LD_GOTTPREL_PREL19), /* type */
+ 2, /* rightshift */
+ 4, /* size */
+ 19, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSIE_LD_GOTTPREL_PREL19), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0x1ffffc, /* dst_mask */
+ false), /* pcrel_offset */
+
+ HOWTO64 (AARCH64_R (TLSIE_MOVW_GOTTPREL_G0_NC), /* type */
+ 0, /* rightshift */
+ 4, /* size */
+ 16, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSIE_MOVW_GOTTPREL_G0_NC), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ false), /* pcrel_offset */
+
+ HOWTO64 (AARCH64_R (TLSIE_MOVW_GOTTPREL_G1), /* type */
+ 16, /* rightshift */
+ 4, /* size */
+ 16, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_unsigned, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSIE_MOVW_GOTTPREL_G1), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* ADD: bit[23:12] of byte offset to module TLS base address. */
+ HOWTO (AARCH64_R (TLSLD_ADD_DTPREL_HI12), /* type */
+ 12, /* rightshift */
+ 4, /* size */
+ 12, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_unsigned, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSLD_ADD_DTPREL_HI12), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xfff, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* Unsigned 12 bit byte offset to module TLS base address. */
+ HOWTO (AARCH64_R (TLSLD_ADD_DTPREL_LO12), /* type */
+ 0, /* rightshift */
+ 4, /* size */
+ 12, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_unsigned, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSLD_ADD_DTPREL_LO12), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xfff, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* No overflow check version of BFD_RELOC_AARCH64_TLSLD_ADD_DTPREL_LO12. */
+ HOWTO (AARCH64_R (TLSLD_ADD_DTPREL_LO12_NC), /* type */
+ 0, /* rightshift */
+ 4, /* size */
+ 12, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSLD_ADD_DTPREL_LO12_NC), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xfff, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* ADD: GOT offset G(S) & 0xff8 [no overflow check] */
+ HOWTO (AARCH64_R (TLSLD_ADD_LO12_NC), /* type */
+ 0, /* rightshift */
+ 4, /* size */
+ 12, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSLD_ADD_LO12_NC), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xfff, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* Get to the page for the GOT entry for the symbol
+ (G(S) - P) using an ADRP instruction. */
+ HOWTO (AARCH64_R (TLSLD_ADR_PAGE21), /* type */
+ 12, /* rightshift */
+ 4, /* size */
+ 21, /* bitsize */
+ true, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSLD_ADR_PAGE21), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0x1fffff, /* dst_mask */
+ true), /* pcrel_offset */
+
+ HOWTO (AARCH64_R (TLSLD_ADR_PREL21), /* type */
+ 0, /* rightshift */
+ 4, /* size */
+ 21, /* bitsize */
+ true, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSLD_ADR_PREL21), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0x1fffff, /* dst_mask */
+ true), /* pcrel_offset */
+
+ /* LD/ST16: bit[11:1] of byte offset to module TLS base address. */
+ HOWTO64 (AARCH64_R (TLSLD_LDST16_DTPREL_LO12), /* type */
+ 1, /* rightshift */
+ 4, /* size */
+ 11, /* bitsize */
+ false, /* pc_relative */
+ 10, /* bitpos */
+ complain_overflow_unsigned, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSLD_LDST16_DTPREL_LO12), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0x1ffc00, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* Same as BFD_RELOC_AARCH64_TLSLD_LDST16_DTPREL_LO12, but no overflow check. */
+ HOWTO64 (AARCH64_R (TLSLD_LDST16_DTPREL_LO12_NC), /* type */
+ 1, /* rightshift */
+ 4, /* size */
+ 11, /* bitsize */
+ false, /* pc_relative */
+ 10, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSLD_LDST16_DTPREL_LO12_NC), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0x1ffc00, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* LD/ST32: bit[11:2] of byte offset to module TLS base address. */
+ HOWTO64 (AARCH64_R (TLSLD_LDST32_DTPREL_LO12), /* type */
+ 2, /* rightshift */
+ 4, /* size */
+ 10, /* bitsize */
+ false, /* pc_relative */
+ 10, /* bitpos */
+ complain_overflow_unsigned, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSLD_LDST32_DTPREL_LO12), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0x3ffc00, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* Same as BFD_RELOC_AARCH64_TLSLD_LDST32_DTPREL_LO12, but no overflow check. */
+ HOWTO64 (AARCH64_R (TLSLD_LDST32_DTPREL_LO12_NC), /* type */
+ 2, /* rightshift */
+ 4, /* size */
+ 10, /* bitsize */
+ false, /* pc_relative */
+ 10, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSLD_LDST32_DTPREL_LO12_NC), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffc00, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* LD/ST64: bit[11:3] of byte offset to module TLS base address. */
+ HOWTO64 (AARCH64_R (TLSLD_LDST64_DTPREL_LO12), /* type */
+ 3, /* rightshift */
+ 4, /* size */
+ 9, /* bitsize */
+ false, /* pc_relative */
+ 10, /* bitpos */
+ complain_overflow_unsigned, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSLD_LDST64_DTPREL_LO12), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0x3ffc00, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* Same as BFD_RELOC_AARCH64_TLSLD_LDST64_DTPREL_LO12, but no overflow check. */
+ HOWTO64 (AARCH64_R (TLSLD_LDST64_DTPREL_LO12_NC), /* type */
+ 3, /* rightshift */
+ 4, /* size */
+ 9, /* bitsize */
+ false, /* pc_relative */
+ 10, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSLD_LDST64_DTPREL_LO12_NC), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0x7fc00, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* LD/ST8: bit[11:0] of byte offset to module TLS base address. */
+ HOWTO64 (AARCH64_R (TLSLD_LDST8_DTPREL_LO12), /* type */
+ 0, /* rightshift */
+ 4, /* size */
+ 12, /* bitsize */
+ false, /* pc_relative */
+ 10, /* bitpos */
+ complain_overflow_unsigned, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSLD_LDST8_DTPREL_LO12), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0x3ffc00, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* Same as BFD_RELOC_AARCH64_TLSLD_LDST8_DTPREL_LO12, but no overflow check. */
+ HOWTO64 (AARCH64_R (TLSLD_LDST8_DTPREL_LO12_NC), /* type */
+ 0, /* rightshift */
+ 4, /* size */
+ 12, /* bitsize */
+ false, /* pc_relative */
+ 10, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSLD_LDST8_DTPREL_LO12_NC), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0x3ffc00, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* MOVZ: bit[15:0] of byte offset to module TLS base address. */
+ HOWTO (AARCH64_R (TLSLD_MOVW_DTPREL_G0), /* type */
+ 0, /* rightshift */
+ 4, /* size */
+ 16, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_unsigned, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSLD_MOVW_DTPREL_G0), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* No overflow check version of BFD_RELOC_AARCH64_TLSLD_MOVW_DTPREL_G0. */
+ HOWTO (AARCH64_R (TLSLD_MOVW_DTPREL_G0_NC), /* type */
+ 0, /* rightshift */
+ 4, /* size */
+ 16, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSLD_MOVW_DTPREL_G0_NC), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* MOVZ: bit[31:16] of byte offset to module TLS base address. */
+ HOWTO (AARCH64_R (TLSLD_MOVW_DTPREL_G1), /* type */
+ 16, /* rightshift */
+ 4, /* size */
+ 16, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_unsigned, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSLD_MOVW_DTPREL_G1), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* No overflow check version of BFD_RELOC_AARCH64_TLSLD_MOVW_DTPREL_G1. */
+ HOWTO64 (AARCH64_R (TLSLD_MOVW_DTPREL_G1_NC), /* type */
+ 16, /* rightshift */
+ 4, /* size */
+ 16, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSLD_MOVW_DTPREL_G1_NC), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* MOVZ: bit[47:32] of byte offset to module TLS base address. */
+ HOWTO64 (AARCH64_R (TLSLD_MOVW_DTPREL_G2), /* type */
+ 32, /* rightshift */
+ 4, /* size */
+ 16, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_unsigned, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSLD_MOVW_DTPREL_G2), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ false), /* pcrel_offset */
+
+ HOWTO64 (AARCH64_R (TLSLE_MOVW_TPREL_G2), /* type */
+ 32, /* rightshift */
+ 4, /* size */
+ 16, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_unsigned, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSLE_MOVW_TPREL_G2), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ false), /* pcrel_offset */
+
+ HOWTO (AARCH64_R (TLSLE_MOVW_TPREL_G1), /* type */
+ 16, /* rightshift */
+ 4, /* size */
+ 16, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSLE_MOVW_TPREL_G1), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ false), /* pcrel_offset */
+
+ HOWTO64 (AARCH64_R (TLSLE_MOVW_TPREL_G1_NC), /* type */
+ 16, /* rightshift */
+ 4, /* size */
+ 16, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSLE_MOVW_TPREL_G1_NC), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ false), /* pcrel_offset */
+
+ HOWTO (AARCH64_R (TLSLE_MOVW_TPREL_G0), /* type */
+ 0, /* rightshift */
+ 4, /* size */
+ 16, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSLE_MOVW_TPREL_G0), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ false), /* pcrel_offset */
+
+ HOWTO (AARCH64_R (TLSLE_MOVW_TPREL_G0_NC), /* type */
+ 0, /* rightshift */
+ 4, /* size */
+ 16, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSLE_MOVW_TPREL_G0_NC), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ false), /* pcrel_offset */
+
+ HOWTO (AARCH64_R (TLSLE_ADD_TPREL_HI12), /* type */
+ 12, /* rightshift */
+ 4, /* size */
+ 12, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_unsigned, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSLE_ADD_TPREL_HI12), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xfff, /* dst_mask */
+ false), /* pcrel_offset */
+
+ HOWTO (AARCH64_R (TLSLE_ADD_TPREL_LO12), /* type */
+ 0, /* rightshift */
+ 4, /* size */
+ 12, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_unsigned, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSLE_ADD_TPREL_LO12), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xfff, /* dst_mask */
+ false), /* pcrel_offset */
+
+ HOWTO (AARCH64_R (TLSLE_ADD_TPREL_LO12_NC), /* type */
+ 0, /* rightshift */
+ 4, /* size */
+ 12, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSLE_ADD_TPREL_LO12_NC), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xfff, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* LD/ST16: bit[11:1] of byte offset to module TLS base address. */
+ HOWTO (AARCH64_R (TLSLE_LDST16_TPREL_LO12), /* type */
+ 1, /* rightshift */
+ 4, /* size */
+ 11, /* bitsize */
+ false, /* pc_relative */
+ 10, /* bitpos */
+ complain_overflow_unsigned, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSLE_LDST16_TPREL_LO12), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0x1ffc00, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* Same as BFD_RELOC_AARCH64_TLSLE_LDST16_TPREL_LO12, but no overflow check. */
+ HOWTO (AARCH64_R (TLSLE_LDST16_TPREL_LO12_NC), /* type */
+ 1, /* rightshift */
+ 4, /* size */
+ 11, /* bitsize */
+ false, /* pc_relative */
+ 10, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSLE_LDST16_TPREL_LO12_NC), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0x1ffc00, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* LD/ST32: bit[11:2] of byte offset to module TLS base address. */
+ HOWTO (AARCH64_R (TLSLE_LDST32_TPREL_LO12), /* type */
+ 2, /* rightshift */
+ 4, /* size */
+ 10, /* bitsize */
+ false, /* pc_relative */
+ 10, /* bitpos */
+ complain_overflow_unsigned, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSLE_LDST32_TPREL_LO12), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffc00, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* Same as BFD_RELOC_AARCH64_TLSLE_LDST32_TPREL_LO12, but no overflow check. */
+ HOWTO (AARCH64_R (TLSLE_LDST32_TPREL_LO12_NC), /* type */
+ 2, /* rightshift */
+ 4, /* size */
+ 10, /* bitsize */
+ false, /* pc_relative */
+ 10, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSLE_LDST32_TPREL_LO12_NC), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffc00, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* LD/ST64: bit[11:3] of byte offset to module TLS base address. */
+ HOWTO (AARCH64_R (TLSLE_LDST64_TPREL_LO12), /* type */
+ 3, /* rightshift */
+ 4, /* size */
+ 9, /* bitsize */
+ false, /* pc_relative */
+ 10, /* bitpos */
+ complain_overflow_unsigned, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSLE_LDST64_TPREL_LO12), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0x7fc00, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* Same as BFD_RELOC_AARCH64_TLSLE_LDST64_TPREL_LO12, but no overflow check. */
+ HOWTO (AARCH64_R (TLSLE_LDST64_TPREL_LO12_NC), /* type */
+ 3, /* rightshift */
+ 4, /* size */
+ 9, /* bitsize */
+ false, /* pc_relative */
+ 10, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSLE_LDST64_TPREL_LO12_NC), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0x7fc00, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* LD/ST8: bit[11:0] of byte offset to module TLS base address. */
+ HOWTO (AARCH64_R (TLSLE_LDST8_TPREL_LO12), /* type */
+ 0, /* rightshift */
+ 4, /* size */
+ 12, /* bitsize */
+ false, /* pc_relative */
+ 10, /* bitpos */
+ complain_overflow_unsigned, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSLE_LDST8_TPREL_LO12), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0x3ffc00, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* Same as BFD_RELOC_AARCH64_TLSLE_LDST8_TPREL_LO12, but no overflow check. */
+ HOWTO (AARCH64_R (TLSLE_LDST8_TPREL_LO12_NC), /* type */
+ 0, /* rightshift */
+ 4, /* size */
+ 12, /* bitsize */
+ false, /* pc_relative */
+ 10, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSLE_LDST8_TPREL_LO12_NC), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0x3ffc00, /* dst_mask */
+ false), /* pcrel_offset */
+
+ HOWTO (AARCH64_R (TLSDESC_LD_PREL19), /* type */
+ 2, /* rightshift */
+ 4, /* size */
+ 19, /* bitsize */
+ true, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSDESC_LD_PREL19), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0x0ffffe0, /* dst_mask */
+ true), /* pcrel_offset */
+
+ HOWTO (AARCH64_R (TLSDESC_ADR_PREL21), /* type */
+ 0, /* rightshift */
+ 4, /* size */
+ 21, /* bitsize */
+ true, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSDESC_ADR_PREL21), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0x1fffff, /* dst_mask */
+ true), /* pcrel_offset */
+
+ /* Get to the page for the GOT entry for the symbol
+ (G(S) - P) using an ADRP instruction. */
+ HOWTO (AARCH64_R (TLSDESC_ADR_PAGE21), /* type */
+ 12, /* rightshift */
+ 4, /* size */
+ 21, /* bitsize */
+ true, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSDESC_ADR_PAGE21), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0x1fffff, /* dst_mask */
+ true), /* pcrel_offset */
+
+ /* LD64: GOT offset G(S) & 0xff8. */
+ HOWTO64 (AARCH64_R (TLSDESC_LD64_LO12), /* type */
+ 3, /* rightshift */
+ 4, /* size */
+ 12, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSDESC_LD64_LO12), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xff8, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* LD32: GOT offset G(S) & 0xffc. */
+ HOWTO32 (AARCH64_R (TLSDESC_LD32_LO12_NC), /* type */
+ 2, /* rightshift */
+ 4, /* size */
+ 12, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSDESC_LD32_LO12_NC), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffc, /* dst_mask */
+ false), /* pcrel_offset */
+
+ /* ADD: GOT offset G(S) & 0xfff. */
+ HOWTO (AARCH64_R (TLSDESC_ADD_LO12), /* type */
+ 0, /* rightshift */
+ 4, /* size */
+ 12, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont,/* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSDESC_ADD_LO12), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xfff, /* dst_mask */
+ false), /* pcrel_offset */
+
+ HOWTO64 (AARCH64_R (TLSDESC_OFF_G1), /* type */
+ 16, /* rightshift */
+ 4, /* size */
+ 12, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_unsigned, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSDESC_OFF_G1), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ false), /* pcrel_offset */
+
+ HOWTO64 (AARCH64_R (TLSDESC_OFF_G0_NC), /* type */
+ 0, /* rightshift */
+ 4, /* size */
+ 12, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSDESC_OFF_G0_NC), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ false), /* pcrel_offset */
+
+ HOWTO64 (AARCH64_R (TLSDESC_LDR), /* type */
+ 0, /* rightshift */
+ 4, /* size */
+ 12, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSDESC_LDR), /* name */
+ false, /* partial_inplace */
+ 0x0, /* src_mask */
+ 0x0, /* dst_mask */
+ false), /* pcrel_offset */
+
+ HOWTO64 (AARCH64_R (TLSDESC_ADD), /* type */
+ 0, /* rightshift */
+ 4, /* size */
+ 12, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSDESC_ADD), /* name */
+ false, /* partial_inplace */
+ 0x0, /* src_mask */
+ 0x0, /* dst_mask */
+ false), /* pcrel_offset */
+
+ HOWTO (AARCH64_R (TLSDESC_CALL), /* type */
+ 0, /* rightshift */
+ 4, /* size */
+ 0, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSDESC_CALL), /* name */
+ false, /* partial_inplace */
+ 0x0, /* src_mask */
+ 0x0, /* dst_mask */
+ false), /* pcrel_offset */
+
+ HOWTO (AARCH64_R (COPY), /* type */
+ 0, /* rightshift */
+ 4, /* size */
+ 64, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_bitfield, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (COPY), /* name */
+ true, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffffffff, /* dst_mask */
+ false), /* pcrel_offset */
+
+ HOWTO (AARCH64_R (GLOB_DAT), /* type */
+ 0, /* rightshift */
+ 4, /* size */
+ 64, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_bitfield, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (GLOB_DAT), /* name */
+ true, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffffffff, /* dst_mask */
+ false), /* pcrel_offset */
+
+ HOWTO (AARCH64_R (JUMP_SLOT), /* type */
+ 0, /* rightshift */
+ 4, /* size */
+ 64, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_bitfield, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (JUMP_SLOT), /* name */
+ true, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffffffff, /* dst_mask */
+ false), /* pcrel_offset */
+
+ HOWTO (AARCH64_R (RELATIVE), /* type */
+ 0, /* rightshift */
+ 4, /* size */
+ 64, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_bitfield, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (RELATIVE), /* name */
+ true, /* partial_inplace */
+ 0, /* src_mask */
+ ALL_ONES, /* dst_mask */
+ false), /* pcrel_offset */
+
+ HOWTO (AARCH64_R (TLS_DTPMOD), /* type */
+ 0, /* rightshift */
+ 4, /* size */
+ 64, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+#if ARCH_SIZE == 64
+ AARCH64_R_STR (TLS_DTPMOD64), /* name */
+#else
+ AARCH64_R_STR (TLS_DTPMOD), /* name */
+#endif
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ ALL_ONES, /* dst_mask */
+ false), /* pc_reloffset */
+
+ HOWTO (AARCH64_R (TLS_DTPREL), /* type */
+ 0, /* rightshift */
+ 4, /* size */
+ 64, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+#if ARCH_SIZE == 64
+ AARCH64_R_STR (TLS_DTPREL64), /* name */
+#else
+ AARCH64_R_STR (TLS_DTPREL), /* name */
+#endif
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ ALL_ONES, /* dst_mask */
+ false), /* pcrel_offset */
+
+ HOWTO (AARCH64_R (TLS_TPREL), /* type */
+ 0, /* rightshift */
+ 4, /* size */
+ 64, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+#if ARCH_SIZE == 64
+ AARCH64_R_STR (TLS_TPREL64), /* name */
+#else
+ AARCH64_R_STR (TLS_TPREL), /* name */
+#endif
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ ALL_ONES, /* dst_mask */
+ false), /* pcrel_offset */
+
+ HOWTO (AARCH64_R (TLSDESC), /* type */
+ 0, /* rightshift */
+ 4, /* size */
+ 64, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (TLSDESC), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ ALL_ONES, /* dst_mask */
+ false), /* pcrel_offset */
+
+ HOWTO (AARCH64_R (IRELATIVE), /* type */
+ 0, /* rightshift */
+ 4, /* size */
+ 64, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_bitfield, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ AARCH64_R_STR (IRELATIVE), /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ ALL_ONES, /* dst_mask */
+ false), /* pcrel_offset */
+
+ EMPTY_HOWTO (0),
+};
+
+static reloc_howto_type elfNN_aarch64_howto_none =
+ HOWTO (R_AARCH64_NONE, /* type */
+ 0, /* rightshift */
+ 0, /* size */
+ 0, /* bitsize */
+ false, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont,/* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ "R_AARCH64_NONE", /* name */
+ false, /* partial_inplace */
+ 0, /* src_mask */
+ 0, /* dst_mask */
+ false); /* pcrel_offset */
+
+/* Given HOWTO, return the bfd internal relocation enumerator. */
+
+static bfd_reloc_code_real_type
+elfNN_aarch64_bfd_reloc_from_howto (reloc_howto_type *howto)
+{
+ const int size
+ = (int) ARRAY_SIZE (elfNN_aarch64_howto_table);
+ const ptrdiff_t offset
+ = howto - elfNN_aarch64_howto_table;
+
+ if (offset > 0 && offset < size - 1)
+ return BFD_RELOC_AARCH64_RELOC_START + offset;
+
+ if (howto == &elfNN_aarch64_howto_none)
+ return BFD_RELOC_AARCH64_NONE;
+
+ return BFD_RELOC_AARCH64_RELOC_START;
+}
+
+/* Given R_TYPE, return the bfd internal relocation enumerator. */
+
+static bfd_reloc_code_real_type
+elfNN_aarch64_bfd_reloc_from_type (bfd *abfd, unsigned int r_type)
+{
+ static bool initialized_p = false;
+ /* Indexed by R_TYPE, values are offsets in the howto_table. */
+ static unsigned int offsets[R_AARCH64_end];
+
+ if (!initialized_p)
+ {
+ unsigned int i;
+
+ for (i = 1; i < ARRAY_SIZE (elfNN_aarch64_howto_table) - 1; ++i)
+ if (elfNN_aarch64_howto_table[i].type != 0)
+ offsets[elfNN_aarch64_howto_table[i].type] = i;
+
+ initialized_p = true;
+ }
+
+ if (r_type == R_AARCH64_NONE || r_type == R_AARCH64_NULL)
+ return BFD_RELOC_AARCH64_NONE;
+
+ /* PR 17512: file: b371e70a. */
+ if (r_type >= R_AARCH64_end)
+ {
+ _bfd_error_handler (_("%pB: unsupported relocation type %#x"),
+ abfd, r_type);
+ bfd_set_error (bfd_error_bad_value);
+ return BFD_RELOC_AARCH64_NONE;
+ }
+
+ return BFD_RELOC_AARCH64_RELOC_START + offsets[r_type];
+}
+
+struct elf_aarch64_reloc_map
+{
+ bfd_reloc_code_real_type from;
+ bfd_reloc_code_real_type to;
+};
+
+/* Map bfd generic reloc to AArch64-specific reloc. */
+static const struct elf_aarch64_reloc_map elf_aarch64_reloc_map[] =
+{
+ {BFD_RELOC_NONE, BFD_RELOC_AARCH64_NONE},
+
+ /* Basic data relocations. */
+ {BFD_RELOC_CTOR, BFD_RELOC_AARCH64_NN},
+ {BFD_RELOC_64, BFD_RELOC_AARCH64_64},
+ {BFD_RELOC_32, BFD_RELOC_AARCH64_32},
+ {BFD_RELOC_16, BFD_RELOC_AARCH64_16},
+ {BFD_RELOC_64_PCREL, BFD_RELOC_AARCH64_64_PCREL},
+ {BFD_RELOC_32_PCREL, BFD_RELOC_AARCH64_32_PCREL},
+ {BFD_RELOC_16_PCREL, BFD_RELOC_AARCH64_16_PCREL},
+};
+
+/* Given the bfd internal relocation enumerator in CODE, return the
+ corresponding howto entry. */
+
+static reloc_howto_type *
+elfNN_aarch64_howto_from_bfd_reloc (bfd_reloc_code_real_type code)
+{
+ unsigned int i;
+
+ /* Convert bfd generic reloc to AArch64-specific reloc. */
+ if (code < BFD_RELOC_AARCH64_RELOC_START
+ || code > BFD_RELOC_AARCH64_RELOC_END)
+ for (i = 0; i < ARRAY_SIZE (elf_aarch64_reloc_map); i++)
+ if (elf_aarch64_reloc_map[i].from == code)
+ {
+ code = elf_aarch64_reloc_map[i].to;
+ break;
+ }
+
+ if (code > BFD_RELOC_AARCH64_RELOC_START
+ && code < BFD_RELOC_AARCH64_RELOC_END)
+ if (elfNN_aarch64_howto_table[code - BFD_RELOC_AARCH64_RELOC_START].type)
+ return &elfNN_aarch64_howto_table[code - BFD_RELOC_AARCH64_RELOC_START];
+
+ if (code == BFD_RELOC_AARCH64_NONE)
+ return &elfNN_aarch64_howto_none;
+
+ return NULL;
+}
+
+static reloc_howto_type *
+elfNN_aarch64_howto_from_type (bfd *abfd, unsigned int r_type)
+{
+ bfd_reloc_code_real_type val;
+ reloc_howto_type *howto;
+
+#if ARCH_SIZE == 32
+ if (r_type > 256)
+ {
+ bfd_set_error (bfd_error_bad_value);
+ return NULL;
+ }
+#endif
+
+ if (r_type == R_AARCH64_NONE)
+ return &elfNN_aarch64_howto_none;
+
+ val = elfNN_aarch64_bfd_reloc_from_type (abfd, r_type);
+ howto = elfNN_aarch64_howto_from_bfd_reloc (val);
+
+ if (howto != NULL)
+ return howto;
+
+ bfd_set_error (bfd_error_bad_value);
+ return NULL;
+}
+
+static bool
+elfNN_aarch64_info_to_howto (bfd *abfd, arelent *bfd_reloc,
+ Elf_Internal_Rela *elf_reloc)
+{
+ unsigned int r_type;
+
+ r_type = ELFNN_R_TYPE (elf_reloc->r_info);
+ bfd_reloc->howto = elfNN_aarch64_howto_from_type (abfd, r_type);
+
+ if (bfd_reloc->howto == NULL)
+ {
+ /* xgettext:c-format */
+ _bfd_error_handler (_("%pB: unsupported relocation type %#x"), abfd, r_type);
+ return false;
+ }
+ return true;
+}
+
+static reloc_howto_type *
+elfNN_aarch64_reloc_type_lookup (bfd *abfd ATTRIBUTE_UNUSED,
+ bfd_reloc_code_real_type code)
+{
+ reloc_howto_type *howto = elfNN_aarch64_howto_from_bfd_reloc (code);
+
+ if (howto != NULL)
+ return howto;
+
+ bfd_set_error (bfd_error_bad_value);
+ return NULL;
+}
+
+static reloc_howto_type *
+elfNN_aarch64_reloc_name_lookup (bfd *abfd ATTRIBUTE_UNUSED,
+ const char *r_name)
+{
+ unsigned int i;
+
+ for (i = 1; i < ARRAY_SIZE (elfNN_aarch64_howto_table) - 1; ++i)
+ if (elfNN_aarch64_howto_table[i].name != NULL
+ && strcasecmp (elfNN_aarch64_howto_table[i].name, r_name) == 0)
+ return &elfNN_aarch64_howto_table[i];
+
+ return NULL;
+}
+
+#define TARGET_LITTLE_SYM aarch64_elfNN_le_vec
+#define TARGET_LITTLE_NAME "elfNN-littleaarch64"
+#define TARGET_BIG_SYM aarch64_elfNN_be_vec
+#define TARGET_BIG_NAME "elfNN-bigaarch64"
+
+/* The linker script knows the section names for placement.
+ The entry_names are used to do simple name mangling on the stubs.
+ Given a function name, and its type, the stub can be found. The
+ name can be changed. The only requirement is the %s be present. */
+#define STUB_ENTRY_NAME "__%s_veneer"
+
+/* Stub name for a BTI landing stub. */
+#define BTI_STUB_ENTRY_NAME "__%s_bti_veneer"
+
+/* The name of the dynamic interpreter. This is put in the .interp
+ section. */
+#define ELF_DYNAMIC_INTERPRETER "/lib/ld.so.1"
+
+#define AARCH64_MAX_FWD_BRANCH_OFFSET \
+ (((1 << 25) - 1) << 2)
+#define AARCH64_MAX_BWD_BRANCH_OFFSET \
+ (-((1 << 25) << 2))
+
+#define AARCH64_MAX_ADRP_IMM ((1 << 20) - 1)
+#define AARCH64_MIN_ADRP_IMM (-(1 << 20))
+
+static int
+aarch64_valid_for_adrp_p (bfd_vma value, bfd_vma place)
+{
+ bfd_signed_vma offset = (bfd_signed_vma) (PG (value) - PG (place)) >> 12;
+ return offset <= AARCH64_MAX_ADRP_IMM && offset >= AARCH64_MIN_ADRP_IMM;
+}
+
+static int
+aarch64_valid_branch_p (bfd_vma value, bfd_vma place)
+{
+ bfd_signed_vma offset = (bfd_signed_vma) (value - place);
+ return (offset <= AARCH64_MAX_FWD_BRANCH_OFFSET
+ && offset >= AARCH64_MAX_BWD_BRANCH_OFFSET);
+}
+
+static const uint32_t aarch64_adrp_branch_stub [] =
+{
+ 0x90000010, /* adrp ip0, X */
+ /* R_AARCH64_ADR_HI21_PCREL(X) */
+ 0x91000210, /* add ip0, ip0, :lo12:X */
+ /* R_AARCH64_ADD_ABS_LO12_NC(X) */
+ 0xd61f0200, /* br ip0 */
+};
+
+static const uint32_t aarch64_long_branch_stub[] =
+{
+#if ARCH_SIZE == 64
+ 0x58000090, /* ldr ip0, 1f */
+#else
+ 0x18000090, /* ldr wip0, 1f */
+#endif
+ 0x10000011, /* adr ip1, #0 */
+ 0x8b110210, /* add ip0, ip0, ip1 */
+ 0xd61f0200, /* br ip0 */
+ 0x00000000, /* 1: .xword or .word
+ R_AARCH64_PRELNN(X) + 12
+ */
+ 0x00000000,
+};
+
+static const uint32_t aarch64_bti_direct_branch_stub[] =
+{
+ 0xd503245f, /* bti c */
+ 0x14000000, /* b <label> */
+};
+
+static const uint32_t aarch64_erratum_835769_stub[] =
+{
+ 0x00000000, /* Placeholder for multiply accumulate. */
+ 0x14000000, /* b <label> */
+};
+
+static const uint32_t aarch64_erratum_843419_stub[] =
+{
+ 0x00000000, /* Placeholder for LDR instruction. */
+ 0x14000000, /* b <label> */
+};
+
+/* Section name for stubs is the associated section name plus this
+ string. */
+#define STUB_SUFFIX ".stub"
+
+enum elf_aarch64_stub_type
+{
+ aarch64_stub_none,
+ aarch64_stub_adrp_branch,
+ aarch64_stub_long_branch,
+ aarch64_stub_bti_direct_branch,
+ aarch64_stub_erratum_835769_veneer,
+ aarch64_stub_erratum_843419_veneer,
+};
+
+struct elf_aarch64_stub_hash_entry
+{
+ /* Base hash table entry structure. */
+ struct bfd_hash_entry root;
+
+ /* The stub section. */
+ asection *stub_sec;
+
+ /* Offset within stub_sec of the beginning of this stub. */
+ bfd_vma stub_offset;
+
+ /* Given the symbol's value and its section we can determine its final
+ value when building the stubs (so the stub knows where to jump). */
+ bfd_vma target_value;
+ asection *target_section;
+
+ enum elf_aarch64_stub_type stub_type;
+
+ /* The symbol table entry, if any, that this was derived from. */
+ struct elf_aarch64_link_hash_entry *h;
+
+ /* Destination symbol type */
+ unsigned char st_type;
+
+ /* The target is also a stub. */
+ bool double_stub;
+
+ /* Where this stub is being called from, or, in the case of combined
+ stub sections, the first input section in the group. */
+ asection *id_sec;
+
+ /* The name for the local symbol at the start of this stub. The
+ stub name in the hash table has to be unique; this does not, so
+ it can be friendlier. */
+ char *output_name;
+
+ /* The instruction which caused this stub to be generated (only valid for
+ erratum 835769 workaround stubs at present). */
+ uint32_t veneered_insn;
+
+ /* In an erratum 843419 workaround stub, the ADRP instruction offset. */
+ bfd_vma adrp_offset;
+};
+
+/* Used to build a map of a section. This is required for mixed-endian
+ code/data. */
+
+typedef struct elf_elf_section_map
+{
+ bfd_vma vma;
+ char type;
+}
+elf_aarch64_section_map;
+
+
+typedef struct _aarch64_elf_section_data
+{
+ struct bfd_elf_section_data elf;
+ unsigned int mapcount;
+ unsigned int mapsize;
+ elf_aarch64_section_map *map;
+}
+_aarch64_elf_section_data;
+
+#define elf_aarch64_section_data(sec) \
+ ((_aarch64_elf_section_data *) elf_section_data (sec))
+
+/* The size of the thread control block which is defined to be two pointers. */
+#define TCB_SIZE (ARCH_SIZE/8)*2
+
+struct elf_aarch64_local_symbol
+{
+ unsigned int got_type;
+ bfd_signed_vma got_refcount;
+ bfd_vma got_offset;
+
+ /* Offset of the GOTPLT entry reserved for the TLS descriptor. The
+ offset is from the end of the jump table and reserved entries
+ within the PLTGOT.
+
+ The magic value (bfd_vma) -1 indicates that an offset has not be
+ allocated. */
+ bfd_vma tlsdesc_got_jump_table_offset;
+};
+
+#define elf_aarch64_locals(bfd) (elf_aarch64_tdata (bfd)->locals)
+
+#define is_aarch64_elf(bfd) \
+ (bfd_get_flavour (bfd) == bfd_target_elf_flavour \
+ && elf_tdata (bfd) != NULL \
+ && elf_object_id (bfd) == AARCH64_ELF_DATA)
+
+static bool
+elfNN_aarch64_mkobject (bfd *abfd)
+{
+ return bfd_elf_allocate_object (abfd, sizeof (struct elf_aarch64_obj_tdata));
+}
+
+#define elf_aarch64_hash_entry(ent) \
+ ((struct elf_aarch64_link_hash_entry *)(ent))
+
+#define GOT_UNKNOWN 0
+#define GOT_NORMAL 1
+#define GOT_TLS_GD 2
+#define GOT_TLS_IE 4
+#define GOT_TLSDESC_GD 8
+
+#define GOT_TLS_GD_ANY_P(type) ((type & GOT_TLS_GD) || (type & GOT_TLSDESC_GD))
+
+/* AArch64 ELF linker hash entry. */
+struct elf_aarch64_link_hash_entry
+{
+ struct elf_link_hash_entry root;
+
+ /* Since PLT entries have variable size, we need to record the
+ index into .got.plt instead of recomputing it from the PLT
+ offset. */
+ bfd_signed_vma plt_got_offset;
+
+ /* Bit mask representing the type of GOT entry(s) if any required by
+ this symbol. */
+ unsigned int got_type;
+
+ /* TRUE if symbol is defined as a protected symbol. */
+ unsigned int def_protected : 1;
+
+ /* A pointer to the most recently used stub hash entry against this
+ symbol. */
+ struct elf_aarch64_stub_hash_entry *stub_cache;
+
+ /* Offset of the GOTPLT entry reserved for the TLS descriptor. The offset
+ is from the end of the jump table and reserved entries within the PLTGOT.
+
+ The magic value (bfd_vma) -1 indicates that an offset has not
+ be allocated. */
+ bfd_vma tlsdesc_got_jump_table_offset;
+};
+
+static unsigned int
+elfNN_aarch64_symbol_got_type (struct elf_link_hash_entry *h,
+ bfd *abfd,
+ unsigned long r_symndx)
+{
+ if (h)
+ return elf_aarch64_hash_entry (h)->got_type;
+
+ if (! elf_aarch64_locals (abfd))
+ return GOT_UNKNOWN;
+
+ return elf_aarch64_locals (abfd)[r_symndx].got_type;
+}
+
+/* Get the AArch64 elf linker hash table from a link_info structure. */
+#define elf_aarch64_hash_table(info) \
+ ((struct elf_aarch64_link_hash_table *) ((info)->hash))
+
+#define aarch64_stub_hash_lookup(table, string, create, copy) \
+ ((struct elf_aarch64_stub_hash_entry *) \
+ bfd_hash_lookup ((table), (string), (create), (copy)))
+
+/* AArch64 ELF linker hash table. */
+struct elf_aarch64_link_hash_table
+{
+ /* The main hash table. */
+ struct elf_link_hash_table root;
+
+ /* Nonzero to force PIC branch veneers. */
+ int pic_veneer;
+
+ /* Fix erratum 835769. */
+ int fix_erratum_835769;
+
+ /* Fix erratum 843419. */
+ erratum_84319_opts fix_erratum_843419;
+
+ /* Don't apply link-time values for dynamic relocations. */
+ int no_apply_dynamic_relocs;
+
+ /* The number of bytes in the initial entry in the PLT. */
+ bfd_size_type plt_header_size;
+
+ /* The bytes of the initial PLT entry. */
+ const bfd_byte *plt0_entry;
+
+ /* The number of bytes in the subsequent PLT entries. */
+ bfd_size_type plt_entry_size;
+
+ /* The bytes of the subsequent PLT entry. */
+ const bfd_byte *plt_entry;
+
+ /* PLT entries have a common shape, but may have some pre-amble
+ instructions (such as BTI). This delta is used to factor this
+ out of the common code. */
+ int plt_entry_delta;
+
+ /* For convenience in allocate_dynrelocs. */
+ bfd *obfd;
+
+ /* The amount of space used by the reserved portion of the sgotplt
+ section, plus whatever space is used by the jump slots. */
+ bfd_vma sgotplt_jump_table_size;
+
+ /* The stub hash table. */
+ struct bfd_hash_table stub_hash_table;
+
+ /* Linker stub bfd. */
+ bfd *stub_bfd;
+
+ /* Linker call-backs. */
+ asection *(*add_stub_section) (const char *, asection *);
+ void (*layout_sections_again) (void);
+
+ /* Array to keep track of which stub sections have been created, and
+ information on stub grouping. */
+ struct map_stub
+ {
+ /* This is the section to which stubs in the group will be
+ attached. */
+ asection *link_sec;
+ /* The stub section. */
+ asection *stub_sec;
+ } *stub_group;
+
+ /* Assorted information used by elfNN_aarch64_size_stubs. */
+ unsigned int bfd_count;
+ unsigned int top_index;
+ asection **input_list;
+
+ /* True when two stubs are added where one targets the other, happens
+ when BTI stubs are inserted and then the stub layout must not change
+ during elfNN_aarch64_build_stubs. */
+ bool has_double_stub;
+
+ /* JUMP_SLOT relocs for variant PCS symbols may be present. */
+ int variant_pcs;
+
+ /* The number of bytes in the PLT enty for the TLS descriptor. */
+ bfd_size_type tlsdesc_plt_entry_size;
+
+ /* Used by local STT_GNU_IFUNC symbols. */
+ htab_t loc_hash_table;
+ void * loc_hash_memory;
+
+ /* Array of relative relocs to be emitted in DT_RELR format. */
+ bfd_size_type relr_alloc;
+ bfd_size_type relr_count;
+ struct relr_entry
+ {
+ asection *sec;
+ bfd_vma off;
+ } *relr;
+ /* Sorted output addresses of above relative relocs. */
+ bfd_vma *relr_sorted;
+ /* Layout recomputation count. */
+ bfd_size_type relr_layout_iter;
+};
+
+/* Create an entry in an AArch64 ELF linker hash table. */
+
+static struct bfd_hash_entry *
+elfNN_aarch64_link_hash_newfunc (struct bfd_hash_entry *entry,
+ struct bfd_hash_table *table,
+ const char *string)
+{
+ struct elf_aarch64_link_hash_entry *ret =
+ (struct elf_aarch64_link_hash_entry *) entry;
+
+ /* Allocate the structure if it has not already been allocated by a
+ subclass. */
+ if (ret == NULL)
+ ret = bfd_hash_allocate (table,
+ sizeof (struct elf_aarch64_link_hash_entry));
+ if (ret == NULL)
+ return (struct bfd_hash_entry *) ret;
+
+ /* Call the allocation method of the superclass. */
+ ret = ((struct elf_aarch64_link_hash_entry *)
+ _bfd_elf_link_hash_newfunc ((struct bfd_hash_entry *) ret,
+ table, string));
+ if (ret != NULL)
+ {
+ ret->got_type = GOT_UNKNOWN;
+ ret->def_protected = 0;
+ ret->plt_got_offset = (bfd_vma) - 1;
+ ret->stub_cache = NULL;
+ ret->tlsdesc_got_jump_table_offset = (bfd_vma) - 1;
+ }
+
+ return (struct bfd_hash_entry *) ret;
+}
+
+/* Initialize an entry in the stub hash table. */
+
+static struct bfd_hash_entry *
+stub_hash_newfunc (struct bfd_hash_entry *entry,
+ struct bfd_hash_table *table, const char *string)
+{
+ /* Allocate the structure if it has not already been allocated by a
+ subclass. */
+ if (entry == NULL)
+ {
+ entry = bfd_hash_allocate (table,
+ sizeof (struct
+ elf_aarch64_stub_hash_entry));
+ if (entry == NULL)
+ return entry;
+ }
+
+ /* Call the allocation method of the superclass. */
+ entry = bfd_hash_newfunc (entry, table, string);
+ if (entry != NULL)
+ {
+ struct elf_aarch64_stub_hash_entry *eh;
+
+ /* Initialize the local fields. */
+ eh = (struct elf_aarch64_stub_hash_entry *) entry;
+ memset (&eh->stub_sec, 0,
+ (sizeof (struct elf_aarch64_stub_hash_entry)
+ - offsetof (struct elf_aarch64_stub_hash_entry, stub_sec)));
+ }
+
+ return entry;
+}
+
+/* Compute a hash of a local hash entry. We use elf_link_hash_entry
+ for local symbol so that we can handle local STT_GNU_IFUNC symbols
+ as global symbol. We reuse indx and dynstr_index for local symbol
+ hash since they aren't used by global symbols in this backend. */
+
+static hashval_t
+elfNN_aarch64_local_htab_hash (const void *ptr)
+{
+ struct elf_link_hash_entry *h
+ = (struct elf_link_hash_entry *) ptr;
+ return ELF_LOCAL_SYMBOL_HASH (h->indx, h->dynstr_index);
+}
+
+/* Compare local hash entries. */
+
+static int
+elfNN_aarch64_local_htab_eq (const void *ptr1, const void *ptr2)
+{
+ struct elf_link_hash_entry *h1
+ = (struct elf_link_hash_entry *) ptr1;
+ struct elf_link_hash_entry *h2
+ = (struct elf_link_hash_entry *) ptr2;
+
+ return h1->indx == h2->indx && h1->dynstr_index == h2->dynstr_index;
+}
+
+/* Find and/or create a hash entry for local symbol. */
+
+static struct elf_link_hash_entry *
+elfNN_aarch64_get_local_sym_hash (struct elf_aarch64_link_hash_table *htab,
+ bfd *abfd, const Elf_Internal_Rela *rel,
+ bool create)
+{
+ struct elf_aarch64_link_hash_entry e, *ret;
+ asection *sec = abfd->sections;
+ hashval_t h = ELF_LOCAL_SYMBOL_HASH (sec->id,
+ ELFNN_R_SYM (rel->r_info));
+ void **slot;
+
+ e.root.indx = sec->id;
+ e.root.dynstr_index = ELFNN_R_SYM (rel->r_info);
+ slot = htab_find_slot_with_hash (htab->loc_hash_table, &e, h,
+ create ? INSERT : NO_INSERT);
+
+ if (!slot)
+ return NULL;
+
+ if (*slot)
+ {
+ ret = (struct elf_aarch64_link_hash_entry *) *slot;
+ return &ret->root;
+ }
+
+ ret = (struct elf_aarch64_link_hash_entry *)
+ objalloc_alloc ((struct objalloc *) htab->loc_hash_memory,
+ sizeof (struct elf_aarch64_link_hash_entry));
+ if (ret)
+ {
+ memset (ret, 0, sizeof (*ret));
+ ret->root.indx = sec->id;
+ ret->root.dynstr_index = ELFNN_R_SYM (rel->r_info);
+ ret->root.dynindx = -1;
+ *slot = ret;
+ }
+ return &ret->root;
+}
+
+/* Copy the extra info we tack onto an elf_link_hash_entry. */
+
+static void
+elfNN_aarch64_copy_indirect_symbol (struct bfd_link_info *info,
+ struct elf_link_hash_entry *dir,
+ struct elf_link_hash_entry *ind)
+{
+ struct elf_aarch64_link_hash_entry *edir, *eind;
+
+ edir = (struct elf_aarch64_link_hash_entry *) dir;
+ eind = (struct elf_aarch64_link_hash_entry *) ind;
+
+ if (ind->root.type == bfd_link_hash_indirect)
+ {
+ /* Copy over PLT info. */
+ if (dir->got.refcount <= 0)
+ {
+ edir->got_type = eind->got_type;
+ eind->got_type = GOT_UNKNOWN;
+ }
+ }
+
+ _bfd_elf_link_hash_copy_indirect (info, dir, ind);
+}
+
+/* Merge non-visibility st_other attributes. */
+
+static void
+elfNN_aarch64_merge_symbol_attribute (struct elf_link_hash_entry *h,
+ unsigned int st_other,
+ bool definition,
+ bool dynamic ATTRIBUTE_UNUSED)
+{
+ if (definition)
+ {
+ struct elf_aarch64_link_hash_entry *eh
+ = (struct elf_aarch64_link_hash_entry *)h;
+ eh->def_protected = ELF_ST_VISIBILITY (st_other) == STV_PROTECTED;
+ }
+
+ unsigned int isym_sto = st_other & ~ELF_ST_VISIBILITY (-1);
+ unsigned int h_sto = h->other & ~ELF_ST_VISIBILITY (-1);
+
+ if (isym_sto == h_sto)
+ return;
+
+ if (isym_sto & ~STO_AARCH64_VARIANT_PCS)
+ /* Not fatal, this callback cannot fail. */
+ _bfd_error_handler (_("unknown attribute for symbol `%s': 0x%02x"),
+ h->root.root.string, isym_sto);
+
+ /* Note: Ideally we would warn about any attribute mismatch, but
+ this api does not allow that without substantial changes. */
+ if (isym_sto & STO_AARCH64_VARIANT_PCS)
+ h->other |= STO_AARCH64_VARIANT_PCS;
+}
+
+/* Destroy an AArch64 elf linker hash table. */
+
+static void
+elfNN_aarch64_link_hash_table_free (bfd *obfd)
+{
+ struct elf_aarch64_link_hash_table *ret
+ = (struct elf_aarch64_link_hash_table *) obfd->link.hash;
+
+ if (ret->loc_hash_table)
+ htab_delete (ret->loc_hash_table);
+ if (ret->loc_hash_memory)
+ objalloc_free ((struct objalloc *) ret->loc_hash_memory);
+
+ bfd_hash_table_free (&ret->stub_hash_table);
+ _bfd_elf_link_hash_table_free (obfd);
+}
+
+/* Create an AArch64 elf linker hash table. */
+
+static struct bfd_link_hash_table *
+elfNN_aarch64_link_hash_table_create (bfd *abfd)
+{
+ struct elf_aarch64_link_hash_table *ret;
+ size_t amt = sizeof (struct elf_aarch64_link_hash_table);
+
+ ret = bfd_zmalloc (amt);
+ if (ret == NULL)
+ return NULL;
+
+ if (!_bfd_elf_link_hash_table_init
+ (&ret->root, abfd, elfNN_aarch64_link_hash_newfunc,
+ sizeof (struct elf_aarch64_link_hash_entry)))
+ {
+ free (ret);
+ return NULL;
+ }
+
+ ret->plt_header_size = PLT_ENTRY_SIZE;
+ ret->plt0_entry = elfNN_aarch64_small_plt0_entry;
+ ret->plt_entry_size = PLT_SMALL_ENTRY_SIZE;
+ ret->plt_entry_delta = 0;
+ ret->plt_entry = elfNN_aarch64_small_plt_entry;
+ ret->tlsdesc_plt_entry_size = PLT_TLSDESC_ENTRY_SIZE;
+ ret->obfd = abfd;
+ ret->root.tlsdesc_got = (bfd_vma) - 1;
+
+ if (!bfd_hash_table_init (&ret->stub_hash_table, stub_hash_newfunc,
+ sizeof (struct elf_aarch64_stub_hash_entry)))
+ {
+ _bfd_elf_link_hash_table_free (abfd);
+ return NULL;
+ }
+
+ ret->loc_hash_table = htab_try_create (1024,
+ elfNN_aarch64_local_htab_hash,
+ elfNN_aarch64_local_htab_eq,
+ NULL);
+ ret->loc_hash_memory = objalloc_create ();
+ if (!ret->loc_hash_table || !ret->loc_hash_memory)
+ {
+ elfNN_aarch64_link_hash_table_free (abfd);
+ return NULL;
+ }
+ ret->root.root.hash_table_free = elfNN_aarch64_link_hash_table_free;
+
+ return &ret->root.root;
+}
+
+/* Perform relocation R_TYPE. Returns TRUE upon success, FALSE otherwise. */
+
+static bool
+aarch64_relocate (unsigned int r_type, bfd *input_bfd, asection *input_section,
+ bfd_vma offset, bfd_vma value)
+{
+ reloc_howto_type *howto;
+ bfd_vma place;
+
+ howto = elfNN_aarch64_howto_from_type (input_bfd, r_type);
+ place = (input_section->output_section->vma + input_section->output_offset
+ + offset);
+
+ r_type = elfNN_aarch64_bfd_reloc_from_type (input_bfd, r_type);
+ value = _bfd_aarch64_elf_resolve_relocation (input_bfd, r_type, place,
+ value, 0, false);
+ return _bfd_aarch64_elf_put_addend (input_bfd,
+ input_section->contents + offset, r_type,
+ howto, value) == bfd_reloc_ok;
+}
+
+/* Determine the type of stub needed, if any, for a call. */
+
+static enum elf_aarch64_stub_type
+aarch64_type_of_stub (asection *input_sec,
+ const Elf_Internal_Rela *rel,
+ asection *sym_sec,
+ unsigned char st_type,
+ bfd_vma destination)
+{
+ bfd_vma location;
+ bfd_signed_vma branch_offset;
+ unsigned int r_type;
+ enum elf_aarch64_stub_type stub_type = aarch64_stub_none;
+
+ if (st_type != STT_FUNC
+ && (sym_sec == input_sec))
+ return stub_type;
+
+ /* Determine where the call point is. */
+ location = (input_sec->output_offset
+ + input_sec->output_section->vma + rel->r_offset);
+
+ branch_offset = (bfd_signed_vma) (destination - location);
+
+ r_type = ELFNN_R_TYPE (rel->r_info);
+
+ /* We don't want to redirect any old unconditional jump in this way,
+ only one which is being used for a sibcall, where it is
+ acceptable for the IP0 and IP1 registers to be clobbered. */
+ if ((r_type == AARCH64_R (CALL26) || r_type == AARCH64_R (JUMP26))
+ && (branch_offset > AARCH64_MAX_FWD_BRANCH_OFFSET
+ || branch_offset < AARCH64_MAX_BWD_BRANCH_OFFSET))
+ {
+ stub_type = aarch64_stub_long_branch;
+ }
+
+ return stub_type;
+}
+
+/* Build a name for an entry in the stub hash table. */
+
+static char *
+elfNN_aarch64_stub_name (const asection *input_section,
+ const asection *sym_sec,
+ const struct elf_aarch64_link_hash_entry *hash,
+ const Elf_Internal_Rela *rel)
+{
+ char *stub_name;
+ bfd_size_type len;
+
+ if (hash)
+ {
+ len = 8 + 1 + strlen (hash->root.root.root.string) + 1 + 16 + 1;
+ stub_name = bfd_malloc (len);
+ if (stub_name != NULL)
+ snprintf (stub_name, len, "%08x_%s+%" PRIx64,
+ (unsigned int) input_section->id,
+ hash->root.root.root.string,
+ (uint64_t) rel->r_addend);
+ }
+ else
+ {
+ len = 8 + 1 + 8 + 1 + 8 + 1 + 16 + 1;
+ stub_name = bfd_malloc (len);
+ if (stub_name != NULL)
+ snprintf (stub_name, len, "%08x_%x:%x+%" PRIx64,
+ (unsigned int) input_section->id,
+ (unsigned int) sym_sec->id,
+ (unsigned int) ELFNN_R_SYM (rel->r_info),
+ (uint64_t) rel->r_addend);
+ }
+
+ return stub_name;
+}
+
+/* Return TRUE if symbol H should be hashed in the `.gnu.hash' section. For
+ executable PLT slots where the executable never takes the address of those
+ functions, the function symbols are not added to the hash table. */
+
+static bool
+elf_aarch64_hash_symbol (struct elf_link_hash_entry *h)
+{
+ if (h->plt.offset != (bfd_vma) -1
+ && !h->def_regular
+ && !h->pointer_equality_needed)
+ return false;
+
+ return _bfd_elf_hash_symbol (h);
+}
+
+
+/* Look up an entry in the stub hash. Stub entries are cached because
+ creating the stub name takes a bit of time. */
+
+static struct elf_aarch64_stub_hash_entry *
+elfNN_aarch64_get_stub_entry (const asection *input_section,
+ const asection *sym_sec,
+ struct elf_link_hash_entry *hash,
+ const Elf_Internal_Rela *rel,
+ struct elf_aarch64_link_hash_table *htab)
+{
+ struct elf_aarch64_stub_hash_entry *stub_entry;
+ struct elf_aarch64_link_hash_entry *h =
+ (struct elf_aarch64_link_hash_entry *) hash;
+ const asection *id_sec;
+
+ if ((input_section->flags & SEC_CODE) == 0)
+ return NULL;
+
+ /* If this input section is part of a group of sections sharing one
+ stub section, then use the id of the first section in the group.
+ Stub names need to include a section id, as there may well be
+ more than one stub used to reach say, printf, and we need to
+ distinguish between them. */
+ id_sec = htab->stub_group[input_section->id].link_sec;
+
+ if (h != NULL && h->stub_cache != NULL
+ && h->stub_cache->h == h && h->stub_cache->id_sec == id_sec)
+ {
+ stub_entry = h->stub_cache;
+ }
+ else
+ {
+ char *stub_name;
+
+ stub_name = elfNN_aarch64_stub_name (id_sec, sym_sec, h, rel);
+ if (stub_name == NULL)
+ return NULL;
+
+ stub_entry = aarch64_stub_hash_lookup (&htab->stub_hash_table,
+ stub_name, false, false);
+ if (h != NULL)
+ h->stub_cache = stub_entry;
+
+ free (stub_name);
+ }
+
+ return stub_entry;
+}
+
+
+/* Create a stub section. */
+
+static asection *
+_bfd_aarch64_create_stub_section (asection *section,
+ struct elf_aarch64_link_hash_table *htab)
+{
+ size_t namelen;
+ bfd_size_type len;
+ char *s_name;
+
+ namelen = strlen (section->name);
+ len = namelen + sizeof (STUB_SUFFIX);
+ s_name = bfd_alloc (htab->stub_bfd, len);
+ if (s_name == NULL)
+ return NULL;
+
+ memcpy (s_name, section->name, namelen);
+ memcpy (s_name + namelen, STUB_SUFFIX, sizeof (STUB_SUFFIX));
+ return (*htab->add_stub_section) (s_name, section);
+}
+
+
+/* Find or create a stub section for a link section.
+
+ Fix or create the stub section used to collect stubs attached to
+ the specified link section. */
+
+static asection *
+_bfd_aarch64_get_stub_for_link_section (asection *link_section,
+ struct elf_aarch64_link_hash_table *htab)
+{
+ if (htab->stub_group[link_section->id].stub_sec == NULL)
+ htab->stub_group[link_section->id].stub_sec
+ = _bfd_aarch64_create_stub_section (link_section, htab);
+ return htab->stub_group[link_section->id].stub_sec;
+}
+
+
+/* Find or create a stub section in the stub group for an input
+ section. */
+
+static asection *
+_bfd_aarch64_create_or_find_stub_sec (asection *section,
+ struct elf_aarch64_link_hash_table *htab)
+{
+ asection *link_sec = htab->stub_group[section->id].link_sec;
+ return _bfd_aarch64_get_stub_for_link_section (link_sec, htab);
+}
+
+
+/* Add a new stub entry in the stub group associated with an input
+ section to the stub hash. Not all fields of the new stub entry are
+ initialised. */
+
+static struct elf_aarch64_stub_hash_entry *
+_bfd_aarch64_add_stub_entry_in_group (const char *stub_name,
+ asection *section,
+ struct elf_aarch64_link_hash_table *htab)
+{
+ asection *link_sec;
+ asection *stub_sec;
+ struct elf_aarch64_stub_hash_entry *stub_entry;
+
+ link_sec = htab->stub_group[section->id].link_sec;
+ stub_sec = _bfd_aarch64_create_or_find_stub_sec (section, htab);
+
+ /* Enter this entry into the linker stub hash table. */
+ stub_entry = aarch64_stub_hash_lookup (&htab->stub_hash_table, stub_name,
+ true, false);
+ if (stub_entry == NULL)
+ {
+ /* xgettext:c-format */
+ _bfd_error_handler (_("%pB: cannot create stub entry %s"),
+ section->owner, stub_name);
+ return NULL;
+ }
+
+ stub_entry->stub_sec = stub_sec;
+ stub_entry->stub_offset = 0;
+ stub_entry->id_sec = link_sec;
+
+ return stub_entry;
+}
+
+/* Add a new stub entry in the final stub section to the stub hash.
+ Not all fields of the new stub entry are initialised. */
+
+static struct elf_aarch64_stub_hash_entry *
+_bfd_aarch64_add_stub_entry_after (const char *stub_name,
+ asection *link_section,
+ struct elf_aarch64_link_hash_table *htab)
+{
+ asection *stub_sec;
+ struct elf_aarch64_stub_hash_entry *stub_entry;
+
+ stub_sec = NULL;
+ /* Only create the actual stub if we will end up needing it. */
+ if (htab->fix_erratum_843419 & ERRAT_ADRP)
+ stub_sec = _bfd_aarch64_get_stub_for_link_section (link_section, htab);
+ stub_entry = aarch64_stub_hash_lookup (&htab->stub_hash_table, stub_name,
+ true, false);
+ if (stub_entry == NULL)
+ {
+ _bfd_error_handler (_("cannot create stub entry %s"), stub_name);
+ return NULL;
+ }
+
+ stub_entry->stub_sec = stub_sec;
+ stub_entry->stub_offset = 0;
+ stub_entry->id_sec = link_section;
+
+ return stub_entry;
+}
+
+
+static bool
+aarch64_build_one_stub (struct bfd_hash_entry *gen_entry,
+ void *in_arg)
+{
+ struct elf_aarch64_stub_hash_entry *stub_entry;
+ asection *stub_sec;
+ bfd *stub_bfd;
+ bfd_byte *loc;
+ bfd_vma sym_value;
+ bfd_vma veneered_insn_loc;
+ bfd_vma veneer_entry_loc;
+ bfd_signed_vma branch_offset = 0;
+ unsigned int template_size;
+ unsigned int pad_size = 0;
+ const uint32_t *template;
+ unsigned int i;
+ struct bfd_link_info *info;
+ struct elf_aarch64_link_hash_table *htab;
+
+ /* Massage our args to the form they really have. */
+ stub_entry = (struct elf_aarch64_stub_hash_entry *) gen_entry;
+
+ info = (struct bfd_link_info *) in_arg;
+ htab = elf_aarch64_hash_table (info);
+
+ /* Fail if the target section could not be assigned to an output
+ section. The user should fix his linker script. */
+ if (stub_entry->target_section->output_section == NULL
+ && info->non_contiguous_regions)
+ info->callbacks->einfo (_("%F%P: Could not assign `%pA' to an output section. "
+ "Retry without "
+ "--enable-non-contiguous-regions.\n"),
+ stub_entry->target_section);
+
+ stub_sec = stub_entry->stub_sec;
+
+ /* The layout must not change when a stub may be the target of another. */
+ if (htab->has_double_stub)
+ BFD_ASSERT (stub_entry->stub_offset == stub_sec->size);
+
+ /* Make a note of the offset within the stubs for this entry. */
+ stub_entry->stub_offset = stub_sec->size;
+ loc = stub_sec->contents + stub_entry->stub_offset;
+
+ stub_bfd = stub_sec->owner;
+
+ /* This is the address of the stub destination. */
+ sym_value = (stub_entry->target_value
+ + stub_entry->target_section->output_offset
+ + stub_entry->target_section->output_section->vma);
+
+ if (stub_entry->stub_type == aarch64_stub_long_branch)
+ {
+ bfd_vma place = (stub_entry->stub_offset + stub_sec->output_section->vma
+ + stub_sec->output_offset);
+
+ /* See if we can relax the stub. */
+ if (aarch64_valid_for_adrp_p (sym_value, place))
+ {
+ stub_entry->stub_type = aarch64_stub_adrp_branch;
+
+ /* Avoid the relaxation changing the layout. */
+ if (htab->has_double_stub)
+ pad_size = sizeof (aarch64_long_branch_stub)
+ - sizeof (aarch64_adrp_branch_stub);
+ }
+ }
+
+ switch (stub_entry->stub_type)
+ {
+ case aarch64_stub_adrp_branch:
+ template = aarch64_adrp_branch_stub;
+ template_size = sizeof (aarch64_adrp_branch_stub);
+ break;
+ case aarch64_stub_long_branch:
+ template = aarch64_long_branch_stub;
+ template_size = sizeof (aarch64_long_branch_stub);
+ break;
+ case aarch64_stub_bti_direct_branch:
+ template = aarch64_bti_direct_branch_stub;
+ template_size = sizeof (aarch64_bti_direct_branch_stub);
+ break;
+ case aarch64_stub_erratum_835769_veneer:
+ template = aarch64_erratum_835769_stub;
+ template_size = sizeof (aarch64_erratum_835769_stub);
+ break;
+ case aarch64_stub_erratum_843419_veneer:
+ template = aarch64_erratum_843419_stub;
+ template_size = sizeof (aarch64_erratum_843419_stub);
+ break;
+ default:
+ abort ();
+ }
+
+ for (i = 0; i < (template_size / sizeof template[0]); i++)
+ {
+ bfd_putl32 (template[i], loc);
+ loc += 4;
+ }
+
+ template_size += pad_size;
+ template_size = (template_size + 7) & ~7;
+ stub_sec->size += template_size;
+
+ switch (stub_entry->stub_type)
+ {
+ case aarch64_stub_adrp_branch:
+ if (!aarch64_relocate (AARCH64_R (ADR_PREL_PG_HI21), stub_bfd, stub_sec,
+ stub_entry->stub_offset, sym_value))
+ /* The stub would not have been relaxed if the offset was out
+ of range. */
+ BFD_FAIL ();
+
+ if (!aarch64_relocate (AARCH64_R (ADD_ABS_LO12_NC), stub_bfd, stub_sec,
+ stub_entry->stub_offset + 4, sym_value))
+ BFD_FAIL ();
+ break;
+
+ case aarch64_stub_long_branch:
+ /* We want the value relative to the address 12 bytes back from the
+ value itself. */
+ if (!aarch64_relocate (AARCH64_R (PRELNN), stub_bfd, stub_sec,
+ stub_entry->stub_offset + 16, sym_value + 12))
+ BFD_FAIL ();
+ break;
+
+ case aarch64_stub_bti_direct_branch:
+ if (!aarch64_relocate (AARCH64_R (JUMP26), stub_bfd, stub_sec,
+ stub_entry->stub_offset + 4, sym_value))
+ BFD_FAIL ();
+ break;
+
+ case aarch64_stub_erratum_835769_veneer:
+ veneered_insn_loc = stub_entry->target_section->output_section->vma
+ + stub_entry->target_section->output_offset
+ + stub_entry->target_value;
+ veneer_entry_loc = stub_entry->stub_sec->output_section->vma
+ + stub_entry->stub_sec->output_offset
+ + stub_entry->stub_offset;
+ branch_offset = veneered_insn_loc - veneer_entry_loc;
+ branch_offset >>= 2;
+ branch_offset &= 0x3ffffff;
+ bfd_putl32 (stub_entry->veneered_insn,
+ stub_sec->contents + stub_entry->stub_offset);
+ bfd_putl32 (template[1] | branch_offset,
+ stub_sec->contents + stub_entry->stub_offset + 4);
+ break;
+
+ case aarch64_stub_erratum_843419_veneer:
+ if (!aarch64_relocate (AARCH64_R (JUMP26), stub_bfd, stub_sec,
+ stub_entry->stub_offset + 4, sym_value + 4))
+ BFD_FAIL ();
+ break;
+
+ default:
+ abort ();
+ }
+
+ return true;
+}
+
+/* As above, but don't actually build the stub. Just bump offset so
+ we know stub section sizes and record the offset for each stub so
+ a stub can target another stub (needed for BTI direct branch stub). */
+
+static bool
+aarch64_size_one_stub (struct bfd_hash_entry *gen_entry, void *in_arg)
+{
+ struct elf_aarch64_stub_hash_entry *stub_entry;
+ struct elf_aarch64_link_hash_table *htab;
+ int size;
+
+ /* Massage our args to the form they really have. */
+ stub_entry = (struct elf_aarch64_stub_hash_entry *) gen_entry;
+ htab = (struct elf_aarch64_link_hash_table *) in_arg;
+
+ switch (stub_entry->stub_type)
+ {
+ case aarch64_stub_adrp_branch:
+ size = sizeof (aarch64_adrp_branch_stub);
+ break;
+ case aarch64_stub_long_branch:
+ size = sizeof (aarch64_long_branch_stub);
+ break;
+ case aarch64_stub_bti_direct_branch:
+ size = sizeof (aarch64_bti_direct_branch_stub);
+ break;
+ case aarch64_stub_erratum_835769_veneer:
+ size = sizeof (aarch64_erratum_835769_stub);
+ break;
+ case aarch64_stub_erratum_843419_veneer:
+ {
+ if (htab->fix_erratum_843419 == ERRAT_ADR)
+ return true;
+ size = sizeof (aarch64_erratum_843419_stub);
+ }
+ break;
+ default:
+ abort ();
+ }
+
+ size = (size + 7) & ~7;
+ stub_entry->stub_offset = stub_entry->stub_sec->size;
+ stub_entry->stub_sec->size += size;
+ return true;
+}
+
+/* Output is BTI compatible. */
+
+static bool
+elf_aarch64_bti_p (bfd *output_bfd)
+{
+ return elf_aarch64_tdata (output_bfd)->gnu_property_aarch64_feature_1_and
+ & GNU_PROPERTY_AARCH64_FEATURE_1_BTI;
+}
+
+/* External entry points for sizing and building linker stubs. */
+
+/* Set up various things so that we can make a list of input sections
+ for each output section included in the link. Returns -1 on error,
+ 0 when no stubs will be needed, and 1 on success. */
+
+int
+elfNN_aarch64_setup_section_lists (bfd *output_bfd,
+ struct bfd_link_info *info)
+{
+ bfd *input_bfd;
+ unsigned int bfd_count;
+ unsigned int top_id, top_index;
+ asection *section;
+ asection **input_list, **list;
+ size_t amt;
+ struct elf_aarch64_link_hash_table *htab =
+ elf_aarch64_hash_table (info);
+
+ if (!is_elf_hash_table (&htab->root.root))
+ return 0;
+
+ /* Count the number of input BFDs and find the top input section id. */
+ for (input_bfd = info->input_bfds, bfd_count = 0, top_id = 0;
+ input_bfd != NULL; input_bfd = input_bfd->link.next)
+ {
+ bfd_count += 1;
+ for (section = input_bfd->sections;
+ section != NULL; section = section->next)
+ {
+ if (top_id < section->id)
+ top_id = section->id;
+ }
+ }
+ htab->bfd_count = bfd_count;
+
+ amt = sizeof (struct map_stub) * (top_id + 1);
+ htab->stub_group = bfd_zmalloc (amt);
+ if (htab->stub_group == NULL)
+ return -1;
+
+ /* We can't use output_bfd->section_count here to find the top output
+ section index as some sections may have been removed, and
+ _bfd_strip_section_from_output doesn't renumber the indices. */
+ for (section = output_bfd->sections, top_index = 0;
+ section != NULL; section = section->next)
+ {
+ if (top_index < section->index)
+ top_index = section->index;
+ }
+
+ htab->top_index = top_index;
+ amt = sizeof (asection *) * (top_index + 1);
+ input_list = bfd_malloc (amt);
+ htab->input_list = input_list;
+ if (input_list == NULL)
+ return -1;
+
+ /* For sections we aren't interested in, mark their entries with a
+ value we can check later. */
+ list = input_list + top_index;
+ do
+ *list = bfd_abs_section_ptr;
+ while (list-- != input_list);
+
+ for (section = output_bfd->sections;
+ section != NULL; section = section->next)
+ {
+ if ((section->flags & SEC_CODE) != 0)
+ input_list[section->index] = NULL;
+ }
+
+ return 1;
+}
+
+/* Used by elfNN_aarch64_next_input_section and group_sections. */
+#define PREV_SEC(sec) (htab->stub_group[(sec)->id].link_sec)
+
+/* The linker repeatedly calls this function for each input section,
+ in the order that input sections are linked into output sections.
+ Build lists of input sections to determine groupings between which
+ we may insert linker stubs. */
+
+void
+elfNN_aarch64_next_input_section (struct bfd_link_info *info, asection *isec)
+{
+ struct elf_aarch64_link_hash_table *htab =
+ elf_aarch64_hash_table (info);
+
+ if (isec->output_section->index <= htab->top_index)
+ {
+ asection **list = htab->input_list + isec->output_section->index;
+
+ if (*list != bfd_abs_section_ptr && (isec->flags & SEC_CODE) != 0)
+ {
+ /* Steal the link_sec pointer for our list. */
+ /* This happens to make the list in reverse order,
+ which is what we want. */
+ PREV_SEC (isec) = *list;
+ *list = isec;
+ }
+ }
+}
+
+/* See whether we can group stub sections together. Grouping stub
+ sections may result in fewer stubs. More importantly, we need to
+ put all .init* and .fini* stubs at the beginning of the .init or
+ .fini output sections respectively, because glibc splits the
+ _init and _fini functions into multiple parts. Putting a stub in
+ the middle of a function is not a good idea. */
+
+static void
+group_sections (struct elf_aarch64_link_hash_table *htab,
+ bfd_size_type stub_group_size,
+ bool stubs_always_after_branch)
+{
+ asection **list = htab->input_list;
+
+ do
+ {
+ asection *tail = *list;
+ asection *head;
+
+ if (tail == bfd_abs_section_ptr)
+ continue;
+
+ /* Reverse the list: we must avoid placing stubs at the
+ beginning of the section because the beginning of the text
+ section may be required for an interrupt vector in bare metal
+ code. */
+#define NEXT_SEC PREV_SEC
+ head = NULL;
+ while (tail != NULL)
+ {
+ /* Pop from tail. */
+ asection *item = tail;
+ tail = PREV_SEC (item);
+
+ /* Push on head. */
+ NEXT_SEC (item) = head;
+ head = item;
+ }
+
+ while (head != NULL)
+ {
+ asection *curr;
+ asection *next;
+ bfd_vma stub_group_start = head->output_offset;
+ bfd_vma end_of_next;
+
+ curr = head;
+ while (NEXT_SEC (curr) != NULL)
+ {
+ next = NEXT_SEC (curr);
+ end_of_next = next->output_offset + next->size;
+ if (end_of_next - stub_group_start >= stub_group_size)
+ /* End of NEXT is too far from start, so stop. */
+ break;
+ /* Add NEXT to the group. */
+ curr = next;
+ }
+
+ /* OK, the size from the start to the start of CURR is less
+ than stub_group_size and thus can be handled by one stub
+ section. (Or the head section is itself larger than
+ stub_group_size, in which case we may be toast.)
+ We should really be keeping track of the total size of
+ stubs added here, as stubs contribute to the final output
+ section size. */
+ do
+ {
+ next = NEXT_SEC (head);
+ /* Set up this stub group. */
+ htab->stub_group[head->id].link_sec = curr;
+ }
+ while (head != curr && (head = next) != NULL);
+
+ /* But wait, there's more! Input sections up to stub_group_size
+ bytes after the stub section can be handled by it too. */
+ if (!stubs_always_after_branch)
+ {
+ stub_group_start = curr->output_offset + curr->size;
+
+ while (next != NULL)
+ {
+ end_of_next = next->output_offset + next->size;
+ if (end_of_next - stub_group_start >= stub_group_size)
+ /* End of NEXT is too far from stubs, so stop. */
+ break;
+ /* Add NEXT to the stub group. */
+ head = next;
+ next = NEXT_SEC (head);
+ htab->stub_group[head->id].link_sec = curr;
+ }
+ }
+ head = next;
+ }
+ }
+ while (list++ != htab->input_list + htab->top_index);
+
+ free (htab->input_list);
+}
+
+#undef PREV_SEC
+#undef PREV_SEC
+
+#define AARCH64_HINT(insn) (((insn) & 0xfffff01f) == 0xd503201f)
+#define AARCH64_PACIASP 0xd503233f
+#define AARCH64_PACIBSP 0xd503237f
+#define AARCH64_BTI_C 0xd503245f
+#define AARCH64_BTI_J 0xd503249f
+#define AARCH64_BTI_JC 0xd50324df
+
+/* True if the inserted stub does not break BTI compatibility. */
+
+static bool
+aarch64_bti_stub_p (struct bfd_link_info *info,
+ struct elf_aarch64_stub_hash_entry *stub_entry)
+{
+ /* Stubs without indirect branch are BTI compatible. */
+ if (stub_entry->stub_type != aarch64_stub_adrp_branch
+ && stub_entry->stub_type != aarch64_stub_long_branch)
+ return true;
+
+ /* Return true if the target instruction is compatible with BR x16. */
+
+ struct elf_aarch64_link_hash_table *globals = elf_aarch64_hash_table (info);
+ asection *section = stub_entry->target_section;
+ bfd_byte loc[4];
+ file_ptr off = stub_entry->target_value;
+ bfd_size_type count = sizeof (loc);
+
+ /* PLT code is not generated yet, so treat it specially.
+ Note: Checking elf_aarch64_obj_tdata.plt_type & PLT_BTI is not
+ enough because it only implies BTI in the PLT0 and tlsdesc PLT
+ entries. Normal PLT entries don't have BTI in a shared library
+ (because such PLT is normally not called indirectly and adding
+ the BTI when a stub targets a PLT would change the PLT layout
+ and it's too late for that here). */
+ if (section == globals->root.splt)
+ memcpy (loc, globals->plt_entry, count);
+ else if (!bfd_get_section_contents (section->owner, section, loc, off, count))
+ return false;
+
+ uint32_t insn = bfd_getl32 (loc);
+ if (!AARCH64_HINT (insn))
+ return false;
+ return insn == AARCH64_BTI_C
+ || insn == AARCH64_PACIASP
+ || insn == AARCH64_BTI_JC
+ || insn == AARCH64_BTI_J
+ || insn == AARCH64_PACIBSP;
+}
+
+#define AARCH64_BITS(x, pos, n) (((x) >> (pos)) & ((1 << (n)) - 1))
+
+#define AARCH64_RT(insn) AARCH64_BITS (insn, 0, 5)
+#define AARCH64_RT2(insn) AARCH64_BITS (insn, 10, 5)
+#define AARCH64_RA(insn) AARCH64_BITS (insn, 10, 5)
+#define AARCH64_RD(insn) AARCH64_BITS (insn, 0, 5)
+#define AARCH64_RN(insn) AARCH64_BITS (insn, 5, 5)
+#define AARCH64_RM(insn) AARCH64_BITS (insn, 16, 5)
+
+#define AARCH64_MAC(insn) (((insn) & 0xff000000) == 0x9b000000)
+#define AARCH64_BIT(insn, n) AARCH64_BITS (insn, n, 1)
+#define AARCH64_OP31(insn) AARCH64_BITS (insn, 21, 3)
+#define AARCH64_ZR 0x1f
+
+/* All ld/st ops. See C4-182 of the ARM ARM. The encoding space for
+ LD_PCREL, LDST_RO, LDST_UI and LDST_UIMM cover prefetch ops. */
+
+#define AARCH64_LD(insn) (AARCH64_BIT (insn, 22) == 1)
+#define AARCH64_LDST(insn) (((insn) & 0x0a000000) == 0x08000000)
+#define AARCH64_LDST_EX(insn) (((insn) & 0x3f000000) == 0x08000000)
+#define AARCH64_LDST_PCREL(insn) (((insn) & 0x3b000000) == 0x18000000)
+#define AARCH64_LDST_NAP(insn) (((insn) & 0x3b800000) == 0x28000000)
+#define AARCH64_LDSTP_PI(insn) (((insn) & 0x3b800000) == 0x28800000)
+#define AARCH64_LDSTP_O(insn) (((insn) & 0x3b800000) == 0x29000000)
+#define AARCH64_LDSTP_PRE(insn) (((insn) & 0x3b800000) == 0x29800000)
+#define AARCH64_LDST_UI(insn) (((insn) & 0x3b200c00) == 0x38000000)
+#define AARCH64_LDST_PIIMM(insn) (((insn) & 0x3b200c00) == 0x38000400)
+#define AARCH64_LDST_U(insn) (((insn) & 0x3b200c00) == 0x38000800)
+#define AARCH64_LDST_PREIMM(insn) (((insn) & 0x3b200c00) == 0x38000c00)
+#define AARCH64_LDST_RO(insn) (((insn) & 0x3b200c00) == 0x38200800)
+#define AARCH64_LDST_UIMM(insn) (((insn) & 0x3b000000) == 0x39000000)
+#define AARCH64_LDST_SIMD_M(insn) (((insn) & 0xbfbf0000) == 0x0c000000)
+#define AARCH64_LDST_SIMD_M_PI(insn) (((insn) & 0xbfa00000) == 0x0c800000)
+#define AARCH64_LDST_SIMD_S(insn) (((insn) & 0xbf9f0000) == 0x0d000000)
+#define AARCH64_LDST_SIMD_S_PI(insn) (((insn) & 0xbf800000) == 0x0d800000)
+
+/* Classify an INSN if it is indeed a load/store.
+
+ Return TRUE if INSN is a LD/ST instruction otherwise return FALSE.
+
+ For scalar LD/ST instructions PAIR is FALSE, RT is returned and RT2
+ is set equal to RT.
+
+ For LD/ST pair instructions PAIR is TRUE, RT and RT2 are returned. */
+
+static bool
+aarch64_mem_op_p (uint32_t insn, unsigned int *rt, unsigned int *rt2,
+ bool *pair, bool *load)
+{
+ uint32_t opcode;
+ unsigned int r;
+ uint32_t opc = 0;
+ uint32_t v = 0;
+ uint32_t opc_v = 0;
+
+ /* Bail out quickly if INSN doesn't fall into the load-store
+ encoding space. */
+ if (!AARCH64_LDST (insn))
+ return false;
+
+ *pair = false;
+ *load = false;
+ if (AARCH64_LDST_EX (insn))
+ {
+ *rt = AARCH64_RT (insn);
+ *rt2 = *rt;
+ if (AARCH64_BIT (insn, 21) == 1)
+ {
+ *pair = true;
+ *rt2 = AARCH64_RT2 (insn);
+ }
+ *load = AARCH64_LD (insn);
+ return true;
+ }
+ else if (AARCH64_LDST_NAP (insn)
+ || AARCH64_LDSTP_PI (insn)
+ || AARCH64_LDSTP_O (insn)
+ || AARCH64_LDSTP_PRE (insn))
+ {
+ *pair = true;
+ *rt = AARCH64_RT (insn);
+ *rt2 = AARCH64_RT2 (insn);
+ *load = AARCH64_LD (insn);
+ return true;
+ }
+ else if (AARCH64_LDST_PCREL (insn)
+ || AARCH64_LDST_UI (insn)
+ || AARCH64_LDST_PIIMM (insn)
+ || AARCH64_LDST_U (insn)
+ || AARCH64_LDST_PREIMM (insn)
+ || AARCH64_LDST_RO (insn)
+ || AARCH64_LDST_UIMM (insn))
+ {
+ *rt = AARCH64_RT (insn);
+ *rt2 = *rt;
+ if (AARCH64_LDST_PCREL (insn))
+ *load = true;
+ opc = AARCH64_BITS (insn, 22, 2);
+ v = AARCH64_BIT (insn, 26);
+ opc_v = opc | (v << 2);
+ *load = (opc_v == 1 || opc_v == 2 || opc_v == 3
+ || opc_v == 5 || opc_v == 7);
+ return true;
+ }
+ else if (AARCH64_LDST_SIMD_M (insn)
+ || AARCH64_LDST_SIMD_M_PI (insn))
+ {
+ *rt = AARCH64_RT (insn);
+ *load = AARCH64_BIT (insn, 22);
+ opcode = (insn >> 12) & 0xf;
+ switch (opcode)
+ {
+ case 0:
+ case 2:
+ *rt2 = *rt + 3;
+ break;
+
+ case 4:
+ case 6:
+ *rt2 = *rt + 2;
+ break;
+
+ case 7:
+ *rt2 = *rt;
+ break;
+
+ case 8:
+ case 10:
+ *rt2 = *rt + 1;
+ break;
+
+ default:
+ return false;
+ }
+ return true;
+ }
+ else if (AARCH64_LDST_SIMD_S (insn)
+ || AARCH64_LDST_SIMD_S_PI (insn))
+ {
+ *rt = AARCH64_RT (insn);
+ r = (insn >> 21) & 1;
+ *load = AARCH64_BIT (insn, 22);
+ opcode = (insn >> 13) & 0x7;
+ switch (opcode)
+ {
+ case 0:
+ case 2:
+ case 4:
+ *rt2 = *rt + r;
+ break;
+
+ case 1:
+ case 3:
+ case 5:
+ *rt2 = *rt + (r == 0 ? 2 : 3);
+ break;
+
+ case 6:
+ *rt2 = *rt + r;
+ break;
+
+ case 7:
+ *rt2 = *rt + (r == 0 ? 2 : 3);
+ break;
+
+ default:
+ return false;
+ }
+ return true;
+ }
+
+ return false;
+}
+
+/* Return TRUE if INSN is multiply-accumulate. */
+
+static bool
+aarch64_mlxl_p (uint32_t insn)
+{
+ uint32_t op31 = AARCH64_OP31 (insn);
+
+ if (AARCH64_MAC (insn)
+ && (op31 == 0 || op31 == 1 || op31 == 5)
+ /* Exclude MUL instructions which are encoded as a multiple accumulate
+ with RA = XZR. */
+ && AARCH64_RA (insn) != AARCH64_ZR)
+ return true;
+
+ return false;
+}
+
+/* Some early revisions of the Cortex-A53 have an erratum (835769) whereby
+ it is possible for a 64-bit multiply-accumulate instruction to generate an
+ incorrect result. The details are quite complex and hard to
+ determine statically, since branches in the code may exist in some
+ circumstances, but all cases end with a memory (load, store, or
+ prefetch) instruction followed immediately by the multiply-accumulate
+ operation. We employ a linker patching technique, by moving the potentially
+ affected multiply-accumulate instruction into a patch region and replacing
+ the original instruction with a branch to the patch. This function checks
+ if INSN_1 is the memory operation followed by a multiply-accumulate
+ operation (INSN_2). Return TRUE if an erratum sequence is found, FALSE
+ if INSN_1 and INSN_2 are safe. */
+
+static bool
+aarch64_erratum_sequence (uint32_t insn_1, uint32_t insn_2)
+{
+ uint32_t rt;
+ uint32_t rt2;
+ uint32_t rn;
+ uint32_t rm;
+ uint32_t ra;
+ bool pair;
+ bool load;
+
+ if (aarch64_mlxl_p (insn_2)
+ && aarch64_mem_op_p (insn_1, &rt, &rt2, &pair, &load))
+ {
+ /* Any SIMD memory op is independent of the subsequent MLA
+ by definition of the erratum. */
+ if (AARCH64_BIT (insn_1, 26))
+ return true;
+
+ /* If not SIMD, check for integer memory ops and MLA relationship. */
+ rn = AARCH64_RN (insn_2);
+ ra = AARCH64_RA (insn_2);
+ rm = AARCH64_RM (insn_2);
+
+ /* If this is a load and there's a true(RAW) dependency, we are safe
+ and this is not an erratum sequence. */
+ if (load &&
+ (rt == rn || rt == rm || rt == ra
+ || (pair && (rt2 == rn || rt2 == rm || rt2 == ra))))
+ return false;
+
+ /* We conservatively put out stubs for all other cases (including
+ writebacks). */
+ return true;
+ }
+
+ return false;
+}
+
+/* Used to order a list of mapping symbols by address. */
+
+static int
+elf_aarch64_compare_mapping (const void *a, const void *b)
+{
+ const elf_aarch64_section_map *amap = (const elf_aarch64_section_map *) a;
+ const elf_aarch64_section_map *bmap = (const elf_aarch64_section_map *) b;
+
+ if (amap->vma > bmap->vma)
+ return 1;
+ else if (amap->vma < bmap->vma)
+ return -1;
+ else if (amap->type > bmap->type)
+ /* Ensure results do not depend on the host qsort for objects with
+ multiple mapping symbols at the same address by sorting on type
+ after vma. */
+ return 1;
+ else if (amap->type < bmap->type)
+ return -1;
+ else
+ return 0;
+}
+
+
+static char *
+_bfd_aarch64_erratum_835769_stub_name (unsigned num_fixes)
+{
+ char *stub_name = (char *) bfd_malloc
+ (strlen ("__erratum_835769_veneer_") + 16);
+ if (stub_name != NULL)
+ sprintf (stub_name,"__erratum_835769_veneer_%d", num_fixes);
+ return stub_name;
+}
+
+/* Scan for Cortex-A53 erratum 835769 sequence.
+
+ Return TRUE else FALSE on abnormal termination. */
+
+static bool
+_bfd_aarch64_erratum_835769_scan (bfd *input_bfd,
+ struct bfd_link_info *info,
+ unsigned int *num_fixes_p)
+{
+ asection *section;
+ struct elf_aarch64_link_hash_table *htab = elf_aarch64_hash_table (info);
+ unsigned int num_fixes = *num_fixes_p;
+
+ if (htab == NULL)
+ return true;
+
+ for (section = input_bfd->sections;
+ section != NULL;
+ section = section->next)
+ {
+ bfd_byte *contents = NULL;
+ struct _aarch64_elf_section_data *sec_data;
+ unsigned int span;
+
+ if (elf_section_type (section) != SHT_PROGBITS
+ || (elf_section_flags (section) & SHF_EXECINSTR) == 0
+ || (section->flags & SEC_EXCLUDE) != 0
+ || (section->sec_info_type == SEC_INFO_TYPE_JUST_SYMS)
+ || (section->output_section == bfd_abs_section_ptr))
+ continue;
+
+ if (elf_section_data (section)->this_hdr.contents != NULL)
+ contents = elf_section_data (section)->this_hdr.contents;
+ else if (! bfd_malloc_and_get_section (input_bfd, section, &contents))
+ return false;
+
+ sec_data = elf_aarch64_section_data (section);
+
+ if (sec_data->mapcount)
+ qsort (sec_data->map, sec_data->mapcount,
+ sizeof (elf_aarch64_section_map), elf_aarch64_compare_mapping);
+
+ for (span = 0; span < sec_data->mapcount; span++)
+ {
+ unsigned int span_start = sec_data->map[span].vma;
+ unsigned int span_end = ((span == sec_data->mapcount - 1)
+ ? sec_data->map[0].vma + section->size
+ : sec_data->map[span + 1].vma);
+ unsigned int i;
+ char span_type = sec_data->map[span].type;
+
+ if (span_type == 'd')
+ continue;
+
+ for (i = span_start; i + 4 < span_end; i += 4)
+ {
+ uint32_t insn_1 = bfd_getl32 (contents + i);
+ uint32_t insn_2 = bfd_getl32 (contents + i + 4);
+
+ if (aarch64_erratum_sequence (insn_1, insn_2))
+ {
+ struct elf_aarch64_stub_hash_entry *stub_entry;
+ char *stub_name = _bfd_aarch64_erratum_835769_stub_name (num_fixes);
+ if (! stub_name)
+ return false;
+
+ stub_entry = _bfd_aarch64_add_stub_entry_in_group (stub_name,
+ section,
+ htab);
+ if (! stub_entry)
+ return false;
+
+ stub_entry->stub_type = aarch64_stub_erratum_835769_veneer;
+ stub_entry->target_section = section;
+ stub_entry->target_value = i + 4;
+ stub_entry->veneered_insn = insn_2;
+ stub_entry->output_name = stub_name;
+ num_fixes++;
+ }
+ }
+ }
+ if (elf_section_data (section)->this_hdr.contents == NULL)
+ free (contents);
+ }
+
+ *num_fixes_p = num_fixes;
+
+ return true;
+}
+
+
+/* Test if instruction INSN is ADRP. */
+
+static bool
+_bfd_aarch64_adrp_p (uint32_t insn)
+{
+ return ((insn & AARCH64_ADRP_OP_MASK) == AARCH64_ADRP_OP);
+}
+
+
+/* Helper predicate to look for cortex-a53 erratum 843419 sequence 1. */
+
+static bool
+_bfd_aarch64_erratum_843419_sequence_p (uint32_t insn_1, uint32_t insn_2,
+ uint32_t insn_3)
+{
+ uint32_t rt;
+ uint32_t rt2;
+ bool pair;
+ bool load;
+
+ return (aarch64_mem_op_p (insn_2, &rt, &rt2, &pair, &load)
+ && (!pair
+ || (pair && !load))
+ && AARCH64_LDST_UIMM (insn_3)
+ && AARCH64_RN (insn_3) == AARCH64_RD (insn_1));
+}
+
+
+/* Test for the presence of Cortex-A53 erratum 843419 instruction sequence.
+
+ Return TRUE if section CONTENTS at offset I contains one of the
+ erratum 843419 sequences, otherwise return FALSE. If a sequence is
+ seen set P_VENEER_I to the offset of the final LOAD/STORE
+ instruction in the sequence.
+ */
+
+static bool
+_bfd_aarch64_erratum_843419_p (bfd_byte *contents, bfd_vma vma,
+ bfd_vma i, bfd_vma span_end,
+ bfd_vma *p_veneer_i)
+{
+ uint32_t insn_1 = bfd_getl32 (contents + i);
+
+ if (!_bfd_aarch64_adrp_p (insn_1))
+ return false;
+
+ if (span_end < i + 12)
+ return false;
+
+ uint32_t insn_2 = bfd_getl32 (contents + i + 4);
+ uint32_t insn_3 = bfd_getl32 (contents + i + 8);
+
+ if ((vma & 0xfff) != 0xff8 && (vma & 0xfff) != 0xffc)
+ return false;
+
+ if (_bfd_aarch64_erratum_843419_sequence_p (insn_1, insn_2, insn_3))
+ {
+ *p_veneer_i = i + 8;
+ return true;
+ }
+
+ if (span_end < i + 16)
+ return false;
+
+ uint32_t insn_4 = bfd_getl32 (contents + i + 12);
+
+ if (_bfd_aarch64_erratum_843419_sequence_p (insn_1, insn_2, insn_4))
+ {
+ *p_veneer_i = i + 12;
+ return true;
+ }
+
+ return false;
+}
+
+
+/* Resize all stub sections. */
+
+static void
+_bfd_aarch64_resize_stubs (struct elf_aarch64_link_hash_table *htab)
+{
+ asection *section;
+
+ /* OK, we've added some stubs. Find out the new size of the
+ stub sections. */
+ for (section = htab->stub_bfd->sections;
+ section != NULL; section = section->next)
+ {
+ /* Ignore non-stub sections. */
+ if (!strstr (section->name, STUB_SUFFIX))
+ continue;
+
+ /* Add space for a branch. Add 8 bytes to keep section 8 byte aligned,
+ as long branch stubs contain a 64-bit address. */
+ section->size = 8;
+ }
+
+ bfd_hash_traverse (&htab->stub_hash_table, aarch64_size_one_stub, htab);
+
+ for (section = htab->stub_bfd->sections;
+ section != NULL; section = section->next)
+ {
+ if (!strstr (section->name, STUB_SUFFIX))
+ continue;
+
+ /* Empty stub section. */
+ if (section->size == 8)
+ section->size = 0;
+
+ /* Ensure all stub sections have a size which is a multiple of
+ 4096. This is important in order to ensure that the insertion
+ of stub sections does not in itself move existing code around
+ in such a way that new errata sequences are created. We only do this
+ when the ADRP workaround is enabled. If only the ADR workaround is
+ enabled then the stubs workaround won't ever be used. */
+ if (htab->fix_erratum_843419 & ERRAT_ADRP)
+ if (section->size)
+ section->size = BFD_ALIGN (section->size, 0x1000);
+ }
+}
+
+/* Construct an erratum 843419 workaround stub name. */
+
+static char *
+_bfd_aarch64_erratum_843419_stub_name (asection *input_section,
+ bfd_vma offset)
+{
+ const bfd_size_type len = 8 + 4 + 1 + 8 + 1 + 16 + 1;
+ char *stub_name = bfd_malloc (len);
+
+ if (stub_name != NULL)
+ snprintf (stub_name, len, "e843419@%04x_%08x_%" PRIx64,
+ input_section->owner->id,
+ input_section->id,
+ (uint64_t) offset);
+ return stub_name;
+}
+
+/* Build a stub_entry structure describing an 843419 fixup.
+
+ The stub_entry constructed is populated with the bit pattern INSN
+ of the instruction located at OFFSET within input SECTION.
+
+ Returns TRUE on success. */
+
+static bool
+_bfd_aarch64_erratum_843419_fixup (uint32_t insn,
+ bfd_vma adrp_offset,
+ bfd_vma ldst_offset,
+ asection *section,
+ struct bfd_link_info *info)
+{
+ struct elf_aarch64_link_hash_table *htab = elf_aarch64_hash_table (info);
+ char *stub_name;
+ struct elf_aarch64_stub_hash_entry *stub_entry;
+
+ stub_name = _bfd_aarch64_erratum_843419_stub_name (section, ldst_offset);
+ if (stub_name == NULL)
+ return false;
+ stub_entry = aarch64_stub_hash_lookup (&htab->stub_hash_table, stub_name,
+ false, false);
+ if (stub_entry)
+ {
+ free (stub_name);
+ return true;
+ }
+
+ /* We always place an 843419 workaround veneer in the stub section
+ attached to the input section in which an erratum sequence has
+ been found. This ensures that later in the link process (in
+ elfNN_aarch64_write_section) when we copy the veneered
+ instruction from the input section into the stub section the
+ copied instruction will have had any relocations applied to it.
+ If we placed workaround veneers in any other stub section then we
+ could not assume that all relocations have been processed on the
+ corresponding input section at the point we output the stub
+ section. */
+
+ stub_entry = _bfd_aarch64_add_stub_entry_after (stub_name, section, htab);
+ if (stub_entry == NULL)
+ {
+ free (stub_name);
+ return false;
+ }
+
+ stub_entry->adrp_offset = adrp_offset;
+ stub_entry->target_value = ldst_offset;
+ stub_entry->target_section = section;
+ stub_entry->stub_type = aarch64_stub_erratum_843419_veneer;
+ stub_entry->veneered_insn = insn;
+ stub_entry->output_name = stub_name;
+
+ return true;
+}
+
+
+/* Scan an input section looking for the signature of erratum 843419.
+
+ Scans input SECTION in INPUT_BFD looking for erratum 843419
+ signatures, for each signature found a stub_entry is created
+ describing the location of the erratum for subsequent fixup.
+
+ Return TRUE on successful scan, FALSE on failure to scan.
+ */
+
+static bool
+_bfd_aarch64_erratum_843419_scan (bfd *input_bfd, asection *section,
+ struct bfd_link_info *info)
+{
+ struct elf_aarch64_link_hash_table *htab = elf_aarch64_hash_table (info);
+
+ if (htab == NULL)
+ return true;
+
+ if (elf_section_type (section) != SHT_PROGBITS
+ || (elf_section_flags (section) & SHF_EXECINSTR) == 0
+ || (section->flags & SEC_EXCLUDE) != 0
+ || (section->sec_info_type == SEC_INFO_TYPE_JUST_SYMS)
+ || (section->output_section == bfd_abs_section_ptr))
+ return true;
+
+ do
+ {
+ bfd_byte *contents = NULL;
+ struct _aarch64_elf_section_data *sec_data;
+ unsigned int span;
+
+ if (elf_section_data (section)->this_hdr.contents != NULL)
+ contents = elf_section_data (section)->this_hdr.contents;
+ else if (! bfd_malloc_and_get_section (input_bfd, section, &contents))
+ return false;
+
+ sec_data = elf_aarch64_section_data (section);
+
+ if (sec_data->mapcount)
+ qsort (sec_data->map, sec_data->mapcount,
+ sizeof (elf_aarch64_section_map), elf_aarch64_compare_mapping);
+
+ for (span = 0; span < sec_data->mapcount; span++)
+ {
+ unsigned int span_start = sec_data->map[span].vma;
+ unsigned int span_end = ((span == sec_data->mapcount - 1)
+ ? sec_data->map[0].vma + section->size
+ : sec_data->map[span + 1].vma);
+ unsigned int i;
+ char span_type = sec_data->map[span].type;
+
+ if (span_type == 'd')
+ continue;
+
+ for (i = span_start; i + 8 < span_end; i += 4)
+ {
+ bfd_vma vma = (section->output_section->vma
+ + section->output_offset
+ + i);
+ bfd_vma veneer_i;
+
+ if (_bfd_aarch64_erratum_843419_p
+ (contents, vma, i, span_end, &veneer_i))
+ {
+ uint32_t insn = bfd_getl32 (contents + veneer_i);
+
+ if (!_bfd_aarch64_erratum_843419_fixup (insn, i, veneer_i,
+ section, info))
+ return false;
+ }
+ }
+ }
+
+ if (elf_section_data (section)->this_hdr.contents == NULL)
+ free (contents);
+ }
+ while (0);
+
+ return true;
+}
+
+
+/* Add stub entries for calls.
+
+ The basic idea here is to examine all the relocations looking for
+ PC-relative calls to a target that is unreachable with a "bl"
+ instruction. */
+
+static bool
+_bfd_aarch64_add_call_stub_entries (bool *stub_changed, bfd *output_bfd,
+ struct bfd_link_info *info)
+{
+ struct elf_aarch64_link_hash_table *htab = elf_aarch64_hash_table (info);
+ bool need_bti = elf_aarch64_bti_p (output_bfd);
+ bfd *input_bfd;
+
+ for (input_bfd = info->input_bfds; input_bfd != NULL;
+ input_bfd = input_bfd->link.next)
+ {
+ Elf_Internal_Shdr *symtab_hdr;
+ asection *section;
+ Elf_Internal_Sym *local_syms = NULL;
+
+ if (!is_aarch64_elf (input_bfd)
+ || (input_bfd->flags & BFD_LINKER_CREATED) != 0)
+ continue;
+
+ /* We'll need the symbol table in a second. */
+ symtab_hdr = &elf_tdata (input_bfd)->symtab_hdr;
+ if (symtab_hdr->sh_info == 0)
+ continue;
+
+ /* Walk over each section attached to the input bfd. */
+ for (section = input_bfd->sections;
+ section != NULL; section = section->next)
+ {
+ Elf_Internal_Rela *internal_relocs, *irelaend, *irela;
+
+ /* If there aren't any relocs, then there's nothing more to do. */
+ if ((section->flags & SEC_RELOC) == 0
+ || section->reloc_count == 0
+ || (section->flags & SEC_CODE) == 0)
+ continue;
+
+ /* If this section is a link-once section that will be
+ discarded, then don't create any stubs. */
+ if (section->output_section == NULL
+ || section->output_section->owner != output_bfd)
+ continue;
+
+ /* Get the relocs. */
+ internal_relocs
+ = _bfd_elf_link_read_relocs (input_bfd, section, NULL,
+ NULL, info->keep_memory);
+ if (internal_relocs == NULL)
+ goto error_ret_free_local;
+
+ /* Now examine each relocation. */
+ irela = internal_relocs;
+ irelaend = irela + section->reloc_count;
+ for (; irela < irelaend; irela++)
+ {
+ unsigned int r_type, r_indx;
+ enum elf_aarch64_stub_type stub_type;
+ struct elf_aarch64_stub_hash_entry *stub_entry;
+ struct elf_aarch64_stub_hash_entry *stub_entry_bti;
+ asection *sym_sec;
+ bfd_vma sym_value;
+ bfd_vma destination;
+ struct elf_aarch64_link_hash_entry *hash;
+ const char *sym_name;
+ char *stub_name;
+ char *stub_name_bti;
+ const asection *id_sec;
+ const asection *id_sec_bti;
+ unsigned char st_type;
+ bfd_size_type len;
+
+ r_type = ELFNN_R_TYPE (irela->r_info);
+ r_indx = ELFNN_R_SYM (irela->r_info);
+
+ if (r_type >= (unsigned int) R_AARCH64_end)
+ {
+ bfd_set_error (bfd_error_bad_value);
+ error_ret_free_internal:
+ if (elf_section_data (section)->relocs == NULL)
+ free (internal_relocs);
+ goto error_ret_free_local;
+ }
+
+ /* Only look for stubs on unconditional branch and
+ branch and link instructions. */
+ if (r_type != (unsigned int) AARCH64_R (CALL26)
+ && r_type != (unsigned int) AARCH64_R (JUMP26))
+ continue;
+
+ /* Now determine the call target, its name, value,
+ section. */
+ sym_sec = NULL;
+ sym_value = 0;
+ destination = 0;
+ hash = NULL;
+ sym_name = NULL;
+ if (r_indx < symtab_hdr->sh_info)
+ {
+ /* It's a local symbol. */
+ Elf_Internal_Sym *sym;
+ Elf_Internal_Shdr *hdr;
+
+ if (local_syms == NULL)
+ {
+ local_syms
+ = (Elf_Internal_Sym *) symtab_hdr->contents;
+ if (local_syms == NULL)
+ local_syms
+ = bfd_elf_get_elf_syms (input_bfd, symtab_hdr,
+ symtab_hdr->sh_info, 0,
+ NULL, NULL, NULL);
+ if (local_syms == NULL)
+ goto error_ret_free_internal;
+ }
+
+ sym = local_syms + r_indx;
+ hdr = elf_elfsections (input_bfd)[sym->st_shndx];
+ sym_sec = hdr->bfd_section;
+ if (!sym_sec)
+ /* This is an undefined symbol. It can never
+ be resolved. */
+ continue;
+
+ if (ELF_ST_TYPE (sym->st_info) != STT_SECTION)
+ sym_value = sym->st_value;
+ destination = (sym_value + irela->r_addend
+ + sym_sec->output_offset
+ + sym_sec->output_section->vma);
+ st_type = ELF_ST_TYPE (sym->st_info);
+ sym_name
+ = bfd_elf_string_from_elf_section (input_bfd,
+ symtab_hdr->sh_link,
+ sym->st_name);
+ }
+ else
+ {
+ int e_indx;
+
+ e_indx = r_indx - symtab_hdr->sh_info;
+ hash = ((struct elf_aarch64_link_hash_entry *)
+ elf_sym_hashes (input_bfd)[e_indx]);
+
+ while (hash->root.root.type == bfd_link_hash_indirect
+ || hash->root.root.type == bfd_link_hash_warning)
+ hash = ((struct elf_aarch64_link_hash_entry *)
+ hash->root.root.u.i.link);
+
+ if (hash->root.root.type == bfd_link_hash_defined
+ || hash->root.root.type == bfd_link_hash_defweak)
+ {
+ struct elf_aarch64_link_hash_table *globals =
+ elf_aarch64_hash_table (info);
+ sym_sec = hash->root.root.u.def.section;
+ sym_value = hash->root.root.u.def.value;
+ /* For a destination in a shared library,
+ use the PLT stub as target address to
+ decide whether a branch stub is
+ needed. */
+ if (globals->root.splt != NULL && hash != NULL
+ && hash->root.plt.offset != (bfd_vma) - 1)
+ {
+ sym_sec = globals->root.splt;
+ sym_value = hash->root.plt.offset;
+ if (sym_sec->output_section != NULL)
+ destination = (sym_value
+ + sym_sec->output_offset
+ + sym_sec->output_section->vma);
+ }
+ else if (sym_sec->output_section != NULL)
+ destination = (sym_value + irela->r_addend
+ + sym_sec->output_offset
+ + sym_sec->output_section->vma);
+ }
+ else if (hash->root.root.type == bfd_link_hash_undefined
+ || (hash->root.root.type
+ == bfd_link_hash_undefweak))
+ {
+ /* For a shared library, use the PLT stub as
+ target address to decide whether a long
+ branch stub is needed.
+ For absolute code, they cannot be handled. */
+ struct elf_aarch64_link_hash_table *globals =
+ elf_aarch64_hash_table (info);
+
+ if (globals->root.splt != NULL && hash != NULL
+ && hash->root.plt.offset != (bfd_vma) - 1)
+ {
+ sym_sec = globals->root.splt;
+ sym_value = hash->root.plt.offset;
+ if (sym_sec->output_section != NULL)
+ destination = (sym_value
+ + sym_sec->output_offset
+ + sym_sec->output_section->vma);
+ }
+ else
+ continue;
+ }
+ else
+ {
+ bfd_set_error (bfd_error_bad_value);
+ goto error_ret_free_internal;
+ }
+ st_type = ELF_ST_TYPE (hash->root.type);
+ sym_name = hash->root.root.root.string;
+ }
+
+ /* Determine what (if any) linker stub is needed. */
+ stub_type = aarch64_type_of_stub (section, irela, sym_sec,
+ st_type, destination);
+ if (stub_type == aarch64_stub_none)
+ continue;
+
+ /* Support for grouping stub sections. */
+ id_sec = htab->stub_group[section->id].link_sec;
+
+ /* Get the name of this stub. */
+ stub_name = elfNN_aarch64_stub_name (id_sec, sym_sec, hash,
+ irela);
+ if (!stub_name)
+ goto error_ret_free_internal;
+
+ stub_entry =
+ aarch64_stub_hash_lookup (&htab->stub_hash_table,
+ stub_name, false, false);
+ if (stub_entry != NULL)
+ {
+ /* The proper stub has already been created. */
+ free (stub_name);
+
+ /* Always update this stub's target since it may have
+ changed after layout. */
+ stub_entry->target_value = sym_value + irela->r_addend;
+
+ if (stub_entry->double_stub)
+ {
+ /* Update the target of both stubs. */
+
+ id_sec_bti = htab->stub_group[sym_sec->id].link_sec;
+ stub_name_bti =
+ elfNN_aarch64_stub_name (id_sec_bti, sym_sec, hash,
+ irela);
+ if (!stub_name_bti)
+ goto error_ret_free_internal;
+ stub_entry_bti =
+ aarch64_stub_hash_lookup (&htab->stub_hash_table,
+ stub_name_bti, false, false);
+ BFD_ASSERT (stub_entry_bti != NULL);
+ free (stub_name_bti);
+ stub_entry_bti->target_value = stub_entry->target_value;
+ stub_entry->target_value = stub_entry_bti->stub_offset;
+ }
+ continue;
+ }
+
+ stub_entry = _bfd_aarch64_add_stub_entry_in_group
+ (stub_name, section, htab);
+ if (stub_entry == NULL)
+ {
+ free (stub_name);
+ goto error_ret_free_internal;
+ }
+
+ stub_entry->target_value = sym_value + irela->r_addend;
+ stub_entry->target_section = sym_sec;
+ stub_entry->stub_type = stub_type;
+ stub_entry->h = hash;
+ stub_entry->st_type = st_type;
+
+ if (sym_name == NULL)
+ sym_name = "unnamed";
+ len = sizeof (STUB_ENTRY_NAME) + strlen (sym_name);
+ stub_entry->output_name = bfd_alloc (htab->stub_bfd, len);
+ if (stub_entry->output_name == NULL)
+ {
+ free (stub_name);
+ goto error_ret_free_internal;
+ }
+
+ snprintf (stub_entry->output_name, len, STUB_ENTRY_NAME,
+ sym_name);
+
+ /* A stub with indirect jump may break BTI compatibility, so
+ insert another stub with direct jump near the target then. */
+ if (need_bti && !aarch64_bti_stub_p (info, stub_entry))
+ {
+ id_sec_bti = htab->stub_group[sym_sec->id].link_sec;
+
+ /* If the stub with indirect jump and the BTI stub are in
+ the same stub group: change the indirect jump stub into
+ a BTI stub since a direct branch can reach the target.
+ The BTI landing pad is still needed in case another
+ stub indirectly jumps to it. */
+ if (id_sec_bti == id_sec)
+ {
+ stub_entry->stub_type = aarch64_stub_bti_direct_branch;
+ goto skip_double_stub;
+ }
+
+ stub_entry->double_stub = true;
+ htab->has_double_stub = true;
+
+ stub_name_bti =
+ elfNN_aarch64_stub_name (id_sec_bti, sym_sec, hash, irela);
+ if (!stub_name_bti)
+ {
+ free (stub_name);
+ goto error_ret_free_internal;
+ }
+
+ stub_entry_bti =
+ aarch64_stub_hash_lookup (&htab->stub_hash_table,
+ stub_name_bti, false, false);
+ if (stub_entry_bti != NULL)
+ BFD_ASSERT (stub_entry_bti->stub_type
+ == aarch64_stub_bti_direct_branch);
+ else
+ {
+ stub_entry_bti =
+ _bfd_aarch64_add_stub_entry_in_group (stub_name_bti,
+ sym_sec, htab);
+ if (stub_entry_bti == NULL)
+ {
+ free (stub_name);
+ free (stub_name_bti);
+ goto error_ret_free_internal;
+ }
+
+ stub_entry_bti->target_value =
+ sym_value + irela->r_addend;
+ stub_entry_bti->target_section = sym_sec;
+ stub_entry_bti->stub_type =
+ aarch64_stub_bti_direct_branch;
+ stub_entry_bti->h = hash;
+ stub_entry_bti->st_type = st_type;
+
+ len = sizeof (BTI_STUB_ENTRY_NAME) + strlen (sym_name);
+ stub_entry_bti->output_name = bfd_alloc (htab->stub_bfd,
+ len);
+ if (stub_entry_bti->output_name == NULL)
+ {
+ free (stub_name);
+ free (stub_name_bti);
+ goto error_ret_free_internal;
+ }
+ snprintf (stub_entry_bti->output_name, len,
+ BTI_STUB_ENTRY_NAME, sym_name);
+ }
+
+ /* Update the indirect call stub to target the BTI stub. */
+ stub_entry->target_value = 0;
+ stub_entry->target_section = stub_entry_bti->stub_sec;
+ stub_entry->stub_type = stub_type;
+ stub_entry->h = NULL;
+ stub_entry->st_type = STT_FUNC;
+ }
+skip_double_stub:
+ *stub_changed = true;
+ }
+
+ /* We're done with the internal relocs, free them. */
+ if (elf_section_data (section)->relocs == NULL)
+ free (internal_relocs);
+ }
+ }
+ return true;
+ error_ret_free_local:
+ return false;
+}
+
+
+/* Determine and set the size of the stub section for a final link. */
+
+bool
+elfNN_aarch64_size_stubs (bfd *output_bfd,
+ bfd *stub_bfd,
+ struct bfd_link_info *info,
+ bfd_signed_vma group_size,
+ asection * (*add_stub_section) (const char *,
+ asection *),
+ void (*layout_sections_again) (void))
+{
+ bfd_size_type stub_group_size;
+ bool stubs_always_before_branch;
+ struct elf_aarch64_link_hash_table *htab = elf_aarch64_hash_table (info);
+ unsigned int num_erratum_835769_fixes = 0;
+
+ /* Propagate mach to stub bfd, because it may not have been
+ finalized when we created stub_bfd. */
+ bfd_set_arch_mach (stub_bfd, bfd_get_arch (output_bfd),
+ bfd_get_mach (output_bfd));
+
+ /* Stash our params away. */
+ htab->stub_bfd = stub_bfd;
+ htab->add_stub_section = add_stub_section;
+ htab->layout_sections_again = layout_sections_again;
+ stubs_always_before_branch = group_size < 0;
+ if (group_size < 0)
+ stub_group_size = -group_size;
+ else
+ stub_group_size = group_size;
+
+ if (stub_group_size == 1)
+ {
+ /* Default values. */
+ /* AArch64 branch range is +-128MB. The value used is 1MB less. */
+ stub_group_size = 127 * 1024 * 1024;
+ }
+
+ group_sections (htab, stub_group_size, stubs_always_before_branch);
+
+ (*htab->layout_sections_again) ();
+
+ if (htab->fix_erratum_835769)
+ {
+ bfd *input_bfd;
+
+ for (input_bfd = info->input_bfds;
+ input_bfd != NULL; input_bfd = input_bfd->link.next)
+ {
+ if (!is_aarch64_elf (input_bfd)
+ || (input_bfd->flags & BFD_LINKER_CREATED) != 0)
+ continue;
+
+ if (!_bfd_aarch64_erratum_835769_scan (input_bfd, info,
+ &num_erratum_835769_fixes))
+ return false;
+ }
+
+ _bfd_aarch64_resize_stubs (htab);
+ (*htab->layout_sections_again) ();
+ }
+
+ if (htab->fix_erratum_843419 != ERRAT_NONE)
+ {
+ bfd *input_bfd;
+
+ for (input_bfd = info->input_bfds;
+ input_bfd != NULL;
+ input_bfd = input_bfd->link.next)
+ {
+ asection *section;
+
+ if (!is_aarch64_elf (input_bfd)
+ || (input_bfd->flags & BFD_LINKER_CREATED) != 0)
+ continue;
+
+ for (section = input_bfd->sections;
+ section != NULL;
+ section = section->next)
+ if (!_bfd_aarch64_erratum_843419_scan (input_bfd, section, info))
+ return false;
+ }
+
+ _bfd_aarch64_resize_stubs (htab);
+ (*htab->layout_sections_again) ();
+ }
+
+ for (;;)
+ {
+ bool stub_changed = false;
+
+ if (!_bfd_aarch64_add_call_stub_entries (&stub_changed, output_bfd, info))
+ return false;
+
+ if (!stub_changed)
+ return true;
+
+ _bfd_aarch64_resize_stubs (htab);
+ (*htab->layout_sections_again) ();
+ }
+}
+
+/* Build all the stubs associated with the current output file. The
+ stubs are kept in a hash table attached to the main linker hash
+ table. We also set up the .plt entries for statically linked PIC
+ functions here. This function is called via aarch64_elf_finish in the
+ linker. */
+
+bool
+elfNN_aarch64_build_stubs (struct bfd_link_info *info)
+{
+ asection *stub_sec;
+ struct bfd_hash_table *table;
+ struct elf_aarch64_link_hash_table *htab;
+
+ htab = elf_aarch64_hash_table (info);
+
+ for (stub_sec = htab->stub_bfd->sections;
+ stub_sec != NULL; stub_sec = stub_sec->next)
+ {
+ bfd_size_type size;
+
+ /* Ignore non-stub sections. */
+ if (!strstr (stub_sec->name, STUB_SUFFIX))
+ continue;
+
+ /* Allocate memory to hold the linker stubs. */
+ size = stub_sec->size;
+ stub_sec->contents = bfd_zalloc (htab->stub_bfd, size);
+ if (stub_sec->contents == NULL && size != 0)
+ return false;
+ stub_sec->size = 0;
+
+ /* Add a branch around the stub section, and a nop, to keep it 8 byte
+ aligned, as long branch stubs contain a 64-bit address. */
+ bfd_putl32 (0x14000000 | (size >> 2), stub_sec->contents);
+ bfd_putl32 (INSN_NOP, stub_sec->contents + 4);
+ stub_sec->size += 8;
+ }
+
+ /* Build the stubs as directed by the stub hash table. */
+ table = &htab->stub_hash_table;
+ bfd_hash_traverse (table, aarch64_build_one_stub, info);
+
+ return true;
+}
+
+
+/* Add an entry to the code/data map for section SEC. */
+
+static void
+elfNN_aarch64_section_map_add (asection *sec, char type, bfd_vma vma)
+{
+ struct _aarch64_elf_section_data *sec_data =
+ elf_aarch64_section_data (sec);
+ unsigned int newidx;
+
+ if (sec_data->map == NULL)
+ {
+ sec_data->map = bfd_malloc (sizeof (elf_aarch64_section_map));
+ sec_data->mapcount = 0;
+ sec_data->mapsize = 1;
+ }
+
+ newidx = sec_data->mapcount++;
+
+ if (sec_data->mapcount > sec_data->mapsize)
+ {
+ sec_data->mapsize *= 2;
+ sec_data->map = bfd_realloc_or_free
+ (sec_data->map, sec_data->mapsize * sizeof (elf_aarch64_section_map));
+ }
+
+ if (sec_data->map)
+ {
+ sec_data->map[newidx].vma = vma;
+ sec_data->map[newidx].type = type;
+ }
+}
+
+
+/* Initialise maps of insn/data for input BFDs. */
+void
+bfd_elfNN_aarch64_init_maps (bfd *abfd)
+{
+ Elf_Internal_Sym *isymbuf;
+ Elf_Internal_Shdr *hdr;
+ unsigned int i, localsyms;
+
+ /* Make sure that we are dealing with an AArch64 elf binary. */
+ if (!is_aarch64_elf (abfd))
+ return;
+
+ if ((abfd->flags & DYNAMIC) != 0)
+ return;
+
+ hdr = &elf_symtab_hdr (abfd);
+ localsyms = hdr->sh_info;
+
+ /* Obtain a buffer full of symbols for this BFD. The hdr->sh_info field
+ should contain the number of local symbols, which should come before any
+ global symbols. Mapping symbols are always local. */
+ isymbuf = bfd_elf_get_elf_syms (abfd, hdr, localsyms, 0, NULL, NULL, NULL);
+
+ /* No internal symbols read? Skip this BFD. */
+ if (isymbuf == NULL)
+ return;
+
+ for (i = 0; i < localsyms; i++)
+ {
+ Elf_Internal_Sym *isym = &isymbuf[i];
+ asection *sec = bfd_section_from_elf_index (abfd, isym->st_shndx);
+ const char *name;
+
+ if (sec != NULL && ELF_ST_BIND (isym->st_info) == STB_LOCAL)
+ {
+ name = bfd_elf_string_from_elf_section (abfd,
+ hdr->sh_link,
+ isym->st_name);
+
+ if (bfd_is_aarch64_special_symbol_name
+ (name, BFD_AARCH64_SPECIAL_SYM_TYPE_MAP))
+ elfNN_aarch64_section_map_add (sec, name[1], isym->st_value);
+ }
+ }
+}
+
+static void
+setup_plt_values (struct bfd_link_info *link_info,
+ aarch64_plt_type plt_type)
+{
+ struct elf_aarch64_link_hash_table *globals;
+ globals = elf_aarch64_hash_table (link_info);
+
+ if (plt_type == PLT_BTI_PAC)
+ {
+ globals->plt0_entry = elfNN_aarch64_small_plt0_bti_entry;
+
+ /* Only in ET_EXEC we need PLTn with BTI. */
+ if (bfd_link_executable (link_info))
+ {
+ globals->plt_entry_size = PLT_BTI_PAC_SMALL_ENTRY_SIZE;
+ globals->plt_entry = elfNN_aarch64_small_plt_bti_pac_entry;
+ globals->plt_entry_delta = 4;
+ }
+ else
+ {
+ globals->plt_entry_size = PLT_PAC_SMALL_ENTRY_SIZE;
+ globals->plt_entry = elfNN_aarch64_small_plt_pac_entry;
+ globals->plt_entry_delta = 0;
+ }
+ }
+ else if (plt_type == PLT_BTI)
+ {
+ globals->plt0_entry = elfNN_aarch64_small_plt0_bti_entry;
+
+ /* Only in ET_EXEC we need PLTn with BTI. */
+ if (bfd_link_executable (link_info))
+ {
+ globals->plt_entry_size = PLT_BTI_SMALL_ENTRY_SIZE;
+ globals->plt_entry = elfNN_aarch64_small_plt_bti_entry;
+ globals->plt_entry_delta = 4;
+ }
+ }
+ else if (plt_type == PLT_PAC)
+ {
+ globals->plt_entry_size = PLT_PAC_SMALL_ENTRY_SIZE;
+ globals->plt_entry = elfNN_aarch64_small_plt_pac_entry;
+ }
+}
+
+/* Set option values needed during linking. */
+void
+bfd_elfNN_aarch64_set_options (struct bfd *output_bfd,
+ struct bfd_link_info *link_info,
+ int no_enum_warn,
+ int no_wchar_warn, int pic_veneer,
+ int fix_erratum_835769,
+ erratum_84319_opts fix_erratum_843419,
+ int no_apply_dynamic_relocs,
+ const aarch64_protection_opts *sw_protections)
+{
+ struct elf_aarch64_link_hash_table *globals;
+
+ globals = elf_aarch64_hash_table (link_info);
+ globals->pic_veneer = pic_veneer;
+ globals->fix_erratum_835769 = fix_erratum_835769;
+ /* If the default options are used, then ERRAT_ADR will be set by default
+ which will enable the ADRP->ADR workaround for the erratum 843419
+ workaround. */
+ globals->fix_erratum_843419 = fix_erratum_843419;
+ globals->no_apply_dynamic_relocs = no_apply_dynamic_relocs;
+
+ BFD_ASSERT (is_aarch64_elf (output_bfd));
+ elf_aarch64_tdata (output_bfd)->no_enum_size_warning = no_enum_warn;
+ elf_aarch64_tdata (output_bfd)->no_wchar_size_warning = no_wchar_warn;
+
+ /* Note: gnu_property_aarch64_feature_1_and was initialized to 0 by
+ bfd_zalloc(). */
+ if (sw_protections->plt_type & PLT_BTI)
+ elf_aarch64_tdata (output_bfd)->gnu_property_aarch64_feature_1_and
+ |= GNU_PROPERTY_AARCH64_FEATURE_1_BTI;
+
+ switch (sw_protections->gcs_type)
+ {
+ case GCS_ALWAYS:
+ elf_aarch64_tdata (output_bfd)->gnu_property_aarch64_feature_1_and
+ |= GNU_PROPERTY_AARCH64_FEATURE_1_GCS;
+ break;
+ case GCS_NEVER:
+ elf_aarch64_tdata (output_bfd)->gnu_property_aarch64_feature_1_and
+ &= ~GNU_PROPERTY_AARCH64_FEATURE_1_GCS;
+ break;
+ case GCS_IMPLICIT:
+ /* GCS feature on the output bfd will be deduced from input objects. */
+ break;
+ }
+
+ elf_aarch64_tdata (output_bfd)->sw_protections = *sw_protections;
+ /* Inherit the value from '-z gcs-report' if the option '-z gcs-report-dynamic'
+ was not set on the command line. However, the inheritance mechanism is
+ capped to avoid inheriting the error level from -g gcs-report as the user
+ might want to continue to build a module without rebuilding all the shared
+ libraries. If a user also wants to error GCS issues in the shared
+ libraries, '-z gcs-report-dynamic=error' will have to be specified
+ explicitly. */
+ if (sw_protections->gcs_report_dynamic == MARKING_UNSET)
+ elf_aarch64_tdata (output_bfd)->sw_protections.gcs_report_dynamic
+ = (sw_protections->gcs_report == MARKING_ERROR)
+ ? MARKING_WARN
+ : sw_protections->gcs_report;
+
+ elf_aarch64_tdata (output_bfd)->n_bti_issues = 0;
+ elf_aarch64_tdata (output_bfd)->n_gcs_issues = 0;
+ elf_aarch64_tdata (output_bfd)->n_gcs_dynamic_issues = 0;
+
+ setup_plt_values (link_info, sw_protections->plt_type);
+}
+
+static bfd_vma
+aarch64_calculate_got_entry_vma (struct elf_link_hash_entry *h,
+ struct elf_aarch64_link_hash_table
+ *globals, struct bfd_link_info *info,
+ bfd_vma value, bfd *output_bfd,
+ bool *unresolved_reloc_p)
+{
+ bfd_vma off = (bfd_vma) - 1;
+ asection *basegot = globals->root.sgot;
+ bool dyn = globals->root.dynamic_sections_created;
+
+ if (h != NULL)
+ {
+ BFD_ASSERT (basegot != NULL);
+ off = h->got.offset;
+ BFD_ASSERT (off != (bfd_vma) - 1);
+ if (!WILL_CALL_FINISH_DYNAMIC_SYMBOL (dyn, bfd_link_pic (info), h)
+ || (bfd_link_pic (info)
+ && SYMBOL_REFERENCES_LOCAL (info, h))
+ || (ELF_ST_VISIBILITY (h->other)
+ && h->root.type == bfd_link_hash_undefweak))
+ {
+ /* This is actually a static link, or it is a -Bsymbolic link
+ and the symbol is defined locally. We must initialize this
+ entry in the global offset table. Since the offset must
+ always be a multiple of 8 (4 in the case of ILP32), we use
+ the least significant bit to record whether we have
+ initialized it already.
+ When doing a dynamic link, we create a .rel(a).got relocation
+ entry to initialize the value. This is done in the
+ finish_dynamic_symbol routine. */
+ if ((off & 1) != 0)
+ off &= ~1;
+ else
+ {
+ bfd_put_NN (output_bfd, value, basegot->contents + off);
+ h->got.offset |= 1;
+ }
+ }
+ else
+ *unresolved_reloc_p = false;
+
+ off = off + basegot->output_section->vma + basegot->output_offset;
+ }
+
+ return off;
+}
+
+/* Change R_TYPE to a more efficient access model where possible,
+ return the new reloc type. */
+
+static bfd_reloc_code_real_type
+aarch64_tls_transition_without_check (bfd_reloc_code_real_type r_type,
+ struct elf_link_hash_entry *h,
+ struct bfd_link_info *info)
+{
+ bool local_exec = bfd_link_executable (info)
+ && SYMBOL_REFERENCES_LOCAL (info, h);
+
+ switch (r_type)
+ {
+ case BFD_RELOC_AARCH64_TLSDESC_ADR_PAGE21:
+ case BFD_RELOC_AARCH64_TLSGD_ADR_PAGE21:
+ return (local_exec
+ ? BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G1
+ : BFD_RELOC_AARCH64_TLSIE_ADR_GOTTPREL_PAGE21);
+
+ case BFD_RELOC_AARCH64_TLSDESC_ADR_PREL21:
+ return (local_exec
+ ? BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G0_NC
+ : r_type);
+
+ case BFD_RELOC_AARCH64_TLSDESC_LD_PREL19:
+ return (local_exec
+ ? BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G1
+ : BFD_RELOC_AARCH64_TLSIE_LD_GOTTPREL_PREL19);
+
+ case BFD_RELOC_AARCH64_TLSDESC_LDR:
+ return (local_exec
+ ? BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G0_NC
+ : BFD_RELOC_AARCH64_NONE);
+
+ case BFD_RELOC_AARCH64_TLSDESC_OFF_G0_NC:
+ return (local_exec
+ ? BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G1_NC
+ : BFD_RELOC_AARCH64_TLSIE_MOVW_GOTTPREL_G0_NC);
+
+ case BFD_RELOC_AARCH64_TLSDESC_OFF_G1:
+ return (local_exec
+ ? BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G2
+ : BFD_RELOC_AARCH64_TLSIE_MOVW_GOTTPREL_G1);
+
+ case BFD_RELOC_AARCH64_TLSDESC_LDNN_LO12_NC:
+ case BFD_RELOC_AARCH64_TLSGD_ADD_LO12_NC:
+ return (local_exec
+ ? BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G0_NC
+ : BFD_RELOC_AARCH64_TLSIE_LDNN_GOTTPREL_LO12_NC);
+
+ case BFD_RELOC_AARCH64_TLSIE_ADR_GOTTPREL_PAGE21:
+ return local_exec ? BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G1 : r_type;
+
+ case BFD_RELOC_AARCH64_TLSIE_LDNN_GOTTPREL_LO12_NC:
+ return local_exec ? BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G0_NC : r_type;
+
+ case BFD_RELOC_AARCH64_TLSIE_LD_GOTTPREL_PREL19:
+ return r_type;
+
+ case BFD_RELOC_AARCH64_TLSGD_ADR_PREL21:
+ return (local_exec
+ ? BFD_RELOC_AARCH64_TLSLE_ADD_TPREL_HI12
+ : BFD_RELOC_AARCH64_TLSIE_LD_GOTTPREL_PREL19);
+
+ case BFD_RELOC_AARCH64_TLSDESC_ADD:
+ case BFD_RELOC_AARCH64_TLSDESC_ADD_LO12:
+ case BFD_RELOC_AARCH64_TLSDESC_CALL:
+ /* Instructions with these relocations will become NOPs. */
+ return BFD_RELOC_AARCH64_NONE;
+
+ case BFD_RELOC_AARCH64_TLSLD_ADD_LO12_NC:
+ case BFD_RELOC_AARCH64_TLSLD_ADR_PAGE21:
+ case BFD_RELOC_AARCH64_TLSLD_ADR_PREL21:
+ return local_exec ? BFD_RELOC_AARCH64_NONE : r_type;
+
+#if ARCH_SIZE == 64
+ case BFD_RELOC_AARCH64_TLSGD_MOVW_G0_NC:
+ return local_exec
+ ? BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G1_NC
+ : BFD_RELOC_AARCH64_TLSIE_MOVW_GOTTPREL_G0_NC;
+
+ case BFD_RELOC_AARCH64_TLSGD_MOVW_G1:
+ return local_exec
+ ? BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G2
+ : BFD_RELOC_AARCH64_TLSIE_MOVW_GOTTPREL_G1;
+#endif
+
+ default:
+ break;
+ }
+
+ return r_type;
+}
+
+static unsigned int
+aarch64_reloc_got_type (bfd_reloc_code_real_type r_type)
+{
+ switch (r_type)
+ {
+ case BFD_RELOC_AARCH64_ADR_GOT_PAGE:
+ case BFD_RELOC_AARCH64_GOT_LD_PREL19:
+ case BFD_RELOC_AARCH64_LD32_GOTPAGE_LO14:
+ case BFD_RELOC_AARCH64_LD32_GOT_LO12_NC:
+ case BFD_RELOC_AARCH64_LD64_GOTOFF_LO15:
+ case BFD_RELOC_AARCH64_LD64_GOTPAGE_LO15:
+ case BFD_RELOC_AARCH64_LD64_GOT_LO12_NC:
+ case BFD_RELOC_AARCH64_MOVW_GOTOFF_G0_NC:
+ case BFD_RELOC_AARCH64_MOVW_GOTOFF_G1:
+ return GOT_NORMAL;
+
+ case BFD_RELOC_AARCH64_TLSGD_ADD_LO12_NC:
+ case BFD_RELOC_AARCH64_TLSGD_ADR_PAGE21:
+ case BFD_RELOC_AARCH64_TLSGD_ADR_PREL21:
+ case BFD_RELOC_AARCH64_TLSGD_MOVW_G0_NC:
+ case BFD_RELOC_AARCH64_TLSGD_MOVW_G1:
+ case BFD_RELOC_AARCH64_TLSLD_ADD_LO12_NC:
+ case BFD_RELOC_AARCH64_TLSLD_ADR_PAGE21:
+ case BFD_RELOC_AARCH64_TLSLD_ADR_PREL21:
+ return GOT_TLS_GD;
+
+ case BFD_RELOC_AARCH64_TLSDESC_ADD:
+ case BFD_RELOC_AARCH64_TLSDESC_ADD_LO12:
+ case BFD_RELOC_AARCH64_TLSDESC_ADR_PAGE21:
+ case BFD_RELOC_AARCH64_TLSDESC_ADR_PREL21:
+ case BFD_RELOC_AARCH64_TLSDESC_CALL:
+ case BFD_RELOC_AARCH64_TLSDESC_LD32_LO12_NC:
+ case BFD_RELOC_AARCH64_TLSDESC_LD64_LO12:
+ case BFD_RELOC_AARCH64_TLSDESC_LD_PREL19:
+ case BFD_RELOC_AARCH64_TLSDESC_LDR:
+ case BFD_RELOC_AARCH64_TLSDESC_OFF_G0_NC:
+ case BFD_RELOC_AARCH64_TLSDESC_OFF_G1:
+ return GOT_TLSDESC_GD;
+
+ case BFD_RELOC_AARCH64_TLSIE_ADR_GOTTPREL_PAGE21:
+ case BFD_RELOC_AARCH64_TLSIE_LD32_GOTTPREL_LO12_NC:
+ case BFD_RELOC_AARCH64_TLSIE_LD64_GOTTPREL_LO12_NC:
+ case BFD_RELOC_AARCH64_TLSIE_LD_GOTTPREL_PREL19:
+ case BFD_RELOC_AARCH64_TLSIE_MOVW_GOTTPREL_G0_NC:
+ case BFD_RELOC_AARCH64_TLSIE_MOVW_GOTTPREL_G1:
+ return GOT_TLS_IE;
+
+ default:
+ break;
+ }
+ return GOT_UNKNOWN;
+}
+
+static bool
+aarch64_can_relax_tls (bfd *input_bfd,
+ struct bfd_link_info *info,
+ bfd_reloc_code_real_type r_type,
+ struct elf_link_hash_entry *h,
+ unsigned long r_symndx)
+{
+ unsigned int symbol_got_type;
+ unsigned int reloc_got_type;
+
+ if (! IS_AARCH64_TLS_RELAX_RELOC (r_type))
+ return false;
+
+ symbol_got_type = elfNN_aarch64_symbol_got_type (h, input_bfd, r_symndx);
+ reloc_got_type = aarch64_reloc_got_type (r_type);
+
+ if (symbol_got_type == GOT_TLS_IE && GOT_TLS_GD_ANY_P (reloc_got_type))
+ return true;
+
+ if (!bfd_link_executable (info))
+ return false;
+
+ if (h && h->root.type == bfd_link_hash_undefweak)
+ return false;
+
+ return true;
+}
+
+/* Given the relocation code R_TYPE, return the relaxed bfd reloc
+ enumerator. */
+
+static bfd_reloc_code_real_type
+aarch64_tls_transition (bfd *input_bfd,
+ struct bfd_link_info *info,
+ unsigned int r_type,
+ struct elf_link_hash_entry *h,
+ unsigned long r_symndx)
+{
+ bfd_reloc_code_real_type bfd_r_type
+ = elfNN_aarch64_bfd_reloc_from_type (input_bfd, r_type);
+
+ if (! aarch64_can_relax_tls (input_bfd, info, bfd_r_type, h, r_symndx))
+ return bfd_r_type;
+
+ return aarch64_tls_transition_without_check (bfd_r_type, h, info);
+}
+
+/* Return the base VMA address which should be subtracted from real addresses
+ when resolving R_AARCH64_TLS_DTPREL relocation. */
+
+static bfd_vma
+dtpoff_base (struct bfd_link_info *info)
+{
+ /* If tls_sec is NULL, we should have signalled an error already. */
+ BFD_ASSERT (elf_hash_table (info)->tls_sec != NULL);
+ return elf_hash_table (info)->tls_sec->vma;
+}
+
+/* Return the base VMA address which should be subtracted from real addresses
+ when resolving R_AARCH64_TLS_GOTTPREL64 relocations. */
+
+static bfd_vma
+tpoff_base (struct bfd_link_info *info)
+{
+ struct elf_link_hash_table *htab = elf_hash_table (info);
+
+ /* If tls_sec is NULL, we should have signalled an error already. */
+ BFD_ASSERT (htab->tls_sec != NULL);
+
+ bfd_vma base = align_power ((bfd_vma) TCB_SIZE,
+ htab->tls_sec->alignment_power);
+ return htab->tls_sec->vma - base;
+}
+
+static bfd_vma *
+symbol_got_offset_ref (bfd *input_bfd, struct elf_link_hash_entry *h,
+ unsigned long r_symndx)
+{
+ /* Calculate the address of the GOT entry for symbol
+ referred to in h. */
+ if (h != NULL)
+ return &h->got.offset;
+ else
+ {
+ /* local symbol */
+ struct elf_aarch64_local_symbol *l;
+
+ l = elf_aarch64_locals (input_bfd);
+ return &l[r_symndx].got_offset;
+ }
+}
+
+static void
+symbol_got_offset_mark (bfd *input_bfd, struct elf_link_hash_entry *h,
+ unsigned long r_symndx)
+{
+ bfd_vma *p;
+ p = symbol_got_offset_ref (input_bfd, h, r_symndx);
+ *p |= 1;
+}
+
+static int
+symbol_got_offset_mark_p (bfd *input_bfd, struct elf_link_hash_entry *h,
+ unsigned long r_symndx)
+{
+ bfd_vma value;
+ value = * symbol_got_offset_ref (input_bfd, h, r_symndx);
+ return value & 1;
+}
+
+static bfd_vma
+symbol_got_offset (bfd *input_bfd, struct elf_link_hash_entry *h,
+ unsigned long r_symndx)
+{
+ bfd_vma value;
+ value = * symbol_got_offset_ref (input_bfd, h, r_symndx);
+ value &= ~1;
+ return value;
+}
+
+static bfd_vma *
+symbol_tlsdesc_got_offset_ref (bfd *input_bfd, struct elf_link_hash_entry *h,
+ unsigned long r_symndx)
+{
+ /* Calculate the address of the GOT entry for symbol
+ referred to in h. */
+ if (h != NULL)
+ {
+ struct elf_aarch64_link_hash_entry *eh;
+ eh = (struct elf_aarch64_link_hash_entry *) h;
+ return &eh->tlsdesc_got_jump_table_offset;
+ }
+ else
+ {
+ /* local symbol */
+ struct elf_aarch64_local_symbol *l;
+
+ l = elf_aarch64_locals (input_bfd);
+ return &l[r_symndx].tlsdesc_got_jump_table_offset;
+ }
+}
+
+static void
+symbol_tlsdesc_got_offset_mark (bfd *input_bfd, struct elf_link_hash_entry *h,
+ unsigned long r_symndx)
+{
+ bfd_vma *p;
+ p = symbol_tlsdesc_got_offset_ref (input_bfd, h, r_symndx);
+ *p |= 1;
+}
+
+static int
+symbol_tlsdesc_got_offset_mark_p (bfd *input_bfd,
+ struct elf_link_hash_entry *h,
+ unsigned long r_symndx)
+{
+ bfd_vma value;
+ value = * symbol_tlsdesc_got_offset_ref (input_bfd, h, r_symndx);
+ return value & 1;
+}
+
+static bfd_vma
+symbol_tlsdesc_got_offset (bfd *input_bfd, struct elf_link_hash_entry *h,
+ unsigned long r_symndx)
+{
+ bfd_vma value;
+ value = * symbol_tlsdesc_got_offset_ref (input_bfd, h, r_symndx);
+ value &= ~1;
+ return value;
+}
+
+/* Data for make_branch_to_erratum_835769_stub(). */
+
+struct erratum_835769_branch_to_stub_data
+{
+ struct bfd_link_info *info;
+ asection *output_section;
+ bfd_byte *contents;
+};
+
+/* Helper to insert branches to erratum 835769 stubs in the right
+ places for a particular section. */
+
+static bool
+make_branch_to_erratum_835769_stub (struct bfd_hash_entry *gen_entry,
+ void *in_arg)
+{
+ struct elf_aarch64_stub_hash_entry *stub_entry;
+ struct erratum_835769_branch_to_stub_data *data;
+ bfd_byte *contents;
+ unsigned long branch_insn = 0;
+ bfd_vma veneered_insn_loc, veneer_entry_loc;
+ bfd_signed_vma branch_offset;
+ unsigned int target;
+ bfd *abfd;
+
+ stub_entry = (struct elf_aarch64_stub_hash_entry *) gen_entry;
+ data = (struct erratum_835769_branch_to_stub_data *) in_arg;
+
+ if (stub_entry->target_section != data->output_section
+ || stub_entry->stub_type != aarch64_stub_erratum_835769_veneer)
+ return true;
+
+ contents = data->contents;
+ veneered_insn_loc = stub_entry->target_section->output_section->vma
+ + stub_entry->target_section->output_offset
+ + stub_entry->target_value;
+ veneer_entry_loc = stub_entry->stub_sec->output_section->vma
+ + stub_entry->stub_sec->output_offset
+ + stub_entry->stub_offset;
+ branch_offset = veneer_entry_loc - veneered_insn_loc;
+
+ abfd = stub_entry->target_section->owner;
+ if (!aarch64_valid_branch_p (veneer_entry_loc, veneered_insn_loc))
+ _bfd_error_handler
+ (_("%pB: error: erratum 835769 stub out "
+ "of range (input file too large)"), abfd);
+
+ target = stub_entry->target_value;
+ branch_insn = 0x14000000;
+ branch_offset >>= 2;
+ branch_offset &= 0x3ffffff;
+ branch_insn |= branch_offset;
+ bfd_putl32 (branch_insn, &contents[target]);
+
+ return true;
+}
+
+
+static bool
+_bfd_aarch64_erratum_843419_branch_to_stub (struct bfd_hash_entry *gen_entry,
+ void *in_arg)
+{
+ struct elf_aarch64_stub_hash_entry *stub_entry
+ = (struct elf_aarch64_stub_hash_entry *) gen_entry;
+ struct erratum_835769_branch_to_stub_data *data
+ = (struct erratum_835769_branch_to_stub_data *) in_arg;
+ struct bfd_link_info *info;
+ struct elf_aarch64_link_hash_table *htab;
+ bfd_byte *contents;
+ asection *section;
+ bfd *abfd;
+ bfd_vma place;
+ uint32_t insn;
+
+ info = data->info;
+ contents = data->contents;
+ section = data->output_section;
+
+ htab = elf_aarch64_hash_table (info);
+
+ if (stub_entry->target_section != section
+ || stub_entry->stub_type != aarch64_stub_erratum_843419_veneer)
+ return true;
+
+ BFD_ASSERT (((htab->fix_erratum_843419 & ERRAT_ADRP) && stub_entry->stub_sec)
+ || (htab->fix_erratum_843419 & ERRAT_ADR));
+
+ /* Only update the stub section if we have one. We should always have one if
+ we're allowed to use the ADRP errata workaround, otherwise it is not
+ required. */
+ if (stub_entry->stub_sec)
+ {
+ insn = bfd_getl32 (contents + stub_entry->target_value);
+ bfd_putl32 (insn,
+ stub_entry->stub_sec->contents + stub_entry->stub_offset);
+ }
+
+ place = (section->output_section->vma + section->output_offset
+ + stub_entry->adrp_offset);
+ insn = bfd_getl32 (contents + stub_entry->adrp_offset);
+
+ if (!_bfd_aarch64_adrp_p (insn))
+ abort ();
+
+ bfd_signed_vma imm =
+ (_bfd_aarch64_sign_extend
+ ((bfd_vma) _bfd_aarch64_decode_adrp_imm (insn) << 12, 33)
+ - (place & 0xfff));
+
+ if ((htab->fix_erratum_843419 & ERRAT_ADR)
+ && (imm >= AARCH64_MIN_ADRP_IMM && imm <= AARCH64_MAX_ADRP_IMM))
+ {
+ insn = (_bfd_aarch64_reencode_adr_imm (AARCH64_ADR_OP, imm)
+ | AARCH64_RT (insn));
+ bfd_putl32 (insn, contents + stub_entry->adrp_offset);
+ /* Stub is not needed, don't map it out. */
+ stub_entry->stub_type = aarch64_stub_none;
+ }
+ else if (htab->fix_erratum_843419 & ERRAT_ADRP)
+ {
+ bfd_vma veneered_insn_loc;
+ bfd_vma veneer_entry_loc;
+ bfd_signed_vma branch_offset;
+ uint32_t branch_insn;
+
+ veneered_insn_loc = stub_entry->target_section->output_section->vma
+ + stub_entry->target_section->output_offset
+ + stub_entry->target_value;
+ veneer_entry_loc = stub_entry->stub_sec->output_section->vma
+ + stub_entry->stub_sec->output_offset
+ + stub_entry->stub_offset;
+ branch_offset = veneer_entry_loc - veneered_insn_loc;
+
+ abfd = stub_entry->target_section->owner;
+ if (!aarch64_valid_branch_p (veneer_entry_loc, veneered_insn_loc))
+ _bfd_error_handler
+ (_("%pB: error: erratum 843419 stub out "
+ "of range (input file too large)"), abfd);
+
+ branch_insn = 0x14000000;
+ branch_offset >>= 2;
+ branch_offset &= 0x3ffffff;
+ branch_insn |= branch_offset;
+ bfd_putl32 (branch_insn, contents + stub_entry->target_value);
+ }
+ else
+ {
+ abfd = stub_entry->target_section->owner;
+ _bfd_error_handler
+ (_("%pB: error: erratum 843419 immediate 0x%" PRIx64
+ " out of range for ADR (input file too large) and "
+ "--fix-cortex-a53-843419=adr used. Run the linker with "
+ "--fix-cortex-a53-843419=full instead"),
+ abfd, (uint64_t) (bfd_vma) imm);
+ bfd_set_error (bfd_error_bad_value);
+ /* This function is called inside a hashtable traversal and the error
+ handlers called above turn into non-fatal errors. Which means this
+ case ld returns an exit code 0 and also produces a broken object file.
+ To prevent this, issue a hard abort. */
+ BFD_FAIL ();
+ }
+ return true;
+}
+
+
+static bool
+elfNN_aarch64_write_section (bfd *output_bfd ATTRIBUTE_UNUSED,
+ struct bfd_link_info *link_info,
+ asection *sec,
+ bfd_byte *contents)
+
+{
+ struct elf_aarch64_link_hash_table *globals =
+ elf_aarch64_hash_table (link_info);
+
+ if (globals == NULL)
+ return false;
+
+ /* Fix code to point to erratum 835769 stubs. */
+ if (globals->fix_erratum_835769)
+ {
+ struct erratum_835769_branch_to_stub_data data;
+
+ data.info = link_info;
+ data.output_section = sec;
+ data.contents = contents;
+ bfd_hash_traverse (&globals->stub_hash_table,
+ make_branch_to_erratum_835769_stub, &data);
+ }
+
+ if (globals->fix_erratum_843419)
+ {
+ struct erratum_835769_branch_to_stub_data data;
+
+ data.info = link_info;
+ data.output_section = sec;
+ data.contents = contents;
+ bfd_hash_traverse (&globals->stub_hash_table,
+ _bfd_aarch64_erratum_843419_branch_to_stub, &data);
+ }
+
+ return false;
+}
+
+/* Return TRUE if RELOC is a relocation against the base of GOT table. */
+
+static bool
+aarch64_relocation_aginst_gp_p (bfd_reloc_code_real_type reloc)
+{
+ return (reloc == BFD_RELOC_AARCH64_LD32_GOTPAGE_LO14
+ || reloc == BFD_RELOC_AARCH64_LD64_GOTPAGE_LO15
+ || reloc == BFD_RELOC_AARCH64_LD64_GOTOFF_LO15
+ || reloc == BFD_RELOC_AARCH64_MOVW_GOTOFF_G0_NC
+ || reloc == BFD_RELOC_AARCH64_MOVW_GOTOFF_G1);
+}
+
+/* Perform a relocation as part of a final link. The input relocation type
+ should be TLS relaxed. */
+
+static bfd_reloc_status_type
+elfNN_aarch64_final_link_relocate (reloc_howto_type *howto,
+ bfd *input_bfd,
+ bfd *output_bfd,
+ asection *input_section,
+ bfd_byte *contents,
+ Elf_Internal_Rela *rel,
+ bfd_vma value,
+ struct bfd_link_info *info,
+ asection *sym_sec,
+ struct elf_link_hash_entry *h,
+ bool *unresolved_reloc_p,
+ bool save_addend,
+ bfd_vma *saved_addend,
+ Elf_Internal_Sym *sym)
+{
+ Elf_Internal_Shdr *symtab_hdr;
+ unsigned int r_type = howto->type;
+ bfd_reloc_code_real_type bfd_r_type
+ = elfNN_aarch64_bfd_reloc_from_howto (howto);
+ unsigned long r_symndx;
+ bfd_byte *hit_data = contents + rel->r_offset;
+ bfd_vma place, off, got_entry_addr = 0;
+ bfd_signed_vma signed_addend;
+ struct elf_aarch64_link_hash_table *globals;
+ bool weak_undef_p;
+ bool relative_reloc;
+ asection *base_got;
+ bfd_vma orig_value = value;
+ bool resolved_to_zero;
+ bool abs_symbol_p;
+
+ globals = elf_aarch64_hash_table (info);
+
+ symtab_hdr = &elf_symtab_hdr (input_bfd);
+
+ BFD_ASSERT (is_aarch64_elf (input_bfd));
+
+ r_symndx = ELFNN_R_SYM (rel->r_info);
+
+ place = input_section->output_section->vma
+ + input_section->output_offset + rel->r_offset;
+
+ /* Get addend, accumulating the addend for consecutive relocs
+ which refer to the same offset. */
+ signed_addend = saved_addend ? *saved_addend : 0;
+ signed_addend += rel->r_addend;
+
+ weak_undef_p = (h ? h->root.type == bfd_link_hash_undefweak
+ : bfd_is_und_section (sym_sec));
+ abs_symbol_p = h != NULL && bfd_is_abs_symbol (&h->root);
+
+
+ /* Since STT_GNU_IFUNC symbol must go through PLT, we handle
+ it here if it is defined in a non-shared object. */
+ if (h != NULL
+ && h->type == STT_GNU_IFUNC
+ && (input_section->flags & SEC_ALLOC)
+ && h->def_regular)
+ {
+ asection *plt;
+ const char *name;
+ bfd_vma addend = 0;
+
+ if ((input_section->flags & SEC_ALLOC) == 0)
+ {
+ /* If this is a SHT_NOTE section without SHF_ALLOC, treat
+ STT_GNU_IFUNC symbol as STT_FUNC. */
+ if (elf_section_type (input_section) == SHT_NOTE)
+ goto skip_ifunc;
+
+ /* Dynamic relocs are not propagated for SEC_DEBUGGING
+ sections because such sections are not SEC_ALLOC and
+ thus ld.so will not process them. */
+ if ((input_section->flags & SEC_DEBUGGING) != 0)
+ return bfd_reloc_ok;
+
+ if (h->root.root.string)
+ name = h->root.root.string;
+ else
+ name = bfd_elf_sym_name (input_bfd, symtab_hdr, sym, NULL);
+ _bfd_error_handler
+ /* xgettext:c-format */
+ (_("%pB(%pA+%#" PRIx64 "): "
+ "unresolvable %s relocation against symbol `%s'"),
+ input_bfd, input_section, (uint64_t) rel->r_offset,
+ howto->name, name);
+ bfd_set_error (bfd_error_bad_value);
+ return bfd_reloc_notsupported;
+ }
+ else if (h->plt.offset == (bfd_vma) -1)
+ goto bad_ifunc_reloc;
+
+ /* STT_GNU_IFUNC symbol must go through PLT. */
+ plt = globals->root.splt ? globals->root.splt : globals->root.iplt;
+ value = (plt->output_section->vma + plt->output_offset + h->plt.offset);
+
+ switch (bfd_r_type)
+ {
+ default:
+ bad_ifunc_reloc:
+ if (h->root.root.string)
+ name = h->root.root.string;
+ else
+ name = bfd_elf_sym_name (input_bfd, symtab_hdr, sym,
+ NULL);
+ _bfd_error_handler
+ /* xgettext:c-format */
+ (_("%pB: relocation %s against STT_GNU_IFUNC "
+ "symbol `%s' isn't handled by %s"), input_bfd,
+ howto->name, name, __func__);
+ bfd_set_error (bfd_error_bad_value);
+ return bfd_reloc_notsupported;
+
+ case BFD_RELOC_AARCH64_NN:
+ if (rel->r_addend != 0)
+ {
+ if (h->root.root.string)
+ name = h->root.root.string;
+ else
+ name = bfd_elf_sym_name (input_bfd, symtab_hdr,
+ sym, NULL);
+ _bfd_error_handler
+ /* xgettext:c-format */
+ (_("%pB: relocation %s against STT_GNU_IFUNC "
+ "symbol `%s' has non-zero addend: %" PRId64),
+ input_bfd, howto->name, name, (int64_t) rel->r_addend);
+ bfd_set_error (bfd_error_bad_value);
+ return bfd_reloc_notsupported;
+ }
+
+ /* Generate dynamic relocation only when there is a
+ non-GOT reference in a shared object. */
+ if (bfd_link_pic (info) && h->non_got_ref)
+ {
+ Elf_Internal_Rela outrel;
+ asection *sreloc;
+
+ /* Need a dynamic relocation to get the real function
+ address. */
+ outrel.r_offset = _bfd_elf_section_offset (output_bfd,
+ info,
+ input_section,
+ rel->r_offset);
+ if (outrel.r_offset == (bfd_vma) -1
+ || outrel.r_offset == (bfd_vma) -2)
+ abort ();
+
+ outrel.r_offset += (input_section->output_section->vma
+ + input_section->output_offset);
+
+ if (h->dynindx == -1
+ || h->forced_local
+ || bfd_link_executable (info))
+ {
+ /* This symbol is resolved locally. */
+ outrel.r_info = ELFNN_R_INFO (0, AARCH64_R (IRELATIVE));
+ outrel.r_addend = (h->root.u.def.value
+ + h->root.u.def.section->output_section->vma
+ + h->root.u.def.section->output_offset);
+ }
+ else
+ {
+ outrel.r_info = ELFNN_R_INFO (h->dynindx, r_type);
+ outrel.r_addend = 0;
+ }
+
+ sreloc = globals->root.irelifunc;
+ elf_append_rela (output_bfd, sreloc, &outrel);
+
+ /* If this reloc is against an external symbol, we
+ do not want to fiddle with the addend. Otherwise,
+ we need to include the symbol value so that it
+ becomes an addend for the dynamic reloc. For an
+ internal symbol, we have updated addend. */
+ return bfd_reloc_ok;
+ }
+ /* FALLTHROUGH */
+ case BFD_RELOC_AARCH64_CALL26:
+ case BFD_RELOC_AARCH64_JUMP26:
+ value = _bfd_aarch64_elf_resolve_relocation (input_bfd, bfd_r_type,
+ place, value,
+ signed_addend,
+ weak_undef_p);
+ return _bfd_aarch64_elf_put_addend (input_bfd, hit_data, bfd_r_type,
+ howto, value);
+ case BFD_RELOC_AARCH64_ADR_GOT_PAGE:
+ case BFD_RELOC_AARCH64_GOT_LD_PREL19:
+ case BFD_RELOC_AARCH64_LD32_GOTPAGE_LO14:
+ case BFD_RELOC_AARCH64_LD32_GOT_LO12_NC:
+ case BFD_RELOC_AARCH64_LD64_GOTPAGE_LO15:
+ case BFD_RELOC_AARCH64_MOVW_GOTOFF_G0_NC:
+ case BFD_RELOC_AARCH64_MOVW_GOTOFF_G1:
+ case BFD_RELOC_AARCH64_LD64_GOTOFF_LO15:
+ case BFD_RELOC_AARCH64_LD64_GOT_LO12_NC:
+ base_got = globals->root.sgot;
+ off = h->got.offset;
+
+ if (base_got == NULL)
+ abort ();
+
+ if (off == (bfd_vma) -1)
+ {
+ bfd_vma plt_index;
+
+ /* We can't use h->got.offset here to save state, or
+ even just remember the offset, as finish_dynamic_symbol
+ would use that as offset into .got. */
+
+ if (globals->root.splt != NULL)
+ {
+ plt_index = ((h->plt.offset - globals->plt_header_size) /
+ globals->plt_entry_size);
+ off = (plt_index + 3) * GOT_ENTRY_SIZE;
+ base_got = globals->root.sgotplt;
+ }
+ else
+ {
+ plt_index = h->plt.offset / globals->plt_entry_size;
+ off = plt_index * GOT_ENTRY_SIZE;
+ base_got = globals->root.igotplt;
+ }
+
+ if (h->dynindx == -1
+ || h->forced_local
+ || info->symbolic)
+ {
+ /* This references the local definition. We must
+ initialize this entry in the global offset table.
+ Since the offset must always be a multiple of 8,
+ we use the least significant bit to record
+ whether we have initialized it already.
+
+ When doing a dynamic link, we create a .rela.got
+ relocation entry to initialize the value. This
+ is done in the finish_dynamic_symbol routine. */
+ if ((off & 1) != 0)
+ off &= ~1;
+ else
+ {
+ bfd_put_NN (output_bfd, value,
+ base_got->contents + off);
+ /* Note that this is harmless as -1 | 1 still is -1. */
+ h->got.offset |= 1;
+ }
+ }
+ value = (base_got->output_section->vma
+ + base_got->output_offset + off);
+ }
+ else
+ value = aarch64_calculate_got_entry_vma (h, globals, info,
+ value, output_bfd,
+ unresolved_reloc_p);
+
+ if (aarch64_relocation_aginst_gp_p (bfd_r_type))
+ addend = (globals->root.sgot->output_section->vma
+ + globals->root.sgot->output_offset);
+
+ value = _bfd_aarch64_elf_resolve_relocation (input_bfd, bfd_r_type,
+ place, value,
+ addend, weak_undef_p);
+ return _bfd_aarch64_elf_put_addend (input_bfd, hit_data, bfd_r_type, howto, value);
+ case BFD_RELOC_AARCH64_ADD_LO12:
+ case BFD_RELOC_AARCH64_ADR_HI21_PCREL:
+ break;
+ }
+ }
+
+ skip_ifunc:
+ resolved_to_zero = (h != NULL
+ && UNDEFWEAK_NO_DYNAMIC_RELOC (info, h));
+
+ switch (bfd_r_type)
+ {
+ case BFD_RELOC_AARCH64_NONE:
+ case BFD_RELOC_AARCH64_TLSDESC_ADD:
+ case BFD_RELOC_AARCH64_TLSDESC_CALL:
+ case BFD_RELOC_AARCH64_TLSDESC_LDR:
+ *unresolved_reloc_p = false;
+ return bfd_reloc_ok;
+
+ case BFD_RELOC_AARCH64_NN:
+
+ /* When generating a shared library or PIE, these relocations
+ are copied into the output file to be resolved at run time. */
+ if ((bfd_link_pic (info)
+ && (input_section->flags & SEC_ALLOC)
+ && (h == NULL
+ || (ELF_ST_VISIBILITY (h->other) == STV_DEFAULT
+ && !resolved_to_zero)
+ || h->root.type != bfd_link_hash_undefweak))
+ /* Or we are creating an executable, we may need to keep relocations
+ for symbols satisfied by a dynamic library if we manage to avoid
+ copy relocs for the symbol. */
+ || (ELIMINATE_COPY_RELOCS
+ && !bfd_link_pic (info)
+ && h != NULL
+ && (input_section->flags & SEC_ALLOC)
+ && h->dynindx != -1
+ && !h->non_got_ref
+ && ((h->def_dynamic
+ && !h->def_regular)
+ || h->root.type == bfd_link_hash_undefweak
+ || h->root.type == bfd_link_hash_undefined)))
+ {
+ Elf_Internal_Rela outrel;
+ bfd_byte *loc;
+ bool skip, relocate;
+ asection *sreloc;
+
+ *unresolved_reloc_p = false;
+
+ skip = false;
+ relocate = false;
+
+ outrel.r_addend = signed_addend;
+ outrel.r_offset =
+ _bfd_elf_section_offset (output_bfd, info, input_section,
+ rel->r_offset);
+ if (outrel.r_offset == (bfd_vma) - 1)
+ skip = true;
+ else if (outrel.r_offset == (bfd_vma) - 2)
+ {
+ skip = true;
+ relocate = true;
+ }
+ else if (abs_symbol_p)
+ {
+ /* Local absolute symbol. */
+ skip = (h->forced_local || (h->dynindx == -1));
+ relocate = skip;
+ }
+
+ outrel.r_offset += (input_section->output_section->vma
+ + input_section->output_offset);
+
+ if (skip)
+ memset (&outrel, 0, sizeof outrel);
+ else if (h != NULL
+ && h->dynindx != -1
+ && (!bfd_link_pic (info)
+ || !(bfd_link_pie (info) || SYMBOLIC_BIND (info, h))
+ || !h->def_regular))
+ outrel.r_info = ELFNN_R_INFO (h->dynindx, r_type);
+ else if (info->enable_dt_relr
+ && input_section->alignment_power != 0
+ && rel->r_offset % 2 == 0)
+ {
+ /* Don't emit a relative relocation that is packed, only
+ apply the addend. */
+ return _bfd_final_link_relocate (howto, input_bfd, input_section,
+ contents, rel->r_offset, value,
+ signed_addend);
+ }
+ else
+ {
+ int symbol;
+
+ /* On SVR4-ish systems, the dynamic loader cannot
+ relocate the text and data segments independently,
+ so the symbol does not matter. */
+ symbol = 0;
+ relocate = !globals->no_apply_dynamic_relocs;
+ outrel.r_info = ELFNN_R_INFO (symbol, AARCH64_R (RELATIVE));
+ outrel.r_addend += value;
+ }
+
+ sreloc = elf_section_data (input_section)->sreloc;
+ if (sreloc == NULL || sreloc->contents == NULL)
+ return bfd_reloc_notsupported;
+
+ loc = sreloc->contents + sreloc->reloc_count++ * RELOC_SIZE (globals);
+ bfd_elfNN_swap_reloca_out (output_bfd, &outrel, loc);
+
+ if (sreloc->reloc_count * RELOC_SIZE (globals) > sreloc->size)
+ {
+ /* Sanity to check that we have previously allocated
+ sufficient space in the relocation section for the
+ number of relocations we actually want to emit. */
+ abort ();
+ }
+
+ /* If this reloc is against an external symbol, we do not want to
+ fiddle with the addend. Otherwise, we need to include the symbol
+ value so that it becomes an addend for the dynamic reloc. */
+ if (!relocate)
+ return bfd_reloc_ok;
+
+ return _bfd_final_link_relocate (howto, input_bfd, input_section,
+ contents, rel->r_offset, value,
+ signed_addend);
+ }
+ else
+ value += signed_addend;
+ break;
+
+ case BFD_RELOC_AARCH64_CALL26:
+ case BFD_RELOC_AARCH64_JUMP26:
+ {
+ asection *splt = globals->root.splt;
+ bool via_plt_p =
+ splt != NULL && h != NULL && h->plt.offset != (bfd_vma) - 1;
+
+ /* A call to an undefined weak symbol is converted to a jump to
+ the next instruction unless a PLT entry will be created.
+ The jump to the next instruction is optimized as a NOP.
+ Do the same for local undefined symbols. */
+ if (weak_undef_p && ! via_plt_p)
+ {
+ bfd_putl32 (INSN_NOP, hit_data);
+ return bfd_reloc_ok;
+ }
+
+ /* If the call goes through a PLT entry, make sure to
+ check distance to the right destination address. */
+ if (via_plt_p)
+ value = (splt->output_section->vma
+ + splt->output_offset + h->plt.offset);
+
+ /* Check if a stub has to be inserted because the destination
+ is too far away. */
+ struct elf_aarch64_stub_hash_entry *stub_entry = NULL;
+
+ /* If the branch destination is directed to plt stub, "value" will be
+ the final destination, otherwise we should plus signed_addend, it may
+ contain non-zero value, for example call to local function symbol
+ which are turned into "sec_sym + sec_off", and sec_off is kept in
+ signed_addend. */
+ if (! aarch64_valid_branch_p (via_plt_p ? value : value + signed_addend,
+ place))
+ /* The target is out of reach, so redirect the branch to
+ the local stub for this function. */
+ stub_entry = elfNN_aarch64_get_stub_entry (input_section, sym_sec, h,
+ rel, globals);
+ if (stub_entry != NULL)
+ {
+ value = (stub_entry->stub_offset
+ + stub_entry->stub_sec->output_offset
+ + stub_entry->stub_sec->output_section->vma);
+
+ /* We have redirected the destination to stub entry address,
+ so ignore any addend record in the original rela entry. */
+ signed_addend = 0;
+ }
+ }
+ value = _bfd_aarch64_elf_resolve_relocation (input_bfd, bfd_r_type,
+ place, value,
+ signed_addend, weak_undef_p);
+ *unresolved_reloc_p = false;
+ break;
+
+ case BFD_RELOC_AARCH64_16_PCREL:
+ case BFD_RELOC_AARCH64_32_PCREL:
+ case BFD_RELOC_AARCH64_64_PCREL:
+ case BFD_RELOC_AARCH64_ADR_HI21_NC_PCREL:
+ case BFD_RELOC_AARCH64_ADR_HI21_PCREL:
+ case BFD_RELOC_AARCH64_ADR_LO21_PCREL:
+ case BFD_RELOC_AARCH64_LD_LO19_PCREL:
+ case BFD_RELOC_AARCH64_MOVW_PREL_G0:
+ case BFD_RELOC_AARCH64_MOVW_PREL_G0_NC:
+ case BFD_RELOC_AARCH64_MOVW_PREL_G1:
+ case BFD_RELOC_AARCH64_MOVW_PREL_G1_NC:
+ case BFD_RELOC_AARCH64_MOVW_PREL_G2:
+ case BFD_RELOC_AARCH64_MOVW_PREL_G2_NC:
+ case BFD_RELOC_AARCH64_MOVW_PREL_G3:
+ if (bfd_link_pic (info)
+ && (input_section->flags & SEC_ALLOC) != 0
+ && (input_section->flags & SEC_READONLY) != 0
+ && !_bfd_elf_symbol_refs_local_p (h, info, 1))
+ {
+ int howto_index = bfd_r_type - BFD_RELOC_AARCH64_RELOC_START;
+
+ _bfd_error_handler
+ /* xgettext:c-format */
+ (_("%pB: relocation %s against symbol `%s' which may bind "
+ "externally can not be used when making a shared object; "
+ "recompile with -fPIC"),
+ input_bfd, elfNN_aarch64_howto_table[howto_index].name,
+ h->root.root.string);
+ bfd_set_error (bfd_error_bad_value);
+ return bfd_reloc_notsupported;
+ }
+ value = _bfd_aarch64_elf_resolve_relocation (input_bfd, bfd_r_type,
+ place, value,
+ signed_addend,
+ weak_undef_p);
+ break;
+
+ case BFD_RELOC_AARCH64_BRANCH19:
+ case BFD_RELOC_AARCH64_TSTBR14:
+ if (h && h->root.type == bfd_link_hash_undefined)
+ {
+ _bfd_error_handler
+ /* xgettext:c-format */
+ (_("%pB: conditional branch to undefined symbol `%s' "
+ "not allowed"), input_bfd, h->root.root.string);
+ bfd_set_error (bfd_error_bad_value);
+ return bfd_reloc_notsupported;
+ }
+ /* Fall through. */
+
+ case BFD_RELOC_AARCH64_16:
+#if ARCH_SIZE == 64
+ case BFD_RELOC_AARCH64_32:
+#endif
+ case BFD_RELOC_AARCH64_ADD_LO12:
+ case BFD_RELOC_AARCH64_LDST128_LO12:
+ case BFD_RELOC_AARCH64_LDST16_LO12:
+ case BFD_RELOC_AARCH64_LDST32_LO12:
+ case BFD_RELOC_AARCH64_LDST64_LO12:
+ case BFD_RELOC_AARCH64_LDST8_LO12:
+ case BFD_RELOC_AARCH64_MOVW_G0:
+ case BFD_RELOC_AARCH64_MOVW_G0_NC:
+ case BFD_RELOC_AARCH64_MOVW_G0_S:
+ case BFD_RELOC_AARCH64_MOVW_G1:
+ case BFD_RELOC_AARCH64_MOVW_G1_NC:
+ case BFD_RELOC_AARCH64_MOVW_G1_S:
+ case BFD_RELOC_AARCH64_MOVW_G2:
+ case BFD_RELOC_AARCH64_MOVW_G2_NC:
+ case BFD_RELOC_AARCH64_MOVW_G2_S:
+ case BFD_RELOC_AARCH64_MOVW_G3:
+ value = _bfd_aarch64_elf_resolve_relocation (input_bfd, bfd_r_type,
+ place, value,
+ signed_addend, weak_undef_p);
+ break;
+
+ case BFD_RELOC_AARCH64_ADR_GOT_PAGE:
+ case BFD_RELOC_AARCH64_GOT_LD_PREL19:
+ case BFD_RELOC_AARCH64_LD32_GOTPAGE_LO14:
+ case BFD_RELOC_AARCH64_LD32_GOT_LO12_NC:
+ case BFD_RELOC_AARCH64_LD64_GOTPAGE_LO15:
+ case BFD_RELOC_AARCH64_LD64_GOT_LO12_NC:
+ case BFD_RELOC_AARCH64_LD64_GOTOFF_LO15:
+ case BFD_RELOC_AARCH64_MOVW_GOTOFF_G0_NC:
+ case BFD_RELOC_AARCH64_MOVW_GOTOFF_G1:
+ if (globals->root.sgot == NULL)
+ BFD_ASSERT (h != NULL);
+
+ relative_reloc = false;
+ if (h != NULL)
+ {
+ bfd_vma addend = 0;
+
+ /* If a symbol is not dynamic and is not undefined weak, bind it
+ locally and generate a RELATIVE relocation under PIC mode.
+
+ NOTE: one symbol may be referenced by several relocations, we
+ should only generate one RELATIVE relocation for that symbol.
+ Therefore, check GOT offset mark first. */
+ if (h->dynindx == -1
+ && !h->forced_local
+ && h->root.type != bfd_link_hash_undefweak
+ && bfd_link_pic (info)
+ && !symbol_got_offset_mark_p (input_bfd, h, r_symndx))
+ relative_reloc = true;
+
+ value = aarch64_calculate_got_entry_vma (h, globals, info, value,
+ output_bfd,
+ unresolved_reloc_p);
+ /* Record the GOT entry address which will be used when generating
+ RELATIVE relocation. */
+ if (relative_reloc)
+ got_entry_addr = value;
+
+ if (aarch64_relocation_aginst_gp_p (bfd_r_type))
+ addend = (globals->root.sgot->output_section->vma
+ + globals->root.sgot->output_offset);
+ value = _bfd_aarch64_elf_resolve_relocation (input_bfd, bfd_r_type,
+ place, value,
+ addend, weak_undef_p);
+ }
+ else
+ {
+ bfd_vma addend = 0;
+ struct elf_aarch64_local_symbol *locals
+ = elf_aarch64_locals (input_bfd);
+
+ if (locals == NULL)
+ {
+ int howto_index = bfd_r_type - BFD_RELOC_AARCH64_RELOC_START;
+ _bfd_error_handler
+ /* xgettext:c-format */
+ (_("%pB: local symbol descriptor table be NULL when applying "
+ "relocation %s against local symbol"),
+ input_bfd, elfNN_aarch64_howto_table[howto_index].name);
+ abort ();
+ }
+
+ off = symbol_got_offset (input_bfd, h, r_symndx);
+ base_got = globals->root.sgot;
+ got_entry_addr = (base_got->output_section->vma
+ + base_got->output_offset + off);
+
+ if (!symbol_got_offset_mark_p (input_bfd, h, r_symndx))
+ {
+ bfd_put_64 (output_bfd, value, base_got->contents + off);
+
+ /* For local symbol, we have done absolute relocation in static
+ linking stage. While for shared library, we need to update the
+ content of GOT entry according to the shared object's runtime
+ base address. So, we need to generate a R_AARCH64_RELATIVE reloc
+ for dynamic linker. */
+ if (bfd_link_pic (info))
+ relative_reloc = true;
+
+ symbol_got_offset_mark (input_bfd, h, r_symndx);
+ }
+
+ /* Update the relocation value to GOT entry addr as we have transformed
+ the direct data access into indirect data access through GOT. */
+ value = got_entry_addr;
+
+ if (aarch64_relocation_aginst_gp_p (bfd_r_type))
+ addend = base_got->output_section->vma + base_got->output_offset;
+
+ value = _bfd_aarch64_elf_resolve_relocation (input_bfd, bfd_r_type,
+ place, value,
+ addend, weak_undef_p);
+ }
+
+ /* Emit relative relocations, but not if they are packed (DT_RELR). */
+ if (relative_reloc && !info->enable_dt_relr)
+ {
+ asection *s;
+ Elf_Internal_Rela outrel;
+
+ s = globals->root.srelgot;
+ if (s == NULL)
+ abort ();
+
+ outrel.r_offset = got_entry_addr;
+ outrel.r_info = ELFNN_R_INFO (0, AARCH64_R (RELATIVE));
+ outrel.r_addend = orig_value;
+ elf_append_rela (output_bfd, s, &outrel);
+ }
+ break;
+
+ case BFD_RELOC_AARCH64_TLSGD_ADD_LO12_NC:
+ case BFD_RELOC_AARCH64_TLSGD_ADR_PAGE21:
+ case BFD_RELOC_AARCH64_TLSGD_ADR_PREL21:
+ case BFD_RELOC_AARCH64_TLSIE_ADR_GOTTPREL_PAGE21:
+ case BFD_RELOC_AARCH64_TLSIE_LD32_GOTTPREL_LO12_NC:
+ case BFD_RELOC_AARCH64_TLSIE_LD64_GOTTPREL_LO12_NC:
+ case BFD_RELOC_AARCH64_TLSIE_LD_GOTTPREL_PREL19:
+ case BFD_RELOC_AARCH64_TLSLD_ADD_LO12_NC:
+ case BFD_RELOC_AARCH64_TLSLD_ADR_PAGE21:
+ case BFD_RELOC_AARCH64_TLSLD_ADR_PREL21:
+ if (globals->root.sgot == NULL)
+ return bfd_reloc_notsupported;
+
+ value = (symbol_got_offset (input_bfd, h, r_symndx)
+ + globals->root.sgot->output_section->vma
+ + globals->root.sgot->output_offset);
+
+ value = _bfd_aarch64_elf_resolve_relocation (input_bfd, bfd_r_type,
+ place, value,
+ 0, weak_undef_p);
+ *unresolved_reloc_p = false;
+ break;
+
+ case BFD_RELOC_AARCH64_TLSGD_MOVW_G0_NC:
+ case BFD_RELOC_AARCH64_TLSGD_MOVW_G1:
+ case BFD_RELOC_AARCH64_TLSIE_MOVW_GOTTPREL_G0_NC:
+ case BFD_RELOC_AARCH64_TLSIE_MOVW_GOTTPREL_G1:
+ if (globals->root.sgot == NULL)
+ return bfd_reloc_notsupported;
+
+ value = symbol_got_offset (input_bfd, h, r_symndx);
+ value = _bfd_aarch64_elf_resolve_relocation (input_bfd, bfd_r_type,
+ place, value,
+ 0, weak_undef_p);
+ *unresolved_reloc_p = false;
+ break;
+
+ case BFD_RELOC_AARCH64_TLSLD_ADD_DTPREL_HI12:
+ case BFD_RELOC_AARCH64_TLSLD_ADD_DTPREL_LO12:
+ case BFD_RELOC_AARCH64_TLSLD_ADD_DTPREL_LO12_NC:
+ case BFD_RELOC_AARCH64_TLSLD_LDST16_DTPREL_LO12:
+ case BFD_RELOC_AARCH64_TLSLD_LDST16_DTPREL_LO12_NC:
+ case BFD_RELOC_AARCH64_TLSLD_LDST32_DTPREL_LO12:
+ case BFD_RELOC_AARCH64_TLSLD_LDST32_DTPREL_LO12_NC:
+ case BFD_RELOC_AARCH64_TLSLD_LDST64_DTPREL_LO12:
+ case BFD_RELOC_AARCH64_TLSLD_LDST64_DTPREL_LO12_NC:
+ case BFD_RELOC_AARCH64_TLSLD_LDST8_DTPREL_LO12:
+ case BFD_RELOC_AARCH64_TLSLD_LDST8_DTPREL_LO12_NC:
+ case BFD_RELOC_AARCH64_TLSLD_MOVW_DTPREL_G0:
+ case BFD_RELOC_AARCH64_TLSLD_MOVW_DTPREL_G0_NC:
+ case BFD_RELOC_AARCH64_TLSLD_MOVW_DTPREL_G1:
+ case BFD_RELOC_AARCH64_TLSLD_MOVW_DTPREL_G1_NC:
+ case BFD_RELOC_AARCH64_TLSLD_MOVW_DTPREL_G2:
+ {
+ if (!(weak_undef_p || elf_hash_table (info)->tls_sec))
+ {
+ int howto_index = bfd_r_type - BFD_RELOC_AARCH64_RELOC_START;
+ _bfd_error_handler
+ /* xgettext:c-format */
+ (_("%pB: TLS relocation %s against undefined symbol `%s'"),
+ input_bfd, elfNN_aarch64_howto_table[howto_index].name,
+ h->root.root.string);
+ bfd_set_error (bfd_error_bad_value);
+ return bfd_reloc_notsupported;
+ }
+
+ bfd_vma def_value
+ = weak_undef_p ? 0 : signed_addend - dtpoff_base (info);
+ value = _bfd_aarch64_elf_resolve_relocation (input_bfd, bfd_r_type,
+ place, value,
+ def_value, weak_undef_p);
+ break;
+ }
+
+ case BFD_RELOC_AARCH64_TLSLE_ADD_TPREL_HI12:
+ case BFD_RELOC_AARCH64_TLSLE_ADD_TPREL_LO12:
+ case BFD_RELOC_AARCH64_TLSLE_ADD_TPREL_LO12_NC:
+ case BFD_RELOC_AARCH64_TLSLE_LDST16_TPREL_LO12:
+ case BFD_RELOC_AARCH64_TLSLE_LDST16_TPREL_LO12_NC:
+ case BFD_RELOC_AARCH64_TLSLE_LDST32_TPREL_LO12:
+ case BFD_RELOC_AARCH64_TLSLE_LDST32_TPREL_LO12_NC:
+ case BFD_RELOC_AARCH64_TLSLE_LDST64_TPREL_LO12:
+ case BFD_RELOC_AARCH64_TLSLE_LDST64_TPREL_LO12_NC:
+ case BFD_RELOC_AARCH64_TLSLE_LDST8_TPREL_LO12:
+ case BFD_RELOC_AARCH64_TLSLE_LDST8_TPREL_LO12_NC:
+ case BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G0:
+ case BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G0_NC:
+ case BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G1:
+ case BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G1_NC:
+ case BFD_RELOC_AARCH64_TLSLE_MOVW_TPREL_G2:
+ {
+ if (!(weak_undef_p || elf_hash_table (info)->tls_sec))
+ {
+ int howto_index = bfd_r_type - BFD_RELOC_AARCH64_RELOC_START;
+ _bfd_error_handler
+ /* xgettext:c-format */
+ (_("%pB: TLS relocation %s against undefined symbol `%s'"),
+ input_bfd, elfNN_aarch64_howto_table[howto_index].name,
+ h->root.root.string);
+ bfd_set_error (bfd_error_bad_value);
+ return bfd_reloc_notsupported;
+ }
+
+ bfd_vma def_value
+ = weak_undef_p ? 0 : signed_addend - tpoff_base (info);
+ value = _bfd_aarch64_elf_resolve_relocation (input_bfd, bfd_r_type,
+ place, value,
+ def_value, weak_undef_p);
+ *unresolved_reloc_p = false;
+ break;
+ }
+
+ case BFD_RELOC_AARCH64_TLSDESC_ADD_LO12:
+ case BFD_RELOC_AARCH64_TLSDESC_ADR_PAGE21:
+ case BFD_RELOC_AARCH64_TLSDESC_ADR_PREL21:
+ case BFD_RELOC_AARCH64_TLSDESC_LD32_LO12_NC:
+ case BFD_RELOC_AARCH64_TLSDESC_LD64_LO12:
+ case BFD_RELOC_AARCH64_TLSDESC_LD_PREL19:
+ if (globals->root.sgot == NULL)
+ return bfd_reloc_notsupported;
+ value = (symbol_tlsdesc_got_offset (input_bfd, h, r_symndx)
+ + globals->root.sgotplt->output_section->vma
+ + globals->root.sgotplt->output_offset
+ + globals->sgotplt_jump_table_size);
+
+ value = _bfd_aarch64_elf_resolve_relocation (input_bfd, bfd_r_type,
+ place, value,
+ 0, weak_undef_p);
+ *unresolved_reloc_p = false;
+ break;
+
+ case BFD_RELOC_AARCH64_TLSDESC_OFF_G0_NC:
+ case BFD_RELOC_AARCH64_TLSDESC_OFF_G1:
+ if (globals->root.sgot == NULL)
+ return bfd_reloc_notsupported;
+
+ value = (symbol_tlsdesc_got_offset (input_bfd, h, r_symndx)
+ + globals->root.sgotplt->output_section->vma
+ + globals->root.sgotplt->output_offset
+ + globals->sgotplt_jump_table_size);
+
+ value -= (globals->root.sgot->output_section->vma
+ + globals->root.sgot->output_offset);
+
+ value = _bfd_aarch64_elf_resolve_relocation (input_bfd, bfd_r_type,
+ place, value,
+ 0, weak_undef_p);
+ *unresolved_reloc_p = false;
+ break;
+
+ default:
+ return bfd_reloc_notsupported;
+ }
+
+ if (saved_addend)
+ *saved_addend = value;
+
+ /* Only apply the final relocation in a sequence. */
+ if (save_addend)
+ return bfd_reloc_continue;
+
+ return _bfd_aarch64_elf_put_addend (input_bfd, hit_data, bfd_r_type,
+ howto, value);
+}
+
+/* LP64 and ILP32 operates on x- and w-registers respectively.
+ Next definitions take into account the difference between
+ corresponding machine codes. R means x-register if the target
+ arch is LP64, and w-register if the target is ILP32. */
+
+#if ARCH_SIZE == 64
+# define add_R0_R0 (0x91000000)
+# define add_R0_R0_R1 (0x8b000020)
+# define add_R0_R1 (0x91400020)
+# define ldr_R0 (0x58000000)
+# define ldr_R0_mask(i) (i & 0xffffffe0)
+# define ldr_R0_x0 (0xf9400000)
+# define ldr_hw_R0 (0xf2a00000)
+# define movk_R0 (0xf2800000)
+# define movz_R0 (0xd2a00000)
+# define movz_hw_R0 (0xd2c00000)
+#else /*ARCH_SIZE == 32 */
+# define add_R0_R0 (0x11000000)
+# define add_R0_R0_R1 (0x0b000020)
+# define add_R0_R1 (0x11400020)
+# define ldr_R0 (0x18000000)
+# define ldr_R0_mask(i) (i & 0xbfffffe0)
+# define ldr_R0_x0 (0xb9400000)
+# define ldr_hw_R0 (0x72a00000)
+# define movk_R0 (0x72800000)
+# define movz_R0 (0x52a00000)
+# define movz_hw_R0 (0x52c00000)
+#endif
+
+/* Structure to hold payload for _bfd_aarch64_erratum_843419_clear_stub,
+ it is used to identify the stub information to reset. */
+
+struct erratum_843419_branch_to_stub_clear_data
+{
+ bfd_vma adrp_offset;
+ asection *output_section;
+};
+
+/* Clear the erratum information for GEN_ENTRY if the ADRP_OFFSET and
+ section inside IN_ARG matches. The clearing is done by setting the
+ stub_type to none. */
+
+static bool
+_bfd_aarch64_erratum_843419_clear_stub (struct bfd_hash_entry *gen_entry,
+ void *in_arg)
+{
+ struct elf_aarch64_stub_hash_entry *stub_entry
+ = (struct elf_aarch64_stub_hash_entry *) gen_entry;
+ struct erratum_843419_branch_to_stub_clear_data *data
+ = (struct erratum_843419_branch_to_stub_clear_data *) in_arg;
+
+ if (stub_entry->target_section != data->output_section
+ || stub_entry->stub_type != aarch64_stub_erratum_843419_veneer
+ || stub_entry->adrp_offset != data->adrp_offset)
+ return true;
+
+ /* Change the stub type instead of removing the entry, removing from the hash
+ table would be slower and we have already reserved the memory for the entry
+ so there wouldn't be much gain. Changing the stub also keeps around a
+ record of what was there before. */
+ stub_entry->stub_type = aarch64_stub_none;
+
+ /* We're done and there could have been only one matching stub at that
+ particular offset, so abort further traversal. */
+ return false;
+}
+
+/* TLS Relaxations may relax an adrp sequence that matches the erratum 843419
+ sequence. In this case the erratum no longer applies and we need to remove
+ the entry from the pending stub generation. This clears matching adrp insn
+ at ADRP_OFFSET in INPUT_SECTION in the stub table defined in GLOBALS. */
+
+static void
+clear_erratum_843419_entry (struct elf_aarch64_link_hash_table *globals,
+ bfd_vma adrp_offset, asection *input_section)
+{
+ if (globals->fix_erratum_843419 & ERRAT_ADRP)
+ {
+ struct erratum_843419_branch_to_stub_clear_data data;
+ data.adrp_offset = adrp_offset;
+ data.output_section = input_section;
+
+ bfd_hash_traverse (&globals->stub_hash_table,
+ _bfd_aarch64_erratum_843419_clear_stub, &data);
+ }
+}
+
+/* Handle TLS relaxations. Relaxing is possible for symbols that use
+ R_AARCH64_TLSDESC_ADR_{PAGE, LD64_LO12_NC, ADD_LO12_NC} during a static
+ link.
+
+ Return bfd_reloc_ok if we're done, bfd_reloc_continue if the caller
+ is to then call final_link_relocate. Return other values in the
+ case of error. */
+
+static bfd_reloc_status_type
+elfNN_aarch64_tls_relax (struct elf_aarch64_link_hash_table *globals,
+ bfd *input_bfd, asection *input_section,
+ bfd_byte *contents, Elf_Internal_Rela *rel,
+ struct elf_link_hash_entry *h,
+ struct bfd_link_info *info)
+{
+ bool local_exec = bfd_link_executable (info)
+ && SYMBOL_REFERENCES_LOCAL (info, h);
+ unsigned int r_type = ELFNN_R_TYPE (rel->r_info);
+ unsigned long insn;
+
+ BFD_ASSERT (globals && input_bfd && contents && rel);
+
+ switch (elfNN_aarch64_bfd_reloc_from_type (input_bfd, r_type))
+ {
+ case BFD_RELOC_AARCH64_TLSDESC_ADR_PAGE21:
+ case BFD_RELOC_AARCH64_TLSGD_ADR_PAGE21:
+ if (local_exec)
+ {
+ /* GD->LE relaxation:
+ adrp x0, :tlsgd:var => movz R0, :tprel_g1:var
+ or
+ adrp x0, :tlsdesc:var => movz R0, :tprel_g1:var
+
+ Where R is x for LP64, and w for ILP32. */
+ bfd_putl32 (movz_R0, contents + rel->r_offset);
+ /* We have relaxed the adrp into a mov, we may have to clear any
+ pending erratum fixes. */
+ clear_erratum_843419_entry (globals, rel->r_offset, input_section);
+ return bfd_reloc_continue;
+ }
+ else
+ {
+ /* GD->IE relaxation:
+ adrp x0, :tlsgd:var => adrp x0, :gottprel:var
+ or
+ adrp x0, :tlsdesc:var => adrp x0, :gottprel:var
+ */
+ return bfd_reloc_continue;
+ }
+
+ case BFD_RELOC_AARCH64_TLSDESC_ADR_PREL21:
+ BFD_ASSERT (0);
+ break;
+
+ case BFD_RELOC_AARCH64_TLSDESC_LD_PREL19:
+ if (local_exec)
+ {
+ /* Tiny TLSDESC->LE relaxation:
+ ldr x1, :tlsdesc:var => movz R0, #:tprel_g1:var
+ adr x0, :tlsdesc:var => movk R0, #:tprel_g0_nc:var
+ .tlsdesccall var
+ blr x1 => nop
+
+ Where R is x for LP64, and w for ILP32. */
+ BFD_ASSERT (ELFNN_R_TYPE (rel[1].r_info) == AARCH64_R (TLSDESC_ADR_PREL21));
+ BFD_ASSERT (ELFNN_R_TYPE (rel[2].r_info) == AARCH64_R (TLSDESC_CALL));
+
+ rel[1].r_info = ELFNN_R_INFO (ELFNN_R_SYM (rel->r_info),
+ AARCH64_R (TLSLE_MOVW_TPREL_G0_NC));
+ rel[2].r_info = ELFNN_R_INFO (STN_UNDEF, R_AARCH64_NONE);
+
+ bfd_putl32 (movz_R0, contents + rel->r_offset);
+ bfd_putl32 (movk_R0, contents + rel->r_offset + 4);
+ bfd_putl32 (INSN_NOP, contents + rel->r_offset + 8);
+ return bfd_reloc_continue;
+ }
+ else
+ {
+ /* Tiny TLSDESC->IE relaxation:
+ ldr x1, :tlsdesc:var => ldr x0, :gottprel:var
+ adr x0, :tlsdesc:var => nop
+ .tlsdesccall var
+ blr x1 => nop
+ */
+ BFD_ASSERT (ELFNN_R_TYPE (rel[1].r_info) == AARCH64_R (TLSDESC_ADR_PREL21));
+ BFD_ASSERT (ELFNN_R_TYPE (rel[2].r_info) == AARCH64_R (TLSDESC_CALL));
+
+ rel[1].r_info = ELFNN_R_INFO (STN_UNDEF, R_AARCH64_NONE);
+ rel[2].r_info = ELFNN_R_INFO (STN_UNDEF, R_AARCH64_NONE);
+
+ bfd_putl32 (ldr_R0, contents + rel->r_offset);
+ bfd_putl32 (INSN_NOP, contents + rel->r_offset + 4);
+ bfd_putl32 (INSN_NOP, contents + rel->r_offset + 8);
+ return bfd_reloc_continue;
+ }
+
+ case BFD_RELOC_AARCH64_TLSGD_ADR_PREL21:
+ if (local_exec)
+ {
+ /* Tiny GD->LE relaxation:
+ adr x0, :tlsgd:var => mrs x1, tpidr_el0
+ bl __tls_get_addr => add R0, R1, #:tprel_hi12:x, lsl #12
+ nop => add R0, R0, #:tprel_lo12_nc:x
+
+ Where R is x for LP64, and x for Ilp32. */
+
+ /* First kill the tls_get_addr reloc on the bl instruction. */
+ BFD_ASSERT (rel->r_offset + 4 == rel[1].r_offset);
+
+ bfd_putl32 (0xd53bd041, contents + rel->r_offset + 0);
+ bfd_putl32 (add_R0_R1, contents + rel->r_offset + 4);
+ bfd_putl32 (add_R0_R0, contents + rel->r_offset + 8);
+
+ rel[1].r_info = ELFNN_R_INFO (ELFNN_R_SYM (rel->r_info),
+ AARCH64_R (TLSLE_ADD_TPREL_LO12_NC));
+ rel[1].r_offset = rel->r_offset + 8;
+
+ /* Move the current relocation to the second instruction in
+ the sequence. */
+ rel->r_offset += 4;
+ rel->r_info = ELFNN_R_INFO (ELFNN_R_SYM (rel->r_info),
+ AARCH64_R (TLSLE_ADD_TPREL_HI12));
+ return bfd_reloc_continue;
+ }
+ else
+ {
+ /* Tiny GD->IE relaxation:
+ adr x0, :tlsgd:var => ldr R0, :gottprel:var
+ bl __tls_get_addr => mrs x1, tpidr_el0
+ nop => add R0, R0, R1
+
+ Where R is x for LP64, and w for Ilp32. */
+
+ /* First kill the tls_get_addr reloc on the bl instruction. */
+ BFD_ASSERT (rel->r_offset + 4 == rel[1].r_offset);
+ rel[1].r_info = ELFNN_R_INFO (STN_UNDEF, R_AARCH64_NONE);
+
+ bfd_putl32 (ldr_R0, contents + rel->r_offset);
+ bfd_putl32 (0xd53bd041, contents + rel->r_offset + 4);
+ bfd_putl32 (add_R0_R0_R1, contents + rel->r_offset + 8);
+ return bfd_reloc_continue;
+ }
+
+#if ARCH_SIZE == 64
+ case BFD_RELOC_AARCH64_TLSGD_MOVW_G1:
+ BFD_ASSERT (ELFNN_R_TYPE (rel[1].r_info) == AARCH64_R (TLSGD_MOVW_G0_NC));
+ BFD_ASSERT (rel->r_offset + 12 == rel[2].r_offset);
+ BFD_ASSERT (ELFNN_R_TYPE (rel[2].r_info) == AARCH64_R (CALL26));
+
+ if (local_exec)
+ {
+ /* Large GD->LE relaxation:
+ movz x0, #:tlsgd_g1:var => movz x0, #:tprel_g2:var, lsl #32
+ movk x0, #:tlsgd_g0_nc:var => movk x0, #:tprel_g1_nc:var, lsl #16
+ add x0, gp, x0 => movk x0, #:tprel_g0_nc:var
+ bl __tls_get_addr => mrs x1, tpidr_el0
+ nop => add x0, x0, x1
+ */
+ rel[2].r_info = ELFNN_R_INFO (ELFNN_R_SYM (rel->r_info),
+ AARCH64_R (TLSLE_MOVW_TPREL_G0_NC));
+ rel[2].r_offset = rel->r_offset + 8;
+
+ bfd_putl32 (movz_hw_R0, contents + rel->r_offset + 0);
+ bfd_putl32 (ldr_hw_R0, contents + rel->r_offset + 4);
+ bfd_putl32 (movk_R0, contents + rel->r_offset + 8);
+ bfd_putl32 (0xd53bd041, contents + rel->r_offset + 12);
+ bfd_putl32 (add_R0_R0_R1, contents + rel->r_offset + 16);
+ }
+ else
+ {
+ /* Large GD->IE relaxation:
+ movz x0, #:tlsgd_g1:var => movz x0, #:gottprel_g1:var, lsl #16
+ movk x0, #:tlsgd_g0_nc:var => movk x0, #:gottprel_g0_nc:var
+ add x0, gp, x0 => ldr x0, [gp, x0]
+ bl __tls_get_addr => mrs x1, tpidr_el0
+ nop => add x0, x0, x1
+ */
+ rel[2].r_info = ELFNN_R_INFO (STN_UNDEF, R_AARCH64_NONE);
+ bfd_putl32 (0xd2a80000, contents + rel->r_offset + 0);
+ bfd_putl32 (ldr_R0, contents + rel->r_offset + 8);
+ bfd_putl32 (0xd53bd041, contents + rel->r_offset + 12);
+ bfd_putl32 (add_R0_R0_R1, contents + rel->r_offset + 16);
+ }
+ return bfd_reloc_continue;
+
+ case BFD_RELOC_AARCH64_TLSGD_MOVW_G0_NC:
+ return bfd_reloc_continue;
+#endif
+
+ case BFD_RELOC_AARCH64_TLSIE_LD_GOTTPREL_PREL19:
+ return bfd_reloc_continue;
+
+ case BFD_RELOC_AARCH64_TLSDESC_LDNN_LO12_NC:
+ if (local_exec)
+ {
+ /* GD->LE relaxation:
+ ldr xd, [x0, #:tlsdesc_lo12:var] => movk x0, :tprel_g0_nc:var
+
+ Where R is x for lp64 mode, and w for ILP32 mode. */
+ bfd_putl32 (movk_R0, contents + rel->r_offset);
+ return bfd_reloc_continue;
+ }
+ else
+ {
+ /* GD->IE relaxation:
+ ldr xd, [x0, #:tlsdesc_lo12:var] => ldr R0, [x0, #:gottprel_lo12:var]
+
+ Where R is x for lp64 mode, and w for ILP32 mode. */
+ insn = bfd_getl32 (contents + rel->r_offset);
+ bfd_putl32 (ldr_R0_mask (insn), contents + rel->r_offset);
+ return bfd_reloc_continue;
+ }
+
+ case BFD_RELOC_AARCH64_TLSGD_ADD_LO12_NC:
+ if (local_exec)
+ {
+ /* GD->LE relaxation
+ add x0, #:tlsgd_lo12:var => movk R0, :tprel_g0_nc:var
+ bl __tls_get_addr => mrs x1, tpidr_el0
+ nop => add R0, R1, R0
+
+ Where R is x for lp64 mode, and w for ILP32 mode. */
+
+ /* First kill the tls_get_addr reloc on the bl instruction. */
+ BFD_ASSERT (rel->r_offset + 4 == rel[1].r_offset);
+ rel[1].r_info = ELFNN_R_INFO (STN_UNDEF, R_AARCH64_NONE);
+
+ bfd_putl32 (movk_R0, contents + rel->r_offset);
+ bfd_putl32 (0xd53bd041, contents + rel->r_offset + 4);
+ bfd_putl32 (add_R0_R0_R1, contents + rel->r_offset + 8);
+ return bfd_reloc_continue;
+ }
+ else
+ {
+ /* GD->IE relaxation
+ ADD x0, #:tlsgd_lo12:var => ldr R0, [x0, #:gottprel_lo12:var]
+ BL __tls_get_addr => mrs x1, tpidr_el0
+ R_AARCH64_CALL26
+ NOP => add R0, R1, R0
+
+ Where R is x for lp64 mode, and w for ilp32 mode. */
+
+ BFD_ASSERT (ELFNN_R_TYPE (rel[1].r_info) == AARCH64_R (CALL26));
+
+ /* Remove the relocation on the BL instruction. */
+ rel[1].r_info = ELFNN_R_INFO (STN_UNDEF, R_AARCH64_NONE);
+
+ /* We choose to fixup the BL and NOP instructions using the
+ offset from the second relocation to allow flexibility in
+ scheduling instructions between the ADD and BL. */
+ bfd_putl32 (ldr_R0_x0, contents + rel->r_offset);
+ bfd_putl32 (0xd53bd041, contents + rel[1].r_offset);
+ bfd_putl32 (add_R0_R0_R1, contents + rel[1].r_offset + 4);
+ return bfd_reloc_continue;
+ }
+
+ case BFD_RELOC_AARCH64_TLSDESC_ADD:
+ case BFD_RELOC_AARCH64_TLSDESC_ADD_LO12:
+ case BFD_RELOC_AARCH64_TLSDESC_CALL:
+ /* GD->IE/LE relaxation:
+ add x0, x0, #:tlsdesc_lo12:var => nop
+ blr xd => nop
+ */
+ bfd_putl32 (INSN_NOP, contents + rel->r_offset);
+ return bfd_reloc_ok;
+
+ case BFD_RELOC_AARCH64_TLSDESC_LDR:
+ if (local_exec)
+ {
+ /* GD->LE relaxation:
+ ldr xd, [gp, xn] => movk R0, #:tprel_g0_nc:var
+
+ Where R is x for lp64 mode, and w for ILP32 mode. */
+ bfd_putl32 (movk_R0, contents + rel->r_offset);
+ return bfd_reloc_continue;
+ }
+ else
+ {
+ /* GD->IE relaxation:
+ ldr xd, [gp, xn] => ldr R0, [gp, xn]
+
+ Where R is x for lp64 mode, and w for ILP32 mode. */
+ insn = bfd_getl32 (contents + rel->r_offset);
+ bfd_putl32 (ldr_R0_mask (insn), contents + rel->r_offset);
+ return bfd_reloc_ok;
+ }
+
+ case BFD_RELOC_AARCH64_TLSDESC_OFF_G0_NC:
+ /* GD->LE relaxation:
+ movk xd, #:tlsdesc_off_g0_nc:var => movk R0, #:tprel_g1_nc:var, lsl #16
+ GD->IE relaxation:
+ movk xd, #:tlsdesc_off_g0_nc:var => movk Rd, #:gottprel_g0_nc:var
+
+ Where R is x for lp64 mode, and w for ILP32 mode. */
+ if (local_exec)
+ bfd_putl32 (ldr_hw_R0, contents + rel->r_offset);
+ return bfd_reloc_continue;
+
+ case BFD_RELOC_AARCH64_TLSDESC_OFF_G1:
+ if (local_exec)
+ {
+ /* GD->LE relaxation:
+ movz xd, #:tlsdesc_off_g1:var => movz R0, #:tprel_g2:var, lsl #32
+
+ Where R is x for lp64 mode, and w for ILP32 mode. */
+ bfd_putl32 (movz_hw_R0, contents + rel->r_offset);
+ return bfd_reloc_continue;
+ }
+ else
+ {
+ /* GD->IE relaxation:
+ movz xd, #:tlsdesc_off_g1:var => movz Rd, #:gottprel_g1:var, lsl #16
+
+ Where R is x for lp64 mode, and w for ILP32 mode. */
+ insn = bfd_getl32 (contents + rel->r_offset);
+ bfd_putl32 (movz_R0 | (insn & 0x1f), contents + rel->r_offset);
+ return bfd_reloc_continue;
+ }
+
+ case BFD_RELOC_AARCH64_TLSIE_ADR_GOTTPREL_PAGE21:
+ /* IE->LE relaxation:
+ adrp xd, :gottprel:var => movz Rd, :tprel_g1:var
+
+ Where R is x for lp64 mode, and w for ILP32 mode. */
+ if (local_exec)
+ {
+ insn = bfd_getl32 (contents + rel->r_offset);
+ bfd_putl32 (movz_R0 | (insn & 0x1f), contents + rel->r_offset);
+ /* We have relaxed the adrp into a mov, we may have to clear any
+ pending erratum fixes. */
+ clear_erratum_843419_entry (globals, rel->r_offset, input_section);
+ }
+ return bfd_reloc_continue;
+
+ case BFD_RELOC_AARCH64_TLSIE_LDNN_GOTTPREL_LO12_NC:
+ /* IE->LE relaxation:
+ ldr xd, [xm, #:gottprel_lo12:var] => movk Rd, :tprel_g0_nc:var
+
+ Where R is x for lp64 mode, and w for ILP32 mode. */
+ if (local_exec)
+ {
+ insn = bfd_getl32 (contents + rel->r_offset);
+ bfd_putl32 (movk_R0 | (insn & 0x1f), contents + rel->r_offset);
+ }
+ return bfd_reloc_continue;
+
+ case BFD_RELOC_AARCH64_TLSLD_ADR_PREL21:
+ /* LD->LE relaxation (tiny):
+ adr x0, :tlsldm:x => mrs x0, tpidr_el0
+ bl __tls_get_addr => add R0, R0, TCB_SIZE
+
+ Where R is x for lp64 mode, and w for ilp32 mode. */
+ if (local_exec)
+ {
+ BFD_ASSERT (rel->r_offset + 4 == rel[1].r_offset);
+ BFD_ASSERT (ELFNN_R_TYPE (rel[1].r_info) == AARCH64_R (CALL26));
+ /* No need of CALL26 relocation for tls_get_addr. */
+ rel[1].r_info = ELFNN_R_INFO (STN_UNDEF, R_AARCH64_NONE);
+ bfd_putl32 (0xd53bd040, contents + rel->r_offset + 0);
+ bfd_putl32 (add_R0_R0 | (TCB_SIZE << 10),
+ contents + rel->r_offset + 4);
+ return bfd_reloc_ok;
+ }
+ return bfd_reloc_continue;
+
+ case BFD_RELOC_AARCH64_TLSLD_ADR_PAGE21:
+ /* LD->LE relaxation (small):
+ adrp x0, :tlsldm:x => mrs x0, tpidr_el0
+ */
+ if (local_exec)
+ {
+ bfd_putl32 (0xd53bd040, contents + rel->r_offset);
+ return bfd_reloc_ok;
+ }
+ return bfd_reloc_continue;
+
+ case BFD_RELOC_AARCH64_TLSLD_ADD_LO12_NC:
+ /* LD->LE relaxation (small):
+ add x0, #:tlsldm_lo12:x => add R0, R0, TCB_SIZE
+ bl __tls_get_addr => nop
+
+ Where R is x for lp64 mode, and w for ilp32 mode. */
+ if (local_exec)
+ {
+ BFD_ASSERT (rel->r_offset + 4 == rel[1].r_offset);
+ BFD_ASSERT (ELFNN_R_TYPE (rel[1].r_info) == AARCH64_R (CALL26));
+ /* No need of CALL26 relocation for tls_get_addr. */
+ rel[1].r_info = ELFNN_R_INFO (STN_UNDEF, R_AARCH64_NONE);
+ bfd_putl32 (add_R0_R0 | (TCB_SIZE << 10),
+ contents + rel->r_offset + 0);
+ bfd_putl32 (INSN_NOP, contents + rel->r_offset + 4);
+ return bfd_reloc_ok;
+ }
+ return bfd_reloc_continue;
+
+ default:
+ return bfd_reloc_continue;
+ }
+
+ return bfd_reloc_ok;
+}
+
+/* Relocate an AArch64 ELF section. */
+
+static int
+elfNN_aarch64_relocate_section (bfd *output_bfd,
+ struct bfd_link_info *info,
+ bfd *input_bfd,
+ asection *input_section,
+ bfd_byte *contents,
+ Elf_Internal_Rela *relocs,
+ Elf_Internal_Sym *local_syms,
+ asection **local_sections)
+{
+ Elf_Internal_Shdr *symtab_hdr;
+ struct elf_link_hash_entry **sym_hashes;
+ Elf_Internal_Rela *rel;
+ Elf_Internal_Rela *relend;
+ const char *name;
+ struct elf_aarch64_link_hash_table *globals;
+ bool save_addend = false;
+ bfd_vma addend = 0;
+
+ globals = elf_aarch64_hash_table (info);
+
+ symtab_hdr = &elf_symtab_hdr (input_bfd);
+ sym_hashes = elf_sym_hashes (input_bfd);
+
+ rel = relocs;
+ relend = relocs + input_section->reloc_count;
+ for (; rel < relend; rel++)
+ {
+ unsigned int r_type;
+ bfd_reloc_code_real_type bfd_r_type;
+ bfd_reloc_code_real_type relaxed_bfd_r_type;
+ reloc_howto_type *howto;
+ unsigned long r_symndx;
+ Elf_Internal_Sym *sym;
+ asection *sec;
+ struct elf_link_hash_entry *h;
+ bfd_vma relocation;
+ bfd_reloc_status_type r;
+ arelent bfd_reloc;
+ char sym_type;
+ bool unresolved_reloc = false;
+ char *error_message = NULL;
+
+ r_symndx = ELFNN_R_SYM (rel->r_info);
+ r_type = ELFNN_R_TYPE (rel->r_info);
+
+ bfd_reloc.howto = elfNN_aarch64_howto_from_type (input_bfd, r_type);
+ howto = bfd_reloc.howto;
+
+ if (howto == NULL)
+ return _bfd_unrecognized_reloc (input_bfd, input_section, r_type);
+
+ bfd_r_type = elfNN_aarch64_bfd_reloc_from_howto (howto);
+
+ h = NULL;
+ sym = NULL;
+ sec = NULL;
+
+ if (r_symndx < symtab_hdr->sh_info)
+ {
+ sym = local_syms + r_symndx;
+ sym_type = ELFNN_ST_TYPE (sym->st_info);
+ sec = local_sections[r_symndx];
+
+ /* An object file might have a reference to a local
+ undefined symbol. This is a daft object file, but we
+ should at least do something about it. NONE and NULL
+ relocations do not use the symbol and are explicitly
+ allowed to use an undefined one, so allow those.
+ Likewise for relocations against STN_UNDEF. */
+ if (r_type != R_AARCH64_NONE && r_type != R_AARCH64_NULL
+ && r_symndx != STN_UNDEF
+ && bfd_is_und_section (sec)
+ && ELF_ST_BIND (sym->st_info) != STB_WEAK)
+ (*info->callbacks->undefined_symbol)
+ (info, bfd_elf_string_from_elf_section
+ (input_bfd, symtab_hdr->sh_link, sym->st_name),
+ input_bfd, input_section, rel->r_offset, true);
+
+ relocation = _bfd_elf_rela_local_sym (output_bfd, sym, &sec, rel);
+
+ /* Relocate against local STT_GNU_IFUNC symbol. */
+ if (!bfd_link_relocatable (info)
+ && ELF_ST_TYPE (sym->st_info) == STT_GNU_IFUNC)
+ {
+ h = elfNN_aarch64_get_local_sym_hash (globals, input_bfd,
+ rel, false);
+ if (h == NULL)
+ abort ();
+
+ /* Set STT_GNU_IFUNC symbol value. */
+ h->root.u.def.value = sym->st_value;
+ h->root.u.def.section = sec;
+ }
+ }
+ else
+ {
+ bool warned, ignored;
+
+ RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
+ r_symndx, symtab_hdr, sym_hashes,
+ h, sec, relocation,
+ unresolved_reloc, warned, ignored);
+
+ sym_type = h->type;
+ }
+
+ if (sec != NULL && discarded_section (sec))
+ RELOC_AGAINST_DISCARDED_SECTION (info, input_bfd, input_section,
+ rel, 1, relend, howto, 0, contents);
+
+ if (bfd_link_relocatable (info))
+ continue;
+
+ if (h != NULL)
+ name = h->root.root.string;
+ else
+ {
+ name = (bfd_elf_string_from_elf_section
+ (input_bfd, symtab_hdr->sh_link, sym->st_name));
+ if (name == NULL || *name == '\0')
+ name = bfd_section_name (sec);
+ }
+
+ if (r_symndx != 0
+ && r_type != R_AARCH64_NONE
+ && r_type != R_AARCH64_NULL
+ && (h == NULL
+ || h->root.type == bfd_link_hash_defined
+ || h->root.type == bfd_link_hash_defweak)
+ && IS_AARCH64_TLS_RELOC (bfd_r_type) != (sym_type == STT_TLS))
+ {
+ _bfd_error_handler
+ ((sym_type == STT_TLS
+ /* xgettext:c-format */
+ ? _("%pB(%pA+%#" PRIx64 "): %s used with TLS symbol %s")
+ /* xgettext:c-format */
+ : _("%pB(%pA+%#" PRIx64 "): %s used with non-TLS symbol %s")),
+ input_bfd,
+ input_section, (uint64_t) rel->r_offset, howto->name, name);
+ }
+
+ /* We relax only if we can see that there can be a valid transition
+ from a reloc type to another.
+ We call elfNN_aarch64_final_link_relocate unless we're completely
+ done, i.e., the relaxation produced the final output we want. */
+
+ relaxed_bfd_r_type = aarch64_tls_transition (input_bfd, info, r_type,
+ h, r_symndx);
+ if (relaxed_bfd_r_type != bfd_r_type)
+ {
+ bfd_r_type = relaxed_bfd_r_type;
+ howto = elfNN_aarch64_howto_from_bfd_reloc (bfd_r_type);
+ BFD_ASSERT (howto != NULL);
+ r_type = howto->type;
+ r = elfNN_aarch64_tls_relax (globals, input_bfd, input_section,
+ contents, rel, h, info);
+ unresolved_reloc = 0;
+ }
+ else
+ r = bfd_reloc_continue;
+
+ /* There may be multiple consecutive relocations for the
+ same offset. In that case we are supposed to treat the
+ output of each relocation as the addend for the next. */
+ if (rel + 1 < relend
+ && rel->r_offset == rel[1].r_offset
+ && ELFNN_R_TYPE (rel[1].r_info) != R_AARCH64_NONE
+ && ELFNN_R_TYPE (rel[1].r_info) != R_AARCH64_NULL)
+ save_addend = true;
+ else
+ save_addend = false;
+
+ if (r == bfd_reloc_continue)
+ r = elfNN_aarch64_final_link_relocate (howto, input_bfd, output_bfd,
+ input_section, contents, rel,
+ relocation, info, sec,
+ h, &unresolved_reloc,
+ save_addend, &addend, sym);
+
+ switch (elfNN_aarch64_bfd_reloc_from_type (input_bfd, r_type))
+ {
+ case BFD_RELOC_AARCH64_TLSGD_ADD_LO12_NC:
+ case BFD_RELOC_AARCH64_TLSGD_ADR_PAGE21:
+ case BFD_RELOC_AARCH64_TLSGD_ADR_PREL21:
+ case BFD_RELOC_AARCH64_TLSGD_MOVW_G0_NC:
+ case BFD_RELOC_AARCH64_TLSGD_MOVW_G1:
+ case BFD_RELOC_AARCH64_TLSLD_ADD_LO12_NC:
+ case BFD_RELOC_AARCH64_TLSLD_ADR_PAGE21:
+ case BFD_RELOC_AARCH64_TLSLD_ADR_PREL21:
+ if (! symbol_got_offset_mark_p (input_bfd, h, r_symndx))
+ {
+ bool need_relocs = false;
+ bfd_byte *loc;
+ int indx;
+ bfd_vma off;
+
+ off = symbol_got_offset (input_bfd, h, r_symndx);
+ indx = h && h->dynindx != -1 ? h->dynindx : 0;
+
+ need_relocs =
+ (!bfd_link_executable (info) || indx != 0) &&
+ (h == NULL
+ || ELF_ST_VISIBILITY (h->other) == STV_DEFAULT
+ || h->root.type != bfd_link_hash_undefweak);
+
+ BFD_ASSERT (globals->root.srelgot != NULL);
+
+ if (need_relocs)
+ {
+ Elf_Internal_Rela rela;
+ rela.r_info = ELFNN_R_INFO (indx, AARCH64_R (TLS_DTPMOD));
+ rela.r_addend = 0;
+ rela.r_offset = globals->root.sgot->output_section->vma +
+ globals->root.sgot->output_offset + off;
+
+
+ loc = globals->root.srelgot->contents;
+ loc += globals->root.srelgot->reloc_count++
+ * RELOC_SIZE (htab);
+ bfd_elfNN_swap_reloca_out (output_bfd, &rela, loc);
+
+ bfd_reloc_code_real_type real_type =
+ elfNN_aarch64_bfd_reloc_from_type (input_bfd, r_type);
+
+ if (real_type == BFD_RELOC_AARCH64_TLSLD_ADR_PREL21
+ || real_type == BFD_RELOC_AARCH64_TLSLD_ADR_PAGE21
+ || real_type == BFD_RELOC_AARCH64_TLSLD_ADD_LO12_NC)
+ {
+ /* For local dynamic, don't generate DTPREL in any case.
+ Initialize the DTPREL slot into zero, so we get module
+ base address when invoke runtime TLS resolver. */
+ bfd_put_NN (output_bfd, 0,
+ globals->root.sgot->contents + off
+ + GOT_ENTRY_SIZE);
+ }
+ else if (indx == 0)
+ {
+ bfd_put_NN (output_bfd,
+ relocation - dtpoff_base (info),
+ globals->root.sgot->contents + off
+ + GOT_ENTRY_SIZE);
+ }
+ else
+ {
+ /* This TLS symbol is global. We emit a
+ relocation to fixup the tls offset at load
+ time. */
+ rela.r_info =
+ ELFNN_R_INFO (indx, AARCH64_R (TLS_DTPREL));
+ rela.r_addend = 0;
+ rela.r_offset =
+ (globals->root.sgot->output_section->vma
+ + globals->root.sgot->output_offset + off
+ + GOT_ENTRY_SIZE);
+
+ loc = globals->root.srelgot->contents;
+ loc += globals->root.srelgot->reloc_count++
+ * RELOC_SIZE (globals);
+ bfd_elfNN_swap_reloca_out (output_bfd, &rela, loc);
+ bfd_put_NN (output_bfd, (bfd_vma) 0,
+ globals->root.sgot->contents + off
+ + GOT_ENTRY_SIZE);
+ }
+ }
+ else
+ {
+ bfd_put_NN (output_bfd, (bfd_vma) 1,
+ globals->root.sgot->contents + off);
+ bfd_put_NN (output_bfd,
+ relocation - dtpoff_base (info),
+ globals->root.sgot->contents + off
+ + GOT_ENTRY_SIZE);
+ }
+
+ symbol_got_offset_mark (input_bfd, h, r_symndx);
+ }
+ break;
+
+ case BFD_RELOC_AARCH64_TLSIE_ADR_GOTTPREL_PAGE21:
+ case BFD_RELOC_AARCH64_TLSIE_LDNN_GOTTPREL_LO12_NC:
+ case BFD_RELOC_AARCH64_TLSIE_LD_GOTTPREL_PREL19:
+ case BFD_RELOC_AARCH64_TLSIE_MOVW_GOTTPREL_G0_NC:
+ case BFD_RELOC_AARCH64_TLSIE_MOVW_GOTTPREL_G1:
+ if (! symbol_got_offset_mark_p (input_bfd, h, r_symndx))
+ {
+ bool need_relocs = false;
+ bfd_byte *loc;
+ int indx;
+ bfd_vma off;
+
+ off = symbol_got_offset (input_bfd, h, r_symndx);
+
+ indx = h && h->dynindx != -1 ? h->dynindx : 0;
+
+ need_relocs =
+ (!bfd_link_executable (info) || indx != 0) &&
+ (h == NULL
+ || ELF_ST_VISIBILITY (h->other) == STV_DEFAULT
+ || h->root.type != bfd_link_hash_undefweak);
+
+ BFD_ASSERT (globals->root.srelgot != NULL);
+
+ if (need_relocs)
+ {
+ Elf_Internal_Rela rela;
+
+ if (indx == 0)
+ rela.r_addend = relocation - dtpoff_base (info);
+ else
+ rela.r_addend = 0;
+
+ rela.r_info = ELFNN_R_INFO (indx, AARCH64_R (TLS_TPREL));
+ rela.r_offset = globals->root.sgot->output_section->vma +
+ globals->root.sgot->output_offset + off;
+
+ loc = globals->root.srelgot->contents;
+ loc += globals->root.srelgot->reloc_count++
+ * RELOC_SIZE (htab);
+
+ bfd_elfNN_swap_reloca_out (output_bfd, &rela, loc);
+
+ bfd_put_NN (output_bfd, rela.r_addend,
+ globals->root.sgot->contents + off);
+ }
+ else
+ bfd_put_NN (output_bfd, relocation - tpoff_base (info),
+ globals->root.sgot->contents + off);
+
+ symbol_got_offset_mark (input_bfd, h, r_symndx);
+ }
+ break;
+
+ case BFD_RELOC_AARCH64_TLSDESC_ADD_LO12:
+ case BFD_RELOC_AARCH64_TLSDESC_ADR_PAGE21:
+ case BFD_RELOC_AARCH64_TLSDESC_ADR_PREL21:
+ case BFD_RELOC_AARCH64_TLSDESC_LDNN_LO12_NC:
+ case BFD_RELOC_AARCH64_TLSDESC_LD_PREL19:
+ case BFD_RELOC_AARCH64_TLSDESC_OFF_G0_NC:
+ case BFD_RELOC_AARCH64_TLSDESC_OFF_G1:
+ if (! symbol_tlsdesc_got_offset_mark_p (input_bfd, h, r_symndx))
+ {
+ bool need_relocs = false;
+ int indx = h && h->dynindx != -1 ? h->dynindx : 0;
+ bfd_vma off = symbol_tlsdesc_got_offset (input_bfd, h, r_symndx);
+
+ need_relocs = (h == NULL
+ || ELF_ST_VISIBILITY (h->other) == STV_DEFAULT
+ || h->root.type != bfd_link_hash_undefweak);
+
+ BFD_ASSERT (globals->root.srelgot != NULL);
+ BFD_ASSERT (globals->root.sgot != NULL);
+
+ if (need_relocs)
+ {
+ bfd_byte *loc;
+ Elf_Internal_Rela rela;
+ rela.r_info = ELFNN_R_INFO (indx, AARCH64_R (TLSDESC));
+
+ rela.r_addend = 0;
+ rela.r_offset = (globals->root.sgotplt->output_section->vma
+ + globals->root.sgotplt->output_offset
+ + off + globals->sgotplt_jump_table_size);
+
+ if (indx == 0)
+ rela.r_addend = relocation - dtpoff_base (info);
+
+ /* Allocate the next available slot in the PLT reloc
+ section to hold our R_AARCH64_TLSDESC, the next
+ available slot is determined from reloc_count,
+ which we step. But note, reloc_count was
+ artifically moved down while allocating slots for
+ real PLT relocs such that all of the PLT relocs
+ will fit above the initial reloc_count and the
+ extra stuff will fit below. */
+ loc = globals->root.srelplt->contents;
+ loc += globals->root.srelplt->reloc_count++
+ * RELOC_SIZE (globals);
+
+ bfd_elfNN_swap_reloca_out (output_bfd, &rela, loc);
+
+ bfd_put_NN (output_bfd, (bfd_vma) 0,
+ globals->root.sgotplt->contents + off +
+ globals->sgotplt_jump_table_size);
+ bfd_put_NN (output_bfd, (bfd_vma) 0,
+ globals->root.sgotplt->contents + off +
+ globals->sgotplt_jump_table_size +
+ GOT_ENTRY_SIZE);
+ }
+
+ symbol_tlsdesc_got_offset_mark (input_bfd, h, r_symndx);
+ }
+ break;
+ default:
+ break;
+ }
+
+ /* Dynamic relocs are not propagated for SEC_DEBUGGING sections
+ because such sections are not SEC_ALLOC and thus ld.so will
+ not process them. */
+ if (unresolved_reloc
+ && !((input_section->flags & SEC_DEBUGGING) != 0
+ && h->def_dynamic)
+ && _bfd_elf_section_offset (output_bfd, info, input_section,
+ +rel->r_offset) != (bfd_vma) - 1)
+ {
+ _bfd_error_handler
+ /* xgettext:c-format */
+ (_("%pB(%pA+%#" PRIx64 "): "
+ "unresolvable %s relocation against symbol `%s'"),
+ input_bfd, input_section, (uint64_t) rel->r_offset, howto->name,
+ h->root.root.string);
+ return false;
+ }
+
+ if (r != bfd_reloc_ok && r != bfd_reloc_continue)
+ {
+ bfd_reloc_code_real_type real_r_type
+ = elfNN_aarch64_bfd_reloc_from_type (input_bfd, r_type);
+
+ switch (r)
+ {
+ case bfd_reloc_overflow:
+ (*info->callbacks->reloc_overflow)
+ (info, (h ? &h->root : NULL), name, howto->name, (bfd_vma) 0,
+ input_bfd, input_section, rel->r_offset);
+ if (real_r_type == BFD_RELOC_AARCH64_LD64_GOTPAGE_LO15
+ || real_r_type == BFD_RELOC_AARCH64_LD32_GOTPAGE_LO14)
+ {
+ (*info->callbacks->warning)
+ (info,
+ _("too many GOT entries for -fpic, "
+ "please recompile with -fPIC"),
+ name, input_bfd, input_section, rel->r_offset);
+ return false;
+ }
+ /* Overflow can occur when a variable is referenced with a type
+ that has a larger alignment than the type with which it was
+ declared. eg:
+ file1.c: extern int foo; int a (void) { return foo; }
+ file2.c: char bar, foo, baz;
+ If the variable is placed into a data section at an offset
+ that is incompatible with the larger alignment requirement
+ overflow will occur. (Strictly speaking this is not overflow
+ but rather an alignment problem, but the bfd_reloc_ error
+ enum does not have a value to cover that situation).
+
+ Try to catch this situation here and provide a more helpful
+ error message to the user. */
+ if (addend & (((bfd_vma) 1 << howto->rightshift) - 1)
+ /* FIXME: Are we testing all of the appropriate reloc
+ types here ? */
+ && (real_r_type == BFD_RELOC_AARCH64_LD_LO19_PCREL
+ || real_r_type == BFD_RELOC_AARCH64_LDST16_LO12
+ || real_r_type == BFD_RELOC_AARCH64_LDST32_LO12
+ || real_r_type == BFD_RELOC_AARCH64_LDST64_LO12
+ || real_r_type == BFD_RELOC_AARCH64_LDST128_LO12))
+ {
+ info->callbacks->warning
+ (info, _("one possible cause of this error is that the \
+symbol is being referenced in the indicated code as if it had a larger \
+alignment than was declared where it was defined"),
+ name, input_bfd, input_section, rel->r_offset);
+ }
+ break;
+
+ case bfd_reloc_undefined:
+ (*info->callbacks->undefined_symbol)
+ (info, name, input_bfd, input_section, rel->r_offset, true);
+ break;
+
+ case bfd_reloc_outofrange:
+ error_message = _("out of range");
+ goto common_error;
+
+ case bfd_reloc_notsupported:
+ error_message = _("unsupported relocation");
+ goto common_error;
+
+ case bfd_reloc_dangerous:
+ /* error_message should already be set. */
+ goto common_error;
+
+ default:
+ error_message = _("unknown error");
+ /* Fall through. */
+
+ common_error:
+ BFD_ASSERT (error_message != NULL);
+ (*info->callbacks->reloc_dangerous)
+ (info, error_message, input_bfd, input_section, rel->r_offset);
+ break;
+ }
+ }
+
+ if (!save_addend)
+ addend = 0;
+ }
+
+ return true;
+}
+
+/* Set the right machine number. */
+
+static bool
+elfNN_aarch64_object_p (bfd *abfd)
+{
+#if ARCH_SIZE == 32
+ bfd_default_set_arch_mach (abfd, bfd_arch_aarch64, bfd_mach_aarch64_ilp32);
+#else
+ bfd_default_set_arch_mach (abfd, bfd_arch_aarch64, bfd_mach_aarch64);
+#endif
+ return true;
+}
+
+/* Function to keep AArch64 specific flags in the ELF header. */
+
+static bool
+elfNN_aarch64_set_private_flags (bfd *abfd, flagword flags)
+{
+ if (elf_flags_init (abfd) && elf_elfheader (abfd)->e_flags != flags)
+ {
+ }
+ else
+ {
+ elf_elfheader (abfd)->e_flags = flags;
+ elf_flags_init (abfd) = true;
+ }
+
+ return true;
+}
+
+/* Merge backend specific data from an object file to the output
+ object file when linking. */
+
+static bool
+elfNN_aarch64_merge_private_bfd_data (bfd *ibfd, struct bfd_link_info *info)
+{
+ bfd *obfd = info->output_bfd;
+ flagword out_flags;
+ flagword in_flags;
+ bool flags_compatible = true;
+ asection *sec;
+
+ /* Check if we have the same endianess. */
+ if (!_bfd_generic_verify_endian_match (ibfd, info))
+ return false;
+
+ if (!is_aarch64_elf (ibfd) || !is_aarch64_elf (obfd))
+ return true;
+
+ /* The input BFD must have had its flags initialised. */
+ /* The following seems bogus to me -- The flags are initialized in
+ the assembler but I don't think an elf_flags_init field is
+ written into the object. */
+ /* BFD_ASSERT (elf_flags_init (ibfd)); */
+
+ in_flags = elf_elfheader (ibfd)->e_flags;
+ out_flags = elf_elfheader (obfd)->e_flags;
+
+ if (!elf_flags_init (obfd))
+ {
+ /* If the input is the default architecture and had the default
+ flags then do not bother setting the flags for the output
+ architecture, instead allow future merges to do this. If no
+ future merges ever set these flags then they will retain their
+ uninitialised values, which surprise surprise, correspond
+ to the default values. */
+ if (bfd_get_arch_info (ibfd)->the_default
+ && elf_elfheader (ibfd)->e_flags == 0)
+ return true;
+
+ elf_flags_init (obfd) = true;
+ elf_elfheader (obfd)->e_flags = in_flags;
+
+ if (bfd_get_arch (obfd) == bfd_get_arch (ibfd)
+ && bfd_get_arch_info (obfd)->the_default)
+ return bfd_set_arch_mach (obfd, bfd_get_arch (ibfd),
+ bfd_get_mach (ibfd));
+
+ return true;
+ }
+
+ /* Identical flags must be compatible. */
+ if (in_flags == out_flags)
+ return true;
+
+ /* Check to see if the input BFD actually contains any sections. If
+ not, its flags may not have been initialised either, but it
+ cannot actually cause any incompatiblity. Do not short-circuit
+ dynamic objects; their section list may be emptied by
+ elf_link_add_object_symbols.
+
+ Also check to see if there are no code sections in the input.
+ In this case there is no need to check for code specific flags.
+ XXX - do we need to worry about floating-point format compatability
+ in data sections ? */
+ if (!(ibfd->flags & DYNAMIC))
+ {
+ bool null_input_bfd = true;
+ bool only_data_sections = true;
+
+ for (sec = ibfd->sections; sec != NULL; sec = sec->next)
+ {
+ if ((bfd_section_flags (sec)
+ & (SEC_LOAD | SEC_CODE | SEC_HAS_CONTENTS))
+ == (SEC_LOAD | SEC_CODE | SEC_HAS_CONTENTS))
+ only_data_sections = false;
+
+ null_input_bfd = false;
+ break;
+ }
+
+ if (null_input_bfd || only_data_sections)
+ return true;
+ }
+
+ return flags_compatible;
+}
+
+/* Display the flags field. */
+
+static bool
+elfNN_aarch64_print_private_bfd_data (bfd *abfd, void *ptr)
+{
+ FILE *file = (FILE *) ptr;
+ unsigned long flags;
+
+ BFD_ASSERT (abfd != NULL && ptr != NULL);
+
+ /* Print normal ELF private data. */
+ _bfd_elf_print_private_bfd_data (abfd, ptr);
+
+ flags = elf_elfheader (abfd)->e_flags;
+ /* Ignore init flag - it may not be set, despite the flags field
+ containing valid data. */
+
+ /* xgettext:c-format */
+ fprintf (file, _("private flags = 0x%lx:"), elf_elfheader (abfd)->e_flags);
+
+ if (flags)
+ fprintf (file, _(" <Unrecognised flag bits set>"));
+
+ fputc ('\n', file);
+
+ return true;
+}
+
+/* Return true if we need copy relocation against EH. */
+
+static bool
+need_copy_relocation_p (struct elf_aarch64_link_hash_entry *eh)
+{
+ struct elf_dyn_relocs *p;
+ asection *s;
+
+ for (p = eh->root.dyn_relocs; p != NULL; p = p->next)
+ {
+ /* If there is any pc-relative reference, we need to keep copy relocation
+ to avoid propagating the relocation into runtime that current glibc
+ does not support. */
+ if (p->pc_count)
+ return true;
+
+ s = p->sec->output_section;
+ /* Need copy relocation if it's against read-only section. */
+ if (s != NULL && (s->flags & SEC_READONLY) != 0)
+ return true;
+ }
+
+ return false;
+}
+
+/* Adjust a symbol defined by a dynamic object and referenced by a
+ regular object. The current definition is in some section of the
+ dynamic object, but we're not including those sections. We have to
+ change the definition to something the rest of the link can
+ understand. */
+
+static bool
+elfNN_aarch64_adjust_dynamic_symbol (struct bfd_link_info *info,
+ struct elf_link_hash_entry *h)
+{
+ struct elf_aarch64_link_hash_table *htab;
+ asection *s, *srel;
+
+ /* If this is a function, put it in the procedure linkage table. We
+ will fill in the contents of the procedure linkage table later,
+ when we know the address of the .got section. */
+ if (h->type == STT_FUNC || h->type == STT_GNU_IFUNC || h->needs_plt)
+ {
+ if (h->plt.refcount <= 0
+ || (h->type != STT_GNU_IFUNC
+ && (SYMBOL_CALLS_LOCAL (info, h)
+ || (ELF_ST_VISIBILITY (h->other) != STV_DEFAULT
+ && h->root.type == bfd_link_hash_undefweak))))
+ {
+ /* This case can occur if we saw a CALL26 reloc in
+ an input file, but the symbol wasn't referred to
+ by a dynamic object or all references were
+ garbage collected. In which case we can end up
+ resolving. */
+ h->plt.offset = (bfd_vma) - 1;
+ h->needs_plt = 0;
+ }
+
+ return true;
+ }
+ else
+ /* Otherwise, reset to -1. */
+ h->plt.offset = (bfd_vma) - 1;
+
+
+ /* If this is a weak symbol, and there is a real definition, the
+ processor independent code will have arranged for us to see the
+ real definition first, and we can just use the same value. */
+ if (h->is_weakalias)
+ {
+ struct elf_link_hash_entry *def = weakdef (h);
+ BFD_ASSERT (def->root.type == bfd_link_hash_defined);
+ h->root.u.def.section = def->root.u.def.section;
+ h->root.u.def.value = def->root.u.def.value;
+ if (ELIMINATE_COPY_RELOCS || info->nocopyreloc)
+ h->non_got_ref = def->non_got_ref;
+ return true;
+ }
+
+ /* If we are creating a shared library, we must presume that the
+ only references to the symbol are via the global offset table.
+ For such cases we need not do anything here; the relocations will
+ be handled correctly by relocate_section. */
+ if (bfd_link_pic (info))
+ return true;
+
+ /* If there are no references to this symbol that do not use the
+ GOT, we don't need to generate a copy reloc. */
+ if (!h->non_got_ref)
+ return true;
+
+ /* If -z nocopyreloc was given, we won't generate them either. */
+ if (info->nocopyreloc)
+ {
+ h->non_got_ref = 0;
+ return true;
+ }
+
+ if (ELIMINATE_COPY_RELOCS)
+ {
+ struct elf_aarch64_link_hash_entry *eh;
+ /* If we don't find any dynamic relocs in read-only sections, then
+ we'll be keeping the dynamic relocs and avoiding the copy reloc. */
+ eh = (struct elf_aarch64_link_hash_entry *) h;
+ if (!need_copy_relocation_p (eh))
+ {
+ h->non_got_ref = 0;
+ return true;
+ }
+ }
+
+ /* We must allocate the symbol in our .dynbss section, which will
+ become part of the .bss section of the executable. There will be
+ an entry for this symbol in the .dynsym section. The dynamic
+ object will contain position independent code, so all references
+ from the dynamic object to this symbol will go through the global
+ offset table. The dynamic linker will use the .dynsym entry to
+ determine the address it must put in the global offset table, so
+ both the dynamic object and the regular object will refer to the
+ same memory location for the variable. */
+
+ htab = elf_aarch64_hash_table (info);
+
+ /* We must generate a R_AARCH64_COPY reloc to tell the dynamic linker
+ to copy the initial value out of the dynamic object and into the
+ runtime process image. */
+ if ((h->root.u.def.section->flags & SEC_READONLY) != 0)
+ {
+ s = htab->root.sdynrelro;
+ srel = htab->root.sreldynrelro;
+ }
+ else
+ {
+ s = htab->root.sdynbss;
+ srel = htab->root.srelbss;
+ }
+ if ((h->root.u.def.section->flags & SEC_ALLOC) != 0 && h->size != 0)
+ {
+ srel->size += RELOC_SIZE (htab);
+ h->needs_copy = 1;
+ }
+
+ return _bfd_elf_adjust_dynamic_copy (info, h, s);
+
+}
+
+static bool
+elfNN_aarch64_allocate_local_symbols (bfd *abfd, unsigned number)
+{
+ struct elf_aarch64_local_symbol *locals;
+ locals = elf_aarch64_locals (abfd);
+ if (locals == NULL)
+ {
+ locals = (struct elf_aarch64_local_symbol *)
+ bfd_zalloc (abfd, number * sizeof (struct elf_aarch64_local_symbol));
+ if (locals == NULL)
+ return false;
+ elf_aarch64_locals (abfd) = locals;
+ }
+ return true;
+}
+
+/* Create the .got section to hold the global offset table. */
+
+static bool
+aarch64_elf_create_got_section (bfd *abfd, struct bfd_link_info *info)
+{
+ const struct elf_backend_data *bed = get_elf_backend_data (abfd);
+ flagword flags;
+ asection *s;
+ struct elf_link_hash_entry *h;
+ struct elf_link_hash_table *htab = elf_hash_table (info);
+
+ /* This function may be called more than once. */
+ if (htab->sgot != NULL)
+ return true;
+
+ flags = bed->dynamic_sec_flags;
+
+ s = bfd_make_section_anyway_with_flags (abfd,
+ (bed->rela_plts_and_copies_p
+ ? ".rela.got" : ".rel.got"),
+ (bed->dynamic_sec_flags
+ | SEC_READONLY));
+ if (s == NULL
+ || !bfd_set_section_alignment (s, bed->s->log_file_align))
+ return false;
+ htab->srelgot = s;
+
+ s = bfd_make_section_anyway_with_flags (abfd, ".got", flags);
+ if (s == NULL
+ || !bfd_set_section_alignment (s, bed->s->log_file_align))
+ return false;
+ htab->sgot = s;
+ htab->sgot->size += GOT_ENTRY_SIZE;
+
+ if (bed->want_got_sym)
+ {
+ /* Define the symbol _GLOBAL_OFFSET_TABLE_ at the start of the .got
+ (or .got.plt) section. We don't do this in the linker script
+ because we don't want to define the symbol if we are not creating
+ a global offset table. */
+ h = _bfd_elf_define_linkage_sym (abfd, info, s,
+ "_GLOBAL_OFFSET_TABLE_");
+ elf_hash_table (info)->hgot = h;
+ if (h == NULL)
+ return false;
+ }
+
+ if (bed->want_got_plt)
+ {
+ s = bfd_make_section_anyway_with_flags (abfd, ".got.plt", flags);
+ if (s == NULL
+ || !bfd_set_section_alignment (s, bed->s->log_file_align))
+ return false;
+ htab->sgotplt = s;
+ }
+
+ /* The first bit of the global offset table is the header. */
+ s->size += bed->got_header_size;
+
+ return true;
+}
+
+/* Look through the relocs for a section during the first phase. */
+
+static bool
+elfNN_aarch64_check_relocs (bfd *abfd, struct bfd_link_info *info,
+ asection *sec, const Elf_Internal_Rela *relocs)
+{
+ Elf_Internal_Shdr *symtab_hdr;
+ struct elf_link_hash_entry **sym_hashes;
+ const Elf_Internal_Rela *rel;
+ const Elf_Internal_Rela *rel_end;
+ asection *sreloc;
+
+ struct elf_aarch64_link_hash_table *htab;
+
+ if (bfd_link_relocatable (info))
+ return true;
+
+ BFD_ASSERT (is_aarch64_elf (abfd));
+
+ htab = elf_aarch64_hash_table (info);
+ sreloc = NULL;
+
+ symtab_hdr = &elf_symtab_hdr (abfd);
+ sym_hashes = elf_sym_hashes (abfd);
+
+ rel_end = relocs + sec->reloc_count;
+ for (rel = relocs; rel < rel_end; rel++)
+ {
+ struct elf_link_hash_entry *h;
+ unsigned int r_symndx;
+ unsigned int r_type;
+ bfd_reloc_code_real_type bfd_r_type;
+ Elf_Internal_Sym *isym;
+
+ r_symndx = ELFNN_R_SYM (rel->r_info);
+ r_type = ELFNN_R_TYPE (rel->r_info);
+
+ if (r_symndx >= NUM_SHDR_ENTRIES (symtab_hdr))
+ {
+ /* xgettext:c-format */
+ _bfd_error_handler (_("%pB: bad symbol index: %d"), abfd, r_symndx);
+ return false;
+ }
+
+ if (r_symndx < symtab_hdr->sh_info)
+ {
+ /* A local symbol. */
+ isym = bfd_sym_from_r_symndx (&htab->root.sym_cache,
+ abfd, r_symndx);
+ if (isym == NULL)
+ return false;
+
+ /* Check relocation against local STT_GNU_IFUNC symbol. */
+ if (ELF_ST_TYPE (isym->st_info) == STT_GNU_IFUNC)
+ {
+ h = elfNN_aarch64_get_local_sym_hash (htab, abfd, rel,
+ true);
+ if (h == NULL)
+ return false;
+
+ /* Fake a STT_GNU_IFUNC symbol. */
+ h->type = STT_GNU_IFUNC;
+ h->def_regular = 1;
+ h->ref_regular = 1;
+ h->forced_local = 1;
+ h->root.type = bfd_link_hash_defined;
+ }
+ else
+ h = NULL;
+ }
+ else
+ {
+ h = sym_hashes[r_symndx - symtab_hdr->sh_info];
+ while (h->root.type == bfd_link_hash_indirect
+ || h->root.type == bfd_link_hash_warning)
+ h = (struct elf_link_hash_entry *) h->root.u.i.link;
+ }
+
+ /* Could be done earlier, if h were already available. */
+ bfd_r_type = aarch64_tls_transition (abfd, info, r_type, h, r_symndx);
+
+ if (h != NULL)
+ {
+ /* If a relocation refers to _GLOBAL_OFFSET_TABLE_, create the .got.
+ This shows up in particular in an R_AARCH64_PREL64 in large model
+ when calculating the pc-relative address to .got section which is
+ used to initialize the gp register. */
+ if (h->root.root.string
+ && strcmp (h->root.root.string, "_GLOBAL_OFFSET_TABLE_") == 0)
+ {
+ if (htab->root.dynobj == NULL)
+ htab->root.dynobj = abfd;
+
+ if (! aarch64_elf_create_got_section (htab->root.dynobj, info))
+ return false;
+
+ BFD_ASSERT (h == htab->root.hgot);
+ }
+
+ /* Create the ifunc sections for static executables. If we
+ never see an indirect function symbol nor we are building
+ a static executable, those sections will be empty and
+ won't appear in output. */
+ switch (bfd_r_type)
+ {
+ default:
+ break;
+
+ case BFD_RELOC_AARCH64_ADD_LO12:
+ case BFD_RELOC_AARCH64_ADR_GOT_PAGE:
+ case BFD_RELOC_AARCH64_ADR_HI21_PCREL:
+ case BFD_RELOC_AARCH64_CALL26:
+ case BFD_RELOC_AARCH64_GOT_LD_PREL19:
+ case BFD_RELOC_AARCH64_JUMP26:
+ case BFD_RELOC_AARCH64_LD32_GOTPAGE_LO14:
+ case BFD_RELOC_AARCH64_LD32_GOT_LO12_NC:
+ case BFD_RELOC_AARCH64_LD64_GOTOFF_LO15:
+ case BFD_RELOC_AARCH64_LD64_GOTPAGE_LO15:
+ case BFD_RELOC_AARCH64_LD64_GOT_LO12_NC:
+ case BFD_RELOC_AARCH64_MOVW_GOTOFF_G0_NC:
+ case BFD_RELOC_AARCH64_MOVW_GOTOFF_G1:
+ case BFD_RELOC_AARCH64_NN:
+ if (htab->root.dynobj == NULL)
+ htab->root.dynobj = abfd;
+ if (!_bfd_elf_create_ifunc_sections (htab->root.dynobj, info))
+ return false;
+ break;
+ }
+
+ /* It is referenced by a non-shared object. */
+ h->ref_regular = 1;
+ }
+
+ switch (bfd_r_type)
+ {
+ case BFD_RELOC_AARCH64_16:
+#if ARCH_SIZE == 64
+ case BFD_RELOC_AARCH64_32:
+#endif
+ if (bfd_link_pic (info) && (sec->flags & SEC_ALLOC) != 0)
+ {
+ if (h != NULL
+ /* This is an absolute symbol. It represents a value instead
+ of an address. */
+ && (bfd_is_abs_symbol (&h->root)
+ /* This is an undefined symbol. */
+ || h->root.type == bfd_link_hash_undefined))
+ break;
+
+ /* For local symbols, defined global symbols in a non-ABS section,
+ it is assumed that the value is an address. */
+ int howto_index = bfd_r_type - BFD_RELOC_AARCH64_RELOC_START;
+ _bfd_error_handler
+ /* xgettext:c-format */
+ (_("%pB: relocation %s against `%s' can not be used when making "
+ "a shared object"),
+ abfd, elfNN_aarch64_howto_table[howto_index].name,
+ (h) ? h->root.root.string : "a local symbol");
+ bfd_set_error (bfd_error_bad_value);
+ return false;
+ }
+ else
+ break;
+
+ case BFD_RELOC_AARCH64_MOVW_G0_NC:
+ case BFD_RELOC_AARCH64_MOVW_G1_NC:
+ case BFD_RELOC_AARCH64_MOVW_G2_NC:
+ case BFD_RELOC_AARCH64_MOVW_G3:
+ if (bfd_link_pic (info))
+ {
+ int howto_index = bfd_r_type - BFD_RELOC_AARCH64_RELOC_START;
+ _bfd_error_handler
+ /* xgettext:c-format */
+ (_("%pB: relocation %s against `%s' can not be used when making "
+ "a shared object; recompile with -fPIC"),
+ abfd, elfNN_aarch64_howto_table[howto_index].name,
+ (h) ? h->root.root.string : "a local symbol");
+ bfd_set_error (bfd_error_bad_value);
+ return false;
+ }
+ /* Fall through. */
+
+ case BFD_RELOC_AARCH64_16_PCREL:
+ case BFD_RELOC_AARCH64_32_PCREL:
+ case BFD_RELOC_AARCH64_64_PCREL:
+ case BFD_RELOC_AARCH64_ADD_LO12:
+ case BFD_RELOC_AARCH64_ADR_HI21_NC_PCREL:
+ case BFD_RELOC_AARCH64_ADR_HI21_PCREL:
+ case BFD_RELOC_AARCH64_ADR_LO21_PCREL:
+ case BFD_RELOC_AARCH64_LDST128_LO12:
+ case BFD_RELOC_AARCH64_LDST16_LO12:
+ case BFD_RELOC_AARCH64_LDST32_LO12:
+ case BFD_RELOC_AARCH64_LDST64_LO12:
+ case BFD_RELOC_AARCH64_LDST8_LO12:
+ case BFD_RELOC_AARCH64_LD_LO19_PCREL:
+ if (h == NULL || bfd_link_pic (info))
+ break;
+ /* Fall through. */
+
+ case BFD_RELOC_AARCH64_NN:
+
+ /* We don't need to handle relocs into sections not going into
+ the "real" output. */
+ if ((sec->flags & SEC_ALLOC) == 0)
+ break;
+
+ if (h != NULL)
+ {
+ if (!bfd_link_pic (info))
+ h->non_got_ref = 1;
+
+ h->plt.refcount += 1;
+ h->pointer_equality_needed = 1;
+ }
+
+ /* No need to do anything if we're not creating a shared
+ object. */
+ if (!(bfd_link_pic (info)
+ /* If on the other hand, we are creating an executable, we
+ may need to keep relocations for symbols satisfied by a
+ dynamic library if we manage to avoid copy relocs for the
+ symbol.
+
+ NOTE: Currently, there is no support of copy relocs
+ elimination on pc-relative relocation types, because there is
+ no dynamic relocation support for them in glibc. We still
+ record the dynamic symbol reference for them. This is
+ because one symbol may be referenced by both absolute
+ relocation (for example, BFD_RELOC_AARCH64_NN) and
+ pc-relative relocation. We need full symbol reference
+ information to make correct decision later in
+ elfNN_aarch64_adjust_dynamic_symbol. */
+ || (ELIMINATE_COPY_RELOCS
+ && !bfd_link_pic (info)
+ && h != NULL
+ && (h->root.type == bfd_link_hash_defweak
+ || !h->def_regular))))
+ break;
+
+ {
+ struct elf_dyn_relocs *p;
+ struct elf_dyn_relocs **head;
+ int howto_index = bfd_r_type - BFD_RELOC_AARCH64_RELOC_START;
+
+ /* We must copy these reloc types into the output file.
+ Create a reloc section in dynobj and make room for
+ this reloc. */
+ if (sreloc == NULL)
+ {
+ if (htab->root.dynobj == NULL)
+ htab->root.dynobj = abfd;
+
+ sreloc = _bfd_elf_make_dynamic_reloc_section
+ (sec, htab->root.dynobj, LOG_FILE_ALIGN, abfd, /*rela? */ true);
+
+ if (sreloc == NULL)
+ return false;
+ }
+
+ /* If this is a global symbol, we count the number of
+ relocations we need for this symbol. */
+ if (h != NULL)
+ {
+ head = &h->dyn_relocs;
+ }
+ else
+ {
+ /* Track dynamic relocs needed for local syms too.
+ We really need local syms available to do this
+ easily. Oh well. */
+
+ asection *s;
+ void **vpp;
+
+ isym = bfd_sym_from_r_symndx (&htab->root.sym_cache,
+ abfd, r_symndx);
+ if (isym == NULL)
+ return false;
+
+ s = bfd_section_from_elf_index (abfd, isym->st_shndx);
+ if (s == NULL)
+ s = sec;
+
+ /* Beware of type punned pointers vs strict aliasing
+ rules. */
+ vpp = &(elf_section_data (s)->local_dynrel);
+ head = (struct elf_dyn_relocs **) vpp;
+ }
+
+ p = *head;
+ if (p == NULL || p->sec != sec)
+ {
+ size_t amt = sizeof *p;
+ p = ((struct elf_dyn_relocs *)
+ bfd_zalloc (htab->root.dynobj, amt));
+ if (p == NULL)
+ return false;
+ p->next = *head;
+ *head = p;
+ p->sec = sec;
+ }
+
+ p->count += 1;
+
+ if (elfNN_aarch64_howto_table[howto_index].pc_relative)
+ p->pc_count += 1;
+ }
+ break;
+
+ /* RR: We probably want to keep a consistency check that
+ there are no dangling GOT_PAGE relocs. */
+ case BFD_RELOC_AARCH64_ADR_GOT_PAGE:
+ case BFD_RELOC_AARCH64_GOT_LD_PREL19:
+ case BFD_RELOC_AARCH64_LD32_GOTPAGE_LO14:
+ case BFD_RELOC_AARCH64_LD32_GOT_LO12_NC:
+ case BFD_RELOC_AARCH64_LD64_GOTOFF_LO15:
+ case BFD_RELOC_AARCH64_LD64_GOTPAGE_LO15:
+ case BFD_RELOC_AARCH64_LD64_GOT_LO12_NC:
+ case BFD_RELOC_AARCH64_MOVW_GOTOFF_G0_NC:
+ case BFD_RELOC_AARCH64_MOVW_GOTOFF_G1:
+ case BFD_RELOC_AARCH64_TLSDESC_ADD_LO12:
+ case BFD_RELOC_AARCH64_TLSDESC_ADR_PAGE21:
+ case BFD_RELOC_AARCH64_TLSDESC_ADR_PREL21:
+ case BFD_RELOC_AARCH64_TLSDESC_LD32_LO12_NC:
+ case BFD_RELOC_AARCH64_TLSDESC_LD64_LO12:
+ case BFD_RELOC_AARCH64_TLSDESC_LD_PREL19:
+ case BFD_RELOC_AARCH64_TLSDESC_OFF_G0_NC:
+ case BFD_RELOC_AARCH64_TLSDESC_OFF_G1:
+ case BFD_RELOC_AARCH64_TLSGD_ADD_LO12_NC:
+ case BFD_RELOC_AARCH64_TLSGD_ADR_PAGE21:
+ case BFD_RELOC_AARCH64_TLSGD_ADR_PREL21:
+ case BFD_RELOC_AARCH64_TLSGD_MOVW_G0_NC:
+ case BFD_RELOC_AARCH64_TLSGD_MOVW_G1:
+ case BFD_RELOC_AARCH64_TLSIE_ADR_GOTTPREL_PAGE21:
+ case BFD_RELOC_AARCH64_TLSIE_LD32_GOTTPREL_LO12_NC:
+ case BFD_RELOC_AARCH64_TLSIE_LD64_GOTTPREL_LO12_NC:
+ case BFD_RELOC_AARCH64_TLSIE_LD_GOTTPREL_PREL19:
+ case BFD_RELOC_AARCH64_TLSIE_MOVW_GOTTPREL_G0_NC:
+ case BFD_RELOC_AARCH64_TLSIE_MOVW_GOTTPREL_G1:
+ case BFD_RELOC_AARCH64_TLSLD_ADD_LO12_NC:
+ case BFD_RELOC_AARCH64_TLSLD_ADR_PAGE21:
+ case BFD_RELOC_AARCH64_TLSLD_ADR_PREL21:
+ {
+ unsigned got_type;
+ unsigned old_got_type;
+
+ got_type = aarch64_reloc_got_type (bfd_r_type);
+
+ if (h)
+ {
+ h->got.refcount += 1;
+ old_got_type = elf_aarch64_hash_entry (h)->got_type;
+ }
+ else
+ {
+ struct elf_aarch64_local_symbol *locals;
+
+ if (!elfNN_aarch64_allocate_local_symbols
+ (abfd, symtab_hdr->sh_info))
+ return false;
+
+ locals = elf_aarch64_locals (abfd);
+ BFD_ASSERT (r_symndx < symtab_hdr->sh_info);
+ locals[r_symndx].got_refcount += 1;
+ old_got_type = locals[r_symndx].got_type;
+ }
+
+ /* If a variable is accessed with both general dynamic TLS
+ methods, two slots may be created. */
+ if (GOT_TLS_GD_ANY_P (old_got_type) && GOT_TLS_GD_ANY_P (got_type))
+ got_type |= old_got_type;
+
+ /* We will already have issued an error message if there
+ is a TLS/non-TLS mismatch, based on the symbol type.
+ So just combine any TLS types needed. */
+ if (old_got_type != GOT_UNKNOWN && old_got_type != GOT_NORMAL
+ && got_type != GOT_NORMAL)
+ got_type |= old_got_type;
+
+ /* If the symbol is accessed by both IE and GD methods, we
+ are able to relax. Turn off the GD flag, without
+ messing up with any other kind of TLS types that may be
+ involved. */
+ if ((got_type & GOT_TLS_IE) && GOT_TLS_GD_ANY_P (got_type))
+ got_type &= ~ (GOT_TLSDESC_GD | GOT_TLS_GD);
+
+ if (old_got_type != got_type)
+ {
+ if (h != NULL)
+ elf_aarch64_hash_entry (h)->got_type = got_type;
+ else
+ {
+ struct elf_aarch64_local_symbol *locals;
+ locals = elf_aarch64_locals (abfd);
+ BFD_ASSERT (r_symndx < symtab_hdr->sh_info);
+ locals[r_symndx].got_type = got_type;
+ }
+ }
+
+ if (htab->root.dynobj == NULL)
+ htab->root.dynobj = abfd;
+ if (! aarch64_elf_create_got_section (htab->root.dynobj, info))
+ return false;
+ break;
+ }
+
+ case BFD_RELOC_AARCH64_CALL26:
+ case BFD_RELOC_AARCH64_JUMP26:
+ /* If this is a local symbol then we resolve it
+ directly without creating a PLT entry. */
+ if (h == NULL)
+ continue;
+
+ h->needs_plt = 1;
+ if (h->plt.refcount <= 0)
+ h->plt.refcount = 1;
+ else
+ h->plt.refcount += 1;
+ break;
+
+ default:
+ break;
+ }
+ }
+
+ return true;
+}
+
+/* Treat mapping symbols as special target symbols. */
+
+static bool
+elfNN_aarch64_is_target_special_symbol (bfd *abfd ATTRIBUTE_UNUSED,
+ asymbol *sym)
+{
+ return bfd_is_aarch64_special_symbol_name (sym->name,
+ BFD_AARCH64_SPECIAL_SYM_TYPE_ANY);
+}
+
+/* If the ELF symbol SYM might be a function in SEC, return the
+ function size and set *CODE_OFF to the function's entry point,
+ otherwise return zero. */
+
+static bfd_size_type
+elfNN_aarch64_maybe_function_sym (const asymbol *sym, asection *sec,
+ bfd_vma *code_off)
+{
+ bfd_size_type size;
+ elf_symbol_type * elf_sym = (elf_symbol_type *) sym;
+
+ if ((sym->flags & (BSF_SECTION_SYM | BSF_FILE | BSF_OBJECT
+ | BSF_THREAD_LOCAL | BSF_RELC | BSF_SRELC)) != 0
+ || sym->section != sec)
+ return 0;
+
+ size = (sym->flags & BSF_SYNTHETIC) ? 0 : elf_sym->internal_elf_sym.st_size;
+
+ if (!(sym->flags & BSF_SYNTHETIC))
+ switch (ELF_ST_TYPE (elf_sym->internal_elf_sym.st_info))
+ {
+ case STT_NOTYPE:
+ /* Ignore symbols created by the annobin plugin for gcc and clang.
+ These symbols are hidden, local, notype and have a size of 0. */
+ if (size == 0
+ && sym->flags & BSF_LOCAL
+ && ELF_ST_VISIBILITY (elf_sym->internal_elf_sym.st_other) == STV_HIDDEN)
+ return 0;
+ /* Fall through. */
+ case STT_FUNC:
+ /* FIXME: Allow STT_GNU_IFUNC as well ? */
+ break;
+ default:
+ return 0;
+ }
+
+ if ((sym->flags & BSF_LOCAL)
+ && bfd_is_aarch64_special_symbol_name (sym->name,
+ BFD_AARCH64_SPECIAL_SYM_TYPE_ANY))
+ return 0;
+
+ *code_off = sym->value;
+
+ /* Do not return 0 for the function's size. */
+ return size ? size : 1;
+}
+
+static bool
+elfNN_aarch64_find_inliner_info (bfd *abfd,
+ const char **filename_ptr,
+ const char **functionname_ptr,
+ unsigned int *line_ptr)
+{
+ bool found;
+ found = _bfd_dwarf2_find_inliner_info
+ (abfd, filename_ptr,
+ functionname_ptr, line_ptr, &elf_tdata (abfd)->dwarf2_find_line_info);
+ return found;
+}
+
+
+static bool
+elfNN_aarch64_init_file_header (bfd *abfd, struct bfd_link_info *link_info)
+{
+ Elf_Internal_Ehdr *i_ehdrp; /* ELF file header, internal form. */
+
+ if (!_bfd_elf_init_file_header (abfd, link_info))
+ return false;
+
+ i_ehdrp = elf_elfheader (abfd);
+ i_ehdrp->e_ident[EI_ABIVERSION] = AARCH64_ELF_ABI_VERSION;
+ return true;
+}
+
+static enum elf_reloc_type_class
+elfNN_aarch64_reloc_type_class (const struct bfd_link_info *info ATTRIBUTE_UNUSED,
+ const asection *rel_sec ATTRIBUTE_UNUSED,
+ const Elf_Internal_Rela *rela)
+{
+ struct elf_aarch64_link_hash_table *htab = elf_aarch64_hash_table (info);
+
+ if (htab->root.dynsym != NULL
+ && htab->root.dynsym->contents != NULL)
+ {
+ /* Check relocation against STT_GNU_IFUNC symbol if there are
+ dynamic symbols. */
+ bfd *abfd = info->output_bfd;
+ const struct elf_backend_data *bed = get_elf_backend_data (abfd);
+ unsigned long r_symndx = ELFNN_R_SYM (rela->r_info);
+ if (r_symndx != STN_UNDEF)
+ {
+ Elf_Internal_Sym sym;
+ if (!bed->s->swap_symbol_in (abfd,
+ (htab->root.dynsym->contents
+ + r_symndx * bed->s->sizeof_sym),
+ 0, &sym))
+ {
+ /* xgettext:c-format */
+ _bfd_error_handler (_("%pB symbol number %lu references"
+ " nonexistent SHT_SYMTAB_SHNDX section"),
+ abfd, r_symndx);
+ /* Ideally an error class should be returned here. */
+ }
+ else if (ELF_ST_TYPE (sym.st_info) == STT_GNU_IFUNC)
+ return reloc_class_ifunc;
+ }
+ }
+
+ switch ((int) ELFNN_R_TYPE (rela->r_info))
+ {
+ case AARCH64_R (IRELATIVE):
+ return reloc_class_ifunc;
+ case AARCH64_R (RELATIVE):
+ return reloc_class_relative;
+ case AARCH64_R (JUMP_SLOT):
+ return reloc_class_plt;
+ case AARCH64_R (COPY):
+ return reloc_class_copy;
+ default:
+ return reloc_class_normal;
+ }
+}
+
+/* Handle an AArch64 specific section when reading an object file. This is
+ called when bfd_section_from_shdr finds a section with an unknown
+ type. */
+
+static bool
+elfNN_aarch64_section_from_shdr (bfd *abfd,
+ Elf_Internal_Shdr *hdr,
+ const char *name, int shindex)
+{
+ /* There ought to be a place to keep ELF backend specific flags, but
+ at the moment there isn't one. We just keep track of the
+ sections by their name, instead. Fortunately, the ABI gives
+ names for all the AArch64 specific sections, so we will probably get
+ away with this. */
+ switch (hdr->sh_type)
+ {
+ case SHT_AARCH64_ATTRIBUTES:
+ break;
+
+ default:
+ return false;
+ }
+
+ if (!_bfd_elf_make_section_from_shdr (abfd, hdr, name, shindex))
+ return false;
+
+ return true;
+}
+
+/* Process any AArch64-specific program segment types. */
+
+static bool
+elfNN_aarch64_section_from_phdr (bfd *abfd ATTRIBUTE_UNUSED,
+ Elf_Internal_Phdr *hdr,
+ int hdr_index ATTRIBUTE_UNUSED,
+ const char *name ATTRIBUTE_UNUSED)
+{
+ /* Right now we only handle the PT_AARCH64_MEMTAG_MTE segment type. */
+ if (hdr == NULL || hdr->p_type != PT_AARCH64_MEMTAG_MTE)
+ return false;
+
+ if (hdr->p_filesz > 0)
+ {
+ /* Sections created from memory tag p_type's are always named
+ "memtag". This makes it easier for tools (for example, GDB)
+ to find them. */
+ asection *newsect = bfd_make_section_anyway (abfd, "memtag");
+
+ if (newsect == NULL)
+ return false;
+
+ unsigned int opb = bfd_octets_per_byte (abfd, NULL);
+
+ /* p_vaddr holds the original start address of the tagged memory
+ range. */
+ newsect->vma = hdr->p_vaddr / opb;
+
+ /* p_filesz holds the storage size of the packed tags. */
+ newsect->size = hdr->p_filesz;
+ newsect->filepos = hdr->p_offset;
+
+ /* p_memsz holds the size of the memory range that contains tags. The
+ section's rawsize field is reused for this purpose. */
+ newsect->rawsize = hdr->p_memsz;
+
+ /* Make sure the section's flags has SEC_HAS_CONTENTS set, otherwise
+ BFD will return all zeroes when attempting to get contents from this
+ section. */
+ newsect->flags |= SEC_HAS_CONTENTS;
+ }
+
+ return true;
+}
+
+/* Implements the bfd_elf_modify_headers hook for aarch64. */
+
+static bool
+elfNN_aarch64_modify_headers (bfd *abfd,
+ struct bfd_link_info *info)
+{
+ struct elf_segment_map *m;
+ unsigned int segment_count = 0;
+ Elf_Internal_Phdr *p;
+
+ for (m = elf_seg_map (abfd); m != NULL; m = m->next, segment_count++)
+ {
+ /* We are only interested in the memory tag segment that will be dumped
+ to a core file. If we have no memory tags or this isn't a core file we
+ are dealing with, just skip this segment. */
+ if (m->p_type != PT_AARCH64_MEMTAG_MTE
+ || bfd_get_format (abfd) != bfd_core)
+ continue;
+
+ /* For memory tag segments in core files, the size of the file contents
+ is smaller than the size of the memory range. Adjust the memory size
+ accordingly. The real memory size is held in the section's rawsize
+ field. */
+ if (m->count > 0)
+ {
+ p = elf_tdata (abfd)->phdr;
+ p += m->idx;
+ p->p_memsz = m->sections[0]->rawsize;
+ p->p_flags = 0;
+ p->p_paddr = 0;
+ p->p_align = 0;
+ }
+ }
+
+ /* Give the generic code a chance to handle the headers. */
+ return _bfd_elf_modify_headers (abfd, info);
+}
+
+
+typedef struct
+{
+ void *finfo;
+ struct bfd_link_info *info;
+ asection *sec;
+ int sec_shndx;
+ int (*func) (void *, const char *, Elf_Internal_Sym *,
+ asection *, struct elf_link_hash_entry *);
+} output_arch_syminfo;
+
+enum map_symbol_type
+{
+ AARCH64_MAP_INSN,
+ AARCH64_MAP_DATA
+};
+
+
+/* Output a single mapping symbol. */
+
+static bool
+elfNN_aarch64_output_map_sym (output_arch_syminfo *osi,
+ enum map_symbol_type type, bfd_vma offset)
+{
+ static const char *names[2] = { "$x", "$d" };
+ Elf_Internal_Sym sym;
+
+ sym.st_value = (osi->sec->output_section->vma
+ + osi->sec->output_offset + offset);
+ sym.st_size = 0;
+ sym.st_other = 0;
+ sym.st_info = ELF_ST_INFO (STB_LOCAL, STT_NOTYPE);
+ sym.st_shndx = osi->sec_shndx;
+ return osi->func (osi->finfo, names[type], &sym, osi->sec, NULL) == 1;
+}
+
+/* Output a single local symbol for a generated stub. */
+
+static bool
+elfNN_aarch64_output_stub_sym (output_arch_syminfo *osi, const char *name,
+ bfd_vma offset, bfd_vma size)
+{
+ Elf_Internal_Sym sym;
+
+ sym.st_value = (osi->sec->output_section->vma
+ + osi->sec->output_offset + offset);
+ sym.st_size = size;
+ sym.st_other = 0;
+ sym.st_info = ELF_ST_INFO (STB_LOCAL, STT_FUNC);
+ sym.st_shndx = osi->sec_shndx;
+ return osi->func (osi->finfo, name, &sym, osi->sec, NULL) == 1;
+}
+
+static bool
+aarch64_map_one_stub (struct bfd_hash_entry *gen_entry, void *in_arg)
+{
+ struct elf_aarch64_stub_hash_entry *stub_entry;
+ asection *stub_sec;
+ bfd_vma addr;
+ char *stub_name;
+ output_arch_syminfo *osi;
+
+ /* Massage our args to the form they really have. */
+ stub_entry = (struct elf_aarch64_stub_hash_entry *) gen_entry;
+ osi = (output_arch_syminfo *) in_arg;
+
+ stub_sec = stub_entry->stub_sec;
+
+ /* Ensure this stub is attached to the current section being
+ processed. */
+ if (stub_sec != osi->sec)
+ return true;
+
+ addr = (bfd_vma) stub_entry->stub_offset;
+
+ stub_name = stub_entry->output_name;
+
+ switch (stub_entry->stub_type)
+ {
+ case aarch64_stub_adrp_branch:
+ if (!elfNN_aarch64_output_stub_sym (osi, stub_name, addr,
+ sizeof (aarch64_adrp_branch_stub)))
+ return false;
+ if (!elfNN_aarch64_output_map_sym (osi, AARCH64_MAP_INSN, addr))
+ return false;
+ break;
+ case aarch64_stub_long_branch:
+ if (!elfNN_aarch64_output_stub_sym
+ (osi, stub_name, addr, sizeof (aarch64_long_branch_stub)))
+ return false;
+ if (!elfNN_aarch64_output_map_sym (osi, AARCH64_MAP_INSN, addr))
+ return false;
+ if (!elfNN_aarch64_output_map_sym (osi, AARCH64_MAP_DATA, addr + 16))
+ return false;
+ break;
+ case aarch64_stub_bti_direct_branch:
+ if (!elfNN_aarch64_output_stub_sym (osi, stub_name, addr,
+ sizeof (aarch64_bti_direct_branch_stub)))
+ return false;
+ if (!elfNN_aarch64_output_map_sym (osi, AARCH64_MAP_INSN, addr))
+ return false;
+ break;
+ case aarch64_stub_erratum_835769_veneer:
+ if (!elfNN_aarch64_output_stub_sym (osi, stub_name, addr,
+ sizeof (aarch64_erratum_835769_stub)))
+ return false;
+ if (!elfNN_aarch64_output_map_sym (osi, AARCH64_MAP_INSN, addr))
+ return false;
+ break;
+ case aarch64_stub_erratum_843419_veneer:
+ if (!elfNN_aarch64_output_stub_sym (osi, stub_name, addr,
+ sizeof (aarch64_erratum_843419_stub)))
+ return false;
+ if (!elfNN_aarch64_output_map_sym (osi, AARCH64_MAP_INSN, addr))
+ return false;
+ break;
+ case aarch64_stub_none:
+ break;
+
+ default:
+ abort ();
+ }
+
+ return true;
+}
+
+/* Output mapping symbols for linker generated sections. */
+
+static bool
+elfNN_aarch64_output_arch_local_syms (bfd *output_bfd,
+ struct bfd_link_info *info,
+ void *finfo,
+ int (*func) (void *, const char *,
+ Elf_Internal_Sym *,
+ asection *,
+ struct elf_link_hash_entry
+ *))
+{
+ output_arch_syminfo osi;
+ struct elf_aarch64_link_hash_table *htab;
+
+ if (info->strip == strip_all
+ && !info->emitrelocations
+ && !bfd_link_relocatable (info))
+ return true;
+
+ htab = elf_aarch64_hash_table (info);
+
+ osi.finfo = finfo;
+ osi.info = info;
+ osi.func = func;
+
+ /* Long calls stubs. */
+ if (htab->stub_bfd && htab->stub_bfd->sections)
+ {
+ asection *stub_sec;
+
+ for (stub_sec = htab->stub_bfd->sections;
+ stub_sec != NULL; stub_sec = stub_sec->next)
+ {
+ /* Ignore non-stub sections. */
+ if (!strstr (stub_sec->name, STUB_SUFFIX))
+ continue;
+
+ osi.sec = stub_sec;
+
+ osi.sec_shndx = _bfd_elf_section_from_bfd_section
+ (output_bfd, osi.sec->output_section);
+
+ /* The first instruction in a stub is always a branch. */
+ if (!elfNN_aarch64_output_map_sym (&osi, AARCH64_MAP_INSN, 0))
+ return false;
+
+ bfd_hash_traverse (&htab->stub_hash_table, aarch64_map_one_stub,
+ &osi);
+ }
+ }
+
+ /* Finally, output mapping symbols for the PLT. */
+ if (!htab->root.splt || htab->root.splt->size == 0)
+ return true;
+
+ osi.sec_shndx = _bfd_elf_section_from_bfd_section
+ (output_bfd, htab->root.splt->output_section);
+ osi.sec = htab->root.splt;
+
+ elfNN_aarch64_output_map_sym (&osi, AARCH64_MAP_INSN, 0);
+
+ return true;
+
+}
+
+/* Allocate target specific section data. */
+
+static bool
+elfNN_aarch64_new_section_hook (bfd *abfd, asection *sec)
+{
+ _aarch64_elf_section_data *sdata;
+
+ sdata = bfd_zalloc (abfd, sizeof (*sdata));
+ if (sdata == NULL)
+ return false;
+ sec->used_by_bfd = sdata;
+
+ return _bfd_elf_new_section_hook (abfd, sec);
+}
+
+
+/* Create dynamic sections. This is different from the ARM backend in that
+ the got, plt, gotplt and their relocation sections are all created in the
+ standard part of the bfd elf backend. */
+
+static bool
+elfNN_aarch64_create_dynamic_sections (bfd *dynobj,
+ struct bfd_link_info *info)
+{
+ /* We need to create .got section. */
+ if (!aarch64_elf_create_got_section (dynobj, info))
+ return false;
+
+ return _bfd_elf_create_dynamic_sections (dynobj, info);
+}
+
+
+/* Allocate space in .plt, .got and associated reloc sections for
+ dynamic relocs. */
+
+static bool
+elfNN_aarch64_allocate_dynrelocs (struct elf_link_hash_entry *h, void *inf)
+{
+ struct bfd_link_info *info;
+ struct elf_aarch64_link_hash_table *htab;
+ struct elf_aarch64_link_hash_entry *eh;
+ struct elf_dyn_relocs *p;
+
+ /* An example of a bfd_link_hash_indirect symbol is versioned
+ symbol. For example: __gxx_personality_v0(bfd_link_hash_indirect)
+ -> __gxx_personality_v0(bfd_link_hash_defined)
+
+ There is no need to process bfd_link_hash_indirect symbols here
+ because we will also be presented with the concrete instance of
+ the symbol and elfNN_aarch64_copy_indirect_symbol () will have been
+ called to copy all relevant data from the generic to the concrete
+ symbol instance. */
+ if (h->root.type == bfd_link_hash_indirect)
+ return true;
+
+ if (h->root.type == bfd_link_hash_warning)
+ h = (struct elf_link_hash_entry *) h->root.u.i.link;
+
+ info = (struct bfd_link_info *) inf;
+ htab = elf_aarch64_hash_table (info);
+
+ /* Since STT_GNU_IFUNC symbol must go through PLT, we handle it
+ here if it is defined and referenced in a non-shared object. */
+ if (h->type == STT_GNU_IFUNC
+ && h->def_regular)
+ return true;
+ else if (htab->root.dynamic_sections_created && h->plt.refcount > 0)
+ {
+ /* Make sure this symbol is output as a dynamic symbol.
+ Undefined weak syms won't yet be marked as dynamic. */
+ if (h->dynindx == -1 && !h->forced_local
+ && h->root.type == bfd_link_hash_undefweak)
+ {
+ if (!bfd_elf_link_record_dynamic_symbol (info, h))
+ return false;
+ }
+
+ if (bfd_link_pic (info) || WILL_CALL_FINISH_DYNAMIC_SYMBOL (1, 0, h))
+ {
+ asection *s = htab->root.splt;
+
+ /* If this is the first .plt entry, make room for the special
+ first entry. */
+ if (s->size == 0)
+ s->size += htab->plt_header_size;
+
+ h->plt.offset = s->size;
+
+ /* If this symbol is not defined in a regular file, and we are
+ not generating a shared library, then set the symbol to this
+ location in the .plt. This is required to make function
+ pointers compare as equal between the normal executable and
+ the shared library. */
+ if (!bfd_link_pic (info) && !h->def_regular)
+ {
+ h->root.u.def.section = s;
+ h->root.u.def.value = h->plt.offset;
+ }
+
+ /* Make room for this entry. For now we only create the
+ small model PLT entries. We later need to find a way
+ of relaxing into these from the large model PLT entries. */
+ s->size += htab->plt_entry_size;
+
+ /* We also need to make an entry in the .got.plt section, which
+ will be placed in the .got section by the linker script. */
+ htab->root.sgotplt->size += GOT_ENTRY_SIZE;
+
+ /* We also need to make an entry in the .rela.plt section. */
+ htab->root.srelplt->size += RELOC_SIZE (htab);
+
+ /* We need to ensure that all GOT entries that serve the PLT
+ are consecutive with the special GOT slots [0] [1] and
+ [2]. Any addtional relocations, such as
+ R_AARCH64_TLSDESC, must be placed after the PLT related
+ entries. We abuse the reloc_count such that during
+ sizing we adjust reloc_count to indicate the number of
+ PLT related reserved entries. In subsequent phases when
+ filling in the contents of the reloc entries, PLT related
+ entries are placed by computing their PLT index (0
+ .. reloc_count). While other none PLT relocs are placed
+ at the slot indicated by reloc_count and reloc_count is
+ updated. */
+
+ htab->root.srelplt->reloc_count++;
+
+ /* Mark the DSO in case R_<CLS>_JUMP_SLOT relocs against
+ variant PCS symbols are present. */
+ if (h->other & STO_AARCH64_VARIANT_PCS)
+ htab->variant_pcs = 1;
+
+ }
+ else
+ {
+ h->plt.offset = (bfd_vma) - 1;
+ h->needs_plt = 0;
+ }
+ }
+ else
+ {
+ h->plt.offset = (bfd_vma) - 1;
+ h->needs_plt = 0;
+ }
+
+ eh = (struct elf_aarch64_link_hash_entry *) h;
+ eh->tlsdesc_got_jump_table_offset = (bfd_vma) - 1;
+
+ if (h->got.refcount > 0)
+ {
+ bool dyn;
+ unsigned got_type = elf_aarch64_hash_entry (h)->got_type;
+
+ h->got.offset = (bfd_vma) - 1;
+
+ dyn = htab->root.dynamic_sections_created;
+
+ /* Make sure this symbol is output as a dynamic symbol.
+ Undefined weak syms won't yet be marked as dynamic. */
+ if (dyn && h->dynindx == -1 && !h->forced_local
+ && h->root.type == bfd_link_hash_undefweak)
+ {
+ if (!bfd_elf_link_record_dynamic_symbol (info, h))
+ return false;
+ }
+
+ if (got_type == GOT_UNKNOWN)
+ {
+ }
+ else if (got_type == GOT_NORMAL)
+ {
+ h->got.offset = htab->root.sgot->size;
+ htab->root.sgot->size += GOT_ENTRY_SIZE;
+ if ((ELF_ST_VISIBILITY (h->other) == STV_DEFAULT
+ || h->root.type != bfd_link_hash_undefweak)
+ && (bfd_link_pic (info)
+ || WILL_CALL_FINISH_DYNAMIC_SYMBOL (dyn, 0, h))
+ /* Undefined weak symbol in static PIE resolves to 0 without
+ any dynamic relocations. */
+ && !UNDEFWEAK_NO_DYNAMIC_RELOC (info, h))
+ {
+ htab->root.srelgot->size += RELOC_SIZE (htab);
+ }
+ }
+ else
+ {
+ int indx;
+ if (got_type & GOT_TLSDESC_GD)
+ {
+ eh->tlsdesc_got_jump_table_offset =
+ (htab->root.sgotplt->size
+ - aarch64_compute_jump_table_size (htab));
+ htab->root.sgotplt->size += GOT_ENTRY_SIZE * 2;
+ h->got.offset = (bfd_vma) - 2;
+ }
+
+ if (got_type & GOT_TLS_GD)
+ {
+ h->got.offset = htab->root.sgot->size;
+ htab->root.sgot->size += GOT_ENTRY_SIZE * 2;
+ }
+
+ if (got_type & GOT_TLS_IE)
+ {
+ h->got.offset = htab->root.sgot->size;
+ htab->root.sgot->size += GOT_ENTRY_SIZE;
+ }
+
+ indx = h && h->dynindx != -1 ? h->dynindx : 0;
+ if ((ELF_ST_VISIBILITY (h->other) == STV_DEFAULT
+ || h->root.type != bfd_link_hash_undefweak)
+ && (!bfd_link_executable (info)
+ || indx != 0
+ || WILL_CALL_FINISH_DYNAMIC_SYMBOL (dyn, 0, h)))
+ {
+ if (got_type & GOT_TLSDESC_GD)
+ {
+ htab->root.srelplt->size += RELOC_SIZE (htab);
+ /* Note reloc_count not incremented here! We have
+ already adjusted reloc_count for this relocation
+ type. */
+
+ /* TLSDESC PLT is now needed, but not yet determined. */
+ htab->root.tlsdesc_plt = (bfd_vma) - 1;
+ }
+
+ if (got_type & GOT_TLS_GD)
+ htab->root.srelgot->size += RELOC_SIZE (htab) * 2;
+
+ if (got_type & GOT_TLS_IE)
+ htab->root.srelgot->size += RELOC_SIZE (htab);
+ }
+ }
+ }
+ else
+ {
+ h->got.offset = (bfd_vma) - 1;
+ }
+
+ if (h->dyn_relocs == NULL)
+ return true;
+
+ for (p = h->dyn_relocs; p != NULL; p = p->next)
+ if (eh->def_protected)
+ {
+ /* Disallow copy relocations against protected symbol. */
+ asection *s = p->sec->output_section;
+ if (s != NULL && (s->flags & SEC_READONLY) != 0)
+ {
+ info->callbacks->einfo
+ /* xgettext:c-format */
+ (_ ("%F%P: %pB: copy relocation against non-copyable "
+ "protected symbol `%s'\n"),
+ p->sec->owner, h->root.root.string);
+ return false;
+ }
+ }
+
+ /* In the shared -Bsymbolic case, discard space allocated for
+ dynamic pc-relative relocs against symbols which turn out to be
+ defined in regular objects. For the normal shared case, discard
+ space for pc-relative relocs that have become local due to symbol
+ visibility changes. */
+
+ if (bfd_link_pic (info))
+ {
+ /* Relocs that use pc_count are those that appear on a call
+ insn, or certain REL relocs that can generated via assembly.
+ We want calls to protected symbols to resolve directly to the
+ function rather than going via the plt. If people want
+ function pointer comparisons to work as expected then they
+ should avoid writing weird assembly. */
+ if (SYMBOL_CALLS_LOCAL (info, h))
+ {
+ struct elf_dyn_relocs **pp;
+
+ for (pp = &h->dyn_relocs; (p = *pp) != NULL;)
+ {
+ p->count -= p->pc_count;
+ p->pc_count = 0;
+ if (p->count == 0)
+ *pp = p->next;
+ else
+ pp = &p->next;
+ }
+ }
+
+ /* Also discard relocs on undefined weak syms with non-default
+ visibility. */
+ if (h->dyn_relocs != NULL && h->root.type == bfd_link_hash_undefweak)
+ {
+ if (ELF_ST_VISIBILITY (h->other) != STV_DEFAULT
+ || UNDEFWEAK_NO_DYNAMIC_RELOC (info, h))
+ h->dyn_relocs = NULL;
+
+ /* Make sure undefined weak symbols are output as a dynamic
+ symbol in PIEs. */
+ else if (h->dynindx == -1
+ && !h->forced_local
+ && h->root.type == bfd_link_hash_undefweak
+ && !bfd_elf_link_record_dynamic_symbol (info, h))
+ return false;
+ }
+
+ }
+ else if (ELIMINATE_COPY_RELOCS)
+ {
+ /* For the non-shared case, discard space for relocs against
+ symbols which turn out to need copy relocs or are not
+ dynamic. */
+
+ if (!h->non_got_ref
+ && ((h->def_dynamic
+ && !h->def_regular)
+ || (htab->root.dynamic_sections_created
+ && (h->root.type == bfd_link_hash_undefweak
+ || h->root.type == bfd_link_hash_undefined))))
+ {
+ /* Make sure this symbol is output as a dynamic symbol.
+ Undefined weak syms won't yet be marked as dynamic. */
+ if (h->dynindx == -1
+ && !h->forced_local
+ && h->root.type == bfd_link_hash_undefweak
+ && !bfd_elf_link_record_dynamic_symbol (info, h))
+ return false;
+
+ /* If that succeeded, we know we'll be keeping all the
+ relocs. */
+ if (h->dynindx != -1)
+ goto keep;
+ }
+
+ h->dyn_relocs = NULL;
+
+ keep:;
+ }
+
+ /* Finally, allocate space. */
+ for (p = h->dyn_relocs; p != NULL; p = p->next)
+ {
+ asection *sreloc;
+
+ sreloc = elf_section_data (p->sec)->sreloc;
+
+ BFD_ASSERT (sreloc != NULL);
+
+ sreloc->size += p->count * RELOC_SIZE (htab);
+ }
+
+ return true;
+}
+
+/* Allocate space in .plt, .got and associated reloc sections for
+ ifunc dynamic relocs. */
+
+static bool
+elfNN_aarch64_allocate_ifunc_dynrelocs (struct elf_link_hash_entry *h,
+ void *inf)
+{
+ struct bfd_link_info *info;
+ struct elf_aarch64_link_hash_table *htab;
+
+ /* An example of a bfd_link_hash_indirect symbol is versioned
+ symbol. For example: __gxx_personality_v0(bfd_link_hash_indirect)
+ -> __gxx_personality_v0(bfd_link_hash_defined)
+
+ There is no need to process bfd_link_hash_indirect symbols here
+ because we will also be presented with the concrete instance of
+ the symbol and elfNN_aarch64_copy_indirect_symbol () will have been
+ called to copy all relevant data from the generic to the concrete
+ symbol instance. */
+ if (h->root.type == bfd_link_hash_indirect)
+ return true;
+
+ if (h->root.type == bfd_link_hash_warning)
+ h = (struct elf_link_hash_entry *) h->root.u.i.link;
+
+ info = (struct bfd_link_info *) inf;
+ htab = elf_aarch64_hash_table (info);
+
+ /* Since STT_GNU_IFUNC symbol must go through PLT, we handle it
+ here if it is defined and referenced in a non-shared object. */
+ if (h->type == STT_GNU_IFUNC
+ && h->def_regular)
+ return _bfd_elf_allocate_ifunc_dyn_relocs (info, h,
+ &h->dyn_relocs,
+ htab->plt_entry_size,
+ htab->plt_header_size,
+ GOT_ENTRY_SIZE,
+ false);
+ return true;
+}
+
+/* Allocate space in .plt, .got and associated reloc sections for
+ local ifunc dynamic relocs. */
+
+static int
+elfNN_aarch64_allocate_local_ifunc_dynrelocs (void **slot, void *inf)
+{
+ struct elf_link_hash_entry *h
+ = (struct elf_link_hash_entry *) *slot;
+
+ if (h->type != STT_GNU_IFUNC
+ || !h->def_regular
+ || !h->ref_regular
+ || !h->forced_local
+ || h->root.type != bfd_link_hash_defined)
+ abort ();
+
+ return elfNN_aarch64_allocate_ifunc_dynrelocs (h, inf);
+}
+
+/* Record a relative relocation that will be emitted packed (DT_RELR).
+ Called after relocation sections are sized, so undo the size accounting
+ for this relocation. */
+
+static bool
+record_relr (struct elf_aarch64_link_hash_table *htab, asection *sec,
+ bfd_vma off, asection *sreloc)
+{
+ /* Undo the relocation section size accounting. */
+ BFD_ASSERT (sreloc->size >= RELOC_SIZE (htab));
+ sreloc->size -= RELOC_SIZE (htab);
+ /* The packing format uses the last bit of the address so that
+ must be aligned. We don't pack relocations that may not be
+ aligned even though the final output address could end up
+ aligned, to avoid complex sizing logic for a rare case. */
+ BFD_ASSERT (off % 2 == 0 && sec->alignment_power > 0);
+ if (htab->relr_count >= htab->relr_alloc)
+ {
+ if (htab->relr_alloc == 0)
+ htab->relr_alloc = 4096;
+ else
+ htab->relr_alloc *= 2;
+ htab->relr = bfd_realloc (htab->relr,
+ htab->relr_alloc * sizeof (*htab->relr));
+ if (htab->relr == NULL)
+ return false;
+ }
+ htab->relr[htab->relr_count].sec = sec;
+ htab->relr[htab->relr_count].off = off;
+ htab->relr_count++;
+ return true;
+}
+
+/* Follow elfNN_aarch64_allocate_dynrelocs, but only record relative
+ relocations against the GOT and undo their previous size accounting. */
+
+static bool
+record_relr_dyn_got_relocs (struct elf_link_hash_entry *h, void *inf)
+{
+
+ if (h->root.type == bfd_link_hash_indirect)
+ return true;
+ if (h->root.type == bfd_link_hash_warning)
+ h = (struct elf_link_hash_entry *) h->root.u.i.link;
+ if (h->type == STT_GNU_IFUNC && h->def_regular)
+ return true;
+ if (h->got.refcount <= 0)
+ return true;
+ if (elf_aarch64_hash_entry (h)->got_type != GOT_NORMAL)
+ return true;
+
+ struct bfd_link_info *info = (struct bfd_link_info *) inf;
+ struct elf_aarch64_link_hash_table *htab = elf_aarch64_hash_table (info);
+
+ if ((ELF_ST_VISIBILITY (h->other) == STV_DEFAULT
+ || h->root.type != bfd_link_hash_undefweak)
+ && bfd_link_pic (info)
+ /* Undefined weak symbol in static PIE resolves to 0 without
+ any dynamic relocations. */
+ && !UNDEFWEAK_NO_DYNAMIC_RELOC (info, h))
+ {
+ bool relative_reloc = SYMBOL_REFERENCES_LOCAL (info, h)
+ && !bfd_is_abs_symbol (&h->root);
+ if (relative_reloc)
+ if (!record_relr (htab, htab->root.sgot, h->got.offset,
+ htab->root.srelgot))
+ return false;
+ }
+ return true;
+}
+
+/* Record packed relative relocs against the GOT for local symbols.
+ Undo the size accounting of elfNN_aarch64_late_size_sections. */
+
+static bool
+record_relr_local_got_relocs (bfd *input_bfd, struct bfd_link_info *info)
+{
+ struct elf_aarch64_local_symbol *locals;
+ Elf_Internal_Shdr *symtab_hdr;
+ struct elf_aarch64_link_hash_table *htab;
+
+ if (!bfd_link_pic (info))
+ return true;
+
+ locals = elf_aarch64_locals (input_bfd);
+ if (locals == NULL)
+ return true;
+
+ symtab_hdr = &elf_symtab_hdr (input_bfd);
+ htab = elf_aarch64_hash_table (info);
+ for (unsigned int i = 0; i < symtab_hdr->sh_info; i++)
+ {
+ bfd_vma off = locals[i].got_offset;
+ if (locals[i].got_refcount <= 0)
+ continue;
+ if ((locals[i].got_type & GOT_NORMAL) == 0)
+ continue;
+
+ /* FIXME: If the local symbol is in SHN_ABS then emitting
+ a relative relocation is not correct, but it seems to
+ be wrong in elfNN_aarch64_final_link_relocate too. */
+ if (!record_relr (htab, htab->root.sgot, off, htab->root.srelgot))
+ return false;
+ }
+ return true;
+}
+
+/* Follows the logic of elfNN_aarch64_relocate_section to decide which
+ relocations will become relative and possible to pack. Ignore
+ relocations against the GOT, those are handled separately per-symbol.
+ Undo the size accounting of the packed relocations and record them
+ so the relr section can be sized later. */
+
+static bool
+record_relr_non_got_relocs (bfd *input_bfd, struct bfd_link_info *info,
+ asection *sec)
+{
+ const Elf_Internal_Rela *relocs;
+ const Elf_Internal_Rela *rel;
+ const Elf_Internal_Rela *rel_end;
+ asection *sreloc;
+ struct elf_aarch64_link_hash_table *htab;
+ Elf_Internal_Shdr *symtab_hdr;
+ struct elf_link_hash_entry **sym_hashes;
+
+ if (sec->reloc_count == 0)
+ return true;
+ if ((sec->flags & (SEC_RELOC | SEC_ALLOC | SEC_DEBUGGING))
+ != (SEC_RELOC | SEC_ALLOC))
+ return true;
+ if (sec->alignment_power == 0)
+ return true;
+ if (discarded_section (sec))
+ return true;
+ sreloc = elf_section_data (sec)->sreloc;
+ if (sreloc == NULL)
+ return true;
+ htab = elf_aarch64_hash_table (info);
+ symtab_hdr = &elf_symtab_hdr (input_bfd);
+ sym_hashes = elf_sym_hashes (input_bfd);
+ relocs = _bfd_elf_link_info_read_relocs (input_bfd, info, sec, NULL, NULL,
+ info->keep_memory);
+ BFD_ASSERT (relocs != NULL);
+ rel_end = relocs + sec->reloc_count;
+ for (rel = relocs; rel < rel_end; rel++)
+ {
+ unsigned int r_symndx = ELFNN_R_SYM (rel->r_info);
+ unsigned int r_type = ELFNN_R_TYPE (rel->r_info);
+
+ bfd_reloc_code_real_type bfd_r_type
+ = elfNN_aarch64_bfd_reloc_from_type (input_bfd, r_type);
+ /* Handle relocs that can become R_AARCH64_RELATIVE,
+ but not ones against the GOT as those are handled
+ separately per-symbol. */
+ if (bfd_r_type != BFD_RELOC_AARCH64_NN)
+ continue;
+ /* Can only pack relocation against an aligned address. */
+ if (rel->r_offset % 2 != 0)
+ continue;
+
+ struct elf_link_hash_entry *h = NULL;
+ asection *def_sec = NULL;
+ bool resolved_to_zero = false;
+ if (r_symndx < symtab_hdr->sh_info)
+ {
+ /* A local symbol. */
+ Elf_Internal_Sym *isym;
+ isym = bfd_sym_from_r_symndx (&htab->root.sym_cache,
+ input_bfd, r_symndx);
+ BFD_ASSERT (isym != NULL);
+ if (ELF_ST_TYPE (isym->st_info) == STT_GNU_IFUNC)
+ continue;
+ def_sec = bfd_section_from_elf_index (input_bfd, isym->st_shndx);
+ }
+ else
+ {
+ h = sym_hashes[r_symndx - symtab_hdr->sh_info];
+ while (h->root.type == bfd_link_hash_indirect
+ || h->root.type == bfd_link_hash_warning)
+ h = (struct elf_link_hash_entry *) h->root.u.i.link;
+
+ /* Filter out symbols that cannot have a relative reloc. */
+ if (h->dyn_relocs == NULL)
+ continue;
+ if (bfd_is_abs_symbol (&h->root))
+ continue;
+ if (h->type == STT_GNU_IFUNC)
+ continue;
+
+ if (h->root.type == bfd_link_hash_defined
+ || h->root.type == bfd_link_hash_defweak)
+ def_sec = h->root.u.def.section;
+ resolved_to_zero = UNDEFWEAK_NO_DYNAMIC_RELOC (info, h);
+ }
+ if (def_sec != NULL && discarded_section (def_sec))
+ continue;
+ /* Same logic as in elfNN_aarch64_final_link_relocate.
+ Except conditionals trimmed that cannot result a reltive reloc. */
+ if (bfd_link_pic (info)
+ && (h == NULL
+ || (ELF_ST_VISIBILITY (h->other) == STV_DEFAULT
+ && !resolved_to_zero)
+ || h->root.type != bfd_link_hash_undefweak))
+ {
+ if (h != NULL
+ && h->dynindx != -1
+ && (!(bfd_link_pie (info) || SYMBOLIC_BIND (info, h))
+ || !h->def_regular))
+ continue;
+ if (!record_relr (htab, sec, rel->r_offset, sreloc))
+ return false;
+ }
+ }
+ return true;
+}
+
+static int
+cmp_relr_addr (const void *p, const void *q)
+{
+ const bfd_vma *a = p;
+ const bfd_vma *b = q;
+ return *a < *b ? -1 : *a > *b ? 1 : 0;
+}
+
+/* Produce a malloc'd sorted array of reloc addresses in htab->relr_sorted.
+ Returns false on allocation failure. */
+
+static bool
+sort_relr (struct bfd_link_info *info,
+ struct elf_aarch64_link_hash_table *htab)
+{
+ if (htab->relr_count == 0)
+ return true;
+
+ bfd_vma *addr = htab->relr_sorted;
+ if (addr == NULL)
+ {
+ addr = bfd_malloc (htab->relr_count * sizeof (*addr));
+ if (addr == NULL)
+ return false;
+ htab->relr_sorted = addr;
+ }
+
+ for (bfd_size_type i = 0; i < htab->relr_count; i++)
+ {
+ bfd_vma off = _bfd_elf_section_offset (info->output_bfd, info,
+ htab->relr[i].sec,
+ htab->relr[i].off);
+ addr[i] = htab->relr[i].sec->output_section->vma
+ + htab->relr[i].sec->output_offset
+ + off;
+ }
+ qsort (addr, htab->relr_count, sizeof (*addr), cmp_relr_addr);
+ return true;
+}
+
+/* Size of a relr entry and a relocated location. */
+#define RELR_SZ (ARCH_SIZE / 8)
+/* Number of consecutive locations a relr bitmap entry references. */
+#define RELR_N (ARCH_SIZE - 1)
+
+/* Size .relr.dyn whenever the layout changes, the number of packed
+ relocs are unchanged but the packed representation can. */
+
+bool
+elfNN_aarch64_size_relative_relocs (struct bfd_link_info *info,
+ bool *need_layout)
+{
+ struct elf_aarch64_link_hash_table *htab = elf_aarch64_hash_table (info);
+ asection *srelrdyn = htab->root.srelrdyn;
+ *need_layout = false;
+
+ if (!sort_relr (info, htab))
+ return false;
+ bfd_vma *addr = htab->relr_sorted;
+
+ BFD_ASSERT (srelrdyn != NULL);
+ bfd_size_type oldsize = srelrdyn->size;
+ srelrdyn->size = 0;
+ for (bfd_size_type i = 0; i < htab->relr_count; )
+ {
+ bfd_vma base = addr[i];
+ i++;
+ srelrdyn->size += RELR_SZ;
+ base += RELR_SZ;
+ for (;;)
+ {
+ bfd_size_type start_i = i;
+ while (i < htab->relr_count
+ && addr[i] - base < RELR_N * RELR_SZ
+ && (addr[i] - base) % RELR_SZ == 0)
+ i++;
+ if (i == start_i)
+ break;
+ srelrdyn->size += RELR_SZ;
+ base += RELR_N * RELR_SZ;
+ }
+ }
+ if (srelrdyn->size != oldsize)
+ {
+ *need_layout = true;
+ /* Stop after a few iterations in case the layout does not converge,
+ we can do this when the size would shrink. */
+ if (htab->relr_layout_iter++ > 5 && srelrdyn->size < oldsize)
+ {
+ srelrdyn->size = oldsize;
+ *need_layout = false;
+ }
+ }
+ return true;
+}
+
+/* Emit the .relr.dyn section after it is sized and the layout is fixed. */
+
+bool
+elfNN_aarch64_finish_relative_relocs (struct bfd_link_info *info)
+{
+ struct elf_aarch64_link_hash_table *htab = elf_aarch64_hash_table (info);
+ asection *srelrdyn = htab->root.srelrdyn;
+ bfd *dynobj = htab->root.dynobj;
+
+ if (srelrdyn == NULL || srelrdyn->size == 0)
+ return true;
+ srelrdyn->contents = bfd_alloc (dynobj, srelrdyn->size);
+ if (srelrdyn->contents == NULL)
+ return false;
+ bfd_vma *addr = htab->relr_sorted;
+ bfd_byte *loc = srelrdyn->contents;
+ for (bfd_size_type i = 0; i < htab->relr_count; )
+ {
+ bfd_vma base = addr[i];
+ i++;
+ bfd_put_NN (dynobj, base, loc);
+ loc += RELR_SZ;
+ base += RELR_SZ;
+ for (;;)
+ {
+ bfd_vma bits = 0;
+ while (i < htab->relr_count)
+ {
+ bfd_vma delta = addr[i] - base;
+ if (delta >= RELR_N * RELR_SZ || delta % RELR_SZ != 0)
+ break;
+ bits |= (bfd_vma) 1 << (delta / RELR_SZ);
+ i++;
+ }
+ if (bits == 0)
+ break;
+ bfd_put_NN (dynobj, (bits << 1) | 1, loc);
+ loc += RELR_SZ;
+ base += RELR_N * RELR_SZ;
+ }
+ }
+ free (addr);
+ htab->relr_sorted = NULL;
+ /* Pad any excess with 1's, a do-nothing encoding. */
+ while (loc < srelrdyn->contents + srelrdyn->size)
+ {
+ bfd_put_NN (dynobj, 1, loc);
+ loc += RELR_SZ;
+ }
+ return true;
+}
+
+/* This is the most important function of all . Innocuosly named
+ though ! */
+
+static bool
+elfNN_aarch64_late_size_sections (bfd *output_bfd ATTRIBUTE_UNUSED,
+ struct bfd_link_info *info)
+{
+ struct elf_aarch64_link_hash_table *htab;
+ bfd *dynobj;
+ asection *s;
+ bool relocs;
+ bfd *ibfd;
+
+ htab = elf_aarch64_hash_table ((info));
+ dynobj = htab->root.dynobj;
+
+ if (dynobj == NULL)
+ return true;
+
+ if (htab->root.dynamic_sections_created)
+ {
+ if (bfd_link_executable (info) && !info->nointerp)
+ {
+ s = bfd_get_linker_section (dynobj, ".interp");
+ if (s == NULL)
+ abort ();
+ s->size = sizeof ELF_DYNAMIC_INTERPRETER;
+ s->contents = (unsigned char *) ELF_DYNAMIC_INTERPRETER;
+ }
+ }
+
+ /* Set up .got offsets for local syms, and space for local dynamic
+ relocs. */
+ for (ibfd = info->input_bfds; ibfd != NULL; ibfd = ibfd->link.next)
+ {
+ struct elf_aarch64_local_symbol *locals = NULL;
+ Elf_Internal_Shdr *symtab_hdr;
+ asection *srel;
+ unsigned int i;
+
+ if (!is_aarch64_elf (ibfd))
+ continue;
+
+ for (s = ibfd->sections; s != NULL; s = s->next)
+ {
+ struct elf_dyn_relocs *p;
+
+ for (p = (struct elf_dyn_relocs *)
+ (elf_section_data (s)->local_dynrel); p != NULL; p = p->next)
+ {
+ if (discarded_section (p->sec))
+ {
+ /* Input section has been discarded, either because
+ it is a copy of a linkonce section or due to
+ linker script /DISCARD/, so we'll be discarding
+ the relocs too. */
+ }
+ else if (p->count != 0)
+ {
+ srel = elf_section_data (p->sec)->sreloc;
+ srel->size += p->count * RELOC_SIZE (htab);
+ if ((p->sec->output_section->flags & SEC_READONLY) != 0)
+ info->flags |= DF_TEXTREL;
+ }
+ }
+ }
+
+ locals = elf_aarch64_locals (ibfd);
+ if (!locals)
+ continue;
+
+ symtab_hdr = &elf_symtab_hdr (ibfd);
+ srel = htab->root.srelgot;
+ for (i = 0; i < symtab_hdr->sh_info; i++)
+ {
+ locals[i].got_offset = (bfd_vma) - 1;
+ locals[i].tlsdesc_got_jump_table_offset = (bfd_vma) - 1;
+ if (locals[i].got_refcount > 0)
+ {
+ unsigned got_type = locals[i].got_type;
+ if (got_type & GOT_TLSDESC_GD)
+ {
+ locals[i].tlsdesc_got_jump_table_offset =
+ (htab->root.sgotplt->size
+ - aarch64_compute_jump_table_size (htab));
+ htab->root.sgotplt->size += GOT_ENTRY_SIZE * 2;
+ locals[i].got_offset = (bfd_vma) - 2;
+ }
+
+ if (got_type & GOT_TLS_GD)
+ {
+ locals[i].got_offset = htab->root.sgot->size;
+ htab->root.sgot->size += GOT_ENTRY_SIZE * 2;
+ }
+
+ if (got_type & GOT_TLS_IE
+ || got_type & GOT_NORMAL)
+ {
+ locals[i].got_offset = htab->root.sgot->size;
+ htab->root.sgot->size += GOT_ENTRY_SIZE;
+ }
+
+ if (got_type == GOT_UNKNOWN)
+ {
+ }
+
+ if (bfd_link_pic (info))
+ {
+ if (got_type & GOT_TLSDESC_GD)
+ {
+ htab->root.srelplt->size += RELOC_SIZE (htab);
+ /* Note RELOC_COUNT not incremented here! */
+ htab->root.tlsdesc_plt = (bfd_vma) - 1;
+ }
+
+ if (got_type & GOT_TLS_GD)
+ htab->root.srelgot->size += RELOC_SIZE (htab) * 2;
+
+ if (got_type & GOT_TLS_IE
+ || got_type & GOT_NORMAL)
+ htab->root.srelgot->size += RELOC_SIZE (htab);
+ }
+ }
+ else
+ {
+ locals[i].got_refcount = (bfd_vma) - 1;
+ }
+ }
+ }
+
+
+ /* Allocate global sym .plt and .got entries, and space for global
+ sym dynamic relocs. */
+ elf_link_hash_traverse (&htab->root, elfNN_aarch64_allocate_dynrelocs,
+ info);
+
+ /* Allocate global ifunc sym .plt and .got entries, and space for global
+ ifunc sym dynamic relocs. */
+ elf_link_hash_traverse (&htab->root, elfNN_aarch64_allocate_ifunc_dynrelocs,
+ info);
+
+ /* Allocate .plt and .got entries, and space for local ifunc symbols. */
+ htab_traverse (htab->loc_hash_table,
+ elfNN_aarch64_allocate_local_ifunc_dynrelocs,
+ info);
+
+ /* For every jump slot reserved in the sgotplt, reloc_count is
+ incremented. However, when we reserve space for TLS descriptors,
+ it's not incremented, so in order to compute the space reserved
+ for them, it suffices to multiply the reloc count by the jump
+ slot size. */
+
+ if (htab->root.srelplt)
+ htab->sgotplt_jump_table_size = aarch64_compute_jump_table_size (htab);
+
+ if (htab->root.tlsdesc_plt)
+ {
+ if (htab->root.splt->size == 0)
+ htab->root.splt->size += htab->plt_header_size;
+
+ /* If we're not using lazy TLS relocations, don't generate the
+ GOT and PLT entry required. */
+ if ((info->flags & DF_BIND_NOW))
+ htab->root.tlsdesc_plt = 0;
+ else
+ {
+ htab->root.tlsdesc_plt = htab->root.splt->size;
+ htab->root.splt->size += htab->tlsdesc_plt_entry_size;
+
+ htab->root.tlsdesc_got = htab->root.sgot->size;
+ htab->root.sgot->size += GOT_ENTRY_SIZE;
+ }
+ }
+
+ /* Record the relative relocations that will be packed and undo the
+ size allocation for them in .rela.*. The size of .relr.dyn will be
+ computed later iteratively since it depends on the final layout. */
+ if (info->enable_dt_relr && !bfd_link_relocatable (info))
+ {
+ elf_link_hash_traverse (&htab->root, record_relr_dyn_got_relocs, info);
+
+ for (ibfd = info->input_bfds; ibfd != NULL; ibfd = ibfd->link.next)
+ {
+ if (!is_aarch64_elf (ibfd))
+ continue;
+
+ for (s = ibfd->sections; s != NULL; s = s->next)
+ if (!record_relr_non_got_relocs (ibfd, info, s))
+ return false;
+
+ if (!record_relr_local_got_relocs (ibfd, info))
+ return false;
+ }
+ }
+
+ /* Init mapping symbols information to use later to distingush between
+ code and data while scanning for errata. */
+ if (htab->fix_erratum_835769 || htab->fix_erratum_843419)
+ for (ibfd = info->input_bfds; ibfd != NULL; ibfd = ibfd->link.next)
+ {
+ if (!is_aarch64_elf (ibfd))
+ continue;
+ bfd_elfNN_aarch64_init_maps (ibfd);
+ }
+
+ /* We now have determined the sizes of the various dynamic sections.
+ Allocate memory for them. */
+ relocs = false;
+ for (s = dynobj->sections; s != NULL; s = s->next)
+ {
+ if ((s->flags & SEC_LINKER_CREATED) == 0)
+ continue;
+
+ if (s == htab->root.splt
+ || s == htab->root.sgot
+ || s == htab->root.sgotplt
+ || s == htab->root.iplt
+ || s == htab->root.igotplt
+ || s == htab->root.sdynbss
+ || s == htab->root.sdynrelro)
+ {
+ /* Strip this section if we don't need it; see the
+ comment below. */
+ }
+ else if (startswith (bfd_section_name (s), ".rela"))
+ {
+ if (s->size != 0 && s != htab->root.srelplt)
+ relocs = true;
+
+ /* We use the reloc_count field as a counter if we need
+ to copy relocs into the output file. */
+ if (s != htab->root.srelplt)
+ s->reloc_count = 0;
+ }
+ else if (s == htab->root.srelrdyn)
+ {
+ /* Remove .relr.dyn based on relr_count, not size, since
+ it is not sized yet. */
+ if (htab->relr_count == 0)
+ s->flags |= SEC_EXCLUDE;
+ else
+ /* Force dynamic tags for relocs even if there are no
+ .rela* relocs, required for setting DT_TEXTREL. */
+ relocs = true;
+ /* Allocate contents later. */
+ continue;
+ }
+ else
+ {
+ /* It's not one of our sections, so don't allocate space. */
+ continue;
+ }
+
+ if (s->size == 0)
+ {
+ /* If we don't need this section, strip it from the
+ output file. This is mostly to handle .rela.bss and
+ .rela.plt. We must create both sections in
+ create_dynamic_sections, because they must be created
+ before the linker maps input sections to output
+ sections. The linker does that before
+ adjust_dynamic_symbol is called, and it is that
+ function which decides whether anything needs to go
+ into these sections. */
+ s->flags |= SEC_EXCLUDE;
+ continue;
+ }
+
+ if ((s->flags & SEC_HAS_CONTENTS) == 0)
+ continue;
+
+ /* Allocate memory for the section contents. We use bfd_zalloc
+ here in case unused entries are not reclaimed before the
+ section's contents are written out. This should not happen,
+ but this way if it does, we get a R_AARCH64_NONE reloc instead
+ of garbage. */
+ s->contents = (bfd_byte *) bfd_zalloc (dynobj, s->size);
+ if (s->contents == NULL)
+ return false;
+ }
+
+ if (htab->root.dynamic_sections_created)
+ {
+ /* Add some entries to the .dynamic section. We fill in the
+ values later, in elfNN_aarch64_finish_dynamic_sections, but we
+ must add the entries now so that we get the correct size for
+ the .dynamic section. The DT_DEBUG entry is filled in by the
+ dynamic linker and used by the debugger. */
+#define add_dynamic_entry(TAG, VAL) \
+ _bfd_elf_add_dynamic_entry (info, TAG, VAL)
+
+ if (!_bfd_elf_add_dynamic_tags (output_bfd, info, relocs))
+ return false;
+
+ if (htab->root.splt->size != 0)
+ {
+ if (htab->variant_pcs
+ && !add_dynamic_entry (DT_AARCH64_VARIANT_PCS, 0))
+ return false;
+
+ aarch64_plt_type plt_type
+ = elf_aarch64_tdata (output_bfd)->sw_protections.plt_type;
+ if ((plt_type == PLT_BTI_PAC)
+ && (!add_dynamic_entry (DT_AARCH64_BTI_PLT, 0)
+ || !add_dynamic_entry (DT_AARCH64_PAC_PLT, 0)))
+ return false;
+
+ else if ((plt_type == PLT_BTI)
+ && !add_dynamic_entry (DT_AARCH64_BTI_PLT, 0))
+ return false;
+
+ else if ((plt_type == PLT_PAC)
+ && !add_dynamic_entry (DT_AARCH64_PAC_PLT, 0))
+ return false;
+ }
+ }
+#undef add_dynamic_entry
+
+ return true;
+}
+
+static inline void
+elf_aarch64_update_plt_entry (bfd *output_bfd,
+ bfd_reloc_code_real_type r_type,
+ bfd_byte *plt_entry, bfd_vma value)
+{
+ reloc_howto_type *howto = elfNN_aarch64_howto_from_bfd_reloc (r_type);
+
+ /* FIXME: We should check the return value from this function call. */
+ (void) _bfd_aarch64_elf_put_addend (output_bfd, plt_entry, r_type, howto, value);
+}
+
+static void
+elfNN_aarch64_create_small_pltn_entry (struct elf_link_hash_entry *h,
+ struct elf_aarch64_link_hash_table
+ *htab, bfd *output_bfd,
+ struct bfd_link_info *info)
+{
+ bfd_byte *plt_entry;
+ bfd_vma plt_index;
+ bfd_vma got_offset;
+ bfd_vma gotplt_entry_address;
+ bfd_vma plt_entry_address;
+ Elf_Internal_Rela rela;
+ bfd_byte *loc;
+ asection *plt, *gotplt, *relplt;
+
+ /* When building a static executable, use .iplt, .igot.plt and
+ .rela.iplt sections for STT_GNU_IFUNC symbols. */
+ if (htab->root.splt != NULL)
+ {
+ plt = htab->root.splt;
+ gotplt = htab->root.sgotplt;
+ relplt = htab->root.srelplt;
+ }
+ else
+ {
+ plt = htab->root.iplt;
+ gotplt = htab->root.igotplt;
+ relplt = htab->root.irelplt;
+ }
+
+ /* Get the index in the procedure linkage table which
+ corresponds to this symbol. This is the index of this symbol
+ in all the symbols for which we are making plt entries. The
+ first entry in the procedure linkage table is reserved.
+
+ Get the offset into the .got table of the entry that
+ corresponds to this function. Each .got entry is GOT_ENTRY_SIZE
+ bytes. The first three are reserved for the dynamic linker.
+
+ For static executables, we don't reserve anything. */
+
+ if (plt == htab->root.splt)
+ {
+ plt_index = (h->plt.offset - htab->plt_header_size) / htab->plt_entry_size;
+ got_offset = (plt_index + 3) * GOT_ENTRY_SIZE;
+ }
+ else
+ {
+ plt_index = h->plt.offset / htab->plt_entry_size;
+ got_offset = plt_index * GOT_ENTRY_SIZE;
+ }
+
+ plt_entry = plt->contents + h->plt.offset;
+ plt_entry_address = plt->output_section->vma
+ + plt->output_offset + h->plt.offset;
+ gotplt_entry_address = gotplt->output_section->vma +
+ gotplt->output_offset + got_offset;
+
+ /* Copy in the boiler-plate for the PLTn entry. */
+ memcpy (plt_entry, htab->plt_entry, htab->plt_entry_size);
+
+ /* Allow for any delta (such as a BTI instruction) before the common
+ sequence. */
+ plt_entry += htab->plt_entry_delta;
+
+ /* Fill in the top 21 bits for this: ADRP x16, PLT_GOT + n * 8.
+ ADRP: ((PG(S+A)-PG(P)) >> 12) & 0x1fffff */
+ elf_aarch64_update_plt_entry (output_bfd, BFD_RELOC_AARCH64_ADR_HI21_PCREL,
+ plt_entry,
+ PG (gotplt_entry_address) -
+ PG (plt_entry_address));
+
+ /* Fill in the lo12 bits for the load from the pltgot. */
+ elf_aarch64_update_plt_entry (output_bfd, BFD_RELOC_AARCH64_LDSTNN_LO12,
+ plt_entry + 4,
+ PG_OFFSET (gotplt_entry_address));
+
+ /* Fill in the lo12 bits for the add from the pltgot entry. */
+ elf_aarch64_update_plt_entry (output_bfd, BFD_RELOC_AARCH64_ADD_LO12,
+ plt_entry + 8,
+ PG_OFFSET (gotplt_entry_address));
+
+ /* All the GOTPLT Entries are essentially initialized to PLT0. */
+ bfd_put_NN (output_bfd,
+ plt->output_section->vma + plt->output_offset,
+ gotplt->contents + got_offset);
+
+ rela.r_offset = gotplt_entry_address;
+
+ if (h->dynindx == -1
+ || ((bfd_link_executable (info)
+ || ELF_ST_VISIBILITY (h->other) != STV_DEFAULT)
+ && h->def_regular
+ && h->type == STT_GNU_IFUNC))
+ {
+ /* If an STT_GNU_IFUNC symbol is locally defined, generate
+ R_AARCH64_IRELATIVE instead of R_AARCH64_JUMP_SLOT. */
+ rela.r_info = ELFNN_R_INFO (0, AARCH64_R (IRELATIVE));
+ rela.r_addend = (h->root.u.def.value
+ + h->root.u.def.section->output_section->vma
+ + h->root.u.def.section->output_offset);
+ }
+ else
+ {
+ /* Fill in the entry in the .rela.plt section. */
+ rela.r_info = ELFNN_R_INFO (h->dynindx, AARCH64_R (JUMP_SLOT));
+ rela.r_addend = 0;
+ }
+
+ /* Compute the relocation entry to used based on PLT index and do
+ not adjust reloc_count. The reloc_count has already been adjusted
+ to account for this entry. */
+ loc = relplt->contents + plt_index * RELOC_SIZE (htab);
+ bfd_elfNN_swap_reloca_out (output_bfd, &rela, loc);
+}
+
+/* Size sections even though they're not dynamic. We use it to setup
+ _TLS_MODULE_BASE_, if needed. */
+
+static bool
+elfNN_aarch64_early_size_sections (bfd *output_bfd,
+ struct bfd_link_info *info)
+{
+ asection *tls_sec;
+
+ if (bfd_link_relocatable (info))
+ return true;
+
+ tls_sec = elf_hash_table (info)->tls_sec;
+
+ if (tls_sec)
+ {
+ struct elf_link_hash_entry *tlsbase;
+
+ tlsbase = elf_link_hash_lookup (elf_hash_table (info),
+ "_TLS_MODULE_BASE_", true, true, false);
+
+ if (tlsbase)
+ {
+ struct bfd_link_hash_entry *h = NULL;
+ const struct elf_backend_data *bed =
+ get_elf_backend_data (output_bfd);
+
+ if (!(_bfd_generic_link_add_one_symbol
+ (info, output_bfd, "_TLS_MODULE_BASE_", BSF_LOCAL,
+ tls_sec, 0, NULL, false, bed->collect, &h)))
+ return false;
+
+ tlsbase->type = STT_TLS;
+ tlsbase = (struct elf_link_hash_entry *) h;
+ tlsbase->def_regular = 1;
+ tlsbase->other = STV_HIDDEN;
+ (*bed->elf_backend_hide_symbol) (info, tlsbase, true);
+ }
+ }
+
+ return true;
+}
+
+/* Finish up dynamic symbol handling. We set the contents of various
+ dynamic sections here. */
+
+static bool
+elfNN_aarch64_finish_dynamic_symbol (bfd *output_bfd,
+ struct bfd_link_info *info,
+ struct elf_link_hash_entry *h,
+ Elf_Internal_Sym *sym)
+{
+ struct elf_aarch64_link_hash_table *htab;
+ htab = elf_aarch64_hash_table (info);
+
+ if (h->plt.offset != (bfd_vma) - 1)
+ {
+ asection *plt, *gotplt, *relplt;
+
+ /* This symbol has an entry in the procedure linkage table. Set
+ it up. */
+
+ /* When building a static executable, use .iplt, .igot.plt and
+ .rela.iplt sections for STT_GNU_IFUNC symbols. */
+ if (htab->root.splt != NULL)
+ {
+ plt = htab->root.splt;
+ gotplt = htab->root.sgotplt;
+ relplt = htab->root.srelplt;
+ }
+ else
+ {
+ plt = htab->root.iplt;
+ gotplt = htab->root.igotplt;
+ relplt = htab->root.irelplt;
+ }
+
+ /* This symbol has an entry in the procedure linkage table. Set
+ it up. */
+ if ((h->dynindx == -1
+ && !((h->forced_local || bfd_link_executable (info))
+ && h->def_regular
+ && h->type == STT_GNU_IFUNC))
+ || plt == NULL
+ || gotplt == NULL
+ || relplt == NULL)
+ abort ();
+
+ elfNN_aarch64_create_small_pltn_entry (h, htab, output_bfd, info);
+ if (!h->def_regular)
+ {
+ /* Mark the symbol as undefined, rather than as defined in
+ the .plt section. */
+ sym->st_shndx = SHN_UNDEF;
+ /* If the symbol is weak we need to clear the value.
+ Otherwise, the PLT entry would provide a definition for
+ the symbol even if the symbol wasn't defined anywhere,
+ and so the symbol would never be NULL. Leave the value if
+ there were any relocations where pointer equality matters
+ (this is a clue for the dynamic linker, to make function
+ pointer comparisons work between an application and shared
+ library). */
+ if (!h->ref_regular_nonweak || !h->pointer_equality_needed)
+ sym->st_value = 0;
+ }
+ }
+
+ if (h->got.offset != (bfd_vma) - 1
+ && elf_aarch64_hash_entry (h)->got_type == GOT_NORMAL
+ /* Undefined weak symbol in static PIE resolves to 0 without
+ any dynamic relocations. */
+ && !UNDEFWEAK_NO_DYNAMIC_RELOC (info, h))
+ {
+ Elf_Internal_Rela rela;
+ bfd_byte *loc;
+
+ /* This symbol has an entry in the global offset table. Set it
+ up. */
+ if (htab->root.sgot == NULL || htab->root.srelgot == NULL)
+ abort ();
+
+ rela.r_offset = (htab->root.sgot->output_section->vma
+ + htab->root.sgot->output_offset
+ + (h->got.offset & ~(bfd_vma) 1));
+
+ if (h->def_regular
+ && h->type == STT_GNU_IFUNC)
+ {
+ if (bfd_link_pic (info))
+ {
+ /* Generate R_AARCH64_GLOB_DAT. */
+ goto do_glob_dat;
+ }
+ else
+ {
+ asection *plt;
+
+ if (!h->pointer_equality_needed)
+ abort ();
+
+ /* For non-shared object, we can't use .got.plt, which
+ contains the real function address if we need pointer
+ equality. We load the GOT entry with the PLT entry. */
+ plt = htab->root.splt ? htab->root.splt : htab->root.iplt;
+ bfd_put_NN (output_bfd, (plt->output_section->vma
+ + plt->output_offset
+ + h->plt.offset),
+ htab->root.sgot->contents
+ + (h->got.offset & ~(bfd_vma) 1));
+ return true;
+ }
+ }
+ else if (bfd_link_pic (info) && SYMBOL_REFERENCES_LOCAL (info, h))
+ {
+ if (!(h->def_regular || ELF_COMMON_DEF_P (h)))
+ return false;
+ BFD_ASSERT ((h->got.offset & 1) != 0);
+ /* Don't emit relative relocs if they are packed. */
+ if (info->enable_dt_relr)
+ goto skip_got_reloc;
+ rela.r_info = ELFNN_R_INFO (0, AARCH64_R (RELATIVE));
+ rela.r_addend = (h->root.u.def.value
+ + h->root.u.def.section->output_section->vma
+ + h->root.u.def.section->output_offset);
+ }
+ else
+ {
+ do_glob_dat:
+ BFD_ASSERT ((h->got.offset & 1) == 0);
+ bfd_put_NN (output_bfd, (bfd_vma) 0,
+ htab->root.sgot->contents + h->got.offset);
+ rela.r_info = ELFNN_R_INFO (h->dynindx, AARCH64_R (GLOB_DAT));
+ rela.r_addend = 0;
+ }
+
+ loc = htab->root.srelgot->contents;
+ loc += htab->root.srelgot->reloc_count++ * RELOC_SIZE (htab);
+ bfd_elfNN_swap_reloca_out (output_bfd, &rela, loc);
+ }
+skip_got_reloc:
+
+ if (h->needs_copy)
+ {
+ Elf_Internal_Rela rela;
+ asection *s;
+ bfd_byte *loc;
+
+ /* This symbol needs a copy reloc. Set it up. */
+ if (h->dynindx == -1
+ || (h->root.type != bfd_link_hash_defined
+ && h->root.type != bfd_link_hash_defweak)
+ || htab->root.srelbss == NULL)
+ abort ();
+
+ rela.r_offset = (h->root.u.def.value
+ + h->root.u.def.section->output_section->vma
+ + h->root.u.def.section->output_offset);
+ rela.r_info = ELFNN_R_INFO (h->dynindx, AARCH64_R (COPY));
+ rela.r_addend = 0;
+ if (h->root.u.def.section == htab->root.sdynrelro)
+ s = htab->root.sreldynrelro;
+ else
+ s = htab->root.srelbss;
+ loc = s->contents + s->reloc_count++ * RELOC_SIZE (htab);
+ bfd_elfNN_swap_reloca_out (output_bfd, &rela, loc);
+ }
+
+ /* Mark _DYNAMIC and _GLOBAL_OFFSET_TABLE_ as absolute. SYM may
+ be NULL for local symbols. */
+ if (sym != NULL
+ && (h == elf_hash_table (info)->hdynamic
+ || h == elf_hash_table (info)->hgot))
+ sym->st_shndx = SHN_ABS;
+
+ return true;
+}
+
+/* Finish up local dynamic symbol handling. We set the contents of
+ various dynamic sections here. */
+
+static int
+elfNN_aarch64_finish_local_dynamic_symbol (void **slot, void *inf)
+{
+ struct elf_link_hash_entry *h
+ = (struct elf_link_hash_entry *) *slot;
+ struct bfd_link_info *info
+ = (struct bfd_link_info *) inf;
+
+ return elfNN_aarch64_finish_dynamic_symbol (info->output_bfd,
+ info, h, NULL);
+}
+
+static void
+elfNN_aarch64_init_small_plt0_entry (bfd *output_bfd ATTRIBUTE_UNUSED,
+ struct elf_aarch64_link_hash_table
+ *htab)
+{
+ /* Fill in PLT0. Fixme:RR Note this doesn't distinguish between
+ small and large plts and at the minute just generates
+ the small PLT. */
+
+ /* PLT0 of the small PLT looks like this in ELF64 -
+ stp x16, x30, [sp, #-16]! // Save the reloc and lr on stack.
+ adrp x16, PLT_GOT + 16 // Get the page base of the GOTPLT
+ ldr x17, [x16, #:lo12:PLT_GOT+16] // Load the address of the
+ // symbol resolver
+ add x16, x16, #:lo12:PLT_GOT+16 // Load the lo12 bits of the
+ // GOTPLT entry for this.
+ br x17
+ PLT0 will be slightly different in ELF32 due to different got entry
+ size. */
+ bfd_vma plt_got_2nd_ent; /* Address of GOT[2]. */
+ bfd_vma plt_base;
+
+
+ memcpy (htab->root.splt->contents, htab->plt0_entry,
+ htab->plt_header_size);
+
+ /* PR 26312: Explicitly set the sh_entsize to 0 so that
+ consumers do not think that the section contains fixed
+ sized objects. */
+ elf_section_data (htab->root.splt->output_section)->this_hdr.sh_entsize = 0;
+
+ plt_got_2nd_ent = (htab->root.sgotplt->output_section->vma
+ + htab->root.sgotplt->output_offset
+ + GOT_ENTRY_SIZE * 2);
+
+ plt_base = htab->root.splt->output_section->vma +
+ htab->root.splt->output_offset;
+
+ /* First instruction in BTI enabled PLT stub is a BTI
+ instruction so skip it. */
+ bfd_byte *plt0_entry = htab->root.splt->contents;
+ if (elf_aarch64_tdata (output_bfd)->sw_protections.plt_type & PLT_BTI)
+ plt0_entry = plt0_entry + 4;
+
+ /* Fill in the top 21 bits for this: ADRP x16, PLT_GOT + n * 8.
+ ADRP: ((PG(S+A)-PG(P)) >> 12) & 0x1fffff */
+ elf_aarch64_update_plt_entry (output_bfd, BFD_RELOC_AARCH64_ADR_HI21_PCREL,
+ plt0_entry + 4,
+ PG (plt_got_2nd_ent) - PG (plt_base + 4));
+
+ elf_aarch64_update_plt_entry (output_bfd, BFD_RELOC_AARCH64_LDSTNN_LO12,
+ plt0_entry + 8,
+ PG_OFFSET (plt_got_2nd_ent));
+
+ elf_aarch64_update_plt_entry (output_bfd, BFD_RELOC_AARCH64_ADD_LO12,
+ plt0_entry + 12,
+ PG_OFFSET (plt_got_2nd_ent));
+}
+
+static bool
+elfNN_aarch64_finish_dynamic_sections (bfd *output_bfd,
+ struct bfd_link_info *info)
+{
+ struct elf_aarch64_link_hash_table *htab;
+ bfd *dynobj;
+ asection *sdyn;
+
+ htab = elf_aarch64_hash_table (info);
+ dynobj = htab->root.dynobj;
+ sdyn = bfd_get_linker_section (dynobj, ".dynamic");
+
+ if (htab->root.dynamic_sections_created)
+ {
+ ElfNN_External_Dyn *dyncon, *dynconend;
+
+ if (sdyn == NULL || htab->root.sgot == NULL)
+ abort ();
+
+ dyncon = (ElfNN_External_Dyn *) sdyn->contents;
+ dynconend = (ElfNN_External_Dyn *) (sdyn->contents + sdyn->size);
+ for (; dyncon < dynconend; dyncon++)
+ {
+ Elf_Internal_Dyn dyn;
+ asection *s;
+
+ bfd_elfNN_swap_dyn_in (dynobj, dyncon, &dyn);
+
+ switch (dyn.d_tag)
+ {
+ default:
+ continue;
+
+ case DT_PLTGOT:
+ s = htab->root.sgotplt;
+ dyn.d_un.d_ptr = s->output_section->vma + s->output_offset;
+ break;
+
+ case DT_JMPREL:
+ s = htab->root.srelplt;
+ dyn.d_un.d_ptr = s->output_section->vma + s->output_offset;
+ break;
+
+ case DT_PLTRELSZ:
+ s = htab->root.srelplt;
+ dyn.d_un.d_val = s->size;
+ break;
+
+ case DT_TLSDESC_PLT:
+ s = htab->root.splt;
+ dyn.d_un.d_ptr = s->output_section->vma + s->output_offset
+ + htab->root.tlsdesc_plt;
+ break;
+
+ case DT_TLSDESC_GOT:
+ s = htab->root.sgot;
+ BFD_ASSERT (htab->root.tlsdesc_got != (bfd_vma)-1);
+ dyn.d_un.d_ptr = s->output_section->vma + s->output_offset
+ + htab->root.tlsdesc_got;
+ break;
+ }
+
+ bfd_elfNN_swap_dyn_out (output_bfd, &dyn, dyncon);
+ }
+
+ }
+
+ /* Fill in the special first entry in the procedure linkage table. */
+ if (htab->root.splt && htab->root.splt->size > 0)
+ {
+ elfNN_aarch64_init_small_plt0_entry (output_bfd, htab);
+
+ if (htab->root.tlsdesc_plt && !(info->flags & DF_BIND_NOW))
+ {
+ BFD_ASSERT (htab->root.tlsdesc_got != (bfd_vma)-1);
+ bfd_put_NN (output_bfd, (bfd_vma) 0,
+ htab->root.sgot->contents + htab->root.tlsdesc_got);
+
+ const bfd_byte *entry = elfNN_aarch64_tlsdesc_small_plt_entry;
+ htab->tlsdesc_plt_entry_size = PLT_TLSDESC_ENTRY_SIZE;
+
+ aarch64_plt_type type
+ = elf_aarch64_tdata (output_bfd)->sw_protections.plt_type;
+ if (type == PLT_BTI || type == PLT_BTI_PAC)
+ {
+ entry = elfNN_aarch64_tlsdesc_small_plt_bti_entry;
+ }
+
+ memcpy (htab->root.splt->contents + htab->root.tlsdesc_plt,
+ entry, htab->tlsdesc_plt_entry_size);
+
+ {
+ bfd_vma adrp1_addr =
+ htab->root.splt->output_section->vma
+ + htab->root.splt->output_offset
+ + htab->root.tlsdesc_plt + 4;
+
+ bfd_vma adrp2_addr = adrp1_addr + 4;
+
+ bfd_vma got_addr =
+ htab->root.sgot->output_section->vma
+ + htab->root.sgot->output_offset;
+
+ bfd_vma pltgot_addr =
+ htab->root.sgotplt->output_section->vma
+ + htab->root.sgotplt->output_offset;
+
+ bfd_vma dt_tlsdesc_got = got_addr + htab->root.tlsdesc_got;
+
+ bfd_byte *plt_entry =
+ htab->root.splt->contents + htab->root.tlsdesc_plt;
+
+ /* First instruction in BTI enabled PLT stub is a BTI
+ instruction so skip it. */
+ if (type & PLT_BTI)
+ {
+ plt_entry = plt_entry + 4;
+ adrp1_addr = adrp1_addr + 4;
+ adrp2_addr = adrp2_addr + 4;
+ }
+
+ /* adrp x2, DT_TLSDESC_GOT */
+ elf_aarch64_update_plt_entry (output_bfd,
+ BFD_RELOC_AARCH64_ADR_HI21_PCREL,
+ plt_entry + 4,
+ (PG (dt_tlsdesc_got)
+ - PG (adrp1_addr)));
+
+ /* adrp x3, 0 */
+ elf_aarch64_update_plt_entry (output_bfd,
+ BFD_RELOC_AARCH64_ADR_HI21_PCREL,
+ plt_entry + 8,
+ (PG (pltgot_addr)
+ - PG (adrp2_addr)));
+
+ /* ldr x2, [x2, #0] */
+ elf_aarch64_update_plt_entry (output_bfd,
+ BFD_RELOC_AARCH64_LDSTNN_LO12,
+ plt_entry + 12,
+ PG_OFFSET (dt_tlsdesc_got));
+
+ /* add x3, x3, 0 */
+ elf_aarch64_update_plt_entry (output_bfd,
+ BFD_RELOC_AARCH64_ADD_LO12,
+ plt_entry + 16,
+ PG_OFFSET (pltgot_addr));
+ }
+ }
+ }
+
+ if (htab->root.sgotplt)
+ {
+ if (bfd_is_abs_section (htab->root.sgotplt->output_section))
+ {
+ _bfd_error_handler
+ (_("discarded output section: `%pA'"), htab->root.sgotplt);
+ return false;
+ }
+
+ /* Fill in the first three entries in the global offset table. */
+ if (htab->root.sgotplt->size > 0)
+ {
+ bfd_put_NN (output_bfd, (bfd_vma) 0, htab->root.sgotplt->contents);
+
+ /* Write GOT[1] and GOT[2], needed for the dynamic linker. */
+ bfd_put_NN (output_bfd,
+ (bfd_vma) 0,
+ htab->root.sgotplt->contents + GOT_ENTRY_SIZE);
+ bfd_put_NN (output_bfd,
+ (bfd_vma) 0,
+ htab->root.sgotplt->contents + GOT_ENTRY_SIZE * 2);
+ }
+
+ if (htab->root.sgot)
+ {
+ if (htab->root.sgot->size > 0)
+ {
+ bfd_vma addr =
+ sdyn ? sdyn->output_section->vma + sdyn->output_offset : 0;
+ bfd_put_NN (output_bfd, addr, htab->root.sgot->contents);
+ }
+ }
+
+ elf_section_data (htab->root.sgotplt->output_section)->
+ this_hdr.sh_entsize = GOT_ENTRY_SIZE;
+ }
+
+ if (htab->root.sgot && htab->root.sgot->size > 0)
+ elf_section_data (htab->root.sgot->output_section)->this_hdr.sh_entsize
+ = GOT_ENTRY_SIZE;
+
+ /* Fill PLT and GOT entries for local STT_GNU_IFUNC symbols. */
+ htab_traverse (htab->loc_hash_table,
+ elfNN_aarch64_finish_local_dynamic_symbol,
+ info);
+
+ return true;
+}
+
+/* Check if BTI enabled PLTs are needed. Returns the type needed. */
+static aarch64_plt_type
+get_plt_type (bfd *abfd)
+{
+ aarch64_plt_type ret = PLT_NORMAL;
+ bfd_byte *contents, *extdyn, *extdynend;
+ asection *sec = bfd_get_section_by_name (abfd, ".dynamic");
+ if (!sec
+ || (sec->flags & SEC_HAS_CONTENTS) == 0
+ || sec->size < sizeof (ElfNN_External_Dyn)
+ || !bfd_malloc_and_get_section (abfd, sec, &contents))
+ return ret;
+ extdyn = contents;
+ extdynend = contents + sec->size - sizeof (ElfNN_External_Dyn);
+ for (; extdyn <= extdynend; extdyn += sizeof (ElfNN_External_Dyn))
+ {
+ Elf_Internal_Dyn dyn;
+ bfd_elfNN_swap_dyn_in (abfd, extdyn, &dyn);
+
+ /* Let's check the processor specific dynamic array tags. */
+ bfd_vma tag = dyn.d_tag;
+ if (tag < DT_LOPROC || tag > DT_HIPROC)
+ continue;
+
+ switch (tag)
+ {
+ case DT_AARCH64_BTI_PLT:
+ ret |= PLT_BTI;
+ break;
+
+ case DT_AARCH64_PAC_PLT:
+ ret |= PLT_PAC;
+ break;
+
+ default: break;
+ }
+ }
+ free (contents);
+ return ret;
+}
+
+static long
+elfNN_aarch64_get_synthetic_symtab (bfd *abfd,
+ long symcount,
+ asymbol **syms,
+ long dynsymcount,
+ asymbol **dynsyms,
+ asymbol **ret)
+{
+ elf_aarch64_tdata (abfd)->sw_protections.plt_type = get_plt_type (abfd);
+ return _bfd_elf_get_synthetic_symtab (abfd, symcount, syms,
+ dynsymcount, dynsyms, ret);
+}
+
+/* Return address for Ith PLT stub in section PLT, for relocation REL
+ or (bfd_vma) -1 if it should not be included. */
+
+static bfd_vma
+elfNN_aarch64_plt_sym_val (bfd_vma i, const asection *plt,
+ const arelent *rel ATTRIBUTE_UNUSED)
+{
+ size_t plt0_size = PLT_ENTRY_SIZE;
+ size_t pltn_size = PLT_SMALL_ENTRY_SIZE;
+
+ aarch64_plt_type plt_type
+ = elf_aarch64_tdata (plt->owner)->sw_protections.plt_type;
+ if (plt_type == PLT_BTI_PAC)
+ {
+ if (elf_elfheader (plt->owner)->e_type == ET_EXEC)
+ pltn_size = PLT_BTI_PAC_SMALL_ENTRY_SIZE;
+ else
+ pltn_size = PLT_PAC_SMALL_ENTRY_SIZE;
+ }
+ else if (plt_type == PLT_BTI)
+ {
+ if (elf_elfheader (plt->owner)->e_type == ET_EXEC)
+ pltn_size = PLT_BTI_SMALL_ENTRY_SIZE;
+ }
+ else if (plt_type == PLT_PAC)
+ {
+ pltn_size = PLT_PAC_SMALL_ENTRY_SIZE;
+ }
+
+ return plt->vma + plt0_size + i * pltn_size;
+}
+
+/* Returns TRUE if NAME is an AArch64 mapping symbol.
+ The ARM ELF standard defines $x (for A64 code) and $d (for data).
+ It also allows a period initiated suffix to be added to the symbol, ie:
+ "$[adtx]\.[:sym_char]+". */
+
+static bool
+is_aarch64_mapping_symbol (const char * name)
+{
+ return name != NULL /* Paranoia. */
+ && name[0] == '$' /* Note: if objcopy --prefix-symbols has been used then
+ the mapping symbols could have acquired a prefix.
+ We do not support this here, since such symbols no
+ longer conform to the ARM ELF ABI. */
+ && (name[1] == 'd' || name[1] == 'x')
+ && (name[2] == 0 || name[2] == '.');
+ /* FIXME: Strictly speaking the symbol is only a valid mapping symbol if
+ any characters that follow the period are legal characters for the body
+ of a symbol's name. For now we just assume that this is the case. */
+}
+
+/* Make sure that mapping symbols in object files are not removed via the
+ "strip --strip-unneeded" tool. These symbols might needed in order to
+ correctly generate linked files. Once an object file has been linked,
+ it should be safe to remove them. */
+
+static void
+elfNN_aarch64_backend_symbol_processing (bfd *abfd, asymbol *sym)
+{
+ if (((abfd->flags & (EXEC_P | DYNAMIC)) == 0)
+ && sym->section != bfd_abs_section_ptr
+ && is_aarch64_mapping_symbol (sym->name))
+ sym->flags |= BSF_KEEP;
+}
+
+/* Implement elf_backend_setup_gnu_properties for AArch64. It serves as a
+ wrapper function for _bfd_aarch64_elf_link_setup_gnu_properties to account
+ for the effect of GNU properties of the output_bfd. */
+static bfd *
+elfNN_aarch64_link_setup_gnu_properties (struct bfd_link_info *info)
+{
+ bfd *pbfd = _bfd_aarch64_elf_link_setup_gnu_properties (info);
+
+ /* When BTI is forced on the command line, information flows from plt_type to
+ outprop, so plt_type has already been set and outprop don't have any effect
+ on plt_type.
+ Whereas if BTI is inferred from the input bfds, information flows from
+ outprop to plt_type. If the property GNU_PROPERTY_AARCH64_FEATURE_1_BTI
+ has been set on all the input bfds, then BTI is set on the output bfd and
+ plt_type is updated accordingly. */
+ struct elf_aarch64_obj_tdata * tdata = elf_aarch64_tdata (info->output_bfd);
+ uint32_t outprop = tdata->gnu_property_aarch64_feature_1_and;
+ if (outprop & GNU_PROPERTY_AARCH64_FEATURE_1_BTI)
+ tdata->sw_protections.plt_type |= PLT_BTI;
+ setup_plt_values (info, tdata->sw_protections.plt_type);
+ return pbfd;
+}
+
+/* Implement elf_backend_merge_gnu_properties for AArch64. It serves as a
+ wrapper function for _bfd_aarch64_elf_merge_gnu_properties to account
+ for the effect of GNU properties of the output_bfd. */
+static bool
+elfNN_aarch64_merge_gnu_properties (struct bfd_link_info *info,
+ bfd *abfd, bfd *bbfd,
+ elf_property *aprop,
+ elf_property *bprop)
+{
+ uint32_t outprop
+ = elf_aarch64_tdata (info->output_bfd)->gnu_property_aarch64_feature_1_and;
+
+ /* Properties are merged per type, hence only check for warnings when merging
+ GNU_PROPERTY_AARCH64_FEATURE_1_AND. */
+ if ((aprop && aprop->pr_type == GNU_PROPERTY_AARCH64_FEATURE_1_AND)
+ || (bprop && bprop->pr_type == GNU_PROPERTY_AARCH64_FEATURE_1_AND))
+ {
+ const aarch64_protection_opts *sw_protections
+ = &elf_aarch64_tdata (info->output_bfd)->sw_protections;
+ aarch64_feature_marking_report bti_report = sw_protections->bti_report;
+ aarch64_feature_marking_report gcs_report = sw_protections->gcs_report;
+
+ /* If output has been marked with BTI using command line argument, give
+ out warning if necessary. */
+ if ((outprop & GNU_PROPERTY_AARCH64_FEATURE_1_BTI)
+ && (bti_report != MARKING_NONE))
+ {
+ if (!aprop || !(aprop->u.number & GNU_PROPERTY_AARCH64_FEATURE_1_BTI))
+ _bfd_aarch64_elf_check_bti_report (info, abfd);
+ if (!bprop || !(bprop->u.number & GNU_PROPERTY_AARCH64_FEATURE_1_BTI))
+ _bfd_aarch64_elf_check_bti_report (info, bbfd);
+ }
+
+ /* If the output has been marked with GCS using '-z gcs' and the input is
+ missing GCS feature tag, throw a warning/error in accordance with
+ -z gcs-report=warning/error. */
+ if ((outprop & GNU_PROPERTY_AARCH64_FEATURE_1_GCS)
+ && gcs_report != MARKING_NONE)
+ {
+ if (!aprop || !(aprop->u.number & GNU_PROPERTY_AARCH64_FEATURE_1_GCS))
+ _bfd_aarch64_elf_check_gcs_report (info, abfd);
+ if (!bprop || !(bprop->u.number & GNU_PROPERTY_AARCH64_FEATURE_1_GCS))
+ _bfd_aarch64_elf_check_gcs_report (info, bbfd);
+ }
+ }
+
+ return _bfd_aarch64_elf_merge_gnu_properties (info, abfd, aprop,
+ bprop, outprop);
+}
+
+/* We use this so we can override certain functions
+ (though currently we don't). */
+
+const struct elf_size_info elfNN_aarch64_size_info =
+{
+ sizeof (ElfNN_External_Ehdr),
+ sizeof (ElfNN_External_Phdr),
+ sizeof (ElfNN_External_Shdr),
+ sizeof (ElfNN_External_Rel),
+ sizeof (ElfNN_External_Rela),
+ sizeof (ElfNN_External_Sym),
+ sizeof (ElfNN_External_Dyn),
+ sizeof (Elf_External_Note),
+ 4, /* Hash table entry size. */
+ 1, /* Internal relocs per external relocs. */
+ ARCH_SIZE, /* Arch size. */
+ LOG_FILE_ALIGN, /* Log_file_align. */
+ ELFCLASSNN, EV_CURRENT,
+ bfd_elfNN_write_out_phdrs,
+ bfd_elfNN_write_shdrs_and_ehdr,
+ bfd_elfNN_checksum_contents,
+ bfd_elfNN_write_relocs,
+ bfd_elfNN_swap_symbol_in,
+ bfd_elfNN_swap_symbol_out,
+ bfd_elfNN_slurp_reloc_table,
+ bfd_elfNN_slurp_symbol_table,
+ bfd_elfNN_swap_dyn_in,
+ bfd_elfNN_swap_dyn_out,
+ bfd_elfNN_swap_reloc_in,
+ bfd_elfNN_swap_reloc_out,
+ bfd_elfNN_swap_reloca_in,
+ bfd_elfNN_swap_reloca_out
+};
+
+#define ELF_ARCH bfd_arch_aarch64
+#define ELF_TARGET_ID AARCH64_ELF_DATA
+#define ELF_MACHINE_CODE EM_AARCH64
+#define ELF_MAXPAGESIZE 0x10000
+#define ELF_COMMONPAGESIZE 0x1000
+
+#define bfd_elfNN_bfd_is_target_special_symbol \
+ elfNN_aarch64_is_target_special_symbol
+
+#define bfd_elfNN_bfd_link_hash_table_create \
+ elfNN_aarch64_link_hash_table_create
+
+#define bfd_elfNN_bfd_merge_private_bfd_data \
+ elfNN_aarch64_merge_private_bfd_data
+
+#define bfd_elfNN_bfd_print_private_bfd_data \
+ elfNN_aarch64_print_private_bfd_data
+
+#define bfd_elfNN_bfd_reloc_type_lookup \
+ elfNN_aarch64_reloc_type_lookup
+
+#define bfd_elfNN_bfd_reloc_name_lookup \
+ elfNN_aarch64_reloc_name_lookup
+
+#define bfd_elfNN_bfd_set_private_flags \
+ elfNN_aarch64_set_private_flags
+
+#define bfd_elfNN_find_inliner_info \
+ elfNN_aarch64_find_inliner_info
+
+#define bfd_elfNN_get_synthetic_symtab \
+ elfNN_aarch64_get_synthetic_symtab
+
+#define bfd_elfNN_mkobject \
+ elfNN_aarch64_mkobject
+
+#define bfd_elfNN_new_section_hook \
+ elfNN_aarch64_new_section_hook
+
+#define elf_backend_adjust_dynamic_symbol \
+ elfNN_aarch64_adjust_dynamic_symbol
+
+#define elf_backend_early_size_sections \
+ elfNN_aarch64_early_size_sections
+
+#define elf_backend_check_relocs \
+ elfNN_aarch64_check_relocs
+
+#define elf_backend_copy_indirect_symbol \
+ elfNN_aarch64_copy_indirect_symbol
+
+#define elf_backend_merge_symbol_attribute \
+ elfNN_aarch64_merge_symbol_attribute
+
+/* Create .dynbss, and .rela.bss sections in DYNOBJ, and set up shortcuts
+ to them in our hash. */
+#define elf_backend_create_dynamic_sections \
+ elfNN_aarch64_create_dynamic_sections
+
+#define elf_backend_init_index_section \
+ _bfd_elf_init_2_index_sections
+
+#define elf_backend_finish_dynamic_sections \
+ elfNN_aarch64_finish_dynamic_sections
+
+#define elf_backend_finish_dynamic_symbol \
+ elfNN_aarch64_finish_dynamic_symbol
+
+#define elf_backend_object_p \
+ elfNN_aarch64_object_p
+
+#define elf_backend_output_arch_local_syms \
+ elfNN_aarch64_output_arch_local_syms
+
+#define elf_backend_maybe_function_sym \
+ elfNN_aarch64_maybe_function_sym
+
+#define elf_backend_plt_sym_val \
+ elfNN_aarch64_plt_sym_val
+
+#define elf_backend_init_file_header \
+ elfNN_aarch64_init_file_header
+
+#define elf_backend_relocate_section \
+ elfNN_aarch64_relocate_section
+
+#define elf_backend_reloc_type_class \
+ elfNN_aarch64_reloc_type_class
+
+#define elf_backend_section_from_shdr \
+ elfNN_aarch64_section_from_shdr
+
+#define elf_backend_section_from_phdr \
+ elfNN_aarch64_section_from_phdr
+
+#define elf_backend_modify_headers \
+ elfNN_aarch64_modify_headers
+
+#define elf_backend_late_size_sections \
+ elfNN_aarch64_late_size_sections
+
+#define elf_backend_size_info \
+ elfNN_aarch64_size_info
+
+#define elf_backend_write_section \
+ elfNN_aarch64_write_section
+
+#define elf_backend_symbol_processing \
+ elfNN_aarch64_backend_symbol_processing
+
+#define elf_backend_setup_gnu_properties \
+ elfNN_aarch64_link_setup_gnu_properties
+
+#define elf_backend_merge_gnu_properties \
+ elfNN_aarch64_merge_gnu_properties
+
+#define elf_backend_size_relative_relocs \
+ elfNN_aarch64_size_relative_relocs
+
+#define elf_backend_finish_relative_relocs \
+ elfNN_aarch64_finish_relative_relocs
+
+#define elf_backend_can_refcount 1
+#define elf_backend_can_gc_sections 1
+#define elf_backend_plt_readonly 1
+#define elf_backend_want_got_plt 1
+#define elf_backend_want_plt_sym 0
+#define elf_backend_want_dynrelro 1
+#define elf_backend_may_use_rel_p 0
+#define elf_backend_may_use_rela_p 1
+#define elf_backend_default_use_rela_p 1
+#define elf_backend_rela_normal 1
+#define elf_backend_dtrel_excludes_plt 1
+#define elf_backend_got_header_size (GOT_ENTRY_SIZE * 3)
+#define elf_backend_default_execstack 0
+#define elf_backend_extern_protected_data 0
+#define elf_backend_hash_symbol elf_aarch64_hash_symbol
+
+#undef elf_backend_obj_attrs_section
+#define elf_backend_obj_attrs_section ".ARM.attributes"
+
+#include "elfNN-target.h"
+
+/* CloudABI support. */
+
+#undef TARGET_LITTLE_SYM
+#define TARGET_LITTLE_SYM aarch64_elfNN_le_cloudabi_vec
+#undef TARGET_LITTLE_NAME
+#define TARGET_LITTLE_NAME "elfNN-littleaarch64-cloudabi"
+#undef TARGET_BIG_SYM
+#define TARGET_BIG_SYM aarch64_elfNN_be_cloudabi_vec
+#undef TARGET_BIG_NAME
+#define TARGET_BIG_NAME "elfNN-bigaarch64-cloudabi"
+
+#undef ELF_OSABI
+#define ELF_OSABI ELFOSABI_CLOUDABI
+
+#undef elfNN_bed
+#define elfNN_bed elfNN_aarch64_cloudabi_bed
+
+#include "elfNN-target.h"
Index: sources/GNU/binutils/create-2.44-aarch64-ifunc-patch/create.patch.sh
===================================================================
--- sources/GNU/binutils/create-2.44-aarch64-ifunc-patch/create.patch.sh (nonexistent)
+++ sources/GNU/binutils/create-2.44-aarch64-ifunc-patch/create.patch.sh (revision 76)
@@ -0,0 +1,15 @@
+#!/bin/bash
+
+VERSION=2.44
+
+tar --files-from=file.list -xJvf ../binutils-$VERSION.tar.xz
+mv binutils-$VERSION binutils-$VERSION-orig
+
+cp -rf ./binutils-$VERSION-new ./binutils-$VERSION
+
+diff --unified -Nr binutils-$VERSION-orig binutils-$VERSION > binutils-$VERSION-aarch64-ifunc.patch
+
+mv binutils-$VERSION-aarch64-ifunc.patch ../patches
+
+rm -rf ./binutils-$VERSION
+rm -rf ./binutils-$VERSION-orig
Property changes on: sources/GNU/binutils/create-2.44-aarch64-ifunc-patch/create.patch.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: sources/GNU/binutils/create-2.44-aarch64-ifunc-patch/file.list
===================================================================
--- sources/GNU/binutils/create-2.44-aarch64-ifunc-patch/file.list (nonexistent)
+++ sources/GNU/binutils/create-2.44-aarch64-ifunc-patch/file.list (revision 76)
@@ -0,0 +1 @@
+binutils-2.44/bfd/elfnn-aarch64.c
Index: sources/GNU/binutils/create-2.44-export-demangle-patch/binutils-2.44-new/bfd/Makefile.am
===================================================================
--- sources/GNU/binutils/create-2.44-export-demangle-patch/binutils-2.44-new/bfd/Makefile.am (nonexistent)
+++ sources/GNU/binutils/create-2.44-export-demangle-patch/binutils-2.44-new/bfd/Makefile.am (revision 76)
@@ -0,0 +1,1021 @@
+## Process this file with automake to generate Makefile.in
+#
+# Copyright (C) 2012-2025 Free Software Foundation, Inc.
+#
+# This file is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; see the file COPYING3. If not see
+# <http://www.gnu.org/licenses/>.
+#
+
+AUTOMAKE_OPTIONS = no-dist foreign info-in-builddir no-texinfo.tex
+ACLOCAL_AMFLAGS = -I . -I .. -I ../config
+
+MOSTLYCLEANFILES =
+CLEANFILES =
+DISTCLEANFILES =
+MAINTAINERCLEANFILES =
+
+INCDIR = $(srcdir)/../include
+CSEARCH = -I. -I$(srcdir) -I$(INCDIR)
+
+SUBDIRS = po
+
+bfddocdir = doc
+
+libbfd_la_LDFLAGS =
+if INSTALL_LIBBFD
+bfdlibdir = @bfdlibdir@
+bfdincludedir = @bfdincludedir@
+bfdlib_LTLIBRARIES = libbfd.la
+bfdinclude_HEADERS = $(BFD_H) $(INCDIR)/ansidecl.h $(INCDIR)/symcat.h \
+ $(INCDIR)/diagnostics.h $(INCDIR)/bfdlink.h $(INCDIR)/demangle.h
+else !INSTALL_LIBBFD
+# Empty these so that the respective installation directories will not be created.
+bfdlibdir =
+bfdincludedir =
+bfdinclude_HEADERS =
+rpath_bfdlibdir = @bfdlibdir@
+noinst_LTLIBRARIES = libbfd.la
+libbfd_la_LDFLAGS += -rpath $(rpath_bfdlibdir)
+endif
+
+# This is where we get zlib from. zlibdir is -L../zlib and zlibinc is
+# -I../zlib, unless we were configured with --with-system-zlib, in which
+# case both are empty.
+ZLIB = @zlibdir@ -lz
+ZLIBINC = @zlibinc@
+
+WARN_CFLAGS = @WARN_CFLAGS@
+NO_WERROR = @NO_WERROR@
+AM_CFLAGS = $(WARN_CFLAGS) $(ZLIBINC) $(ZSTD_CFLAGS)
+AM_CPPFLAGS = -DBINDIR='"$(bindir)"' -DLIBDIR='"$(libdir)"' @LARGEFILE_CPPFLAGS@
+if PLUGINS
+bfdinclude_HEADERS += $(INCDIR)/plugin-api.h
+LIBDL = @lt_cv_dlopen_libs@
+endif
+
+# bfd.h goes here, for now
+BFD_H = bfd.h
+
+# Jim Kingdon notes:
+# Writing S-records should be included in all (or at least most)
+# *-*-coff, *-*-aout, etc., configurations, because people will want to
+# be able to use objcopy to create S-records. (S-records are not useful
+# for the debugger, so if you are downloading things as S-records you
+# need two copies of the executable, one to download and one for the
+# debugger).
+BFD32_LIBS = \
+ archive.lo archures.lo bfd.lo bfdio.lo cache.lo \
+ coff-bfd.lo compress.lo corefile.lo elf-properties.lo format.lo \
+ hash.lo libbfd.lo linker.lo merge.lo opncls.lo reloc.lo \
+ section.lo simple.lo stab-syms.lo stabs.lo syms.lo targets.lo \
+ binary.lo ihex.lo srec.lo tekhex.lo verilog.lo
+
+BFD64_LIBS = archive64.lo
+
+BFD32_LIBS_CFILES = \
+ archive.c archures.c bfd.c bfdio.c cache.c coff-bfd.c \
+ compress.c corefile.c elf-properties.c format.c hash.c \
+ libbfd.c linker.c merge.c opncls.c reloc.c \
+ section.c simple.c stab-syms.c stabs.c syms.c targets.c \
+ binary.c ihex.c srec.c tekhex.c verilog.c
+
+BFD64_LIBS_CFILES = archive64.c
+
+# This list is alphabetized to make it easier to keep in sync
+# with the decls and initializer in archures.c.
+ALL_MACHINES = \
+ cpu-aarch64.lo \
+ cpu-alpha.lo \
+ cpu-amdgcn.lo \
+ cpu-arc.lo \
+ cpu-arm.lo \
+ cpu-avr.lo \
+ cpu-bfin.lo \
+ cpu-bpf.lo \
+ cpu-cr16.lo \
+ cpu-cris.lo \
+ cpu-crx.lo \
+ cpu-csky.lo \
+ cpu-d10v.lo \
+ cpu-d30v.lo \
+ cpu-dlx.lo \
+ cpu-epiphany.lo \
+ cpu-fr30.lo \
+ cpu-frv.lo \
+ cpu-ft32.lo \
+ cpu-h8300.lo \
+ cpu-hppa.lo \
+ cpu-i386.lo \
+ cpu-ia64.lo \
+ cpu-iamcu.lo \
+ cpu-ip2k.lo \
+ cpu-iq2000.lo \
+ cpu-kvx.lo \
+ cpu-lm32.lo \
+ cpu-loongarch.lo \
+ cpu-m10200.lo \
+ cpu-m10300.lo \
+ cpu-m32c.lo \
+ cpu-m32r.lo \
+ cpu-m68hc11.lo \
+ cpu-m68hc12.lo \
+ cpu-m68k.lo \
+ cpu-m9s12x.lo \
+ cpu-m9s12xg.lo \
+ cpu-mcore.lo \
+ cpu-mep.lo \
+ cpu-metag.lo \
+ cpu-microblaze.lo \
+ cpu-mips.lo \
+ cpu-mmix.lo \
+ cpu-moxie.lo \
+ cpu-msp430.lo \
+ cpu-mt.lo \
+ cpu-nds32.lo \
+ cpu-nfp.lo \
+ cpu-ns32k.lo \
+ cpu-or1k.lo \
+ cpu-pdp11.lo \
+ cpu-pj.lo \
+ cpu-powerpc.lo \
+ cpu-pru.lo \
+ cpu-riscv.lo \
+ cpu-rl78.lo \
+ cpu-rs6000.lo \
+ cpu-rx.lo \
+ cpu-s12z.lo \
+ cpu-s390.lo \
+ cpu-score.lo \
+ cpu-sh.lo \
+ cpu-sparc.lo \
+ cpu-spu.lo \
+ cpu-tic30.lo \
+ cpu-tic4x.lo \
+ cpu-tic54x.lo \
+ cpu-tic6x.lo \
+ cpu-tilegx.lo \
+ cpu-tilepro.lo \
+ cpu-v850.lo \
+ cpu-v850_rh850.lo \
+ cpu-vax.lo \
+ cpu-visium.lo \
+ cpu-wasm32.lo \
+ cpu-xgate.lo \
+ cpu-xstormy16.lo \
+ cpu-xtensa.lo \
+ cpu-z80.lo \
+ cpu-z8k.lo
+
+ALL_MACHINES_CFILES = \
+ cpu-aarch64.c \
+ cpu-alpha.c \
+ cpu-amdgcn.c \
+ cpu-arc.c \
+ cpu-arm.c \
+ cpu-avr.c \
+ cpu-bfin.c \
+ cpu-bpf.c \
+ cpu-cr16.c \
+ cpu-cris.c \
+ cpu-crx.c \
+ cpu-csky.c \
+ cpu-d10v.c \
+ cpu-d30v.c \
+ cpu-dlx.c \
+ cpu-epiphany.c \
+ cpu-fr30.c \
+ cpu-frv.c \
+ cpu-ft32.c \
+ cpu-h8300.c \
+ cpu-hppa.c \
+ cpu-i386.c \
+ cpu-ia64.c \
+ cpu-iamcu.c \
+ cpu-ip2k.c \
+ cpu-iq2000.c \
+ cpu-kvx.c \
+ cpu-lm32.c \
+ cpu-loongarch.c \
+ cpu-m10200.c \
+ cpu-m10300.c \
+ cpu-m32c.c \
+ cpu-m32r.c \
+ cpu-m68hc11.c \
+ cpu-m68hc12.c \
+ cpu-m68k.c \
+ cpu-m9s12x.c \
+ cpu-m9s12xg.c \
+ cpu-mcore.c \
+ cpu-mep.c \
+ cpu-metag.c \
+ cpu-microblaze.c \
+ cpu-mips.c \
+ cpu-mmix.c \
+ cpu-moxie.c \
+ cpu-msp430.c \
+ cpu-mt.c \
+ cpu-nds32.c \
+ cpu-nfp.c \
+ cpu-ns32k.c \
+ cpu-or1k.c \
+ cpu-pdp11.c \
+ cpu-pj.c \
+ cpu-powerpc.c \
+ cpu-pru.c \
+ cpu-riscv.c \
+ cpu-rl78.c \
+ cpu-rs6000.c \
+ cpu-rx.c \
+ cpu-s12z.c \
+ cpu-s390.c \
+ cpu-score.c \
+ cpu-sh.c \
+ cpu-sparc.c \
+ cpu-spu.c \
+ cpu-tic30.c \
+ cpu-tic4x.c \
+ cpu-tic54x.c \
+ cpu-tic6x.c \
+ cpu-tilegx.c \
+ cpu-tilepro.c \
+ cpu-v850.c \
+ cpu-v850_rh850.c \
+ cpu-vax.c \
+ cpu-visium.c \
+ cpu-wasm32.c \
+ cpu-xgate.c \
+ cpu-xstormy16.c \
+ cpu-xtensa.c \
+ cpu-z80.c \
+ cpu-z8k.c
+
+# The .o files needed by all of the 32 bit vectors that are configured into
+# target_vector in targets.c if configured with --enable-targets=all.
+BFD32_BACKENDS = \
+ aout-cris.lo \
+ aout-ns32k.lo \
+ aout32.lo \
+ cf-i386lynx.lo \
+ coff-go32.lo \
+ coff-i386.lo \
+ coff-mips.lo \
+ coff-rs6000.lo \
+ coff-sh.lo \
+ coff-stgo32.lo \
+ coff-tic30.lo \
+ coff-tic4x.lo \
+ coff-tic54x.lo \
+ coff-z80.lo \
+ coff-z8k.lo \
+ coffgen.lo \
+ cofflink.lo \
+ dwarf1.lo \
+ dwarf2.lo \
+ ecoff.lo \
+ ecofflink.lo \
+ elf-attrs.lo \
+ elf-eh-frame.lo \
+ elf-ifunc.lo \
+ elf-m10200.lo \
+ elf-m10300.lo \
+ elf-nacl.lo \
+ elf-sframe.lo \
+ elf-strtab.lo \
+ elf-vxworks.lo \
+ elf.lo \
+ elf32-am33lin.lo \
+ elf32-arc.lo \
+ elf32-arm.lo \
+ elf32-avr.lo \
+ elf32-bfin.lo \
+ elf32-cr16.lo \
+ elf32-cris.lo \
+ elf32-crx.lo \
+ elf32-csky.lo \
+ elf32-d10v.lo \
+ elf32-d30v.lo \
+ elf32-dlx.lo \
+ elf32-epiphany.lo \
+ elf32-fr30.lo \
+ elf32-frv.lo \
+ elf32-ft32.lo \
+ elf32-gen.lo \
+ elf32-h8300.lo \
+ elf32-hppa.lo \
+ elf32-i386.lo \
+ elf32-ip2k.lo \
+ elf32-iq2000.lo \
+ elf32-lm32.lo \
+ elf32-m32c.lo \
+ elf32-m32r.lo \
+ elf32-m68hc11.lo \
+ elf32-m68hc12.lo \
+ elf32-m68hc1x.lo \
+ elf32-m68k.lo \
+ elf32-mcore.lo \
+ elf32-mep.lo \
+ elf32-metag.lo \
+ elf32-microblaze.lo \
+ elf32-moxie.lo \
+ elf32-msp430.lo \
+ elf32-mt.lo \
+ elf32-nds32.lo \
+ elf32-or1k.lo \
+ elf32-pj.lo \
+ elf32-ppc.lo \
+ elf32-pru.lo \
+ elf32-rl78.lo \
+ elf32-rx.lo \
+ elf32-s12z.lo \
+ elf32-s390.lo \
+ elf32-sh.lo \
+ elf32-sparc.lo \
+ elf32-spu.lo \
+ elf32-tic6x.lo \
+ elf32-tilegx.lo \
+ elf32-tilepro.lo \
+ elf32-v850.lo \
+ elf32-vax.lo \
+ elf32-visium.lo \
+ elf32-wasm32.lo \
+ elf32-xgate.lo \
+ elf32-xstormy16.lo \
+ elf32-xtensa.lo \
+ elf32-z80.lo \
+ elf32.lo \
+ elflink.lo \
+ elfxx-sparc.lo \
+ elfxx-tilegx.lo \
+ elfxx-x86.lo \
+ i386aout.lo \
+ i386bsd.lo \
+ i386lynx.lo \
+ i386msdos.lo \
+ mach-o-arm.lo \
+ mach-o-i386.lo \
+ mach-o.lo \
+ ns32knetbsd.lo \
+ pc532-mach.lo \
+ pdb.lo \
+ pdp11.lo \
+ pe-arm-wince.lo \
+ pe-arm.lo \
+ pe-i386.lo \
+ pe-mcore.lo \
+ pe-sh.lo \
+ pef.lo \
+ pei-arm-wince.lo \
+ pei-arm.lo \
+ pei-i386.lo \
+ pei-mcore.lo \
+ pei-sh.lo \
+ peigen.lo \
+ plugin.lo \
+ ppcboot.lo \
+ reloc16.lo \
+ som.lo \
+ vax1knetbsd.lo \
+ vaxnetbsd.lo \
+ vms-lib.lo \
+ vms-misc.lo \
+ wasm-module.lo \
+ xcofflink.lo \
+ xsym.lo \
+ xtensa-dynconfig.lo \
+ xtensa-isa.lo \
+ xtensa-modules.lo
+
+BFD32_BACKENDS_CFILES = \
+ aout-cris.c \
+ aout-ns32k.c \
+ aout32.c \
+ cf-i386lynx.c \
+ coff-go32.c \
+ coff-i386.c \
+ coff-mips.c \
+ coff-rs6000.c \
+ coff-sh.c \
+ coff-stgo32.c \
+ coff-tic30.c \
+ coff-tic4x.c \
+ coff-tic54x.c \
+ coff-z80.c \
+ coff-z8k.c \
+ coffgen.c \
+ cofflink.c \
+ dwarf1.c \
+ dwarf2.c \
+ ecoff.c \
+ ecofflink.c \
+ elf-attrs.c \
+ elf-eh-frame.c \
+ elf-ifunc.c \
+ elf-m10200.c \
+ elf-m10300.c \
+ elf-nacl.c \
+ elf-sframe.c \
+ elf-strtab.c \
+ elf-vxworks.c \
+ elf.c \
+ elf32-am33lin.c \
+ elf32-arc.c \
+ elf32-arm.c \
+ elf32-avr.c \
+ elf32-bfin.c \
+ elf32-cr16.c \
+ elf32-cris.c \
+ elf32-crx.c \
+ elf32-csky.c \
+ elf32-d10v.c \
+ elf32-d30v.c \
+ elf32-dlx.c \
+ elf32-epiphany.c \
+ elf32-fr30.c \
+ elf32-frv.c \
+ elf32-ft32.c \
+ elf32-gen.c \
+ elf32-h8300.c \
+ elf32-hppa.c \
+ elf32-i386.c \
+ elf32-ip2k.c \
+ elf32-iq2000.c \
+ elf32-lm32.c \
+ elf32-m32c.c \
+ elf32-m32r.c \
+ elf32-m68hc11.c \
+ elf32-m68hc12.c \
+ elf32-m68hc1x.c \
+ elf32-m68k.c \
+ elf32-mcore.c \
+ elf32-mep.c \
+ elf32-metag.c \
+ elf32-microblaze.c \
+ elf32-moxie.c \
+ elf32-msp430.c \
+ elf32-mt.c \
+ elf32-nds32.c \
+ elf32-or1k.c \
+ elf32-pj.c \
+ elf32-ppc.c \
+ elf32-pru.c \
+ elf32-rl78.c \
+ elf32-rx.c \
+ elf32-s12z.c \
+ elf32-s390.c \
+ elf32-sh.c \
+ elf32-sparc.c \
+ elf32-spu.c \
+ elf32-tic6x.c \
+ elf32-tilegx.c \
+ elf32-tilepro.c \
+ elf32-v850.c \
+ elf32-vax.c \
+ elf32-visium.c \
+ elf32-wasm32.c \
+ elf32-xgate.c \
+ elf32-xstormy16.c \
+ elf32-xtensa.c \
+ elf32-z80.c \
+ elf32.c \
+ elflink.c \
+ elfxx-sparc.c \
+ elfxx-tilegx.c \
+ elfxx-x86.c \
+ i386aout.c \
+ i386bsd.c \
+ i386lynx.c \
+ i386msdos.c \
+ mach-o-arm.c \
+ mach-o-i386.c \
+ mach-o.c \
+ ns32knetbsd.c \
+ pc532-mach.c \
+ pdb.c \
+ pdp11.c \
+ pe-arm-wince.c \
+ pe-arm.c \
+ pe-i386.c \
+ pe-mcore.c \
+ pe-sh.c \
+ pef.c \
+ pei-arm-wince.c \
+ pei-arm.c \
+ pei-i386.c \
+ pei-mcore.c \
+ pei-sh.c \
+ plugin.c \
+ ppcboot.c \
+ reloc16.c \
+ som.c \
+ vax1knetbsd.c \
+ vaxnetbsd.c \
+ vms-lib.c \
+ vms-misc.c \
+ wasm-module.c \
+ xcofflink.c \
+ xsym.c \
+ xtensa-dynconfig.c \
+ xtensa-isa.c \
+ xtensa-modules.c
+
+# The .o files needed by all of the 64 bit vectors that are configured into
+# target_vector in targets.c if configured with --enable-targets=all
+# and --enable-64-bit-bfd.
+# elf32-ia64.c requires a 64-bit bfd_vma, and hence can not be put in
+# BFD32_BACKENDS.
+BFD64_BACKENDS = \
+ aix5ppc-core.lo \
+ aout64.lo \
+ coff-alpha.lo \
+ coff-x86_64.lo \
+ coff64-rs6000.lo \
+ elf32-aarch64.lo \
+ elf32-ia64.lo \
+ elf32-kvx.lo \
+ elf32-loongarch.lo \
+ elf32-mips.lo \
+ elf32-riscv.lo \
+ elf32-score.lo \
+ elf32-score7.lo \
+ elf64-aarch64.lo \
+ elf64-alpha.lo \
+ elf64-amdgcn.lo \
+ elf64-bpf.lo \
+ elf64-gen.lo \
+ elf64-hppa.lo \
+ elf64-ia64-vms.lo \
+ elf64-ia64.lo \
+ elf64-kvx.lo \
+ elf64-loongarch.lo \
+ elf64-mips.lo \
+ elf64-mmix.lo \
+ elf64-nfp.lo \
+ elf64-ppc.lo \
+ elf64-riscv.lo \
+ elf64-s390.lo \
+ elf64-sparc.lo \
+ elf64-tilegx.lo \
+ elf64-x86-64.lo \
+ elf64.lo \
+ elfn32-mips.lo \
+ elfxx-aarch64.lo \
+ elfxx-ia64.lo \
+ elfxx-kvx.lo \
+ elfxx-loongarch.lo \
+ elfxx-mips.lo \
+ elfxx-riscv.lo \
+ elfxx-x86.lo \
+ mach-o-aarch64.lo \
+ mach-o-x86-64.lo \
+ mmo.lo \
+ pe-aarch64.lo \
+ pe-aarch64igen.lo \
+ pe-loongarch64igen.lo \
+ pe-riscv64igen.lo \
+ pe-x86_64.lo \
+ pei-aarch64.lo \
+ pei-ia64.lo \
+ pei-loongarch64.lo \
+ pei-riscv64.lo \
+ pei-x86_64.lo \
+ pepigen.lo \
+ pex64igen.lo \
+ vms-alpha.lo
+
+BFD64_BACKENDS_CFILES = \
+ aix5ppc-core.c \
+ aout64.c \
+ coff-alpha.c \
+ coff-x86_64.c \
+ coff64-rs6000.c \
+ elf32-mips.c \
+ elf32-score.c \
+ elf32-score7.c \
+ elf64-alpha.c \
+ elf64-amdgcn.c \
+ elf64-bpf.c \
+ elf64-gen.c \
+ elf64-hppa.c \
+ elf64-ia64-vms.c \
+ elf64-mips.c \
+ elf64-mmix.c \
+ elf64-nfp.c \
+ elf64-ppc.c \
+ elf64-s390.c \
+ elf64-sparc.c \
+ elf64-tilegx.c \
+ elf64-x86-64.c \
+ elf64.c \
+ elfn32-mips.c \
+ elfxx-aarch64.c \
+ elfxx-ia64.c \
+ elfxx-kvx.c \
+ elfxx-loongarch.c \
+ elfxx-mips.c \
+ elfxx-riscv.c \
+ elfxx-x86.c \
+ mach-o-aarch64.c \
+ mach-o-x86-64.c \
+ mmo.c \
+ pe-aarch64.c \
+ pe-x86_64.c \
+ pei-aarch64.c \
+ pei-ia64.c \
+ pei-loongarch64.c \
+ pei-riscv64.c \
+ pei-x86_64.c \
+ vms-alpha.c
+
+OPTIONAL_BACKENDS = \
+ cisco-core.lo \
+ hpux-core.lo \
+ irix-core.lo \
+ lynx-core.lo \
+ netbsd-core.lo \
+ osf-core.lo \
+ rs6000-core.lo \
+ trad-core.lo
+
+OPTIONAL_BACKENDS_CFILES = \
+ cisco-core.c \
+ hpux-core.c \
+ irix-core.c \
+ lynx-core.c \
+ netbsd-core.c \
+ osf-core.c \
+ rs6000-core.c \
+ trad-core.c
+
+# Reconfigure if config.bfd or configure.host changes.
+# development.sh is used to determine -Werror default.
+CONFIG_STATUS_DEPENDENCIES = \
+ $(srcdir)/config.bfd \
+ $(srcdir)/configure.host \
+ $(srcdir)/development.sh
+
+# These are defined by configure:
+WORDSIZE = @wordsize@
+ALL_BACKENDS = @all_backends@
+BFD_BACKENDS = @bfd_backends@
+BFD_MACHINES = @bfd_machines@
+TDEFAULTS = @tdefaults@
+HAVEVECS = @havevecs@
+
+AM_CPPFLAGS += @HDEFINES@ @COREFLAG@ @TDEFINES@ $(CSEARCH) $(CSWITCHES) \
+ $(HAVEVECS) @INCINTL@
+
+# C source files that correspond to .o's.
+SOURCE_CFILES = \
+ $(BFD32_LIBS_CFILES) \
+ $(BFD64_LIBS_CFILES) \
+ $(ALL_MACHINES_CFILES) \
+ $(BFD32_BACKENDS_CFILES) \
+ $(BFD64_BACKENDS_CFILES) \
+ $(OPTIONAL_BACKENDS_CFILES)
+
+BUILD_CFILES = \
+ elf32-aarch64.c elf64-aarch64.c \
+ elf32-kvx.c elf64-kvx.c \
+ elf32-ia64.c elf64-ia64.c \
+ elf32-loongarch.c elf64-loongarch.c \
+ elf32-riscv.c elf64-riscv.c \
+ peigen.c pepigen.c pex64igen.c pe-aarch64igen.c pe-loongarch64igen.c \
+ pe-riscv64igen.c
+
+CFILES = $(SOURCE_CFILES) $(BUILD_CFILES)
+
+## This is a list of all .h files in the source tree minus those that
+## are processed to produce other .h files
+SOURCE_HFILES = \
+ aout-target.h aoutx.h arc-got.h arc-plt.h \
+ coff-arm.h coff-bfd.h coffcode.h coffswap.h \
+ cpu-aarch64.h cpu-arm.h cpu-h8300.h cpu-m68k.h cpu-riscv.h \
+ ecoff-bfd.h ecoffswap.h \
+ elf32-arm.h elf32-avr.h elf32-bfin.h elf32-cr16.h elf32-csky.h \
+ elf32-dlx.h elf32-hppa.h elf32-m68hc1x.h elf32-m68k.h \
+ elf32-metag.h elf32-nds32.h elf32-ppc.h \
+ elf32-rx.h elf32-score.h elf32-sh-relocs.h elf32-spu.h \
+ elf32-tic6x.h elf32-tilegx.h elf32-tilepro.h elf32-v850.h \
+ elf64-hppa.h elf64-ppc.h elf64-tilegx.h \
+ elf-bfd.h elfcode.h elfcore.h elf-hppa.h elf-linker-x86.h \
+ elf-linux-core.h elf-nacl.h elf-s390.h elf-vxworks.h \
+ elfxx-aarch64.h elfxx-ia64.h elfxx-mips.h elfxx-riscv.h \
+ elfxx-sparc.h elfxx-tilegx.h elfxx-x86.h elfxx-loongarch.h \
+ genlink.h go32stub.h \
+ libaout.h libbfd.h libcoff.h libecoff.h libhppa.h \
+ libpei.h libxcoff.h \
+ mach-o.h \
+ netbsd.h ns32k.h \
+ pef.h pef-traceback.h peicode.h plugin.h \
+ som.h sysdep.h \
+ version.h vms.h \
+ wasm-module.h \
+ xcofflink.h xsym.h
+
+## ... and .h files which are in the build tree, minus config.h and bfd.h
+BUILD_HFILES = \
+ bfdver.h elf32-target.h elf64-target.h targmatch.h
+
+# Ensure they are built early:
+BUILT_SOURCES = $(BUILD_HFILES) @MAINT@ $(BUILD_CFILES)
+
+HFILES = $(SOURCE_HFILES) $(BUILD_HFILES)
+
+BFD_H_DEPS = $(INCDIR)/ansidecl.h $(INCDIR)/symcat.h $(INCDIR)/diagnostics.h
+LOCAL_H_DEPS = libbfd.h sysdep.h config.h
+$(BFD32_LIBS) \
+ $(BFD64_LIBS) \
+ $(ALL_MACHINES) \
+ $(BFD32_BACKENDS) \
+ $(BFD64_BACKENDS) \
+ $(OPTIONAL_BACKENDS): $(BFD_H) $(BFD_H_DEPS) $(LOCAL_H_DEPS)
+
+SRC_POTFILES = $(SOURCE_CFILES) $(SOURCE_HFILES)
+BLD_POTFILES = $(BUILD_CFILES) $(BUILD_HFILES)
+
+po/SRC-POTFILES.in: @MAINT@ Makefile
+ for file in $(SRC_POTFILES); do echo $$file; done \
+ | LC_ALL=C sort | uniq > tmp.src \
+ && mv tmp.src $(srcdir)/po/SRC-POTFILES.in
+
+po/BLD-POTFILES.in: @MAINT@ Makefile
+ for file in $(BLD_POTFILES); do echo $$file; done \
+ | LC_ALL=C sort | uniq > tmp.bld \
+ && mv tmp.bld $(srcdir)/po/BLD-POTFILES.in
+
+all diststuff: info
+
+# Various kinds of .o files to put in libbfd.a:
+# BFD_BACKENDS Routines the configured targets need.
+# BFD_MACHINES Architecture-specific routines the configured targets need.
+# COREFILE Core file routines for a native configuration
+# bfd64_libs Routines for 64bit support
+OFILES = $(BFD_BACKENDS) $(BFD_MACHINES) @COREFILE@ @bfd64_libs@
+
+stamp-ofiles: Makefile
+ rm -f tofiles
+ f=""; \
+ for i in $(OFILES) ; do \
+ case " $$f " in \
+ *" $$i "*) ;; \
+ *) f="$$f $$i" ;; \
+ esac ; \
+ done ; \
+ echo $$f > tofiles
+ $(SHELL) $(srcdir)/../move-if-change tofiles ofiles
+ touch stamp-ofiles
+
+ofiles: stamp-ofiles ; @true
+
+# Since BFD64_LIBS is optional and we can't have substitution in
+# libbfd_la_SOURCES, we put BFD64_LIBS in OFILES instead.
+# However, list all sources in EXTRA_libbfd_la_SOURCES so the
+# dependency tracking fragments are picked up in the Makefile.
+libbfd_la_SOURCES = $(BFD32_LIBS_CFILES)
+EXTRA_libbfd_la_SOURCES = $(CFILES)
+libbfd_la_DEPENDENCIES = $(OFILES) ofiles ../libsframe/libsframe.la
+libbfd_la_LIBADD = `cat ofiles` @SHARED_LIBADD@ $(LIBDL) $(ZLIB) $(ZSTD_LIBS) ../libsframe/libsframe.la
+libbfd_la_LDFLAGS += -release `cat libtool-soversion` @SHARED_LDFLAGS@
+
+# This file holds an array associating configuration triplets and
+# vector names. It is built from config.bfd. It is not compiled by
+# itself, but is included by targets.c.
+targmatch.h: config.bfd targmatch.sed
+ $(AM_V_at)rm -f targmatch.new
+ $(AM_V_GEN)$(SED) -f $(srcdir)/targmatch.sed < $(srcdir)/config.bfd > targmatch.new
+ $(AM_V_at)mv -f targmatch.new targmatch.h
+
+# When compiling archures.c and targets.c, supply the default target
+# info from configure.
+
+targets.lo: targets.c Makefile
+if am__fastdepCC
+ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $(TDEFAULTS) $(srcdir)/targets.c
+ $(AM_V_at)mv -f $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
+else
+if AMDEP
+ source='targets.c' object='$@' libtool=yes @AMDEPBACKSLASH@
+ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+endif
+ $(AM_V_CC)$(LTCOMPILE) -c -o $@ $(TDEFAULTS) $(srcdir)/targets.c
+endif
+
+archures.lo: archures.c Makefile
+if am__fastdepCC
+ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $(TDEFAULTS) $(srcdir)/archures.c
+ $(AM_V_at)mv -f $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
+else
+if AMDEP
+ source='archures.c' object='$@' libtool=yes @AMDEPBACKSLASH@
+ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+endif
+ $(AM_V_CC)$(LTCOMPILE) -c -o $@ $(TDEFAULTS) $(srcdir)/archures.c
+endif
+
+dwarf2.lo: dwarf2.c Makefile
+if am__fastdepCC
+ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ -DDEBUGDIR=\"$(DEBUGDIR)\" $(srcdir)/dwarf2.c
+ $(AM_V_at)mv -f $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
+else
+if AMDEP
+ source='dwarf2.c' object='$@' libtool=yes @AMDEPBACKSLASH@
+ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+endif
+ $(AM_V_CC)$(LTCOMPILE) -c -o $@ -DDEBUGDIR=\"$(DEBUGDIR)\" $(srcdir)/dwarf2.c
+endif
+
+elf32-target.h : elfxx-target.h
+ $(AM_V_GEN)$(SED) -e s/NN/32/g < $< > $@
+
+elf64-target.h : elfxx-target.h
+ $(AM_V_GEN)$(SED) -e s/NN/64/g < $< > $@
+
+elf32-aarch64.c : elfnn-aarch64.c
+ $(AM_V_at)echo "#line 1 \"$<\"" > $@
+ $(AM_V_GEN)$(SED) -e s/NN/32/g < $< >> $@
+
+elf64-aarch64.c : elfnn-aarch64.c
+ $(AM_V_at)echo "#line 1 \"$<\"" > $@
+ $(AM_V_GEN)$(SED) -e s/NN/64/g < $< >> $@
+
+elf32-ia64.c : elfnn-ia64.c
+ $(AM_V_at)echo "#line 1 \"$<\"" > $@
+ $(AM_V_GEN)$(SED) -e s/NN/32/g < $< >> $@
+
+elf64-ia64.c : elfnn-ia64.c
+ $(AM_V_at)echo "#line 1 \"$<\"" > $@
+ $(AM_V_GEN)$(SED) -e s/NN/64/g < $< >> $@
+
+elf32-kvx.c : elfnn-kvx.c
+ $(AM_V_at)echo "#line 1 \"$<\"" > $@
+ $(AM_V_GEN)$(SED) -e s/NN/32/g < $< >> $@
+
+elf64-kvx.c : elfnn-kvx.c
+ $(AM_V_at)echo "#line 1 \"$<\"" > $@
+ $(AM_V_GEN)$(SED) -e s/NN/64/g < $< >> $@
+
+elf32-loongarch.c : elfnn-loongarch.c
+ $(AM_V_at)echo "#line 1 \"$<\"" > $@
+ $(AM_V_GEN)$(SED) -e s/NN/32/g < $< >> $@
+
+elf64-loongarch.c : elfnn-loongarch.c
+ $(AM_V_at)echo "#line 1 \"$<\"" > $@
+ $(AM_V_GEN)$(SED) -e s/NN/64/g < $< >> $@
+
+elf32-riscv.c : elfnn-riscv.c
+ $(AM_V_at)echo "#line 1 \"$<\"" > $@
+ $(AM_V_GEN)$(SED) -e s/NN/32/g < $< >> $@
+
+elf64-riscv.c : elfnn-riscv.c
+ $(AM_V_at)echo "#line 1 \"$<\"" > $@
+ $(AM_V_GEN)$(SED) -e s/NN/64/g < $< >> $@
+
+peigen.c : peXXigen.c
+ $(AM_V_at)echo "#line 1 \"$<\"" > $@
+ $(AM_V_GEN)$(SED) -e s/XX/pe/g < $< >> $@
+
+pepigen.c : peXXigen.c
+ $(AM_V_at)echo "#line 1 \"$<\"" > $@
+ $(AM_V_GEN)$(SED) -e s/XX/pep/g < $< >> $@
+
+pex64igen.c: peXXigen.c
+ $(AM_V_at)echo "#line 1 \"$<\"" > $@
+ $(AM_V_GEN)$(SED) -e s/XX/pex64/g < $< >> $@
+
+pe-aarch64igen.c: peXXigen.c
+ $(AM_V_at)echo "#line 1 \"$<\"" > $@
+ $(AM_V_GEN)$(SED) -e s/XX/peAArch64/g < $< >> $@
+
+pe-loongarch64igen.c: peXXigen.c
+ $(AM_V_at)echo "#line 1 \"$<\"" > $@
+ $(AM_V_GEN)$(SED) -e s/XX/peLoongArch64/g < $< >> $@
+
+pe-riscv64igen.c: peXXigen.c
+ $(AM_V_at)echo "#line 1 \"peXXigen.c\"" > $@
+ $(AM_V_GEN)$(SED) -e s/XX/peRiscV64/g < $< >> $@
+
+host-aout.lo: Makefile
+
+# The following program can be used to generate a simple config file
+# which can be folded into an h-XXX file for a new host, with some editing.
+aout-params.h: gen-aout
+ ./gen-aout host > aout-params.h
+gen-aout: $(srcdir)/gen-aout.c Makefile
+ $(CC) -o gen-aout $(CFLAGS) $(LFLAGS) $(srcdir)/gen-aout.c
+
+$(BFD_H): stmp-bfd-h ; @true
+
+stmp-bfd-h: bfd-in3.h
+ rm -f bfd-tmp.h
+ cp bfd-in3.h bfd-tmp.h
+ $(SHELL) $(srcdir)/../move-if-change bfd-tmp.h $(BFD_H)
+ rm -f bfd-tmp.h
+ touch stmp-bfd-h
+
+BFD_H_FILES = bfd-in.h libbfd.c hash.c section.c syms.c \
+ archive.c archures.c bfd.c bfdio.c \
+ cache.c compress.c corefile.c format.c linker.c opncls.c \
+ reloc.c simple.c stab-syms.c stabs.c targets.c
+BFD64_H_FILES = archive64.c
+LIBBFD_H_FILES = libbfd-in.h libbfd.c bfd.c bfdio.c \
+ archive.c archures.c cache.c hash.c linker.c opncls.c \
+ reloc.c section.c stabs.c targets.c
+LIBCOFF_H_FILES = libcoff-in.h coffcode.h
+
+headers: stmp-bin2-h stmp-lbfd-h stmp-lcoff-h
+
+# We only rebuild the header files automatically if we have been
+# configured with --enable-maintainer-mode.
+
+REGEN_HEADER = \
+ ( \
+ set -e; \
+ echo "$$H_FILES" | sed -f $(srcdir)/doc/header.sed; \
+ for file in $$H_FILES; do \
+ file="$(srcdir)/$$file"; \
+ case $$file in \
+ *-in.h) cat $$file;; \
+ *) echo $$file | sed -e 's,.*/,,' -e 's,^,/* Extracted from ,' \
+ -e 's,$$,. */,'; \
+ $(MKDOC) $$CHEW_FLAGS -f $(srcdir)/doc/proto.str < $$file;; \
+ esac; \
+ done; \
+ echo "\#ifdef __cplusplus"; \
+ echo "}"; \
+ echo "\#endif"; \
+ echo "\#endif"; \
+ )
+
+$(srcdir)/bfd-in2.h: @MAINT@ stmp-bin2-h ; @true
+stmp-bin2-h: $(BFD_H_FILES) $(BFD64_H_FILES) $(MKDOC)
+ $(AM_V_GEN)H_FILES="$(BFD_H_FILES)" CHEW_FLAGS= ; $(REGEN_HEADER) > bfd-in2.h-new
+ $(AM_V_at)$(SHELL) $(srcdir)/../move-if-change bfd-in2.h-new $(srcdir)/bfd-in2.h
+ $(AM_V_at)touch stmp-bin2-h
+
+$(srcdir)/libbfd.h: @MAINT@ stmp-lbfd-h ; @true
+stmp-lbfd-h: $(LIBBFD_H_FILES) $(MKDOC)
+ $(AM_V_GEN)H_FILES="$(LIBBFD_H_FILES)" CHEW_FLAGS=-i ; $(REGEN_HEADER) > libbfd.h-new
+ $(AM_V_at)$(SHELL) $(srcdir)/../move-if-change libbfd.h-new $(srcdir)/libbfd.h
+ $(AM_V_at)touch stmp-lbfd-h
+
+$(srcdir)/libcoff.h: @MAINT@ stmp-lcoff-h ; @true
+stmp-lcoff-h: $(LIBCOFF_H_FILES) $(MKDOC)
+ $(AM_V_GEN)H_FILES="$(LIBCOFF_H_FILES)" CHEW_FLAGS=-i ; $(REGEN_HEADER) > libcoff.h-new
+ $(AM_V_at)$(SHELL) $(srcdir)/../move-if-change libcoff.h-new $(srcdir)/libcoff.h
+ $(AM_V_at)touch stmp-lcoff-h
+
+MOSTLYCLEANFILES += ofiles stamp-ofiles
+
+CLEANFILES += bfd.h dep.sed stmp-bfd-h DEP DEPA DEP1 DEP2 \
+ stmp-bin2-h stmp-lbfd-h stmp-lcoff-h
+
+DISTCLEANFILES += $(BUILD_CFILES) $(BUILD_HFILES) libtool-soversion
+
+bfdver.h: $(srcdir)/version.h $(srcdir)/development.sh $(srcdir)/Makefile.in
+ $(AM_V_GEN)\
+ bfd_version=`echo "$(VERSION)" | $(SED) -e 's/\([^\.]*\)\.*\([^\.]*\)\.*\([^\.]*\)\.*\([^\.]*\)\.*\([^\.]*\).*/\1.00\2.00\3.00\4.00\5/' -e 's/\([^\.]*\)\..*\(..\)\..*\(..\)\..*\(..\)\..*\(..\)$$/\1\2\3\4\5/'` ;\
+ bfd_version_string="\"$(VERSION)\"" ;\
+ bfd_soversion="$(VERSION)" ;\
+ bfd_version_package="\"$(PKGVERSION)\"" ;\
+ report_bugs_to="\"$(REPORT_BUGS_TO)\"" ;\
+ . $(srcdir)/development.sh ;\
+ if test "$$development" = true ; then \
+ bfd_version_date=`$(SED) -n -e 's/.*DATE //p' < $(srcdir)/version.h` ;\
+ bfd_version_string="\"$(VERSION).$${bfd_version_date}\"" ;\
+ bfd_soversion="$(VERSION).$${bfd_version_date}" ;\
+ fi ;\
+ $(SED) -e "s,@bfd_version@,$$bfd_version," \
+ -e "s,@bfd_version_string@,$$bfd_version_string," \
+ -e "s,@bfd_version_package@,$$bfd_version_package," \
+ -e "s,@report_bugs_to@,$$report_bugs_to," \
+ < $(srcdir)/version.h > $@; \
+ echo "$${bfd_soversion}" > libtool-soversion
+
+# Disable -Werror, if it has been enabled, since coffswap.h won't
+# compile with gcc 4.5 and above.
+coff-tic4x.lo: coff-tic4x.c
+@am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< $(NO_WERROR)
+@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepCC_FALSE@ $(AM_V_CC)$(LTCOMPILE) -c -o $@ $< $(NO_WERROR)
+
+coff-tic54x.lo: coff-tic54x.c
+@am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< $(NO_WERROR)
+@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepCC_FALSE@ $(AM_V_CC)$(LTCOMPILE) -c -o $@ $< $(NO_WERROR)
+
+include doc/local.mk
Index: sources/GNU/binutils/create-2.44-export-demangle-patch/binutils-2.44-new/bfd/Makefile.in
===================================================================
--- sources/GNU/binutils/create-2.44-export-demangle-patch/binutils-2.44-new/bfd/Makefile.in (nonexistent)
+++ sources/GNU/binutils/create-2.44-export-demangle-patch/binutils-2.44-new/bfd/Makefile.in (revision 76)
@@ -0,0 +1,2536 @@
+# Makefile.in generated by automake 1.15.1 from Makefile.am.
+# @configure_input@
+
+# Copyright (C) 1994-2017 Free Software Foundation, Inc.
+
+# This Makefile.in is free software; the Free Software Foundation
+# gives unlimited permission to copy and/or distribute it,
+# with or without modifications, as long as this notice is preserved.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
+# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+# PARTICULAR PURPOSE.
+
+@SET_MAKE@
+
+#
+# Copyright (C) 2012-2025 Free Software Foundation, Inc.
+#
+# This file is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; see the file COPYING3. If not see
+# <http://www.gnu.org/licenses/>.
+#
+
+
+VPATH = @srcdir@
+am__is_gnu_make = { \
+ if test -z '$(MAKELEVEL)'; then \
+ false; \
+ elif test -n '$(MAKE_HOST)'; then \
+ true; \
+ elif test -n '$(MAKE_VERSION)' && test -n '$(CURDIR)'; then \
+ true; \
+ else \
+ false; \
+ fi; \
+}
+am__make_running_with_option = \
+ case $${target_option-} in \
+ ?) ;; \
+ *) echo "am__make_running_with_option: internal error: invalid" \
+ "target option '$${target_option-}' specified" >&2; \
+ exit 1;; \
+ esac; \
+ has_opt=no; \
+ sane_makeflags=$$MAKEFLAGS; \
+ if $(am__is_gnu_make); then \
+ sane_makeflags=$$MFLAGS; \
+ else \
+ case $$MAKEFLAGS in \
+ *\\[\ \ ]*) \
+ bs=\\; \
+ sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
+ | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
+ esac; \
+ fi; \
+ skip_next=no; \
+ strip_trailopt () \
+ { \
+ flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
+ }; \
+ for flg in $$sane_makeflags; do \
+ test $$skip_next = yes && { skip_next=no; continue; }; \
+ case $$flg in \
+ *=*|--*) continue;; \
+ -*I) strip_trailopt 'I'; skip_next=yes;; \
+ -*I?*) strip_trailopt 'I';; \
+ -*O) strip_trailopt 'O'; skip_next=yes;; \
+ -*O?*) strip_trailopt 'O';; \
+ -*l) strip_trailopt 'l'; skip_next=yes;; \
+ -*l?*) strip_trailopt 'l';; \
+ -[dEDm]) skip_next=yes;; \
+ -[JT]) skip_next=yes;; \
+ esac; \
+ case $$flg in \
+ *$$target_option*) has_opt=yes; break;; \
+ esac; \
+ done; \
+ test $$has_opt = yes
+am__make_dryrun = (target_option=n; $(am__make_running_with_option))
+am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
+pkgdatadir = $(datadir)/@PACKAGE@
+pkgincludedir = $(includedir)/@PACKAGE@
+pkglibdir = $(libdir)/@PACKAGE@
+pkglibexecdir = $(libexecdir)/@PACKAGE@
+am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
+install_sh_DATA = $(install_sh) -c -m 644
+install_sh_PROGRAM = $(install_sh) -c
+install_sh_SCRIPT = $(install_sh) -c
+INSTALL_HEADER = $(INSTALL_DATA)
+transform = $(program_transform_name)
+NORMAL_INSTALL = :
+PRE_INSTALL = :
+POST_INSTALL = :
+NORMAL_UNINSTALL = :
+PRE_UNINSTALL = :
+POST_UNINSTALL = :
+build_triplet = @build@
+host_triplet = @host@
+target_triplet = @target@
+@INSTALL_LIBBFD_FALSE@am__append_1 = -rpath $(rpath_bfdlibdir)
+@PLUGINS_TRUE@am__append_2 = $(INCDIR)/plugin-api.h
+subdir = .
+ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
+am__aclocal_m4_deps = $(top_srcdir)/../config/acx.m4 \
+ $(top_srcdir)/../config/bfd64.m4 \
+ $(top_srcdir)/../config/depstand.m4 \
+ $(top_srcdir)/../config/gettext-sister.m4 \
+ $(top_srcdir)/../config/gettext.m4 \
+ $(top_srcdir)/../config/iconv.m4 \
+ $(top_srcdir)/../config/intlmacosx.m4 \
+ $(top_srcdir)/../config/jobserver.m4 \
+ $(top_srcdir)/../config/largefile.m4 \
+ $(top_srcdir)/../config/lead-dot.m4 \
+ $(top_srcdir)/../config/lib-ld.m4 \
+ $(top_srcdir)/../config/lib-link.m4 \
+ $(top_srcdir)/../config/lib-prefix.m4 \
+ $(top_srcdir)/../config/mmap.m4 $(top_srcdir)/../config/nls.m4 \
+ $(top_srcdir)/../config/override.m4 \
+ $(top_srcdir)/../config/pkg.m4 \
+ $(top_srcdir)/../config/plugins.m4 \
+ $(top_srcdir)/../config/po.m4 \
+ $(top_srcdir)/../config/progtest.m4 \
+ $(top_srcdir)/../config/zlib.m4 \
+ $(top_srcdir)/../config/zstd.m4 $(top_srcdir)/../libtool.m4 \
+ $(top_srcdir)/../ltoptions.m4 $(top_srcdir)/../ltsugar.m4 \
+ $(top_srcdir)/../ltversion.m4 $(top_srcdir)/../lt~obsolete.m4 \
+ $(top_srcdir)/ax_tls.m4 $(top_srcdir)/bfd.m4 \
+ $(top_srcdir)/warning.m4 $(top_srcdir)/acinclude.m4 \
+ $(top_srcdir)/version.m4 $(top_srcdir)/configure.ac
+am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
+ $(ACLOCAL_M4)
+DIST_COMMON = $(srcdir)/Makefile.am $(top_srcdir)/configure \
+ $(am__configure_deps) $(am__bfdinclude_HEADERS_DIST)
+am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \
+ configure.lineno config.status.lineno
+mkinstalldirs = $(SHELL) $(top_srcdir)/../mkinstalldirs
+CONFIG_HEADER = config.h
+CONFIG_CLEAN_FILES = bfd-in3.h po/Makefile.in
+CONFIG_CLEAN_VPATH_FILES =
+am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
+am__vpath_adj = case $$p in \
+ $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \
+ *) f=$$p;; \
+ esac;
+am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`;
+am__install_max = 40
+am__nobase_strip_setup = \
+ srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'`
+am__nobase_strip = \
+ for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||"
+am__nobase_list = $(am__nobase_strip_setup); \
+ for p in $$list; do echo "$$p $$p"; done | \
+ sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \
+ $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \
+ if (++n[$$2] == $(am__install_max)) \
+ { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \
+ END { for (dir in files) print dir, files[dir] }'
+am__base_list = \
+ sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \
+ sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g'
+am__uninstall_files_from_dir = { \
+ test -z "$$files" \
+ || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \
+ || { echo " ( cd '$$dir' && rm -f" $$files ")"; \
+ $(am__cd) "$$dir" && rm -f $$files; }; \
+ }
+am__installdirs = "$(DESTDIR)$(bfdlibdir)" "$(DESTDIR)$(infodir)" \
+ "$(DESTDIR)$(bfdincludedir)"
+LTLIBRARIES = $(bfdlib_LTLIBRARIES) $(noinst_LTLIBRARIES)
+am__DEPENDENCIES_1 =
+am__objects_1 = archive.lo archures.lo bfd.lo bfdio.lo cache.lo \
+ coff-bfd.lo compress.lo corefile.lo elf-properties.lo \
+ format.lo hash.lo libbfd.lo linker.lo merge.lo opncls.lo \
+ reloc.lo section.lo simple.lo stab-syms.lo stabs.lo syms.lo \
+ targets.lo binary.lo ihex.lo srec.lo tekhex.lo verilog.lo
+am_libbfd_la_OBJECTS = $(am__objects_1)
+libbfd_la_OBJECTS = $(am_libbfd_la_OBJECTS)
+AM_V_lt = $(am__v_lt_@AM_V@)
+am__v_lt_ = $(am__v_lt_@AM_DEFAULT_V@)
+am__v_lt_0 = --silent
+am__v_lt_1 =
+libbfd_la_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+ $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
+ $(libbfd_la_LDFLAGS) $(LDFLAGS) -o $@
+@INSTALL_LIBBFD_FALSE@am_libbfd_la_rpath =
+@INSTALL_LIBBFD_TRUE@am_libbfd_la_rpath = -rpath $(bfdlibdir)
+AM_V_P = $(am__v_P_@AM_V@)
+am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
+am__v_P_0 = false
+am__v_P_1 = :
+AM_V_GEN = $(am__v_GEN_@AM_V@)
+am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
+am__v_GEN_0 = @echo " GEN " $@;
+am__v_GEN_1 =
+AM_V_at = $(am__v_at_@AM_V@)
+am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
+am__v_at_0 = @
+am__v_at_1 =
+DEFAULT_INCLUDES = -I.@am__isrc@
+depcomp = $(SHELL) $(top_srcdir)/../depcomp
+am__depfiles_maybe = depfiles
+am__mv = mv -f
+COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
+ $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
+LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+ $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \
+ $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \
+ $(AM_CFLAGS) $(CFLAGS)
+AM_V_CC = $(am__v_CC_@AM_V@)
+am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@)
+am__v_CC_0 = @echo " CC " $@;
+am__v_CC_1 =
+CCLD = $(CC)
+LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+ $(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
+ $(AM_LDFLAGS) $(LDFLAGS) -o $@
+AM_V_CCLD = $(am__v_CCLD_@AM_V@)
+am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@)
+am__v_CCLD_0 = @echo " CCLD " $@;
+am__v_CCLD_1 =
+SOURCES = $(libbfd_la_SOURCES) $(EXTRA_libbfd_la_SOURCES)
+AM_V_DVIPS = $(am__v_DVIPS_@AM_V@)
+am__v_DVIPS_ = $(am__v_DVIPS_@AM_DEFAULT_V@)
+am__v_DVIPS_0 = @echo " DVIPS " $@;
+am__v_DVIPS_1 =
+AM_V_MAKEINFO = $(am__v_MAKEINFO_@AM_V@)
+am__v_MAKEINFO_ = $(am__v_MAKEINFO_@AM_DEFAULT_V@)
+am__v_MAKEINFO_0 = @echo " MAKEINFO" $@;
+am__v_MAKEINFO_1 =
+AM_V_INFOHTML = $(am__v_INFOHTML_@AM_V@)
+am__v_INFOHTML_ = $(am__v_INFOHTML_@AM_DEFAULT_V@)
+am__v_INFOHTML_0 = @echo " INFOHTML" $@;
+am__v_INFOHTML_1 =
+AM_V_TEXI2DVI = $(am__v_TEXI2DVI_@AM_V@)
+am__v_TEXI2DVI_ = $(am__v_TEXI2DVI_@AM_DEFAULT_V@)
+am__v_TEXI2DVI_0 = @echo " TEXI2DVI" $@;
+am__v_TEXI2DVI_1 =
+AM_V_TEXI2PDF = $(am__v_TEXI2PDF_@AM_V@)
+am__v_TEXI2PDF_ = $(am__v_TEXI2PDF_@AM_DEFAULT_V@)
+am__v_TEXI2PDF_0 = @echo " TEXI2PDF" $@;
+am__v_TEXI2PDF_1 =
+AM_V_texinfo = $(am__v_texinfo_@AM_V@)
+am__v_texinfo_ = $(am__v_texinfo_@AM_DEFAULT_V@)
+am__v_texinfo_0 = -q
+am__v_texinfo_1 =
+AM_V_texidevnull = $(am__v_texidevnull_@AM_V@)
+am__v_texidevnull_ = $(am__v_texidevnull_@AM_DEFAULT_V@)
+am__v_texidevnull_0 = > /dev/null
+am__v_texidevnull_1 =
+am__dirstamp = $(am__leading_dot)dirstamp
+INFO_DEPS = doc/bfd.info
+am__TEXINFO_TEX_DIR = $(srcdir)
+DVIS = doc/bfd.dvi
+PDFS = doc/bfd.pdf
+PSS = doc/bfd.ps
+HTMLS = doc/bfd.html
+TEXINFOS = doc/bfd.texi
+TEXI2PDF = $(TEXI2DVI) --pdf --batch
+MAKEINFOHTML = $(MAKEINFO) --html
+AM_MAKEINFOHTMLFLAGS = $(AM_MAKEINFOFLAGS)
+DVIPS = dvips
+RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \
+ ctags-recursive dvi-recursive html-recursive info-recursive \
+ install-data-recursive install-dvi-recursive \
+ install-exec-recursive install-html-recursive \
+ install-info-recursive install-pdf-recursive \
+ install-ps-recursive install-recursive installcheck-recursive \
+ installdirs-recursive pdf-recursive ps-recursive \
+ tags-recursive uninstall-recursive
+am__can_run_installinfo = \
+ case $$AM_UPDATE_INFO_DIR in \
+ n|no|NO) false;; \
+ *) (install-info --version) >/dev/null 2>&1;; \
+ esac
+am__bfdinclude_HEADERS_DIST = $(INCDIR)/plugin-api.h bfd.h \
+ $(INCDIR)/ansidecl.h $(INCDIR)/symcat.h \
+ $(INCDIR)/diagnostics.h $(INCDIR)/bfdlink.h $(INCDIR)/demangle.h
+HEADERS = $(bfdinclude_HEADERS)
+RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \
+ distclean-recursive maintainer-clean-recursive
+am__recursive_targets = \
+ $(RECURSIVE_TARGETS) \
+ $(RECURSIVE_CLEAN_TARGETS) \
+ $(am__extra_recursive_targets)
+AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \
+ cscope
+am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) \
+ $(LISP)config.in
+# Read a list of newline-separated strings from the standard input,
+# and print each of them once, without duplicates. Input order is
+# *not* preserved.
+am__uniquify_input = $(AWK) '\
+ BEGIN { nonempty = 0; } \
+ { items[$$0] = 1; nonempty = 1; } \
+ END { if (nonempty) { for (i in items) print i; }; } \
+'
+# Make sure the list of sources is unique. This is necessary because,
+# e.g., the same source file might be shared among _SOURCES variables
+# for different programs/libraries.
+am__define_uniq_tagged_files = \
+ list='$(am__tagged_files)'; \
+ unique=`for i in $$list; do \
+ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
+ done | $(am__uniquify_input)`
+ETAGS = etags
+CTAGS = ctags
+CSCOPE = cscope
+DIST_SUBDIRS = $(SUBDIRS)
+ACLOCAL = @ACLOCAL@
+AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
+AR = @AR@
+AUTOCONF = @AUTOCONF@
+AUTOHEADER = @AUTOHEADER@
+AUTOMAKE = @AUTOMAKE@
+AWK = @AWK@
+CATALOGS = @CATALOGS@
+CATOBJEXT = @CATOBJEXT@
+CC = @CC@
+CCDEPMODE = @CCDEPMODE@
+CC_FOR_BUILD = @CC_FOR_BUILD@
+CFLAGS = @CFLAGS@
+COREFILE = @COREFILE@
+COREFLAG = @COREFLAG@
+CPP = @CPP@
+CPPFLAGS = @CPPFLAGS@
+CYGPATH_W = @CYGPATH_W@
+DATADIRNAME = @DATADIRNAME@
+DEBUGDIR = @DEBUGDIR@
+DEFS = @DEFS@
+DEPDIR = @DEPDIR@
+DSYMUTIL = @DSYMUTIL@
+DUMPBIN = @DUMPBIN@
+ECHO_C = @ECHO_C@
+ECHO_N = @ECHO_N@
+ECHO_T = @ECHO_T@
+EGREP = @EGREP@
+EXEEXT = @EXEEXT@
+EXEEXT_FOR_BUILD = @EXEEXT_FOR_BUILD@
+FGREP = @FGREP@
+GENCAT = @GENCAT@
+GMSGFMT = @GMSGFMT@
+GREP = @GREP@
+HDEFINES = @HDEFINES@
+INCINTL = @INCINTL@
+INSTALL = @INSTALL@
+INSTALL_DATA = @INSTALL_DATA@
+INSTALL_PROGRAM = @INSTALL_PROGRAM@
+INSTALL_SCRIPT = @INSTALL_SCRIPT@
+INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
+INSTOBJEXT = @INSTOBJEXT@
+INTLLIBS = @INTLLIBS@
+INTL_MACOSX_LIBS = @INTL_MACOSX_LIBS@
+LARGEFILE_CPPFLAGS = @LARGEFILE_CPPFLAGS@
+LD = @LD@
+LDFLAGS = @LDFLAGS@
+LIBICONV = @LIBICONV@
+LIBINTL = @LIBINTL@
+LIBINTL_DEP = @LIBINTL_DEP@
+LIBM = @LIBM@
+LIBOBJS = @LIBOBJS@
+LIBS = @LIBS@
+LIBTOOL = @LIBTOOL@
+LIPO = @LIPO@
+LN_S = @LN_S@
+LTLIBICONV = @LTLIBICONV@
+LTLIBINTL = @LTLIBINTL@
+LTLIBOBJS = @LTLIBOBJS@
+MAINT = @MAINT@
+MAKEINFO = @MAKEINFO@
+MKDIR_P = @MKDIR_P@
+MKINSTALLDIRS = @MKINSTALLDIRS@
+MSGFMT = @MSGFMT@
+MSGMERGE = @MSGMERGE@
+NM = @NM@
+NMEDIT = @NMEDIT@
+NO_WERROR = @NO_WERROR@
+OBJDUMP = @OBJDUMP@
+OBJEXT = @OBJEXT@
+OTOOL = @OTOOL@
+OTOOL64 = @OTOOL64@
+PACKAGE = @PACKAGE@
+PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
+PACKAGE_NAME = @PACKAGE_NAME@
+PACKAGE_STRING = @PACKAGE_STRING@
+PACKAGE_TARNAME = @PACKAGE_TARNAME@
+PACKAGE_URL = @PACKAGE_URL@
+PACKAGE_VERSION = @PACKAGE_VERSION@
+PATH_SEPARATOR = @PATH_SEPARATOR@
+PKGVERSION = @PKGVERSION@
+PKG_CONFIG = @PKG_CONFIG@
+PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@
+PKG_CONFIG_PATH = @PKG_CONFIG_PATH@
+POSUB = @POSUB@
+RANLIB = @RANLIB@
+REPORT_BUGS_TEXI = @REPORT_BUGS_TEXI@
+REPORT_BUGS_TO = @REPORT_BUGS_TO@
+SED = @SED@
+SET_MAKE = @SET_MAKE@
+SHARED_LDFLAGS = @SHARED_LDFLAGS@
+SHARED_LIBADD = @SHARED_LIBADD@
+SHELL = @SHELL@
+STRIP = @STRIP@
+TDEFINES = @TDEFINES@
+USE_NLS = @USE_NLS@
+VERSION = @VERSION@
+WARN_CFLAGS = @WARN_CFLAGS@
+WARN_CFLAGS_FOR_BUILD = @WARN_CFLAGS_FOR_BUILD@
+WARN_WRITE_STRINGS = @WARN_WRITE_STRINGS@
+XGETTEXT = @XGETTEXT@
+ZSTD_CFLAGS = @ZSTD_CFLAGS@
+ZSTD_LIBS = @ZSTD_LIBS@
+abs_builddir = @abs_builddir@
+abs_srcdir = @abs_srcdir@
+abs_top_builddir = @abs_top_builddir@
+abs_top_srcdir = @abs_top_srcdir@
+ac_ct_CC = @ac_ct_CC@
+ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
+all_backends = @all_backends@
+am__include = @am__include@
+am__leading_dot = @am__leading_dot@
+am__quote = @am__quote@
+am__tar = @am__tar@
+am__untar = @am__untar@
+bfd64_libs = @bfd64_libs@
+bfd_backends = @bfd_backends@
+bfd_default_target_size = @bfd_default_target_size@
+bfd_file_ptr = @bfd_file_ptr@
+bfd_machines = @bfd_machines@
+bfd_ufile_ptr = @bfd_ufile_ptr@
+@INSTALL_LIBBFD_FALSE@bfdincludedir =
+@INSTALL_LIBBFD_TRUE@bfdincludedir = @bfdincludedir@
+# Empty these so that the respective installation directories will not be created.
+@INSTALL_LIBBFD_FALSE@bfdlibdir =
+@INSTALL_LIBBFD_TRUE@bfdlibdir = @bfdlibdir@
+bindir = @bindir@
+build = @build@
+build_alias = @build_alias@
+build_cpu = @build_cpu@
+build_os = @build_os@
+build_vendor = @build_vendor@
+builddir = @builddir@
+datadir = @datadir@
+datarootdir = @datarootdir@
+docdir = @docdir@
+dvidir = @dvidir@
+exec_prefix = @exec_prefix@
+havevecs = @havevecs@
+host = @host@
+host_alias = @host_alias@
+host_cpu = @host_cpu@
+host_noncanonical = @host_noncanonical@
+host_os = @host_os@
+host_vendor = @host_vendor@
+htmldir = @htmldir@
+includedir = @includedir@
+infodir = @infodir@
+install_sh = @install_sh@
+libdir = @libdir@
+libexecdir = @libexecdir@
+localedir = @localedir@
+localstatedir = @localstatedir@
+lt_cv_dlopen_libs = @lt_cv_dlopen_libs@
+mandir = @mandir@
+mkdir_p = @mkdir_p@
+oldincludedir = @oldincludedir@
+pdfdir = @pdfdir@
+prefix = @prefix@
+program_transform_name = @program_transform_name@
+psdir = @psdir@
+sbindir = @sbindir@
+sharedstatedir = @sharedstatedir@
+srcdir = @srcdir@
+supports_plugins = @supports_plugins@
+sysconfdir = @sysconfdir@
+target = @target@
+target_alias = @target_alias@
+target_cpu = @target_cpu@
+target_noncanonical = @target_noncanonical@
+target_os = @target_os@
+target_vendor = @target_vendor@
+tdefaults = @tdefaults@
+top_build_prefix = @top_build_prefix@
+top_builddir = @top_builddir@
+top_srcdir = @top_srcdir@
+wordsize = @wordsize@
+zlibdir = @zlibdir@
+zlibinc = @zlibinc@
+AUTOMAKE_OPTIONS = no-dist foreign info-in-builddir no-texinfo.tex
+ACLOCAL_AMFLAGS = -I . -I .. -I ../config
+MOSTLYCLEANFILES = ofiles stamp-ofiles $(MKDOC) doc/*.o doc/*.stamp
+CLEANFILES = bfd.h dep.sed stmp-bfd-h DEP DEPA DEP1 DEP2 stmp-bin2-h \
+ stmp-lbfd-h stmp-lcoff-h
+DISTCLEANFILES = $(BUILD_CFILES) $(BUILD_HFILES) libtool-soversion \
+ doc/bfd.?? doc/bfd.??? texput.log
+MAINTAINERCLEANFILES = $(DOCFILES) doc/bfd.info
+INCDIR = $(srcdir)/../include
+CSEARCH = -I. -I$(srcdir) -I$(INCDIR)
+SUBDIRS = po
+bfddocdir = doc
+libbfd_la_LDFLAGS = $(am__append_1) -release `cat libtool-soversion` \
+ @SHARED_LDFLAGS@ $(am__empty)
+@INSTALL_LIBBFD_TRUE@bfdlib_LTLIBRARIES = libbfd.la
+@INSTALL_LIBBFD_FALSE@bfdinclude_HEADERS = $(am__append_2)
+@INSTALL_LIBBFD_TRUE@bfdinclude_HEADERS = $(BFD_H) \
+@INSTALL_LIBBFD_TRUE@ $(INCDIR)/ansidecl.h $(INCDIR)/symcat.h \
+@INSTALL_LIBBFD_TRUE@ $(INCDIR)/diagnostics.h $(INCDIR)/demangle.h \
+@INSTALL_LIBBFD_TRUE@ $(INCDIR)/bfdlink.h $(am__append_2)
+@INSTALL_LIBBFD_FALSE@rpath_bfdlibdir = @bfdlibdir@
+@INSTALL_LIBBFD_FALSE@noinst_LTLIBRARIES = libbfd.la
+
+# This is where we get zlib from. zlibdir is -L../zlib and zlibinc is
+# -I../zlib, unless we were configured with --with-system-zlib, in which
+# case both are empty.
+ZLIB = @zlibdir@ -lz
+ZLIBINC = @zlibinc@
+AM_CFLAGS = $(WARN_CFLAGS) $(ZLIBINC) $(ZSTD_CFLAGS)
+AM_CPPFLAGS = -DBINDIR='"$(bindir)"' -DLIBDIR='"$(libdir)"' \
+ @LARGEFILE_CPPFLAGS@ @HDEFINES@ @COREFLAG@ @TDEFINES@ \
+ $(CSEARCH) $(CSWITCHES) $(HAVEVECS) @INCINTL@
+@PLUGINS_TRUE@LIBDL = @lt_cv_dlopen_libs@
+
+# bfd.h goes here, for now
+BFD_H = bfd.h
+
+# Jim Kingdon notes:
+# Writing S-records should be included in all (or at least most)
+# *-*-coff, *-*-aout, etc., configurations, because people will want to
+# be able to use objcopy to create S-records. (S-records are not useful
+# for the debugger, so if you are downloading things as S-records you
+# need two copies of the executable, one to download and one for the
+# debugger).
+BFD32_LIBS = \
+ archive.lo archures.lo bfd.lo bfdio.lo cache.lo \
+ coff-bfd.lo compress.lo corefile.lo elf-properties.lo format.lo \
+ hash.lo libbfd.lo linker.lo merge.lo opncls.lo reloc.lo \
+ section.lo simple.lo stab-syms.lo stabs.lo syms.lo targets.lo \
+ binary.lo ihex.lo srec.lo tekhex.lo verilog.lo
+
+BFD64_LIBS = archive64.lo
+BFD32_LIBS_CFILES = \
+ archive.c archures.c bfd.c bfdio.c cache.c coff-bfd.c \
+ compress.c corefile.c elf-properties.c format.c hash.c \
+ libbfd.c linker.c merge.c opncls.c reloc.c \
+ section.c simple.c stab-syms.c stabs.c syms.c targets.c \
+ binary.c ihex.c srec.c tekhex.c verilog.c
+
+BFD64_LIBS_CFILES = archive64.c
+
+# This list is alphabetized to make it easier to keep in sync
+# with the decls and initializer in archures.c.
+ALL_MACHINES = \
+ cpu-aarch64.lo \
+ cpu-alpha.lo \
+ cpu-amdgcn.lo \
+ cpu-arc.lo \
+ cpu-arm.lo \
+ cpu-avr.lo \
+ cpu-bfin.lo \
+ cpu-bpf.lo \
+ cpu-cr16.lo \
+ cpu-cris.lo \
+ cpu-crx.lo \
+ cpu-csky.lo \
+ cpu-d10v.lo \
+ cpu-d30v.lo \
+ cpu-dlx.lo \
+ cpu-epiphany.lo \
+ cpu-fr30.lo \
+ cpu-frv.lo \
+ cpu-ft32.lo \
+ cpu-h8300.lo \
+ cpu-hppa.lo \
+ cpu-i386.lo \
+ cpu-ia64.lo \
+ cpu-iamcu.lo \
+ cpu-ip2k.lo \
+ cpu-iq2000.lo \
+ cpu-kvx.lo \
+ cpu-lm32.lo \
+ cpu-loongarch.lo \
+ cpu-m10200.lo \
+ cpu-m10300.lo \
+ cpu-m32c.lo \
+ cpu-m32r.lo \
+ cpu-m68hc11.lo \
+ cpu-m68hc12.lo \
+ cpu-m68k.lo \
+ cpu-m9s12x.lo \
+ cpu-m9s12xg.lo \
+ cpu-mcore.lo \
+ cpu-mep.lo \
+ cpu-metag.lo \
+ cpu-microblaze.lo \
+ cpu-mips.lo \
+ cpu-mmix.lo \
+ cpu-moxie.lo \
+ cpu-msp430.lo \
+ cpu-mt.lo \
+ cpu-nds32.lo \
+ cpu-nfp.lo \
+ cpu-ns32k.lo \
+ cpu-or1k.lo \
+ cpu-pdp11.lo \
+ cpu-pj.lo \
+ cpu-powerpc.lo \
+ cpu-pru.lo \
+ cpu-riscv.lo \
+ cpu-rl78.lo \
+ cpu-rs6000.lo \
+ cpu-rx.lo \
+ cpu-s12z.lo \
+ cpu-s390.lo \
+ cpu-score.lo \
+ cpu-sh.lo \
+ cpu-sparc.lo \
+ cpu-spu.lo \
+ cpu-tic30.lo \
+ cpu-tic4x.lo \
+ cpu-tic54x.lo \
+ cpu-tic6x.lo \
+ cpu-tilegx.lo \
+ cpu-tilepro.lo \
+ cpu-v850.lo \
+ cpu-v850_rh850.lo \
+ cpu-vax.lo \
+ cpu-visium.lo \
+ cpu-wasm32.lo \
+ cpu-xgate.lo \
+ cpu-xstormy16.lo \
+ cpu-xtensa.lo \
+ cpu-z80.lo \
+ cpu-z8k.lo
+
+ALL_MACHINES_CFILES = \
+ cpu-aarch64.c \
+ cpu-alpha.c \
+ cpu-amdgcn.c \
+ cpu-arc.c \
+ cpu-arm.c \
+ cpu-avr.c \
+ cpu-bfin.c \
+ cpu-bpf.c \
+ cpu-cr16.c \
+ cpu-cris.c \
+ cpu-crx.c \
+ cpu-csky.c \
+ cpu-d10v.c \
+ cpu-d30v.c \
+ cpu-dlx.c \
+ cpu-epiphany.c \
+ cpu-fr30.c \
+ cpu-frv.c \
+ cpu-ft32.c \
+ cpu-h8300.c \
+ cpu-hppa.c \
+ cpu-i386.c \
+ cpu-ia64.c \
+ cpu-iamcu.c \
+ cpu-ip2k.c \
+ cpu-iq2000.c \
+ cpu-kvx.c \
+ cpu-lm32.c \
+ cpu-loongarch.c \
+ cpu-m10200.c \
+ cpu-m10300.c \
+ cpu-m32c.c \
+ cpu-m32r.c \
+ cpu-m68hc11.c \
+ cpu-m68hc12.c \
+ cpu-m68k.c \
+ cpu-m9s12x.c \
+ cpu-m9s12xg.c \
+ cpu-mcore.c \
+ cpu-mep.c \
+ cpu-metag.c \
+ cpu-microblaze.c \
+ cpu-mips.c \
+ cpu-mmix.c \
+ cpu-moxie.c \
+ cpu-msp430.c \
+ cpu-mt.c \
+ cpu-nds32.c \
+ cpu-nfp.c \
+ cpu-ns32k.c \
+ cpu-or1k.c \
+ cpu-pdp11.c \
+ cpu-pj.c \
+ cpu-powerpc.c \
+ cpu-pru.c \
+ cpu-riscv.c \
+ cpu-rl78.c \
+ cpu-rs6000.c \
+ cpu-rx.c \
+ cpu-s12z.c \
+ cpu-s390.c \
+ cpu-score.c \
+ cpu-sh.c \
+ cpu-sparc.c \
+ cpu-spu.c \
+ cpu-tic30.c \
+ cpu-tic4x.c \
+ cpu-tic54x.c \
+ cpu-tic6x.c \
+ cpu-tilegx.c \
+ cpu-tilepro.c \
+ cpu-v850.c \
+ cpu-v850_rh850.c \
+ cpu-vax.c \
+ cpu-visium.c \
+ cpu-wasm32.c \
+ cpu-xgate.c \
+ cpu-xstormy16.c \
+ cpu-xtensa.c \
+ cpu-z80.c \
+ cpu-z8k.c
+
+
+# The .o files needed by all of the 32 bit vectors that are configured into
+# target_vector in targets.c if configured with --enable-targets=all.
+BFD32_BACKENDS = \
+ aout-cris.lo \
+ aout-ns32k.lo \
+ aout32.lo \
+ cf-i386lynx.lo \
+ coff-go32.lo \
+ coff-i386.lo \
+ coff-mips.lo \
+ coff-rs6000.lo \
+ coff-sh.lo \
+ coff-stgo32.lo \
+ coff-tic30.lo \
+ coff-tic4x.lo \
+ coff-tic54x.lo \
+ coff-z80.lo \
+ coff-z8k.lo \
+ coffgen.lo \
+ cofflink.lo \
+ dwarf1.lo \
+ dwarf2.lo \
+ ecoff.lo \
+ ecofflink.lo \
+ elf-attrs.lo \
+ elf-eh-frame.lo \
+ elf-ifunc.lo \
+ elf-m10200.lo \
+ elf-m10300.lo \
+ elf-nacl.lo \
+ elf-sframe.lo \
+ elf-strtab.lo \
+ elf-vxworks.lo \
+ elf.lo \
+ elf32-am33lin.lo \
+ elf32-arc.lo \
+ elf32-arm.lo \
+ elf32-avr.lo \
+ elf32-bfin.lo \
+ elf32-cr16.lo \
+ elf32-cris.lo \
+ elf32-crx.lo \
+ elf32-csky.lo \
+ elf32-d10v.lo \
+ elf32-d30v.lo \
+ elf32-dlx.lo \
+ elf32-epiphany.lo \
+ elf32-fr30.lo \
+ elf32-frv.lo \
+ elf32-ft32.lo \
+ elf32-gen.lo \
+ elf32-h8300.lo \
+ elf32-hppa.lo \
+ elf32-i386.lo \
+ elf32-ip2k.lo \
+ elf32-iq2000.lo \
+ elf32-lm32.lo \
+ elf32-m32c.lo \
+ elf32-m32r.lo \
+ elf32-m68hc11.lo \
+ elf32-m68hc12.lo \
+ elf32-m68hc1x.lo \
+ elf32-m68k.lo \
+ elf32-mcore.lo \
+ elf32-mep.lo \
+ elf32-metag.lo \
+ elf32-microblaze.lo \
+ elf32-moxie.lo \
+ elf32-msp430.lo \
+ elf32-mt.lo \
+ elf32-nds32.lo \
+ elf32-or1k.lo \
+ elf32-pj.lo \
+ elf32-ppc.lo \
+ elf32-pru.lo \
+ elf32-rl78.lo \
+ elf32-rx.lo \
+ elf32-s12z.lo \
+ elf32-s390.lo \
+ elf32-sh.lo \
+ elf32-sparc.lo \
+ elf32-spu.lo \
+ elf32-tic6x.lo \
+ elf32-tilegx.lo \
+ elf32-tilepro.lo \
+ elf32-v850.lo \
+ elf32-vax.lo \
+ elf32-visium.lo \
+ elf32-wasm32.lo \
+ elf32-xgate.lo \
+ elf32-xstormy16.lo \
+ elf32-xtensa.lo \
+ elf32-z80.lo \
+ elf32.lo \
+ elflink.lo \
+ elfxx-sparc.lo \
+ elfxx-tilegx.lo \
+ elfxx-x86.lo \
+ i386aout.lo \
+ i386bsd.lo \
+ i386lynx.lo \
+ i386msdos.lo \
+ mach-o-arm.lo \
+ mach-o-i386.lo \
+ mach-o.lo \
+ ns32knetbsd.lo \
+ pc532-mach.lo \
+ pdb.lo \
+ pdp11.lo \
+ pe-arm-wince.lo \
+ pe-arm.lo \
+ pe-i386.lo \
+ pe-mcore.lo \
+ pe-sh.lo \
+ pef.lo \
+ pei-arm-wince.lo \
+ pei-arm.lo \
+ pei-i386.lo \
+ pei-mcore.lo \
+ pei-sh.lo \
+ peigen.lo \
+ plugin.lo \
+ ppcboot.lo \
+ reloc16.lo \
+ som.lo \
+ vax1knetbsd.lo \
+ vaxnetbsd.lo \
+ vms-lib.lo \
+ vms-misc.lo \
+ wasm-module.lo \
+ xcofflink.lo \
+ xsym.lo \
+ xtensa-dynconfig.lo \
+ xtensa-isa.lo \
+ xtensa-modules.lo
+
+BFD32_BACKENDS_CFILES = \
+ aout-cris.c \
+ aout-ns32k.c \
+ aout32.c \
+ cf-i386lynx.c \
+ coff-go32.c \
+ coff-i386.c \
+ coff-mips.c \
+ coff-rs6000.c \
+ coff-sh.c \
+ coff-stgo32.c \
+ coff-tic30.c \
+ coff-tic4x.c \
+ coff-tic54x.c \
+ coff-z80.c \
+ coff-z8k.c \
+ coffgen.c \
+ cofflink.c \
+ dwarf1.c \
+ dwarf2.c \
+ ecoff.c \
+ ecofflink.c \
+ elf-attrs.c \
+ elf-eh-frame.c \
+ elf-ifunc.c \
+ elf-m10200.c \
+ elf-m10300.c \
+ elf-nacl.c \
+ elf-sframe.c \
+ elf-strtab.c \
+ elf-vxworks.c \
+ elf.c \
+ elf32-am33lin.c \
+ elf32-arc.c \
+ elf32-arm.c \
+ elf32-avr.c \
+ elf32-bfin.c \
+ elf32-cr16.c \
+ elf32-cris.c \
+ elf32-crx.c \
+ elf32-csky.c \
+ elf32-d10v.c \
+ elf32-d30v.c \
+ elf32-dlx.c \
+ elf32-epiphany.c \
+ elf32-fr30.c \
+ elf32-frv.c \
+ elf32-ft32.c \
+ elf32-gen.c \
+ elf32-h8300.c \
+ elf32-hppa.c \
+ elf32-i386.c \
+ elf32-ip2k.c \
+ elf32-iq2000.c \
+ elf32-lm32.c \
+ elf32-m32c.c \
+ elf32-m32r.c \
+ elf32-m68hc11.c \
+ elf32-m68hc12.c \
+ elf32-m68hc1x.c \
+ elf32-m68k.c \
+ elf32-mcore.c \
+ elf32-mep.c \
+ elf32-metag.c \
+ elf32-microblaze.c \
+ elf32-moxie.c \
+ elf32-msp430.c \
+ elf32-mt.c \
+ elf32-nds32.c \
+ elf32-or1k.c \
+ elf32-pj.c \
+ elf32-ppc.c \
+ elf32-pru.c \
+ elf32-rl78.c \
+ elf32-rx.c \
+ elf32-s12z.c \
+ elf32-s390.c \
+ elf32-sh.c \
+ elf32-sparc.c \
+ elf32-spu.c \
+ elf32-tic6x.c \
+ elf32-tilegx.c \
+ elf32-tilepro.c \
+ elf32-v850.c \
+ elf32-vax.c \
+ elf32-visium.c \
+ elf32-wasm32.c \
+ elf32-xgate.c \
+ elf32-xstormy16.c \
+ elf32-xtensa.c \
+ elf32-z80.c \
+ elf32.c \
+ elflink.c \
+ elfxx-sparc.c \
+ elfxx-tilegx.c \
+ elfxx-x86.c \
+ i386aout.c \
+ i386bsd.c \
+ i386lynx.c \
+ i386msdos.c \
+ mach-o-arm.c \
+ mach-o-i386.c \
+ mach-o.c \
+ ns32knetbsd.c \
+ pc532-mach.c \
+ pdb.c \
+ pdp11.c \
+ pe-arm-wince.c \
+ pe-arm.c \
+ pe-i386.c \
+ pe-mcore.c \
+ pe-sh.c \
+ pef.c \
+ pei-arm-wince.c \
+ pei-arm.c \
+ pei-i386.c \
+ pei-mcore.c \
+ pei-sh.c \
+ plugin.c \
+ ppcboot.c \
+ reloc16.c \
+ som.c \
+ vax1knetbsd.c \
+ vaxnetbsd.c \
+ vms-lib.c \
+ vms-misc.c \
+ wasm-module.c \
+ xcofflink.c \
+ xsym.c \
+ xtensa-dynconfig.c \
+ xtensa-isa.c \
+ xtensa-modules.c
+
+
+# The .o files needed by all of the 64 bit vectors that are configured into
+# target_vector in targets.c if configured with --enable-targets=all
+# and --enable-64-bit-bfd.
+# elf32-ia64.c requires a 64-bit bfd_vma, and hence can not be put in
+# BFD32_BACKENDS.
+BFD64_BACKENDS = \
+ aix5ppc-core.lo \
+ aout64.lo \
+ coff-alpha.lo \
+ coff-x86_64.lo \
+ coff64-rs6000.lo \
+ elf32-aarch64.lo \
+ elf32-ia64.lo \
+ elf32-kvx.lo \
+ elf32-loongarch.lo \
+ elf32-mips.lo \
+ elf32-riscv.lo \
+ elf32-score.lo \
+ elf32-score7.lo \
+ elf64-aarch64.lo \
+ elf64-alpha.lo \
+ elf64-amdgcn.lo \
+ elf64-bpf.lo \
+ elf64-gen.lo \
+ elf64-hppa.lo \
+ elf64-ia64-vms.lo \
+ elf64-ia64.lo \
+ elf64-kvx.lo \
+ elf64-loongarch.lo \
+ elf64-mips.lo \
+ elf64-mmix.lo \
+ elf64-nfp.lo \
+ elf64-ppc.lo \
+ elf64-riscv.lo \
+ elf64-s390.lo \
+ elf64-sparc.lo \
+ elf64-tilegx.lo \
+ elf64-x86-64.lo \
+ elf64.lo \
+ elfn32-mips.lo \
+ elfxx-aarch64.lo \
+ elfxx-ia64.lo \
+ elfxx-kvx.lo \
+ elfxx-loongarch.lo \
+ elfxx-mips.lo \
+ elfxx-riscv.lo \
+ elfxx-x86.lo \
+ mach-o-aarch64.lo \
+ mach-o-x86-64.lo \
+ mmo.lo \
+ pe-aarch64.lo \
+ pe-aarch64igen.lo \
+ pe-loongarch64igen.lo \
+ pe-riscv64igen.lo \
+ pe-x86_64.lo \
+ pei-aarch64.lo \
+ pei-ia64.lo \
+ pei-loongarch64.lo \
+ pei-riscv64.lo \
+ pei-x86_64.lo \
+ pepigen.lo \
+ pex64igen.lo \
+ vms-alpha.lo
+
+BFD64_BACKENDS_CFILES = \
+ aix5ppc-core.c \
+ aout64.c \
+ coff-alpha.c \
+ coff-x86_64.c \
+ coff64-rs6000.c \
+ elf32-mips.c \
+ elf32-score.c \
+ elf32-score7.c \
+ elf64-alpha.c \
+ elf64-amdgcn.c \
+ elf64-bpf.c \
+ elf64-gen.c \
+ elf64-hppa.c \
+ elf64-ia64-vms.c \
+ elf64-mips.c \
+ elf64-mmix.c \
+ elf64-nfp.c \
+ elf64-ppc.c \
+ elf64-s390.c \
+ elf64-sparc.c \
+ elf64-tilegx.c \
+ elf64-x86-64.c \
+ elf64.c \
+ elfn32-mips.c \
+ elfxx-aarch64.c \
+ elfxx-ia64.c \
+ elfxx-kvx.c \
+ elfxx-loongarch.c \
+ elfxx-mips.c \
+ elfxx-riscv.c \
+ elfxx-x86.c \
+ mach-o-aarch64.c \
+ mach-o-x86-64.c \
+ mmo.c \
+ pe-aarch64.c \
+ pe-x86_64.c \
+ pei-aarch64.c \
+ pei-ia64.c \
+ pei-loongarch64.c \
+ pei-riscv64.c \
+ pei-x86_64.c \
+ vms-alpha.c
+
+OPTIONAL_BACKENDS = \
+ cisco-core.lo \
+ hpux-core.lo \
+ irix-core.lo \
+ lynx-core.lo \
+ netbsd-core.lo \
+ osf-core.lo \
+ rs6000-core.lo \
+ trad-core.lo
+
+OPTIONAL_BACKENDS_CFILES = \
+ cisco-core.c \
+ hpux-core.c \
+ irix-core.c \
+ lynx-core.c \
+ netbsd-core.c \
+ osf-core.c \
+ rs6000-core.c \
+ trad-core.c
+
+
+# Reconfigure if config.bfd or configure.host changes.
+# development.sh is used to determine -Werror default.
+CONFIG_STATUS_DEPENDENCIES = \
+ $(srcdir)/config.bfd \
+ $(srcdir)/configure.host \
+ $(srcdir)/development.sh
+
+
+# These are defined by configure:
+WORDSIZE = @wordsize@
+ALL_BACKENDS = @all_backends@
+BFD_BACKENDS = @bfd_backends@
+BFD_MACHINES = @bfd_machines@
+TDEFAULTS = @tdefaults@
+HAVEVECS = @havevecs@
+
+# C source files that correspond to .o's.
+SOURCE_CFILES = \
+ $(BFD32_LIBS_CFILES) \
+ $(BFD64_LIBS_CFILES) \
+ $(ALL_MACHINES_CFILES) \
+ $(BFD32_BACKENDS_CFILES) \
+ $(BFD64_BACKENDS_CFILES) \
+ $(OPTIONAL_BACKENDS_CFILES)
+
+BUILD_CFILES = \
+ elf32-aarch64.c elf64-aarch64.c \
+ elf32-kvx.c elf64-kvx.c \
+ elf32-ia64.c elf64-ia64.c \
+ elf32-loongarch.c elf64-loongarch.c \
+ elf32-riscv.c elf64-riscv.c \
+ peigen.c pepigen.c pex64igen.c pe-aarch64igen.c pe-loongarch64igen.c \
+ pe-riscv64igen.c
+
+CFILES = $(SOURCE_CFILES) $(BUILD_CFILES)
+SOURCE_HFILES = \
+ aout-target.h aoutx.h arc-got.h arc-plt.h \
+ coff-arm.h coff-bfd.h coffcode.h coffswap.h \
+ cpu-aarch64.h cpu-arm.h cpu-h8300.h cpu-m68k.h cpu-riscv.h \
+ ecoff-bfd.h ecoffswap.h \
+ elf32-arm.h elf32-avr.h elf32-bfin.h elf32-cr16.h elf32-csky.h \
+ elf32-dlx.h elf32-hppa.h elf32-m68hc1x.h elf32-m68k.h \
+ elf32-metag.h elf32-nds32.h elf32-ppc.h \
+ elf32-rx.h elf32-score.h elf32-sh-relocs.h elf32-spu.h \
+ elf32-tic6x.h elf32-tilegx.h elf32-tilepro.h elf32-v850.h \
+ elf64-hppa.h elf64-ppc.h elf64-tilegx.h \
+ elf-bfd.h elfcode.h elfcore.h elf-hppa.h elf-linker-x86.h \
+ elf-linux-core.h elf-nacl.h elf-s390.h elf-vxworks.h \
+ elfxx-aarch64.h elfxx-ia64.h elfxx-mips.h elfxx-riscv.h \
+ elfxx-sparc.h elfxx-tilegx.h elfxx-x86.h elfxx-loongarch.h \
+ genlink.h go32stub.h \
+ libaout.h libbfd.h libcoff.h libecoff.h libhppa.h \
+ libpei.h libxcoff.h \
+ mach-o.h \
+ netbsd.h ns32k.h \
+ pef.h pef-traceback.h peicode.h plugin.h \
+ som.h sysdep.h \
+ version.h vms.h \
+ wasm-module.h \
+ xcofflink.h xsym.h
+
+BUILD_HFILES = \
+ bfdver.h elf32-target.h elf64-target.h targmatch.h
+
+
+# Ensure they are built early:
+BUILT_SOURCES = $(BUILD_HFILES) @MAINT@ $(BUILD_CFILES)
+HFILES = $(SOURCE_HFILES) $(BUILD_HFILES)
+BFD_H_DEPS = $(INCDIR)/ansidecl.h $(INCDIR)/symcat.h $(INCDIR)/diagnostics.h
+LOCAL_H_DEPS = libbfd.h sysdep.h config.h
+SRC_POTFILES = $(SOURCE_CFILES) $(SOURCE_HFILES)
+BLD_POTFILES = $(BUILD_CFILES) $(BUILD_HFILES)
+
+# Various kinds of .o files to put in libbfd.a:
+# BFD_BACKENDS Routines the configured targets need.
+# BFD_MACHINES Architecture-specific routines the configured targets need.
+# COREFILE Core file routines for a native configuration
+# bfd64_libs Routines for 64bit support
+OFILES = $(BFD_BACKENDS) $(BFD_MACHINES) @COREFILE@ @bfd64_libs@
+
+# Since BFD64_LIBS is optional and we can't have substitution in
+# libbfd_la_SOURCES, we put BFD64_LIBS in OFILES instead.
+# However, list all sources in EXTRA_libbfd_la_SOURCES so the
+# dependency tracking fragments are picked up in the Makefile.
+libbfd_la_SOURCES = $(BFD32_LIBS_CFILES)
+EXTRA_libbfd_la_SOURCES = $(CFILES)
+libbfd_la_DEPENDENCIES = $(OFILES) ofiles ../libsframe/libsframe.la
+libbfd_la_LIBADD = `cat ofiles` @SHARED_LIBADD@ $(LIBDL) $(ZLIB) $(ZSTD_LIBS) ../libsframe/libsframe.la
+BFD_H_FILES = bfd-in.h libbfd.c hash.c section.c syms.c \
+ archive.c archures.c bfd.c bfdio.c \
+ cache.c compress.c corefile.c format.c linker.c opncls.c \
+ reloc.c simple.c stab-syms.c stabs.c targets.c
+
+BFD64_H_FILES = archive64.c
+LIBBFD_H_FILES = libbfd-in.h libbfd.c bfd.c bfdio.c \
+ archive.c archures.c cache.c hash.c linker.c opncls.c \
+ reloc.c section.c stabs.c targets.c
+
+LIBCOFF_H_FILES = libcoff-in.h coffcode.h
+
+# We only rebuild the header files automatically if we have been
+# configured with --enable-maintainer-mode.
+REGEN_HEADER = \
+ ( \
+ set -e; \
+ echo "$$H_FILES" | sed -f $(srcdir)/doc/header.sed; \
+ for file in $$H_FILES; do \
+ file="$(srcdir)/$$file"; \
+ case $$file in \
+ *-in.h) cat $$file;; \
+ *) echo $$file | sed -e 's,.*/,,' -e 's,^,/* Extracted from ,' \
+ -e 's,$$,. */,'; \
+ $(MKDOC) $$CHEW_FLAGS -f $(srcdir)/doc/proto.str < $$file;; \
+ esac; \
+ done; \
+ echo "\#ifdef __cplusplus"; \
+ echo "}"; \
+ echo "\#endif"; \
+ echo "\#endif"; \
+ )
+
+DOCFILES = \
+ doc/aoutx.texi \
+ doc/archive.texi \
+ doc/archures.texi \
+ doc/bfdio.texi \
+ doc/bfdt.texi \
+ doc/bfdver.texi \
+ doc/cache.texi \
+ doc/coffcode.texi \
+ doc/corefile.texi \
+ doc/elfcode.texi \
+ doc/elf.texi \
+ doc/format.texi \
+ doc/hash.texi \
+ doc/libbfd.texi \
+ doc/linker.texi \
+ doc/mmo.texi \
+ doc/opncls.texi \
+ doc/reloc.texi \
+ doc/section.texi \
+ doc/syms.texi \
+ doc/targets.texi
+
+
+# SRCDOC, SRCPROT, SRCIPROT only used to sidestep Sun Make bug in interaction
+# between VPATH and suffix rules. If you use GNU Make, perhaps other Makes,
+# you don't need these three:
+SRCDOC = \
+ $(srcdir)/aoutx.h $(srcdir)/archive.c \
+ $(srcdir)/archures.c $(srcdir)/bfd.c \
+ $(srcdir)/cache.c $(srcdir)/coffcode.h \
+ $(srcdir)/corefile.c $(srcdir)/elf.c \
+ $(srcdir)/elfcode.h $(srcdir)/format.c \
+ $(srcdir)/libbfd.c $(srcdir)/opncls.c \
+ $(srcdir)/reloc.c $(srcdir)/section.c \
+ $(srcdir)/syms.c $(srcdir)/targets.c \
+ $(srcdir)/hash.c $(srcdir)/linker.c \
+ $(srcdir)/mmo.c
+
+SRCPROT = $(srcdir)/archive.c $(srcdir)/archures.c \
+ $(srcdir)/bfd.c $(srcdir)/coffcode.h $(srcdir)/corefile.c \
+ $(srcdir)/format.c $(srcdir)/libbfd.c \
+ $(srcdir)/opncls.c $(srcdir)/reloc.c \
+ $(srcdir)/section.c $(srcdir)/syms.c \
+ $(srcdir)/targets.c
+
+SRCIPROT = $(srcdir)/cache.c $(srcdir)/libbfd.c \
+ $(srcdir)/bfdio.c \
+ $(srcdir)/reloc.c $(srcdir)/cpu-h8300.c \
+ $(srcdir)/archures.c
+
+TEXIDIR = $(srcdir)/../texinfo/fsf
+info_TEXINFOS = doc/bfd.texi
+doc_bfd_TEXINFOS = $(DOCFILES) doc/bfdsumm.texi
+AM_MAKEINFOFLAGS = --no-split -I "$(srcdir)/doc" -I doc
+TEXI2DVI = texi2dvi -I "$(srcdir)/doc" -I doc
+MKDOC = doc/chew$(EXEEXT_FOR_BUILD)
+
+# We can't replace these rules with an implicit rule, because
+# makes without VPATH support couldn't find the .h files in `..'.
+
+# We do not depend on chew directly so that we can distribute the info
+# files, and permit people to rebuild them, without requiring the makeinfo
+# program. If somebody tries to rebuild info, but none of the .texi files
+# have changed, then nothing will be rebuilt.
+REGEN_TEXI = \
+ ( \
+ set -e; \
+ $(MKDOC) -f $(srcdir)/doc/doc.str < $< > $@.tmp; \
+ texi=$@; \
+ texi=$${texi%.stamp}.texi; \
+ test -e $$texi || test ! -f $(srcdir)/$$texi || $(LN_S) $(abs_srcdir)/$$texi $$texi; \
+ $(SHELL) $(srcdir)/../move-if-change $@.tmp $$texi; \
+ touch $@; \
+ )
+
+noinst_TEXINFOS = doc/bfdint.texi
+all: $(BUILT_SOURCES) config.h
+ $(MAKE) $(AM_MAKEFLAGS) all-recursive
+
+.SUFFIXES:
+.SUFFIXES: .c .dvi .lo .o .obj .ps
+am--refresh: Makefile
+ @:
+$(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(srcdir)/doc/local.mk $(am__configure_deps)
+ @for dep in $?; do \
+ case '$(am__configure_deps)' in \
+ *$$dep*) \
+ echo ' cd $(srcdir) && $(AUTOMAKE) --foreign'; \
+ $(am__cd) $(srcdir) && $(AUTOMAKE) --foreign \
+ && exit 0; \
+ exit 1;; \
+ esac; \
+ done; \
+ echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign Makefile'; \
+ $(am__cd) $(top_srcdir) && \
+ $(AUTOMAKE) --foreign Makefile
+Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
+ @case '$?' in \
+ *config.status*) \
+ echo ' $(SHELL) ./config.status'; \
+ $(SHELL) ./config.status;; \
+ *) \
+ echo ' cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe)'; \
+ cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe);; \
+ esac;
+$(srcdir)/doc/local.mk $(am__empty):
+
+$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
+ $(SHELL) ./config.status --recheck
+
+$(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps)
+ $(am__cd) $(srcdir) && $(AUTOCONF)
+$(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps)
+ $(am__cd) $(srcdir) && $(ACLOCAL) $(ACLOCAL_AMFLAGS)
+$(am__aclocal_m4_deps):
+
+config.h: stamp-h1
+ @test -f $@ || rm -f stamp-h1
+ @test -f $@ || $(MAKE) $(AM_MAKEFLAGS) stamp-h1
+
+stamp-h1: $(srcdir)/config.in $(top_builddir)/config.status
+ @rm -f stamp-h1
+ cd $(top_builddir) && $(SHELL) ./config.status config.h
+$(srcdir)/config.in: @MAINTAINER_MODE_TRUE@ $(am__configure_deps)
+ ($(am__cd) $(top_srcdir) && $(AUTOHEADER))
+ rm -f stamp-h1
+ touch $@
+
+distclean-hdr:
+ -rm -f config.h stamp-h1
+bfd-in3.h: $(top_builddir)/config.status $(srcdir)/bfd-in2.h
+ cd $(top_builddir) && $(SHELL) ./config.status $@
+po/Makefile.in: $(top_builddir)/config.status $(top_srcdir)/po/Make-in
+ cd $(top_builddir) && $(SHELL) ./config.status $@
+
+install-bfdlibLTLIBRARIES: $(bfdlib_LTLIBRARIES)
+ @$(NORMAL_INSTALL)
+ @list='$(bfdlib_LTLIBRARIES)'; test -n "$(bfdlibdir)" || list=; \
+ list2=; for p in $$list; do \
+ if test -f $$p; then \
+ list2="$$list2 $$p"; \
+ else :; fi; \
+ done; \
+ test -z "$$list2" || { \
+ echo " $(MKDIR_P) '$(DESTDIR)$(bfdlibdir)'"; \
+ $(MKDIR_P) "$(DESTDIR)$(bfdlibdir)" || exit 1; \
+ echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 '$(DESTDIR)$(bfdlibdir)'"; \
+ $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=install $(INSTALL) $(INSTALL_STRIP_FLAG) $$list2 "$(DESTDIR)$(bfdlibdir)"; \
+ }
+
+uninstall-bfdlibLTLIBRARIES:
+ @$(NORMAL_UNINSTALL)
+ @list='$(bfdlib_LTLIBRARIES)'; test -n "$(bfdlibdir)" || list=; \
+ for p in $$list; do \
+ $(am__strip_dir) \
+ echo " $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f '$(DESTDIR)$(bfdlibdir)/$$f'"; \
+ $(LIBTOOL) $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=uninstall rm -f "$(DESTDIR)$(bfdlibdir)/$$f"; \
+ done
+
+clean-bfdlibLTLIBRARIES:
+ -test -z "$(bfdlib_LTLIBRARIES)" || rm -f $(bfdlib_LTLIBRARIES)
+ @list='$(bfdlib_LTLIBRARIES)'; \
+ locs=`for p in $$list; do echo $$p; done | \
+ sed 's|^[^/]*$$|.|; s|/[^/]*$$||; s|$$|/so_locations|' | \
+ sort -u`; \
+ test -z "$$locs" || { \
+ echo rm -f $${locs}; \
+ rm -f $${locs}; \
+ }
+
+clean-noinstLTLIBRARIES:
+ -test -z "$(noinst_LTLIBRARIES)" || rm -f $(noinst_LTLIBRARIES)
+ @list='$(noinst_LTLIBRARIES)'; \
+ locs=`for p in $$list; do echo $$p; done | \
+ sed 's|^[^/]*$$|.|; s|/[^/]*$$||; s|$$|/so_locations|' | \
+ sort -u`; \
+ test -z "$$locs" || { \
+ echo rm -f $${locs}; \
+ rm -f $${locs}; \
+ }
+
+libbfd.la: $(libbfd_la_OBJECTS) $(libbfd_la_DEPENDENCIES) $(EXTRA_libbfd_la_DEPENDENCIES)
+ $(AM_V_CCLD)$(libbfd_la_LINK) $(am_libbfd_la_rpath) $(libbfd_la_OBJECTS) $(libbfd_la_LIBADD) $(LIBS)
+
+mostlyclean-compile:
+ -rm -f *.$(OBJEXT)
+
+distclean-compile:
+ -rm -f *.tab.c
+
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/aix5ppc-core.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/aout-cris.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/aout-ns32k.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/aout32.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/aout64.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/archive.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/archive64.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/archures.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/bfd.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/bfdio.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/binary.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cache.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cf-i386lynx.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cisco-core.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/coff-alpha.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/coff-bfd.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/coff-go32.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/coff-i386.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/coff-mips.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/coff-rs6000.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/coff-sh.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/coff-stgo32.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/coff-tic30.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/coff-tic4x.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/coff-tic54x.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/coff-x86_64.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/coff-z80.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/coff-z8k.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/coff64-rs6000.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/coffgen.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cofflink.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/compress.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/corefile.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-aarch64.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-alpha.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-amdgcn.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-arc.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-arm.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-avr.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-bfin.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-bpf.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-cr16.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-cris.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-crx.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-csky.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-d10v.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-d30v.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-dlx.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-epiphany.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-fr30.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-frv.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-ft32.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-h8300.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-hppa.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-i386.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-ia64.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-iamcu.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-ip2k.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-iq2000.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-kvx.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-lm32.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-loongarch.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-m10200.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-m10300.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-m32c.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-m32r.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-m68hc11.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-m68hc12.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-m68k.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-m9s12x.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-m9s12xg.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-mcore.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-mep.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-metag.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-microblaze.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-mips.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-mmix.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-moxie.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-msp430.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-mt.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-nds32.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-nfp.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-ns32k.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-or1k.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-pdp11.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-pj.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-powerpc.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-pru.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-riscv.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-rl78.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-rs6000.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-rx.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-s12z.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-s390.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-score.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-sh.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-sparc.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-spu.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-tic30.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-tic4x.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-tic54x.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-tic6x.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-tilegx.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-tilepro.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-v850.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-v850_rh850.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-vax.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-visium.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-wasm32.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-xgate.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-xstormy16.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-xtensa.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-z80.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/cpu-z8k.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/dwarf1.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/dwarf2.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ecoff.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ecofflink.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf-attrs.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf-eh-frame.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf-ifunc.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf-m10200.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf-m10300.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf-nacl.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf-properties.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf-sframe.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf-strtab.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf-vxworks.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-aarch64.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-am33lin.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-arc.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-arm.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-avr.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-bfin.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-cr16.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-cris.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-crx.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-csky.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-d10v.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-d30v.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-dlx.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-epiphany.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-fr30.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-frv.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-ft32.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-gen.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-h8300.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-hppa.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-i386.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-ia64.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-ip2k.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-iq2000.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-kvx.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-lm32.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-loongarch.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-m32c.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-m32r.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-m68hc11.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-m68hc12.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-m68hc1x.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-m68k.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-mcore.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-mep.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-metag.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-microblaze.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-mips.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-moxie.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-msp430.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-mt.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-nds32.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-or1k.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-pj.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-ppc.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-pru.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-riscv.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-rl78.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-rx.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-s12z.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-s390.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-score.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-score7.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-sh.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-sparc.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-spu.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-tic6x.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-tilegx.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-tilepro.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-v850.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-vax.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-visium.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-wasm32.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-xgate.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-xstormy16.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-xtensa.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32-z80.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf32.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf64-aarch64.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf64-alpha.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf64-amdgcn.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf64-bpf.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf64-gen.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf64-hppa.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf64-ia64-vms.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf64-ia64.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf64-kvx.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf64-loongarch.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf64-mips.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf64-mmix.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf64-nfp.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf64-ppc.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf64-riscv.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf64-s390.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf64-sparc.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf64-tilegx.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf64-x86-64.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elf64.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elflink.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elfn32-mips.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elfxx-aarch64.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elfxx-ia64.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elfxx-kvx.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elfxx-loongarch.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elfxx-mips.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elfxx-riscv.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elfxx-sparc.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elfxx-tilegx.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/elfxx-x86.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/format.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/hash.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/hpux-core.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/i386aout.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/i386bsd.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/i386lynx.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/i386msdos.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ihex.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/irix-core.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/libbfd.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/linker.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/lynx-core.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mach-o-aarch64.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mach-o-arm.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mach-o-i386.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mach-o-x86-64.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mach-o.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/merge.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mmo.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/netbsd-core.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ns32knetbsd.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/opncls.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/osf-core.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pc532-mach.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pdb.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pdp11.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pe-aarch64.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pe-aarch64igen.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pe-arm-wince.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pe-arm.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pe-i386.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pe-loongarch64igen.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pe-mcore.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pe-riscv64igen.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pe-sh.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pe-x86_64.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pef.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pei-aarch64.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pei-arm-wince.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pei-arm.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pei-i386.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pei-ia64.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pei-loongarch64.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pei-mcore.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pei-riscv64.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pei-sh.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pei-x86_64.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/peigen.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pepigen.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/pex64igen.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/plugin.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ppcboot.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/reloc.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/reloc16.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/rs6000-core.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/section.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/simple.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/som.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/srec.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/stab-syms.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/stabs.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/syms.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/targets.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tekhex.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/trad-core.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/vax1knetbsd.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/vaxnetbsd.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/verilog.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/vms-alpha.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/vms-lib.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/vms-misc.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/wasm-module.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/xcofflink.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/xsym.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/xtensa-dynconfig.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/xtensa-isa.Plo@am__quote@
+@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/xtensa-modules.Plo@am__quote@
+
+.c.o:
+@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
+@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ $<
+
+.c.obj:
+@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
+@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
+
+.c.lo:
+@am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
+@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(LTCOMPILE) -c -o $@ $<
+
+mostlyclean-libtool:
+ -rm -f *.lo
+
+clean-libtool:
+ -rm -rf .libs _libs
+
+distclean-libtool:
+ -rm -f libtool config.lt
+doc/$(am__dirstamp):
+ @$(MKDIR_P) doc
+ @: > doc/$(am__dirstamp)
+
+doc/bfd.info: doc/bfd.texi $(doc_bfd_TEXINFOS)
+ @test -f doc/$(am__dirstamp) || $(MAKE) $(AM_MAKEFLAGS) doc/$(am__dirstamp)
+ $(AM_V_MAKEINFO)restore=: && backupdir="$(am__leading_dot)am$$$$" && \
+ rm -rf $$backupdir && mkdir $$backupdir && \
+ if ($(MAKEINFO) --version) >/dev/null 2>&1; then \
+ for f in $@ $@-[0-9] $@-[0-9][0-9] $(@:.info=).i[0-9] $(@:.info=).i[0-9][0-9]; do \
+ if test -f $$f; then mv $$f $$backupdir; restore=mv; else :; fi; \
+ done; \
+ else :; fi && \
+ if $(MAKEINFO) $(AM_MAKEINFOFLAGS) $(MAKEINFOFLAGS) -I doc -I $(srcdir)/doc \
+ -o $@ `test -f 'doc/bfd.texi' || echo '$(srcdir)/'`doc/bfd.texi; \
+ then \
+ rc=0; \
+ else \
+ rc=$$?; \
+ $$restore $$backupdir/* `echo "./$@" | sed 's|[^/]*$$||'`; \
+ fi; \
+ rm -rf $$backupdir; exit $$rc
+
+doc/bfd.dvi: doc/bfd.texi $(doc_bfd_TEXINFOS) doc/$(am__dirstamp)
+ $(AM_V_TEXI2DVI)TEXINPUTS="$(am__TEXINFO_TEX_DIR)$(PATH_SEPARATOR)$$TEXINPUTS" \
+ MAKEINFO='$(MAKEINFO) $(AM_MAKEINFOFLAGS) $(MAKEINFOFLAGS) -I doc -I $(srcdir)/doc' \
+ $(TEXI2DVI) $(AM_V_texinfo) --build-dir=$(@:.dvi=.t2d) -o $@ $(AM_V_texidevnull) \
+ `test -f 'doc/bfd.texi' || echo '$(srcdir)/'`doc/bfd.texi
+
+doc/bfd.pdf: doc/bfd.texi $(doc_bfd_TEXINFOS) doc/$(am__dirstamp)
+ $(AM_V_TEXI2PDF)TEXINPUTS="$(am__TEXINFO_TEX_DIR)$(PATH_SEPARATOR)$$TEXINPUTS" \
+ MAKEINFO='$(MAKEINFO) $(AM_MAKEINFOFLAGS) $(MAKEINFOFLAGS) -I doc -I $(srcdir)/doc' \
+ $(TEXI2PDF) $(AM_V_texinfo) --build-dir=$(@:.pdf=.t2p) -o $@ $(AM_V_texidevnull) \
+ `test -f 'doc/bfd.texi' || echo '$(srcdir)/'`doc/bfd.texi
+
+doc/bfd.html: doc/bfd.texi $(doc_bfd_TEXINFOS) doc/$(am__dirstamp)
+ $(AM_V_MAKEINFO)rm -rf $(@:.html=.htp)
+ $(AM_V_at)if $(MAKEINFOHTML) $(AM_MAKEINFOHTMLFLAGS) $(MAKEINFOFLAGS) -I doc -I $(srcdir)/doc \
+ -o $(@:.html=.htp) `test -f 'doc/bfd.texi' || echo '$(srcdir)/'`doc/bfd.texi; \
+ then \
+ rm -rf $@ && mv $(@:.html=.htp) $@; \
+ else \
+ rm -rf $(@:.html=.htp); exit 1; \
+ fi
+.dvi.ps:
+ $(AM_V_DVIPS)TEXINPUTS="$(am__TEXINFO_TEX_DIR)$(PATH_SEPARATOR)$$TEXINPUTS" \
+ $(DVIPS) $(AM_V_texinfo) -o $@ $<
+
+uninstall-dvi-am:
+ @$(NORMAL_UNINSTALL)
+ @list='$(DVIS)'; test -n "$(dvidir)" || list=; \
+ for p in $$list; do \
+ $(am__strip_dir) \
+ echo " rm -f '$(DESTDIR)$(dvidir)/$$f'"; \
+ rm -f "$(DESTDIR)$(dvidir)/$$f"; \
+ done
+
+uninstall-html-am:
+ @$(NORMAL_UNINSTALL)
+ @list='$(HTMLS)'; test -n "$(htmldir)" || list=; \
+ for p in $$list; do \
+ $(am__strip_dir) \
+ echo " rm -rf '$(DESTDIR)$(htmldir)/$$f'"; \
+ rm -rf "$(DESTDIR)$(htmldir)/$$f"; \
+ done
+
+uninstall-info-am:
+ @$(PRE_UNINSTALL)
+ @if test -d '$(DESTDIR)$(infodir)' && $(am__can_run_installinfo); then \
+ list='$(INFO_DEPS)'; \
+ for file in $$list; do \
+ relfile=`echo "$$file" | sed 's|^.*/||'`; \
+ echo " install-info --info-dir='$(DESTDIR)$(infodir)' --remove '$(DESTDIR)$(infodir)/$$relfile'"; \
+ if install-info --info-dir="$(DESTDIR)$(infodir)" --remove "$(DESTDIR)$(infodir)/$$relfile"; \
+ then :; else test ! -f "$(DESTDIR)$(infodir)/$$relfile" || exit 1; fi; \
+ done; \
+ else :; fi
+ @$(NORMAL_UNINSTALL)
+ @list='$(INFO_DEPS)'; \
+ for file in $$list; do \
+ relfile=`echo "$$file" | sed 's|^.*/||'`; \
+ relfile_i=`echo "$$relfile" | sed 's|\.info$$||;s|$$|.i|'`; \
+ (if test -d "$(DESTDIR)$(infodir)" && cd "$(DESTDIR)$(infodir)"; then \
+ echo " cd '$(DESTDIR)$(infodir)' && rm -f $$relfile $$relfile-[0-9] $$relfile-[0-9][0-9] $$relfile_i[0-9] $$relfile_i[0-9][0-9]"; \
+ rm -f $$relfile $$relfile-[0-9] $$relfile-[0-9][0-9] $$relfile_i[0-9] $$relfile_i[0-9][0-9]; \
+ else :; fi); \
+ done
+
+uninstall-pdf-am:
+ @$(NORMAL_UNINSTALL)
+ @list='$(PDFS)'; test -n "$(pdfdir)" || list=; \
+ for p in $$list; do \
+ $(am__strip_dir) \
+ echo " rm -f '$(DESTDIR)$(pdfdir)/$$f'"; \
+ rm -f "$(DESTDIR)$(pdfdir)/$$f"; \
+ done
+
+uninstall-ps-am:
+ @$(NORMAL_UNINSTALL)
+ @list='$(PSS)'; test -n "$(psdir)" || list=; \
+ for p in $$list; do \
+ $(am__strip_dir) \
+ echo " rm -f '$(DESTDIR)$(psdir)/$$f'"; \
+ rm -f "$(DESTDIR)$(psdir)/$$f"; \
+ done
+
+dist-info: $(INFO_DEPS)
+ @srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; \
+ list='$(INFO_DEPS)'; \
+ for base in $$list; do \
+ case $$base in \
+ $(srcdir)/*) base=`echo "$$base" | sed "s|^$$srcdirstrip/||"`;; \
+ esac; \
+ if test -f $$base; then d=.; else d=$(srcdir); fi; \
+ base_i=`echo "$$base" | sed 's|\.info$$||;s|$$|.i|'`; \
+ for file in $$d/$$base $$d/$$base-[0-9] $$d/$$base-[0-9][0-9] $$d/$$base_i[0-9] $$d/$$base_i[0-9][0-9]; do \
+ if test -f $$file; then \
+ relfile=`expr "$$file" : "$$d/\(.*\)"`; \
+ test -f "$(distdir)/$$relfile" || \
+ cp -p $$file "$(distdir)/$$relfile"; \
+ else :; fi; \
+ done; \
+ done
+
+mostlyclean-aminfo:
+ -rm -rf doc/bfd.t2d doc/bfd.t2p
+
+clean-aminfo:
+ -test -z "doc/bfd.dvi doc/bfd.pdf doc/bfd.ps doc/bfd.html" \
+ || rm -rf doc/bfd.dvi doc/bfd.pdf doc/bfd.ps doc/bfd.html
+
+maintainer-clean-aminfo:
+ @list='$(INFO_DEPS)'; for i in $$list; do \
+ i_i=`echo "$$i" | sed 's|\.info$$||;s|$$|.i|'`; \
+ echo " rm -f $$i $$i-[0-9] $$i-[0-9][0-9] $$i_i[0-9] $$i_i[0-9][0-9]"; \
+ rm -f $$i $$i-[0-9] $$i-[0-9][0-9] $$i_i[0-9] $$i_i[0-9][0-9]; \
+ done
+install-bfdincludeHEADERS: $(bfdinclude_HEADERS)
+ @$(NORMAL_INSTALL)
+ @list='$(bfdinclude_HEADERS)'; test -n "$(bfdincludedir)" || list=; \
+ if test -n "$$list"; then \
+ echo " $(MKDIR_P) '$(DESTDIR)$(bfdincludedir)'"; \
+ $(MKDIR_P) "$(DESTDIR)$(bfdincludedir)" || exit 1; \
+ fi; \
+ for p in $$list; do \
+ if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
+ echo "$$d$$p"; \
+ done | $(am__base_list) | \
+ while read files; do \
+ echo " $(INSTALL_HEADER) $$files '$(DESTDIR)$(bfdincludedir)'"; \
+ $(INSTALL_HEADER) $$files "$(DESTDIR)$(bfdincludedir)" || exit $$?; \
+ done
+
+uninstall-bfdincludeHEADERS:
+ @$(NORMAL_UNINSTALL)
+ @list='$(bfdinclude_HEADERS)'; test -n "$(bfdincludedir)" || list=; \
+ files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \
+ dir='$(DESTDIR)$(bfdincludedir)'; $(am__uninstall_files_from_dir)
+
+# This directory's subdirectories are mostly independent; you can cd
+# into them and run 'make' without going through this Makefile.
+# To change the values of 'make' variables: instead of editing Makefiles,
+# (1) if the variable is set in 'config.status', edit 'config.status'
+# (which will cause the Makefiles to be regenerated when you run 'make');
+# (2) otherwise, pass the desired values on the 'make' command line.
+$(am__recursive_targets):
+ @fail=; \
+ if $(am__make_keepgoing); then \
+ failcom='fail=yes'; \
+ else \
+ failcom='exit 1'; \
+ fi; \
+ dot_seen=no; \
+ target=`echo $@ | sed s/-recursive//`; \
+ case "$@" in \
+ distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \
+ *) list='$(SUBDIRS)' ;; \
+ esac; \
+ for subdir in $$list; do \
+ echo "Making $$target in $$subdir"; \
+ if test "$$subdir" = "."; then \
+ dot_seen=yes; \
+ local_target="$$target-am"; \
+ else \
+ local_target="$$target"; \
+ fi; \
+ ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
+ || eval $$failcom; \
+ done; \
+ if test "$$dot_seen" = "no"; then \
+ $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \
+ fi; test -z "$$fail"
+
+ID: $(am__tagged_files)
+ $(am__define_uniq_tagged_files); mkid -fID $$unique
+tags: tags-recursive
+TAGS: tags
+
+tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
+ set x; \
+ here=`pwd`; \
+ if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \
+ include_option=--etags-include; \
+ empty_fix=.; \
+ else \
+ include_option=--include; \
+ empty_fix=; \
+ fi; \
+ list='$(SUBDIRS)'; for subdir in $$list; do \
+ if test "$$subdir" = .; then :; else \
+ test ! -f $$subdir/TAGS || \
+ set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \
+ fi; \
+ done; \
+ $(am__define_uniq_tagged_files); \
+ shift; \
+ if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
+ test -n "$$unique" || unique=$$empty_fix; \
+ if test $$# -gt 0; then \
+ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
+ "$$@" $$unique; \
+ else \
+ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
+ $$unique; \
+ fi; \
+ fi
+ctags: ctags-recursive
+
+CTAGS: ctags
+ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
+ $(am__define_uniq_tagged_files); \
+ test -z "$(CTAGS_ARGS)$$unique" \
+ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
+ $$unique
+
+GTAGS:
+ here=`$(am__cd) $(top_builddir) && pwd` \
+ && $(am__cd) $(top_srcdir) \
+ && gtags -i $(GTAGS_ARGS) "$$here"
+cscope: cscope.files
+ test ! -s cscope.files \
+ || $(CSCOPE) -b -q $(AM_CSCOPEFLAGS) $(CSCOPEFLAGS) -i cscope.files $(CSCOPE_ARGS)
+clean-cscope:
+ -rm -f cscope.files
+cscope.files: clean-cscope cscopelist
+cscopelist: cscopelist-recursive
+
+cscopelist-am: $(am__tagged_files)
+ list='$(am__tagged_files)'; \
+ case "$(srcdir)" in \
+ [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
+ *) sdir=$(subdir)/$(srcdir) ;; \
+ esac; \
+ for i in $$list; do \
+ if test -f "$$i"; then \
+ echo "$(subdir)/$$i"; \
+ else \
+ echo "$$sdir/$$i"; \
+ fi; \
+ done >> $(top_builddir)/cscope.files
+
+distclean-tags:
+ -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
+ -rm -f cscope.out cscope.in.out cscope.po.out cscope.files
+check-am: all-am
+check: $(BUILT_SOURCES)
+ $(MAKE) $(AM_MAKEFLAGS) check-recursive
+all-am: Makefile $(INFO_DEPS) $(LTLIBRARIES) $(HEADERS) config.h
+installdirs: installdirs-recursive
+installdirs-am:
+ for dir in "$(DESTDIR)$(bfdlibdir)" "$(DESTDIR)$(infodir)" "$(DESTDIR)$(bfdincludedir)"; do \
+ test -z "$$dir" || $(MKDIR_P) "$$dir"; \
+ done
+install: $(BUILT_SOURCES)
+ $(MAKE) $(AM_MAKEFLAGS) install-recursive
+install-exec: install-exec-recursive
+install-data: install-data-recursive
+uninstall: uninstall-recursive
+
+install-am: all-am
+ @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
+
+installcheck: installcheck-recursive
+install-strip:
+ if test -z '$(STRIP)'; then \
+ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
+ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
+ install; \
+ else \
+ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
+ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
+ "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
+ fi
+mostlyclean-generic:
+ -test -z "$(MOSTLYCLEANFILES)" || rm -f $(MOSTLYCLEANFILES)
+
+clean-generic:
+ -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES)
+
+distclean-generic:
+ -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
+ -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
+ -rm -f doc/$(am__dirstamp)
+ -test -z "$(DISTCLEANFILES)" || rm -f $(DISTCLEANFILES)
+
+maintainer-clean-generic:
+ @echo "This command is intended for maintainers to use"
+ @echo "it deletes files that may require special tools to rebuild."
+ -test -z "$(BUILT_SOURCES)" || rm -f $(BUILT_SOURCES)
+ -test -z "$(MAINTAINERCLEANFILES)" || rm -f $(MAINTAINERCLEANFILES)
+clean: clean-recursive
+
+clean-am: clean-aminfo clean-bfdlibLTLIBRARIES clean-generic \
+ clean-libtool clean-noinstLTLIBRARIES mostlyclean-am
+
+distclean: distclean-recursive
+ -rm -f $(am__CONFIG_DISTCLEAN_FILES)
+ -rm -rf ./$(DEPDIR)
+ -rm -f Makefile
+distclean-am: clean-am distclean-compile distclean-generic \
+ distclean-hdr distclean-libtool distclean-tags
+
+dvi: dvi-recursive
+
+dvi-am: $(DVIS)
+
+html: html-recursive
+
+html-am: $(HTMLS) html-local
+
+info: info-recursive
+
+info-am: $(INFO_DEPS)
+
+install-data-am: install-bfdincludeHEADERS install-bfdlibLTLIBRARIES \
+ install-info-am
+
+install-dvi: install-dvi-recursive
+
+install-dvi-am: $(DVIS)
+ @$(NORMAL_INSTALL)
+ @list='$(DVIS)'; test -n "$(dvidir)" || list=; \
+ if test -n "$$list"; then \
+ echo " $(MKDIR_P) '$(DESTDIR)$(dvidir)'"; \
+ $(MKDIR_P) "$(DESTDIR)$(dvidir)" || exit 1; \
+ fi; \
+ for p in $$list; do \
+ if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
+ echo "$$d$$p"; \
+ done | $(am__base_list) | \
+ while read files; do \
+ echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(dvidir)'"; \
+ $(INSTALL_DATA) $$files "$(DESTDIR)$(dvidir)" || exit $$?; \
+ done
+install-exec-am:
+
+install-html: install-html-recursive
+
+install-html-am: $(HTMLS)
+ @$(NORMAL_INSTALL)
+ @list='$(HTMLS)'; list2=; test -n "$(htmldir)" || list=; \
+ if test -n "$$list"; then \
+ echo " $(MKDIR_P) '$(DESTDIR)$(htmldir)'"; \
+ $(MKDIR_P) "$(DESTDIR)$(htmldir)" || exit 1; \
+ fi; \
+ for p in $$list; do \
+ if test -f "$$p" || test -d "$$p"; then d=; else d="$(srcdir)/"; fi; \
+ $(am__strip_dir) \
+ d2=$$d$$p; \
+ if test -d "$$d2"; then \
+ echo " $(MKDIR_P) '$(DESTDIR)$(htmldir)/$$f'"; \
+ $(MKDIR_P) "$(DESTDIR)$(htmldir)/$$f" || exit 1; \
+ echo " $(INSTALL_DATA) '$$d2'/* '$(DESTDIR)$(htmldir)/$$f'"; \
+ $(INSTALL_DATA) "$$d2"/* "$(DESTDIR)$(htmldir)/$$f" || exit $$?; \
+ else \
+ list2="$$list2 $$d2"; \
+ fi; \
+ done; \
+ test -z "$$list2" || { echo "$$list2" | $(am__base_list) | \
+ while read files; do \
+ echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(htmldir)'"; \
+ $(INSTALL_DATA) $$files "$(DESTDIR)$(htmldir)" || exit $$?; \
+ done; }
+install-info: install-info-recursive
+
+install-info-am: $(INFO_DEPS)
+ @$(NORMAL_INSTALL)
+ @srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; \
+ list='$(INFO_DEPS)'; test -n "$(infodir)" || list=; \
+ if test -n "$$list"; then \
+ echo " $(MKDIR_P) '$(DESTDIR)$(infodir)'"; \
+ $(MKDIR_P) "$(DESTDIR)$(infodir)" || exit 1; \
+ fi; \
+ for file in $$list; do \
+ case $$file in \
+ $(srcdir)/*) file=`echo "$$file" | sed "s|^$$srcdirstrip/||"`;; \
+ esac; \
+ if test -f $$file; then d=.; else d=$(srcdir); fi; \
+ file_i=`echo "$$file" | sed 's|\.info$$||;s|$$|.i|'`; \
+ for ifile in $$d/$$file $$d/$$file-[0-9] $$d/$$file-[0-9][0-9] \
+ $$d/$$file_i[0-9] $$d/$$file_i[0-9][0-9] ; do \
+ if test -f $$ifile; then \
+ echo "$$ifile"; \
+ else : ; fi; \
+ done; \
+ done | $(am__base_list) | \
+ while read files; do \
+ echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(infodir)'"; \
+ $(INSTALL_DATA) $$files "$(DESTDIR)$(infodir)" || exit $$?; done
+ @$(POST_INSTALL)
+ @if $(am__can_run_installinfo); then \
+ list='$(INFO_DEPS)'; test -n "$(infodir)" || list=; \
+ for file in $$list; do \
+ relfile=`echo "$$file" | sed 's|^.*/||'`; \
+ echo " install-info --info-dir='$(DESTDIR)$(infodir)' '$(DESTDIR)$(infodir)/$$relfile'";\
+ install-info --info-dir="$(DESTDIR)$(infodir)" "$(DESTDIR)$(infodir)/$$relfile" || :;\
+ done; \
+ else : ; fi
+install-man:
+
+install-pdf: install-pdf-recursive
+
+install-pdf-am: $(PDFS)
+ @$(NORMAL_INSTALL)
+ @list='$(PDFS)'; test -n "$(pdfdir)" || list=; \
+ if test -n "$$list"; then \
+ echo " $(MKDIR_P) '$(DESTDIR)$(pdfdir)'"; \
+ $(MKDIR_P) "$(DESTDIR)$(pdfdir)" || exit 1; \
+ fi; \
+ for p in $$list; do \
+ if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
+ echo "$$d$$p"; \
+ done | $(am__base_list) | \
+ while read files; do \
+ echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(pdfdir)'"; \
+ $(INSTALL_DATA) $$files "$(DESTDIR)$(pdfdir)" || exit $$?; done
+install-ps: install-ps-recursive
+
+install-ps-am: $(PSS)
+ @$(NORMAL_INSTALL)
+ @list='$(PSS)'; test -n "$(psdir)" || list=; \
+ if test -n "$$list"; then \
+ echo " $(MKDIR_P) '$(DESTDIR)$(psdir)'"; \
+ $(MKDIR_P) "$(DESTDIR)$(psdir)" || exit 1; \
+ fi; \
+ for p in $$list; do \
+ if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
+ echo "$$d$$p"; \
+ done | $(am__base_list) | \
+ while read files; do \
+ echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(psdir)'"; \
+ $(INSTALL_DATA) $$files "$(DESTDIR)$(psdir)" || exit $$?; done
+installcheck-am:
+
+maintainer-clean: maintainer-clean-recursive
+ -rm -f $(am__CONFIG_DISTCLEAN_FILES)
+ -rm -rf $(top_srcdir)/autom4te.cache
+ -rm -rf ./$(DEPDIR)
+ -rm -f Makefile
+maintainer-clean-am: distclean-am maintainer-clean-aminfo \
+ maintainer-clean-generic
+
+mostlyclean: mostlyclean-recursive
+
+mostlyclean-am: mostlyclean-aminfo mostlyclean-compile \
+ mostlyclean-generic mostlyclean-libtool
+
+pdf: pdf-recursive
+
+pdf-am: $(PDFS)
+
+ps: ps-recursive
+
+ps-am: $(PSS)
+
+uninstall-am: uninstall-bfdincludeHEADERS uninstall-bfdlibLTLIBRARIES \
+ uninstall-dvi-am uninstall-html-am uninstall-info-am \
+ uninstall-pdf-am uninstall-ps-am
+
+.MAKE: $(am__recursive_targets) all check install install-am \
+ install-strip
+
+.PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am \
+ am--refresh check check-am clean clean-aminfo \
+ clean-bfdlibLTLIBRARIES clean-cscope clean-generic \
+ clean-libtool clean-noinstLTLIBRARIES cscope cscopelist-am \
+ ctags ctags-am dist-info distclean distclean-compile \
+ distclean-generic distclean-hdr distclean-libtool \
+ distclean-tags dvi dvi-am html html-am html-local info info-am \
+ install install-am install-bfdincludeHEADERS \
+ install-bfdlibLTLIBRARIES install-data install-data-am \
+ install-dvi install-dvi-am install-exec install-exec-am \
+ install-html install-html-am install-info install-info-am \
+ install-man install-pdf install-pdf-am install-ps \
+ install-ps-am install-strip installcheck installcheck-am \
+ installdirs installdirs-am maintainer-clean \
+ maintainer-clean-aminfo maintainer-clean-generic mostlyclean \
+ mostlyclean-aminfo mostlyclean-compile mostlyclean-generic \
+ mostlyclean-libtool pdf pdf-am ps ps-am tags tags-am uninstall \
+ uninstall-am uninstall-bfdincludeHEADERS \
+ uninstall-bfdlibLTLIBRARIES uninstall-dvi-am uninstall-html-am \
+ uninstall-info-am uninstall-pdf-am uninstall-ps-am
+
+.PRECIOUS: Makefile
+
+$(BFD32_LIBS) \
+ $(BFD64_LIBS) \
+ $(ALL_MACHINES) \
+ $(BFD32_BACKENDS) \
+ $(BFD64_BACKENDS) \
+ $(OPTIONAL_BACKENDS): $(BFD_H) $(BFD_H_DEPS) $(LOCAL_H_DEPS)
+
+po/SRC-POTFILES.in: @MAINT@ Makefile
+ for file in $(SRC_POTFILES); do echo $$file; done \
+ | LC_ALL=C sort | uniq > tmp.src \
+ && mv tmp.src $(srcdir)/po/SRC-POTFILES.in
+
+po/BLD-POTFILES.in: @MAINT@ Makefile
+ for file in $(BLD_POTFILES); do echo $$file; done \
+ | LC_ALL=C sort | uniq > tmp.bld \
+ && mv tmp.bld $(srcdir)/po/BLD-POTFILES.in
+
+all diststuff: info
+
+stamp-ofiles: Makefile
+ rm -f tofiles
+ f=""; \
+ for i in $(OFILES) ; do \
+ case " $$f " in \
+ *" $$i "*) ;; \
+ *) f="$$f $$i" ;; \
+ esac ; \
+ done ; \
+ echo $$f > tofiles
+ $(SHELL) $(srcdir)/../move-if-change tofiles ofiles
+ touch stamp-ofiles
+
+ofiles: stamp-ofiles ; @true
+
+# This file holds an array associating configuration triplets and
+# vector names. It is built from config.bfd. It is not compiled by
+# itself, but is included by targets.c.
+targmatch.h: config.bfd targmatch.sed
+ $(AM_V_at)rm -f targmatch.new
+ $(AM_V_GEN)$(SED) -f $(srcdir)/targmatch.sed < $(srcdir)/config.bfd > targmatch.new
+ $(AM_V_at)mv -f targmatch.new targmatch.h
+
+# When compiling archures.c and targets.c, supply the default target
+# info from configure.
+
+targets.lo: targets.c Makefile
+@am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $(TDEFAULTS) $(srcdir)/targets.c
+@am__fastdepCC_TRUE@ $(AM_V_at)mv -f $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='targets.c' object='$@' libtool=yes @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepCC_FALSE@ $(AM_V_CC)$(LTCOMPILE) -c -o $@ $(TDEFAULTS) $(srcdir)/targets.c
+
+archures.lo: archures.c Makefile
+@am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $(TDEFAULTS) $(srcdir)/archures.c
+@am__fastdepCC_TRUE@ $(AM_V_at)mv -f $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='archures.c' object='$@' libtool=yes @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepCC_FALSE@ $(AM_V_CC)$(LTCOMPILE) -c -o $@ $(TDEFAULTS) $(srcdir)/archures.c
+
+dwarf2.lo: dwarf2.c Makefile
+@am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ -DDEBUGDIR=\"$(DEBUGDIR)\" $(srcdir)/dwarf2.c
+@am__fastdepCC_TRUE@ $(AM_V_at)mv -f $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='dwarf2.c' object='$@' libtool=yes @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepCC_FALSE@ $(AM_V_CC)$(LTCOMPILE) -c -o $@ -DDEBUGDIR=\"$(DEBUGDIR)\" $(srcdir)/dwarf2.c
+
+elf32-target.h : elfxx-target.h
+ $(AM_V_GEN)$(SED) -e s/NN/32/g < $< > $@
+
+elf64-target.h : elfxx-target.h
+ $(AM_V_GEN)$(SED) -e s/NN/64/g < $< > $@
+
+elf32-aarch64.c : elfnn-aarch64.c
+ $(AM_V_at)echo "#line 1 \"$<\"" > $@
+ $(AM_V_GEN)$(SED) -e s/NN/32/g < $< >> $@
+
+elf64-aarch64.c : elfnn-aarch64.c
+ $(AM_V_at)echo "#line 1 \"$<\"" > $@
+ $(AM_V_GEN)$(SED) -e s/NN/64/g < $< >> $@
+
+elf32-ia64.c : elfnn-ia64.c
+ $(AM_V_at)echo "#line 1 \"$<\"" > $@
+ $(AM_V_GEN)$(SED) -e s/NN/32/g < $< >> $@
+
+elf64-ia64.c : elfnn-ia64.c
+ $(AM_V_at)echo "#line 1 \"$<\"" > $@
+ $(AM_V_GEN)$(SED) -e s/NN/64/g < $< >> $@
+
+elf32-kvx.c : elfnn-kvx.c
+ $(AM_V_at)echo "#line 1 \"$<\"" > $@
+ $(AM_V_GEN)$(SED) -e s/NN/32/g < $< >> $@
+
+elf64-kvx.c : elfnn-kvx.c
+ $(AM_V_at)echo "#line 1 \"$<\"" > $@
+ $(AM_V_GEN)$(SED) -e s/NN/64/g < $< >> $@
+
+elf32-loongarch.c : elfnn-loongarch.c
+ $(AM_V_at)echo "#line 1 \"$<\"" > $@
+ $(AM_V_GEN)$(SED) -e s/NN/32/g < $< >> $@
+
+elf64-loongarch.c : elfnn-loongarch.c
+ $(AM_V_at)echo "#line 1 \"$<\"" > $@
+ $(AM_V_GEN)$(SED) -e s/NN/64/g < $< >> $@
+
+elf32-riscv.c : elfnn-riscv.c
+ $(AM_V_at)echo "#line 1 \"$<\"" > $@
+ $(AM_V_GEN)$(SED) -e s/NN/32/g < $< >> $@
+
+elf64-riscv.c : elfnn-riscv.c
+ $(AM_V_at)echo "#line 1 \"$<\"" > $@
+ $(AM_V_GEN)$(SED) -e s/NN/64/g < $< >> $@
+
+peigen.c : peXXigen.c
+ $(AM_V_at)echo "#line 1 \"$<\"" > $@
+ $(AM_V_GEN)$(SED) -e s/XX/pe/g < $< >> $@
+
+pepigen.c : peXXigen.c
+ $(AM_V_at)echo "#line 1 \"$<\"" > $@
+ $(AM_V_GEN)$(SED) -e s/XX/pep/g < $< >> $@
+
+pex64igen.c: peXXigen.c
+ $(AM_V_at)echo "#line 1 \"$<\"" > $@
+ $(AM_V_GEN)$(SED) -e s/XX/pex64/g < $< >> $@
+
+pe-aarch64igen.c: peXXigen.c
+ $(AM_V_at)echo "#line 1 \"$<\"" > $@
+ $(AM_V_GEN)$(SED) -e s/XX/peAArch64/g < $< >> $@
+
+pe-loongarch64igen.c: peXXigen.c
+ $(AM_V_at)echo "#line 1 \"$<\"" > $@
+ $(AM_V_GEN)$(SED) -e s/XX/peLoongArch64/g < $< >> $@
+
+pe-riscv64igen.c: peXXigen.c
+ $(AM_V_at)echo "#line 1 \"peXXigen.c\"" > $@
+ $(AM_V_GEN)$(SED) -e s/XX/peRiscV64/g < $< >> $@
+
+host-aout.lo: Makefile
+
+# The following program can be used to generate a simple config file
+# which can be folded into an h-XXX file for a new host, with some editing.
+aout-params.h: gen-aout
+ ./gen-aout host > aout-params.h
+gen-aout: $(srcdir)/gen-aout.c Makefile
+ $(CC) -o gen-aout $(CFLAGS) $(LFLAGS) $(srcdir)/gen-aout.c
+
+$(BFD_H): stmp-bfd-h ; @true
+
+stmp-bfd-h: bfd-in3.h
+ rm -f bfd-tmp.h
+ cp bfd-in3.h bfd-tmp.h
+ $(SHELL) $(srcdir)/../move-if-change bfd-tmp.h $(BFD_H)
+ rm -f bfd-tmp.h
+ touch stmp-bfd-h
+
+headers: stmp-bin2-h stmp-lbfd-h stmp-lcoff-h
+
+$(srcdir)/bfd-in2.h: @MAINT@ stmp-bin2-h ; @true
+stmp-bin2-h: $(BFD_H_FILES) $(BFD64_H_FILES) $(MKDOC)
+ $(AM_V_GEN)H_FILES="$(BFD_H_FILES)" CHEW_FLAGS= ; $(REGEN_HEADER) > bfd-in2.h-new
+ $(AM_V_at)$(SHELL) $(srcdir)/../move-if-change bfd-in2.h-new $(srcdir)/bfd-in2.h
+ $(AM_V_at)touch stmp-bin2-h
+
+$(srcdir)/libbfd.h: @MAINT@ stmp-lbfd-h ; @true
+stmp-lbfd-h: $(LIBBFD_H_FILES) $(MKDOC)
+ $(AM_V_GEN)H_FILES="$(LIBBFD_H_FILES)" CHEW_FLAGS=-i ; $(REGEN_HEADER) > libbfd.h-new
+ $(AM_V_at)$(SHELL) $(srcdir)/../move-if-change libbfd.h-new $(srcdir)/libbfd.h
+ $(AM_V_at)touch stmp-lbfd-h
+
+$(srcdir)/libcoff.h: @MAINT@ stmp-lcoff-h ; @true
+stmp-lcoff-h: $(LIBCOFF_H_FILES) $(MKDOC)
+ $(AM_V_GEN)H_FILES="$(LIBCOFF_H_FILES)" CHEW_FLAGS=-i ; $(REGEN_HEADER) > libcoff.h-new
+ $(AM_V_at)$(SHELL) $(srcdir)/../move-if-change libcoff.h-new $(srcdir)/libcoff.h
+ $(AM_V_at)touch stmp-lcoff-h
+
+bfdver.h: $(srcdir)/version.h $(srcdir)/development.sh $(srcdir)/Makefile.in
+ $(AM_V_GEN)\
+ bfd_version=`echo "$(VERSION)" | $(SED) -e 's/\([^\.]*\)\.*\([^\.]*\)\.*\([^\.]*\)\.*\([^\.]*\)\.*\([^\.]*\).*/\1.00\2.00\3.00\4.00\5/' -e 's/\([^\.]*\)\..*\(..\)\..*\(..\)\..*\(..\)\..*\(..\)$$/\1\2\3\4\5/'` ;\
+ bfd_version_string="\"$(VERSION)\"" ;\
+ bfd_soversion="$(VERSION)" ;\
+ bfd_version_package="\"$(PKGVERSION)\"" ;\
+ report_bugs_to="\"$(REPORT_BUGS_TO)\"" ;\
+ . $(srcdir)/development.sh ;\
+ if test "$$development" = true ; then \
+ bfd_version_date=`$(SED) -n -e 's/.*DATE //p' < $(srcdir)/version.h` ;\
+ bfd_version_string="\"$(VERSION).$${bfd_version_date}\"" ;\
+ bfd_soversion="$(VERSION).$${bfd_version_date}" ;\
+ fi ;\
+ $(SED) -e "s,@bfd_version@,$$bfd_version," \
+ -e "s,@bfd_version_string@,$$bfd_version_string," \
+ -e "s,@bfd_version_package@,$$bfd_version_package," \
+ -e "s,@report_bugs_to@,$$report_bugs_to," \
+ < $(srcdir)/version.h > $@; \
+ echo "$${bfd_soversion}" > libtool-soversion
+
+# Disable -Werror, if it has been enabled, since coffswap.h won't
+# compile with gcc 4.5 and above.
+coff-tic4x.lo: coff-tic4x.c
+@am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< $(NO_WERROR)
+@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepCC_FALSE@ $(AM_V_CC)$(LTCOMPILE) -c -o $@ $< $(NO_WERROR)
+
+coff-tic54x.lo: coff-tic54x.c
+@am__fastdepCC_TRUE@ $(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< $(NO_WERROR)
+@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
+@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
+@am__fastdepCC_FALSE@ $(AM_V_CC)$(LTCOMPILE) -c -o $@ $< $(NO_WERROR)
+
+$(MKDOC): doc/chew.stamp ; @true
+doc/chew.stamp: $(srcdir)/doc/chew.c doc/$(am__dirstamp)
+ $(AM_V_CCLD)$(CC_FOR_BUILD) -o doc/chw$$$$$(EXEEXT_FOR_BUILD) $(CFLAGS_FOR_BUILD) \
+ $(WARN_CFLAGS_FOR_BUILD) $(CPPFLAGS_FOR_BUILD) $(LDFLAGS_FOR_BUILD) \
+ -I. -I$(srcdir) -Idoc -I$(srcdir)/../include -I$(srcdir)/../intl -I../intl \
+ $(srcdir)/doc/chew.c && \
+ $(SHELL) $(srcdir)/../move-if-change \
+ doc/chw$$$$$(EXEEXT_FOR_BUILD) $(MKDOC) && \
+ touch $@
+
+.PRECIOUS: doc/%.stamp
+doc/%.texi: doc/%.stamp ; @true
+doc/%.stamp: $(srcdir)/%.c $(srcdir)/doc/doc.str $(MKDOC) doc/$(am__dirstamp)
+ $(AM_V_GEN)$(REGEN_TEXI)
+doc/%.stamp: $(srcdir)/%.h $(srcdir)/doc/doc.str $(MKDOC) doc/$(am__dirstamp)
+ $(AM_V_GEN)$(REGEN_TEXI)
+
+# Avoid the %.stamp generating a builddir/bfd.texi that overrides the
+# srcdir/ as well as regenerating doc/bfd.info for each make run.
+doc/bfd.stamp: $(srcdir)/doc/bfd.texi ; $(AM_V_at)touch $@
+
+# We use bfdt.texi, rather than bfd.texi, to avoid conflicting with
+# bfd.texi on an 8.3 filesystem.
+doc/bfdt.stamp: $(srcdir)/bfd.c $(srcdir)/doc/doc.str $(MKDOC) doc/$(am__dirstamp)
+ $(AM_V_GEN)$(REGEN_TEXI)
+
+doc/bfdver.texi: $(srcdir)/Makefile.in
+ $(AM_V_GEN)\
+ $(MKDIR_P) $(@D); \
+ echo "@set VERSION $(VERSION)" > $@; \
+ if test -n "$(PKGVERSION)"; then \
+ echo "@set VERSION_PACKAGE $(PKGVERSION)" >> $@; \
+ fi; \
+ echo "@set UPDATED `date '+%B %Y'`" >> $@; \
+ if test -n "$(REPORT_BUGS_TEXI)"; then \
+ echo "@set BUGURL $(REPORT_BUGS_TEXI)" >> $@; \
+ fi
+
+html-local: doc/bfd/index.html
+doc/bfd/index.html: doc/bfd.texi $(bfd_TEXINFOS) doc/$(am__dirstamp)
+ $(AM_V_at)$(MAKEINFOHTML) $(AM_MAKEINFOHTMLFLAGS) $(MAKEINFOFLAGS) \
+ --split=node -o doc/bfd $(srcdir)/doc/bfd.texi
+
+# Tell versions [3.59,3.63) of GNU make to not export all variables.
+# Otherwise a system limit (for SysV at least) may be exceeded.
+.NOEXPORT:
Index: sources/GNU/binutils/create-2.44-export-demangle-patch/create.patch.sh
===================================================================
--- sources/GNU/binutils/create-2.44-export-demangle-patch/create.patch.sh (nonexistent)
+++ sources/GNU/binutils/create-2.44-export-demangle-patch/create.patch.sh (revision 76)
@@ -0,0 +1,15 @@
+#!/bin/bash
+
+VERSION=2.44
+
+tar --files-from=file.list -xJvf ../binutils-$VERSION.tar.xz
+mv binutils-$VERSION binutils-$VERSION-orig
+
+cp -rf ./binutils-$VERSION-new ./binutils-$VERSION
+
+diff --unified -Nr binutils-$VERSION-orig binutils-$VERSION > binutils-$VERSION-export-demangle.patch
+
+mv binutils-$VERSION-export-demangle.patch ../patches
+
+rm -rf ./binutils-$VERSION
+rm -rf ./binutils-$VERSION-orig
Property changes on: sources/GNU/binutils/create-2.44-export-demangle-patch/create.patch.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*
\ No newline at end of property
Index: sources/GNU/binutils/create-2.44-export-demangle-patch/file.list
===================================================================
--- sources/GNU/binutils/create-2.44-export-demangle-patch/file.list (nonexistent)
+++ sources/GNU/binutils/create-2.44-export-demangle-patch/file.list (revision 76)
@@ -0,0 +1,2 @@
+binutils-2.44/bfd/Makefile.am
+binutils-2.44/bfd/Makefile.in
Index: sources/GNU/binutils/create-2.44-ldforcele-patch/binutils-2.44-new/ld/ldlang.c
===================================================================
--- sources/GNU/binutils/create-2.44-ldforcele-patch/binutils-2.44-new/ld/ldlang.c (nonexistent)
+++ sources/GNU/binutils/create-2.44-ldforcele-patch/binutils-2.44-new/ld/ldlang.c (revision 76)
@@ -0,0 +1,11082 @@
+/* Linker command language support.
+ Copyright (C) 1991-2025 Free Software Foundation, Inc.
+
+ This file is part of the GNU Binutils.
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 3 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston,
+ MA 02110-1301, USA. */
+
+#include "sysdep.h"
+#include <limits.h>
+#include "bfd.h"
+#include "libiberty.h"
+#include "filenames.h"
+#include "safe-ctype.h"
+#include "obstack.h"
+#include "bfdlink.h"
+#include "ctf-api.h"
+#include "ld.h"
+#include "ldmain.h"
+#include "ldexp.h"
+#include "ldlang.h"
+#include <ldgram.h>
+#include "ldlex.h"
+#include "ldmisc.h"
+#include "ldctor.h"
+#include "ldfile.h"
+#include "ldemul.h"
+#include "ldwrite.h"
+#include "fnmatch.h"
+#include "demangle.h"
+#include "hashtab.h"
+#include "elf-bfd.h"
+#include "bfdver.h"
+
+#if BFD_SUPPORTS_PLUGINS
+#include "plugin.h"
+#endif
+
+/* FIXME: Put it here to avoid NAME conflict from ldgram.h. */
+#include "elf-bfd.h"
+
+#ifndef offsetof
+#define offsetof(TYPE, MEMBER) ((size_t) & (((TYPE*) 0)->MEMBER))
+#endif
+
+/* Convert between addresses in bytes and sizes in octets.
+ For currently supported targets, octets_per_byte is always a power
+ of two, so we can use shifts. */
+#define TO_ADDR(X) ((X) >> opb_shift)
+#define TO_SIZE(X) ((X) << opb_shift)
+
+/* Local variables. */
+static struct obstack stat_obstack;
+static struct obstack map_obstack;
+static struct obstack pt_obstack;
+
+#define obstack_chunk_alloc xmalloc
+#define obstack_chunk_free free
+static const char *entry_symbol_default = "start";
+static bool map_head_is_link_order = false;
+static lang_output_section_statement_type *default_common_section;
+static bool map_option_f;
+static bfd_vma print_dot;
+static lang_input_statement_type *first_file;
+static const char *current_target;
+static lang_statement_list_type *stat_save[10];
+static lang_statement_list_type **stat_save_ptr = &stat_save[0];
+static struct unique_sections *unique_section_list;
+static struct asneeded_minfo *asneeded_list_head;
+static unsigned int opb_shift = 0;
+static cmdline_list_type cmdline_object_only_file_list;
+static cmdline_list_type cmdline_object_only_archive_list;
+static cmdline_list_type cmdline_temp_object_only_list;
+
+/* Forward declarations. */
+static void exp_init_os (etree_type *);
+static lang_input_statement_type *lookup_name (const char *);
+static bool wont_add_section_p (asection *,
+ lang_output_section_statement_type *);
+static void insert_undefined (const char *);
+static bool sort_def_symbol (struct bfd_link_hash_entry *, void *);
+static lang_statement_union_type *new_statement (enum statement_enum type,
+ size_t size,
+ lang_statement_list_type *list);
+static void print_statement (lang_statement_union_type *,
+ lang_output_section_statement_type *);
+static void print_statement_list (lang_statement_union_type *,
+ lang_output_section_statement_type *);
+static void print_statements (void);
+static void print_input_section (asection *, bool);
+static bool lang_one_common (struct bfd_link_hash_entry *, void *);
+static void lang_record_phdrs (void);
+static void lang_do_version_exports_section (void);
+static void lang_finalize_version_expr_head
+ (struct bfd_elf_version_expr_head *);
+static void lang_do_memory_regions (bool);
+static void cmdline_lists_init (void);
+static void cmdline_get_object_only_input_files (void);
+static void print_cmdline_list (cmdline_union_type *);
+static bool cmdline_on_object_only_archive_list_p (bfd *);
+
+/* Exported variables. */
+const char *output_target;
+lang_output_section_statement_type *abs_output_section;
+/* Header for list of statements corresponding to any files involved in the
+ link, either specified from the command-line or added implicitely (eg.
+ archive member used to resolved undefined symbol, wildcard statement from
+ linker script, etc.). Next pointer is in next field of a
+ lang_statement_header_type (reached via header field in a
+ lang_statement_union). */
+lang_statement_list_type statement_list;
+lang_statement_list_type lang_os_list;
+lang_statement_list_type *stat_ptr = &statement_list;
+/* Header for list of statements corresponding to files used in the final
+ executable. This can be either object file specified on the command-line
+ or library member resolving an undefined reference. Next pointer is in next
+ field of a lang_input_statement_type (reached via input_statement field in a
+ lang_statement_union). */
+lang_statement_list_type file_chain = { NULL, NULL };
+/* Header for list of statements corresponding to files specified on the
+ command-line for linking. It thus contains real object files and archive
+ but not archive members. Next pointer is in next_real_file field of a
+ lang_input_statement_type statement (reached via input_statement field in a
+ lang_statement_union). */
+lang_statement_list_type input_file_chain;
+static const char *current_input_file;
+struct bfd_elf_dynamic_list **current_dynamic_list_p;
+struct bfd_sym_chain entry_symbol = { NULL, NULL };
+const char *entry_section = ".text";
+struct lang_input_statement_flags input_flags;
+bool entry_from_cmdline;
+bool lang_has_input_file = false;
+bool had_output_filename = false;
+bool lang_float_flag = false;
+bool delete_output_file_on_failure = false;
+bool enable_linker_version = false;
+struct lang_phdr *lang_phdr_list;
+struct lang_nocrossrefs *nocrossref_list;
+struct asneeded_minfo **asneeded_list_tail;
+#ifdef ENABLE_LIBCTF
+static ctf_dict_t *ctf_output;
+#endif
+
+/* Functions that traverse the linker script and might evaluate
+ DEFINED() need to increment this at the start of the traversal. */
+int lang_statement_iteration = 0;
+
+/* Count times through one_lang_size_sections_pass after mark phase. */
+static int lang_sizing_iteration = 0;
+
+/* Return TRUE if the PATTERN argument is a wildcard pattern.
+ Although backslashes are treated specially if a pattern contains
+ wildcards, we do not consider the mere presence of a backslash to
+ be enough to cause the pattern to be treated as a wildcard.
+ That lets us handle DOS filenames more naturally. */
+#define wildcardp(pattern) (strpbrk ((pattern), "?*[") != NULL)
+
+#define new_stat(x, y) \
+ (x##_type *) new_statement (x##_enum, sizeof (x##_type), y)
+
+#define outside_section_address(q) \
+ ((q)->output_offset + (q)->output_section->vma)
+
+#define outside_symbol_address(q) \
+ ((q)->value + outside_section_address (q->section))
+
+/* CTF sections smaller than this are not compressed: compression of
+ dictionaries this small doesn't gain much, and this lets consumers mmap the
+ sections directly out of the ELF file and use them with no decompression
+ overhead if they want to. */
+#define CTF_COMPRESSION_THRESHOLD 4096
+
+void *
+stat_alloc (size_t size)
+{
+ return obstack_alloc (&stat_obstack, size);
+}
+
+/* Code for handling simple wildcards without going through fnmatch,
+ which can be expensive because of charset translations etc. */
+
+/* A simple wild is a literal string followed by a single '*',
+ where the literal part is at least 4 characters long. */
+
+static bool
+is_simple_wild (const char *name)
+{
+ size_t len = strcspn (name, "*?[");
+ return len >= 4 && name[len] == '*' && name[len + 1] == '\0';
+}
+
+static bool
+match_simple_wild (const char *pattern, const char *name)
+{
+ /* The first four characters of the pattern are guaranteed valid
+ non-wildcard characters. So we can go faster. */
+ if (pattern[0] != name[0] || pattern[1] != name[1]
+ || pattern[2] != name[2] || pattern[3] != name[3])
+ return false;
+
+ pattern += 4;
+ name += 4;
+ while (*pattern != '*')
+ if (*name++ != *pattern++)
+ return false;
+
+ return true;
+}
+
+static int
+name_match (const char *pattern, const char *name)
+{
+ if (is_simple_wild (pattern))
+ return !match_simple_wild (pattern, name);
+ if (wildcardp (pattern))
+ return fnmatch (pattern, name, 0);
+ return strcmp (pattern, name);
+}
+
+/* Given an analyzed wildcard_spec SPEC, match it against NAME,
+ returns zero on a match, non-zero if there's no match. */
+
+static int
+spec_match (const struct wildcard_spec *spec, const char *name)
+{
+ size_t nl = spec->namelen;
+ size_t pl = spec->prefixlen;
+ size_t sl = spec->suffixlen;
+ size_t inputlen = strlen (name);
+ int r;
+
+ if (pl)
+ {
+ if (inputlen < pl)
+ return 1;
+
+ r = memcmp (spec->name, name, pl);
+ if (r)
+ return r;
+ }
+
+ if (sl)
+ {
+ if (inputlen < sl)
+ return 1;
+
+ r = memcmp (spec->name + nl - sl, name + inputlen - sl, sl);
+ if (r)
+ return r;
+ }
+
+ if (nl == pl + sl + 1 && spec->name[pl] == '*')
+ return 0;
+
+ if (nl > pl)
+ return fnmatch (spec->name + pl, name + pl, 0);
+
+ if (inputlen >= nl)
+ return name[nl];
+
+ return 0;
+}
+
+static char *
+ldirname (const char *name)
+{
+ const char *base = lbasename (name);
+ char *dirname;
+
+ while (base > name && IS_DIR_SEPARATOR (base[-1]))
+ --base;
+ if (base == name)
+ return strdup (".");
+ dirname = strdup (name);
+ dirname[base - name] = '\0';
+ return dirname;
+}
+
+/* If PATTERN is of the form archive:file, return a pointer to the
+ separator. If not, return NULL. */
+
+static char *
+archive_path (const char *pattern)
+{
+ char *p = NULL;
+
+ if (link_info.path_separator == 0)
+ return p;
+
+ p = strchr (pattern, link_info.path_separator);
+#ifdef HAVE_DOS_BASED_FILE_SYSTEM
+ if (p == NULL || link_info.path_separator != ':')
+ return p;
+
+ /* Assume a match on the second char is part of drive specifier,
+ as in "c:\silly.dos". */
+ if (p == pattern + 1 && ISALPHA (*pattern))
+ p = strchr (p + 1, link_info.path_separator);
+#endif
+ return p;
+}
+
+/* Given that FILE_SPEC results in a non-NULL SEP result from archive_path,
+ return whether F matches FILE_SPEC. */
+
+static bool
+input_statement_is_archive_path (const char *file_spec, char *sep,
+ lang_input_statement_type *f)
+{
+ bool match = false;
+
+ if ((*(sep + 1) == 0
+ || name_match (sep + 1, f->filename) == 0)
+ && ((sep != file_spec)
+ == (f->the_bfd != NULL && f->the_bfd->my_archive != NULL)))
+ {
+ match = true;
+
+ if (sep != file_spec)
+ {
+ const char *aname = bfd_get_filename (f->the_bfd->my_archive);
+ *sep = 0;
+ match = name_match (file_spec, aname) == 0;
+ *sep = link_info.path_separator;
+ }
+ }
+ return match;
+}
+
+static bool
+unique_section_p (const asection *sec,
+ const lang_output_section_statement_type *os)
+{
+ struct unique_sections *unam;
+ const char *secnam;
+
+ if (!link_info.resolve_section_groups
+ && sec->owner != NULL
+ && bfd_is_group_section (sec->owner, sec))
+ return !(os != NULL
+ && strcmp (os->name, DISCARD_SECTION_NAME) == 0);
+
+ secnam = sec->name;
+ for (unam = unique_section_list; unam; unam = unam->next)
+ if (name_match (unam->name, secnam) == 0)
+ return true;
+
+ return false;
+}
+
+/* Generic traversal routines for finding matching sections. */
+
+/* Return true if FILE matches a pattern in EXCLUDE_LIST, otherwise return
+ false. */
+
+static bool
+walk_wild_file_in_exclude_list (struct name_list *exclude_list,
+ lang_input_statement_type *file)
+{
+ struct name_list *list_tmp;
+
+ for (list_tmp = exclude_list;
+ list_tmp;
+ list_tmp = list_tmp->next)
+ {
+ char *p = archive_path (list_tmp->name);
+
+ if (p != NULL)
+ {
+ if (input_statement_is_archive_path (list_tmp->name, p, file))
+ return true;
+ }
+
+ else if (name_match (list_tmp->name, file->filename) == 0)
+ return true;
+
+ /* FIXME: Perhaps remove the following at some stage? Matching
+ unadorned archives like this was never documented and has
+ been superceded by the archive:path syntax. */
+ else if (file->the_bfd != NULL
+ && file->the_bfd->my_archive != NULL
+ && name_match (list_tmp->name,
+ bfd_get_filename (file->the_bfd->my_archive)) == 0)
+ return true;
+ }
+
+ return false;
+}
+
+/* Add SECTION (from input FILE) to the list of matching sections
+ within PTR (the matching wildcard is SEC). */
+
+static void
+add_matching_section (lang_wild_statement_type *ptr,
+ struct wildcard_list *sec,
+ asection *section,
+ lang_input_statement_type *file)
+{
+ lang_input_matcher_type *new_section;
+ /* Add a section reference to the list. */
+ new_section = new_stat (lang_input_matcher, &ptr->matching_sections);
+ new_section->section = section;
+ new_section->pattern = sec;
+ new_section->input_stmt = file;
+}
+
+/* Process section S (from input file FILE) in relation to wildcard
+ statement PTR. We already know that a prefix of the name of S matches
+ some wildcard in PTR's wildcard list. Here we check if the filename
+ matches as well (if it's specified) and if any of the wildcards in fact
+ does match. */
+
+static void
+walk_wild_section_match (lang_wild_statement_type *ptr,
+ lang_input_statement_type *file,
+ asection *s)
+{
+ struct wildcard_list *sec;
+ const char *file_spec = ptr->filename;
+ char *p;
+
+ /* Check if filenames match. */
+ if (file_spec == NULL)
+ ;
+ else if ((p = archive_path (file_spec)) != NULL)
+ {
+ if (!input_statement_is_archive_path (file_spec, p, file))
+ return;
+ }
+ else if (wildcardp (file_spec))
+ {
+ if (fnmatch (file_spec, file->filename, 0) != 0)
+ return;
+ }
+ else
+ {
+ /* XXX Matching against non-wildcard filename in wild statements
+ was done by going through lookup_name, which uses
+ ->local_sym_name to compare against, not ->filename. We retain
+ this behaviour even though the above code paths use filename.
+ It would be more logical to use it here as well, in which
+ case the above wildcard() arm could be folded into this by using
+ name_match. This would also solve the worry of what to do
+ about unset local_sym_name (in which case lookup_name simply adds
+ the input file again). */
+ const char *filename = file->local_sym_name;
+ lang_input_statement_type *arch_is;
+ if (filename && filename_cmp (filename, file_spec) == 0)
+ ;
+ /* FIXME: see also walk_wild_file_in_exclude_list for why we
+ also check parents BFD (local_sym_)name to match input statements
+ with unadorned archive names. */
+ else if (file->the_bfd
+ && file->the_bfd->my_archive
+ && (arch_is = bfd_usrdata (file->the_bfd->my_archive))
+ && arch_is->local_sym_name
+ && filename_cmp (arch_is->local_sym_name, file_spec) == 0)
+ ;
+ else
+ return;
+ }
+
+ /* If filename is excluded we're done. */
+ if (walk_wild_file_in_exclude_list (ptr->exclude_name_list, file))
+ return;
+
+ /* Check section name against each wildcard spec. If there's no
+ wildcard all sections match. */
+ sec = ptr->section_list;
+ if (sec == NULL)
+ add_matching_section (ptr, sec, s, file);
+ else
+ {
+ const char *sname = bfd_section_name (s);
+ for (; sec != NULL; sec = sec->next)
+ {
+ if (sec->spec.name != NULL
+ && spec_match (&sec->spec, sname) != 0)
+ continue;
+
+ /* Don't process sections from files which were excluded. */
+ if (!walk_wild_file_in_exclude_list (sec->spec.exclude_name_list,
+ file))
+ add_matching_section (ptr, sec, s, file);
+ }
+ }
+}
+
+/* Return the numerical value of the init_priority attribute from
+ section name NAME. */
+
+static int
+get_init_priority (const asection *sec)
+{
+ const char *name = bfd_section_name (sec);
+ const char *dot;
+
+ /* GCC uses the following section names for the init_priority
+ attribute with numerical values 101 to 65535 inclusive. A
+ lower value means a higher priority.
+
+ 1: .init_array.NNNNN/.fini_array.NNNNN: Where NNNNN is the
+ decimal numerical value of the init_priority attribute.
+ The order of execution in .init_array is forward and
+ .fini_array is backward.
+ 2: .ctors.NNNNN/.dtors.NNNNN: Where NNNNN is 65535 minus the
+ decimal numerical value of the init_priority attribute.
+ The order of execution in .ctors is backward and .dtors
+ is forward.
+
+ .init_array.NNNNN sections would normally be placed in an output
+ .init_array section, .fini_array.NNNNN in .fini_array,
+ .ctors.NNNNN in .ctors, and .dtors.NNNNN in .dtors. This means
+ we should sort by increasing number (and could just use
+ SORT_BY_NAME in scripts). However if .ctors.NNNNN sections are
+ being placed in .init_array (which may also contain
+ .init_array.NNNNN sections) or .dtors.NNNNN sections are being
+ placed in .fini_array then we need to extract the init_priority
+ attribute and sort on that. */
+ dot = strrchr (name, '.');
+ if (dot != NULL && ISDIGIT (dot[1]))
+ {
+ char *end;
+ unsigned long init_priority = strtoul (dot + 1, &end, 10);
+ if (*end == 0)
+ {
+ if (dot == name + 6
+ && (strncmp (name, ".ctors", 6) == 0
+ || strncmp (name, ".dtors", 6) == 0))
+ init_priority = 65535 - init_priority;
+ if (init_priority <= INT_MAX)
+ return init_priority;
+ }
+ }
+ return -1;
+}
+
+/* Compare sections ASEC and BSEC according to SORT. */
+
+static int
+compare_section (sort_type sort, asection *asec, asection *bsec, bool reversed)
+{
+ int ret;
+ int a_priority, b_priority;
+
+ switch (sort)
+ {
+ default:
+ abort ();
+
+ case by_init_priority:
+ a_priority = get_init_priority (asec);
+ b_priority = get_init_priority (bsec);
+ if (a_priority < 0 || b_priority < 0)
+ goto sort_by_name;
+ if (reversed)
+ ret = b_priority - a_priority;
+ else
+ ret = a_priority - b_priority;
+ if (ret)
+ break;
+ else
+ goto sort_by_name;
+
+ case by_alignment_name:
+ ret = bfd_section_alignment (bsec) - bfd_section_alignment (asec);
+ if (ret)
+ break;
+ /* Fall through. */
+
+ case by_name:
+ sort_by_name:
+ if (reversed)
+ ret = strcmp (bfd_section_name (bsec), bfd_section_name (asec));
+ else
+ ret = strcmp (bfd_section_name (asec), bfd_section_name (bsec));
+ break;
+
+ case by_name_alignment:
+ if (reversed)
+ ret = strcmp (bfd_section_name (bsec), bfd_section_name (asec));
+ else
+ ret = strcmp (bfd_section_name (asec), bfd_section_name (bsec));
+ if (ret)
+ break;
+ /* Fall through. */
+
+ case by_alignment:
+ ret = bfd_section_alignment (bsec) - bfd_section_alignment (asec);
+ break;
+ }
+
+ return ret;
+}
+
+/* PE puts the sort key in the input statement. */
+
+static const char *
+sort_filename (bfd *abfd)
+{
+ lang_input_statement_type *is = bfd_usrdata (abfd);
+ if (is->sort_key)
+ return is->sort_key;
+ return bfd_get_filename (abfd);
+}
+
+/* Handle wildcard sorting. This returns the place in a binary search tree
+ where this FILE:SECTION should be inserted for wild statement WILD where
+ the spec SEC was the matching one. The tree is later linearized. */
+
+static lang_section_bst_type **
+wild_sort (lang_wild_statement_type *wild,
+ struct wildcard_list *sec,
+ lang_input_statement_type *file,
+ asection *section)
+{
+ lang_section_bst_type **tree;
+
+ if (!wild->filenames_sorted
+ && (sec == NULL || sec->spec.sorted == none
+ || sec->spec.sorted == by_none))
+ {
+ /* We might be called even if _this_ spec doesn't need sorting,
+ in which case we simply append at the right end of tree. */
+ return wild->rightmost;
+ }
+
+ tree = &wild->tree;
+ while (*tree)
+ {
+ /* Sorting by filename takes precedence over sorting by section
+ name. */
+
+ if (wild->filenames_sorted)
+ {
+ const char *fn, *ln;
+ bool fa, la;
+ int i;
+ asection *lsec = (*tree)->section;
+
+ /* The PE support for the .idata section as generated by
+ dlltool assumes that files will be sorted by the name of
+ the archive and then the name of the file within the
+ archive. */
+
+ fa = file->the_bfd->my_archive != NULL;
+ if (fa)
+ fn = sort_filename (file->the_bfd->my_archive);
+ else
+ fn = sort_filename (file->the_bfd);
+
+ la = lsec->owner->my_archive != NULL;
+ if (la)
+ ln = sort_filename (lsec->owner->my_archive);
+ else
+ ln = sort_filename (lsec->owner);
+
+ if (wild->filenames_reversed)
+ i = filename_cmp (ln, fn);
+ else
+ i = filename_cmp (fn, ln);
+
+ if (i > 0)
+ { tree = &((*tree)->right); continue; }
+ else if (i < 0)
+ { tree = &((*tree)->left); continue; }
+
+ if (fa || la)
+ {
+ if (fa)
+ fn = sort_filename (file->the_bfd);
+ if (la)
+ ln = sort_filename (lsec->owner);
+
+ if (wild->filenames_reversed)
+ i = filename_cmp (ln, fn);
+ else
+ i = filename_cmp (fn, ln);
+
+ if (i > 0)
+ { tree = &((*tree)->right); continue; }
+ else if (i < 0)
+ { tree = &((*tree)->left); continue; }
+ }
+ }
+
+ /* Here either the files are not sorted by name, or we are
+ looking at the sections for this file. */
+
+ /* Find the correct node to append this section. */
+ if (sec && sec->spec.sorted != none && sec->spec.sorted != by_none
+ && compare_section (sec->spec.sorted, section, (*tree)->section, sec->spec.reversed) < 0)
+ tree = &((*tree)->left);
+ else
+ tree = &((*tree)->right);
+ }
+
+ return tree;
+}
+
+/* Use wild_sort to build a BST to sort sections. */
+
+static void
+output_section_callback_sort (lang_wild_statement_type *ptr,
+ struct wildcard_list *sec,
+ asection *section,
+ lang_input_statement_type *file,
+ void *output)
+{
+ lang_section_bst_type *node;
+ lang_section_bst_type **tree;
+ lang_output_section_statement_type *os;
+
+ os = (lang_output_section_statement_type *) output;
+
+ if (unique_section_p (section, os))
+ return;
+
+ /* Don't add sections to the tree when we already know that
+ lang_add_section won't do anything with it. */
+ if (wont_add_section_p (section, os))
+ return;
+
+ node = (lang_section_bst_type *) xmalloc (sizeof (lang_section_bst_type));
+ node->left = 0;
+ node->right = 0;
+ node->section = section;
+ node->pattern = ptr->section_list;
+
+ tree = wild_sort (ptr, sec, file, section);
+ if (tree != NULL)
+ {
+ *tree = node;
+ if (tree == ptr->rightmost)
+ ptr->rightmost = &node->right;
+ }
+}
+
+/* Convert a sorted sections' BST back to list form. */
+
+static void
+output_section_callback_tree_to_list (lang_wild_statement_type *ptr,
+ lang_section_bst_type *tree,
+ void *output)
+{
+ if (tree->left)
+ output_section_callback_tree_to_list (ptr, tree->left, output);
+
+ lang_add_section (&ptr->children, tree->section, tree->pattern,
+ ptr->section_flag_list,
+ (lang_output_section_statement_type *) output);
+
+ if (tree->right)
+ output_section_callback_tree_to_list (ptr, tree->right, output);
+
+ free (tree);
+}
+
+
+/* Sections are matched against wildcard statements via a prefix tree.
+ The prefix tree holds prefixes of all matching patterns (up to the first
+ wildcard character), and the wild statement from which those patterns
+ came. When matching a section name against the tree we're walking through
+ the tree character by character. Each statement we hit is one that
+ potentially matches. This is checked by actually going through the
+ (glob) matching routines.
+
+ When the section name turns out to actually match we record that section
+ in the wild statements list of matching sections. */
+
+/* A prefix can be matched by multiple statement, so we need a list of them. */
+struct wild_stmt_list
+{
+ lang_wild_statement_type *stmt;
+ struct wild_stmt_list *next;
+};
+
+/* The prefix tree itself. */
+struct prefixtree
+{
+ /* The list of all children (linked via .next). */
+ struct prefixtree *child;
+ struct prefixtree *next;
+ /* This tree node is responsible for the prefix of parent plus 'c'. */
+ char c;
+ /* The statements that potentially can match this prefix. */
+ struct wild_stmt_list *stmt;
+};
+
+/* We always have a root node in the prefix tree. It corresponds to the
+ empty prefix. E.g. a glob like "*" would sit in this root. */
+static struct prefixtree the_root, *ptroot = &the_root;
+
+/* Given a prefix tree in *TREE, corresponding to prefix P, find or
+ INSERT the tree node corresponding to prefix P+C. */
+
+static struct prefixtree *
+get_prefix_tree (struct prefixtree **tree, char c, bool insert)
+{
+ struct prefixtree *t;
+ for (t = *tree; t; t = t->next)
+ if (t->c == c)
+ return t;
+ if (!insert)
+ return NULL;
+ t = (struct prefixtree *) obstack_alloc (&pt_obstack, sizeof *t);
+ t->child = NULL;
+ t->next = *tree;
+ t->c = c;
+ t->stmt = NULL;
+ *tree = t;
+ return t;
+}
+
+/* Add STMT to the set of statements that can be matched by the prefix
+ corresponding to prefix tree T. */
+
+static void
+pt_add_stmt (struct prefixtree *t, lang_wild_statement_type *stmt)
+{
+ struct wild_stmt_list *sl, **psl;
+ sl = (struct wild_stmt_list *) obstack_alloc (&pt_obstack, sizeof *sl);
+ sl->stmt = stmt;
+ sl->next = NULL;
+ psl = &t->stmt;
+ while (*psl)
+ psl = &(*psl)->next;
+ *psl = sl;
+}
+
+/* Insert STMT into the global prefix tree. */
+
+static void
+insert_prefix_tree (lang_wild_statement_type *stmt)
+{
+ struct wildcard_list *sec;
+ struct prefixtree *t;
+
+ if (!stmt->section_list)
+ {
+ /* If we have no section_list (no wildcards in the wild STMT),
+ then every section name will match, so add this to the root. */
+ pt_add_stmt (ptroot, stmt);
+ return;
+ }
+
+ for (sec = stmt->section_list; sec; sec = sec->next)
+ {
+ const char *name = sec->spec.name ? sec->spec.name : "*";
+ char c;
+ t = ptroot;
+ for (; (c = *name); name++)
+ {
+ if (c == '*' || c == '[' || c == '?')
+ break;
+ t = get_prefix_tree (&t->child, c, true);
+ }
+ /* If we hit a glob character, the matching prefix is what we saw
+ until now. If we hit the end of pattern (hence it's no glob) then
+ we can do better: we only need to record a match when a section name
+ completely matches, not merely a prefix, so record the trailing 0
+ as well. */
+ if (!c)
+ t = get_prefix_tree (&t->child, 0, true);
+ pt_add_stmt (t, stmt);
+ }
+}
+
+/* Dump T indented by INDENT spaces. */
+
+static void
+debug_prefix_tree_rec (struct prefixtree *t, int indent)
+{
+ for (; t; t = t->next)
+ {
+ struct wild_stmt_list *sl;
+ printf ("%*s %c", indent, "", t->c);
+ for (sl = t->stmt; sl; sl = sl->next)
+ {
+ struct wildcard_list *curr;
+ printf (" %p ", sl->stmt);
+ for (curr = sl->stmt->section_list; curr; curr = curr->next)
+ printf ("%s ", curr->spec.name ? curr->spec.name : "*");
+ }
+ printf ("\n");
+ debug_prefix_tree_rec (t->child, indent + 2);
+ }
+}
+
+/* Dump the global prefix tree. */
+
+static void
+debug_prefix_tree (void)
+{
+ debug_prefix_tree_rec (ptroot, 2);
+}
+
+/* Like strcspn() but start to look from the end to beginning of
+ S. Returns the length of the suffix of S consisting entirely
+ of characters not in REJECT. */
+
+static size_t
+rstrcspn (const char *s, const char *reject)
+{
+ size_t len = strlen (s), sufflen = 0;
+ while (len--)
+ {
+ char c = s[len];
+ if (strchr (reject, c) != 0)
+ break;
+ sufflen++;
+ }
+ return sufflen;
+}
+
+/* Analyze the wildcards in wild statement PTR to setup various
+ things for quick matching. */
+
+static void
+analyze_walk_wild_section_handler (lang_wild_statement_type *ptr)
+{
+ struct wildcard_list *sec;
+
+ ptr->tree = NULL;
+ ptr->rightmost = &ptr->tree;
+
+ for (sec = ptr->section_list; sec != NULL; sec = sec->next)
+ {
+ if (sec->spec.name)
+ {
+ sec->spec.namelen = strlen (sec->spec.name);
+ sec->spec.prefixlen = strcspn (sec->spec.name, "?*[");
+ sec->spec.suffixlen = rstrcspn (sec->spec.name + sec->spec.prefixlen,
+ "?*]");
+ }
+ else
+ sec->spec.namelen = sec->spec.prefixlen = sec->spec.suffixlen = 0;
+ }
+
+ insert_prefix_tree (ptr);
+}
+
+/* Match all sections from FILE against the global prefix tree,
+ and record them into each wild statement that has a match. */
+
+static void
+resolve_wild_sections (lang_input_statement_type *file)
+{
+ asection *s;
+
+ if (file->flags.just_syms)
+ return;
+
+ for (s = file->the_bfd->sections; s != NULL; s = s->next)
+ {
+ const char *sname = bfd_section_name (s);
+ char c = 1;
+ struct prefixtree *t = ptroot;
+ //printf (" YYY consider %s of %s\n", sname, file->the_bfd->filename);
+ do
+ {
+ if (t->stmt)
+ {
+ struct wild_stmt_list *sl;
+ for (sl = t->stmt; sl; sl = sl->next)
+ {
+ walk_wild_section_match (sl->stmt, file, s);
+ //printf (" ZZZ maybe place into %p\n", sl->stmt);
+ }
+ }
+ if (!c)
+ break;
+ c = *sname++;
+ t = get_prefix_tree (&t->child, c, false);
+ }
+ while (t);
+ }
+}
+
+/* Match all sections from all input files against the global prefix tree. */
+
+static void
+resolve_wilds (void)
+{
+ LANG_FOR_EACH_INPUT_STATEMENT (f)
+ {
+ //printf("XXX %s\n", f->filename);
+ if (f->the_bfd == NULL
+ || !bfd_check_format (f->the_bfd, bfd_archive))
+ resolve_wild_sections (f);
+ else
+ {
+ bfd *member;
+
+ /* This is an archive file. We must map each member of the
+ archive separately. */
+ member = bfd_openr_next_archived_file (f->the_bfd, NULL);
+ while (member != NULL)
+ {
+ /* When lookup_name is called, it will call the add_symbols
+ entry point for the archive. For each element of the
+ archive which is included, BFD will call ldlang_add_file,
+ which will set the usrdata field of the member to the
+ lang_input_statement. */
+ if (bfd_usrdata (member) != NULL)
+ resolve_wild_sections (bfd_usrdata (member));
+
+ member = bfd_openr_next_archived_file (f->the_bfd, member);
+ }
+ }
+ }
+}
+
+/* For each input section that matches wild statement S calls
+ CALLBACK with DATA. */
+
+static void
+walk_wild (lang_wild_statement_type *s, callback_t callback, void *data)
+{
+ lang_statement_union_type *l;
+
+ for (l = s->matching_sections.head; l; l = l->header.next)
+ {
+ (*callback) (s, l->input_matcher.pattern, l->input_matcher.section,
+ l->input_matcher.input_stmt, data);
+ }
+}
+
+/* lang_for_each_statement walks the parse tree and calls the provided
+ function for each node, except those inside output section statements
+ with constraint set to -1. */
+
+void
+lang_for_each_statement_worker (void (*func) (lang_statement_union_type *),
+ lang_statement_union_type *s)
+{
+ for (; s != NULL; s = s->header.next)
+ {
+ func (s);
+
+ switch (s->header.type)
+ {
+ case lang_constructors_statement_enum:
+ lang_for_each_statement_worker (func, constructor_list.head);
+ break;
+ case lang_output_section_statement_enum:
+ if (s->output_section_statement.constraint != -1)
+ lang_for_each_statement_worker
+ (func, s->output_section_statement.children.head);
+ break;
+ case lang_wild_statement_enum:
+ lang_for_each_statement_worker (func,
+ s->wild_statement.children.head);
+ break;
+ case lang_group_statement_enum:
+ lang_for_each_statement_worker (func,
+ s->group_statement.children.head);
+ break;
+ case lang_data_statement_enum:
+ case lang_reloc_statement_enum:
+ case lang_object_symbols_statement_enum:
+ case lang_output_statement_enum:
+ case lang_target_statement_enum:
+ case lang_input_section_enum:
+ case lang_input_statement_enum:
+ case lang_assignment_statement_enum:
+ case lang_padding_statement_enum:
+ case lang_address_statement_enum:
+ case lang_fill_statement_enum:
+ case lang_insert_statement_enum:
+ break;
+ default:
+ FAIL ();
+ break;
+ }
+ }
+}
+
+void
+lang_for_each_statement (void (*func) (lang_statement_union_type *))
+{
+ lang_for_each_statement_worker (func, statement_list.head);
+}
+
+/*----------------------------------------------------------------------*/
+
+void
+lang_list_init (lang_statement_list_type *list)
+{
+ list->head = NULL;
+ list->tail = &list->head;
+}
+
+static void
+lang_statement_append (lang_statement_list_type *list,
+ void *element,
+ void *field)
+{
+ *(list->tail) = element;
+ list->tail = field;
+}
+
+void
+push_stat_ptr (lang_statement_list_type *new_ptr)
+{
+ if (stat_save_ptr >= stat_save + sizeof (stat_save) / sizeof (stat_save[0]))
+ abort ();
+ *stat_save_ptr++ = stat_ptr;
+ stat_ptr = new_ptr;
+}
+
+void
+pop_stat_ptr (void)
+{
+ if (stat_save_ptr <= stat_save)
+ abort ();
+ stat_ptr = *--stat_save_ptr;
+}
+
+/* Build a new statement node for the parse tree. */
+
+static lang_statement_union_type *
+new_statement (enum statement_enum type,
+ size_t size,
+ lang_statement_list_type *list)
+{
+ lang_statement_union_type *new_stmt;
+
+ new_stmt = stat_alloc (size);
+ new_stmt->header.type = type;
+ new_stmt->header.next = NULL;
+ lang_statement_append (list, new_stmt, &new_stmt->header.next);
+ return new_stmt;
+}
+
+/* Build a new input file node for the language. There are several
+ ways in which we treat an input file, eg, we only look at symbols,
+ or prefix it with a -l etc.
+
+ We can be supplied with requests for input files more than once;
+ they may, for example be split over several lines like foo.o(.text)
+ foo.o(.data) etc, so when asked for a file we check that we haven't
+ got it already so we don't duplicate the bfd. */
+
+static lang_input_statement_type *
+new_afile (const char *name,
+ lang_input_file_enum_type file_type,
+ const char *target,
+ const char *from_filename)
+{
+ lang_input_statement_type *p;
+
+ lang_has_input_file = true;
+
+ /* PR 30632: It is OK for name to be NULL. For example
+ see the initialization of first_file in lang_init(). */
+ if (name != NULL)
+ {
+ name = ldfile_possibly_remap_input (name);
+ /* But if a name is remapped to NULL, it should be ignored. */
+ if (name == NULL)
+ return NULL;
+ }
+
+ p = new_stat (lang_input_statement, stat_ptr);
+ memset (&p->the_bfd, 0,
+ sizeof (*p) - offsetof (lang_input_statement_type, the_bfd));
+ p->extra_search_path = NULL;
+ p->target = target;
+ p->flags.dynamic = input_flags.dynamic;
+ p->flags.add_DT_NEEDED_for_dynamic = input_flags.add_DT_NEEDED_for_dynamic;
+ p->flags.add_DT_NEEDED_for_regular = input_flags.add_DT_NEEDED_for_regular;
+ p->flags.whole_archive = input_flags.whole_archive;
+ p->flags.sysrooted = input_flags.sysrooted;
+ p->sort_key = NULL;
+
+ switch (file_type)
+ {
+ case lang_input_file_is_symbols_only_enum:
+ p->filename = name;
+ p->local_sym_name = name;
+ p->flags.real = true;
+ p->flags.just_syms = true;
+ break;
+ case lang_input_file_is_fake_enum:
+ p->filename = name;
+ p->local_sym_name = name;
+ break;
+ case lang_input_file_is_l_enum:
+ if (name[0] == ':' && name[1] != '\0')
+ {
+ p->filename = name + 1;
+ p->flags.full_name_provided = true;
+ }
+ else
+ p->filename = name;
+ p->local_sym_name = concat ("-l", name, (const char *) NULL);
+ p->flags.maybe_archive = true;
+ p->flags.real = true;
+ p->flags.search_dirs = true;
+ break;
+ case lang_input_file_is_marker_enum:
+ p->filename = name;
+ p->local_sym_name = name;
+ p->flags.search_dirs = true;
+ break;
+ case lang_input_file_is_search_file_enum:
+ p->filename = name;
+ p->local_sym_name = name;
+ /* If name is a relative path, search the directory of the current linker
+ script first. */
+ if (from_filename && !IS_ABSOLUTE_PATH (name))
+ p->extra_search_path = ldirname (from_filename);
+ p->flags.real = true;
+ p->flags.search_dirs = true;
+ break;
+ case lang_input_file_is_file_enum:
+ p->filename = name;
+ p->local_sym_name = name;
+ p->flags.real = true;
+ break;
+ default:
+ FAIL ();
+ }
+
+ lang_statement_append (&input_file_chain, p, &p->next_real_file);
+ return p;
+}
+
+lang_input_statement_type *
+lang_add_input_file (const char *name,
+ lang_input_file_enum_type file_type,
+ const char *target)
+{
+ if (name != NULL
+ && (*name == '=' || startswith (name, "$SYSROOT")))
+ {
+ lang_input_statement_type *ret;
+ char *sysrooted_name
+ = concat (ld_sysroot,
+ name + (*name == '=' ? 1 : strlen ("$SYSROOT")),
+ (const char *) NULL);
+
+ /* We've now forcibly prepended the sysroot, making the input
+ file independent of the context. Therefore, temporarily
+ force a non-sysrooted context for this statement, so it won't
+ get the sysroot prepended again when opened. (N.B. if it's a
+ script, any child nodes with input files starting with "/"
+ will be handled as "sysrooted" as they'll be found to be
+ within the sysroot subdirectory.) */
+ unsigned int outer_sysrooted = input_flags.sysrooted;
+ input_flags.sysrooted = 0;
+ ret = new_afile (sysrooted_name, file_type, target, NULL);
+ input_flags.sysrooted = outer_sysrooted;
+ return ret;
+ }
+
+ return new_afile (name, file_type, target, current_input_file);
+}
+
+struct out_section_hash_entry
+{
+ struct bfd_hash_entry root;
+ lang_statement_union_type s;
+ struct out_section_hash_entry *tail;
+};
+
+/* The hash table. */
+
+static struct bfd_hash_table output_section_statement_table;
+
+/* Support routines for the hash table used by lang_output_section_find,
+ initialize the table, fill in an entry and remove the table. */
+
+static struct out_section_hash_entry *
+output_section_statement_newfunc_1 (struct bfd_hash_entry *entry,
+ struct bfd_hash_table *table,
+ const char *string)
+{
+ lang_output_section_statement_type **nextp;
+ struct out_section_hash_entry *ret;
+
+ if (entry == NULL)
+ {
+ entry = (struct bfd_hash_entry *) bfd_hash_allocate (table,
+ sizeof (*ret));
+ if (entry == NULL)
+ return NULL;
+ }
+
+ entry = bfd_hash_newfunc (entry, table, string);
+ if (entry == NULL)
+ return NULL;
+
+ ret = (struct out_section_hash_entry *) entry;
+ memset (&ret->s, 0, sizeof (ret->s));
+ ret->s.header.type = lang_output_section_statement_enum;
+ ret->s.output_section_statement.subsection_alignment = NULL;
+ ret->s.output_section_statement.section_alignment = NULL;
+ ret->s.output_section_statement.block_value = 1;
+ lang_list_init (&ret->s.output_section_statement.children);
+ lang_list_init (&ret->s.output_section_statement.sort_children);
+ lang_statement_append (stat_ptr, &ret->s, &ret->s.header.next);
+
+ /* For every output section statement added to the list, except the
+ first one, lang_os_list.tail points to the "next"
+ field of the last element of the list. */
+ if (lang_os_list.head != NULL)
+ ret->s.output_section_statement.prev
+ = ((lang_output_section_statement_type *)
+ ((char *) lang_os_list.tail
+ - offsetof (lang_output_section_statement_type, next)));
+
+ /* GCC's strict aliasing rules prevent us from just casting the
+ address, so we store the pointer in a variable and cast that
+ instead. */
+ nextp = &ret->s.output_section_statement.next;
+ lang_statement_append (&lang_os_list, &ret->s, nextp);
+ return ret;
+}
+
+static struct bfd_hash_entry *
+output_section_statement_newfunc (struct bfd_hash_entry *entry,
+ struct bfd_hash_table *table,
+ const char *string)
+{
+ struct out_section_hash_entry *ret;
+
+ ret = output_section_statement_newfunc_1 (entry, table, string);
+ if (ret == NULL)
+ return NULL;
+ ret->tail = ret;
+ return &ret->root;
+}
+
+static void
+output_section_statement_table_init (void)
+{
+ if (!bfd_hash_table_init_n (&output_section_statement_table,
+ output_section_statement_newfunc,
+ sizeof (struct out_section_hash_entry),
+ 61))
+ einfo (_("%F%P: can not create hash table: %E\n"));
+}
+
+static void
+output_section_statement_table_free (void)
+{
+ bfd_hash_table_free (&output_section_statement_table);
+}
+
+/* Build enough state so that the parser can build its tree. */
+
+void
+lang_init (bool object_only)
+{
+ if (!object_only)
+ {
+ obstack_begin (&stat_obstack, 1000);
+ obstack_init (&pt_obstack);
+ }
+
+ stat_ptr = &statement_list;
+
+ output_section_statement_table_init ();
+
+ cmdline_lists_init ();
+
+ lang_list_init (stat_ptr);
+
+ lang_list_init (&input_file_chain);
+ lang_list_init (&lang_os_list);
+ lang_list_init (&file_chain);
+ first_file = lang_add_input_file (NULL, lang_input_file_is_marker_enum,
+ NULL);
+ abs_output_section =
+ lang_output_section_statement_lookup (BFD_ABS_SECTION_NAME, 0, 1);
+
+ abs_output_section->bfd_section = bfd_abs_section_ptr;
+
+ asneeded_list_head = NULL;
+ asneeded_list_tail = &asneeded_list_head;
+}
+
+void
+lang_finish (void)
+{
+ output_section_statement_table_free ();
+ ldfile_free ();
+}
+
+/*----------------------------------------------------------------------
+ A region is an area of memory declared with the
+ MEMORY { name:org=exp, len=exp ... }
+ syntax.
+
+ We maintain a list of all the regions here.
+
+ If no regions are specified in the script, then the default is used
+ which is created when looked up to be the entire data space.
+
+ If create is true we are creating a region inside a MEMORY block.
+ In this case it is probably an error to create a region that has
+ already been created. If we are not inside a MEMORY block it is
+ dubious to use an undeclared region name (except DEFAULT_MEMORY_REGION)
+ and so we issue a warning.
+
+ Each region has at least one name. The first name is either
+ DEFAULT_MEMORY_REGION or the name given in the MEMORY block. You can add
+ alias names to an existing region within a script with
+ REGION_ALIAS (alias, region_name). Each name corresponds to at most one
+ region. */
+
+static lang_memory_region_type *lang_memory_region_list;
+static lang_memory_region_type **lang_memory_region_list_tail
+ = &lang_memory_region_list;
+
+lang_memory_region_type *
+lang_memory_region_lookup (const char *const name, bool create)
+{
+ lang_memory_region_name *n;
+ lang_memory_region_type *r;
+ lang_memory_region_type *new_region;
+
+ /* NAME is NULL for LMA memspecs if no region was specified. */
+ if (name == NULL)
+ return NULL;
+
+ for (r = lang_memory_region_list; r != NULL; r = r->next)
+ for (n = &r->name_list; n != NULL; n = n->next)
+ if (strcmp (n->name, name) == 0)
+ {
+ if (create)
+ einfo (_("%P:%pS: warning: redeclaration of memory region `%s'\n"),
+ NULL, name);
+ return r;
+ }
+
+ if (!create && strcmp (name, DEFAULT_MEMORY_REGION))
+ einfo (_("%P:%pS: warning: memory region `%s' not declared\n"),
+ NULL, name);
+
+ new_region = stat_alloc (sizeof (lang_memory_region_type));
+
+ new_region->name_list.name = xstrdup (name);
+ new_region->name_list.next = NULL;
+ new_region->next = NULL;
+ new_region->origin_exp = NULL;
+ new_region->origin = 0;
+ new_region->length_exp = NULL;
+ new_region->length = ~(bfd_size_type) 0;
+ new_region->current = 0;
+ new_region->last_os = NULL;
+ new_region->flags = 0;
+ new_region->not_flags = 0;
+ new_region->had_full_message = false;
+
+ *lang_memory_region_list_tail = new_region;
+ lang_memory_region_list_tail = &new_region->next;
+
+ return new_region;
+}
+
+void
+lang_memory_region_alias (const char *alias, const char *region_name)
+{
+ lang_memory_region_name *n;
+ lang_memory_region_type *r;
+ lang_memory_region_type *region;
+
+ /* The default region must be unique. This ensures that it is not necessary
+ to iterate through the name list if someone wants the check if a region is
+ the default memory region. */
+ if (strcmp (region_name, DEFAULT_MEMORY_REGION) == 0
+ || strcmp (alias, DEFAULT_MEMORY_REGION) == 0)
+ einfo (_("%F%P:%pS: error: alias for default memory region\n"), NULL);
+
+ /* Look for the target region and check if the alias is not already
+ in use. */
+ region = NULL;
+ for (r = lang_memory_region_list; r != NULL; r = r->next)
+ for (n = &r->name_list; n != NULL; n = n->next)
+ {
+ if (region == NULL && strcmp (n->name, region_name) == 0)
+ region = r;
+ if (strcmp (n->name, alias) == 0)
+ einfo (_("%F%P:%pS: error: redefinition of memory region "
+ "alias `%s'\n"),
+ NULL, alias);
+ }
+
+ /* Check if the target region exists. */
+ if (region == NULL)
+ einfo (_("%F%P:%pS: error: memory region `%s' "
+ "for alias `%s' does not exist\n"),
+ NULL, region_name, alias);
+
+ /* Add alias to region name list. */
+ n = stat_alloc (sizeof (lang_memory_region_name));
+ n->name = xstrdup (alias);
+ n->next = region->name_list.next;
+ region->name_list.next = n;
+}
+
+static lang_memory_region_type *
+lang_memory_default (asection *section)
+{
+ lang_memory_region_type *p;
+
+ flagword sec_flags = section->flags;
+
+ /* Override SEC_DATA to mean a writable section. */
+ if ((sec_flags & (SEC_ALLOC | SEC_READONLY | SEC_CODE)) == SEC_ALLOC)
+ sec_flags |= SEC_DATA;
+
+ for (p = lang_memory_region_list; p != NULL; p = p->next)
+ {
+ if ((p->flags & sec_flags) != 0
+ && (p->not_flags & sec_flags) == 0)
+ {
+ return p;
+ }
+ }
+ return lang_memory_region_lookup (DEFAULT_MEMORY_REGION, false);
+}
+
+/* Get the output section statement directly from the userdata. */
+
+lang_output_section_statement_type *
+lang_output_section_get (const asection *output_section)
+{
+ return bfd_section_userdata (output_section);
+}
+
+/* Find or create an output_section_statement with the given NAME.
+ If CONSTRAINT is non-zero match one with that constraint, otherwise
+ match any non-negative constraint. If CREATE is 0 return NULL when
+ no match exists. If CREATE is 1, create an output_section_statement
+ when no match exists or if CONSTRAINT is SPECIAL. If CREATE is 2,
+ always make a new output_section_statement. */
+
+lang_output_section_statement_type *
+lang_output_section_statement_lookup (const char *name,
+ int constraint,
+ int create)
+{
+ struct out_section_hash_entry *entry;
+
+ entry = ((struct out_section_hash_entry *)
+ bfd_hash_lookup (&output_section_statement_table, name,
+ create != 0, false));
+ if (entry == NULL)
+ {
+ if (create)
+ einfo (_("%F%P: failed creating section `%s': %E\n"), name);
+ return NULL;
+ }
+
+ if (entry->s.output_section_statement.name != NULL)
+ {
+ /* We have a section of this name, but it might not have the correct
+ constraint. */
+ struct out_section_hash_entry *first_ent = entry;
+ struct out_section_hash_entry *last_ent;
+
+ name = entry->s.output_section_statement.name;
+ if (create != 2
+ && !(create && constraint == SPECIAL))
+ {
+ do
+ {
+ if (constraint == entry->s.output_section_statement.constraint
+ || (constraint == 0
+ && entry->s.output_section_statement.constraint >= 0))
+ return &entry->s.output_section_statement;
+ last_ent = entry;
+ entry = (struct out_section_hash_entry *) entry->root.next;
+ }
+ while (entry != NULL
+ && name == entry->s.output_section_statement.name);
+ }
+ else
+ last_ent = first_ent->tail;
+
+ if (!create)
+ return NULL;
+
+ /* Only the first entry needs the tail pointer. */
+ entry = bfd_hash_allocate (&output_section_statement_table,
+ offsetof (struct out_section_hash_entry, tail));
+ if (entry != NULL)
+ entry
+ = output_section_statement_newfunc_1 (&entry->root,
+ &output_section_statement_table,
+ name);
+ if (entry == NULL)
+ {
+ einfo (_("%F%P: failed creating section `%s': %E\n"), name);
+ return NULL;
+ }
+ entry->root = last_ent->root;
+ last_ent->root.next = &entry->root;
+ first_ent->tail = entry;
+ }
+
+ entry->s.output_section_statement.name = name;
+ entry->s.output_section_statement.constraint = constraint;
+ entry->s.output_section_statement.dup_output = (create == 2
+ || constraint == SPECIAL);
+ return &entry->s.output_section_statement;
+}
+
+/* Find the next output_section_statement with the same name as OS.
+ If CONSTRAINT is non-zero, find one with that constraint otherwise
+ match any non-negative constraint. */
+
+lang_output_section_statement_type *
+next_matching_output_section_statement (lang_output_section_statement_type *os,
+ int constraint)
+{
+ /* All output_section_statements are actually part of a
+ struct out_section_hash_entry. */
+ struct out_section_hash_entry *entry = (struct out_section_hash_entry *)
+ ((char *) os
+ - offsetof (struct out_section_hash_entry, s.output_section_statement));
+ const char *name = os->name;
+
+ ASSERT (name == entry->root.string);
+ do
+ {
+ entry = (struct out_section_hash_entry *) entry->root.next;
+ if (entry == NULL
+ || name != entry->s.output_section_statement.name)
+ return NULL;
+ }
+ while (constraint != entry->s.output_section_statement.constraint
+ && (constraint != 0
+ || entry->s.output_section_statement.constraint < 0));
+
+ return &entry->s.output_section_statement;
+}
+
+/* A variant of lang_output_section_find used by place_orphan.
+ Returns the output statement that should precede a new output
+ statement for SEC. If an exact match is found on certain flags,
+ sets *EXACT too. */
+
+lang_output_section_statement_type *
+lang_output_section_find_by_flags (const asection *sec,
+ flagword sec_flags,
+ lang_output_section_statement_type **exact,
+ lang_match_sec_type_func match_type)
+{
+ lang_output_section_statement_type *first, *look, *found;
+ flagword look_flags, differ;
+
+ /* We know the first statement on this list is *ABS*. May as well
+ skip it. */
+ first = (void *) lang_os_list.head;
+ first = first->next;
+
+ /* First try for an exact match. */
+ found = NULL;
+ for (look = first; look; look = look->next)
+ {
+ look_flags = look->flags;
+ if (look->bfd_section != NULL)
+ {
+ look_flags = look->bfd_section->flags;
+ if (match_type && !match_type (link_info.output_bfd,
+ look->bfd_section,
+ sec->owner, sec))
+ continue;
+ }
+ differ = look_flags ^ sec_flags;
+ if (!(differ & (SEC_HAS_CONTENTS | SEC_ALLOC | SEC_LOAD | SEC_READONLY
+ | SEC_CODE | SEC_SMALL_DATA | SEC_THREAD_LOCAL)))
+ found = look;
+ }
+ if (found != NULL)
+ {
+ if (exact != NULL)
+ *exact = found;
+ return found;
+ }
+
+ if ((sec_flags & SEC_CODE) != 0
+ && (sec_flags & SEC_ALLOC) != 0)
+ {
+ /* Try for a rw code section. */
+ for (look = first; look; look = look->next)
+ {
+ look_flags = look->flags;
+ if (look->bfd_section != NULL)
+ {
+ look_flags = look->bfd_section->flags;
+ if (match_type && !match_type (link_info.output_bfd,
+ look->bfd_section,
+ sec->owner, sec))
+ continue;
+ }
+ differ = look_flags ^ sec_flags;
+ if (!(differ & (SEC_HAS_CONTENTS | SEC_ALLOC | SEC_LOAD
+ | SEC_CODE | SEC_SMALL_DATA | SEC_THREAD_LOCAL)))
+ found = look;
+ }
+ }
+ else if ((sec_flags & SEC_READONLY) != 0
+ && (sec_flags & SEC_ALLOC) != 0)
+ {
+ /* .rodata can go after .text, .sdata2 after .rodata. */
+ for (look = first; look; look = look->next)
+ {
+ look_flags = look->flags;
+ if (look->bfd_section != NULL)
+ {
+ look_flags = look->bfd_section->flags;
+ if (match_type && !match_type (link_info.output_bfd,
+ look->bfd_section,
+ sec->owner, sec))
+ continue;
+ }
+ differ = look_flags ^ sec_flags;
+ if (!(differ & (SEC_HAS_CONTENTS | SEC_ALLOC | SEC_LOAD
+ | SEC_READONLY | SEC_SMALL_DATA))
+ || (!(differ & (SEC_HAS_CONTENTS | SEC_ALLOC | SEC_LOAD
+ | SEC_READONLY))
+ && !(look_flags & SEC_SMALL_DATA)))
+ found = look;
+ }
+ }
+ else if ((sec_flags & SEC_THREAD_LOCAL) != 0
+ && (sec_flags & SEC_ALLOC) != 0)
+ {
+ /* .tdata can go after .data, .tbss after .tdata. Treat .tbss
+ as if it were a loaded section, and don't use match_type. */
+ bool seen_thread_local = false;
+
+ match_type = NULL;
+ for (look = first; look; look = look->next)
+ {
+ look_flags = look->flags;
+ if (look->bfd_section != NULL)
+ look_flags = look->bfd_section->flags;
+
+ differ = look_flags ^ (sec_flags | SEC_LOAD | SEC_HAS_CONTENTS);
+ if (!(differ & (SEC_THREAD_LOCAL | SEC_ALLOC)))
+ {
+ /* .tdata and .tbss must be adjacent and in that order. */
+ if (!(look_flags & SEC_LOAD)
+ && (sec_flags & SEC_LOAD))
+ /* ..so if we're at a .tbss section and we're placing
+ a .tdata section stop looking and return the
+ previous section. */
+ break;
+ found = look;
+ seen_thread_local = true;
+ }
+ else if (seen_thread_local)
+ break;
+ else if (!(differ & (SEC_HAS_CONTENTS | SEC_ALLOC | SEC_LOAD)))
+ found = look;
+ }
+ }
+ else if ((sec_flags & SEC_SMALL_DATA) != 0
+ && (sec_flags & SEC_ALLOC) != 0)
+ {
+ /* .sdata goes after .data, .sbss after .sdata. */
+ for (look = first; look; look = look->next)
+ {
+ look_flags = look->flags;
+ if (look->bfd_section != NULL)
+ {
+ look_flags = look->bfd_section->flags;
+ if (match_type && !match_type (link_info.output_bfd,
+ look->bfd_section,
+ sec->owner, sec))
+ continue;
+ }
+ differ = look_flags ^ sec_flags;
+ if (!(differ & (SEC_HAS_CONTENTS | SEC_ALLOC | SEC_LOAD
+ | SEC_THREAD_LOCAL))
+ || ((look_flags & SEC_SMALL_DATA)
+ && !(sec_flags & SEC_HAS_CONTENTS)))
+ found = look;
+ }
+ }
+ else if ((sec_flags & SEC_HAS_CONTENTS) != 0
+ && (sec_flags & SEC_ALLOC) != 0)
+ {
+ /* .data goes after .rodata. */
+ for (look = first; look; look = look->next)
+ {
+ look_flags = look->flags;
+ if (look->bfd_section != NULL)
+ {
+ look_flags = look->bfd_section->flags;
+ if (match_type && !match_type (link_info.output_bfd,
+ look->bfd_section,
+ sec->owner, sec))
+ continue;
+ }
+ differ = look_flags ^ sec_flags;
+ if (!(differ & (SEC_HAS_CONTENTS | SEC_ALLOC | SEC_LOAD
+ | SEC_SMALL_DATA | SEC_THREAD_LOCAL)))
+ found = look;
+ }
+ }
+ else if ((sec_flags & SEC_ALLOC) != 0)
+ {
+ /* .bss goes after any other alloc section. */
+ for (look = first; look; look = look->next)
+ {
+ look_flags = look->flags;
+ if (look->bfd_section != NULL)
+ {
+ look_flags = look->bfd_section->flags;
+ if (match_type && !match_type (link_info.output_bfd,
+ look->bfd_section,
+ sec->owner, sec))
+ continue;
+ }
+ differ = look_flags ^ sec_flags;
+ if (!(differ & SEC_ALLOC))
+ found = look;
+ }
+ }
+ else
+ {
+ /* non-alloc go last. */
+ for (look = first; look; look = look->next)
+ {
+ look_flags = look->flags;
+ if (look->bfd_section != NULL)
+ look_flags = look->bfd_section->flags;
+ differ = look_flags ^ sec_flags;
+ if (!(differ & SEC_DEBUGGING))
+ found = look;
+ }
+ return found;
+ }
+
+ if (found || !match_type)
+ return found;
+
+ return lang_output_section_find_by_flags (sec, sec_flags, NULL, NULL);
+}
+
+/* Find the last output section before given output statement.
+ Used by place_orphan. */
+
+static asection *
+output_prev_sec_find (lang_output_section_statement_type *os)
+{
+ lang_output_section_statement_type *lookup;
+
+ for (lookup = os->prev; lookup != NULL; lookup = lookup->prev)
+ {
+ if (lookup->constraint < 0)
+ continue;
+
+ if (lookup->bfd_section != NULL)
+ return lookup->bfd_section;
+ }
+
+ return NULL;
+}
+
+/* Look for a suitable place for a new output section statement. The
+ idea is to skip over anything that might be inside a SECTIONS {}
+ statement in a script, before we find another output section
+ statement. Assignments to "dot" before an output section statement
+ are assumed to belong to it, except in two cases; The first
+ assignment to dot, and assignments before non-alloc sections.
+ Otherwise we might put an orphan before . = . + SIZEOF_HEADERS or
+ similar assignments that set the initial address, or we might
+ insert non-alloc note sections among assignments setting end of
+ image symbols. */
+
+static lang_statement_union_type **
+insert_os_after (lang_statement_union_type *after)
+{
+ lang_statement_union_type **where;
+ lang_statement_union_type **assign = NULL;
+ bool ignore_first;
+
+ ignore_first = after == lang_os_list.head;
+
+ for (where = &after->header.next;
+ *where != NULL;
+ where = &(*where)->header.next)
+ {
+ switch ((*where)->header.type)
+ {
+ case lang_assignment_statement_enum:
+ if (assign == NULL)
+ {
+ lang_assignment_statement_type *ass;
+
+ ass = &(*where)->assignment_statement;
+ if (ass->exp->type.node_class != etree_assert
+ && ass->exp->assign.dst[0] == '.'
+ && ass->exp->assign.dst[1] == 0)
+ {
+ if (!ignore_first)
+ assign = where;
+ ignore_first = false;
+ }
+ }
+ continue;
+ case lang_wild_statement_enum:
+ case lang_input_section_enum:
+ case lang_object_symbols_statement_enum:
+ case lang_fill_statement_enum:
+ case lang_data_statement_enum:
+ case lang_reloc_statement_enum:
+ case lang_padding_statement_enum:
+ case lang_constructors_statement_enum:
+ assign = NULL;
+ ignore_first = false;
+ continue;
+ case lang_output_section_statement_enum:
+ if (assign != NULL)
+ {
+ asection *s = (*where)->output_section_statement.bfd_section;
+
+ if (s == NULL
+ || s->map_head.s == NULL
+ || (s->flags & SEC_ALLOC) != 0)
+ where = assign;
+ }
+ break;
+ case lang_input_statement_enum:
+ case lang_address_statement_enum:
+ case lang_target_statement_enum:
+ case lang_output_statement_enum:
+ case lang_group_statement_enum:
+ case lang_insert_statement_enum:
+ continue;
+ case lang_input_matcher_enum:
+ FAIL ();
+ }
+ break;
+ }
+
+ return where;
+}
+
+lang_output_section_statement_type *
+lang_insert_orphan (asection *s,
+ const char *secname,
+ int constraint,
+ lang_output_section_statement_type *after,
+ struct orphan_save *place,
+ etree_type *address,
+ lang_statement_list_type *add_child)
+{
+ lang_statement_list_type add;
+ lang_output_section_statement_type *os;
+ lang_output_section_statement_type **os_tail;
+
+ /* If we have found an appropriate place for the output section
+ statements for this orphan, add them to our own private list,
+ inserting them later into the global statement list. */
+ if (after != NULL)
+ {
+ lang_list_init (&add);
+ push_stat_ptr (&add);
+ }
+
+ if (bfd_link_relocatable (&link_info)
+ || (s->flags & (SEC_LOAD | SEC_ALLOC)) == 0)
+ address = exp_intop (0);
+
+ os_tail = (lang_output_section_statement_type **) lang_os_list.tail;
+ os = lang_enter_output_section_statement (
+ secname, address, normal_section, 0, NULL, NULL, NULL, constraint, 0);
+
+ if (add_child == NULL)
+ add_child = &os->children;
+ lang_add_section (add_child, s, NULL, NULL, os);
+
+ if (after && (s->flags & (SEC_LOAD | SEC_ALLOC)) != 0)
+ {
+ const char *region = (after->region
+ ? after->region->name_list.name
+ : DEFAULT_MEMORY_REGION);
+ const char *lma_region = (after->lma_region
+ ? after->lma_region->name_list.name
+ : NULL);
+ lang_leave_output_section_statement (NULL, region, after->phdrs,
+ lma_region);
+ }
+ else
+ lang_leave_output_section_statement (NULL, DEFAULT_MEMORY_REGION, NULL,
+ NULL);
+
+ /* Restore the global list pointer. */
+ if (after != NULL)
+ pop_stat_ptr ();
+
+ if (after != NULL && os->bfd_section != NULL)
+ {
+ asection *snew, *as;
+ bool place_after = place->stmt == NULL;
+ bool insert_after = true;
+
+ snew = os->bfd_section;
+
+ /* Shuffle the bfd section list to make the output file look
+ neater. This is really only cosmetic. */
+ if (place->section == NULL
+ && after != (void *) lang_os_list.head)
+ {
+ asection *bfd_section = after->bfd_section;
+
+ /* If the output statement hasn't been used to place any input
+ sections (and thus doesn't have an output bfd_section),
+ look for the closest prior output statement having an
+ output section. */
+ if (bfd_section == NULL)
+ bfd_section = output_prev_sec_find (after);
+
+ if (bfd_section != NULL
+ && bfd_section->owner != NULL
+ && bfd_section != snew)
+ place->section = &bfd_section->next;
+ }
+
+ if (place->section == NULL)
+ place->section = &link_info.output_bfd->sections;
+
+ as = *place->section;
+
+ if (!as)
+ {
+ /* Put the section at the end of the list. */
+
+ /* Unlink the section. */
+ bfd_section_list_remove (link_info.output_bfd, snew);
+
+ /* Now tack it back on in the right place. */
+ bfd_section_list_append (link_info.output_bfd, snew);
+ }
+ else if ((bfd_get_flavour (link_info.output_bfd)
+ == bfd_target_elf_flavour)
+ && (bfd_get_flavour (s->owner)
+ == bfd_target_elf_flavour)
+ && ((elf_section_type (s) == SHT_NOTE
+ && (s->flags & SEC_LOAD) != 0)
+ || (elf_section_type (as) == SHT_NOTE
+ && (as->flags & SEC_LOAD) != 0)))
+ {
+ /* Make sure that output note sections are grouped and sorted
+ by alignments when inserting a note section or insert a
+ section after a note section, */
+ asection *sec;
+ /* A specific section after which the output note section
+ should be placed. */
+ asection *after_sec;
+ /* True if we need to insert the orphan section after a
+ specific section to maintain output note section order. */
+ bool after_sec_note = false;
+
+ static asection *first_orphan_note = NULL;
+
+ /* Group and sort output note section by alignments in
+ ascending order. */
+ after_sec = NULL;
+ if (elf_section_type (s) == SHT_NOTE
+ && (s->flags & SEC_LOAD) != 0)
+ {
+ /* Search from the beginning for the last output note
+ section with equal or larger alignments. NB: Don't
+ place orphan note section after non-note sections. */
+
+ first_orphan_note = NULL;
+
+ /* NB: When --rosegment is used, the .note.gnu.build-id
+ section is placed before text sections. Ignore the
+ .note.gnu.build-id section if -z separate-code and
+ --rosegment are used together to avoid putting any
+ note sections between the .note.gnu.build-id section
+ and text sections in the same PT_LOAD segment. */
+ bool ignore_build_id = (link_info.separate_code
+ && link_info.one_rosegment);
+
+ for (sec = link_info.output_bfd->sections;
+ (sec != NULL
+ && !bfd_is_abs_section (sec));
+ sec = sec->next)
+ if (sec != snew
+ && elf_section_type (sec) == SHT_NOTE
+ && (sec->flags & SEC_LOAD) != 0
+ && (!ignore_build_id
+ || strcmp (sec->name, ".note.gnu.build-id") != 0))
+ {
+ if (!first_orphan_note)
+ first_orphan_note = sec;
+ if (sec->alignment_power >= s->alignment_power)
+ after_sec = sec;
+ }
+ else if (first_orphan_note)
+ {
+ /* Stop if there is non-note section after the first
+ orphan note section. */
+ break;
+ }
+
+ /* If this will be the first orphan note section, it can
+ be placed at the default location. */
+ after_sec_note = first_orphan_note != NULL;
+ if (after_sec == NULL && after_sec_note)
+ {
+ /* If all output note sections have smaller
+ alignments, place the section before all
+ output orphan note sections. */
+ after_sec = first_orphan_note;
+ insert_after = false;
+ }
+ }
+ else if (first_orphan_note)
+ {
+ /* Don't place non-note sections in the middle of orphan
+ note sections. */
+ after_sec_note = true;
+ after_sec = as;
+ for (sec = as->next;
+ (sec != NULL
+ && !bfd_is_abs_section (sec));
+ sec = sec->next)
+ if (elf_section_type (sec) == SHT_NOTE
+ && (sec->flags & SEC_LOAD) != 0)
+ after_sec = sec;
+ }
+
+ if (after_sec_note)
+ {
+ if (after_sec)
+ {
+ /* Search forward to insert OS after AFTER_SEC output
+ statement. */
+ lang_output_section_statement_type *stmt, *next;
+ bool found = false;
+ for (stmt = after; stmt != NULL; stmt = next)
+ {
+ next = stmt->next;
+ if (insert_after)
+ {
+ if (stmt->bfd_section == after_sec)
+ {
+ place_after = true;
+ found = true;
+ after = stmt;
+ break;
+ }
+ }
+ else
+ {
+ /* If INSERT_AFTER is FALSE, place OS before
+ AFTER_SEC output statement. */
+ if (next && next->bfd_section == after_sec)
+ {
+ place_after = true;
+ found = true;
+ after = stmt;
+ break;
+ }
+ }
+ }
+
+ /* Search backward to insert OS after AFTER_SEC output
+ statement. */
+ if (!found)
+ for (stmt = after; stmt != NULL; stmt = stmt->prev)
+ {
+ if (insert_after)
+ {
+ if (stmt->bfd_section == after_sec)
+ {
+ place_after = true;
+ after = stmt;
+ break;
+ }
+ }
+ else
+ {
+ /* If INSERT_AFTER is FALSE, place OS before
+ AFTER_SEC output statement. */
+ if (stmt->next->bfd_section == after_sec)
+ {
+ place_after = true;
+ after = stmt;
+ break;
+ }
+ }
+ }
+ }
+
+ if (after_sec == NULL
+ || (insert_after && after_sec->next != snew)
+ || (!insert_after && after_sec->prev != snew))
+ {
+ /* Unlink the section. */
+ bfd_section_list_remove (link_info.output_bfd, snew);
+
+ /* Place SNEW after AFTER_SEC. If AFTER_SEC is NULL,
+ prepend SNEW. */
+ if (after_sec)
+ {
+ if (insert_after)
+ bfd_section_list_insert_after (link_info.output_bfd,
+ after_sec, snew);
+ else
+ bfd_section_list_insert_before (link_info.output_bfd,
+ after_sec, snew);
+ }
+ else
+ bfd_section_list_prepend (link_info.output_bfd, snew);
+ }
+ }
+ else if (as != snew && as->prev != snew)
+ {
+ /* Unlink the section. */
+ bfd_section_list_remove (link_info.output_bfd, snew);
+
+ /* Now tack it back on in the right place. */
+ bfd_section_list_insert_before (link_info.output_bfd,
+ as, snew);
+ }
+ }
+ else if (as != snew && as->prev != snew)
+ {
+ /* Unlink the section. */
+ bfd_section_list_remove (link_info.output_bfd, snew);
+
+ /* Now tack it back on in the right place. */
+ bfd_section_list_insert_before (link_info.output_bfd, as, snew);
+ }
+
+ /* Save the end of this list. Further ophans of this type will
+ follow the one we've just added. */
+ place->section = &snew->next;
+
+ /* The following is non-cosmetic. We try to put the output
+ statements in some sort of reasonable order here, because they
+ determine the final load addresses of the orphan sections.
+ In addition, placing output statements in the wrong order may
+ require extra segments. For instance, given a typical
+ situation of all read-only sections placed in one segment and
+ following that a segment containing all the read-write
+ sections, we wouldn't want to place an orphan read/write
+ section before or amongst the read-only ones. */
+ if (add.head != NULL)
+ {
+ lang_output_section_statement_type *newly_added_os;
+
+ /* Place OS after AFTER if AFTER_NOTE is TRUE. */
+ if (place_after)
+ {
+ lang_statement_union_type **where;
+
+ where = insert_os_after ((lang_statement_union_type *) after);
+ *add.tail = *where;
+ *where = add.head;
+
+ place->os_tail = &after->next;
+ }
+ else
+ {
+ /* Put it after the last orphan statement we added. */
+ *add.tail = *place->stmt;
+ *place->stmt = add.head;
+ }
+
+ /* Fix the global list pointer if we happened to tack our
+ new list at the tail. */
+ if (*stat_ptr->tail == add.head)
+ stat_ptr->tail = add.tail;
+
+ /* Save the end of this list. */
+ place->stmt = add.tail;
+
+ /* Do the same for the list of output section statements. */
+ newly_added_os = *os_tail;
+ *os_tail = NULL;
+ newly_added_os->prev = (lang_output_section_statement_type *)
+ ((char *) place->os_tail
+ - offsetof (lang_output_section_statement_type, next));
+ newly_added_os->next = *place->os_tail;
+ if (newly_added_os->next != NULL)
+ newly_added_os->next->prev = newly_added_os;
+ *place->os_tail = newly_added_os;
+ place->os_tail = &newly_added_os->next;
+
+ /* Fixing the global list pointer here is a little different.
+ We added to the list in lang_enter_output_section_statement,
+ trimmed off the new output_section_statment above when
+ assigning *os_tail = NULL, but possibly added it back in
+ the same place when assigning *place->os_tail. */
+ if (*os_tail == NULL)
+ lang_os_list.tail = (lang_statement_union_type **) os_tail;
+ }
+ }
+ return os;
+}
+
+static void
+lang_print_asneeded (void)
+{
+ struct asneeded_minfo *m;
+
+ if (asneeded_list_head == NULL)
+ return;
+
+ minfo (_("\nAs-needed library included to satisfy reference by file (symbol)\n\n"));
+
+ for (m = asneeded_list_head; m != NULL; m = m->next)
+ {
+ int len;
+
+ minfo ("%s", m->soname);
+ len = strlen (m->soname);
+
+ if (len >= 29)
+ {
+ print_nl ();
+ len = 0;
+ }
+ print_spaces (30 - len);
+
+ if (m->ref != NULL)
+ minfo ("%pB ", m->ref);
+ minfo ("(%pT)\n", m->name);
+ }
+}
+
+static void
+lang_map_flags (flagword flag)
+{
+ if (flag & SEC_ALLOC)
+ minfo ("a");
+
+ if (flag & SEC_CODE)
+ minfo ("x");
+
+ if (flag & SEC_READONLY)
+ minfo ("r");
+
+ if (flag & SEC_DATA)
+ minfo ("w");
+
+ if (flag & SEC_LOAD)
+ minfo ("l");
+}
+
+void
+lang_map (void)
+{
+ lang_memory_region_type *m;
+ bool dis_header_printed = false;
+
+ ldfile_print_input_remaps ();
+
+ LANG_FOR_EACH_INPUT_STATEMENT (file)
+ {
+ asection *s;
+
+ if ((file->the_bfd->flags & (BFD_LINKER_CREATED | DYNAMIC)) != 0
+ || file->flags.just_syms)
+ continue;
+
+ if (config.print_map_discarded)
+ for (s = file->the_bfd->sections; s != NULL; s = s->next)
+ if ((s->output_section == NULL
+ || s->output_section->owner != link_info.output_bfd)
+ && (s->flags & (SEC_LINKER_CREATED | SEC_KEEP)) == 0)
+ {
+ if (! dis_header_printed)
+ {
+ minfo (_("\nDiscarded input sections\n\n"));
+ dis_header_printed = true;
+ }
+
+ print_input_section (s, true);
+ }
+ }
+ if (config.print_map_discarded && ! dis_header_printed)
+ minfo (_("\nThere are no discarded input sections\n"));
+
+ minfo (_("\nMemory Configuration\n\n"));
+ fprintf (config.map_file, "%-16s %-18s %-18s %s\n",
+ _("Name"), _("Origin"), _("Length"), _("Attributes"));
+
+ for (m = lang_memory_region_list; m != NULL; m = m->next)
+ {
+ fprintf (config.map_file, "%-16s", m->name_list.name);
+
+ char buf[32];
+ bfd_sprintf_vma (link_info.output_bfd, buf, m->origin);
+ fprintf (config.map_file, " 0x%-16s", buf);
+ bfd_sprintf_vma (link_info.output_bfd, buf, m->length);
+ fprintf (config.map_file,
+ " 0x%*s", m->flags || m->not_flags ? -17 : 0, buf);
+ if (m->flags)
+ lang_map_flags (m->flags);
+
+ if (m->not_flags)
+ {
+ minfo ("!");
+ lang_map_flags (m->not_flags);
+ }
+
+ print_nl ();
+ }
+
+ minfo (_("\nLinker script and memory map\n\n"));
+
+ if (!link_info.reduce_memory_overheads)
+ {
+ obstack_begin (&map_obstack, 1000);
+ bfd_link_hash_traverse (link_info.hash, sort_def_symbol, 0);
+ }
+ expld.phase = lang_fixed_phase_enum;
+ lang_statement_iteration++;
+ print_statements ();
+
+ ldemul_extra_map_file_text (link_info.output_bfd, &link_info,
+ config.map_file);
+}
+
+static bool
+sort_def_symbol (struct bfd_link_hash_entry *hash_entry,
+ void *info ATTRIBUTE_UNUSED)
+{
+ if ((hash_entry->type == bfd_link_hash_defined
+ || hash_entry->type == bfd_link_hash_defweak)
+ && hash_entry->u.def.section->owner != link_info.output_bfd
+ && hash_entry->u.def.section->owner != NULL)
+ {
+ input_section_userdata_type *ud;
+ struct map_symbol_def *def;
+
+ ud = bfd_section_userdata (hash_entry->u.def.section);
+ if (!ud)
+ {
+ ud = stat_alloc (sizeof (*ud));
+ bfd_set_section_userdata (hash_entry->u.def.section, ud);
+ ud->map_symbol_def_tail = &ud->map_symbol_def_head;
+ ud->map_symbol_def_count = 0;
+ }
+ else if (!ud->map_symbol_def_tail)
+ ud->map_symbol_def_tail = &ud->map_symbol_def_head;
+
+ def = (struct map_symbol_def *) obstack_alloc (&map_obstack, sizeof *def);
+ def->entry = hash_entry;
+ *(ud->map_symbol_def_tail) = def;
+ ud->map_symbol_def_tail = &def->next;
+ ud->map_symbol_def_count++;
+ }
+ return true;
+}
+
+/* Initialize an output section. */
+
+static void
+init_os (lang_output_section_statement_type *s, flagword flags)
+{
+ if (strcmp (s->name, DISCARD_SECTION_NAME) == 0)
+ einfo (_("%F%P: illegal use of `%s' section\n"), DISCARD_SECTION_NAME);
+
+ if (!s->dup_output)
+ s->bfd_section = bfd_get_section_by_name (link_info.output_bfd, s->name);
+ if (s->bfd_section == NULL)
+ s->bfd_section = bfd_make_section_anyway_with_flags (link_info.output_bfd,
+ s->name, flags);
+ if (s->bfd_section == NULL)
+ {
+ einfo (_("%F%P: output format %s cannot represent section"
+ " called %s: %E\n"),
+ link_info.output_bfd->xvec->name, s->name);
+ }
+ s->bfd_section->output_section = s->bfd_section;
+ s->bfd_section->output_offset = 0;
+
+ /* Set the userdata of the output section to the output section
+ statement to avoid lookup. */
+ bfd_set_section_userdata (s->bfd_section, s);
+
+ /* If there is a base address, make sure that any sections it might
+ mention are initialized. */
+ if (s->addr_tree != NULL)
+ exp_init_os (s->addr_tree);
+
+ if (s->load_base != NULL)
+ exp_init_os (s->load_base);
+
+ /* If supplied an alignment, set it. */
+ if (s->section_alignment != NULL)
+ s->bfd_section->alignment_power = exp_get_power (s->section_alignment, s,
+ "section alignment");
+}
+
+static flagword
+get_os_init_flag (lang_output_section_statement_type * os)
+{
+ if (os != NULL)
+ switch (os->sectype)
+ {
+ case readonly_section: return SEC_READONLY;
+ case noload_section: return SEC_NEVER_LOAD;
+ default: break;
+ }
+
+ return 0;
+}
+
+/* Make sure that all output sections mentioned in an expression are
+ initialized. */
+
+static void
+exp_init_os (etree_type *exp)
+{
+ switch (exp->type.node_class)
+ {
+ case etree_assign:
+ case etree_provide:
+ case etree_provided:
+ exp_init_os (exp->assign.src);
+ break;
+
+ case etree_binary:
+ exp_init_os (exp->binary.lhs);
+ exp_init_os (exp->binary.rhs);
+ break;
+
+ case etree_trinary:
+ exp_init_os (exp->trinary.cond);
+ exp_init_os (exp->trinary.lhs);
+ exp_init_os (exp->trinary.rhs);
+ break;
+
+ case etree_assert:
+ exp_init_os (exp->assert_s.child);
+ break;
+
+ case etree_unary:
+ exp_init_os (exp->unary.child);
+ break;
+
+ case etree_name:
+ switch (exp->type.node_code)
+ {
+ case ADDR:
+ case LOADADDR:
+ {
+ lang_output_section_statement_type *os;
+
+ os = lang_output_section_find (exp->name.name);
+ if (os != NULL && os->bfd_section == NULL)
+ init_os (os, get_os_init_flag (os));
+ }
+ }
+ break;
+
+ default:
+ break;
+ }
+}
+
+static void
+section_already_linked (bfd *abfd, asection *sec, void *data)
+{
+ lang_input_statement_type *entry = (lang_input_statement_type *) data;
+
+ /* If we are only reading symbols from this object, then we want to
+ discard all sections. */
+ if (entry->flags.just_syms)
+ {
+ bfd_link_just_syms (abfd, sec, &link_info);
+ return;
+ }
+
+ /* Deal with SHF_EXCLUDE ELF sections. */
+ if (!bfd_link_relocatable (&link_info)
+ && (abfd->flags & BFD_PLUGIN) == 0
+ && (sec->flags & (SEC_GROUP | SEC_KEEP | SEC_EXCLUDE)) == SEC_EXCLUDE)
+ sec->output_section = bfd_abs_section_ptr;
+
+ if (!(abfd->flags & DYNAMIC))
+ bfd_section_already_linked (abfd, sec, &link_info);
+}
+
+
+/* Returns true if SECTION is one we know will be discarded based on its
+ section flags, otherwise returns false. */
+
+static bool
+lang_discard_section_p (asection *section)
+{
+ bool discard;
+ flagword flags = section->flags;
+
+ /* Discard sections marked with SEC_EXCLUDE. */
+ discard = (flags & SEC_EXCLUDE) != 0;
+
+ /* Discard the group descriptor sections when we're finally placing the
+ sections from within the group. */
+ if ((flags & SEC_GROUP) != 0
+ && link_info.resolve_section_groups)
+ discard = true;
+
+ /* Discard debugging sections if we are stripping debugging
+ information. */
+ if ((link_info.strip == strip_debugger || link_info.strip == strip_all)
+ && (flags & SEC_DEBUGGING) != 0)
+ discard = true;
+
+ /* Discard non-alloc sections if we are stripping section headers. */
+ else if (config.no_section_header && (flags & SEC_ALLOC) == 0)
+ discard = true;
+
+ return discard;
+}
+
+/* Return TRUE if SECTION is never going to be added to output statement
+ OUTPUT. lang_add_section() definitely won't do anything with SECTION
+ if this returns TRUE. It may do something (or not) if this returns FALSE.
+
+ Can be used as early-out to filter matches. This may set
+ output_section of SECTION, if it was unset, to the abs section in case
+ we discover SECTION to be always discarded. This may also give
+ warning messages. */
+
+static bool
+wont_add_section_p (asection *section,
+ lang_output_section_statement_type *output)
+{
+ bool discard;
+
+ /* Is this section one we know should be discarded? */
+ discard = lang_discard_section_p (section);
+
+ /* Discard input sections which are assigned to a section named
+ DISCARD_SECTION_NAME. */
+ if (strcmp (output->name, DISCARD_SECTION_NAME) == 0)
+ discard = true;
+
+ if (discard)
+ {
+ if (section->output_section == NULL)
+ {
+ /* This prevents future calls from assigning this section or
+ warning about it again. */
+ section->output_section = bfd_abs_section_ptr;
+ }
+ else if (bfd_is_abs_section (section->output_section))
+ ;
+ else if (link_info.non_contiguous_regions_warnings)
+ einfo (_("%P:%pS: warning: --enable-non-contiguous-regions makes "
+ "section `%pA' from `%pB' match /DISCARD/ clause.\n"),
+ NULL, section, section->owner);
+
+ return true;
+ }
+
+ if (section->output_section != NULL)
+ {
+ if (!link_info.non_contiguous_regions)
+ return true;
+
+ /* SECTION has already been handled in a special way
+ (eg. LINK_ONCE): skip it. */
+ if (bfd_is_abs_section (section->output_section))
+ return true;
+
+ /* Already assigned to the same output section, do not process
+ it again, to avoid creating loops between duplicate sections
+ later. */
+ if (section->output_section == output->bfd_section)
+ return true;
+
+ if (link_info.non_contiguous_regions_warnings && output->bfd_section)
+ einfo (_("%P:%pS: warning: --enable-non-contiguous-regions may "
+ "change behaviour for section `%pA' from `%pB' (assigned to "
+ "%pA, but additional match: %pA)\n"),
+ NULL, section, section->owner, section->output_section,
+ output->bfd_section);
+
+ /* SECTION has already been assigned to an output section, but
+ the user allows it to be mapped to another one in case it
+ overflows. We'll later update the actual output section in
+ size_input_section as appropriate. */
+ }
+
+ return false;
+}
+
+/* The wild routines.
+
+ These expand statements like *(.text) and foo.o to a list of
+ explicit actions, like foo.o(.text), bar.o(.text) and
+ foo.o(.text, .data). */
+
+/* Add SECTION to the output section OUTPUT. Do this by creating a
+ lang_input_section statement which is placed at PTR. */
+
+void
+lang_add_section (lang_statement_list_type *ptr,
+ asection *section,
+ struct wildcard_list *pattern,
+ struct flag_info *sflag_info,
+ lang_output_section_statement_type *output)
+{
+ flagword flags = section->flags;
+
+ lang_input_section_type *new_section;
+ bfd *abfd = link_info.output_bfd;
+
+ if (wont_add_section_p (section, output))
+ return;
+
+ if (sflag_info)
+ {
+ bool keep;
+
+ keep = bfd_lookup_section_flags (&link_info, sflag_info, section);
+ if (!keep)
+ return;
+ }
+
+ /* We don't copy the SEC_NEVER_LOAD flag from an input section
+ to an output section, because we want to be able to include a
+ SEC_NEVER_LOAD section in the middle of an otherwise loaded
+ section (I don't know why we want to do this, but we do).
+ build_link_order in ldwrite.c handles this case by turning
+ the embedded SEC_NEVER_LOAD section into a fill. */
+ flags &= ~ SEC_NEVER_LOAD;
+
+ /* If final link, don't copy the SEC_LINK_ONCE flags, they've
+ already been processed. One reason to do this is that on pe
+ format targets, .text$foo sections go into .text and it's odd
+ to see .text with SEC_LINK_ONCE set. */
+ if ((flags & (SEC_LINK_ONCE | SEC_GROUP)) == (SEC_LINK_ONCE | SEC_GROUP))
+ {
+ if (link_info.resolve_section_groups)
+ flags &= ~(SEC_LINK_ONCE | SEC_LINK_DUPLICATES | SEC_RELOC);
+ else
+ flags &= ~(SEC_LINK_DUPLICATES | SEC_RELOC);
+ }
+ else if (!bfd_link_relocatable (&link_info))
+ flags &= ~(SEC_LINK_ONCE | SEC_LINK_DUPLICATES | SEC_RELOC);
+
+ switch (output->sectype)
+ {
+ case normal_section:
+ case overlay_section:
+ case first_overlay_section:
+ case type_section:
+ break;
+ case noalloc_section:
+ flags &= ~SEC_ALLOC;
+ break;
+ case typed_readonly_section:
+ case readonly_section:
+ flags |= SEC_READONLY;
+ break;
+ case noload_section:
+ flags &= ~SEC_LOAD;
+ flags |= SEC_NEVER_LOAD;
+ /* Unfortunately GNU ld has managed to evolve two different
+ meanings to NOLOAD in scripts. ELF gets a .bss style noload,
+ alloc, no contents section. All others get a noload, noalloc
+ section. */
+ if (bfd_get_flavour (link_info.output_bfd) == bfd_target_elf_flavour)
+ flags &= ~SEC_HAS_CONTENTS;
+ else
+ flags &= ~SEC_ALLOC;
+ break;
+ }
+
+ if (output->bfd_section == NULL)
+ init_os (output, flags);
+
+ /* If SEC_READONLY is not set in the input section, then clear
+ it from the output section. */
+ output->bfd_section->flags &= flags | ~SEC_READONLY;
+
+ if (output->bfd_section->linker_has_input)
+ {
+ /* Only set SEC_READONLY flag on the first input section. */
+ flags &= ~ SEC_READONLY;
+
+ /* Keep SEC_MERGE and SEC_STRINGS only if they are the same. */
+ if ((output->bfd_section->flags & (SEC_MERGE | SEC_STRINGS))
+ != (flags & (SEC_MERGE | SEC_STRINGS))
+ || ((flags & SEC_MERGE) != 0
+ && output->bfd_section->entsize != section->entsize))
+ {
+ output->bfd_section->flags &= ~ (SEC_MERGE | SEC_STRINGS);
+ flags &= ~ (SEC_MERGE | SEC_STRINGS);
+ }
+ }
+ output->bfd_section->flags |= flags;
+
+ if (!output->bfd_section->linker_has_input)
+ {
+ output->bfd_section->linker_has_input = 1;
+ /* This must happen after flags have been updated. The output
+ section may have been created before we saw its first input
+ section, eg. for a data statement. */
+ bfd_init_private_section_data (section->owner, section,
+ link_info.output_bfd,
+ output->bfd_section,
+ &link_info);
+ if ((flags & SEC_MERGE) != 0)
+ output->bfd_section->entsize = section->entsize;
+ }
+
+ if ((flags & SEC_TIC54X_BLOCK) != 0
+ && bfd_get_arch (section->owner) == bfd_arch_tic54x)
+ {
+ /* FIXME: This value should really be obtained from the bfd... */
+ output->block_value = 128;
+ }
+
+ /* When a .ctors section is placed in .init_array it must be copied
+ in reverse order. Similarly for .dtors. Set that up. */
+ if (bfd_get_flavour (link_info.output_bfd) == bfd_target_elf_flavour
+ && ((startswith (section->name, ".ctors")
+ && strcmp (output->bfd_section->name, ".init_array") == 0)
+ || (startswith (section->name, ".dtors")
+ && strcmp (output->bfd_section->name, ".fini_array") == 0))
+ && (section->name[6] == 0 || section->name[6] == '.'))
+ section->flags |= SEC_ELF_REVERSE_COPY;
+
+ if (section->alignment_power > output->bfd_section->alignment_power)
+ output->bfd_section->alignment_power = section->alignment_power;
+
+ section->output_section = output->bfd_section;
+
+ if (!map_head_is_link_order)
+ {
+ asection *s = output->bfd_section->map_tail.s;
+ output->bfd_section->map_tail.s = section;
+ section->map_head.s = NULL;
+ section->map_tail.s = s;
+ if (s != NULL)
+ s->map_head.s = section;
+ else
+ output->bfd_section->map_head.s = section;
+ }
+
+ /* Add a section reference to the list. */
+ new_section = new_stat (lang_input_section, ptr);
+ new_section->section = section;
+ new_section->pattern = pattern;
+}
+
+/* Expand a wild statement for a particular FILE. SECTION may be
+ NULL, in which case it is a wild card. This assumes that the
+ wild statement doesn't need any sorting (of filenames or sections). */
+
+static void
+output_section_callback_nosort (lang_wild_statement_type *ptr,
+ struct wildcard_list *sec ATTRIBUTE_UNUSED,
+ asection *section,
+ lang_input_statement_type *file ATTRIBUTE_UNUSED,
+ void *output)
+{
+ lang_output_section_statement_type *os;
+
+ os = (lang_output_section_statement_type *) output;
+
+ /* Exclude sections that match UNIQUE_SECTION_LIST. */
+ if (unique_section_p (section, os))
+ return;
+
+ lang_add_section (&ptr->children, section, ptr->section_list,
+ ptr->section_flag_list, os);
+}
+
+/* Check if all sections in a wild statement for a particular FILE
+ are readonly. */
+
+static void
+check_section_callback (lang_wild_statement_type *ptr ATTRIBUTE_UNUSED,
+ struct wildcard_list *sec ATTRIBUTE_UNUSED,
+ asection *section,
+ lang_input_statement_type *file ATTRIBUTE_UNUSED,
+ void *output)
+{
+ lang_output_section_statement_type *os;
+
+ os = (lang_output_section_statement_type *) output;
+
+ /* Exclude sections that match UNIQUE_SECTION_LIST. */
+ if (unique_section_p (section, os))
+ return;
+
+ if (section->output_section == NULL && (section->flags & SEC_READONLY) == 0)
+ os->all_input_readonly = false;
+}
+
+/* This is passed a file name which must have been seen already and
+ added to the statement tree. We will see if it has been opened
+ already and had its symbols read. If not then we'll read it. */
+
+static lang_input_statement_type *
+lookup_name (const char *name)
+{
+ lang_input_statement_type *search;
+
+ for (search = (void *) input_file_chain.head;
+ search != NULL;
+ search = search->next_real_file)
+ {
+ /* Use the local_sym_name as the name of the file that has
+ already been loaded as filename might have been transformed
+ via the search directory lookup mechanism. */
+ const char *filename = search->local_sym_name;
+
+ if (filename != NULL
+ && filename_cmp (filename, name) == 0)
+ break;
+ }
+
+ if (search == NULL)
+ {
+ /* Arrange to splice the input statement added by new_afile into
+ statement_list after the current input_file_chain tail.
+ We know input_file_chain is not an empty list, and that
+ lookup_name was called via open_input_bfds. Later calls to
+ lookup_name should always match an existing input_statement. */
+ lang_statement_union_type **tail = stat_ptr->tail;
+ lang_statement_union_type **after
+ = (void *) ((char *) input_file_chain.tail
+ - offsetof (lang_input_statement_type, next_real_file)
+ + offsetof (lang_input_statement_type, header.next));
+ lang_statement_union_type *rest = *after;
+ stat_ptr->tail = after;
+ search = new_afile (name, lang_input_file_is_search_file_enum,
+ default_target, NULL);
+ *stat_ptr->tail = rest;
+ if (*tail == NULL)
+ stat_ptr->tail = tail;
+ }
+
+ /* If we have already added this file, or this file is not real
+ don't add this file. */
+ if (search->flags.loaded || !search->flags.real)
+ return search;
+
+ if (!load_symbols (search, NULL))
+ return NULL;
+
+ return search;
+}
+
+/* Save LIST as a list of libraries whose symbols should not be exported. */
+
+struct excluded_lib
+{
+ char *name;
+ struct excluded_lib *next;
+};
+static struct excluded_lib *excluded_libs;
+
+void
+add_excluded_libs (const char *list)
+{
+ const char *p = list, *end;
+
+ while (*p != '\0')
+ {
+ struct excluded_lib *entry;
+ end = strpbrk (p, ",:");
+ if (end == NULL)
+ end = p + strlen (p);
+ entry = (struct excluded_lib *) xmalloc (sizeof (*entry));
+ entry->next = excluded_libs;
+ entry->name = (char *) xmalloc (end - p + 1);
+ memcpy (entry->name, p, end - p);
+ entry->name[end - p] = '\0';
+ excluded_libs = entry;
+ if (*end == '\0')
+ break;
+ p = end + 1;
+ }
+}
+
+static void
+check_excluded_libs (bfd *abfd)
+{
+ struct excluded_lib *lib = excluded_libs;
+
+ while (lib)
+ {
+ int len = strlen (lib->name);
+ const char *filename = lbasename (bfd_get_filename (abfd));
+
+ if (strcmp (lib->name, "ALL") == 0)
+ {
+ abfd->no_export = true;
+ return;
+ }
+
+ if (filename_ncmp (lib->name, filename, len) == 0
+ && (filename[len] == '\0'
+ || (filename[len] == '.' && filename[len + 1] == 'a'
+ && filename[len + 2] == '\0')))
+ {
+ abfd->no_export = true;
+ return;
+ }
+
+ lib = lib->next;
+ }
+}
+
+/* Get the symbols for an input file. */
+
+bool
+load_symbols (lang_input_statement_type *entry,
+ lang_statement_list_type *place)
+{
+ char **matching;
+
+ if (entry->flags.loaded)
+ return true;
+
+ ldfile_open_file (entry);
+
+ /* Do not process further if the file was missing. */
+ if (entry->flags.missing_file)
+ return true;
+
+ if (trace_files || verbose)
+ info_msg ("%pI\n", entry);
+
+ if (!bfd_check_format (entry->the_bfd, bfd_archive)
+ && !bfd_check_format_matches (entry->the_bfd, bfd_object, &matching))
+ {
+ bfd_error_type err;
+ struct lang_input_statement_flags save_flags;
+ extern FILE *yyin;
+
+ err = bfd_get_error ();
+
+ /* See if the emulation has some special knowledge. */
+ if (ldemul_unrecognized_file (entry))
+ {
+ if (err == bfd_error_file_ambiguously_recognized)
+ free (matching);
+ return true;
+ }
+
+ if (err == bfd_error_file_ambiguously_recognized)
+ {
+ char **p;
+
+ einfo (_("%P: %pB: file not recognized: %E;"
+ " matching formats:"), entry->the_bfd);
+ for (p = matching; *p != NULL; p++)
+ einfo (" %s", *p);
+ free (matching);
+ einfo ("%F\n");
+ }
+ else if (err != bfd_error_file_not_recognized
+ || place == NULL)
+ einfo (_("%F%P: %pB: file not recognized: %E\n"), entry->the_bfd);
+
+ bfd_close (entry->the_bfd);
+ entry->the_bfd = NULL;
+
+ /* Try to interpret the file as a linker script. */
+ save_flags = input_flags;
+ ldfile_open_command_file (entry->filename);
+
+ push_stat_ptr (place);
+ input_flags.add_DT_NEEDED_for_regular
+ = entry->flags.add_DT_NEEDED_for_regular;
+ input_flags.add_DT_NEEDED_for_dynamic
+ = entry->flags.add_DT_NEEDED_for_dynamic;
+ input_flags.whole_archive = entry->flags.whole_archive;
+ input_flags.dynamic = entry->flags.dynamic;
+
+ ldfile_assumed_script = true;
+ parser_input = input_script;
+ current_input_file = entry->filename;
+ yyparse ();
+ current_input_file = NULL;
+ ldfile_assumed_script = false;
+
+ /* missing_file is sticky. sysrooted will already have been
+ restored when seeing EOF in yyparse, but no harm to restore
+ again. */
+ save_flags.missing_file |= input_flags.missing_file;
+ input_flags = save_flags;
+ pop_stat_ptr ();
+ fclose (yyin);
+ yyin = NULL;
+ entry->flags.loaded = true;
+
+ return true;
+ }
+
+ if (ldemul_recognized_file (entry))
+ return true;
+
+ /* We don't call ldlang_add_file for an archive. Instead, the
+ add_symbols entry point will call ldlang_add_file, via the
+ add_archive_element callback, for each element of the archive
+ which is used. */
+ switch (bfd_get_format (entry->the_bfd))
+ {
+ default:
+ break;
+
+ case bfd_object:
+ if (!entry->flags.reload)
+ ldlang_add_file (entry);
+ break;
+
+ case bfd_archive:
+ check_excluded_libs (entry->the_bfd);
+
+ bfd_set_usrdata (entry->the_bfd, entry);
+ if (entry->flags.whole_archive)
+ {
+ bfd *member = NULL;
+ bool loaded = true;
+
+ for (;;)
+ {
+ bfd *subsbfd;
+ member = bfd_openr_next_archived_file (entry->the_bfd, member);
+
+ if (member == NULL)
+ break;
+
+ if (!bfd_check_format (member, bfd_object))
+ {
+ einfo (_("%F%P: %pB: member %pB in archive is not an object\n"),
+ entry->the_bfd, member);
+ loaded = false;
+ }
+
+ if (config.emitting_gnu_object_only)
+ {
+ if (!cmdline_on_object_only_archive_list_p (member))
+ continue;
+ }
+
+ subsbfd = member;
+ if (!(*link_info.callbacks
+ ->add_archive_element) (&link_info, member,
+ "--whole-archive", &subsbfd))
+ abort ();
+
+ /* Potentially, the add_archive_element hook may have set a
+ substitute BFD for us. */
+ if (!bfd_link_add_symbols (subsbfd, &link_info))
+ {
+ einfo (_("%F%P: %pB: error adding symbols: %E\n"), member);
+ loaded = false;
+ }
+ }
+
+ entry->flags.loaded = loaded;
+ return loaded;
+ }
+ break;
+ }
+
+ if (bfd_link_add_symbols (entry->the_bfd, &link_info))
+ entry->flags.loaded = true;
+ else
+ einfo (_("%F%P: %pB: error adding symbols: %E\n"), entry->the_bfd);
+
+ return entry->flags.loaded;
+}
+
+/* Handle a wild statement. S->FILENAME or S->SECTION_LIST or both
+ may be NULL, indicating that it is a wildcard. Separate
+ lang_input_section statements are created for each part of the
+ expansion; they are added after the wild statement S. OUTPUT is
+ the output section. */
+
+static void
+wild (lang_wild_statement_type *s,
+ const char *target ATTRIBUTE_UNUSED,
+ lang_output_section_statement_type *output)
+{
+ struct wildcard_list *sec;
+
+ if (s->filenames_sorted || s->any_specs_sorted)
+ {
+ lang_section_bst_type *tree;
+
+ walk_wild (s, output_section_callback_sort, output);
+
+ tree = s->tree;
+ if (tree)
+ {
+ output_section_callback_tree_to_list (s, tree, output);
+ s->tree = NULL;
+ s->rightmost = &s->tree;
+ }
+ }
+ else
+ walk_wild (s, output_section_callback_nosort, output);
+
+ if (default_common_section == NULL)
+ for (sec = s->section_list; sec != NULL; sec = sec->next)
+ if (sec->spec.name != NULL && strcmp (sec->spec.name, "COMMON") == 0)
+ {
+ /* Remember the section that common is going to in case we
+ later get something which doesn't know where to put it. */
+ default_common_section = output;
+ break;
+ }
+}
+
+/* Return TRUE iff target is the sought target. */
+
+static int
+get_target (const bfd_target *target, void *data)
+{
+ const char *sought = (const char *) data;
+
+ return strcmp (target->name, sought) == 0;
+}
+
+/* Like strcpy() but convert to lower case as well. */
+
+static void
+stricpy (char *dest, const char *src)
+{
+ char c;
+
+ while ((c = *src++) != 0)
+ *dest++ = TOLOWER (c);
+
+ *dest = 0;
+}
+
+/* Remove the first occurrence of needle (if any) in haystack
+ from haystack. */
+
+static void
+strcut (char *haystack, const char *needle)
+{
+ haystack = strstr (haystack, needle);
+
+ if (haystack)
+ {
+ char *src;
+
+ for (src = haystack + strlen (needle); *src;)
+ *haystack++ = *src++;
+
+ *haystack = 0;
+ }
+}
+
+/* Compare two target format name strings.
+ Return a value indicating how "similar" they are. */
+
+static int
+name_compare (const char *first, const char *second)
+{
+ char *copy1;
+ char *copy2;
+ int result;
+
+ copy1 = (char *) xmalloc (strlen (first) + 1);
+ copy2 = (char *) xmalloc (strlen (second) + 1);
+
+ /* Convert the names to lower case. */
+ stricpy (copy1, first);
+ stricpy (copy2, second);
+
+ /* Remove size and endian strings from the name. */
+ strcut (copy1, "big");
+ strcut (copy1, "little");
+ strcut (copy2, "big");
+ strcut (copy2, "little");
+
+ /* Return a value based on how many characters match,
+ starting from the beginning. If both strings are
+ the same then return 10 * their length. */
+ for (result = 0; copy1[result] == copy2[result]; result++)
+ if (copy1[result] == 0)
+ {
+ result *= 10;
+ break;
+ }
+
+ free (copy1);
+ free (copy2);
+
+ return result;
+}
+
+/* Set by closest_target_match() below. */
+static const bfd_target *winner;
+
+/* Scan all the valid bfd targets looking for one that has the endianness
+ requirement that was specified on the command line, and is the nearest
+ match to the original output target. */
+
+static int
+closest_target_match (const bfd_target *target, void *data)
+{
+ const bfd_target *original = (const bfd_target *) data;
+
+ if (command_line.endian == ENDIAN_BIG
+ && target->byteorder != BFD_ENDIAN_BIG)
+ return 0;
+
+ if (command_line.endian == ENDIAN_LITTLE
+ && target->byteorder != BFD_ENDIAN_LITTLE)
+ return 0;
+
+ /* Must be the same flavour. */
+ if (target->flavour != original->flavour)
+ return 0;
+
+ /* Ignore generic big and little endian elf vectors. */
+ if (strcmp (target->name, "elf32-big") == 0
+ || strcmp (target->name, "elf64-big") == 0
+ || strcmp (target->name, "elf32-little") == 0
+ || strcmp (target->name, "elf64-little") == 0)
+ return 0;
+
+ /* If we have not found a potential winner yet, then record this one. */
+ if (winner == NULL)
+ {
+ winner = target;
+ return 0;
+ }
+
+ /* Oh dear, we now have two potential candidates for a successful match.
+ Compare their names and choose the better one. */
+ if (name_compare (target->name, original->name)
+ > name_compare (winner->name, original->name))
+ winner = target;
+
+ /* Keep on searching until wqe have checked them all. */
+ return 0;
+}
+
+/* Return the BFD target format of the first input file. */
+
+static const char *
+get_first_input_target (void)
+{
+ const char *target = NULL;
+
+ LANG_FOR_EACH_INPUT_STATEMENT (s)
+ {
+ if (s->header.type == lang_input_statement_enum
+ && s->flags.real)
+ {
+ ldfile_open_file (s);
+
+ if (s->the_bfd != NULL
+ && bfd_check_format (s->the_bfd, bfd_object))
+ {
+ target = bfd_get_target (s->the_bfd);
+
+ if (target != NULL)
+ break;
+ }
+ }
+ }
+
+ return target;
+}
+
+const char *
+lang_get_output_target (void)
+{
+ const char *target;
+
+ /* Has the user told us which output format to use? */
+ if (output_target != NULL)
+ return output_target;
+
+ /* No - has the current target been set to something other than
+ the default? */
+ if (current_target != default_target && current_target != NULL)
+ return current_target;
+
+ /* No - can we determine the format of the first input file? */
+ target = get_first_input_target ();
+ if (target != NULL)
+ return target;
+
+ /* Failed - use the default output target. */
+ return default_target;
+}
+
+/* Open the output file. */
+
+static void
+open_output (const char *name)
+{
+ lang_input_statement_type *f;
+ char *out = lrealpath (name);
+
+ for (f = (void *) input_file_chain.head;
+ f != NULL;
+ f = f->next_real_file)
+ if (f->flags.real)
+ {
+ char *in = lrealpath (f->local_sym_name);
+ if (filename_cmp (in, out) == 0)
+ einfo (_("%F%P: input file '%s' is the same as output file\n"),
+ f->filename);
+ free (in);
+ }
+ free (out);
+
+ output_target = lang_get_output_target ();
+
+ /* Has the user requested a particular endianness on the command
+ line? */
+ if (command_line.endian != ENDIAN_UNSET)
+ {
+ /* Get the chosen target. */
+ const bfd_target *target
+ = bfd_iterate_over_targets (get_target, (void *) output_target);
+
+ /* If the target is not supported, we cannot do anything. */
+ if (target != NULL)
+ {
+ enum bfd_endian desired_endian;
+
+ if (command_line.endian == ENDIAN_BIG)
+ desired_endian = BFD_ENDIAN_BIG;
+ else
+ desired_endian = BFD_ENDIAN_LITTLE;
+
+ /* See if the target has the wrong endianness. This should
+ not happen if the linker script has provided big and
+ little endian alternatives, but some scrips don't do
+ this. */
+ if (target->byteorder != desired_endian)
+ {
+ /* If it does, then see if the target provides
+ an alternative with the correct endianness. */
+ if (target->alternative_target != NULL
+ && (target->alternative_target->byteorder == desired_endian))
+ output_target = target->alternative_target->name;
+ else
+ {
+ /* Try to find a target as similar as possible to
+ the default target, but which has the desired
+ endian characteristic. */
+ bfd_iterate_over_targets (closest_target_match,
+ (void *) target);
+
+ /* Oh dear - we could not find any targets that
+ satisfy our requirements. */
+ if (winner == NULL)
+ einfo (_("%P: warning: could not find any targets"
+ " that match endianness requirement\n"));
+ else
+ output_target = winner->name;
+ }
+ }
+ }
+ }
+
+ link_info.output_bfd = bfd_openw (name, output_target);
+
+ if (link_info.output_bfd == NULL)
+ {
+ if (bfd_get_error () == bfd_error_invalid_target)
+ einfo (_("%F%P: target %s not found\n"), output_target);
+
+ einfo (_("%F%P: cannot open output file %s: %E\n"), name);
+ }
+
+ delete_output_file_on_failure = true;
+
+ if (!bfd_set_format (link_info.output_bfd, bfd_object))
+ einfo (_("%F%P: %s: can not make object file: %E\n"), name);
+ if (!bfd_set_arch_mach (link_info.output_bfd,
+ ldfile_output_architecture,
+ ldfile_output_machine))
+ einfo (_("%F%P: %s: can not set architecture: %E\n"), name);
+
+ link_info.hash = bfd_link_hash_table_create (link_info.output_bfd);
+ if (link_info.hash == NULL)
+ einfo (_("%F%P: can not create hash table: %E\n"));
+
+ bfd_set_gp_size (link_info.output_bfd, g_switch_value);
+}
+
+static void
+ldlang_open_output (lang_statement_union_type *statement)
+{
+ switch (statement->header.type)
+ {
+ case lang_output_statement_enum:
+ ASSERT (link_info.output_bfd == NULL);
+ open_output (statement->output_statement.name);
+ ldemul_set_output_arch ();
+ if (config.magic_demand_paged
+ && !bfd_link_relocatable (&link_info))
+ link_info.output_bfd->flags |= D_PAGED;
+ else
+ link_info.output_bfd->flags &= ~D_PAGED;
+ if (config.text_read_only)
+ link_info.output_bfd->flags |= WP_TEXT;
+ else
+ link_info.output_bfd->flags &= ~WP_TEXT;
+ if (link_info.traditional_format)
+ link_info.output_bfd->flags |= BFD_TRADITIONAL_FORMAT;
+ else
+ link_info.output_bfd->flags &= ~BFD_TRADITIONAL_FORMAT;
+ if (config.no_section_header)
+ link_info.output_bfd->flags |= BFD_NO_SECTION_HEADER;
+ else
+ link_info.output_bfd->flags &= ~BFD_NO_SECTION_HEADER;
+ break;
+
+ case lang_target_statement_enum:
+ current_target = statement->target_statement.target;
+ break;
+ default:
+ break;
+ }
+}
+
+static void
+init_opb (asection *s)
+{
+ unsigned int x;
+
+ opb_shift = 0;
+ if (bfd_get_flavour (link_info.output_bfd) == bfd_target_elf_flavour
+ && s != NULL
+ && (s->flags & SEC_ELF_OCTETS) != 0)
+ return;
+
+ x = bfd_arch_mach_octets_per_byte (ldfile_output_architecture,
+ ldfile_output_machine);
+ if (x > 1)
+ while ((x & 1) == 0)
+ {
+ x >>= 1;
+ ++opb_shift;
+ }
+ ASSERT (x == 1);
+}
+
+/* Open all the input files. */
+
+enum open_bfd_mode
+ {
+ OPEN_BFD_NORMAL = 0,
+ OPEN_BFD_FORCE = 1,
+ OPEN_BFD_RESCAN = 2
+ };
+#if BFD_SUPPORTS_PLUGINS
+static lang_input_statement_type *plugin_insert = NULL;
+static struct bfd_link_hash_entry *plugin_undefs = NULL;
+#endif
+
+static void
+open_input_bfds (lang_statement_union_type *s,
+ lang_output_section_statement_type *os,
+ enum open_bfd_mode mode)
+{
+ for (; s != NULL; s = s->header.next)
+ {
+ switch (s->header.type)
+ {
+ case lang_constructors_statement_enum:
+ open_input_bfds (constructor_list.head, os, mode);
+ break;
+ case lang_output_section_statement_enum:
+ os = &s->output_section_statement;
+ open_input_bfds (os->children.head, os, mode);
+ break;
+ case lang_wild_statement_enum:
+ /* Maybe we should load the file's symbols. */
+ if ((mode & OPEN_BFD_RESCAN) == 0
+ && s->wild_statement.filename
+ && !wildcardp (s->wild_statement.filename)
+ && !archive_path (s->wild_statement.filename))
+ lookup_name (s->wild_statement.filename);
+ open_input_bfds (s->wild_statement.children.head, os, mode);
+ break;
+ case lang_group_statement_enum:
+ {
+ struct bfd_link_hash_entry *undefs;
+#if BFD_SUPPORTS_PLUGINS
+ lang_input_statement_type *plugin_insert_save;
+#endif
+
+ /* We must continually search the entries in the group
+ until no new symbols are added to the list of undefined
+ symbols. */
+
+ do
+ {
+#if BFD_SUPPORTS_PLUGINS
+ plugin_insert_save = plugin_insert;
+#endif
+ undefs = link_info.hash->undefs_tail;
+ open_input_bfds (s->group_statement.children.head, os,
+ mode | OPEN_BFD_FORCE);
+ }
+ while (undefs != link_info.hash->undefs_tail
+#if BFD_SUPPORTS_PLUGINS
+ /* Objects inserted by a plugin, which are loaded
+ before we hit this loop, may have added new
+ undefs. */
+ || (plugin_insert != plugin_insert_save && plugin_undefs)
+#endif
+ );
+ }
+ break;
+ case lang_target_statement_enum:
+ current_target = s->target_statement.target;
+ break;
+ case lang_input_statement_enum:
+ if (s->input_statement.flags.real)
+ {
+ lang_statement_union_type **os_tail;
+ lang_statement_list_type add;
+ bfd *abfd;
+
+ s->input_statement.target = current_target;
+
+ /* If we are being called from within a group, and this
+ is an archive which has already been searched, then
+ force it to be researched unless the whole archive
+ has been loaded already. Do the same for a rescan.
+ Likewise reload --as-needed shared libs. */
+ if (mode != OPEN_BFD_NORMAL
+#if BFD_SUPPORTS_PLUGINS
+ && ((mode & OPEN_BFD_RESCAN) == 0
+ || plugin_insert == NULL)
+#endif
+ && s->input_statement.flags.loaded
+ && (abfd = s->input_statement.the_bfd) != NULL
+ && ((bfd_get_format (abfd) == bfd_archive
+ && !s->input_statement.flags.whole_archive)
+ || (bfd_get_format (abfd) == bfd_object
+ && ((abfd->flags) & DYNAMIC) != 0
+ && s->input_statement.flags.add_DT_NEEDED_for_regular
+ && bfd_get_flavour (abfd) == bfd_target_elf_flavour
+ && (elf_dyn_lib_class (abfd) & DYN_AS_NEEDED) != 0)))
+ {
+ s->input_statement.flags.loaded = false;
+ s->input_statement.flags.reload = true;
+ }
+
+ os_tail = lang_os_list.tail;
+ lang_list_init (&add);
+
+ if (!load_symbols (&s->input_statement, &add))
+ config.make_executable = false;
+
+ if (add.head != NULL)
+ {
+ /* If this was a script with output sections then
+ tack any added statements on to the end of the
+ list. This avoids having to reorder the output
+ section statement list. Very likely the user
+ forgot -T, and whatever we do here will not meet
+ naive user expectations. */
+ if (os_tail != lang_os_list.tail)
+ {
+ einfo (_("%P: warning: %s contains output sections;"
+ " did you forget -T?\n"),
+ s->input_statement.filename);
+ *stat_ptr->tail = add.head;
+ stat_ptr->tail = add.tail;
+ }
+ else
+ {
+ *add.tail = s->header.next;
+ s->header.next = add.head;
+ }
+ }
+ }
+#if BFD_SUPPORTS_PLUGINS
+ /* If we have found the point at which a plugin added new
+ files, clear plugin_insert to enable archive rescan. */
+ if (&s->input_statement == plugin_insert)
+ plugin_insert = NULL;
+#endif
+ break;
+ case lang_assignment_statement_enum:
+ if (s->assignment_statement.exp->type.node_class != etree_assert)
+ exp_fold_tree_no_dot (s->assignment_statement.exp, os);
+ break;
+ default:
+ break;
+ }
+ }
+
+ /* Exit if any of the files were missing. */
+ if (input_flags.missing_file)
+ einfo ("%F");
+}
+
+#ifdef ENABLE_LIBCTF
+/* Emit CTF errors and warnings. fp can be NULL to report errors/warnings
+ that happened specifically at CTF open time. */
+static void
+lang_ctf_errs_warnings (ctf_dict_t *fp)
+{
+ ctf_next_t *i = NULL;
+ char *text;
+ int is_warning;
+ int err;
+
+ while ((text = ctf_errwarning_next (fp, &i, &is_warning, &err)) != NULL)
+ {
+ einfo (_("%s: %s\n"), is_warning ? _("CTF warning"): _("CTF error"),
+ text);
+ free (text);
+ }
+ if (err != ECTF_NEXT_END)
+ {
+ einfo (_("CTF error: cannot get CTF errors: `%s'\n"),
+ ctf_errmsg (err));
+ }
+
+ /* `err' returns errors from the error/warning iterator in particular.
+ These never assert. But if we have an fp, that could have recorded
+ an assertion failure: assert if it has done so. */
+ ASSERT (!fp || ctf_errno (fp) != ECTF_INTERNAL);
+}
+
+/* Open the CTF sections in the input files with libctf: if any were opened,
+ create a fake input file that we'll write the merged CTF data to later
+ on. */
+
+static void
+ldlang_open_ctf (void)
+{
+ int any_ctf = 0;
+ int err;
+
+ LANG_FOR_EACH_INPUT_STATEMENT (file)
+ {
+ asection *sect;
+
+ /* Incoming files from the compiler have a single ctf_dict_t in them
+ (which is presented to us by the libctf API in a ctf_archive_t
+ wrapper): files derived from a previous relocatable link have a CTF
+ archive containing possibly many CTF files. */
+
+ if ((file->the_ctf = ctf_bfdopen (file->the_bfd, &err)) == NULL)
+ {
+ if (err != ECTF_NOCTFDATA)
+ {
+ lang_ctf_errs_warnings (NULL);
+ einfo (_("%P: warning: CTF section in %pB not loaded; "
+ "its types will be discarded: %s\n"), file->the_bfd,
+ ctf_errmsg (err));
+ }
+ continue;
+ }
+
+ /* Prevent the contents of this section from being written, while
+ requiring the section itself to be duplicated in the output, but only
+ once. */
+ /* This section must exist if ctf_bfdopen() succeeded. */
+ sect = bfd_get_section_by_name (file->the_bfd, ".ctf");
+ sect->size = 0;
+ sect->flags |= SEC_NEVER_LOAD | SEC_HAS_CONTENTS | SEC_LINKER_CREATED;
+
+ if (any_ctf)
+ sect->flags |= SEC_EXCLUDE;
+ any_ctf = 1;
+ }
+
+ if (!any_ctf)
+ {
+ ctf_output = NULL;
+ return;
+ }
+
+ if ((ctf_output = ctf_create (&err)) != NULL)
+ return;
+
+ einfo (_("%P: warning: CTF output not created: `%s'\n"),
+ ctf_errmsg (err));
+
+ LANG_FOR_EACH_INPUT_STATEMENT (errfile)
+ ctf_close (errfile->the_ctf);
+}
+
+/* Merge together CTF sections. After this, only the symtab-dependent
+ function and data object sections need adjustment. */
+
+static void
+lang_merge_ctf (void)
+{
+ asection *output_sect;
+ int flags = 0;
+
+ if (!ctf_output)
+ return;
+
+ output_sect = bfd_get_section_by_name (link_info.output_bfd, ".ctf");
+
+ /* If the section was discarded, don't waste time merging. */
+ if (output_sect == NULL)
+ {
+ ctf_dict_close (ctf_output);
+ ctf_output = NULL;
+
+ LANG_FOR_EACH_INPUT_STATEMENT (file)
+ {
+ ctf_close (file->the_ctf);
+ file->the_ctf = NULL;
+ }
+ return;
+ }
+
+ LANG_FOR_EACH_INPUT_STATEMENT (file)
+ {
+ if (!file->the_ctf)
+ continue;
+
+ /* Takes ownership of file->the_ctf. */
+ if (ctf_link_add_ctf (ctf_output, file->the_ctf, file->filename) < 0)
+ {
+ einfo (_("%P: warning: CTF section in %pB cannot be linked: `%s'\n"),
+ file->the_bfd, ctf_errmsg (ctf_errno (ctf_output)));
+ ctf_close (file->the_ctf);
+ file->the_ctf = NULL;
+ continue;
+ }
+ }
+
+ if (!config.ctf_share_duplicated)
+ flags = CTF_LINK_SHARE_UNCONFLICTED;
+ else
+ flags = CTF_LINK_SHARE_DUPLICATED;
+ if (!config.ctf_variables)
+ flags |= CTF_LINK_OMIT_VARIABLES_SECTION;
+ if (bfd_link_relocatable (&link_info))
+ flags |= CTF_LINK_NO_FILTER_REPORTED_SYMS;
+
+ if (ctf_link (ctf_output, flags) < 0)
+ {
+ lang_ctf_errs_warnings (ctf_output);
+ einfo (_("%P: warning: CTF linking failed; "
+ "output will have no CTF section: %s\n"),
+ ctf_errmsg (ctf_errno (ctf_output)));
+ if (output_sect)
+ {
+ output_sect->size = 0;
+ output_sect->flags |= SEC_EXCLUDE;
+ }
+ }
+ /* Output any lingering errors that didn't come from ctf_link. */
+ lang_ctf_errs_warnings (ctf_output);
+}
+
+/* Let the emulation acquire strings from the dynamic strtab to help it optimize
+ the CTF, if supported. */
+
+void
+ldlang_ctf_acquire_strings (struct elf_strtab_hash *dynstrtab)
+{
+ ldemul_acquire_strings_for_ctf (ctf_output, dynstrtab);
+}
+
+/* Inform the emulation about the addition of a new dynamic symbol, in BFD
+ internal format. */
+void ldlang_ctf_new_dynsym (int symidx, struct elf_internal_sym *sym)
+{
+ ldemul_new_dynsym_for_ctf (ctf_output, symidx, sym);
+}
+
+/* Write out the CTF section. Called early, if the emulation isn't going to
+ need to dedup against the strtab and symtab, then possibly called from the
+ target linker code if the dedup has happened. */
+static void
+lang_write_ctf (int late)
+{
+ size_t output_size;
+ asection *output_sect;
+
+ if (!ctf_output)
+ return;
+
+ if (late)
+ {
+ /* Emit CTF late if this emulation says it can do so. */
+ if (ldemul_emit_ctf_early ())
+ return;
+ }
+ else
+ {
+ if (!ldemul_emit_ctf_early ())
+ return;
+ }
+
+ /* Inform the emulation that all the symbols that will be received have
+ been. */
+
+ ldemul_new_dynsym_for_ctf (ctf_output, 0, NULL);
+
+ /* Emit CTF. */
+
+ output_sect = bfd_get_section_by_name (link_info.output_bfd, ".ctf");
+ if (output_sect)
+ {
+ output_sect->contents = ctf_link_write (ctf_output, &output_size,
+ CTF_COMPRESSION_THRESHOLD);
+ output_sect->size = output_size;
+ output_sect->flags |= SEC_IN_MEMORY | SEC_KEEP;
+
+ lang_ctf_errs_warnings (ctf_output);
+ if (!output_sect->contents)
+ {
+ einfo (_("%P: warning: CTF section emission failed; "
+ "output will have no CTF section: %s\n"),
+ ctf_errmsg (ctf_errno (ctf_output)));
+ output_sect->size = 0;
+ output_sect->flags |= SEC_EXCLUDE;
+ }
+ }
+
+ /* This also closes every CTF input file used in the link. */
+ ctf_dict_close (ctf_output);
+ ctf_output = NULL;
+
+ LANG_FOR_EACH_INPUT_STATEMENT (file)
+ file->the_ctf = NULL;
+}
+
+/* Write out the CTF section late, if the emulation needs that. */
+
+void
+ldlang_write_ctf_late (void)
+{
+ /* Trigger a "late call", if the emulation needs one. */
+
+ lang_write_ctf (1);
+}
+#else
+static void
+ldlang_open_ctf (void)
+{
+ LANG_FOR_EACH_INPUT_STATEMENT (file)
+ {
+ asection *sect;
+
+ /* If built without CTF, warn and delete all CTF sections from the output.
+ (The alternative would be to simply concatenate them, which does not
+ yield a valid CTF section.) */
+
+ if ((sect = bfd_get_section_by_name (file->the_bfd, ".ctf")) != NULL)
+ {
+ einfo (_("%P: warning: CTF section in %pB not linkable: "
+ "%P was built without support for CTF\n"), file->the_bfd);
+ sect->size = 0;
+ sect->flags |= SEC_EXCLUDE;
+ }
+ }
+}
+
+static void lang_merge_ctf (void) {}
+void
+ldlang_ctf_acquire_strings (struct elf_strtab_hash *dynstrtab
+ ATTRIBUTE_UNUSED) {}
+void
+ldlang_ctf_new_dynsym (int symidx ATTRIBUTE_UNUSED,
+ struct elf_internal_sym *sym ATTRIBUTE_UNUSED) {}
+static void lang_write_ctf (int late ATTRIBUTE_UNUSED) {}
+void ldlang_write_ctf_late (void) {}
+#endif
+
+/* Add the supplied name to the symbol table as an undefined reference.
+ This is a two step process as the symbol table doesn't even exist at
+ the time the ld command line is processed. First we put the name
+ on a list, then, once the output file has been opened, transfer the
+ name to the symbol table. */
+
+typedef struct bfd_sym_chain ldlang_undef_chain_list_type;
+
+#define ldlang_undef_chain_list_head entry_symbol.next
+
+void
+ldlang_add_undef (const char *const name, bool cmdline ATTRIBUTE_UNUSED)
+{
+ ldlang_undef_chain_list_type *new_undef;
+
+ new_undef = stat_alloc (sizeof (*new_undef));
+ new_undef->next = ldlang_undef_chain_list_head;
+ ldlang_undef_chain_list_head = new_undef;
+
+ new_undef->name = xstrdup (name);
+
+ if (link_info.output_bfd != NULL)
+ insert_undefined (new_undef->name);
+}
+
+/* Insert NAME as undefined in the symbol table. */
+
+static void
+insert_undefined (const char *name)
+{
+ struct bfd_link_hash_entry *h;
+
+ h = bfd_link_hash_lookup (link_info.hash, name, true, false, true);
+ if (h == NULL)
+ einfo (_("%F%P: bfd_link_hash_lookup failed: %E\n"));
+ if (h->type == bfd_link_hash_new)
+ {
+ h->type = bfd_link_hash_undefined;
+ h->u.undef.abfd = NULL;
+ h->non_ir_ref_regular = true;
+ bfd_link_add_undef (link_info.hash, h);
+ }
+}
+
+/* Run through the list of undefineds created above and place them
+ into the linker hash table as undefined symbols belonging to the
+ script file. */
+
+static void
+lang_place_undefineds (void)
+{
+ ldlang_undef_chain_list_type *ptr;
+
+ for (ptr = ldlang_undef_chain_list_head; ptr != NULL; ptr = ptr->next)
+ insert_undefined (ptr->name);
+}
+
+/* Mark -u symbols against garbage collection. */
+
+static void
+lang_mark_undefineds (void)
+{
+ ldlang_undef_chain_list_type *ptr;
+
+ if (is_elf_hash_table (link_info.hash))
+ for (ptr = ldlang_undef_chain_list_head; ptr != NULL; ptr = ptr->next)
+ {
+ struct elf_link_hash_entry *h = (struct elf_link_hash_entry *)
+ bfd_link_hash_lookup (link_info.hash, ptr->name, false, false, true);
+ if (h != NULL)
+ h->mark = 1;
+ }
+}
+
+/* Structure used to build the list of symbols that the user has required
+ be defined. */
+
+struct require_defined_symbol
+{
+ const char *name;
+ struct require_defined_symbol *next;
+};
+
+/* The list of symbols that the user has required be defined. */
+
+static struct require_defined_symbol *require_defined_symbol_list;
+
+/* Add a new symbol NAME to the list of symbols that are required to be
+ defined. */
+
+void
+ldlang_add_require_defined (const char *const name)
+{
+ struct require_defined_symbol *ptr;
+
+ ldlang_add_undef (name, true);
+ ptr = stat_alloc (sizeof (*ptr));
+ ptr->next = require_defined_symbol_list;
+ ptr->name = strdup (name);
+ require_defined_symbol_list = ptr;
+}
+
+/* Check that all symbols the user required to be defined, are defined,
+ raise an error if we find a symbol that is not defined. */
+
+static void
+ldlang_check_require_defined_symbols (void)
+{
+ struct require_defined_symbol *ptr;
+
+ for (ptr = require_defined_symbol_list; ptr != NULL; ptr = ptr->next)
+ {
+ struct bfd_link_hash_entry *h;
+
+ h = bfd_link_hash_lookup (link_info.hash, ptr->name,
+ false, false, true);
+ if (h == NULL
+ || (h->type != bfd_link_hash_defined
+ && h->type != bfd_link_hash_defweak))
+ einfo(_("%X%P: required symbol `%s' not defined\n"), ptr->name);
+ }
+}
+
+/* Check for all readonly or some readwrite sections. */
+
+static void
+check_input_sections
+ (lang_statement_union_type *s,
+ lang_output_section_statement_type *output_section_statement)
+{
+ for (; s != NULL; s = s->header.next)
+ {
+ switch (s->header.type)
+ {
+ case lang_wild_statement_enum:
+ walk_wild (&s->wild_statement, check_section_callback,
+ output_section_statement);
+ if (!output_section_statement->all_input_readonly)
+ return;
+ break;
+ case lang_constructors_statement_enum:
+ check_input_sections (constructor_list.head,
+ output_section_statement);
+ if (!output_section_statement->all_input_readonly)
+ return;
+ break;
+ case lang_group_statement_enum:
+ check_input_sections (s->group_statement.children.head,
+ output_section_statement);
+ if (!output_section_statement->all_input_readonly)
+ return;
+ break;
+ default:
+ break;
+ }
+ }
+}
+
+/* Update wildcard statements if needed. */
+
+static void
+update_wild_statements (lang_statement_union_type *s)
+{
+ struct wildcard_list *sec;
+
+ switch (sort_section)
+ {
+ default:
+ FAIL ();
+
+ case none:
+ break;
+
+ case by_name:
+ case by_alignment:
+ for (; s != NULL; s = s->header.next)
+ {
+ switch (s->header.type)
+ {
+ default:
+ break;
+
+ case lang_wild_statement_enum:
+ for (sec = s->wild_statement.section_list; sec != NULL;
+ sec = sec->next)
+ /* Don't sort .init/.fini sections. */
+ if (strcmp (sec->spec.name, ".init") != 0
+ && strcmp (sec->spec.name, ".fini") != 0)
+ {
+ switch (sec->spec.sorted)
+ {
+ case none:
+ sec->spec.sorted = sort_section;
+ break;
+ case by_name:
+ if (sort_section == by_alignment)
+ sec->spec.sorted = by_name_alignment;
+ break;
+ case by_alignment:
+ if (sort_section == by_name)
+ sec->spec.sorted = by_alignment_name;
+ break;
+ default:
+ break;
+ }
+ s->wild_statement.any_specs_sorted = true;
+ }
+ break;
+
+ case lang_constructors_statement_enum:
+ update_wild_statements (constructor_list.head);
+ break;
+
+ case lang_output_section_statement_enum:
+ update_wild_statements
+ (s->output_section_statement.children.head);
+ break;
+
+ case lang_group_statement_enum:
+ update_wild_statements (s->group_statement.children.head);
+ break;
+ }
+ }
+ break;
+ }
+}
+
+/* Open input files and attach to output sections. */
+
+static void
+map_input_to_output_sections
+ (lang_statement_union_type *s, const char *target,
+ lang_output_section_statement_type *os)
+{
+ for (; s != NULL; s = s->header.next)
+ {
+ lang_output_section_statement_type *tos;
+ flagword flags;
+ unsigned int type = 0;
+
+ switch (s->header.type)
+ {
+ case lang_wild_statement_enum:
+ wild (&s->wild_statement, target, os);
+ break;
+ case lang_constructors_statement_enum:
+ map_input_to_output_sections (constructor_list.head,
+ target,
+ os);
+ break;
+ case lang_output_section_statement_enum:
+ tos = &s->output_section_statement;
+ if (tos->constraint == ONLY_IF_RW
+ || tos->constraint == ONLY_IF_RO)
+ {
+ tos->all_input_readonly = true;
+ check_input_sections (tos->children.head, tos);
+ if (tos->all_input_readonly != (tos->constraint == ONLY_IF_RO))
+ tos->constraint = -1;
+ }
+ if (tos->constraint >= 0)
+ map_input_to_output_sections (tos->children.head,
+ target,
+ tos);
+ break;
+ case lang_output_statement_enum:
+ break;
+ case lang_target_statement_enum:
+ target = s->target_statement.target;
+ break;
+ case lang_group_statement_enum:
+ map_input_to_output_sections (s->group_statement.children.head,
+ target,
+ os);
+ break;
+ case lang_data_statement_enum:
+ if (os == NULL)
+ /* This should never happen. */
+ FAIL ();
+ /* Make sure that any sections mentioned in the expression
+ are initialized. */
+ exp_init_os (s->data_statement.exp);
+ /* The output section gets CONTENTS, ALLOC and LOAD, but
+ these may be overridden by the script. */
+ flags = SEC_HAS_CONTENTS | SEC_ALLOC | SEC_LOAD;
+ switch (os->sectype)
+ {
+ case normal_section:
+ case overlay_section:
+ case first_overlay_section:
+ break;
+ case noalloc_section:
+ flags = SEC_HAS_CONTENTS;
+ break;
+ case readonly_section:
+ flags |= SEC_READONLY;
+ break;
+ case typed_readonly_section:
+ flags |= SEC_READONLY;
+ /* Fall through. */
+ case type_section:
+ if (os->sectype_value->type.node_class == etree_name
+ && os->sectype_value->type.node_code == NAME)
+ {
+ const char *name = os->sectype_value->name.name;
+ if (strcmp (name, "SHT_PROGBITS") == 0)
+ type = SHT_PROGBITS;
+ else if (strcmp (name, "SHT_STRTAB") == 0)
+ type = SHT_STRTAB;
+ else if (strcmp (name, "SHT_NOTE") == 0)
+ type = SHT_NOTE;
+ else if (strcmp (name, "SHT_NOBITS") == 0)
+ type = SHT_NOBITS;
+ else if (strcmp (name, "SHT_INIT_ARRAY") == 0)
+ type = SHT_INIT_ARRAY;
+ else if (strcmp (name, "SHT_FINI_ARRAY") == 0)
+ type = SHT_FINI_ARRAY;
+ else if (strcmp (name, "SHT_PREINIT_ARRAY") == 0)
+ type = SHT_PREINIT_ARRAY;
+ else
+ einfo (_ ("%F%P: invalid type for output section `%s'\n"),
+ os->name);
+ }
+ else
+ {
+ exp_fold_tree_no_dot (os->sectype_value, os);
+ if (expld.result.valid_p)
+ type = expld.result.value;
+ else
+ einfo (_ ("%F%P: invalid type for output section `%s'\n"),
+ os->name);
+ }
+ break;
+ case noload_section:
+ if (bfd_get_flavour (link_info.output_bfd)
+ == bfd_target_elf_flavour)
+ flags = SEC_NEVER_LOAD | SEC_ALLOC;
+ else
+ flags = SEC_NEVER_LOAD | SEC_HAS_CONTENTS;
+ break;
+ }
+ if (os->bfd_section == NULL)
+ init_os (os, flags | SEC_READONLY);
+ else
+ os->bfd_section->flags |= flags;
+ os->bfd_section->type = type;
+ break;
+ case lang_input_section_enum:
+ break;
+ case lang_fill_statement_enum:
+ case lang_object_symbols_statement_enum:
+ case lang_reloc_statement_enum:
+ case lang_padding_statement_enum:
+ case lang_input_statement_enum:
+ if (os != NULL && os->bfd_section == NULL)
+ init_os (os, 0);
+ break;
+
+ case lang_assignment_statement_enum:
+ if (os != NULL && os->bfd_section == NULL)
+ init_os (os, get_os_init_flag (os));
+
+ /* Make sure that any sections mentioned in the assignment
+ are initialized. */
+ exp_init_os (s->assignment_statement.exp);
+ break;
+
+ case lang_address_statement_enum:
+ /* Mark the specified section with the supplied address.
+ If this section was actually a segment marker, then the
+ directive is ignored if the linker script explicitly
+ processed the segment marker. Originally, the linker
+ treated segment directives (like -Ttext on the
+ command-line) as section directives. We honor the
+ section directive semantics for backwards compatibility;
+ linker scripts that do not specifically check for
+ SEGMENT_START automatically get the old semantics. */
+ if (!s->address_statement.segment
+ || !s->address_statement.segment->used)
+ {
+ const char *name = s->address_statement.section_name;
+
+ /* Create the output section statement here so that
+ orphans with a set address will be placed after other
+ script sections. If we let the orphan placement code
+ place them in amongst other sections then the address
+ will affect following script sections, which is
+ likely to surprise naive users. */
+ tos = lang_output_section_statement_lookup (name, 0, 1);
+ tos->addr_tree = s->address_statement.address;
+ if (tos->bfd_section == NULL)
+ init_os (tos, 0);
+ }
+ break;
+ case lang_insert_statement_enum:
+ break;
+ case lang_input_matcher_enum:
+ FAIL ();
+ }
+ }
+}
+
+/* An insert statement snips out all the linker statements from the
+ start of the list and places them after the output section
+ statement specified by the insert. This operation is complicated
+ by the fact that we keep a doubly linked list of output section
+ statements as well as the singly linked list of all statements.
+ FIXME someday: Twiddling with the list not only moves statements
+ from the user's script but also input and group statements that are
+ built from command line object files and --start-group. We only
+ get away with this because the list pointers used by file_chain
+ and input_file_chain are not reordered, and processing via
+ statement_list after this point mostly ignores input statements.
+ One exception is the map file, where LOAD and START GROUP/END GROUP
+ can end up looking odd. */
+
+static void
+process_insert_statements (lang_statement_union_type **start)
+{
+ lang_statement_union_type **s;
+ lang_output_section_statement_type *first_os = NULL;
+ lang_output_section_statement_type *last_os = NULL;
+ lang_output_section_statement_type *os;
+
+ s = start;
+ while (*s != NULL)
+ {
+ if ((*s)->header.type == lang_output_section_statement_enum)
+ {
+ /* Keep pointers to the first and last output section
+ statement in the sequence we may be about to move. */
+ os = &(*s)->output_section_statement;
+
+ ASSERT (last_os == NULL || last_os->next == os);
+ last_os = os;
+
+ /* Set constraint negative so that lang_output_section_find
+ won't match this output section statement. At this
+ stage in linking constraint has values in the range
+ [-1, ONLY_IN_RW]. */
+ last_os->constraint = -2 - last_os->constraint;
+ if (first_os == NULL)
+ first_os = last_os;
+ }
+ else if ((*s)->header.type == lang_group_statement_enum)
+ {
+ /* A user might put -T between --start-group and
+ --end-group. One way this odd construct might arise is
+ from a wrapper around ld to change library search
+ behaviour. For example:
+ #! /bin/sh
+ exec real_ld --start-group "$@" --end-group
+ This isn't completely unreasonable so go looking inside a
+ group statement for insert statements. */
+ process_insert_statements (&(*s)->group_statement.children.head);
+ }
+ else if ((*s)->header.type == lang_insert_statement_enum)
+ {
+ lang_insert_statement_type *i = &(*s)->insert_statement;
+ lang_output_section_statement_type *where;
+ lang_statement_union_type **ptr;
+ lang_statement_union_type *first;
+
+ if (link_info.non_contiguous_regions)
+ {
+ einfo (_("warning: INSERT statement in linker script is "
+ "incompatible with --enable-non-contiguous-regions.\n"));
+ }
+
+ where = lang_output_section_find (i->where);
+ if (where != NULL && i->is_before)
+ {
+ do
+ where = where->prev;
+ while (where != NULL && where->constraint < 0);
+ }
+ if (where == NULL)
+ {
+ einfo (_("%F%P: %s not found for insert\n"), i->where);
+ return;
+ }
+
+ /* Deal with reordering the output section statement list. */
+ if (last_os != NULL)
+ {
+ asection *first_sec, *last_sec;
+ struct lang_output_section_statement_struct **next;
+
+ /* Snip out the output sections we are moving. */
+ first_os->prev->next = last_os->next;
+ if (last_os->next == NULL)
+ {
+ next = &first_os->prev->next;
+ lang_os_list.tail = (lang_statement_union_type **) next;
+ }
+ else
+ last_os->next->prev = first_os->prev;
+ /* Add them in at the new position. */
+ last_os->next = where->next;
+ if (where->next == NULL)
+ {
+ next = &last_os->next;
+ lang_os_list.tail = (lang_statement_union_type **) next;
+ }
+ else
+ where->next->prev = last_os;
+ first_os->prev = where;
+ where->next = first_os;
+
+ /* Move the bfd sections in the same way. */
+ first_sec = NULL;
+ last_sec = NULL;
+ for (os = first_os; os != NULL; os = os->next)
+ {
+ os->constraint = -2 - os->constraint;
+ if (os->bfd_section != NULL
+ && os->bfd_section->owner != NULL)
+ {
+ last_sec = os->bfd_section;
+ if (first_sec == NULL)
+ first_sec = last_sec;
+ }
+ if (os == last_os)
+ break;
+ }
+ if (last_sec != NULL)
+ {
+ asection *sec = where->bfd_section;
+ if (sec == NULL)
+ sec = output_prev_sec_find (where);
+
+ /* The place we want to insert must come after the
+ sections we are moving. So if we find no
+ section or if the section is the same as our
+ last section, then no move is needed. */
+ if (sec != NULL && sec != last_sec)
+ {
+ /* Trim them off. */
+ if (first_sec->prev != NULL)
+ first_sec->prev->next = last_sec->next;
+ else
+ link_info.output_bfd->sections = last_sec->next;
+ if (last_sec->next != NULL)
+ last_sec->next->prev = first_sec->prev;
+ else
+ link_info.output_bfd->section_last = first_sec->prev;
+ /* Add back. */
+ if (sec->owner == NULL)
+ /* SEC is the absolute section, from the
+ first dummy output section statement. Add
+ back the sections we trimmed off to the
+ start of the bfd sections. */
+ sec = NULL;
+ if (sec != NULL)
+ last_sec->next = sec->next;
+ else
+ last_sec->next = link_info.output_bfd->sections;
+ if (last_sec->next != NULL)
+ last_sec->next->prev = last_sec;
+ else
+ link_info.output_bfd->section_last = last_sec;
+ first_sec->prev = sec;
+ if (first_sec->prev != NULL)
+ first_sec->prev->next = first_sec;
+ else
+ link_info.output_bfd->sections = first_sec;
+ }
+ }
+ }
+
+ lang_statement_union_type *after = (void *) where;
+ if (where == &lang_os_list.head->output_section_statement
+ && where->next == first_os)
+ {
+ /* PR30155. Handle a corner case where the statement
+ list is something like the following:
+ . LOAD t.o
+ . .data 0x0000000000000000 0x0
+ . [0x0000000000000000] b = .
+ . *(.data)
+ . .data 0x0000000000000000 0x0 t.o
+ . 0x0000000000000000 0x4 LONG 0x0
+ . INSERT BEFORE .text.start
+ . [0x0000000000000004] a = .
+ . .text.start 0x0000000000000000 0x0
+ . [0x0000000000000000] c = .
+ . OUTPUT(a.out elf64-x86-64)
+ Here we do not want to allow insert_os_after to
+ choose a point inside the list we are moving.
+ That would lose the list. Instead, let
+ insert_os_after work from the INSERT, which in this
+ particular example will result in inserting after
+ the assignment "a = .". */
+ after = *s;
+ }
+ ptr = insert_os_after (after);
+ /* Snip everything from the start of the list, up to and
+ including the insert statement we are currently processing. */
+ first = *start;
+ *start = (*s)->header.next;
+ /* Add them back where they belong, minus the insert. */
+ *s = *ptr;
+ if (*s == NULL)
+ statement_list.tail = s;
+ *ptr = first;
+ s = start;
+ first_os = NULL;
+ last_os = NULL;
+ continue;
+ }
+ s = &(*s)->header.next;
+ }
+
+ /* Undo constraint twiddling. */
+ for (os = first_os; os != NULL; os = os->next)
+ {
+ os->constraint = -2 - os->constraint;
+ if (os == last_os)
+ break;
+ }
+}
+
+/* An output section might have been removed after its statement was
+ added. For example, ldemul_before_allocation can remove dynamic
+ sections if they turn out to be not needed. Clean them up here. */
+
+void
+strip_excluded_output_sections (void)
+{
+ lang_output_section_statement_type *os;
+
+ /* Run lang_size_sections (if not already done). */
+ if (expld.phase != lang_mark_phase_enum)
+ {
+ expld.phase = lang_mark_phase_enum;
+ expld.dataseg.phase = exp_seg_none;
+ one_lang_size_sections_pass (NULL, false);
+ lang_reset_memory_regions ();
+ }
+
+ for (os = (void *) lang_os_list.head;
+ os != NULL;
+ os = os->next)
+ {
+ asection *output_section;
+ bool exclude;
+
+ if (os->constraint < 0)
+ continue;
+
+ output_section = os->bfd_section;
+ if (output_section == NULL)
+ continue;
+
+ exclude = (output_section->rawsize == 0
+ && (output_section->flags & SEC_KEEP) == 0
+ && !bfd_section_removed_from_list (link_info.output_bfd,
+ output_section));
+
+ /* Some sections have not yet been sized, notably .gnu.version,
+ .dynsym, .dynstr and .hash. These all have SEC_LINKER_CREATED
+ input sections, so don't drop output sections that have such
+ input sections unless they are also marked SEC_EXCLUDE. */
+ if (exclude && output_section->map_head.s != NULL)
+ {
+ asection *s;
+
+ for (s = output_section->map_head.s; s != NULL; s = s->map_head.s)
+ if ((s->flags & SEC_EXCLUDE) == 0
+ && ((s->flags & SEC_LINKER_CREATED) != 0
+ || link_info.emitrelocations))
+ {
+ exclude = false;
+ break;
+ }
+ }
+
+ if (exclude)
+ {
+ /* We don't set bfd_section to NULL since bfd_section of the
+ removed output section statement may still be used. */
+ if (!os->update_dot)
+ os->ignored = true;
+ output_section->flags |= SEC_EXCLUDE;
+ bfd_section_list_remove (link_info.output_bfd, output_section);
+ link_info.output_bfd->section_count--;
+ }
+ }
+}
+
+/* Called from ldwrite to clear out asection.map_head and
+ asection.map_tail for use as link_orders in ldwrite. */
+
+void
+lang_clear_os_map (void)
+{
+ lang_output_section_statement_type *os;
+
+ if (map_head_is_link_order)
+ return;
+
+ for (os = (void *) lang_os_list.head;
+ os != NULL;
+ os = os->next)
+ {
+ asection *output_section;
+
+ if (os->constraint < 0)
+ continue;
+
+ output_section = os->bfd_section;
+ if (output_section == NULL)
+ continue;
+
+ /* TODO: Don't just junk map_head.s, turn them into link_orders. */
+ output_section->map_head.link_order = NULL;
+ output_section->map_tail.link_order = NULL;
+ }
+
+ /* Stop future calls to lang_add_section from messing with map_head
+ and map_tail link_order fields. */
+ map_head_is_link_order = true;
+}
+
+static void
+print_output_section_statement
+ (lang_output_section_statement_type *output_section_statement)
+{
+ asection *section = output_section_statement->bfd_section;
+ int len;
+
+ if (output_section_statement != abs_output_section)
+ {
+ minfo ("\n%s", output_section_statement->name);
+
+ if (section != NULL)
+ {
+ print_dot = section->vma;
+
+ len = strlen (output_section_statement->name);
+ if (len >= SECTION_NAME_MAP_LENGTH - 1)
+ {
+ print_nl ();
+ len = 0;
+ }
+ print_spaces (SECTION_NAME_MAP_LENGTH - len);
+
+ minfo ("0x%V %W", section->vma, TO_ADDR (section->size));
+
+ if (section->vma != section->lma)
+ minfo (_(" load address 0x%V"), section->lma);
+
+ if (output_section_statement->update_dot_tree != NULL)
+ exp_fold_tree (output_section_statement->update_dot_tree,
+ output_section_statement,
+ bfd_abs_section_ptr, &print_dot);
+ }
+
+ print_nl ();
+ }
+
+ print_statement_list (output_section_statement->children.head,
+ output_section_statement);
+}
+
+static void
+print_assignment (lang_assignment_statement_type *assignment,
+ lang_output_section_statement_type *output_section)
+{
+ bool is_dot;
+ etree_type *tree;
+ asection *osec;
+
+ print_spaces (SECTION_NAME_MAP_LENGTH);
+
+ if (assignment->exp->type.node_class == etree_assert)
+ {
+ is_dot = false;
+ tree = assignment->exp->assert_s.child;
+ }
+ else
+ {
+ const char *dst = assignment->exp->assign.dst;
+
+ is_dot = (dst[0] == '.' && dst[1] == 0);
+ tree = assignment->exp;
+ }
+
+ osec = output_section->bfd_section;
+ if (osec == NULL)
+ osec = bfd_abs_section_ptr;
+
+ if (assignment->exp->type.node_class != etree_provide)
+ exp_fold_tree (tree, output_section, osec, &print_dot);
+ else
+ expld.result.valid_p = false;
+
+ char buf[32];
+ const char *str = buf;
+ if (expld.result.valid_p)
+ {
+ bfd_vma value;
+
+ if (assignment->exp->type.node_class == etree_assert
+ || is_dot
+ || expld.assign_name != NULL)
+ {
+ value = expld.result.value;
+
+ if (expld.result.section != NULL)
+ value += expld.result.section->vma;
+
+ buf[0] = '0';
+ buf[1] = 'x';
+ bfd_sprintf_vma (link_info.output_bfd, buf + 2, value);
+ if (is_dot)
+ print_dot = value;
+ }
+ else
+ {
+ struct bfd_link_hash_entry *h;
+
+ h = bfd_link_hash_lookup (link_info.hash, assignment->exp->assign.dst,
+ false, false, true);
+ if (h != NULL
+ && (h->type == bfd_link_hash_defined
+ || h->type == bfd_link_hash_defweak))
+ {
+ value = h->u.def.value;
+ value += h->u.def.section->output_section->vma;
+ value += h->u.def.section->output_offset;
+
+ buf[0] = '[';
+ buf[1] = '0';
+ buf[2] = 'x';
+ bfd_sprintf_vma (link_info.output_bfd, buf + 3, value);
+ strcat (buf, "]");
+ }
+ else
+ str = "[unresolved]";
+ }
+ }
+ else
+ {
+ if (assignment->exp->type.node_class == etree_provide)
+ str = "[!provide]";
+ else
+ str = "*undef*";
+ }
+ expld.assign_name = NULL;
+
+ fprintf (config.map_file, "%-34s", str);
+ exp_print_tree (assignment->exp);
+ print_nl ();
+}
+
+static void
+print_input_statement (lang_input_statement_type *statm)
+{
+ if (statm->filename != NULL)
+ fprintf (config.map_file, "LOAD %s\n", statm->filename);
+}
+
+/* Print all symbols defined in a particular section. This is called
+ via bfd_link_hash_traverse, or by print_all_symbols. */
+
+bool
+print_one_symbol (struct bfd_link_hash_entry *hash_entry, void *ptr)
+{
+ asection *sec = (asection *) ptr;
+
+ if ((hash_entry->type == bfd_link_hash_defined
+ || hash_entry->type == bfd_link_hash_defweak)
+ && sec == hash_entry->u.def.section)
+ {
+ print_spaces (SECTION_NAME_MAP_LENGTH);
+ minfo ("0x%V ",
+ (hash_entry->u.def.value
+ + hash_entry->u.def.section->output_offset
+ + hash_entry->u.def.section->output_section->vma));
+
+ minfo (" %pT\n", hash_entry->root.string);
+ }
+
+ return true;
+}
+
+static int
+hash_entry_addr_cmp (const void *a, const void *b)
+{
+ const struct bfd_link_hash_entry *l = *(const struct bfd_link_hash_entry **)a;
+ const struct bfd_link_hash_entry *r = *(const struct bfd_link_hash_entry **)b;
+
+ if (l->u.def.value < r->u.def.value)
+ return -1;
+ else if (l->u.def.value > r->u.def.value)
+ return 1;
+ else
+ return 0;
+}
+
+static void
+print_all_symbols (asection *sec)
+{
+ input_section_userdata_type *ud = bfd_section_userdata (sec);
+ struct map_symbol_def *def;
+ struct bfd_link_hash_entry **entries;
+ unsigned int i;
+
+ if (!ud)
+ return;
+
+ *ud->map_symbol_def_tail = 0;
+
+ /* Sort the symbols by address. */
+ entries = (struct bfd_link_hash_entry **)
+ obstack_alloc (&map_obstack,
+ ud->map_symbol_def_count * sizeof (*entries));
+
+ for (i = 0, def = ud->map_symbol_def_head; def; def = def->next, i++)
+ entries[i] = def->entry;
+
+ qsort (entries, ud->map_symbol_def_count, sizeof (*entries),
+ hash_entry_addr_cmp);
+
+ /* Print the symbols. */
+ for (i = 0; i < ud->map_symbol_def_count; i++)
+ ldemul_print_symbol (entries[i], sec);
+
+ obstack_free (&map_obstack, entries);
+}
+
+/* Returns TRUE if SYM is a symbol suitable for printing
+ in a linker map as a local symbol. */
+
+static bool
+ld_is_local_symbol (asymbol * sym)
+{
+ const char * name = bfd_asymbol_name (sym);
+
+ if (name == NULL || *name == 0)
+ return false;
+
+ /* Skip .Lxxx and such like. */
+ if (bfd_is_local_label (link_info.output_bfd, sym))
+ return false;
+
+ /* FIXME: This is intended to skip ARM mapping symbols,
+ which for some reason are not excluded by bfd_is_local_label,
+ but maybe it is wrong for other architectures.
+ It would be better to fix bfd_is_local_label. */
+ if (*name == '$')
+ return false;
+
+ /* Some local symbols, eg _GLOBAL_OFFSET_TABLE_, are present
+ in the hash table, so do not print duplicates here. */
+ struct bfd_link_hash_entry * h;
+ h = bfd_link_hash_lookup (link_info.hash, name, false /* create */,
+ false /* copy */, true /* follow */);
+ if (h == NULL)
+ return true;
+
+ /* Symbols from the plugin owned BFD will not get their own
+ iteration of this function, but can be on the link_info
+ list. So include them here. */
+ if (h->u.def.section->owner != NULL
+ && ((bfd_get_file_flags (h->u.def.section->owner) & (BFD_LINKER_CREATED | BFD_PLUGIN))
+ == (BFD_LINKER_CREATED | BFD_PLUGIN)))
+ return true;
+
+ return false;
+}
+
+/* Print information about an input section to the map file. */
+
+static void
+print_input_section (asection *i, bool is_discarded)
+{
+ bfd_size_type size = i->size;
+ int len;
+ bfd_vma addr;
+
+ init_opb (i);
+
+ minfo (" %s", i->name);
+
+ len = 1 + strlen (i->name);
+ if (len >= SECTION_NAME_MAP_LENGTH - 1)
+ {
+ print_nl ();
+ len = 0;
+ }
+ print_spaces (SECTION_NAME_MAP_LENGTH - len);
+
+ if (i->output_section != NULL
+ && i->output_section->owner == link_info.output_bfd)
+ addr = i->output_section->vma + i->output_offset;
+ else
+ {
+ addr = print_dot;
+ if (!is_discarded)
+ size = 0;
+ }
+
+ char buf[32];
+ bfd_sprintf_vma (link_info.output_bfd, buf, addr);
+ minfo ("0x%s %W %pB\n", buf, TO_ADDR (size), i->owner);
+
+ if (size != i->rawsize && i->rawsize != 0)
+ {
+ len = SECTION_NAME_MAP_LENGTH + 3 + strlen (buf);
+ print_spaces (len);
+ minfo (_("%W (size before relaxing)\n"), TO_ADDR (i->rawsize));
+ }
+
+ if (i->output_section != NULL
+ && i->output_section->owner == link_info.output_bfd)
+ {
+ if (link_info.reduce_memory_overheads)
+ bfd_link_hash_traverse (link_info.hash, ldemul_print_symbol, i);
+ else
+ print_all_symbols (i);
+
+ /* Update print_dot, but make sure that we do not move it
+ backwards - this could happen if we have overlays and a
+ later overlay is shorter than an earier one. */
+ if (addr + TO_ADDR (size) > print_dot)
+ print_dot = addr + TO_ADDR (size);
+
+ if (config.print_map_locals)
+ {
+ long storage_needed;
+
+ /* FIXME: It would be better to cache this table, rather
+ than recreating it for each output section. */
+ /* FIXME: This call is not working for non-ELF based targets.
+ Find out why. */
+ storage_needed = bfd_get_symtab_upper_bound (link_info.output_bfd);
+ if (storage_needed > 0)
+ {
+ asymbol ** symbol_table;
+ long number_of_symbols;
+ long j;
+
+ symbol_table = xmalloc (storage_needed);
+ number_of_symbols = bfd_canonicalize_symtab (link_info.output_bfd, symbol_table);
+
+ for (j = 0; j < number_of_symbols; j++)
+ {
+ asymbol * sym = symbol_table[j];
+ bfd_vma sym_addr = sym->value + i->output_section->vma;
+
+ if (sym->section == i->output_section
+ && (sym->flags & BSF_LOCAL) != 0
+ && sym_addr >= addr
+ && sym_addr < print_dot
+ && ld_is_local_symbol (sym))
+ {
+ print_spaces (SECTION_NAME_MAP_LENGTH);
+ minfo ("0x%V (local) %s\n", sym_addr, bfd_asymbol_name (sym));
+ }
+ }
+
+ free (symbol_table);
+ }
+ }
+ }
+}
+
+static void
+print_fill_statement (lang_fill_statement_type *fill)
+{
+ size_t size;
+ unsigned char *p;
+ fputs (" FILL mask 0x", config.map_file);
+ for (p = fill->fill->data, size = fill->fill->size; size != 0; p++, size--)
+ fprintf (config.map_file, "%02x", *p);
+ fputs ("\n", config.map_file);
+}
+
+static void
+print_data_statement (lang_data_statement_type *data)
+{
+ bfd_vma addr;
+ bfd_size_type size;
+ const char *name;
+
+ init_opb (data->output_section);
+ print_spaces (SECTION_NAME_MAP_LENGTH);
+
+ addr = data->output_offset;
+ if (data->output_section != NULL)
+ addr += data->output_section->vma;
+
+ switch (data->type)
+ {
+ default:
+ abort ();
+ case BYTE:
+ size = BYTE_SIZE;
+ name = "BYTE";
+ break;
+ case SHORT:
+ size = SHORT_SIZE;
+ name = "SHORT";
+ break;
+ case LONG:
+ size = LONG_SIZE;
+ name = "LONG";
+ break;
+ case QUAD:
+ size = QUAD_SIZE;
+ name = "QUAD";
+ break;
+ case SQUAD:
+ size = QUAD_SIZE;
+ name = "SQUAD";
+ break;
+ }
+
+ if (size < TO_SIZE ((unsigned) 1))
+ size = TO_SIZE ((unsigned) 1);
+ minfo ("0x%V %W %s 0x%v", addr, TO_ADDR (size), name, data->value);
+
+ if (data->exp->type.node_class != etree_value)
+ {
+ print_space ();
+ exp_print_tree (data->exp);
+ }
+
+ print_nl ();
+
+ print_dot = addr + TO_ADDR (size);
+}
+
+/* Print an address statement. These are generated by options like
+ -Ttext. */
+
+static void
+print_address_statement (lang_address_statement_type *address)
+{
+ minfo (_("Address of section %s set to "), address->section_name);
+ exp_print_tree (address->address);
+ print_nl ();
+}
+
+/* Print a reloc statement. */
+
+static void
+print_reloc_statement (lang_reloc_statement_type *reloc)
+{
+ bfd_vma addr;
+ bfd_size_type size;
+
+ init_opb (reloc->output_section);
+ print_spaces (SECTION_NAME_MAP_LENGTH);
+
+ addr = reloc->output_offset;
+ if (reloc->output_section != NULL)
+ addr += reloc->output_section->vma;
+
+ size = bfd_get_reloc_size (reloc->howto);
+
+ minfo ("0x%V %W RELOC %s ", addr, TO_ADDR (size), reloc->howto->name);
+
+ if (reloc->name != NULL)
+ minfo ("%s+", reloc->name);
+ else
+ minfo ("%s+", reloc->section->name);
+
+ exp_print_tree (reloc->addend_exp);
+
+ print_nl ();
+
+ print_dot = addr + TO_ADDR (size);
+}
+
+static void
+print_padding_statement (lang_padding_statement_type *s)
+{
+ int len;
+ bfd_vma addr;
+
+ init_opb (s->output_section);
+ minfo (" *fill*");
+
+ len = sizeof " *fill*" - 1;
+ print_spaces (SECTION_NAME_MAP_LENGTH - len);
+
+ addr = s->output_offset;
+ if (s->output_section != NULL)
+ addr += s->output_section->vma;
+ minfo ("0x%V %W ", addr, TO_ADDR (s->size));
+
+ if (s->fill->size != 0)
+ {
+ size_t size;
+ unsigned char *p;
+ for (p = s->fill->data, size = s->fill->size; size != 0; p++, size--)
+ fprintf (config.map_file, "%02x", *p);
+ }
+
+ print_nl ();
+
+ print_dot = addr + TO_ADDR (s->size);
+}
+
+static void
+print_wild_statement (lang_wild_statement_type *w,
+ lang_output_section_statement_type *os)
+{
+ struct wildcard_list *sec;
+
+ print_space ();
+
+ if (w->exclude_name_list)
+ {
+ name_list *tmp;
+ minfo ("EXCLUDE_FILE(%s", w->exclude_name_list->name);
+ for (tmp = w->exclude_name_list->next; tmp; tmp = tmp->next)
+ minfo (" %s", tmp->name);
+ minfo (") ");
+ }
+
+ if (w->filenames_sorted)
+ minfo ("SORT_BY_NAME(");
+ if (w->filenames_reversed)
+ minfo ("REVERSE(");
+ if (w->filename != NULL)
+ minfo ("%s", w->filename);
+ else
+ minfo ("*");
+ if (w->filenames_reversed)
+ minfo (")");
+ if (w->filenames_sorted)
+ minfo (")");
+
+ minfo ("(");
+ for (sec = w->section_list; sec; sec = sec->next)
+ {
+ int closing_paren = 0;
+
+ switch (sec->spec.sorted)
+ {
+ case none:
+ break;
+
+ case by_name:
+ minfo ("SORT_BY_NAME(");
+ closing_paren = 1;
+ break;
+
+ case by_alignment:
+ minfo ("SORT_BY_ALIGNMENT(");
+ closing_paren = 1;
+ break;
+
+ case by_name_alignment:
+ minfo ("SORT_BY_NAME(SORT_BY_ALIGNMENT(");
+ closing_paren = 2;
+ break;
+
+ case by_alignment_name:
+ minfo ("SORT_BY_ALIGNMENT(SORT_BY_NAME(");
+ closing_paren = 2;
+ break;
+
+ case by_none:
+ minfo ("SORT_NONE(");
+ closing_paren = 1;
+ break;
+
+ case by_init_priority:
+ minfo ("SORT_BY_INIT_PRIORITY(");
+ closing_paren = 1;
+ break;
+ }
+
+ if (sec->spec.reversed)
+ {
+ minfo ("REVERSE(");
+ closing_paren++;
+ }
+
+ if (sec->spec.exclude_name_list != NULL)
+ {
+ name_list *tmp;
+ minfo ("EXCLUDE_FILE(%s", sec->spec.exclude_name_list->name);
+ for (tmp = sec->spec.exclude_name_list->next; tmp; tmp = tmp->next)
+ minfo (" %s", tmp->name);
+ minfo (") ");
+ }
+ if (sec->spec.name != NULL)
+ minfo ("%s", sec->spec.name);
+ else
+ minfo ("*");
+ for (;closing_paren > 0; closing_paren--)
+ minfo (")");
+ if (sec->next)
+ minfo (" ");
+ }
+ minfo (")");
+
+ print_nl ();
+
+ print_statement_list (w->children.head, os);
+}
+
+/* Print a group statement. */
+
+static void
+print_group (lang_group_statement_type *s,
+ lang_output_section_statement_type *os)
+{
+ fprintf (config.map_file, "START GROUP\n");
+ print_statement_list (s->children.head, os);
+ fprintf (config.map_file, "END GROUP\n");
+}
+
+/* Print the list of statements in S.
+ This can be called for any statement type. */
+
+static void
+print_statement_list (lang_statement_union_type *s,
+ lang_output_section_statement_type *os)
+{
+ while (s != NULL)
+ {
+ print_statement (s, os);
+ s = s->header.next;
+ }
+}
+
+/* Print the first statement in statement list S.
+ This can be called for any statement type. */
+
+static void
+print_statement (lang_statement_union_type *s,
+ lang_output_section_statement_type *os)
+{
+ switch (s->header.type)
+ {
+ default:
+ fprintf (config.map_file, _("Fail with %d\n"), s->header.type);
+ FAIL ();
+ break;
+ case lang_constructors_statement_enum:
+ if (constructor_list.head != NULL)
+ {
+ if (constructors_sorted)
+ minfo (" SORT (CONSTRUCTORS)\n");
+ else
+ minfo (" CONSTRUCTORS\n");
+ print_statement_list (constructor_list.head, os);
+ }
+ break;
+ case lang_wild_statement_enum:
+ print_wild_statement (&s->wild_statement, os);
+ break;
+ case lang_address_statement_enum:
+ print_address_statement (&s->address_statement);
+ break;
+ case lang_object_symbols_statement_enum:
+ minfo (" CREATE_OBJECT_SYMBOLS\n");
+ break;
+ case lang_fill_statement_enum:
+ print_fill_statement (&s->fill_statement);
+ break;
+ case lang_data_statement_enum:
+ print_data_statement (&s->data_statement);
+ break;
+ case lang_reloc_statement_enum:
+ print_reloc_statement (&s->reloc_statement);
+ break;
+ case lang_input_section_enum:
+ print_input_section (s->input_section.section, false);
+ break;
+ case lang_padding_statement_enum:
+ print_padding_statement (&s->padding_statement);
+ break;
+ case lang_output_section_statement_enum:
+ print_output_section_statement (&s->output_section_statement);
+ break;
+ case lang_assignment_statement_enum:
+ print_assignment (&s->assignment_statement, os);
+ break;
+ case lang_target_statement_enum:
+ fprintf (config.map_file, "TARGET(%s)\n", s->target_statement.target);
+ break;
+ case lang_output_statement_enum:
+ minfo ("OUTPUT(%s", s->output_statement.name);
+ if (output_target != NULL)
+ minfo (" %s", output_target);
+ minfo (")\n");
+ break;
+ case lang_input_statement_enum:
+ print_input_statement (&s->input_statement);
+ break;
+ case lang_group_statement_enum:
+ print_group (&s->group_statement, os);
+ break;
+ case lang_insert_statement_enum:
+ minfo ("INSERT %s %s\n",
+ s->insert_statement.is_before ? "BEFORE" : "AFTER",
+ s->insert_statement.where);
+ break;
+ }
+}
+
+static void
+print_statements (void)
+{
+ print_statement_list (statement_list.head, abs_output_section);
+}
+
+/* Print the first N statements in statement list S to STDERR.
+ If N == 0, nothing is printed.
+ If N < 0, the entire list is printed.
+ Intended to be called from GDB. */
+
+void
+dprint_statement (lang_statement_union_type *s, int n)
+{
+ FILE *map_save = config.map_file;
+
+ config.map_file = stderr;
+
+ if (n < 0)
+ print_statement_list (s, abs_output_section);
+ else
+ {
+ while (s && --n >= 0)
+ {
+ print_statement (s, abs_output_section);
+ s = s->header.next;
+ }
+ }
+
+ config.map_file = map_save;
+}
+
+static void
+insert_pad (lang_statement_union_type **ptr,
+ fill_type *fill,
+ bfd_size_type alignment_needed,
+ asection *output_section,
+ bfd_vma dot)
+{
+ static fill_type zero_fill;
+ lang_statement_union_type *pad = NULL;
+
+ if (ptr != &statement_list.head)
+ pad = ((lang_statement_union_type *)
+ ((char *) ptr - offsetof (lang_statement_union_type, header.next)));
+ if (pad != NULL
+ && pad->header.type == lang_padding_statement_enum
+ && pad->padding_statement.output_section == output_section)
+ {
+ /* Use the existing pad statement. */
+ }
+ else if ((pad = *ptr) != NULL
+ && pad->header.type == lang_padding_statement_enum
+ && pad->padding_statement.output_section == output_section)
+ {
+ /* Use the existing pad statement. */
+ }
+ else
+ {
+ /* Make a new padding statement, linked into existing chain. */
+ pad = stat_alloc (sizeof (lang_padding_statement_type));
+ pad->header.next = *ptr;
+ *ptr = pad;
+ pad->header.type = lang_padding_statement_enum;
+ pad->padding_statement.output_section = output_section;
+ if (fill == NULL)
+ fill = &zero_fill;
+ pad->padding_statement.fill = fill;
+ }
+ pad->padding_statement.output_offset = dot - output_section->vma;
+ pad->padding_statement.size = alignment_needed;
+ if (!(output_section->flags & SEC_FIXED_SIZE))
+ output_section->size = TO_SIZE (dot + TO_ADDR (alignment_needed)
+ - output_section->vma);
+}
+
+/* Work out how much this section will move the dot point. */
+
+static bfd_vma
+size_input_section
+ (lang_statement_union_type **this_ptr,
+ lang_output_section_statement_type *output_section_statement,
+ fill_type *fill,
+ bool *removed,
+ bfd_vma dot)
+{
+ lang_input_section_type *is = &((*this_ptr)->input_section);
+ asection *i = is->section;
+ asection *o = output_section_statement->bfd_section;
+ *removed = 0;
+
+ if (link_info.non_contiguous_regions)
+ {
+ /* If the input section I has already been successfully assigned
+ to an output section other than O, don't bother with it and
+ let the caller remove it from the list. Keep processing in
+ case we have already handled O, because the repeated passes
+ have reinitialized its size. */
+ if (i->already_assigned && i->already_assigned != o)
+ {
+ *removed = 1;
+ return dot;
+ }
+ }
+
+ if (i->sec_info_type == SEC_INFO_TYPE_JUST_SYMS)
+ i->output_offset = i->vma - o->vma;
+ else if (((i->flags & SEC_EXCLUDE) != 0)
+ || output_section_statement->ignored)
+ i->output_offset = dot - o->vma;
+ else
+ {
+ bfd_size_type alignment_needed;
+
+ /* Align this section first to the input sections requirement,
+ then to the output section's requirement. If this alignment
+ is greater than any seen before, then record it too. Perform
+ the alignment by inserting a magic 'padding' statement.
+ We can force input section alignment within an output section
+ by using SUBALIGN. The value specified overrides any alignment
+ given by input sections, whether larger or smaller. */
+
+ if (output_section_statement->subsection_alignment != NULL)
+ o->alignment_power = i->alignment_power =
+ exp_get_power (output_section_statement->subsection_alignment,
+ output_section_statement,
+ "subsection alignment");
+
+ if (o->alignment_power < i->alignment_power)
+ o->alignment_power = i->alignment_power;
+
+ alignment_needed = align_power (dot, i->alignment_power) - dot;
+
+ if (alignment_needed != 0)
+ {
+ insert_pad (this_ptr, fill, TO_SIZE (alignment_needed), o, dot);
+ dot += alignment_needed;
+ }
+
+ if (link_info.non_contiguous_regions)
+ {
+ /* If I would overflow O, let the caller remove I from the
+ list. */
+ if (output_section_statement->region)
+ {
+ bfd_vma end = output_section_statement->region->origin
+ + output_section_statement->region->length;
+
+ if (dot + TO_ADDR (i->size) > end)
+ {
+ if (i->flags & SEC_LINKER_CREATED)
+ einfo (_("%F%P: Output section `%pA' not large enough for "
+ "the linker-created stubs section `%pA'.\n"),
+ i->output_section, i);
+
+ if (i->rawsize && i->rawsize != i->size)
+ einfo (_("%F%P: Relaxation not supported with "
+ "--enable-non-contiguous-regions (section `%pA' "
+ "would overflow `%pA' after it changed size).\n"),
+ i, i->output_section);
+
+ *removed = 1;
+ dot = end;
+ i->output_section = NULL;
+ return dot;
+ }
+ }
+ }
+
+ /* Remember where in the output section this input section goes. */
+ i->output_offset = dot - o->vma;
+
+ /* Mark how big the output section must be to contain this now. */
+ dot += TO_ADDR (i->size);
+ if (!(o->flags & SEC_FIXED_SIZE))
+ o->size = TO_SIZE (dot - o->vma);
+
+ if (link_info.non_contiguous_regions)
+ {
+ /* Record that I was successfully assigned to O, and update
+ its actual output section too. */
+ i->already_assigned = o;
+ i->output_section = o;
+ }
+ }
+
+ return dot;
+}
+
+struct check_sec
+{
+ asection *sec;
+ bool warned;
+};
+
+static int
+sort_sections_by_lma (const void *arg1, const void *arg2)
+{
+ const asection *sec1 = ((const struct check_sec *) arg1)->sec;
+ const asection *sec2 = ((const struct check_sec *) arg2)->sec;
+
+ if (sec1->lma < sec2->lma)
+ return -1;
+ else if (sec1->lma > sec2->lma)
+ return 1;
+ else if (sec1->id < sec2->id)
+ return -1;
+ else if (sec1->id > sec2->id)
+ return 1;
+
+ return 0;
+}
+
+static int
+sort_sections_by_vma (const void *arg1, const void *arg2)
+{
+ const asection *sec1 = ((const struct check_sec *) arg1)->sec;
+ const asection *sec2 = ((const struct check_sec *) arg2)->sec;
+
+ if (sec1->vma < sec2->vma)
+ return -1;
+ else if (sec1->vma > sec2->vma)
+ return 1;
+ else if (sec1->id < sec2->id)
+ return -1;
+ else if (sec1->id > sec2->id)
+ return 1;
+
+ return 0;
+}
+
+#define IS_TBSS(s) \
+ ((s->flags & (SEC_LOAD | SEC_THREAD_LOCAL)) == SEC_THREAD_LOCAL)
+
+#define IGNORE_SECTION(s) \
+ ((s->flags & SEC_ALLOC) == 0 || IS_TBSS (s))
+
+/* Check to see if any allocated sections overlap with other allocated
+ sections. This can happen if a linker script specifies the output
+ section addresses of the two sections. Also check whether any memory
+ region has overflowed. */
+
+static void
+lang_check_section_addresses (void)
+{
+ asection *s, *p;
+ struct check_sec *sections;
+ size_t i, count;
+ bfd_vma addr_mask;
+ bfd_vma s_start;
+ bfd_vma s_end;
+ bfd_vma p_start = 0;
+ bfd_vma p_end = 0;
+ lang_memory_region_type *m;
+ bool overlays;
+
+ /* Detect address space overflow on allocated sections. */
+ addr_mask = ((bfd_vma) 1 <<
+ (bfd_arch_bits_per_address (link_info.output_bfd) - 1)) - 1;
+ addr_mask = (addr_mask << 1) + 1;
+ for (s = link_info.output_bfd->sections; s != NULL; s = s->next)
+ if ((s->flags & SEC_ALLOC) != 0)
+ {
+ s_end = (s->vma + s->size) & addr_mask;
+ if (s_end != 0 && s_end < (s->vma & addr_mask))
+ einfo (_("%X%P: section %s VMA wraps around address space\n"),
+ s->name);
+ else
+ {
+ s_end = (s->lma + s->size) & addr_mask;
+ if (s_end != 0 && s_end < (s->lma & addr_mask))
+ einfo (_("%X%P: section %s LMA wraps around address space\n"),
+ s->name);
+ }
+ }
+
+ if (bfd_count_sections (link_info.output_bfd) <= 1)
+ return;
+
+ count = bfd_count_sections (link_info.output_bfd);
+ sections = XNEWVEC (struct check_sec, count);
+
+ /* Scan all sections in the output list. */
+ count = 0;
+ for (s = link_info.output_bfd->sections; s != NULL; s = s->next)
+ {
+ if (IGNORE_SECTION (s)
+ || s->size == 0)
+ continue;
+
+ sections[count].sec = s;
+ sections[count].warned = false;
+ count++;
+ }
+
+ if (count <= 1)
+ {
+ free (sections);
+ return;
+ }
+
+ qsort (sections, count, sizeof (*sections), sort_sections_by_lma);
+
+ /* First check section LMAs. There should be no overlap of LMAs on
+ loadable sections, even with overlays. */
+ for (p = NULL, i = 0; i < count; i++)
+ {
+ s = sections[i].sec;
+ init_opb (s);
+ if ((s->flags & SEC_LOAD) != 0)
+ {
+ s_start = s->lma;
+ s_end = s_start + TO_ADDR (s->size) - 1;
+
+ /* Look for an overlap. We have sorted sections by lma, so
+ we know that s_start >= p_start. Besides the obvious
+ case of overlap when the current section starts before
+ the previous one ends, we also must have overlap if the
+ previous section wraps around the address space. */
+ if (p != NULL
+ && (s_start <= p_end
+ || p_end < p_start))
+ {
+ einfo (_("%X%P: section %s LMA [%V,%V]"
+ " overlaps section %s LMA [%V,%V]\n"),
+ s->name, s_start, s_end, p->name, p_start, p_end);
+ sections[i].warned = true;
+ }
+ p = s;
+ p_start = s_start;
+ p_end = s_end;
+ }
+ }
+
+ /* If any non-zero size allocated section (excluding tbss) starts at
+ exactly the same VMA as another such section, then we have
+ overlays. Overlays generated by the OVERLAY keyword will have
+ this property. It is possible to intentionally generate overlays
+ that fail this test, but it would be unusual. */
+ qsort (sections, count, sizeof (*sections), sort_sections_by_vma);
+ overlays = false;
+ p_start = sections[0].sec->vma;
+ for (i = 1; i < count; i++)
+ {
+ s_start = sections[i].sec->vma;
+ if (p_start == s_start)
+ {
+ overlays = true;
+ break;
+ }
+ p_start = s_start;
+ }
+
+ /* Now check section VMAs if no overlays were detected. */
+ if (!overlays)
+ {
+ for (p = NULL, i = 0; i < count; i++)
+ {
+ s = sections[i].sec;
+ init_opb (s);
+ s_start = s->vma;
+ s_end = s_start + TO_ADDR (s->size) - 1;
+
+ if (p != NULL
+ && !sections[i].warned
+ && (s_start <= p_end
+ || p_end < p_start))
+ einfo (_("%X%P: section %s VMA [%V,%V]"
+ " overlaps section %s VMA [%V,%V]\n"),
+ s->name, s_start, s_end, p->name, p_start, p_end);
+ p = s;
+ p_start = s_start;
+ p_end = s_end;
+ }
+ }
+
+ free (sections);
+
+ /* If any memory region has overflowed, report by how much.
+ We do not issue this diagnostic for regions that had sections
+ explicitly placed outside their bounds; os_region_check's
+ diagnostics are adequate for that case.
+
+ FIXME: It is conceivable that m->current - (m->origin + m->length)
+ might overflow a 32-bit integer. There is, alas, no way to print
+ a bfd_vma quantity in decimal. */
+ for (m = lang_memory_region_list; m; m = m->next)
+ if (m->had_full_message)
+ {
+ unsigned long over = m->current - (m->origin + m->length);
+ einfo (ngettext ("%X%P: region `%s' overflowed by %lu byte\n",
+ "%X%P: region `%s' overflowed by %lu bytes\n",
+ over),
+ m->name_list.name, over);
+ }
+}
+
+/* Make sure the new address is within the region. We explicitly permit the
+ current address to be at the exact end of the region when the address is
+ non-zero, in case the region is at the end of addressable memory and the
+ calculation wraps around. */
+
+static void
+os_region_check (lang_output_section_statement_type *os,
+ lang_memory_region_type *region,
+ etree_type *tree,
+ bfd_vma rbase)
+{
+ if ((region->current < region->origin
+ || (region->current - region->origin > region->length))
+ && ((region->current != region->origin + region->length)
+ || rbase == 0))
+ {
+ if (tree != NULL)
+ {
+ einfo (_("%X%P: address 0x%v of %pB section `%s'"
+ " is not within region `%s'\n"),
+ region->current,
+ os->bfd_section->owner,
+ os->bfd_section->name,
+ region->name_list.name);
+ }
+ else if (!region->had_full_message)
+ {
+ region->had_full_message = true;
+
+ einfo (_("%X%P: %pB section `%s' will not fit in region `%s'\n"),
+ os->bfd_section->owner,
+ os->bfd_section->name,
+ region->name_list.name);
+ }
+ }
+}
+
+static void
+ldlang_check_relro_region (lang_statement_union_type *s)
+{
+ seg_align_type *seg = &expld.dataseg;
+
+ if (seg->relro == exp_seg_relro_start)
+ {
+ if (!seg->relro_start_stat)
+ seg->relro_start_stat = s;
+ else
+ {
+ ASSERT (seg->relro_start_stat == s);
+ }
+ }
+ else if (seg->relro == exp_seg_relro_end)
+ {
+ if (!seg->relro_end_stat)
+ seg->relro_end_stat = s;
+ else
+ {
+ ASSERT (seg->relro_end_stat == s);
+ }
+ }
+}
+
+/* Set the sizes for all the output sections. */
+
+static bfd_vma
+lang_size_sections_1
+ (lang_statement_union_type **prev,
+ lang_output_section_statement_type *current_os,
+ fill_type *fill,
+ bfd_vma dot,
+ bool *relax,
+ bool check_regions)
+{
+ lang_statement_union_type *s;
+ lang_statement_union_type *prev_s = NULL;
+ bool removed_prev_s = false;
+ lang_output_section_statement_type *os = current_os;
+
+ /* Size up the sections from their constituent parts. */
+ for (s = *prev; s != NULL; prev_s = s, s = s->header.next)
+ {
+ bool removed = false;
+
+ switch (s->header.type)
+ {
+ case lang_output_section_statement_enum:
+ {
+ bfd_vma newdot, after, dotdelta;
+ lang_memory_region_type *r;
+ int section_alignment = 0;
+
+ os = &s->output_section_statement;
+ init_opb (os->bfd_section);
+ if (os->constraint == -1)
+ break;
+
+ /* FIXME: We shouldn't need to zero section vmas for ld -r
+ here, in lang_insert_orphan, or in the default linker scripts.
+ This is covering for coff backend linker bugs. See PR6945. */
+ if (os->addr_tree == NULL
+ && bfd_link_relocatable (&link_info)
+ && (bfd_get_flavour (link_info.output_bfd)
+ == bfd_target_coff_flavour))
+ os->addr_tree = exp_intop (0);
+ if (os->addr_tree != NULL)
+ {
+ exp_fold_tree (os->addr_tree, os, bfd_abs_section_ptr, &dot);
+
+ if (expld.result.valid_p)
+ {
+ dot = expld.result.value;
+ if (expld.result.section != NULL)
+ dot += expld.result.section->vma;
+ }
+ else if (expld.phase != lang_mark_phase_enum)
+ einfo (_("%F%P:%pS: non constant or forward reference"
+ " address expression for section %s\n"),
+ os->addr_tree, os->name);
+ }
+
+ if (os->bfd_section == NULL)
+ /* This section was removed or never actually created. */
+ break;
+
+ /* If this is a COFF shared library section, use the size and
+ address from the input section. FIXME: This is COFF
+ specific; it would be cleaner if there were some other way
+ to do this, but nothing simple comes to mind. */
+ if (((bfd_get_flavour (link_info.output_bfd)
+ == bfd_target_ecoff_flavour)
+ || (bfd_get_flavour (link_info.output_bfd)
+ == bfd_target_coff_flavour))
+ && (os->bfd_section->flags & SEC_COFF_SHARED_LIBRARY) != 0)
+ {
+ asection *input;
+
+ if (os->children.head == NULL
+ || os->children.head->header.next != NULL
+ || (os->children.head->header.type
+ != lang_input_section_enum))
+ einfo (_("%X%P: internal error on COFF shared library"
+ " section %s\n"), os->name);
+
+ input = os->children.head->input_section.section;
+ bfd_set_section_vma (os->bfd_section,
+ bfd_section_vma (input));
+ if (!(os->bfd_section->flags & SEC_FIXED_SIZE))
+ os->bfd_section->size = input->size;
+ break;
+ }
+
+ newdot = dot;
+ dotdelta = 0;
+ if (bfd_is_abs_section (os->bfd_section))
+ {
+ /* No matter what happens, an abs section starts at zero. */
+ ASSERT (os->bfd_section->vma == 0);
+ }
+ else
+ {
+ if (os->addr_tree == NULL)
+ {
+ /* No address specified for this section, get one
+ from the region specification. */
+ if (os->region == NULL
+ || ((os->bfd_section->flags & (SEC_ALLOC | SEC_LOAD))
+ && os->region->name_list.name[0] == '*'
+ && strcmp (os->region->name_list.name,
+ DEFAULT_MEMORY_REGION) == 0))
+ {
+ os->region = lang_memory_default (os->bfd_section);
+ }
+
+ /* If a loadable section is using the default memory
+ region, and some non default memory regions were
+ defined, issue an error message. */
+ if (!os->ignored
+ && !IGNORE_SECTION (os->bfd_section)
+ && !bfd_link_relocatable (&link_info)
+ && check_regions
+ && strcmp (os->region->name_list.name,
+ DEFAULT_MEMORY_REGION) == 0
+ && lang_memory_region_list != NULL
+ && (strcmp (lang_memory_region_list->name_list.name,
+ DEFAULT_MEMORY_REGION) != 0
+ || lang_memory_region_list->next != NULL)
+ && lang_sizing_iteration == 1)
+ {
+ /* By default this is an error rather than just a
+ warning because if we allocate the section to the
+ default memory region we can end up creating an
+ excessively large binary, or even seg faulting when
+ attempting to perform a negative seek. See
+ sources.redhat.com/ml/binutils/2003-04/msg00423.html
+ for an example of this. This behaviour can be
+ overridden by the using the --no-check-sections
+ switch. */
+ if (command_line.check_section_addresses)
+ einfo (_("%F%P: error: no memory region specified"
+ " for loadable section `%s'\n"),
+ bfd_section_name (os->bfd_section));
+ else
+ einfo (_("%P: warning: no memory region specified"
+ " for loadable section `%s'\n"),
+ bfd_section_name (os->bfd_section));
+ }
+
+ newdot = os->region->current;
+ section_alignment = os->bfd_section->alignment_power;
+ }
+ else
+ section_alignment = exp_get_power (os->section_alignment, os,
+ "section alignment");
+
+ /* Align to what the section needs. */
+ if (section_alignment > 0)
+ {
+ bfd_vma savedot = newdot;
+ bfd_vma diff = 0;
+
+ newdot = align_power (newdot, section_alignment);
+ dotdelta = newdot - savedot;
+
+ if (lang_sizing_iteration == 1)
+ diff = dotdelta;
+ else if (lang_sizing_iteration > 1)
+ {
+ /* Only report adjustments that would change
+ alignment from what we have already reported. */
+ diff = newdot - os->bfd_section->vma;
+ if (!(diff & (((bfd_vma) 1 << section_alignment) - 1)))
+ diff = 0;
+ }
+ if (diff != 0
+ && (config.warn_section_align
+ || os->addr_tree != NULL))
+ einfo (_("%P: warning: "
+ "start of section %s changed by %ld\n"),
+ os->name, (long) diff);
+ }
+
+ bfd_set_section_vma (os->bfd_section, newdot);
+
+ os->bfd_section->output_offset = 0;
+ }
+
+ lang_size_sections_1 (&os->children.head, os,
+ os->fill, newdot, relax, check_regions);
+
+ os->processed_vma = true;
+
+ if (bfd_is_abs_section (os->bfd_section) || os->ignored)
+ /* Except for some special linker created sections,
+ no output section should change from zero size
+ after strip_excluded_output_sections. A non-zero
+ size on an ignored section indicates that some
+ input section was not sized early enough. */
+ ASSERT (os->bfd_section->size == 0);
+ else
+ {
+ dot = os->bfd_section->vma;
+
+ /* Put the section within the requested block size, or
+ align at the block boundary. */
+ after = ((dot
+ + TO_ADDR (os->bfd_section->size)
+ + os->block_value - 1)
+ & - (bfd_vma) os->block_value);
+
+ if (!(os->bfd_section->flags & SEC_FIXED_SIZE))
+ os->bfd_section->size = TO_SIZE (after
+ - os->bfd_section->vma);
+ }
+
+ /* Set section lma. */
+ r = os->region;
+ if (r == NULL)
+ r = lang_memory_region_lookup (DEFAULT_MEMORY_REGION, false);
+
+ if (os->load_base)
+ {
+ bfd_vma lma = exp_get_abs_int (os->load_base, 0, "load base");
+ os->bfd_section->lma = lma;
+ }
+ else if (os->lma_region != NULL)
+ {
+ bfd_vma lma = os->lma_region->current;
+
+ if (os->align_lma_with_input)
+ lma += dotdelta;
+ else
+ {
+ /* When LMA_REGION is the same as REGION, align the LMA
+ as we did for the VMA, possibly including alignment
+ from the bfd section. If a different region, then
+ only align according to the value in the output
+ statement. */
+ if (os->lma_region != os->region)
+ section_alignment = exp_get_power (os->section_alignment,
+ os,
+ "section alignment");
+ if (section_alignment > 0)
+ lma = align_power (lma, section_alignment);
+ }
+ os->bfd_section->lma = lma;
+ }
+ else if (r->last_os != NULL
+ && (os->bfd_section->flags & SEC_ALLOC) != 0)
+ {
+ bfd_vma lma;
+ asection *last;
+
+ last = r->last_os->output_section_statement.bfd_section;
+
+ /* A backwards move of dot should be accompanied by
+ an explicit assignment to the section LMA (ie.
+ os->load_base set) because backwards moves can
+ create overlapping LMAs. */
+ if (dot < last->vma
+ && os->bfd_section->size != 0
+ && dot + TO_ADDR (os->bfd_section->size) <= last->vma)
+ {
+ /* If dot moved backwards then leave lma equal to
+ vma. This is the old default lma, which might
+ just happen to work when the backwards move is
+ sufficiently large. Nag if this changes anything,
+ so people can fix their linker scripts. */
+
+ if (last->vma != last->lma)
+ einfo (_("%P: warning: dot moved backwards "
+ "before `%s'\n"), os->name);
+ }
+ else
+ {
+ /* If this is an overlay, set the current lma to that
+ at the end of the previous section. */
+ if (os->sectype == overlay_section)
+ lma = last->lma + TO_ADDR (last->size);
+
+ /* Otherwise, keep the same lma to vma relationship
+ as the previous section. */
+ else
+ lma = os->bfd_section->vma + last->lma - last->vma;
+
+ if (section_alignment > 0)
+ lma = align_power (lma, section_alignment);
+ os->bfd_section->lma = lma;
+ }
+ }
+ os->processed_lma = true;
+
+ /* Keep track of normal sections using the default
+ lma region. We use this to set the lma for
+ following sections. Overlays or other linker
+ script assignment to lma might mean that the
+ default lma == vma is incorrect.
+ To avoid warnings about dot moving backwards when using
+ -Ttext, don't start tracking sections until we find one
+ of non-zero size or with lma set differently to vma.
+ Do this tracking before we short-cut the loop so that we
+ track changes for the case where the section size is zero,
+ but the lma is set differently to the vma. This is
+ important, if an orphan section is placed after an
+ otherwise empty output section that has an explicit lma
+ set, we want that lma reflected in the orphans lma. */
+ if (((!IGNORE_SECTION (os->bfd_section)
+ && (os->bfd_section->size != 0
+ || (r->last_os == NULL
+ && os->bfd_section->vma != os->bfd_section->lma)
+ || (r->last_os != NULL
+ && dot >= (r->last_os->output_section_statement
+ .bfd_section->vma))))
+ || os->sectype == first_overlay_section)
+ && os->lma_region == NULL
+ && !bfd_link_relocatable (&link_info))
+ r->last_os = s;
+
+ if (bfd_is_abs_section (os->bfd_section) || os->ignored)
+ break;
+
+ /* .tbss sections effectively have zero size. */
+ if (!IS_TBSS (os->bfd_section)
+ || bfd_link_relocatable (&link_info))
+ dotdelta = TO_ADDR (os->bfd_section->size);
+ else
+ dotdelta = 0;
+ dot += dotdelta;
+
+ if (os->update_dot_tree != 0)
+ exp_fold_tree (os->update_dot_tree, os, bfd_abs_section_ptr, &dot);
+
+ /* Update dot in the region ?
+ We only do this if the section is going to be allocated,
+ since unallocated sections do not contribute to the region's
+ overall size in memory. */
+ if (os->region != NULL
+ && (os->bfd_section->flags & (SEC_ALLOC | SEC_LOAD)))
+ {
+ os->region->current = dot;
+
+ if (check_regions)
+ /* Make sure the new address is within the region. */
+ os_region_check (os, os->region, os->addr_tree,
+ os->bfd_section->vma);
+
+ if (os->lma_region != NULL && os->lma_region != os->region
+ && ((os->bfd_section->flags & SEC_LOAD)
+ || os->align_lma_with_input))
+ {
+ os->lma_region->current = os->bfd_section->lma + dotdelta;
+
+ if (check_regions)
+ os_region_check (os, os->lma_region, NULL,
+ os->bfd_section->lma);
+ }
+ }
+ }
+ break;
+
+ case lang_constructors_statement_enum:
+ dot = lang_size_sections_1 (&constructor_list.head, current_os,
+ fill, dot, relax, check_regions);
+ break;
+
+ case lang_data_statement_enum:
+ {
+ unsigned int size = 0;
+
+ s->data_statement.output_offset = dot - current_os->bfd_section->vma;
+ s->data_statement.output_section = current_os->bfd_section;
+
+ /* We might refer to provided symbols in the expression, and
+ need to mark them as needed. */
+ exp_fold_tree (s->data_statement.exp, os,
+ bfd_abs_section_ptr, &dot);
+
+ switch (s->data_statement.type)
+ {
+ default:
+ abort ();
+ case QUAD:
+ case SQUAD:
+ size = QUAD_SIZE;
+ break;
+ case LONG:
+ size = LONG_SIZE;
+ break;
+ case SHORT:
+ size = SHORT_SIZE;
+ break;
+ case BYTE:
+ size = BYTE_SIZE;
+ break;
+ }
+ if (size < TO_SIZE ((unsigned) 1))
+ size = TO_SIZE ((unsigned) 1);
+ dot += TO_ADDR (size);
+ if (!(current_os->bfd_section->flags & SEC_FIXED_SIZE))
+ current_os->bfd_section->size
+ = TO_SIZE (dot - current_os->bfd_section->vma);
+
+ }
+ break;
+
+ case lang_reloc_statement_enum:
+ {
+ int size;
+
+ s->reloc_statement.output_offset
+ = dot - current_os->bfd_section->vma;
+ s->reloc_statement.output_section
+ = current_os->bfd_section;
+ size = bfd_get_reloc_size (s->reloc_statement.howto);
+ dot += TO_ADDR (size);
+ if (!(current_os->bfd_section->flags & SEC_FIXED_SIZE))
+ current_os->bfd_section->size
+ = TO_SIZE (dot - current_os->bfd_section->vma);
+ }
+ break;
+
+ case lang_wild_statement_enum:
+ dot = lang_size_sections_1 (&s->wild_statement.children.head,
+ current_os, fill, dot, relax,
+ check_regions);
+ break;
+
+ case lang_object_symbols_statement_enum:
+ link_info.create_object_symbols_section = current_os->bfd_section;
+ current_os->bfd_section->flags |= SEC_KEEP;
+ break;
+
+ case lang_output_statement_enum:
+ case lang_target_statement_enum:
+ break;
+
+ case lang_input_section_enum:
+ {
+ asection *i;
+
+ i = s->input_section.section;
+ if (relax)
+ {
+ bool again;
+
+ if (!bfd_relax_section (i->owner, i, &link_info, &again))
+ einfo (_("%F%P: can't relax section: %E\n"));
+ if (again)
+ *relax = true;
+ }
+ dot = size_input_section (prev, current_os, fill, &removed, dot);
+ }
+ break;
+
+ case lang_input_statement_enum:
+ break;
+
+ case lang_fill_statement_enum:
+ s->fill_statement.output_section = current_os->bfd_section;
+
+ fill = s->fill_statement.fill;
+ break;
+
+ case lang_assignment_statement_enum:
+ {
+ bfd_vma newdot = dot;
+ etree_type *tree = s->assignment_statement.exp;
+
+ expld.dataseg.relro = exp_seg_relro_none;
+
+ exp_fold_tree (tree, os, current_os->bfd_section, &newdot);
+
+ ldlang_check_relro_region (s);
+
+ expld.dataseg.relro = exp_seg_relro_none;
+
+ /* This symbol may be relative to this section. */
+ if ((tree->type.node_class == etree_provided
+ || tree->type.node_class == etree_assign)
+ && (tree->assign.dst [0] != '.'
+ || tree->assign.dst [1] != '\0'))
+ current_os->update_dot = 1;
+
+ if (!current_os->ignored)
+ {
+ if (current_os == abs_output_section)
+ {
+ /* If we don't have an output section, then just adjust
+ the default memory address. */
+ lang_memory_region_lookup (DEFAULT_MEMORY_REGION,
+ false)->current = newdot;
+ }
+ else if (newdot != dot)
+ {
+ /* Insert a pad after this statement. We can't
+ put the pad before when relaxing, in case the
+ assignment references dot. */
+ insert_pad (&s->header.next, fill, TO_SIZE (newdot - dot),
+ current_os->bfd_section, dot);
+
+ /* Don't neuter the pad below when relaxing. */
+ s = s->header.next;
+
+ /* If dot is advanced, this implies that the section
+ should have space allocated to it, unless the
+ user has explicitly stated that the section
+ should not be allocated. */
+ if (current_os->sectype != noalloc_section
+ && (current_os->sectype != noload_section
+ || (bfd_get_flavour (link_info.output_bfd)
+ == bfd_target_elf_flavour)))
+ current_os->bfd_section->flags |= SEC_ALLOC;
+ }
+ dot = newdot;
+ }
+ }
+ break;
+
+ case lang_padding_statement_enum:
+ /* If this is the first time lang_size_sections is called,
+ we won't have any padding statements. If this is the
+ second or later passes when relaxing, we should allow
+ padding to shrink. If padding is needed on this pass, it
+ will be added back in. */
+ s->padding_statement.size = 0;
+
+ /* Make sure output_offset is valid. If relaxation shrinks
+ the section and this pad isn't needed, it's possible to
+ have output_offset larger than the final size of the
+ section. bfd_set_section_contents will complain even for
+ a pad size of zero. */
+ s->padding_statement.output_offset
+ = dot - current_os->bfd_section->vma;
+ break;
+
+ case lang_group_statement_enum:
+ dot = lang_size_sections_1 (&s->group_statement.children.head,
+ current_os, fill, dot, relax,
+ check_regions);
+ break;
+
+ case lang_insert_statement_enum:
+ break;
+
+ /* We can only get here when relaxing is turned on. */
+ case lang_address_statement_enum:
+ break;
+
+ default:
+ FAIL ();
+ break;
+ }
+
+ /* If an input section doesn't fit in the current output
+ section, remove it from the list. Handle the case where we
+ have to remove an input_section statement here: there is a
+ special case to remove the first element of the list. */
+ if (link_info.non_contiguous_regions && removed)
+ {
+ /* If we removed the first element during the previous
+ iteration, override the loop assignment of prev_s. */
+ if (removed_prev_s)
+ prev_s = NULL;
+
+ if (prev_s)
+ {
+ /* If there was a real previous input section, just skip
+ the current one. */
+ prev_s->header.next=s->header.next;
+ s = prev_s;
+ removed_prev_s = false;
+ }
+ else
+ {
+ /* Remove the first input section of the list. */
+ *prev = s->header.next;
+ removed_prev_s = true;
+ }
+
+ /* Move to next element, unless we removed the head of the
+ list. */
+ if (!removed_prev_s)
+ prev = &s->header.next;
+ }
+ else
+ {
+ prev = &s->header.next;
+ removed_prev_s = false;
+ }
+ }
+ return dot;
+}
+
+/* Callback routine that is used in _bfd_elf_map_sections_to_segments.
+ The BFD library has set NEW_SEGMENT to TRUE iff it thinks that
+ CURRENT_SECTION and PREVIOUS_SECTION ought to be placed into different
+ segments. We are allowed an opportunity to override this decision. */
+
+bool
+ldlang_override_segment_assignment (struct bfd_link_info *info ATTRIBUTE_UNUSED,
+ bfd *abfd ATTRIBUTE_UNUSED,
+ asection *current_section,
+ asection *previous_section,
+ bool new_segment)
+{
+ lang_output_section_statement_type *cur;
+ lang_output_section_statement_type *prev;
+
+ /* The checks below are only necessary when the BFD library has decided
+ that the two sections ought to be placed into the same segment. */
+ if (new_segment)
+ return true;
+
+ /* Paranoia checks. */
+ if (current_section == NULL || previous_section == NULL)
+ return new_segment;
+
+ /* If this flag is set, the target never wants code and non-code
+ sections comingled in the same segment. */
+ if (config.separate_code
+ && ((current_section->flags ^ previous_section->flags) & SEC_CODE))
+ return true;
+
+ /* Find the memory regions associated with the two sections.
+ We call lang_output_section_find() here rather than scanning the list
+ of output sections looking for a matching section pointer because if
+ we have a large number of sections then a hash lookup is faster. */
+ cur = lang_output_section_find (current_section->name);
+ prev = lang_output_section_find (previous_section->name);
+
+ /* More paranoia. */
+ if (cur == NULL || prev == NULL)
+ return new_segment;
+
+ /* If the regions are different then force the sections to live in
+ different segments. See the email thread starting at the following
+ URL for the reasons why this is necessary:
+ http://sourceware.org/ml/binutils/2007-02/msg00216.html */
+ return cur->region != prev->region;
+}
+
+void
+one_lang_size_sections_pass (bool *relax, bool check_regions)
+{
+ lang_statement_iteration++;
+ if (expld.phase != lang_mark_phase_enum)
+ lang_sizing_iteration++;
+ lang_size_sections_1 (&statement_list.head, abs_output_section,
+ 0, 0, relax, check_regions);
+}
+
+static bool
+lang_size_segment (void)
+{
+ /* If XXX_SEGMENT_ALIGN XXX_SEGMENT_END pair was seen, check whether
+ a page could be saved in the data segment. */
+ seg_align_type *seg = &expld.dataseg;
+ bfd_vma first, last;
+
+ first = -seg->base & (seg->commonpagesize - 1);
+ last = seg->end & (seg->commonpagesize - 1);
+ if (first && last
+ && ((seg->base & ~(seg->commonpagesize - 1))
+ != (seg->end & ~(seg->commonpagesize - 1)))
+ && first + last <= seg->commonpagesize)
+ {
+ seg->phase = exp_seg_adjust;
+ return true;
+ }
+
+ seg->phase = exp_seg_done;
+ return false;
+}
+
+static bfd_vma
+lang_size_relro_segment_1 (void)
+{
+ seg_align_type *seg = &expld.dataseg;
+ bfd_vma relro_end, desired_end;
+ asection *sec;
+
+ /* Compute the expected PT_GNU_RELRO/PT_LOAD segment end. */
+ relro_end = (seg->relro_end + seg->relropagesize - 1) & -seg->relropagesize;
+
+ /* Adjust by the offset arg of XXX_SEGMENT_RELRO_END. */
+ desired_end = relro_end - seg->relro_offset;
+
+ /* For sections in the relro segment.. */
+ for (sec = link_info.output_bfd->section_last; sec; sec = sec->prev)
+ if ((sec->flags & SEC_ALLOC) != 0
+ && sec->vma >= seg->base
+ && sec->vma < seg->relro_end - seg->relro_offset)
+ {
+ /* Where do we want to put this section so that it ends as
+ desired? */
+ bfd_vma start, end, bump;
+
+ end = start = sec->vma;
+ if (!IS_TBSS (sec))
+ end += TO_ADDR (sec->size);
+ bump = desired_end - end;
+ /* We'd like to increase START by BUMP, but we must heed
+ alignment so the increase might be less than optimum. */
+ start += bump;
+ start &= ~(((bfd_vma) 1 << sec->alignment_power) - 1);
+ /* This is now the desired end for the previous section. */
+ desired_end = start;
+ }
+
+ seg->phase = exp_seg_relro_adjust;
+ ASSERT (desired_end >= seg->base);
+ seg->base = desired_end;
+ return relro_end;
+}
+
+static bool
+lang_size_relro_segment (bool *relax, bool check_regions)
+{
+ bool do_reset = false;
+
+ if (link_info.relro && expld.dataseg.relro_end)
+ {
+ bfd_vma data_initial_base = expld.dataseg.base;
+ bfd_vma data_relro_end = lang_size_relro_segment_1 ();
+
+ lang_reset_memory_regions ();
+ one_lang_size_sections_pass (relax, check_regions);
+
+ /* Assignments to dot, or to output section address in a user
+ script have increased padding over the original. Revert. */
+ if (expld.dataseg.relro_end > data_relro_end)
+ {
+ expld.dataseg.base = data_initial_base;
+ do_reset = true;
+ }
+ }
+ else if (lang_size_segment ())
+ do_reset = true;
+
+ return do_reset;
+}
+
+void
+lang_size_sections (bool *relax, bool check_regions)
+{
+ expld.phase = lang_allocating_phase_enum;
+ expld.dataseg.phase = exp_seg_none;
+
+ one_lang_size_sections_pass (relax, check_regions);
+
+ if (expld.dataseg.phase != exp_seg_end_seen)
+ expld.dataseg.phase = exp_seg_done;
+
+ if (expld.dataseg.phase == exp_seg_end_seen)
+ {
+ bool do_reset
+ = lang_size_relro_segment (relax, check_regions);
+
+ if (do_reset)
+ {
+ lang_reset_memory_regions ();
+ one_lang_size_sections_pass (relax, check_regions);
+ }
+
+ if (link_info.relro && expld.dataseg.relro_end)
+ {
+ link_info.relro_start = expld.dataseg.base;
+ link_info.relro_end = expld.dataseg.relro_end;
+ }
+ }
+}
+
+static lang_output_section_statement_type *current_section;
+static lang_assignment_statement_type *current_assign;
+static bool prefer_next_section;
+
+/* Worker function for lang_do_assignments. Recursiveness goes here. */
+
+static bfd_vma
+lang_do_assignments_1 (lang_statement_union_type *s,
+ lang_output_section_statement_type *current_os,
+ fill_type *fill,
+ bfd_vma dot,
+ bool *found_end)
+{
+ lang_output_section_statement_type *os = current_os;
+
+ for (; s != NULL; s = s->header.next)
+ {
+ switch (s->header.type)
+ {
+ case lang_constructors_statement_enum:
+ dot = lang_do_assignments_1 (constructor_list.head,
+ current_os, fill, dot, found_end);
+ break;
+
+ case lang_output_section_statement_enum:
+ {
+ bfd_vma newdot;
+
+ os = &s->output_section_statement;
+ os->after_end = *found_end;
+ init_opb (os->bfd_section);
+ newdot = dot;
+ if (os->bfd_section != NULL)
+ {
+ if (!os->ignored && (os->bfd_section->flags & SEC_ALLOC) != 0)
+ {
+ current_section = os;
+ prefer_next_section = false;
+ }
+ newdot = os->bfd_section->vma;
+ }
+ newdot = lang_do_assignments_1 (os->children.head,
+ os, os->fill, newdot, found_end);
+ if (!os->ignored)
+ {
+ if (os->bfd_section != NULL)
+ {
+ newdot = os->bfd_section->vma;
+
+ /* .tbss sections effectively have zero size. */
+ if (!IS_TBSS (os->bfd_section)
+ || bfd_link_relocatable (&link_info))
+ newdot += TO_ADDR (os->bfd_section->size);
+
+ if (os->update_dot_tree != NULL)
+ exp_fold_tree (os->update_dot_tree, os,
+ bfd_abs_section_ptr, &newdot);
+ }
+ dot = newdot;
+ }
+ }
+ break;
+
+ case lang_wild_statement_enum:
+
+ dot = lang_do_assignments_1 (s->wild_statement.children.head,
+ current_os, fill, dot, found_end);
+ break;
+
+ case lang_object_symbols_statement_enum:
+ case lang_output_statement_enum:
+ case lang_target_statement_enum:
+ break;
+
+ case lang_data_statement_enum:
+ exp_fold_tree (s->data_statement.exp, os, bfd_abs_section_ptr, &dot);
+ if (expld.result.valid_p)
+ {
+ s->data_statement.value = expld.result.value;
+ if (expld.result.section != NULL)
+ s->data_statement.value += expld.result.section->vma;
+ }
+ else if (expld.phase == lang_final_phase_enum)
+ einfo (_("%F%P: invalid data statement\n"));
+ {
+ unsigned int size;
+ switch (s->data_statement.type)
+ {
+ default:
+ abort ();
+ case QUAD:
+ case SQUAD:
+ size = QUAD_SIZE;
+ break;
+ case LONG:
+ size = LONG_SIZE;
+ break;
+ case SHORT:
+ size = SHORT_SIZE;
+ break;
+ case BYTE:
+ size = BYTE_SIZE;
+ break;
+ }
+ if (size < TO_SIZE ((unsigned) 1))
+ size = TO_SIZE ((unsigned) 1);
+ dot += TO_ADDR (size);
+ }
+ break;
+
+ case lang_reloc_statement_enum:
+ exp_fold_tree (s->reloc_statement.addend_exp, os,
+ bfd_abs_section_ptr, &dot);
+ if (expld.result.valid_p)
+ s->reloc_statement.addend_value = expld.result.value;
+ else if (expld.phase == lang_final_phase_enum)
+ einfo (_("%F%P: invalid reloc statement\n"));
+ dot += TO_ADDR (bfd_get_reloc_size (s->reloc_statement.howto));
+ break;
+
+ case lang_input_section_enum:
+ {
+ asection *in = s->input_section.section;
+
+ if ((in->flags & SEC_EXCLUDE) == 0)
+ dot += TO_ADDR (in->size);
+ }
+ break;
+
+ case lang_input_statement_enum:
+ break;
+
+ case lang_fill_statement_enum:
+ fill = s->fill_statement.fill;
+ break;
+
+ case lang_assignment_statement_enum:
+ current_assign = &s->assignment_statement;
+ if (current_assign->exp->type.node_class != etree_assert)
+ {
+ const char *p = current_assign->exp->assign.dst;
+
+ if (current_os == abs_output_section && p[0] == '.' && p[1] == 0)
+ prefer_next_section = true;
+
+ while (*p == '_')
+ ++p;
+ if (strcmp (p, "end") == 0)
+ *found_end = true;
+ }
+ exp_fold_tree (s->assignment_statement.exp, os,
+ (current_os->bfd_section != NULL
+ ? current_os->bfd_section : bfd_und_section_ptr),
+ &dot);
+ break;
+
+ case lang_padding_statement_enum:
+ dot += TO_ADDR (s->padding_statement.size);
+ break;
+
+ case lang_group_statement_enum:
+ dot = lang_do_assignments_1 (s->group_statement.children.head,
+ current_os, fill, dot, found_end);
+ break;
+
+ case lang_insert_statement_enum:
+ break;
+
+ case lang_address_statement_enum:
+ break;
+
+ default:
+ FAIL ();
+ break;
+ }
+ }
+ return dot;
+}
+
+void
+lang_do_assignments (lang_phase_type phase)
+{
+ bool found_end = false;
+
+ current_section = NULL;
+ prefer_next_section = false;
+ expld.phase = phase;
+ lang_statement_iteration++;
+ lang_do_assignments_1 (statement_list.head,
+ abs_output_section, NULL, 0, &found_end);
+}
+
+/* For an assignment statement outside of an output section statement,
+ choose the best of neighbouring output sections to use for values
+ of "dot". */
+
+asection *
+section_for_dot (void)
+{
+ asection *s;
+
+ /* Assignments belong to the previous output section, unless there
+ has been an assignment to "dot", in which case following
+ assignments belong to the next output section. (The assumption
+ is that an assignment to "dot" is setting up the address for the
+ next output section.) Except that past the assignment to "_end"
+ we always associate with the previous section. This exception is
+ for targets like SH that define an alloc .stack or other
+ weirdness after non-alloc sections. */
+ if (current_section == NULL || prefer_next_section)
+ {
+ lang_statement_union_type *stmt;
+ lang_output_section_statement_type *os;
+
+ for (stmt = (lang_statement_union_type *) current_assign;
+ stmt != NULL;
+ stmt = stmt->header.next)
+ if (stmt->header.type == lang_output_section_statement_enum)
+ break;
+
+ os = stmt ? &stmt->output_section_statement : NULL;
+ while (os != NULL
+ && !os->after_end
+ && (os->bfd_section == NULL
+ || (os->bfd_section->flags & SEC_EXCLUDE) != 0
+ || bfd_section_removed_from_list (link_info.output_bfd,
+ os->bfd_section)))
+ os = os->next;
+
+ if (current_section == NULL || os == NULL || !os->after_end)
+ {
+ if (os != NULL)
+ s = os->bfd_section;
+ else
+ s = link_info.output_bfd->section_last;
+ while (s != NULL
+ && ((s->flags & SEC_ALLOC) == 0
+ || (s->flags & SEC_THREAD_LOCAL) != 0))
+ s = s->prev;
+ if (s != NULL)
+ return s;
+
+ return bfd_abs_section_ptr;
+ }
+ }
+
+ s = current_section->bfd_section;
+
+ /* The section may have been stripped. */
+ while (s != NULL
+ && ((s->flags & SEC_EXCLUDE) != 0
+ || (s->flags & SEC_ALLOC) == 0
+ || (s->flags & SEC_THREAD_LOCAL) != 0
+ || bfd_section_removed_from_list (link_info.output_bfd, s)))
+ s = s->prev;
+ if (s == NULL)
+ s = link_info.output_bfd->sections;
+ while (s != NULL
+ && ((s->flags & SEC_ALLOC) == 0
+ || (s->flags & SEC_THREAD_LOCAL) != 0))
+ s = s->next;
+ if (s != NULL)
+ return s;
+
+ return bfd_abs_section_ptr;
+}
+
+/* Array of __start/__stop/.startof./.sizeof/ symbols. */
+
+static struct bfd_link_hash_entry **start_stop_syms;
+static size_t start_stop_count = 0;
+static size_t start_stop_alloc = 0;
+
+/* Give start/stop SYMBOL for SEC a preliminary definition, and add it
+ to start_stop_syms. */
+
+static void
+lang_define_start_stop (const char *symbol, asection *sec)
+{
+ struct bfd_link_hash_entry *h;
+
+ h = bfd_define_start_stop (link_info.output_bfd, &link_info, symbol, sec);
+ if (h != NULL)
+ {
+ if (start_stop_count == start_stop_alloc)
+ {
+ start_stop_alloc = 2 * start_stop_alloc + 10;
+ start_stop_syms
+ = xrealloc (start_stop_syms,
+ start_stop_alloc * sizeof (*start_stop_syms));
+ }
+ start_stop_syms[start_stop_count++] = h;
+ }
+}
+
+/* Check for input sections whose names match references to
+ __start_SECNAME or __stop_SECNAME symbols. Give the symbols
+ preliminary definitions. */
+
+static void
+lang_init_start_stop (void)
+{
+ bfd *abfd;
+ asection *s;
+ char leading_char = bfd_get_symbol_leading_char (link_info.output_bfd);
+
+ for (abfd = link_info.input_bfds; abfd != NULL; abfd = abfd->link.next)
+ for (s = abfd->sections; s != NULL; s = s->next)
+ {
+ const char *ps;
+ const char *secname = s->name;
+
+ for (ps = secname; *ps != '\0'; ps++)
+ if (!ISALNUM ((unsigned char) *ps) && *ps != '_')
+ break;
+ if (*ps == '\0')
+ {
+ char *symbol = (char *) xmalloc (10 + strlen (secname));
+
+ symbol[0] = leading_char;
+ sprintf (symbol + (leading_char != 0), "__start_%s", secname);
+ lang_define_start_stop (symbol, s);
+
+ symbol[1] = leading_char;
+ memcpy (symbol + 1 + (leading_char != 0), "__stop", 6);
+ lang_define_start_stop (symbol + 1, s);
+
+ free (symbol);
+ }
+ }
+}
+
+/* Iterate over start_stop_syms. */
+
+static void
+foreach_start_stop (void (*func) (struct bfd_link_hash_entry *))
+{
+ size_t i;
+
+ for (i = 0; i < start_stop_count; ++i)
+ func (start_stop_syms[i]);
+}
+
+/* __start and __stop symbols are only supposed to be defined by the
+ linker for orphan sections, but we now extend that to sections that
+ map to an output section of the same name. The symbols were
+ defined early for --gc-sections, before we mapped input to output
+ sections, so undo those that don't satisfy this rule. */
+
+static void
+undef_start_stop (struct bfd_link_hash_entry *h)
+{
+ if (h->ldscript_def)
+ return;
+
+ if (h->u.def.section->output_section == NULL
+ || h->u.def.section->output_section->owner != link_info.output_bfd
+ || strcmp (h->u.def.section->name,
+ h->u.def.section->output_section->name) != 0)
+ {
+ asection *sec = bfd_get_section_by_name (link_info.output_bfd,
+ h->u.def.section->name);
+ if (sec != NULL)
+ {
+ /* When there are more than one input sections with the same
+ section name, SECNAME, linker picks the first one to define
+ __start_SECNAME and __stop_SECNAME symbols. When the first
+ input section is removed by comdat group, we need to check
+ if there is still an output section with section name
+ SECNAME. */
+ asection *i;
+ for (i = sec->map_head.s; i != NULL; i = i->map_head.s)
+ if (strcmp (h->u.def.section->name, i->name) == 0)
+ {
+ h->u.def.section = i;
+ return;
+ }
+ }
+ h->type = bfd_link_hash_undefined;
+ h->u.undef.abfd = NULL;
+ if (is_elf_hash_table (link_info.hash))
+ {
+ const struct elf_backend_data *bed;
+ struct elf_link_hash_entry *eh = (struct elf_link_hash_entry *) h;
+ unsigned int was_forced = eh->forced_local;
+
+ bed = get_elf_backend_data (link_info.output_bfd);
+ (*bed->elf_backend_hide_symbol) (&link_info, eh, true);
+ if (!eh->ref_regular_nonweak)
+ h->type = bfd_link_hash_undefweak;
+ eh->def_regular = 0;
+ eh->forced_local = was_forced;
+ }
+ }
+}
+
+static void
+lang_undef_start_stop (void)
+{
+ foreach_start_stop (undef_start_stop);
+}
+
+/* Check for output sections whose names match references to
+ .startof.SECNAME or .sizeof.SECNAME symbols. Give the symbols
+ preliminary definitions. */
+
+static void
+lang_init_startof_sizeof (void)
+{
+ asection *s;
+
+ for (s = link_info.output_bfd->sections; s != NULL; s = s->next)
+ {
+ const char *secname = s->name;
+ char *symbol = (char *) xmalloc (10 + strlen (secname));
+
+ sprintf (symbol, ".startof.%s", secname);
+ lang_define_start_stop (symbol, s);
+
+ memcpy (symbol + 1, ".size", 5);
+ lang_define_start_stop (symbol + 1, s);
+ free (symbol);
+ }
+}
+
+/* Set .startof., .sizeof., __start and __stop symbols final values. */
+
+static void
+set_start_stop (struct bfd_link_hash_entry *h)
+{
+ if (h->ldscript_def
+ || h->type != bfd_link_hash_defined)
+ return;
+
+ if (h->root.string[0] == '.')
+ {
+ /* .startof. or .sizeof. symbol.
+ .startof. already has final value. */
+ if (h->root.string[2] == 'i')
+ {
+ /* .sizeof. */
+ h->u.def.value = TO_ADDR (h->u.def.section->size);
+ h->u.def.section = bfd_abs_section_ptr;
+ }
+ }
+ else
+ {
+ /* __start or __stop symbol. */
+ int has_lead = bfd_get_symbol_leading_char (link_info.output_bfd) != 0;
+
+ h->u.def.section = h->u.def.section->output_section;
+ if (h->root.string[4 + has_lead] == 'o')
+ {
+ /* __stop_ */
+ h->u.def.value = TO_ADDR (h->u.def.section->size);
+ }
+ }
+}
+
+static void
+lang_finalize_start_stop (void)
+{
+ foreach_start_stop (set_start_stop);
+}
+
+static void
+lang_symbol_tweaks (void)
+{
+ /* Give initial values for __start and __stop symbols, so that ELF
+ gc_sections will keep sections referenced by these symbols. Must
+ be done before lang_do_assignments. */
+ if (config.build_constructors)
+ lang_init_start_stop ();
+
+ /* Make __ehdr_start hidden, and set def_regular even though it is
+ likely undefined at this stage. For lang_check_relocs. */
+ if (is_elf_hash_table (link_info.hash)
+ && !bfd_link_relocatable (&link_info))
+ {
+ struct elf_link_hash_entry *h = (struct elf_link_hash_entry *)
+ bfd_link_hash_lookup (link_info.hash, "__ehdr_start",
+ false, false, true);
+
+ /* Only adjust the export class if the symbol was referenced
+ and not defined, otherwise leave it alone. */
+ if (h != NULL
+ && (h->root.type == bfd_link_hash_new
+ || h->root.type == bfd_link_hash_undefined
+ || h->root.type == bfd_link_hash_undefweak
+ || h->root.type == bfd_link_hash_common))
+ {
+ const struct elf_backend_data *bed;
+ bed = get_elf_backend_data (link_info.output_bfd);
+ (*bed->elf_backend_hide_symbol) (&link_info, h, true);
+ if (ELF_ST_VISIBILITY (h->other) != STV_INTERNAL)
+ h->other = (h->other & ~ELF_ST_VISIBILITY (-1)) | STV_HIDDEN;
+ h->def_regular = 1;
+ h->root.linker_def = 1;
+ h->root.rel_from_abs = 1;
+ }
+ }
+}
+
+static void
+lang_end (void)
+{
+ struct bfd_link_hash_entry *h;
+ bool warn;
+
+ if ((bfd_link_relocatable (&link_info) && !link_info.gc_sections)
+ || bfd_link_dll (&link_info))
+ warn = entry_from_cmdline;
+ else
+ warn = true;
+
+ /* Force the user to specify a root when generating a relocatable with
+ --gc-sections, unless --gc-keep-exported was also given. */
+ if (bfd_link_relocatable (&link_info)
+ && link_info.gc_sections
+ && !link_info.gc_keep_exported)
+ {
+ struct bfd_sym_chain *sym;
+
+ for (sym = link_info.gc_sym_list; sym != NULL; sym = sym->next)
+ {
+ h = bfd_link_hash_lookup (link_info.hash, sym->name,
+ false, false, false);
+ if (h != NULL
+ && (h->type == bfd_link_hash_defined
+ || h->type == bfd_link_hash_defweak)
+ && !bfd_is_const_section (h->u.def.section))
+ break;
+ }
+ if (!sym)
+ einfo (_("%F%P: --gc-sections requires a defined symbol root "
+ "specified by -e or -u\n"));
+ }
+
+ if (entry_symbol.name == NULL)
+ {
+ /* No entry has been specified. Look for the default entry, but
+ don't warn if we don't find it. */
+ entry_symbol.name = entry_symbol_default;
+ warn = false;
+ }
+
+ h = bfd_link_hash_lookup (link_info.hash, entry_symbol.name,
+ false, false, true);
+ if (h != NULL
+ && (h->type == bfd_link_hash_defined
+ || h->type == bfd_link_hash_defweak)
+ && h->u.def.section->output_section != NULL)
+ {
+ bfd_vma val;
+
+ val = (h->u.def.value
+ + bfd_section_vma (h->u.def.section->output_section)
+ + h->u.def.section->output_offset);
+ if (!bfd_set_start_address (link_info.output_bfd, val))
+ einfo (_("%F%P: %s: can't set start address\n"), entry_symbol.name);
+ }
+ else
+ {
+ bfd_vma val;
+ const char *send;
+
+ /* We couldn't find the entry symbol. Try parsing it as a
+ number. */
+ val = bfd_scan_vma (entry_symbol.name, &send, 0);
+ if (*send == '\0')
+ {
+ if (!bfd_set_start_address (link_info.output_bfd, val))
+ einfo (_("%F%P: can't set start address\n"));
+ }
+ /* BZ 2004952: Only use the start of the entry section for executables. */
+ else if bfd_link_executable (&link_info)
+ {
+ asection *ts;
+
+ /* Can't find the entry symbol, and it's not a number. Use
+ the first address in the text section. */
+ ts = bfd_get_section_by_name (link_info.output_bfd, entry_section);
+ if (ts != NULL)
+ {
+ if (warn)
+ einfo (_("%P: warning: cannot find entry symbol %s;"
+ " defaulting to %V\n"),
+ entry_symbol.name,
+ bfd_section_vma (ts));
+ if (!bfd_set_start_address (link_info.output_bfd,
+ bfd_section_vma (ts)))
+ einfo (_("%F%P: can't set start address\n"));
+ }
+ else
+ {
+ if (warn)
+ einfo (_("%P: warning: cannot find entry symbol %s;"
+ " not setting start address\n"),
+ entry_symbol.name);
+ }
+ }
+ else
+ {
+ if (warn)
+ einfo (_("%P: warning: cannot find entry symbol %s;"
+ " not setting start address\n"),
+ entry_symbol.name);
+ }
+ }
+}
+
+/* This is a small function used when we want to ignore errors from
+ BFD. */
+
+static void
+ignore_bfd_errors (const char *fmt ATTRIBUTE_UNUSED,
+ va_list ap ATTRIBUTE_UNUSED)
+{
+ /* Don't do anything. */
+}
+
+/* Check that the architecture of all the input files is compatible
+ with the output file. Also call the backend to let it do any
+ other checking that is needed. */
+
+static void
+lang_check (void)
+{
+ lang_input_statement_type *file;
+ bfd *input_bfd;
+ const bfd_arch_info_type *compatible;
+
+ for (file = (void *) file_chain.head;
+ file != NULL;
+ file = file->next)
+ {
+#if BFD_SUPPORTS_PLUGINS
+ /* Don't check format of files claimed by plugin. */
+ if (file->flags.claimed)
+ continue;
+#endif /* BFD_SUPPORTS_PLUGINS */
+ input_bfd = file->the_bfd;
+ compatible
+ = bfd_arch_get_compatible (input_bfd, link_info.output_bfd,
+ command_line.accept_unknown_input_arch);
+
+ /* In general it is not possible to perform a relocatable
+ link between differing object formats when the input
+ file has relocations, because the relocations in the
+ input format may not have equivalent representations in
+ the output format (and besides BFD does not translate
+ relocs for other link purposes than a final link). */
+ if (!file->flags.just_syms
+ && (bfd_link_relocatable (&link_info)
+ || link_info.emitrelocations)
+ && (compatible == NULL
+ || (bfd_get_flavour (input_bfd)
+ != bfd_get_flavour (link_info.output_bfd)))
+ && (bfd_get_file_flags (input_bfd) & HAS_RELOC) != 0)
+ {
+ einfo (_("%F%P: relocatable linking with relocations from"
+ " format %s (%pB) to format %s (%pB) is not supported\n"),
+ bfd_get_target (input_bfd), input_bfd,
+ bfd_get_target (link_info.output_bfd), link_info.output_bfd);
+ /* einfo with %F exits. */
+ }
+
+ if (compatible == NULL)
+ {
+ if (command_line.warn_mismatch)
+ einfo (_("%X%P: %s architecture of input file `%pB'"
+ " is incompatible with %s output\n"),
+ bfd_printable_name (input_bfd), input_bfd,
+ bfd_printable_name (link_info.output_bfd));
+ }
+
+ /* If the input bfd has no contents, it shouldn't set the
+ private data of the output bfd. */
+ else if (!file->flags.just_syms
+ && ((input_bfd->flags & DYNAMIC) != 0
+ || bfd_count_sections (input_bfd) != 0))
+ {
+ bfd_error_handler_type pfn = NULL;
+
+ /* If we aren't supposed to warn about mismatched input
+ files, temporarily set the BFD error handler to a
+ function which will do nothing. We still want to call
+ bfd_merge_private_bfd_data, since it may set up
+ information which is needed in the output file. */
+ if (!command_line.warn_mismatch)
+ pfn = bfd_set_error_handler (ignore_bfd_errors);
+ if (!bfd_merge_private_bfd_data (input_bfd, &link_info))
+ {
+ if (command_line.warn_mismatch)
+ einfo (_("%X%P: failed to merge target specific data"
+ " of file %pB\n"), input_bfd);
+ }
+ if (!command_line.warn_mismatch)
+ bfd_set_error_handler (pfn);
+ }
+ }
+}
+
+/* Look through all the global common symbols and attach them to the
+ correct section. The -sort-common command line switch may be used
+ to roughly sort the entries by alignment. */
+
+static void
+lang_common (void)
+{
+ if (link_info.inhibit_common_definition)
+ return;
+ if (bfd_link_relocatable (&link_info)
+ && !command_line.force_common_definition)
+ return;
+
+ if (!config.sort_common)
+ bfd_link_hash_traverse (link_info.hash, lang_one_common, NULL);
+ else
+ {
+ unsigned int power;
+
+ if (config.sort_common == sort_descending)
+ {
+ for (power = 4; power > 0; power--)
+ bfd_link_hash_traverse (link_info.hash, lang_one_common, &power);
+
+ power = 0;
+ bfd_link_hash_traverse (link_info.hash, lang_one_common, &power);
+ }
+ else
+ {
+ for (power = 0; power <= 4; power++)
+ bfd_link_hash_traverse (link_info.hash, lang_one_common, &power);
+
+ power = (unsigned int) -1;
+ bfd_link_hash_traverse (link_info.hash, lang_one_common, &power);
+ }
+ }
+}
+
+/* Place one common symbol in the correct section. */
+
+static bool
+lang_one_common (struct bfd_link_hash_entry *h, void *info)
+{
+ unsigned int power_of_two;
+ bfd_vma size;
+ asection *section;
+
+ if (h->type != bfd_link_hash_common)
+ return true;
+
+ size = h->u.c.size;
+ power_of_two = h->u.c.p->alignment_power;
+
+ if (config.sort_common == sort_descending
+ && power_of_two < *(unsigned int *) info)
+ return true;
+ else if (config.sort_common == sort_ascending
+ && power_of_two > *(unsigned int *) info)
+ return true;
+
+ section = h->u.c.p->section;
+ if (!bfd_define_common_symbol (link_info.output_bfd, &link_info, h))
+ einfo (_("%F%P: could not define common symbol `%pT': %E\n"),
+ h->root.string);
+
+ if (config.map_file != NULL)
+ {
+ static bool header_printed;
+ int len;
+ char *name;
+ char buf[32];
+
+ if (!header_printed)
+ {
+ minfo (_("\nAllocating common symbols\n"));
+ minfo (_("Common symbol size file\n\n"));
+ header_printed = true;
+ }
+
+ name = bfd_demangle (link_info.output_bfd, h->root.string,
+ DMGL_ANSI | DMGL_PARAMS);
+ if (name == NULL)
+ {
+ minfo ("%s", h->root.string);
+ len = strlen (h->root.string);
+ }
+ else
+ {
+ minfo ("%s", name);
+ len = strlen (name);
+ free (name);
+ }
+
+ if (len >= 19)
+ {
+ print_nl ();
+ len = 0;
+ }
+
+ sprintf (buf, "%" PRIx64, (uint64_t) size);
+ fprintf (config.map_file, "%*s0x%-16s", 20 - len, "", buf);
+
+ minfo ("%pB\n", section->owner);
+ }
+
+ return true;
+}
+
+/* Handle a single orphan section S, placing the orphan into an appropriate
+ output section. The effects of the --orphan-handling command line
+ option are handled here. */
+
+static void
+ldlang_place_orphan (asection *s)
+{
+ if (config.orphan_handling == orphan_handling_discard)
+ {
+ lang_output_section_statement_type *os;
+ os = lang_output_section_statement_lookup (DISCARD_SECTION_NAME, 0, 1);
+ if (os->addr_tree == NULL
+ && (bfd_link_relocatable (&link_info)
+ || (s->flags & (SEC_LOAD | SEC_ALLOC)) == 0))
+ os->addr_tree = exp_intop (0);
+ lang_add_section (&os->children, s, NULL, NULL, os);
+ }
+ else
+ {
+ lang_output_section_statement_type *os;
+ const char *name = s->name;
+ int constraint = 0;
+
+ if (config.orphan_handling == orphan_handling_error)
+ einfo (_("%X%P: error: unplaced orphan section `%pA' from `%pB'\n"),
+ s, s->owner);
+
+ if (config.unique_orphan_sections || unique_section_p (s, NULL))
+ constraint = SPECIAL;
+
+ os = ldemul_place_orphan (s, name, constraint);
+ if (os == NULL)
+ {
+ os = lang_output_section_statement_lookup (name, constraint, 1);
+ if (os->addr_tree == NULL
+ && (bfd_link_relocatable (&link_info)
+ || (s->flags & (SEC_LOAD | SEC_ALLOC)) == 0))
+ os->addr_tree = exp_intop (0);
+ lang_add_section (&os->children, s, NULL, NULL, os);
+ }
+
+ if (config.orphan_handling == orphan_handling_warn)
+ einfo (_("%P: warning: orphan section `%pA' from `%pB' being "
+ "placed in section `%s'\n"),
+ s, s->owner, os->name);
+ }
+}
+
+/* Run through the input files and ensure that every input section has
+ somewhere to go. If one is found without a destination then create
+ an input request and place it into the statement tree. */
+
+static void
+lang_place_orphans (void)
+{
+ LANG_FOR_EACH_INPUT_STATEMENT (file)
+ {
+ asection *s;
+
+ for (s = file->the_bfd->sections; s != NULL; s = s->next)
+ {
+ if (s->output_section == NULL)
+ {
+ /* This section of the file is not attached, root
+ around for a sensible place for it to go. */
+
+ if (file->flags.just_syms)
+ bfd_link_just_syms (file->the_bfd, s, &link_info);
+ else if (lang_discard_section_p (s))
+ s->output_section = bfd_abs_section_ptr;
+ else if (strcmp (s->name, "COMMON") == 0)
+ {
+ /* This is a lonely common section which must have
+ come from an archive. We attach to the section
+ with the wildcard. */
+ if (!bfd_link_relocatable (&link_info)
+ || command_line.force_common_definition)
+ {
+ if (default_common_section == NULL)
+ default_common_section
+ = lang_output_section_statement_lookup (".bss", 0, 1);
+ lang_add_section (&default_common_section->children, s,
+ NULL, NULL, default_common_section);
+ }
+ }
+ else
+ ldlang_place_orphan (s);
+ }
+ }
+ }
+}
+
+void
+lang_set_flags (lang_memory_region_type *ptr, const char *flags, int invert)
+{
+ flagword *ptr_flags;
+
+ ptr_flags = invert ? &ptr->not_flags : &ptr->flags;
+
+ while (*flags)
+ {
+ switch (*flags)
+ {
+ /* PR 17900: An exclamation mark in the attributes reverses
+ the sense of any of the attributes that follow. */
+ case '!':
+ invert = !invert;
+ ptr_flags = invert ? &ptr->not_flags : &ptr->flags;
+ break;
+
+ case 'A': case 'a':
+ *ptr_flags |= SEC_ALLOC;
+ break;
+
+ case 'R': case 'r':
+ *ptr_flags |= SEC_READONLY;
+ break;
+
+ case 'W': case 'w':
+ *ptr_flags |= SEC_DATA;
+ break;
+
+ case 'X': case 'x':
+ *ptr_flags |= SEC_CODE;
+ break;
+
+ case 'L': case 'l':
+ case 'I': case 'i':
+ *ptr_flags |= SEC_LOAD;
+ break;
+
+ default:
+ einfo (_("%F%P: invalid character %c (%d) in flags\n"),
+ *flags, *flags);
+ break;
+ }
+ flags++;
+ }
+}
+
+/* Call a function on each real input file. This function will be
+ called on an archive, but not on the elements. */
+
+void
+lang_for_each_input_file (void (*func) (lang_input_statement_type *))
+{
+ lang_input_statement_type *f;
+
+ for (f = (void *) input_file_chain.head;
+ f != NULL;
+ f = f->next_real_file)
+ if (f->flags.real)
+ func (f);
+}
+
+/* Call a function on each real file. The function will be called on
+ all the elements of an archive which are included in the link, but
+ will not be called on the archive file itself. */
+
+void
+lang_for_each_file (void (*func) (lang_input_statement_type *))
+{
+ LANG_FOR_EACH_INPUT_STATEMENT (f)
+ {
+ if (f->flags.real)
+ func (f);
+ }
+}
+
+void
+ldlang_add_file (lang_input_statement_type *entry)
+{
+ lang_statement_append (&file_chain, entry, &entry->next);
+
+ /* The BFD linker needs to have a list of all input BFDs involved in
+ a link. */
+ ASSERT (link_info.input_bfds_tail != &entry->the_bfd->link.next
+ && entry->the_bfd->link.next == NULL);
+ ASSERT (entry->the_bfd != link_info.output_bfd);
+
+ *link_info.input_bfds_tail = entry->the_bfd;
+ link_info.input_bfds_tail = &entry->the_bfd->link.next;
+ bfd_set_usrdata (entry->the_bfd, entry);
+ bfd_set_gp_size (entry->the_bfd, g_switch_value);
+
+ /* Look through the sections and check for any which should not be
+ included in the link. We need to do this now, so that we can
+ notice when the backend linker tries to report multiple
+ definition errors for symbols which are in sections we aren't
+ going to link. FIXME: It might be better to entirely ignore
+ symbols which are defined in sections which are going to be
+ discarded. This would require modifying the backend linker for
+ each backend which might set the SEC_LINK_ONCE flag. If we do
+ this, we should probably handle SEC_EXCLUDE in the same way. */
+
+ bfd_map_over_sections (entry->the_bfd, section_already_linked, entry);
+}
+
+void
+lang_add_output (const char *name, int from_script)
+{
+ /* Make -o on command line override OUTPUT in script. */
+ if (!had_output_filename || !from_script)
+ {
+ output_filename = name;
+ had_output_filename = true;
+ }
+}
+
+lang_output_section_statement_type *
+lang_enter_output_section_statement (const char *output_section_statement_name,
+ etree_type *address_exp,
+ enum section_type sectype,
+ etree_type *sectype_value,
+ etree_type *align,
+ etree_type *subalign,
+ etree_type *ebase,
+ int constraint,
+ int align_with_input)
+{
+ lang_output_section_statement_type *os;
+
+ os = lang_output_section_statement_lookup (output_section_statement_name,
+ constraint,
+ in_section_ordering ? 0 : 2);
+ if (os == NULL) /* && in_section_ordering */
+ einfo (_("%F%P:%pS: error: output section '%s' must already exist\n"),
+ NULL, output_section_statement_name);
+ current_section = os;
+
+ /* Make next things chain into subchain of this. */
+ push_stat_ptr (in_section_ordering ? &os->sort_children : &os->children);
+
+ if (in_section_ordering)
+ return os;
+
+ if (os->addr_tree == NULL)
+ os->addr_tree = address_exp;
+
+ os->sectype = sectype;
+ if (sectype == type_section || sectype == typed_readonly_section)
+ os->sectype_value = sectype_value;
+ else if (sectype == noload_section)
+ os->flags = SEC_NEVER_LOAD;
+ else
+ os->flags = SEC_NO_FLAGS;
+ os->block_value = 1;
+
+ os->align_lma_with_input = align_with_input == ALIGN_WITH_INPUT;
+ if (os->align_lma_with_input && align != NULL)
+ einfo (_("%F%P:%pS: error: align with input and explicit align specified\n"),
+ NULL);
+
+ os->subsection_alignment = subalign;
+ os->section_alignment = align;
+
+ os->load_base = ebase;
+ return os;
+}
+
+void
+lang_final (void)
+{
+ lang_output_statement_type *new_stmt;
+
+ new_stmt = new_stat (lang_output_statement, stat_ptr);
+ new_stmt->name = output_filename;
+}
+
+/* Reset the current counters in the regions. */
+
+void
+lang_reset_memory_regions (void)
+{
+ lang_memory_region_type *p = lang_memory_region_list;
+ asection *o;
+ lang_output_section_statement_type *os;
+
+ for (p = lang_memory_region_list; p != NULL; p = p->next)
+ {
+ p->current = p->origin;
+ p->last_os = NULL;
+ }
+
+ for (os = (void *) lang_os_list.head;
+ os != NULL;
+ os = os->next)
+ {
+ os->processed_vma = false;
+ os->processed_lma = false;
+ }
+
+ for (o = link_info.output_bfd->sections; o != NULL; o = o->next)
+ {
+ /* Save the last size for possible use by bfd_relax_section. */
+ o->rawsize = o->size;
+ if (!(o->flags & SEC_FIXED_SIZE))
+ o->size = 0;
+ }
+}
+
+/* Worker for lang_gc_sections_1. */
+
+static void
+gc_section_callback (lang_wild_statement_type *ptr,
+ struct wildcard_list *sec ATTRIBUTE_UNUSED,
+ asection *section,
+ lang_input_statement_type *file ATTRIBUTE_UNUSED,
+ void *data ATTRIBUTE_UNUSED)
+{
+ /* If the wild pattern was marked KEEP, the member sections
+ should be as well. */
+ if (ptr->keep_sections)
+ section->flags |= SEC_KEEP;
+}
+
+/* Iterate over sections marking them against GC. */
+
+static void
+lang_gc_sections_1 (lang_statement_union_type *s)
+{
+ for (; s != NULL; s = s->header.next)
+ {
+ switch (s->header.type)
+ {
+ case lang_wild_statement_enum:
+ walk_wild (&s->wild_statement, gc_section_callback, NULL);
+ break;
+ case lang_constructors_statement_enum:
+ lang_gc_sections_1 (constructor_list.head);
+ break;
+ case lang_output_section_statement_enum:
+ lang_gc_sections_1 (s->output_section_statement.children.head);
+ break;
+ case lang_group_statement_enum:
+ lang_gc_sections_1 (s->group_statement.children.head);
+ break;
+ default:
+ break;
+ }
+ }
+}
+
+static void
+lang_gc_sections (void)
+{
+ /* Keep all sections so marked in the link script. */
+ lang_gc_sections_1 (statement_list.head);
+
+ /* SEC_EXCLUDE is ignored when doing a relocatable link, except in
+ the special case of .stabstr debug info. (See bfd/stabs.c)
+ Twiddle the flag here, to simplify later linker code. */
+ if (bfd_link_relocatable (&link_info))
+ {
+ LANG_FOR_EACH_INPUT_STATEMENT (f)
+ {
+ asection *sec;
+#if BFD_SUPPORTS_PLUGINS
+ if (f->flags.claimed)
+ continue;
+#endif
+ for (sec = f->the_bfd->sections; sec != NULL; sec = sec->next)
+ if ((sec->flags & SEC_DEBUGGING) == 0
+ || strcmp (sec->name, ".stabstr") != 0)
+ sec->flags &= ~SEC_EXCLUDE;
+ }
+ }
+
+ if (link_info.gc_sections)
+ bfd_gc_sections (link_info.output_bfd, &link_info);
+}
+
+/* Worker for lang_find_relro_sections_1. */
+
+static void
+find_relro_section_callback (lang_wild_statement_type *ptr ATTRIBUTE_UNUSED,
+ struct wildcard_list *sec ATTRIBUTE_UNUSED,
+ asection *section,
+ lang_input_statement_type *file ATTRIBUTE_UNUSED,
+ void *data)
+{
+ /* Discarded, excluded and ignored sections effectively have zero
+ size. */
+ if (section->output_section != NULL
+ && section->output_section->owner == link_info.output_bfd
+ && (section->output_section->flags & SEC_EXCLUDE) == 0
+ && !IGNORE_SECTION (section)
+ && section->size != 0)
+ {
+ bool *has_relro_section = (bool *) data;
+ *has_relro_section = true;
+ }
+}
+
+/* Iterate over sections for relro sections. */
+
+static void
+lang_find_relro_sections_1 (lang_statement_union_type *s,
+ bool *has_relro_section)
+{
+ if (*has_relro_section)
+ return;
+
+ for (; s != NULL; s = s->header.next)
+ {
+ if (s == expld.dataseg.relro_end_stat)
+ break;
+
+ switch (s->header.type)
+ {
+ case lang_wild_statement_enum:
+ walk_wild (&s->wild_statement,
+ find_relro_section_callback,
+ has_relro_section);
+ break;
+ case lang_constructors_statement_enum:
+ lang_find_relro_sections_1 (constructor_list.head,
+ has_relro_section);
+ break;
+ case lang_output_section_statement_enum:
+ lang_find_relro_sections_1 (s->output_section_statement.children.head,
+ has_relro_section);
+ break;
+ case lang_group_statement_enum:
+ lang_find_relro_sections_1 (s->group_statement.children.head,
+ has_relro_section);
+ break;
+ default:
+ break;
+ }
+ }
+}
+
+static void
+lang_find_relro_sections (void)
+{
+ bool has_relro_section = false;
+
+ /* Check all sections in the link script. */
+
+ lang_find_relro_sections_1 (expld.dataseg.relro_start_stat,
+ &has_relro_section);
+
+ if (!has_relro_section)
+ link_info.relro = false;
+}
+
+/* Relax all sections until bfd_relax_section gives up. */
+
+void
+lang_relax_sections (bool need_layout)
+{
+ /* NB: Also enable relaxation to layout sections for DT_RELR. */
+ if (RELAXATION_ENABLED || link_info.enable_dt_relr)
+ {
+ /* We may need more than one relaxation pass. */
+ int i = link_info.relax_pass;
+
+ /* The backend can use it to determine the current pass. */
+ link_info.relax_pass = 0;
+
+ while (i--)
+ {
+ /* Keep relaxing until bfd_relax_section gives up. */
+ bool relax_again;
+
+ link_info.relax_trip = -1;
+ do
+ {
+ link_info.relax_trip++;
+
+ /* Note: pe-dll.c does something like this also. If you find
+ you need to change this code, you probably need to change
+ pe-dll.c also. DJ */
+
+ /* Do all the assignments with our current guesses as to
+ section sizes. */
+ lang_do_assignments (lang_assigning_phase_enum);
+
+ /* We must do this after lang_do_assignments, because it uses
+ size. */
+ lang_reset_memory_regions ();
+
+ /* Perform another relax pass - this time we know where the
+ globals are, so can make a better guess. */
+ relax_again = false;
+ lang_size_sections (&relax_again, false);
+ }
+ while (relax_again);
+
+ link_info.relax_pass++;
+ }
+ need_layout = true;
+ }
+
+ if (need_layout)
+ {
+ /* Final extra sizing to report errors. */
+ lang_do_assignments (lang_assigning_phase_enum);
+ lang_reset_memory_regions ();
+ lang_size_sections (NULL, true);
+ }
+}
+
+#if BFD_SUPPORTS_PLUGINS
+/* Find the insert point for the plugin's replacement files. We
+ place them after the first claimed real object file, or if the
+ first claimed object is an archive member, after the last real
+ object file immediately preceding the archive. In the event
+ no objects have been claimed at all, we return the first dummy
+ object file on the list as the insert point; that works, but
+ the callee must be careful when relinking the file_chain as it
+ is not actually on that chain, only the statement_list and the
+ input_file list; in that case, the replacement files must be
+ inserted at the head of the file_chain. */
+
+static lang_input_statement_type *
+find_replacements_insert_point (bool *before)
+{
+ lang_input_statement_type *claim1, *lastobject;
+ lastobject = (void *) input_file_chain.head;
+ for (claim1 = (void *) file_chain.head;
+ claim1 != NULL;
+ claim1 = claim1->next)
+ {
+ if (claim1->flags.claimed)
+ {
+ *before = claim1->flags.claim_archive;
+ return claim1->flags.claim_archive ? lastobject : claim1;
+ }
+ /* Update lastobject if this is a real object file. */
+ if (claim1->the_bfd != NULL && claim1->the_bfd->my_archive == NULL)
+ lastobject = claim1;
+ }
+ /* No files were claimed by the plugin. Choose the last object
+ file found on the list (maybe the first, dummy entry) as the
+ insert point. */
+ *before = false;
+ return lastobject;
+}
+
+/* Find where to insert ADD, an archive element or shared library
+ added during a rescan. */
+
+static lang_input_statement_type **
+find_rescan_insertion (lang_input_statement_type *add)
+{
+ bfd *add_bfd = add->the_bfd;
+ lang_input_statement_type *f;
+ lang_input_statement_type *last_loaded = NULL;
+ lang_input_statement_type *before = NULL;
+ lang_input_statement_type **iter = NULL;
+
+ if (add_bfd->my_archive != NULL)
+ add_bfd = add_bfd->my_archive;
+
+ /* First look through the input file chain, to find an object file
+ before the one we've rescanned. Normal object files always
+ appear on both the input file chain and the file chain, so this
+ lets us get quickly to somewhere near the correct place on the
+ file chain if it is full of archive elements. Archives don't
+ appear on the file chain, but if an element has been extracted
+ then their input_statement->next points at it. */
+ for (f = (void *) input_file_chain.head;
+ f != NULL;
+ f = f->next_real_file)
+ {
+ if (f->the_bfd == add_bfd)
+ {
+ before = last_loaded;
+ if (f->next != NULL)
+ return &f->next->next;
+ }
+ if (f->the_bfd != NULL && f->next != NULL)
+ last_loaded = f;
+ }
+
+ for (iter = before ? &before->next : &file_chain.head->input_statement.next;
+ *iter != NULL;
+ iter = &(*iter)->next)
+ if (!(*iter)->flags.claim_archive
+ && (*iter)->the_bfd->my_archive == NULL)
+ break;
+
+ return iter;
+}
+
+/* Detach new nodes added to DESTLIST since the time ORIGLIST
+ was taken as a copy of it and leave them in ORIGLIST. */
+
+static void
+lang_list_remove_tail (lang_statement_list_type *destlist,
+ lang_statement_list_type *origlist)
+{
+ union lang_statement_union **savetail;
+ /* Check that ORIGLIST really is an earlier state of DESTLIST. */
+ ASSERT (origlist->head == destlist->head);
+ savetail = origlist->tail;
+ origlist->head = *(savetail);
+ origlist->tail = destlist->tail;
+ destlist->tail = savetail;
+ *savetail = NULL;
+}
+
+static lang_statement_union_type **
+find_next_input_statement (lang_statement_union_type **s)
+{
+ for ( ; *s; s = &(*s)->header.next)
+ {
+ lang_statement_union_type **t;
+ switch ((*s)->header.type)
+ {
+ case lang_input_statement_enum:
+ return s;
+ case lang_wild_statement_enum:
+ t = &(*s)->wild_statement.children.head;
+ break;
+ case lang_group_statement_enum:
+ t = &(*s)->group_statement.children.head;
+ break;
+ case lang_output_section_statement_enum:
+ t = &(*s)->output_section_statement.children.head;
+ break;
+ default:
+ continue;
+ }
+ t = find_next_input_statement (t);
+ if (*t)
+ return t;
+ }
+ return s;
+}
+#endif /* BFD_SUPPORTS_PLUGINS */
+
+/* Insert SRCLIST into DESTLIST after given element by chaining
+ on FIELD as the next-pointer. (Counterintuitively does not need
+ a pointer to the actual after-node itself, just its chain field.) */
+
+static void
+lang_list_insert_after (lang_statement_list_type *destlist,
+ lang_statement_list_type *srclist,
+ lang_statement_union_type **field)
+{
+ *(srclist->tail) = *field;
+ *field = srclist->head;
+ if (destlist->tail == field)
+ destlist->tail = srclist->tail;
+}
+
+/* Add NAME to the list of garbage collection entry points. */
+
+void
+lang_add_gc_name (const char *name)
+{
+ struct bfd_sym_chain *sym;
+
+ if (name == NULL)
+ return;
+
+ sym = stat_alloc (sizeof (*sym));
+
+ sym->next = link_info.gc_sym_list;
+ sym->name = name;
+ link_info.gc_sym_list = sym;
+}
+
+/* Check relocations. */
+
+static void
+lang_check_relocs (void)
+{
+ if (link_info.check_relocs_after_open_input)
+ {
+ bfd *abfd;
+
+ for (abfd = link_info.input_bfds;
+ abfd != (bfd *) NULL; abfd = abfd->link.next)
+ if (!bfd_link_check_relocs (abfd, &link_info))
+ {
+ /* No object output, fail return. */
+ config.make_executable = false;
+ /* Note: we do not abort the loop, but rather
+ continue the scan in case there are other
+ bad relocations to report. */
+ }
+ }
+}
+
+/* Look through all output sections looking for places where we can
+ propagate forward the lma region. */
+
+static void
+lang_propagate_lma_regions (void)
+{
+ lang_output_section_statement_type *os;
+
+ for (os = (void *) lang_os_list.head;
+ os != NULL;
+ os = os->next)
+ {
+ if (os->prev != NULL
+ && os->lma_region == NULL
+ && os->load_base == NULL
+ && os->addr_tree == NULL
+ && os->region == os->prev->region)
+ os->lma_region = os->prev->lma_region;
+ }
+}
+
+static void
+warn_non_contiguous_discards (void)
+{
+ LANG_FOR_EACH_INPUT_STATEMENT (file)
+ {
+ if ((file->the_bfd->flags & (BFD_LINKER_CREATED | DYNAMIC)) != 0
+ || file->flags.just_syms)
+ continue;
+
+ for (asection *s = file->the_bfd->sections; s != NULL; s = s->next)
+ if (s->output_section == NULL
+ && (s->flags & SEC_LINKER_CREATED) == 0)
+ einfo (_("%P: warning: --enable-non-contiguous-regions "
+ "discards section `%pA' from `%pB'\n"),
+ s, file->the_bfd);
+ }
+}
+
+static void
+reset_one_wild (lang_statement_union_type *statement)
+{
+ if (statement->header.type == lang_wild_statement_enum)
+ {
+ lang_wild_statement_type *stmt = &statement->wild_statement;
+ lang_list_init (&stmt->matching_sections);
+ }
+}
+
+static void
+reset_resolved_wilds (void)
+{
+ lang_for_each_statement (reset_one_wild);
+}
+
+/* For each output section statement, splice any entries on the
+ sort_children list before the first wild statement on the children
+ list. */
+
+static void
+lang_os_merge_sort_children (void)
+{
+ lang_output_section_statement_type *os;
+ for (os = (void *) lang_os_list.head; os != NULL; os = os->next)
+ {
+ if (os->sort_children.head != NULL)
+ {
+ lang_statement_union_type **where;
+ for (where = &os->children.head;
+ *where != NULL;
+ where = &(*where)->header.next)
+ if ((*where)->header.type == lang_wild_statement_enum)
+ break;
+ lang_list_insert_after (&os->children, &os->sort_children, where);
+ }
+ }
+}
+
+void
+lang_process (void)
+{
+ lang_os_merge_sort_children ();
+
+ /* Finalize dynamic list. */
+ if (link_info.dynamic_list)
+ lang_finalize_version_expr_head (&link_info.dynamic_list->head);
+
+ current_target = default_target;
+
+ /* Open the output file. */
+ lang_for_each_statement (ldlang_open_output);
+ init_opb (NULL);
+
+ ldemul_create_output_section_statements ();
+
+ /* Add to the hash table all undefineds on the command line. */
+ lang_place_undefineds ();
+
+ if (!bfd_section_already_linked_table_init ())
+ einfo (_("%F%P: can not create hash table: %E\n"));
+
+ /* A first pass through the memory regions ensures that if any region
+ references a symbol for its origin or length then this symbol will be
+ added to the symbol table. Having these symbols in the symbol table
+ means that when we call open_input_bfds PROVIDE statements will
+ trigger to provide any needed symbols. The regions origins and
+ lengths are not assigned as a result of this call. */
+ lang_do_memory_regions (false);
+
+ /* Create a bfd for each input file. */
+ current_target = default_target;
+ lang_statement_iteration++;
+ open_input_bfds (statement_list.head, NULL, OPEN_BFD_NORMAL);
+
+ /* Now that open_input_bfds has processed assignments and provide
+ statements we can give values to symbolic origin/length now. */
+ lang_do_memory_regions (true);
+
+ ldemul_before_plugin_all_symbols_read ();
+
+#if BFD_SUPPORTS_PLUGINS
+ if (link_info.lto_plugin_active)
+ {
+ lang_statement_list_type added;
+ lang_statement_list_type files, inputfiles;
+
+ /* Now all files are read, let the plugin(s) decide if there
+ are any more to be added to the link before we call the
+ emulation's after_open hook. We create a private list of
+ input statements for this purpose, which we will eventually
+ insert into the global statement list after the first claimed
+ file. */
+ added = *stat_ptr;
+ /* We need to manipulate all three chains in synchrony. */
+ files = file_chain;
+ inputfiles = input_file_chain;
+ if (plugin_call_all_symbols_read ())
+ einfo (_("%F%P: %s: plugin reported error after all symbols read\n"),
+ plugin_error_plugin ());
+ link_info.lto_all_symbols_read = true;
+ /* Open any newly added files, updating the file chains. */
+ plugin_undefs = link_info.hash->undefs_tail;
+ lang_output_section_statement_type *last_os = NULL;
+ if (lang_os_list.head != NULL)
+ last_os = ((lang_output_section_statement_type *)
+ ((char *) lang_os_list.tail
+ - offsetof (lang_output_section_statement_type, next)));
+ open_input_bfds (*added.tail, last_os, OPEN_BFD_NORMAL);
+ if (plugin_undefs == link_info.hash->undefs_tail)
+ plugin_undefs = NULL;
+ /* Restore the global list pointer now they have all been added. */
+ lang_list_remove_tail (stat_ptr, &added);
+ /* And detach the fresh ends of the file lists. */
+ lang_list_remove_tail (&file_chain, &files);
+ lang_list_remove_tail (&input_file_chain, &inputfiles);
+ /* Were any new files added? */
+ if (added.head != NULL)
+ {
+ /* If so, we will insert them into the statement list immediately
+ after the first input file that was claimed by the plugin,
+ unless that file was an archive in which case it is inserted
+ immediately before. */
+ bool before;
+ lang_statement_union_type **prev;
+ plugin_insert = find_replacements_insert_point (&before);
+ /* If a plugin adds input files without having claimed any, we
+ don't really have a good idea where to place them. Just putting
+ them at the start or end of the list is liable to leave them
+ outside the crtbegin...crtend range. */
+ ASSERT (plugin_insert != NULL);
+ /* Splice the new statement list into the old one. */
+ prev = &plugin_insert->header.next;
+ if (before)
+ {
+ prev = find_next_input_statement (prev);
+ if (*prev != (void *) plugin_insert->next_real_file)
+ {
+ /* We didn't find the expected input statement.
+ Fall back to adding after plugin_insert. */
+ prev = &plugin_insert->header.next;
+ }
+ }
+ lang_list_insert_after (stat_ptr, &added, prev);
+ /* Likewise for the file chains. */
+ lang_list_insert_after (&input_file_chain, &inputfiles,
+ (void *) &plugin_insert->next_real_file);
+ /* We must be careful when relinking file_chain; we may need to
+ insert the new files at the head of the list if the insert
+ point chosen is the dummy first input file. */
+ if (plugin_insert->filename)
+ lang_list_insert_after (&file_chain, &files,
+ (void *) &plugin_insert->next);
+ else
+ lang_list_insert_after (&file_chain, &files, &file_chain.head);
+
+ /* Rescan archives in case new undefined symbols have appeared. */
+ files = file_chain;
+ lang_statement_iteration++;
+ open_input_bfds (statement_list.head, NULL, OPEN_BFD_RESCAN);
+ lang_list_remove_tail (&file_chain, &files);
+ while (files.head != NULL)
+ {
+ lang_input_statement_type **insert;
+ lang_input_statement_type **iter, *temp;
+ bfd *my_arch;
+
+ insert = find_rescan_insertion (&files.head->input_statement);
+ /* All elements from an archive can be added at once. */
+ iter = &files.head->input_statement.next;
+ my_arch = files.head->input_statement.the_bfd->my_archive;
+ if (my_arch != NULL)
+ for (; *iter != NULL; iter = &(*iter)->next)
+ if ((*iter)->the_bfd->my_archive != my_arch)
+ break;
+ temp = *insert;
+ *insert = &files.head->input_statement;
+ files.head = (lang_statement_union_type *) *iter;
+ *iter = temp;
+ if (file_chain.tail == (lang_statement_union_type **) insert)
+ file_chain.tail = (lang_statement_union_type **) iter;
+ if (my_arch != NULL)
+ {
+ lang_input_statement_type *parent = bfd_usrdata (my_arch);
+ if (parent != NULL)
+ parent->next = (lang_input_statement_type *)
+ ((char *) iter
+ - offsetof (lang_input_statement_type, next));
+ }
+ }
+ }
+ }
+ else
+#endif /* BFD_SUPPORTS_PLUGINS */
+ if (bfd_link_relocatable (&link_info))
+ {
+ /* Check if .gnu_object_only section should be created. */
+ bfd *p;
+ int object_type;
+
+ object_type = 0;
+ for (p = link_info.input_bfds; p != (bfd *) NULL; p = p->link.next)
+ {
+ enum bfd_lto_object_type lto_type = bfd_get_lto_type (p);
+ /* NB: Treat fat IR object as IR object here. */
+ if (lto_type == lto_fat_ir_object)
+ lto_type = lto_slim_ir_object;
+ object_type |= 1 << lto_type;
+ if ((object_type & (1 << lto_mixed_object)) != 0
+ || ((object_type
+ & (1 << lto_non_ir_object
+ | 1 << lto_slim_ir_object))
+ == (1 << lto_non_ir_object | 1 << lto_slim_ir_object)))
+ {
+ config.emit_gnu_object_only = true;
+ break;
+ }
+ }
+
+ if (verbose
+ && (cmdline_object_only_file_list.head
+ || cmdline_object_only_archive_list.head))
+ {
+ info_msg (_("Object-only input files:\n "));
+ print_cmdline_list (cmdline_object_only_file_list.head);
+ print_cmdline_list (cmdline_object_only_archive_list.head);
+ }
+ }
+
+ struct bfd_sym_chain **sym = &link_info.gc_sym_list;
+ while (*sym)
+ sym = &(*sym)->next;
+
+ *sym = &entry_symbol;
+
+ if (entry_symbol.name == NULL)
+ {
+ *sym = ldlang_undef_chain_list_head;
+
+ /* entry_symbol is normally initialised by an ENTRY definition in the
+ linker script or the -e command line option. But if neither of
+ these have been used, the target specific backend may still have
+ provided an entry symbol via a call to lang_default_entry().
+ Unfortunately this value will not be processed until lang_end()
+ is called, long after this function has finished. So detect this
+ case here and add the target's entry symbol to the list of starting
+ points for garbage collection resolution. */
+ lang_add_gc_name (entry_symbol_default);
+ }
+
+ lang_add_gc_name (link_info.init_function);
+ lang_add_gc_name (link_info.fini_function);
+
+ ldemul_after_open ();
+ if (config.map_file != NULL)
+ lang_print_asneeded ();
+
+ ldlang_open_ctf ();
+
+ bfd_section_already_linked_table_free ();
+
+ /* Make sure that we're not mixing architectures. We call this
+ after all the input files have been opened, but before we do any
+ other processing, so that any operations merge_private_bfd_data
+ does on the output file will be known during the rest of the
+ link. */
+ lang_check ();
+
+ /* Handle .exports instead of a version script if we're told to do so. */
+ if (command_line.version_exports_section)
+ lang_do_version_exports_section ();
+
+ /* Build all sets based on the information gathered from the input
+ files. */
+ ldctor_build_sets ();
+
+ lang_symbol_tweaks ();
+
+ /* PR 13683: We must rerun the assignments prior to running garbage
+ collection in order to make sure that all symbol aliases are resolved. */
+ lang_do_assignments (lang_mark_phase_enum);
+ expld.phase = lang_first_phase_enum;
+
+ /* Size up the common data. */
+ lang_common ();
+
+ if (0)
+ debug_prefix_tree ();
+
+ resolve_wilds ();
+
+ /* Remove unreferenced sections if asked to. */
+ lang_gc_sections ();
+
+ lang_mark_undefineds ();
+
+ /* Check relocations. */
+ lang_check_relocs ();
+
+ ldemul_after_check_relocs ();
+
+ /* There might have been new sections created (e.g. as result of
+ checking relocs to need a .got, or suchlike), so to properly order
+ them into our lists of matching sections reset them here. */
+ reset_resolved_wilds ();
+ resolve_wilds ();
+
+ /* Update wild statements in case the user gave --sort-section.
+ Note how the option might have come after the linker script and
+ so couldn't have been set when the wild statements were created. */
+ update_wild_statements (statement_list.head);
+
+ /* Run through the contours of the script and attach input sections
+ to the correct output sections. */
+ lang_statement_iteration++;
+ map_input_to_output_sections (statement_list.head, NULL, NULL);
+
+ /* Start at the statement immediately after the special abs_section
+ output statement, so that it isn't reordered. */
+ process_insert_statements (&lang_os_list.head->header.next);
+
+ ldemul_before_place_orphans ();
+
+ /* Find any sections not attached explicitly and handle them. */
+ lang_place_orphans ();
+
+ if (!bfd_link_relocatable (&link_info))
+ {
+ asection *found;
+
+ /* Merge SEC_MERGE sections. This has to be done after GC of
+ sections, so that GCed sections are not merged, but before
+ assigning dynamic symbols, since removing whole input sections
+ is hard then. */
+ if (!bfd_merge_sections (link_info.output_bfd, &link_info))
+ einfo (_("%F%P: bfd_merge_sections failed: %E\n"));
+
+ /* Look for a text section and set the readonly attribute in it. */
+ found = bfd_get_section_by_name (link_info.output_bfd, ".text");
+
+ if (found != NULL)
+ {
+ if (config.text_read_only)
+ found->flags |= SEC_READONLY;
+ else
+ found->flags &= ~SEC_READONLY;
+ }
+ }
+
+ /* Merge together CTF sections. After this, only the symtab-dependent
+ function and data object sections need adjustment. */
+ lang_merge_ctf ();
+
+ /* Emit the CTF, iff the emulation doesn't need to do late emission after
+ examining things laid out late, like the strtab. */
+ lang_write_ctf (0);
+
+ /* Copy forward lma regions for output sections in same lma region. */
+ lang_propagate_lma_regions ();
+
+ /* Defining __start/__stop symbols early for --gc-sections to work
+ around a glibc build problem can result in these symbols being
+ defined when they should not be. Fix them now. */
+ if (config.build_constructors)
+ lang_undef_start_stop ();
+
+ /* Define .startof./.sizeof. symbols with preliminary values before
+ dynamic symbols are created. */
+ if (!bfd_link_relocatable (&link_info))
+ lang_init_startof_sizeof ();
+
+ /* Do anything special before sizing sections. This is where ELF
+ and other back-ends size dynamic sections. */
+ ldemul_before_allocation ();
+
+ /* We must record the program headers before we try to fix the
+ section positions, since they will affect SIZEOF_HEADERS. */
+ lang_record_phdrs ();
+
+ /* Check relro sections. */
+ if (link_info.relro && !bfd_link_relocatable (&link_info))
+ lang_find_relro_sections ();
+
+ /* Size up the sections. */
+ lang_size_sections (NULL, !RELAXATION_ENABLED);
+
+ /* See if anything special should be done now we know how big
+ everything is. This is where relaxation is done. */
+ ldemul_after_allocation ();
+
+ /* Fix any __start, __stop, .startof. or .sizeof. symbols. */
+ lang_finalize_start_stop ();
+
+ /* Do all the assignments again, to report errors. Assignment
+ statements are processed multiple times, updating symbols; In
+ open_input_bfds, lang_do_assignments, and lang_size_sections.
+ Since lang_relax_sections calls lang_do_assignments, symbols are
+ also updated in ldemul_after_allocation. */
+ lang_do_assignments (lang_final_phase_enum);
+
+ ldemul_finish ();
+
+ /* Convert absolute symbols to section relative. */
+ ldexp_finalize_syms ();
+
+ /* Make sure that the section addresses make sense. */
+ if (command_line.check_section_addresses)
+ lang_check_section_addresses ();
+
+ if (link_info.non_contiguous_regions
+ && link_info.non_contiguous_regions_warnings)
+ warn_non_contiguous_discards ();
+
+ /* Check any required symbols are known. */
+ ldlang_check_require_defined_symbols ();
+
+ lang_end ();
+}
+
+void
+lang_add_version_string (void)
+{
+ if (! enable_linker_version)
+ return;
+
+ const char * str = "GNU ld ";
+ int len = strlen (str);
+ int i;
+
+ for (i = 0 ; i < len ; i++)
+ lang_add_data (BYTE, exp_intop (str[i]));
+
+ str = BFD_VERSION_STRING;
+ len = strlen (str);
+
+ for (i = 0 ; i < len ; i++)
+ lang_add_data (BYTE, exp_intop (str[i]));
+
+ lang_add_data (BYTE, exp_intop ('\0'));
+}
+
+/* EXPORTED TO YACC */
+
+void
+lang_add_wild (struct wildcard_spec *filespec,
+ struct wildcard_list *section_list,
+ bool keep_sections)
+{
+ struct wildcard_list *curr, *next;
+ lang_wild_statement_type *new_stmt;
+ bool any_specs_sorted = false;
+
+ /* Reverse the list as the parser puts it back to front. */
+ for (curr = section_list, section_list = NULL;
+ curr != NULL;
+ section_list = curr, curr = next)
+ {
+ if (curr->spec.sorted != none && curr->spec.sorted != by_none)
+ any_specs_sorted = true;
+ next = curr->next;
+ curr->next = section_list;
+ }
+
+ if (filespec != NULL && filespec->name != NULL)
+ {
+ if (strcmp (filespec->name, "*") == 0)
+ filespec->name = NULL;
+ else if (!wildcardp (filespec->name))
+ lang_has_input_file = true;
+ }
+
+ new_stmt = new_stat (lang_wild_statement, stat_ptr);
+ new_stmt->filename = NULL;
+ new_stmt->filenames_sorted = false;
+ new_stmt->any_specs_sorted = any_specs_sorted;
+ new_stmt->section_flag_list = NULL;
+ new_stmt->exclude_name_list = NULL;
+ if (filespec != NULL)
+ {
+ new_stmt->filename = filespec->name;
+ new_stmt->filenames_sorted = (filespec->sorted == by_name || filespec->reversed);
+ new_stmt->section_flag_list = filespec->section_flag_list;
+ new_stmt->exclude_name_list = filespec->exclude_name_list;
+ new_stmt->filenames_reversed = filespec->reversed;
+ }
+ new_stmt->section_list = section_list;
+ new_stmt->keep_sections = keep_sections;
+ lang_list_init (&new_stmt->children);
+ lang_list_init (&new_stmt->matching_sections);
+ analyze_walk_wild_section_handler (new_stmt);
+ if (0)
+ {
+ printf ("wild %s(", new_stmt->filename ? new_stmt->filename : "*");
+ for (curr = new_stmt->section_list; curr; curr = curr->next)
+ printf ("%s ", curr->spec.name ? curr->spec.name : "*");
+ printf (")\n");
+ }
+}
+
+void
+lang_section_start (const char *name, etree_type *address,
+ const segment_type *segment)
+{
+ lang_address_statement_type *ad;
+
+ ad = new_stat (lang_address_statement, stat_ptr);
+ ad->section_name = name;
+ ad->address = address;
+ ad->segment = segment;
+}
+
+/* Set the start symbol to NAME. CMDLINE is nonzero if this is called
+ because of a -e argument on the command line, or zero if this is
+ called by ENTRY in a linker script. Command line arguments take
+ precedence. */
+
+void
+lang_add_entry (const char *name, bool cmdline)
+{
+ if (entry_symbol.name == NULL
+ || cmdline
+ || !entry_from_cmdline)
+ {
+ entry_symbol.name = name;
+ entry_from_cmdline = cmdline;
+ }
+}
+
+/* Set the default start symbol to NAME. .em files should use this,
+ not lang_add_entry, to override the use of "start" if neither the
+ linker script nor the command line specifies an entry point. NAME
+ must be permanently allocated. */
+void
+lang_default_entry (const char *name)
+{
+ entry_symbol_default = name;
+}
+
+void
+lang_add_target (const char *name)
+{
+ lang_target_statement_type *new_stmt;
+
+ new_stmt = new_stat (lang_target_statement, stat_ptr);
+ new_stmt->target = name;
+}
+
+void
+lang_add_map (const char *name)
+{
+ while (*name)
+ {
+ switch (*name)
+ {
+ case 'F':
+ map_option_f = true;
+ break;
+ }
+ name++;
+ }
+}
+
+void
+lang_add_fill (fill_type *fill)
+{
+ lang_fill_statement_type *new_stmt;
+
+ new_stmt = new_stat (lang_fill_statement, stat_ptr);
+ new_stmt->fill = fill;
+}
+
+void
+lang_add_data (int type, union etree_union *exp)
+{
+ lang_data_statement_type *new_stmt;
+
+ new_stmt = new_stat (lang_data_statement, stat_ptr);
+ new_stmt->exp = exp;
+ new_stmt->type = type;
+}
+
+void
+lang_add_string (const char *s)
+{
+ bfd_vma len = strlen (s);
+ bfd_vma i;
+ bool escape = false;
+
+ /* Add byte expressions until end of string. */
+ for (i = 0 ; i < len; i++)
+ {
+ char c = *s++;
+
+ if (escape)
+ {
+ switch (c)
+ {
+ default:
+ /* Ignore the escape. */
+ break;
+
+ case 'n': c = '\n'; break;
+ case 'r': c = '\r'; break;
+ case 't': c = '\t'; break;
+
+ case '0':
+ case '1':
+ case '2':
+ case '3':
+ case '4':
+ case '5':
+ case '6':
+ case '7':
+ /* We have an octal number. */
+ {
+ unsigned int value = c - '0';
+
+ c = *s;
+ if ((c >= '0') && (c <= '7'))
+ {
+ value <<= 3;
+ value += (c - '0');
+ i++;
+ s++;
+
+ c = *s;
+ if ((c >= '0') && (c <= '7'))
+ {
+ value <<= 3;
+ value += (c - '0');
+ i++;
+ s++;
+ }
+ }
+
+ if (value > 0xff)
+ {
+ /* octal: \777 is treated as '\077' + '7' */
+ value >>= 3;
+ i--;
+ s--;
+ }
+
+ c = value;
+ }
+ break;
+ }
+
+ lang_add_data (BYTE, exp_intop (c));
+ escape = false;
+ }
+ else
+ {
+ if (c == '\\')
+ escape = true;
+ else
+ lang_add_data (BYTE, exp_intop (c));
+ }
+ }
+
+ /* Remeber to terminate the string. */
+ lang_add_data (BYTE, exp_intop (0));
+}
+
+/* Create a new reloc statement. RELOC is the BFD relocation type to
+ generate. HOWTO is the corresponding howto structure (we could
+ look this up, but the caller has already done so). SECTION is the
+ section to generate a reloc against, or NAME is the name of the
+ symbol to generate a reloc against. Exactly one of SECTION and
+ NAME must be NULL. ADDEND is an expression for the addend. */
+
+void
+lang_add_reloc (bfd_reloc_code_real_type reloc,
+ reloc_howto_type *howto,
+ asection *section,
+ const char *name,
+ union etree_union *addend)
+{
+ lang_reloc_statement_type *p = new_stat (lang_reloc_statement, stat_ptr);
+
+ p->reloc = reloc;
+ p->howto = howto;
+ p->section = section;
+ p->name = name;
+ p->addend_exp = addend;
+
+ p->addend_value = 0;
+ p->output_section = NULL;
+ p->output_offset = 0;
+}
+
+lang_assignment_statement_type *
+lang_add_assignment (etree_type *exp)
+{
+ lang_assignment_statement_type *new_stmt;
+
+ new_stmt = new_stat (lang_assignment_statement, stat_ptr);
+ new_stmt->exp = exp;
+ return new_stmt;
+}
+
+void
+lang_add_attribute (enum statement_enum attribute)
+{
+ new_statement (attribute, sizeof (lang_statement_header_type), stat_ptr);
+}
+
+void
+lang_startup (const char *name)
+{
+ if (first_file->filename != NULL)
+ {
+ einfo (_("%F%P: multiple STARTUP files\n"));
+ }
+ first_file->filename = name;
+ first_file->local_sym_name = name;
+ first_file->flags.real = true;
+}
+
+void
+lang_float (bool maybe)
+{
+ lang_float_flag = maybe;
+}
+
+
+/* Work out the load- and run-time regions from a script statement, and
+ store them in *LMA_REGION and *REGION respectively.
+
+ MEMSPEC is the name of the run-time region, or the value of
+ DEFAULT_MEMORY_REGION if the statement didn't specify one.
+ LMA_MEMSPEC is the name of the load-time region, or null if the
+ statement didn't specify one.HAVE_LMA_P is TRUE if the statement
+ had an explicit load address.
+
+ It is an error to specify both a load region and a load address. */
+
+static void
+lang_get_regions (lang_memory_region_type **region,
+ lang_memory_region_type **lma_region,
+ const char *memspec,
+ const char *lma_memspec,
+ bool have_lma,
+ bool have_vma)
+{
+ *lma_region = lang_memory_region_lookup (lma_memspec, false);
+
+ /* If no runtime region or VMA has been specified, but the load region
+ has been specified, then use the load region for the runtime region
+ as well. */
+ if (lma_memspec != NULL
+ && !have_vma
+ && strcmp (memspec, DEFAULT_MEMORY_REGION) == 0)
+ *region = *lma_region;
+ else
+ *region = lang_memory_region_lookup (memspec, false);
+
+ if (have_lma && lma_memspec != 0)
+ einfo (_("%X%P:%pS: section has both a load address and a load region\n"),
+ NULL);
+}
+
+void
+lang_leave_output_section_statement (fill_type *fill, const char *memspec,
+ lang_output_section_phdr_list *phdrs,
+ const char *lma_memspec)
+{
+ pop_stat_ptr ();
+ if (in_section_ordering)
+ return;
+
+ lang_get_regions (¤t_section->region,
+ ¤t_section->lma_region,
+ memspec, lma_memspec,
+ current_section->load_base != NULL,
+ current_section->addr_tree != NULL);
+
+ current_section->fill = fill;
+ current_section->phdrs = phdrs;
+}
+
+/* Set the output format type. -oformat overrides scripts. */
+
+void
+lang_add_output_format (const char *format,
+ const char *big,
+ const char *little,
+ int from_script)
+{
+ if (output_target == NULL || !from_script)
+ {
+ if (command_line.endian == ENDIAN_BIG
+ && big != NULL)
+ format = big;
+ else if (command_line.endian == ENDIAN_LITTLE
+ && little != NULL)
+ format = little;
+
+ if (getenv ("LD_FORCE_LE") != NULL)
+ {
+ if (strcmp (format, "elf64-powerpc") == 0)
+ format = "elf64-powerpcle";
+ else if (strcmp (format, "elf32-powerpc") == 0)
+ format = "elf32-powerpcle";
+ else if (strcmp (format, "elf64-big") == 0)
+ format = "elf64-little";
+ else if (strcmp (format, "elf32-big") == 0)
+ format = "elf32-little";
+ }
+
+ output_target = format;
+ }
+}
+
+void
+lang_add_insert (const char *where, int is_before)
+{
+ lang_insert_statement_type *new_stmt;
+
+ new_stmt = new_stat (lang_insert_statement, stat_ptr);
+ new_stmt->where = where;
+ new_stmt->is_before = is_before;
+ saved_script_handle = previous_script_handle;
+}
+
+/* Enter a group. This creates a new lang_group_statement, and sets
+ stat_ptr to build new statements within the group. */
+
+void
+lang_enter_group (void)
+{
+ lang_group_statement_type *g;
+
+ g = new_stat (lang_group_statement, stat_ptr);
+ lang_list_init (&g->children);
+ push_stat_ptr (&g->children);
+}
+
+/* Leave a group. This just resets stat_ptr to start writing to the
+ regular list of statements again. Note that this will not work if
+ groups can occur inside anything else which can adjust stat_ptr,
+ but currently they can't. */
+
+void
+lang_leave_group (void)
+{
+ pop_stat_ptr ();
+}
+
+/* Add a new program header. This is called for each entry in a PHDRS
+ command in a linker script. */
+
+void
+lang_new_phdr (const char *name,
+ etree_type *type,
+ bool filehdr,
+ bool phdrs,
+ etree_type *at,
+ etree_type *flags)
+{
+ struct lang_phdr *n, **pp;
+ bool hdrs;
+
+ n = stat_alloc (sizeof (struct lang_phdr));
+ n->next = NULL;
+ n->name = name;
+ n->type = exp_get_vma (type, NULL, 0, "program header type");
+ n->filehdr = filehdr;
+ n->phdrs = phdrs;
+ n->at = at;
+ n->flags = flags;
+
+ hdrs = n->type == 1 && (phdrs || filehdr);
+
+ for (pp = &lang_phdr_list; *pp != NULL; pp = &(*pp)->next)
+ if (hdrs
+ && (*pp)->type == 1
+ && !((*pp)->filehdr || (*pp)->phdrs))
+ {
+ einfo (_("%X%P:%pS: PHDRS and FILEHDR are not supported"
+ " when prior PT_LOAD headers lack them\n"), NULL);
+ hdrs = false;
+ }
+
+ *pp = n;
+}
+
+/* Record the program header information in the output BFD. FIXME: We
+ should not be calling an ELF specific function here. */
+
+static void
+lang_record_phdrs (void)
+{
+ unsigned int alc;
+ asection **secs;
+ lang_output_section_phdr_list *last;
+ struct lang_phdr *l;
+ lang_output_section_statement_type *os;
+
+ alc = 10;
+ secs = (asection **) xmalloc (alc * sizeof (asection *));
+ last = NULL;
+
+ for (l = lang_phdr_list; l != NULL; l = l->next)
+ {
+ unsigned int c;
+ flagword flags;
+ bfd_vma at;
+
+ c = 0;
+ for (os = (void *) lang_os_list.head;
+ os != NULL;
+ os = os->next)
+ {
+ lang_output_section_phdr_list *pl;
+
+ if (os->constraint < 0)
+ continue;
+
+ pl = os->phdrs;
+ if (pl != NULL)
+ last = pl;
+ else
+ {
+ if (os->sectype == noload_section
+ || os->bfd_section == NULL
+ || (os->bfd_section->flags & SEC_ALLOC) == 0)
+ continue;
+
+ /* Don't add orphans to PT_INTERP header. */
+ if (l->type == PT_INTERP)
+ continue;
+
+ if (last == NULL)
+ {
+ lang_output_section_statement_type *tmp_os;
+
+ /* If we have not run across a section with a program
+ header assigned to it yet, then scan forwards to find
+ one. This prevents inconsistencies in the linker's
+ behaviour when a script has specified just a single
+ header and there are sections in that script which are
+ not assigned to it, and which occur before the first
+ use of that header. See here for more details:
+ http://sourceware.org/ml/binutils/2007-02/msg00291.html */
+ for (tmp_os = os; tmp_os; tmp_os = tmp_os->next)
+ if (tmp_os->phdrs)
+ {
+ last = tmp_os->phdrs;
+ break;
+ }
+ if (last == NULL)
+ einfo (_("%F%P: no sections assigned to phdrs\n"));
+ }
+ pl = last;
+ }
+
+ if (os->bfd_section == NULL)
+ continue;
+
+ for (; pl != NULL; pl = pl->next)
+ {
+ if (strcmp (pl->name, l->name) == 0)
+ {
+ if (c >= alc)
+ {
+ alc *= 2;
+ secs = (asection **) xrealloc (secs,
+ alc * sizeof (asection *));
+ }
+ secs[c] = os->bfd_section;
+ ++c;
+ pl->used = true;
+ }
+ }
+ }
+
+ if (l->flags == NULL)
+ flags = 0;
+ else
+ flags = exp_get_vma (l->flags, NULL, 0, "phdr flags");
+
+ if (l->at == NULL)
+ at = 0;
+ else
+ at = exp_get_vma (l->at, NULL, 0, "phdr load address");
+
+ if (!bfd_record_phdr (link_info.output_bfd, l->type,
+ l->flags != NULL, flags, l->at != NULL,
+ at, l->filehdr, l->phdrs, c, secs))
+ einfo (_("%F%P: bfd_record_phdr failed: %E\n"));
+ }
+
+ free (secs);
+
+ /* Make sure all the phdr assignments succeeded. */
+ for (os = (void *) lang_os_list.head;
+ os != NULL;
+ os = os->next)
+ {
+ lang_output_section_phdr_list *pl;
+
+ if (os->constraint < 0
+ || os->bfd_section == NULL)
+ continue;
+
+ for (pl = os->phdrs;
+ pl != NULL;
+ pl = pl->next)
+ if (!pl->used && strcmp (pl->name, "NONE") != 0)
+ einfo (_("%X%P: section `%s' assigned to non-existent phdr `%s'\n"),
+ os->name, pl->name);
+ }
+}
+
+/* Record a list of sections which may not be cross referenced. */
+
+void
+lang_add_nocrossref (lang_nocrossref_type *l)
+{
+ struct lang_nocrossrefs *n;
+
+ n = (struct lang_nocrossrefs *) xmalloc (sizeof *n);
+ n->next = nocrossref_list;
+ n->list = l;
+ n->onlyfirst = false;
+ nocrossref_list = n;
+
+ /* Set notice_all so that we get informed about all symbols. */
+ link_info.notice_all = true;
+}
+
+/* Record a section that cannot be referenced from a list of sections. */
+
+void
+lang_add_nocrossref_to (lang_nocrossref_type *l)
+{
+ lang_add_nocrossref (l);
+ nocrossref_list->onlyfirst = true;
+}
+
+/* Overlay handling. We handle overlays with some static variables. */
+
+/* The overlay virtual address. */
+static etree_type *overlay_vma;
+/* And subsection alignment. */
+static etree_type *overlay_subalign;
+
+/* An expression for the maximum section size seen so far. */
+static etree_type *overlay_max;
+
+/* A list of all the sections in this overlay. */
+
+struct overlay_list {
+ struct overlay_list *next;
+ lang_output_section_statement_type *os;
+};
+
+static struct overlay_list *overlay_list;
+
+/* Start handling an overlay. */
+
+void
+lang_enter_overlay (etree_type *vma_expr, etree_type *subalign)
+{
+ /* The grammar should prevent nested overlays from occurring. */
+ ASSERT (overlay_vma == NULL
+ && overlay_subalign == NULL
+ &&